configure revision 316069
1#! /bin/sh
2# Guess values for system-dependent variables and create Makefiles.
3# Generated by GNU Autoconf 2.69 for sntp 4.2.8p10.
4#
5# Report bugs to <http://bugs.ntp.org./>.
6#
7#
8# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
9#
10#
11# This configure script is free software; the Free Software Foundation
12# gives unlimited permission to copy, distribute and modify it.
13## -------------------- ##
14## M4sh Initialization. ##
15## -------------------- ##
16
17# Be more Bourne compatible
18DUALCASE=1; export DUALCASE # for MKS sh
19if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
20  emulate sh
21  NULLCMD=:
22  # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
23  # is contrary to our usage.  Disable this feature.
24  alias -g '${1+"$@"}'='"$@"'
25  setopt NO_GLOB_SUBST
26else
27  case `(set -o) 2>/dev/null` in #(
28  *posix*) :
29    set -o posix ;; #(
30  *) :
31     ;;
32esac
33fi
34
35
36as_nl='
37'
38export as_nl
39# Printing a long string crashes Solaris 7 /usr/bin/printf.
40as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
41as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
42as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
43# Prefer a ksh shell builtin over an external printf program on Solaris,
44# but without wasting forks for bash or zsh.
45if test -z "$BASH_VERSION$ZSH_VERSION" \
46    && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
47  as_echo='print -r --'
48  as_echo_n='print -rn --'
49elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
50  as_echo='printf %s\n'
51  as_echo_n='printf %s'
52else
53  if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
54    as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
55    as_echo_n='/usr/ucb/echo -n'
56  else
57    as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
58    as_echo_n_body='eval
59      arg=$1;
60      case $arg in #(
61      *"$as_nl"*)
62	expr "X$arg" : "X\\(.*\\)$as_nl";
63	arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
64      esac;
65      expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
66    '
67    export as_echo_n_body
68    as_echo_n='sh -c $as_echo_n_body as_echo'
69  fi
70  export as_echo_body
71  as_echo='sh -c $as_echo_body as_echo'
72fi
73
74# The user is always right.
75if test "${PATH_SEPARATOR+set}" != set; then
76  PATH_SEPARATOR=:
77  (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
78    (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
79      PATH_SEPARATOR=';'
80  }
81fi
82
83
84# IFS
85# We need space, tab and new line, in precisely that order.  Quoting is
86# there to prevent editors from complaining about space-tab.
87# (If _AS_PATH_WALK were called with IFS unset, it would disable word
88# splitting by setting IFS to empty value.)
89IFS=" ""	$as_nl"
90
91# Find who we are.  Look in the path if we contain no directory separator.
92as_myself=
93case $0 in #((
94  *[\\/]* ) as_myself=$0 ;;
95  *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
96for as_dir in $PATH
97do
98  IFS=$as_save_IFS
99  test -z "$as_dir" && as_dir=.
100    test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
101  done
102IFS=$as_save_IFS
103
104     ;;
105esac
106# We did not find ourselves, most probably we were run as `sh COMMAND'
107# in which case we are not to be found in the path.
108if test "x$as_myself" = x; then
109  as_myself=$0
110fi
111if test ! -f "$as_myself"; then
112  $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
113  exit 1
114fi
115
116# Unset variables that we do not need and which cause bugs (e.g. in
117# pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
118# suppresses any "Segmentation fault" message there.  '((' could
119# trigger a bug in pdksh 5.2.14.
120for as_var in BASH_ENV ENV MAIL MAILPATH
121do eval test x\${$as_var+set} = xset \
122  && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
123done
124PS1='$ '
125PS2='> '
126PS4='+ '
127
128# NLS nuisances.
129LC_ALL=C
130export LC_ALL
131LANGUAGE=C
132export LANGUAGE
133
134# CDPATH.
135(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
136
137# Use a proper internal environment variable to ensure we don't fall
138  # into an infinite loop, continuously re-executing ourselves.
139  if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
140    _as_can_reexec=no; export _as_can_reexec;
141    # We cannot yet assume a decent shell, so we have to provide a
142# neutralization value for shells without unset; and this also
143# works around shells that cannot unset nonexistent variables.
144# Preserve -v and -x to the replacement shell.
145BASH_ENV=/dev/null
146ENV=/dev/null
147(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
148case $- in # ((((
149  *v*x* | *x*v* ) as_opts=-vx ;;
150  *v* ) as_opts=-v ;;
151  *x* ) as_opts=-x ;;
152  * ) as_opts= ;;
153esac
154exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
155# Admittedly, this is quite paranoid, since all the known shells bail
156# out after a failed `exec'.
157$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
158as_fn_exit 255
159  fi
160  # We don't want this to propagate to other subprocesses.
161          { _as_can_reexec=; unset _as_can_reexec;}
162if test "x$CONFIG_SHELL" = x; then
163  as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
164  emulate sh
165  NULLCMD=:
166  # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
167  # is contrary to our usage.  Disable this feature.
168  alias -g '\${1+\"\$@\"}'='\"\$@\"'
169  setopt NO_GLOB_SUBST
170else
171  case \`(set -o) 2>/dev/null\` in #(
172  *posix*) :
173    set -o posix ;; #(
174  *) :
175     ;;
176esac
177fi
178"
179  as_required="as_fn_return () { (exit \$1); }
180as_fn_success () { as_fn_return 0; }
181as_fn_failure () { as_fn_return 1; }
182as_fn_ret_success () { return 0; }
183as_fn_ret_failure () { return 1; }
184
185exitcode=0
186as_fn_success || { exitcode=1; echo as_fn_success failed.; }
187as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
188as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
189as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
190if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
191
192else
193  exitcode=1; echo positional parameters were not saved.
194fi
195test x\$exitcode = x0 || exit 1
196test -x / || exit 1"
197  as_suggested="  as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
198  as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
199  eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
200  test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
201test \$(( 1 + 1 )) = 2 || exit 1
202
203  test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || (
204    ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
205    ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
206    ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
207    PATH=/empty FPATH=/empty; export PATH FPATH
208    test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\
209      || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1"
210  if (eval "$as_required") 2>/dev/null; then :
211  as_have_required=yes
212else
213  as_have_required=no
214fi
215  if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
216
217else
218  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
219as_found=false
220for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
221do
222  IFS=$as_save_IFS
223  test -z "$as_dir" && as_dir=.
224  as_found=:
225  case $as_dir in #(
226	 /*)
227	   for as_base in sh bash ksh sh5; do
228	     # Try only shells that exist, to save several forks.
229	     as_shell=$as_dir/$as_base
230	     if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
231		    { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
232  CONFIG_SHELL=$as_shell as_have_required=yes
233		   if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
234  break 2
235fi
236fi
237	   done;;
238       esac
239  as_found=false
240done
241$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
242	      { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
243  CONFIG_SHELL=$SHELL as_have_required=yes
244fi; }
245IFS=$as_save_IFS
246
247
248      if test "x$CONFIG_SHELL" != x; then :
249  export CONFIG_SHELL
250             # We cannot yet assume a decent shell, so we have to provide a
251# neutralization value for shells without unset; and this also
252# works around shells that cannot unset nonexistent variables.
253# Preserve -v and -x to the replacement shell.
254BASH_ENV=/dev/null
255ENV=/dev/null
256(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
257case $- in # ((((
258  *v*x* | *x*v* ) as_opts=-vx ;;
259  *v* ) as_opts=-v ;;
260  *x* ) as_opts=-x ;;
261  * ) as_opts= ;;
262esac
263exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
264# Admittedly, this is quite paranoid, since all the known shells bail
265# out after a failed `exec'.
266$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
267exit 255
268fi
269
270    if test x$as_have_required = xno; then :
271  $as_echo "$0: This script requires a shell more modern than all"
272  $as_echo "$0: the shells that I found on your system."
273  if test x${ZSH_VERSION+set} = xset ; then
274    $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
275    $as_echo "$0: be upgraded to zsh 4.3.4 or later."
276  else
277    $as_echo "$0: Please tell bug-autoconf@gnu.org and
278$0: http://bugs.ntp.org./ about your system, including any
279$0: error possibly output before this message. Then install
280$0: a modern shell, or manually run the script under such a
281$0: shell if you do have one."
282  fi
283  exit 1
284fi
285fi
286fi
287SHELL=${CONFIG_SHELL-/bin/sh}
288export SHELL
289# Unset more variables known to interfere with behavior of common tools.
290CLICOLOR_FORCE= GREP_OPTIONS=
291unset CLICOLOR_FORCE GREP_OPTIONS
292
293## --------------------- ##
294## M4sh Shell Functions. ##
295## --------------------- ##
296# as_fn_unset VAR
297# ---------------
298# Portably unset VAR.
299as_fn_unset ()
300{
301  { eval $1=; unset $1;}
302}
303as_unset=as_fn_unset
304
305# as_fn_set_status STATUS
306# -----------------------
307# Set $? to STATUS, without forking.
308as_fn_set_status ()
309{
310  return $1
311} # as_fn_set_status
312
313# as_fn_exit STATUS
314# -----------------
315# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
316as_fn_exit ()
317{
318  set +e
319  as_fn_set_status $1
320  exit $1
321} # as_fn_exit
322
323# as_fn_mkdir_p
324# -------------
325# Create "$as_dir" as a directory, including parents if necessary.
326as_fn_mkdir_p ()
327{
328
329  case $as_dir in #(
330  -*) as_dir=./$as_dir;;
331  esac
332  test -d "$as_dir" || eval $as_mkdir_p || {
333    as_dirs=
334    while :; do
335      case $as_dir in #(
336      *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
337      *) as_qdir=$as_dir;;
338      esac
339      as_dirs="'$as_qdir' $as_dirs"
340      as_dir=`$as_dirname -- "$as_dir" ||
341$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
342	 X"$as_dir" : 'X\(//\)[^/]' \| \
343	 X"$as_dir" : 'X\(//\)$' \| \
344	 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
345$as_echo X"$as_dir" |
346    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
347	    s//\1/
348	    q
349	  }
350	  /^X\(\/\/\)[^/].*/{
351	    s//\1/
352	    q
353	  }
354	  /^X\(\/\/\)$/{
355	    s//\1/
356	    q
357	  }
358	  /^X\(\/\).*/{
359	    s//\1/
360	    q
361	  }
362	  s/.*/./; q'`
363      test -d "$as_dir" && break
364    done
365    test -z "$as_dirs" || eval "mkdir $as_dirs"
366  } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
367
368
369} # as_fn_mkdir_p
370
371# as_fn_executable_p FILE
372# -----------------------
373# Test if FILE is an executable regular file.
374as_fn_executable_p ()
375{
376  test -f "$1" && test -x "$1"
377} # as_fn_executable_p
378# as_fn_append VAR VALUE
379# ----------------------
380# Append the text in VALUE to the end of the definition contained in VAR. Take
381# advantage of any shell optimizations that allow amortized linear growth over
382# repeated appends, instead of the typical quadratic growth present in naive
383# implementations.
384if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
385  eval 'as_fn_append ()
386  {
387    eval $1+=\$2
388  }'
389else
390  as_fn_append ()
391  {
392    eval $1=\$$1\$2
393  }
394fi # as_fn_append
395
396# as_fn_arith ARG...
397# ------------------
398# Perform arithmetic evaluation on the ARGs, and store the result in the
399# global $as_val. Take advantage of shells that can avoid forks. The arguments
400# must be portable across $(()) and expr.
401if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
402  eval 'as_fn_arith ()
403  {
404    as_val=$(( $* ))
405  }'
406else
407  as_fn_arith ()
408  {
409    as_val=`expr "$@" || test $? -eq 1`
410  }
411fi # as_fn_arith
412
413
414# as_fn_error STATUS ERROR [LINENO LOG_FD]
415# ----------------------------------------
416# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
417# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
418# script with STATUS, using 1 if that was 0.
419as_fn_error ()
420{
421  as_status=$1; test $as_status -eq 0 && as_status=1
422  if test "$4"; then
423    as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
424    $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
425  fi
426  $as_echo "$as_me: error: $2" >&2
427  as_fn_exit $as_status
428} # as_fn_error
429
430if expr a : '\(a\)' >/dev/null 2>&1 &&
431   test "X`expr 00001 : '.*\(...\)'`" = X001; then
432  as_expr=expr
433else
434  as_expr=false
435fi
436
437if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
438  as_basename=basename
439else
440  as_basename=false
441fi
442
443if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
444  as_dirname=dirname
445else
446  as_dirname=false
447fi
448
449as_me=`$as_basename -- "$0" ||
450$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
451	 X"$0" : 'X\(//\)$' \| \
452	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
453$as_echo X/"$0" |
454    sed '/^.*\/\([^/][^/]*\)\/*$/{
455	    s//\1/
456	    q
457	  }
458	  /^X\/\(\/\/\)$/{
459	    s//\1/
460	    q
461	  }
462	  /^X\/\(\/\).*/{
463	    s//\1/
464	    q
465	  }
466	  s/.*/./; q'`
467
468# Avoid depending upon Character Ranges.
469as_cr_letters='abcdefghijklmnopqrstuvwxyz'
470as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
471as_cr_Letters=$as_cr_letters$as_cr_LETTERS
472as_cr_digits='0123456789'
473as_cr_alnum=$as_cr_Letters$as_cr_digits
474
475
476  as_lineno_1=$LINENO as_lineno_1a=$LINENO
477  as_lineno_2=$LINENO as_lineno_2a=$LINENO
478  eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
479  test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
480  # Blame Lee E. McMahon (1931-1989) for sed's syntax.  :-)
481  sed -n '
482    p
483    /[$]LINENO/=
484  ' <$as_myself |
485    sed '
486      s/[$]LINENO.*/&-/
487      t lineno
488      b
489      :lineno
490      N
491      :loop
492      s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
493      t loop
494      s/-\n.*//
495    ' >$as_me.lineno &&
496  chmod +x "$as_me.lineno" ||
497    { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
498
499  # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
500  # already done that, so ensure we don't try to do so again and fall
501  # in an infinite loop.  This has already happened in practice.
502  _as_can_reexec=no; export _as_can_reexec
503  # Don't try to exec as it changes $[0], causing all sort of problems
504  # (the dirname of $[0] is not the place where we might find the
505  # original and so on.  Autoconf is especially sensitive to this).
506  . "./$as_me.lineno"
507  # Exit status is that of the last command.
508  exit
509}
510
511ECHO_C= ECHO_N= ECHO_T=
512case `echo -n x` in #(((((
513-n*)
514  case `echo 'xy\c'` in
515  *c*) ECHO_T='	';;	# ECHO_T is single tab character.
516  xy)  ECHO_C='\c';;
517  *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
518       ECHO_T='	';;
519  esac;;
520*)
521  ECHO_N='-n';;
522esac
523
524rm -f conf$$ conf$$.exe conf$$.file
525if test -d conf$$.dir; then
526  rm -f conf$$.dir/conf$$.file
527else
528  rm -f conf$$.dir
529  mkdir conf$$.dir 2>/dev/null
530fi
531if (echo >conf$$.file) 2>/dev/null; then
532  if ln -s conf$$.file conf$$ 2>/dev/null; then
533    as_ln_s='ln -s'
534    # ... but there are two gotchas:
535    # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
536    # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
537    # In both cases, we have to default to `cp -pR'.
538    ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
539      as_ln_s='cp -pR'
540  elif ln conf$$.file conf$$ 2>/dev/null; then
541    as_ln_s=ln
542  else
543    as_ln_s='cp -pR'
544  fi
545else
546  as_ln_s='cp -pR'
547fi
548rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
549rmdir conf$$.dir 2>/dev/null
550
551if mkdir -p . 2>/dev/null; then
552  as_mkdir_p='mkdir -p "$as_dir"'
553else
554  test -d ./-p && rmdir ./-p
555  as_mkdir_p=false
556fi
557
558as_test_x='test -x'
559as_executable_p=as_fn_executable_p
560
561# Sed expression to map a string onto a valid CPP name.
562as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
563
564# Sed expression to map a string onto a valid variable name.
565as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
566
567SHELL=${CONFIG_SHELL-/bin/sh}
568
569
570test -n "$DJDIR" || exec 7<&0 </dev/null
571exec 6>&1
572
573# Name of the host.
574# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
575# so uname gets run too.
576ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
577
578#
579# Initializations.
580#
581ac_default_prefix=/usr/local
582ac_clean_files=
583ac_config_libobj_dir=.
584LIBOBJS=
585cross_compiling=no
586subdirs=
587MFLAGS=
588MAKEFLAGS=
589
590# Identity of this package.
591PACKAGE_NAME='sntp'
592PACKAGE_TARNAME='sntp'
593PACKAGE_VERSION='4.2.8p10'
594PACKAGE_STRING='sntp 4.2.8p10'
595PACKAGE_BUGREPORT='http://bugs.ntp.org./'
596PACKAGE_URL='http://www.ntp.org./'
597
598# Factoring default headers for most tests.
599ac_includes_default="\
600#include <stdio.h>
601#ifdef HAVE_SYS_TYPES_H
602# include <sys/types.h>
603#endif
604#ifdef HAVE_SYS_STAT_H
605# include <sys/stat.h>
606#endif
607#ifdef STDC_HEADERS
608# include <stdlib.h>
609# include <stddef.h>
610#else
611# ifdef HAVE_STDLIB_H
612#  include <stdlib.h>
613# endif
614#endif
615#ifdef HAVE_STRING_H
616# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
617#  include <memory.h>
618# endif
619# include <string.h>
620#endif
621#ifdef HAVE_STRINGS_H
622# include <strings.h>
623#endif
624#ifdef HAVE_INTTYPES_H
625# include <inttypes.h>
626#endif
627#ifdef HAVE_STDINT_H
628# include <stdint.h>
629#endif
630#ifdef HAVE_UNISTD_H
631# include <unistd.h>
632#endif"
633
634ac_header_list=
635enable_option_checking=no
636ac_subst_vars='am__EXEEXT_FALSE
637am__EXEEXT_TRUE
638LTLIBOBJS
639BUILD_TEST_KODFILE_FALSE
640BUILD_TEST_KODFILE_TRUE
641BUILD_TEST_KODDATABASE_FALSE
642BUILD_TEST_KODDATABASE_TRUE
643UNITYBUILD_AVAILABLE_FALSE
644UNITYBUILD_AVAILABLE_TRUE
645PATH_RUBY
646VER_SUFFIX
647LIB_SYSLOG
648subdirs
649BUILD_LIBEVENT_FALSE
650BUILD_LIBEVENT_TRUE
651LDADD_LIBEVENT
652CPPFLAGS_LIBEVENT
653CFLAGS_LIBEVENT
654PKG_CONFIG
655NTP_FORCE_LIBEVENT_DIST
656LIBOPTS_DIR
657LIBOPTS_CFLAGS
658LIBOPTS_LDADD
659NEED_LIBOPTS_FALSE
660NEED_LIBOPTS_TRUE
661INSTALL_LIBOPTS_FALSE
662INSTALL_LIBOPTS_TRUE
663POSIX_SHELL
664GL_GENERATE_STDNORETURN_H_FALSE
665GL_GENERATE_STDNORETURN_H_TRUE
666STDNORETURN_H
667BUILD_SNTP_FALSE
668BUILD_SNTP_TRUE
669SNTP
670LIBTOOL_DEPS
671LT_SYS_LIBRARY_PATH
672OTOOL64
673OTOOL
674LIPO
675NMEDIT
676DSYMUTIL
677MANIFEST_TOOL
678RANLIB
679DLLTOOL
680OBJDUMP
681LN_S
682NM
683ac_ct_DUMPBIN
684DUMPBIN
685LIBTOOL
686LIBOBJS
687PTHREADS_FALSE
688PTHREADS_TRUE
689LIBISC_PTHREADS_NOTHREADS
690PTHREAD_LIBS
691LTHREAD_LIBS
692BUILD_THREAD
693HAVE_INLINE
694LDADD_LIBUTIL
695ALLOCA
696LIBM
697EDITLINE_LIBS
698LD
699FGREP
700SED
701LDADD_LIBNTP
702NTP_CROSSCOMPILE_FALSE
703NTP_CROSSCOMPILE_TRUE
704ac_ct_AR
705AR
706INSTALL_UPDATE_LEAP_FALSE
707INSTALL_UPDATE_LEAP_TRUE
708UPDATE_LEAP_NI
709UPDATE_LEAP_MS
710UPDATE_LEAP_DS
711UPDATE_LEAP_DL
712UPDATE_LEAP_DB
713TIMETRIM_NI
714TIMETRIM_MS
715TIMETRIM_DS
716TIMETRIM_DL
717TIMETRIM_DB
718TICKADJ_NI
719TICKADJ_MS
720TICKADJ_DS
721TICKADJ_DL
722TICKADJ_DB
723SNTP_NI
724SNTP_MS
725SNTP_DS
726SNTP_DL
727SNTP_DB
728NTP_WAIT_NI
729NTP_WAIT_MS
730NTP_WAIT_DS
731NTP_WAIT_DL
732NTP_WAIT_DB
733NTP_KEYGEN_NI
734NTP_KEYGEN_MS
735NTP_KEYGEN_DS
736NTP_KEYGEN_DL
737NTP_KEYGEN_DB
738NTPTRACE_NI
739NTPTRACE_MS
740NTPTRACE_DS
741NTPTRACE_DL
742NTPTRACE_DB
743NTPTIME_NI
744NTPTIME_MS
745NTPTIME_DS
746NTPTIME_DL
747NTPTIME_DB
748INSTALL_NTPSWEEP_FALSE
749INSTALL_NTPSWEEP_TRUE
750NTPSWEEP_NI
751NTPSWEEP_MS
752NTPSWEEP_DS
753NTPSWEEP_DL
754NTPSWEEP_DB
755NTPSNMPD_NI
756NTPSNMPD_MS
757NTPSNMPD_DS
758NTPSNMPD_DL
759NTPSNMPD_DB
760NTPQ_NI
761NTPQ_MS
762NTPQ_DS
763NTPQ_DL
764NTPQ_DB
765NTPD_NI
766NTPD_MS
767NTPD_DS
768NTPD_DL
769NTPD_DB
770NTPDSIM_NI
771NTPDSIM_MS
772NTPDSIM_DS
773NTPDSIM_DL
774NTPDSIM_DB
775NTPDC_NI
776NTPDC_MS
777NTPDC_DS
778NTPDC_DL
779NTPDC_DB
780NTPDATE_NI
781NTPDATE_MS
782NTPDATE_DS
783NTPDATE_DL
784NTPDATE_DB
785MANTAGFMT
786CALC_TICKADJ_NI
787CALC_TICKADJ_MS
788CALC_TICKADJ_DS
789CALC_TICKADJ_DL
790CALC_TICKADJ_DB
791WANT_CALC_TICKADJ_MS_FALSE
792WANT_CALC_TICKADJ_MS_TRUE
793NTP_HARD_LDFLAGS
794NTP_HARD_CPPFLAGS
795NTP_HARD_CFLAGS
796LDFLAGS_NTP
797LDADD_NTP
798CPPFLAGS_NTP
799CFLAGS_NTP
800EGREP
801GREP
802CPP
803am__fastdepCC_FALSE
804am__fastdepCC_TRUE
805CCDEPMODE
806am__nodep
807AMDEPBACKSLASH
808AMDEP_FALSE
809AMDEP_TRUE
810am__quote
811am__include
812DEPDIR
813OBJEXT
814EXEEXT
815ac_ct_CC
816CPPFLAGS
817LDFLAGS
818CFLAGS
819CC
820host_os
821host_vendor
822host_cpu
823host
824build_os
825build_vendor
826build_cpu
827build
828AM_BACKSLASH
829AM_DEFAULT_VERBOSITY
830AM_DEFAULT_V
831AM_V
832am__untar
833am__tar
834AMTAR
835am__leading_dot
836SET_MAKE
837AWK
838mkdir_p
839MKDIR_P
840INSTALL_STRIP_PROGRAM
841STRIP
842install_sh
843MAKEINFO
844AUTOHEADER
845AUTOMAKE
846AUTOCONF
847ACLOCAL
848VERSION
849PACKAGE
850CYGPATH_W
851am__isrc
852INSTALL_DATA
853INSTALL_SCRIPT
854INSTALL_PROGRAM
855target_alias
856host_alias
857build_alias
858LIBS
859ECHO_T
860ECHO_N
861ECHO_C
862DEFS
863mandir
864localedir
865libdir
866psdir
867pdfdir
868dvidir
869htmldir
870infodir
871docdir
872oldincludedir
873includedir
874localstatedir
875sharedstatedir
876sysconfdir
877datadir
878datarootdir
879libexecdir
880sbindir
881bindir
882program_transform_name
883prefix
884exec_prefix
885PACKAGE_URL
886PACKAGE_BUGREPORT
887PACKAGE_STRING
888PACKAGE_VERSION
889PACKAGE_TARNAME
890PACKAGE_NAME
891PATH_SEPARATOR
892SHELL'
893ac_subst_files=''
894ac_user_opts='
895enable_option_checking
896enable_silent_rules
897enable_dependency_tracking
898with_locfile
899with_gnu_ld
900with_lineeditlibs
901enable_debugging
902enable_thread_support
903with_threads
904with_yielding_select
905enable_c99_snprintf
906enable_clockctl
907enable_linuxcaps
908enable_solarisprivs
909enable_shared
910enable_static
911with_pic
912enable_fast_install
913with_aix_soname
914with_sysroot
915enable_libtool_lock
916with_sntp
917enable_nls
918enable_local_libopts
919enable_libopts_install
920with_autoopts_config
921with_regex_header
922with_libregex
923with_libregex_cflags
924with_libregex_libs
925enable_optional_args
926enable_local_libevent
927with_crypto
928with_openssl_libdir
929with_openssl_incdir
930with_rpath
931enable_ipv6
932with_kame
933enable_getifaddrs
934enable_problem_tests
935'
936      ac_precious_vars='build_alias
937host_alias
938target_alias
939CC
940CFLAGS
941LDFLAGS
942LIBS
943CPPFLAGS
944CPP
945LT_SYS_LIBRARY_PATH'
946ac_subdirs_all='libevent'
947
948# Initialize some variables set by options.
949ac_init_help=
950ac_init_version=false
951ac_unrecognized_opts=
952ac_unrecognized_sep=
953# The variables have the same names as the options, with
954# dashes changed to underlines.
955cache_file=/dev/null
956exec_prefix=NONE
957no_create=
958no_recursion=
959prefix=NONE
960program_prefix=NONE
961program_suffix=NONE
962program_transform_name=s,x,x,
963silent=
964site=
965srcdir=
966verbose=
967x_includes=NONE
968x_libraries=NONE
969
970# Installation directory options.
971# These are left unexpanded so users can "make install exec_prefix=/foo"
972# and all the variables that are supposed to be based on exec_prefix
973# by default will actually change.
974# Use braces instead of parens because sh, perl, etc. also accept them.
975# (The list follows the same order as the GNU Coding Standards.)
976bindir='${exec_prefix}/bin'
977sbindir='${exec_prefix}/sbin'
978libexecdir='${exec_prefix}/libexec'
979datarootdir='${prefix}/share'
980datadir='${datarootdir}'
981sysconfdir='${prefix}/etc'
982sharedstatedir='${prefix}/com'
983localstatedir='${prefix}/var'
984includedir='${prefix}/include'
985oldincludedir='/usr/include'
986docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
987infodir='${datarootdir}/info'
988htmldir='${docdir}'
989dvidir='${docdir}'
990pdfdir='${docdir}'
991psdir='${docdir}'
992libdir='${exec_prefix}/lib'
993localedir='${datarootdir}/locale'
994mandir='${datarootdir}/man'
995
996ac_prev=
997ac_dashdash=
998for ac_option
999do
1000  # If the previous option needs an argument, assign it.
1001  if test -n "$ac_prev"; then
1002    eval $ac_prev=\$ac_option
1003    ac_prev=
1004    continue
1005  fi
1006
1007  case $ac_option in
1008  *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1009  *=)   ac_optarg= ;;
1010  *)    ac_optarg=yes ;;
1011  esac
1012
1013  # Accept the important Cygnus configure options, so we can diagnose typos.
1014
1015  case $ac_dashdash$ac_option in
1016  --)
1017    ac_dashdash=yes ;;
1018
1019  -bindir | --bindir | --bindi | --bind | --bin | --bi)
1020    ac_prev=bindir ;;
1021  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1022    bindir=$ac_optarg ;;
1023
1024  -build | --build | --buil | --bui | --bu)
1025    ac_prev=build_alias ;;
1026  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1027    build_alias=$ac_optarg ;;
1028
1029  -cache-file | --cache-file | --cache-fil | --cache-fi \
1030  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1031    ac_prev=cache_file ;;
1032  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1033  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1034    cache_file=$ac_optarg ;;
1035
1036  --config-cache | -C)
1037    cache_file=config.cache ;;
1038
1039  -datadir | --datadir | --datadi | --datad)
1040    ac_prev=datadir ;;
1041  -datadir=* | --datadir=* | --datadi=* | --datad=*)
1042    datadir=$ac_optarg ;;
1043
1044  -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1045  | --dataroo | --dataro | --datar)
1046    ac_prev=datarootdir ;;
1047  -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1048  | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1049    datarootdir=$ac_optarg ;;
1050
1051  -disable-* | --disable-*)
1052    ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1053    # Reject names that are not valid shell variable names.
1054    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1055      as_fn_error $? "invalid feature name: $ac_useropt"
1056    ac_useropt_orig=$ac_useropt
1057    ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1058    case $ac_user_opts in
1059      *"
1060"enable_$ac_useropt"
1061"*) ;;
1062      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1063	 ac_unrecognized_sep=', ';;
1064    esac
1065    eval enable_$ac_useropt=no ;;
1066
1067  -docdir | --docdir | --docdi | --doc | --do)
1068    ac_prev=docdir ;;
1069  -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1070    docdir=$ac_optarg ;;
1071
1072  -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1073    ac_prev=dvidir ;;
1074  -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1075    dvidir=$ac_optarg ;;
1076
1077  -enable-* | --enable-*)
1078    ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1079    # Reject names that are not valid shell variable names.
1080    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1081      as_fn_error $? "invalid feature name: $ac_useropt"
1082    ac_useropt_orig=$ac_useropt
1083    ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1084    case $ac_user_opts in
1085      *"
1086"enable_$ac_useropt"
1087"*) ;;
1088      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1089	 ac_unrecognized_sep=', ';;
1090    esac
1091    eval enable_$ac_useropt=\$ac_optarg ;;
1092
1093  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1094  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1095  | --exec | --exe | --ex)
1096    ac_prev=exec_prefix ;;
1097  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1098  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1099  | --exec=* | --exe=* | --ex=*)
1100    exec_prefix=$ac_optarg ;;
1101
1102  -gas | --gas | --ga | --g)
1103    # Obsolete; use --with-gas.
1104    with_gas=yes ;;
1105
1106  -help | --help | --hel | --he | -h)
1107    ac_init_help=long ;;
1108  -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1109    ac_init_help=recursive ;;
1110  -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1111    ac_init_help=short ;;
1112
1113  -host | --host | --hos | --ho)
1114    ac_prev=host_alias ;;
1115  -host=* | --host=* | --hos=* | --ho=*)
1116    host_alias=$ac_optarg ;;
1117
1118  -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1119    ac_prev=htmldir ;;
1120  -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1121  | --ht=*)
1122    htmldir=$ac_optarg ;;
1123
1124  -includedir | --includedir | --includedi | --included | --include \
1125  | --includ | --inclu | --incl | --inc)
1126    ac_prev=includedir ;;
1127  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1128  | --includ=* | --inclu=* | --incl=* | --inc=*)
1129    includedir=$ac_optarg ;;
1130
1131  -infodir | --infodir | --infodi | --infod | --info | --inf)
1132    ac_prev=infodir ;;
1133  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1134    infodir=$ac_optarg ;;
1135
1136  -libdir | --libdir | --libdi | --libd)
1137    ac_prev=libdir ;;
1138  -libdir=* | --libdir=* | --libdi=* | --libd=*)
1139    libdir=$ac_optarg ;;
1140
1141  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1142  | --libexe | --libex | --libe)
1143    ac_prev=libexecdir ;;
1144  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1145  | --libexe=* | --libex=* | --libe=*)
1146    libexecdir=$ac_optarg ;;
1147
1148  -localedir | --localedir | --localedi | --localed | --locale)
1149    ac_prev=localedir ;;
1150  -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1151    localedir=$ac_optarg ;;
1152
1153  -localstatedir | --localstatedir | --localstatedi | --localstated \
1154  | --localstate | --localstat | --localsta | --localst | --locals)
1155    ac_prev=localstatedir ;;
1156  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1157  | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1158    localstatedir=$ac_optarg ;;
1159
1160  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1161    ac_prev=mandir ;;
1162  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1163    mandir=$ac_optarg ;;
1164
1165  -nfp | --nfp | --nf)
1166    # Obsolete; use --without-fp.
1167    with_fp=no ;;
1168
1169  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1170  | --no-cr | --no-c | -n)
1171    no_create=yes ;;
1172
1173  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1174  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1175    no_recursion=yes ;;
1176
1177  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1178  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1179  | --oldin | --oldi | --old | --ol | --o)
1180    ac_prev=oldincludedir ;;
1181  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1182  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1183  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1184    oldincludedir=$ac_optarg ;;
1185
1186  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1187    ac_prev=prefix ;;
1188  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1189    prefix=$ac_optarg ;;
1190
1191  -program-prefix | --program-prefix | --program-prefi | --program-pref \
1192  | --program-pre | --program-pr | --program-p)
1193    ac_prev=program_prefix ;;
1194  -program-prefix=* | --program-prefix=* | --program-prefi=* \
1195  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1196    program_prefix=$ac_optarg ;;
1197
1198  -program-suffix | --program-suffix | --program-suffi | --program-suff \
1199  | --program-suf | --program-su | --program-s)
1200    ac_prev=program_suffix ;;
1201  -program-suffix=* | --program-suffix=* | --program-suffi=* \
1202  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1203    program_suffix=$ac_optarg ;;
1204
1205  -program-transform-name | --program-transform-name \
1206  | --program-transform-nam | --program-transform-na \
1207  | --program-transform-n | --program-transform- \
1208  | --program-transform | --program-transfor \
1209  | --program-transfo | --program-transf \
1210  | --program-trans | --program-tran \
1211  | --progr-tra | --program-tr | --program-t)
1212    ac_prev=program_transform_name ;;
1213  -program-transform-name=* | --program-transform-name=* \
1214  | --program-transform-nam=* | --program-transform-na=* \
1215  | --program-transform-n=* | --program-transform-=* \
1216  | --program-transform=* | --program-transfor=* \
1217  | --program-transfo=* | --program-transf=* \
1218  | --program-trans=* | --program-tran=* \
1219  | --progr-tra=* | --program-tr=* | --program-t=*)
1220    program_transform_name=$ac_optarg ;;
1221
1222  -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1223    ac_prev=pdfdir ;;
1224  -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1225    pdfdir=$ac_optarg ;;
1226
1227  -psdir | --psdir | --psdi | --psd | --ps)
1228    ac_prev=psdir ;;
1229  -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1230    psdir=$ac_optarg ;;
1231
1232  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1233  | -silent | --silent | --silen | --sile | --sil)
1234    silent=yes ;;
1235
1236  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1237    ac_prev=sbindir ;;
1238  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1239  | --sbi=* | --sb=*)
1240    sbindir=$ac_optarg ;;
1241
1242  -sharedstatedir | --sharedstatedir | --sharedstatedi \
1243  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1244  | --sharedst | --shareds | --shared | --share | --shar \
1245  | --sha | --sh)
1246    ac_prev=sharedstatedir ;;
1247  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1248  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1249  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1250  | --sha=* | --sh=*)
1251    sharedstatedir=$ac_optarg ;;
1252
1253  -site | --site | --sit)
1254    ac_prev=site ;;
1255  -site=* | --site=* | --sit=*)
1256    site=$ac_optarg ;;
1257
1258  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1259    ac_prev=srcdir ;;
1260  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1261    srcdir=$ac_optarg ;;
1262
1263  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1264  | --syscon | --sysco | --sysc | --sys | --sy)
1265    ac_prev=sysconfdir ;;
1266  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1267  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1268    sysconfdir=$ac_optarg ;;
1269
1270  -target | --target | --targe | --targ | --tar | --ta | --t)
1271    ac_prev=target_alias ;;
1272  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1273    target_alias=$ac_optarg ;;
1274
1275  -v | -verbose | --verbose | --verbos | --verbo | --verb)
1276    verbose=yes ;;
1277
1278  -version | --version | --versio | --versi | --vers | -V)
1279    ac_init_version=: ;;
1280
1281  -with-* | --with-*)
1282    ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1283    # Reject names that are not valid shell variable names.
1284    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1285      as_fn_error $? "invalid package name: $ac_useropt"
1286    ac_useropt_orig=$ac_useropt
1287    ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1288    case $ac_user_opts in
1289      *"
1290"with_$ac_useropt"
1291"*) ;;
1292      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1293	 ac_unrecognized_sep=', ';;
1294    esac
1295    eval with_$ac_useropt=\$ac_optarg ;;
1296
1297  -without-* | --without-*)
1298    ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1299    # Reject names that are not valid shell variable names.
1300    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1301      as_fn_error $? "invalid package name: $ac_useropt"
1302    ac_useropt_orig=$ac_useropt
1303    ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1304    case $ac_user_opts in
1305      *"
1306"with_$ac_useropt"
1307"*) ;;
1308      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1309	 ac_unrecognized_sep=', ';;
1310    esac
1311    eval with_$ac_useropt=no ;;
1312
1313  --x)
1314    # Obsolete; use --with-x.
1315    with_x=yes ;;
1316
1317  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1318  | --x-incl | --x-inc | --x-in | --x-i)
1319    ac_prev=x_includes ;;
1320  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1321  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1322    x_includes=$ac_optarg ;;
1323
1324  -x-libraries | --x-libraries | --x-librarie | --x-librari \
1325  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1326    ac_prev=x_libraries ;;
1327  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1328  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1329    x_libraries=$ac_optarg ;;
1330
1331  -*) as_fn_error $? "unrecognized option: \`$ac_option'
1332Try \`$0 --help' for more information"
1333    ;;
1334
1335  *=*)
1336    ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1337    # Reject names that are not valid shell variable names.
1338    case $ac_envvar in #(
1339      '' | [0-9]* | *[!_$as_cr_alnum]* )
1340      as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1341    esac
1342    eval $ac_envvar=\$ac_optarg
1343    export $ac_envvar ;;
1344
1345  *)
1346    # FIXME: should be removed in autoconf 3.0.
1347    $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1348    expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1349      $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1350    : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1351    ;;
1352
1353  esac
1354done
1355
1356if test -n "$ac_prev"; then
1357  ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1358  as_fn_error $? "missing argument to $ac_option"
1359fi
1360
1361if test -n "$ac_unrecognized_opts"; then
1362  case $enable_option_checking in
1363    no) ;;
1364    fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1365    *)     $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1366  esac
1367fi
1368
1369# Check all directory arguments for consistency.
1370for ac_var in	exec_prefix prefix bindir sbindir libexecdir datarootdir \
1371		datadir sysconfdir sharedstatedir localstatedir includedir \
1372		oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1373		libdir localedir mandir
1374do
1375  eval ac_val=\$$ac_var
1376  # Remove trailing slashes.
1377  case $ac_val in
1378    */ )
1379      ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1380      eval $ac_var=\$ac_val;;
1381  esac
1382  # Be sure to have absolute directory names.
1383  case $ac_val in
1384    [\\/$]* | ?:[\\/]* )  continue;;
1385    NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1386  esac
1387  as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1388done
1389
1390# There might be people who depend on the old broken behavior: `$host'
1391# used to hold the argument of --host etc.
1392# FIXME: To remove some day.
1393build=$build_alias
1394host=$host_alias
1395target=$target_alias
1396
1397# FIXME: To remove some day.
1398if test "x$host_alias" != x; then
1399  if test "x$build_alias" = x; then
1400    cross_compiling=maybe
1401  elif test "x$build_alias" != "x$host_alias"; then
1402    cross_compiling=yes
1403  fi
1404fi
1405
1406ac_tool_prefix=
1407test -n "$host_alias" && ac_tool_prefix=$host_alias-
1408
1409test "$silent" = yes && exec 6>/dev/null
1410
1411
1412ac_pwd=`pwd` && test -n "$ac_pwd" &&
1413ac_ls_di=`ls -di .` &&
1414ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1415  as_fn_error $? "working directory cannot be determined"
1416test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1417  as_fn_error $? "pwd does not report name of working directory"
1418
1419
1420# Find the source files, if location was not specified.
1421if test -z "$srcdir"; then
1422  ac_srcdir_defaulted=yes
1423  # Try the directory containing this script, then the parent directory.
1424  ac_confdir=`$as_dirname -- "$as_myself" ||
1425$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1426	 X"$as_myself" : 'X\(//\)[^/]' \| \
1427	 X"$as_myself" : 'X\(//\)$' \| \
1428	 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1429$as_echo X"$as_myself" |
1430    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1431	    s//\1/
1432	    q
1433	  }
1434	  /^X\(\/\/\)[^/].*/{
1435	    s//\1/
1436	    q
1437	  }
1438	  /^X\(\/\/\)$/{
1439	    s//\1/
1440	    q
1441	  }
1442	  /^X\(\/\).*/{
1443	    s//\1/
1444	    q
1445	  }
1446	  s/.*/./; q'`
1447  srcdir=$ac_confdir
1448  if test ! -r "$srcdir/$ac_unique_file"; then
1449    srcdir=..
1450  fi
1451else
1452  ac_srcdir_defaulted=no
1453fi
1454if test ! -r "$srcdir/$ac_unique_file"; then
1455  test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1456  as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1457fi
1458ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1459ac_abs_confdir=`(
1460	cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1461	pwd)`
1462# When building in place, set srcdir=.
1463if test "$ac_abs_confdir" = "$ac_pwd"; then
1464  srcdir=.
1465fi
1466# Remove unnecessary trailing slashes from srcdir.
1467# Double slashes in file names in object file debugging info
1468# mess up M-x gdb in Emacs.
1469case $srcdir in
1470*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1471esac
1472for ac_var in $ac_precious_vars; do
1473  eval ac_env_${ac_var}_set=\${${ac_var}+set}
1474  eval ac_env_${ac_var}_value=\$${ac_var}
1475  eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1476  eval ac_cv_env_${ac_var}_value=\$${ac_var}
1477done
1478
1479#
1480# Report the --help message.
1481#
1482if test "$ac_init_help" = "long"; then
1483  # Omit some internal or obsolete options to make the list less imposing.
1484  # This message is too long to be a string in the A/UX 3.1 sh.
1485  cat <<_ACEOF
1486\`configure' configures sntp 4.2.8p10 to adapt to many kinds of systems.
1487
1488Usage: $0 [OPTION]... [VAR=VALUE]...
1489
1490To assign environment variables (e.g., CC, CFLAGS...), specify them as
1491VAR=VALUE.  See below for descriptions of some of the useful variables.
1492
1493Defaults for the options are specified in brackets.
1494
1495Configuration:
1496  -h, --help              display this help and exit
1497      --help=short        display options specific to this package
1498      --help=recursive    display the short help of all the included packages
1499  -V, --version           display version information and exit
1500  -q, --quiet, --silent   do not print \`checking ...' messages
1501      --cache-file=FILE   cache test results in FILE [disabled]
1502  -C, --config-cache      alias for \`--cache-file=config.cache'
1503  -n, --no-create         do not create output files
1504      --srcdir=DIR        find the sources in DIR [configure dir or \`..']
1505
1506Installation directories:
1507  --prefix=PREFIX         install architecture-independent files in PREFIX
1508                          [$ac_default_prefix]
1509  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
1510                          [PREFIX]
1511
1512By default, \`make install' will install all the files in
1513\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
1514an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1515for instance \`--prefix=\$HOME'.
1516
1517For better control, use the options below.
1518
1519Fine tuning of the installation directories:
1520  --bindir=DIR            user executables [EPREFIX/bin]
1521  --sbindir=DIR           system admin executables [EPREFIX/sbin]
1522  --libexecdir=DIR        program executables [EPREFIX/libexec]
1523  --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
1524  --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
1525  --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
1526  --libdir=DIR            object code libraries [EPREFIX/lib]
1527  --includedir=DIR        C header files [PREFIX/include]
1528  --oldincludedir=DIR     C header files for non-gcc [/usr/include]
1529  --datarootdir=DIR       read-only arch.-independent data root [PREFIX/share]
1530  --datadir=DIR           read-only architecture-independent data [DATAROOTDIR]
1531  --infodir=DIR           info documentation [DATAROOTDIR/info]
1532  --localedir=DIR         locale-dependent data [DATAROOTDIR/locale]
1533  --mandir=DIR            man documentation [DATAROOTDIR/man]
1534  --docdir=DIR            documentation root [DATAROOTDIR/doc/sntp]
1535  --htmldir=DIR           html documentation [DOCDIR]
1536  --dvidir=DIR            dvi documentation [DOCDIR]
1537  --pdfdir=DIR            pdf documentation [DOCDIR]
1538  --psdir=DIR             ps documentation [DOCDIR]
1539_ACEOF
1540
1541  cat <<\_ACEOF
1542
1543Program names:
1544  --program-prefix=PREFIX            prepend PREFIX to installed program names
1545  --program-suffix=SUFFIX            append SUFFIX to installed program names
1546  --program-transform-name=PROGRAM   run sed PROGRAM on installed program names
1547
1548System types:
1549  --build=BUILD     configure for building on BUILD [guessed]
1550  --host=HOST       cross-compile to build programs to run on HOST [BUILD]
1551_ACEOF
1552fi
1553
1554if test -n "$ac_init_help"; then
1555  case $ac_init_help in
1556     short | recursive ) echo "Configuration of sntp 4.2.8p10:";;
1557   esac
1558  cat <<\_ACEOF
1559
1560Optional Features:
1561  --disable-option-checking  ignore unrecognized --enable/--with options
1562  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1563  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1564  --enable-silent-rules   less verbose build output (undo: "make V=1")
1565  --disable-silent-rules  verbose build output (undo: "make V=0")
1566  --enable-dependency-tracking
1567                          do not reject slow dependency extractors
1568  --disable-dependency-tracking
1569                          speeds up one-time build
1570  defaults:               + yes, - no, s system-specific
1571  --enable-debugging      + include ntpd debugging code
1572  --enable-thread-support s use threads (+ if available)
1573  --enable-c99-snprintf   s force replacement
1574  --enable-clockctl       s Use /dev/clockctl for non-root clock control
1575  --enable-linuxcaps      + Use Linux capabilities for non-root clock control
1576  --enable-solarisprivs   + Use Solaris privileges for non-root clock control
1577  --enable-shared[=PKGS]  build shared libraries [default=no]
1578  --enable-static[=PKGS]  build static libraries [default=yes]
1579  --enable-fast-install[=PKGS]
1580                          optimize for fast installation [default=yes]
1581  --disable-libtool-lock  avoid locking (might break parallel builds)
1582  --disable-nls           disable nls support in libopts
1583  --enable-local-libopts  Use the supplied libopts tearoff code
1584  --enable-libopts-install
1585                          Install libopts with client installation
1586  --disable-optional-args not wanting optional option args
1587  --enable-local-libevent Force using the supplied libevent tearoff code
1588  --enable-ipv6           s use IPv6?
1589
1590  --enable-getifaddrs     + Enable the use of getifaddrs() [[yes|no]].
1591  --enable-problem-tests  + enable tests with undiagnosed problems
1592
1593Optional Packages:
1594  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1595  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1596  --with-locfile=XXX      os-specific or "legacy"
1597  --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
1598  --with-lineeditlibs     edit,editline (readline may be specified if desired)
1599  --with-threads	  with threads [auto]
1600  --with-yielding-select  with yielding select [auto]
1601  --with-pic[=PKGS]       try to use only PIC/non-PIC objects [default=use
1602                          both]
1603  --with-aix-soname=aix|svr4|both
1604                          shared library versioning (aka "SONAME") variant to
1605                          provide on AIX, [default=aix].
1606  --with-sysroot[=DIR]    Search for dependent libraries within DIR (or the
1607                          compiler's sysroot if not specified).
1608  --without-sntp          - disable building sntp and sntp/tests
1609  --with-autoopts-config  specify the config-info script
1610  --with-regex-header     a reg expr header is specified
1611  --with-libregex         libregex installation prefix
1612  --with-libregex-cflags  libregex compile flags
1613  --with-libregex-libs    libregex link command arguments
1614  --with-crypto           + =openssl,libcrypto
1615
1616  --with-openssl-libdir   + =/something/reasonable
1617
1618  --with-openssl-incdir   + =/something/reasonable
1619
1620  --without-rpath         s Disable auto-added -R linker paths
1621
1622  --with-kame             - =/usr/local/v6
1623
1624Some influential environment variables:
1625  CC          C compiler command
1626  CFLAGS      C compiler flags
1627  LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1628              nonstandard directory <lib dir>
1629  LIBS        libraries to pass to the linker, e.g. -l<library>
1630  CPPFLAGS    (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
1631              you have headers in a nonstandard directory <include dir>
1632  CPP         C preprocessor
1633  LT_SYS_LIBRARY_PATH
1634              User-defined run-time library search path.
1635
1636Use these variables to override the choices made by `configure' or to help
1637it to find libraries and programs with nonstandard names/locations.
1638
1639Report bugs to <http://bugs.ntp.org./>.
1640sntp home page: <http://www.ntp.org./>.
1641_ACEOF
1642ac_status=$?
1643fi
1644
1645if test "$ac_init_help" = "recursive"; then
1646  # If there are subdirs, report their specific --help.
1647  for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1648    test -d "$ac_dir" ||
1649      { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1650      continue
1651    ac_builddir=.
1652
1653case "$ac_dir" in
1654.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1655*)
1656  ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1657  # A ".." for each directory in $ac_dir_suffix.
1658  ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1659  case $ac_top_builddir_sub in
1660  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1661  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1662  esac ;;
1663esac
1664ac_abs_top_builddir=$ac_pwd
1665ac_abs_builddir=$ac_pwd$ac_dir_suffix
1666# for backward compatibility:
1667ac_top_builddir=$ac_top_build_prefix
1668
1669case $srcdir in
1670  .)  # We are building in place.
1671    ac_srcdir=.
1672    ac_top_srcdir=$ac_top_builddir_sub
1673    ac_abs_top_srcdir=$ac_pwd ;;
1674  [\\/]* | ?:[\\/]* )  # Absolute name.
1675    ac_srcdir=$srcdir$ac_dir_suffix;
1676    ac_top_srcdir=$srcdir
1677    ac_abs_top_srcdir=$srcdir ;;
1678  *) # Relative name.
1679    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1680    ac_top_srcdir=$ac_top_build_prefix$srcdir
1681    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1682esac
1683ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1684
1685    cd "$ac_dir" || { ac_status=$?; continue; }
1686    # Check for guested configure.
1687    if test -f "$ac_srcdir/configure.gnu"; then
1688      echo &&
1689      $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1690    elif test -f "$ac_srcdir/configure"; then
1691      echo &&
1692      $SHELL "$ac_srcdir/configure" --help=recursive
1693    else
1694      $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1695    fi || ac_status=$?
1696    cd "$ac_pwd" || { ac_status=$?; break; }
1697  done
1698fi
1699
1700test -n "$ac_init_help" && exit $ac_status
1701if $ac_init_version; then
1702  cat <<\_ACEOF
1703sntp configure 4.2.8p10
1704generated by GNU Autoconf 2.69
1705
1706Copyright (C) 2012 Free Software Foundation, Inc.
1707This configure script is free software; the Free Software Foundation
1708gives unlimited permission to copy, distribute and modify it.
1709_ACEOF
1710  exit
1711fi
1712
1713## ------------------------ ##
1714## Autoconf initialization. ##
1715## ------------------------ ##
1716
1717# ac_fn_c_try_compile LINENO
1718# --------------------------
1719# Try to compile conftest.$ac_ext, and return whether this succeeded.
1720ac_fn_c_try_compile ()
1721{
1722  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1723  rm -f conftest.$ac_objext
1724  if { { ac_try="$ac_compile"
1725case "(($ac_try" in
1726  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1727  *) ac_try_echo=$ac_try;;
1728esac
1729eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1730$as_echo "$ac_try_echo"; } >&5
1731  (eval "$ac_compile") 2>conftest.err
1732  ac_status=$?
1733  if test -s conftest.err; then
1734    grep -v '^ *+' conftest.err >conftest.er1
1735    cat conftest.er1 >&5
1736    mv -f conftest.er1 conftest.err
1737  fi
1738  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1739  test $ac_status = 0; } && {
1740	 test -z "$ac_c_werror_flag" ||
1741	 test ! -s conftest.err
1742       } && test -s conftest.$ac_objext; then :
1743  ac_retval=0
1744else
1745  $as_echo "$as_me: failed program was:" >&5
1746sed 's/^/| /' conftest.$ac_ext >&5
1747
1748	ac_retval=1
1749fi
1750  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1751  as_fn_set_status $ac_retval
1752
1753} # ac_fn_c_try_compile
1754
1755# ac_fn_c_try_cpp LINENO
1756# ----------------------
1757# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1758ac_fn_c_try_cpp ()
1759{
1760  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1761  if { { ac_try="$ac_cpp conftest.$ac_ext"
1762case "(($ac_try" in
1763  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1764  *) ac_try_echo=$ac_try;;
1765esac
1766eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1767$as_echo "$ac_try_echo"; } >&5
1768  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1769  ac_status=$?
1770  if test -s conftest.err; then
1771    grep -v '^ *+' conftest.err >conftest.er1
1772    cat conftest.er1 >&5
1773    mv -f conftest.er1 conftest.err
1774  fi
1775  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1776  test $ac_status = 0; } > conftest.i && {
1777	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1778	 test ! -s conftest.err
1779       }; then :
1780  ac_retval=0
1781else
1782  $as_echo "$as_me: failed program was:" >&5
1783sed 's/^/| /' conftest.$ac_ext >&5
1784
1785    ac_retval=1
1786fi
1787  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1788  as_fn_set_status $ac_retval
1789
1790} # ac_fn_c_try_cpp
1791
1792# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
1793# -------------------------------------------------------
1794# Tests whether HEADER exists, giving a warning if it cannot be compiled using
1795# the include files in INCLUDES and setting the cache variable VAR
1796# accordingly.
1797ac_fn_c_check_header_mongrel ()
1798{
1799  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1800  if eval \${$3+:} false; then :
1801  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1802$as_echo_n "checking for $2... " >&6; }
1803if eval \${$3+:} false; then :
1804  $as_echo_n "(cached) " >&6
1805fi
1806eval ac_res=\$$3
1807	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1808$as_echo "$ac_res" >&6; }
1809else
1810  # Is the header compilable?
1811{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
1812$as_echo_n "checking $2 usability... " >&6; }
1813cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1814/* end confdefs.h.  */
1815$4
1816#include <$2>
1817_ACEOF
1818if ac_fn_c_try_compile "$LINENO"; then :
1819  ac_header_compiler=yes
1820else
1821  ac_header_compiler=no
1822fi
1823rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1824{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
1825$as_echo "$ac_header_compiler" >&6; }
1826
1827# Is the header present?
1828{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
1829$as_echo_n "checking $2 presence... " >&6; }
1830cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1831/* end confdefs.h.  */
1832#include <$2>
1833_ACEOF
1834if ac_fn_c_try_cpp "$LINENO"; then :
1835  ac_header_preproc=yes
1836else
1837  ac_header_preproc=no
1838fi
1839rm -f conftest.err conftest.i conftest.$ac_ext
1840{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
1841$as_echo "$ac_header_preproc" >&6; }
1842
1843# So?  What about this header?
1844case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
1845  yes:no: )
1846    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
1847$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
1848    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1849$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1850    ;;
1851  no:yes:* )
1852    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
1853$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
1854    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     check for missing prerequisite headers?" >&5
1855$as_echo "$as_me: WARNING: $2:     check for missing prerequisite headers?" >&2;}
1856    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
1857$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
1858    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&5
1859$as_echo "$as_me: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&2;}
1860    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1861$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1862( $as_echo "## ------------------------------------ ##
1863## Report this to http://bugs.ntp.org./ ##
1864## ------------------------------------ ##"
1865     ) | sed "s/^/$as_me: WARNING:     /" >&2
1866    ;;
1867esac
1868  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1869$as_echo_n "checking for $2... " >&6; }
1870if eval \${$3+:} false; then :
1871  $as_echo_n "(cached) " >&6
1872else
1873  eval "$3=\$ac_header_compiler"
1874fi
1875eval ac_res=\$$3
1876	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1877$as_echo "$ac_res" >&6; }
1878fi
1879  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1880
1881} # ac_fn_c_check_header_mongrel
1882
1883# ac_fn_c_try_run LINENO
1884# ----------------------
1885# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
1886# that executables *can* be run.
1887ac_fn_c_try_run ()
1888{
1889  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1890  if { { ac_try="$ac_link"
1891case "(($ac_try" in
1892  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1893  *) ac_try_echo=$ac_try;;
1894esac
1895eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1896$as_echo "$ac_try_echo"; } >&5
1897  (eval "$ac_link") 2>&5
1898  ac_status=$?
1899  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1900  test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1901  { { case "(($ac_try" in
1902  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1903  *) ac_try_echo=$ac_try;;
1904esac
1905eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1906$as_echo "$ac_try_echo"; } >&5
1907  (eval "$ac_try") 2>&5
1908  ac_status=$?
1909  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1910  test $ac_status = 0; }; }; then :
1911  ac_retval=0
1912else
1913  $as_echo "$as_me: program exited with status $ac_status" >&5
1914       $as_echo "$as_me: failed program was:" >&5
1915sed 's/^/| /' conftest.$ac_ext >&5
1916
1917       ac_retval=$ac_status
1918fi
1919  rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1920  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1921  as_fn_set_status $ac_retval
1922
1923} # ac_fn_c_try_run
1924
1925# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
1926# -------------------------------------------------------
1927# Tests whether HEADER exists and can be compiled using the include files in
1928# INCLUDES, setting the cache variable VAR accordingly.
1929ac_fn_c_check_header_compile ()
1930{
1931  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1932  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1933$as_echo_n "checking for $2... " >&6; }
1934if eval \${$3+:} false; then :
1935  $as_echo_n "(cached) " >&6
1936else
1937  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1938/* end confdefs.h.  */
1939$4
1940#include <$2>
1941_ACEOF
1942if ac_fn_c_try_compile "$LINENO"; then :
1943  eval "$3=yes"
1944else
1945  eval "$3=no"
1946fi
1947rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1948fi
1949eval ac_res=\$$3
1950	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1951$as_echo "$ac_res" >&6; }
1952  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1953
1954} # ac_fn_c_check_header_compile
1955
1956# ac_fn_c_try_link LINENO
1957# -----------------------
1958# Try to link conftest.$ac_ext, and return whether this succeeded.
1959ac_fn_c_try_link ()
1960{
1961  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1962  rm -f conftest.$ac_objext conftest$ac_exeext
1963  if { { ac_try="$ac_link"
1964case "(($ac_try" in
1965  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1966  *) ac_try_echo=$ac_try;;
1967esac
1968eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1969$as_echo "$ac_try_echo"; } >&5
1970  (eval "$ac_link") 2>conftest.err
1971  ac_status=$?
1972  if test -s conftest.err; then
1973    grep -v '^ *+' conftest.err >conftest.er1
1974    cat conftest.er1 >&5
1975    mv -f conftest.er1 conftest.err
1976  fi
1977  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1978  test $ac_status = 0; } && {
1979	 test -z "$ac_c_werror_flag" ||
1980	 test ! -s conftest.err
1981       } && test -s conftest$ac_exeext && {
1982	 test "$cross_compiling" = yes ||
1983	 test -x conftest$ac_exeext
1984       }; then :
1985  ac_retval=0
1986else
1987  $as_echo "$as_me: failed program was:" >&5
1988sed 's/^/| /' conftest.$ac_ext >&5
1989
1990	ac_retval=1
1991fi
1992  # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
1993  # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
1994  # interfere with the next link command; also delete a directory that is
1995  # left behind by Apple's compiler.  We do this before executing the actions.
1996  rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1997  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1998  as_fn_set_status $ac_retval
1999
2000} # ac_fn_c_try_link
2001
2002# ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2003# -------------------------------------------
2004# Tests whether TYPE exists after having included INCLUDES, setting cache
2005# variable VAR accordingly.
2006ac_fn_c_check_type ()
2007{
2008  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2009  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2010$as_echo_n "checking for $2... " >&6; }
2011if eval \${$3+:} false; then :
2012  $as_echo_n "(cached) " >&6
2013else
2014  eval "$3=no"
2015  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2016/* end confdefs.h.  */
2017$4
2018int
2019main ()
2020{
2021if (sizeof ($2))
2022	 return 0;
2023  ;
2024  return 0;
2025}
2026_ACEOF
2027if ac_fn_c_try_compile "$LINENO"; then :
2028  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2029/* end confdefs.h.  */
2030$4
2031int
2032main ()
2033{
2034if (sizeof (($2)))
2035	    return 0;
2036  ;
2037  return 0;
2038}
2039_ACEOF
2040if ac_fn_c_try_compile "$LINENO"; then :
2041
2042else
2043  eval "$3=yes"
2044fi
2045rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2046fi
2047rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2048fi
2049eval ac_res=\$$3
2050	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2051$as_echo "$ac_res" >&6; }
2052  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2053
2054} # ac_fn_c_check_type
2055
2056# ac_fn_c_check_func LINENO FUNC VAR
2057# ----------------------------------
2058# Tests whether FUNC exists, setting the cache variable VAR accordingly
2059ac_fn_c_check_func ()
2060{
2061  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2062  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2063$as_echo_n "checking for $2... " >&6; }
2064if eval \${$3+:} false; then :
2065  $as_echo_n "(cached) " >&6
2066else
2067  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2068/* end confdefs.h.  */
2069/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2070   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
2071#define $2 innocuous_$2
2072
2073/* System header to define __stub macros and hopefully few prototypes,
2074    which can conflict with char $2 (); below.
2075    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2076    <limits.h> exists even on freestanding compilers.  */
2077
2078#ifdef __STDC__
2079# include <limits.h>
2080#else
2081# include <assert.h>
2082#endif
2083
2084#undef $2
2085
2086/* Override any GCC internal prototype to avoid an error.
2087   Use char because int might match the return type of a GCC
2088   builtin and then its argument prototype would still apply.  */
2089#ifdef __cplusplus
2090extern "C"
2091#endif
2092char $2 ();
2093/* The GNU C library defines this for functions which it implements
2094    to always fail with ENOSYS.  Some functions are actually named
2095    something starting with __ and the normal name is an alias.  */
2096#if defined __stub_$2 || defined __stub___$2
2097choke me
2098#endif
2099
2100int
2101main ()
2102{
2103return $2 ();
2104  ;
2105  return 0;
2106}
2107_ACEOF
2108if ac_fn_c_try_link "$LINENO"; then :
2109  eval "$3=yes"
2110else
2111  eval "$3=no"
2112fi
2113rm -f core conftest.err conftest.$ac_objext \
2114    conftest$ac_exeext conftest.$ac_ext
2115fi
2116eval ac_res=\$$3
2117	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2118$as_echo "$ac_res" >&6; }
2119  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2120
2121} # ac_fn_c_check_func
2122
2123# ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
2124# ---------------------------------------------
2125# Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
2126# accordingly.
2127ac_fn_c_check_decl ()
2128{
2129  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2130  as_decl_name=`echo $2|sed 's/ *(.*//'`
2131  as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
2132  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
2133$as_echo_n "checking whether $as_decl_name is declared... " >&6; }
2134if eval \${$3+:} false; then :
2135  $as_echo_n "(cached) " >&6
2136else
2137  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2138/* end confdefs.h.  */
2139$4
2140int
2141main ()
2142{
2143#ifndef $as_decl_name
2144#ifdef __cplusplus
2145  (void) $as_decl_use;
2146#else
2147  (void) $as_decl_name;
2148#endif
2149#endif
2150
2151  ;
2152  return 0;
2153}
2154_ACEOF
2155if ac_fn_c_try_compile "$LINENO"; then :
2156  eval "$3=yes"
2157else
2158  eval "$3=no"
2159fi
2160rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2161fi
2162eval ac_res=\$$3
2163	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2164$as_echo "$ac_res" >&6; }
2165  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2166
2167} # ac_fn_c_check_decl
2168
2169# ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2170# --------------------------------------------
2171# Tries to find the compile-time value of EXPR in a program that includes
2172# INCLUDES, setting VAR accordingly. Returns whether the value could be
2173# computed
2174ac_fn_c_compute_int ()
2175{
2176  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2177  if test "$cross_compiling" = yes; then
2178    # Depending upon the size, compute the lo and hi bounds.
2179cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2180/* end confdefs.h.  */
2181$4
2182int
2183main ()
2184{
2185static int test_array [1 - 2 * !(($2) >= 0)];
2186test_array [0] = 0;
2187return test_array [0];
2188
2189  ;
2190  return 0;
2191}
2192_ACEOF
2193if ac_fn_c_try_compile "$LINENO"; then :
2194  ac_lo=0 ac_mid=0
2195  while :; do
2196    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2197/* end confdefs.h.  */
2198$4
2199int
2200main ()
2201{
2202static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2203test_array [0] = 0;
2204return test_array [0];
2205
2206  ;
2207  return 0;
2208}
2209_ACEOF
2210if ac_fn_c_try_compile "$LINENO"; then :
2211  ac_hi=$ac_mid; break
2212else
2213  as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2214			if test $ac_lo -le $ac_mid; then
2215			  ac_lo= ac_hi=
2216			  break
2217			fi
2218			as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2219fi
2220rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2221  done
2222else
2223  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2224/* end confdefs.h.  */
2225$4
2226int
2227main ()
2228{
2229static int test_array [1 - 2 * !(($2) < 0)];
2230test_array [0] = 0;
2231return test_array [0];
2232
2233  ;
2234  return 0;
2235}
2236_ACEOF
2237if ac_fn_c_try_compile "$LINENO"; then :
2238  ac_hi=-1 ac_mid=-1
2239  while :; do
2240    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2241/* end confdefs.h.  */
2242$4
2243int
2244main ()
2245{
2246static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2247test_array [0] = 0;
2248return test_array [0];
2249
2250  ;
2251  return 0;
2252}
2253_ACEOF
2254if ac_fn_c_try_compile "$LINENO"; then :
2255  ac_lo=$ac_mid; break
2256else
2257  as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2258			if test $ac_mid -le $ac_hi; then
2259			  ac_lo= ac_hi=
2260			  break
2261			fi
2262			as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2263fi
2264rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2265  done
2266else
2267  ac_lo= ac_hi=
2268fi
2269rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2270fi
2271rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2272# Binary search between lo and hi bounds.
2273while test "x$ac_lo" != "x$ac_hi"; do
2274  as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2275  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2276/* end confdefs.h.  */
2277$4
2278int
2279main ()
2280{
2281static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2282test_array [0] = 0;
2283return test_array [0];
2284
2285  ;
2286  return 0;
2287}
2288_ACEOF
2289if ac_fn_c_try_compile "$LINENO"; then :
2290  ac_hi=$ac_mid
2291else
2292  as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2293fi
2294rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2295done
2296case $ac_lo in #((
2297?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2298'') ac_retval=1 ;;
2299esac
2300  else
2301    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2302/* end confdefs.h.  */
2303$4
2304static long int longval () { return $2; }
2305static unsigned long int ulongval () { return $2; }
2306#include <stdio.h>
2307#include <stdlib.h>
2308int
2309main ()
2310{
2311
2312  FILE *f = fopen ("conftest.val", "w");
2313  if (! f)
2314    return 1;
2315  if (($2) < 0)
2316    {
2317      long int i = longval ();
2318      if (i != ($2))
2319	return 1;
2320      fprintf (f, "%ld", i);
2321    }
2322  else
2323    {
2324      unsigned long int i = ulongval ();
2325      if (i != ($2))
2326	return 1;
2327      fprintf (f, "%lu", i);
2328    }
2329  /* Do not output a trailing newline, as this causes \r\n confusion
2330     on some platforms.  */
2331  return ferror (f) || fclose (f) != 0;
2332
2333  ;
2334  return 0;
2335}
2336_ACEOF
2337if ac_fn_c_try_run "$LINENO"; then :
2338  echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2339else
2340  ac_retval=1
2341fi
2342rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2343  conftest.$ac_objext conftest.beam conftest.$ac_ext
2344rm -f conftest.val
2345
2346  fi
2347  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2348  as_fn_set_status $ac_retval
2349
2350} # ac_fn_c_compute_int
2351
2352# ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2353# ----------------------------------------------------
2354# Tries to find if the field MEMBER exists in type AGGR, after including
2355# INCLUDES, setting cache variable VAR accordingly.
2356ac_fn_c_check_member ()
2357{
2358  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2359  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2360$as_echo_n "checking for $2.$3... " >&6; }
2361if eval \${$4+:} false; then :
2362  $as_echo_n "(cached) " >&6
2363else
2364  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2365/* end confdefs.h.  */
2366$5
2367int
2368main ()
2369{
2370static $2 ac_aggr;
2371if (ac_aggr.$3)
2372return 0;
2373  ;
2374  return 0;
2375}
2376_ACEOF
2377if ac_fn_c_try_compile "$LINENO"; then :
2378  eval "$4=yes"
2379else
2380  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2381/* end confdefs.h.  */
2382$5
2383int
2384main ()
2385{
2386static $2 ac_aggr;
2387if (sizeof ac_aggr.$3)
2388return 0;
2389  ;
2390  return 0;
2391}
2392_ACEOF
2393if ac_fn_c_try_compile "$LINENO"; then :
2394  eval "$4=yes"
2395else
2396  eval "$4=no"
2397fi
2398rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2399fi
2400rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2401fi
2402eval ac_res=\$$4
2403	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2404$as_echo "$ac_res" >&6; }
2405  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2406
2407} # ac_fn_c_check_member
2408cat >config.log <<_ACEOF
2409This file contains any messages produced by compilers while
2410running configure, to aid debugging if configure makes a mistake.
2411
2412It was created by sntp $as_me 4.2.8p10, which was
2413generated by GNU Autoconf 2.69.  Invocation command line was
2414
2415  $ $0 $@
2416
2417_ACEOF
2418exec 5>>config.log
2419{
2420cat <<_ASUNAME
2421## --------- ##
2422## Platform. ##
2423## --------- ##
2424
2425hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2426uname -m = `(uname -m) 2>/dev/null || echo unknown`
2427uname -r = `(uname -r) 2>/dev/null || echo unknown`
2428uname -s = `(uname -s) 2>/dev/null || echo unknown`
2429uname -v = `(uname -v) 2>/dev/null || echo unknown`
2430
2431/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2432/bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
2433
2434/bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
2435/usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
2436/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2437/usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
2438/bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
2439/usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
2440/bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
2441
2442_ASUNAME
2443
2444as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2445for as_dir in $PATH
2446do
2447  IFS=$as_save_IFS
2448  test -z "$as_dir" && as_dir=.
2449    $as_echo "PATH: $as_dir"
2450  done
2451IFS=$as_save_IFS
2452
2453} >&5
2454
2455cat >&5 <<_ACEOF
2456
2457
2458## ----------- ##
2459## Core tests. ##
2460## ----------- ##
2461
2462_ACEOF
2463
2464
2465# Keep a trace of the command line.
2466# Strip out --no-create and --no-recursion so they do not pile up.
2467# Strip out --silent because we don't want to record it for future runs.
2468# Also quote any args containing shell meta-characters.
2469# Make two passes to allow for proper duplicate-argument suppression.
2470ac_configure_args=
2471ac_configure_args0=
2472ac_configure_args1=
2473ac_must_keep_next=false
2474for ac_pass in 1 2
2475do
2476  for ac_arg
2477  do
2478    case $ac_arg in
2479    -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2480    -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2481    | -silent | --silent | --silen | --sile | --sil)
2482      continue ;;
2483    *\'*)
2484      ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2485    esac
2486    case $ac_pass in
2487    1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2488    2)
2489      as_fn_append ac_configure_args1 " '$ac_arg'"
2490      if test $ac_must_keep_next = true; then
2491	ac_must_keep_next=false # Got value, back to normal.
2492      else
2493	case $ac_arg in
2494	  *=* | --config-cache | -C | -disable-* | --disable-* \
2495	  | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2496	  | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2497	  | -with-* | --with-* | -without-* | --without-* | --x)
2498	    case "$ac_configure_args0 " in
2499	      "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2500	    esac
2501	    ;;
2502	  -* ) ac_must_keep_next=true ;;
2503	esac
2504      fi
2505      as_fn_append ac_configure_args " '$ac_arg'"
2506      ;;
2507    esac
2508  done
2509done
2510{ ac_configure_args0=; unset ac_configure_args0;}
2511{ ac_configure_args1=; unset ac_configure_args1;}
2512
2513# When interrupted or exit'd, cleanup temporary files, and complete
2514# config.log.  We remove comments because anyway the quotes in there
2515# would cause problems or look ugly.
2516# WARNING: Use '\'' to represent an apostrophe within the trap.
2517# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2518trap 'exit_status=$?
2519  # Save into config.log some information that might help in debugging.
2520  {
2521    echo
2522
2523    $as_echo "## ---------------- ##
2524## Cache variables. ##
2525## ---------------- ##"
2526    echo
2527    # The following way of writing the cache mishandles newlines in values,
2528(
2529  for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2530    eval ac_val=\$$ac_var
2531    case $ac_val in #(
2532    *${as_nl}*)
2533      case $ac_var in #(
2534      *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2535$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2536      esac
2537      case $ac_var in #(
2538      _ | IFS | as_nl) ;; #(
2539      BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2540      *) { eval $ac_var=; unset $ac_var;} ;;
2541      esac ;;
2542    esac
2543  done
2544  (set) 2>&1 |
2545    case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2546    *${as_nl}ac_space=\ *)
2547      sed -n \
2548	"s/'\''/'\''\\\\'\'''\''/g;
2549	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2550      ;; #(
2551    *)
2552      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2553      ;;
2554    esac |
2555    sort
2556)
2557    echo
2558
2559    $as_echo "## ----------------- ##
2560## Output variables. ##
2561## ----------------- ##"
2562    echo
2563    for ac_var in $ac_subst_vars
2564    do
2565      eval ac_val=\$$ac_var
2566      case $ac_val in
2567      *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2568      esac
2569      $as_echo "$ac_var='\''$ac_val'\''"
2570    done | sort
2571    echo
2572
2573    if test -n "$ac_subst_files"; then
2574      $as_echo "## ------------------- ##
2575## File substitutions. ##
2576## ------------------- ##"
2577      echo
2578      for ac_var in $ac_subst_files
2579      do
2580	eval ac_val=\$$ac_var
2581	case $ac_val in
2582	*\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2583	esac
2584	$as_echo "$ac_var='\''$ac_val'\''"
2585      done | sort
2586      echo
2587    fi
2588
2589    if test -s confdefs.h; then
2590      $as_echo "## ----------- ##
2591## confdefs.h. ##
2592## ----------- ##"
2593      echo
2594      cat confdefs.h
2595      echo
2596    fi
2597    test "$ac_signal" != 0 &&
2598      $as_echo "$as_me: caught signal $ac_signal"
2599    $as_echo "$as_me: exit $exit_status"
2600  } >&5
2601  rm -f core *.core core.conftest.* &&
2602    rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2603    exit $exit_status
2604' 0
2605for ac_signal in 1 2 13 15; do
2606  trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2607done
2608ac_signal=0
2609
2610# confdefs.h avoids OS command line length limits that DEFS can exceed.
2611rm -f -r conftest* confdefs.h
2612
2613$as_echo "/* confdefs.h */" > confdefs.h
2614
2615# Predefined preprocessor variables.
2616
2617cat >>confdefs.h <<_ACEOF
2618#define PACKAGE_NAME "$PACKAGE_NAME"
2619_ACEOF
2620
2621cat >>confdefs.h <<_ACEOF
2622#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2623_ACEOF
2624
2625cat >>confdefs.h <<_ACEOF
2626#define PACKAGE_VERSION "$PACKAGE_VERSION"
2627_ACEOF
2628
2629cat >>confdefs.h <<_ACEOF
2630#define PACKAGE_STRING "$PACKAGE_STRING"
2631_ACEOF
2632
2633cat >>confdefs.h <<_ACEOF
2634#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2635_ACEOF
2636
2637cat >>confdefs.h <<_ACEOF
2638#define PACKAGE_URL "$PACKAGE_URL"
2639_ACEOF
2640
2641
2642# Let the site file select an alternate cache file if it wants to.
2643# Prefer an explicitly selected file to automatically selected ones.
2644ac_site_file1=NONE
2645ac_site_file2=NONE
2646if test -n "$CONFIG_SITE"; then
2647  # We do not want a PATH search for config.site.
2648  case $CONFIG_SITE in #((
2649    -*)  ac_site_file1=./$CONFIG_SITE;;
2650    */*) ac_site_file1=$CONFIG_SITE;;
2651    *)   ac_site_file1=./$CONFIG_SITE;;
2652  esac
2653elif test "x$prefix" != xNONE; then
2654  ac_site_file1=$prefix/share/config.site
2655  ac_site_file2=$prefix/etc/config.site
2656else
2657  ac_site_file1=$ac_default_prefix/share/config.site
2658  ac_site_file2=$ac_default_prefix/etc/config.site
2659fi
2660for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2661do
2662  test "x$ac_site_file" = xNONE && continue
2663  if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
2664    { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2665$as_echo "$as_me: loading site script $ac_site_file" >&6;}
2666    sed 's/^/| /' "$ac_site_file" >&5
2667    . "$ac_site_file" \
2668      || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2669$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2670as_fn_error $? "failed to load site script $ac_site_file
2671See \`config.log' for more details" "$LINENO" 5; }
2672  fi
2673done
2674
2675if test -r "$cache_file"; then
2676  # Some versions of bash will fail to source /dev/null (special files
2677  # actually), so we avoid doing that.  DJGPP emulates it as a regular file.
2678  if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2679    { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2680$as_echo "$as_me: loading cache $cache_file" >&6;}
2681    case $cache_file in
2682      [\\/]* | ?:[\\/]* ) . "$cache_file";;
2683      *)                      . "./$cache_file";;
2684    esac
2685  fi
2686else
2687  { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2688$as_echo "$as_me: creating cache $cache_file" >&6;}
2689  >$cache_file
2690fi
2691
2692as_fn_append ac_header_list " stdarg.h"
2693# Check that the precious variables saved in the cache have kept the same
2694# value.
2695ac_cache_corrupted=false
2696for ac_var in $ac_precious_vars; do
2697  eval ac_old_set=\$ac_cv_env_${ac_var}_set
2698  eval ac_new_set=\$ac_env_${ac_var}_set
2699  eval ac_old_val=\$ac_cv_env_${ac_var}_value
2700  eval ac_new_val=\$ac_env_${ac_var}_value
2701  case $ac_old_set,$ac_new_set in
2702    set,)
2703      { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2704$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2705      ac_cache_corrupted=: ;;
2706    ,set)
2707      { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2708$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2709      ac_cache_corrupted=: ;;
2710    ,);;
2711    *)
2712      if test "x$ac_old_val" != "x$ac_new_val"; then
2713	# differences in whitespace do not lead to failure.
2714	ac_old_val_w=`echo x $ac_old_val`
2715	ac_new_val_w=`echo x $ac_new_val`
2716	if test "$ac_old_val_w" != "$ac_new_val_w"; then
2717	  { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2718$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2719	  ac_cache_corrupted=:
2720	else
2721	  { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2722$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2723	  eval $ac_var=\$ac_old_val
2724	fi
2725	{ $as_echo "$as_me:${as_lineno-$LINENO}:   former value:  \`$ac_old_val'" >&5
2726$as_echo "$as_me:   former value:  \`$ac_old_val'" >&2;}
2727	{ $as_echo "$as_me:${as_lineno-$LINENO}:   current value: \`$ac_new_val'" >&5
2728$as_echo "$as_me:   current value: \`$ac_new_val'" >&2;}
2729      fi;;
2730  esac
2731  # Pass precious variables to config.status.
2732  if test "$ac_new_set" = set; then
2733    case $ac_new_val in
2734    *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2735    *) ac_arg=$ac_var=$ac_new_val ;;
2736    esac
2737    case " $ac_configure_args " in
2738      *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
2739      *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2740    esac
2741  fi
2742done
2743if $ac_cache_corrupted; then
2744  { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2745$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2746  { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2747$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2748  as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
2749fi
2750## -------------------- ##
2751## Main body of script. ##
2752## -------------------- ##
2753
2754ac_ext=c
2755ac_cpp='$CPP $CPPFLAGS'
2756ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2757ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2758ac_compiler_gnu=$ac_cv_c_compiler_gnu
2759
2760
2761
2762ac_aux_dir=
2763for ac_dir in libevent/build-aux "$srcdir"/libevent/build-aux; do
2764  if test -f "$ac_dir/install-sh"; then
2765    ac_aux_dir=$ac_dir
2766    ac_install_sh="$ac_aux_dir/install-sh -c"
2767    break
2768  elif test -f "$ac_dir/install.sh"; then
2769    ac_aux_dir=$ac_dir
2770    ac_install_sh="$ac_aux_dir/install.sh -c"
2771    break
2772  elif test -f "$ac_dir/shtool"; then
2773    ac_aux_dir=$ac_dir
2774    ac_install_sh="$ac_aux_dir/shtool install -c"
2775    break
2776  fi
2777done
2778if test -z "$ac_aux_dir"; then
2779  as_fn_error $? "cannot find install-sh, install.sh, or shtool in libevent/build-aux \"$srcdir\"/libevent/build-aux" "$LINENO" 5
2780fi
2781
2782# These three variables are undocumented and unsupported,
2783# and are intended to be withdrawn in a future Autoconf release.
2784# They can cause serious problems if a builder's source tree is in a directory
2785# whose full name contains unusual characters.
2786ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
2787ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
2788ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
2789
2790
2791ac_ext=c
2792ac_cpp='$CPP $CPPFLAGS'
2793ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2794ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2795ac_compiler_gnu=$ac_cv_c_compiler_gnu
2796
2797
2798# Bump sntp_configure_cache_version for each change to configure.ac or
2799# .m4 files which invalidates cached values from previous configure
2800# runs.
2801#
2802# If the change affects cache variables used only by the main NTP
2803# configure.ac, then only its version number should be bumped, while
2804# the subdir configure.ac version numbers should be unchanged.  The
2805# same is true for a test/variable that is used only by one subdir
2806# being changed incompatibly; only that subdir's cache version needs
2807# bumping.
2808#
2809# If a change affects variables shared by all NTP configure scripts,
2810# please bump the version numbers of each.  If you are not sure, the
2811# safe choice is to bump all on any cache-invalidating change.
2812#
2813# In order to avoid the risk of version stamp collision between -stable
2814# and -dev branches, do not simply increment the version, instead use
2815# the date YYYYMMDD optionally with -HHMM if there is more than one
2816# bump in a day.
2817
2818sntp_configure_cache_version=20120806
2819
2820# When the version of config.cache and configure do not
2821# match, NTP_CACHEVERSION will flush the cache.
2822
2823
2824
2825    ntp_cache_flush=1
2826
2827    case "$ntp_cv_sntp_cache_version" in
2828     $sntp_configure_cache_version)
2829	# same version, good
2830	ntp_cache_flush=0
2831	;;
2832     '')
2833	# No cache, predates ntp_cv_sntp_cache_version, or is empty.
2834	case "$cache_file" in
2835	 /dev/null)
2836	    ntp_cache_flush=0
2837	    ;;
2838	 *)
2839	    case "$NTP_CACHEVERSION_PARENT" in
2840	     '')
2841		# Do not clear the cache immediately after it is created
2842		# empty as it is noisy.  Differentiate a newly-created
2843		# config.cache from one predating the cache version
2844		# mechanism by looking for the first cached variable set
2845		# by Autoconf
2846		case "$ac_cv_path_install" in
2847		 '')
2848		    # empty config.cache file
2849		    ntp_cache_flush=0
2850		esac
2851		;;
2852	     *)
2853		# Parent configure just created cache from empty,
2854		# flushing would be counterproductive.
2855		ntp_cache_flush=0;
2856		;;
2857	    esac
2858	esac
2859	;;
2860     *)
2861	# configure cache version mismatches config.cache version
2862	;;
2863    esac
2864
2865    case "$ntp_cache_flush" in
2866     1)
2867	c_version="${ntp_cv_sntp_cache_version:-(no version found)}"
2868
2869	# Do we flush all variables or exclude others' version stamps?
2870
2871	case "$NTP_CACHEVERSION_PARENT" in
2872	 '')
2873	    # Clear all *_cv_* variables including our child subdirs'
2874	    # ntp_cv_*_cache_version variables.  This prevents subdir
2875	    # configure scripts from noticing a version mismatch just
2876	    # after the top configure in the invocation cleared and
2877	    # recreated the cache.
2878
2879	    c_varname_list=`set |
2880			    sed -n -e 's/=.*$//' \
2881				   -e '/_cv_/p'
2882			   `
2883	    ;;
2884	 *)
2885	    # This is not the top configure this particular invocation.
2886	    # Clear all *_cv_* variables sparing the version stamps
2887	    # of other configure scripts, so we don't trigger
2888	    # useless repeated clearings.
2889
2890	    c_varname_list=`set |
2891			    sed -n -e 's/=.*$//' \
2892				   -e '/ntp_cv_.*_cache_version/d' \
2893				   -e '/_cv_/p'
2894			   `
2895	esac
2896
2897	for c_varname in $c_varname_list
2898	do
2899	    	    	    	    	    	    { eval $c_varname=; unset $c_varname; }
2900	done
2901
2902	{ $as_echo "$as_me:${as_lineno-$LINENO}: $cache_file saved by another version, ignored." >&5
2903$as_echo "$as_me: $cache_file saved by another version, ignored." >&6;}
2904	{ $as_echo "$as_me:${as_lineno-$LINENO}: configure script cache version: $sntp_configure_cache_version" >&5
2905$as_echo "$as_me: configure script cache version: $sntp_configure_cache_version" >&6;}
2906	{ $as_echo "$as_me:${as_lineno-$LINENO}: $cache_file version: $c_version" >&5
2907$as_echo "$as_me: $cache_file version: $c_version" >&6;}
2908	{ c_varname=; unset c_varname;}
2909	{ c_varname_list=; unset c_varname_list;}
2910	{ c_version=; unset c_version;}
2911    esac
2912
2913    { ntp_cache_flush=; unset ntp_cache_flush;}
2914
2915    # save configure version in config.cache for next time
2916    ntp_cv_sntp_cache_version="$sntp_configure_cache_version"
2917
2918    # let any subdir configure.ac NTP_CACHEVERSION invocations
2919    # know they are not the top level.
2920    NTP_CACHEVERSION_PARENT='sntp' ; export NTP_CACHEVERSION_PARENT
2921
2922
2923am__api_version='1.15'
2924
2925# Find a good install program.  We prefer a C program (faster),
2926# so one script is as good as another.  But avoid the broken or
2927# incompatible versions:
2928# SysV /etc/install, /usr/sbin/install
2929# SunOS /usr/etc/install
2930# IRIX /sbin/install
2931# AIX /bin/install
2932# AmigaOS /C/install, which installs bootblocks on floppy discs
2933# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
2934# AFS /usr/afsws/bin/install, which mishandles nonexistent args
2935# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
2936# OS/2's system install, which has a completely different semantic
2937# ./install, which can be erroneously created by make from ./install.sh.
2938# Reject install programs that cannot install multiple files.
2939{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
2940$as_echo_n "checking for a BSD-compatible install... " >&6; }
2941if test -z "$INSTALL"; then
2942if ${ac_cv_path_install+:} false; then :
2943  $as_echo_n "(cached) " >&6
2944else
2945  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2946for as_dir in $PATH
2947do
2948  IFS=$as_save_IFS
2949  test -z "$as_dir" && as_dir=.
2950    # Account for people who put trailing slashes in PATH elements.
2951case $as_dir/ in #((
2952  ./ | .// | /[cC]/* | \
2953  /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
2954  ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
2955  /usr/ucb/* ) ;;
2956  *)
2957    # OSF1 and SCO ODT 3.0 have their own names for install.
2958    # Don't use installbsd from OSF since it installs stuff as root
2959    # by default.
2960    for ac_prog in ginstall scoinst install; do
2961      for ac_exec_ext in '' $ac_executable_extensions; do
2962	if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
2963	  if test $ac_prog = install &&
2964	    grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
2965	    # AIX install.  It has an incompatible calling convention.
2966	    :
2967	  elif test $ac_prog = install &&
2968	    grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
2969	    # program-specific install script used by HP pwplus--don't use.
2970	    :
2971	  else
2972	    rm -rf conftest.one conftest.two conftest.dir
2973	    echo one > conftest.one
2974	    echo two > conftest.two
2975	    mkdir conftest.dir
2976	    if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
2977	      test -s conftest.one && test -s conftest.two &&
2978	      test -s conftest.dir/conftest.one &&
2979	      test -s conftest.dir/conftest.two
2980	    then
2981	      ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
2982	      break 3
2983	    fi
2984	  fi
2985	fi
2986      done
2987    done
2988    ;;
2989esac
2990
2991  done
2992IFS=$as_save_IFS
2993
2994rm -rf conftest.one conftest.two conftest.dir
2995
2996fi
2997  if test "${ac_cv_path_install+set}" = set; then
2998    INSTALL=$ac_cv_path_install
2999  else
3000    # As a last resort, use the slow shell script.  Don't cache a
3001    # value for INSTALL within a source directory, because that will
3002    # break other packages using the cache if that directory is
3003    # removed, or if the value is a relative name.
3004    INSTALL=$ac_install_sh
3005  fi
3006fi
3007{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
3008$as_echo "$INSTALL" >&6; }
3009
3010# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3011# It thinks the first close brace ends the variable substitution.
3012test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3013
3014test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3015
3016test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3017
3018{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
3019$as_echo_n "checking whether build environment is sane... " >&6; }
3020# Reject unsafe characters in $srcdir or the absolute working directory
3021# name.  Accept space and tab only in the latter.
3022am_lf='
3023'
3024case `pwd` in
3025  *[\\\"\#\$\&\'\`$am_lf]*)
3026    as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;;
3027esac
3028case $srcdir in
3029  *[\\\"\#\$\&\'\`$am_lf\ \	]*)
3030    as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;;
3031esac
3032
3033# Do 'set' in a subshell so we don't clobber the current shell's
3034# arguments.  Must try -L first in case configure is actually a
3035# symlink; some systems play weird games with the mod time of symlinks
3036# (eg FreeBSD returns the mod time of the symlink's containing
3037# directory).
3038if (
3039   am_has_slept=no
3040   for am_try in 1 2; do
3041     echo "timestamp, slept: $am_has_slept" > conftest.file
3042     set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
3043     if test "$*" = "X"; then
3044	# -L didn't work.
3045	set X `ls -t "$srcdir/configure" conftest.file`
3046     fi
3047     if test "$*" != "X $srcdir/configure conftest.file" \
3048	&& test "$*" != "X conftest.file $srcdir/configure"; then
3049
3050	# If neither matched, then we have a broken ls.  This can happen
3051	# if, for instance, CONFIG_SHELL is bash and it inherits a
3052	# broken ls alias from the environment.  This has actually
3053	# happened.  Such a system could not be considered "sane".
3054	as_fn_error $? "ls -t appears to fail.  Make sure there is not a broken
3055  alias in your environment" "$LINENO" 5
3056     fi
3057     if test "$2" = conftest.file || test $am_try -eq 2; then
3058       break
3059     fi
3060     # Just in case.
3061     sleep 1
3062     am_has_slept=yes
3063   done
3064   test "$2" = conftest.file
3065   )
3066then
3067   # Ok.
3068   :
3069else
3070   as_fn_error $? "newly created file is older than distributed files!
3071Check your system clock" "$LINENO" 5
3072fi
3073{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3074$as_echo "yes" >&6; }
3075# If we didn't sleep, we still need to ensure time stamps of config.status and
3076# generated files are strictly newer.
3077am_sleep_pid=
3078if grep 'slept: no' conftest.file >/dev/null 2>&1; then
3079  ( sleep 1 ) &
3080  am_sleep_pid=$!
3081fi
3082
3083rm -f conftest.file
3084
3085test "$program_prefix" != NONE &&
3086  program_transform_name="s&^&$program_prefix&;$program_transform_name"
3087# Use a double $ so make ignores it.
3088test "$program_suffix" != NONE &&
3089  program_transform_name="s&\$&$program_suffix&;$program_transform_name"
3090# Double any \ or $.
3091# By default was `s,x,x', remove it if useless.
3092ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
3093program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
3094
3095# Expand $ac_aux_dir to an absolute path.
3096am_aux_dir=`cd "$ac_aux_dir" && pwd`
3097
3098if test x"${MISSING+set}" != xset; then
3099  case $am_aux_dir in
3100  *\ * | *\	*)
3101    MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
3102  *)
3103    MISSING="\${SHELL} $am_aux_dir/missing" ;;
3104  esac
3105fi
3106# Use eval to expand $SHELL
3107if eval "$MISSING --is-lightweight"; then
3108  am_missing_run="$MISSING "
3109else
3110  am_missing_run=
3111  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5
3112$as_echo "$as_me: WARNING: 'missing' script is too old or missing" >&2;}
3113fi
3114
3115if test x"${install_sh+set}" != xset; then
3116  case $am_aux_dir in
3117  *\ * | *\	*)
3118    install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
3119  *)
3120    install_sh="\${SHELL} $am_aux_dir/install-sh"
3121  esac
3122fi
3123
3124# Installed binaries are usually stripped using 'strip' when the user
3125# run "make install-strip".  However 'strip' might not be the right
3126# tool to use in cross-compilation environments, therefore Automake
3127# will honor the 'STRIP' environment variable to overrule this program.
3128if test "$cross_compiling" != no; then
3129  if test -n "$ac_tool_prefix"; then
3130  # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
3131set dummy ${ac_tool_prefix}strip; ac_word=$2
3132{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3133$as_echo_n "checking for $ac_word... " >&6; }
3134if ${ac_cv_prog_STRIP+:} false; then :
3135  $as_echo_n "(cached) " >&6
3136else
3137  if test -n "$STRIP"; then
3138  ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
3139else
3140as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3141for as_dir in $PATH
3142do
3143  IFS=$as_save_IFS
3144  test -z "$as_dir" && as_dir=.
3145    for ac_exec_ext in '' $ac_executable_extensions; do
3146  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3147    ac_cv_prog_STRIP="${ac_tool_prefix}strip"
3148    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3149    break 2
3150  fi
3151done
3152  done
3153IFS=$as_save_IFS
3154
3155fi
3156fi
3157STRIP=$ac_cv_prog_STRIP
3158if test -n "$STRIP"; then
3159  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
3160$as_echo "$STRIP" >&6; }
3161else
3162  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3163$as_echo "no" >&6; }
3164fi
3165
3166
3167fi
3168if test -z "$ac_cv_prog_STRIP"; then
3169  ac_ct_STRIP=$STRIP
3170  # Extract the first word of "strip", so it can be a program name with args.
3171set dummy strip; ac_word=$2
3172{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3173$as_echo_n "checking for $ac_word... " >&6; }
3174if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
3175  $as_echo_n "(cached) " >&6
3176else
3177  if test -n "$ac_ct_STRIP"; then
3178  ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
3179else
3180as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3181for as_dir in $PATH
3182do
3183  IFS=$as_save_IFS
3184  test -z "$as_dir" && as_dir=.
3185    for ac_exec_ext in '' $ac_executable_extensions; do
3186  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3187    ac_cv_prog_ac_ct_STRIP="strip"
3188    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3189    break 2
3190  fi
3191done
3192  done
3193IFS=$as_save_IFS
3194
3195fi
3196fi
3197ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
3198if test -n "$ac_ct_STRIP"; then
3199  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
3200$as_echo "$ac_ct_STRIP" >&6; }
3201else
3202  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3203$as_echo "no" >&6; }
3204fi
3205
3206  if test "x$ac_ct_STRIP" = x; then
3207    STRIP=":"
3208  else
3209    case $cross_compiling:$ac_tool_warned in
3210yes:)
3211{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3212$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3213ac_tool_warned=yes ;;
3214esac
3215    STRIP=$ac_ct_STRIP
3216  fi
3217else
3218  STRIP="$ac_cv_prog_STRIP"
3219fi
3220
3221fi
3222INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
3223
3224{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
3225$as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
3226if test -z "$MKDIR_P"; then
3227  if ${ac_cv_path_mkdir+:} false; then :
3228  $as_echo_n "(cached) " >&6
3229else
3230  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3231for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
3232do
3233  IFS=$as_save_IFS
3234  test -z "$as_dir" && as_dir=.
3235    for ac_prog in mkdir gmkdir; do
3236	 for ac_exec_ext in '' $ac_executable_extensions; do
3237	   as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue
3238	   case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
3239	     'mkdir (GNU coreutils) '* | \
3240	     'mkdir (coreutils) '* | \
3241	     'mkdir (fileutils) '4.1*)
3242	       ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
3243	       break 3;;
3244	   esac
3245	 done
3246       done
3247  done
3248IFS=$as_save_IFS
3249
3250fi
3251
3252  test -d ./--version && rmdir ./--version
3253  if test "${ac_cv_path_mkdir+set}" = set; then
3254    MKDIR_P="$ac_cv_path_mkdir -p"
3255  else
3256    # As a last resort, use the slow shell script.  Don't cache a
3257    # value for MKDIR_P within a source directory, because that will
3258    # break other packages using the cache if that directory is
3259    # removed, or if the value is a relative name.
3260    MKDIR_P="$ac_install_sh -d"
3261  fi
3262fi
3263{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
3264$as_echo "$MKDIR_P" >&6; }
3265
3266for ac_prog in gawk mawk nawk awk
3267do
3268  # Extract the first word of "$ac_prog", so it can be a program name with args.
3269set dummy $ac_prog; ac_word=$2
3270{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3271$as_echo_n "checking for $ac_word... " >&6; }
3272if ${ac_cv_prog_AWK+:} false; then :
3273  $as_echo_n "(cached) " >&6
3274else
3275  if test -n "$AWK"; then
3276  ac_cv_prog_AWK="$AWK" # Let the user override the test.
3277else
3278as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3279for as_dir in $PATH
3280do
3281  IFS=$as_save_IFS
3282  test -z "$as_dir" && as_dir=.
3283    for ac_exec_ext in '' $ac_executable_extensions; do
3284  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3285    ac_cv_prog_AWK="$ac_prog"
3286    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3287    break 2
3288  fi
3289done
3290  done
3291IFS=$as_save_IFS
3292
3293fi
3294fi
3295AWK=$ac_cv_prog_AWK
3296if test -n "$AWK"; then
3297  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
3298$as_echo "$AWK" >&6; }
3299else
3300  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3301$as_echo "no" >&6; }
3302fi
3303
3304
3305  test -n "$AWK" && break
3306done
3307
3308{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
3309$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
3310set x ${MAKE-make}
3311ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
3312if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then :
3313  $as_echo_n "(cached) " >&6
3314else
3315  cat >conftest.make <<\_ACEOF
3316SHELL = /bin/sh
3317all:
3318	@echo '@@@%%%=$(MAKE)=@@@%%%'
3319_ACEOF
3320# GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
3321case `${MAKE-make} -f conftest.make 2>/dev/null` in
3322  *@@@%%%=?*=@@@%%%*)
3323    eval ac_cv_prog_make_${ac_make}_set=yes;;
3324  *)
3325    eval ac_cv_prog_make_${ac_make}_set=no;;
3326esac
3327rm -f conftest.make
3328fi
3329if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
3330  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3331$as_echo "yes" >&6; }
3332  SET_MAKE=
3333else
3334  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3335$as_echo "no" >&6; }
3336  SET_MAKE="MAKE=${MAKE-make}"
3337fi
3338
3339rm -rf .tst 2>/dev/null
3340mkdir .tst 2>/dev/null
3341if test -d .tst; then
3342  am__leading_dot=.
3343else
3344  am__leading_dot=_
3345fi
3346rmdir .tst 2>/dev/null
3347
3348# Check whether --enable-silent-rules was given.
3349if test "${enable_silent_rules+set}" = set; then :
3350  enableval=$enable_silent_rules;
3351fi
3352
3353case $enable_silent_rules in # (((
3354  yes) AM_DEFAULT_VERBOSITY=0;;
3355   no) AM_DEFAULT_VERBOSITY=1;;
3356    *) AM_DEFAULT_VERBOSITY=1;;
3357esac
3358am_make=${MAKE-make}
3359{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
3360$as_echo_n "checking whether $am_make supports nested variables... " >&6; }
3361if ${am_cv_make_support_nested_variables+:} false; then :
3362  $as_echo_n "(cached) " >&6
3363else
3364  if $as_echo 'TRUE=$(BAR$(V))
3365BAR0=false
3366BAR1=true
3367V=1
3368am__doit:
3369	@$(TRUE)
3370.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
3371  am_cv_make_support_nested_variables=yes
3372else
3373  am_cv_make_support_nested_variables=no
3374fi
3375fi
3376{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
3377$as_echo "$am_cv_make_support_nested_variables" >&6; }
3378if test $am_cv_make_support_nested_variables = yes; then
3379    AM_V='$(V)'
3380  AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
3381else
3382  AM_V=$AM_DEFAULT_VERBOSITY
3383  AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
3384fi
3385AM_BACKSLASH='\'
3386
3387if test "`cd $srcdir && pwd`" != "`pwd`"; then
3388  # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
3389  # is not polluted with repeated "-I."
3390  am__isrc=' -I$(srcdir)'
3391  # test to see if srcdir already configured
3392  if test -f $srcdir/config.status; then
3393    as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
3394  fi
3395fi
3396
3397# test whether we have cygpath
3398if test -z "$CYGPATH_W"; then
3399  if (cygpath --version) >/dev/null 2>/dev/null; then
3400    CYGPATH_W='cygpath -w'
3401  else
3402    CYGPATH_W=echo
3403  fi
3404fi
3405
3406
3407# Define the identity of the package.
3408 PACKAGE='sntp'
3409 VERSION='4.2.8p10'
3410
3411
3412cat >>confdefs.h <<_ACEOF
3413#define PACKAGE "$PACKAGE"
3414_ACEOF
3415
3416
3417cat >>confdefs.h <<_ACEOF
3418#define VERSION "$VERSION"
3419_ACEOF
3420
3421# Some tools Automake needs.
3422
3423ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
3424
3425
3426AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
3427
3428
3429AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
3430
3431
3432AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
3433
3434
3435MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
3436
3437# For better backward compatibility.  To be removed once Automake 1.9.x
3438# dies out for good.  For more background, see:
3439# <http://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
3440# <http://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
3441mkdir_p='$(MKDIR_P)'
3442
3443# We need awk for the "check" target (and possibly the TAP driver).  The
3444# system "awk" is bad on some platforms.
3445# Always define AMTAR for backward compatibility.  Yes, it's still used
3446# in the wild :-(  We should find a proper way to deprecate it ...
3447AMTAR='$${TAR-tar}'
3448
3449
3450# We'll loop over all known methods to create a tar archive until one works.
3451_am_tools='gnutar  pax cpio none'
3452
3453am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'
3454
3455
3456
3457
3458
3459
3460# POSIX will say in a future version that running "rm -f" with no argument
3461# is OK; and we want to be able to make that assumption in our Makefile
3462# recipes.  So use an aggressive probe to check that the usage we want is
3463# actually supported "in the wild" to an acceptable degree.
3464# See automake bug#10828.
3465# To make any issue more visible, cause the running configure to be aborted
3466# by default if the 'rm' program in use doesn't match our expectations; the
3467# user can still override this though.
3468if rm -f && rm -fr && rm -rf; then : OK; else
3469  cat >&2 <<'END'
3470Oops!
3471
3472Your 'rm' program seems unable to run without file operands specified
3473on the command line, even when the '-f' option is present.  This is contrary
3474to the behaviour of most rm programs out there, and not conforming with
3475the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542>
3476
3477Please tell bug-automake@gnu.org about your system, including the value
3478of your $PATH and any error possibly output before this message.  This
3479can help us improve future automake versions.
3480
3481END
3482  if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then
3483    echo 'Configuration will proceed anyway, since you have set the' >&2
3484    echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2
3485    echo >&2
3486  else
3487    cat >&2 <<'END'
3488Aborting the configuration process, to ensure you take notice of the issue.
3489
3490You can download and install GNU coreutils to get an 'rm' implementation
3491that behaves properly: <http://www.gnu.org/software/coreutils/>.
3492
3493If you want to complete the configuration process using your problematic
3494'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
3495to "yes", and re-run configure.
3496
3497END
3498    as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5
3499  fi
3500fi
3501
3502# Check whether --enable-silent-rules was given.
3503if test "${enable_silent_rules+set}" = set; then :
3504  enableval=$enable_silent_rules;
3505fi
3506
3507case $enable_silent_rules in # (((
3508  yes) AM_DEFAULT_VERBOSITY=0;;
3509   no) AM_DEFAULT_VERBOSITY=1;;
3510    *) AM_DEFAULT_VERBOSITY=0;;
3511esac
3512am_make=${MAKE-make}
3513{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
3514$as_echo_n "checking whether $am_make supports nested variables... " >&6; }
3515if ${am_cv_make_support_nested_variables+:} false; then :
3516  $as_echo_n "(cached) " >&6
3517else
3518  if $as_echo 'TRUE=$(BAR$(V))
3519BAR0=false
3520BAR1=true
3521V=1
3522am__doit:
3523	@$(TRUE)
3524.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
3525  am_cv_make_support_nested_variables=yes
3526else
3527  am_cv_make_support_nested_variables=no
3528fi
3529fi
3530{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
3531$as_echo "$am_cv_make_support_nested_variables" >&6; }
3532if test $am_cv_make_support_nested_variables = yes; then
3533    AM_V='$(V)'
3534  AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
3535else
3536  AM_V=$AM_DEFAULT_VERBOSITY
3537  AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
3538fi
3539AM_BACKSLASH='\'
3540
3541
3542# Make sure we can run config.sub.
3543$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
3544  as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
3545
3546{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
3547$as_echo_n "checking build system type... " >&6; }
3548if ${ac_cv_build+:} false; then :
3549  $as_echo_n "(cached) " >&6
3550else
3551  ac_build_alias=$build_alias
3552test "x$ac_build_alias" = x &&
3553  ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
3554test "x$ac_build_alias" = x &&
3555  as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
3556ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
3557  as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
3558
3559fi
3560{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
3561$as_echo "$ac_cv_build" >&6; }
3562case $ac_cv_build in
3563*-*-*) ;;
3564*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
3565esac
3566build=$ac_cv_build
3567ac_save_IFS=$IFS; IFS='-'
3568set x $ac_cv_build
3569shift
3570build_cpu=$1
3571build_vendor=$2
3572shift; shift
3573# Remember, the first character of IFS is used to create $*,
3574# except with old shells:
3575build_os=$*
3576IFS=$ac_save_IFS
3577case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
3578
3579
3580{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
3581$as_echo_n "checking host system type... " >&6; }
3582if ${ac_cv_host+:} false; then :
3583  $as_echo_n "(cached) " >&6
3584else
3585  if test "x$host_alias" = x; then
3586  ac_cv_host=$ac_cv_build
3587else
3588  ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
3589    as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
3590fi
3591
3592fi
3593{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
3594$as_echo "$ac_cv_host" >&6; }
3595case $ac_cv_host in
3596*-*-*) ;;
3597*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
3598esac
3599host=$ac_cv_host
3600ac_save_IFS=$IFS; IFS='-'
3601set x $ac_cv_host
3602shift
3603host_cpu=$1
3604host_vendor=$2
3605shift; shift
3606# Remember, the first character of IFS is used to create $*,
3607# except with old shells:
3608host_os=$*
3609IFS=$ac_save_IFS
3610case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
3611
3612
3613
3614cat >>confdefs.h <<_ACEOF
3615#define STR_SYSTEM "$host"
3616_ACEOF
3617
3618ac_config_headers="$ac_config_headers config.h"
3619
3620
3621DEPDIR="${am__leading_dot}deps"
3622
3623ac_config_commands="$ac_config_commands depfiles"
3624
3625
3626am_make=${MAKE-make}
3627cat > confinc << 'END'
3628am__doit:
3629	@echo this is the am__doit target
3630.PHONY: am__doit
3631END
3632# If we don't find an include directive, just comment out the code.
3633{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
3634$as_echo_n "checking for style of include used by $am_make... " >&6; }
3635am__include="#"
3636am__quote=
3637_am_result=none
3638# First try GNU make style include.
3639echo "include confinc" > confmf
3640# Ignore all kinds of additional output from 'make'.
3641case `$am_make -s -f confmf 2> /dev/null` in #(
3642*the\ am__doit\ target*)
3643  am__include=include
3644  am__quote=
3645  _am_result=GNU
3646  ;;
3647esac
3648# Now try BSD make style include.
3649if test "$am__include" = "#"; then
3650   echo '.include "confinc"' > confmf
3651   case `$am_make -s -f confmf 2> /dev/null` in #(
3652   *the\ am__doit\ target*)
3653     am__include=.include
3654     am__quote="\""
3655     _am_result=BSD
3656     ;;
3657   esac
3658fi
3659
3660
3661{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
3662$as_echo "$_am_result" >&6; }
3663rm -f confinc confmf
3664
3665# Check whether --enable-dependency-tracking was given.
3666if test "${enable_dependency_tracking+set}" = set; then :
3667  enableval=$enable_dependency_tracking;
3668fi
3669
3670if test "x$enable_dependency_tracking" != xno; then
3671  am_depcomp="$ac_aux_dir/depcomp"
3672  AMDEPBACKSLASH='\'
3673  am__nodep='_no'
3674fi
3675 if test "x$enable_dependency_tracking" != xno; then
3676  AMDEP_TRUE=
3677  AMDEP_FALSE='#'
3678else
3679  AMDEP_TRUE='#'
3680  AMDEP_FALSE=
3681fi
3682
3683
3684
3685case "$build" in
3686 *-*-freebsd1?.*)
3687    cclist=cc
3688    ;;
3689 *)
3690    cclist="cc gcc"
3691    ;;
3692esac
3693
3694
3695#AC_USE_SYSTEM_EXTENSIONS
3696
3697ac_ext=c
3698ac_cpp='$CPP $CPPFLAGS'
3699ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3700ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3701ac_compiler_gnu=$ac_cv_c_compiler_gnu
3702if test -n "$ac_tool_prefix"; then
3703  for ac_prog in $cclist
3704  do
3705    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3706set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3707{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3708$as_echo_n "checking for $ac_word... " >&6; }
3709if ${ac_cv_prog_CC+:} false; then :
3710  $as_echo_n "(cached) " >&6
3711else
3712  if test -n "$CC"; then
3713  ac_cv_prog_CC="$CC" # Let the user override the test.
3714else
3715as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3716for as_dir in $PATH
3717do
3718  IFS=$as_save_IFS
3719  test -z "$as_dir" && as_dir=.
3720    for ac_exec_ext in '' $ac_executable_extensions; do
3721  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3722    ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3723    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3724    break 2
3725  fi
3726done
3727  done
3728IFS=$as_save_IFS
3729
3730fi
3731fi
3732CC=$ac_cv_prog_CC
3733if test -n "$CC"; then
3734  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3735$as_echo "$CC" >&6; }
3736else
3737  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3738$as_echo "no" >&6; }
3739fi
3740
3741
3742    test -n "$CC" && break
3743  done
3744fi
3745if test -z "$CC"; then
3746  ac_ct_CC=$CC
3747  for ac_prog in $cclist
3748do
3749  # Extract the first word of "$ac_prog", so it can be a program name with args.
3750set dummy $ac_prog; ac_word=$2
3751{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3752$as_echo_n "checking for $ac_word... " >&6; }
3753if ${ac_cv_prog_ac_ct_CC+:} false; then :
3754  $as_echo_n "(cached) " >&6
3755else
3756  if test -n "$ac_ct_CC"; then
3757  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3758else
3759as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3760for as_dir in $PATH
3761do
3762  IFS=$as_save_IFS
3763  test -z "$as_dir" && as_dir=.
3764    for ac_exec_ext in '' $ac_executable_extensions; do
3765  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3766    ac_cv_prog_ac_ct_CC="$ac_prog"
3767    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3768    break 2
3769  fi
3770done
3771  done
3772IFS=$as_save_IFS
3773
3774fi
3775fi
3776ac_ct_CC=$ac_cv_prog_ac_ct_CC
3777if test -n "$ac_ct_CC"; then
3778  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3779$as_echo "$ac_ct_CC" >&6; }
3780else
3781  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3782$as_echo "no" >&6; }
3783fi
3784
3785
3786  test -n "$ac_ct_CC" && break
3787done
3788
3789  if test "x$ac_ct_CC" = x; then
3790    CC=""
3791  else
3792    case $cross_compiling:$ac_tool_warned in
3793yes:)
3794{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3795$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3796ac_tool_warned=yes ;;
3797esac
3798    CC=$ac_ct_CC
3799  fi
3800fi
3801
3802
3803test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3804$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3805as_fn_error $? "no acceptable C compiler found in \$PATH
3806See \`config.log' for more details" "$LINENO" 5; }
3807
3808# Provide some information about the compiler.
3809$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
3810set X $ac_compile
3811ac_compiler=$2
3812for ac_option in --version -v -V -qversion; do
3813  { { ac_try="$ac_compiler $ac_option >&5"
3814case "(($ac_try" in
3815  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3816  *) ac_try_echo=$ac_try;;
3817esac
3818eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3819$as_echo "$ac_try_echo"; } >&5
3820  (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3821  ac_status=$?
3822  if test -s conftest.err; then
3823    sed '10a\
3824... rest of stderr output deleted ...
3825         10q' conftest.err >conftest.er1
3826    cat conftest.er1 >&5
3827  fi
3828  rm -f conftest.er1 conftest.err
3829  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3830  test $ac_status = 0; }
3831done
3832
3833cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3834/* end confdefs.h.  */
3835
3836int
3837main ()
3838{
3839
3840  ;
3841  return 0;
3842}
3843_ACEOF
3844ac_clean_files_save=$ac_clean_files
3845ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
3846# Try to create an executable without -o first, disregard a.out.
3847# It will help us diagnose broken compilers, and finding out an intuition
3848# of exeext.
3849{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
3850$as_echo_n "checking whether the C compiler works... " >&6; }
3851ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3852
3853# The possible output files:
3854ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3855
3856ac_rmfiles=
3857for ac_file in $ac_files
3858do
3859  case $ac_file in
3860    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3861    * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3862  esac
3863done
3864rm -f $ac_rmfiles
3865
3866if { { ac_try="$ac_link_default"
3867case "(($ac_try" in
3868  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3869  *) ac_try_echo=$ac_try;;
3870esac
3871eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3872$as_echo "$ac_try_echo"; } >&5
3873  (eval "$ac_link_default") 2>&5
3874  ac_status=$?
3875  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3876  test $ac_status = 0; }; then :
3877  # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3878# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3879# in a Makefile.  We should not override ac_cv_exeext if it was cached,
3880# so that the user can short-circuit this test for compilers unknown to
3881# Autoconf.
3882for ac_file in $ac_files ''
3883do
3884  test -f "$ac_file" || continue
3885  case $ac_file in
3886    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
3887	;;
3888    [ab].out )
3889	# We found the default executable, but exeext='' is most
3890	# certainly right.
3891	break;;
3892    *.* )
3893	if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3894	then :; else
3895	   ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3896	fi
3897	# We set ac_cv_exeext here because the later test for it is not
3898	# safe: cross compilers may not add the suffix if given an `-o'
3899	# argument, so we may need to know it at that point already.
3900	# Even if this section looks crufty: it has the advantage of
3901	# actually working.
3902	break;;
3903    * )
3904	break;;
3905  esac
3906done
3907test "$ac_cv_exeext" = no && ac_cv_exeext=
3908
3909else
3910  ac_file=''
3911fi
3912if test -z "$ac_file"; then :
3913  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3914$as_echo "no" >&6; }
3915$as_echo "$as_me: failed program was:" >&5
3916sed 's/^/| /' conftest.$ac_ext >&5
3917
3918{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3919$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3920as_fn_error 77 "C compiler cannot create executables
3921See \`config.log' for more details" "$LINENO" 5; }
3922else
3923  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3924$as_echo "yes" >&6; }
3925fi
3926{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
3927$as_echo_n "checking for C compiler default output file name... " >&6; }
3928{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
3929$as_echo "$ac_file" >&6; }
3930ac_exeext=$ac_cv_exeext
3931
3932rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
3933ac_clean_files=$ac_clean_files_save
3934{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
3935$as_echo_n "checking for suffix of executables... " >&6; }
3936if { { ac_try="$ac_link"
3937case "(($ac_try" in
3938  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3939  *) ac_try_echo=$ac_try;;
3940esac
3941eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3942$as_echo "$ac_try_echo"; } >&5
3943  (eval "$ac_link") 2>&5
3944  ac_status=$?
3945  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3946  test $ac_status = 0; }; then :
3947  # If both `conftest.exe' and `conftest' are `present' (well, observable)
3948# catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
3949# work properly (i.e., refer to `conftest.exe'), while it won't with
3950# `rm'.
3951for ac_file in conftest.exe conftest conftest.*; do
3952  test -f "$ac_file" || continue
3953  case $ac_file in
3954    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3955    *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3956	  break;;
3957    * ) break;;
3958  esac
3959done
3960else
3961  { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3962$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3963as_fn_error $? "cannot compute suffix of executables: cannot compile and link
3964See \`config.log' for more details" "$LINENO" 5; }
3965fi
3966rm -f conftest conftest$ac_cv_exeext
3967{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
3968$as_echo "$ac_cv_exeext" >&6; }
3969
3970rm -f conftest.$ac_ext
3971EXEEXT=$ac_cv_exeext
3972ac_exeext=$EXEEXT
3973cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3974/* end confdefs.h.  */
3975#include <stdio.h>
3976int
3977main ()
3978{
3979FILE *f = fopen ("conftest.out", "w");
3980 return ferror (f) || fclose (f) != 0;
3981
3982  ;
3983  return 0;
3984}
3985_ACEOF
3986ac_clean_files="$ac_clean_files conftest.out"
3987# Check that the compiler produces executables we can run.  If not, either
3988# the compiler is broken, or we cross compile.
3989{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
3990$as_echo_n "checking whether we are cross compiling... " >&6; }
3991if test "$cross_compiling" != yes; then
3992  { { ac_try="$ac_link"
3993case "(($ac_try" in
3994  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3995  *) ac_try_echo=$ac_try;;
3996esac
3997eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3998$as_echo "$ac_try_echo"; } >&5
3999  (eval "$ac_link") 2>&5
4000  ac_status=$?
4001  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4002  test $ac_status = 0; }
4003  if { ac_try='./conftest$ac_cv_exeext'
4004  { { case "(($ac_try" in
4005  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4006  *) ac_try_echo=$ac_try;;
4007esac
4008eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4009$as_echo "$ac_try_echo"; } >&5
4010  (eval "$ac_try") 2>&5
4011  ac_status=$?
4012  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4013  test $ac_status = 0; }; }; then
4014    cross_compiling=no
4015  else
4016    if test "$cross_compiling" = maybe; then
4017	cross_compiling=yes
4018    else
4019	{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4020$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4021as_fn_error $? "cannot run C compiled programs.
4022If you meant to cross compile, use \`--host'.
4023See \`config.log' for more details" "$LINENO" 5; }
4024    fi
4025  fi
4026fi
4027{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
4028$as_echo "$cross_compiling" >&6; }
4029
4030rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
4031ac_clean_files=$ac_clean_files_save
4032{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
4033$as_echo_n "checking for suffix of object files... " >&6; }
4034if ${ac_cv_objext+:} false; then :
4035  $as_echo_n "(cached) " >&6
4036else
4037  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4038/* end confdefs.h.  */
4039
4040int
4041main ()
4042{
4043
4044  ;
4045  return 0;
4046}
4047_ACEOF
4048rm -f conftest.o conftest.obj
4049if { { ac_try="$ac_compile"
4050case "(($ac_try" in
4051  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4052  *) ac_try_echo=$ac_try;;
4053esac
4054eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4055$as_echo "$ac_try_echo"; } >&5
4056  (eval "$ac_compile") 2>&5
4057  ac_status=$?
4058  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4059  test $ac_status = 0; }; then :
4060  for ac_file in conftest.o conftest.obj conftest.*; do
4061  test -f "$ac_file" || continue;
4062  case $ac_file in
4063    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
4064    *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
4065       break;;
4066  esac
4067done
4068else
4069  $as_echo "$as_me: failed program was:" >&5
4070sed 's/^/| /' conftest.$ac_ext >&5
4071
4072{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4073$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4074as_fn_error $? "cannot compute suffix of object files: cannot compile
4075See \`config.log' for more details" "$LINENO" 5; }
4076fi
4077rm -f conftest.$ac_cv_objext conftest.$ac_ext
4078fi
4079{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
4080$as_echo "$ac_cv_objext" >&6; }
4081OBJEXT=$ac_cv_objext
4082ac_objext=$OBJEXT
4083{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
4084$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
4085if ${ac_cv_c_compiler_gnu+:} false; then :
4086  $as_echo_n "(cached) " >&6
4087else
4088  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4089/* end confdefs.h.  */
4090
4091int
4092main ()
4093{
4094#ifndef __GNUC__
4095       choke me
4096#endif
4097
4098  ;
4099  return 0;
4100}
4101_ACEOF
4102if ac_fn_c_try_compile "$LINENO"; then :
4103  ac_compiler_gnu=yes
4104else
4105  ac_compiler_gnu=no
4106fi
4107rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4108ac_cv_c_compiler_gnu=$ac_compiler_gnu
4109
4110fi
4111{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
4112$as_echo "$ac_cv_c_compiler_gnu" >&6; }
4113if test $ac_compiler_gnu = yes; then
4114  GCC=yes
4115else
4116  GCC=
4117fi
4118ac_test_CFLAGS=${CFLAGS+set}
4119ac_save_CFLAGS=$CFLAGS
4120{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
4121$as_echo_n "checking whether $CC accepts -g... " >&6; }
4122if ${ac_cv_prog_cc_g+:} false; then :
4123  $as_echo_n "(cached) " >&6
4124else
4125  ac_save_c_werror_flag=$ac_c_werror_flag
4126   ac_c_werror_flag=yes
4127   ac_cv_prog_cc_g=no
4128   CFLAGS="-g"
4129   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4130/* end confdefs.h.  */
4131
4132int
4133main ()
4134{
4135
4136  ;
4137  return 0;
4138}
4139_ACEOF
4140if ac_fn_c_try_compile "$LINENO"; then :
4141  ac_cv_prog_cc_g=yes
4142else
4143  CFLAGS=""
4144      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4145/* end confdefs.h.  */
4146
4147int
4148main ()
4149{
4150
4151  ;
4152  return 0;
4153}
4154_ACEOF
4155if ac_fn_c_try_compile "$LINENO"; then :
4156
4157else
4158  ac_c_werror_flag=$ac_save_c_werror_flag
4159	 CFLAGS="-g"
4160	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4161/* end confdefs.h.  */
4162
4163int
4164main ()
4165{
4166
4167  ;
4168  return 0;
4169}
4170_ACEOF
4171if ac_fn_c_try_compile "$LINENO"; then :
4172  ac_cv_prog_cc_g=yes
4173fi
4174rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4175fi
4176rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4177fi
4178rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4179   ac_c_werror_flag=$ac_save_c_werror_flag
4180fi
4181{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
4182$as_echo "$ac_cv_prog_cc_g" >&6; }
4183if test "$ac_test_CFLAGS" = set; then
4184  CFLAGS=$ac_save_CFLAGS
4185elif test $ac_cv_prog_cc_g = yes; then
4186  if test "$GCC" = yes; then
4187    CFLAGS="-g -O2"
4188  else
4189    CFLAGS="-g"
4190  fi
4191else
4192  if test "$GCC" = yes; then
4193    CFLAGS="-O2"
4194  else
4195    CFLAGS=
4196  fi
4197fi
4198{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
4199$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
4200if ${ac_cv_prog_cc_c89+:} false; then :
4201  $as_echo_n "(cached) " >&6
4202else
4203  ac_cv_prog_cc_c89=no
4204ac_save_CC=$CC
4205cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4206/* end confdefs.h.  */
4207#include <stdarg.h>
4208#include <stdio.h>
4209struct stat;
4210/* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
4211struct buf { int x; };
4212FILE * (*rcsopen) (struct buf *, struct stat *, int);
4213static char *e (p, i)
4214     char **p;
4215     int i;
4216{
4217  return p[i];
4218}
4219static char *f (char * (*g) (char **, int), char **p, ...)
4220{
4221  char *s;
4222  va_list v;
4223  va_start (v,p);
4224  s = g (p, va_arg (v,int));
4225  va_end (v);
4226  return s;
4227}
4228
4229/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
4230   function prototypes and stuff, but not '\xHH' hex character constants.
4231   These don't provoke an error unfortunately, instead are silently treated
4232   as 'x'.  The following induces an error, until -std is added to get
4233   proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
4234   array size at least.  It's necessary to write '\x00'==0 to get something
4235   that's true only with -std.  */
4236int osf4_cc_array ['\x00' == 0 ? 1 : -1];
4237
4238/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
4239   inside strings and character constants.  */
4240#define FOO(x) 'x'
4241int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
4242
4243int test (int i, double x);
4244struct s1 {int (*f) (int a);};
4245struct s2 {int (*f) (double a);};
4246int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4247int argc;
4248char **argv;
4249int
4250main ()
4251{
4252return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
4253  ;
4254  return 0;
4255}
4256_ACEOF
4257for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
4258	-Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4259do
4260  CC="$ac_save_CC $ac_arg"
4261  if ac_fn_c_try_compile "$LINENO"; then :
4262  ac_cv_prog_cc_c89=$ac_arg
4263fi
4264rm -f core conftest.err conftest.$ac_objext
4265  test "x$ac_cv_prog_cc_c89" != "xno" && break
4266done
4267rm -f conftest.$ac_ext
4268CC=$ac_save_CC
4269
4270fi
4271# AC_CACHE_VAL
4272case "x$ac_cv_prog_cc_c89" in
4273  x)
4274    { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4275$as_echo "none needed" >&6; } ;;
4276  xno)
4277    { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4278$as_echo "unsupported" >&6; } ;;
4279  *)
4280    CC="$CC $ac_cv_prog_cc_c89"
4281    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
4282$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
4283esac
4284if test "x$ac_cv_prog_cc_c89" != xno; then :
4285
4286fi
4287
4288ac_ext=c
4289ac_cpp='$CPP $CPPFLAGS'
4290ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4291ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4292ac_compiler_gnu=$ac_cv_c_compiler_gnu
4293
4294ac_ext=c
4295ac_cpp='$CPP $CPPFLAGS'
4296ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4297ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4298ac_compiler_gnu=$ac_cv_c_compiler_gnu
4299{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5
4300$as_echo_n "checking whether $CC understands -c and -o together... " >&6; }
4301if ${am_cv_prog_cc_c_o+:} false; then :
4302  $as_echo_n "(cached) " >&6
4303else
4304  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4305/* end confdefs.h.  */
4306
4307int
4308main ()
4309{
4310
4311  ;
4312  return 0;
4313}
4314_ACEOF
4315  # Make sure it works both with $CC and with simple cc.
4316  # Following AC_PROG_CC_C_O, we do the test twice because some
4317  # compilers refuse to overwrite an existing .o file with -o,
4318  # though they will create one.
4319  am_cv_prog_cc_c_o=yes
4320  for am_i in 1 2; do
4321    if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5
4322   ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5
4323   ac_status=$?
4324   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4325   (exit $ac_status); } \
4326         && test -f conftest2.$ac_objext; then
4327      : OK
4328    else
4329      am_cv_prog_cc_c_o=no
4330      break
4331    fi
4332  done
4333  rm -f core conftest*
4334  unset am_i
4335fi
4336{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5
4337$as_echo "$am_cv_prog_cc_c_o" >&6; }
4338if test "$am_cv_prog_cc_c_o" != yes; then
4339   # Losing compiler, so override with the script.
4340   # FIXME: It is wrong to rewrite CC.
4341   # But if we don't then we get into trouble of one sort or another.
4342   # A longer-term fix would be to have automake use am__CC in this case,
4343   # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
4344   CC="$am_aux_dir/compile $CC"
4345fi
4346ac_ext=c
4347ac_cpp='$CPP $CPPFLAGS'
4348ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4349ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4350ac_compiler_gnu=$ac_cv_c_compiler_gnu
4351
4352
4353depcc="$CC"   am_compiler_list=
4354
4355{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
4356$as_echo_n "checking dependency style of $depcc... " >&6; }
4357if ${am_cv_CC_dependencies_compiler_type+:} false; then :
4358  $as_echo_n "(cached) " >&6
4359else
4360  if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
4361  # We make a subdir and do the tests there.  Otherwise we can end up
4362  # making bogus files that we don't know about and never remove.  For
4363  # instance it was reported that on HP-UX the gcc test will end up
4364  # making a dummy file named 'D' -- because '-MD' means "put the output
4365  # in D".
4366  rm -rf conftest.dir
4367  mkdir conftest.dir
4368  # Copy depcomp to subdir because otherwise we won't find it if we're
4369  # using a relative directory.
4370  cp "$am_depcomp" conftest.dir
4371  cd conftest.dir
4372  # We will build objects and dependencies in a subdirectory because
4373  # it helps to detect inapplicable dependency modes.  For instance
4374  # both Tru64's cc and ICC support -MD to output dependencies as a
4375  # side effect of compilation, but ICC will put the dependencies in
4376  # the current directory while Tru64 will put them in the object
4377  # directory.
4378  mkdir sub
4379
4380  am_cv_CC_dependencies_compiler_type=none
4381  if test "$am_compiler_list" = ""; then
4382     am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
4383  fi
4384  am__universal=false
4385  case " $depcc " in #(
4386     *\ -arch\ *\ -arch\ *) am__universal=true ;;
4387     esac
4388
4389  for depmode in $am_compiler_list; do
4390    # Setup a source with many dependencies, because some compilers
4391    # like to wrap large dependency lists on column 80 (with \), and
4392    # we should not choose a depcomp mode which is confused by this.
4393    #
4394    # We need to recreate these files for each test, as the compiler may
4395    # overwrite some of them when testing with obscure command lines.
4396    # This happens at least with the AIX C compiler.
4397    : > sub/conftest.c
4398    for i in 1 2 3 4 5 6; do
4399      echo '#include "conftst'$i'.h"' >> sub/conftest.c
4400      # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
4401      # Solaris 10 /bin/sh.
4402      echo '/* dummy */' > sub/conftst$i.h
4403    done
4404    echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
4405
4406    # We check with '-c' and '-o' for the sake of the "dashmstdout"
4407    # mode.  It turns out that the SunPro C++ compiler does not properly
4408    # handle '-M -o', and we need to detect this.  Also, some Intel
4409    # versions had trouble with output in subdirs.
4410    am__obj=sub/conftest.${OBJEXT-o}
4411    am__minus_obj="-o $am__obj"
4412    case $depmode in
4413    gcc)
4414      # This depmode causes a compiler race in universal mode.
4415      test "$am__universal" = false || continue
4416      ;;
4417    nosideeffect)
4418      # After this tag, mechanisms are not by side-effect, so they'll
4419      # only be used when explicitly requested.
4420      if test "x$enable_dependency_tracking" = xyes; then
4421	continue
4422      else
4423	break
4424      fi
4425      ;;
4426    msvc7 | msvc7msys | msvisualcpp | msvcmsys)
4427      # This compiler won't grok '-c -o', but also, the minuso test has
4428      # not run yet.  These depmodes are late enough in the game, and
4429      # so weak that their functioning should not be impacted.
4430      am__obj=conftest.${OBJEXT-o}
4431      am__minus_obj=
4432      ;;
4433    none) break ;;
4434    esac
4435    if depmode=$depmode \
4436       source=sub/conftest.c object=$am__obj \
4437       depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
4438       $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
4439         >/dev/null 2>conftest.err &&
4440       grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
4441       grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
4442       grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
4443       ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
4444      # icc doesn't choke on unknown options, it will just issue warnings
4445      # or remarks (even with -Werror).  So we grep stderr for any message
4446      # that says an option was ignored or not supported.
4447      # When given -MP, icc 7.0 and 7.1 complain thusly:
4448      #   icc: Command line warning: ignoring option '-M'; no argument required
4449      # The diagnosis changed in icc 8.0:
4450      #   icc: Command line remark: option '-MP' not supported
4451      if (grep 'ignoring option' conftest.err ||
4452          grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
4453        am_cv_CC_dependencies_compiler_type=$depmode
4454        break
4455      fi
4456    fi
4457  done
4458
4459  cd ..
4460  rm -rf conftest.dir
4461else
4462  am_cv_CC_dependencies_compiler_type=none
4463fi
4464
4465fi
4466{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
4467$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
4468CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
4469
4470 if
4471  test "x$enable_dependency_tracking" != xno \
4472  && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
4473  am__fastdepCC_TRUE=
4474  am__fastdepCC_FALSE='#'
4475else
4476  am__fastdepCC_TRUE='#'
4477  am__fastdepCC_FALSE=
4478fi
4479
4480
4481
4482
4483
4484ac_ext=c
4485ac_cpp='$CPP $CPPFLAGS'
4486ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4487ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4488ac_compiler_gnu=$ac_cv_c_compiler_gnu
4489{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
4490$as_echo_n "checking how to run the C preprocessor... " >&6; }
4491# On Suns, sometimes $CPP names a directory.
4492if test -n "$CPP" && test -d "$CPP"; then
4493  CPP=
4494fi
4495if test -z "$CPP"; then
4496  if ${ac_cv_prog_CPP+:} false; then :
4497  $as_echo_n "(cached) " >&6
4498else
4499      # Double quotes because CPP needs to be expanded
4500    for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
4501    do
4502      ac_preproc_ok=false
4503for ac_c_preproc_warn_flag in '' yes
4504do
4505  # Use a header file that comes with gcc, so configuring glibc
4506  # with a fresh cross-compiler works.
4507  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4508  # <limits.h> exists even on freestanding compilers.
4509  # On the NeXT, cc -E runs the code through the compiler's parser,
4510  # not just through cpp. "Syntax error" is here to catch this case.
4511  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4512/* end confdefs.h.  */
4513#ifdef __STDC__
4514# include <limits.h>
4515#else
4516# include <assert.h>
4517#endif
4518		     Syntax error
4519_ACEOF
4520if ac_fn_c_try_cpp "$LINENO"; then :
4521
4522else
4523  # Broken: fails on valid input.
4524continue
4525fi
4526rm -f conftest.err conftest.i conftest.$ac_ext
4527
4528  # OK, works on sane cases.  Now check whether nonexistent headers
4529  # can be detected and how.
4530  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4531/* end confdefs.h.  */
4532#include <ac_nonexistent.h>
4533_ACEOF
4534if ac_fn_c_try_cpp "$LINENO"; then :
4535  # Broken: success on invalid input.
4536continue
4537else
4538  # Passes both tests.
4539ac_preproc_ok=:
4540break
4541fi
4542rm -f conftest.err conftest.i conftest.$ac_ext
4543
4544done
4545# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4546rm -f conftest.i conftest.err conftest.$ac_ext
4547if $ac_preproc_ok; then :
4548  break
4549fi
4550
4551    done
4552    ac_cv_prog_CPP=$CPP
4553
4554fi
4555  CPP=$ac_cv_prog_CPP
4556else
4557  ac_cv_prog_CPP=$CPP
4558fi
4559{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
4560$as_echo "$CPP" >&6; }
4561ac_preproc_ok=false
4562for ac_c_preproc_warn_flag in '' yes
4563do
4564  # Use a header file that comes with gcc, so configuring glibc
4565  # with a fresh cross-compiler works.
4566  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4567  # <limits.h> exists even on freestanding compilers.
4568  # On the NeXT, cc -E runs the code through the compiler's parser,
4569  # not just through cpp. "Syntax error" is here to catch this case.
4570  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4571/* end confdefs.h.  */
4572#ifdef __STDC__
4573# include <limits.h>
4574#else
4575# include <assert.h>
4576#endif
4577		     Syntax error
4578_ACEOF
4579if ac_fn_c_try_cpp "$LINENO"; then :
4580
4581else
4582  # Broken: fails on valid input.
4583continue
4584fi
4585rm -f conftest.err conftest.i conftest.$ac_ext
4586
4587  # OK, works on sane cases.  Now check whether nonexistent headers
4588  # can be detected and how.
4589  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4590/* end confdefs.h.  */
4591#include <ac_nonexistent.h>
4592_ACEOF
4593if ac_fn_c_try_cpp "$LINENO"; then :
4594  # Broken: success on invalid input.
4595continue
4596else
4597  # Passes both tests.
4598ac_preproc_ok=:
4599break
4600fi
4601rm -f conftest.err conftest.i conftest.$ac_ext
4602
4603done
4604# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4605rm -f conftest.i conftest.err conftest.$ac_ext
4606if $ac_preproc_ok; then :
4607
4608else
4609  { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4610$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4611as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
4612See \`config.log' for more details" "$LINENO" 5; }
4613fi
4614
4615ac_ext=c
4616ac_cpp='$CPP $CPPFLAGS'
4617ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4618ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4619ac_compiler_gnu=$ac_cv_c_compiler_gnu
4620
4621
4622{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
4623$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
4624if ${ac_cv_path_GREP+:} false; then :
4625  $as_echo_n "(cached) " >&6
4626else
4627  if test -z "$GREP"; then
4628  ac_path_GREP_found=false
4629  # Loop through the user's path and test for each of PROGNAME-LIST
4630  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4631for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4632do
4633  IFS=$as_save_IFS
4634  test -z "$as_dir" && as_dir=.
4635    for ac_prog in grep ggrep; do
4636    for ac_exec_ext in '' $ac_executable_extensions; do
4637      ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
4638      as_fn_executable_p "$ac_path_GREP" || continue
4639# Check for GNU ac_path_GREP and select it if it is found.
4640  # Check for GNU $ac_path_GREP
4641case `"$ac_path_GREP" --version 2>&1` in
4642*GNU*)
4643  ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
4644*)
4645  ac_count=0
4646  $as_echo_n 0123456789 >"conftest.in"
4647  while :
4648  do
4649    cat "conftest.in" "conftest.in" >"conftest.tmp"
4650    mv "conftest.tmp" "conftest.in"
4651    cp "conftest.in" "conftest.nl"
4652    $as_echo 'GREP' >> "conftest.nl"
4653    "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4654    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4655    as_fn_arith $ac_count + 1 && ac_count=$as_val
4656    if test $ac_count -gt ${ac_path_GREP_max-0}; then
4657      # Best one so far, save it but keep looking for a better one
4658      ac_cv_path_GREP="$ac_path_GREP"
4659      ac_path_GREP_max=$ac_count
4660    fi
4661    # 10*(2^10) chars as input seems more than enough
4662    test $ac_count -gt 10 && break
4663  done
4664  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4665esac
4666
4667      $ac_path_GREP_found && break 3
4668    done
4669  done
4670  done
4671IFS=$as_save_IFS
4672  if test -z "$ac_cv_path_GREP"; then
4673    as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4674  fi
4675else
4676  ac_cv_path_GREP=$GREP
4677fi
4678
4679fi
4680{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
4681$as_echo "$ac_cv_path_GREP" >&6; }
4682 GREP="$ac_cv_path_GREP"
4683
4684
4685{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
4686$as_echo_n "checking for egrep... " >&6; }
4687if ${ac_cv_path_EGREP+:} false; then :
4688  $as_echo_n "(cached) " >&6
4689else
4690  if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
4691   then ac_cv_path_EGREP="$GREP -E"
4692   else
4693     if test -z "$EGREP"; then
4694  ac_path_EGREP_found=false
4695  # Loop through the user's path and test for each of PROGNAME-LIST
4696  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4697for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4698do
4699  IFS=$as_save_IFS
4700  test -z "$as_dir" && as_dir=.
4701    for ac_prog in egrep; do
4702    for ac_exec_ext in '' $ac_executable_extensions; do
4703      ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
4704      as_fn_executable_p "$ac_path_EGREP" || continue
4705# Check for GNU ac_path_EGREP and select it if it is found.
4706  # Check for GNU $ac_path_EGREP
4707case `"$ac_path_EGREP" --version 2>&1` in
4708*GNU*)
4709  ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
4710*)
4711  ac_count=0
4712  $as_echo_n 0123456789 >"conftest.in"
4713  while :
4714  do
4715    cat "conftest.in" "conftest.in" >"conftest.tmp"
4716    mv "conftest.tmp" "conftest.in"
4717    cp "conftest.in" "conftest.nl"
4718    $as_echo 'EGREP' >> "conftest.nl"
4719    "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4720    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4721    as_fn_arith $ac_count + 1 && ac_count=$as_val
4722    if test $ac_count -gt ${ac_path_EGREP_max-0}; then
4723      # Best one so far, save it but keep looking for a better one
4724      ac_cv_path_EGREP="$ac_path_EGREP"
4725      ac_path_EGREP_max=$ac_count
4726    fi
4727    # 10*(2^10) chars as input seems more than enough
4728    test $ac_count -gt 10 && break
4729  done
4730  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4731esac
4732
4733      $ac_path_EGREP_found && break 3
4734    done
4735  done
4736  done
4737IFS=$as_save_IFS
4738  if test -z "$ac_cv_path_EGREP"; then
4739    as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4740  fi
4741else
4742  ac_cv_path_EGREP=$EGREP
4743fi
4744
4745   fi
4746fi
4747{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
4748$as_echo "$ac_cv_path_EGREP" >&6; }
4749 EGREP="$ac_cv_path_EGREP"
4750
4751
4752{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
4753$as_echo_n "checking for ANSI C header files... " >&6; }
4754if ${ac_cv_header_stdc+:} false; then :
4755  $as_echo_n "(cached) " >&6
4756else
4757  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4758/* end confdefs.h.  */
4759#include <stdlib.h>
4760#include <stdarg.h>
4761#include <string.h>
4762#include <float.h>
4763
4764int
4765main ()
4766{
4767
4768  ;
4769  return 0;
4770}
4771_ACEOF
4772if ac_fn_c_try_compile "$LINENO"; then :
4773  ac_cv_header_stdc=yes
4774else
4775  ac_cv_header_stdc=no
4776fi
4777rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4778
4779if test $ac_cv_header_stdc = yes; then
4780  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
4781  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4782/* end confdefs.h.  */
4783#include <string.h>
4784
4785_ACEOF
4786if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4787  $EGREP "memchr" >/dev/null 2>&1; then :
4788
4789else
4790  ac_cv_header_stdc=no
4791fi
4792rm -f conftest*
4793
4794fi
4795
4796if test $ac_cv_header_stdc = yes; then
4797  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
4798  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4799/* end confdefs.h.  */
4800#include <stdlib.h>
4801
4802_ACEOF
4803if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4804  $EGREP "free" >/dev/null 2>&1; then :
4805
4806else
4807  ac_cv_header_stdc=no
4808fi
4809rm -f conftest*
4810
4811fi
4812
4813if test $ac_cv_header_stdc = yes; then
4814  # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
4815  if test "$cross_compiling" = yes; then :
4816  :
4817else
4818  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4819/* end confdefs.h.  */
4820#include <ctype.h>
4821#include <stdlib.h>
4822#if ((' ' & 0x0FF) == 0x020)
4823# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4824# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4825#else
4826# define ISLOWER(c) \
4827		   (('a' <= (c) && (c) <= 'i') \
4828		     || ('j' <= (c) && (c) <= 'r') \
4829		     || ('s' <= (c) && (c) <= 'z'))
4830# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4831#endif
4832
4833#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4834int
4835main ()
4836{
4837  int i;
4838  for (i = 0; i < 256; i++)
4839    if (XOR (islower (i), ISLOWER (i))
4840	|| toupper (i) != TOUPPER (i))
4841      return 2;
4842  return 0;
4843}
4844_ACEOF
4845if ac_fn_c_try_run "$LINENO"; then :
4846
4847else
4848  ac_cv_header_stdc=no
4849fi
4850rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
4851  conftest.$ac_objext conftest.beam conftest.$ac_ext
4852fi
4853
4854fi
4855fi
4856{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
4857$as_echo "$ac_cv_header_stdc" >&6; }
4858if test $ac_cv_header_stdc = yes; then
4859
4860$as_echo "#define STDC_HEADERS 1" >>confdefs.h
4861
4862fi
4863
4864# On IRIX 5.3, sys/types and inttypes.h are conflicting.
4865for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
4866		  inttypes.h stdint.h unistd.h
4867do :
4868  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
4869ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
4870"
4871if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
4872  cat >>confdefs.h <<_ACEOF
4873#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
4874_ACEOF
4875
4876fi
4877
4878done
4879
4880
4881
4882
4883
4884  ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
4885if test "x$ac_cv_header_minix_config_h" = xyes; then :
4886  MINIX=yes
4887else
4888  MINIX=
4889fi
4890
4891
4892  if test "$MINIX" = yes; then
4893
4894$as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
4895
4896
4897$as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
4898
4899
4900$as_echo "#define _MINIX 1" >>confdefs.h
4901
4902  fi
4903
4904        case "$host_os" in
4905    hpux*)
4906
4907$as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h
4908
4909      ;;
4910  esac
4911
4912
4913  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
4914$as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
4915if ${ac_cv_safe_to_define___extensions__+:} false; then :
4916  $as_echo_n "(cached) " >&6
4917else
4918  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4919/* end confdefs.h.  */
4920
4921#         define __EXTENSIONS__ 1
4922          $ac_includes_default
4923int
4924main ()
4925{
4926
4927  ;
4928  return 0;
4929}
4930_ACEOF
4931if ac_fn_c_try_compile "$LINENO"; then :
4932  ac_cv_safe_to_define___extensions__=yes
4933else
4934  ac_cv_safe_to_define___extensions__=no
4935fi
4936rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4937fi
4938{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
4939$as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
4940  test $ac_cv_safe_to_define___extensions__ = yes &&
4941    $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
4942
4943  $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
4944
4945  $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
4946
4947  $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
4948
4949  $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
4950
4951
4952
4953   case $ac_cv_prog_cc_stdc in #(
4954  no) :
4955    ac_cv_prog_cc_c99=no; ac_cv_prog_cc_c89=no ;; #(
4956  *) :
4957    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5
4958$as_echo_n "checking for $CC option to accept ISO C99... " >&6; }
4959if ${ac_cv_prog_cc_c99+:} false; then :
4960  $as_echo_n "(cached) " >&6
4961else
4962  ac_cv_prog_cc_c99=no
4963ac_save_CC=$CC
4964cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4965/* end confdefs.h.  */
4966#include <stdarg.h>
4967#include <stdbool.h>
4968#include <stdlib.h>
4969#include <wchar.h>
4970#include <stdio.h>
4971
4972// Check varargs macros.  These examples are taken from C99 6.10.3.5.
4973#define debug(...) fprintf (stderr, __VA_ARGS__)
4974#define showlist(...) puts (#__VA_ARGS__)
4975#define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
4976static void
4977test_varargs_macros (void)
4978{
4979  int x = 1234;
4980  int y = 5678;
4981  debug ("Flag");
4982  debug ("X = %d\n", x);
4983  showlist (The first, second, and third items.);
4984  report (x>y, "x is %d but y is %d", x, y);
4985}
4986
4987// Check long long types.
4988#define BIG64 18446744073709551615ull
4989#define BIG32 4294967295ul
4990#define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
4991#if !BIG_OK
4992  your preprocessor is broken;
4993#endif
4994#if BIG_OK
4995#else
4996  your preprocessor is broken;
4997#endif
4998static long long int bignum = -9223372036854775807LL;
4999static unsigned long long int ubignum = BIG64;
5000
5001struct incomplete_array
5002{
5003  int datasize;
5004  double data[];
5005};
5006
5007struct named_init {
5008  int number;
5009  const wchar_t *name;
5010  double average;
5011};
5012
5013typedef const char *ccp;
5014
5015static inline int
5016test_restrict (ccp restrict text)
5017{
5018  // See if C++-style comments work.
5019  // Iterate through items via the restricted pointer.
5020  // Also check for declarations in for loops.
5021  for (unsigned int i = 0; *(text+i) != '\0'; ++i)
5022    continue;
5023  return 0;
5024}
5025
5026// Check varargs and va_copy.
5027static void
5028test_varargs (const char *format, ...)
5029{
5030  va_list args;
5031  va_start (args, format);
5032  va_list args_copy;
5033  va_copy (args_copy, args);
5034
5035  const char *str;
5036  int number;
5037  float fnumber;
5038
5039  while (*format)
5040    {
5041      switch (*format++)
5042	{
5043	case 's': // string
5044	  str = va_arg (args_copy, const char *);
5045	  break;
5046	case 'd': // int
5047	  number = va_arg (args_copy, int);
5048	  break;
5049	case 'f': // float
5050	  fnumber = va_arg (args_copy, double);
5051	  break;
5052	default:
5053	  break;
5054	}
5055    }
5056  va_end (args_copy);
5057  va_end (args);
5058}
5059
5060int
5061main ()
5062{
5063
5064  // Check bool.
5065  _Bool success = false;
5066
5067  // Check restrict.
5068  if (test_restrict ("String literal") == 0)
5069    success = true;
5070  char *restrict newvar = "Another string";
5071
5072  // Check varargs.
5073  test_varargs ("s, d' f .", "string", 65, 34.234);
5074  test_varargs_macros ();
5075
5076  // Check flexible array members.
5077  struct incomplete_array *ia =
5078    malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
5079  ia->datasize = 10;
5080  for (int i = 0; i < ia->datasize; ++i)
5081    ia->data[i] = i * 1.234;
5082
5083  // Check named initializers.
5084  struct named_init ni = {
5085    .number = 34,
5086    .name = L"Test wide string",
5087    .average = 543.34343,
5088  };
5089
5090  ni.number = 58;
5091
5092  int dynamic_array[ni.number];
5093  dynamic_array[ni.number - 1] = 543;
5094
5095  // work around unused variable warnings
5096  return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
5097	  || dynamic_array[ni.number - 1] != 543);
5098
5099  ;
5100  return 0;
5101}
5102_ACEOF
5103for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -D_STDC_C99= -qlanglvl=extc99
5104do
5105  CC="$ac_save_CC $ac_arg"
5106  if ac_fn_c_try_compile "$LINENO"; then :
5107  ac_cv_prog_cc_c99=$ac_arg
5108fi
5109rm -f core conftest.err conftest.$ac_objext
5110  test "x$ac_cv_prog_cc_c99" != "xno" && break
5111done
5112rm -f conftest.$ac_ext
5113CC=$ac_save_CC
5114
5115fi
5116# AC_CACHE_VAL
5117case "x$ac_cv_prog_cc_c99" in
5118  x)
5119    { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5120$as_echo "none needed" >&6; } ;;
5121  xno)
5122    { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5123$as_echo "unsupported" >&6; } ;;
5124  *)
5125    CC="$CC $ac_cv_prog_cc_c99"
5126    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
5127$as_echo "$ac_cv_prog_cc_c99" >&6; } ;;
5128esac
5129if test "x$ac_cv_prog_cc_c99" != xno; then :
5130  ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
5131else
5132  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
5133$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
5134if ${ac_cv_prog_cc_c89+:} false; then :
5135  $as_echo_n "(cached) " >&6
5136else
5137  ac_cv_prog_cc_c89=no
5138ac_save_CC=$CC
5139cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5140/* end confdefs.h.  */
5141#include <stdarg.h>
5142#include <stdio.h>
5143struct stat;
5144/* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
5145struct buf { int x; };
5146FILE * (*rcsopen) (struct buf *, struct stat *, int);
5147static char *e (p, i)
5148     char **p;
5149     int i;
5150{
5151  return p[i];
5152}
5153static char *f (char * (*g) (char **, int), char **p, ...)
5154{
5155  char *s;
5156  va_list v;
5157  va_start (v,p);
5158  s = g (p, va_arg (v,int));
5159  va_end (v);
5160  return s;
5161}
5162
5163/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
5164   function prototypes and stuff, but not '\xHH' hex character constants.
5165   These don't provoke an error unfortunately, instead are silently treated
5166   as 'x'.  The following induces an error, until -std is added to get
5167   proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
5168   array size at least.  It's necessary to write '\x00'==0 to get something
5169   that's true only with -std.  */
5170int osf4_cc_array ['\x00' == 0 ? 1 : -1];
5171
5172/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
5173   inside strings and character constants.  */
5174#define FOO(x) 'x'
5175int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
5176
5177int test (int i, double x);
5178struct s1 {int (*f) (int a);};
5179struct s2 {int (*f) (double a);};
5180int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
5181int argc;
5182char **argv;
5183int
5184main ()
5185{
5186return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
5187  ;
5188  return 0;
5189}
5190_ACEOF
5191for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5192	-Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5193do
5194  CC="$ac_save_CC $ac_arg"
5195  if ac_fn_c_try_compile "$LINENO"; then :
5196  ac_cv_prog_cc_c89=$ac_arg
5197fi
5198rm -f core conftest.err conftest.$ac_objext
5199  test "x$ac_cv_prog_cc_c89" != "xno" && break
5200done
5201rm -f conftest.$ac_ext
5202CC=$ac_save_CC
5203
5204fi
5205# AC_CACHE_VAL
5206case "x$ac_cv_prog_cc_c89" in
5207  x)
5208    { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5209$as_echo "none needed" >&6; } ;;
5210  xno)
5211    { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5212$as_echo "unsupported" >&6; } ;;
5213  *)
5214    CC="$CC $ac_cv_prog_cc_c89"
5215    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5216$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
5217esac
5218if test "x$ac_cv_prog_cc_c89" != xno; then :
5219  ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
5220else
5221  ac_cv_prog_cc_stdc=no
5222fi
5223
5224fi
5225 ;;
5226esac
5227  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO Standard C" >&5
5228$as_echo_n "checking for $CC option to accept ISO Standard C... " >&6; }
5229  if ${ac_cv_prog_cc_stdc+:} false; then :
5230  $as_echo_n "(cached) " >&6
5231fi
5232
5233  case $ac_cv_prog_cc_stdc in #(
5234  no) :
5235    { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5236$as_echo "unsupported" >&6; } ;; #(
5237  '') :
5238    { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5239$as_echo "none needed" >&6; } ;; #(
5240  *) :
5241    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_stdc" >&5
5242$as_echo "$ac_cv_prog_cc_stdc" >&6; } ;;
5243esac
5244
5245
5246
5247
5248
5249# Ralf Wildenhues: With per-target flags we need CC_C_O
5250# AM_PROG_CC_C_O supersets AC_PROG_CC_C_O
5251
5252if test $ac_cv_c_compiler_gnu = yes; then
5253    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC needs -traditional" >&5
5254$as_echo_n "checking whether $CC needs -traditional... " >&6; }
5255if ${ac_cv_prog_gcc_traditional+:} false; then :
5256  $as_echo_n "(cached) " >&6
5257else
5258    ac_pattern="Autoconf.*'x'"
5259  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5260/* end confdefs.h.  */
5261#include <sgtty.h>
5262Autoconf TIOCGETP
5263_ACEOF
5264if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5265  $EGREP "$ac_pattern" >/dev/null 2>&1; then :
5266  ac_cv_prog_gcc_traditional=yes
5267else
5268  ac_cv_prog_gcc_traditional=no
5269fi
5270rm -f conftest*
5271
5272
5273  if test $ac_cv_prog_gcc_traditional = no; then
5274    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5275/* end confdefs.h.  */
5276#include <termio.h>
5277Autoconf TCGETA
5278_ACEOF
5279if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5280  $EGREP "$ac_pattern" >/dev/null 2>&1; then :
5281  ac_cv_prog_gcc_traditional=yes
5282fi
5283rm -f conftest*
5284
5285  fi
5286fi
5287{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_gcc_traditional" >&5
5288$as_echo "$ac_cv_prog_gcc_traditional" >&6; }
5289  if test $ac_cv_prog_gcc_traditional = yes; then
5290    CC="$CC -traditional"
5291  fi
5292fi
5293
5294
5295
5296CFLAGS_NTP=
5297CPPFLAGS_NTP=
5298LDADD_NTP=
5299LDFLAGS_NTP=
5300
5301
5302
5303
5304
5305case "$ac_cv_prog_cc_c89" in
5306 no)
5307    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ANSI C89/ISO C90 is the minimum to compile NTP
5308		 version 4.2.5 and higher." >&5
5309$as_echo "$as_me: WARNING: ANSI C89/ISO C90 is the minimum to compile NTP
5310		 version 4.2.5 and higher." >&2;}
5311    ;;
5312esac
5313
5314{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC can handle #warning" >&5
5315$as_echo_n "checking if $CC can handle #warning... " >&6; }
5316if ${ntp_cv_cpp_warning+:} false; then :
5317  $as_echo_n "(cached) " >&6
5318else
5319  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5320/* end confdefs.h.  */
5321
5322int
5323main ()
5324{
5325#warning foo
5326  ;
5327  return 0;
5328}
5329_ACEOF
5330if ac_fn_c_try_compile "$LINENO"; then :
5331  ntp_cv_cpp_warning=yes
5332else
5333  ntp_cv_cpp_warning=no
5334
5335fi
5336rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5337
5338fi
5339{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_cpp_warning" >&5
5340$as_echo "$ntp_cv_cpp_warning" >&6; }
5341case "$ntp_cv_cpp_warning" in
5342 no)
5343
5344$as_echo "#define NO_OPTION_NAME_WARNINGS 1" >>confdefs.h
5345
5346esac
5347
5348{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC supports __attribute__((...))" >&5
5349$as_echo_n "checking if $CC supports __attribute__((...))... " >&6; }
5350if ${ntp_cv_cc_attribute+:} false; then :
5351  $as_echo_n "(cached) " >&6
5352else
5353  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5354/* end confdefs.h.  */
5355
5356int
5357main ()
5358{
5359void foo(void) __attribute__((__noreturn__));
5360
5361  ;
5362  return 0;
5363}
5364_ACEOF
5365if ac_fn_c_try_compile "$LINENO"; then :
5366  ntp_cv_cc_attribute=yes
5367else
5368  ntp_cv_cc_attribute=no
5369
5370fi
5371rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5372
5373fi
5374{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_cc_attribute" >&5
5375$as_echo "$ntp_cv_cc_attribute" >&6; }
5376case "$ntp_cv_cc_attribute" in
5377 yes)
5378
5379$as_echo "#define HAVE___ATTRIBUTE__ /**/" >>confdefs.h
5380
5381esac
5382
5383
5384case "$GCC" in
5385 yes)
5386    SAVED_CFLAGS="$CFLAGS"
5387    CFLAGS="$CFLAGS -Wstrict-overflow"
5388    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC can handle -Wstrict-overflow" >&5
5389$as_echo_n "checking if $CC can handle -Wstrict-overflow... " >&6; }
5390if ${ntp_cv_gcc_Wstrict_overflow+:} false; then :
5391  $as_echo_n "(cached) " >&6
5392else
5393  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5394/* end confdefs.h.  */
5395
5396int
5397main ()
5398{
5399
5400  ;
5401  return 0;
5402}
5403_ACEOF
5404if ac_fn_c_try_compile "$LINENO"; then :
5405  ntp_cv_gcc_Wstrict_overflow=yes
5406else
5407  ntp_cv_gcc_Wstrict_overflow=no
5408
5409fi
5410rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5411
5412fi
5413{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_gcc_Wstrict_overflow" >&5
5414$as_echo "$ntp_cv_gcc_Wstrict_overflow" >&6; }
5415    #
5416    # $ntp_cv_gcc_Wstrict_overflow is tested later to add the
5417    # flag to CFLAGS.
5418    #
5419    CFLAGS="$SAVED_CFLAGS -Winit-self"
5420    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC can handle -Winit-self" >&5
5421$as_echo_n "checking if $CC can handle -Winit-self... " >&6; }
5422if ${ntp_cv_gcc_Winit_self+:} false; then :
5423  $as_echo_n "(cached) " >&6
5424else
5425
5426	    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5427/* end confdefs.h.  */
5428
5429int
5430main ()
5431{
5432
5433  ;
5434  return 0;
5435}
5436_ACEOF
5437if ac_fn_c_try_compile "$LINENO"; then :
5438  ntp_cv_gcc_Winit_self=yes
5439else
5440  ntp_cv_gcc_Winit_self=no
5441
5442fi
5443rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5444
5445
5446fi
5447{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_gcc_Winit_self" >&5
5448$as_echo "$ntp_cv_gcc_Winit_self" >&6; }
5449    CFLAGS="$SAVED_CFLAGS"
5450    { SAVED_CFLAGS=; unset SAVED_CFLAGS;}
5451    #
5452    # $ntp_cv_gcc_Winit_self is tested later to add the
5453    # flag to CFLAGS_NTP.
5454    #
5455    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linker supports omitting unused code and data" >&5
5456$as_echo_n "checking if linker supports omitting unused code and data... " >&6; }
5457if ${ntp_cv_gc_sections_runs+:} false; then :
5458  $as_echo_n "(cached) " >&6
5459else
5460
5461	    	    	    	    	    	    	    	    	    	    	    origCFLAGS="$CFLAGS"
5462	    CFLAGS="$CFLAGS -Wl,--gc-sections"
5463	    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5464/* end confdefs.h.  */
5465
5466			#include <stdlib.h>
5467			#include <stdio.h>
5468
5469int
5470main ()
5471{
5472
5473			FILE *	fpC;
5474			char	buf[32];
5475			size_t	cch;
5476			int	read_success_once;
5477
5478			fpC = fopen("conftest.c", "r");
5479			if (NULL == fpC)
5480				exit(1);
5481			do {
5482				cch = fread(buf, sizeof(buf), 1, fpC);
5483				read_success_once |= (0 != cch);
5484			} while (0 != cch);
5485			if (!read_success_once)
5486				exit(2);
5487			if (!feof(fpC))
5488				exit(3);
5489			if (0 != fclose(fpC))
5490				exit(4);
5491
5492			exit(EXIT_SUCCESS);
5493
5494
5495  ;
5496  return 0;
5497}
5498_ACEOF
5499if ac_fn_c_try_link "$LINENO"; then :
5500
5501		    if test "X$cross_compiling" = "Xyes" || grep gc-sections conftest.err ; then
5502			ntp_cv_gc_sections_runs=no
5503		    else
5504			ntp_cv_gc_sections_runs=no
5505			./conftest >/dev/null 2>&1 && ntp_cv_gc_sections_runs=yes
5506		    fi
5507
5508else
5509  ntp_cv_gc_sections_runs=no
5510
5511fi
5512rm -f core conftest.err conftest.$ac_objext \
5513    conftest$ac_exeext conftest.$ac_ext
5514	    CFLAGS="$origCFLAGS"
5515	    { origCFLAGS=; unset origCFLAGS;}
5516
5517
5518fi
5519{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_gc_sections_runs" >&5
5520$as_echo "$ntp_cv_gc_sections_runs" >&6; }
5521    case "$ntp_cv_gc_sections_runs" in
5522     yes)
5523	LDADD_LIBNTP="-Wl,--gc-sections"
5524	CFLAGS_NTP="$CFLAGS_NTP -ffunction-sections -fdata-sections"
5525	;;
5526     no)
5527	LDADD_LIBNTP=
5528	;;
5529    esac
5530    CFLAGS_NTP="$CFLAGS_NTP -Wall"
5531    CFLAGS_NTP="$CFLAGS_NTP -Wcast-align"
5532    CFLAGS_NTP="$CFLAGS_NTP -Wcast-qual"
5533    # CFLAGS_NTP="$CFLAGS_NTP -Wconversion"
5534    # CFLAGS_NTP="$CFLAGS_NTP -Werror"
5535    # CFLAGS_NTP="$CFLAGS_NTP -Wextra"
5536    # CFLAGS_NTP="$CFLAGS_NTP -Wfloat-equal"
5537    CFLAGS_NTP="$CFLAGS_NTP -Wmissing-prototypes"
5538    CFLAGS_NTP="$CFLAGS_NTP -Wpointer-arith"
5539    CFLAGS_NTP="$CFLAGS_NTP -Wshadow"
5540    # CFLAGS_NTP="$CFLAGS_NTP -Wtraditional"
5541    # CFLAGS_NTP="$CFLAGS_NTP -Wwrite-strings"
5542    case "$ntp_cv_gcc_Winit_self" in
5543     yes)
5544	CFLAGS_NTP="$CFLAGS_NTP -Winit-self"
5545    esac
5546    case "$ntp_cv_gcc_Wstrict_overflow" in
5547     yes)
5548	CFLAGS_NTP="$CFLAGS_NTP -Wstrict-overflow"
5549    esac
5550    # -W[no-]strict-prototypes might be added by NTP_OPENSSL
5551esac
5552
5553
5554    { $as_echo "$as_me:${as_lineno-$LINENO}: checking additional compiler flags" >&5
5555$as_echo_n "checking additional compiler flags... " >&6; }
5556    # allow ntp_os_cflags to be preset to skip this stuff
5557    case "${ntp_os_cflags+set}" in
5558     set)
5559	;;
5560     *)
5561	ntp_os_cflags=
5562	case "$host_os" in
5563	 aix[1-3]*)
5564	    ;;
5565	 aix4.[0-2]*)
5566	    # turn on additional headers
5567	    ntp_os_cflags="-D_XOPEN_EXTENDED_SOURCE"
5568	    ;;
5569	 aix5.3*)
5570	    # avoid circular dependencies in yp headers, and more
5571	    ntp_os_cflags="-DHAVE_BAD_HEADERS -D_XOPEN_EXTENDED_SOURCE"
5572	    ntp_os_cflags="${ntp_os_cflags} -D_USE_IRS -D_MSGQSUPPORT"
5573	    ;;
5574	 aix*)
5575	    # XXX Only verified thru AIX6.
5576	    # aix7 seems to need a different XOPEN_SOURCE_EXTENDED thing.
5577	    # avoid circular dependencies in yp headers
5578	    # _XOPEN_SOURCE=500 = X/Open 5: POSIX 1995
5579	    # _XOPEN_SOURCE=600 = X/Open 6: POSIX 2004
5580	    # _XOPEN_SOURCE=700 = X/Open 7: POSIX 2008
5581	    ntp_os_cflags="-DHAVE_BAD_HEADERS -D_XOPEN_SOURCE=600"
5582	    ntp_os_cflags="${ntp_os_cflags} -D_USE_IRS"
5583	    ;;
5584	 amigaos)
5585	    ntp_os_cflags="-DSYS_AMIGA"
5586	    ;;
5587	 darwin*|macosx*|rhapsody*)
5588	    ntp_os_cflags="-D_P1003_1B_VISIBLE"
5589	    ;;
5590	 hpux10.*)		# at least for hppa2.0-hp-hpux10.20
5591	    case "$GCC" in
5592	     yes)
5593		;;
5594	     *)
5595		# use Ansi compiler on HPUX, and some -Wp magic
5596		ntp_os_cflags="-Ae -Wp,-H18816"
5597		;;
5598	    esac
5599	    ntp_os_cflags="${ntp_os_cflags} -D_HPUX_SOURCE -D__STDC_VERSION__=199901L"
5600	    ;;
5601	 hpux*)
5602	    case "$GCC" in
5603	     yes)
5604		;;
5605	     *)
5606		# use Ansi compiler on HPUX
5607		ntp_os_cflags="-Ae"
5608	    esac
5609	    ntp_os_cflags="${ntp_os_cflags} -D_HPUX_SOURCE -D__STDC_VERSION__=199901L"
5610	    ;;
5611	 irix6*)
5612	    case "$CC" in
5613	     cc)
5614		# do not use 64-bit compiler
5615		ntp_os_cflags="-n32 -mips3 -Wl,-woff,84"
5616	    esac
5617	    ;;
5618	 nextstep3)
5619	    ntp_os_cflags="-posix"
5620	    ;;
5621	 solaris1*|solaris2.[0-5]|solaris2.5.*)
5622	    ;;
5623	 sunos[34]*|sunos5.[0-5]|sunos5.5.*)
5624	    ;;
5625	 solaris2*|sunos5*)
5626	    # turn on 64-bit file offset interface
5627	    ntp_os_cflags="-D_LARGEFILE64_SOURCE"
5628	    ;;
5629	 vxworks*)
5630	    case "$build" in
5631	     $host)
5632		;;
5633	     *)
5634		# Quick and dirty sanity check
5635		case "$VX_KERNEL" in
5636		 '')
5637		    as_fn_error $? "See html/build/hints/vxworks.html" "$LINENO" 5
5638		esac
5639		ntp_os_cflags="-DSYS_VXWORKS"
5640	    esac
5641	    ;;
5642	esac
5643    esac
5644    case "$ntp_os_cflags" in
5645     '')
5646	ntp_os_cflags_msg="none needed"
5647	;;
5648     *)
5649	ntp_os_cflags_msg="$ntp_os_cflags"
5650    esac
5651    CFLAGS_NTP="$CFLAGS_NTP $ntp_os_cflags"
5652    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_os_cflags_msg" >&5
5653$as_echo "$ntp_os_cflags_msg" >&6; }
5654    { ntp_os_cflags_msg=; unset ntp_os_cflags_msg;}
5655    ###
5656    { $as_echo "$as_me:${as_lineno-$LINENO}: checking additional linker flags" >&5
5657$as_echo_n "checking additional linker flags... " >&6; }
5658    # HMS: The following might still need tweaking
5659    # allow ntp_os_ldflags to be preset to skip this stuff
5660    case "${ntp_os_ldflags+set}" in
5661     set)
5662	;;
5663     *)
5664	ntp_os_ldflags=
5665	case "$host_os" in
5666	 hpux*)
5667	    case "$GCC" in
5668	     yes)
5669		ntp_os_ldflags="-Wl,+allowdups"
5670		;;
5671	    esac
5672	    ;;
5673	esac
5674	;;
5675    esac
5676    case "$ntp_os_ldflags" in
5677     '')
5678	ntp_os_ldflags_msg="none needed"
5679	;;
5680     *)
5681	ntp_os_ldflags_msg="$ntp_os_ldflags"
5682    esac
5683    LDFLAGS_NTP="$LDFLAGS_NTP $ntp_os_ldflags"
5684    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_os_ldflags_msg" >&5
5685$as_echo "$ntp_os_ldflags_msg" >&6; }
5686    { ntp_os_ldflags_msg=; unset ntp_os_ldflags_msg;}
5687
5688
5689 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
5690$as_echo_n "checking whether byte ordering is bigendian... " >&6; }
5691if ${ac_cv_c_bigendian+:} false; then :
5692  $as_echo_n "(cached) " >&6
5693else
5694  ac_cv_c_bigendian=unknown
5695    # See if we're dealing with a universal compiler.
5696    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5697/* end confdefs.h.  */
5698#ifndef __APPLE_CC__
5699	       not a universal capable compiler
5700	     #endif
5701	     typedef int dummy;
5702
5703_ACEOF
5704if ac_fn_c_try_compile "$LINENO"; then :
5705
5706	# Check for potential -arch flags.  It is not universal unless
5707	# there are at least two -arch flags with different values.
5708	ac_arch=
5709	ac_prev=
5710	for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
5711	 if test -n "$ac_prev"; then
5712	   case $ac_word in
5713	     i?86 | x86_64 | ppc | ppc64)
5714	       if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
5715		 ac_arch=$ac_word
5716	       else
5717		 ac_cv_c_bigendian=universal
5718		 break
5719	       fi
5720	       ;;
5721	   esac
5722	   ac_prev=
5723	 elif test "x$ac_word" = "x-arch"; then
5724	   ac_prev=arch
5725	 fi
5726       done
5727fi
5728rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5729    if test $ac_cv_c_bigendian = unknown; then
5730      # See if sys/param.h defines the BYTE_ORDER macro.
5731      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5732/* end confdefs.h.  */
5733#include <sys/types.h>
5734	     #include <sys/param.h>
5735
5736int
5737main ()
5738{
5739#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
5740		     && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
5741		     && LITTLE_ENDIAN)
5742	      bogus endian macros
5743	     #endif
5744
5745  ;
5746  return 0;
5747}
5748_ACEOF
5749if ac_fn_c_try_compile "$LINENO"; then :
5750  # It does; now see whether it defined to BIG_ENDIAN or not.
5751	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5752/* end confdefs.h.  */
5753#include <sys/types.h>
5754		#include <sys/param.h>
5755
5756int
5757main ()
5758{
5759#if BYTE_ORDER != BIG_ENDIAN
5760		 not big endian
5761		#endif
5762
5763  ;
5764  return 0;
5765}
5766_ACEOF
5767if ac_fn_c_try_compile "$LINENO"; then :
5768  ac_cv_c_bigendian=yes
5769else
5770  ac_cv_c_bigendian=no
5771fi
5772rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5773fi
5774rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5775    fi
5776    if test $ac_cv_c_bigendian = unknown; then
5777      # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
5778      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5779/* end confdefs.h.  */
5780#include <limits.h>
5781
5782int
5783main ()
5784{
5785#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
5786	      bogus endian macros
5787	     #endif
5788
5789  ;
5790  return 0;
5791}
5792_ACEOF
5793if ac_fn_c_try_compile "$LINENO"; then :
5794  # It does; now see whether it defined to _BIG_ENDIAN or not.
5795	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5796/* end confdefs.h.  */
5797#include <limits.h>
5798
5799int
5800main ()
5801{
5802#ifndef _BIG_ENDIAN
5803		 not big endian
5804		#endif
5805
5806  ;
5807  return 0;
5808}
5809_ACEOF
5810if ac_fn_c_try_compile "$LINENO"; then :
5811  ac_cv_c_bigendian=yes
5812else
5813  ac_cv_c_bigendian=no
5814fi
5815rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5816fi
5817rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5818    fi
5819    if test $ac_cv_c_bigendian = unknown; then
5820      # Compile a test program.
5821      if test "$cross_compiling" = yes; then :
5822  # Try to guess by grepping values from an object file.
5823	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5824/* end confdefs.h.  */
5825short int ascii_mm[] =
5826		  { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
5827		short int ascii_ii[] =
5828		  { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
5829		int use_ascii (int i) {
5830		  return ascii_mm[i] + ascii_ii[i];
5831		}
5832		short int ebcdic_ii[] =
5833		  { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
5834		short int ebcdic_mm[] =
5835		  { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
5836		int use_ebcdic (int i) {
5837		  return ebcdic_mm[i] + ebcdic_ii[i];
5838		}
5839		extern int foo;
5840
5841int
5842main ()
5843{
5844return use_ascii (foo) == use_ebcdic (foo);
5845  ;
5846  return 0;
5847}
5848_ACEOF
5849if ac_fn_c_try_compile "$LINENO"; then :
5850  if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
5851	      ac_cv_c_bigendian=yes
5852	    fi
5853	    if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
5854	      if test "$ac_cv_c_bigendian" = unknown; then
5855		ac_cv_c_bigendian=no
5856	      else
5857		# finding both strings is unlikely to happen, but who knows?
5858		ac_cv_c_bigendian=unknown
5859	      fi
5860	    fi
5861fi
5862rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5863else
5864  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5865/* end confdefs.h.  */
5866$ac_includes_default
5867int
5868main ()
5869{
5870
5871	     /* Are we little or big endian?  From Harbison&Steele.  */
5872	     union
5873	     {
5874	       long int l;
5875	       char c[sizeof (long int)];
5876	     } u;
5877	     u.l = 1;
5878	     return u.c[sizeof (long int) - 1] == 1;
5879
5880  ;
5881  return 0;
5882}
5883_ACEOF
5884if ac_fn_c_try_run "$LINENO"; then :
5885  ac_cv_c_bigendian=no
5886else
5887  ac_cv_c_bigendian=yes
5888fi
5889rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
5890  conftest.$ac_objext conftest.beam conftest.$ac_ext
5891fi
5892
5893    fi
5894fi
5895{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
5896$as_echo "$ac_cv_c_bigendian" >&6; }
5897 case $ac_cv_c_bigendian in #(
5898   yes)
5899     $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
5900;; #(
5901   no)
5902      ;; #(
5903   universal)
5904
5905$as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
5906
5907     ;; #(
5908   *)
5909     as_fn_error $? "unknown endianness
5910 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
5911 esac
5912
5913{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working volatile" >&5
5914$as_echo_n "checking for working volatile... " >&6; }
5915if ${ac_cv_c_volatile+:} false; then :
5916  $as_echo_n "(cached) " >&6
5917else
5918  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5919/* end confdefs.h.  */
5920
5921int
5922main ()
5923{
5924
5925volatile int x;
5926int * volatile y = (int *) 0;
5927return !x && !y;
5928  ;
5929  return 0;
5930}
5931_ACEOF
5932if ac_fn_c_try_compile "$LINENO"; then :
5933  ac_cv_c_volatile=yes
5934else
5935  ac_cv_c_volatile=no
5936fi
5937rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5938fi
5939{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_volatile" >&5
5940$as_echo "$ac_cv_c_volatile" >&6; }
5941if test $ac_cv_c_volatile = no; then
5942
5943$as_echo "#define volatile /**/" >>confdefs.h
5944
5945fi
5946
5947ac_ext=c
5948ac_cpp='$CPP $CPPFLAGS'
5949ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5950ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5951ac_compiler_gnu=$ac_cv_c_compiler_gnu
5952{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
5953$as_echo_n "checking how to run the C preprocessor... " >&6; }
5954# On Suns, sometimes $CPP names a directory.
5955if test -n "$CPP" && test -d "$CPP"; then
5956  CPP=
5957fi
5958if test -z "$CPP"; then
5959  if ${ac_cv_prog_CPP+:} false; then :
5960  $as_echo_n "(cached) " >&6
5961else
5962      # Double quotes because CPP needs to be expanded
5963    for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
5964    do
5965      ac_preproc_ok=false
5966for ac_c_preproc_warn_flag in '' yes
5967do
5968  # Use a header file that comes with gcc, so configuring glibc
5969  # with a fresh cross-compiler works.
5970  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5971  # <limits.h> exists even on freestanding compilers.
5972  # On the NeXT, cc -E runs the code through the compiler's parser,
5973  # not just through cpp. "Syntax error" is here to catch this case.
5974  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5975/* end confdefs.h.  */
5976#ifdef __STDC__
5977# include <limits.h>
5978#else
5979# include <assert.h>
5980#endif
5981		     Syntax error
5982_ACEOF
5983if ac_fn_c_try_cpp "$LINENO"; then :
5984
5985else
5986  # Broken: fails on valid input.
5987continue
5988fi
5989rm -f conftest.err conftest.i conftest.$ac_ext
5990
5991  # OK, works on sane cases.  Now check whether nonexistent headers
5992  # can be detected and how.
5993  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5994/* end confdefs.h.  */
5995#include <ac_nonexistent.h>
5996_ACEOF
5997if ac_fn_c_try_cpp "$LINENO"; then :
5998  # Broken: success on invalid input.
5999continue
6000else
6001  # Passes both tests.
6002ac_preproc_ok=:
6003break
6004fi
6005rm -f conftest.err conftest.i conftest.$ac_ext
6006
6007done
6008# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6009rm -f conftest.i conftest.err conftest.$ac_ext
6010if $ac_preproc_ok; then :
6011  break
6012fi
6013
6014    done
6015    ac_cv_prog_CPP=$CPP
6016
6017fi
6018  CPP=$ac_cv_prog_CPP
6019else
6020  ac_cv_prog_CPP=$CPP
6021fi
6022{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
6023$as_echo "$CPP" >&6; }
6024ac_preproc_ok=false
6025for ac_c_preproc_warn_flag in '' yes
6026do
6027  # Use a header file that comes with gcc, so configuring glibc
6028  # with a fresh cross-compiler works.
6029  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6030  # <limits.h> exists even on freestanding compilers.
6031  # On the NeXT, cc -E runs the code through the compiler's parser,
6032  # not just through cpp. "Syntax error" is here to catch this case.
6033  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6034/* end confdefs.h.  */
6035#ifdef __STDC__
6036# include <limits.h>
6037#else
6038# include <assert.h>
6039#endif
6040		     Syntax error
6041_ACEOF
6042if ac_fn_c_try_cpp "$LINENO"; then :
6043
6044else
6045  # Broken: fails on valid input.
6046continue
6047fi
6048rm -f conftest.err conftest.i conftest.$ac_ext
6049
6050  # OK, works on sane cases.  Now check whether nonexistent headers
6051  # can be detected and how.
6052  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6053/* end confdefs.h.  */
6054#include <ac_nonexistent.h>
6055_ACEOF
6056if ac_fn_c_try_cpp "$LINENO"; then :
6057  # Broken: success on invalid input.
6058continue
6059else
6060  # Passes both tests.
6061ac_preproc_ok=:
6062break
6063fi
6064rm -f conftest.err conftest.i conftest.$ac_ext
6065
6066done
6067# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6068rm -f conftest.i conftest.err conftest.$ac_ext
6069if $ac_preproc_ok; then :
6070
6071else
6072  { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
6073$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
6074as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
6075See \`config.log' for more details" "$LINENO" 5; }
6076fi
6077
6078ac_ext=c
6079ac_cpp='$CPP $CPPFLAGS'
6080ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6081ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6082ac_compiler_gnu=$ac_cv_c_compiler_gnu
6083
6084
6085
6086
6087
6088{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for compile/link hardening flags" >&5
6089$as_echo_n "checking for compile/link hardening flags... " >&6; }
6090
6091
6092# Check whether --with-locfile was given.
6093if test "${with_locfile+set}" = set; then :
6094  withval=$with_locfile;
6095else
6096  with_locfile=no
6097
6098fi
6099
6100
6101(									\
6102    SENTINEL_DIR="$PWD" &&						\
6103    cd $srcdir/ &&							\
6104    case "$with_locfile" in						\
6105     yes|no|'')								\
6106	scripts/genHardFlags -d "$SENTINEL_DIR"				\
6107	;;								\
6108     *)									\
6109	scripts/genHardFlags -d "$SENTINEL_DIR" -f "$with_locfile"	\
6110	;;								\
6111    esac								\
6112) > genHardFlags.i 2> genHardFlags.err
6113. ./genHardFlags.i
6114
6115case "$GENHARDFLAG" in
6116 OK)
6117    { $as_echo "$as_me:${as_lineno-$LINENO}: result: in file $GENHARDFLAGFILE" >&5
6118$as_echo "in file $GENHARDFLAGFILE" >&6; }
6119    rm genHardFlags.err genHardFlags.i
6120    ;;
6121 *)
6122    { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed." >&5
6123$as_echo "failed." >&6; }
6124    as_fn_error $? "Problem with genHardFlags!" "$LINENO" 5
6125    ;;
6126esac
6127
6128
6129
6130
6131
6132
6133
6134
6135
6136{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for install dir and man conventions" >&5
6137$as_echo_n "checking for install dir and man conventions... " >&6; }
6138
6139
6140# Check whether --with-locfile was given.
6141if test "${with_locfile+set}" = set; then :
6142  withval=$with_locfile;
6143else
6144  with_locfile=no
6145
6146fi
6147
6148
6149(									\
6150    SENTINEL_DIR="$PWD" &&						\
6151    cd $srcdir/ &&							\
6152    case "$with_locfile" in						\
6153     yes|no|'')								\
6154	scripts/genLocInfo -d "$SENTINEL_DIR"				\
6155	;;								\
6156     *)									\
6157	scripts/genLocInfo -d "$SENTINEL_DIR" -f "$with_locfile"	\
6158	;;								\
6159    esac								\
6160) > genLocInfo.i 2> genLocInfo.err
6161. ./genLocInfo.i
6162
6163case "$GENLOCINFO" in
6164 OK)
6165    { $as_echo "$as_me:${as_lineno-$LINENO}: result: in file $GENLOCINFOFILE" >&5
6166$as_echo "in file $GENLOCINFOFILE" >&6; }
6167    rm genLocInfo.err genLocInfo.i
6168    ;;
6169 *)
6170    { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed." >&5
6171$as_echo "failed." >&6; }
6172    as_fn_error $? "Problem with genLocInfo!" "$LINENO" 5
6173    ;;
6174esac
6175
6176 if test "$CALC_TICKADJ_MS" ; then
6177  WANT_CALC_TICKADJ_MS_TRUE=
6178  WANT_CALC_TICKADJ_MS_FALSE='#'
6179else
6180  WANT_CALC_TICKADJ_MS_TRUE='#'
6181  WANT_CALC_TICKADJ_MS_FALSE=
6182fi
6183
6184
6185
6186
6187
6188
6189
6190
6191
6192
6193
6194
6195
6196
6197
6198
6199
6200
6201
6202
6203
6204
6205
6206
6207
6208
6209
6210
6211
6212
6213
6214
6215
6216
6217
6218
6219
6220
6221
6222
6223
6224
6225
6226 if test -z "$NTPSWEEP_NI" ; then
6227  INSTALL_NTPSWEEP_TRUE=
6228  INSTALL_NTPSWEEP_FALSE='#'
6229else
6230  INSTALL_NTPSWEEP_TRUE='#'
6231  INSTALL_NTPSWEEP_FALSE=
6232fi
6233
6234
6235
6236
6237
6238
6239
6240
6241
6242
6243
6244
6245
6246
6247
6248
6249
6250
6251
6252
6253
6254
6255
6256
6257
6258
6259
6260
6261
6262
6263
6264
6265
6266
6267
6268
6269
6270
6271
6272
6273
6274 if test -z "$UPDATE_LEAP_NI" ; then
6275  INSTALL_UPDATE_LEAP_TRUE=
6276  INSTALL_UPDATE_LEAP_FALSE='#'
6277else
6278  INSTALL_UPDATE_LEAP_TRUE='#'
6279  INSTALL_UPDATE_LEAP_FALSE=
6280fi
6281
6282
6283
6284
6285if test -n "$ac_tool_prefix"; then
6286  for ac_prog in ar lib "link -lib"
6287  do
6288    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
6289set dummy $ac_tool_prefix$ac_prog; ac_word=$2
6290{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6291$as_echo_n "checking for $ac_word... " >&6; }
6292if ${ac_cv_prog_AR+:} false; then :
6293  $as_echo_n "(cached) " >&6
6294else
6295  if test -n "$AR"; then
6296  ac_cv_prog_AR="$AR" # Let the user override the test.
6297else
6298as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6299for as_dir in $PATH
6300do
6301  IFS=$as_save_IFS
6302  test -z "$as_dir" && as_dir=.
6303    for ac_exec_ext in '' $ac_executable_extensions; do
6304  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6305    ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
6306    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6307    break 2
6308  fi
6309done
6310  done
6311IFS=$as_save_IFS
6312
6313fi
6314fi
6315AR=$ac_cv_prog_AR
6316if test -n "$AR"; then
6317  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
6318$as_echo "$AR" >&6; }
6319else
6320  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6321$as_echo "no" >&6; }
6322fi
6323
6324
6325    test -n "$AR" && break
6326  done
6327fi
6328if test -z "$AR"; then
6329  ac_ct_AR=$AR
6330  for ac_prog in ar lib "link -lib"
6331do
6332  # Extract the first word of "$ac_prog", so it can be a program name with args.
6333set dummy $ac_prog; ac_word=$2
6334{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6335$as_echo_n "checking for $ac_word... " >&6; }
6336if ${ac_cv_prog_ac_ct_AR+:} false; then :
6337  $as_echo_n "(cached) " >&6
6338else
6339  if test -n "$ac_ct_AR"; then
6340  ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
6341else
6342as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6343for as_dir in $PATH
6344do
6345  IFS=$as_save_IFS
6346  test -z "$as_dir" && as_dir=.
6347    for ac_exec_ext in '' $ac_executable_extensions; do
6348  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6349    ac_cv_prog_ac_ct_AR="$ac_prog"
6350    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6351    break 2
6352  fi
6353done
6354  done
6355IFS=$as_save_IFS
6356
6357fi
6358fi
6359ac_ct_AR=$ac_cv_prog_ac_ct_AR
6360if test -n "$ac_ct_AR"; then
6361  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
6362$as_echo "$ac_ct_AR" >&6; }
6363else
6364  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6365$as_echo "no" >&6; }
6366fi
6367
6368
6369  test -n "$ac_ct_AR" && break
6370done
6371
6372  if test "x$ac_ct_AR" = x; then
6373    AR="false"
6374  else
6375    case $cross_compiling:$ac_tool_warned in
6376yes:)
6377{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6378$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6379ac_tool_warned=yes ;;
6380esac
6381    AR=$ac_ct_AR
6382  fi
6383fi
6384
6385: ${AR=ar}
6386
6387{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the archiver ($AR) interface" >&5
6388$as_echo_n "checking the archiver ($AR) interface... " >&6; }
6389if ${am_cv_ar_interface+:} false; then :
6390  $as_echo_n "(cached) " >&6
6391else
6392  ac_ext=c
6393ac_cpp='$CPP $CPPFLAGS'
6394ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6395ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6396ac_compiler_gnu=$ac_cv_c_compiler_gnu
6397
6398   am_cv_ar_interface=ar
6399   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6400/* end confdefs.h.  */
6401int some_variable = 0;
6402_ACEOF
6403if ac_fn_c_try_compile "$LINENO"; then :
6404  am_ar_try='$AR cru libconftest.a conftest.$ac_objext >&5'
6405      { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$am_ar_try\""; } >&5
6406  (eval $am_ar_try) 2>&5
6407  ac_status=$?
6408  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
6409  test $ac_status = 0; }
6410      if test "$ac_status" -eq 0; then
6411        am_cv_ar_interface=ar
6412      else
6413        am_ar_try='$AR -NOLOGO -OUT:conftest.lib conftest.$ac_objext >&5'
6414        { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$am_ar_try\""; } >&5
6415  (eval $am_ar_try) 2>&5
6416  ac_status=$?
6417  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
6418  test $ac_status = 0; }
6419        if test "$ac_status" -eq 0; then
6420          am_cv_ar_interface=lib
6421        else
6422          am_cv_ar_interface=unknown
6423        fi
6424      fi
6425      rm -f conftest.lib libconftest.a
6426
6427fi
6428rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6429   ac_ext=c
6430ac_cpp='$CPP $CPPFLAGS'
6431ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6432ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6433ac_compiler_gnu=$ac_cv_c_compiler_gnu
6434
6435fi
6436{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_ar_interface" >&5
6437$as_echo "$am_cv_ar_interface" >&6; }
6438
6439case $am_cv_ar_interface in
6440ar)
6441  ;;
6442lib)
6443  # Microsoft lib, so override with the ar-lib wrapper script.
6444  # FIXME: It is wrong to rewrite AR.
6445  # But if we don't then we get into trouble of one sort or another.
6446  # A longer-term fix would be to have automake use am__AR in this case,
6447  # and then we could set am__AR="$am_aux_dir/ar-lib \$(AR)" or something
6448  # similar.
6449  AR="$am_aux_dir/ar-lib $AR"
6450  ;;
6451unknown)
6452  as_fn_error $? "could not determine $AR interface" "$LINENO" 5
6453  ;;
6454esac
6455
6456
6457
6458
6459
6460# Expose a cross-compilation indicator to makefiles
6461 if test $build != $host; then
6462  NTP_CROSSCOMPILE_TRUE=
6463  NTP_CROSSCOMPILE_FALSE='#'
6464else
6465  NTP_CROSSCOMPILE_TRUE='#'
6466  NTP_CROSSCOMPILE_FALSE=
6467fi
6468
6469
6470
6471{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
6472$as_echo_n "checking for a sed that does not truncate output... " >&6; }
6473if ${ac_cv_path_SED+:} false; then :
6474  $as_echo_n "(cached) " >&6
6475else
6476            ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
6477     for ac_i in 1 2 3 4 5 6 7; do
6478       ac_script="$ac_script$as_nl$ac_script"
6479     done
6480     echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
6481     { ac_script=; unset ac_script;}
6482     if test -z "$SED"; then
6483  ac_path_SED_found=false
6484  # Loop through the user's path and test for each of PROGNAME-LIST
6485  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6486for as_dir in $PATH
6487do
6488  IFS=$as_save_IFS
6489  test -z "$as_dir" && as_dir=.
6490    for ac_prog in sed gsed; do
6491    for ac_exec_ext in '' $ac_executable_extensions; do
6492      ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
6493      as_fn_executable_p "$ac_path_SED" || continue
6494# Check for GNU ac_path_SED and select it if it is found.
6495  # Check for GNU $ac_path_SED
6496case `"$ac_path_SED" --version 2>&1` in
6497*GNU*)
6498  ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
6499*)
6500  ac_count=0
6501  $as_echo_n 0123456789 >"conftest.in"
6502  while :
6503  do
6504    cat "conftest.in" "conftest.in" >"conftest.tmp"
6505    mv "conftest.tmp" "conftest.in"
6506    cp "conftest.in" "conftest.nl"
6507    $as_echo '' >> "conftest.nl"
6508    "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
6509    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
6510    as_fn_arith $ac_count + 1 && ac_count=$as_val
6511    if test $ac_count -gt ${ac_path_SED_max-0}; then
6512      # Best one so far, save it but keep looking for a better one
6513      ac_cv_path_SED="$ac_path_SED"
6514      ac_path_SED_max=$ac_count
6515    fi
6516    # 10*(2^10) chars as input seems more than enough
6517    test $ac_count -gt 10 && break
6518  done
6519  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
6520esac
6521
6522      $ac_path_SED_found && break 3
6523    done
6524  done
6525  done
6526IFS=$as_save_IFS
6527  if test -z "$ac_cv_path_SED"; then
6528    as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
6529  fi
6530else
6531  ac_cv_path_SED=$SED
6532fi
6533
6534fi
6535{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
6536$as_echo "$ac_cv_path_SED" >&6; }
6537 SED="$ac_cv_path_SED"
6538  rm -f conftest.sed
6539
6540test -z "$SED" && SED=sed
6541Xsed="$SED -e 1s/^X//"
6542
6543
6544
6545
6546
6547
6548
6549
6550
6551
6552
6553{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
6554$as_echo_n "checking for fgrep... " >&6; }
6555if ${ac_cv_path_FGREP+:} false; then :
6556  $as_echo_n "(cached) " >&6
6557else
6558  if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
6559   then ac_cv_path_FGREP="$GREP -F"
6560   else
6561     if test -z "$FGREP"; then
6562  ac_path_FGREP_found=false
6563  # Loop through the user's path and test for each of PROGNAME-LIST
6564  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6565for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
6566do
6567  IFS=$as_save_IFS
6568  test -z "$as_dir" && as_dir=.
6569    for ac_prog in fgrep; do
6570    for ac_exec_ext in '' $ac_executable_extensions; do
6571      ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
6572      as_fn_executable_p "$ac_path_FGREP" || continue
6573# Check for GNU ac_path_FGREP and select it if it is found.
6574  # Check for GNU $ac_path_FGREP
6575case `"$ac_path_FGREP" --version 2>&1` in
6576*GNU*)
6577  ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
6578*)
6579  ac_count=0
6580  $as_echo_n 0123456789 >"conftest.in"
6581  while :
6582  do
6583    cat "conftest.in" "conftest.in" >"conftest.tmp"
6584    mv "conftest.tmp" "conftest.in"
6585    cp "conftest.in" "conftest.nl"
6586    $as_echo 'FGREP' >> "conftest.nl"
6587    "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
6588    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
6589    as_fn_arith $ac_count + 1 && ac_count=$as_val
6590    if test $ac_count -gt ${ac_path_FGREP_max-0}; then
6591      # Best one so far, save it but keep looking for a better one
6592      ac_cv_path_FGREP="$ac_path_FGREP"
6593      ac_path_FGREP_max=$ac_count
6594    fi
6595    # 10*(2^10) chars as input seems more than enough
6596    test $ac_count -gt 10 && break
6597  done
6598  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
6599esac
6600
6601      $ac_path_FGREP_found && break 3
6602    done
6603  done
6604  done
6605IFS=$as_save_IFS
6606  if test -z "$ac_cv_path_FGREP"; then
6607    as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
6608  fi
6609else
6610  ac_cv_path_FGREP=$FGREP
6611fi
6612
6613   fi
6614fi
6615{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5
6616$as_echo "$ac_cv_path_FGREP" >&6; }
6617 FGREP="$ac_cv_path_FGREP"
6618
6619
6620test -z "$GREP" && GREP=grep
6621
6622
6623
6624
6625
6626
6627
6628
6629
6630
6631
6632
6633
6634
6635
6636
6637
6638ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
6639ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
6640ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
6641
6642{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
6643$as_echo_n "checking how to print strings... " >&6; }
6644# Test print first, because it will be a builtin if present.
6645if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
6646   test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
6647  ECHO='print -r --'
6648elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
6649  ECHO='printf %s\n'
6650else
6651  # Use this function as a fallback that always works.
6652  func_fallback_echo ()
6653  {
6654    eval 'cat <<_LTECHO_EOF
6655$1
6656_LTECHO_EOF'
6657  }
6658  ECHO='func_fallback_echo'
6659fi
6660
6661# func_echo_all arg...
6662# Invoke $ECHO with all args, space-separated.
6663func_echo_all ()
6664{
6665    $ECHO ""
6666}
6667
6668case $ECHO in
6669  printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5
6670$as_echo "printf" >&6; } ;;
6671  print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5
6672$as_echo "print -r" >&6; } ;;
6673  *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5
6674$as_echo "cat" >&6; } ;;
6675esac
6676
6677
6678
6679
6680
6681
6682
6683
6684
6685
6686
6687
6688
6689
6690ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
6691if test "x$ac_cv_type_pid_t" = xyes; then :
6692
6693else
6694
6695cat >>confdefs.h <<_ACEOF
6696#define pid_t int
6697_ACEOF
6698
6699fi
6700
6701ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
6702if test "x$ac_cv_type_size_t" = xyes; then :
6703
6704else
6705
6706cat >>confdefs.h <<_ACEOF
6707#define size_t unsigned int
6708_ACEOF
6709
6710fi
6711
6712
6713            # Check whether --enable-c99-snprintf was given.
6714if test "${enable_c99_snprintf+set}" = set; then :
6715  enableval=$enable_c99_snprintf; force_c99_snprintf=$enableval
6716else
6717  force_c99_snprintf=no
6718
6719fi
6720
6721    case "$force_c99_snprintf" in
6722     yes)
6723	hw_force_rpl_snprintf=yes
6724	hw_force_rpl_vsnprintf=yes
6725    esac
6726
6727
6728
6729
6730
6731
6732  for ac_header in $ac_header_list
6733do :
6734  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6735ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
6736"
6737if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
6738  cat >>confdefs.h <<_ACEOF
6739#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
6740_ACEOF
6741
6742fi
6743
6744done
6745
6746
6747
6748
6749
6750
6751
6752  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
6753$as_echo_n "checking for unsigned long long int... " >&6; }
6754if ${ac_cv_type_unsigned_long_long_int+:} false; then :
6755  $as_echo_n "(cached) " >&6
6756else
6757  ac_cv_type_unsigned_long_long_int=yes
6758     if test "x${ac_cv_prog_cc_c99-no}" = xno; then
6759       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6760/* end confdefs.h.  */
6761
6762  /* For now, do not test the preprocessor; as of 2007 there are too many
6763	 implementations with broken preprocessors.  Perhaps this can
6764	 be revisited in 2012.  In the meantime, code should not expect
6765	 #if to work with literals wider than 32 bits.  */
6766      /* Test literals.  */
6767      long long int ll = 9223372036854775807ll;
6768      long long int nll = -9223372036854775807LL;
6769      unsigned long long int ull = 18446744073709551615ULL;
6770      /* Test constant expressions.   */
6771      typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
6772		     ? 1 : -1)];
6773      typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
6774		     ? 1 : -1)];
6775      int i = 63;
6776int
6777main ()
6778{
6779/* Test availability of runtime routines for shift and division.  */
6780      long long int llmax = 9223372036854775807ll;
6781      unsigned long long int ullmax = 18446744073709551615ull;
6782      return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
6783	      | (llmax / ll) | (llmax % ll)
6784	      | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
6785	      | (ullmax / ull) | (ullmax % ull));
6786  ;
6787  return 0;
6788}
6789
6790_ACEOF
6791if ac_fn_c_try_link "$LINENO"; then :
6792
6793else
6794  ac_cv_type_unsigned_long_long_int=no
6795fi
6796rm -f core conftest.err conftest.$ac_objext \
6797    conftest$ac_exeext conftest.$ac_ext
6798     fi
6799fi
6800{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
6801$as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
6802  if test $ac_cv_type_unsigned_long_long_int = yes; then
6803
6804$as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
6805
6806  fi
6807
6808
6809      ac_fn_c_check_func "$LINENO" "vsnprintf" "ac_cv_func_vsnprintf"
6810if test "x$ac_cv_func_vsnprintf" = xyes; then :
6811  hw_cv_func_vsnprintf=yes
6812else
6813  hw_cv_func_vsnprintf=no
6814fi
6815
6816  if test "$hw_cv_func_vsnprintf" = yes; then :
6817  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether vsnprintf is C99 compliant" >&5
6818$as_echo_n "checking whether vsnprintf is C99 compliant... " >&6; }
6819if ${hw_cv_func_vsnprintf_c99+:} false; then :
6820  $as_echo_n "(cached) " >&6
6821else
6822  if test "$cross_compiling" = yes; then :
6823  hw_cv_func_vsnprintf_c99=no
6824else
6825  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6826/* end confdefs.h.  */
6827#if HAVE_STDARG_H
6828          #include <stdarg.h>
6829          #endif
6830          #include <stdio.h>
6831          static int testprintf(char *buf, size_t size, const char *format, ...)
6832          {
6833            int result;
6834            va_list ap;
6835            va_start(ap, format);
6836            result = vsnprintf(buf, size, format, ap);
6837            va_end(ap);
6838            return result;
6839          }
6840int
6841main ()
6842{
6843char buf[43];
6844          if (testprintf(buf, 4, "The answer is %27.2g.", 42.0) != 42 ||
6845              testprintf(buf, 0, "No, it's %32zu.", (size_t)42) != 42 ||
6846              buf[0] != 'T' || buf[3] != '\0')
6847            return 1;
6848  ;
6849  return 0;
6850}
6851_ACEOF
6852if ac_fn_c_try_run "$LINENO"; then :
6853  hw_cv_func_vsnprintf_c99=yes
6854else
6855  hw_cv_func_vsnprintf_c99=no
6856fi
6857rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6858  conftest.$ac_objext conftest.beam conftest.$ac_ext
6859fi
6860
6861fi
6862{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hw_cv_func_vsnprintf_c99" >&5
6863$as_echo "$hw_cv_func_vsnprintf_c99" >&6; }
6864else
6865  hw_cv_func_vsnprintf_c99=no
6866fi
6867
6868$as_echo "#define HAVE_VSNPRINTF 1" >>confdefs.h
6869
6870  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if C99-snprintf replacement vsnprintf will be used" >&5
6871$as_echo_n "checking if C99-snprintf replacement vsnprintf will be used... " >&6; }
6872  if test "${hw_force_rpl_vsnprintf=no}" = yes -o "$hw_cv_func_vsnprintf_c99" = no; then :
6873  hw_use_rpl_vsnprintf=yes
6874else
6875  hw_use_rpl_vsnprintf=no
6876fi
6877  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hw_use_rpl_vsnprintf" >&5
6878$as_echo "$hw_use_rpl_vsnprintf" >&6; }
6879  if test "$hw_use_rpl_vsnprintf" = yes; then :
6880
6881$as_echo "#define HW_WANT_RPL_VSNPRINTF 1" >>confdefs.h
6882
6883    if test ${hw_nodef_vsnprintf=no} = no; then :
6884
6885$as_echo "#define vsnprintf rpl_vsnprintf" >>confdefs.h
6886
6887fi
6888    for ac_header in inttypes.h locale.h stddef.h stdint.h
6889do :
6890  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6891ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
6892if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
6893  cat >>confdefs.h <<_ACEOF
6894#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
6895_ACEOF
6896
6897fi
6898
6899done
6900
6901    ac_fn_c_check_member "$LINENO" "struct lconv" "decimal_point" "ac_cv_member_struct_lconv_decimal_point" "#include <locale.h>
6902"
6903if test "x$ac_cv_member_struct_lconv_decimal_point" = xyes; then :
6904
6905cat >>confdefs.h <<_ACEOF
6906#define HAVE_STRUCT_LCONV_DECIMAL_POINT 1
6907_ACEOF
6908
6909
6910fi
6911ac_fn_c_check_member "$LINENO" "struct lconv" "thousands_sep" "ac_cv_member_struct_lconv_thousands_sep" "#include <locale.h>
6912"
6913if test "x$ac_cv_member_struct_lconv_thousands_sep" = xyes; then :
6914
6915cat >>confdefs.h <<_ACEOF
6916#define HAVE_STRUCT_LCONV_THOUSANDS_SEP 1
6917_ACEOF
6918
6919
6920fi
6921
6922
6923  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double" >&5
6924$as_echo_n "checking for long double... " >&6; }
6925if ${ac_cv_type_long_double+:} false; then :
6926  $as_echo_n "(cached) " >&6
6927else
6928  if test "$GCC" = yes; then
6929       ac_cv_type_long_double=yes
6930     else
6931       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6932/* end confdefs.h.  */
6933/* The Stardent Vistra knows sizeof (long double), but does
6934		 not support it.  */
6935	      long double foo = 0.0L;
6936int
6937main ()
6938{
6939static int test_array [1 - 2 * !(/* On Ultrix 4.3 cc, long double is 4 and double is 8.  */
6940	      sizeof (double) <= sizeof (long double))];
6941test_array [0] = 0;
6942return test_array [0];
6943
6944  ;
6945  return 0;
6946}
6947_ACEOF
6948if ac_fn_c_try_compile "$LINENO"; then :
6949  ac_cv_type_long_double=yes
6950else
6951  ac_cv_type_long_double=no
6952fi
6953rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6954     fi
6955fi
6956{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_double" >&5
6957$as_echo "$ac_cv_type_long_double" >&6; }
6958  if test $ac_cv_type_long_double = yes; then
6959
6960$as_echo "#define HAVE_LONG_DOUBLE 1" >>confdefs.h
6961
6962  fi
6963
6964
6965
6966  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
6967$as_echo_n "checking for long long int... " >&6; }
6968if ${ac_cv_type_long_long_int+:} false; then :
6969  $as_echo_n "(cached) " >&6
6970else
6971  ac_cv_type_long_long_int=yes
6972      if test "x${ac_cv_prog_cc_c99-no}" = xno; then
6973	ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
6974	if test $ac_cv_type_long_long_int = yes; then
6975	  	  	  	  if test "$cross_compiling" = yes; then :
6976  :
6977else
6978  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6979/* end confdefs.h.  */
6980#include <limits.h>
6981		 #ifndef LLONG_MAX
6982		 # define HALF \
6983			  (1LL << (sizeof (long long int) * CHAR_BIT - 2))
6984		 # define LLONG_MAX (HALF - 1 + HALF)
6985		 #endif
6986int
6987main ()
6988{
6989long long int n = 1;
6990		 int i;
6991		 for (i = 0; ; i++)
6992		   {
6993		     long long int m = n << i;
6994		     if (m >> i != n)
6995		       return 1;
6996		     if (LLONG_MAX / 2 < m)
6997		       break;
6998		   }
6999		 return 0;
7000  ;
7001  return 0;
7002}
7003_ACEOF
7004if ac_fn_c_try_run "$LINENO"; then :
7005
7006else
7007  ac_cv_type_long_long_int=no
7008fi
7009rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7010  conftest.$ac_objext conftest.beam conftest.$ac_ext
7011fi
7012
7013	fi
7014      fi
7015fi
7016{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
7017$as_echo "$ac_cv_type_long_long_int" >&6; }
7018  if test $ac_cv_type_long_long_int = yes; then
7019
7020$as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
7021
7022  fi
7023
7024
7025  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
7026$as_echo_n "checking for unsigned long long int... " >&6; }
7027if ${ac_cv_type_unsigned_long_long_int+:} false; then :
7028  $as_echo_n "(cached) " >&6
7029else
7030  ac_cv_type_unsigned_long_long_int=yes
7031     if test "x${ac_cv_prog_cc_c99-no}" = xno; then
7032       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7033/* end confdefs.h.  */
7034
7035  /* For now, do not test the preprocessor; as of 2007 there are too many
7036	 implementations with broken preprocessors.  Perhaps this can
7037	 be revisited in 2012.  In the meantime, code should not expect
7038	 #if to work with literals wider than 32 bits.  */
7039      /* Test literals.  */
7040      long long int ll = 9223372036854775807ll;
7041      long long int nll = -9223372036854775807LL;
7042      unsigned long long int ull = 18446744073709551615ULL;
7043      /* Test constant expressions.   */
7044      typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
7045		     ? 1 : -1)];
7046      typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
7047		     ? 1 : -1)];
7048      int i = 63;
7049int
7050main ()
7051{
7052/* Test availability of runtime routines for shift and division.  */
7053      long long int llmax = 9223372036854775807ll;
7054      unsigned long long int ullmax = 18446744073709551615ull;
7055      return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
7056	      | (llmax / ll) | (llmax % ll)
7057	      | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
7058	      | (ullmax / ull) | (ullmax % ull));
7059  ;
7060  return 0;
7061}
7062
7063_ACEOF
7064if ac_fn_c_try_link "$LINENO"; then :
7065
7066else
7067  ac_cv_type_unsigned_long_long_int=no
7068fi
7069rm -f core conftest.err conftest.$ac_objext \
7070    conftest$ac_exeext conftest.$ac_ext
7071     fi
7072fi
7073{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
7074$as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
7075  if test $ac_cv_type_unsigned_long_long_int = yes; then
7076
7077$as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
7078
7079  fi
7080
7081    ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
7082if test "x$ac_cv_type_size_t" = xyes; then :
7083
7084else
7085
7086cat >>confdefs.h <<_ACEOF
7087#define size_t unsigned int
7088_ACEOF
7089
7090fi
7091
7092
7093
7094  ac_fn_c_check_type "$LINENO" "intmax_t" "ac_cv_type_intmax_t" "$ac_includes_default"
7095if test "x$ac_cv_type_intmax_t" = xyes; then :
7096
7097$as_echo "#define HAVE_INTMAX_T 1" >>confdefs.h
7098
7099else
7100  test $ac_cv_type_long_long_int = yes \
7101       && ac_type='long long int' \
7102       || ac_type='long int'
7103
7104cat >>confdefs.h <<_ACEOF
7105#define intmax_t $ac_type
7106_ACEOF
7107
7108fi
7109
7110
7111
7112
7113  ac_fn_c_check_type "$LINENO" "uintmax_t" "ac_cv_type_uintmax_t" "$ac_includes_default"
7114if test "x$ac_cv_type_uintmax_t" = xyes; then :
7115
7116$as_echo "#define HAVE_UINTMAX_T 1" >>confdefs.h
7117
7118else
7119  test $ac_cv_type_unsigned_long_long_int = yes \
7120       && ac_type='unsigned long long int' \
7121       || ac_type='unsigned long int'
7122
7123cat >>confdefs.h <<_ACEOF
7124#define uintmax_t $ac_type
7125_ACEOF
7126
7127fi
7128
7129
7130
7131  ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default"
7132if test "x$ac_cv_type_uintptr_t" = xyes; then :
7133
7134$as_echo "#define HAVE_UINTPTR_T 1" >>confdefs.h
7135
7136else
7137  for ac_type in 'unsigned int' 'unsigned long int' \
7138	'unsigned long long int'; do
7139       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7140/* end confdefs.h.  */
7141$ac_includes_default
7142int
7143main ()
7144{
7145static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))];
7146test_array [0] = 0;
7147return test_array [0];
7148
7149  ;
7150  return 0;
7151}
7152_ACEOF
7153if ac_fn_c_try_compile "$LINENO"; then :
7154
7155cat >>confdefs.h <<_ACEOF
7156#define uintptr_t $ac_type
7157_ACEOF
7158
7159	  ac_type=
7160fi
7161rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7162       test -z "$ac_type" && break
7163     done
7164fi
7165
7166
7167    ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default"
7168if test "x$ac_cv_type_ptrdiff_t" = xyes; then :
7169
7170cat >>confdefs.h <<_ACEOF
7171#define HAVE_PTRDIFF_T 1
7172_ACEOF
7173
7174
7175fi
7176
7177    for ac_func in localeconv
7178do :
7179  ac_fn_c_check_func "$LINENO" "localeconv" "ac_cv_func_localeconv"
7180if test "x$ac_cv_func_localeconv" = xyes; then :
7181  cat >>confdefs.h <<_ACEOF
7182#define HAVE_LOCALECONV 1
7183_ACEOF
7184
7185fi
7186done
7187
7188
7189  if test "x$_hw_cv_func_xprintf_replace_done" != xyes; then :
7190  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
7191$as_echo_n "checking for an ANSI C-conforming const... " >&6; }
7192if ${ac_cv_c_const+:} false; then :
7193  $as_echo_n "(cached) " >&6
7194else
7195  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7196/* end confdefs.h.  */
7197
7198int
7199main ()
7200{
7201
7202#ifndef __cplusplus
7203  /* Ultrix mips cc rejects this sort of thing.  */
7204  typedef int charset[2];
7205  const charset cs = { 0, 0 };
7206  /* SunOS 4.1.1 cc rejects this.  */
7207  char const *const *pcpcc;
7208  char **ppc;
7209  /* NEC SVR4.0.2 mips cc rejects this.  */
7210  struct point {int x, y;};
7211  static struct point const zero = {0,0};
7212  /* AIX XL C 1.02.0.0 rejects this.
7213     It does not let you subtract one const X* pointer from another in
7214     an arm of an if-expression whose if-part is not a constant
7215     expression */
7216  const char *g = "string";
7217  pcpcc = &g + (g ? g-g : 0);
7218  /* HPUX 7.0 cc rejects these. */
7219  ++pcpcc;
7220  ppc = (char**) pcpcc;
7221  pcpcc = (char const *const *) ppc;
7222  { /* SCO 3.2v4 cc rejects this sort of thing.  */
7223    char tx;
7224    char *t = &tx;
7225    char const *s = 0 ? (char *) 0 : (char const *) 0;
7226
7227    *t++ = 0;
7228    if (s) return 0;
7229  }
7230  { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
7231    int x[] = {25, 17};
7232    const int *foo = &x[0];
7233    ++foo;
7234  }
7235  { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
7236    typedef const int *iptr;
7237    iptr p = 0;
7238    ++p;
7239  }
7240  { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying
7241       "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
7242    struct s { int j; const int *ap[3]; } bx;
7243    struct s *b = &bx; b->j = 5;
7244  }
7245  { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
7246    const int foo = 10;
7247    if (!foo) return 0;
7248  }
7249  return !cs[0] && !zero.x;
7250#endif
7251
7252  ;
7253  return 0;
7254}
7255_ACEOF
7256if ac_fn_c_try_compile "$LINENO"; then :
7257  ac_cv_c_const=yes
7258else
7259  ac_cv_c_const=no
7260fi
7261rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7262fi
7263{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
7264$as_echo "$ac_cv_c_const" >&6; }
7265if test $ac_cv_c_const = no; then
7266
7267$as_echo "#define const /**/" >>confdefs.h
7268
7269fi
7270
7271
7272
7273
7274    case " $LIBOBJS " in
7275  *" snprintf.$ac_objext "* ) ;;
7276  *) LIBOBJS="$LIBOBJS snprintf.$ac_objext"
7277 ;;
7278esac
7279
7280    _hw_cv_func_xprintf_replace_done=yes
7281fi
7282
7283fi
7284
7285
7286    ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
7287if test "x$ac_cv_func_snprintf" = xyes; then :
7288  hw_cv_func_snprintf=yes
7289else
7290  hw_cv_func_snprintf=no
7291fi
7292
7293  if test "$hw_cv_func_snprintf" = yes; then :
7294  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether snprintf is C99 compliant" >&5
7295$as_echo_n "checking whether snprintf is C99 compliant... " >&6; }
7296if ${hw_cv_func_snprintf_c99+:} false; then :
7297  $as_echo_n "(cached) " >&6
7298else
7299  if test "$cross_compiling" = yes; then :
7300  hw_cv_func_snprintf_c99=no
7301else
7302  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7303/* end confdefs.h.  */
7304#include <stdio.h>
7305int
7306main ()
7307{
7308char buf[43];
7309          if (snprintf(buf, 4, "The answer is %27.2g.", 42.0) != 42 ||
7310              snprintf(buf, 0, "No, it's %32zu.", (size_t)42) != 42 ||
7311              buf[0] != 'T' || buf[3] != '\0')
7312            return 1;
7313  ;
7314  return 0;
7315}
7316_ACEOF
7317if ac_fn_c_try_run "$LINENO"; then :
7318  hw_cv_func_snprintf_c99=yes
7319else
7320  hw_cv_func_snprintf_c99=no
7321fi
7322rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7323  conftest.$ac_objext conftest.beam conftest.$ac_ext
7324fi
7325
7326fi
7327{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hw_cv_func_snprintf_c99" >&5
7328$as_echo "$hw_cv_func_snprintf_c99" >&6; }
7329else
7330  hw_cv_func_snprintf_c99=no
7331fi
7332
7333$as_echo "#define HAVE_SNPRINTF 1" >>confdefs.h
7334
7335  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if C99-snprintf replacement snprintf will be used" >&5
7336$as_echo_n "checking if C99-snprintf replacement snprintf will be used... " >&6; }
7337  if test "${hw_force_rpl_snprintf=no}" = yes -o "$hw_cv_func_snprintf_c99" = no; then :
7338  hw_use_rpl_snprintf=yes
7339else
7340  hw_use_rpl_snprintf=no
7341fi
7342  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hw_use_rpl_snprintf" >&5
7343$as_echo "$hw_use_rpl_snprintf" >&6; }
7344  if test "$hw_use_rpl_snprintf" = yes; then :
7345
7346$as_echo "#define HW_WANT_RPL_SNPRINTF 1" >>confdefs.h
7347
7348    if test ${hw_nodef_snprintf=no} = no; then :
7349
7350$as_echo "#define snprintf rpl_snprintf" >>confdefs.h
7351
7352fi
7353
7354  if test "x$_hw_cv_func_xprintf_replace_done" != xyes; then :
7355  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
7356$as_echo_n "checking for an ANSI C-conforming const... " >&6; }
7357if ${ac_cv_c_const+:} false; then :
7358  $as_echo_n "(cached) " >&6
7359else
7360  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7361/* end confdefs.h.  */
7362
7363int
7364main ()
7365{
7366
7367#ifndef __cplusplus
7368  /* Ultrix mips cc rejects this sort of thing.  */
7369  typedef int charset[2];
7370  const charset cs = { 0, 0 };
7371  /* SunOS 4.1.1 cc rejects this.  */
7372  char const *const *pcpcc;
7373  char **ppc;
7374  /* NEC SVR4.0.2 mips cc rejects this.  */
7375  struct point {int x, y;};
7376  static struct point const zero = {0,0};
7377  /* AIX XL C 1.02.0.0 rejects this.
7378     It does not let you subtract one const X* pointer from another in
7379     an arm of an if-expression whose if-part is not a constant
7380     expression */
7381  const char *g = "string";
7382  pcpcc = &g + (g ? g-g : 0);
7383  /* HPUX 7.0 cc rejects these. */
7384  ++pcpcc;
7385  ppc = (char**) pcpcc;
7386  pcpcc = (char const *const *) ppc;
7387  { /* SCO 3.2v4 cc rejects this sort of thing.  */
7388    char tx;
7389    char *t = &tx;
7390    char const *s = 0 ? (char *) 0 : (char const *) 0;
7391
7392    *t++ = 0;
7393    if (s) return 0;
7394  }
7395  { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
7396    int x[] = {25, 17};
7397    const int *foo = &x[0];
7398    ++foo;
7399  }
7400  { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
7401    typedef const int *iptr;
7402    iptr p = 0;
7403    ++p;
7404  }
7405  { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying
7406       "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
7407    struct s { int j; const int *ap[3]; } bx;
7408    struct s *b = &bx; b->j = 5;
7409  }
7410  { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
7411    const int foo = 10;
7412    if (!foo) return 0;
7413  }
7414  return !cs[0] && !zero.x;
7415#endif
7416
7417  ;
7418  return 0;
7419}
7420_ACEOF
7421if ac_fn_c_try_compile "$LINENO"; then :
7422  ac_cv_c_const=yes
7423else
7424  ac_cv_c_const=no
7425fi
7426rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7427fi
7428{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
7429$as_echo "$ac_cv_c_const" >&6; }
7430if test $ac_cv_c_const = no; then
7431
7432$as_echo "#define const /**/" >>confdefs.h
7433
7434fi
7435
7436
7437
7438
7439    case " $LIBOBJS " in
7440  *" snprintf.$ac_objext "* ) ;;
7441  *) LIBOBJS="$LIBOBJS snprintf.$ac_objext"
7442 ;;
7443esac
7444
7445    _hw_cv_func_xprintf_replace_done=yes
7446fi
7447
7448fi
7449
7450
7451
7452
7453
7454# HMS: Save $LIBS and empty it.
7455# any LIBS we add here should go in to LDADD_LIBNTP
7456
7457__LIBS=$LIBS
7458LIBS=
7459
7460
7461
7462# [Bug 2332] because we need to know if we are using GNU ld...
7463
7464
7465# Check whether --with-gnu-ld was given.
7466if test "${with_gnu_ld+set}" = set; then :
7467  withval=$with_gnu_ld; test no = "$withval" || with_gnu_ld=yes
7468else
7469  with_gnu_ld=no
7470fi
7471
7472ac_prog=ld
7473if test yes = "$GCC"; then
7474  # Check if gcc -print-prog-name=ld gives a path.
7475  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
7476$as_echo_n "checking for ld used by $CC... " >&6; }
7477  case $host in
7478  *-*-mingw*)
7479    # gcc leaves a trailing carriage return, which upsets mingw
7480    ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
7481  *)
7482    ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
7483  esac
7484  case $ac_prog in
7485    # Accept absolute paths.
7486    [\\/]* | ?:[\\/]*)
7487      re_direlt='/[^/][^/]*/\.\./'
7488      # Canonicalize the pathname of ld
7489      ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
7490      while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
7491	ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
7492      done
7493      test -z "$LD" && LD=$ac_prog
7494      ;;
7495  "")
7496    # If it fails, then pretend we aren't using GCC.
7497    ac_prog=ld
7498    ;;
7499  *)
7500    # If it is relative, then search for the first ld in PATH.
7501    with_gnu_ld=unknown
7502    ;;
7503  esac
7504elif test yes = "$with_gnu_ld"; then
7505  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
7506$as_echo_n "checking for GNU ld... " >&6; }
7507else
7508  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
7509$as_echo_n "checking for non-GNU ld... " >&6; }
7510fi
7511if ${lt_cv_path_LD+:} false; then :
7512  $as_echo_n "(cached) " >&6
7513else
7514  if test -z "$LD"; then
7515  lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
7516  for ac_dir in $PATH; do
7517    IFS=$lt_save_ifs
7518    test -z "$ac_dir" && ac_dir=.
7519    if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
7520      lt_cv_path_LD=$ac_dir/$ac_prog
7521      # Check to see if the program is GNU ld.  I'd rather use --version,
7522      # but apparently some variants of GNU ld only accept -v.
7523      # Break only if it was the GNU/non-GNU ld that we prefer.
7524      case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
7525      *GNU* | *'with BFD'*)
7526	test no != "$with_gnu_ld" && break
7527	;;
7528      *)
7529	test yes != "$with_gnu_ld" && break
7530	;;
7531      esac
7532    fi
7533  done
7534  IFS=$lt_save_ifs
7535else
7536  lt_cv_path_LD=$LD # Let the user override the test with a path.
7537fi
7538fi
7539
7540LD=$lt_cv_path_LD
7541if test -n "$LD"; then
7542  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
7543$as_echo "$LD" >&6; }
7544else
7545  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7546$as_echo "no" >&6; }
7547fi
7548test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
7549{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
7550$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
7551if ${lt_cv_prog_gnu_ld+:} false; then :
7552  $as_echo_n "(cached) " >&6
7553else
7554  # I'd rather use --version here, but apparently some GNU lds only accept -v.
7555case `$LD -v 2>&1 </dev/null` in
7556*GNU* | *'with BFD'*)
7557  lt_cv_prog_gnu_ld=yes
7558  ;;
7559*)
7560  lt_cv_prog_gnu_ld=no
7561  ;;
7562esac
7563fi
7564{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5
7565$as_echo "$lt_cv_prog_gnu_ld" >&6; }
7566with_gnu_ld=$lt_cv_prog_gnu_ld
7567
7568
7569
7570
7571
7572
7573
7574
7575
7576
7577
7578{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for directory path separator" >&5
7579$as_echo_n "checking for directory path separator... " >&6; }
7580if ${ntp_cv_dir_sep+:} false; then :
7581  $as_echo_n "(cached) " >&6
7582else
7583
7584	case "$ntp_cv_dir_sep" in
7585	 '')
7586	    case "$host_os" in
7587	     *djgpp | *mingw32* | *emx*)
7588		ntp_cv_dir_sep="'\\'"
7589		;;
7590	     *)
7591		ntp_cv_dir_sep="'/'"
7592		;;
7593	    esac
7594	esac
7595
7596
7597fi
7598{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_dir_sep" >&5
7599$as_echo "$ntp_cv_dir_sep" >&6; }
7600
7601cat >>confdefs.h <<_ACEOF
7602#define DIR_SEP $ntp_cv_dir_sep
7603_ACEOF
7604
7605
7606
7607    NTP_ORIG_LIBS="$LIBS"
7608
7609# Check whether --with-lineeditlibs was given.
7610if test "${with_lineeditlibs+set}" = set; then :
7611  withval=$with_lineeditlibs; use_lineeditlibs="$withval"
7612else
7613  use_lineeditlibs="edit,editline"
7614
7615fi
7616
7617    { $as_echo "$as_me:${as_lineno-$LINENO}: checking line editing libraries" >&5
7618$as_echo_n "checking line editing libraries... " >&6; }
7619    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $use_lineeditlibs" >&5
7620$as_echo "$use_lineeditlibs" >&6; }
7621    case "$use_lineeditlibs" in
7622     no)
7623	ntp_lib_lineedit=no
7624	;;
7625     *)
7626	for lineedit_lib in `echo $use_lineeditlibs | sed -e 's/,/ /'`; do
7627	    for term_lib in "" termcap curses ncurses; do
7628		case "$term_lib" in
7629		 '')
7630		    TRY_LIB="-l$lineedit_lib"
7631		    ;;
7632		 *)
7633		    TRY_LIB="-l$lineedit_lib -l$term_lib"
7634		    ;;
7635		esac
7636		LIBS="$NTP_ORIG_LIBS $TRY_LIB"
7637		{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for readline() with $TRY_LIB" >&5
7638$as_echo_n "checking for readline() with $TRY_LIB... " >&6; }
7639		cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7640/* end confdefs.h.  */
7641
7642/* Override any GCC internal prototype to avoid an error.
7643   Use char because int might match the return type of a GCC
7644   builtin and then its argument prototype would still apply.  */
7645#ifdef __cplusplus
7646extern "C"
7647#endif
7648char readline ();
7649int
7650main ()
7651{
7652return readline ();
7653  ;
7654  return 0;
7655}
7656_ACEOF
7657if ac_fn_c_try_link "$LINENO"; then :
7658  ntp_lib_lineedit="$TRY_LIB"
7659fi
7660rm -f core conftest.err conftest.$ac_objext \
7661    conftest$ac_exeext conftest.$ac_ext
7662		case "$ntp_lib_lineedit" in
7663		 '')
7664		    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7665$as_echo "no" >&6; }
7666		    ;;
7667		 *)
7668		    # Use readline()
7669		    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7670$as_echo "yes" >&6; }
7671		    break
7672		esac
7673		case "$term_lib" in
7674		 '')
7675		    # do not try el_gets without a terminal library
7676		    ;;
7677		 *)
7678		    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for el_gets() with $TRY_LIB" >&5
7679$as_echo_n "checking for el_gets() with $TRY_LIB... " >&6; }
7680		    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7681/* end confdefs.h.  */
7682
7683/* Override any GCC internal prototype to avoid an error.
7684   Use char because int might match the return type of a GCC
7685   builtin and then its argument prototype would still apply.  */
7686#ifdef __cplusplus
7687extern "C"
7688#endif
7689char el_gets ();
7690int
7691main ()
7692{
7693return el_gets ();
7694  ;
7695  return 0;
7696}
7697_ACEOF
7698if ac_fn_c_try_link "$LINENO"; then :
7699  ntp_lib_lineedit="$TRY_LIB"
7700fi
7701rm -f core conftest.err conftest.$ac_objext \
7702    conftest$ac_exeext conftest.$ac_ext
7703		    case "$ntp_lib_lineedit" in
7704		     '')
7705			{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7706$as_echo "no" >&6; }
7707			;;
7708		     *) # Use el_gets()
7709			{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7710$as_echo "yes" >&6; }
7711			break
7712			;;
7713		    esac	# $ntp_lib_lineedit
7714		esac		# $term_lib
7715	    done
7716	    case "$ntp_lib_lineedit" in
7717	     '')
7718		;;
7719	     *)
7720		break
7721		;;
7722	    esac
7723	done
7724	LIBS="$NTP_ORIG_LIBS"
7725	;;
7726    esac	# $use_lineeditlibs
7727
7728    case "$ntp_lib_lineedit" in
7729     '')
7730	ntp_lib_lineedit="no"
7731	;;
7732     no)
7733	;;
7734     *)
7735	EDITLINE_LIBS="$ntp_lib_lineedit"
7736
7737	;;
7738    esac	# $ntp_lib_lineedit
7739
7740    case "$ntp_lib_lineedit" in
7741     no)
7742	;;
7743     *)
7744	for ac_header in readline.h readline/readline.h histedit.h
7745do :
7746  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
7747ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
7748if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
7749  cat >>confdefs.h <<_ACEOF
7750#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
7751_ACEOF
7752
7753fi
7754
7755done
7756
7757	for ac_header in history.h readline/history.h
7758do :
7759  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
7760ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
7761if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
7762  cat >>confdefs.h <<_ACEOF
7763#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
7764_ACEOF
7765
7766fi
7767
7768done
7769
7770
7771	case "$ac_cv_header_histedit_h" in
7772	 yes)
7773	    { $as_echo "$as_me:${as_lineno-$LINENO}: checking number of arguments to el_init()" >&5
7774$as_echo_n "checking number of arguments to el_init()... " >&6; }
7775if ${ntp_cv_el_init_args+:} false; then :
7776  $as_echo_n "(cached) " >&6
7777else
7778  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7779/* end confdefs.h.  */
7780
7781			    #include <stdio.h>
7782			    #include <histedit.h>
7783
7784int
7785main ()
7786{
7787
7788			    el_init("conftest", stdin, stdout, stderr);
7789
7790
7791  ;
7792  return 0;
7793}
7794_ACEOF
7795if ac_fn_c_try_compile "$LINENO"; then :
7796  ntp_cv_el_init_args=4
7797else
7798  ntp_cv_el_init_args=3
7799
7800fi
7801rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7802
7803fi
7804{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_el_init_args" >&5
7805$as_echo "$ntp_cv_el_init_args" >&6; }
7806
7807cat >>confdefs.h <<_ACEOF
7808#define EL_INIT_ARGS $ntp_cv_el_init_args
7809_ACEOF
7810
7811	esac
7812
7813	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readline supports history" >&5
7814$as_echo_n "checking whether readline supports history... " >&6; }
7815
7816	ntp_lib_lineedit_history="no"
7817	ORIG_LIBS="$LIBS"
7818	LIBS="$ORIG_LIBS $ntp_lib_lineedit"
7819	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7820/* end confdefs.h.  */
7821
7822/* Override any GCC internal prototype to avoid an error.
7823   Use char because int might match the return type of a GCC
7824   builtin and then its argument prototype would still apply.  */
7825#ifdef __cplusplus
7826extern "C"
7827#endif
7828char add_history ();
7829int
7830main ()
7831{
7832return add_history ();
7833  ;
7834  return 0;
7835}
7836_ACEOF
7837if ac_fn_c_try_link "$LINENO"; then :
7838  ntp_lib_lineedit_history="yes"
7839fi
7840rm -f core conftest.err conftest.$ac_objext \
7841    conftest$ac_exeext conftest.$ac_ext
7842	LIBS="$ORIG_LIBS"
7843
7844	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_lib_lineedit_history" >&5
7845$as_echo "$ntp_lib_lineedit_history" >&6; }
7846
7847	case "$ntp_lib_lineedit_history" in
7848	 yes)
7849
7850$as_echo "#define HAVE_READLINE_HISTORY 1" >>confdefs.h
7851
7852	esac
7853    esac	# $ntp_lib_lineedit
7854    { NTP_ORIG_LIBS=; unset NTP_ORIG_LIBS;}
7855    { ORIG_LIBS=; unset ORIG_LIBS;}
7856    { TRY_LIB=; unset TRY_LIB;}
7857    { use_lineeditlibs=; unset use_lineeditlibs;}
7858
7859
7860LIBM=
7861case "$host" in
7862 *-*-darwin*)
7863    ;;
7864 *)
7865    _libs=$LIBS
7866    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing cos" >&5
7867$as_echo_n "checking for library containing cos... " >&6; }
7868if ${ac_cv_search_cos+:} false; then :
7869  $as_echo_n "(cached) " >&6
7870else
7871  ac_func_search_save_LIBS=$LIBS
7872cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7873/* end confdefs.h.  */
7874
7875/* Override any GCC internal prototype to avoid an error.
7876   Use char because int might match the return type of a GCC
7877   builtin and then its argument prototype would still apply.  */
7878#ifdef __cplusplus
7879extern "C"
7880#endif
7881char cos ();
7882int
7883main ()
7884{
7885return cos ();
7886  ;
7887  return 0;
7888}
7889_ACEOF
7890for ac_lib in '' m; do
7891  if test -z "$ac_lib"; then
7892    ac_res="none required"
7893  else
7894    ac_res=-l$ac_lib
7895    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7896  fi
7897  if ac_fn_c_try_link "$LINENO"; then :
7898  ac_cv_search_cos=$ac_res
7899fi
7900rm -f core conftest.err conftest.$ac_objext \
7901    conftest$ac_exeext
7902  if ${ac_cv_search_cos+:} false; then :
7903  break
7904fi
7905done
7906if ${ac_cv_search_cos+:} false; then :
7907
7908else
7909  ac_cv_search_cos=no
7910fi
7911rm conftest.$ac_ext
7912LIBS=$ac_func_search_save_LIBS
7913fi
7914{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_cos" >&5
7915$as_echo "$ac_cv_search_cos" >&6; }
7916ac_res=$ac_cv_search_cos
7917if test "$ac_res" != no; then :
7918  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7919  LIBM="-lm"
7920fi
7921
7922    LIBS=$_libs
7923    ;;
7924esac
7925
7926{ _libs=; unset _libs;}
7927
7928
7929for ac_header in vfork.h
7930do :
7931  ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
7932if test "x$ac_cv_header_vfork_h" = xyes; then :
7933  cat >>confdefs.h <<_ACEOF
7934#define HAVE_VFORK_H 1
7935_ACEOF
7936
7937fi
7938
7939done
7940
7941for ac_func in fork vfork
7942do :
7943  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
7944ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
7945if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
7946  cat >>confdefs.h <<_ACEOF
7947#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
7948_ACEOF
7949
7950fi
7951done
7952
7953if test "x$ac_cv_func_fork" = xyes; then
7954  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
7955$as_echo_n "checking for working fork... " >&6; }
7956if ${ac_cv_func_fork_works+:} false; then :
7957  $as_echo_n "(cached) " >&6
7958else
7959  if test "$cross_compiling" = yes; then :
7960  ac_cv_func_fork_works=cross
7961else
7962  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7963/* end confdefs.h.  */
7964$ac_includes_default
7965int
7966main ()
7967{
7968
7969	  /* By Ruediger Kuhlmann. */
7970	  return fork () < 0;
7971
7972  ;
7973  return 0;
7974}
7975_ACEOF
7976if ac_fn_c_try_run "$LINENO"; then :
7977  ac_cv_func_fork_works=yes
7978else
7979  ac_cv_func_fork_works=no
7980fi
7981rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7982  conftest.$ac_objext conftest.beam conftest.$ac_ext
7983fi
7984
7985fi
7986{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
7987$as_echo "$ac_cv_func_fork_works" >&6; }
7988
7989else
7990  ac_cv_func_fork_works=$ac_cv_func_fork
7991fi
7992if test "x$ac_cv_func_fork_works" = xcross; then
7993  case $host in
7994    *-*-amigaos* | *-*-msdosdjgpp*)
7995      # Override, as these systems have only a dummy fork() stub
7996      ac_cv_func_fork_works=no
7997      ;;
7998    *)
7999      ac_cv_func_fork_works=yes
8000      ;;
8001  esac
8002  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
8003$as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
8004fi
8005ac_cv_func_vfork_works=$ac_cv_func_vfork
8006if test "x$ac_cv_func_vfork" = xyes; then
8007  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
8008$as_echo_n "checking for working vfork... " >&6; }
8009if ${ac_cv_func_vfork_works+:} false; then :
8010  $as_echo_n "(cached) " >&6
8011else
8012  if test "$cross_compiling" = yes; then :
8013  ac_cv_func_vfork_works=cross
8014else
8015  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8016/* end confdefs.h.  */
8017/* Thanks to Paul Eggert for this test.  */
8018$ac_includes_default
8019#include <sys/wait.h>
8020#ifdef HAVE_VFORK_H
8021# include <vfork.h>
8022#endif
8023/* On some sparc systems, changes by the child to local and incoming
8024   argument registers are propagated back to the parent.  The compiler
8025   is told about this with #include <vfork.h>, but some compilers
8026   (e.g. gcc -O) don't grok <vfork.h>.  Test for this by using a
8027   static variable whose address is put into a register that is
8028   clobbered by the vfork.  */
8029static void
8030#ifdef __cplusplus
8031sparc_address_test (int arg)
8032# else
8033sparc_address_test (arg) int arg;
8034#endif
8035{
8036  static pid_t child;
8037  if (!child) {
8038    child = vfork ();
8039    if (child < 0) {
8040      perror ("vfork");
8041      _exit(2);
8042    }
8043    if (!child) {
8044      arg = getpid();
8045      write(-1, "", 0);
8046      _exit (arg);
8047    }
8048  }
8049}
8050
8051int
8052main ()
8053{
8054  pid_t parent = getpid ();
8055  pid_t child;
8056
8057  sparc_address_test (0);
8058
8059  child = vfork ();
8060
8061  if (child == 0) {
8062    /* Here is another test for sparc vfork register problems.  This
8063       test uses lots of local variables, at least as many local
8064       variables as main has allocated so far including compiler
8065       temporaries.  4 locals are enough for gcc 1.40.3 on a Solaris
8066       4.1.3 sparc, but we use 8 to be safe.  A buggy compiler should
8067       reuse the register of parent for one of the local variables,
8068       since it will think that parent can't possibly be used any more
8069       in this routine.  Assigning to the local variable will thus
8070       munge parent in the parent process.  */
8071    pid_t
8072      p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
8073      p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
8074    /* Convince the compiler that p..p7 are live; otherwise, it might
8075       use the same hardware register for all 8 local variables.  */
8076    if (p != p1 || p != p2 || p != p3 || p != p4
8077	|| p != p5 || p != p6 || p != p7)
8078      _exit(1);
8079
8080    /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
8081       from child file descriptors.  If the child closes a descriptor
8082       before it execs or exits, this munges the parent's descriptor
8083       as well.  Test for this by closing stdout in the child.  */
8084    _exit(close(fileno(stdout)) != 0);
8085  } else {
8086    int status;
8087    struct stat st;
8088
8089    while (wait(&status) != child)
8090      ;
8091    return (
8092	 /* Was there some problem with vforking?  */
8093	 child < 0
8094
8095	 /* Did the child fail?  (This shouldn't happen.)  */
8096	 || status
8097
8098	 /* Did the vfork/compiler bug occur?  */
8099	 || parent != getpid()
8100
8101	 /* Did the file descriptor bug occur?  */
8102	 || fstat(fileno(stdout), &st) != 0
8103	 );
8104  }
8105}
8106_ACEOF
8107if ac_fn_c_try_run "$LINENO"; then :
8108  ac_cv_func_vfork_works=yes
8109else
8110  ac_cv_func_vfork_works=no
8111fi
8112rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8113  conftest.$ac_objext conftest.beam conftest.$ac_ext
8114fi
8115
8116fi
8117{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
8118$as_echo "$ac_cv_func_vfork_works" >&6; }
8119
8120fi;
8121if test "x$ac_cv_func_fork_works" = xcross; then
8122  ac_cv_func_vfork_works=$ac_cv_func_vfork
8123  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
8124$as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
8125fi
8126
8127if test "x$ac_cv_func_vfork_works" = xyes; then
8128
8129$as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
8130
8131else
8132
8133$as_echo "#define vfork fork" >>confdefs.h
8134
8135fi
8136if test "x$ac_cv_func_fork_works" = xyes; then
8137
8138$as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
8139
8140fi
8141
8142# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
8143# for constant arguments.  Useless!
8144{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
8145$as_echo_n "checking for working alloca.h... " >&6; }
8146if ${ac_cv_working_alloca_h+:} false; then :
8147  $as_echo_n "(cached) " >&6
8148else
8149  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8150/* end confdefs.h.  */
8151#include <alloca.h>
8152int
8153main ()
8154{
8155char *p = (char *) alloca (2 * sizeof (int));
8156			  if (p) return 0;
8157  ;
8158  return 0;
8159}
8160_ACEOF
8161if ac_fn_c_try_link "$LINENO"; then :
8162  ac_cv_working_alloca_h=yes
8163else
8164  ac_cv_working_alloca_h=no
8165fi
8166rm -f core conftest.err conftest.$ac_objext \
8167    conftest$ac_exeext conftest.$ac_ext
8168fi
8169{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
8170$as_echo "$ac_cv_working_alloca_h" >&6; }
8171if test $ac_cv_working_alloca_h = yes; then
8172
8173$as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
8174
8175fi
8176
8177{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
8178$as_echo_n "checking for alloca... " >&6; }
8179if ${ac_cv_func_alloca_works+:} false; then :
8180  $as_echo_n "(cached) " >&6
8181else
8182  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8183/* end confdefs.h.  */
8184#ifdef __GNUC__
8185# define alloca __builtin_alloca
8186#else
8187# ifdef _MSC_VER
8188#  include <malloc.h>
8189#  define alloca _alloca
8190# else
8191#  ifdef HAVE_ALLOCA_H
8192#   include <alloca.h>
8193#  else
8194#   ifdef _AIX
8195 #pragma alloca
8196#   else
8197#    ifndef alloca /* predefined by HP cc +Olibcalls */
8198void *alloca (size_t);
8199#    endif
8200#   endif
8201#  endif
8202# endif
8203#endif
8204
8205int
8206main ()
8207{
8208char *p = (char *) alloca (1);
8209				    if (p) return 0;
8210  ;
8211  return 0;
8212}
8213_ACEOF
8214if ac_fn_c_try_link "$LINENO"; then :
8215  ac_cv_func_alloca_works=yes
8216else
8217  ac_cv_func_alloca_works=no
8218fi
8219rm -f core conftest.err conftest.$ac_objext \
8220    conftest$ac_exeext conftest.$ac_ext
8221fi
8222{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
8223$as_echo "$ac_cv_func_alloca_works" >&6; }
8224
8225if test $ac_cv_func_alloca_works = yes; then
8226
8227$as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
8228
8229else
8230  # The SVR3 libPW and SVR4 libucb both contain incompatible functions
8231# that cause trouble.  Some versions do not even contain alloca or
8232# contain a buggy version.  If you still want to use their alloca,
8233# use ar to extract alloca.o from them instead of compiling alloca.c.
8234
8235ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
8236
8237$as_echo "#define C_ALLOCA 1" >>confdefs.h
8238
8239
8240{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5
8241$as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; }
8242if ${ac_cv_os_cray+:} false; then :
8243  $as_echo_n "(cached) " >&6
8244else
8245  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8246/* end confdefs.h.  */
8247#if defined CRAY && ! defined CRAY2
8248webecray
8249#else
8250wenotbecray
8251#endif
8252
8253_ACEOF
8254if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8255  $EGREP "webecray" >/dev/null 2>&1; then :
8256  ac_cv_os_cray=yes
8257else
8258  ac_cv_os_cray=no
8259fi
8260rm -f conftest*
8261
8262fi
8263{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
8264$as_echo "$ac_cv_os_cray" >&6; }
8265if test $ac_cv_os_cray = yes; then
8266  for ac_func in _getb67 GETB67 getb67; do
8267    as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
8268ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
8269if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
8270
8271cat >>confdefs.h <<_ACEOF
8272#define CRAY_STACKSEG_END $ac_func
8273_ACEOF
8274
8275    break
8276fi
8277
8278  done
8279fi
8280
8281{ $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
8282$as_echo_n "checking stack direction for C alloca... " >&6; }
8283if ${ac_cv_c_stack_direction+:} false; then :
8284  $as_echo_n "(cached) " >&6
8285else
8286  if test "$cross_compiling" = yes; then :
8287  ac_cv_c_stack_direction=0
8288else
8289  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8290/* end confdefs.h.  */
8291$ac_includes_default
8292int
8293find_stack_direction (int *addr, int depth)
8294{
8295  int dir, dummy = 0;
8296  if (! addr)
8297    addr = &dummy;
8298  *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
8299  dir = depth ? find_stack_direction (addr, depth - 1) : 0;
8300  return dir + dummy;
8301}
8302
8303int
8304main (int argc, char **argv)
8305{
8306  return find_stack_direction (0, argc + !argv + 20) < 0;
8307}
8308_ACEOF
8309if ac_fn_c_try_run "$LINENO"; then :
8310  ac_cv_c_stack_direction=1
8311else
8312  ac_cv_c_stack_direction=-1
8313fi
8314rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8315  conftest.$ac_objext conftest.beam conftest.$ac_ext
8316fi
8317
8318fi
8319{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
8320$as_echo "$ac_cv_c_stack_direction" >&6; }
8321cat >>confdefs.h <<_ACEOF
8322#define STACK_DIRECTION $ac_cv_c_stack_direction
8323_ACEOF
8324
8325
8326fi
8327
8328ac_fn_c_check_decl "$LINENO" "strerror_r" "ac_cv_have_decl_strerror_r" "$ac_includes_default"
8329if test "x$ac_cv_have_decl_strerror_r" = xyes; then :
8330  ac_have_decl=1
8331else
8332  ac_have_decl=0
8333fi
8334
8335cat >>confdefs.h <<_ACEOF
8336#define HAVE_DECL_STRERROR_R $ac_have_decl
8337_ACEOF
8338
8339for ac_func in strerror_r
8340do :
8341  ac_fn_c_check_func "$LINENO" "strerror_r" "ac_cv_func_strerror_r"
8342if test "x$ac_cv_func_strerror_r" = xyes; then :
8343  cat >>confdefs.h <<_ACEOF
8344#define HAVE_STRERROR_R 1
8345_ACEOF
8346
8347fi
8348done
8349
8350{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strerror_r returns char *" >&5
8351$as_echo_n "checking whether strerror_r returns char *... " >&6; }
8352if ${ac_cv_func_strerror_r_char_p+:} false; then :
8353  $as_echo_n "(cached) " >&6
8354else
8355
8356    ac_cv_func_strerror_r_char_p=no
8357    if test $ac_cv_have_decl_strerror_r = yes; then
8358      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8359/* end confdefs.h.  */
8360$ac_includes_default
8361int
8362main ()
8363{
8364
8365	  char buf[100];
8366	  char x = *strerror_r (0, buf, sizeof buf);
8367	  char *p = strerror_r (0, buf, sizeof buf);
8368	  return !p || x;
8369
8370  ;
8371  return 0;
8372}
8373_ACEOF
8374if ac_fn_c_try_compile "$LINENO"; then :
8375  ac_cv_func_strerror_r_char_p=yes
8376fi
8377rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8378    else
8379      # strerror_r is not declared.  Choose between
8380      # systems that have relatively inaccessible declarations for the
8381      # function.  BeOS and DEC UNIX 4.0 fall in this category, but the
8382      # former has a strerror_r that returns char*, while the latter
8383      # has a strerror_r that returns `int'.
8384      # This test should segfault on the DEC system.
8385      if test "$cross_compiling" = yes; then :
8386  :
8387else
8388  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8389/* end confdefs.h.  */
8390$ac_includes_default
8391	extern char *strerror_r ();
8392int
8393main ()
8394{
8395char buf[100];
8396	  char x = *strerror_r (0, buf, sizeof buf);
8397	  return ! isalpha (x);
8398  ;
8399  return 0;
8400}
8401_ACEOF
8402if ac_fn_c_try_run "$LINENO"; then :
8403  ac_cv_func_strerror_r_char_p=yes
8404fi
8405rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8406  conftest.$ac_objext conftest.beam conftest.$ac_ext
8407fi
8408
8409    fi
8410
8411fi
8412{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_strerror_r_char_p" >&5
8413$as_echo "$ac_cv_func_strerror_r_char_p" >&6; }
8414if test $ac_cv_func_strerror_r_char_p = yes; then
8415
8416$as_echo "#define STRERROR_R_CHAR_P 1" >>confdefs.h
8417
8418fi
8419
8420
8421ac_busted_vpath_in_make=no
8422case "$build" in
8423 *-*-irix6.1*)	# 64 bit only
8424    # busted vpath?
8425    ;;
8426 *-*-irix6*)	# 6.2 (and later?)
8427    ac_busted_vpath_in_make=yes
8428    ;;
8429 *-*-solaris2.5.1)
8430    ac_busted_vpath_in_make=yes
8431    ;;
8432 *-*-unicosmp*)
8433    ac_busted_vpath_in_make=yes
8434    ;;
8435esac
8436
8437case "$ac_busted_vpath_in_make$srcdir" in
8438 yes.|no*)
8439    ;;
8440 *) case "`${MAKE-make} -v -f /dev/null 2>/dev/null | grep 'GNU Make'`" in
8441     '')
8442	as_fn_error $? "building outside of the main directory requires GNU make" "$LINENO" 5
8443    esac
8444    ;;
8445esac
8446
8447case "$host" in
8448 *-*-aix4*)
8449	# Bug 2516:
8450	# Was *-*-aix[[4-9]]*
8451	# XXX only verified thru AIX6.  But...
8452	# Ken Link says this is fine for AIX 5.3 and 7.1, and sees no reason
8453	# that this support would be in 5.3, removed in 6, and added back.
8454	#
8455	# (prr) aix 4.1 doesn't have clock_settime, but in aix 4.3 it's a stub
8456	# (returning ENOSYS).  I didn't check 4.2.  If, in the future,
8457	# IBM pulls its thumbs out long enough to implement clock_settime,
8458	# this conditional will need to change.  Maybe use AC_TRY_RUN
8459	# instead to try to set the time to itself and check errno.
8460    ;;
8461 *)
8462    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
8463$as_echo_n "checking for library containing clock_gettime... " >&6; }
8464if ${ac_cv_search_clock_gettime+:} false; then :
8465  $as_echo_n "(cached) " >&6
8466else
8467  ac_func_search_save_LIBS=$LIBS
8468cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8469/* end confdefs.h.  */
8470
8471/* Override any GCC internal prototype to avoid an error.
8472   Use char because int might match the return type of a GCC
8473   builtin and then its argument prototype would still apply.  */
8474#ifdef __cplusplus
8475extern "C"
8476#endif
8477char clock_gettime ();
8478int
8479main ()
8480{
8481return clock_gettime ();
8482  ;
8483  return 0;
8484}
8485_ACEOF
8486for ac_lib in '' rt; do
8487  if test -z "$ac_lib"; then
8488    ac_res="none required"
8489  else
8490    ac_res=-l$ac_lib
8491    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8492  fi
8493  if ac_fn_c_try_link "$LINENO"; then :
8494  ac_cv_search_clock_gettime=$ac_res
8495fi
8496rm -f core conftest.err conftest.$ac_objext \
8497    conftest$ac_exeext
8498  if ${ac_cv_search_clock_gettime+:} false; then :
8499  break
8500fi
8501done
8502if ${ac_cv_search_clock_gettime+:} false; then :
8503
8504else
8505  ac_cv_search_clock_gettime=no
8506fi
8507rm conftest.$ac_ext
8508LIBS=$ac_func_search_save_LIBS
8509fi
8510{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
8511$as_echo "$ac_cv_search_clock_gettime" >&6; }
8512ac_res=$ac_cv_search_clock_gettime
8513if test "$ac_res" != no; then :
8514  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8515  case "$ac_cv_search_clock_gettime" in
8516 'none required') ;;
8517 no) ;;
8518 *) LDADD_LIBNTP="$ac_cv_search_clock_gettime $LDADD_LIBNTP" ;;
8519 esac
8520
8521fi
8522
8523    for ac_func in clock_getres clock_gettime clock_settime
8524do :
8525  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
8526ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
8527if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
8528  cat >>confdefs.h <<_ACEOF
8529#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
8530_ACEOF
8531
8532fi
8533done
8534
8535    ;;
8536esac
8537
8538for ac_func in getclock stime timegm strlcpy strlcat
8539do :
8540  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
8541ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
8542if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
8543  cat >>confdefs.h <<_ACEOF
8544#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
8545_ACEOF
8546
8547fi
8548done
8549
8550
8551# Bug 2713
8552LDADD_LIBUTIL=
8553
8554{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing snprintb" >&5
8555$as_echo_n "checking for library containing snprintb... " >&6; }
8556if ${ac_cv_search_snprintb+:} false; then :
8557  $as_echo_n "(cached) " >&6
8558else
8559  ac_func_search_save_LIBS=$LIBS
8560cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8561/* end confdefs.h.  */
8562
8563/* Override any GCC internal prototype to avoid an error.
8564   Use char because int might match the return type of a GCC
8565   builtin and then its argument prototype would still apply.  */
8566#ifdef __cplusplus
8567extern "C"
8568#endif
8569char snprintb ();
8570int
8571main ()
8572{
8573return snprintb ();
8574  ;
8575  return 0;
8576}
8577_ACEOF
8578for ac_lib in '' util; do
8579  if test -z "$ac_lib"; then
8580    ac_res="none required"
8581  else
8582    ac_res=-l$ac_lib
8583    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8584  fi
8585  if ac_fn_c_try_link "$LINENO"; then :
8586  ac_cv_search_snprintb=$ac_res
8587fi
8588rm -f core conftest.err conftest.$ac_objext \
8589    conftest$ac_exeext
8590  if ${ac_cv_search_snprintb+:} false; then :
8591  break
8592fi
8593done
8594if ${ac_cv_search_snprintb+:} false; then :
8595
8596else
8597  ac_cv_search_snprintb=no
8598fi
8599rm conftest.$ac_ext
8600LIBS=$ac_func_search_save_LIBS
8601fi
8602{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_snprintb" >&5
8603$as_echo "$ac_cv_search_snprintb" >&6; }
8604ac_res=$ac_cv_search_snprintb
8605if test "$ac_res" != no; then :
8606  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8607  case "$ac_cv_search_snprintb" in
8608 'none required') ;;
8609 no) ;;
8610 *) LDADD_LIBUTIL="$ac_cv_search_snprintb $LDADD_LIBUTIL" ;;
8611 esac
8612
8613$as_echo "#define USE_SNPRINTB 1" >>confdefs.h
8614
8615fi
8616
8617
8618#
8619for ac_header in errno.h sys/socket.h sys/types.h time.h
8620do :
8621  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8622ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
8623if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
8624  cat >>confdefs.h <<_ACEOF
8625#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8626_ACEOF
8627
8628fi
8629
8630done
8631
8632for ac_header in net/if.h
8633do :
8634  ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "
8635    #ifdef HAVE_SYS_SOCKET_H
8636    # include <sys/socket.h>
8637    #endif
8638
8639"
8640if test "x$ac_cv_header_net_if_h" = xyes; then :
8641  cat >>confdefs.h <<_ACEOF
8642#define HAVE_NET_IF_H 1
8643_ACEOF
8644
8645fi
8646
8647done
8648
8649case "$host" in
8650 *-hp-hpux*)
8651    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if net/if.h requires mpinfou predeclaration" >&5
8652$as_echo_n "checking if net/if.h requires mpinfou predeclaration... " >&6; }
8653if ${ntp_cv_predecl_mpinfou+:} false; then :
8654  $as_echo_n "(cached) " >&6
8655else
8656
8657	    np_cv_predecl_mpinfou=no
8658	    case "$ac_cv_header_net_if_h" in
8659	     no)
8660		cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8661/* end confdefs.h.  */
8662
8663			    typedef union mpinfou {
8664				    struct pdk_mpinfo *pdkptr;
8665				    struct mpinfo *pikptr;
8666			    } mpinfou_t;
8667			    #ifdef HAVE_SYS_SOCKET_H
8668			    # include <sys/socket.h>
8669			    #endif
8670			    #include <net/if.h>
8671
8672int
8673main ()
8674{
8675
8676
8677
8678  ;
8679  return 0;
8680}
8681_ACEOF
8682if ac_fn_c_try_compile "$LINENO"; then :
8683
8684			ntp_cv_predecl_mpinfou=yes
8685			ac_cv_header_net_if_h=yes
8686
8687
8688fi
8689rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8690	    esac
8691
8692
8693fi
8694{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_predecl_mpinfou" >&5
8695$as_echo "$ntp_cv_predecl_mpinfou" >&6; }
8696    case "$ntp_cv_predecl_mpinfou" in
8697     yes)
8698	cat >>confdefs.h <<_ACEOF
8699#ifndef MPINFOU_PREDECLARED
8700# define MPINFOU_PREDECLARED
8701typedef union mpinfou {
8702	struct pdk_mpinfo *pdkptr;
8703	struct mpinfo *pikptr;
8704} mpinfou_t;
8705#endif
8706_ACEOF
8707
8708    esac
8709esac
8710
8711case "$host" in
8712 *-linux*)
8713    for ac_header in linux/if_addr.h
8714do :
8715  ac_fn_c_check_header_compile "$LINENO" "linux/if_addr.h" "ac_cv_header_linux_if_addr_h" "
8716	#ifdef HAVE_SYS_SOCKET_H
8717	# include <sys/socket.h>
8718	#endif
8719
8720"
8721if test "x$ac_cv_header_linux_if_addr_h" = xyes; then :
8722  cat >>confdefs.h <<_ACEOF
8723#define HAVE_LINUX_IF_ADDR_H 1
8724_ACEOF
8725
8726fi
8727
8728done
8729
8730
8731$as_echo "#define NEED_EARLY_FORK 1" >>confdefs.h
8732
8733esac
8734
8735for ac_header in arpa/nameser.h sys/param.h sys/time.h sys/timers.h
8736do :
8737  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8738ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
8739if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
8740  cat >>confdefs.h <<_ACEOF
8741#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8742_ACEOF
8743
8744fi
8745
8746done
8747
8748# sys/sysctl.h depends on sys/param.h on OpenBSD - Bug 1576
8749for ac_header in sys/sysctl.h
8750do :
8751  ac_fn_c_check_header_compile "$LINENO" "sys/sysctl.h" "ac_cv_header_sys_sysctl_h" "
8752    #if defined HAVE_SYS_PARAM_H
8753    # include <sys/param.h>
8754    #endif
8755
8756"
8757if test "x$ac_cv_header_sys_sysctl_h" = xyes; then :
8758  cat >>confdefs.h <<_ACEOF
8759#define HAVE_SYS_SYSCTL_H 1
8760_ACEOF
8761
8762fi
8763
8764done
8765
8766for ac_header in netinet/in_system.h netinet/in_systm.h netinet/in.h
8767do :
8768  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8769ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
8770if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
8771  cat >>confdefs.h <<_ACEOF
8772#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8773_ACEOF
8774
8775fi
8776
8777done
8778
8779
8780for ac_header in resolv.h
8781do :
8782  ac_fn_c_check_header_compile "$LINENO" "resolv.h" "ac_cv_header_resolv_h" "
8783    #ifdef HAVE_SYS_TYPES_H
8784    # include <sys/types.h>
8785    #endif
8786    #ifdef HAVE_NETINET_IN_H
8787    # include <netinet/in.h>
8788    #endif
8789    #ifdef HAVE_ARPA_NAMESER_H
8790    # include <arpa/nameser.h>
8791    #endif
8792
8793"
8794if test "x$ac_cv_header_resolv_h" = xyes; then :
8795  cat >>confdefs.h <<_ACEOF
8796#define HAVE_RESOLV_H 1
8797_ACEOF
8798
8799fi
8800
8801done
8802
8803
8804for ac_header in net/if_var.h
8805do :
8806  ac_fn_c_check_header_compile "$LINENO" "net/if_var.h" "ac_cv_header_net_if_var_h" "
8807    #if HAVE_SYS_TYPES_H
8808    # include <sys/types.h>
8809    #endif
8810    #ifdef HAVE_SYS_SOCKET_H
8811    # include <sys/socket.h>
8812    #endif
8813    #ifdef HAVE_NETINET_IN_H
8814    # include <netinet/in.h>
8815    #endif
8816    #ifdef HAVE_NET_IF_H
8817    # include <net/if.h>
8818    #endif
8819
8820"
8821if test "x$ac_cv_header_net_if_var_h" = xyes; then :
8822  cat >>confdefs.h <<_ACEOF
8823#define HAVE_NET_IF_VAR_H 1
8824_ACEOF
8825
8826fi
8827
8828done
8829
8830
8831for ac_header in netinet/ip.h netinet/in_var.h
8832do :
8833  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8834ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "
8835    #ifdef HAVE_SYS_TYPES_H
8836    # include <sys/types.h>
8837    #endif
8838    #ifdef HAVE_SYS_SOCKET_H
8839    # include <sys/socket.h>
8840    #endif
8841    #ifdef HAVE_NET_IF_H
8842    # include <net/if.h>
8843    #endif
8844    #ifdef HAVE_NETINET_IN_H
8845    # include <netinet/in.h>
8846    #endif
8847    #ifdef HAVE_NET_IF_VAR_H
8848    # include <net/if_var.h>
8849    #endif
8850    #ifdef HAVE_NETINET_IN_SYSTM_H
8851    # include <netinet/in_systm.h>
8852    #endif
8853
8854"
8855if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
8856  cat >>confdefs.h <<_ACEOF
8857#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8858_ACEOF
8859
8860fi
8861
8862done
8863
8864
8865# HMS: Do we need to check for -lsocket before or after these tests?
8866{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing inet_pton" >&5
8867$as_echo_n "checking for library containing inet_pton... " >&6; }
8868if ${ac_cv_search_inet_pton+:} false; then :
8869  $as_echo_n "(cached) " >&6
8870else
8871  ac_func_search_save_LIBS=$LIBS
8872cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8873/* end confdefs.h.  */
8874
8875/* Override any GCC internal prototype to avoid an error.
8876   Use char because int might match the return type of a GCC
8877   builtin and then its argument prototype would still apply.  */
8878#ifdef __cplusplus
8879extern "C"
8880#endif
8881char inet_pton ();
8882int
8883main ()
8884{
8885return inet_pton ();
8886  ;
8887  return 0;
8888}
8889_ACEOF
8890for ac_lib in '' nsl; do
8891  if test -z "$ac_lib"; then
8892    ac_res="none required"
8893  else
8894    ac_res=-l$ac_lib
8895    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8896  fi
8897  if ac_fn_c_try_link "$LINENO"; then :
8898  ac_cv_search_inet_pton=$ac_res
8899fi
8900rm -f core conftest.err conftest.$ac_objext \
8901    conftest$ac_exeext
8902  if ${ac_cv_search_inet_pton+:} false; then :
8903  break
8904fi
8905done
8906if ${ac_cv_search_inet_pton+:} false; then :
8907
8908else
8909  ac_cv_search_inet_pton=no
8910fi
8911rm conftest.$ac_ext
8912LIBS=$ac_func_search_save_LIBS
8913fi
8914{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_inet_pton" >&5
8915$as_echo "$ac_cv_search_inet_pton" >&6; }
8916ac_res=$ac_cv_search_inet_pton
8917if test "$ac_res" != no; then :
8918  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8919  case "$ac_cv_search_inet_pton" in
8920 'none required') ;;
8921 no) ;;
8922 *) LDADD_LIBNTP="$ac_cv_search_inet_pton $LDADD_LIBNTP" ;;
8923 esac
8924
8925fi
8926
8927{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing inet_ntop" >&5
8928$as_echo_n "checking for library containing inet_ntop... " >&6; }
8929if ${ac_cv_search_inet_ntop+:} false; then :
8930  $as_echo_n "(cached) " >&6
8931else
8932  ac_func_search_save_LIBS=$LIBS
8933cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8934/* end confdefs.h.  */
8935
8936/* Override any GCC internal prototype to avoid an error.
8937   Use char because int might match the return type of a GCC
8938   builtin and then its argument prototype would still apply.  */
8939#ifdef __cplusplus
8940extern "C"
8941#endif
8942char inet_ntop ();
8943int
8944main ()
8945{
8946return inet_ntop ();
8947  ;
8948  return 0;
8949}
8950_ACEOF
8951for ac_lib in '' resolv; do
8952  if test -z "$ac_lib"; then
8953    ac_res="none required"
8954  else
8955    ac_res=-l$ac_lib
8956    LIBS="-l$ac_lib -lnsl $ac_func_search_save_LIBS"
8957  fi
8958  if ac_fn_c_try_link "$LINENO"; then :
8959  ac_cv_search_inet_ntop=$ac_res
8960fi
8961rm -f core conftest.err conftest.$ac_objext \
8962    conftest$ac_exeext
8963  if ${ac_cv_search_inet_ntop+:} false; then :
8964  break
8965fi
8966done
8967if ${ac_cv_search_inet_ntop+:} false; then :
8968
8969else
8970  ac_cv_search_inet_ntop=no
8971fi
8972rm conftest.$ac_ext
8973LIBS=$ac_func_search_save_LIBS
8974fi
8975{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_inet_ntop" >&5
8976$as_echo "$ac_cv_search_inet_ntop" >&6; }
8977ac_res=$ac_cv_search_inet_ntop
8978if test "$ac_res" != no; then :
8979  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8980  case "$ac_cv_search_inet_ntop" in
8981 'none required') ;;
8982 no) ;;
8983 *) LDADD_LIBNTP="$ac_cv_search_inet_ntop $LDADD_LIBNTP" ;;
8984 esac
8985
8986fi
8987
8988
8989# [Bug 1628] On Solaris, we need -lxnet -lsocket.  Generalize this to
8990# avoid keying on the OS name:  If we find socket functions in
8991# libsocket, next try for them in libxnet without libsocket, if found,
8992# list both.  If we simply tested libxnet first, we would find the
8993# functions there and never add libsocket.  See also [Bug 660]
8994# http://bugs.ntp.org/show_bug.cgi?id=660#c9
8995saved_LIBS=$LIBS
8996{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing setsockopt" >&5
8997$as_echo_n "checking for library containing setsockopt... " >&6; }
8998if ${ac_cv_search_setsockopt+:} false; then :
8999  $as_echo_n "(cached) " >&6
9000else
9001  ac_func_search_save_LIBS=$LIBS
9002cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9003/* end confdefs.h.  */
9004
9005/* Override any GCC internal prototype to avoid an error.
9006   Use char because int might match the return type of a GCC
9007   builtin and then its argument prototype would still apply.  */
9008#ifdef __cplusplus
9009extern "C"
9010#endif
9011char setsockopt ();
9012int
9013main ()
9014{
9015return setsockopt ();
9016  ;
9017  return 0;
9018}
9019_ACEOF
9020for ac_lib in '' socket; do
9021  if test -z "$ac_lib"; then
9022    ac_res="none required"
9023  else
9024    ac_res=-l$ac_lib
9025    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
9026  fi
9027  if ac_fn_c_try_link "$LINENO"; then :
9028  ac_cv_search_setsockopt=$ac_res
9029fi
9030rm -f core conftest.err conftest.$ac_objext \
9031    conftest$ac_exeext
9032  if ${ac_cv_search_setsockopt+:} false; then :
9033  break
9034fi
9035done
9036if ${ac_cv_search_setsockopt+:} false; then :
9037
9038else
9039  ac_cv_search_setsockopt=no
9040fi
9041rm conftest.$ac_ext
9042LIBS=$ac_func_search_save_LIBS
9043fi
9044{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_setsockopt" >&5
9045$as_echo "$ac_cv_search_setsockopt" >&6; }
9046ac_res=$ac_cv_search_setsockopt
9047if test "$ac_res" != no; then :
9048  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
9049  case "$ac_cv_search_setsockopt" in
9050 'none required') ;;
9051 no) ;;
9052 *) LDADD_LIBNTP="$ac_cv_search_setsockopt $LDADD_LIBNTP" ;;
9053 esac
9054
9055fi
9056
9057case "$ac_cv_search_setsockopt" in
9058 -lsocket)
9059    LIBS="$saved_LIBS"
9060    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing getsockopt" >&5
9061$as_echo_n "checking for library containing getsockopt... " >&6; }
9062if ${ac_cv_search_getsockopt+:} false; then :
9063  $as_echo_n "(cached) " >&6
9064else
9065  ac_func_search_save_LIBS=$LIBS
9066cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9067/* end confdefs.h.  */
9068
9069/* Override any GCC internal prototype to avoid an error.
9070   Use char because int might match the return type of a GCC
9071   builtin and then its argument prototype would still apply.  */
9072#ifdef __cplusplus
9073extern "C"
9074#endif
9075char getsockopt ();
9076int
9077main ()
9078{
9079return getsockopt ();
9080  ;
9081  return 0;
9082}
9083_ACEOF
9084for ac_lib in '' xnet; do
9085  if test -z "$ac_lib"; then
9086    ac_res="none required"
9087  else
9088    ac_res=-l$ac_lib
9089    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
9090  fi
9091  if ac_fn_c_try_link "$LINENO"; then :
9092  ac_cv_search_getsockopt=$ac_res
9093fi
9094rm -f core conftest.err conftest.$ac_objext \
9095    conftest$ac_exeext
9096  if ${ac_cv_search_getsockopt+:} false; then :
9097  break
9098fi
9099done
9100if ${ac_cv_search_getsockopt+:} false; then :
9101
9102else
9103  ac_cv_search_getsockopt=no
9104fi
9105rm conftest.$ac_ext
9106LIBS=$ac_func_search_save_LIBS
9107fi
9108{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_getsockopt" >&5
9109$as_echo "$ac_cv_search_getsockopt" >&6; }
9110ac_res=$ac_cv_search_getsockopt
9111if test "$ac_res" != no; then :
9112  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
9113  case "$ac_cv_search_getsockopt" in
9114 'none required') ;;
9115 no) ;;
9116 *) LDADD_LIBNTP="$ac_cv_search_getsockopt $LDADD_LIBNTP" ;;
9117 esac
9118
9119fi
9120
9121    # XXX Possible trouble here - reading the comments above and looking at the
9122    # code below I wonder if we'll add -lxnet when we don't need it.
9123    # Also, do we need to add -lxnet to LDADD_LIBNTP, or perhaps see if it's
9124    # there when it is not needed?
9125    case "$ac_cv_search_getsockopt" in
9126     -lxnet)
9127	LIBS="-lxnet -lsocket $saved_LIBS"
9128	;;
9129     *) LIBS="-lsocket $saved_LIBS"
9130	;;
9131    esac
9132    ;;
9133esac
9134{ saved_LIBS=; unset saved_LIBS;}
9135
9136# Bug 2427 - look for recvmsg here.
9137for ac_func in recvmsg
9138do :
9139  ac_fn_c_check_func "$LINENO" "recvmsg" "ac_cv_func_recvmsg"
9140if test "x$ac_cv_func_recvmsg" = xyes; then :
9141  cat >>confdefs.h <<_ACEOF
9142#define HAVE_RECVMSG 1
9143_ACEOF
9144
9145fi
9146done
9147
9148
9149{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
9150$as_echo_n "checking for inline... " >&6; }
9151if ${ac_cv_c_inline+:} false; then :
9152  $as_echo_n "(cached) " >&6
9153else
9154  ac_cv_c_inline=no
9155for ac_kw in inline __inline__ __inline; do
9156  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9157/* end confdefs.h.  */
9158#ifndef __cplusplus
9159typedef int foo_t;
9160static $ac_kw foo_t static_foo () {return 0; }
9161$ac_kw foo_t foo () {return 0; }
9162#endif
9163
9164_ACEOF
9165if ac_fn_c_try_compile "$LINENO"; then :
9166  ac_cv_c_inline=$ac_kw
9167fi
9168rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9169  test "$ac_cv_c_inline" != no && break
9170done
9171
9172fi
9173{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
9174$as_echo "$ac_cv_c_inline" >&6; }
9175
9176case $ac_cv_c_inline in
9177  inline | yes) ;;
9178  *)
9179    case $ac_cv_c_inline in
9180      no) ac_val=;;
9181      *) ac_val=$ac_cv_c_inline;;
9182    esac
9183    cat >>confdefs.h <<_ACEOF
9184#ifndef __cplusplus
9185#define inline $ac_val
9186#endif
9187_ACEOF
9188    ;;
9189esac
9190
9191
9192case "$ac_cv_c_inline" in
9193 '')
9194    ;;
9195 *)
9196
9197$as_echo "#define HAVE_INLINE 1" >>confdefs.h
9198
9199
9200esac
9201
9202{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
9203$as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
9204if ${ac_cv_header_time+:} false; then :
9205  $as_echo_n "(cached) " >&6
9206else
9207  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9208/* end confdefs.h.  */
9209#include <sys/types.h>
9210#include <sys/time.h>
9211#include <time.h>
9212
9213int
9214main ()
9215{
9216if ((struct tm *) 0)
9217return 0;
9218  ;
9219  return 0;
9220}
9221_ACEOF
9222if ac_fn_c_try_compile "$LINENO"; then :
9223  ac_cv_header_time=yes
9224else
9225  ac_cv_header_time=no
9226fi
9227rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9228fi
9229{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
9230$as_echo "$ac_cv_header_time" >&6; }
9231if test $ac_cv_header_time = yes; then
9232
9233$as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
9234
9235fi
9236
9237# The cast to long int works around a bug in the HP C Compiler
9238# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9239# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9240# This bug is HP SR number 8606223364.
9241{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of time_t" >&5
9242$as_echo_n "checking size of time_t... " >&6; }
9243if ${ac_cv_sizeof_time_t+:} false; then :
9244  $as_echo_n "(cached) " >&6
9245else
9246  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (time_t))" "ac_cv_sizeof_time_t"        "$ac_includes_default"; then :
9247
9248else
9249  if test "$ac_cv_type_time_t" = yes; then
9250     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9251$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9252as_fn_error 77 "cannot compute sizeof (time_t)
9253See \`config.log' for more details" "$LINENO" 5; }
9254   else
9255     ac_cv_sizeof_time_t=0
9256   fi
9257fi
9258
9259fi
9260{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_time_t" >&5
9261$as_echo "$ac_cv_sizeof_time_t" >&6; }
9262
9263
9264
9265cat >>confdefs.h <<_ACEOF
9266#define SIZEOF_TIME_T $ac_cv_sizeof_time_t
9267_ACEOF
9268
9269
9270{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether char is unsigned" >&5
9271$as_echo_n "checking whether char is unsigned... " >&6; }
9272if ${ac_cv_c_char_unsigned+:} false; then :
9273  $as_echo_n "(cached) " >&6
9274else
9275  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9276/* end confdefs.h.  */
9277$ac_includes_default
9278int
9279main ()
9280{
9281static int test_array [1 - 2 * !(((char) -1) < 0)];
9282test_array [0] = 0;
9283return test_array [0];
9284
9285  ;
9286  return 0;
9287}
9288_ACEOF
9289if ac_fn_c_try_compile "$LINENO"; then :
9290  ac_cv_c_char_unsigned=no
9291else
9292  ac_cv_c_char_unsigned=yes
9293fi
9294rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9295fi
9296{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_char_unsigned" >&5
9297$as_echo "$ac_cv_c_char_unsigned" >&6; }
9298if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then
9299  $as_echo "#define __CHAR_UNSIGNED__ 1" >>confdefs.h
9300
9301fi
9302		# The cast to long int works around a bug in the HP C Compiler
9303# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9304# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9305# This bug is HP SR number 8606223364.
9306{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of signed char" >&5
9307$as_echo_n "checking size of signed char... " >&6; }
9308if ${ac_cv_sizeof_signed_char+:} false; then :
9309  $as_echo_n "(cached) " >&6
9310else
9311  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (signed char))" "ac_cv_sizeof_signed_char"        "$ac_includes_default"; then :
9312
9313else
9314  if test "$ac_cv_type_signed_char" = yes; then
9315     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9316$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9317as_fn_error 77 "cannot compute sizeof (signed char)
9318See \`config.log' for more details" "$LINENO" 5; }
9319   else
9320     ac_cv_sizeof_signed_char=0
9321   fi
9322fi
9323
9324fi
9325{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_signed_char" >&5
9326$as_echo "$ac_cv_sizeof_signed_char" >&6; }
9327
9328
9329
9330cat >>confdefs.h <<_ACEOF
9331#define SIZEOF_SIGNED_CHAR $ac_cv_sizeof_signed_char
9332_ACEOF
9333
9334
9335ac_fn_c_check_type "$LINENO" "s_char" "ac_cv_type_s_char" "$ac_includes_default"
9336if test "x$ac_cv_type_s_char" = xyes; then :
9337
9338cat >>confdefs.h <<_ACEOF
9339#define HAVE_S_CHAR 1
9340_ACEOF
9341
9342
9343fi
9344ac_fn_c_check_type "$LINENO" "long long" "ac_cv_type_long_long" "$ac_includes_default"
9345if test "x$ac_cv_type_long_long" = xyes; then :
9346
9347cat >>confdefs.h <<_ACEOF
9348#define HAVE_LONG_LONG 1
9349_ACEOF
9350
9351
9352fi
9353
9354# The cast to long int works around a bug in the HP C Compiler
9355# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9356# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9357# This bug is HP SR number 8606223364.
9358{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5
9359$as_echo_n "checking size of short... " >&6; }
9360if ${ac_cv_sizeof_short+:} false; then :
9361  $as_echo_n "(cached) " >&6
9362else
9363  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (short))" "ac_cv_sizeof_short"        "$ac_includes_default"; then :
9364
9365else
9366  if test "$ac_cv_type_short" = yes; then
9367     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9368$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9369as_fn_error 77 "cannot compute sizeof (short)
9370See \`config.log' for more details" "$LINENO" 5; }
9371   else
9372     ac_cv_sizeof_short=0
9373   fi
9374fi
9375
9376fi
9377{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5
9378$as_echo "$ac_cv_sizeof_short" >&6; }
9379
9380
9381
9382cat >>confdefs.h <<_ACEOF
9383#define SIZEOF_SHORT $ac_cv_sizeof_short
9384_ACEOF
9385
9386
9387# The cast to long int works around a bug in the HP C Compiler
9388# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9389# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9390# This bug is HP SR number 8606223364.
9391{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5
9392$as_echo_n "checking size of int... " >&6; }
9393if ${ac_cv_sizeof_int+:} false; then :
9394  $as_echo_n "(cached) " >&6
9395else
9396  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int"        "$ac_includes_default"; then :
9397
9398else
9399  if test "$ac_cv_type_int" = yes; then
9400     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9401$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9402as_fn_error 77 "cannot compute sizeof (int)
9403See \`config.log' for more details" "$LINENO" 5; }
9404   else
9405     ac_cv_sizeof_int=0
9406   fi
9407fi
9408
9409fi
9410{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5
9411$as_echo "$ac_cv_sizeof_int" >&6; }
9412
9413
9414
9415cat >>confdefs.h <<_ACEOF
9416#define SIZEOF_INT $ac_cv_sizeof_int
9417_ACEOF
9418
9419
9420# The cast to long int works around a bug in the HP C Compiler
9421# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9422# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9423# This bug is HP SR number 8606223364.
9424{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
9425$as_echo_n "checking size of long... " >&6; }
9426if ${ac_cv_sizeof_long+:} false; then :
9427  $as_echo_n "(cached) " >&6
9428else
9429  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long"        "$ac_includes_default"; then :
9430
9431else
9432  if test "$ac_cv_type_long" = yes; then
9433     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9434$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9435as_fn_error 77 "cannot compute sizeof (long)
9436See \`config.log' for more details" "$LINENO" 5; }
9437   else
9438     ac_cv_sizeof_long=0
9439   fi
9440fi
9441
9442fi
9443{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
9444$as_echo "$ac_cv_sizeof_long" >&6; }
9445
9446
9447
9448cat >>confdefs.h <<_ACEOF
9449#define SIZEOF_LONG $ac_cv_sizeof_long
9450_ACEOF
9451
9452
9453
9454case "$ac_cv_type_long_long" in
9455 no)
9456    ;;
9457 *)
9458    # The cast to long int works around a bug in the HP C Compiler
9459# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9460# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9461# This bug is HP SR number 8606223364.
9462{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5
9463$as_echo_n "checking size of long long... " >&6; }
9464if ${ac_cv_sizeof_long_long+:} false; then :
9465  $as_echo_n "(cached) " >&6
9466else
9467  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long"        "$ac_includes_default"; then :
9468
9469else
9470  if test "$ac_cv_type_long_long" = yes; then
9471     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9472$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9473as_fn_error 77 "cannot compute sizeof (long long)
9474See \`config.log' for more details" "$LINENO" 5; }
9475   else
9476     ac_cv_sizeof_long_long=0
9477   fi
9478fi
9479
9480fi
9481{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5
9482$as_echo "$ac_cv_sizeof_long_long" >&6; }
9483
9484
9485
9486cat >>confdefs.h <<_ACEOF
9487#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
9488_ACEOF
9489
9490
9491    ;;
9492esac
9493
9494case "$ac_cv_c_char_unsigned$ac_cv_sizeof_signed_char$ac_cv_type_s_char" in
9495 *yes)
9496    # We have a typedef for s_char.  Might as well believe it...
9497    ;;
9498 no0no)
9499    # We have signed chars, can't say 'signed char', no s_char typedef.
9500
9501$as_echo "#define NEED_S_CHAR_TYPEDEF 1" >>confdefs.h
9502
9503    ;;
9504 no1no)
9505    # We have signed chars, can say 'signed char', no s_char typedef.
9506
9507$as_echo "#define NEED_S_CHAR_TYPEDEF 1" >>confdefs.h
9508
9509    ;;
9510 yes0no)
9511    # We have unsigned chars, can't say 'signed char', no s_char typedef.
9512    as_fn_error $? "No way to specify a signed character!" "$LINENO" 5
9513    ;;
9514 yes1no)
9515    # We have unsigned chars, can say 'signed char', no s_char typedef.
9516
9517$as_echo "#define NEED_S_CHAR_TYPEDEF 1" >>confdefs.h
9518
9519    ;;
9520esac
9521
9522{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5
9523$as_echo_n "checking for uid_t in sys/types.h... " >&6; }
9524if ${ac_cv_type_uid_t+:} false; then :
9525  $as_echo_n "(cached) " >&6
9526else
9527  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9528/* end confdefs.h.  */
9529#include <sys/types.h>
9530
9531_ACEOF
9532if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9533  $EGREP "uid_t" >/dev/null 2>&1; then :
9534  ac_cv_type_uid_t=yes
9535else
9536  ac_cv_type_uid_t=no
9537fi
9538rm -f conftest*
9539
9540fi
9541{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5
9542$as_echo "$ac_cv_type_uid_t" >&6; }
9543if test $ac_cv_type_uid_t = no; then
9544
9545$as_echo "#define uid_t int" >>confdefs.h
9546
9547
9548$as_echo "#define gid_t int" >>confdefs.h
9549
9550fi
9551
9552
9553
9554
9555
9556
9557{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we're including debugging code" >&5
9558$as_echo_n "checking if we're including debugging code... " >&6; }
9559# Check whether --enable-debugging was given.
9560if test "${enable_debugging+set}" = set; then :
9561  enableval=$enable_debugging; ntp_ok=$enableval
9562else
9563  ntp_ok=yes
9564
9565fi
9566
9567case "$ntp_ok" in
9568 yes)
9569
9570$as_echo "#define DEBUG 1" >>confdefs.h
9571
9572esac
9573{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
9574$as_echo "$ntp_ok" >&6; }
9575
9576
9577
9578# check if we can compile with pthreads
9579for ac_header in semaphore.h
9580do :
9581  ac_fn_c_check_header_mongrel "$LINENO" "semaphore.h" "ac_cv_header_semaphore_h" "$ac_includes_default"
9582if test "x$ac_cv_header_semaphore_h" = xyes; then :
9583  cat >>confdefs.h <<_ACEOF
9584#define HAVE_SEMAPHORE_H 1
9585_ACEOF
9586
9587fi
9588
9589done
9590
9591for ac_func in socketpair
9592do :
9593  ac_fn_c_check_func "$LINENO" "socketpair" "ac_cv_func_socketpair"
9594if test "x$ac_cv_func_socketpair" = xyes; then :
9595  cat >>confdefs.h <<_ACEOF
9596#define HAVE_SOCKETPAIR 1
9597_ACEOF
9598
9599fi
9600done
9601
9602# Check whether --enable-thread-support was given.
9603if test "${enable_thread_support+set}" = set; then :
9604  enableval=$enable_thread_support;
9605else
9606  enable_thread_support=yes
9607
9608fi
9609
9610have_pthreads=no
9611case "$enable_thread_support" in
9612 no) ;;
9613 *)
9614    ol_found_pthreads=no
9615
9616
9617
9618ac_ext=c
9619ac_cpp='$CPP $CPPFLAGS'
9620ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
9621ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
9622ac_compiler_gnu=$ac_cv_c_compiler_gnu
9623
9624# OpenLDAP --with-threads
9625
9626# Check whether --with-threads was given.
9627if test "${with_threads+set}" = set; then :
9628  withval=$with_threads;
9629	ol_arg=invalid
9630	for ol_val in auto nt posix mach pth lwp yes no manual  ; do
9631		if test "$withval" = "$ol_val" ; then
9632			ol_arg="$ol_val"
9633		fi
9634	done
9635	if test "$ol_arg" = "invalid" ; then
9636		as_fn_error $? "bad value $withval for --with-threads" "$LINENO" 5
9637	fi
9638	ol_with_threads="$ol_arg"
9639
9640else
9641  	ol_with_threads="auto"
9642fi
9643# end --with-threads
9644
9645
9646case "$ol_with_threads$host" in
9647 auto*-*-solaris2.[0-6])
9648        ol_with_threads=no
9649    ;;
9650esac
9651
9652
9653ol_aix_threads=no
9654case "$host" in
9655*-*-aix*) 	if test -z "$CC" ; then
9656		case "$ol_with_threads" in
9657		auto | yes |  posix) ol_aix_threads=yes ;;
9658		esac
9659	fi
9660;;
9661esac
9662
9663if test $ol_aix_threads = yes ; then
9664	if test -z "${CC}" ; then
9665		for ac_prog in cc_r xlc_r cc
9666do
9667  # Extract the first word of "$ac_prog", so it can be a program name with args.
9668set dummy $ac_prog; ac_word=$2
9669{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9670$as_echo_n "checking for $ac_word... " >&6; }
9671if ${ac_cv_prog_CC+:} false; then :
9672  $as_echo_n "(cached) " >&6
9673else
9674  if test -n "$CC"; then
9675  ac_cv_prog_CC="$CC" # Let the user override the test.
9676else
9677as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9678for as_dir in $PATH
9679do
9680  IFS=$as_save_IFS
9681  test -z "$as_dir" && as_dir=.
9682    for ac_exec_ext in '' $ac_executable_extensions; do
9683  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9684    ac_cv_prog_CC="$ac_prog"
9685    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9686    break 2
9687  fi
9688done
9689  done
9690IFS=$as_save_IFS
9691
9692fi
9693fi
9694CC=$ac_cv_prog_CC
9695if test -n "$CC"; then
9696  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
9697$as_echo "$CC" >&6; }
9698else
9699  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9700$as_echo "no" >&6; }
9701fi
9702
9703
9704  test -n "$CC" && break
9705done
9706
9707
9708		if test "$CC" = cc ; then
9709						if test $ol_with_threads != auto ; then
9710				as_fn_error $? "--with-threads requires cc_r (or other suitable compiler) on AIX" "$LINENO" 5
9711			else
9712				{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: disabling threads, no cc_r on AIX" >&5
9713$as_echo "$as_me: WARNING: disabling threads, no cc_r on AIX" >&2;}
9714			fi
9715			ol_with_threads=no
9716  		fi
9717	fi
9718
9719	case ${CC} in cc_r | xlc_r)
9720		ol_with_threads=posix
9721		ol_cv_pthread_create=yes
9722		;;
9723	esac
9724fi
9725
9726ol_link_threads=no
9727# OpenLDAP --with-yielding_select
9728
9729# Check whether --with-yielding_select was given.
9730if test "${with_yielding_select+set}" = set; then :
9731  withval=$with_yielding_select;
9732	ol_arg=invalid
9733	for ol_val in auto yes no manual  ; do
9734		if test "$withval" = "$ol_val" ; then
9735			ol_arg="$ol_val"
9736		fi
9737	done
9738	if test "$ol_arg" = "invalid" ; then
9739		as_fn_error $? "bad value $withval for --with-yielding_select" "$LINENO" 5
9740	fi
9741	ol_with_yielding_select="$ol_arg"
9742
9743else
9744  	ol_with_yielding_select="auto"
9745fi
9746# end --with-yielding_select
9747
9748
9749case $ol_with_threads in auto | yes | nt)
9750
9751
9752	ac_fn_c_check_func "$LINENO" "_beginthread" "ac_cv_func__beginthread"
9753if test "x$ac_cv_func__beginthread" = xyes; then :
9754
9755fi
9756
9757
9758	if test $ac_cv_func__beginthread = yes ; then
9759
9760$as_echo "#define HAVE_NT_THREADS 1" >>confdefs.h
9761
9762		ol_cv_nt_threads=yes
9763	fi
9764
9765
9766	if test "$ol_cv_nt_threads" = yes ; then
9767		ol_link_threads=nt
9768		ol_with_threads=found
9769		ol_with_yielding_select=yes
9770
9771
9772$as_echo "#define HAVE_NT_SERVICE_MANAGER 1" >>confdefs.h
9773
9774
9775$as_echo "#define HAVE_NT_EVENT_LOG 1" >>confdefs.h
9776
9777	fi
9778
9779	if test $ol_with_threads = nt ; then
9780		as_fn_error $? "could not locate NT Threads" "$LINENO" 5
9781	fi
9782	;;
9783esac
9784
9785case $ol_with_threads in auto | yes | posix)
9786
9787	for ac_header in pthread.h
9788do :
9789  ac_fn_c_check_header_mongrel "$LINENO" "pthread.h" "ac_cv_header_pthread_h" "$ac_includes_default"
9790if test "x$ac_cv_header_pthread_h" = xyes; then :
9791  cat >>confdefs.h <<_ACEOF
9792#define HAVE_PTHREAD_H 1
9793_ACEOF
9794
9795fi
9796
9797done
9798
9799
9800	if test $ac_cv_header_pthread_h = yes ; then
9801		{ $as_echo "$as_me:${as_lineno-$LINENO}: checking POSIX thread version" >&5
9802$as_echo_n "checking POSIX thread version... " >&6; }
9803if ${ol_cv_pthread_version+:} false; then :
9804  $as_echo_n "(cached) " >&6
9805else
9806
9807	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9808/* end confdefs.h.  */
9809
9810#		include <pthread.h>
9811
9812int
9813main ()
9814{
9815
9816		int i = PTHREAD_CREATE_JOINABLE;
9817
9818  ;
9819  return 0;
9820}
9821_ACEOF
9822if ac_fn_c_try_compile "$LINENO"; then :
9823
9824	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9825/* end confdefs.h.  */
9826#include <pthread.h>
9827
9828_ACEOF
9829if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9830  $EGREP "pthread_detach" >/dev/null 2>&1; then :
9831  ol_cv_pthread_version=10
9832else
9833  ol_cv_pthread_version=8
9834fi
9835rm -f conftest*
9836
9837else
9838
9839	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9840/* end confdefs.h.  */
9841
9842#		include <pthread.h>
9843#		ifdef PTHREAD_CREATE_UNDETACHED
9844		draft7
9845#		endif
9846
9847_ACEOF
9848if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9849  $EGREP "draft7" >/dev/null 2>&1; then :
9850  ol_cv_pthread_version=7
9851else
9852
9853	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9854/* end confdefs.h.  */
9855#include <pthread.h>
9856
9857_ACEOF
9858if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9859  $EGREP "pthread_attr_init" >/dev/null 2>&1; then :
9860  ol_cv_pthread_version=6
9861else
9862
9863	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9864/* end confdefs.h.  */
9865
9866#		include <pthread.h>
9867#ifdef		PTHREAD_MUTEX_INITIALIZER
9868		draft5
9869#endif
9870
9871_ACEOF
9872if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9873  $EGREP "draft5" >/dev/null 2>&1; then :
9874  ol_cv_pthread_version=5
9875else
9876  ol_cv_pthread_version=4
9877fi
9878rm -f conftest*
9879
9880fi
9881rm -f conftest*
9882
9883fi
9884rm -f conftest*
9885
9886fi
9887rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9888
9889fi
9890{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_version" >&5
9891$as_echo "$ol_cv_pthread_version" >&6; }
9892
9893
9894		if test $ol_cv_pthread_version != 0 ; then
9895
9896cat >>confdefs.h <<_ACEOF
9897#define HAVE_PTHREADS $ol_cv_pthread_version
9898_ACEOF
9899
9900		else
9901			as_fn_error $? "unknown pthread version" "$LINENO" 5
9902		fi
9903
9904		# consider threads found
9905		ol_with_threads=found
9906
9907
9908	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LinuxThreads pthread.h" >&5
9909$as_echo_n "checking for LinuxThreads pthread.h... " >&6; }
9910if ${ol_cv_header_linux_threads+:} false; then :
9911  $as_echo_n "(cached) " >&6
9912else
9913  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9914/* end confdefs.h.  */
9915#include <pthread.h>
9916_ACEOF
9917if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9918  $EGREP "pthread_kill_other_threads_np" >/dev/null 2>&1; then :
9919  ol_cv_header_linux_threads=yes
9920else
9921  ol_cv_header_linux_threads=no
9922fi
9923rm -f conftest*
9924
9925
9926fi
9927{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_header_linux_threads" >&5
9928$as_echo "$ol_cv_header_linux_threads" >&6; }
9929	if test $ol_cv_header_linux_threads = yes; then
9930
9931$as_echo "#define HAVE_LINUX_THREADS 1" >>confdefs.h
9932
9933	fi
9934
9935
9936	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU Pth pthread.h" >&5
9937$as_echo_n "checking for GNU Pth pthread.h... " >&6; }
9938if ${ol_cv_header_gnu_pth_pthread_h+:} false; then :
9939  $as_echo_n "(cached) " >&6
9940else
9941  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9942/* end confdefs.h.  */
9943#include <pthread.h>
9944#ifdef _POSIX_THREAD_IS_GNU_PTH
9945	__gnu_pth__;
9946#endif
9947
9948_ACEOF
9949if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9950  $EGREP "__gnu_pth__" >/dev/null 2>&1; then :
9951  ol_cv_header_gnu_pth_pthread_h=yes
9952else
9953  ol_cv_header_gnu_pth_pthread_h=no
9954fi
9955rm -f conftest*
9956
9957
9958fi
9959{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_header_gnu_pth_pthread_h" >&5
9960$as_echo "$ol_cv_header_gnu_pth_pthread_h" >&6; }
9961
9962
9963		if test $ol_cv_header_gnu_pth_pthread_h = no ; then
9964			for ac_header in sched.h
9965do :
9966  ac_fn_c_check_header_mongrel "$LINENO" "sched.h" "ac_cv_header_sched_h" "$ac_includes_default"
9967if test "x$ac_cv_header_sched_h" = xyes; then :
9968  cat >>confdefs.h <<_ACEOF
9969#define HAVE_SCHED_H 1
9970_ACEOF
9971
9972fi
9973
9974done
9975
9976		fi
9977
9978
9979				{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in default libraries" >&5
9980$as_echo_n "checking for pthread_create in default libraries... " >&6; }
9981if ${ol_cv_pthread_create+:} false; then :
9982  $as_echo_n "(cached) " >&6
9983else
9984
9985			if test "$cross_compiling" = yes; then :
9986  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9987/* end confdefs.h.  */
9988
9989/* pthread test headers */
9990#include <pthread.h>
9991#if HAVE_PTHREADS < 7
9992#include <errno.h>
9993#endif
9994#ifndef NULL
9995#define NULL (void*)0
9996#endif
9997
9998static void *task(p)
9999	void *p;
10000{
10001	return (void *) (p == NULL);
10002}
10003
10004int
10005main ()
10006{
10007
10008	/* pthread test function */
10009#ifndef PTHREAD_CREATE_DETACHED
10010#define	PTHREAD_CREATE_DETACHED	1
10011#endif
10012	pthread_t t;
10013	int status;
10014	int detach = PTHREAD_CREATE_DETACHED;
10015
10016#if HAVE_PTHREADS > 4
10017	/* Final pthreads */
10018	pthread_attr_t attr;
10019
10020	status = pthread_attr_init(&attr);
10021	if( status ) return status;
10022
10023#if HAVE_PTHREADS < 7
10024	status = pthread_attr_setdetachstate(&attr, &detach);
10025	if( status < 0 ) status = errno;
10026#else
10027	status = pthread_attr_setdetachstate(&attr, detach);
10028#endif
10029	if( status ) return status;
10030	status = pthread_create( &t, &attr, task, NULL );
10031#if HAVE_PTHREADS < 7
10032	if( status < 0 ) status = errno;
10033#endif
10034	if( status ) return status;
10035#else
10036	/* Draft 4 pthreads */
10037	status = pthread_create( &t, pthread_attr_default, task, NULL );
10038	if( status ) return errno;
10039
10040	/* give thread a chance to complete */
10041	/* it should remain joinable and hence detachable */
10042	sleep( 1 );
10043
10044	status = pthread_detach( &t );
10045	if( status ) return errno;
10046#endif
10047
10048#ifdef HAVE_LINUX_THREADS
10049	pthread_kill_other_threads_np();
10050#endif
10051
10052	return 0;
10053
10054  ;
10055  return 0;
10056}
10057_ACEOF
10058if ac_fn_c_try_link "$LINENO"; then :
10059  ol_cv_pthread_create=yes
10060else
10061  ol_cv_pthread_create=no
10062fi
10063rm -f core conftest.err conftest.$ac_objext \
10064    conftest$ac_exeext conftest.$ac_ext
10065else
10066  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10067/* end confdefs.h.  */
10068
10069
10070/* pthread test headers */
10071#include <pthread.h>
10072#if HAVE_PTHREADS < 7
10073#include <errno.h>
10074#endif
10075#ifndef NULL
10076#define NULL (void*)0
10077#endif
10078
10079static void *task(p)
10080	void *p;
10081{
10082	return (void *) (p == NULL);
10083}
10084
10085
10086int main(argc, argv)
10087	int argc;
10088	char **argv;
10089{
10090
10091	/* pthread test function */
10092#ifndef PTHREAD_CREATE_DETACHED
10093#define	PTHREAD_CREATE_DETACHED	1
10094#endif
10095	pthread_t t;
10096	int status;
10097	int detach = PTHREAD_CREATE_DETACHED;
10098
10099#if HAVE_PTHREADS > 4
10100	/* Final pthreads */
10101	pthread_attr_t attr;
10102
10103	status = pthread_attr_init(&attr);
10104	if( status ) return status;
10105
10106#if HAVE_PTHREADS < 7
10107	status = pthread_attr_setdetachstate(&attr, &detach);
10108	if( status < 0 ) status = errno;
10109#else
10110	status = pthread_attr_setdetachstate(&attr, detach);
10111#endif
10112	if( status ) return status;
10113	status = pthread_create( &t, &attr, task, NULL );
10114#if HAVE_PTHREADS < 7
10115	if( status < 0 ) status = errno;
10116#endif
10117	if( status ) return status;
10118#else
10119	/* Draft 4 pthreads */
10120	status = pthread_create( &t, pthread_attr_default, task, NULL );
10121	if( status ) return errno;
10122
10123	/* give thread a chance to complete */
10124	/* it should remain joinable and hence detachable */
10125	sleep( 1 );
10126
10127	status = pthread_detach( &t );
10128	if( status ) return errno;
10129#endif
10130
10131#ifdef HAVE_LINUX_THREADS
10132	pthread_kill_other_threads_np();
10133#endif
10134
10135	return 0;
10136
10137}
10138
10139_ACEOF
10140if ac_fn_c_try_run "$LINENO"; then :
10141  ol_cv_pthread_create=yes
10142else
10143  ol_cv_pthread_create=no
10144fi
10145rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10146  conftest.$ac_objext conftest.beam conftest.$ac_ext
10147fi
10148
10149fi
10150{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_create" >&5
10151$as_echo "$ol_cv_pthread_create" >&6; }
10152
10153		if test $ol_cv_pthread_create != no ; then
10154			ol_link_threads=posix
10155			ol_link_pthreads=""
10156		fi
10157
10158		# Pthread try link: -kthread (ol_cv_pthread_kthread)
10159if test "$ol_link_threads" = no ; then
10160	# try -kthread
10161	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -kthread" >&5
10162$as_echo_n "checking for pthread link with -kthread... " >&6; }
10163if ${ol_cv_pthread_kthread+:} false; then :
10164  $as_echo_n "(cached) " >&6
10165else
10166
10167		# save the flags
10168		ol_LIBS="$LIBS"
10169		LIBS="-kthread $LIBS"
10170
10171		if test "$cross_compiling" = yes; then :
10172  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10173/* end confdefs.h.  */
10174
10175/* pthread test headers */
10176#include <pthread.h>
10177#if HAVE_PTHREADS < 7
10178#include <errno.h>
10179#endif
10180#ifndef NULL
10181#define NULL (void*)0
10182#endif
10183
10184static void *task(p)
10185	void *p;
10186{
10187	return (void *) (p == NULL);
10188}
10189
10190int
10191main ()
10192{
10193
10194	/* pthread test function */
10195#ifndef PTHREAD_CREATE_DETACHED
10196#define	PTHREAD_CREATE_DETACHED	1
10197#endif
10198	pthread_t t;
10199	int status;
10200	int detach = PTHREAD_CREATE_DETACHED;
10201
10202#if HAVE_PTHREADS > 4
10203	/* Final pthreads */
10204	pthread_attr_t attr;
10205
10206	status = pthread_attr_init(&attr);
10207	if( status ) return status;
10208
10209#if HAVE_PTHREADS < 7
10210	status = pthread_attr_setdetachstate(&attr, &detach);
10211	if( status < 0 ) status = errno;
10212#else
10213	status = pthread_attr_setdetachstate(&attr, detach);
10214#endif
10215	if( status ) return status;
10216	status = pthread_create( &t, &attr, task, NULL );
10217#if HAVE_PTHREADS < 7
10218	if( status < 0 ) status = errno;
10219#endif
10220	if( status ) return status;
10221#else
10222	/* Draft 4 pthreads */
10223	status = pthread_create( &t, pthread_attr_default, task, NULL );
10224	if( status ) return errno;
10225
10226	/* give thread a chance to complete */
10227	/* it should remain joinable and hence detachable */
10228	sleep( 1 );
10229
10230	status = pthread_detach( &t );
10231	if( status ) return errno;
10232#endif
10233
10234#ifdef HAVE_LINUX_THREADS
10235	pthread_kill_other_threads_np();
10236#endif
10237
10238	return 0;
10239
10240  ;
10241  return 0;
10242}
10243_ACEOF
10244if ac_fn_c_try_link "$LINENO"; then :
10245  ol_cv_pthread_kthread=yes
10246else
10247  ol_cv_pthread_kthread=no
10248fi
10249rm -f core conftest.err conftest.$ac_objext \
10250    conftest$ac_exeext conftest.$ac_ext
10251else
10252  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10253/* end confdefs.h.  */
10254
10255
10256/* pthread test headers */
10257#include <pthread.h>
10258#if HAVE_PTHREADS < 7
10259#include <errno.h>
10260#endif
10261#ifndef NULL
10262#define NULL (void*)0
10263#endif
10264
10265static void *task(p)
10266	void *p;
10267{
10268	return (void *) (p == NULL);
10269}
10270
10271
10272int main(argc, argv)
10273	int argc;
10274	char **argv;
10275{
10276
10277	/* pthread test function */
10278#ifndef PTHREAD_CREATE_DETACHED
10279#define	PTHREAD_CREATE_DETACHED	1
10280#endif
10281	pthread_t t;
10282	int status;
10283	int detach = PTHREAD_CREATE_DETACHED;
10284
10285#if HAVE_PTHREADS > 4
10286	/* Final pthreads */
10287	pthread_attr_t attr;
10288
10289	status = pthread_attr_init(&attr);
10290	if( status ) return status;
10291
10292#if HAVE_PTHREADS < 7
10293	status = pthread_attr_setdetachstate(&attr, &detach);
10294	if( status < 0 ) status = errno;
10295#else
10296	status = pthread_attr_setdetachstate(&attr, detach);
10297#endif
10298	if( status ) return status;
10299	status = pthread_create( &t, &attr, task, NULL );
10300#if HAVE_PTHREADS < 7
10301	if( status < 0 ) status = errno;
10302#endif
10303	if( status ) return status;
10304#else
10305	/* Draft 4 pthreads */
10306	status = pthread_create( &t, pthread_attr_default, task, NULL );
10307	if( status ) return errno;
10308
10309	/* give thread a chance to complete */
10310	/* it should remain joinable and hence detachable */
10311	sleep( 1 );
10312
10313	status = pthread_detach( &t );
10314	if( status ) return errno;
10315#endif
10316
10317#ifdef HAVE_LINUX_THREADS
10318	pthread_kill_other_threads_np();
10319#endif
10320
10321	return 0;
10322
10323}
10324
10325_ACEOF
10326if ac_fn_c_try_run "$LINENO"; then :
10327  ol_cv_pthread_kthread=yes
10328else
10329  ol_cv_pthread_kthread=no
10330fi
10331rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10332  conftest.$ac_objext conftest.beam conftest.$ac_ext
10333fi
10334
10335
10336		# restore the LIBS
10337		LIBS="$ol_LIBS"
10338
10339fi
10340{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_kthread" >&5
10341$as_echo "$ol_cv_pthread_kthread" >&6; }
10342
10343	if test $ol_cv_pthread_kthread = yes ; then
10344		ol_link_pthreads="-kthread"
10345		ol_link_threads=posix
10346	fi
10347fi
10348
10349		# Pthread try link: -pthread (ol_cv_pthread_pthread)
10350if test "$ol_link_threads" = no ; then
10351	# try -pthread
10352	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -pthread" >&5
10353$as_echo_n "checking for pthread link with -pthread... " >&6; }
10354if ${ol_cv_pthread_pthread+:} false; then :
10355  $as_echo_n "(cached) " >&6
10356else
10357
10358		# save the flags
10359		ol_LIBS="$LIBS"
10360		LIBS="-pthread $LIBS"
10361
10362		if test "$cross_compiling" = yes; then :
10363  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10364/* end confdefs.h.  */
10365
10366/* pthread test headers */
10367#include <pthread.h>
10368#if HAVE_PTHREADS < 7
10369#include <errno.h>
10370#endif
10371#ifndef NULL
10372#define NULL (void*)0
10373#endif
10374
10375static void *task(p)
10376	void *p;
10377{
10378	return (void *) (p == NULL);
10379}
10380
10381int
10382main ()
10383{
10384
10385	/* pthread test function */
10386#ifndef PTHREAD_CREATE_DETACHED
10387#define	PTHREAD_CREATE_DETACHED	1
10388#endif
10389	pthread_t t;
10390	int status;
10391	int detach = PTHREAD_CREATE_DETACHED;
10392
10393#if HAVE_PTHREADS > 4
10394	/* Final pthreads */
10395	pthread_attr_t attr;
10396
10397	status = pthread_attr_init(&attr);
10398	if( status ) return status;
10399
10400#if HAVE_PTHREADS < 7
10401	status = pthread_attr_setdetachstate(&attr, &detach);
10402	if( status < 0 ) status = errno;
10403#else
10404	status = pthread_attr_setdetachstate(&attr, detach);
10405#endif
10406	if( status ) return status;
10407	status = pthread_create( &t, &attr, task, NULL );
10408#if HAVE_PTHREADS < 7
10409	if( status < 0 ) status = errno;
10410#endif
10411	if( status ) return status;
10412#else
10413	/* Draft 4 pthreads */
10414	status = pthread_create( &t, pthread_attr_default, task, NULL );
10415	if( status ) return errno;
10416
10417	/* give thread a chance to complete */
10418	/* it should remain joinable and hence detachable */
10419	sleep( 1 );
10420
10421	status = pthread_detach( &t );
10422	if( status ) return errno;
10423#endif
10424
10425#ifdef HAVE_LINUX_THREADS
10426	pthread_kill_other_threads_np();
10427#endif
10428
10429	return 0;
10430
10431  ;
10432  return 0;
10433}
10434_ACEOF
10435if ac_fn_c_try_link "$LINENO"; then :
10436  ol_cv_pthread_pthread=yes
10437else
10438  ol_cv_pthread_pthread=no
10439fi
10440rm -f core conftest.err conftest.$ac_objext \
10441    conftest$ac_exeext conftest.$ac_ext
10442else
10443  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10444/* end confdefs.h.  */
10445
10446
10447/* pthread test headers */
10448#include <pthread.h>
10449#if HAVE_PTHREADS < 7
10450#include <errno.h>
10451#endif
10452#ifndef NULL
10453#define NULL (void*)0
10454#endif
10455
10456static void *task(p)
10457	void *p;
10458{
10459	return (void *) (p == NULL);
10460}
10461
10462
10463int main(argc, argv)
10464	int argc;
10465	char **argv;
10466{
10467
10468	/* pthread test function */
10469#ifndef PTHREAD_CREATE_DETACHED
10470#define	PTHREAD_CREATE_DETACHED	1
10471#endif
10472	pthread_t t;
10473	int status;
10474	int detach = PTHREAD_CREATE_DETACHED;
10475
10476#if HAVE_PTHREADS > 4
10477	/* Final pthreads */
10478	pthread_attr_t attr;
10479
10480	status = pthread_attr_init(&attr);
10481	if( status ) return status;
10482
10483#if HAVE_PTHREADS < 7
10484	status = pthread_attr_setdetachstate(&attr, &detach);
10485	if( status < 0 ) status = errno;
10486#else
10487	status = pthread_attr_setdetachstate(&attr, detach);
10488#endif
10489	if( status ) return status;
10490	status = pthread_create( &t, &attr, task, NULL );
10491#if HAVE_PTHREADS < 7
10492	if( status < 0 ) status = errno;
10493#endif
10494	if( status ) return status;
10495#else
10496	/* Draft 4 pthreads */
10497	status = pthread_create( &t, pthread_attr_default, task, NULL );
10498	if( status ) return errno;
10499
10500	/* give thread a chance to complete */
10501	/* it should remain joinable and hence detachable */
10502	sleep( 1 );
10503
10504	status = pthread_detach( &t );
10505	if( status ) return errno;
10506#endif
10507
10508#ifdef HAVE_LINUX_THREADS
10509	pthread_kill_other_threads_np();
10510#endif
10511
10512	return 0;
10513
10514}
10515
10516_ACEOF
10517if ac_fn_c_try_run "$LINENO"; then :
10518  ol_cv_pthread_pthread=yes
10519else
10520  ol_cv_pthread_pthread=no
10521fi
10522rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10523  conftest.$ac_objext conftest.beam conftest.$ac_ext
10524fi
10525
10526
10527		# restore the LIBS
10528		LIBS="$ol_LIBS"
10529
10530fi
10531{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_pthread" >&5
10532$as_echo "$ol_cv_pthread_pthread" >&6; }
10533
10534	if test $ol_cv_pthread_pthread = yes ; then
10535		ol_link_pthreads="-pthread"
10536		ol_link_threads=posix
10537	fi
10538fi
10539
10540		# Pthread try link: -pthreads (ol_cv_pthread_pthreads)
10541if test "$ol_link_threads" = no ; then
10542	# try -pthreads
10543	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -pthreads" >&5
10544$as_echo_n "checking for pthread link with -pthreads... " >&6; }
10545if ${ol_cv_pthread_pthreads+:} false; then :
10546  $as_echo_n "(cached) " >&6
10547else
10548
10549		# save the flags
10550		ol_LIBS="$LIBS"
10551		LIBS="-pthreads $LIBS"
10552
10553		if test "$cross_compiling" = yes; then :
10554  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10555/* end confdefs.h.  */
10556
10557/* pthread test headers */
10558#include <pthread.h>
10559#if HAVE_PTHREADS < 7
10560#include <errno.h>
10561#endif
10562#ifndef NULL
10563#define NULL (void*)0
10564#endif
10565
10566static void *task(p)
10567	void *p;
10568{
10569	return (void *) (p == NULL);
10570}
10571
10572int
10573main ()
10574{
10575
10576	/* pthread test function */
10577#ifndef PTHREAD_CREATE_DETACHED
10578#define	PTHREAD_CREATE_DETACHED	1
10579#endif
10580	pthread_t t;
10581	int status;
10582	int detach = PTHREAD_CREATE_DETACHED;
10583
10584#if HAVE_PTHREADS > 4
10585	/* Final pthreads */
10586	pthread_attr_t attr;
10587
10588	status = pthread_attr_init(&attr);
10589	if( status ) return status;
10590
10591#if HAVE_PTHREADS < 7
10592	status = pthread_attr_setdetachstate(&attr, &detach);
10593	if( status < 0 ) status = errno;
10594#else
10595	status = pthread_attr_setdetachstate(&attr, detach);
10596#endif
10597	if( status ) return status;
10598	status = pthread_create( &t, &attr, task, NULL );
10599#if HAVE_PTHREADS < 7
10600	if( status < 0 ) status = errno;
10601#endif
10602	if( status ) return status;
10603#else
10604	/* Draft 4 pthreads */
10605	status = pthread_create( &t, pthread_attr_default, task, NULL );
10606	if( status ) return errno;
10607
10608	/* give thread a chance to complete */
10609	/* it should remain joinable and hence detachable */
10610	sleep( 1 );
10611
10612	status = pthread_detach( &t );
10613	if( status ) return errno;
10614#endif
10615
10616#ifdef HAVE_LINUX_THREADS
10617	pthread_kill_other_threads_np();
10618#endif
10619
10620	return 0;
10621
10622  ;
10623  return 0;
10624}
10625_ACEOF
10626if ac_fn_c_try_link "$LINENO"; then :
10627  ol_cv_pthread_pthreads=yes
10628else
10629  ol_cv_pthread_pthreads=no
10630fi
10631rm -f core conftest.err conftest.$ac_objext \
10632    conftest$ac_exeext conftest.$ac_ext
10633else
10634  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10635/* end confdefs.h.  */
10636
10637
10638/* pthread test headers */
10639#include <pthread.h>
10640#if HAVE_PTHREADS < 7
10641#include <errno.h>
10642#endif
10643#ifndef NULL
10644#define NULL (void*)0
10645#endif
10646
10647static void *task(p)
10648	void *p;
10649{
10650	return (void *) (p == NULL);
10651}
10652
10653
10654int main(argc, argv)
10655	int argc;
10656	char **argv;
10657{
10658
10659	/* pthread test function */
10660#ifndef PTHREAD_CREATE_DETACHED
10661#define	PTHREAD_CREATE_DETACHED	1
10662#endif
10663	pthread_t t;
10664	int status;
10665	int detach = PTHREAD_CREATE_DETACHED;
10666
10667#if HAVE_PTHREADS > 4
10668	/* Final pthreads */
10669	pthread_attr_t attr;
10670
10671	status = pthread_attr_init(&attr);
10672	if( status ) return status;
10673
10674#if HAVE_PTHREADS < 7
10675	status = pthread_attr_setdetachstate(&attr, &detach);
10676	if( status < 0 ) status = errno;
10677#else
10678	status = pthread_attr_setdetachstate(&attr, detach);
10679#endif
10680	if( status ) return status;
10681	status = pthread_create( &t, &attr, task, NULL );
10682#if HAVE_PTHREADS < 7
10683	if( status < 0 ) status = errno;
10684#endif
10685	if( status ) return status;
10686#else
10687	/* Draft 4 pthreads */
10688	status = pthread_create( &t, pthread_attr_default, task, NULL );
10689	if( status ) return errno;
10690
10691	/* give thread a chance to complete */
10692	/* it should remain joinable and hence detachable */
10693	sleep( 1 );
10694
10695	status = pthread_detach( &t );
10696	if( status ) return errno;
10697#endif
10698
10699#ifdef HAVE_LINUX_THREADS
10700	pthread_kill_other_threads_np();
10701#endif
10702
10703	return 0;
10704
10705}
10706
10707_ACEOF
10708if ac_fn_c_try_run "$LINENO"; then :
10709  ol_cv_pthread_pthreads=yes
10710else
10711  ol_cv_pthread_pthreads=no
10712fi
10713rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10714  conftest.$ac_objext conftest.beam conftest.$ac_ext
10715fi
10716
10717
10718		# restore the LIBS
10719		LIBS="$ol_LIBS"
10720
10721fi
10722{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_pthreads" >&5
10723$as_echo "$ol_cv_pthread_pthreads" >&6; }
10724
10725	if test $ol_cv_pthread_pthreads = yes ; then
10726		ol_link_pthreads="-pthreads"
10727		ol_link_threads=posix
10728	fi
10729fi
10730
10731		# Pthread try link: -mthreads (ol_cv_pthread_mthreads)
10732if test "$ol_link_threads" = no ; then
10733	# try -mthreads
10734	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -mthreads" >&5
10735$as_echo_n "checking for pthread link with -mthreads... " >&6; }
10736if ${ol_cv_pthread_mthreads+:} false; then :
10737  $as_echo_n "(cached) " >&6
10738else
10739
10740		# save the flags
10741		ol_LIBS="$LIBS"
10742		LIBS="-mthreads $LIBS"
10743
10744		if test "$cross_compiling" = yes; then :
10745  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10746/* end confdefs.h.  */
10747
10748/* pthread test headers */
10749#include <pthread.h>
10750#if HAVE_PTHREADS < 7
10751#include <errno.h>
10752#endif
10753#ifndef NULL
10754#define NULL (void*)0
10755#endif
10756
10757static void *task(p)
10758	void *p;
10759{
10760	return (void *) (p == NULL);
10761}
10762
10763int
10764main ()
10765{
10766
10767	/* pthread test function */
10768#ifndef PTHREAD_CREATE_DETACHED
10769#define	PTHREAD_CREATE_DETACHED	1
10770#endif
10771	pthread_t t;
10772	int status;
10773	int detach = PTHREAD_CREATE_DETACHED;
10774
10775#if HAVE_PTHREADS > 4
10776	/* Final pthreads */
10777	pthread_attr_t attr;
10778
10779	status = pthread_attr_init(&attr);
10780	if( status ) return status;
10781
10782#if HAVE_PTHREADS < 7
10783	status = pthread_attr_setdetachstate(&attr, &detach);
10784	if( status < 0 ) status = errno;
10785#else
10786	status = pthread_attr_setdetachstate(&attr, detach);
10787#endif
10788	if( status ) return status;
10789	status = pthread_create( &t, &attr, task, NULL );
10790#if HAVE_PTHREADS < 7
10791	if( status < 0 ) status = errno;
10792#endif
10793	if( status ) return status;
10794#else
10795	/* Draft 4 pthreads */
10796	status = pthread_create( &t, pthread_attr_default, task, NULL );
10797	if( status ) return errno;
10798
10799	/* give thread a chance to complete */
10800	/* it should remain joinable and hence detachable */
10801	sleep( 1 );
10802
10803	status = pthread_detach( &t );
10804	if( status ) return errno;
10805#endif
10806
10807#ifdef HAVE_LINUX_THREADS
10808	pthread_kill_other_threads_np();
10809#endif
10810
10811	return 0;
10812
10813  ;
10814  return 0;
10815}
10816_ACEOF
10817if ac_fn_c_try_link "$LINENO"; then :
10818  ol_cv_pthread_mthreads=yes
10819else
10820  ol_cv_pthread_mthreads=no
10821fi
10822rm -f core conftest.err conftest.$ac_objext \
10823    conftest$ac_exeext conftest.$ac_ext
10824else
10825  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10826/* end confdefs.h.  */
10827
10828
10829/* pthread test headers */
10830#include <pthread.h>
10831#if HAVE_PTHREADS < 7
10832#include <errno.h>
10833#endif
10834#ifndef NULL
10835#define NULL (void*)0
10836#endif
10837
10838static void *task(p)
10839	void *p;
10840{
10841	return (void *) (p == NULL);
10842}
10843
10844
10845int main(argc, argv)
10846	int argc;
10847	char **argv;
10848{
10849
10850	/* pthread test function */
10851#ifndef PTHREAD_CREATE_DETACHED
10852#define	PTHREAD_CREATE_DETACHED	1
10853#endif
10854	pthread_t t;
10855	int status;
10856	int detach = PTHREAD_CREATE_DETACHED;
10857
10858#if HAVE_PTHREADS > 4
10859	/* Final pthreads */
10860	pthread_attr_t attr;
10861
10862	status = pthread_attr_init(&attr);
10863	if( status ) return status;
10864
10865#if HAVE_PTHREADS < 7
10866	status = pthread_attr_setdetachstate(&attr, &detach);
10867	if( status < 0 ) status = errno;
10868#else
10869	status = pthread_attr_setdetachstate(&attr, detach);
10870#endif
10871	if( status ) return status;
10872	status = pthread_create( &t, &attr, task, NULL );
10873#if HAVE_PTHREADS < 7
10874	if( status < 0 ) status = errno;
10875#endif
10876	if( status ) return status;
10877#else
10878	/* Draft 4 pthreads */
10879	status = pthread_create( &t, pthread_attr_default, task, NULL );
10880	if( status ) return errno;
10881
10882	/* give thread a chance to complete */
10883	/* it should remain joinable and hence detachable */
10884	sleep( 1 );
10885
10886	status = pthread_detach( &t );
10887	if( status ) return errno;
10888#endif
10889
10890#ifdef HAVE_LINUX_THREADS
10891	pthread_kill_other_threads_np();
10892#endif
10893
10894	return 0;
10895
10896}
10897
10898_ACEOF
10899if ac_fn_c_try_run "$LINENO"; then :
10900  ol_cv_pthread_mthreads=yes
10901else
10902  ol_cv_pthread_mthreads=no
10903fi
10904rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10905  conftest.$ac_objext conftest.beam conftest.$ac_ext
10906fi
10907
10908
10909		# restore the LIBS
10910		LIBS="$ol_LIBS"
10911
10912fi
10913{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_mthreads" >&5
10914$as_echo "$ol_cv_pthread_mthreads" >&6; }
10915
10916	if test $ol_cv_pthread_mthreads = yes ; then
10917		ol_link_pthreads="-mthreads"
10918		ol_link_threads=posix
10919	fi
10920fi
10921
10922		# Pthread try link: -thread (ol_cv_pthread_thread)
10923if test "$ol_link_threads" = no ; then
10924	# try -thread
10925	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -thread" >&5
10926$as_echo_n "checking for pthread link with -thread... " >&6; }
10927if ${ol_cv_pthread_thread+:} false; then :
10928  $as_echo_n "(cached) " >&6
10929else
10930
10931		# save the flags
10932		ol_LIBS="$LIBS"
10933		LIBS="-thread $LIBS"
10934
10935		if test "$cross_compiling" = yes; then :
10936  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10937/* end confdefs.h.  */
10938
10939/* pthread test headers */
10940#include <pthread.h>
10941#if HAVE_PTHREADS < 7
10942#include <errno.h>
10943#endif
10944#ifndef NULL
10945#define NULL (void*)0
10946#endif
10947
10948static void *task(p)
10949	void *p;
10950{
10951	return (void *) (p == NULL);
10952}
10953
10954int
10955main ()
10956{
10957
10958	/* pthread test function */
10959#ifndef PTHREAD_CREATE_DETACHED
10960#define	PTHREAD_CREATE_DETACHED	1
10961#endif
10962	pthread_t t;
10963	int status;
10964	int detach = PTHREAD_CREATE_DETACHED;
10965
10966#if HAVE_PTHREADS > 4
10967	/* Final pthreads */
10968	pthread_attr_t attr;
10969
10970	status = pthread_attr_init(&attr);
10971	if( status ) return status;
10972
10973#if HAVE_PTHREADS < 7
10974	status = pthread_attr_setdetachstate(&attr, &detach);
10975	if( status < 0 ) status = errno;
10976#else
10977	status = pthread_attr_setdetachstate(&attr, detach);
10978#endif
10979	if( status ) return status;
10980	status = pthread_create( &t, &attr, task, NULL );
10981#if HAVE_PTHREADS < 7
10982	if( status < 0 ) status = errno;
10983#endif
10984	if( status ) return status;
10985#else
10986	/* Draft 4 pthreads */
10987	status = pthread_create( &t, pthread_attr_default, task, NULL );
10988	if( status ) return errno;
10989
10990	/* give thread a chance to complete */
10991	/* it should remain joinable and hence detachable */
10992	sleep( 1 );
10993
10994	status = pthread_detach( &t );
10995	if( status ) return errno;
10996#endif
10997
10998#ifdef HAVE_LINUX_THREADS
10999	pthread_kill_other_threads_np();
11000#endif
11001
11002	return 0;
11003
11004  ;
11005  return 0;
11006}
11007_ACEOF
11008if ac_fn_c_try_link "$LINENO"; then :
11009  ol_cv_pthread_thread=yes
11010else
11011  ol_cv_pthread_thread=no
11012fi
11013rm -f core conftest.err conftest.$ac_objext \
11014    conftest$ac_exeext conftest.$ac_ext
11015else
11016  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11017/* end confdefs.h.  */
11018
11019
11020/* pthread test headers */
11021#include <pthread.h>
11022#if HAVE_PTHREADS < 7
11023#include <errno.h>
11024#endif
11025#ifndef NULL
11026#define NULL (void*)0
11027#endif
11028
11029static void *task(p)
11030	void *p;
11031{
11032	return (void *) (p == NULL);
11033}
11034
11035
11036int main(argc, argv)
11037	int argc;
11038	char **argv;
11039{
11040
11041	/* pthread test function */
11042#ifndef PTHREAD_CREATE_DETACHED
11043#define	PTHREAD_CREATE_DETACHED	1
11044#endif
11045	pthread_t t;
11046	int status;
11047	int detach = PTHREAD_CREATE_DETACHED;
11048
11049#if HAVE_PTHREADS > 4
11050	/* Final pthreads */
11051	pthread_attr_t attr;
11052
11053	status = pthread_attr_init(&attr);
11054	if( status ) return status;
11055
11056#if HAVE_PTHREADS < 7
11057	status = pthread_attr_setdetachstate(&attr, &detach);
11058	if( status < 0 ) status = errno;
11059#else
11060	status = pthread_attr_setdetachstate(&attr, detach);
11061#endif
11062	if( status ) return status;
11063	status = pthread_create( &t, &attr, task, NULL );
11064#if HAVE_PTHREADS < 7
11065	if( status < 0 ) status = errno;
11066#endif
11067	if( status ) return status;
11068#else
11069	/* Draft 4 pthreads */
11070	status = pthread_create( &t, pthread_attr_default, task, NULL );
11071	if( status ) return errno;
11072
11073	/* give thread a chance to complete */
11074	/* it should remain joinable and hence detachable */
11075	sleep( 1 );
11076
11077	status = pthread_detach( &t );
11078	if( status ) return errno;
11079#endif
11080
11081#ifdef HAVE_LINUX_THREADS
11082	pthread_kill_other_threads_np();
11083#endif
11084
11085	return 0;
11086
11087}
11088
11089_ACEOF
11090if ac_fn_c_try_run "$LINENO"; then :
11091  ol_cv_pthread_thread=yes
11092else
11093  ol_cv_pthread_thread=no
11094fi
11095rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11096  conftest.$ac_objext conftest.beam conftest.$ac_ext
11097fi
11098
11099
11100		# restore the LIBS
11101		LIBS="$ol_LIBS"
11102
11103fi
11104{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_thread" >&5
11105$as_echo "$ol_cv_pthread_thread" >&6; }
11106
11107	if test $ol_cv_pthread_thread = yes ; then
11108		ol_link_pthreads="-thread"
11109		ol_link_threads=posix
11110	fi
11111fi
11112
11113
11114		# Pthread try link: -lpthread -lmach -lexc -lc_r (ol_cv_pthread_lpthread_lmach_lexc_lc_r)
11115if test "$ol_link_threads" = no ; then
11116	# try -lpthread -lmach -lexc -lc_r
11117	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthread -lmach -lexc -lc_r" >&5
11118$as_echo_n "checking for pthread link with -lpthread -lmach -lexc -lc_r... " >&6; }
11119if ${ol_cv_pthread_lpthread_lmach_lexc_lc_r+:} false; then :
11120  $as_echo_n "(cached) " >&6
11121else
11122
11123		# save the flags
11124		ol_LIBS="$LIBS"
11125		LIBS="-lpthread -lmach -lexc -lc_r $LIBS"
11126
11127		if test "$cross_compiling" = yes; then :
11128  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11129/* end confdefs.h.  */
11130
11131/* pthread test headers */
11132#include <pthread.h>
11133#if HAVE_PTHREADS < 7
11134#include <errno.h>
11135#endif
11136#ifndef NULL
11137#define NULL (void*)0
11138#endif
11139
11140static void *task(p)
11141	void *p;
11142{
11143	return (void *) (p == NULL);
11144}
11145
11146int
11147main ()
11148{
11149
11150	/* pthread test function */
11151#ifndef PTHREAD_CREATE_DETACHED
11152#define	PTHREAD_CREATE_DETACHED	1
11153#endif
11154	pthread_t t;
11155	int status;
11156	int detach = PTHREAD_CREATE_DETACHED;
11157
11158#if HAVE_PTHREADS > 4
11159	/* Final pthreads */
11160	pthread_attr_t attr;
11161
11162	status = pthread_attr_init(&attr);
11163	if( status ) return status;
11164
11165#if HAVE_PTHREADS < 7
11166	status = pthread_attr_setdetachstate(&attr, &detach);
11167	if( status < 0 ) status = errno;
11168#else
11169	status = pthread_attr_setdetachstate(&attr, detach);
11170#endif
11171	if( status ) return status;
11172	status = pthread_create( &t, &attr, task, NULL );
11173#if HAVE_PTHREADS < 7
11174	if( status < 0 ) status = errno;
11175#endif
11176	if( status ) return status;
11177#else
11178	/* Draft 4 pthreads */
11179	status = pthread_create( &t, pthread_attr_default, task, NULL );
11180	if( status ) return errno;
11181
11182	/* give thread a chance to complete */
11183	/* it should remain joinable and hence detachable */
11184	sleep( 1 );
11185
11186	status = pthread_detach( &t );
11187	if( status ) return errno;
11188#endif
11189
11190#ifdef HAVE_LINUX_THREADS
11191	pthread_kill_other_threads_np();
11192#endif
11193
11194	return 0;
11195
11196  ;
11197  return 0;
11198}
11199_ACEOF
11200if ac_fn_c_try_link "$LINENO"; then :
11201  ol_cv_pthread_lpthread_lmach_lexc_lc_r=yes
11202else
11203  ol_cv_pthread_lpthread_lmach_lexc_lc_r=no
11204fi
11205rm -f core conftest.err conftest.$ac_objext \
11206    conftest$ac_exeext conftest.$ac_ext
11207else
11208  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11209/* end confdefs.h.  */
11210
11211
11212/* pthread test headers */
11213#include <pthread.h>
11214#if HAVE_PTHREADS < 7
11215#include <errno.h>
11216#endif
11217#ifndef NULL
11218#define NULL (void*)0
11219#endif
11220
11221static void *task(p)
11222	void *p;
11223{
11224	return (void *) (p == NULL);
11225}
11226
11227
11228int main(argc, argv)
11229	int argc;
11230	char **argv;
11231{
11232
11233	/* pthread test function */
11234#ifndef PTHREAD_CREATE_DETACHED
11235#define	PTHREAD_CREATE_DETACHED	1
11236#endif
11237	pthread_t t;
11238	int status;
11239	int detach = PTHREAD_CREATE_DETACHED;
11240
11241#if HAVE_PTHREADS > 4
11242	/* Final pthreads */
11243	pthread_attr_t attr;
11244
11245	status = pthread_attr_init(&attr);
11246	if( status ) return status;
11247
11248#if HAVE_PTHREADS < 7
11249	status = pthread_attr_setdetachstate(&attr, &detach);
11250	if( status < 0 ) status = errno;
11251#else
11252	status = pthread_attr_setdetachstate(&attr, detach);
11253#endif
11254	if( status ) return status;
11255	status = pthread_create( &t, &attr, task, NULL );
11256#if HAVE_PTHREADS < 7
11257	if( status < 0 ) status = errno;
11258#endif
11259	if( status ) return status;
11260#else
11261	/* Draft 4 pthreads */
11262	status = pthread_create( &t, pthread_attr_default, task, NULL );
11263	if( status ) return errno;
11264
11265	/* give thread a chance to complete */
11266	/* it should remain joinable and hence detachable */
11267	sleep( 1 );
11268
11269	status = pthread_detach( &t );
11270	if( status ) return errno;
11271#endif
11272
11273#ifdef HAVE_LINUX_THREADS
11274	pthread_kill_other_threads_np();
11275#endif
11276
11277	return 0;
11278
11279}
11280
11281_ACEOF
11282if ac_fn_c_try_run "$LINENO"; then :
11283  ol_cv_pthread_lpthread_lmach_lexc_lc_r=yes
11284else
11285  ol_cv_pthread_lpthread_lmach_lexc_lc_r=no
11286fi
11287rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11288  conftest.$ac_objext conftest.beam conftest.$ac_ext
11289fi
11290
11291
11292		# restore the LIBS
11293		LIBS="$ol_LIBS"
11294
11295fi
11296{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lpthread_lmach_lexc_lc_r" >&5
11297$as_echo "$ol_cv_pthread_lpthread_lmach_lexc_lc_r" >&6; }
11298
11299	if test $ol_cv_pthread_lpthread_lmach_lexc_lc_r = yes ; then
11300		ol_link_pthreads="-lpthread -lmach -lexc -lc_r"
11301		ol_link_threads=posix
11302	fi
11303fi
11304
11305		# Pthread try link: -lpthread -lmach -lexc (ol_cv_pthread_lpthread_lmach_lexc)
11306if test "$ol_link_threads" = no ; then
11307	# try -lpthread -lmach -lexc
11308	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthread -lmach -lexc" >&5
11309$as_echo_n "checking for pthread link with -lpthread -lmach -lexc... " >&6; }
11310if ${ol_cv_pthread_lpthread_lmach_lexc+:} false; then :
11311  $as_echo_n "(cached) " >&6
11312else
11313
11314		# save the flags
11315		ol_LIBS="$LIBS"
11316		LIBS="-lpthread -lmach -lexc $LIBS"
11317
11318		if test "$cross_compiling" = yes; then :
11319  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11320/* end confdefs.h.  */
11321
11322/* pthread test headers */
11323#include <pthread.h>
11324#if HAVE_PTHREADS < 7
11325#include <errno.h>
11326#endif
11327#ifndef NULL
11328#define NULL (void*)0
11329#endif
11330
11331static void *task(p)
11332	void *p;
11333{
11334	return (void *) (p == NULL);
11335}
11336
11337int
11338main ()
11339{
11340
11341	/* pthread test function */
11342#ifndef PTHREAD_CREATE_DETACHED
11343#define	PTHREAD_CREATE_DETACHED	1
11344#endif
11345	pthread_t t;
11346	int status;
11347	int detach = PTHREAD_CREATE_DETACHED;
11348
11349#if HAVE_PTHREADS > 4
11350	/* Final pthreads */
11351	pthread_attr_t attr;
11352
11353	status = pthread_attr_init(&attr);
11354	if( status ) return status;
11355
11356#if HAVE_PTHREADS < 7
11357	status = pthread_attr_setdetachstate(&attr, &detach);
11358	if( status < 0 ) status = errno;
11359#else
11360	status = pthread_attr_setdetachstate(&attr, detach);
11361#endif
11362	if( status ) return status;
11363	status = pthread_create( &t, &attr, task, NULL );
11364#if HAVE_PTHREADS < 7
11365	if( status < 0 ) status = errno;
11366#endif
11367	if( status ) return status;
11368#else
11369	/* Draft 4 pthreads */
11370	status = pthread_create( &t, pthread_attr_default, task, NULL );
11371	if( status ) return errno;
11372
11373	/* give thread a chance to complete */
11374	/* it should remain joinable and hence detachable */
11375	sleep( 1 );
11376
11377	status = pthread_detach( &t );
11378	if( status ) return errno;
11379#endif
11380
11381#ifdef HAVE_LINUX_THREADS
11382	pthread_kill_other_threads_np();
11383#endif
11384
11385	return 0;
11386
11387  ;
11388  return 0;
11389}
11390_ACEOF
11391if ac_fn_c_try_link "$LINENO"; then :
11392  ol_cv_pthread_lpthread_lmach_lexc=yes
11393else
11394  ol_cv_pthread_lpthread_lmach_lexc=no
11395fi
11396rm -f core conftest.err conftest.$ac_objext \
11397    conftest$ac_exeext conftest.$ac_ext
11398else
11399  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11400/* end confdefs.h.  */
11401
11402
11403/* pthread test headers */
11404#include <pthread.h>
11405#if HAVE_PTHREADS < 7
11406#include <errno.h>
11407#endif
11408#ifndef NULL
11409#define NULL (void*)0
11410#endif
11411
11412static void *task(p)
11413	void *p;
11414{
11415	return (void *) (p == NULL);
11416}
11417
11418
11419int main(argc, argv)
11420	int argc;
11421	char **argv;
11422{
11423
11424	/* pthread test function */
11425#ifndef PTHREAD_CREATE_DETACHED
11426#define	PTHREAD_CREATE_DETACHED	1
11427#endif
11428	pthread_t t;
11429	int status;
11430	int detach = PTHREAD_CREATE_DETACHED;
11431
11432#if HAVE_PTHREADS > 4
11433	/* Final pthreads */
11434	pthread_attr_t attr;
11435
11436	status = pthread_attr_init(&attr);
11437	if( status ) return status;
11438
11439#if HAVE_PTHREADS < 7
11440	status = pthread_attr_setdetachstate(&attr, &detach);
11441	if( status < 0 ) status = errno;
11442#else
11443	status = pthread_attr_setdetachstate(&attr, detach);
11444#endif
11445	if( status ) return status;
11446	status = pthread_create( &t, &attr, task, NULL );
11447#if HAVE_PTHREADS < 7
11448	if( status < 0 ) status = errno;
11449#endif
11450	if( status ) return status;
11451#else
11452	/* Draft 4 pthreads */
11453	status = pthread_create( &t, pthread_attr_default, task, NULL );
11454	if( status ) return errno;
11455
11456	/* give thread a chance to complete */
11457	/* it should remain joinable and hence detachable */
11458	sleep( 1 );
11459
11460	status = pthread_detach( &t );
11461	if( status ) return errno;
11462#endif
11463
11464#ifdef HAVE_LINUX_THREADS
11465	pthread_kill_other_threads_np();
11466#endif
11467
11468	return 0;
11469
11470}
11471
11472_ACEOF
11473if ac_fn_c_try_run "$LINENO"; then :
11474  ol_cv_pthread_lpthread_lmach_lexc=yes
11475else
11476  ol_cv_pthread_lpthread_lmach_lexc=no
11477fi
11478rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11479  conftest.$ac_objext conftest.beam conftest.$ac_ext
11480fi
11481
11482
11483		# restore the LIBS
11484		LIBS="$ol_LIBS"
11485
11486fi
11487{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lpthread_lmach_lexc" >&5
11488$as_echo "$ol_cv_pthread_lpthread_lmach_lexc" >&6; }
11489
11490	if test $ol_cv_pthread_lpthread_lmach_lexc = yes ; then
11491		ol_link_pthreads="-lpthread -lmach -lexc"
11492		ol_link_threads=posix
11493	fi
11494fi
11495
11496
11497		# Pthread try link: -lpthread -Wl,-woff,85 (ol_cv_pthread_lib_lpthread_woff)
11498if test "$ol_link_threads" = no ; then
11499	# try -lpthread -Wl,-woff,85
11500	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthread -Wl,-woff,85" >&5
11501$as_echo_n "checking for pthread link with -lpthread -Wl,-woff,85... " >&6; }
11502if ${ol_cv_pthread_lib_lpthread_woff+:} false; then :
11503  $as_echo_n "(cached) " >&6
11504else
11505
11506		# save the flags
11507		ol_LIBS="$LIBS"
11508		LIBS="-lpthread -Wl,-woff,85 $LIBS"
11509
11510		if test "$cross_compiling" = yes; then :
11511  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11512/* end confdefs.h.  */
11513
11514/* pthread test headers */
11515#include <pthread.h>
11516#if HAVE_PTHREADS < 7
11517#include <errno.h>
11518#endif
11519#ifndef NULL
11520#define NULL (void*)0
11521#endif
11522
11523static void *task(p)
11524	void *p;
11525{
11526	return (void *) (p == NULL);
11527}
11528
11529int
11530main ()
11531{
11532
11533	/* pthread test function */
11534#ifndef PTHREAD_CREATE_DETACHED
11535#define	PTHREAD_CREATE_DETACHED	1
11536#endif
11537	pthread_t t;
11538	int status;
11539	int detach = PTHREAD_CREATE_DETACHED;
11540
11541#if HAVE_PTHREADS > 4
11542	/* Final pthreads */
11543	pthread_attr_t attr;
11544
11545	status = pthread_attr_init(&attr);
11546	if( status ) return status;
11547
11548#if HAVE_PTHREADS < 7
11549	status = pthread_attr_setdetachstate(&attr, &detach);
11550	if( status < 0 ) status = errno;
11551#else
11552	status = pthread_attr_setdetachstate(&attr, detach);
11553#endif
11554	if( status ) return status;
11555	status = pthread_create( &t, &attr, task, NULL );
11556#if HAVE_PTHREADS < 7
11557	if( status < 0 ) status = errno;
11558#endif
11559	if( status ) return status;
11560#else
11561	/* Draft 4 pthreads */
11562	status = pthread_create( &t, pthread_attr_default, task, NULL );
11563	if( status ) return errno;
11564
11565	/* give thread a chance to complete */
11566	/* it should remain joinable and hence detachable */
11567	sleep( 1 );
11568
11569	status = pthread_detach( &t );
11570	if( status ) return errno;
11571#endif
11572
11573#ifdef HAVE_LINUX_THREADS
11574	pthread_kill_other_threads_np();
11575#endif
11576
11577	return 0;
11578
11579  ;
11580  return 0;
11581}
11582_ACEOF
11583if ac_fn_c_try_link "$LINENO"; then :
11584  ol_cv_pthread_lib_lpthread_woff=yes
11585else
11586  ol_cv_pthread_lib_lpthread_woff=no
11587fi
11588rm -f core conftest.err conftest.$ac_objext \
11589    conftest$ac_exeext conftest.$ac_ext
11590else
11591  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11592/* end confdefs.h.  */
11593
11594
11595/* pthread test headers */
11596#include <pthread.h>
11597#if HAVE_PTHREADS < 7
11598#include <errno.h>
11599#endif
11600#ifndef NULL
11601#define NULL (void*)0
11602#endif
11603
11604static void *task(p)
11605	void *p;
11606{
11607	return (void *) (p == NULL);
11608}
11609
11610
11611int main(argc, argv)
11612	int argc;
11613	char **argv;
11614{
11615
11616	/* pthread test function */
11617#ifndef PTHREAD_CREATE_DETACHED
11618#define	PTHREAD_CREATE_DETACHED	1
11619#endif
11620	pthread_t t;
11621	int status;
11622	int detach = PTHREAD_CREATE_DETACHED;
11623
11624#if HAVE_PTHREADS > 4
11625	/* Final pthreads */
11626	pthread_attr_t attr;
11627
11628	status = pthread_attr_init(&attr);
11629	if( status ) return status;
11630
11631#if HAVE_PTHREADS < 7
11632	status = pthread_attr_setdetachstate(&attr, &detach);
11633	if( status < 0 ) status = errno;
11634#else
11635	status = pthread_attr_setdetachstate(&attr, detach);
11636#endif
11637	if( status ) return status;
11638	status = pthread_create( &t, &attr, task, NULL );
11639#if HAVE_PTHREADS < 7
11640	if( status < 0 ) status = errno;
11641#endif
11642	if( status ) return status;
11643#else
11644	/* Draft 4 pthreads */
11645	status = pthread_create( &t, pthread_attr_default, task, NULL );
11646	if( status ) return errno;
11647
11648	/* give thread a chance to complete */
11649	/* it should remain joinable and hence detachable */
11650	sleep( 1 );
11651
11652	status = pthread_detach( &t );
11653	if( status ) return errno;
11654#endif
11655
11656#ifdef HAVE_LINUX_THREADS
11657	pthread_kill_other_threads_np();
11658#endif
11659
11660	return 0;
11661
11662}
11663
11664_ACEOF
11665if ac_fn_c_try_run "$LINENO"; then :
11666  ol_cv_pthread_lib_lpthread_woff=yes
11667else
11668  ol_cv_pthread_lib_lpthread_woff=no
11669fi
11670rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11671  conftest.$ac_objext conftest.beam conftest.$ac_ext
11672fi
11673
11674
11675		# restore the LIBS
11676		LIBS="$ol_LIBS"
11677
11678fi
11679{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lib_lpthread_woff" >&5
11680$as_echo "$ol_cv_pthread_lib_lpthread_woff" >&6; }
11681
11682	if test $ol_cv_pthread_lib_lpthread_woff = yes ; then
11683		ol_link_pthreads="-lpthread -Wl,-woff,85"
11684		ol_link_threads=posix
11685	fi
11686fi
11687
11688
11689		# Pthread try link: -lpthread (ol_cv_pthread_lpthread)
11690if test "$ol_link_threads" = no ; then
11691	# try -lpthread
11692	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthread" >&5
11693$as_echo_n "checking for pthread link with -lpthread... " >&6; }
11694if ${ol_cv_pthread_lpthread+:} false; then :
11695  $as_echo_n "(cached) " >&6
11696else
11697
11698		# save the flags
11699		ol_LIBS="$LIBS"
11700		LIBS="-lpthread $LIBS"
11701
11702		if test "$cross_compiling" = yes; then :
11703  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11704/* end confdefs.h.  */
11705
11706/* pthread test headers */
11707#include <pthread.h>
11708#if HAVE_PTHREADS < 7
11709#include <errno.h>
11710#endif
11711#ifndef NULL
11712#define NULL (void*)0
11713#endif
11714
11715static void *task(p)
11716	void *p;
11717{
11718	return (void *) (p == NULL);
11719}
11720
11721int
11722main ()
11723{
11724
11725	/* pthread test function */
11726#ifndef PTHREAD_CREATE_DETACHED
11727#define	PTHREAD_CREATE_DETACHED	1
11728#endif
11729	pthread_t t;
11730	int status;
11731	int detach = PTHREAD_CREATE_DETACHED;
11732
11733#if HAVE_PTHREADS > 4
11734	/* Final pthreads */
11735	pthread_attr_t attr;
11736
11737	status = pthread_attr_init(&attr);
11738	if( status ) return status;
11739
11740#if HAVE_PTHREADS < 7
11741	status = pthread_attr_setdetachstate(&attr, &detach);
11742	if( status < 0 ) status = errno;
11743#else
11744	status = pthread_attr_setdetachstate(&attr, detach);
11745#endif
11746	if( status ) return status;
11747	status = pthread_create( &t, &attr, task, NULL );
11748#if HAVE_PTHREADS < 7
11749	if( status < 0 ) status = errno;
11750#endif
11751	if( status ) return status;
11752#else
11753	/* Draft 4 pthreads */
11754	status = pthread_create( &t, pthread_attr_default, task, NULL );
11755	if( status ) return errno;
11756
11757	/* give thread a chance to complete */
11758	/* it should remain joinable and hence detachable */
11759	sleep( 1 );
11760
11761	status = pthread_detach( &t );
11762	if( status ) return errno;
11763#endif
11764
11765#ifdef HAVE_LINUX_THREADS
11766	pthread_kill_other_threads_np();
11767#endif
11768
11769	return 0;
11770
11771  ;
11772  return 0;
11773}
11774_ACEOF
11775if ac_fn_c_try_link "$LINENO"; then :
11776  ol_cv_pthread_lpthread=yes
11777else
11778  ol_cv_pthread_lpthread=no
11779fi
11780rm -f core conftest.err conftest.$ac_objext \
11781    conftest$ac_exeext conftest.$ac_ext
11782else
11783  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11784/* end confdefs.h.  */
11785
11786
11787/* pthread test headers */
11788#include <pthread.h>
11789#if HAVE_PTHREADS < 7
11790#include <errno.h>
11791#endif
11792#ifndef NULL
11793#define NULL (void*)0
11794#endif
11795
11796static void *task(p)
11797	void *p;
11798{
11799	return (void *) (p == NULL);
11800}
11801
11802
11803int main(argc, argv)
11804	int argc;
11805	char **argv;
11806{
11807
11808	/* pthread test function */
11809#ifndef PTHREAD_CREATE_DETACHED
11810#define	PTHREAD_CREATE_DETACHED	1
11811#endif
11812	pthread_t t;
11813	int status;
11814	int detach = PTHREAD_CREATE_DETACHED;
11815
11816#if HAVE_PTHREADS > 4
11817	/* Final pthreads */
11818	pthread_attr_t attr;
11819
11820	status = pthread_attr_init(&attr);
11821	if( status ) return status;
11822
11823#if HAVE_PTHREADS < 7
11824	status = pthread_attr_setdetachstate(&attr, &detach);
11825	if( status < 0 ) status = errno;
11826#else
11827	status = pthread_attr_setdetachstate(&attr, detach);
11828#endif
11829	if( status ) return status;
11830	status = pthread_create( &t, &attr, task, NULL );
11831#if HAVE_PTHREADS < 7
11832	if( status < 0 ) status = errno;
11833#endif
11834	if( status ) return status;
11835#else
11836	/* Draft 4 pthreads */
11837	status = pthread_create( &t, pthread_attr_default, task, NULL );
11838	if( status ) return errno;
11839
11840	/* give thread a chance to complete */
11841	/* it should remain joinable and hence detachable */
11842	sleep( 1 );
11843
11844	status = pthread_detach( &t );
11845	if( status ) return errno;
11846#endif
11847
11848#ifdef HAVE_LINUX_THREADS
11849	pthread_kill_other_threads_np();
11850#endif
11851
11852	return 0;
11853
11854}
11855
11856_ACEOF
11857if ac_fn_c_try_run "$LINENO"; then :
11858  ol_cv_pthread_lpthread=yes
11859else
11860  ol_cv_pthread_lpthread=no
11861fi
11862rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11863  conftest.$ac_objext conftest.beam conftest.$ac_ext
11864fi
11865
11866
11867		# restore the LIBS
11868		LIBS="$ol_LIBS"
11869
11870fi
11871{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lpthread" >&5
11872$as_echo "$ol_cv_pthread_lpthread" >&6; }
11873
11874	if test $ol_cv_pthread_lpthread = yes ; then
11875		ol_link_pthreads="-lpthread"
11876		ol_link_threads=posix
11877	fi
11878fi
11879
11880		# Pthread try link: -lc_r (ol_cv_pthread_lc_r)
11881if test "$ol_link_threads" = no ; then
11882	# try -lc_r
11883	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lc_r" >&5
11884$as_echo_n "checking for pthread link with -lc_r... " >&6; }
11885if ${ol_cv_pthread_lc_r+:} false; then :
11886  $as_echo_n "(cached) " >&6
11887else
11888
11889		# save the flags
11890		ol_LIBS="$LIBS"
11891		LIBS="-lc_r $LIBS"
11892
11893		if test "$cross_compiling" = yes; then :
11894  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11895/* end confdefs.h.  */
11896
11897/* pthread test headers */
11898#include <pthread.h>
11899#if HAVE_PTHREADS < 7
11900#include <errno.h>
11901#endif
11902#ifndef NULL
11903#define NULL (void*)0
11904#endif
11905
11906static void *task(p)
11907	void *p;
11908{
11909	return (void *) (p == NULL);
11910}
11911
11912int
11913main ()
11914{
11915
11916	/* pthread test function */
11917#ifndef PTHREAD_CREATE_DETACHED
11918#define	PTHREAD_CREATE_DETACHED	1
11919#endif
11920	pthread_t t;
11921	int status;
11922	int detach = PTHREAD_CREATE_DETACHED;
11923
11924#if HAVE_PTHREADS > 4
11925	/* Final pthreads */
11926	pthread_attr_t attr;
11927
11928	status = pthread_attr_init(&attr);
11929	if( status ) return status;
11930
11931#if HAVE_PTHREADS < 7
11932	status = pthread_attr_setdetachstate(&attr, &detach);
11933	if( status < 0 ) status = errno;
11934#else
11935	status = pthread_attr_setdetachstate(&attr, detach);
11936#endif
11937	if( status ) return status;
11938	status = pthread_create( &t, &attr, task, NULL );
11939#if HAVE_PTHREADS < 7
11940	if( status < 0 ) status = errno;
11941#endif
11942	if( status ) return status;
11943#else
11944	/* Draft 4 pthreads */
11945	status = pthread_create( &t, pthread_attr_default, task, NULL );
11946	if( status ) return errno;
11947
11948	/* give thread a chance to complete */
11949	/* it should remain joinable and hence detachable */
11950	sleep( 1 );
11951
11952	status = pthread_detach( &t );
11953	if( status ) return errno;
11954#endif
11955
11956#ifdef HAVE_LINUX_THREADS
11957	pthread_kill_other_threads_np();
11958#endif
11959
11960	return 0;
11961
11962  ;
11963  return 0;
11964}
11965_ACEOF
11966if ac_fn_c_try_link "$LINENO"; then :
11967  ol_cv_pthread_lc_r=yes
11968else
11969  ol_cv_pthread_lc_r=no
11970fi
11971rm -f core conftest.err conftest.$ac_objext \
11972    conftest$ac_exeext conftest.$ac_ext
11973else
11974  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11975/* end confdefs.h.  */
11976
11977
11978/* pthread test headers */
11979#include <pthread.h>
11980#if HAVE_PTHREADS < 7
11981#include <errno.h>
11982#endif
11983#ifndef NULL
11984#define NULL (void*)0
11985#endif
11986
11987static void *task(p)
11988	void *p;
11989{
11990	return (void *) (p == NULL);
11991}
11992
11993
11994int main(argc, argv)
11995	int argc;
11996	char **argv;
11997{
11998
11999	/* pthread test function */
12000#ifndef PTHREAD_CREATE_DETACHED
12001#define	PTHREAD_CREATE_DETACHED	1
12002#endif
12003	pthread_t t;
12004	int status;
12005	int detach = PTHREAD_CREATE_DETACHED;
12006
12007#if HAVE_PTHREADS > 4
12008	/* Final pthreads */
12009	pthread_attr_t attr;
12010
12011	status = pthread_attr_init(&attr);
12012	if( status ) return status;
12013
12014#if HAVE_PTHREADS < 7
12015	status = pthread_attr_setdetachstate(&attr, &detach);
12016	if( status < 0 ) status = errno;
12017#else
12018	status = pthread_attr_setdetachstate(&attr, detach);
12019#endif
12020	if( status ) return status;
12021	status = pthread_create( &t, &attr, task, NULL );
12022#if HAVE_PTHREADS < 7
12023	if( status < 0 ) status = errno;
12024#endif
12025	if( status ) return status;
12026#else
12027	/* Draft 4 pthreads */
12028	status = pthread_create( &t, pthread_attr_default, task, NULL );
12029	if( status ) return errno;
12030
12031	/* give thread a chance to complete */
12032	/* it should remain joinable and hence detachable */
12033	sleep( 1 );
12034
12035	status = pthread_detach( &t );
12036	if( status ) return errno;
12037#endif
12038
12039#ifdef HAVE_LINUX_THREADS
12040	pthread_kill_other_threads_np();
12041#endif
12042
12043	return 0;
12044
12045}
12046
12047_ACEOF
12048if ac_fn_c_try_run "$LINENO"; then :
12049  ol_cv_pthread_lc_r=yes
12050else
12051  ol_cv_pthread_lc_r=no
12052fi
12053rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12054  conftest.$ac_objext conftest.beam conftest.$ac_ext
12055fi
12056
12057
12058		# restore the LIBS
12059		LIBS="$ol_LIBS"
12060
12061fi
12062{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lc_r" >&5
12063$as_echo "$ol_cv_pthread_lc_r" >&6; }
12064
12065	if test $ol_cv_pthread_lc_r = yes ; then
12066		ol_link_pthreads="-lc_r"
12067		ol_link_threads=posix
12068	fi
12069fi
12070
12071
12072		# Pthread try link: -threads (ol_cv_pthread_threads)
12073if test "$ol_link_threads" = no ; then
12074	# try -threads
12075	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -threads" >&5
12076$as_echo_n "checking for pthread link with -threads... " >&6; }
12077if ${ol_cv_pthread_threads+:} false; then :
12078  $as_echo_n "(cached) " >&6
12079else
12080
12081		# save the flags
12082		ol_LIBS="$LIBS"
12083		LIBS="-threads $LIBS"
12084
12085		if test "$cross_compiling" = yes; then :
12086  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12087/* end confdefs.h.  */
12088
12089/* pthread test headers */
12090#include <pthread.h>
12091#if HAVE_PTHREADS < 7
12092#include <errno.h>
12093#endif
12094#ifndef NULL
12095#define NULL (void*)0
12096#endif
12097
12098static void *task(p)
12099	void *p;
12100{
12101	return (void *) (p == NULL);
12102}
12103
12104int
12105main ()
12106{
12107
12108	/* pthread test function */
12109#ifndef PTHREAD_CREATE_DETACHED
12110#define	PTHREAD_CREATE_DETACHED	1
12111#endif
12112	pthread_t t;
12113	int status;
12114	int detach = PTHREAD_CREATE_DETACHED;
12115
12116#if HAVE_PTHREADS > 4
12117	/* Final pthreads */
12118	pthread_attr_t attr;
12119
12120	status = pthread_attr_init(&attr);
12121	if( status ) return status;
12122
12123#if HAVE_PTHREADS < 7
12124	status = pthread_attr_setdetachstate(&attr, &detach);
12125	if( status < 0 ) status = errno;
12126#else
12127	status = pthread_attr_setdetachstate(&attr, detach);
12128#endif
12129	if( status ) return status;
12130	status = pthread_create( &t, &attr, task, NULL );
12131#if HAVE_PTHREADS < 7
12132	if( status < 0 ) status = errno;
12133#endif
12134	if( status ) return status;
12135#else
12136	/* Draft 4 pthreads */
12137	status = pthread_create( &t, pthread_attr_default, task, NULL );
12138	if( status ) return errno;
12139
12140	/* give thread a chance to complete */
12141	/* it should remain joinable and hence detachable */
12142	sleep( 1 );
12143
12144	status = pthread_detach( &t );
12145	if( status ) return errno;
12146#endif
12147
12148#ifdef HAVE_LINUX_THREADS
12149	pthread_kill_other_threads_np();
12150#endif
12151
12152	return 0;
12153
12154  ;
12155  return 0;
12156}
12157_ACEOF
12158if ac_fn_c_try_link "$LINENO"; then :
12159  ol_cv_pthread_threads=yes
12160else
12161  ol_cv_pthread_threads=no
12162fi
12163rm -f core conftest.err conftest.$ac_objext \
12164    conftest$ac_exeext conftest.$ac_ext
12165else
12166  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12167/* end confdefs.h.  */
12168
12169
12170/* pthread test headers */
12171#include <pthread.h>
12172#if HAVE_PTHREADS < 7
12173#include <errno.h>
12174#endif
12175#ifndef NULL
12176#define NULL (void*)0
12177#endif
12178
12179static void *task(p)
12180	void *p;
12181{
12182	return (void *) (p == NULL);
12183}
12184
12185
12186int main(argc, argv)
12187	int argc;
12188	char **argv;
12189{
12190
12191	/* pthread test function */
12192#ifndef PTHREAD_CREATE_DETACHED
12193#define	PTHREAD_CREATE_DETACHED	1
12194#endif
12195	pthread_t t;
12196	int status;
12197	int detach = PTHREAD_CREATE_DETACHED;
12198
12199#if HAVE_PTHREADS > 4
12200	/* Final pthreads */
12201	pthread_attr_t attr;
12202
12203	status = pthread_attr_init(&attr);
12204	if( status ) return status;
12205
12206#if HAVE_PTHREADS < 7
12207	status = pthread_attr_setdetachstate(&attr, &detach);
12208	if( status < 0 ) status = errno;
12209#else
12210	status = pthread_attr_setdetachstate(&attr, detach);
12211#endif
12212	if( status ) return status;
12213	status = pthread_create( &t, &attr, task, NULL );
12214#if HAVE_PTHREADS < 7
12215	if( status < 0 ) status = errno;
12216#endif
12217	if( status ) return status;
12218#else
12219	/* Draft 4 pthreads */
12220	status = pthread_create( &t, pthread_attr_default, task, NULL );
12221	if( status ) return errno;
12222
12223	/* give thread a chance to complete */
12224	/* it should remain joinable and hence detachable */
12225	sleep( 1 );
12226
12227	status = pthread_detach( &t );
12228	if( status ) return errno;
12229#endif
12230
12231#ifdef HAVE_LINUX_THREADS
12232	pthread_kill_other_threads_np();
12233#endif
12234
12235	return 0;
12236
12237}
12238
12239_ACEOF
12240if ac_fn_c_try_run "$LINENO"; then :
12241  ol_cv_pthread_threads=yes
12242else
12243  ol_cv_pthread_threads=no
12244fi
12245rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12246  conftest.$ac_objext conftest.beam conftest.$ac_ext
12247fi
12248
12249
12250		# restore the LIBS
12251		LIBS="$ol_LIBS"
12252
12253fi
12254{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_threads" >&5
12255$as_echo "$ol_cv_pthread_threads" >&6; }
12256
12257	if test $ol_cv_pthread_threads = yes ; then
12258		ol_link_pthreads="-threads"
12259		ol_link_threads=posix
12260	fi
12261fi
12262
12263
12264		# Pthread try link: -lpthreads -lmach -lexc -lc_r (ol_cv_pthread_lpthreads_lmach_lexc_lc_r)
12265if test "$ol_link_threads" = no ; then
12266	# try -lpthreads -lmach -lexc -lc_r
12267	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthreads -lmach -lexc -lc_r" >&5
12268$as_echo_n "checking for pthread link with -lpthreads -lmach -lexc -lc_r... " >&6; }
12269if ${ol_cv_pthread_lpthreads_lmach_lexc_lc_r+:} false; then :
12270  $as_echo_n "(cached) " >&6
12271else
12272
12273		# save the flags
12274		ol_LIBS="$LIBS"
12275		LIBS="-lpthreads -lmach -lexc -lc_r $LIBS"
12276
12277		if test "$cross_compiling" = yes; then :
12278  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12279/* end confdefs.h.  */
12280
12281/* pthread test headers */
12282#include <pthread.h>
12283#if HAVE_PTHREADS < 7
12284#include <errno.h>
12285#endif
12286#ifndef NULL
12287#define NULL (void*)0
12288#endif
12289
12290static void *task(p)
12291	void *p;
12292{
12293	return (void *) (p == NULL);
12294}
12295
12296int
12297main ()
12298{
12299
12300	/* pthread test function */
12301#ifndef PTHREAD_CREATE_DETACHED
12302#define	PTHREAD_CREATE_DETACHED	1
12303#endif
12304	pthread_t t;
12305	int status;
12306	int detach = PTHREAD_CREATE_DETACHED;
12307
12308#if HAVE_PTHREADS > 4
12309	/* Final pthreads */
12310	pthread_attr_t attr;
12311
12312	status = pthread_attr_init(&attr);
12313	if( status ) return status;
12314
12315#if HAVE_PTHREADS < 7
12316	status = pthread_attr_setdetachstate(&attr, &detach);
12317	if( status < 0 ) status = errno;
12318#else
12319	status = pthread_attr_setdetachstate(&attr, detach);
12320#endif
12321	if( status ) return status;
12322	status = pthread_create( &t, &attr, task, NULL );
12323#if HAVE_PTHREADS < 7
12324	if( status < 0 ) status = errno;
12325#endif
12326	if( status ) return status;
12327#else
12328	/* Draft 4 pthreads */
12329	status = pthread_create( &t, pthread_attr_default, task, NULL );
12330	if( status ) return errno;
12331
12332	/* give thread a chance to complete */
12333	/* it should remain joinable and hence detachable */
12334	sleep( 1 );
12335
12336	status = pthread_detach( &t );
12337	if( status ) return errno;
12338#endif
12339
12340#ifdef HAVE_LINUX_THREADS
12341	pthread_kill_other_threads_np();
12342#endif
12343
12344	return 0;
12345
12346  ;
12347  return 0;
12348}
12349_ACEOF
12350if ac_fn_c_try_link "$LINENO"; then :
12351  ol_cv_pthread_lpthreads_lmach_lexc_lc_r=yes
12352else
12353  ol_cv_pthread_lpthreads_lmach_lexc_lc_r=no
12354fi
12355rm -f core conftest.err conftest.$ac_objext \
12356    conftest$ac_exeext conftest.$ac_ext
12357else
12358  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12359/* end confdefs.h.  */
12360
12361
12362/* pthread test headers */
12363#include <pthread.h>
12364#if HAVE_PTHREADS < 7
12365#include <errno.h>
12366#endif
12367#ifndef NULL
12368#define NULL (void*)0
12369#endif
12370
12371static void *task(p)
12372	void *p;
12373{
12374	return (void *) (p == NULL);
12375}
12376
12377
12378int main(argc, argv)
12379	int argc;
12380	char **argv;
12381{
12382
12383	/* pthread test function */
12384#ifndef PTHREAD_CREATE_DETACHED
12385#define	PTHREAD_CREATE_DETACHED	1
12386#endif
12387	pthread_t t;
12388	int status;
12389	int detach = PTHREAD_CREATE_DETACHED;
12390
12391#if HAVE_PTHREADS > 4
12392	/* Final pthreads */
12393	pthread_attr_t attr;
12394
12395	status = pthread_attr_init(&attr);
12396	if( status ) return status;
12397
12398#if HAVE_PTHREADS < 7
12399	status = pthread_attr_setdetachstate(&attr, &detach);
12400	if( status < 0 ) status = errno;
12401#else
12402	status = pthread_attr_setdetachstate(&attr, detach);
12403#endif
12404	if( status ) return status;
12405	status = pthread_create( &t, &attr, task, NULL );
12406#if HAVE_PTHREADS < 7
12407	if( status < 0 ) status = errno;
12408#endif
12409	if( status ) return status;
12410#else
12411	/* Draft 4 pthreads */
12412	status = pthread_create( &t, pthread_attr_default, task, NULL );
12413	if( status ) return errno;
12414
12415	/* give thread a chance to complete */
12416	/* it should remain joinable and hence detachable */
12417	sleep( 1 );
12418
12419	status = pthread_detach( &t );
12420	if( status ) return errno;
12421#endif
12422
12423#ifdef HAVE_LINUX_THREADS
12424	pthread_kill_other_threads_np();
12425#endif
12426
12427	return 0;
12428
12429}
12430
12431_ACEOF
12432if ac_fn_c_try_run "$LINENO"; then :
12433  ol_cv_pthread_lpthreads_lmach_lexc_lc_r=yes
12434else
12435  ol_cv_pthread_lpthreads_lmach_lexc_lc_r=no
12436fi
12437rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12438  conftest.$ac_objext conftest.beam conftest.$ac_ext
12439fi
12440
12441
12442		# restore the LIBS
12443		LIBS="$ol_LIBS"
12444
12445fi
12446{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lpthreads_lmach_lexc_lc_r" >&5
12447$as_echo "$ol_cv_pthread_lpthreads_lmach_lexc_lc_r" >&6; }
12448
12449	if test $ol_cv_pthread_lpthreads_lmach_lexc_lc_r = yes ; then
12450		ol_link_pthreads="-lpthreads -lmach -lexc -lc_r"
12451		ol_link_threads=posix
12452	fi
12453fi
12454
12455		# Pthread try link: -lpthreads -lmach -lexc (ol_cv_pthread_lpthreads_lmach_lexc)
12456if test "$ol_link_threads" = no ; then
12457	# try -lpthreads -lmach -lexc
12458	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthreads -lmach -lexc" >&5
12459$as_echo_n "checking for pthread link with -lpthreads -lmach -lexc... " >&6; }
12460if ${ol_cv_pthread_lpthreads_lmach_lexc+:} false; then :
12461  $as_echo_n "(cached) " >&6
12462else
12463
12464		# save the flags
12465		ol_LIBS="$LIBS"
12466		LIBS="-lpthreads -lmach -lexc $LIBS"
12467
12468		if test "$cross_compiling" = yes; then :
12469  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12470/* end confdefs.h.  */
12471
12472/* pthread test headers */
12473#include <pthread.h>
12474#if HAVE_PTHREADS < 7
12475#include <errno.h>
12476#endif
12477#ifndef NULL
12478#define NULL (void*)0
12479#endif
12480
12481static void *task(p)
12482	void *p;
12483{
12484	return (void *) (p == NULL);
12485}
12486
12487int
12488main ()
12489{
12490
12491	/* pthread test function */
12492#ifndef PTHREAD_CREATE_DETACHED
12493#define	PTHREAD_CREATE_DETACHED	1
12494#endif
12495	pthread_t t;
12496	int status;
12497	int detach = PTHREAD_CREATE_DETACHED;
12498
12499#if HAVE_PTHREADS > 4
12500	/* Final pthreads */
12501	pthread_attr_t attr;
12502
12503	status = pthread_attr_init(&attr);
12504	if( status ) return status;
12505
12506#if HAVE_PTHREADS < 7
12507	status = pthread_attr_setdetachstate(&attr, &detach);
12508	if( status < 0 ) status = errno;
12509#else
12510	status = pthread_attr_setdetachstate(&attr, detach);
12511#endif
12512	if( status ) return status;
12513	status = pthread_create( &t, &attr, task, NULL );
12514#if HAVE_PTHREADS < 7
12515	if( status < 0 ) status = errno;
12516#endif
12517	if( status ) return status;
12518#else
12519	/* Draft 4 pthreads */
12520	status = pthread_create( &t, pthread_attr_default, task, NULL );
12521	if( status ) return errno;
12522
12523	/* give thread a chance to complete */
12524	/* it should remain joinable and hence detachable */
12525	sleep( 1 );
12526
12527	status = pthread_detach( &t );
12528	if( status ) return errno;
12529#endif
12530
12531#ifdef HAVE_LINUX_THREADS
12532	pthread_kill_other_threads_np();
12533#endif
12534
12535	return 0;
12536
12537  ;
12538  return 0;
12539}
12540_ACEOF
12541if ac_fn_c_try_link "$LINENO"; then :
12542  ol_cv_pthread_lpthreads_lmach_lexc=yes
12543else
12544  ol_cv_pthread_lpthreads_lmach_lexc=no
12545fi
12546rm -f core conftest.err conftest.$ac_objext \
12547    conftest$ac_exeext conftest.$ac_ext
12548else
12549  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12550/* end confdefs.h.  */
12551
12552
12553/* pthread test headers */
12554#include <pthread.h>
12555#if HAVE_PTHREADS < 7
12556#include <errno.h>
12557#endif
12558#ifndef NULL
12559#define NULL (void*)0
12560#endif
12561
12562static void *task(p)
12563	void *p;
12564{
12565	return (void *) (p == NULL);
12566}
12567
12568
12569int main(argc, argv)
12570	int argc;
12571	char **argv;
12572{
12573
12574	/* pthread test function */
12575#ifndef PTHREAD_CREATE_DETACHED
12576#define	PTHREAD_CREATE_DETACHED	1
12577#endif
12578	pthread_t t;
12579	int status;
12580	int detach = PTHREAD_CREATE_DETACHED;
12581
12582#if HAVE_PTHREADS > 4
12583	/* Final pthreads */
12584	pthread_attr_t attr;
12585
12586	status = pthread_attr_init(&attr);
12587	if( status ) return status;
12588
12589#if HAVE_PTHREADS < 7
12590	status = pthread_attr_setdetachstate(&attr, &detach);
12591	if( status < 0 ) status = errno;
12592#else
12593	status = pthread_attr_setdetachstate(&attr, detach);
12594#endif
12595	if( status ) return status;
12596	status = pthread_create( &t, &attr, task, NULL );
12597#if HAVE_PTHREADS < 7
12598	if( status < 0 ) status = errno;
12599#endif
12600	if( status ) return status;
12601#else
12602	/* Draft 4 pthreads */
12603	status = pthread_create( &t, pthread_attr_default, task, NULL );
12604	if( status ) return errno;
12605
12606	/* give thread a chance to complete */
12607	/* it should remain joinable and hence detachable */
12608	sleep( 1 );
12609
12610	status = pthread_detach( &t );
12611	if( status ) return errno;
12612#endif
12613
12614#ifdef HAVE_LINUX_THREADS
12615	pthread_kill_other_threads_np();
12616#endif
12617
12618	return 0;
12619
12620}
12621
12622_ACEOF
12623if ac_fn_c_try_run "$LINENO"; then :
12624  ol_cv_pthread_lpthreads_lmach_lexc=yes
12625else
12626  ol_cv_pthread_lpthreads_lmach_lexc=no
12627fi
12628rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12629  conftest.$ac_objext conftest.beam conftest.$ac_ext
12630fi
12631
12632
12633		# restore the LIBS
12634		LIBS="$ol_LIBS"
12635
12636fi
12637{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lpthreads_lmach_lexc" >&5
12638$as_echo "$ol_cv_pthread_lpthreads_lmach_lexc" >&6; }
12639
12640	if test $ol_cv_pthread_lpthreads_lmach_lexc = yes ; then
12641		ol_link_pthreads="-lpthreads -lmach -lexc"
12642		ol_link_threads=posix
12643	fi
12644fi
12645
12646		# Pthread try link: -lpthreads -lexc (ol_cv_pthread_lpthreads_lexc)
12647if test "$ol_link_threads" = no ; then
12648	# try -lpthreads -lexc
12649	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthreads -lexc" >&5
12650$as_echo_n "checking for pthread link with -lpthreads -lexc... " >&6; }
12651if ${ol_cv_pthread_lpthreads_lexc+:} false; then :
12652  $as_echo_n "(cached) " >&6
12653else
12654
12655		# save the flags
12656		ol_LIBS="$LIBS"
12657		LIBS="-lpthreads -lexc $LIBS"
12658
12659		if test "$cross_compiling" = yes; then :
12660  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12661/* end confdefs.h.  */
12662
12663/* pthread test headers */
12664#include <pthread.h>
12665#if HAVE_PTHREADS < 7
12666#include <errno.h>
12667#endif
12668#ifndef NULL
12669#define NULL (void*)0
12670#endif
12671
12672static void *task(p)
12673	void *p;
12674{
12675	return (void *) (p == NULL);
12676}
12677
12678int
12679main ()
12680{
12681
12682	/* pthread test function */
12683#ifndef PTHREAD_CREATE_DETACHED
12684#define	PTHREAD_CREATE_DETACHED	1
12685#endif
12686	pthread_t t;
12687	int status;
12688	int detach = PTHREAD_CREATE_DETACHED;
12689
12690#if HAVE_PTHREADS > 4
12691	/* Final pthreads */
12692	pthread_attr_t attr;
12693
12694	status = pthread_attr_init(&attr);
12695	if( status ) return status;
12696
12697#if HAVE_PTHREADS < 7
12698	status = pthread_attr_setdetachstate(&attr, &detach);
12699	if( status < 0 ) status = errno;
12700#else
12701	status = pthread_attr_setdetachstate(&attr, detach);
12702#endif
12703	if( status ) return status;
12704	status = pthread_create( &t, &attr, task, NULL );
12705#if HAVE_PTHREADS < 7
12706	if( status < 0 ) status = errno;
12707#endif
12708	if( status ) return status;
12709#else
12710	/* Draft 4 pthreads */
12711	status = pthread_create( &t, pthread_attr_default, task, NULL );
12712	if( status ) return errno;
12713
12714	/* give thread a chance to complete */
12715	/* it should remain joinable and hence detachable */
12716	sleep( 1 );
12717
12718	status = pthread_detach( &t );
12719	if( status ) return errno;
12720#endif
12721
12722#ifdef HAVE_LINUX_THREADS
12723	pthread_kill_other_threads_np();
12724#endif
12725
12726	return 0;
12727
12728  ;
12729  return 0;
12730}
12731_ACEOF
12732if ac_fn_c_try_link "$LINENO"; then :
12733  ol_cv_pthread_lpthreads_lexc=yes
12734else
12735  ol_cv_pthread_lpthreads_lexc=no
12736fi
12737rm -f core conftest.err conftest.$ac_objext \
12738    conftest$ac_exeext conftest.$ac_ext
12739else
12740  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12741/* end confdefs.h.  */
12742
12743
12744/* pthread test headers */
12745#include <pthread.h>
12746#if HAVE_PTHREADS < 7
12747#include <errno.h>
12748#endif
12749#ifndef NULL
12750#define NULL (void*)0
12751#endif
12752
12753static void *task(p)
12754	void *p;
12755{
12756	return (void *) (p == NULL);
12757}
12758
12759
12760int main(argc, argv)
12761	int argc;
12762	char **argv;
12763{
12764
12765	/* pthread test function */
12766#ifndef PTHREAD_CREATE_DETACHED
12767#define	PTHREAD_CREATE_DETACHED	1
12768#endif
12769	pthread_t t;
12770	int status;
12771	int detach = PTHREAD_CREATE_DETACHED;
12772
12773#if HAVE_PTHREADS > 4
12774	/* Final pthreads */
12775	pthread_attr_t attr;
12776
12777	status = pthread_attr_init(&attr);
12778	if( status ) return status;
12779
12780#if HAVE_PTHREADS < 7
12781	status = pthread_attr_setdetachstate(&attr, &detach);
12782	if( status < 0 ) status = errno;
12783#else
12784	status = pthread_attr_setdetachstate(&attr, detach);
12785#endif
12786	if( status ) return status;
12787	status = pthread_create( &t, &attr, task, NULL );
12788#if HAVE_PTHREADS < 7
12789	if( status < 0 ) status = errno;
12790#endif
12791	if( status ) return status;
12792#else
12793	/* Draft 4 pthreads */
12794	status = pthread_create( &t, pthread_attr_default, task, NULL );
12795	if( status ) return errno;
12796
12797	/* give thread a chance to complete */
12798	/* it should remain joinable and hence detachable */
12799	sleep( 1 );
12800
12801	status = pthread_detach( &t );
12802	if( status ) return errno;
12803#endif
12804
12805#ifdef HAVE_LINUX_THREADS
12806	pthread_kill_other_threads_np();
12807#endif
12808
12809	return 0;
12810
12811}
12812
12813_ACEOF
12814if ac_fn_c_try_run "$LINENO"; then :
12815  ol_cv_pthread_lpthreads_lexc=yes
12816else
12817  ol_cv_pthread_lpthreads_lexc=no
12818fi
12819rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12820  conftest.$ac_objext conftest.beam conftest.$ac_ext
12821fi
12822
12823
12824		# restore the LIBS
12825		LIBS="$ol_LIBS"
12826
12827fi
12828{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lpthreads_lexc" >&5
12829$as_echo "$ol_cv_pthread_lpthreads_lexc" >&6; }
12830
12831	if test $ol_cv_pthread_lpthreads_lexc = yes ; then
12832		ol_link_pthreads="-lpthreads -lexc"
12833		ol_link_threads=posix
12834	fi
12835fi
12836
12837
12838		# Pthread try link: -lpthreads (ol_cv_pthread_lib_lpthreads)
12839if test "$ol_link_threads" = no ; then
12840	# try -lpthreads
12841	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthreads" >&5
12842$as_echo_n "checking for pthread link with -lpthreads... " >&6; }
12843if ${ol_cv_pthread_lib_lpthreads+:} false; then :
12844  $as_echo_n "(cached) " >&6
12845else
12846
12847		# save the flags
12848		ol_LIBS="$LIBS"
12849		LIBS="-lpthreads $LIBS"
12850
12851		if test "$cross_compiling" = yes; then :
12852  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12853/* end confdefs.h.  */
12854
12855/* pthread test headers */
12856#include <pthread.h>
12857#if HAVE_PTHREADS < 7
12858#include <errno.h>
12859#endif
12860#ifndef NULL
12861#define NULL (void*)0
12862#endif
12863
12864static void *task(p)
12865	void *p;
12866{
12867	return (void *) (p == NULL);
12868}
12869
12870int
12871main ()
12872{
12873
12874	/* pthread test function */
12875#ifndef PTHREAD_CREATE_DETACHED
12876#define	PTHREAD_CREATE_DETACHED	1
12877#endif
12878	pthread_t t;
12879	int status;
12880	int detach = PTHREAD_CREATE_DETACHED;
12881
12882#if HAVE_PTHREADS > 4
12883	/* Final pthreads */
12884	pthread_attr_t attr;
12885
12886	status = pthread_attr_init(&attr);
12887	if( status ) return status;
12888
12889#if HAVE_PTHREADS < 7
12890	status = pthread_attr_setdetachstate(&attr, &detach);
12891	if( status < 0 ) status = errno;
12892#else
12893	status = pthread_attr_setdetachstate(&attr, detach);
12894#endif
12895	if( status ) return status;
12896	status = pthread_create( &t, &attr, task, NULL );
12897#if HAVE_PTHREADS < 7
12898	if( status < 0 ) status = errno;
12899#endif
12900	if( status ) return status;
12901#else
12902	/* Draft 4 pthreads */
12903	status = pthread_create( &t, pthread_attr_default, task, NULL );
12904	if( status ) return errno;
12905
12906	/* give thread a chance to complete */
12907	/* it should remain joinable and hence detachable */
12908	sleep( 1 );
12909
12910	status = pthread_detach( &t );
12911	if( status ) return errno;
12912#endif
12913
12914#ifdef HAVE_LINUX_THREADS
12915	pthread_kill_other_threads_np();
12916#endif
12917
12918	return 0;
12919
12920  ;
12921  return 0;
12922}
12923_ACEOF
12924if ac_fn_c_try_link "$LINENO"; then :
12925  ol_cv_pthread_lib_lpthreads=yes
12926else
12927  ol_cv_pthread_lib_lpthreads=no
12928fi
12929rm -f core conftest.err conftest.$ac_objext \
12930    conftest$ac_exeext conftest.$ac_ext
12931else
12932  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12933/* end confdefs.h.  */
12934
12935
12936/* pthread test headers */
12937#include <pthread.h>
12938#if HAVE_PTHREADS < 7
12939#include <errno.h>
12940#endif
12941#ifndef NULL
12942#define NULL (void*)0
12943#endif
12944
12945static void *task(p)
12946	void *p;
12947{
12948	return (void *) (p == NULL);
12949}
12950
12951
12952int main(argc, argv)
12953	int argc;
12954	char **argv;
12955{
12956
12957	/* pthread test function */
12958#ifndef PTHREAD_CREATE_DETACHED
12959#define	PTHREAD_CREATE_DETACHED	1
12960#endif
12961	pthread_t t;
12962	int status;
12963	int detach = PTHREAD_CREATE_DETACHED;
12964
12965#if HAVE_PTHREADS > 4
12966	/* Final pthreads */
12967	pthread_attr_t attr;
12968
12969	status = pthread_attr_init(&attr);
12970	if( status ) return status;
12971
12972#if HAVE_PTHREADS < 7
12973	status = pthread_attr_setdetachstate(&attr, &detach);
12974	if( status < 0 ) status = errno;
12975#else
12976	status = pthread_attr_setdetachstate(&attr, detach);
12977#endif
12978	if( status ) return status;
12979	status = pthread_create( &t, &attr, task, NULL );
12980#if HAVE_PTHREADS < 7
12981	if( status < 0 ) status = errno;
12982#endif
12983	if( status ) return status;
12984#else
12985	/* Draft 4 pthreads */
12986	status = pthread_create( &t, pthread_attr_default, task, NULL );
12987	if( status ) return errno;
12988
12989	/* give thread a chance to complete */
12990	/* it should remain joinable and hence detachable */
12991	sleep( 1 );
12992
12993	status = pthread_detach( &t );
12994	if( status ) return errno;
12995#endif
12996
12997#ifdef HAVE_LINUX_THREADS
12998	pthread_kill_other_threads_np();
12999#endif
13000
13001	return 0;
13002
13003}
13004
13005_ACEOF
13006if ac_fn_c_try_run "$LINENO"; then :
13007  ol_cv_pthread_lib_lpthreads=yes
13008else
13009  ol_cv_pthread_lib_lpthreads=no
13010fi
13011rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13012  conftest.$ac_objext conftest.beam conftest.$ac_ext
13013fi
13014
13015
13016		# restore the LIBS
13017		LIBS="$ol_LIBS"
13018
13019fi
13020{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lib_lpthreads" >&5
13021$as_echo "$ol_cv_pthread_lib_lpthreads" >&6; }
13022
13023	if test $ol_cv_pthread_lib_lpthreads = yes ; then
13024		ol_link_pthreads="-lpthreads"
13025		ol_link_threads=posix
13026	fi
13027fi
13028
13029
13030{ $as_echo "$as_me:${as_lineno-$LINENO}: ol_link_threads: <$ol_link_threads> ol_link_pthreads <$ol_link_pthreads>" >&5
13031$as_echo "$as_me: ol_link_threads: <$ol_link_threads> ol_link_pthreads <$ol_link_pthreads>" >&6;}
13032
13033		if test $ol_link_threads != no ; then
13034			LTHREAD_LIBS="$LTHREAD_LIBS $ol_link_pthreads"
13035
13036						save_CPPFLAGS="$CPPFLAGS"
13037			save_LIBS="$LIBS"
13038			LIBS="$LTHREAD_LIBS $LIBS"
13039
13040												for ac_func in sched_yield pthread_yield thr_yield
13041do :
13042  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13043ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13044if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
13045  cat >>confdefs.h <<_ACEOF
13046#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13047_ACEOF
13048
13049fi
13050done
13051
13052
13053			if test $ac_cv_func_sched_yield = no &&
13054			   test $ac_cv_func_pthread_yield = no &&
13055			   test $ac_cv_func_thr_yield = no ; then
13056								{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sched_yield in -lrt" >&5
13057$as_echo_n "checking for sched_yield in -lrt... " >&6; }
13058if ${ac_cv_lib_rt_sched_yield+:} false; then :
13059  $as_echo_n "(cached) " >&6
13060else
13061  ac_check_lib_save_LIBS=$LIBS
13062LIBS="-lrt  $LIBS"
13063cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13064/* end confdefs.h.  */
13065
13066/* Override any GCC internal prototype to avoid an error.
13067   Use char because int might match the return type of a GCC
13068   builtin and then its argument prototype would still apply.  */
13069#ifdef __cplusplus
13070extern "C"
13071#endif
13072char sched_yield ();
13073int
13074main ()
13075{
13076return sched_yield ();
13077  ;
13078  return 0;
13079}
13080_ACEOF
13081if ac_fn_c_try_link "$LINENO"; then :
13082  ac_cv_lib_rt_sched_yield=yes
13083else
13084  ac_cv_lib_rt_sched_yield=no
13085fi
13086rm -f core conftest.err conftest.$ac_objext \
13087    conftest$ac_exeext conftest.$ac_ext
13088LIBS=$ac_check_lib_save_LIBS
13089fi
13090{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_rt_sched_yield" >&5
13091$as_echo "$ac_cv_lib_rt_sched_yield" >&6; }
13092if test "x$ac_cv_lib_rt_sched_yield" = xyes; then :
13093  LTHREAD_LIBS="$LTHREAD_LIBS -lrt"
13094
13095$as_echo "#define HAVE_SCHED_YIELD 1" >>confdefs.h
13096
13097					ac_cv_func_sched_yield=yes
13098else
13099  ac_cv_func_sched_yield=no
13100fi
13101
13102			fi
13103			if test $ac_cv_func_sched_yield = no &&
13104			   test $ac_cv_func_pthread_yield = no &&
13105			   test "$ac_cv_func_thr_yield" = no ; then
13106				{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: could not locate sched_yield() or pthread_yield()" >&5
13107$as_echo "$as_me: WARNING: could not locate sched_yield() or pthread_yield()" >&2;}
13108			fi
13109
13110						for ac_func in pthread_kill
13111do :
13112  ac_fn_c_check_func "$LINENO" "pthread_kill" "ac_cv_func_pthread_kill"
13113if test "x$ac_cv_func_pthread_kill" = xyes; then :
13114  cat >>confdefs.h <<_ACEOF
13115#define HAVE_PTHREAD_KILL 1
13116_ACEOF
13117
13118fi
13119done
13120
13121
13122									{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_rwlock_destroy with <pthread.h>" >&5
13123$as_echo_n "checking for pthread_rwlock_destroy with <pthread.h>... " >&6; }
13124if ${ol_cv_func_pthread_rwlock_destroy+:} false; then :
13125  $as_echo_n "(cached) " >&6
13126else
13127
13128								cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13129/* end confdefs.h.  */
13130
13131#include <pthread.h>
13132pthread_rwlock_t rwlock;
13133
13134int
13135main ()
13136{
13137pthread_rwlock_destroy(&rwlock);
13138  ;
13139  return 0;
13140}
13141_ACEOF
13142if ac_fn_c_try_link "$LINENO"; then :
13143  ol_cv_func_pthread_rwlock_destroy=yes
13144else
13145  ol_cv_func_pthread_rwlock_destroy=no
13146fi
13147rm -f core conftest.err conftest.$ac_objext \
13148    conftest$ac_exeext conftest.$ac_ext
13149
13150fi
13151{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_func_pthread_rwlock_destroy" >&5
13152$as_echo "$ol_cv_func_pthread_rwlock_destroy" >&6; }
13153			if test $ol_cv_func_pthread_rwlock_destroy = yes ; then
13154
13155$as_echo "#define HAVE_PTHREAD_RWLOCK_DESTROY 1" >>confdefs.h
13156
13157			fi
13158
13159									{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_detach with <pthread.h>" >&5
13160$as_echo_n "checking for pthread_detach with <pthread.h>... " >&6; }
13161if ${ol_cv_func_pthread_detach+:} false; then :
13162  $as_echo_n "(cached) " >&6
13163else
13164
13165								cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13166/* end confdefs.h.  */
13167
13168#include <pthread.h>
13169#ifndef NULL
13170#define NULL (void*)0
13171#endif
13172
13173int
13174main ()
13175{
13176pthread_detach(NULL);
13177  ;
13178  return 0;
13179}
13180_ACEOF
13181if ac_fn_c_try_link "$LINENO"; then :
13182  ol_cv_func_pthread_detach=yes
13183else
13184  ol_cv_func_pthread_detach=no
13185fi
13186rm -f core conftest.err conftest.$ac_objext \
13187    conftest$ac_exeext conftest.$ac_ext
13188
13189fi
13190{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_func_pthread_detach" >&5
13191$as_echo "$ol_cv_func_pthread_detach" >&6; }
13192
13193			if test $ol_cv_func_pthread_detach = no ; then
13194				as_fn_error $? "could not locate pthread_detach()" "$LINENO" 5
13195			fi
13196
13197
13198$as_echo "#define HAVE_PTHREAD_DETACH 1" >>confdefs.h
13199
13200
13201						for ac_func in \
13202				pthread_setconcurrency \
13203				pthread_getconcurrency \
13204				thr_setconcurrency \
13205				thr_getconcurrency \
13206
13207do :
13208  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13209ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13210if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
13211  cat >>confdefs.h <<_ACEOF
13212#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13213_ACEOF
13214
13215fi
13216done
13217
13218
13219
13220	for ac_func in pthread_kill_other_threads_np
13221do :
13222  ac_fn_c_check_func "$LINENO" "pthread_kill_other_threads_np" "ac_cv_func_pthread_kill_other_threads_np"
13223if test "x$ac_cv_func_pthread_kill_other_threads_np" = xyes; then :
13224  cat >>confdefs.h <<_ACEOF
13225#define HAVE_PTHREAD_KILL_OTHER_THREADS_NP 1
13226_ACEOF
13227
13228fi
13229done
13230
13231	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LinuxThreads implementation" >&5
13232$as_echo_n "checking for LinuxThreads implementation... " >&6; }
13233if ${ol_cv_sys_linux_threads+:} false; then :
13234  $as_echo_n "(cached) " >&6
13235else
13236  ol_cv_sys_linux_threads=$ac_cv_func_pthread_kill_other_threads_np
13237fi
13238{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_sys_linux_threads" >&5
13239$as_echo "$ol_cv_sys_linux_threads" >&6; }
13240
13241
13242
13243
13244	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LinuxThreads consistency" >&5
13245$as_echo_n "checking for LinuxThreads consistency... " >&6; }
13246if ${ol_cv_linux_threads+:} false; then :
13247  $as_echo_n "(cached) " >&6
13248else
13249
13250		if test $ol_cv_header_linux_threads = yes &&
13251		   test $ol_cv_sys_linux_threads = yes; then
13252			ol_cv_linux_threads=yes
13253		elif test $ol_cv_header_linux_threads = no &&
13254		     test $ol_cv_sys_linux_threads = no; then
13255			ol_cv_linux_threads=no
13256		else
13257			ol_cv_linux_threads=error
13258		fi
13259
13260fi
13261{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_linux_threads" >&5
13262$as_echo "$ol_cv_linux_threads" >&6; }
13263
13264
13265			if test $ol_cv_linux_threads = error; then
13266				as_fn_error $? "LinuxThreads header/library mismatch" "$LINENO" 5;
13267			fi
13268
13269			{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if pthread_create() works" >&5
13270$as_echo_n "checking if pthread_create() works... " >&6; }
13271if ${ol_cv_pthread_create_works+:} false; then :
13272  $as_echo_n "(cached) " >&6
13273else
13274
13275			if test "$cross_compiling" = yes; then :
13276  				ol_cv_pthread_create_works=yes
13277else
13278  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13279/* end confdefs.h.  */
13280
13281
13282/* pthread test headers */
13283#include <pthread.h>
13284#if HAVE_PTHREADS < 7
13285#include <errno.h>
13286#endif
13287#ifndef NULL
13288#define NULL (void*)0
13289#endif
13290
13291static void *task(p)
13292	void *p;
13293{
13294	return (void *) (p == NULL);
13295}
13296
13297
13298int main(argc, argv)
13299	int argc;
13300	char **argv;
13301{
13302
13303	/* pthread test function */
13304#ifndef PTHREAD_CREATE_DETACHED
13305#define	PTHREAD_CREATE_DETACHED	1
13306#endif
13307	pthread_t t;
13308	int status;
13309	int detach = PTHREAD_CREATE_DETACHED;
13310
13311#if HAVE_PTHREADS > 4
13312	/* Final pthreads */
13313	pthread_attr_t attr;
13314
13315	status = pthread_attr_init(&attr);
13316	if( status ) return status;
13317
13318#if HAVE_PTHREADS < 7
13319	status = pthread_attr_setdetachstate(&attr, &detach);
13320	if( status < 0 ) status = errno;
13321#else
13322	status = pthread_attr_setdetachstate(&attr, detach);
13323#endif
13324	if( status ) return status;
13325	status = pthread_create( &t, &attr, task, NULL );
13326#if HAVE_PTHREADS < 7
13327	if( status < 0 ) status = errno;
13328#endif
13329	if( status ) return status;
13330#else
13331	/* Draft 4 pthreads */
13332	status = pthread_create( &t, pthread_attr_default, task, NULL );
13333	if( status ) return errno;
13334
13335	/* give thread a chance to complete */
13336	/* it should remain joinable and hence detachable */
13337	sleep( 1 );
13338
13339	status = pthread_detach( &t );
13340	if( status ) return errno;
13341#endif
13342
13343#ifdef HAVE_LINUX_THREADS
13344	pthread_kill_other_threads_np();
13345#endif
13346
13347	return 0;
13348
13349}
13350
13351_ACEOF
13352if ac_fn_c_try_run "$LINENO"; then :
13353  ol_cv_pthread_create_works=yes
13354else
13355  ol_cv_pthread_create_works=no
13356fi
13357rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13358  conftest.$ac_objext conftest.beam conftest.$ac_ext
13359fi
13360
13361fi
13362{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_create_works" >&5
13363$as_echo "$ol_cv_pthread_create_works" >&6; }
13364
13365			if test $ol_cv_pthread_create_works = no ; then
13366				as_fn_error $? "pthread_create is not usable, check environment settings" "$LINENO" 5
13367			fi
13368
13369			ol_replace_broken_yield=no
13370
13371			if test $ol_replace_broken_yield = yes ; then
13372
13373$as_echo "#define REPLACE_BROKEN_YIELD 1" >>confdefs.h
13374
13375			fi
13376
13377						if test x$ol_with_yielding_select = xauto ; then
13378				{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if select yields when using pthreads" >&5
13379$as_echo_n "checking if select yields when using pthreads... " >&6; }
13380if ${ol_cv_pthread_select_yields+:} false; then :
13381  $as_echo_n "(cached) " >&6
13382else
13383
13384				if test "$cross_compiling" = yes; then :
13385  ol_cv_pthread_select_yields=cross
13386else
13387  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13388/* end confdefs.h.  */
13389
13390#include <sys/types.h>
13391#include <sys/time.h>
13392#include <unistd.h>
13393#include <pthread.h>
13394#ifndef NULL
13395#define NULL (void*) 0
13396#endif
13397
13398static int fildes[2];
13399
13400static void *task(p)
13401	void *p;
13402{
13403	int i;
13404	struct timeval tv;
13405
13406	fd_set rfds;
13407
13408	tv.tv_sec=10;
13409	tv.tv_usec=0;
13410
13411	FD_ZERO(&rfds);
13412	FD_SET(fildes[0], &rfds);
13413
13414	/* we're not interested in any fds */
13415	i = select(FD_SETSIZE, &rfds, NULL, NULL, &tv);
13416
13417	if(i < 0) {
13418		perror("select");
13419		exit(10);
13420	}
13421
13422	exit(0); /* if we exit here, the select blocked the whole process */
13423}
13424
13425int main(argc, argv)
13426	int argc;
13427	char **argv;
13428{
13429	pthread_t t;
13430
13431	/* create a pipe to select */
13432	if(pipe(&fildes[0])) {
13433		perror("select");
13434		exit(1);
13435	}
13436
13437#ifdef HAVE_PTHREAD_SETCONCURRENCY
13438	(void) pthread_setconcurrency(2);
13439#else
13440#ifdef HAVE_THR_SETCONCURRENCY
13441	/* Set Solaris LWP concurrency to 2 */
13442	thr_setconcurrency(2);
13443#endif
13444#endif
13445
13446#if HAVE_PTHREADS < 6
13447	pthread_create(&t, pthread_attr_default, task, NULL);
13448#else
13449	pthread_create(&t, NULL, task, NULL);
13450#endif
13451
13452	/* make sure task runs first */
13453#ifdef HAVE_THR_YIELD
13454	thr_yield();
13455#elif defined( HAVE_SCHED_YIELD )
13456	sched_yield();
13457#elif defined( HAVE_PTHREAD_YIELD )
13458	pthread_yield();
13459#endif
13460
13461	exit(2);
13462}
13463_ACEOF
13464if ac_fn_c_try_run "$LINENO"; then :
13465  ol_cv_pthread_select_yields=no
13466else
13467  ol_cv_pthread_select_yields=yes
13468fi
13469rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13470  conftest.$ac_objext conftest.beam conftest.$ac_ext
13471fi
13472
13473fi
13474{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_select_yields" >&5
13475$as_echo "$ol_cv_pthread_select_yields" >&6; }
13476
13477				if test $ol_cv_pthread_select_yields = cross ; then
13478					as_fn_error $? "crossing compiling: use --with-yielding-select=yes|no|manual" "$LINENO" 5
13479				fi
13480
13481				if test $ol_cv_pthread_select_yields = yes ; then
13482					ol_with_yielding_select=yes
13483				fi
13484			fi
13485
13486						CPPFLAGS="$save_CPPFLAGS"
13487			LIBS="$save_LIBS"
13488		else
13489			as_fn_error $? "could not locate usable POSIX Threads" "$LINENO" 5
13490		fi
13491	fi
13492
13493	if test $ol_with_threads = posix ; then
13494		as_fn_error $? "could not locate POSIX Threads" "$LINENO" 5
13495	fi
13496	;;
13497esac
13498
13499case $ol_with_threads in auto | yes | mach)
13500
13501		for ac_header in mach/cthreads.h cthreads.h
13502do :
13503  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13504ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
13505if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
13506  cat >>confdefs.h <<_ACEOF
13507#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13508_ACEOF
13509
13510fi
13511
13512done
13513
13514	if test $ac_cv_header_mach_cthreads_h = yes ; then
13515		ol_with_threads=found
13516
13517				ac_fn_c_check_func "$LINENO" "cthread_fork" "ac_cv_func_cthread_fork"
13518if test "x$ac_cv_func_cthread_fork" = xyes; then :
13519  ol_link_threads=yes
13520fi
13521
13522
13523		if test $ol_link_threads = no ; then
13524									{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for cthread_fork with -all_load" >&5
13525$as_echo_n "checking for cthread_fork with -all_load... " >&6; }
13526if ${ol_cv_cthread_all_load+:} false; then :
13527  $as_echo_n "(cached) " >&6
13528else
13529
13530								save_LIBS="$LIBS"
13531				LIBS="-all_load $LIBS"
13532				cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13533/* end confdefs.h.  */
13534#include <mach/cthreads.h>
13535int
13536main ()
13537{
13538
13539					cthread_fork((void *)0, (void *)0);
13540
13541  ;
13542  return 0;
13543}
13544_ACEOF
13545if ac_fn_c_try_link "$LINENO"; then :
13546  ol_cv_cthread_all_load=yes
13547else
13548  ol_cv_cthread_all_load=no
13549fi
13550rm -f core conftest.err conftest.$ac_objext \
13551    conftest$ac_exeext conftest.$ac_ext
13552								LIBS="$save_LIBS"
13553
13554fi
13555{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_cthread_all_load" >&5
13556$as_echo "$ol_cv_cthread_all_load" >&6; }
13557
13558			if test $ol_cv_cthread_all_load = yes ; then
13559				LTHREAD_LIBS="$LTHREAD_LIBS -all_load"
13560				ol_link_threads=mach
13561				ol_with_threads=found
13562			fi
13563		fi
13564
13565	elif test $ac_cv_header_cthreads_h = yes ; then
13566
13567		ol_with_threads=found
13568
13569				save_LIBS="$LIBS"
13570		LIBS="$LIBS -lthreads"
13571		ac_fn_c_check_func "$LINENO" "cthread_fork" "ac_cv_func_cthread_fork"
13572if test "x$ac_cv_func_cthread_fork" = xyes; then :
13573  ol_link_threads=yes
13574fi
13575
13576		LIBS="$save_LIBS"
13577
13578		if test $ol_link_threads = yes ; then
13579			LTHREAD_LIBS="-lthreads"
13580			ol_link_threads=mach
13581			ol_with_threads=found
13582		else
13583			as_fn_error $? "could not link with Mach CThreads" "$LINENO" 5
13584		fi
13585
13586	elif test $ol_with_threads = mach ; then
13587		as_fn_error $? "could not locate Mach CThreads" "$LINENO" 5
13588	fi
13589
13590	if test $ol_link_threads = mach ; then
13591
13592$as_echo "#define HAVE_MACH_CTHREADS 1" >>confdefs.h
13593
13594	elif test $ol_with_threads = found ; then
13595		as_fn_error $? "could not link with Mach CThreads" "$LINENO" 5
13596	fi
13597	;;
13598esac
13599
13600case $ol_with_threads in auto | yes | pth)
13601
13602	for ac_header in pth.h
13603do :
13604  ac_fn_c_check_header_mongrel "$LINENO" "pth.h" "ac_cv_header_pth_h" "$ac_includes_default"
13605if test "x$ac_cv_header_pth_h" = xyes; then :
13606  cat >>confdefs.h <<_ACEOF
13607#define HAVE_PTH_H 1
13608_ACEOF
13609
13610fi
13611
13612done
13613
13614
13615	if test $ac_cv_header_pth_h = yes ; then
13616		{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pth_version in -lpth" >&5
13617$as_echo_n "checking for pth_version in -lpth... " >&6; }
13618if ${ac_cv_lib_pth_pth_version+:} false; then :
13619  $as_echo_n "(cached) " >&6
13620else
13621  ac_check_lib_save_LIBS=$LIBS
13622LIBS="-lpth  $LIBS"
13623cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13624/* end confdefs.h.  */
13625
13626/* Override any GCC internal prototype to avoid an error.
13627   Use char because int might match the return type of a GCC
13628   builtin and then its argument prototype would still apply.  */
13629#ifdef __cplusplus
13630extern "C"
13631#endif
13632char pth_version ();
13633int
13634main ()
13635{
13636return pth_version ();
13637  ;
13638  return 0;
13639}
13640_ACEOF
13641if ac_fn_c_try_link "$LINENO"; then :
13642  ac_cv_lib_pth_pth_version=yes
13643else
13644  ac_cv_lib_pth_pth_version=no
13645fi
13646rm -f core conftest.err conftest.$ac_objext \
13647    conftest$ac_exeext conftest.$ac_ext
13648LIBS=$ac_check_lib_save_LIBS
13649fi
13650{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pth_pth_version" >&5
13651$as_echo "$ac_cv_lib_pth_pth_version" >&6; }
13652if test "x$ac_cv_lib_pth_pth_version" = xyes; then :
13653  have_pth=yes
13654else
13655  have_pth=no
13656fi
13657
13658
13659		if test $have_pth = yes ; then
13660
13661$as_echo "#define HAVE_GNU_PTH 1" >>confdefs.h
13662
13663			LTHREAD_LIBS="$LTHREAD_LIBS -lpth"
13664			ol_link_threads=pth
13665			ol_with_threads=found
13666
13667			if test x$ol_with_yielding_select = xauto ; then
13668				ol_with_yielding_select=yes
13669			fi
13670		fi
13671	fi
13672	;;
13673esac
13674
13675case $ol_with_threads in auto | yes | lwp)
13676
13677		for ac_header in thread.h synch.h
13678do :
13679  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13680ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
13681if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
13682  cat >>confdefs.h <<_ACEOF
13683#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13684_ACEOF
13685
13686fi
13687
13688done
13689
13690	if test $ac_cv_header_thread_h = yes &&
13691	   test $ac_cv_header_synch_h = yes ; then
13692		{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for thr_create in -lthread" >&5
13693$as_echo_n "checking for thr_create in -lthread... " >&6; }
13694if ${ac_cv_lib_thread_thr_create+:} false; then :
13695  $as_echo_n "(cached) " >&6
13696else
13697  ac_check_lib_save_LIBS=$LIBS
13698LIBS="-lthread  $LIBS"
13699cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13700/* end confdefs.h.  */
13701
13702/* Override any GCC internal prototype to avoid an error.
13703   Use char because int might match the return type of a GCC
13704   builtin and then its argument prototype would still apply.  */
13705#ifdef __cplusplus
13706extern "C"
13707#endif
13708char thr_create ();
13709int
13710main ()
13711{
13712return thr_create ();
13713  ;
13714  return 0;
13715}
13716_ACEOF
13717if ac_fn_c_try_link "$LINENO"; then :
13718  ac_cv_lib_thread_thr_create=yes
13719else
13720  ac_cv_lib_thread_thr_create=no
13721fi
13722rm -f core conftest.err conftest.$ac_objext \
13723    conftest$ac_exeext conftest.$ac_ext
13724LIBS=$ac_check_lib_save_LIBS
13725fi
13726{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_thread_thr_create" >&5
13727$as_echo "$ac_cv_lib_thread_thr_create" >&6; }
13728if test "x$ac_cv_lib_thread_thr_create" = xyes; then :
13729  have_thr=yes
13730else
13731  have_thr=no
13732fi
13733
13734
13735		if test $have_thr = yes ; then
13736
13737$as_echo "#define HAVE_THR 1" >>confdefs.h
13738
13739			LTHREAD_LIBS="$LTHREAD_LIBS -lthread"
13740			ol_link_threads=thr
13741
13742			if test x$ol_with_yielding_select = xauto ; then
13743				ol_with_yielding_select=yes
13744			fi
13745
13746						for ac_func in \
13747				thr_setconcurrency \
13748				thr_getconcurrency \
13749
13750do :
13751  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13752ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13753if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
13754  cat >>confdefs.h <<_ACEOF
13755#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13756_ACEOF
13757
13758fi
13759done
13760
13761		fi
13762	fi
13763
13764		for ac_header in lwp/lwp.h
13765do :
13766  ac_fn_c_check_header_mongrel "$LINENO" "lwp/lwp.h" "ac_cv_header_lwp_lwp_h" "$ac_includes_default"
13767if test "x$ac_cv_header_lwp_lwp_h" = xyes; then :
13768  cat >>confdefs.h <<_ACEOF
13769#define HAVE_LWP_LWP_H 1
13770_ACEOF
13771
13772fi
13773
13774done
13775
13776	if test $ac_cv_header_lwp_lwp_h = yes ; then
13777		{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for lwp_create in -llwp" >&5
13778$as_echo_n "checking for lwp_create in -llwp... " >&6; }
13779if ${ac_cv_lib_lwp_lwp_create+:} false; then :
13780  $as_echo_n "(cached) " >&6
13781else
13782  ac_check_lib_save_LIBS=$LIBS
13783LIBS="-llwp  $LIBS"
13784cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13785/* end confdefs.h.  */
13786
13787/* Override any GCC internal prototype to avoid an error.
13788   Use char because int might match the return type of a GCC
13789   builtin and then its argument prototype would still apply.  */
13790#ifdef __cplusplus
13791extern "C"
13792#endif
13793char lwp_create ();
13794int
13795main ()
13796{
13797return lwp_create ();
13798  ;
13799  return 0;
13800}
13801_ACEOF
13802if ac_fn_c_try_link "$LINENO"; then :
13803  ac_cv_lib_lwp_lwp_create=yes
13804else
13805  ac_cv_lib_lwp_lwp_create=no
13806fi
13807rm -f core conftest.err conftest.$ac_objext \
13808    conftest$ac_exeext conftest.$ac_ext
13809LIBS=$ac_check_lib_save_LIBS
13810fi
13811{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lwp_lwp_create" >&5
13812$as_echo "$ac_cv_lib_lwp_lwp_create" >&6; }
13813if test "x$ac_cv_lib_lwp_lwp_create" = xyes; then :
13814  have_lwp=yes
13815else
13816  have_lwp=no
13817fi
13818
13819
13820		if test $have_lwp = yes ; then
13821
13822$as_echo "#define HAVE_LWP 1" >>confdefs.h
13823
13824			LTHREAD_LIBS="$LTHREAD_LIBS -llwp"
13825			ol_link_threads=lwp
13826
13827			if test x$ol_with_yielding_select = xauto ; then
13828				ol_with_yielding_select=no
13829			fi
13830		fi
13831	fi
13832	;;
13833esac
13834
13835if test $ol_with_yielding_select = yes ; then
13836
13837$as_echo "#define HAVE_YIELDING_SELECT 1" >>confdefs.h
13838
13839fi
13840
13841if test $ol_with_threads = manual ; then
13842		ol_link_threads=yes
13843
13844	{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: thread defines and link options must be set manually" >&5
13845$as_echo "$as_me: WARNING: thread defines and link options must be set manually" >&2;}
13846
13847	for ac_header in pthread.h sched.h
13848do :
13849  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13850ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
13851if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
13852  cat >>confdefs.h <<_ACEOF
13853#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13854_ACEOF
13855
13856fi
13857
13858done
13859
13860	for ac_func in sched_yield pthread_yield
13861do :
13862  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13863ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13864if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
13865  cat >>confdefs.h <<_ACEOF
13866#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13867_ACEOF
13868
13869fi
13870done
13871
13872
13873	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LinuxThreads pthread.h" >&5
13874$as_echo_n "checking for LinuxThreads pthread.h... " >&6; }
13875if ${ol_cv_header_linux_threads+:} false; then :
13876  $as_echo_n "(cached) " >&6
13877else
13878  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13879/* end confdefs.h.  */
13880#include <pthread.h>
13881_ACEOF
13882if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13883  $EGREP "pthread_kill_other_threads_np" >/dev/null 2>&1; then :
13884  ol_cv_header_linux_threads=yes
13885else
13886  ol_cv_header_linux_threads=no
13887fi
13888rm -f conftest*
13889
13890
13891fi
13892{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_header_linux_threads" >&5
13893$as_echo "$ol_cv_header_linux_threads" >&6; }
13894	if test $ol_cv_header_linux_threads = yes; then
13895
13896$as_echo "#define HAVE_LINUX_THREADS 1" >>confdefs.h
13897
13898	fi
13899
13900
13901	for ac_header in mach/cthreads.h
13902do :
13903  ac_fn_c_check_header_mongrel "$LINENO" "mach/cthreads.h" "ac_cv_header_mach_cthreads_h" "$ac_includes_default"
13904if test "x$ac_cv_header_mach_cthreads_h" = xyes; then :
13905  cat >>confdefs.h <<_ACEOF
13906#define HAVE_MACH_CTHREADS_H 1
13907_ACEOF
13908
13909fi
13910
13911done
13912
13913	for ac_header in lwp/lwp.h
13914do :
13915  ac_fn_c_check_header_mongrel "$LINENO" "lwp/lwp.h" "ac_cv_header_lwp_lwp_h" "$ac_includes_default"
13916if test "x$ac_cv_header_lwp_lwp_h" = xyes; then :
13917  cat >>confdefs.h <<_ACEOF
13918#define HAVE_LWP_LWP_H 1
13919_ACEOF
13920
13921fi
13922
13923done
13924
13925	for ac_header in thread.h synch.h
13926do :
13927  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13928ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
13929if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
13930  cat >>confdefs.h <<_ACEOF
13931#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13932_ACEOF
13933
13934fi
13935
13936done
13937
13938fi
13939
13940if test $ol_link_threads != no && test $ol_link_threads != nt ; then
13941
13942$as_echo "#define REENTRANT 1" >>confdefs.h
13943
13944
13945$as_echo "#define _REENTRANT 1" >>confdefs.h
13946
13947
13948$as_echo "#define THREAD_SAFE 1" >>confdefs.h
13949
13950
13951$as_echo "#define _THREAD_SAFE 1" >>confdefs.h
13952
13953
13954$as_echo "#define THREADSAFE 1" >>confdefs.h
13955
13956
13957$as_echo "#define _THREADSAFE 1" >>confdefs.h
13958
13959
13960$as_echo "#define _SGI_MP_SOURCE 1" >>confdefs.h
13961
13962
13963			{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for thread specific errno" >&5
13964$as_echo_n "checking for thread specific errno... " >&6; }
13965if ${ol_cv_errno_thread_specific+:} false; then :
13966  $as_echo_n "(cached) " >&6
13967else
13968
13969		cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13970/* end confdefs.h.  */
13971#include <errno.h>
13972int
13973main ()
13974{
13975errno = 0;
13976  ;
13977  return 0;
13978}
13979_ACEOF
13980if ac_fn_c_try_link "$LINENO"; then :
13981  ol_cv_errno_thread_specific=yes
13982else
13983  ol_cv_errno_thread_specific=no
13984fi
13985rm -f core conftest.err conftest.$ac_objext \
13986    conftest$ac_exeext conftest.$ac_ext
13987
13988fi
13989{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_errno_thread_specific" >&5
13990$as_echo "$ol_cv_errno_thread_specific" >&6; }
13991
13992			{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for thread specific h_errno" >&5
13993$as_echo_n "checking for thread specific h_errno... " >&6; }
13994if ${ol_cv_h_errno_thread_specific+:} false; then :
13995  $as_echo_n "(cached) " >&6
13996else
13997
13998		cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13999/* end confdefs.h.  */
14000#include <netdb.h>
14001int
14002main ()
14003{
14004h_errno = 0;
14005  ;
14006  return 0;
14007}
14008_ACEOF
14009if ac_fn_c_try_link "$LINENO"; then :
14010  ol_cv_h_errno_thread_specific=yes
14011else
14012  ol_cv_h_errno_thread_specific=no
14013fi
14014rm -f core conftest.err conftest.$ac_objext \
14015    conftest$ac_exeext conftest.$ac_ext
14016
14017fi
14018{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_h_errno_thread_specific" >&5
14019$as_echo "$ol_cv_h_errno_thread_specific" >&6; }
14020
14021	if test $ol_cv_errno_thread_specific != yes ||
14022	   test $ol_cv_h_errno_thread_specific != yes ; then
14023		LIBS="$LTHREAD_LIBS $LIBS"
14024		LTHREAD_LIBS=""
14025	fi
14026
14027fi
14028
14029if test $ol_link_threads = no ; then
14030	if test $ol_with_threads = yes ; then
14031		as_fn_error $? "no suitable thread support" "$LINENO" 5
14032	fi
14033
14034	if test $ol_with_threads = auto ; then
14035		{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no suitable thread support, disabling threads" >&5
14036$as_echo "$as_me: WARNING: no suitable thread support, disabling threads" >&2;}
14037		ol_with_threads=no
14038	fi
14039
14040
14041$as_echo "#define NO_THREADS 1" >>confdefs.h
14042
14043	LTHREAD_LIBS=""
14044	BUILD_THREAD=no
14045else
14046	BUILD_THREAD=yes
14047fi
14048
14049if test $ol_link_threads != no ; then
14050
14051$as_echo "#define LDAP_API_FEATURE_X_OPENLDAP_THREAD_SAFE 1" >>confdefs.h
14052
14053fi
14054
14055# Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
14056case "$ol_with_threads" in
14057 no)
14058    ol_pthread_ok=no
14059
14060    ;;
14061 *)
14062    ol_found_pthreads=yes
14063    ;;
14064esac
14065
14066ac_ext=c
14067ac_cpp='$CPP $CPPFLAGS'
14068ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
14069ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
14070ac_compiler_gnu=$ac_cv_c_compiler_gnu
14071
14072
14073
14074
14075
14076
14077    case "$ol_found_pthreads" in
14078     yes)
14079	saved_LIBS="$LIBS"
14080	LIBS="$LTHREAD_LIBS $LIBS"
14081	saved_CFLAGS="$CFLAGS"
14082	CFLAGS="$PTHREAD_CFLAGS $CFLAGS"
14083	for ac_func in sem_timedwait
14084do :
14085  ac_fn_c_check_func "$LINENO" "sem_timedwait" "ac_cv_func_sem_timedwait"
14086if test "x$ac_cv_func_sem_timedwait" = xyes; then :
14087  cat >>confdefs.h <<_ACEOF
14088#define HAVE_SEM_TIMEDWAIT 1
14089_ACEOF
14090
14091fi
14092done
14093
14094	LIBS="$saved_LIBS"
14095	{ saved_LIBS=; unset saved_LIBS;}
14096	CFLAGS="$saved_CFLAGS"
14097	{ saved_CFLAGS=; unset saved_CFLAGS;}
14098	case "$ac_cv_func_sem_timedwait" in
14099	 yes)
14100	    PTHREAD_LIBS="$LTHREAD_LIBS"
14101	    have_pthreads=yes
14102	esac
14103    esac
14104esac
14105
14106case "$have_pthreads" in
14107 yes)
14108    CFLAGS_NTP="$CFLAGS_NTP $PTHREAD_CFLAGS"
14109    saved_LIBS="$LIBS"
14110    LIBS="$LTHREAD_LIBS $LIBS"
14111    saved_CFLAGS="$CFLAGS"
14112    CFLAGS="$PTHREAD_CFLAGS $CFLAGS"
14113    # The cast to long int works around a bug in the HP C Compiler
14114# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
14115# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
14116# This bug is HP SR number 8606223364.
14117{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of pthread_t" >&5
14118$as_echo_n "checking size of pthread_t... " >&6; }
14119if ${ac_cv_sizeof_pthread_t+:} false; then :
14120  $as_echo_n "(cached) " >&6
14121else
14122  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (pthread_t))" "ac_cv_sizeof_pthread_t"        "
14123	    $ac_includes_default
14124	    #include <pthread.h>
14125
14126
14127"; then :
14128
14129else
14130  if test "$ac_cv_type_pthread_t" = yes; then
14131     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
14132$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
14133as_fn_error 77 "cannot compute sizeof (pthread_t)
14134See \`config.log' for more details" "$LINENO" 5; }
14135   else
14136     ac_cv_sizeof_pthread_t=0
14137   fi
14138fi
14139
14140fi
14141{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_pthread_t" >&5
14142$as_echo "$ac_cv_sizeof_pthread_t" >&6; }
14143
14144
14145
14146cat >>confdefs.h <<_ACEOF
14147#define SIZEOF_PTHREAD_T $ac_cv_sizeof_pthread_t
14148_ACEOF
14149
14150
14151    LIBISC_PTHREADS_NOTHREADS=pthreads
14152
14153$as_echo "#define ISC_PLATFORM_USETHREADS 1" >>confdefs.h
14154
14155    #
14156    # We'd like to use sigwait() too
14157    #
14158    ac_fn_c_check_func "$LINENO" "sigwait" "ac_cv_func_sigwait"
14159if test "x$ac_cv_func_sigwait" = xyes; then :
14160  have_sigwait=yes
14161else
14162  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigwait in -lc" >&5
14163$as_echo_n "checking for sigwait in -lc... " >&6; }
14164if ${ac_cv_lib_c_sigwait+:} false; then :
14165  $as_echo_n "(cached) " >&6
14166else
14167  ac_check_lib_save_LIBS=$LIBS
14168LIBS="-lc  $LIBS"
14169cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14170/* end confdefs.h.  */
14171
14172/* Override any GCC internal prototype to avoid an error.
14173   Use char because int might match the return type of a GCC
14174   builtin and then its argument prototype would still apply.  */
14175#ifdef __cplusplus
14176extern "C"
14177#endif
14178char sigwait ();
14179int
14180main ()
14181{
14182return sigwait ();
14183  ;
14184  return 0;
14185}
14186_ACEOF
14187if ac_fn_c_try_link "$LINENO"; then :
14188  ac_cv_lib_c_sigwait=yes
14189else
14190  ac_cv_lib_c_sigwait=no
14191fi
14192rm -f core conftest.err conftest.$ac_objext \
14193    conftest$ac_exeext conftest.$ac_ext
14194LIBS=$ac_check_lib_save_LIBS
14195fi
14196{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_sigwait" >&5
14197$as_echo "$ac_cv_lib_c_sigwait" >&6; }
14198if test "x$ac_cv_lib_c_sigwait" = xyes; then :
14199  have_sigwait=yes
14200else
14201  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigwait in -lpthread" >&5
14202$as_echo_n "checking for sigwait in -lpthread... " >&6; }
14203if ${ac_cv_lib_pthread_sigwait+:} false; then :
14204  $as_echo_n "(cached) " >&6
14205else
14206  ac_check_lib_save_LIBS=$LIBS
14207LIBS="-lpthread  $LIBS"
14208cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14209/* end confdefs.h.  */
14210
14211/* Override any GCC internal prototype to avoid an error.
14212   Use char because int might match the return type of a GCC
14213   builtin and then its argument prototype would still apply.  */
14214#ifdef __cplusplus
14215extern "C"
14216#endif
14217char sigwait ();
14218int
14219main ()
14220{
14221return sigwait ();
14222  ;
14223  return 0;
14224}
14225_ACEOF
14226if ac_fn_c_try_link "$LINENO"; then :
14227  ac_cv_lib_pthread_sigwait=yes
14228else
14229  ac_cv_lib_pthread_sigwait=no
14230fi
14231rm -f core conftest.err conftest.$ac_objext \
14232    conftest$ac_exeext conftest.$ac_ext
14233LIBS=$ac_check_lib_save_LIBS
14234fi
14235{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_sigwait" >&5
14236$as_echo "$ac_cv_lib_pthread_sigwait" >&6; }
14237if test "x$ac_cv_lib_pthread_sigwait" = xyes; then :
14238  have_sigwait=yes
14239else
14240  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _Psigwait in -lpthread" >&5
14241$as_echo_n "checking for _Psigwait in -lpthread... " >&6; }
14242if ${ac_cv_lib_pthread__Psigwait+:} false; then :
14243  $as_echo_n "(cached) " >&6
14244else
14245  ac_check_lib_save_LIBS=$LIBS
14246LIBS="-lpthread  $LIBS"
14247cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14248/* end confdefs.h.  */
14249
14250/* Override any GCC internal prototype to avoid an error.
14251   Use char because int might match the return type of a GCC
14252   builtin and then its argument prototype would still apply.  */
14253#ifdef __cplusplus
14254extern "C"
14255#endif
14256char _Psigwait ();
14257int
14258main ()
14259{
14260return _Psigwait ();
14261  ;
14262  return 0;
14263}
14264_ACEOF
14265if ac_fn_c_try_link "$LINENO"; then :
14266  ac_cv_lib_pthread__Psigwait=yes
14267else
14268  ac_cv_lib_pthread__Psigwait=no
14269fi
14270rm -f core conftest.err conftest.$ac_objext \
14271    conftest$ac_exeext conftest.$ac_ext
14272LIBS=$ac_check_lib_save_LIBS
14273fi
14274{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread__Psigwait" >&5
14275$as_echo "$ac_cv_lib_pthread__Psigwait" >&6; }
14276if test "x$ac_cv_lib_pthread__Psigwait" = xyes; then :
14277  have_sigwait=yes
14278else
14279  have_sigwait=no
14280
14281fi
14282
14283
14284fi
14285
14286
14287fi
14288
14289
14290fi
14291
14292    case "$host:$have_sigwait" in
14293     *-freebsd*:no)
14294	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigwait in -lc_r" >&5
14295$as_echo_n "checking for sigwait in -lc_r... " >&6; }
14296if ${ac_cv_lib_c_r_sigwait+:} false; then :
14297  $as_echo_n "(cached) " >&6
14298else
14299  ac_check_lib_save_LIBS=$LIBS
14300LIBS="-lc_r  $LIBS"
14301cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14302/* end confdefs.h.  */
14303
14304/* Override any GCC internal prototype to avoid an error.
14305   Use char because int might match the return type of a GCC
14306   builtin and then its argument prototype would still apply.  */
14307#ifdef __cplusplus
14308extern "C"
14309#endif
14310char sigwait ();
14311int
14312main ()
14313{
14314return sigwait ();
14315  ;
14316  return 0;
14317}
14318_ACEOF
14319if ac_fn_c_try_link "$LINENO"; then :
14320  ac_cv_lib_c_r_sigwait=yes
14321else
14322  ac_cv_lib_c_r_sigwait=no
14323fi
14324rm -f core conftest.err conftest.$ac_objext \
14325    conftest$ac_exeext conftest.$ac_ext
14326LIBS=$ac_check_lib_save_LIBS
14327fi
14328{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_r_sigwait" >&5
14329$as_echo "$ac_cv_lib_c_r_sigwait" >&6; }
14330if test "x$ac_cv_lib_c_r_sigwait" = xyes; then :
14331  have_sigwait=yes
14332
14333fi
14334
14335    esac
14336    case "$have_sigwait" in
14337     yes)
14338	ac_cv_func_sigwait=yes
14339
14340$as_echo "#define HAVE_SIGWAIT 1" >>confdefs.h
14341
14342    esac
14343
14344    for ac_func in pthread_attr_getstacksize
14345do :
14346  ac_fn_c_check_func "$LINENO" "pthread_attr_getstacksize" "ac_cv_func_pthread_attr_getstacksize"
14347if test "x$ac_cv_func_pthread_attr_getstacksize" = xyes; then :
14348  cat >>confdefs.h <<_ACEOF
14349#define HAVE_PTHREAD_ATTR_GETSTACKSIZE 1
14350_ACEOF
14351
14352fi
14353done
14354
14355    for ac_func in pthread_attr_setstacksize sysconf
14356do :
14357  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14358ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14359if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
14360  cat >>confdefs.h <<_ACEOF
14361#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14362_ACEOF
14363
14364fi
14365done
14366
14367
14368    case "$host" in
14369     *-freebsd5.[012]|*-freebsd5.[012].*)
14370	;;
14371     *-freebsd5.[3456789]|*-freebsd5.[3456789].*|*-freebsd6.*)
14372
14373$as_echo "#define NEED_PTHREAD_SCOPE_SYSTEM 1" >>confdefs.h
14374
14375	;;
14376     *-bsdi3.*|*-bsdi4.0*)
14377
14378$as_echo "#define NEED_PTHREAD_INIT 1" >>confdefs.h
14379
14380	;;
14381     *-linux*)
14382
14383$as_echo "#define HAVE_LINUXTHREADS 1" >>confdefs.h
14384
14385	;;
14386     *-solaris*)
14387	$as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
14388
14389	for ac_func in pthread_setconcurrency
14390do :
14391  ac_fn_c_check_func "$LINENO" "pthread_setconcurrency" "ac_cv_func_pthread_setconcurrency"
14392if test "x$ac_cv_func_pthread_setconcurrency" = xyes; then :
14393  cat >>confdefs.h <<_ACEOF
14394#define HAVE_PTHREAD_SETCONCURRENCY 1
14395_ACEOF
14396
14397fi
14398done
14399
14400	case "$ac_cv_func_pthread_setconcurrency" in
14401	 yes)
14402
14403$as_echo "#define CALL_PTHREAD_SETCONCURRENCY 1" >>confdefs.h
14404
14405	esac
14406	;;
14407     *-sco-sysv*uw*|*-*-sysv*UnixWare*|*-*-sysv*OpenUNIX*)
14408
14409$as_echo "#define HAVE_UNIXWARE_SIGWAIT 1" >>confdefs.h
14410
14411	;;
14412    esac
14413    hack_shutup_pthreadonceinit=no
14414    case "$host" in
14415     *-aix5.[123].*)
14416	hack_shutup_pthreadonceinit=yes
14417	;;
14418     *-solaris2.[89])
14419	hack_shutup_pthreadonceinit=yes
14420	;;
14421     *-solaris2.1[0-9])
14422	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if extra braces are needed for PTHREAD_ONCE_INIT" >&5
14423$as_echo_n "checking if extra braces are needed for PTHREAD_ONCE_INIT... " >&6; }
14424if ${ntp_cv_braces_around_pthread_once_init+:} false; then :
14425  $as_echo_n "(cached) " >&6
14426else
14427  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14428/* end confdefs.h.  */
14429
14430			#include <pthread.h>
14431
14432int
14433main ()
14434{
14435
14436		        static pthread_once_t once_test =
14437						PTHREAD_ONCE_INIT;
14438
14439
14440  ;
14441  return 0;
14442}
14443_ACEOF
14444if ac_fn_c_try_compile "$LINENO"; then :
14445  ntp_cv_braces_around_pthread_once_init=no
14446else
14447  ntp_cv_braces_around_pthread_once_init=yes
14448
14449fi
14450rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14451
14452fi
14453{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_braces_around_pthread_once_init" >&5
14454$as_echo "$ntp_cv_braces_around_pthread_once_init" >&6; }
14455	case "$ntp_cv_braces_around_pthread_once_init" in
14456	 yes)
14457	    hack_shutup_pthreadonceinit=yes
14458	esac
14459	;;
14460    esac
14461    case "$hack_shutup_pthreadonceinit" in
14462     yes)
14463
14464$as_echo "#define ISC_PLATFORM_BRACEPTHREADONCEINIT 1" >>confdefs.h
14465
14466    esac
14467    LIBS="$saved_LIBS"
14468    { saved_LIBS=; unset saved_LIBS;}
14469    CFLAGS="$saved_CFLAGS"
14470    { saved_CFLAGS=; unset saved_CFLAGS;}
14471    ;;
14472 *)
14473    LIBISC_PTHREADS_NOTHREADS=nothreads
14474    ;;
14475esac
14476
14477 if test "$have_pthreads" != "no"; then
14478  PTHREADS_TRUE=
14479  PTHREADS_FALSE='#'
14480else
14481  PTHREADS_TRUE='#'
14482  PTHREADS_FALSE=
14483fi
14484
14485
14486
14487
14488
14489
14490
14491case "$hw_use_rpl_vsnprintf:$hw_cv_func_vsnprintf" in
14492 no:yes)
14493    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if vsnprintf expands \"%m\" to strerror(errno)" >&5
14494$as_echo_n "checking if vsnprintf expands \"%m\" to strerror(errno)... " >&6; }
14495if ${ntp_cv_vsnprintf_percent_m+:} false; then :
14496  $as_echo_n "(cached) " >&6
14497else
14498  if test "$cross_compiling" = yes; then :
14499  ntp_cv_vsnprintf_percent_m=no
14500
14501else
14502  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14503/* end confdefs.h.  */
14504
14505		    #include <stdarg.h>
14506		    #include <errno.h>
14507		    #include <stdio.h>
14508		    #include <string.h>
14509
14510		    int call_vsnprintf(
14511			    char *	dst,
14512			    size_t	sz,
14513			    const char *fmt,
14514			    ...
14515			    );
14516
14517		    int call_vsnprintf(
14518			    char *	dst,
14519			    size_t	sz,
14520			    const char *fmt,
14521			    ...
14522			    )
14523		    {
14524			    va_list	ap;
14525			    int		rc;
14526
14527			    va_start(ap, fmt);
14528			    rc = vsnprintf(dst, sz, fmt, ap);
14529			    va_end(ap);
14530
14531			    return rc;
14532		    }
14533
14534int
14535main ()
14536{
14537
14538		    char	sbuf[512];
14539		    char	pbuf[512];
14540		    int		slen;
14541
14542		    strcpy(sbuf, strerror(ENOENT));
14543		    errno = ENOENT;
14544		    slen = call_vsnprintf(pbuf, sizeof(pbuf), "%m",
14545					  "wrong");
14546		    return strcmp(sbuf, pbuf);
14547
14548
14549  ;
14550  return 0;
14551}
14552_ACEOF
14553if ac_fn_c_try_run "$LINENO"; then :
14554  ntp_cv_vsnprintf_percent_m=yes
14555else
14556  ntp_cv_vsnprintf_percent_m=no
14557fi
14558rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14559  conftest.$ac_objext conftest.beam conftest.$ac_ext
14560fi
14561
14562
14563fi
14564{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_vsnprintf_percent_m" >&5
14565$as_echo "$ntp_cv_vsnprintf_percent_m" >&6; }
14566    case "$ntp_cv_vsnprintf_percent_m" in
14567     yes)
14568
14569$as_echo "#define VSNPRINTF_PERCENT_M 1" >>confdefs.h
14570
14571    esac
14572esac
14573
14574for ac_header in sys/clockctl.h
14575do :
14576  ac_fn_c_check_header_mongrel "$LINENO" "sys/clockctl.h" "ac_cv_header_sys_clockctl_h" "$ac_includes_default"
14577if test "x$ac_cv_header_sys_clockctl_h" = xyes; then :
14578  cat >>confdefs.h <<_ACEOF
14579#define HAVE_SYS_CLOCKCTL_H 1
14580_ACEOF
14581
14582fi
14583
14584done
14585
14586
14587# Check whether --enable-clockctl was given.
14588if test "${enable_clockctl+set}" = set; then :
14589  enableval=$enable_clockctl; ntp_use_dev_clockctl=$enableval
14590else
14591  ntp_use_dev_clockctl=$ac_cv_header_sys_clockctl_h
14592
14593fi
14594
14595
14596{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should use /dev/clockctl" >&5
14597$as_echo_n "checking if we should use /dev/clockctl... " >&6; }
14598{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_use_dev_clockctl" >&5
14599$as_echo "$ntp_use_dev_clockctl" >&6; }
14600
14601
14602for ac_header in sys/capability.h sys/prctl.h
14603do :
14604  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
14605ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
14606if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
14607  cat >>confdefs.h <<_ACEOF
14608#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
14609_ACEOF
14610
14611fi
14612
14613done
14614
14615
14616{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we have linux capabilities (libcap)" >&5
14617$as_echo_n "checking if we have linux capabilities (libcap)... " >&6; }
14618
14619case "$ac_cv_header_sys_capability_h$ac_cv_header_sys_prctl_h" in
14620 yesyes)
14621    case "$host" in
14622     mips-sgi-irix*)
14623	ntp_have_linuxcaps=no
14624	;;
14625     *) ntp_have_linuxcaps=yes
14626	;;
14627    esac
14628    ;;
14629 *)
14630    ntp_have_linuxcaps=no
14631    ;;
14632esac
14633
14634# Check whether --enable-linuxcaps was given.
14635if test "${enable_linuxcaps+set}" = set; then :
14636  enableval=$enable_linuxcaps; ntp_have_linuxcaps=$enableval
14637
14638fi
14639
14640
14641{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_have_linuxcaps" >&5
14642$as_echo "$ntp_have_linuxcaps" >&6; }
14643
14644case "$ntp_have_linuxcaps" in
14645 yes)
14646
14647$as_echo "#define HAVE_LINUX_CAPABILITIES 1" >>confdefs.h
14648
14649    LIBS="$LIBS -lcap"
14650    ;;
14651esac
14652
14653
14654for ac_header in priv.h
14655do :
14656  ac_fn_c_check_header_mongrel "$LINENO" "priv.h" "ac_cv_header_priv_h" "$ac_includes_default"
14657if test "x$ac_cv_header_priv_h" = xyes; then :
14658  cat >>confdefs.h <<_ACEOF
14659#define HAVE_PRIV_H 1
14660_ACEOF
14661
14662fi
14663
14664done
14665
14666case "$ac_cv_header_priv_h" in
14667 yes)
14668    case "$host" in
14669     *-solaris*)
14670	ac_fn_c_check_func "$LINENO" "setppriv" "ac_cv_func_setppriv"
14671if test "x$ac_cv_func_setppriv" = xyes; then :
14672  ntp_have_solarisprivs=yes
14673else
14674  ntp_have_solarisprivs=no
14675
14676fi
14677
14678	;;
14679    esac
14680esac
14681
14682# Check whether --enable-solarisprivs was given.
14683if test "${enable_solarisprivs+set}" = set; then :
14684  enableval=$enable_solarisprivs; ntp_have_solarisprivs=$enableval
14685
14686fi
14687
14688
14689{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we have solaris privileges" >&5
14690$as_echo_n "checking if we have solaris privileges... " >&6; }
14691
14692case "$ntp_have_solarisprivs" in
14693 yes)
14694
14695$as_echo "#define HAVE_SOLARIS_PRIVS 1" >>confdefs.h
14696
14697esac
14698
14699{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_have_solarisprivs" >&5
14700$as_echo "$ntp_have_solarisprivs" >&6; }
14701
14702case "$ntp_use_dev_clockctl$ntp_have_linuxcaps$ntp_have_solarisprivs" in
14703 *yes*)
14704
14705$as_echo "#define HAVE_DROPROOT 1" >>confdefs.h
14706
14707esac
14708
14709case "$host" in
14710 *-*-darwin*)
14711    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing res_9_init" >&5
14712$as_echo_n "checking for library containing res_9_init... " >&6; }
14713if ${ac_cv_search_res_9_init+:} false; then :
14714  $as_echo_n "(cached) " >&6
14715else
14716  ac_func_search_save_LIBS=$LIBS
14717cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14718/* end confdefs.h.  */
14719
14720/* Override any GCC internal prototype to avoid an error.
14721   Use char because int might match the return type of a GCC
14722   builtin and then its argument prototype would still apply.  */
14723#ifdef __cplusplus
14724extern "C"
14725#endif
14726char res_9_init ();
14727int
14728main ()
14729{
14730return res_9_init ();
14731  ;
14732  return 0;
14733}
14734_ACEOF
14735for ac_lib in '' resolv; do
14736  if test -z "$ac_lib"; then
14737    ac_res="none required"
14738  else
14739    ac_res=-l$ac_lib
14740    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
14741  fi
14742  if ac_fn_c_try_link "$LINENO"; then :
14743  ac_cv_search_res_9_init=$ac_res
14744fi
14745rm -f core conftest.err conftest.$ac_objext \
14746    conftest$ac_exeext
14747  if ${ac_cv_search_res_9_init+:} false; then :
14748  break
14749fi
14750done
14751if ${ac_cv_search_res_9_init+:} false; then :
14752
14753else
14754  ac_cv_search_res_9_init=no
14755fi
14756rm conftest.$ac_ext
14757LIBS=$ac_func_search_save_LIBS
14758fi
14759{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_res_9_init" >&5
14760$as_echo "$ac_cv_search_res_9_init" >&6; }
14761ac_res=$ac_cv_search_res_9_init
14762if test "$ac_res" != no; then :
14763  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
14764
14765fi
14766
14767    ;;
14768 *) { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing res_init" >&5
14769$as_echo_n "checking for library containing res_init... " >&6; }
14770if ${ac_cv_search_res_init+:} false; then :
14771  $as_echo_n "(cached) " >&6
14772else
14773  ac_func_search_save_LIBS=$LIBS
14774cat 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
14781extern "C"
14782#endif
14783char res_init ();
14784int
14785main ()
14786{
14787return res_init ();
14788  ;
14789  return 0;
14790}
14791_ACEOF
14792for ac_lib in '' resolv; do
14793  if test -z "$ac_lib"; then
14794    ac_res="none required"
14795  else
14796    ac_res=-l$ac_lib
14797    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
14798  fi
14799  if ac_fn_c_try_link "$LINENO"; then :
14800  ac_cv_search_res_init=$ac_res
14801fi
14802rm -f core conftest.err conftest.$ac_objext \
14803    conftest$ac_exeext
14804  if ${ac_cv_search_res_init+:} false; then :
14805  break
14806fi
14807done
14808if ${ac_cv_search_res_init+:} false; then :
14809
14810else
14811  ac_cv_search_res_init=no
14812fi
14813rm conftest.$ac_ext
14814LIBS=$ac_func_search_save_LIBS
14815fi
14816{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_res_init" >&5
14817$as_echo "$ac_cv_search_res_init" >&6; }
14818ac_res=$ac_cv_search_res_init
14819if test "$ac_res" != no; then :
14820  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
14821
14822fi
14823
14824    ;;
14825esac
14826for ac_header in sys/types.h netinet/in.h arpa/nameser.h netdb.h resolv.h
14827do :
14828  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
14829ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "#ifdef HAVE_SYS_TYPES_H
14830#  include <sys/types.h>
14831#endif
14832#ifdef HAVE_NETINET_IN_H
14833#  include <netinet/in.h>   /* inet_ functions / structs */
14834#endif
14835#ifdef HAVE_ARPA_NAMESER_H
14836#  include <arpa/nameser.h> /* DNS HEADER struct */
14837#endif
14838#ifdef HAVE_NETDB_H
14839#  include <netdb.h>
14840#endif
14841"
14842if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
14843  cat >>confdefs.h <<_ACEOF
14844#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
14845_ACEOF
14846
14847fi
14848
14849done
14850
14851
14852#HMS: Why do we do this check so "early"?
14853for ac_func in res_init
14854do :
14855  ac_fn_c_check_func "$LINENO" "res_init" "ac_cv_func_res_init"
14856if test "x$ac_cv_func_res_init" = xyes; then :
14857  cat >>confdefs.h <<_ACEOF
14858#define HAVE_RES_INIT 1
14859_ACEOF
14860
14861else
14862  for ac_func in __res_init
14863do :
14864  ac_fn_c_check_func "$LINENO" "__res_init" "ac_cv_func___res_init"
14865if test "x$ac_cv_func___res_init" = xyes; then :
14866  cat >>confdefs.h <<_ACEOF
14867#define HAVE___RES_INIT 1
14868_ACEOF
14869
14870fi
14871done
14872
14873fi
14874done
14875
14876
14877# We also need -lsocket, but we have tested for that already.
14878ac_fn_c_check_func "$LINENO" "inet_ntop" "ac_cv_func_inet_ntop"
14879if test "x$ac_cv_func_inet_ntop" = xyes; then :
14880
14881else
14882
14883$as_echo "#define ISC_PLATFORM_NEEDNTOP 1" >>confdefs.h
14884
14885fi
14886
14887ac_fn_c_check_func "$LINENO" "inet_pton" "ac_cv_func_inet_pton"
14888if test "x$ac_cv_func_inet_pton" = xyes; then :
14889
14890else
14891
14892$as_echo "#define ISC_PLATFORM_NEEDPTON 1" >>confdefs.h
14893
14894fi
14895
14896
14897ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default"
14898if test "x$ac_cv_type_uintptr_t" = xyes; then :
14899
14900cat >>confdefs.h <<_ACEOF
14901#define HAVE_UINTPTR_T 1
14902_ACEOF
14903
14904
14905fi
14906ac_fn_c_check_type "$LINENO" "int32" "ac_cv_type_int32" "$ac_includes_default"
14907if test "x$ac_cv_type_int32" = xyes; then :
14908
14909cat >>confdefs.h <<_ACEOF
14910#define HAVE_INT32 1
14911_ACEOF
14912
14913
14914fi
14915ac_fn_c_check_type "$LINENO" "u_int32" "ac_cv_type_u_int32" "$ac_includes_default"
14916if test "x$ac_cv_type_u_int32" = xyes; then :
14917
14918cat >>confdefs.h <<_ACEOF
14919#define HAVE_U_INT32 1
14920_ACEOF
14921
14922
14923fi
14924
14925
14926
14927
14928case "$ac_cv_type_int32::$ac_cv_header_resolv_h" in
14929 no::yes)
14930    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for int32 with DNS headers included" >&5
14931$as_echo_n "checking for int32 with DNS headers included... " >&6; }
14932if ${ntp_cv_type_int32_with_dns+:} false; then :
14933  $as_echo_n "(cached) " >&6
14934else
14935  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14936/* end confdefs.h.  */
14937
14938		    #ifdef HAVE_ARPA_NAMESER_H
14939		    # include <arpa/nameser.h>
14940		    #endif
14941		    #include <resolv.h>
14942
14943int
14944main ()
14945{
14946
14947		    size_t cb = sizeof(int32);
14948
14949
14950  ;
14951  return 0;
14952}
14953_ACEOF
14954if ac_fn_c_try_compile "$LINENO"; then :
14955  ntp_cv_type_int32_with_dns=yes
14956else
14957  ntp_cv_type_int32_with_dns=no
14958
14959fi
14960rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14961
14962fi
14963{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_type_int32_with_dns" >&5
14964$as_echo "$ntp_cv_type_int32_with_dns" >&6; }
14965    case "$ntp_cv_type_int32_with_dns" in
14966     yes)
14967
14968$as_echo "#define HAVE_INT32_ONLY_WITH_DNS 1" >>confdefs.h
14969
14970    esac
14971esac
14972
14973case "$ac_cv_type_u_int32::$ac_cv_header_resolv_h" in
14974 no::yes)
14975    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for u_int32 with DNS headers included" >&5
14976$as_echo_n "checking for u_int32 with DNS headers included... " >&6; }
14977if ${ntp_cv_type_u_int32_with_dns+:} false; then :
14978  $as_echo_n "(cached) " >&6
14979else
14980  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14981/* end confdefs.h.  */
14982
14983		    #ifdef HAVE_ARPA_NAMESER_H
14984		    # include <arpa/nameser.h>
14985		    #endif
14986		    #include <resolv.h>
14987
14988int
14989main ()
14990{
14991
14992		    size_t cb = sizeof(u_int32);
14993
14994
14995  ;
14996  return 0;
14997}
14998_ACEOF
14999if ac_fn_c_try_compile "$LINENO"; then :
15000  ntp_cv_type_u_int32_with_dns=yes
15001else
15002  ntp_cv_type_u_int32_with_dns=no
15003
15004fi
15005rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15006
15007fi
15008{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_type_u_int32_with_dns" >&5
15009$as_echo "$ntp_cv_type_u_int32_with_dns" >&6; }
15010    case "$ntp_cv_type_u_int32_with_dns" in
15011     yes)
15012
15013$as_echo "#define HAVE_U_INT32_ONLY_WITH_DNS 1" >>confdefs.h
15014
15015    esac
15016esac
15017
15018for ac_header in sys/timepps.h
15019do :
15020  ac_fn_c_check_header_compile "$LINENO" "sys/timepps.h" "ac_cv_header_sys_timepps_h" "
15021	#ifdef HAVE_SYS_TIME_H
15022	# include <sys/time.h>
15023	#endif
15024	#ifdef HAVE_ERRNO_H
15025	# include <errno.h>
15026	#endif
15027
15028
15029"
15030if test "x$ac_cv_header_sys_timepps_h" = xyes; then :
15031  cat >>confdefs.h <<_ACEOF
15032#define HAVE_SYS_TIMEPPS_H 1
15033_ACEOF
15034
15035fi
15036
15037done
15038
15039
15040{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec" >&5
15041$as_echo_n "checking for struct timespec... " >&6; }
15042if ${ntp_cv_struct_timespec+:} false; then :
15043  $as_echo_n "(cached) " >&6
15044else
15045  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15046/* end confdefs.h.  */
15047
15048		#include <sys/time.h>
15049		/* Under SunOS, timespec is in sys/timepps.h,
15050		   which needs errno.h and FRAC */
15051		#ifdef HAVE_ERRNO_H
15052		# include <errno.h>
15053		#endif
15054		#ifdef HAVE_SYS_TIMEPPS_H
15055		# define FRAC 4294967296
15056		# include <sys/timepps.h>
15057		#endif
15058
15059int
15060main ()
15061{
15062
15063		struct timespec n;
15064
15065
15066  ;
15067  return 0;
15068}
15069_ACEOF
15070if ac_fn_c_try_compile "$LINENO"; then :
15071  ntp_cv_struct_timespec=yes
15072else
15073  ntp_cv_struct_timespec=no
15074
15075fi
15076rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15077
15078fi
15079{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_struct_timespec" >&5
15080$as_echo "$ntp_cv_struct_timespec" >&6; }
15081case "$ntp_cv_struct_timespec" in
15082 yes)
15083
15084$as_echo "#define HAVE_STRUCT_TIMESPEC 1" >>confdefs.h
15085
15086esac
15087
15088{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct ntptimeval" >&5
15089$as_echo_n "checking for struct ntptimeval... " >&6; }
15090if ${ntp_cv_struct_ntptimeval+:} false; then :
15091  $as_echo_n "(cached) " >&6
15092else
15093  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15094/* end confdefs.h.  */
15095
15096		#include <sys/time.h>
15097		#include <sys/timex.h>
15098
15099int
15100main ()
15101{
15102
15103		struct ntptimeval n;
15104
15105
15106  ;
15107  return 0;
15108}
15109_ACEOF
15110if ac_fn_c_try_compile "$LINENO"; then :
15111  ntp_cv_struct_ntptimeval=yes
15112else
15113  ntp_cv_struct_ntptimeval=no
15114
15115fi
15116rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15117
15118fi
15119{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_struct_ntptimeval" >&5
15120$as_echo "$ntp_cv_struct_ntptimeval" >&6; }
15121case "$ntp_cv_struct_ntptimeval" in
15122 yes)
15123
15124$as_echo "#define HAVE_STRUCT_NTPTIMEVAL 1" >>confdefs.h
15125
15126esac
15127
15128for ac_header in md5.h
15129do :
15130  ac_fn_c_check_header_compile "$LINENO" "md5.h" "ac_cv_header_md5_h" "
15131	#ifdef HAVE_SYS_TYPES_H
15132	# include <sys/types.h>
15133	#endif
15134
15135
15136"
15137if test "x$ac_cv_header_md5_h" = xyes; then :
15138  cat >>confdefs.h <<_ACEOF
15139#define HAVE_MD5_H 1
15140_ACEOF
15141
15142fi
15143
15144done
15145
15146
15147{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing MD5Init" >&5
15148$as_echo_n "checking for library containing MD5Init... " >&6; }
15149if ${ac_cv_search_MD5Init+:} false; then :
15150  $as_echo_n "(cached) " >&6
15151else
15152  ac_func_search_save_LIBS=$LIBS
15153cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15154/* end confdefs.h.  */
15155
15156/* Override any GCC internal prototype to avoid an error.
15157   Use char because int might match the return type of a GCC
15158   builtin and then its argument prototype would still apply.  */
15159#ifdef __cplusplus
15160extern "C"
15161#endif
15162char MD5Init ();
15163int
15164main ()
15165{
15166return MD5Init ();
15167  ;
15168  return 0;
15169}
15170_ACEOF
15171for ac_lib in '' md5 md; do
15172  if test -z "$ac_lib"; then
15173    ac_res="none required"
15174  else
15175    ac_res=-l$ac_lib
15176    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
15177  fi
15178  if ac_fn_c_try_link "$LINENO"; then :
15179  ac_cv_search_MD5Init=$ac_res
15180fi
15181rm -f core conftest.err conftest.$ac_objext \
15182    conftest$ac_exeext
15183  if ${ac_cv_search_MD5Init+:} false; then :
15184  break
15185fi
15186done
15187if ${ac_cv_search_MD5Init+:} false; then :
15188
15189else
15190  ac_cv_search_MD5Init=no
15191fi
15192rm conftest.$ac_ext
15193LIBS=$ac_func_search_save_LIBS
15194fi
15195{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_MD5Init" >&5
15196$as_echo "$ac_cv_search_MD5Init" >&6; }
15197ac_res=$ac_cv_search_MD5Init
15198if test "$ac_res" != no; then :
15199  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
15200
15201fi
15202
15203for ac_func in MD5Init sysconf getdtablesize sigaction sigset sigvec
15204do :
15205  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15206ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15207if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
15208  cat >>confdefs.h <<_ACEOF
15209#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15210_ACEOF
15211
15212fi
15213done
15214
15215
15216{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for SIGIO" >&5
15217$as_echo_n "checking for SIGIO... " >&6; }
15218if ${ntp_cv_hdr_def_sigio+:} false; then :
15219  $as_echo_n "(cached) " >&6
15220else
15221  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15222/* end confdefs.h.  */
15223
15224	    #include <signal.h>
15225
15226	    #ifndef SIGIO
15227	    # error
15228	    #endif
15229
15230_ACEOF
15231if ac_fn_c_try_cpp "$LINENO"; then :
15232  ntp_cv_hdr_def_sigio=yes
15233else
15234  ntp_cv_hdr_def_sigio=no
15235
15236fi
15237rm -f conftest.err conftest.i conftest.$ac_ext
15238
15239fi
15240{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_hdr_def_sigio" >&5
15241$as_echo "$ntp_cv_hdr_def_sigio" >&6; }
15242
15243{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want to use SIGIO" >&5
15244$as_echo_n "checking if we want to use SIGIO... " >&6; }
15245ans=no
15246case "$ntp_cv_hdr_def_sigio" in
15247 yes)
15248    ans=yes
15249    case "$host" in
15250     alpha*-dec-osf4*|alpha*-dec-osf5*)
15251	ans=no
15252	;;
15253     *-convex-*)
15254	ans=no
15255	;;
15256     *-dec-*)
15257	ans=no
15258	;;
15259     *-pc-cygwin*)
15260	ans=no
15261	;;
15262     *-sni-sysv*)
15263	ans=no
15264	;;
15265     *-stratus-vos)
15266	ans=no
15267	;;
15268     *-univel-sysv*)
15269	ans=no
15270	;;
15271     *-*-irix6*)
15272	ans=no
15273	;;
15274     *-*-freebsd*)
15275	ans=no
15276	;;
15277     *-*-*linux*)
15278	ans=no
15279	;;
15280     *-*-unicosmp*)
15281	ans=no
15282	;;
15283     *-*-kfreebsd*)
15284	ans=no
15285	;;
15286     m68k-*-mint*)
15287	ans=no
15288	;;
15289    esac
15290    ;;
15291esac
15292case "$ans" in
15293 yes)
15294
15295$as_echo "#define HAVE_SIGNALED_IO 1" >>confdefs.h
15296
15297esac
15298{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
15299$as_echo "$ans" >&6; }
15300
15301{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for SIGPOLL" >&5
15302$as_echo_n "checking for SIGPOLL... " >&6; }
15303if ${ntp_cv_hdr_def_sigpoll+:} false; then :
15304  $as_echo_n "(cached) " >&6
15305else
15306  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15307/* end confdefs.h.  */
15308
15309	    #include <signal.h>
15310
15311	    #ifndef SIGPOLL
15312	    # error
15313	    #endif
15314
15315_ACEOF
15316if ac_fn_c_try_cpp "$LINENO"; then :
15317  ntp_cv_hdr_def_sigpoll=yes
15318else
15319  ntp_cv_hdr_def_sigpoll=no
15320
15321fi
15322rm -f conftest.err conftest.i conftest.$ac_ext
15323
15324fi
15325{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_hdr_def_sigpoll" >&5
15326$as_echo "$ntp_cv_hdr_def_sigpoll" >&6; }
15327
15328{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can use SIGPOLL for UDP I/O" >&5
15329$as_echo_n "checking if we can use SIGPOLL for UDP I/O... " >&6; }
15330ans=no
15331case "$ntp_cv_hdr_def_sigpoll" in
15332 yes)
15333    case "$host" in
15334     mips-sgi-irix*)
15335	ans=no
15336	;;
15337     vax-dec-bsd)
15338	ans=no
15339	;;
15340     *-pc-cygwin*)
15341	ans=no
15342	;;
15343     *-sni-sysv*)
15344	ans=no
15345	;;
15346     *-stratus-vos)
15347	ans=no
15348	;;
15349     *-*-aix[4-9]*)
15350	# XXX Only verified thru AIX6
15351	ans=no
15352	;;
15353     *-*-hpux*)
15354	ans=no
15355	;;
15356     *-*-*linux*)
15357	ans=no
15358	;;
15359     *-*-osf*)
15360	ans=no
15361	;;
15362     *-*-qnx*)
15363	ans=no
15364	;;
15365     *-*-sunos*)
15366	ans=no
15367	;;
15368     *-*-solaris*)
15369	ans=no
15370	;;
15371     *-*-ultrix*)
15372	ans=no
15373	;;
15374     *-*-unicosmp*)
15375	ans=no
15376	;;
15377     *-*-kfreebsd*)
15378	ans=no
15379	;;
15380     *) ans=yes
15381	;;
15382    esac
15383    ;;
15384esac
15385case "$ans" in
15386 yes)
15387
15388$as_echo "#define USE_UDP_SIGPOLL 1" >>confdefs.h
15389
15390esac
15391{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
15392$as_echo "$ans" >&6; }
15393
15394{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can use SIGPOLL for TTY I/O" >&5
15395$as_echo_n "checking if we can use SIGPOLL for TTY I/O... " >&6; }
15396ans=no
15397case "$ntp_cv_hdr_def_sigpoll" in
15398 yes)
15399    case "$host" in
15400     mips-sgi-irix*)
15401	ans=no
15402	;;
15403     vax-dec-bsd)
15404	ans=no
15405	;;
15406     *-pc-cygwin*)
15407	ans=no
15408	;;
15409     *-sni-sysv*)
15410	ans=no
15411	;;
15412     *-stratus-vos)
15413	ans=no
15414	;;
15415     *-*-aix[4-9]*)
15416	# XXX Only verified thru AIX6
15417	ans=no
15418	;;
15419     *-*-hpux*)
15420	ans=no
15421	;;
15422     *-*-*linux*)
15423	ans=no
15424	;;
15425     *-*-osf*)
15426	ans=no
15427	;;
15428     *-*-sunos*)
15429	ans=no
15430	;;
15431     *-*-ultrix*)
15432	ans=no
15433	;;
15434     *-*-qnx*)
15435	ans=no
15436	;;
15437     *-*-unicosmp*)
15438	ans=no
15439	;;
15440     *-*-kfreebsd*)
15441	ans=no
15442	;;
15443     *) ans=yes
15444	;;
15445    esac
15446    ;;
15447esac
15448case "$ans" in
15449 yes)
15450
15451$as_echo "#define USE_TTY_SIGPOLL 1" >>confdefs.h
15452
15453esac
15454{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
15455$as_echo "$ans" >&6; }
15456
15457{ $as_echo "$as_me:${as_lineno-$LINENO}: checking number of arguments to gettimeofday()" >&5
15458$as_echo_n "checking number of arguments to gettimeofday()... " >&6; }
15459if ${ntp_cv_func_Xettimeofday_nargs+:} false; then :
15460  $as_echo_n "(cached) " >&6
15461else
15462  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15463/* end confdefs.h.  */
15464
15465		#include <sys/time.h>
15466
15467int
15468main ()
15469{
15470
15471		gettimeofday(0, 0);
15472		settimeofday(0, 0);
15473
15474
15475  ;
15476  return 0;
15477}
15478_ACEOF
15479if ac_fn_c_try_compile "$LINENO"; then :
15480  ntp_cv_func_Xettimeofday_nargs=2
15481else
15482  ntp_cv_func_Xettimeofday_nargs=1
15483
15484fi
15485rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15486
15487fi
15488{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_func_Xettimeofday_nargs" >&5
15489$as_echo "$ntp_cv_func_Xettimeofday_nargs" >&6; }
15490case "$ntp_cv_func_Xettimeofday_nargs" in
15491 1)
15492
15493$as_echo "#define SYSV_TIMEOFDAY 1" >>confdefs.h
15494
15495esac
15496
15497for ac_func in settimeofday
15498do :
15499  ac_fn_c_check_func "$LINENO" "settimeofday" "ac_cv_func_settimeofday"
15500if test "x$ac_cv_func_settimeofday" = xyes; then :
15501  cat >>confdefs.h <<_ACEOF
15502#define HAVE_SETTIMEOFDAY 1
15503_ACEOF
15504
15505else
15506
15507    case "$host" in
15508     *-*-mpeix*) ac_cv_func_settimeofday=yes
15509    esac
15510
15511fi
15512done
15513
15514
15515{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we'll use clock_settime or settimeofday or stime" >&5
15516$as_echo_n "checking if we'll use clock_settime or settimeofday or stime... " >&6; }
15517ntp_warning='GRONK'
15518ans=none
15519case "$ac_cv_func_clock_settime$ac_cv_func_settimeofday$ac_cv_func_stime" in
15520 yes*)
15521    ntp_warning=''
15522    ans='clock_settime()'
15523    ;;
15524 noyes*)
15525    ntp_warning='But clock_settime() would be better (if we had it)'
15526    ans='settimeofday()'
15527    ;;
15528 nonoyes)
15529    ntp_warning='Which is the worst of the three'
15530    ans='stime()'
15531    ;;
15532 *)
15533    case "$build" in
15534     $host)
15535	ntp_warning='Which leaves us with nothing to use!'
15536    esac
15537esac
15538{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
15539$as_echo "$ans" >&6; }
15540case "$ntp_warning" in
15541 '')
15542    ;;
15543 *)
15544    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** $ntp_warning ***" >&5
15545$as_echo "$as_me: WARNING: *** $ntp_warning ***" >&2;}
15546    ;;
15547esac
15548
15549
15550LDADD_LIBNTP="$LDADD_LIBNTP $LIBS"
15551LIBS=$__LIBS
15552{ __LIBS=; unset __LIBS;}
15553
15554
15555
15556# Check whether --enable-shared was given.
15557if test "${enable_shared+set}" = set; then :
15558  enableval=$enable_shared; p=${PACKAGE-default}
15559    case $enableval in
15560    yes) enable_shared=yes ;;
15561    no) enable_shared=no ;;
15562    *)
15563      enable_shared=no
15564      # Look at the argument we got.  We use all the common list separators.
15565      lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
15566      for pkg in $enableval; do
15567	IFS=$lt_save_ifs
15568	if test "X$pkg" = "X$p"; then
15569	  enable_shared=yes
15570	fi
15571      done
15572      IFS=$lt_save_ifs
15573      ;;
15574    esac
15575else
15576  enable_shared=no
15577fi
15578
15579
15580
15581
15582
15583
15584
15585
15586
15587case `pwd` in
15588  *\ * | *\	*)
15589    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5
15590$as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;;
15591esac
15592
15593
15594
15595macro_version='2.4.6'
15596macro_revision='2.4.6'
15597
15598
15599
15600
15601
15602
15603
15604
15605
15606
15607
15608
15609
15610ltmain=$ac_aux_dir/ltmain.sh
15611
15612# Backslashify metacharacters that are still active within
15613# double-quoted strings.
15614sed_quote_subst='s/\(["`$\\]\)/\\\1/g'
15615
15616# Same as above, but do not quote variable references.
15617double_quote_subst='s/\(["`\\]\)/\\\1/g'
15618
15619# Sed substitution to delay expansion of an escaped shell variable in a
15620# double_quote_subst'ed string.
15621delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
15622
15623# Sed substitution to delay expansion of an escaped single quote.
15624delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
15625
15626# Sed substitution to avoid accidental globbing in evaled expressions
15627no_glob_subst='s/\*/\\\*/g'
15628
15629{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5
15630$as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; }
15631if ${lt_cv_path_NM+:} false; then :
15632  $as_echo_n "(cached) " >&6
15633else
15634  if test -n "$NM"; then
15635  # Let the user override the test.
15636  lt_cv_path_NM=$NM
15637else
15638  lt_nm_to_check=${ac_tool_prefix}nm
15639  if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
15640    lt_nm_to_check="$lt_nm_to_check nm"
15641  fi
15642  for lt_tmp_nm in $lt_nm_to_check; do
15643    lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
15644    for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
15645      IFS=$lt_save_ifs
15646      test -z "$ac_dir" && ac_dir=.
15647      tmp_nm=$ac_dir/$lt_tmp_nm
15648      if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext"; then
15649	# Check to see if the nm accepts a BSD-compat flag.
15650	# Adding the 'sed 1q' prevents false positives on HP-UX, which says:
15651	#   nm: unknown option "B" ignored
15652	# Tru64's nm complains that /dev/null is an invalid object file
15653	# MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty
15654	case $build_os in
15655	mingw*) lt_bad_file=conftest.nm/nofile ;;
15656	*) lt_bad_file=/dev/null ;;
15657	esac
15658	case `"$tmp_nm" -B $lt_bad_file 2>&1 | sed '1q'` in
15659	*$lt_bad_file* | *'Invalid file or object type'*)
15660	  lt_cv_path_NM="$tmp_nm -B"
15661	  break 2
15662	  ;;
15663	*)
15664	  case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
15665	  */dev/null*)
15666	    lt_cv_path_NM="$tmp_nm -p"
15667	    break 2
15668	    ;;
15669	  *)
15670	    lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
15671	    continue # so that we can try to find one that supports BSD flags
15672	    ;;
15673	  esac
15674	  ;;
15675	esac
15676      fi
15677    done
15678    IFS=$lt_save_ifs
15679  done
15680  : ${lt_cv_path_NM=no}
15681fi
15682fi
15683{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5
15684$as_echo "$lt_cv_path_NM" >&6; }
15685if test no != "$lt_cv_path_NM"; then
15686  NM=$lt_cv_path_NM
15687else
15688  # Didn't find any BSD compatible name lister, look for dumpbin.
15689  if test -n "$DUMPBIN"; then :
15690    # Let the user override the test.
15691  else
15692    if test -n "$ac_tool_prefix"; then
15693  for ac_prog in dumpbin "link -dump"
15694  do
15695    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
15696set dummy $ac_tool_prefix$ac_prog; ac_word=$2
15697{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15698$as_echo_n "checking for $ac_word... " >&6; }
15699if ${ac_cv_prog_DUMPBIN+:} false; then :
15700  $as_echo_n "(cached) " >&6
15701else
15702  if test -n "$DUMPBIN"; then
15703  ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test.
15704else
15705as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15706for as_dir in $PATH
15707do
15708  IFS=$as_save_IFS
15709  test -z "$as_dir" && as_dir=.
15710    for ac_exec_ext in '' $ac_executable_extensions; do
15711  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15712    ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog"
15713    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15714    break 2
15715  fi
15716done
15717  done
15718IFS=$as_save_IFS
15719
15720fi
15721fi
15722DUMPBIN=$ac_cv_prog_DUMPBIN
15723if test -n "$DUMPBIN"; then
15724  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5
15725$as_echo "$DUMPBIN" >&6; }
15726else
15727  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15728$as_echo "no" >&6; }
15729fi
15730
15731
15732    test -n "$DUMPBIN" && break
15733  done
15734fi
15735if test -z "$DUMPBIN"; then
15736  ac_ct_DUMPBIN=$DUMPBIN
15737  for ac_prog in dumpbin "link -dump"
15738do
15739  # Extract the first word of "$ac_prog", so it can be a program name with args.
15740set dummy $ac_prog; ac_word=$2
15741{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15742$as_echo_n "checking for $ac_word... " >&6; }
15743if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then :
15744  $as_echo_n "(cached) " >&6
15745else
15746  if test -n "$ac_ct_DUMPBIN"; then
15747  ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test.
15748else
15749as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15750for as_dir in $PATH
15751do
15752  IFS=$as_save_IFS
15753  test -z "$as_dir" && as_dir=.
15754    for ac_exec_ext in '' $ac_executable_extensions; do
15755  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15756    ac_cv_prog_ac_ct_DUMPBIN="$ac_prog"
15757    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15758    break 2
15759  fi
15760done
15761  done
15762IFS=$as_save_IFS
15763
15764fi
15765fi
15766ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN
15767if test -n "$ac_ct_DUMPBIN"; then
15768  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5
15769$as_echo "$ac_ct_DUMPBIN" >&6; }
15770else
15771  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15772$as_echo "no" >&6; }
15773fi
15774
15775
15776  test -n "$ac_ct_DUMPBIN" && break
15777done
15778
15779  if test "x$ac_ct_DUMPBIN" = x; then
15780    DUMPBIN=":"
15781  else
15782    case $cross_compiling:$ac_tool_warned in
15783yes:)
15784{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
15785$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
15786ac_tool_warned=yes ;;
15787esac
15788    DUMPBIN=$ac_ct_DUMPBIN
15789  fi
15790fi
15791
15792    case `$DUMPBIN -symbols -headers /dev/null 2>&1 | sed '1q'` in
15793    *COFF*)
15794      DUMPBIN="$DUMPBIN -symbols -headers"
15795      ;;
15796    *)
15797      DUMPBIN=:
15798      ;;
15799    esac
15800  fi
15801
15802  if test : != "$DUMPBIN"; then
15803    NM=$DUMPBIN
15804  fi
15805fi
15806test -z "$NM" && NM=nm
15807
15808
15809
15810
15811
15812
15813{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5
15814$as_echo_n "checking the name lister ($NM) interface... " >&6; }
15815if ${lt_cv_nm_interface+:} false; then :
15816  $as_echo_n "(cached) " >&6
15817else
15818  lt_cv_nm_interface="BSD nm"
15819  echo "int some_variable = 0;" > conftest.$ac_ext
15820  (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5)
15821  (eval "$ac_compile" 2>conftest.err)
15822  cat conftest.err >&5
15823  (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
15824  (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
15825  cat conftest.err >&5
15826  (eval echo "\"\$as_me:$LINENO: output\"" >&5)
15827  cat conftest.out >&5
15828  if $GREP 'External.*some_variable' conftest.out > /dev/null; then
15829    lt_cv_nm_interface="MS dumpbin"
15830  fi
15831  rm -f conftest*
15832fi
15833{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5
15834$as_echo "$lt_cv_nm_interface" >&6; }
15835
15836{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
15837$as_echo_n "checking whether ln -s works... " >&6; }
15838LN_S=$as_ln_s
15839if test "$LN_S" = "ln -s"; then
15840  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15841$as_echo "yes" >&6; }
15842else
15843  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
15844$as_echo "no, using $LN_S" >&6; }
15845fi
15846
15847# find the maximum length of command line arguments
15848{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5
15849$as_echo_n "checking the maximum length of command line arguments... " >&6; }
15850if ${lt_cv_sys_max_cmd_len+:} false; then :
15851  $as_echo_n "(cached) " >&6
15852else
15853    i=0
15854  teststring=ABCD
15855
15856  case $build_os in
15857  msdosdjgpp*)
15858    # On DJGPP, this test can blow up pretty badly due to problems in libc
15859    # (any single argument exceeding 2000 bytes causes a buffer overrun
15860    # during glob expansion).  Even if it were fixed, the result of this
15861    # check would be larger than it should be.
15862    lt_cv_sys_max_cmd_len=12288;    # 12K is about right
15863    ;;
15864
15865  gnu*)
15866    # Under GNU Hurd, this test is not required because there is
15867    # no limit to the length of command line arguments.
15868    # Libtool will interpret -1 as no limit whatsoever
15869    lt_cv_sys_max_cmd_len=-1;
15870    ;;
15871
15872  cygwin* | mingw* | cegcc*)
15873    # On Win9x/ME, this test blows up -- it succeeds, but takes
15874    # about 5 minutes as the teststring grows exponentially.
15875    # Worse, since 9x/ME are not pre-emptively multitasking,
15876    # you end up with a "frozen" computer, even though with patience
15877    # the test eventually succeeds (with a max line length of 256k).
15878    # Instead, let's just punt: use the minimum linelength reported by
15879    # all of the supported platforms: 8192 (on NT/2K/XP).
15880    lt_cv_sys_max_cmd_len=8192;
15881    ;;
15882
15883  mint*)
15884    # On MiNT this can take a long time and run out of memory.
15885    lt_cv_sys_max_cmd_len=8192;
15886    ;;
15887
15888  amigaos*)
15889    # On AmigaOS with pdksh, this test takes hours, literally.
15890    # So we just punt and use a minimum line length of 8192.
15891    lt_cv_sys_max_cmd_len=8192;
15892    ;;
15893
15894  bitrig* | darwin* | dragonfly* | freebsd* | netbsd* | openbsd*)
15895    # This has been around since 386BSD, at least.  Likely further.
15896    if test -x /sbin/sysctl; then
15897      lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
15898    elif test -x /usr/sbin/sysctl; then
15899      lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
15900    else
15901      lt_cv_sys_max_cmd_len=65536	# usable default for all BSDs
15902    fi
15903    # And add a safety zone
15904    lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
15905    lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
15906    ;;
15907
15908  interix*)
15909    # We know the value 262144 and hardcode it with a safety zone (like BSD)
15910    lt_cv_sys_max_cmd_len=196608
15911    ;;
15912
15913  os2*)
15914    # The test takes a long time on OS/2.
15915    lt_cv_sys_max_cmd_len=8192
15916    ;;
15917
15918  osf*)
15919    # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
15920    # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
15921    # nice to cause kernel panics so lets avoid the loop below.
15922    # First set a reasonable default.
15923    lt_cv_sys_max_cmd_len=16384
15924    #
15925    if test -x /sbin/sysconfig; then
15926      case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
15927        *1*) lt_cv_sys_max_cmd_len=-1 ;;
15928      esac
15929    fi
15930    ;;
15931  sco3.2v5*)
15932    lt_cv_sys_max_cmd_len=102400
15933    ;;
15934  sysv5* | sco5v6* | sysv4.2uw2*)
15935    kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
15936    if test -n "$kargmax"; then
15937      lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[	 ]//'`
15938    else
15939      lt_cv_sys_max_cmd_len=32768
15940    fi
15941    ;;
15942  *)
15943    lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
15944    if test -n "$lt_cv_sys_max_cmd_len" && \
15945       test undefined != "$lt_cv_sys_max_cmd_len"; then
15946      lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
15947      lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
15948    else
15949      # Make teststring a little bigger before we do anything with it.
15950      # a 1K string should be a reasonable start.
15951      for i in 1 2 3 4 5 6 7 8; do
15952        teststring=$teststring$teststring
15953      done
15954      SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
15955      # If test is not a shell built-in, we'll probably end up computing a
15956      # maximum length that is only half of the actual maximum length, but
15957      # we can't tell.
15958      while { test X`env echo "$teststring$teststring" 2>/dev/null` \
15959	         = "X$teststring$teststring"; } >/dev/null 2>&1 &&
15960	      test 17 != "$i" # 1/2 MB should be enough
15961      do
15962        i=`expr $i + 1`
15963        teststring=$teststring$teststring
15964      done
15965      # Only check the string length outside the loop.
15966      lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
15967      teststring=
15968      # Add a significant safety factor because C++ compilers can tack on
15969      # massive amounts of additional arguments before passing them to the
15970      # linker.  It appears as though 1/2 is a usable value.
15971      lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
15972    fi
15973    ;;
15974  esac
15975
15976fi
15977
15978if test -n "$lt_cv_sys_max_cmd_len"; then
15979  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5
15980$as_echo "$lt_cv_sys_max_cmd_len" >&6; }
15981else
15982  { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5
15983$as_echo "none" >&6; }
15984fi
15985max_cmd_len=$lt_cv_sys_max_cmd_len
15986
15987
15988
15989
15990
15991
15992: ${CP="cp -f"}
15993: ${MV="mv -f"}
15994: ${RM="rm -f"}
15995
15996if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
15997  lt_unset=unset
15998else
15999  lt_unset=false
16000fi
16001
16002
16003
16004
16005
16006# test EBCDIC or ASCII
16007case `echo X|tr X '\101'` in
16008 A) # ASCII based system
16009    # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
16010  lt_SP2NL='tr \040 \012'
16011  lt_NL2SP='tr \015\012 \040\040'
16012  ;;
16013 *) # EBCDIC based system
16014  lt_SP2NL='tr \100 \n'
16015  lt_NL2SP='tr \r\n \100\100'
16016  ;;
16017esac
16018
16019
16020
16021
16022
16023
16024
16025
16026
16027{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5
16028$as_echo_n "checking how to convert $build file names to $host format... " >&6; }
16029if ${lt_cv_to_host_file_cmd+:} false; then :
16030  $as_echo_n "(cached) " >&6
16031else
16032  case $host in
16033  *-*-mingw* )
16034    case $build in
16035      *-*-mingw* ) # actually msys
16036        lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
16037        ;;
16038      *-*-cygwin* )
16039        lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
16040        ;;
16041      * ) # otherwise, assume *nix
16042        lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
16043        ;;
16044    esac
16045    ;;
16046  *-*-cygwin* )
16047    case $build in
16048      *-*-mingw* ) # actually msys
16049        lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
16050        ;;
16051      *-*-cygwin* )
16052        lt_cv_to_host_file_cmd=func_convert_file_noop
16053        ;;
16054      * ) # otherwise, assume *nix
16055        lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
16056        ;;
16057    esac
16058    ;;
16059  * ) # unhandled hosts (and "normal" native builds)
16060    lt_cv_to_host_file_cmd=func_convert_file_noop
16061    ;;
16062esac
16063
16064fi
16065
16066to_host_file_cmd=$lt_cv_to_host_file_cmd
16067{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5
16068$as_echo "$lt_cv_to_host_file_cmd" >&6; }
16069
16070
16071
16072
16073
16074{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5
16075$as_echo_n "checking how to convert $build file names to toolchain format... " >&6; }
16076if ${lt_cv_to_tool_file_cmd+:} false; then :
16077  $as_echo_n "(cached) " >&6
16078else
16079  #assume ordinary cross tools, or native build.
16080lt_cv_to_tool_file_cmd=func_convert_file_noop
16081case $host in
16082  *-*-mingw* )
16083    case $build in
16084      *-*-mingw* ) # actually msys
16085        lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
16086        ;;
16087    esac
16088    ;;
16089esac
16090
16091fi
16092
16093to_tool_file_cmd=$lt_cv_to_tool_file_cmd
16094{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5
16095$as_echo "$lt_cv_to_tool_file_cmd" >&6; }
16096
16097
16098
16099
16100
16101{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
16102$as_echo_n "checking for $LD option to reload object files... " >&6; }
16103if ${lt_cv_ld_reload_flag+:} false; then :
16104  $as_echo_n "(cached) " >&6
16105else
16106  lt_cv_ld_reload_flag='-r'
16107fi
16108{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5
16109$as_echo "$lt_cv_ld_reload_flag" >&6; }
16110reload_flag=$lt_cv_ld_reload_flag
16111case $reload_flag in
16112"" | " "*) ;;
16113*) reload_flag=" $reload_flag" ;;
16114esac
16115reload_cmds='$LD$reload_flag -o $output$reload_objs'
16116case $host_os in
16117  cygwin* | mingw* | pw32* | cegcc*)
16118    if test yes != "$GCC"; then
16119      reload_cmds=false
16120    fi
16121    ;;
16122  darwin*)
16123    if test yes = "$GCC"; then
16124      reload_cmds='$LTCC $LTCFLAGS -nostdlib $wl-r -o $output$reload_objs'
16125    else
16126      reload_cmds='$LD$reload_flag -o $output$reload_objs'
16127    fi
16128    ;;
16129esac
16130
16131
16132
16133
16134
16135
16136
16137
16138
16139if test -n "$ac_tool_prefix"; then
16140  # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
16141set dummy ${ac_tool_prefix}objdump; ac_word=$2
16142{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16143$as_echo_n "checking for $ac_word... " >&6; }
16144if ${ac_cv_prog_OBJDUMP+:} false; then :
16145  $as_echo_n "(cached) " >&6
16146else
16147  if test -n "$OBJDUMP"; then
16148  ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
16149else
16150as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16151for as_dir in $PATH
16152do
16153  IFS=$as_save_IFS
16154  test -z "$as_dir" && as_dir=.
16155    for ac_exec_ext in '' $ac_executable_extensions; do
16156  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16157    ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
16158    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16159    break 2
16160  fi
16161done
16162  done
16163IFS=$as_save_IFS
16164
16165fi
16166fi
16167OBJDUMP=$ac_cv_prog_OBJDUMP
16168if test -n "$OBJDUMP"; then
16169  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
16170$as_echo "$OBJDUMP" >&6; }
16171else
16172  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16173$as_echo "no" >&6; }
16174fi
16175
16176
16177fi
16178if test -z "$ac_cv_prog_OBJDUMP"; then
16179  ac_ct_OBJDUMP=$OBJDUMP
16180  # Extract the first word of "objdump", so it can be a program name with args.
16181set dummy objdump; ac_word=$2
16182{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16183$as_echo_n "checking for $ac_word... " >&6; }
16184if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
16185  $as_echo_n "(cached) " >&6
16186else
16187  if test -n "$ac_ct_OBJDUMP"; then
16188  ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
16189else
16190as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16191for as_dir in $PATH
16192do
16193  IFS=$as_save_IFS
16194  test -z "$as_dir" && as_dir=.
16195    for ac_exec_ext in '' $ac_executable_extensions; do
16196  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16197    ac_cv_prog_ac_ct_OBJDUMP="objdump"
16198    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16199    break 2
16200  fi
16201done
16202  done
16203IFS=$as_save_IFS
16204
16205fi
16206fi
16207ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
16208if test -n "$ac_ct_OBJDUMP"; then
16209  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
16210$as_echo "$ac_ct_OBJDUMP" >&6; }
16211else
16212  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16213$as_echo "no" >&6; }
16214fi
16215
16216  if test "x$ac_ct_OBJDUMP" = x; then
16217    OBJDUMP="false"
16218  else
16219    case $cross_compiling:$ac_tool_warned in
16220yes:)
16221{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
16222$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
16223ac_tool_warned=yes ;;
16224esac
16225    OBJDUMP=$ac_ct_OBJDUMP
16226  fi
16227else
16228  OBJDUMP="$ac_cv_prog_OBJDUMP"
16229fi
16230
16231test -z "$OBJDUMP" && OBJDUMP=objdump
16232
16233
16234
16235
16236
16237
16238
16239
16240
16241{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5
16242$as_echo_n "checking how to recognize dependent libraries... " >&6; }
16243if ${lt_cv_deplibs_check_method+:} false; then :
16244  $as_echo_n "(cached) " >&6
16245else
16246  lt_cv_file_magic_cmd='$MAGIC_CMD'
16247lt_cv_file_magic_test_file=
16248lt_cv_deplibs_check_method='unknown'
16249# Need to set the preceding variable on all platforms that support
16250# interlibrary dependencies.
16251# 'none' -- dependencies not supported.
16252# 'unknown' -- same as none, but documents that we really don't know.
16253# 'pass_all' -- all dependencies passed with no checks.
16254# 'test_compile' -- check by making test program.
16255# 'file_magic [[regex]]' -- check by looking for files in library path
16256# that responds to the $file_magic_cmd with a given extended regex.
16257# If you have 'file' or equivalent on your system and you're not sure
16258# whether 'pass_all' will *always* work, you probably want this one.
16259
16260case $host_os in
16261aix[4-9]*)
16262  lt_cv_deplibs_check_method=pass_all
16263  ;;
16264
16265beos*)
16266  lt_cv_deplibs_check_method=pass_all
16267  ;;
16268
16269bsdi[45]*)
16270  lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
16271  lt_cv_file_magic_cmd='/usr/bin/file -L'
16272  lt_cv_file_magic_test_file=/shlib/libc.so
16273  ;;
16274
16275cygwin*)
16276  # func_win32_libid is a shell function defined in ltmain.sh
16277  lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
16278  lt_cv_file_magic_cmd='func_win32_libid'
16279  ;;
16280
16281mingw* | pw32*)
16282  # Base MSYS/MinGW do not provide the 'file' command needed by
16283  # func_win32_libid shell function, so use a weaker test based on 'objdump',
16284  # unless we find 'file', for example because we are cross-compiling.
16285  if ( file / ) >/dev/null 2>&1; then
16286    lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
16287    lt_cv_file_magic_cmd='func_win32_libid'
16288  else
16289    # Keep this pattern in sync with the one in func_win32_libid.
16290    lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
16291    lt_cv_file_magic_cmd='$OBJDUMP -f'
16292  fi
16293  ;;
16294
16295cegcc*)
16296  # use the weaker test based on 'objdump'. See mingw*.
16297  lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
16298  lt_cv_file_magic_cmd='$OBJDUMP -f'
16299  ;;
16300
16301darwin* | rhapsody*)
16302  lt_cv_deplibs_check_method=pass_all
16303  ;;
16304
16305freebsd* | dragonfly*)
16306  if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
16307    case $host_cpu in
16308    i*86 )
16309      # Not sure whether the presence of OpenBSD here was a mistake.
16310      # Let's accept both of them until this is cleared up.
16311      lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library'
16312      lt_cv_file_magic_cmd=/usr/bin/file
16313      lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
16314      ;;
16315    esac
16316  else
16317    lt_cv_deplibs_check_method=pass_all
16318  fi
16319  ;;
16320
16321haiku*)
16322  lt_cv_deplibs_check_method=pass_all
16323  ;;
16324
16325hpux10.20* | hpux11*)
16326  lt_cv_file_magic_cmd=/usr/bin/file
16327  case $host_cpu in
16328  ia64*)
16329    lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64'
16330    lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
16331    ;;
16332  hppa*64*)
16333    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]'
16334    lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
16335    ;;
16336  *)
16337    lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library'
16338    lt_cv_file_magic_test_file=/usr/lib/libc.sl
16339    ;;
16340  esac
16341  ;;
16342
16343interix[3-9]*)
16344  # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
16345  lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$'
16346  ;;
16347
16348irix5* | irix6* | nonstopux*)
16349  case $LD in
16350  *-32|*"-32 ") libmagic=32-bit;;
16351  *-n32|*"-n32 ") libmagic=N32;;
16352  *-64|*"-64 ") libmagic=64-bit;;
16353  *) libmagic=never-match;;
16354  esac
16355  lt_cv_deplibs_check_method=pass_all
16356  ;;
16357
16358# This must be glibc/ELF.
16359linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
16360  lt_cv_deplibs_check_method=pass_all
16361  ;;
16362
16363netbsd*)
16364  if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
16365    lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
16366  else
16367    lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$'
16368  fi
16369  ;;
16370
16371newos6*)
16372  lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
16373  lt_cv_file_magic_cmd=/usr/bin/file
16374  lt_cv_file_magic_test_file=/usr/lib/libnls.so
16375  ;;
16376
16377*nto* | *qnx*)
16378  lt_cv_deplibs_check_method=pass_all
16379  ;;
16380
16381openbsd* | bitrig*)
16382  if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
16383    lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$'
16384  else
16385    lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
16386  fi
16387  ;;
16388
16389osf3* | osf4* | osf5*)
16390  lt_cv_deplibs_check_method=pass_all
16391  ;;
16392
16393rdos*)
16394  lt_cv_deplibs_check_method=pass_all
16395  ;;
16396
16397solaris*)
16398  lt_cv_deplibs_check_method=pass_all
16399  ;;
16400
16401sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
16402  lt_cv_deplibs_check_method=pass_all
16403  ;;
16404
16405sysv4 | sysv4.3*)
16406  case $host_vendor in
16407  motorola)
16408    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]'
16409    lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
16410    ;;
16411  ncr)
16412    lt_cv_deplibs_check_method=pass_all
16413    ;;
16414  sequent)
16415    lt_cv_file_magic_cmd='/bin/file'
16416    lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
16417    ;;
16418  sni)
16419    lt_cv_file_magic_cmd='/bin/file'
16420    lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"
16421    lt_cv_file_magic_test_file=/lib/libc.so
16422    ;;
16423  siemens)
16424    lt_cv_deplibs_check_method=pass_all
16425    ;;
16426  pc)
16427    lt_cv_deplibs_check_method=pass_all
16428    ;;
16429  esac
16430  ;;
16431
16432tpf*)
16433  lt_cv_deplibs_check_method=pass_all
16434  ;;
16435os2*)
16436  lt_cv_deplibs_check_method=pass_all
16437  ;;
16438esac
16439
16440fi
16441{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
16442$as_echo "$lt_cv_deplibs_check_method" >&6; }
16443
16444file_magic_glob=
16445want_nocaseglob=no
16446if test "$build" = "$host"; then
16447  case $host_os in
16448  mingw* | pw32*)
16449    if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
16450      want_nocaseglob=yes
16451    else
16452      file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"`
16453    fi
16454    ;;
16455  esac
16456fi
16457
16458file_magic_cmd=$lt_cv_file_magic_cmd
16459deplibs_check_method=$lt_cv_deplibs_check_method
16460test -z "$deplibs_check_method" && deplibs_check_method=unknown
16461
16462
16463
16464
16465
16466
16467
16468
16469
16470
16471
16472
16473
16474
16475
16476
16477
16478
16479
16480
16481
16482
16483if test -n "$ac_tool_prefix"; then
16484  # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
16485set dummy ${ac_tool_prefix}dlltool; ac_word=$2
16486{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16487$as_echo_n "checking for $ac_word... " >&6; }
16488if ${ac_cv_prog_DLLTOOL+:} false; then :
16489  $as_echo_n "(cached) " >&6
16490else
16491  if test -n "$DLLTOOL"; then
16492  ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
16493else
16494as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16495for as_dir in $PATH
16496do
16497  IFS=$as_save_IFS
16498  test -z "$as_dir" && as_dir=.
16499    for ac_exec_ext in '' $ac_executable_extensions; do
16500  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16501    ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
16502    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16503    break 2
16504  fi
16505done
16506  done
16507IFS=$as_save_IFS
16508
16509fi
16510fi
16511DLLTOOL=$ac_cv_prog_DLLTOOL
16512if test -n "$DLLTOOL"; then
16513  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
16514$as_echo "$DLLTOOL" >&6; }
16515else
16516  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16517$as_echo "no" >&6; }
16518fi
16519
16520
16521fi
16522if test -z "$ac_cv_prog_DLLTOOL"; then
16523  ac_ct_DLLTOOL=$DLLTOOL
16524  # Extract the first word of "dlltool", so it can be a program name with args.
16525set dummy dlltool; ac_word=$2
16526{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16527$as_echo_n "checking for $ac_word... " >&6; }
16528if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then :
16529  $as_echo_n "(cached) " >&6
16530else
16531  if test -n "$ac_ct_DLLTOOL"; then
16532  ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
16533else
16534as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16535for as_dir in $PATH
16536do
16537  IFS=$as_save_IFS
16538  test -z "$as_dir" && as_dir=.
16539    for ac_exec_ext in '' $ac_executable_extensions; do
16540  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16541    ac_cv_prog_ac_ct_DLLTOOL="dlltool"
16542    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16543    break 2
16544  fi
16545done
16546  done
16547IFS=$as_save_IFS
16548
16549fi
16550fi
16551ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
16552if test -n "$ac_ct_DLLTOOL"; then
16553  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
16554$as_echo "$ac_ct_DLLTOOL" >&6; }
16555else
16556  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16557$as_echo "no" >&6; }
16558fi
16559
16560  if test "x$ac_ct_DLLTOOL" = x; then
16561    DLLTOOL="false"
16562  else
16563    case $cross_compiling:$ac_tool_warned in
16564yes:)
16565{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
16566$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
16567ac_tool_warned=yes ;;
16568esac
16569    DLLTOOL=$ac_ct_DLLTOOL
16570  fi
16571else
16572  DLLTOOL="$ac_cv_prog_DLLTOOL"
16573fi
16574
16575test -z "$DLLTOOL" && DLLTOOL=dlltool
16576
16577
16578
16579
16580
16581
16582
16583
16584
16585
16586{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5
16587$as_echo_n "checking how to associate runtime and link libraries... " >&6; }
16588if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then :
16589  $as_echo_n "(cached) " >&6
16590else
16591  lt_cv_sharedlib_from_linklib_cmd='unknown'
16592
16593case $host_os in
16594cygwin* | mingw* | pw32* | cegcc*)
16595  # two different shell functions defined in ltmain.sh;
16596  # decide which one to use based on capabilities of $DLLTOOL
16597  case `$DLLTOOL --help 2>&1` in
16598  *--identify-strict*)
16599    lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
16600    ;;
16601  *)
16602    lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
16603    ;;
16604  esac
16605  ;;
16606*)
16607  # fallback: assume linklib IS sharedlib
16608  lt_cv_sharedlib_from_linklib_cmd=$ECHO
16609  ;;
16610esac
16611
16612fi
16613{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5
16614$as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; }
16615sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
16616test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
16617
16618
16619
16620
16621
16622
16623
16624if test -n "$ac_tool_prefix"; then
16625  for ac_prog in ar
16626  do
16627    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
16628set dummy $ac_tool_prefix$ac_prog; ac_word=$2
16629{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16630$as_echo_n "checking for $ac_word... " >&6; }
16631if ${ac_cv_prog_AR+:} false; then :
16632  $as_echo_n "(cached) " >&6
16633else
16634  if test -n "$AR"; then
16635  ac_cv_prog_AR="$AR" # Let the user override the test.
16636else
16637as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16638for as_dir in $PATH
16639do
16640  IFS=$as_save_IFS
16641  test -z "$as_dir" && as_dir=.
16642    for ac_exec_ext in '' $ac_executable_extensions; do
16643  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16644    ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
16645    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16646    break 2
16647  fi
16648done
16649  done
16650IFS=$as_save_IFS
16651
16652fi
16653fi
16654AR=$ac_cv_prog_AR
16655if test -n "$AR"; then
16656  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
16657$as_echo "$AR" >&6; }
16658else
16659  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16660$as_echo "no" >&6; }
16661fi
16662
16663
16664    test -n "$AR" && break
16665  done
16666fi
16667if test -z "$AR"; then
16668  ac_ct_AR=$AR
16669  for ac_prog in ar
16670do
16671  # Extract the first word of "$ac_prog", so it can be a program name with args.
16672set dummy $ac_prog; ac_word=$2
16673{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16674$as_echo_n "checking for $ac_word... " >&6; }
16675if ${ac_cv_prog_ac_ct_AR+:} false; then :
16676  $as_echo_n "(cached) " >&6
16677else
16678  if test -n "$ac_ct_AR"; then
16679  ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
16680else
16681as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16682for as_dir in $PATH
16683do
16684  IFS=$as_save_IFS
16685  test -z "$as_dir" && as_dir=.
16686    for ac_exec_ext in '' $ac_executable_extensions; do
16687  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16688    ac_cv_prog_ac_ct_AR="$ac_prog"
16689    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16690    break 2
16691  fi
16692done
16693  done
16694IFS=$as_save_IFS
16695
16696fi
16697fi
16698ac_ct_AR=$ac_cv_prog_ac_ct_AR
16699if test -n "$ac_ct_AR"; then
16700  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
16701$as_echo "$ac_ct_AR" >&6; }
16702else
16703  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16704$as_echo "no" >&6; }
16705fi
16706
16707
16708  test -n "$ac_ct_AR" && break
16709done
16710
16711  if test "x$ac_ct_AR" = x; then
16712    AR="false"
16713  else
16714    case $cross_compiling:$ac_tool_warned in
16715yes:)
16716{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
16717$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
16718ac_tool_warned=yes ;;
16719esac
16720    AR=$ac_ct_AR
16721  fi
16722fi
16723
16724: ${AR=ar}
16725: ${AR_FLAGS=cru}
16726
16727
16728
16729
16730
16731
16732
16733
16734
16735
16736
16737{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5
16738$as_echo_n "checking for archiver @FILE support... " >&6; }
16739if ${lt_cv_ar_at_file+:} false; then :
16740  $as_echo_n "(cached) " >&6
16741else
16742  lt_cv_ar_at_file=no
16743   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16744/* end confdefs.h.  */
16745
16746int
16747main ()
16748{
16749
16750  ;
16751  return 0;
16752}
16753_ACEOF
16754if ac_fn_c_try_compile "$LINENO"; then :
16755  echo conftest.$ac_objext > conftest.lst
16756      lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5'
16757      { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
16758  (eval $lt_ar_try) 2>&5
16759  ac_status=$?
16760  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
16761  test $ac_status = 0; }
16762      if test 0 -eq "$ac_status"; then
16763	# Ensure the archiver fails upon bogus file names.
16764	rm -f conftest.$ac_objext libconftest.a
16765	{ { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
16766  (eval $lt_ar_try) 2>&5
16767  ac_status=$?
16768  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
16769  test $ac_status = 0; }
16770	if test 0 -ne "$ac_status"; then
16771          lt_cv_ar_at_file=@
16772        fi
16773      fi
16774      rm -f conftest.* libconftest.a
16775
16776fi
16777rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16778
16779fi
16780{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5
16781$as_echo "$lt_cv_ar_at_file" >&6; }
16782
16783if test no = "$lt_cv_ar_at_file"; then
16784  archiver_list_spec=
16785else
16786  archiver_list_spec=$lt_cv_ar_at_file
16787fi
16788
16789
16790
16791
16792
16793
16794
16795if test -n "$ac_tool_prefix"; then
16796  # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
16797set dummy ${ac_tool_prefix}strip; ac_word=$2
16798{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16799$as_echo_n "checking for $ac_word... " >&6; }
16800if ${ac_cv_prog_STRIP+:} false; then :
16801  $as_echo_n "(cached) " >&6
16802else
16803  if test -n "$STRIP"; then
16804  ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
16805else
16806as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16807for as_dir in $PATH
16808do
16809  IFS=$as_save_IFS
16810  test -z "$as_dir" && as_dir=.
16811    for ac_exec_ext in '' $ac_executable_extensions; do
16812  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16813    ac_cv_prog_STRIP="${ac_tool_prefix}strip"
16814    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16815    break 2
16816  fi
16817done
16818  done
16819IFS=$as_save_IFS
16820
16821fi
16822fi
16823STRIP=$ac_cv_prog_STRIP
16824if test -n "$STRIP"; then
16825  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
16826$as_echo "$STRIP" >&6; }
16827else
16828  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16829$as_echo "no" >&6; }
16830fi
16831
16832
16833fi
16834if test -z "$ac_cv_prog_STRIP"; then
16835  ac_ct_STRIP=$STRIP
16836  # Extract the first word of "strip", so it can be a program name with args.
16837set dummy strip; ac_word=$2
16838{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16839$as_echo_n "checking for $ac_word... " >&6; }
16840if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
16841  $as_echo_n "(cached) " >&6
16842else
16843  if test -n "$ac_ct_STRIP"; then
16844  ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
16845else
16846as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16847for as_dir in $PATH
16848do
16849  IFS=$as_save_IFS
16850  test -z "$as_dir" && as_dir=.
16851    for ac_exec_ext in '' $ac_executable_extensions; do
16852  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16853    ac_cv_prog_ac_ct_STRIP="strip"
16854    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16855    break 2
16856  fi
16857done
16858  done
16859IFS=$as_save_IFS
16860
16861fi
16862fi
16863ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
16864if test -n "$ac_ct_STRIP"; then
16865  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
16866$as_echo "$ac_ct_STRIP" >&6; }
16867else
16868  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16869$as_echo "no" >&6; }
16870fi
16871
16872  if test "x$ac_ct_STRIP" = x; then
16873    STRIP=":"
16874  else
16875    case $cross_compiling:$ac_tool_warned in
16876yes:)
16877{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
16878$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
16879ac_tool_warned=yes ;;
16880esac
16881    STRIP=$ac_ct_STRIP
16882  fi
16883else
16884  STRIP="$ac_cv_prog_STRIP"
16885fi
16886
16887test -z "$STRIP" && STRIP=:
16888
16889
16890
16891
16892
16893
16894if test -n "$ac_tool_prefix"; then
16895  # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
16896set dummy ${ac_tool_prefix}ranlib; ac_word=$2
16897{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16898$as_echo_n "checking for $ac_word... " >&6; }
16899if ${ac_cv_prog_RANLIB+:} false; then :
16900  $as_echo_n "(cached) " >&6
16901else
16902  if test -n "$RANLIB"; then
16903  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
16904else
16905as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16906for as_dir in $PATH
16907do
16908  IFS=$as_save_IFS
16909  test -z "$as_dir" && as_dir=.
16910    for ac_exec_ext in '' $ac_executable_extensions; do
16911  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16912    ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
16913    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16914    break 2
16915  fi
16916done
16917  done
16918IFS=$as_save_IFS
16919
16920fi
16921fi
16922RANLIB=$ac_cv_prog_RANLIB
16923if test -n "$RANLIB"; then
16924  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
16925$as_echo "$RANLIB" >&6; }
16926else
16927  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16928$as_echo "no" >&6; }
16929fi
16930
16931
16932fi
16933if test -z "$ac_cv_prog_RANLIB"; then
16934  ac_ct_RANLIB=$RANLIB
16935  # Extract the first word of "ranlib", so it can be a program name with args.
16936set dummy ranlib; ac_word=$2
16937{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16938$as_echo_n "checking for $ac_word... " >&6; }
16939if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
16940  $as_echo_n "(cached) " >&6
16941else
16942  if test -n "$ac_ct_RANLIB"; then
16943  ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
16944else
16945as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16946for as_dir in $PATH
16947do
16948  IFS=$as_save_IFS
16949  test -z "$as_dir" && as_dir=.
16950    for ac_exec_ext in '' $ac_executable_extensions; do
16951  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16952    ac_cv_prog_ac_ct_RANLIB="ranlib"
16953    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16954    break 2
16955  fi
16956done
16957  done
16958IFS=$as_save_IFS
16959
16960fi
16961fi
16962ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
16963if test -n "$ac_ct_RANLIB"; then
16964  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
16965$as_echo "$ac_ct_RANLIB" >&6; }
16966else
16967  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16968$as_echo "no" >&6; }
16969fi
16970
16971  if test "x$ac_ct_RANLIB" = x; then
16972    RANLIB=":"
16973  else
16974    case $cross_compiling:$ac_tool_warned in
16975yes:)
16976{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
16977$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
16978ac_tool_warned=yes ;;
16979esac
16980    RANLIB=$ac_ct_RANLIB
16981  fi
16982else
16983  RANLIB="$ac_cv_prog_RANLIB"
16984fi
16985
16986test -z "$RANLIB" && RANLIB=:
16987
16988
16989
16990
16991
16992
16993# Determine commands to create old-style static archives.
16994old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
16995old_postinstall_cmds='chmod 644 $oldlib'
16996old_postuninstall_cmds=
16997
16998if test -n "$RANLIB"; then
16999  case $host_os in
17000  bitrig* | openbsd*)
17001    old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib"
17002    ;;
17003  *)
17004    old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib"
17005    ;;
17006  esac
17007  old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib"
17008fi
17009
17010case $host_os in
17011  darwin*)
17012    lock_old_archive_extraction=yes ;;
17013  *)
17014    lock_old_archive_extraction=no ;;
17015esac
17016
17017
17018
17019
17020
17021
17022
17023
17024
17025
17026
17027
17028
17029
17030
17031
17032
17033
17034
17035
17036
17037
17038
17039
17040
17041
17042
17043
17044
17045
17046
17047
17048
17049
17050
17051
17052
17053
17054
17055# If no C compiler was specified, use CC.
17056LTCC=${LTCC-"$CC"}
17057
17058# If no C compiler flags were specified, use CFLAGS.
17059LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
17060
17061# Allow CC to be a program name with arguments.
17062compiler=$CC
17063
17064
17065# Check for command to grab the raw symbol name followed by C symbol from nm.
17066{ $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5
17067$as_echo_n "checking command to parse $NM output from $compiler object... " >&6; }
17068if ${lt_cv_sys_global_symbol_pipe+:} false; then :
17069  $as_echo_n "(cached) " >&6
17070else
17071
17072# These are sane defaults that work on at least a few old systems.
17073# [They come from Ultrix.  What could be older than Ultrix?!! ;)]
17074
17075# Character class describing NM global symbol codes.
17076symcode='[BCDEGRST]'
17077
17078# Regexp to match symbols that can be accessed directly from C.
17079sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
17080
17081# Define system-specific variables.
17082case $host_os in
17083aix*)
17084  symcode='[BCDT]'
17085  ;;
17086cygwin* | mingw* | pw32* | cegcc*)
17087  symcode='[ABCDGISTW]'
17088  ;;
17089hpux*)
17090  if test ia64 = "$host_cpu"; then
17091    symcode='[ABCDEGRST]'
17092  fi
17093  ;;
17094irix* | nonstopux*)
17095  symcode='[BCDEGRST]'
17096  ;;
17097osf*)
17098  symcode='[BCDEGQRST]'
17099  ;;
17100solaris*)
17101  symcode='[BDRT]'
17102  ;;
17103sco3.2v5*)
17104  symcode='[DT]'
17105  ;;
17106sysv4.2uw2*)
17107  symcode='[DT]'
17108  ;;
17109sysv5* | sco5v6* | unixware* | OpenUNIX*)
17110  symcode='[ABDT]'
17111  ;;
17112sysv4)
17113  symcode='[DFNSTU]'
17114  ;;
17115esac
17116
17117# If we're using GNU nm, then use its standard symbol codes.
17118case `$NM -V 2>&1` in
17119*GNU* | *'with BFD'*)
17120  symcode='[ABCDGIRSTW]' ;;
17121esac
17122
17123if test "$lt_cv_nm_interface" = "MS dumpbin"; then
17124  # Gets list of data symbols to import.
17125  lt_cv_sys_global_symbol_to_import="sed -n -e 's/^I .* \(.*\)$/\1/p'"
17126  # Adjust the below global symbol transforms to fixup imported variables.
17127  lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'"
17128  lt_c_name_hook=" -e 's/^I .* \(.*\)$/  {\"\1\", (void *) 0},/p'"
17129  lt_c_name_lib_hook="\
17130  -e 's/^I .* \(lib.*\)$/  {\"\1\", (void *) 0},/p'\
17131  -e 's/^I .* \(.*\)$/  {\"lib\1\", (void *) 0},/p'"
17132else
17133  # Disable hooks by default.
17134  lt_cv_sys_global_symbol_to_import=
17135  lt_cdecl_hook=
17136  lt_c_name_hook=
17137  lt_c_name_lib_hook=
17138fi
17139
17140# Transform an extracted symbol line into a proper C declaration.
17141# Some systems (esp. on ia64) link data and code symbols differently,
17142# so use this general approach.
17143lt_cv_sys_global_symbol_to_cdecl="sed -n"\
17144$lt_cdecl_hook\
17145" -e 's/^T .* \(.*\)$/extern int \1();/p'"\
17146" -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'"
17147
17148# Transform an extracted symbol line into symbol name and symbol address
17149lt_cv_sys_global_symbol_to_c_name_address="sed -n"\
17150$lt_c_name_hook\
17151" -e 's/^: \(.*\) .*$/  {\"\1\", (void *) 0},/p'"\
17152" -e 's/^$symcode$symcode* .* \(.*\)$/  {\"\1\", (void *) \&\1},/p'"
17153
17154# Transform an extracted symbol line into symbol name with lib prefix and
17155# symbol address.
17156lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n"\
17157$lt_c_name_lib_hook\
17158" -e 's/^: \(.*\) .*$/  {\"\1\", (void *) 0},/p'"\
17159" -e 's/^$symcode$symcode* .* \(lib.*\)$/  {\"\1\", (void *) \&\1},/p'"\
17160" -e 's/^$symcode$symcode* .* \(.*\)$/  {\"lib\1\", (void *) \&\1},/p'"
17161
17162# Handle CRLF in mingw tool chain
17163opt_cr=
17164case $build_os in
17165mingw*)
17166  opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
17167  ;;
17168esac
17169
17170# Try without a prefix underscore, then with it.
17171for ac_symprfx in "" "_"; do
17172
17173  # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
17174  symxfrm="\\1 $ac_symprfx\\2 \\2"
17175
17176  # Write the raw and C identifiers.
17177  if test "$lt_cv_nm_interface" = "MS dumpbin"; then
17178    # Fake it for dumpbin and say T for any non-static function,
17179    # D for any global variable and I for any imported variable.
17180    # Also find C++ and __fastcall symbols from MSVC++,
17181    # which start with @ or ?.
17182    lt_cv_sys_global_symbol_pipe="$AWK '"\
17183"     {last_section=section; section=\$ 3};"\
17184"     /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\
17185"     /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
17186"     /^ *Symbol name *: /{split(\$ 0,sn,\":\"); si=substr(sn[2],2)};"\
17187"     /^ *Type *: code/{print \"T\",si,substr(si,length(prfx))};"\
17188"     /^ *Type *: data/{print \"I\",si,substr(si,length(prfx))};"\
17189"     \$ 0!~/External *\|/{next};"\
17190"     / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
17191"     {if(hide[section]) next};"\
17192"     {f=\"D\"}; \$ 0~/\(\).*\|/{f=\"T\"};"\
17193"     {split(\$ 0,a,/\||\r/); split(a[2],s)};"\
17194"     s[1]~/^[@?]/{print f,s[1],s[1]; next};"\
17195"     s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\
17196"     ' prfx=^$ac_symprfx"
17197  else
17198    lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[	 ]\($symcode$symcode*\)[	 ][	 ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
17199  fi
17200  lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
17201
17202  # Check to see that the pipe works correctly.
17203  pipe_works=no
17204
17205  rm -f conftest*
17206  cat > conftest.$ac_ext <<_LT_EOF
17207#ifdef __cplusplus
17208extern "C" {
17209#endif
17210char nm_test_var;
17211void nm_test_func(void);
17212void nm_test_func(void){}
17213#ifdef __cplusplus
17214}
17215#endif
17216int main(){nm_test_var='a';nm_test_func();return(0);}
17217_LT_EOF
17218
17219  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
17220  (eval $ac_compile) 2>&5
17221  ac_status=$?
17222  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
17223  test $ac_status = 0; }; then
17224    # Now try to grab the symbols.
17225    nlist=conftest.nm
17226    if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5
17227  (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5
17228  ac_status=$?
17229  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
17230  test $ac_status = 0; } && test -s "$nlist"; then
17231      # Try sorting and uniquifying the output.
17232      if sort "$nlist" | uniq > "$nlist"T; then
17233	mv -f "$nlist"T "$nlist"
17234      else
17235	rm -f "$nlist"T
17236      fi
17237
17238      # Make sure that we snagged all the symbols we need.
17239      if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
17240	if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
17241	  cat <<_LT_EOF > conftest.$ac_ext
17242/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests.  */
17243#if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE
17244/* DATA imports from DLLs on WIN32 can't be const, because runtime
17245   relocations are performed -- see ld's documentation on pseudo-relocs.  */
17246# define LT_DLSYM_CONST
17247#elif defined __osf__
17248/* This system does not cope well with relocations in const data.  */
17249# define LT_DLSYM_CONST
17250#else
17251# define LT_DLSYM_CONST const
17252#endif
17253
17254#ifdef __cplusplus
17255extern "C" {
17256#endif
17257
17258_LT_EOF
17259	  # Now generate the symbol file.
17260	  eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
17261
17262	  cat <<_LT_EOF >> conftest.$ac_ext
17263
17264/* The mapping between symbol names and symbols.  */
17265LT_DLSYM_CONST struct {
17266  const char *name;
17267  void       *address;
17268}
17269lt__PROGRAM__LTX_preloaded_symbols[] =
17270{
17271  { "@PROGRAM@", (void *) 0 },
17272_LT_EOF
17273	  $SED "s/^$symcode$symcode* .* \(.*\)$/  {\"\1\", (void *) \&\1},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
17274	  cat <<\_LT_EOF >> conftest.$ac_ext
17275  {0, (void *) 0}
17276};
17277
17278/* This works around a problem in FreeBSD linker */
17279#ifdef FREEBSD_WORKAROUND
17280static const void *lt_preloaded_setup() {
17281  return lt__PROGRAM__LTX_preloaded_symbols;
17282}
17283#endif
17284
17285#ifdef __cplusplus
17286}
17287#endif
17288_LT_EOF
17289	  # Now try linking the two files.
17290	  mv conftest.$ac_objext conftstm.$ac_objext
17291	  lt_globsym_save_LIBS=$LIBS
17292	  lt_globsym_save_CFLAGS=$CFLAGS
17293	  LIBS=conftstm.$ac_objext
17294	  CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
17295	  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
17296  (eval $ac_link) 2>&5
17297  ac_status=$?
17298  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
17299  test $ac_status = 0; } && test -s conftest$ac_exeext; then
17300	    pipe_works=yes
17301	  fi
17302	  LIBS=$lt_globsym_save_LIBS
17303	  CFLAGS=$lt_globsym_save_CFLAGS
17304	else
17305	  echo "cannot find nm_test_func in $nlist" >&5
17306	fi
17307      else
17308	echo "cannot find nm_test_var in $nlist" >&5
17309      fi
17310    else
17311      echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5
17312    fi
17313  else
17314    echo "$progname: failed program was:" >&5
17315    cat conftest.$ac_ext >&5
17316  fi
17317  rm -rf conftest* conftst*
17318
17319  # Do not use the global_symbol_pipe unless it works.
17320  if test yes = "$pipe_works"; then
17321    break
17322  else
17323    lt_cv_sys_global_symbol_pipe=
17324  fi
17325done
17326
17327fi
17328
17329if test -z "$lt_cv_sys_global_symbol_pipe"; then
17330  lt_cv_sys_global_symbol_to_cdecl=
17331fi
17332if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
17333  { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
17334$as_echo "failed" >&6; }
17335else
17336  { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
17337$as_echo "ok" >&6; }
17338fi
17339
17340# Response file support.
17341if test "$lt_cv_nm_interface" = "MS dumpbin"; then
17342  nm_file_list_spec='@'
17343elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then
17344  nm_file_list_spec='@'
17345fi
17346
17347
17348
17349
17350
17351
17352
17353
17354
17355
17356
17357
17358
17359
17360
17361
17362
17363
17364
17365
17366
17367
17368
17369
17370
17371
17372
17373
17374
17375
17376
17377
17378
17379
17380
17381
17382
17383{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
17384$as_echo_n "checking for sysroot... " >&6; }
17385
17386# Check whether --with-sysroot was given.
17387if test "${with_sysroot+set}" = set; then :
17388  withval=$with_sysroot;
17389else
17390  with_sysroot=no
17391fi
17392
17393
17394lt_sysroot=
17395case $with_sysroot in #(
17396 yes)
17397   if test yes = "$GCC"; then
17398     lt_sysroot=`$CC --print-sysroot 2>/dev/null`
17399   fi
17400   ;; #(
17401 /*)
17402   lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"`
17403   ;; #(
17404 no|'')
17405   ;; #(
17406 *)
17407   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_sysroot" >&5
17408$as_echo "$with_sysroot" >&6; }
17409   as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5
17410   ;;
17411esac
17412
17413 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5
17414$as_echo "${lt_sysroot:-no}" >&6; }
17415
17416
17417
17418
17419
17420{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a working dd" >&5
17421$as_echo_n "checking for a working dd... " >&6; }
17422if ${ac_cv_path_lt_DD+:} false; then :
17423  $as_echo_n "(cached) " >&6
17424else
17425  printf 0123456789abcdef0123456789abcdef >conftest.i
17426cat conftest.i conftest.i >conftest2.i
17427: ${lt_DD:=$DD}
17428if test -z "$lt_DD"; then
17429  ac_path_lt_DD_found=false
17430  # Loop through the user's path and test for each of PROGNAME-LIST
17431  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17432for as_dir in $PATH
17433do
17434  IFS=$as_save_IFS
17435  test -z "$as_dir" && as_dir=.
17436    for ac_prog in dd; do
17437    for ac_exec_ext in '' $ac_executable_extensions; do
17438      ac_path_lt_DD="$as_dir/$ac_prog$ac_exec_ext"
17439      as_fn_executable_p "$ac_path_lt_DD" || continue
17440if "$ac_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then
17441  cmp -s conftest.i conftest.out \
17442  && ac_cv_path_lt_DD="$ac_path_lt_DD" ac_path_lt_DD_found=:
17443fi
17444      $ac_path_lt_DD_found && break 3
17445    done
17446  done
17447  done
17448IFS=$as_save_IFS
17449  if test -z "$ac_cv_path_lt_DD"; then
17450    :
17451  fi
17452else
17453  ac_cv_path_lt_DD=$lt_DD
17454fi
17455
17456rm -f conftest.i conftest2.i conftest.out
17457fi
17458{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_lt_DD" >&5
17459$as_echo "$ac_cv_path_lt_DD" >&6; }
17460
17461
17462{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to truncate binary pipes" >&5
17463$as_echo_n "checking how to truncate binary pipes... " >&6; }
17464if ${lt_cv_truncate_bin+:} false; then :
17465  $as_echo_n "(cached) " >&6
17466else
17467  printf 0123456789abcdef0123456789abcdef >conftest.i
17468cat conftest.i conftest.i >conftest2.i
17469lt_cv_truncate_bin=
17470if "$ac_cv_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then
17471  cmp -s conftest.i conftest.out \
17472  && lt_cv_truncate_bin="$ac_cv_path_lt_DD bs=4096 count=1"
17473fi
17474rm -f conftest.i conftest2.i conftest.out
17475test -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q"
17476fi
17477{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_truncate_bin" >&5
17478$as_echo "$lt_cv_truncate_bin" >&6; }
17479
17480
17481
17482
17483
17484
17485
17486# Calculate cc_basename.  Skip known compiler wrappers and cross-prefix.
17487func_cc_basename ()
17488{
17489    for cc_temp in $*""; do
17490      case $cc_temp in
17491        compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
17492        distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
17493        \-*) ;;
17494        *) break;;
17495      esac
17496    done
17497    func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
17498}
17499
17500# Check whether --enable-libtool-lock was given.
17501if test "${enable_libtool_lock+set}" = set; then :
17502  enableval=$enable_libtool_lock;
17503fi
17504
17505test no = "$enable_libtool_lock" || enable_libtool_lock=yes
17506
17507# Some flags need to be propagated to the compiler or linker for good
17508# libtool support.
17509case $host in
17510ia64-*-hpux*)
17511  # Find out what ABI is being produced by ac_compile, and set mode
17512  # options accordingly.
17513  echo 'int i;' > conftest.$ac_ext
17514  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
17515  (eval $ac_compile) 2>&5
17516  ac_status=$?
17517  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
17518  test $ac_status = 0; }; then
17519    case `/usr/bin/file conftest.$ac_objext` in
17520      *ELF-32*)
17521	HPUX_IA64_MODE=32
17522	;;
17523      *ELF-64*)
17524	HPUX_IA64_MODE=64
17525	;;
17526    esac
17527  fi
17528  rm -rf conftest*
17529  ;;
17530*-*-irix6*)
17531  # Find out what ABI is being produced by ac_compile, and set linker
17532  # options accordingly.
17533  echo '#line '$LINENO' "configure"' > conftest.$ac_ext
17534  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
17535  (eval $ac_compile) 2>&5
17536  ac_status=$?
17537  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
17538  test $ac_status = 0; }; then
17539    if test yes = "$lt_cv_prog_gnu_ld"; then
17540      case `/usr/bin/file conftest.$ac_objext` in
17541	*32-bit*)
17542	  LD="${LD-ld} -melf32bsmip"
17543	  ;;
17544	*N32*)
17545	  LD="${LD-ld} -melf32bmipn32"
17546	  ;;
17547	*64-bit*)
17548	  LD="${LD-ld} -melf64bmip"
17549	;;
17550      esac
17551    else
17552      case `/usr/bin/file conftest.$ac_objext` in
17553	*32-bit*)
17554	  LD="${LD-ld} -32"
17555	  ;;
17556	*N32*)
17557	  LD="${LD-ld} -n32"
17558	  ;;
17559	*64-bit*)
17560	  LD="${LD-ld} -64"
17561	  ;;
17562      esac
17563    fi
17564  fi
17565  rm -rf conftest*
17566  ;;
17567
17568mips64*-*linux*)
17569  # Find out what ABI is being produced by ac_compile, and set linker
17570  # options accordingly.
17571  echo '#line '$LINENO' "configure"' > conftest.$ac_ext
17572  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
17573  (eval $ac_compile) 2>&5
17574  ac_status=$?
17575  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
17576  test $ac_status = 0; }; then
17577    emul=elf
17578    case `/usr/bin/file conftest.$ac_objext` in
17579      *32-bit*)
17580	emul="${emul}32"
17581	;;
17582      *64-bit*)
17583	emul="${emul}64"
17584	;;
17585    esac
17586    case `/usr/bin/file conftest.$ac_objext` in
17587      *MSB*)
17588	emul="${emul}btsmip"
17589	;;
17590      *LSB*)
17591	emul="${emul}ltsmip"
17592	;;
17593    esac
17594    case `/usr/bin/file conftest.$ac_objext` in
17595      *N32*)
17596	emul="${emul}n32"
17597	;;
17598    esac
17599    LD="${LD-ld} -m $emul"
17600  fi
17601  rm -rf conftest*
17602  ;;
17603
17604x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \
17605s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
17606  # Find out what ABI is being produced by ac_compile, and set linker
17607  # options accordingly.  Note that the listed cases only cover the
17608  # situations where additional linker options are needed (such as when
17609  # doing 32-bit compilation for a host where ld defaults to 64-bit, or
17610  # vice versa); the common cases where no linker options are needed do
17611  # not appear in the list.
17612  echo 'int i;' > conftest.$ac_ext
17613  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
17614  (eval $ac_compile) 2>&5
17615  ac_status=$?
17616  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
17617  test $ac_status = 0; }; then
17618    case `/usr/bin/file conftest.o` in
17619      *32-bit*)
17620	case $host in
17621	  x86_64-*kfreebsd*-gnu)
17622	    LD="${LD-ld} -m elf_i386_fbsd"
17623	    ;;
17624	  x86_64-*linux*)
17625	    case `/usr/bin/file conftest.o` in
17626	      *x86-64*)
17627		LD="${LD-ld} -m elf32_x86_64"
17628		;;
17629	      *)
17630		LD="${LD-ld} -m elf_i386"
17631		;;
17632	    esac
17633	    ;;
17634	  powerpc64le-*linux*)
17635	    LD="${LD-ld} -m elf32lppclinux"
17636	    ;;
17637	  powerpc64-*linux*)
17638	    LD="${LD-ld} -m elf32ppclinux"
17639	    ;;
17640	  s390x-*linux*)
17641	    LD="${LD-ld} -m elf_s390"
17642	    ;;
17643	  sparc64-*linux*)
17644	    LD="${LD-ld} -m elf32_sparc"
17645	    ;;
17646	esac
17647	;;
17648      *64-bit*)
17649	case $host in
17650	  x86_64-*kfreebsd*-gnu)
17651	    LD="${LD-ld} -m elf_x86_64_fbsd"
17652	    ;;
17653	  x86_64-*linux*)
17654	    LD="${LD-ld} -m elf_x86_64"
17655	    ;;
17656	  powerpcle-*linux*)
17657	    LD="${LD-ld} -m elf64lppc"
17658	    ;;
17659	  powerpc-*linux*)
17660	    LD="${LD-ld} -m elf64ppc"
17661	    ;;
17662	  s390*-*linux*|s390*-*tpf*)
17663	    LD="${LD-ld} -m elf64_s390"
17664	    ;;
17665	  sparc*-*linux*)
17666	    LD="${LD-ld} -m elf64_sparc"
17667	    ;;
17668	esac
17669	;;
17670    esac
17671  fi
17672  rm -rf conftest*
17673  ;;
17674
17675*-*-sco3.2v5*)
17676  # On SCO OpenServer 5, we need -belf to get full-featured binaries.
17677  SAVE_CFLAGS=$CFLAGS
17678  CFLAGS="$CFLAGS -belf"
17679  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5
17680$as_echo_n "checking whether the C compiler needs -belf... " >&6; }
17681if ${lt_cv_cc_needs_belf+:} false; then :
17682  $as_echo_n "(cached) " >&6
17683else
17684  ac_ext=c
17685ac_cpp='$CPP $CPPFLAGS'
17686ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
17687ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
17688ac_compiler_gnu=$ac_cv_c_compiler_gnu
17689
17690     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17691/* end confdefs.h.  */
17692
17693int
17694main ()
17695{
17696
17697  ;
17698  return 0;
17699}
17700_ACEOF
17701if ac_fn_c_try_link "$LINENO"; then :
17702  lt_cv_cc_needs_belf=yes
17703else
17704  lt_cv_cc_needs_belf=no
17705fi
17706rm -f core conftest.err conftest.$ac_objext \
17707    conftest$ac_exeext conftest.$ac_ext
17708     ac_ext=c
17709ac_cpp='$CPP $CPPFLAGS'
17710ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
17711ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
17712ac_compiler_gnu=$ac_cv_c_compiler_gnu
17713
17714fi
17715{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5
17716$as_echo "$lt_cv_cc_needs_belf" >&6; }
17717  if test yes != "$lt_cv_cc_needs_belf"; then
17718    # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
17719    CFLAGS=$SAVE_CFLAGS
17720  fi
17721  ;;
17722*-*solaris*)
17723  # Find out what ABI is being produced by ac_compile, and set linker
17724  # options accordingly.
17725  echo 'int i;' > conftest.$ac_ext
17726  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
17727  (eval $ac_compile) 2>&5
17728  ac_status=$?
17729  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
17730  test $ac_status = 0; }; then
17731    case `/usr/bin/file conftest.o` in
17732    *64-bit*)
17733      case $lt_cv_prog_gnu_ld in
17734      yes*)
17735        case $host in
17736        i?86-*-solaris*|x86_64-*-solaris*)
17737          LD="${LD-ld} -m elf_x86_64"
17738          ;;
17739        sparc*-*-solaris*)
17740          LD="${LD-ld} -m elf64_sparc"
17741          ;;
17742        esac
17743        # GNU ld 2.21 introduced _sol2 emulations.  Use them if available.
17744        if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then
17745          LD=${LD-ld}_sol2
17746        fi
17747        ;;
17748      *)
17749	if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
17750	  LD="${LD-ld} -64"
17751	fi
17752	;;
17753      esac
17754      ;;
17755    esac
17756  fi
17757  rm -rf conftest*
17758  ;;
17759esac
17760
17761need_locks=$enable_libtool_lock
17762
17763if test -n "$ac_tool_prefix"; then
17764  # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args.
17765set dummy ${ac_tool_prefix}mt; ac_word=$2
17766{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17767$as_echo_n "checking for $ac_word... " >&6; }
17768if ${ac_cv_prog_MANIFEST_TOOL+:} false; then :
17769  $as_echo_n "(cached) " >&6
17770else
17771  if test -n "$MANIFEST_TOOL"; then
17772  ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test.
17773else
17774as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17775for as_dir in $PATH
17776do
17777  IFS=$as_save_IFS
17778  test -z "$as_dir" && as_dir=.
17779    for ac_exec_ext in '' $ac_executable_extensions; do
17780  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17781    ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt"
17782    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17783    break 2
17784  fi
17785done
17786  done
17787IFS=$as_save_IFS
17788
17789fi
17790fi
17791MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL
17792if test -n "$MANIFEST_TOOL"; then
17793  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5
17794$as_echo "$MANIFEST_TOOL" >&6; }
17795else
17796  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17797$as_echo "no" >&6; }
17798fi
17799
17800
17801fi
17802if test -z "$ac_cv_prog_MANIFEST_TOOL"; then
17803  ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL
17804  # Extract the first word of "mt", so it can be a program name with args.
17805set dummy mt; ac_word=$2
17806{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17807$as_echo_n "checking for $ac_word... " >&6; }
17808if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then :
17809  $as_echo_n "(cached) " >&6
17810else
17811  if test -n "$ac_ct_MANIFEST_TOOL"; then
17812  ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test.
17813else
17814as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17815for as_dir in $PATH
17816do
17817  IFS=$as_save_IFS
17818  test -z "$as_dir" && as_dir=.
17819    for ac_exec_ext in '' $ac_executable_extensions; do
17820  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17821    ac_cv_prog_ac_ct_MANIFEST_TOOL="mt"
17822    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17823    break 2
17824  fi
17825done
17826  done
17827IFS=$as_save_IFS
17828
17829fi
17830fi
17831ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL
17832if test -n "$ac_ct_MANIFEST_TOOL"; then
17833  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5
17834$as_echo "$ac_ct_MANIFEST_TOOL" >&6; }
17835else
17836  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17837$as_echo "no" >&6; }
17838fi
17839
17840  if test "x$ac_ct_MANIFEST_TOOL" = x; then
17841    MANIFEST_TOOL=":"
17842  else
17843    case $cross_compiling:$ac_tool_warned in
17844yes:)
17845{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
17846$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
17847ac_tool_warned=yes ;;
17848esac
17849    MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL
17850  fi
17851else
17852  MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL"
17853fi
17854
17855test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
17856{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5
17857$as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; }
17858if ${lt_cv_path_mainfest_tool+:} false; then :
17859  $as_echo_n "(cached) " >&6
17860else
17861  lt_cv_path_mainfest_tool=no
17862  echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5
17863  $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
17864  cat conftest.err >&5
17865  if $GREP 'Manifest Tool' conftest.out > /dev/null; then
17866    lt_cv_path_mainfest_tool=yes
17867  fi
17868  rm -f conftest*
17869fi
17870{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5
17871$as_echo "$lt_cv_path_mainfest_tool" >&6; }
17872if test yes != "$lt_cv_path_mainfest_tool"; then
17873  MANIFEST_TOOL=:
17874fi
17875
17876
17877
17878
17879
17880
17881  case $host_os in
17882    rhapsody* | darwin*)
17883    if test -n "$ac_tool_prefix"; then
17884  # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args.
17885set dummy ${ac_tool_prefix}dsymutil; ac_word=$2
17886{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17887$as_echo_n "checking for $ac_word... " >&6; }
17888if ${ac_cv_prog_DSYMUTIL+:} false; then :
17889  $as_echo_n "(cached) " >&6
17890else
17891  if test -n "$DSYMUTIL"; then
17892  ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
17893else
17894as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17895for as_dir in $PATH
17896do
17897  IFS=$as_save_IFS
17898  test -z "$as_dir" && as_dir=.
17899    for ac_exec_ext in '' $ac_executable_extensions; do
17900  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17901    ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil"
17902    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17903    break 2
17904  fi
17905done
17906  done
17907IFS=$as_save_IFS
17908
17909fi
17910fi
17911DSYMUTIL=$ac_cv_prog_DSYMUTIL
17912if test -n "$DSYMUTIL"; then
17913  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
17914$as_echo "$DSYMUTIL" >&6; }
17915else
17916  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17917$as_echo "no" >&6; }
17918fi
17919
17920
17921fi
17922if test -z "$ac_cv_prog_DSYMUTIL"; then
17923  ac_ct_DSYMUTIL=$DSYMUTIL
17924  # Extract the first word of "dsymutil", so it can be a program name with args.
17925set dummy dsymutil; ac_word=$2
17926{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17927$as_echo_n "checking for $ac_word... " >&6; }
17928if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then :
17929  $as_echo_n "(cached) " >&6
17930else
17931  if test -n "$ac_ct_DSYMUTIL"; then
17932  ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test.
17933else
17934as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17935for as_dir in $PATH
17936do
17937  IFS=$as_save_IFS
17938  test -z "$as_dir" && as_dir=.
17939    for ac_exec_ext in '' $ac_executable_extensions; do
17940  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17941    ac_cv_prog_ac_ct_DSYMUTIL="dsymutil"
17942    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17943    break 2
17944  fi
17945done
17946  done
17947IFS=$as_save_IFS
17948
17949fi
17950fi
17951ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL
17952if test -n "$ac_ct_DSYMUTIL"; then
17953  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5
17954$as_echo "$ac_ct_DSYMUTIL" >&6; }
17955else
17956  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17957$as_echo "no" >&6; }
17958fi
17959
17960  if test "x$ac_ct_DSYMUTIL" = x; then
17961    DSYMUTIL=":"
17962  else
17963    case $cross_compiling:$ac_tool_warned in
17964yes:)
17965{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
17966$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
17967ac_tool_warned=yes ;;
17968esac
17969    DSYMUTIL=$ac_ct_DSYMUTIL
17970  fi
17971else
17972  DSYMUTIL="$ac_cv_prog_DSYMUTIL"
17973fi
17974
17975    if test -n "$ac_tool_prefix"; then
17976  # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args.
17977set dummy ${ac_tool_prefix}nmedit; ac_word=$2
17978{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17979$as_echo_n "checking for $ac_word... " >&6; }
17980if ${ac_cv_prog_NMEDIT+:} false; then :
17981  $as_echo_n "(cached) " >&6
17982else
17983  if test -n "$NMEDIT"; then
17984  ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test.
17985else
17986as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17987for as_dir in $PATH
17988do
17989  IFS=$as_save_IFS
17990  test -z "$as_dir" && as_dir=.
17991    for ac_exec_ext in '' $ac_executable_extensions; do
17992  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17993    ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit"
17994    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17995    break 2
17996  fi
17997done
17998  done
17999IFS=$as_save_IFS
18000
18001fi
18002fi
18003NMEDIT=$ac_cv_prog_NMEDIT
18004if test -n "$NMEDIT"; then
18005  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5
18006$as_echo "$NMEDIT" >&6; }
18007else
18008  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18009$as_echo "no" >&6; }
18010fi
18011
18012
18013fi
18014if test -z "$ac_cv_prog_NMEDIT"; then
18015  ac_ct_NMEDIT=$NMEDIT
18016  # Extract the first word of "nmedit", so it can be a program name with args.
18017set dummy nmedit; ac_word=$2
18018{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18019$as_echo_n "checking for $ac_word... " >&6; }
18020if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then :
18021  $as_echo_n "(cached) " >&6
18022else
18023  if test -n "$ac_ct_NMEDIT"; then
18024  ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test.
18025else
18026as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18027for as_dir in $PATH
18028do
18029  IFS=$as_save_IFS
18030  test -z "$as_dir" && as_dir=.
18031    for ac_exec_ext in '' $ac_executable_extensions; do
18032  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18033    ac_cv_prog_ac_ct_NMEDIT="nmedit"
18034    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18035    break 2
18036  fi
18037done
18038  done
18039IFS=$as_save_IFS
18040
18041fi
18042fi
18043ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT
18044if test -n "$ac_ct_NMEDIT"; then
18045  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5
18046$as_echo "$ac_ct_NMEDIT" >&6; }
18047else
18048  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18049$as_echo "no" >&6; }
18050fi
18051
18052  if test "x$ac_ct_NMEDIT" = x; then
18053    NMEDIT=":"
18054  else
18055    case $cross_compiling:$ac_tool_warned in
18056yes:)
18057{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
18058$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
18059ac_tool_warned=yes ;;
18060esac
18061    NMEDIT=$ac_ct_NMEDIT
18062  fi
18063else
18064  NMEDIT="$ac_cv_prog_NMEDIT"
18065fi
18066
18067    if test -n "$ac_tool_prefix"; then
18068  # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args.
18069set dummy ${ac_tool_prefix}lipo; ac_word=$2
18070{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18071$as_echo_n "checking for $ac_word... " >&6; }
18072if ${ac_cv_prog_LIPO+:} false; then :
18073  $as_echo_n "(cached) " >&6
18074else
18075  if test -n "$LIPO"; then
18076  ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
18077else
18078as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18079for as_dir in $PATH
18080do
18081  IFS=$as_save_IFS
18082  test -z "$as_dir" && as_dir=.
18083    for ac_exec_ext in '' $ac_executable_extensions; do
18084  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18085    ac_cv_prog_LIPO="${ac_tool_prefix}lipo"
18086    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18087    break 2
18088  fi
18089done
18090  done
18091IFS=$as_save_IFS
18092
18093fi
18094fi
18095LIPO=$ac_cv_prog_LIPO
18096if test -n "$LIPO"; then
18097  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
18098$as_echo "$LIPO" >&6; }
18099else
18100  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18101$as_echo "no" >&6; }
18102fi
18103
18104
18105fi
18106if test -z "$ac_cv_prog_LIPO"; then
18107  ac_ct_LIPO=$LIPO
18108  # Extract the first word of "lipo", so it can be a program name with args.
18109set dummy lipo; ac_word=$2
18110{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18111$as_echo_n "checking for $ac_word... " >&6; }
18112if ${ac_cv_prog_ac_ct_LIPO+:} false; then :
18113  $as_echo_n "(cached) " >&6
18114else
18115  if test -n "$ac_ct_LIPO"; then
18116  ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test.
18117else
18118as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18119for as_dir in $PATH
18120do
18121  IFS=$as_save_IFS
18122  test -z "$as_dir" && as_dir=.
18123    for ac_exec_ext in '' $ac_executable_extensions; do
18124  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18125    ac_cv_prog_ac_ct_LIPO="lipo"
18126    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18127    break 2
18128  fi
18129done
18130  done
18131IFS=$as_save_IFS
18132
18133fi
18134fi
18135ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO
18136if test -n "$ac_ct_LIPO"; then
18137  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5
18138$as_echo "$ac_ct_LIPO" >&6; }
18139else
18140  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18141$as_echo "no" >&6; }
18142fi
18143
18144  if test "x$ac_ct_LIPO" = x; then
18145    LIPO=":"
18146  else
18147    case $cross_compiling:$ac_tool_warned in
18148yes:)
18149{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
18150$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
18151ac_tool_warned=yes ;;
18152esac
18153    LIPO=$ac_ct_LIPO
18154  fi
18155else
18156  LIPO="$ac_cv_prog_LIPO"
18157fi
18158
18159    if test -n "$ac_tool_prefix"; then
18160  # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args.
18161set dummy ${ac_tool_prefix}otool; ac_word=$2
18162{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18163$as_echo_n "checking for $ac_word... " >&6; }
18164if ${ac_cv_prog_OTOOL+:} false; then :
18165  $as_echo_n "(cached) " >&6
18166else
18167  if test -n "$OTOOL"; then
18168  ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
18169else
18170as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18171for as_dir in $PATH
18172do
18173  IFS=$as_save_IFS
18174  test -z "$as_dir" && as_dir=.
18175    for ac_exec_ext in '' $ac_executable_extensions; do
18176  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18177    ac_cv_prog_OTOOL="${ac_tool_prefix}otool"
18178    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18179    break 2
18180  fi
18181done
18182  done
18183IFS=$as_save_IFS
18184
18185fi
18186fi
18187OTOOL=$ac_cv_prog_OTOOL
18188if test -n "$OTOOL"; then
18189  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
18190$as_echo "$OTOOL" >&6; }
18191else
18192  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18193$as_echo "no" >&6; }
18194fi
18195
18196
18197fi
18198if test -z "$ac_cv_prog_OTOOL"; then
18199  ac_ct_OTOOL=$OTOOL
18200  # Extract the first word of "otool", so it can be a program name with args.
18201set dummy otool; ac_word=$2
18202{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18203$as_echo_n "checking for $ac_word... " >&6; }
18204if ${ac_cv_prog_ac_ct_OTOOL+:} false; then :
18205  $as_echo_n "(cached) " >&6
18206else
18207  if test -n "$ac_ct_OTOOL"; then
18208  ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test.
18209else
18210as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18211for as_dir in $PATH
18212do
18213  IFS=$as_save_IFS
18214  test -z "$as_dir" && as_dir=.
18215    for ac_exec_ext in '' $ac_executable_extensions; do
18216  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18217    ac_cv_prog_ac_ct_OTOOL="otool"
18218    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18219    break 2
18220  fi
18221done
18222  done
18223IFS=$as_save_IFS
18224
18225fi
18226fi
18227ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL
18228if test -n "$ac_ct_OTOOL"; then
18229  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5
18230$as_echo "$ac_ct_OTOOL" >&6; }
18231else
18232  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18233$as_echo "no" >&6; }
18234fi
18235
18236  if test "x$ac_ct_OTOOL" = x; then
18237    OTOOL=":"
18238  else
18239    case $cross_compiling:$ac_tool_warned in
18240yes:)
18241{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
18242$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
18243ac_tool_warned=yes ;;
18244esac
18245    OTOOL=$ac_ct_OTOOL
18246  fi
18247else
18248  OTOOL="$ac_cv_prog_OTOOL"
18249fi
18250
18251    if test -n "$ac_tool_prefix"; then
18252  # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args.
18253set dummy ${ac_tool_prefix}otool64; ac_word=$2
18254{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18255$as_echo_n "checking for $ac_word... " >&6; }
18256if ${ac_cv_prog_OTOOL64+:} false; then :
18257  $as_echo_n "(cached) " >&6
18258else
18259  if test -n "$OTOOL64"; then
18260  ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test.
18261else
18262as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18263for as_dir in $PATH
18264do
18265  IFS=$as_save_IFS
18266  test -z "$as_dir" && as_dir=.
18267    for ac_exec_ext in '' $ac_executable_extensions; do
18268  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18269    ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64"
18270    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18271    break 2
18272  fi
18273done
18274  done
18275IFS=$as_save_IFS
18276
18277fi
18278fi
18279OTOOL64=$ac_cv_prog_OTOOL64
18280if test -n "$OTOOL64"; then
18281  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5
18282$as_echo "$OTOOL64" >&6; }
18283else
18284  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18285$as_echo "no" >&6; }
18286fi
18287
18288
18289fi
18290if test -z "$ac_cv_prog_OTOOL64"; then
18291  ac_ct_OTOOL64=$OTOOL64
18292  # Extract the first word of "otool64", so it can be a program name with args.
18293set dummy otool64; ac_word=$2
18294{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18295$as_echo_n "checking for $ac_word... " >&6; }
18296if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then :
18297  $as_echo_n "(cached) " >&6
18298else
18299  if test -n "$ac_ct_OTOOL64"; then
18300  ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test.
18301else
18302as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18303for as_dir in $PATH
18304do
18305  IFS=$as_save_IFS
18306  test -z "$as_dir" && as_dir=.
18307    for ac_exec_ext in '' $ac_executable_extensions; do
18308  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18309    ac_cv_prog_ac_ct_OTOOL64="otool64"
18310    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18311    break 2
18312  fi
18313done
18314  done
18315IFS=$as_save_IFS
18316
18317fi
18318fi
18319ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64
18320if test -n "$ac_ct_OTOOL64"; then
18321  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5
18322$as_echo "$ac_ct_OTOOL64" >&6; }
18323else
18324  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18325$as_echo "no" >&6; }
18326fi
18327
18328  if test "x$ac_ct_OTOOL64" = x; then
18329    OTOOL64=":"
18330  else
18331    case $cross_compiling:$ac_tool_warned in
18332yes:)
18333{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
18334$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
18335ac_tool_warned=yes ;;
18336esac
18337    OTOOL64=$ac_ct_OTOOL64
18338  fi
18339else
18340  OTOOL64="$ac_cv_prog_OTOOL64"
18341fi
18342
18343
18344
18345
18346
18347
18348
18349
18350
18351
18352
18353
18354
18355
18356
18357
18358
18359
18360
18361
18362
18363
18364
18365
18366
18367
18368
18369    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5
18370$as_echo_n "checking for -single_module linker flag... " >&6; }
18371if ${lt_cv_apple_cc_single_mod+:} false; then :
18372  $as_echo_n "(cached) " >&6
18373else
18374  lt_cv_apple_cc_single_mod=no
18375      if test -z "$LT_MULTI_MODULE"; then
18376	# By default we will add the -single_module flag. You can override
18377	# by either setting the environment variable LT_MULTI_MODULE
18378	# non-empty at configure time, or by adding -multi_module to the
18379	# link flags.
18380	rm -rf libconftest.dylib*
18381	echo "int foo(void){return 1;}" > conftest.c
18382	echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
18383-dynamiclib -Wl,-single_module conftest.c" >&5
18384	$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
18385	  -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
18386        _lt_result=$?
18387	# If there is a non-empty error log, and "single_module"
18388	# appears in it, assume the flag caused a linker warning
18389        if test -s conftest.err && $GREP single_module conftest.err; then
18390	  cat conftest.err >&5
18391	# Otherwise, if the output was created with a 0 exit code from
18392	# the compiler, it worked.
18393	elif test -f libconftest.dylib && test 0 = "$_lt_result"; then
18394	  lt_cv_apple_cc_single_mod=yes
18395	else
18396	  cat conftest.err >&5
18397	fi
18398	rm -rf libconftest.dylib*
18399	rm -f conftest.*
18400      fi
18401fi
18402{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5
18403$as_echo "$lt_cv_apple_cc_single_mod" >&6; }
18404
18405    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5
18406$as_echo_n "checking for -exported_symbols_list linker flag... " >&6; }
18407if ${lt_cv_ld_exported_symbols_list+:} false; then :
18408  $as_echo_n "(cached) " >&6
18409else
18410  lt_cv_ld_exported_symbols_list=no
18411      save_LDFLAGS=$LDFLAGS
18412      echo "_main" > conftest.sym
18413      LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
18414      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18415/* end confdefs.h.  */
18416
18417int
18418main ()
18419{
18420
18421  ;
18422  return 0;
18423}
18424_ACEOF
18425if ac_fn_c_try_link "$LINENO"; then :
18426  lt_cv_ld_exported_symbols_list=yes
18427else
18428  lt_cv_ld_exported_symbols_list=no
18429fi
18430rm -f core conftest.err conftest.$ac_objext \
18431    conftest$ac_exeext conftest.$ac_ext
18432	LDFLAGS=$save_LDFLAGS
18433
18434fi
18435{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5
18436$as_echo "$lt_cv_ld_exported_symbols_list" >&6; }
18437
18438    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5
18439$as_echo_n "checking for -force_load linker flag... " >&6; }
18440if ${lt_cv_ld_force_load+:} false; then :
18441  $as_echo_n "(cached) " >&6
18442else
18443  lt_cv_ld_force_load=no
18444      cat > conftest.c << _LT_EOF
18445int forced_loaded() { return 2;}
18446_LT_EOF
18447      echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5
18448      $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
18449      echo "$AR cru libconftest.a conftest.o" >&5
18450      $AR cru libconftest.a conftest.o 2>&5
18451      echo "$RANLIB libconftest.a" >&5
18452      $RANLIB libconftest.a 2>&5
18453      cat > conftest.c << _LT_EOF
18454int main() { return 0;}
18455_LT_EOF
18456      echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5
18457      $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
18458      _lt_result=$?
18459      if test -s conftest.err && $GREP force_load conftest.err; then
18460	cat conftest.err >&5
18461      elif test -f conftest && test 0 = "$_lt_result" && $GREP forced_load conftest >/dev/null 2>&1; then
18462	lt_cv_ld_force_load=yes
18463      else
18464	cat conftest.err >&5
18465      fi
18466        rm -f conftest.err libconftest.a conftest conftest.c
18467        rm -rf conftest.dSYM
18468
18469fi
18470{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5
18471$as_echo "$lt_cv_ld_force_load" >&6; }
18472    case $host_os in
18473    rhapsody* | darwin1.[012])
18474      _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;;
18475    darwin1.*)
18476      _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;;
18477    darwin*) # darwin 5.x on
18478      # if running on 10.5 or later, the deployment target defaults
18479      # to the OS version, if on x86, and 10.4, the deployment
18480      # target defaults to 10.4. Don't you love it?
18481      case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
18482	10.0,*86*-darwin8*|10.0,*-darwin[91]*)
18483	  _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;;
18484	10.[012][,.]*)
18485	  _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;;
18486	10.*)
18487	  _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;;
18488      esac
18489    ;;
18490  esac
18491    if test yes = "$lt_cv_apple_cc_single_mod"; then
18492      _lt_dar_single_mod='$single_module'
18493    fi
18494    if test yes = "$lt_cv_ld_exported_symbols_list"; then
18495      _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym'
18496    else
18497      _lt_dar_export_syms='~$NMEDIT -s $output_objdir/$libname-symbols.expsym $lib'
18498    fi
18499    if test : != "$DSYMUTIL" && test no = "$lt_cv_ld_force_load"; then
18500      _lt_dsymutil='~$DSYMUTIL $lib || :'
18501    else
18502      _lt_dsymutil=
18503    fi
18504    ;;
18505  esac
18506
18507# func_munge_path_list VARIABLE PATH
18508# -----------------------------------
18509# VARIABLE is name of variable containing _space_ separated list of
18510# directories to be munged by the contents of PATH, which is string
18511# having a format:
18512# "DIR[:DIR]:"
18513#       string "DIR[ DIR]" will be prepended to VARIABLE
18514# ":DIR[:DIR]"
18515#       string "DIR[ DIR]" will be appended to VARIABLE
18516# "DIRP[:DIRP]::[DIRA:]DIRA"
18517#       string "DIRP[ DIRP]" will be prepended to VARIABLE and string
18518#       "DIRA[ DIRA]" will be appended to VARIABLE
18519# "DIR[:DIR]"
18520#       VARIABLE will be replaced by "DIR[ DIR]"
18521func_munge_path_list ()
18522{
18523    case x$2 in
18524    x)
18525        ;;
18526    *:)
18527        eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\"
18528        ;;
18529    x:*)
18530        eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\"
18531        ;;
18532    *::*)
18533        eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\"
18534        eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\"
18535        ;;
18536    *)
18537        eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\"
18538        ;;
18539    esac
18540}
18541
18542for ac_header in dlfcn.h
18543do :
18544  ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
18545"
18546if test "x$ac_cv_header_dlfcn_h" = xyes; then :
18547  cat >>confdefs.h <<_ACEOF
18548#define HAVE_DLFCN_H 1
18549_ACEOF
18550
18551fi
18552
18553done
18554
18555
18556
18557
18558
18559# Set options
18560
18561
18562
18563        enable_dlopen=no
18564
18565
18566  enable_win32_dll=no
18567
18568
18569
18570  # Check whether --enable-static was given.
18571if test "${enable_static+set}" = set; then :
18572  enableval=$enable_static; p=${PACKAGE-default}
18573    case $enableval in
18574    yes) enable_static=yes ;;
18575    no) enable_static=no ;;
18576    *)
18577     enable_static=no
18578      # Look at the argument we got.  We use all the common list separators.
18579      lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
18580      for pkg in $enableval; do
18581	IFS=$lt_save_ifs
18582	if test "X$pkg" = "X$p"; then
18583	  enable_static=yes
18584	fi
18585      done
18586      IFS=$lt_save_ifs
18587      ;;
18588    esac
18589else
18590  enable_static=yes
18591fi
18592
18593
18594
18595
18596
18597
18598
18599
18600
18601
18602# Check whether --with-pic was given.
18603if test "${with_pic+set}" = set; then :
18604  withval=$with_pic; lt_p=${PACKAGE-default}
18605    case $withval in
18606    yes|no) pic_mode=$withval ;;
18607    *)
18608      pic_mode=default
18609      # Look at the argument we got.  We use all the common list separators.
18610      lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
18611      for lt_pkg in $withval; do
18612	IFS=$lt_save_ifs
18613	if test "X$lt_pkg" = "X$lt_p"; then
18614	  pic_mode=yes
18615	fi
18616      done
18617      IFS=$lt_save_ifs
18618      ;;
18619    esac
18620else
18621  pic_mode=default
18622fi
18623
18624
18625
18626
18627
18628
18629
18630
18631  # Check whether --enable-fast-install was given.
18632if test "${enable_fast_install+set}" = set; then :
18633  enableval=$enable_fast_install; p=${PACKAGE-default}
18634    case $enableval in
18635    yes) enable_fast_install=yes ;;
18636    no) enable_fast_install=no ;;
18637    *)
18638      enable_fast_install=no
18639      # Look at the argument we got.  We use all the common list separators.
18640      lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
18641      for pkg in $enableval; do
18642	IFS=$lt_save_ifs
18643	if test "X$pkg" = "X$p"; then
18644	  enable_fast_install=yes
18645	fi
18646      done
18647      IFS=$lt_save_ifs
18648      ;;
18649    esac
18650else
18651  enable_fast_install=yes
18652fi
18653
18654
18655
18656
18657
18658
18659
18660
18661  shared_archive_member_spec=
18662case $host,$enable_shared in
18663power*-*-aix[5-9]*,yes)
18664  { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variant of shared library versioning to provide" >&5
18665$as_echo_n "checking which variant of shared library versioning to provide... " >&6; }
18666
18667# Check whether --with-aix-soname was given.
18668if test "${with_aix_soname+set}" = set; then :
18669  withval=$with_aix_soname; case $withval in
18670    aix|svr4|both)
18671      ;;
18672    *)
18673      as_fn_error $? "Unknown argument to --with-aix-soname" "$LINENO" 5
18674      ;;
18675    esac
18676    lt_cv_with_aix_soname=$with_aix_soname
18677else
18678  if ${lt_cv_with_aix_soname+:} false; then :
18679  $as_echo_n "(cached) " >&6
18680else
18681  lt_cv_with_aix_soname=aix
18682fi
18683
18684    with_aix_soname=$lt_cv_with_aix_soname
18685fi
18686
18687  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_aix_soname" >&5
18688$as_echo "$with_aix_soname" >&6; }
18689  if test aix != "$with_aix_soname"; then
18690    # For the AIX way of multilib, we name the shared archive member
18691    # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o',
18692    # and 'shr.imp' or 'shr_64.imp', respectively, for the Import File.
18693    # Even when GNU compilers ignore OBJECT_MODE but need '-maix64' flag,
18694    # the AIX toolchain works better with OBJECT_MODE set (default 32).
18695    if test 64 = "${OBJECT_MODE-32}"; then
18696      shared_archive_member_spec=shr_64
18697    else
18698      shared_archive_member_spec=shr
18699    fi
18700  fi
18701  ;;
18702*)
18703  with_aix_soname=aix
18704  ;;
18705esac
18706
18707
18708
18709
18710
18711
18712
18713
18714
18715
18716# This can be used to rebuild libtool when needed
18717LIBTOOL_DEPS=$ltmain
18718
18719# Always use our own libtool.
18720LIBTOOL='$(SHELL) $(top_builddir)/libtool'
18721
18722
18723
18724
18725
18726
18727
18728
18729
18730
18731
18732
18733
18734
18735
18736
18737
18738
18739
18740
18741
18742
18743
18744
18745
18746
18747
18748
18749
18750
18751test -z "$LN_S" && LN_S="ln -s"
18752
18753
18754
18755
18756
18757
18758
18759
18760
18761
18762
18763
18764
18765
18766if test -n "${ZSH_VERSION+set}"; then
18767   setopt NO_GLOB_SUBST
18768fi
18769
18770{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5
18771$as_echo_n "checking for objdir... " >&6; }
18772if ${lt_cv_objdir+:} false; then :
18773  $as_echo_n "(cached) " >&6
18774else
18775  rm -f .libs 2>/dev/null
18776mkdir .libs 2>/dev/null
18777if test -d .libs; then
18778  lt_cv_objdir=.libs
18779else
18780  # MS-DOS does not allow filenames that begin with a dot.
18781  lt_cv_objdir=_libs
18782fi
18783rmdir .libs 2>/dev/null
18784fi
18785{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5
18786$as_echo "$lt_cv_objdir" >&6; }
18787objdir=$lt_cv_objdir
18788
18789
18790
18791
18792
18793cat >>confdefs.h <<_ACEOF
18794#define LT_OBJDIR "$lt_cv_objdir/"
18795_ACEOF
18796
18797
18798
18799
18800case $host_os in
18801aix3*)
18802  # AIX sometimes has problems with the GCC collect2 program.  For some
18803  # reason, if we set the COLLECT_NAMES environment variable, the problems
18804  # vanish in a puff of smoke.
18805  if test set != "${COLLECT_NAMES+set}"; then
18806    COLLECT_NAMES=
18807    export COLLECT_NAMES
18808  fi
18809  ;;
18810esac
18811
18812# Global variables:
18813ofile=libtool
18814can_build_shared=yes
18815
18816# All known linkers require a '.a' archive for static linking (except MSVC,
18817# which needs '.lib').
18818libext=a
18819
18820with_gnu_ld=$lt_cv_prog_gnu_ld
18821
18822old_CC=$CC
18823old_CFLAGS=$CFLAGS
18824
18825# Set sane defaults for various variables
18826test -z "$CC" && CC=cc
18827test -z "$LTCC" && LTCC=$CC
18828test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
18829test -z "$LD" && LD=ld
18830test -z "$ac_objext" && ac_objext=o
18831
18832func_cc_basename $compiler
18833cc_basename=$func_cc_basename_result
18834
18835
18836# Only perform the check for file, if the check method requires it
18837test -z "$MAGIC_CMD" && MAGIC_CMD=file
18838case $deplibs_check_method in
18839file_magic*)
18840  if test "$file_magic_cmd" = '$MAGIC_CMD'; then
18841    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5
18842$as_echo_n "checking for ${ac_tool_prefix}file... " >&6; }
18843if ${lt_cv_path_MAGIC_CMD+:} false; then :
18844  $as_echo_n "(cached) " >&6
18845else
18846  case $MAGIC_CMD in
18847[\\/*] |  ?:[\\/]*)
18848  lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path.
18849  ;;
18850*)
18851  lt_save_MAGIC_CMD=$MAGIC_CMD
18852  lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
18853  ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
18854  for ac_dir in $ac_dummy; do
18855    IFS=$lt_save_ifs
18856    test -z "$ac_dir" && ac_dir=.
18857    if test -f "$ac_dir/${ac_tool_prefix}file"; then
18858      lt_cv_path_MAGIC_CMD=$ac_dir/"${ac_tool_prefix}file"
18859      if test -n "$file_magic_test_file"; then
18860	case $deplibs_check_method in
18861	"file_magic "*)
18862	  file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
18863	  MAGIC_CMD=$lt_cv_path_MAGIC_CMD
18864	  if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
18865	    $EGREP "$file_magic_regex" > /dev/null; then
18866	    :
18867	  else
18868	    cat <<_LT_EOF 1>&2
18869
18870*** Warning: the command libtool uses to detect shared libraries,
18871*** $file_magic_cmd, produces output that libtool cannot recognize.
18872*** The result is that libtool may fail to recognize shared libraries
18873*** as such.  This will affect the creation of libtool libraries that
18874*** depend on shared libraries, but programs linked with such libtool
18875*** libraries will work regardless of this problem.  Nevertheless, you
18876*** may want to report the problem to your system manager and/or to
18877*** bug-libtool@gnu.org
18878
18879_LT_EOF
18880	  fi ;;
18881	esac
18882      fi
18883      break
18884    fi
18885  done
18886  IFS=$lt_save_ifs
18887  MAGIC_CMD=$lt_save_MAGIC_CMD
18888  ;;
18889esac
18890fi
18891
18892MAGIC_CMD=$lt_cv_path_MAGIC_CMD
18893if test -n "$MAGIC_CMD"; then
18894  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
18895$as_echo "$MAGIC_CMD" >&6; }
18896else
18897  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18898$as_echo "no" >&6; }
18899fi
18900
18901
18902
18903
18904
18905if test -z "$lt_cv_path_MAGIC_CMD"; then
18906  if test -n "$ac_tool_prefix"; then
18907    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5
18908$as_echo_n "checking for file... " >&6; }
18909if ${lt_cv_path_MAGIC_CMD+:} false; then :
18910  $as_echo_n "(cached) " >&6
18911else
18912  case $MAGIC_CMD in
18913[\\/*] |  ?:[\\/]*)
18914  lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path.
18915  ;;
18916*)
18917  lt_save_MAGIC_CMD=$MAGIC_CMD
18918  lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
18919  ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
18920  for ac_dir in $ac_dummy; do
18921    IFS=$lt_save_ifs
18922    test -z "$ac_dir" && ac_dir=.
18923    if test -f "$ac_dir/file"; then
18924      lt_cv_path_MAGIC_CMD=$ac_dir/"file"
18925      if test -n "$file_magic_test_file"; then
18926	case $deplibs_check_method in
18927	"file_magic "*)
18928	  file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
18929	  MAGIC_CMD=$lt_cv_path_MAGIC_CMD
18930	  if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
18931	    $EGREP "$file_magic_regex" > /dev/null; then
18932	    :
18933	  else
18934	    cat <<_LT_EOF 1>&2
18935
18936*** Warning: the command libtool uses to detect shared libraries,
18937*** $file_magic_cmd, produces output that libtool cannot recognize.
18938*** The result is that libtool may fail to recognize shared libraries
18939*** as such.  This will affect the creation of libtool libraries that
18940*** depend on shared libraries, but programs linked with such libtool
18941*** libraries will work regardless of this problem.  Nevertheless, you
18942*** may want to report the problem to your system manager and/or to
18943*** bug-libtool@gnu.org
18944
18945_LT_EOF
18946	  fi ;;
18947	esac
18948      fi
18949      break
18950    fi
18951  done
18952  IFS=$lt_save_ifs
18953  MAGIC_CMD=$lt_save_MAGIC_CMD
18954  ;;
18955esac
18956fi
18957
18958MAGIC_CMD=$lt_cv_path_MAGIC_CMD
18959if test -n "$MAGIC_CMD"; then
18960  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
18961$as_echo "$MAGIC_CMD" >&6; }
18962else
18963  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18964$as_echo "no" >&6; }
18965fi
18966
18967
18968  else
18969    MAGIC_CMD=:
18970  fi
18971fi
18972
18973  fi
18974  ;;
18975esac
18976
18977# Use C for the default configuration in the libtool script
18978
18979lt_save_CC=$CC
18980ac_ext=c
18981ac_cpp='$CPP $CPPFLAGS'
18982ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
18983ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
18984ac_compiler_gnu=$ac_cv_c_compiler_gnu
18985
18986
18987# Source file extension for C test sources.
18988ac_ext=c
18989
18990# Object file extension for compiled C test sources.
18991objext=o
18992objext=$objext
18993
18994# Code to be used in simple compile tests
18995lt_simple_compile_test_code="int some_variable = 0;"
18996
18997# Code to be used in simple link tests
18998lt_simple_link_test_code='int main(){return(0);}'
18999
19000
19001
19002
19003
19004
19005
19006# If no C compiler was specified, use CC.
19007LTCC=${LTCC-"$CC"}
19008
19009# If no C compiler flags were specified, use CFLAGS.
19010LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
19011
19012# Allow CC to be a program name with arguments.
19013compiler=$CC
19014
19015# Save the default compiler, since it gets overwritten when the other
19016# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
19017compiler_DEFAULT=$CC
19018
19019# save warnings/boilerplate of simple test code
19020ac_outfile=conftest.$ac_objext
19021echo "$lt_simple_compile_test_code" >conftest.$ac_ext
19022eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
19023_lt_compiler_boilerplate=`cat conftest.err`
19024$RM conftest*
19025
19026ac_outfile=conftest.$ac_objext
19027echo "$lt_simple_link_test_code" >conftest.$ac_ext
19028eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
19029_lt_linker_boilerplate=`cat conftest.err`
19030$RM -r conftest*
19031
19032
19033## CAVEAT EMPTOR:
19034## There is no encapsulation within the following macros, do not change
19035## the running order or otherwise move them around unless you know exactly
19036## what you are doing...
19037if test -n "$compiler"; then
19038
19039lt_prog_compiler_no_builtin_flag=
19040
19041if test yes = "$GCC"; then
19042  case $cc_basename in
19043  nvcc*)
19044    lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;;
19045  *)
19046    lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;;
19047  esac
19048
19049  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
19050$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; }
19051if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then :
19052  $as_echo_n "(cached) " >&6
19053else
19054  lt_cv_prog_compiler_rtti_exceptions=no
19055   ac_outfile=conftest.$ac_objext
19056   echo "$lt_simple_compile_test_code" > conftest.$ac_ext
19057   lt_compiler_flag="-fno-rtti -fno-exceptions"  ## exclude from sc_useless_quotes_in_assignment
19058   # Insert the option either (1) after the last *FLAGS variable, or
19059   # (2) before a word containing "conftest.", or (3) at the end.
19060   # Note that $ac_compile itself does not contain backslashes and begins
19061   # with a dollar sign (not a hyphen), so the echo should work correctly.
19062   # The option is referenced via a variable to avoid confusing sed.
19063   lt_compile=`echo "$ac_compile" | $SED \
19064   -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
19065   -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
19066   -e 's:$: $lt_compiler_flag:'`
19067   (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
19068   (eval "$lt_compile" 2>conftest.err)
19069   ac_status=$?
19070   cat conftest.err >&5
19071   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19072   if (exit $ac_status) && test -s "$ac_outfile"; then
19073     # The compiler can only warn and ignore the option if not recognized
19074     # So say no if there are warnings other than the usual output.
19075     $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
19076     $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
19077     if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
19078       lt_cv_prog_compiler_rtti_exceptions=yes
19079     fi
19080   fi
19081   $RM conftest*
19082
19083fi
19084{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
19085$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; }
19086
19087if test yes = "$lt_cv_prog_compiler_rtti_exceptions"; then
19088    lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions"
19089else
19090    :
19091fi
19092
19093fi
19094
19095
19096
19097
19098
19099
19100  lt_prog_compiler_wl=
19101lt_prog_compiler_pic=
19102lt_prog_compiler_static=
19103
19104
19105  if test yes = "$GCC"; then
19106    lt_prog_compiler_wl='-Wl,'
19107    lt_prog_compiler_static='-static'
19108
19109    case $host_os in
19110      aix*)
19111      # All AIX code is PIC.
19112      if test ia64 = "$host_cpu"; then
19113	# AIX 5 now supports IA64 processor
19114	lt_prog_compiler_static='-Bstatic'
19115      fi
19116      lt_prog_compiler_pic='-fPIC'
19117      ;;
19118
19119    amigaos*)
19120      case $host_cpu in
19121      powerpc)
19122            # see comment about AmigaOS4 .so support
19123            lt_prog_compiler_pic='-fPIC'
19124        ;;
19125      m68k)
19126            # FIXME: we need at least 68020 code to build shared libraries, but
19127            # adding the '-m68020' flag to GCC prevents building anything better,
19128            # like '-m68040'.
19129            lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4'
19130        ;;
19131      esac
19132      ;;
19133
19134    beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
19135      # PIC is the default for these OSes.
19136      ;;
19137
19138    mingw* | cygwin* | pw32* | os2* | cegcc*)
19139      # This hack is so that the source file can tell whether it is being
19140      # built for inclusion in a dll (and should export symbols for example).
19141      # Although the cygwin gcc ignores -fPIC, still need this for old-style
19142      # (--disable-auto-import) libraries
19143      lt_prog_compiler_pic='-DDLL_EXPORT'
19144      case $host_os in
19145      os2*)
19146	lt_prog_compiler_static='$wl-static'
19147	;;
19148      esac
19149      ;;
19150
19151    darwin* | rhapsody*)
19152      # PIC is the default on this platform
19153      # Common symbols not allowed in MH_DYLIB files
19154      lt_prog_compiler_pic='-fno-common'
19155      ;;
19156
19157    haiku*)
19158      # PIC is the default for Haiku.
19159      # The "-static" flag exists, but is broken.
19160      lt_prog_compiler_static=
19161      ;;
19162
19163    hpux*)
19164      # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
19165      # PA HP-UX.  On IA64 HP-UX, PIC is the default but the pic flag
19166      # sets the default TLS model and affects inlining.
19167      case $host_cpu in
19168      hppa*64*)
19169	# +Z the default
19170	;;
19171      *)
19172	lt_prog_compiler_pic='-fPIC'
19173	;;
19174      esac
19175      ;;
19176
19177    interix[3-9]*)
19178      # Interix 3.x gcc -fpic/-fPIC options generate broken code.
19179      # Instead, we relocate shared libraries at runtime.
19180      ;;
19181
19182    msdosdjgpp*)
19183      # Just because we use GCC doesn't mean we suddenly get shared libraries
19184      # on systems that don't support them.
19185      lt_prog_compiler_can_build_shared=no
19186      enable_shared=no
19187      ;;
19188
19189    *nto* | *qnx*)
19190      # QNX uses GNU C++, but need to define -shared option too, otherwise
19191      # it will coredump.
19192      lt_prog_compiler_pic='-fPIC -shared'
19193      ;;
19194
19195    sysv4*MP*)
19196      if test -d /usr/nec; then
19197	lt_prog_compiler_pic=-Kconform_pic
19198      fi
19199      ;;
19200
19201    *)
19202      lt_prog_compiler_pic='-fPIC'
19203      ;;
19204    esac
19205
19206    case $cc_basename in
19207    nvcc*) # Cuda Compiler Driver 2.2
19208      lt_prog_compiler_wl='-Xlinker '
19209      if test -n "$lt_prog_compiler_pic"; then
19210        lt_prog_compiler_pic="-Xcompiler $lt_prog_compiler_pic"
19211      fi
19212      ;;
19213    esac
19214  else
19215    # PORTME Check for flag to pass linker flags through the system compiler.
19216    case $host_os in
19217    aix*)
19218      lt_prog_compiler_wl='-Wl,'
19219      if test ia64 = "$host_cpu"; then
19220	# AIX 5 now supports IA64 processor
19221	lt_prog_compiler_static='-Bstatic'
19222      else
19223	lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp'
19224      fi
19225      ;;
19226
19227    darwin* | rhapsody*)
19228      # PIC is the default on this platform
19229      # Common symbols not allowed in MH_DYLIB files
19230      lt_prog_compiler_pic='-fno-common'
19231      case $cc_basename in
19232      nagfor*)
19233        # NAG Fortran compiler
19234        lt_prog_compiler_wl='-Wl,-Wl,,'
19235        lt_prog_compiler_pic='-PIC'
19236        lt_prog_compiler_static='-Bstatic'
19237        ;;
19238      esac
19239      ;;
19240
19241    mingw* | cygwin* | pw32* | os2* | cegcc*)
19242      # This hack is so that the source file can tell whether it is being
19243      # built for inclusion in a dll (and should export symbols for example).
19244      lt_prog_compiler_pic='-DDLL_EXPORT'
19245      case $host_os in
19246      os2*)
19247	lt_prog_compiler_static='$wl-static'
19248	;;
19249      esac
19250      ;;
19251
19252    hpux9* | hpux10* | hpux11*)
19253      lt_prog_compiler_wl='-Wl,'
19254      # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
19255      # not for PA HP-UX.
19256      case $host_cpu in
19257      hppa*64*|ia64*)
19258	# +Z the default
19259	;;
19260      *)
19261	lt_prog_compiler_pic='+Z'
19262	;;
19263      esac
19264      # Is there a better lt_prog_compiler_static that works with the bundled CC?
19265      lt_prog_compiler_static='$wl-a ${wl}archive'
19266      ;;
19267
19268    irix5* | irix6* | nonstopux*)
19269      lt_prog_compiler_wl='-Wl,'
19270      # PIC (with -KPIC) is the default.
19271      lt_prog_compiler_static='-non_shared'
19272      ;;
19273
19274    linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
19275      case $cc_basename in
19276      # old Intel for x86_64, which still supported -KPIC.
19277      ecc*)
19278	lt_prog_compiler_wl='-Wl,'
19279	lt_prog_compiler_pic='-KPIC'
19280	lt_prog_compiler_static='-static'
19281        ;;
19282      # icc used to be incompatible with GCC.
19283      # ICC 10 doesn't accept -KPIC any more.
19284      icc* | ifort*)
19285	lt_prog_compiler_wl='-Wl,'
19286	lt_prog_compiler_pic='-fPIC'
19287	lt_prog_compiler_static='-static'
19288        ;;
19289      # Lahey Fortran 8.1.
19290      lf95*)
19291	lt_prog_compiler_wl='-Wl,'
19292	lt_prog_compiler_pic='--shared'
19293	lt_prog_compiler_static='--static'
19294	;;
19295      nagfor*)
19296	# NAG Fortran compiler
19297	lt_prog_compiler_wl='-Wl,-Wl,,'
19298	lt_prog_compiler_pic='-PIC'
19299	lt_prog_compiler_static='-Bstatic'
19300	;;
19301      tcc*)
19302	# Fabrice Bellard et al's Tiny C Compiler
19303	lt_prog_compiler_wl='-Wl,'
19304	lt_prog_compiler_pic='-fPIC'
19305	lt_prog_compiler_static='-static'
19306	;;
19307      pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
19308        # Portland Group compilers (*not* the Pentium gcc compiler,
19309	# which looks to be a dead project)
19310	lt_prog_compiler_wl='-Wl,'
19311	lt_prog_compiler_pic='-fpic'
19312	lt_prog_compiler_static='-Bstatic'
19313        ;;
19314      ccc*)
19315        lt_prog_compiler_wl='-Wl,'
19316        # All Alpha code is PIC.
19317        lt_prog_compiler_static='-non_shared'
19318        ;;
19319      xl* | bgxl* | bgf* | mpixl*)
19320	# IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
19321	lt_prog_compiler_wl='-Wl,'
19322	lt_prog_compiler_pic='-qpic'
19323	lt_prog_compiler_static='-qstaticlink'
19324	;;
19325      *)
19326	case `$CC -V 2>&1 | sed 5q` in
19327	*Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [1-7].* | *Sun*Fortran*\ 8.[0-3]*)
19328	  # Sun Fortran 8.3 passes all unrecognized flags to the linker
19329	  lt_prog_compiler_pic='-KPIC'
19330	  lt_prog_compiler_static='-Bstatic'
19331	  lt_prog_compiler_wl=''
19332	  ;;
19333	*Sun\ F* | *Sun*Fortran*)
19334	  lt_prog_compiler_pic='-KPIC'
19335	  lt_prog_compiler_static='-Bstatic'
19336	  lt_prog_compiler_wl='-Qoption ld '
19337	  ;;
19338	*Sun\ C*)
19339	  # Sun C 5.9
19340	  lt_prog_compiler_pic='-KPIC'
19341	  lt_prog_compiler_static='-Bstatic'
19342	  lt_prog_compiler_wl='-Wl,'
19343	  ;;
19344        *Intel*\ [CF]*Compiler*)
19345	  lt_prog_compiler_wl='-Wl,'
19346	  lt_prog_compiler_pic='-fPIC'
19347	  lt_prog_compiler_static='-static'
19348	  ;;
19349	*Portland\ Group*)
19350	  lt_prog_compiler_wl='-Wl,'
19351	  lt_prog_compiler_pic='-fpic'
19352	  lt_prog_compiler_static='-Bstatic'
19353	  ;;
19354	esac
19355	;;
19356      esac
19357      ;;
19358
19359    newsos6)
19360      lt_prog_compiler_pic='-KPIC'
19361      lt_prog_compiler_static='-Bstatic'
19362      ;;
19363
19364    *nto* | *qnx*)
19365      # QNX uses GNU C++, but need to define -shared option too, otherwise
19366      # it will coredump.
19367      lt_prog_compiler_pic='-fPIC -shared'
19368      ;;
19369
19370    osf3* | osf4* | osf5*)
19371      lt_prog_compiler_wl='-Wl,'
19372      # All OSF/1 code is PIC.
19373      lt_prog_compiler_static='-non_shared'
19374      ;;
19375
19376    rdos*)
19377      lt_prog_compiler_static='-non_shared'
19378      ;;
19379
19380    solaris*)
19381      lt_prog_compiler_pic='-KPIC'
19382      lt_prog_compiler_static='-Bstatic'
19383      case $cc_basename in
19384      f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
19385	lt_prog_compiler_wl='-Qoption ld ';;
19386      *)
19387	lt_prog_compiler_wl='-Wl,';;
19388      esac
19389      ;;
19390
19391    sunos4*)
19392      lt_prog_compiler_wl='-Qoption ld '
19393      lt_prog_compiler_pic='-PIC'
19394      lt_prog_compiler_static='-Bstatic'
19395      ;;
19396
19397    sysv4 | sysv4.2uw2* | sysv4.3*)
19398      lt_prog_compiler_wl='-Wl,'
19399      lt_prog_compiler_pic='-KPIC'
19400      lt_prog_compiler_static='-Bstatic'
19401      ;;
19402
19403    sysv4*MP*)
19404      if test -d /usr/nec; then
19405	lt_prog_compiler_pic='-Kconform_pic'
19406	lt_prog_compiler_static='-Bstatic'
19407      fi
19408      ;;
19409
19410    sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
19411      lt_prog_compiler_wl='-Wl,'
19412      lt_prog_compiler_pic='-KPIC'
19413      lt_prog_compiler_static='-Bstatic'
19414      ;;
19415
19416    unicos*)
19417      lt_prog_compiler_wl='-Wl,'
19418      lt_prog_compiler_can_build_shared=no
19419      ;;
19420
19421    uts4*)
19422      lt_prog_compiler_pic='-pic'
19423      lt_prog_compiler_static='-Bstatic'
19424      ;;
19425
19426    *)
19427      lt_prog_compiler_can_build_shared=no
19428      ;;
19429    esac
19430  fi
19431
19432case $host_os in
19433  # For platforms that do not support PIC, -DPIC is meaningless:
19434  *djgpp*)
19435    lt_prog_compiler_pic=
19436    ;;
19437  *)
19438    lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
19439    ;;
19440esac
19441
19442{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
19443$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
19444if ${lt_cv_prog_compiler_pic+:} false; then :
19445  $as_echo_n "(cached) " >&6
19446else
19447  lt_cv_prog_compiler_pic=$lt_prog_compiler_pic
19448fi
19449{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5
19450$as_echo "$lt_cv_prog_compiler_pic" >&6; }
19451lt_prog_compiler_pic=$lt_cv_prog_compiler_pic
19452
19453#
19454# Check to make sure the PIC flag actually works.
19455#
19456if test -n "$lt_prog_compiler_pic"; then
19457  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
19458$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; }
19459if ${lt_cv_prog_compiler_pic_works+:} false; then :
19460  $as_echo_n "(cached) " >&6
19461else
19462  lt_cv_prog_compiler_pic_works=no
19463   ac_outfile=conftest.$ac_objext
19464   echo "$lt_simple_compile_test_code" > conftest.$ac_ext
19465   lt_compiler_flag="$lt_prog_compiler_pic -DPIC"  ## exclude from sc_useless_quotes_in_assignment
19466   # Insert the option either (1) after the last *FLAGS variable, or
19467   # (2) before a word containing "conftest.", or (3) at the end.
19468   # Note that $ac_compile itself does not contain backslashes and begins
19469   # with a dollar sign (not a hyphen), so the echo should work correctly.
19470   # The option is referenced via a variable to avoid confusing sed.
19471   lt_compile=`echo "$ac_compile" | $SED \
19472   -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
19473   -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
19474   -e 's:$: $lt_compiler_flag:'`
19475   (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
19476   (eval "$lt_compile" 2>conftest.err)
19477   ac_status=$?
19478   cat conftest.err >&5
19479   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19480   if (exit $ac_status) && test -s "$ac_outfile"; then
19481     # The compiler can only warn and ignore the option if not recognized
19482     # So say no if there are warnings other than the usual output.
19483     $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
19484     $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
19485     if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
19486       lt_cv_prog_compiler_pic_works=yes
19487     fi
19488   fi
19489   $RM conftest*
19490
19491fi
19492{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5
19493$as_echo "$lt_cv_prog_compiler_pic_works" >&6; }
19494
19495if test yes = "$lt_cv_prog_compiler_pic_works"; then
19496    case $lt_prog_compiler_pic in
19497     "" | " "*) ;;
19498     *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;;
19499     esac
19500else
19501    lt_prog_compiler_pic=
19502     lt_prog_compiler_can_build_shared=no
19503fi
19504
19505fi
19506
19507
19508
19509
19510
19511
19512
19513
19514
19515
19516
19517#
19518# Check to make sure the static flag actually works.
19519#
19520wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\"
19521{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5
19522$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
19523if ${lt_cv_prog_compiler_static_works+:} false; then :
19524  $as_echo_n "(cached) " >&6
19525else
19526  lt_cv_prog_compiler_static_works=no
19527   save_LDFLAGS=$LDFLAGS
19528   LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
19529   echo "$lt_simple_link_test_code" > conftest.$ac_ext
19530   if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
19531     # The linker can only warn and ignore the option if not recognized
19532     # So say no if there are warnings
19533     if test -s conftest.err; then
19534       # Append any errors to the config.log.
19535       cat conftest.err 1>&5
19536       $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
19537       $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
19538       if diff conftest.exp conftest.er2 >/dev/null; then
19539         lt_cv_prog_compiler_static_works=yes
19540       fi
19541     else
19542       lt_cv_prog_compiler_static_works=yes
19543     fi
19544   fi
19545   $RM -r conftest*
19546   LDFLAGS=$save_LDFLAGS
19547
19548fi
19549{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5
19550$as_echo "$lt_cv_prog_compiler_static_works" >&6; }
19551
19552if test yes = "$lt_cv_prog_compiler_static_works"; then
19553    :
19554else
19555    lt_prog_compiler_static=
19556fi
19557
19558
19559
19560
19561
19562
19563
19564  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
19565$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
19566if ${lt_cv_prog_compiler_c_o+:} false; then :
19567  $as_echo_n "(cached) " >&6
19568else
19569  lt_cv_prog_compiler_c_o=no
19570   $RM -r conftest 2>/dev/null
19571   mkdir conftest
19572   cd conftest
19573   mkdir out
19574   echo "$lt_simple_compile_test_code" > conftest.$ac_ext
19575
19576   lt_compiler_flag="-o out/conftest2.$ac_objext"
19577   # Insert the option either (1) after the last *FLAGS variable, or
19578   # (2) before a word containing "conftest.", or (3) at the end.
19579   # Note that $ac_compile itself does not contain backslashes and begins
19580   # with a dollar sign (not a hyphen), so the echo should work correctly.
19581   lt_compile=`echo "$ac_compile" | $SED \
19582   -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
19583   -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
19584   -e 's:$: $lt_compiler_flag:'`
19585   (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
19586   (eval "$lt_compile" 2>out/conftest.err)
19587   ac_status=$?
19588   cat out/conftest.err >&5
19589   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19590   if (exit $ac_status) && test -s out/conftest2.$ac_objext
19591   then
19592     # The compiler can only warn and ignore the option if not recognized
19593     # So say no if there are warnings
19594     $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
19595     $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
19596     if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
19597       lt_cv_prog_compiler_c_o=yes
19598     fi
19599   fi
19600   chmod u+w . 2>&5
19601   $RM conftest*
19602   # SGI C++ compiler will create directory out/ii_files/ for
19603   # template instantiation
19604   test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
19605   $RM out/* && rmdir out
19606   cd ..
19607   $RM -r conftest
19608   $RM conftest*
19609
19610fi
19611{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
19612$as_echo "$lt_cv_prog_compiler_c_o" >&6; }
19613
19614
19615
19616
19617
19618
19619  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
19620$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
19621if ${lt_cv_prog_compiler_c_o+:} false; then :
19622  $as_echo_n "(cached) " >&6
19623else
19624  lt_cv_prog_compiler_c_o=no
19625   $RM -r conftest 2>/dev/null
19626   mkdir conftest
19627   cd conftest
19628   mkdir out
19629   echo "$lt_simple_compile_test_code" > conftest.$ac_ext
19630
19631   lt_compiler_flag="-o out/conftest2.$ac_objext"
19632   # Insert the option either (1) after the last *FLAGS variable, or
19633   # (2) before a word containing "conftest.", or (3) at the end.
19634   # Note that $ac_compile itself does not contain backslashes and begins
19635   # with a dollar sign (not a hyphen), so the echo should work correctly.
19636   lt_compile=`echo "$ac_compile" | $SED \
19637   -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
19638   -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
19639   -e 's:$: $lt_compiler_flag:'`
19640   (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
19641   (eval "$lt_compile" 2>out/conftest.err)
19642   ac_status=$?
19643   cat out/conftest.err >&5
19644   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19645   if (exit $ac_status) && test -s out/conftest2.$ac_objext
19646   then
19647     # The compiler can only warn and ignore the option if not recognized
19648     # So say no if there are warnings
19649     $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
19650     $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
19651     if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
19652       lt_cv_prog_compiler_c_o=yes
19653     fi
19654   fi
19655   chmod u+w . 2>&5
19656   $RM conftest*
19657   # SGI C++ compiler will create directory out/ii_files/ for
19658   # template instantiation
19659   test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
19660   $RM out/* && rmdir out
19661   cd ..
19662   $RM -r conftest
19663   $RM conftest*
19664
19665fi
19666{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
19667$as_echo "$lt_cv_prog_compiler_c_o" >&6; }
19668
19669
19670
19671
19672hard_links=nottested
19673if test no = "$lt_cv_prog_compiler_c_o" && test no != "$need_locks"; then
19674  # do not overwrite the value of need_locks provided by the user
19675  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5
19676$as_echo_n "checking if we can lock with hard links... " >&6; }
19677  hard_links=yes
19678  $RM conftest*
19679  ln conftest.a conftest.b 2>/dev/null && hard_links=no
19680  touch conftest.a
19681  ln conftest.a conftest.b 2>&5 || hard_links=no
19682  ln conftest.a conftest.b 2>/dev/null && hard_links=no
19683  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5
19684$as_echo "$hard_links" >&6; }
19685  if test no = "$hard_links"; then
19686    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&5
19687$as_echo "$as_me: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&2;}
19688    need_locks=warn
19689  fi
19690else
19691  need_locks=no
19692fi
19693
19694
19695
19696
19697
19698
19699  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
19700$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
19701
19702  runpath_var=
19703  allow_undefined_flag=
19704  always_export_symbols=no
19705  archive_cmds=
19706  archive_expsym_cmds=
19707  compiler_needs_object=no
19708  enable_shared_with_static_runtimes=no
19709  export_dynamic_flag_spec=
19710  export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
19711  hardcode_automatic=no
19712  hardcode_direct=no
19713  hardcode_direct_absolute=no
19714  hardcode_libdir_flag_spec=
19715  hardcode_libdir_separator=
19716  hardcode_minus_L=no
19717  hardcode_shlibpath_var=unsupported
19718  inherit_rpath=no
19719  link_all_deplibs=unknown
19720  module_cmds=
19721  module_expsym_cmds=
19722  old_archive_from_new_cmds=
19723  old_archive_from_expsyms_cmds=
19724  thread_safe_flag_spec=
19725  whole_archive_flag_spec=
19726  # include_expsyms should be a list of space-separated symbols to be *always*
19727  # included in the symbol list
19728  include_expsyms=
19729  # exclude_expsyms can be an extended regexp of symbols to exclude
19730  # it will be wrapped by ' (' and ')$', so one must not match beginning or
19731  # end of line.  Example: 'a|bc|.*d.*' will exclude the symbols 'a' and 'bc',
19732  # as well as any symbol that contains 'd'.
19733  exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
19734  # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
19735  # platforms (ab)use it in PIC code, but their linkers get confused if
19736  # the symbol is explicitly referenced.  Since portable code cannot
19737  # rely on this symbol name, it's probably fine to never include it in
19738  # preloaded symbol tables.
19739  # Exclude shared library initialization/finalization symbols.
19740  extract_expsyms_cmds=
19741
19742  case $host_os in
19743  cygwin* | mingw* | pw32* | cegcc*)
19744    # FIXME: the MSVC++ port hasn't been tested in a loooong time
19745    # When not using gcc, we currently assume that we are using
19746    # Microsoft Visual C++.
19747    if test yes != "$GCC"; then
19748      with_gnu_ld=no
19749    fi
19750    ;;
19751  interix*)
19752    # we just hope/assume this is gcc and not c89 (= MSVC++)
19753    with_gnu_ld=yes
19754    ;;
19755  openbsd* | bitrig*)
19756    with_gnu_ld=no
19757    ;;
19758  esac
19759
19760  ld_shlibs=yes
19761
19762  # On some targets, GNU ld is compatible enough with the native linker
19763  # that we're better off using the native interface for both.
19764  lt_use_gnu_ld_interface=no
19765  if test yes = "$with_gnu_ld"; then
19766    case $host_os in
19767      aix*)
19768	# The AIX port of GNU ld has always aspired to compatibility
19769	# with the native linker.  However, as the warning in the GNU ld
19770	# block says, versions before 2.19.5* couldn't really create working
19771	# shared libraries, regardless of the interface used.
19772	case `$LD -v 2>&1` in
19773	  *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
19774	  *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;;
19775	  *\ \(GNU\ Binutils\)\ [3-9]*) ;;
19776	  *)
19777	    lt_use_gnu_ld_interface=yes
19778	    ;;
19779	esac
19780	;;
19781      *)
19782	lt_use_gnu_ld_interface=yes
19783	;;
19784    esac
19785  fi
19786
19787  if test yes = "$lt_use_gnu_ld_interface"; then
19788    # If archive_cmds runs LD, not CC, wlarc should be empty
19789    wlarc='$wl'
19790
19791    # Set some defaults for GNU ld with shared library support. These
19792    # are reset later if shared libraries are not supported. Putting them
19793    # here allows them to be overridden if necessary.
19794    runpath_var=LD_RUN_PATH
19795    hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
19796    export_dynamic_flag_spec='$wl--export-dynamic'
19797    # ancient GNU ld didn't support --whole-archive et. al.
19798    if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
19799      whole_archive_flag_spec=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive'
19800    else
19801      whole_archive_flag_spec=
19802    fi
19803    supports_anon_versioning=no
19804    case `$LD -v | $SED -e 's/(^)\+)\s\+//' 2>&1` in
19805      *GNU\ gold*) supports_anon_versioning=yes ;;
19806      *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
19807      *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
19808      *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
19809      *\ 2.11.*) ;; # other 2.11 versions
19810      *) supports_anon_versioning=yes ;;
19811    esac
19812
19813    # See if GNU ld supports shared libraries.
19814    case $host_os in
19815    aix[3-9]*)
19816      # On AIX/PPC, the GNU linker is very broken
19817      if test ia64 != "$host_cpu"; then
19818	ld_shlibs=no
19819	cat <<_LT_EOF 1>&2
19820
19821*** Warning: the GNU linker, at least up to release 2.19, is reported
19822*** to be unable to reliably create shared libraries on AIX.
19823*** Therefore, libtool is disabling shared libraries support.  If you
19824*** really care for shared libraries, you may want to install binutils
19825*** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
19826*** You will then need to restart the configuration process.
19827
19828_LT_EOF
19829      fi
19830      ;;
19831
19832    amigaos*)
19833      case $host_cpu in
19834      powerpc)
19835            # see comment about AmigaOS4 .so support
19836            archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
19837            archive_expsym_cmds=''
19838        ;;
19839      m68k)
19840            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)'
19841            hardcode_libdir_flag_spec='-L$libdir'
19842            hardcode_minus_L=yes
19843        ;;
19844      esac
19845      ;;
19846
19847    beos*)
19848      if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
19849	allow_undefined_flag=unsupported
19850	# Joseph Beckenbach <jrb3@best.com> says some releases of gcc
19851	# support --undefined.  This deserves some investigation.  FIXME
19852	archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
19853      else
19854	ld_shlibs=no
19855      fi
19856      ;;
19857
19858    cygwin* | mingw* | pw32* | cegcc*)
19859      # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless,
19860      # as there is no search path for DLLs.
19861      hardcode_libdir_flag_spec='-L$libdir'
19862      export_dynamic_flag_spec='$wl--export-all-symbols'
19863      allow_undefined_flag=unsupported
19864      always_export_symbols=no
19865      enable_shared_with_static_runtimes=yes
19866      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'
19867      exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'
19868
19869      if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
19870        archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
19871	# If the export-symbols file already is a .def file, use it as
19872	# is; otherwise, prepend EXPORTS...
19873	archive_expsym_cmds='if   test DEF = "`$SED -n     -e '\''s/^[	 ]*//'\''     -e '\''/^\(;.*\)*$/d'\''     -e '\''s/^\(EXPORTS\|LIBRARY\)\([	 ].*\)*$/DEF/p'\''     -e q     $export_symbols`" ; then
19874          cp $export_symbols $output_objdir/$soname.def;
19875        else
19876          echo EXPORTS > $output_objdir/$soname.def;
19877          cat $export_symbols >> $output_objdir/$soname.def;
19878        fi~
19879        $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
19880      else
19881	ld_shlibs=no
19882      fi
19883      ;;
19884
19885    haiku*)
19886      archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
19887      link_all_deplibs=yes
19888      ;;
19889
19890    os2*)
19891      hardcode_libdir_flag_spec='-L$libdir'
19892      hardcode_minus_L=yes
19893      allow_undefined_flag=unsupported
19894      shrext_cmds=.dll
19895      archive_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
19896	$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
19897	$ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
19898	$ECHO EXPORTS >> $output_objdir/$libname.def~
19899	emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
19900	$CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
19901	emximp -o $lib $output_objdir/$libname.def'
19902      archive_expsym_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
19903	$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
19904	$ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
19905	$ECHO EXPORTS >> $output_objdir/$libname.def~
19906	prefix_cmds="$SED"~
19907	if test EXPORTS = "`$SED 1q $export_symbols`"; then
19908	  prefix_cmds="$prefix_cmds -e 1d";
19909	fi~
19910	prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
19911	cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
19912	$CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
19913	emximp -o $lib $output_objdir/$libname.def'
19914      old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
19915      enable_shared_with_static_runtimes=yes
19916      ;;
19917
19918    interix[3-9]*)
19919      hardcode_direct=no
19920      hardcode_shlibpath_var=no
19921      hardcode_libdir_flag_spec='$wl-rpath,$libdir'
19922      export_dynamic_flag_spec='$wl-E'
19923      # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
19924      # Instead, shared libraries are loaded at an image base (0x10000000 by
19925      # default) and relocated if they conflict, which is a slow very memory
19926      # consuming and fragmenting process.  To avoid this, we pick a random,
19927      # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
19928      # time.  Moving up from 0x10000000 also allows more sbrk(2) space.
19929      archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
19930      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'
19931      ;;
19932
19933    gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
19934      tmp_diet=no
19935      if test linux-dietlibc = "$host_os"; then
19936	case $cc_basename in
19937	  diet\ *) tmp_diet=yes;;	# linux-dietlibc with static linking (!diet-dyn)
19938	esac
19939      fi
19940      if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
19941	 && test no = "$tmp_diet"
19942      then
19943	tmp_addflag=' $pic_flag'
19944	tmp_sharedflag='-shared'
19945	case $cc_basename,$host_cpu in
19946        pgcc*)				# Portland Group C compiler
19947	  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'
19948	  tmp_addflag=' $pic_flag'
19949	  ;;
19950	pgf77* | pgf90* | pgf95* | pgfortran*)
19951					# Portland Group f77 and f90 compilers
19952	  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'
19953	  tmp_addflag=' $pic_flag -Mnomain' ;;
19954	ecc*,ia64* | icc*,ia64*)	# Intel C compiler on ia64
19955	  tmp_addflag=' -i_dynamic' ;;
19956	efc*,ia64* | ifort*,ia64*)	# Intel Fortran compiler on ia64
19957	  tmp_addflag=' -i_dynamic -nofor_main' ;;
19958	ifc* | ifort*)			# Intel Fortran compiler
19959	  tmp_addflag=' -nofor_main' ;;
19960	lf95*)				# Lahey Fortran 8.1
19961	  whole_archive_flag_spec=
19962	  tmp_sharedflag='--shared' ;;
19963        nagfor*)                        # NAGFOR 5.3
19964          tmp_sharedflag='-Wl,-shared' ;;
19965	xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below)
19966	  tmp_sharedflag='-qmkshrobj'
19967	  tmp_addflag= ;;
19968	nvcc*)	# Cuda Compiler Driver 2.2
19969	  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'
19970	  compiler_needs_object=yes
19971	  ;;
19972	esac
19973	case `$CC -V 2>&1 | sed 5q` in
19974	*Sun\ C*)			# Sun C 5.9
19975	  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'
19976	  compiler_needs_object=yes
19977	  tmp_sharedflag='-G' ;;
19978	*Sun\ F*)			# Sun Fortran 8.3
19979	  tmp_sharedflag='-G' ;;
19980	esac
19981	archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
19982
19983        if test yes = "$supports_anon_versioning"; then
19984          archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
19985            cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
19986            echo "local: *; };" >> $output_objdir/$libname.ver~
19987            $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib'
19988        fi
19989
19990	case $cc_basename in
19991	tcc*)
19992	  export_dynamic_flag_spec='-rdynamic'
19993	  ;;
19994	xlf* | bgf* | bgxlf* | mpixlf*)
19995	  # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
19996	  whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
19997	  hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
19998	  archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
19999	  if test yes = "$supports_anon_versioning"; then
20000	    archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
20001              cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
20002              echo "local: *; };" >> $output_objdir/$libname.ver~
20003              $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
20004	  fi
20005	  ;;
20006	esac
20007      else
20008        ld_shlibs=no
20009      fi
20010      ;;
20011
20012    netbsd*)
20013      if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
20014	archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
20015	wlarc=
20016      else
20017	archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
20018	archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
20019      fi
20020      ;;
20021
20022    solaris*)
20023      if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
20024	ld_shlibs=no
20025	cat <<_LT_EOF 1>&2
20026
20027*** Warning: The releases 2.8.* of the GNU linker cannot reliably
20028*** create shared libraries on Solaris systems.  Therefore, libtool
20029*** is disabling shared libraries support.  We urge you to upgrade GNU
20030*** binutils to release 2.9.1 or newer.  Another option is to modify
20031*** your PATH or compiler configuration so that the native linker is
20032*** used, and then restart.
20033
20034_LT_EOF
20035      elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
20036	archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
20037	archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
20038      else
20039	ld_shlibs=no
20040      fi
20041      ;;
20042
20043    sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
20044      case `$LD -v 2>&1` in
20045        *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*)
20046	ld_shlibs=no
20047	cat <<_LT_EOF 1>&2
20048
20049*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 cannot
20050*** reliably create shared libraries on SCO systems.  Therefore, libtool
20051*** is disabling shared libraries support.  We urge you to upgrade GNU
20052*** binutils to release 2.16.91.0.3 or newer.  Another option is to modify
20053*** your PATH or compiler configuration so that the native linker is
20054*** used, and then restart.
20055
20056_LT_EOF
20057	;;
20058	*)
20059	  # For security reasons, it is highly recommended that you always
20060	  # use absolute paths for naming shared libraries, and exclude the
20061	  # DT_RUNPATH tag from executables and libraries.  But doing so
20062	  # requires that you compile everything twice, which is a pain.
20063	  if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
20064	    hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
20065	    archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
20066	    archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
20067	  else
20068	    ld_shlibs=no
20069	  fi
20070	;;
20071      esac
20072      ;;
20073
20074    sunos4*)
20075      archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
20076      wlarc=
20077      hardcode_direct=yes
20078      hardcode_shlibpath_var=no
20079      ;;
20080
20081    *)
20082      if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
20083	archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
20084	archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
20085      else
20086	ld_shlibs=no
20087      fi
20088      ;;
20089    esac
20090
20091    if test no = "$ld_shlibs"; then
20092      runpath_var=
20093      hardcode_libdir_flag_spec=
20094      export_dynamic_flag_spec=
20095      whole_archive_flag_spec=
20096    fi
20097  else
20098    # PORTME fill in a description of your system's linker (not GNU ld)
20099    case $host_os in
20100    aix3*)
20101      allow_undefined_flag=unsupported
20102      always_export_symbols=yes
20103      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'
20104      # Note: this linker hardcodes the directories in LIBPATH if there
20105      # are no directories specified by -L.
20106      hardcode_minus_L=yes
20107      if test yes = "$GCC" && test -z "$lt_prog_compiler_static"; then
20108	# Neither direct hardcoding nor static linking is supported with a
20109	# broken collect2.
20110	hardcode_direct=unsupported
20111      fi
20112      ;;
20113
20114    aix[4-9]*)
20115      if test ia64 = "$host_cpu"; then
20116	# On IA64, the linker does run time linking by default, so we don't
20117	# have to do anything special.
20118	aix_use_runtimelinking=no
20119	exp_sym_flag='-Bexport'
20120	no_entry_flag=
20121      else
20122	# If we're using GNU nm, then we don't want the "-C" option.
20123	# -C means demangle to GNU nm, but means don't demangle to AIX nm.
20124	# Without the "-l" option, or with the "-B" option, AIX nm treats
20125	# weak defined symbols like other global defined symbols, whereas
20126	# GNU nm marks them as "W".
20127	# While the 'weak' keyword is ignored in the Export File, we need
20128	# it in the Import File for the 'aix-soname' feature, so we have
20129	# to replace the "-B" option with "-P" for AIX nm.
20130	if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
20131	  export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols'
20132	else
20133	  export_symbols_cmds='`func_echo_all $NM | $SED -e '\''s/B\([^B]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && (substr(\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols'
20134	fi
20135	aix_use_runtimelinking=no
20136
20137	# Test if we are trying to use run time linking or normal
20138	# AIX style linking. If -brtl is somewhere in LDFLAGS, we
20139	# have runtime linking enabled, and use it for executables.
20140	# For shared libraries, we enable/disable runtime linking
20141	# depending on the kind of the shared library created -
20142	# when "with_aix_soname,aix_use_runtimelinking" is:
20143	# "aix,no"   lib.a(lib.so.V) shared, rtl:no,  for executables
20144	# "aix,yes"  lib.so          shared, rtl:yes, for executables
20145	#            lib.a           static archive
20146	# "both,no"  lib.so.V(shr.o) shared, rtl:yes
20147	#            lib.a(lib.so.V) shared, rtl:no,  for executables
20148	# "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables
20149	#            lib.a(lib.so.V) shared, rtl:no
20150	# "svr4,*"   lib.so.V(shr.o) shared, rtl:yes, for executables
20151	#            lib.a           static archive
20152	case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
20153	  for ld_flag in $LDFLAGS; do
20154	  if (test x-brtl = "x$ld_flag" || test x-Wl,-brtl = "x$ld_flag"); then
20155	    aix_use_runtimelinking=yes
20156	    break
20157	  fi
20158	  done
20159	  if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then
20160	    # With aix-soname=svr4, we create the lib.so.V shared archives only,
20161	    # so we don't have lib.a shared libs to link our executables.
20162	    # We have to force runtime linking in this case.
20163	    aix_use_runtimelinking=yes
20164	    LDFLAGS="$LDFLAGS -Wl,-brtl"
20165	  fi
20166	  ;;
20167	esac
20168
20169	exp_sym_flag='-bexport'
20170	no_entry_flag='-bnoentry'
20171      fi
20172
20173      # When large executables or shared objects are built, AIX ld can
20174      # have problems creating the table of contents.  If linking a library
20175      # or program results in "error TOC overflow" add -mminimal-toc to
20176      # CXXFLAGS/CFLAGS for g++/gcc.  In the cases where that is not
20177      # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
20178
20179      archive_cmds=''
20180      hardcode_direct=yes
20181      hardcode_direct_absolute=yes
20182      hardcode_libdir_separator=':'
20183      link_all_deplibs=yes
20184      file_list_spec='$wl-f,'
20185      case $with_aix_soname,$aix_use_runtimelinking in
20186      aix,*) ;; # traditional, no import file
20187      svr4,* | *,yes) # use import file
20188	# The Import File defines what to hardcode.
20189	hardcode_direct=no
20190	hardcode_direct_absolute=no
20191	;;
20192      esac
20193
20194      if test yes = "$GCC"; then
20195	case $host_os in aix4.[012]|aix4.[012].*)
20196	# We only want to do this on AIX 4.2 and lower, the check
20197	# below for broken collect2 doesn't work under 4.3+
20198	  collect2name=`$CC -print-prog-name=collect2`
20199	  if test -f "$collect2name" &&
20200	   strings "$collect2name" | $GREP resolve_lib_name >/dev/null
20201	  then
20202	  # We have reworked collect2
20203	  :
20204	  else
20205	  # We have old collect2
20206	  hardcode_direct=unsupported
20207	  # It fails to find uninstalled libraries when the uninstalled
20208	  # path is not listed in the libpath.  Setting hardcode_minus_L
20209	  # to unsupported forces relinking
20210	  hardcode_minus_L=yes
20211	  hardcode_libdir_flag_spec='-L$libdir'
20212	  hardcode_libdir_separator=
20213	  fi
20214	  ;;
20215	esac
20216	shared_flag='-shared'
20217	if test yes = "$aix_use_runtimelinking"; then
20218	  shared_flag="$shared_flag "'$wl-G'
20219	fi
20220	# Need to ensure runtime linking is disabled for the traditional
20221	# shared library, or the linker may eventually find shared libraries
20222	# /with/ Import File - we do not want to mix them.
20223	shared_flag_aix='-shared'
20224	shared_flag_svr4='-shared $wl-G'
20225      else
20226	# not using gcc
20227	if test ia64 = "$host_cpu"; then
20228	# VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
20229	# chokes on -Wl,-G. The following line is correct:
20230	  shared_flag='-G'
20231	else
20232	  if test yes = "$aix_use_runtimelinking"; then
20233	    shared_flag='$wl-G'
20234	  else
20235	    shared_flag='$wl-bM:SRE'
20236	  fi
20237	  shared_flag_aix='$wl-bM:SRE'
20238	  shared_flag_svr4='$wl-G'
20239	fi
20240      fi
20241
20242      export_dynamic_flag_spec='$wl-bexpall'
20243      # It seems that -bexpall does not export symbols beginning with
20244      # underscore (_), so it is better to generate a list of symbols to export.
20245      always_export_symbols=yes
20246      if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then
20247	# Warning - without using the other runtime loading flags (-brtl),
20248	# -berok will link without error, but may produce a broken library.
20249	allow_undefined_flag='-berok'
20250        # Determine the default libpath from the value encoded in an
20251        # empty executable.
20252        if test set = "${lt_cv_aix_libpath+set}"; then
20253  aix_libpath=$lt_cv_aix_libpath
20254else
20255  if ${lt_cv_aix_libpath_+:} false; then :
20256  $as_echo_n "(cached) " >&6
20257else
20258  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20259/* end confdefs.h.  */
20260
20261int
20262main ()
20263{
20264
20265  ;
20266  return 0;
20267}
20268_ACEOF
20269if ac_fn_c_try_link "$LINENO"; then :
20270
20271  lt_aix_libpath_sed='
20272      /Import File Strings/,/^$/ {
20273	  /^0/ {
20274	      s/^0  *\([^ ]*\) *$/\1/
20275	      p
20276	  }
20277      }'
20278  lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
20279  # Check for a 64-bit object if we didn't find anything.
20280  if test -z "$lt_cv_aix_libpath_"; then
20281    lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
20282  fi
20283fi
20284rm -f core conftest.err conftest.$ac_objext \
20285    conftest$ac_exeext conftest.$ac_ext
20286  if test -z "$lt_cv_aix_libpath_"; then
20287    lt_cv_aix_libpath_=/usr/lib:/lib
20288  fi
20289
20290fi
20291
20292  aix_libpath=$lt_cv_aix_libpath_
20293fi
20294
20295        hardcode_libdir_flag_spec='$wl-blibpath:$libdir:'"$aix_libpath"
20296        archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag
20297      else
20298	if test ia64 = "$host_cpu"; then
20299	  hardcode_libdir_flag_spec='$wl-R $libdir:/usr/lib:/lib'
20300	  allow_undefined_flag="-z nodefs"
20301	  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"
20302	else
20303	 # Determine the default libpath from the value encoded in an
20304	 # empty executable.
20305	 if test set = "${lt_cv_aix_libpath+set}"; then
20306  aix_libpath=$lt_cv_aix_libpath
20307else
20308  if ${lt_cv_aix_libpath_+:} false; then :
20309  $as_echo_n "(cached) " >&6
20310else
20311  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20312/* end confdefs.h.  */
20313
20314int
20315main ()
20316{
20317
20318  ;
20319  return 0;
20320}
20321_ACEOF
20322if ac_fn_c_try_link "$LINENO"; then :
20323
20324  lt_aix_libpath_sed='
20325      /Import File Strings/,/^$/ {
20326	  /^0/ {
20327	      s/^0  *\([^ ]*\) *$/\1/
20328	      p
20329	  }
20330      }'
20331  lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
20332  # Check for a 64-bit object if we didn't find anything.
20333  if test -z "$lt_cv_aix_libpath_"; then
20334    lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
20335  fi
20336fi
20337rm -f core conftest.err conftest.$ac_objext \
20338    conftest$ac_exeext conftest.$ac_ext
20339  if test -z "$lt_cv_aix_libpath_"; then
20340    lt_cv_aix_libpath_=/usr/lib:/lib
20341  fi
20342
20343fi
20344
20345  aix_libpath=$lt_cv_aix_libpath_
20346fi
20347
20348	 hardcode_libdir_flag_spec='$wl-blibpath:$libdir:'"$aix_libpath"
20349	  # Warning - without using the other run time loading flags,
20350	  # -berok will link without error, but may produce a broken library.
20351	  no_undefined_flag=' $wl-bernotok'
20352	  allow_undefined_flag=' $wl-berok'
20353	  if test yes = "$with_gnu_ld"; then
20354	    # We only use this code for GNU lds that support --whole-archive.
20355	    whole_archive_flag_spec='$wl--whole-archive$convenience $wl--no-whole-archive'
20356	  else
20357	    # Exported symbols can be pulled into shared objects from archives
20358	    whole_archive_flag_spec='$convenience'
20359	  fi
20360	  archive_cmds_need_lc=yes
20361	  archive_expsym_cmds='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d'
20362	  # -brtl affects multiple linker settings, -berok does not and is overridden later
20363	  compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([, ]\\)%-berok\\1%g"`'
20364	  if test svr4 != "$with_aix_soname"; then
20365	    # This is similar to how AIX traditionally builds its shared libraries.
20366	    archive_expsym_cmds="$archive_expsym_cmds"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname'
20367	  fi
20368	  if test aix != "$with_aix_soname"; then
20369	    archive_expsym_cmds="$archive_expsym_cmds"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp'
20370	  else
20371	    # used by -dlpreopen to get the symbols
20372	    archive_expsym_cmds="$archive_expsym_cmds"'~$MV  $output_objdir/$realname.d/$soname $output_objdir'
20373	  fi
20374	  archive_expsym_cmds="$archive_expsym_cmds"'~$RM -r $output_objdir/$realname.d'
20375	fi
20376      fi
20377      ;;
20378
20379    amigaos*)
20380      case $host_cpu in
20381      powerpc)
20382            # see comment about AmigaOS4 .so support
20383            archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
20384            archive_expsym_cmds=''
20385        ;;
20386      m68k)
20387            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)'
20388            hardcode_libdir_flag_spec='-L$libdir'
20389            hardcode_minus_L=yes
20390        ;;
20391      esac
20392      ;;
20393
20394    bsdi[45]*)
20395      export_dynamic_flag_spec=-rdynamic
20396      ;;
20397
20398    cygwin* | mingw* | pw32* | cegcc*)
20399      # When not using gcc, we currently assume that we are using
20400      # Microsoft Visual C++.
20401      # hardcode_libdir_flag_spec is actually meaningless, as there is
20402      # no search path for DLLs.
20403      case $cc_basename in
20404      cl*)
20405	# Native MSVC
20406	hardcode_libdir_flag_spec=' '
20407	allow_undefined_flag=unsupported
20408	always_export_symbols=yes
20409	file_list_spec='@'
20410	# Tell ltmain to make .lib files, not .a files.
20411	libext=lib
20412	# Tell ltmain to make .dll files, not .so files.
20413	shrext_cmds=.dll
20414	# FIXME: Setting linknames here is a bad hack.
20415	archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames='
20416	archive_expsym_cmds='if   test DEF = "`$SED -n     -e '\''s/^[	 ]*//'\''     -e '\''/^\(;.*\)*$/d'\''     -e '\''s/^\(EXPORTS\|LIBRARY\)\([	 ].*\)*$/DEF/p'\''     -e q     $export_symbols`" ; then
20417            cp "$export_symbols" "$output_objdir/$soname.def";
20418            echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp";
20419          else
20420            $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp;
20421          fi~
20422          $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
20423          linknames='
20424	# The linker will not automatically build a static lib if we build a DLL.
20425	# _LT_TAGVAR(old_archive_from_new_cmds, )='true'
20426	enable_shared_with_static_runtimes=yes
20427	exclude_expsyms='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
20428	export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
20429	# Don't use ranlib
20430	old_postinstall_cmds='chmod 644 $oldlib'
20431	postlink_cmds='lt_outputfile="@OUTPUT@"~
20432          lt_tool_outputfile="@TOOL_OUTPUT@"~
20433          case $lt_outputfile in
20434            *.exe|*.EXE) ;;
20435            *)
20436              lt_outputfile=$lt_outputfile.exe
20437              lt_tool_outputfile=$lt_tool_outputfile.exe
20438              ;;
20439          esac~
20440          if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then
20441            $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
20442            $RM "$lt_outputfile.manifest";
20443          fi'
20444	;;
20445      *)
20446	# Assume MSVC wrapper
20447	hardcode_libdir_flag_spec=' '
20448	allow_undefined_flag=unsupported
20449	# Tell ltmain to make .lib files, not .a files.
20450	libext=lib
20451	# Tell ltmain to make .dll files, not .so files.
20452	shrext_cmds=.dll
20453	# FIXME: Setting linknames here is a bad hack.
20454	archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
20455	# The linker will automatically build a .lib file if we build a DLL.
20456	old_archive_from_new_cmds='true'
20457	# FIXME: Should let the user specify the lib program.
20458	old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
20459	enable_shared_with_static_runtimes=yes
20460	;;
20461      esac
20462      ;;
20463
20464    darwin* | rhapsody*)
20465
20466
20467  archive_cmds_need_lc=no
20468  hardcode_direct=no
20469  hardcode_automatic=yes
20470  hardcode_shlibpath_var=unsupported
20471  if test yes = "$lt_cv_ld_force_load"; then
20472    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\"`'
20473
20474  else
20475    whole_archive_flag_spec=''
20476  fi
20477  link_all_deplibs=yes
20478  allow_undefined_flag=$_lt_dar_allow_undefined
20479  case $cc_basename in
20480     ifort*|nagfor*) _lt_dar_can_shared=yes ;;
20481     *) _lt_dar_can_shared=$GCC ;;
20482  esac
20483  if test yes = "$_lt_dar_can_shared"; then
20484    output_verbose_link_cmd=func_echo_all
20485    archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil"
20486    module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil"
20487    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"
20488    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"
20489
20490  else
20491  ld_shlibs=no
20492  fi
20493
20494      ;;
20495
20496    dgux*)
20497      archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
20498      hardcode_libdir_flag_spec='-L$libdir'
20499      hardcode_shlibpath_var=no
20500      ;;
20501
20502    # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
20503    # support.  Future versions do this automatically, but an explicit c++rt0.o
20504    # does not break anything, and helps significantly (at the cost of a little
20505    # extra space).
20506    freebsd2.2*)
20507      archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
20508      hardcode_libdir_flag_spec='-R$libdir'
20509      hardcode_direct=yes
20510      hardcode_shlibpath_var=no
20511      ;;
20512
20513    # Unfortunately, older versions of FreeBSD 2 do not have this feature.
20514    freebsd2.*)
20515      archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
20516      hardcode_direct=yes
20517      hardcode_minus_L=yes
20518      hardcode_shlibpath_var=no
20519      ;;
20520
20521    # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
20522    freebsd* | dragonfly*)
20523      archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
20524      hardcode_libdir_flag_spec='-R$libdir'
20525      hardcode_direct=yes
20526      hardcode_shlibpath_var=no
20527      ;;
20528
20529    hpux9*)
20530      if test yes = "$GCC"; then
20531	archive_cmds='$RM $output_objdir/$soname~$CC -shared $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib'
20532      else
20533	archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib'
20534      fi
20535      hardcode_libdir_flag_spec='$wl+b $wl$libdir'
20536      hardcode_libdir_separator=:
20537      hardcode_direct=yes
20538
20539      # hardcode_minus_L: Not really in the search PATH,
20540      # but as the default location of the library.
20541      hardcode_minus_L=yes
20542      export_dynamic_flag_spec='$wl-E'
20543      ;;
20544
20545    hpux10*)
20546      if test yes,no = "$GCC,$with_gnu_ld"; then
20547	archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
20548      else
20549	archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
20550      fi
20551      if test no = "$with_gnu_ld"; then
20552	hardcode_libdir_flag_spec='$wl+b $wl$libdir'
20553	hardcode_libdir_separator=:
20554	hardcode_direct=yes
20555	hardcode_direct_absolute=yes
20556	export_dynamic_flag_spec='$wl-E'
20557	# hardcode_minus_L: Not really in the search PATH,
20558	# but as the default location of the library.
20559	hardcode_minus_L=yes
20560      fi
20561      ;;
20562
20563    hpux11*)
20564      if test yes,no = "$GCC,$with_gnu_ld"; then
20565	case $host_cpu in
20566	hppa*64*)
20567	  archive_cmds='$CC -shared $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
20568	  ;;
20569	ia64*)
20570	  archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
20571	  ;;
20572	*)
20573	  archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
20574	  ;;
20575	esac
20576      else
20577	case $host_cpu in
20578	hppa*64*)
20579	  archive_cmds='$CC -b $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
20580	  ;;
20581	ia64*)
20582	  archive_cmds='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
20583	  ;;
20584	*)
20585
20586	  # Older versions of the 11.00 compiler do not understand -b yet
20587	  # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
20588	  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5
20589$as_echo_n "checking if $CC understands -b... " >&6; }
20590if ${lt_cv_prog_compiler__b+:} false; then :
20591  $as_echo_n "(cached) " >&6
20592else
20593  lt_cv_prog_compiler__b=no
20594   save_LDFLAGS=$LDFLAGS
20595   LDFLAGS="$LDFLAGS -b"
20596   echo "$lt_simple_link_test_code" > conftest.$ac_ext
20597   if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
20598     # The linker can only warn and ignore the option if not recognized
20599     # So say no if there are warnings
20600     if test -s conftest.err; then
20601       # Append any errors to the config.log.
20602       cat conftest.err 1>&5
20603       $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
20604       $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
20605       if diff conftest.exp conftest.er2 >/dev/null; then
20606         lt_cv_prog_compiler__b=yes
20607       fi
20608     else
20609       lt_cv_prog_compiler__b=yes
20610     fi
20611   fi
20612   $RM -r conftest*
20613   LDFLAGS=$save_LDFLAGS
20614
20615fi
20616{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5
20617$as_echo "$lt_cv_prog_compiler__b" >&6; }
20618
20619if test yes = "$lt_cv_prog_compiler__b"; then
20620    archive_cmds='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
20621else
20622    archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
20623fi
20624
20625	  ;;
20626	esac
20627      fi
20628      if test no = "$with_gnu_ld"; then
20629	hardcode_libdir_flag_spec='$wl+b $wl$libdir'
20630	hardcode_libdir_separator=:
20631
20632	case $host_cpu in
20633	hppa*64*|ia64*)
20634	  hardcode_direct=no
20635	  hardcode_shlibpath_var=no
20636	  ;;
20637	*)
20638	  hardcode_direct=yes
20639	  hardcode_direct_absolute=yes
20640	  export_dynamic_flag_spec='$wl-E'
20641
20642	  # hardcode_minus_L: Not really in the search PATH,
20643	  # but as the default location of the library.
20644	  hardcode_minus_L=yes
20645	  ;;
20646	esac
20647      fi
20648      ;;
20649
20650    irix5* | irix6* | nonstopux*)
20651      if test yes = "$GCC"; then
20652	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'
20653	# Try to use the -exported_symbol ld option, if it does not
20654	# work, assume that -exports_file does not work either and
20655	# implicitly export all symbols.
20656	# This should be the same for all languages, so no per-tag cache variable.
20657	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5
20658$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; }
20659if ${lt_cv_irix_exported_symbol+:} false; then :
20660  $as_echo_n "(cached) " >&6
20661else
20662  save_LDFLAGS=$LDFLAGS
20663	   LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null"
20664	   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20665/* end confdefs.h.  */
20666int foo (void) { return 0; }
20667_ACEOF
20668if ac_fn_c_try_link "$LINENO"; then :
20669  lt_cv_irix_exported_symbol=yes
20670else
20671  lt_cv_irix_exported_symbol=no
20672fi
20673rm -f core conftest.err conftest.$ac_objext \
20674    conftest$ac_exeext conftest.$ac_ext
20675           LDFLAGS=$save_LDFLAGS
20676fi
20677{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5
20678$as_echo "$lt_cv_irix_exported_symbol" >&6; }
20679	if test yes = "$lt_cv_irix_exported_symbol"; then
20680          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'
20681	fi
20682      else
20683	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'
20684	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'
20685      fi
20686      archive_cmds_need_lc='no'
20687      hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
20688      hardcode_libdir_separator=:
20689      inherit_rpath=yes
20690      link_all_deplibs=yes
20691      ;;
20692
20693    linux*)
20694      case $cc_basename in
20695      tcc*)
20696	# Fabrice Bellard et al's Tiny C Compiler
20697	ld_shlibs=yes
20698	archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
20699	;;
20700      esac
20701      ;;
20702
20703    netbsd*)
20704      if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
20705	archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'  # a.out
20706      else
20707	archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags'      # ELF
20708      fi
20709      hardcode_libdir_flag_spec='-R$libdir'
20710      hardcode_direct=yes
20711      hardcode_shlibpath_var=no
20712      ;;
20713
20714    newsos6)
20715      archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
20716      hardcode_direct=yes
20717      hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
20718      hardcode_libdir_separator=:
20719      hardcode_shlibpath_var=no
20720      ;;
20721
20722    *nto* | *qnx*)
20723      ;;
20724
20725    openbsd* | bitrig*)
20726      if test -f /usr/libexec/ld.so; then
20727	hardcode_direct=yes
20728	hardcode_shlibpath_var=no
20729	hardcode_direct_absolute=yes
20730	if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
20731	  archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
20732	  archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols'
20733	  hardcode_libdir_flag_spec='$wl-rpath,$libdir'
20734	  export_dynamic_flag_spec='$wl-E'
20735	else
20736	  archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
20737	  hardcode_libdir_flag_spec='$wl-rpath,$libdir'
20738	fi
20739      else
20740	ld_shlibs=no
20741      fi
20742      ;;
20743
20744    os2*)
20745      hardcode_libdir_flag_spec='-L$libdir'
20746      hardcode_minus_L=yes
20747      allow_undefined_flag=unsupported
20748      shrext_cmds=.dll
20749      archive_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
20750	$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
20751	$ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
20752	$ECHO EXPORTS >> $output_objdir/$libname.def~
20753	emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
20754	$CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
20755	emximp -o $lib $output_objdir/$libname.def'
20756      archive_expsym_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
20757	$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
20758	$ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
20759	$ECHO EXPORTS >> $output_objdir/$libname.def~
20760	prefix_cmds="$SED"~
20761	if test EXPORTS = "`$SED 1q $export_symbols`"; then
20762	  prefix_cmds="$prefix_cmds -e 1d";
20763	fi~
20764	prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
20765	cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
20766	$CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
20767	emximp -o $lib $output_objdir/$libname.def'
20768      old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
20769      enable_shared_with_static_runtimes=yes
20770      ;;
20771
20772    osf3*)
20773      if test yes = "$GCC"; then
20774	allow_undefined_flag=' $wl-expect_unresolved $wl\*'
20775	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'
20776      else
20777	allow_undefined_flag=' -expect_unresolved \*'
20778	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'
20779      fi
20780      archive_cmds_need_lc='no'
20781      hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
20782      hardcode_libdir_separator=:
20783      ;;
20784
20785    osf4* | osf5*)	# as osf3* with the addition of -msym flag
20786      if test yes = "$GCC"; then
20787	allow_undefined_flag=' $wl-expect_unresolved $wl\*'
20788	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'
20789	hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
20790      else
20791	allow_undefined_flag=' -expect_unresolved \*'
20792	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'
20793	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~
20794          $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'
20795
20796	# Both c and cxx compiler support -rpath directly
20797	hardcode_libdir_flag_spec='-rpath $libdir'
20798      fi
20799      archive_cmds_need_lc='no'
20800      hardcode_libdir_separator=:
20801      ;;
20802
20803    solaris*)
20804      no_undefined_flag=' -z defs'
20805      if test yes = "$GCC"; then
20806	wlarc='$wl'
20807	archive_cmds='$CC -shared $pic_flag $wl-z ${wl}text $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
20808	archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
20809          $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'
20810      else
20811	case `$CC -V 2>&1` in
20812	*"Compilers 5.0"*)
20813	  wlarc=''
20814	  archive_cmds='$LD -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $linker_flags'
20815	  archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
20816            $LD -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
20817	  ;;
20818	*)
20819	  wlarc='$wl'
20820	  archive_cmds='$CC -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $compiler_flags'
20821	  archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
20822            $CC -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
20823	  ;;
20824	esac
20825      fi
20826      hardcode_libdir_flag_spec='-R$libdir'
20827      hardcode_shlibpath_var=no
20828      case $host_os in
20829      solaris2.[0-5] | solaris2.[0-5].*) ;;
20830      *)
20831	# The compiler driver will combine and reorder linker options,
20832	# but understands '-z linker_flag'.  GCC discards it without '$wl',
20833	# but is careful enough not to reorder.
20834	# Supported since Solaris 2.6 (maybe 2.5.1?)
20835	if test yes = "$GCC"; then
20836	  whole_archive_flag_spec='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract'
20837	else
20838	  whole_archive_flag_spec='-z allextract$convenience -z defaultextract'
20839	fi
20840	;;
20841      esac
20842      link_all_deplibs=yes
20843      ;;
20844
20845    sunos4*)
20846      if test sequent = "$host_vendor"; then
20847	# Use $CC to link under sequent, because it throws in some extra .o
20848	# files that make .init and .fini sections work.
20849	archive_cmds='$CC -G $wl-h $soname -o $lib $libobjs $deplibs $compiler_flags'
20850      else
20851	archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
20852      fi
20853      hardcode_libdir_flag_spec='-L$libdir'
20854      hardcode_direct=yes
20855      hardcode_minus_L=yes
20856      hardcode_shlibpath_var=no
20857      ;;
20858
20859    sysv4)
20860      case $host_vendor in
20861	sni)
20862	  archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
20863	  hardcode_direct=yes # is this really true???
20864	;;
20865	siemens)
20866	  ## LD is ld it makes a PLAMLIB
20867	  ## CC just makes a GrossModule.
20868	  archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
20869	  reload_cmds='$CC -r -o $output$reload_objs'
20870	  hardcode_direct=no
20871        ;;
20872	motorola)
20873	  archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
20874	  hardcode_direct=no #Motorola manual says yes, but my tests say they lie
20875	;;
20876      esac
20877      runpath_var='LD_RUN_PATH'
20878      hardcode_shlibpath_var=no
20879      ;;
20880
20881    sysv4.3*)
20882      archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
20883      hardcode_shlibpath_var=no
20884      export_dynamic_flag_spec='-Bexport'
20885      ;;
20886
20887    sysv4*MP*)
20888      if test -d /usr/nec; then
20889	archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
20890	hardcode_shlibpath_var=no
20891	runpath_var=LD_RUN_PATH
20892	hardcode_runpath_var=yes
20893	ld_shlibs=yes
20894      fi
20895      ;;
20896
20897    sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
20898      no_undefined_flag='$wl-z,text'
20899      archive_cmds_need_lc=no
20900      hardcode_shlibpath_var=no
20901      runpath_var='LD_RUN_PATH'
20902
20903      if test yes = "$GCC"; then
20904	archive_cmds='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
20905	archive_expsym_cmds='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
20906      else
20907	archive_cmds='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
20908	archive_expsym_cmds='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
20909      fi
20910      ;;
20911
20912    sysv5* | sco3.2v5* | sco5v6*)
20913      # Note: We CANNOT use -z defs as we might desire, because we do not
20914      # link with -lc, and that would cause any symbols used from libc to
20915      # always be unresolved, which means just about no library would
20916      # ever link correctly.  If we're not using GNU ld we use -z text
20917      # though, which does catch some bad symbols but isn't as heavy-handed
20918      # as -z defs.
20919      no_undefined_flag='$wl-z,text'
20920      allow_undefined_flag='$wl-z,nodefs'
20921      archive_cmds_need_lc=no
20922      hardcode_shlibpath_var=no
20923      hardcode_libdir_flag_spec='$wl-R,$libdir'
20924      hardcode_libdir_separator=':'
20925      link_all_deplibs=yes
20926      export_dynamic_flag_spec='$wl-Bexport'
20927      runpath_var='LD_RUN_PATH'
20928
20929      if test yes = "$GCC"; then
20930	archive_cmds='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
20931	archive_expsym_cmds='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
20932      else
20933	archive_cmds='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
20934	archive_expsym_cmds='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
20935      fi
20936      ;;
20937
20938    uts4*)
20939      archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
20940      hardcode_libdir_flag_spec='-L$libdir'
20941      hardcode_shlibpath_var=no
20942      ;;
20943
20944    *)
20945      ld_shlibs=no
20946      ;;
20947    esac
20948
20949    if test sni = "$host_vendor"; then
20950      case $host in
20951      sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
20952	export_dynamic_flag_spec='$wl-Blargedynsym'
20953	;;
20954      esac
20955    fi
20956  fi
20957
20958{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5
20959$as_echo "$ld_shlibs" >&6; }
20960test no = "$ld_shlibs" && can_build_shared=no
20961
20962with_gnu_ld=$with_gnu_ld
20963
20964
20965
20966
20967
20968
20969
20970
20971
20972
20973
20974
20975
20976
20977
20978#
20979# Do we need to explicitly link libc?
20980#
20981case "x$archive_cmds_need_lc" in
20982x|xyes)
20983  # Assume -lc should be added
20984  archive_cmds_need_lc=yes
20985
20986  if test yes,yes = "$GCC,$enable_shared"; then
20987    case $archive_cmds in
20988    *'~'*)
20989      # FIXME: we may have to deal with multi-command sequences.
20990      ;;
20991    '$CC '*)
20992      # Test whether the compiler implicitly links with -lc since on some
20993      # systems, -lgcc has to come before -lc. If gcc already passes -lc
20994      # to ld, don't add -lc before -lgcc.
20995      { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5
20996$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; }
20997if ${lt_cv_archive_cmds_need_lc+:} false; then :
20998  $as_echo_n "(cached) " >&6
20999else
21000  $RM conftest*
21001	echo "$lt_simple_compile_test_code" > conftest.$ac_ext
21002
21003	if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
21004  (eval $ac_compile) 2>&5
21005  ac_status=$?
21006  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
21007  test $ac_status = 0; } 2>conftest.err; then
21008	  soname=conftest
21009	  lib=conftest
21010	  libobjs=conftest.$ac_objext
21011	  deplibs=
21012	  wl=$lt_prog_compiler_wl
21013	  pic_flag=$lt_prog_compiler_pic
21014	  compiler_flags=-v
21015	  linker_flags=-v
21016	  verstring=
21017	  output_objdir=.
21018	  libname=conftest
21019	  lt_save_allow_undefined_flag=$allow_undefined_flag
21020	  allow_undefined_flag=
21021	  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5
21022  (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5
21023  ac_status=$?
21024  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
21025  test $ac_status = 0; }
21026	  then
21027	    lt_cv_archive_cmds_need_lc=no
21028	  else
21029	    lt_cv_archive_cmds_need_lc=yes
21030	  fi
21031	  allow_undefined_flag=$lt_save_allow_undefined_flag
21032	else
21033	  cat conftest.err 1>&5
21034	fi
21035	$RM conftest*
21036
21037fi
21038{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5
21039$as_echo "$lt_cv_archive_cmds_need_lc" >&6; }
21040      archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc
21041      ;;
21042    esac
21043  fi
21044  ;;
21045esac
21046
21047
21048
21049
21050
21051
21052
21053
21054
21055
21056
21057
21058
21059
21060
21061
21062
21063
21064
21065
21066
21067
21068
21069
21070
21071
21072
21073
21074
21075
21076
21077
21078
21079
21080
21081
21082
21083
21084
21085
21086
21087
21088
21089
21090
21091
21092
21093
21094
21095
21096
21097
21098
21099
21100
21101
21102
21103
21104
21105
21106
21107
21108
21109
21110
21111
21112
21113
21114
21115
21116
21117
21118
21119
21120
21121
21122
21123
21124
21125
21126
21127
21128
21129
21130
21131
21132
21133
21134
21135
21136
21137
21138
21139
21140
21141
21142
21143
21144
21145
21146
21147
21148
21149
21150
21151
21152
21153
21154
21155
21156
21157
21158
21159
21160
21161
21162
21163
21164
21165
21166
21167
21168
21169
21170
21171
21172
21173
21174
21175
21176
21177
21178
21179
21180
21181
21182
21183
21184
21185
21186
21187
21188
21189
21190
21191
21192
21193
21194
21195
21196
21197
21198  { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5
21199$as_echo_n "checking dynamic linker characteristics... " >&6; }
21200
21201if test yes = "$GCC"; then
21202  case $host_os in
21203    darwin*) lt_awk_arg='/^libraries:/,/LR/' ;;
21204    *) lt_awk_arg='/^libraries:/' ;;
21205  esac
21206  case $host_os in
21207    mingw* | cegcc*) lt_sed_strip_eq='s|=\([A-Za-z]:\)|\1|g' ;;
21208    *) lt_sed_strip_eq='s|=/|/|g' ;;
21209  esac
21210  lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
21211  case $lt_search_path_spec in
21212  *\;*)
21213    # if the path contains ";" then we assume it to be the separator
21214    # otherwise default to the standard path separator (i.e. ":") - it is
21215    # assumed that no part of a normal pathname contains ";" but that should
21216    # okay in the real world where ";" in dirpaths is itself problematic.
21217    lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
21218    ;;
21219  *)
21220    lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
21221    ;;
21222  esac
21223  # Ok, now we have the path, separated by spaces, we can step through it
21224  # and add multilib dir if necessary...
21225  lt_tmp_lt_search_path_spec=
21226  lt_multi_os_dir=/`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
21227  # ...but if some path component already ends with the multilib dir we assume
21228  # that all is fine and trust -print-search-dirs as is (GCC 4.2? or newer).
21229  case "$lt_multi_os_dir; $lt_search_path_spec " in
21230  "/; "* | "/.; "* | "/./; "* | *"$lt_multi_os_dir "* | *"$lt_multi_os_dir/ "*)
21231    lt_multi_os_dir=
21232    ;;
21233  esac
21234  for lt_sys_path in $lt_search_path_spec; do
21235    if test -d "$lt_sys_path$lt_multi_os_dir"; then
21236      lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path$lt_multi_os_dir"
21237    elif test -n "$lt_multi_os_dir"; then
21238      test -d "$lt_sys_path" && \
21239	lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
21240    fi
21241  done
21242  lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
21243BEGIN {RS = " "; FS = "/|\n";} {
21244  lt_foo = "";
21245  lt_count = 0;
21246  for (lt_i = NF; lt_i > 0; lt_i--) {
21247    if ($lt_i != "" && $lt_i != ".") {
21248      if ($lt_i == "..") {
21249        lt_count++;
21250      } else {
21251        if (lt_count == 0) {
21252          lt_foo = "/" $lt_i lt_foo;
21253        } else {
21254          lt_count--;
21255        }
21256      }
21257    }
21258  }
21259  if (lt_foo != "") { lt_freq[lt_foo]++; }
21260  if (lt_freq[lt_foo] == 1) { print lt_foo; }
21261}'`
21262  # AWK program above erroneously prepends '/' to C:/dos/paths
21263  # for these hosts.
21264  case $host_os in
21265    mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
21266      $SED 's|/\([A-Za-z]:\)|\1|g'` ;;
21267  esac
21268  sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
21269else
21270  sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
21271fi
21272library_names_spec=
21273libname_spec='lib$name'
21274soname_spec=
21275shrext_cmds=.so
21276postinstall_cmds=
21277postuninstall_cmds=
21278finish_cmds=
21279finish_eval=
21280shlibpath_var=
21281shlibpath_overrides_runpath=unknown
21282version_type=none
21283dynamic_linker="$host_os ld.so"
21284sys_lib_dlsearch_path_spec="/lib /usr/lib"
21285need_lib_prefix=unknown
21286hardcode_into_libs=no
21287
21288# when you set need_version to no, make sure it does not cause -set_version
21289# flags to be left without arguments
21290need_version=unknown
21291
21292
21293
21294case $host_os in
21295aix3*)
21296  version_type=linux # correct to gnu/linux during the next big refactor
21297  library_names_spec='$libname$release$shared_ext$versuffix $libname.a'
21298  shlibpath_var=LIBPATH
21299
21300  # AIX 3 has no versioning support, so we append a major version to the name.
21301  soname_spec='$libname$release$shared_ext$major'
21302  ;;
21303
21304aix[4-9]*)
21305  version_type=linux # correct to gnu/linux during the next big refactor
21306  need_lib_prefix=no
21307  need_version=no
21308  hardcode_into_libs=yes
21309  if test ia64 = "$host_cpu"; then
21310    # AIX 5 supports IA64
21311    library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext'
21312    shlibpath_var=LD_LIBRARY_PATH
21313  else
21314    # With GCC up to 2.95.x, collect2 would create an import file
21315    # for dependence libraries.  The import file would start with
21316    # the line '#! .'.  This would cause the generated library to
21317    # depend on '.', always an invalid library.  This was fixed in
21318    # development snapshots of GCC prior to 3.0.
21319    case $host_os in
21320      aix4 | aix4.[01] | aix4.[01].*)
21321      if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
21322	   echo ' yes '
21323	   echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then
21324	:
21325      else
21326	can_build_shared=no
21327      fi
21328      ;;
21329    esac
21330    # Using Import Files as archive members, it is possible to support
21331    # filename-based versioning of shared library archives on AIX. While
21332    # this would work for both with and without runtime linking, it will
21333    # prevent static linking of such archives. So we do filename-based
21334    # shared library versioning with .so extension only, which is used
21335    # when both runtime linking and shared linking is enabled.
21336    # Unfortunately, runtime linking may impact performance, so we do
21337    # not want this to be the default eventually. Also, we use the
21338    # versioned .so libs for executables only if there is the -brtl
21339    # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only.
21340    # To allow for filename-based versioning support, we need to create
21341    # libNAME.so.V as an archive file, containing:
21342    # *) an Import File, referring to the versioned filename of the
21343    #    archive as well as the shared archive member, telling the
21344    #    bitwidth (32 or 64) of that shared object, and providing the
21345    #    list of exported symbols of that shared object, eventually
21346    #    decorated with the 'weak' keyword
21347    # *) the shared object with the F_LOADONLY flag set, to really avoid
21348    #    it being seen by the linker.
21349    # At run time we better use the real file rather than another symlink,
21350    # but for link time we create the symlink libNAME.so -> libNAME.so.V
21351
21352    case $with_aix_soname,$aix_use_runtimelinking in
21353    # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct
21354    # soname into executable. Probably we can add versioning support to
21355    # collect2, so additional links can be useful in future.
21356    aix,yes) # traditional libtool
21357      dynamic_linker='AIX unversionable lib.so'
21358      # If using run time linking (on AIX 4.2 or later) use lib<name>.so
21359      # instead of lib<name>.a to let people know that these are not
21360      # typical AIX shared libraries.
21361      library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
21362      ;;
21363    aix,no) # traditional AIX only
21364      dynamic_linker='AIX lib.a(lib.so.V)'
21365      # We preserve .a as extension for shared libraries through AIX4.2
21366      # and later when we are not doing run time linking.
21367      library_names_spec='$libname$release.a $libname.a'
21368      soname_spec='$libname$release$shared_ext$major'
21369      ;;
21370    svr4,*) # full svr4 only
21371      dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o)"
21372      library_names_spec='$libname$release$shared_ext$major $libname$shared_ext'
21373      # We do not specify a path in Import Files, so LIBPATH fires.
21374      shlibpath_overrides_runpath=yes
21375      ;;
21376    *,yes) # both, prefer svr4
21377      dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o), lib.a(lib.so.V)"
21378      library_names_spec='$libname$release$shared_ext$major $libname$shared_ext'
21379      # unpreferred sharedlib libNAME.a needs extra handling
21380      postinstall_cmds='test -n "$linkname" || linkname="$realname"~func_stripname "" ".so" "$linkname"~$install_shared_prog "$dir/$func_stripname_result.$libext" "$destdir/$func_stripname_result.$libext"~test -z "$tstripme" || test -z "$striplib" || $striplib "$destdir/$func_stripname_result.$libext"'
21381      postuninstall_cmds='for n in $library_names $old_library; do :; done~func_stripname "" ".so" "$n"~test "$func_stripname_result" = "$n" || func_append rmfiles " $odir/$func_stripname_result.$libext"'
21382      # We do not specify a path in Import Files, so LIBPATH fires.
21383      shlibpath_overrides_runpath=yes
21384      ;;
21385    *,no) # both, prefer aix
21386      dynamic_linker="AIX lib.a(lib.so.V), lib.so.V($shared_archive_member_spec.o)"
21387      library_names_spec='$libname$release.a $libname.a'
21388      soname_spec='$libname$release$shared_ext$major'
21389      # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling
21390      postinstall_cmds='test -z "$dlname" || $install_shared_prog $dir/$dlname $destdir/$dlname~test -z "$tstripme" || test -z "$striplib" || $striplib $destdir/$dlname~test -n "$linkname" || linkname=$realname~func_stripname "" ".a" "$linkname"~(cd "$destdir" && $LN_S -f $dlname $func_stripname_result.so)'
21391      postuninstall_cmds='test -z "$dlname" || func_append rmfiles " $odir/$dlname"~for n in $old_library $library_names; do :; done~func_stripname "" ".a" "$n"~func_append rmfiles " $odir/$func_stripname_result.so"'
21392      ;;
21393    esac
21394    shlibpath_var=LIBPATH
21395  fi
21396  ;;
21397
21398amigaos*)
21399  case $host_cpu in
21400  powerpc)
21401    # Since July 2007 AmigaOS4 officially supports .so libraries.
21402    # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
21403    library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
21404    ;;
21405  m68k)
21406    library_names_spec='$libname.ixlibrary $libname.a'
21407    # Create ${libname}_ixlibrary.a entries in /sys/libs.
21408    finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
21409    ;;
21410  esac
21411  ;;
21412
21413beos*)
21414  library_names_spec='$libname$shared_ext'
21415  dynamic_linker="$host_os ld.so"
21416  shlibpath_var=LIBRARY_PATH
21417  ;;
21418
21419bsdi[45]*)
21420  version_type=linux # correct to gnu/linux during the next big refactor
21421  need_version=no
21422  library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
21423  soname_spec='$libname$release$shared_ext$major'
21424  finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
21425  shlibpath_var=LD_LIBRARY_PATH
21426  sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
21427  sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
21428  # the default ld.so.conf also contains /usr/contrib/lib and
21429  # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
21430  # libtool to hard-code these into programs
21431  ;;
21432
21433cygwin* | mingw* | pw32* | cegcc*)
21434  version_type=windows
21435  shrext_cmds=.dll
21436  need_version=no
21437  need_lib_prefix=no
21438
21439  case $GCC,$cc_basename in
21440  yes,*)
21441    # gcc
21442    library_names_spec='$libname.dll.a'
21443    # DLL is installed to $(libdir)/../bin by postinstall_cmds
21444    postinstall_cmds='base_file=`basename \$file`~
21445      dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~
21446      dldir=$destdir/`dirname \$dlpath`~
21447      test -d \$dldir || mkdir -p \$dldir~
21448      $install_prog $dir/$dlname \$dldir/$dlname~
21449      chmod a+x \$dldir/$dlname~
21450      if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
21451        eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
21452      fi'
21453    postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
21454      dlpath=$dir/\$dldll~
21455       $RM \$dlpath'
21456    shlibpath_overrides_runpath=yes
21457
21458    case $host_os in
21459    cygwin*)
21460      # Cygwin DLLs use 'cyg' prefix rather than 'lib'
21461      soname_spec='`echo $libname | sed -e 's/^lib/cyg/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
21462
21463      sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"
21464      ;;
21465    mingw* | cegcc*)
21466      # MinGW DLLs use traditional 'lib' prefix
21467      soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
21468      ;;
21469    pw32*)
21470      # pw32 DLLs use 'pw' prefix rather than 'lib'
21471      library_names_spec='`echo $libname | sed -e 's/^lib/pw/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
21472      ;;
21473    esac
21474    dynamic_linker='Win32 ld.exe'
21475    ;;
21476
21477  *,cl*)
21478    # Native MSVC
21479    libname_spec='$name'
21480    soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
21481    library_names_spec='$libname.dll.lib'
21482
21483    case $build_os in
21484    mingw*)
21485      sys_lib_search_path_spec=
21486      lt_save_ifs=$IFS
21487      IFS=';'
21488      for lt_path in $LIB
21489      do
21490        IFS=$lt_save_ifs
21491        # Let DOS variable expansion print the short 8.3 style file name.
21492        lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
21493        sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
21494      done
21495      IFS=$lt_save_ifs
21496      # Convert to MSYS style.
21497      sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'`
21498      ;;
21499    cygwin*)
21500      # Convert to unix form, then to dos form, then back to unix form
21501      # but this time dos style (no spaces!) so that the unix form looks
21502      # like /cygdrive/c/PROGRA~1:/cygdr...
21503      sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
21504      sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
21505      sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
21506      ;;
21507    *)
21508      sys_lib_search_path_spec=$LIB
21509      if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
21510        # It is most probably a Windows format PATH.
21511        sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
21512      else
21513        sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
21514      fi
21515      # FIXME: find the short name or the path components, as spaces are
21516      # common. (e.g. "Program Files" -> "PROGRA~1")
21517      ;;
21518    esac
21519
21520    # DLL is installed to $(libdir)/../bin by postinstall_cmds
21521    postinstall_cmds='base_file=`basename \$file`~
21522      dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~
21523      dldir=$destdir/`dirname \$dlpath`~
21524      test -d \$dldir || mkdir -p \$dldir~
21525      $install_prog $dir/$dlname \$dldir/$dlname'
21526    postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
21527      dlpath=$dir/\$dldll~
21528       $RM \$dlpath'
21529    shlibpath_overrides_runpath=yes
21530    dynamic_linker='Win32 link.exe'
21531    ;;
21532
21533  *)
21534    # Assume MSVC wrapper
21535    library_names_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext $libname.lib'
21536    dynamic_linker='Win32 ld.exe'
21537    ;;
21538  esac
21539  # FIXME: first we should search . and the directory the executable is in
21540  shlibpath_var=PATH
21541  ;;
21542
21543darwin* | rhapsody*)
21544  dynamic_linker="$host_os dyld"
21545  version_type=darwin
21546  need_lib_prefix=no
21547  need_version=no
21548  library_names_spec='$libname$release$major$shared_ext $libname$shared_ext'
21549  soname_spec='$libname$release$major$shared_ext'
21550  shlibpath_overrides_runpath=yes
21551  shlibpath_var=DYLD_LIBRARY_PATH
21552  shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
21553
21554  sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"
21555  sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
21556  ;;
21557
21558dgux*)
21559  version_type=linux # correct to gnu/linux during the next big refactor
21560  need_lib_prefix=no
21561  need_version=no
21562  library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
21563  soname_spec='$libname$release$shared_ext$major'
21564  shlibpath_var=LD_LIBRARY_PATH
21565  ;;
21566
21567freebsd* | dragonfly*)
21568  # DragonFly does not have aout.  When/if they implement a new
21569  # versioning mechanism, adjust this.
21570  if test -x /usr/bin/objformat; then
21571    objformat=`/usr/bin/objformat`
21572  else
21573    case $host_os in
21574    freebsd[23].*) objformat=aout ;;
21575    *) objformat=elf ;;
21576    esac
21577  fi
21578  version_type=freebsd-$objformat
21579  case $version_type in
21580    freebsd-elf*)
21581      library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
21582      soname_spec='$libname$release$shared_ext$major'
21583      need_version=no
21584      need_lib_prefix=no
21585      ;;
21586    freebsd-*)
21587      library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
21588      need_version=yes
21589      ;;
21590  esac
21591  shlibpath_var=LD_LIBRARY_PATH
21592  case $host_os in
21593  freebsd2.*)
21594    shlibpath_overrides_runpath=yes
21595    ;;
21596  freebsd3.[01]* | freebsdelf3.[01]*)
21597    shlibpath_overrides_runpath=yes
21598    hardcode_into_libs=yes
21599    ;;
21600  freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
21601  freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
21602    shlibpath_overrides_runpath=no
21603    hardcode_into_libs=yes
21604    ;;
21605  *) # from 4.6 on, and DragonFly
21606    shlibpath_overrides_runpath=yes
21607    hardcode_into_libs=yes
21608    ;;
21609  esac
21610  ;;
21611
21612haiku*)
21613  version_type=linux # correct to gnu/linux during the next big refactor
21614  need_lib_prefix=no
21615  need_version=no
21616  dynamic_linker="$host_os runtime_loader"
21617  library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
21618  soname_spec='$libname$release$shared_ext$major'
21619  shlibpath_var=LIBRARY_PATH
21620  shlibpath_overrides_runpath=no
21621  sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
21622  hardcode_into_libs=yes
21623  ;;
21624
21625hpux9* | hpux10* | hpux11*)
21626  # Give a soname corresponding to the major version so that dld.sl refuses to
21627  # link against other versions.
21628  version_type=sunos
21629  need_lib_prefix=no
21630  need_version=no
21631  case $host_cpu in
21632  ia64*)
21633    shrext_cmds='.so'
21634    hardcode_into_libs=yes
21635    dynamic_linker="$host_os dld.so"
21636    shlibpath_var=LD_LIBRARY_PATH
21637    shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
21638    library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
21639    soname_spec='$libname$release$shared_ext$major'
21640    if test 32 = "$HPUX_IA64_MODE"; then
21641      sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
21642      sys_lib_dlsearch_path_spec=/usr/lib/hpux32
21643    else
21644      sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
21645      sys_lib_dlsearch_path_spec=/usr/lib/hpux64
21646    fi
21647    ;;
21648  hppa*64*)
21649    shrext_cmds='.sl'
21650    hardcode_into_libs=yes
21651    dynamic_linker="$host_os dld.sl"
21652    shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
21653    shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
21654    library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
21655    soname_spec='$libname$release$shared_ext$major'
21656    sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
21657    sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
21658    ;;
21659  *)
21660    shrext_cmds='.sl'
21661    dynamic_linker="$host_os dld.sl"
21662    shlibpath_var=SHLIB_PATH
21663    shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
21664    library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
21665    soname_spec='$libname$release$shared_ext$major'
21666    ;;
21667  esac
21668  # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
21669  postinstall_cmds='chmod 555 $lib'
21670  # or fails outright, so override atomically:
21671  install_override_mode=555
21672  ;;
21673
21674interix[3-9]*)
21675  version_type=linux # correct to gnu/linux during the next big refactor
21676  need_lib_prefix=no
21677  need_version=no
21678  library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
21679  soname_spec='$libname$release$shared_ext$major'
21680  dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
21681  shlibpath_var=LD_LIBRARY_PATH
21682  shlibpath_overrides_runpath=no
21683  hardcode_into_libs=yes
21684  ;;
21685
21686irix5* | irix6* | nonstopux*)
21687  case $host_os in
21688    nonstopux*) version_type=nonstopux ;;
21689    *)
21690	if test yes = "$lt_cv_prog_gnu_ld"; then
21691		version_type=linux # correct to gnu/linux during the next big refactor
21692	else
21693		version_type=irix
21694	fi ;;
21695  esac
21696  need_lib_prefix=no
21697  need_version=no
21698  soname_spec='$libname$release$shared_ext$major'
21699  library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext'
21700  case $host_os in
21701  irix5* | nonstopux*)
21702    libsuff= shlibsuff=
21703    ;;
21704  *)
21705    case $LD in # libtool.m4 will add one of these switches to LD
21706    *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
21707      libsuff= shlibsuff= libmagic=32-bit;;
21708    *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
21709      libsuff=32 shlibsuff=N32 libmagic=N32;;
21710    *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
21711      libsuff=64 shlibsuff=64 libmagic=64-bit;;
21712    *) libsuff= shlibsuff= libmagic=never-match;;
21713    esac
21714    ;;
21715  esac
21716  shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
21717  shlibpath_overrides_runpath=no
21718  sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff"
21719  sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff"
21720  hardcode_into_libs=yes
21721  ;;
21722
21723# No shared lib support for Linux oldld, aout, or coff.
21724linux*oldld* | linux*aout* | linux*coff*)
21725  dynamic_linker=no
21726  ;;
21727
21728linux*android*)
21729  version_type=none # Android doesn't support versioned libraries.
21730  need_lib_prefix=no
21731  need_version=no
21732  library_names_spec='$libname$release$shared_ext'
21733  soname_spec='$libname$release$shared_ext'
21734  finish_cmds=
21735  shlibpath_var=LD_LIBRARY_PATH
21736  shlibpath_overrides_runpath=yes
21737
21738  # This implies no fast_install, which is unacceptable.
21739  # Some rework will be needed to allow for fast_install
21740  # before this can be enabled.
21741  hardcode_into_libs=yes
21742
21743  dynamic_linker='Android linker'
21744  # Don't embed -rpath directories since the linker doesn't support them.
21745  hardcode_libdir_flag_spec='-L$libdir'
21746  ;;
21747
21748# This must be glibc/ELF.
21749linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
21750  version_type=linux # correct to gnu/linux during the next big refactor
21751  need_lib_prefix=no
21752  need_version=no
21753  library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
21754  soname_spec='$libname$release$shared_ext$major'
21755  finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
21756  shlibpath_var=LD_LIBRARY_PATH
21757  shlibpath_overrides_runpath=no
21758
21759  # Some binutils ld are patched to set DT_RUNPATH
21760  if ${lt_cv_shlibpath_overrides_runpath+:} false; then :
21761  $as_echo_n "(cached) " >&6
21762else
21763  lt_cv_shlibpath_overrides_runpath=no
21764    save_LDFLAGS=$LDFLAGS
21765    save_libdir=$libdir
21766    eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \
21767	 LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\""
21768    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21769/* end confdefs.h.  */
21770
21771int
21772main ()
21773{
21774
21775  ;
21776  return 0;
21777}
21778_ACEOF
21779if ac_fn_c_try_link "$LINENO"; then :
21780  if  ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then :
21781  lt_cv_shlibpath_overrides_runpath=yes
21782fi
21783fi
21784rm -f core conftest.err conftest.$ac_objext \
21785    conftest$ac_exeext conftest.$ac_ext
21786    LDFLAGS=$save_LDFLAGS
21787    libdir=$save_libdir
21788
21789fi
21790
21791  shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
21792
21793  # This implies no fast_install, which is unacceptable.
21794  # Some rework will be needed to allow for fast_install
21795  # before this can be enabled.
21796  hardcode_into_libs=yes
21797
21798  # Ideally, we could use ldconfig to report *all* directores which are
21799  # searched for libraries, however this is still not possible.  Aside from not
21800  # being certain /sbin/ldconfig is available, command
21801  # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64,
21802  # even though it is searched at run-time.  Try to do the best guess by
21803  # appending ld.so.conf contents (and includes) to the search path.
21804  if test -f /etc/ld.so.conf; then
21805    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' ' '`
21806    sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
21807  fi
21808
21809  # We used to test for /lib/ld.so.1 and disable shared libraries on
21810  # powerpc, because MkLinux only supported shared libraries with the
21811  # GNU dynamic linker.  Since this was broken with cross compilers,
21812  # most powerpc-linux boxes support dynamic linking these days and
21813  # people can always --disable-shared, the test was removed, and we
21814  # assume the GNU/Linux dynamic linker is in use.
21815  dynamic_linker='GNU/Linux ld.so'
21816  ;;
21817
21818netbsd*)
21819  version_type=sunos
21820  need_lib_prefix=no
21821  need_version=no
21822  if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
21823    library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
21824    finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
21825    dynamic_linker='NetBSD (a.out) ld.so'
21826  else
21827    library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
21828    soname_spec='$libname$release$shared_ext$major'
21829    dynamic_linker='NetBSD ld.elf_so'
21830  fi
21831  shlibpath_var=LD_LIBRARY_PATH
21832  shlibpath_overrides_runpath=yes
21833  hardcode_into_libs=yes
21834  ;;
21835
21836newsos6)
21837  version_type=linux # correct to gnu/linux during the next big refactor
21838  library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
21839  shlibpath_var=LD_LIBRARY_PATH
21840  shlibpath_overrides_runpath=yes
21841  ;;
21842
21843*nto* | *qnx*)
21844  version_type=qnx
21845  need_lib_prefix=no
21846  need_version=no
21847  library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
21848  soname_spec='$libname$release$shared_ext$major'
21849  shlibpath_var=LD_LIBRARY_PATH
21850  shlibpath_overrides_runpath=no
21851  hardcode_into_libs=yes
21852  dynamic_linker='ldqnx.so'
21853  ;;
21854
21855openbsd* | bitrig*)
21856  version_type=sunos
21857  sys_lib_dlsearch_path_spec=/usr/lib
21858  need_lib_prefix=no
21859  if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
21860    need_version=no
21861  else
21862    need_version=yes
21863  fi
21864  library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
21865  finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
21866  shlibpath_var=LD_LIBRARY_PATH
21867  shlibpath_overrides_runpath=yes
21868  ;;
21869
21870os2*)
21871  libname_spec='$name'
21872  version_type=windows
21873  shrext_cmds=.dll
21874  need_version=no
21875  need_lib_prefix=no
21876  # OS/2 can only load a DLL with a base name of 8 characters or less.
21877  soname_spec='`test -n "$os2dllname" && libname="$os2dllname";
21878    v=$($ECHO $release$versuffix | tr -d .-);
21879    n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _);
21880    $ECHO $n$v`$shared_ext'
21881  library_names_spec='${libname}_dll.$libext'
21882  dynamic_linker='OS/2 ld.exe'
21883  shlibpath_var=BEGINLIBPATH
21884  sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
21885  sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
21886  postinstall_cmds='base_file=`basename \$file`~
21887    dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~
21888    dldir=$destdir/`dirname \$dlpath`~
21889    test -d \$dldir || mkdir -p \$dldir~
21890    $install_prog $dir/$dlname \$dldir/$dlname~
21891    chmod a+x \$dldir/$dlname~
21892    if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
21893      eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
21894    fi'
21895  postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~
21896    dlpath=$dir/\$dldll~
21897    $RM \$dlpath'
21898  ;;
21899
21900osf3* | osf4* | osf5*)
21901  version_type=osf
21902  need_lib_prefix=no
21903  need_version=no
21904  soname_spec='$libname$release$shared_ext$major'
21905  library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
21906  shlibpath_var=LD_LIBRARY_PATH
21907  sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
21908  sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
21909  ;;
21910
21911rdos*)
21912  dynamic_linker=no
21913  ;;
21914
21915solaris*)
21916  version_type=linux # correct to gnu/linux during the next big refactor
21917  need_lib_prefix=no
21918  need_version=no
21919  library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
21920  soname_spec='$libname$release$shared_ext$major'
21921  shlibpath_var=LD_LIBRARY_PATH
21922  shlibpath_overrides_runpath=yes
21923  hardcode_into_libs=yes
21924  # ldd complains unless libraries are executable
21925  postinstall_cmds='chmod +x $lib'
21926  ;;
21927
21928sunos4*)
21929  version_type=sunos
21930  library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
21931  finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
21932  shlibpath_var=LD_LIBRARY_PATH
21933  shlibpath_overrides_runpath=yes
21934  if test yes = "$with_gnu_ld"; then
21935    need_lib_prefix=no
21936  fi
21937  need_version=yes
21938  ;;
21939
21940sysv4 | sysv4.3*)
21941  version_type=linux # correct to gnu/linux during the next big refactor
21942  library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
21943  soname_spec='$libname$release$shared_ext$major'
21944  shlibpath_var=LD_LIBRARY_PATH
21945  case $host_vendor in
21946    sni)
21947      shlibpath_overrides_runpath=no
21948      need_lib_prefix=no
21949      runpath_var=LD_RUN_PATH
21950      ;;
21951    siemens)
21952      need_lib_prefix=no
21953      ;;
21954    motorola)
21955      need_lib_prefix=no
21956      need_version=no
21957      shlibpath_overrides_runpath=no
21958      sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
21959      ;;
21960  esac
21961  ;;
21962
21963sysv4*MP*)
21964  if test -d /usr/nec; then
21965    version_type=linux # correct to gnu/linux during the next big refactor
21966    library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext'
21967    soname_spec='$libname$shared_ext.$major'
21968    shlibpath_var=LD_LIBRARY_PATH
21969  fi
21970  ;;
21971
21972sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
21973  version_type=sco
21974  need_lib_prefix=no
21975  need_version=no
21976  library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext'
21977  soname_spec='$libname$release$shared_ext$major'
21978  shlibpath_var=LD_LIBRARY_PATH
21979  shlibpath_overrides_runpath=yes
21980  hardcode_into_libs=yes
21981  if test yes = "$with_gnu_ld"; then
21982    sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
21983  else
21984    sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
21985    case $host_os in
21986      sco3.2v5*)
21987        sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
21988	;;
21989    esac
21990  fi
21991  sys_lib_dlsearch_path_spec='/usr/lib'
21992  ;;
21993
21994tpf*)
21995  # TPF is a cross-target only.  Preferred cross-host = GNU/Linux.
21996  version_type=linux # correct to gnu/linux during the next big refactor
21997  need_lib_prefix=no
21998  need_version=no
21999  library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
22000  shlibpath_var=LD_LIBRARY_PATH
22001  shlibpath_overrides_runpath=no
22002  hardcode_into_libs=yes
22003  ;;
22004
22005uts4*)
22006  version_type=linux # correct to gnu/linux during the next big refactor
22007  library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
22008  soname_spec='$libname$release$shared_ext$major'
22009  shlibpath_var=LD_LIBRARY_PATH
22010  ;;
22011
22012*)
22013  dynamic_linker=no
22014  ;;
22015esac
22016{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5
22017$as_echo "$dynamic_linker" >&6; }
22018test no = "$dynamic_linker" && can_build_shared=no
22019
22020variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
22021if test yes = "$GCC"; then
22022  variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
22023fi
22024
22025if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then
22026  sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec
22027fi
22028
22029if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then
22030  sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec
22031fi
22032
22033# remember unaugmented sys_lib_dlsearch_path content for libtool script decls...
22034configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec
22035
22036# ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code
22037func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH"
22038
22039# to be used as default LT_SYS_LIBRARY_PATH value in generated libtool
22040configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH
22041
22042
22043
22044
22045
22046
22047
22048
22049
22050
22051
22052
22053
22054
22055
22056
22057
22058
22059
22060
22061
22062
22063
22064
22065
22066
22067
22068
22069
22070
22071
22072
22073
22074
22075
22076
22077
22078
22079
22080
22081
22082
22083
22084
22085
22086
22087
22088
22089
22090
22091
22092
22093
22094
22095
22096
22097
22098
22099
22100
22101
22102
22103
22104
22105
22106
22107
22108
22109
22110
22111
22112
22113
22114
22115
22116
22117
22118
22119
22120
22121
22122
22123
22124
22125
22126
22127
22128
22129
22130
22131
22132
22133
22134
22135
22136
22137
22138  { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5
22139$as_echo_n "checking how to hardcode library paths into programs... " >&6; }
22140hardcode_action=
22141if test -n "$hardcode_libdir_flag_spec" ||
22142   test -n "$runpath_var" ||
22143   test yes = "$hardcode_automatic"; then
22144
22145  # We can hardcode non-existent directories.
22146  if test no != "$hardcode_direct" &&
22147     # If the only mechanism to avoid hardcoding is shlibpath_var, we
22148     # have to relink, otherwise we might link with an installed library
22149     # when we should be linking with a yet-to-be-installed one
22150     ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, )" &&
22151     test no != "$hardcode_minus_L"; then
22152    # Linking always hardcodes the temporary library directory.
22153    hardcode_action=relink
22154  else
22155    # We can link without hardcoding, and we can hardcode nonexisting dirs.
22156    hardcode_action=immediate
22157  fi
22158else
22159  # We cannot hardcode anything, or else we can only hardcode existing
22160  # directories.
22161  hardcode_action=unsupported
22162fi
22163{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5
22164$as_echo "$hardcode_action" >&6; }
22165
22166if test relink = "$hardcode_action" ||
22167   test yes = "$inherit_rpath"; then
22168  # Fast installation is not supported
22169  enable_fast_install=no
22170elif test yes = "$shlibpath_overrides_runpath" ||
22171     test no = "$enable_shared"; then
22172  # Fast installation is not necessary
22173  enable_fast_install=needless
22174fi
22175
22176
22177
22178
22179
22180
22181  if test yes != "$enable_dlopen"; then
22182  enable_dlopen=unknown
22183  enable_dlopen_self=unknown
22184  enable_dlopen_self_static=unknown
22185else
22186  lt_cv_dlopen=no
22187  lt_cv_dlopen_libs=
22188
22189  case $host_os in
22190  beos*)
22191    lt_cv_dlopen=load_add_on
22192    lt_cv_dlopen_libs=
22193    lt_cv_dlopen_self=yes
22194    ;;
22195
22196  mingw* | pw32* | cegcc*)
22197    lt_cv_dlopen=LoadLibrary
22198    lt_cv_dlopen_libs=
22199    ;;
22200
22201  cygwin*)
22202    lt_cv_dlopen=dlopen
22203    lt_cv_dlopen_libs=
22204    ;;
22205
22206  darwin*)
22207    # if libdl is installed we need to link against it
22208    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
22209$as_echo_n "checking for dlopen in -ldl... " >&6; }
22210if ${ac_cv_lib_dl_dlopen+:} false; then :
22211  $as_echo_n "(cached) " >&6
22212else
22213  ac_check_lib_save_LIBS=$LIBS
22214LIBS="-ldl  $LIBS"
22215cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22216/* end confdefs.h.  */
22217
22218/* Override any GCC internal prototype to avoid an error.
22219   Use char because int might match the return type of a GCC
22220   builtin and then its argument prototype would still apply.  */
22221#ifdef __cplusplus
22222extern "C"
22223#endif
22224char dlopen ();
22225int
22226main ()
22227{
22228return dlopen ();
22229  ;
22230  return 0;
22231}
22232_ACEOF
22233if ac_fn_c_try_link "$LINENO"; then :
22234  ac_cv_lib_dl_dlopen=yes
22235else
22236  ac_cv_lib_dl_dlopen=no
22237fi
22238rm -f core conftest.err conftest.$ac_objext \
22239    conftest$ac_exeext conftest.$ac_ext
22240LIBS=$ac_check_lib_save_LIBS
22241fi
22242{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
22243$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
22244if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
22245  lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl
22246else
22247
22248    lt_cv_dlopen=dyld
22249    lt_cv_dlopen_libs=
22250    lt_cv_dlopen_self=yes
22251
22252fi
22253
22254    ;;
22255
22256  tpf*)
22257    # Don't try to run any link tests for TPF.  We know it's impossible
22258    # because TPF is a cross-compiler, and we know how we open DSOs.
22259    lt_cv_dlopen=dlopen
22260    lt_cv_dlopen_libs=
22261    lt_cv_dlopen_self=no
22262    ;;
22263
22264  *)
22265    ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load"
22266if test "x$ac_cv_func_shl_load" = xyes; then :
22267  lt_cv_dlopen=shl_load
22268else
22269  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5
22270$as_echo_n "checking for shl_load in -ldld... " >&6; }
22271if ${ac_cv_lib_dld_shl_load+:} false; then :
22272  $as_echo_n "(cached) " >&6
22273else
22274  ac_check_lib_save_LIBS=$LIBS
22275LIBS="-ldld  $LIBS"
22276cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22277/* end confdefs.h.  */
22278
22279/* Override any GCC internal prototype to avoid an error.
22280   Use char because int might match the return type of a GCC
22281   builtin and then its argument prototype would still apply.  */
22282#ifdef __cplusplus
22283extern "C"
22284#endif
22285char shl_load ();
22286int
22287main ()
22288{
22289return shl_load ();
22290  ;
22291  return 0;
22292}
22293_ACEOF
22294if ac_fn_c_try_link "$LINENO"; then :
22295  ac_cv_lib_dld_shl_load=yes
22296else
22297  ac_cv_lib_dld_shl_load=no
22298fi
22299rm -f core conftest.err conftest.$ac_objext \
22300    conftest$ac_exeext conftest.$ac_ext
22301LIBS=$ac_check_lib_save_LIBS
22302fi
22303{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5
22304$as_echo "$ac_cv_lib_dld_shl_load" >&6; }
22305if test "x$ac_cv_lib_dld_shl_load" = xyes; then :
22306  lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld
22307else
22308  ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen"
22309if test "x$ac_cv_func_dlopen" = xyes; then :
22310  lt_cv_dlopen=dlopen
22311else
22312  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
22313$as_echo_n "checking for dlopen in -ldl... " >&6; }
22314if ${ac_cv_lib_dl_dlopen+:} false; then :
22315  $as_echo_n "(cached) " >&6
22316else
22317  ac_check_lib_save_LIBS=$LIBS
22318LIBS="-ldl  $LIBS"
22319cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22320/* end confdefs.h.  */
22321
22322/* Override any GCC internal prototype to avoid an error.
22323   Use char because int might match the return type of a GCC
22324   builtin and then its argument prototype would still apply.  */
22325#ifdef __cplusplus
22326extern "C"
22327#endif
22328char dlopen ();
22329int
22330main ()
22331{
22332return dlopen ();
22333  ;
22334  return 0;
22335}
22336_ACEOF
22337if ac_fn_c_try_link "$LINENO"; then :
22338  ac_cv_lib_dl_dlopen=yes
22339else
22340  ac_cv_lib_dl_dlopen=no
22341fi
22342rm -f core conftest.err conftest.$ac_objext \
22343    conftest$ac_exeext conftest.$ac_ext
22344LIBS=$ac_check_lib_save_LIBS
22345fi
22346{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
22347$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
22348if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
22349  lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl
22350else
22351  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5
22352$as_echo_n "checking for dlopen in -lsvld... " >&6; }
22353if ${ac_cv_lib_svld_dlopen+:} false; then :
22354  $as_echo_n "(cached) " >&6
22355else
22356  ac_check_lib_save_LIBS=$LIBS
22357LIBS="-lsvld  $LIBS"
22358cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22359/* end confdefs.h.  */
22360
22361/* Override any GCC internal prototype to avoid an error.
22362   Use char because int might match the return type of a GCC
22363   builtin and then its argument prototype would still apply.  */
22364#ifdef __cplusplus
22365extern "C"
22366#endif
22367char dlopen ();
22368int
22369main ()
22370{
22371return dlopen ();
22372  ;
22373  return 0;
22374}
22375_ACEOF
22376if ac_fn_c_try_link "$LINENO"; then :
22377  ac_cv_lib_svld_dlopen=yes
22378else
22379  ac_cv_lib_svld_dlopen=no
22380fi
22381rm -f core conftest.err conftest.$ac_objext \
22382    conftest$ac_exeext conftest.$ac_ext
22383LIBS=$ac_check_lib_save_LIBS
22384fi
22385{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5
22386$as_echo "$ac_cv_lib_svld_dlopen" >&6; }
22387if test "x$ac_cv_lib_svld_dlopen" = xyes; then :
22388  lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld
22389else
22390  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5
22391$as_echo_n "checking for dld_link in -ldld... " >&6; }
22392if ${ac_cv_lib_dld_dld_link+:} false; then :
22393  $as_echo_n "(cached) " >&6
22394else
22395  ac_check_lib_save_LIBS=$LIBS
22396LIBS="-ldld  $LIBS"
22397cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22398/* end confdefs.h.  */
22399
22400/* Override any GCC internal prototype to avoid an error.
22401   Use char because int might match the return type of a GCC
22402   builtin and then its argument prototype would still apply.  */
22403#ifdef __cplusplus
22404extern "C"
22405#endif
22406char dld_link ();
22407int
22408main ()
22409{
22410return dld_link ();
22411  ;
22412  return 0;
22413}
22414_ACEOF
22415if ac_fn_c_try_link "$LINENO"; then :
22416  ac_cv_lib_dld_dld_link=yes
22417else
22418  ac_cv_lib_dld_dld_link=no
22419fi
22420rm -f core conftest.err conftest.$ac_objext \
22421    conftest$ac_exeext conftest.$ac_ext
22422LIBS=$ac_check_lib_save_LIBS
22423fi
22424{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5
22425$as_echo "$ac_cv_lib_dld_dld_link" >&6; }
22426if test "x$ac_cv_lib_dld_dld_link" = xyes; then :
22427  lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld
22428fi
22429
22430
22431fi
22432
22433
22434fi
22435
22436
22437fi
22438
22439
22440fi
22441
22442
22443fi
22444
22445    ;;
22446  esac
22447
22448  if test no = "$lt_cv_dlopen"; then
22449    enable_dlopen=no
22450  else
22451    enable_dlopen=yes
22452  fi
22453
22454  case $lt_cv_dlopen in
22455  dlopen)
22456    save_CPPFLAGS=$CPPFLAGS
22457    test yes = "$ac_cv_header_dlfcn_h" && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
22458
22459    save_LDFLAGS=$LDFLAGS
22460    wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
22461
22462    save_LIBS=$LIBS
22463    LIBS="$lt_cv_dlopen_libs $LIBS"
22464
22465    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5
22466$as_echo_n "checking whether a program can dlopen itself... " >&6; }
22467if ${lt_cv_dlopen_self+:} false; then :
22468  $as_echo_n "(cached) " >&6
22469else
22470  	  if test yes = "$cross_compiling"; then :
22471  lt_cv_dlopen_self=cross
22472else
22473  lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
22474  lt_status=$lt_dlunknown
22475  cat > conftest.$ac_ext <<_LT_EOF
22476#line $LINENO "configure"
22477#include "confdefs.h"
22478
22479#if HAVE_DLFCN_H
22480#include <dlfcn.h>
22481#endif
22482
22483#include <stdio.h>
22484
22485#ifdef RTLD_GLOBAL
22486#  define LT_DLGLOBAL		RTLD_GLOBAL
22487#else
22488#  ifdef DL_GLOBAL
22489#    define LT_DLGLOBAL		DL_GLOBAL
22490#  else
22491#    define LT_DLGLOBAL		0
22492#  endif
22493#endif
22494
22495/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
22496   find out it does not work in some platform. */
22497#ifndef LT_DLLAZY_OR_NOW
22498#  ifdef RTLD_LAZY
22499#    define LT_DLLAZY_OR_NOW		RTLD_LAZY
22500#  else
22501#    ifdef DL_LAZY
22502#      define LT_DLLAZY_OR_NOW		DL_LAZY
22503#    else
22504#      ifdef RTLD_NOW
22505#        define LT_DLLAZY_OR_NOW	RTLD_NOW
22506#      else
22507#        ifdef DL_NOW
22508#          define LT_DLLAZY_OR_NOW	DL_NOW
22509#        else
22510#          define LT_DLLAZY_OR_NOW	0
22511#        endif
22512#      endif
22513#    endif
22514#  endif
22515#endif
22516
22517/* When -fvisibility=hidden is used, assume the code has been annotated
22518   correspondingly for the symbols needed.  */
22519#if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
22520int fnord () __attribute__((visibility("default")));
22521#endif
22522
22523int fnord () { return 42; }
22524int main ()
22525{
22526  void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
22527  int status = $lt_dlunknown;
22528
22529  if (self)
22530    {
22531      if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
22532      else
22533        {
22534	  if (dlsym( self,"_fnord"))  status = $lt_dlneed_uscore;
22535          else puts (dlerror ());
22536	}
22537      /* dlclose (self); */
22538    }
22539  else
22540    puts (dlerror ());
22541
22542  return status;
22543}
22544_LT_EOF
22545  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
22546  (eval $ac_link) 2>&5
22547  ac_status=$?
22548  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
22549  test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then
22550    (./conftest; exit; ) >&5 2>/dev/null
22551    lt_status=$?
22552    case x$lt_status in
22553      x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
22554      x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
22555      x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;;
22556    esac
22557  else :
22558    # compilation failed
22559    lt_cv_dlopen_self=no
22560  fi
22561fi
22562rm -fr conftest*
22563
22564
22565fi
22566{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5
22567$as_echo "$lt_cv_dlopen_self" >&6; }
22568
22569    if test yes = "$lt_cv_dlopen_self"; then
22570      wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
22571      { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5
22572$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; }
22573if ${lt_cv_dlopen_self_static+:} false; then :
22574  $as_echo_n "(cached) " >&6
22575else
22576  	  if test yes = "$cross_compiling"; then :
22577  lt_cv_dlopen_self_static=cross
22578else
22579  lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
22580  lt_status=$lt_dlunknown
22581  cat > conftest.$ac_ext <<_LT_EOF
22582#line $LINENO "configure"
22583#include "confdefs.h"
22584
22585#if HAVE_DLFCN_H
22586#include <dlfcn.h>
22587#endif
22588
22589#include <stdio.h>
22590
22591#ifdef RTLD_GLOBAL
22592#  define LT_DLGLOBAL		RTLD_GLOBAL
22593#else
22594#  ifdef DL_GLOBAL
22595#    define LT_DLGLOBAL		DL_GLOBAL
22596#  else
22597#    define LT_DLGLOBAL		0
22598#  endif
22599#endif
22600
22601/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
22602   find out it does not work in some platform. */
22603#ifndef LT_DLLAZY_OR_NOW
22604#  ifdef RTLD_LAZY
22605#    define LT_DLLAZY_OR_NOW		RTLD_LAZY
22606#  else
22607#    ifdef DL_LAZY
22608#      define LT_DLLAZY_OR_NOW		DL_LAZY
22609#    else
22610#      ifdef RTLD_NOW
22611#        define LT_DLLAZY_OR_NOW	RTLD_NOW
22612#      else
22613#        ifdef DL_NOW
22614#          define LT_DLLAZY_OR_NOW	DL_NOW
22615#        else
22616#          define LT_DLLAZY_OR_NOW	0
22617#        endif
22618#      endif
22619#    endif
22620#  endif
22621#endif
22622
22623/* When -fvisibility=hidden is used, assume the code has been annotated
22624   correspondingly for the symbols needed.  */
22625#if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
22626int fnord () __attribute__((visibility("default")));
22627#endif
22628
22629int fnord () { return 42; }
22630int main ()
22631{
22632  void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
22633  int status = $lt_dlunknown;
22634
22635  if (self)
22636    {
22637      if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
22638      else
22639        {
22640	  if (dlsym( self,"_fnord"))  status = $lt_dlneed_uscore;
22641          else puts (dlerror ());
22642	}
22643      /* dlclose (self); */
22644    }
22645  else
22646    puts (dlerror ());
22647
22648  return status;
22649}
22650_LT_EOF
22651  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
22652  (eval $ac_link) 2>&5
22653  ac_status=$?
22654  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
22655  test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then
22656    (./conftest; exit; ) >&5 2>/dev/null
22657    lt_status=$?
22658    case x$lt_status in
22659      x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
22660      x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
22661      x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;;
22662    esac
22663  else :
22664    # compilation failed
22665    lt_cv_dlopen_self_static=no
22666  fi
22667fi
22668rm -fr conftest*
22669
22670
22671fi
22672{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5
22673$as_echo "$lt_cv_dlopen_self_static" >&6; }
22674    fi
22675
22676    CPPFLAGS=$save_CPPFLAGS
22677    LDFLAGS=$save_LDFLAGS
22678    LIBS=$save_LIBS
22679    ;;
22680  esac
22681
22682  case $lt_cv_dlopen_self in
22683  yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
22684  *) enable_dlopen_self=unknown ;;
22685  esac
22686
22687  case $lt_cv_dlopen_self_static in
22688  yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
22689  *) enable_dlopen_self_static=unknown ;;
22690  esac
22691fi
22692
22693
22694
22695
22696
22697
22698
22699
22700
22701
22702
22703
22704
22705
22706
22707
22708
22709striplib=
22710old_striplib=
22711{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5
22712$as_echo_n "checking whether stripping libraries is possible... " >&6; }
22713if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
22714  test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
22715  test -z "$striplib" && striplib="$STRIP --strip-unneeded"
22716  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22717$as_echo "yes" >&6; }
22718else
22719# FIXME - insert some real tests, host_os isn't really good enough
22720  case $host_os in
22721  darwin*)
22722    if test -n "$STRIP"; then
22723      striplib="$STRIP -x"
22724      old_striplib="$STRIP -S"
22725      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22726$as_echo "yes" >&6; }
22727    else
22728      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22729$as_echo "no" >&6; }
22730    fi
22731    ;;
22732  *)
22733    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22734$as_echo "no" >&6; }
22735    ;;
22736  esac
22737fi
22738
22739
22740
22741
22742
22743
22744
22745
22746
22747
22748
22749
22750  # Report what library types will actually be built
22751  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5
22752$as_echo_n "checking if libtool supports shared libraries... " >&6; }
22753  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5
22754$as_echo "$can_build_shared" >&6; }
22755
22756  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5
22757$as_echo_n "checking whether to build shared libraries... " >&6; }
22758  test no = "$can_build_shared" && enable_shared=no
22759
22760  # On AIX, shared libraries and static libraries use the same namespace, and
22761  # are all built from PIC.
22762  case $host_os in
22763  aix3*)
22764    test yes = "$enable_shared" && enable_static=no
22765    if test -n "$RANLIB"; then
22766      archive_cmds="$archive_cmds~\$RANLIB \$lib"
22767      postinstall_cmds='$RANLIB $lib'
22768    fi
22769    ;;
22770
22771  aix[4-9]*)
22772    if test ia64 != "$host_cpu"; then
22773      case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in
22774      yes,aix,yes) ;;			# shared object as lib.so file only
22775      yes,svr4,*) ;;			# shared object as lib.so archive member only
22776      yes,*) enable_static=no ;;	# shared object in lib.a archive as well
22777      esac
22778    fi
22779    ;;
22780  esac
22781  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5
22782$as_echo "$enable_shared" >&6; }
22783
22784  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5
22785$as_echo_n "checking whether to build static libraries... " >&6; }
22786  # Make sure either enable_shared or enable_static is yes.
22787  test yes = "$enable_shared" || enable_static=yes
22788  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5
22789$as_echo "$enable_static" >&6; }
22790
22791
22792
22793
22794fi
22795ac_ext=c
22796ac_cpp='$CPP $CPPFLAGS'
22797ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
22798ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
22799ac_compiler_gnu=$ac_cv_c_compiler_gnu
22800
22801CC=$lt_save_CC
22802
22803
22804
22805
22806
22807
22808
22809
22810
22811
22812
22813
22814
22815
22816
22817        ac_config_commands="$ac_config_commands libtool"
22818
22819
22820
22821
22822# Only expand once:
22823
22824
22825
22826
22827
22828
22829{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if sntp will be built" >&5
22830$as_echo_n "checking if sntp will be built... " >&6; }
22831
22832# Check whether --with-sntp was given.
22833if test "${with_sntp+set}" = set; then :
22834  withval=$with_sntp;
22835else
22836  with_sntp="${withsntp=yes}"
22837
22838fi
22839
22840case "$with_sntp" in
22841 no)
22842    SNTP=
22843    ;;
22844 *)
22845    SNTP=sntp
22846    ;;
22847esac
22848
22849 if test -n "$SNTP"; then
22850  BUILD_SNTP_TRUE=
22851  BUILD_SNTP_FALSE='#'
22852else
22853  BUILD_SNTP_TRUE='#'
22854  BUILD_SNTP_FALSE=
22855fi
22856
22857{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_sntp" >&5
22858$as_echo "$with_sntp" >&6; }
22859
22860
22861
22862case "$SNTP" in
22863 '')
22864    SNTP_DB=
22865    SNTP_DL=
22866    SNTP_DS=
22867    ;;
22868esac
22869
22870###
22871
22872# NTP has (so far) been relying on leading-edge autogen.
22873# Therefore, by default:
22874# - use the version we ship with
22875# - do not install it
22876# - build a static copy (AC_DISABLE_SHARED - done earlier)
22877case "${enable_local_libopts+set}" in
22878 set) ;;
22879 *) enable_local_libopts=yes ;;
22880esac
22881case "${enable_libopts_install+set}" in
22882 set) ;;
22883 *) enable_libopts_install=no ;;
22884esac
22885enable_nls=no
22886
22887
22888  ac_header_dirent=no
22889for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
22890  as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
22891{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5
22892$as_echo_n "checking for $ac_hdr that defines DIR... " >&6; }
22893if eval \${$as_ac_Header+:} false; then :
22894  $as_echo_n "(cached) " >&6
22895else
22896  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22897/* end confdefs.h.  */
22898#include <sys/types.h>
22899#include <$ac_hdr>
22900
22901int
22902main ()
22903{
22904if ((DIR *) 0)
22905return 0;
22906  ;
22907  return 0;
22908}
22909_ACEOF
22910if ac_fn_c_try_compile "$LINENO"; then :
22911  eval "$as_ac_Header=yes"
22912else
22913  eval "$as_ac_Header=no"
22914fi
22915rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22916fi
22917eval ac_res=\$$as_ac_Header
22918	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
22919$as_echo "$ac_res" >&6; }
22920if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
22921  cat >>confdefs.h <<_ACEOF
22922#define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
22923_ACEOF
22924
22925ac_header_dirent=$ac_hdr; break
22926fi
22927
22928done
22929# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
22930if test $ac_header_dirent = dirent.h; then
22931  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5
22932$as_echo_n "checking for library containing opendir... " >&6; }
22933if ${ac_cv_search_opendir+:} false; then :
22934  $as_echo_n "(cached) " >&6
22935else
22936  ac_func_search_save_LIBS=$LIBS
22937cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22938/* end confdefs.h.  */
22939
22940/* Override any GCC internal prototype to avoid an error.
22941   Use char because int might match the return type of a GCC
22942   builtin and then its argument prototype would still apply.  */
22943#ifdef __cplusplus
22944extern "C"
22945#endif
22946char opendir ();
22947int
22948main ()
22949{
22950return opendir ();
22951  ;
22952  return 0;
22953}
22954_ACEOF
22955for ac_lib in '' dir; do
22956  if test -z "$ac_lib"; then
22957    ac_res="none required"
22958  else
22959    ac_res=-l$ac_lib
22960    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
22961  fi
22962  if ac_fn_c_try_link "$LINENO"; then :
22963  ac_cv_search_opendir=$ac_res
22964fi
22965rm -f core conftest.err conftest.$ac_objext \
22966    conftest$ac_exeext
22967  if ${ac_cv_search_opendir+:} false; then :
22968  break
22969fi
22970done
22971if ${ac_cv_search_opendir+:} false; then :
22972
22973else
22974  ac_cv_search_opendir=no
22975fi
22976rm conftest.$ac_ext
22977LIBS=$ac_func_search_save_LIBS
22978fi
22979{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5
22980$as_echo "$ac_cv_search_opendir" >&6; }
22981ac_res=$ac_cv_search_opendir
22982if test "$ac_res" != no; then :
22983  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
22984
22985fi
22986
22987else
22988  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5
22989$as_echo_n "checking for library containing opendir... " >&6; }
22990if ${ac_cv_search_opendir+:} false; then :
22991  $as_echo_n "(cached) " >&6
22992else
22993  ac_func_search_save_LIBS=$LIBS
22994cat 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
23001extern "C"
23002#endif
23003char opendir ();
23004int
23005main ()
23006{
23007return opendir ();
23008  ;
23009  return 0;
23010}
23011_ACEOF
23012for ac_lib in '' x; 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
23021fi
23022rm -f core conftest.err conftest.$ac_objext \
23023    conftest$ac_exeext
23024  if ${ac_cv_search_opendir+:} false; then :
23025  break
23026fi
23027done
23028if ${ac_cv_search_opendir+:} false; then :
23029
23030else
23031  ac_cv_search_opendir=no
23032fi
23033rm conftest.$ac_ext
23034LIBS=$ac_func_search_save_LIBS
23035fi
23036{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5
23037$as_echo "$ac_cv_search_opendir" >&6; }
23038ac_res=$ac_cv_search_opendir
23039if test "$ac_res" != no; then :
23040  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
23041
23042fi
23043
23044fi
23045
23046
23047  # =================
23048  # AC_CHECK_HEADERS
23049  # =================
23050  for ac_header in  \
23051      sys/mman.h    sys/param.h   sys/poll.h    sys/procset.h \
23052      sys/select.h  sys/socket.h  sys/stropts.h sys/time.h \
23053      sys/un.h      sys/wait.h    dlfcn.h       errno.h \
23054      fcntl.h       libgen.h      libintl.h     memory.h \
23055      netinet/in.h  setjmp.h      stdbool.h     sysexits.h \
23056      unistd.h      utime.h
23057do :
23058  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
23059ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
23060if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
23061  cat >>confdefs.h <<_ACEOF
23062#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
23063_ACEOF
23064
23065fi
23066
23067done
23068
23069
23070  for ac_header in stdarg.h     varargs.h
23071do :
23072  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
23073ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
23074if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
23075  cat >>confdefs.h <<_ACEOF
23076#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
23077_ACEOF
23078 lo_have_arg_hdr=true;break
23079else
23080  lo_have_arg_hdr=false
23081fi
23082
23083done
23084
23085
23086  for ac_header in string.h     strings.h
23087do :
23088  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
23089ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
23090if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
23091  cat >>confdefs.h <<_ACEOF
23092#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
23093_ACEOF
23094 lo_have_str_hdr=true;break
23095else
23096  lo_have_str_hdr=false
23097fi
23098
23099done
23100
23101
23102  for ac_header in limits.h     sys/limits.h  values.h
23103do :
23104  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
23105ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
23106if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
23107  cat >>confdefs.h <<_ACEOF
23108#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
23109_ACEOF
23110 lo_have_lim_hdr=true;break
23111else
23112  lo_have_lim_hdr=false
23113fi
23114
23115done
23116
23117
23118  for ac_header in inttypes.h   stdint.h
23119do :
23120  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
23121ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
23122if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
23123  cat >>confdefs.h <<_ACEOF
23124#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
23125_ACEOF
23126 lo_have_typ_hdr=true;break
23127else
23128  lo_have_typ_hdr=false
23129fi
23130
23131done
23132
23133
23134  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working stdnoreturn.h" >&5
23135$as_echo_n "checking for working stdnoreturn.h... " >&6; }
23136if ${gl_cv_header_working_stdnoreturn_h+:} false; then :
23137  $as_echo_n "(cached) " >&6
23138else
23139  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23140/* end confdefs.h.  */
23141#include <stdlib.h>
23142            #include <stdnoreturn.h>
23143            /* Do not check for 'noreturn' after the return type.
23144               C11 allows it, but it's rarely done that way
23145               and circa-2012 bleeding-edge GCC rejects it when given
23146               -Werror=old-style-declaration.  */
23147            noreturn void foo1 (void) { exit (0); }
23148            _Noreturn void foo2 (void) { exit (0); }
23149            int testit (int argc, char **argv) {
23150              if (argc & 1)
23151                return 0;
23152              (argv[0][0] ? foo1 : foo2) ();
23153            }
23154
23155int
23156main ()
23157{
23158
23159  ;
23160  return 0;
23161}
23162_ACEOF
23163if ac_fn_c_try_compile "$LINENO"; then :
23164  gl_cv_header_working_stdnoreturn_h=yes
23165else
23166  gl_cv_header_working_stdnoreturn_h=no
23167fi
23168rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23169fi
23170{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdnoreturn_h" >&5
23171$as_echo "$gl_cv_header_working_stdnoreturn_h" >&6; }
23172
23173  if test $gl_cv_header_working_stdnoreturn_h = yes; then
23174    STDNORETURN_H=''
23175  else
23176    STDNORETURN_H='stdnoreturn.h'
23177  fi
23178
23179
23180   if test -n "$STDNORETURN_H"; then
23181  GL_GENERATE_STDNORETURN_H_TRUE=
23182  GL_GENERATE_STDNORETURN_H_FALSE='#'
23183else
23184  GL_GENERATE_STDNORETURN_H_TRUE='#'
23185  GL_GENERATE_STDNORETURN_H_FALSE=
23186fi
23187
23188
23189
23190  # ----------------------------------------------------------------------
23191  # check for various programs used during the build.
23192  # On OS/X, "wchar.h" needs "runetype.h" to work properly.
23193  # ----------------------------------------------------------------------
23194  for ac_header in runetype.h wchar.h
23195do :
23196  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
23197ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "
23198  $ac_includes_default
23199  #if HAVE_RUNETYPE_H
23200  # include <runetype.h>
23201  #endif
23202
23203"
23204if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
23205  cat >>confdefs.h <<_ACEOF
23206#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
23207_ACEOF
23208
23209fi
23210
23211done
23212
23213
23214  # Check whether --enable-nls was given.
23215if test "${enable_nls+set}" = set; then :
23216  enableval=$enable_nls;
23217fi
23218
23219  if test "x$enable_nls" != "xno" && \
23220  test "X${ac_cv_header_libintl_h}" = Xyes; then :
23221
23222
23223$as_echo "#define ENABLE_NLS 1" >>confdefs.h
23224
23225fi
23226
23227  # --------------------------------------------
23228  # Verify certain entries from AC_CHECK_HEADERS
23229  # --------------------------------------------
23230  ${lo_have_arg_hdr} || \
23231    as_fn_error $? "you must have stdarg.h or varargs.h on your system" "$LINENO" 5
23232
23233  ${lo_have_str_hdr} || \
23234    as_fn_error $? "you must have string.h or strings.h on your system" "$LINENO" 5
23235
23236  ${lo_have_lim_hdr} || \
23237    as_fn_error $? "you must have one of limits.h, sys/limits.h or values.h" "$LINENO" 5
23238
23239  ${lo_have_typ_hdr} || \
23240    as_fn_error $? "you must have inttypes.h or stdint.h on your system" "$LINENO" 5
23241
23242  for f in sys_types sys_param sys_stat string errno stdlib memory setjmp
23243  do eval as_ac_var=\${ac_cv_header_${f}_h}
23244     test "X${as_ac_var}" = Xyes || {
23245       as_fn_error $? "you must have ${f}.h on your system" "$LINENO" 5
23246     }
23247  done
23248  test "X${ac_cv_header_inttypes_h-no}" = Xyes || \
23249    echo '#include <stdint.h>' > inttypes.h
23250
23251  # ----------------------------------------------------------------------
23252  # Checks for typedefs
23253  # ----------------------------------------------------------------------
23254  ac_fn_c_check_type "$LINENO" "wchar_t" "ac_cv_type_wchar_t" "$ac_includes_default"
23255if test "x$ac_cv_type_wchar_t" = xyes; then :
23256
23257cat >>confdefs.h <<_ACEOF
23258#define HAVE_WCHAR_T 1
23259_ACEOF
23260
23261
23262fi
23263
23264  ac_fn_c_check_type "$LINENO" "wint_t" "ac_cv_type_wint_t" "
23265    $ac_includes_default
23266    #if HAVE_RUNETYPE_H
23267    # include <runetype.h>
23268    #endif
23269    #if HAVE_WCHAR_H
23270    # include <wchar.h>
23271    #endif
23272
23273"
23274if test "x$ac_cv_type_wint_t" = xyes; then :
23275
23276cat >>confdefs.h <<_ACEOF
23277#define HAVE_WINT_T 1
23278_ACEOF
23279
23280
23281fi
23282
23283  ac_fn_c_check_type "$LINENO" "int8_t" "ac_cv_type_int8_t" "$ac_includes_default"
23284if test "x$ac_cv_type_int8_t" = xyes; then :
23285
23286cat >>confdefs.h <<_ACEOF
23287#define HAVE_INT8_T 1
23288_ACEOF
23289
23290
23291fi
23292ac_fn_c_check_type "$LINENO" "uint8_t" "ac_cv_type_uint8_t" "$ac_includes_default"
23293if test "x$ac_cv_type_uint8_t" = xyes; then :
23294
23295cat >>confdefs.h <<_ACEOF
23296#define HAVE_UINT8_T 1
23297_ACEOF
23298
23299
23300fi
23301ac_fn_c_check_type "$LINENO" "int16_t" "ac_cv_type_int16_t" "$ac_includes_default"
23302if test "x$ac_cv_type_int16_t" = xyes; then :
23303
23304cat >>confdefs.h <<_ACEOF
23305#define HAVE_INT16_T 1
23306_ACEOF
23307
23308
23309fi
23310ac_fn_c_check_type "$LINENO" "uint16_t" "ac_cv_type_uint16_t" "$ac_includes_default"
23311if test "x$ac_cv_type_uint16_t" = xyes; then :
23312
23313cat >>confdefs.h <<_ACEOF
23314#define HAVE_UINT16_T 1
23315_ACEOF
23316
23317
23318fi
23319ac_fn_c_check_type "$LINENO" "int32_t" "ac_cv_type_int32_t" "$ac_includes_default"
23320if test "x$ac_cv_type_int32_t" = xyes; then :
23321
23322cat >>confdefs.h <<_ACEOF
23323#define HAVE_INT32_T 1
23324_ACEOF
23325
23326
23327fi
23328ac_fn_c_check_type "$LINENO" "uint32_t" "ac_cv_type_uint32_t" "$ac_includes_default"
23329if test "x$ac_cv_type_uint32_t" = xyes; then :
23330
23331cat >>confdefs.h <<_ACEOF
23332#define HAVE_UINT32_T 1
23333_ACEOF
23334
23335
23336fi
23337ac_fn_c_check_type "$LINENO" "intptr_t" "ac_cv_type_intptr_t" "$ac_includes_default"
23338if test "x$ac_cv_type_intptr_t" = xyes; then :
23339
23340cat >>confdefs.h <<_ACEOF
23341#define HAVE_INTPTR_T 1
23342_ACEOF
23343
23344
23345fi
23346ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default"
23347if test "x$ac_cv_type_uintptr_t" = xyes; then :
23348
23349cat >>confdefs.h <<_ACEOF
23350#define HAVE_UINTPTR_T 1
23351_ACEOF
23352
23353
23354fi
23355ac_fn_c_check_type "$LINENO" "uint_t" "ac_cv_type_uint_t" "$ac_includes_default"
23356if test "x$ac_cv_type_uint_t" = xyes; then :
23357
23358cat >>confdefs.h <<_ACEOF
23359#define HAVE_UINT_T 1
23360_ACEOF
23361
23362
23363fi
23364ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
23365if test "x$ac_cv_type_pid_t" = xyes; then :
23366
23367cat >>confdefs.h <<_ACEOF
23368#define HAVE_PID_T 1
23369_ACEOF
23370
23371
23372fi
23373ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
23374if test "x$ac_cv_type_size_t" = xyes; then :
23375
23376cat >>confdefs.h <<_ACEOF
23377#define HAVE_SIZE_T 1
23378_ACEOF
23379
23380
23381fi
23382ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default"
23383if test "x$ac_cv_type_ptrdiff_t" = xyes; then :
23384
23385cat >>confdefs.h <<_ACEOF
23386#define HAVE_PTRDIFF_T 1
23387_ACEOF
23388
23389
23390fi
23391
23392  # The cast to long int works around a bug in the HP C Compiler
23393# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
23394# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
23395# This bug is HP SR number 8606223364.
23396{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of char *" >&5
23397$as_echo_n "checking size of char *... " >&6; }
23398if ${ac_cv_sizeof_char_p+:} false; then :
23399  $as_echo_n "(cached) " >&6
23400else
23401  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (char *))" "ac_cv_sizeof_char_p"        "$ac_includes_default"; then :
23402
23403else
23404  if test "$ac_cv_type_char_p" = yes; then
23405     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
23406$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
23407as_fn_error 77 "cannot compute sizeof (char *)
23408See \`config.log' for more details" "$LINENO" 5; }
23409   else
23410     ac_cv_sizeof_char_p=0
23411   fi
23412fi
23413
23414fi
23415{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_char_p" >&5
23416$as_echo "$ac_cv_sizeof_char_p" >&6; }
23417
23418
23419
23420cat >>confdefs.h <<_ACEOF
23421#define SIZEOF_CHAR_P $ac_cv_sizeof_char_p
23422_ACEOF
23423
23424
23425  # The cast to long int works around a bug in the HP C Compiler
23426# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
23427# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
23428# This bug is HP SR number 8606223364.
23429{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5
23430$as_echo_n "checking size of int... " >&6; }
23431if ${ac_cv_sizeof_int+:} false; then :
23432  $as_echo_n "(cached) " >&6
23433else
23434  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int"        "$ac_includes_default"; then :
23435
23436else
23437  if test "$ac_cv_type_int" = yes; then
23438     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
23439$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
23440as_fn_error 77 "cannot compute sizeof (int)
23441See \`config.log' for more details" "$LINENO" 5; }
23442   else
23443     ac_cv_sizeof_int=0
23444   fi
23445fi
23446
23447fi
23448{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5
23449$as_echo "$ac_cv_sizeof_int" >&6; }
23450
23451
23452
23453cat >>confdefs.h <<_ACEOF
23454#define SIZEOF_INT $ac_cv_sizeof_int
23455_ACEOF
23456
23457
23458  # The cast to long int works around a bug in the HP C Compiler
23459# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
23460# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
23461# This bug is HP SR number 8606223364.
23462{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
23463$as_echo_n "checking size of long... " >&6; }
23464if ${ac_cv_sizeof_long+:} false; then :
23465  $as_echo_n "(cached) " >&6
23466else
23467  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long"        "$ac_includes_default"; then :
23468
23469else
23470  if test "$ac_cv_type_long" = yes; then
23471     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
23472$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
23473as_fn_error 77 "cannot compute sizeof (long)
23474See \`config.log' for more details" "$LINENO" 5; }
23475   else
23476     ac_cv_sizeof_long=0
23477   fi
23478fi
23479
23480fi
23481{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
23482$as_echo "$ac_cv_sizeof_long" >&6; }
23483
23484
23485
23486cat >>confdefs.h <<_ACEOF
23487#define SIZEOF_LONG $ac_cv_sizeof_long
23488_ACEOF
23489
23490
23491  # The cast to long int works around a bug in the HP C Compiler
23492# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
23493# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
23494# This bug is HP SR number 8606223364.
23495{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5
23496$as_echo_n "checking size of short... " >&6; }
23497if ${ac_cv_sizeof_short+:} false; then :
23498  $as_echo_n "(cached) " >&6
23499else
23500  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (short))" "ac_cv_sizeof_short"        "$ac_includes_default"; then :
23501
23502else
23503  if test "$ac_cv_type_short" = yes; then
23504     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
23505$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
23506as_fn_error 77 "cannot compute sizeof (short)
23507See \`config.log' for more details" "$LINENO" 5; }
23508   else
23509     ac_cv_sizeof_short=0
23510   fi
23511fi
23512
23513fi
23514{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5
23515$as_echo "$ac_cv_sizeof_short" >&6; }
23516
23517
23518
23519cat >>confdefs.h <<_ACEOF
23520#define SIZEOF_SHORT $ac_cv_sizeof_short
23521_ACEOF
23522
23523
23524
23525  # ------------
23526  # AC_CHECK_LIB
23527  # ------------
23528  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pathfind in -lgen" >&5
23529$as_echo_n "checking for pathfind in -lgen... " >&6; }
23530if ${ac_cv_lib_gen_pathfind+:} false; then :
23531  $as_echo_n "(cached) " >&6
23532else
23533  ac_check_lib_save_LIBS=$LIBS
23534LIBS="-lgen  $LIBS"
23535cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23536/* end confdefs.h.  */
23537
23538/* Override any GCC internal prototype to avoid an error.
23539   Use char because int might match the return type of a GCC
23540   builtin and then its argument prototype would still apply.  */
23541#ifdef __cplusplus
23542extern "C"
23543#endif
23544char pathfind ();
23545int
23546main ()
23547{
23548return pathfind ();
23549  ;
23550  return 0;
23551}
23552_ACEOF
23553if ac_fn_c_try_link "$LINENO"; then :
23554  ac_cv_lib_gen_pathfind=yes
23555else
23556  ac_cv_lib_gen_pathfind=no
23557fi
23558rm -f core conftest.err conftest.$ac_objext \
23559    conftest$ac_exeext conftest.$ac_ext
23560LIBS=$ac_check_lib_save_LIBS
23561fi
23562{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gen_pathfind" >&5
23563$as_echo "$ac_cv_lib_gen_pathfind" >&6; }
23564if test "x$ac_cv_lib_gen_pathfind" = xyes; then :
23565  cat >>confdefs.h <<_ACEOF
23566#define HAVE_LIBGEN 1
23567_ACEOF
23568
23569  LIBS="-lgen $LIBS"
23570
23571fi
23572
23573  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gettext in -lintl" >&5
23574$as_echo_n "checking for gettext in -lintl... " >&6; }
23575if ${ac_cv_lib_intl_gettext+:} false; then :
23576  $as_echo_n "(cached) " >&6
23577else
23578  ac_check_lib_save_LIBS=$LIBS
23579LIBS="-lintl  $LIBS"
23580cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23581/* end confdefs.h.  */
23582
23583/* Override any GCC internal prototype to avoid an error.
23584   Use char because int might match the return type of a GCC
23585   builtin and then its argument prototype would still apply.  */
23586#ifdef __cplusplus
23587extern "C"
23588#endif
23589char gettext ();
23590int
23591main ()
23592{
23593return gettext ();
23594  ;
23595  return 0;
23596}
23597_ACEOF
23598if ac_fn_c_try_link "$LINENO"; then :
23599  ac_cv_lib_intl_gettext=yes
23600else
23601  ac_cv_lib_intl_gettext=no
23602fi
23603rm -f core conftest.err conftest.$ac_objext \
23604    conftest$ac_exeext conftest.$ac_ext
23605LIBS=$ac_check_lib_save_LIBS
23606fi
23607{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_gettext" >&5
23608$as_echo "$ac_cv_lib_intl_gettext" >&6; }
23609if test "x$ac_cv_lib_intl_gettext" = xyes; then :
23610  cat >>confdefs.h <<_ACEOF
23611#define HAVE_LIBINTL 1
23612_ACEOF
23613
23614  LIBS="-lintl $LIBS"
23615
23616fi
23617
23618  for ac_func in vprintf
23619do :
23620  ac_fn_c_check_func "$LINENO" "vprintf" "ac_cv_func_vprintf"
23621if test "x$ac_cv_func_vprintf" = xyes; then :
23622  cat >>confdefs.h <<_ACEOF
23623#define HAVE_VPRINTF 1
23624_ACEOF
23625
23626ac_fn_c_check_func "$LINENO" "_doprnt" "ac_cv_func__doprnt"
23627if test "x$ac_cv_func__doprnt" = xyes; then :
23628
23629$as_echo "#define HAVE_DOPRNT 1" >>confdefs.h
23630
23631fi
23632
23633fi
23634done
23635
23636
23637  for ac_header in vfork.h
23638do :
23639  ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
23640if test "x$ac_cv_header_vfork_h" = xyes; then :
23641  cat >>confdefs.h <<_ACEOF
23642#define HAVE_VFORK_H 1
23643_ACEOF
23644
23645fi
23646
23647done
23648
23649for ac_func in fork vfork
23650do :
23651  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
23652ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
23653if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
23654  cat >>confdefs.h <<_ACEOF
23655#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
23656_ACEOF
23657
23658fi
23659done
23660
23661if test "x$ac_cv_func_fork" = xyes; then
23662  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
23663$as_echo_n "checking for working fork... " >&6; }
23664if ${ac_cv_func_fork_works+:} false; then :
23665  $as_echo_n "(cached) " >&6
23666else
23667  if test "$cross_compiling" = yes; then :
23668  ac_cv_func_fork_works=cross
23669else
23670  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23671/* end confdefs.h.  */
23672$ac_includes_default
23673int
23674main ()
23675{
23676
23677	  /* By Ruediger Kuhlmann. */
23678	  return fork () < 0;
23679
23680  ;
23681  return 0;
23682}
23683_ACEOF
23684if ac_fn_c_try_run "$LINENO"; then :
23685  ac_cv_func_fork_works=yes
23686else
23687  ac_cv_func_fork_works=no
23688fi
23689rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23690  conftest.$ac_objext conftest.beam conftest.$ac_ext
23691fi
23692
23693fi
23694{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
23695$as_echo "$ac_cv_func_fork_works" >&6; }
23696
23697else
23698  ac_cv_func_fork_works=$ac_cv_func_fork
23699fi
23700if test "x$ac_cv_func_fork_works" = xcross; then
23701  case $host in
23702    *-*-amigaos* | *-*-msdosdjgpp*)
23703      # Override, as these systems have only a dummy fork() stub
23704      ac_cv_func_fork_works=no
23705      ;;
23706    *)
23707      ac_cv_func_fork_works=yes
23708      ;;
23709  esac
23710  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
23711$as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
23712fi
23713ac_cv_func_vfork_works=$ac_cv_func_vfork
23714if test "x$ac_cv_func_vfork" = xyes; then
23715  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
23716$as_echo_n "checking for working vfork... " >&6; }
23717if ${ac_cv_func_vfork_works+:} false; then :
23718  $as_echo_n "(cached) " >&6
23719else
23720  if test "$cross_compiling" = yes; then :
23721  ac_cv_func_vfork_works=cross
23722else
23723  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23724/* end confdefs.h.  */
23725/* Thanks to Paul Eggert for this test.  */
23726$ac_includes_default
23727#include <sys/wait.h>
23728#ifdef HAVE_VFORK_H
23729# include <vfork.h>
23730#endif
23731/* On some sparc systems, changes by the child to local and incoming
23732   argument registers are propagated back to the parent.  The compiler
23733   is told about this with #include <vfork.h>, but some compilers
23734   (e.g. gcc -O) don't grok <vfork.h>.  Test for this by using a
23735   static variable whose address is put into a register that is
23736   clobbered by the vfork.  */
23737static void
23738#ifdef __cplusplus
23739sparc_address_test (int arg)
23740# else
23741sparc_address_test (arg) int arg;
23742#endif
23743{
23744  static pid_t child;
23745  if (!child) {
23746    child = vfork ();
23747    if (child < 0) {
23748      perror ("vfork");
23749      _exit(2);
23750    }
23751    if (!child) {
23752      arg = getpid();
23753      write(-1, "", 0);
23754      _exit (arg);
23755    }
23756  }
23757}
23758
23759int
23760main ()
23761{
23762  pid_t parent = getpid ();
23763  pid_t child;
23764
23765  sparc_address_test (0);
23766
23767  child = vfork ();
23768
23769  if (child == 0) {
23770    /* Here is another test for sparc vfork register problems.  This
23771       test uses lots of local variables, at least as many local
23772       variables as main has allocated so far including compiler
23773       temporaries.  4 locals are enough for gcc 1.40.3 on a Solaris
23774       4.1.3 sparc, but we use 8 to be safe.  A buggy compiler should
23775       reuse the register of parent for one of the local variables,
23776       since it will think that parent can't possibly be used any more
23777       in this routine.  Assigning to the local variable will thus
23778       munge parent in the parent process.  */
23779    pid_t
23780      p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
23781      p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
23782    /* Convince the compiler that p..p7 are live; otherwise, it might
23783       use the same hardware register for all 8 local variables.  */
23784    if (p != p1 || p != p2 || p != p3 || p != p4
23785	|| p != p5 || p != p6 || p != p7)
23786      _exit(1);
23787
23788    /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
23789       from child file descriptors.  If the child closes a descriptor
23790       before it execs or exits, this munges the parent's descriptor
23791       as well.  Test for this by closing stdout in the child.  */
23792    _exit(close(fileno(stdout)) != 0);
23793  } else {
23794    int status;
23795    struct stat st;
23796
23797    while (wait(&status) != child)
23798      ;
23799    return (
23800	 /* Was there some problem with vforking?  */
23801	 child < 0
23802
23803	 /* Did the child fail?  (This shouldn't happen.)  */
23804	 || status
23805
23806	 /* Did the vfork/compiler bug occur?  */
23807	 || parent != getpid()
23808
23809	 /* Did the file descriptor bug occur?  */
23810	 || fstat(fileno(stdout), &st) != 0
23811	 );
23812  }
23813}
23814_ACEOF
23815if ac_fn_c_try_run "$LINENO"; then :
23816  ac_cv_func_vfork_works=yes
23817else
23818  ac_cv_func_vfork_works=no
23819fi
23820rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23821  conftest.$ac_objext conftest.beam conftest.$ac_ext
23822fi
23823
23824fi
23825{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
23826$as_echo "$ac_cv_func_vfork_works" >&6; }
23827
23828fi;
23829if test "x$ac_cv_func_fork_works" = xcross; then
23830  ac_cv_func_vfork_works=$ac_cv_func_vfork
23831  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
23832$as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
23833fi
23834
23835if test "x$ac_cv_func_vfork_works" = xyes; then
23836
23837$as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
23838
23839else
23840
23841$as_echo "#define vfork fork" >>confdefs.h
23842
23843fi
23844if test "x$ac_cv_func_fork_works" = xyes; then
23845
23846$as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
23847
23848fi
23849
23850  for ac_func in mmap canonicalize_file_name snprintf strdup strchr \
23851                 strrchr strsignal fchmod fstat chmod
23852do :
23853  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
23854ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
23855if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
23856  cat >>confdefs.h <<_ACEOF
23857#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
23858_ACEOF
23859
23860fi
23861done
23862
23863  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
23864$as_echo_n "checking for a sed that does not truncate output... " >&6; }
23865if ${ac_cv_path_SED+:} false; then :
23866  $as_echo_n "(cached) " >&6
23867else
23868            ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
23869     for ac_i in 1 2 3 4 5 6 7; do
23870       ac_script="$ac_script$as_nl$ac_script"
23871     done
23872     echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
23873     { ac_script=; unset ac_script;}
23874     if test -z "$SED"; then
23875  ac_path_SED_found=false
23876  # Loop through the user's path and test for each of PROGNAME-LIST
23877  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
23878for as_dir in $PATH
23879do
23880  IFS=$as_save_IFS
23881  test -z "$as_dir" && as_dir=.
23882    for ac_prog in sed gsed; do
23883    for ac_exec_ext in '' $ac_executable_extensions; do
23884      ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
23885      as_fn_executable_p "$ac_path_SED" || continue
23886# Check for GNU ac_path_SED and select it if it is found.
23887  # Check for GNU $ac_path_SED
23888case `"$ac_path_SED" --version 2>&1` in
23889*GNU*)
23890  ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
23891*)
23892  ac_count=0
23893  $as_echo_n 0123456789 >"conftest.in"
23894  while :
23895  do
23896    cat "conftest.in" "conftest.in" >"conftest.tmp"
23897    mv "conftest.tmp" "conftest.in"
23898    cp "conftest.in" "conftest.nl"
23899    $as_echo '' >> "conftest.nl"
23900    "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
23901    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
23902    as_fn_arith $ac_count + 1 && ac_count=$as_val
23903    if test $ac_count -gt ${ac_path_SED_max-0}; then
23904      # Best one so far, save it but keep looking for a better one
23905      ac_cv_path_SED="$ac_path_SED"
23906      ac_path_SED_max=$ac_count
23907    fi
23908    # 10*(2^10) chars as input seems more than enough
23909    test $ac_count -gt 10 && break
23910  done
23911  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
23912esac
23913
23914      $ac_path_SED_found && break 3
23915    done
23916  done
23917  done
23918IFS=$as_save_IFS
23919  if test -z "$ac_cv_path_SED"; then
23920    as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
23921  fi
23922else
23923  ac_cv_path_SED=$SED
23924fi
23925
23926fi
23927{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
23928$as_echo "$ac_cv_path_SED" >&6; }
23929 SED="$ac_cv_path_SED"
23930  rm -f conftest.sed
23931
23932  while :
23933  do
23934      POSIX_SHELL=`which bash`
23935      test -x "$POSIX_SHELL" && break
23936      POSIX_SHELL=`which dash`
23937      test -x "$POSIX_SHELL" && break
23938      POSIX_SHELL=/usr/xpg4/bin/sh
23939      test -x "$POSIX_SHELL" && break
23940      POSIX_SHELL=`/bin/sh -c '
23941          exec 2>/dev/null
23942          if ! true ; then exit 1 ; fi
23943          echo /bin/sh'`
23944      test -x "$POSIX_SHELL" && break
23945      as_fn_error $? "cannot locate a working POSIX shell" "$LINENO" 5
23946  done
23947
23948cat >>confdefs.h <<_ACEOF
23949#define POSIX_SHELL "${POSIX_SHELL}"
23950_ACEOF
23951
23952
23953
23954
23955
23956  LIBOPTS_BUILD_BLOCKED=''
23957
23958
23959  NEED_LIBOPTS_DIR=''
23960
23961  # Check whether --enable-local-libopts was given.
23962if test "${enable_local_libopts+set}" = set; then :
23963  enableval=$enable_local_libopts;
23964    if test x$enableval = xyes ; then
23965       { $as_echo "$as_me:${as_lineno-$LINENO}: Using supplied libopts tearoff" >&5
23966$as_echo "$as_me: Using supplied libopts tearoff" >&6;}
23967       LIBOPTS_CFLAGS='-I$(top_srcdir)/libopts'
23968       NEED_LIBOPTS_DIR=true
23969       LIBOPTS_LDADD='$(top_builddir)/libopts/libopts.la'
23970    fi
23971fi
23972
23973
23974  # Check whether --enable-libopts-install was given.
23975if test "${enable_libopts_install+set}" = set; then :
23976  enableval=$enable_libopts_install;
23977fi
23978
23979   if test "X${enable_libopts_install}" = Xyes; then
23980  INSTALL_LIBOPTS_TRUE=
23981  INSTALL_LIBOPTS_FALSE='#'
23982else
23983  INSTALL_LIBOPTS_TRUE='#'
23984  INSTALL_LIBOPTS_FALSE=
23985fi
23986
23987
23988  if test -z "${NEED_LIBOPTS_DIR}" ; then
23989     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether autoopts-config can be found" >&5
23990$as_echo_n "checking whether autoopts-config can be found... " >&6; }
23991
23992# Check whether --with-autoopts-config was given.
23993if test "${with_autoopts_config+set}" = set; then :
23994  withval=$with_autoopts_config; lo_cv_with_autoopts_config=${with_autoopts_config}
23995else
23996  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether autoopts-config is specified" >&5
23997$as_echo_n "checking whether autoopts-config is specified... " >&6; }
23998if ${lo_cv_with_autoopts_config+:} false; then :
23999  $as_echo_n "(cached) " >&6
24000else
24001  if autoopts-config --help 2>/dev/null 1>&2
24002        then lo_cv_with_autoopts_config=autoopts-config
24003        elif libopts-config --help 2>/dev/null 1>&2
24004        then lo_cv_with_autoopts_config=libopts-config
24005        else lo_cv_with_autoopts_config=no ; fi
24006fi
24007{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lo_cv_with_autoopts_config" >&5
24008$as_echo "$lo_cv_with_autoopts_config" >&6; }
24009
24010fi
24011 # end of AC_ARG_WITH
24012
24013     if ${lo_cv_test_autoopts+:} false; then :
24014  $as_echo_n "(cached) " >&6
24015else
24016
24017        if test -z "${lo_cv_with_autoopts_config}" \
24018                -o X"${lo_cv_with_autoopts_config}" = Xno
24019        then
24020           if autoopts-config --help 2>/dev/null 1>&2
24021           then lo_cv_with_autoopts_config=autoopts-config
24022           elif libopts-config --help 2>/dev/null 1>&2
24023           then lo_cv_with_autoopts_config=libopts-config
24024           else lo_cv_with_autoopts_config=false ; fi
24025        fi
24026        lo_cv_test_autoopts=`
24027            ${lo_cv_with_autoopts_config} --libs` 2> /dev/null
24028        if test $? -ne 0 -o -z "${lo_cv_test_autoopts}"
24029        then lo_cv_test_autoopts=no ; fi
24030
24031fi
24032 # end of CACHE_VAL
24033     { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lo_cv_test_autoopts}" >&5
24034$as_echo "${lo_cv_test_autoopts}" >&6; }
24035
24036     if test "X${lo_cv_test_autoopts}" != Xno
24037     then
24038        LIBOPTS_LDADD="${lo_cv_test_autoopts}"
24039        LIBOPTS_CFLAGS="`${lo_cv_with_autoopts_config} --cflags`"
24040     else
24041        LIBOPTS_LDADD='$(top_builddir)/libopts/libopts.la'
24042        LIBOPTS_CFLAGS='-I$(top_srcdir)/libopts'
24043        NEED_LIBOPTS_DIR=true
24044     fi
24045  fi # end of if test -z "${NEED_LIBOPTS_DIR}"
24046  if test -n "${LIBOPTS_BUILD_BLOCKED}" ; then
24047    NEED_LIBOPTS_DIR=''
24048  fi
24049   if test -n "${NEED_LIBOPTS_DIR}"; then
24050  NEED_LIBOPTS_TRUE=
24051  NEED_LIBOPTS_FALSE='#'
24052else
24053  NEED_LIBOPTS_TRUE='#'
24054  NEED_LIBOPTS_FALSE=
24055fi
24056
24057
24058
24059  LIBOPTS_DIR=libopts
24060
24061
24062# end of AC_DEFUN of LIBOPTS_CHECK_COMMON
24063
24064
24065    if test -z "$NEED_LIBOPTS_TRUE"; then :
24066
24067
24068
24069  # Check to see if a reg expr header is specified.
24070
24071
24072# Check whether --with-regex-header was given.
24073if test "${with_regex_header+set}" = set; then :
24074  withval=$with_regex_header; libopts_cv_with_regex_header=${with_regex_header}
24075else
24076  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a reg expr header is specified" >&5
24077$as_echo_n "checking whether a reg expr header is specified... " >&6; }
24078if ${libopts_cv_with_regex_header+:} false; then :
24079  $as_echo_n "(cached) " >&6
24080else
24081  libopts_cv_with_regex_header=no
24082fi
24083{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_with_regex_header" >&5
24084$as_echo "$libopts_cv_with_regex_header" >&6; }
24085
24086fi
24087 # end of AC_ARG_WITH
24088  if test "X${libopts_cv_with_regex_header}" != Xno
24089  then
24090    cat >>confdefs.h <<_ACEOF
24091#define REGEX_HEADER <${libopts_cv_with_regex_header}>
24092_ACEOF
24093
24094  else
24095
24096$as_echo "#define REGEX_HEADER <regex.h>" >>confdefs.h
24097
24098  fi
24099
24100
24101
24102  # Check to see if a working libregex can be found.
24103
24104
24105# Check whether --with-libregex was given.
24106if test "${with_libregex+set}" = set; then :
24107  withval=$with_libregex; libopts_cv_with_libregex_root=${with_libregex}
24108else
24109  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether with-libregex was specified" >&5
24110$as_echo_n "checking whether with-libregex was specified... " >&6; }
24111if ${libopts_cv_with_libregex_root+:} false; then :
24112  $as_echo_n "(cached) " >&6
24113else
24114  libopts_cv_with_libregex_root=no
24115fi
24116{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_with_libregex_root" >&5
24117$as_echo "$libopts_cv_with_libregex_root" >&6; }
24118
24119fi
24120 # end of AC_ARG_WITH libregex
24121
24122  if test "${with_libregex+set}" = set && \
24123     test "X${withval}" = Xno
24124  then ## disabled by request
24125    libopts_cv_with_libregex_root=no
24126    libopts_cv_with_libregex_cflags=no
24127    libopts_cv_with_libregex_libs=no
24128  else
24129
24130
24131# Check whether --with-libregex-cflags was given.
24132if test "${with_libregex_cflags+set}" = set; then :
24133  withval=$with_libregex_cflags; libopts_cv_with_libregex_cflags=${with_libregex_cflags}
24134else
24135  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether with-libregex-cflags was specified" >&5
24136$as_echo_n "checking whether with-libregex-cflags was specified... " >&6; }
24137if ${libopts_cv_with_libregex_cflags+:} false; then :
24138  $as_echo_n "(cached) " >&6
24139else
24140  libopts_cv_with_libregex_cflags=no
24141fi
24142{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_with_libregex_cflags" >&5
24143$as_echo "$libopts_cv_with_libregex_cflags" >&6; }
24144
24145fi
24146 # end of AC_ARG_WITH libregex-cflags
24147
24148
24149# Check whether --with-libregex-libs was given.
24150if test "${with_libregex_libs+set}" = set; then :
24151  withval=$with_libregex_libs; libopts_cv_with_libregex_libs=${with_libregex_libs}
24152else
24153  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether with-libregex-libs was specified" >&5
24154$as_echo_n "checking whether with-libregex-libs was specified... " >&6; }
24155if ${libopts_cv_with_libregex_libs+:} false; then :
24156  $as_echo_n "(cached) " >&6
24157else
24158  libopts_cv_with_libregex_libs=no
24159fi
24160{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_with_libregex_libs" >&5
24161$as_echo "$libopts_cv_with_libregex_libs" >&6; }
24162
24163fi
24164 # end of AC_ARG_WITH libregex-libs
24165
24166  case "X${libopts_cv_with_libregex_cflags}" in
24167  Xyes|Xno|X )
24168    case "X${libopts_cv_with_libregex_root}" in
24169    Xyes|Xno|X ) libopts_cv_with_libregex_cflags=no ;;
24170    * ) libopts_cv_with_libregex_cflags=-I${libopts_cv_with_libregex_root}/include ;;
24171    esac
24172  esac
24173  case "X${libopts_cv_with_libregex_libs}" in
24174  Xyes|Xno|X )
24175    case "X${libopts_cv_with_libregex_root}" in
24176    Xyes|Xno|X ) libopts_cv_with_libregex_libs=no ;;
24177    * )        libopts_cv_with_libregex_libs="-L${libopts_cv_with_libregex_root}/lib -lregex" ;;
24178    esac
24179  esac
24180  libopts_save_CPPFLAGS="${CPPFLAGS}"
24181  libopts_save_LIBS="${LIBS}"
24182  case "X${libopts_cv_with_libregex_cflags}" in
24183  Xyes|Xno|X )
24184    libopts_cv_with_libregex_cflags="" ;;
24185  * ) CPPFLAGS="${CPPFLAGS} ${libopts_cv_with_libregex_cflags}" ;;
24186  esac
24187  case "X${libopts_cv_with_libregex_libs}" in
24188  Xyes|Xno|X )
24189    libopts_cv_with_libregex_libs="" ;;
24190  * )
24191    LIBS="${LIBS} ${libopts_cv_with_libregex_libs}" ;;
24192  esac
24193  LIBREGEX_CFLAGS=""
24194  LIBREGEX_LIBS=""
24195  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether libregex functions properly" >&5
24196$as_echo_n "checking whether libregex functions properly... " >&6; }
24197  if ${libopts_cv_with_libregex+:} false; then :
24198  $as_echo_n "(cached) " >&6
24199else
24200
24201  if test "$cross_compiling" = yes; then :
24202  libopts_cv_with_libregex=no
24203else
24204  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24205/* end confdefs.h.  */
24206#include <stdio.h>
24207#include <stdlib.h>
24208#include <sys/types.h>
24209#include REGEX_HEADER
24210static regex_t re;
24211void comp_re(char const * pzPat) {
24212  int res = regcomp( &re, pzPat, REG_EXTENDED|REG_ICASE|REG_NEWLINE );
24213  if (res == 0) return;
24214  exit( res ); }
24215int main() {
24216  regmatch_t m[2];
24217  comp_re( "^.*\$"   );
24218  comp_re( "()|no.*" );
24219  comp_re( "."       );
24220  if (regexec( &re, "X", 2, m, 0 ) != 0)  return 1;
24221  if ((m[0].rm_so != 0) || (m[0].rm_eo != 1)) {
24222    fputs( "error: regex -->.<-- did not match\n", stderr );
24223    return 1;
24224  }
24225  return 0; }
24226_ACEOF
24227if ac_fn_c_try_run "$LINENO"; then :
24228  libopts_cv_with_libregex=yes
24229else
24230  libopts_cv_with_libregex=no
24231fi
24232rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24233  conftest.$ac_objext conftest.beam conftest.$ac_ext
24234fi
24235 # end of AC_RUN_IFELSE
24236
24237fi
24238 # end of AC_CACHE_VAL for libopts_cv_with_libregex
24239  fi ## disabled by request
24240  { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_with_libregex}" >&5
24241$as_echo "${libopts_cv_with_libregex}" >&6; }
24242  if test "X${libopts_cv_with_libregex}" != Xno
24243  then
24244
24245$as_echo "#define WITH_LIBREGEX 1" >>confdefs.h
24246
24247  else
24248    CPPFLAGS="${libopts_save_CPPFLAGS}"
24249    LIBS="${libopts_save_LIBS}"
24250    libopts_cv_with_libregex_root=no
24251libopts_cv_with_libregex_cflags=no
24252libopts_cv_with_libregex_libs=no
24253libopts_cv_with_libregex=no
24254  fi
24255
24256
24257
24258  # Check to see if pathfind(3) works.
24259
24260  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pathfind(3) works" >&5
24261$as_echo_n "checking whether pathfind(3) works... " >&6; }
24262  if ${libopts_cv_run_pathfind+:} false; then :
24263  $as_echo_n "(cached) " >&6
24264else
24265
24266  if test "$cross_compiling" = yes; then :
24267  libopts_cv_run_pathfind=no
24268
24269else
24270  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24271/* end confdefs.h.  */
24272#include <string.h>
24273#include <stdlib.h>
24274int main (int argc, char ** argv) {
24275   char * pz = pathfind( getenv( "PATH" ), "sh", "x" );
24276   return (pz == 0) ? 1 : 0;
24277}
24278_ACEOF
24279if ac_fn_c_try_run "$LINENO"; then :
24280  libopts_cv_run_pathfind=yes
24281else
24282  libopts_cv_run_pathfind=no
24283fi
24284rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24285  conftest.$ac_objext conftest.beam conftest.$ac_ext
24286fi
24287 # end of RUN_IFELSE
24288
24289fi
24290 # end of AC_CACHE_VAL for libopts_cv_run_pathfind
24291  { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_pathfind}" >&5
24292$as_echo "${libopts_cv_run_pathfind}" >&6; }
24293  if test "X${libopts_cv_run_pathfind}" != Xno
24294  then
24295
24296$as_echo "#define HAVE_PATHFIND 1" >>confdefs.h
24297
24298  fi
24299
24300
24301
24302  # Check to see if /dev/zero is readable device.
24303
24304  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether /dev/zero is readable device" >&5
24305$as_echo_n "checking whether /dev/zero is readable device... " >&6; }
24306  if ${libopts_cv_test_dev_zero+:} false; then :
24307  $as_echo_n "(cached) " >&6
24308else
24309
24310    libopts_cv_test_dev_zero=`exec 2> /dev/null
24311dzero=\`ls -lL /dev/zero | egrep ^c......r\`
24312test -z "${dzero}" && exit 1
24313echo ${dzero}`
24314    if test $? -ne 0 || test -z "$libopts_cv_test_dev_zero"
24315    then libopts_cv_test_dev_zero=no
24316    fi
24317
24318fi
24319 # end of CACHE_VAL of libopts_cv_test_dev_zero
24320  { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_test_dev_zero}" >&5
24321$as_echo "${libopts_cv_test_dev_zero}" >&6; }
24322  if test "X${libopts_cv_test_dev_zero}" != Xno
24323  then
24324
24325$as_echo "#define HAVE_DEV_ZERO 1" >>confdefs.h
24326
24327  fi
24328
24329
24330
24331  # Check to see if we have a functional realpath(3C).
24332
24333  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we have a functional realpath(3C)" >&5
24334$as_echo_n "checking whether we have a functional realpath(3C)... " >&6; }
24335  if ${libopts_cv_run_realpath+:} false; then :
24336  $as_echo_n "(cached) " >&6
24337else
24338
24339  if test "$cross_compiling" = yes; then :
24340  libopts_cv_run_realpath=no
24341
24342else
24343  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24344/* end confdefs.h.  */
24345#include <limits.h>
24346#include <stdlib.h>
24347int main (int argc, char ** argv) {
24348#ifndef PATH_MAX
24349choke me!!
24350#else
24351   char zPath[PATH_MAX+1];
24352#endif
24353   char *pz = realpath(argv[0], zPath);
24354   return (pz == zPath) ? 0 : 1;
24355}
24356_ACEOF
24357if ac_fn_c_try_run "$LINENO"; then :
24358  libopts_cv_run_realpath=yes
24359else
24360  libopts_cv_run_realpath=no
24361fi
24362rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24363  conftest.$ac_objext conftest.beam conftest.$ac_ext
24364fi
24365 # end of RUN_IFELSE
24366
24367fi
24368 # end of AC_CACHE_VAL for libopts_cv_run_realpath
24369  { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_realpath}" >&5
24370$as_echo "${libopts_cv_run_realpath}" >&6; }
24371  if test "X${libopts_cv_run_realpath}" != Xno
24372  then
24373
24374$as_echo "#define HAVE_REALPATH 1" >>confdefs.h
24375
24376  fi
24377
24378
24379
24380  # Check to see if strftime() works.
24381
24382  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strftime() works" >&5
24383$as_echo_n "checking whether strftime() works... " >&6; }
24384  if ${libopts_cv_run_strftime+:} false; then :
24385  $as_echo_n "(cached) " >&6
24386else
24387
24388  if test "$cross_compiling" = yes; then :
24389  libopts_cv_run_strftime=no
24390
24391else
24392  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24393/* end confdefs.h.  */
24394#include <time.h>
24395#include <string.h>
24396char t_buf[ 64 ];
24397int main() {
24398  static char const z[] = "Thursday Aug 28 240";
24399  struct tm tm;
24400  tm.tm_sec   = 36;  /* seconds after the minute [0, 61]  */
24401  tm.tm_min   = 44;  /* minutes after the hour [0, 59] */
24402  tm.tm_hour  = 12;  /* hour since midnight [0, 23] */
24403  tm.tm_mday  = 28;  /* day of the month [1, 31] */
24404  tm.tm_mon   =  7;  /* months since January [0, 11] */
24405  tm.tm_year  = 86;  /* years since 1900 */
24406  tm.tm_wday  =  4;  /* days since Sunday [0, 6] */
24407  tm.tm_yday  = 239; /* days since January 1 [0, 365] */
24408  tm.tm_isdst =  1;  /* flag for daylight savings time */
24409  strftime( t_buf, sizeof( t_buf ), "%A %b %d %j", &tm );
24410  return (strcmp( t_buf, z ) != 0); }
24411_ACEOF
24412if ac_fn_c_try_run "$LINENO"; then :
24413  libopts_cv_run_strftime=yes
24414else
24415  libopts_cv_run_strftime=no
24416fi
24417rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24418  conftest.$ac_objext conftest.beam conftest.$ac_ext
24419fi
24420 # end of RUN_IFELSE
24421
24422fi
24423 # end of AC_CACHE_VAL for libopts_cv_run_strftime
24424  { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_strftime}" >&5
24425$as_echo "${libopts_cv_run_strftime}" >&6; }
24426  if test "X${libopts_cv_run_strftime}" != Xno
24427  then
24428
24429$as_echo "#define HAVE_STRFTIME 1" >>confdefs.h
24430
24431  fi
24432
24433
24434
24435  # Check to see if fopen accepts "b" mode.
24436
24437  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fopen accepts \"b\" mode" >&5
24438$as_echo_n "checking whether fopen accepts \"b\" mode... " >&6; }
24439  if ${libopts_cv_run_fopen_binary+:} false; then :
24440  $as_echo_n "(cached) " >&6
24441else
24442
24443  if test "$cross_compiling" = yes; then :
24444  libopts_cv_run_fopen_binary=no
24445
24446else
24447  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24448/* end confdefs.h.  */
24449#include <stdio.h>
24450int main (int argc, char ** argv) {
24451FILE * fp = fopen("conftest.$ac_ext", "rb");
24452return (fp == NULL) ? 1 : fclose(fp); }
24453_ACEOF
24454if ac_fn_c_try_run "$LINENO"; then :
24455  libopts_cv_run_fopen_binary=yes
24456else
24457  libopts_cv_run_fopen_binary=no
24458fi
24459rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24460  conftest.$ac_objext conftest.beam conftest.$ac_ext
24461fi
24462 # end of RUN_IFELSE
24463
24464fi
24465 # end of AC_CACHE_VAL for libopts_cv_run_fopen_binary
24466  { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_fopen_binary}" >&5
24467$as_echo "${libopts_cv_run_fopen_binary}" >&6; }
24468  if test "X${libopts_cv_run_fopen_binary}" != Xno
24469  then
24470
24471$as_echo "#define FOPEN_BINARY_FLAG \"b\"" >>confdefs.h
24472
24473  else
24474
24475$as_echo "#define FOPEN_BINARY_FLAG \"\"" >>confdefs.h
24476
24477  fi
24478
24479
24480
24481  # Check to see if fopen accepts "t" mode.
24482
24483  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fopen accepts \"t\" mode" >&5
24484$as_echo_n "checking whether fopen accepts \"t\" mode... " >&6; }
24485  if ${libopts_cv_run_fopen_text+:} false; then :
24486  $as_echo_n "(cached) " >&6
24487else
24488
24489  if test "$cross_compiling" = yes; then :
24490  libopts_cv_run_fopen_text=no
24491
24492else
24493  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24494/* end confdefs.h.  */
24495#include <stdio.h>
24496int main (int argc, char ** argv) {
24497FILE * fp = fopen("conftest.$ac_ext", "rt");
24498return (fp == NULL) ? 1 : fclose(fp); }
24499_ACEOF
24500if ac_fn_c_try_run "$LINENO"; then :
24501  libopts_cv_run_fopen_text=yes
24502else
24503  libopts_cv_run_fopen_text=no
24504fi
24505rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24506  conftest.$ac_objext conftest.beam conftest.$ac_ext
24507fi
24508 # end of RUN_IFELSE
24509
24510fi
24511 # end of AC_CACHE_VAL for libopts_cv_run_fopen_text
24512  { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_fopen_text}" >&5
24513$as_echo "${libopts_cv_run_fopen_text}" >&6; }
24514  if test "X${libopts_cv_run_fopen_text}" != Xno
24515  then
24516
24517$as_echo "#define FOPEN_TEXT_FLAG \"t\"" >>confdefs.h
24518
24519  else
24520
24521$as_echo "#define FOPEN_TEXT_FLAG \"\"" >>confdefs.h
24522
24523  fi
24524
24525
24526
24527  # Check to see if not wanting optional option args.
24528
24529  # Check whether --enable-optional-args was given.
24530if test "${enable_optional_args+set}" = set; then :
24531  enableval=$enable_optional_args; libopts_cv_enable_optional_args=${enable_optional_args}
24532else
24533  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether not wanting optional option args" >&5
24534$as_echo_n "checking whether not wanting optional option args... " >&6; }
24535if ${libopts_cv_enable_optional_args+:} false; then :
24536  $as_echo_n "(cached) " >&6
24537else
24538  libopts_cv_enable_optional_args=yes
24539fi
24540{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_enable_optional_args" >&5
24541$as_echo "$libopts_cv_enable_optional_args" >&6; }
24542
24543fi
24544 # end of AC_ARG_ENABLE
24545  if test "X${libopts_cv_enable_optional_args}" = Xno
24546  then
24547
24548$as_echo "#define NO_OPTIONAL_OPT_ARGS 1" >>confdefs.h
24549
24550  fi
24551
24552
24553
24554
24555
24556          fi
24557  ac_config_files="$ac_config_files libopts/Makefile"
24558
24559  # end of AC_DEFUN of LIBOPTS_CHECK
24560
24561
24562# From when we only used libevent for sntp:
24563#AM_COND_IF(
24564#    [BUILD_SNTP],
24565#    [NTP_LIBEVENT_CHECK],
24566#    [NTP_LIBEVENT_CHECK_NOBUILD]
24567#)
24568
24569
24570
24571ntp_pkgconfig_min_version='0.15.0'
24572if test -n "$ac_tool_prefix"; then
24573  # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
24574set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
24575{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
24576$as_echo_n "checking for $ac_word... " >&6; }
24577if ${ac_cv_path_PKG_CONFIG+:} false; then :
24578  $as_echo_n "(cached) " >&6
24579else
24580  case $PKG_CONFIG in
24581  [\\/]* | ?:[\\/]*)
24582  ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
24583  ;;
24584  *)
24585  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24586for as_dir in $PATH
24587do
24588  IFS=$as_save_IFS
24589  test -z "$as_dir" && as_dir=.
24590    for ac_exec_ext in '' $ac_executable_extensions; do
24591  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
24592    ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
24593    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
24594    break 2
24595  fi
24596done
24597  done
24598IFS=$as_save_IFS
24599
24600  ;;
24601esac
24602fi
24603PKG_CONFIG=$ac_cv_path_PKG_CONFIG
24604if test -n "$PKG_CONFIG"; then
24605  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
24606$as_echo "$PKG_CONFIG" >&6; }
24607else
24608  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24609$as_echo "no" >&6; }
24610fi
24611
24612
24613fi
24614if test -z "$ac_cv_path_PKG_CONFIG"; then
24615  ac_pt_PKG_CONFIG=$PKG_CONFIG
24616  # Extract the first word of "pkg-config", so it can be a program name with args.
24617set dummy pkg-config; ac_word=$2
24618{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
24619$as_echo_n "checking for $ac_word... " >&6; }
24620if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then :
24621  $as_echo_n "(cached) " >&6
24622else
24623  case $ac_pt_PKG_CONFIG in
24624  [\\/]* | ?:[\\/]*)
24625  ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
24626  ;;
24627  *)
24628  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24629for as_dir in $PATH
24630do
24631  IFS=$as_save_IFS
24632  test -z "$as_dir" && as_dir=.
24633    for ac_exec_ext in '' $ac_executable_extensions; do
24634  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
24635    ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
24636    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
24637    break 2
24638  fi
24639done
24640  done
24641IFS=$as_save_IFS
24642
24643  ;;
24644esac
24645fi
24646ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
24647if test -n "$ac_pt_PKG_CONFIG"; then
24648  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
24649$as_echo "$ac_pt_PKG_CONFIG" >&6; }
24650else
24651  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24652$as_echo "no" >&6; }
24653fi
24654
24655  if test "x$ac_pt_PKG_CONFIG" = x; then
24656    PKG_CONFIG=""
24657  else
24658    case $cross_compiling:$ac_tool_warned in
24659yes:)
24660{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
24661$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
24662ac_tool_warned=yes ;;
24663esac
24664    PKG_CONFIG=$ac_pt_PKG_CONFIG
24665  fi
24666else
24667  PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
24668fi
24669
24670{ ac_cv_path_PKG_CONFIG=; unset ac_cv_path_PKG_CONFIG;}
24671{ ac_cv_path_ac_pt_PKG_CONFIG=; unset ac_cv_path_ac_pt_PKG_CONFIG;}
24672
24673case "$PKG_CONFIG" in
24674 /*)
24675    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if pkg-config is at least version $ntp_pkgconfig_min_version" >&5
24676$as_echo_n "checking if pkg-config is at least version $ntp_pkgconfig_min_version... " >&6; }
24677    if $PKG_CONFIG --atleast-pkgconfig-version $ntp_pkgconfig_min_version; then
24678	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
24679$as_echo "yes" >&6; }
24680    else
24681	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24682$as_echo "no" >&6; }
24683	PKG_CONFIG=""
24684    fi
24685    ;;
24686esac
24687
24688
24689
24690
24691# Check whether --enable-local-libevent was given.
24692if test "${enable_local_libevent+set}" = set; then :
24693  enableval=$enable_local_libevent; ntp_use_local_libevent=$enableval
24694else
24695  ntp_use_local_libevent=${ntp_use_local_libevent-detect}
24696
24697fi
24698
24699
24700
24701
24702
24703
24704
24705
24706
24707
24708ntp_libevent_min_version=2
24709ntp_libevent_tearoff=libevent
24710
24711
24712
24713
24714
24715case "$ntp_use_local_libevent" in
24716 yes)
24717    ;;
24718 *) # If we have (a good enough) pkg-config, see if it can find libevent
24719    case "$PKG_CONFIG" in
24720     /*)
24721	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if libevent $ntp_libevent_min_version or later is installed" >&5
24722$as_echo_n "checking if libevent $ntp_libevent_min_version or later is installed... " >&6; }
24723	if $PKG_CONFIG --atleast-version=$ntp_libevent_min_version libevent
24724	then
24725	    ntp_use_local_libevent=no
24726	    { $as_echo "$as_me:${as_lineno-$LINENO}: Using the installed libevent" >&5
24727$as_echo "$as_me: Using the installed libevent" >&6;}
24728	    CFLAGS_LIBEVENT=`$PKG_CONFIG --cflags libevent_pthreads`
24729	    CPPFLAGS_LIBEVENT=`$PKG_CONFIG --cflags-only-I libevent`
24730	    # HMS: I hope the following is accurate.
24731	    # We don't need -levent, we only need  -levent_core.
24732	    # While we could grab only the -L stuff, there *might* be
24733	    # other flags there we want.  Originally we just removed -levent
24734	    # but then somebody decided to install -levent-2.0
24735	    # LDADD_LIBEVENT=`$PKG_CONFIG --libs libevent | sed 's:-levent::'`
24736	    # So now we dance...
24737	    LDADD_LIBEVENT=
24738	    for i in `$PKG_CONFIG --libs libevent` `$PKG_CONFIG --cflags-only-other libevent_pthreads`
24739	    do
24740		case "$i" in
24741		 -D*) ;;
24742		 -levent*) ;;
24743		 *) case "$LDADD_LIBEVENT" in
24744		     '') LDADD_LIBEVENT="$i" ;;
24745		     *) LDADD_LIBEVENT="$LDADD_LIBEVENT $i" ;;
24746		    esac
24747		    ;;
24748		esac
24749	    done
24750	    case "$LIBISC_PTHREADS_NOTHREADS" in
24751	     pthreads)
24752		LDADD_LIBEVENT="$LDADD_LIBEVENT -levent_pthreads"
24753	    esac
24754	    LDADD_LIBEVENT="$LDADD_LIBEVENT -levent_core"
24755	    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
24756$as_echo "yes" >&6; }
24757	else
24758	    ntp_use_local_libevent=yes
24759	    # HMS: do we only need to do this if LIBISC_PTHREADS_NOTHREADS
24760	    # is "pthreads"?
24761	    CFLAGS_LIBEVENT=`$PKG_CONFIG --cflags libevent_pthreads`
24762	    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24763$as_echo "no" >&6; }
24764	fi
24765	;;
24766     *)
24767	ntp_use_local_libevent=yes
24768	;;
24769    esac
24770    ;;
24771esac
24772
24773case "$ntp_use_local_libevent" in
24774 yes)
24775    { $as_echo "$as_me:${as_lineno-$LINENO}: Using libevent tearoff" >&5
24776$as_echo "$as_me: Using libevent tearoff" >&6;}
24777    CPPFLAGS_LIBEVENT="-I\$(top_builddir)/$ntp_libevent_tearoff/include -I\$(top_srcdir)/$ntp_libevent_tearoff/include"
24778    case "$LIBISC_PTHREADS_NOTHREADS" in
24779     pthreads)
24780	LDADD_LIBEVENT="\$(top_builddir)/$ntp_libevent_tearoff/libevent_pthreads.la \$(top_builddir)/$ntp_libevent_tearoff/libevent_core.la"
24781	;;
24782     *)
24783	LDADD_LIBEVENT="\$(top_builddir)/$ntp_libevent_tearoff/libevent_core.la"
24784    esac
24785esac
24786
24787
24788 if test "x$ntp_use_local_libevent" = "xyes"; then
24789  BUILD_LIBEVENT_TRUE=
24790  BUILD_LIBEVENT_FALSE='#'
24791else
24792  BUILD_LIBEVENT_TRUE='#'
24793  BUILD_LIBEVENT_FALSE=
24794fi
24795
24796
24797
24798
24799case "$ntp_libevent_tearoff" in
24800 libevent)
24801    ;;
24802 *)
24803    as_fn_error $? "ntp_libevent.m4 dir must be libevent, not $ntp_libevent_tearoff" "$LINENO" 5
24804    ;;
24805esac
24806
24807case "$ntp_use_local_libevent" in
24808 yes)
24809                        ac_configure_args=" --disable-openssl${ac_configure_args}"
24810    ac_configure_args=" --disable-shared${ac_configure_args}"
24811    ac_configure_args=" --disable-libevent-regress${ac_configure_args}"
24812    ac_configure_args=" --disable-libevent-install${ac_configure_args}"
24813    ac_configure_args=" --enable-silent-rules${ac_configure_args}"
24814    ac_configure_args=" --enable-function-sections${ac_configure_args}"
24815    ac_configure_args=" LEP_CFLAGS='${NTP_HARD_CFLAGS}'${ac_configure_args}"
24816    ac_configure_args=" LEP_CPPFLAGS='${NTP_HARD_CPPFLAGS}'${ac_configure_args}"
24817    ac_configure_args=" LEP_LDFLAGS='${NTP_HARD_LDFLAGS}'${ac_configure_args}"
24818    subdirs="$subdirs libevent"
24819
24820    ;;
24821 *)
24822    NTP_FORCE_LIBEVENT_DIST=libevent
24823    ;;
24824esac
24825
24826
24827
24828# Checks for libraries.
24829
24830
24831LIB_SYSLOG=''
24832
24833{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing openlog" >&5
24834$as_echo_n "checking for library containing openlog... " >&6; }
24835if ${ac_cv_search_openlog+:} false; then :
24836  $as_echo_n "(cached) " >&6
24837else
24838  ac_func_search_save_LIBS=$LIBS
24839cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24840/* end confdefs.h.  */
24841
24842/* Override any GCC internal prototype to avoid an error.
24843   Use char because int might match the return type of a GCC
24844   builtin and then its argument prototype would still apply.  */
24845#ifdef __cplusplus
24846extern "C"
24847#endif
24848char openlog ();
24849int
24850main ()
24851{
24852return openlog ();
24853  ;
24854  return 0;
24855}
24856_ACEOF
24857for ac_lib in '' gen syslog; do
24858  if test -z "$ac_lib"; then
24859    ac_res="none required"
24860  else
24861    ac_res=-l$ac_lib
24862    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
24863  fi
24864  if ac_fn_c_try_link "$LINENO"; then :
24865  ac_cv_search_openlog=$ac_res
24866fi
24867rm -f core conftest.err conftest.$ac_objext \
24868    conftest$ac_exeext
24869  if ${ac_cv_search_openlog+:} false; then :
24870  break
24871fi
24872done
24873if ${ac_cv_search_openlog+:} false; then :
24874
24875else
24876  ac_cv_search_openlog=no
24877fi
24878rm conftest.$ac_ext
24879LIBS=$ac_func_search_save_LIBS
24880fi
24881{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_openlog" >&5
24882$as_echo "$ac_cv_search_openlog" >&6; }
24883ac_res=$ac_cv_search_openlog
24884if test "$ac_res" != no; then :
24885  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
24886  case "$ac_cv_search_openlog" in
24887 'none required') ;;
24888 no) ;;
24889 *) LIB_SYSLOG="$ac_cv_search_openlog $LIB_SYSLOG" ;;
24890 esac
24891
24892fi
24893
24894
24895# Checks for header files.
24896for ac_header in netdb.h string.h strings.h syslog.h
24897do :
24898  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
24899ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
24900if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
24901  cat >>confdefs.h <<_ACEOF
24902#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
24903_ACEOF
24904
24905fi
24906
24907done
24908
24909
24910
24911for ac_header in sysexits.h
24912do :
24913  ac_fn_c_check_header_mongrel "$LINENO" "sysexits.h" "ac_cv_header_sysexits_h" "$ac_includes_default"
24914if test "x$ac_cv_header_sysexits_h" = xyes; then :
24915  cat >>confdefs.h <<_ACEOF
24916#define HAVE_SYSEXITS_H 1
24917_ACEOF
24918
24919else
24920
24921
24922$as_echo "#define EX_OK 0" >>confdefs.h
24923
24924
24925$as_echo "#define EX_SOFTWARE 70" >>confdefs.h
24926
24927
24928fi
24929
24930done
24931
24932
24933
24934{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for facilitynames in syslog.h" >&5
24935$as_echo_n "checking for facilitynames in syslog.h... " >&6; }
24936if ${ac_cv_HAVE_SYSLOG_FACILITYNAMES+:} false; then :
24937  $as_echo_n "(cached) " >&6
24938else
24939
24940cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24941/* end confdefs.h.  */
24942
24943#define SYSLOG_NAMES
24944#include <stdlib.h>
24945#include <syslog.h>
24946
24947int
24948main ()
24949{
24950 void *fnames; fnames = facilitynames;
24951  ;
24952  return 0;
24953}
24954_ACEOF
24955if ac_fn_c_try_compile "$LINENO"; then :
24956  ac_cv_HAVE_SYSLOG_FACILITYNAMES=yes
24957else
24958  ac_cv_HAVE_SYSLOG_FACILITYNAMES=no
24959fi
24960rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24961fi
24962{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_HAVE_SYSLOG_FACILITYNAMES" >&5
24963$as_echo "$ac_cv_HAVE_SYSLOG_FACILITYNAMES" >&6; }
24964case "$ac_cv_HAVE_SYSLOG_FACILITYNAMES" in
24965 yes)
24966
24967$as_echo "#define HAVE_SYSLOG_FACILITYNAMES 1" >>confdefs.h
24968
24969    ;;
24970 no)
24971    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: No facilitynames in <syslog.h>" >&5
24972$as_echo "$as_me: WARNING: No facilitynames in <syslog.h>" >&2;}
24973    ;;
24974 cross)
24975    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: facilitynames in <syslog.h> - cross-compiling" >&5
24976$as_echo "$as_me: WARNING: facilitynames in <syslog.h> - cross-compiling" >&2;}
24977    ;;
24978esac
24979
24980
24981# Checks for typedefs, structures, and compiler characteristics.
24982{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
24983$as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
24984if ${ac_cv_header_stdbool_h+:} false; then :
24985  $as_echo_n "(cached) " >&6
24986else
24987  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24988/* end confdefs.h.  */
24989
24990             #include <stdbool.h>
24991             #ifndef bool
24992              "error: bool is not defined"
24993             #endif
24994             #ifndef false
24995              "error: false is not defined"
24996             #endif
24997             #if false
24998              "error: false is not 0"
24999             #endif
25000             #ifndef true
25001              "error: true is not defined"
25002             #endif
25003             #if true != 1
25004              "error: true is not 1"
25005             #endif
25006             #ifndef __bool_true_false_are_defined
25007              "error: __bool_true_false_are_defined is not defined"
25008             #endif
25009
25010             struct s { _Bool s: 1; _Bool t; } s;
25011
25012             char a[true == 1 ? 1 : -1];
25013             char b[false == 0 ? 1 : -1];
25014             char c[__bool_true_false_are_defined == 1 ? 1 : -1];
25015             char d[(bool) 0.5 == true ? 1 : -1];
25016             /* See body of main program for 'e'.  */
25017             char f[(_Bool) 0.0 == false ? 1 : -1];
25018             char g[true];
25019             char h[sizeof (_Bool)];
25020             char i[sizeof s.t];
25021             enum { j = false, k = true, l = false * true, m = true * 256 };
25022             /* The following fails for
25023                HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
25024             _Bool n[m];
25025             char o[sizeof n == m * sizeof n[0] ? 1 : -1];
25026             char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
25027             /* Catch a bug in an HP-UX C compiler.  See
25028                http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
25029                http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
25030              */
25031             _Bool q = true;
25032             _Bool *pq = &q;
25033
25034int
25035main ()
25036{
25037
25038             bool e = &s;
25039             *pq |= q;
25040             *pq |= ! q;
25041             /* Refer to every declared value, to avoid compiler optimizations.  */
25042             return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
25043                     + !m + !n + !o + !p + !q + !pq);
25044
25045  ;
25046  return 0;
25047}
25048_ACEOF
25049if ac_fn_c_try_compile "$LINENO"; then :
25050  ac_cv_header_stdbool_h=yes
25051else
25052  ac_cv_header_stdbool_h=no
25053fi
25054rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25055fi
25056{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
25057$as_echo "$ac_cv_header_stdbool_h" >&6; }
25058   ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
25059if test "x$ac_cv_type__Bool" = xyes; then :
25060
25061cat >>confdefs.h <<_ACEOF
25062#define HAVE__BOOL 1
25063_ACEOF
25064
25065
25066fi
25067
25068
25069if test $ac_cv_header_stdbool_h = yes; then
25070
25071$as_echo "#define HAVE_STDBOOL_H 1" >>confdefs.h
25072
25073fi
25074
25075
25076
25077
25078
25079VER_SUFFIX=
25080
25081
25082
25083
25084# Check whether --with-crypto was given.
25085if test "${with_crypto+set}" = set; then :
25086  withval=$with_crypto;
25087fi
25088
25089
25090# Check whether --with-openssl-libdir was given.
25091if test "${with_openssl_libdir+set}" = set; then :
25092  withval=$with_openssl_libdir;
25093fi
25094
25095
25096# Check whether --with-openssl-incdir was given.
25097if test "${with_openssl_incdir+set}" = set; then :
25098  withval=$with_openssl_incdir;
25099fi
25100
25101
25102# Check whether --with-rpath was given.
25103if test "${with_rpath+set}" = set; then :
25104  withval=$with_rpath;
25105fi
25106
25107
25108ntp_openssl=no
25109ntp_openssl_from_pkg_config=no
25110
25111with_crypto=${with_crypto:-openssl,libcrypto}
25112case "$with_crypto" in
25113 yes)
25114    with_crypto=openssl,libcrypto
25115esac
25116
25117
25118case "$with_crypto:${PKG_CONFIG:+notempty}:${with_openssl_libdir-notgiven}:${with_openssl_incdir-notgiven}" in
25119 no:*) ;;
25120 *:notempty:notgiven:notgiven)
25121    for pkg in `echo $with_crypto | sed -e 's/,/ /'`; do
25122	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config for $pkg" >&5
25123$as_echo_n "checking pkg-config for $pkg... " >&6; }
25124	if $PKG_CONFIG --exists $pkg ; then
25125	    CPPFLAGS_NTP="$CPPFLAGS_NTP `$PKG_CONFIG --cflags-only-I $pkg`"
25126	    CFLAGS_NTP="$CFLAGS_NTP `$PKG_CONFIG --cflags-only-other $pkg`"
25127	    LDADD_NTP="$LDADD_NTP `$PKG_CONFIG --libs-only-L $pkg`"
25128	    LDADD_NTP="$LDADD_NTP `$PKG_CONFIG --libs-only-l --static $pkg`"
25129	    LDFLAGS_NTP="$LDFLAGS_NTP `$PKG_CONFIG --libs-only-other $pkg`"
25130	    VER_SUFFIX=o
25131	    ntp_openssl=yes
25132	    ntp_openssl_from_pkg_config=yes
25133	    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
25134$as_echo "yes" >&6; }
25135
25136	    break
25137	fi
25138	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25139$as_echo "no" >&6; }
25140    done
25141esac
25142case "$with_crypto:$ntp_openssl" in
25143 no:*) ;;
25144 *:no)
25145    need_dash_r=
25146    need_dash_Wlrpath=
25147    case "${with_rpath-notgiven}" in
25148     yes)
25149	# Lame - what to do if we need -Wl... but not -R?
25150	need_dash_r=1
25151	;;
25152     notgiven)
25153	case "$host" in
25154	 *-*-linux*)
25155	    # This may really only be true for gcc
25156	    need_dash_Wlrpath=1
25157	    ;;
25158	 *-*-netbsd*)
25159	    need_dash_r=1
25160	    ;;
25161	 *-*-solaris*)
25162	    need_dash_r=1
25163	    ;;
25164	esac
25165	;;
25166    esac
25167
25168    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for openssl library directory" >&5
25169$as_echo_n "checking for openssl library directory... " >&6; }
25170    with_openssl_libdir=${with_openssl_libdir-notgiven}
25171    case "$with_openssl_libdir" in
25172     notgiven)
25173	case "$build" in
25174	 $host)
25175	    with_openssl_libdir=default
25176	    ;;
25177	 *)
25178	    with_openssl_libdir=no
25179	    ;;
25180	esac
25181    esac
25182    case "$with_openssl_libdir" in
25183     default)
25184	# Look in:
25185	with_openssl_libdir="/usr/lib /usr/lib/openssl /usr/sfw/lib"
25186	with_openssl_libdir="$with_openssl_libdir /usr/local/lib"
25187	with_openssl_libdir="$with_openssl_libdir /usr/local/ssl/lib /lib"
25188    esac
25189    case "$with_openssl_libdir" in
25190     no)
25191	;;
25192     *) # Look for libcrypto.a and libssl.a:
25193	for i in $with_openssl_libdir no
25194	do
25195	    case "$host" in
25196	     *-*-darwin*)
25197		test -f $i/libcrypto.dylib -a -f $i/libssl.dylib && break
25198		;;
25199	     *)
25200		test -f $i/libcrypto.so -a -f $i/libssl.so && break
25201		test -f $i/libcrypto.a -a -f $i/libssl.a && break
25202		;;
25203	    esac
25204	done
25205	openssl_libdir=$i
25206	;;
25207    esac
25208    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $openssl_libdir" >&5
25209$as_echo "$openssl_libdir" >&6; }
25210    case "$openssl_libdir" in
25211     no)
25212	openssl_libdir=
25213	{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libcrypto and libssl not found in any of $with_openssl_libdir" >&5
25214$as_echo "$as_me: WARNING: libcrypto and libssl not found in any of $with_openssl_libdir" >&2;}
25215    esac
25216
25217    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for openssl include directory" >&5
25218$as_echo_n "checking for openssl include directory... " >&6; }
25219    with_openssl_incdir=${with_openssl_incdir-notgiven}
25220    case "$with_openssl_incdir" in
25221     notgiven)
25222	# Look in:
25223	with_openssl_incdir="/usr/include /usr/sfw/include"
25224	with_openssl_incdir="$with_openssl_incdir /usr/local/include"
25225	with_openssl_incdir="$with_openssl_incdir /usr/local/ssl/include"
25226    esac
25227    case "$with_openssl_incdir" in
25228     no)
25229	;;
25230     *) # look for openssl/evp.h:
25231	for i in $with_openssl_incdir no
25232	do
25233	    test -f $i/openssl/evp.h && break
25234	done
25235	openssl_incdir=$i
25236	;;
25237    esac
25238    { i=; unset i;}
25239    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $openssl_incdir" >&5
25240$as_echo "$openssl_incdir" >&6; }
25241    case "$openssl_incdir" in
25242     no)
25243	openssl_incdir=
25244	{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: did not find openssl/evp.h in any of $with_openssl_incdir" >&5
25245$as_echo "$as_me: WARNING: did not find openssl/evp.h in any of $with_openssl_incdir" >&2;}
25246    esac
25247    if test -z "$openssl_libdir" -o -z "$openssl_incdir"
25248    then
25249	ntp_openssl=no
25250    else
25251	ntp_openssl=yes
25252	VER_SUFFIX=o
25253    fi
25254    case "$ntp_openssl" in
25255     yes)
25256	# We have OpenSSL inc/lib dirs - use them.
25257	case "$openssl_incdir" in
25258	 /usr/include)
25259	    ;;
25260	 *)
25261	    CPPFLAGS_NTP="$CPPFLAGS_NTP -I$openssl_incdir"
25262	    ;;
25263	esac
25264	case "$openssl_libdir" in
25265	 /usr/lib)
25266	    ;;
25267	 *)
25268	    LDADD_NTP="$LDADD_NTP -L$openssl_libdir"
25269	    case "$need_dash_r" in
25270	     1)
25271		LDFLAGS_NTP="$LDFLAGS_NTP -R$openssl_libdir"
25272	    esac
25273	    case "$need_dash_Wlrpath" in
25274	     1)
25275		LDFLAGS_NTP="$LDFLAGS_NTP -Wl,-rpath,$openssl_libdir"
25276	    esac
25277	    ;;
25278	esac
25279	LDADD_NTP="$LDADD_NTP -lcrypto"
25280    esac
25281esac
25282
25283{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we will use crypto" >&5
25284$as_echo_n "checking if we will use crypto... " >&6; }
25285{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_openssl" >&5
25286$as_echo "$ntp_openssl" >&6; }
25287
25288case "$ntp_openssl" in
25289 yes)
25290
25291$as_echo "#define OPENSSL /**/" >>confdefs.h
25292
25293    case "$VER_SUFFIX" in
25294     *o*) ;;
25295     *) as_fn_error $? "OPENSSL set but no 'o' in VER_SUFFIX!" "$LINENO" 5 ;;
25296    esac
25297    ;;
25298esac
25299
25300NTPO_SAVED_CPPFLAGS="$CPPFLAGS"
25301CPPFLAGS="$CPPFLAGS $CPPFLAGS_NTP"
25302NTPO_SAVED_LIBS="$LIBS"
25303
25304#
25305# check for linking with -lcrypto failure, and try -lcrypto -lz.
25306# Helps m68k-atari-mint
25307#
25308case "$ntp_openssl:$ntp_openssl_from_pkg_config" in
25309 yes:no)
25310    LIBS="$NTPO_SAVED_LIBS $LDADD_NTP"
25311    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linking with -lcrypto alone works" >&5
25312$as_echo_n "checking if linking with -lcrypto alone works... " >&6; }
25313if ${ntp_cv_bare_lcrypto+:} false; then :
25314  $as_echo_n "(cached) " >&6
25315else
25316  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25317/* end confdefs.h.  */
25318
25319		    #include "openssl/err.h"
25320		    #include "openssl/evp.h"
25321
25322int
25323main ()
25324{
25325
25326		    ERR_load_crypto_strings();
25327		    OpenSSL_add_all_algorithms();
25328
25329
25330  ;
25331  return 0;
25332}
25333_ACEOF
25334if ac_fn_c_try_link "$LINENO"; then :
25335  ntp_cv_bare_lcrypto=yes
25336else
25337  ntp_cv_bare_lcrypto=no
25338
25339fi
25340rm -f core conftest.err conftest.$ac_objext \
25341    conftest$ac_exeext conftest.$ac_ext
25342
25343fi
25344{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_bare_lcrypto" >&5
25345$as_echo "$ntp_cv_bare_lcrypto" >&6; }
25346    case "$ntp_cv_bare_lcrypto" in
25347     no)
25348	LIBS="$NTPO_SAVED_LIBS $LDADD_NTP -lz"
25349	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if linking with -lcrypto -lz works" >&5
25350$as_echo_n "checking if linking with -lcrypto -lz works... " >&6; }
25351if ${ntp_cv_lcrypto_lz+:} false; then :
25352  $as_echo_n "(cached) " >&6
25353else
25354  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25355/* end confdefs.h.  */
25356
25357			#include "openssl/err.h"
25358			#include "openssl/evp.h"
25359
25360int
25361main ()
25362{
25363
25364			ERR_load_crypto_strings();
25365			OpenSSL_add_all_algorithms();
25366
25367
25368  ;
25369  return 0;
25370}
25371_ACEOF
25372if ac_fn_c_try_link "$LINENO"; then :
25373  ntp_cv_lcrypto_lz=yes
25374else
25375  ntp_cv_lcrypto_lz=no
25376
25377fi
25378rm -f core conftest.err conftest.$ac_objext \
25379    conftest$ac_exeext conftest.$ac_ext
25380
25381fi
25382{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_lcrypto_lz" >&5
25383$as_echo "$ntp_cv_lcrypto_lz" >&6; }
25384	case "$ntp_cv_lcrypto_lz" in
25385	 yes)
25386	     LDADD_NTP="$LDADD_NTP -lz"
25387	esac
25388    esac
25389esac
25390
25391#
25392# Older OpenSSL headers have a number of callback prototypes inside
25393# other function prototypes which trigger copious warnings with gcc's
25394# -Wstrict-prototypes, which is included in -Wall.
25395#
25396# An example:
25397#
25398# int i2d_RSA_NET(const RSA *a, unsigned char **pp,
25399#		  int (*cb)(), int sgckey);
25400#		  ^^^^^^^^^^^
25401#
25402#
25403#
25404openssl_triggers_warnings=unknown
25405NTPO_SAVED_CFLAGS="$CFLAGS"
25406
25407case "$ntp_openssl:$GCC" in
25408 yes:yes)
25409    CFLAGS="$CFLAGS -Werror"
25410    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25411/* end confdefs.h.  */
25412
25413
25414int
25415main ()
25416{
25417
25418		/* see if -Werror breaks gcc */
25419
25420
25421  ;
25422  return 0;
25423}
25424_ACEOF
25425if ac_fn_c_try_compile "$LINENO"; then :
25426  gcc_handles_Werror=yes
25427else
25428  gcc_handles_Werror=no
25429
25430fi
25431rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25432    case "$gcc_handles_Werror" in
25433     no)
25434	# if this gcc doesn't do -Werror go ahead and use
25435	# -Wstrict-prototypes.
25436	openssl_triggers_warnings=yes
25437	;;
25438     yes)
25439	CFLAGS="$CFLAGS -Wstrict-prototypes"
25440	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25441/* end confdefs.h.  */
25442
25443		    #include "openssl/asn1_mac.h"
25444		    #include "openssl/bn.h"
25445		    #include "openssl/err.h"
25446		    #include "openssl/evp.h"
25447		    #include "openssl/pem.h"
25448		    #include "openssl/rand.h"
25449		    #include "openssl/x509v3.h"
25450
25451int
25452main ()
25453{
25454
25455		    /* empty body */
25456
25457
25458  ;
25459  return 0;
25460}
25461_ACEOF
25462if ac_fn_c_try_compile "$LINENO"; then :
25463  openssl_triggers_warnings=no
25464else
25465  openssl_triggers_warnings=yes
25466
25467fi
25468rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25469    esac
25470    case "$openssl_triggers_warnings" in
25471     yes)
25472	CFLAGS_NTP="$CFLAGS_NTP -Wno-strict-prototypes"
25473	;;
25474     *)
25475	CFLAGS_NTP="$CFLAGS_NTP -Wstrict-prototypes"
25476    esac
25477    ;;
25478 no:yes)
25479    # gcc without OpenSSL
25480    CFLAGS_NTP="$CFLAGS_NTP -Wstrict-prototypes"
25481esac
25482
25483# Because we don't want -Werror for the EVP_MD_do_all_sorted check
25484CFLAGS="$NTPO_SAVED_CFLAGS"
25485
25486case "$ntp_openssl" in
25487 yes)
25488    LIBS="$NTPO_SAVED_LIBS $LDADD_NTP"
25489    for ac_func in EVP_MD_do_all_sorted
25490do :
25491  ac_fn_c_check_func "$LINENO" "EVP_MD_do_all_sorted" "ac_cv_func_EVP_MD_do_all_sorted"
25492if test "x$ac_cv_func_EVP_MD_do_all_sorted" = xyes; then :
25493  cat >>confdefs.h <<_ACEOF
25494#define HAVE_EVP_MD_DO_ALL_SORTED 1
25495_ACEOF
25496
25497fi
25498done
25499
25500    ;;
25501esac
25502
25503
25504CPPFLAGS="$NTPO_SAVED_CPPFLAGS"
25505LIBS="$NTPO_SAVED_LIBS"
25506{ NTPO_SAVED_CFLAGS=; unset NTPO_SAVED_CFLAGS;}
25507{ NTPO_SAVED_CPPFLAGS=; unset NTPO_SAVED_CPPFLAGS;}
25508{ NTPO_SAVED_LIBS=; unset NTPO_SAVED_LIBS;}
25509{ openssl_triggers_warnings=; unset openssl_triggers_warnings;}
25510{ ntp_openssl_from_pkg_config=; unset ntp_openssl_from_pkg_config;}
25511
25512
25513
25514{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct sockaddr_storage" >&5
25515$as_echo_n "checking for struct sockaddr_storage... " >&6; }
25516if ${ntp_cv_sockaddr_storage+:} false; then :
25517  $as_echo_n "(cached) " >&6
25518else
25519  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25520/* end confdefs.h.  */
25521
25522		#ifdef HAVE_SYS_TYPES_H
25523		# include <sys/types.h>
25524		#endif
25525		#ifdef HAVE_SYS_SOCKET_H
25526		# include <sys/socket.h>
25527		#endif
25528		#ifdef HAVE_NETINET_IN_H
25529		# include <netinet/in.h>
25530		#endif
25531
25532int
25533main ()
25534{
25535
25536		struct sockaddr_storage n;
25537
25538
25539  ;
25540  return 0;
25541}
25542_ACEOF
25543if ac_fn_c_try_compile "$LINENO"; then :
25544  ntp_cv_sockaddr_storage=yes
25545else
25546  ntp_cv_sockaddr_storage=no
25547
25548fi
25549rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25550
25551fi
25552{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_sockaddr_storage" >&5
25553$as_echo "$ntp_cv_sockaddr_storage" >&6; }
25554case "$ntp_cv_sockaddr_storage" in
25555 yes)
25556
25557$as_echo "#define HAVE_STRUCT_SOCKADDR_STORAGE 1" >>confdefs.h
25558
25559    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sockaddr_storage.__ss_family" >&5
25560$as_echo_n "checking for sockaddr_storage.__ss_family... " >&6; }
25561if ${ntp_cv_have___ss_family+:} false; then :
25562  $as_echo_n "(cached) " >&6
25563else
25564  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25565/* end confdefs.h.  */
25566
25567		    #ifdef HAVE_SYS_TYPES_H
25568		    # include <sys/types.h>
25569		    #endif
25570		    #ifdef HAVE_SYS_SOCKET_H
25571		    # include <sys/socket.h>
25572		    #endif
25573		    #ifdef HAVE_NETINET_IN_H
25574		    # include <netinet/in.h>
25575		    #endif
25576
25577int
25578main ()
25579{
25580
25581		    struct sockaddr_storage s;
25582		    s.__ss_family = 1;
25583
25584
25585  ;
25586  return 0;
25587}
25588_ACEOF
25589if ac_fn_c_try_compile "$LINENO"; then :
25590  ntp_cv_have___ss_family=yes
25591else
25592  ntp_cv_have___ss_family=no
25593
25594fi
25595rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25596
25597fi
25598{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_have___ss_family" >&5
25599$as_echo "$ntp_cv_have___ss_family" >&6; }
25600    case "$ntp_cv_have___ss_family" in
25601     yes)
25602
25603$as_echo "#define HAVE___SS_FAMILY_IN_SS 1" >>confdefs.h
25604
25605    esac
25606
25607esac
25608
25609
25610#
25611# Look for in_port_t.
25612#
25613{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for in_port_t" >&5
25614$as_echo_n "checking for in_port_t... " >&6; }
25615if ${isc_cv_have_in_port_t+:} false; then :
25616  $as_echo_n "(cached) " >&6
25617else
25618  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25619/* end confdefs.h.  */
25620
25621		#include <sys/types.h>
25622		#include <netinet/in.h>
25623
25624int
25625main ()
25626{
25627
25628		in_port_t port = 25;
25629		return (0);
25630
25631
25632  ;
25633  return 0;
25634}
25635_ACEOF
25636if ac_fn_c_try_compile "$LINENO"; then :
25637  isc_cv_have_in_port_t=yes
25638else
25639  isc_cv_have_in_port_t=no
25640
25641fi
25642rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25643
25644fi
25645{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_have_in_port_t" >&5
25646$as_echo "$isc_cv_have_in_port_t" >&6; }
25647case "$isc_cv_have_in_port_t" in
25648 no)
25649
25650$as_echo "#define ISC_PLATFORM_NEEDPORTT 1" >>confdefs.h
25651
25652esac
25653
25654{ $as_echo "$as_me:${as_lineno-$LINENO}: checking type of socklen arg for getsockname()" >&5
25655$as_echo_n "checking type of socklen arg for getsockname()... " >&6; }
25656if ${ntp_cv_getsockname_socklen_type+:} false; then :
25657  $as_echo_n "(cached) " >&6
25658else
25659
25660    getsockname_socklen_type_found=no
25661    for getsockname_arg2 in 'struct sockaddr *' 'void *'; do
25662	for ntp_cv_getsockname_socklen_type in 'socklen_t' 'size_t' 'unsigned int' 'int'; do
25663	    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25664/* end confdefs.h.  */
25665
25666			#ifdef HAVE_SYS_TYPES_H
25667			# include <sys/types.h>
25668			#endif
25669			#ifdef HAVE_SYS_SOCKET_H
25670			# include <sys/socket.h>
25671			#endif
25672
25673int
25674main ()
25675{
25676
25677			extern
25678			getsockname(int, $getsockname_arg2,
25679				$ntp_cv_getsockname_socklen_type *);
25680
25681
25682  ;
25683  return 0;
25684}
25685_ACEOF
25686if ac_fn_c_try_compile "$LINENO"; then :
25687  getsockname_socklen_type_found=yes ; break 2
25688fi
25689rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25690	done
25691    done
25692    case "$getsockname_socklen_type_found" in
25693     no)
25694	ntp_cv_getsockname_socklen_type='socklen_t'
25695    esac
25696    { getsockname_arg2=; unset getsockname_arg2;}
25697    { getsockname_socklen_type_found=; unset getsockname_socklen_type_found;}
25698
25699
25700fi
25701{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_getsockname_socklen_type" >&5
25702$as_echo "$ntp_cv_getsockname_socklen_type" >&6; }
25703
25704cat >>confdefs.h <<_ACEOF
25705#define GETSOCKNAME_SOCKLEN_TYPE $ntp_cv_getsockname_socklen_type
25706_ACEOF
25707
25708
25709{ $as_echo "$as_me:${as_lineno-$LINENO}: checking struct sockaddr for sa_len" >&5
25710$as_echo_n "checking struct sockaddr for sa_len... " >&6; }
25711if ${isc_cv_platform_havesalen+:} false; then :
25712  $as_echo_n "(cached) " >&6
25713else
25714  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25715/* end confdefs.h.  */
25716
25717		#include <sys/types.h>
25718		#include <sys/socket.h>
25719
25720int
25721main ()
25722{
25723
25724		extern struct sockaddr *ps;
25725		return ps->sa_len;
25726
25727
25728  ;
25729  return 0;
25730}
25731_ACEOF
25732if ac_fn_c_try_compile "$LINENO"; then :
25733  isc_cv_platform_havesalen=yes
25734else
25735  isc_cv_platform_havesalen=no
25736
25737fi
25738rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25739
25740fi
25741{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_platform_havesalen" >&5
25742$as_echo "$isc_cv_platform_havesalen" >&6; }
25743case "$isc_cv_platform_havesalen" in
25744 yes)
25745
25746$as_echo "#define ISC_PLATFORM_HAVESALEN 1" >>confdefs.h
25747
25748esac
25749
25750# Check whether --enable-ipv6 was given.
25751if test "${enable_ipv6+set}" = set; then :
25752  enableval=$enable_ipv6;
25753fi
25754
25755
25756case "$enable_ipv6" in
25757 yes|''|autodetect)
25758    case "$host" in
25759     powerpc-ibm-aix4*)
25760	;;
25761     *)
25762
25763$as_echo "#define WANT_IPV6 1" >>confdefs.h
25764
25765	;;
25766    esac
25767    ;;
25768 no)
25769    ;;
25770esac
25771
25772
25773case "$host" in
25774 *-*-darwin*)
25775
25776$as_echo "#define __APPLE_USE_RFC_3542 1" >>confdefs.h
25777
25778esac
25779
25780
25781{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for IPv6 structures" >&5
25782$as_echo_n "checking for IPv6 structures... " >&6; }
25783if ${isc_cv_found_ipv6+:} false; then :
25784  $as_echo_n "(cached) " >&6
25785else
25786  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25787/* end confdefs.h.  */
25788
25789		#include <sys/types.h>
25790		#include <sys/socket.h>
25791		#include <netinet/in.h>
25792
25793int
25794main ()
25795{
25796
25797		struct sockaddr_in6 sin6;
25798
25799
25800  ;
25801  return 0;
25802}
25803_ACEOF
25804if ac_fn_c_try_compile "$LINENO"; then :
25805  isc_cv_found_ipv6=yes
25806else
25807  isc_cv_found_ipv6=no
25808
25809fi
25810rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25811
25812fi
25813{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_found_ipv6" >&5
25814$as_echo "$isc_cv_found_ipv6" >&6; }
25815
25816#
25817# See whether IPv6 support is provided via a Kame add-on.
25818# This is done before other IPv6 linking tests so LIBS is properly set.
25819#
25820{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Kame IPv6 support" >&5
25821$as_echo_n "checking for Kame IPv6 support... " >&6; }
25822
25823# Check whether --with-kame was given.
25824if test "${with_kame+set}" = set; then :
25825  withval=$with_kame; use_kame="$withval"
25826else
25827  use_kame="no"
25828
25829fi
25830
25831case "$use_kame" in
25832 no)
25833    ;;
25834 yes)
25835    kame_path=/usr/local/v6
25836    ;;
25837 *)
25838    kame_path="$use_kame"
25839    ;;
25840esac
25841case "$use_kame" in
25842 no)
25843    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25844$as_echo "no" >&6; }
25845    ;;
25846 *)
25847    if test -f $kame_path/lib/libinet6.a; then
25848	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $kame_path/lib/libinet6.a" >&5
25849$as_echo "$kame_path/lib/libinet6.a" >&6; }
25850	LIBS="-L$kame_path/lib -linet6 $LIBS"
25851    else
25852	as_fn_error $? "$kame_path/lib/libinet6.a not found.
25853
25854Please choose the proper path with the following command:
25855
25856    configure --with-kame=PATH
25857" "$LINENO" 5
25858    fi
25859    ;;
25860esac
25861
25862#
25863# Whether netinet6/in6.h is needed has to be defined in isc/platform.h.
25864# Including it on Kame-using platforms is very bad, though, because
25865# Kame uses #error against direct inclusion.   So include it on only
25866# the platform that is otherwise broken without it -- BSD/OS 4.0 through 4.1.
25867# This is done before the in6_pktinfo check because that's what
25868# netinet6/in6.h is needed for.
25869#
25870case "$host" in
25871 *-bsdi4.[01]*)
25872
25873$as_echo "#define ISC_PLATFORM_NEEDNETINET6IN6H 1" >>confdefs.h
25874
25875    isc_netinet6in6_hack="#include <netinet6/in6.h>"
25876    ;;
25877 *)
25878    isc_netinet6in6_hack=""
25879    ;;
25880esac
25881
25882#
25883# This is similar to the netinet6/in6.h issue.
25884#
25885case "$host" in
25886 *-sco-sysv*uw*|*-*-sysv*UnixWare*|*-*-sysv*OpenUNIX*)
25887
25888$as_echo "#define ISC_PLATFORM_FIXIN6ISADDR 1" >>confdefs.h
25889
25890    isc_netinetin6_hack="#include <netinet/in6.h>"
25891    ;;
25892 *)
25893    isc_netinetin6_hack=""
25894    ;;
25895esac
25896
25897
25898case "$isc_cv_found_ipv6" in
25899 yes)
25900
25901$as_echo "#define ISC_PLATFORM_HAVEIPV6 1" >>confdefs.h
25902
25903    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for in6_pktinfo" >&5
25904$as_echo_n "checking for in6_pktinfo... " >&6; }
25905if ${isc_cv_have_in6_pktinfo+:} false; then :
25906  $as_echo_n "(cached) " >&6
25907else
25908  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25909/* end confdefs.h.  */
25910
25911		    #include <sys/types.h>
25912		    #include <sys/socket.h>
25913		    #include <netinet/in.h>
25914		    $isc_netinetin6_hack
25915		    $isc_netinet6in6_hack
25916
25917int
25918main ()
25919{
25920
25921		    struct in6_pktinfo xyzzy;
25922
25923
25924  ;
25925  return 0;
25926}
25927_ACEOF
25928if ac_fn_c_try_compile "$LINENO"; then :
25929  isc_cv_have_in6_pktinfo=yes
25930else
25931  isc_cv_have_in6_pktinfo=no
25932
25933fi
25934rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25935
25936fi
25937{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_have_in6_pktinfo" >&5
25938$as_echo "$isc_cv_have_in6_pktinfo" >&6; }
25939    case "$isc_cv_have_in6_pktinfo" in
25940     yes)
25941
25942$as_echo "#define ISC_PLATFORM_HAVEIN6PKTINFO 1" >>confdefs.h
25943
25944    esac
25945
25946
25947    # HMS: Use HAVE_STRUCT_SOCKADDR_IN6_SIN6_SCOPE_ID instead?
25948    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sockaddr_in6.sin6_scope_id" >&5
25949$as_echo_n "checking for sockaddr_in6.sin6_scope_id... " >&6; }
25950if ${isc_cv_have_sin6_scope_id+:} false; then :
25951  $as_echo_n "(cached) " >&6
25952else
25953  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25954/* end confdefs.h.  */
25955
25956		    #include <sys/types.h>
25957		    #include <sys/socket.h>
25958		    #include <netinet/in.h>
25959		    $isc_netinetin6_hack
25960		    $isc_netinet6in6_hack
25961
25962int
25963main ()
25964{
25965
25966		    struct sockaddr_in6 xyzzy;
25967		    xyzzy.sin6_scope_id = 0;
25968
25969
25970  ;
25971  return 0;
25972}
25973_ACEOF
25974if ac_fn_c_try_compile "$LINENO"; then :
25975  isc_cv_have_sin6_scope_id=yes
25976else
25977  isc_cv_have_sin6_scope_id=no
25978
25979fi
25980rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25981
25982fi
25983{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_have_sin6_scope_id" >&5
25984$as_echo "$isc_cv_have_sin6_scope_id" >&6; }
25985
25986    case "$isc_cv_have_sin6_scope_id" in
25987     yes)
25988
25989$as_echo "#define ISC_PLATFORM_HAVESCOPEID 1" >>confdefs.h
25990
25991    esac
25992esac
25993
25994
25995# We need this check run even without isc_cv_found_ipv6=yes
25996
25997{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for in6addr_any" >&5
25998$as_echo_n "checking for in6addr_any... " >&6; }
25999if ${isc_cv_in6addr_any_links+:} false; then :
26000  $as_echo_n "(cached) " >&6
26001else
26002
26003	SAVED_LIBS="$LIBS"
26004	LIBS="$LDADD_LIBNTP $LIBS"
26005	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26006/* end confdefs.h.  */
26007$ac_includes_default
26008		    #include <sys/socket.h>
26009		    #include <netinet/in.h>
26010		    $isc_netinetin6_hack
26011		    $isc_netinet6in6_hack
26012
26013int
26014main ()
26015{
26016
26017		    printf("%x", in6addr_any.s6_addr[15]);
26018
26019
26020  ;
26021  return 0;
26022}
26023_ACEOF
26024if ac_fn_c_try_link "$LINENO"; then :
26025  isc_cv_in6addr_any_links=yes
26026else
26027  isc_cv_in6addr_any_links=no
26028
26029fi
26030rm -f core conftest.err conftest.$ac_objext \
26031    conftest$ac_exeext conftest.$ac_ext
26032	LIBS="$SAVED_LIBS"
26033	{ SAVED_LIBS=; unset SAVED_LIBS;}
26034
26035
26036fi
26037{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_in6addr_any_links" >&5
26038$as_echo "$isc_cv_in6addr_any_links" >&6; }
26039
26040case "$isc_cv_in6addr_any_links" in
26041 no)
26042
26043$as_echo "#define ISC_PLATFORM_NEEDIN6ADDRANY 1" >>confdefs.h
26044
26045esac
26046
26047
26048{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct if_laddrconf" >&5
26049$as_echo_n "checking for struct if_laddrconf... " >&6; }
26050if ${isc_cv_struct_if_laddrconf+:} false; then :
26051  $as_echo_n "(cached) " >&6
26052else
26053  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26054/* end confdefs.h.  */
26055
26056		#include <sys/types.h>
26057		#include <net/if6.h>
26058
26059int
26060main ()
26061{
26062
26063		struct if_laddrconf a;
26064
26065
26066  ;
26067  return 0;
26068}
26069_ACEOF
26070if ac_fn_c_try_compile "$LINENO"; then :
26071  isc_cv_struct_if_laddrconf=yes
26072else
26073  isc_cv_struct_if_laddrconf=no
26074
26075fi
26076rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26077
26078fi
26079{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_struct_if_laddrconf" >&5
26080$as_echo "$isc_cv_struct_if_laddrconf" >&6; }
26081
26082case "$isc_cv_struct_if_laddrconf" in
26083 yes)
26084
26085$as_echo "#define ISC_PLATFORM_HAVEIF_LADDRCONF 1" >>confdefs.h
26086
26087esac
26088
26089{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct if_laddrreq" >&5
26090$as_echo_n "checking for struct if_laddrreq... " >&6; }
26091if ${isc_cv_struct_if_laddrreq+:} false; then :
26092  $as_echo_n "(cached) " >&6
26093else
26094  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26095/* end confdefs.h.  */
26096
26097		#include <sys/types.h>
26098		#include <net/if6.h>
26099
26100int
26101main ()
26102{
26103
26104		struct if_laddrreq a;
26105
26106
26107  ;
26108  return 0;
26109}
26110_ACEOF
26111if ac_fn_c_try_compile "$LINENO"; then :
26112  isc_cv_struct_if_laddrreq=yes
26113else
26114  isc_cv_struct_if_laddrreq=no
26115
26116fi
26117rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26118
26119fi
26120{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_struct_if_laddrreq" >&5
26121$as_echo "$isc_cv_struct_if_laddrreq" >&6; }
26122
26123case "$isc_cv_struct_if_laddrreq" in
26124 yes)
26125
26126$as_echo "#define ISC_PLATFORM_HAVEIF_LADDRREQ 1" >>confdefs.h
26127
26128esac
26129
26130{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for multicast IP support" >&5
26131$as_echo_n "checking for multicast IP support... " >&6; }
26132if ${ntp_cv_multicast+:} false; then :
26133  $as_echo_n "(cached) " >&6
26134else
26135
26136	ntp_cv_multicast=no
26137	case "$host" in
26138	 i386-sequent-sysv4)
26139	    ;;
26140	 *)
26141	    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26142/* end confdefs.h.  */
26143
26144			#ifdef HAVE_NETINET_IN_H
26145			# include <netinet/in.h>
26146			#endif
26147
26148int
26149main ()
26150{
26151
26152			struct ip_mreq ipmr;
26153			ipmr.imr_interface.s_addr = 0;
26154
26155
26156  ;
26157  return 0;
26158}
26159_ACEOF
26160if ac_fn_c_try_compile "$LINENO"; then :
26161  ntp_cv_multicast=yes
26162fi
26163rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26164	    ;;
26165	esac
26166
26167
26168fi
26169{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_multicast" >&5
26170$as_echo "$ntp_cv_multicast" >&6; }
26171case "$ntp_cv_multicast" in
26172 yes)
26173
26174$as_echo "#define MCAST 1" >>confdefs.h
26175
26176    { $as_echo "$as_me:${as_lineno-$LINENO}: checking arg type needed for setsockopt() IP*_MULTICAST_LOOP" >&5
26177$as_echo_n "checking arg type needed for setsockopt() IP*_MULTICAST_LOOP... " >&6; }
26178if ${ntp_cv_typeof_ip_multicast_loop+:} false; then :
26179  $as_echo_n "(cached) " >&6
26180else
26181
26182	    case "$host" in
26183	     *-*-netbsd*|*-*-*linux*)
26184		ntp_cv_typeof_ip_multicast_loop=u_int
26185		;;
26186	     *)
26187		ntp_cv_typeof_ip_multicast_loop=u_char
26188		;;
26189	    esac
26190
26191
26192fi
26193{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_typeof_ip_multicast_loop" >&5
26194$as_echo "$ntp_cv_typeof_ip_multicast_loop" >&6; }
26195
26196cat >>confdefs.h <<_ACEOF
26197#define TYPEOF_IP_MULTICAST_LOOP $ntp_cv_typeof_ip_multicast_loop
26198_ACEOF
26199
26200esac
26201
26202# Check whether --enable-getifaddrs was given.
26203if test "${enable_getifaddrs+set}" = set; then :
26204  enableval=$enable_getifaddrs; want_getifaddrs="$enableval"
26205else
26206  want_getifaddrs="yes"
26207
26208fi
26209
26210
26211case $want_getifaddrs in
26212 glibc)
26213    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --enable-getifaddrs=glibc is no longer required" >&5
26214$as_echo "$as_me: WARNING: --enable-getifaddrs=glibc is no longer required" >&2;}
26215esac
26216case $want_getifaddrs in
26217 no)
26218    ;;
26219 *)
26220    SAVED_LIBS="$LIBS"
26221    LIBS="$LDADD_LIBNTP $LIBS"
26222    for ac_func in getifaddrs
26223do :
26224  ac_fn_c_check_func "$LINENO" "getifaddrs" "ac_cv_func_getifaddrs"
26225if test "x$ac_cv_func_getifaddrs" = xyes; then :
26226  cat >>confdefs.h <<_ACEOF
26227#define HAVE_GETIFADDRS 1
26228_ACEOF
26229
26230fi
26231done
26232
26233    LIBS="$SAVED_LIBS"
26234    { SAVED_LIBS=; unset SAVED_LIBS;}
26235    ;;
26236esac
26237
26238#
26239# Check for if_nametoindex() for IPv6 scoped addresses support
26240#
26241case "$host" in
26242 *-hp-hpux*)
26243    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing if_nametoindex" >&5
26244$as_echo_n "checking for library containing if_nametoindex... " >&6; }
26245if ${ac_cv_search_if_nametoindex+:} false; then :
26246  $as_echo_n "(cached) " >&6
26247else
26248  ac_func_search_save_LIBS=$LIBS
26249cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26250/* end confdefs.h.  */
26251
26252/* Override any GCC internal prototype to avoid an error.
26253   Use char because int might match the return type of a GCC
26254   builtin and then its argument prototype would still apply.  */
26255#ifdef __cplusplus
26256extern "C"
26257#endif
26258char if_nametoindex ();
26259int
26260main ()
26261{
26262return if_nametoindex ();
26263  ;
26264  return 0;
26265}
26266_ACEOF
26267for ac_lib in '' ipv6; do
26268  if test -z "$ac_lib"; then
26269    ac_res="none required"
26270  else
26271    ac_res=-l$ac_lib
26272    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
26273  fi
26274  if ac_fn_c_try_link "$LINENO"; then :
26275  ac_cv_search_if_nametoindex=$ac_res
26276fi
26277rm -f core conftest.err conftest.$ac_objext \
26278    conftest$ac_exeext
26279  if ${ac_cv_search_if_nametoindex+:} false; then :
26280  break
26281fi
26282done
26283if ${ac_cv_search_if_nametoindex+:} false; then :
26284
26285else
26286  ac_cv_search_if_nametoindex=no
26287fi
26288rm conftest.$ac_ext
26289LIBS=$ac_func_search_save_LIBS
26290fi
26291{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_if_nametoindex" >&5
26292$as_echo "$ac_cv_search_if_nametoindex" >&6; }
26293ac_res=$ac_cv_search_if_nametoindex
26294if test "$ac_res" != no; then :
26295  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
26296
26297fi
26298
26299esac
26300SAVED_LIBS="$LIBS"
26301LIBS="$LDADD_LIBNTP $LIBS"
26302for ac_func in if_nametoindex
26303do :
26304  ac_fn_c_check_func "$LINENO" "if_nametoindex" "ac_cv_func_if_nametoindex"
26305if test "x$ac_cv_func_if_nametoindex" = xyes; then :
26306  cat >>confdefs.h <<_ACEOF
26307#define HAVE_IF_NAMETOINDEX 1
26308_ACEOF
26309
26310fi
26311done
26312
26313LIBS="$SAVED_LIBS"
26314{ SAVED_LIBS=; unset SAVED_LIBS;}
26315case "$ac_cv_func_if_nametoindex" in
26316 yes)
26317
26318$as_echo "#define ISC_PLATFORM_HAVEIFNAMETOINDEX 1" >>confdefs.h
26319
26320esac
26321
26322
26323
26324###
26325
26326# Hacks
26327# these need work if we're to move libntp under sntp
26328
26329$as_echo "#define HAVE_NO_NICE 1" >>confdefs.h
26330
26331
26332$as_echo "#define HAVE_TERMIOS 1" >>confdefs.h
26333
26334
26335# Checks for library functions.
26336for ac_func in socket
26337do :
26338  ac_fn_c_check_func "$LINENO" "socket" "ac_cv_func_socket"
26339if test "x$ac_cv_func_socket" = xyes; then :
26340  cat >>confdefs.h <<_ACEOF
26341#define HAVE_SOCKET 1
26342_ACEOF
26343
26344fi
26345done
26346
26347
26348
26349# We may not need have_unity
26350have_unity=false
26351# Extract the first word of "ruby", so it can be a program name with args.
26352set dummy ruby; ac_word=$2
26353{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
26354$as_echo_n "checking for $ac_word... " >&6; }
26355if ${ac_cv_path_PATH_RUBY+:} false; then :
26356  $as_echo_n "(cached) " >&6
26357else
26358  case $PATH_RUBY in
26359  [\\/]* | ?:[\\/]*)
26360  ac_cv_path_PATH_RUBY="$PATH_RUBY" # Let the user override the test with a path.
26361  ;;
26362  *)
26363  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26364for as_dir in $PATH
26365do
26366  IFS=$as_save_IFS
26367  test -z "$as_dir" && as_dir=.
26368    for ac_exec_ext in '' $ac_executable_extensions; do
26369  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
26370    ac_cv_path_PATH_RUBY="$as_dir/$ac_word$ac_exec_ext"
26371    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
26372    break 2
26373  fi
26374done
26375  done
26376IFS=$as_save_IFS
26377
26378  ;;
26379esac
26380fi
26381PATH_RUBY=$ac_cv_path_PATH_RUBY
26382if test -n "$PATH_RUBY"; then
26383  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATH_RUBY" >&5
26384$as_echo "$PATH_RUBY" >&6; }
26385else
26386  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26387$as_echo "no" >&6; }
26388fi
26389
26390
26391case "$PATH_RUBY" in
26392 /*)
26393    have_unity=true
26394    ;;
26395 *) PATH_RUBY="false"
26396    ;;
26397esac
26398# We may not need UNITYBUILD_AVAILABLE
26399 if $have_unity; then
26400  UNITYBUILD_AVAILABLE_TRUE=
26401  UNITYBUILD_AVAILABLE_FALSE='#'
26402else
26403  UNITYBUILD_AVAILABLE_TRUE='#'
26404  UNITYBUILD_AVAILABLE_FALSE=
26405fi
26406
26407
26408
26409## HMS: if we don't find c++ we should not look for gtest.
26410#AC_PROG_CXX
26411#NTP_GOOGLETEST
26412
26413
26414case "$build" in
26415 $host)	cross=0 ;;
26416 *)	cross=1 ;;
26417esac
26418
26419{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want to enable tests with undiagnosed problems" >&5
26420$as_echo_n "checking if we want to enable tests with undiagnosed problems... " >&6; }
26421# Check whether --enable-problem-tests was given.
26422if test "${enable_problem_tests+set}" = set; then :
26423  enableval=$enable_problem_tests; sntp_ept=$enableval
26424else
26425  sntp_ept=yes
26426
26427fi
26428
26429{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $sntp_ept" >&5
26430$as_echo "$sntp_ept" >&6; }
26431
26432{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can run test-kodDatabase" >&5
26433$as_echo_n "checking if we can run test-kodDatabase... " >&6; }
26434sntp_test_kodDatabase="no"
26435case "$sntp_ept:$cross:$host" in
26436 no:0:*-apple-darwin12.6.0) ;;
26437 *) sntp_test_kodDatabase="yes" ;;
26438esac
26439{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $sntp_test_kodDatabase" >&5
26440$as_echo "$sntp_test_kodDatabase" >&6; }
26441 if test x$sntp_test_kodDatabase = xyes; then
26442  BUILD_TEST_KODDATABASE_TRUE=
26443  BUILD_TEST_KODDATABASE_FALSE='#'
26444else
26445  BUILD_TEST_KODDATABASE_TRUE='#'
26446  BUILD_TEST_KODDATABASE_FALSE=
26447fi
26448
26449
26450{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can run test-kodFile" >&5
26451$as_echo_n "checking if we can run test-kodFile... " >&6; }
26452sntp_test_kodFile="no"
26453case "$sntp_ept:$cross:$host" in
26454 no:0:*-apple-darwin12.6.0) ;;
26455 *) sntp_test_kodFile="yes" ;;
26456esac
26457{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $sntp_test_kodFile" >&5
26458$as_echo "$sntp_test_kodFile" >&6; }
26459 if test x$sntp_test_kodFile = xyes; then
26460  BUILD_TEST_KODFILE_TRUE=
26461  BUILD_TEST_KODFILE_FALSE='#'
26462else
26463  BUILD_TEST_KODFILE_TRUE='#'
26464  BUILD_TEST_KODFILE_FALSE=
26465fi
26466
26467
26468
26469
26470# All libraries should be in various LIB_* variables now.
26471#LIBS=
26472# Sadly not.  There is a gettext() check somewhere, and on Solaris this pulls
26473# in -lintl -lgen, outside our "scope".
26474
26475ac_config_files="$ac_config_files Makefile"
26476
26477ac_config_files="$ac_config_files include/Makefile"
26478
26479ac_config_files="$ac_config_files scripts/Makefile"
26480
26481ac_config_files="$ac_config_files tests/Makefile"
26482
26483ac_config_files="$ac_config_files tests/fileHandlingTest.h"
26484
26485ac_config_files="$ac_config_files unity/Makefile"
26486
26487
26488cat >confcache <<\_ACEOF
26489# This file is a shell script that caches the results of configure
26490# tests run on this system so they can be shared between configure
26491# scripts and configure runs, see configure's option --config-cache.
26492# It is not useful on other systems.  If it contains results you don't
26493# want to keep, you may remove or edit it.
26494#
26495# config.status only pays attention to the cache file if you give it
26496# the --recheck option to rerun configure.
26497#
26498# `ac_cv_env_foo' variables (set or unset) will be overridden when
26499# loading this file, other *unset* `ac_cv_foo' will be assigned the
26500# following values.
26501
26502_ACEOF
26503
26504# The following way of writing the cache mishandles newlines in values,
26505# but we know of no workaround that is simple, portable, and efficient.
26506# So, we kill variables containing newlines.
26507# Ultrix sh set writes to stderr and can't be redirected directly,
26508# and sets the high bit in the cache file unless we assign to the vars.
26509(
26510  for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
26511    eval ac_val=\$$ac_var
26512    case $ac_val in #(
26513    *${as_nl}*)
26514      case $ac_var in #(
26515      *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
26516$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
26517      esac
26518      case $ac_var in #(
26519      _ | IFS | as_nl) ;; #(
26520      BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
26521      *) { eval $ac_var=; unset $ac_var;} ;;
26522      esac ;;
26523    esac
26524  done
26525
26526  (set) 2>&1 |
26527    case $as_nl`(ac_space=' '; set) 2>&1` in #(
26528    *${as_nl}ac_space=\ *)
26529      # `set' does not quote correctly, so add quotes: double-quote
26530      # substitution turns \\\\ into \\, and sed turns \\ into \.
26531      sed -n \
26532	"s/'/'\\\\''/g;
26533	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
26534      ;; #(
26535    *)
26536      # `set' quotes correctly as required by POSIX, so do not add quotes.
26537      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
26538      ;;
26539    esac |
26540    sort
26541) |
26542  sed '
26543     /^ac_cv_env_/b end
26544     t clear
26545     :clear
26546     s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
26547     t end
26548     s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
26549     :end' >>confcache
26550if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
26551  if test -w "$cache_file"; then
26552    if test "x$cache_file" != "x/dev/null"; then
26553      { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
26554$as_echo "$as_me: updating cache $cache_file" >&6;}
26555      if test ! -f "$cache_file" || test -h "$cache_file"; then
26556	cat confcache >"$cache_file"
26557      else
26558        case $cache_file in #(
26559        */* | ?:*)
26560	  mv -f confcache "$cache_file"$$ &&
26561	  mv -f "$cache_file"$$ "$cache_file" ;; #(
26562        *)
26563	  mv -f confcache "$cache_file" ;;
26564	esac
26565      fi
26566    fi
26567  else
26568    { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
26569$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
26570  fi
26571fi
26572rm -f confcache
26573
26574test "x$prefix" = xNONE && prefix=$ac_default_prefix
26575# Let make expand exec_prefix.
26576test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
26577
26578DEFS=-DHAVE_CONFIG_H
26579
26580ac_libobjs=
26581ac_ltlibobjs=
26582U=
26583for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
26584  # 1. Remove the extension, and $U if already installed.
26585  ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
26586  ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
26587  # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
26588  #    will be set to the directory where LIBOBJS objects are built.
26589  as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
26590  as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
26591done
26592LIBOBJS=$ac_libobjs
26593
26594LTLIBOBJS=$ac_ltlibobjs
26595
26596
26597{ $as_echo "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5
26598$as_echo_n "checking that generated files are newer than configure... " >&6; }
26599   if test -n "$am_sleep_pid"; then
26600     # Hide warnings about reused PIDs.
26601     wait $am_sleep_pid 2>/dev/null
26602   fi
26603   { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5
26604$as_echo "done" >&6; }
26605 if test -n "$EXEEXT"; then
26606  am__EXEEXT_TRUE=
26607  am__EXEEXT_FALSE='#'
26608else
26609  am__EXEEXT_TRUE='#'
26610  am__EXEEXT_FALSE=
26611fi
26612
26613if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
26614  as_fn_error $? "conditional \"AMDEP\" was never defined.
26615Usually this means the macro was only invoked conditionally." "$LINENO" 5
26616fi
26617if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
26618  as_fn_error $? "conditional \"am__fastdepCC\" was never defined.
26619Usually this means the macro was only invoked conditionally." "$LINENO" 5
26620fi
26621
26622if test -z "${WANT_CALC_TICKADJ_MS_TRUE}" && test -z "${WANT_CALC_TICKADJ_MS_FALSE}"; then
26623  as_fn_error $? "conditional \"WANT_CALC_TICKADJ_MS\" was never defined.
26624Usually this means the macro was only invoked conditionally." "$LINENO" 5
26625fi
26626if test -z "${INSTALL_NTPSWEEP_TRUE}" && test -z "${INSTALL_NTPSWEEP_FALSE}"; then
26627  as_fn_error $? "conditional \"INSTALL_NTPSWEEP\" was never defined.
26628Usually this means the macro was only invoked conditionally." "$LINENO" 5
26629fi
26630if test -z "${INSTALL_UPDATE_LEAP_TRUE}" && test -z "${INSTALL_UPDATE_LEAP_FALSE}"; then
26631  as_fn_error $? "conditional \"INSTALL_UPDATE_LEAP\" was never defined.
26632Usually this means the macro was only invoked conditionally." "$LINENO" 5
26633fi
26634if test -z "${NTP_CROSSCOMPILE_TRUE}" && test -z "${NTP_CROSSCOMPILE_FALSE}"; then
26635  as_fn_error $? "conditional \"NTP_CROSSCOMPILE\" was never defined.
26636Usually this means the macro was only invoked conditionally." "$LINENO" 5
26637fi
26638if test -z "${PTHREADS_TRUE}" && test -z "${PTHREADS_FALSE}"; then
26639  as_fn_error $? "conditional \"PTHREADS\" was never defined.
26640Usually this means the macro was only invoked conditionally." "$LINENO" 5
26641fi
26642if test -z "${BUILD_SNTP_TRUE}" && test -z "${BUILD_SNTP_FALSE}"; then
26643  as_fn_error $? "conditional \"BUILD_SNTP\" was never defined.
26644Usually this means the macro was only invoked conditionally." "$LINENO" 5
26645fi
26646if test -z "${GL_GENERATE_STDNORETURN_H_TRUE}" && test -z "${GL_GENERATE_STDNORETURN_H_FALSE}"; then
26647  as_fn_error $? "conditional \"GL_GENERATE_STDNORETURN_H\" was never defined.
26648Usually this means the macro was only invoked conditionally." "$LINENO" 5
26649fi
26650if test -z "${INSTALL_LIBOPTS_TRUE}" && test -z "${INSTALL_LIBOPTS_FALSE}"; then
26651  as_fn_error $? "conditional \"INSTALL_LIBOPTS\" was never defined.
26652Usually this means the macro was only invoked conditionally." "$LINENO" 5
26653fi
26654if test -z "${NEED_LIBOPTS_TRUE}" && test -z "${NEED_LIBOPTS_FALSE}"; then
26655  as_fn_error $? "conditional \"NEED_LIBOPTS\" was never defined.
26656Usually this means the macro was only invoked conditionally." "$LINENO" 5
26657fi
26658if test -z "${BUILD_LIBEVENT_TRUE}" && test -z "${BUILD_LIBEVENT_FALSE}"; then
26659  as_fn_error $? "conditional \"BUILD_LIBEVENT\" was never defined.
26660Usually this means the macro was only invoked conditionally." "$LINENO" 5
26661fi
26662if test -z "${UNITYBUILD_AVAILABLE_TRUE}" && test -z "${UNITYBUILD_AVAILABLE_FALSE}"; then
26663  as_fn_error $? "conditional \"UNITYBUILD_AVAILABLE\" was never defined.
26664Usually this means the macro was only invoked conditionally." "$LINENO" 5
26665fi
26666if test -z "${BUILD_TEST_KODDATABASE_TRUE}" && test -z "${BUILD_TEST_KODDATABASE_FALSE}"; then
26667  as_fn_error $? "conditional \"BUILD_TEST_KODDATABASE\" was never defined.
26668Usually this means the macro was only invoked conditionally." "$LINENO" 5
26669fi
26670if test -z "${BUILD_TEST_KODFILE_TRUE}" && test -z "${BUILD_TEST_KODFILE_FALSE}"; then
26671  as_fn_error $? "conditional \"BUILD_TEST_KODFILE\" was never defined.
26672Usually this means the macro was only invoked conditionally." "$LINENO" 5
26673fi
26674
26675: "${CONFIG_STATUS=./config.status}"
26676ac_write_fail=0
26677ac_clean_files_save=$ac_clean_files
26678ac_clean_files="$ac_clean_files $CONFIG_STATUS"
26679{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
26680$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
26681as_write_fail=0
26682cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
26683#! $SHELL
26684# Generated by $as_me.
26685# Run this file to recreate the current configuration.
26686# Compiler output produced by configure, useful for debugging
26687# configure, is in config.log if it exists.
26688
26689debug=false
26690ac_cs_recheck=false
26691ac_cs_silent=false
26692
26693SHELL=\${CONFIG_SHELL-$SHELL}
26694export SHELL
26695_ASEOF
26696cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
26697## -------------------- ##
26698## M4sh Initialization. ##
26699## -------------------- ##
26700
26701# Be more Bourne compatible
26702DUALCASE=1; export DUALCASE # for MKS sh
26703if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
26704  emulate sh
26705  NULLCMD=:
26706  # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
26707  # is contrary to our usage.  Disable this feature.
26708  alias -g '${1+"$@"}'='"$@"'
26709  setopt NO_GLOB_SUBST
26710else
26711  case `(set -o) 2>/dev/null` in #(
26712  *posix*) :
26713    set -o posix ;; #(
26714  *) :
26715     ;;
26716esac
26717fi
26718
26719
26720as_nl='
26721'
26722export as_nl
26723# Printing a long string crashes Solaris 7 /usr/bin/printf.
26724as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
26725as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
26726as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
26727# Prefer a ksh shell builtin over an external printf program on Solaris,
26728# but without wasting forks for bash or zsh.
26729if test -z "$BASH_VERSION$ZSH_VERSION" \
26730    && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
26731  as_echo='print -r --'
26732  as_echo_n='print -rn --'
26733elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
26734  as_echo='printf %s\n'
26735  as_echo_n='printf %s'
26736else
26737  if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
26738    as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
26739    as_echo_n='/usr/ucb/echo -n'
26740  else
26741    as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
26742    as_echo_n_body='eval
26743      arg=$1;
26744      case $arg in #(
26745      *"$as_nl"*)
26746	expr "X$arg" : "X\\(.*\\)$as_nl";
26747	arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
26748      esac;
26749      expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
26750    '
26751    export as_echo_n_body
26752    as_echo_n='sh -c $as_echo_n_body as_echo'
26753  fi
26754  export as_echo_body
26755  as_echo='sh -c $as_echo_body as_echo'
26756fi
26757
26758# The user is always right.
26759if test "${PATH_SEPARATOR+set}" != set; then
26760  PATH_SEPARATOR=:
26761  (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
26762    (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
26763      PATH_SEPARATOR=';'
26764  }
26765fi
26766
26767
26768# IFS
26769# We need space, tab and new line, in precisely that order.  Quoting is
26770# there to prevent editors from complaining about space-tab.
26771# (If _AS_PATH_WALK were called with IFS unset, it would disable word
26772# splitting by setting IFS to empty value.)
26773IFS=" ""	$as_nl"
26774
26775# Find who we are.  Look in the path if we contain no directory separator.
26776as_myself=
26777case $0 in #((
26778  *[\\/]* ) as_myself=$0 ;;
26779  *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26780for as_dir in $PATH
26781do
26782  IFS=$as_save_IFS
26783  test -z "$as_dir" && as_dir=.
26784    test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
26785  done
26786IFS=$as_save_IFS
26787
26788     ;;
26789esac
26790# We did not find ourselves, most probably we were run as `sh COMMAND'
26791# in which case we are not to be found in the path.
26792if test "x$as_myself" = x; then
26793  as_myself=$0
26794fi
26795if test ! -f "$as_myself"; then
26796  $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
26797  exit 1
26798fi
26799
26800# Unset variables that we do not need and which cause bugs (e.g. in
26801# pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
26802# suppresses any "Segmentation fault" message there.  '((' could
26803# trigger a bug in pdksh 5.2.14.
26804for as_var in BASH_ENV ENV MAIL MAILPATH
26805do eval test x\${$as_var+set} = xset \
26806  && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
26807done
26808PS1='$ '
26809PS2='> '
26810PS4='+ '
26811
26812# NLS nuisances.
26813LC_ALL=C
26814export LC_ALL
26815LANGUAGE=C
26816export LANGUAGE
26817
26818# CDPATH.
26819(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
26820
26821
26822# as_fn_error STATUS ERROR [LINENO LOG_FD]
26823# ----------------------------------------
26824# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
26825# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
26826# script with STATUS, using 1 if that was 0.
26827as_fn_error ()
26828{
26829  as_status=$1; test $as_status -eq 0 && as_status=1
26830  if test "$4"; then
26831    as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
26832    $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
26833  fi
26834  $as_echo "$as_me: error: $2" >&2
26835  as_fn_exit $as_status
26836} # as_fn_error
26837
26838
26839# as_fn_set_status STATUS
26840# -----------------------
26841# Set $? to STATUS, without forking.
26842as_fn_set_status ()
26843{
26844  return $1
26845} # as_fn_set_status
26846
26847# as_fn_exit STATUS
26848# -----------------
26849# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
26850as_fn_exit ()
26851{
26852  set +e
26853  as_fn_set_status $1
26854  exit $1
26855} # as_fn_exit
26856
26857# as_fn_unset VAR
26858# ---------------
26859# Portably unset VAR.
26860as_fn_unset ()
26861{
26862  { eval $1=; unset $1;}
26863}
26864as_unset=as_fn_unset
26865# as_fn_append VAR VALUE
26866# ----------------------
26867# Append the text in VALUE to the end of the definition contained in VAR. Take
26868# advantage of any shell optimizations that allow amortized linear growth over
26869# repeated appends, instead of the typical quadratic growth present in naive
26870# implementations.
26871if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
26872  eval 'as_fn_append ()
26873  {
26874    eval $1+=\$2
26875  }'
26876else
26877  as_fn_append ()
26878  {
26879    eval $1=\$$1\$2
26880  }
26881fi # as_fn_append
26882
26883# as_fn_arith ARG...
26884# ------------------
26885# Perform arithmetic evaluation on the ARGs, and store the result in the
26886# global $as_val. Take advantage of shells that can avoid forks. The arguments
26887# must be portable across $(()) and expr.
26888if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
26889  eval 'as_fn_arith ()
26890  {
26891    as_val=$(( $* ))
26892  }'
26893else
26894  as_fn_arith ()
26895  {
26896    as_val=`expr "$@" || test $? -eq 1`
26897  }
26898fi # as_fn_arith
26899
26900
26901if expr a : '\(a\)' >/dev/null 2>&1 &&
26902   test "X`expr 00001 : '.*\(...\)'`" = X001; then
26903  as_expr=expr
26904else
26905  as_expr=false
26906fi
26907
26908if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
26909  as_basename=basename
26910else
26911  as_basename=false
26912fi
26913
26914if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
26915  as_dirname=dirname
26916else
26917  as_dirname=false
26918fi
26919
26920as_me=`$as_basename -- "$0" ||
26921$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
26922	 X"$0" : 'X\(//\)$' \| \
26923	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
26924$as_echo X/"$0" |
26925    sed '/^.*\/\([^/][^/]*\)\/*$/{
26926	    s//\1/
26927	    q
26928	  }
26929	  /^X\/\(\/\/\)$/{
26930	    s//\1/
26931	    q
26932	  }
26933	  /^X\/\(\/\).*/{
26934	    s//\1/
26935	    q
26936	  }
26937	  s/.*/./; q'`
26938
26939# Avoid depending upon Character Ranges.
26940as_cr_letters='abcdefghijklmnopqrstuvwxyz'
26941as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
26942as_cr_Letters=$as_cr_letters$as_cr_LETTERS
26943as_cr_digits='0123456789'
26944as_cr_alnum=$as_cr_Letters$as_cr_digits
26945
26946ECHO_C= ECHO_N= ECHO_T=
26947case `echo -n x` in #(((((
26948-n*)
26949  case `echo 'xy\c'` in
26950  *c*) ECHO_T='	';;	# ECHO_T is single tab character.
26951  xy)  ECHO_C='\c';;
26952  *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
26953       ECHO_T='	';;
26954  esac;;
26955*)
26956  ECHO_N='-n';;
26957esac
26958
26959rm -f conf$$ conf$$.exe conf$$.file
26960if test -d conf$$.dir; then
26961  rm -f conf$$.dir/conf$$.file
26962else
26963  rm -f conf$$.dir
26964  mkdir conf$$.dir 2>/dev/null
26965fi
26966if (echo >conf$$.file) 2>/dev/null; then
26967  if ln -s conf$$.file conf$$ 2>/dev/null; then
26968    as_ln_s='ln -s'
26969    # ... but there are two gotchas:
26970    # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
26971    # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
26972    # In both cases, we have to default to `cp -pR'.
26973    ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
26974      as_ln_s='cp -pR'
26975  elif ln conf$$.file conf$$ 2>/dev/null; then
26976    as_ln_s=ln
26977  else
26978    as_ln_s='cp -pR'
26979  fi
26980else
26981  as_ln_s='cp -pR'
26982fi
26983rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
26984rmdir conf$$.dir 2>/dev/null
26985
26986
26987# as_fn_mkdir_p
26988# -------------
26989# Create "$as_dir" as a directory, including parents if necessary.
26990as_fn_mkdir_p ()
26991{
26992
26993  case $as_dir in #(
26994  -*) as_dir=./$as_dir;;
26995  esac
26996  test -d "$as_dir" || eval $as_mkdir_p || {
26997    as_dirs=
26998    while :; do
26999      case $as_dir in #(
27000      *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
27001      *) as_qdir=$as_dir;;
27002      esac
27003      as_dirs="'$as_qdir' $as_dirs"
27004      as_dir=`$as_dirname -- "$as_dir" ||
27005$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
27006	 X"$as_dir" : 'X\(//\)[^/]' \| \
27007	 X"$as_dir" : 'X\(//\)$' \| \
27008	 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
27009$as_echo X"$as_dir" |
27010    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
27011	    s//\1/
27012	    q
27013	  }
27014	  /^X\(\/\/\)[^/].*/{
27015	    s//\1/
27016	    q
27017	  }
27018	  /^X\(\/\/\)$/{
27019	    s//\1/
27020	    q
27021	  }
27022	  /^X\(\/\).*/{
27023	    s//\1/
27024	    q
27025	  }
27026	  s/.*/./; q'`
27027      test -d "$as_dir" && break
27028    done
27029    test -z "$as_dirs" || eval "mkdir $as_dirs"
27030  } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
27031
27032
27033} # as_fn_mkdir_p
27034if mkdir -p . 2>/dev/null; then
27035  as_mkdir_p='mkdir -p "$as_dir"'
27036else
27037  test -d ./-p && rmdir ./-p
27038  as_mkdir_p=false
27039fi
27040
27041
27042# as_fn_executable_p FILE
27043# -----------------------
27044# Test if FILE is an executable regular file.
27045as_fn_executable_p ()
27046{
27047  test -f "$1" && test -x "$1"
27048} # as_fn_executable_p
27049as_test_x='test -x'
27050as_executable_p=as_fn_executable_p
27051
27052# Sed expression to map a string onto a valid CPP name.
27053as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
27054
27055# Sed expression to map a string onto a valid variable name.
27056as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
27057
27058
27059exec 6>&1
27060## ----------------------------------- ##
27061## Main body of $CONFIG_STATUS script. ##
27062## ----------------------------------- ##
27063_ASEOF
27064test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
27065
27066cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
27067# Save the log message, to keep $0 and so on meaningful, and to
27068# report actual input values of CONFIG_FILES etc. instead of their
27069# values after options handling.
27070ac_log="
27071This file was extended by sntp $as_me 4.2.8p10, which was
27072generated by GNU Autoconf 2.69.  Invocation command line was
27073
27074  CONFIG_FILES    = $CONFIG_FILES
27075  CONFIG_HEADERS  = $CONFIG_HEADERS
27076  CONFIG_LINKS    = $CONFIG_LINKS
27077  CONFIG_COMMANDS = $CONFIG_COMMANDS
27078  $ $0 $@
27079
27080on `(hostname || uname -n) 2>/dev/null | sed 1q`
27081"
27082
27083_ACEOF
27084
27085case $ac_config_files in *"
27086"*) set x $ac_config_files; shift; ac_config_files=$*;;
27087esac
27088
27089case $ac_config_headers in *"
27090"*) set x $ac_config_headers; shift; ac_config_headers=$*;;
27091esac
27092
27093
27094cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
27095# Files that config.status was made for.
27096config_files="$ac_config_files"
27097config_headers="$ac_config_headers"
27098config_commands="$ac_config_commands"
27099
27100_ACEOF
27101
27102cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
27103ac_cs_usage="\
27104\`$as_me' instantiates files and other configuration actions
27105from templates according to the current configuration.  Unless the files
27106and actions are specified as TAGs, all are instantiated by default.
27107
27108Usage: $0 [OPTION]... [TAG]...
27109
27110  -h, --help       print this help, then exit
27111  -V, --version    print version number and configuration settings, then exit
27112      --config     print configuration, then exit
27113  -q, --quiet, --silent
27114                   do not print progress messages
27115  -d, --debug      don't remove temporary files
27116      --recheck    update $as_me by reconfiguring in the same conditions
27117      --file=FILE[:TEMPLATE]
27118                   instantiate the configuration file FILE
27119      --header=FILE[:TEMPLATE]
27120                   instantiate the configuration header FILE
27121
27122Configuration files:
27123$config_files
27124
27125Configuration headers:
27126$config_headers
27127
27128Configuration commands:
27129$config_commands
27130
27131Report bugs to <http://bugs.ntp.org./>.
27132sntp home page: <http://www.ntp.org./>."
27133
27134_ACEOF
27135cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
27136ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
27137ac_cs_version="\\
27138sntp config.status 4.2.8p10
27139configured by $0, generated by GNU Autoconf 2.69,
27140  with options \\"\$ac_cs_config\\"
27141
27142Copyright (C) 2012 Free Software Foundation, Inc.
27143This config.status script is free software; the Free Software Foundation
27144gives unlimited permission to copy, distribute and modify it."
27145
27146ac_pwd='$ac_pwd'
27147srcdir='$srcdir'
27148INSTALL='$INSTALL'
27149MKDIR_P='$MKDIR_P'
27150AWK='$AWK'
27151test -n "\$AWK" || AWK=awk
27152_ACEOF
27153
27154cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
27155# The default lists apply if the user does not specify any file.
27156ac_need_defaults=:
27157while test $# != 0
27158do
27159  case $1 in
27160  --*=?*)
27161    ac_option=`expr "X$1" : 'X\([^=]*\)='`
27162    ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
27163    ac_shift=:
27164    ;;
27165  --*=)
27166    ac_option=`expr "X$1" : 'X\([^=]*\)='`
27167    ac_optarg=
27168    ac_shift=:
27169    ;;
27170  *)
27171    ac_option=$1
27172    ac_optarg=$2
27173    ac_shift=shift
27174    ;;
27175  esac
27176
27177  case $ac_option in
27178  # Handling of the options.
27179  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
27180    ac_cs_recheck=: ;;
27181  --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
27182    $as_echo "$ac_cs_version"; exit ;;
27183  --config | --confi | --conf | --con | --co | --c )
27184    $as_echo "$ac_cs_config"; exit ;;
27185  --debug | --debu | --deb | --de | --d | -d )
27186    debug=: ;;
27187  --file | --fil | --fi | --f )
27188    $ac_shift
27189    case $ac_optarg in
27190    *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
27191    '') as_fn_error $? "missing file argument" ;;
27192    esac
27193    as_fn_append CONFIG_FILES " '$ac_optarg'"
27194    ac_need_defaults=false;;
27195  --header | --heade | --head | --hea )
27196    $ac_shift
27197    case $ac_optarg in
27198    *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
27199    esac
27200    as_fn_append CONFIG_HEADERS " '$ac_optarg'"
27201    ac_need_defaults=false;;
27202  --he | --h)
27203    # Conflict between --help and --header
27204    as_fn_error $? "ambiguous option: \`$1'
27205Try \`$0 --help' for more information.";;
27206  --help | --hel | -h )
27207    $as_echo "$ac_cs_usage"; exit ;;
27208  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
27209  | -silent | --silent | --silen | --sile | --sil | --si | --s)
27210    ac_cs_silent=: ;;
27211
27212  # This is an error.
27213  -*) as_fn_error $? "unrecognized option: \`$1'
27214Try \`$0 --help' for more information." ;;
27215
27216  *) as_fn_append ac_config_targets " $1"
27217     ac_need_defaults=false ;;
27218
27219  esac
27220  shift
27221done
27222
27223ac_configure_extra_args=
27224
27225if $ac_cs_silent; then
27226  exec 6>/dev/null
27227  ac_configure_extra_args="$ac_configure_extra_args --silent"
27228fi
27229
27230_ACEOF
27231cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
27232if \$ac_cs_recheck; then
27233  set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
27234  shift
27235  \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
27236  CONFIG_SHELL='$SHELL'
27237  export CONFIG_SHELL
27238  exec "\$@"
27239fi
27240
27241_ACEOF
27242cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
27243exec 5>>config.log
27244{
27245  echo
27246  sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
27247## Running $as_me. ##
27248_ASBOX
27249  $as_echo "$ac_log"
27250} >&5
27251
27252_ACEOF
27253cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
27254#
27255# INIT-COMMANDS
27256#
27257AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
27258
27259
27260# The HP-UX ksh and POSIX shell print the target directory to stdout
27261# if CDPATH is set.
27262(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
27263
27264sed_quote_subst='$sed_quote_subst'
27265double_quote_subst='$double_quote_subst'
27266delay_variable_subst='$delay_variable_subst'
27267SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`'
27268Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`'
27269GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`'
27270EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`'
27271FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`'
27272SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`'
27273ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`'
27274LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`'
27275enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`'
27276macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`'
27277macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`'
27278enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`'
27279pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`'
27280enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`'
27281shared_archive_member_spec='`$ECHO "$shared_archive_member_spec" | $SED "$delay_single_quote_subst"`'
27282PATH_SEPARATOR='`$ECHO "$PATH_SEPARATOR" | $SED "$delay_single_quote_subst"`'
27283host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`'
27284host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`'
27285host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`'
27286build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`'
27287build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`'
27288build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`'
27289NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`'
27290LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`'
27291max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`'
27292ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`'
27293exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
27294lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
27295lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
27296lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
27297lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`'
27298lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`'
27299reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`'
27300reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`'
27301OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`'
27302deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`'
27303file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`'
27304file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`'
27305want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`'
27306DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`'
27307sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`'
27308AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`'
27309AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`'
27310archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`'
27311STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
27312RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
27313old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
27314old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
27315old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`'
27316lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`'
27317CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`'
27318CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`'
27319compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`'
27320GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`'
27321lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`'
27322lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
27323lt_cv_sys_global_symbol_to_import='`$ECHO "$lt_cv_sys_global_symbol_to_import" | $SED "$delay_single_quote_subst"`'
27324lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
27325lt_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"`'
27326lt_cv_nm_interface='`$ECHO "$lt_cv_nm_interface" | $SED "$delay_single_quote_subst"`'
27327nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`'
27328lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`'
27329lt_cv_truncate_bin='`$ECHO "$lt_cv_truncate_bin" | $SED "$delay_single_quote_subst"`'
27330objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`'
27331MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`'
27332lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`'
27333lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`'
27334lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
27335lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`'
27336lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`'
27337need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`'
27338MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`'
27339DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
27340NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
27341LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
27342OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`'
27343OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`'
27344libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`'
27345shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`'
27346extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
27347archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`'
27348enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`'
27349export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`'
27350whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`'
27351compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`'
27352old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`'
27353old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
27354archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`'
27355archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`'
27356module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`'
27357module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`'
27358with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`'
27359allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`'
27360no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`'
27361hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`'
27362hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`'
27363hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`'
27364hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`'
27365hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`'
27366hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`'
27367hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
27368inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
27369link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
27370always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`'
27371export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`'
27372exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`'
27373include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`'
27374prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`'
27375postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`'
27376file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
27377variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
27378need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
27379need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`'
27380version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`'
27381runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`'
27382shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`'
27383shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`'
27384libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`'
27385library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`'
27386soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`'
27387install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`'
27388postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`'
27389postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
27390finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`'
27391finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`'
27392hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`'
27393sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`'
27394configure_time_dlsearch_path='`$ECHO "$configure_time_dlsearch_path" | $SED "$delay_single_quote_subst"`'
27395configure_time_lt_sys_library_path='`$ECHO "$configure_time_lt_sys_library_path" | $SED "$delay_single_quote_subst"`'
27396hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`'
27397enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`'
27398enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`'
27399enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`'
27400old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`'
27401striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`'
27402
27403LTCC='$LTCC'
27404LTCFLAGS='$LTCFLAGS'
27405compiler='$compiler_DEFAULT'
27406
27407# A function that is used when there is no print builtin or printf.
27408func_fallback_echo ()
27409{
27410  eval 'cat <<_LTECHO_EOF
27411\$1
27412_LTECHO_EOF'
27413}
27414
27415# Quote evaled strings.
27416for var in SED \
27417GREP \
27418EGREP \
27419FGREP \
27420SHELL \
27421ECHO \
27422LD \
27423PATH_SEPARATOR \
27424NM \
27425LN_S \
27426lt_SP2NL \
27427lt_NL2SP \
27428reload_flag \
27429OBJDUMP \
27430deplibs_check_method \
27431file_magic_cmd \
27432file_magic_glob \
27433want_nocaseglob \
27434DLLTOOL \
27435sharedlib_from_linklib_cmd \
27436AR \
27437AR_FLAGS \
27438archiver_list_spec \
27439STRIP \
27440RANLIB \
27441CC \
27442CFLAGS \
27443compiler \
27444lt_cv_sys_global_symbol_pipe \
27445lt_cv_sys_global_symbol_to_cdecl \
27446lt_cv_sys_global_symbol_to_import \
27447lt_cv_sys_global_symbol_to_c_name_address \
27448lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
27449lt_cv_nm_interface \
27450nm_file_list_spec \
27451lt_cv_truncate_bin \
27452lt_prog_compiler_no_builtin_flag \
27453lt_prog_compiler_pic \
27454lt_prog_compiler_wl \
27455lt_prog_compiler_static \
27456lt_cv_prog_compiler_c_o \
27457need_locks \
27458MANIFEST_TOOL \
27459DSYMUTIL \
27460NMEDIT \
27461LIPO \
27462OTOOL \
27463OTOOL64 \
27464shrext_cmds \
27465export_dynamic_flag_spec \
27466whole_archive_flag_spec \
27467compiler_needs_object \
27468with_gnu_ld \
27469allow_undefined_flag \
27470no_undefined_flag \
27471hardcode_libdir_flag_spec \
27472hardcode_libdir_separator \
27473exclude_expsyms \
27474include_expsyms \
27475file_list_spec \
27476variables_saved_for_relink \
27477libname_spec \
27478library_names_spec \
27479soname_spec \
27480install_override_mode \
27481finish_eval \
27482old_striplib \
27483striplib; do
27484    case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
27485    *[\\\\\\\`\\"\\\$]*)
27486      eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes
27487      ;;
27488    *)
27489      eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
27490      ;;
27491    esac
27492done
27493
27494# Double-quote double-evaled strings.
27495for var in reload_cmds \
27496old_postinstall_cmds \
27497old_postuninstall_cmds \
27498old_archive_cmds \
27499extract_expsyms_cmds \
27500old_archive_from_new_cmds \
27501old_archive_from_expsyms_cmds \
27502archive_cmds \
27503archive_expsym_cmds \
27504module_cmds \
27505module_expsym_cmds \
27506export_symbols_cmds \
27507prelink_cmds \
27508postlink_cmds \
27509postinstall_cmds \
27510postuninstall_cmds \
27511finish_cmds \
27512sys_lib_search_path_spec \
27513configure_time_dlsearch_path \
27514configure_time_lt_sys_library_path; do
27515    case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
27516    *[\\\\\\\`\\"\\\$]*)
27517      eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes
27518      ;;
27519    *)
27520      eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
27521      ;;
27522    esac
27523done
27524
27525ac_aux_dir='$ac_aux_dir'
27526
27527# See if we are running on zsh, and set the options that allow our
27528# commands through without removal of \ escapes INIT.
27529if test -n "\${ZSH_VERSION+set}"; then
27530   setopt NO_GLOB_SUBST
27531fi
27532
27533
27534    PACKAGE='$PACKAGE'
27535    VERSION='$VERSION'
27536    RM='$RM'
27537    ofile='$ofile'
27538
27539
27540
27541
27542_ACEOF
27543
27544cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
27545
27546# Handling of arguments.
27547for ac_config_target in $ac_config_targets
27548do
27549  case $ac_config_target in
27550    "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;;
27551    "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
27552    "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;;
27553    "libopts/Makefile") CONFIG_FILES="$CONFIG_FILES libopts/Makefile" ;;
27554    "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
27555    "include/Makefile") CONFIG_FILES="$CONFIG_FILES include/Makefile" ;;
27556    "scripts/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/Makefile" ;;
27557    "tests/Makefile") CONFIG_FILES="$CONFIG_FILES tests/Makefile" ;;
27558    "tests/fileHandlingTest.h") CONFIG_FILES="$CONFIG_FILES tests/fileHandlingTest.h" ;;
27559    "unity/Makefile") CONFIG_FILES="$CONFIG_FILES unity/Makefile" ;;
27560
27561  *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
27562  esac
27563done
27564
27565
27566# If the user did not use the arguments to specify the items to instantiate,
27567# then the envvar interface is used.  Set only those that are not.
27568# We use the long form for the default assignment because of an extremely
27569# bizarre bug on SunOS 4.1.3.
27570if $ac_need_defaults; then
27571  test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
27572  test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
27573  test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
27574fi
27575
27576# Have a temporary directory for convenience.  Make it in the build tree
27577# simply because there is no reason against having it here, and in addition,
27578# creating and moving files from /tmp can sometimes cause problems.
27579# Hook for its removal unless debugging.
27580# Note that there is a small window in which the directory will not be cleaned:
27581# after its creation but before its name has been assigned to `$tmp'.
27582$debug ||
27583{
27584  tmp= ac_tmp=
27585  trap 'exit_status=$?
27586  : "${ac_tmp:=$tmp}"
27587  { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
27588' 0
27589  trap 'as_fn_exit 1' 1 2 13 15
27590}
27591# Create a (secure) tmp directory for tmp files.
27592
27593{
27594  tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
27595  test -d "$tmp"
27596}  ||
27597{
27598  tmp=./conf$$-$RANDOM
27599  (umask 077 && mkdir "$tmp")
27600} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
27601ac_tmp=$tmp
27602
27603# Set up the scripts for CONFIG_FILES section.
27604# No need to generate them if there are no CONFIG_FILES.
27605# This happens for instance with `./config.status config.h'.
27606if test -n "$CONFIG_FILES"; then
27607
27608
27609ac_cr=`echo X | tr X '\015'`
27610# On cygwin, bash can eat \r inside `` if the user requested igncr.
27611# But we know of no other shell where ac_cr would be empty at this
27612# point, so we can use a bashism as a fallback.
27613if test "x$ac_cr" = x; then
27614  eval ac_cr=\$\'\\r\'
27615fi
27616ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
27617if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
27618  ac_cs_awk_cr='\\r'
27619else
27620  ac_cs_awk_cr=$ac_cr
27621fi
27622
27623echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
27624_ACEOF
27625
27626
27627{
27628  echo "cat >conf$$subs.awk <<_ACEOF" &&
27629  echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
27630  echo "_ACEOF"
27631} >conf$$subs.sh ||
27632  as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
27633ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
27634ac_delim='%!_!# '
27635for ac_last_try in false false false false false :; do
27636  . ./conf$$subs.sh ||
27637    as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
27638
27639  ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
27640  if test $ac_delim_n = $ac_delim_num; then
27641    break
27642  elif $ac_last_try; then
27643    as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
27644  else
27645    ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
27646  fi
27647done
27648rm -f conf$$subs.sh
27649
27650cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
27651cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
27652_ACEOF
27653sed -n '
27654h
27655s/^/S["/; s/!.*/"]=/
27656p
27657g
27658s/^[^!]*!//
27659:repl
27660t repl
27661s/'"$ac_delim"'$//
27662t delim
27663:nl
27664h
27665s/\(.\{148\}\)..*/\1/
27666t more1
27667s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
27668p
27669n
27670b repl
27671:more1
27672s/["\\]/\\&/g; s/^/"/; s/$/"\\/
27673p
27674g
27675s/.\{148\}//
27676t nl
27677:delim
27678h
27679s/\(.\{148\}\)..*/\1/
27680t more2
27681s/["\\]/\\&/g; s/^/"/; s/$/"/
27682p
27683b
27684:more2
27685s/["\\]/\\&/g; s/^/"/; s/$/"\\/
27686p
27687g
27688s/.\{148\}//
27689t delim
27690' <conf$$subs.awk | sed '
27691/^[^""]/{
27692  N
27693  s/\n//
27694}
27695' >>$CONFIG_STATUS || ac_write_fail=1
27696rm -f conf$$subs.awk
27697cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
27698_ACAWK
27699cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
27700  for (key in S) S_is_set[key] = 1
27701  FS = ""
27702
27703}
27704{
27705  line = $ 0
27706  nfields = split(line, field, "@")
27707  substed = 0
27708  len = length(field[1])
27709  for (i = 2; i < nfields; i++) {
27710    key = field[i]
27711    keylen = length(key)
27712    if (S_is_set[key]) {
27713      value = S[key]
27714      line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
27715      len += length(value) + length(field[++i])
27716      substed = 1
27717    } else
27718      len += 1 + keylen
27719  }
27720
27721  print line
27722}
27723
27724_ACAWK
27725_ACEOF
27726cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
27727if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
27728  sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
27729else
27730  cat
27731fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
27732  || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
27733_ACEOF
27734
27735# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
27736# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
27737# trailing colons and then remove the whole line if VPATH becomes empty
27738# (actually we leave an empty line to preserve line numbers).
27739if test "x$srcdir" = x.; then
27740  ac_vpsub='/^[	 ]*VPATH[	 ]*=[	 ]*/{
27741h
27742s///
27743s/^/:/
27744s/[	 ]*$/:/
27745s/:\$(srcdir):/:/g
27746s/:\${srcdir}:/:/g
27747s/:@srcdir@:/:/g
27748s/^:*//
27749s/:*$//
27750x
27751s/\(=[	 ]*\).*/\1/
27752G
27753s/\n//
27754s/^[^=]*=[	 ]*$//
27755}'
27756fi
27757
27758cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
27759fi # test -n "$CONFIG_FILES"
27760
27761# Set up the scripts for CONFIG_HEADERS section.
27762# No need to generate them if there are no CONFIG_HEADERS.
27763# This happens for instance with `./config.status Makefile'.
27764if test -n "$CONFIG_HEADERS"; then
27765cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
27766BEGIN {
27767_ACEOF
27768
27769# Transform confdefs.h into an awk script `defines.awk', embedded as
27770# here-document in config.status, that substitutes the proper values into
27771# config.h.in to produce config.h.
27772
27773# Create a delimiter string that does not exist in confdefs.h, to ease
27774# handling of long lines.
27775ac_delim='%!_!# '
27776for ac_last_try in false false :; do
27777  ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
27778  if test -z "$ac_tt"; then
27779    break
27780  elif $ac_last_try; then
27781    as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
27782  else
27783    ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
27784  fi
27785done
27786
27787# For the awk script, D is an array of macro values keyed by name,
27788# likewise P contains macro parameters if any.  Preserve backslash
27789# newline sequences.
27790
27791ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
27792sed -n '
27793s/.\{148\}/&'"$ac_delim"'/g
27794t rset
27795:rset
27796s/^[	 ]*#[	 ]*define[	 ][	 ]*/ /
27797t def
27798d
27799:def
27800s/\\$//
27801t bsnl
27802s/["\\]/\\&/g
27803s/^ \('"$ac_word_re"'\)\(([^()]*)\)[	 ]*\(.*\)/P["\1"]="\2"\
27804D["\1"]=" \3"/p
27805s/^ \('"$ac_word_re"'\)[	 ]*\(.*\)/D["\1"]=" \2"/p
27806d
27807:bsnl
27808s/["\\]/\\&/g
27809s/^ \('"$ac_word_re"'\)\(([^()]*)\)[	 ]*\(.*\)/P["\1"]="\2"\
27810D["\1"]=" \3\\\\\\n"\\/p
27811t cont
27812s/^ \('"$ac_word_re"'\)[	 ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
27813t cont
27814d
27815:cont
27816n
27817s/.\{148\}/&'"$ac_delim"'/g
27818t clear
27819:clear
27820s/\\$//
27821t bsnlc
27822s/["\\]/\\&/g; s/^/"/; s/$/"/p
27823d
27824:bsnlc
27825s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
27826b cont
27827' <confdefs.h | sed '
27828s/'"$ac_delim"'/"\\\
27829"/g' >>$CONFIG_STATUS || ac_write_fail=1
27830
27831cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
27832  for (key in D) D_is_set[key] = 1
27833  FS = ""
27834}
27835/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
27836  line = \$ 0
27837  split(line, arg, " ")
27838  if (arg[1] == "#") {
27839    defundef = arg[2]
27840    mac1 = arg[3]
27841  } else {
27842    defundef = substr(arg[1], 2)
27843    mac1 = arg[2]
27844  }
27845  split(mac1, mac2, "(") #)
27846  macro = mac2[1]
27847  prefix = substr(line, 1, index(line, defundef) - 1)
27848  if (D_is_set[macro]) {
27849    # Preserve the white space surrounding the "#".
27850    print prefix "define", macro P[macro] D[macro]
27851    next
27852  } else {
27853    # Replace #undef with comments.  This is necessary, for example,
27854    # in the case of _POSIX_SOURCE, which is predefined and required
27855    # on some systems where configure will not decide to define it.
27856    if (defundef == "undef") {
27857      print "/*", prefix defundef, macro, "*/"
27858      next
27859    }
27860  }
27861}
27862{ print }
27863_ACAWK
27864_ACEOF
27865cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
27866  as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
27867fi # test -n "$CONFIG_HEADERS"
27868
27869
27870eval set X "  :F $CONFIG_FILES  :H $CONFIG_HEADERS    :C $CONFIG_COMMANDS"
27871shift
27872for ac_tag
27873do
27874  case $ac_tag in
27875  :[FHLC]) ac_mode=$ac_tag; continue;;
27876  esac
27877  case $ac_mode$ac_tag in
27878  :[FHL]*:*);;
27879  :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
27880  :[FH]-) ac_tag=-:-;;
27881  :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
27882  esac
27883  ac_save_IFS=$IFS
27884  IFS=:
27885  set x $ac_tag
27886  IFS=$ac_save_IFS
27887  shift
27888  ac_file=$1
27889  shift
27890
27891  case $ac_mode in
27892  :L) ac_source=$1;;
27893  :[FH])
27894    ac_file_inputs=
27895    for ac_f
27896    do
27897      case $ac_f in
27898      -) ac_f="$ac_tmp/stdin";;
27899      *) # Look for the file first in the build tree, then in the source tree
27900	 # (if the path is not absolute).  The absolute path cannot be DOS-style,
27901	 # because $ac_f cannot contain `:'.
27902	 test -f "$ac_f" ||
27903	   case $ac_f in
27904	   [\\/$]*) false;;
27905	   *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
27906	   esac ||
27907	   as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
27908      esac
27909      case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
27910      as_fn_append ac_file_inputs " '$ac_f'"
27911    done
27912
27913    # Let's still pretend it is `configure' which instantiates (i.e., don't
27914    # use $as_me), people would be surprised to read:
27915    #    /* config.h.  Generated by config.status.  */
27916    configure_input='Generated from '`
27917	  $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
27918	`' by configure.'
27919    if test x"$ac_file" != x-; then
27920      configure_input="$ac_file.  $configure_input"
27921      { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
27922$as_echo "$as_me: creating $ac_file" >&6;}
27923    fi
27924    # Neutralize special characters interpreted by sed in replacement strings.
27925    case $configure_input in #(
27926    *\&* | *\|* | *\\* )
27927       ac_sed_conf_input=`$as_echo "$configure_input" |
27928       sed 's/[\\\\&|]/\\\\&/g'`;; #(
27929    *) ac_sed_conf_input=$configure_input;;
27930    esac
27931
27932    case $ac_tag in
27933    *:-:* | *:-) cat >"$ac_tmp/stdin" \
27934      || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
27935    esac
27936    ;;
27937  esac
27938
27939  ac_dir=`$as_dirname -- "$ac_file" ||
27940$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
27941	 X"$ac_file" : 'X\(//\)[^/]' \| \
27942	 X"$ac_file" : 'X\(//\)$' \| \
27943	 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
27944$as_echo X"$ac_file" |
27945    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
27946	    s//\1/
27947	    q
27948	  }
27949	  /^X\(\/\/\)[^/].*/{
27950	    s//\1/
27951	    q
27952	  }
27953	  /^X\(\/\/\)$/{
27954	    s//\1/
27955	    q
27956	  }
27957	  /^X\(\/\).*/{
27958	    s//\1/
27959	    q
27960	  }
27961	  s/.*/./; q'`
27962  as_dir="$ac_dir"; as_fn_mkdir_p
27963  ac_builddir=.
27964
27965case "$ac_dir" in
27966.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
27967*)
27968  ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
27969  # A ".." for each directory in $ac_dir_suffix.
27970  ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
27971  case $ac_top_builddir_sub in
27972  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
27973  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
27974  esac ;;
27975esac
27976ac_abs_top_builddir=$ac_pwd
27977ac_abs_builddir=$ac_pwd$ac_dir_suffix
27978# for backward compatibility:
27979ac_top_builddir=$ac_top_build_prefix
27980
27981case $srcdir in
27982  .)  # We are building in place.
27983    ac_srcdir=.
27984    ac_top_srcdir=$ac_top_builddir_sub
27985    ac_abs_top_srcdir=$ac_pwd ;;
27986  [\\/]* | ?:[\\/]* )  # Absolute name.
27987    ac_srcdir=$srcdir$ac_dir_suffix;
27988    ac_top_srcdir=$srcdir
27989    ac_abs_top_srcdir=$srcdir ;;
27990  *) # Relative name.
27991    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
27992    ac_top_srcdir=$ac_top_build_prefix$srcdir
27993    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
27994esac
27995ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
27996
27997
27998  case $ac_mode in
27999  :F)
28000  #
28001  # CONFIG_FILE
28002  #
28003
28004  case $INSTALL in
28005  [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
28006  *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
28007  esac
28008  ac_MKDIR_P=$MKDIR_P
28009  case $MKDIR_P in
28010  [\\/$]* | ?:[\\/]* ) ;;
28011  */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
28012  esac
28013_ACEOF
28014
28015cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
28016# If the template does not know about datarootdir, expand it.
28017# FIXME: This hack should be removed a few years after 2.60.
28018ac_datarootdir_hack=; ac_datarootdir_seen=
28019ac_sed_dataroot='
28020/datarootdir/ {
28021  p
28022  q
28023}
28024/@datadir@/p
28025/@docdir@/p
28026/@infodir@/p
28027/@localedir@/p
28028/@mandir@/p'
28029case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
28030*datarootdir*) ac_datarootdir_seen=yes;;
28031*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
28032  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
28033$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
28034_ACEOF
28035cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
28036  ac_datarootdir_hack='
28037  s&@datadir@&$datadir&g
28038  s&@docdir@&$docdir&g
28039  s&@infodir@&$infodir&g
28040  s&@localedir@&$localedir&g
28041  s&@mandir@&$mandir&g
28042  s&\\\${datarootdir}&$datarootdir&g' ;;
28043esac
28044_ACEOF
28045
28046# Neutralize VPATH when `$srcdir' = `.'.
28047# Shell code in configure.ac might set extrasub.
28048# FIXME: do we really want to maintain this feature?
28049cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
28050ac_sed_extra="$ac_vpsub
28051$extrasub
28052_ACEOF
28053cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
28054:t
28055/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
28056s|@configure_input@|$ac_sed_conf_input|;t t
28057s&@top_builddir@&$ac_top_builddir_sub&;t t
28058s&@top_build_prefix@&$ac_top_build_prefix&;t t
28059s&@srcdir@&$ac_srcdir&;t t
28060s&@abs_srcdir@&$ac_abs_srcdir&;t t
28061s&@top_srcdir@&$ac_top_srcdir&;t t
28062s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
28063s&@builddir@&$ac_builddir&;t t
28064s&@abs_builddir@&$ac_abs_builddir&;t t
28065s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
28066s&@INSTALL@&$ac_INSTALL&;t t
28067s&@MKDIR_P@&$ac_MKDIR_P&;t t
28068$ac_datarootdir_hack
28069"
28070eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
28071  >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
28072
28073test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
28074  { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
28075  { ac_out=`sed -n '/^[	 ]*datarootdir[	 ]*:*=/p' \
28076      "$ac_tmp/out"`; test -z "$ac_out"; } &&
28077  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
28078which seems to be undefined.  Please make sure it is defined" >&5
28079$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
28080which seems to be undefined.  Please make sure it is defined" >&2;}
28081
28082  rm -f "$ac_tmp/stdin"
28083  case $ac_file in
28084  -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
28085  *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
28086  esac \
28087  || as_fn_error $? "could not create $ac_file" "$LINENO" 5
28088 ;;
28089  :H)
28090  #
28091  # CONFIG_HEADER
28092  #
28093  if test x"$ac_file" != x-; then
28094    {
28095      $as_echo "/* $configure_input  */" \
28096      && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
28097    } >"$ac_tmp/config.h" \
28098      || as_fn_error $? "could not create $ac_file" "$LINENO" 5
28099    if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
28100      { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
28101$as_echo "$as_me: $ac_file is unchanged" >&6;}
28102    else
28103      rm -f "$ac_file"
28104      mv "$ac_tmp/config.h" "$ac_file" \
28105	|| as_fn_error $? "could not create $ac_file" "$LINENO" 5
28106    fi
28107  else
28108    $as_echo "/* $configure_input  */" \
28109      && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
28110      || as_fn_error $? "could not create -" "$LINENO" 5
28111  fi
28112# Compute "$ac_file"'s index in $config_headers.
28113_am_arg="$ac_file"
28114_am_stamp_count=1
28115for _am_header in $config_headers :; do
28116  case $_am_header in
28117    $_am_arg | $_am_arg:* )
28118      break ;;
28119    * )
28120      _am_stamp_count=`expr $_am_stamp_count + 1` ;;
28121  esac
28122done
28123echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
28124$as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
28125	 X"$_am_arg" : 'X\(//\)[^/]' \| \
28126	 X"$_am_arg" : 'X\(//\)$' \| \
28127	 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
28128$as_echo X"$_am_arg" |
28129    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
28130	    s//\1/
28131	    q
28132	  }
28133	  /^X\(\/\/\)[^/].*/{
28134	    s//\1/
28135	    q
28136	  }
28137	  /^X\(\/\/\)$/{
28138	    s//\1/
28139	    q
28140	  }
28141	  /^X\(\/\).*/{
28142	    s//\1/
28143	    q
28144	  }
28145	  s/.*/./; q'`/stamp-h$_am_stamp_count
28146 ;;
28147
28148  :C)  { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
28149$as_echo "$as_me: executing $ac_file commands" >&6;}
28150 ;;
28151  esac
28152
28153
28154  case $ac_file$ac_mode in
28155    "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
28156  # Older Autoconf quotes --file arguments for eval, but not when files
28157  # are listed without --file.  Let's play safe and only enable the eval
28158  # if we detect the quoting.
28159  case $CONFIG_FILES in
28160  *\'*) eval set x "$CONFIG_FILES" ;;
28161  *)   set x $CONFIG_FILES ;;
28162  esac
28163  shift
28164  for mf
28165  do
28166    # Strip MF so we end up with the name of the file.
28167    mf=`echo "$mf" | sed -e 's/:.*$//'`
28168    # Check whether this is an Automake generated Makefile or not.
28169    # We used to match only the files named 'Makefile.in', but
28170    # some people rename them; so instead we look at the file content.
28171    # Grep'ing the first line is not enough: some people post-process
28172    # each Makefile.in and add a new line on top of each file to say so.
28173    # Grep'ing the whole file is not good either: AIX grep has a line
28174    # limit of 2048, but all sed's we know have understand at least 4000.
28175    if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
28176      dirpart=`$as_dirname -- "$mf" ||
28177$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
28178	 X"$mf" : 'X\(//\)[^/]' \| \
28179	 X"$mf" : 'X\(//\)$' \| \
28180	 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
28181$as_echo X"$mf" |
28182    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
28183	    s//\1/
28184	    q
28185	  }
28186	  /^X\(\/\/\)[^/].*/{
28187	    s//\1/
28188	    q
28189	  }
28190	  /^X\(\/\/\)$/{
28191	    s//\1/
28192	    q
28193	  }
28194	  /^X\(\/\).*/{
28195	    s//\1/
28196	    q
28197	  }
28198	  s/.*/./; q'`
28199    else
28200      continue
28201    fi
28202    # Extract the definition of DEPDIR, am__include, and am__quote
28203    # from the Makefile without running 'make'.
28204    DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
28205    test -z "$DEPDIR" && continue
28206    am__include=`sed -n 's/^am__include = //p' < "$mf"`
28207    test -z "$am__include" && continue
28208    am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
28209    # Find all dependency output files, they are included files with
28210    # $(DEPDIR) in their names.  We invoke sed twice because it is the
28211    # simplest approach to changing $(DEPDIR) to its actual value in the
28212    # expansion.
28213    for file in `sed -n "
28214      s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
28215	 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do
28216      # Make sure the directory exists.
28217      test -f "$dirpart/$file" && continue
28218      fdir=`$as_dirname -- "$file" ||
28219$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
28220	 X"$file" : 'X\(//\)[^/]' \| \
28221	 X"$file" : 'X\(//\)$' \| \
28222	 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
28223$as_echo X"$file" |
28224    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
28225	    s//\1/
28226	    q
28227	  }
28228	  /^X\(\/\/\)[^/].*/{
28229	    s//\1/
28230	    q
28231	  }
28232	  /^X\(\/\/\)$/{
28233	    s//\1/
28234	    q
28235	  }
28236	  /^X\(\/\).*/{
28237	    s//\1/
28238	    q
28239	  }
28240	  s/.*/./; q'`
28241      as_dir=$dirpart/$fdir; as_fn_mkdir_p
28242      # echo "creating $dirpart/$file"
28243      echo '# dummy' > "$dirpart/$file"
28244    done
28245  done
28246}
28247 ;;
28248    "libtool":C)
28249
28250    # See if we are running on zsh, and set the options that allow our
28251    # commands through without removal of \ escapes.
28252    if test -n "${ZSH_VERSION+set}"; then
28253      setopt NO_GLOB_SUBST
28254    fi
28255
28256    cfgfile=${ofile}T
28257    trap "$RM \"$cfgfile\"; exit 1" 1 2 15
28258    $RM "$cfgfile"
28259
28260    cat <<_LT_EOF >> "$cfgfile"
28261#! $SHELL
28262# Generated automatically by $as_me ($PACKAGE) $VERSION
28263# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
28264# NOTE: Changes made to this file will be lost: look at ltmain.sh.
28265
28266# Provide generalized library-building support services.
28267# Written by Gordon Matzigkeit, 1996
28268
28269# Copyright (C) 2014 Free Software Foundation, Inc.
28270# This is free software; see the source for copying conditions.  There is NO
28271# warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
28272
28273# GNU Libtool is free software; you can redistribute it and/or modify
28274# it under the terms of the GNU General Public License as published by
28275# the Free Software Foundation; either version 2 of of the License, or
28276# (at your option) any later version.
28277#
28278# As a special exception to the GNU General Public License, if you
28279# distribute this file as part of a program or library that is built
28280# using GNU Libtool, you may include this file under the  same
28281# distribution terms that you use for the rest of that program.
28282#
28283# GNU Libtool is distributed in the hope that it will be useful, but
28284# WITHOUT ANY WARRANTY; without even the implied warranty of
28285# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
28286# GNU General Public License for more details.
28287#
28288# You should have received a copy of the GNU General Public License
28289# along with this program.  If not, see <http://www.gnu.org/licenses/>.
28290
28291
28292# The names of the tagged configurations supported by this script.
28293available_tags=''
28294
28295# Configured defaults for sys_lib_dlsearch_path munging.
28296: \${LT_SYS_LIBRARY_PATH="$configure_time_lt_sys_library_path"}
28297
28298# ### BEGIN LIBTOOL CONFIG
28299
28300# A sed program that does not truncate output.
28301SED=$lt_SED
28302
28303# Sed that helps us avoid accidentally triggering echo(1) options like -n.
28304Xsed="\$SED -e 1s/^X//"
28305
28306# A grep program that handles long lines.
28307GREP=$lt_GREP
28308
28309# An ERE matcher.
28310EGREP=$lt_EGREP
28311
28312# A literal string matcher.
28313FGREP=$lt_FGREP
28314
28315# Shell to use when invoking shell scripts.
28316SHELL=$lt_SHELL
28317
28318# An echo program that protects backslashes.
28319ECHO=$lt_ECHO
28320
28321# Whether or not to build shared libraries.
28322build_libtool_libs=$enable_shared
28323
28324# Which release of libtool.m4 was used?
28325macro_version=$macro_version
28326macro_revision=$macro_revision
28327
28328# Whether or not to build static libraries.
28329build_old_libs=$enable_static
28330
28331# What type of objects to build.
28332pic_mode=$pic_mode
28333
28334# Whether or not to optimize for fast installation.
28335fast_install=$enable_fast_install
28336
28337# Shared archive member basename,for filename based shared library versioning on AIX.
28338shared_archive_member_spec=$shared_archive_member_spec
28339
28340# The PATH separator for the build system.
28341PATH_SEPARATOR=$lt_PATH_SEPARATOR
28342
28343# The host system.
28344host_alias=$host_alias
28345host=$host
28346host_os=$host_os
28347
28348# The build system.
28349build_alias=$build_alias
28350build=$build
28351build_os=$build_os
28352
28353# A BSD- or MS-compatible name lister.
28354NM=$lt_NM
28355
28356# Whether we need soft or hard links.
28357LN_S=$lt_LN_S
28358
28359# What is the maximum length of a command?
28360max_cmd_len=$max_cmd_len
28361
28362# Object file suffix (normally "o").
28363objext=$ac_objext
28364
28365# Executable file suffix (normally "").
28366exeext=$exeext
28367
28368# whether the shell understands "unset".
28369lt_unset=$lt_unset
28370
28371# turn spaces into newlines.
28372SP2NL=$lt_lt_SP2NL
28373
28374# turn newlines into spaces.
28375NL2SP=$lt_lt_NL2SP
28376
28377# convert \$build file names to \$host format.
28378to_host_file_cmd=$lt_cv_to_host_file_cmd
28379
28380# convert \$build files to toolchain format.
28381to_tool_file_cmd=$lt_cv_to_tool_file_cmd
28382
28383# An object symbol dumper.
28384OBJDUMP=$lt_OBJDUMP
28385
28386# Method to check whether dependent libraries are shared objects.
28387deplibs_check_method=$lt_deplibs_check_method
28388
28389# Command to use when deplibs_check_method = "file_magic".
28390file_magic_cmd=$lt_file_magic_cmd
28391
28392# How to find potential files when deplibs_check_method = "file_magic".
28393file_magic_glob=$lt_file_magic_glob
28394
28395# Find potential files using nocaseglob when deplibs_check_method = "file_magic".
28396want_nocaseglob=$lt_want_nocaseglob
28397
28398# DLL creation program.
28399DLLTOOL=$lt_DLLTOOL
28400
28401# Command to associate shared and link libraries.
28402sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd
28403
28404# The archiver.
28405AR=$lt_AR
28406
28407# Flags to create an archive.
28408AR_FLAGS=$lt_AR_FLAGS
28409
28410# How to feed a file listing to the archiver.
28411archiver_list_spec=$lt_archiver_list_spec
28412
28413# A symbol stripping program.
28414STRIP=$lt_STRIP
28415
28416# Commands used to install an old-style archive.
28417RANLIB=$lt_RANLIB
28418old_postinstall_cmds=$lt_old_postinstall_cmds
28419old_postuninstall_cmds=$lt_old_postuninstall_cmds
28420
28421# Whether to use a lock for old archive extraction.
28422lock_old_archive_extraction=$lock_old_archive_extraction
28423
28424# A C compiler.
28425LTCC=$lt_CC
28426
28427# LTCC compiler flags.
28428LTCFLAGS=$lt_CFLAGS
28429
28430# Take the output of nm and produce a listing of raw symbols and C names.
28431global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
28432
28433# Transform the output of nm in a proper C declaration.
28434global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
28435
28436# Transform the output of nm into a list of symbols to manually relocate.
28437global_symbol_to_import=$lt_lt_cv_sys_global_symbol_to_import
28438
28439# Transform the output of nm in a C name address pair.
28440global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
28441
28442# Transform the output of nm in a C name address pair when lib prefix is needed.
28443global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
28444
28445# The name lister interface.
28446nm_interface=$lt_lt_cv_nm_interface
28447
28448# Specify filename containing input files for \$NM.
28449nm_file_list_spec=$lt_nm_file_list_spec
28450
28451# The root where to search for dependent libraries,and where our libraries should be installed.
28452lt_sysroot=$lt_sysroot
28453
28454# Command to truncate a binary pipe.
28455lt_truncate_bin=$lt_lt_cv_truncate_bin
28456
28457# The name of the directory that contains temporary libtool files.
28458objdir=$objdir
28459
28460# Used to examine libraries when file_magic_cmd begins with "file".
28461MAGIC_CMD=$MAGIC_CMD
28462
28463# Must we lock files when doing compilation?
28464need_locks=$lt_need_locks
28465
28466# Manifest tool.
28467MANIFEST_TOOL=$lt_MANIFEST_TOOL
28468
28469# Tool to manipulate archived DWARF debug symbol files on Mac OS X.
28470DSYMUTIL=$lt_DSYMUTIL
28471
28472# Tool to change global to local symbols on Mac OS X.
28473NMEDIT=$lt_NMEDIT
28474
28475# Tool to manipulate fat objects and archives on Mac OS X.
28476LIPO=$lt_LIPO
28477
28478# ldd/readelf like tool for Mach-O binaries on Mac OS X.
28479OTOOL=$lt_OTOOL
28480
28481# ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4.
28482OTOOL64=$lt_OTOOL64
28483
28484# Old archive suffix (normally "a").
28485libext=$libext
28486
28487# Shared library suffix (normally ".so").
28488shrext_cmds=$lt_shrext_cmds
28489
28490# The commands to extract the exported symbol list from a shared archive.
28491extract_expsyms_cmds=$lt_extract_expsyms_cmds
28492
28493# Variables whose values should be saved in libtool wrapper scripts and
28494# restored at link time.
28495variables_saved_for_relink=$lt_variables_saved_for_relink
28496
28497# Do we need the "lib" prefix for modules?
28498need_lib_prefix=$need_lib_prefix
28499
28500# Do we need a version for libraries?
28501need_version=$need_version
28502
28503# Library versioning type.
28504version_type=$version_type
28505
28506# Shared library runtime path variable.
28507runpath_var=$runpath_var
28508
28509# Shared library path variable.
28510shlibpath_var=$shlibpath_var
28511
28512# Is shlibpath searched before the hard-coded library search path?
28513shlibpath_overrides_runpath=$shlibpath_overrides_runpath
28514
28515# Format of library name prefix.
28516libname_spec=$lt_libname_spec
28517
28518# List of archive names.  First name is the real one, the rest are links.
28519# The last name is the one that the linker finds with -lNAME
28520library_names_spec=$lt_library_names_spec
28521
28522# The coded name of the library, if different from the real name.
28523soname_spec=$lt_soname_spec
28524
28525# Permission mode override for installation of shared libraries.
28526install_override_mode=$lt_install_override_mode
28527
28528# Command to use after installation of a shared archive.
28529postinstall_cmds=$lt_postinstall_cmds
28530
28531# Command to use after uninstallation of a shared archive.
28532postuninstall_cmds=$lt_postuninstall_cmds
28533
28534# Commands used to finish a libtool library installation in a directory.
28535finish_cmds=$lt_finish_cmds
28536
28537# As "finish_cmds", except a single script fragment to be evaled but
28538# not shown.
28539finish_eval=$lt_finish_eval
28540
28541# Whether we should hardcode library paths into libraries.
28542hardcode_into_libs=$hardcode_into_libs
28543
28544# Compile-time system search path for libraries.
28545sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
28546
28547# Detected run-time system search path for libraries.
28548sys_lib_dlsearch_path_spec=$lt_configure_time_dlsearch_path
28549
28550# Explicit LT_SYS_LIBRARY_PATH set during ./configure time.
28551configure_time_lt_sys_library_path=$lt_configure_time_lt_sys_library_path
28552
28553# Whether dlopen is supported.
28554dlopen_support=$enable_dlopen
28555
28556# Whether dlopen of programs is supported.
28557dlopen_self=$enable_dlopen_self
28558
28559# Whether dlopen of statically linked programs is supported.
28560dlopen_self_static=$enable_dlopen_self_static
28561
28562# Commands to strip libraries.
28563old_striplib=$lt_old_striplib
28564striplib=$lt_striplib
28565
28566
28567# The linker used to build libraries.
28568LD=$lt_LD
28569
28570# How to create reloadable object files.
28571reload_flag=$lt_reload_flag
28572reload_cmds=$lt_reload_cmds
28573
28574# Commands used to build an old-style archive.
28575old_archive_cmds=$lt_old_archive_cmds
28576
28577# A language specific compiler.
28578CC=$lt_compiler
28579
28580# Is the compiler the GNU compiler?
28581with_gcc=$GCC
28582
28583# Compiler flag to turn off builtin functions.
28584no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
28585
28586# Additional compiler flags for building library objects.
28587pic_flag=$lt_lt_prog_compiler_pic
28588
28589# How to pass a linker flag through the compiler.
28590wl=$lt_lt_prog_compiler_wl
28591
28592# Compiler flag to prevent dynamic linking.
28593link_static_flag=$lt_lt_prog_compiler_static
28594
28595# Does compiler simultaneously support -c and -o options?
28596compiler_c_o=$lt_lt_cv_prog_compiler_c_o
28597
28598# Whether or not to add -lc for building shared libraries.
28599build_libtool_need_lc=$archive_cmds_need_lc
28600
28601# Whether or not to disallow shared libs when runtime libs are static.
28602allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes
28603
28604# Compiler flag to allow reflexive dlopens.
28605export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
28606
28607# Compiler flag to generate shared objects directly from archives.
28608whole_archive_flag_spec=$lt_whole_archive_flag_spec
28609
28610# Whether the compiler copes with passing no objects directly.
28611compiler_needs_object=$lt_compiler_needs_object
28612
28613# Create an old-style archive from a shared archive.
28614old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
28615
28616# Create a temporary old-style archive to link instead of a shared archive.
28617old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
28618
28619# Commands used to build a shared archive.
28620archive_cmds=$lt_archive_cmds
28621archive_expsym_cmds=$lt_archive_expsym_cmds
28622
28623# Commands used to build a loadable module if different from building
28624# a shared archive.
28625module_cmds=$lt_module_cmds
28626module_expsym_cmds=$lt_module_expsym_cmds
28627
28628# Whether we are building with GNU ld or not.
28629with_gnu_ld=$lt_with_gnu_ld
28630
28631# Flag that allows shared libraries with undefined symbols to be built.
28632allow_undefined_flag=$lt_allow_undefined_flag
28633
28634# Flag that enforces no undefined symbols.
28635no_undefined_flag=$lt_no_undefined_flag
28636
28637# Flag to hardcode \$libdir into a binary during linking.
28638# This must work even if \$libdir does not exist
28639hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
28640
28641# Whether we need a single "-rpath" flag with a separated argument.
28642hardcode_libdir_separator=$lt_hardcode_libdir_separator
28643
28644# Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes
28645# DIR into the resulting binary.
28646hardcode_direct=$hardcode_direct
28647
28648# Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes
28649# DIR into the resulting binary and the resulting library dependency is
28650# "absolute",i.e impossible to change by setting \$shlibpath_var if the
28651# library is relocated.
28652hardcode_direct_absolute=$hardcode_direct_absolute
28653
28654# Set to "yes" if using the -LDIR flag during linking hardcodes DIR
28655# into the resulting binary.
28656hardcode_minus_L=$hardcode_minus_L
28657
28658# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
28659# into the resulting binary.
28660hardcode_shlibpath_var=$hardcode_shlibpath_var
28661
28662# Set to "yes" if building a shared library automatically hardcodes DIR
28663# into the library and all subsequent libraries and executables linked
28664# against it.
28665hardcode_automatic=$hardcode_automatic
28666
28667# Set to yes if linker adds runtime paths of dependent libraries
28668# to runtime path list.
28669inherit_rpath=$inherit_rpath
28670
28671# Whether libtool must link a program against all its dependency libraries.
28672link_all_deplibs=$link_all_deplibs
28673
28674# Set to "yes" if exported symbols are required.
28675always_export_symbols=$always_export_symbols
28676
28677# The commands to list exported symbols.
28678export_symbols_cmds=$lt_export_symbols_cmds
28679
28680# Symbols that should not be listed in the preloaded symbols.
28681exclude_expsyms=$lt_exclude_expsyms
28682
28683# Symbols that must always be exported.
28684include_expsyms=$lt_include_expsyms
28685
28686# Commands necessary for linking programs (against libraries) with templates.
28687prelink_cmds=$lt_prelink_cmds
28688
28689# Commands necessary for finishing linking programs.
28690postlink_cmds=$lt_postlink_cmds
28691
28692# Specify filename containing input files.
28693file_list_spec=$lt_file_list_spec
28694
28695# How to hardcode a shared library path into an executable.
28696hardcode_action=$hardcode_action
28697
28698# ### END LIBTOOL CONFIG
28699
28700_LT_EOF
28701
28702    cat <<'_LT_EOF' >> "$cfgfile"
28703
28704# ### BEGIN FUNCTIONS SHARED WITH CONFIGURE
28705
28706# func_munge_path_list VARIABLE PATH
28707# -----------------------------------
28708# VARIABLE is name of variable containing _space_ separated list of
28709# directories to be munged by the contents of PATH, which is string
28710# having a format:
28711# "DIR[:DIR]:"
28712#       string "DIR[ DIR]" will be prepended to VARIABLE
28713# ":DIR[:DIR]"
28714#       string "DIR[ DIR]" will be appended to VARIABLE
28715# "DIRP[:DIRP]::[DIRA:]DIRA"
28716#       string "DIRP[ DIRP]" will be prepended to VARIABLE and string
28717#       "DIRA[ DIRA]" will be appended to VARIABLE
28718# "DIR[:DIR]"
28719#       VARIABLE will be replaced by "DIR[ DIR]"
28720func_munge_path_list ()
28721{
28722    case x$2 in
28723    x)
28724        ;;
28725    *:)
28726        eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\"
28727        ;;
28728    x:*)
28729        eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\"
28730        ;;
28731    *::*)
28732        eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\"
28733        eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\"
28734        ;;
28735    *)
28736        eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\"
28737        ;;
28738    esac
28739}
28740
28741
28742# Calculate cc_basename.  Skip known compiler wrappers and cross-prefix.
28743func_cc_basename ()
28744{
28745    for cc_temp in $*""; do
28746      case $cc_temp in
28747        compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
28748        distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
28749        \-*) ;;
28750        *) break;;
28751      esac
28752    done
28753    func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
28754}
28755
28756
28757# ### END FUNCTIONS SHARED WITH CONFIGURE
28758
28759_LT_EOF
28760
28761  case $host_os in
28762  aix3*)
28763    cat <<\_LT_EOF >> "$cfgfile"
28764# AIX sometimes has problems with the GCC collect2 program.  For some
28765# reason, if we set the COLLECT_NAMES environment variable, the problems
28766# vanish in a puff of smoke.
28767if test set != "${COLLECT_NAMES+set}"; then
28768  COLLECT_NAMES=
28769  export COLLECT_NAMES
28770fi
28771_LT_EOF
28772    ;;
28773  esac
28774
28775
28776ltmain=$ac_aux_dir/ltmain.sh
28777
28778
28779  # We use sed instead of cat because bash on DJGPP gets confused if
28780  # if finds mixed CR/LF and LF-only lines.  Since sed operates in
28781  # text mode, it properly converts lines to CR/LF.  This bash problem
28782  # is reportedly fixed, but why not run on old versions too?
28783  sed '$q' "$ltmain" >> "$cfgfile" \
28784     || (rm -f "$cfgfile"; exit 1)
28785
28786   mv -f "$cfgfile" "$ofile" ||
28787    (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
28788  chmod +x "$ofile"
28789
28790 ;;
28791
28792  esac
28793done # for ac_tag
28794
28795
28796as_fn_exit 0
28797_ACEOF
28798ac_clean_files=$ac_clean_files_save
28799
28800test $ac_write_fail = 0 ||
28801  as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
28802
28803
28804# configure is writing to config.log, and then calls config.status.
28805# config.status does its own redirection, appending to config.log.
28806# Unfortunately, on DOS this fails, as config.log is still kept open
28807# by configure, so config.status won't be able to write to it; its
28808# output is simply discarded.  So we exec the FD to /dev/null,
28809# effectively closing config.log, so it can be properly (re)opened and
28810# appended to by config.status.  When coming back to configure, we
28811# need to make the FD available again.
28812if test "$no_create" != yes; then
28813  ac_cs_success=:
28814  ac_config_status_args=
28815  test "$silent" = yes &&
28816    ac_config_status_args="$ac_config_status_args --quiet"
28817  exec 5>/dev/null
28818  $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
28819  exec 5>>config.log
28820  # Use ||, not &&, to avoid exiting from the if with $? = 1, which
28821  # would make configure fail if this is the last instruction.
28822  $ac_cs_success || as_fn_exit 1
28823fi
28824
28825#
28826# CONFIG_SUBDIRS section.
28827#
28828if test "$no_recursion" != yes; then
28829
28830  # Remove --cache-file, --srcdir, and --disable-option-checking arguments
28831  # so they do not pile up.
28832  ac_sub_configure_args=
28833  ac_prev=
28834  eval "set x $ac_configure_args"
28835  shift
28836  for ac_arg
28837  do
28838    if test -n "$ac_prev"; then
28839      ac_prev=
28840      continue
28841    fi
28842    case $ac_arg in
28843    -cache-file | --cache-file | --cache-fil | --cache-fi \
28844    | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
28845      ac_prev=cache_file ;;
28846    -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
28847    | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* \
28848    | --c=*)
28849      ;;
28850    --config-cache | -C)
28851      ;;
28852    -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
28853      ac_prev=srcdir ;;
28854    -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
28855      ;;
28856    -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
28857      ac_prev=prefix ;;
28858    -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
28859      ;;
28860    --disable-option-checking)
28861      ;;
28862    *)
28863      case $ac_arg in
28864      *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
28865      esac
28866      as_fn_append ac_sub_configure_args " '$ac_arg'" ;;
28867    esac
28868  done
28869
28870  # Always prepend --prefix to ensure using the same prefix
28871  # in subdir configurations.
28872  ac_arg="--prefix=$prefix"
28873  case $ac_arg in
28874  *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
28875  esac
28876  ac_sub_configure_args="'$ac_arg' $ac_sub_configure_args"
28877
28878  # Pass --silent
28879  if test "$silent" = yes; then
28880    ac_sub_configure_args="--silent $ac_sub_configure_args"
28881  fi
28882
28883  # Always prepend --disable-option-checking to silence warnings, since
28884  # different subdirs can have different --enable and --with options.
28885  ac_sub_configure_args="--disable-option-checking $ac_sub_configure_args"
28886
28887  ac_popdir=`pwd`
28888  for ac_dir in : $subdirs; do test "x$ac_dir" = x: && continue
28889
28890    # Do not complain, so a configure script can configure whichever
28891    # parts of a large source tree are present.
28892    test -d "$srcdir/$ac_dir" || continue
28893
28894    ac_msg="=== configuring in $ac_dir (`pwd`/$ac_dir)"
28895    $as_echo "$as_me:${as_lineno-$LINENO}: $ac_msg" >&5
28896    $as_echo "$ac_msg" >&6
28897    as_dir="$ac_dir"; as_fn_mkdir_p
28898    ac_builddir=.
28899
28900case "$ac_dir" in
28901.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
28902*)
28903  ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
28904  # A ".." for each directory in $ac_dir_suffix.
28905  ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
28906  case $ac_top_builddir_sub in
28907  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
28908  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
28909  esac ;;
28910esac
28911ac_abs_top_builddir=$ac_pwd
28912ac_abs_builddir=$ac_pwd$ac_dir_suffix
28913# for backward compatibility:
28914ac_top_builddir=$ac_top_build_prefix
28915
28916case $srcdir in
28917  .)  # We are building in place.
28918    ac_srcdir=.
28919    ac_top_srcdir=$ac_top_builddir_sub
28920    ac_abs_top_srcdir=$ac_pwd ;;
28921  [\\/]* | ?:[\\/]* )  # Absolute name.
28922    ac_srcdir=$srcdir$ac_dir_suffix;
28923    ac_top_srcdir=$srcdir
28924    ac_abs_top_srcdir=$srcdir ;;
28925  *) # Relative name.
28926    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
28927    ac_top_srcdir=$ac_top_build_prefix$srcdir
28928    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
28929esac
28930ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
28931
28932
28933    cd "$ac_dir"
28934
28935    # Check for guested configure; otherwise get Cygnus style configure.
28936    if test -f "$ac_srcdir/configure.gnu"; then
28937      ac_sub_configure=$ac_srcdir/configure.gnu
28938    elif test -f "$ac_srcdir/configure"; then
28939      ac_sub_configure=$ac_srcdir/configure
28940    elif test -f "$ac_srcdir/configure.in"; then
28941      # This should be Cygnus configure.
28942      ac_sub_configure=$ac_aux_dir/configure
28943    else
28944      { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no configuration information is in $ac_dir" >&5
28945$as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2;}
28946      ac_sub_configure=
28947    fi
28948
28949    # The recursion is here.
28950    if test -n "$ac_sub_configure"; then
28951      # Make the cache file name correct relative to the subdirectory.
28952      case $cache_file in
28953      [\\/]* | ?:[\\/]* ) ac_sub_cache_file=$cache_file ;;
28954      *) # Relative name.
28955	ac_sub_cache_file=$ac_top_build_prefix$cache_file ;;
28956      esac
28957
28958      { $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
28959$as_echo "$as_me: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&6;}
28960      # The eval makes quoting arguments work.
28961      eval "\$SHELL \"\$ac_sub_configure\" $ac_sub_configure_args \
28962	   --cache-file=\"\$ac_sub_cache_file\" --srcdir=\"\$ac_srcdir\"" ||
28963	as_fn_error $? "$ac_sub_configure failed for $ac_dir" "$LINENO" 5
28964    fi
28965
28966    cd "$ac_popdir"
28967  done
28968fi
28969if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
28970  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
28971$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
28972fi
28973
28974