xref: /freebsd/contrib/ntp/configure (revision 190cef3d52236565eb22e18b33e9e865ec634aa3)
1#! /bin/sh
2# Guess values for system-dependent variables and create Makefiles.
3# Generated by GNU Autoconf 2.69 for ntp 4.2.8p12.
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='ntp'
592PACKAGE_TARNAME='ntp'
593PACKAGE_VERSION='4.2.8p12'
594PACKAGE_STRING='ntp 4.2.8p12'
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
639subdirs
640PERLLIBDIR
641NTP_KEYSDIR
642BUILD_TEST_NTP_SIGND_FALSE
643BUILD_TEST_NTP_SIGND_TRUE
644BUILD_TEST_NTP_SCANNER_FALSE
645BUILD_TEST_NTP_SCANNER_TRUE
646BUILD_TEST_NTP_RESTRICT_FALSE
647BUILD_TEST_NTP_RESTRICT_TRUE
648GTEST_AVAILABLE_FALSE
649GTEST_AVAILABLE_TRUE
650GTEST_CPPFLAGS
651GTEST_CXXFLAGS
652GTEST_LIBS
653GTEST_LDFLAGS
654GTEST_CONFIG
655UNITYBUILD_AVAILABLE_FALSE
656UNITYBUILD_AVAILABLE_TRUE
657PATH_RUBY
658HAVE_LEAPSMEARINTERVAL
659SAVECONFIG_ENABLED_FALSE
660SAVECONFIG_ENABLED_TRUE
661LSCF
662MAKE_NTPSNMPD
663SNMP_CFLAGS
664SNMP_CPPFLAGS
665SNMP_LIBS
666BUILD_SNTP_FALSE
667BUILD_SNTP_TRUE
668SNTP
669MAKE_NTPDSIM
670MAKE_LIBNTPSIM
671MAKE_TIMETRIM
672MAKE_TICKADJ
673MAKE_NTPTIME
674MAKE_ADJTIMED
675CHUTEST
676PROPDELAY
677MAKE_PARSEKMODULE
678DCFD
679TESTDCF
680MAKE_CHECK_LAYOUT
681VER_SUFFIX
682MAKE_CHECK_Y2K
683MAKE_LIBPARSE_KERNEL
684MAKE_LIBPARSE
685LIBPARSE
686HAVE_RLIMIT_STACK
687HAVE_RLIMIT_MEMLOCK
688LDADD_NLIST
689PATH_NET_SNMP_CONFIG
690CONFIG_SHELL
691PATH_TEST
692PATH_PERL
693LIBOBJS
694PTHREADS_FALSE
695PTHREADS_TRUE
696LIBISC_PTHREADS_NOTHREADS
697PTHREAD_LIBS
698LTHREAD_LIBS
699BUILD_THREAD
700HAVE_INLINE
701LDADD_LIBUTIL
702ALLOCA
703LIBM
704EDITLINE_LIBS
705LDADD_LIBNTP
706NTP_CROSSCOMPILE_FALSE
707NTP_CROSSCOMPILE_TRUE
708BUILD_LIBEVENT_FALSE
709BUILD_LIBEVENT_TRUE
710LDADD_LIBEVENT
711CPPFLAGS_LIBEVENT
712CFLAGS_LIBEVENT
713PKG_CONFIG
714LIBOPTS_DIR
715LIBOPTS_CFLAGS
716LIBOPTS_LDADD
717NEED_LIBOPTS_FALSE
718NEED_LIBOPTS_TRUE
719INSTALL_LIBOPTS_FALSE
720INSTALL_LIBOPTS_TRUE
721POSIX_SHELL
722GL_GENERATE_STDNORETURN_H_FALSE
723GL_GENERATE_STDNORETURN_H_TRUE
724STDNORETURN_H
725LIBTOOL_DEPS
726LT_SYS_LIBRARY_PATH
727OTOOL64
728OTOOL
729LIPO
730NMEDIT
731DSYMUTIL
732MANIFEST_TOOL
733RANLIB
734DLLTOOL
735OBJDUMP
736LN_S
737NM
738ac_ct_DUMPBIN
739DUMPBIN
740LD
741FGREP
742SED
743LIBTOOL
744ac_ct_AR
745AR
746INSTALL_UPDATE_LEAP_FALSE
747INSTALL_UPDATE_LEAP_TRUE
748UPDATE_LEAP_NI
749UPDATE_LEAP_MS
750UPDATE_LEAP_DS
751UPDATE_LEAP_DL
752UPDATE_LEAP_DB
753TIMETRIM_NI
754TIMETRIM_MS
755TIMETRIM_DS
756TIMETRIM_DL
757TIMETRIM_DB
758TICKADJ_NI
759TICKADJ_MS
760TICKADJ_DS
761TICKADJ_DL
762TICKADJ_DB
763SNTP_NI
764SNTP_MS
765SNTP_DS
766SNTP_DL
767SNTP_DB
768NTP_WAIT_NI
769NTP_WAIT_MS
770NTP_WAIT_DS
771NTP_WAIT_DL
772NTP_WAIT_DB
773NTP_KEYGEN_NI
774NTP_KEYGEN_MS
775NTP_KEYGEN_DS
776NTP_KEYGEN_DL
777NTP_KEYGEN_DB
778NTPTRACE_NI
779NTPTRACE_MS
780NTPTRACE_DS
781NTPTRACE_DL
782NTPTRACE_DB
783NTPTIME_NI
784NTPTIME_MS
785NTPTIME_DS
786NTPTIME_DL
787NTPTIME_DB
788INSTALL_NTPSWEEP_FALSE
789INSTALL_NTPSWEEP_TRUE
790NTPSWEEP_NI
791NTPSWEEP_MS
792NTPSWEEP_DS
793NTPSWEEP_DL
794NTPSWEEP_DB
795NTPSNMPD_NI
796NTPSNMPD_MS
797NTPSNMPD_DS
798NTPSNMPD_DL
799NTPSNMPD_DB
800NTPQ_NI
801NTPQ_MS
802NTPQ_DS
803NTPQ_DL
804NTPQ_DB
805NTPD_NI
806NTPD_MS
807NTPD_DS
808NTPD_DL
809NTPD_DB
810NTPDSIM_NI
811NTPDSIM_MS
812NTPDSIM_DS
813NTPDSIM_DL
814NTPDSIM_DB
815NTPDC_NI
816NTPDC_MS
817NTPDC_DS
818NTPDC_DL
819NTPDC_DB
820NTPDATE_NI
821NTPDATE_MS
822NTPDATE_DS
823NTPDATE_DL
824NTPDATE_DB
825MANTAGFMT
826CALC_TICKADJ_NI
827CALC_TICKADJ_MS
828CALC_TICKADJ_DS
829CALC_TICKADJ_DL
830CALC_TICKADJ_DB
831WANT_CALC_TICKADJ_MS_FALSE
832WANT_CALC_TICKADJ_MS_TRUE
833VPATH_HACK_FALSE
834VPATH_HACK_TRUE
835NTP_HARD_LDFLAGS
836NTP_HARD_CPPFLAGS
837NTP_HARD_CFLAGS
838YFLAGS
839YACC
840LDFLAGS_NTP
841LDADD_NTP
842CPPFLAGS_NTP
843CFLAGS_NTP
844EGREP
845GREP
846CPP
847am__fastdepCC_FALSE
848am__fastdepCC_TRUE
849CCDEPMODE
850am__nodep
851AMDEPBACKSLASH
852AMDEP_FALSE
853AMDEP_TRUE
854am__quote
855am__include
856DEPDIR
857OBJEXT
858EXEEXT
859ac_ct_CC
860CPPFLAGS
861LDFLAGS
862CFLAGS
863CC
864host_os
865host_vendor
866host_cpu
867host
868build_os
869build_vendor
870build_cpu
871build
872AM_BACKSLASH
873AM_DEFAULT_VERBOSITY
874AM_DEFAULT_V
875AM_V
876am__untar
877am__tar
878AMTAR
879am__leading_dot
880SET_MAKE
881AWK
882mkdir_p
883MKDIR_P
884INSTALL_STRIP_PROGRAM
885STRIP
886install_sh
887MAKEINFO
888AUTOHEADER
889AUTOMAKE
890AUTOCONF
891ACLOCAL
892VERSION
893PACKAGE
894CYGPATH_W
895am__isrc
896INSTALL_DATA
897INSTALL_SCRIPT
898INSTALL_PROGRAM
899target_alias
900host_alias
901build_alias
902LIBS
903ECHO_T
904ECHO_N
905ECHO_C
906DEFS
907mandir
908localedir
909libdir
910psdir
911pdfdir
912dvidir
913htmldir
914infodir
915docdir
916oldincludedir
917includedir
918localstatedir
919sharedstatedir
920sysconfdir
921datadir
922datarootdir
923libexecdir
924sbindir
925bindir
926program_transform_name
927prefix
928exec_prefix
929PACKAGE_URL
930PACKAGE_BUGREPORT
931PACKAGE_STRING
932PACKAGE_VERSION
933PACKAGE_TARNAME
934PACKAGE_NAME
935PATH_SEPARATOR
936SHELL'
937ac_subst_files='calc_tickadj_opts
938ntp_wait_opts
939ntpsweep_opts
940ntptrace_opts
941summary_opts
942plot_summary_opts'
943ac_user_opts='
944enable_option_checking
945enable_silent_rules
946enable_dependency_tracking
947with_hardenfile
948with_locfile
949enable_shared
950enable_static
951with_pic
952enable_fast_install
953with_aix_soname
954with_gnu_ld
955with_sysroot
956enable_libtool_lock
957enable_nls
958enable_local_libopts
959enable_libopts_install
960with_autoopts_config
961enable_local_libevent
962with_lineeditlibs
963enable_debugging
964enable_thread_support
965with_threads
966with_yielding_select
967enable_c99_snprintf
968enable_clockctl
969enable_linuxcaps
970enable_solarisprivs
971enable_trustedbsd_mac
972with_arlib
973with_net_snmp_config
974enable_libseccomp
975with_stack_limit
976with_memlock
977enable_debug_timing
978enable_dst_minutes
979enable_ignore_dns_errors
980enable_BANCOMM
981enable_GPSVME
982enable_all_clocks
983enable_ACTS
984enable_ARBITER
985enable_ARCRON_MSF
986enable_AS2201
987enable_ATOM
988enable_CHRONOLOG
989enable_CHU
990enable_AUDIO_CHU
991enable_DATUM
992enable_DUMBCLOCK
993enable_FG
994enable_HEATH
995enable_HOPFSERIAL
996enable_HOPFPCI
997enable_HPGPS
998enable_IRIG
999enable_JJY
1000enable_JUPITER
1001enable_LEITCH
1002enable_LOCAL_CLOCK
1003enable_MX4200
1004enable_NEOCLOCK4X
1005enable_NMEA
1006enable_GPSD
1007enable_ONCORE
1008enable_PALISADE
1009enable_PCF
1010enable_PST
1011enable_RIPENCC
1012enable_SHM
1013enable_SPECTRACOM
1014enable_TPRO
1015enable_TRUETIME
1016enable_TT560
1017enable_ULINK
1018enable_TSYNCPCI
1019enable_WWV
1020enable_ZYFER
1021enable_parse_clocks
1022enable_COMPUTIME
1023enable_DCF7000
1024enable_HOPF6021
1025enable_MEINBERG
1026enable_RAWDCF
1027enable_RCC8000
1028enable_SCHMID
1029enable_TRIMTAIP
1030enable_TRIMTSIP
1031enable_WHARTON
1032enable_VARITEXT
1033enable_SEL240X
1034with_crypto
1035with_openssl_libdir
1036with_openssl_incdir
1037with_rpath
1038enable_openssl_random
1039enable_autokey
1040enable_kmem
1041enable_accurate_adjtime
1042enable_tick
1043enable_tickadj
1044enable_simulator
1045with_sntp
1046with_ntpsnmpd
1047enable_slew_always
1048enable_step_slew
1049enable_ntpdate_step
1050enable_hourly_todr_sync
1051enable_kernel_fll_bug
1052enable_bug1243_fix
1053enable_bug3020_fix
1054enable_irig_sawtooth
1055enable_nist
1056enable_ntp_signd
1057enable_ipv6
1058with_kame
1059enable_getifaddrs
1060enable_saveconfig
1061enable_leap_smear
1062enable_dynamic_interleave
1063with_gtest
1064enable_problem_tests
1065'
1066      ac_precious_vars='build_alias
1067host_alias
1068target_alias
1069CC
1070CFLAGS
1071LDFLAGS
1072LIBS
1073CPPFLAGS
1074CPP
1075YACC
1076YFLAGS
1077LT_SYS_LIBRARY_PATH'
1078ac_subdirs_all='sntp'
1079
1080# Initialize some variables set by options.
1081ac_init_help=
1082ac_init_version=false
1083ac_unrecognized_opts=
1084ac_unrecognized_sep=
1085# The variables have the same names as the options, with
1086# dashes changed to underlines.
1087cache_file=/dev/null
1088exec_prefix=NONE
1089no_create=
1090no_recursion=
1091prefix=NONE
1092program_prefix=NONE
1093program_suffix=NONE
1094program_transform_name=s,x,x,
1095silent=
1096site=
1097srcdir=
1098verbose=
1099x_includes=NONE
1100x_libraries=NONE
1101
1102# Installation directory options.
1103# These are left unexpanded so users can "make install exec_prefix=/foo"
1104# and all the variables that are supposed to be based on exec_prefix
1105# by default will actually change.
1106# Use braces instead of parens because sh, perl, etc. also accept them.
1107# (The list follows the same order as the GNU Coding Standards.)
1108bindir='${exec_prefix}/bin'
1109sbindir='${exec_prefix}/sbin'
1110libexecdir='${exec_prefix}/libexec'
1111datarootdir='${prefix}/share'
1112datadir='${datarootdir}'
1113sysconfdir='${prefix}/etc'
1114sharedstatedir='${prefix}/com'
1115localstatedir='${prefix}/var'
1116includedir='${prefix}/include'
1117oldincludedir='/usr/include'
1118docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
1119infodir='${datarootdir}/info'
1120htmldir='${docdir}'
1121dvidir='${docdir}'
1122pdfdir='${docdir}'
1123psdir='${docdir}'
1124libdir='${exec_prefix}/lib'
1125localedir='${datarootdir}/locale'
1126mandir='${datarootdir}/man'
1127
1128ac_prev=
1129ac_dashdash=
1130for ac_option
1131do
1132  # If the previous option needs an argument, assign it.
1133  if test -n "$ac_prev"; then
1134    eval $ac_prev=\$ac_option
1135    ac_prev=
1136    continue
1137  fi
1138
1139  case $ac_option in
1140  *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1141  *=)   ac_optarg= ;;
1142  *)    ac_optarg=yes ;;
1143  esac
1144
1145  # Accept the important Cygnus configure options, so we can diagnose typos.
1146
1147  case $ac_dashdash$ac_option in
1148  --)
1149    ac_dashdash=yes ;;
1150
1151  -bindir | --bindir | --bindi | --bind | --bin | --bi)
1152    ac_prev=bindir ;;
1153  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1154    bindir=$ac_optarg ;;
1155
1156  -build | --build | --buil | --bui | --bu)
1157    ac_prev=build_alias ;;
1158  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1159    build_alias=$ac_optarg ;;
1160
1161  -cache-file | --cache-file | --cache-fil | --cache-fi \
1162  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1163    ac_prev=cache_file ;;
1164  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1165  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1166    cache_file=$ac_optarg ;;
1167
1168  --config-cache | -C)
1169    cache_file=config.cache ;;
1170
1171  -datadir | --datadir | --datadi | --datad)
1172    ac_prev=datadir ;;
1173  -datadir=* | --datadir=* | --datadi=* | --datad=*)
1174    datadir=$ac_optarg ;;
1175
1176  -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1177  | --dataroo | --dataro | --datar)
1178    ac_prev=datarootdir ;;
1179  -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1180  | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1181    datarootdir=$ac_optarg ;;
1182
1183  -disable-* | --disable-*)
1184    ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1185    # Reject names that are not valid shell variable names.
1186    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1187      as_fn_error $? "invalid feature name: $ac_useropt"
1188    ac_useropt_orig=$ac_useropt
1189    ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1190    case $ac_user_opts in
1191      *"
1192"enable_$ac_useropt"
1193"*) ;;
1194      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1195	 ac_unrecognized_sep=', ';;
1196    esac
1197    eval enable_$ac_useropt=no ;;
1198
1199  -docdir | --docdir | --docdi | --doc | --do)
1200    ac_prev=docdir ;;
1201  -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1202    docdir=$ac_optarg ;;
1203
1204  -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1205    ac_prev=dvidir ;;
1206  -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1207    dvidir=$ac_optarg ;;
1208
1209  -enable-* | --enable-*)
1210    ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1211    # Reject names that are not valid shell variable names.
1212    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1213      as_fn_error $? "invalid feature name: $ac_useropt"
1214    ac_useropt_orig=$ac_useropt
1215    ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1216    case $ac_user_opts in
1217      *"
1218"enable_$ac_useropt"
1219"*) ;;
1220      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1221	 ac_unrecognized_sep=', ';;
1222    esac
1223    eval enable_$ac_useropt=\$ac_optarg ;;
1224
1225  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1226  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1227  | --exec | --exe | --ex)
1228    ac_prev=exec_prefix ;;
1229  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1230  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1231  | --exec=* | --exe=* | --ex=*)
1232    exec_prefix=$ac_optarg ;;
1233
1234  -gas | --gas | --ga | --g)
1235    # Obsolete; use --with-gas.
1236    with_gas=yes ;;
1237
1238  -help | --help | --hel | --he | -h)
1239    ac_init_help=long ;;
1240  -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1241    ac_init_help=recursive ;;
1242  -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1243    ac_init_help=short ;;
1244
1245  -host | --host | --hos | --ho)
1246    ac_prev=host_alias ;;
1247  -host=* | --host=* | --hos=* | --ho=*)
1248    host_alias=$ac_optarg ;;
1249
1250  -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1251    ac_prev=htmldir ;;
1252  -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1253  | --ht=*)
1254    htmldir=$ac_optarg ;;
1255
1256  -includedir | --includedir | --includedi | --included | --include \
1257  | --includ | --inclu | --incl | --inc)
1258    ac_prev=includedir ;;
1259  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1260  | --includ=* | --inclu=* | --incl=* | --inc=*)
1261    includedir=$ac_optarg ;;
1262
1263  -infodir | --infodir | --infodi | --infod | --info | --inf)
1264    ac_prev=infodir ;;
1265  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1266    infodir=$ac_optarg ;;
1267
1268  -libdir | --libdir | --libdi | --libd)
1269    ac_prev=libdir ;;
1270  -libdir=* | --libdir=* | --libdi=* | --libd=*)
1271    libdir=$ac_optarg ;;
1272
1273  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1274  | --libexe | --libex | --libe)
1275    ac_prev=libexecdir ;;
1276  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1277  | --libexe=* | --libex=* | --libe=*)
1278    libexecdir=$ac_optarg ;;
1279
1280  -localedir | --localedir | --localedi | --localed | --locale)
1281    ac_prev=localedir ;;
1282  -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1283    localedir=$ac_optarg ;;
1284
1285  -localstatedir | --localstatedir | --localstatedi | --localstated \
1286  | --localstate | --localstat | --localsta | --localst | --locals)
1287    ac_prev=localstatedir ;;
1288  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1289  | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1290    localstatedir=$ac_optarg ;;
1291
1292  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1293    ac_prev=mandir ;;
1294  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1295    mandir=$ac_optarg ;;
1296
1297  -nfp | --nfp | --nf)
1298    # Obsolete; use --without-fp.
1299    with_fp=no ;;
1300
1301  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1302  | --no-cr | --no-c | -n)
1303    no_create=yes ;;
1304
1305  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1306  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1307    no_recursion=yes ;;
1308
1309  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1310  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1311  | --oldin | --oldi | --old | --ol | --o)
1312    ac_prev=oldincludedir ;;
1313  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1314  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1315  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1316    oldincludedir=$ac_optarg ;;
1317
1318  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1319    ac_prev=prefix ;;
1320  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1321    prefix=$ac_optarg ;;
1322
1323  -program-prefix | --program-prefix | --program-prefi | --program-pref \
1324  | --program-pre | --program-pr | --program-p)
1325    ac_prev=program_prefix ;;
1326  -program-prefix=* | --program-prefix=* | --program-prefi=* \
1327  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1328    program_prefix=$ac_optarg ;;
1329
1330  -program-suffix | --program-suffix | --program-suffi | --program-suff \
1331  | --program-suf | --program-su | --program-s)
1332    ac_prev=program_suffix ;;
1333  -program-suffix=* | --program-suffix=* | --program-suffi=* \
1334  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1335    program_suffix=$ac_optarg ;;
1336
1337  -program-transform-name | --program-transform-name \
1338  | --program-transform-nam | --program-transform-na \
1339  | --program-transform-n | --program-transform- \
1340  | --program-transform | --program-transfor \
1341  | --program-transfo | --program-transf \
1342  | --program-trans | --program-tran \
1343  | --progr-tra | --program-tr | --program-t)
1344    ac_prev=program_transform_name ;;
1345  -program-transform-name=* | --program-transform-name=* \
1346  | --program-transform-nam=* | --program-transform-na=* \
1347  | --program-transform-n=* | --program-transform-=* \
1348  | --program-transform=* | --program-transfor=* \
1349  | --program-transfo=* | --program-transf=* \
1350  | --program-trans=* | --program-tran=* \
1351  | --progr-tra=* | --program-tr=* | --program-t=*)
1352    program_transform_name=$ac_optarg ;;
1353
1354  -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1355    ac_prev=pdfdir ;;
1356  -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1357    pdfdir=$ac_optarg ;;
1358
1359  -psdir | --psdir | --psdi | --psd | --ps)
1360    ac_prev=psdir ;;
1361  -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1362    psdir=$ac_optarg ;;
1363
1364  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1365  | -silent | --silent | --silen | --sile | --sil)
1366    silent=yes ;;
1367
1368  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1369    ac_prev=sbindir ;;
1370  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1371  | --sbi=* | --sb=*)
1372    sbindir=$ac_optarg ;;
1373
1374  -sharedstatedir | --sharedstatedir | --sharedstatedi \
1375  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1376  | --sharedst | --shareds | --shared | --share | --shar \
1377  | --sha | --sh)
1378    ac_prev=sharedstatedir ;;
1379  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1380  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1381  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1382  | --sha=* | --sh=*)
1383    sharedstatedir=$ac_optarg ;;
1384
1385  -site | --site | --sit)
1386    ac_prev=site ;;
1387  -site=* | --site=* | --sit=*)
1388    site=$ac_optarg ;;
1389
1390  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1391    ac_prev=srcdir ;;
1392  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1393    srcdir=$ac_optarg ;;
1394
1395  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1396  | --syscon | --sysco | --sysc | --sys | --sy)
1397    ac_prev=sysconfdir ;;
1398  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1399  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1400    sysconfdir=$ac_optarg ;;
1401
1402  -target | --target | --targe | --targ | --tar | --ta | --t)
1403    ac_prev=target_alias ;;
1404  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1405    target_alias=$ac_optarg ;;
1406
1407  -v | -verbose | --verbose | --verbos | --verbo | --verb)
1408    verbose=yes ;;
1409
1410  -version | --version | --versio | --versi | --vers | -V)
1411    ac_init_version=: ;;
1412
1413  -with-* | --with-*)
1414    ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1415    # Reject names that are not valid shell variable names.
1416    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1417      as_fn_error $? "invalid package name: $ac_useropt"
1418    ac_useropt_orig=$ac_useropt
1419    ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1420    case $ac_user_opts in
1421      *"
1422"with_$ac_useropt"
1423"*) ;;
1424      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1425	 ac_unrecognized_sep=', ';;
1426    esac
1427    eval with_$ac_useropt=\$ac_optarg ;;
1428
1429  -without-* | --without-*)
1430    ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1431    # Reject names that are not valid shell variable names.
1432    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1433      as_fn_error $? "invalid package name: $ac_useropt"
1434    ac_useropt_orig=$ac_useropt
1435    ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1436    case $ac_user_opts in
1437      *"
1438"with_$ac_useropt"
1439"*) ;;
1440      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1441	 ac_unrecognized_sep=', ';;
1442    esac
1443    eval with_$ac_useropt=no ;;
1444
1445  --x)
1446    # Obsolete; use --with-x.
1447    with_x=yes ;;
1448
1449  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1450  | --x-incl | --x-inc | --x-in | --x-i)
1451    ac_prev=x_includes ;;
1452  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1453  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1454    x_includes=$ac_optarg ;;
1455
1456  -x-libraries | --x-libraries | --x-librarie | --x-librari \
1457  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1458    ac_prev=x_libraries ;;
1459  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1460  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1461    x_libraries=$ac_optarg ;;
1462
1463  -*) as_fn_error $? "unrecognized option: \`$ac_option'
1464Try \`$0 --help' for more information"
1465    ;;
1466
1467  *=*)
1468    ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1469    # Reject names that are not valid shell variable names.
1470    case $ac_envvar in #(
1471      '' | [0-9]* | *[!_$as_cr_alnum]* )
1472      as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1473    esac
1474    eval $ac_envvar=\$ac_optarg
1475    export $ac_envvar ;;
1476
1477  *)
1478    # FIXME: should be removed in autoconf 3.0.
1479    $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1480    expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1481      $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1482    : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1483    ;;
1484
1485  esac
1486done
1487
1488if test -n "$ac_prev"; then
1489  ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1490  as_fn_error $? "missing argument to $ac_option"
1491fi
1492
1493if test -n "$ac_unrecognized_opts"; then
1494  case $enable_option_checking in
1495    no) ;;
1496    fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1497    *)     $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1498  esac
1499fi
1500
1501# Check all directory arguments for consistency.
1502for ac_var in	exec_prefix prefix bindir sbindir libexecdir datarootdir \
1503		datadir sysconfdir sharedstatedir localstatedir includedir \
1504		oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1505		libdir localedir mandir
1506do
1507  eval ac_val=\$$ac_var
1508  # Remove trailing slashes.
1509  case $ac_val in
1510    */ )
1511      ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1512      eval $ac_var=\$ac_val;;
1513  esac
1514  # Be sure to have absolute directory names.
1515  case $ac_val in
1516    [\\/$]* | ?:[\\/]* )  continue;;
1517    NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1518  esac
1519  as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1520done
1521
1522# There might be people who depend on the old broken behavior: `$host'
1523# used to hold the argument of --host etc.
1524# FIXME: To remove some day.
1525build=$build_alias
1526host=$host_alias
1527target=$target_alias
1528
1529# FIXME: To remove some day.
1530if test "x$host_alias" != x; then
1531  if test "x$build_alias" = x; then
1532    cross_compiling=maybe
1533  elif test "x$build_alias" != "x$host_alias"; then
1534    cross_compiling=yes
1535  fi
1536fi
1537
1538ac_tool_prefix=
1539test -n "$host_alias" && ac_tool_prefix=$host_alias-
1540
1541test "$silent" = yes && exec 6>/dev/null
1542
1543
1544ac_pwd=`pwd` && test -n "$ac_pwd" &&
1545ac_ls_di=`ls -di .` &&
1546ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1547  as_fn_error $? "working directory cannot be determined"
1548test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1549  as_fn_error $? "pwd does not report name of working directory"
1550
1551
1552# Find the source files, if location was not specified.
1553if test -z "$srcdir"; then
1554  ac_srcdir_defaulted=yes
1555  # Try the directory containing this script, then the parent directory.
1556  ac_confdir=`$as_dirname -- "$as_myself" ||
1557$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1558	 X"$as_myself" : 'X\(//\)[^/]' \| \
1559	 X"$as_myself" : 'X\(//\)$' \| \
1560	 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1561$as_echo X"$as_myself" |
1562    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1563	    s//\1/
1564	    q
1565	  }
1566	  /^X\(\/\/\)[^/].*/{
1567	    s//\1/
1568	    q
1569	  }
1570	  /^X\(\/\/\)$/{
1571	    s//\1/
1572	    q
1573	  }
1574	  /^X\(\/\).*/{
1575	    s//\1/
1576	    q
1577	  }
1578	  s/.*/./; q'`
1579  srcdir=$ac_confdir
1580  if test ! -r "$srcdir/$ac_unique_file"; then
1581    srcdir=..
1582  fi
1583else
1584  ac_srcdir_defaulted=no
1585fi
1586if test ! -r "$srcdir/$ac_unique_file"; then
1587  test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1588  as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1589fi
1590ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1591ac_abs_confdir=`(
1592	cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1593	pwd)`
1594# When building in place, set srcdir=.
1595if test "$ac_abs_confdir" = "$ac_pwd"; then
1596  srcdir=.
1597fi
1598# Remove unnecessary trailing slashes from srcdir.
1599# Double slashes in file names in object file debugging info
1600# mess up M-x gdb in Emacs.
1601case $srcdir in
1602*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1603esac
1604for ac_var in $ac_precious_vars; do
1605  eval ac_env_${ac_var}_set=\${${ac_var}+set}
1606  eval ac_env_${ac_var}_value=\$${ac_var}
1607  eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1608  eval ac_cv_env_${ac_var}_value=\$${ac_var}
1609done
1610
1611#
1612# Report the --help message.
1613#
1614if test "$ac_init_help" = "long"; then
1615  # Omit some internal or obsolete options to make the list less imposing.
1616  # This message is too long to be a string in the A/UX 3.1 sh.
1617  cat <<_ACEOF
1618\`configure' configures ntp 4.2.8p12 to adapt to many kinds of systems.
1619
1620Usage: $0 [OPTION]... [VAR=VALUE]...
1621
1622To assign environment variables (e.g., CC, CFLAGS...), specify them as
1623VAR=VALUE.  See below for descriptions of some of the useful variables.
1624
1625Defaults for the options are specified in brackets.
1626
1627Configuration:
1628  -h, --help              display this help and exit
1629      --help=short        display options specific to this package
1630      --help=recursive    display the short help of all the included packages
1631  -V, --version           display version information and exit
1632  -q, --quiet, --silent   do not print \`checking ...' messages
1633      --cache-file=FILE   cache test results in FILE [disabled]
1634  -C, --config-cache      alias for \`--cache-file=config.cache'
1635  -n, --no-create         do not create output files
1636      --srcdir=DIR        find the sources in DIR [configure dir or \`..']
1637
1638Installation directories:
1639  --prefix=PREFIX         install architecture-independent files in PREFIX
1640                          [$ac_default_prefix]
1641  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
1642                          [PREFIX]
1643
1644By default, \`make install' will install all the files in
1645\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
1646an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1647for instance \`--prefix=\$HOME'.
1648
1649For better control, use the options below.
1650
1651Fine tuning of the installation directories:
1652  --bindir=DIR            user executables [EPREFIX/bin]
1653  --sbindir=DIR           system admin executables [EPREFIX/sbin]
1654  --libexecdir=DIR        program executables [EPREFIX/libexec]
1655  --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
1656  --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
1657  --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
1658  --libdir=DIR            object code libraries [EPREFIX/lib]
1659  --includedir=DIR        C header files [PREFIX/include]
1660  --oldincludedir=DIR     C header files for non-gcc [/usr/include]
1661  --datarootdir=DIR       read-only arch.-independent data root [PREFIX/share]
1662  --datadir=DIR           read-only architecture-independent data [DATAROOTDIR]
1663  --infodir=DIR           info documentation [DATAROOTDIR/info]
1664  --localedir=DIR         locale-dependent data [DATAROOTDIR/locale]
1665  --mandir=DIR            man documentation [DATAROOTDIR/man]
1666  --docdir=DIR            documentation root [DATAROOTDIR/doc/ntp]
1667  --htmldir=DIR           html documentation [DOCDIR]
1668  --dvidir=DIR            dvi documentation [DOCDIR]
1669  --pdfdir=DIR            pdf documentation [DOCDIR]
1670  --psdir=DIR             ps documentation [DOCDIR]
1671_ACEOF
1672
1673  cat <<\_ACEOF
1674
1675Program names:
1676  --program-prefix=PREFIX            prepend PREFIX to installed program names
1677  --program-suffix=SUFFIX            append SUFFIX to installed program names
1678  --program-transform-name=PROGRAM   run sed PROGRAM on installed program names
1679
1680System types:
1681  --build=BUILD     configure for building on BUILD [guessed]
1682  --host=HOST       cross-compile to build programs to run on HOST [BUILD]
1683_ACEOF
1684fi
1685
1686if test -n "$ac_init_help"; then
1687  case $ac_init_help in
1688     short | recursive ) echo "Configuration of ntp 4.2.8p12:";;
1689   esac
1690  cat <<\_ACEOF
1691
1692Optional Features and Packages:
1693  --disable-option-checking  ignore unrecognized --enable/--with options
1694  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1695  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1696  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1697  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1698  --enable-silent-rules   less verbose build output (undo: "make V=1")
1699  --disable-silent-rules  verbose build output (undo: "make V=0")
1700  --enable-dependency-tracking
1701                          do not reject slow dependency extractors
1702  --disable-dependency-tracking
1703                          speeds up one-time build
1704  --with-hardenfile=XXX   os-specific or "/dev/null"
1705  --with-locfile=XXX      os-specific or "legacy"
1706  --enable-shared[=PKGS]  build shared libraries [default=no]
1707  --enable-static[=PKGS]  build static libraries [default=yes]
1708  --with-pic[=PKGS]       try to use only PIC/non-PIC objects [default=use
1709                          both]
1710  --enable-fast-install[=PKGS]
1711                          optimize for fast installation [default=yes]
1712  --with-aix-soname=aix|svr4|both
1713                          shared library versioning (aka "SONAME") variant to
1714                          provide on AIX, [default=aix].
1715  --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
1716  --with-sysroot[=DIR]    Search for dependent libraries within DIR (or the
1717                          compiler's sysroot if not specified).
1718  --disable-libtool-lock  avoid locking (might break parallel builds)
1719  --disable-nls           disable nls support in libopts
1720  --enable-local-libopts  Use the supplied libopts tearoff code
1721  --enable-libopts-install
1722                          Install libopts with client installation
1723  --with-autoopts-config  specify the config-info script
1724  --enable-local-libevent Force using the supplied libevent tearoff code
1725  --with-lineeditlibs     edit,editline (readline may be specified if desired)
1726  defaults:               + yes, - no, s system-specific
1727  --enable-debugging      + include ntpd debugging code
1728  --enable-thread-support s use threads (+ if available)
1729  --with-threads	  with threads [auto]
1730  --with-yielding-select  with yielding select [auto]
1731  --enable-c99-snprintf   s force replacement
1732  --enable-clockctl       s Use /dev/clockctl for non-root clock control
1733  --enable-linuxcaps      + Use Linux capabilities for non-root clock control
1734  --enable-solarisprivs   + Use Solaris privileges for non-root clock control
1735  --enable-trustedbsd-mac s Use TrustedBSD MAC policy for non-root clock
1736                          control
1737  --with-arlib            - deprecated, arlib not distributed
1738  --with-net-snmp-config  + =net-snmp-config
1739  --enable-libseccomp     EXPERIMENTAL: enable support for libseccomp
1740                          sandboxing (default is no)
1741  --with-stack-limit      ? =50 (200 for openbsd) 4k pages
1742  --with-memlock          ? =32 (-1 on linux) megabytes
1743  --enable-debug-timing   - include processing time debugging code (costs
1744                          performance)
1745  --enable-dst-minutes    =60 minutes per DST adjustment
1746  --enable-ignore-dns-errors
1747                          - retry DNS queries on any error
1748  --enable-BANCOMM        - Datum/Bancomm bc635/VME interface
1749  --enable-GPSVME         - TrueTime GPS receiver/VME interface
1750  --enable-all-clocks     + include all suitable non-PARSE clocks:
1751  --enable-ACTS           s ACTS modem service
1752  --enable-ARBITER        + Arbiter 1088A/B GPS receiver
1753  --enable-ARCRON-MSF     + Arcron MSF receiver
1754  --enable-AS2201         + Austron 2200A/2201A GPS receiver
1755  --enable-ATOM           s ATOM PPS interface
1756  --enable-CHRONOLOG      + Chrono-log K-series WWVB receiver
1757  --enable-CHU            + CHU modem/decoder
1758  --enable-AUDIO-CHU      s CHU audio/decoder
1759  --enable-DATUM          s Datum Programmable Time System
1760  --enable-DUMBCLOCK      + Dumb generic hh:mm:ss local clock
1761  --enable-FG             + Forum Graphic GPS
1762  --enable-HEATH          s Heath GC-1000 WWV/WWVH receiver
1763  --enable-HOPFSERIAL     + hopf serial clock device
1764  --enable-HOPFPCI        + hopf 6039 PCI board
1765  --enable-HPGPS          + HP 58503A GPS receiver
1766  --enable-IRIG           s IRIG audio decoder
1767  --enable-JJY            + JJY receiver
1768  --enable-JUPITER        s Rockwell Jupiter GPS receiver
1769  --enable-LEITCH         + Leitch CSD 5300 Master Clock System Driver
1770  --enable-LOCAL-CLOCK    + local clock reference
1771  --enable-MX4200         s Magnavox MX4200 GPS receiver
1772  --enable-NEOCLOCK4X     + NeoClock4X DCF77 / TDF receiver
1773  --enable-NMEA           + NMEA GPS receiver
1774  --enable-GPSD           + GPSD JSON receiver
1775  --enable-ONCORE         s Motorola VP/UT Oncore GPS receiver
1776  --enable-PALISADE       s Palisade clock
1777  --enable-PCF            + Conrad parallel port radio clock
1778  --enable-PST            + PST/Traconex 1020 WWV/WWVH receiver
1779  --enable-RIPENCC        - RIPENCC specific Trimble driver
1780  --enable-SHM            s SHM clock attached thru shared memory
1781  --enable-SPECTRACOM     + Spectracom 8170/Netclock/2 WWVB receiver
1782  --enable-TPRO           s KSI/Odetics TPRO/S GPS receiver/IRIG interface
1783  --enable-TRUETIME       s Kinemetrics/TrueTime receivers
1784  --enable-TT560          - TrueTime 560 IRIG-B decoder
1785  --enable-ULINK          + Ultralink WWVB receiver
1786  --enable-TSYNCPCI       s Spectracom TSYNC timing board
1787  --enable-WWV            s WWV Audio receiver
1788  --enable-ZYFER          + Zyfer GPStarplus receiver
1789  --enable-parse-clocks   - include all suitable PARSE clocks:
1790  --enable-COMPUTIME      s Diem Computime Radio Clock
1791  --enable-DCF7000        s ELV/DCF7000 clock
1792  --enable-HOPF6021       s HOPF 6021 clock
1793  --enable-MEINBERG       s Meinberg clocks
1794  --enable-RAWDCF         s DCF77 raw time code
1795  --enable-RCC8000        s RCC 8000 clock
1796  --enable-SCHMID         s Schmid DCF77 clock
1797  --enable-TRIMTAIP       s Trimble GPS receiver/TAIP protocol
1798  --enable-TRIMTSIP       s Trimble GPS receiver/TSIP protocol
1799  --enable-WHARTON        s WHARTON 400A Series clock
1800  --enable-VARITEXT       s VARITEXT clock
1801  --enable-SEL240X        s SEL240X clock
1802  --with-crypto           + =openssl,libcrypto
1803
1804  --with-openssl-libdir   + =/something/reasonable
1805
1806  --with-openssl-incdir   + =/something/reasonable
1807
1808  --without-rpath         s Disable auto-added -R linker paths
1809
1810  --enable-openssl-random Use OpenSSL's crypto random number functions, if
1811                          available (default is yes)
1812  --enable-autokey        + support NTP Autokey protocol
1813  --enable-kmem           s read /dev/kmem for tick and/or tickadj
1814  --enable-accurate-adjtime
1815                          s the adjtime() call is accurate
1816  --enable-tick=VALUE     s force a value for 'tick'
1817  --enable-tickadj=VALUE  s force a value for 'tickadj'
1818  --enable-simulator      - build/install the NTPD simulator?
1819  --without-sntp          - disable building sntp and sntp/tests
1820  --with-ntpsnmpd         s Build ntpsnmpd MIB agent?
1821  --enable-slew-always    s always slew the time
1822  --enable-step-slew      s step and slew the time
1823  --enable-ntpdate-step   s if ntpdate should step the time
1824  --enable-hourly-todr-sync
1825                          s if we should sync TODR hourly
1826  --enable-kernel-fll-bug s if we should avoid a kernel FLL bug
1827  --enable-bug1243-fix    + use unmodified autokey session keys
1828  --enable-bug3020-fix    + Provide the explicit 127.0.0.0/8 martian filter
1829  --enable-irig-sawtooth  s if we should enable the IRIG sawtooth filter
1830  --enable-nist           - if we should enable the NIST lockclock scheme
1831  --enable-ntp-signd      - Provide support for Samba's signing daemon,
1832                          =/var/run/ntp_signd
1833  --enable-ipv6           s use IPv6?
1834
1835  --with-kame             - =/usr/local/v6
1836  --enable-getifaddrs     + Enable the use of getifaddrs() [[yes|no]].
1837  --enable-saveconfig     + saveconfig mechanism
1838  --enable-leap-smear     - experimental leap smear code
1839  --enable-dynamic-interleave
1840                          - dynamic interleave support
1841  --with-gtest            Use the gtest framework (Default: if it's available)
1842  --enable-problem-tests  + enable tests with undiagnosed problems
1843
1844Some influential environment variables:
1845  CC          C compiler command
1846  CFLAGS      C compiler flags
1847  LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1848              nonstandard directory <lib dir>
1849  LIBS        libraries to pass to the linker, e.g. -l<library>
1850  CPPFLAGS    (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
1851              you have headers in a nonstandard directory <include dir>
1852  CPP         C preprocessor
1853  YACC        The `Yet Another Compiler Compiler' implementation to use.
1854              Defaults to the first program found out of: `bison -y', `byacc',
1855              `yacc'.
1856  YFLAGS      The list of arguments that will be passed by default to $YACC.
1857              This script will default YFLAGS to the empty string to avoid a
1858              default value of `-d' given by some make applications.
1859  LT_SYS_LIBRARY_PATH
1860              User-defined run-time library search path.
1861
1862Use these variables to override the choices made by `configure' or to help
1863it to find libraries and programs with nonstandard names/locations.
1864
1865Report bugs to <http://bugs.ntp.org./>.
1866ntp home page: <http://www.ntp.org./>.
1867_ACEOF
1868ac_status=$?
1869fi
1870
1871if test "$ac_init_help" = "recursive"; then
1872  # If there are subdirs, report their specific --help.
1873  for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1874    test -d "$ac_dir" ||
1875      { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1876      continue
1877    ac_builddir=.
1878
1879case "$ac_dir" in
1880.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1881*)
1882  ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1883  # A ".." for each directory in $ac_dir_suffix.
1884  ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1885  case $ac_top_builddir_sub in
1886  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1887  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1888  esac ;;
1889esac
1890ac_abs_top_builddir=$ac_pwd
1891ac_abs_builddir=$ac_pwd$ac_dir_suffix
1892# for backward compatibility:
1893ac_top_builddir=$ac_top_build_prefix
1894
1895case $srcdir in
1896  .)  # We are building in place.
1897    ac_srcdir=.
1898    ac_top_srcdir=$ac_top_builddir_sub
1899    ac_abs_top_srcdir=$ac_pwd ;;
1900  [\\/]* | ?:[\\/]* )  # Absolute name.
1901    ac_srcdir=$srcdir$ac_dir_suffix;
1902    ac_top_srcdir=$srcdir
1903    ac_abs_top_srcdir=$srcdir ;;
1904  *) # Relative name.
1905    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1906    ac_top_srcdir=$ac_top_build_prefix$srcdir
1907    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1908esac
1909ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1910
1911    cd "$ac_dir" || { ac_status=$?; continue; }
1912    # Check for guested configure.
1913    if test -f "$ac_srcdir/configure.gnu"; then
1914      echo &&
1915      $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1916    elif test -f "$ac_srcdir/configure"; then
1917      echo &&
1918      $SHELL "$ac_srcdir/configure" --help=recursive
1919    else
1920      $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1921    fi || ac_status=$?
1922    cd "$ac_pwd" || { ac_status=$?; break; }
1923  done
1924fi
1925
1926test -n "$ac_init_help" && exit $ac_status
1927if $ac_init_version; then
1928  cat <<\_ACEOF
1929ntp configure 4.2.8p12
1930generated by GNU Autoconf 2.69
1931
1932Copyright (C) 2012 Free Software Foundation, Inc.
1933This configure script is free software; the Free Software Foundation
1934gives unlimited permission to copy, distribute and modify it.
1935_ACEOF
1936  exit
1937fi
1938
1939## ------------------------ ##
1940## Autoconf initialization. ##
1941## ------------------------ ##
1942
1943# ac_fn_c_try_compile LINENO
1944# --------------------------
1945# Try to compile conftest.$ac_ext, and return whether this succeeded.
1946ac_fn_c_try_compile ()
1947{
1948  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1949  rm -f conftest.$ac_objext
1950  if { { ac_try="$ac_compile"
1951case "(($ac_try" in
1952  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1953  *) ac_try_echo=$ac_try;;
1954esac
1955eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1956$as_echo "$ac_try_echo"; } >&5
1957  (eval "$ac_compile") 2>conftest.err
1958  ac_status=$?
1959  if test -s conftest.err; then
1960    grep -v '^ *+' conftest.err >conftest.er1
1961    cat conftest.er1 >&5
1962    mv -f conftest.er1 conftest.err
1963  fi
1964  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1965  test $ac_status = 0; } && {
1966	 test -z "$ac_c_werror_flag" ||
1967	 test ! -s conftest.err
1968       } && test -s conftest.$ac_objext; then :
1969  ac_retval=0
1970else
1971  $as_echo "$as_me: failed program was:" >&5
1972sed 's/^/| /' conftest.$ac_ext >&5
1973
1974	ac_retval=1
1975fi
1976  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1977  as_fn_set_status $ac_retval
1978
1979} # ac_fn_c_try_compile
1980
1981# ac_fn_c_try_cpp LINENO
1982# ----------------------
1983# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1984ac_fn_c_try_cpp ()
1985{
1986  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1987  if { { ac_try="$ac_cpp conftest.$ac_ext"
1988case "(($ac_try" in
1989  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1990  *) ac_try_echo=$ac_try;;
1991esac
1992eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1993$as_echo "$ac_try_echo"; } >&5
1994  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1995  ac_status=$?
1996  if test -s conftest.err; then
1997    grep -v '^ *+' conftest.err >conftest.er1
1998    cat conftest.er1 >&5
1999    mv -f conftest.er1 conftest.err
2000  fi
2001  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2002  test $ac_status = 0; } > conftest.i && {
2003	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2004	 test ! -s conftest.err
2005       }; then :
2006  ac_retval=0
2007else
2008  $as_echo "$as_me: failed program was:" >&5
2009sed 's/^/| /' conftest.$ac_ext >&5
2010
2011    ac_retval=1
2012fi
2013  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2014  as_fn_set_status $ac_retval
2015
2016} # ac_fn_c_try_cpp
2017
2018# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
2019# -------------------------------------------------------
2020# Tests whether HEADER exists, giving a warning if it cannot be compiled using
2021# the include files in INCLUDES and setting the cache variable VAR
2022# accordingly.
2023ac_fn_c_check_header_mongrel ()
2024{
2025  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2026  if eval \${$3+:} false; then :
2027  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2028$as_echo_n "checking for $2... " >&6; }
2029if eval \${$3+:} false; then :
2030  $as_echo_n "(cached) " >&6
2031fi
2032eval ac_res=\$$3
2033	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2034$as_echo "$ac_res" >&6; }
2035else
2036  # Is the header compilable?
2037{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2038$as_echo_n "checking $2 usability... " >&6; }
2039cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2040/* end confdefs.h.  */
2041$4
2042#include <$2>
2043_ACEOF
2044if ac_fn_c_try_compile "$LINENO"; then :
2045  ac_header_compiler=yes
2046else
2047  ac_header_compiler=no
2048fi
2049rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2050{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2051$as_echo "$ac_header_compiler" >&6; }
2052
2053# Is the header present?
2054{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2055$as_echo_n "checking $2 presence... " >&6; }
2056cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2057/* end confdefs.h.  */
2058#include <$2>
2059_ACEOF
2060if ac_fn_c_try_cpp "$LINENO"; then :
2061  ac_header_preproc=yes
2062else
2063  ac_header_preproc=no
2064fi
2065rm -f conftest.err conftest.i conftest.$ac_ext
2066{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2067$as_echo "$ac_header_preproc" >&6; }
2068
2069# So?  What about this header?
2070case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
2071  yes:no: )
2072    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2073$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2074    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2075$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2076    ;;
2077  no:yes:* )
2078    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2079$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2080    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     check for missing prerequisite headers?" >&5
2081$as_echo "$as_me: WARNING: $2:     check for missing prerequisite headers?" >&2;}
2082    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2083$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2084    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&5
2085$as_echo "$as_me: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&2;}
2086    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2087$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2088( $as_echo "## ------------------------------------ ##
2089## Report this to http://bugs.ntp.org./ ##
2090## ------------------------------------ ##"
2091     ) | sed "s/^/$as_me: WARNING:     /" >&2
2092    ;;
2093esac
2094  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2095$as_echo_n "checking for $2... " >&6; }
2096if eval \${$3+:} false; then :
2097  $as_echo_n "(cached) " >&6
2098else
2099  eval "$3=\$ac_header_compiler"
2100fi
2101eval ac_res=\$$3
2102	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2103$as_echo "$ac_res" >&6; }
2104fi
2105  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2106
2107} # ac_fn_c_check_header_mongrel
2108
2109# ac_fn_c_try_run LINENO
2110# ----------------------
2111# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2112# that executables *can* be run.
2113ac_fn_c_try_run ()
2114{
2115  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2116  if { { ac_try="$ac_link"
2117case "(($ac_try" in
2118  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2119  *) ac_try_echo=$ac_try;;
2120esac
2121eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2122$as_echo "$ac_try_echo"; } >&5
2123  (eval "$ac_link") 2>&5
2124  ac_status=$?
2125  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2126  test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2127  { { case "(($ac_try" in
2128  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2129  *) ac_try_echo=$ac_try;;
2130esac
2131eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2132$as_echo "$ac_try_echo"; } >&5
2133  (eval "$ac_try") 2>&5
2134  ac_status=$?
2135  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2136  test $ac_status = 0; }; }; then :
2137  ac_retval=0
2138else
2139  $as_echo "$as_me: program exited with status $ac_status" >&5
2140       $as_echo "$as_me: failed program was:" >&5
2141sed 's/^/| /' conftest.$ac_ext >&5
2142
2143       ac_retval=$ac_status
2144fi
2145  rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2146  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2147  as_fn_set_status $ac_retval
2148
2149} # ac_fn_c_try_run
2150
2151# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2152# -------------------------------------------------------
2153# Tests whether HEADER exists and can be compiled using the include files in
2154# INCLUDES, setting the cache variable VAR accordingly.
2155ac_fn_c_check_header_compile ()
2156{
2157  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2158  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2159$as_echo_n "checking for $2... " >&6; }
2160if eval \${$3+:} false; then :
2161  $as_echo_n "(cached) " >&6
2162else
2163  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2164/* end confdefs.h.  */
2165$4
2166#include <$2>
2167_ACEOF
2168if ac_fn_c_try_compile "$LINENO"; then :
2169  eval "$3=yes"
2170else
2171  eval "$3=no"
2172fi
2173rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2174fi
2175eval ac_res=\$$3
2176	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2177$as_echo "$ac_res" >&6; }
2178  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2179
2180} # ac_fn_c_check_header_compile
2181
2182# ac_fn_c_try_link LINENO
2183# -----------------------
2184# Try to link conftest.$ac_ext, and return whether this succeeded.
2185ac_fn_c_try_link ()
2186{
2187  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2188  rm -f conftest.$ac_objext conftest$ac_exeext
2189  if { { ac_try="$ac_link"
2190case "(($ac_try" in
2191  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2192  *) ac_try_echo=$ac_try;;
2193esac
2194eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2195$as_echo "$ac_try_echo"; } >&5
2196  (eval "$ac_link") 2>conftest.err
2197  ac_status=$?
2198  if test -s conftest.err; then
2199    grep -v '^ *+' conftest.err >conftest.er1
2200    cat conftest.er1 >&5
2201    mv -f conftest.er1 conftest.err
2202  fi
2203  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2204  test $ac_status = 0; } && {
2205	 test -z "$ac_c_werror_flag" ||
2206	 test ! -s conftest.err
2207       } && test -s conftest$ac_exeext && {
2208	 test "$cross_compiling" = yes ||
2209	 test -x conftest$ac_exeext
2210       }; then :
2211  ac_retval=0
2212else
2213  $as_echo "$as_me: failed program was:" >&5
2214sed 's/^/| /' conftest.$ac_ext >&5
2215
2216	ac_retval=1
2217fi
2218  # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2219  # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2220  # interfere with the next link command; also delete a directory that is
2221  # left behind by Apple's compiler.  We do this before executing the actions.
2222  rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2223  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2224  as_fn_set_status $ac_retval
2225
2226} # ac_fn_c_try_link
2227
2228# ac_fn_c_check_func LINENO FUNC VAR
2229# ----------------------------------
2230# Tests whether FUNC exists, setting the cache variable VAR accordingly
2231ac_fn_c_check_func ()
2232{
2233  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2234  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2235$as_echo_n "checking for $2... " >&6; }
2236if eval \${$3+:} false; then :
2237  $as_echo_n "(cached) " >&6
2238else
2239  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2240/* end confdefs.h.  */
2241/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2242   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
2243#define $2 innocuous_$2
2244
2245/* System header to define __stub macros and hopefully few prototypes,
2246    which can conflict with char $2 (); below.
2247    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2248    <limits.h> exists even on freestanding compilers.  */
2249
2250#ifdef __STDC__
2251# include <limits.h>
2252#else
2253# include <assert.h>
2254#endif
2255
2256#undef $2
2257
2258/* Override any GCC internal prototype to avoid an error.
2259   Use char because int might match the return type of a GCC
2260   builtin and then its argument prototype would still apply.  */
2261#ifdef __cplusplus
2262extern "C"
2263#endif
2264char $2 ();
2265/* The GNU C library defines this for functions which it implements
2266    to always fail with ENOSYS.  Some functions are actually named
2267    something starting with __ and the normal name is an alias.  */
2268#if defined __stub_$2 || defined __stub___$2
2269choke me
2270#endif
2271
2272int
2273main ()
2274{
2275return $2 ();
2276  ;
2277  return 0;
2278}
2279_ACEOF
2280if ac_fn_c_try_link "$LINENO"; then :
2281  eval "$3=yes"
2282else
2283  eval "$3=no"
2284fi
2285rm -f core conftest.err conftest.$ac_objext \
2286    conftest$ac_exeext conftest.$ac_ext
2287fi
2288eval ac_res=\$$3
2289	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2290$as_echo "$ac_res" >&6; }
2291  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2292
2293} # ac_fn_c_check_func
2294
2295# ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2296# -------------------------------------------
2297# Tests whether TYPE exists after having included INCLUDES, setting cache
2298# variable VAR accordingly.
2299ac_fn_c_check_type ()
2300{
2301  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2302  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2303$as_echo_n "checking for $2... " >&6; }
2304if eval \${$3+:} false; then :
2305  $as_echo_n "(cached) " >&6
2306else
2307  eval "$3=no"
2308  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2309/* end confdefs.h.  */
2310$4
2311int
2312main ()
2313{
2314if (sizeof ($2))
2315	 return 0;
2316  ;
2317  return 0;
2318}
2319_ACEOF
2320if ac_fn_c_try_compile "$LINENO"; then :
2321  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2322/* end confdefs.h.  */
2323$4
2324int
2325main ()
2326{
2327if (sizeof (($2)))
2328	    return 0;
2329  ;
2330  return 0;
2331}
2332_ACEOF
2333if ac_fn_c_try_compile "$LINENO"; then :
2334
2335else
2336  eval "$3=yes"
2337fi
2338rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2339fi
2340rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2341fi
2342eval ac_res=\$$3
2343	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2344$as_echo "$ac_res" >&6; }
2345  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2346
2347} # ac_fn_c_check_type
2348
2349# ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2350# --------------------------------------------
2351# Tries to find the compile-time value of EXPR in a program that includes
2352# INCLUDES, setting VAR accordingly. Returns whether the value could be
2353# computed
2354ac_fn_c_compute_int ()
2355{
2356  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2357  if test "$cross_compiling" = yes; then
2358    # Depending upon the size, compute the lo and hi bounds.
2359cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2360/* end confdefs.h.  */
2361$4
2362int
2363main ()
2364{
2365static int test_array [1 - 2 * !(($2) >= 0)];
2366test_array [0] = 0;
2367return test_array [0];
2368
2369  ;
2370  return 0;
2371}
2372_ACEOF
2373if ac_fn_c_try_compile "$LINENO"; then :
2374  ac_lo=0 ac_mid=0
2375  while :; do
2376    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2377/* end confdefs.h.  */
2378$4
2379int
2380main ()
2381{
2382static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2383test_array [0] = 0;
2384return test_array [0];
2385
2386  ;
2387  return 0;
2388}
2389_ACEOF
2390if ac_fn_c_try_compile "$LINENO"; then :
2391  ac_hi=$ac_mid; break
2392else
2393  as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2394			if test $ac_lo -le $ac_mid; then
2395			  ac_lo= ac_hi=
2396			  break
2397			fi
2398			as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2399fi
2400rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2401  done
2402else
2403  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2404/* end confdefs.h.  */
2405$4
2406int
2407main ()
2408{
2409static int test_array [1 - 2 * !(($2) < 0)];
2410test_array [0] = 0;
2411return test_array [0];
2412
2413  ;
2414  return 0;
2415}
2416_ACEOF
2417if ac_fn_c_try_compile "$LINENO"; then :
2418  ac_hi=-1 ac_mid=-1
2419  while :; do
2420    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2421/* end confdefs.h.  */
2422$4
2423int
2424main ()
2425{
2426static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2427test_array [0] = 0;
2428return test_array [0];
2429
2430  ;
2431  return 0;
2432}
2433_ACEOF
2434if ac_fn_c_try_compile "$LINENO"; then :
2435  ac_lo=$ac_mid; break
2436else
2437  as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2438			if test $ac_mid -le $ac_hi; then
2439			  ac_lo= ac_hi=
2440			  break
2441			fi
2442			as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2443fi
2444rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2445  done
2446else
2447  ac_lo= ac_hi=
2448fi
2449rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2450fi
2451rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2452# Binary search between lo and hi bounds.
2453while test "x$ac_lo" != "x$ac_hi"; do
2454  as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2455  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2456/* end confdefs.h.  */
2457$4
2458int
2459main ()
2460{
2461static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2462test_array [0] = 0;
2463return test_array [0];
2464
2465  ;
2466  return 0;
2467}
2468_ACEOF
2469if ac_fn_c_try_compile "$LINENO"; then :
2470  ac_hi=$ac_mid
2471else
2472  as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2473fi
2474rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2475done
2476case $ac_lo in #((
2477?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2478'') ac_retval=1 ;;
2479esac
2480  else
2481    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2482/* end confdefs.h.  */
2483$4
2484static long int longval () { return $2; }
2485static unsigned long int ulongval () { return $2; }
2486#include <stdio.h>
2487#include <stdlib.h>
2488int
2489main ()
2490{
2491
2492  FILE *f = fopen ("conftest.val", "w");
2493  if (! f)
2494    return 1;
2495  if (($2) < 0)
2496    {
2497      long int i = longval ();
2498      if (i != ($2))
2499	return 1;
2500      fprintf (f, "%ld", i);
2501    }
2502  else
2503    {
2504      unsigned long int i = ulongval ();
2505      if (i != ($2))
2506	return 1;
2507      fprintf (f, "%lu", i);
2508    }
2509  /* Do not output a trailing newline, as this causes \r\n confusion
2510     on some platforms.  */
2511  return ferror (f) || fclose (f) != 0;
2512
2513  ;
2514  return 0;
2515}
2516_ACEOF
2517if ac_fn_c_try_run "$LINENO"; then :
2518  echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2519else
2520  ac_retval=1
2521fi
2522rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2523  conftest.$ac_objext conftest.beam conftest.$ac_ext
2524rm -f conftest.val
2525
2526  fi
2527  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2528  as_fn_set_status $ac_retval
2529
2530} # ac_fn_c_compute_int
2531
2532# ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
2533# ---------------------------------------------
2534# Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
2535# accordingly.
2536ac_fn_c_check_decl ()
2537{
2538  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2539  as_decl_name=`echo $2|sed 's/ *(.*//'`
2540  as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
2541  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
2542$as_echo_n "checking whether $as_decl_name is declared... " >&6; }
2543if eval \${$3+:} false; then :
2544  $as_echo_n "(cached) " >&6
2545else
2546  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2547/* end confdefs.h.  */
2548$4
2549int
2550main ()
2551{
2552#ifndef $as_decl_name
2553#ifdef __cplusplus
2554  (void) $as_decl_use;
2555#else
2556  (void) $as_decl_name;
2557#endif
2558#endif
2559
2560  ;
2561  return 0;
2562}
2563_ACEOF
2564if ac_fn_c_try_compile "$LINENO"; then :
2565  eval "$3=yes"
2566else
2567  eval "$3=no"
2568fi
2569rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2570fi
2571eval ac_res=\$$3
2572	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2573$as_echo "$ac_res" >&6; }
2574  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2575
2576} # ac_fn_c_check_decl
2577
2578# ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2579# ----------------------------------------------------
2580# Tries to find if the field MEMBER exists in type AGGR, after including
2581# INCLUDES, setting cache variable VAR accordingly.
2582ac_fn_c_check_member ()
2583{
2584  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2585  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2586$as_echo_n "checking for $2.$3... " >&6; }
2587if eval \${$4+:} false; then :
2588  $as_echo_n "(cached) " >&6
2589else
2590  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2591/* end confdefs.h.  */
2592$5
2593int
2594main ()
2595{
2596static $2 ac_aggr;
2597if (ac_aggr.$3)
2598return 0;
2599  ;
2600  return 0;
2601}
2602_ACEOF
2603if ac_fn_c_try_compile "$LINENO"; then :
2604  eval "$4=yes"
2605else
2606  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2607/* end confdefs.h.  */
2608$5
2609int
2610main ()
2611{
2612static $2 ac_aggr;
2613if (sizeof ac_aggr.$3)
2614return 0;
2615  ;
2616  return 0;
2617}
2618_ACEOF
2619if ac_fn_c_try_compile "$LINENO"; then :
2620  eval "$4=yes"
2621else
2622  eval "$4=no"
2623fi
2624rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2625fi
2626rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2627fi
2628eval ac_res=\$$4
2629	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2630$as_echo "$ac_res" >&6; }
2631  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2632
2633} # ac_fn_c_check_member
2634cat >config.log <<_ACEOF
2635This file contains any messages produced by compilers while
2636running configure, to aid debugging if configure makes a mistake.
2637
2638It was created by ntp $as_me 4.2.8p12, which was
2639generated by GNU Autoconf 2.69.  Invocation command line was
2640
2641  $ $0 $@
2642
2643_ACEOF
2644exec 5>>config.log
2645{
2646cat <<_ASUNAME
2647## --------- ##
2648## Platform. ##
2649## --------- ##
2650
2651hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2652uname -m = `(uname -m) 2>/dev/null || echo unknown`
2653uname -r = `(uname -r) 2>/dev/null || echo unknown`
2654uname -s = `(uname -s) 2>/dev/null || echo unknown`
2655uname -v = `(uname -v) 2>/dev/null || echo unknown`
2656
2657/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2658/bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
2659
2660/bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
2661/usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
2662/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2663/usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
2664/bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
2665/usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
2666/bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
2667
2668_ASUNAME
2669
2670as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2671for as_dir in $PATH
2672do
2673  IFS=$as_save_IFS
2674  test -z "$as_dir" && as_dir=.
2675    $as_echo "PATH: $as_dir"
2676  done
2677IFS=$as_save_IFS
2678
2679} >&5
2680
2681cat >&5 <<_ACEOF
2682
2683
2684## ----------- ##
2685## Core tests. ##
2686## ----------- ##
2687
2688_ACEOF
2689
2690
2691# Keep a trace of the command line.
2692# Strip out --no-create and --no-recursion so they do not pile up.
2693# Strip out --silent because we don't want to record it for future runs.
2694# Also quote any args containing shell meta-characters.
2695# Make two passes to allow for proper duplicate-argument suppression.
2696ac_configure_args=
2697ac_configure_args0=
2698ac_configure_args1=
2699ac_must_keep_next=false
2700for ac_pass in 1 2
2701do
2702  for ac_arg
2703  do
2704    case $ac_arg in
2705    -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2706    -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2707    | -silent | --silent | --silen | --sile | --sil)
2708      continue ;;
2709    *\'*)
2710      ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2711    esac
2712    case $ac_pass in
2713    1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2714    2)
2715      as_fn_append ac_configure_args1 " '$ac_arg'"
2716      if test $ac_must_keep_next = true; then
2717	ac_must_keep_next=false # Got value, back to normal.
2718      else
2719	case $ac_arg in
2720	  *=* | --config-cache | -C | -disable-* | --disable-* \
2721	  | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2722	  | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2723	  | -with-* | --with-* | -without-* | --without-* | --x)
2724	    case "$ac_configure_args0 " in
2725	      "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2726	    esac
2727	    ;;
2728	  -* ) ac_must_keep_next=true ;;
2729	esac
2730      fi
2731      as_fn_append ac_configure_args " '$ac_arg'"
2732      ;;
2733    esac
2734  done
2735done
2736{ ac_configure_args0=; unset ac_configure_args0;}
2737{ ac_configure_args1=; unset ac_configure_args1;}
2738
2739# When interrupted or exit'd, cleanup temporary files, and complete
2740# config.log.  We remove comments because anyway the quotes in there
2741# would cause problems or look ugly.
2742# WARNING: Use '\'' to represent an apostrophe within the trap.
2743# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2744trap 'exit_status=$?
2745  # Save into config.log some information that might help in debugging.
2746  {
2747    echo
2748
2749    $as_echo "## ---------------- ##
2750## Cache variables. ##
2751## ---------------- ##"
2752    echo
2753    # The following way of writing the cache mishandles newlines in values,
2754(
2755  for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2756    eval ac_val=\$$ac_var
2757    case $ac_val in #(
2758    *${as_nl}*)
2759      case $ac_var in #(
2760      *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2761$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2762      esac
2763      case $ac_var in #(
2764      _ | IFS | as_nl) ;; #(
2765      BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2766      *) { eval $ac_var=; unset $ac_var;} ;;
2767      esac ;;
2768    esac
2769  done
2770  (set) 2>&1 |
2771    case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2772    *${as_nl}ac_space=\ *)
2773      sed -n \
2774	"s/'\''/'\''\\\\'\'''\''/g;
2775	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2776      ;; #(
2777    *)
2778      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2779      ;;
2780    esac |
2781    sort
2782)
2783    echo
2784
2785    $as_echo "## ----------------- ##
2786## Output variables. ##
2787## ----------------- ##"
2788    echo
2789    for ac_var in $ac_subst_vars
2790    do
2791      eval ac_val=\$$ac_var
2792      case $ac_val in
2793      *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2794      esac
2795      $as_echo "$ac_var='\''$ac_val'\''"
2796    done | sort
2797    echo
2798
2799    if test -n "$ac_subst_files"; then
2800      $as_echo "## ------------------- ##
2801## File substitutions. ##
2802## ------------------- ##"
2803      echo
2804      for ac_var in $ac_subst_files
2805      do
2806	eval ac_val=\$$ac_var
2807	case $ac_val in
2808	*\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2809	esac
2810	$as_echo "$ac_var='\''$ac_val'\''"
2811      done | sort
2812      echo
2813    fi
2814
2815    if test -s confdefs.h; then
2816      $as_echo "## ----------- ##
2817## confdefs.h. ##
2818## ----------- ##"
2819      echo
2820      cat confdefs.h
2821      echo
2822    fi
2823    test "$ac_signal" != 0 &&
2824      $as_echo "$as_me: caught signal $ac_signal"
2825    $as_echo "$as_me: exit $exit_status"
2826  } >&5
2827  rm -f core *.core core.conftest.* &&
2828    rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2829    exit $exit_status
2830' 0
2831for ac_signal in 1 2 13 15; do
2832  trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2833done
2834ac_signal=0
2835
2836# confdefs.h avoids OS command line length limits that DEFS can exceed.
2837rm -f -r conftest* confdefs.h
2838
2839$as_echo "/* confdefs.h */" > confdefs.h
2840
2841# Predefined preprocessor variables.
2842
2843cat >>confdefs.h <<_ACEOF
2844#define PACKAGE_NAME "$PACKAGE_NAME"
2845_ACEOF
2846
2847cat >>confdefs.h <<_ACEOF
2848#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2849_ACEOF
2850
2851cat >>confdefs.h <<_ACEOF
2852#define PACKAGE_VERSION "$PACKAGE_VERSION"
2853_ACEOF
2854
2855cat >>confdefs.h <<_ACEOF
2856#define PACKAGE_STRING "$PACKAGE_STRING"
2857_ACEOF
2858
2859cat >>confdefs.h <<_ACEOF
2860#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2861_ACEOF
2862
2863cat >>confdefs.h <<_ACEOF
2864#define PACKAGE_URL "$PACKAGE_URL"
2865_ACEOF
2866
2867
2868# Let the site file select an alternate cache file if it wants to.
2869# Prefer an explicitly selected file to automatically selected ones.
2870ac_site_file1=NONE
2871ac_site_file2=NONE
2872if test -n "$CONFIG_SITE"; then
2873  # We do not want a PATH search for config.site.
2874  case $CONFIG_SITE in #((
2875    -*)  ac_site_file1=./$CONFIG_SITE;;
2876    */*) ac_site_file1=$CONFIG_SITE;;
2877    *)   ac_site_file1=./$CONFIG_SITE;;
2878  esac
2879elif test "x$prefix" != xNONE; then
2880  ac_site_file1=$prefix/share/config.site
2881  ac_site_file2=$prefix/etc/config.site
2882else
2883  ac_site_file1=$ac_default_prefix/share/config.site
2884  ac_site_file2=$ac_default_prefix/etc/config.site
2885fi
2886for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2887do
2888  test "x$ac_site_file" = xNONE && continue
2889  if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
2890    { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2891$as_echo "$as_me: loading site script $ac_site_file" >&6;}
2892    sed 's/^/| /' "$ac_site_file" >&5
2893    . "$ac_site_file" \
2894      || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2895$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2896as_fn_error $? "failed to load site script $ac_site_file
2897See \`config.log' for more details" "$LINENO" 5; }
2898  fi
2899done
2900
2901if test -r "$cache_file"; then
2902  # Some versions of bash will fail to source /dev/null (special files
2903  # actually), so we avoid doing that.  DJGPP emulates it as a regular file.
2904  if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2905    { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2906$as_echo "$as_me: loading cache $cache_file" >&6;}
2907    case $cache_file in
2908      [\\/]* | ?:[\\/]* ) . "$cache_file";;
2909      *)                      . "./$cache_file";;
2910    esac
2911  fi
2912else
2913  { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2914$as_echo "$as_me: creating cache $cache_file" >&6;}
2915  >$cache_file
2916fi
2917
2918as_fn_append ac_header_list " stdarg.h"
2919# Check that the precious variables saved in the cache have kept the same
2920# value.
2921ac_cache_corrupted=false
2922for ac_var in $ac_precious_vars; do
2923  eval ac_old_set=\$ac_cv_env_${ac_var}_set
2924  eval ac_new_set=\$ac_env_${ac_var}_set
2925  eval ac_old_val=\$ac_cv_env_${ac_var}_value
2926  eval ac_new_val=\$ac_env_${ac_var}_value
2927  case $ac_old_set,$ac_new_set in
2928    set,)
2929      { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2930$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2931      ac_cache_corrupted=: ;;
2932    ,set)
2933      { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2934$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2935      ac_cache_corrupted=: ;;
2936    ,);;
2937    *)
2938      if test "x$ac_old_val" != "x$ac_new_val"; then
2939	# differences in whitespace do not lead to failure.
2940	ac_old_val_w=`echo x $ac_old_val`
2941	ac_new_val_w=`echo x $ac_new_val`
2942	if test "$ac_old_val_w" != "$ac_new_val_w"; then
2943	  { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2944$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2945	  ac_cache_corrupted=:
2946	else
2947	  { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2948$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2949	  eval $ac_var=\$ac_old_val
2950	fi
2951	{ $as_echo "$as_me:${as_lineno-$LINENO}:   former value:  \`$ac_old_val'" >&5
2952$as_echo "$as_me:   former value:  \`$ac_old_val'" >&2;}
2953	{ $as_echo "$as_me:${as_lineno-$LINENO}:   current value: \`$ac_new_val'" >&5
2954$as_echo "$as_me:   current value: \`$ac_new_val'" >&2;}
2955      fi;;
2956  esac
2957  # Pass precious variables to config.status.
2958  if test "$ac_new_set" = set; then
2959    case $ac_new_val in
2960    *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2961    *) ac_arg=$ac_var=$ac_new_val ;;
2962    esac
2963    case " $ac_configure_args " in
2964      *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
2965      *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2966    esac
2967  fi
2968done
2969if $ac_cache_corrupted; then
2970  { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2971$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2972  { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2973$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2974  as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
2975fi
2976## -------------------- ##
2977## Main body of script. ##
2978## -------------------- ##
2979
2980ac_ext=c
2981ac_cpp='$CPP $CPPFLAGS'
2982ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2983ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2984ac_compiler_gnu=$ac_cv_c_compiler_gnu
2985
2986
2987
2988ac_aux_dir=
2989for ac_dir in sntp/libevent/build-aux "$srcdir"/sntp/libevent/build-aux; do
2990  if test -f "$ac_dir/install-sh"; then
2991    ac_aux_dir=$ac_dir
2992    ac_install_sh="$ac_aux_dir/install-sh -c"
2993    break
2994  elif test -f "$ac_dir/install.sh"; then
2995    ac_aux_dir=$ac_dir
2996    ac_install_sh="$ac_aux_dir/install.sh -c"
2997    break
2998  elif test -f "$ac_dir/shtool"; then
2999    ac_aux_dir=$ac_dir
3000    ac_install_sh="$ac_aux_dir/shtool install -c"
3001    break
3002  fi
3003done
3004if test -z "$ac_aux_dir"; then
3005  as_fn_error $? "cannot find install-sh, install.sh, or shtool in sntp/libevent/build-aux \"$srcdir\"/sntp/libevent/build-aux" "$LINENO" 5
3006fi
3007
3008# These three variables are undocumented and unsupported,
3009# and are intended to be withdrawn in a future Autoconf release.
3010# They can cause serious problems if a builder's source tree is in a directory
3011# whose full name contains unusual characters.
3012ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
3013ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
3014ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
3015
3016
3017ac_ext=c
3018ac_cpp='$CPP $CPPFLAGS'
3019ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3020ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3021ac_compiler_gnu=$ac_cv_c_compiler_gnu
3022
3023
3024
3025
3026
3027
3028# Bump ntp_configure_cache_version for each change to configure.ac or
3029# .m4 files which invalidates cached values from previous configure
3030# runs.
3031#
3032# If the change affects cache variables used only by the main NTP
3033# configure.ac, then only its version number should be bumped, while
3034# the subdir configure.ac version numbers should be unchanged.  The
3035# same is true for a test/variable that is used only by one subdir
3036# being changed incompatibly; only that subdir's cache version needs
3037# bumping.
3038#
3039# If a change affects variables shared by all NTP configure scripts,
3040# please bump the version numbers of each.  If you are not sure, the
3041# safe choice is to bump all on any cache-invalidating change.
3042#
3043# In order to avoid the risk of version stamp collision between -stable
3044# and -dev branches, do not simply increment the version, instead use
3045# the date YYYYMMDD optionally with -HHMM if there is more than one
3046# bump in a day.
3047
3048ntp_configure_cache_version=20120806
3049
3050# When the cache version of config.cache and configure do not
3051# match, NTP_CACHEVERSION will flush the cache.
3052
3053
3054
3055    ntp_cache_flush=1
3056
3057    case "$ntp_cv_main_cache_version" in
3058     $ntp_configure_cache_version)
3059	# same version, good
3060	ntp_cache_flush=0
3061	;;
3062     '')
3063	# No cache, predates ntp_cv_main_cache_version, or is empty.
3064	case "$cache_file" in
3065	 /dev/null)
3066	    ntp_cache_flush=0
3067	    ;;
3068	 *)
3069	    case "$NTP_CACHEVERSION_PARENT" in
3070	     '')
3071		# Do not clear the cache immediately after it is created
3072		# empty as it is noisy.  Differentiate a newly-created
3073		# config.cache from one predating the cache version
3074		# mechanism by looking for the first cached variable set
3075		# by Autoconf
3076		case "$ac_cv_path_install" in
3077		 '')
3078		    # empty config.cache file
3079		    ntp_cache_flush=0
3080		esac
3081		;;
3082	     *)
3083		# Parent configure just created cache from empty,
3084		# flushing would be counterproductive.
3085		ntp_cache_flush=0;
3086		;;
3087	    esac
3088	esac
3089	;;
3090     *)
3091	# configure cache version mismatches config.cache version
3092	;;
3093    esac
3094
3095    case "$ntp_cache_flush" in
3096     1)
3097	c_version="${ntp_cv_main_cache_version:-(no version found)}"
3098
3099	# Do we flush all variables or exclude others' version stamps?
3100
3101	case "$NTP_CACHEVERSION_PARENT" in
3102	 '')
3103	    # Clear all *_cv_* variables including our child subdirs'
3104	    # ntp_cv_*_cache_version variables.  This prevents subdir
3105	    # configure scripts from noticing a version mismatch just
3106	    # after the top configure in the invocation cleared and
3107	    # recreated the cache.
3108
3109	    c_varname_list=`set |
3110			    sed -n -e 's/=.*$//' \
3111				   -e '/_cv_/p'
3112			   `
3113	    ;;
3114	 *)
3115	    # This is not the top configure this particular invocation.
3116	    # Clear all *_cv_* variables sparing the version stamps
3117	    # of other configure scripts, so we don't trigger
3118	    # useless repeated clearings.
3119
3120	    c_varname_list=`set |
3121			    sed -n -e 's/=.*$//' \
3122				   -e '/ntp_cv_.*_cache_version/d' \
3123				   -e '/_cv_/p'
3124			   `
3125	esac
3126
3127	for c_varname in $c_varname_list
3128	do
3129	    	    	    	    	    	    { eval $c_varname=; unset $c_varname; }
3130	done
3131
3132	{ $as_echo "$as_me:${as_lineno-$LINENO}: $cache_file saved by another version, ignored." >&5
3133$as_echo "$as_me: $cache_file saved by another version, ignored." >&6;}
3134	{ $as_echo "$as_me:${as_lineno-$LINENO}: configure script cache version: $ntp_configure_cache_version" >&5
3135$as_echo "$as_me: configure script cache version: $ntp_configure_cache_version" >&6;}
3136	{ $as_echo "$as_me:${as_lineno-$LINENO}: $cache_file version: $c_version" >&5
3137$as_echo "$as_me: $cache_file version: $c_version" >&6;}
3138	{ c_varname=; unset c_varname;}
3139	{ c_varname_list=; unset c_varname_list;}
3140	{ c_version=; unset c_version;}
3141    esac
3142
3143    { ntp_cache_flush=; unset ntp_cache_flush;}
3144
3145    # save configure version in config.cache for next time
3146    ntp_cv_main_cache_version="$ntp_configure_cache_version"
3147
3148    # let any subdir configure.ac NTP_CACHEVERSION invocations
3149    # know they are not the top level.
3150    NTP_CACHEVERSION_PARENT='main' ; export NTP_CACHEVERSION_PARENT
3151
3152
3153am__api_version='1.15'
3154
3155# Find a good install program.  We prefer a C program (faster),
3156# so one script is as good as another.  But avoid the broken or
3157# incompatible versions:
3158# SysV /etc/install, /usr/sbin/install
3159# SunOS /usr/etc/install
3160# IRIX /sbin/install
3161# AIX /bin/install
3162# AmigaOS /C/install, which installs bootblocks on floppy discs
3163# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3164# AFS /usr/afsws/bin/install, which mishandles nonexistent args
3165# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3166# OS/2's system install, which has a completely different semantic
3167# ./install, which can be erroneously created by make from ./install.sh.
3168# Reject install programs that cannot install multiple files.
3169{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
3170$as_echo_n "checking for a BSD-compatible install... " >&6; }
3171if test -z "$INSTALL"; then
3172if ${ac_cv_path_install+:} false; then :
3173  $as_echo_n "(cached) " >&6
3174else
3175  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3176for as_dir in $PATH
3177do
3178  IFS=$as_save_IFS
3179  test -z "$as_dir" && as_dir=.
3180    # Account for people who put trailing slashes in PATH elements.
3181case $as_dir/ in #((
3182  ./ | .// | /[cC]/* | \
3183  /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3184  ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
3185  /usr/ucb/* ) ;;
3186  *)
3187    # OSF1 and SCO ODT 3.0 have their own names for install.
3188    # Don't use installbsd from OSF since it installs stuff as root
3189    # by default.
3190    for ac_prog in ginstall scoinst install; do
3191      for ac_exec_ext in '' $ac_executable_extensions; do
3192	if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
3193	  if test $ac_prog = install &&
3194	    grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3195	    # AIX install.  It has an incompatible calling convention.
3196	    :
3197	  elif test $ac_prog = install &&
3198	    grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3199	    # program-specific install script used by HP pwplus--don't use.
3200	    :
3201	  else
3202	    rm -rf conftest.one conftest.two conftest.dir
3203	    echo one > conftest.one
3204	    echo two > conftest.two
3205	    mkdir conftest.dir
3206	    if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
3207	      test -s conftest.one && test -s conftest.two &&
3208	      test -s conftest.dir/conftest.one &&
3209	      test -s conftest.dir/conftest.two
3210	    then
3211	      ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3212	      break 3
3213	    fi
3214	  fi
3215	fi
3216      done
3217    done
3218    ;;
3219esac
3220
3221  done
3222IFS=$as_save_IFS
3223
3224rm -rf conftest.one conftest.two conftest.dir
3225
3226fi
3227  if test "${ac_cv_path_install+set}" = set; then
3228    INSTALL=$ac_cv_path_install
3229  else
3230    # As a last resort, use the slow shell script.  Don't cache a
3231    # value for INSTALL within a source directory, because that will
3232    # break other packages using the cache if that directory is
3233    # removed, or if the value is a relative name.
3234    INSTALL=$ac_install_sh
3235  fi
3236fi
3237{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
3238$as_echo "$INSTALL" >&6; }
3239
3240# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3241# It thinks the first close brace ends the variable substitution.
3242test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3243
3244test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3245
3246test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3247
3248{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
3249$as_echo_n "checking whether build environment is sane... " >&6; }
3250# Reject unsafe characters in $srcdir or the absolute working directory
3251# name.  Accept space and tab only in the latter.
3252am_lf='
3253'
3254case `pwd` in
3255  *[\\\"\#\$\&\'\`$am_lf]*)
3256    as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;;
3257esac
3258case $srcdir in
3259  *[\\\"\#\$\&\'\`$am_lf\ \	]*)
3260    as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;;
3261esac
3262
3263# Do 'set' in a subshell so we don't clobber the current shell's
3264# arguments.  Must try -L first in case configure is actually a
3265# symlink; some systems play weird games with the mod time of symlinks
3266# (eg FreeBSD returns the mod time of the symlink's containing
3267# directory).
3268if (
3269   am_has_slept=no
3270   for am_try in 1 2; do
3271     echo "timestamp, slept: $am_has_slept" > conftest.file
3272     set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
3273     if test "$*" = "X"; then
3274	# -L didn't work.
3275	set X `ls -t "$srcdir/configure" conftest.file`
3276     fi
3277     if test "$*" != "X $srcdir/configure conftest.file" \
3278	&& test "$*" != "X conftest.file $srcdir/configure"; then
3279
3280	# If neither matched, then we have a broken ls.  This can happen
3281	# if, for instance, CONFIG_SHELL is bash and it inherits a
3282	# broken ls alias from the environment.  This has actually
3283	# happened.  Such a system could not be considered "sane".
3284	as_fn_error $? "ls -t appears to fail.  Make sure there is not a broken
3285  alias in your environment" "$LINENO" 5
3286     fi
3287     if test "$2" = conftest.file || test $am_try -eq 2; then
3288       break
3289     fi
3290     # Just in case.
3291     sleep 1
3292     am_has_slept=yes
3293   done
3294   test "$2" = conftest.file
3295   )
3296then
3297   # Ok.
3298   :
3299else
3300   as_fn_error $? "newly created file is older than distributed files!
3301Check your system clock" "$LINENO" 5
3302fi
3303{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3304$as_echo "yes" >&6; }
3305# If we didn't sleep, we still need to ensure time stamps of config.status and
3306# generated files are strictly newer.
3307am_sleep_pid=
3308if grep 'slept: no' conftest.file >/dev/null 2>&1; then
3309  ( sleep 1 ) &
3310  am_sleep_pid=$!
3311fi
3312
3313rm -f conftest.file
3314
3315test "$program_prefix" != NONE &&
3316  program_transform_name="s&^&$program_prefix&;$program_transform_name"
3317# Use a double $ so make ignores it.
3318test "$program_suffix" != NONE &&
3319  program_transform_name="s&\$&$program_suffix&;$program_transform_name"
3320# Double any \ or $.
3321# By default was `s,x,x', remove it if useless.
3322ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
3323program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
3324
3325# Expand $ac_aux_dir to an absolute path.
3326am_aux_dir=`cd "$ac_aux_dir" && pwd`
3327
3328if test x"${MISSING+set}" != xset; then
3329  case $am_aux_dir in
3330  *\ * | *\	*)
3331    MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
3332  *)
3333    MISSING="\${SHELL} $am_aux_dir/missing" ;;
3334  esac
3335fi
3336# Use eval to expand $SHELL
3337if eval "$MISSING --is-lightweight"; then
3338  am_missing_run="$MISSING "
3339else
3340  am_missing_run=
3341  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5
3342$as_echo "$as_me: WARNING: 'missing' script is too old or missing" >&2;}
3343fi
3344
3345if test x"${install_sh+set}" != xset; then
3346  case $am_aux_dir in
3347  *\ * | *\	*)
3348    install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
3349  *)
3350    install_sh="\${SHELL} $am_aux_dir/install-sh"
3351  esac
3352fi
3353
3354# Installed binaries are usually stripped using 'strip' when the user
3355# run "make install-strip".  However 'strip' might not be the right
3356# tool to use in cross-compilation environments, therefore Automake
3357# will honor the 'STRIP' environment variable to overrule this program.
3358if test "$cross_compiling" != no; then
3359  if test -n "$ac_tool_prefix"; then
3360  # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
3361set dummy ${ac_tool_prefix}strip; ac_word=$2
3362{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3363$as_echo_n "checking for $ac_word... " >&6; }
3364if ${ac_cv_prog_STRIP+:} false; then :
3365  $as_echo_n "(cached) " >&6
3366else
3367  if test -n "$STRIP"; then
3368  ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
3369else
3370as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3371for as_dir in $PATH
3372do
3373  IFS=$as_save_IFS
3374  test -z "$as_dir" && as_dir=.
3375    for ac_exec_ext in '' $ac_executable_extensions; do
3376  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3377    ac_cv_prog_STRIP="${ac_tool_prefix}strip"
3378    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3379    break 2
3380  fi
3381done
3382  done
3383IFS=$as_save_IFS
3384
3385fi
3386fi
3387STRIP=$ac_cv_prog_STRIP
3388if test -n "$STRIP"; then
3389  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
3390$as_echo "$STRIP" >&6; }
3391else
3392  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3393$as_echo "no" >&6; }
3394fi
3395
3396
3397fi
3398if test -z "$ac_cv_prog_STRIP"; then
3399  ac_ct_STRIP=$STRIP
3400  # Extract the first word of "strip", so it can be a program name with args.
3401set dummy strip; ac_word=$2
3402{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3403$as_echo_n "checking for $ac_word... " >&6; }
3404if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
3405  $as_echo_n "(cached) " >&6
3406else
3407  if test -n "$ac_ct_STRIP"; then
3408  ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
3409else
3410as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3411for as_dir in $PATH
3412do
3413  IFS=$as_save_IFS
3414  test -z "$as_dir" && as_dir=.
3415    for ac_exec_ext in '' $ac_executable_extensions; do
3416  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3417    ac_cv_prog_ac_ct_STRIP="strip"
3418    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3419    break 2
3420  fi
3421done
3422  done
3423IFS=$as_save_IFS
3424
3425fi
3426fi
3427ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
3428if test -n "$ac_ct_STRIP"; then
3429  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
3430$as_echo "$ac_ct_STRIP" >&6; }
3431else
3432  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3433$as_echo "no" >&6; }
3434fi
3435
3436  if test "x$ac_ct_STRIP" = x; then
3437    STRIP=":"
3438  else
3439    case $cross_compiling:$ac_tool_warned in
3440yes:)
3441{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3442$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3443ac_tool_warned=yes ;;
3444esac
3445    STRIP=$ac_ct_STRIP
3446  fi
3447else
3448  STRIP="$ac_cv_prog_STRIP"
3449fi
3450
3451fi
3452INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
3453
3454{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
3455$as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
3456if test -z "$MKDIR_P"; then
3457  if ${ac_cv_path_mkdir+:} false; then :
3458  $as_echo_n "(cached) " >&6
3459else
3460  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3461for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
3462do
3463  IFS=$as_save_IFS
3464  test -z "$as_dir" && as_dir=.
3465    for ac_prog in mkdir gmkdir; do
3466	 for ac_exec_ext in '' $ac_executable_extensions; do
3467	   as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue
3468	   case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
3469	     'mkdir (GNU coreutils) '* | \
3470	     'mkdir (coreutils) '* | \
3471	     'mkdir (fileutils) '4.1*)
3472	       ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
3473	       break 3;;
3474	   esac
3475	 done
3476       done
3477  done
3478IFS=$as_save_IFS
3479
3480fi
3481
3482  test -d ./--version && rmdir ./--version
3483  if test "${ac_cv_path_mkdir+set}" = set; then
3484    MKDIR_P="$ac_cv_path_mkdir -p"
3485  else
3486    # As a last resort, use the slow shell script.  Don't cache a
3487    # value for MKDIR_P within a source directory, because that will
3488    # break other packages using the cache if that directory is
3489    # removed, or if the value is a relative name.
3490    MKDIR_P="$ac_install_sh -d"
3491  fi
3492fi
3493{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
3494$as_echo "$MKDIR_P" >&6; }
3495
3496for ac_prog in gawk mawk nawk awk
3497do
3498  # Extract the first word of "$ac_prog", so it can be a program name with args.
3499set dummy $ac_prog; ac_word=$2
3500{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3501$as_echo_n "checking for $ac_word... " >&6; }
3502if ${ac_cv_prog_AWK+:} false; then :
3503  $as_echo_n "(cached) " >&6
3504else
3505  if test -n "$AWK"; then
3506  ac_cv_prog_AWK="$AWK" # Let the user override the test.
3507else
3508as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3509for as_dir in $PATH
3510do
3511  IFS=$as_save_IFS
3512  test -z "$as_dir" && as_dir=.
3513    for ac_exec_ext in '' $ac_executable_extensions; do
3514  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3515    ac_cv_prog_AWK="$ac_prog"
3516    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3517    break 2
3518  fi
3519done
3520  done
3521IFS=$as_save_IFS
3522
3523fi
3524fi
3525AWK=$ac_cv_prog_AWK
3526if test -n "$AWK"; then
3527  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
3528$as_echo "$AWK" >&6; }
3529else
3530  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3531$as_echo "no" >&6; }
3532fi
3533
3534
3535  test -n "$AWK" && break
3536done
3537
3538{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
3539$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
3540set x ${MAKE-make}
3541ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
3542if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then :
3543  $as_echo_n "(cached) " >&6
3544else
3545  cat >conftest.make <<\_ACEOF
3546SHELL = /bin/sh
3547all:
3548	@echo '@@@%%%=$(MAKE)=@@@%%%'
3549_ACEOF
3550# GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
3551case `${MAKE-make} -f conftest.make 2>/dev/null` in
3552  *@@@%%%=?*=@@@%%%*)
3553    eval ac_cv_prog_make_${ac_make}_set=yes;;
3554  *)
3555    eval ac_cv_prog_make_${ac_make}_set=no;;
3556esac
3557rm -f conftest.make
3558fi
3559if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
3560  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3561$as_echo "yes" >&6; }
3562  SET_MAKE=
3563else
3564  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3565$as_echo "no" >&6; }
3566  SET_MAKE="MAKE=${MAKE-make}"
3567fi
3568
3569rm -rf .tst 2>/dev/null
3570mkdir .tst 2>/dev/null
3571if test -d .tst; then
3572  am__leading_dot=.
3573else
3574  am__leading_dot=_
3575fi
3576rmdir .tst 2>/dev/null
3577
3578# Check whether --enable-silent-rules was given.
3579if test "${enable_silent_rules+set}" = set; then :
3580  enableval=$enable_silent_rules;
3581fi
3582
3583case $enable_silent_rules in # (((
3584  yes) AM_DEFAULT_VERBOSITY=0;;
3585   no) AM_DEFAULT_VERBOSITY=1;;
3586    *) AM_DEFAULT_VERBOSITY=1;;
3587esac
3588am_make=${MAKE-make}
3589{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
3590$as_echo_n "checking whether $am_make supports nested variables... " >&6; }
3591if ${am_cv_make_support_nested_variables+:} false; then :
3592  $as_echo_n "(cached) " >&6
3593else
3594  if $as_echo 'TRUE=$(BAR$(V))
3595BAR0=false
3596BAR1=true
3597V=1
3598am__doit:
3599	@$(TRUE)
3600.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
3601  am_cv_make_support_nested_variables=yes
3602else
3603  am_cv_make_support_nested_variables=no
3604fi
3605fi
3606{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
3607$as_echo "$am_cv_make_support_nested_variables" >&6; }
3608if test $am_cv_make_support_nested_variables = yes; then
3609    AM_V='$(V)'
3610  AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
3611else
3612  AM_V=$AM_DEFAULT_VERBOSITY
3613  AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
3614fi
3615AM_BACKSLASH='\'
3616
3617if test "`cd $srcdir && pwd`" != "`pwd`"; then
3618  # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
3619  # is not polluted with repeated "-I."
3620  am__isrc=' -I$(srcdir)'
3621  # test to see if srcdir already configured
3622  if test -f $srcdir/config.status; then
3623    as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
3624  fi
3625fi
3626
3627# test whether we have cygpath
3628if test -z "$CYGPATH_W"; then
3629  if (cygpath --version) >/dev/null 2>/dev/null; then
3630    CYGPATH_W='cygpath -w'
3631  else
3632    CYGPATH_W=echo
3633  fi
3634fi
3635
3636
3637# Define the identity of the package.
3638 PACKAGE='ntp'
3639 VERSION='4.2.8p12'
3640
3641
3642cat >>confdefs.h <<_ACEOF
3643#define PACKAGE "$PACKAGE"
3644_ACEOF
3645
3646
3647cat >>confdefs.h <<_ACEOF
3648#define VERSION "$VERSION"
3649_ACEOF
3650
3651# Some tools Automake needs.
3652
3653ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
3654
3655
3656AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
3657
3658
3659AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
3660
3661
3662AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
3663
3664
3665MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
3666
3667# For better backward compatibility.  To be removed once Automake 1.9.x
3668# dies out for good.  For more background, see:
3669# <http://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
3670# <http://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
3671mkdir_p='$(MKDIR_P)'
3672
3673# We need awk for the "check" target (and possibly the TAP driver).  The
3674# system "awk" is bad on some platforms.
3675# Always define AMTAR for backward compatibility.  Yes, it's still used
3676# in the wild :-(  We should find a proper way to deprecate it ...
3677AMTAR='$${TAR-tar}'
3678
3679
3680# We'll loop over all known methods to create a tar archive until one works.
3681_am_tools='gnutar  pax cpio none'
3682
3683am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'
3684
3685
3686
3687
3688
3689
3690# POSIX will say in a future version that running "rm -f" with no argument
3691# is OK; and we want to be able to make that assumption in our Makefile
3692# recipes.  So use an aggressive probe to check that the usage we want is
3693# actually supported "in the wild" to an acceptable degree.
3694# See automake bug#10828.
3695# To make any issue more visible, cause the running configure to be aborted
3696# by default if the 'rm' program in use doesn't match our expectations; the
3697# user can still override this though.
3698if rm -f && rm -fr && rm -rf; then : OK; else
3699  cat >&2 <<'END'
3700Oops!
3701
3702Your 'rm' program seems unable to run without file operands specified
3703on the command line, even when the '-f' option is present.  This is contrary
3704to the behaviour of most rm programs out there, and not conforming with
3705the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542>
3706
3707Please tell bug-automake@gnu.org about your system, including the value
3708of your $PATH and any error possibly output before this message.  This
3709can help us improve future automake versions.
3710
3711END
3712  if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then
3713    echo 'Configuration will proceed anyway, since you have set the' >&2
3714    echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2
3715    echo >&2
3716  else
3717    cat >&2 <<'END'
3718Aborting the configuration process, to ensure you take notice of the issue.
3719
3720You can download and install GNU coreutils to get an 'rm' implementation
3721that behaves properly: <http://www.gnu.org/software/coreutils/>.
3722
3723If you want to complete the configuration process using your problematic
3724'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
3725to "yes", and re-run configure.
3726
3727END
3728    as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5
3729  fi
3730fi
3731
3732
3733# Check whether --enable-silent-rules was given.
3734if test "${enable_silent_rules+set}" = set; then :
3735  enableval=$enable_silent_rules;
3736fi
3737
3738case $enable_silent_rules in # (((
3739  yes) AM_DEFAULT_VERBOSITY=0;;
3740   no) AM_DEFAULT_VERBOSITY=1;;
3741    *) AM_DEFAULT_VERBOSITY=0;;
3742esac
3743am_make=${MAKE-make}
3744{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
3745$as_echo_n "checking whether $am_make supports nested variables... " >&6; }
3746if ${am_cv_make_support_nested_variables+:} false; then :
3747  $as_echo_n "(cached) " >&6
3748else
3749  if $as_echo 'TRUE=$(BAR$(V))
3750BAR0=false
3751BAR1=true
3752V=1
3753am__doit:
3754	@$(TRUE)
3755.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
3756  am_cv_make_support_nested_variables=yes
3757else
3758  am_cv_make_support_nested_variables=no
3759fi
3760fi
3761{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
3762$as_echo "$am_cv_make_support_nested_variables" >&6; }
3763if test $am_cv_make_support_nested_variables = yes; then
3764    AM_V='$(V)'
3765  AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
3766else
3767  AM_V=$AM_DEFAULT_VERBOSITY
3768  AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
3769fi
3770AM_BACKSLASH='\'
3771
3772
3773# Make sure we can run config.sub.
3774$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
3775  as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
3776
3777{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
3778$as_echo_n "checking build system type... " >&6; }
3779if ${ac_cv_build+:} false; then :
3780  $as_echo_n "(cached) " >&6
3781else
3782  ac_build_alias=$build_alias
3783test "x$ac_build_alias" = x &&
3784  ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
3785test "x$ac_build_alias" = x &&
3786  as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
3787ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
3788  as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
3789
3790fi
3791{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
3792$as_echo "$ac_cv_build" >&6; }
3793case $ac_cv_build in
3794*-*-*) ;;
3795*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
3796esac
3797build=$ac_cv_build
3798ac_save_IFS=$IFS; IFS='-'
3799set x $ac_cv_build
3800shift
3801build_cpu=$1
3802build_vendor=$2
3803shift; shift
3804# Remember, the first character of IFS is used to create $*,
3805# except with old shells:
3806build_os=$*
3807IFS=$ac_save_IFS
3808case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
3809
3810
3811{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
3812$as_echo_n "checking host system type... " >&6; }
3813if ${ac_cv_host+:} false; then :
3814  $as_echo_n "(cached) " >&6
3815else
3816  if test "x$host_alias" = x; then
3817  ac_cv_host=$ac_cv_build
3818else
3819  ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
3820    as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
3821fi
3822
3823fi
3824{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
3825$as_echo "$ac_cv_host" >&6; }
3826case $ac_cv_host in
3827*-*-*) ;;
3828*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
3829esac
3830host=$ac_cv_host
3831ac_save_IFS=$IFS; IFS='-'
3832set x $ac_cv_host
3833shift
3834host_cpu=$1
3835host_vendor=$2
3836shift; shift
3837# Remember, the first character of IFS is used to create $*,
3838# except with old shells:
3839host_os=$*
3840IFS=$ac_save_IFS
3841case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
3842
3843
3844
3845cat >>confdefs.h <<_ACEOF
3846#define STR_SYSTEM "$host"
3847_ACEOF
3848
3849ac_config_headers="$ac_config_headers config.h"
3850
3851
3852ntp_atom_ok=${ntp_atom_ok=no}
3853ntp_oncore_ok=${ntp_oncore_ok=no}
3854ntp_parse_ok=${ntp_parse_ok=no}
3855ntp_ripe_ncc_ok=${ntp_parse_ok=no}
3856ntp_jupiter_ok=${ntp_jupiter_ok=no}
3857
3858DEPDIR="${am__leading_dot}deps"
3859
3860ac_config_commands="$ac_config_commands depfiles"
3861
3862
3863am_make=${MAKE-make}
3864cat > confinc << 'END'
3865am__doit:
3866	@echo this is the am__doit target
3867.PHONY: am__doit
3868END
3869# If we don't find an include directive, just comment out the code.
3870{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
3871$as_echo_n "checking for style of include used by $am_make... " >&6; }
3872am__include="#"
3873am__quote=
3874_am_result=none
3875# First try GNU make style include.
3876echo "include confinc" > confmf
3877# Ignore all kinds of additional output from 'make'.
3878case `$am_make -s -f confmf 2> /dev/null` in #(
3879*the\ am__doit\ target*)
3880  am__include=include
3881  am__quote=
3882  _am_result=GNU
3883  ;;
3884esac
3885# Now try BSD make style include.
3886if test "$am__include" = "#"; then
3887   echo '.include "confinc"' > confmf
3888   case `$am_make -s -f confmf 2> /dev/null` in #(
3889   *the\ am__doit\ target*)
3890     am__include=.include
3891     am__quote="\""
3892     _am_result=BSD
3893     ;;
3894   esac
3895fi
3896
3897
3898{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
3899$as_echo "$_am_result" >&6; }
3900rm -f confinc confmf
3901
3902# Check whether --enable-dependency-tracking was given.
3903if test "${enable_dependency_tracking+set}" = set; then :
3904  enableval=$enable_dependency_tracking;
3905fi
3906
3907if test "x$enable_dependency_tracking" != xno; then
3908  am_depcomp="$ac_aux_dir/depcomp"
3909  AMDEPBACKSLASH='\'
3910  am__nodep='_no'
3911fi
3912 if test "x$enable_dependency_tracking" != xno; then
3913  AMDEP_TRUE=
3914  AMDEP_FALSE='#'
3915else
3916  AMDEP_TRUE='#'
3917  AMDEP_FALSE=
3918fi
3919
3920
3921
3922case "$build" in
3923 *-*-freebsd1?.*)
3924    cclist=cc
3925    ;;
3926 *)
3927    cclist="cc gcc"
3928    ;;
3929esac
3930
3931
3932#AC_USE_SYSTEM_EXTENSIONS
3933
3934ac_ext=c
3935ac_cpp='$CPP $CPPFLAGS'
3936ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3937ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3938ac_compiler_gnu=$ac_cv_c_compiler_gnu
3939if test -n "$ac_tool_prefix"; then
3940  for ac_prog in $cclist
3941  do
3942    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3943set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3944{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3945$as_echo_n "checking for $ac_word... " >&6; }
3946if ${ac_cv_prog_CC+:} false; then :
3947  $as_echo_n "(cached) " >&6
3948else
3949  if test -n "$CC"; then
3950  ac_cv_prog_CC="$CC" # Let the user override the test.
3951else
3952as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3953for as_dir in $PATH
3954do
3955  IFS=$as_save_IFS
3956  test -z "$as_dir" && as_dir=.
3957    for ac_exec_ext in '' $ac_executable_extensions; do
3958  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3959    ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3960    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3961    break 2
3962  fi
3963done
3964  done
3965IFS=$as_save_IFS
3966
3967fi
3968fi
3969CC=$ac_cv_prog_CC
3970if test -n "$CC"; then
3971  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3972$as_echo "$CC" >&6; }
3973else
3974  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3975$as_echo "no" >&6; }
3976fi
3977
3978
3979    test -n "$CC" && break
3980  done
3981fi
3982if test -z "$CC"; then
3983  ac_ct_CC=$CC
3984  for ac_prog in $cclist
3985do
3986  # Extract the first word of "$ac_prog", so it can be a program name with args.
3987set dummy $ac_prog; ac_word=$2
3988{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3989$as_echo_n "checking for $ac_word... " >&6; }
3990if ${ac_cv_prog_ac_ct_CC+:} false; then :
3991  $as_echo_n "(cached) " >&6
3992else
3993  if test -n "$ac_ct_CC"; then
3994  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3995else
3996as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3997for as_dir in $PATH
3998do
3999  IFS=$as_save_IFS
4000  test -z "$as_dir" && as_dir=.
4001    for ac_exec_ext in '' $ac_executable_extensions; do
4002  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4003    ac_cv_prog_ac_ct_CC="$ac_prog"
4004    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4005    break 2
4006  fi
4007done
4008  done
4009IFS=$as_save_IFS
4010
4011fi
4012fi
4013ac_ct_CC=$ac_cv_prog_ac_ct_CC
4014if test -n "$ac_ct_CC"; then
4015  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4016$as_echo "$ac_ct_CC" >&6; }
4017else
4018  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4019$as_echo "no" >&6; }
4020fi
4021
4022
4023  test -n "$ac_ct_CC" && break
4024done
4025
4026  if test "x$ac_ct_CC" = x; then
4027    CC=""
4028  else
4029    case $cross_compiling:$ac_tool_warned in
4030yes:)
4031{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4032$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4033ac_tool_warned=yes ;;
4034esac
4035    CC=$ac_ct_CC
4036  fi
4037fi
4038
4039
4040test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4041$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4042as_fn_error $? "no acceptable C compiler found in \$PATH
4043See \`config.log' for more details" "$LINENO" 5; }
4044
4045# Provide some information about the compiler.
4046$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
4047set X $ac_compile
4048ac_compiler=$2
4049for ac_option in --version -v -V -qversion; do
4050  { { ac_try="$ac_compiler $ac_option >&5"
4051case "(($ac_try" in
4052  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4053  *) ac_try_echo=$ac_try;;
4054esac
4055eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4056$as_echo "$ac_try_echo"; } >&5
4057  (eval "$ac_compiler $ac_option >&5") 2>conftest.err
4058  ac_status=$?
4059  if test -s conftest.err; then
4060    sed '10a\
4061... rest of stderr output deleted ...
4062         10q' conftest.err >conftest.er1
4063    cat conftest.er1 >&5
4064  fi
4065  rm -f conftest.er1 conftest.err
4066  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4067  test $ac_status = 0; }
4068done
4069
4070cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4071/* end confdefs.h.  */
4072
4073int
4074main ()
4075{
4076
4077  ;
4078  return 0;
4079}
4080_ACEOF
4081ac_clean_files_save=$ac_clean_files
4082ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
4083# Try to create an executable without -o first, disregard a.out.
4084# It will help us diagnose broken compilers, and finding out an intuition
4085# of exeext.
4086{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
4087$as_echo_n "checking whether the C compiler works... " >&6; }
4088ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
4089
4090# The possible output files:
4091ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
4092
4093ac_rmfiles=
4094for ac_file in $ac_files
4095do
4096  case $ac_file in
4097    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4098    * ) ac_rmfiles="$ac_rmfiles $ac_file";;
4099  esac
4100done
4101rm -f $ac_rmfiles
4102
4103if { { ac_try="$ac_link_default"
4104case "(($ac_try" in
4105  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4106  *) ac_try_echo=$ac_try;;
4107esac
4108eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4109$as_echo "$ac_try_echo"; } >&5
4110  (eval "$ac_link_default") 2>&5
4111  ac_status=$?
4112  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4113  test $ac_status = 0; }; then :
4114  # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
4115# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
4116# in a Makefile.  We should not override ac_cv_exeext if it was cached,
4117# so that the user can short-circuit this test for compilers unknown to
4118# Autoconf.
4119for ac_file in $ac_files ''
4120do
4121  test -f "$ac_file" || continue
4122  case $ac_file in
4123    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
4124	;;
4125    [ab].out )
4126	# We found the default executable, but exeext='' is most
4127	# certainly right.
4128	break;;
4129    *.* )
4130	if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
4131	then :; else
4132	   ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4133	fi
4134	# We set ac_cv_exeext here because the later test for it is not
4135	# safe: cross compilers may not add the suffix if given an `-o'
4136	# argument, so we may need to know it at that point already.
4137	# Even if this section looks crufty: it has the advantage of
4138	# actually working.
4139	break;;
4140    * )
4141	break;;
4142  esac
4143done
4144test "$ac_cv_exeext" = no && ac_cv_exeext=
4145
4146else
4147  ac_file=''
4148fi
4149if test -z "$ac_file"; then :
4150  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4151$as_echo "no" >&6; }
4152$as_echo "$as_me: failed program was:" >&5
4153sed 's/^/| /' conftest.$ac_ext >&5
4154
4155{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4156$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4157as_fn_error 77 "C compiler cannot create executables
4158See \`config.log' for more details" "$LINENO" 5; }
4159else
4160  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4161$as_echo "yes" >&6; }
4162fi
4163{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
4164$as_echo_n "checking for C compiler default output file name... " >&6; }
4165{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
4166$as_echo "$ac_file" >&6; }
4167ac_exeext=$ac_cv_exeext
4168
4169rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
4170ac_clean_files=$ac_clean_files_save
4171{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
4172$as_echo_n "checking for suffix of executables... " >&6; }
4173if { { ac_try="$ac_link"
4174case "(($ac_try" in
4175  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4176  *) ac_try_echo=$ac_try;;
4177esac
4178eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4179$as_echo "$ac_try_echo"; } >&5
4180  (eval "$ac_link") 2>&5
4181  ac_status=$?
4182  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4183  test $ac_status = 0; }; then :
4184  # If both `conftest.exe' and `conftest' are `present' (well, observable)
4185# catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
4186# work properly (i.e., refer to `conftest.exe'), while it won't with
4187# `rm'.
4188for ac_file in conftest.exe conftest conftest.*; do
4189  test -f "$ac_file" || continue
4190  case $ac_file in
4191    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4192    *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4193	  break;;
4194    * ) break;;
4195  esac
4196done
4197else
4198  { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4199$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4200as_fn_error $? "cannot compute suffix of executables: cannot compile and link
4201See \`config.log' for more details" "$LINENO" 5; }
4202fi
4203rm -f conftest conftest$ac_cv_exeext
4204{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
4205$as_echo "$ac_cv_exeext" >&6; }
4206
4207rm -f conftest.$ac_ext
4208EXEEXT=$ac_cv_exeext
4209ac_exeext=$EXEEXT
4210cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4211/* end confdefs.h.  */
4212#include <stdio.h>
4213int
4214main ()
4215{
4216FILE *f = fopen ("conftest.out", "w");
4217 return ferror (f) || fclose (f) != 0;
4218
4219  ;
4220  return 0;
4221}
4222_ACEOF
4223ac_clean_files="$ac_clean_files conftest.out"
4224# Check that the compiler produces executables we can run.  If not, either
4225# the compiler is broken, or we cross compile.
4226{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
4227$as_echo_n "checking whether we are cross compiling... " >&6; }
4228if test "$cross_compiling" != yes; then
4229  { { ac_try="$ac_link"
4230case "(($ac_try" in
4231  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4232  *) ac_try_echo=$ac_try;;
4233esac
4234eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4235$as_echo "$ac_try_echo"; } >&5
4236  (eval "$ac_link") 2>&5
4237  ac_status=$?
4238  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4239  test $ac_status = 0; }
4240  if { ac_try='./conftest$ac_cv_exeext'
4241  { { case "(($ac_try" in
4242  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4243  *) ac_try_echo=$ac_try;;
4244esac
4245eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4246$as_echo "$ac_try_echo"; } >&5
4247  (eval "$ac_try") 2>&5
4248  ac_status=$?
4249  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4250  test $ac_status = 0; }; }; then
4251    cross_compiling=no
4252  else
4253    if test "$cross_compiling" = maybe; then
4254	cross_compiling=yes
4255    else
4256	{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4257$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4258as_fn_error $? "cannot run C compiled programs.
4259If you meant to cross compile, use \`--host'.
4260See \`config.log' for more details" "$LINENO" 5; }
4261    fi
4262  fi
4263fi
4264{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
4265$as_echo "$cross_compiling" >&6; }
4266
4267rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
4268ac_clean_files=$ac_clean_files_save
4269{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
4270$as_echo_n "checking for suffix of object files... " >&6; }
4271if ${ac_cv_objext+:} false; then :
4272  $as_echo_n "(cached) " >&6
4273else
4274  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4275/* end confdefs.h.  */
4276
4277int
4278main ()
4279{
4280
4281  ;
4282  return 0;
4283}
4284_ACEOF
4285rm -f conftest.o conftest.obj
4286if { { ac_try="$ac_compile"
4287case "(($ac_try" in
4288  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4289  *) ac_try_echo=$ac_try;;
4290esac
4291eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4292$as_echo "$ac_try_echo"; } >&5
4293  (eval "$ac_compile") 2>&5
4294  ac_status=$?
4295  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4296  test $ac_status = 0; }; then :
4297  for ac_file in conftest.o conftest.obj conftest.*; do
4298  test -f "$ac_file" || continue;
4299  case $ac_file in
4300    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
4301    *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
4302       break;;
4303  esac
4304done
4305else
4306  $as_echo "$as_me: failed program was:" >&5
4307sed 's/^/| /' conftest.$ac_ext >&5
4308
4309{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4310$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4311as_fn_error $? "cannot compute suffix of object files: cannot compile
4312See \`config.log' for more details" "$LINENO" 5; }
4313fi
4314rm -f conftest.$ac_cv_objext conftest.$ac_ext
4315fi
4316{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
4317$as_echo "$ac_cv_objext" >&6; }
4318OBJEXT=$ac_cv_objext
4319ac_objext=$OBJEXT
4320{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
4321$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
4322if ${ac_cv_c_compiler_gnu+:} false; then :
4323  $as_echo_n "(cached) " >&6
4324else
4325  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4326/* end confdefs.h.  */
4327
4328int
4329main ()
4330{
4331#ifndef __GNUC__
4332       choke me
4333#endif
4334
4335  ;
4336  return 0;
4337}
4338_ACEOF
4339if ac_fn_c_try_compile "$LINENO"; then :
4340  ac_compiler_gnu=yes
4341else
4342  ac_compiler_gnu=no
4343fi
4344rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4345ac_cv_c_compiler_gnu=$ac_compiler_gnu
4346
4347fi
4348{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
4349$as_echo "$ac_cv_c_compiler_gnu" >&6; }
4350if test $ac_compiler_gnu = yes; then
4351  GCC=yes
4352else
4353  GCC=
4354fi
4355ac_test_CFLAGS=${CFLAGS+set}
4356ac_save_CFLAGS=$CFLAGS
4357{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
4358$as_echo_n "checking whether $CC accepts -g... " >&6; }
4359if ${ac_cv_prog_cc_g+:} false; then :
4360  $as_echo_n "(cached) " >&6
4361else
4362  ac_save_c_werror_flag=$ac_c_werror_flag
4363   ac_c_werror_flag=yes
4364   ac_cv_prog_cc_g=no
4365   CFLAGS="-g"
4366   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4367/* end confdefs.h.  */
4368
4369int
4370main ()
4371{
4372
4373  ;
4374  return 0;
4375}
4376_ACEOF
4377if ac_fn_c_try_compile "$LINENO"; then :
4378  ac_cv_prog_cc_g=yes
4379else
4380  CFLAGS=""
4381      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4382/* end confdefs.h.  */
4383
4384int
4385main ()
4386{
4387
4388  ;
4389  return 0;
4390}
4391_ACEOF
4392if ac_fn_c_try_compile "$LINENO"; then :
4393
4394else
4395  ac_c_werror_flag=$ac_save_c_werror_flag
4396	 CFLAGS="-g"
4397	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4398/* end confdefs.h.  */
4399
4400int
4401main ()
4402{
4403
4404  ;
4405  return 0;
4406}
4407_ACEOF
4408if ac_fn_c_try_compile "$LINENO"; then :
4409  ac_cv_prog_cc_g=yes
4410fi
4411rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4412fi
4413rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4414fi
4415rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4416   ac_c_werror_flag=$ac_save_c_werror_flag
4417fi
4418{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
4419$as_echo "$ac_cv_prog_cc_g" >&6; }
4420if test "$ac_test_CFLAGS" = set; then
4421  CFLAGS=$ac_save_CFLAGS
4422elif test $ac_cv_prog_cc_g = yes; then
4423  if test "$GCC" = yes; then
4424    CFLAGS="-g -O2"
4425  else
4426    CFLAGS="-g"
4427  fi
4428else
4429  if test "$GCC" = yes; then
4430    CFLAGS="-O2"
4431  else
4432    CFLAGS=
4433  fi
4434fi
4435{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
4436$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
4437if ${ac_cv_prog_cc_c89+:} false; then :
4438  $as_echo_n "(cached) " >&6
4439else
4440  ac_cv_prog_cc_c89=no
4441ac_save_CC=$CC
4442cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4443/* end confdefs.h.  */
4444#include <stdarg.h>
4445#include <stdio.h>
4446struct stat;
4447/* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
4448struct buf { int x; };
4449FILE * (*rcsopen) (struct buf *, struct stat *, int);
4450static char *e (p, i)
4451     char **p;
4452     int i;
4453{
4454  return p[i];
4455}
4456static char *f (char * (*g) (char **, int), char **p, ...)
4457{
4458  char *s;
4459  va_list v;
4460  va_start (v,p);
4461  s = g (p, va_arg (v,int));
4462  va_end (v);
4463  return s;
4464}
4465
4466/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
4467   function prototypes and stuff, but not '\xHH' hex character constants.
4468   These don't provoke an error unfortunately, instead are silently treated
4469   as 'x'.  The following induces an error, until -std is added to get
4470   proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
4471   array size at least.  It's necessary to write '\x00'==0 to get something
4472   that's true only with -std.  */
4473int osf4_cc_array ['\x00' == 0 ? 1 : -1];
4474
4475/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
4476   inside strings and character constants.  */
4477#define FOO(x) 'x'
4478int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
4479
4480int test (int i, double x);
4481struct s1 {int (*f) (int a);};
4482struct s2 {int (*f) (double a);};
4483int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4484int argc;
4485char **argv;
4486int
4487main ()
4488{
4489return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
4490  ;
4491  return 0;
4492}
4493_ACEOF
4494for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
4495	-Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4496do
4497  CC="$ac_save_CC $ac_arg"
4498  if ac_fn_c_try_compile "$LINENO"; then :
4499  ac_cv_prog_cc_c89=$ac_arg
4500fi
4501rm -f core conftest.err conftest.$ac_objext
4502  test "x$ac_cv_prog_cc_c89" != "xno" && break
4503done
4504rm -f conftest.$ac_ext
4505CC=$ac_save_CC
4506
4507fi
4508# AC_CACHE_VAL
4509case "x$ac_cv_prog_cc_c89" in
4510  x)
4511    { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4512$as_echo "none needed" >&6; } ;;
4513  xno)
4514    { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4515$as_echo "unsupported" >&6; } ;;
4516  *)
4517    CC="$CC $ac_cv_prog_cc_c89"
4518    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
4519$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
4520esac
4521if test "x$ac_cv_prog_cc_c89" != xno; then :
4522
4523fi
4524
4525ac_ext=c
4526ac_cpp='$CPP $CPPFLAGS'
4527ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4528ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4529ac_compiler_gnu=$ac_cv_c_compiler_gnu
4530
4531ac_ext=c
4532ac_cpp='$CPP $CPPFLAGS'
4533ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4534ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4535ac_compiler_gnu=$ac_cv_c_compiler_gnu
4536{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5
4537$as_echo_n "checking whether $CC understands -c and -o together... " >&6; }
4538if ${am_cv_prog_cc_c_o+:} false; then :
4539  $as_echo_n "(cached) " >&6
4540else
4541  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4542/* end confdefs.h.  */
4543
4544int
4545main ()
4546{
4547
4548  ;
4549  return 0;
4550}
4551_ACEOF
4552  # Make sure it works both with $CC and with simple cc.
4553  # Following AC_PROG_CC_C_O, we do the test twice because some
4554  # compilers refuse to overwrite an existing .o file with -o,
4555  # though they will create one.
4556  am_cv_prog_cc_c_o=yes
4557  for am_i in 1 2; do
4558    if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5
4559   ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5
4560   ac_status=$?
4561   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4562   (exit $ac_status); } \
4563         && test -f conftest2.$ac_objext; then
4564      : OK
4565    else
4566      am_cv_prog_cc_c_o=no
4567      break
4568    fi
4569  done
4570  rm -f core conftest*
4571  unset am_i
4572fi
4573{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5
4574$as_echo "$am_cv_prog_cc_c_o" >&6; }
4575if test "$am_cv_prog_cc_c_o" != yes; then
4576   # Losing compiler, so override with the script.
4577   # FIXME: It is wrong to rewrite CC.
4578   # But if we don't then we get into trouble of one sort or another.
4579   # A longer-term fix would be to have automake use am__CC in this case,
4580   # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
4581   CC="$am_aux_dir/compile $CC"
4582fi
4583ac_ext=c
4584ac_cpp='$CPP $CPPFLAGS'
4585ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4586ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4587ac_compiler_gnu=$ac_cv_c_compiler_gnu
4588
4589
4590depcc="$CC"   am_compiler_list=
4591
4592{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
4593$as_echo_n "checking dependency style of $depcc... " >&6; }
4594if ${am_cv_CC_dependencies_compiler_type+:} false; then :
4595  $as_echo_n "(cached) " >&6
4596else
4597  if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
4598  # We make a subdir and do the tests there.  Otherwise we can end up
4599  # making bogus files that we don't know about and never remove.  For
4600  # instance it was reported that on HP-UX the gcc test will end up
4601  # making a dummy file named 'D' -- because '-MD' means "put the output
4602  # in D".
4603  rm -rf conftest.dir
4604  mkdir conftest.dir
4605  # Copy depcomp to subdir because otherwise we won't find it if we're
4606  # using a relative directory.
4607  cp "$am_depcomp" conftest.dir
4608  cd conftest.dir
4609  # We will build objects and dependencies in a subdirectory because
4610  # it helps to detect inapplicable dependency modes.  For instance
4611  # both Tru64's cc and ICC support -MD to output dependencies as a
4612  # side effect of compilation, but ICC will put the dependencies in
4613  # the current directory while Tru64 will put them in the object
4614  # directory.
4615  mkdir sub
4616
4617  am_cv_CC_dependencies_compiler_type=none
4618  if test "$am_compiler_list" = ""; then
4619     am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
4620  fi
4621  am__universal=false
4622  case " $depcc " in #(
4623     *\ -arch\ *\ -arch\ *) am__universal=true ;;
4624     esac
4625
4626  for depmode in $am_compiler_list; do
4627    # Setup a source with many dependencies, because some compilers
4628    # like to wrap large dependency lists on column 80 (with \), and
4629    # we should not choose a depcomp mode which is confused by this.
4630    #
4631    # We need to recreate these files for each test, as the compiler may
4632    # overwrite some of them when testing with obscure command lines.
4633    # This happens at least with the AIX C compiler.
4634    : > sub/conftest.c
4635    for i in 1 2 3 4 5 6; do
4636      echo '#include "conftst'$i'.h"' >> sub/conftest.c
4637      # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
4638      # Solaris 10 /bin/sh.
4639      echo '/* dummy */' > sub/conftst$i.h
4640    done
4641    echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
4642
4643    # We check with '-c' and '-o' for the sake of the "dashmstdout"
4644    # mode.  It turns out that the SunPro C++ compiler does not properly
4645    # handle '-M -o', and we need to detect this.  Also, some Intel
4646    # versions had trouble with output in subdirs.
4647    am__obj=sub/conftest.${OBJEXT-o}
4648    am__minus_obj="-o $am__obj"
4649    case $depmode in
4650    gcc)
4651      # This depmode causes a compiler race in universal mode.
4652      test "$am__universal" = false || continue
4653      ;;
4654    nosideeffect)
4655      # After this tag, mechanisms are not by side-effect, so they'll
4656      # only be used when explicitly requested.
4657      if test "x$enable_dependency_tracking" = xyes; then
4658	continue
4659      else
4660	break
4661      fi
4662      ;;
4663    msvc7 | msvc7msys | msvisualcpp | msvcmsys)
4664      # This compiler won't grok '-c -o', but also, the minuso test has
4665      # not run yet.  These depmodes are late enough in the game, and
4666      # so weak that their functioning should not be impacted.
4667      am__obj=conftest.${OBJEXT-o}
4668      am__minus_obj=
4669      ;;
4670    none) break ;;
4671    esac
4672    if depmode=$depmode \
4673       source=sub/conftest.c object=$am__obj \
4674       depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
4675       $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
4676         >/dev/null 2>conftest.err &&
4677       grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
4678       grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
4679       grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
4680       ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
4681      # icc doesn't choke on unknown options, it will just issue warnings
4682      # or remarks (even with -Werror).  So we grep stderr for any message
4683      # that says an option was ignored or not supported.
4684      # When given -MP, icc 7.0 and 7.1 complain thusly:
4685      #   icc: Command line warning: ignoring option '-M'; no argument required
4686      # The diagnosis changed in icc 8.0:
4687      #   icc: Command line remark: option '-MP' not supported
4688      if (grep 'ignoring option' conftest.err ||
4689          grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
4690        am_cv_CC_dependencies_compiler_type=$depmode
4691        break
4692      fi
4693    fi
4694  done
4695
4696  cd ..
4697  rm -rf conftest.dir
4698else
4699  am_cv_CC_dependencies_compiler_type=none
4700fi
4701
4702fi
4703{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
4704$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
4705CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
4706
4707 if
4708  test "x$enable_dependency_tracking" != xno \
4709  && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
4710  am__fastdepCC_TRUE=
4711  am__fastdepCC_FALSE='#'
4712else
4713  am__fastdepCC_TRUE='#'
4714  am__fastdepCC_FALSE=
4715fi
4716
4717
4718
4719
4720
4721ac_ext=c
4722ac_cpp='$CPP $CPPFLAGS'
4723ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4724ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4725ac_compiler_gnu=$ac_cv_c_compiler_gnu
4726{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
4727$as_echo_n "checking how to run the C preprocessor... " >&6; }
4728# On Suns, sometimes $CPP names a directory.
4729if test -n "$CPP" && test -d "$CPP"; then
4730  CPP=
4731fi
4732if test -z "$CPP"; then
4733  if ${ac_cv_prog_CPP+:} false; then :
4734  $as_echo_n "(cached) " >&6
4735else
4736      # Double quotes because CPP needs to be expanded
4737    for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
4738    do
4739      ac_preproc_ok=false
4740for ac_c_preproc_warn_flag in '' yes
4741do
4742  # Use a header file that comes with gcc, so configuring glibc
4743  # with a fresh cross-compiler works.
4744  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4745  # <limits.h> exists even on freestanding compilers.
4746  # On the NeXT, cc -E runs the code through the compiler's parser,
4747  # not just through cpp. "Syntax error" is here to catch this case.
4748  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4749/* end confdefs.h.  */
4750#ifdef __STDC__
4751# include <limits.h>
4752#else
4753# include <assert.h>
4754#endif
4755		     Syntax error
4756_ACEOF
4757if ac_fn_c_try_cpp "$LINENO"; then :
4758
4759else
4760  # Broken: fails on valid input.
4761continue
4762fi
4763rm -f conftest.err conftest.i conftest.$ac_ext
4764
4765  # OK, works on sane cases.  Now check whether nonexistent headers
4766  # can be detected and how.
4767  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4768/* end confdefs.h.  */
4769#include <ac_nonexistent.h>
4770_ACEOF
4771if ac_fn_c_try_cpp "$LINENO"; then :
4772  # Broken: success on invalid input.
4773continue
4774else
4775  # Passes both tests.
4776ac_preproc_ok=:
4777break
4778fi
4779rm -f conftest.err conftest.i conftest.$ac_ext
4780
4781done
4782# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4783rm -f conftest.i conftest.err conftest.$ac_ext
4784if $ac_preproc_ok; then :
4785  break
4786fi
4787
4788    done
4789    ac_cv_prog_CPP=$CPP
4790
4791fi
4792  CPP=$ac_cv_prog_CPP
4793else
4794  ac_cv_prog_CPP=$CPP
4795fi
4796{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
4797$as_echo "$CPP" >&6; }
4798ac_preproc_ok=false
4799for ac_c_preproc_warn_flag in '' yes
4800do
4801  # Use a header file that comes with gcc, so configuring glibc
4802  # with a fresh cross-compiler works.
4803  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4804  # <limits.h> exists even on freestanding compilers.
4805  # On the NeXT, cc -E runs the code through the compiler's parser,
4806  # not just through cpp. "Syntax error" is here to catch this case.
4807  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4808/* end confdefs.h.  */
4809#ifdef __STDC__
4810# include <limits.h>
4811#else
4812# include <assert.h>
4813#endif
4814		     Syntax error
4815_ACEOF
4816if ac_fn_c_try_cpp "$LINENO"; then :
4817
4818else
4819  # Broken: fails on valid input.
4820continue
4821fi
4822rm -f conftest.err conftest.i conftest.$ac_ext
4823
4824  # OK, works on sane cases.  Now check whether nonexistent headers
4825  # can be detected and how.
4826  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4827/* end confdefs.h.  */
4828#include <ac_nonexistent.h>
4829_ACEOF
4830if ac_fn_c_try_cpp "$LINENO"; then :
4831  # Broken: success on invalid input.
4832continue
4833else
4834  # Passes both tests.
4835ac_preproc_ok=:
4836break
4837fi
4838rm -f conftest.err conftest.i conftest.$ac_ext
4839
4840done
4841# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4842rm -f conftest.i conftest.err conftest.$ac_ext
4843if $ac_preproc_ok; then :
4844
4845else
4846  { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4847$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4848as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
4849See \`config.log' for more details" "$LINENO" 5; }
4850fi
4851
4852ac_ext=c
4853ac_cpp='$CPP $CPPFLAGS'
4854ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4855ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4856ac_compiler_gnu=$ac_cv_c_compiler_gnu
4857
4858
4859{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
4860$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
4861if ${ac_cv_path_GREP+:} false; then :
4862  $as_echo_n "(cached) " >&6
4863else
4864  if test -z "$GREP"; then
4865  ac_path_GREP_found=false
4866  # Loop through the user's path and test for each of PROGNAME-LIST
4867  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4868for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4869do
4870  IFS=$as_save_IFS
4871  test -z "$as_dir" && as_dir=.
4872    for ac_prog in grep ggrep; do
4873    for ac_exec_ext in '' $ac_executable_extensions; do
4874      ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
4875      as_fn_executable_p "$ac_path_GREP" || continue
4876# Check for GNU ac_path_GREP and select it if it is found.
4877  # Check for GNU $ac_path_GREP
4878case `"$ac_path_GREP" --version 2>&1` in
4879*GNU*)
4880  ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
4881*)
4882  ac_count=0
4883  $as_echo_n 0123456789 >"conftest.in"
4884  while :
4885  do
4886    cat "conftest.in" "conftest.in" >"conftest.tmp"
4887    mv "conftest.tmp" "conftest.in"
4888    cp "conftest.in" "conftest.nl"
4889    $as_echo 'GREP' >> "conftest.nl"
4890    "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4891    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4892    as_fn_arith $ac_count + 1 && ac_count=$as_val
4893    if test $ac_count -gt ${ac_path_GREP_max-0}; then
4894      # Best one so far, save it but keep looking for a better one
4895      ac_cv_path_GREP="$ac_path_GREP"
4896      ac_path_GREP_max=$ac_count
4897    fi
4898    # 10*(2^10) chars as input seems more than enough
4899    test $ac_count -gt 10 && break
4900  done
4901  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4902esac
4903
4904      $ac_path_GREP_found && break 3
4905    done
4906  done
4907  done
4908IFS=$as_save_IFS
4909  if test -z "$ac_cv_path_GREP"; then
4910    as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4911  fi
4912else
4913  ac_cv_path_GREP=$GREP
4914fi
4915
4916fi
4917{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
4918$as_echo "$ac_cv_path_GREP" >&6; }
4919 GREP="$ac_cv_path_GREP"
4920
4921
4922{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
4923$as_echo_n "checking for egrep... " >&6; }
4924if ${ac_cv_path_EGREP+:} false; then :
4925  $as_echo_n "(cached) " >&6
4926else
4927  if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
4928   then ac_cv_path_EGREP="$GREP -E"
4929   else
4930     if test -z "$EGREP"; then
4931  ac_path_EGREP_found=false
4932  # Loop through the user's path and test for each of PROGNAME-LIST
4933  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4934for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4935do
4936  IFS=$as_save_IFS
4937  test -z "$as_dir" && as_dir=.
4938    for ac_prog in egrep; do
4939    for ac_exec_ext in '' $ac_executable_extensions; do
4940      ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
4941      as_fn_executable_p "$ac_path_EGREP" || continue
4942# Check for GNU ac_path_EGREP and select it if it is found.
4943  # Check for GNU $ac_path_EGREP
4944case `"$ac_path_EGREP" --version 2>&1` in
4945*GNU*)
4946  ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
4947*)
4948  ac_count=0
4949  $as_echo_n 0123456789 >"conftest.in"
4950  while :
4951  do
4952    cat "conftest.in" "conftest.in" >"conftest.tmp"
4953    mv "conftest.tmp" "conftest.in"
4954    cp "conftest.in" "conftest.nl"
4955    $as_echo 'EGREP' >> "conftest.nl"
4956    "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4957    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4958    as_fn_arith $ac_count + 1 && ac_count=$as_val
4959    if test $ac_count -gt ${ac_path_EGREP_max-0}; then
4960      # Best one so far, save it but keep looking for a better one
4961      ac_cv_path_EGREP="$ac_path_EGREP"
4962      ac_path_EGREP_max=$ac_count
4963    fi
4964    # 10*(2^10) chars as input seems more than enough
4965    test $ac_count -gt 10 && break
4966  done
4967  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4968esac
4969
4970      $ac_path_EGREP_found && break 3
4971    done
4972  done
4973  done
4974IFS=$as_save_IFS
4975  if test -z "$ac_cv_path_EGREP"; then
4976    as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4977  fi
4978else
4979  ac_cv_path_EGREP=$EGREP
4980fi
4981
4982   fi
4983fi
4984{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
4985$as_echo "$ac_cv_path_EGREP" >&6; }
4986 EGREP="$ac_cv_path_EGREP"
4987
4988
4989{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
4990$as_echo_n "checking for ANSI C header files... " >&6; }
4991if ${ac_cv_header_stdc+:} false; then :
4992  $as_echo_n "(cached) " >&6
4993else
4994  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4995/* end confdefs.h.  */
4996#include <stdlib.h>
4997#include <stdarg.h>
4998#include <string.h>
4999#include <float.h>
5000
5001int
5002main ()
5003{
5004
5005  ;
5006  return 0;
5007}
5008_ACEOF
5009if ac_fn_c_try_compile "$LINENO"; then :
5010  ac_cv_header_stdc=yes
5011else
5012  ac_cv_header_stdc=no
5013fi
5014rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5015
5016if test $ac_cv_header_stdc = yes; then
5017  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
5018  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5019/* end confdefs.h.  */
5020#include <string.h>
5021
5022_ACEOF
5023if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5024  $EGREP "memchr" >/dev/null 2>&1; then :
5025
5026else
5027  ac_cv_header_stdc=no
5028fi
5029rm -f conftest*
5030
5031fi
5032
5033if test $ac_cv_header_stdc = yes; then
5034  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
5035  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5036/* end confdefs.h.  */
5037#include <stdlib.h>
5038
5039_ACEOF
5040if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5041  $EGREP "free" >/dev/null 2>&1; then :
5042
5043else
5044  ac_cv_header_stdc=no
5045fi
5046rm -f conftest*
5047
5048fi
5049
5050if test $ac_cv_header_stdc = yes; then
5051  # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
5052  if test "$cross_compiling" = yes; then :
5053  :
5054else
5055  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5056/* end confdefs.h.  */
5057#include <ctype.h>
5058#include <stdlib.h>
5059#if ((' ' & 0x0FF) == 0x020)
5060# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
5061# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
5062#else
5063# define ISLOWER(c) \
5064		   (('a' <= (c) && (c) <= 'i') \
5065		     || ('j' <= (c) && (c) <= 'r') \
5066		     || ('s' <= (c) && (c) <= 'z'))
5067# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
5068#endif
5069
5070#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
5071int
5072main ()
5073{
5074  int i;
5075  for (i = 0; i < 256; i++)
5076    if (XOR (islower (i), ISLOWER (i))
5077	|| toupper (i) != TOUPPER (i))
5078      return 2;
5079  return 0;
5080}
5081_ACEOF
5082if ac_fn_c_try_run "$LINENO"; then :
5083
5084else
5085  ac_cv_header_stdc=no
5086fi
5087rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
5088  conftest.$ac_objext conftest.beam conftest.$ac_ext
5089fi
5090
5091fi
5092fi
5093{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
5094$as_echo "$ac_cv_header_stdc" >&6; }
5095if test $ac_cv_header_stdc = yes; then
5096
5097$as_echo "#define STDC_HEADERS 1" >>confdefs.h
5098
5099fi
5100
5101# On IRIX 5.3, sys/types and inttypes.h are conflicting.
5102for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
5103		  inttypes.h stdint.h unistd.h
5104do :
5105  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
5106ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
5107"
5108if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
5109  cat >>confdefs.h <<_ACEOF
5110#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
5111_ACEOF
5112
5113fi
5114
5115done
5116
5117
5118
5119
5120
5121  ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
5122if test "x$ac_cv_header_minix_config_h" = xyes; then :
5123  MINIX=yes
5124else
5125  MINIX=
5126fi
5127
5128
5129  if test "$MINIX" = yes; then
5130
5131$as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
5132
5133
5134$as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
5135
5136
5137$as_echo "#define _MINIX 1" >>confdefs.h
5138
5139  fi
5140
5141        case "$host_os" in
5142    hpux*)
5143
5144$as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h
5145
5146      ;;
5147  esac
5148
5149
5150  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
5151$as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
5152if ${ac_cv_safe_to_define___extensions__+:} false; then :
5153  $as_echo_n "(cached) " >&6
5154else
5155  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5156/* end confdefs.h.  */
5157
5158#         define __EXTENSIONS__ 1
5159          $ac_includes_default
5160int
5161main ()
5162{
5163
5164  ;
5165  return 0;
5166}
5167_ACEOF
5168if ac_fn_c_try_compile "$LINENO"; then :
5169  ac_cv_safe_to_define___extensions__=yes
5170else
5171  ac_cv_safe_to_define___extensions__=no
5172fi
5173rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5174fi
5175{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
5176$as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
5177  test $ac_cv_safe_to_define___extensions__ = yes &&
5178    $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
5179
5180  $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
5181
5182  $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
5183
5184  $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
5185
5186  $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
5187
5188
5189
5190   case $ac_cv_prog_cc_stdc in #(
5191  no) :
5192    ac_cv_prog_cc_c99=no; ac_cv_prog_cc_c89=no ;; #(
5193  *) :
5194    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5
5195$as_echo_n "checking for $CC option to accept ISO C99... " >&6; }
5196if ${ac_cv_prog_cc_c99+:} false; then :
5197  $as_echo_n "(cached) " >&6
5198else
5199  ac_cv_prog_cc_c99=no
5200ac_save_CC=$CC
5201cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5202/* end confdefs.h.  */
5203#include <stdarg.h>
5204#include <stdbool.h>
5205#include <stdlib.h>
5206#include <wchar.h>
5207#include <stdio.h>
5208
5209// Check varargs macros.  These examples are taken from C99 6.10.3.5.
5210#define debug(...) fprintf (stderr, __VA_ARGS__)
5211#define showlist(...) puts (#__VA_ARGS__)
5212#define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
5213static void
5214test_varargs_macros (void)
5215{
5216  int x = 1234;
5217  int y = 5678;
5218  debug ("Flag");
5219  debug ("X = %d\n", x);
5220  showlist (The first, second, and third items.);
5221  report (x>y, "x is %d but y is %d", x, y);
5222}
5223
5224// Check long long types.
5225#define BIG64 18446744073709551615ull
5226#define BIG32 4294967295ul
5227#define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
5228#if !BIG_OK
5229  your preprocessor is broken;
5230#endif
5231#if BIG_OK
5232#else
5233  your preprocessor is broken;
5234#endif
5235static long long int bignum = -9223372036854775807LL;
5236static unsigned long long int ubignum = BIG64;
5237
5238struct incomplete_array
5239{
5240  int datasize;
5241  double data[];
5242};
5243
5244struct named_init {
5245  int number;
5246  const wchar_t *name;
5247  double average;
5248};
5249
5250typedef const char *ccp;
5251
5252static inline int
5253test_restrict (ccp restrict text)
5254{
5255  // See if C++-style comments work.
5256  // Iterate through items via the restricted pointer.
5257  // Also check for declarations in for loops.
5258  for (unsigned int i = 0; *(text+i) != '\0'; ++i)
5259    continue;
5260  return 0;
5261}
5262
5263// Check varargs and va_copy.
5264static void
5265test_varargs (const char *format, ...)
5266{
5267  va_list args;
5268  va_start (args, format);
5269  va_list args_copy;
5270  va_copy (args_copy, args);
5271
5272  const char *str;
5273  int number;
5274  float fnumber;
5275
5276  while (*format)
5277    {
5278      switch (*format++)
5279	{
5280	case 's': // string
5281	  str = va_arg (args_copy, const char *);
5282	  break;
5283	case 'd': // int
5284	  number = va_arg (args_copy, int);
5285	  break;
5286	case 'f': // float
5287	  fnumber = va_arg (args_copy, double);
5288	  break;
5289	default:
5290	  break;
5291	}
5292    }
5293  va_end (args_copy);
5294  va_end (args);
5295}
5296
5297int
5298main ()
5299{
5300
5301  // Check bool.
5302  _Bool success = false;
5303
5304  // Check restrict.
5305  if (test_restrict ("String literal") == 0)
5306    success = true;
5307  char *restrict newvar = "Another string";
5308
5309  // Check varargs.
5310  test_varargs ("s, d' f .", "string", 65, 34.234);
5311  test_varargs_macros ();
5312
5313  // Check flexible array members.
5314  struct incomplete_array *ia =
5315    malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
5316  ia->datasize = 10;
5317  for (int i = 0; i < ia->datasize; ++i)
5318    ia->data[i] = i * 1.234;
5319
5320  // Check named initializers.
5321  struct named_init ni = {
5322    .number = 34,
5323    .name = L"Test wide string",
5324    .average = 543.34343,
5325  };
5326
5327  ni.number = 58;
5328
5329  int dynamic_array[ni.number];
5330  dynamic_array[ni.number - 1] = 543;
5331
5332  // work around unused variable warnings
5333  return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
5334	  || dynamic_array[ni.number - 1] != 543);
5335
5336  ;
5337  return 0;
5338}
5339_ACEOF
5340for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -D_STDC_C99= -qlanglvl=extc99
5341do
5342  CC="$ac_save_CC $ac_arg"
5343  if ac_fn_c_try_compile "$LINENO"; then :
5344  ac_cv_prog_cc_c99=$ac_arg
5345fi
5346rm -f core conftest.err conftest.$ac_objext
5347  test "x$ac_cv_prog_cc_c99" != "xno" && break
5348done
5349rm -f conftest.$ac_ext
5350CC=$ac_save_CC
5351
5352fi
5353# AC_CACHE_VAL
5354case "x$ac_cv_prog_cc_c99" in
5355  x)
5356    { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5357$as_echo "none needed" >&6; } ;;
5358  xno)
5359    { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5360$as_echo "unsupported" >&6; } ;;
5361  *)
5362    CC="$CC $ac_cv_prog_cc_c99"
5363    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
5364$as_echo "$ac_cv_prog_cc_c99" >&6; } ;;
5365esac
5366if test "x$ac_cv_prog_cc_c99" != xno; then :
5367  ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
5368else
5369  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
5370$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
5371if ${ac_cv_prog_cc_c89+:} false; then :
5372  $as_echo_n "(cached) " >&6
5373else
5374  ac_cv_prog_cc_c89=no
5375ac_save_CC=$CC
5376cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5377/* end confdefs.h.  */
5378#include <stdarg.h>
5379#include <stdio.h>
5380struct stat;
5381/* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
5382struct buf { int x; };
5383FILE * (*rcsopen) (struct buf *, struct stat *, int);
5384static char *e (p, i)
5385     char **p;
5386     int i;
5387{
5388  return p[i];
5389}
5390static char *f (char * (*g) (char **, int), char **p, ...)
5391{
5392  char *s;
5393  va_list v;
5394  va_start (v,p);
5395  s = g (p, va_arg (v,int));
5396  va_end (v);
5397  return s;
5398}
5399
5400/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
5401   function prototypes and stuff, but not '\xHH' hex character constants.
5402   These don't provoke an error unfortunately, instead are silently treated
5403   as 'x'.  The following induces an error, until -std is added to get
5404   proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
5405   array size at least.  It's necessary to write '\x00'==0 to get something
5406   that's true only with -std.  */
5407int osf4_cc_array ['\x00' == 0 ? 1 : -1];
5408
5409/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
5410   inside strings and character constants.  */
5411#define FOO(x) 'x'
5412int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
5413
5414int test (int i, double x);
5415struct s1 {int (*f) (int a);};
5416struct s2 {int (*f) (double a);};
5417int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
5418int argc;
5419char **argv;
5420int
5421main ()
5422{
5423return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
5424  ;
5425  return 0;
5426}
5427_ACEOF
5428for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5429	-Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5430do
5431  CC="$ac_save_CC $ac_arg"
5432  if ac_fn_c_try_compile "$LINENO"; then :
5433  ac_cv_prog_cc_c89=$ac_arg
5434fi
5435rm -f core conftest.err conftest.$ac_objext
5436  test "x$ac_cv_prog_cc_c89" != "xno" && break
5437done
5438rm -f conftest.$ac_ext
5439CC=$ac_save_CC
5440
5441fi
5442# AC_CACHE_VAL
5443case "x$ac_cv_prog_cc_c89" in
5444  x)
5445    { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5446$as_echo "none needed" >&6; } ;;
5447  xno)
5448    { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5449$as_echo "unsupported" >&6; } ;;
5450  *)
5451    CC="$CC $ac_cv_prog_cc_c89"
5452    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5453$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
5454esac
5455if test "x$ac_cv_prog_cc_c89" != xno; then :
5456  ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
5457else
5458  ac_cv_prog_cc_stdc=no
5459fi
5460
5461fi
5462 ;;
5463esac
5464  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO Standard C" >&5
5465$as_echo_n "checking for $CC option to accept ISO Standard C... " >&6; }
5466  if ${ac_cv_prog_cc_stdc+:} false; then :
5467  $as_echo_n "(cached) " >&6
5468fi
5469
5470  case $ac_cv_prog_cc_stdc in #(
5471  no) :
5472    { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5473$as_echo "unsupported" >&6; } ;; #(
5474  '') :
5475    { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5476$as_echo "none needed" >&6; } ;; #(
5477  *) :
5478    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_stdc" >&5
5479$as_echo "$ac_cv_prog_cc_stdc" >&6; } ;;
5480esac
5481
5482
5483
5484
5485
5486# Ralf Wildenhues: With per-target flags we need CC_C_O
5487# AM_PROG_CC_C_O supersets AC_PROG_CC_C_O
5488
5489if test $ac_cv_c_compiler_gnu = yes; then
5490    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC needs -traditional" >&5
5491$as_echo_n "checking whether $CC needs -traditional... " >&6; }
5492if ${ac_cv_prog_gcc_traditional+:} false; then :
5493  $as_echo_n "(cached) " >&6
5494else
5495    ac_pattern="Autoconf.*'x'"
5496  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5497/* end confdefs.h.  */
5498#include <sgtty.h>
5499Autoconf TIOCGETP
5500_ACEOF
5501if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5502  $EGREP "$ac_pattern" >/dev/null 2>&1; then :
5503  ac_cv_prog_gcc_traditional=yes
5504else
5505  ac_cv_prog_gcc_traditional=no
5506fi
5507rm -f conftest*
5508
5509
5510  if test $ac_cv_prog_gcc_traditional = no; then
5511    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5512/* end confdefs.h.  */
5513#include <termio.h>
5514Autoconf TCGETA
5515_ACEOF
5516if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5517  $EGREP "$ac_pattern" >/dev/null 2>&1; then :
5518  ac_cv_prog_gcc_traditional=yes
5519fi
5520rm -f conftest*
5521
5522  fi
5523fi
5524{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_gcc_traditional" >&5
5525$as_echo "$ac_cv_prog_gcc_traditional" >&6; }
5526  if test $ac_cv_prog_gcc_traditional = yes; then
5527    CC="$CC -traditional"
5528  fi
5529fi
5530
5531
5532
5533CFLAGS_NTP=
5534CPPFLAGS_NTP=
5535LDADD_NTP=
5536LDFLAGS_NTP=
5537
5538
5539
5540
5541
5542case "$ac_cv_prog_cc_c89" in
5543 no)
5544    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ANSI C89/ISO C90 is the minimum to compile NTP
5545		 version 4.2.5 and higher." >&5
5546$as_echo "$as_me: WARNING: ANSI C89/ISO C90 is the minimum to compile NTP
5547		 version 4.2.5 and higher." >&2;}
5548    ;;
5549esac
5550
5551{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC can handle #warning" >&5
5552$as_echo_n "checking if $CC can handle #warning... " >&6; }
5553if ${ntp_cv_cpp_warning+:} false; then :
5554  $as_echo_n "(cached) " >&6
5555else
5556  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5557/* end confdefs.h.  */
5558
5559int
5560main ()
5561{
5562#warning foo
5563  ;
5564  return 0;
5565}
5566_ACEOF
5567if ac_fn_c_try_compile "$LINENO"; then :
5568  ntp_cv_cpp_warning=yes
5569else
5570  ntp_cv_cpp_warning=no
5571
5572fi
5573rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5574
5575fi
5576{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_cpp_warning" >&5
5577$as_echo "$ntp_cv_cpp_warning" >&6; }
5578case "$ntp_cv_cpp_warning" in
5579 no)
5580
5581$as_echo "#define NO_OPTION_NAME_WARNINGS 1" >>confdefs.h
5582
5583esac
5584
5585{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC supports __attribute__((...))" >&5
5586$as_echo_n "checking if $CC supports __attribute__((...))... " >&6; }
5587if ${ntp_cv_cc_attribute+:} false; then :
5588  $as_echo_n "(cached) " >&6
5589else
5590  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5591/* end confdefs.h.  */
5592
5593int
5594main ()
5595{
5596void foo(void) __attribute__((__noreturn__));
5597
5598  ;
5599  return 0;
5600}
5601_ACEOF
5602if ac_fn_c_try_compile "$LINENO"; then :
5603  ntp_cv_cc_attribute=yes
5604else
5605  ntp_cv_cc_attribute=no
5606
5607fi
5608rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5609
5610fi
5611{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_cc_attribute" >&5
5612$as_echo "$ntp_cv_cc_attribute" >&6; }
5613case "$ntp_cv_cc_attribute" in
5614 yes)
5615
5616$as_echo "#define HAVE___ATTRIBUTE__ /**/" >>confdefs.h
5617
5618esac
5619
5620
5621case "$GCC" in
5622 yes)
5623    SAVED_CFLAGS="$CFLAGS"
5624    CFLAGS="$CFLAGS -Wstrict-overflow"
5625    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC can handle -Wstrict-overflow" >&5
5626$as_echo_n "checking if $CC can handle -Wstrict-overflow... " >&6; }
5627if ${ntp_cv_gcc_Wstrict_overflow+:} false; then :
5628  $as_echo_n "(cached) " >&6
5629else
5630  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5631/* end confdefs.h.  */
5632
5633int
5634main ()
5635{
5636
5637  ;
5638  return 0;
5639}
5640_ACEOF
5641if ac_fn_c_try_compile "$LINENO"; then :
5642  ntp_cv_gcc_Wstrict_overflow=yes
5643else
5644  ntp_cv_gcc_Wstrict_overflow=no
5645
5646fi
5647rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5648
5649fi
5650{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_gcc_Wstrict_overflow" >&5
5651$as_echo "$ntp_cv_gcc_Wstrict_overflow" >&6; }
5652    #
5653    # $ntp_cv_gcc_Wstrict_overflow is tested later to add the
5654    # flag to CFLAGS.
5655    #
5656    CFLAGS="$SAVED_CFLAGS -Winit-self"
5657    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC can handle -Winit-self" >&5
5658$as_echo_n "checking if $CC can handle -Winit-self... " >&6; }
5659if ${ntp_cv_gcc_Winit_self+:} false; then :
5660  $as_echo_n "(cached) " >&6
5661else
5662
5663	    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5664/* end confdefs.h.  */
5665
5666int
5667main ()
5668{
5669
5670  ;
5671  return 0;
5672}
5673_ACEOF
5674if ac_fn_c_try_compile "$LINENO"; then :
5675  ntp_cv_gcc_Winit_self=yes
5676else
5677  ntp_cv_gcc_Winit_self=no
5678
5679fi
5680rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5681
5682
5683fi
5684{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_gcc_Winit_self" >&5
5685$as_echo "$ntp_cv_gcc_Winit_self" >&6; }
5686    CFLAGS="$SAVED_CFLAGS"
5687    { SAVED_CFLAGS=; unset SAVED_CFLAGS;}
5688    #
5689    # $ntp_cv_gcc_Winit_self is tested later to add the
5690    # flag to CFLAGS_NTP.
5691    #
5692    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linker supports omitting unused code and data" >&5
5693$as_echo_n "checking if linker supports omitting unused code and data... " >&6; }
5694if ${ntp_cv_gc_sections_runs+:} false; then :
5695  $as_echo_n "(cached) " >&6
5696else
5697
5698	    	    	    	    	    	    	    	    	    	    	    origCFLAGS="$CFLAGS"
5699	    CFLAGS="$CFLAGS -Wl,--gc-sections"
5700	    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5701/* end confdefs.h.  */
5702
5703			#include <stdlib.h>
5704			#include <stdio.h>
5705
5706int
5707main ()
5708{
5709
5710			FILE *	fpC;
5711			char	buf[32];
5712			size_t	cch;
5713			int	read_success_once;
5714
5715			fpC = fopen("conftest.c", "r");
5716			if (NULL == fpC)
5717				exit(1);
5718			do {
5719				cch = fread(buf, sizeof(buf), 1, fpC);
5720				read_success_once |= (0 != cch);
5721			} while (0 != cch);
5722			if (!read_success_once)
5723				exit(2);
5724			if (!feof(fpC))
5725				exit(3);
5726			if (0 != fclose(fpC))
5727				exit(4);
5728
5729			exit(EXIT_SUCCESS);
5730
5731
5732  ;
5733  return 0;
5734}
5735_ACEOF
5736if ac_fn_c_try_link "$LINENO"; then :
5737
5738		    if test "X$cross_compiling" = "Xyes" || grep gc-sections conftest.err ; then
5739			ntp_cv_gc_sections_runs=no
5740		    else
5741			ntp_cv_gc_sections_runs=no
5742			./conftest >/dev/null 2>&1 && ntp_cv_gc_sections_runs=yes
5743		    fi
5744
5745else
5746  ntp_cv_gc_sections_runs=no
5747
5748fi
5749rm -f core conftest.err conftest.$ac_objext \
5750    conftest$ac_exeext conftest.$ac_ext
5751	    CFLAGS="$origCFLAGS"
5752	    { origCFLAGS=; unset origCFLAGS;}
5753
5754
5755fi
5756{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_gc_sections_runs" >&5
5757$as_echo "$ntp_cv_gc_sections_runs" >&6; }
5758    case "$ntp_cv_gc_sections_runs" in
5759     yes)
5760	LDADD_LIBNTP="-Wl,--gc-sections"
5761	CFLAGS_NTP="$CFLAGS_NTP -ffunction-sections -fdata-sections"
5762	;;
5763     no)
5764	LDADD_LIBNTP=
5765	;;
5766    esac
5767    CFLAGS_NTP="$CFLAGS_NTP -Wall"
5768    CFLAGS_NTP="$CFLAGS_NTP -Wcast-align"
5769    CFLAGS_NTP="$CFLAGS_NTP -Wcast-qual"
5770    # CFLAGS_NTP="$CFLAGS_NTP -Wconversion"
5771    # CFLAGS_NTP="$CFLAGS_NTP -Werror"
5772    # CFLAGS_NTP="$CFLAGS_NTP -Wextra"
5773    # CFLAGS_NTP="$CFLAGS_NTP -Wfloat-equal"
5774    CFLAGS_NTP="$CFLAGS_NTP -Wmissing-prototypes"
5775    CFLAGS_NTP="$CFLAGS_NTP -Wpointer-arith"
5776    CFLAGS_NTP="$CFLAGS_NTP -Wshadow"
5777    # CFLAGS_NTP="$CFLAGS_NTP -Wtraditional"
5778    # CFLAGS_NTP="$CFLAGS_NTP -Wwrite-strings"
5779    case "$ntp_cv_gcc_Winit_self" in
5780     yes)
5781	CFLAGS_NTP="$CFLAGS_NTP -Winit-self"
5782    esac
5783    case "$ntp_cv_gcc_Wstrict_overflow" in
5784     yes)
5785	CFLAGS_NTP="$CFLAGS_NTP -Wstrict-overflow"
5786    esac
5787    # -W[no-]strict-prototypes might be added by NTP_OPENSSL
5788esac
5789
5790
5791    { $as_echo "$as_me:${as_lineno-$LINENO}: checking additional compiler flags" >&5
5792$as_echo_n "checking additional compiler flags... " >&6; }
5793    # allow ntp_os_cflags to be preset to skip this stuff
5794    case "${ntp_os_cflags+set}" in
5795     set)
5796	;;
5797     *)
5798	ntp_os_cflags=
5799	case "$host_os" in
5800	 aix[1-3]*)
5801	    ;;
5802	 aix4.[0-2]*)
5803	    # turn on additional headers
5804	    ntp_os_cflags="-D_XOPEN_EXTENDED_SOURCE"
5805	    ;;
5806	 aix5.3*)
5807	    # avoid circular dependencies in yp headers, and more
5808	    ntp_os_cflags="-DHAVE_BAD_HEADERS -D_XOPEN_EXTENDED_SOURCE"
5809	    ntp_os_cflags="${ntp_os_cflags} -D_USE_IRS -D_MSGQSUPPORT"
5810	    ;;
5811	 aix*)
5812	    # XXX Only verified thru AIX6.
5813	    # aix7 seems to need a different XOPEN_SOURCE_EXTENDED thing.
5814	    # avoid circular dependencies in yp headers
5815	    # _XOPEN_SOURCE=500 = X/Open 5: POSIX 1995
5816	    # _XOPEN_SOURCE=600 = X/Open 6: POSIX 2004
5817	    # _XOPEN_SOURCE=700 = X/Open 7: POSIX 2008
5818	    ntp_os_cflags="-DHAVE_BAD_HEADERS -D_XOPEN_SOURCE=600"
5819	    ntp_os_cflags="${ntp_os_cflags} -D_USE_IRS"
5820	    ;;
5821	 amigaos)
5822	    ntp_os_cflags="-DSYS_AMIGA"
5823	    ;;
5824	 darwin*|macosx*|rhapsody*)
5825	    ntp_os_cflags="-D_P1003_1B_VISIBLE"
5826	    ;;
5827	 hpux10.*)		# at least for hppa2.0-hp-hpux10.20
5828	    case "$GCC" in
5829	     yes)
5830		;;
5831	     *)
5832		# use Ansi compiler on HPUX, and some -Wp magic
5833		ntp_os_cflags="-Ae -Wp,-H18816"
5834		;;
5835	    esac
5836	    ntp_os_cflags="${ntp_os_cflags} -D_HPUX_SOURCE -D__STDC_VERSION__=199901L"
5837	    ;;
5838	 hpux*)
5839	    case "$GCC" in
5840	     yes)
5841		;;
5842	     *)
5843		# use Ansi compiler on HPUX
5844		ntp_os_cflags="-Ae"
5845	    esac
5846	    ntp_os_cflags="${ntp_os_cflags} -D_HPUX_SOURCE -D__STDC_VERSION__=199901L"
5847	    ;;
5848	 irix6*)
5849	    case "$CC" in
5850	     cc)
5851		# do not use 64-bit compiler
5852		ntp_os_cflags="-n32 -mips3 -Wl,-woff,84"
5853	    esac
5854	    ;;
5855	 nextstep3)
5856	    ntp_os_cflags="-posix"
5857	    ;;
5858	 solaris1*|solaris2.[0-5]|solaris2.5.*)
5859	    ;;
5860	 sunos[34]*|sunos5.[0-5]|sunos5.5.*)
5861	    ;;
5862	 solaris2*|sunos5*)
5863	    # turn on 64-bit file offset interface
5864	    ntp_os_cflags="-D_LARGEFILE64_SOURCE"
5865	    ;;
5866	 vxworks*)
5867	    case "$build" in
5868	     $host)
5869		;;
5870	     *)
5871		# Quick and dirty sanity check
5872		case "$VX_KERNEL" in
5873		 '')
5874		    as_fn_error $? "See html/build/hints/vxworks.html" "$LINENO" 5
5875		esac
5876		ntp_os_cflags="-DSYS_VXWORKS"
5877	    esac
5878	    ;;
5879	esac
5880    esac
5881    case "$ntp_os_cflags" in
5882     '')
5883	ntp_os_cflags_msg="none needed"
5884	;;
5885     *)
5886	ntp_os_cflags_msg="$ntp_os_cflags"
5887    esac
5888    CFLAGS_NTP="$CFLAGS_NTP $ntp_os_cflags"
5889    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_os_cflags_msg" >&5
5890$as_echo "$ntp_os_cflags_msg" >&6; }
5891    { ntp_os_cflags_msg=; unset ntp_os_cflags_msg;}
5892    ###
5893    { $as_echo "$as_me:${as_lineno-$LINENO}: checking additional linker flags" >&5
5894$as_echo_n "checking additional linker flags... " >&6; }
5895    # HMS: The following might still need tweaking
5896    # allow ntp_os_ldflags to be preset to skip this stuff
5897    case "${ntp_os_ldflags+set}" in
5898     set)
5899	;;
5900     *)
5901	ntp_os_ldflags=
5902	case "$host_os" in
5903	 hpux*)
5904	    case "$GCC" in
5905	     yes)
5906		ntp_os_ldflags="-Wl,+allowdups"
5907		;;
5908	    esac
5909	    ;;
5910	esac
5911	;;
5912    esac
5913    case "$ntp_os_ldflags" in
5914     '')
5915	ntp_os_ldflags_msg="none needed"
5916	;;
5917     *)
5918	ntp_os_ldflags_msg="$ntp_os_ldflags"
5919    esac
5920    LDFLAGS_NTP="$LDFLAGS_NTP $ntp_os_ldflags"
5921    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_os_ldflags_msg" >&5
5922$as_echo "$ntp_os_ldflags_msg" >&6; }
5923    { ntp_os_ldflags_msg=; unset ntp_os_ldflags_msg;}
5924
5925
5926 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
5927$as_echo_n "checking whether byte ordering is bigendian... " >&6; }
5928if ${ac_cv_c_bigendian+:} false; then :
5929  $as_echo_n "(cached) " >&6
5930else
5931  ac_cv_c_bigendian=unknown
5932    # See if we're dealing with a universal compiler.
5933    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5934/* end confdefs.h.  */
5935#ifndef __APPLE_CC__
5936	       not a universal capable compiler
5937	     #endif
5938	     typedef int dummy;
5939
5940_ACEOF
5941if ac_fn_c_try_compile "$LINENO"; then :
5942
5943	# Check for potential -arch flags.  It is not universal unless
5944	# there are at least two -arch flags with different values.
5945	ac_arch=
5946	ac_prev=
5947	for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
5948	 if test -n "$ac_prev"; then
5949	   case $ac_word in
5950	     i?86 | x86_64 | ppc | ppc64)
5951	       if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
5952		 ac_arch=$ac_word
5953	       else
5954		 ac_cv_c_bigendian=universal
5955		 break
5956	       fi
5957	       ;;
5958	   esac
5959	   ac_prev=
5960	 elif test "x$ac_word" = "x-arch"; then
5961	   ac_prev=arch
5962	 fi
5963       done
5964fi
5965rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5966    if test $ac_cv_c_bigendian = unknown; then
5967      # See if sys/param.h defines the BYTE_ORDER macro.
5968      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5969/* end confdefs.h.  */
5970#include <sys/types.h>
5971	     #include <sys/param.h>
5972
5973int
5974main ()
5975{
5976#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
5977		     && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
5978		     && LITTLE_ENDIAN)
5979	      bogus endian macros
5980	     #endif
5981
5982  ;
5983  return 0;
5984}
5985_ACEOF
5986if ac_fn_c_try_compile "$LINENO"; then :
5987  # It does; now see whether it defined to BIG_ENDIAN or not.
5988	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5989/* end confdefs.h.  */
5990#include <sys/types.h>
5991		#include <sys/param.h>
5992
5993int
5994main ()
5995{
5996#if BYTE_ORDER != BIG_ENDIAN
5997		 not big endian
5998		#endif
5999
6000  ;
6001  return 0;
6002}
6003_ACEOF
6004if ac_fn_c_try_compile "$LINENO"; then :
6005  ac_cv_c_bigendian=yes
6006else
6007  ac_cv_c_bigendian=no
6008fi
6009rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6010fi
6011rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6012    fi
6013    if test $ac_cv_c_bigendian = unknown; then
6014      # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
6015      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6016/* end confdefs.h.  */
6017#include <limits.h>
6018
6019int
6020main ()
6021{
6022#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
6023	      bogus endian macros
6024	     #endif
6025
6026  ;
6027  return 0;
6028}
6029_ACEOF
6030if ac_fn_c_try_compile "$LINENO"; then :
6031  # It does; now see whether it defined to _BIG_ENDIAN or not.
6032	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6033/* end confdefs.h.  */
6034#include <limits.h>
6035
6036int
6037main ()
6038{
6039#ifndef _BIG_ENDIAN
6040		 not big endian
6041		#endif
6042
6043  ;
6044  return 0;
6045}
6046_ACEOF
6047if ac_fn_c_try_compile "$LINENO"; then :
6048  ac_cv_c_bigendian=yes
6049else
6050  ac_cv_c_bigendian=no
6051fi
6052rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6053fi
6054rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6055    fi
6056    if test $ac_cv_c_bigendian = unknown; then
6057      # Compile a test program.
6058      if test "$cross_compiling" = yes; then :
6059  # Try to guess by grepping values from an object file.
6060	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6061/* end confdefs.h.  */
6062short int ascii_mm[] =
6063		  { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
6064		short int ascii_ii[] =
6065		  { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
6066		int use_ascii (int i) {
6067		  return ascii_mm[i] + ascii_ii[i];
6068		}
6069		short int ebcdic_ii[] =
6070		  { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
6071		short int ebcdic_mm[] =
6072		  { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
6073		int use_ebcdic (int i) {
6074		  return ebcdic_mm[i] + ebcdic_ii[i];
6075		}
6076		extern int foo;
6077
6078int
6079main ()
6080{
6081return use_ascii (foo) == use_ebcdic (foo);
6082  ;
6083  return 0;
6084}
6085_ACEOF
6086if ac_fn_c_try_compile "$LINENO"; then :
6087  if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
6088	      ac_cv_c_bigendian=yes
6089	    fi
6090	    if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
6091	      if test "$ac_cv_c_bigendian" = unknown; then
6092		ac_cv_c_bigendian=no
6093	      else
6094		# finding both strings is unlikely to happen, but who knows?
6095		ac_cv_c_bigendian=unknown
6096	      fi
6097	    fi
6098fi
6099rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6100else
6101  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6102/* end confdefs.h.  */
6103$ac_includes_default
6104int
6105main ()
6106{
6107
6108	     /* Are we little or big endian?  From Harbison&Steele.  */
6109	     union
6110	     {
6111	       long int l;
6112	       char c[sizeof (long int)];
6113	     } u;
6114	     u.l = 1;
6115	     return u.c[sizeof (long int) - 1] == 1;
6116
6117  ;
6118  return 0;
6119}
6120_ACEOF
6121if ac_fn_c_try_run "$LINENO"; then :
6122  ac_cv_c_bigendian=no
6123else
6124  ac_cv_c_bigendian=yes
6125fi
6126rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6127  conftest.$ac_objext conftest.beam conftest.$ac_ext
6128fi
6129
6130    fi
6131fi
6132{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
6133$as_echo "$ac_cv_c_bigendian" >&6; }
6134 case $ac_cv_c_bigendian in #(
6135   yes)
6136     $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
6137;; #(
6138   no)
6139      ;; #(
6140   universal)
6141
6142$as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
6143
6144     ;; #(
6145   *)
6146     as_fn_error $? "unknown endianness
6147 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
6148 esac
6149
6150{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working volatile" >&5
6151$as_echo_n "checking for working volatile... " >&6; }
6152if ${ac_cv_c_volatile+:} false; then :
6153  $as_echo_n "(cached) " >&6
6154else
6155  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6156/* end confdefs.h.  */
6157
6158int
6159main ()
6160{
6161
6162volatile int x;
6163int * volatile y = (int *) 0;
6164return !x && !y;
6165  ;
6166  return 0;
6167}
6168_ACEOF
6169if ac_fn_c_try_compile "$LINENO"; then :
6170  ac_cv_c_volatile=yes
6171else
6172  ac_cv_c_volatile=no
6173fi
6174rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6175fi
6176{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_volatile" >&5
6177$as_echo "$ac_cv_c_volatile" >&6; }
6178if test $ac_cv_c_volatile = no; then
6179
6180$as_echo "#define volatile /**/" >>confdefs.h
6181
6182fi
6183
6184ac_ext=c
6185ac_cpp='$CPP $CPPFLAGS'
6186ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6187ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6188ac_compiler_gnu=$ac_cv_c_compiler_gnu
6189{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
6190$as_echo_n "checking how to run the C preprocessor... " >&6; }
6191# On Suns, sometimes $CPP names a directory.
6192if test -n "$CPP" && test -d "$CPP"; then
6193  CPP=
6194fi
6195if test -z "$CPP"; then
6196  if ${ac_cv_prog_CPP+:} false; then :
6197  $as_echo_n "(cached) " >&6
6198else
6199      # Double quotes because CPP needs to be expanded
6200    for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
6201    do
6202      ac_preproc_ok=false
6203for ac_c_preproc_warn_flag in '' yes
6204do
6205  # Use a header file that comes with gcc, so configuring glibc
6206  # with a fresh cross-compiler works.
6207  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6208  # <limits.h> exists even on freestanding compilers.
6209  # On the NeXT, cc -E runs the code through the compiler's parser,
6210  # not just through cpp. "Syntax error" is here to catch this case.
6211  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6212/* end confdefs.h.  */
6213#ifdef __STDC__
6214# include <limits.h>
6215#else
6216# include <assert.h>
6217#endif
6218		     Syntax error
6219_ACEOF
6220if ac_fn_c_try_cpp "$LINENO"; then :
6221
6222else
6223  # Broken: fails on valid input.
6224continue
6225fi
6226rm -f conftest.err conftest.i conftest.$ac_ext
6227
6228  # OK, works on sane cases.  Now check whether nonexistent headers
6229  # can be detected and how.
6230  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6231/* end confdefs.h.  */
6232#include <ac_nonexistent.h>
6233_ACEOF
6234if ac_fn_c_try_cpp "$LINENO"; then :
6235  # Broken: success on invalid input.
6236continue
6237else
6238  # Passes both tests.
6239ac_preproc_ok=:
6240break
6241fi
6242rm -f conftest.err conftest.i conftest.$ac_ext
6243
6244done
6245# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6246rm -f conftest.i conftest.err conftest.$ac_ext
6247if $ac_preproc_ok; then :
6248  break
6249fi
6250
6251    done
6252    ac_cv_prog_CPP=$CPP
6253
6254fi
6255  CPP=$ac_cv_prog_CPP
6256else
6257  ac_cv_prog_CPP=$CPP
6258fi
6259{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
6260$as_echo "$CPP" >&6; }
6261ac_preproc_ok=false
6262for ac_c_preproc_warn_flag in '' yes
6263do
6264  # Use a header file that comes with gcc, so configuring glibc
6265  # with a fresh cross-compiler works.
6266  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6267  # <limits.h> exists even on freestanding compilers.
6268  # On the NeXT, cc -E runs the code through the compiler's parser,
6269  # not just through cpp. "Syntax error" is here to catch this case.
6270  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6271/* end confdefs.h.  */
6272#ifdef __STDC__
6273# include <limits.h>
6274#else
6275# include <assert.h>
6276#endif
6277		     Syntax error
6278_ACEOF
6279if ac_fn_c_try_cpp "$LINENO"; then :
6280
6281else
6282  # Broken: fails on valid input.
6283continue
6284fi
6285rm -f conftest.err conftest.i conftest.$ac_ext
6286
6287  # OK, works on sane cases.  Now check whether nonexistent headers
6288  # can be detected and how.
6289  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6290/* end confdefs.h.  */
6291#include <ac_nonexistent.h>
6292_ACEOF
6293if ac_fn_c_try_cpp "$LINENO"; then :
6294  # Broken: success on invalid input.
6295continue
6296else
6297  # Passes both tests.
6298ac_preproc_ok=:
6299break
6300fi
6301rm -f conftest.err conftest.i conftest.$ac_ext
6302
6303done
6304# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6305rm -f conftest.i conftest.err conftest.$ac_ext
6306if $ac_preproc_ok; then :
6307
6308else
6309  { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
6310$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
6311as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
6312See \`config.log' for more details" "$LINENO" 5; }
6313fi
6314
6315ac_ext=c
6316ac_cpp='$CPP $CPPFLAGS'
6317ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6318ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6319ac_compiler_gnu=$ac_cv_c_compiler_gnu
6320
6321
6322
6323
6324for ac_prog in 'bison -y' byacc
6325do
6326  # Extract the first word of "$ac_prog", so it can be a program name with args.
6327set dummy $ac_prog; ac_word=$2
6328{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6329$as_echo_n "checking for $ac_word... " >&6; }
6330if ${ac_cv_prog_YACC+:} false; then :
6331  $as_echo_n "(cached) " >&6
6332else
6333  if test -n "$YACC"; then
6334  ac_cv_prog_YACC="$YACC" # Let the user override the test.
6335else
6336as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6337for as_dir in $PATH
6338do
6339  IFS=$as_save_IFS
6340  test -z "$as_dir" && as_dir=.
6341    for ac_exec_ext in '' $ac_executable_extensions; do
6342  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6343    ac_cv_prog_YACC="$ac_prog"
6344    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6345    break 2
6346  fi
6347done
6348  done
6349IFS=$as_save_IFS
6350
6351fi
6352fi
6353YACC=$ac_cv_prog_YACC
6354if test -n "$YACC"; then
6355  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $YACC" >&5
6356$as_echo "$YACC" >&6; }
6357else
6358  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6359$as_echo "no" >&6; }
6360fi
6361
6362
6363  test -n "$YACC" && break
6364done
6365test -n "$YACC" || YACC="yacc"
6366
6367   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5
6368$as_echo_n "checking for $CC option to accept ISO C99... " >&6; }
6369if ${ac_cv_prog_cc_c99+:} false; then :
6370  $as_echo_n "(cached) " >&6
6371else
6372  ac_cv_prog_cc_c99=no
6373ac_save_CC=$CC
6374cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6375/* end confdefs.h.  */
6376#include <stdarg.h>
6377#include <stdbool.h>
6378#include <stdlib.h>
6379#include <wchar.h>
6380#include <stdio.h>
6381
6382// Check varargs macros.  These examples are taken from C99 6.10.3.5.
6383#define debug(...) fprintf (stderr, __VA_ARGS__)
6384#define showlist(...) puts (#__VA_ARGS__)
6385#define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
6386static void
6387test_varargs_macros (void)
6388{
6389  int x = 1234;
6390  int y = 5678;
6391  debug ("Flag");
6392  debug ("X = %d\n", x);
6393  showlist (The first, second, and third items.);
6394  report (x>y, "x is %d but y is %d", x, y);
6395}
6396
6397// Check long long types.
6398#define BIG64 18446744073709551615ull
6399#define BIG32 4294967295ul
6400#define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
6401#if !BIG_OK
6402  your preprocessor is broken;
6403#endif
6404#if BIG_OK
6405#else
6406  your preprocessor is broken;
6407#endif
6408static long long int bignum = -9223372036854775807LL;
6409static unsigned long long int ubignum = BIG64;
6410
6411struct incomplete_array
6412{
6413  int datasize;
6414  double data[];
6415};
6416
6417struct named_init {
6418  int number;
6419  const wchar_t *name;
6420  double average;
6421};
6422
6423typedef const char *ccp;
6424
6425static inline int
6426test_restrict (ccp restrict text)
6427{
6428  // See if C++-style comments work.
6429  // Iterate through items via the restricted pointer.
6430  // Also check for declarations in for loops.
6431  for (unsigned int i = 0; *(text+i) != '\0'; ++i)
6432    continue;
6433  return 0;
6434}
6435
6436// Check varargs and va_copy.
6437static void
6438test_varargs (const char *format, ...)
6439{
6440  va_list args;
6441  va_start (args, format);
6442  va_list args_copy;
6443  va_copy (args_copy, args);
6444
6445  const char *str;
6446  int number;
6447  float fnumber;
6448
6449  while (*format)
6450    {
6451      switch (*format++)
6452	{
6453	case 's': // string
6454	  str = va_arg (args_copy, const char *);
6455	  break;
6456	case 'd': // int
6457	  number = va_arg (args_copy, int);
6458	  break;
6459	case 'f': // float
6460	  fnumber = va_arg (args_copy, double);
6461	  break;
6462	default:
6463	  break;
6464	}
6465    }
6466  va_end (args_copy);
6467  va_end (args);
6468}
6469
6470int
6471main ()
6472{
6473
6474  // Check bool.
6475  _Bool success = false;
6476
6477  // Check restrict.
6478  if (test_restrict ("String literal") == 0)
6479    success = true;
6480  char *restrict newvar = "Another string";
6481
6482  // Check varargs.
6483  test_varargs ("s, d' f .", "string", 65, 34.234);
6484  test_varargs_macros ();
6485
6486  // Check flexible array members.
6487  struct incomplete_array *ia =
6488    malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
6489  ia->datasize = 10;
6490  for (int i = 0; i < ia->datasize; ++i)
6491    ia->data[i] = i * 1.234;
6492
6493  // Check named initializers.
6494  struct named_init ni = {
6495    .number = 34,
6496    .name = L"Test wide string",
6497    .average = 543.34343,
6498  };
6499
6500  ni.number = 58;
6501
6502  int dynamic_array[ni.number];
6503  dynamic_array[ni.number - 1] = 543;
6504
6505  // work around unused variable warnings
6506  return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
6507	  || dynamic_array[ni.number - 1] != 543);
6508
6509  ;
6510  return 0;
6511}
6512_ACEOF
6513for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -D_STDC_C99= -qlanglvl=extc99
6514do
6515  CC="$ac_save_CC $ac_arg"
6516  if ac_fn_c_try_compile "$LINENO"; then :
6517  ac_cv_prog_cc_c99=$ac_arg
6518fi
6519rm -f core conftest.err conftest.$ac_objext
6520  test "x$ac_cv_prog_cc_c99" != "xno" && break
6521done
6522rm -f conftest.$ac_ext
6523CC=$ac_save_CC
6524
6525fi
6526# AC_CACHE_VAL
6527case "x$ac_cv_prog_cc_c99" in
6528  x)
6529    { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6530$as_echo "none needed" >&6; } ;;
6531  xno)
6532    { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6533$as_echo "unsupported" >&6; } ;;
6534  *)
6535    CC="$CC $ac_cv_prog_cc_c99"
6536    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
6537$as_echo "$ac_cv_prog_cc_c99" >&6; } ;;
6538esac
6539if test "x$ac_cv_prog_cc_c99" != xno; then :
6540
6541fi
6542
6543
6544
6545	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports C99 structure initialization" >&5
6546$as_echo_n "checking whether the compiler supports C99 structure initialization... " >&6; }
6547
6548
6549	ac_ext=c
6550ac_cpp='$CPP $CPPFLAGS'
6551ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6552ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6553ac_compiler_gnu=$ac_cv_c_compiler_gnu
6554
6555
6556		cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6557/* end confdefs.h.  */
6558
6559			struct foo_s {int i1; int i2;};
6560			int main() { struct foo_s foo[] = { { .i1 = 1, .i2 = 1 }, { .i1 = 2, .i2 = 2 }, { .i1 = 0, .i2 = 0 } }; }
6561
6562_ACEOF
6563if ac_fn_c_try_compile "$LINENO"; then :
6564  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6565$as_echo "yes" >&6; }
6566else
6567  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6568$as_echo "no" >&6; }
6569
6570$as_echo "#define MISSING_C99_STRUCT_INIT 1" >>confdefs.h
6571
6572fi
6573rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6574
6575	ac_ext=c
6576ac_cpp='$CPP $CPPFLAGS'
6577ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6578ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6579ac_compiler_gnu=$ac_cv_c_compiler_gnu
6580
6581
6582
6583
6584
6585{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for compile/link hardening flags" >&5
6586$as_echo_n "checking for compile/link hardening flags... " >&6; }
6587
6588
6589# Check whether --with-hardenfile was given.
6590if test "${with_hardenfile+set}" = set; then :
6591  withval=$with_hardenfile;
6592else
6593  with_hardenfile=no
6594
6595fi
6596
6597
6598(									\
6599    SENTINEL_DIR="$PWD" &&						\
6600    cd $srcdir/sntp &&							\
6601    case "$with_hardenfile" in						\
6602     yes|no|'')								\
6603	scripts/genHardFlags -d "$SENTINEL_DIR"				\
6604	;;								\
6605     *)									\
6606	scripts/genHardFlags -d "$SENTINEL_DIR" -f "$with_hardenfile"	\
6607	;;								\
6608    esac								\
6609) > genHardFlags.i 2> genHardFlags.err
6610. ./genHardFlags.i
6611
6612case "$GENHARDFLAG" in
6613 OK)
6614    { $as_echo "$as_me:${as_lineno-$LINENO}: result: in file $GENHARDFLAGFILE" >&5
6615$as_echo "in file $GENHARDFLAGFILE" >&6; }
6616    rm genHardFlags.err genHardFlags.i
6617    ;;
6618 *)
6619    { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed." >&5
6620$as_echo "failed." >&6; }
6621    as_fn_error $? "Problem with genHardFlags!" "$LINENO" 5
6622    ;;
6623esac
6624
6625
6626
6627
6628
6629
6630
6631
6632{ $as_echo "$as_me:${as_lineno-$LINENO}: checking to see if we need ylwrap VPATH hack" >&5
6633$as_echo_n "checking to see if we need ylwrap VPATH hack... " >&6; }
6634ntp_vpath_hack="no"
6635case "$srcdir::${force_ntp_vpath_hack-no}" in
6636 .::*)
6637    ;; # VPATH_HACK path is for VPATH builds only.
6638 *::yes)
6639    ntp_vpath_hack="yes"
6640    ;;
6641 *::*)
6642    case "`${MAKE-make} -v -f /dev/null 2>/dev/null | grep 'GNU Make'`" in
6643     '')
6644	ntp_vpath_hack="yes"
6645    esac
6646esac
6647{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_vpath_hack" >&5
6648$as_echo "$ntp_vpath_hack" >&6; }
6649 if test x$ntp_vpath_hack = xyes; then
6650  VPATH_HACK_TRUE=
6651  VPATH_HACK_FALSE='#'
6652else
6653  VPATH_HACK_TRUE='#'
6654  VPATH_HACK_FALSE=
6655fi
6656
6657
6658
6659
6660{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for install dir and man conventions" >&5
6661$as_echo_n "checking for install dir and man conventions... " >&6; }
6662
6663
6664# Check whether --with-locfile was given.
6665if test "${with_locfile+set}" = set; then :
6666  withval=$with_locfile;
6667else
6668  with_locfile=no
6669
6670fi
6671
6672
6673(									\
6674    SENTINEL_DIR="$PWD" &&						\
6675    cd $srcdir/sntp &&							\
6676    case "$with_locfile" in						\
6677     yes|no|'')								\
6678	scripts/genLocInfo -d "$SENTINEL_DIR"				\
6679	;;								\
6680     *)									\
6681	scripts/genLocInfo -d "$SENTINEL_DIR" -f "$with_locfile"	\
6682	;;								\
6683    esac								\
6684) > genLocInfo.i 2> genLocInfo.err
6685. ./genLocInfo.i
6686
6687case "$GENLOCINFO" in
6688 OK)
6689    { $as_echo "$as_me:${as_lineno-$LINENO}: result: in file $GENLOCINFOFILE" >&5
6690$as_echo "in file $GENLOCINFOFILE" >&6; }
6691    rm genLocInfo.err genLocInfo.i
6692    ;;
6693 *)
6694    { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed." >&5
6695$as_echo "failed." >&6; }
6696    as_fn_error $? "Problem with genLocInfo!" "$LINENO" 5
6697    ;;
6698esac
6699
6700 if test "$CALC_TICKADJ_MS" ; then
6701  WANT_CALC_TICKADJ_MS_TRUE=
6702  WANT_CALC_TICKADJ_MS_FALSE='#'
6703else
6704  WANT_CALC_TICKADJ_MS_TRUE='#'
6705  WANT_CALC_TICKADJ_MS_FALSE=
6706fi
6707
6708
6709
6710
6711
6712
6713
6714
6715
6716
6717
6718
6719
6720
6721
6722
6723
6724
6725
6726
6727
6728
6729
6730
6731
6732
6733
6734
6735
6736
6737
6738
6739
6740
6741
6742
6743
6744
6745
6746
6747
6748
6749
6750 if test -z "$NTPSWEEP_NI" ; then
6751  INSTALL_NTPSWEEP_TRUE=
6752  INSTALL_NTPSWEEP_FALSE='#'
6753else
6754  INSTALL_NTPSWEEP_TRUE='#'
6755  INSTALL_NTPSWEEP_FALSE=
6756fi
6757
6758
6759
6760
6761
6762
6763
6764
6765
6766
6767
6768
6769
6770
6771
6772
6773
6774
6775
6776
6777
6778
6779
6780
6781
6782
6783
6784
6785
6786
6787
6788
6789
6790
6791
6792
6793
6794
6795
6796
6797
6798 if test -z "$UPDATE_LEAP_NI" ; then
6799  INSTALL_UPDATE_LEAP_TRUE=
6800  INSTALL_UPDATE_LEAP_FALSE='#'
6801else
6802  INSTALL_UPDATE_LEAP_TRUE='#'
6803  INSTALL_UPDATE_LEAP_FALSE=
6804fi
6805
6806
6807
6808if test -n "$ac_tool_prefix"; then
6809  for ac_prog in ar lib "link -lib"
6810  do
6811    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
6812set dummy $ac_tool_prefix$ac_prog; ac_word=$2
6813{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6814$as_echo_n "checking for $ac_word... " >&6; }
6815if ${ac_cv_prog_AR+:} false; then :
6816  $as_echo_n "(cached) " >&6
6817else
6818  if test -n "$AR"; then
6819  ac_cv_prog_AR="$AR" # Let the user override the test.
6820else
6821as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6822for as_dir in $PATH
6823do
6824  IFS=$as_save_IFS
6825  test -z "$as_dir" && as_dir=.
6826    for ac_exec_ext in '' $ac_executable_extensions; do
6827  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6828    ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
6829    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6830    break 2
6831  fi
6832done
6833  done
6834IFS=$as_save_IFS
6835
6836fi
6837fi
6838AR=$ac_cv_prog_AR
6839if test -n "$AR"; then
6840  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
6841$as_echo "$AR" >&6; }
6842else
6843  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6844$as_echo "no" >&6; }
6845fi
6846
6847
6848    test -n "$AR" && break
6849  done
6850fi
6851if test -z "$AR"; then
6852  ac_ct_AR=$AR
6853  for ac_prog in ar lib "link -lib"
6854do
6855  # Extract the first word of "$ac_prog", so it can be a program name with args.
6856set dummy $ac_prog; ac_word=$2
6857{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6858$as_echo_n "checking for $ac_word... " >&6; }
6859if ${ac_cv_prog_ac_ct_AR+:} false; then :
6860  $as_echo_n "(cached) " >&6
6861else
6862  if test -n "$ac_ct_AR"; then
6863  ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
6864else
6865as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6866for as_dir in $PATH
6867do
6868  IFS=$as_save_IFS
6869  test -z "$as_dir" && as_dir=.
6870    for ac_exec_ext in '' $ac_executable_extensions; do
6871  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6872    ac_cv_prog_ac_ct_AR="$ac_prog"
6873    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6874    break 2
6875  fi
6876done
6877  done
6878IFS=$as_save_IFS
6879
6880fi
6881fi
6882ac_ct_AR=$ac_cv_prog_ac_ct_AR
6883if test -n "$ac_ct_AR"; then
6884  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
6885$as_echo "$ac_ct_AR" >&6; }
6886else
6887  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6888$as_echo "no" >&6; }
6889fi
6890
6891
6892  test -n "$ac_ct_AR" && break
6893done
6894
6895  if test "x$ac_ct_AR" = x; then
6896    AR="false"
6897  else
6898    case $cross_compiling:$ac_tool_warned in
6899yes:)
6900{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6901$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6902ac_tool_warned=yes ;;
6903esac
6904    AR=$ac_ct_AR
6905  fi
6906fi
6907
6908: ${AR=ar}
6909
6910{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the archiver ($AR) interface" >&5
6911$as_echo_n "checking the archiver ($AR) interface... " >&6; }
6912if ${am_cv_ar_interface+:} false; then :
6913  $as_echo_n "(cached) " >&6
6914else
6915  ac_ext=c
6916ac_cpp='$CPP $CPPFLAGS'
6917ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6918ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6919ac_compiler_gnu=$ac_cv_c_compiler_gnu
6920
6921   am_cv_ar_interface=ar
6922   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6923/* end confdefs.h.  */
6924int some_variable = 0;
6925_ACEOF
6926if ac_fn_c_try_compile "$LINENO"; then :
6927  am_ar_try='$AR cru libconftest.a conftest.$ac_objext >&5'
6928      { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$am_ar_try\""; } >&5
6929  (eval $am_ar_try) 2>&5
6930  ac_status=$?
6931  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
6932  test $ac_status = 0; }
6933      if test "$ac_status" -eq 0; then
6934        am_cv_ar_interface=ar
6935      else
6936        am_ar_try='$AR -NOLOGO -OUT:conftest.lib conftest.$ac_objext >&5'
6937        { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$am_ar_try\""; } >&5
6938  (eval $am_ar_try) 2>&5
6939  ac_status=$?
6940  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
6941  test $ac_status = 0; }
6942        if test "$ac_status" -eq 0; then
6943          am_cv_ar_interface=lib
6944        else
6945          am_cv_ar_interface=unknown
6946        fi
6947      fi
6948      rm -f conftest.lib libconftest.a
6949
6950fi
6951rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6952   ac_ext=c
6953ac_cpp='$CPP $CPPFLAGS'
6954ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6955ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6956ac_compiler_gnu=$ac_cv_c_compiler_gnu
6957
6958fi
6959{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_ar_interface" >&5
6960$as_echo "$am_cv_ar_interface" >&6; }
6961
6962case $am_cv_ar_interface in
6963ar)
6964  ;;
6965lib)
6966  # Microsoft lib, so override with the ar-lib wrapper script.
6967  # FIXME: It is wrong to rewrite AR.
6968  # But if we don't then we get into trouble of one sort or another.
6969  # A longer-term fix would be to have automake use am__AR in this case,
6970  # and then we could set am__AR="$am_aux_dir/ar-lib \$(AR)" or something
6971  # similar.
6972  AR="$am_aux_dir/ar-lib $AR"
6973  ;;
6974unknown)
6975  as_fn_error $? "could not determine $AR interface" "$LINENO" 5
6976  ;;
6977esac
6978
6979
6980
6981# So far, the only shared library we might use is libopts.
6982# It's a small library - we might as well use a static version of it.
6983# Check whether --enable-shared was given.
6984if test "${enable_shared+set}" = set; then :
6985  enableval=$enable_shared; p=${PACKAGE-default}
6986    case $enableval in
6987    yes) enable_shared=yes ;;
6988    no) enable_shared=no ;;
6989    *)
6990      enable_shared=no
6991      # Look at the argument we got.  We use all the common list separators.
6992      lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
6993      for pkg in $enableval; do
6994	IFS=$lt_save_ifs
6995	if test "X$pkg" = "X$p"; then
6996	  enable_shared=yes
6997	fi
6998      done
6999      IFS=$lt_save_ifs
7000      ;;
7001    esac
7002else
7003  enable_shared=no
7004fi
7005
7006
7007
7008
7009
7010
7011
7012
7013
7014case `pwd` in
7015  *\ * | *\	*)
7016    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5
7017$as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;;
7018esac
7019
7020
7021
7022macro_version='2.4.6'
7023macro_revision='2.4.6'
7024
7025
7026
7027
7028
7029
7030
7031
7032
7033
7034
7035
7036
7037ltmain=$ac_aux_dir/ltmain.sh
7038
7039# Backslashify metacharacters that are still active within
7040# double-quoted strings.
7041sed_quote_subst='s/\(["`$\\]\)/\\\1/g'
7042
7043# Same as above, but do not quote variable references.
7044double_quote_subst='s/\(["`\\]\)/\\\1/g'
7045
7046# Sed substitution to delay expansion of an escaped shell variable in a
7047# double_quote_subst'ed string.
7048delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
7049
7050# Sed substitution to delay expansion of an escaped single quote.
7051delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
7052
7053# Sed substitution to avoid accidental globbing in evaled expressions
7054no_glob_subst='s/\*/\\\*/g'
7055
7056ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
7057ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
7058ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
7059
7060{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
7061$as_echo_n "checking how to print strings... " >&6; }
7062# Test print first, because it will be a builtin if present.
7063if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
7064   test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
7065  ECHO='print -r --'
7066elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
7067  ECHO='printf %s\n'
7068else
7069  # Use this function as a fallback that always works.
7070  func_fallback_echo ()
7071  {
7072    eval 'cat <<_LTECHO_EOF
7073$1
7074_LTECHO_EOF'
7075  }
7076  ECHO='func_fallback_echo'
7077fi
7078
7079# func_echo_all arg...
7080# Invoke $ECHO with all args, space-separated.
7081func_echo_all ()
7082{
7083    $ECHO ""
7084}
7085
7086case $ECHO in
7087  printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5
7088$as_echo "printf" >&6; } ;;
7089  print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5
7090$as_echo "print -r" >&6; } ;;
7091  *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5
7092$as_echo "cat" >&6; } ;;
7093esac
7094
7095
7096
7097
7098
7099
7100
7101
7102
7103
7104
7105
7106
7107
7108{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
7109$as_echo_n "checking for a sed that does not truncate output... " >&6; }
7110if ${ac_cv_path_SED+:} false; then :
7111  $as_echo_n "(cached) " >&6
7112else
7113            ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
7114     for ac_i in 1 2 3 4 5 6 7; do
7115       ac_script="$ac_script$as_nl$ac_script"
7116     done
7117     echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
7118     { ac_script=; unset ac_script;}
7119     if test -z "$SED"; then
7120  ac_path_SED_found=false
7121  # Loop through the user's path and test for each of PROGNAME-LIST
7122  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7123for as_dir in $PATH
7124do
7125  IFS=$as_save_IFS
7126  test -z "$as_dir" && as_dir=.
7127    for ac_prog in sed gsed; do
7128    for ac_exec_ext in '' $ac_executable_extensions; do
7129      ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
7130      as_fn_executable_p "$ac_path_SED" || continue
7131# Check for GNU ac_path_SED and select it if it is found.
7132  # Check for GNU $ac_path_SED
7133case `"$ac_path_SED" --version 2>&1` in
7134*GNU*)
7135  ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
7136*)
7137  ac_count=0
7138  $as_echo_n 0123456789 >"conftest.in"
7139  while :
7140  do
7141    cat "conftest.in" "conftest.in" >"conftest.tmp"
7142    mv "conftest.tmp" "conftest.in"
7143    cp "conftest.in" "conftest.nl"
7144    $as_echo '' >> "conftest.nl"
7145    "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
7146    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
7147    as_fn_arith $ac_count + 1 && ac_count=$as_val
7148    if test $ac_count -gt ${ac_path_SED_max-0}; then
7149      # Best one so far, save it but keep looking for a better one
7150      ac_cv_path_SED="$ac_path_SED"
7151      ac_path_SED_max=$ac_count
7152    fi
7153    # 10*(2^10) chars as input seems more than enough
7154    test $ac_count -gt 10 && break
7155  done
7156  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
7157esac
7158
7159      $ac_path_SED_found && break 3
7160    done
7161  done
7162  done
7163IFS=$as_save_IFS
7164  if test -z "$ac_cv_path_SED"; then
7165    as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
7166  fi
7167else
7168  ac_cv_path_SED=$SED
7169fi
7170
7171fi
7172{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
7173$as_echo "$ac_cv_path_SED" >&6; }
7174 SED="$ac_cv_path_SED"
7175  rm -f conftest.sed
7176
7177test -z "$SED" && SED=sed
7178Xsed="$SED -e 1s/^X//"
7179
7180
7181
7182
7183
7184
7185
7186
7187
7188
7189
7190{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
7191$as_echo_n "checking for fgrep... " >&6; }
7192if ${ac_cv_path_FGREP+:} false; then :
7193  $as_echo_n "(cached) " >&6
7194else
7195  if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
7196   then ac_cv_path_FGREP="$GREP -F"
7197   else
7198     if test -z "$FGREP"; then
7199  ac_path_FGREP_found=false
7200  # Loop through the user's path and test for each of PROGNAME-LIST
7201  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7202for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
7203do
7204  IFS=$as_save_IFS
7205  test -z "$as_dir" && as_dir=.
7206    for ac_prog in fgrep; do
7207    for ac_exec_ext in '' $ac_executable_extensions; do
7208      ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
7209      as_fn_executable_p "$ac_path_FGREP" || continue
7210# Check for GNU ac_path_FGREP and select it if it is found.
7211  # Check for GNU $ac_path_FGREP
7212case `"$ac_path_FGREP" --version 2>&1` in
7213*GNU*)
7214  ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
7215*)
7216  ac_count=0
7217  $as_echo_n 0123456789 >"conftest.in"
7218  while :
7219  do
7220    cat "conftest.in" "conftest.in" >"conftest.tmp"
7221    mv "conftest.tmp" "conftest.in"
7222    cp "conftest.in" "conftest.nl"
7223    $as_echo 'FGREP' >> "conftest.nl"
7224    "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
7225    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
7226    as_fn_arith $ac_count + 1 && ac_count=$as_val
7227    if test $ac_count -gt ${ac_path_FGREP_max-0}; then
7228      # Best one so far, save it but keep looking for a better one
7229      ac_cv_path_FGREP="$ac_path_FGREP"
7230      ac_path_FGREP_max=$ac_count
7231    fi
7232    # 10*(2^10) chars as input seems more than enough
7233    test $ac_count -gt 10 && break
7234  done
7235  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
7236esac
7237
7238      $ac_path_FGREP_found && break 3
7239    done
7240  done
7241  done
7242IFS=$as_save_IFS
7243  if test -z "$ac_cv_path_FGREP"; then
7244    as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
7245  fi
7246else
7247  ac_cv_path_FGREP=$FGREP
7248fi
7249
7250   fi
7251fi
7252{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5
7253$as_echo "$ac_cv_path_FGREP" >&6; }
7254 FGREP="$ac_cv_path_FGREP"
7255
7256
7257test -z "$GREP" && GREP=grep
7258
7259
7260
7261
7262
7263
7264
7265
7266
7267
7268
7269
7270
7271
7272
7273
7274
7275
7276
7277# Check whether --with-gnu-ld was given.
7278if test "${with_gnu_ld+set}" = set; then :
7279  withval=$with_gnu_ld; test no = "$withval" || with_gnu_ld=yes
7280else
7281  with_gnu_ld=no
7282fi
7283
7284ac_prog=ld
7285if test yes = "$GCC"; then
7286  # Check if gcc -print-prog-name=ld gives a path.
7287  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
7288$as_echo_n "checking for ld used by $CC... " >&6; }
7289  case $host in
7290  *-*-mingw*)
7291    # gcc leaves a trailing carriage return, which upsets mingw
7292    ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
7293  *)
7294    ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
7295  esac
7296  case $ac_prog in
7297    # Accept absolute paths.
7298    [\\/]* | ?:[\\/]*)
7299      re_direlt='/[^/][^/]*/\.\./'
7300      # Canonicalize the pathname of ld
7301      ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
7302      while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
7303	ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
7304      done
7305      test -z "$LD" && LD=$ac_prog
7306      ;;
7307  "")
7308    # If it fails, then pretend we aren't using GCC.
7309    ac_prog=ld
7310    ;;
7311  *)
7312    # If it is relative, then search for the first ld in PATH.
7313    with_gnu_ld=unknown
7314    ;;
7315  esac
7316elif test yes = "$with_gnu_ld"; then
7317  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
7318$as_echo_n "checking for GNU ld... " >&6; }
7319else
7320  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
7321$as_echo_n "checking for non-GNU ld... " >&6; }
7322fi
7323if ${lt_cv_path_LD+:} false; then :
7324  $as_echo_n "(cached) " >&6
7325else
7326  if test -z "$LD"; then
7327  lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
7328  for ac_dir in $PATH; do
7329    IFS=$lt_save_ifs
7330    test -z "$ac_dir" && ac_dir=.
7331    if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
7332      lt_cv_path_LD=$ac_dir/$ac_prog
7333      # Check to see if the program is GNU ld.  I'd rather use --version,
7334      # but apparently some variants of GNU ld only accept -v.
7335      # Break only if it was the GNU/non-GNU ld that we prefer.
7336      case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
7337      *GNU* | *'with BFD'*)
7338	test no != "$with_gnu_ld" && break
7339	;;
7340      *)
7341	test yes != "$with_gnu_ld" && break
7342	;;
7343      esac
7344    fi
7345  done
7346  IFS=$lt_save_ifs
7347else
7348  lt_cv_path_LD=$LD # Let the user override the test with a path.
7349fi
7350fi
7351
7352LD=$lt_cv_path_LD
7353if test -n "$LD"; then
7354  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
7355$as_echo "$LD" >&6; }
7356else
7357  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7358$as_echo "no" >&6; }
7359fi
7360test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
7361{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
7362$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
7363if ${lt_cv_prog_gnu_ld+:} false; then :
7364  $as_echo_n "(cached) " >&6
7365else
7366  # I'd rather use --version here, but apparently some GNU lds only accept -v.
7367case `$LD -v 2>&1 </dev/null` in
7368*GNU* | *'with BFD'*)
7369  lt_cv_prog_gnu_ld=yes
7370  ;;
7371*)
7372  lt_cv_prog_gnu_ld=no
7373  ;;
7374esac
7375fi
7376{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5
7377$as_echo "$lt_cv_prog_gnu_ld" >&6; }
7378with_gnu_ld=$lt_cv_prog_gnu_ld
7379
7380
7381
7382
7383
7384
7385
7386
7387
7388{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5
7389$as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; }
7390if ${lt_cv_path_NM+:} false; then :
7391  $as_echo_n "(cached) " >&6
7392else
7393  if test -n "$NM"; then
7394  # Let the user override the test.
7395  lt_cv_path_NM=$NM
7396else
7397  lt_nm_to_check=${ac_tool_prefix}nm
7398  if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
7399    lt_nm_to_check="$lt_nm_to_check nm"
7400  fi
7401  for lt_tmp_nm in $lt_nm_to_check; do
7402    lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
7403    for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
7404      IFS=$lt_save_ifs
7405      test -z "$ac_dir" && ac_dir=.
7406      tmp_nm=$ac_dir/$lt_tmp_nm
7407      if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext"; then
7408	# Check to see if the nm accepts a BSD-compat flag.
7409	# Adding the 'sed 1q' prevents false positives on HP-UX, which says:
7410	#   nm: unknown option "B" ignored
7411	# Tru64's nm complains that /dev/null is an invalid object file
7412	# MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty
7413	case $build_os in
7414	mingw*) lt_bad_file=conftest.nm/nofile ;;
7415	*) lt_bad_file=/dev/null ;;
7416	esac
7417	case `"$tmp_nm" -B $lt_bad_file 2>&1 | sed '1q'` in
7418	*$lt_bad_file* | *'Invalid file or object type'*)
7419	  lt_cv_path_NM="$tmp_nm -B"
7420	  break 2
7421	  ;;
7422	*)
7423	  case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
7424	  */dev/null*)
7425	    lt_cv_path_NM="$tmp_nm -p"
7426	    break 2
7427	    ;;
7428	  *)
7429	    lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
7430	    continue # so that we can try to find one that supports BSD flags
7431	    ;;
7432	  esac
7433	  ;;
7434	esac
7435      fi
7436    done
7437    IFS=$lt_save_ifs
7438  done
7439  : ${lt_cv_path_NM=no}
7440fi
7441fi
7442{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5
7443$as_echo "$lt_cv_path_NM" >&6; }
7444if test no != "$lt_cv_path_NM"; then
7445  NM=$lt_cv_path_NM
7446else
7447  # Didn't find any BSD compatible name lister, look for dumpbin.
7448  if test -n "$DUMPBIN"; then :
7449    # Let the user override the test.
7450  else
7451    if test -n "$ac_tool_prefix"; then
7452  for ac_prog in dumpbin "link -dump"
7453  do
7454    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
7455set dummy $ac_tool_prefix$ac_prog; ac_word=$2
7456{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7457$as_echo_n "checking for $ac_word... " >&6; }
7458if ${ac_cv_prog_DUMPBIN+:} false; then :
7459  $as_echo_n "(cached) " >&6
7460else
7461  if test -n "$DUMPBIN"; then
7462  ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test.
7463else
7464as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7465for as_dir in $PATH
7466do
7467  IFS=$as_save_IFS
7468  test -z "$as_dir" && as_dir=.
7469    for ac_exec_ext in '' $ac_executable_extensions; do
7470  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7471    ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog"
7472    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7473    break 2
7474  fi
7475done
7476  done
7477IFS=$as_save_IFS
7478
7479fi
7480fi
7481DUMPBIN=$ac_cv_prog_DUMPBIN
7482if test -n "$DUMPBIN"; then
7483  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5
7484$as_echo "$DUMPBIN" >&6; }
7485else
7486  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7487$as_echo "no" >&6; }
7488fi
7489
7490
7491    test -n "$DUMPBIN" && break
7492  done
7493fi
7494if test -z "$DUMPBIN"; then
7495  ac_ct_DUMPBIN=$DUMPBIN
7496  for ac_prog in dumpbin "link -dump"
7497do
7498  # Extract the first word of "$ac_prog", so it can be a program name with args.
7499set dummy $ac_prog; ac_word=$2
7500{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7501$as_echo_n "checking for $ac_word... " >&6; }
7502if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then :
7503  $as_echo_n "(cached) " >&6
7504else
7505  if test -n "$ac_ct_DUMPBIN"; then
7506  ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test.
7507else
7508as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7509for as_dir in $PATH
7510do
7511  IFS=$as_save_IFS
7512  test -z "$as_dir" && as_dir=.
7513    for ac_exec_ext in '' $ac_executable_extensions; do
7514  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7515    ac_cv_prog_ac_ct_DUMPBIN="$ac_prog"
7516    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7517    break 2
7518  fi
7519done
7520  done
7521IFS=$as_save_IFS
7522
7523fi
7524fi
7525ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN
7526if test -n "$ac_ct_DUMPBIN"; then
7527  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5
7528$as_echo "$ac_ct_DUMPBIN" >&6; }
7529else
7530  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7531$as_echo "no" >&6; }
7532fi
7533
7534
7535  test -n "$ac_ct_DUMPBIN" && break
7536done
7537
7538  if test "x$ac_ct_DUMPBIN" = x; then
7539    DUMPBIN=":"
7540  else
7541    case $cross_compiling:$ac_tool_warned in
7542yes:)
7543{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7544$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7545ac_tool_warned=yes ;;
7546esac
7547    DUMPBIN=$ac_ct_DUMPBIN
7548  fi
7549fi
7550
7551    case `$DUMPBIN -symbols -headers /dev/null 2>&1 | sed '1q'` in
7552    *COFF*)
7553      DUMPBIN="$DUMPBIN -symbols -headers"
7554      ;;
7555    *)
7556      DUMPBIN=:
7557      ;;
7558    esac
7559  fi
7560
7561  if test : != "$DUMPBIN"; then
7562    NM=$DUMPBIN
7563  fi
7564fi
7565test -z "$NM" && NM=nm
7566
7567
7568
7569
7570
7571
7572{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5
7573$as_echo_n "checking the name lister ($NM) interface... " >&6; }
7574if ${lt_cv_nm_interface+:} false; then :
7575  $as_echo_n "(cached) " >&6
7576else
7577  lt_cv_nm_interface="BSD nm"
7578  echo "int some_variable = 0;" > conftest.$ac_ext
7579  (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5)
7580  (eval "$ac_compile" 2>conftest.err)
7581  cat conftest.err >&5
7582  (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
7583  (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
7584  cat conftest.err >&5
7585  (eval echo "\"\$as_me:$LINENO: output\"" >&5)
7586  cat conftest.out >&5
7587  if $GREP 'External.*some_variable' conftest.out > /dev/null; then
7588    lt_cv_nm_interface="MS dumpbin"
7589  fi
7590  rm -f conftest*
7591fi
7592{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5
7593$as_echo "$lt_cv_nm_interface" >&6; }
7594
7595{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
7596$as_echo_n "checking whether ln -s works... " >&6; }
7597LN_S=$as_ln_s
7598if test "$LN_S" = "ln -s"; then
7599  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7600$as_echo "yes" >&6; }
7601else
7602  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
7603$as_echo "no, using $LN_S" >&6; }
7604fi
7605
7606# find the maximum length of command line arguments
7607{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5
7608$as_echo_n "checking the maximum length of command line arguments... " >&6; }
7609if ${lt_cv_sys_max_cmd_len+:} false; then :
7610  $as_echo_n "(cached) " >&6
7611else
7612    i=0
7613  teststring=ABCD
7614
7615  case $build_os in
7616  msdosdjgpp*)
7617    # On DJGPP, this test can blow up pretty badly due to problems in libc
7618    # (any single argument exceeding 2000 bytes causes a buffer overrun
7619    # during glob expansion).  Even if it were fixed, the result of this
7620    # check would be larger than it should be.
7621    lt_cv_sys_max_cmd_len=12288;    # 12K is about right
7622    ;;
7623
7624  gnu*)
7625    # Under GNU Hurd, this test is not required because there is
7626    # no limit to the length of command line arguments.
7627    # Libtool will interpret -1 as no limit whatsoever
7628    lt_cv_sys_max_cmd_len=-1;
7629    ;;
7630
7631  cygwin* | mingw* | cegcc*)
7632    # On Win9x/ME, this test blows up -- it succeeds, but takes
7633    # about 5 minutes as the teststring grows exponentially.
7634    # Worse, since 9x/ME are not pre-emptively multitasking,
7635    # you end up with a "frozen" computer, even though with patience
7636    # the test eventually succeeds (with a max line length of 256k).
7637    # Instead, let's just punt: use the minimum linelength reported by
7638    # all of the supported platforms: 8192 (on NT/2K/XP).
7639    lt_cv_sys_max_cmd_len=8192;
7640    ;;
7641
7642  mint*)
7643    # On MiNT this can take a long time and run out of memory.
7644    lt_cv_sys_max_cmd_len=8192;
7645    ;;
7646
7647  amigaos*)
7648    # On AmigaOS with pdksh, this test takes hours, literally.
7649    # So we just punt and use a minimum line length of 8192.
7650    lt_cv_sys_max_cmd_len=8192;
7651    ;;
7652
7653  bitrig* | darwin* | dragonfly* | freebsd* | netbsd* | openbsd*)
7654    # This has been around since 386BSD, at least.  Likely further.
7655    if test -x /sbin/sysctl; then
7656      lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
7657    elif test -x /usr/sbin/sysctl; then
7658      lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
7659    else
7660      lt_cv_sys_max_cmd_len=65536	# usable default for all BSDs
7661    fi
7662    # And add a safety zone
7663    lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
7664    lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
7665    ;;
7666
7667  interix*)
7668    # We know the value 262144 and hardcode it with a safety zone (like BSD)
7669    lt_cv_sys_max_cmd_len=196608
7670    ;;
7671
7672  os2*)
7673    # The test takes a long time on OS/2.
7674    lt_cv_sys_max_cmd_len=8192
7675    ;;
7676
7677  osf*)
7678    # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
7679    # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
7680    # nice to cause kernel panics so lets avoid the loop below.
7681    # First set a reasonable default.
7682    lt_cv_sys_max_cmd_len=16384
7683    #
7684    if test -x /sbin/sysconfig; then
7685      case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
7686        *1*) lt_cv_sys_max_cmd_len=-1 ;;
7687      esac
7688    fi
7689    ;;
7690  sco3.2v5*)
7691    lt_cv_sys_max_cmd_len=102400
7692    ;;
7693  sysv5* | sco5v6* | sysv4.2uw2*)
7694    kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
7695    if test -n "$kargmax"; then
7696      lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[	 ]//'`
7697    else
7698      lt_cv_sys_max_cmd_len=32768
7699    fi
7700    ;;
7701  *)
7702    lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
7703    if test -n "$lt_cv_sys_max_cmd_len" && \
7704       test undefined != "$lt_cv_sys_max_cmd_len"; then
7705      lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
7706      lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
7707    else
7708      # Make teststring a little bigger before we do anything with it.
7709      # a 1K string should be a reasonable start.
7710      for i in 1 2 3 4 5 6 7 8; do
7711        teststring=$teststring$teststring
7712      done
7713      SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
7714      # If test is not a shell built-in, we'll probably end up computing a
7715      # maximum length that is only half of the actual maximum length, but
7716      # we can't tell.
7717      while { test X`env echo "$teststring$teststring" 2>/dev/null` \
7718	         = "X$teststring$teststring"; } >/dev/null 2>&1 &&
7719	      test 17 != "$i" # 1/2 MB should be enough
7720      do
7721        i=`expr $i + 1`
7722        teststring=$teststring$teststring
7723      done
7724      # Only check the string length outside the loop.
7725      lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
7726      teststring=
7727      # Add a significant safety factor because C++ compilers can tack on
7728      # massive amounts of additional arguments before passing them to the
7729      # linker.  It appears as though 1/2 is a usable value.
7730      lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
7731    fi
7732    ;;
7733  esac
7734
7735fi
7736
7737if test -n "$lt_cv_sys_max_cmd_len"; then
7738  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5
7739$as_echo "$lt_cv_sys_max_cmd_len" >&6; }
7740else
7741  { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5
7742$as_echo "none" >&6; }
7743fi
7744max_cmd_len=$lt_cv_sys_max_cmd_len
7745
7746
7747
7748
7749
7750
7751: ${CP="cp -f"}
7752: ${MV="mv -f"}
7753: ${RM="rm -f"}
7754
7755if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
7756  lt_unset=unset
7757else
7758  lt_unset=false
7759fi
7760
7761
7762
7763
7764
7765# test EBCDIC or ASCII
7766case `echo X|tr X '\101'` in
7767 A) # ASCII based system
7768    # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
7769  lt_SP2NL='tr \040 \012'
7770  lt_NL2SP='tr \015\012 \040\040'
7771  ;;
7772 *) # EBCDIC based system
7773  lt_SP2NL='tr \100 \n'
7774  lt_NL2SP='tr \r\n \100\100'
7775  ;;
7776esac
7777
7778
7779
7780
7781
7782
7783
7784
7785
7786{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5
7787$as_echo_n "checking how to convert $build file names to $host format... " >&6; }
7788if ${lt_cv_to_host_file_cmd+:} false; then :
7789  $as_echo_n "(cached) " >&6
7790else
7791  case $host in
7792  *-*-mingw* )
7793    case $build in
7794      *-*-mingw* ) # actually msys
7795        lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
7796        ;;
7797      *-*-cygwin* )
7798        lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
7799        ;;
7800      * ) # otherwise, assume *nix
7801        lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
7802        ;;
7803    esac
7804    ;;
7805  *-*-cygwin* )
7806    case $build in
7807      *-*-mingw* ) # actually msys
7808        lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
7809        ;;
7810      *-*-cygwin* )
7811        lt_cv_to_host_file_cmd=func_convert_file_noop
7812        ;;
7813      * ) # otherwise, assume *nix
7814        lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
7815        ;;
7816    esac
7817    ;;
7818  * ) # unhandled hosts (and "normal" native builds)
7819    lt_cv_to_host_file_cmd=func_convert_file_noop
7820    ;;
7821esac
7822
7823fi
7824
7825to_host_file_cmd=$lt_cv_to_host_file_cmd
7826{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5
7827$as_echo "$lt_cv_to_host_file_cmd" >&6; }
7828
7829
7830
7831
7832
7833{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5
7834$as_echo_n "checking how to convert $build file names to toolchain format... " >&6; }
7835if ${lt_cv_to_tool_file_cmd+:} false; then :
7836  $as_echo_n "(cached) " >&6
7837else
7838  #assume ordinary cross tools, or native build.
7839lt_cv_to_tool_file_cmd=func_convert_file_noop
7840case $host in
7841  *-*-mingw* )
7842    case $build in
7843      *-*-mingw* ) # actually msys
7844        lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
7845        ;;
7846    esac
7847    ;;
7848esac
7849
7850fi
7851
7852to_tool_file_cmd=$lt_cv_to_tool_file_cmd
7853{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5
7854$as_echo "$lt_cv_to_tool_file_cmd" >&6; }
7855
7856
7857
7858
7859
7860{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
7861$as_echo_n "checking for $LD option to reload object files... " >&6; }
7862if ${lt_cv_ld_reload_flag+:} false; then :
7863  $as_echo_n "(cached) " >&6
7864else
7865  lt_cv_ld_reload_flag='-r'
7866fi
7867{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5
7868$as_echo "$lt_cv_ld_reload_flag" >&6; }
7869reload_flag=$lt_cv_ld_reload_flag
7870case $reload_flag in
7871"" | " "*) ;;
7872*) reload_flag=" $reload_flag" ;;
7873esac
7874reload_cmds='$LD$reload_flag -o $output$reload_objs'
7875case $host_os in
7876  cygwin* | mingw* | pw32* | cegcc*)
7877    if test yes != "$GCC"; then
7878      reload_cmds=false
7879    fi
7880    ;;
7881  darwin*)
7882    if test yes = "$GCC"; then
7883      reload_cmds='$LTCC $LTCFLAGS -nostdlib $wl-r -o $output$reload_objs'
7884    else
7885      reload_cmds='$LD$reload_flag -o $output$reload_objs'
7886    fi
7887    ;;
7888esac
7889
7890
7891
7892
7893
7894
7895
7896
7897
7898if test -n "$ac_tool_prefix"; then
7899  # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
7900set dummy ${ac_tool_prefix}objdump; ac_word=$2
7901{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7902$as_echo_n "checking for $ac_word... " >&6; }
7903if ${ac_cv_prog_OBJDUMP+:} false; then :
7904  $as_echo_n "(cached) " >&6
7905else
7906  if test -n "$OBJDUMP"; then
7907  ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
7908else
7909as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7910for as_dir in $PATH
7911do
7912  IFS=$as_save_IFS
7913  test -z "$as_dir" && as_dir=.
7914    for ac_exec_ext in '' $ac_executable_extensions; do
7915  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7916    ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
7917    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7918    break 2
7919  fi
7920done
7921  done
7922IFS=$as_save_IFS
7923
7924fi
7925fi
7926OBJDUMP=$ac_cv_prog_OBJDUMP
7927if test -n "$OBJDUMP"; then
7928  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
7929$as_echo "$OBJDUMP" >&6; }
7930else
7931  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7932$as_echo "no" >&6; }
7933fi
7934
7935
7936fi
7937if test -z "$ac_cv_prog_OBJDUMP"; then
7938  ac_ct_OBJDUMP=$OBJDUMP
7939  # Extract the first word of "objdump", so it can be a program name with args.
7940set dummy objdump; ac_word=$2
7941{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7942$as_echo_n "checking for $ac_word... " >&6; }
7943if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
7944  $as_echo_n "(cached) " >&6
7945else
7946  if test -n "$ac_ct_OBJDUMP"; then
7947  ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
7948else
7949as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7950for as_dir in $PATH
7951do
7952  IFS=$as_save_IFS
7953  test -z "$as_dir" && as_dir=.
7954    for ac_exec_ext in '' $ac_executable_extensions; do
7955  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7956    ac_cv_prog_ac_ct_OBJDUMP="objdump"
7957    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7958    break 2
7959  fi
7960done
7961  done
7962IFS=$as_save_IFS
7963
7964fi
7965fi
7966ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
7967if test -n "$ac_ct_OBJDUMP"; then
7968  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
7969$as_echo "$ac_ct_OBJDUMP" >&6; }
7970else
7971  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7972$as_echo "no" >&6; }
7973fi
7974
7975  if test "x$ac_ct_OBJDUMP" = x; then
7976    OBJDUMP="false"
7977  else
7978    case $cross_compiling:$ac_tool_warned in
7979yes:)
7980{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7981$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7982ac_tool_warned=yes ;;
7983esac
7984    OBJDUMP=$ac_ct_OBJDUMP
7985  fi
7986else
7987  OBJDUMP="$ac_cv_prog_OBJDUMP"
7988fi
7989
7990test -z "$OBJDUMP" && OBJDUMP=objdump
7991
7992
7993
7994
7995
7996
7997
7998
7999
8000{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5
8001$as_echo_n "checking how to recognize dependent libraries... " >&6; }
8002if ${lt_cv_deplibs_check_method+:} false; then :
8003  $as_echo_n "(cached) " >&6
8004else
8005  lt_cv_file_magic_cmd='$MAGIC_CMD'
8006lt_cv_file_magic_test_file=
8007lt_cv_deplibs_check_method='unknown'
8008# Need to set the preceding variable on all platforms that support
8009# interlibrary dependencies.
8010# 'none' -- dependencies not supported.
8011# 'unknown' -- same as none, but documents that we really don't know.
8012# 'pass_all' -- all dependencies passed with no checks.
8013# 'test_compile' -- check by making test program.
8014# 'file_magic [[regex]]' -- check by looking for files in library path
8015# that responds to the $file_magic_cmd with a given extended regex.
8016# If you have 'file' or equivalent on your system and you're not sure
8017# whether 'pass_all' will *always* work, you probably want this one.
8018
8019case $host_os in
8020aix[4-9]*)
8021  lt_cv_deplibs_check_method=pass_all
8022  ;;
8023
8024beos*)
8025  lt_cv_deplibs_check_method=pass_all
8026  ;;
8027
8028bsdi[45]*)
8029  lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
8030  lt_cv_file_magic_cmd='/usr/bin/file -L'
8031  lt_cv_file_magic_test_file=/shlib/libc.so
8032  ;;
8033
8034cygwin*)
8035  # func_win32_libid is a shell function defined in ltmain.sh
8036  lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
8037  lt_cv_file_magic_cmd='func_win32_libid'
8038  ;;
8039
8040mingw* | pw32*)
8041  # Base MSYS/MinGW do not provide the 'file' command needed by
8042  # func_win32_libid shell function, so use a weaker test based on 'objdump',
8043  # unless we find 'file', for example because we are cross-compiling.
8044  if ( file / ) >/dev/null 2>&1; then
8045    lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
8046    lt_cv_file_magic_cmd='func_win32_libid'
8047  else
8048    # Keep this pattern in sync with the one in func_win32_libid.
8049    lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
8050    lt_cv_file_magic_cmd='$OBJDUMP -f'
8051  fi
8052  ;;
8053
8054cegcc*)
8055  # use the weaker test based on 'objdump'. See mingw*.
8056  lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
8057  lt_cv_file_magic_cmd='$OBJDUMP -f'
8058  ;;
8059
8060darwin* | rhapsody*)
8061  lt_cv_deplibs_check_method=pass_all
8062  ;;
8063
8064freebsd* | dragonfly*)
8065  if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
8066    case $host_cpu in
8067    i*86 )
8068      # Not sure whether the presence of OpenBSD here was a mistake.
8069      # Let's accept both of them until this is cleared up.
8070      lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library'
8071      lt_cv_file_magic_cmd=/usr/bin/file
8072      lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
8073      ;;
8074    esac
8075  else
8076    lt_cv_deplibs_check_method=pass_all
8077  fi
8078  ;;
8079
8080haiku*)
8081  lt_cv_deplibs_check_method=pass_all
8082  ;;
8083
8084hpux10.20* | hpux11*)
8085  lt_cv_file_magic_cmd=/usr/bin/file
8086  case $host_cpu in
8087  ia64*)
8088    lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64'
8089    lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
8090    ;;
8091  hppa*64*)
8092    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]'
8093    lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
8094    ;;
8095  *)
8096    lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library'
8097    lt_cv_file_magic_test_file=/usr/lib/libc.sl
8098    ;;
8099  esac
8100  ;;
8101
8102interix[3-9]*)
8103  # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
8104  lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$'
8105  ;;
8106
8107irix5* | irix6* | nonstopux*)
8108  case $LD in
8109  *-32|*"-32 ") libmagic=32-bit;;
8110  *-n32|*"-n32 ") libmagic=N32;;
8111  *-64|*"-64 ") libmagic=64-bit;;
8112  *) libmagic=never-match;;
8113  esac
8114  lt_cv_deplibs_check_method=pass_all
8115  ;;
8116
8117# This must be glibc/ELF.
8118linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
8119  lt_cv_deplibs_check_method=pass_all
8120  ;;
8121
8122netbsd*)
8123  if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
8124    lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
8125  else
8126    lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$'
8127  fi
8128  ;;
8129
8130newos6*)
8131  lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
8132  lt_cv_file_magic_cmd=/usr/bin/file
8133  lt_cv_file_magic_test_file=/usr/lib/libnls.so
8134  ;;
8135
8136*nto* | *qnx*)
8137  lt_cv_deplibs_check_method=pass_all
8138  ;;
8139
8140openbsd* | bitrig*)
8141  if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
8142    lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$'
8143  else
8144    lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
8145  fi
8146  ;;
8147
8148osf3* | osf4* | osf5*)
8149  lt_cv_deplibs_check_method=pass_all
8150  ;;
8151
8152rdos*)
8153  lt_cv_deplibs_check_method=pass_all
8154  ;;
8155
8156solaris*)
8157  lt_cv_deplibs_check_method=pass_all
8158  ;;
8159
8160sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
8161  lt_cv_deplibs_check_method=pass_all
8162  ;;
8163
8164sysv4 | sysv4.3*)
8165  case $host_vendor in
8166  motorola)
8167    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]'
8168    lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
8169    ;;
8170  ncr)
8171    lt_cv_deplibs_check_method=pass_all
8172    ;;
8173  sequent)
8174    lt_cv_file_magic_cmd='/bin/file'
8175    lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
8176    ;;
8177  sni)
8178    lt_cv_file_magic_cmd='/bin/file'
8179    lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"
8180    lt_cv_file_magic_test_file=/lib/libc.so
8181    ;;
8182  siemens)
8183    lt_cv_deplibs_check_method=pass_all
8184    ;;
8185  pc)
8186    lt_cv_deplibs_check_method=pass_all
8187    ;;
8188  esac
8189  ;;
8190
8191tpf*)
8192  lt_cv_deplibs_check_method=pass_all
8193  ;;
8194os2*)
8195  lt_cv_deplibs_check_method=pass_all
8196  ;;
8197esac
8198
8199fi
8200{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
8201$as_echo "$lt_cv_deplibs_check_method" >&6; }
8202
8203file_magic_glob=
8204want_nocaseglob=no
8205if test "$build" = "$host"; then
8206  case $host_os in
8207  mingw* | pw32*)
8208    if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
8209      want_nocaseglob=yes
8210    else
8211      file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"`
8212    fi
8213    ;;
8214  esac
8215fi
8216
8217file_magic_cmd=$lt_cv_file_magic_cmd
8218deplibs_check_method=$lt_cv_deplibs_check_method
8219test -z "$deplibs_check_method" && deplibs_check_method=unknown
8220
8221
8222
8223
8224
8225
8226
8227
8228
8229
8230
8231
8232
8233
8234
8235
8236
8237
8238
8239
8240
8241
8242if test -n "$ac_tool_prefix"; then
8243  # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
8244set dummy ${ac_tool_prefix}dlltool; ac_word=$2
8245{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8246$as_echo_n "checking for $ac_word... " >&6; }
8247if ${ac_cv_prog_DLLTOOL+:} false; then :
8248  $as_echo_n "(cached) " >&6
8249else
8250  if test -n "$DLLTOOL"; then
8251  ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
8252else
8253as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8254for as_dir in $PATH
8255do
8256  IFS=$as_save_IFS
8257  test -z "$as_dir" && as_dir=.
8258    for ac_exec_ext in '' $ac_executable_extensions; do
8259  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8260    ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
8261    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8262    break 2
8263  fi
8264done
8265  done
8266IFS=$as_save_IFS
8267
8268fi
8269fi
8270DLLTOOL=$ac_cv_prog_DLLTOOL
8271if test -n "$DLLTOOL"; then
8272  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
8273$as_echo "$DLLTOOL" >&6; }
8274else
8275  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8276$as_echo "no" >&6; }
8277fi
8278
8279
8280fi
8281if test -z "$ac_cv_prog_DLLTOOL"; then
8282  ac_ct_DLLTOOL=$DLLTOOL
8283  # Extract the first word of "dlltool", so it can be a program name with args.
8284set dummy dlltool; ac_word=$2
8285{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8286$as_echo_n "checking for $ac_word... " >&6; }
8287if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then :
8288  $as_echo_n "(cached) " >&6
8289else
8290  if test -n "$ac_ct_DLLTOOL"; then
8291  ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
8292else
8293as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8294for as_dir in $PATH
8295do
8296  IFS=$as_save_IFS
8297  test -z "$as_dir" && as_dir=.
8298    for ac_exec_ext in '' $ac_executable_extensions; do
8299  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8300    ac_cv_prog_ac_ct_DLLTOOL="dlltool"
8301    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8302    break 2
8303  fi
8304done
8305  done
8306IFS=$as_save_IFS
8307
8308fi
8309fi
8310ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
8311if test -n "$ac_ct_DLLTOOL"; then
8312  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
8313$as_echo "$ac_ct_DLLTOOL" >&6; }
8314else
8315  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8316$as_echo "no" >&6; }
8317fi
8318
8319  if test "x$ac_ct_DLLTOOL" = x; then
8320    DLLTOOL="false"
8321  else
8322    case $cross_compiling:$ac_tool_warned in
8323yes:)
8324{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8325$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8326ac_tool_warned=yes ;;
8327esac
8328    DLLTOOL=$ac_ct_DLLTOOL
8329  fi
8330else
8331  DLLTOOL="$ac_cv_prog_DLLTOOL"
8332fi
8333
8334test -z "$DLLTOOL" && DLLTOOL=dlltool
8335
8336
8337
8338
8339
8340
8341
8342
8343
8344
8345{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5
8346$as_echo_n "checking how to associate runtime and link libraries... " >&6; }
8347if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then :
8348  $as_echo_n "(cached) " >&6
8349else
8350  lt_cv_sharedlib_from_linklib_cmd='unknown'
8351
8352case $host_os in
8353cygwin* | mingw* | pw32* | cegcc*)
8354  # two different shell functions defined in ltmain.sh;
8355  # decide which one to use based on capabilities of $DLLTOOL
8356  case `$DLLTOOL --help 2>&1` in
8357  *--identify-strict*)
8358    lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
8359    ;;
8360  *)
8361    lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
8362    ;;
8363  esac
8364  ;;
8365*)
8366  # fallback: assume linklib IS sharedlib
8367  lt_cv_sharedlib_from_linklib_cmd=$ECHO
8368  ;;
8369esac
8370
8371fi
8372{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5
8373$as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; }
8374sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
8375test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
8376
8377
8378
8379
8380
8381
8382
8383if test -n "$ac_tool_prefix"; then
8384  for ac_prog in ar
8385  do
8386    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
8387set dummy $ac_tool_prefix$ac_prog; ac_word=$2
8388{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8389$as_echo_n "checking for $ac_word... " >&6; }
8390if ${ac_cv_prog_AR+:} false; then :
8391  $as_echo_n "(cached) " >&6
8392else
8393  if test -n "$AR"; then
8394  ac_cv_prog_AR="$AR" # Let the user override the test.
8395else
8396as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8397for as_dir in $PATH
8398do
8399  IFS=$as_save_IFS
8400  test -z "$as_dir" && as_dir=.
8401    for ac_exec_ext in '' $ac_executable_extensions; do
8402  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8403    ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
8404    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8405    break 2
8406  fi
8407done
8408  done
8409IFS=$as_save_IFS
8410
8411fi
8412fi
8413AR=$ac_cv_prog_AR
8414if test -n "$AR"; then
8415  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
8416$as_echo "$AR" >&6; }
8417else
8418  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8419$as_echo "no" >&6; }
8420fi
8421
8422
8423    test -n "$AR" && break
8424  done
8425fi
8426if test -z "$AR"; then
8427  ac_ct_AR=$AR
8428  for ac_prog in ar
8429do
8430  # Extract the first word of "$ac_prog", so it can be a program name with args.
8431set dummy $ac_prog; ac_word=$2
8432{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8433$as_echo_n "checking for $ac_word... " >&6; }
8434if ${ac_cv_prog_ac_ct_AR+:} false; then :
8435  $as_echo_n "(cached) " >&6
8436else
8437  if test -n "$ac_ct_AR"; then
8438  ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
8439else
8440as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8441for as_dir in $PATH
8442do
8443  IFS=$as_save_IFS
8444  test -z "$as_dir" && as_dir=.
8445    for ac_exec_ext in '' $ac_executable_extensions; do
8446  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8447    ac_cv_prog_ac_ct_AR="$ac_prog"
8448    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8449    break 2
8450  fi
8451done
8452  done
8453IFS=$as_save_IFS
8454
8455fi
8456fi
8457ac_ct_AR=$ac_cv_prog_ac_ct_AR
8458if test -n "$ac_ct_AR"; then
8459  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
8460$as_echo "$ac_ct_AR" >&6; }
8461else
8462  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8463$as_echo "no" >&6; }
8464fi
8465
8466
8467  test -n "$ac_ct_AR" && break
8468done
8469
8470  if test "x$ac_ct_AR" = x; then
8471    AR="false"
8472  else
8473    case $cross_compiling:$ac_tool_warned in
8474yes:)
8475{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8476$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8477ac_tool_warned=yes ;;
8478esac
8479    AR=$ac_ct_AR
8480  fi
8481fi
8482
8483: ${AR=ar}
8484: ${AR_FLAGS=cru}
8485
8486
8487
8488
8489
8490
8491
8492
8493
8494
8495
8496{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5
8497$as_echo_n "checking for archiver @FILE support... " >&6; }
8498if ${lt_cv_ar_at_file+:} false; then :
8499  $as_echo_n "(cached) " >&6
8500else
8501  lt_cv_ar_at_file=no
8502   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8503/* end confdefs.h.  */
8504
8505int
8506main ()
8507{
8508
8509  ;
8510  return 0;
8511}
8512_ACEOF
8513if ac_fn_c_try_compile "$LINENO"; then :
8514  echo conftest.$ac_objext > conftest.lst
8515      lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5'
8516      { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
8517  (eval $lt_ar_try) 2>&5
8518  ac_status=$?
8519  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8520  test $ac_status = 0; }
8521      if test 0 -eq "$ac_status"; then
8522	# Ensure the archiver fails upon bogus file names.
8523	rm -f conftest.$ac_objext libconftest.a
8524	{ { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
8525  (eval $lt_ar_try) 2>&5
8526  ac_status=$?
8527  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8528  test $ac_status = 0; }
8529	if test 0 -ne "$ac_status"; then
8530          lt_cv_ar_at_file=@
8531        fi
8532      fi
8533      rm -f conftest.* libconftest.a
8534
8535fi
8536rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8537
8538fi
8539{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5
8540$as_echo "$lt_cv_ar_at_file" >&6; }
8541
8542if test no = "$lt_cv_ar_at_file"; then
8543  archiver_list_spec=
8544else
8545  archiver_list_spec=$lt_cv_ar_at_file
8546fi
8547
8548
8549
8550
8551
8552
8553
8554if test -n "$ac_tool_prefix"; then
8555  # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
8556set dummy ${ac_tool_prefix}strip; ac_word=$2
8557{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8558$as_echo_n "checking for $ac_word... " >&6; }
8559if ${ac_cv_prog_STRIP+:} false; then :
8560  $as_echo_n "(cached) " >&6
8561else
8562  if test -n "$STRIP"; then
8563  ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
8564else
8565as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8566for as_dir in $PATH
8567do
8568  IFS=$as_save_IFS
8569  test -z "$as_dir" && as_dir=.
8570    for ac_exec_ext in '' $ac_executable_extensions; do
8571  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8572    ac_cv_prog_STRIP="${ac_tool_prefix}strip"
8573    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8574    break 2
8575  fi
8576done
8577  done
8578IFS=$as_save_IFS
8579
8580fi
8581fi
8582STRIP=$ac_cv_prog_STRIP
8583if test -n "$STRIP"; then
8584  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
8585$as_echo "$STRIP" >&6; }
8586else
8587  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8588$as_echo "no" >&6; }
8589fi
8590
8591
8592fi
8593if test -z "$ac_cv_prog_STRIP"; then
8594  ac_ct_STRIP=$STRIP
8595  # Extract the first word of "strip", so it can be a program name with args.
8596set dummy strip; ac_word=$2
8597{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8598$as_echo_n "checking for $ac_word... " >&6; }
8599if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
8600  $as_echo_n "(cached) " >&6
8601else
8602  if test -n "$ac_ct_STRIP"; then
8603  ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
8604else
8605as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8606for as_dir in $PATH
8607do
8608  IFS=$as_save_IFS
8609  test -z "$as_dir" && as_dir=.
8610    for ac_exec_ext in '' $ac_executable_extensions; do
8611  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8612    ac_cv_prog_ac_ct_STRIP="strip"
8613    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8614    break 2
8615  fi
8616done
8617  done
8618IFS=$as_save_IFS
8619
8620fi
8621fi
8622ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
8623if test -n "$ac_ct_STRIP"; then
8624  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
8625$as_echo "$ac_ct_STRIP" >&6; }
8626else
8627  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8628$as_echo "no" >&6; }
8629fi
8630
8631  if test "x$ac_ct_STRIP" = x; then
8632    STRIP=":"
8633  else
8634    case $cross_compiling:$ac_tool_warned in
8635yes:)
8636{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8637$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8638ac_tool_warned=yes ;;
8639esac
8640    STRIP=$ac_ct_STRIP
8641  fi
8642else
8643  STRIP="$ac_cv_prog_STRIP"
8644fi
8645
8646test -z "$STRIP" && STRIP=:
8647
8648
8649
8650
8651
8652
8653if test -n "$ac_tool_prefix"; then
8654  # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
8655set dummy ${ac_tool_prefix}ranlib; ac_word=$2
8656{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8657$as_echo_n "checking for $ac_word... " >&6; }
8658if ${ac_cv_prog_RANLIB+:} false; then :
8659  $as_echo_n "(cached) " >&6
8660else
8661  if test -n "$RANLIB"; then
8662  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
8663else
8664as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8665for as_dir in $PATH
8666do
8667  IFS=$as_save_IFS
8668  test -z "$as_dir" && as_dir=.
8669    for ac_exec_ext in '' $ac_executable_extensions; do
8670  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8671    ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
8672    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8673    break 2
8674  fi
8675done
8676  done
8677IFS=$as_save_IFS
8678
8679fi
8680fi
8681RANLIB=$ac_cv_prog_RANLIB
8682if test -n "$RANLIB"; then
8683  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
8684$as_echo "$RANLIB" >&6; }
8685else
8686  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8687$as_echo "no" >&6; }
8688fi
8689
8690
8691fi
8692if test -z "$ac_cv_prog_RANLIB"; then
8693  ac_ct_RANLIB=$RANLIB
8694  # Extract the first word of "ranlib", so it can be a program name with args.
8695set dummy ranlib; ac_word=$2
8696{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8697$as_echo_n "checking for $ac_word... " >&6; }
8698if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
8699  $as_echo_n "(cached) " >&6
8700else
8701  if test -n "$ac_ct_RANLIB"; then
8702  ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
8703else
8704as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8705for as_dir in $PATH
8706do
8707  IFS=$as_save_IFS
8708  test -z "$as_dir" && as_dir=.
8709    for ac_exec_ext in '' $ac_executable_extensions; do
8710  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8711    ac_cv_prog_ac_ct_RANLIB="ranlib"
8712    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8713    break 2
8714  fi
8715done
8716  done
8717IFS=$as_save_IFS
8718
8719fi
8720fi
8721ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
8722if test -n "$ac_ct_RANLIB"; then
8723  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
8724$as_echo "$ac_ct_RANLIB" >&6; }
8725else
8726  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8727$as_echo "no" >&6; }
8728fi
8729
8730  if test "x$ac_ct_RANLIB" = x; then
8731    RANLIB=":"
8732  else
8733    case $cross_compiling:$ac_tool_warned in
8734yes:)
8735{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8736$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8737ac_tool_warned=yes ;;
8738esac
8739    RANLIB=$ac_ct_RANLIB
8740  fi
8741else
8742  RANLIB="$ac_cv_prog_RANLIB"
8743fi
8744
8745test -z "$RANLIB" && RANLIB=:
8746
8747
8748
8749
8750
8751
8752# Determine commands to create old-style static archives.
8753old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
8754old_postinstall_cmds='chmod 644 $oldlib'
8755old_postuninstall_cmds=
8756
8757if test -n "$RANLIB"; then
8758  case $host_os in
8759  bitrig* | openbsd*)
8760    old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib"
8761    ;;
8762  *)
8763    old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib"
8764    ;;
8765  esac
8766  old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib"
8767fi
8768
8769case $host_os in
8770  darwin*)
8771    lock_old_archive_extraction=yes ;;
8772  *)
8773    lock_old_archive_extraction=no ;;
8774esac
8775
8776
8777
8778
8779
8780
8781
8782
8783
8784
8785
8786
8787
8788
8789
8790
8791
8792
8793
8794
8795
8796
8797
8798
8799
8800
8801
8802
8803
8804
8805
8806
8807
8808
8809
8810
8811
8812
8813
8814# If no C compiler was specified, use CC.
8815LTCC=${LTCC-"$CC"}
8816
8817# If no C compiler flags were specified, use CFLAGS.
8818LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
8819
8820# Allow CC to be a program name with arguments.
8821compiler=$CC
8822
8823
8824# Check for command to grab the raw symbol name followed by C symbol from nm.
8825{ $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5
8826$as_echo_n "checking command to parse $NM output from $compiler object... " >&6; }
8827if ${lt_cv_sys_global_symbol_pipe+:} false; then :
8828  $as_echo_n "(cached) " >&6
8829else
8830
8831# These are sane defaults that work on at least a few old systems.
8832# [They come from Ultrix.  What could be older than Ultrix?!! ;)]
8833
8834# Character class describing NM global symbol codes.
8835symcode='[BCDEGRST]'
8836
8837# Regexp to match symbols that can be accessed directly from C.
8838sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
8839
8840# Define system-specific variables.
8841case $host_os in
8842aix*)
8843  symcode='[BCDT]'
8844  ;;
8845cygwin* | mingw* | pw32* | cegcc*)
8846  symcode='[ABCDGISTW]'
8847  ;;
8848hpux*)
8849  if test ia64 = "$host_cpu"; then
8850    symcode='[ABCDEGRST]'
8851  fi
8852  ;;
8853irix* | nonstopux*)
8854  symcode='[BCDEGRST]'
8855  ;;
8856osf*)
8857  symcode='[BCDEGQRST]'
8858  ;;
8859solaris*)
8860  symcode='[BDRT]'
8861  ;;
8862sco3.2v5*)
8863  symcode='[DT]'
8864  ;;
8865sysv4.2uw2*)
8866  symcode='[DT]'
8867  ;;
8868sysv5* | sco5v6* | unixware* | OpenUNIX*)
8869  symcode='[ABDT]'
8870  ;;
8871sysv4)
8872  symcode='[DFNSTU]'
8873  ;;
8874esac
8875
8876# If we're using GNU nm, then use its standard symbol codes.
8877case `$NM -V 2>&1` in
8878*GNU* | *'with BFD'*)
8879  symcode='[ABCDGIRSTW]' ;;
8880esac
8881
8882if test "$lt_cv_nm_interface" = "MS dumpbin"; then
8883  # Gets list of data symbols to import.
8884  lt_cv_sys_global_symbol_to_import="sed -n -e 's/^I .* \(.*\)$/\1/p'"
8885  # Adjust the below global symbol transforms to fixup imported variables.
8886  lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'"
8887  lt_c_name_hook=" -e 's/^I .* \(.*\)$/  {\"\1\", (void *) 0},/p'"
8888  lt_c_name_lib_hook="\
8889  -e 's/^I .* \(lib.*\)$/  {\"\1\", (void *) 0},/p'\
8890  -e 's/^I .* \(.*\)$/  {\"lib\1\", (void *) 0},/p'"
8891else
8892  # Disable hooks by default.
8893  lt_cv_sys_global_symbol_to_import=
8894  lt_cdecl_hook=
8895  lt_c_name_hook=
8896  lt_c_name_lib_hook=
8897fi
8898
8899# Transform an extracted symbol line into a proper C declaration.
8900# Some systems (esp. on ia64) link data and code symbols differently,
8901# so use this general approach.
8902lt_cv_sys_global_symbol_to_cdecl="sed -n"\
8903$lt_cdecl_hook\
8904" -e 's/^T .* \(.*\)$/extern int \1();/p'"\
8905" -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'"
8906
8907# Transform an extracted symbol line into symbol name and symbol address
8908lt_cv_sys_global_symbol_to_c_name_address="sed -n"\
8909$lt_c_name_hook\
8910" -e 's/^: \(.*\) .*$/  {\"\1\", (void *) 0},/p'"\
8911" -e 's/^$symcode$symcode* .* \(.*\)$/  {\"\1\", (void *) \&\1},/p'"
8912
8913# Transform an extracted symbol line into symbol name with lib prefix and
8914# symbol address.
8915lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n"\
8916$lt_c_name_lib_hook\
8917" -e 's/^: \(.*\) .*$/  {\"\1\", (void *) 0},/p'"\
8918" -e 's/^$symcode$symcode* .* \(lib.*\)$/  {\"\1\", (void *) \&\1},/p'"\
8919" -e 's/^$symcode$symcode* .* \(.*\)$/  {\"lib\1\", (void *) \&\1},/p'"
8920
8921# Handle CRLF in mingw tool chain
8922opt_cr=
8923case $build_os in
8924mingw*)
8925  opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
8926  ;;
8927esac
8928
8929# Try without a prefix underscore, then with it.
8930for ac_symprfx in "" "_"; do
8931
8932  # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
8933  symxfrm="\\1 $ac_symprfx\\2 \\2"
8934
8935  # Write the raw and C identifiers.
8936  if test "$lt_cv_nm_interface" = "MS dumpbin"; then
8937    # Fake it for dumpbin and say T for any non-static function,
8938    # D for any global variable and I for any imported variable.
8939    # Also find C++ and __fastcall symbols from MSVC++,
8940    # which start with @ or ?.
8941    lt_cv_sys_global_symbol_pipe="$AWK '"\
8942"     {last_section=section; section=\$ 3};"\
8943"     /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\
8944"     /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
8945"     /^ *Symbol name *: /{split(\$ 0,sn,\":\"); si=substr(sn[2],2)};"\
8946"     /^ *Type *: code/{print \"T\",si,substr(si,length(prfx))};"\
8947"     /^ *Type *: data/{print \"I\",si,substr(si,length(prfx))};"\
8948"     \$ 0!~/External *\|/{next};"\
8949"     / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
8950"     {if(hide[section]) next};"\
8951"     {f=\"D\"}; \$ 0~/\(\).*\|/{f=\"T\"};"\
8952"     {split(\$ 0,a,/\||\r/); split(a[2],s)};"\
8953"     s[1]~/^[@?]/{print f,s[1],s[1]; next};"\
8954"     s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\
8955"     ' prfx=^$ac_symprfx"
8956  else
8957    lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[	 ]\($symcode$symcode*\)[	 ][	 ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
8958  fi
8959  lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
8960
8961  # Check to see that the pipe works correctly.
8962  pipe_works=no
8963
8964  rm -f conftest*
8965  cat > conftest.$ac_ext <<_LT_EOF
8966#ifdef __cplusplus
8967extern "C" {
8968#endif
8969char nm_test_var;
8970void nm_test_func(void);
8971void nm_test_func(void){}
8972#ifdef __cplusplus
8973}
8974#endif
8975int main(){nm_test_var='a';nm_test_func();return(0);}
8976_LT_EOF
8977
8978  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
8979  (eval $ac_compile) 2>&5
8980  ac_status=$?
8981  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8982  test $ac_status = 0; }; then
8983    # Now try to grab the symbols.
8984    nlist=conftest.nm
8985    if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5
8986  (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5
8987  ac_status=$?
8988  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8989  test $ac_status = 0; } && test -s "$nlist"; then
8990      # Try sorting and uniquifying the output.
8991      if sort "$nlist" | uniq > "$nlist"T; then
8992	mv -f "$nlist"T "$nlist"
8993      else
8994	rm -f "$nlist"T
8995      fi
8996
8997      # Make sure that we snagged all the symbols we need.
8998      if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
8999	if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
9000	  cat <<_LT_EOF > conftest.$ac_ext
9001/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests.  */
9002#if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE
9003/* DATA imports from DLLs on WIN32 can't be const, because runtime
9004   relocations are performed -- see ld's documentation on pseudo-relocs.  */
9005# define LT_DLSYM_CONST
9006#elif defined __osf__
9007/* This system does not cope well with relocations in const data.  */
9008# define LT_DLSYM_CONST
9009#else
9010# define LT_DLSYM_CONST const
9011#endif
9012
9013#ifdef __cplusplus
9014extern "C" {
9015#endif
9016
9017_LT_EOF
9018	  # Now generate the symbol file.
9019	  eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
9020
9021	  cat <<_LT_EOF >> conftest.$ac_ext
9022
9023/* The mapping between symbol names and symbols.  */
9024LT_DLSYM_CONST struct {
9025  const char *name;
9026  void       *address;
9027}
9028lt__PROGRAM__LTX_preloaded_symbols[] =
9029{
9030  { "@PROGRAM@", (void *) 0 },
9031_LT_EOF
9032	  $SED "s/^$symcode$symcode* .* \(.*\)$/  {\"\1\", (void *) \&\1},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
9033	  cat <<\_LT_EOF >> conftest.$ac_ext
9034  {0, (void *) 0}
9035};
9036
9037/* This works around a problem in FreeBSD linker */
9038#ifdef FREEBSD_WORKAROUND
9039static const void *lt_preloaded_setup() {
9040  return lt__PROGRAM__LTX_preloaded_symbols;
9041}
9042#endif
9043
9044#ifdef __cplusplus
9045}
9046#endif
9047_LT_EOF
9048	  # Now try linking the two files.
9049	  mv conftest.$ac_objext conftstm.$ac_objext
9050	  lt_globsym_save_LIBS=$LIBS
9051	  lt_globsym_save_CFLAGS=$CFLAGS
9052	  LIBS=conftstm.$ac_objext
9053	  CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
9054	  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
9055  (eval $ac_link) 2>&5
9056  ac_status=$?
9057  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9058  test $ac_status = 0; } && test -s conftest$ac_exeext; then
9059	    pipe_works=yes
9060	  fi
9061	  LIBS=$lt_globsym_save_LIBS
9062	  CFLAGS=$lt_globsym_save_CFLAGS
9063	else
9064	  echo "cannot find nm_test_func in $nlist" >&5
9065	fi
9066      else
9067	echo "cannot find nm_test_var in $nlist" >&5
9068      fi
9069    else
9070      echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5
9071    fi
9072  else
9073    echo "$progname: failed program was:" >&5
9074    cat conftest.$ac_ext >&5
9075  fi
9076  rm -rf conftest* conftst*
9077
9078  # Do not use the global_symbol_pipe unless it works.
9079  if test yes = "$pipe_works"; then
9080    break
9081  else
9082    lt_cv_sys_global_symbol_pipe=
9083  fi
9084done
9085
9086fi
9087
9088if test -z "$lt_cv_sys_global_symbol_pipe"; then
9089  lt_cv_sys_global_symbol_to_cdecl=
9090fi
9091if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
9092  { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
9093$as_echo "failed" >&6; }
9094else
9095  { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
9096$as_echo "ok" >&6; }
9097fi
9098
9099# Response file support.
9100if test "$lt_cv_nm_interface" = "MS dumpbin"; then
9101  nm_file_list_spec='@'
9102elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then
9103  nm_file_list_spec='@'
9104fi
9105
9106
9107
9108
9109
9110
9111
9112
9113
9114
9115
9116
9117
9118
9119
9120
9121
9122
9123
9124
9125
9126
9127
9128
9129
9130
9131
9132
9133
9134
9135
9136
9137
9138
9139
9140
9141
9142{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
9143$as_echo_n "checking for sysroot... " >&6; }
9144
9145# Check whether --with-sysroot was given.
9146if test "${with_sysroot+set}" = set; then :
9147  withval=$with_sysroot;
9148else
9149  with_sysroot=no
9150fi
9151
9152
9153lt_sysroot=
9154case $with_sysroot in #(
9155 yes)
9156   if test yes = "$GCC"; then
9157     lt_sysroot=`$CC --print-sysroot 2>/dev/null`
9158   fi
9159   ;; #(
9160 /*)
9161   lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"`
9162   ;; #(
9163 no|'')
9164   ;; #(
9165 *)
9166   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_sysroot" >&5
9167$as_echo "$with_sysroot" >&6; }
9168   as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5
9169   ;;
9170esac
9171
9172 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5
9173$as_echo "${lt_sysroot:-no}" >&6; }
9174
9175
9176
9177
9178
9179{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a working dd" >&5
9180$as_echo_n "checking for a working dd... " >&6; }
9181if ${ac_cv_path_lt_DD+:} false; then :
9182  $as_echo_n "(cached) " >&6
9183else
9184  printf 0123456789abcdef0123456789abcdef >conftest.i
9185cat conftest.i conftest.i >conftest2.i
9186: ${lt_DD:=$DD}
9187if test -z "$lt_DD"; then
9188  ac_path_lt_DD_found=false
9189  # Loop through the user's path and test for each of PROGNAME-LIST
9190  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9191for as_dir in $PATH
9192do
9193  IFS=$as_save_IFS
9194  test -z "$as_dir" && as_dir=.
9195    for ac_prog in dd; do
9196    for ac_exec_ext in '' $ac_executable_extensions; do
9197      ac_path_lt_DD="$as_dir/$ac_prog$ac_exec_ext"
9198      as_fn_executable_p "$ac_path_lt_DD" || continue
9199if "$ac_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then
9200  cmp -s conftest.i conftest.out \
9201  && ac_cv_path_lt_DD="$ac_path_lt_DD" ac_path_lt_DD_found=:
9202fi
9203      $ac_path_lt_DD_found && break 3
9204    done
9205  done
9206  done
9207IFS=$as_save_IFS
9208  if test -z "$ac_cv_path_lt_DD"; then
9209    :
9210  fi
9211else
9212  ac_cv_path_lt_DD=$lt_DD
9213fi
9214
9215rm -f conftest.i conftest2.i conftest.out
9216fi
9217{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_lt_DD" >&5
9218$as_echo "$ac_cv_path_lt_DD" >&6; }
9219
9220
9221{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to truncate binary pipes" >&5
9222$as_echo_n "checking how to truncate binary pipes... " >&6; }
9223if ${lt_cv_truncate_bin+:} false; then :
9224  $as_echo_n "(cached) " >&6
9225else
9226  printf 0123456789abcdef0123456789abcdef >conftest.i
9227cat conftest.i conftest.i >conftest2.i
9228lt_cv_truncate_bin=
9229if "$ac_cv_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then
9230  cmp -s conftest.i conftest.out \
9231  && lt_cv_truncate_bin="$ac_cv_path_lt_DD bs=4096 count=1"
9232fi
9233rm -f conftest.i conftest2.i conftest.out
9234test -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q"
9235fi
9236{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_truncate_bin" >&5
9237$as_echo "$lt_cv_truncate_bin" >&6; }
9238
9239
9240
9241
9242
9243
9244
9245# Calculate cc_basename.  Skip known compiler wrappers and cross-prefix.
9246func_cc_basename ()
9247{
9248    for cc_temp in $*""; do
9249      case $cc_temp in
9250        compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
9251        distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
9252        \-*) ;;
9253        *) break;;
9254      esac
9255    done
9256    func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
9257}
9258
9259# Check whether --enable-libtool-lock was given.
9260if test "${enable_libtool_lock+set}" = set; then :
9261  enableval=$enable_libtool_lock;
9262fi
9263
9264test no = "$enable_libtool_lock" || enable_libtool_lock=yes
9265
9266# Some flags need to be propagated to the compiler or linker for good
9267# libtool support.
9268case $host in
9269ia64-*-hpux*)
9270  # Find out what ABI is being produced by ac_compile, and set mode
9271  # options accordingly.
9272  echo 'int i;' > conftest.$ac_ext
9273  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9274  (eval $ac_compile) 2>&5
9275  ac_status=$?
9276  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9277  test $ac_status = 0; }; then
9278    case `/usr/bin/file conftest.$ac_objext` in
9279      *ELF-32*)
9280	HPUX_IA64_MODE=32
9281	;;
9282      *ELF-64*)
9283	HPUX_IA64_MODE=64
9284	;;
9285    esac
9286  fi
9287  rm -rf conftest*
9288  ;;
9289*-*-irix6*)
9290  # Find out what ABI is being produced by ac_compile, and set linker
9291  # options accordingly.
9292  echo '#line '$LINENO' "configure"' > conftest.$ac_ext
9293  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9294  (eval $ac_compile) 2>&5
9295  ac_status=$?
9296  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9297  test $ac_status = 0; }; then
9298    if test yes = "$lt_cv_prog_gnu_ld"; then
9299      case `/usr/bin/file conftest.$ac_objext` in
9300	*32-bit*)
9301	  LD="${LD-ld} -melf32bsmip"
9302	  ;;
9303	*N32*)
9304	  LD="${LD-ld} -melf32bmipn32"
9305	  ;;
9306	*64-bit*)
9307	  LD="${LD-ld} -melf64bmip"
9308	;;
9309      esac
9310    else
9311      case `/usr/bin/file conftest.$ac_objext` in
9312	*32-bit*)
9313	  LD="${LD-ld} -32"
9314	  ;;
9315	*N32*)
9316	  LD="${LD-ld} -n32"
9317	  ;;
9318	*64-bit*)
9319	  LD="${LD-ld} -64"
9320	  ;;
9321      esac
9322    fi
9323  fi
9324  rm -rf conftest*
9325  ;;
9326
9327mips64*-*linux*)
9328  # Find out what ABI is being produced by ac_compile, and set linker
9329  # options accordingly.
9330  echo '#line '$LINENO' "configure"' > conftest.$ac_ext
9331  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9332  (eval $ac_compile) 2>&5
9333  ac_status=$?
9334  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9335  test $ac_status = 0; }; then
9336    emul=elf
9337    case `/usr/bin/file conftest.$ac_objext` in
9338      *32-bit*)
9339	emul="${emul}32"
9340	;;
9341      *64-bit*)
9342	emul="${emul}64"
9343	;;
9344    esac
9345    case `/usr/bin/file conftest.$ac_objext` in
9346      *MSB*)
9347	emul="${emul}btsmip"
9348	;;
9349      *LSB*)
9350	emul="${emul}ltsmip"
9351	;;
9352    esac
9353    case `/usr/bin/file conftest.$ac_objext` in
9354      *N32*)
9355	emul="${emul}n32"
9356	;;
9357    esac
9358    LD="${LD-ld} -m $emul"
9359  fi
9360  rm -rf conftest*
9361  ;;
9362
9363x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \
9364s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
9365  # Find out what ABI is being produced by ac_compile, and set linker
9366  # options accordingly.  Note that the listed cases only cover the
9367  # situations where additional linker options are needed (such as when
9368  # doing 32-bit compilation for a host where ld defaults to 64-bit, or
9369  # vice versa); the common cases where no linker options are needed do
9370  # not appear in the list.
9371  echo 'int i;' > conftest.$ac_ext
9372  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9373  (eval $ac_compile) 2>&5
9374  ac_status=$?
9375  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9376  test $ac_status = 0; }; then
9377    case `/usr/bin/file conftest.o` in
9378      *32-bit*)
9379	case $host in
9380	  x86_64-*kfreebsd*-gnu)
9381	    LD="${LD-ld} -m elf_i386_fbsd"
9382	    ;;
9383	  x86_64-*linux*)
9384	    case `/usr/bin/file conftest.o` in
9385	      *x86-64*)
9386		LD="${LD-ld} -m elf32_x86_64"
9387		;;
9388	      *)
9389		LD="${LD-ld} -m elf_i386"
9390		;;
9391	    esac
9392	    ;;
9393	  powerpc64le-*linux*)
9394	    LD="${LD-ld} -m elf32lppclinux"
9395	    ;;
9396	  powerpc64-*linux*)
9397	    LD="${LD-ld} -m elf32ppclinux"
9398	    ;;
9399	  s390x-*linux*)
9400	    LD="${LD-ld} -m elf_s390"
9401	    ;;
9402	  sparc64-*linux*)
9403	    LD="${LD-ld} -m elf32_sparc"
9404	    ;;
9405	esac
9406	;;
9407      *64-bit*)
9408	case $host in
9409	  x86_64-*kfreebsd*-gnu)
9410	    LD="${LD-ld} -m elf_x86_64_fbsd"
9411	    ;;
9412	  x86_64-*linux*)
9413	    LD="${LD-ld} -m elf_x86_64"
9414	    ;;
9415	  powerpcle-*linux*)
9416	    LD="${LD-ld} -m elf64lppc"
9417	    ;;
9418	  powerpc-*linux*)
9419	    LD="${LD-ld} -m elf64ppc"
9420	    ;;
9421	  s390*-*linux*|s390*-*tpf*)
9422	    LD="${LD-ld} -m elf64_s390"
9423	    ;;
9424	  sparc*-*linux*)
9425	    LD="${LD-ld} -m elf64_sparc"
9426	    ;;
9427	esac
9428	;;
9429    esac
9430  fi
9431  rm -rf conftest*
9432  ;;
9433
9434*-*-sco3.2v5*)
9435  # On SCO OpenServer 5, we need -belf to get full-featured binaries.
9436  SAVE_CFLAGS=$CFLAGS
9437  CFLAGS="$CFLAGS -belf"
9438  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5
9439$as_echo_n "checking whether the C compiler needs -belf... " >&6; }
9440if ${lt_cv_cc_needs_belf+:} false; then :
9441  $as_echo_n "(cached) " >&6
9442else
9443  ac_ext=c
9444ac_cpp='$CPP $CPPFLAGS'
9445ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
9446ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
9447ac_compiler_gnu=$ac_cv_c_compiler_gnu
9448
9449     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9450/* end confdefs.h.  */
9451
9452int
9453main ()
9454{
9455
9456  ;
9457  return 0;
9458}
9459_ACEOF
9460if ac_fn_c_try_link "$LINENO"; then :
9461  lt_cv_cc_needs_belf=yes
9462else
9463  lt_cv_cc_needs_belf=no
9464fi
9465rm -f core conftest.err conftest.$ac_objext \
9466    conftest$ac_exeext conftest.$ac_ext
9467     ac_ext=c
9468ac_cpp='$CPP $CPPFLAGS'
9469ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
9470ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
9471ac_compiler_gnu=$ac_cv_c_compiler_gnu
9472
9473fi
9474{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5
9475$as_echo "$lt_cv_cc_needs_belf" >&6; }
9476  if test yes != "$lt_cv_cc_needs_belf"; then
9477    # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
9478    CFLAGS=$SAVE_CFLAGS
9479  fi
9480  ;;
9481*-*solaris*)
9482  # Find out what ABI is being produced by ac_compile, and set linker
9483  # options accordingly.
9484  echo 'int i;' > conftest.$ac_ext
9485  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9486  (eval $ac_compile) 2>&5
9487  ac_status=$?
9488  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9489  test $ac_status = 0; }; then
9490    case `/usr/bin/file conftest.o` in
9491    *64-bit*)
9492      case $lt_cv_prog_gnu_ld in
9493      yes*)
9494        case $host in
9495        i?86-*-solaris*|x86_64-*-solaris*)
9496          LD="${LD-ld} -m elf_x86_64"
9497          ;;
9498        sparc*-*-solaris*)
9499          LD="${LD-ld} -m elf64_sparc"
9500          ;;
9501        esac
9502        # GNU ld 2.21 introduced _sol2 emulations.  Use them if available.
9503        if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then
9504          LD=${LD-ld}_sol2
9505        fi
9506        ;;
9507      *)
9508	if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
9509	  LD="${LD-ld} -64"
9510	fi
9511	;;
9512      esac
9513      ;;
9514    esac
9515  fi
9516  rm -rf conftest*
9517  ;;
9518esac
9519
9520need_locks=$enable_libtool_lock
9521
9522if test -n "$ac_tool_prefix"; then
9523  # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args.
9524set dummy ${ac_tool_prefix}mt; ac_word=$2
9525{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9526$as_echo_n "checking for $ac_word... " >&6; }
9527if ${ac_cv_prog_MANIFEST_TOOL+:} false; then :
9528  $as_echo_n "(cached) " >&6
9529else
9530  if test -n "$MANIFEST_TOOL"; then
9531  ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test.
9532else
9533as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9534for as_dir in $PATH
9535do
9536  IFS=$as_save_IFS
9537  test -z "$as_dir" && as_dir=.
9538    for ac_exec_ext in '' $ac_executable_extensions; do
9539  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9540    ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt"
9541    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9542    break 2
9543  fi
9544done
9545  done
9546IFS=$as_save_IFS
9547
9548fi
9549fi
9550MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL
9551if test -n "$MANIFEST_TOOL"; then
9552  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5
9553$as_echo "$MANIFEST_TOOL" >&6; }
9554else
9555  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9556$as_echo "no" >&6; }
9557fi
9558
9559
9560fi
9561if test -z "$ac_cv_prog_MANIFEST_TOOL"; then
9562  ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL
9563  # Extract the first word of "mt", so it can be a program name with args.
9564set dummy mt; ac_word=$2
9565{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9566$as_echo_n "checking for $ac_word... " >&6; }
9567if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then :
9568  $as_echo_n "(cached) " >&6
9569else
9570  if test -n "$ac_ct_MANIFEST_TOOL"; then
9571  ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test.
9572else
9573as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9574for as_dir in $PATH
9575do
9576  IFS=$as_save_IFS
9577  test -z "$as_dir" && as_dir=.
9578    for ac_exec_ext in '' $ac_executable_extensions; do
9579  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9580    ac_cv_prog_ac_ct_MANIFEST_TOOL="mt"
9581    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9582    break 2
9583  fi
9584done
9585  done
9586IFS=$as_save_IFS
9587
9588fi
9589fi
9590ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL
9591if test -n "$ac_ct_MANIFEST_TOOL"; then
9592  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5
9593$as_echo "$ac_ct_MANIFEST_TOOL" >&6; }
9594else
9595  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9596$as_echo "no" >&6; }
9597fi
9598
9599  if test "x$ac_ct_MANIFEST_TOOL" = x; then
9600    MANIFEST_TOOL=":"
9601  else
9602    case $cross_compiling:$ac_tool_warned in
9603yes:)
9604{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9605$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9606ac_tool_warned=yes ;;
9607esac
9608    MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL
9609  fi
9610else
9611  MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL"
9612fi
9613
9614test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
9615{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5
9616$as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; }
9617if ${lt_cv_path_mainfest_tool+:} false; then :
9618  $as_echo_n "(cached) " >&6
9619else
9620  lt_cv_path_mainfest_tool=no
9621  echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5
9622  $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
9623  cat conftest.err >&5
9624  if $GREP 'Manifest Tool' conftest.out > /dev/null; then
9625    lt_cv_path_mainfest_tool=yes
9626  fi
9627  rm -f conftest*
9628fi
9629{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5
9630$as_echo "$lt_cv_path_mainfest_tool" >&6; }
9631if test yes != "$lt_cv_path_mainfest_tool"; then
9632  MANIFEST_TOOL=:
9633fi
9634
9635
9636
9637
9638
9639
9640  case $host_os in
9641    rhapsody* | darwin*)
9642    if test -n "$ac_tool_prefix"; then
9643  # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args.
9644set dummy ${ac_tool_prefix}dsymutil; ac_word=$2
9645{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9646$as_echo_n "checking for $ac_word... " >&6; }
9647if ${ac_cv_prog_DSYMUTIL+:} false; then :
9648  $as_echo_n "(cached) " >&6
9649else
9650  if test -n "$DSYMUTIL"; then
9651  ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
9652else
9653as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9654for as_dir in $PATH
9655do
9656  IFS=$as_save_IFS
9657  test -z "$as_dir" && as_dir=.
9658    for ac_exec_ext in '' $ac_executable_extensions; do
9659  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9660    ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil"
9661    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9662    break 2
9663  fi
9664done
9665  done
9666IFS=$as_save_IFS
9667
9668fi
9669fi
9670DSYMUTIL=$ac_cv_prog_DSYMUTIL
9671if test -n "$DSYMUTIL"; then
9672  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
9673$as_echo "$DSYMUTIL" >&6; }
9674else
9675  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9676$as_echo "no" >&6; }
9677fi
9678
9679
9680fi
9681if test -z "$ac_cv_prog_DSYMUTIL"; then
9682  ac_ct_DSYMUTIL=$DSYMUTIL
9683  # Extract the first word of "dsymutil", so it can be a program name with args.
9684set dummy dsymutil; ac_word=$2
9685{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9686$as_echo_n "checking for $ac_word... " >&6; }
9687if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then :
9688  $as_echo_n "(cached) " >&6
9689else
9690  if test -n "$ac_ct_DSYMUTIL"; then
9691  ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test.
9692else
9693as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9694for as_dir in $PATH
9695do
9696  IFS=$as_save_IFS
9697  test -z "$as_dir" && as_dir=.
9698    for ac_exec_ext in '' $ac_executable_extensions; do
9699  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9700    ac_cv_prog_ac_ct_DSYMUTIL="dsymutil"
9701    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9702    break 2
9703  fi
9704done
9705  done
9706IFS=$as_save_IFS
9707
9708fi
9709fi
9710ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL
9711if test -n "$ac_ct_DSYMUTIL"; then
9712  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5
9713$as_echo "$ac_ct_DSYMUTIL" >&6; }
9714else
9715  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9716$as_echo "no" >&6; }
9717fi
9718
9719  if test "x$ac_ct_DSYMUTIL" = x; then
9720    DSYMUTIL=":"
9721  else
9722    case $cross_compiling:$ac_tool_warned in
9723yes:)
9724{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9725$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9726ac_tool_warned=yes ;;
9727esac
9728    DSYMUTIL=$ac_ct_DSYMUTIL
9729  fi
9730else
9731  DSYMUTIL="$ac_cv_prog_DSYMUTIL"
9732fi
9733
9734    if test -n "$ac_tool_prefix"; then
9735  # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args.
9736set dummy ${ac_tool_prefix}nmedit; ac_word=$2
9737{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9738$as_echo_n "checking for $ac_word... " >&6; }
9739if ${ac_cv_prog_NMEDIT+:} false; then :
9740  $as_echo_n "(cached) " >&6
9741else
9742  if test -n "$NMEDIT"; then
9743  ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test.
9744else
9745as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9746for as_dir in $PATH
9747do
9748  IFS=$as_save_IFS
9749  test -z "$as_dir" && as_dir=.
9750    for ac_exec_ext in '' $ac_executable_extensions; do
9751  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9752    ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit"
9753    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9754    break 2
9755  fi
9756done
9757  done
9758IFS=$as_save_IFS
9759
9760fi
9761fi
9762NMEDIT=$ac_cv_prog_NMEDIT
9763if test -n "$NMEDIT"; then
9764  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5
9765$as_echo "$NMEDIT" >&6; }
9766else
9767  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9768$as_echo "no" >&6; }
9769fi
9770
9771
9772fi
9773if test -z "$ac_cv_prog_NMEDIT"; then
9774  ac_ct_NMEDIT=$NMEDIT
9775  # Extract the first word of "nmedit", so it can be a program name with args.
9776set dummy nmedit; ac_word=$2
9777{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9778$as_echo_n "checking for $ac_word... " >&6; }
9779if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then :
9780  $as_echo_n "(cached) " >&6
9781else
9782  if test -n "$ac_ct_NMEDIT"; then
9783  ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test.
9784else
9785as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9786for as_dir in $PATH
9787do
9788  IFS=$as_save_IFS
9789  test -z "$as_dir" && as_dir=.
9790    for ac_exec_ext in '' $ac_executable_extensions; do
9791  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9792    ac_cv_prog_ac_ct_NMEDIT="nmedit"
9793    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9794    break 2
9795  fi
9796done
9797  done
9798IFS=$as_save_IFS
9799
9800fi
9801fi
9802ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT
9803if test -n "$ac_ct_NMEDIT"; then
9804  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5
9805$as_echo "$ac_ct_NMEDIT" >&6; }
9806else
9807  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9808$as_echo "no" >&6; }
9809fi
9810
9811  if test "x$ac_ct_NMEDIT" = x; then
9812    NMEDIT=":"
9813  else
9814    case $cross_compiling:$ac_tool_warned in
9815yes:)
9816{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9817$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9818ac_tool_warned=yes ;;
9819esac
9820    NMEDIT=$ac_ct_NMEDIT
9821  fi
9822else
9823  NMEDIT="$ac_cv_prog_NMEDIT"
9824fi
9825
9826    if test -n "$ac_tool_prefix"; then
9827  # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args.
9828set dummy ${ac_tool_prefix}lipo; ac_word=$2
9829{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9830$as_echo_n "checking for $ac_word... " >&6; }
9831if ${ac_cv_prog_LIPO+:} false; then :
9832  $as_echo_n "(cached) " >&6
9833else
9834  if test -n "$LIPO"; then
9835  ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
9836else
9837as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9838for as_dir in $PATH
9839do
9840  IFS=$as_save_IFS
9841  test -z "$as_dir" && as_dir=.
9842    for ac_exec_ext in '' $ac_executable_extensions; do
9843  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9844    ac_cv_prog_LIPO="${ac_tool_prefix}lipo"
9845    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9846    break 2
9847  fi
9848done
9849  done
9850IFS=$as_save_IFS
9851
9852fi
9853fi
9854LIPO=$ac_cv_prog_LIPO
9855if test -n "$LIPO"; then
9856  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
9857$as_echo "$LIPO" >&6; }
9858else
9859  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9860$as_echo "no" >&6; }
9861fi
9862
9863
9864fi
9865if test -z "$ac_cv_prog_LIPO"; then
9866  ac_ct_LIPO=$LIPO
9867  # Extract the first word of "lipo", so it can be a program name with args.
9868set dummy lipo; ac_word=$2
9869{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9870$as_echo_n "checking for $ac_word... " >&6; }
9871if ${ac_cv_prog_ac_ct_LIPO+:} false; then :
9872  $as_echo_n "(cached) " >&6
9873else
9874  if test -n "$ac_ct_LIPO"; then
9875  ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test.
9876else
9877as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9878for as_dir in $PATH
9879do
9880  IFS=$as_save_IFS
9881  test -z "$as_dir" && as_dir=.
9882    for ac_exec_ext in '' $ac_executable_extensions; do
9883  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9884    ac_cv_prog_ac_ct_LIPO="lipo"
9885    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9886    break 2
9887  fi
9888done
9889  done
9890IFS=$as_save_IFS
9891
9892fi
9893fi
9894ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO
9895if test -n "$ac_ct_LIPO"; then
9896  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5
9897$as_echo "$ac_ct_LIPO" >&6; }
9898else
9899  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9900$as_echo "no" >&6; }
9901fi
9902
9903  if test "x$ac_ct_LIPO" = x; then
9904    LIPO=":"
9905  else
9906    case $cross_compiling:$ac_tool_warned in
9907yes:)
9908{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9909$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9910ac_tool_warned=yes ;;
9911esac
9912    LIPO=$ac_ct_LIPO
9913  fi
9914else
9915  LIPO="$ac_cv_prog_LIPO"
9916fi
9917
9918    if test -n "$ac_tool_prefix"; then
9919  # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args.
9920set dummy ${ac_tool_prefix}otool; ac_word=$2
9921{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9922$as_echo_n "checking for $ac_word... " >&6; }
9923if ${ac_cv_prog_OTOOL+:} false; then :
9924  $as_echo_n "(cached) " >&6
9925else
9926  if test -n "$OTOOL"; then
9927  ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
9928else
9929as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9930for as_dir in $PATH
9931do
9932  IFS=$as_save_IFS
9933  test -z "$as_dir" && as_dir=.
9934    for ac_exec_ext in '' $ac_executable_extensions; do
9935  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9936    ac_cv_prog_OTOOL="${ac_tool_prefix}otool"
9937    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9938    break 2
9939  fi
9940done
9941  done
9942IFS=$as_save_IFS
9943
9944fi
9945fi
9946OTOOL=$ac_cv_prog_OTOOL
9947if test -n "$OTOOL"; then
9948  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
9949$as_echo "$OTOOL" >&6; }
9950else
9951  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9952$as_echo "no" >&6; }
9953fi
9954
9955
9956fi
9957if test -z "$ac_cv_prog_OTOOL"; then
9958  ac_ct_OTOOL=$OTOOL
9959  # Extract the first word of "otool", so it can be a program name with args.
9960set dummy otool; ac_word=$2
9961{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9962$as_echo_n "checking for $ac_word... " >&6; }
9963if ${ac_cv_prog_ac_ct_OTOOL+:} false; then :
9964  $as_echo_n "(cached) " >&6
9965else
9966  if test -n "$ac_ct_OTOOL"; then
9967  ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test.
9968else
9969as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9970for as_dir in $PATH
9971do
9972  IFS=$as_save_IFS
9973  test -z "$as_dir" && as_dir=.
9974    for ac_exec_ext in '' $ac_executable_extensions; do
9975  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9976    ac_cv_prog_ac_ct_OTOOL="otool"
9977    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9978    break 2
9979  fi
9980done
9981  done
9982IFS=$as_save_IFS
9983
9984fi
9985fi
9986ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL
9987if test -n "$ac_ct_OTOOL"; then
9988  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5
9989$as_echo "$ac_ct_OTOOL" >&6; }
9990else
9991  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9992$as_echo "no" >&6; }
9993fi
9994
9995  if test "x$ac_ct_OTOOL" = x; then
9996    OTOOL=":"
9997  else
9998    case $cross_compiling:$ac_tool_warned in
9999yes:)
10000{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
10001$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
10002ac_tool_warned=yes ;;
10003esac
10004    OTOOL=$ac_ct_OTOOL
10005  fi
10006else
10007  OTOOL="$ac_cv_prog_OTOOL"
10008fi
10009
10010    if test -n "$ac_tool_prefix"; then
10011  # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args.
10012set dummy ${ac_tool_prefix}otool64; ac_word=$2
10013{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10014$as_echo_n "checking for $ac_word... " >&6; }
10015if ${ac_cv_prog_OTOOL64+:} false; then :
10016  $as_echo_n "(cached) " >&6
10017else
10018  if test -n "$OTOOL64"; then
10019  ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test.
10020else
10021as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10022for as_dir in $PATH
10023do
10024  IFS=$as_save_IFS
10025  test -z "$as_dir" && as_dir=.
10026    for ac_exec_ext in '' $ac_executable_extensions; do
10027  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10028    ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64"
10029    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10030    break 2
10031  fi
10032done
10033  done
10034IFS=$as_save_IFS
10035
10036fi
10037fi
10038OTOOL64=$ac_cv_prog_OTOOL64
10039if test -n "$OTOOL64"; then
10040  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5
10041$as_echo "$OTOOL64" >&6; }
10042else
10043  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10044$as_echo "no" >&6; }
10045fi
10046
10047
10048fi
10049if test -z "$ac_cv_prog_OTOOL64"; then
10050  ac_ct_OTOOL64=$OTOOL64
10051  # Extract the first word of "otool64", so it can be a program name with args.
10052set dummy otool64; ac_word=$2
10053{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10054$as_echo_n "checking for $ac_word... " >&6; }
10055if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then :
10056  $as_echo_n "(cached) " >&6
10057else
10058  if test -n "$ac_ct_OTOOL64"; then
10059  ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test.
10060else
10061as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10062for as_dir in $PATH
10063do
10064  IFS=$as_save_IFS
10065  test -z "$as_dir" && as_dir=.
10066    for ac_exec_ext in '' $ac_executable_extensions; do
10067  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10068    ac_cv_prog_ac_ct_OTOOL64="otool64"
10069    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10070    break 2
10071  fi
10072done
10073  done
10074IFS=$as_save_IFS
10075
10076fi
10077fi
10078ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64
10079if test -n "$ac_ct_OTOOL64"; then
10080  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5
10081$as_echo "$ac_ct_OTOOL64" >&6; }
10082else
10083  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10084$as_echo "no" >&6; }
10085fi
10086
10087  if test "x$ac_ct_OTOOL64" = x; then
10088    OTOOL64=":"
10089  else
10090    case $cross_compiling:$ac_tool_warned in
10091yes:)
10092{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
10093$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
10094ac_tool_warned=yes ;;
10095esac
10096    OTOOL64=$ac_ct_OTOOL64
10097  fi
10098else
10099  OTOOL64="$ac_cv_prog_OTOOL64"
10100fi
10101
10102
10103
10104
10105
10106
10107
10108
10109
10110
10111
10112
10113
10114
10115
10116
10117
10118
10119
10120
10121
10122
10123
10124
10125
10126
10127
10128    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5
10129$as_echo_n "checking for -single_module linker flag... " >&6; }
10130if ${lt_cv_apple_cc_single_mod+:} false; then :
10131  $as_echo_n "(cached) " >&6
10132else
10133  lt_cv_apple_cc_single_mod=no
10134      if test -z "$LT_MULTI_MODULE"; then
10135	# By default we will add the -single_module flag. You can override
10136	# by either setting the environment variable LT_MULTI_MODULE
10137	# non-empty at configure time, or by adding -multi_module to the
10138	# link flags.
10139	rm -rf libconftest.dylib*
10140	echo "int foo(void){return 1;}" > conftest.c
10141	echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
10142-dynamiclib -Wl,-single_module conftest.c" >&5
10143	$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
10144	  -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
10145        _lt_result=$?
10146	# If there is a non-empty error log, and "single_module"
10147	# appears in it, assume the flag caused a linker warning
10148        if test -s conftest.err && $GREP single_module conftest.err; then
10149	  cat conftest.err >&5
10150	# Otherwise, if the output was created with a 0 exit code from
10151	# the compiler, it worked.
10152	elif test -f libconftest.dylib && test 0 = "$_lt_result"; then
10153	  lt_cv_apple_cc_single_mod=yes
10154	else
10155	  cat conftest.err >&5
10156	fi
10157	rm -rf libconftest.dylib*
10158	rm -f conftest.*
10159      fi
10160fi
10161{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5
10162$as_echo "$lt_cv_apple_cc_single_mod" >&6; }
10163
10164    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5
10165$as_echo_n "checking for -exported_symbols_list linker flag... " >&6; }
10166if ${lt_cv_ld_exported_symbols_list+:} false; then :
10167  $as_echo_n "(cached) " >&6
10168else
10169  lt_cv_ld_exported_symbols_list=no
10170      save_LDFLAGS=$LDFLAGS
10171      echo "_main" > conftest.sym
10172      LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
10173      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10174/* end confdefs.h.  */
10175
10176int
10177main ()
10178{
10179
10180  ;
10181  return 0;
10182}
10183_ACEOF
10184if ac_fn_c_try_link "$LINENO"; then :
10185  lt_cv_ld_exported_symbols_list=yes
10186else
10187  lt_cv_ld_exported_symbols_list=no
10188fi
10189rm -f core conftest.err conftest.$ac_objext \
10190    conftest$ac_exeext conftest.$ac_ext
10191	LDFLAGS=$save_LDFLAGS
10192
10193fi
10194{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5
10195$as_echo "$lt_cv_ld_exported_symbols_list" >&6; }
10196
10197    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5
10198$as_echo_n "checking for -force_load linker flag... " >&6; }
10199if ${lt_cv_ld_force_load+:} false; then :
10200  $as_echo_n "(cached) " >&6
10201else
10202  lt_cv_ld_force_load=no
10203      cat > conftest.c << _LT_EOF
10204int forced_loaded() { return 2;}
10205_LT_EOF
10206      echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5
10207      $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
10208      echo "$AR cru libconftest.a conftest.o" >&5
10209      $AR cru libconftest.a conftest.o 2>&5
10210      echo "$RANLIB libconftest.a" >&5
10211      $RANLIB libconftest.a 2>&5
10212      cat > conftest.c << _LT_EOF
10213int main() { return 0;}
10214_LT_EOF
10215      echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5
10216      $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
10217      _lt_result=$?
10218      if test -s conftest.err && $GREP force_load conftest.err; then
10219	cat conftest.err >&5
10220      elif test -f conftest && test 0 = "$_lt_result" && $GREP forced_load conftest >/dev/null 2>&1; then
10221	lt_cv_ld_force_load=yes
10222      else
10223	cat conftest.err >&5
10224      fi
10225        rm -f conftest.err libconftest.a conftest conftest.c
10226        rm -rf conftest.dSYM
10227
10228fi
10229{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5
10230$as_echo "$lt_cv_ld_force_load" >&6; }
10231    case $host_os in
10232    rhapsody* | darwin1.[012])
10233      _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;;
10234    darwin1.*)
10235      _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;;
10236    darwin*) # darwin 5.x on
10237      # if running on 10.5 or later, the deployment target defaults
10238      # to the OS version, if on x86, and 10.4, the deployment
10239      # target defaults to 10.4. Don't you love it?
10240      case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
10241	10.0,*86*-darwin8*|10.0,*-darwin[91]*)
10242	  _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;;
10243	10.[012][,.]*)
10244	  _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;;
10245	10.*)
10246	  _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;;
10247      esac
10248    ;;
10249  esac
10250    if test yes = "$lt_cv_apple_cc_single_mod"; then
10251      _lt_dar_single_mod='$single_module'
10252    fi
10253    if test yes = "$lt_cv_ld_exported_symbols_list"; then
10254      _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym'
10255    else
10256      _lt_dar_export_syms='~$NMEDIT -s $output_objdir/$libname-symbols.expsym $lib'
10257    fi
10258    if test : != "$DSYMUTIL" && test no = "$lt_cv_ld_force_load"; then
10259      _lt_dsymutil='~$DSYMUTIL $lib || :'
10260    else
10261      _lt_dsymutil=
10262    fi
10263    ;;
10264  esac
10265
10266# func_munge_path_list VARIABLE PATH
10267# -----------------------------------
10268# VARIABLE is name of variable containing _space_ separated list of
10269# directories to be munged by the contents of PATH, which is string
10270# having a format:
10271# "DIR[:DIR]:"
10272#       string "DIR[ DIR]" will be prepended to VARIABLE
10273# ":DIR[:DIR]"
10274#       string "DIR[ DIR]" will be appended to VARIABLE
10275# "DIRP[:DIRP]::[DIRA:]DIRA"
10276#       string "DIRP[ DIRP]" will be prepended to VARIABLE and string
10277#       "DIRA[ DIRA]" will be appended to VARIABLE
10278# "DIR[:DIR]"
10279#       VARIABLE will be replaced by "DIR[ DIR]"
10280func_munge_path_list ()
10281{
10282    case x$2 in
10283    x)
10284        ;;
10285    *:)
10286        eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\"
10287        ;;
10288    x:*)
10289        eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\"
10290        ;;
10291    *::*)
10292        eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\"
10293        eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\"
10294        ;;
10295    *)
10296        eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\"
10297        ;;
10298    esac
10299}
10300
10301for ac_header in dlfcn.h
10302do :
10303  ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
10304"
10305if test "x$ac_cv_header_dlfcn_h" = xyes; then :
10306  cat >>confdefs.h <<_ACEOF
10307#define HAVE_DLFCN_H 1
10308_ACEOF
10309
10310fi
10311
10312done
10313
10314
10315
10316
10317
10318# Set options
10319
10320
10321
10322        enable_dlopen=no
10323
10324
10325  enable_win32_dll=no
10326
10327
10328
10329  # Check whether --enable-static was given.
10330if test "${enable_static+set}" = set; then :
10331  enableval=$enable_static; p=${PACKAGE-default}
10332    case $enableval in
10333    yes) enable_static=yes ;;
10334    no) enable_static=no ;;
10335    *)
10336     enable_static=no
10337      # Look at the argument we got.  We use all the common list separators.
10338      lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
10339      for pkg in $enableval; do
10340	IFS=$lt_save_ifs
10341	if test "X$pkg" = "X$p"; then
10342	  enable_static=yes
10343	fi
10344      done
10345      IFS=$lt_save_ifs
10346      ;;
10347    esac
10348else
10349  enable_static=yes
10350fi
10351
10352
10353
10354
10355
10356
10357
10358
10359
10360
10361# Check whether --with-pic was given.
10362if test "${with_pic+set}" = set; then :
10363  withval=$with_pic; lt_p=${PACKAGE-default}
10364    case $withval in
10365    yes|no) pic_mode=$withval ;;
10366    *)
10367      pic_mode=default
10368      # Look at the argument we got.  We use all the common list separators.
10369      lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
10370      for lt_pkg in $withval; do
10371	IFS=$lt_save_ifs
10372	if test "X$lt_pkg" = "X$lt_p"; then
10373	  pic_mode=yes
10374	fi
10375      done
10376      IFS=$lt_save_ifs
10377      ;;
10378    esac
10379else
10380  pic_mode=default
10381fi
10382
10383
10384
10385
10386
10387
10388
10389
10390  # Check whether --enable-fast-install was given.
10391if test "${enable_fast_install+set}" = set; then :
10392  enableval=$enable_fast_install; p=${PACKAGE-default}
10393    case $enableval in
10394    yes) enable_fast_install=yes ;;
10395    no) enable_fast_install=no ;;
10396    *)
10397      enable_fast_install=no
10398      # Look at the argument we got.  We use all the common list separators.
10399      lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
10400      for pkg in $enableval; do
10401	IFS=$lt_save_ifs
10402	if test "X$pkg" = "X$p"; then
10403	  enable_fast_install=yes
10404	fi
10405      done
10406      IFS=$lt_save_ifs
10407      ;;
10408    esac
10409else
10410  enable_fast_install=yes
10411fi
10412
10413
10414
10415
10416
10417
10418
10419
10420  shared_archive_member_spec=
10421case $host,$enable_shared in
10422power*-*-aix[5-9]*,yes)
10423  { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variant of shared library versioning to provide" >&5
10424$as_echo_n "checking which variant of shared library versioning to provide... " >&6; }
10425
10426# Check whether --with-aix-soname was given.
10427if test "${with_aix_soname+set}" = set; then :
10428  withval=$with_aix_soname; case $withval in
10429    aix|svr4|both)
10430      ;;
10431    *)
10432      as_fn_error $? "Unknown argument to --with-aix-soname" "$LINENO" 5
10433      ;;
10434    esac
10435    lt_cv_with_aix_soname=$with_aix_soname
10436else
10437  if ${lt_cv_with_aix_soname+:} false; then :
10438  $as_echo_n "(cached) " >&6
10439else
10440  lt_cv_with_aix_soname=aix
10441fi
10442
10443    with_aix_soname=$lt_cv_with_aix_soname
10444fi
10445
10446  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_aix_soname" >&5
10447$as_echo "$with_aix_soname" >&6; }
10448  if test aix != "$with_aix_soname"; then
10449    # For the AIX way of multilib, we name the shared archive member
10450    # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o',
10451    # and 'shr.imp' or 'shr_64.imp', respectively, for the Import File.
10452    # Even when GNU compilers ignore OBJECT_MODE but need '-maix64' flag,
10453    # the AIX toolchain works better with OBJECT_MODE set (default 32).
10454    if test 64 = "${OBJECT_MODE-32}"; then
10455      shared_archive_member_spec=shr_64
10456    else
10457      shared_archive_member_spec=shr
10458    fi
10459  fi
10460  ;;
10461*)
10462  with_aix_soname=aix
10463  ;;
10464esac
10465
10466
10467
10468
10469
10470
10471
10472
10473
10474
10475# This can be used to rebuild libtool when needed
10476LIBTOOL_DEPS=$ltmain
10477
10478# Always use our own libtool.
10479LIBTOOL='$(SHELL) $(top_builddir)/libtool'
10480
10481
10482
10483
10484
10485
10486
10487
10488
10489
10490
10491
10492
10493
10494
10495
10496
10497
10498
10499
10500
10501
10502
10503
10504
10505
10506
10507
10508
10509
10510test -z "$LN_S" && LN_S="ln -s"
10511
10512
10513
10514
10515
10516
10517
10518
10519
10520
10521
10522
10523
10524
10525if test -n "${ZSH_VERSION+set}"; then
10526   setopt NO_GLOB_SUBST
10527fi
10528
10529{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5
10530$as_echo_n "checking for objdir... " >&6; }
10531if ${lt_cv_objdir+:} false; then :
10532  $as_echo_n "(cached) " >&6
10533else
10534  rm -f .libs 2>/dev/null
10535mkdir .libs 2>/dev/null
10536if test -d .libs; then
10537  lt_cv_objdir=.libs
10538else
10539  # MS-DOS does not allow filenames that begin with a dot.
10540  lt_cv_objdir=_libs
10541fi
10542rmdir .libs 2>/dev/null
10543fi
10544{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5
10545$as_echo "$lt_cv_objdir" >&6; }
10546objdir=$lt_cv_objdir
10547
10548
10549
10550
10551
10552cat >>confdefs.h <<_ACEOF
10553#define LT_OBJDIR "$lt_cv_objdir/"
10554_ACEOF
10555
10556
10557
10558
10559case $host_os in
10560aix3*)
10561  # AIX sometimes has problems with the GCC collect2 program.  For some
10562  # reason, if we set the COLLECT_NAMES environment variable, the problems
10563  # vanish in a puff of smoke.
10564  if test set != "${COLLECT_NAMES+set}"; then
10565    COLLECT_NAMES=
10566    export COLLECT_NAMES
10567  fi
10568  ;;
10569esac
10570
10571# Global variables:
10572ofile=libtool
10573can_build_shared=yes
10574
10575# All known linkers require a '.a' archive for static linking (except MSVC,
10576# which needs '.lib').
10577libext=a
10578
10579with_gnu_ld=$lt_cv_prog_gnu_ld
10580
10581old_CC=$CC
10582old_CFLAGS=$CFLAGS
10583
10584# Set sane defaults for various variables
10585test -z "$CC" && CC=cc
10586test -z "$LTCC" && LTCC=$CC
10587test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
10588test -z "$LD" && LD=ld
10589test -z "$ac_objext" && ac_objext=o
10590
10591func_cc_basename $compiler
10592cc_basename=$func_cc_basename_result
10593
10594
10595# Only perform the check for file, if the check method requires it
10596test -z "$MAGIC_CMD" && MAGIC_CMD=file
10597case $deplibs_check_method in
10598file_magic*)
10599  if test "$file_magic_cmd" = '$MAGIC_CMD'; then
10600    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5
10601$as_echo_n "checking for ${ac_tool_prefix}file... " >&6; }
10602if ${lt_cv_path_MAGIC_CMD+:} false; then :
10603  $as_echo_n "(cached) " >&6
10604else
10605  case $MAGIC_CMD in
10606[\\/*] |  ?:[\\/]*)
10607  lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path.
10608  ;;
10609*)
10610  lt_save_MAGIC_CMD=$MAGIC_CMD
10611  lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
10612  ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
10613  for ac_dir in $ac_dummy; do
10614    IFS=$lt_save_ifs
10615    test -z "$ac_dir" && ac_dir=.
10616    if test -f "$ac_dir/${ac_tool_prefix}file"; then
10617      lt_cv_path_MAGIC_CMD=$ac_dir/"${ac_tool_prefix}file"
10618      if test -n "$file_magic_test_file"; then
10619	case $deplibs_check_method in
10620	"file_magic "*)
10621	  file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
10622	  MAGIC_CMD=$lt_cv_path_MAGIC_CMD
10623	  if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
10624	    $EGREP "$file_magic_regex" > /dev/null; then
10625	    :
10626	  else
10627	    cat <<_LT_EOF 1>&2
10628
10629*** Warning: the command libtool uses to detect shared libraries,
10630*** $file_magic_cmd, produces output that libtool cannot recognize.
10631*** The result is that libtool may fail to recognize shared libraries
10632*** as such.  This will affect the creation of libtool libraries that
10633*** depend on shared libraries, but programs linked with such libtool
10634*** libraries will work regardless of this problem.  Nevertheless, you
10635*** may want to report the problem to your system manager and/or to
10636*** bug-libtool@gnu.org
10637
10638_LT_EOF
10639	  fi ;;
10640	esac
10641      fi
10642      break
10643    fi
10644  done
10645  IFS=$lt_save_ifs
10646  MAGIC_CMD=$lt_save_MAGIC_CMD
10647  ;;
10648esac
10649fi
10650
10651MAGIC_CMD=$lt_cv_path_MAGIC_CMD
10652if test -n "$MAGIC_CMD"; then
10653  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
10654$as_echo "$MAGIC_CMD" >&6; }
10655else
10656  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10657$as_echo "no" >&6; }
10658fi
10659
10660
10661
10662
10663
10664if test -z "$lt_cv_path_MAGIC_CMD"; then
10665  if test -n "$ac_tool_prefix"; then
10666    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5
10667$as_echo_n "checking for file... " >&6; }
10668if ${lt_cv_path_MAGIC_CMD+:} false; then :
10669  $as_echo_n "(cached) " >&6
10670else
10671  case $MAGIC_CMD in
10672[\\/*] |  ?:[\\/]*)
10673  lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path.
10674  ;;
10675*)
10676  lt_save_MAGIC_CMD=$MAGIC_CMD
10677  lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
10678  ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
10679  for ac_dir in $ac_dummy; do
10680    IFS=$lt_save_ifs
10681    test -z "$ac_dir" && ac_dir=.
10682    if test -f "$ac_dir/file"; then
10683      lt_cv_path_MAGIC_CMD=$ac_dir/"file"
10684      if test -n "$file_magic_test_file"; then
10685	case $deplibs_check_method in
10686	"file_magic "*)
10687	  file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
10688	  MAGIC_CMD=$lt_cv_path_MAGIC_CMD
10689	  if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
10690	    $EGREP "$file_magic_regex" > /dev/null; then
10691	    :
10692	  else
10693	    cat <<_LT_EOF 1>&2
10694
10695*** Warning: the command libtool uses to detect shared libraries,
10696*** $file_magic_cmd, produces output that libtool cannot recognize.
10697*** The result is that libtool may fail to recognize shared libraries
10698*** as such.  This will affect the creation of libtool libraries that
10699*** depend on shared libraries, but programs linked with such libtool
10700*** libraries will work regardless of this problem.  Nevertheless, you
10701*** may want to report the problem to your system manager and/or to
10702*** bug-libtool@gnu.org
10703
10704_LT_EOF
10705	  fi ;;
10706	esac
10707      fi
10708      break
10709    fi
10710  done
10711  IFS=$lt_save_ifs
10712  MAGIC_CMD=$lt_save_MAGIC_CMD
10713  ;;
10714esac
10715fi
10716
10717MAGIC_CMD=$lt_cv_path_MAGIC_CMD
10718if test -n "$MAGIC_CMD"; then
10719  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
10720$as_echo "$MAGIC_CMD" >&6; }
10721else
10722  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10723$as_echo "no" >&6; }
10724fi
10725
10726
10727  else
10728    MAGIC_CMD=:
10729  fi
10730fi
10731
10732  fi
10733  ;;
10734esac
10735
10736# Use C for the default configuration in the libtool script
10737
10738lt_save_CC=$CC
10739ac_ext=c
10740ac_cpp='$CPP $CPPFLAGS'
10741ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
10742ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
10743ac_compiler_gnu=$ac_cv_c_compiler_gnu
10744
10745
10746# Source file extension for C test sources.
10747ac_ext=c
10748
10749# Object file extension for compiled C test sources.
10750objext=o
10751objext=$objext
10752
10753# Code to be used in simple compile tests
10754lt_simple_compile_test_code="int some_variable = 0;"
10755
10756# Code to be used in simple link tests
10757lt_simple_link_test_code='int main(){return(0);}'
10758
10759
10760
10761
10762
10763
10764
10765# If no C compiler was specified, use CC.
10766LTCC=${LTCC-"$CC"}
10767
10768# If no C compiler flags were specified, use CFLAGS.
10769LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
10770
10771# Allow CC to be a program name with arguments.
10772compiler=$CC
10773
10774# Save the default compiler, since it gets overwritten when the other
10775# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
10776compiler_DEFAULT=$CC
10777
10778# save warnings/boilerplate of simple test code
10779ac_outfile=conftest.$ac_objext
10780echo "$lt_simple_compile_test_code" >conftest.$ac_ext
10781eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
10782_lt_compiler_boilerplate=`cat conftest.err`
10783$RM conftest*
10784
10785ac_outfile=conftest.$ac_objext
10786echo "$lt_simple_link_test_code" >conftest.$ac_ext
10787eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
10788_lt_linker_boilerplate=`cat conftest.err`
10789$RM -r conftest*
10790
10791
10792## CAVEAT EMPTOR:
10793## There is no encapsulation within the following macros, do not change
10794## the running order or otherwise move them around unless you know exactly
10795## what you are doing...
10796if test -n "$compiler"; then
10797
10798lt_prog_compiler_no_builtin_flag=
10799
10800if test yes = "$GCC"; then
10801  case $cc_basename in
10802  nvcc*)
10803    lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;;
10804  *)
10805    lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;;
10806  esac
10807
10808  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
10809$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; }
10810if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then :
10811  $as_echo_n "(cached) " >&6
10812else
10813  lt_cv_prog_compiler_rtti_exceptions=no
10814   ac_outfile=conftest.$ac_objext
10815   echo "$lt_simple_compile_test_code" > conftest.$ac_ext
10816   lt_compiler_flag="-fno-rtti -fno-exceptions"  ## exclude from sc_useless_quotes_in_assignment
10817   # Insert the option either (1) after the last *FLAGS variable, or
10818   # (2) before a word containing "conftest.", or (3) at the end.
10819   # Note that $ac_compile itself does not contain backslashes and begins
10820   # with a dollar sign (not a hyphen), so the echo should work correctly.
10821   # The option is referenced via a variable to avoid confusing sed.
10822   lt_compile=`echo "$ac_compile" | $SED \
10823   -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
10824   -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
10825   -e 's:$: $lt_compiler_flag:'`
10826   (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
10827   (eval "$lt_compile" 2>conftest.err)
10828   ac_status=$?
10829   cat conftest.err >&5
10830   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10831   if (exit $ac_status) && test -s "$ac_outfile"; then
10832     # The compiler can only warn and ignore the option if not recognized
10833     # So say no if there are warnings other than the usual output.
10834     $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
10835     $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
10836     if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
10837       lt_cv_prog_compiler_rtti_exceptions=yes
10838     fi
10839   fi
10840   $RM conftest*
10841
10842fi
10843{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
10844$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; }
10845
10846if test yes = "$lt_cv_prog_compiler_rtti_exceptions"; then
10847    lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions"
10848else
10849    :
10850fi
10851
10852fi
10853
10854
10855
10856
10857
10858
10859  lt_prog_compiler_wl=
10860lt_prog_compiler_pic=
10861lt_prog_compiler_static=
10862
10863
10864  if test yes = "$GCC"; then
10865    lt_prog_compiler_wl='-Wl,'
10866    lt_prog_compiler_static='-static'
10867
10868    case $host_os in
10869      aix*)
10870      # All AIX code is PIC.
10871      if test ia64 = "$host_cpu"; then
10872	# AIX 5 now supports IA64 processor
10873	lt_prog_compiler_static='-Bstatic'
10874      fi
10875      lt_prog_compiler_pic='-fPIC'
10876      ;;
10877
10878    amigaos*)
10879      case $host_cpu in
10880      powerpc)
10881            # see comment about AmigaOS4 .so support
10882            lt_prog_compiler_pic='-fPIC'
10883        ;;
10884      m68k)
10885            # FIXME: we need at least 68020 code to build shared libraries, but
10886            # adding the '-m68020' flag to GCC prevents building anything better,
10887            # like '-m68040'.
10888            lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4'
10889        ;;
10890      esac
10891      ;;
10892
10893    beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
10894      # PIC is the default for these OSes.
10895      ;;
10896
10897    mingw* | cygwin* | pw32* | os2* | cegcc*)
10898      # This hack is so that the source file can tell whether it is being
10899      # built for inclusion in a dll (and should export symbols for example).
10900      # Although the cygwin gcc ignores -fPIC, still need this for old-style
10901      # (--disable-auto-import) libraries
10902      lt_prog_compiler_pic='-DDLL_EXPORT'
10903      case $host_os in
10904      os2*)
10905	lt_prog_compiler_static='$wl-static'
10906	;;
10907      esac
10908      ;;
10909
10910    darwin* | rhapsody*)
10911      # PIC is the default on this platform
10912      # Common symbols not allowed in MH_DYLIB files
10913      lt_prog_compiler_pic='-fno-common'
10914      ;;
10915
10916    haiku*)
10917      # PIC is the default for Haiku.
10918      # The "-static" flag exists, but is broken.
10919      lt_prog_compiler_static=
10920      ;;
10921
10922    hpux*)
10923      # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
10924      # PA HP-UX.  On IA64 HP-UX, PIC is the default but the pic flag
10925      # sets the default TLS model and affects inlining.
10926      case $host_cpu in
10927      hppa*64*)
10928	# +Z the default
10929	;;
10930      *)
10931	lt_prog_compiler_pic='-fPIC'
10932	;;
10933      esac
10934      ;;
10935
10936    interix[3-9]*)
10937      # Interix 3.x gcc -fpic/-fPIC options generate broken code.
10938      # Instead, we relocate shared libraries at runtime.
10939      ;;
10940
10941    msdosdjgpp*)
10942      # Just because we use GCC doesn't mean we suddenly get shared libraries
10943      # on systems that don't support them.
10944      lt_prog_compiler_can_build_shared=no
10945      enable_shared=no
10946      ;;
10947
10948    *nto* | *qnx*)
10949      # QNX uses GNU C++, but need to define -shared option too, otherwise
10950      # it will coredump.
10951      lt_prog_compiler_pic='-fPIC -shared'
10952      ;;
10953
10954    sysv4*MP*)
10955      if test -d /usr/nec; then
10956	lt_prog_compiler_pic=-Kconform_pic
10957      fi
10958      ;;
10959
10960    *)
10961      lt_prog_compiler_pic='-fPIC'
10962      ;;
10963    esac
10964
10965    case $cc_basename in
10966    nvcc*) # Cuda Compiler Driver 2.2
10967      lt_prog_compiler_wl='-Xlinker '
10968      if test -n "$lt_prog_compiler_pic"; then
10969        lt_prog_compiler_pic="-Xcompiler $lt_prog_compiler_pic"
10970      fi
10971      ;;
10972    esac
10973  else
10974    # PORTME Check for flag to pass linker flags through the system compiler.
10975    case $host_os in
10976    aix*)
10977      lt_prog_compiler_wl='-Wl,'
10978      if test ia64 = "$host_cpu"; then
10979	# AIX 5 now supports IA64 processor
10980	lt_prog_compiler_static='-Bstatic'
10981      else
10982	lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp'
10983      fi
10984      ;;
10985
10986    darwin* | rhapsody*)
10987      # PIC is the default on this platform
10988      # Common symbols not allowed in MH_DYLIB files
10989      lt_prog_compiler_pic='-fno-common'
10990      case $cc_basename in
10991      nagfor*)
10992        # NAG Fortran compiler
10993        lt_prog_compiler_wl='-Wl,-Wl,,'
10994        lt_prog_compiler_pic='-PIC'
10995        lt_prog_compiler_static='-Bstatic'
10996        ;;
10997      esac
10998      ;;
10999
11000    mingw* | cygwin* | pw32* | os2* | cegcc*)
11001      # This hack is so that the source file can tell whether it is being
11002      # built for inclusion in a dll (and should export symbols for example).
11003      lt_prog_compiler_pic='-DDLL_EXPORT'
11004      case $host_os in
11005      os2*)
11006	lt_prog_compiler_static='$wl-static'
11007	;;
11008      esac
11009      ;;
11010
11011    hpux9* | hpux10* | hpux11*)
11012      lt_prog_compiler_wl='-Wl,'
11013      # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
11014      # not for PA HP-UX.
11015      case $host_cpu in
11016      hppa*64*|ia64*)
11017	# +Z the default
11018	;;
11019      *)
11020	lt_prog_compiler_pic='+Z'
11021	;;
11022      esac
11023      # Is there a better lt_prog_compiler_static that works with the bundled CC?
11024      lt_prog_compiler_static='$wl-a ${wl}archive'
11025      ;;
11026
11027    irix5* | irix6* | nonstopux*)
11028      lt_prog_compiler_wl='-Wl,'
11029      # PIC (with -KPIC) is the default.
11030      lt_prog_compiler_static='-non_shared'
11031      ;;
11032
11033    linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
11034      case $cc_basename in
11035      # old Intel for x86_64, which still supported -KPIC.
11036      ecc*)
11037	lt_prog_compiler_wl='-Wl,'
11038	lt_prog_compiler_pic='-KPIC'
11039	lt_prog_compiler_static='-static'
11040        ;;
11041      # icc used to be incompatible with GCC.
11042      # ICC 10 doesn't accept -KPIC any more.
11043      icc* | ifort*)
11044	lt_prog_compiler_wl='-Wl,'
11045	lt_prog_compiler_pic='-fPIC'
11046	lt_prog_compiler_static='-static'
11047        ;;
11048      # Lahey Fortran 8.1.
11049      lf95*)
11050	lt_prog_compiler_wl='-Wl,'
11051	lt_prog_compiler_pic='--shared'
11052	lt_prog_compiler_static='--static'
11053	;;
11054      nagfor*)
11055	# NAG Fortran compiler
11056	lt_prog_compiler_wl='-Wl,-Wl,,'
11057	lt_prog_compiler_pic='-PIC'
11058	lt_prog_compiler_static='-Bstatic'
11059	;;
11060      tcc*)
11061	# Fabrice Bellard et al's Tiny C Compiler
11062	lt_prog_compiler_wl='-Wl,'
11063	lt_prog_compiler_pic='-fPIC'
11064	lt_prog_compiler_static='-static'
11065	;;
11066      pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
11067        # Portland Group compilers (*not* the Pentium gcc compiler,
11068	# which looks to be a dead project)
11069	lt_prog_compiler_wl='-Wl,'
11070	lt_prog_compiler_pic='-fpic'
11071	lt_prog_compiler_static='-Bstatic'
11072        ;;
11073      ccc*)
11074        lt_prog_compiler_wl='-Wl,'
11075        # All Alpha code is PIC.
11076        lt_prog_compiler_static='-non_shared'
11077        ;;
11078      xl* | bgxl* | bgf* | mpixl*)
11079	# IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
11080	lt_prog_compiler_wl='-Wl,'
11081	lt_prog_compiler_pic='-qpic'
11082	lt_prog_compiler_static='-qstaticlink'
11083	;;
11084      *)
11085	case `$CC -V 2>&1 | sed 5q` in
11086	*Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [1-7].* | *Sun*Fortran*\ 8.[0-3]*)
11087	  # Sun Fortran 8.3 passes all unrecognized flags to the linker
11088	  lt_prog_compiler_pic='-KPIC'
11089	  lt_prog_compiler_static='-Bstatic'
11090	  lt_prog_compiler_wl=''
11091	  ;;
11092	*Sun\ F* | *Sun*Fortran*)
11093	  lt_prog_compiler_pic='-KPIC'
11094	  lt_prog_compiler_static='-Bstatic'
11095	  lt_prog_compiler_wl='-Qoption ld '
11096	  ;;
11097	*Sun\ C*)
11098	  # Sun C 5.9
11099	  lt_prog_compiler_pic='-KPIC'
11100	  lt_prog_compiler_static='-Bstatic'
11101	  lt_prog_compiler_wl='-Wl,'
11102	  ;;
11103        *Intel*\ [CF]*Compiler*)
11104	  lt_prog_compiler_wl='-Wl,'
11105	  lt_prog_compiler_pic='-fPIC'
11106	  lt_prog_compiler_static='-static'
11107	  ;;
11108	*Portland\ Group*)
11109	  lt_prog_compiler_wl='-Wl,'
11110	  lt_prog_compiler_pic='-fpic'
11111	  lt_prog_compiler_static='-Bstatic'
11112	  ;;
11113	esac
11114	;;
11115      esac
11116      ;;
11117
11118    newsos6)
11119      lt_prog_compiler_pic='-KPIC'
11120      lt_prog_compiler_static='-Bstatic'
11121      ;;
11122
11123    *nto* | *qnx*)
11124      # QNX uses GNU C++, but need to define -shared option too, otherwise
11125      # it will coredump.
11126      lt_prog_compiler_pic='-fPIC -shared'
11127      ;;
11128
11129    osf3* | osf4* | osf5*)
11130      lt_prog_compiler_wl='-Wl,'
11131      # All OSF/1 code is PIC.
11132      lt_prog_compiler_static='-non_shared'
11133      ;;
11134
11135    rdos*)
11136      lt_prog_compiler_static='-non_shared'
11137      ;;
11138
11139    solaris*)
11140      lt_prog_compiler_pic='-KPIC'
11141      lt_prog_compiler_static='-Bstatic'
11142      case $cc_basename in
11143      f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
11144	lt_prog_compiler_wl='-Qoption ld ';;
11145      *)
11146	lt_prog_compiler_wl='-Wl,';;
11147      esac
11148      ;;
11149
11150    sunos4*)
11151      lt_prog_compiler_wl='-Qoption ld '
11152      lt_prog_compiler_pic='-PIC'
11153      lt_prog_compiler_static='-Bstatic'
11154      ;;
11155
11156    sysv4 | sysv4.2uw2* | sysv4.3*)
11157      lt_prog_compiler_wl='-Wl,'
11158      lt_prog_compiler_pic='-KPIC'
11159      lt_prog_compiler_static='-Bstatic'
11160      ;;
11161
11162    sysv4*MP*)
11163      if test -d /usr/nec; then
11164	lt_prog_compiler_pic='-Kconform_pic'
11165	lt_prog_compiler_static='-Bstatic'
11166      fi
11167      ;;
11168
11169    sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
11170      lt_prog_compiler_wl='-Wl,'
11171      lt_prog_compiler_pic='-KPIC'
11172      lt_prog_compiler_static='-Bstatic'
11173      ;;
11174
11175    unicos*)
11176      lt_prog_compiler_wl='-Wl,'
11177      lt_prog_compiler_can_build_shared=no
11178      ;;
11179
11180    uts4*)
11181      lt_prog_compiler_pic='-pic'
11182      lt_prog_compiler_static='-Bstatic'
11183      ;;
11184
11185    *)
11186      lt_prog_compiler_can_build_shared=no
11187      ;;
11188    esac
11189  fi
11190
11191case $host_os in
11192  # For platforms that do not support PIC, -DPIC is meaningless:
11193  *djgpp*)
11194    lt_prog_compiler_pic=
11195    ;;
11196  *)
11197    lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
11198    ;;
11199esac
11200
11201{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
11202$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
11203if ${lt_cv_prog_compiler_pic+:} false; then :
11204  $as_echo_n "(cached) " >&6
11205else
11206  lt_cv_prog_compiler_pic=$lt_prog_compiler_pic
11207fi
11208{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5
11209$as_echo "$lt_cv_prog_compiler_pic" >&6; }
11210lt_prog_compiler_pic=$lt_cv_prog_compiler_pic
11211
11212#
11213# Check to make sure the PIC flag actually works.
11214#
11215if test -n "$lt_prog_compiler_pic"; then
11216  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
11217$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; }
11218if ${lt_cv_prog_compiler_pic_works+:} false; then :
11219  $as_echo_n "(cached) " >&6
11220else
11221  lt_cv_prog_compiler_pic_works=no
11222   ac_outfile=conftest.$ac_objext
11223   echo "$lt_simple_compile_test_code" > conftest.$ac_ext
11224   lt_compiler_flag="$lt_prog_compiler_pic -DPIC"  ## exclude from sc_useless_quotes_in_assignment
11225   # Insert the option either (1) after the last *FLAGS variable, or
11226   # (2) before a word containing "conftest.", or (3) at the end.
11227   # Note that $ac_compile itself does not contain backslashes and begins
11228   # with a dollar sign (not a hyphen), so the echo should work correctly.
11229   # The option is referenced via a variable to avoid confusing sed.
11230   lt_compile=`echo "$ac_compile" | $SED \
11231   -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
11232   -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
11233   -e 's:$: $lt_compiler_flag:'`
11234   (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
11235   (eval "$lt_compile" 2>conftest.err)
11236   ac_status=$?
11237   cat conftest.err >&5
11238   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11239   if (exit $ac_status) && test -s "$ac_outfile"; then
11240     # The compiler can only warn and ignore the option if not recognized
11241     # So say no if there are warnings other than the usual output.
11242     $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
11243     $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
11244     if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
11245       lt_cv_prog_compiler_pic_works=yes
11246     fi
11247   fi
11248   $RM conftest*
11249
11250fi
11251{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5
11252$as_echo "$lt_cv_prog_compiler_pic_works" >&6; }
11253
11254if test yes = "$lt_cv_prog_compiler_pic_works"; then
11255    case $lt_prog_compiler_pic in
11256     "" | " "*) ;;
11257     *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;;
11258     esac
11259else
11260    lt_prog_compiler_pic=
11261     lt_prog_compiler_can_build_shared=no
11262fi
11263
11264fi
11265
11266
11267
11268
11269
11270
11271
11272
11273
11274
11275
11276#
11277# Check to make sure the static flag actually works.
11278#
11279wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\"
11280{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5
11281$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
11282if ${lt_cv_prog_compiler_static_works+:} false; then :
11283  $as_echo_n "(cached) " >&6
11284else
11285  lt_cv_prog_compiler_static_works=no
11286   save_LDFLAGS=$LDFLAGS
11287   LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
11288   echo "$lt_simple_link_test_code" > conftest.$ac_ext
11289   if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
11290     # The linker can only warn and ignore the option if not recognized
11291     # So say no if there are warnings
11292     if test -s conftest.err; then
11293       # Append any errors to the config.log.
11294       cat conftest.err 1>&5
11295       $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
11296       $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
11297       if diff conftest.exp conftest.er2 >/dev/null; then
11298         lt_cv_prog_compiler_static_works=yes
11299       fi
11300     else
11301       lt_cv_prog_compiler_static_works=yes
11302     fi
11303   fi
11304   $RM -r conftest*
11305   LDFLAGS=$save_LDFLAGS
11306
11307fi
11308{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5
11309$as_echo "$lt_cv_prog_compiler_static_works" >&6; }
11310
11311if test yes = "$lt_cv_prog_compiler_static_works"; then
11312    :
11313else
11314    lt_prog_compiler_static=
11315fi
11316
11317
11318
11319
11320
11321
11322
11323  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
11324$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
11325if ${lt_cv_prog_compiler_c_o+:} false; then :
11326  $as_echo_n "(cached) " >&6
11327else
11328  lt_cv_prog_compiler_c_o=no
11329   $RM -r conftest 2>/dev/null
11330   mkdir conftest
11331   cd conftest
11332   mkdir out
11333   echo "$lt_simple_compile_test_code" > conftest.$ac_ext
11334
11335   lt_compiler_flag="-o out/conftest2.$ac_objext"
11336   # Insert the option either (1) after the last *FLAGS variable, or
11337   # (2) before a word containing "conftest.", or (3) at the end.
11338   # Note that $ac_compile itself does not contain backslashes and begins
11339   # with a dollar sign (not a hyphen), so the echo should work correctly.
11340   lt_compile=`echo "$ac_compile" | $SED \
11341   -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
11342   -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
11343   -e 's:$: $lt_compiler_flag:'`
11344   (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
11345   (eval "$lt_compile" 2>out/conftest.err)
11346   ac_status=$?
11347   cat out/conftest.err >&5
11348   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11349   if (exit $ac_status) && test -s out/conftest2.$ac_objext
11350   then
11351     # The compiler can only warn and ignore the option if not recognized
11352     # So say no if there are warnings
11353     $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
11354     $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
11355     if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
11356       lt_cv_prog_compiler_c_o=yes
11357     fi
11358   fi
11359   chmod u+w . 2>&5
11360   $RM conftest*
11361   # SGI C++ compiler will create directory out/ii_files/ for
11362   # template instantiation
11363   test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
11364   $RM out/* && rmdir out
11365   cd ..
11366   $RM -r conftest
11367   $RM conftest*
11368
11369fi
11370{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
11371$as_echo "$lt_cv_prog_compiler_c_o" >&6; }
11372
11373
11374
11375
11376
11377
11378  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
11379$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
11380if ${lt_cv_prog_compiler_c_o+:} false; then :
11381  $as_echo_n "(cached) " >&6
11382else
11383  lt_cv_prog_compiler_c_o=no
11384   $RM -r conftest 2>/dev/null
11385   mkdir conftest
11386   cd conftest
11387   mkdir out
11388   echo "$lt_simple_compile_test_code" > conftest.$ac_ext
11389
11390   lt_compiler_flag="-o out/conftest2.$ac_objext"
11391   # Insert the option either (1) after the last *FLAGS variable, or
11392   # (2) before a word containing "conftest.", or (3) at the end.
11393   # Note that $ac_compile itself does not contain backslashes and begins
11394   # with a dollar sign (not a hyphen), so the echo should work correctly.
11395   lt_compile=`echo "$ac_compile" | $SED \
11396   -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
11397   -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
11398   -e 's:$: $lt_compiler_flag:'`
11399   (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
11400   (eval "$lt_compile" 2>out/conftest.err)
11401   ac_status=$?
11402   cat out/conftest.err >&5
11403   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11404   if (exit $ac_status) && test -s out/conftest2.$ac_objext
11405   then
11406     # The compiler can only warn and ignore the option if not recognized
11407     # So say no if there are warnings
11408     $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
11409     $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
11410     if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
11411       lt_cv_prog_compiler_c_o=yes
11412     fi
11413   fi
11414   chmod u+w . 2>&5
11415   $RM conftest*
11416   # SGI C++ compiler will create directory out/ii_files/ for
11417   # template instantiation
11418   test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
11419   $RM out/* && rmdir out
11420   cd ..
11421   $RM -r conftest
11422   $RM conftest*
11423
11424fi
11425{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
11426$as_echo "$lt_cv_prog_compiler_c_o" >&6; }
11427
11428
11429
11430
11431hard_links=nottested
11432if test no = "$lt_cv_prog_compiler_c_o" && test no != "$need_locks"; then
11433  # do not overwrite the value of need_locks provided by the user
11434  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5
11435$as_echo_n "checking if we can lock with hard links... " >&6; }
11436  hard_links=yes
11437  $RM conftest*
11438  ln conftest.a conftest.b 2>/dev/null && hard_links=no
11439  touch conftest.a
11440  ln conftest.a conftest.b 2>&5 || hard_links=no
11441  ln conftest.a conftest.b 2>/dev/null && hard_links=no
11442  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5
11443$as_echo "$hard_links" >&6; }
11444  if test no = "$hard_links"; then
11445    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&5
11446$as_echo "$as_me: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&2;}
11447    need_locks=warn
11448  fi
11449else
11450  need_locks=no
11451fi
11452
11453
11454
11455
11456
11457
11458  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
11459$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
11460
11461  runpath_var=
11462  allow_undefined_flag=
11463  always_export_symbols=no
11464  archive_cmds=
11465  archive_expsym_cmds=
11466  compiler_needs_object=no
11467  enable_shared_with_static_runtimes=no
11468  export_dynamic_flag_spec=
11469  export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
11470  hardcode_automatic=no
11471  hardcode_direct=no
11472  hardcode_direct_absolute=no
11473  hardcode_libdir_flag_spec=
11474  hardcode_libdir_separator=
11475  hardcode_minus_L=no
11476  hardcode_shlibpath_var=unsupported
11477  inherit_rpath=no
11478  link_all_deplibs=unknown
11479  module_cmds=
11480  module_expsym_cmds=
11481  old_archive_from_new_cmds=
11482  old_archive_from_expsyms_cmds=
11483  thread_safe_flag_spec=
11484  whole_archive_flag_spec=
11485  # include_expsyms should be a list of space-separated symbols to be *always*
11486  # included in the symbol list
11487  include_expsyms=
11488  # exclude_expsyms can be an extended regexp of symbols to exclude
11489  # it will be wrapped by ' (' and ')$', so one must not match beginning or
11490  # end of line.  Example: 'a|bc|.*d.*' will exclude the symbols 'a' and 'bc',
11491  # as well as any symbol that contains 'd'.
11492  exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
11493  # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
11494  # platforms (ab)use it in PIC code, but their linkers get confused if
11495  # the symbol is explicitly referenced.  Since portable code cannot
11496  # rely on this symbol name, it's probably fine to never include it in
11497  # preloaded symbol tables.
11498  # Exclude shared library initialization/finalization symbols.
11499  extract_expsyms_cmds=
11500
11501  case $host_os in
11502  cygwin* | mingw* | pw32* | cegcc*)
11503    # FIXME: the MSVC++ port hasn't been tested in a loooong time
11504    # When not using gcc, we currently assume that we are using
11505    # Microsoft Visual C++.
11506    if test yes != "$GCC"; then
11507      with_gnu_ld=no
11508    fi
11509    ;;
11510  interix*)
11511    # we just hope/assume this is gcc and not c89 (= MSVC++)
11512    with_gnu_ld=yes
11513    ;;
11514  openbsd* | bitrig*)
11515    with_gnu_ld=no
11516    ;;
11517  esac
11518
11519  ld_shlibs=yes
11520
11521  # On some targets, GNU ld is compatible enough with the native linker
11522  # that we're better off using the native interface for both.
11523  lt_use_gnu_ld_interface=no
11524  if test yes = "$with_gnu_ld"; then
11525    case $host_os in
11526      aix*)
11527	# The AIX port of GNU ld has always aspired to compatibility
11528	# with the native linker.  However, as the warning in the GNU ld
11529	# block says, versions before 2.19.5* couldn't really create working
11530	# shared libraries, regardless of the interface used.
11531	case `$LD -v 2>&1` in
11532	  *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
11533	  *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;;
11534	  *\ \(GNU\ Binutils\)\ [3-9]*) ;;
11535	  *)
11536	    lt_use_gnu_ld_interface=yes
11537	    ;;
11538	esac
11539	;;
11540      *)
11541	lt_use_gnu_ld_interface=yes
11542	;;
11543    esac
11544  fi
11545
11546  if test yes = "$lt_use_gnu_ld_interface"; then
11547    # If archive_cmds runs LD, not CC, wlarc should be empty
11548    wlarc='$wl'
11549
11550    # Set some defaults for GNU ld with shared library support. These
11551    # are reset later if shared libraries are not supported. Putting them
11552    # here allows them to be overridden if necessary.
11553    runpath_var=LD_RUN_PATH
11554    hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
11555    export_dynamic_flag_spec='$wl--export-dynamic'
11556    # ancient GNU ld didn't support --whole-archive et. al.
11557    if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
11558      whole_archive_flag_spec=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive'
11559    else
11560      whole_archive_flag_spec=
11561    fi
11562    supports_anon_versioning=no
11563    case `$LD -v | $SED -e 's/(^)\+)\s\+//' 2>&1` in
11564      *GNU\ gold*) supports_anon_versioning=yes ;;
11565      *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
11566      *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
11567      *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
11568      *\ 2.11.*) ;; # other 2.11 versions
11569      *) supports_anon_versioning=yes ;;
11570    esac
11571
11572    # See if GNU ld supports shared libraries.
11573    case $host_os in
11574    aix[3-9]*)
11575      # On AIX/PPC, the GNU linker is very broken
11576      if test ia64 != "$host_cpu"; then
11577	ld_shlibs=no
11578	cat <<_LT_EOF 1>&2
11579
11580*** Warning: the GNU linker, at least up to release 2.19, is reported
11581*** to be unable to reliably create shared libraries on AIX.
11582*** Therefore, libtool is disabling shared libraries support.  If you
11583*** really care for shared libraries, you may want to install binutils
11584*** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
11585*** You will then need to restart the configuration process.
11586
11587_LT_EOF
11588      fi
11589      ;;
11590
11591    amigaos*)
11592      case $host_cpu in
11593      powerpc)
11594            # see comment about AmigaOS4 .so support
11595            archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11596            archive_expsym_cmds=''
11597        ;;
11598      m68k)
11599            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)'
11600            hardcode_libdir_flag_spec='-L$libdir'
11601            hardcode_minus_L=yes
11602        ;;
11603      esac
11604      ;;
11605
11606    beos*)
11607      if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
11608	allow_undefined_flag=unsupported
11609	# Joseph Beckenbach <jrb3@best.com> says some releases of gcc
11610	# support --undefined.  This deserves some investigation.  FIXME
11611	archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11612      else
11613	ld_shlibs=no
11614      fi
11615      ;;
11616
11617    cygwin* | mingw* | pw32* | cegcc*)
11618      # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless,
11619      # as there is no search path for DLLs.
11620      hardcode_libdir_flag_spec='-L$libdir'
11621      export_dynamic_flag_spec='$wl--export-all-symbols'
11622      allow_undefined_flag=unsupported
11623      always_export_symbols=no
11624      enable_shared_with_static_runtimes=yes
11625      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'
11626      exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'
11627
11628      if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
11629        archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
11630	# If the export-symbols file already is a .def file, use it as
11631	# is; otherwise, prepend EXPORTS...
11632	archive_expsym_cmds='if   test DEF = "`$SED -n     -e '\''s/^[	 ]*//'\''     -e '\''/^\(;.*\)*$/d'\''     -e '\''s/^\(EXPORTS\|LIBRARY\)\([	 ].*\)*$/DEF/p'\''     -e q     $export_symbols`" ; then
11633          cp $export_symbols $output_objdir/$soname.def;
11634        else
11635          echo EXPORTS > $output_objdir/$soname.def;
11636          cat $export_symbols >> $output_objdir/$soname.def;
11637        fi~
11638        $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
11639      else
11640	ld_shlibs=no
11641      fi
11642      ;;
11643
11644    haiku*)
11645      archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11646      link_all_deplibs=yes
11647      ;;
11648
11649    os2*)
11650      hardcode_libdir_flag_spec='-L$libdir'
11651      hardcode_minus_L=yes
11652      allow_undefined_flag=unsupported
11653      shrext_cmds=.dll
11654      archive_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
11655	$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
11656	$ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
11657	$ECHO EXPORTS >> $output_objdir/$libname.def~
11658	emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
11659	$CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
11660	emximp -o $lib $output_objdir/$libname.def'
11661      archive_expsym_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
11662	$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
11663	$ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
11664	$ECHO EXPORTS >> $output_objdir/$libname.def~
11665	prefix_cmds="$SED"~
11666	if test EXPORTS = "`$SED 1q $export_symbols`"; then
11667	  prefix_cmds="$prefix_cmds -e 1d";
11668	fi~
11669	prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
11670	cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
11671	$CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
11672	emximp -o $lib $output_objdir/$libname.def'
11673      old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
11674      enable_shared_with_static_runtimes=yes
11675      ;;
11676
11677    interix[3-9]*)
11678      hardcode_direct=no
11679      hardcode_shlibpath_var=no
11680      hardcode_libdir_flag_spec='$wl-rpath,$libdir'
11681      export_dynamic_flag_spec='$wl-E'
11682      # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
11683      # Instead, shared libraries are loaded at an image base (0x10000000 by
11684      # default) and relocated if they conflict, which is a slow very memory
11685      # consuming and fragmenting process.  To avoid this, we pick a random,
11686      # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
11687      # time.  Moving up from 0x10000000 also allows more sbrk(2) space.
11688      archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
11689      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'
11690      ;;
11691
11692    gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
11693      tmp_diet=no
11694      if test linux-dietlibc = "$host_os"; then
11695	case $cc_basename in
11696	  diet\ *) tmp_diet=yes;;	# linux-dietlibc with static linking (!diet-dyn)
11697	esac
11698      fi
11699      if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
11700	 && test no = "$tmp_diet"
11701      then
11702	tmp_addflag=' $pic_flag'
11703	tmp_sharedflag='-shared'
11704	case $cc_basename,$host_cpu in
11705        pgcc*)				# Portland Group C compiler
11706	  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'
11707	  tmp_addflag=' $pic_flag'
11708	  ;;
11709	pgf77* | pgf90* | pgf95* | pgfortran*)
11710					# Portland Group f77 and f90 compilers
11711	  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'
11712	  tmp_addflag=' $pic_flag -Mnomain' ;;
11713	ecc*,ia64* | icc*,ia64*)	# Intel C compiler on ia64
11714	  tmp_addflag=' -i_dynamic' ;;
11715	efc*,ia64* | ifort*,ia64*)	# Intel Fortran compiler on ia64
11716	  tmp_addflag=' -i_dynamic -nofor_main' ;;
11717	ifc* | ifort*)			# Intel Fortran compiler
11718	  tmp_addflag=' -nofor_main' ;;
11719	lf95*)				# Lahey Fortran 8.1
11720	  whole_archive_flag_spec=
11721	  tmp_sharedflag='--shared' ;;
11722        nagfor*)                        # NAGFOR 5.3
11723          tmp_sharedflag='-Wl,-shared' ;;
11724	xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below)
11725	  tmp_sharedflag='-qmkshrobj'
11726	  tmp_addflag= ;;
11727	nvcc*)	# Cuda Compiler Driver 2.2
11728	  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'
11729	  compiler_needs_object=yes
11730	  ;;
11731	esac
11732	case `$CC -V 2>&1 | sed 5q` in
11733	*Sun\ C*)			# Sun C 5.9
11734	  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'
11735	  compiler_needs_object=yes
11736	  tmp_sharedflag='-G' ;;
11737	*Sun\ F*)			# Sun Fortran 8.3
11738	  tmp_sharedflag='-G' ;;
11739	esac
11740	archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11741
11742        if test yes = "$supports_anon_versioning"; then
11743          archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
11744            cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
11745            echo "local: *; };" >> $output_objdir/$libname.ver~
11746            $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib'
11747        fi
11748
11749	case $cc_basename in
11750	tcc*)
11751	  export_dynamic_flag_spec='-rdynamic'
11752	  ;;
11753	xlf* | bgf* | bgxlf* | mpixlf*)
11754	  # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
11755	  whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
11756	  hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
11757	  archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
11758	  if test yes = "$supports_anon_versioning"; then
11759	    archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
11760              cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
11761              echo "local: *; };" >> $output_objdir/$libname.ver~
11762              $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
11763	  fi
11764	  ;;
11765	esac
11766      else
11767        ld_shlibs=no
11768      fi
11769      ;;
11770
11771    netbsd*)
11772      if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
11773	archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
11774	wlarc=
11775      else
11776	archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11777	archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
11778      fi
11779      ;;
11780
11781    solaris*)
11782      if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
11783	ld_shlibs=no
11784	cat <<_LT_EOF 1>&2
11785
11786*** Warning: The releases 2.8.* of the GNU linker cannot reliably
11787*** create shared libraries on Solaris systems.  Therefore, libtool
11788*** is disabling shared libraries support.  We urge you to upgrade GNU
11789*** binutils to release 2.9.1 or newer.  Another option is to modify
11790*** your PATH or compiler configuration so that the native linker is
11791*** used, and then restart.
11792
11793_LT_EOF
11794      elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
11795	archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11796	archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
11797      else
11798	ld_shlibs=no
11799      fi
11800      ;;
11801
11802    sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
11803      case `$LD -v 2>&1` in
11804        *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*)
11805	ld_shlibs=no
11806	cat <<_LT_EOF 1>&2
11807
11808*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 cannot
11809*** reliably create shared libraries on SCO systems.  Therefore, libtool
11810*** is disabling shared libraries support.  We urge you to upgrade GNU
11811*** binutils to release 2.16.91.0.3 or newer.  Another option is to modify
11812*** your PATH or compiler configuration so that the native linker is
11813*** used, and then restart.
11814
11815_LT_EOF
11816	;;
11817	*)
11818	  # For security reasons, it is highly recommended that you always
11819	  # use absolute paths for naming shared libraries, and exclude the
11820	  # DT_RUNPATH tag from executables and libraries.  But doing so
11821	  # requires that you compile everything twice, which is a pain.
11822	  if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
11823	    hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
11824	    archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11825	    archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
11826	  else
11827	    ld_shlibs=no
11828	  fi
11829	;;
11830      esac
11831      ;;
11832
11833    sunos4*)
11834      archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
11835      wlarc=
11836      hardcode_direct=yes
11837      hardcode_shlibpath_var=no
11838      ;;
11839
11840    *)
11841      if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
11842	archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11843	archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
11844      else
11845	ld_shlibs=no
11846      fi
11847      ;;
11848    esac
11849
11850    if test no = "$ld_shlibs"; then
11851      runpath_var=
11852      hardcode_libdir_flag_spec=
11853      export_dynamic_flag_spec=
11854      whole_archive_flag_spec=
11855    fi
11856  else
11857    # PORTME fill in a description of your system's linker (not GNU ld)
11858    case $host_os in
11859    aix3*)
11860      allow_undefined_flag=unsupported
11861      always_export_symbols=yes
11862      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'
11863      # Note: this linker hardcodes the directories in LIBPATH if there
11864      # are no directories specified by -L.
11865      hardcode_minus_L=yes
11866      if test yes = "$GCC" && test -z "$lt_prog_compiler_static"; then
11867	# Neither direct hardcoding nor static linking is supported with a
11868	# broken collect2.
11869	hardcode_direct=unsupported
11870      fi
11871      ;;
11872
11873    aix[4-9]*)
11874      if test ia64 = "$host_cpu"; then
11875	# On IA64, the linker does run time linking by default, so we don't
11876	# have to do anything special.
11877	aix_use_runtimelinking=no
11878	exp_sym_flag='-Bexport'
11879	no_entry_flag=
11880      else
11881	# If we're using GNU nm, then we don't want the "-C" option.
11882	# -C means demangle to GNU nm, but means don't demangle to AIX nm.
11883	# Without the "-l" option, or with the "-B" option, AIX nm treats
11884	# weak defined symbols like other global defined symbols, whereas
11885	# GNU nm marks them as "W".
11886	# While the 'weak' keyword is ignored in the Export File, we need
11887	# it in the Import File for the 'aix-soname' feature, so we have
11888	# to replace the "-B" option with "-P" for AIX nm.
11889	if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
11890	  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'
11891	else
11892	  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'
11893	fi
11894	aix_use_runtimelinking=no
11895
11896	# Test if we are trying to use run time linking or normal
11897	# AIX style linking. If -brtl is somewhere in LDFLAGS, we
11898	# have runtime linking enabled, and use it for executables.
11899	# For shared libraries, we enable/disable runtime linking
11900	# depending on the kind of the shared library created -
11901	# when "with_aix_soname,aix_use_runtimelinking" is:
11902	# "aix,no"   lib.a(lib.so.V) shared, rtl:no,  for executables
11903	# "aix,yes"  lib.so          shared, rtl:yes, for executables
11904	#            lib.a           static archive
11905	# "both,no"  lib.so.V(shr.o) shared, rtl:yes
11906	#            lib.a(lib.so.V) shared, rtl:no,  for executables
11907	# "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables
11908	#            lib.a(lib.so.V) shared, rtl:no
11909	# "svr4,*"   lib.so.V(shr.o) shared, rtl:yes, for executables
11910	#            lib.a           static archive
11911	case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
11912	  for ld_flag in $LDFLAGS; do
11913	  if (test x-brtl = "x$ld_flag" || test x-Wl,-brtl = "x$ld_flag"); then
11914	    aix_use_runtimelinking=yes
11915	    break
11916	  fi
11917	  done
11918	  if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then
11919	    # With aix-soname=svr4, we create the lib.so.V shared archives only,
11920	    # so we don't have lib.a shared libs to link our executables.
11921	    # We have to force runtime linking in this case.
11922	    aix_use_runtimelinking=yes
11923	    LDFLAGS="$LDFLAGS -Wl,-brtl"
11924	  fi
11925	  ;;
11926	esac
11927
11928	exp_sym_flag='-bexport'
11929	no_entry_flag='-bnoentry'
11930      fi
11931
11932      # When large executables or shared objects are built, AIX ld can
11933      # have problems creating the table of contents.  If linking a library
11934      # or program results in "error TOC overflow" add -mminimal-toc to
11935      # CXXFLAGS/CFLAGS for g++/gcc.  In the cases where that is not
11936      # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
11937
11938      archive_cmds=''
11939      hardcode_direct=yes
11940      hardcode_direct_absolute=yes
11941      hardcode_libdir_separator=':'
11942      link_all_deplibs=yes
11943      file_list_spec='$wl-f,'
11944      case $with_aix_soname,$aix_use_runtimelinking in
11945      aix,*) ;; # traditional, no import file
11946      svr4,* | *,yes) # use import file
11947	# The Import File defines what to hardcode.
11948	hardcode_direct=no
11949	hardcode_direct_absolute=no
11950	;;
11951      esac
11952
11953      if test yes = "$GCC"; then
11954	case $host_os in aix4.[012]|aix4.[012].*)
11955	# We only want to do this on AIX 4.2 and lower, the check
11956	# below for broken collect2 doesn't work under 4.3+
11957	  collect2name=`$CC -print-prog-name=collect2`
11958	  if test -f "$collect2name" &&
11959	   strings "$collect2name" | $GREP resolve_lib_name >/dev/null
11960	  then
11961	  # We have reworked collect2
11962	  :
11963	  else
11964	  # We have old collect2
11965	  hardcode_direct=unsupported
11966	  # It fails to find uninstalled libraries when the uninstalled
11967	  # path is not listed in the libpath.  Setting hardcode_minus_L
11968	  # to unsupported forces relinking
11969	  hardcode_minus_L=yes
11970	  hardcode_libdir_flag_spec='-L$libdir'
11971	  hardcode_libdir_separator=
11972	  fi
11973	  ;;
11974	esac
11975	shared_flag='-shared'
11976	if test yes = "$aix_use_runtimelinking"; then
11977	  shared_flag="$shared_flag "'$wl-G'
11978	fi
11979	# Need to ensure runtime linking is disabled for the traditional
11980	# shared library, or the linker may eventually find shared libraries
11981	# /with/ Import File - we do not want to mix them.
11982	shared_flag_aix='-shared'
11983	shared_flag_svr4='-shared $wl-G'
11984      else
11985	# not using gcc
11986	if test ia64 = "$host_cpu"; then
11987	# VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
11988	# chokes on -Wl,-G. The following line is correct:
11989	  shared_flag='-G'
11990	else
11991	  if test yes = "$aix_use_runtimelinking"; then
11992	    shared_flag='$wl-G'
11993	  else
11994	    shared_flag='$wl-bM:SRE'
11995	  fi
11996	  shared_flag_aix='$wl-bM:SRE'
11997	  shared_flag_svr4='$wl-G'
11998	fi
11999      fi
12000
12001      export_dynamic_flag_spec='$wl-bexpall'
12002      # It seems that -bexpall does not export symbols beginning with
12003      # underscore (_), so it is better to generate a list of symbols to export.
12004      always_export_symbols=yes
12005      if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then
12006	# Warning - without using the other runtime loading flags (-brtl),
12007	# -berok will link without error, but may produce a broken library.
12008	allow_undefined_flag='-berok'
12009        # Determine the default libpath from the value encoded in an
12010        # empty executable.
12011        if test set = "${lt_cv_aix_libpath+set}"; then
12012  aix_libpath=$lt_cv_aix_libpath
12013else
12014  if ${lt_cv_aix_libpath_+:} false; then :
12015  $as_echo_n "(cached) " >&6
12016else
12017  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12018/* end confdefs.h.  */
12019
12020int
12021main ()
12022{
12023
12024  ;
12025  return 0;
12026}
12027_ACEOF
12028if ac_fn_c_try_link "$LINENO"; then :
12029
12030  lt_aix_libpath_sed='
12031      /Import File Strings/,/^$/ {
12032	  /^0/ {
12033	      s/^0  *\([^ ]*\) *$/\1/
12034	      p
12035	  }
12036      }'
12037  lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
12038  # Check for a 64-bit object if we didn't find anything.
12039  if test -z "$lt_cv_aix_libpath_"; then
12040    lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
12041  fi
12042fi
12043rm -f core conftest.err conftest.$ac_objext \
12044    conftest$ac_exeext conftest.$ac_ext
12045  if test -z "$lt_cv_aix_libpath_"; then
12046    lt_cv_aix_libpath_=/usr/lib:/lib
12047  fi
12048
12049fi
12050
12051  aix_libpath=$lt_cv_aix_libpath_
12052fi
12053
12054        hardcode_libdir_flag_spec='$wl-blibpath:$libdir:'"$aix_libpath"
12055        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
12056      else
12057	if test ia64 = "$host_cpu"; then
12058	  hardcode_libdir_flag_spec='$wl-R $libdir:/usr/lib:/lib'
12059	  allow_undefined_flag="-z nodefs"
12060	  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"
12061	else
12062	 # Determine the default libpath from the value encoded in an
12063	 # empty executable.
12064	 if test set = "${lt_cv_aix_libpath+set}"; then
12065  aix_libpath=$lt_cv_aix_libpath
12066else
12067  if ${lt_cv_aix_libpath_+:} false; then :
12068  $as_echo_n "(cached) " >&6
12069else
12070  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12071/* end confdefs.h.  */
12072
12073int
12074main ()
12075{
12076
12077  ;
12078  return 0;
12079}
12080_ACEOF
12081if ac_fn_c_try_link "$LINENO"; then :
12082
12083  lt_aix_libpath_sed='
12084      /Import File Strings/,/^$/ {
12085	  /^0/ {
12086	      s/^0  *\([^ ]*\) *$/\1/
12087	      p
12088	  }
12089      }'
12090  lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
12091  # Check for a 64-bit object if we didn't find anything.
12092  if test -z "$lt_cv_aix_libpath_"; then
12093    lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
12094  fi
12095fi
12096rm -f core conftest.err conftest.$ac_objext \
12097    conftest$ac_exeext conftest.$ac_ext
12098  if test -z "$lt_cv_aix_libpath_"; then
12099    lt_cv_aix_libpath_=/usr/lib:/lib
12100  fi
12101
12102fi
12103
12104  aix_libpath=$lt_cv_aix_libpath_
12105fi
12106
12107	 hardcode_libdir_flag_spec='$wl-blibpath:$libdir:'"$aix_libpath"
12108	  # Warning - without using the other run time loading flags,
12109	  # -berok will link without error, but may produce a broken library.
12110	  no_undefined_flag=' $wl-bernotok'
12111	  allow_undefined_flag=' $wl-berok'
12112	  if test yes = "$with_gnu_ld"; then
12113	    # We only use this code for GNU lds that support --whole-archive.
12114	    whole_archive_flag_spec='$wl--whole-archive$convenience $wl--no-whole-archive'
12115	  else
12116	    # Exported symbols can be pulled into shared objects from archives
12117	    whole_archive_flag_spec='$convenience'
12118	  fi
12119	  archive_cmds_need_lc=yes
12120	  archive_expsym_cmds='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d'
12121	  # -brtl affects multiple linker settings, -berok does not and is overridden later
12122	  compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([, ]\\)%-berok\\1%g"`'
12123	  if test svr4 != "$with_aix_soname"; then
12124	    # This is similar to how AIX traditionally builds its shared libraries.
12125	    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'
12126	  fi
12127	  if test aix != "$with_aix_soname"; then
12128	    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'
12129	  else
12130	    # used by -dlpreopen to get the symbols
12131	    archive_expsym_cmds="$archive_expsym_cmds"'~$MV  $output_objdir/$realname.d/$soname $output_objdir'
12132	  fi
12133	  archive_expsym_cmds="$archive_expsym_cmds"'~$RM -r $output_objdir/$realname.d'
12134	fi
12135      fi
12136      ;;
12137
12138    amigaos*)
12139      case $host_cpu in
12140      powerpc)
12141            # see comment about AmigaOS4 .so support
12142            archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
12143            archive_expsym_cmds=''
12144        ;;
12145      m68k)
12146            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)'
12147            hardcode_libdir_flag_spec='-L$libdir'
12148            hardcode_minus_L=yes
12149        ;;
12150      esac
12151      ;;
12152
12153    bsdi[45]*)
12154      export_dynamic_flag_spec=-rdynamic
12155      ;;
12156
12157    cygwin* | mingw* | pw32* | cegcc*)
12158      # When not using gcc, we currently assume that we are using
12159      # Microsoft Visual C++.
12160      # hardcode_libdir_flag_spec is actually meaningless, as there is
12161      # no search path for DLLs.
12162      case $cc_basename in
12163      cl*)
12164	# Native MSVC
12165	hardcode_libdir_flag_spec=' '
12166	allow_undefined_flag=unsupported
12167	always_export_symbols=yes
12168	file_list_spec='@'
12169	# Tell ltmain to make .lib files, not .a files.
12170	libext=lib
12171	# Tell ltmain to make .dll files, not .so files.
12172	shrext_cmds=.dll
12173	# FIXME: Setting linknames here is a bad hack.
12174	archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames='
12175	archive_expsym_cmds='if   test DEF = "`$SED -n     -e '\''s/^[	 ]*//'\''     -e '\''/^\(;.*\)*$/d'\''     -e '\''s/^\(EXPORTS\|LIBRARY\)\([	 ].*\)*$/DEF/p'\''     -e q     $export_symbols`" ; then
12176            cp "$export_symbols" "$output_objdir/$soname.def";
12177            echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp";
12178          else
12179            $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp;
12180          fi~
12181          $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
12182          linknames='
12183	# The linker will not automatically build a static lib if we build a DLL.
12184	# _LT_TAGVAR(old_archive_from_new_cmds, )='true'
12185	enable_shared_with_static_runtimes=yes
12186	exclude_expsyms='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
12187	export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
12188	# Don't use ranlib
12189	old_postinstall_cmds='chmod 644 $oldlib'
12190	postlink_cmds='lt_outputfile="@OUTPUT@"~
12191          lt_tool_outputfile="@TOOL_OUTPUT@"~
12192          case $lt_outputfile in
12193            *.exe|*.EXE) ;;
12194            *)
12195              lt_outputfile=$lt_outputfile.exe
12196              lt_tool_outputfile=$lt_tool_outputfile.exe
12197              ;;
12198          esac~
12199          if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then
12200            $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
12201            $RM "$lt_outputfile.manifest";
12202          fi'
12203	;;
12204      *)
12205	# Assume MSVC wrapper
12206	hardcode_libdir_flag_spec=' '
12207	allow_undefined_flag=unsupported
12208	# Tell ltmain to make .lib files, not .a files.
12209	libext=lib
12210	# Tell ltmain to make .dll files, not .so files.
12211	shrext_cmds=.dll
12212	# FIXME: Setting linknames here is a bad hack.
12213	archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
12214	# The linker will automatically build a .lib file if we build a DLL.
12215	old_archive_from_new_cmds='true'
12216	# FIXME: Should let the user specify the lib program.
12217	old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
12218	enable_shared_with_static_runtimes=yes
12219	;;
12220      esac
12221      ;;
12222
12223    darwin* | rhapsody*)
12224
12225
12226  archive_cmds_need_lc=no
12227  hardcode_direct=no
12228  hardcode_automatic=yes
12229  hardcode_shlibpath_var=unsupported
12230  if test yes = "$lt_cv_ld_force_load"; then
12231    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\"`'
12232
12233  else
12234    whole_archive_flag_spec=''
12235  fi
12236  link_all_deplibs=yes
12237  allow_undefined_flag=$_lt_dar_allow_undefined
12238  case $cc_basename in
12239     ifort*|nagfor*) _lt_dar_can_shared=yes ;;
12240     *) _lt_dar_can_shared=$GCC ;;
12241  esac
12242  if test yes = "$_lt_dar_can_shared"; then
12243    output_verbose_link_cmd=func_echo_all
12244    archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil"
12245    module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil"
12246    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"
12247    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"
12248
12249  else
12250  ld_shlibs=no
12251  fi
12252
12253      ;;
12254
12255    dgux*)
12256      archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12257      hardcode_libdir_flag_spec='-L$libdir'
12258      hardcode_shlibpath_var=no
12259      ;;
12260
12261    # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
12262    # support.  Future versions do this automatically, but an explicit c++rt0.o
12263    # does not break anything, and helps significantly (at the cost of a little
12264    # extra space).
12265    freebsd2.2*)
12266      archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
12267      hardcode_libdir_flag_spec='-R$libdir'
12268      hardcode_direct=yes
12269      hardcode_shlibpath_var=no
12270      ;;
12271
12272    # Unfortunately, older versions of FreeBSD 2 do not have this feature.
12273    freebsd2.*)
12274      archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
12275      hardcode_direct=yes
12276      hardcode_minus_L=yes
12277      hardcode_shlibpath_var=no
12278      ;;
12279
12280    # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
12281    freebsd* | dragonfly*)
12282      archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
12283      hardcode_libdir_flag_spec='-R$libdir'
12284      hardcode_direct=yes
12285      hardcode_shlibpath_var=no
12286      ;;
12287
12288    hpux9*)
12289      if test yes = "$GCC"; then
12290	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'
12291      else
12292	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'
12293      fi
12294      hardcode_libdir_flag_spec='$wl+b $wl$libdir'
12295      hardcode_libdir_separator=:
12296      hardcode_direct=yes
12297
12298      # hardcode_minus_L: Not really in the search PATH,
12299      # but as the default location of the library.
12300      hardcode_minus_L=yes
12301      export_dynamic_flag_spec='$wl-E'
12302      ;;
12303
12304    hpux10*)
12305      if test yes,no = "$GCC,$with_gnu_ld"; then
12306	archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
12307      else
12308	archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
12309      fi
12310      if test no = "$with_gnu_ld"; then
12311	hardcode_libdir_flag_spec='$wl+b $wl$libdir'
12312	hardcode_libdir_separator=:
12313	hardcode_direct=yes
12314	hardcode_direct_absolute=yes
12315	export_dynamic_flag_spec='$wl-E'
12316	# hardcode_minus_L: Not really in the search PATH,
12317	# but as the default location of the library.
12318	hardcode_minus_L=yes
12319      fi
12320      ;;
12321
12322    hpux11*)
12323      if test yes,no = "$GCC,$with_gnu_ld"; then
12324	case $host_cpu in
12325	hppa*64*)
12326	  archive_cmds='$CC -shared $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
12327	  ;;
12328	ia64*)
12329	  archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
12330	  ;;
12331	*)
12332	  archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
12333	  ;;
12334	esac
12335      else
12336	case $host_cpu in
12337	hppa*64*)
12338	  archive_cmds='$CC -b $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
12339	  ;;
12340	ia64*)
12341	  archive_cmds='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
12342	  ;;
12343	*)
12344
12345	  # Older versions of the 11.00 compiler do not understand -b yet
12346	  # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
12347	  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5
12348$as_echo_n "checking if $CC understands -b... " >&6; }
12349if ${lt_cv_prog_compiler__b+:} false; then :
12350  $as_echo_n "(cached) " >&6
12351else
12352  lt_cv_prog_compiler__b=no
12353   save_LDFLAGS=$LDFLAGS
12354   LDFLAGS="$LDFLAGS -b"
12355   echo "$lt_simple_link_test_code" > conftest.$ac_ext
12356   if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
12357     # The linker can only warn and ignore the option if not recognized
12358     # So say no if there are warnings
12359     if test -s conftest.err; then
12360       # Append any errors to the config.log.
12361       cat conftest.err 1>&5
12362       $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
12363       $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
12364       if diff conftest.exp conftest.er2 >/dev/null; then
12365         lt_cv_prog_compiler__b=yes
12366       fi
12367     else
12368       lt_cv_prog_compiler__b=yes
12369     fi
12370   fi
12371   $RM -r conftest*
12372   LDFLAGS=$save_LDFLAGS
12373
12374fi
12375{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5
12376$as_echo "$lt_cv_prog_compiler__b" >&6; }
12377
12378if test yes = "$lt_cv_prog_compiler__b"; then
12379    archive_cmds='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
12380else
12381    archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
12382fi
12383
12384	  ;;
12385	esac
12386      fi
12387      if test no = "$with_gnu_ld"; then
12388	hardcode_libdir_flag_spec='$wl+b $wl$libdir'
12389	hardcode_libdir_separator=:
12390
12391	case $host_cpu in
12392	hppa*64*|ia64*)
12393	  hardcode_direct=no
12394	  hardcode_shlibpath_var=no
12395	  ;;
12396	*)
12397	  hardcode_direct=yes
12398	  hardcode_direct_absolute=yes
12399	  export_dynamic_flag_spec='$wl-E'
12400
12401	  # hardcode_minus_L: Not really in the search PATH,
12402	  # but as the default location of the library.
12403	  hardcode_minus_L=yes
12404	  ;;
12405	esac
12406      fi
12407      ;;
12408
12409    irix5* | irix6* | nonstopux*)
12410      if test yes = "$GCC"; then
12411	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'
12412	# Try to use the -exported_symbol ld option, if it does not
12413	# work, assume that -exports_file does not work either and
12414	# implicitly export all symbols.
12415	# This should be the same for all languages, so no per-tag cache variable.
12416	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5
12417$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; }
12418if ${lt_cv_irix_exported_symbol+:} false; then :
12419  $as_echo_n "(cached) " >&6
12420else
12421  save_LDFLAGS=$LDFLAGS
12422	   LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null"
12423	   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12424/* end confdefs.h.  */
12425int foo (void) { return 0; }
12426_ACEOF
12427if ac_fn_c_try_link "$LINENO"; then :
12428  lt_cv_irix_exported_symbol=yes
12429else
12430  lt_cv_irix_exported_symbol=no
12431fi
12432rm -f core conftest.err conftest.$ac_objext \
12433    conftest$ac_exeext conftest.$ac_ext
12434           LDFLAGS=$save_LDFLAGS
12435fi
12436{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5
12437$as_echo "$lt_cv_irix_exported_symbol" >&6; }
12438	if test yes = "$lt_cv_irix_exported_symbol"; then
12439          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'
12440	fi
12441      else
12442	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'
12443	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'
12444      fi
12445      archive_cmds_need_lc='no'
12446      hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
12447      hardcode_libdir_separator=:
12448      inherit_rpath=yes
12449      link_all_deplibs=yes
12450      ;;
12451
12452    linux*)
12453      case $cc_basename in
12454      tcc*)
12455	# Fabrice Bellard et al's Tiny C Compiler
12456	ld_shlibs=yes
12457	archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
12458	;;
12459      esac
12460      ;;
12461
12462    netbsd*)
12463      if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
12464	archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'  # a.out
12465      else
12466	archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags'      # ELF
12467      fi
12468      hardcode_libdir_flag_spec='-R$libdir'
12469      hardcode_direct=yes
12470      hardcode_shlibpath_var=no
12471      ;;
12472
12473    newsos6)
12474      archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12475      hardcode_direct=yes
12476      hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
12477      hardcode_libdir_separator=:
12478      hardcode_shlibpath_var=no
12479      ;;
12480
12481    *nto* | *qnx*)
12482      ;;
12483
12484    openbsd* | bitrig*)
12485      if test -f /usr/libexec/ld.so; then
12486	hardcode_direct=yes
12487	hardcode_shlibpath_var=no
12488	hardcode_direct_absolute=yes
12489	if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
12490	  archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
12491	  archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols'
12492	  hardcode_libdir_flag_spec='$wl-rpath,$libdir'
12493	  export_dynamic_flag_spec='$wl-E'
12494	else
12495	  archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
12496	  hardcode_libdir_flag_spec='$wl-rpath,$libdir'
12497	fi
12498      else
12499	ld_shlibs=no
12500      fi
12501      ;;
12502
12503    os2*)
12504      hardcode_libdir_flag_spec='-L$libdir'
12505      hardcode_minus_L=yes
12506      allow_undefined_flag=unsupported
12507      shrext_cmds=.dll
12508      archive_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
12509	$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
12510	$ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
12511	$ECHO EXPORTS >> $output_objdir/$libname.def~
12512	emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
12513	$CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
12514	emximp -o $lib $output_objdir/$libname.def'
12515      archive_expsym_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
12516	$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
12517	$ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
12518	$ECHO EXPORTS >> $output_objdir/$libname.def~
12519	prefix_cmds="$SED"~
12520	if test EXPORTS = "`$SED 1q $export_symbols`"; then
12521	  prefix_cmds="$prefix_cmds -e 1d";
12522	fi~
12523	prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
12524	cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
12525	$CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
12526	emximp -o $lib $output_objdir/$libname.def'
12527      old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
12528      enable_shared_with_static_runtimes=yes
12529      ;;
12530
12531    osf3*)
12532      if test yes = "$GCC"; then
12533	allow_undefined_flag=' $wl-expect_unresolved $wl\*'
12534	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'
12535      else
12536	allow_undefined_flag=' -expect_unresolved \*'
12537	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'
12538      fi
12539      archive_cmds_need_lc='no'
12540      hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
12541      hardcode_libdir_separator=:
12542      ;;
12543
12544    osf4* | osf5*)	# as osf3* with the addition of -msym flag
12545      if test yes = "$GCC"; then
12546	allow_undefined_flag=' $wl-expect_unresolved $wl\*'
12547	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'
12548	hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
12549      else
12550	allow_undefined_flag=' -expect_unresolved \*'
12551	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'
12552	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~
12553          $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'
12554
12555	# Both c and cxx compiler support -rpath directly
12556	hardcode_libdir_flag_spec='-rpath $libdir'
12557      fi
12558      archive_cmds_need_lc='no'
12559      hardcode_libdir_separator=:
12560      ;;
12561
12562    solaris*)
12563      no_undefined_flag=' -z defs'
12564      if test yes = "$GCC"; then
12565	wlarc='$wl'
12566	archive_cmds='$CC -shared $pic_flag $wl-z ${wl}text $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
12567	archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
12568          $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'
12569      else
12570	case `$CC -V 2>&1` in
12571	*"Compilers 5.0"*)
12572	  wlarc=''
12573	  archive_cmds='$LD -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $linker_flags'
12574	  archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
12575            $LD -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
12576	  ;;
12577	*)
12578	  wlarc='$wl'
12579	  archive_cmds='$CC -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $compiler_flags'
12580	  archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
12581            $CC -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
12582	  ;;
12583	esac
12584      fi
12585      hardcode_libdir_flag_spec='-R$libdir'
12586      hardcode_shlibpath_var=no
12587      case $host_os in
12588      solaris2.[0-5] | solaris2.[0-5].*) ;;
12589      *)
12590	# The compiler driver will combine and reorder linker options,
12591	# but understands '-z linker_flag'.  GCC discards it without '$wl',
12592	# but is careful enough not to reorder.
12593	# Supported since Solaris 2.6 (maybe 2.5.1?)
12594	if test yes = "$GCC"; then
12595	  whole_archive_flag_spec='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract'
12596	else
12597	  whole_archive_flag_spec='-z allextract$convenience -z defaultextract'
12598	fi
12599	;;
12600      esac
12601      link_all_deplibs=yes
12602      ;;
12603
12604    sunos4*)
12605      if test sequent = "$host_vendor"; then
12606	# Use $CC to link under sequent, because it throws in some extra .o
12607	# files that make .init and .fini sections work.
12608	archive_cmds='$CC -G $wl-h $soname -o $lib $libobjs $deplibs $compiler_flags'
12609      else
12610	archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
12611      fi
12612      hardcode_libdir_flag_spec='-L$libdir'
12613      hardcode_direct=yes
12614      hardcode_minus_L=yes
12615      hardcode_shlibpath_var=no
12616      ;;
12617
12618    sysv4)
12619      case $host_vendor in
12620	sni)
12621	  archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12622	  hardcode_direct=yes # is this really true???
12623	;;
12624	siemens)
12625	  ## LD is ld it makes a PLAMLIB
12626	  ## CC just makes a GrossModule.
12627	  archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
12628	  reload_cmds='$CC -r -o $output$reload_objs'
12629	  hardcode_direct=no
12630        ;;
12631	motorola)
12632	  archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12633	  hardcode_direct=no #Motorola manual says yes, but my tests say they lie
12634	;;
12635      esac
12636      runpath_var='LD_RUN_PATH'
12637      hardcode_shlibpath_var=no
12638      ;;
12639
12640    sysv4.3*)
12641      archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12642      hardcode_shlibpath_var=no
12643      export_dynamic_flag_spec='-Bexport'
12644      ;;
12645
12646    sysv4*MP*)
12647      if test -d /usr/nec; then
12648	archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12649	hardcode_shlibpath_var=no
12650	runpath_var=LD_RUN_PATH
12651	hardcode_runpath_var=yes
12652	ld_shlibs=yes
12653      fi
12654      ;;
12655
12656    sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
12657      no_undefined_flag='$wl-z,text'
12658      archive_cmds_need_lc=no
12659      hardcode_shlibpath_var=no
12660      runpath_var='LD_RUN_PATH'
12661
12662      if test yes = "$GCC"; then
12663	archive_cmds='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12664	archive_expsym_cmds='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12665      else
12666	archive_cmds='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12667	archive_expsym_cmds='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12668      fi
12669      ;;
12670
12671    sysv5* | sco3.2v5* | sco5v6*)
12672      # Note: We CANNOT use -z defs as we might desire, because we do not
12673      # link with -lc, and that would cause any symbols used from libc to
12674      # always be unresolved, which means just about no library would
12675      # ever link correctly.  If we're not using GNU ld we use -z text
12676      # though, which does catch some bad symbols but isn't as heavy-handed
12677      # as -z defs.
12678      no_undefined_flag='$wl-z,text'
12679      allow_undefined_flag='$wl-z,nodefs'
12680      archive_cmds_need_lc=no
12681      hardcode_shlibpath_var=no
12682      hardcode_libdir_flag_spec='$wl-R,$libdir'
12683      hardcode_libdir_separator=':'
12684      link_all_deplibs=yes
12685      export_dynamic_flag_spec='$wl-Bexport'
12686      runpath_var='LD_RUN_PATH'
12687
12688      if test yes = "$GCC"; then
12689	archive_cmds='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12690	archive_expsym_cmds='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12691      else
12692	archive_cmds='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12693	archive_expsym_cmds='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12694      fi
12695      ;;
12696
12697    uts4*)
12698      archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12699      hardcode_libdir_flag_spec='-L$libdir'
12700      hardcode_shlibpath_var=no
12701      ;;
12702
12703    *)
12704      ld_shlibs=no
12705      ;;
12706    esac
12707
12708    if test sni = "$host_vendor"; then
12709      case $host in
12710      sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
12711	export_dynamic_flag_spec='$wl-Blargedynsym'
12712	;;
12713      esac
12714    fi
12715  fi
12716
12717{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5
12718$as_echo "$ld_shlibs" >&6; }
12719test no = "$ld_shlibs" && can_build_shared=no
12720
12721with_gnu_ld=$with_gnu_ld
12722
12723
12724
12725
12726
12727
12728
12729
12730
12731
12732
12733
12734
12735
12736
12737#
12738# Do we need to explicitly link libc?
12739#
12740case "x$archive_cmds_need_lc" in
12741x|xyes)
12742  # Assume -lc should be added
12743  archive_cmds_need_lc=yes
12744
12745  if test yes,yes = "$GCC,$enable_shared"; then
12746    case $archive_cmds in
12747    *'~'*)
12748      # FIXME: we may have to deal with multi-command sequences.
12749      ;;
12750    '$CC '*)
12751      # Test whether the compiler implicitly links with -lc since on some
12752      # systems, -lgcc has to come before -lc. If gcc already passes -lc
12753      # to ld, don't add -lc before -lgcc.
12754      { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5
12755$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; }
12756if ${lt_cv_archive_cmds_need_lc+:} false; then :
12757  $as_echo_n "(cached) " >&6
12758else
12759  $RM conftest*
12760	echo "$lt_simple_compile_test_code" > conftest.$ac_ext
12761
12762	if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
12763  (eval $ac_compile) 2>&5
12764  ac_status=$?
12765  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
12766  test $ac_status = 0; } 2>conftest.err; then
12767	  soname=conftest
12768	  lib=conftest
12769	  libobjs=conftest.$ac_objext
12770	  deplibs=
12771	  wl=$lt_prog_compiler_wl
12772	  pic_flag=$lt_prog_compiler_pic
12773	  compiler_flags=-v
12774	  linker_flags=-v
12775	  verstring=
12776	  output_objdir=.
12777	  libname=conftest
12778	  lt_save_allow_undefined_flag=$allow_undefined_flag
12779	  allow_undefined_flag=
12780	  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5
12781  (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5
12782  ac_status=$?
12783  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
12784  test $ac_status = 0; }
12785	  then
12786	    lt_cv_archive_cmds_need_lc=no
12787	  else
12788	    lt_cv_archive_cmds_need_lc=yes
12789	  fi
12790	  allow_undefined_flag=$lt_save_allow_undefined_flag
12791	else
12792	  cat conftest.err 1>&5
12793	fi
12794	$RM conftest*
12795
12796fi
12797{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5
12798$as_echo "$lt_cv_archive_cmds_need_lc" >&6; }
12799      archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc
12800      ;;
12801    esac
12802  fi
12803  ;;
12804esac
12805
12806
12807
12808
12809
12810
12811
12812
12813
12814
12815
12816
12817
12818
12819
12820
12821
12822
12823
12824
12825
12826
12827
12828
12829
12830
12831
12832
12833
12834
12835
12836
12837
12838
12839
12840
12841
12842
12843
12844
12845
12846
12847
12848
12849
12850
12851
12852
12853
12854
12855
12856
12857
12858
12859
12860
12861
12862
12863
12864
12865
12866
12867
12868
12869
12870
12871
12872
12873
12874
12875
12876
12877
12878
12879
12880
12881
12882
12883
12884
12885
12886
12887
12888
12889
12890
12891
12892
12893
12894
12895
12896
12897
12898
12899
12900
12901
12902
12903
12904
12905
12906
12907
12908
12909
12910
12911
12912
12913
12914
12915
12916
12917
12918
12919
12920
12921
12922
12923
12924
12925
12926
12927
12928
12929
12930
12931
12932
12933
12934
12935
12936
12937
12938
12939
12940
12941
12942
12943
12944
12945
12946
12947
12948
12949
12950
12951
12952
12953
12954
12955
12956
12957  { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5
12958$as_echo_n "checking dynamic linker characteristics... " >&6; }
12959
12960if test yes = "$GCC"; then
12961  case $host_os in
12962    darwin*) lt_awk_arg='/^libraries:/,/LR/' ;;
12963    *) lt_awk_arg='/^libraries:/' ;;
12964  esac
12965  case $host_os in
12966    mingw* | cegcc*) lt_sed_strip_eq='s|=\([A-Za-z]:\)|\1|g' ;;
12967    *) lt_sed_strip_eq='s|=/|/|g' ;;
12968  esac
12969  lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
12970  case $lt_search_path_spec in
12971  *\;*)
12972    # if the path contains ";" then we assume it to be the separator
12973    # otherwise default to the standard path separator (i.e. ":") - it is
12974    # assumed that no part of a normal pathname contains ";" but that should
12975    # okay in the real world where ";" in dirpaths is itself problematic.
12976    lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
12977    ;;
12978  *)
12979    lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
12980    ;;
12981  esac
12982  # Ok, now we have the path, separated by spaces, we can step through it
12983  # and add multilib dir if necessary...
12984  lt_tmp_lt_search_path_spec=
12985  lt_multi_os_dir=/`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
12986  # ...but if some path component already ends with the multilib dir we assume
12987  # that all is fine and trust -print-search-dirs as is (GCC 4.2? or newer).
12988  case "$lt_multi_os_dir; $lt_search_path_spec " in
12989  "/; "* | "/.; "* | "/./; "* | *"$lt_multi_os_dir "* | *"$lt_multi_os_dir/ "*)
12990    lt_multi_os_dir=
12991    ;;
12992  esac
12993  for lt_sys_path in $lt_search_path_spec; do
12994    if test -d "$lt_sys_path$lt_multi_os_dir"; then
12995      lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path$lt_multi_os_dir"
12996    elif test -n "$lt_multi_os_dir"; then
12997      test -d "$lt_sys_path" && \
12998	lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
12999    fi
13000  done
13001  lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
13002BEGIN {RS = " "; FS = "/|\n";} {
13003  lt_foo = "";
13004  lt_count = 0;
13005  for (lt_i = NF; lt_i > 0; lt_i--) {
13006    if ($lt_i != "" && $lt_i != ".") {
13007      if ($lt_i == "..") {
13008        lt_count++;
13009      } else {
13010        if (lt_count == 0) {
13011          lt_foo = "/" $lt_i lt_foo;
13012        } else {
13013          lt_count--;
13014        }
13015      }
13016    }
13017  }
13018  if (lt_foo != "") { lt_freq[lt_foo]++; }
13019  if (lt_freq[lt_foo] == 1) { print lt_foo; }
13020}'`
13021  # AWK program above erroneously prepends '/' to C:/dos/paths
13022  # for these hosts.
13023  case $host_os in
13024    mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
13025      $SED 's|/\([A-Za-z]:\)|\1|g'` ;;
13026  esac
13027  sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
13028else
13029  sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
13030fi
13031library_names_spec=
13032libname_spec='lib$name'
13033soname_spec=
13034shrext_cmds=.so
13035postinstall_cmds=
13036postuninstall_cmds=
13037finish_cmds=
13038finish_eval=
13039shlibpath_var=
13040shlibpath_overrides_runpath=unknown
13041version_type=none
13042dynamic_linker="$host_os ld.so"
13043sys_lib_dlsearch_path_spec="/lib /usr/lib"
13044need_lib_prefix=unknown
13045hardcode_into_libs=no
13046
13047# when you set need_version to no, make sure it does not cause -set_version
13048# flags to be left without arguments
13049need_version=unknown
13050
13051
13052
13053case $host_os in
13054aix3*)
13055  version_type=linux # correct to gnu/linux during the next big refactor
13056  library_names_spec='$libname$release$shared_ext$versuffix $libname.a'
13057  shlibpath_var=LIBPATH
13058
13059  # AIX 3 has no versioning support, so we append a major version to the name.
13060  soname_spec='$libname$release$shared_ext$major'
13061  ;;
13062
13063aix[4-9]*)
13064  version_type=linux # correct to gnu/linux during the next big refactor
13065  need_lib_prefix=no
13066  need_version=no
13067  hardcode_into_libs=yes
13068  if test ia64 = "$host_cpu"; then
13069    # AIX 5 supports IA64
13070    library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext'
13071    shlibpath_var=LD_LIBRARY_PATH
13072  else
13073    # With GCC up to 2.95.x, collect2 would create an import file
13074    # for dependence libraries.  The import file would start with
13075    # the line '#! .'.  This would cause the generated library to
13076    # depend on '.', always an invalid library.  This was fixed in
13077    # development snapshots of GCC prior to 3.0.
13078    case $host_os in
13079      aix4 | aix4.[01] | aix4.[01].*)
13080      if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
13081	   echo ' yes '
13082	   echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then
13083	:
13084      else
13085	can_build_shared=no
13086      fi
13087      ;;
13088    esac
13089    # Using Import Files as archive members, it is possible to support
13090    # filename-based versioning of shared library archives on AIX. While
13091    # this would work for both with and without runtime linking, it will
13092    # prevent static linking of such archives. So we do filename-based
13093    # shared library versioning with .so extension only, which is used
13094    # when both runtime linking and shared linking is enabled.
13095    # Unfortunately, runtime linking may impact performance, so we do
13096    # not want this to be the default eventually. Also, we use the
13097    # versioned .so libs for executables only if there is the -brtl
13098    # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only.
13099    # To allow for filename-based versioning support, we need to create
13100    # libNAME.so.V as an archive file, containing:
13101    # *) an Import File, referring to the versioned filename of the
13102    #    archive as well as the shared archive member, telling the
13103    #    bitwidth (32 or 64) of that shared object, and providing the
13104    #    list of exported symbols of that shared object, eventually
13105    #    decorated with the 'weak' keyword
13106    # *) the shared object with the F_LOADONLY flag set, to really avoid
13107    #    it being seen by the linker.
13108    # At run time we better use the real file rather than another symlink,
13109    # but for link time we create the symlink libNAME.so -> libNAME.so.V
13110
13111    case $with_aix_soname,$aix_use_runtimelinking in
13112    # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct
13113    # soname into executable. Probably we can add versioning support to
13114    # collect2, so additional links can be useful in future.
13115    aix,yes) # traditional libtool
13116      dynamic_linker='AIX unversionable lib.so'
13117      # If using run time linking (on AIX 4.2 or later) use lib<name>.so
13118      # instead of lib<name>.a to let people know that these are not
13119      # typical AIX shared libraries.
13120      library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13121      ;;
13122    aix,no) # traditional AIX only
13123      dynamic_linker='AIX lib.a(lib.so.V)'
13124      # We preserve .a as extension for shared libraries through AIX4.2
13125      # and later when we are not doing run time linking.
13126      library_names_spec='$libname$release.a $libname.a'
13127      soname_spec='$libname$release$shared_ext$major'
13128      ;;
13129    svr4,*) # full svr4 only
13130      dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o)"
13131      library_names_spec='$libname$release$shared_ext$major $libname$shared_ext'
13132      # We do not specify a path in Import Files, so LIBPATH fires.
13133      shlibpath_overrides_runpath=yes
13134      ;;
13135    *,yes) # both, prefer svr4
13136      dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o), lib.a(lib.so.V)"
13137      library_names_spec='$libname$release$shared_ext$major $libname$shared_ext'
13138      # unpreferred sharedlib libNAME.a needs extra handling
13139      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"'
13140      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"'
13141      # We do not specify a path in Import Files, so LIBPATH fires.
13142      shlibpath_overrides_runpath=yes
13143      ;;
13144    *,no) # both, prefer aix
13145      dynamic_linker="AIX lib.a(lib.so.V), lib.so.V($shared_archive_member_spec.o)"
13146      library_names_spec='$libname$release.a $libname.a'
13147      soname_spec='$libname$release$shared_ext$major'
13148      # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling
13149      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)'
13150      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"'
13151      ;;
13152    esac
13153    shlibpath_var=LIBPATH
13154  fi
13155  ;;
13156
13157amigaos*)
13158  case $host_cpu in
13159  powerpc)
13160    # Since July 2007 AmigaOS4 officially supports .so libraries.
13161    # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
13162    library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13163    ;;
13164  m68k)
13165    library_names_spec='$libname.ixlibrary $libname.a'
13166    # Create ${libname}_ixlibrary.a entries in /sys/libs.
13167    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'
13168    ;;
13169  esac
13170  ;;
13171
13172beos*)
13173  library_names_spec='$libname$shared_ext'
13174  dynamic_linker="$host_os ld.so"
13175  shlibpath_var=LIBRARY_PATH
13176  ;;
13177
13178bsdi[45]*)
13179  version_type=linux # correct to gnu/linux during the next big refactor
13180  need_version=no
13181  library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13182  soname_spec='$libname$release$shared_ext$major'
13183  finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
13184  shlibpath_var=LD_LIBRARY_PATH
13185  sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
13186  sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
13187  # the default ld.so.conf also contains /usr/contrib/lib and
13188  # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
13189  # libtool to hard-code these into programs
13190  ;;
13191
13192cygwin* | mingw* | pw32* | cegcc*)
13193  version_type=windows
13194  shrext_cmds=.dll
13195  need_version=no
13196  need_lib_prefix=no
13197
13198  case $GCC,$cc_basename in
13199  yes,*)
13200    # gcc
13201    library_names_spec='$libname.dll.a'
13202    # DLL is installed to $(libdir)/../bin by postinstall_cmds
13203    postinstall_cmds='base_file=`basename \$file`~
13204      dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~
13205      dldir=$destdir/`dirname \$dlpath`~
13206      test -d \$dldir || mkdir -p \$dldir~
13207      $install_prog $dir/$dlname \$dldir/$dlname~
13208      chmod a+x \$dldir/$dlname~
13209      if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
13210        eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
13211      fi'
13212    postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
13213      dlpath=$dir/\$dldll~
13214       $RM \$dlpath'
13215    shlibpath_overrides_runpath=yes
13216
13217    case $host_os in
13218    cygwin*)
13219      # Cygwin DLLs use 'cyg' prefix rather than 'lib'
13220      soname_spec='`echo $libname | sed -e 's/^lib/cyg/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
13221
13222      sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"
13223      ;;
13224    mingw* | cegcc*)
13225      # MinGW DLLs use traditional 'lib' prefix
13226      soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
13227      ;;
13228    pw32*)
13229      # pw32 DLLs use 'pw' prefix rather than 'lib'
13230      library_names_spec='`echo $libname | sed -e 's/^lib/pw/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
13231      ;;
13232    esac
13233    dynamic_linker='Win32 ld.exe'
13234    ;;
13235
13236  *,cl*)
13237    # Native MSVC
13238    libname_spec='$name'
13239    soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
13240    library_names_spec='$libname.dll.lib'
13241
13242    case $build_os in
13243    mingw*)
13244      sys_lib_search_path_spec=
13245      lt_save_ifs=$IFS
13246      IFS=';'
13247      for lt_path in $LIB
13248      do
13249        IFS=$lt_save_ifs
13250        # Let DOS variable expansion print the short 8.3 style file name.
13251        lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
13252        sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
13253      done
13254      IFS=$lt_save_ifs
13255      # Convert to MSYS style.
13256      sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'`
13257      ;;
13258    cygwin*)
13259      # Convert to unix form, then to dos form, then back to unix form
13260      # but this time dos style (no spaces!) so that the unix form looks
13261      # like /cygdrive/c/PROGRA~1:/cygdr...
13262      sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
13263      sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
13264      sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
13265      ;;
13266    *)
13267      sys_lib_search_path_spec=$LIB
13268      if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
13269        # It is most probably a Windows format PATH.
13270        sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
13271      else
13272        sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
13273      fi
13274      # FIXME: find the short name or the path components, as spaces are
13275      # common. (e.g. "Program Files" -> "PROGRA~1")
13276      ;;
13277    esac
13278
13279    # DLL is installed to $(libdir)/../bin by postinstall_cmds
13280    postinstall_cmds='base_file=`basename \$file`~
13281      dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~
13282      dldir=$destdir/`dirname \$dlpath`~
13283      test -d \$dldir || mkdir -p \$dldir~
13284      $install_prog $dir/$dlname \$dldir/$dlname'
13285    postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
13286      dlpath=$dir/\$dldll~
13287       $RM \$dlpath'
13288    shlibpath_overrides_runpath=yes
13289    dynamic_linker='Win32 link.exe'
13290    ;;
13291
13292  *)
13293    # Assume MSVC wrapper
13294    library_names_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext $libname.lib'
13295    dynamic_linker='Win32 ld.exe'
13296    ;;
13297  esac
13298  # FIXME: first we should search . and the directory the executable is in
13299  shlibpath_var=PATH
13300  ;;
13301
13302darwin* | rhapsody*)
13303  dynamic_linker="$host_os dyld"
13304  version_type=darwin
13305  need_lib_prefix=no
13306  need_version=no
13307  library_names_spec='$libname$release$major$shared_ext $libname$shared_ext'
13308  soname_spec='$libname$release$major$shared_ext'
13309  shlibpath_overrides_runpath=yes
13310  shlibpath_var=DYLD_LIBRARY_PATH
13311  shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
13312
13313  sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"
13314  sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
13315  ;;
13316
13317dgux*)
13318  version_type=linux # correct to gnu/linux during the next big refactor
13319  need_lib_prefix=no
13320  need_version=no
13321  library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13322  soname_spec='$libname$release$shared_ext$major'
13323  shlibpath_var=LD_LIBRARY_PATH
13324  ;;
13325
13326freebsd* | dragonfly*)
13327  # DragonFly does not have aout.  When/if they implement a new
13328  # versioning mechanism, adjust this.
13329  if test -x /usr/bin/objformat; then
13330    objformat=`/usr/bin/objformat`
13331  else
13332    case $host_os in
13333    freebsd[23].*) objformat=aout ;;
13334    *) objformat=elf ;;
13335    esac
13336  fi
13337  version_type=freebsd-$objformat
13338  case $version_type in
13339    freebsd-elf*)
13340      library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13341      soname_spec='$libname$release$shared_ext$major'
13342      need_version=no
13343      need_lib_prefix=no
13344      ;;
13345    freebsd-*)
13346      library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
13347      need_version=yes
13348      ;;
13349  esac
13350  shlibpath_var=LD_LIBRARY_PATH
13351  case $host_os in
13352  freebsd2.*)
13353    shlibpath_overrides_runpath=yes
13354    ;;
13355  freebsd3.[01]* | freebsdelf3.[01]*)
13356    shlibpath_overrides_runpath=yes
13357    hardcode_into_libs=yes
13358    ;;
13359  freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
13360  freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
13361    shlibpath_overrides_runpath=no
13362    hardcode_into_libs=yes
13363    ;;
13364  *) # from 4.6 on, and DragonFly
13365    shlibpath_overrides_runpath=yes
13366    hardcode_into_libs=yes
13367    ;;
13368  esac
13369  ;;
13370
13371haiku*)
13372  version_type=linux # correct to gnu/linux during the next big refactor
13373  need_lib_prefix=no
13374  need_version=no
13375  dynamic_linker="$host_os runtime_loader"
13376  library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13377  soname_spec='$libname$release$shared_ext$major'
13378  shlibpath_var=LIBRARY_PATH
13379  shlibpath_overrides_runpath=no
13380  sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
13381  hardcode_into_libs=yes
13382  ;;
13383
13384hpux9* | hpux10* | hpux11*)
13385  # Give a soname corresponding to the major version so that dld.sl refuses to
13386  # link against other versions.
13387  version_type=sunos
13388  need_lib_prefix=no
13389  need_version=no
13390  case $host_cpu in
13391  ia64*)
13392    shrext_cmds='.so'
13393    hardcode_into_libs=yes
13394    dynamic_linker="$host_os dld.so"
13395    shlibpath_var=LD_LIBRARY_PATH
13396    shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
13397    library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13398    soname_spec='$libname$release$shared_ext$major'
13399    if test 32 = "$HPUX_IA64_MODE"; then
13400      sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
13401      sys_lib_dlsearch_path_spec=/usr/lib/hpux32
13402    else
13403      sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
13404      sys_lib_dlsearch_path_spec=/usr/lib/hpux64
13405    fi
13406    ;;
13407  hppa*64*)
13408    shrext_cmds='.sl'
13409    hardcode_into_libs=yes
13410    dynamic_linker="$host_os dld.sl"
13411    shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
13412    shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
13413    library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13414    soname_spec='$libname$release$shared_ext$major'
13415    sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
13416    sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
13417    ;;
13418  *)
13419    shrext_cmds='.sl'
13420    dynamic_linker="$host_os dld.sl"
13421    shlibpath_var=SHLIB_PATH
13422    shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
13423    library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13424    soname_spec='$libname$release$shared_ext$major'
13425    ;;
13426  esac
13427  # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
13428  postinstall_cmds='chmod 555 $lib'
13429  # or fails outright, so override atomically:
13430  install_override_mode=555
13431  ;;
13432
13433interix[3-9]*)
13434  version_type=linux # correct to gnu/linux during the next big refactor
13435  need_lib_prefix=no
13436  need_version=no
13437  library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13438  soname_spec='$libname$release$shared_ext$major'
13439  dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
13440  shlibpath_var=LD_LIBRARY_PATH
13441  shlibpath_overrides_runpath=no
13442  hardcode_into_libs=yes
13443  ;;
13444
13445irix5* | irix6* | nonstopux*)
13446  case $host_os in
13447    nonstopux*) version_type=nonstopux ;;
13448    *)
13449	if test yes = "$lt_cv_prog_gnu_ld"; then
13450		version_type=linux # correct to gnu/linux during the next big refactor
13451	else
13452		version_type=irix
13453	fi ;;
13454  esac
13455  need_lib_prefix=no
13456  need_version=no
13457  soname_spec='$libname$release$shared_ext$major'
13458  library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext'
13459  case $host_os in
13460  irix5* | nonstopux*)
13461    libsuff= shlibsuff=
13462    ;;
13463  *)
13464    case $LD in # libtool.m4 will add one of these switches to LD
13465    *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
13466      libsuff= shlibsuff= libmagic=32-bit;;
13467    *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
13468      libsuff=32 shlibsuff=N32 libmagic=N32;;
13469    *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
13470      libsuff=64 shlibsuff=64 libmagic=64-bit;;
13471    *) libsuff= shlibsuff= libmagic=never-match;;
13472    esac
13473    ;;
13474  esac
13475  shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
13476  shlibpath_overrides_runpath=no
13477  sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff"
13478  sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff"
13479  hardcode_into_libs=yes
13480  ;;
13481
13482# No shared lib support for Linux oldld, aout, or coff.
13483linux*oldld* | linux*aout* | linux*coff*)
13484  dynamic_linker=no
13485  ;;
13486
13487linux*android*)
13488  version_type=none # Android doesn't support versioned libraries.
13489  need_lib_prefix=no
13490  need_version=no
13491  library_names_spec='$libname$release$shared_ext'
13492  soname_spec='$libname$release$shared_ext'
13493  finish_cmds=
13494  shlibpath_var=LD_LIBRARY_PATH
13495  shlibpath_overrides_runpath=yes
13496
13497  # This implies no fast_install, which is unacceptable.
13498  # Some rework will be needed to allow for fast_install
13499  # before this can be enabled.
13500  hardcode_into_libs=yes
13501
13502  dynamic_linker='Android linker'
13503  # Don't embed -rpath directories since the linker doesn't support them.
13504  hardcode_libdir_flag_spec='-L$libdir'
13505  ;;
13506
13507# This must be glibc/ELF.
13508linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
13509  version_type=linux # correct to gnu/linux during the next big refactor
13510  need_lib_prefix=no
13511  need_version=no
13512  library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13513  soname_spec='$libname$release$shared_ext$major'
13514  finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
13515  shlibpath_var=LD_LIBRARY_PATH
13516  shlibpath_overrides_runpath=no
13517
13518  # Some binutils ld are patched to set DT_RUNPATH
13519  if ${lt_cv_shlibpath_overrides_runpath+:} false; then :
13520  $as_echo_n "(cached) " >&6
13521else
13522  lt_cv_shlibpath_overrides_runpath=no
13523    save_LDFLAGS=$LDFLAGS
13524    save_libdir=$libdir
13525    eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \
13526	 LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\""
13527    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13528/* end confdefs.h.  */
13529
13530int
13531main ()
13532{
13533
13534  ;
13535  return 0;
13536}
13537_ACEOF
13538if ac_fn_c_try_link "$LINENO"; then :
13539  if  ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then :
13540  lt_cv_shlibpath_overrides_runpath=yes
13541fi
13542fi
13543rm -f core conftest.err conftest.$ac_objext \
13544    conftest$ac_exeext conftest.$ac_ext
13545    LDFLAGS=$save_LDFLAGS
13546    libdir=$save_libdir
13547
13548fi
13549
13550  shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
13551
13552  # This implies no fast_install, which is unacceptable.
13553  # Some rework will be needed to allow for fast_install
13554  # before this can be enabled.
13555  hardcode_into_libs=yes
13556
13557  # Ideally, we could use ldconfig to report *all* directores which are
13558  # searched for libraries, however this is still not possible.  Aside from not
13559  # being certain /sbin/ldconfig is available, command
13560  # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64,
13561  # even though it is searched at run-time.  Try to do the best guess by
13562  # appending ld.so.conf contents (and includes) to the search path.
13563  if test -f /etc/ld.so.conf; then
13564    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' ' '`
13565    sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
13566  fi
13567
13568  # We used to test for /lib/ld.so.1 and disable shared libraries on
13569  # powerpc, because MkLinux only supported shared libraries with the
13570  # GNU dynamic linker.  Since this was broken with cross compilers,
13571  # most powerpc-linux boxes support dynamic linking these days and
13572  # people can always --disable-shared, the test was removed, and we
13573  # assume the GNU/Linux dynamic linker is in use.
13574  dynamic_linker='GNU/Linux ld.so'
13575  ;;
13576
13577netbsd*)
13578  version_type=sunos
13579  need_lib_prefix=no
13580  need_version=no
13581  if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
13582    library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
13583    finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
13584    dynamic_linker='NetBSD (a.out) ld.so'
13585  else
13586    library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13587    soname_spec='$libname$release$shared_ext$major'
13588    dynamic_linker='NetBSD ld.elf_so'
13589  fi
13590  shlibpath_var=LD_LIBRARY_PATH
13591  shlibpath_overrides_runpath=yes
13592  hardcode_into_libs=yes
13593  ;;
13594
13595newsos6)
13596  version_type=linux # correct to gnu/linux during the next big refactor
13597  library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13598  shlibpath_var=LD_LIBRARY_PATH
13599  shlibpath_overrides_runpath=yes
13600  ;;
13601
13602*nto* | *qnx*)
13603  version_type=qnx
13604  need_lib_prefix=no
13605  need_version=no
13606  library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13607  soname_spec='$libname$release$shared_ext$major'
13608  shlibpath_var=LD_LIBRARY_PATH
13609  shlibpath_overrides_runpath=no
13610  hardcode_into_libs=yes
13611  dynamic_linker='ldqnx.so'
13612  ;;
13613
13614openbsd* | bitrig*)
13615  version_type=sunos
13616  sys_lib_dlsearch_path_spec=/usr/lib
13617  need_lib_prefix=no
13618  if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
13619    need_version=no
13620  else
13621    need_version=yes
13622  fi
13623  library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
13624  finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
13625  shlibpath_var=LD_LIBRARY_PATH
13626  shlibpath_overrides_runpath=yes
13627  ;;
13628
13629os2*)
13630  libname_spec='$name'
13631  version_type=windows
13632  shrext_cmds=.dll
13633  need_version=no
13634  need_lib_prefix=no
13635  # OS/2 can only load a DLL with a base name of 8 characters or less.
13636  soname_spec='`test -n "$os2dllname" && libname="$os2dllname";
13637    v=$($ECHO $release$versuffix | tr -d .-);
13638    n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _);
13639    $ECHO $n$v`$shared_ext'
13640  library_names_spec='${libname}_dll.$libext'
13641  dynamic_linker='OS/2 ld.exe'
13642  shlibpath_var=BEGINLIBPATH
13643  sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
13644  sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
13645  postinstall_cmds='base_file=`basename \$file`~
13646    dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~
13647    dldir=$destdir/`dirname \$dlpath`~
13648    test -d \$dldir || mkdir -p \$dldir~
13649    $install_prog $dir/$dlname \$dldir/$dlname~
13650    chmod a+x \$dldir/$dlname~
13651    if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
13652      eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
13653    fi'
13654  postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~
13655    dlpath=$dir/\$dldll~
13656    $RM \$dlpath'
13657  ;;
13658
13659osf3* | osf4* | osf5*)
13660  version_type=osf
13661  need_lib_prefix=no
13662  need_version=no
13663  soname_spec='$libname$release$shared_ext$major'
13664  library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13665  shlibpath_var=LD_LIBRARY_PATH
13666  sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
13667  sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
13668  ;;
13669
13670rdos*)
13671  dynamic_linker=no
13672  ;;
13673
13674solaris*)
13675  version_type=linux # correct to gnu/linux during the next big refactor
13676  need_lib_prefix=no
13677  need_version=no
13678  library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13679  soname_spec='$libname$release$shared_ext$major'
13680  shlibpath_var=LD_LIBRARY_PATH
13681  shlibpath_overrides_runpath=yes
13682  hardcode_into_libs=yes
13683  # ldd complains unless libraries are executable
13684  postinstall_cmds='chmod +x $lib'
13685  ;;
13686
13687sunos4*)
13688  version_type=sunos
13689  library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
13690  finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
13691  shlibpath_var=LD_LIBRARY_PATH
13692  shlibpath_overrides_runpath=yes
13693  if test yes = "$with_gnu_ld"; then
13694    need_lib_prefix=no
13695  fi
13696  need_version=yes
13697  ;;
13698
13699sysv4 | sysv4.3*)
13700  version_type=linux # correct to gnu/linux during the next big refactor
13701  library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13702  soname_spec='$libname$release$shared_ext$major'
13703  shlibpath_var=LD_LIBRARY_PATH
13704  case $host_vendor in
13705    sni)
13706      shlibpath_overrides_runpath=no
13707      need_lib_prefix=no
13708      runpath_var=LD_RUN_PATH
13709      ;;
13710    siemens)
13711      need_lib_prefix=no
13712      ;;
13713    motorola)
13714      need_lib_prefix=no
13715      need_version=no
13716      shlibpath_overrides_runpath=no
13717      sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
13718      ;;
13719  esac
13720  ;;
13721
13722sysv4*MP*)
13723  if test -d /usr/nec; then
13724    version_type=linux # correct to gnu/linux during the next big refactor
13725    library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext'
13726    soname_spec='$libname$shared_ext.$major'
13727    shlibpath_var=LD_LIBRARY_PATH
13728  fi
13729  ;;
13730
13731sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
13732  version_type=sco
13733  need_lib_prefix=no
13734  need_version=no
13735  library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext'
13736  soname_spec='$libname$release$shared_ext$major'
13737  shlibpath_var=LD_LIBRARY_PATH
13738  shlibpath_overrides_runpath=yes
13739  hardcode_into_libs=yes
13740  if test yes = "$with_gnu_ld"; then
13741    sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
13742  else
13743    sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
13744    case $host_os in
13745      sco3.2v5*)
13746        sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
13747	;;
13748    esac
13749  fi
13750  sys_lib_dlsearch_path_spec='/usr/lib'
13751  ;;
13752
13753tpf*)
13754  # TPF is a cross-target only.  Preferred cross-host = GNU/Linux.
13755  version_type=linux # correct to gnu/linux during the next big refactor
13756  need_lib_prefix=no
13757  need_version=no
13758  library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13759  shlibpath_var=LD_LIBRARY_PATH
13760  shlibpath_overrides_runpath=no
13761  hardcode_into_libs=yes
13762  ;;
13763
13764uts4*)
13765  version_type=linux # correct to gnu/linux during the next big refactor
13766  library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13767  soname_spec='$libname$release$shared_ext$major'
13768  shlibpath_var=LD_LIBRARY_PATH
13769  ;;
13770
13771*)
13772  dynamic_linker=no
13773  ;;
13774esac
13775{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5
13776$as_echo "$dynamic_linker" >&6; }
13777test no = "$dynamic_linker" && can_build_shared=no
13778
13779variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
13780if test yes = "$GCC"; then
13781  variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
13782fi
13783
13784if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then
13785  sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec
13786fi
13787
13788if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then
13789  sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec
13790fi
13791
13792# remember unaugmented sys_lib_dlsearch_path content for libtool script decls...
13793configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec
13794
13795# ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code
13796func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH"
13797
13798# to be used as default LT_SYS_LIBRARY_PATH value in generated libtool
13799configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH
13800
13801
13802
13803
13804
13805
13806
13807
13808
13809
13810
13811
13812
13813
13814
13815
13816
13817
13818
13819
13820
13821
13822
13823
13824
13825
13826
13827
13828
13829
13830
13831
13832
13833
13834
13835
13836
13837
13838
13839
13840
13841
13842
13843
13844
13845
13846
13847
13848
13849
13850
13851
13852
13853
13854
13855
13856
13857
13858
13859
13860
13861
13862
13863
13864
13865
13866
13867
13868
13869
13870
13871
13872
13873
13874
13875
13876
13877
13878
13879
13880
13881
13882
13883
13884
13885
13886
13887
13888
13889
13890
13891
13892
13893
13894
13895
13896
13897  { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5
13898$as_echo_n "checking how to hardcode library paths into programs... " >&6; }
13899hardcode_action=
13900if test -n "$hardcode_libdir_flag_spec" ||
13901   test -n "$runpath_var" ||
13902   test yes = "$hardcode_automatic"; then
13903
13904  # We can hardcode non-existent directories.
13905  if test no != "$hardcode_direct" &&
13906     # If the only mechanism to avoid hardcoding is shlibpath_var, we
13907     # have to relink, otherwise we might link with an installed library
13908     # when we should be linking with a yet-to-be-installed one
13909     ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, )" &&
13910     test no != "$hardcode_minus_L"; then
13911    # Linking always hardcodes the temporary library directory.
13912    hardcode_action=relink
13913  else
13914    # We can link without hardcoding, and we can hardcode nonexisting dirs.
13915    hardcode_action=immediate
13916  fi
13917else
13918  # We cannot hardcode anything, or else we can only hardcode existing
13919  # directories.
13920  hardcode_action=unsupported
13921fi
13922{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5
13923$as_echo "$hardcode_action" >&6; }
13924
13925if test relink = "$hardcode_action" ||
13926   test yes = "$inherit_rpath"; then
13927  # Fast installation is not supported
13928  enable_fast_install=no
13929elif test yes = "$shlibpath_overrides_runpath" ||
13930     test no = "$enable_shared"; then
13931  # Fast installation is not necessary
13932  enable_fast_install=needless
13933fi
13934
13935
13936
13937
13938
13939
13940  if test yes != "$enable_dlopen"; then
13941  enable_dlopen=unknown
13942  enable_dlopen_self=unknown
13943  enable_dlopen_self_static=unknown
13944else
13945  lt_cv_dlopen=no
13946  lt_cv_dlopen_libs=
13947
13948  case $host_os in
13949  beos*)
13950    lt_cv_dlopen=load_add_on
13951    lt_cv_dlopen_libs=
13952    lt_cv_dlopen_self=yes
13953    ;;
13954
13955  mingw* | pw32* | cegcc*)
13956    lt_cv_dlopen=LoadLibrary
13957    lt_cv_dlopen_libs=
13958    ;;
13959
13960  cygwin*)
13961    lt_cv_dlopen=dlopen
13962    lt_cv_dlopen_libs=
13963    ;;
13964
13965  darwin*)
13966    # if libdl is installed we need to link against it
13967    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
13968$as_echo_n "checking for dlopen in -ldl... " >&6; }
13969if ${ac_cv_lib_dl_dlopen+:} false; then :
13970  $as_echo_n "(cached) " >&6
13971else
13972  ac_check_lib_save_LIBS=$LIBS
13973LIBS="-ldl  $LIBS"
13974cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13975/* end confdefs.h.  */
13976
13977/* Override any GCC internal prototype to avoid an error.
13978   Use char because int might match the return type of a GCC
13979   builtin and then its argument prototype would still apply.  */
13980#ifdef __cplusplus
13981extern "C"
13982#endif
13983char dlopen ();
13984int
13985main ()
13986{
13987return dlopen ();
13988  ;
13989  return 0;
13990}
13991_ACEOF
13992if ac_fn_c_try_link "$LINENO"; then :
13993  ac_cv_lib_dl_dlopen=yes
13994else
13995  ac_cv_lib_dl_dlopen=no
13996fi
13997rm -f core conftest.err conftest.$ac_objext \
13998    conftest$ac_exeext conftest.$ac_ext
13999LIBS=$ac_check_lib_save_LIBS
14000fi
14001{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
14002$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
14003if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
14004  lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl
14005else
14006
14007    lt_cv_dlopen=dyld
14008    lt_cv_dlopen_libs=
14009    lt_cv_dlopen_self=yes
14010
14011fi
14012
14013    ;;
14014
14015  tpf*)
14016    # Don't try to run any link tests for TPF.  We know it's impossible
14017    # because TPF is a cross-compiler, and we know how we open DSOs.
14018    lt_cv_dlopen=dlopen
14019    lt_cv_dlopen_libs=
14020    lt_cv_dlopen_self=no
14021    ;;
14022
14023  *)
14024    ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load"
14025if test "x$ac_cv_func_shl_load" = xyes; then :
14026  lt_cv_dlopen=shl_load
14027else
14028  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5
14029$as_echo_n "checking for shl_load in -ldld... " >&6; }
14030if ${ac_cv_lib_dld_shl_load+:} false; then :
14031  $as_echo_n "(cached) " >&6
14032else
14033  ac_check_lib_save_LIBS=$LIBS
14034LIBS="-ldld  $LIBS"
14035cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14036/* end confdefs.h.  */
14037
14038/* Override any GCC internal prototype to avoid an error.
14039   Use char because int might match the return type of a GCC
14040   builtin and then its argument prototype would still apply.  */
14041#ifdef __cplusplus
14042extern "C"
14043#endif
14044char shl_load ();
14045int
14046main ()
14047{
14048return shl_load ();
14049  ;
14050  return 0;
14051}
14052_ACEOF
14053if ac_fn_c_try_link "$LINENO"; then :
14054  ac_cv_lib_dld_shl_load=yes
14055else
14056  ac_cv_lib_dld_shl_load=no
14057fi
14058rm -f core conftest.err conftest.$ac_objext \
14059    conftest$ac_exeext conftest.$ac_ext
14060LIBS=$ac_check_lib_save_LIBS
14061fi
14062{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5
14063$as_echo "$ac_cv_lib_dld_shl_load" >&6; }
14064if test "x$ac_cv_lib_dld_shl_load" = xyes; then :
14065  lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld
14066else
14067  ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen"
14068if test "x$ac_cv_func_dlopen" = xyes; then :
14069  lt_cv_dlopen=dlopen
14070else
14071  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
14072$as_echo_n "checking for dlopen in -ldl... " >&6; }
14073if ${ac_cv_lib_dl_dlopen+:} false; then :
14074  $as_echo_n "(cached) " >&6
14075else
14076  ac_check_lib_save_LIBS=$LIBS
14077LIBS="-ldl  $LIBS"
14078cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14079/* end confdefs.h.  */
14080
14081/* Override any GCC internal prototype to avoid an error.
14082   Use char because int might match the return type of a GCC
14083   builtin and then its argument prototype would still apply.  */
14084#ifdef __cplusplus
14085extern "C"
14086#endif
14087char dlopen ();
14088int
14089main ()
14090{
14091return dlopen ();
14092  ;
14093  return 0;
14094}
14095_ACEOF
14096if ac_fn_c_try_link "$LINENO"; then :
14097  ac_cv_lib_dl_dlopen=yes
14098else
14099  ac_cv_lib_dl_dlopen=no
14100fi
14101rm -f core conftest.err conftest.$ac_objext \
14102    conftest$ac_exeext conftest.$ac_ext
14103LIBS=$ac_check_lib_save_LIBS
14104fi
14105{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
14106$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
14107if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
14108  lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl
14109else
14110  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5
14111$as_echo_n "checking for dlopen in -lsvld... " >&6; }
14112if ${ac_cv_lib_svld_dlopen+:} false; then :
14113  $as_echo_n "(cached) " >&6
14114else
14115  ac_check_lib_save_LIBS=$LIBS
14116LIBS="-lsvld  $LIBS"
14117cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14118/* end confdefs.h.  */
14119
14120/* Override any GCC internal prototype to avoid an error.
14121   Use char because int might match the return type of a GCC
14122   builtin and then its argument prototype would still apply.  */
14123#ifdef __cplusplus
14124extern "C"
14125#endif
14126char dlopen ();
14127int
14128main ()
14129{
14130return dlopen ();
14131  ;
14132  return 0;
14133}
14134_ACEOF
14135if ac_fn_c_try_link "$LINENO"; then :
14136  ac_cv_lib_svld_dlopen=yes
14137else
14138  ac_cv_lib_svld_dlopen=no
14139fi
14140rm -f core conftest.err conftest.$ac_objext \
14141    conftest$ac_exeext conftest.$ac_ext
14142LIBS=$ac_check_lib_save_LIBS
14143fi
14144{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5
14145$as_echo "$ac_cv_lib_svld_dlopen" >&6; }
14146if test "x$ac_cv_lib_svld_dlopen" = xyes; then :
14147  lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld
14148else
14149  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5
14150$as_echo_n "checking for dld_link in -ldld... " >&6; }
14151if ${ac_cv_lib_dld_dld_link+:} false; then :
14152  $as_echo_n "(cached) " >&6
14153else
14154  ac_check_lib_save_LIBS=$LIBS
14155LIBS="-ldld  $LIBS"
14156cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14157/* end confdefs.h.  */
14158
14159/* Override any GCC internal prototype to avoid an error.
14160   Use char because int might match the return type of a GCC
14161   builtin and then its argument prototype would still apply.  */
14162#ifdef __cplusplus
14163extern "C"
14164#endif
14165char dld_link ();
14166int
14167main ()
14168{
14169return dld_link ();
14170  ;
14171  return 0;
14172}
14173_ACEOF
14174if ac_fn_c_try_link "$LINENO"; then :
14175  ac_cv_lib_dld_dld_link=yes
14176else
14177  ac_cv_lib_dld_dld_link=no
14178fi
14179rm -f core conftest.err conftest.$ac_objext \
14180    conftest$ac_exeext conftest.$ac_ext
14181LIBS=$ac_check_lib_save_LIBS
14182fi
14183{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5
14184$as_echo "$ac_cv_lib_dld_dld_link" >&6; }
14185if test "x$ac_cv_lib_dld_dld_link" = xyes; then :
14186  lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld
14187fi
14188
14189
14190fi
14191
14192
14193fi
14194
14195
14196fi
14197
14198
14199fi
14200
14201
14202fi
14203
14204    ;;
14205  esac
14206
14207  if test no = "$lt_cv_dlopen"; then
14208    enable_dlopen=no
14209  else
14210    enable_dlopen=yes
14211  fi
14212
14213  case $lt_cv_dlopen in
14214  dlopen)
14215    save_CPPFLAGS=$CPPFLAGS
14216    test yes = "$ac_cv_header_dlfcn_h" && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
14217
14218    save_LDFLAGS=$LDFLAGS
14219    wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
14220
14221    save_LIBS=$LIBS
14222    LIBS="$lt_cv_dlopen_libs $LIBS"
14223
14224    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5
14225$as_echo_n "checking whether a program can dlopen itself... " >&6; }
14226if ${lt_cv_dlopen_self+:} false; then :
14227  $as_echo_n "(cached) " >&6
14228else
14229  	  if test yes = "$cross_compiling"; then :
14230  lt_cv_dlopen_self=cross
14231else
14232  lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
14233  lt_status=$lt_dlunknown
14234  cat > conftest.$ac_ext <<_LT_EOF
14235#line $LINENO "configure"
14236#include "confdefs.h"
14237
14238#if HAVE_DLFCN_H
14239#include <dlfcn.h>
14240#endif
14241
14242#include <stdio.h>
14243
14244#ifdef RTLD_GLOBAL
14245#  define LT_DLGLOBAL		RTLD_GLOBAL
14246#else
14247#  ifdef DL_GLOBAL
14248#    define LT_DLGLOBAL		DL_GLOBAL
14249#  else
14250#    define LT_DLGLOBAL		0
14251#  endif
14252#endif
14253
14254/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
14255   find out it does not work in some platform. */
14256#ifndef LT_DLLAZY_OR_NOW
14257#  ifdef RTLD_LAZY
14258#    define LT_DLLAZY_OR_NOW		RTLD_LAZY
14259#  else
14260#    ifdef DL_LAZY
14261#      define LT_DLLAZY_OR_NOW		DL_LAZY
14262#    else
14263#      ifdef RTLD_NOW
14264#        define LT_DLLAZY_OR_NOW	RTLD_NOW
14265#      else
14266#        ifdef DL_NOW
14267#          define LT_DLLAZY_OR_NOW	DL_NOW
14268#        else
14269#          define LT_DLLAZY_OR_NOW	0
14270#        endif
14271#      endif
14272#    endif
14273#  endif
14274#endif
14275
14276/* When -fvisibility=hidden is used, assume the code has been annotated
14277   correspondingly for the symbols needed.  */
14278#if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
14279int fnord () __attribute__((visibility("default")));
14280#endif
14281
14282int fnord () { return 42; }
14283int main ()
14284{
14285  void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
14286  int status = $lt_dlunknown;
14287
14288  if (self)
14289    {
14290      if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
14291      else
14292        {
14293	  if (dlsym( self,"_fnord"))  status = $lt_dlneed_uscore;
14294          else puts (dlerror ());
14295	}
14296      /* dlclose (self); */
14297    }
14298  else
14299    puts (dlerror ());
14300
14301  return status;
14302}
14303_LT_EOF
14304  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
14305  (eval $ac_link) 2>&5
14306  ac_status=$?
14307  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
14308  test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then
14309    (./conftest; exit; ) >&5 2>/dev/null
14310    lt_status=$?
14311    case x$lt_status in
14312      x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
14313      x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
14314      x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;;
14315    esac
14316  else :
14317    # compilation failed
14318    lt_cv_dlopen_self=no
14319  fi
14320fi
14321rm -fr conftest*
14322
14323
14324fi
14325{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5
14326$as_echo "$lt_cv_dlopen_self" >&6; }
14327
14328    if test yes = "$lt_cv_dlopen_self"; then
14329      wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
14330      { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5
14331$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; }
14332if ${lt_cv_dlopen_self_static+:} false; then :
14333  $as_echo_n "(cached) " >&6
14334else
14335  	  if test yes = "$cross_compiling"; then :
14336  lt_cv_dlopen_self_static=cross
14337else
14338  lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
14339  lt_status=$lt_dlunknown
14340  cat > conftest.$ac_ext <<_LT_EOF
14341#line $LINENO "configure"
14342#include "confdefs.h"
14343
14344#if HAVE_DLFCN_H
14345#include <dlfcn.h>
14346#endif
14347
14348#include <stdio.h>
14349
14350#ifdef RTLD_GLOBAL
14351#  define LT_DLGLOBAL		RTLD_GLOBAL
14352#else
14353#  ifdef DL_GLOBAL
14354#    define LT_DLGLOBAL		DL_GLOBAL
14355#  else
14356#    define LT_DLGLOBAL		0
14357#  endif
14358#endif
14359
14360/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
14361   find out it does not work in some platform. */
14362#ifndef LT_DLLAZY_OR_NOW
14363#  ifdef RTLD_LAZY
14364#    define LT_DLLAZY_OR_NOW		RTLD_LAZY
14365#  else
14366#    ifdef DL_LAZY
14367#      define LT_DLLAZY_OR_NOW		DL_LAZY
14368#    else
14369#      ifdef RTLD_NOW
14370#        define LT_DLLAZY_OR_NOW	RTLD_NOW
14371#      else
14372#        ifdef DL_NOW
14373#          define LT_DLLAZY_OR_NOW	DL_NOW
14374#        else
14375#          define LT_DLLAZY_OR_NOW	0
14376#        endif
14377#      endif
14378#    endif
14379#  endif
14380#endif
14381
14382/* When -fvisibility=hidden is used, assume the code has been annotated
14383   correspondingly for the symbols needed.  */
14384#if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
14385int fnord () __attribute__((visibility("default")));
14386#endif
14387
14388int fnord () { return 42; }
14389int main ()
14390{
14391  void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
14392  int status = $lt_dlunknown;
14393
14394  if (self)
14395    {
14396      if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
14397      else
14398        {
14399	  if (dlsym( self,"_fnord"))  status = $lt_dlneed_uscore;
14400          else puts (dlerror ());
14401	}
14402      /* dlclose (self); */
14403    }
14404  else
14405    puts (dlerror ());
14406
14407  return status;
14408}
14409_LT_EOF
14410  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
14411  (eval $ac_link) 2>&5
14412  ac_status=$?
14413  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
14414  test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then
14415    (./conftest; exit; ) >&5 2>/dev/null
14416    lt_status=$?
14417    case x$lt_status in
14418      x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
14419      x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
14420      x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;;
14421    esac
14422  else :
14423    # compilation failed
14424    lt_cv_dlopen_self_static=no
14425  fi
14426fi
14427rm -fr conftest*
14428
14429
14430fi
14431{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5
14432$as_echo "$lt_cv_dlopen_self_static" >&6; }
14433    fi
14434
14435    CPPFLAGS=$save_CPPFLAGS
14436    LDFLAGS=$save_LDFLAGS
14437    LIBS=$save_LIBS
14438    ;;
14439  esac
14440
14441  case $lt_cv_dlopen_self in
14442  yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
14443  *) enable_dlopen_self=unknown ;;
14444  esac
14445
14446  case $lt_cv_dlopen_self_static in
14447  yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
14448  *) enable_dlopen_self_static=unknown ;;
14449  esac
14450fi
14451
14452
14453
14454
14455
14456
14457
14458
14459
14460
14461
14462
14463
14464
14465
14466
14467
14468striplib=
14469old_striplib=
14470{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5
14471$as_echo_n "checking whether stripping libraries is possible... " >&6; }
14472if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
14473  test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
14474  test -z "$striplib" && striplib="$STRIP --strip-unneeded"
14475  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14476$as_echo "yes" >&6; }
14477else
14478# FIXME - insert some real tests, host_os isn't really good enough
14479  case $host_os in
14480  darwin*)
14481    if test -n "$STRIP"; then
14482      striplib="$STRIP -x"
14483      old_striplib="$STRIP -S"
14484      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14485$as_echo "yes" >&6; }
14486    else
14487      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14488$as_echo "no" >&6; }
14489    fi
14490    ;;
14491  *)
14492    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14493$as_echo "no" >&6; }
14494    ;;
14495  esac
14496fi
14497
14498
14499
14500
14501
14502
14503
14504
14505
14506
14507
14508
14509  # Report what library types will actually be built
14510  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5
14511$as_echo_n "checking if libtool supports shared libraries... " >&6; }
14512  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5
14513$as_echo "$can_build_shared" >&6; }
14514
14515  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5
14516$as_echo_n "checking whether to build shared libraries... " >&6; }
14517  test no = "$can_build_shared" && enable_shared=no
14518
14519  # On AIX, shared libraries and static libraries use the same namespace, and
14520  # are all built from PIC.
14521  case $host_os in
14522  aix3*)
14523    test yes = "$enable_shared" && enable_static=no
14524    if test -n "$RANLIB"; then
14525      archive_cmds="$archive_cmds~\$RANLIB \$lib"
14526      postinstall_cmds='$RANLIB $lib'
14527    fi
14528    ;;
14529
14530  aix[4-9]*)
14531    if test ia64 != "$host_cpu"; then
14532      case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in
14533      yes,aix,yes) ;;			# shared object as lib.so file only
14534      yes,svr4,*) ;;			# shared object as lib.so archive member only
14535      yes,*) enable_static=no ;;	# shared object in lib.a archive as well
14536      esac
14537    fi
14538    ;;
14539  esac
14540  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5
14541$as_echo "$enable_shared" >&6; }
14542
14543  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5
14544$as_echo_n "checking whether to build static libraries... " >&6; }
14545  # Make sure either enable_shared or enable_static is yes.
14546  test yes = "$enable_shared" || enable_static=yes
14547  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5
14548$as_echo "$enable_static" >&6; }
14549
14550
14551
14552
14553fi
14554ac_ext=c
14555ac_cpp='$CPP $CPPFLAGS'
14556ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
14557ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
14558ac_compiler_gnu=$ac_cv_c_compiler_gnu
14559
14560CC=$lt_save_CC
14561
14562
14563
14564
14565
14566
14567
14568
14569
14570
14571
14572
14573
14574
14575
14576        ac_config_commands="$ac_config_commands libtool"
14577
14578
14579
14580
14581# Only expand once:
14582
14583
14584
14585
14586# NTP has (so far) been relying on leading-edge autogen, which
14587# means we need the appropriate corresponding libopts as well.
14588# Therefore, by default:
14589# - use the version of libopts we ship with
14590# - do not install it
14591# - build a static copy (AC_DISABLE_SHARED - done earlier)
14592case "${enable_local_libopts+set}" in
14593 set) ;;
14594 *) enable_local_libopts=yes ;;
14595esac
14596case "${enable_libopts_install+set}" in
14597 set) ;;
14598 *) enable_libopts_install=no ;;
14599esac
14600enable_nls=no
14601ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
14602if test "x$ac_cv_type_pid_t" = xyes; then :
14603
14604else
14605
14606cat >>confdefs.h <<_ACEOF
14607#define pid_t int
14608_ACEOF
14609
14610fi
14611
14612
14613
14614  ac_header_dirent=no
14615for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
14616  as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
14617{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5
14618$as_echo_n "checking for $ac_hdr that defines DIR... " >&6; }
14619if eval \${$as_ac_Header+:} false; then :
14620  $as_echo_n "(cached) " >&6
14621else
14622  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14623/* end confdefs.h.  */
14624#include <sys/types.h>
14625#include <$ac_hdr>
14626
14627int
14628main ()
14629{
14630if ((DIR *) 0)
14631return 0;
14632  ;
14633  return 0;
14634}
14635_ACEOF
14636if ac_fn_c_try_compile "$LINENO"; then :
14637  eval "$as_ac_Header=yes"
14638else
14639  eval "$as_ac_Header=no"
14640fi
14641rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14642fi
14643eval ac_res=\$$as_ac_Header
14644	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
14645$as_echo "$ac_res" >&6; }
14646if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
14647  cat >>confdefs.h <<_ACEOF
14648#define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
14649_ACEOF
14650
14651ac_header_dirent=$ac_hdr; break
14652fi
14653
14654done
14655# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
14656if test $ac_header_dirent = dirent.h; then
14657  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5
14658$as_echo_n "checking for library containing opendir... " >&6; }
14659if ${ac_cv_search_opendir+:} false; then :
14660  $as_echo_n "(cached) " >&6
14661else
14662  ac_func_search_save_LIBS=$LIBS
14663cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14664/* end confdefs.h.  */
14665
14666/* Override any GCC internal prototype to avoid an error.
14667   Use char because int might match the return type of a GCC
14668   builtin and then its argument prototype would still apply.  */
14669#ifdef __cplusplus
14670extern "C"
14671#endif
14672char opendir ();
14673int
14674main ()
14675{
14676return opendir ();
14677  ;
14678  return 0;
14679}
14680_ACEOF
14681for ac_lib in '' dir; do
14682  if test -z "$ac_lib"; then
14683    ac_res="none required"
14684  else
14685    ac_res=-l$ac_lib
14686    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
14687  fi
14688  if ac_fn_c_try_link "$LINENO"; then :
14689  ac_cv_search_opendir=$ac_res
14690fi
14691rm -f core conftest.err conftest.$ac_objext \
14692    conftest$ac_exeext
14693  if ${ac_cv_search_opendir+:} false; then :
14694  break
14695fi
14696done
14697if ${ac_cv_search_opendir+:} false; then :
14698
14699else
14700  ac_cv_search_opendir=no
14701fi
14702rm conftest.$ac_ext
14703LIBS=$ac_func_search_save_LIBS
14704fi
14705{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5
14706$as_echo "$ac_cv_search_opendir" >&6; }
14707ac_res=$ac_cv_search_opendir
14708if test "$ac_res" != no; then :
14709  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
14710
14711fi
14712
14713else
14714  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5
14715$as_echo_n "checking for library containing opendir... " >&6; }
14716if ${ac_cv_search_opendir+:} false; then :
14717  $as_echo_n "(cached) " >&6
14718else
14719  ac_func_search_save_LIBS=$LIBS
14720cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14721/* end confdefs.h.  */
14722
14723/* Override any GCC internal prototype to avoid an error.
14724   Use char because int might match the return type of a GCC
14725   builtin and then its argument prototype would still apply.  */
14726#ifdef __cplusplus
14727extern "C"
14728#endif
14729char opendir ();
14730int
14731main ()
14732{
14733return opendir ();
14734  ;
14735  return 0;
14736}
14737_ACEOF
14738for ac_lib in '' x; do
14739  if test -z "$ac_lib"; then
14740    ac_res="none required"
14741  else
14742    ac_res=-l$ac_lib
14743    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
14744  fi
14745  if ac_fn_c_try_link "$LINENO"; then :
14746  ac_cv_search_opendir=$ac_res
14747fi
14748rm -f core conftest.err conftest.$ac_objext \
14749    conftest$ac_exeext
14750  if ${ac_cv_search_opendir+:} false; then :
14751  break
14752fi
14753done
14754if ${ac_cv_search_opendir+:} false; then :
14755
14756else
14757  ac_cv_search_opendir=no
14758fi
14759rm conftest.$ac_ext
14760LIBS=$ac_func_search_save_LIBS
14761fi
14762{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5
14763$as_echo "$ac_cv_search_opendir" >&6; }
14764ac_res=$ac_cv_search_opendir
14765if test "$ac_res" != no; then :
14766  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
14767
14768fi
14769
14770fi
14771
14772
14773  # =================
14774  # AC_CHECK_HEADERS
14775  # =================
14776  for ac_header in  \
14777      sys/mman.h    sys/param.h   sys/poll.h    sys/procset.h \
14778      sys/select.h  sys/socket.h  sys/stropts.h sys/time.h \
14779      sys/un.h      sys/wait.h    dlfcn.h       errno.h \
14780      fcntl.h       libgen.h      libintl.h     memory.h \
14781      netinet/in.h  setjmp.h      stdbool.h     sysexits.h \
14782      unistd.h      utime.h
14783do :
14784  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
14785ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
14786if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
14787  cat >>confdefs.h <<_ACEOF
14788#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
14789_ACEOF
14790
14791fi
14792
14793done
14794
14795
14796  for ac_header in stdarg.h     varargs.h
14797do :
14798  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
14799ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
14800if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
14801  cat >>confdefs.h <<_ACEOF
14802#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
14803_ACEOF
14804 lo_have_arg_hdr=true;break
14805else
14806  lo_have_arg_hdr=false
14807fi
14808
14809done
14810
14811
14812  for ac_header in string.h     strings.h
14813do :
14814  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
14815ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
14816if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
14817  cat >>confdefs.h <<_ACEOF
14818#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
14819_ACEOF
14820 lo_have_str_hdr=true;break
14821else
14822  lo_have_str_hdr=false
14823fi
14824
14825done
14826
14827
14828  for ac_header in limits.h     sys/limits.h  values.h
14829do :
14830  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
14831ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
14832if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
14833  cat >>confdefs.h <<_ACEOF
14834#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
14835_ACEOF
14836 lo_have_lim_hdr=true;break
14837else
14838  lo_have_lim_hdr=false
14839fi
14840
14841done
14842
14843
14844  for ac_header in inttypes.h   stdint.h
14845do :
14846  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
14847ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
14848if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
14849  cat >>confdefs.h <<_ACEOF
14850#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
14851_ACEOF
14852 lo_have_typ_hdr=true;break
14853else
14854  lo_have_typ_hdr=false
14855fi
14856
14857done
14858
14859
14860  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working stdnoreturn.h" >&5
14861$as_echo_n "checking for working stdnoreturn.h... " >&6; }
14862if ${gl_cv_header_working_stdnoreturn_h+:} false; then :
14863  $as_echo_n "(cached) " >&6
14864else
14865  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14866/* end confdefs.h.  */
14867#include <stdlib.h>
14868            #include <stdnoreturn.h>
14869            /* Do not check for 'noreturn' after the return type.
14870               C11 allows it, but it's rarely done that way
14871               and circa-2012 bleeding-edge GCC rejects it when given
14872               -Werror=old-style-declaration.  */
14873            noreturn void foo1 (void) { exit (0); }
14874            _Noreturn void foo2 (void) { exit (0); }
14875            int testit (int argc, char **argv) {
14876              if (argc & 1)
14877                return 0;
14878              (argv[0][0] ? foo1 : foo2) ();
14879            }
14880
14881int
14882main ()
14883{
14884
14885  ;
14886  return 0;
14887}
14888_ACEOF
14889if ac_fn_c_try_compile "$LINENO"; then :
14890  gl_cv_header_working_stdnoreturn_h=yes
14891else
14892  gl_cv_header_working_stdnoreturn_h=no
14893fi
14894rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14895fi
14896{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdnoreturn_h" >&5
14897$as_echo "$gl_cv_header_working_stdnoreturn_h" >&6; }
14898
14899  if test $gl_cv_header_working_stdnoreturn_h = yes; then
14900    STDNORETURN_H=''
14901  else
14902    STDNORETURN_H='stdnoreturn.h'
14903  fi
14904
14905
14906   if test -n "$STDNORETURN_H"; then
14907  GL_GENERATE_STDNORETURN_H_TRUE=
14908  GL_GENERATE_STDNORETURN_H_FALSE='#'
14909else
14910  GL_GENERATE_STDNORETURN_H_TRUE='#'
14911  GL_GENERATE_STDNORETURN_H_FALSE=
14912fi
14913
14914
14915
14916  # ----------------------------------------------------------------------
14917  # check for various programs used during the build.
14918  # On OS/X, "wchar.h" needs "runetype.h" to work properly.
14919  # ----------------------------------------------------------------------
14920  for ac_header in runetype.h wchar.h
14921do :
14922  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
14923ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "
14924  $ac_includes_default
14925  #if HAVE_RUNETYPE_H
14926  # include <runetype.h>
14927  #endif
14928
14929"
14930if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
14931  cat >>confdefs.h <<_ACEOF
14932#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
14933_ACEOF
14934
14935fi
14936
14937done
14938
14939
14940  # Check whether --enable-nls was given.
14941if test "${enable_nls+set}" = set; then :
14942  enableval=$enable_nls;
14943fi
14944
14945  if test "x$enable_nls" != "xno" && \
14946  test "X${ac_cv_header_libintl_h}" = Xyes; then :
14947
14948
14949$as_echo "#define ENABLE_NLS 1" >>confdefs.h
14950
14951fi
14952
14953  # --------------------------------------------
14954  # Verify certain entries from AC_CHECK_HEADERS
14955  # --------------------------------------------
14956  ${lo_have_arg_hdr} || \
14957    as_fn_error $? "you must have stdarg.h or varargs.h on your system" "$LINENO" 5
14958
14959  ${lo_have_str_hdr} || \
14960    as_fn_error $? "you must have string.h or strings.h on your system" "$LINENO" 5
14961
14962  ${lo_have_lim_hdr} || \
14963    as_fn_error $? "you must have one of limits.h, sys/limits.h or values.h" "$LINENO" 5
14964
14965  ${lo_have_typ_hdr} || \
14966    as_fn_error $? "you must have inttypes.h or stdint.h on your system" "$LINENO" 5
14967
14968  for f in sys_types sys_param sys_stat string errno stdlib memory setjmp
14969  do eval as_ac_var=\${ac_cv_header_${f}_h}
14970     test "X${as_ac_var}" = Xyes || {
14971       as_fn_error $? "you must have ${f}.h on your system" "$LINENO" 5
14972     }
14973  done
14974  test "X${ac_cv_header_inttypes_h-no}" = Xyes || \
14975    echo '#include <stdint.h>' > inttypes.h
14976
14977  # ----------------------------------------------------------------------
14978  # Checks for typedefs
14979  # ----------------------------------------------------------------------
14980  ac_fn_c_check_type "$LINENO" "wchar_t" "ac_cv_type_wchar_t" "$ac_includes_default"
14981if test "x$ac_cv_type_wchar_t" = xyes; then :
14982
14983cat >>confdefs.h <<_ACEOF
14984#define HAVE_WCHAR_T 1
14985_ACEOF
14986
14987
14988fi
14989
14990  ac_fn_c_check_type "$LINENO" "wint_t" "ac_cv_type_wint_t" "
14991    $ac_includes_default
14992    #if HAVE_RUNETYPE_H
14993    # include <runetype.h>
14994    #endif
14995    #if HAVE_WCHAR_H
14996    # include <wchar.h>
14997    #endif
14998
14999"
15000if test "x$ac_cv_type_wint_t" = xyes; then :
15001
15002cat >>confdefs.h <<_ACEOF
15003#define HAVE_WINT_T 1
15004_ACEOF
15005
15006
15007fi
15008
15009  ac_fn_c_check_type "$LINENO" "int8_t" "ac_cv_type_int8_t" "$ac_includes_default"
15010if test "x$ac_cv_type_int8_t" = xyes; then :
15011
15012cat >>confdefs.h <<_ACEOF
15013#define HAVE_INT8_T 1
15014_ACEOF
15015
15016
15017fi
15018ac_fn_c_check_type "$LINENO" "uint8_t" "ac_cv_type_uint8_t" "$ac_includes_default"
15019if test "x$ac_cv_type_uint8_t" = xyes; then :
15020
15021cat >>confdefs.h <<_ACEOF
15022#define HAVE_UINT8_T 1
15023_ACEOF
15024
15025
15026fi
15027ac_fn_c_check_type "$LINENO" "int16_t" "ac_cv_type_int16_t" "$ac_includes_default"
15028if test "x$ac_cv_type_int16_t" = xyes; then :
15029
15030cat >>confdefs.h <<_ACEOF
15031#define HAVE_INT16_T 1
15032_ACEOF
15033
15034
15035fi
15036ac_fn_c_check_type "$LINENO" "uint16_t" "ac_cv_type_uint16_t" "$ac_includes_default"
15037if test "x$ac_cv_type_uint16_t" = xyes; then :
15038
15039cat >>confdefs.h <<_ACEOF
15040#define HAVE_UINT16_T 1
15041_ACEOF
15042
15043
15044fi
15045ac_fn_c_check_type "$LINENO" "int32_t" "ac_cv_type_int32_t" "$ac_includes_default"
15046if test "x$ac_cv_type_int32_t" = xyes; then :
15047
15048cat >>confdefs.h <<_ACEOF
15049#define HAVE_INT32_T 1
15050_ACEOF
15051
15052
15053fi
15054ac_fn_c_check_type "$LINENO" "uint32_t" "ac_cv_type_uint32_t" "$ac_includes_default"
15055if test "x$ac_cv_type_uint32_t" = xyes; then :
15056
15057cat >>confdefs.h <<_ACEOF
15058#define HAVE_UINT32_T 1
15059_ACEOF
15060
15061
15062fi
15063ac_fn_c_check_type "$LINENO" "intptr_t" "ac_cv_type_intptr_t" "$ac_includes_default"
15064if test "x$ac_cv_type_intptr_t" = xyes; then :
15065
15066cat >>confdefs.h <<_ACEOF
15067#define HAVE_INTPTR_T 1
15068_ACEOF
15069
15070
15071fi
15072ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default"
15073if test "x$ac_cv_type_uintptr_t" = xyes; then :
15074
15075cat >>confdefs.h <<_ACEOF
15076#define HAVE_UINTPTR_T 1
15077_ACEOF
15078
15079
15080fi
15081ac_fn_c_check_type "$LINENO" "uint_t" "ac_cv_type_uint_t" "$ac_includes_default"
15082if test "x$ac_cv_type_uint_t" = xyes; then :
15083
15084cat >>confdefs.h <<_ACEOF
15085#define HAVE_UINT_T 1
15086_ACEOF
15087
15088
15089fi
15090ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
15091if test "x$ac_cv_type_pid_t" = xyes; then :
15092
15093cat >>confdefs.h <<_ACEOF
15094#define HAVE_PID_T 1
15095_ACEOF
15096
15097
15098fi
15099ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
15100if test "x$ac_cv_type_size_t" = xyes; then :
15101
15102cat >>confdefs.h <<_ACEOF
15103#define HAVE_SIZE_T 1
15104_ACEOF
15105
15106
15107fi
15108ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default"
15109if test "x$ac_cv_type_ptrdiff_t" = xyes; then :
15110
15111cat >>confdefs.h <<_ACEOF
15112#define HAVE_PTRDIFF_T 1
15113_ACEOF
15114
15115
15116fi
15117
15118  # The cast to long int works around a bug in the HP C Compiler
15119# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
15120# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
15121# This bug is HP SR number 8606223364.
15122{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of char *" >&5
15123$as_echo_n "checking size of char *... " >&6; }
15124if ${ac_cv_sizeof_char_p+:} false; then :
15125  $as_echo_n "(cached) " >&6
15126else
15127  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (char *))" "ac_cv_sizeof_char_p"        "$ac_includes_default"; then :
15128
15129else
15130  if test "$ac_cv_type_char_p" = yes; then
15131     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
15132$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
15133as_fn_error 77 "cannot compute sizeof (char *)
15134See \`config.log' for more details" "$LINENO" 5; }
15135   else
15136     ac_cv_sizeof_char_p=0
15137   fi
15138fi
15139
15140fi
15141{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_char_p" >&5
15142$as_echo "$ac_cv_sizeof_char_p" >&6; }
15143
15144
15145
15146cat >>confdefs.h <<_ACEOF
15147#define SIZEOF_CHAR_P $ac_cv_sizeof_char_p
15148_ACEOF
15149
15150
15151  # The cast to long int works around a bug in the HP C Compiler
15152# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
15153# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
15154# This bug is HP SR number 8606223364.
15155{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5
15156$as_echo_n "checking size of int... " >&6; }
15157if ${ac_cv_sizeof_int+:} false; then :
15158  $as_echo_n "(cached) " >&6
15159else
15160  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int"        "$ac_includes_default"; then :
15161
15162else
15163  if test "$ac_cv_type_int" = yes; then
15164     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
15165$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
15166as_fn_error 77 "cannot compute sizeof (int)
15167See \`config.log' for more details" "$LINENO" 5; }
15168   else
15169     ac_cv_sizeof_int=0
15170   fi
15171fi
15172
15173fi
15174{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5
15175$as_echo "$ac_cv_sizeof_int" >&6; }
15176
15177
15178
15179cat >>confdefs.h <<_ACEOF
15180#define SIZEOF_INT $ac_cv_sizeof_int
15181_ACEOF
15182
15183
15184  # The cast to long int works around a bug in the HP C Compiler
15185# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
15186# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
15187# This bug is HP SR number 8606223364.
15188{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
15189$as_echo_n "checking size of long... " >&6; }
15190if ${ac_cv_sizeof_long+:} false; then :
15191  $as_echo_n "(cached) " >&6
15192else
15193  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long"        "$ac_includes_default"; then :
15194
15195else
15196  if test "$ac_cv_type_long" = yes; then
15197     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
15198$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
15199as_fn_error 77 "cannot compute sizeof (long)
15200See \`config.log' for more details" "$LINENO" 5; }
15201   else
15202     ac_cv_sizeof_long=0
15203   fi
15204fi
15205
15206fi
15207{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
15208$as_echo "$ac_cv_sizeof_long" >&6; }
15209
15210
15211
15212cat >>confdefs.h <<_ACEOF
15213#define SIZEOF_LONG $ac_cv_sizeof_long
15214_ACEOF
15215
15216
15217  # The cast to long int works around a bug in the HP C Compiler
15218# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
15219# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
15220# This bug is HP SR number 8606223364.
15221{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5
15222$as_echo_n "checking size of short... " >&6; }
15223if ${ac_cv_sizeof_short+:} false; then :
15224  $as_echo_n "(cached) " >&6
15225else
15226  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (short))" "ac_cv_sizeof_short"        "$ac_includes_default"; then :
15227
15228else
15229  if test "$ac_cv_type_short" = yes; then
15230     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
15231$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
15232as_fn_error 77 "cannot compute sizeof (short)
15233See \`config.log' for more details" "$LINENO" 5; }
15234   else
15235     ac_cv_sizeof_short=0
15236   fi
15237fi
15238
15239fi
15240{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5
15241$as_echo "$ac_cv_sizeof_short" >&6; }
15242
15243
15244
15245cat >>confdefs.h <<_ACEOF
15246#define SIZEOF_SHORT $ac_cv_sizeof_short
15247_ACEOF
15248
15249
15250
15251  # ------------
15252  # AC_CHECK_LIB
15253  # ------------
15254  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pathfind in -lgen" >&5
15255$as_echo_n "checking for pathfind in -lgen... " >&6; }
15256if ${ac_cv_lib_gen_pathfind+:} false; then :
15257  $as_echo_n "(cached) " >&6
15258else
15259  ac_check_lib_save_LIBS=$LIBS
15260LIBS="-lgen  $LIBS"
15261cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15262/* end confdefs.h.  */
15263
15264/* Override any GCC internal prototype to avoid an error.
15265   Use char because int might match the return type of a GCC
15266   builtin and then its argument prototype would still apply.  */
15267#ifdef __cplusplus
15268extern "C"
15269#endif
15270char pathfind ();
15271int
15272main ()
15273{
15274return pathfind ();
15275  ;
15276  return 0;
15277}
15278_ACEOF
15279if ac_fn_c_try_link "$LINENO"; then :
15280  ac_cv_lib_gen_pathfind=yes
15281else
15282  ac_cv_lib_gen_pathfind=no
15283fi
15284rm -f core conftest.err conftest.$ac_objext \
15285    conftest$ac_exeext conftest.$ac_ext
15286LIBS=$ac_check_lib_save_LIBS
15287fi
15288{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gen_pathfind" >&5
15289$as_echo "$ac_cv_lib_gen_pathfind" >&6; }
15290if test "x$ac_cv_lib_gen_pathfind" = xyes; then :
15291  cat >>confdefs.h <<_ACEOF
15292#define HAVE_LIBGEN 1
15293_ACEOF
15294
15295  LIBS="-lgen $LIBS"
15296
15297fi
15298
15299  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gettext in -lintl" >&5
15300$as_echo_n "checking for gettext in -lintl... " >&6; }
15301if ${ac_cv_lib_intl_gettext+:} false; then :
15302  $as_echo_n "(cached) " >&6
15303else
15304  ac_check_lib_save_LIBS=$LIBS
15305LIBS="-lintl  $LIBS"
15306cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15307/* end confdefs.h.  */
15308
15309/* Override any GCC internal prototype to avoid an error.
15310   Use char because int might match the return type of a GCC
15311   builtin and then its argument prototype would still apply.  */
15312#ifdef __cplusplus
15313extern "C"
15314#endif
15315char gettext ();
15316int
15317main ()
15318{
15319return gettext ();
15320  ;
15321  return 0;
15322}
15323_ACEOF
15324if ac_fn_c_try_link "$LINENO"; then :
15325  ac_cv_lib_intl_gettext=yes
15326else
15327  ac_cv_lib_intl_gettext=no
15328fi
15329rm -f core conftest.err conftest.$ac_objext \
15330    conftest$ac_exeext conftest.$ac_ext
15331LIBS=$ac_check_lib_save_LIBS
15332fi
15333{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_gettext" >&5
15334$as_echo "$ac_cv_lib_intl_gettext" >&6; }
15335if test "x$ac_cv_lib_intl_gettext" = xyes; then :
15336  cat >>confdefs.h <<_ACEOF
15337#define HAVE_LIBINTL 1
15338_ACEOF
15339
15340  LIBS="-lintl $LIBS"
15341
15342fi
15343
15344  for ac_func in vprintf
15345do :
15346  ac_fn_c_check_func "$LINENO" "vprintf" "ac_cv_func_vprintf"
15347if test "x$ac_cv_func_vprintf" = xyes; then :
15348  cat >>confdefs.h <<_ACEOF
15349#define HAVE_VPRINTF 1
15350_ACEOF
15351
15352ac_fn_c_check_func "$LINENO" "_doprnt" "ac_cv_func__doprnt"
15353if test "x$ac_cv_func__doprnt" = xyes; then :
15354
15355$as_echo "#define HAVE_DOPRNT 1" >>confdefs.h
15356
15357fi
15358
15359fi
15360done
15361
15362
15363  for ac_header in vfork.h
15364do :
15365  ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
15366if test "x$ac_cv_header_vfork_h" = xyes; then :
15367  cat >>confdefs.h <<_ACEOF
15368#define HAVE_VFORK_H 1
15369_ACEOF
15370
15371fi
15372
15373done
15374
15375for ac_func in fork vfork
15376do :
15377  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15378ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15379if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
15380  cat >>confdefs.h <<_ACEOF
15381#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15382_ACEOF
15383
15384fi
15385done
15386
15387if test "x$ac_cv_func_fork" = xyes; then
15388  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
15389$as_echo_n "checking for working fork... " >&6; }
15390if ${ac_cv_func_fork_works+:} false; then :
15391  $as_echo_n "(cached) " >&6
15392else
15393  if test "$cross_compiling" = yes; then :
15394  ac_cv_func_fork_works=cross
15395else
15396  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15397/* end confdefs.h.  */
15398$ac_includes_default
15399int
15400main ()
15401{
15402
15403	  /* By Ruediger Kuhlmann. */
15404	  return fork () < 0;
15405
15406  ;
15407  return 0;
15408}
15409_ACEOF
15410if ac_fn_c_try_run "$LINENO"; then :
15411  ac_cv_func_fork_works=yes
15412else
15413  ac_cv_func_fork_works=no
15414fi
15415rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15416  conftest.$ac_objext conftest.beam conftest.$ac_ext
15417fi
15418
15419fi
15420{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
15421$as_echo "$ac_cv_func_fork_works" >&6; }
15422
15423else
15424  ac_cv_func_fork_works=$ac_cv_func_fork
15425fi
15426if test "x$ac_cv_func_fork_works" = xcross; then
15427  case $host in
15428    *-*-amigaos* | *-*-msdosdjgpp*)
15429      # Override, as these systems have only a dummy fork() stub
15430      ac_cv_func_fork_works=no
15431      ;;
15432    *)
15433      ac_cv_func_fork_works=yes
15434      ;;
15435  esac
15436  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
15437$as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
15438fi
15439ac_cv_func_vfork_works=$ac_cv_func_vfork
15440if test "x$ac_cv_func_vfork" = xyes; then
15441  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
15442$as_echo_n "checking for working vfork... " >&6; }
15443if ${ac_cv_func_vfork_works+:} false; then :
15444  $as_echo_n "(cached) " >&6
15445else
15446  if test "$cross_compiling" = yes; then :
15447  ac_cv_func_vfork_works=cross
15448else
15449  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15450/* end confdefs.h.  */
15451/* Thanks to Paul Eggert for this test.  */
15452$ac_includes_default
15453#include <sys/wait.h>
15454#ifdef HAVE_VFORK_H
15455# include <vfork.h>
15456#endif
15457/* On some sparc systems, changes by the child to local and incoming
15458   argument registers are propagated back to the parent.  The compiler
15459   is told about this with #include <vfork.h>, but some compilers
15460   (e.g. gcc -O) don't grok <vfork.h>.  Test for this by using a
15461   static variable whose address is put into a register that is
15462   clobbered by the vfork.  */
15463static void
15464#ifdef __cplusplus
15465sparc_address_test (int arg)
15466# else
15467sparc_address_test (arg) int arg;
15468#endif
15469{
15470  static pid_t child;
15471  if (!child) {
15472    child = vfork ();
15473    if (child < 0) {
15474      perror ("vfork");
15475      _exit(2);
15476    }
15477    if (!child) {
15478      arg = getpid();
15479      write(-1, "", 0);
15480      _exit (arg);
15481    }
15482  }
15483}
15484
15485int
15486main ()
15487{
15488  pid_t parent = getpid ();
15489  pid_t child;
15490
15491  sparc_address_test (0);
15492
15493  child = vfork ();
15494
15495  if (child == 0) {
15496    /* Here is another test for sparc vfork register problems.  This
15497       test uses lots of local variables, at least as many local
15498       variables as main has allocated so far including compiler
15499       temporaries.  4 locals are enough for gcc 1.40.3 on a Solaris
15500       4.1.3 sparc, but we use 8 to be safe.  A buggy compiler should
15501       reuse the register of parent for one of the local variables,
15502       since it will think that parent can't possibly be used any more
15503       in this routine.  Assigning to the local variable will thus
15504       munge parent in the parent process.  */
15505    pid_t
15506      p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
15507      p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
15508    /* Convince the compiler that p..p7 are live; otherwise, it might
15509       use the same hardware register for all 8 local variables.  */
15510    if (p != p1 || p != p2 || p != p3 || p != p4
15511	|| p != p5 || p != p6 || p != p7)
15512      _exit(1);
15513
15514    /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
15515       from child file descriptors.  If the child closes a descriptor
15516       before it execs or exits, this munges the parent's descriptor
15517       as well.  Test for this by closing stdout in the child.  */
15518    _exit(close(fileno(stdout)) != 0);
15519  } else {
15520    int status;
15521    struct stat st;
15522
15523    while (wait(&status) != child)
15524      ;
15525    return (
15526	 /* Was there some problem with vforking?  */
15527	 child < 0
15528
15529	 /* Did the child fail?  (This shouldn't happen.)  */
15530	 || status
15531
15532	 /* Did the vfork/compiler bug occur?  */
15533	 || parent != getpid()
15534
15535	 /* Did the file descriptor bug occur?  */
15536	 || fstat(fileno(stdout), &st) != 0
15537	 );
15538  }
15539}
15540_ACEOF
15541if ac_fn_c_try_run "$LINENO"; then :
15542  ac_cv_func_vfork_works=yes
15543else
15544  ac_cv_func_vfork_works=no
15545fi
15546rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15547  conftest.$ac_objext conftest.beam conftest.$ac_ext
15548fi
15549
15550fi
15551{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
15552$as_echo "$ac_cv_func_vfork_works" >&6; }
15553
15554fi;
15555if test "x$ac_cv_func_fork_works" = xcross; then
15556  ac_cv_func_vfork_works=$ac_cv_func_vfork
15557  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
15558$as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
15559fi
15560
15561if test "x$ac_cv_func_vfork_works" = xyes; then
15562
15563$as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
15564
15565else
15566
15567$as_echo "#define vfork fork" >>confdefs.h
15568
15569fi
15570if test "x$ac_cv_func_fork_works" = xyes; then
15571
15572$as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
15573
15574fi
15575
15576  for ac_func in mmap canonicalize_file_name snprintf strdup strchr \
15577                 strrchr strsignal fchmod fstat chmod
15578do :
15579  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15580ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15581if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
15582  cat >>confdefs.h <<_ACEOF
15583#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15584_ACEOF
15585
15586fi
15587done
15588
15589  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
15590$as_echo_n "checking for a sed that does not truncate output... " >&6; }
15591if ${ac_cv_path_SED+:} false; then :
15592  $as_echo_n "(cached) " >&6
15593else
15594            ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
15595     for ac_i in 1 2 3 4 5 6 7; do
15596       ac_script="$ac_script$as_nl$ac_script"
15597     done
15598     echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
15599     { ac_script=; unset ac_script;}
15600     if test -z "$SED"; then
15601  ac_path_SED_found=false
15602  # Loop through the user's path and test for each of PROGNAME-LIST
15603  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15604for as_dir in $PATH
15605do
15606  IFS=$as_save_IFS
15607  test -z "$as_dir" && as_dir=.
15608    for ac_prog in sed gsed; do
15609    for ac_exec_ext in '' $ac_executable_extensions; do
15610      ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
15611      as_fn_executable_p "$ac_path_SED" || continue
15612# Check for GNU ac_path_SED and select it if it is found.
15613  # Check for GNU $ac_path_SED
15614case `"$ac_path_SED" --version 2>&1` in
15615*GNU*)
15616  ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
15617*)
15618  ac_count=0
15619  $as_echo_n 0123456789 >"conftest.in"
15620  while :
15621  do
15622    cat "conftest.in" "conftest.in" >"conftest.tmp"
15623    mv "conftest.tmp" "conftest.in"
15624    cp "conftest.in" "conftest.nl"
15625    $as_echo '' >> "conftest.nl"
15626    "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
15627    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
15628    as_fn_arith $ac_count + 1 && ac_count=$as_val
15629    if test $ac_count -gt ${ac_path_SED_max-0}; then
15630      # Best one so far, save it but keep looking for a better one
15631      ac_cv_path_SED="$ac_path_SED"
15632      ac_path_SED_max=$ac_count
15633    fi
15634    # 10*(2^10) chars as input seems more than enough
15635    test $ac_count -gt 10 && break
15636  done
15637  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
15638esac
15639
15640      $ac_path_SED_found && break 3
15641    done
15642  done
15643  done
15644IFS=$as_save_IFS
15645  if test -z "$ac_cv_path_SED"; then
15646    as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
15647  fi
15648else
15649  ac_cv_path_SED=$SED
15650fi
15651
15652fi
15653{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
15654$as_echo "$ac_cv_path_SED" >&6; }
15655 SED="$ac_cv_path_SED"
15656  rm -f conftest.sed
15657
15658  while :
15659  do
15660      POSIX_SHELL=`which bash`
15661      test -x "$POSIX_SHELL" && break
15662      POSIX_SHELL=`which dash`
15663      test -x "$POSIX_SHELL" && break
15664      POSIX_SHELL=/usr/xpg4/bin/sh
15665      test -x "$POSIX_SHELL" && break
15666      POSIX_SHELL=`/bin/sh -c '
15667          exec 2>/dev/null
15668          if ! true ; then exit 1 ; fi
15669          echo /bin/sh'`
15670      test -x "$POSIX_SHELL" && break
15671      as_fn_error $? "cannot locate a working POSIX shell" "$LINENO" 5
15672  done
15673
15674cat >>confdefs.h <<_ACEOF
15675#define POSIX_SHELL "${POSIX_SHELL}"
15676_ACEOF
15677
15678
15679
15680
15681
15682  LIBOPTS_BUILD_BLOCKED=true
15683
15684
15685  NEED_LIBOPTS_DIR=''
15686
15687  # Check whether --enable-local-libopts was given.
15688if test "${enable_local_libopts+set}" = set; then :
15689  enableval=$enable_local_libopts;
15690    if test x$enableval = xyes ; then
15691       { $as_echo "$as_me:${as_lineno-$LINENO}: Using supplied libopts tearoff" >&5
15692$as_echo "$as_me: Using supplied libopts tearoff" >&6;}
15693       LIBOPTS_CFLAGS='-I$(top_srcdir)/sntp/libopts'
15694       NEED_LIBOPTS_DIR=true
15695       LIBOPTS_LDADD='$(top_builddir)/sntp/libopts/libopts.la'
15696    fi
15697fi
15698
15699
15700  # Check whether --enable-libopts-install was given.
15701if test "${enable_libopts_install+set}" = set; then :
15702  enableval=$enable_libopts_install;
15703fi
15704
15705   if test "X${enable_libopts_install}" = Xyes; then
15706  INSTALL_LIBOPTS_TRUE=
15707  INSTALL_LIBOPTS_FALSE='#'
15708else
15709  INSTALL_LIBOPTS_TRUE='#'
15710  INSTALL_LIBOPTS_FALSE=
15711fi
15712
15713
15714  if test -z "${NEED_LIBOPTS_DIR}" ; then
15715     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether autoopts-config can be found" >&5
15716$as_echo_n "checking whether autoopts-config can be found... " >&6; }
15717
15718# Check whether --with-autoopts-config was given.
15719if test "${with_autoopts_config+set}" = set; then :
15720  withval=$with_autoopts_config; lo_cv_with_autoopts_config=${with_autoopts_config}
15721else
15722  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether autoopts-config is specified" >&5
15723$as_echo_n "checking whether autoopts-config is specified... " >&6; }
15724if ${lo_cv_with_autoopts_config+:} false; then :
15725  $as_echo_n "(cached) " >&6
15726else
15727  if autoopts-config --help 2>/dev/null 1>&2
15728        then lo_cv_with_autoopts_config=autoopts-config
15729        elif libopts-config --help 2>/dev/null 1>&2
15730        then lo_cv_with_autoopts_config=libopts-config
15731        else lo_cv_with_autoopts_config=no ; fi
15732fi
15733{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lo_cv_with_autoopts_config" >&5
15734$as_echo "$lo_cv_with_autoopts_config" >&6; }
15735
15736fi
15737 # end of AC_ARG_WITH
15738
15739     if ${lo_cv_test_autoopts+:} false; then :
15740  $as_echo_n "(cached) " >&6
15741else
15742
15743        if test -z "${lo_cv_with_autoopts_config}" \
15744                -o X"${lo_cv_with_autoopts_config}" = Xno
15745        then
15746           if autoopts-config --help 2>/dev/null 1>&2
15747           then lo_cv_with_autoopts_config=autoopts-config
15748           elif libopts-config --help 2>/dev/null 1>&2
15749           then lo_cv_with_autoopts_config=libopts-config
15750           else lo_cv_with_autoopts_config=false ; fi
15751        fi
15752        lo_cv_test_autoopts=`
15753            ${lo_cv_with_autoopts_config} --libs` 2> /dev/null
15754        if test $? -ne 0 -o -z "${lo_cv_test_autoopts}"
15755        then lo_cv_test_autoopts=no ; fi
15756
15757fi
15758 # end of CACHE_VAL
15759     { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lo_cv_test_autoopts}" >&5
15760$as_echo "${lo_cv_test_autoopts}" >&6; }
15761
15762     if test "X${lo_cv_test_autoopts}" != Xno
15763     then
15764        LIBOPTS_LDADD="${lo_cv_test_autoopts}"
15765        LIBOPTS_CFLAGS="`${lo_cv_with_autoopts_config} --cflags`"
15766     else
15767        LIBOPTS_LDADD='$(top_builddir)/sntp/libopts/libopts.la'
15768        LIBOPTS_CFLAGS='-I$(top_srcdir)/sntp/libopts'
15769        NEED_LIBOPTS_DIR=true
15770     fi
15771  fi # end of if test -z "${NEED_LIBOPTS_DIR}"
15772  if test -n "${LIBOPTS_BUILD_BLOCKED}" ; then
15773    NEED_LIBOPTS_DIR=''
15774  fi
15775   if test -n "${NEED_LIBOPTS_DIR}"; then
15776  NEED_LIBOPTS_TRUE=
15777  NEED_LIBOPTS_FALSE='#'
15778else
15779  NEED_LIBOPTS_TRUE='#'
15780  NEED_LIBOPTS_FALSE=
15781fi
15782
15783
15784
15785  LIBOPTS_DIR=sntp/libopts
15786
15787
15788# end of AC_DEFUN of LIBOPTS_CHECK_COMMON
15789
15790  # end of AC_DEFUN of LIBOPTS_CHECK_NOBUILD
15791
15792
15793
15794
15795ntp_pkgconfig_min_version='0.15.0'
15796if test -n "$ac_tool_prefix"; then
15797  # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
15798set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
15799{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15800$as_echo_n "checking for $ac_word... " >&6; }
15801if ${ac_cv_path_PKG_CONFIG+:} false; then :
15802  $as_echo_n "(cached) " >&6
15803else
15804  case $PKG_CONFIG in
15805  [\\/]* | ?:[\\/]*)
15806  ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
15807  ;;
15808  *)
15809  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15810for as_dir in $PATH
15811do
15812  IFS=$as_save_IFS
15813  test -z "$as_dir" && as_dir=.
15814    for ac_exec_ext in '' $ac_executable_extensions; do
15815  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15816    ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
15817    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15818    break 2
15819  fi
15820done
15821  done
15822IFS=$as_save_IFS
15823
15824  ;;
15825esac
15826fi
15827PKG_CONFIG=$ac_cv_path_PKG_CONFIG
15828if test -n "$PKG_CONFIG"; then
15829  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
15830$as_echo "$PKG_CONFIG" >&6; }
15831else
15832  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15833$as_echo "no" >&6; }
15834fi
15835
15836
15837fi
15838if test -z "$ac_cv_path_PKG_CONFIG"; then
15839  ac_pt_PKG_CONFIG=$PKG_CONFIG
15840  # Extract the first word of "pkg-config", so it can be a program name with args.
15841set dummy pkg-config; ac_word=$2
15842{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15843$as_echo_n "checking for $ac_word... " >&6; }
15844if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then :
15845  $as_echo_n "(cached) " >&6
15846else
15847  case $ac_pt_PKG_CONFIG in
15848  [\\/]* | ?:[\\/]*)
15849  ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
15850  ;;
15851  *)
15852  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15853for as_dir in $PATH
15854do
15855  IFS=$as_save_IFS
15856  test -z "$as_dir" && as_dir=.
15857    for ac_exec_ext in '' $ac_executable_extensions; do
15858  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15859    ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
15860    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15861    break 2
15862  fi
15863done
15864  done
15865IFS=$as_save_IFS
15866
15867  ;;
15868esac
15869fi
15870ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
15871if test -n "$ac_pt_PKG_CONFIG"; then
15872  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
15873$as_echo "$ac_pt_PKG_CONFIG" >&6; }
15874else
15875  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15876$as_echo "no" >&6; }
15877fi
15878
15879  if test "x$ac_pt_PKG_CONFIG" = x; then
15880    PKG_CONFIG=""
15881  else
15882    case $cross_compiling:$ac_tool_warned in
15883yes:)
15884{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
15885$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
15886ac_tool_warned=yes ;;
15887esac
15888    PKG_CONFIG=$ac_pt_PKG_CONFIG
15889  fi
15890else
15891  PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
15892fi
15893
15894{ ac_cv_path_PKG_CONFIG=; unset ac_cv_path_PKG_CONFIG;}
15895{ ac_cv_path_ac_pt_PKG_CONFIG=; unset ac_cv_path_ac_pt_PKG_CONFIG;}
15896
15897case "$PKG_CONFIG" in
15898 /*)
15899    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if pkg-config is at least version $ntp_pkgconfig_min_version" >&5
15900$as_echo_n "checking if pkg-config is at least version $ntp_pkgconfig_min_version... " >&6; }
15901    if $PKG_CONFIG --atleast-pkgconfig-version $ntp_pkgconfig_min_version; then
15902	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15903$as_echo "yes" >&6; }
15904    else
15905	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15906$as_echo "no" >&6; }
15907	PKG_CONFIG=""
15908    fi
15909    ;;
15910esac
15911
15912
15913
15914
15915# Check whether --enable-local-libevent was given.
15916if test "${enable_local_libevent+set}" = set; then :
15917  enableval=$enable_local_libevent; ntp_use_local_libevent=$enableval
15918else
15919  ntp_use_local_libevent=${ntp_use_local_libevent-detect}
15920
15921fi
15922
15923
15924
15925
15926
15927ntp_libevent_min_version=2
15928ntp_libevent_tearoff=sntp/libevent
15929
15930
15931
15932
15933
15934case "$ntp_use_local_libevent" in
15935 yes)
15936    ;;
15937 *) # If we have (a good enough) pkg-config, see if it can find libevent
15938    case "$PKG_CONFIG" in
15939     /*)
15940	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if libevent $ntp_libevent_min_version or later is installed" >&5
15941$as_echo_n "checking if libevent $ntp_libevent_min_version or later is installed... " >&6; }
15942	if $PKG_CONFIG --atleast-version=$ntp_libevent_min_version libevent
15943	then
15944	    ntp_use_local_libevent=no
15945	    ntp_libevent_version="`$PKG_CONFIG --modversion libevent`"
15946	    case "$ntp_libevent_version" in
15947	     *.*) ;;
15948	     *) ntp_libevent_version='(unknown)' ;;
15949	    esac
15950	    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, version $ntp_libevent_version" >&5
15951$as_echo "yes, version $ntp_libevent_version" >&6; }
15952	    CFLAGS_LIBEVENT=`$PKG_CONFIG --cflags libevent_pthreads`
15953	    CPPFLAGS_LIBEVENT=`$PKG_CONFIG --cflags-only-I libevent`
15954	    # HMS: I hope the following is accurate.
15955	    # We don't need -levent, we only need  -levent_core.
15956	    # While we could grab only the -L stuff, there *might* be
15957	    # other flags there we want.  Originally we just removed -levent
15958	    # but then somebody decided to install -levent-2.0
15959	    # LDADD_LIBEVENT=`$PKG_CONFIG --libs libevent | sed 's:-levent::'`
15960	    # So now we dance...
15961	    LDADD_LIBEVENT=
15962	    for i in `$PKG_CONFIG --libs libevent` `$PKG_CONFIG --cflags-only-other libevent_pthreads`
15963	    do
15964		case "$i" in
15965		 -D*) ;;
15966		 -levent*) ;;
15967		 *) case "$LDADD_LIBEVENT" in
15968		     '') LDADD_LIBEVENT="$i" ;;
15969		     *) LDADD_LIBEVENT="$LDADD_LIBEVENT $i" ;;
15970		    esac
15971		    ;;
15972		esac
15973	    done
15974	    case "$LIBISC_PTHREADS_NOTHREADS" in
15975	     pthreads)
15976		LDADD_LIBEVENT="$LDADD_LIBEVENT -levent_pthreads"
15977	    esac
15978	    LDADD_LIBEVENT="$LDADD_LIBEVENT -levent_core"
15979	else
15980	    ntp_use_local_libevent=yes
15981	    # HMS: do we only need to do this if LIBISC_PTHREADS_NOTHREADS
15982	    # is "pthreads"?
15983	    CFLAGS_LIBEVENT=`$PKG_CONFIG --cflags libevent_pthreads`
15984	    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15985$as_echo "no" >&6; }
15986	fi
15987	;;
15988     *)
15989	ntp_use_local_libevent=yes
15990	;;
15991    esac
15992    ;;
15993esac
15994
15995case "$ntp_use_local_libevent" in
15996 yes)
15997    { $as_echo "$as_me:${as_lineno-$LINENO}: Using libevent tearoff" >&5
15998$as_echo "$as_me: Using libevent tearoff" >&6;}
15999    CPPFLAGS_LIBEVENT="-I\$(top_builddir)/$ntp_libevent_tearoff/include -I\$(top_srcdir)/$ntp_libevent_tearoff/include"
16000    case "$LIBISC_PTHREADS_NOTHREADS" in
16001     pthreads)
16002	LDADD_LIBEVENT="\$(top_builddir)/$ntp_libevent_tearoff/libevent_pthreads.la \$(top_builddir)/$ntp_libevent_tearoff/libevent_core.la"
16003	;;
16004     *)
16005	LDADD_LIBEVENT="\$(top_builddir)/$ntp_libevent_tearoff/libevent_core.la"
16006    esac
16007esac
16008
16009
16010 if test "x$ntp_use_local_libevent" = "xyes"; then
16011  BUILD_LIBEVENT_TRUE=
16012  BUILD_LIBEVENT_FALSE='#'
16013else
16014  BUILD_LIBEVENT_TRUE='#'
16015  BUILD_LIBEVENT_FALSE=
16016fi
16017
16018
16019
16020
16021
16022
16023# Expose a cross-compilation indicator to makefiles
16024 if test $build != $host; then
16025  NTP_CROSSCOMPILE_TRUE=
16026  NTP_CROSSCOMPILE_FALSE='#'
16027else
16028  NTP_CROSSCOMPILE_TRUE='#'
16029  NTP_CROSSCOMPILE_FALSE=
16030fi
16031
16032
16033
16034ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
16035if test "x$ac_cv_type_size_t" = xyes; then :
16036
16037else
16038
16039cat >>confdefs.h <<_ACEOF
16040#define size_t unsigned int
16041_ACEOF
16042
16043fi
16044
16045
16046            # Check whether --enable-c99-snprintf was given.
16047if test "${enable_c99_snprintf+set}" = set; then :
16048  enableval=$enable_c99_snprintf; force_c99_snprintf=$enableval
16049else
16050  force_c99_snprintf=no
16051
16052fi
16053
16054    case "$force_c99_snprintf" in
16055     yes)
16056	hw_force_rpl_snprintf=yes
16057	hw_force_rpl_vsnprintf=yes
16058    esac
16059
16060
16061
16062
16063
16064
16065  for ac_header in $ac_header_list
16066do :
16067  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
16068ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
16069"
16070if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
16071  cat >>confdefs.h <<_ACEOF
16072#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
16073_ACEOF
16074
16075fi
16076
16077done
16078
16079
16080
16081
16082
16083
16084
16085  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
16086$as_echo_n "checking for unsigned long long int... " >&6; }
16087if ${ac_cv_type_unsigned_long_long_int+:} false; then :
16088  $as_echo_n "(cached) " >&6
16089else
16090  ac_cv_type_unsigned_long_long_int=yes
16091     if test "x${ac_cv_prog_cc_c99-no}" = xno; then
16092       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16093/* end confdefs.h.  */
16094
16095  /* For now, do not test the preprocessor; as of 2007 there are too many
16096	 implementations with broken preprocessors.  Perhaps this can
16097	 be revisited in 2012.  In the meantime, code should not expect
16098	 #if to work with literals wider than 32 bits.  */
16099      /* Test literals.  */
16100      long long int ll = 9223372036854775807ll;
16101      long long int nll = -9223372036854775807LL;
16102      unsigned long long int ull = 18446744073709551615ULL;
16103      /* Test constant expressions.   */
16104      typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
16105		     ? 1 : -1)];
16106      typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
16107		     ? 1 : -1)];
16108      int i = 63;
16109int
16110main ()
16111{
16112/* Test availability of runtime routines for shift and division.  */
16113      long long int llmax = 9223372036854775807ll;
16114      unsigned long long int ullmax = 18446744073709551615ull;
16115      return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
16116	      | (llmax / ll) | (llmax % ll)
16117	      | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
16118	      | (ullmax / ull) | (ullmax % ull));
16119  ;
16120  return 0;
16121}
16122
16123_ACEOF
16124if ac_fn_c_try_link "$LINENO"; then :
16125
16126else
16127  ac_cv_type_unsigned_long_long_int=no
16128fi
16129rm -f core conftest.err conftest.$ac_objext \
16130    conftest$ac_exeext conftest.$ac_ext
16131     fi
16132fi
16133{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
16134$as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
16135  if test $ac_cv_type_unsigned_long_long_int = yes; then
16136
16137$as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
16138
16139  fi
16140
16141
16142      ac_fn_c_check_func "$LINENO" "vsnprintf" "ac_cv_func_vsnprintf"
16143if test "x$ac_cv_func_vsnprintf" = xyes; then :
16144  hw_cv_func_vsnprintf=yes
16145else
16146  hw_cv_func_vsnprintf=no
16147fi
16148
16149  if test "$hw_cv_func_vsnprintf" = yes; then :
16150  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether vsnprintf is C99 compliant" >&5
16151$as_echo_n "checking whether vsnprintf is C99 compliant... " >&6; }
16152if ${hw_cv_func_vsnprintf_c99+:} false; then :
16153  $as_echo_n "(cached) " >&6
16154else
16155  if test "$cross_compiling" = yes; then :
16156  hw_cv_func_vsnprintf_c99=no
16157else
16158  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16159/* end confdefs.h.  */
16160#if HAVE_STDARG_H
16161          #include <stdarg.h>
16162          #endif
16163          #include <stdio.h>
16164          static int testprintf(char *buf, size_t size, const char *format, ...)
16165          {
16166            int result;
16167            va_list ap;
16168            va_start(ap, format);
16169            result = vsnprintf(buf, size, format, ap);
16170            va_end(ap);
16171            return result;
16172          }
16173int
16174main ()
16175{
16176char buf[43];
16177          if (testprintf(buf, 4, "The answer is %27.2g.", 42.0) != 42 ||
16178              testprintf(buf, 0, "No, it's %32zu.", (size_t)42) != 42 ||
16179              buf[0] != 'T' || buf[3] != '\0')
16180            return 1;
16181  ;
16182  return 0;
16183}
16184_ACEOF
16185if ac_fn_c_try_run "$LINENO"; then :
16186  hw_cv_func_vsnprintf_c99=yes
16187else
16188  hw_cv_func_vsnprintf_c99=no
16189fi
16190rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16191  conftest.$ac_objext conftest.beam conftest.$ac_ext
16192fi
16193
16194fi
16195{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hw_cv_func_vsnprintf_c99" >&5
16196$as_echo "$hw_cv_func_vsnprintf_c99" >&6; }
16197else
16198  hw_cv_func_vsnprintf_c99=no
16199fi
16200
16201$as_echo "#define HAVE_VSNPRINTF 1" >>confdefs.h
16202
16203  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if C99-snprintf replacement vsnprintf will be used" >&5
16204$as_echo_n "checking if C99-snprintf replacement vsnprintf will be used... " >&6; }
16205  if test "${hw_force_rpl_vsnprintf=no}" = yes -o "$hw_cv_func_vsnprintf_c99" = no; then :
16206  hw_use_rpl_vsnprintf=yes
16207else
16208  hw_use_rpl_vsnprintf=no
16209fi
16210  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hw_use_rpl_vsnprintf" >&5
16211$as_echo "$hw_use_rpl_vsnprintf" >&6; }
16212  if test "$hw_use_rpl_vsnprintf" = yes; then :
16213
16214$as_echo "#define HW_WANT_RPL_VSNPRINTF 1" >>confdefs.h
16215
16216    if test ${hw_nodef_vsnprintf=no} = no; then :
16217
16218$as_echo "#define vsnprintf rpl_vsnprintf" >>confdefs.h
16219
16220fi
16221    for ac_header in inttypes.h locale.h stddef.h stdint.h
16222do :
16223  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
16224ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
16225if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
16226  cat >>confdefs.h <<_ACEOF
16227#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
16228_ACEOF
16229
16230fi
16231
16232done
16233
16234    ac_fn_c_check_member "$LINENO" "struct lconv" "decimal_point" "ac_cv_member_struct_lconv_decimal_point" "#include <locale.h>
16235"
16236if test "x$ac_cv_member_struct_lconv_decimal_point" = xyes; then :
16237
16238cat >>confdefs.h <<_ACEOF
16239#define HAVE_STRUCT_LCONV_DECIMAL_POINT 1
16240_ACEOF
16241
16242
16243fi
16244ac_fn_c_check_member "$LINENO" "struct lconv" "thousands_sep" "ac_cv_member_struct_lconv_thousands_sep" "#include <locale.h>
16245"
16246if test "x$ac_cv_member_struct_lconv_thousands_sep" = xyes; then :
16247
16248cat >>confdefs.h <<_ACEOF
16249#define HAVE_STRUCT_LCONV_THOUSANDS_SEP 1
16250_ACEOF
16251
16252
16253fi
16254
16255
16256  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double" >&5
16257$as_echo_n "checking for long double... " >&6; }
16258if ${ac_cv_type_long_double+:} false; then :
16259  $as_echo_n "(cached) " >&6
16260else
16261  if test "$GCC" = yes; then
16262       ac_cv_type_long_double=yes
16263     else
16264       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16265/* end confdefs.h.  */
16266/* The Stardent Vistra knows sizeof (long double), but does
16267		 not support it.  */
16268	      long double foo = 0.0L;
16269int
16270main ()
16271{
16272static int test_array [1 - 2 * !(/* On Ultrix 4.3 cc, long double is 4 and double is 8.  */
16273	      sizeof (double) <= sizeof (long double))];
16274test_array [0] = 0;
16275return test_array [0];
16276
16277  ;
16278  return 0;
16279}
16280_ACEOF
16281if ac_fn_c_try_compile "$LINENO"; then :
16282  ac_cv_type_long_double=yes
16283else
16284  ac_cv_type_long_double=no
16285fi
16286rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16287     fi
16288fi
16289{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_double" >&5
16290$as_echo "$ac_cv_type_long_double" >&6; }
16291  if test $ac_cv_type_long_double = yes; then
16292
16293$as_echo "#define HAVE_LONG_DOUBLE 1" >>confdefs.h
16294
16295  fi
16296
16297
16298
16299  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
16300$as_echo_n "checking for long long int... " >&6; }
16301if ${ac_cv_type_long_long_int+:} false; then :
16302  $as_echo_n "(cached) " >&6
16303else
16304  ac_cv_type_long_long_int=yes
16305      if test "x${ac_cv_prog_cc_c99-no}" = xno; then
16306	ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
16307	if test $ac_cv_type_long_long_int = yes; then
16308	  	  	  	  if test "$cross_compiling" = yes; then :
16309  :
16310else
16311  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16312/* end confdefs.h.  */
16313#include <limits.h>
16314		 #ifndef LLONG_MAX
16315		 # define HALF \
16316			  (1LL << (sizeof (long long int) * CHAR_BIT - 2))
16317		 # define LLONG_MAX (HALF - 1 + HALF)
16318		 #endif
16319int
16320main ()
16321{
16322long long int n = 1;
16323		 int i;
16324		 for (i = 0; ; i++)
16325		   {
16326		     long long int m = n << i;
16327		     if (m >> i != n)
16328		       return 1;
16329		     if (LLONG_MAX / 2 < m)
16330		       break;
16331		   }
16332		 return 0;
16333  ;
16334  return 0;
16335}
16336_ACEOF
16337if ac_fn_c_try_run "$LINENO"; then :
16338
16339else
16340  ac_cv_type_long_long_int=no
16341fi
16342rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16343  conftest.$ac_objext conftest.beam conftest.$ac_ext
16344fi
16345
16346	fi
16347      fi
16348fi
16349{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
16350$as_echo "$ac_cv_type_long_long_int" >&6; }
16351  if test $ac_cv_type_long_long_int = yes; then
16352
16353$as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
16354
16355  fi
16356
16357
16358  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
16359$as_echo_n "checking for unsigned long long int... " >&6; }
16360if ${ac_cv_type_unsigned_long_long_int+:} false; then :
16361  $as_echo_n "(cached) " >&6
16362else
16363  ac_cv_type_unsigned_long_long_int=yes
16364     if test "x${ac_cv_prog_cc_c99-no}" = xno; then
16365       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16366/* end confdefs.h.  */
16367
16368  /* For now, do not test the preprocessor; as of 2007 there are too many
16369	 implementations with broken preprocessors.  Perhaps this can
16370	 be revisited in 2012.  In the meantime, code should not expect
16371	 #if to work with literals wider than 32 bits.  */
16372      /* Test literals.  */
16373      long long int ll = 9223372036854775807ll;
16374      long long int nll = -9223372036854775807LL;
16375      unsigned long long int ull = 18446744073709551615ULL;
16376      /* Test constant expressions.   */
16377      typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
16378		     ? 1 : -1)];
16379      typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
16380		     ? 1 : -1)];
16381      int i = 63;
16382int
16383main ()
16384{
16385/* Test availability of runtime routines for shift and division.  */
16386      long long int llmax = 9223372036854775807ll;
16387      unsigned long long int ullmax = 18446744073709551615ull;
16388      return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
16389	      | (llmax / ll) | (llmax % ll)
16390	      | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
16391	      | (ullmax / ull) | (ullmax % ull));
16392  ;
16393  return 0;
16394}
16395
16396_ACEOF
16397if ac_fn_c_try_link "$LINENO"; then :
16398
16399else
16400  ac_cv_type_unsigned_long_long_int=no
16401fi
16402rm -f core conftest.err conftest.$ac_objext \
16403    conftest$ac_exeext conftest.$ac_ext
16404     fi
16405fi
16406{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
16407$as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
16408  if test $ac_cv_type_unsigned_long_long_int = yes; then
16409
16410$as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
16411
16412  fi
16413
16414    ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
16415if test "x$ac_cv_type_size_t" = xyes; then :
16416
16417else
16418
16419cat >>confdefs.h <<_ACEOF
16420#define size_t unsigned int
16421_ACEOF
16422
16423fi
16424
16425
16426
16427  ac_fn_c_check_type "$LINENO" "intmax_t" "ac_cv_type_intmax_t" "$ac_includes_default"
16428if test "x$ac_cv_type_intmax_t" = xyes; then :
16429
16430$as_echo "#define HAVE_INTMAX_T 1" >>confdefs.h
16431
16432else
16433  test $ac_cv_type_long_long_int = yes \
16434       && ac_type='long long int' \
16435       || ac_type='long int'
16436
16437cat >>confdefs.h <<_ACEOF
16438#define intmax_t $ac_type
16439_ACEOF
16440
16441fi
16442
16443
16444
16445
16446  ac_fn_c_check_type "$LINENO" "uintmax_t" "ac_cv_type_uintmax_t" "$ac_includes_default"
16447if test "x$ac_cv_type_uintmax_t" = xyes; then :
16448
16449$as_echo "#define HAVE_UINTMAX_T 1" >>confdefs.h
16450
16451else
16452  test $ac_cv_type_unsigned_long_long_int = yes \
16453       && ac_type='unsigned long long int' \
16454       || ac_type='unsigned long int'
16455
16456cat >>confdefs.h <<_ACEOF
16457#define uintmax_t $ac_type
16458_ACEOF
16459
16460fi
16461
16462
16463
16464  ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default"
16465if test "x$ac_cv_type_uintptr_t" = xyes; then :
16466
16467$as_echo "#define HAVE_UINTPTR_T 1" >>confdefs.h
16468
16469else
16470  for ac_type in 'unsigned int' 'unsigned long int' \
16471	'unsigned long long int'; do
16472       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16473/* end confdefs.h.  */
16474$ac_includes_default
16475int
16476main ()
16477{
16478static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))];
16479test_array [0] = 0;
16480return test_array [0];
16481
16482  ;
16483  return 0;
16484}
16485_ACEOF
16486if ac_fn_c_try_compile "$LINENO"; then :
16487
16488cat >>confdefs.h <<_ACEOF
16489#define uintptr_t $ac_type
16490_ACEOF
16491
16492	  ac_type=
16493fi
16494rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16495       test -z "$ac_type" && break
16496     done
16497fi
16498
16499
16500    ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default"
16501if test "x$ac_cv_type_ptrdiff_t" = xyes; then :
16502
16503cat >>confdefs.h <<_ACEOF
16504#define HAVE_PTRDIFF_T 1
16505_ACEOF
16506
16507
16508fi
16509
16510    for ac_func in localeconv
16511do :
16512  ac_fn_c_check_func "$LINENO" "localeconv" "ac_cv_func_localeconv"
16513if test "x$ac_cv_func_localeconv" = xyes; then :
16514  cat >>confdefs.h <<_ACEOF
16515#define HAVE_LOCALECONV 1
16516_ACEOF
16517
16518fi
16519done
16520
16521
16522  if test "x$_hw_cv_func_xprintf_replace_done" != xyes; then :
16523  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
16524$as_echo_n "checking for an ANSI C-conforming const... " >&6; }
16525if ${ac_cv_c_const+:} false; then :
16526  $as_echo_n "(cached) " >&6
16527else
16528  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16529/* end confdefs.h.  */
16530
16531int
16532main ()
16533{
16534
16535#ifndef __cplusplus
16536  /* Ultrix mips cc rejects this sort of thing.  */
16537  typedef int charset[2];
16538  const charset cs = { 0, 0 };
16539  /* SunOS 4.1.1 cc rejects this.  */
16540  char const *const *pcpcc;
16541  char **ppc;
16542  /* NEC SVR4.0.2 mips cc rejects this.  */
16543  struct point {int x, y;};
16544  static struct point const zero = {0,0};
16545  /* AIX XL C 1.02.0.0 rejects this.
16546     It does not let you subtract one const X* pointer from another in
16547     an arm of an if-expression whose if-part is not a constant
16548     expression */
16549  const char *g = "string";
16550  pcpcc = &g + (g ? g-g : 0);
16551  /* HPUX 7.0 cc rejects these. */
16552  ++pcpcc;
16553  ppc = (char**) pcpcc;
16554  pcpcc = (char const *const *) ppc;
16555  { /* SCO 3.2v4 cc rejects this sort of thing.  */
16556    char tx;
16557    char *t = &tx;
16558    char const *s = 0 ? (char *) 0 : (char const *) 0;
16559
16560    *t++ = 0;
16561    if (s) return 0;
16562  }
16563  { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
16564    int x[] = {25, 17};
16565    const int *foo = &x[0];
16566    ++foo;
16567  }
16568  { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
16569    typedef const int *iptr;
16570    iptr p = 0;
16571    ++p;
16572  }
16573  { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying
16574       "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
16575    struct s { int j; const int *ap[3]; } bx;
16576    struct s *b = &bx; b->j = 5;
16577  }
16578  { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
16579    const int foo = 10;
16580    if (!foo) return 0;
16581  }
16582  return !cs[0] && !zero.x;
16583#endif
16584
16585  ;
16586  return 0;
16587}
16588_ACEOF
16589if ac_fn_c_try_compile "$LINENO"; then :
16590  ac_cv_c_const=yes
16591else
16592  ac_cv_c_const=no
16593fi
16594rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16595fi
16596{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
16597$as_echo "$ac_cv_c_const" >&6; }
16598if test $ac_cv_c_const = no; then
16599
16600$as_echo "#define const /**/" >>confdefs.h
16601
16602fi
16603
16604
16605
16606
16607    case " $LIBOBJS " in
16608  *" snprintf.$ac_objext "* ) ;;
16609  *) LIBOBJS="$LIBOBJS snprintf.$ac_objext"
16610 ;;
16611esac
16612
16613    _hw_cv_func_xprintf_replace_done=yes
16614fi
16615
16616fi
16617
16618
16619    ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
16620if test "x$ac_cv_func_snprintf" = xyes; then :
16621  hw_cv_func_snprintf=yes
16622else
16623  hw_cv_func_snprintf=no
16624fi
16625
16626  if test "$hw_cv_func_snprintf" = yes; then :
16627  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether snprintf is C99 compliant" >&5
16628$as_echo_n "checking whether snprintf is C99 compliant... " >&6; }
16629if ${hw_cv_func_snprintf_c99+:} false; then :
16630  $as_echo_n "(cached) " >&6
16631else
16632  if test "$cross_compiling" = yes; then :
16633  hw_cv_func_snprintf_c99=no
16634else
16635  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16636/* end confdefs.h.  */
16637#include <stdio.h>
16638int
16639main ()
16640{
16641char buf[43];
16642          if (snprintf(buf, 4, "The answer is %27.2g.", 42.0) != 42 ||
16643              snprintf(buf, 0, "No, it's %32zu.", (size_t)42) != 42 ||
16644              buf[0] != 'T' || buf[3] != '\0')
16645            return 1;
16646  ;
16647  return 0;
16648}
16649_ACEOF
16650if ac_fn_c_try_run "$LINENO"; then :
16651  hw_cv_func_snprintf_c99=yes
16652else
16653  hw_cv_func_snprintf_c99=no
16654fi
16655rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16656  conftest.$ac_objext conftest.beam conftest.$ac_ext
16657fi
16658
16659fi
16660{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hw_cv_func_snprintf_c99" >&5
16661$as_echo "$hw_cv_func_snprintf_c99" >&6; }
16662else
16663  hw_cv_func_snprintf_c99=no
16664fi
16665
16666$as_echo "#define HAVE_SNPRINTF 1" >>confdefs.h
16667
16668  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if C99-snprintf replacement snprintf will be used" >&5
16669$as_echo_n "checking if C99-snprintf replacement snprintf will be used... " >&6; }
16670  if test "${hw_force_rpl_snprintf=no}" = yes -o "$hw_cv_func_snprintf_c99" = no; then :
16671  hw_use_rpl_snprintf=yes
16672else
16673  hw_use_rpl_snprintf=no
16674fi
16675  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hw_use_rpl_snprintf" >&5
16676$as_echo "$hw_use_rpl_snprintf" >&6; }
16677  if test "$hw_use_rpl_snprintf" = yes; then :
16678
16679$as_echo "#define HW_WANT_RPL_SNPRINTF 1" >>confdefs.h
16680
16681    if test ${hw_nodef_snprintf=no} = no; then :
16682
16683$as_echo "#define snprintf rpl_snprintf" >>confdefs.h
16684
16685fi
16686
16687  if test "x$_hw_cv_func_xprintf_replace_done" != xyes; then :
16688  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
16689$as_echo_n "checking for an ANSI C-conforming const... " >&6; }
16690if ${ac_cv_c_const+:} false; then :
16691  $as_echo_n "(cached) " >&6
16692else
16693  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16694/* end confdefs.h.  */
16695
16696int
16697main ()
16698{
16699
16700#ifndef __cplusplus
16701  /* Ultrix mips cc rejects this sort of thing.  */
16702  typedef int charset[2];
16703  const charset cs = { 0, 0 };
16704  /* SunOS 4.1.1 cc rejects this.  */
16705  char const *const *pcpcc;
16706  char **ppc;
16707  /* NEC SVR4.0.2 mips cc rejects this.  */
16708  struct point {int x, y;};
16709  static struct point const zero = {0,0};
16710  /* AIX XL C 1.02.0.0 rejects this.
16711     It does not let you subtract one const X* pointer from another in
16712     an arm of an if-expression whose if-part is not a constant
16713     expression */
16714  const char *g = "string";
16715  pcpcc = &g + (g ? g-g : 0);
16716  /* HPUX 7.0 cc rejects these. */
16717  ++pcpcc;
16718  ppc = (char**) pcpcc;
16719  pcpcc = (char const *const *) ppc;
16720  { /* SCO 3.2v4 cc rejects this sort of thing.  */
16721    char tx;
16722    char *t = &tx;
16723    char const *s = 0 ? (char *) 0 : (char const *) 0;
16724
16725    *t++ = 0;
16726    if (s) return 0;
16727  }
16728  { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
16729    int x[] = {25, 17};
16730    const int *foo = &x[0];
16731    ++foo;
16732  }
16733  { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
16734    typedef const int *iptr;
16735    iptr p = 0;
16736    ++p;
16737  }
16738  { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying
16739       "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
16740    struct s { int j; const int *ap[3]; } bx;
16741    struct s *b = &bx; b->j = 5;
16742  }
16743  { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
16744    const int foo = 10;
16745    if (!foo) return 0;
16746  }
16747  return !cs[0] && !zero.x;
16748#endif
16749
16750  ;
16751  return 0;
16752}
16753_ACEOF
16754if ac_fn_c_try_compile "$LINENO"; then :
16755  ac_cv_c_const=yes
16756else
16757  ac_cv_c_const=no
16758fi
16759rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16760fi
16761{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
16762$as_echo "$ac_cv_c_const" >&6; }
16763if test $ac_cv_c_const = no; then
16764
16765$as_echo "#define const /**/" >>confdefs.h
16766
16767fi
16768
16769
16770
16771
16772    case " $LIBOBJS " in
16773  *" snprintf.$ac_objext "* ) ;;
16774  *) LIBOBJS="$LIBOBJS snprintf.$ac_objext"
16775 ;;
16776esac
16777
16778    _hw_cv_func_xprintf_replace_done=yes
16779fi
16780
16781fi
16782
16783
16784
16785
16786
16787# HMS: Save $LIBS and empty it.
16788# any LIBS we add here should go in to LDADD_LIBNTP
16789
16790__LIBS=$LIBS
16791LIBS=
16792
16793
16794
16795# [Bug 2332] because we need to know if we are using GNU ld...
16796
16797
16798# Check whether --with-gnu-ld was given.
16799if test "${with_gnu_ld+set}" = set; then :
16800  withval=$with_gnu_ld; test no = "$withval" || with_gnu_ld=yes
16801else
16802  with_gnu_ld=no
16803fi
16804
16805ac_prog=ld
16806if test yes = "$GCC"; then
16807  # Check if gcc -print-prog-name=ld gives a path.
16808  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
16809$as_echo_n "checking for ld used by $CC... " >&6; }
16810  case $host in
16811  *-*-mingw*)
16812    # gcc leaves a trailing carriage return, which upsets mingw
16813    ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
16814  *)
16815    ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
16816  esac
16817  case $ac_prog in
16818    # Accept absolute paths.
16819    [\\/]* | ?:[\\/]*)
16820      re_direlt='/[^/][^/]*/\.\./'
16821      # Canonicalize the pathname of ld
16822      ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
16823      while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
16824	ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
16825      done
16826      test -z "$LD" && LD=$ac_prog
16827      ;;
16828  "")
16829    # If it fails, then pretend we aren't using GCC.
16830    ac_prog=ld
16831    ;;
16832  *)
16833    # If it is relative, then search for the first ld in PATH.
16834    with_gnu_ld=unknown
16835    ;;
16836  esac
16837elif test yes = "$with_gnu_ld"; then
16838  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
16839$as_echo_n "checking for GNU ld... " >&6; }
16840else
16841  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
16842$as_echo_n "checking for non-GNU ld... " >&6; }
16843fi
16844if ${lt_cv_path_LD+:} false; then :
16845  $as_echo_n "(cached) " >&6
16846else
16847  if test -z "$LD"; then
16848  lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
16849  for ac_dir in $PATH; do
16850    IFS=$lt_save_ifs
16851    test -z "$ac_dir" && ac_dir=.
16852    if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
16853      lt_cv_path_LD=$ac_dir/$ac_prog
16854      # Check to see if the program is GNU ld.  I'd rather use --version,
16855      # but apparently some variants of GNU ld only accept -v.
16856      # Break only if it was the GNU/non-GNU ld that we prefer.
16857      case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
16858      *GNU* | *'with BFD'*)
16859	test no != "$with_gnu_ld" && break
16860	;;
16861      *)
16862	test yes != "$with_gnu_ld" && break
16863	;;
16864      esac
16865    fi
16866  done
16867  IFS=$lt_save_ifs
16868else
16869  lt_cv_path_LD=$LD # Let the user override the test with a path.
16870fi
16871fi
16872
16873LD=$lt_cv_path_LD
16874if test -n "$LD"; then
16875  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
16876$as_echo "$LD" >&6; }
16877else
16878  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16879$as_echo "no" >&6; }
16880fi
16881test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
16882{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
16883$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
16884if ${lt_cv_prog_gnu_ld+:} false; then :
16885  $as_echo_n "(cached) " >&6
16886else
16887  # I'd rather use --version here, but apparently some GNU lds only accept -v.
16888case `$LD -v 2>&1 </dev/null` in
16889*GNU* | *'with BFD'*)
16890  lt_cv_prog_gnu_ld=yes
16891  ;;
16892*)
16893  lt_cv_prog_gnu_ld=no
16894  ;;
16895esac
16896fi
16897{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5
16898$as_echo "$lt_cv_prog_gnu_ld" >&6; }
16899with_gnu_ld=$lt_cv_prog_gnu_ld
16900
16901
16902
16903
16904
16905
16906
16907
16908{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for directory path separator" >&5
16909$as_echo_n "checking for directory path separator... " >&6; }
16910if ${ntp_cv_dir_sep+:} false; then :
16911  $as_echo_n "(cached) " >&6
16912else
16913
16914	case "$ntp_cv_dir_sep" in
16915	 '')
16916	    case "$host_os" in
16917	     *djgpp | *mingw32* | *emx*)
16918		ntp_cv_dir_sep="'\\'"
16919		;;
16920	     *)
16921		ntp_cv_dir_sep="'/'"
16922		;;
16923	    esac
16924	esac
16925
16926
16927fi
16928{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_dir_sep" >&5
16929$as_echo "$ntp_cv_dir_sep" >&6; }
16930
16931cat >>confdefs.h <<_ACEOF
16932#define DIR_SEP $ntp_cv_dir_sep
16933_ACEOF
16934
16935
16936
16937    NTP_ORIG_LIBS="$LIBS"
16938
16939# Check whether --with-lineeditlibs was given.
16940if test "${with_lineeditlibs+set}" = set; then :
16941  withval=$with_lineeditlibs; use_lineeditlibs="$withval"
16942else
16943  use_lineeditlibs="edit,editline"
16944
16945fi
16946
16947    { $as_echo "$as_me:${as_lineno-$LINENO}: checking line editing libraries" >&5
16948$as_echo_n "checking line editing libraries... " >&6; }
16949    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $use_lineeditlibs" >&5
16950$as_echo "$use_lineeditlibs" >&6; }
16951    case "$use_lineeditlibs" in
16952     no)
16953	ntp_lib_lineedit=no
16954	;;
16955     *)
16956	for lineedit_lib in `echo $use_lineeditlibs | sed -e 's/,/ /'`; do
16957	    for term_lib in "" termcap curses ncurses; do
16958		case "$term_lib" in
16959		 '')
16960		    TRY_LIB="-l$lineedit_lib"
16961		    ;;
16962		 *)
16963		    TRY_LIB="-l$lineedit_lib -l$term_lib"
16964		    ;;
16965		esac
16966		LIBS="$NTP_ORIG_LIBS $TRY_LIB"
16967		{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for readline() with $TRY_LIB" >&5
16968$as_echo_n "checking for readline() with $TRY_LIB... " >&6; }
16969		cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16970/* end confdefs.h.  */
16971
16972/* Override any GCC internal prototype to avoid an error.
16973   Use char because int might match the return type of a GCC
16974   builtin and then its argument prototype would still apply.  */
16975#ifdef __cplusplus
16976extern "C"
16977#endif
16978char readline ();
16979int
16980main ()
16981{
16982return readline ();
16983  ;
16984  return 0;
16985}
16986_ACEOF
16987if ac_fn_c_try_link "$LINENO"; then :
16988  ntp_lib_lineedit="$TRY_LIB"
16989fi
16990rm -f core conftest.err conftest.$ac_objext \
16991    conftest$ac_exeext conftest.$ac_ext
16992		case "$ntp_lib_lineedit" in
16993		 '')
16994		    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16995$as_echo "no" >&6; }
16996		    ;;
16997		 *)
16998		    # Use readline()
16999		    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17000$as_echo "yes" >&6; }
17001		    break
17002		esac
17003		case "$term_lib" in
17004		 '')
17005		    # do not try el_gets without a terminal library
17006		    ;;
17007		 *)
17008		    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for el_gets() with $TRY_LIB" >&5
17009$as_echo_n "checking for el_gets() with $TRY_LIB... " >&6; }
17010		    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17011/* end confdefs.h.  */
17012
17013/* Override any GCC internal prototype to avoid an error.
17014   Use char because int might match the return type of a GCC
17015   builtin and then its argument prototype would still apply.  */
17016#ifdef __cplusplus
17017extern "C"
17018#endif
17019char el_gets ();
17020int
17021main ()
17022{
17023return el_gets ();
17024  ;
17025  return 0;
17026}
17027_ACEOF
17028if ac_fn_c_try_link "$LINENO"; then :
17029  ntp_lib_lineedit="$TRY_LIB"
17030fi
17031rm -f core conftest.err conftest.$ac_objext \
17032    conftest$ac_exeext conftest.$ac_ext
17033		    case "$ntp_lib_lineedit" in
17034		     '')
17035			{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17036$as_echo "no" >&6; }
17037			;;
17038		     *) # Use el_gets()
17039			{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17040$as_echo "yes" >&6; }
17041			break
17042			;;
17043		    esac	# $ntp_lib_lineedit
17044		esac		# $term_lib
17045	    done
17046	    case "$ntp_lib_lineedit" in
17047	     '')
17048		;;
17049	     *)
17050		break
17051		;;
17052	    esac
17053	done
17054	LIBS="$NTP_ORIG_LIBS"
17055	;;
17056    esac	# $use_lineeditlibs
17057
17058    case "$ntp_lib_lineedit" in
17059     '')
17060	ntp_lib_lineedit="no"
17061	;;
17062     no)
17063	;;
17064     *)
17065	EDITLINE_LIBS="$ntp_lib_lineedit"
17066
17067	;;
17068    esac	# $ntp_lib_lineedit
17069
17070    case "$ntp_lib_lineedit" in
17071     no)
17072	;;
17073     *)
17074	for ac_header in readline.h readline/readline.h histedit.h
17075do :
17076  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
17077ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
17078if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
17079  cat >>confdefs.h <<_ACEOF
17080#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
17081_ACEOF
17082
17083fi
17084
17085done
17086
17087	for ac_header in history.h readline/history.h
17088do :
17089  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
17090ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
17091if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
17092  cat >>confdefs.h <<_ACEOF
17093#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
17094_ACEOF
17095
17096fi
17097
17098done
17099
17100
17101	case "$ac_cv_header_histedit_h" in
17102	 yes)
17103	    { $as_echo "$as_me:${as_lineno-$LINENO}: checking number of arguments to el_init()" >&5
17104$as_echo_n "checking number of arguments to el_init()... " >&6; }
17105if ${ntp_cv_el_init_args+:} false; then :
17106  $as_echo_n "(cached) " >&6
17107else
17108  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17109/* end confdefs.h.  */
17110
17111			    #include <stdio.h>
17112			    #include <histedit.h>
17113
17114int
17115main ()
17116{
17117
17118			    el_init("conftest", stdin, stdout, stderr);
17119
17120
17121  ;
17122  return 0;
17123}
17124_ACEOF
17125if ac_fn_c_try_compile "$LINENO"; then :
17126  ntp_cv_el_init_args=4
17127else
17128  ntp_cv_el_init_args=3
17129
17130fi
17131rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17132
17133fi
17134{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_el_init_args" >&5
17135$as_echo "$ntp_cv_el_init_args" >&6; }
17136
17137cat >>confdefs.h <<_ACEOF
17138#define EL_INIT_ARGS $ntp_cv_el_init_args
17139_ACEOF
17140
17141	esac
17142
17143	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readline supports history" >&5
17144$as_echo_n "checking whether readline supports history... " >&6; }
17145
17146	ntp_lib_lineedit_history="no"
17147	ORIG_LIBS="$LIBS"
17148	LIBS="$ORIG_LIBS $ntp_lib_lineedit"
17149	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17150/* end confdefs.h.  */
17151
17152/* Override any GCC internal prototype to avoid an error.
17153   Use char because int might match the return type of a GCC
17154   builtin and then its argument prototype would still apply.  */
17155#ifdef __cplusplus
17156extern "C"
17157#endif
17158char add_history ();
17159int
17160main ()
17161{
17162return add_history ();
17163  ;
17164  return 0;
17165}
17166_ACEOF
17167if ac_fn_c_try_link "$LINENO"; then :
17168  ntp_lib_lineedit_history="yes"
17169fi
17170rm -f core conftest.err conftest.$ac_objext \
17171    conftest$ac_exeext conftest.$ac_ext
17172	LIBS="$ORIG_LIBS"
17173
17174	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_lib_lineedit_history" >&5
17175$as_echo "$ntp_lib_lineedit_history" >&6; }
17176
17177	case "$ntp_lib_lineedit_history" in
17178	 yes)
17179
17180$as_echo "#define HAVE_READLINE_HISTORY 1" >>confdefs.h
17181
17182	esac
17183    esac	# $ntp_lib_lineedit
17184    { NTP_ORIG_LIBS=; unset NTP_ORIG_LIBS;}
17185    { ORIG_LIBS=; unset ORIG_LIBS;}
17186    { TRY_LIB=; unset TRY_LIB;}
17187    { use_lineeditlibs=; unset use_lineeditlibs;}
17188
17189
17190LIBM=
17191case "$host" in
17192 *-*-darwin*)
17193    ;;
17194 *)
17195    _libs=$LIBS
17196    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing cos" >&5
17197$as_echo_n "checking for library containing cos... " >&6; }
17198if ${ac_cv_search_cos+:} false; then :
17199  $as_echo_n "(cached) " >&6
17200else
17201  ac_func_search_save_LIBS=$LIBS
17202cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17203/* end confdefs.h.  */
17204
17205/* Override any GCC internal prototype to avoid an error.
17206   Use char because int might match the return type of a GCC
17207   builtin and then its argument prototype would still apply.  */
17208#ifdef __cplusplus
17209extern "C"
17210#endif
17211char cos ();
17212int
17213main ()
17214{
17215return cos ();
17216  ;
17217  return 0;
17218}
17219_ACEOF
17220for ac_lib in '' m; do
17221  if test -z "$ac_lib"; then
17222    ac_res="none required"
17223  else
17224    ac_res=-l$ac_lib
17225    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
17226  fi
17227  if ac_fn_c_try_link "$LINENO"; then :
17228  ac_cv_search_cos=$ac_res
17229fi
17230rm -f core conftest.err conftest.$ac_objext \
17231    conftest$ac_exeext
17232  if ${ac_cv_search_cos+:} false; then :
17233  break
17234fi
17235done
17236if ${ac_cv_search_cos+:} false; then :
17237
17238else
17239  ac_cv_search_cos=no
17240fi
17241rm conftest.$ac_ext
17242LIBS=$ac_func_search_save_LIBS
17243fi
17244{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_cos" >&5
17245$as_echo "$ac_cv_search_cos" >&6; }
17246ac_res=$ac_cv_search_cos
17247if test "$ac_res" != no; then :
17248  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
17249  LIBM="-lm"
17250fi
17251
17252    LIBS=$_libs
17253    ;;
17254esac
17255
17256{ _libs=; unset _libs;}
17257
17258
17259for ac_header in vfork.h
17260do :
17261  ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
17262if test "x$ac_cv_header_vfork_h" = xyes; then :
17263  cat >>confdefs.h <<_ACEOF
17264#define HAVE_VFORK_H 1
17265_ACEOF
17266
17267fi
17268
17269done
17270
17271for ac_func in fork vfork
17272do :
17273  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
17274ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
17275if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
17276  cat >>confdefs.h <<_ACEOF
17277#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
17278_ACEOF
17279
17280fi
17281done
17282
17283if test "x$ac_cv_func_fork" = xyes; then
17284  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
17285$as_echo_n "checking for working fork... " >&6; }
17286if ${ac_cv_func_fork_works+:} false; then :
17287  $as_echo_n "(cached) " >&6
17288else
17289  if test "$cross_compiling" = yes; then :
17290  ac_cv_func_fork_works=cross
17291else
17292  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17293/* end confdefs.h.  */
17294$ac_includes_default
17295int
17296main ()
17297{
17298
17299	  /* By Ruediger Kuhlmann. */
17300	  return fork () < 0;
17301
17302  ;
17303  return 0;
17304}
17305_ACEOF
17306if ac_fn_c_try_run "$LINENO"; then :
17307  ac_cv_func_fork_works=yes
17308else
17309  ac_cv_func_fork_works=no
17310fi
17311rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17312  conftest.$ac_objext conftest.beam conftest.$ac_ext
17313fi
17314
17315fi
17316{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
17317$as_echo "$ac_cv_func_fork_works" >&6; }
17318
17319else
17320  ac_cv_func_fork_works=$ac_cv_func_fork
17321fi
17322if test "x$ac_cv_func_fork_works" = xcross; then
17323  case $host in
17324    *-*-amigaos* | *-*-msdosdjgpp*)
17325      # Override, as these systems have only a dummy fork() stub
17326      ac_cv_func_fork_works=no
17327      ;;
17328    *)
17329      ac_cv_func_fork_works=yes
17330      ;;
17331  esac
17332  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
17333$as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
17334fi
17335ac_cv_func_vfork_works=$ac_cv_func_vfork
17336if test "x$ac_cv_func_vfork" = xyes; then
17337  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
17338$as_echo_n "checking for working vfork... " >&6; }
17339if ${ac_cv_func_vfork_works+:} false; then :
17340  $as_echo_n "(cached) " >&6
17341else
17342  if test "$cross_compiling" = yes; then :
17343  ac_cv_func_vfork_works=cross
17344else
17345  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17346/* end confdefs.h.  */
17347/* Thanks to Paul Eggert for this test.  */
17348$ac_includes_default
17349#include <sys/wait.h>
17350#ifdef HAVE_VFORK_H
17351# include <vfork.h>
17352#endif
17353/* On some sparc systems, changes by the child to local and incoming
17354   argument registers are propagated back to the parent.  The compiler
17355   is told about this with #include <vfork.h>, but some compilers
17356   (e.g. gcc -O) don't grok <vfork.h>.  Test for this by using a
17357   static variable whose address is put into a register that is
17358   clobbered by the vfork.  */
17359static void
17360#ifdef __cplusplus
17361sparc_address_test (int arg)
17362# else
17363sparc_address_test (arg) int arg;
17364#endif
17365{
17366  static pid_t child;
17367  if (!child) {
17368    child = vfork ();
17369    if (child < 0) {
17370      perror ("vfork");
17371      _exit(2);
17372    }
17373    if (!child) {
17374      arg = getpid();
17375      write(-1, "", 0);
17376      _exit (arg);
17377    }
17378  }
17379}
17380
17381int
17382main ()
17383{
17384  pid_t parent = getpid ();
17385  pid_t child;
17386
17387  sparc_address_test (0);
17388
17389  child = vfork ();
17390
17391  if (child == 0) {
17392    /* Here is another test for sparc vfork register problems.  This
17393       test uses lots of local variables, at least as many local
17394       variables as main has allocated so far including compiler
17395       temporaries.  4 locals are enough for gcc 1.40.3 on a Solaris
17396       4.1.3 sparc, but we use 8 to be safe.  A buggy compiler should
17397       reuse the register of parent for one of the local variables,
17398       since it will think that parent can't possibly be used any more
17399       in this routine.  Assigning to the local variable will thus
17400       munge parent in the parent process.  */
17401    pid_t
17402      p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
17403      p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
17404    /* Convince the compiler that p..p7 are live; otherwise, it might
17405       use the same hardware register for all 8 local variables.  */
17406    if (p != p1 || p != p2 || p != p3 || p != p4
17407	|| p != p5 || p != p6 || p != p7)
17408      _exit(1);
17409
17410    /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
17411       from child file descriptors.  If the child closes a descriptor
17412       before it execs or exits, this munges the parent's descriptor
17413       as well.  Test for this by closing stdout in the child.  */
17414    _exit(close(fileno(stdout)) != 0);
17415  } else {
17416    int status;
17417    struct stat st;
17418
17419    while (wait(&status) != child)
17420      ;
17421    return (
17422	 /* Was there some problem with vforking?  */
17423	 child < 0
17424
17425	 /* Did the child fail?  (This shouldn't happen.)  */
17426	 || status
17427
17428	 /* Did the vfork/compiler bug occur?  */
17429	 || parent != getpid()
17430
17431	 /* Did the file descriptor bug occur?  */
17432	 || fstat(fileno(stdout), &st) != 0
17433	 );
17434  }
17435}
17436_ACEOF
17437if ac_fn_c_try_run "$LINENO"; then :
17438  ac_cv_func_vfork_works=yes
17439else
17440  ac_cv_func_vfork_works=no
17441fi
17442rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17443  conftest.$ac_objext conftest.beam conftest.$ac_ext
17444fi
17445
17446fi
17447{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
17448$as_echo "$ac_cv_func_vfork_works" >&6; }
17449
17450fi;
17451if test "x$ac_cv_func_fork_works" = xcross; then
17452  ac_cv_func_vfork_works=$ac_cv_func_vfork
17453  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
17454$as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
17455fi
17456
17457if test "x$ac_cv_func_vfork_works" = xyes; then
17458
17459$as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
17460
17461else
17462
17463$as_echo "#define vfork fork" >>confdefs.h
17464
17465fi
17466if test "x$ac_cv_func_fork_works" = xyes; then
17467
17468$as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
17469
17470fi
17471
17472# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
17473# for constant arguments.  Useless!
17474{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
17475$as_echo_n "checking for working alloca.h... " >&6; }
17476if ${ac_cv_working_alloca_h+:} false; then :
17477  $as_echo_n "(cached) " >&6
17478else
17479  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17480/* end confdefs.h.  */
17481#include <alloca.h>
17482int
17483main ()
17484{
17485char *p = (char *) alloca (2 * sizeof (int));
17486			  if (p) return 0;
17487  ;
17488  return 0;
17489}
17490_ACEOF
17491if ac_fn_c_try_link "$LINENO"; then :
17492  ac_cv_working_alloca_h=yes
17493else
17494  ac_cv_working_alloca_h=no
17495fi
17496rm -f core conftest.err conftest.$ac_objext \
17497    conftest$ac_exeext conftest.$ac_ext
17498fi
17499{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
17500$as_echo "$ac_cv_working_alloca_h" >&6; }
17501if test $ac_cv_working_alloca_h = yes; then
17502
17503$as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
17504
17505fi
17506
17507{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
17508$as_echo_n "checking for alloca... " >&6; }
17509if ${ac_cv_func_alloca_works+:} false; then :
17510  $as_echo_n "(cached) " >&6
17511else
17512  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17513/* end confdefs.h.  */
17514#ifdef __GNUC__
17515# define alloca __builtin_alloca
17516#else
17517# ifdef _MSC_VER
17518#  include <malloc.h>
17519#  define alloca _alloca
17520# else
17521#  ifdef HAVE_ALLOCA_H
17522#   include <alloca.h>
17523#  else
17524#   ifdef _AIX
17525 #pragma alloca
17526#   else
17527#    ifndef alloca /* predefined by HP cc +Olibcalls */
17528void *alloca (size_t);
17529#    endif
17530#   endif
17531#  endif
17532# endif
17533#endif
17534
17535int
17536main ()
17537{
17538char *p = (char *) alloca (1);
17539				    if (p) return 0;
17540  ;
17541  return 0;
17542}
17543_ACEOF
17544if ac_fn_c_try_link "$LINENO"; then :
17545  ac_cv_func_alloca_works=yes
17546else
17547  ac_cv_func_alloca_works=no
17548fi
17549rm -f core conftest.err conftest.$ac_objext \
17550    conftest$ac_exeext conftest.$ac_ext
17551fi
17552{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
17553$as_echo "$ac_cv_func_alloca_works" >&6; }
17554
17555if test $ac_cv_func_alloca_works = yes; then
17556
17557$as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
17558
17559else
17560  # The SVR3 libPW and SVR4 libucb both contain incompatible functions
17561# that cause trouble.  Some versions do not even contain alloca or
17562# contain a buggy version.  If you still want to use their alloca,
17563# use ar to extract alloca.o from them instead of compiling alloca.c.
17564
17565ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
17566
17567$as_echo "#define C_ALLOCA 1" >>confdefs.h
17568
17569
17570{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5
17571$as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; }
17572if ${ac_cv_os_cray+:} false; then :
17573  $as_echo_n "(cached) " >&6
17574else
17575  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17576/* end confdefs.h.  */
17577#if defined CRAY && ! defined CRAY2
17578webecray
17579#else
17580wenotbecray
17581#endif
17582
17583_ACEOF
17584if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17585  $EGREP "webecray" >/dev/null 2>&1; then :
17586  ac_cv_os_cray=yes
17587else
17588  ac_cv_os_cray=no
17589fi
17590rm -f conftest*
17591
17592fi
17593{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
17594$as_echo "$ac_cv_os_cray" >&6; }
17595if test $ac_cv_os_cray = yes; then
17596  for ac_func in _getb67 GETB67 getb67; do
17597    as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
17598ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
17599if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
17600
17601cat >>confdefs.h <<_ACEOF
17602#define CRAY_STACKSEG_END $ac_func
17603_ACEOF
17604
17605    break
17606fi
17607
17608  done
17609fi
17610
17611{ $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
17612$as_echo_n "checking stack direction for C alloca... " >&6; }
17613if ${ac_cv_c_stack_direction+:} false; then :
17614  $as_echo_n "(cached) " >&6
17615else
17616  if test "$cross_compiling" = yes; then :
17617  ac_cv_c_stack_direction=0
17618else
17619  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17620/* end confdefs.h.  */
17621$ac_includes_default
17622int
17623find_stack_direction (int *addr, int depth)
17624{
17625  int dir, dummy = 0;
17626  if (! addr)
17627    addr = &dummy;
17628  *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
17629  dir = depth ? find_stack_direction (addr, depth - 1) : 0;
17630  return dir + dummy;
17631}
17632
17633int
17634main (int argc, char **argv)
17635{
17636  return find_stack_direction (0, argc + !argv + 20) < 0;
17637}
17638_ACEOF
17639if ac_fn_c_try_run "$LINENO"; then :
17640  ac_cv_c_stack_direction=1
17641else
17642  ac_cv_c_stack_direction=-1
17643fi
17644rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17645  conftest.$ac_objext conftest.beam conftest.$ac_ext
17646fi
17647
17648fi
17649{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
17650$as_echo "$ac_cv_c_stack_direction" >&6; }
17651cat >>confdefs.h <<_ACEOF
17652#define STACK_DIRECTION $ac_cv_c_stack_direction
17653_ACEOF
17654
17655
17656fi
17657
17658ac_fn_c_check_decl "$LINENO" "strerror_r" "ac_cv_have_decl_strerror_r" "$ac_includes_default"
17659if test "x$ac_cv_have_decl_strerror_r" = xyes; then :
17660  ac_have_decl=1
17661else
17662  ac_have_decl=0
17663fi
17664
17665cat >>confdefs.h <<_ACEOF
17666#define HAVE_DECL_STRERROR_R $ac_have_decl
17667_ACEOF
17668
17669for ac_func in strerror_r
17670do :
17671  ac_fn_c_check_func "$LINENO" "strerror_r" "ac_cv_func_strerror_r"
17672if test "x$ac_cv_func_strerror_r" = xyes; then :
17673  cat >>confdefs.h <<_ACEOF
17674#define HAVE_STRERROR_R 1
17675_ACEOF
17676
17677fi
17678done
17679
17680{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strerror_r returns char *" >&5
17681$as_echo_n "checking whether strerror_r returns char *... " >&6; }
17682if ${ac_cv_func_strerror_r_char_p+:} false; then :
17683  $as_echo_n "(cached) " >&6
17684else
17685
17686    ac_cv_func_strerror_r_char_p=no
17687    if test $ac_cv_have_decl_strerror_r = yes; then
17688      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17689/* end confdefs.h.  */
17690$ac_includes_default
17691int
17692main ()
17693{
17694
17695	  char buf[100];
17696	  char x = *strerror_r (0, buf, sizeof buf);
17697	  char *p = strerror_r (0, buf, sizeof buf);
17698	  return !p || x;
17699
17700  ;
17701  return 0;
17702}
17703_ACEOF
17704if ac_fn_c_try_compile "$LINENO"; then :
17705  ac_cv_func_strerror_r_char_p=yes
17706fi
17707rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17708    else
17709      # strerror_r is not declared.  Choose between
17710      # systems that have relatively inaccessible declarations for the
17711      # function.  BeOS and DEC UNIX 4.0 fall in this category, but the
17712      # former has a strerror_r that returns char*, while the latter
17713      # has a strerror_r that returns `int'.
17714      # This test should segfault on the DEC system.
17715      if test "$cross_compiling" = yes; then :
17716  :
17717else
17718  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17719/* end confdefs.h.  */
17720$ac_includes_default
17721	extern char *strerror_r ();
17722int
17723main ()
17724{
17725char buf[100];
17726	  char x = *strerror_r (0, buf, sizeof buf);
17727	  return ! isalpha (x);
17728  ;
17729  return 0;
17730}
17731_ACEOF
17732if ac_fn_c_try_run "$LINENO"; then :
17733  ac_cv_func_strerror_r_char_p=yes
17734fi
17735rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17736  conftest.$ac_objext conftest.beam conftest.$ac_ext
17737fi
17738
17739    fi
17740
17741fi
17742{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_strerror_r_char_p" >&5
17743$as_echo "$ac_cv_func_strerror_r_char_p" >&6; }
17744if test $ac_cv_func_strerror_r_char_p = yes; then
17745
17746$as_echo "#define STRERROR_R_CHAR_P 1" >>confdefs.h
17747
17748fi
17749
17750
17751ac_busted_vpath_in_make=no
17752case "$build" in
17753 *-*-irix6.1*)	# 64 bit only
17754    # busted vpath?
17755    ;;
17756 *-*-irix6*)	# 6.2 (and later?)
17757    ac_busted_vpath_in_make=yes
17758    ;;
17759 *-*-solaris2.5.1)
17760    ac_busted_vpath_in_make=yes
17761    ;;
17762 *-*-unicosmp*)
17763    ac_busted_vpath_in_make=yes
17764    ;;
17765esac
17766
17767case "$ac_busted_vpath_in_make$srcdir" in
17768 yes.|no*)
17769    ;;
17770 *) case "`${MAKE-make} -v -f /dev/null 2>/dev/null | grep 'GNU Make'`" in
17771     '')
17772	as_fn_error $? "building outside of the main directory requires GNU make" "$LINENO" 5
17773    esac
17774    ;;
17775esac
17776
17777case "$host" in
17778 *-*-aix4*)
17779	# Bug 2516:
17780	# Was *-*-aix[[4-9]]*
17781	# XXX only verified thru AIX6.  But...
17782	# Ken Link says this is fine for AIX 5.3 and 7.1, and sees no reason
17783	# that this support would be in 5.3, removed in 6, and added back.
17784	#
17785	# (prr) aix 4.1 doesn't have clock_settime, but in aix 4.3 it's a stub
17786	# (returning ENOSYS).  I didn't check 4.2.  If, in the future,
17787	# IBM pulls its thumbs out long enough to implement clock_settime,
17788	# this conditional will need to change.  Maybe use AC_TRY_RUN
17789	# instead to try to set the time to itself and check errno.
17790    ;;
17791 *)
17792    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
17793$as_echo_n "checking for library containing clock_gettime... " >&6; }
17794if ${ac_cv_search_clock_gettime+:} false; then :
17795  $as_echo_n "(cached) " >&6
17796else
17797  ac_func_search_save_LIBS=$LIBS
17798cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17799/* end confdefs.h.  */
17800
17801/* Override any GCC internal prototype to avoid an error.
17802   Use char because int might match the return type of a GCC
17803   builtin and then its argument prototype would still apply.  */
17804#ifdef __cplusplus
17805extern "C"
17806#endif
17807char clock_gettime ();
17808int
17809main ()
17810{
17811return clock_gettime ();
17812  ;
17813  return 0;
17814}
17815_ACEOF
17816for ac_lib in '' rt; do
17817  if test -z "$ac_lib"; then
17818    ac_res="none required"
17819  else
17820    ac_res=-l$ac_lib
17821    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
17822  fi
17823  if ac_fn_c_try_link "$LINENO"; then :
17824  ac_cv_search_clock_gettime=$ac_res
17825fi
17826rm -f core conftest.err conftest.$ac_objext \
17827    conftest$ac_exeext
17828  if ${ac_cv_search_clock_gettime+:} false; then :
17829  break
17830fi
17831done
17832if ${ac_cv_search_clock_gettime+:} false; then :
17833
17834else
17835  ac_cv_search_clock_gettime=no
17836fi
17837rm conftest.$ac_ext
17838LIBS=$ac_func_search_save_LIBS
17839fi
17840{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
17841$as_echo "$ac_cv_search_clock_gettime" >&6; }
17842ac_res=$ac_cv_search_clock_gettime
17843if test "$ac_res" != no; then :
17844  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
17845  case "$ac_cv_search_clock_gettime" in
17846 'none required') ;;
17847 no) ;;
17848 *) LDADD_LIBNTP="$ac_cv_search_clock_gettime $LDADD_LIBNTP" ;;
17849 esac
17850
17851fi
17852
17853    for ac_func in clock_getres clock_gettime clock_settime
17854do :
17855  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
17856ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
17857if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
17858  cat >>confdefs.h <<_ACEOF
17859#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
17860_ACEOF
17861
17862fi
17863done
17864
17865    ;;
17866esac
17867
17868for ac_func in getclock stime timegm strlcpy strlcat
17869do :
17870  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
17871ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
17872if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
17873  cat >>confdefs.h <<_ACEOF
17874#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
17875_ACEOF
17876
17877fi
17878done
17879
17880
17881# Bug 2713
17882LDADD_LIBUTIL=
17883
17884{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing snprintb" >&5
17885$as_echo_n "checking for library containing snprintb... " >&6; }
17886if ${ac_cv_search_snprintb+:} false; then :
17887  $as_echo_n "(cached) " >&6
17888else
17889  ac_func_search_save_LIBS=$LIBS
17890cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17891/* end confdefs.h.  */
17892
17893/* Override any GCC internal prototype to avoid an error.
17894   Use char because int might match the return type of a GCC
17895   builtin and then its argument prototype would still apply.  */
17896#ifdef __cplusplus
17897extern "C"
17898#endif
17899char snprintb ();
17900int
17901main ()
17902{
17903return snprintb ();
17904  ;
17905  return 0;
17906}
17907_ACEOF
17908for ac_lib in '' util; do
17909  if test -z "$ac_lib"; then
17910    ac_res="none required"
17911  else
17912    ac_res=-l$ac_lib
17913    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
17914  fi
17915  if ac_fn_c_try_link "$LINENO"; then :
17916  ac_cv_search_snprintb=$ac_res
17917fi
17918rm -f core conftest.err conftest.$ac_objext \
17919    conftest$ac_exeext
17920  if ${ac_cv_search_snprintb+:} false; then :
17921  break
17922fi
17923done
17924if ${ac_cv_search_snprintb+:} false; then :
17925
17926else
17927  ac_cv_search_snprintb=no
17928fi
17929rm conftest.$ac_ext
17930LIBS=$ac_func_search_save_LIBS
17931fi
17932{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_snprintb" >&5
17933$as_echo "$ac_cv_search_snprintb" >&6; }
17934ac_res=$ac_cv_search_snprintb
17935if test "$ac_res" != no; then :
17936  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
17937  case "$ac_cv_search_snprintb" in
17938 'none required') ;;
17939 no) ;;
17940 *) LDADD_LIBUTIL="$ac_cv_search_snprintb $LDADD_LIBUTIL" ;;
17941 esac
17942
17943$as_echo "#define USE_SNPRINTB 1" >>confdefs.h
17944
17945fi
17946
17947
17948#
17949for ac_header in errno.h sys/socket.h sys/types.h time.h
17950do :
17951  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
17952ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
17953if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
17954  cat >>confdefs.h <<_ACEOF
17955#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
17956_ACEOF
17957
17958fi
17959
17960done
17961
17962for ac_header in net/if.h
17963do :
17964  ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "
17965    #ifdef HAVE_SYS_SOCKET_H
17966    # include <sys/socket.h>
17967    #endif
17968
17969"
17970if test "x$ac_cv_header_net_if_h" = xyes; then :
17971  cat >>confdefs.h <<_ACEOF
17972#define HAVE_NET_IF_H 1
17973_ACEOF
17974
17975fi
17976
17977done
17978
17979case "$host" in
17980 *-hp-hpux*)
17981    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if net/if.h requires mpinfou predeclaration" >&5
17982$as_echo_n "checking if net/if.h requires mpinfou predeclaration... " >&6; }
17983if ${ntp_cv_predecl_mpinfou+:} false; then :
17984  $as_echo_n "(cached) " >&6
17985else
17986
17987	    np_cv_predecl_mpinfou=no
17988	    case "$ac_cv_header_net_if_h" in
17989	     no)
17990		cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17991/* end confdefs.h.  */
17992
17993			    typedef union mpinfou {
17994				    struct pdk_mpinfo *pdkptr;
17995				    struct mpinfo *pikptr;
17996			    } mpinfou_t;
17997			    #ifdef HAVE_SYS_SOCKET_H
17998			    # include <sys/socket.h>
17999			    #endif
18000			    #include <net/if.h>
18001
18002int
18003main ()
18004{
18005
18006
18007
18008  ;
18009  return 0;
18010}
18011_ACEOF
18012if ac_fn_c_try_compile "$LINENO"; then :
18013
18014			ntp_cv_predecl_mpinfou=yes
18015			ac_cv_header_net_if_h=yes
18016
18017
18018fi
18019rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18020	    esac
18021
18022
18023fi
18024{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_predecl_mpinfou" >&5
18025$as_echo "$ntp_cv_predecl_mpinfou" >&6; }
18026    case "$ntp_cv_predecl_mpinfou" in
18027     yes)
18028	cat >>confdefs.h <<_ACEOF
18029#ifndef MPINFOU_PREDECLARED
18030# define MPINFOU_PREDECLARED
18031typedef union mpinfou {
18032	struct pdk_mpinfo *pdkptr;
18033	struct mpinfo *pikptr;
18034} mpinfou_t;
18035#endif
18036_ACEOF
18037
18038    esac
18039esac
18040
18041case "$host" in
18042 *-linux*)
18043    for ac_header in linux/if_addr.h
18044do :
18045  ac_fn_c_check_header_compile "$LINENO" "linux/if_addr.h" "ac_cv_header_linux_if_addr_h" "
18046	#ifdef HAVE_SYS_SOCKET_H
18047	# include <sys/socket.h>
18048	#endif
18049
18050"
18051if test "x$ac_cv_header_linux_if_addr_h" = xyes; then :
18052  cat >>confdefs.h <<_ACEOF
18053#define HAVE_LINUX_IF_ADDR_H 1
18054_ACEOF
18055
18056fi
18057
18058done
18059
18060
18061$as_echo "#define NEED_EARLY_FORK 1" >>confdefs.h
18062
18063esac
18064
18065for ac_header in arpa/nameser.h sys/param.h sys/time.h sys/timers.h
18066do :
18067  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
18068ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
18069if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
18070  cat >>confdefs.h <<_ACEOF
18071#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
18072_ACEOF
18073
18074fi
18075
18076done
18077
18078# sys/sysctl.h depends on sys/param.h on OpenBSD - Bug 1576
18079for ac_header in sys/sysctl.h
18080do :
18081  ac_fn_c_check_header_compile "$LINENO" "sys/sysctl.h" "ac_cv_header_sys_sysctl_h" "
18082    #if defined HAVE_SYS_PARAM_H
18083    # include <sys/param.h>
18084    #endif
18085
18086"
18087if test "x$ac_cv_header_sys_sysctl_h" = xyes; then :
18088  cat >>confdefs.h <<_ACEOF
18089#define HAVE_SYS_SYSCTL_H 1
18090_ACEOF
18091
18092fi
18093
18094done
18095
18096for ac_header in netinet/in_system.h netinet/in_systm.h netinet/in.h
18097do :
18098  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
18099ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
18100if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
18101  cat >>confdefs.h <<_ACEOF
18102#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
18103_ACEOF
18104
18105fi
18106
18107done
18108
18109
18110for ac_header in resolv.h
18111do :
18112  ac_fn_c_check_header_compile "$LINENO" "resolv.h" "ac_cv_header_resolv_h" "
18113    #ifdef HAVE_SYS_TYPES_H
18114    # include <sys/types.h>
18115    #endif
18116    #ifdef HAVE_NETINET_IN_H
18117    # include <netinet/in.h>
18118    #endif
18119    #ifdef HAVE_ARPA_NAMESER_H
18120    # include <arpa/nameser.h>
18121    #endif
18122
18123"
18124if test "x$ac_cv_header_resolv_h" = xyes; then :
18125  cat >>confdefs.h <<_ACEOF
18126#define HAVE_RESOLV_H 1
18127_ACEOF
18128
18129fi
18130
18131done
18132
18133
18134for ac_header in net/if_var.h
18135do :
18136  ac_fn_c_check_header_compile "$LINENO" "net/if_var.h" "ac_cv_header_net_if_var_h" "
18137    #if HAVE_SYS_TYPES_H
18138    # include <sys/types.h>
18139    #endif
18140    #ifdef HAVE_SYS_SOCKET_H
18141    # include <sys/socket.h>
18142    #endif
18143    #ifdef HAVE_NETINET_IN_H
18144    # include <netinet/in.h>
18145    #endif
18146    #ifdef HAVE_NET_IF_H
18147    # include <net/if.h>
18148    #endif
18149
18150"
18151if test "x$ac_cv_header_net_if_var_h" = xyes; then :
18152  cat >>confdefs.h <<_ACEOF
18153#define HAVE_NET_IF_VAR_H 1
18154_ACEOF
18155
18156fi
18157
18158done
18159
18160
18161for ac_header in netinet/ip.h netinet/in_var.h
18162do :
18163  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
18164ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "
18165    #ifdef HAVE_SYS_TYPES_H
18166    # include <sys/types.h>
18167    #endif
18168    #ifdef HAVE_SYS_SOCKET_H
18169    # include <sys/socket.h>
18170    #endif
18171    #ifdef HAVE_NET_IF_H
18172    # include <net/if.h>
18173    #endif
18174    #ifdef HAVE_NETINET_IN_H
18175    # include <netinet/in.h>
18176    #endif
18177    #ifdef HAVE_NET_IF_VAR_H
18178    # include <net/if_var.h>
18179    #endif
18180    #ifdef HAVE_NETINET_IN_SYSTM_H
18181    # include <netinet/in_systm.h>
18182    #endif
18183
18184"
18185if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
18186  cat >>confdefs.h <<_ACEOF
18187#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
18188_ACEOF
18189
18190fi
18191
18192done
18193
18194
18195# HMS: Do we need to check for -lsocket before or after these tests?
18196{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing inet_pton" >&5
18197$as_echo_n "checking for library containing inet_pton... " >&6; }
18198if ${ac_cv_search_inet_pton+:} false; then :
18199  $as_echo_n "(cached) " >&6
18200else
18201  ac_func_search_save_LIBS=$LIBS
18202cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18203/* end confdefs.h.  */
18204
18205/* Override any GCC internal prototype to avoid an error.
18206   Use char because int might match the return type of a GCC
18207   builtin and then its argument prototype would still apply.  */
18208#ifdef __cplusplus
18209extern "C"
18210#endif
18211char inet_pton ();
18212int
18213main ()
18214{
18215return inet_pton ();
18216  ;
18217  return 0;
18218}
18219_ACEOF
18220for ac_lib in '' nsl; do
18221  if test -z "$ac_lib"; then
18222    ac_res="none required"
18223  else
18224    ac_res=-l$ac_lib
18225    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
18226  fi
18227  if ac_fn_c_try_link "$LINENO"; then :
18228  ac_cv_search_inet_pton=$ac_res
18229fi
18230rm -f core conftest.err conftest.$ac_objext \
18231    conftest$ac_exeext
18232  if ${ac_cv_search_inet_pton+:} false; then :
18233  break
18234fi
18235done
18236if ${ac_cv_search_inet_pton+:} false; then :
18237
18238else
18239  ac_cv_search_inet_pton=no
18240fi
18241rm conftest.$ac_ext
18242LIBS=$ac_func_search_save_LIBS
18243fi
18244{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_inet_pton" >&5
18245$as_echo "$ac_cv_search_inet_pton" >&6; }
18246ac_res=$ac_cv_search_inet_pton
18247if test "$ac_res" != no; then :
18248  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
18249  case "$ac_cv_search_inet_pton" in
18250 'none required') ;;
18251 no) ;;
18252 *) LDADD_LIBNTP="$ac_cv_search_inet_pton $LDADD_LIBNTP" ;;
18253 esac
18254
18255fi
18256
18257{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing inet_ntop" >&5
18258$as_echo_n "checking for library containing inet_ntop... " >&6; }
18259if ${ac_cv_search_inet_ntop+:} false; then :
18260  $as_echo_n "(cached) " >&6
18261else
18262  ac_func_search_save_LIBS=$LIBS
18263cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18264/* end confdefs.h.  */
18265
18266/* Override any GCC internal prototype to avoid an error.
18267   Use char because int might match the return type of a GCC
18268   builtin and then its argument prototype would still apply.  */
18269#ifdef __cplusplus
18270extern "C"
18271#endif
18272char inet_ntop ();
18273int
18274main ()
18275{
18276return inet_ntop ();
18277  ;
18278  return 0;
18279}
18280_ACEOF
18281for ac_lib in '' resolv; do
18282  if test -z "$ac_lib"; then
18283    ac_res="none required"
18284  else
18285    ac_res=-l$ac_lib
18286    LIBS="-l$ac_lib -lnsl $ac_func_search_save_LIBS"
18287  fi
18288  if ac_fn_c_try_link "$LINENO"; then :
18289  ac_cv_search_inet_ntop=$ac_res
18290fi
18291rm -f core conftest.err conftest.$ac_objext \
18292    conftest$ac_exeext
18293  if ${ac_cv_search_inet_ntop+:} false; then :
18294  break
18295fi
18296done
18297if ${ac_cv_search_inet_ntop+:} false; then :
18298
18299else
18300  ac_cv_search_inet_ntop=no
18301fi
18302rm conftest.$ac_ext
18303LIBS=$ac_func_search_save_LIBS
18304fi
18305{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_inet_ntop" >&5
18306$as_echo "$ac_cv_search_inet_ntop" >&6; }
18307ac_res=$ac_cv_search_inet_ntop
18308if test "$ac_res" != no; then :
18309  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
18310  case "$ac_cv_search_inet_ntop" in
18311 'none required') ;;
18312 no) ;;
18313 *) LDADD_LIBNTP="$ac_cv_search_inet_ntop $LDADD_LIBNTP" ;;
18314 esac
18315
18316fi
18317
18318
18319# [Bug 1628] On Solaris, we need -lxnet -lsocket.  Generalize this to
18320# avoid keying on the OS name:  If we find socket functions in
18321# libsocket, next try for them in libxnet without libsocket, if found,
18322# list both.  If we simply tested libxnet first, we would find the
18323# functions there and never add libsocket.  See also [Bug 660]
18324# http://bugs.ntp.org/show_bug.cgi?id=660#c9
18325saved_LIBS=$LIBS
18326{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing setsockopt" >&5
18327$as_echo_n "checking for library containing setsockopt... " >&6; }
18328if ${ac_cv_search_setsockopt+:} false; then :
18329  $as_echo_n "(cached) " >&6
18330else
18331  ac_func_search_save_LIBS=$LIBS
18332cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18333/* end confdefs.h.  */
18334
18335/* Override any GCC internal prototype to avoid an error.
18336   Use char because int might match the return type of a GCC
18337   builtin and then its argument prototype would still apply.  */
18338#ifdef __cplusplus
18339extern "C"
18340#endif
18341char setsockopt ();
18342int
18343main ()
18344{
18345return setsockopt ();
18346  ;
18347  return 0;
18348}
18349_ACEOF
18350for ac_lib in '' socket; do
18351  if test -z "$ac_lib"; then
18352    ac_res="none required"
18353  else
18354    ac_res=-l$ac_lib
18355    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
18356  fi
18357  if ac_fn_c_try_link "$LINENO"; then :
18358  ac_cv_search_setsockopt=$ac_res
18359fi
18360rm -f core conftest.err conftest.$ac_objext \
18361    conftest$ac_exeext
18362  if ${ac_cv_search_setsockopt+:} false; then :
18363  break
18364fi
18365done
18366if ${ac_cv_search_setsockopt+:} false; then :
18367
18368else
18369  ac_cv_search_setsockopt=no
18370fi
18371rm conftest.$ac_ext
18372LIBS=$ac_func_search_save_LIBS
18373fi
18374{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_setsockopt" >&5
18375$as_echo "$ac_cv_search_setsockopt" >&6; }
18376ac_res=$ac_cv_search_setsockopt
18377if test "$ac_res" != no; then :
18378  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
18379  case "$ac_cv_search_setsockopt" in
18380 'none required') ;;
18381 no) ;;
18382 *) LDADD_LIBNTP="$ac_cv_search_setsockopt $LDADD_LIBNTP" ;;
18383 esac
18384
18385fi
18386
18387case "$ac_cv_search_setsockopt" in
18388 -lsocket)
18389    LIBS="$saved_LIBS"
18390    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing getsockopt" >&5
18391$as_echo_n "checking for library containing getsockopt... " >&6; }
18392if ${ac_cv_search_getsockopt+:} false; then :
18393  $as_echo_n "(cached) " >&6
18394else
18395  ac_func_search_save_LIBS=$LIBS
18396cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18397/* end confdefs.h.  */
18398
18399/* Override any GCC internal prototype to avoid an error.
18400   Use char because int might match the return type of a GCC
18401   builtin and then its argument prototype would still apply.  */
18402#ifdef __cplusplus
18403extern "C"
18404#endif
18405char getsockopt ();
18406int
18407main ()
18408{
18409return getsockopt ();
18410  ;
18411  return 0;
18412}
18413_ACEOF
18414for ac_lib in '' xnet; do
18415  if test -z "$ac_lib"; then
18416    ac_res="none required"
18417  else
18418    ac_res=-l$ac_lib
18419    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
18420  fi
18421  if ac_fn_c_try_link "$LINENO"; then :
18422  ac_cv_search_getsockopt=$ac_res
18423fi
18424rm -f core conftest.err conftest.$ac_objext \
18425    conftest$ac_exeext
18426  if ${ac_cv_search_getsockopt+:} false; then :
18427  break
18428fi
18429done
18430if ${ac_cv_search_getsockopt+:} false; then :
18431
18432else
18433  ac_cv_search_getsockopt=no
18434fi
18435rm conftest.$ac_ext
18436LIBS=$ac_func_search_save_LIBS
18437fi
18438{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_getsockopt" >&5
18439$as_echo "$ac_cv_search_getsockopt" >&6; }
18440ac_res=$ac_cv_search_getsockopt
18441if test "$ac_res" != no; then :
18442  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
18443  case "$ac_cv_search_getsockopt" in
18444 'none required') ;;
18445 no) ;;
18446 *) LDADD_LIBNTP="$ac_cv_search_getsockopt $LDADD_LIBNTP" ;;
18447 esac
18448
18449fi
18450
18451    # XXX Possible trouble here - reading the comments above and looking at the
18452    # code below I wonder if we'll add -lxnet when we don't need it.
18453    # Also, do we need to add -lxnet to LDADD_LIBNTP, or perhaps see if it's
18454    # there when it is not needed?
18455    case "$ac_cv_search_getsockopt" in
18456     -lxnet)
18457	LIBS="-lxnet -lsocket $saved_LIBS"
18458	;;
18459     *) LIBS="-lsocket $saved_LIBS"
18460	;;
18461    esac
18462    ;;
18463esac
18464{ saved_LIBS=; unset saved_LIBS;}
18465
18466# Bug 2427 - look for recvmsg here.
18467for ac_func in recvmsg
18468do :
18469  ac_fn_c_check_func "$LINENO" "recvmsg" "ac_cv_func_recvmsg"
18470if test "x$ac_cv_func_recvmsg" = xyes; then :
18471  cat >>confdefs.h <<_ACEOF
18472#define HAVE_RECVMSG 1
18473_ACEOF
18474
18475fi
18476done
18477
18478
18479{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
18480$as_echo_n "checking for inline... " >&6; }
18481if ${ac_cv_c_inline+:} false; then :
18482  $as_echo_n "(cached) " >&6
18483else
18484  ac_cv_c_inline=no
18485for ac_kw in inline __inline__ __inline; do
18486  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18487/* end confdefs.h.  */
18488#ifndef __cplusplus
18489typedef int foo_t;
18490static $ac_kw foo_t static_foo () {return 0; }
18491$ac_kw foo_t foo () {return 0; }
18492#endif
18493
18494_ACEOF
18495if ac_fn_c_try_compile "$LINENO"; then :
18496  ac_cv_c_inline=$ac_kw
18497fi
18498rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18499  test "$ac_cv_c_inline" != no && break
18500done
18501
18502fi
18503{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
18504$as_echo "$ac_cv_c_inline" >&6; }
18505
18506case $ac_cv_c_inline in
18507  inline | yes) ;;
18508  *)
18509    case $ac_cv_c_inline in
18510      no) ac_val=;;
18511      *) ac_val=$ac_cv_c_inline;;
18512    esac
18513    cat >>confdefs.h <<_ACEOF
18514#ifndef __cplusplus
18515#define inline $ac_val
18516#endif
18517_ACEOF
18518    ;;
18519esac
18520
18521
18522case "$ac_cv_c_inline" in
18523 '')
18524    ;;
18525 *)
18526
18527$as_echo "#define HAVE_INLINE 1" >>confdefs.h
18528
18529
18530esac
18531
18532{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
18533$as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
18534if ${ac_cv_header_time+:} false; then :
18535  $as_echo_n "(cached) " >&6
18536else
18537  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18538/* end confdefs.h.  */
18539#include <sys/types.h>
18540#include <sys/time.h>
18541#include <time.h>
18542
18543int
18544main ()
18545{
18546if ((struct tm *) 0)
18547return 0;
18548  ;
18549  return 0;
18550}
18551_ACEOF
18552if ac_fn_c_try_compile "$LINENO"; then :
18553  ac_cv_header_time=yes
18554else
18555  ac_cv_header_time=no
18556fi
18557rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18558fi
18559{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
18560$as_echo "$ac_cv_header_time" >&6; }
18561if test $ac_cv_header_time = yes; then
18562
18563$as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
18564
18565fi
18566
18567# The cast to long int works around a bug in the HP C Compiler
18568# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
18569# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
18570# This bug is HP SR number 8606223364.
18571{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of time_t" >&5
18572$as_echo_n "checking size of time_t... " >&6; }
18573if ${ac_cv_sizeof_time_t+:} false; then :
18574  $as_echo_n "(cached) " >&6
18575else
18576  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (time_t))" "ac_cv_sizeof_time_t"        "$ac_includes_default"; then :
18577
18578else
18579  if test "$ac_cv_type_time_t" = yes; then
18580     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
18581$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18582as_fn_error 77 "cannot compute sizeof (time_t)
18583See \`config.log' for more details" "$LINENO" 5; }
18584   else
18585     ac_cv_sizeof_time_t=0
18586   fi
18587fi
18588
18589fi
18590{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_time_t" >&5
18591$as_echo "$ac_cv_sizeof_time_t" >&6; }
18592
18593
18594
18595cat >>confdefs.h <<_ACEOF
18596#define SIZEOF_TIME_T $ac_cv_sizeof_time_t
18597_ACEOF
18598
18599
18600{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether char is unsigned" >&5
18601$as_echo_n "checking whether char is unsigned... " >&6; }
18602if ${ac_cv_c_char_unsigned+:} false; then :
18603  $as_echo_n "(cached) " >&6
18604else
18605  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18606/* end confdefs.h.  */
18607$ac_includes_default
18608int
18609main ()
18610{
18611static int test_array [1 - 2 * !(((char) -1) < 0)];
18612test_array [0] = 0;
18613return test_array [0];
18614
18615  ;
18616  return 0;
18617}
18618_ACEOF
18619if ac_fn_c_try_compile "$LINENO"; then :
18620  ac_cv_c_char_unsigned=no
18621else
18622  ac_cv_c_char_unsigned=yes
18623fi
18624rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18625fi
18626{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_char_unsigned" >&5
18627$as_echo "$ac_cv_c_char_unsigned" >&6; }
18628if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then
18629  $as_echo "#define __CHAR_UNSIGNED__ 1" >>confdefs.h
18630
18631fi
18632		# The cast to long int works around a bug in the HP C Compiler
18633# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
18634# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
18635# This bug is HP SR number 8606223364.
18636{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of signed char" >&5
18637$as_echo_n "checking size of signed char... " >&6; }
18638if ${ac_cv_sizeof_signed_char+:} false; then :
18639  $as_echo_n "(cached) " >&6
18640else
18641  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (signed char))" "ac_cv_sizeof_signed_char"        "$ac_includes_default"; then :
18642
18643else
18644  if test "$ac_cv_type_signed_char" = yes; then
18645     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
18646$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18647as_fn_error 77 "cannot compute sizeof (signed char)
18648See \`config.log' for more details" "$LINENO" 5; }
18649   else
18650     ac_cv_sizeof_signed_char=0
18651   fi
18652fi
18653
18654fi
18655{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_signed_char" >&5
18656$as_echo "$ac_cv_sizeof_signed_char" >&6; }
18657
18658
18659
18660cat >>confdefs.h <<_ACEOF
18661#define SIZEOF_SIGNED_CHAR $ac_cv_sizeof_signed_char
18662_ACEOF
18663
18664
18665ac_fn_c_check_type "$LINENO" "s_char" "ac_cv_type_s_char" "$ac_includes_default"
18666if test "x$ac_cv_type_s_char" = xyes; then :
18667
18668cat >>confdefs.h <<_ACEOF
18669#define HAVE_S_CHAR 1
18670_ACEOF
18671
18672
18673fi
18674ac_fn_c_check_type "$LINENO" "long long" "ac_cv_type_long_long" "$ac_includes_default"
18675if test "x$ac_cv_type_long_long" = xyes; then :
18676
18677cat >>confdefs.h <<_ACEOF
18678#define HAVE_LONG_LONG 1
18679_ACEOF
18680
18681
18682fi
18683
18684# The cast to long int works around a bug in the HP C Compiler
18685# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
18686# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
18687# This bug is HP SR number 8606223364.
18688{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5
18689$as_echo_n "checking size of short... " >&6; }
18690if ${ac_cv_sizeof_short+:} false; then :
18691  $as_echo_n "(cached) " >&6
18692else
18693  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (short))" "ac_cv_sizeof_short"        "$ac_includes_default"; then :
18694
18695else
18696  if test "$ac_cv_type_short" = yes; then
18697     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
18698$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18699as_fn_error 77 "cannot compute sizeof (short)
18700See \`config.log' for more details" "$LINENO" 5; }
18701   else
18702     ac_cv_sizeof_short=0
18703   fi
18704fi
18705
18706fi
18707{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5
18708$as_echo "$ac_cv_sizeof_short" >&6; }
18709
18710
18711
18712cat >>confdefs.h <<_ACEOF
18713#define SIZEOF_SHORT $ac_cv_sizeof_short
18714_ACEOF
18715
18716
18717# The cast to long int works around a bug in the HP C Compiler
18718# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
18719# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
18720# This bug is HP SR number 8606223364.
18721{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5
18722$as_echo_n "checking size of int... " >&6; }
18723if ${ac_cv_sizeof_int+:} false; then :
18724  $as_echo_n "(cached) " >&6
18725else
18726  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int"        "$ac_includes_default"; then :
18727
18728else
18729  if test "$ac_cv_type_int" = yes; then
18730     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
18731$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18732as_fn_error 77 "cannot compute sizeof (int)
18733See \`config.log' for more details" "$LINENO" 5; }
18734   else
18735     ac_cv_sizeof_int=0
18736   fi
18737fi
18738
18739fi
18740{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5
18741$as_echo "$ac_cv_sizeof_int" >&6; }
18742
18743
18744
18745cat >>confdefs.h <<_ACEOF
18746#define SIZEOF_INT $ac_cv_sizeof_int
18747_ACEOF
18748
18749
18750# The cast to long int works around a bug in the HP C Compiler
18751# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
18752# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
18753# This bug is HP SR number 8606223364.
18754{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
18755$as_echo_n "checking size of long... " >&6; }
18756if ${ac_cv_sizeof_long+:} false; then :
18757  $as_echo_n "(cached) " >&6
18758else
18759  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long"        "$ac_includes_default"; then :
18760
18761else
18762  if test "$ac_cv_type_long" = yes; then
18763     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
18764$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18765as_fn_error 77 "cannot compute sizeof (long)
18766See \`config.log' for more details" "$LINENO" 5; }
18767   else
18768     ac_cv_sizeof_long=0
18769   fi
18770fi
18771
18772fi
18773{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
18774$as_echo "$ac_cv_sizeof_long" >&6; }
18775
18776
18777
18778cat >>confdefs.h <<_ACEOF
18779#define SIZEOF_LONG $ac_cv_sizeof_long
18780_ACEOF
18781
18782
18783
18784case "$ac_cv_type_long_long" in
18785 no)
18786    ;;
18787 *)
18788    # The cast to long int works around a bug in the HP C Compiler
18789# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
18790# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
18791# This bug is HP SR number 8606223364.
18792{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5
18793$as_echo_n "checking size of long long... " >&6; }
18794if ${ac_cv_sizeof_long_long+:} false; then :
18795  $as_echo_n "(cached) " >&6
18796else
18797  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long"        "$ac_includes_default"; then :
18798
18799else
18800  if test "$ac_cv_type_long_long" = yes; then
18801     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
18802$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18803as_fn_error 77 "cannot compute sizeof (long long)
18804See \`config.log' for more details" "$LINENO" 5; }
18805   else
18806     ac_cv_sizeof_long_long=0
18807   fi
18808fi
18809
18810fi
18811{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5
18812$as_echo "$ac_cv_sizeof_long_long" >&6; }
18813
18814
18815
18816cat >>confdefs.h <<_ACEOF
18817#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
18818_ACEOF
18819
18820
18821    ;;
18822esac
18823
18824case "$ac_cv_c_char_unsigned$ac_cv_sizeof_signed_char$ac_cv_type_s_char" in
18825 *yes)
18826    # We have a typedef for s_char.  Might as well believe it...
18827    ;;
18828 no0no)
18829    # We have signed chars, can't say 'signed char', no s_char typedef.
18830
18831$as_echo "#define NEED_S_CHAR_TYPEDEF 1" >>confdefs.h
18832
18833    ;;
18834 no1no)
18835    # We have signed chars, can say 'signed char', no s_char typedef.
18836
18837$as_echo "#define NEED_S_CHAR_TYPEDEF 1" >>confdefs.h
18838
18839    ;;
18840 yes0no)
18841    # We have unsigned chars, can't say 'signed char', no s_char typedef.
18842    as_fn_error $? "No way to specify a signed character!" "$LINENO" 5
18843    ;;
18844 yes1no)
18845    # We have unsigned chars, can say 'signed char', no s_char typedef.
18846
18847$as_echo "#define NEED_S_CHAR_TYPEDEF 1" >>confdefs.h
18848
18849    ;;
18850esac
18851
18852{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5
18853$as_echo_n "checking for uid_t in sys/types.h... " >&6; }
18854if ${ac_cv_type_uid_t+:} false; then :
18855  $as_echo_n "(cached) " >&6
18856else
18857  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18858/* end confdefs.h.  */
18859#include <sys/types.h>
18860
18861_ACEOF
18862if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18863  $EGREP "uid_t" >/dev/null 2>&1; then :
18864  ac_cv_type_uid_t=yes
18865else
18866  ac_cv_type_uid_t=no
18867fi
18868rm -f conftest*
18869
18870fi
18871{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5
18872$as_echo "$ac_cv_type_uid_t" >&6; }
18873if test $ac_cv_type_uid_t = no; then
18874
18875$as_echo "#define uid_t int" >>confdefs.h
18876
18877
18878$as_echo "#define gid_t int" >>confdefs.h
18879
18880fi
18881
18882
18883
18884
18885
18886
18887{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we're including debugging code" >&5
18888$as_echo_n "checking if we're including debugging code... " >&6; }
18889# Check whether --enable-debugging was given.
18890if test "${enable_debugging+set}" = set; then :
18891  enableval=$enable_debugging; ntp_ok=$enableval
18892else
18893  ntp_ok=yes
18894
18895fi
18896
18897case "$ntp_ok" in
18898 yes)
18899
18900$as_echo "#define DEBUG 1" >>confdefs.h
18901
18902esac
18903{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
18904$as_echo "$ntp_ok" >&6; }
18905
18906
18907
18908# check if we can compile with pthreads
18909for ac_header in semaphore.h
18910do :
18911  ac_fn_c_check_header_mongrel "$LINENO" "semaphore.h" "ac_cv_header_semaphore_h" "$ac_includes_default"
18912if test "x$ac_cv_header_semaphore_h" = xyes; then :
18913  cat >>confdefs.h <<_ACEOF
18914#define HAVE_SEMAPHORE_H 1
18915_ACEOF
18916
18917fi
18918
18919done
18920
18921for ac_func in socketpair
18922do :
18923  ac_fn_c_check_func "$LINENO" "socketpair" "ac_cv_func_socketpair"
18924if test "x$ac_cv_func_socketpair" = xyes; then :
18925  cat >>confdefs.h <<_ACEOF
18926#define HAVE_SOCKETPAIR 1
18927_ACEOF
18928
18929fi
18930done
18931
18932# Check whether --enable-thread-support was given.
18933if test "${enable_thread_support+set}" = set; then :
18934  enableval=$enable_thread_support;
18935else
18936  enable_thread_support=yes
18937
18938fi
18939
18940have_pthreads=no
18941case "$enable_thread_support" in
18942 no) ;;
18943 *)
18944    ol_found_pthreads=no
18945
18946
18947
18948ac_ext=c
18949ac_cpp='$CPP $CPPFLAGS'
18950ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
18951ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
18952ac_compiler_gnu=$ac_cv_c_compiler_gnu
18953
18954# OpenLDAP --with-threads
18955
18956# Check whether --with-threads was given.
18957if test "${with_threads+set}" = set; then :
18958  withval=$with_threads;
18959	ol_arg=invalid
18960	for ol_val in auto nt posix mach pth lwp yes no manual  ; do
18961		if test "$withval" = "$ol_val" ; then
18962			ol_arg="$ol_val"
18963		fi
18964	done
18965	if test "$ol_arg" = "invalid" ; then
18966		as_fn_error $? "bad value $withval for --with-threads" "$LINENO" 5
18967	fi
18968	ol_with_threads="$ol_arg"
18969
18970else
18971  	ol_with_threads="auto"
18972fi
18973# end --with-threads
18974
18975
18976case "$ol_with_threads$host" in
18977 auto*-*-solaris2.[0-6])
18978        ol_with_threads=no
18979    ;;
18980esac
18981
18982
18983ol_aix_threads=no
18984case "$host" in
18985*-*-aix*) 	if test -z "$CC" ; then
18986		case "$ol_with_threads" in
18987		auto | yes |  posix) ol_aix_threads=yes ;;
18988		esac
18989	fi
18990;;
18991esac
18992
18993if test $ol_aix_threads = yes ; then
18994	if test -z "${CC}" ; then
18995		for ac_prog in cc_r xlc_r cc
18996do
18997  # Extract the first word of "$ac_prog", so it can be a program name with args.
18998set dummy $ac_prog; ac_word=$2
18999{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19000$as_echo_n "checking for $ac_word... " >&6; }
19001if ${ac_cv_prog_CC+:} false; then :
19002  $as_echo_n "(cached) " >&6
19003else
19004  if test -n "$CC"; then
19005  ac_cv_prog_CC="$CC" # Let the user override the test.
19006else
19007as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19008for as_dir in $PATH
19009do
19010  IFS=$as_save_IFS
19011  test -z "$as_dir" && as_dir=.
19012    for ac_exec_ext in '' $ac_executable_extensions; do
19013  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19014    ac_cv_prog_CC="$ac_prog"
19015    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19016    break 2
19017  fi
19018done
19019  done
19020IFS=$as_save_IFS
19021
19022fi
19023fi
19024CC=$ac_cv_prog_CC
19025if test -n "$CC"; then
19026  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
19027$as_echo "$CC" >&6; }
19028else
19029  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19030$as_echo "no" >&6; }
19031fi
19032
19033
19034  test -n "$CC" && break
19035done
19036
19037
19038		if test "$CC" = cc ; then
19039						if test $ol_with_threads != auto ; then
19040				as_fn_error $? "--with-threads requires cc_r (or other suitable compiler) on AIX" "$LINENO" 5
19041			else
19042				{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: disabling threads, no cc_r on AIX" >&5
19043$as_echo "$as_me: WARNING: disabling threads, no cc_r on AIX" >&2;}
19044			fi
19045			ol_with_threads=no
19046  		fi
19047	fi
19048
19049	case ${CC} in cc_r | xlc_r)
19050		ol_with_threads=posix
19051		ol_cv_pthread_create=yes
19052		;;
19053	esac
19054fi
19055
19056ol_link_threads=no
19057# OpenLDAP --with-yielding_select
19058
19059# Check whether --with-yielding_select was given.
19060if test "${with_yielding_select+set}" = set; then :
19061  withval=$with_yielding_select;
19062	ol_arg=invalid
19063	for ol_val in auto yes no manual  ; do
19064		if test "$withval" = "$ol_val" ; then
19065			ol_arg="$ol_val"
19066		fi
19067	done
19068	if test "$ol_arg" = "invalid" ; then
19069		as_fn_error $? "bad value $withval for --with-yielding_select" "$LINENO" 5
19070	fi
19071	ol_with_yielding_select="$ol_arg"
19072
19073else
19074  	ol_with_yielding_select="auto"
19075fi
19076# end --with-yielding_select
19077
19078
19079case $ol_with_threads in auto | yes | nt)
19080
19081
19082	ac_fn_c_check_func "$LINENO" "_beginthread" "ac_cv_func__beginthread"
19083if test "x$ac_cv_func__beginthread" = xyes; then :
19084
19085fi
19086
19087
19088	if test $ac_cv_func__beginthread = yes ; then
19089
19090$as_echo "#define HAVE_NT_THREADS 1" >>confdefs.h
19091
19092		ol_cv_nt_threads=yes
19093	fi
19094
19095
19096	if test "$ol_cv_nt_threads" = yes ; then
19097		ol_link_threads=nt
19098		ol_with_threads=found
19099		ol_with_yielding_select=yes
19100
19101
19102$as_echo "#define HAVE_NT_SERVICE_MANAGER 1" >>confdefs.h
19103
19104
19105$as_echo "#define HAVE_NT_EVENT_LOG 1" >>confdefs.h
19106
19107	fi
19108
19109	if test $ol_with_threads = nt ; then
19110		as_fn_error $? "could not locate NT Threads" "$LINENO" 5
19111	fi
19112	;;
19113esac
19114
19115case $ol_with_threads in auto | yes | posix)
19116
19117	for ac_header in pthread.h
19118do :
19119  ac_fn_c_check_header_mongrel "$LINENO" "pthread.h" "ac_cv_header_pthread_h" "$ac_includes_default"
19120if test "x$ac_cv_header_pthread_h" = xyes; then :
19121  cat >>confdefs.h <<_ACEOF
19122#define HAVE_PTHREAD_H 1
19123_ACEOF
19124
19125fi
19126
19127done
19128
19129
19130	if test $ac_cv_header_pthread_h = yes ; then
19131		{ $as_echo "$as_me:${as_lineno-$LINENO}: checking POSIX thread version" >&5
19132$as_echo_n "checking POSIX thread version... " >&6; }
19133if ${ol_cv_pthread_version+:} false; then :
19134  $as_echo_n "(cached) " >&6
19135else
19136
19137	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19138/* end confdefs.h.  */
19139
19140#		include <pthread.h>
19141
19142int
19143main ()
19144{
19145
19146		int i = PTHREAD_CREATE_JOINABLE;
19147
19148  ;
19149  return 0;
19150}
19151_ACEOF
19152if ac_fn_c_try_compile "$LINENO"; then :
19153
19154	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19155/* end confdefs.h.  */
19156#include <pthread.h>
19157
19158_ACEOF
19159if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19160  $EGREP "pthread_detach" >/dev/null 2>&1; then :
19161  ol_cv_pthread_version=10
19162else
19163  ol_cv_pthread_version=8
19164fi
19165rm -f conftest*
19166
19167else
19168
19169	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19170/* end confdefs.h.  */
19171
19172#		include <pthread.h>
19173#		ifdef PTHREAD_CREATE_UNDETACHED
19174		draft7
19175#		endif
19176
19177_ACEOF
19178if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19179  $EGREP "draft7" >/dev/null 2>&1; then :
19180  ol_cv_pthread_version=7
19181else
19182
19183	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19184/* end confdefs.h.  */
19185#include <pthread.h>
19186
19187_ACEOF
19188if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19189  $EGREP "pthread_attr_init" >/dev/null 2>&1; then :
19190  ol_cv_pthread_version=6
19191else
19192
19193	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19194/* end confdefs.h.  */
19195
19196#		include <pthread.h>
19197#ifdef		PTHREAD_MUTEX_INITIALIZER
19198		draft5
19199#endif
19200
19201_ACEOF
19202if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19203  $EGREP "draft5" >/dev/null 2>&1; then :
19204  ol_cv_pthread_version=5
19205else
19206  ol_cv_pthread_version=4
19207fi
19208rm -f conftest*
19209
19210fi
19211rm -f conftest*
19212
19213fi
19214rm -f conftest*
19215
19216fi
19217rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19218
19219fi
19220{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_version" >&5
19221$as_echo "$ol_cv_pthread_version" >&6; }
19222
19223
19224		if test $ol_cv_pthread_version != 0 ; then
19225
19226cat >>confdefs.h <<_ACEOF
19227#define HAVE_PTHREADS $ol_cv_pthread_version
19228_ACEOF
19229
19230		else
19231			as_fn_error $? "unknown pthread version" "$LINENO" 5
19232		fi
19233
19234		# consider threads found
19235		ol_with_threads=found
19236
19237
19238	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LinuxThreads pthread.h" >&5
19239$as_echo_n "checking for LinuxThreads pthread.h... " >&6; }
19240if ${ol_cv_header_linux_threads+:} false; then :
19241  $as_echo_n "(cached) " >&6
19242else
19243  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19244/* end confdefs.h.  */
19245#include <pthread.h>
19246_ACEOF
19247if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19248  $EGREP "pthread_kill_other_threads_np" >/dev/null 2>&1; then :
19249  ol_cv_header_linux_threads=yes
19250else
19251  ol_cv_header_linux_threads=no
19252fi
19253rm -f conftest*
19254
19255
19256fi
19257{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_header_linux_threads" >&5
19258$as_echo "$ol_cv_header_linux_threads" >&6; }
19259	if test $ol_cv_header_linux_threads = yes; then
19260
19261$as_echo "#define HAVE_LINUX_THREADS 1" >>confdefs.h
19262
19263	fi
19264
19265
19266	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU Pth pthread.h" >&5
19267$as_echo_n "checking for GNU Pth pthread.h... " >&6; }
19268if ${ol_cv_header_gnu_pth_pthread_h+:} false; then :
19269  $as_echo_n "(cached) " >&6
19270else
19271  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19272/* end confdefs.h.  */
19273#include <pthread.h>
19274#ifdef _POSIX_THREAD_IS_GNU_PTH
19275	__gnu_pth__;
19276#endif
19277
19278_ACEOF
19279if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19280  $EGREP "__gnu_pth__" >/dev/null 2>&1; then :
19281  ol_cv_header_gnu_pth_pthread_h=yes
19282else
19283  ol_cv_header_gnu_pth_pthread_h=no
19284fi
19285rm -f conftest*
19286
19287
19288fi
19289{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_header_gnu_pth_pthread_h" >&5
19290$as_echo "$ol_cv_header_gnu_pth_pthread_h" >&6; }
19291
19292
19293		if test $ol_cv_header_gnu_pth_pthread_h = no ; then
19294			for ac_header in sched.h
19295do :
19296  ac_fn_c_check_header_mongrel "$LINENO" "sched.h" "ac_cv_header_sched_h" "$ac_includes_default"
19297if test "x$ac_cv_header_sched_h" = xyes; then :
19298  cat >>confdefs.h <<_ACEOF
19299#define HAVE_SCHED_H 1
19300_ACEOF
19301
19302fi
19303
19304done
19305
19306		fi
19307
19308
19309				{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in default libraries" >&5
19310$as_echo_n "checking for pthread_create in default libraries... " >&6; }
19311if ${ol_cv_pthread_create+:} false; then :
19312  $as_echo_n "(cached) " >&6
19313else
19314
19315			if test "$cross_compiling" = yes; then :
19316  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19317/* end confdefs.h.  */
19318
19319/* pthread test headers */
19320#include <pthread.h>
19321#if HAVE_PTHREADS < 7
19322#include <errno.h>
19323#endif
19324#ifndef NULL
19325#define NULL (void*)0
19326#endif
19327
19328static void *task(p)
19329	void *p;
19330{
19331	return (void *) (p == NULL);
19332}
19333
19334int
19335main ()
19336{
19337
19338	/* pthread test function */
19339#ifndef PTHREAD_CREATE_DETACHED
19340#define	PTHREAD_CREATE_DETACHED	1
19341#endif
19342	pthread_t t;
19343	int status;
19344	int detach = PTHREAD_CREATE_DETACHED;
19345
19346#if HAVE_PTHREADS > 4
19347	/* Final pthreads */
19348	pthread_attr_t attr;
19349
19350	status = pthread_attr_init(&attr);
19351	if( status ) return status;
19352
19353#if HAVE_PTHREADS < 7
19354	status = pthread_attr_setdetachstate(&attr, &detach);
19355	if( status < 0 ) status = errno;
19356#else
19357	status = pthread_attr_setdetachstate(&attr, detach);
19358#endif
19359	if( status ) return status;
19360	status = pthread_create( &t, &attr, task, NULL );
19361#if HAVE_PTHREADS < 7
19362	if( status < 0 ) status = errno;
19363#endif
19364	if( status ) return status;
19365#else
19366	/* Draft 4 pthreads */
19367	status = pthread_create( &t, pthread_attr_default, task, NULL );
19368	if( status ) return errno;
19369
19370	/* give thread a chance to complete */
19371	/* it should remain joinable and hence detachable */
19372	sleep( 1 );
19373
19374	status = pthread_detach( &t );
19375	if( status ) return errno;
19376#endif
19377
19378#ifdef HAVE_LINUX_THREADS
19379	pthread_kill_other_threads_np();
19380#endif
19381
19382	return 0;
19383
19384  ;
19385  return 0;
19386}
19387_ACEOF
19388if ac_fn_c_try_link "$LINENO"; then :
19389  ol_cv_pthread_create=yes
19390else
19391  ol_cv_pthread_create=no
19392fi
19393rm -f core conftest.err conftest.$ac_objext \
19394    conftest$ac_exeext conftest.$ac_ext
19395else
19396  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19397/* end confdefs.h.  */
19398
19399
19400/* pthread test headers */
19401#include <pthread.h>
19402#if HAVE_PTHREADS < 7
19403#include <errno.h>
19404#endif
19405#ifndef NULL
19406#define NULL (void*)0
19407#endif
19408
19409static void *task(p)
19410	void *p;
19411{
19412	return (void *) (p == NULL);
19413}
19414
19415
19416int main(argc, argv)
19417	int argc;
19418	char **argv;
19419{
19420
19421	/* pthread test function */
19422#ifndef PTHREAD_CREATE_DETACHED
19423#define	PTHREAD_CREATE_DETACHED	1
19424#endif
19425	pthread_t t;
19426	int status;
19427	int detach = PTHREAD_CREATE_DETACHED;
19428
19429#if HAVE_PTHREADS > 4
19430	/* Final pthreads */
19431	pthread_attr_t attr;
19432
19433	status = pthread_attr_init(&attr);
19434	if( status ) return status;
19435
19436#if HAVE_PTHREADS < 7
19437	status = pthread_attr_setdetachstate(&attr, &detach);
19438	if( status < 0 ) status = errno;
19439#else
19440	status = pthread_attr_setdetachstate(&attr, detach);
19441#endif
19442	if( status ) return status;
19443	status = pthread_create( &t, &attr, task, NULL );
19444#if HAVE_PTHREADS < 7
19445	if( status < 0 ) status = errno;
19446#endif
19447	if( status ) return status;
19448#else
19449	/* Draft 4 pthreads */
19450	status = pthread_create( &t, pthread_attr_default, task, NULL );
19451	if( status ) return errno;
19452
19453	/* give thread a chance to complete */
19454	/* it should remain joinable and hence detachable */
19455	sleep( 1 );
19456
19457	status = pthread_detach( &t );
19458	if( status ) return errno;
19459#endif
19460
19461#ifdef HAVE_LINUX_THREADS
19462	pthread_kill_other_threads_np();
19463#endif
19464
19465	return 0;
19466
19467}
19468
19469_ACEOF
19470if ac_fn_c_try_run "$LINENO"; then :
19471  ol_cv_pthread_create=yes
19472else
19473  ol_cv_pthread_create=no
19474fi
19475rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19476  conftest.$ac_objext conftest.beam conftest.$ac_ext
19477fi
19478
19479fi
19480{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_create" >&5
19481$as_echo "$ol_cv_pthread_create" >&6; }
19482
19483		if test $ol_cv_pthread_create != no ; then
19484			ol_link_threads=posix
19485			ol_link_pthreads=""
19486		fi
19487
19488		# Pthread try link: -kthread (ol_cv_pthread_kthread)
19489if test "$ol_link_threads" = no ; then
19490	# try -kthread
19491	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -kthread" >&5
19492$as_echo_n "checking for pthread link with -kthread... " >&6; }
19493if ${ol_cv_pthread_kthread+:} false; then :
19494  $as_echo_n "(cached) " >&6
19495else
19496
19497		# save the flags
19498		ol_LIBS="$LIBS"
19499		LIBS="-kthread $LIBS"
19500
19501		if test "$cross_compiling" = yes; then :
19502  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19503/* end confdefs.h.  */
19504
19505/* pthread test headers */
19506#include <pthread.h>
19507#if HAVE_PTHREADS < 7
19508#include <errno.h>
19509#endif
19510#ifndef NULL
19511#define NULL (void*)0
19512#endif
19513
19514static void *task(p)
19515	void *p;
19516{
19517	return (void *) (p == NULL);
19518}
19519
19520int
19521main ()
19522{
19523
19524	/* pthread test function */
19525#ifndef PTHREAD_CREATE_DETACHED
19526#define	PTHREAD_CREATE_DETACHED	1
19527#endif
19528	pthread_t t;
19529	int status;
19530	int detach = PTHREAD_CREATE_DETACHED;
19531
19532#if HAVE_PTHREADS > 4
19533	/* Final pthreads */
19534	pthread_attr_t attr;
19535
19536	status = pthread_attr_init(&attr);
19537	if( status ) return status;
19538
19539#if HAVE_PTHREADS < 7
19540	status = pthread_attr_setdetachstate(&attr, &detach);
19541	if( status < 0 ) status = errno;
19542#else
19543	status = pthread_attr_setdetachstate(&attr, detach);
19544#endif
19545	if( status ) return status;
19546	status = pthread_create( &t, &attr, task, NULL );
19547#if HAVE_PTHREADS < 7
19548	if( status < 0 ) status = errno;
19549#endif
19550	if( status ) return status;
19551#else
19552	/* Draft 4 pthreads */
19553	status = pthread_create( &t, pthread_attr_default, task, NULL );
19554	if( status ) return errno;
19555
19556	/* give thread a chance to complete */
19557	/* it should remain joinable and hence detachable */
19558	sleep( 1 );
19559
19560	status = pthread_detach( &t );
19561	if( status ) return errno;
19562#endif
19563
19564#ifdef HAVE_LINUX_THREADS
19565	pthread_kill_other_threads_np();
19566#endif
19567
19568	return 0;
19569
19570  ;
19571  return 0;
19572}
19573_ACEOF
19574if ac_fn_c_try_link "$LINENO"; then :
19575  ol_cv_pthread_kthread=yes
19576else
19577  ol_cv_pthread_kthread=no
19578fi
19579rm -f core conftest.err conftest.$ac_objext \
19580    conftest$ac_exeext conftest.$ac_ext
19581else
19582  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19583/* end confdefs.h.  */
19584
19585
19586/* pthread test headers */
19587#include <pthread.h>
19588#if HAVE_PTHREADS < 7
19589#include <errno.h>
19590#endif
19591#ifndef NULL
19592#define NULL (void*)0
19593#endif
19594
19595static void *task(p)
19596	void *p;
19597{
19598	return (void *) (p == NULL);
19599}
19600
19601
19602int main(argc, argv)
19603	int argc;
19604	char **argv;
19605{
19606
19607	/* pthread test function */
19608#ifndef PTHREAD_CREATE_DETACHED
19609#define	PTHREAD_CREATE_DETACHED	1
19610#endif
19611	pthread_t t;
19612	int status;
19613	int detach = PTHREAD_CREATE_DETACHED;
19614
19615#if HAVE_PTHREADS > 4
19616	/* Final pthreads */
19617	pthread_attr_t attr;
19618
19619	status = pthread_attr_init(&attr);
19620	if( status ) return status;
19621
19622#if HAVE_PTHREADS < 7
19623	status = pthread_attr_setdetachstate(&attr, &detach);
19624	if( status < 0 ) status = errno;
19625#else
19626	status = pthread_attr_setdetachstate(&attr, detach);
19627#endif
19628	if( status ) return status;
19629	status = pthread_create( &t, &attr, task, NULL );
19630#if HAVE_PTHREADS < 7
19631	if( status < 0 ) status = errno;
19632#endif
19633	if( status ) return status;
19634#else
19635	/* Draft 4 pthreads */
19636	status = pthread_create( &t, pthread_attr_default, task, NULL );
19637	if( status ) return errno;
19638
19639	/* give thread a chance to complete */
19640	/* it should remain joinable and hence detachable */
19641	sleep( 1 );
19642
19643	status = pthread_detach( &t );
19644	if( status ) return errno;
19645#endif
19646
19647#ifdef HAVE_LINUX_THREADS
19648	pthread_kill_other_threads_np();
19649#endif
19650
19651	return 0;
19652
19653}
19654
19655_ACEOF
19656if ac_fn_c_try_run "$LINENO"; then :
19657  ol_cv_pthread_kthread=yes
19658else
19659  ol_cv_pthread_kthread=no
19660fi
19661rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19662  conftest.$ac_objext conftest.beam conftest.$ac_ext
19663fi
19664
19665
19666		# restore the LIBS
19667		LIBS="$ol_LIBS"
19668
19669fi
19670{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_kthread" >&5
19671$as_echo "$ol_cv_pthread_kthread" >&6; }
19672
19673	if test $ol_cv_pthread_kthread = yes ; then
19674		ol_link_pthreads="-kthread"
19675		ol_link_threads=posix
19676	fi
19677fi
19678
19679		# Pthread try link: -pthread (ol_cv_pthread_pthread)
19680if test "$ol_link_threads" = no ; then
19681	# try -pthread
19682	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -pthread" >&5
19683$as_echo_n "checking for pthread link with -pthread... " >&6; }
19684if ${ol_cv_pthread_pthread+:} false; then :
19685  $as_echo_n "(cached) " >&6
19686else
19687
19688		# save the flags
19689		ol_LIBS="$LIBS"
19690		LIBS="-pthread $LIBS"
19691
19692		if test "$cross_compiling" = yes; then :
19693  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19694/* end confdefs.h.  */
19695
19696/* pthread test headers */
19697#include <pthread.h>
19698#if HAVE_PTHREADS < 7
19699#include <errno.h>
19700#endif
19701#ifndef NULL
19702#define NULL (void*)0
19703#endif
19704
19705static void *task(p)
19706	void *p;
19707{
19708	return (void *) (p == NULL);
19709}
19710
19711int
19712main ()
19713{
19714
19715	/* pthread test function */
19716#ifndef PTHREAD_CREATE_DETACHED
19717#define	PTHREAD_CREATE_DETACHED	1
19718#endif
19719	pthread_t t;
19720	int status;
19721	int detach = PTHREAD_CREATE_DETACHED;
19722
19723#if HAVE_PTHREADS > 4
19724	/* Final pthreads */
19725	pthread_attr_t attr;
19726
19727	status = pthread_attr_init(&attr);
19728	if( status ) return status;
19729
19730#if HAVE_PTHREADS < 7
19731	status = pthread_attr_setdetachstate(&attr, &detach);
19732	if( status < 0 ) status = errno;
19733#else
19734	status = pthread_attr_setdetachstate(&attr, detach);
19735#endif
19736	if( status ) return status;
19737	status = pthread_create( &t, &attr, task, NULL );
19738#if HAVE_PTHREADS < 7
19739	if( status < 0 ) status = errno;
19740#endif
19741	if( status ) return status;
19742#else
19743	/* Draft 4 pthreads */
19744	status = pthread_create( &t, pthread_attr_default, task, NULL );
19745	if( status ) return errno;
19746
19747	/* give thread a chance to complete */
19748	/* it should remain joinable and hence detachable */
19749	sleep( 1 );
19750
19751	status = pthread_detach( &t );
19752	if( status ) return errno;
19753#endif
19754
19755#ifdef HAVE_LINUX_THREADS
19756	pthread_kill_other_threads_np();
19757#endif
19758
19759	return 0;
19760
19761  ;
19762  return 0;
19763}
19764_ACEOF
19765if ac_fn_c_try_link "$LINENO"; then :
19766  ol_cv_pthread_pthread=yes
19767else
19768  ol_cv_pthread_pthread=no
19769fi
19770rm -f core conftest.err conftest.$ac_objext \
19771    conftest$ac_exeext conftest.$ac_ext
19772else
19773  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19774/* end confdefs.h.  */
19775
19776
19777/* pthread test headers */
19778#include <pthread.h>
19779#if HAVE_PTHREADS < 7
19780#include <errno.h>
19781#endif
19782#ifndef NULL
19783#define NULL (void*)0
19784#endif
19785
19786static void *task(p)
19787	void *p;
19788{
19789	return (void *) (p == NULL);
19790}
19791
19792
19793int main(argc, argv)
19794	int argc;
19795	char **argv;
19796{
19797
19798	/* pthread test function */
19799#ifndef PTHREAD_CREATE_DETACHED
19800#define	PTHREAD_CREATE_DETACHED	1
19801#endif
19802	pthread_t t;
19803	int status;
19804	int detach = PTHREAD_CREATE_DETACHED;
19805
19806#if HAVE_PTHREADS > 4
19807	/* Final pthreads */
19808	pthread_attr_t attr;
19809
19810	status = pthread_attr_init(&attr);
19811	if( status ) return status;
19812
19813#if HAVE_PTHREADS < 7
19814	status = pthread_attr_setdetachstate(&attr, &detach);
19815	if( status < 0 ) status = errno;
19816#else
19817	status = pthread_attr_setdetachstate(&attr, detach);
19818#endif
19819	if( status ) return status;
19820	status = pthread_create( &t, &attr, task, NULL );
19821#if HAVE_PTHREADS < 7
19822	if( status < 0 ) status = errno;
19823#endif
19824	if( status ) return status;
19825#else
19826	/* Draft 4 pthreads */
19827	status = pthread_create( &t, pthread_attr_default, task, NULL );
19828	if( status ) return errno;
19829
19830	/* give thread a chance to complete */
19831	/* it should remain joinable and hence detachable */
19832	sleep( 1 );
19833
19834	status = pthread_detach( &t );
19835	if( status ) return errno;
19836#endif
19837
19838#ifdef HAVE_LINUX_THREADS
19839	pthread_kill_other_threads_np();
19840#endif
19841
19842	return 0;
19843
19844}
19845
19846_ACEOF
19847if ac_fn_c_try_run "$LINENO"; then :
19848  ol_cv_pthread_pthread=yes
19849else
19850  ol_cv_pthread_pthread=no
19851fi
19852rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19853  conftest.$ac_objext conftest.beam conftest.$ac_ext
19854fi
19855
19856
19857		# restore the LIBS
19858		LIBS="$ol_LIBS"
19859
19860fi
19861{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_pthread" >&5
19862$as_echo "$ol_cv_pthread_pthread" >&6; }
19863
19864	if test $ol_cv_pthread_pthread = yes ; then
19865		ol_link_pthreads="-pthread"
19866		ol_link_threads=posix
19867	fi
19868fi
19869
19870		# Pthread try link: -pthreads (ol_cv_pthread_pthreads)
19871if test "$ol_link_threads" = no ; then
19872	# try -pthreads
19873	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -pthreads" >&5
19874$as_echo_n "checking for pthread link with -pthreads... " >&6; }
19875if ${ol_cv_pthread_pthreads+:} false; then :
19876  $as_echo_n "(cached) " >&6
19877else
19878
19879		# save the flags
19880		ol_LIBS="$LIBS"
19881		LIBS="-pthreads $LIBS"
19882
19883		if test "$cross_compiling" = yes; then :
19884  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19885/* end confdefs.h.  */
19886
19887/* pthread test headers */
19888#include <pthread.h>
19889#if HAVE_PTHREADS < 7
19890#include <errno.h>
19891#endif
19892#ifndef NULL
19893#define NULL (void*)0
19894#endif
19895
19896static void *task(p)
19897	void *p;
19898{
19899	return (void *) (p == NULL);
19900}
19901
19902int
19903main ()
19904{
19905
19906	/* pthread test function */
19907#ifndef PTHREAD_CREATE_DETACHED
19908#define	PTHREAD_CREATE_DETACHED	1
19909#endif
19910	pthread_t t;
19911	int status;
19912	int detach = PTHREAD_CREATE_DETACHED;
19913
19914#if HAVE_PTHREADS > 4
19915	/* Final pthreads */
19916	pthread_attr_t attr;
19917
19918	status = pthread_attr_init(&attr);
19919	if( status ) return status;
19920
19921#if HAVE_PTHREADS < 7
19922	status = pthread_attr_setdetachstate(&attr, &detach);
19923	if( status < 0 ) status = errno;
19924#else
19925	status = pthread_attr_setdetachstate(&attr, detach);
19926#endif
19927	if( status ) return status;
19928	status = pthread_create( &t, &attr, task, NULL );
19929#if HAVE_PTHREADS < 7
19930	if( status < 0 ) status = errno;
19931#endif
19932	if( status ) return status;
19933#else
19934	/* Draft 4 pthreads */
19935	status = pthread_create( &t, pthread_attr_default, task, NULL );
19936	if( status ) return errno;
19937
19938	/* give thread a chance to complete */
19939	/* it should remain joinable and hence detachable */
19940	sleep( 1 );
19941
19942	status = pthread_detach( &t );
19943	if( status ) return errno;
19944#endif
19945
19946#ifdef HAVE_LINUX_THREADS
19947	pthread_kill_other_threads_np();
19948#endif
19949
19950	return 0;
19951
19952  ;
19953  return 0;
19954}
19955_ACEOF
19956if ac_fn_c_try_link "$LINENO"; then :
19957  ol_cv_pthread_pthreads=yes
19958else
19959  ol_cv_pthread_pthreads=no
19960fi
19961rm -f core conftest.err conftest.$ac_objext \
19962    conftest$ac_exeext conftest.$ac_ext
19963else
19964  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19965/* end confdefs.h.  */
19966
19967
19968/* pthread test headers */
19969#include <pthread.h>
19970#if HAVE_PTHREADS < 7
19971#include <errno.h>
19972#endif
19973#ifndef NULL
19974#define NULL (void*)0
19975#endif
19976
19977static void *task(p)
19978	void *p;
19979{
19980	return (void *) (p == NULL);
19981}
19982
19983
19984int main(argc, argv)
19985	int argc;
19986	char **argv;
19987{
19988
19989	/* pthread test function */
19990#ifndef PTHREAD_CREATE_DETACHED
19991#define	PTHREAD_CREATE_DETACHED	1
19992#endif
19993	pthread_t t;
19994	int status;
19995	int detach = PTHREAD_CREATE_DETACHED;
19996
19997#if HAVE_PTHREADS > 4
19998	/* Final pthreads */
19999	pthread_attr_t attr;
20000
20001	status = pthread_attr_init(&attr);
20002	if( status ) return status;
20003
20004#if HAVE_PTHREADS < 7
20005	status = pthread_attr_setdetachstate(&attr, &detach);
20006	if( status < 0 ) status = errno;
20007#else
20008	status = pthread_attr_setdetachstate(&attr, detach);
20009#endif
20010	if( status ) return status;
20011	status = pthread_create( &t, &attr, task, NULL );
20012#if HAVE_PTHREADS < 7
20013	if( status < 0 ) status = errno;
20014#endif
20015	if( status ) return status;
20016#else
20017	/* Draft 4 pthreads */
20018	status = pthread_create( &t, pthread_attr_default, task, NULL );
20019	if( status ) return errno;
20020
20021	/* give thread a chance to complete */
20022	/* it should remain joinable and hence detachable */
20023	sleep( 1 );
20024
20025	status = pthread_detach( &t );
20026	if( status ) return errno;
20027#endif
20028
20029#ifdef HAVE_LINUX_THREADS
20030	pthread_kill_other_threads_np();
20031#endif
20032
20033	return 0;
20034
20035}
20036
20037_ACEOF
20038if ac_fn_c_try_run "$LINENO"; then :
20039  ol_cv_pthread_pthreads=yes
20040else
20041  ol_cv_pthread_pthreads=no
20042fi
20043rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20044  conftest.$ac_objext conftest.beam conftest.$ac_ext
20045fi
20046
20047
20048		# restore the LIBS
20049		LIBS="$ol_LIBS"
20050
20051fi
20052{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_pthreads" >&5
20053$as_echo "$ol_cv_pthread_pthreads" >&6; }
20054
20055	if test $ol_cv_pthread_pthreads = yes ; then
20056		ol_link_pthreads="-pthreads"
20057		ol_link_threads=posix
20058	fi
20059fi
20060
20061		# Pthread try link: -mthreads (ol_cv_pthread_mthreads)
20062if test "$ol_link_threads" = no ; then
20063	# try -mthreads
20064	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -mthreads" >&5
20065$as_echo_n "checking for pthread link with -mthreads... " >&6; }
20066if ${ol_cv_pthread_mthreads+:} false; then :
20067  $as_echo_n "(cached) " >&6
20068else
20069
20070		# save the flags
20071		ol_LIBS="$LIBS"
20072		LIBS="-mthreads $LIBS"
20073
20074		if test "$cross_compiling" = yes; then :
20075  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20076/* end confdefs.h.  */
20077
20078/* pthread test headers */
20079#include <pthread.h>
20080#if HAVE_PTHREADS < 7
20081#include <errno.h>
20082#endif
20083#ifndef NULL
20084#define NULL (void*)0
20085#endif
20086
20087static void *task(p)
20088	void *p;
20089{
20090	return (void *) (p == NULL);
20091}
20092
20093int
20094main ()
20095{
20096
20097	/* pthread test function */
20098#ifndef PTHREAD_CREATE_DETACHED
20099#define	PTHREAD_CREATE_DETACHED	1
20100#endif
20101	pthread_t t;
20102	int status;
20103	int detach = PTHREAD_CREATE_DETACHED;
20104
20105#if HAVE_PTHREADS > 4
20106	/* Final pthreads */
20107	pthread_attr_t attr;
20108
20109	status = pthread_attr_init(&attr);
20110	if( status ) return status;
20111
20112#if HAVE_PTHREADS < 7
20113	status = pthread_attr_setdetachstate(&attr, &detach);
20114	if( status < 0 ) status = errno;
20115#else
20116	status = pthread_attr_setdetachstate(&attr, detach);
20117#endif
20118	if( status ) return status;
20119	status = pthread_create( &t, &attr, task, NULL );
20120#if HAVE_PTHREADS < 7
20121	if( status < 0 ) status = errno;
20122#endif
20123	if( status ) return status;
20124#else
20125	/* Draft 4 pthreads */
20126	status = pthread_create( &t, pthread_attr_default, task, NULL );
20127	if( status ) return errno;
20128
20129	/* give thread a chance to complete */
20130	/* it should remain joinable and hence detachable */
20131	sleep( 1 );
20132
20133	status = pthread_detach( &t );
20134	if( status ) return errno;
20135#endif
20136
20137#ifdef HAVE_LINUX_THREADS
20138	pthread_kill_other_threads_np();
20139#endif
20140
20141	return 0;
20142
20143  ;
20144  return 0;
20145}
20146_ACEOF
20147if ac_fn_c_try_link "$LINENO"; then :
20148  ol_cv_pthread_mthreads=yes
20149else
20150  ol_cv_pthread_mthreads=no
20151fi
20152rm -f core conftest.err conftest.$ac_objext \
20153    conftest$ac_exeext conftest.$ac_ext
20154else
20155  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20156/* end confdefs.h.  */
20157
20158
20159/* pthread test headers */
20160#include <pthread.h>
20161#if HAVE_PTHREADS < 7
20162#include <errno.h>
20163#endif
20164#ifndef NULL
20165#define NULL (void*)0
20166#endif
20167
20168static void *task(p)
20169	void *p;
20170{
20171	return (void *) (p == NULL);
20172}
20173
20174
20175int main(argc, argv)
20176	int argc;
20177	char **argv;
20178{
20179
20180	/* pthread test function */
20181#ifndef PTHREAD_CREATE_DETACHED
20182#define	PTHREAD_CREATE_DETACHED	1
20183#endif
20184	pthread_t t;
20185	int status;
20186	int detach = PTHREAD_CREATE_DETACHED;
20187
20188#if HAVE_PTHREADS > 4
20189	/* Final pthreads */
20190	pthread_attr_t attr;
20191
20192	status = pthread_attr_init(&attr);
20193	if( status ) return status;
20194
20195#if HAVE_PTHREADS < 7
20196	status = pthread_attr_setdetachstate(&attr, &detach);
20197	if( status < 0 ) status = errno;
20198#else
20199	status = pthread_attr_setdetachstate(&attr, detach);
20200#endif
20201	if( status ) return status;
20202	status = pthread_create( &t, &attr, task, NULL );
20203#if HAVE_PTHREADS < 7
20204	if( status < 0 ) status = errno;
20205#endif
20206	if( status ) return status;
20207#else
20208	/* Draft 4 pthreads */
20209	status = pthread_create( &t, pthread_attr_default, task, NULL );
20210	if( status ) return errno;
20211
20212	/* give thread a chance to complete */
20213	/* it should remain joinable and hence detachable */
20214	sleep( 1 );
20215
20216	status = pthread_detach( &t );
20217	if( status ) return errno;
20218#endif
20219
20220#ifdef HAVE_LINUX_THREADS
20221	pthread_kill_other_threads_np();
20222#endif
20223
20224	return 0;
20225
20226}
20227
20228_ACEOF
20229if ac_fn_c_try_run "$LINENO"; then :
20230  ol_cv_pthread_mthreads=yes
20231else
20232  ol_cv_pthread_mthreads=no
20233fi
20234rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20235  conftest.$ac_objext conftest.beam conftest.$ac_ext
20236fi
20237
20238
20239		# restore the LIBS
20240		LIBS="$ol_LIBS"
20241
20242fi
20243{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_mthreads" >&5
20244$as_echo "$ol_cv_pthread_mthreads" >&6; }
20245
20246	if test $ol_cv_pthread_mthreads = yes ; then
20247		ol_link_pthreads="-mthreads"
20248		ol_link_threads=posix
20249	fi
20250fi
20251
20252		# Pthread try link: -thread (ol_cv_pthread_thread)
20253if test "$ol_link_threads" = no ; then
20254	# try -thread
20255	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -thread" >&5
20256$as_echo_n "checking for pthread link with -thread... " >&6; }
20257if ${ol_cv_pthread_thread+:} false; then :
20258  $as_echo_n "(cached) " >&6
20259else
20260
20261		# save the flags
20262		ol_LIBS="$LIBS"
20263		LIBS="-thread $LIBS"
20264
20265		if test "$cross_compiling" = yes; then :
20266  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20267/* end confdefs.h.  */
20268
20269/* pthread test headers */
20270#include <pthread.h>
20271#if HAVE_PTHREADS < 7
20272#include <errno.h>
20273#endif
20274#ifndef NULL
20275#define NULL (void*)0
20276#endif
20277
20278static void *task(p)
20279	void *p;
20280{
20281	return (void *) (p == NULL);
20282}
20283
20284int
20285main ()
20286{
20287
20288	/* pthread test function */
20289#ifndef PTHREAD_CREATE_DETACHED
20290#define	PTHREAD_CREATE_DETACHED	1
20291#endif
20292	pthread_t t;
20293	int status;
20294	int detach = PTHREAD_CREATE_DETACHED;
20295
20296#if HAVE_PTHREADS > 4
20297	/* Final pthreads */
20298	pthread_attr_t attr;
20299
20300	status = pthread_attr_init(&attr);
20301	if( status ) return status;
20302
20303#if HAVE_PTHREADS < 7
20304	status = pthread_attr_setdetachstate(&attr, &detach);
20305	if( status < 0 ) status = errno;
20306#else
20307	status = pthread_attr_setdetachstate(&attr, detach);
20308#endif
20309	if( status ) return status;
20310	status = pthread_create( &t, &attr, task, NULL );
20311#if HAVE_PTHREADS < 7
20312	if( status < 0 ) status = errno;
20313#endif
20314	if( status ) return status;
20315#else
20316	/* Draft 4 pthreads */
20317	status = pthread_create( &t, pthread_attr_default, task, NULL );
20318	if( status ) return errno;
20319
20320	/* give thread a chance to complete */
20321	/* it should remain joinable and hence detachable */
20322	sleep( 1 );
20323
20324	status = pthread_detach( &t );
20325	if( status ) return errno;
20326#endif
20327
20328#ifdef HAVE_LINUX_THREADS
20329	pthread_kill_other_threads_np();
20330#endif
20331
20332	return 0;
20333
20334  ;
20335  return 0;
20336}
20337_ACEOF
20338if ac_fn_c_try_link "$LINENO"; then :
20339  ol_cv_pthread_thread=yes
20340else
20341  ol_cv_pthread_thread=no
20342fi
20343rm -f core conftest.err conftest.$ac_objext \
20344    conftest$ac_exeext conftest.$ac_ext
20345else
20346  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20347/* end confdefs.h.  */
20348
20349
20350/* pthread test headers */
20351#include <pthread.h>
20352#if HAVE_PTHREADS < 7
20353#include <errno.h>
20354#endif
20355#ifndef NULL
20356#define NULL (void*)0
20357#endif
20358
20359static void *task(p)
20360	void *p;
20361{
20362	return (void *) (p == NULL);
20363}
20364
20365
20366int main(argc, argv)
20367	int argc;
20368	char **argv;
20369{
20370
20371	/* pthread test function */
20372#ifndef PTHREAD_CREATE_DETACHED
20373#define	PTHREAD_CREATE_DETACHED	1
20374#endif
20375	pthread_t t;
20376	int status;
20377	int detach = PTHREAD_CREATE_DETACHED;
20378
20379#if HAVE_PTHREADS > 4
20380	/* Final pthreads */
20381	pthread_attr_t attr;
20382
20383	status = pthread_attr_init(&attr);
20384	if( status ) return status;
20385
20386#if HAVE_PTHREADS < 7
20387	status = pthread_attr_setdetachstate(&attr, &detach);
20388	if( status < 0 ) status = errno;
20389#else
20390	status = pthread_attr_setdetachstate(&attr, detach);
20391#endif
20392	if( status ) return status;
20393	status = pthread_create( &t, &attr, task, NULL );
20394#if HAVE_PTHREADS < 7
20395	if( status < 0 ) status = errno;
20396#endif
20397	if( status ) return status;
20398#else
20399	/* Draft 4 pthreads */
20400	status = pthread_create( &t, pthread_attr_default, task, NULL );
20401	if( status ) return errno;
20402
20403	/* give thread a chance to complete */
20404	/* it should remain joinable and hence detachable */
20405	sleep( 1 );
20406
20407	status = pthread_detach( &t );
20408	if( status ) return errno;
20409#endif
20410
20411#ifdef HAVE_LINUX_THREADS
20412	pthread_kill_other_threads_np();
20413#endif
20414
20415	return 0;
20416
20417}
20418
20419_ACEOF
20420if ac_fn_c_try_run "$LINENO"; then :
20421  ol_cv_pthread_thread=yes
20422else
20423  ol_cv_pthread_thread=no
20424fi
20425rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20426  conftest.$ac_objext conftest.beam conftest.$ac_ext
20427fi
20428
20429
20430		# restore the LIBS
20431		LIBS="$ol_LIBS"
20432
20433fi
20434{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_thread" >&5
20435$as_echo "$ol_cv_pthread_thread" >&6; }
20436
20437	if test $ol_cv_pthread_thread = yes ; then
20438		ol_link_pthreads="-thread"
20439		ol_link_threads=posix
20440	fi
20441fi
20442
20443
20444		# Pthread try link: -lpthread -lmach -lexc -lc_r (ol_cv_pthread_lpthread_lmach_lexc_lc_r)
20445if test "$ol_link_threads" = no ; then
20446	# try -lpthread -lmach -lexc -lc_r
20447	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthread -lmach -lexc -lc_r" >&5
20448$as_echo_n "checking for pthread link with -lpthread -lmach -lexc -lc_r... " >&6; }
20449if ${ol_cv_pthread_lpthread_lmach_lexc_lc_r+:} false; then :
20450  $as_echo_n "(cached) " >&6
20451else
20452
20453		# save the flags
20454		ol_LIBS="$LIBS"
20455		LIBS="-lpthread -lmach -lexc -lc_r $LIBS"
20456
20457		if test "$cross_compiling" = yes; then :
20458  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20459/* end confdefs.h.  */
20460
20461/* pthread test headers */
20462#include <pthread.h>
20463#if HAVE_PTHREADS < 7
20464#include <errno.h>
20465#endif
20466#ifndef NULL
20467#define NULL (void*)0
20468#endif
20469
20470static void *task(p)
20471	void *p;
20472{
20473	return (void *) (p == NULL);
20474}
20475
20476int
20477main ()
20478{
20479
20480	/* pthread test function */
20481#ifndef PTHREAD_CREATE_DETACHED
20482#define	PTHREAD_CREATE_DETACHED	1
20483#endif
20484	pthread_t t;
20485	int status;
20486	int detach = PTHREAD_CREATE_DETACHED;
20487
20488#if HAVE_PTHREADS > 4
20489	/* Final pthreads */
20490	pthread_attr_t attr;
20491
20492	status = pthread_attr_init(&attr);
20493	if( status ) return status;
20494
20495#if HAVE_PTHREADS < 7
20496	status = pthread_attr_setdetachstate(&attr, &detach);
20497	if( status < 0 ) status = errno;
20498#else
20499	status = pthread_attr_setdetachstate(&attr, detach);
20500#endif
20501	if( status ) return status;
20502	status = pthread_create( &t, &attr, task, NULL );
20503#if HAVE_PTHREADS < 7
20504	if( status < 0 ) status = errno;
20505#endif
20506	if( status ) return status;
20507#else
20508	/* Draft 4 pthreads */
20509	status = pthread_create( &t, pthread_attr_default, task, NULL );
20510	if( status ) return errno;
20511
20512	/* give thread a chance to complete */
20513	/* it should remain joinable and hence detachable */
20514	sleep( 1 );
20515
20516	status = pthread_detach( &t );
20517	if( status ) return errno;
20518#endif
20519
20520#ifdef HAVE_LINUX_THREADS
20521	pthread_kill_other_threads_np();
20522#endif
20523
20524	return 0;
20525
20526  ;
20527  return 0;
20528}
20529_ACEOF
20530if ac_fn_c_try_link "$LINENO"; then :
20531  ol_cv_pthread_lpthread_lmach_lexc_lc_r=yes
20532else
20533  ol_cv_pthread_lpthread_lmach_lexc_lc_r=no
20534fi
20535rm -f core conftest.err conftest.$ac_objext \
20536    conftest$ac_exeext conftest.$ac_ext
20537else
20538  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20539/* end confdefs.h.  */
20540
20541
20542/* pthread test headers */
20543#include <pthread.h>
20544#if HAVE_PTHREADS < 7
20545#include <errno.h>
20546#endif
20547#ifndef NULL
20548#define NULL (void*)0
20549#endif
20550
20551static void *task(p)
20552	void *p;
20553{
20554	return (void *) (p == NULL);
20555}
20556
20557
20558int main(argc, argv)
20559	int argc;
20560	char **argv;
20561{
20562
20563	/* pthread test function */
20564#ifndef PTHREAD_CREATE_DETACHED
20565#define	PTHREAD_CREATE_DETACHED	1
20566#endif
20567	pthread_t t;
20568	int status;
20569	int detach = PTHREAD_CREATE_DETACHED;
20570
20571#if HAVE_PTHREADS > 4
20572	/* Final pthreads */
20573	pthread_attr_t attr;
20574
20575	status = pthread_attr_init(&attr);
20576	if( status ) return status;
20577
20578#if HAVE_PTHREADS < 7
20579	status = pthread_attr_setdetachstate(&attr, &detach);
20580	if( status < 0 ) status = errno;
20581#else
20582	status = pthread_attr_setdetachstate(&attr, detach);
20583#endif
20584	if( status ) return status;
20585	status = pthread_create( &t, &attr, task, NULL );
20586#if HAVE_PTHREADS < 7
20587	if( status < 0 ) status = errno;
20588#endif
20589	if( status ) return status;
20590#else
20591	/* Draft 4 pthreads */
20592	status = pthread_create( &t, pthread_attr_default, task, NULL );
20593	if( status ) return errno;
20594
20595	/* give thread a chance to complete */
20596	/* it should remain joinable and hence detachable */
20597	sleep( 1 );
20598
20599	status = pthread_detach( &t );
20600	if( status ) return errno;
20601#endif
20602
20603#ifdef HAVE_LINUX_THREADS
20604	pthread_kill_other_threads_np();
20605#endif
20606
20607	return 0;
20608
20609}
20610
20611_ACEOF
20612if ac_fn_c_try_run "$LINENO"; then :
20613  ol_cv_pthread_lpthread_lmach_lexc_lc_r=yes
20614else
20615  ol_cv_pthread_lpthread_lmach_lexc_lc_r=no
20616fi
20617rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20618  conftest.$ac_objext conftest.beam conftest.$ac_ext
20619fi
20620
20621
20622		# restore the LIBS
20623		LIBS="$ol_LIBS"
20624
20625fi
20626{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lpthread_lmach_lexc_lc_r" >&5
20627$as_echo "$ol_cv_pthread_lpthread_lmach_lexc_lc_r" >&6; }
20628
20629	if test $ol_cv_pthread_lpthread_lmach_lexc_lc_r = yes ; then
20630		ol_link_pthreads="-lpthread -lmach -lexc -lc_r"
20631		ol_link_threads=posix
20632	fi
20633fi
20634
20635		# Pthread try link: -lpthread -lmach -lexc (ol_cv_pthread_lpthread_lmach_lexc)
20636if test "$ol_link_threads" = no ; then
20637	# try -lpthread -lmach -lexc
20638	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthread -lmach -lexc" >&5
20639$as_echo_n "checking for pthread link with -lpthread -lmach -lexc... " >&6; }
20640if ${ol_cv_pthread_lpthread_lmach_lexc+:} false; then :
20641  $as_echo_n "(cached) " >&6
20642else
20643
20644		# save the flags
20645		ol_LIBS="$LIBS"
20646		LIBS="-lpthread -lmach -lexc $LIBS"
20647
20648		if test "$cross_compiling" = yes; then :
20649  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20650/* end confdefs.h.  */
20651
20652/* pthread test headers */
20653#include <pthread.h>
20654#if HAVE_PTHREADS < 7
20655#include <errno.h>
20656#endif
20657#ifndef NULL
20658#define NULL (void*)0
20659#endif
20660
20661static void *task(p)
20662	void *p;
20663{
20664	return (void *) (p == NULL);
20665}
20666
20667int
20668main ()
20669{
20670
20671	/* pthread test function */
20672#ifndef PTHREAD_CREATE_DETACHED
20673#define	PTHREAD_CREATE_DETACHED	1
20674#endif
20675	pthread_t t;
20676	int status;
20677	int detach = PTHREAD_CREATE_DETACHED;
20678
20679#if HAVE_PTHREADS > 4
20680	/* Final pthreads */
20681	pthread_attr_t attr;
20682
20683	status = pthread_attr_init(&attr);
20684	if( status ) return status;
20685
20686#if HAVE_PTHREADS < 7
20687	status = pthread_attr_setdetachstate(&attr, &detach);
20688	if( status < 0 ) status = errno;
20689#else
20690	status = pthread_attr_setdetachstate(&attr, detach);
20691#endif
20692	if( status ) return status;
20693	status = pthread_create( &t, &attr, task, NULL );
20694#if HAVE_PTHREADS < 7
20695	if( status < 0 ) status = errno;
20696#endif
20697	if( status ) return status;
20698#else
20699	/* Draft 4 pthreads */
20700	status = pthread_create( &t, pthread_attr_default, task, NULL );
20701	if( status ) return errno;
20702
20703	/* give thread a chance to complete */
20704	/* it should remain joinable and hence detachable */
20705	sleep( 1 );
20706
20707	status = pthread_detach( &t );
20708	if( status ) return errno;
20709#endif
20710
20711#ifdef HAVE_LINUX_THREADS
20712	pthread_kill_other_threads_np();
20713#endif
20714
20715	return 0;
20716
20717  ;
20718  return 0;
20719}
20720_ACEOF
20721if ac_fn_c_try_link "$LINENO"; then :
20722  ol_cv_pthread_lpthread_lmach_lexc=yes
20723else
20724  ol_cv_pthread_lpthread_lmach_lexc=no
20725fi
20726rm -f core conftest.err conftest.$ac_objext \
20727    conftest$ac_exeext conftest.$ac_ext
20728else
20729  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20730/* end confdefs.h.  */
20731
20732
20733/* pthread test headers */
20734#include <pthread.h>
20735#if HAVE_PTHREADS < 7
20736#include <errno.h>
20737#endif
20738#ifndef NULL
20739#define NULL (void*)0
20740#endif
20741
20742static void *task(p)
20743	void *p;
20744{
20745	return (void *) (p == NULL);
20746}
20747
20748
20749int main(argc, argv)
20750	int argc;
20751	char **argv;
20752{
20753
20754	/* pthread test function */
20755#ifndef PTHREAD_CREATE_DETACHED
20756#define	PTHREAD_CREATE_DETACHED	1
20757#endif
20758	pthread_t t;
20759	int status;
20760	int detach = PTHREAD_CREATE_DETACHED;
20761
20762#if HAVE_PTHREADS > 4
20763	/* Final pthreads */
20764	pthread_attr_t attr;
20765
20766	status = pthread_attr_init(&attr);
20767	if( status ) return status;
20768
20769#if HAVE_PTHREADS < 7
20770	status = pthread_attr_setdetachstate(&attr, &detach);
20771	if( status < 0 ) status = errno;
20772#else
20773	status = pthread_attr_setdetachstate(&attr, detach);
20774#endif
20775	if( status ) return status;
20776	status = pthread_create( &t, &attr, task, NULL );
20777#if HAVE_PTHREADS < 7
20778	if( status < 0 ) status = errno;
20779#endif
20780	if( status ) return status;
20781#else
20782	/* Draft 4 pthreads */
20783	status = pthread_create( &t, pthread_attr_default, task, NULL );
20784	if( status ) return errno;
20785
20786	/* give thread a chance to complete */
20787	/* it should remain joinable and hence detachable */
20788	sleep( 1 );
20789
20790	status = pthread_detach( &t );
20791	if( status ) return errno;
20792#endif
20793
20794#ifdef HAVE_LINUX_THREADS
20795	pthread_kill_other_threads_np();
20796#endif
20797
20798	return 0;
20799
20800}
20801
20802_ACEOF
20803if ac_fn_c_try_run "$LINENO"; then :
20804  ol_cv_pthread_lpthread_lmach_lexc=yes
20805else
20806  ol_cv_pthread_lpthread_lmach_lexc=no
20807fi
20808rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20809  conftest.$ac_objext conftest.beam conftest.$ac_ext
20810fi
20811
20812
20813		# restore the LIBS
20814		LIBS="$ol_LIBS"
20815
20816fi
20817{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lpthread_lmach_lexc" >&5
20818$as_echo "$ol_cv_pthread_lpthread_lmach_lexc" >&6; }
20819
20820	if test $ol_cv_pthread_lpthread_lmach_lexc = yes ; then
20821		ol_link_pthreads="-lpthread -lmach -lexc"
20822		ol_link_threads=posix
20823	fi
20824fi
20825
20826
20827		# Pthread try link: -lpthread -Wl,-woff,85 (ol_cv_pthread_lib_lpthread_woff)
20828if test "$ol_link_threads" = no ; then
20829	# try -lpthread -Wl,-woff,85
20830	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthread -Wl,-woff,85" >&5
20831$as_echo_n "checking for pthread link with -lpthread -Wl,-woff,85... " >&6; }
20832if ${ol_cv_pthread_lib_lpthread_woff+:} false; then :
20833  $as_echo_n "(cached) " >&6
20834else
20835
20836		# save the flags
20837		ol_LIBS="$LIBS"
20838		LIBS="-lpthread -Wl,-woff,85 $LIBS"
20839
20840		if test "$cross_compiling" = yes; then :
20841  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20842/* end confdefs.h.  */
20843
20844/* pthread test headers */
20845#include <pthread.h>
20846#if HAVE_PTHREADS < 7
20847#include <errno.h>
20848#endif
20849#ifndef NULL
20850#define NULL (void*)0
20851#endif
20852
20853static void *task(p)
20854	void *p;
20855{
20856	return (void *) (p == NULL);
20857}
20858
20859int
20860main ()
20861{
20862
20863	/* pthread test function */
20864#ifndef PTHREAD_CREATE_DETACHED
20865#define	PTHREAD_CREATE_DETACHED	1
20866#endif
20867	pthread_t t;
20868	int status;
20869	int detach = PTHREAD_CREATE_DETACHED;
20870
20871#if HAVE_PTHREADS > 4
20872	/* Final pthreads */
20873	pthread_attr_t attr;
20874
20875	status = pthread_attr_init(&attr);
20876	if( status ) return status;
20877
20878#if HAVE_PTHREADS < 7
20879	status = pthread_attr_setdetachstate(&attr, &detach);
20880	if( status < 0 ) status = errno;
20881#else
20882	status = pthread_attr_setdetachstate(&attr, detach);
20883#endif
20884	if( status ) return status;
20885	status = pthread_create( &t, &attr, task, NULL );
20886#if HAVE_PTHREADS < 7
20887	if( status < 0 ) status = errno;
20888#endif
20889	if( status ) return status;
20890#else
20891	/* Draft 4 pthreads */
20892	status = pthread_create( &t, pthread_attr_default, task, NULL );
20893	if( status ) return errno;
20894
20895	/* give thread a chance to complete */
20896	/* it should remain joinable and hence detachable */
20897	sleep( 1 );
20898
20899	status = pthread_detach( &t );
20900	if( status ) return errno;
20901#endif
20902
20903#ifdef HAVE_LINUX_THREADS
20904	pthread_kill_other_threads_np();
20905#endif
20906
20907	return 0;
20908
20909  ;
20910  return 0;
20911}
20912_ACEOF
20913if ac_fn_c_try_link "$LINENO"; then :
20914  ol_cv_pthread_lib_lpthread_woff=yes
20915else
20916  ol_cv_pthread_lib_lpthread_woff=no
20917fi
20918rm -f core conftest.err conftest.$ac_objext \
20919    conftest$ac_exeext conftest.$ac_ext
20920else
20921  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20922/* end confdefs.h.  */
20923
20924
20925/* pthread test headers */
20926#include <pthread.h>
20927#if HAVE_PTHREADS < 7
20928#include <errno.h>
20929#endif
20930#ifndef NULL
20931#define NULL (void*)0
20932#endif
20933
20934static void *task(p)
20935	void *p;
20936{
20937	return (void *) (p == NULL);
20938}
20939
20940
20941int main(argc, argv)
20942	int argc;
20943	char **argv;
20944{
20945
20946	/* pthread test function */
20947#ifndef PTHREAD_CREATE_DETACHED
20948#define	PTHREAD_CREATE_DETACHED	1
20949#endif
20950	pthread_t t;
20951	int status;
20952	int detach = PTHREAD_CREATE_DETACHED;
20953
20954#if HAVE_PTHREADS > 4
20955	/* Final pthreads */
20956	pthread_attr_t attr;
20957
20958	status = pthread_attr_init(&attr);
20959	if( status ) return status;
20960
20961#if HAVE_PTHREADS < 7
20962	status = pthread_attr_setdetachstate(&attr, &detach);
20963	if( status < 0 ) status = errno;
20964#else
20965	status = pthread_attr_setdetachstate(&attr, detach);
20966#endif
20967	if( status ) return status;
20968	status = pthread_create( &t, &attr, task, NULL );
20969#if HAVE_PTHREADS < 7
20970	if( status < 0 ) status = errno;
20971#endif
20972	if( status ) return status;
20973#else
20974	/* Draft 4 pthreads */
20975	status = pthread_create( &t, pthread_attr_default, task, NULL );
20976	if( status ) return errno;
20977
20978	/* give thread a chance to complete */
20979	/* it should remain joinable and hence detachable */
20980	sleep( 1 );
20981
20982	status = pthread_detach( &t );
20983	if( status ) return errno;
20984#endif
20985
20986#ifdef HAVE_LINUX_THREADS
20987	pthread_kill_other_threads_np();
20988#endif
20989
20990	return 0;
20991
20992}
20993
20994_ACEOF
20995if ac_fn_c_try_run "$LINENO"; then :
20996  ol_cv_pthread_lib_lpthread_woff=yes
20997else
20998  ol_cv_pthread_lib_lpthread_woff=no
20999fi
21000rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21001  conftest.$ac_objext conftest.beam conftest.$ac_ext
21002fi
21003
21004
21005		# restore the LIBS
21006		LIBS="$ol_LIBS"
21007
21008fi
21009{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lib_lpthread_woff" >&5
21010$as_echo "$ol_cv_pthread_lib_lpthread_woff" >&6; }
21011
21012	if test $ol_cv_pthread_lib_lpthread_woff = yes ; then
21013		ol_link_pthreads="-lpthread -Wl,-woff,85"
21014		ol_link_threads=posix
21015	fi
21016fi
21017
21018
21019		# Pthread try link: -lpthread (ol_cv_pthread_lpthread)
21020if test "$ol_link_threads" = no ; then
21021	# try -lpthread
21022	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthread" >&5
21023$as_echo_n "checking for pthread link with -lpthread... " >&6; }
21024if ${ol_cv_pthread_lpthread+:} false; then :
21025  $as_echo_n "(cached) " >&6
21026else
21027
21028		# save the flags
21029		ol_LIBS="$LIBS"
21030		LIBS="-lpthread $LIBS"
21031
21032		if test "$cross_compiling" = yes; then :
21033  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21034/* end confdefs.h.  */
21035
21036/* pthread test headers */
21037#include <pthread.h>
21038#if HAVE_PTHREADS < 7
21039#include <errno.h>
21040#endif
21041#ifndef NULL
21042#define NULL (void*)0
21043#endif
21044
21045static void *task(p)
21046	void *p;
21047{
21048	return (void *) (p == NULL);
21049}
21050
21051int
21052main ()
21053{
21054
21055	/* pthread test function */
21056#ifndef PTHREAD_CREATE_DETACHED
21057#define	PTHREAD_CREATE_DETACHED	1
21058#endif
21059	pthread_t t;
21060	int status;
21061	int detach = PTHREAD_CREATE_DETACHED;
21062
21063#if HAVE_PTHREADS > 4
21064	/* Final pthreads */
21065	pthread_attr_t attr;
21066
21067	status = pthread_attr_init(&attr);
21068	if( status ) return status;
21069
21070#if HAVE_PTHREADS < 7
21071	status = pthread_attr_setdetachstate(&attr, &detach);
21072	if( status < 0 ) status = errno;
21073#else
21074	status = pthread_attr_setdetachstate(&attr, detach);
21075#endif
21076	if( status ) return status;
21077	status = pthread_create( &t, &attr, task, NULL );
21078#if HAVE_PTHREADS < 7
21079	if( status < 0 ) status = errno;
21080#endif
21081	if( status ) return status;
21082#else
21083	/* Draft 4 pthreads */
21084	status = pthread_create( &t, pthread_attr_default, task, NULL );
21085	if( status ) return errno;
21086
21087	/* give thread a chance to complete */
21088	/* it should remain joinable and hence detachable */
21089	sleep( 1 );
21090
21091	status = pthread_detach( &t );
21092	if( status ) return errno;
21093#endif
21094
21095#ifdef HAVE_LINUX_THREADS
21096	pthread_kill_other_threads_np();
21097#endif
21098
21099	return 0;
21100
21101  ;
21102  return 0;
21103}
21104_ACEOF
21105if ac_fn_c_try_link "$LINENO"; then :
21106  ol_cv_pthread_lpthread=yes
21107else
21108  ol_cv_pthread_lpthread=no
21109fi
21110rm -f core conftest.err conftest.$ac_objext \
21111    conftest$ac_exeext conftest.$ac_ext
21112else
21113  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21114/* end confdefs.h.  */
21115
21116
21117/* pthread test headers */
21118#include <pthread.h>
21119#if HAVE_PTHREADS < 7
21120#include <errno.h>
21121#endif
21122#ifndef NULL
21123#define NULL (void*)0
21124#endif
21125
21126static void *task(p)
21127	void *p;
21128{
21129	return (void *) (p == NULL);
21130}
21131
21132
21133int main(argc, argv)
21134	int argc;
21135	char **argv;
21136{
21137
21138	/* pthread test function */
21139#ifndef PTHREAD_CREATE_DETACHED
21140#define	PTHREAD_CREATE_DETACHED	1
21141#endif
21142	pthread_t t;
21143	int status;
21144	int detach = PTHREAD_CREATE_DETACHED;
21145
21146#if HAVE_PTHREADS > 4
21147	/* Final pthreads */
21148	pthread_attr_t attr;
21149
21150	status = pthread_attr_init(&attr);
21151	if( status ) return status;
21152
21153#if HAVE_PTHREADS < 7
21154	status = pthread_attr_setdetachstate(&attr, &detach);
21155	if( status < 0 ) status = errno;
21156#else
21157	status = pthread_attr_setdetachstate(&attr, detach);
21158#endif
21159	if( status ) return status;
21160	status = pthread_create( &t, &attr, task, NULL );
21161#if HAVE_PTHREADS < 7
21162	if( status < 0 ) status = errno;
21163#endif
21164	if( status ) return status;
21165#else
21166	/* Draft 4 pthreads */
21167	status = pthread_create( &t, pthread_attr_default, task, NULL );
21168	if( status ) return errno;
21169
21170	/* give thread a chance to complete */
21171	/* it should remain joinable and hence detachable */
21172	sleep( 1 );
21173
21174	status = pthread_detach( &t );
21175	if( status ) return errno;
21176#endif
21177
21178#ifdef HAVE_LINUX_THREADS
21179	pthread_kill_other_threads_np();
21180#endif
21181
21182	return 0;
21183
21184}
21185
21186_ACEOF
21187if ac_fn_c_try_run "$LINENO"; then :
21188  ol_cv_pthread_lpthread=yes
21189else
21190  ol_cv_pthread_lpthread=no
21191fi
21192rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21193  conftest.$ac_objext conftest.beam conftest.$ac_ext
21194fi
21195
21196
21197		# restore the LIBS
21198		LIBS="$ol_LIBS"
21199
21200fi
21201{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lpthread" >&5
21202$as_echo "$ol_cv_pthread_lpthread" >&6; }
21203
21204	if test $ol_cv_pthread_lpthread = yes ; then
21205		ol_link_pthreads="-lpthread"
21206		ol_link_threads=posix
21207	fi
21208fi
21209
21210		# Pthread try link: -lc_r (ol_cv_pthread_lc_r)
21211if test "$ol_link_threads" = no ; then
21212	# try -lc_r
21213	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lc_r" >&5
21214$as_echo_n "checking for pthread link with -lc_r... " >&6; }
21215if ${ol_cv_pthread_lc_r+:} false; then :
21216  $as_echo_n "(cached) " >&6
21217else
21218
21219		# save the flags
21220		ol_LIBS="$LIBS"
21221		LIBS="-lc_r $LIBS"
21222
21223		if test "$cross_compiling" = yes; then :
21224  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21225/* end confdefs.h.  */
21226
21227/* pthread test headers */
21228#include <pthread.h>
21229#if HAVE_PTHREADS < 7
21230#include <errno.h>
21231#endif
21232#ifndef NULL
21233#define NULL (void*)0
21234#endif
21235
21236static void *task(p)
21237	void *p;
21238{
21239	return (void *) (p == NULL);
21240}
21241
21242int
21243main ()
21244{
21245
21246	/* pthread test function */
21247#ifndef PTHREAD_CREATE_DETACHED
21248#define	PTHREAD_CREATE_DETACHED	1
21249#endif
21250	pthread_t t;
21251	int status;
21252	int detach = PTHREAD_CREATE_DETACHED;
21253
21254#if HAVE_PTHREADS > 4
21255	/* Final pthreads */
21256	pthread_attr_t attr;
21257
21258	status = pthread_attr_init(&attr);
21259	if( status ) return status;
21260
21261#if HAVE_PTHREADS < 7
21262	status = pthread_attr_setdetachstate(&attr, &detach);
21263	if( status < 0 ) status = errno;
21264#else
21265	status = pthread_attr_setdetachstate(&attr, detach);
21266#endif
21267	if( status ) return status;
21268	status = pthread_create( &t, &attr, task, NULL );
21269#if HAVE_PTHREADS < 7
21270	if( status < 0 ) status = errno;
21271#endif
21272	if( status ) return status;
21273#else
21274	/* Draft 4 pthreads */
21275	status = pthread_create( &t, pthread_attr_default, task, NULL );
21276	if( status ) return errno;
21277
21278	/* give thread a chance to complete */
21279	/* it should remain joinable and hence detachable */
21280	sleep( 1 );
21281
21282	status = pthread_detach( &t );
21283	if( status ) return errno;
21284#endif
21285
21286#ifdef HAVE_LINUX_THREADS
21287	pthread_kill_other_threads_np();
21288#endif
21289
21290	return 0;
21291
21292  ;
21293  return 0;
21294}
21295_ACEOF
21296if ac_fn_c_try_link "$LINENO"; then :
21297  ol_cv_pthread_lc_r=yes
21298else
21299  ol_cv_pthread_lc_r=no
21300fi
21301rm -f core conftest.err conftest.$ac_objext \
21302    conftest$ac_exeext conftest.$ac_ext
21303else
21304  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21305/* end confdefs.h.  */
21306
21307
21308/* pthread test headers */
21309#include <pthread.h>
21310#if HAVE_PTHREADS < 7
21311#include <errno.h>
21312#endif
21313#ifndef NULL
21314#define NULL (void*)0
21315#endif
21316
21317static void *task(p)
21318	void *p;
21319{
21320	return (void *) (p == NULL);
21321}
21322
21323
21324int main(argc, argv)
21325	int argc;
21326	char **argv;
21327{
21328
21329	/* pthread test function */
21330#ifndef PTHREAD_CREATE_DETACHED
21331#define	PTHREAD_CREATE_DETACHED	1
21332#endif
21333	pthread_t t;
21334	int status;
21335	int detach = PTHREAD_CREATE_DETACHED;
21336
21337#if HAVE_PTHREADS > 4
21338	/* Final pthreads */
21339	pthread_attr_t attr;
21340
21341	status = pthread_attr_init(&attr);
21342	if( status ) return status;
21343
21344#if HAVE_PTHREADS < 7
21345	status = pthread_attr_setdetachstate(&attr, &detach);
21346	if( status < 0 ) status = errno;
21347#else
21348	status = pthread_attr_setdetachstate(&attr, detach);
21349#endif
21350	if( status ) return status;
21351	status = pthread_create( &t, &attr, task, NULL );
21352#if HAVE_PTHREADS < 7
21353	if( status < 0 ) status = errno;
21354#endif
21355	if( status ) return status;
21356#else
21357	/* Draft 4 pthreads */
21358	status = pthread_create( &t, pthread_attr_default, task, NULL );
21359	if( status ) return errno;
21360
21361	/* give thread a chance to complete */
21362	/* it should remain joinable and hence detachable */
21363	sleep( 1 );
21364
21365	status = pthread_detach( &t );
21366	if( status ) return errno;
21367#endif
21368
21369#ifdef HAVE_LINUX_THREADS
21370	pthread_kill_other_threads_np();
21371#endif
21372
21373	return 0;
21374
21375}
21376
21377_ACEOF
21378if ac_fn_c_try_run "$LINENO"; then :
21379  ol_cv_pthread_lc_r=yes
21380else
21381  ol_cv_pthread_lc_r=no
21382fi
21383rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21384  conftest.$ac_objext conftest.beam conftest.$ac_ext
21385fi
21386
21387
21388		# restore the LIBS
21389		LIBS="$ol_LIBS"
21390
21391fi
21392{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lc_r" >&5
21393$as_echo "$ol_cv_pthread_lc_r" >&6; }
21394
21395	if test $ol_cv_pthread_lc_r = yes ; then
21396		ol_link_pthreads="-lc_r"
21397		ol_link_threads=posix
21398	fi
21399fi
21400
21401
21402		# Pthread try link: -threads (ol_cv_pthread_threads)
21403if test "$ol_link_threads" = no ; then
21404	# try -threads
21405	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -threads" >&5
21406$as_echo_n "checking for pthread link with -threads... " >&6; }
21407if ${ol_cv_pthread_threads+:} false; then :
21408  $as_echo_n "(cached) " >&6
21409else
21410
21411		# save the flags
21412		ol_LIBS="$LIBS"
21413		LIBS="-threads $LIBS"
21414
21415		if test "$cross_compiling" = yes; then :
21416  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21417/* end confdefs.h.  */
21418
21419/* pthread test headers */
21420#include <pthread.h>
21421#if HAVE_PTHREADS < 7
21422#include <errno.h>
21423#endif
21424#ifndef NULL
21425#define NULL (void*)0
21426#endif
21427
21428static void *task(p)
21429	void *p;
21430{
21431	return (void *) (p == NULL);
21432}
21433
21434int
21435main ()
21436{
21437
21438	/* pthread test function */
21439#ifndef PTHREAD_CREATE_DETACHED
21440#define	PTHREAD_CREATE_DETACHED	1
21441#endif
21442	pthread_t t;
21443	int status;
21444	int detach = PTHREAD_CREATE_DETACHED;
21445
21446#if HAVE_PTHREADS > 4
21447	/* Final pthreads */
21448	pthread_attr_t attr;
21449
21450	status = pthread_attr_init(&attr);
21451	if( status ) return status;
21452
21453#if HAVE_PTHREADS < 7
21454	status = pthread_attr_setdetachstate(&attr, &detach);
21455	if( status < 0 ) status = errno;
21456#else
21457	status = pthread_attr_setdetachstate(&attr, detach);
21458#endif
21459	if( status ) return status;
21460	status = pthread_create( &t, &attr, task, NULL );
21461#if HAVE_PTHREADS < 7
21462	if( status < 0 ) status = errno;
21463#endif
21464	if( status ) return status;
21465#else
21466	/* Draft 4 pthreads */
21467	status = pthread_create( &t, pthread_attr_default, task, NULL );
21468	if( status ) return errno;
21469
21470	/* give thread a chance to complete */
21471	/* it should remain joinable and hence detachable */
21472	sleep( 1 );
21473
21474	status = pthread_detach( &t );
21475	if( status ) return errno;
21476#endif
21477
21478#ifdef HAVE_LINUX_THREADS
21479	pthread_kill_other_threads_np();
21480#endif
21481
21482	return 0;
21483
21484  ;
21485  return 0;
21486}
21487_ACEOF
21488if ac_fn_c_try_link "$LINENO"; then :
21489  ol_cv_pthread_threads=yes
21490else
21491  ol_cv_pthread_threads=no
21492fi
21493rm -f core conftest.err conftest.$ac_objext \
21494    conftest$ac_exeext conftest.$ac_ext
21495else
21496  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21497/* end confdefs.h.  */
21498
21499
21500/* pthread test headers */
21501#include <pthread.h>
21502#if HAVE_PTHREADS < 7
21503#include <errno.h>
21504#endif
21505#ifndef NULL
21506#define NULL (void*)0
21507#endif
21508
21509static void *task(p)
21510	void *p;
21511{
21512	return (void *) (p == NULL);
21513}
21514
21515
21516int main(argc, argv)
21517	int argc;
21518	char **argv;
21519{
21520
21521	/* pthread test function */
21522#ifndef PTHREAD_CREATE_DETACHED
21523#define	PTHREAD_CREATE_DETACHED	1
21524#endif
21525	pthread_t t;
21526	int status;
21527	int detach = PTHREAD_CREATE_DETACHED;
21528
21529#if HAVE_PTHREADS > 4
21530	/* Final pthreads */
21531	pthread_attr_t attr;
21532
21533	status = pthread_attr_init(&attr);
21534	if( status ) return status;
21535
21536#if HAVE_PTHREADS < 7
21537	status = pthread_attr_setdetachstate(&attr, &detach);
21538	if( status < 0 ) status = errno;
21539#else
21540	status = pthread_attr_setdetachstate(&attr, detach);
21541#endif
21542	if( status ) return status;
21543	status = pthread_create( &t, &attr, task, NULL );
21544#if HAVE_PTHREADS < 7
21545	if( status < 0 ) status = errno;
21546#endif
21547	if( status ) return status;
21548#else
21549	/* Draft 4 pthreads */
21550	status = pthread_create( &t, pthread_attr_default, task, NULL );
21551	if( status ) return errno;
21552
21553	/* give thread a chance to complete */
21554	/* it should remain joinable and hence detachable */
21555	sleep( 1 );
21556
21557	status = pthread_detach( &t );
21558	if( status ) return errno;
21559#endif
21560
21561#ifdef HAVE_LINUX_THREADS
21562	pthread_kill_other_threads_np();
21563#endif
21564
21565	return 0;
21566
21567}
21568
21569_ACEOF
21570if ac_fn_c_try_run "$LINENO"; then :
21571  ol_cv_pthread_threads=yes
21572else
21573  ol_cv_pthread_threads=no
21574fi
21575rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21576  conftest.$ac_objext conftest.beam conftest.$ac_ext
21577fi
21578
21579
21580		# restore the LIBS
21581		LIBS="$ol_LIBS"
21582
21583fi
21584{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_threads" >&5
21585$as_echo "$ol_cv_pthread_threads" >&6; }
21586
21587	if test $ol_cv_pthread_threads = yes ; then
21588		ol_link_pthreads="-threads"
21589		ol_link_threads=posix
21590	fi
21591fi
21592
21593
21594		# Pthread try link: -lpthreads -lmach -lexc -lc_r (ol_cv_pthread_lpthreads_lmach_lexc_lc_r)
21595if test "$ol_link_threads" = no ; then
21596	# try -lpthreads -lmach -lexc -lc_r
21597	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthreads -lmach -lexc -lc_r" >&5
21598$as_echo_n "checking for pthread link with -lpthreads -lmach -lexc -lc_r... " >&6; }
21599if ${ol_cv_pthread_lpthreads_lmach_lexc_lc_r+:} false; then :
21600  $as_echo_n "(cached) " >&6
21601else
21602
21603		# save the flags
21604		ol_LIBS="$LIBS"
21605		LIBS="-lpthreads -lmach -lexc -lc_r $LIBS"
21606
21607		if test "$cross_compiling" = yes; then :
21608  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21609/* end confdefs.h.  */
21610
21611/* pthread test headers */
21612#include <pthread.h>
21613#if HAVE_PTHREADS < 7
21614#include <errno.h>
21615#endif
21616#ifndef NULL
21617#define NULL (void*)0
21618#endif
21619
21620static void *task(p)
21621	void *p;
21622{
21623	return (void *) (p == NULL);
21624}
21625
21626int
21627main ()
21628{
21629
21630	/* pthread test function */
21631#ifndef PTHREAD_CREATE_DETACHED
21632#define	PTHREAD_CREATE_DETACHED	1
21633#endif
21634	pthread_t t;
21635	int status;
21636	int detach = PTHREAD_CREATE_DETACHED;
21637
21638#if HAVE_PTHREADS > 4
21639	/* Final pthreads */
21640	pthread_attr_t attr;
21641
21642	status = pthread_attr_init(&attr);
21643	if( status ) return status;
21644
21645#if HAVE_PTHREADS < 7
21646	status = pthread_attr_setdetachstate(&attr, &detach);
21647	if( status < 0 ) status = errno;
21648#else
21649	status = pthread_attr_setdetachstate(&attr, detach);
21650#endif
21651	if( status ) return status;
21652	status = pthread_create( &t, &attr, task, NULL );
21653#if HAVE_PTHREADS < 7
21654	if( status < 0 ) status = errno;
21655#endif
21656	if( status ) return status;
21657#else
21658	/* Draft 4 pthreads */
21659	status = pthread_create( &t, pthread_attr_default, task, NULL );
21660	if( status ) return errno;
21661
21662	/* give thread a chance to complete */
21663	/* it should remain joinable and hence detachable */
21664	sleep( 1 );
21665
21666	status = pthread_detach( &t );
21667	if( status ) return errno;
21668#endif
21669
21670#ifdef HAVE_LINUX_THREADS
21671	pthread_kill_other_threads_np();
21672#endif
21673
21674	return 0;
21675
21676  ;
21677  return 0;
21678}
21679_ACEOF
21680if ac_fn_c_try_link "$LINENO"; then :
21681  ol_cv_pthread_lpthreads_lmach_lexc_lc_r=yes
21682else
21683  ol_cv_pthread_lpthreads_lmach_lexc_lc_r=no
21684fi
21685rm -f core conftest.err conftest.$ac_objext \
21686    conftest$ac_exeext conftest.$ac_ext
21687else
21688  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21689/* end confdefs.h.  */
21690
21691
21692/* pthread test headers */
21693#include <pthread.h>
21694#if HAVE_PTHREADS < 7
21695#include <errno.h>
21696#endif
21697#ifndef NULL
21698#define NULL (void*)0
21699#endif
21700
21701static void *task(p)
21702	void *p;
21703{
21704	return (void *) (p == NULL);
21705}
21706
21707
21708int main(argc, argv)
21709	int argc;
21710	char **argv;
21711{
21712
21713	/* pthread test function */
21714#ifndef PTHREAD_CREATE_DETACHED
21715#define	PTHREAD_CREATE_DETACHED	1
21716#endif
21717	pthread_t t;
21718	int status;
21719	int detach = PTHREAD_CREATE_DETACHED;
21720
21721#if HAVE_PTHREADS > 4
21722	/* Final pthreads */
21723	pthread_attr_t attr;
21724
21725	status = pthread_attr_init(&attr);
21726	if( status ) return status;
21727
21728#if HAVE_PTHREADS < 7
21729	status = pthread_attr_setdetachstate(&attr, &detach);
21730	if( status < 0 ) status = errno;
21731#else
21732	status = pthread_attr_setdetachstate(&attr, detach);
21733#endif
21734	if( status ) return status;
21735	status = pthread_create( &t, &attr, task, NULL );
21736#if HAVE_PTHREADS < 7
21737	if( status < 0 ) status = errno;
21738#endif
21739	if( status ) return status;
21740#else
21741	/* Draft 4 pthreads */
21742	status = pthread_create( &t, pthread_attr_default, task, NULL );
21743	if( status ) return errno;
21744
21745	/* give thread a chance to complete */
21746	/* it should remain joinable and hence detachable */
21747	sleep( 1 );
21748
21749	status = pthread_detach( &t );
21750	if( status ) return errno;
21751#endif
21752
21753#ifdef HAVE_LINUX_THREADS
21754	pthread_kill_other_threads_np();
21755#endif
21756
21757	return 0;
21758
21759}
21760
21761_ACEOF
21762if ac_fn_c_try_run "$LINENO"; then :
21763  ol_cv_pthread_lpthreads_lmach_lexc_lc_r=yes
21764else
21765  ol_cv_pthread_lpthreads_lmach_lexc_lc_r=no
21766fi
21767rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21768  conftest.$ac_objext conftest.beam conftest.$ac_ext
21769fi
21770
21771
21772		# restore the LIBS
21773		LIBS="$ol_LIBS"
21774
21775fi
21776{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lpthreads_lmach_lexc_lc_r" >&5
21777$as_echo "$ol_cv_pthread_lpthreads_lmach_lexc_lc_r" >&6; }
21778
21779	if test $ol_cv_pthread_lpthreads_lmach_lexc_lc_r = yes ; then
21780		ol_link_pthreads="-lpthreads -lmach -lexc -lc_r"
21781		ol_link_threads=posix
21782	fi
21783fi
21784
21785		# Pthread try link: -lpthreads -lmach -lexc (ol_cv_pthread_lpthreads_lmach_lexc)
21786if test "$ol_link_threads" = no ; then
21787	# try -lpthreads -lmach -lexc
21788	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthreads -lmach -lexc" >&5
21789$as_echo_n "checking for pthread link with -lpthreads -lmach -lexc... " >&6; }
21790if ${ol_cv_pthread_lpthreads_lmach_lexc+:} false; then :
21791  $as_echo_n "(cached) " >&6
21792else
21793
21794		# save the flags
21795		ol_LIBS="$LIBS"
21796		LIBS="-lpthreads -lmach -lexc $LIBS"
21797
21798		if test "$cross_compiling" = yes; then :
21799  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21800/* end confdefs.h.  */
21801
21802/* pthread test headers */
21803#include <pthread.h>
21804#if HAVE_PTHREADS < 7
21805#include <errno.h>
21806#endif
21807#ifndef NULL
21808#define NULL (void*)0
21809#endif
21810
21811static void *task(p)
21812	void *p;
21813{
21814	return (void *) (p == NULL);
21815}
21816
21817int
21818main ()
21819{
21820
21821	/* pthread test function */
21822#ifndef PTHREAD_CREATE_DETACHED
21823#define	PTHREAD_CREATE_DETACHED	1
21824#endif
21825	pthread_t t;
21826	int status;
21827	int detach = PTHREAD_CREATE_DETACHED;
21828
21829#if HAVE_PTHREADS > 4
21830	/* Final pthreads */
21831	pthread_attr_t attr;
21832
21833	status = pthread_attr_init(&attr);
21834	if( status ) return status;
21835
21836#if HAVE_PTHREADS < 7
21837	status = pthread_attr_setdetachstate(&attr, &detach);
21838	if( status < 0 ) status = errno;
21839#else
21840	status = pthread_attr_setdetachstate(&attr, detach);
21841#endif
21842	if( status ) return status;
21843	status = pthread_create( &t, &attr, task, NULL );
21844#if HAVE_PTHREADS < 7
21845	if( status < 0 ) status = errno;
21846#endif
21847	if( status ) return status;
21848#else
21849	/* Draft 4 pthreads */
21850	status = pthread_create( &t, pthread_attr_default, task, NULL );
21851	if( status ) return errno;
21852
21853	/* give thread a chance to complete */
21854	/* it should remain joinable and hence detachable */
21855	sleep( 1 );
21856
21857	status = pthread_detach( &t );
21858	if( status ) return errno;
21859#endif
21860
21861#ifdef HAVE_LINUX_THREADS
21862	pthread_kill_other_threads_np();
21863#endif
21864
21865	return 0;
21866
21867  ;
21868  return 0;
21869}
21870_ACEOF
21871if ac_fn_c_try_link "$LINENO"; then :
21872  ol_cv_pthread_lpthreads_lmach_lexc=yes
21873else
21874  ol_cv_pthread_lpthreads_lmach_lexc=no
21875fi
21876rm -f core conftest.err conftest.$ac_objext \
21877    conftest$ac_exeext conftest.$ac_ext
21878else
21879  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21880/* end confdefs.h.  */
21881
21882
21883/* pthread test headers */
21884#include <pthread.h>
21885#if HAVE_PTHREADS < 7
21886#include <errno.h>
21887#endif
21888#ifndef NULL
21889#define NULL (void*)0
21890#endif
21891
21892static void *task(p)
21893	void *p;
21894{
21895	return (void *) (p == NULL);
21896}
21897
21898
21899int main(argc, argv)
21900	int argc;
21901	char **argv;
21902{
21903
21904	/* pthread test function */
21905#ifndef PTHREAD_CREATE_DETACHED
21906#define	PTHREAD_CREATE_DETACHED	1
21907#endif
21908	pthread_t t;
21909	int status;
21910	int detach = PTHREAD_CREATE_DETACHED;
21911
21912#if HAVE_PTHREADS > 4
21913	/* Final pthreads */
21914	pthread_attr_t attr;
21915
21916	status = pthread_attr_init(&attr);
21917	if( status ) return status;
21918
21919#if HAVE_PTHREADS < 7
21920	status = pthread_attr_setdetachstate(&attr, &detach);
21921	if( status < 0 ) status = errno;
21922#else
21923	status = pthread_attr_setdetachstate(&attr, detach);
21924#endif
21925	if( status ) return status;
21926	status = pthread_create( &t, &attr, task, NULL );
21927#if HAVE_PTHREADS < 7
21928	if( status < 0 ) status = errno;
21929#endif
21930	if( status ) return status;
21931#else
21932	/* Draft 4 pthreads */
21933	status = pthread_create( &t, pthread_attr_default, task, NULL );
21934	if( status ) return errno;
21935
21936	/* give thread a chance to complete */
21937	/* it should remain joinable and hence detachable */
21938	sleep( 1 );
21939
21940	status = pthread_detach( &t );
21941	if( status ) return errno;
21942#endif
21943
21944#ifdef HAVE_LINUX_THREADS
21945	pthread_kill_other_threads_np();
21946#endif
21947
21948	return 0;
21949
21950}
21951
21952_ACEOF
21953if ac_fn_c_try_run "$LINENO"; then :
21954  ol_cv_pthread_lpthreads_lmach_lexc=yes
21955else
21956  ol_cv_pthread_lpthreads_lmach_lexc=no
21957fi
21958rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21959  conftest.$ac_objext conftest.beam conftest.$ac_ext
21960fi
21961
21962
21963		# restore the LIBS
21964		LIBS="$ol_LIBS"
21965
21966fi
21967{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lpthreads_lmach_lexc" >&5
21968$as_echo "$ol_cv_pthread_lpthreads_lmach_lexc" >&6; }
21969
21970	if test $ol_cv_pthread_lpthreads_lmach_lexc = yes ; then
21971		ol_link_pthreads="-lpthreads -lmach -lexc"
21972		ol_link_threads=posix
21973	fi
21974fi
21975
21976		# Pthread try link: -lpthreads -lexc (ol_cv_pthread_lpthreads_lexc)
21977if test "$ol_link_threads" = no ; then
21978	# try -lpthreads -lexc
21979	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthreads -lexc" >&5
21980$as_echo_n "checking for pthread link with -lpthreads -lexc... " >&6; }
21981if ${ol_cv_pthread_lpthreads_lexc+:} false; then :
21982  $as_echo_n "(cached) " >&6
21983else
21984
21985		# save the flags
21986		ol_LIBS="$LIBS"
21987		LIBS="-lpthreads -lexc $LIBS"
21988
21989		if test "$cross_compiling" = yes; then :
21990  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21991/* end confdefs.h.  */
21992
21993/* pthread test headers */
21994#include <pthread.h>
21995#if HAVE_PTHREADS < 7
21996#include <errno.h>
21997#endif
21998#ifndef NULL
21999#define NULL (void*)0
22000#endif
22001
22002static void *task(p)
22003	void *p;
22004{
22005	return (void *) (p == NULL);
22006}
22007
22008int
22009main ()
22010{
22011
22012	/* pthread test function */
22013#ifndef PTHREAD_CREATE_DETACHED
22014#define	PTHREAD_CREATE_DETACHED	1
22015#endif
22016	pthread_t t;
22017	int status;
22018	int detach = PTHREAD_CREATE_DETACHED;
22019
22020#if HAVE_PTHREADS > 4
22021	/* Final pthreads */
22022	pthread_attr_t attr;
22023
22024	status = pthread_attr_init(&attr);
22025	if( status ) return status;
22026
22027#if HAVE_PTHREADS < 7
22028	status = pthread_attr_setdetachstate(&attr, &detach);
22029	if( status < 0 ) status = errno;
22030#else
22031	status = pthread_attr_setdetachstate(&attr, detach);
22032#endif
22033	if( status ) return status;
22034	status = pthread_create( &t, &attr, task, NULL );
22035#if HAVE_PTHREADS < 7
22036	if( status < 0 ) status = errno;
22037#endif
22038	if( status ) return status;
22039#else
22040	/* Draft 4 pthreads */
22041	status = pthread_create( &t, pthread_attr_default, task, NULL );
22042	if( status ) return errno;
22043
22044	/* give thread a chance to complete */
22045	/* it should remain joinable and hence detachable */
22046	sleep( 1 );
22047
22048	status = pthread_detach( &t );
22049	if( status ) return errno;
22050#endif
22051
22052#ifdef HAVE_LINUX_THREADS
22053	pthread_kill_other_threads_np();
22054#endif
22055
22056	return 0;
22057
22058  ;
22059  return 0;
22060}
22061_ACEOF
22062if ac_fn_c_try_link "$LINENO"; then :
22063  ol_cv_pthread_lpthreads_lexc=yes
22064else
22065  ol_cv_pthread_lpthreads_lexc=no
22066fi
22067rm -f core conftest.err conftest.$ac_objext \
22068    conftest$ac_exeext conftest.$ac_ext
22069else
22070  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22071/* end confdefs.h.  */
22072
22073
22074/* pthread test headers */
22075#include <pthread.h>
22076#if HAVE_PTHREADS < 7
22077#include <errno.h>
22078#endif
22079#ifndef NULL
22080#define NULL (void*)0
22081#endif
22082
22083static void *task(p)
22084	void *p;
22085{
22086	return (void *) (p == NULL);
22087}
22088
22089
22090int main(argc, argv)
22091	int argc;
22092	char **argv;
22093{
22094
22095	/* pthread test function */
22096#ifndef PTHREAD_CREATE_DETACHED
22097#define	PTHREAD_CREATE_DETACHED	1
22098#endif
22099	pthread_t t;
22100	int status;
22101	int detach = PTHREAD_CREATE_DETACHED;
22102
22103#if HAVE_PTHREADS > 4
22104	/* Final pthreads */
22105	pthread_attr_t attr;
22106
22107	status = pthread_attr_init(&attr);
22108	if( status ) return status;
22109
22110#if HAVE_PTHREADS < 7
22111	status = pthread_attr_setdetachstate(&attr, &detach);
22112	if( status < 0 ) status = errno;
22113#else
22114	status = pthread_attr_setdetachstate(&attr, detach);
22115#endif
22116	if( status ) return status;
22117	status = pthread_create( &t, &attr, task, NULL );
22118#if HAVE_PTHREADS < 7
22119	if( status < 0 ) status = errno;
22120#endif
22121	if( status ) return status;
22122#else
22123	/* Draft 4 pthreads */
22124	status = pthread_create( &t, pthread_attr_default, task, NULL );
22125	if( status ) return errno;
22126
22127	/* give thread a chance to complete */
22128	/* it should remain joinable and hence detachable */
22129	sleep( 1 );
22130
22131	status = pthread_detach( &t );
22132	if( status ) return errno;
22133#endif
22134
22135#ifdef HAVE_LINUX_THREADS
22136	pthread_kill_other_threads_np();
22137#endif
22138
22139	return 0;
22140
22141}
22142
22143_ACEOF
22144if ac_fn_c_try_run "$LINENO"; then :
22145  ol_cv_pthread_lpthreads_lexc=yes
22146else
22147  ol_cv_pthread_lpthreads_lexc=no
22148fi
22149rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22150  conftest.$ac_objext conftest.beam conftest.$ac_ext
22151fi
22152
22153
22154		# restore the LIBS
22155		LIBS="$ol_LIBS"
22156
22157fi
22158{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lpthreads_lexc" >&5
22159$as_echo "$ol_cv_pthread_lpthreads_lexc" >&6; }
22160
22161	if test $ol_cv_pthread_lpthreads_lexc = yes ; then
22162		ol_link_pthreads="-lpthreads -lexc"
22163		ol_link_threads=posix
22164	fi
22165fi
22166
22167
22168		# Pthread try link: -lpthreads (ol_cv_pthread_lib_lpthreads)
22169if test "$ol_link_threads" = no ; then
22170	# try -lpthreads
22171	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthreads" >&5
22172$as_echo_n "checking for pthread link with -lpthreads... " >&6; }
22173if ${ol_cv_pthread_lib_lpthreads+:} false; then :
22174  $as_echo_n "(cached) " >&6
22175else
22176
22177		# save the flags
22178		ol_LIBS="$LIBS"
22179		LIBS="-lpthreads $LIBS"
22180
22181		if test "$cross_compiling" = yes; then :
22182  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22183/* end confdefs.h.  */
22184
22185/* pthread test headers */
22186#include <pthread.h>
22187#if HAVE_PTHREADS < 7
22188#include <errno.h>
22189#endif
22190#ifndef NULL
22191#define NULL (void*)0
22192#endif
22193
22194static void *task(p)
22195	void *p;
22196{
22197	return (void *) (p == NULL);
22198}
22199
22200int
22201main ()
22202{
22203
22204	/* pthread test function */
22205#ifndef PTHREAD_CREATE_DETACHED
22206#define	PTHREAD_CREATE_DETACHED	1
22207#endif
22208	pthread_t t;
22209	int status;
22210	int detach = PTHREAD_CREATE_DETACHED;
22211
22212#if HAVE_PTHREADS > 4
22213	/* Final pthreads */
22214	pthread_attr_t attr;
22215
22216	status = pthread_attr_init(&attr);
22217	if( status ) return status;
22218
22219#if HAVE_PTHREADS < 7
22220	status = pthread_attr_setdetachstate(&attr, &detach);
22221	if( status < 0 ) status = errno;
22222#else
22223	status = pthread_attr_setdetachstate(&attr, detach);
22224#endif
22225	if( status ) return status;
22226	status = pthread_create( &t, &attr, task, NULL );
22227#if HAVE_PTHREADS < 7
22228	if( status < 0 ) status = errno;
22229#endif
22230	if( status ) return status;
22231#else
22232	/* Draft 4 pthreads */
22233	status = pthread_create( &t, pthread_attr_default, task, NULL );
22234	if( status ) return errno;
22235
22236	/* give thread a chance to complete */
22237	/* it should remain joinable and hence detachable */
22238	sleep( 1 );
22239
22240	status = pthread_detach( &t );
22241	if( status ) return errno;
22242#endif
22243
22244#ifdef HAVE_LINUX_THREADS
22245	pthread_kill_other_threads_np();
22246#endif
22247
22248	return 0;
22249
22250  ;
22251  return 0;
22252}
22253_ACEOF
22254if ac_fn_c_try_link "$LINENO"; then :
22255  ol_cv_pthread_lib_lpthreads=yes
22256else
22257  ol_cv_pthread_lib_lpthreads=no
22258fi
22259rm -f core conftest.err conftest.$ac_objext \
22260    conftest$ac_exeext conftest.$ac_ext
22261else
22262  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22263/* end confdefs.h.  */
22264
22265
22266/* pthread test headers */
22267#include <pthread.h>
22268#if HAVE_PTHREADS < 7
22269#include <errno.h>
22270#endif
22271#ifndef NULL
22272#define NULL (void*)0
22273#endif
22274
22275static void *task(p)
22276	void *p;
22277{
22278	return (void *) (p == NULL);
22279}
22280
22281
22282int main(argc, argv)
22283	int argc;
22284	char **argv;
22285{
22286
22287	/* pthread test function */
22288#ifndef PTHREAD_CREATE_DETACHED
22289#define	PTHREAD_CREATE_DETACHED	1
22290#endif
22291	pthread_t t;
22292	int status;
22293	int detach = PTHREAD_CREATE_DETACHED;
22294
22295#if HAVE_PTHREADS > 4
22296	/* Final pthreads */
22297	pthread_attr_t attr;
22298
22299	status = pthread_attr_init(&attr);
22300	if( status ) return status;
22301
22302#if HAVE_PTHREADS < 7
22303	status = pthread_attr_setdetachstate(&attr, &detach);
22304	if( status < 0 ) status = errno;
22305#else
22306	status = pthread_attr_setdetachstate(&attr, detach);
22307#endif
22308	if( status ) return status;
22309	status = pthread_create( &t, &attr, task, NULL );
22310#if HAVE_PTHREADS < 7
22311	if( status < 0 ) status = errno;
22312#endif
22313	if( status ) return status;
22314#else
22315	/* Draft 4 pthreads */
22316	status = pthread_create( &t, pthread_attr_default, task, NULL );
22317	if( status ) return errno;
22318
22319	/* give thread a chance to complete */
22320	/* it should remain joinable and hence detachable */
22321	sleep( 1 );
22322
22323	status = pthread_detach( &t );
22324	if( status ) return errno;
22325#endif
22326
22327#ifdef HAVE_LINUX_THREADS
22328	pthread_kill_other_threads_np();
22329#endif
22330
22331	return 0;
22332
22333}
22334
22335_ACEOF
22336if ac_fn_c_try_run "$LINENO"; then :
22337  ol_cv_pthread_lib_lpthreads=yes
22338else
22339  ol_cv_pthread_lib_lpthreads=no
22340fi
22341rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22342  conftest.$ac_objext conftest.beam conftest.$ac_ext
22343fi
22344
22345
22346		# restore the LIBS
22347		LIBS="$ol_LIBS"
22348
22349fi
22350{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lib_lpthreads" >&5
22351$as_echo "$ol_cv_pthread_lib_lpthreads" >&6; }
22352
22353	if test $ol_cv_pthread_lib_lpthreads = yes ; then
22354		ol_link_pthreads="-lpthreads"
22355		ol_link_threads=posix
22356	fi
22357fi
22358
22359
22360{ $as_echo "$as_me:${as_lineno-$LINENO}: ol_link_threads: <$ol_link_threads> ol_link_pthreads <$ol_link_pthreads>" >&5
22361$as_echo "$as_me: ol_link_threads: <$ol_link_threads> ol_link_pthreads <$ol_link_pthreads>" >&6;}
22362
22363		if test $ol_link_threads != no ; then
22364			LTHREAD_LIBS="$LTHREAD_LIBS $ol_link_pthreads"
22365
22366						save_CPPFLAGS="$CPPFLAGS"
22367			save_LIBS="$LIBS"
22368			LIBS="$LTHREAD_LIBS $LIBS"
22369
22370												for ac_func in sched_yield pthread_yield thr_yield
22371do :
22372  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
22373ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
22374if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
22375  cat >>confdefs.h <<_ACEOF
22376#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
22377_ACEOF
22378
22379fi
22380done
22381
22382
22383			if test $ac_cv_func_sched_yield = no &&
22384			   test $ac_cv_func_pthread_yield = no &&
22385			   test $ac_cv_func_thr_yield = no ; then
22386								{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sched_yield in -lrt" >&5
22387$as_echo_n "checking for sched_yield in -lrt... " >&6; }
22388if ${ac_cv_lib_rt_sched_yield+:} false; then :
22389  $as_echo_n "(cached) " >&6
22390else
22391  ac_check_lib_save_LIBS=$LIBS
22392LIBS="-lrt  $LIBS"
22393cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22394/* end confdefs.h.  */
22395
22396/* Override any GCC internal prototype to avoid an error.
22397   Use char because int might match the return type of a GCC
22398   builtin and then its argument prototype would still apply.  */
22399#ifdef __cplusplus
22400extern "C"
22401#endif
22402char sched_yield ();
22403int
22404main ()
22405{
22406return sched_yield ();
22407  ;
22408  return 0;
22409}
22410_ACEOF
22411if ac_fn_c_try_link "$LINENO"; then :
22412  ac_cv_lib_rt_sched_yield=yes
22413else
22414  ac_cv_lib_rt_sched_yield=no
22415fi
22416rm -f core conftest.err conftest.$ac_objext \
22417    conftest$ac_exeext conftest.$ac_ext
22418LIBS=$ac_check_lib_save_LIBS
22419fi
22420{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_rt_sched_yield" >&5
22421$as_echo "$ac_cv_lib_rt_sched_yield" >&6; }
22422if test "x$ac_cv_lib_rt_sched_yield" = xyes; then :
22423  LTHREAD_LIBS="$LTHREAD_LIBS -lrt"
22424
22425$as_echo "#define HAVE_SCHED_YIELD 1" >>confdefs.h
22426
22427					ac_cv_func_sched_yield=yes
22428else
22429  ac_cv_func_sched_yield=no
22430fi
22431
22432			fi
22433			if test $ac_cv_func_sched_yield = no &&
22434			   test $ac_cv_func_pthread_yield = no &&
22435			   test "$ac_cv_func_thr_yield" = no ; then
22436				{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: could not locate sched_yield() or pthread_yield()" >&5
22437$as_echo "$as_me: WARNING: could not locate sched_yield() or pthread_yield()" >&2;}
22438			fi
22439
22440						for ac_func in pthread_kill
22441do :
22442  ac_fn_c_check_func "$LINENO" "pthread_kill" "ac_cv_func_pthread_kill"
22443if test "x$ac_cv_func_pthread_kill" = xyes; then :
22444  cat >>confdefs.h <<_ACEOF
22445#define HAVE_PTHREAD_KILL 1
22446_ACEOF
22447
22448fi
22449done
22450
22451
22452									{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_rwlock_destroy with <pthread.h>" >&5
22453$as_echo_n "checking for pthread_rwlock_destroy with <pthread.h>... " >&6; }
22454if ${ol_cv_func_pthread_rwlock_destroy+:} false; then :
22455  $as_echo_n "(cached) " >&6
22456else
22457
22458								cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22459/* end confdefs.h.  */
22460
22461#include <pthread.h>
22462pthread_rwlock_t rwlock;
22463
22464int
22465main ()
22466{
22467pthread_rwlock_destroy(&rwlock);
22468  ;
22469  return 0;
22470}
22471_ACEOF
22472if ac_fn_c_try_link "$LINENO"; then :
22473  ol_cv_func_pthread_rwlock_destroy=yes
22474else
22475  ol_cv_func_pthread_rwlock_destroy=no
22476fi
22477rm -f core conftest.err conftest.$ac_objext \
22478    conftest$ac_exeext conftest.$ac_ext
22479
22480fi
22481{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_func_pthread_rwlock_destroy" >&5
22482$as_echo "$ol_cv_func_pthread_rwlock_destroy" >&6; }
22483			if test $ol_cv_func_pthread_rwlock_destroy = yes ; then
22484
22485$as_echo "#define HAVE_PTHREAD_RWLOCK_DESTROY 1" >>confdefs.h
22486
22487			fi
22488
22489									{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_detach with <pthread.h>" >&5
22490$as_echo_n "checking for pthread_detach with <pthread.h>... " >&6; }
22491if ${ol_cv_func_pthread_detach+:} false; then :
22492  $as_echo_n "(cached) " >&6
22493else
22494
22495								cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22496/* end confdefs.h.  */
22497
22498#include <pthread.h>
22499#ifndef NULL
22500#define NULL (void*)0
22501#endif
22502
22503int
22504main ()
22505{
22506pthread_detach(NULL);
22507  ;
22508  return 0;
22509}
22510_ACEOF
22511if ac_fn_c_try_link "$LINENO"; then :
22512  ol_cv_func_pthread_detach=yes
22513else
22514  ol_cv_func_pthread_detach=no
22515fi
22516rm -f core conftest.err conftest.$ac_objext \
22517    conftest$ac_exeext conftest.$ac_ext
22518
22519fi
22520{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_func_pthread_detach" >&5
22521$as_echo "$ol_cv_func_pthread_detach" >&6; }
22522
22523			if test $ol_cv_func_pthread_detach = no ; then
22524				as_fn_error $? "could not locate pthread_detach()" "$LINENO" 5
22525			fi
22526
22527
22528$as_echo "#define HAVE_PTHREAD_DETACH 1" >>confdefs.h
22529
22530
22531						for ac_func in \
22532				pthread_setconcurrency \
22533				pthread_getconcurrency \
22534				thr_setconcurrency \
22535				thr_getconcurrency \
22536
22537do :
22538  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
22539ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
22540if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
22541  cat >>confdefs.h <<_ACEOF
22542#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
22543_ACEOF
22544
22545fi
22546done
22547
22548
22549
22550	for ac_func in pthread_kill_other_threads_np
22551do :
22552  ac_fn_c_check_func "$LINENO" "pthread_kill_other_threads_np" "ac_cv_func_pthread_kill_other_threads_np"
22553if test "x$ac_cv_func_pthread_kill_other_threads_np" = xyes; then :
22554  cat >>confdefs.h <<_ACEOF
22555#define HAVE_PTHREAD_KILL_OTHER_THREADS_NP 1
22556_ACEOF
22557
22558fi
22559done
22560
22561	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LinuxThreads implementation" >&5
22562$as_echo_n "checking for LinuxThreads implementation... " >&6; }
22563if ${ol_cv_sys_linux_threads+:} false; then :
22564  $as_echo_n "(cached) " >&6
22565else
22566  ol_cv_sys_linux_threads=$ac_cv_func_pthread_kill_other_threads_np
22567fi
22568{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_sys_linux_threads" >&5
22569$as_echo "$ol_cv_sys_linux_threads" >&6; }
22570
22571
22572
22573
22574	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LinuxThreads consistency" >&5
22575$as_echo_n "checking for LinuxThreads consistency... " >&6; }
22576if ${ol_cv_linux_threads+:} false; then :
22577  $as_echo_n "(cached) " >&6
22578else
22579
22580		if test $ol_cv_header_linux_threads = yes &&
22581		   test $ol_cv_sys_linux_threads = yes; then
22582			ol_cv_linux_threads=yes
22583		elif test $ol_cv_header_linux_threads = no &&
22584		     test $ol_cv_sys_linux_threads = no; then
22585			ol_cv_linux_threads=no
22586		else
22587			ol_cv_linux_threads=error
22588		fi
22589
22590fi
22591{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_linux_threads" >&5
22592$as_echo "$ol_cv_linux_threads" >&6; }
22593
22594
22595			if test $ol_cv_linux_threads = error; then
22596				as_fn_error $? "LinuxThreads header/library mismatch" "$LINENO" 5;
22597			fi
22598
22599			{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if pthread_create() works" >&5
22600$as_echo_n "checking if pthread_create() works... " >&6; }
22601if ${ol_cv_pthread_create_works+:} false; then :
22602  $as_echo_n "(cached) " >&6
22603else
22604
22605			if test "$cross_compiling" = yes; then :
22606  				ol_cv_pthread_create_works=yes
22607else
22608  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22609/* end confdefs.h.  */
22610
22611
22612/* pthread test headers */
22613#include <pthread.h>
22614#if HAVE_PTHREADS < 7
22615#include <errno.h>
22616#endif
22617#ifndef NULL
22618#define NULL (void*)0
22619#endif
22620
22621static void *task(p)
22622	void *p;
22623{
22624	return (void *) (p == NULL);
22625}
22626
22627
22628int main(argc, argv)
22629	int argc;
22630	char **argv;
22631{
22632
22633	/* pthread test function */
22634#ifndef PTHREAD_CREATE_DETACHED
22635#define	PTHREAD_CREATE_DETACHED	1
22636#endif
22637	pthread_t t;
22638	int status;
22639	int detach = PTHREAD_CREATE_DETACHED;
22640
22641#if HAVE_PTHREADS > 4
22642	/* Final pthreads */
22643	pthread_attr_t attr;
22644
22645	status = pthread_attr_init(&attr);
22646	if( status ) return status;
22647
22648#if HAVE_PTHREADS < 7
22649	status = pthread_attr_setdetachstate(&attr, &detach);
22650	if( status < 0 ) status = errno;
22651#else
22652	status = pthread_attr_setdetachstate(&attr, detach);
22653#endif
22654	if( status ) return status;
22655	status = pthread_create( &t, &attr, task, NULL );
22656#if HAVE_PTHREADS < 7
22657	if( status < 0 ) status = errno;
22658#endif
22659	if( status ) return status;
22660#else
22661	/* Draft 4 pthreads */
22662	status = pthread_create( &t, pthread_attr_default, task, NULL );
22663	if( status ) return errno;
22664
22665	/* give thread a chance to complete */
22666	/* it should remain joinable and hence detachable */
22667	sleep( 1 );
22668
22669	status = pthread_detach( &t );
22670	if( status ) return errno;
22671#endif
22672
22673#ifdef HAVE_LINUX_THREADS
22674	pthread_kill_other_threads_np();
22675#endif
22676
22677	return 0;
22678
22679}
22680
22681_ACEOF
22682if ac_fn_c_try_run "$LINENO"; then :
22683  ol_cv_pthread_create_works=yes
22684else
22685  ol_cv_pthread_create_works=no
22686fi
22687rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22688  conftest.$ac_objext conftest.beam conftest.$ac_ext
22689fi
22690
22691fi
22692{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_create_works" >&5
22693$as_echo "$ol_cv_pthread_create_works" >&6; }
22694
22695			if test $ol_cv_pthread_create_works = no ; then
22696				as_fn_error $? "pthread_create is not usable, check environment settings" "$LINENO" 5
22697			fi
22698
22699			ol_replace_broken_yield=no
22700
22701			if test $ol_replace_broken_yield = yes ; then
22702
22703$as_echo "#define REPLACE_BROKEN_YIELD 1" >>confdefs.h
22704
22705			fi
22706
22707						if test x$ol_with_yielding_select = xauto ; then
22708				{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if select yields when using pthreads" >&5
22709$as_echo_n "checking if select yields when using pthreads... " >&6; }
22710if ${ol_cv_pthread_select_yields+:} false; then :
22711  $as_echo_n "(cached) " >&6
22712else
22713
22714				if test "$cross_compiling" = yes; then :
22715  ol_cv_pthread_select_yields=cross
22716else
22717  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22718/* end confdefs.h.  */
22719
22720#include <sys/types.h>
22721#include <sys/time.h>
22722#include <unistd.h>
22723#include <pthread.h>
22724#ifndef NULL
22725#define NULL (void*) 0
22726#endif
22727
22728static int fildes[2];
22729
22730static void *task(p)
22731	void *p;
22732{
22733	int i;
22734	struct timeval tv;
22735
22736	fd_set rfds;
22737
22738	tv.tv_sec=10;
22739	tv.tv_usec=0;
22740
22741	FD_ZERO(&rfds);
22742	FD_SET(fildes[0], &rfds);
22743
22744	/* we're not interested in any fds */
22745	i = select(FD_SETSIZE, &rfds, NULL, NULL, &tv);
22746
22747	if(i < 0) {
22748		perror("select");
22749		exit(10);
22750	}
22751
22752	exit(0); /* if we exit here, the select blocked the whole process */
22753}
22754
22755int main(argc, argv)
22756	int argc;
22757	char **argv;
22758{
22759	pthread_t t;
22760
22761	/* create a pipe to select */
22762	if(pipe(&fildes[0])) {
22763		perror("select");
22764		exit(1);
22765	}
22766
22767#ifdef HAVE_PTHREAD_SETCONCURRENCY
22768	(void) pthread_setconcurrency(2);
22769#else
22770#ifdef HAVE_THR_SETCONCURRENCY
22771	/* Set Solaris LWP concurrency to 2 */
22772	thr_setconcurrency(2);
22773#endif
22774#endif
22775
22776#if HAVE_PTHREADS < 6
22777	pthread_create(&t, pthread_attr_default, task, NULL);
22778#else
22779	pthread_create(&t, NULL, task, NULL);
22780#endif
22781
22782	/* make sure task runs first */
22783#ifdef HAVE_THR_YIELD
22784	thr_yield();
22785#elif defined( HAVE_SCHED_YIELD )
22786	sched_yield();
22787#elif defined( HAVE_PTHREAD_YIELD )
22788	pthread_yield();
22789#endif
22790
22791	exit(2);
22792}
22793_ACEOF
22794if ac_fn_c_try_run "$LINENO"; then :
22795  ol_cv_pthread_select_yields=no
22796else
22797  ol_cv_pthread_select_yields=yes
22798fi
22799rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22800  conftest.$ac_objext conftest.beam conftest.$ac_ext
22801fi
22802
22803fi
22804{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_select_yields" >&5
22805$as_echo "$ol_cv_pthread_select_yields" >&6; }
22806
22807				if test $ol_cv_pthread_select_yields = cross ; then
22808					as_fn_error $? "crossing compiling: use --with-yielding-select=yes|no|manual" "$LINENO" 5
22809				fi
22810
22811				if test $ol_cv_pthread_select_yields = yes ; then
22812					ol_with_yielding_select=yes
22813				fi
22814			fi
22815
22816						CPPFLAGS="$save_CPPFLAGS"
22817			LIBS="$save_LIBS"
22818		else
22819			as_fn_error $? "could not locate usable POSIX Threads" "$LINENO" 5
22820		fi
22821	fi
22822
22823	if test $ol_with_threads = posix ; then
22824		as_fn_error $? "could not locate POSIX Threads" "$LINENO" 5
22825	fi
22826	;;
22827esac
22828
22829case $ol_with_threads in auto | yes | mach)
22830
22831		for ac_header in mach/cthreads.h cthreads.h
22832do :
22833  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
22834ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
22835if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
22836  cat >>confdefs.h <<_ACEOF
22837#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
22838_ACEOF
22839
22840fi
22841
22842done
22843
22844	if test $ac_cv_header_mach_cthreads_h = yes ; then
22845		ol_with_threads=found
22846
22847				ac_fn_c_check_func "$LINENO" "cthread_fork" "ac_cv_func_cthread_fork"
22848if test "x$ac_cv_func_cthread_fork" = xyes; then :
22849  ol_link_threads=yes
22850fi
22851
22852
22853		if test $ol_link_threads = no ; then
22854									{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for cthread_fork with -all_load" >&5
22855$as_echo_n "checking for cthread_fork with -all_load... " >&6; }
22856if ${ol_cv_cthread_all_load+:} false; then :
22857  $as_echo_n "(cached) " >&6
22858else
22859
22860								save_LIBS="$LIBS"
22861				LIBS="-all_load $LIBS"
22862				cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22863/* end confdefs.h.  */
22864#include <mach/cthreads.h>
22865int
22866main ()
22867{
22868
22869					cthread_fork((void *)0, (void *)0);
22870
22871  ;
22872  return 0;
22873}
22874_ACEOF
22875if ac_fn_c_try_link "$LINENO"; then :
22876  ol_cv_cthread_all_load=yes
22877else
22878  ol_cv_cthread_all_load=no
22879fi
22880rm -f core conftest.err conftest.$ac_objext \
22881    conftest$ac_exeext conftest.$ac_ext
22882								LIBS="$save_LIBS"
22883
22884fi
22885{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_cthread_all_load" >&5
22886$as_echo "$ol_cv_cthread_all_load" >&6; }
22887
22888			if test $ol_cv_cthread_all_load = yes ; then
22889				LTHREAD_LIBS="$LTHREAD_LIBS -all_load"
22890				ol_link_threads=mach
22891				ol_with_threads=found
22892			fi
22893		fi
22894
22895	elif test $ac_cv_header_cthreads_h = yes ; then
22896
22897		ol_with_threads=found
22898
22899				save_LIBS="$LIBS"
22900		LIBS="$LIBS -lthreads"
22901		ac_fn_c_check_func "$LINENO" "cthread_fork" "ac_cv_func_cthread_fork"
22902if test "x$ac_cv_func_cthread_fork" = xyes; then :
22903  ol_link_threads=yes
22904fi
22905
22906		LIBS="$save_LIBS"
22907
22908		if test $ol_link_threads = yes ; then
22909			LTHREAD_LIBS="-lthreads"
22910			ol_link_threads=mach
22911			ol_with_threads=found
22912		else
22913			as_fn_error $? "could not link with Mach CThreads" "$LINENO" 5
22914		fi
22915
22916	elif test $ol_with_threads = mach ; then
22917		as_fn_error $? "could not locate Mach CThreads" "$LINENO" 5
22918	fi
22919
22920	if test $ol_link_threads = mach ; then
22921
22922$as_echo "#define HAVE_MACH_CTHREADS 1" >>confdefs.h
22923
22924	elif test $ol_with_threads = found ; then
22925		as_fn_error $? "could not link with Mach CThreads" "$LINENO" 5
22926	fi
22927	;;
22928esac
22929
22930case $ol_with_threads in auto | yes | pth)
22931
22932	for ac_header in pth.h
22933do :
22934  ac_fn_c_check_header_mongrel "$LINENO" "pth.h" "ac_cv_header_pth_h" "$ac_includes_default"
22935if test "x$ac_cv_header_pth_h" = xyes; then :
22936  cat >>confdefs.h <<_ACEOF
22937#define HAVE_PTH_H 1
22938_ACEOF
22939
22940fi
22941
22942done
22943
22944
22945	if test $ac_cv_header_pth_h = yes ; then
22946		{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pth_version in -lpth" >&5
22947$as_echo_n "checking for pth_version in -lpth... " >&6; }
22948if ${ac_cv_lib_pth_pth_version+:} false; then :
22949  $as_echo_n "(cached) " >&6
22950else
22951  ac_check_lib_save_LIBS=$LIBS
22952LIBS="-lpth  $LIBS"
22953cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22954/* end confdefs.h.  */
22955
22956/* Override any GCC internal prototype to avoid an error.
22957   Use char because int might match the return type of a GCC
22958   builtin and then its argument prototype would still apply.  */
22959#ifdef __cplusplus
22960extern "C"
22961#endif
22962char pth_version ();
22963int
22964main ()
22965{
22966return pth_version ();
22967  ;
22968  return 0;
22969}
22970_ACEOF
22971if ac_fn_c_try_link "$LINENO"; then :
22972  ac_cv_lib_pth_pth_version=yes
22973else
22974  ac_cv_lib_pth_pth_version=no
22975fi
22976rm -f core conftest.err conftest.$ac_objext \
22977    conftest$ac_exeext conftest.$ac_ext
22978LIBS=$ac_check_lib_save_LIBS
22979fi
22980{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pth_pth_version" >&5
22981$as_echo "$ac_cv_lib_pth_pth_version" >&6; }
22982if test "x$ac_cv_lib_pth_pth_version" = xyes; then :
22983  have_pth=yes
22984else
22985  have_pth=no
22986fi
22987
22988
22989		if test $have_pth = yes ; then
22990
22991$as_echo "#define HAVE_GNU_PTH 1" >>confdefs.h
22992
22993			LTHREAD_LIBS="$LTHREAD_LIBS -lpth"
22994			ol_link_threads=pth
22995			ol_with_threads=found
22996
22997			if test x$ol_with_yielding_select = xauto ; then
22998				ol_with_yielding_select=yes
22999			fi
23000		fi
23001	fi
23002	;;
23003esac
23004
23005case $ol_with_threads in auto | yes | lwp)
23006
23007		for ac_header in thread.h synch.h
23008do :
23009  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
23010ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
23011if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
23012  cat >>confdefs.h <<_ACEOF
23013#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
23014_ACEOF
23015
23016fi
23017
23018done
23019
23020	if test $ac_cv_header_thread_h = yes &&
23021	   test $ac_cv_header_synch_h = yes ; then
23022		{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for thr_create in -lthread" >&5
23023$as_echo_n "checking for thr_create in -lthread... " >&6; }
23024if ${ac_cv_lib_thread_thr_create+:} false; then :
23025  $as_echo_n "(cached) " >&6
23026else
23027  ac_check_lib_save_LIBS=$LIBS
23028LIBS="-lthread  $LIBS"
23029cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23030/* end confdefs.h.  */
23031
23032/* Override any GCC internal prototype to avoid an error.
23033   Use char because int might match the return type of a GCC
23034   builtin and then its argument prototype would still apply.  */
23035#ifdef __cplusplus
23036extern "C"
23037#endif
23038char thr_create ();
23039int
23040main ()
23041{
23042return thr_create ();
23043  ;
23044  return 0;
23045}
23046_ACEOF
23047if ac_fn_c_try_link "$LINENO"; then :
23048  ac_cv_lib_thread_thr_create=yes
23049else
23050  ac_cv_lib_thread_thr_create=no
23051fi
23052rm -f core conftest.err conftest.$ac_objext \
23053    conftest$ac_exeext conftest.$ac_ext
23054LIBS=$ac_check_lib_save_LIBS
23055fi
23056{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_thread_thr_create" >&5
23057$as_echo "$ac_cv_lib_thread_thr_create" >&6; }
23058if test "x$ac_cv_lib_thread_thr_create" = xyes; then :
23059  have_thr=yes
23060else
23061  have_thr=no
23062fi
23063
23064
23065		if test $have_thr = yes ; then
23066
23067$as_echo "#define HAVE_THR 1" >>confdefs.h
23068
23069			LTHREAD_LIBS="$LTHREAD_LIBS -lthread"
23070			ol_link_threads=thr
23071
23072			if test x$ol_with_yielding_select = xauto ; then
23073				ol_with_yielding_select=yes
23074			fi
23075
23076						for ac_func in \
23077				thr_setconcurrency \
23078				thr_getconcurrency \
23079
23080do :
23081  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
23082ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
23083if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
23084  cat >>confdefs.h <<_ACEOF
23085#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
23086_ACEOF
23087
23088fi
23089done
23090
23091		fi
23092	fi
23093
23094		for ac_header in lwp/lwp.h
23095do :
23096  ac_fn_c_check_header_mongrel "$LINENO" "lwp/lwp.h" "ac_cv_header_lwp_lwp_h" "$ac_includes_default"
23097if test "x$ac_cv_header_lwp_lwp_h" = xyes; then :
23098  cat >>confdefs.h <<_ACEOF
23099#define HAVE_LWP_LWP_H 1
23100_ACEOF
23101
23102fi
23103
23104done
23105
23106	if test $ac_cv_header_lwp_lwp_h = yes ; then
23107		{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for lwp_create in -llwp" >&5
23108$as_echo_n "checking for lwp_create in -llwp... " >&6; }
23109if ${ac_cv_lib_lwp_lwp_create+:} false; then :
23110  $as_echo_n "(cached) " >&6
23111else
23112  ac_check_lib_save_LIBS=$LIBS
23113LIBS="-llwp  $LIBS"
23114cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23115/* end confdefs.h.  */
23116
23117/* Override any GCC internal prototype to avoid an error.
23118   Use char because int might match the return type of a GCC
23119   builtin and then its argument prototype would still apply.  */
23120#ifdef __cplusplus
23121extern "C"
23122#endif
23123char lwp_create ();
23124int
23125main ()
23126{
23127return lwp_create ();
23128  ;
23129  return 0;
23130}
23131_ACEOF
23132if ac_fn_c_try_link "$LINENO"; then :
23133  ac_cv_lib_lwp_lwp_create=yes
23134else
23135  ac_cv_lib_lwp_lwp_create=no
23136fi
23137rm -f core conftest.err conftest.$ac_objext \
23138    conftest$ac_exeext conftest.$ac_ext
23139LIBS=$ac_check_lib_save_LIBS
23140fi
23141{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lwp_lwp_create" >&5
23142$as_echo "$ac_cv_lib_lwp_lwp_create" >&6; }
23143if test "x$ac_cv_lib_lwp_lwp_create" = xyes; then :
23144  have_lwp=yes
23145else
23146  have_lwp=no
23147fi
23148
23149
23150		if test $have_lwp = yes ; then
23151
23152$as_echo "#define HAVE_LWP 1" >>confdefs.h
23153
23154			LTHREAD_LIBS="$LTHREAD_LIBS -llwp"
23155			ol_link_threads=lwp
23156
23157			if test x$ol_with_yielding_select = xauto ; then
23158				ol_with_yielding_select=no
23159			fi
23160		fi
23161	fi
23162	;;
23163esac
23164
23165if test $ol_with_yielding_select = yes ; then
23166
23167$as_echo "#define HAVE_YIELDING_SELECT 1" >>confdefs.h
23168
23169fi
23170
23171if test $ol_with_threads = manual ; then
23172		ol_link_threads=yes
23173
23174	{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: thread defines and link options must be set manually" >&5
23175$as_echo "$as_me: WARNING: thread defines and link options must be set manually" >&2;}
23176
23177	for ac_header in pthread.h sched.h
23178do :
23179  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
23180ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
23181if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
23182  cat >>confdefs.h <<_ACEOF
23183#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
23184_ACEOF
23185
23186fi
23187
23188done
23189
23190	for ac_func in sched_yield pthread_yield
23191do :
23192  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
23193ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
23194if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
23195  cat >>confdefs.h <<_ACEOF
23196#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
23197_ACEOF
23198
23199fi
23200done
23201
23202
23203	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LinuxThreads pthread.h" >&5
23204$as_echo_n "checking for LinuxThreads pthread.h... " >&6; }
23205if ${ol_cv_header_linux_threads+:} false; then :
23206  $as_echo_n "(cached) " >&6
23207else
23208  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23209/* end confdefs.h.  */
23210#include <pthread.h>
23211_ACEOF
23212if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
23213  $EGREP "pthread_kill_other_threads_np" >/dev/null 2>&1; then :
23214  ol_cv_header_linux_threads=yes
23215else
23216  ol_cv_header_linux_threads=no
23217fi
23218rm -f conftest*
23219
23220
23221fi
23222{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_header_linux_threads" >&5
23223$as_echo "$ol_cv_header_linux_threads" >&6; }
23224	if test $ol_cv_header_linux_threads = yes; then
23225
23226$as_echo "#define HAVE_LINUX_THREADS 1" >>confdefs.h
23227
23228	fi
23229
23230
23231	for ac_header in mach/cthreads.h
23232do :
23233  ac_fn_c_check_header_mongrel "$LINENO" "mach/cthreads.h" "ac_cv_header_mach_cthreads_h" "$ac_includes_default"
23234if test "x$ac_cv_header_mach_cthreads_h" = xyes; then :
23235  cat >>confdefs.h <<_ACEOF
23236#define HAVE_MACH_CTHREADS_H 1
23237_ACEOF
23238
23239fi
23240
23241done
23242
23243	for ac_header in lwp/lwp.h
23244do :
23245  ac_fn_c_check_header_mongrel "$LINENO" "lwp/lwp.h" "ac_cv_header_lwp_lwp_h" "$ac_includes_default"
23246if test "x$ac_cv_header_lwp_lwp_h" = xyes; then :
23247  cat >>confdefs.h <<_ACEOF
23248#define HAVE_LWP_LWP_H 1
23249_ACEOF
23250
23251fi
23252
23253done
23254
23255	for ac_header in thread.h synch.h
23256do :
23257  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
23258ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
23259if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
23260  cat >>confdefs.h <<_ACEOF
23261#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
23262_ACEOF
23263
23264fi
23265
23266done
23267
23268fi
23269
23270if test $ol_link_threads != no && test $ol_link_threads != nt ; then
23271
23272$as_echo "#define REENTRANT 1" >>confdefs.h
23273
23274
23275$as_echo "#define _REENTRANT 1" >>confdefs.h
23276
23277
23278$as_echo "#define THREAD_SAFE 1" >>confdefs.h
23279
23280
23281$as_echo "#define _THREAD_SAFE 1" >>confdefs.h
23282
23283
23284$as_echo "#define THREADSAFE 1" >>confdefs.h
23285
23286
23287$as_echo "#define _THREADSAFE 1" >>confdefs.h
23288
23289
23290$as_echo "#define _SGI_MP_SOURCE 1" >>confdefs.h
23291
23292
23293			{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for thread specific errno" >&5
23294$as_echo_n "checking for thread specific errno... " >&6; }
23295if ${ol_cv_errno_thread_specific+:} false; then :
23296  $as_echo_n "(cached) " >&6
23297else
23298
23299		cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23300/* end confdefs.h.  */
23301#include <errno.h>
23302int
23303main ()
23304{
23305errno = 0;
23306  ;
23307  return 0;
23308}
23309_ACEOF
23310if ac_fn_c_try_link "$LINENO"; then :
23311  ol_cv_errno_thread_specific=yes
23312else
23313  ol_cv_errno_thread_specific=no
23314fi
23315rm -f core conftest.err conftest.$ac_objext \
23316    conftest$ac_exeext conftest.$ac_ext
23317
23318fi
23319{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_errno_thread_specific" >&5
23320$as_echo "$ol_cv_errno_thread_specific" >&6; }
23321
23322			{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for thread specific h_errno" >&5
23323$as_echo_n "checking for thread specific h_errno... " >&6; }
23324if ${ol_cv_h_errno_thread_specific+:} false; then :
23325  $as_echo_n "(cached) " >&6
23326else
23327
23328		cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23329/* end confdefs.h.  */
23330#include <netdb.h>
23331int
23332main ()
23333{
23334h_errno = 0;
23335  ;
23336  return 0;
23337}
23338_ACEOF
23339if ac_fn_c_try_link "$LINENO"; then :
23340  ol_cv_h_errno_thread_specific=yes
23341else
23342  ol_cv_h_errno_thread_specific=no
23343fi
23344rm -f core conftest.err conftest.$ac_objext \
23345    conftest$ac_exeext conftest.$ac_ext
23346
23347fi
23348{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_h_errno_thread_specific" >&5
23349$as_echo "$ol_cv_h_errno_thread_specific" >&6; }
23350
23351	if test $ol_cv_errno_thread_specific != yes ||
23352	   test $ol_cv_h_errno_thread_specific != yes ; then
23353		LIBS="$LTHREAD_LIBS $LIBS"
23354		LTHREAD_LIBS=""
23355	fi
23356
23357fi
23358
23359if test $ol_link_threads = no ; then
23360	if test $ol_with_threads = yes ; then
23361		as_fn_error $? "no suitable thread support" "$LINENO" 5
23362	fi
23363
23364	if test $ol_with_threads = auto ; then
23365		{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no suitable thread support, disabling threads" >&5
23366$as_echo "$as_me: WARNING: no suitable thread support, disabling threads" >&2;}
23367		ol_with_threads=no
23368	fi
23369
23370
23371$as_echo "#define NO_THREADS 1" >>confdefs.h
23372
23373	LTHREAD_LIBS=""
23374	BUILD_THREAD=no
23375else
23376	BUILD_THREAD=yes
23377fi
23378
23379if test $ol_link_threads != no ; then
23380
23381$as_echo "#define LDAP_API_FEATURE_X_OPENLDAP_THREAD_SAFE 1" >>confdefs.h
23382
23383fi
23384
23385# Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
23386case "$ol_with_threads" in
23387 no)
23388    ol_pthread_ok=no
23389
23390    ;;
23391 *)
23392    ol_found_pthreads=yes
23393    ;;
23394esac
23395
23396ac_ext=c
23397ac_cpp='$CPP $CPPFLAGS'
23398ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
23399ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
23400ac_compiler_gnu=$ac_cv_c_compiler_gnu
23401
23402
23403
23404
23405
23406
23407    case "$ol_found_pthreads" in
23408     yes)
23409	saved_LIBS="$LIBS"
23410	LIBS="$LTHREAD_LIBS $LIBS"
23411	saved_CFLAGS="$CFLAGS"
23412	CFLAGS="$PTHREAD_CFLAGS $CFLAGS"
23413	for ac_func in sem_timedwait
23414do :
23415  ac_fn_c_check_func "$LINENO" "sem_timedwait" "ac_cv_func_sem_timedwait"
23416if test "x$ac_cv_func_sem_timedwait" = xyes; then :
23417  cat >>confdefs.h <<_ACEOF
23418#define HAVE_SEM_TIMEDWAIT 1
23419_ACEOF
23420
23421fi
23422done
23423
23424	LIBS="$saved_LIBS"
23425	{ saved_LIBS=; unset saved_LIBS;}
23426	CFLAGS="$saved_CFLAGS"
23427	{ saved_CFLAGS=; unset saved_CFLAGS;}
23428	case "$ac_cv_func_sem_timedwait" in
23429	 yes)
23430	    PTHREAD_LIBS="$LTHREAD_LIBS"
23431	    have_pthreads=yes
23432	esac
23433    esac
23434esac
23435
23436case "$have_pthreads" in
23437 yes)
23438    CFLAGS_NTP="$CFLAGS_NTP $PTHREAD_CFLAGS"
23439    saved_LIBS="$LIBS"
23440    LIBS="$LTHREAD_LIBS $LIBS"
23441    saved_CFLAGS="$CFLAGS"
23442    CFLAGS="$PTHREAD_CFLAGS $CFLAGS"
23443    # The cast to long int works around a bug in the HP C Compiler
23444# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
23445# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
23446# This bug is HP SR number 8606223364.
23447{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of pthread_t" >&5
23448$as_echo_n "checking size of pthread_t... " >&6; }
23449if ${ac_cv_sizeof_pthread_t+:} false; then :
23450  $as_echo_n "(cached) " >&6
23451else
23452  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (pthread_t))" "ac_cv_sizeof_pthread_t"        "
23453	    $ac_includes_default
23454	    #include <pthread.h>
23455
23456
23457"; then :
23458
23459else
23460  if test "$ac_cv_type_pthread_t" = yes; then
23461     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
23462$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
23463as_fn_error 77 "cannot compute sizeof (pthread_t)
23464See \`config.log' for more details" "$LINENO" 5; }
23465   else
23466     ac_cv_sizeof_pthread_t=0
23467   fi
23468fi
23469
23470fi
23471{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_pthread_t" >&5
23472$as_echo "$ac_cv_sizeof_pthread_t" >&6; }
23473
23474
23475
23476cat >>confdefs.h <<_ACEOF
23477#define SIZEOF_PTHREAD_T $ac_cv_sizeof_pthread_t
23478_ACEOF
23479
23480
23481    LIBISC_PTHREADS_NOTHREADS=pthreads
23482
23483$as_echo "#define ISC_PLATFORM_USETHREADS 1" >>confdefs.h
23484
23485    #
23486    # We'd like to use sigwait() too
23487    #
23488    ac_fn_c_check_func "$LINENO" "sigwait" "ac_cv_func_sigwait"
23489if test "x$ac_cv_func_sigwait" = xyes; then :
23490  have_sigwait=yes
23491else
23492  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigwait in -lc" >&5
23493$as_echo_n "checking for sigwait in -lc... " >&6; }
23494if ${ac_cv_lib_c_sigwait+:} false; then :
23495  $as_echo_n "(cached) " >&6
23496else
23497  ac_check_lib_save_LIBS=$LIBS
23498LIBS="-lc  $LIBS"
23499cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23500/* end confdefs.h.  */
23501
23502/* Override any GCC internal prototype to avoid an error.
23503   Use char because int might match the return type of a GCC
23504   builtin and then its argument prototype would still apply.  */
23505#ifdef __cplusplus
23506extern "C"
23507#endif
23508char sigwait ();
23509int
23510main ()
23511{
23512return sigwait ();
23513  ;
23514  return 0;
23515}
23516_ACEOF
23517if ac_fn_c_try_link "$LINENO"; then :
23518  ac_cv_lib_c_sigwait=yes
23519else
23520  ac_cv_lib_c_sigwait=no
23521fi
23522rm -f core conftest.err conftest.$ac_objext \
23523    conftest$ac_exeext conftest.$ac_ext
23524LIBS=$ac_check_lib_save_LIBS
23525fi
23526{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_sigwait" >&5
23527$as_echo "$ac_cv_lib_c_sigwait" >&6; }
23528if test "x$ac_cv_lib_c_sigwait" = xyes; then :
23529  have_sigwait=yes
23530else
23531  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigwait in -lpthread" >&5
23532$as_echo_n "checking for sigwait in -lpthread... " >&6; }
23533if ${ac_cv_lib_pthread_sigwait+:} false; then :
23534  $as_echo_n "(cached) " >&6
23535else
23536  ac_check_lib_save_LIBS=$LIBS
23537LIBS="-lpthread  $LIBS"
23538cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23539/* end confdefs.h.  */
23540
23541/* Override any GCC internal prototype to avoid an error.
23542   Use char because int might match the return type of a GCC
23543   builtin and then its argument prototype would still apply.  */
23544#ifdef __cplusplus
23545extern "C"
23546#endif
23547char sigwait ();
23548int
23549main ()
23550{
23551return sigwait ();
23552  ;
23553  return 0;
23554}
23555_ACEOF
23556if ac_fn_c_try_link "$LINENO"; then :
23557  ac_cv_lib_pthread_sigwait=yes
23558else
23559  ac_cv_lib_pthread_sigwait=no
23560fi
23561rm -f core conftest.err conftest.$ac_objext \
23562    conftest$ac_exeext conftest.$ac_ext
23563LIBS=$ac_check_lib_save_LIBS
23564fi
23565{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_sigwait" >&5
23566$as_echo "$ac_cv_lib_pthread_sigwait" >&6; }
23567if test "x$ac_cv_lib_pthread_sigwait" = xyes; then :
23568  have_sigwait=yes
23569else
23570  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _Psigwait in -lpthread" >&5
23571$as_echo_n "checking for _Psigwait in -lpthread... " >&6; }
23572if ${ac_cv_lib_pthread__Psigwait+:} false; then :
23573  $as_echo_n "(cached) " >&6
23574else
23575  ac_check_lib_save_LIBS=$LIBS
23576LIBS="-lpthread  $LIBS"
23577cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23578/* end confdefs.h.  */
23579
23580/* Override any GCC internal prototype to avoid an error.
23581   Use char because int might match the return type of a GCC
23582   builtin and then its argument prototype would still apply.  */
23583#ifdef __cplusplus
23584extern "C"
23585#endif
23586char _Psigwait ();
23587int
23588main ()
23589{
23590return _Psigwait ();
23591  ;
23592  return 0;
23593}
23594_ACEOF
23595if ac_fn_c_try_link "$LINENO"; then :
23596  ac_cv_lib_pthread__Psigwait=yes
23597else
23598  ac_cv_lib_pthread__Psigwait=no
23599fi
23600rm -f core conftest.err conftest.$ac_objext \
23601    conftest$ac_exeext conftest.$ac_ext
23602LIBS=$ac_check_lib_save_LIBS
23603fi
23604{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread__Psigwait" >&5
23605$as_echo "$ac_cv_lib_pthread__Psigwait" >&6; }
23606if test "x$ac_cv_lib_pthread__Psigwait" = xyes; then :
23607  have_sigwait=yes
23608else
23609  have_sigwait=no
23610
23611fi
23612
23613
23614fi
23615
23616
23617fi
23618
23619
23620fi
23621
23622    case "$host:$have_sigwait" in
23623     *-freebsd*:no)
23624	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigwait in -lc_r" >&5
23625$as_echo_n "checking for sigwait in -lc_r... " >&6; }
23626if ${ac_cv_lib_c_r_sigwait+:} false; then :
23627  $as_echo_n "(cached) " >&6
23628else
23629  ac_check_lib_save_LIBS=$LIBS
23630LIBS="-lc_r  $LIBS"
23631cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23632/* end confdefs.h.  */
23633
23634/* Override any GCC internal prototype to avoid an error.
23635   Use char because int might match the return type of a GCC
23636   builtin and then its argument prototype would still apply.  */
23637#ifdef __cplusplus
23638extern "C"
23639#endif
23640char sigwait ();
23641int
23642main ()
23643{
23644return sigwait ();
23645  ;
23646  return 0;
23647}
23648_ACEOF
23649if ac_fn_c_try_link "$LINENO"; then :
23650  ac_cv_lib_c_r_sigwait=yes
23651else
23652  ac_cv_lib_c_r_sigwait=no
23653fi
23654rm -f core conftest.err conftest.$ac_objext \
23655    conftest$ac_exeext conftest.$ac_ext
23656LIBS=$ac_check_lib_save_LIBS
23657fi
23658{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_r_sigwait" >&5
23659$as_echo "$ac_cv_lib_c_r_sigwait" >&6; }
23660if test "x$ac_cv_lib_c_r_sigwait" = xyes; then :
23661  have_sigwait=yes
23662
23663fi
23664
23665    esac
23666    case "$have_sigwait" in
23667     yes)
23668	ac_cv_func_sigwait=yes
23669
23670$as_echo "#define HAVE_SIGWAIT 1" >>confdefs.h
23671
23672    esac
23673
23674    for ac_func in pthread_attr_getstacksize
23675do :
23676  ac_fn_c_check_func "$LINENO" "pthread_attr_getstacksize" "ac_cv_func_pthread_attr_getstacksize"
23677if test "x$ac_cv_func_pthread_attr_getstacksize" = xyes; then :
23678  cat >>confdefs.h <<_ACEOF
23679#define HAVE_PTHREAD_ATTR_GETSTACKSIZE 1
23680_ACEOF
23681
23682fi
23683done
23684
23685    for ac_func in pthread_attr_setstacksize sysconf
23686do :
23687  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
23688ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
23689if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
23690  cat >>confdefs.h <<_ACEOF
23691#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
23692_ACEOF
23693
23694fi
23695done
23696
23697
23698    case "$host" in
23699     *-freebsd5.[012]|*-freebsd5.[012].*)
23700	;;
23701     *-freebsd5.[3456789]|*-freebsd5.[3456789].*|*-freebsd6.*)
23702
23703$as_echo "#define NEED_PTHREAD_SCOPE_SYSTEM 1" >>confdefs.h
23704
23705	;;
23706     *-bsdi3.*|*-bsdi4.0*)
23707
23708$as_echo "#define NEED_PTHREAD_INIT 1" >>confdefs.h
23709
23710	;;
23711     *-linux*)
23712
23713$as_echo "#define HAVE_LINUXTHREADS 1" >>confdefs.h
23714
23715	;;
23716     *-solaris*)
23717	$as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
23718
23719	for ac_func in pthread_setconcurrency
23720do :
23721  ac_fn_c_check_func "$LINENO" "pthread_setconcurrency" "ac_cv_func_pthread_setconcurrency"
23722if test "x$ac_cv_func_pthread_setconcurrency" = xyes; then :
23723  cat >>confdefs.h <<_ACEOF
23724#define HAVE_PTHREAD_SETCONCURRENCY 1
23725_ACEOF
23726
23727fi
23728done
23729
23730	case "$ac_cv_func_pthread_setconcurrency" in
23731	 yes)
23732
23733$as_echo "#define CALL_PTHREAD_SETCONCURRENCY 1" >>confdefs.h
23734
23735	esac
23736	;;
23737     *-sco-sysv*uw*|*-*-sysv*UnixWare*|*-*-sysv*OpenUNIX*)
23738
23739$as_echo "#define HAVE_UNIXWARE_SIGWAIT 1" >>confdefs.h
23740
23741	;;
23742    esac
23743    hack_shutup_pthreadonceinit=no
23744    case "$host" in
23745     *-aix5.[123].*)
23746	hack_shutup_pthreadonceinit=yes
23747	;;
23748     *-solaris2.[89])
23749	hack_shutup_pthreadonceinit=yes
23750	;;
23751     *-solaris2.1[0-9])
23752	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if extra braces are needed for PTHREAD_ONCE_INIT" >&5
23753$as_echo_n "checking if extra braces are needed for PTHREAD_ONCE_INIT... " >&6; }
23754if ${ntp_cv_braces_around_pthread_once_init+:} false; then :
23755  $as_echo_n "(cached) " >&6
23756else
23757  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23758/* end confdefs.h.  */
23759
23760			#include <pthread.h>
23761
23762int
23763main ()
23764{
23765
23766		        static pthread_once_t once_test =
23767						PTHREAD_ONCE_INIT;
23768
23769
23770  ;
23771  return 0;
23772}
23773_ACEOF
23774if ac_fn_c_try_compile "$LINENO"; then :
23775  ntp_cv_braces_around_pthread_once_init=no
23776else
23777  ntp_cv_braces_around_pthread_once_init=yes
23778
23779fi
23780rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23781
23782fi
23783{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_braces_around_pthread_once_init" >&5
23784$as_echo "$ntp_cv_braces_around_pthread_once_init" >&6; }
23785	case "$ntp_cv_braces_around_pthread_once_init" in
23786	 yes)
23787	    hack_shutup_pthreadonceinit=yes
23788	esac
23789	;;
23790    esac
23791    case "$hack_shutup_pthreadonceinit" in
23792     yes)
23793
23794$as_echo "#define ISC_PLATFORM_BRACEPTHREADONCEINIT 1" >>confdefs.h
23795
23796    esac
23797    LIBS="$saved_LIBS"
23798    { saved_LIBS=; unset saved_LIBS;}
23799    CFLAGS="$saved_CFLAGS"
23800    { saved_CFLAGS=; unset saved_CFLAGS;}
23801    ;;
23802 *)
23803    LIBISC_PTHREADS_NOTHREADS=nothreads
23804    ;;
23805esac
23806
23807 if test "$have_pthreads" != "no"; then
23808  PTHREADS_TRUE=
23809  PTHREADS_FALSE='#'
23810else
23811  PTHREADS_TRUE='#'
23812  PTHREADS_FALSE=
23813fi
23814
23815
23816
23817
23818
23819
23820
23821case "$hw_use_rpl_vsnprintf:$hw_cv_func_vsnprintf" in
23822 no:yes)
23823    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if vsnprintf expands \"%m\" to strerror(errno)" >&5
23824$as_echo_n "checking if vsnprintf expands \"%m\" to strerror(errno)... " >&6; }
23825if ${ntp_cv_vsnprintf_percent_m+:} false; then :
23826  $as_echo_n "(cached) " >&6
23827else
23828  if test "$cross_compiling" = yes; then :
23829  ntp_cv_vsnprintf_percent_m=no
23830
23831else
23832  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23833/* end confdefs.h.  */
23834
23835		    #include <stdarg.h>
23836		    #include <errno.h>
23837		    #include <stdio.h>
23838		    #include <string.h>
23839
23840		    int call_vsnprintf(
23841			    char *	dst,
23842			    size_t	sz,
23843			    const char *fmt,
23844			    ...
23845			    );
23846
23847		    int call_vsnprintf(
23848			    char *	dst,
23849			    size_t	sz,
23850			    const char *fmt,
23851			    ...
23852			    )
23853		    {
23854			    va_list	ap;
23855			    int		rc;
23856
23857			    va_start(ap, fmt);
23858			    rc = vsnprintf(dst, sz, fmt, ap);
23859			    va_end(ap);
23860
23861			    return rc;
23862		    }
23863
23864int
23865main ()
23866{
23867
23868		    char	sbuf[512];
23869		    char	pbuf[512];
23870		    int		slen;
23871
23872		    strcpy(sbuf, strerror(ENOENT));
23873		    errno = ENOENT;
23874		    slen = call_vsnprintf(pbuf, sizeof(pbuf), "%m",
23875					  "wrong");
23876		    return strcmp(sbuf, pbuf);
23877
23878
23879  ;
23880  return 0;
23881}
23882_ACEOF
23883if ac_fn_c_try_run "$LINENO"; then :
23884  ntp_cv_vsnprintf_percent_m=yes
23885else
23886  ntp_cv_vsnprintf_percent_m=no
23887fi
23888rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23889  conftest.$ac_objext conftest.beam conftest.$ac_ext
23890fi
23891
23892
23893fi
23894{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_vsnprintf_percent_m" >&5
23895$as_echo "$ntp_cv_vsnprintf_percent_m" >&6; }
23896    case "$ntp_cv_vsnprintf_percent_m" in
23897     yes)
23898
23899$as_echo "#define VSNPRINTF_PERCENT_M 1" >>confdefs.h
23900
23901    esac
23902esac
23903
23904for ac_header in sys/clockctl.h
23905do :
23906  ac_fn_c_check_header_mongrel "$LINENO" "sys/clockctl.h" "ac_cv_header_sys_clockctl_h" "$ac_includes_default"
23907if test "x$ac_cv_header_sys_clockctl_h" = xyes; then :
23908  cat >>confdefs.h <<_ACEOF
23909#define HAVE_SYS_CLOCKCTL_H 1
23910_ACEOF
23911
23912fi
23913
23914done
23915
23916
23917# Check whether --enable-clockctl was given.
23918if test "${enable_clockctl+set}" = set; then :
23919  enableval=$enable_clockctl; ntp_use_dev_clockctl=$enableval
23920else
23921  ntp_use_dev_clockctl=$ac_cv_header_sys_clockctl_h
23922
23923fi
23924
23925
23926{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should use /dev/clockctl" >&5
23927$as_echo_n "checking if we should use /dev/clockctl... " >&6; }
23928{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_use_dev_clockctl" >&5
23929$as_echo "$ntp_use_dev_clockctl" >&6; }
23930
23931
23932for ac_header in sys/capability.h sys/prctl.h
23933do :
23934  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
23935ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
23936if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
23937  cat >>confdefs.h <<_ACEOF
23938#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
23939_ACEOF
23940
23941fi
23942
23943done
23944
23945
23946{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we have linux capabilities (libcap)" >&5
23947$as_echo_n "checking if we have linux capabilities (libcap)... " >&6; }
23948
23949case "$ac_cv_header_sys_capability_h$ac_cv_header_sys_prctl_h" in
23950 yesyes)
23951    case "$host" in
23952     mips-sgi-irix*)
23953	ntp_have_linuxcaps=no
23954	;;
23955     *) ntp_have_linuxcaps=yes
23956	;;
23957    esac
23958    ;;
23959 *)
23960    ntp_have_linuxcaps=no
23961    ;;
23962esac
23963
23964# Check whether --enable-linuxcaps was given.
23965if test "${enable_linuxcaps+set}" = set; then :
23966  enableval=$enable_linuxcaps; ntp_have_linuxcaps=$enableval
23967
23968fi
23969
23970
23971{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_have_linuxcaps" >&5
23972$as_echo "$ntp_have_linuxcaps" >&6; }
23973
23974case "$ntp_have_linuxcaps" in
23975 yes)
23976
23977$as_echo "#define HAVE_LINUX_CAPABILITIES 1" >>confdefs.h
23978
23979    LIBS="$LIBS -lcap"
23980    ;;
23981esac
23982
23983
23984for ac_header in priv.h
23985do :
23986  ac_fn_c_check_header_mongrel "$LINENO" "priv.h" "ac_cv_header_priv_h" "$ac_includes_default"
23987if test "x$ac_cv_header_priv_h" = xyes; then :
23988  cat >>confdefs.h <<_ACEOF
23989#define HAVE_PRIV_H 1
23990_ACEOF
23991
23992fi
23993
23994done
23995
23996case "$ac_cv_header_priv_h" in
23997 yes)
23998    case "$host" in
23999     *-solaris*)
24000	ac_fn_c_check_func "$LINENO" "setppriv" "ac_cv_func_setppriv"
24001if test "x$ac_cv_func_setppriv" = xyes; then :
24002  ntp_have_solarisprivs=yes
24003else
24004  ntp_have_solarisprivs=no
24005
24006fi
24007
24008	;;
24009    esac
24010esac
24011
24012# Check whether --enable-solarisprivs was given.
24013if test "${enable_solarisprivs+set}" = set; then :
24014  enableval=$enable_solarisprivs; ntp_have_solarisprivs=$enableval
24015
24016fi
24017
24018
24019{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we have solaris privileges" >&5
24020$as_echo_n "checking if we have solaris privileges... " >&6; }
24021
24022case "$ntp_have_solarisprivs" in
24023 yes)
24024
24025$as_echo "#define HAVE_SOLARIS_PRIVS 1" >>confdefs.h
24026
24027esac
24028
24029{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_have_solarisprivs" >&5
24030$as_echo "$ntp_have_solarisprivs" >&6; }
24031
24032for ac_header in sys/mac.h
24033do :
24034  ac_fn_c_check_header_mongrel "$LINENO" "sys/mac.h" "ac_cv_header_sys_mac_h" "$ac_includes_default"
24035if test "x$ac_cv_header_sys_mac_h" = xyes; then :
24036  cat >>confdefs.h <<_ACEOF
24037#define HAVE_SYS_MAC_H 1
24038_ACEOF
24039
24040fi
24041
24042done
24043
24044
24045# Check whether --enable-trustedbsd_mac was given.
24046if test "${enable_trustedbsd_mac+set}" = set; then :
24047  enableval=$enable_trustedbsd_mac; ntp_use_trustedbsd_mac=$enableval
24048
24049fi
24050
24051
24052{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should use TrustedBSD MAC privileges" >&5
24053$as_echo_n "checking if we should use TrustedBSD MAC privileges... " >&6; }
24054
24055case "$ntp_use_trustedbsd_mac$ac_cv_header_sys_mac_h" in
24056 yesyes)
24057
24058$as_echo "#define HAVE_TRUSTEDBSD_MAC 1" >>confdefs.h
24059
24060esac
24061
24062{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_use_trustedbsd_mac" >&5
24063$as_echo "$ntp_use_trustedbsd_mac" >&6; }
24064
24065case "$ntp_use_dev_clockctl$ntp_have_linuxcaps$ntp_have_solarisprivs$ntp_use_trustedbsd_mac" in
24066 *yes*)
24067
24068$as_echo "#define HAVE_DROPROOT 1" >>confdefs.h
24069
24070esac
24071
24072case "$host" in
24073 *-*-darwin*)
24074    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing res_9_init" >&5
24075$as_echo_n "checking for library containing res_9_init... " >&6; }
24076if ${ac_cv_search_res_9_init+:} false; then :
24077  $as_echo_n "(cached) " >&6
24078else
24079  ac_func_search_save_LIBS=$LIBS
24080cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24081/* end confdefs.h.  */
24082
24083/* Override any GCC internal prototype to avoid an error.
24084   Use char because int might match the return type of a GCC
24085   builtin and then its argument prototype would still apply.  */
24086#ifdef __cplusplus
24087extern "C"
24088#endif
24089char res_9_init ();
24090int
24091main ()
24092{
24093return res_9_init ();
24094  ;
24095  return 0;
24096}
24097_ACEOF
24098for ac_lib in '' resolv; do
24099  if test -z "$ac_lib"; then
24100    ac_res="none required"
24101  else
24102    ac_res=-l$ac_lib
24103    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
24104  fi
24105  if ac_fn_c_try_link "$LINENO"; then :
24106  ac_cv_search_res_9_init=$ac_res
24107fi
24108rm -f core conftest.err conftest.$ac_objext \
24109    conftest$ac_exeext
24110  if ${ac_cv_search_res_9_init+:} false; then :
24111  break
24112fi
24113done
24114if ${ac_cv_search_res_9_init+:} false; then :
24115
24116else
24117  ac_cv_search_res_9_init=no
24118fi
24119rm conftest.$ac_ext
24120LIBS=$ac_func_search_save_LIBS
24121fi
24122{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_res_9_init" >&5
24123$as_echo "$ac_cv_search_res_9_init" >&6; }
24124ac_res=$ac_cv_search_res_9_init
24125if test "$ac_res" != no; then :
24126  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
24127
24128fi
24129
24130    ;;
24131 *) { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing res_init" >&5
24132$as_echo_n "checking for library containing res_init... " >&6; }
24133if ${ac_cv_search_res_init+:} false; then :
24134  $as_echo_n "(cached) " >&6
24135else
24136  ac_func_search_save_LIBS=$LIBS
24137cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24138/* end confdefs.h.  */
24139
24140/* Override any GCC internal prototype to avoid an error.
24141   Use char because int might match the return type of a GCC
24142   builtin and then its argument prototype would still apply.  */
24143#ifdef __cplusplus
24144extern "C"
24145#endif
24146char res_init ();
24147int
24148main ()
24149{
24150return res_init ();
24151  ;
24152  return 0;
24153}
24154_ACEOF
24155for ac_lib in '' resolv; do
24156  if test -z "$ac_lib"; then
24157    ac_res="none required"
24158  else
24159    ac_res=-l$ac_lib
24160    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
24161  fi
24162  if ac_fn_c_try_link "$LINENO"; then :
24163  ac_cv_search_res_init=$ac_res
24164fi
24165rm -f core conftest.err conftest.$ac_objext \
24166    conftest$ac_exeext
24167  if ${ac_cv_search_res_init+:} false; then :
24168  break
24169fi
24170done
24171if ${ac_cv_search_res_init+:} false; then :
24172
24173else
24174  ac_cv_search_res_init=no
24175fi
24176rm conftest.$ac_ext
24177LIBS=$ac_func_search_save_LIBS
24178fi
24179{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_res_init" >&5
24180$as_echo "$ac_cv_search_res_init" >&6; }
24181ac_res=$ac_cv_search_res_init
24182if test "$ac_res" != no; then :
24183  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
24184
24185fi
24186
24187    ;;
24188esac
24189for ac_header in sys/types.h netinet/in.h arpa/nameser.h netdb.h resolv.h
24190do :
24191  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
24192ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "#ifdef HAVE_SYS_TYPES_H
24193#  include <sys/types.h>
24194#endif
24195#ifdef HAVE_NETINET_IN_H
24196#  include <netinet/in.h>   /* inet_ functions / structs */
24197#endif
24198#ifdef HAVE_ARPA_NAMESER_H
24199#  include <arpa/nameser.h> /* DNS HEADER struct */
24200#endif
24201#ifdef HAVE_NETDB_H
24202#  include <netdb.h>
24203#endif
24204"
24205if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
24206  cat >>confdefs.h <<_ACEOF
24207#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
24208_ACEOF
24209
24210fi
24211
24212done
24213
24214
24215#HMS: Why do we do this check so "early"?
24216for ac_func in res_init
24217do :
24218  ac_fn_c_check_func "$LINENO" "res_init" "ac_cv_func_res_init"
24219if test "x$ac_cv_func_res_init" = xyes; then :
24220  cat >>confdefs.h <<_ACEOF
24221#define HAVE_RES_INIT 1
24222_ACEOF
24223
24224else
24225  for ac_func in __res_init
24226do :
24227  ac_fn_c_check_func "$LINENO" "__res_init" "ac_cv_func___res_init"
24228if test "x$ac_cv_func___res_init" = xyes; then :
24229  cat >>confdefs.h <<_ACEOF
24230#define HAVE___RES_INIT 1
24231_ACEOF
24232
24233fi
24234done
24235
24236fi
24237done
24238
24239
24240# We also need -lsocket, but we have tested for that already.
24241ac_fn_c_check_func "$LINENO" "inet_ntop" "ac_cv_func_inet_ntop"
24242if test "x$ac_cv_func_inet_ntop" = xyes; then :
24243
24244else
24245
24246$as_echo "#define ISC_PLATFORM_NEEDNTOP 1" >>confdefs.h
24247
24248fi
24249
24250ac_fn_c_check_func "$LINENO" "inet_pton" "ac_cv_func_inet_pton"
24251if test "x$ac_cv_func_inet_pton" = xyes; then :
24252
24253else
24254
24255$as_echo "#define ISC_PLATFORM_NEEDPTON 1" >>confdefs.h
24256
24257fi
24258
24259
24260ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default"
24261if test "x$ac_cv_type_uintptr_t" = xyes; then :
24262
24263cat >>confdefs.h <<_ACEOF
24264#define HAVE_UINTPTR_T 1
24265_ACEOF
24266
24267
24268fi
24269ac_fn_c_check_type "$LINENO" "int32" "ac_cv_type_int32" "$ac_includes_default"
24270if test "x$ac_cv_type_int32" = xyes; then :
24271
24272cat >>confdefs.h <<_ACEOF
24273#define HAVE_INT32 1
24274_ACEOF
24275
24276
24277fi
24278ac_fn_c_check_type "$LINENO" "u_int32" "ac_cv_type_u_int32" "$ac_includes_default"
24279if test "x$ac_cv_type_u_int32" = xyes; then :
24280
24281cat >>confdefs.h <<_ACEOF
24282#define HAVE_U_INT32 1
24283_ACEOF
24284
24285
24286fi
24287
24288
24289
24290
24291case "$ac_cv_type_int32::$ac_cv_header_resolv_h" in
24292 no::yes)
24293    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for int32 with DNS headers included" >&5
24294$as_echo_n "checking for int32 with DNS headers included... " >&6; }
24295if ${ntp_cv_type_int32_with_dns+:} false; then :
24296  $as_echo_n "(cached) " >&6
24297else
24298  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24299/* end confdefs.h.  */
24300
24301		    #ifdef HAVE_ARPA_NAMESER_H
24302		    # include <arpa/nameser.h>
24303		    #endif
24304		    #include <resolv.h>
24305
24306int
24307main ()
24308{
24309
24310		    size_t cb = sizeof(int32);
24311
24312
24313  ;
24314  return 0;
24315}
24316_ACEOF
24317if ac_fn_c_try_compile "$LINENO"; then :
24318  ntp_cv_type_int32_with_dns=yes
24319else
24320  ntp_cv_type_int32_with_dns=no
24321
24322fi
24323rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24324
24325fi
24326{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_type_int32_with_dns" >&5
24327$as_echo "$ntp_cv_type_int32_with_dns" >&6; }
24328    case "$ntp_cv_type_int32_with_dns" in
24329     yes)
24330
24331$as_echo "#define HAVE_INT32_ONLY_WITH_DNS 1" >>confdefs.h
24332
24333    esac
24334esac
24335
24336case "$ac_cv_type_u_int32::$ac_cv_header_resolv_h" in
24337 no::yes)
24338    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for u_int32 with DNS headers included" >&5
24339$as_echo_n "checking for u_int32 with DNS headers included... " >&6; }
24340if ${ntp_cv_type_u_int32_with_dns+:} false; then :
24341  $as_echo_n "(cached) " >&6
24342else
24343  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24344/* end confdefs.h.  */
24345
24346		    #ifdef HAVE_ARPA_NAMESER_H
24347		    # include <arpa/nameser.h>
24348		    #endif
24349		    #include <resolv.h>
24350
24351int
24352main ()
24353{
24354
24355		    size_t cb = sizeof(u_int32);
24356
24357
24358  ;
24359  return 0;
24360}
24361_ACEOF
24362if ac_fn_c_try_compile "$LINENO"; then :
24363  ntp_cv_type_u_int32_with_dns=yes
24364else
24365  ntp_cv_type_u_int32_with_dns=no
24366
24367fi
24368rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24369
24370fi
24371{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_type_u_int32_with_dns" >&5
24372$as_echo "$ntp_cv_type_u_int32_with_dns" >&6; }
24373    case "$ntp_cv_type_u_int32_with_dns" in
24374     yes)
24375
24376$as_echo "#define HAVE_U_INT32_ONLY_WITH_DNS 1" >>confdefs.h
24377
24378    esac
24379esac
24380
24381for ac_header in sys/timepps.h
24382do :
24383  ac_fn_c_check_header_compile "$LINENO" "sys/timepps.h" "ac_cv_header_sys_timepps_h" "
24384	#ifdef HAVE_SYS_TIME_H
24385	# include <sys/time.h>
24386	#endif
24387	#ifdef HAVE_ERRNO_H
24388	# include <errno.h>
24389	#endif
24390
24391
24392"
24393if test "x$ac_cv_header_sys_timepps_h" = xyes; then :
24394  cat >>confdefs.h <<_ACEOF
24395#define HAVE_SYS_TIMEPPS_H 1
24396_ACEOF
24397
24398fi
24399
24400done
24401
24402
24403{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec" >&5
24404$as_echo_n "checking for struct timespec... " >&6; }
24405if ${ntp_cv_struct_timespec+:} false; then :
24406  $as_echo_n "(cached) " >&6
24407else
24408  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24409/* end confdefs.h.  */
24410
24411		#include <sys/time.h>
24412		/* Under SunOS, timespec is in sys/timepps.h,
24413		   which needs errno.h and FRAC */
24414		#ifdef HAVE_ERRNO_H
24415		# include <errno.h>
24416		#endif
24417		#ifdef HAVE_SYS_TIMEPPS_H
24418		# define FRAC 4294967296
24419		# include <sys/timepps.h>
24420		#endif
24421
24422int
24423main ()
24424{
24425
24426		struct timespec n;
24427
24428
24429  ;
24430  return 0;
24431}
24432_ACEOF
24433if ac_fn_c_try_compile "$LINENO"; then :
24434  ntp_cv_struct_timespec=yes
24435else
24436  ntp_cv_struct_timespec=no
24437
24438fi
24439rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24440
24441fi
24442{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_struct_timespec" >&5
24443$as_echo "$ntp_cv_struct_timespec" >&6; }
24444case "$ntp_cv_struct_timespec" in
24445 yes)
24446
24447$as_echo "#define HAVE_STRUCT_TIMESPEC 1" >>confdefs.h
24448
24449esac
24450
24451{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct ntptimeval" >&5
24452$as_echo_n "checking for struct ntptimeval... " >&6; }
24453if ${ntp_cv_struct_ntptimeval+:} false; then :
24454  $as_echo_n "(cached) " >&6
24455else
24456  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24457/* end confdefs.h.  */
24458
24459		#include <sys/time.h>
24460		#include <sys/timex.h>
24461
24462int
24463main ()
24464{
24465
24466		struct ntptimeval n;
24467
24468
24469  ;
24470  return 0;
24471}
24472_ACEOF
24473if ac_fn_c_try_compile "$LINENO"; then :
24474  ntp_cv_struct_ntptimeval=yes
24475else
24476  ntp_cv_struct_ntptimeval=no
24477
24478fi
24479rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24480
24481fi
24482{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_struct_ntptimeval" >&5
24483$as_echo "$ntp_cv_struct_ntptimeval" >&6; }
24484case "$ntp_cv_struct_ntptimeval" in
24485 yes)
24486
24487$as_echo "#define HAVE_STRUCT_NTPTIMEVAL 1" >>confdefs.h
24488
24489esac
24490
24491for ac_header in md5.h
24492do :
24493  ac_fn_c_check_header_compile "$LINENO" "md5.h" "ac_cv_header_md5_h" "
24494	#ifdef HAVE_SYS_TYPES_H
24495	# include <sys/types.h>
24496	#endif
24497
24498
24499"
24500if test "x$ac_cv_header_md5_h" = xyes; then :
24501  cat >>confdefs.h <<_ACEOF
24502#define HAVE_MD5_H 1
24503_ACEOF
24504
24505fi
24506
24507done
24508
24509
24510{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing MD5Init" >&5
24511$as_echo_n "checking for library containing MD5Init... " >&6; }
24512if ${ac_cv_search_MD5Init+:} false; then :
24513  $as_echo_n "(cached) " >&6
24514else
24515  ac_func_search_save_LIBS=$LIBS
24516cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24517/* end confdefs.h.  */
24518
24519/* Override any GCC internal prototype to avoid an error.
24520   Use char because int might match the return type of a GCC
24521   builtin and then its argument prototype would still apply.  */
24522#ifdef __cplusplus
24523extern "C"
24524#endif
24525char MD5Init ();
24526int
24527main ()
24528{
24529return MD5Init ();
24530  ;
24531  return 0;
24532}
24533_ACEOF
24534for ac_lib in '' md5 md; do
24535  if test -z "$ac_lib"; then
24536    ac_res="none required"
24537  else
24538    ac_res=-l$ac_lib
24539    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
24540  fi
24541  if ac_fn_c_try_link "$LINENO"; then :
24542  ac_cv_search_MD5Init=$ac_res
24543fi
24544rm -f core conftest.err conftest.$ac_objext \
24545    conftest$ac_exeext
24546  if ${ac_cv_search_MD5Init+:} false; then :
24547  break
24548fi
24549done
24550if ${ac_cv_search_MD5Init+:} false; then :
24551
24552else
24553  ac_cv_search_MD5Init=no
24554fi
24555rm conftest.$ac_ext
24556LIBS=$ac_func_search_save_LIBS
24557fi
24558{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_MD5Init" >&5
24559$as_echo "$ac_cv_search_MD5Init" >&6; }
24560ac_res=$ac_cv_search_MD5Init
24561if test "$ac_res" != no; then :
24562  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
24563
24564fi
24565
24566for ac_func in MD5Init sysconf getdtablesize sigaction sigset sigvec
24567do :
24568  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
24569ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
24570if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
24571  cat >>confdefs.h <<_ACEOF
24572#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
24573_ACEOF
24574
24575fi
24576done
24577
24578
24579{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for SIGIO" >&5
24580$as_echo_n "checking for SIGIO... " >&6; }
24581if ${ntp_cv_hdr_def_sigio+:} false; then :
24582  $as_echo_n "(cached) " >&6
24583else
24584  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24585/* end confdefs.h.  */
24586
24587	    #include <signal.h>
24588
24589	    #ifndef SIGIO
24590	    # error
24591	    #endif
24592
24593_ACEOF
24594if ac_fn_c_try_cpp "$LINENO"; then :
24595  ntp_cv_hdr_def_sigio=yes
24596else
24597  ntp_cv_hdr_def_sigio=no
24598
24599fi
24600rm -f conftest.err conftest.i conftest.$ac_ext
24601
24602fi
24603{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_hdr_def_sigio" >&5
24604$as_echo "$ntp_cv_hdr_def_sigio" >&6; }
24605
24606{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want to use SIGIO" >&5
24607$as_echo_n "checking if we want to use SIGIO... " >&6; }
24608ans=no
24609case "$ntp_cv_hdr_def_sigio" in
24610 yes)
24611    ans=yes
24612    case "$host" in
24613     alpha*-dec-osf4*|alpha*-dec-osf5*)
24614	ans=no
24615	;;
24616     *-convex-*)
24617	ans=no
24618	;;
24619     *-dec-*)
24620	ans=no
24621	;;
24622     *-pc-cygwin*)
24623	ans=no
24624	;;
24625     *-sni-sysv*)
24626	ans=no
24627	;;
24628     *-stratus-vos)
24629	ans=no
24630	;;
24631     *-univel-sysv*)
24632	ans=no
24633	;;
24634     *-*-irix6*)
24635	ans=no
24636	;;
24637     *-*-freebsd*)
24638	ans=no
24639	;;
24640     *-*-*linux*)
24641	ans=no
24642	;;
24643     *-*-unicosmp*)
24644	ans=no
24645	;;
24646     *-*-kfreebsd*)
24647	ans=no
24648	;;
24649     m68k-*-mint*)
24650	ans=no
24651	;;
24652    esac
24653    ;;
24654esac
24655case "$ans" in
24656 yes)
24657
24658$as_echo "#define HAVE_SIGNALED_IO 1" >>confdefs.h
24659
24660esac
24661{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
24662$as_echo "$ans" >&6; }
24663
24664{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for SIGPOLL" >&5
24665$as_echo_n "checking for SIGPOLL... " >&6; }
24666if ${ntp_cv_hdr_def_sigpoll+:} false; then :
24667  $as_echo_n "(cached) " >&6
24668else
24669  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24670/* end confdefs.h.  */
24671
24672	    #include <signal.h>
24673
24674	    #ifndef SIGPOLL
24675	    # error
24676	    #endif
24677
24678_ACEOF
24679if ac_fn_c_try_cpp "$LINENO"; then :
24680  ntp_cv_hdr_def_sigpoll=yes
24681else
24682  ntp_cv_hdr_def_sigpoll=no
24683
24684fi
24685rm -f conftest.err conftest.i conftest.$ac_ext
24686
24687fi
24688{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_hdr_def_sigpoll" >&5
24689$as_echo "$ntp_cv_hdr_def_sigpoll" >&6; }
24690
24691{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can use SIGPOLL for UDP I/O" >&5
24692$as_echo_n "checking if we can use SIGPOLL for UDP I/O... " >&6; }
24693ans=no
24694case "$ntp_cv_hdr_def_sigpoll" in
24695 yes)
24696    case "$host" in
24697     mips-sgi-irix*)
24698	ans=no
24699	;;
24700     vax-dec-bsd)
24701	ans=no
24702	;;
24703     *-pc-cygwin*)
24704	ans=no
24705	;;
24706     *-sni-sysv*)
24707	ans=no
24708	;;
24709     *-stratus-vos)
24710	ans=no
24711	;;
24712     *-*-aix[4-9]*)
24713	# XXX Only verified thru AIX6
24714	ans=no
24715	;;
24716     *-*-hpux*)
24717	ans=no
24718	;;
24719     *-*-*linux*)
24720	ans=no
24721	;;
24722     *-*-osf*)
24723	ans=no
24724	;;
24725     *-*-qnx*)
24726	ans=no
24727	;;
24728     *-*-sunos*)
24729	ans=no
24730	;;
24731     *-*-solaris*)
24732	ans=no
24733	;;
24734     *-*-ultrix*)
24735	ans=no
24736	;;
24737     *-*-unicosmp*)
24738	ans=no
24739	;;
24740     *-*-kfreebsd*)
24741	ans=no
24742	;;
24743     *) ans=yes
24744	;;
24745    esac
24746    ;;
24747esac
24748case "$ans" in
24749 yes)
24750
24751$as_echo "#define USE_UDP_SIGPOLL 1" >>confdefs.h
24752
24753esac
24754{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
24755$as_echo "$ans" >&6; }
24756
24757{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can use SIGPOLL for TTY I/O" >&5
24758$as_echo_n "checking if we can use SIGPOLL for TTY I/O... " >&6; }
24759ans=no
24760case "$ntp_cv_hdr_def_sigpoll" in
24761 yes)
24762    case "$host" in
24763     mips-sgi-irix*)
24764	ans=no
24765	;;
24766     vax-dec-bsd)
24767	ans=no
24768	;;
24769     *-pc-cygwin*)
24770	ans=no
24771	;;
24772     *-sni-sysv*)
24773	ans=no
24774	;;
24775     *-stratus-vos)
24776	ans=no
24777	;;
24778     *-*-aix[4-9]*)
24779	# XXX Only verified thru AIX6
24780	ans=no
24781	;;
24782     *-*-hpux*)
24783	ans=no
24784	;;
24785     *-*-*linux*)
24786	ans=no
24787	;;
24788     *-*-osf*)
24789	ans=no
24790	;;
24791     *-*-sunos*)
24792	ans=no
24793	;;
24794     *-*-ultrix*)
24795	ans=no
24796	;;
24797     *-*-qnx*)
24798	ans=no
24799	;;
24800     *-*-unicosmp*)
24801	ans=no
24802	;;
24803     *-*-kfreebsd*)
24804	ans=no
24805	;;
24806     *) ans=yes
24807	;;
24808    esac
24809    ;;
24810esac
24811case "$ans" in
24812 yes)
24813
24814$as_echo "#define USE_TTY_SIGPOLL 1" >>confdefs.h
24815
24816esac
24817{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
24818$as_echo "$ans" >&6; }
24819
24820{ $as_echo "$as_me:${as_lineno-$LINENO}: checking number of arguments to gettimeofday()" >&5
24821$as_echo_n "checking number of arguments to gettimeofday()... " >&6; }
24822if ${ntp_cv_func_Xettimeofday_nargs+:} false; then :
24823  $as_echo_n "(cached) " >&6
24824else
24825  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24826/* end confdefs.h.  */
24827
24828		#include <sys/time.h>
24829
24830int
24831main ()
24832{
24833
24834		gettimeofday(0, 0);
24835		settimeofday(0, 0);
24836
24837
24838  ;
24839  return 0;
24840}
24841_ACEOF
24842if ac_fn_c_try_compile "$LINENO"; then :
24843  ntp_cv_func_Xettimeofday_nargs=2
24844else
24845  ntp_cv_func_Xettimeofday_nargs=1
24846
24847fi
24848rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24849
24850fi
24851{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_func_Xettimeofday_nargs" >&5
24852$as_echo "$ntp_cv_func_Xettimeofday_nargs" >&6; }
24853case "$ntp_cv_func_Xettimeofday_nargs" in
24854 1)
24855
24856$as_echo "#define SYSV_TIMEOFDAY 1" >>confdefs.h
24857
24858esac
24859
24860for ac_func in settimeofday
24861do :
24862  ac_fn_c_check_func "$LINENO" "settimeofday" "ac_cv_func_settimeofday"
24863if test "x$ac_cv_func_settimeofday" = xyes; then :
24864  cat >>confdefs.h <<_ACEOF
24865#define HAVE_SETTIMEOFDAY 1
24866_ACEOF
24867
24868else
24869
24870    case "$host" in
24871     *-*-mpeix*) ac_cv_func_settimeofday=yes
24872    esac
24873
24874fi
24875done
24876
24877
24878{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we'll use clock_settime or settimeofday or stime" >&5
24879$as_echo_n "checking if we'll use clock_settime or settimeofday or stime... " >&6; }
24880ntp_warning='GRONK'
24881ans=none
24882case "$ac_cv_func_clock_settime$ac_cv_func_settimeofday$ac_cv_func_stime" in
24883 yes*)
24884    ntp_warning=''
24885    ans='clock_settime()'
24886    ;;
24887 noyes*)
24888    ntp_warning='But clock_settime() would be better (if we had it)'
24889    ans='settimeofday()'
24890    ;;
24891 nonoyes)
24892    ntp_warning='Which is the worst of the three'
24893    ans='stime()'
24894    ;;
24895 *)
24896    case "$build" in
24897     $host)
24898	ntp_warning='Which leaves us with nothing to use!'
24899    esac
24900esac
24901{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
24902$as_echo "$ans" >&6; }
24903case "$ntp_warning" in
24904 '')
24905    ;;
24906 *)
24907    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** $ntp_warning ***" >&5
24908$as_echo "$as_me: WARNING: *** $ntp_warning ***" >&2;}
24909    ;;
24910esac
24911
24912
24913LDADD_LIBNTP="$LDADD_LIBNTP $LIBS"
24914LIBS=$__LIBS
24915{ __LIBS=; unset __LIBS;}
24916
24917
24918
24919{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for deprecated --with-arlib" >&5
24920$as_echo_n "checking for deprecated --with-arlib... " >&6; }
24921
24922# Check whether --with-arlib was given.
24923if test "${with_arlib+set}" = set; then :
24924  withval=$with_arlib; ans=$withval
24925else
24926  ans=no
24927fi
24928
24929{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
24930$as_echo "$ans" >&6; }
24931
24932case "$ans" in
24933 yes)
24934    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Please do not use --with-arlib, arlib is no longer included.  In the future, --with-arlib will not be recognized." >&5
24935$as_echo "$as_me: WARNING: Please do not use --with-arlib, arlib is no longer included.  In the future, --with-arlib will not be recognized." >&2;}
24936    ;;
24937esac
24938
24939for ac_prog in gawk mawk nawk awk
24940do
24941  # Extract the first word of "$ac_prog", so it can be a program name with args.
24942set dummy $ac_prog; ac_word=$2
24943{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
24944$as_echo_n "checking for $ac_word... " >&6; }
24945if ${ac_cv_prog_AWK+:} false; then :
24946  $as_echo_n "(cached) " >&6
24947else
24948  if test -n "$AWK"; then
24949  ac_cv_prog_AWK="$AWK" # Let the user override the test.
24950else
24951as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24952for as_dir in $PATH
24953do
24954  IFS=$as_save_IFS
24955  test -z "$as_dir" && as_dir=.
24956    for ac_exec_ext in '' $ac_executable_extensions; do
24957  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
24958    ac_cv_prog_AWK="$ac_prog"
24959    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
24960    break 2
24961  fi
24962done
24963  done
24964IFS=$as_save_IFS
24965
24966fi
24967fi
24968AWK=$ac_cv_prog_AWK
24969if test -n "$AWK"; then
24970  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
24971$as_echo "$AWK" >&6; }
24972else
24973  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24974$as_echo "no" >&6; }
24975fi
24976
24977
24978  test -n "$AWK" && break
24979done
24980
24981{ ac_cv_prog_AWK=; unset ac_cv_prog_AWK;}
24982				{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
24983$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
24984set x ${MAKE-make}
24985ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
24986if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then :
24987  $as_echo_n "(cached) " >&6
24988else
24989  cat >conftest.make <<\_ACEOF
24990SHELL = /bin/sh
24991all:
24992	@echo '@@@%%%=$(MAKE)=@@@%%%'
24993_ACEOF
24994# GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
24995case `${MAKE-make} -f conftest.make 2>/dev/null` in
24996  *@@@%%%=?*=@@@%%%*)
24997    eval ac_cv_prog_make_${ac_make}_set=yes;;
24998  *)
24999    eval ac_cv_prog_make_${ac_make}_set=no;;
25000esac
25001rm -f conftest.make
25002fi
25003if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
25004  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
25005$as_echo "yes" >&6; }
25006  SET_MAKE=
25007else
25008  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25009$as_echo "no" >&6; }
25010  SET_MAKE="MAKE=${MAKE-make}"
25011fi
25012
25013
25014
25015
25016
25017{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
25018$as_echo_n "checking whether ln -s works... " >&6; }
25019LN_S=$as_ln_s
25020if test "$LN_S" = "ln -s"; then
25021  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
25022$as_echo "yes" >&6; }
25023else
25024  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
25025$as_echo "no, using $LN_S" >&6; }
25026fi
25027
25028{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing strerror" >&5
25029$as_echo_n "checking for library containing strerror... " >&6; }
25030if ${ac_cv_search_strerror+:} false; then :
25031  $as_echo_n "(cached) " >&6
25032else
25033  ac_func_search_save_LIBS=$LIBS
25034cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25035/* end confdefs.h.  */
25036
25037/* Override any GCC internal prototype to avoid an error.
25038   Use char because int might match the return type of a GCC
25039   builtin and then its argument prototype would still apply.  */
25040#ifdef __cplusplus
25041extern "C"
25042#endif
25043char strerror ();
25044int
25045main ()
25046{
25047return strerror ();
25048  ;
25049  return 0;
25050}
25051_ACEOF
25052for ac_lib in '' cposix; do
25053  if test -z "$ac_lib"; then
25054    ac_res="none required"
25055  else
25056    ac_res=-l$ac_lib
25057    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
25058  fi
25059  if ac_fn_c_try_link "$LINENO"; then :
25060  ac_cv_search_strerror=$ac_res
25061fi
25062rm -f core conftest.err conftest.$ac_objext \
25063    conftest$ac_exeext
25064  if ${ac_cv_search_strerror+:} false; then :
25065  break
25066fi
25067done
25068if ${ac_cv_search_strerror+:} false; then :
25069
25070else
25071  ac_cv_search_strerror=no
25072fi
25073rm conftest.$ac_ext
25074LIBS=$ac_func_search_save_LIBS
25075fi
25076{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_strerror" >&5
25077$as_echo "$ac_cv_search_strerror" >&6; }
25078ac_res=$ac_cv_search_strerror
25079if test "$ac_res" != no; then :
25080  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
25081
25082fi
25083
25084
25085
25086# Extract the first word of "perl", so it can be a program name with args.
25087set dummy perl; ac_word=$2
25088{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25089$as_echo_n "checking for $ac_word... " >&6; }
25090if ${ac_cv_path_PATH_PERL+:} false; then :
25091  $as_echo_n "(cached) " >&6
25092else
25093  case $PATH_PERL in
25094  [\\/]* | ?:[\\/]*)
25095  ac_cv_path_PATH_PERL="$PATH_PERL" # Let the user override the test with a path.
25096  ;;
25097  *)
25098  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25099for as_dir in $PATH
25100do
25101  IFS=$as_save_IFS
25102  test -z "$as_dir" && as_dir=.
25103    for ac_exec_ext in '' $ac_executable_extensions; do
25104  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25105    ac_cv_path_PATH_PERL="$as_dir/$ac_word$ac_exec_ext"
25106    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25107    break 2
25108  fi
25109done
25110  done
25111IFS=$as_save_IFS
25112
25113  ;;
25114esac
25115fi
25116PATH_PERL=$ac_cv_path_PATH_PERL
25117if test -n "$PATH_PERL"; then
25118  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATH_PERL" >&5
25119$as_echo "$PATH_PERL" >&6; }
25120else
25121  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25122$as_echo "no" >&6; }
25123fi
25124
25125
25126{ ac_cv_path_PATH_PERL=; unset ac_cv_path_PATH_PERL;}
25127# Extract the first word of "test", so it can be a program name with args.
25128set dummy test; ac_word=$2
25129{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25130$as_echo_n "checking for $ac_word... " >&6; }
25131if ${ac_cv_path_PATH_TEST+:} false; then :
25132  $as_echo_n "(cached) " >&6
25133else
25134  case $PATH_TEST in
25135  [\\/]* | ?:[\\/]*)
25136  ac_cv_path_PATH_TEST="$PATH_TEST" # Let the user override the test with a path.
25137  ;;
25138  *)
25139  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25140for as_dir in $PATH
25141do
25142  IFS=$as_save_IFS
25143  test -z "$as_dir" && as_dir=.
25144    for ac_exec_ext in '' $ac_executable_extensions; do
25145  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25146    ac_cv_path_PATH_TEST="$as_dir/$ac_word$ac_exec_ext"
25147    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25148    break 2
25149  fi
25150done
25151  done
25152IFS=$as_save_IFS
25153
25154  ;;
25155esac
25156fi
25157PATH_TEST=$ac_cv_path_PATH_TEST
25158if test -n "$PATH_TEST"; then
25159  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATH_TEST" >&5
25160$as_echo "$PATH_TEST" >&6; }
25161else
25162  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25163$as_echo "no" >&6; }
25164fi
25165
25166
25167{ ac_cv_path_PATH_TEST=; unset ac_cv_path_PATH_TEST;}
25168test -z "$CONFIG_SHELL" && CONFIG_SHELL=/bin/sh
25169
25170
25171# Check whether --with-net-snmp-config was given.
25172if test "${with_net_snmp_config+set}" = set; then :
25173  withval=$with_net_snmp_config; ans=$withval
25174else
25175  ans=yes
25176
25177fi
25178
25179case "$ans" in
25180 no)
25181    ;;
25182 yes)
25183    ans=net-snmp-config
25184    ;;
25185 /*)
25186    ;;
25187 */*)
25188    as_fn_error $? "--with-net-snmp-config takes either a name or an absolute path" "$LINENO" 5
25189    ;;
25190 *)
25191    ;;
25192esac
25193PROG_NET_SNMP_CONFIG=$ans
25194case "$PROG_NET_SNMP_CONFIG" in
25195 no) ;;
25196 /*)
25197    PATH_NET_SNMP_CONFIG=$PROG_NET_SNMP_CONFIG
25198    ;;
25199 *)
25200    # Extract the first word of "$PROG_NET_SNMP_CONFIG", so it can be a program name with args.
25201set dummy $PROG_NET_SNMP_CONFIG; ac_word=$2
25202{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25203$as_echo_n "checking for $ac_word... " >&6; }
25204if ${ac_cv_path_PATH_NET_SNMP_CONFIG+:} false; then :
25205  $as_echo_n "(cached) " >&6
25206else
25207  case $PATH_NET_SNMP_CONFIG in
25208  [\\/]* | ?:[\\/]*)
25209  ac_cv_path_PATH_NET_SNMP_CONFIG="$PATH_NET_SNMP_CONFIG" # Let the user override the test with a path.
25210  ;;
25211  *)
25212  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25213for as_dir in $PATH
25214do
25215  IFS=$as_save_IFS
25216  test -z "$as_dir" && as_dir=.
25217    for ac_exec_ext in '' $ac_executable_extensions; do
25218  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25219    ac_cv_path_PATH_NET_SNMP_CONFIG="$as_dir/$ac_word$ac_exec_ext"
25220    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25221    break 2
25222  fi
25223done
25224  done
25225IFS=$as_save_IFS
25226
25227  ;;
25228esac
25229fi
25230PATH_NET_SNMP_CONFIG=$ac_cv_path_PATH_NET_SNMP_CONFIG
25231if test -n "$PATH_NET_SNMP_CONFIG"; then
25232  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATH_NET_SNMP_CONFIG" >&5
25233$as_echo "$PATH_NET_SNMP_CONFIG" >&6; }
25234else
25235  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25236$as_echo "no" >&6; }
25237fi
25238
25239
25240    { ac_cv_path_PATH_NET_SNMP_CONFIG=; unset ac_cv_path_PATH_NET_SNMP_CONFIG;}
25241;;
25242esac
25243{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for net-snmp-config path" >&5
25244$as_echo_n "checking for net-snmp-config path... " >&6; }
25245{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATH_NET_SNMP_CONFIG" >&5
25246$as_echo "$PATH_NET_SNMP_CONFIG" >&6; }
25247
25248case "$PATH_NET_SNMP_CONFIG" in
25249 /*)	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for net-snmp version" >&5
25250$as_echo_n "checking for net-snmp version... " >&6; }
25251if ${ntp_cv_net_snmp_version+:} false; then :
25252  $as_echo_n "(cached) " >&6
25253else
25254  ntp_cv_net_snmp_version=`$PATH_NET_SNMP_CONFIG --version`
25255
25256fi
25257{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_net_snmp_version" >&5
25258$as_echo "$ntp_cv_net_snmp_version" >&6; }
25259	;;
25260esac
25261
25262case "$host" in
25263 *-*-vxworks*)
25264    ac_link="$ac_link $VX_KERNEL"
25265    ;;
25266esac
25267
25268# HMS: a check for -lnsl used to be here - now being done in NTP_LIBNTP
25269{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing openlog" >&5
25270$as_echo_n "checking for library containing openlog... " >&6; }
25271if ${ac_cv_search_openlog+:} false; then :
25272  $as_echo_n "(cached) " >&6
25273else
25274  ac_func_search_save_LIBS=$LIBS
25275cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25276/* end confdefs.h.  */
25277
25278/* Override any GCC internal prototype to avoid an error.
25279   Use char because int might match the return type of a GCC
25280   builtin and then its argument prototype would still apply.  */
25281#ifdef __cplusplus
25282extern "C"
25283#endif
25284char openlog ();
25285int
25286main ()
25287{
25288return openlog ();
25289  ;
25290  return 0;
25291}
25292_ACEOF
25293for ac_lib in '' gen syslog; do
25294  if test -z "$ac_lib"; then
25295    ac_res="none required"
25296  else
25297    ac_res=-l$ac_lib
25298    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
25299  fi
25300  if ac_fn_c_try_link "$LINENO"; then :
25301  ac_cv_search_openlog=$ac_res
25302fi
25303rm -f core conftest.err conftest.$ac_objext \
25304    conftest$ac_exeext
25305  if ${ac_cv_search_openlog+:} false; then :
25306  break
25307fi
25308done
25309if ${ac_cv_search_openlog+:} false; then :
25310
25311else
25312  ac_cv_search_openlog=no
25313fi
25314rm conftest.$ac_ext
25315LIBS=$ac_func_search_save_LIBS
25316fi
25317{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_openlog" >&5
25318$as_echo "$ac_cv_search_openlog" >&6; }
25319ac_res=$ac_cv_search_openlog
25320if test "$ac_res" != no; then :
25321  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
25322
25323fi
25324
25325# XXX library list will be in ac_cv_search_openlog
25326
25327# LIBSECCOMP is off by default -- needs testing with all the features
25328# Please send bug reports to loganaden@gmail.com
25329{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want to use libseccomp sandboxing (EXPERIMENTAL)" >&5
25330$as_echo_n "checking if we want to use libseccomp sandboxing (EXPERIMENTAL)... " >&6; }
25331# Check whether --enable-libseccomp was given.
25332if test "${enable_libseccomp+set}" = set; then :
25333  enableval=$enable_libseccomp; ntp_ok=$enableval
25334else
25335  ntp_ok=no
25336
25337fi
25338
25339{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
25340$as_echo "$ntp_ok" >&6; }
25341case "$ntp_ok" in
25342 yes)
25343    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing seccomp_init" >&5
25344$as_echo_n "checking for library containing seccomp_init... " >&6; }
25345if ${ac_cv_search_seccomp_init+:} false; then :
25346  $as_echo_n "(cached) " >&6
25347else
25348  ac_func_search_save_LIBS=$LIBS
25349cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25350/* end confdefs.h.  */
25351
25352/* Override any GCC internal prototype to avoid an error.
25353   Use char because int might match the return type of a GCC
25354   builtin and then its argument prototype would still apply.  */
25355#ifdef __cplusplus
25356extern "C"
25357#endif
25358char seccomp_init ();
25359int
25360main ()
25361{
25362return seccomp_init ();
25363  ;
25364  return 0;
25365}
25366_ACEOF
25367for ac_lib in '' seccomp; do
25368  if test -z "$ac_lib"; then
25369    ac_res="none required"
25370  else
25371    ac_res=-l$ac_lib
25372    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
25373  fi
25374  if ac_fn_c_try_link "$LINENO"; then :
25375  ac_cv_search_seccomp_init=$ac_res
25376fi
25377rm -f core conftest.err conftest.$ac_objext \
25378    conftest$ac_exeext
25379  if ${ac_cv_search_seccomp_init+:} false; then :
25380  break
25381fi
25382done
25383if ${ac_cv_search_seccomp_init+:} false; then :
25384
25385else
25386  ac_cv_search_seccomp_init=no
25387fi
25388rm conftest.$ac_ext
25389LIBS=$ac_func_search_save_LIBS
25390fi
25391{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_seccomp_init" >&5
25392$as_echo "$ac_cv_search_seccomp_init" >&6; }
25393ac_res=$ac_cv_search_seccomp_init
25394if test "$ac_res" != no; then :
25395  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
25396
25397$as_echo "#define LIBSECCOMP 1" >>confdefs.h
25398
25399
25400fi
25401
25402    if test "$cross_compiling" = yes; then :
25403  { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
25404$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25405as_fn_error $? "cannot run test program while cross compiling
25406See \`config.log' for more details" "$LINENO" 5; }
25407else
25408  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25409/* end confdefs.h.  */
25410
25411	#include <stdio.h>
25412	#include <stdlib.h>
25413	#include <errno.h>
25414	#include <sys/prctl.h>
25415	#include <linux/seccomp.h>
25416
25417	int main(void)
25418	{
25419		int ret;
25420		ret = prctl(PR_GET_SECCOMP, 0, 0, 0, 0);
25421		if (ret < 0) {
25422			switch (errno) {
25423			case ENOSYS:
25424				return 1;
25425			case EINVAL:
25426				return 1;
25427			default:
25428				return 1;
25429			}
25430		}
25431		ret =
25432		prctl(PR_SET_SECCOMP, SECCOMP_MODE_FILTER, NULL, 0, 0);
25433		if (ret < 0) {
25434			switch (errno) {
25435			case EINVAL:
25436				return 1;
25437			case EFAULT:
25438				return 0;
25439			default:
25440				return 1;
25441		}
25442	}
25443return 1;
25444}
25445
25446
25447_ACEOF
25448if ac_fn_c_try_run "$LINENO"; then :
25449
25450$as_echo "#define KERN_SECCOMP 1" >>confdefs.h
25451
25452
25453fi
25454rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25455  conftest.$ac_objext conftest.beam conftest.$ac_ext
25456fi
25457
25458    ;;
25459esac
25460
25461
25462{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for facilitynames in syslog.h" >&5
25463$as_echo_n "checking for facilitynames in syslog.h... " >&6; }
25464if ${ac_cv_HAVE_SYSLOG_FACILITYNAMES+:} false; then :
25465  $as_echo_n "(cached) " >&6
25466else
25467
25468cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25469/* end confdefs.h.  */
25470
25471#define SYSLOG_NAMES
25472#include <stdlib.h>
25473#include <syslog.h>
25474
25475int
25476main ()
25477{
25478 void *fnames; fnames = facilitynames;
25479  ;
25480  return 0;
25481}
25482_ACEOF
25483if ac_fn_c_try_compile "$LINENO"; then :
25484  ac_cv_HAVE_SYSLOG_FACILITYNAMES=yes
25485else
25486  ac_cv_HAVE_SYSLOG_FACILITYNAMES=no
25487fi
25488rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25489fi
25490{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_HAVE_SYSLOG_FACILITYNAMES" >&5
25491$as_echo "$ac_cv_HAVE_SYSLOG_FACILITYNAMES" >&6; }
25492case "$ac_cv_HAVE_SYSLOG_FACILITYNAMES" in
25493 yes)
25494
25495$as_echo "#define HAVE_SYSLOG_FACILITYNAMES 1" >>confdefs.h
25496
25497    ;;
25498 no)
25499    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: No facilitynames in <syslog.h>" >&5
25500$as_echo "$as_me: WARNING: No facilitynames in <syslog.h>" >&2;}
25501    ;;
25502 cross)
25503    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: facilitynames in <syslog.h> - cross-compiling" >&5
25504$as_echo "$as_me: WARNING: facilitynames in <syslog.h> - cross-compiling" >&2;}
25505    ;;
25506esac
25507
25508
25509
25510case "$host" in
25511 *-*-*linux*) ;;
25512 *-*-osf4*) ;;
25513 *-*-osf5*) ;;
25514 *)
25515    # HMS: Make sure we check for -lrt for clock_* before this...
25516    case "$ac_cv_search_clock_gettime" in
25517     '') as_fn_error $? "Internal Error: Haven't looked for clock_gettime() yet!" "$LINENO" 5 ;;
25518    esac
25519    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing sched_setscheduler" >&5
25520$as_echo_n "checking for library containing sched_setscheduler... " >&6; }
25521if ${ac_cv_search_sched_setscheduler+:} false; then :
25522  $as_echo_n "(cached) " >&6
25523else
25524  ac_func_search_save_LIBS=$LIBS
25525cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25526/* end confdefs.h.  */
25527
25528/* Override any GCC internal prototype to avoid an error.
25529   Use char because int might match the return type of a GCC
25530   builtin and then its argument prototype would still apply.  */
25531#ifdef __cplusplus
25532extern "C"
25533#endif
25534char sched_setscheduler ();
25535int
25536main ()
25537{
25538return sched_setscheduler ();
25539  ;
25540  return 0;
25541}
25542_ACEOF
25543for ac_lib in '' rt posix4; do
25544  if test -z "$ac_lib"; then
25545    ac_res="none required"
25546  else
25547    ac_res=-l$ac_lib
25548    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
25549  fi
25550  if ac_fn_c_try_link "$LINENO"; then :
25551  ac_cv_search_sched_setscheduler=$ac_res
25552fi
25553rm -f core conftest.err conftest.$ac_objext \
25554    conftest$ac_exeext
25555  if ${ac_cv_search_sched_setscheduler+:} false; then :
25556  break
25557fi
25558done
25559if ${ac_cv_search_sched_setscheduler+:} false; then :
25560
25561else
25562  ac_cv_search_sched_setscheduler=no
25563fi
25564rm conftest.$ac_ext
25565LIBS=$ac_func_search_save_LIBS
25566fi
25567{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_sched_setscheduler" >&5
25568$as_echo "$ac_cv_search_sched_setscheduler" >&6; }
25569ac_res=$ac_cv_search_sched_setscheduler
25570if test "$ac_res" != no; then :
25571  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
25572
25573fi
25574
25575    ;;
25576esac
25577
25578for ac_header in bstring.h
25579do :
25580  ac_fn_c_check_header_mongrel "$LINENO" "bstring.h" "ac_cv_header_bstring_h" "$ac_includes_default"
25581if test "x$ac_cv_header_bstring_h" = xyes; then :
25582  cat >>confdefs.h <<_ACEOF
25583#define HAVE_BSTRING_H 1
25584_ACEOF
25585
25586fi
25587
25588done
25589
25590ac_fn_c_check_header_mongrel "$LINENO" "dns_sd.h" "ac_cv_header_dns_sd_h" "$ac_includes_default"
25591if test "x$ac_cv_header_dns_sd_h" = xyes; then :
25592  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing DNSServiceRegister" >&5
25593$as_echo_n "checking for library containing DNSServiceRegister... " >&6; }
25594if ${ac_cv_search_DNSServiceRegister+:} false; then :
25595  $as_echo_n "(cached) " >&6
25596else
25597  ac_func_search_save_LIBS=$LIBS
25598cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25599/* end confdefs.h.  */
25600
25601/* Override any GCC internal prototype to avoid an error.
25602   Use char because int might match the return type of a GCC
25603   builtin and then its argument prototype would still apply.  */
25604#ifdef __cplusplus
25605extern "C"
25606#endif
25607char DNSServiceRegister ();
25608int
25609main ()
25610{
25611return DNSServiceRegister ();
25612  ;
25613  return 0;
25614}
25615_ACEOF
25616for ac_lib in '' dns_sd; do
25617  if test -z "$ac_lib"; then
25618    ac_res="none required"
25619  else
25620    ac_res=-l$ac_lib
25621    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
25622  fi
25623  if ac_fn_c_try_link "$LINENO"; then :
25624  ac_cv_search_DNSServiceRegister=$ac_res
25625fi
25626rm -f core conftest.err conftest.$ac_objext \
25627    conftest$ac_exeext
25628  if ${ac_cv_search_DNSServiceRegister+:} false; then :
25629  break
25630fi
25631done
25632if ${ac_cv_search_DNSServiceRegister+:} false; then :
25633
25634else
25635  ac_cv_search_DNSServiceRegister=no
25636fi
25637rm conftest.$ac_ext
25638LIBS=$ac_func_search_save_LIBS
25639fi
25640{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_DNSServiceRegister" >&5
25641$as_echo "$ac_cv_search_DNSServiceRegister" >&6; }
25642ac_res=$ac_cv_search_DNSServiceRegister
25643if test "$ac_res" != no; then :
25644  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
25645
25646$as_echo "#define HAVE_DNSREGISTRATION 1" >>confdefs.h
25647
25648
25649fi
25650
25651
25652fi
25653
25654
25655for ac_header in fcntl.h fnmatch.h ieeefp.h inttypes.h kvm.h math.h
25656do :
25657  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
25658ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
25659if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
25660  cat >>confdefs.h <<_ACEOF
25661#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
25662_ACEOF
25663
25664fi
25665
25666done
25667
25668
25669for ac_header in memory.h netdb.h poll.h
25670do :
25671  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
25672ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
25673if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
25674  cat >>confdefs.h <<_ACEOF
25675#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
25676_ACEOF
25677
25678fi
25679
25680done
25681
25682for ac_header in sgtty.h stdatomic.h
25683do :
25684  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
25685ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
25686if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
25687  cat >>confdefs.h <<_ACEOF
25688#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
25689_ACEOF
25690
25691fi
25692
25693done
25694
25695{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
25696$as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
25697if ${ac_cv_header_stdbool_h+:} false; then :
25698  $as_echo_n "(cached) " >&6
25699else
25700  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25701/* end confdefs.h.  */
25702
25703             #include <stdbool.h>
25704             #ifndef bool
25705              "error: bool is not defined"
25706             #endif
25707             #ifndef false
25708              "error: false is not defined"
25709             #endif
25710             #if false
25711              "error: false is not 0"
25712             #endif
25713             #ifndef true
25714              "error: true is not defined"
25715             #endif
25716             #if true != 1
25717              "error: true is not 1"
25718             #endif
25719             #ifndef __bool_true_false_are_defined
25720              "error: __bool_true_false_are_defined is not defined"
25721             #endif
25722
25723             struct s { _Bool s: 1; _Bool t; } s;
25724
25725             char a[true == 1 ? 1 : -1];
25726             char b[false == 0 ? 1 : -1];
25727             char c[__bool_true_false_are_defined == 1 ? 1 : -1];
25728             char d[(bool) 0.5 == true ? 1 : -1];
25729             /* See body of main program for 'e'.  */
25730             char f[(_Bool) 0.0 == false ? 1 : -1];
25731             char g[true];
25732             char h[sizeof (_Bool)];
25733             char i[sizeof s.t];
25734             enum { j = false, k = true, l = false * true, m = true * 256 };
25735             /* The following fails for
25736                HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
25737             _Bool n[m];
25738             char o[sizeof n == m * sizeof n[0] ? 1 : -1];
25739             char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
25740             /* Catch a bug in an HP-UX C compiler.  See
25741                http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
25742                http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
25743              */
25744             _Bool q = true;
25745             _Bool *pq = &q;
25746
25747int
25748main ()
25749{
25750
25751             bool e = &s;
25752             *pq |= q;
25753             *pq |= ! q;
25754             /* Refer to every declared value, to avoid compiler optimizations.  */
25755             return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
25756                     + !m + !n + !o + !p + !q + !pq);
25757
25758  ;
25759  return 0;
25760}
25761_ACEOF
25762if ac_fn_c_try_compile "$LINENO"; then :
25763  ac_cv_header_stdbool_h=yes
25764else
25765  ac_cv_header_stdbool_h=no
25766fi
25767rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25768fi
25769{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
25770$as_echo "$ac_cv_header_stdbool_h" >&6; }
25771   ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
25772if test "x$ac_cv_type__Bool" = xyes; then :
25773
25774cat >>confdefs.h <<_ACEOF
25775#define HAVE__BOOL 1
25776_ACEOF
25777
25778
25779fi
25780
25781
25782if test $ac_cv_header_stdbool_h = yes; then
25783
25784$as_echo "#define HAVE_STDBOOL_H 1" >>confdefs.h
25785
25786fi
25787
25788for ac_header in stdlib.h string.h termio.h
25789do :
25790  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
25791ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
25792if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
25793  cat >>confdefs.h <<_ACEOF
25794#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
25795_ACEOF
25796
25797fi
25798
25799done
25800
25801for ac_header in termios.h timepps.h timex.h unistd.h
25802do :
25803  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
25804ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
25805if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
25806  cat >>confdefs.h <<_ACEOF
25807#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
25808_ACEOF
25809
25810fi
25811
25812done
25813
25814
25815case "$host" in
25816 *-*-aix*)
25817    for ac_header in utmpx.h
25818do :
25819  ac_fn_c_check_header_mongrel "$LINENO" "utmpx.h" "ac_cv_header_utmpx_h" "$ac_includes_default"
25820if test "x$ac_cv_header_utmpx_h" = xyes; then :
25821  cat >>confdefs.h <<_ACEOF
25822#define HAVE_UTMPX_H 1
25823_ACEOF
25824
25825fi
25826
25827done
25828
25829    case "$ac_cv_header_utmpx_h" in
25830     yes)
25831	;;
25832     *)
25833	for ac_header in utmp.h
25834do :
25835  ac_fn_c_check_header_mongrel "$LINENO" "utmp.h" "ac_cv_header_utmp_h" "$ac_includes_default"
25836if test "x$ac_cv_header_utmp_h" = xyes; then :
25837  cat >>confdefs.h <<_ACEOF
25838#define HAVE_UTMP_H 1
25839_ACEOF
25840
25841fi
25842
25843done
25844
25845	;;
25846    esac
25847    ;;
25848 *)
25849    for ac_header in utmp.h utmpx.h
25850do :
25851  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
25852ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
25853if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
25854  cat >>confdefs.h <<_ACEOF
25855#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
25856_ACEOF
25857
25858fi
25859
25860done
25861
25862    ;;
25863esac
25864
25865#
25866# On Suns only (so far) getpass() truncates the typed password to 8
25867# characters, but getpassphrase() allows up to 257.  Most systems'
25868# getpass() does not truncate, at least not so as to affect ntpq and
25869# ntpdc password prompts.
25870#
25871# So check for getpassphrase(), but only on Sun operating systems.
25872#
25873case "$host" in
25874 *-*-sunos*|*-*-solaris*)
25875    for ac_func in getpassphrase
25876do :
25877  ac_fn_c_check_func "$LINENO" "getpassphrase" "ac_cv_func_getpassphrase"
25878if test "x$ac_cv_func_getpassphrase" = xyes; then :
25879  cat >>confdefs.h <<_ACEOF
25880#define HAVE_GETPASSPHRASE 1
25881_ACEOF
25882
25883fi
25884done
25885
25886esac
25887
25888
25889for ac_header in net/if6.h
25890do :
25891  ac_fn_c_check_header_mongrel "$LINENO" "net/if6.h" "ac_cv_header_net_if6_h" "$ac_includes_default"
25892if test "x$ac_cv_header_net_if6_h" = xyes; then :
25893  cat >>confdefs.h <<_ACEOF
25894#define HAVE_NET_IF6_H 1
25895_ACEOF
25896
25897fi
25898
25899done
25900
25901for ac_header in net/route.h
25902do :
25903  ac_fn_c_check_header_compile "$LINENO" "net/route.h" "ac_cv_header_net_route_h" "
25904    #include <sys/types.h>
25905    #include <sys/socket.h>
25906    #include <net/if.h>
25907
25908"
25909if test "x$ac_cv_header_net_route_h" = xyes; then :
25910  cat >>confdefs.h <<_ACEOF
25911#define HAVE_NET_ROUTE_H 1
25912_ACEOF
25913
25914fi
25915
25916done
25917
25918
25919for ac_header in netinfo/ni.h
25920do :
25921  ac_fn_c_check_header_mongrel "$LINENO" "netinfo/ni.h" "ac_cv_header_netinfo_ni_h" "$ac_includes_default"
25922if test "x$ac_cv_header_netinfo_ni_h" = xyes; then :
25923  cat >>confdefs.h <<_ACEOF
25924#define HAVE_NETINFO_NI_H 1
25925_ACEOF
25926
25927fi
25928
25929done
25930
25931case "$ac_cv_header_netinfo_ni_h" in
25932 yes)
25933
25934$as_echo "#define HAVE_NETINFO 1" >>confdefs.h
25935
25936esac
25937for ac_header in sun/audioio.h sys/audioio.h sys/file.h
25938do :
25939  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
25940ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
25941if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
25942  cat >>confdefs.h <<_ACEOF
25943#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
25944_ACEOF
25945
25946fi
25947
25948done
25949
25950case "$host" in
25951 *-*-sunos4*)
25952    ;;
25953 *)
25954    for ac_header in sys/ioctl.h
25955do :
25956  ac_fn_c_check_header_mongrel "$LINENO" "sys/ioctl.h" "ac_cv_header_sys_ioctl_h" "$ac_includes_default"
25957if test "x$ac_cv_header_sys_ioctl_h" = xyes; then :
25958  cat >>confdefs.h <<_ACEOF
25959#define HAVE_SYS_IOCTL_H 1
25960_ACEOF
25961
25962fi
25963
25964done
25965
25966    ;;
25967esac
25968for ac_header in sys/ipc.h sys/lock.h sys/mman.h
25969do :
25970  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
25971ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
25972if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
25973  cat >>confdefs.h <<_ACEOF
25974#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
25975_ACEOF
25976
25977fi
25978
25979done
25980
25981# HMS: Check sys/proc.h and sys/resource.h after some others
25982for ac_header in sys/modem.h sys/ppsclock.h sys/ppstime.h sched.h
25983do :
25984  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
25985ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
25986if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
25987  cat >>confdefs.h <<_ACEOF
25988#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
25989_ACEOF
25990
25991fi
25992
25993done
25994
25995case "$ac_cv_header_sched_h" in
25996 yes)
25997    ;;
25998 *)
25999    for ac_header in sys/sched.h
26000do :
26001  ac_fn_c_check_header_mongrel "$LINENO" "sys/sched.h" "ac_cv_header_sys_sched_h" "$ac_includes_default"
26002if test "x$ac_cv_header_sys_sched_h" = xyes; then :
26003  cat >>confdefs.h <<_ACEOF
26004#define HAVE_SYS_SCHED_H 1
26005_ACEOF
26006
26007fi
26008
26009done
26010
26011    ;;
26012esac
26013# HMS: Check sys/shm.h after some others
26014for ac_header in sys/select.h sys/signal.h sys/sockio.h
26015do :
26016  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
26017ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
26018if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
26019  cat >>confdefs.h <<_ACEOF
26020#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
26021_ACEOF
26022
26023fi
26024
26025done
26026
26027# HMS: Checked sys/socket.h earlier
26028case "$host" in
26029 *-*-netbsd*)
26030    ;;
26031 *)
26032    for ac_header in machine/soundcard.h sys/soundcard.h
26033do :
26034  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
26035ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
26036if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
26037  cat >>confdefs.h <<_ACEOF
26038#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
26039_ACEOF
26040
26041fi
26042
26043done
26044
26045    ;;
26046esac
26047for ac_header in sys/stat.h sys/stream.h stropts.h sys/stropts.h sys/syssgi.h
26048do :
26049  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
26050ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
26051if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
26052  cat >>confdefs.h <<_ACEOF
26053#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
26054_ACEOF
26055
26056fi
26057
26058done
26059
26060for ac_header in sys/systune.h sys/termios.h sys/tpro.h sys/wait.h
26061do :
26062  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
26063ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
26064if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
26065  cat >>confdefs.h <<_ACEOF
26066#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
26067_ACEOF
26068
26069fi
26070
26071done
26072
26073case "$host" in
26074*-convex-*)
26075    for ac_header in /sys/sync/queue.h /sys/sync/sema.h
26076do :
26077  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
26078ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
26079if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
26080  cat >>confdefs.h <<_ACEOF
26081#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
26082_ACEOF
26083
26084fi
26085
26086done
26087
26088    ;;
26089*-*-bsdi*)
26090    for ac_header in machine/inline.h sys/pcl720.h sys/i8253.h
26091do :
26092  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
26093ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
26094if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
26095  cat >>confdefs.h <<_ACEOF
26096#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
26097_ACEOF
26098
26099fi
26100
26101done
26102
26103    ;;
26104esac
26105
26106case "$ac_cv_header_stdatomic_h" in
26107 yes)
26108	for ac_func in atomic_thread_fence
26109do :
26110  ac_fn_c_check_func "$LINENO" "atomic_thread_fence" "ac_cv_func_atomic_thread_fence"
26111if test "x$ac_cv_func_atomic_thread_fence" = xyes; then :
26112  cat >>confdefs.h <<_ACEOF
26113#define HAVE_ATOMIC_THREAD_FENCE 1
26114_ACEOF
26115
26116fi
26117done
26118
26119	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for atomic_thread_fence()" >&5
26120$as_echo_n "checking for atomic_thread_fence()... " >&6; }
26121if ${ntp_cv_func_atomic_thread_fence+:} false; then :
26122  $as_echo_n "(cached) " >&6
26123else
26124  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26125/* end confdefs.h.  */
26126
26127			#include <stdatomic.h>
26128
26129int
26130main ()
26131{
26132
26133			atomic_thread_fence(memory_order_seq_cst);
26134
26135
26136  ;
26137  return 0;
26138}
26139		ntp_cv_func_atomic_thread_fence=yes
26140_ACEOF
26141if ac_fn_c_try_compile "$LINENO"; then :
26142  ntp_cv_func_atomic_thread_fence=no
26143
26144fi
26145rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26146
26147fi
26148{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_func_atomic_thread_fence" >&5
26149$as_echo "$ntp_cv_func_atomic_thread_fence" >&6; }
26150    ;;
26151esac
26152
26153case "$host" in
26154 *-*-solaris2.6)
26155    # Broken...
26156    ;;
26157 *)
26158    for ac_func in ntp_adjtime ntp_gettime
26159do :
26160  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
26161ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
26162if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
26163  cat >>confdefs.h <<_ACEOF
26164#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
26165_ACEOF
26166
26167fi
26168done
26169
26170    ;;
26171esac
26172
26173case "$host" in
26174 *-*-*linux*)
26175    case "$ac_cv_func_ntp_gettime" in
26176     yes)
26177	;;
26178     *)
26179	for ac_func in __ntp_gettime
26180do :
26181  ac_fn_c_check_func "$LINENO" "__ntp_gettime" "ac_cv_func___ntp_gettime"
26182if test "x$ac_cv_func___ntp_gettime" = xyes; then :
26183  cat >>confdefs.h <<_ACEOF
26184#define HAVE___NTP_GETTIME 1
26185_ACEOF
26186
26187fi
26188done
26189
26190	case "$ac_cv_func___ntp_gettime" in
26191	 yes)
26192
26193$as_echo "#define ntp_gettime __ntp_gettime" >>confdefs.h
26194
26195
26196$as_echo "#define HAVE_NTP_GETTIME 1" >>confdefs.h
26197
26198	esac
26199	;;
26200    esac
26201    for ac_func in adjtimex
26202do :
26203  ac_fn_c_check_func "$LINENO" "adjtimex" "ac_cv_func_adjtimex"
26204if test "x$ac_cv_func_adjtimex" = xyes; then :
26205  cat >>confdefs.h <<_ACEOF
26206#define HAVE_ADJTIMEX 1
26207_ACEOF
26208
26209fi
26210done
26211
26212    case "$ac_cv_func_adjtimex" in
26213     yes)
26214
26215$as_echo "#define ntp_adjtime adjtimex" >>confdefs.h
26216
26217
26218$as_echo "#define HAVE_NTP_ADJTIME 1" >>confdefs.h
26219
26220	have_adjtimex=1
26221	;;
26222     *)
26223	for ac_func in __adjtimex
26224do :
26225  ac_fn_c_check_func "$LINENO" "__adjtimex" "ac_cv_func___adjtimex"
26226if test "x$ac_cv_func___adjtimex" = xyes; then :
26227  cat >>confdefs.h <<_ACEOF
26228#define HAVE___ADJTIMEX 1
26229_ACEOF
26230
26231fi
26232done
26233
26234	case "$ac_cv_func___adjtimex" in
26235	 yes)
26236
26237$as_echo "#define ntp_adjtime __adjtimex" >>confdefs.h
26238
26239
26240$as_echo "#define HAVE_NTP_ADJTIME 1" >>confdefs.h
26241
26242
26243$as_echo "#define adjtimex __adjtimex" >>confdefs.h
26244
26245
26246$as_echo "#define HAVE_ADJTIMEX 1" >>confdefs.h
26247
26248	    have_adjtimex=1
26249	esac
26250	;;
26251    esac
26252esac
26253case "$have_adjtimex" in
26254 '')
26255    # nlist stuff is only needed for tickadj.
26256    saved_LIBS="$LIBS"
26257    LIBS=
26258    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing nlist" >&5
26259$as_echo_n "checking for library containing nlist... " >&6; }
26260if ${ac_cv_search_nlist+:} false; then :
26261  $as_echo_n "(cached) " >&6
26262else
26263  ac_func_search_save_LIBS=$LIBS
26264cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26265/* end confdefs.h.  */
26266
26267/* Override any GCC internal prototype to avoid an error.
26268   Use char because int might match the return type of a GCC
26269   builtin and then its argument prototype would still apply.  */
26270#ifdef __cplusplus
26271extern "C"
26272#endif
26273char nlist ();
26274int
26275main ()
26276{
26277return nlist ();
26278  ;
26279  return 0;
26280}
26281_ACEOF
26282for ac_lib in '' elf ld mld; do
26283  if test -z "$ac_lib"; then
26284    ac_res="none required"
26285  else
26286    ac_res=-l$ac_lib
26287    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
26288  fi
26289  if ac_fn_c_try_link "$LINENO"; then :
26290  ac_cv_search_nlist=$ac_res
26291fi
26292rm -f core conftest.err conftest.$ac_objext \
26293    conftest$ac_exeext
26294  if ${ac_cv_search_nlist+:} false; then :
26295  break
26296fi
26297done
26298if ${ac_cv_search_nlist+:} false; then :
26299
26300else
26301  ac_cv_search_nlist=no
26302fi
26303rm conftest.$ac_ext
26304LIBS=$ac_func_search_save_LIBS
26305fi
26306{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_nlist" >&5
26307$as_echo "$ac_cv_search_nlist" >&6; }
26308ac_res=$ac_cv_search_nlist
26309if test "$ac_res" != no; then :
26310  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
26311
26312fi
26313
26314    # XXX ac_cv_search_nlist will be 'none required', 'no', or '-l...'
26315    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing kvm_open" >&5
26316$as_echo_n "checking for library containing kvm_open... " >&6; }
26317if ${ac_cv_search_kvm_open+:} false; then :
26318  $as_echo_n "(cached) " >&6
26319else
26320  ac_func_search_save_LIBS=$LIBS
26321cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26322/* end confdefs.h.  */
26323
26324/* Override any GCC internal prototype to avoid an error.
26325   Use char because int might match the return type of a GCC
26326   builtin and then its argument prototype would still apply.  */
26327#ifdef __cplusplus
26328extern "C"
26329#endif
26330char kvm_open ();
26331int
26332main ()
26333{
26334return kvm_open ();
26335  ;
26336  return 0;
26337}
26338_ACEOF
26339for ac_lib in '' kvm; do
26340  if test -z "$ac_lib"; then
26341    ac_res="none required"
26342  else
26343    ac_res=-l$ac_lib
26344    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
26345  fi
26346  if ac_fn_c_try_link "$LINENO"; then :
26347  ac_cv_search_kvm_open=$ac_res
26348fi
26349rm -f core conftest.err conftest.$ac_objext \
26350    conftest$ac_exeext
26351  if ${ac_cv_search_kvm_open+:} false; then :
26352  break
26353fi
26354done
26355if ${ac_cv_search_kvm_open+:} false; then :
26356
26357else
26358  ac_cv_search_kvm_open=no
26359fi
26360rm conftest.$ac_ext
26361LIBS=$ac_func_search_save_LIBS
26362fi
26363{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_kvm_open" >&5
26364$as_echo "$ac_cv_search_kvm_open" >&6; }
26365ac_res=$ac_cv_search_kvm_open
26366if test "$ac_res" != no; then :
26367  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
26368
26369fi
26370	    # XXX ac_cv_search_kvm_open will be 'none required', 'no', or '-l...'
26371    for ac_header in nlist.h sys/var.h
26372do :
26373  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
26374ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
26375if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
26376  cat >>confdefs.h <<_ACEOF
26377#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
26378_ACEOF
26379
26380fi
26381
26382done
26383
26384    case "$ac_cv_header_nlist_h" in
26385     yes)
26386
26387$as_echo "#define NLIST_STRUCT 1" >>confdefs.h
26388
26389	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for n_un in struct nlist" >&5
26390$as_echo_n "checking for n_un in struct nlist... " >&6; }
26391if ${ntp_cv_struct_nlist_n_un+:} false; then :
26392  $as_echo_n "(cached) " >&6
26393else
26394  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26395/* end confdefs.h.  */
26396
26397			#include <nlist.h>
26398
26399int
26400main ()
26401{
26402
26403			struct nlist n;
26404			n.n_un.n_name = 0;
26405
26406
26407  ;
26408  return 0;
26409}
26410		ntp_cv_struct_nlist_n_un=yes
26411_ACEOF
26412if ac_fn_c_try_compile "$LINENO"; then :
26413  ntp_cv_struct_nlist_n_un=no
26414
26415fi
26416rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26417
26418fi
26419{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_struct_nlist_n_un" >&5
26420$as_echo "$ntp_cv_struct_nlist_n_un" >&6; }
26421	case "$ntp_cv_struct_nlist_n_un" in
26422	 yes)
26423
26424$as_echo "#define NLIST_NAME_UNION 1" >>confdefs.h
26425
26426	esac
26427    esac
26428
26429    LDADD_NLIST="$LIBS"
26430    LIBS="$saved_LIBS"
26431    { saved_LIBS=; unset saved_LIBS;}
26432esac
26433
26434for ac_header in sys/proc.h
26435do :
26436  ac_fn_c_check_header_compile "$LINENO" "sys/proc.h" "ac_cv_header_sys_proc_h" "
26437    #ifdef HAVE_SYS_TYPES_H
26438    # include <sys/types.h>
26439    #endif
26440    #ifdef HAVE_SYS_TIME_H
26441    # include <sys/time.h>
26442    #endif
26443
26444"
26445if test "x$ac_cv_header_sys_proc_h" = xyes; then :
26446  cat >>confdefs.h <<_ACEOF
26447#define HAVE_SYS_PROC_H 1
26448_ACEOF
26449
26450fi
26451
26452done
26453
26454
26455for ac_header in sys/resource.h
26456do :
26457  ac_fn_c_check_header_compile "$LINENO" "sys/resource.h" "ac_cv_header_sys_resource_h" "
26458    #ifdef HAVE_SYS_TIME_H
26459    # include <sys/time.h>
26460    #endif
26461
26462"
26463if test "x$ac_cv_header_sys_resource_h" = xyes; then :
26464  cat >>confdefs.h <<_ACEOF
26465#define HAVE_SYS_RESOURCE_H 1
26466_ACEOF
26467
26468fi
26469
26470done
26471
26472
26473for ac_header in sys/shm.h
26474do :
26475  ac_fn_c_check_header_compile "$LINENO" "sys/shm.h" "ac_cv_header_sys_shm_h" "
26476    #ifdef HAVE_SYS_TYPES_H
26477    # include <sys/types.h>
26478    #endif
26479    #ifdef HAVE_SYS_IPC_H
26480    # include <sys/ipc.h>
26481    #endif
26482
26483"
26484if test "x$ac_cv_header_sys_shm_h" = xyes; then :
26485  cat >>confdefs.h <<_ACEOF
26486#define HAVE_SYS_SHM_H 1
26487_ACEOF
26488
26489fi
26490
26491done
26492
26493
26494for ac_header in sys/timex.h
26495do :
26496  ac_fn_c_check_header_compile "$LINENO" "sys/timex.h" "ac_cv_header_sys_timex_h" "
26497    #ifdef HAVE_SYS_TIME_H
26498    # include <sys/time.h>
26499    #endif
26500
26501"
26502if test "x$ac_cv_header_sys_timex_h" = xyes; then :
26503  cat >>confdefs.h <<_ACEOF
26504#define HAVE_SYS_TIMEX_H 1
26505_ACEOF
26506
26507fi
26508
26509done
26510
26511
26512
26513
26514# We could do a cv check here, but is it worth it?
26515
26516cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26517/* end confdefs.h.  */
26518
26519    	#include <sys/socket.h>
26520	#ifndef AF_UNSPEC
26521	#include "Bletch: AF_UNSPEC is undefined!"
26522	#endif
26523	#if AF_UNSPEC != 0
26524	#include "Bletch: AF_UNSPEC != 0"
26525	#endif
26526
26527int
26528main ()
26529{
26530{ $as_echo "$as_me:${as_lineno-$LINENO}: AF_UNSPEC is zero, as expected." >&5
26531$as_echo "$as_me: AF_UNSPEC is zero, as expected." >&6;}
26532  ;
26533  return 0;
26534}
26535
26536_ACEOF
26537if ac_fn_c_try_compile "$LINENO"; then :
26538
26539fi
26540rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26541
26542{ $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of signal handlers" >&5
26543$as_echo_n "checking return type of signal handlers... " >&6; }
26544if ${ac_cv_type_signal+:} false; then :
26545  $as_echo_n "(cached) " >&6
26546else
26547  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26548/* end confdefs.h.  */
26549#include <sys/types.h>
26550#include <signal.h>
26551
26552int
26553main ()
26554{
26555return *(signal (0, 0)) (0) == 1;
26556  ;
26557  return 0;
26558}
26559_ACEOF
26560if ac_fn_c_try_compile "$LINENO"; then :
26561  ac_cv_type_signal=int
26562else
26563  ac_cv_type_signal=void
26564fi
26565rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26566fi
26567{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_signal" >&5
26568$as_echo "$ac_cv_type_signal" >&6; }
26569
26570cat >>confdefs.h <<_ACEOF
26571#define RETSIGTYPE $ac_cv_type_signal
26572_ACEOF
26573
26574
26575ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default"
26576if test "x$ac_cv_type_off_t" = xyes; then :
26577
26578else
26579
26580cat >>confdefs.h <<_ACEOF
26581#define off_t long int
26582_ACEOF
26583
26584fi
26585
26586{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5
26587$as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
26588if ${ac_cv_struct_tm+:} false; then :
26589  $as_echo_n "(cached) " >&6
26590else
26591  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26592/* end confdefs.h.  */
26593#include <sys/types.h>
26594#include <time.h>
26595
26596int
26597main ()
26598{
26599struct tm tm;
26600				     int *p = &tm.tm_sec;
26601				     return !p;
26602  ;
26603  return 0;
26604}
26605_ACEOF
26606if ac_fn_c_try_compile "$LINENO"; then :
26607  ac_cv_struct_tm=time.h
26608else
26609  ac_cv_struct_tm=sys/time.h
26610fi
26611rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26612fi
26613{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5
26614$as_echo "$ac_cv_struct_tm" >&6; }
26615if test $ac_cv_struct_tm = sys/time.h; then
26616
26617$as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h
26618
26619fi
26620
26621{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a fallback value for HZ" >&5
26622$as_echo_n "checking for a fallback value for HZ... " >&6; }
26623if ${ntp_cv_default_hz+:} false; then :
26624  $as_echo_n "(cached) " >&6
26625else
26626
26627	ntp_cv_default_hz=100
26628	case "$host" in
26629	 alpha*-dec-osf4*|alpha*-dec-osf5*)
26630	    ntp_cv_default_hz=1024
26631	    ;;
26632	 mips-dec-ultrix4*)
26633	    ntp_cv_default_hz=256
26634	    ;;
26635	esac
26636
26637
26638fi
26639{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_default_hz" >&5
26640$as_echo "$ntp_cv_default_hz" >&6; }
26641
26642cat >>confdefs.h <<_ACEOF
26643#define DEFAULT_HZ $ntp_cv_default_hz
26644_ACEOF
26645
26646
26647{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we need to override the system's value for HZ" >&5
26648$as_echo_n "checking if we need to override the system's value for HZ... " >&6; }
26649if ${ntp_cv_override_hz+:} false; then :
26650  $as_echo_n "(cached) " >&6
26651else
26652
26653	ntp_cv_override_hz=no
26654	case "$host" in
26655	 alpha*-dec-osf4*|alpha*-dec-osf5*)
26656	    ntp_cv_override_hz=yes
26657	    ;;
26658	 mips-dec-ultrix4*)
26659	    ntp_cv_override_hz=yes
26660	    ;;
26661	 *-*-freebsd*)
26662	    ntp_cv_override_hz=yes
26663	    ;;
26664	 *-*-sunos4*)
26665	    ntp_cv_override_hz=yes
26666	    ;;
26667	 *-*-kfreebsd*)
26668	    ntp_cv_override_hz=yes
26669	    ;;
26670	esac
26671
26672
26673fi
26674{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_override_hz" >&5
26675$as_echo "$ntp_cv_override_hz" >&6; }
26676case "$ntp_cv_override_hz" in
26677 yes)
26678
26679$as_echo "#define OVERRIDE_HZ 1" >>confdefs.h
26680
26681esac
26682
26683
26684
26685{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct rt_msghdr" >&5
26686$as_echo_n "checking for struct rt_msghdr... " >&6; }
26687if ${ntp_cv_struct_rt_msghdr+:} false; then :
26688  $as_echo_n "(cached) " >&6
26689else
26690  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26691/* end confdefs.h.  */
26692
26693		#include <sys/types.h>
26694		#include <sys/socket.h>
26695		#include <net/if.h>
26696		#include <net/route.h>
26697
26698int
26699main ()
26700{
26701
26702		struct rt_msghdr p;
26703
26704
26705  ;
26706  return 0;
26707}
26708_ACEOF
26709if ac_fn_c_try_compile "$LINENO"; then :
26710  ntp_cv_struct_rt_msghdr=yes
26711else
26712  ntp_cv_struct_rt_msghdr=no
26713
26714fi
26715rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26716
26717fi
26718{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_struct_rt_msghdr" >&5
26719$as_echo "$ntp_cv_struct_rt_msghdr" >&6; }
26720
26721{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct rtattr" >&5
26722$as_echo_n "checking for struct rtattr... " >&6; }
26723if ${ntp_cv_rtattr+:} false; then :
26724  $as_echo_n "(cached) " >&6
26725else
26726  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26727/* end confdefs.h.  */
26728
26729		#include <stddef.h>
26730		#include <sys/socket.h>
26731		#include <linux/rtnetlink.h>
26732
26733int
26734main ()
26735{
26736
26737		struct rtattr p;
26738
26739
26740  ;
26741  return 0;
26742}
26743_ACEOF
26744if ac_fn_c_try_compile "$LINENO"; then :
26745  ntp_cv_rtattr=yes
26746else
26747  ntp_cv_rtattr=no
26748
26749fi
26750rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26751
26752fi
26753{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_rtattr" >&5
26754$as_echo "$ntp_cv_rtattr" >&6; }
26755
26756case "$ntp_cv_struct_rt_msghdr$ntp_cv_rtattr" in
26757 *yes*)
26758
26759$as_echo "#define HAS_ROUTING_SOCKET 1" >>confdefs.h
26760
26761    case "$ntp_cv_rtattr" in
26762     yes)
26763
26764$as_echo "#define HAVE_RTNETLINK 1" >>confdefs.h
26765
26766    esac
26767esac
26768
26769{ $as_echo "$as_me:${as_lineno-$LINENO}: checking struct sigaction for sa_sigaction" >&5
26770$as_echo_n "checking struct sigaction for sa_sigaction... " >&6; }
26771if ${ntp_cv_struct_sigaction_has_sa_sigaction+:} false; then :
26772  $as_echo_n "(cached) " >&6
26773else
26774  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26775/* end confdefs.h.  */
26776
26777		#include <signal.h>
26778
26779int
26780main ()
26781{
26782
26783		struct sigaction act;
26784		act.sa_sigaction = 0;
26785
26786
26787  ;
26788  return 0;
26789}
26790_ACEOF
26791if ac_fn_c_try_compile "$LINENO"; then :
26792  ntp_cv_struct_sigaction_has_sa_sigaction=yes
26793else
26794  ntp_cv_struct_sigaction_has_sa_sigaction=no
26795
26796fi
26797rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26798
26799fi
26800{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_struct_sigaction_has_sa_sigaction" >&5
26801$as_echo "$ntp_cv_struct_sigaction_has_sa_sigaction" >&6; }
26802case "$ntp_cv_struct_sigaction_has_sa_sigaction" in
26803 yes)
26804
26805$as_echo "#define HAVE_SA_SIGACTION_IN_STRUCT_SIGACTION 1" >>confdefs.h
26806
26807esac
26808
26809{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct ppsclockev" >&5
26810$as_echo_n "checking for struct ppsclockev... " >&6; }
26811if ${ntp_cv_struct_ppsclockev+:} false; then :
26812  $as_echo_n "(cached) " >&6
26813else
26814  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26815/* end confdefs.h.  */
26816
26817		#ifdef HAVE_SYS_TYPES_H
26818		# include <sys/types.h>
26819		#endif
26820		#ifdef HAVE_SYS_TERMIOS_H
26821		# include <sys/termios.h>
26822		#endif
26823		#ifdef HAVE_SYS_TIME_H
26824		# include <sys/time.h>
26825		#endif
26826		#ifdef HAVE_SYS_PPSCLOCK_H
26827		# include <sys/ppsclock.h>
26828		#endif
26829
26830int
26831main ()
26832{
26833
26834		extern struct ppsclockev *pce;
26835		return pce->serial;
26836
26837
26838  ;
26839  return 0;
26840}
26841_ACEOF
26842if ac_fn_c_try_compile "$LINENO"; then :
26843  ntp_cv_struct_ppsclockev=yes
26844else
26845  ntp_cv_struct_ppsclockev=no
26846
26847fi
26848rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26849
26850fi
26851{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_struct_ppsclockev" >&5
26852$as_echo "$ntp_cv_struct_ppsclockev" >&6; }
26853case "$ntp_cv_struct_ppsclockev" in
26854 yes)
26855
26856$as_echo "#define HAVE_STRUCT_PPSCLOCKEV 1" >>confdefs.h
26857
26858esac
26859
26860case "$ac_cv_header_machine_soundcard_h$ac_cv_header_sys_soundcard_h" in
26861  *yes*)
26862    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct snd_size" >&5
26863$as_echo_n "checking for struct snd_size... " >&6; }
26864if ${ntp_cv_struct_snd_size+:} false; then :
26865  $as_echo_n "(cached) " >&6
26866else
26867  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26868/* end confdefs.h.  */
26869
26870		    #ifdef HAVE_MACHINE_SOUNDCARD_H
26871		    # include <machine/soundcard.h>
26872		    #endif
26873		    #ifdef HAVE_SYS_SOUNDCARD_H
26874		    # include <sys/soundcard.h>
26875		    #endif
26876
26877int
26878main ()
26879{
26880
26881		    extern struct snd_size *ss;
26882		    return ss->rec_size;
26883
26884
26885  ;
26886  return 0;
26887}
26888_ACEOF
26889if ac_fn_c_try_compile "$LINENO"; then :
26890  ntp_cv_struct_snd_size=yes
26891else
26892  ntp_cv_struct_snd_size=no
26893
26894fi
26895rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26896
26897fi
26898{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_struct_snd_size" >&5
26899$as_echo "$ntp_cv_struct_snd_size" >&6; }
26900    case "$ntp_cv_struct_snd_size" in
26901     yes)
26902
26903$as_echo "#define HAVE_STRUCT_SND_SIZE 1" >>confdefs.h
26904
26905    esac
26906esac
26907
26908{ $as_echo "$as_me:${as_lineno-$LINENO}: checking struct clockinfo for hz" >&5
26909$as_echo_n "checking struct clockinfo for hz... " >&6; }
26910if ${ntp_cv_struct_clockinfo_has_hz+:} false; then :
26911  $as_echo_n "(cached) " >&6
26912else
26913  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26914/* end confdefs.h.  */
26915
26916		#include <sys/time.h>
26917
26918int
26919main ()
26920{
26921
26922		extern struct clockinfo *pc;
26923		return pc->hz;
26924
26925
26926  ;
26927  return 0;
26928}
26929_ACEOF
26930if ac_fn_c_try_compile "$LINENO"; then :
26931  ntp_cv_struct_clockinfo_has_hz=yes
26932else
26933  ntp_cv_struct_clockinfo_has_hz=no
26934
26935fi
26936rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26937
26938fi
26939{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_struct_clockinfo_has_hz" >&5
26940$as_echo "$ntp_cv_struct_clockinfo_has_hz" >&6; }
26941case "$ntp_cv_struct_clockinfo_has_hz" in
26942 yes)
26943
26944$as_echo "#define HAVE_HZ_IN_STRUCT_CLOCKINFO 1" >>confdefs.h
26945
26946esac
26947
26948{ $as_echo "$as_me:${as_lineno-$LINENO}: checking struct clockinfo for tickadj" >&5
26949$as_echo_n "checking struct clockinfo for tickadj... " >&6; }
26950if ${ntp_cv_struct_clockinfo_has_hz+:} false; then :
26951  $as_echo_n "(cached) " >&6
26952else
26953  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26954/* end confdefs.h.  */
26955
26956		#include <sys/time.h>
26957
26958int
26959main ()
26960{
26961
26962		extern struct clockinfo *pc;
26963		return pc->tickadj;
26964
26965
26966  ;
26967  return 0;
26968}
26969_ACEOF
26970if ac_fn_c_try_compile "$LINENO"; then :
26971  ntp_cv_struct_clockinfo_has_hz=yes
26972else
26973  ntp_cv_struct_clockinfo_has_hz=no
26974
26975fi
26976rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26977
26978fi
26979{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_struct_clockinfo_has_hz" >&5
26980$as_echo "$ntp_cv_struct_clockinfo_has_hz" >&6; }
26981case "$ntp_cv_struct_clockinfo_has_hz" in
26982 yes)
26983
26984$as_echo "#define HAVE_TICKADJ_IN_STRUCT_CLOCKINFO 1" >>confdefs.h
26985
26986esac
26987
26988case "$ntp_cv_struct_ntptimeval" in
26989 yes)
26990    ac_fn_c_check_member "$LINENO" "struct ntptimeval" "time.tv_nsec" "ac_cv_member_struct_ntptimeval_time_tv_nsec" "
26991	    #ifdef HAVE_SYS_TIME_H
26992	    # include <sys/time.h>
26993	    #else
26994	    # ifdef HAVE_TIME_H
26995	    #  include <time.h>
26996	    # endif
26997	    #endif
26998	    #ifdef HAVE_SYS_TIMEX_H
26999	    # include <sys/timex.h>
27000	    #else
27001	    # ifdef HAVE_TIMEX_H
27002	    #  include <timex.h>
27003	    # endif
27004	    #endif
27005
27006
27007"
27008if test "x$ac_cv_member_struct_ntptimeval_time_tv_nsec" = xyes; then :
27009
27010cat >>confdefs.h <<_ACEOF
27011#define HAVE_STRUCT_NTPTIMEVAL_TIME_TV_NSEC 1
27012_ACEOF
27013
27014
27015fi
27016
27017esac
27018
27019####
27020
27021for ac_func in arc4random_buf
27022do :
27023  ac_fn_c_check_func "$LINENO" "arc4random_buf" "ac_cv_func_arc4random_buf"
27024if test "x$ac_cv_func_arc4random_buf" = xyes; then :
27025  cat >>confdefs.h <<_ACEOF
27026#define HAVE_ARC4RANDOM_BUF 1
27027_ACEOF
27028
27029fi
27030done
27031
27032
27033####
27034
27035saved_LIBS="$LIBS"
27036LIBS="$LIBS $LDADD_LIBNTP"
27037for ac_func in daemon
27038do :
27039  ac_fn_c_check_func "$LINENO" "daemon" "ac_cv_func_daemon"
27040if test "x$ac_cv_func_daemon" = xyes; then :
27041  cat >>confdefs.h <<_ACEOF
27042#define HAVE_DAEMON 1
27043_ACEOF
27044
27045fi
27046done
27047
27048# XXX if we keep everything in LIBS and also keep separate lists, this simplifies.
27049LIBS="$saved_LIBS"
27050{ saved_LIBS=; unset saved_LIBS;}
27051
27052for ac_func in finite
27053do :
27054  ac_fn_c_check_func "$LINENO" "finite" "ac_cv_func_finite"
27055if test "x$ac_cv_func_finite" = xyes; then :
27056  cat >>confdefs.h <<_ACEOF
27057#define HAVE_FINITE 1
27058_ACEOF
27059
27060else
27061  for ac_func in isfinite
27062do :
27063  ac_fn_c_check_func "$LINENO" "isfinite" "ac_cv_func_isfinite"
27064if test "x$ac_cv_func_isfinite" = xyes; then :
27065  cat >>confdefs.h <<_ACEOF
27066#define HAVE_ISFINITE 1
27067_ACEOF
27068
27069else
27070
27071	    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for isfinite with <math.h>" >&5
27072$as_echo_n "checking for isfinite with <math.h>... " >&6; }
27073	    _libs=$LIBS
27074	    # XXX
27075	    LIBS="$LIBS -lm"
27076	    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27077/* end confdefs.h.  */
27078
27079			#include <math.h>
27080
27081int
27082main ()
27083{
27084
27085			float f = 0.0;
27086			isfinite(f);
27087
27088
27089  ;
27090  return 0;
27091}
27092_ACEOF
27093if ac_fn_c_try_link "$LINENO"; then :
27094  ans=yes
27095else
27096  ans=no
27097
27098fi
27099rm -f core conftest.err conftest.$ac_objext \
27100    conftest$ac_exeext conftest.$ac_ext
27101	    LIBS=$_libs
27102	    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
27103$as_echo "$ans" >&6; }
27104	    case "$ans" in
27105	     yes)
27106		$as_echo "#define HAVE_ISFINITE 1" >>confdefs.h
27107
27108	    esac
27109
27110
27111fi
27112done
27113
27114
27115fi
27116done
27117
27118
27119for ac_func in fnmatch getbootfile getuid getrusage nanosleep strsignal
27120do :
27121  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
27122ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
27123if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
27124  cat >>confdefs.h <<_ACEOF
27125#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
27126_ACEOF
27127
27128fi
27129done
27130
27131
27132# kvm_open() is only used by tickadj.  Also see above.
27133case "$ac_cv_header_kvm_h" in
27134 yes)
27135    for ac_func in kvm_open
27136do :
27137  ac_fn_c_check_func "$LINENO" "kvm_open" "ac_cv_func_kvm_open"
27138if test "x$ac_cv_func_kvm_open" = xyes; then :
27139  cat >>confdefs.h <<_ACEOF
27140#define HAVE_KVM_OPEN 1
27141_ACEOF
27142
27143fi
27144done
27145
27146    ;;
27147esac
27148
27149case "$host" in
27150 *-*-sco3.2v5.0.*)
27151    # Just stubs.  Sigh.
27152    ;;
27153 *) for ac_func in mkstemp
27154do :
27155  ac_fn_c_check_func "$LINENO" "mkstemp" "ac_cv_func_mkstemp"
27156if test "x$ac_cv_func_mkstemp" = xyes; then :
27157  cat >>confdefs.h <<_ACEOF
27158#define HAVE_MKSTEMP 1
27159_ACEOF
27160
27161fi
27162done
27163
27164    ;;
27165esac
27166for ac_func in mktime
27167do :
27168  ac_fn_c_check_func "$LINENO" "mktime" "ac_cv_func_mktime"
27169if test "x$ac_cv_func_mktime" = xyes; then :
27170  cat >>confdefs.h <<_ACEOF
27171#define HAVE_MKTIME 1
27172_ACEOF
27173
27174fi
27175done
27176
27177case "$host" in
27178 *-*-aix[4-9]*)
27179    # XXX only verified thru AIX6.
27180    # Just a stub.  Sigh.
27181    ;;
27182 *-*-irix[45]*)
27183    # Just a stub in "old" Irix.  Sigh.
27184    ;;
27185# In the belief that the fix for bug 1223 fixes mlockall() under linux...
27186# *-*-*linux*)
27187#    # there, but more trouble than it is worth for now (resolver problems)
27188#    ;;
27189 *-*-qnx*)
27190    # Apparently there but not working in QNX.  Sigh?
27191    ;;
27192 *-*-sco3.2v5.0.*)
27193    # Just a stub.  Sigh.
27194    ;;
27195 alpha*-dec-osf4*|alpha*-dec-osf5*)
27196    # mlockall is there, as a #define calling memlk via <sys/mman.h>
27197    # Not easy to test for - cheat.
27198    for ac_func in memlk
27199do :
27200  ac_fn_c_check_func "$LINENO" "memlk" "ac_cv_func_memlk"
27201if test "x$ac_cv_func_memlk" = xyes; then :
27202  cat >>confdefs.h <<_ACEOF
27203#define HAVE_MEMLK 1
27204_ACEOF
27205 ac_cv_func_mlockall=yes
27206fi
27207done
27208
27209    for ac_func in mlockall
27210do :
27211  ac_fn_c_check_func "$LINENO" "mlockall" "ac_cv_func_mlockall"
27212if test "x$ac_cv_func_mlockall" = xyes; then :
27213  cat >>confdefs.h <<_ACEOF
27214#define HAVE_MLOCKALL 1
27215_ACEOF
27216
27217fi
27218done
27219
27220    ;;
27221 *) for ac_func in mlockall
27222do :
27223  ac_fn_c_check_func "$LINENO" "mlockall" "ac_cv_func_mlockall"
27224if test "x$ac_cv_func_mlockall" = xyes; then :
27225  cat >>confdefs.h <<_ACEOF
27226#define HAVE_MLOCKALL 1
27227_ACEOF
27228
27229fi
27230done
27231
27232    ;;
27233esac
27234for ac_func in nice plock pututline pututxline readlink rtprio
27235do :
27236  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
27237ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
27238if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
27239  cat >>confdefs.h <<_ACEOF
27240#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
27241_ACEOF
27242
27243fi
27244done
27245
27246case "$host" in
27247 *-*-aix[4-9]*)
27248    # XXX only verified thru AIX6.
27249    # Just a stub in AIX 4.  Sigh.
27250    ;;
27251 *-*-solaris2.5*)
27252    # Just stubs in solaris2.5.  Sigh.
27253    ;;
27254 *) for ac_func in sched_setscheduler
27255do :
27256  ac_fn_c_check_func "$LINENO" "sched_setscheduler" "ac_cv_func_sched_setscheduler"
27257if test "x$ac_cv_func_sched_setscheduler" = xyes; then :
27258  cat >>confdefs.h <<_ACEOF
27259#define HAVE_SCHED_SETSCHEDULER 1
27260_ACEOF
27261
27262fi
27263done
27264
27265    ;;
27266esac
27267for ac_func in setlinebuf setpgid setpriority setsid setvbuf
27268do :
27269  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
27270ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
27271if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
27272  cat >>confdefs.h <<_ACEOF
27273#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
27274_ACEOF
27275
27276fi
27277done
27278
27279for ac_func in strdup strerror setrlimit strchr
27280do :
27281  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
27282ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
27283if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
27284  cat >>confdefs.h <<_ACEOF
27285#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
27286_ACEOF
27287
27288fi
27289done
27290
27291case "$host" in
27292 *-*-aix[4-9]*)
27293    # XXX only verified thru AIX6.
27294    # Just stubs.  Sigh.
27295    ;;
27296 *-*-netbsd1*)
27297    # Just stubs.  Sigh.
27298    ;;
27299 *-*-netbsdelf1*)
27300    # Just stubs.  Sigh.
27301    ;;
27302 *-*-openbsd*)
27303    # Just stubs.  Sigh.
27304    ;;
27305 *)
27306    for ac_func in timer_create
27307do :
27308  ac_fn_c_check_func "$LINENO" "timer_create" "ac_cv_func_timer_create"
27309if test "x$ac_cv_func_timer_create" = xyes; then :
27310  cat >>confdefs.h <<_ACEOF
27311#define HAVE_TIMER_CREATE 1
27312_ACEOF
27313
27314fi
27315done
27316
27317    ;;
27318esac
27319
27320
27321
27322{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for RLIMIT_MEMLOCK" >&5
27323$as_echo_n "checking for RLIMIT_MEMLOCK... " >&6; }
27324if ${ntp_cv_rlimit_memlock+:} false; then :
27325  $as_echo_n "(cached) " >&6
27326else
27327  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27328/* end confdefs.h.  */
27329
27330		#ifdef HAVE_SYS_TYPES_H
27331		# include <sys/types.h>
27332		#endif
27333		#ifdef HAVE_SYS_TIME_H
27334		# include <sys/time.h>
27335		#endif
27336		#ifdef HAVE_SYS_RESOURCE_H
27337		# include <sys/resource.h>
27338		#endif
27339
27340int
27341main ()
27342{
27343
27344		getrlimit(RLIMIT_MEMLOCK, 0);
27345
27346
27347  ;
27348  return 0;
27349}
27350_ACEOF
27351if ac_fn_c_try_compile "$LINENO"; then :
27352  ntp_cv_rlimit_memlock=yes
27353else
27354  ntp_cv_rlimit_memlock=no
27355
27356fi
27357rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27358
27359fi
27360{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_rlimit_memlock" >&5
27361$as_echo "$ntp_cv_rlimit_memlock" >&6; }
27362case "$host" in
27363 *-*-*linux*)
27364    ntp_dflt_rlimit_memlock="-1" ;;
27365 *) ntp_dflt_rlimit_memlock="32" ;;
27366esac
27367case "$ntp_cv_rlimit_memlock" in
27368 yes)
27369
27370    HAVE_RLIMIT_MEMLOCK=" memlock $ntp_dflt_rlimit_memlock"  ;;
27371esac
27372
27373{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for RLIMIT_STACK" >&5
27374$as_echo_n "checking for RLIMIT_STACK... " >&6; }
27375if ${ntp_cv_rlimit_stack+:} false; then :
27376  $as_echo_n "(cached) " >&6
27377else
27378  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27379/* end confdefs.h.  */
27380
27381		#ifdef HAVE_SYS_TYPES_H
27382		# include <sys/types.h>
27383		#endif
27384		#ifdef HAVE_SYS_TIME_H
27385		# include <sys/time.h>
27386		#endif
27387		#ifdef HAVE_SYS_RESOURCE_H
27388		# include <sys/resource.h>
27389		#endif
27390
27391int
27392main ()
27393{
27394
27395		getrlimit(RLIMIT_STACK, 0);
27396
27397
27398  ;
27399  return 0;
27400}
27401_ACEOF
27402if ac_fn_c_try_compile "$LINENO"; then :
27403  ntp_cv_rlimit_stack=yes
27404else
27405  ntp_cv_rlimit_stack=no
27406
27407fi
27408rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27409
27410fi
27411{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_rlimit_stack" >&5
27412$as_echo "$ntp_cv_rlimit_stack" >&6; }
27413case "$ntp_cv_rlimit_stack" in
27414 yes)
27415
27416    HAVE_RLIMIT_STACK=" stacksize 50"
27417esac
27418
27419# HMS: Only if we are doing the MLOCKALL stuff...
27420{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for the default number of 4k stack pages" >&5
27421$as_echo_n "checking for the default number of 4k stack pages... " >&6; }
27422
27423# Check whether --with-stack-limit was given.
27424if test "${with_stack_limit+set}" = set; then :
27425  withval=$with_stack_limit; ans=$withval
27426else
27427  ans=yes
27428
27429fi
27430
27431case "$ans" in
27432 yes | no)
27433    case "$host" in
27434     *-*-openbsd*)
27435	ans=200
27436	;;
27437     *) ans=50
27438        ;;
27439    esac
27440    ;;
27441 [1-9][0-9]*)
27442    ;;
27443 *) as_fn_error $? "\"--with-stack-limit requires an integer argument.\"" "$LINENO" 5
27444    ;;
27445esac
27446{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
27447$as_echo "$ans" >&6; }
27448
27449cat >>confdefs.h <<_ACEOF
27450#define DFLT_RLIMIT_STACK $ans
27451_ACEOF
27452
27453
27454# HMS: only if we have RLIMIT_MEMLOCK
27455{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for the default number of megabytes to MEMLOCK" >&5
27456$as_echo_n "checking for the default number of megabytes to MEMLOCK... " >&6; }
27457
27458# Check whether --with-memlock was given.
27459if test "${with_memlock+set}" = set; then :
27460  withval=$with_memlock; ans=$withval
27461else
27462  ans=yes
27463
27464fi
27465
27466case "$ans" in
27467 yes | no)
27468    ans=$ntp_dflt_rlimit_memlock
27469    ;;
27470 [1-9][0-9]*) ;;
27471 *) as_fn_error $? "\"--with-memlock requires an integer argument.\"" "$LINENO" 5
27472     ;;
27473esac
27474{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
27475$as_echo "$ans" >&6; }
27476
27477cat >>confdefs.h <<_ACEOF
27478#define DFLT_RLIMIT_MEMLOCK $ans
27479_ACEOF
27480
27481
27482
27483
27484# some OSes prefer _exit() in forked children to exit()
27485for ac_func in _exit
27486do :
27487  ac_fn_c_check_func "$LINENO" "_exit" "ac_cv_func__exit"
27488if test "x$ac_cv_func__exit" = xyes; then :
27489  cat >>confdefs.h <<_ACEOF
27490#define HAVE__EXIT 1
27491_ACEOF
27492
27493fi
27494done
27495
27496ntp_worker_child_exit=exit
27497case "$ac_cv_func__exit::$host_os" in
27498 yes::netbsd*)
27499    ntp_worker_child_exit=_exit
27500    ;;
27501 yes::openbsd*)
27502    ntp_worker_child_exit=_exit
27503    ;;
27504esac
27505
27506cat >>confdefs.h <<_ACEOF
27507#define WORKER_CHILD_EXIT $ntp_worker_child_exit
27508_ACEOF
27509
27510
27511for ac_func in umask uname updwtmp updwtmpx
27512do :
27513  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
27514ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
27515if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
27516  cat >>confdefs.h <<_ACEOF
27517#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
27518_ACEOF
27519
27520fi
27521done
27522
27523
27524###
27525
27526# http://bugs.ntp.org/737
27527case "$ac_cv_func_recvmsg" in
27528 yes)
27529    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we need extra help to define struct iovec" >&5
27530$as_echo_n "checking if we need extra help to define struct iovec... " >&6; }
27531if ${ntp_cv_struct_iovec_help+:} false; then :
27532  $as_echo_n "(cached) " >&6
27533else
27534
27535	    compiled=no
27536	    for ntp_cv_struct_iovec_help in '0' '1'; do
27537		cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27538/* end confdefs.h.  */
27539
27540			    #ifdef HAVE_SYS_TYPES_H
27541			    # include <sys/types.h>
27542			    #endif
27543			    #ifdef HAVE_SYS_SOCKET_H
27544			    # include <sys/socket.h>
27545			    #endif
27546			    #if $ntp_cv_struct_iovec_help
27547			    # include <sys/uio.h>
27548			    #endif
27549
27550int
27551main ()
27552{
27553
27554			    void foo(void) {
27555				ssize_t x;
27556				int s = 0;
27557				struct iovec iov;
27558				struct msghdr mh;
27559				int flags = 0;
27560
27561				mh.msg_iov = &iov;
27562				x = recvmsg(s, &mh, flags);
27563			    }
27564
27565
27566  ;
27567  return 0;
27568}
27569_ACEOF
27570if ac_fn_c_try_compile "$LINENO"; then :
27571  compiled=yes ; break 1
27572fi
27573rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27574	    done
27575	    case "$compiled" in
27576	     no)
27577		ntp_cv_struct_iovec_help=0
27578	    esac
27579	    { compiled=; unset compiled;}
27580
27581
27582fi
27583{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_struct_iovec_help" >&5
27584$as_echo "$ntp_cv_struct_iovec_help" >&6; }
27585    case "$ntp_cv_struct_iovec_help" in
27586     1)
27587
27588$as_echo "#define HAVE_SYS_UIO_H 1" >>confdefs.h
27589
27590    esac
27591esac
27592
27593{ $as_echo "$as_me:${as_lineno-$LINENO}: checking number of arguments taken by setpgrp()" >&5
27594$as_echo_n "checking number of arguments taken by setpgrp()... " >&6; }
27595if ${ntp_cv_func_setpgrp_nargs+:} false; then :
27596  $as_echo_n "(cached) " >&6
27597else
27598  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27599/* end confdefs.h.  */
27600
27601		#ifdef HAVE_SYS_TYPES_H
27602		# include <sys/types.h>
27603		#endif
27604		#ifdef HAVE_UNISTD_H
27605		# include <unistd.h>
27606		#endif
27607
27608int
27609main ()
27610{
27611
27612		setpgrp(0, 0);
27613
27614
27615  ;
27616  return 0;
27617}
27618_ACEOF
27619if ac_fn_c_try_compile "$LINENO"; then :
27620  ntp_cv_func_setpgrp_nargs=2
27621else
27622  ntp_cv_func_setpgrp_nargs=0
27623
27624fi
27625rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27626
27627fi
27628{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_func_setpgrp_nargs" >&5
27629$as_echo "$ntp_cv_func_setpgrp_nargs" >&6; }
27630case "$ntp_cv_func_setpgrp_nargs" in
27631 0)
27632
27633$as_echo "#define HAVE_SETPGRP_0 1" >>confdefs.h
27634
27635esac
27636
27637{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we need to declare 'errno'" >&5
27638$as_echo_n "checking if we need to declare 'errno'... " >&6; }
27639if ${ntp_cv_decl_errno+:} false; then :
27640  $as_echo_n "(cached) " >&6
27641else
27642  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27643/* end confdefs.h.  */
27644
27645		#ifdef HAVE_ERRNO_H
27646		# include <errno.h>
27647		#endif
27648
27649int
27650main ()
27651{
27652
27653		errno = 0;
27654
27655
27656  ;
27657  return 0;
27658}
27659_ACEOF
27660if ac_fn_c_try_compile "$LINENO"; then :
27661  ntp_cv_decl_errno=no
27662else
27663  ntp_cv_decl_errno=yes
27664
27665fi
27666rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27667
27668fi
27669{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_decl_errno" >&5
27670$as_echo "$ntp_cv_decl_errno" >&6; }
27671case "$ntp_cv_decl_errno" in
27672 yes)
27673
27674$as_echo "#define DECL_ERRNO 1" >>confdefs.h
27675
27676esac
27677
27678{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we may declare 'h_errno'" >&5
27679$as_echo_n "checking if we may declare 'h_errno'... " >&6; }
27680if ${ntp_cv_decl_h_errno+:} false; then :
27681  $as_echo_n "(cached) " >&6
27682else
27683  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27684/* end confdefs.h.  */
27685
27686		#include <sys/types.h>
27687		#ifdef HAVE_NETINET_IN_H
27688		# include <netinet/in.h>
27689		#endif
27690		#ifdef HAVE_ARPA_NAMESER_H
27691		# include <arpa/nameser.h>
27692		#endif
27693		#ifdef HAVE_NETDB_H
27694		# include <netdb.h>
27695		#endif
27696		#ifdef HAVE_RESOLV_H
27697		# include <resolv.h>
27698		#endif
27699
27700int
27701main ()
27702{
27703
27704		extern int h_errno;
27705
27706
27707  ;
27708  return 0;
27709}
27710_ACEOF
27711if ac_fn_c_try_compile "$LINENO"; then :
27712  ntp_cv_decl_h_errno=yes
27713else
27714  ntp_cv_decl_h_errno=no
27715
27716fi
27717rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27718
27719fi
27720{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_decl_h_errno" >&5
27721$as_echo "$ntp_cv_decl_h_errno" >&6; }
27722case "$ntp_cv_decl_h_errno" in
27723 yes)
27724
27725$as_echo "#define DECL_H_ERRNO 1" >>confdefs.h
27726
27727esac
27728
27729{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if declaring 'syscall()' is ok" >&5
27730$as_echo_n "checking if declaring 'syscall()' is ok... " >&6; }
27731if ${ntp_cv_decl_syscall+:} false; then :
27732  $as_echo_n "(cached) " >&6
27733else
27734  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27735/* end confdefs.h.  */
27736
27737		#ifdef HAVE_SYS_TYPES_H
27738		# include <sys/types.h>
27739		#endif
27740		#ifdef HAVE_UNISTD_H
27741		# include <unistd.h>
27742		#endif
27743
27744int
27745main ()
27746{
27747
27748		extern int syscall (int, ...);
27749
27750
27751  ;
27752  return 0;
27753}
27754	ntp_cv_decl_syscall=yes
27755_ACEOF
27756if ac_fn_c_try_compile "$LINENO"; then :
27757  ntp_cv_decl_syscall=no
27758
27759fi
27760rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27761
27762fi
27763{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_decl_syscall" >&5
27764$as_echo "$ntp_cv_decl_syscall" >&6; }
27765case "$ntp_cv_decl_syscall" in
27766 yes)
27767
27768$as_echo "#define DECL_SYSCALL 1" >>confdefs.h
27769
27770esac
27771
27772case "$host" in
27773 *-*-aix4.3.*)
27774
27775$as_echo "#define DECL_HSTRERROR_0 1" >>confdefs.h
27776		# Needed for XLC under AIX 4.3.2
27777    ;;
27778 *-*-mpeix*)
27779
27780$as_echo "#define DECL_ADJTIME_0 1" >>confdefs.h
27781
27782
27783$as_echo "#define DECL_INET_NTOA_0 1" >>confdefs.h
27784
27785
27786$as_echo "#define DECL_MKTEMP_0 1" >>confdefs.h
27787
27788
27789$as_echo "#define DECL_SELECT_0 1" >>confdefs.h
27790
27791
27792$as_echo "#define DECL_SETITIMER_0 1" >>confdefs.h
27793
27794
27795$as_echo "#define DECL_SYSLOG_0 1" >>confdefs.h
27796
27797
27798$as_echo "#define DECL_TIMEOFDAY_0 1" >>confdefs.h
27799
27800    ;;
27801 *-*-osf[45]*)
27802
27803$as_echo "#define DECL_PLOCK_0 1" >>confdefs.h
27804
27805
27806$as_echo "#define DECL_STIME_1 1" >>confdefs.h
27807
27808    ;;
27809 *-*-qnx*)
27810
27811$as_echo "#define DECL_ADJTIME_0 1" >>confdefs.h
27812
27813    ;;
27814 *-*-riscos4*)
27815
27816$as_echo "#define DECL_ADJTIME_0 1" >>confdefs.h
27817
27818
27819$as_echo "#define DECL_BZERO_0 1" >>confdefs.h
27820
27821
27822$as_echo "#define DECL_IOCTL_0 1" >>confdefs.h
27823
27824
27825$as_echo "#define DECL_IPC_0 1" >>confdefs.h
27826
27827
27828$as_echo "#define DECL_MEMMOVE_0 1" >>confdefs.h
27829
27830
27831$as_echo "#define DECL_MKTEMP_0 1" >>confdefs.h
27832
27833
27834$as_echo "#define DECL_RENAME_0 1" >>confdefs.h
27835
27836
27837$as_echo "#define DECL_SELECT_0 1" >>confdefs.h
27838
27839
27840$as_echo "#define DECL_SETITIMER_0 1" >>confdefs.h
27841
27842
27843$as_echo "#define DECL_SETPRIORITY_0 1" >>confdefs.h
27844
27845
27846$as_echo "#define DECL_STDIO_0 1" >>confdefs.h
27847
27848
27849$as_echo "#define DECL_STRTOL_0 1" >>confdefs.h
27850
27851
27852$as_echo "#define DECL_SYSLOG_0 1" >>confdefs.h
27853
27854
27855$as_echo "#define DECL_TIME_0 1" >>confdefs.h
27856
27857
27858$as_echo "#define DECL_TIMEOFDAY_0 1" >>confdefs.h
27859
27860
27861$as_echo "#define DECL_TOLOWER_0 1" >>confdefs.h
27862
27863    ;;
27864 *-*-solaris2*)
27865
27866$as_echo "#define DECL_MKSTEMP_0 1" >>confdefs.h
27867
27868
27869$as_echo "#define DECL_SETPRIORITY_1 1" >>confdefs.h
27870
27871    case "$host" in
27872     *-*-solaris2.4)
27873
27874$as_echo "#define DECL_TIMEOFDAY_0 1" >>confdefs.h
27875
27876	;;
27877    esac
27878    ;;
27879 *-*-sunos4*)
27880
27881$as_echo "#define DECL_ADJTIME_0 1" >>confdefs.h
27882
27883
27884$as_echo "#define DECL_BCOPY_0 1" >>confdefs.h
27885
27886
27887$as_echo "#define DECL_BZERO_0 1" >>confdefs.h
27888
27889
27890$as_echo "#define DECL_IOCTL_0 1" >>confdefs.h
27891
27892
27893$as_echo "#define DECL_IPC_0 1" >>confdefs.h
27894
27895
27896$as_echo "#define DECL_MEMMOVE_0 1" >>confdefs.h
27897
27898
27899$as_echo "#define DECL_MKTEMP_0 1" >>confdefs.h
27900
27901
27902$as_echo "#define DECL_MKSTEMP_0 1" >>confdefs.h
27903
27904
27905$as_echo "#define DECL_RENAME_0 1" >>confdefs.h
27906
27907
27908$as_echo "#define DECL_SELECT_0 1" >>confdefs.h
27909
27910
27911$as_echo "#define DECL_SETITIMER_0 1" >>confdefs.h
27912
27913
27914$as_echo "#define DECL_SETPRIORITY_0 1" >>confdefs.h
27915
27916
27917$as_echo "#define DECL_SIGVEC_0 1" >>confdefs.h
27918
27919    case "`basename $ac_cv_prog_CC`" in
27920     acc*) ;;
27921     *)
27922$as_echo "#define DECL_STDIO_0 1" >>confdefs.h
27923
27924	;;
27925    esac
27926
27927$as_echo "#define DECL_STRTOL_0 1" >>confdefs.h
27928
27929
27930$as_echo "#define DECL_SYSLOG_0 1" >>confdefs.h
27931
27932
27933$as_echo "#define DECL_TIME_0 1" >>confdefs.h
27934
27935
27936$as_echo "#define DECL_TIMEOFDAY_0 1" >>confdefs.h
27937
27938
27939$as_echo "#define DECL_TOLOWER_0 1" >>confdefs.h
27940
27941
27942$as_echo "#define DECL_TOUPPER_0 1" >>confdefs.h
27943
27944
27945$as_echo "#define DECL_STRERROR_0 1" >>confdefs.h
27946
27947    ;;
27948 *-*-ultrix4*)
27949
27950$as_echo "#define DECL_ADJTIME_0 1" >>confdefs.h
27951
27952
27953$as_echo "#define DECL_BZERO_0 1" >>confdefs.h
27954
27955
27956$as_echo "#define DECL_CFSETISPEED_0 1" >>confdefs.h
27957
27958
27959$as_echo "#define DECL_IOCTL_0 1" >>confdefs.h
27960
27961
27962$as_echo "#define DECL_IPC_0 1" >>confdefs.h
27963
27964
27965$as_echo "#define DECL_MKTEMP_0 1" >>confdefs.h
27966
27967
27968$as_echo "#define DECL_NLIST_0 1" >>confdefs.h
27969
27970
27971$as_echo "#define DECL_PLOCK_0 1" >>confdefs.h
27972
27973
27974$as_echo "#define DECL_SELECT_0 1" >>confdefs.h
27975
27976
27977$as_echo "#define DECL_SETITIMER_0 1" >>confdefs.h
27978
27979
27980$as_echo "#define DECL_SETPRIORITY_0 1" >>confdefs.h
27981
27982
27983$as_echo "#define DECL_STIME_0 1" >>confdefs.h
27984
27985
27986$as_echo "#define DECL_SYSLOG_0 1" >>confdefs.h
27987
27988
27989$as_echo "#define DECL_TIMEOFDAY_0 1" >>confdefs.h
27990
27991    ;;
27992esac
27993
27994case "$host" in
27995 *-*-sco3.2*)
27996
27997$as_echo "#define TERMIOS_NEEDS__SVID3 1" >>confdefs.h
27998
27999    ;;
28000esac
28001
28002case "$host" in
28003 *-*-hpux[567]*)
28004
28005$as_echo "#define NEED_RCVBUF_SLOP 1" >>confdefs.h
28006
28007esac
28008
28009{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we will open the broadcast socket" >&5
28010$as_echo_n "checking if we will open the broadcast socket... " >&6; }
28011if ${ntp_cv_var_open_bcast_socket+:} false; then :
28012  $as_echo_n "(cached) " >&6
28013else
28014
28015	ans=yes
28016	case "$host" in
28017	 *-*-domainos)
28018	    ans=no
28019	esac
28020	ntp_cv_var_open_bcast_socket=$ans
28021
28022
28023fi
28024{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_var_open_bcast_socket" >&5
28025$as_echo "$ntp_cv_var_open_bcast_socket" >&6; }
28026case "$ntp_cv_var_open_bcast_socket" in
28027 yes)
28028
28029$as_echo "#define OPEN_BCAST_SOCKET 1" >>confdefs.h
28030
28031esac
28032
28033case "$host" in
28034 *-*-hpux*)
28035
28036$as_echo "#define NEED_HPUX_FINDCONFIG 1" >>confdefs.h
28037
28038esac
28039
28040{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if process groups are set with -pid" >&5
28041$as_echo_n "checking if process groups are set with -pid... " >&6; }
28042if ${ntp_cv_arg_setpgrp_negpid+:} false; then :
28043  $as_echo_n "(cached) " >&6
28044else
28045
28046	case "$host" in
28047	 *-*-hpux[567]*)
28048	    ans=no
28049	    ;;
28050	 *-*-hpux*)
28051	    ans=yes
28052	    ;;
28053	 *-*-*linux*)
28054	    ans=yes
28055	    ;;
28056	 *-*-sunos3*)
28057	    ans=yes
28058	    ;;
28059	 *-*-ultrix2*)
28060	    ans=yes
28061	    ;;
28062	 *)
28063	    ans=no
28064	    ;;
28065	esac
28066	ntp_cv_arg_setpgrp_negpid=$ans
28067
28068
28069fi
28070{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_arg_setpgrp_negpid" >&5
28071$as_echo "$ntp_cv_arg_setpgrp_negpid" >&6; }
28072case "$ntp_cv_arg_setpgrp_negpid" in
28073 yes)
28074
28075$as_echo "#define UDP_BACKWARDS_SETOWN 1" >>confdefs.h
28076
28077esac
28078
28079{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we need a ctty for F_SETOWN" >&5
28080$as_echo_n "checking if we need a ctty for F_SETOWN... " >&6; }
28081if ${ntp_cv_func_ctty_for_f_setown+:} false; then :
28082  $as_echo_n "(cached) " >&6
28083else
28084
28085	case "$host" in
28086	 *-*-bsdi[23]*)
28087	    ans=yes
28088	    ;;
28089	 *-*-freebsd*)
28090	    ans=yes
28091	    ;;
28092	# NetBSD versions prior to 3.99.8 require a CTTY for F_SETOWN,
28093	# while later versions will fail a ioctl(TIOCSCTTY, 0) call in
28094	# some cases and so should not have USE_FSETOWNCTTY.  "netbsd"
28095	# in $host may be followed by "aout", "ecoff", or "elf".
28096	 *-*-netbsd*[a-z]3.[0-8]*|*-*-netbsd*[a-z][0-2].*|*-*-netbsd*[a-z]3.99.[0-7])
28097	    ans=yes
28098	    ;;
28099	 *-*-netbsd3.[0-8]*|*-*-netbsd[0-2].*|*-*-netbsd3.99.[0-7])
28100	    ans=yes
28101	    ;;
28102	 *-*-openbsd*)
28103	    ans=yes
28104	    ;;
28105	 *-*-osf*)
28106	    ans=yes
28107	    ;;
28108	 *-*-darwin*)
28109	    ans=yes
28110	    ;;
28111	 *)
28112	    ans=no
28113	    ;;
28114	esac
28115	ntp_cv_func_ctty_for_f_setown=$ans
28116
28117
28118fi
28119{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_func_ctty_for_f_setown" >&5
28120$as_echo "$ntp_cv_func_ctty_for_f_setown" >&6; }
28121case "$ntp_cv_func_ctty_for_f_setown" in
28122 yes)
28123
28124$as_echo "#define USE_FSETOWNCTTY 1" >>confdefs.h
28125
28126esac
28127
28128{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the OS clears cached routes when more specifics become available" >&5
28129$as_echo_n "checking if the OS clears cached routes when more specifics become available... " >&6; }
28130if ${ntp_cv_os_routeupdates+:} false; then :
28131  $as_echo_n "(cached) " >&6
28132else
28133
28134	case "$host" in
28135	 *-*-netbsd*)
28136	    ans=yes
28137	    ;;
28138	 *)
28139	    ans=no
28140	    ;;
28141	esac
28142	ntp_cv_os_routeupdates=$ans
28143
28144
28145fi
28146{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_os_routeupdates" >&5
28147$as_echo "$ntp_cv_os_routeupdates" >&6; }
28148case "$ntp_cv_os_routeupdates" in
28149 yes)
28150
28151$as_echo "#define OS_MISSES_SPECIFIC_ROUTE_UPDATES 1" >>confdefs.h
28152
28153esac
28154
28155{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the wildcard socket needs REUSEADDR to bind other addresses" >&5
28156$as_echo_n "checking if the wildcard socket needs REUSEADDR to bind other addresses... " >&6; }
28157if ${ntp_cv_os_wildcardreuse+:} false; then :
28158  $as_echo_n "(cached) " >&6
28159else
28160
28161	case "$host" in
28162	 *-*-*linux*)
28163	    ans=yes
28164	    ;;
28165	 *) ans=no
28166	    ;;
28167	esac
28168	ntp_cv_os_wildcardreuse=$ans
28169
28170
28171fi
28172{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_os_wildcardreuse" >&5
28173$as_echo "$ntp_cv_os_wildcardreuse" >&6; }
28174case "$ntp_cv_os_wildcardreuse" in
28175 yes)
28176
28177$as_echo "#define OS_NEEDS_REUSEADDR_FOR_IFADDRBIND 1" >>confdefs.h
28178
28179esac
28180
28181case "$host" in
28182 *-*-aix*)
28183
28184$as_echo "#define NLIST_EXTRA_INDIRECTION 1" >>confdefs.h
28185
28186esac
28187
28188{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a minimum recommended value of tickadj" >&5
28189$as_echo_n "checking for a minimum recommended value of tickadj... " >&6; }
28190if ${ntp_cv_var_min_rec_tickadj+:} false; then :
28191  $as_echo_n "(cached) " >&6
28192else
28193
28194	ans=no
28195	case "$host" in
28196	 *-*-aix*)
28197	    ans=40
28198	    ;;
28199	esac
28200	ntp_cv_var_min_rec_tickadj=$ans
28201
28202
28203fi
28204{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_var_min_rec_tickadj" >&5
28205$as_echo "$ntp_cv_var_min_rec_tickadj" >&6; }
28206case "$ntp_cv_var_min_rec_tickadj" in
28207 ''|no)
28208    ;;
28209 *)
28210
28211cat >>confdefs.h <<_ACEOF
28212#define MIN_REC_TICKADJ $ntp_cv_var_min_rec_tickadj
28213_ACEOF
28214
28215esac
28216
28217{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the TTY code permits PARENB and IGNPAR" >&5
28218$as_echo_n "checking if the TTY code permits PARENB and IGNPAR... " >&6; }
28219if ${ntp_cv_no_parenb_ignpar+:} false; then :
28220  $as_echo_n "(cached) " >&6
28221else
28222
28223	ans=no
28224	case "$host" in
28225	 i?86-*-*linux*)
28226	    ans=yes
28227	    ;;
28228	 mips-sgi-irix*)
28229	    ans=yes
28230	    ;;
28231	 i?86-*-freebsd[123].*)
28232	    ;;
28233	 i?86-*-freebsd*)
28234	    ans=yes
28235	    ;;
28236	 *-*-unicosmp*)
28237	    ans=yes
28238	    ;;
28239	esac
28240	ntp_cv_no_parenb_ignpar=$ans
28241
28242
28243fi
28244{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_no_parenb_ignpar" >&5
28245$as_echo "$ntp_cv_no_parenb_ignpar" >&6; }
28246case "$ntp_cv_no_parenb_ignpar" in
28247 yes)
28248
28249$as_echo "#define NO_PARENB_IGNPAR 1" >>confdefs.h
28250
28251esac
28252
28253{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we're including processing time debugging code" >&5
28254$as_echo_n "checking if we're including processing time debugging code... " >&6; }
28255# Check whether --enable-debug-timing was given.
28256if test "${enable_debug_timing+set}" = set; then :
28257  enableval=$enable_debug_timing; ntp_ok=$enableval
28258else
28259  ntp_ok=no
28260
28261fi
28262
28263case "$ntp_ok" in
28264 yes)
28265
28266$as_echo "#define DEBUG_TIMING 1" >>confdefs.h
28267
28268esac
28269{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
28270$as_echo "$ntp_ok" >&6; }
28271
28272{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a the number of minutes in a DST adjustment" >&5
28273$as_echo_n "checking for a the number of minutes in a DST adjustment... " >&6; }
28274# Check whether --enable-dst-minutes was given.
28275if test "${enable_dst_minutes+set}" = set; then :
28276  enableval=$enable_dst_minutes; ans=$enableval
28277else
28278  ans=60
28279
28280fi
28281
28282
28283cat >>confdefs.h <<_ACEOF
28284#define DSTMINUTES $ans
28285_ACEOF
28286
28287{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
28288$as_echo "$ans" >&6; }
28289
28290{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if ntpd will retry permanent DNS failures" >&5
28291$as_echo_n "checking if ntpd will retry permanent DNS failures... " >&6; }
28292# Check whether --enable-ignore-dns-errors was given.
28293if test "${enable_ignore_dns_errors+set}" = set; then :
28294  enableval=$enable_ignore_dns_errors; ans=$enableval
28295else
28296  ans=no
28297
28298fi
28299
28300case "$ans" in
28301 yes)
28302
28303$as_echo "#define IGNORE_DNS_ERRORS 1" >>confdefs.h
28304
28305esac
28306{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
28307$as_echo "$ans" >&6; }
28308
28309{ $as_echo "$as_me:${as_lineno-$LINENO}: checking availability of ntp_{adj,get}time()" >&5
28310$as_echo_n "checking availability of ntp_{adj,get}time()... " >&6; }
28311if ${ntp_cv_var_ntp_syscalls+:} false; then :
28312  $as_echo_n "(cached) " >&6
28313else
28314
28315	ntp_cv_var_ntp_syscalls=no
28316	case "$ac_cv_func_ntp_adjtime$ac_cv_func_ntp_gettime$ac_cv_func___adjtimex" in
28317	 yesyes*)
28318	    ntp_cv_var_ntp_syscalls=libc
28319	    ;;
28320	 *yes)
28321	    ntp_cv_var_ntp_syscalls=inline
28322	    ;;
28323	 *)
28324	    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28325/* end confdefs.h.  */
28326
28327			#include <sys/syscall.h>
28328			#if !defined(SYS_ntp_gettime) || !defined(SYS_ntp_adjtime)
28329			# error
28330			#endif
28331
28332_ACEOF
28333if ac_fn_c_try_cpp "$LINENO"; then :
28334  ntp_cv_var_ntp_syscalls=kernel
28335
28336fi
28337rm -f conftest.err conftest.i conftest.$ac_ext
28338	    ;;
28339	 esac
28340
28341
28342fi
28343{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_var_ntp_syscalls" >&5
28344$as_echo "$ntp_cv_var_ntp_syscalls" >&6; }
28345case "$ntp_cv_var_ntp_syscalls" in
28346 libc)
28347
28348$as_echo "#define NTP_SYSCALLS_LIBC 1" >>confdefs.h
28349
28350    ;;
28351 kernel)
28352
28353$as_echo "#define NTP_SYSCALLS_STD 1" >>confdefs.h
28354
28355    ;;
28356esac
28357
28358{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if sys/timex.h has STA_FLL" >&5
28359$as_echo_n "checking if sys/timex.h has STA_FLL... " >&6; }
28360if ${ntp_cv_var_sta_fll+:} false; then :
28361  $as_echo_n "(cached) " >&6
28362else
28363  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28364/* end confdefs.h.  */
28365
28366		#include <sys/timex.h>
28367		#ifndef STA_FLL
28368		# error
28369		#endif
28370
28371_ACEOF
28372if ac_fn_c_try_cpp "$LINENO"; then :
28373  ntp_cv_var_sta_fll=yes
28374else
28375  ntp_cv_var_sta_fll=no
28376
28377fi
28378rm -f conftest.err conftest.i conftest.$ac_ext
28379
28380fi
28381{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_var_sta_fll" >&5
28382$as_echo "$ntp_cv_var_sta_fll" >&6; }
28383
28384{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we have kernel PLL support" >&5
28385$as_echo_n "checking if we have kernel PLL support... " >&6; }
28386if ${ntp_cv_var_kernel_pll+:} false; then :
28387  $as_echo_n "(cached) " >&6
28388else
28389  	case "$ac_cv_header_sys_timex_h$ntp_cv_struct_ntptimeval$ntp_cv_var_sta_fll$ntp_cv_var_ntp_syscalls" in
28390	 *no*)
28391	    ntp_cv_var_kernel_pll=no
28392	    ;;
28393	 *) ntp_cv_var_kernel_pll=yes
28394	    ;;
28395	esac
28396
28397
28398fi
28399{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_var_kernel_pll" >&5
28400$as_echo "$ntp_cv_var_kernel_pll" >&6; }
28401case "$ntp_cv_var_kernel_pll" in
28402 yes)
28403
28404$as_echo "#define KERNEL_PLL 1" >>confdefs.h
28405
28406esac
28407
28408{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if SIOCGIFCONF returns buffer size in the buffer" >&5
28409$as_echo_n "checking if SIOCGIFCONF returns buffer size in the buffer... " >&6; }
28410if ${ntp_cv_size_returned_in_buffer+:} false; then :
28411  $as_echo_n "(cached) " >&6
28412else
28413
28414	ans=no
28415	case "$host" in
28416	 *-fujitsu-uxp*)
28417	    ans=yes
28418	    ;;
28419	 *-ncr-sysv4*)
28420	    ans=yes
28421	    ;;
28422	 *-univel-sysv*)
28423	    ans=yes
28424	    ;;
28425	esac
28426	ntp_cv_size_returned_in_buffer=$ans
28427
28428
28429fi
28430{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_size_returned_in_buffer" >&5
28431$as_echo "$ntp_cv_size_returned_in_buffer" >&6; }
28432case "$ntp_cv_size_returned_in_buffer" in
28433 yes)
28434
28435$as_echo "#define SIZE_RETURNED_IN_BUFFER 1" >>confdefs.h
28436
28437esac
28438
28439# Check for ioctls TIOCGPPSEV
28440{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for TTY PPS ioctl TIOCGPPSEV" >&5
28441$as_echo_n "checking for TTY PPS ioctl TIOCGPPSEV... " >&6; }
28442case "$ac_cv_header_termios_h" in
28443 yes)
28444    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28445/* end confdefs.h.  */
28446
28447	    #include <termios.h>
28448	    #ifndef TIOCGPPSEV
28449	    # error
28450	    #endif
28451
28452_ACEOF
28453if ac_fn_c_try_cpp "$LINENO"; then :
28454  ntp_ok=yes
28455else
28456  ntp_ok=no
28457
28458fi
28459rm -f conftest.err conftest.i conftest.$ac_ext
28460    ;;
28461 *)
28462    ntp_ok=no
28463    ;;
28464esac
28465case "$ntp_ok" in
28466 yes)
28467
28468$as_echo "#define HAVE_TIOCGPPSEV 1" >>confdefs.h
28469
28470esac
28471{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
28472$as_echo "$ntp_ok" >&6; }
28473
28474# Check for ioctls TIOCSPPS
28475{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for TTY PPS ioctl TIOCSPPS" >&5
28476$as_echo_n "checking for TTY PPS ioctl TIOCSPPS... " >&6; }
28477case "$ac_cv_header_termios_h" in
28478 yes)
28479    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28480/* end confdefs.h.  */
28481
28482	    #include <termios.h>
28483	    #ifndef TIOCSPPS
28484	    # error
28485	    #endif
28486
28487_ACEOF
28488if ac_fn_c_try_cpp "$LINENO"; then :
28489  ntp_ok=yes
28490else
28491  ntp_ok=no
28492
28493fi
28494rm -f conftest.err conftest.i conftest.$ac_ext
28495    ;;
28496 *)
28497    ntp_ok=no
28498    ;;
28499esac
28500case "$ntp_ok" in
28501 yes)
28502
28503$as_echo "#define HAVE_TIOCSPPS 1" >>confdefs.h
28504
28505esac
28506{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
28507$as_echo "$ntp_ok" >&6; }
28508
28509# Check for ioctls CIOGETEV
28510{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for TTY PPS ioctl CIOGETEV" >&5
28511$as_echo_n "checking for TTY PPS ioctl CIOGETEV... " >&6; }
28512case "$ac_cv_header_sys_ppsclock_h" in
28513 yes)
28514    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28515/* end confdefs.h.  */
28516
28517	    #include <sys/ppsclock.h>
28518	    #ifndef CIOGETEV
28519	    # error
28520	    #endif
28521
28522_ACEOF
28523if ac_fn_c_try_cpp "$LINENO"; then :
28524  ntp_ok=yes
28525else
28526  ntp_ok=no
28527
28528fi
28529rm -f conftest.err conftest.i conftest.$ac_ext
28530    ;;
28531 *)
28532    ntp_ok=no
28533    ;;
28534esac
28535case "$ntp_ok" in
28536 yes)
28537
28538$as_echo "#define HAVE_CIOGETEV 1" >>confdefs.h
28539
28540esac
28541{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
28542$as_echo "$ntp_ok" >&6; }
28543
28544# ATOM/PPSAPI stuff.
28545
28546ntp_atom_ok=yes
28547
28548# Check for header timepps.h, if found then we have PPS API (Draft RFC) stuff.
28549
28550# The PPSAPI headers need "inline" ($ac_cv_c_inline='inline')
28551# The PPSAPI needs struct timespec.
28552# The PPSAPI also needs a timepps header.
28553
28554case "$ac_cv_c_inline$ntp_cv_struct_timespec" in
28555 inlineyes)
28556    case "$ac_cv_header_timepps_h$ac_cv_header_sys_timepps_h$host_os" in
28557     *yes* | *sunos* | *solaris* | *sco* | *netbsd* )
28558
28559$as_echo "#define HAVE_PPSAPI 1" >>confdefs.h
28560
28561	ntp_jupiter_ok=yes
28562	ntp_oncore_ok=yes
28563	ntp_parse_ok=yes
28564	ntp_ripe_ncc_ok=yes
28565	;;
28566    esac
28567    ;;
28568esac
28569
28570# Check for ioctls TIOCGSERIAL, TIOCSSERIAL, ASYNC_PPS_CD_POS, ASYNC_PPS_CD_NEG
28571ac_fn_c_check_header_mongrel "$LINENO" "linux/serial.h" "ac_cv_header_linux_serial_h" "$ac_includes_default"
28572if test "x$ac_cv_header_linux_serial_h" = xyes; then :
28573
28574fi
28575
28576
28577case "$ac_cv_header_sys_ppsclock_h$ac_cv_header_linux_serial_h" in
28578  yesyes)
28579    { $as_echo "$as_me:${as_lineno-$LINENO}: checking ioctl TIOCGSERIAL, TIOCSSERIAL, ASYNC_PPS_CD_POS, ASYNC_PPS_CD_NEG" >&5
28580$as_echo_n "checking ioctl TIOCGSERIAL, TIOCSSERIAL, ASYNC_PPS_CD_POS, ASYNC_PPS_CD_NEG... " >&6; }
28581    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28582/* end confdefs.h.  */
28583
28584	    #include <sys/time.h>
28585	    typedef int u_int;
28586	    #include <sys/ppsclock.h>
28587	    #include <linux/serial.h>
28588
28589	    #ifndef TIOCGSERIAL
28590	    # error
28591	    #endif
28592	    #ifndef TIOCSSERIAL
28593	    # error
28594	    #endif
28595	    #ifndef ASYNC_PPS_CD_POS
28596	    # error
28597	    #endif
28598	    #ifndef ASYNC_PPS_CD_NEG
28599	    # error
28600	    #endif
28601	    #ifndef CIOGETEV
28602	    # error
28603	    #endif
28604
28605_ACEOF
28606if ac_fn_c_try_cpp "$LINENO"; then :
28607  ntp_ok=yes
28608else
28609  ntp_ok=no
28610
28611fi
28612rm -f conftest.err conftest.i conftest.$ac_ext
28613    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
28614$as_echo "$ntp_ok" >&6; }
28615    ;;
28616  *)
28617    ntp_ok=no
28618    ;;
28619esac
28620case "$ntp_ok" in
28621 yes)
28622
28623$as_echo "#define HAVE_TIO_SERIAL_STUFF 1" >>confdefs.h
28624
28625esac
28626
28627# Check for SHMEM_STATUS support
28628{ $as_echo "$as_me:${as_lineno-$LINENO}: checking SHMEM_STATUS support" >&5
28629$as_echo_n "checking SHMEM_STATUS support... " >&6; }
28630case "$ac_cv_header_sys_mman_h" in
28631 yes)
28632    ntp_ok=yes
28633    ;;
28634 *)
28635    ntp_ok=no
28636    ;;
28637esac
28638case "$ntp_ok" in
28639 yes)
28640
28641$as_echo "#define ONCORE_SHMEM_STATUS 1" >>confdefs.h
28642
28643esac
28644{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
28645$as_echo "$ntp_ok" >&6; }
28646
28647ntp_refclock=no
28648
28649# HPUX only, and by explicit request
28650{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Datum/Bancomm bc635/VME interface" >&5
28651$as_echo_n "checking Datum/Bancomm bc635/VME interface... " >&6; }
28652# Check whether --enable-BANCOMM was given.
28653if test "${enable_BANCOMM+set}" = set; then :
28654  enableval=$enable_BANCOMM; ntp_ok=$enableval
28655else
28656  ntp_ok=no
28657
28658fi
28659
28660case "$ntp_ok" in
28661 yes)
28662    ntp_refclock=yes
28663
28664$as_echo "#define CLOCK_BANC 1" >>confdefs.h
28665
28666    ;;
28667esac
28668{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
28669$as_echo "$ntp_ok" >&6; }
28670case "$ntp_ok$host" in
28671 yes*-*-hpux*) ;;
28672 yes*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** But the expected answer is... no ***" >&5
28673$as_echo "$as_me: WARNING: *** But the expected answer is... no ***" >&2;} ;;
28674esac
28675
28676#HPUX only, and only by explicit request
28677{ $as_echo "$as_me:${as_lineno-$LINENO}: checking TrueTime GPS receiver/VME interface" >&5
28678$as_echo_n "checking TrueTime GPS receiver/VME interface... " >&6; }
28679# Check whether --enable-GPSVME was given.
28680if test "${enable_GPSVME+set}" = set; then :
28681  enableval=$enable_GPSVME; ntp_ok=$enableval
28682else
28683  ntp_ok=no
28684
28685fi
28686
28687case "$ntp_ok" in
28688 yes)
28689    ntp_refclock=yes
28690
28691$as_echo "#define CLOCK_GPSVME 1" >>confdefs.h
28692
28693    ;;
28694esac
28695{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
28696$as_echo "$ntp_ok" >&6; }
28697case "$ntp_ok$host" in
28698 yes*-*-hpux*) ;;
28699 yes*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** But the expected answer is... no ***" >&5
28700$as_echo "$as_me: WARNING: *** But the expected answer is... no ***" >&2;} ;;
28701esac
28702
28703{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for PCL720 clock support" >&5
28704$as_echo_n "checking for PCL720 clock support... " >&6; }
28705case "$ac_cv_header_machine_inline_h$ac_cv_header_sys_pcl720_h$ac_cv_header_sys_i8253_h" in
28706 yesyesyes)
28707
28708$as_echo "#define CLOCK_PPS720 1" >>confdefs.h
28709
28710    ans=yes
28711    ;;
28712 *)
28713    ans=no
28714    ;;
28715esac
28716{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
28717$as_echo "$ans" >&6; }
28718
28719{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for default inclusion of all suitable non-PARSE clocks" >&5
28720$as_echo_n "checking for default inclusion of all suitable non-PARSE clocks... " >&6; }
28721# Check whether --enable-all-clocks was given.
28722if test "${enable_all_clocks+set}" = set; then :
28723  enableval=$enable_all_clocks; ntp_eac=$enableval
28724else
28725  ntp_eac=yes
28726
28727fi
28728
28729{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_eac" >&5
28730$as_echo "$ntp_eac" >&6; }
28731
28732# HMS: Should we also require ntp_parse_ok?
28733{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we have support for PARSE clocks" >&5
28734$as_echo_n "checking if we have support for PARSE clocks... " >&6; }
28735case "$ntp_atom_ok$ac_cv_header_termio_h$ac_cv_header_termios_h" in
28736 yes*yes*)
28737    ntp_canparse=yes
28738    ;;
28739 *) ntp_canparse=no
28740    ;;
28741esac
28742{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_canparse" >&5
28743$as_echo "$ntp_canparse" >&6; }
28744
28745{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we have support for audio clocks" >&5
28746$as_echo_n "checking if we have support for audio clocks... " >&6; }
28747case "$ac_cv_header_sun_audioio_h$ac_cv_header_sys_audioio_h$ac_cv_header_machine_soundcard_h$ac_cv_header_sys_soundcard_h" in
28748 *yes*)
28749    ntp_canaudio=yes
28750
28751$as_echo "#define HAVE_AUDIO /**/" >>confdefs.h
28752
28753    ;;
28754 *) ntp_canaudio=no ;;
28755esac
28756{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_canaudio" >&5
28757$as_echo "$ntp_canaudio" >&6; }
28758
28759{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we have support for the SHM refclock interface" >&5
28760$as_echo_n "checking if we have support for the SHM refclock interface... " >&6; }
28761case "$ac_cv_header_sys_ipc_h$ac_cv_header_sys_shm_h" in
28762 yesyes)
28763    ntp_canshm=yes
28764    ;;
28765 *) ntp_canshm=no ;;
28766esac
28767{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_canshm" >&5
28768$as_echo "$ntp_canshm" >&6; }
28769
28770# Test for termios TIOCMBIS modem control (ACTS, Heath, Palisade)
28771{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for termios modem control" >&5
28772$as_echo_n "checking for termios modem control... " >&6; }
28773if ${ntp_cv_modem_control+:} false; then :
28774  $as_echo_n "(cached) " >&6
28775else
28776  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28777/* end confdefs.h.  */
28778
28779		#ifdef HAVE_UNISTD_H
28780		# include <unistd.h>
28781		#endif
28782		#ifdef HAVE_TERMIOS_H
28783		# include <termios.h>
28784		#endif
28785		#ifdef HAVE_SYS_IOCTL_H
28786		# include <sys/ioctl.h>
28787		#endif
28788
28789int
28790main ()
28791{
28792
28793		int	dtr = TIOCM_DTR;
28794
28795		ioctl(1, TIOCMBIS, (char *)&dtr);
28796
28797
28798  ;
28799  return 0;
28800}
28801_ACEOF
28802if ac_fn_c_try_compile "$LINENO"; then :
28803  ntp_cv_modem_control=yes
28804else
28805  ntp_cv_modem_control=no
28806
28807fi
28808rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28809
28810fi
28811{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_modem_control" >&5
28812$as_echo "$ntp_cv_modem_control" >&6; }
28813case "$ntp_eac::$ntp_cv_modem_control" in
28814 yes::yes)
28815    ntp_enable_all_modem_control_clocks=yes
28816    ;;
28817 *)
28818    ntp_enable_all_modem_control_clocks=no
28819    ;;
28820esac
28821
28822# Requires modem control
28823{ $as_echo "$as_me:${as_lineno-$LINENO}: checking ACTS modem service" >&5
28824$as_echo_n "checking ACTS modem service... " >&6; }
28825# Check whether --enable-ACTS was given.
28826if test "${enable_ACTS+set}" = set; then :
28827  enableval=$enable_ACTS; ntp_ok=$enableval
28828else
28829  ntp_ok=$ntp_enable_all_modem_control_clocks
28830
28831fi
28832
28833case "$ntp_ok" in
28834 yes)
28835    ntp_refclock=yes
28836
28837$as_echo "#define CLOCK_ACTS 1" >>confdefs.h
28838
28839    ;;
28840esac
28841{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
28842$as_echo "$ntp_ok" >&6; }
28843
28844{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Arbiter 1088A/B GPS receiver" >&5
28845$as_echo_n "checking Arbiter 1088A/B GPS receiver... " >&6; }
28846# Check whether --enable-ARBITER was given.
28847if test "${enable_ARBITER+set}" = set; then :
28848  enableval=$enable_ARBITER; ntp_ok=$enableval
28849else
28850  ntp_ok=$ntp_eac
28851
28852fi
28853
28854case "$ntp_ok" in
28855 yes)
28856    ntp_refclock=yes
28857
28858$as_echo "#define CLOCK_ARBITER 1" >>confdefs.h
28859
28860    ;;
28861esac
28862{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
28863$as_echo "$ntp_ok" >&6; }
28864
28865{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Arcron MSF receiver" >&5
28866$as_echo_n "checking Arcron MSF receiver... " >&6; }
28867# Check whether --enable-ARCRON_MSF was given.
28868if test "${enable_ARCRON_MSF+set}" = set; then :
28869  enableval=$enable_ARCRON_MSF; ntp_ok=$enableval
28870else
28871  ntp_ok=$ntp_eac
28872
28873fi
28874
28875case "$ntp_ok" in
28876 yes)
28877    ntp_refclock=yes
28878
28879$as_echo "#define CLOCK_ARCRON_MSF 1" >>confdefs.h
28880
28881    ;;
28882esac
28883{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
28884$as_echo "$ntp_ok" >&6; }
28885
28886{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Austron 2200A/2201A GPS receiver" >&5
28887$as_echo_n "checking Austron 2200A/2201A GPS receiver... " >&6; }
28888# Check whether --enable-AS2201 was given.
28889if test "${enable_AS2201+set}" = set; then :
28890  enableval=$enable_AS2201; ntp_ok=$enableval
28891else
28892  ntp_ok=$ntp_eac
28893
28894fi
28895
28896case "$ntp_ok" in
28897 yes)
28898    ntp_refclock=yes
28899
28900$as_echo "#define CLOCK_AS2201 1" >>confdefs.h
28901
28902    ;;
28903esac
28904{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
28905$as_echo "$ntp_ok" >&6; }
28906
28907{ $as_echo "$as_me:${as_lineno-$LINENO}: checking ATOM PPS interface" >&5
28908$as_echo_n "checking ATOM PPS interface... " >&6; }
28909# Check whether --enable-ATOM was given.
28910if test "${enable_ATOM+set}" = set; then :
28911  enableval=$enable_ATOM; ntp_ok=$enableval
28912else
28913  ntp_ok=$ntp_eac
28914
28915fi
28916
28917case "$ntp_atom_ok" in
28918 no) ntp_ok=no ;;
28919esac
28920case "$ntp_ok" in
28921 yes)
28922    ntp_refclock=yes
28923
28924$as_echo "#define CLOCK_ATOM 1" >>confdefs.h
28925
28926    ;;
28927esac
28928{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
28929$as_echo "$ntp_ok" >&6; }
28930
28931{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Chrono-log K-series WWVB receiver" >&5
28932$as_echo_n "checking Chrono-log K-series WWVB receiver... " >&6; }
28933# Check whether --enable-CHRONOLOG was given.
28934if test "${enable_CHRONOLOG+set}" = set; then :
28935  enableval=$enable_CHRONOLOG; ntp_ok=$enableval
28936else
28937  ntp_ok=$ntp_eac
28938
28939fi
28940
28941case "$ntp_ok" in
28942 yes)
28943    ntp_refclock=yes
28944
28945$as_echo "#define CLOCK_CHRONOLOG 1" >>confdefs.h
28946
28947    ;;
28948esac
28949{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
28950$as_echo "$ntp_ok" >&6; }
28951
28952{ $as_echo "$as_me:${as_lineno-$LINENO}: checking CHU modem/decoder" >&5
28953$as_echo_n "checking CHU modem/decoder... " >&6; }
28954# Check whether --enable-CHU was given.
28955if test "${enable_CHU+set}" = set; then :
28956  enableval=$enable_CHU; ntp_ok=$enableval
28957else
28958  ntp_ok=$ntp_eac
28959
28960fi
28961
28962case "$ntp_ok" in
28963 yes)
28964    ntp_refclock=yes
28965
28966$as_echo "#define CLOCK_CHU 1" >>confdefs.h
28967
28968    ;;
28969esac
28970{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
28971$as_echo "$ntp_ok" >&6; }
28972ntp_refclock_chu=$ntp_ok
28973
28974{ $as_echo "$as_me:${as_lineno-$LINENO}: checking CHU audio/decoder" >&5
28975$as_echo_n "checking CHU audio/decoder... " >&6; }
28976# Check whether --enable-AUDIO-CHU was given.
28977if test "${enable_AUDIO_CHU+set}" = set; then :
28978  enableval=$enable_AUDIO_CHU; ntp_ok=$enableval
28979else
28980
28981	case "$ntp_eac$ntp_refclock_chu$ntp_canaudio" in
28982	 *no*)	ntp_ok=no  ;;
28983	 *)	ntp_ok=yes ;;
28984	esac
28985
28986
28987fi
28988
28989{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
28990$as_echo "$ntp_ok" >&6; }
28991# We used to check for sunos/solaris target...
28992case "$ntp_ok$ntp_refclock_chu$ntp_canaudio" in
28993 yes*no*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** But the expected answer is...no ***" >&5
28994$as_echo "$as_me: WARNING: *** But the expected answer is...no ***" >&2;}
28995esac
28996
28997# Not under HP-UX
28998{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Datum Programmable Time System" >&5
28999$as_echo_n "checking Datum Programmable Time System... " >&6; }
29000# Check whether --enable-DATUM was given.
29001if test "${enable_DATUM+set}" = set; then :
29002  enableval=$enable_DATUM; ntp_ok=$enableval
29003else
29004
29005	case "$ac_cv_header_termios_h" in
29006	 yes)
29007	    ntp_ok=$ntp_eac
29008	    ;;
29009	 *) ntp_ok=no
29010	    ;;
29011	esac
29012
29013
29014fi
29015
29016case "$ntp_ok" in
29017 yes)
29018    ntp_refclock=yes
29019
29020$as_echo "#define CLOCK_DATUM 1" >>confdefs.h
29021
29022    ;;
29023esac
29024{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29025$as_echo "$ntp_ok" >&6; }
29026
29027{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Dumb generic hh:mm:ss local clock" >&5
29028$as_echo_n "checking Dumb generic hh:mm:ss local clock... " >&6; }
29029# Check whether --enable-DUMBCLOCK was given.
29030if test "${enable_DUMBCLOCK+set}" = set; then :
29031  enableval=$enable_DUMBCLOCK; ntp_ok=$enableval
29032else
29033  ntp_ok=$ntp_eac
29034
29035fi
29036
29037case "$ntp_ok" in
29038 yes)
29039    ntp_refclock=yes
29040
29041$as_echo "#define CLOCK_DUMBCLOCK 1" >>confdefs.h
29042
29043    ;;
29044esac
29045{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29046$as_echo "$ntp_ok" >&6; }
29047
29048{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Forum Graphic GPS" >&5
29049$as_echo_n "checking Forum Graphic GPS... " >&6; }
29050# Check whether --enable-FG was given.
29051if test "${enable_FG+set}" = set; then :
29052  enableval=$enable_FG; ntp_ok=$enableval
29053else
29054  ntp_ok=$ntp_eac
29055
29056fi
29057
29058case "$ntp_ok" in
29059 yes)
29060    ntp_refclock=yes
29061
29062$as_echo "#define CLOCK_FG 1" >>confdefs.h
29063
29064    ;;
29065esac
29066{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29067$as_echo "$ntp_ok" >&6; }
29068
29069# Requires modem control
29070{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Heath GC-1000 WWV/WWVH receiver" >&5
29071$as_echo_n "checking Heath GC-1000 WWV/WWVH receiver... " >&6; }
29072# Check whether --enable-HEATH was given.
29073if test "${enable_HEATH+set}" = set; then :
29074  enableval=$enable_HEATH; ntp_ok=$enableval
29075else
29076  ntp_ok=$ntp_enable_all_modem_control_clocks
29077
29078fi
29079
29080case "$ntp_ok" in
29081 yes)
29082    ntp_refclock=yes
29083
29084$as_echo "#define CLOCK_HEATH 1" >>confdefs.h
29085
29086    ;;
29087esac
29088{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29089$as_echo "$ntp_ok" >&6; }
29090
29091{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for hopf serial clock device" >&5
29092$as_echo_n "checking for hopf serial clock device... " >&6; }
29093# Check whether --enable-HOPFSERIAL was given.
29094if test "${enable_HOPFSERIAL+set}" = set; then :
29095  enableval=$enable_HOPFSERIAL; ntp_ok=$enableval
29096else
29097  ntp_ok=$ntp_eac
29098
29099fi
29100
29101case "$ntp_ok" in
29102 yes)
29103    ntp_refclock=yes
29104
29105$as_echo "#define CLOCK_HOPF_SERIAL 1" >>confdefs.h
29106
29107    ;;
29108esac
29109{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29110$as_echo "$ntp_ok" >&6; }
29111
29112{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for hopf PCI clock 6039" >&5
29113$as_echo_n "checking for hopf PCI clock 6039... " >&6; }
29114# Check whether --enable-HOPFPCI was given.
29115if test "${enable_HOPFPCI+set}" = set; then :
29116  enableval=$enable_HOPFPCI; ntp_ok=$enableval
29117else
29118  ntp_ok=$ntp_eac
29119
29120fi
29121
29122case "$ntp_ok" in
29123 yes)
29124    ntp_refclock=yes
29125
29126$as_echo "#define CLOCK_HOPF_PCI 1" >>confdefs.h
29127
29128    ;;
29129esac
29130{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29131$as_echo "$ntp_ok" >&6; }
29132
29133{ $as_echo "$as_me:${as_lineno-$LINENO}: checking HP 58503A GPS receiver" >&5
29134$as_echo_n "checking HP 58503A GPS receiver... " >&6; }
29135# Check whether --enable-HPGPS was given.
29136if test "${enable_HPGPS+set}" = set; then :
29137  enableval=$enable_HPGPS; ntp_ok=$enableval
29138else
29139  ntp_ok=$ntp_eac
29140
29141fi
29142
29143case "$ntp_ok" in
29144 yes)
29145    ntp_refclock=yes
29146
29147$as_echo "#define CLOCK_HPGPS 1" >>confdefs.h
29148
29149    ;;
29150esac
29151{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29152$as_echo "$ntp_ok" >&6; }
29153
29154{ $as_echo "$as_me:${as_lineno-$LINENO}: checking IRIG audio decoder" >&5
29155$as_echo_n "checking IRIG audio decoder... " >&6; }
29156# Check whether --enable-IRIG was given.
29157if test "${enable_IRIG+set}" = set; then :
29158  enableval=$enable_IRIG; ntp_ok=$enableval
29159else
29160
29161	case "$ntp_eac$ntp_canaudio" in
29162	 *no*)	ntp_ok=no  ;;
29163	 *)	ntp_ok=yes ;;
29164	esac
29165
29166
29167fi
29168
29169case "$ntp_ok" in
29170 yes)
29171    ntp_refclock=yes
29172
29173$as_echo "#define CLOCK_IRIG 1" >>confdefs.h
29174
29175    ;;
29176esac
29177{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29178$as_echo "$ntp_ok" >&6; }
29179case "$ntp_ok$ntp_canaudio" in
29180 yesno) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** But the expected answer is... no ***" >&5
29181$as_echo "$as_me: WARNING: *** But the expected answer is... no ***" >&2;}
29182esac
29183
29184{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for JJY receiver" >&5
29185$as_echo_n "checking for JJY receiver... " >&6; }
29186# Check whether --enable-JJY was given.
29187if test "${enable_JJY+set}" = set; then :
29188  enableval=$enable_JJY; ntp_ok=$enableval
29189else
29190  ntp_ok=$ntp_eac
29191
29192fi
29193
29194case "$ntp_ok" in
29195 yes)
29196    ntp_refclock=yes
29197
29198$as_echo "#define CLOCK_JJY 1" >>confdefs.h
29199
29200    ;;
29201esac
29202{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29203$as_echo "$ntp_ok" >&6; }
29204
29205{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Rockwell Jupiter GPS receiver" >&5
29206$as_echo_n "checking Rockwell Jupiter GPS receiver... " >&6; }
29207# Check whether --enable-JUPITER was given.
29208if test "${enable_JUPITER+set}" = set; then :
29209  enableval=$enable_JUPITER; ntp_ok=$enableval
29210else
29211  ntp_ok=$ntp_eac
29212fi
29213
29214case "$ntp_jupiter_ok" in
29215 no) ntp_ok=no ;;
29216esac
29217case "$ntp_ok" in
29218 yes)
29219    ntp_refclock=yes
29220
29221$as_echo "#define CLOCK_JUPITER 1" >>confdefs.h
29222
29223    ;;
29224esac
29225{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29226$as_echo "$ntp_ok" >&6; }
29227
29228{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Leitch CSD 5300 Master Clock System Driver" >&5
29229$as_echo_n "checking Leitch CSD 5300 Master Clock System Driver... " >&6; }
29230# Check whether --enable-LEITCH was given.
29231if test "${enable_LEITCH+set}" = set; then :
29232  enableval=$enable_LEITCH; ntp_ok=$enableval
29233else
29234  ntp_ok=$ntp_eac
29235
29236fi
29237
29238case "$ntp_ok" in
29239 yes)
29240    ntp_refclock=yes
29241
29242$as_echo "#define CLOCK_LEITCH 1" >>confdefs.h
29243
29244    ;;
29245esac
29246{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29247$as_echo "$ntp_ok" >&6; }
29248
29249{ $as_echo "$as_me:${as_lineno-$LINENO}: checking local clock reference" >&5
29250$as_echo_n "checking local clock reference... " >&6; }
29251# Check whether --enable-LOCAL-CLOCK was given.
29252if test "${enable_LOCAL_CLOCK+set}" = set; then :
29253  enableval=$enable_LOCAL_CLOCK; ntp_ok=$enableval
29254else
29255  ntp_ok=$ntp_eac
29256
29257fi
29258
29259case "$ntp_ok" in
29260 yes)
29261    ntp_refclock=yes
29262
29263$as_echo "#define CLOCK_LOCAL 1" >>confdefs.h
29264
29265    ;;
29266esac
29267{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29268$as_echo "$ntp_ok" >&6; }
29269
29270
29271# Not Ultrix
29272{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Magnavox MX4200 GPS receiver" >&5
29273$as_echo_n "checking Magnavox MX4200 GPS receiver... " >&6; }
29274# Check whether --enable-MX4200 was given.
29275if test "${enable_MX4200+set}" = set; then :
29276  enableval=$enable_MX4200; ntp_ok=$enableval
29277else
29278
29279	case "$ac_cv_var_ppsclock" in
29280	 yes)
29281	    ntp_ok=$ntp_eac
29282	    ;;
29283	 *)
29284	    ntp_ok=no
29285	    ;;
29286	esac
29287
29288
29289fi
29290
29291case "$ntp_ok" in
29292 yes)
29293    ntp_refclock=yes
29294
29295$as_echo "#define CLOCK_MX4200 1" >>confdefs.h
29296
29297    ;;
29298esac
29299{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29300$as_echo "$ntp_ok" >&6; }
29301case "$ntp_ok$host" in
29302 yes*-*-ultrix*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** But the expected answer is... no ***" >&5
29303$as_echo "$as_me: WARNING: *** But the expected answer is... no ***" >&2;}
29304esac
29305
29306{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for NeoClock4X receiver" >&5
29307$as_echo_n "checking for NeoClock4X receiver... " >&6; }
29308# Check whether --enable-NEOCLOCK4X was given.
29309if test "${enable_NEOCLOCK4X+set}" = set; then :
29310  enableval=$enable_NEOCLOCK4X; ntp_ok=$enableval
29311else
29312  ntp_ok=$ntp_eac
29313
29314fi
29315
29316case "$ntp_ok" in
29317 yes)
29318    ntp_refclock=yes
29319
29320$as_echo "#define CLOCK_NEOCLOCK4X 1" >>confdefs.h
29321
29322    ;;
29323esac
29324{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29325$as_echo "$ntp_ok" >&6; }
29326
29327{ $as_echo "$as_me:${as_lineno-$LINENO}: checking NMEA GPS receiver" >&5
29328$as_echo_n "checking NMEA GPS receiver... " >&6; }
29329# Check whether --enable-NMEA was given.
29330if test "${enable_NMEA+set}" = set; then :
29331  enableval=$enable_NMEA; ntp_ok=$enableval
29332else
29333  ntp_ok=$ntp_eac
29334
29335fi
29336
29337case "$ntp_ok" in
29338 yes)
29339    ntp_refclock=yes
29340
29341$as_echo "#define CLOCK_NMEA 1" >>confdefs.h
29342
29343    ;;
29344esac
29345{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29346$as_echo "$ntp_ok" >&6; }
29347
29348for ac_func in strtoll
29349do :
29350  ac_fn_c_check_func "$LINENO" "strtoll" "ac_cv_func_strtoll"
29351if test "x$ac_cv_func_strtoll" = xyes; then :
29352  cat >>confdefs.h <<_ACEOF
29353#define HAVE_STRTOLL 1
29354_ACEOF
29355
29356fi
29357done
29358
29359{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for GPSD JSON receiver" >&5
29360$as_echo_n "checking for GPSD JSON receiver... " >&6; }
29361# Check whether --enable-GPSD was given.
29362if test "${enable_GPSD+set}" = set; then :
29363  enableval=$enable_GPSD; ntp_ok=$enableval
29364else
29365  case "$ac_cv_func_strtoll" in
29366     yes) ntp_ok=$ntp_eac ;;
29367     *)   ntp_ok="no" ;;
29368    esac
29369
29370fi
29371
29372case "$ntp_ok" in
29373 yes)
29374    ntp_refclock=yes
29375
29376$as_echo "#define CLOCK_GPSDJSON 1" >>confdefs.h
29377
29378    ;;
29379esac
29380{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29381$as_echo "$ntp_ok" >&6; }
29382
29383{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ONCORE Motorola VP/UT Oncore GPS" >&5
29384$as_echo_n "checking for ONCORE Motorola VP/UT Oncore GPS... " >&6; }
29385# Check whether --enable-ONCORE was given.
29386if test "${enable_ONCORE+set}" = set; then :
29387  enableval=$enable_ONCORE; ntp_ok=$enableval
29388else
29389  ntp_ok=$ntp_eac
29390
29391fi
29392
29393case "$ntp_oncore_ok" in
29394 no) ntp_ok=no ;;
29395esac
29396case "$ntp_ok" in
29397 yes)
29398    ntp_refclock=yes
29399
29400$as_echo "#define CLOCK_ONCORE 1" >>confdefs.h
29401
29402    ;;
29403esac
29404{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29405$as_echo "$ntp_ok" >&6; }
29406
29407# Requires modem control
29408{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Palisade clock" >&5
29409$as_echo_n "checking for Palisade clock... " >&6; }
29410# Check whether --enable-PALISADE was given.
29411if test "${enable_PALISADE+set}" = set; then :
29412  enableval=$enable_PALISADE; ntp_ok=$enableval
29413else
29414  ntp_ok=$ntp_enable_all_modem_control_clocks
29415
29416fi
29417
29418case "$ntp_ok" in
29419 yes)
29420    ntp_refclock=yes
29421
29422$as_echo "#define CLOCK_PALISADE 1" >>confdefs.h
29423
29424    ;;
29425esac
29426{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29427$as_echo "$ntp_ok" >&6; }
29428
29429{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Conrad parallel port radio clock" >&5
29430$as_echo_n "checking Conrad parallel port radio clock... " >&6; }
29431# Check whether --enable-PCF was given.
29432if test "${enable_PCF+set}" = set; then :
29433  enableval=$enable_PCF; ntp_ok=$enableval
29434else
29435  ntp_ok=$ntp_eac
29436
29437fi
29438
29439case "$ntp_ok" in
29440 yes)
29441    ntp_refclock=yes
29442
29443$as_echo "#define CLOCK_PCF 1" >>confdefs.h
29444
29445    ;;
29446esac
29447{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29448$as_echo "$ntp_ok" >&6; }
29449
29450{ $as_echo "$as_me:${as_lineno-$LINENO}: checking PST/Traconex 1020 WWV/WWVH receiver" >&5
29451$as_echo_n "checking PST/Traconex 1020 WWV/WWVH receiver... " >&6; }
29452# Check whether --enable-PST was given.
29453if test "${enable_PST+set}" = set; then :
29454  enableval=$enable_PST; ntp_ok=$enableval
29455else
29456  ntp_ok=$ntp_eac
29457
29458fi
29459
29460case "$ntp_ok" in
29461 yes)
29462    ntp_refclock=yes
29463
29464$as_echo "#define CLOCK_PST 1" >>confdefs.h
29465
29466    ;;
29467esac
29468{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29469$as_echo "$ntp_ok" >&6; }
29470
29471{ $as_echo "$as_me:${as_lineno-$LINENO}: checking RIPENCC specific Trimble driver" >&5
29472$as_echo_n "checking RIPENCC specific Trimble driver... " >&6; }
29473# Check whether --enable-RIPENCC was given.
29474if test "${enable_RIPENCC+set}" = set; then :
29475  enableval=$enable_RIPENCC; ntp_ok=$enableval
29476else
29477  ntp_ok=no
29478
29479fi
29480
29481# 020629: HMS: s/$ntp_eac -> -/no because of ptr += sprintf(ptr, ...) usage
29482case "$ntp_ripe_ncc_ok" in
29483 no) ntp_ok=no ;;
29484esac
29485case "$ntp_ok" in
29486 yes)
29487    ntp_refclock=yes
29488
29489$as_echo "#define CLOCK_RIPENCC /**/" >>confdefs.h
29490
29491    ;;
29492esac
29493{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29494$as_echo "$ntp_ok" >&6; }
29495
29496# Danny Meyer says SHM compiles (with a few warnings) under Win32.
29497# For *IX, we need sys/ipc.h and sys/shm.h.
29498{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for SHM clock attached thru shared memory" >&5
29499$as_echo_n "checking for SHM clock attached thru shared memory... " >&6; }
29500# Check whether --enable-SHM was given.
29501if test "${enable_SHM+set}" = set; then :
29502  enableval=$enable_SHM; ntp_ok=$enableval
29503else
29504
29505	case "$ntp_eac$ntp_canshm" in
29506	 *no*)	ntp_ok=no  ;;
29507	 *)	ntp_ok=yes ;;
29508	esac
29509
29510
29511fi
29512
29513case "$ntp_ok" in
29514 yes)
29515    ntp_refclock=yes
29516
29517$as_echo "#define CLOCK_SHM 1" >>confdefs.h
29518
29519    ;;
29520esac
29521{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29522$as_echo "$ntp_ok" >&6; }
29523
29524{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Spectracom 8170/Netclock/2 WWVB receiver" >&5
29525$as_echo_n "checking Spectracom 8170/Netclock/2 WWVB receiver... " >&6; }
29526# Check whether --enable-SPECTRACOM was given.
29527if test "${enable_SPECTRACOM+set}" = set; then :
29528  enableval=$enable_SPECTRACOM; ntp_ok=$enableval
29529else
29530  ntp_ok=$ntp_eac
29531
29532fi
29533
29534case "$ntp_ok" in
29535 yes)
29536    ntp_refclock=yes
29537
29538$as_echo "#define CLOCK_SPECTRACOM 1" >>confdefs.h
29539
29540    ;;
29541esac
29542{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29543$as_echo "$ntp_ok" >&6; }
29544
29545{ $as_echo "$as_me:${as_lineno-$LINENO}: checking KSI/Odetics TPRO/S GPS receiver/IRIG interface" >&5
29546$as_echo_n "checking KSI/Odetics TPRO/S GPS receiver/IRIG interface... " >&6; }
29547# Check whether --enable-TPRO was given.
29548if test "${enable_TPRO+set}" = set; then :
29549  enableval=$enable_TPRO; ntp_ok=$enableval
29550else
29551
29552	case "$ac_cv_header_sys_tpro_h" in
29553	 yes)
29554	    ntp_ok=$ntp_eac
29555	    ;;
29556	 *)
29557	    ntp_ok=no
29558	    ;;
29559	esac
29560
29561
29562fi
29563
29564case "$ntp_ok" in
29565 yes)
29566    ntp_refclock=yes
29567
29568$as_echo "#define CLOCK_TPRO 1" >>confdefs.h
29569
29570    ;;
29571esac
29572{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29573$as_echo "$ntp_ok" >&6; }
29574case "$ntp_ok$ac_cv_header_sys_tpro" in
29575 yesno) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** But the expected answer is... no ***" >&5
29576$as_echo "$as_me: WARNING: *** But the expected answer is... no ***" >&2;}
29577esac
29578
29579# Not on a vax-dec-bsd
29580{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Kinemetrics/TrueTime receivers" >&5
29581$as_echo_n "checking Kinemetrics/TrueTime receivers... " >&6; }
29582# Check whether --enable-TRUETIME was given.
29583if test "${enable_TRUETIME+set}" = set; then :
29584  enableval=$enable_TRUETIME; ntp_ok=$enableval
29585else
29586
29587	case "$host" in
29588	 vax-dec-bsd)
29589	    ntp_ok=no
29590	    ;;
29591	 *)
29592	    ntp_ok=$ntp_eac
29593	    ;;
29594	esac
29595
29596
29597fi
29598
29599case "$ntp_ok" in
29600 yes)
29601    ntp_refclock=yes
29602
29603$as_echo "#define CLOCK_TRUETIME 1" >>confdefs.h
29604
29605    ;;
29606esac
29607{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29608$as_echo "$ntp_ok" >&6; }
29609case "$ntp_ok$host" in
29610 yesvax-dec-bsd) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** But the expected answer is... no ***" >&5
29611$as_echo "$as_me: WARNING: *** But the expected answer is... no ***" >&2;}
29612esac
29613
29614{ $as_echo "$as_me:${as_lineno-$LINENO}: checking TrueTime 560 IRIG-B decoder" >&5
29615$as_echo_n "checking TrueTime 560 IRIG-B decoder... " >&6; }
29616# Check whether --enable-TT560 was given.
29617if test "${enable_TT560+set}" = set; then :
29618  enableval=$enable_TT560; ntp_ok=$enableval
29619else
29620  ntp_ok=no
29621
29622fi
29623
29624case "$ntp_ok" in
29625 yes)
29626    ntp_refclock=yes
29627
29628$as_echo "#define CLOCK_TT560 /**/" >>confdefs.h
29629
29630    ;;
29631esac
29632{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29633$as_echo "$ntp_ok" >&6; }
29634
29635{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Ultralink M320 WWVB receiver" >&5
29636$as_echo_n "checking Ultralink M320 WWVB receiver... " >&6; }
29637# Check whether --enable-ULINK was given.
29638if test "${enable_ULINK+set}" = set; then :
29639  enableval=$enable_ULINK; ntp_ok=$enableval
29640else
29641  ntp_ok=$ntp_eac
29642
29643fi
29644
29645case "$ntp_ok" in
29646 yes)
29647    ntp_refclock=yes
29648
29649$as_echo "#define CLOCK_ULINK 1" >>confdefs.h
29650
29651    ;;
29652esac
29653{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29654$as_echo "$ntp_ok" >&6; }
29655
29656{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Spectracom TSYNC PCI timing board" >&5
29657$as_echo_n "checking Spectracom TSYNC PCI timing board... " >&6; }
29658# Check whether --enable-TSYNCPCI was given.
29659if test "${enable_TSYNCPCI+set}" = set; then :
29660  enableval=$enable_TSYNCPCI; ntp_ok=$enableval
29661else
29662
29663	case "$host" in
29664	 *-*-*linux*)
29665	    ntp_ok=$ntp_eac
29666	    ;;
29667	 *)
29668	    ntp_ok=no
29669	esac
29670
29671
29672fi
29673
29674case "$ntp_ok" in
29675 yes)
29676    ntp_refclock=yes
29677
29678$as_echo "#define CLOCK_TSYNCPCI 1" >>confdefs.h
29679
29680    ;;
29681esac
29682{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29683$as_echo "$ntp_ok" >&6; }
29684
29685{ $as_echo "$as_me:${as_lineno-$LINENO}: checking WWV receiver" >&5
29686$as_echo_n "checking WWV receiver... " >&6; }
29687# Check whether --enable-WWV was given.
29688if test "${enable_WWV+set}" = set; then :
29689  enableval=$enable_WWV; ntp_ok=$enableval
29690else
29691
29692	case "$ntp_eac$ntp_canaudio" in
29693	 *no*)	ntp_ok=no  ;;
29694	 *)	ntp_ok=yes ;;
29695	esac
29696
29697
29698fi
29699
29700case "$ntp_ok" in
29701 yes)
29702    ntp_refclock=yes
29703
29704$as_echo "#define CLOCK_WWV 1" >>confdefs.h
29705
29706    ;;
29707esac
29708{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29709$as_echo "$ntp_ok" >&6; }
29710case "$ntp_ok$ntp_canaudio" in
29711 yesno) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** But the expected answer is... no ***" >&5
29712$as_echo "$as_me: WARNING: *** But the expected answer is... no ***" >&2;}
29713esac
29714
29715{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Zyfer receiver" >&5
29716$as_echo_n "checking for Zyfer receiver... " >&6; }
29717# Check whether --enable-ZYFER was given.
29718if test "${enable_ZYFER+set}" = set; then :
29719  enableval=$enable_ZYFER; ntp_ok=$enableval
29720else
29721  ntp_ok=$ntp_eac
29722
29723fi
29724
29725case "$ntp_ok" in
29726 yes)
29727    ntp_refclock=yes
29728
29729$as_echo "#define CLOCK_ZYFER 1" >>confdefs.h
29730
29731    ;;
29732esac
29733{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29734$as_echo "$ntp_ok" >&6; }
29735
29736{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for default inclusion of all suitable PARSE clocks" >&5
29737$as_echo_n "checking for default inclusion of all suitable PARSE clocks... " >&6; }
29738# Check whether --enable-parse-clocks was given.
29739if test "${enable_parse_clocks+set}" = set; then :
29740  enableval=$enable_parse_clocks; ntp_eapc=$enableval
29741else
29742
29743	case "$ntp_eac" in
29744	 yes)	ntp_eapc=$ntp_canparse ;;
29745	 *)	ntp_eapc=no ;;
29746	esac
29747	# Delete the next line one of these days
29748	ntp_eapc=no
29749
29750
29751fi
29752
29753{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_eapc" >&5
29754$as_echo "$ntp_eapc" >&6; }
29755
29756case "$ntp_eac$ntp_eapc$ntp_canparse" in
29757 noyes*)
29758    as_fn_error $? "\"--enable-parse-clocks\" requires \"--enable-all-clocks\"." "$LINENO" 5
29759    ;;
29760 yesyesno)
29761    as_fn_error $? "You said \"--enable-parse-clocks\" but PARSE isn't supported on this platform!" "$LINENO" 5
29762    ;;
29763esac
29764
29765ntp_libparse=no
29766ntp_parseutil=no
29767ntp_rawdcf=no
29768
29769{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Diem Computime Radio Clock" >&5
29770$as_echo_n "checking Diem Computime Radio Clock... " >&6; }
29771# Check whether --enable-COMPUTIME was given.
29772if test "${enable_COMPUTIME+set}" = set; then :
29773  enableval=$enable_COMPUTIME; ntp_ok=$enableval
29774else
29775  ntp_ok=$ntp_eapc
29776
29777fi
29778
29779case "$ntp_ok" in
29780 yes)
29781    ntp_libparse=yes
29782    ntp_refclock=yes
29783
29784$as_echo "#define CLOCK_COMPUTIME 1" >>confdefs.h
29785
29786    ;;
29787esac
29788{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29789$as_echo "$ntp_ok" >&6; }
29790case "$ntp_ok$ntp_canparse" in
29791 yesno)
29792    as_fn_error $? "That's a parse clock and this system doesn't support it!" "$LINENO" 5
29793esac
29794
29795{ $as_echo "$as_me:${as_lineno-$LINENO}: checking ELV/DCF7000 clock" >&5
29796$as_echo_n "checking ELV/DCF7000 clock... " >&6; }
29797# Check whether --enable-DCF7000 was given.
29798if test "${enable_DCF7000+set}" = set; then :
29799  enableval=$enable_DCF7000; ntp_ok=$enableval
29800else
29801  ntp_ok=$ntp_eapc
29802
29803fi
29804
29805case "$ntp_ok" in
29806 yes)
29807    ntp_libparse=yes
29808    ntp_refclock=yes
29809
29810$as_echo "#define CLOCK_DCF7000 1" >>confdefs.h
29811
29812    ;;
29813esac
29814{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29815$as_echo "$ntp_ok" >&6; }
29816case "$ntp_ok$ntp_canparse" in
29817 yesno)
29818    as_fn_error $? "That's a parse clock and this system doesn't support it!" "$LINENO" 5
29819esac
29820
29821{ $as_echo "$as_me:${as_lineno-$LINENO}: checking HOPF 6021 clock" >&5
29822$as_echo_n "checking HOPF 6021 clock... " >&6; }
29823# Check whether --enable-HOPF6021 was given.
29824if test "${enable_HOPF6021+set}" = set; then :
29825  enableval=$enable_HOPF6021; ntp_ok=$enableval
29826else
29827  ntp_ok=$ntp_eapc
29828
29829fi
29830
29831case "$ntp_ok" in
29832 yes)
29833    ntp_libparse=yes
29834    ntp_refclock=yes
29835
29836$as_echo "#define CLOCK_HOPF6021 1" >>confdefs.h
29837
29838    ;;
29839esac
29840{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29841$as_echo "$ntp_ok" >&6; }
29842case "$ntp_ok$ntp_canparse" in
29843 yesno)
29844    as_fn_error $? "That's a parse clock and this system doesn't support it!" "$LINENO" 5
29845esac
29846
29847{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Meinberg clocks" >&5
29848$as_echo_n "checking Meinberg clocks... " >&6; }
29849# Check whether --enable-MEINBERG was given.
29850if test "${enable_MEINBERG+set}" = set; then :
29851  enableval=$enable_MEINBERG; ntp_ok=$enableval
29852else
29853  ntp_ok=$ntp_eapc
29854
29855fi
29856
29857case "$ntp_ok" in
29858 yes)
29859    ntp_libparse=yes
29860    ntp_refclock=yes
29861
29862$as_echo "#define CLOCK_MEINBERG 1" >>confdefs.h
29863
29864    ;;
29865esac
29866{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29867$as_echo "$ntp_ok" >&6; }
29868case "$ntp_ok$ntp_canparse" in
29869 yesno)
29870    as_fn_error $? "That's a parse clock and this system doesn't support it!" "$LINENO" 5
29871esac
29872
29873{ $as_echo "$as_me:${as_lineno-$LINENO}: checking DCF77 raw time code" >&5
29874$as_echo_n "checking DCF77 raw time code... " >&6; }
29875# Check whether --enable-RAWDCF was given.
29876if test "${enable_RAWDCF+set}" = set; then :
29877  enableval=$enable_RAWDCF; ntp_ok=$enableval
29878else
29879  ntp_ok=$ntp_eapc
29880
29881fi
29882
29883case "$ntp_ok" in
29884 yes)
29885    ntp_libparse=yes
29886    ntp_parseutil=yes
29887    ntp_refclock=yes
29888    ntp_rawdcf=yes
29889
29890$as_echo "#define CLOCK_RAWDCF 1" >>confdefs.h
29891
29892    ;;
29893esac
29894{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29895$as_echo "$ntp_ok" >&6; }
29896case "$ntp_ok$ntp_canparse" in
29897 yesno)
29898    as_fn_error $? "That's a parse clock and this system doesn't support it!" "$LINENO" 5
29899esac
29900
29901case "$ntp_rawdcf" in
29902 yes)
29903    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we must enable parity for RAWDCF" >&5
29904$as_echo_n "checking if we must enable parity for RAWDCF... " >&6; }
29905if ${ntp_cv_rawdcf_parity+:} false; then :
29906  $as_echo_n "(cached) " >&6
29907else
29908
29909	    ans=no
29910	    case "$host" in
29911	     *-*-*linux*)
29912		ans=yes
29913		;;
29914	    esac
29915	    ntp_cv_rawdcf_parity=$ans
29916
29917
29918fi
29919{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_rawdcf_parity" >&5
29920$as_echo "$ntp_cv_rawdcf_parity" >&6; }
29921    case "$ntp_cv_rawdcf_parity" in
29922     yes)
29923
29924$as_echo "#define RAWDCF_NO_IGNPAR 1" >>confdefs.h
29925 ;;
29926    esac
29927esac
29928
29929{ $as_echo "$as_me:${as_lineno-$LINENO}: checking RCC 8000 clock" >&5
29930$as_echo_n "checking RCC 8000 clock... " >&6; }
29931# Check whether --enable-RCC8000 was given.
29932if test "${enable_RCC8000+set}" = set; then :
29933  enableval=$enable_RCC8000; ntp_ok=$enableval
29934else
29935  ntp_ok=$ntp_eapc
29936
29937fi
29938
29939case "$ntp_ok" in
29940 yes)
29941    ntp_libparse=yes
29942    ntp_refclock=yes
29943
29944$as_echo "#define CLOCK_RCC8000 1" >>confdefs.h
29945
29946    ;;
29947esac
29948{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29949$as_echo "$ntp_ok" >&6; }
29950case "$ntp_ok$ntp_canparse" in
29951 yesno)
29952    as_fn_error $? "That's a parse clock and this system doesn't support it!" "$LINENO" 5
29953esac
29954
29955{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Schmid DCF77 clock" >&5
29956$as_echo_n "checking Schmid DCF77 clock... " >&6; }
29957# Check whether --enable-SCHMID was given.
29958if test "${enable_SCHMID+set}" = set; then :
29959  enableval=$enable_SCHMID; ntp_ok=$enableval
29960else
29961  ntp_ok=$ntp_eapc
29962
29963fi
29964
29965case "$ntp_ok" in
29966 yes)
29967    ntp_libparse=yes
29968    ntp_refclock=yes
29969
29970$as_echo "#define CLOCK_SCHMID 1" >>confdefs.h
29971
29972    ;;
29973esac
29974{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
29975$as_echo "$ntp_ok" >&6; }
29976case "$ntp_ok$ntp_canparse" in
29977 yesno)
29978    as_fn_error $? "That's a parse clock and this system doesn't support it!" "$LINENO" 5
29979esac
29980
29981{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Trimble GPS receiver/TAIP protocol" >&5
29982$as_echo_n "checking Trimble GPS receiver/TAIP protocol... " >&6; }
29983# Check whether --enable-TRIMTAIP was given.
29984if test "${enable_TRIMTAIP+set}" = set; then :
29985  enableval=$enable_TRIMTAIP; ntp_ok=$enableval
29986else
29987  ntp_ok=$ntp_eapc
29988
29989fi
29990
29991case "$ntp_ok" in
29992 yes)
29993    ntp_libparse=yes
29994    ntp_refclock=yes
29995
29996$as_echo "#define CLOCK_TRIMTAIP 1" >>confdefs.h
29997
29998    ;;
29999esac
30000{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
30001$as_echo "$ntp_ok" >&6; }
30002case "$ntp_ok$ntp_canparse" in
30003 yesno)
30004    as_fn_error $? "That's a parse clock and this system doesn't support it!" "$LINENO" 5
30005esac
30006
30007{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Trimble GPS receiver/TSIP protocol" >&5
30008$as_echo_n "checking Trimble GPS receiver/TSIP protocol... " >&6; }
30009# Check whether --enable-TRIMTSIP was given.
30010if test "${enable_TRIMTSIP+set}" = set; then :
30011  enableval=$enable_TRIMTSIP; ntp_ok=$enableval
30012else
30013  ntp_ok=$ntp_eapc
30014
30015fi
30016
30017case "$ntp_ok" in
30018 yes)
30019    ntp_libparse=yes
30020    ntp_refclock=yes
30021
30022$as_echo "#define CLOCK_TRIMTSIP 1" >>confdefs.h
30023
30024    ;;
30025esac
30026{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
30027$as_echo "$ntp_ok" >&6; }
30028case "$ntp_ok$ntp_canparse" in
30029 yesno)
30030    as_fn_error $? "That's a parse clock and this system doesn't support it!" "$LINENO" 5
30031esac
30032
30033{ $as_echo "$as_me:${as_lineno-$LINENO}: checking WHARTON 400A Series clock" >&5
30034$as_echo_n "checking WHARTON 400A Series clock... " >&6; }
30035# Check whether --enable-WHARTON was given.
30036if test "${enable_WHARTON+set}" = set; then :
30037  enableval=$enable_WHARTON; ntp_ok=$enableval
30038else
30039  ntp_ok=$ntp_eapc
30040
30041fi
30042
30043case "$ntp_ok" in
30044 yes)
30045    ntp_libparse=yes
30046    ntp_refclock=yes
30047
30048$as_echo "#define CLOCK_WHARTON_400A 1" >>confdefs.h
30049
30050    ;;
30051esac
30052{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
30053$as_echo "$ntp_ok" >&6; }
30054case "$ntp_ok$ntp_canparse" in
30055 yesno)
30056    as_fn_error $? "That's a parse clock and this system doesn't support it!" "$LINENO" 5
30057esac
30058
30059{ $as_echo "$as_me:${as_lineno-$LINENO}: checking VARITEXT clock" >&5
30060$as_echo_n "checking VARITEXT clock... " >&6; }
30061# Check whether --enable-VARITEXT was given.
30062if test "${enable_VARITEXT+set}" = set; then :
30063  enableval=$enable_VARITEXT; ntp_ok=$enableval
30064else
30065  ntp_ok=$ntp_eapc
30066
30067fi
30068
30069case "$ntp_ok" in
30070 yes)
30071    ntp_libparse=yes
30072    ntp_refclock=yes
30073
30074$as_echo "#define CLOCK_VARITEXT 1" >>confdefs.h
30075
30076    ;;
30077esac
30078{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
30079$as_echo "$ntp_ok" >&6; }
30080case "$ntp_ok$ntp_canparse" in
30081 yesno)
30082    as_fn_error $? "That's a parse clock and this system doesn't support it!" "$LINENO" 5
30083esac
30084
30085{ $as_echo "$as_me:${as_lineno-$LINENO}: checking SEL240X clock" >&5
30086$as_echo_n "checking SEL240X clock... " >&6; }
30087# Check whether --enable-SEL240X was given.
30088if test "${enable_SEL240X+set}" = set; then :
30089  enableval=$enable_SEL240X; ntp_ok=$enableval
30090else
30091  ntp_ok=$ntp_eapc
30092fi
30093
30094if test "$ntp_ok" = "yes"; then
30095    ntp_libparse=yes
30096    ntp_refclock=yes
30097
30098$as_echo "#define CLOCK_SEL240X 1" >>confdefs.h
30099
30100fi
30101{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
30102$as_echo "$ntp_ok" >&6; }
30103case "$ntp_ok$ntp_canparse" in
30104 yesno)
30105    as_fn_error $? "That's a parse clock and this system doesn't support it!" "$LINENO" 5
30106    ;;
30107esac
30108
30109
30110
30111
30112
30113
30114{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we need to make and use the parse libraries" >&5
30115$as_echo_n "checking if we need to make and use the parse libraries... " >&6; }
30116ans=no
30117case "$ntp_libparse" in
30118 yes)
30119    ans=yes
30120
30121$as_echo "#define CLOCK_PARSE 1" >>confdefs.h
30122
30123    LIBPARSE=../libparse/libparse.a
30124    MAKE_LIBPARSE=libparse.a
30125    # HMS: check_y2k trips the 34 year problem now...
30126    false && MAKE_CHECK_Y2K=check_y2k
30127esac
30128{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
30129$as_echo "$ans" >&6; }
30130
30131
30132
30133
30134VER_SUFFIX=
30135
30136
30137
30138
30139# Check whether --with-crypto was given.
30140if test "${with_crypto+set}" = set; then :
30141  withval=$with_crypto;
30142fi
30143
30144
30145# Check whether --with-openssl-libdir was given.
30146if test "${with_openssl_libdir+set}" = set; then :
30147  withval=$with_openssl_libdir;
30148fi
30149
30150
30151# Check whether --with-openssl-incdir was given.
30152if test "${with_openssl_incdir+set}" = set; then :
30153  withval=$with_openssl_incdir;
30154fi
30155
30156
30157# Check whether --with-rpath was given.
30158if test "${with_rpath+set}" = set; then :
30159  withval=$with_rpath;
30160fi
30161
30162
30163ntp_openssl=no
30164ntp_openssl_from_pkg_config=no
30165
30166with_crypto=${with_crypto:-openssl,libcrypto}
30167case "$with_crypto" in
30168 yes)
30169    with_crypto=openssl,libcrypto
30170esac
30171
30172
30173case "$with_crypto:${PKG_CONFIG:+notempty}:${with_openssl_libdir-notgiven}:${with_openssl_incdir-notgiven}" in
30174 no:*) ;;
30175 *:notempty:notgiven:notgiven)
30176    for pkg in `echo $with_crypto | sed -e 's/,/ /'`; do
30177	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config for $pkg" >&5
30178$as_echo_n "checking pkg-config for $pkg... " >&6; }
30179	if $PKG_CONFIG --exists $pkg ; then
30180	    CPPFLAGS_NTP="$CPPFLAGS_NTP `$PKG_CONFIG --cflags-only-I $pkg`"
30181	    CFLAGS_NTP="$CFLAGS_NTP `$PKG_CONFIG --cflags-only-other $pkg`"
30182	    LDADD_NTP="$LDADD_NTP `$PKG_CONFIG --libs-only-L $pkg`"
30183	    LDADD_NTP="$LDADD_NTP `$PKG_CONFIG --libs-only-l --static $pkg`"
30184	    LDFLAGS_NTP="$LDFLAGS_NTP `$PKG_CONFIG --libs-only-other $pkg`"
30185	    VER_SUFFIX=o
30186	    ntp_openssl=yes
30187	    ntp_openssl_from_pkg_config=yes
30188	    ntp_openssl_version="`$PKG_CONFIG --modversion $pkg`"
30189	    case "$ntp_openssl_version" in
30190	     *.*) ;;
30191	     *) ntp_openssl_version='(unknown)' ;;
30192	    esac
30193	    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, version $ntp_openssl_version" >&5
30194$as_echo "yes, version $ntp_openssl_version" >&6; }
30195
30196	    break
30197	fi
30198	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30199$as_echo "no" >&6; }
30200    done
30201esac
30202case "$with_crypto:$ntp_openssl" in
30203 no:*) ;;
30204 *:no)
30205    need_dash_r=
30206    need_dash_Wlrpath=
30207    case "${with_rpath-notgiven}" in
30208     yes)
30209	# Lame - what to do if we need -Wl... but not -R?
30210	need_dash_r=1
30211	;;
30212     notgiven)
30213	case "$host" in
30214	 *-*-linux*)
30215	    # This may really only be true for gcc
30216	    need_dash_Wlrpath=1
30217	    ;;
30218	 *-*-netbsd*)
30219	    need_dash_r=1
30220	    ;;
30221	 *-*-solaris*)
30222	    need_dash_r=1
30223	    ;;
30224	esac
30225	;;
30226    esac
30227
30228    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for openssl library directory" >&5
30229$as_echo_n "checking for openssl library directory... " >&6; }
30230    with_openssl_libdir=${with_openssl_libdir-notgiven}
30231    case "$with_openssl_libdir" in
30232     notgiven)
30233	case "$build" in
30234	 $host)
30235	    with_openssl_libdir=default
30236	    ;;
30237	 *)
30238	    with_openssl_libdir=no
30239	    ;;
30240	esac
30241    esac
30242    case "$with_openssl_libdir" in
30243     default)
30244	# Look in:
30245	with_openssl_libdir="/usr/lib /usr/lib/openssl /usr/sfw/lib"
30246	with_openssl_libdir="$with_openssl_libdir /usr/local/lib"
30247	with_openssl_libdir="$with_openssl_libdir /usr/local/ssl/lib /lib"
30248    esac
30249    case "$with_openssl_libdir" in
30250     no)
30251	;;
30252     *) # Look for libcrypto.a and libssl.a:
30253	for i in $with_openssl_libdir no
30254	do
30255	    case "$host" in
30256	     *-*-darwin*)
30257		test -f $i/libcrypto.dylib -a -f $i/libssl.dylib && break
30258		;;
30259	     *)
30260		test -f $i/libcrypto.so -a -f $i/libssl.so && break
30261		test -f $i/libcrypto.a -a -f $i/libssl.a && break
30262		;;
30263	    esac
30264	done
30265	openssl_libdir=$i
30266	;;
30267    esac
30268    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $openssl_libdir" >&5
30269$as_echo "$openssl_libdir" >&6; }
30270    case "$openssl_libdir" in
30271     no)
30272	openssl_libdir=
30273	{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libcrypto and libssl not found in any of $with_openssl_libdir" >&5
30274$as_echo "$as_me: WARNING: libcrypto and libssl not found in any of $with_openssl_libdir" >&2;}
30275    esac
30276
30277    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for openssl include directory" >&5
30278$as_echo_n "checking for openssl include directory... " >&6; }
30279    with_openssl_incdir=${with_openssl_incdir-notgiven}
30280    case "$with_openssl_incdir" in
30281     notgiven)
30282	# Look in:
30283	with_openssl_incdir="/usr/include /usr/sfw/include"
30284	with_openssl_incdir="$with_openssl_incdir /usr/local/include"
30285	with_openssl_incdir="$with_openssl_incdir /usr/local/ssl/include"
30286    esac
30287    case "$with_openssl_incdir" in
30288     no)
30289	;;
30290     *) # look for openssl/evp.h:
30291	for i in $with_openssl_incdir no
30292	do
30293	    test -f $i/openssl/evp.h && break
30294	done
30295	openssl_incdir=$i
30296	;;
30297    esac
30298    { i=; unset i;}
30299    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $openssl_incdir" >&5
30300$as_echo "$openssl_incdir" >&6; }
30301    case "$openssl_incdir" in
30302     no)
30303	openssl_incdir=
30304	{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: did not find openssl/evp.h in any of $with_openssl_incdir" >&5
30305$as_echo "$as_me: WARNING: did not find openssl/evp.h in any of $with_openssl_incdir" >&2;}
30306    esac
30307    if test -z "$openssl_libdir" -o -z "$openssl_incdir"
30308    then
30309	ntp_openssl=no
30310    else
30311	ntp_openssl=yes
30312	VER_SUFFIX=o
30313    fi
30314    case "$ntp_openssl" in
30315     yes)
30316	# We have OpenSSL inc/lib dirs - use them.
30317	case "$openssl_incdir" in
30318	 /usr/include)
30319	    ;;
30320	 *)
30321	    CPPFLAGS_NTP="$CPPFLAGS_NTP -I$openssl_incdir"
30322	    ;;
30323	esac
30324	case "$openssl_libdir" in
30325	 /usr/lib)
30326	    ;;
30327	 *)
30328	    LDADD_NTP="$LDADD_NTP -L$openssl_libdir"
30329	    case "$need_dash_r" in
30330	     1)
30331		LDFLAGS_NTP="$LDFLAGS_NTP -R$openssl_libdir"
30332	    esac
30333	    case "$need_dash_Wlrpath" in
30334	     1)
30335		LDFLAGS_NTP="$LDFLAGS_NTP -Wl,-rpath,$openssl_libdir"
30336	    esac
30337	    ;;
30338	esac
30339	LDADD_NTP="$LDADD_NTP -lcrypto"
30340    esac
30341esac
30342
30343{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we will use crypto" >&5
30344$as_echo_n "checking if we will use crypto... " >&6; }
30345{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_openssl" >&5
30346$as_echo "$ntp_openssl" >&6; }
30347
30348case "$ntp_openssl" in
30349 yes)
30350    for ac_header in openssl/cmac.h openssl/hmac.h
30351do :
30352  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
30353ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
30354if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
30355  cat >>confdefs.h <<_ACEOF
30356#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
30357_ACEOF
30358
30359fi
30360
30361done
30362
30363
30364$as_echo "#define OPENSSL /**/" >>confdefs.h
30365
30366    case "$VER_SUFFIX" in
30367     *o*) ;;
30368     *) as_fn_error $? "OPENSSL set but no 'o' in VER_SUFFIX!" "$LINENO" 5 ;;
30369    esac
30370    ;;
30371esac
30372
30373NTPO_SAVED_CPPFLAGS="$CPPFLAGS"
30374CPPFLAGS="$CPPFLAGS $CPPFLAGS_NTP"
30375NTPO_SAVED_LIBS="$LIBS"
30376
30377#
30378# check for linking with -lcrypto failure, and try -lcrypto -lz.
30379# Helps m68k-atari-mint
30380#
30381case "$ntp_openssl:$ntp_openssl_from_pkg_config" in
30382 yes:no)
30383    LIBS="$NTPO_SAVED_LIBS $LDADD_NTP"
30384    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linking with -lcrypto alone works" >&5
30385$as_echo_n "checking if linking with -lcrypto alone works... " >&6; }
30386if ${ntp_cv_bare_lcrypto+:} false; then :
30387  $as_echo_n "(cached) " >&6
30388else
30389  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30390/* end confdefs.h.  */
30391
30392		    #include "openssl/err.h"
30393		    #include "openssl/evp.h"
30394
30395int
30396main ()
30397{
30398
30399		    ERR_load_crypto_strings();
30400		    OpenSSL_add_all_algorithms();
30401
30402
30403  ;
30404  return 0;
30405}
30406_ACEOF
30407if ac_fn_c_try_link "$LINENO"; then :
30408  ntp_cv_bare_lcrypto=yes
30409else
30410  ntp_cv_bare_lcrypto=no
30411
30412fi
30413rm -f core conftest.err conftest.$ac_objext \
30414    conftest$ac_exeext conftest.$ac_ext
30415
30416fi
30417{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_bare_lcrypto" >&5
30418$as_echo "$ntp_cv_bare_lcrypto" >&6; }
30419    case "$ntp_cv_bare_lcrypto" in
30420     no)
30421	LIBS="$NTPO_SAVED_LIBS $LDADD_NTP -lz"
30422	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if linking with -lcrypto -lz works" >&5
30423$as_echo_n "checking if linking with -lcrypto -lz works... " >&6; }
30424if ${ntp_cv_lcrypto_lz+:} false; then :
30425  $as_echo_n "(cached) " >&6
30426else
30427  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30428/* end confdefs.h.  */
30429
30430			#include "openssl/err.h"
30431			#include "openssl/evp.h"
30432
30433int
30434main ()
30435{
30436
30437			ERR_load_crypto_strings();
30438			OpenSSL_add_all_algorithms();
30439
30440
30441  ;
30442  return 0;
30443}
30444_ACEOF
30445if ac_fn_c_try_link "$LINENO"; then :
30446  ntp_cv_lcrypto_lz=yes
30447else
30448  ntp_cv_lcrypto_lz=no
30449
30450fi
30451rm -f core conftest.err conftest.$ac_objext \
30452    conftest$ac_exeext conftest.$ac_ext
30453
30454fi
30455{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_lcrypto_lz" >&5
30456$as_echo "$ntp_cv_lcrypto_lz" >&6; }
30457	case "$ntp_cv_lcrypto_lz" in
30458	 yes)
30459	     LDADD_NTP="$LDADD_NTP -lz"
30460	esac
30461    esac
30462esac
30463
30464#
30465# Older OpenSSL headers have a number of callback prototypes inside
30466# other function prototypes which trigger copious warnings with gcc's
30467# -Wstrict-prototypes, which is included in -Wall.
30468#
30469# An example:
30470#
30471# int i2d_RSA_NET(const RSA *a, unsigned char **pp,
30472#		  int (*cb)(), int sgckey);
30473#		  ^^^^^^^^^^^
30474#
30475#
30476#
30477openssl_triggers_warnings=unknown
30478NTPO_SAVED_CFLAGS="$CFLAGS"
30479
30480case "$ntp_openssl:$GCC" in
30481 yes:yes)
30482    CFLAGS="$CFLAGS -Werror"
30483    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30484/* end confdefs.h.  */
30485
30486
30487int
30488main ()
30489{
30490
30491		/* see if -Werror breaks gcc */
30492
30493
30494  ;
30495  return 0;
30496}
30497_ACEOF
30498if ac_fn_c_try_compile "$LINENO"; then :
30499  gcc_handles_Werror=yes
30500else
30501  gcc_handles_Werror=no
30502
30503fi
30504rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30505    case "$gcc_handles_Werror" in
30506     no)
30507	# if this gcc doesn't do -Werror go ahead and use
30508	# -Wstrict-prototypes.
30509	openssl_triggers_warnings=yes
30510	;;
30511     yes)
30512	CFLAGS="$CFLAGS -Wstrict-prototypes"
30513	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30514/* end confdefs.h.  */
30515
30516		    #include "openssl/asn1_mac.h"
30517		    #include "openssl/bn.h"
30518		    #include "openssl/err.h"
30519		    #include "openssl/evp.h"
30520		    #include "openssl/pem.h"
30521		    #include "openssl/rand.h"
30522		    #include "openssl/x509v3.h"
30523
30524int
30525main ()
30526{
30527
30528		    /* empty body */
30529
30530
30531  ;
30532  return 0;
30533}
30534_ACEOF
30535if ac_fn_c_try_compile "$LINENO"; then :
30536  openssl_triggers_warnings=no
30537else
30538  openssl_triggers_warnings=yes
30539
30540fi
30541rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30542    esac
30543    case "$openssl_triggers_warnings" in
30544     yes)
30545	CFLAGS_NTP="$CFLAGS_NTP -Wno-strict-prototypes"
30546	;;
30547     *)
30548	CFLAGS_NTP="$CFLAGS_NTP -Wstrict-prototypes"
30549    esac
30550    ;;
30551 no:yes)
30552    # gcc without OpenSSL
30553    CFLAGS_NTP="$CFLAGS_NTP -Wstrict-prototypes"
30554esac
30555
30556# Because we don't want -Werror for the EVP_MD_do_all_sorted check
30557CFLAGS="$NTPO_SAVED_CFLAGS"
30558
30559case "$ntp_openssl" in
30560 yes)
30561    LIBS="$NTPO_SAVED_LIBS $LDADD_NTP"
30562    for ac_func in EVP_MD_do_all_sorted
30563do :
30564  ac_fn_c_check_func "$LINENO" "EVP_MD_do_all_sorted" "ac_cv_func_EVP_MD_do_all_sorted"
30565if test "x$ac_cv_func_EVP_MD_do_all_sorted" = xyes; then :
30566  cat >>confdefs.h <<_ACEOF
30567#define HAVE_EVP_MD_DO_ALL_SORTED 1
30568_ACEOF
30569
30570fi
30571done
30572
30573    ;;
30574esac
30575
30576
30577CPPFLAGS="$NTPO_SAVED_CPPFLAGS"
30578LIBS="$NTPO_SAVED_LIBS"
30579{ NTPO_SAVED_CFLAGS=; unset NTPO_SAVED_CFLAGS;}
30580{ NTPO_SAVED_CPPFLAGS=; unset NTPO_SAVED_CPPFLAGS;}
30581{ NTPO_SAVED_LIBS=; unset NTPO_SAVED_LIBS;}
30582{ openssl_triggers_warnings=; unset openssl_triggers_warnings;}
30583{ ntp_openssl_from_pkg_config=; unset ntp_openssl_from_pkg_config;}
30584
30585
30586{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want to enable CMAC support" >&5
30587$as_echo_n "checking if we want to enable CMAC support... " >&6; }
30588case "$ac_cv_header_openssl_cmac_h" in
30589 yes)
30590
30591$as_echo "#define ENABLE_CMAC 1" >>confdefs.h
30592
30593    ans="yes"
30594    ;;
30595 *) ans="no"
30596    ;;
30597esac
30598{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
30599$as_echo "$ans" >&6; }
30600
30601
30602
30603
30604{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want to use OpenSSL's crypto random (if available)" >&5
30605$as_echo_n "checking if we want to use OpenSSL's crypto random (if available)... " >&6; }
30606# Check whether --enable-openssl-random was given.
30607if test "${enable_openssl_random+set}" = set; then :
30608  enableval=$enable_openssl_random; ntp_use_openssl_random=$enableval
30609else
30610  ntp_use_openssl_random=yes
30611
30612fi
30613
30614{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_use_openssl_random" >&5
30615$as_echo "$ntp_use_openssl_random" >&6; }
30616
30617# The following might need extra libraries
30618NTPO_SAVED_LIBS="$LIBS"
30619LIBS="$NTPO_SAVED_LIBS $LDADD_NTP"
30620for ac_func in RAND_bytes RAND_poll
30621do :
30622  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
30623ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
30624if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
30625  cat >>confdefs.h <<_ACEOF
30626#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
30627_ACEOF
30628
30629fi
30630done
30631
30632LIBS="$NTPO_SAVED_LIBS"
30633case "$ntp_use_openssl_random$ac_cv_func_RAND_bytes$ac_cv_func_RAND_poll" in
30634 yesyesyes)
30635
30636$as_echo "#define USE_OPENSSL_CRYPTO_RAND 1" >>confdefs.h
30637
30638     ;;
30639 *) ntp_use_openssl_random=no ;;
30640esac
30641
30642
30643
30644# if we are using OpenSSL (--with-crypto), by default Autokey is enabled
30645{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want to include NTP Autokey protocol support" >&5
30646$as_echo_n "checking if we want to include NTP Autokey protocol support... " >&6; }
30647# Check whether --enable-autokey was given.
30648if test "${enable_autokey+set}" = set; then :
30649  enableval=$enable_autokey; ntp_autokey=$enableval
30650else
30651  ntp_autokey=$ntp_openssl
30652
30653fi
30654
30655case "$ntp_autokey" in
30656 no)
30657    ;;
30658 *)
30659    case "$ntp_openssl" in
30660     no)
30661	{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Disabling Autokey, --enable-autokey requires --with-crypto." >&5
30662$as_echo "$as_me: WARNING: Disabling Autokey, --enable-autokey requires --with-crypto." >&2;}
30663	ntp_autokey=no
30664	;;
30665     *)
30666
30667$as_echo "#define AUTOKEY 1" >>confdefs.h
30668
30669	ntp_autokey=yes
30670	;;
30671    esac
30672    ;;
30673esac
30674{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_autokey" >&5
30675$as_echo "$ntp_autokey" >&6; }
30676
30677
30678{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want to run check-layout" >&5
30679$as_echo_n "checking if we want to run check-layout... " >&6; }
30680case "$cross_compiling$PATH_PERL" in
30681 no/*)
30682    MAKE_CHECK_LAYOUT=check-layout
30683    ans=yes
30684    ;;
30685 *)
30686    ans=no
30687    ;;
30688esac
30689{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
30690$as_echo "$ans" >&6; }
30691
30692
30693
30694{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can make dcf parse utilities" >&5
30695$as_echo_n "checking if we can make dcf parse utilities... " >&6; }
30696ans=no
30697case "$ntp_parseutil" in
30698 yes)
30699    case "$host" in
30700     *-*-sunos4*|*-*-solaris2*|*-*-*linux*|*-*-netbsd*)
30701	ans="dcfd testdcf"
30702	DCFD=dcfd
30703	TESTDCF=testdcf
30704    esac
30705    ;;
30706esac
30707{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
30708$as_echo "$ans" >&6; }
30709
30710
30711{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can build kernel streams modules for parse" >&5
30712$as_echo_n "checking if we can build kernel streams modules for parse... " >&6; }
30713ans=no
30714case "$ntp_parseutil$ac_cv_header_sys_stropts_h" in
30715 yesyes)
30716    case "$host" in
30717     sparc-*-sunos4*)
30718        case "$ntp_cv_var_kernel_pll" in
30719	yes)
30720
30721$as_echo "#define PPS_SYNC 1" >>confdefs.h
30722
30723	    ;;
30724	esac
30725	ans=parsestreams
30726	MAKE_PARSEKMODULE=parsestreams.loadable_module.o
30727	;;
30728     sparc-*-solaris2*)
30729	ans=parsesolaris
30730	MAKE_PARSEKMODULE=parse
30731	for ac_header in strings.h
30732do :
30733  ac_fn_c_check_header_mongrel "$LINENO" "strings.h" "ac_cv_header_strings_h" "$ac_includes_default"
30734if test "x$ac_cv_header_strings_h" = xyes; then :
30735  cat >>confdefs.h <<_ACEOF
30736#define HAVE_STRINGS_H 1
30737_ACEOF
30738
30739fi
30740
30741done
30742
30743	;;
30744    esac
30745    ;;
30746esac
30747{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
30748$as_echo "$ans" >&6; }
30749
30750{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we need basic refclock support" >&5
30751$as_echo_n "checking if we need basic refclock support... " >&6; }
30752case "$ntp_refclock" in
30753 yes)
30754
30755$as_echo "#define REFCLOCK 1" >>confdefs.h
30756
30757    ;;
30758esac
30759{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_refclock" >&5
30760$as_echo "$ntp_refclock" >&6; }
30761
30762PROPDELAY=propdelay
30763
30764
30765
30766{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want HP-UX adjtimed support" >&5
30767$as_echo_n "checking if we want HP-UX adjtimed support... " >&6; }
30768case "$host" in
30769 *-*-hpux[56789]*)
30770    ans=yes
30771    ;;
30772 *) ans=no
30773    ;;
30774esac
30775case "$ans" in
30776 yes)
30777    MAKE_ADJTIMED=adjtimed
30778
30779$as_echo "#define NEED_HPUX_ADJTIME 1" >>confdefs.h
30780
30781    ;;
30782 *) ADJTIMED_DB=
30783    ADJTIMED_DL=
30784    ADJTIMED_DS=
30785    ADJTIMED_MS=
30786    ;;
30787esac
30788{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
30789$as_echo "$ans" >&6; }
30790
30791{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want QNX adjtime support" >&5
30792$as_echo_n "checking if we want QNX adjtime support... " >&6; }
30793case "$host" in
30794 *-*-qnx*)
30795    ans=yes
30796    ;;
30797 *) ans=no
30798    ;;
30799esac
30800case "$ans" in
30801 yes)
30802
30803$as_echo "#define NEED_QNX_ADJTIME 1" >>confdefs.h
30804
30805    ;;
30806esac
30807{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
30808$as_echo "$ans" >&6; }
30809
30810{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can read kmem" >&5
30811$as_echo_n "checking if we can read kmem... " >&6; }
30812
30813#  the default is to enable it if the system has the capability
30814
30815case "$ac_cv_func_nlist$ac_cv_func_K_open$ac_cv_func_kvm_open" in
30816 *yes*)
30817    ans=yes
30818    ;;
30819 *) ans=no
30820    ;;
30821esac
30822
30823case "$host" in
30824 *-*-domainos)	# Won't be found...
30825    ans=no
30826    ;;
30827 *-*-hpux*)
30828    #ans=no
30829    ;;
30830 *-*-irix[456]*)
30831    ans=no
30832    ;;
30833 *-*-*linux*)
30834    ans=no
30835    ;;
30836 *-*-winnt3.5)
30837    ans=no
30838    ;;
30839 *-*-unicosmp*)
30840    ans=no
30841    ;;
30842esac
30843
30844# --enable-kmem / --disable-kmem controls if present
30845# Check whether --enable-kmem was given.
30846if test "${enable_kmem+set}" = set; then :
30847  enableval=$enable_kmem; ans=$enableval
30848
30849fi
30850
30851
30852{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
30853$as_echo "$ans" >&6; }
30854
30855case "$ans" in
30856 yes)
30857    can_kmem=yes
30858    ;;
30859 *)
30860    can_kmem=no
30861
30862$as_echo "#define NOKMEM 1" >>confdefs.h
30863
30864esac
30865
30866
30867{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if adjtime is accurate" >&5
30868$as_echo_n "checking if adjtime is accurate... " >&6; }
30869
30870# target-dependent defaults
30871
30872case "$host" in
30873 i386-sequent-ptx*)
30874    ans=no
30875    ;;
30876 i386-unknown-osf1*)
30877    ans=yes
30878    ;;
30879 mips-sgi-irix[456]*)
30880    ans=yes
30881    ;;
30882 *-fujitsu-uxp*)
30883    ans=yes
30884    ;;
30885 *-ibm-aix[4-9]*)
30886    # XXX only verified thru AIX6.
30887    ans=yes
30888    ;;
30889 *-*-*linux*)
30890    ans=yes
30891    ;;
30892 *-*-solaris2.[01])
30893    ans=no
30894    ;;
30895 *-*-solaris2*)
30896    ans=yes
30897    ;;
30898 *-*-unicosmp*)
30899    ans=yes
30900    ;;
30901 *) ans=no
30902    ;;
30903esac
30904
30905# --enable-accurate-adjtime / --disable-accurate-adjtime
30906# override the default
30907# Check whether --enable-accurate-adjtime was given.
30908if test "${enable_accurate_adjtime+set}" = set; then :
30909  enableval=$enable_accurate_adjtime; ans=$enableval
30910
30911fi
30912
30913
30914{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
30915$as_echo "$ans" >&6; }
30916
30917case "$ans" in
30918 yes)
30919
30920$as_echo "#define ADJTIME_IS_ACCURATE 1" >>confdefs.h
30921
30922    adjtime_is_accurate=yes
30923    ;;
30924 *)
30925    adjtime_is_accurate=no
30926    ;;
30927esac
30928
30929{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the name of 'tick' in the kernel" >&5
30930$as_echo_n "checking the name of 'tick' in the kernel... " >&6; }
30931if ${ntp_cv_nlist_tick+:} false; then :
30932  $as_echo_n "(cached) " >&6
30933else
30934
30935	ans=_tick
30936	case "$host" in
30937	 m68*-hp-hpux*) # HP9000/300?
30938	    ans=_old_tick
30939	    ;;
30940	 *-apple-aux[23]*)
30941	    ans=tick
30942	    ;;
30943	 *-hp-hpux*)
30944	    ans=old_tick
30945	    ;;
30946	 *-ibm-aix[3-9]*)
30947	    # XXX only verified thru AIX6.
30948	    ans=no
30949	    ;;
30950	 *-*-mpeix*)
30951	    ans=no
30952	    ;;
30953	 *-*-ptx*)
30954	    ans=tick
30955	    ;;
30956	 *-*-sco3.2v[45]*)
30957	    ans=no
30958	    ;;
30959	 *-*-solaris2*)
30960	    ans=nsec_per_tick
30961	    ;;
30962	 *-*-sysv4*)
30963	    ans=tick
30964	    ;;
30965	esac
30966	ntp_cv_nlist_tick=$ans
30967
30968
30969fi
30970{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_nlist_tick" >&5
30971$as_echo "$ntp_cv_nlist_tick" >&6; }
30972case "$ntp_cv_nlist_tick" in
30973 ''|no)
30974    ;;	# HMS: I think we can only get 'no' here...
30975 *)
30976
30977cat >>confdefs.h <<_ACEOF
30978#define K_TICK_NAME "$ntp_cv_nlist_tick"
30979_ACEOF
30980
30981esac
30982
30983{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for the units of 'tick'" >&5
30984$as_echo_n "checking for the units of 'tick'... " >&6; }
30985if ${ntp_cv_tick_nano+:} false; then :
30986  $as_echo_n "(cached) " >&6
30987else
30988
30989	ans=usec
30990	case "$host" in
30991	 *-*-solaris2*)
30992	    ans=nsec
30993	    ;;
30994	esac
30995	ntp_cv_tick_nano=$ans
30996
30997
30998fi
30999{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_tick_nano" >&5
31000$as_echo "$ntp_cv_tick_nano" >&6; }
31001case "$ntp_cv_tick_nano" in
31002 nsec)
31003
31004$as_echo "#define TICK_NANO 1" >>confdefs.h
31005
31006esac
31007
31008{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the name of 'tickadj' in the kernel" >&5
31009$as_echo_n "checking the name of 'tickadj' in the kernel... " >&6; }
31010if ${ntp_cv_nlist_tickadj+:} false; then :
31011  $as_echo_n "(cached) " >&6
31012else
31013
31014	ans=_tickadj
31015	case "$host" in
31016	 m68*-hp-hpux*) # HP9000/300?
31017	    ans=_tickadj
31018	    ;;
31019	 *-apple-aux[23]*)
31020	    ans=tickadj
31021	    ;;
31022	 *-hp-hpux10*)
31023	    ans=no
31024	    ;;
31025	 *-hp-hpux9*)
31026	    ans=no
31027	    ;;
31028	 *-hp-hpux*)
31029	    ans=tickadj
31030	    ;;
31031	 *-*-aix*)
31032	    ans=tickadj
31033	    ;;
31034	 *-*-mpeix*)
31035	    ans=no
31036	    ;;
31037	 *-*-ptx*)
31038	    ans=tickadj
31039	    ;;
31040	 *-*-sco3.2v4*)
31041	    ans=no
31042	    ;;
31043	 *-*-sco3.2v5.0*)
31044	    ans=clock_drift
31045	    ;;
31046	 *-*-solaris2*)
31047	    ans=no	# hrestime_adj
31048	    ;;
31049	 *-*-sysv4*)
31050	    ans=tickadj
31051	    ;;
31052	esac
31053	ntp_cv_nlist_tickadj=$ans
31054
31055
31056fi
31057{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_nlist_tickadj" >&5
31058$as_echo "$ntp_cv_nlist_tickadj" >&6; }
31059case "$ntp_cv_nlist_tickadj" in
31060 ''|no)
31061    ;;	# HMS: I think we can only get 'no' here...
31062 *)
31063
31064cat >>confdefs.h <<_ACEOF
31065#define K_TICKADJ_NAME "$ntp_cv_nlist_tickadj"
31066_ACEOF
31067
31068esac
31069
31070{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for the units of 'tickadj'" >&5
31071$as_echo_n "checking for the units of 'tickadj'... " >&6; }
31072if ${ntp_cv_tickadj_nano+:} false; then :
31073  $as_echo_n "(cached) " >&6
31074else
31075
31076	ans=usec
31077	case "$host" in
31078	 *-*-solaris2*)
31079	    ans=nsec
31080	    ;;
31081	esac
31082	ntp_cv_tickadj_nano=$ans
31083
31084
31085fi
31086{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_tickadj_nano" >&5
31087$as_echo "$ntp_cv_tickadj_nano" >&6; }
31088case "$ntp_cv_tickadj_nano" in
31089 nsec)
31090
31091$as_echo "#define TICKADJ_NANO 1" >>confdefs.h
31092
31093esac
31094
31095{ $as_echo "$as_me:${as_lineno-$LINENO}: checking half-heartedly for 'dosynctodr' in the kernel" >&5
31096$as_echo_n "checking half-heartedly for 'dosynctodr' in the kernel... " >&6; }
31097if ${ntp_cv_nlist_dosynctodr+:} false; then :
31098  $as_echo_n "(cached) " >&6
31099else
31100
31101	case "$host" in
31102	 *-apple-aux[23]*)
31103	    ans=no
31104	    ;;
31105	 *-sni-sysv*)
31106	    ans=dosynctodr
31107	    ;;
31108	 *-stratus-vos)
31109	    ans=no
31110	    ;;
31111	 *-*-aix*)
31112	    ans=dosynctodr
31113	    ;;
31114	 *-*-hpux*)
31115	    ans=no
31116	    ;;
31117	 *-*-mpeix*)
31118	    ans=no
31119	    ;;
31120	 *-*-nextstep*)
31121	    ans=_dosynctodr
31122	    ;;
31123	 *-*-ptx*)
31124	    ans=doresettodr
31125	    ;;
31126	 *-*-sco3.2v4*)
31127	    ans=no
31128	    ;;
31129	 *-*-sco3.2v5*)
31130	    ans=track_rtc
31131	    ;;
31132	 *-*-solaris2*)
31133	    ans=dosynctodr
31134	    ;;
31135	 *-*-sysv4*)
31136	    ans=doresettodr
31137	    ;;
31138	 *)
31139	    ans=_dosynctodr
31140	    ;;
31141	esac
31142	ntp_cv_nlist_dosynctodr=$ans
31143
31144
31145fi
31146{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_nlist_dosynctodr" >&5
31147$as_echo "$ntp_cv_nlist_dosynctodr" >&6; }
31148case "$ntp_cv_nlist_dosynctodr" in
31149 no)
31150    ;;
31151 *)
31152
31153cat >>confdefs.h <<_ACEOF
31154#define K_DOSYNCTODR_NAME "$ntp_cv_nlist_dosynctodr"
31155_ACEOF
31156
31157    ;;
31158esac
31159
31160{ $as_echo "$as_me:${as_lineno-$LINENO}: checking half-heartedly for 'noprintf' in the kernel" >&5
31161$as_echo_n "checking half-heartedly for 'noprintf' in the kernel... " >&6; }
31162if ${ntp_cv_nlist_noprintf+:} false; then :
31163  $as_echo_n "(cached) " >&6
31164else
31165
31166	case "$host" in
31167	 *-apple-aux[23]*)
31168	    ans=no
31169	    ;;
31170	 *-sni-sysv*)
31171	    ans=noprintf
31172	    ;;
31173	 *-stratus-vos)
31174	    ans=no
31175	    ;;
31176	 *-*-aix*)
31177	    ans=noprintf
31178	    ;;
31179	 *-*-hpux*)
31180	    ans=no
31181	    ;;
31182	 *-*-mpeix*)
31183	    ans=no
31184	    ;;
31185	 *-*-ptx*)
31186	    ans=noprintf
31187	    ;;
31188	 *-*-nextstep*)
31189	    ans=_noprintf
31190	    ;;
31191	 *-*-solaris2*)
31192	    ans=noprintf
31193	    ;;
31194	 *-*-sysv4*)
31195	    ans=noprintf
31196	    ;;
31197	 *)
31198	    ans=_noprintf
31199	    ;;
31200	esac
31201	ntp_cv_nlist_noprintf=$ans
31202
31203
31204fi
31205{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_nlist_noprintf" >&5
31206$as_echo "$ntp_cv_nlist_noprintf" >&6; }
31207case "$ntp_cv_nlist_noprintf" in
31208 no)
31209    ;;
31210 *)
31211
31212cat >>confdefs.h <<_ACEOF
31213#define K_NOPRINTF_NAME "$ntp_cv_nlist_noprintf"
31214_ACEOF
31215
31216    ;;
31217esac
31218
31219
31220
31221
31222{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a default value for 'tick'" >&5
31223$as_echo_n "checking for a default value for 'tick'... " >&6; }
31224
31225# target-dependent default for tick
31226
31227case "$host" in
31228 *-*-pc-cygwin*)
31229    as_fn_error $? "tick needs work for cygwin" "$LINENO" 5
31230    ;;
31231 *-univel-sysv*)
31232    ans=10000
31233    ;;
31234 *-*-irix*)
31235    ans=10000
31236    ;;
31237 *-*-*linux*)
31238    ans=txc.tick
31239    ;;
31240 *-*-mpeix*)
31241    ans=no
31242    ;;
31243 *-*-winnt3.5)
31244    ans='(every / 10)'
31245    ;;
31246 *-*-unicosmp*)
31247    ans=10000
31248    ;;
31249 *)
31250    ans='1000000L/hz'
31251    ;;
31252esac
31253
31254# Check whether --enable-tick was given.
31255if test "${enable_tick+set}" = set; then :
31256  enableval=$enable_tick; ans=$enableval
31257
31258fi
31259
31260
31261{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
31262$as_echo "$ans" >&6; }
31263
31264case "$ans" in
31265 ''|no)
31266    ;;	# HMS: I think we can only get 'no' here...
31267 *)
31268
31269cat >>confdefs.h <<_ACEOF
31270#define PRESET_TICK $ans
31271_ACEOF
31272
31273esac
31274
31275{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a default value for 'tickadj'" >&5
31276$as_echo_n "checking for a default value for 'tickadj'... " >&6; }
31277
31278# target-specific default
31279ans='500/hz'
31280case "$host" in
31281 *-fujitsu-uxp*)
31282    case "$adjtime_is_accurate" in
31283     yes)
31284	ans='tick/16'
31285    esac
31286    ;;
31287 *-univel-sysv*)
31288    ans=80
31289    ;;
31290 *-*-aix*)
31291    case "$can_kmem" in
31292     no)
31293	ans=1000
31294	;;
31295    esac
31296    ;;
31297 *-*-domainos)	# Skippy: won't be found...
31298    case "$can_kmem" in
31299     no)
31300	ans=668
31301	;;
31302    esac
31303    ;;
31304 *-*-hpux*)
31305    case "$adjtime_is_accurate" in
31306     yes)
31307	ans='tick/16'
31308	;;
31309    esac
31310    ;;
31311 *-*-irix*)
31312    ans=150
31313    ;;
31314 *-*-mpeix*)
31315    ans=no
31316    ;;
31317 *-*-sco3.2v5.0*)
31318    ans=10000L/hz
31319    ;;
31320 *-*-winnt3.5)
31321    ans=50
31322    ;;
31323 *-*-unicosmp*)
31324    ans=150
31325    ;;
31326esac
31327
31328# Check whether --enable-tickadj was given.
31329if test "${enable_tickadj+set}" = set; then :
31330  enableval=$enable_tickadj; ans=$enableval
31331
31332fi
31333
31334
31335{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
31336$as_echo "$ans" >&6; }
31337
31338default_tickadj=$ans
31339
31340case "$default_tickadj" in
31341 ''|no)
31342    ;;	# HMS: I think we can only get 'no' here...
31343 *)
31344
31345cat >>confdefs.h <<_ACEOF
31346#define PRESET_TICKADJ $default_tickadj
31347_ACEOF
31348 ;;
31349esac
31350
31351# Newer versions of ReliantUNIX round adjtime() values down to
31352# 1/100s (system tick). Sigh ...
31353# Unfortunately, there is no easy way to know if particular release
31354# has this "feature" or any obvious way to test for it.
31355case "$host" in
31356 mips-sni-sysv4*)
31357
31358$as_echo "#define RELIANTUNIX_CLOCK 1" >>confdefs.h
31359
31360esac
31361
31362case "$host" in
31363 *-*-sco3.2v5*)
31364
31365$as_echo "#define SCO5_CLOCK 1" >>confdefs.h
31366
31367esac
31368
31369ntp_cv_make_tickadj=yes
31370case "$can_kmem$ac_cv_var_tick$default_tickadj" in
31371 nonono)	# Don't read KMEM, no presets.  Bogus.
31372    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Can't read kmem, no PRESET_TICK or PRESET_TICKADJ.  No tickadj." >&5
31373$as_echo "$as_me: WARNING: Can't read kmem, no PRESET_TICK or PRESET_TICKADJ.  No tickadj." >&2;}
31374    ntp_cv_make_tickadj=no
31375    ;;
31376 nono*)		# Don't read KMEM, no PRESET_TICK but PRESET_TICKADJ.  Bogus.
31377    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Can't read kmem but no PRESET_TICK.  No tickadj." >&5
31378$as_echo "$as_me: WARNING: Can't read kmem but no PRESET_TICK.  No tickadj." >&2;}
31379    ntp_cv_make_tickadj=no
31380    ;;
31381 no*no)		# Don't read KMEM, PRESET_TICK but no PRESET_TICKADJ.  Bogus.
31382    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Can't read kmem but no PRESET_TICKADJ.  No tickadj." >&5
31383$as_echo "$as_me: WARNING: Can't read kmem but no PRESET_TICKADJ.  No tickadj." >&2;}
31384    ntp_cv_make_tickadj=no
31385    ;;
31386 no*)		# Don't read KMEM, PRESET_TICK and PRESET_TICKADJ.  Cool.
31387    ;;
31388 yesnono)	# Read KMEM, no presets.  Cool.
31389    ;;
31390 yesno*)	# Read KMEM, no PRESET_TICK but PRESET_TICKADJ.  Bogus.
31391    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: PRESET_TICKADJ is defined but not PRESET_TICK.  Please report this." >&5
31392$as_echo "$as_me: WARNING: PRESET_TICKADJ is defined but not PRESET_TICK.  Please report this." >&2;}
31393    ;;
31394 yes*no)	# Read KMEM, PRESET_TICK but no PRESET_TICKADJ.  Cool.
31395    ;;
31396 yes*)		# READ KMEM, PRESET_TICK and PRESET_TICKADJ.
31397    ;;
31398 *)		# Generally bogus.
31399    as_fn_error $? "This shouldn't happen." "$LINENO" 5
31400    ;;
31401esac
31402
31403
31404{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want and can make the ntptime utility" >&5
31405$as_echo_n "checking if we want and can make the ntptime utility... " >&6; }
31406if ${ac_cv_make_ntptime+:} false; then :
31407  $as_echo_n "(cached) " >&6
31408else
31409  case "$host" in
31410 *) case "$ntp_cv_struct_ntptimeval$ntp_cv_var_kernel_pll" in
31411     yesyes)
31412	ans=yes
31413	;;
31414     *)
31415	ans=no
31416	;;
31417    esac
31418    ;;
31419esac
31420ac_cv_make_ntptime=$ans
31421fi
31422{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_make_ntptime" >&5
31423$as_echo "$ac_cv_make_ntptime" >&6; }
31424case "$ac_cv_make_ntptime" in
31425 yes)
31426    MAKE_NTPTIME=ntptime
31427    ;;
31428 *)
31429    NTPTIME_DB=
31430    NTPTIME_DL=
31431    NTPTIME_DS=
31432    NTPTIME_MS=
31433    ;;
31434esac
31435
31436
31437case "$host" in
31438 mips-sni-sysv4*)
31439    # tickadj is pretty useless on newer versions of ReliantUNIX
31440    # Do not bother
31441    ntp_cv_make_tickadj=no
31442    ;;
31443 *-*-irix*)
31444    ntp_cv_make_tickadj=no
31445    ;;
31446 *-*-solaris2*)
31447    # DLM says tickadj is a no-no starting with solaris2.5
31448    case "$host" in
31449     *-*-solaris2.1[0-9]*)
31450	ntp_cv_make_tickadj=no
31451	;;
31452     *-*-solaris2.[0-4]*) ;;
31453     *) ntp_cv_make_tickadj=no ;;
31454    esac
31455    ;;
31456 *-*-unicosmp*)
31457    ntp_cv_make_tickadj=no
31458    ;;
31459esac
31460
31461#
31462# Despite all the above, we always make tickadj.  Setting
31463# ntp_cv_make_tickadj before AC_CACHE_CHECK will cause a false
31464# report that the configuration variable was cached.  It may
31465# be better to simply remove the hunk above, I did not want
31466# to remove it if there is hope it will be used again.
31467#
31468{ ntp_cv_make_tickadj=; unset ntp_cv_make_tickadj;}
31469
31470{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want and can make the tickadj utility" >&5
31471$as_echo_n "checking if we want and can make the tickadj utility... " >&6; }
31472if ${ntp_cv_make_tickadj+:} false; then :
31473  $as_echo_n "(cached) " >&6
31474else
31475  ntp_cv_make_tickadj=yes
31476
31477fi
31478{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_make_tickadj" >&5
31479$as_echo "$ntp_cv_make_tickadj" >&6; }
31480case "$ntp_cv_make_tickadj" in
31481 yes)
31482    MAKE_TICKADJ=tickadj
31483    ;;
31484 *)
31485    CALC_TICKADJ_DB=
31486    CALC_TICKADJ_DL=
31487    CALC_TICKADJ_DS=
31488    CALC_TICKADJ_MS=
31489    TICKADJ_DB=
31490    TICKADJ_DL=
31491    TICKADJ_DS=
31492    TICKADJ_MS=
31493    ;;
31494esac
31495
31496
31497{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want and can make the timetrim utility" >&5
31498$as_echo_n "checking if we want and can make the timetrim utility... " >&6; }
31499if ${ntp_cv_make_timetrim+:} false; then :
31500  $as_echo_n "(cached) " >&6
31501else
31502
31503	case "$host" in
31504	 *-*-irix*)
31505	    ntp_cv_make_timetrim=yes
31506	    ;;
31507	 *-*-unicosmp*)
31508	    ntp_cv_make_timetrim=yes
31509	    ;;
31510	 *)
31511	    ntp_cv_make_timetrim=no
31512	    ;;
31513	esac
31514
31515
31516fi
31517{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_make_timetrim" >&5
31518$as_echo "$ntp_cv_make_timetrim" >&6; }
31519case "$ntp_cv_make_timetrim" in
31520 yes)
31521    MAKE_TIMETRIM=timetrim
31522    ;;
31523 *) TIMETRIM_DB=
31524    TIMETRIM_DL=
31525    TIMETRIM_DS=
31526    TIMETRIM_MS=
31527    ;;
31528esac
31529
31530
31531
31532
31533{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want to build the NTPD simulator" >&5
31534$as_echo_n "checking if we want to build the NTPD simulator... " >&6; }
31535# Check whether --enable-simulator was given.
31536if test "${enable_simulator+set}" = set; then :
31537  enableval=$enable_simulator; ans=$enableval
31538else
31539  ans=no
31540
31541fi
31542
31543{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
31544$as_echo "$ans" >&6; }
31545case "$ans" in
31546 yes)
31547    MAKE_NTPDSIM=ntpdsim
31548    MAKE_LIBNTPSIM=libntpsim.a
31549    ;;
31550 *)
31551    NTPDSIM_DB=
31552    NTPDSIM_DL=
31553    NTPDSIM_DS=
31554    NTPDSIM_MS=
31555    ;;
31556esac
31557
31558case "$build" in
31559 $host)
31560    ;;
31561 *) case "$host" in
31562     *-*-vxworks*)
31563	LDFLAGS="$LDFLAGS -r"
31564	;;
31565    esac
31566    ;;
31567esac
31568
31569
31570
31571{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if sntp will be built" >&5
31572$as_echo_n "checking if sntp will be built... " >&6; }
31573
31574# Check whether --with-sntp was given.
31575if test "${with_sntp+set}" = set; then :
31576  withval=$with_sntp;
31577else
31578  with_sntp="${withsntp=yes}"
31579
31580fi
31581
31582case "$with_sntp" in
31583 no)
31584    SNTP=
31585    ;;
31586 *)
31587    SNTP=sntp
31588    ;;
31589esac
31590
31591 if test -n "$SNTP"; then
31592  BUILD_SNTP_TRUE=
31593  BUILD_SNTP_FALSE='#'
31594else
31595  BUILD_SNTP_TRUE='#'
31596  BUILD_SNTP_FALSE=
31597fi
31598
31599{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_sntp" >&5
31600$as_echo "$with_sntp" >&6; }
31601
31602
31603
31604{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want to build ntpsnmpd" >&5
31605$as_echo_n "checking if we want to build ntpsnmpd... " >&6; }
31606
31607# Check whether --with-ntpsnmpd was given.
31608if test "${with_ntpsnmpd+set}" = set; then :
31609  withval=$with_ntpsnmpd; ans=$withval
31610else
31611
31612	case "$PATH_NET_SNMP_CONFIG" in
31613	 /*)	ans=yes ;;
31614	 *)	ans=no  ;;
31615	esac
31616
31617
31618fi
31619
31620{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
31621$as_echo "$ans" >&6; }
31622case "$ans" in
31623 yes)
31624    case "$PATH_NET_SNMP_CONFIG" in
31625     /*)
31626	SNMP_LIBS=`$PATH_NET_SNMP_CONFIG --agent-libs`
31627	# Bug 2815.  This is a bit of a hack, but it works...
31628	case "$ntp_cv_net_snmp_version" in
31629	 5.3*)	SNMP_LIBS=`echo $SNMP_LIBS | $SED -e 's/-lnetsnmpagent/-lnetsnmpagent -lnetsnmpmibs/'`
31630		;;
31631	esac
31632
31633	# HMS: we really want to separate CPPFLAGS and CFLAGS
31634	foo=`$PATH_NET_SNMP_CONFIG --cflags`
31635	SNMP_CPPFLAGS=
31636	SNMP_CFLAGS=
31637	for i in $foo; do
31638	    case "$i" in
31639	     -D*|-U*|-I*)
31640		SNMP_CPPFLAGS="$SNMP_CPPFLAGS $i"
31641		;;
31642	    *)	SNMP_CFLAGS="$SNMP_CFLAGS $i"
31643		;;
31644	    esac
31645	done
31646
31647
31648
31649	save_CFLAGS=$CFLAGS
31650	save_CPPFLAGS=$CPPFLAGS
31651	save_LIBS=$LIBS
31652	CFLAGS=$SNMP_CFLAGS
31653	CPPFLAGS=$SNMP_CPPFLAGS
31654
31655	ac_fn_c_check_header_mongrel "$LINENO" "net-snmp/net-snmp-config.h" "ac_cv_header_net_snmp_net_snmp_config_h" "$ac_includes_default"
31656if test "x$ac_cv_header_net_snmp_net_snmp_config_h" = xyes; then :
31657  MAKE_NTPSNMPD=ntpsnmpd
31658else
31659  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: net-snmp-config present but net-snmp headers are not available!" >&5
31660$as_echo "$as_me: WARNING: net-snmp-config present but net-snmp headers are not available!" >&2;}
31661
31662fi
31663
31664
31665
31666	# Do this last, as we're messing up LIBS.
31667	# check -lnetsnmp for netsnmp_daemonize
31668	LIBS=`$PATH_NET_SNMP_CONFIG --libs`
31669	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for netsnmp_daemonize in -lnetsnmp" >&5
31670$as_echo_n "checking for netsnmp_daemonize in -lnetsnmp... " >&6; }
31671if ${ac_cv_lib_netsnmp_netsnmp_daemonize+:} false; then :
31672  $as_echo_n "(cached) " >&6
31673else
31674  ac_check_lib_save_LIBS=$LIBS
31675LIBS="-lnetsnmp  $LIBS"
31676cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31677/* end confdefs.h.  */
31678
31679/* Override any GCC internal prototype to avoid an error.
31680   Use char because int might match the return type of a GCC
31681   builtin and then its argument prototype would still apply.  */
31682#ifdef __cplusplus
31683extern "C"
31684#endif
31685char netsnmp_daemonize ();
31686int
31687main ()
31688{
31689return netsnmp_daemonize ();
31690  ;
31691  return 0;
31692}
31693_ACEOF
31694if ac_fn_c_try_link "$LINENO"; then :
31695  ac_cv_lib_netsnmp_netsnmp_daemonize=yes
31696else
31697  ac_cv_lib_netsnmp_netsnmp_daemonize=no
31698fi
31699rm -f core conftest.err conftest.$ac_objext \
31700    conftest$ac_exeext conftest.$ac_ext
31701LIBS=$ac_check_lib_save_LIBS
31702fi
31703{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_netsnmp_netsnmp_daemonize" >&5
31704$as_echo "$ac_cv_lib_netsnmp_netsnmp_daemonize" >&6; }
31705if test "x$ac_cv_lib_netsnmp_netsnmp_daemonize" = xyes; then :
31706  ans=yes
31707else
31708  ans=no
31709
31710fi
31711
31712	case "$ans" in
31713	 no)
31714
31715$as_echo "#define NEED_NETSNMP_DAEMONIZE 1" >>confdefs.h
31716
31717	esac
31718
31719	CFLAGS=$save_CFLAGS
31720	{ save_CFLAGS=; unset save_CFLAGS;}
31721	CPPFLAGS=$save_CPPFLAGS
31722	{ save_CPPFLAGS=; unset save_CPPFLAGS;}
31723	LIBS=$save_LIBS
31724	{ save_LIBS=; unset save_LIBS;}
31725	;;
31726     *)
31727	{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Cannot build ntpsnmpd - net-snmp-config cannot be found" >&5
31728$as_echo "$as_me: WARNING: Cannot build ntpsnmpd - net-snmp-config cannot be found" >&2;}
31729	;;
31730    esac
31731    ;;
31732esac
31733
31734
31735case "$MAKE_NTPSNMPD" in
31736 '')
31737    NTPSNMPD_DB=
31738    NTPSNMPD_DL=
31739    NTPSNMPD_DS=
31740    NTPSNMPD_MS=
31741    ;;
31742esac
31743
31744{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should always slew the time" >&5
31745$as_echo_n "checking if we should always slew the time... " >&6; }
31746
31747# target-specific defaults
31748
31749case "$host" in
31750 *-apple-aux[23]*)
31751    ans=yes
31752    ;;
31753 *-*-bsdi[012]*)
31754    ans=no
31755    ;;
31756 *-*-bsdi*)
31757    ans=yes
31758    ;;
31759 *-*-openvms*)	# HMS: won't be found
31760    ans=yes
31761    ;;
31762 *) ans=no
31763    ;;
31764esac
31765
31766# --enable-slew-always / --disable-slew-always overrides default
31767
31768# Check whether --enable-slew-always was given.
31769if test "${enable_slew_always+set}" = set; then :
31770  enableval=$enable_slew_always; ans=$enableval
31771
31772fi
31773
31774
31775{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
31776$as_echo "$ans" >&6; }
31777
31778case "$ans" in
31779 yes)
31780
31781$as_echo "#define SLEWALWAYS 1" >>confdefs.h
31782
31783esac
31784
31785{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should step and slew the time" >&5
31786$as_echo_n "checking if we should step and slew the time... " >&6; }
31787
31788case "$host" in
31789 *-sni-sysv*)
31790    ans=yes
31791    ;;
31792 *-stratus-vos)
31793    ans=no
31794    ;;
31795 *-univel-sysv*)
31796    ans=no
31797    ;;
31798 *-*-ptx*)
31799    ans=yes
31800    ;;
31801 *-*-solaris2.1[0-9]*)
31802    ans=no
31803    ;;
31804 *-*-solaris2.[012]*)
31805    ans=yes
31806    ;;
31807 *-*-sysv4*)	# HMS: Does this catch Fujitsu UXP?
31808    ans=yes
31809    ;;
31810 *) ans=no
31811    ;;
31812esac
31813
31814# Check whether --enable-step-slew was given.
31815if test "${enable_step_slew+set}" = set; then :
31816  enableval=$enable_step_slew; ans=$enableval
31817
31818fi
31819
31820
31821{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
31822$as_echo "$ans" >&6; }
31823
31824case "$ans" in
31825 yes)
31826
31827$as_echo "#define STEP_SLEW 1" >>confdefs.h
31828
31829esac
31830
31831{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if ntpdate should step the time" >&5
31832$as_echo_n "checking if ntpdate should step the time... " >&6; }
31833
31834case "$host" in
31835 *-apple-aux[23]*)
31836    ans=yes
31837    ;;
31838 *) ans=no
31839    ;;
31840esac
31841
31842# Check whether --enable-ntpdate-step was given.
31843if test "${enable_ntpdate_step+set}" = set; then :
31844  enableval=$enable_ntpdate_step; ans=$enableval
31845
31846fi
31847
31848
31849{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
31850$as_echo "$ans" >&6; }
31851
31852case "$ans" in
31853 yes)
31854
31855$as_echo "#define FORCE_NTPDATE_STEP 1" >>confdefs.h
31856
31857esac
31858
31859
31860{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should sync TODR clock every hour" >&5
31861$as_echo_n "checking if we should sync TODR clock every hour... " >&6; }
31862
31863case "$host" in
31864 *-*-nextstep*)
31865    ans=yes
31866    ;;
31867 *-*-openvms*)	# HMS: won't be found
31868    ans=yes
31869    ;;
31870 *)
31871    ans=no
31872    ;;
31873esac
31874
31875# Check whether --enable-hourly-todr-sync was given.
31876if test "${enable_hourly_todr_sync+set}" = set; then :
31877  enableval=$enable_hourly_todr_sync; ans=$enableval
31878
31879fi
31880
31881
31882{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
31883$as_echo "$ans" >&6; }
31884
31885case "$ac_cv_var_sync_todr" in
31886 yes)
31887
31888$as_echo "#define DOSYNCTODR 1" >>confdefs.h
31889 ;;
31890esac
31891
31892
31893{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should avoid kernel FLL bug" >&5
31894$as_echo_n "checking if we should avoid kernel FLL bug... " >&6; }
31895
31896case "$host" in
31897 *-*-solaris2.6)
31898    unamev=`uname -v`
31899    case "$unamev" in
31900     Generic_105181-*)
31901	old_IFS="$IFS"
31902	IFS="-"
31903	set $unamev
31904	IFS="$old_IFS"
31905	if test "$2" -ge 17
31906	then
31907	    # Generic_105181-17 and higher
31908	    ans=no
31909	else
31910	    ans=yes
31911	fi
31912	;;
31913     *)
31914	ans=yes
31915	;;
31916    esac
31917    ;;
31918 *-*-solaris2.7)
31919    unamev=`uname -v`
31920    case "$unamev" in
31921     Generic_106541-*)
31922	old_IFS="$IFS"
31923	IFS="-"
31924	set $unamev
31925	IFS="$old_IFS"
31926	if test "$2" -ge 07
31927	then
31928	    # Generic_106541-07 and higher
31929	    ans=no
31930	else
31931	    ans=yes
31932	fi
31933	;;
31934     *)
31935	ans=yes
31936	;;
31937    esac
31938    ;;
31939 *)
31940    ans=no
31941    ;;
31942esac
31943
31944# Check whether --enable-kernel-fll-bug was given.
31945if test "${enable_kernel_fll_bug+set}" = set; then :
31946  enableval=$enable_kernel_fll_bug; ans=$enableval
31947
31948fi
31949
31950
31951{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
31952$as_echo "$ans" >&6; }
31953
31954case "$ans" in
31955 yes)
31956
31957$as_echo "#define KERNEL_FLL_BUG 1" >>confdefs.h
31958
31959esac
31960
31961
31962{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want new session key behavior" >&5
31963$as_echo_n "checking if we want new session key behavior... " >&6; }
31964# Check whether --enable-bug1243-fix was given.
31965if test "${enable_bug1243_fix+set}" = set; then :
31966  enableval=$enable_bug1243_fix; ans=$enableval
31967else
31968  ans=yes
31969
31970fi
31971
31972{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
31973$as_echo "$ans" >&6; }
31974case "$ans" in
31975 no)
31976
31977$as_echo "#define DISABLE_BUG1243_FIX 1" >>confdefs.h
31978
31979esac
31980
31981
31982{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want the explicit 127.0.0.0/8 martian filter" >&5
31983$as_echo_n "checking if we want the explicit 127.0.0.0/8 martian filter... " >&6; }
31984# Check whether --enable-bug3020-fix was given.
31985if test "${enable_bug3020_fix+set}" = set; then :
31986  enableval=$enable_bug3020_fix; ans=$enableval
31987else
31988  ans=yes
31989
31990fi
31991
31992{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
31993$as_echo "$ans" >&6; }
31994case "$ans" in
31995 yes)
31996
31997$as_echo "#define ENABLE_BUG3020_FIX 1" >>confdefs.h
31998
31999esac
32000
32001
32002{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should use the IRIG sawtooth filter" >&5
32003$as_echo_n "checking if we should use the IRIG sawtooth filter... " >&6; }
32004
32005case "$host" in
32006 *-*-solaris2.[89])
32007    ans=yes
32008    ;;
32009 *-*-solaris2.1[0-9]*)
32010    ans=yes
32011    ;;
32012 *) ans=no
32013    ;;
32014esac
32015
32016# Check whether --enable-irig-sawtooth was given.
32017if test "${enable_irig_sawtooth+set}" = set; then :
32018  enableval=$enable_irig_sawtooth; ans=$enableval
32019
32020fi
32021
32022
32023{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
32024$as_echo "$ans" >&6; }
32025
32026case "$ans" in
32027 yes)
32028
32029$as_echo "#define IRIG_SUCKS 1" >>confdefs.h
32030
32031esac
32032
32033{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should enable NIST lockclock scheme" >&5
32034$as_echo_n "checking if we should enable NIST lockclock scheme... " >&6; }
32035# Check whether --enable-nist was given.
32036if test "${enable_nist+set}" = set; then :
32037  enableval=$enable_nist; ans=$enableval
32038else
32039  ans=no
32040
32041fi
32042
32043
32044{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
32045$as_echo "$ans" >&6; }
32046
32047case "$ans" in
32048 yes)
32049
32050$as_echo "#define LOCKCLOCK 1" >>confdefs.h
32051 ;;
32052esac
32053
32054{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want support for Samba's signing daemon" >&5
32055$as_echo_n "checking if we want support for Samba's signing daemon... " >&6; }
32056# Check whether --enable-ntp-signd was given.
32057if test "${enable_ntp_signd+set}" = set; then :
32058  enableval=$enable_ntp_signd; ans=$enableval
32059else
32060  ans=no
32061
32062fi
32063
32064
32065{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
32066$as_echo "$ans" >&6; }
32067
32068case "$ans" in
32069 no)
32070    ntp_signd_path=
32071    ;;
32072 yes)
32073    ntp_signd_path=/var/run/ntp_signd
32074    ;;
32075 *)
32076    ntp_signd_path="$ans"
32077esac
32078
32079case "$ntp_signd_path" in
32080 '')
32081    ;;
32082 *)
32083
32084$as_echo "#define HAVE_NTP_SIGND 1" >>confdefs.h
32085
32086
32087cat >>confdefs.h <<_ACEOF
32088#define NTP_SIGND_PATH "$ntp_signd_path"
32089_ACEOF
32090
32091    ;;
32092esac
32093
32094for ac_header in libscf.h
32095do :
32096  ac_fn_c_check_header_mongrel "$LINENO" "libscf.h" "ac_cv_header_libscf_h" "$ac_includes_default"
32097if test "x$ac_cv_header_libscf_h" = xyes; then :
32098  cat >>confdefs.h <<_ACEOF
32099#define HAVE_LIBSCF_H 1
32100_ACEOF
32101
32102fi
32103
32104done
32105
32106LSCF=
32107case "$ac_cv_header_libscf_h" in
32108 yes)
32109    LSCF='-lscf'
32110esac
32111
32112
32113
32114
32115{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct sockaddr_storage" >&5
32116$as_echo_n "checking for struct sockaddr_storage... " >&6; }
32117if ${ntp_cv_sockaddr_storage+:} false; then :
32118  $as_echo_n "(cached) " >&6
32119else
32120  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32121/* end confdefs.h.  */
32122
32123		#ifdef HAVE_SYS_TYPES_H
32124		# include <sys/types.h>
32125		#endif
32126		#ifdef HAVE_SYS_SOCKET_H
32127		# include <sys/socket.h>
32128		#endif
32129		#ifdef HAVE_NETINET_IN_H
32130		# include <netinet/in.h>
32131		#endif
32132
32133int
32134main ()
32135{
32136
32137		struct sockaddr_storage n;
32138
32139
32140  ;
32141  return 0;
32142}
32143_ACEOF
32144if ac_fn_c_try_compile "$LINENO"; then :
32145  ntp_cv_sockaddr_storage=yes
32146else
32147  ntp_cv_sockaddr_storage=no
32148
32149fi
32150rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32151
32152fi
32153{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_sockaddr_storage" >&5
32154$as_echo "$ntp_cv_sockaddr_storage" >&6; }
32155case "$ntp_cv_sockaddr_storage" in
32156 yes)
32157
32158$as_echo "#define HAVE_STRUCT_SOCKADDR_STORAGE 1" >>confdefs.h
32159
32160    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sockaddr_storage.__ss_family" >&5
32161$as_echo_n "checking for sockaddr_storage.__ss_family... " >&6; }
32162if ${ntp_cv_have___ss_family+:} false; then :
32163  $as_echo_n "(cached) " >&6
32164else
32165  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32166/* end confdefs.h.  */
32167
32168		    #ifdef HAVE_SYS_TYPES_H
32169		    # include <sys/types.h>
32170		    #endif
32171		    #ifdef HAVE_SYS_SOCKET_H
32172		    # include <sys/socket.h>
32173		    #endif
32174		    #ifdef HAVE_NETINET_IN_H
32175		    # include <netinet/in.h>
32176		    #endif
32177
32178int
32179main ()
32180{
32181
32182		    struct sockaddr_storage s;
32183		    s.__ss_family = 1;
32184
32185
32186  ;
32187  return 0;
32188}
32189_ACEOF
32190if ac_fn_c_try_compile "$LINENO"; then :
32191  ntp_cv_have___ss_family=yes
32192else
32193  ntp_cv_have___ss_family=no
32194
32195fi
32196rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32197
32198fi
32199{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_have___ss_family" >&5
32200$as_echo "$ntp_cv_have___ss_family" >&6; }
32201    case "$ntp_cv_have___ss_family" in
32202     yes)
32203
32204$as_echo "#define HAVE___SS_FAMILY_IN_SS 1" >>confdefs.h
32205
32206    esac
32207
32208esac
32209
32210
32211#
32212# Look for in_port_t.
32213#
32214{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for in_port_t" >&5
32215$as_echo_n "checking for in_port_t... " >&6; }
32216if ${isc_cv_have_in_port_t+:} false; then :
32217  $as_echo_n "(cached) " >&6
32218else
32219  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32220/* end confdefs.h.  */
32221
32222		#include <sys/types.h>
32223		#include <netinet/in.h>
32224
32225int
32226main ()
32227{
32228
32229		in_port_t port = 25;
32230		return (0);
32231
32232
32233  ;
32234  return 0;
32235}
32236_ACEOF
32237if ac_fn_c_try_compile "$LINENO"; then :
32238  isc_cv_have_in_port_t=yes
32239else
32240  isc_cv_have_in_port_t=no
32241
32242fi
32243rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32244
32245fi
32246{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_have_in_port_t" >&5
32247$as_echo "$isc_cv_have_in_port_t" >&6; }
32248case "$isc_cv_have_in_port_t" in
32249 no)
32250
32251$as_echo "#define ISC_PLATFORM_NEEDPORTT 1" >>confdefs.h
32252
32253esac
32254
32255{ $as_echo "$as_me:${as_lineno-$LINENO}: checking type of socklen arg for getsockname()" >&5
32256$as_echo_n "checking type of socklen arg for getsockname()... " >&6; }
32257if ${ntp_cv_getsockname_socklen_type+:} false; then :
32258  $as_echo_n "(cached) " >&6
32259else
32260
32261    getsockname_socklen_type_found=no
32262    for getsockname_arg2 in 'struct sockaddr *' 'void *'; do
32263	for ntp_cv_getsockname_socklen_type in 'socklen_t' 'size_t' 'unsigned int' 'int'; do
32264	    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32265/* end confdefs.h.  */
32266
32267			#ifdef HAVE_SYS_TYPES_H
32268			# include <sys/types.h>
32269			#endif
32270			#ifdef HAVE_SYS_SOCKET_H
32271			# include <sys/socket.h>
32272			#endif
32273
32274int
32275main ()
32276{
32277
32278			extern
32279			getsockname(int, $getsockname_arg2,
32280				$ntp_cv_getsockname_socklen_type *);
32281
32282
32283  ;
32284  return 0;
32285}
32286_ACEOF
32287if ac_fn_c_try_compile "$LINENO"; then :
32288  getsockname_socklen_type_found=yes ; break 2
32289fi
32290rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32291	done
32292    done
32293    case "$getsockname_socklen_type_found" in
32294     no)
32295	ntp_cv_getsockname_socklen_type='socklen_t'
32296    esac
32297    { getsockname_arg2=; unset getsockname_arg2;}
32298    { getsockname_socklen_type_found=; unset getsockname_socklen_type_found;}
32299
32300
32301fi
32302{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_getsockname_socklen_type" >&5
32303$as_echo "$ntp_cv_getsockname_socklen_type" >&6; }
32304
32305cat >>confdefs.h <<_ACEOF
32306#define GETSOCKNAME_SOCKLEN_TYPE $ntp_cv_getsockname_socklen_type
32307_ACEOF
32308
32309
32310{ $as_echo "$as_me:${as_lineno-$LINENO}: checking struct sockaddr for sa_len" >&5
32311$as_echo_n "checking struct sockaddr for sa_len... " >&6; }
32312if ${isc_cv_platform_havesalen+:} false; then :
32313  $as_echo_n "(cached) " >&6
32314else
32315  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32316/* end confdefs.h.  */
32317
32318		#include <sys/types.h>
32319		#include <sys/socket.h>
32320
32321int
32322main ()
32323{
32324
32325		extern struct sockaddr *ps;
32326		return ps->sa_len;
32327
32328
32329  ;
32330  return 0;
32331}
32332_ACEOF
32333if ac_fn_c_try_compile "$LINENO"; then :
32334  isc_cv_platform_havesalen=yes
32335else
32336  isc_cv_platform_havesalen=no
32337
32338fi
32339rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32340
32341fi
32342{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_platform_havesalen" >&5
32343$as_echo "$isc_cv_platform_havesalen" >&6; }
32344case "$isc_cv_platform_havesalen" in
32345 yes)
32346
32347$as_echo "#define ISC_PLATFORM_HAVESALEN 1" >>confdefs.h
32348
32349esac
32350
32351# Check whether --enable-ipv6 was given.
32352if test "${enable_ipv6+set}" = set; then :
32353  enableval=$enable_ipv6;
32354fi
32355
32356
32357case "$enable_ipv6" in
32358 yes|''|autodetect)
32359    case "$host" in
32360     powerpc-ibm-aix4*)
32361	;;
32362     *)
32363
32364$as_echo "#define WANT_IPV6 1" >>confdefs.h
32365
32366	;;
32367    esac
32368    ;;
32369 no)
32370    ;;
32371esac
32372
32373
32374case "$host" in
32375 *-*-darwin*)
32376
32377$as_echo "#define __APPLE_USE_RFC_3542 1" >>confdefs.h
32378
32379esac
32380
32381
32382{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for IPv6 structures" >&5
32383$as_echo_n "checking for IPv6 structures... " >&6; }
32384if ${isc_cv_found_ipv6+:} false; then :
32385  $as_echo_n "(cached) " >&6
32386else
32387  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32388/* end confdefs.h.  */
32389
32390		#include <sys/types.h>
32391		#include <sys/socket.h>
32392		#include <netinet/in.h>
32393
32394int
32395main ()
32396{
32397
32398		struct sockaddr_in6 sin6;
32399
32400
32401  ;
32402  return 0;
32403}
32404_ACEOF
32405if ac_fn_c_try_compile "$LINENO"; then :
32406  isc_cv_found_ipv6=yes
32407else
32408  isc_cv_found_ipv6=no
32409
32410fi
32411rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32412
32413fi
32414{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_found_ipv6" >&5
32415$as_echo "$isc_cv_found_ipv6" >&6; }
32416
32417#
32418# See whether IPv6 support is provided via a Kame add-on.
32419# This is done before other IPv6 linking tests so LIBS is properly set.
32420#
32421{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Kame IPv6 support" >&5
32422$as_echo_n "checking for Kame IPv6 support... " >&6; }
32423
32424# Check whether --with-kame was given.
32425if test "${with_kame+set}" = set; then :
32426  withval=$with_kame; use_kame="$withval"
32427else
32428  use_kame="no"
32429
32430fi
32431
32432case "$use_kame" in
32433 no)
32434    ;;
32435 yes)
32436    kame_path=/usr/local/v6
32437    ;;
32438 *)
32439    kame_path="$use_kame"
32440    ;;
32441esac
32442case "$use_kame" in
32443 no)
32444    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32445$as_echo "no" >&6; }
32446    ;;
32447 *)
32448    if test -f $kame_path/lib/libinet6.a; then
32449	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $kame_path/lib/libinet6.a" >&5
32450$as_echo "$kame_path/lib/libinet6.a" >&6; }
32451	LIBS="-L$kame_path/lib -linet6 $LIBS"
32452    else
32453	as_fn_error $? "$kame_path/lib/libinet6.a not found.
32454
32455Please choose the proper path with the following command:
32456
32457    configure --with-kame=PATH
32458" "$LINENO" 5
32459    fi
32460    ;;
32461esac
32462
32463#
32464# Whether netinet6/in6.h is needed has to be defined in isc/platform.h.
32465# Including it on Kame-using platforms is very bad, though, because
32466# Kame uses #error against direct inclusion.   So include it on only
32467# the platform that is otherwise broken without it -- BSD/OS 4.0 through 4.1.
32468# This is done before the in6_pktinfo check because that's what
32469# netinet6/in6.h is needed for.
32470#
32471case "$host" in
32472 *-bsdi4.[01]*)
32473
32474$as_echo "#define ISC_PLATFORM_NEEDNETINET6IN6H 1" >>confdefs.h
32475
32476    isc_netinet6in6_hack="#include <netinet6/in6.h>"
32477    ;;
32478 *)
32479    isc_netinet6in6_hack=""
32480    ;;
32481esac
32482
32483#
32484# This is similar to the netinet6/in6.h issue.
32485#
32486case "$host" in
32487 *-sco-sysv*uw*|*-*-sysv*UnixWare*|*-*-sysv*OpenUNIX*)
32488
32489$as_echo "#define ISC_PLATFORM_FIXIN6ISADDR 1" >>confdefs.h
32490
32491    isc_netinetin6_hack="#include <netinet/in6.h>"
32492    ;;
32493 *)
32494    isc_netinetin6_hack=""
32495    ;;
32496esac
32497
32498
32499case "$isc_cv_found_ipv6" in
32500 yes)
32501
32502$as_echo "#define ISC_PLATFORM_HAVEIPV6 1" >>confdefs.h
32503
32504    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for in6_pktinfo" >&5
32505$as_echo_n "checking for in6_pktinfo... " >&6; }
32506if ${isc_cv_have_in6_pktinfo+:} false; then :
32507  $as_echo_n "(cached) " >&6
32508else
32509  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32510/* end confdefs.h.  */
32511
32512		    #include <sys/types.h>
32513		    #include <sys/socket.h>
32514		    #include <netinet/in.h>
32515		    $isc_netinetin6_hack
32516		    $isc_netinet6in6_hack
32517
32518int
32519main ()
32520{
32521
32522		    struct in6_pktinfo xyzzy;
32523
32524
32525  ;
32526  return 0;
32527}
32528_ACEOF
32529if ac_fn_c_try_compile "$LINENO"; then :
32530  isc_cv_have_in6_pktinfo=yes
32531else
32532  isc_cv_have_in6_pktinfo=no
32533
32534fi
32535rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32536
32537fi
32538{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_have_in6_pktinfo" >&5
32539$as_echo "$isc_cv_have_in6_pktinfo" >&6; }
32540    case "$isc_cv_have_in6_pktinfo" in
32541     yes)
32542
32543$as_echo "#define ISC_PLATFORM_HAVEIN6PKTINFO 1" >>confdefs.h
32544
32545    esac
32546
32547
32548    # HMS: Use HAVE_STRUCT_SOCKADDR_IN6_SIN6_SCOPE_ID instead?
32549    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sockaddr_in6.sin6_scope_id" >&5
32550$as_echo_n "checking for sockaddr_in6.sin6_scope_id... " >&6; }
32551if ${isc_cv_have_sin6_scope_id+:} false; then :
32552  $as_echo_n "(cached) " >&6
32553else
32554  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32555/* end confdefs.h.  */
32556
32557		    #include <sys/types.h>
32558		    #include <sys/socket.h>
32559		    #include <netinet/in.h>
32560		    $isc_netinetin6_hack
32561		    $isc_netinet6in6_hack
32562
32563int
32564main ()
32565{
32566
32567		    struct sockaddr_in6 xyzzy;
32568		    xyzzy.sin6_scope_id = 0;
32569
32570
32571  ;
32572  return 0;
32573}
32574_ACEOF
32575if ac_fn_c_try_compile "$LINENO"; then :
32576  isc_cv_have_sin6_scope_id=yes
32577else
32578  isc_cv_have_sin6_scope_id=no
32579
32580fi
32581rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32582
32583fi
32584{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_have_sin6_scope_id" >&5
32585$as_echo "$isc_cv_have_sin6_scope_id" >&6; }
32586
32587    case "$isc_cv_have_sin6_scope_id" in
32588     yes)
32589
32590$as_echo "#define ISC_PLATFORM_HAVESCOPEID 1" >>confdefs.h
32591
32592    esac
32593esac
32594
32595
32596# We need this check run even without isc_cv_found_ipv6=yes
32597
32598{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for in6addr_any" >&5
32599$as_echo_n "checking for in6addr_any... " >&6; }
32600if ${isc_cv_in6addr_any_links+:} false; then :
32601  $as_echo_n "(cached) " >&6
32602else
32603
32604	SAVED_LIBS="$LIBS"
32605	LIBS="$LDADD_LIBNTP $LIBS"
32606	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32607/* end confdefs.h.  */
32608$ac_includes_default
32609		    #include <sys/socket.h>
32610		    #include <netinet/in.h>
32611		    $isc_netinetin6_hack
32612		    $isc_netinet6in6_hack
32613
32614int
32615main ()
32616{
32617
32618		    printf("%x", in6addr_any.s6_addr[15]);
32619
32620
32621  ;
32622  return 0;
32623}
32624_ACEOF
32625if ac_fn_c_try_link "$LINENO"; then :
32626  isc_cv_in6addr_any_links=yes
32627else
32628  isc_cv_in6addr_any_links=no
32629
32630fi
32631rm -f core conftest.err conftest.$ac_objext \
32632    conftest$ac_exeext conftest.$ac_ext
32633	LIBS="$SAVED_LIBS"
32634	{ SAVED_LIBS=; unset SAVED_LIBS;}
32635
32636
32637fi
32638{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_in6addr_any_links" >&5
32639$as_echo "$isc_cv_in6addr_any_links" >&6; }
32640
32641case "$isc_cv_in6addr_any_links" in
32642 no)
32643
32644$as_echo "#define ISC_PLATFORM_NEEDIN6ADDRANY 1" >>confdefs.h
32645
32646esac
32647
32648
32649{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct if_laddrconf" >&5
32650$as_echo_n "checking for struct if_laddrconf... " >&6; }
32651if ${isc_cv_struct_if_laddrconf+:} false; then :
32652  $as_echo_n "(cached) " >&6
32653else
32654  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32655/* end confdefs.h.  */
32656
32657		#include <sys/types.h>
32658		#include <net/if6.h>
32659
32660int
32661main ()
32662{
32663
32664		struct if_laddrconf a;
32665
32666
32667  ;
32668  return 0;
32669}
32670_ACEOF
32671if ac_fn_c_try_compile "$LINENO"; then :
32672  isc_cv_struct_if_laddrconf=yes
32673else
32674  isc_cv_struct_if_laddrconf=no
32675
32676fi
32677rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32678
32679fi
32680{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_struct_if_laddrconf" >&5
32681$as_echo "$isc_cv_struct_if_laddrconf" >&6; }
32682
32683case "$isc_cv_struct_if_laddrconf" in
32684 yes)
32685
32686$as_echo "#define ISC_PLATFORM_HAVEIF_LADDRCONF 1" >>confdefs.h
32687
32688esac
32689
32690{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct if_laddrreq" >&5
32691$as_echo_n "checking for struct if_laddrreq... " >&6; }
32692if ${isc_cv_struct_if_laddrreq+:} false; then :
32693  $as_echo_n "(cached) " >&6
32694else
32695  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32696/* end confdefs.h.  */
32697
32698		#include <sys/types.h>
32699		#include <net/if6.h>
32700
32701int
32702main ()
32703{
32704
32705		struct if_laddrreq a;
32706
32707
32708  ;
32709  return 0;
32710}
32711_ACEOF
32712if ac_fn_c_try_compile "$LINENO"; then :
32713  isc_cv_struct_if_laddrreq=yes
32714else
32715  isc_cv_struct_if_laddrreq=no
32716
32717fi
32718rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32719
32720fi
32721{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_struct_if_laddrreq" >&5
32722$as_echo "$isc_cv_struct_if_laddrreq" >&6; }
32723
32724case "$isc_cv_struct_if_laddrreq" in
32725 yes)
32726
32727$as_echo "#define ISC_PLATFORM_HAVEIF_LADDRREQ 1" >>confdefs.h
32728
32729esac
32730
32731{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for multicast IP support" >&5
32732$as_echo_n "checking for multicast IP support... " >&6; }
32733if ${ntp_cv_multicast+:} false; then :
32734  $as_echo_n "(cached) " >&6
32735else
32736
32737	ntp_cv_multicast=no
32738	case "$host" in
32739	 i386-sequent-sysv4)
32740	    ;;
32741	 *)
32742	    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32743/* end confdefs.h.  */
32744
32745			#ifdef HAVE_NETINET_IN_H
32746			# include <netinet/in.h>
32747			#endif
32748
32749int
32750main ()
32751{
32752
32753			struct ip_mreq ipmr;
32754			ipmr.imr_interface.s_addr = 0;
32755
32756
32757  ;
32758  return 0;
32759}
32760_ACEOF
32761if ac_fn_c_try_compile "$LINENO"; then :
32762  ntp_cv_multicast=yes
32763fi
32764rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32765	    ;;
32766	esac
32767
32768
32769fi
32770{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_multicast" >&5
32771$as_echo "$ntp_cv_multicast" >&6; }
32772case "$ntp_cv_multicast" in
32773 yes)
32774
32775$as_echo "#define MCAST 1" >>confdefs.h
32776
32777    { $as_echo "$as_me:${as_lineno-$LINENO}: checking arg type needed for setsockopt() IP*_MULTICAST_LOOP" >&5
32778$as_echo_n "checking arg type needed for setsockopt() IP*_MULTICAST_LOOP... " >&6; }
32779if ${ntp_cv_typeof_ip_multicast_loop+:} false; then :
32780  $as_echo_n "(cached) " >&6
32781else
32782
32783	    case "$host" in
32784	     *-*-netbsd*|*-*-*linux*)
32785		ntp_cv_typeof_ip_multicast_loop=u_int
32786		;;
32787	     *)
32788		ntp_cv_typeof_ip_multicast_loop=u_char
32789		;;
32790	    esac
32791
32792
32793fi
32794{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_typeof_ip_multicast_loop" >&5
32795$as_echo "$ntp_cv_typeof_ip_multicast_loop" >&6; }
32796
32797cat >>confdefs.h <<_ACEOF
32798#define TYPEOF_IP_MULTICAST_LOOP $ntp_cv_typeof_ip_multicast_loop
32799_ACEOF
32800
32801esac
32802
32803# Check whether --enable-getifaddrs was given.
32804if test "${enable_getifaddrs+set}" = set; then :
32805  enableval=$enable_getifaddrs; want_getifaddrs="$enableval"
32806else
32807  want_getifaddrs="yes"
32808
32809fi
32810
32811
32812case $want_getifaddrs in
32813 glibc)
32814    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --enable-getifaddrs=glibc is no longer required" >&5
32815$as_echo "$as_me: WARNING: --enable-getifaddrs=glibc is no longer required" >&2;}
32816esac
32817case $want_getifaddrs in
32818 no)
32819    ;;
32820 *)
32821    SAVED_LIBS="$LIBS"
32822    LIBS="$LDADD_LIBNTP $LIBS"
32823    for ac_func in getifaddrs
32824do :
32825  ac_fn_c_check_func "$LINENO" "getifaddrs" "ac_cv_func_getifaddrs"
32826if test "x$ac_cv_func_getifaddrs" = xyes; then :
32827  cat >>confdefs.h <<_ACEOF
32828#define HAVE_GETIFADDRS 1
32829_ACEOF
32830
32831fi
32832done
32833
32834    LIBS="$SAVED_LIBS"
32835    { SAVED_LIBS=; unset SAVED_LIBS;}
32836    ;;
32837esac
32838
32839#
32840# Check for if_nametoindex() for IPv6 scoped addresses support
32841#
32842case "$host" in
32843 *-hp-hpux*)
32844    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing if_nametoindex" >&5
32845$as_echo_n "checking for library containing if_nametoindex... " >&6; }
32846if ${ac_cv_search_if_nametoindex+:} false; then :
32847  $as_echo_n "(cached) " >&6
32848else
32849  ac_func_search_save_LIBS=$LIBS
32850cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32851/* end confdefs.h.  */
32852
32853/* Override any GCC internal prototype to avoid an error.
32854   Use char because int might match the return type of a GCC
32855   builtin and then its argument prototype would still apply.  */
32856#ifdef __cplusplus
32857extern "C"
32858#endif
32859char if_nametoindex ();
32860int
32861main ()
32862{
32863return if_nametoindex ();
32864  ;
32865  return 0;
32866}
32867_ACEOF
32868for ac_lib in '' ipv6; do
32869  if test -z "$ac_lib"; then
32870    ac_res="none required"
32871  else
32872    ac_res=-l$ac_lib
32873    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
32874  fi
32875  if ac_fn_c_try_link "$LINENO"; then :
32876  ac_cv_search_if_nametoindex=$ac_res
32877fi
32878rm -f core conftest.err conftest.$ac_objext \
32879    conftest$ac_exeext
32880  if ${ac_cv_search_if_nametoindex+:} false; then :
32881  break
32882fi
32883done
32884if ${ac_cv_search_if_nametoindex+:} false; then :
32885
32886else
32887  ac_cv_search_if_nametoindex=no
32888fi
32889rm conftest.$ac_ext
32890LIBS=$ac_func_search_save_LIBS
32891fi
32892{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_if_nametoindex" >&5
32893$as_echo "$ac_cv_search_if_nametoindex" >&6; }
32894ac_res=$ac_cv_search_if_nametoindex
32895if test "$ac_res" != no; then :
32896  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
32897
32898fi
32899
32900esac
32901SAVED_LIBS="$LIBS"
32902LIBS="$LDADD_LIBNTP $LIBS"
32903for ac_func in if_nametoindex
32904do :
32905  ac_fn_c_check_func "$LINENO" "if_nametoindex" "ac_cv_func_if_nametoindex"
32906if test "x$ac_cv_func_if_nametoindex" = xyes; then :
32907  cat >>confdefs.h <<_ACEOF
32908#define HAVE_IF_NAMETOINDEX 1
32909_ACEOF
32910
32911fi
32912done
32913
32914LIBS="$SAVED_LIBS"
32915{ SAVED_LIBS=; unset SAVED_LIBS;}
32916case "$ac_cv_func_if_nametoindex" in
32917 yes)
32918
32919$as_echo "#define ISC_PLATFORM_HAVEIFNAMETOINDEX 1" >>confdefs.h
32920
32921esac
32922
32923
32924
32925
32926#
32927# Look for a sysctl call to get the list of network interfaces.
32928#
32929{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for interface list sysctl" >&5
32930$as_echo_n "checking for interface list sysctl... " >&6; }
32931if ${ntp_cv_iflist_sysctl+:} false; then :
32932  $as_echo_n "(cached) " >&6
32933else
32934  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32935/* end confdefs.h.  */
32936
32937	    #include <sys/param.h>
32938	    #include <sys/sysctl.h>
32939	    #include <sys/socket.h>
32940	    #ifndef NET_RT_IFLIST
32941	    # error
32942	    #endif
32943
32944_ACEOF
32945if ac_fn_c_try_cpp "$LINENO"; then :
32946  ntp_cv_iflist_sysctl=yes
32947else
32948  ntp_cv_iflist_sysctl=no
32949
32950fi
32951rm -f conftest.err conftest.i conftest.$ac_ext
32952
32953fi
32954{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_iflist_sysctl" >&5
32955$as_echo "$ntp_cv_iflist_sysctl" >&6; }
32956case "$ntp_cv_iflist_sysctl" in
32957 yes)
32958
32959$as_echo "#define HAVE_IFLIST_SYSCTL 1" >>confdefs.h
32960
32961esac
32962
32963###
32964
32965{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want the saveconfig mechanism" >&5
32966$as_echo_n "checking if we want the saveconfig mechanism... " >&6; }
32967# Check whether --enable-saveconfig was given.
32968if test "${enable_saveconfig+set}" = set; then :
32969  enableval=$enable_saveconfig; ntp_ok=$enableval
32970else
32971  ntp_ok=yes
32972
32973fi
32974
32975ntp_saveconfig_enabled=0
32976case "$ntp_ok" in
32977 yes)
32978    ntp_saveconfig_enabled=1
32979
32980$as_echo "#define SAVECONFIG 1" >>confdefs.h
32981
32982    ;;
32983esac
32984 if test x$ntp_saveconfig_enabled = x1; then
32985  SAVECONFIG_ENABLED_TRUE=
32986  SAVECONFIG_ENABLED_FALSE='#'
32987else
32988  SAVECONFIG_ENABLED_TRUE='#'
32989  SAVECONFIG_ENABLED_FALSE=
32990fi
32991
32992{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
32993$as_echo "$ntp_ok" >&6; }
32994
32995###
32996
32997{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want the experimental leap smear code" >&5
32998$as_echo_n "checking if we want the experimental leap smear code... " >&6; }
32999# Check whether --enable-leap-smear was given.
33000if test "${enable_leap_smear+set}" = set; then :
33001  enableval=$enable_leap_smear; ntp_ok=$enableval
33002else
33003  ntp_ok=no
33004
33005fi
33006
33007ntp_leap_smear_enabled=0
33008case "$ntp_ok" in
33009 yes)
33010    ntp_leap_smear_enabled=1
33011
33012$as_echo "#define LEAP_SMEAR 1" >>confdefs.h
33013
33014
33015    HAVE_LEAPSMEARINTERVAL="leapsmearinterval 0"
33016    ;;
33017esac
33018{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
33019$as_echo "$ntp_ok" >&6; }
33020
33021###
33022
33023{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want dynamic interleave support" >&5
33024$as_echo_n "checking if we want dynamic interleave support... " >&6; }
33025# Check whether --enable-dynamic-interleave was given.
33026if test "${enable_dynamic_interleave+set}" = set; then :
33027  enableval=$enable_dynamic_interleave; ntp_ok=$enableval
33028else
33029  ntp_ok=no
33030
33031fi
33032
33033ntp_dynamic_interleave=0
33034case "$ntp_ok" in
33035 yes)
33036    ntp_dynamic_interleave=1
33037    ;;
33038esac
33039
33040cat >>confdefs.h <<_ACEOF
33041#define DYNAMIC_INTERLEAVE $ntp_dynamic_interleave
33042_ACEOF
33043
33044{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
33045$as_echo "$ntp_ok" >&6; }
33046
33047
33048# We may not need have_unity
33049have_unity=false
33050# Extract the first word of "ruby", so it can be a program name with args.
33051set dummy ruby; ac_word=$2
33052{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
33053$as_echo_n "checking for $ac_word... " >&6; }
33054if ${ac_cv_path_PATH_RUBY+:} false; then :
33055  $as_echo_n "(cached) " >&6
33056else
33057  case $PATH_RUBY in
33058  [\\/]* | ?:[\\/]*)
33059  ac_cv_path_PATH_RUBY="$PATH_RUBY" # Let the user override the test with a path.
33060  ;;
33061  *)
33062  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33063for as_dir in $PATH
33064do
33065  IFS=$as_save_IFS
33066  test -z "$as_dir" && as_dir=.
33067    for ac_exec_ext in '' $ac_executable_extensions; do
33068  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
33069    ac_cv_path_PATH_RUBY="$as_dir/$ac_word$ac_exec_ext"
33070    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
33071    break 2
33072  fi
33073done
33074  done
33075IFS=$as_save_IFS
33076
33077  ;;
33078esac
33079fi
33080PATH_RUBY=$ac_cv_path_PATH_RUBY
33081if test -n "$PATH_RUBY"; then
33082  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATH_RUBY" >&5
33083$as_echo "$PATH_RUBY" >&6; }
33084else
33085  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33086$as_echo "no" >&6; }
33087fi
33088
33089
33090case "$PATH_RUBY" in
33091 /*)
33092    have_unity=true
33093    ;;
33094 *) PATH_RUBY="false"
33095    ;;
33096esac
33097# We may not need UNITYBUILD_AVAILABLE
33098 if $have_unity; then
33099  UNITYBUILD_AVAILABLE_TRUE=
33100  UNITYBUILD_AVAILABLE_FALSE='#'
33101else
33102  UNITYBUILD_AVAILABLE_TRUE='#'
33103  UNITYBUILD_AVAILABLE_FALSE=
33104fi
33105
33106
33107
33108
33109
33110gta=false
33111
33112# Check whether --with-gtest was given.
33113if test "${with_gtest+set}" = set; then :
33114  withval=$with_gtest; try_gtest=$withval
33115else
33116  try_gtest=yes
33117
33118fi
33119
33120case "$try_gtest" in
33121 yes)
33122    # Extract the first word of "gtest-config", so it can be a program name with args.
33123set dummy gtest-config; ac_word=$2
33124{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
33125$as_echo_n "checking for $ac_word... " >&6; }
33126if ${ac_cv_path_GTEST_CONFIG+:} false; then :
33127  $as_echo_n "(cached) " >&6
33128else
33129  case $GTEST_CONFIG in
33130  [\\/]* | ?:[\\/]*)
33131  ac_cv_path_GTEST_CONFIG="$GTEST_CONFIG" # Let the user override the test with a path.
33132  ;;
33133  *)
33134  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33135for as_dir in $PATH
33136do
33137  IFS=$as_save_IFS
33138  test -z "$as_dir" && as_dir=.
33139    for ac_exec_ext in '' $ac_executable_extensions; do
33140  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
33141    ac_cv_path_GTEST_CONFIG="$as_dir/$ac_word$ac_exec_ext"
33142    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
33143    break 2
33144  fi
33145done
33146  done
33147IFS=$as_save_IFS
33148
33149  ;;
33150esac
33151fi
33152GTEST_CONFIG=$ac_cv_path_GTEST_CONFIG
33153if test -n "$GTEST_CONFIG"; then
33154  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTEST_CONFIG" >&5
33155$as_echo "$GTEST_CONFIG" >&6; }
33156else
33157  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33158$as_echo "no" >&6; }
33159fi
33160
33161
33162    { ac_cv_path_GTEST_CONFIG=; unset ac_cv_path_GTEST_CONFIG;}
33163    case x${GTEST_CONFIG} in
33164     x) ;;
33165     *)
33166	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking gtest version" >&5
33167$as_echo_n "checking gtest version... " >&6; }
33168	gtest_version_test=`$GTEST_CONFIG --min-version=1.5 || echo toolow`
33169	case "$gtest_version_test" in
33170	 toolow*)
33171	    ;;
33172	 *)
33173	    GTEST_LDFLAGS=`$GTEST_CONFIG --ldflags`
33174	    GTEST_LIBS=`$GTEST_CONFIG --libs`
33175	    GTEST_CXXFLAGS=`$GTEST_CONFIG --cxxflags`
33176	    GTEST_CPPFLAGS=`$GTEST_CONFIG --cppflags`
33177
33178
33179
33180
33181	    gta=true
33182	    ;;
33183	esac
33184	gtest_version=`$GTEST_CONFIG --version`
33185	case "$gta" in
33186	 true)
33187	    { $as_echo "$as_me:${as_lineno-$LINENO}: result: ($gtest_version) ok" >&5
33188$as_echo "($gtest_version) ok" >&6; }
33189	    ;;
33190	 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: ($gtest_version) not ok" >&5
33191$as_echo "($gtest_version) not ok" >&6; }
33192	    ;;
33193	esac
33194	{ gtest_version_test=; unset gtest_version_test;}
33195	{ gtest_version=; unset gtest_version;}
33196    esac
33197esac
33198 if $gta; then
33199  GTEST_AVAILABLE_TRUE=
33200  GTEST_AVAILABLE_FALSE='#'
33201else
33202  GTEST_AVAILABLE_TRUE='#'
33203  GTEST_AVAILABLE_FALSE=
33204fi
33205
33206
33207
33208
33209
33210case "$build" in
33211 $host)	cross=0 ;;
33212 *)	cross=1 ;;
33213esac
33214
33215{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want to enable tests with undiagnosed problems" >&5
33216$as_echo_n "checking if we want to enable tests with undiagnosed problems... " >&6; }
33217# Check whether --enable-problem-tests was given.
33218if test "${enable_problem_tests+set}" = set; then :
33219  enableval=$enable_problem_tests; ntp_ept=$enableval
33220else
33221  ntp_ept=yes
33222
33223fi
33224
33225{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ept" >&5
33226$as_echo "$ntp_ept" >&6; }
33227
33228{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can run test-ntp_restrict" >&5
33229$as_echo_n "checking if we can run test-ntp_restrict... " >&6; }
33230ntp_test_ntp_restrict="no"
33231case "$ntp_ept:$cross:$host" in
33232 no:0:*-*-freebsd6.4) ;;
33233 no:0:*-*-hpux11.23*) ;;
33234 no:0:*-*-solaris*) ;;
33235 *) ntp_test_ntp_restrict="yes" ;;
33236esac
33237{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_test_ntp_restrict" >&5
33238$as_echo "$ntp_test_ntp_restrict" >&6; }
33239 if test x$ntp_test_ntp_restrict = xyes; then
33240  BUILD_TEST_NTP_RESTRICT_TRUE=
33241  BUILD_TEST_NTP_RESTRICT_FALSE='#'
33242else
33243  BUILD_TEST_NTP_RESTRICT_TRUE='#'
33244  BUILD_TEST_NTP_RESTRICT_FALSE=
33245fi
33246
33247
33248{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can run test-ntp_scanner" >&5
33249$as_echo_n "checking if we can run test-ntp_scanner... " >&6; }
33250ntp_test_ntp_scanner="no"
33251case "$ntp_ept:$cross:$host" in
33252 no:0:*-*-freebsd6.4) ;;
33253 no:0:*-*-solaris*) ;;
33254 *) ntp_test_ntp_scanner="yes" ;;
33255esac
33256{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_test_ntp_scanner" >&5
33257$as_echo "$ntp_test_ntp_scanner" >&6; }
33258 if test x$ntp_test_ntp_scanner = xyes; then
33259  BUILD_TEST_NTP_SCANNER_TRUE=
33260  BUILD_TEST_NTP_SCANNER_FALSE='#'
33261else
33262  BUILD_TEST_NTP_SCANNER_TRUE='#'
33263  BUILD_TEST_NTP_SCANNER_FALSE=
33264fi
33265
33266
33267{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can run test-ntp_signd" >&5
33268$as_echo_n "checking if we can run test-ntp_signd... " >&6; }
33269ntp_test_ntp_signd="no"
33270case "$ntp_ept:$cross:$host" in
33271 no:0:*-*-freebsd6.4) ;;
33272 no:0:*-*-solaris*) ;;
33273 *) ntp_test_ntp_signd="yes" ;;
33274esac
33275{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_test_ntp_signd" >&5
33276$as_echo "$ntp_test_ntp_signd" >&6; }
33277 if test x$ntp_test_ntp_signd = xyes; then
33278  BUILD_TEST_NTP_SIGND_TRUE=
33279  BUILD_TEST_NTP_SIGND_FALSE='#'
33280else
33281  BUILD_TEST_NTP_SIGND_TRUE='#'
33282  BUILD_TEST_NTP_SIGND_FALSE=
33283fi
33284
33285
33286
33287
33288###
33289
33290ac_fn_c_check_decl "$LINENO" "sigsetjmp" "ac_cv_have_decl_sigsetjmp" "#include <setjmp.h>
33291"
33292if test "x$ac_cv_have_decl_sigsetjmp" = xyes; then :
33293  ac_have_decl=1
33294else
33295  ac_have_decl=0
33296fi
33297
33298cat >>confdefs.h <<_ACEOF
33299#define HAVE_DECL_SIGSETJMP $ac_have_decl
33300_ACEOF
33301ac_fn_c_check_decl "$LINENO" "siglongjmp" "ac_cv_have_decl_siglongjmp" "#include <setjmp.h>
33302"
33303if test "x$ac_cv_have_decl_siglongjmp" = xyes; then :
33304  ac_have_decl=1
33305else
33306  ac_have_decl=0
33307fi
33308
33309cat >>confdefs.h <<_ACEOF
33310#define HAVE_DECL_SIGLONGJMP $ac_have_decl
33311_ACEOF
33312
33313
33314###
33315
33316
33317  prefix_NONE=
33318  exec_prefix_NONE=
33319  test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix
33320  test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix
33321  eval ac_define_dir="\"$sysconfdir\""
33322  eval ac_define_dir="\"$ac_define_dir\""
33323  NTP_KEYSDIR="$ac_define_dir"
33324
33325
33326cat >>confdefs.h <<_ACEOF
33327#define NTP_KEYSDIR "$ac_define_dir"
33328_ACEOF
33329
33330  test "$prefix_NONE" && prefix=NONE
33331  test "$exec_prefix_NONE" && exec_prefix=NONE
33332
33333
33334ac_config_files="$ac_config_files Makefile"
33335
33336ac_config_files="$ac_config_files adjtimed/Makefile"
33337
33338ac_config_files="$ac_config_files clockstuff/Makefile"
33339
33340ac_config_files="$ac_config_files include/Makefile"
33341
33342ac_config_files="$ac_config_files include/isc/Makefile"
33343
33344ac_config_files="$ac_config_files kernel/Makefile"
33345
33346ac_config_files="$ac_config_files kernel/sys/Makefile"
33347
33348ac_config_files="$ac_config_files libntp/Makefile"
33349
33350ac_config_files="$ac_config_files libparse/Makefile"
33351
33352ac_config_files="$ac_config_files ntpd/Makefile"
33353
33354ac_config_files="$ac_config_files ntpd/complete.conf"
33355
33356ac_config_files="$ac_config_files ntpdate/Makefile"
33357
33358ac_config_files="$ac_config_files ntpdc/Makefile"
33359
33360ac_config_files="$ac_config_files ntpdc/nl.pl"
33361
33362ac_config_files="$ac_config_files ntpq/Makefile"
33363
33364ac_config_files="$ac_config_files ntpsnmpd/Makefile"
33365
33366ac_config_files="$ac_config_files parseutil/Makefile"
33367
33368ac_config_files="$ac_config_files scripts/Makefile"
33369
33370ac_config_files="$ac_config_files scripts/build/Makefile"
33371
33372ac_config_files="$ac_config_files scripts/build/genAuthors"
33373
33374ac_config_files="$ac_config_files scripts/build/mkver"
33375
33376ac_config_files="$ac_config_files scripts/calc_tickadj/Makefile"
33377
33378ac_config_files="$ac_config_files scripts/calc_tickadj/calc_tickadj"
33379
33380ac_config_files="$ac_config_files scripts/lib/Makefile"
33381
33382ac_config_files="$ac_config_files scripts/ntp-wait/Makefile"
33383
33384ac_config_files="$ac_config_files scripts/ntp-wait/ntp-wait"
33385
33386ac_config_files="$ac_config_files scripts/ntpsweep/Makefile"
33387
33388ac_config_files="$ac_config_files scripts/ntpsweep/ntpsweep"
33389
33390ac_config_files="$ac_config_files scripts/ntptrace/Makefile"
33391
33392ac_config_files="$ac_config_files scripts/ntptrace/ntptrace"
33393
33394ac_config_files="$ac_config_files scripts/ntpver"
33395
33396ac_config_files="$ac_config_files scripts/plot_summary"
33397
33398ac_config_files="$ac_config_files scripts/summary"
33399
33400ac_config_files="$ac_config_files scripts/update-leap/Makefile"
33401
33402ac_config_files="$ac_config_files scripts/update-leap/update-leap"
33403
33404ac_config_files="$ac_config_files tests/Makefile"
33405
33406ac_config_files="$ac_config_files tests/bug-2803/Makefile"
33407
33408ac_config_files="$ac_config_files tests/libntp/Makefile"
33409
33410ac_config_files="$ac_config_files tests/ntpd/Makefile"
33411
33412ac_config_files="$ac_config_files tests/ntpq/Makefile"
33413
33414ac_config_files="$ac_config_files tests/sandbox/Makefile"
33415
33416ac_config_files="$ac_config_files tests/sec-2853/Makefile"
33417
33418ac_config_files="$ac_config_files util/Makefile"
33419
33420
33421perllibdir="${datadir}/ntp/lib"
33422
33423  prefix_NONE=
33424  exec_prefix_NONE=
33425  test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix
33426  test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix
33427  eval ac_define_dir="\"$perllibdir\""
33428  eval ac_define_dir="\"$ac_define_dir\""
33429  PERLLIBDIR="$ac_define_dir"
33430
33431
33432cat >>confdefs.h <<_ACEOF
33433#define PERLLIBDIR "$ac_define_dir"
33434_ACEOF
33435
33436  test "$prefix_NONE" && prefix=NONE
33437  test "$exec_prefix_NONE" && exec_prefix=NONE
33438
33439
33440calc_tickadj_opts="$srcdir/scripts/calc_tickadj/calc_tickadj-opts"
33441
33442ntp_wait_opts="$srcdir/scripts/ntp-wait/ntp-wait-opts"
33443
33444ntpsweep_opts="$srcdir/scripts/ntpsweep/ntpsweep-opts"
33445
33446ntptrace_opts="$srcdir/scripts/ntptrace/ntptrace-opts"
33447
33448summary_opts="$srcdir/scripts/summary-opts"
33449
33450plot_summary_opts="$srcdir/scripts/plot_summary-opts"
33451
33452
33453
33454
33455subdirs="$subdirs sntp"
33456
33457
33458cat >confcache <<\_ACEOF
33459# This file is a shell script that caches the results of configure
33460# tests run on this system so they can be shared between configure
33461# scripts and configure runs, see configure's option --config-cache.
33462# It is not useful on other systems.  If it contains results you don't
33463# want to keep, you may remove or edit it.
33464#
33465# config.status only pays attention to the cache file if you give it
33466# the --recheck option to rerun configure.
33467#
33468# `ac_cv_env_foo' variables (set or unset) will be overridden when
33469# loading this file, other *unset* `ac_cv_foo' will be assigned the
33470# following values.
33471
33472_ACEOF
33473
33474# The following way of writing the cache mishandles newlines in values,
33475# but we know of no workaround that is simple, portable, and efficient.
33476# So, we kill variables containing newlines.
33477# Ultrix sh set writes to stderr and can't be redirected directly,
33478# and sets the high bit in the cache file unless we assign to the vars.
33479(
33480  for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
33481    eval ac_val=\$$ac_var
33482    case $ac_val in #(
33483    *${as_nl}*)
33484      case $ac_var in #(
33485      *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
33486$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
33487      esac
33488      case $ac_var in #(
33489      _ | IFS | as_nl) ;; #(
33490      BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
33491      *) { eval $ac_var=; unset $ac_var;} ;;
33492      esac ;;
33493    esac
33494  done
33495
33496  (set) 2>&1 |
33497    case $as_nl`(ac_space=' '; set) 2>&1` in #(
33498    *${as_nl}ac_space=\ *)
33499      # `set' does not quote correctly, so add quotes: double-quote
33500      # substitution turns \\\\ into \\, and sed turns \\ into \.
33501      sed -n \
33502	"s/'/'\\\\''/g;
33503	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
33504      ;; #(
33505    *)
33506      # `set' quotes correctly as required by POSIX, so do not add quotes.
33507      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
33508      ;;
33509    esac |
33510    sort
33511) |
33512  sed '
33513     /^ac_cv_env_/b end
33514     t clear
33515     :clear
33516     s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
33517     t end
33518     s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
33519     :end' >>confcache
33520if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
33521  if test -w "$cache_file"; then
33522    if test "x$cache_file" != "x/dev/null"; then
33523      { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
33524$as_echo "$as_me: updating cache $cache_file" >&6;}
33525      if test ! -f "$cache_file" || test -h "$cache_file"; then
33526	cat confcache >"$cache_file"
33527      else
33528        case $cache_file in #(
33529        */* | ?:*)
33530	  mv -f confcache "$cache_file"$$ &&
33531	  mv -f "$cache_file"$$ "$cache_file" ;; #(
33532        *)
33533	  mv -f confcache "$cache_file" ;;
33534	esac
33535      fi
33536    fi
33537  else
33538    { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
33539$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
33540  fi
33541fi
33542rm -f confcache
33543
33544test "x$prefix" = xNONE && prefix=$ac_default_prefix
33545# Let make expand exec_prefix.
33546test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
33547
33548DEFS=-DHAVE_CONFIG_H
33549
33550ac_libobjs=
33551ac_ltlibobjs=
33552U=
33553for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
33554  # 1. Remove the extension, and $U if already installed.
33555  ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
33556  ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
33557  # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
33558  #    will be set to the directory where LIBOBJS objects are built.
33559  as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
33560  as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
33561done
33562LIBOBJS=$ac_libobjs
33563
33564LTLIBOBJS=$ac_ltlibobjs
33565
33566
33567{ $as_echo "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5
33568$as_echo_n "checking that generated files are newer than configure... " >&6; }
33569   if test -n "$am_sleep_pid"; then
33570     # Hide warnings about reused PIDs.
33571     wait $am_sleep_pid 2>/dev/null
33572   fi
33573   { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5
33574$as_echo "done" >&6; }
33575 if test -n "$EXEEXT"; then
33576  am__EXEEXT_TRUE=
33577  am__EXEEXT_FALSE='#'
33578else
33579  am__EXEEXT_TRUE='#'
33580  am__EXEEXT_FALSE=
33581fi
33582
33583if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
33584  as_fn_error $? "conditional \"AMDEP\" was never defined.
33585Usually this means the macro was only invoked conditionally." "$LINENO" 5
33586fi
33587if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
33588  as_fn_error $? "conditional \"am__fastdepCC\" was never defined.
33589Usually this means the macro was only invoked conditionally." "$LINENO" 5
33590fi
33591
33592if test -z "${VPATH_HACK_TRUE}" && test -z "${VPATH_HACK_FALSE}"; then
33593  as_fn_error $? "conditional \"VPATH_HACK\" was never defined.
33594Usually this means the macro was only invoked conditionally." "$LINENO" 5
33595fi
33596if test -z "${WANT_CALC_TICKADJ_MS_TRUE}" && test -z "${WANT_CALC_TICKADJ_MS_FALSE}"; then
33597  as_fn_error $? "conditional \"WANT_CALC_TICKADJ_MS\" was never defined.
33598Usually this means the macro was only invoked conditionally." "$LINENO" 5
33599fi
33600if test -z "${INSTALL_NTPSWEEP_TRUE}" && test -z "${INSTALL_NTPSWEEP_FALSE}"; then
33601  as_fn_error $? "conditional \"INSTALL_NTPSWEEP\" was never defined.
33602Usually this means the macro was only invoked conditionally." "$LINENO" 5
33603fi
33604if test -z "${INSTALL_UPDATE_LEAP_TRUE}" && test -z "${INSTALL_UPDATE_LEAP_FALSE}"; then
33605  as_fn_error $? "conditional \"INSTALL_UPDATE_LEAP\" was never defined.
33606Usually this means the macro was only invoked conditionally." "$LINENO" 5
33607fi
33608if test -z "${GL_GENERATE_STDNORETURN_H_TRUE}" && test -z "${GL_GENERATE_STDNORETURN_H_FALSE}"; then
33609  as_fn_error $? "conditional \"GL_GENERATE_STDNORETURN_H\" was never defined.
33610Usually this means the macro was only invoked conditionally." "$LINENO" 5
33611fi
33612if test -z "${INSTALL_LIBOPTS_TRUE}" && test -z "${INSTALL_LIBOPTS_FALSE}"; then
33613  as_fn_error $? "conditional \"INSTALL_LIBOPTS\" was never defined.
33614Usually this means the macro was only invoked conditionally." "$LINENO" 5
33615fi
33616if test -z "${NEED_LIBOPTS_TRUE}" && test -z "${NEED_LIBOPTS_FALSE}"; then
33617  as_fn_error $? "conditional \"NEED_LIBOPTS\" was never defined.
33618Usually this means the macro was only invoked conditionally." "$LINENO" 5
33619fi
33620if test -z "${BUILD_LIBEVENT_TRUE}" && test -z "${BUILD_LIBEVENT_FALSE}"; then
33621  as_fn_error $? "conditional \"BUILD_LIBEVENT\" was never defined.
33622Usually this means the macro was only invoked conditionally." "$LINENO" 5
33623fi
33624if test -z "${NTP_CROSSCOMPILE_TRUE}" && test -z "${NTP_CROSSCOMPILE_FALSE}"; then
33625  as_fn_error $? "conditional \"NTP_CROSSCOMPILE\" was never defined.
33626Usually this means the macro was only invoked conditionally." "$LINENO" 5
33627fi
33628if test -z "${PTHREADS_TRUE}" && test -z "${PTHREADS_FALSE}"; then
33629  as_fn_error $? "conditional \"PTHREADS\" was never defined.
33630Usually this means the macro was only invoked conditionally." "$LINENO" 5
33631fi
33632if test -z "${BUILD_SNTP_TRUE}" && test -z "${BUILD_SNTP_FALSE}"; then
33633  as_fn_error $? "conditional \"BUILD_SNTP\" was never defined.
33634Usually this means the macro was only invoked conditionally." "$LINENO" 5
33635fi
33636if test -z "${SAVECONFIG_ENABLED_TRUE}" && test -z "${SAVECONFIG_ENABLED_FALSE}"; then
33637  as_fn_error $? "conditional \"SAVECONFIG_ENABLED\" was never defined.
33638Usually this means the macro was only invoked conditionally." "$LINENO" 5
33639fi
33640if test -z "${UNITYBUILD_AVAILABLE_TRUE}" && test -z "${UNITYBUILD_AVAILABLE_FALSE}"; then
33641  as_fn_error $? "conditional \"UNITYBUILD_AVAILABLE\" was never defined.
33642Usually this means the macro was only invoked conditionally." "$LINENO" 5
33643fi
33644if test -z "${GTEST_AVAILABLE_TRUE}" && test -z "${GTEST_AVAILABLE_FALSE}"; then
33645  as_fn_error $? "conditional \"GTEST_AVAILABLE\" was never defined.
33646Usually this means the macro was only invoked conditionally." "$LINENO" 5
33647fi
33648if test -z "${BUILD_TEST_NTP_RESTRICT_TRUE}" && test -z "${BUILD_TEST_NTP_RESTRICT_FALSE}"; then
33649  as_fn_error $? "conditional \"BUILD_TEST_NTP_RESTRICT\" was never defined.
33650Usually this means the macro was only invoked conditionally." "$LINENO" 5
33651fi
33652if test -z "${BUILD_TEST_NTP_SCANNER_TRUE}" && test -z "${BUILD_TEST_NTP_SCANNER_FALSE}"; then
33653  as_fn_error $? "conditional \"BUILD_TEST_NTP_SCANNER\" was never defined.
33654Usually this means the macro was only invoked conditionally." "$LINENO" 5
33655fi
33656if test -z "${BUILD_TEST_NTP_SIGND_TRUE}" && test -z "${BUILD_TEST_NTP_SIGND_FALSE}"; then
33657  as_fn_error $? "conditional \"BUILD_TEST_NTP_SIGND\" was never defined.
33658Usually this means the macro was only invoked conditionally." "$LINENO" 5
33659fi
33660
33661: "${CONFIG_STATUS=./config.status}"
33662ac_write_fail=0
33663ac_clean_files_save=$ac_clean_files
33664ac_clean_files="$ac_clean_files $CONFIG_STATUS"
33665{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
33666$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
33667as_write_fail=0
33668cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
33669#! $SHELL
33670# Generated by $as_me.
33671# Run this file to recreate the current configuration.
33672# Compiler output produced by configure, useful for debugging
33673# configure, is in config.log if it exists.
33674
33675debug=false
33676ac_cs_recheck=false
33677ac_cs_silent=false
33678
33679SHELL=\${CONFIG_SHELL-$SHELL}
33680export SHELL
33681_ASEOF
33682cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
33683## -------------------- ##
33684## M4sh Initialization. ##
33685## -------------------- ##
33686
33687# Be more Bourne compatible
33688DUALCASE=1; export DUALCASE # for MKS sh
33689if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
33690  emulate sh
33691  NULLCMD=:
33692  # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
33693  # is contrary to our usage.  Disable this feature.
33694  alias -g '${1+"$@"}'='"$@"'
33695  setopt NO_GLOB_SUBST
33696else
33697  case `(set -o) 2>/dev/null` in #(
33698  *posix*) :
33699    set -o posix ;; #(
33700  *) :
33701     ;;
33702esac
33703fi
33704
33705
33706as_nl='
33707'
33708export as_nl
33709# Printing a long string crashes Solaris 7 /usr/bin/printf.
33710as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
33711as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
33712as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
33713# Prefer a ksh shell builtin over an external printf program on Solaris,
33714# but without wasting forks for bash or zsh.
33715if test -z "$BASH_VERSION$ZSH_VERSION" \
33716    && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
33717  as_echo='print -r --'
33718  as_echo_n='print -rn --'
33719elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
33720  as_echo='printf %s\n'
33721  as_echo_n='printf %s'
33722else
33723  if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
33724    as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
33725    as_echo_n='/usr/ucb/echo -n'
33726  else
33727    as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
33728    as_echo_n_body='eval
33729      arg=$1;
33730      case $arg in #(
33731      *"$as_nl"*)
33732	expr "X$arg" : "X\\(.*\\)$as_nl";
33733	arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
33734      esac;
33735      expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
33736    '
33737    export as_echo_n_body
33738    as_echo_n='sh -c $as_echo_n_body as_echo'
33739  fi
33740  export as_echo_body
33741  as_echo='sh -c $as_echo_body as_echo'
33742fi
33743
33744# The user is always right.
33745if test "${PATH_SEPARATOR+set}" != set; then
33746  PATH_SEPARATOR=:
33747  (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
33748    (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
33749      PATH_SEPARATOR=';'
33750  }
33751fi
33752
33753
33754# IFS
33755# We need space, tab and new line, in precisely that order.  Quoting is
33756# there to prevent editors from complaining about space-tab.
33757# (If _AS_PATH_WALK were called with IFS unset, it would disable word
33758# splitting by setting IFS to empty value.)
33759IFS=" ""	$as_nl"
33760
33761# Find who we are.  Look in the path if we contain no directory separator.
33762as_myself=
33763case $0 in #((
33764  *[\\/]* ) as_myself=$0 ;;
33765  *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33766for as_dir in $PATH
33767do
33768  IFS=$as_save_IFS
33769  test -z "$as_dir" && as_dir=.
33770    test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
33771  done
33772IFS=$as_save_IFS
33773
33774     ;;
33775esac
33776# We did not find ourselves, most probably we were run as `sh COMMAND'
33777# in which case we are not to be found in the path.
33778if test "x$as_myself" = x; then
33779  as_myself=$0
33780fi
33781if test ! -f "$as_myself"; then
33782  $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
33783  exit 1
33784fi
33785
33786# Unset variables that we do not need and which cause bugs (e.g. in
33787# pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
33788# suppresses any "Segmentation fault" message there.  '((' could
33789# trigger a bug in pdksh 5.2.14.
33790for as_var in BASH_ENV ENV MAIL MAILPATH
33791do eval test x\${$as_var+set} = xset \
33792  && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
33793done
33794PS1='$ '
33795PS2='> '
33796PS4='+ '
33797
33798# NLS nuisances.
33799LC_ALL=C
33800export LC_ALL
33801LANGUAGE=C
33802export LANGUAGE
33803
33804# CDPATH.
33805(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
33806
33807
33808# as_fn_error STATUS ERROR [LINENO LOG_FD]
33809# ----------------------------------------
33810# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
33811# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
33812# script with STATUS, using 1 if that was 0.
33813as_fn_error ()
33814{
33815  as_status=$1; test $as_status -eq 0 && as_status=1
33816  if test "$4"; then
33817    as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
33818    $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
33819  fi
33820  $as_echo "$as_me: error: $2" >&2
33821  as_fn_exit $as_status
33822} # as_fn_error
33823
33824
33825# as_fn_set_status STATUS
33826# -----------------------
33827# Set $? to STATUS, without forking.
33828as_fn_set_status ()
33829{
33830  return $1
33831} # as_fn_set_status
33832
33833# as_fn_exit STATUS
33834# -----------------
33835# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
33836as_fn_exit ()
33837{
33838  set +e
33839  as_fn_set_status $1
33840  exit $1
33841} # as_fn_exit
33842
33843# as_fn_unset VAR
33844# ---------------
33845# Portably unset VAR.
33846as_fn_unset ()
33847{
33848  { eval $1=; unset $1;}
33849}
33850as_unset=as_fn_unset
33851# as_fn_append VAR VALUE
33852# ----------------------
33853# Append the text in VALUE to the end of the definition contained in VAR. Take
33854# advantage of any shell optimizations that allow amortized linear growth over
33855# repeated appends, instead of the typical quadratic growth present in naive
33856# implementations.
33857if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
33858  eval 'as_fn_append ()
33859  {
33860    eval $1+=\$2
33861  }'
33862else
33863  as_fn_append ()
33864  {
33865    eval $1=\$$1\$2
33866  }
33867fi # as_fn_append
33868
33869# as_fn_arith ARG...
33870# ------------------
33871# Perform arithmetic evaluation on the ARGs, and store the result in the
33872# global $as_val. Take advantage of shells that can avoid forks. The arguments
33873# must be portable across $(()) and expr.
33874if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
33875  eval 'as_fn_arith ()
33876  {
33877    as_val=$(( $* ))
33878  }'
33879else
33880  as_fn_arith ()
33881  {
33882    as_val=`expr "$@" || test $? -eq 1`
33883  }
33884fi # as_fn_arith
33885
33886
33887if expr a : '\(a\)' >/dev/null 2>&1 &&
33888   test "X`expr 00001 : '.*\(...\)'`" = X001; then
33889  as_expr=expr
33890else
33891  as_expr=false
33892fi
33893
33894if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
33895  as_basename=basename
33896else
33897  as_basename=false
33898fi
33899
33900if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
33901  as_dirname=dirname
33902else
33903  as_dirname=false
33904fi
33905
33906as_me=`$as_basename -- "$0" ||
33907$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
33908	 X"$0" : 'X\(//\)$' \| \
33909	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
33910$as_echo X/"$0" |
33911    sed '/^.*\/\([^/][^/]*\)\/*$/{
33912	    s//\1/
33913	    q
33914	  }
33915	  /^X\/\(\/\/\)$/{
33916	    s//\1/
33917	    q
33918	  }
33919	  /^X\/\(\/\).*/{
33920	    s//\1/
33921	    q
33922	  }
33923	  s/.*/./; q'`
33924
33925# Avoid depending upon Character Ranges.
33926as_cr_letters='abcdefghijklmnopqrstuvwxyz'
33927as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
33928as_cr_Letters=$as_cr_letters$as_cr_LETTERS
33929as_cr_digits='0123456789'
33930as_cr_alnum=$as_cr_Letters$as_cr_digits
33931
33932ECHO_C= ECHO_N= ECHO_T=
33933case `echo -n x` in #(((((
33934-n*)
33935  case `echo 'xy\c'` in
33936  *c*) ECHO_T='	';;	# ECHO_T is single tab character.
33937  xy)  ECHO_C='\c';;
33938  *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
33939       ECHO_T='	';;
33940  esac;;
33941*)
33942  ECHO_N='-n';;
33943esac
33944
33945rm -f conf$$ conf$$.exe conf$$.file
33946if test -d conf$$.dir; then
33947  rm -f conf$$.dir/conf$$.file
33948else
33949  rm -f conf$$.dir
33950  mkdir conf$$.dir 2>/dev/null
33951fi
33952if (echo >conf$$.file) 2>/dev/null; then
33953  if ln -s conf$$.file conf$$ 2>/dev/null; then
33954    as_ln_s='ln -s'
33955    # ... but there are two gotchas:
33956    # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
33957    # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
33958    # In both cases, we have to default to `cp -pR'.
33959    ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
33960      as_ln_s='cp -pR'
33961  elif ln conf$$.file conf$$ 2>/dev/null; then
33962    as_ln_s=ln
33963  else
33964    as_ln_s='cp -pR'
33965  fi
33966else
33967  as_ln_s='cp -pR'
33968fi
33969rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
33970rmdir conf$$.dir 2>/dev/null
33971
33972
33973# as_fn_mkdir_p
33974# -------------
33975# Create "$as_dir" as a directory, including parents if necessary.
33976as_fn_mkdir_p ()
33977{
33978
33979  case $as_dir in #(
33980  -*) as_dir=./$as_dir;;
33981  esac
33982  test -d "$as_dir" || eval $as_mkdir_p || {
33983    as_dirs=
33984    while :; do
33985      case $as_dir in #(
33986      *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
33987      *) as_qdir=$as_dir;;
33988      esac
33989      as_dirs="'$as_qdir' $as_dirs"
33990      as_dir=`$as_dirname -- "$as_dir" ||
33991$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
33992	 X"$as_dir" : 'X\(//\)[^/]' \| \
33993	 X"$as_dir" : 'X\(//\)$' \| \
33994	 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
33995$as_echo X"$as_dir" |
33996    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
33997	    s//\1/
33998	    q
33999	  }
34000	  /^X\(\/\/\)[^/].*/{
34001	    s//\1/
34002	    q
34003	  }
34004	  /^X\(\/\/\)$/{
34005	    s//\1/
34006	    q
34007	  }
34008	  /^X\(\/\).*/{
34009	    s//\1/
34010	    q
34011	  }
34012	  s/.*/./; q'`
34013      test -d "$as_dir" && break
34014    done
34015    test -z "$as_dirs" || eval "mkdir $as_dirs"
34016  } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
34017
34018
34019} # as_fn_mkdir_p
34020if mkdir -p . 2>/dev/null; then
34021  as_mkdir_p='mkdir -p "$as_dir"'
34022else
34023  test -d ./-p && rmdir ./-p
34024  as_mkdir_p=false
34025fi
34026
34027
34028# as_fn_executable_p FILE
34029# -----------------------
34030# Test if FILE is an executable regular file.
34031as_fn_executable_p ()
34032{
34033  test -f "$1" && test -x "$1"
34034} # as_fn_executable_p
34035as_test_x='test -x'
34036as_executable_p=as_fn_executable_p
34037
34038# Sed expression to map a string onto a valid CPP name.
34039as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
34040
34041# Sed expression to map a string onto a valid variable name.
34042as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
34043
34044
34045exec 6>&1
34046## ----------------------------------- ##
34047## Main body of $CONFIG_STATUS script. ##
34048## ----------------------------------- ##
34049_ASEOF
34050test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
34051
34052cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
34053# Save the log message, to keep $0 and so on meaningful, and to
34054# report actual input values of CONFIG_FILES etc. instead of their
34055# values after options handling.
34056ac_log="
34057This file was extended by ntp $as_me 4.2.8p12, which was
34058generated by GNU Autoconf 2.69.  Invocation command line was
34059
34060  CONFIG_FILES    = $CONFIG_FILES
34061  CONFIG_HEADERS  = $CONFIG_HEADERS
34062  CONFIG_LINKS    = $CONFIG_LINKS
34063  CONFIG_COMMANDS = $CONFIG_COMMANDS
34064  $ $0 $@
34065
34066on `(hostname || uname -n) 2>/dev/null | sed 1q`
34067"
34068
34069_ACEOF
34070
34071case $ac_config_files in *"
34072"*) set x $ac_config_files; shift; ac_config_files=$*;;
34073esac
34074
34075case $ac_config_headers in *"
34076"*) set x $ac_config_headers; shift; ac_config_headers=$*;;
34077esac
34078
34079
34080cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
34081# Files that config.status was made for.
34082config_files="$ac_config_files"
34083config_headers="$ac_config_headers"
34084config_commands="$ac_config_commands"
34085
34086_ACEOF
34087
34088cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
34089ac_cs_usage="\
34090\`$as_me' instantiates files and other configuration actions
34091from templates according to the current configuration.  Unless the files
34092and actions are specified as TAGs, all are instantiated by default.
34093
34094Usage: $0 [OPTION]... [TAG]...
34095
34096  -h, --help       print this help, then exit
34097  -V, --version    print version number and configuration settings, then exit
34098      --config     print configuration, then exit
34099  -q, --quiet, --silent
34100                   do not print progress messages
34101  -d, --debug      don't remove temporary files
34102      --recheck    update $as_me by reconfiguring in the same conditions
34103      --file=FILE[:TEMPLATE]
34104                   instantiate the configuration file FILE
34105      --header=FILE[:TEMPLATE]
34106                   instantiate the configuration header FILE
34107
34108Configuration files:
34109$config_files
34110
34111Configuration headers:
34112$config_headers
34113
34114Configuration commands:
34115$config_commands
34116
34117Report bugs to <http://bugs.ntp.org./>.
34118ntp home page: <http://www.ntp.org./>."
34119
34120_ACEOF
34121cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
34122ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
34123ac_cs_version="\\
34124ntp config.status 4.2.8p12
34125configured by $0, generated by GNU Autoconf 2.69,
34126  with options \\"\$ac_cs_config\\"
34127
34128Copyright (C) 2012 Free Software Foundation, Inc.
34129This config.status script is free software; the Free Software Foundation
34130gives unlimited permission to copy, distribute and modify it."
34131
34132ac_pwd='$ac_pwd'
34133srcdir='$srcdir'
34134INSTALL='$INSTALL'
34135MKDIR_P='$MKDIR_P'
34136AWK='$AWK'
34137test -n "\$AWK" || AWK=awk
34138_ACEOF
34139
34140cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
34141# The default lists apply if the user does not specify any file.
34142ac_need_defaults=:
34143while test $# != 0
34144do
34145  case $1 in
34146  --*=?*)
34147    ac_option=`expr "X$1" : 'X\([^=]*\)='`
34148    ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
34149    ac_shift=:
34150    ;;
34151  --*=)
34152    ac_option=`expr "X$1" : 'X\([^=]*\)='`
34153    ac_optarg=
34154    ac_shift=:
34155    ;;
34156  *)
34157    ac_option=$1
34158    ac_optarg=$2
34159    ac_shift=shift
34160    ;;
34161  esac
34162
34163  case $ac_option in
34164  # Handling of the options.
34165  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
34166    ac_cs_recheck=: ;;
34167  --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
34168    $as_echo "$ac_cs_version"; exit ;;
34169  --config | --confi | --conf | --con | --co | --c )
34170    $as_echo "$ac_cs_config"; exit ;;
34171  --debug | --debu | --deb | --de | --d | -d )
34172    debug=: ;;
34173  --file | --fil | --fi | --f )
34174    $ac_shift
34175    case $ac_optarg in
34176    *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
34177    '') as_fn_error $? "missing file argument" ;;
34178    esac
34179    as_fn_append CONFIG_FILES " '$ac_optarg'"
34180    ac_need_defaults=false;;
34181  --header | --heade | --head | --hea )
34182    $ac_shift
34183    case $ac_optarg in
34184    *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
34185    esac
34186    as_fn_append CONFIG_HEADERS " '$ac_optarg'"
34187    ac_need_defaults=false;;
34188  --he | --h)
34189    # Conflict between --help and --header
34190    as_fn_error $? "ambiguous option: \`$1'
34191Try \`$0 --help' for more information.";;
34192  --help | --hel | -h )
34193    $as_echo "$ac_cs_usage"; exit ;;
34194  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
34195  | -silent | --silent | --silen | --sile | --sil | --si | --s)
34196    ac_cs_silent=: ;;
34197
34198  # This is an error.
34199  -*) as_fn_error $? "unrecognized option: \`$1'
34200Try \`$0 --help' for more information." ;;
34201
34202  *) as_fn_append ac_config_targets " $1"
34203     ac_need_defaults=false ;;
34204
34205  esac
34206  shift
34207done
34208
34209ac_configure_extra_args=
34210
34211if $ac_cs_silent; then
34212  exec 6>/dev/null
34213  ac_configure_extra_args="$ac_configure_extra_args --silent"
34214fi
34215
34216_ACEOF
34217cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
34218if \$ac_cs_recheck; then
34219  set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
34220  shift
34221  \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
34222  CONFIG_SHELL='$SHELL'
34223  export CONFIG_SHELL
34224  exec "\$@"
34225fi
34226
34227_ACEOF
34228cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
34229exec 5>>config.log
34230{
34231  echo
34232  sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
34233## Running $as_me. ##
34234_ASBOX
34235  $as_echo "$ac_log"
34236} >&5
34237
34238_ACEOF
34239cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
34240#
34241# INIT-COMMANDS
34242#
34243AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
34244
34245
34246# The HP-UX ksh and POSIX shell print the target directory to stdout
34247# if CDPATH is set.
34248(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
34249
34250sed_quote_subst='$sed_quote_subst'
34251double_quote_subst='$double_quote_subst'
34252delay_variable_subst='$delay_variable_subst'
34253enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`'
34254macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`'
34255macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`'
34256enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`'
34257pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`'
34258enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`'
34259shared_archive_member_spec='`$ECHO "$shared_archive_member_spec" | $SED "$delay_single_quote_subst"`'
34260SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`'
34261ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`'
34262PATH_SEPARATOR='`$ECHO "$PATH_SEPARATOR" | $SED "$delay_single_quote_subst"`'
34263host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`'
34264host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`'
34265host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`'
34266build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`'
34267build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`'
34268build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`'
34269SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`'
34270Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`'
34271GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`'
34272EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`'
34273FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`'
34274LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`'
34275NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`'
34276LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`'
34277max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`'
34278ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`'
34279exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
34280lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
34281lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
34282lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
34283lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`'
34284lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`'
34285reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`'
34286reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`'
34287OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`'
34288deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`'
34289file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`'
34290file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`'
34291want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`'
34292DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`'
34293sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`'
34294AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`'
34295AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`'
34296archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`'
34297STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
34298RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
34299old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
34300old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
34301old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`'
34302lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`'
34303CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`'
34304CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`'
34305compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`'
34306GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`'
34307lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`'
34308lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
34309lt_cv_sys_global_symbol_to_import='`$ECHO "$lt_cv_sys_global_symbol_to_import" | $SED "$delay_single_quote_subst"`'
34310lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
34311lt_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"`'
34312lt_cv_nm_interface='`$ECHO "$lt_cv_nm_interface" | $SED "$delay_single_quote_subst"`'
34313nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`'
34314lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`'
34315lt_cv_truncate_bin='`$ECHO "$lt_cv_truncate_bin" | $SED "$delay_single_quote_subst"`'
34316objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`'
34317MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`'
34318lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`'
34319lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`'
34320lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
34321lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`'
34322lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`'
34323need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`'
34324MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`'
34325DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
34326NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
34327LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
34328OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`'
34329OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`'
34330libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`'
34331shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`'
34332extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
34333archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`'
34334enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`'
34335export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`'
34336whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`'
34337compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`'
34338old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`'
34339old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
34340archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`'
34341archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`'
34342module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`'
34343module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`'
34344with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`'
34345allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`'
34346no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`'
34347hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`'
34348hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`'
34349hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`'
34350hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`'
34351hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`'
34352hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`'
34353hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
34354inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
34355link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
34356always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`'
34357export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`'
34358exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`'
34359include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`'
34360prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`'
34361postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`'
34362file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
34363variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
34364need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
34365need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`'
34366version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`'
34367runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`'
34368shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`'
34369shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`'
34370libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`'
34371library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`'
34372soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`'
34373install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`'
34374postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`'
34375postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
34376finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`'
34377finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`'
34378hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`'
34379sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`'
34380configure_time_dlsearch_path='`$ECHO "$configure_time_dlsearch_path" | $SED "$delay_single_quote_subst"`'
34381configure_time_lt_sys_library_path='`$ECHO "$configure_time_lt_sys_library_path" | $SED "$delay_single_quote_subst"`'
34382hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`'
34383enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`'
34384enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`'
34385enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`'
34386old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`'
34387striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`'
34388
34389LTCC='$LTCC'
34390LTCFLAGS='$LTCFLAGS'
34391compiler='$compiler_DEFAULT'
34392
34393# A function that is used when there is no print builtin or printf.
34394func_fallback_echo ()
34395{
34396  eval 'cat <<_LTECHO_EOF
34397\$1
34398_LTECHO_EOF'
34399}
34400
34401# Quote evaled strings.
34402for var in SHELL \
34403ECHO \
34404PATH_SEPARATOR \
34405SED \
34406GREP \
34407EGREP \
34408FGREP \
34409LD \
34410NM \
34411LN_S \
34412lt_SP2NL \
34413lt_NL2SP \
34414reload_flag \
34415OBJDUMP \
34416deplibs_check_method \
34417file_magic_cmd \
34418file_magic_glob \
34419want_nocaseglob \
34420DLLTOOL \
34421sharedlib_from_linklib_cmd \
34422AR \
34423AR_FLAGS \
34424archiver_list_spec \
34425STRIP \
34426RANLIB \
34427CC \
34428CFLAGS \
34429compiler \
34430lt_cv_sys_global_symbol_pipe \
34431lt_cv_sys_global_symbol_to_cdecl \
34432lt_cv_sys_global_symbol_to_import \
34433lt_cv_sys_global_symbol_to_c_name_address \
34434lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
34435lt_cv_nm_interface \
34436nm_file_list_spec \
34437lt_cv_truncate_bin \
34438lt_prog_compiler_no_builtin_flag \
34439lt_prog_compiler_pic \
34440lt_prog_compiler_wl \
34441lt_prog_compiler_static \
34442lt_cv_prog_compiler_c_o \
34443need_locks \
34444MANIFEST_TOOL \
34445DSYMUTIL \
34446NMEDIT \
34447LIPO \
34448OTOOL \
34449OTOOL64 \
34450shrext_cmds \
34451export_dynamic_flag_spec \
34452whole_archive_flag_spec \
34453compiler_needs_object \
34454with_gnu_ld \
34455allow_undefined_flag \
34456no_undefined_flag \
34457hardcode_libdir_flag_spec \
34458hardcode_libdir_separator \
34459exclude_expsyms \
34460include_expsyms \
34461file_list_spec \
34462variables_saved_for_relink \
34463libname_spec \
34464library_names_spec \
34465soname_spec \
34466install_override_mode \
34467finish_eval \
34468old_striplib \
34469striplib; do
34470    case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
34471    *[\\\\\\\`\\"\\\$]*)
34472      eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes
34473      ;;
34474    *)
34475      eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
34476      ;;
34477    esac
34478done
34479
34480# Double-quote double-evaled strings.
34481for var in reload_cmds \
34482old_postinstall_cmds \
34483old_postuninstall_cmds \
34484old_archive_cmds \
34485extract_expsyms_cmds \
34486old_archive_from_new_cmds \
34487old_archive_from_expsyms_cmds \
34488archive_cmds \
34489archive_expsym_cmds \
34490module_cmds \
34491module_expsym_cmds \
34492export_symbols_cmds \
34493prelink_cmds \
34494postlink_cmds \
34495postinstall_cmds \
34496postuninstall_cmds \
34497finish_cmds \
34498sys_lib_search_path_spec \
34499configure_time_dlsearch_path \
34500configure_time_lt_sys_library_path; do
34501    case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
34502    *[\\\\\\\`\\"\\\$]*)
34503      eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes
34504      ;;
34505    *)
34506      eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
34507      ;;
34508    esac
34509done
34510
34511ac_aux_dir='$ac_aux_dir'
34512
34513# See if we are running on zsh, and set the options that allow our
34514# commands through without removal of \ escapes INIT.
34515if test -n "\${ZSH_VERSION+set}"; then
34516   setopt NO_GLOB_SUBST
34517fi
34518
34519
34520    PACKAGE='$PACKAGE'
34521    VERSION='$VERSION'
34522    RM='$RM'
34523    ofile='$ofile'
34524
34525
34526
34527
34528_ACEOF
34529
34530cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
34531
34532# Handling of arguments.
34533for ac_config_target in $ac_config_targets
34534do
34535  case $ac_config_target in
34536    "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;;
34537    "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
34538    "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;;
34539    "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
34540    "adjtimed/Makefile") CONFIG_FILES="$CONFIG_FILES adjtimed/Makefile" ;;
34541    "clockstuff/Makefile") CONFIG_FILES="$CONFIG_FILES clockstuff/Makefile" ;;
34542    "include/Makefile") CONFIG_FILES="$CONFIG_FILES include/Makefile" ;;
34543    "include/isc/Makefile") CONFIG_FILES="$CONFIG_FILES include/isc/Makefile" ;;
34544    "kernel/Makefile") CONFIG_FILES="$CONFIG_FILES kernel/Makefile" ;;
34545    "kernel/sys/Makefile") CONFIG_FILES="$CONFIG_FILES kernel/sys/Makefile" ;;
34546    "libntp/Makefile") CONFIG_FILES="$CONFIG_FILES libntp/Makefile" ;;
34547    "libparse/Makefile") CONFIG_FILES="$CONFIG_FILES libparse/Makefile" ;;
34548    "ntpd/Makefile") CONFIG_FILES="$CONFIG_FILES ntpd/Makefile" ;;
34549    "ntpd/complete.conf") CONFIG_FILES="$CONFIG_FILES ntpd/complete.conf" ;;
34550    "ntpdate/Makefile") CONFIG_FILES="$CONFIG_FILES ntpdate/Makefile" ;;
34551    "ntpdc/Makefile") CONFIG_FILES="$CONFIG_FILES ntpdc/Makefile" ;;
34552    "ntpdc/nl.pl") CONFIG_FILES="$CONFIG_FILES ntpdc/nl.pl" ;;
34553    "ntpq/Makefile") CONFIG_FILES="$CONFIG_FILES ntpq/Makefile" ;;
34554    "ntpsnmpd/Makefile") CONFIG_FILES="$CONFIG_FILES ntpsnmpd/Makefile" ;;
34555    "parseutil/Makefile") CONFIG_FILES="$CONFIG_FILES parseutil/Makefile" ;;
34556    "scripts/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/Makefile" ;;
34557    "scripts/build/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/build/Makefile" ;;
34558    "scripts/build/genAuthors") CONFIG_FILES="$CONFIG_FILES scripts/build/genAuthors" ;;
34559    "scripts/build/mkver") CONFIG_FILES="$CONFIG_FILES scripts/build/mkver" ;;
34560    "scripts/calc_tickadj/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/calc_tickadj/Makefile" ;;
34561    "scripts/calc_tickadj/calc_tickadj") CONFIG_FILES="$CONFIG_FILES scripts/calc_tickadj/calc_tickadj" ;;
34562    "scripts/lib/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/lib/Makefile" ;;
34563    "scripts/ntp-wait/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/ntp-wait/Makefile" ;;
34564    "scripts/ntp-wait/ntp-wait") CONFIG_FILES="$CONFIG_FILES scripts/ntp-wait/ntp-wait" ;;
34565    "scripts/ntpsweep/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/ntpsweep/Makefile" ;;
34566    "scripts/ntpsweep/ntpsweep") CONFIG_FILES="$CONFIG_FILES scripts/ntpsweep/ntpsweep" ;;
34567    "scripts/ntptrace/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/ntptrace/Makefile" ;;
34568    "scripts/ntptrace/ntptrace") CONFIG_FILES="$CONFIG_FILES scripts/ntptrace/ntptrace" ;;
34569    "scripts/ntpver") CONFIG_FILES="$CONFIG_FILES scripts/ntpver" ;;
34570    "scripts/plot_summary") CONFIG_FILES="$CONFIG_FILES scripts/plot_summary" ;;
34571    "scripts/summary") CONFIG_FILES="$CONFIG_FILES scripts/summary" ;;
34572    "scripts/update-leap/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/update-leap/Makefile" ;;
34573    "scripts/update-leap/update-leap") CONFIG_FILES="$CONFIG_FILES scripts/update-leap/update-leap" ;;
34574    "tests/Makefile") CONFIG_FILES="$CONFIG_FILES tests/Makefile" ;;
34575    "tests/bug-2803/Makefile") CONFIG_FILES="$CONFIG_FILES tests/bug-2803/Makefile" ;;
34576    "tests/libntp/Makefile") CONFIG_FILES="$CONFIG_FILES tests/libntp/Makefile" ;;
34577    "tests/ntpd/Makefile") CONFIG_FILES="$CONFIG_FILES tests/ntpd/Makefile" ;;
34578    "tests/ntpq/Makefile") CONFIG_FILES="$CONFIG_FILES tests/ntpq/Makefile" ;;
34579    "tests/sandbox/Makefile") CONFIG_FILES="$CONFIG_FILES tests/sandbox/Makefile" ;;
34580    "tests/sec-2853/Makefile") CONFIG_FILES="$CONFIG_FILES tests/sec-2853/Makefile" ;;
34581    "util/Makefile") CONFIG_FILES="$CONFIG_FILES util/Makefile" ;;
34582
34583  *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
34584  esac
34585done
34586
34587
34588# If the user did not use the arguments to specify the items to instantiate,
34589# then the envvar interface is used.  Set only those that are not.
34590# We use the long form for the default assignment because of an extremely
34591# bizarre bug on SunOS 4.1.3.
34592if $ac_need_defaults; then
34593  test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
34594  test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
34595  test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
34596fi
34597
34598# Have a temporary directory for convenience.  Make it in the build tree
34599# simply because there is no reason against having it here, and in addition,
34600# creating and moving files from /tmp can sometimes cause problems.
34601# Hook for its removal unless debugging.
34602# Note that there is a small window in which the directory will not be cleaned:
34603# after its creation but before its name has been assigned to `$tmp'.
34604$debug ||
34605{
34606  tmp= ac_tmp=
34607  trap 'exit_status=$?
34608  : "${ac_tmp:=$tmp}"
34609  { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
34610' 0
34611  trap 'as_fn_exit 1' 1 2 13 15
34612}
34613# Create a (secure) tmp directory for tmp files.
34614
34615{
34616  tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
34617  test -d "$tmp"
34618}  ||
34619{
34620  tmp=./conf$$-$RANDOM
34621  (umask 077 && mkdir "$tmp")
34622} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
34623ac_tmp=$tmp
34624
34625# Set up the scripts for CONFIG_FILES section.
34626# No need to generate them if there are no CONFIG_FILES.
34627# This happens for instance with `./config.status config.h'.
34628if test -n "$CONFIG_FILES"; then
34629
34630if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
34631  ac_cs_awk_getline=:
34632  ac_cs_awk_pipe_init=
34633  ac_cs_awk_read_file='
34634      while ((getline aline < (F[key])) > 0)
34635	print(aline)
34636      close(F[key])'
34637  ac_cs_awk_pipe_fini=
34638else
34639  ac_cs_awk_getline=false
34640  ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
34641  ac_cs_awk_read_file='
34642      print "|#_!!_#|"
34643      print "cat " F[key] " &&"
34644      '$ac_cs_awk_pipe_init
34645  # The final `:' finishes the AND list.
34646  ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
34647fi
34648ac_cr=`echo X | tr X '\015'`
34649# On cygwin, bash can eat \r inside `` if the user requested igncr.
34650# But we know of no other shell where ac_cr would be empty at this
34651# point, so we can use a bashism as a fallback.
34652if test "x$ac_cr" = x; then
34653  eval ac_cr=\$\'\\r\'
34654fi
34655ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
34656if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
34657  ac_cs_awk_cr='\\r'
34658else
34659  ac_cs_awk_cr=$ac_cr
34660fi
34661
34662echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
34663_ACEOF
34664
34665# Create commands to substitute file output variables.
34666{
34667  echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
34668  echo 'cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&' &&
34669  echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
34670  echo "_ACAWK" &&
34671  echo "_ACEOF"
34672} >conf$$files.sh &&
34673. ./conf$$files.sh ||
34674  as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
34675rm -f conf$$files.sh
34676
34677{
34678  echo "cat >conf$$subs.awk <<_ACEOF" &&
34679  echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
34680  echo "_ACEOF"
34681} >conf$$subs.sh ||
34682  as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
34683ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
34684ac_delim='%!_!# '
34685for ac_last_try in false false false false false :; do
34686  . ./conf$$subs.sh ||
34687    as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
34688
34689  ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
34690  if test $ac_delim_n = $ac_delim_num; then
34691    break
34692  elif $ac_last_try; then
34693    as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
34694  else
34695    ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
34696  fi
34697done
34698rm -f conf$$subs.sh
34699
34700cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
34701cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
34702_ACEOF
34703sed -n '
34704h
34705s/^/S["/; s/!.*/"]=/
34706p
34707g
34708s/^[^!]*!//
34709:repl
34710t repl
34711s/'"$ac_delim"'$//
34712t delim
34713:nl
34714h
34715s/\(.\{148\}\)..*/\1/
34716t more1
34717s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
34718p
34719n
34720b repl
34721:more1
34722s/["\\]/\\&/g; s/^/"/; s/$/"\\/
34723p
34724g
34725s/.\{148\}//
34726t nl
34727:delim
34728h
34729s/\(.\{148\}\)..*/\1/
34730t more2
34731s/["\\]/\\&/g; s/^/"/; s/$/"/
34732p
34733b
34734:more2
34735s/["\\]/\\&/g; s/^/"/; s/$/"\\/
34736p
34737g
34738s/.\{148\}//
34739t delim
34740' <conf$$subs.awk | sed '
34741/^[^""]/{
34742  N
34743  s/\n//
34744}
34745' >>$CONFIG_STATUS || ac_write_fail=1
34746rm -f conf$$subs.awk
34747cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
34748_ACAWK
34749cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
34750  for (key in S) S_is_set[key] = 1
34751  FS = ""
34752  \$ac_cs_awk_pipe_init
34753}
34754{
34755  line = $ 0
34756  nfields = split(line, field, "@")
34757  substed = 0
34758  len = length(field[1])
34759  for (i = 2; i < nfields; i++) {
34760    key = field[i]
34761    keylen = length(key)
34762    if (S_is_set[key]) {
34763      value = S[key]
34764      line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
34765      len += length(value) + length(field[++i])
34766      substed = 1
34767    } else
34768      len += 1 + keylen
34769  }
34770  if (nfields == 3 && !substed) {
34771    key = field[2]
34772    if (F[key] != "" && line ~ /^[	 ]*@.*@[	 ]*$/) {
34773      \$ac_cs_awk_read_file
34774      next
34775    }
34776  }
34777  print line
34778}
34779\$ac_cs_awk_pipe_fini
34780_ACAWK
34781_ACEOF
34782cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
34783if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
34784  sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
34785else
34786  cat
34787fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
34788  || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
34789_ACEOF
34790
34791# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
34792# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
34793# trailing colons and then remove the whole line if VPATH becomes empty
34794# (actually we leave an empty line to preserve line numbers).
34795if test "x$srcdir" = x.; then
34796  ac_vpsub='/^[	 ]*VPATH[	 ]*=[	 ]*/{
34797h
34798s///
34799s/^/:/
34800s/[	 ]*$/:/
34801s/:\$(srcdir):/:/g
34802s/:\${srcdir}:/:/g
34803s/:@srcdir@:/:/g
34804s/^:*//
34805s/:*$//
34806x
34807s/\(=[	 ]*\).*/\1/
34808G
34809s/\n//
34810s/^[^=]*=[	 ]*$//
34811}'
34812fi
34813
34814cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
34815fi # test -n "$CONFIG_FILES"
34816
34817# Set up the scripts for CONFIG_HEADERS section.
34818# No need to generate them if there are no CONFIG_HEADERS.
34819# This happens for instance with `./config.status Makefile'.
34820if test -n "$CONFIG_HEADERS"; then
34821cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
34822BEGIN {
34823_ACEOF
34824
34825# Transform confdefs.h into an awk script `defines.awk', embedded as
34826# here-document in config.status, that substitutes the proper values into
34827# config.h.in to produce config.h.
34828
34829# Create a delimiter string that does not exist in confdefs.h, to ease
34830# handling of long lines.
34831ac_delim='%!_!# '
34832for ac_last_try in false false :; do
34833  ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
34834  if test -z "$ac_tt"; then
34835    break
34836  elif $ac_last_try; then
34837    as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
34838  else
34839    ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
34840  fi
34841done
34842
34843# For the awk script, D is an array of macro values keyed by name,
34844# likewise P contains macro parameters if any.  Preserve backslash
34845# newline sequences.
34846
34847ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
34848sed -n '
34849s/.\{148\}/&'"$ac_delim"'/g
34850t rset
34851:rset
34852s/^[	 ]*#[	 ]*define[	 ][	 ]*/ /
34853t def
34854d
34855:def
34856s/\\$//
34857t bsnl
34858s/["\\]/\\&/g
34859s/^ \('"$ac_word_re"'\)\(([^()]*)\)[	 ]*\(.*\)/P["\1"]="\2"\
34860D["\1"]=" \3"/p
34861s/^ \('"$ac_word_re"'\)[	 ]*\(.*\)/D["\1"]=" \2"/p
34862d
34863:bsnl
34864s/["\\]/\\&/g
34865s/^ \('"$ac_word_re"'\)\(([^()]*)\)[	 ]*\(.*\)/P["\1"]="\2"\
34866D["\1"]=" \3\\\\\\n"\\/p
34867t cont
34868s/^ \('"$ac_word_re"'\)[	 ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
34869t cont
34870d
34871:cont
34872n
34873s/.\{148\}/&'"$ac_delim"'/g
34874t clear
34875:clear
34876s/\\$//
34877t bsnlc
34878s/["\\]/\\&/g; s/^/"/; s/$/"/p
34879d
34880:bsnlc
34881s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
34882b cont
34883' <confdefs.h | sed '
34884s/'"$ac_delim"'/"\\\
34885"/g' >>$CONFIG_STATUS || ac_write_fail=1
34886
34887cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
34888  for (key in D) D_is_set[key] = 1
34889  FS = ""
34890}
34891/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
34892  line = \$ 0
34893  split(line, arg, " ")
34894  if (arg[1] == "#") {
34895    defundef = arg[2]
34896    mac1 = arg[3]
34897  } else {
34898    defundef = substr(arg[1], 2)
34899    mac1 = arg[2]
34900  }
34901  split(mac1, mac2, "(") #)
34902  macro = mac2[1]
34903  prefix = substr(line, 1, index(line, defundef) - 1)
34904  if (D_is_set[macro]) {
34905    # Preserve the white space surrounding the "#".
34906    print prefix "define", macro P[macro] D[macro]
34907    next
34908  } else {
34909    # Replace #undef with comments.  This is necessary, for example,
34910    # in the case of _POSIX_SOURCE, which is predefined and required
34911    # on some systems where configure will not decide to define it.
34912    if (defundef == "undef") {
34913      print "/*", prefix defundef, macro, "*/"
34914      next
34915    }
34916  }
34917}
34918{ print }
34919_ACAWK
34920_ACEOF
34921cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
34922  as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
34923fi # test -n "$CONFIG_HEADERS"
34924
34925
34926eval set X "  :F $CONFIG_FILES  :H $CONFIG_HEADERS    :C $CONFIG_COMMANDS"
34927shift
34928for ac_tag
34929do
34930  case $ac_tag in
34931  :[FHLC]) ac_mode=$ac_tag; continue;;
34932  esac
34933  case $ac_mode$ac_tag in
34934  :[FHL]*:*);;
34935  :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
34936  :[FH]-) ac_tag=-:-;;
34937  :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
34938  esac
34939  ac_save_IFS=$IFS
34940  IFS=:
34941  set x $ac_tag
34942  IFS=$ac_save_IFS
34943  shift
34944  ac_file=$1
34945  shift
34946
34947  case $ac_mode in
34948  :L) ac_source=$1;;
34949  :[FH])
34950    ac_file_inputs=
34951    for ac_f
34952    do
34953      case $ac_f in
34954      -) ac_f="$ac_tmp/stdin";;
34955      *) # Look for the file first in the build tree, then in the source tree
34956	 # (if the path is not absolute).  The absolute path cannot be DOS-style,
34957	 # because $ac_f cannot contain `:'.
34958	 test -f "$ac_f" ||
34959	   case $ac_f in
34960	   [\\/$]*) false;;
34961	   *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
34962	   esac ||
34963	   as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
34964      esac
34965      case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
34966      as_fn_append ac_file_inputs " '$ac_f'"
34967    done
34968
34969    # Let's still pretend it is `configure' which instantiates (i.e., don't
34970    # use $as_me), people would be surprised to read:
34971    #    /* config.h.  Generated by config.status.  */
34972    configure_input='Generated from '`
34973	  $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
34974	`' by configure.'
34975    if test x"$ac_file" != x-; then
34976      configure_input="$ac_file.  $configure_input"
34977      { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
34978$as_echo "$as_me: creating $ac_file" >&6;}
34979    fi
34980    # Neutralize special characters interpreted by sed in replacement strings.
34981    case $configure_input in #(
34982    *\&* | *\|* | *\\* )
34983       ac_sed_conf_input=`$as_echo "$configure_input" |
34984       sed 's/[\\\\&|]/\\\\&/g'`;; #(
34985    *) ac_sed_conf_input=$configure_input;;
34986    esac
34987
34988    case $ac_tag in
34989    *:-:* | *:-) cat >"$ac_tmp/stdin" \
34990      || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
34991    esac
34992    ;;
34993  esac
34994
34995  ac_dir=`$as_dirname -- "$ac_file" ||
34996$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
34997	 X"$ac_file" : 'X\(//\)[^/]' \| \
34998	 X"$ac_file" : 'X\(//\)$' \| \
34999	 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
35000$as_echo X"$ac_file" |
35001    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
35002	    s//\1/
35003	    q
35004	  }
35005	  /^X\(\/\/\)[^/].*/{
35006	    s//\1/
35007	    q
35008	  }
35009	  /^X\(\/\/\)$/{
35010	    s//\1/
35011	    q
35012	  }
35013	  /^X\(\/\).*/{
35014	    s//\1/
35015	    q
35016	  }
35017	  s/.*/./; q'`
35018  as_dir="$ac_dir"; as_fn_mkdir_p
35019  ac_builddir=.
35020
35021case "$ac_dir" in
35022.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
35023*)
35024  ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
35025  # A ".." for each directory in $ac_dir_suffix.
35026  ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
35027  case $ac_top_builddir_sub in
35028  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
35029  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
35030  esac ;;
35031esac
35032ac_abs_top_builddir=$ac_pwd
35033ac_abs_builddir=$ac_pwd$ac_dir_suffix
35034# for backward compatibility:
35035ac_top_builddir=$ac_top_build_prefix
35036
35037case $srcdir in
35038  .)  # We are building in place.
35039    ac_srcdir=.
35040    ac_top_srcdir=$ac_top_builddir_sub
35041    ac_abs_top_srcdir=$ac_pwd ;;
35042  [\\/]* | ?:[\\/]* )  # Absolute name.
35043    ac_srcdir=$srcdir$ac_dir_suffix;
35044    ac_top_srcdir=$srcdir
35045    ac_abs_top_srcdir=$srcdir ;;
35046  *) # Relative name.
35047    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
35048    ac_top_srcdir=$ac_top_build_prefix$srcdir
35049    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
35050esac
35051ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
35052
35053
35054  case $ac_mode in
35055  :F)
35056  #
35057  # CONFIG_FILE
35058  #
35059
35060  case $INSTALL in
35061  [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
35062  *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
35063  esac
35064  ac_MKDIR_P=$MKDIR_P
35065  case $MKDIR_P in
35066  [\\/$]* | ?:[\\/]* ) ;;
35067  */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
35068  esac
35069_ACEOF
35070
35071cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
35072# If the template does not know about datarootdir, expand it.
35073# FIXME: This hack should be removed a few years after 2.60.
35074ac_datarootdir_hack=; ac_datarootdir_seen=
35075ac_sed_dataroot='
35076/datarootdir/ {
35077  p
35078  q
35079}
35080/@datadir@/p
35081/@docdir@/p
35082/@infodir@/p
35083/@localedir@/p
35084/@mandir@/p'
35085case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
35086*datarootdir*) ac_datarootdir_seen=yes;;
35087*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
35088  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
35089$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
35090_ACEOF
35091cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
35092  ac_datarootdir_hack='
35093  s&@datadir@&$datadir&g
35094  s&@docdir@&$docdir&g
35095  s&@infodir@&$infodir&g
35096  s&@localedir@&$localedir&g
35097  s&@mandir@&$mandir&g
35098  s&\\\${datarootdir}&$datarootdir&g' ;;
35099esac
35100_ACEOF
35101
35102# Neutralize VPATH when `$srcdir' = `.'.
35103# Shell code in configure.ac might set extrasub.
35104# FIXME: do we really want to maintain this feature?
35105cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
35106ac_sed_extra="$ac_vpsub
35107$extrasub
35108_ACEOF
35109cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
35110:t
35111/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
35112s|@configure_input@|$ac_sed_conf_input|;t t
35113s&@top_builddir@&$ac_top_builddir_sub&;t t
35114s&@top_build_prefix@&$ac_top_build_prefix&;t t
35115s&@srcdir@&$ac_srcdir&;t t
35116s&@abs_srcdir@&$ac_abs_srcdir&;t t
35117s&@top_srcdir@&$ac_top_srcdir&;t t
35118s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
35119s&@builddir@&$ac_builddir&;t t
35120s&@abs_builddir@&$ac_abs_builddir&;t t
35121s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
35122s&@INSTALL@&$ac_INSTALL&;t t
35123s&@MKDIR_P@&$ac_MKDIR_P&;t t
35124$ac_datarootdir_hack
35125"
35126eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
35127if $ac_cs_awk_getline; then
35128  $AWK -f "$ac_tmp/subs.awk"
35129else
35130  $AWK -f "$ac_tmp/subs.awk" | $SHELL
35131fi \
35132  >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
35133
35134test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
35135  { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
35136  { ac_out=`sed -n '/^[	 ]*datarootdir[	 ]*:*=/p' \
35137      "$ac_tmp/out"`; test -z "$ac_out"; } &&
35138  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
35139which seems to be undefined.  Please make sure it is defined" >&5
35140$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
35141which seems to be undefined.  Please make sure it is defined" >&2;}
35142
35143  rm -f "$ac_tmp/stdin"
35144  case $ac_file in
35145  -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
35146  *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
35147  esac \
35148  || as_fn_error $? "could not create $ac_file" "$LINENO" 5
35149 ;;
35150  :H)
35151  #
35152  # CONFIG_HEADER
35153  #
35154  if test x"$ac_file" != x-; then
35155    {
35156      $as_echo "/* $configure_input  */" \
35157      && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
35158    } >"$ac_tmp/config.h" \
35159      || as_fn_error $? "could not create $ac_file" "$LINENO" 5
35160    if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
35161      { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
35162$as_echo "$as_me: $ac_file is unchanged" >&6;}
35163    else
35164      rm -f "$ac_file"
35165      mv "$ac_tmp/config.h" "$ac_file" \
35166	|| as_fn_error $? "could not create $ac_file" "$LINENO" 5
35167    fi
35168  else
35169    $as_echo "/* $configure_input  */" \
35170      && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
35171      || as_fn_error $? "could not create -" "$LINENO" 5
35172  fi
35173# Compute "$ac_file"'s index in $config_headers.
35174_am_arg="$ac_file"
35175_am_stamp_count=1
35176for _am_header in $config_headers :; do
35177  case $_am_header in
35178    $_am_arg | $_am_arg:* )
35179      break ;;
35180    * )
35181      _am_stamp_count=`expr $_am_stamp_count + 1` ;;
35182  esac
35183done
35184echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
35185$as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
35186	 X"$_am_arg" : 'X\(//\)[^/]' \| \
35187	 X"$_am_arg" : 'X\(//\)$' \| \
35188	 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
35189$as_echo X"$_am_arg" |
35190    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
35191	    s//\1/
35192	    q
35193	  }
35194	  /^X\(\/\/\)[^/].*/{
35195	    s//\1/
35196	    q
35197	  }
35198	  /^X\(\/\/\)$/{
35199	    s//\1/
35200	    q
35201	  }
35202	  /^X\(\/\).*/{
35203	    s//\1/
35204	    q
35205	  }
35206	  s/.*/./; q'`/stamp-h$_am_stamp_count
35207 ;;
35208
35209  :C)  { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
35210$as_echo "$as_me: executing $ac_file commands" >&6;}
35211 ;;
35212  esac
35213
35214
35215  case $ac_file$ac_mode in
35216    "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
35217  # Older Autoconf quotes --file arguments for eval, but not when files
35218  # are listed without --file.  Let's play safe and only enable the eval
35219  # if we detect the quoting.
35220  case $CONFIG_FILES in
35221  *\'*) eval set x "$CONFIG_FILES" ;;
35222  *)   set x $CONFIG_FILES ;;
35223  esac
35224  shift
35225  for mf
35226  do
35227    # Strip MF so we end up with the name of the file.
35228    mf=`echo "$mf" | sed -e 's/:.*$//'`
35229    # Check whether this is an Automake generated Makefile or not.
35230    # We used to match only the files named 'Makefile.in', but
35231    # some people rename them; so instead we look at the file content.
35232    # Grep'ing the first line is not enough: some people post-process
35233    # each Makefile.in and add a new line on top of each file to say so.
35234    # Grep'ing the whole file is not good either: AIX grep has a line
35235    # limit of 2048, but all sed's we know have understand at least 4000.
35236    if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
35237      dirpart=`$as_dirname -- "$mf" ||
35238$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
35239	 X"$mf" : 'X\(//\)[^/]' \| \
35240	 X"$mf" : 'X\(//\)$' \| \
35241	 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
35242$as_echo X"$mf" |
35243    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
35244	    s//\1/
35245	    q
35246	  }
35247	  /^X\(\/\/\)[^/].*/{
35248	    s//\1/
35249	    q
35250	  }
35251	  /^X\(\/\/\)$/{
35252	    s//\1/
35253	    q
35254	  }
35255	  /^X\(\/\).*/{
35256	    s//\1/
35257	    q
35258	  }
35259	  s/.*/./; q'`
35260    else
35261      continue
35262    fi
35263    # Extract the definition of DEPDIR, am__include, and am__quote
35264    # from the Makefile without running 'make'.
35265    DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
35266    test -z "$DEPDIR" && continue
35267    am__include=`sed -n 's/^am__include = //p' < "$mf"`
35268    test -z "$am__include" && continue
35269    am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
35270    # Find all dependency output files, they are included files with
35271    # $(DEPDIR) in their names.  We invoke sed twice because it is the
35272    # simplest approach to changing $(DEPDIR) to its actual value in the
35273    # expansion.
35274    for file in `sed -n "
35275      s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
35276	 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do
35277      # Make sure the directory exists.
35278      test -f "$dirpart/$file" && continue
35279      fdir=`$as_dirname -- "$file" ||
35280$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
35281	 X"$file" : 'X\(//\)[^/]' \| \
35282	 X"$file" : 'X\(//\)$' \| \
35283	 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
35284$as_echo X"$file" |
35285    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
35286	    s//\1/
35287	    q
35288	  }
35289	  /^X\(\/\/\)[^/].*/{
35290	    s//\1/
35291	    q
35292	  }
35293	  /^X\(\/\/\)$/{
35294	    s//\1/
35295	    q
35296	  }
35297	  /^X\(\/\).*/{
35298	    s//\1/
35299	    q
35300	  }
35301	  s/.*/./; q'`
35302      as_dir=$dirpart/$fdir; as_fn_mkdir_p
35303      # echo "creating $dirpart/$file"
35304      echo '# dummy' > "$dirpart/$file"
35305    done
35306  done
35307}
35308 ;;
35309    "libtool":C)
35310
35311    # See if we are running on zsh, and set the options that allow our
35312    # commands through without removal of \ escapes.
35313    if test -n "${ZSH_VERSION+set}"; then
35314      setopt NO_GLOB_SUBST
35315    fi
35316
35317    cfgfile=${ofile}T
35318    trap "$RM \"$cfgfile\"; exit 1" 1 2 15
35319    $RM "$cfgfile"
35320
35321    cat <<_LT_EOF >> "$cfgfile"
35322#! $SHELL
35323# Generated automatically by $as_me ($PACKAGE) $VERSION
35324# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
35325# NOTE: Changes made to this file will be lost: look at ltmain.sh.
35326
35327# Provide generalized library-building support services.
35328# Written by Gordon Matzigkeit, 1996
35329
35330# Copyright (C) 2014 Free Software Foundation, Inc.
35331# This is free software; see the source for copying conditions.  There is NO
35332# warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
35333
35334# GNU Libtool is free software; you can redistribute it and/or modify
35335# it under the terms of the GNU General Public License as published by
35336# the Free Software Foundation; either version 2 of of the License, or
35337# (at your option) any later version.
35338#
35339# As a special exception to the GNU General Public License, if you
35340# distribute this file as part of a program or library that is built
35341# using GNU Libtool, you may include this file under the  same
35342# distribution terms that you use for the rest of that program.
35343#
35344# GNU Libtool is distributed in the hope that it will be useful, but
35345# WITHOUT ANY WARRANTY; without even the implied warranty of
35346# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
35347# GNU General Public License for more details.
35348#
35349# You should have received a copy of the GNU General Public License
35350# along with this program.  If not, see <http://www.gnu.org/licenses/>.
35351
35352
35353# The names of the tagged configurations supported by this script.
35354available_tags=''
35355
35356# Configured defaults for sys_lib_dlsearch_path munging.
35357: \${LT_SYS_LIBRARY_PATH="$configure_time_lt_sys_library_path"}
35358
35359# ### BEGIN LIBTOOL CONFIG
35360
35361# Whether or not to build shared libraries.
35362build_libtool_libs=$enable_shared
35363
35364# Which release of libtool.m4 was used?
35365macro_version=$macro_version
35366macro_revision=$macro_revision
35367
35368# Whether or not to build static libraries.
35369build_old_libs=$enable_static
35370
35371# What type of objects to build.
35372pic_mode=$pic_mode
35373
35374# Whether or not to optimize for fast installation.
35375fast_install=$enable_fast_install
35376
35377# Shared archive member basename,for filename based shared library versioning on AIX.
35378shared_archive_member_spec=$shared_archive_member_spec
35379
35380# Shell to use when invoking shell scripts.
35381SHELL=$lt_SHELL
35382
35383# An echo program that protects backslashes.
35384ECHO=$lt_ECHO
35385
35386# The PATH separator for the build system.
35387PATH_SEPARATOR=$lt_PATH_SEPARATOR
35388
35389# The host system.
35390host_alias=$host_alias
35391host=$host
35392host_os=$host_os
35393
35394# The build system.
35395build_alias=$build_alias
35396build=$build
35397build_os=$build_os
35398
35399# A sed program that does not truncate output.
35400SED=$lt_SED
35401
35402# Sed that helps us avoid accidentally triggering echo(1) options like -n.
35403Xsed="\$SED -e 1s/^X//"
35404
35405# A grep program that handles long lines.
35406GREP=$lt_GREP
35407
35408# An ERE matcher.
35409EGREP=$lt_EGREP
35410
35411# A literal string matcher.
35412FGREP=$lt_FGREP
35413
35414# A BSD- or MS-compatible name lister.
35415NM=$lt_NM
35416
35417# Whether we need soft or hard links.
35418LN_S=$lt_LN_S
35419
35420# What is the maximum length of a command?
35421max_cmd_len=$max_cmd_len
35422
35423# Object file suffix (normally "o").
35424objext=$ac_objext
35425
35426# Executable file suffix (normally "").
35427exeext=$exeext
35428
35429# whether the shell understands "unset".
35430lt_unset=$lt_unset
35431
35432# turn spaces into newlines.
35433SP2NL=$lt_lt_SP2NL
35434
35435# turn newlines into spaces.
35436NL2SP=$lt_lt_NL2SP
35437
35438# convert \$build file names to \$host format.
35439to_host_file_cmd=$lt_cv_to_host_file_cmd
35440
35441# convert \$build files to toolchain format.
35442to_tool_file_cmd=$lt_cv_to_tool_file_cmd
35443
35444# An object symbol dumper.
35445OBJDUMP=$lt_OBJDUMP
35446
35447# Method to check whether dependent libraries are shared objects.
35448deplibs_check_method=$lt_deplibs_check_method
35449
35450# Command to use when deplibs_check_method = "file_magic".
35451file_magic_cmd=$lt_file_magic_cmd
35452
35453# How to find potential files when deplibs_check_method = "file_magic".
35454file_magic_glob=$lt_file_magic_glob
35455
35456# Find potential files using nocaseglob when deplibs_check_method = "file_magic".
35457want_nocaseglob=$lt_want_nocaseglob
35458
35459# DLL creation program.
35460DLLTOOL=$lt_DLLTOOL
35461
35462# Command to associate shared and link libraries.
35463sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd
35464
35465# The archiver.
35466AR=$lt_AR
35467
35468# Flags to create an archive.
35469AR_FLAGS=$lt_AR_FLAGS
35470
35471# How to feed a file listing to the archiver.
35472archiver_list_spec=$lt_archiver_list_spec
35473
35474# A symbol stripping program.
35475STRIP=$lt_STRIP
35476
35477# Commands used to install an old-style archive.
35478RANLIB=$lt_RANLIB
35479old_postinstall_cmds=$lt_old_postinstall_cmds
35480old_postuninstall_cmds=$lt_old_postuninstall_cmds
35481
35482# Whether to use a lock for old archive extraction.
35483lock_old_archive_extraction=$lock_old_archive_extraction
35484
35485# A C compiler.
35486LTCC=$lt_CC
35487
35488# LTCC compiler flags.
35489LTCFLAGS=$lt_CFLAGS
35490
35491# Take the output of nm and produce a listing of raw symbols and C names.
35492global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
35493
35494# Transform the output of nm in a proper C declaration.
35495global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
35496
35497# Transform the output of nm into a list of symbols to manually relocate.
35498global_symbol_to_import=$lt_lt_cv_sys_global_symbol_to_import
35499
35500# Transform the output of nm in a C name address pair.
35501global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
35502
35503# Transform the output of nm in a C name address pair when lib prefix is needed.
35504global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
35505
35506# The name lister interface.
35507nm_interface=$lt_lt_cv_nm_interface
35508
35509# Specify filename containing input files for \$NM.
35510nm_file_list_spec=$lt_nm_file_list_spec
35511
35512# The root where to search for dependent libraries,and where our libraries should be installed.
35513lt_sysroot=$lt_sysroot
35514
35515# Command to truncate a binary pipe.
35516lt_truncate_bin=$lt_lt_cv_truncate_bin
35517
35518# The name of the directory that contains temporary libtool files.
35519objdir=$objdir
35520
35521# Used to examine libraries when file_magic_cmd begins with "file".
35522MAGIC_CMD=$MAGIC_CMD
35523
35524# Must we lock files when doing compilation?
35525need_locks=$lt_need_locks
35526
35527# Manifest tool.
35528MANIFEST_TOOL=$lt_MANIFEST_TOOL
35529
35530# Tool to manipulate archived DWARF debug symbol files on Mac OS X.
35531DSYMUTIL=$lt_DSYMUTIL
35532
35533# Tool to change global to local symbols on Mac OS X.
35534NMEDIT=$lt_NMEDIT
35535
35536# Tool to manipulate fat objects and archives on Mac OS X.
35537LIPO=$lt_LIPO
35538
35539# ldd/readelf like tool for Mach-O binaries on Mac OS X.
35540OTOOL=$lt_OTOOL
35541
35542# ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4.
35543OTOOL64=$lt_OTOOL64
35544
35545# Old archive suffix (normally "a").
35546libext=$libext
35547
35548# Shared library suffix (normally ".so").
35549shrext_cmds=$lt_shrext_cmds
35550
35551# The commands to extract the exported symbol list from a shared archive.
35552extract_expsyms_cmds=$lt_extract_expsyms_cmds
35553
35554# Variables whose values should be saved in libtool wrapper scripts and
35555# restored at link time.
35556variables_saved_for_relink=$lt_variables_saved_for_relink
35557
35558# Do we need the "lib" prefix for modules?
35559need_lib_prefix=$need_lib_prefix
35560
35561# Do we need a version for libraries?
35562need_version=$need_version
35563
35564# Library versioning type.
35565version_type=$version_type
35566
35567# Shared library runtime path variable.
35568runpath_var=$runpath_var
35569
35570# Shared library path variable.
35571shlibpath_var=$shlibpath_var
35572
35573# Is shlibpath searched before the hard-coded library search path?
35574shlibpath_overrides_runpath=$shlibpath_overrides_runpath
35575
35576# Format of library name prefix.
35577libname_spec=$lt_libname_spec
35578
35579# List of archive names.  First name is the real one, the rest are links.
35580# The last name is the one that the linker finds with -lNAME
35581library_names_spec=$lt_library_names_spec
35582
35583# The coded name of the library, if different from the real name.
35584soname_spec=$lt_soname_spec
35585
35586# Permission mode override for installation of shared libraries.
35587install_override_mode=$lt_install_override_mode
35588
35589# Command to use after installation of a shared archive.
35590postinstall_cmds=$lt_postinstall_cmds
35591
35592# Command to use after uninstallation of a shared archive.
35593postuninstall_cmds=$lt_postuninstall_cmds
35594
35595# Commands used to finish a libtool library installation in a directory.
35596finish_cmds=$lt_finish_cmds
35597
35598# As "finish_cmds", except a single script fragment to be evaled but
35599# not shown.
35600finish_eval=$lt_finish_eval
35601
35602# Whether we should hardcode library paths into libraries.
35603hardcode_into_libs=$hardcode_into_libs
35604
35605# Compile-time system search path for libraries.
35606sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
35607
35608# Detected run-time system search path for libraries.
35609sys_lib_dlsearch_path_spec=$lt_configure_time_dlsearch_path
35610
35611# Explicit LT_SYS_LIBRARY_PATH set during ./configure time.
35612configure_time_lt_sys_library_path=$lt_configure_time_lt_sys_library_path
35613
35614# Whether dlopen is supported.
35615dlopen_support=$enable_dlopen
35616
35617# Whether dlopen of programs is supported.
35618dlopen_self=$enable_dlopen_self
35619
35620# Whether dlopen of statically linked programs is supported.
35621dlopen_self_static=$enable_dlopen_self_static
35622
35623# Commands to strip libraries.
35624old_striplib=$lt_old_striplib
35625striplib=$lt_striplib
35626
35627
35628# The linker used to build libraries.
35629LD=$lt_LD
35630
35631# How to create reloadable object files.
35632reload_flag=$lt_reload_flag
35633reload_cmds=$lt_reload_cmds
35634
35635# Commands used to build an old-style archive.
35636old_archive_cmds=$lt_old_archive_cmds
35637
35638# A language specific compiler.
35639CC=$lt_compiler
35640
35641# Is the compiler the GNU compiler?
35642with_gcc=$GCC
35643
35644# Compiler flag to turn off builtin functions.
35645no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
35646
35647# Additional compiler flags for building library objects.
35648pic_flag=$lt_lt_prog_compiler_pic
35649
35650# How to pass a linker flag through the compiler.
35651wl=$lt_lt_prog_compiler_wl
35652
35653# Compiler flag to prevent dynamic linking.
35654link_static_flag=$lt_lt_prog_compiler_static
35655
35656# Does compiler simultaneously support -c and -o options?
35657compiler_c_o=$lt_lt_cv_prog_compiler_c_o
35658
35659# Whether or not to add -lc for building shared libraries.
35660build_libtool_need_lc=$archive_cmds_need_lc
35661
35662# Whether or not to disallow shared libs when runtime libs are static.
35663allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes
35664
35665# Compiler flag to allow reflexive dlopens.
35666export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
35667
35668# Compiler flag to generate shared objects directly from archives.
35669whole_archive_flag_spec=$lt_whole_archive_flag_spec
35670
35671# Whether the compiler copes with passing no objects directly.
35672compiler_needs_object=$lt_compiler_needs_object
35673
35674# Create an old-style archive from a shared archive.
35675old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
35676
35677# Create a temporary old-style archive to link instead of a shared archive.
35678old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
35679
35680# Commands used to build a shared archive.
35681archive_cmds=$lt_archive_cmds
35682archive_expsym_cmds=$lt_archive_expsym_cmds
35683
35684# Commands used to build a loadable module if different from building
35685# a shared archive.
35686module_cmds=$lt_module_cmds
35687module_expsym_cmds=$lt_module_expsym_cmds
35688
35689# Whether we are building with GNU ld or not.
35690with_gnu_ld=$lt_with_gnu_ld
35691
35692# Flag that allows shared libraries with undefined symbols to be built.
35693allow_undefined_flag=$lt_allow_undefined_flag
35694
35695# Flag that enforces no undefined symbols.
35696no_undefined_flag=$lt_no_undefined_flag
35697
35698# Flag to hardcode \$libdir into a binary during linking.
35699# This must work even if \$libdir does not exist
35700hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
35701
35702# Whether we need a single "-rpath" flag with a separated argument.
35703hardcode_libdir_separator=$lt_hardcode_libdir_separator
35704
35705# Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes
35706# DIR into the resulting binary.
35707hardcode_direct=$hardcode_direct
35708
35709# Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes
35710# DIR into the resulting binary and the resulting library dependency is
35711# "absolute",i.e impossible to change by setting \$shlibpath_var if the
35712# library is relocated.
35713hardcode_direct_absolute=$hardcode_direct_absolute
35714
35715# Set to "yes" if using the -LDIR flag during linking hardcodes DIR
35716# into the resulting binary.
35717hardcode_minus_L=$hardcode_minus_L
35718
35719# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
35720# into the resulting binary.
35721hardcode_shlibpath_var=$hardcode_shlibpath_var
35722
35723# Set to "yes" if building a shared library automatically hardcodes DIR
35724# into the library and all subsequent libraries and executables linked
35725# against it.
35726hardcode_automatic=$hardcode_automatic
35727
35728# Set to yes if linker adds runtime paths of dependent libraries
35729# to runtime path list.
35730inherit_rpath=$inherit_rpath
35731
35732# Whether libtool must link a program against all its dependency libraries.
35733link_all_deplibs=$link_all_deplibs
35734
35735# Set to "yes" if exported symbols are required.
35736always_export_symbols=$always_export_symbols
35737
35738# The commands to list exported symbols.
35739export_symbols_cmds=$lt_export_symbols_cmds
35740
35741# Symbols that should not be listed in the preloaded symbols.
35742exclude_expsyms=$lt_exclude_expsyms
35743
35744# Symbols that must always be exported.
35745include_expsyms=$lt_include_expsyms
35746
35747# Commands necessary for linking programs (against libraries) with templates.
35748prelink_cmds=$lt_prelink_cmds
35749
35750# Commands necessary for finishing linking programs.
35751postlink_cmds=$lt_postlink_cmds
35752
35753# Specify filename containing input files.
35754file_list_spec=$lt_file_list_spec
35755
35756# How to hardcode a shared library path into an executable.
35757hardcode_action=$hardcode_action
35758
35759# ### END LIBTOOL CONFIG
35760
35761_LT_EOF
35762
35763    cat <<'_LT_EOF' >> "$cfgfile"
35764
35765# ### BEGIN FUNCTIONS SHARED WITH CONFIGURE
35766
35767# func_munge_path_list VARIABLE PATH
35768# -----------------------------------
35769# VARIABLE is name of variable containing _space_ separated list of
35770# directories to be munged by the contents of PATH, which is string
35771# having a format:
35772# "DIR[:DIR]:"
35773#       string "DIR[ DIR]" will be prepended to VARIABLE
35774# ":DIR[:DIR]"
35775#       string "DIR[ DIR]" will be appended to VARIABLE
35776# "DIRP[:DIRP]::[DIRA:]DIRA"
35777#       string "DIRP[ DIRP]" will be prepended to VARIABLE and string
35778#       "DIRA[ DIRA]" will be appended to VARIABLE
35779# "DIR[:DIR]"
35780#       VARIABLE will be replaced by "DIR[ DIR]"
35781func_munge_path_list ()
35782{
35783    case x$2 in
35784    x)
35785        ;;
35786    *:)
35787        eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\"
35788        ;;
35789    x:*)
35790        eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\"
35791        ;;
35792    *::*)
35793        eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\"
35794        eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\"
35795        ;;
35796    *)
35797        eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\"
35798        ;;
35799    esac
35800}
35801
35802
35803# Calculate cc_basename.  Skip known compiler wrappers and cross-prefix.
35804func_cc_basename ()
35805{
35806    for cc_temp in $*""; do
35807      case $cc_temp in
35808        compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
35809        distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
35810        \-*) ;;
35811        *) break;;
35812      esac
35813    done
35814    func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
35815}
35816
35817
35818# ### END FUNCTIONS SHARED WITH CONFIGURE
35819
35820_LT_EOF
35821
35822  case $host_os in
35823  aix3*)
35824    cat <<\_LT_EOF >> "$cfgfile"
35825# AIX sometimes has problems with the GCC collect2 program.  For some
35826# reason, if we set the COLLECT_NAMES environment variable, the problems
35827# vanish in a puff of smoke.
35828if test set != "${COLLECT_NAMES+set}"; then
35829  COLLECT_NAMES=
35830  export COLLECT_NAMES
35831fi
35832_LT_EOF
35833    ;;
35834  esac
35835
35836
35837ltmain=$ac_aux_dir/ltmain.sh
35838
35839
35840  # We use sed instead of cat because bash on DJGPP gets confused if
35841  # if finds mixed CR/LF and LF-only lines.  Since sed operates in
35842  # text mode, it properly converts lines to CR/LF.  This bash problem
35843  # is reportedly fixed, but why not run on old versions too?
35844  sed '$q' "$ltmain" >> "$cfgfile" \
35845     || (rm -f "$cfgfile"; exit 1)
35846
35847   mv -f "$cfgfile" "$ofile" ||
35848    (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
35849  chmod +x "$ofile"
35850
35851 ;;
35852    "ntpd/complete.conf":F) sed -e '/^rlimit$/d' -e '/^$/d' < ntpd/complete.conf > ntpd/complete.conf.new && mv ntpd/complete.conf.new ntpd/complete.conf ;;
35853    "ntpdc/nl.pl":F) chmod +x ntpdc/nl.pl ;;
35854    "scripts/build/genAuthors":F) chmod +x scripts/build/genAuthors ;;
35855    "scripts/build/mkver":F) chmod +x scripts/build/mkver ;;
35856    "scripts/calc_tickadj/calc_tickadj":F) chmod +x scripts/calc_tickadj/calc_tickadj ;;
35857    "scripts/ntp-wait/ntp-wait":F) chmod +x scripts/ntp-wait/ntp-wait ;;
35858    "scripts/ntpsweep/ntpsweep":F) chmod +x scripts/ntpsweep/ntpsweep ;;
35859    "scripts/ntptrace/ntptrace":F) chmod +x scripts/ntptrace/ntptrace ;;
35860    "scripts/ntpver":F) chmod +x scripts/ntpver ;;
35861    "scripts/plot_summary":F) chmod +x scripts/plot_summary ;;
35862    "scripts/summary":F) chmod +x scripts/summary ;;
35863    "scripts/update-leap/update-leap":F) chmod +x scripts/update-leap/update-leap ;;
35864
35865  esac
35866done # for ac_tag
35867
35868
35869as_fn_exit 0
35870_ACEOF
35871ac_clean_files=$ac_clean_files_save
35872
35873test $ac_write_fail = 0 ||
35874  as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
35875
35876
35877# configure is writing to config.log, and then calls config.status.
35878# config.status does its own redirection, appending to config.log.
35879# Unfortunately, on DOS this fails, as config.log is still kept open
35880# by configure, so config.status won't be able to write to it; its
35881# output is simply discarded.  So we exec the FD to /dev/null,
35882# effectively closing config.log, so it can be properly (re)opened and
35883# appended to by config.status.  When coming back to configure, we
35884# need to make the FD available again.
35885if test "$no_create" != yes; then
35886  ac_cs_success=:
35887  ac_config_status_args=
35888  test "$silent" = yes &&
35889    ac_config_status_args="$ac_config_status_args --quiet"
35890  exec 5>/dev/null
35891  $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
35892  exec 5>>config.log
35893  # Use ||, not &&, to avoid exiting from the if with $? = 1, which
35894  # would make configure fail if this is the last instruction.
35895  $ac_cs_success || as_fn_exit 1
35896fi
35897
35898#
35899# CONFIG_SUBDIRS section.
35900#
35901if test "$no_recursion" != yes; then
35902
35903  # Remove --cache-file, --srcdir, and --disable-option-checking arguments
35904  # so they do not pile up.
35905  ac_sub_configure_args=
35906  ac_prev=
35907  eval "set x $ac_configure_args"
35908  shift
35909  for ac_arg
35910  do
35911    if test -n "$ac_prev"; then
35912      ac_prev=
35913      continue
35914    fi
35915    case $ac_arg in
35916    -cache-file | --cache-file | --cache-fil | --cache-fi \
35917    | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
35918      ac_prev=cache_file ;;
35919    -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
35920    | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* \
35921    | --c=*)
35922      ;;
35923    --config-cache | -C)
35924      ;;
35925    -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
35926      ac_prev=srcdir ;;
35927    -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
35928      ;;
35929    -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
35930      ac_prev=prefix ;;
35931    -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
35932      ;;
35933    --disable-option-checking)
35934      ;;
35935    *)
35936      case $ac_arg in
35937      *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
35938      esac
35939      as_fn_append ac_sub_configure_args " '$ac_arg'" ;;
35940    esac
35941  done
35942
35943  # Always prepend --prefix to ensure using the same prefix
35944  # in subdir configurations.
35945  ac_arg="--prefix=$prefix"
35946  case $ac_arg in
35947  *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
35948  esac
35949  ac_sub_configure_args="'$ac_arg' $ac_sub_configure_args"
35950
35951  # Pass --silent
35952  if test "$silent" = yes; then
35953    ac_sub_configure_args="--silent $ac_sub_configure_args"
35954  fi
35955
35956  # Always prepend --disable-option-checking to silence warnings, since
35957  # different subdirs can have different --enable and --with options.
35958  ac_sub_configure_args="--disable-option-checking $ac_sub_configure_args"
35959
35960  ac_popdir=`pwd`
35961  for ac_dir in : $subdirs; do test "x$ac_dir" = x: && continue
35962
35963    # Do not complain, so a configure script can configure whichever
35964    # parts of a large source tree are present.
35965    test -d "$srcdir/$ac_dir" || continue
35966
35967    ac_msg="=== configuring in $ac_dir (`pwd`/$ac_dir)"
35968    $as_echo "$as_me:${as_lineno-$LINENO}: $ac_msg" >&5
35969    $as_echo "$ac_msg" >&6
35970    as_dir="$ac_dir"; as_fn_mkdir_p
35971    ac_builddir=.
35972
35973case "$ac_dir" in
35974.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
35975*)
35976  ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
35977  # A ".." for each directory in $ac_dir_suffix.
35978  ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
35979  case $ac_top_builddir_sub in
35980  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
35981  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
35982  esac ;;
35983esac
35984ac_abs_top_builddir=$ac_pwd
35985ac_abs_builddir=$ac_pwd$ac_dir_suffix
35986# for backward compatibility:
35987ac_top_builddir=$ac_top_build_prefix
35988
35989case $srcdir in
35990  .)  # We are building in place.
35991    ac_srcdir=.
35992    ac_top_srcdir=$ac_top_builddir_sub
35993    ac_abs_top_srcdir=$ac_pwd ;;
35994  [\\/]* | ?:[\\/]* )  # Absolute name.
35995    ac_srcdir=$srcdir$ac_dir_suffix;
35996    ac_top_srcdir=$srcdir
35997    ac_abs_top_srcdir=$srcdir ;;
35998  *) # Relative name.
35999    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
36000    ac_top_srcdir=$ac_top_build_prefix$srcdir
36001    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
36002esac
36003ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
36004
36005
36006    cd "$ac_dir"
36007
36008    # Check for guested configure; otherwise get Cygnus style configure.
36009    if test -f "$ac_srcdir/configure.gnu"; then
36010      ac_sub_configure=$ac_srcdir/configure.gnu
36011    elif test -f "$ac_srcdir/configure"; then
36012      ac_sub_configure=$ac_srcdir/configure
36013    elif test -f "$ac_srcdir/configure.in"; then
36014      # This should be Cygnus configure.
36015      ac_sub_configure=$ac_aux_dir/configure
36016    else
36017      { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no configuration information is in $ac_dir" >&5
36018$as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2;}
36019      ac_sub_configure=
36020    fi
36021
36022    # The recursion is here.
36023    if test -n "$ac_sub_configure"; then
36024      # Make the cache file name correct relative to the subdirectory.
36025      case $cache_file in
36026      [\\/]* | ?:[\\/]* ) ac_sub_cache_file=$cache_file ;;
36027      *) # Relative name.
36028	ac_sub_cache_file=$ac_top_build_prefix$cache_file ;;
36029      esac
36030
36031      { $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
36032$as_echo "$as_me: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&6;}
36033      # The eval makes quoting arguments work.
36034      eval "\$SHELL \"\$ac_sub_configure\" $ac_sub_configure_args \
36035	   --cache-file=\"\$ac_sub_cache_file\" --srcdir=\"\$ac_srcdir\"" ||
36036	as_fn_error $? "$ac_sub_configure failed for $ac_dir" "$LINENO" 5
36037    fi
36038
36039    cd "$ac_popdir"
36040  done
36041fi
36042if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
36043  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
36044$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
36045fi
36046
36047