]> The Tcpdump Group git mirrors - libpcap/blob - configure
Don't use our own getaddrinfo() on Windows.
[libpcap] / configure
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.69.
4 #
5 #
6 # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
7 #
8 #
9 # This configure script is free software; the Free Software Foundation
10 # gives unlimited permission to copy, distribute and modify it.
11 ## -------------------- ##
12 ## M4sh Initialization. ##
13 ## -------------------- ##
14
15 # Be more Bourne compatible
16 DUALCASE=1; export DUALCASE # for MKS sh
17 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
18 emulate sh
19 NULLCMD=:
20 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
21 # is contrary to our usage. Disable this feature.
22 alias -g '${1+"$@"}'='"$@"'
23 setopt NO_GLOB_SUBST
24 else
25 case `(set -o) 2>/dev/null` in #(
26 *posix*) :
27 set -o posix ;; #(
28 *) :
29 ;;
30 esac
31 fi
32
33
34 as_nl='
35 '
36 export as_nl
37 # Printing a long string crashes Solaris 7 /usr/bin/printf.
38 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
39 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
40 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
41 # Prefer a ksh shell builtin over an external printf program on Solaris,
42 # but without wasting forks for bash or zsh.
43 if test -z "$BASH_VERSION$ZSH_VERSION" \
44 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
45 as_echo='print -r --'
46 as_echo_n='print -rn --'
47 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
48 as_echo='printf %s\n'
49 as_echo_n='printf %s'
50 else
51 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
52 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
53 as_echo_n='/usr/ucb/echo -n'
54 else
55 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
56 as_echo_n_body='eval
57 arg=$1;
58 case $arg in #(
59 *"$as_nl"*)
60 expr "X$arg" : "X\\(.*\\)$as_nl";
61 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
62 esac;
63 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
64 '
65 export as_echo_n_body
66 as_echo_n='sh -c $as_echo_n_body as_echo'
67 fi
68 export as_echo_body
69 as_echo='sh -c $as_echo_body as_echo'
70 fi
71
72 # The user is always right.
73 if test "${PATH_SEPARATOR+set}" != set; then
74 PATH_SEPARATOR=:
75 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
76 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
77 PATH_SEPARATOR=';'
78 }
79 fi
80
81
82 # IFS
83 # We need space, tab and new line, in precisely that order. Quoting is
84 # there to prevent editors from complaining about space-tab.
85 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
86 # splitting by setting IFS to empty value.)
87 IFS=" "" $as_nl"
88
89 # Find who we are. Look in the path if we contain no directory separator.
90 as_myself=
91 case $0 in #((
92 *[\\/]* ) as_myself=$0 ;;
93 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
94 for as_dir in $PATH
95 do
96 IFS=$as_save_IFS
97 test -z "$as_dir" && as_dir=.
98 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
99 done
100 IFS=$as_save_IFS
101
102 ;;
103 esac
104 # We did not find ourselves, most probably we were run as `sh COMMAND'
105 # in which case we are not to be found in the path.
106 if test "x$as_myself" = x; then
107 as_myself=$0
108 fi
109 if test ! -f "$as_myself"; then
110 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
111 exit 1
112 fi
113
114 # Unset variables that we do not need and which cause bugs (e.g. in
115 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
116 # suppresses any "Segmentation fault" message there. '((' could
117 # trigger a bug in pdksh 5.2.14.
118 for as_var in BASH_ENV ENV MAIL MAILPATH
119 do eval test x\${$as_var+set} = xset \
120 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
121 done
122 PS1='$ '
123 PS2='> '
124 PS4='+ '
125
126 # NLS nuisances.
127 LC_ALL=C
128 export LC_ALL
129 LANGUAGE=C
130 export LANGUAGE
131
132 # CDPATH.
133 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
134
135 # Use a proper internal environment variable to ensure we don't fall
136 # into an infinite loop, continuously re-executing ourselves.
137 if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
138 _as_can_reexec=no; export _as_can_reexec;
139 # We cannot yet assume a decent shell, so we have to provide a
140 # neutralization value for shells without unset; and this also
141 # works around shells that cannot unset nonexistent variables.
142 # Preserve -v and -x to the replacement shell.
143 BASH_ENV=/dev/null
144 ENV=/dev/null
145 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
146 case $- in # ((((
147 *v*x* | *x*v* ) as_opts=-vx ;;
148 *v* ) as_opts=-v ;;
149 *x* ) as_opts=-x ;;
150 * ) as_opts= ;;
151 esac
152 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
153 # Admittedly, this is quite paranoid, since all the known shells bail
154 # out after a failed `exec'.
155 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
156 as_fn_exit 255
157 fi
158 # We don't want this to propagate to other subprocesses.
159 { _as_can_reexec=; unset _as_can_reexec;}
160 if test "x$CONFIG_SHELL" = x; then
161 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
162 emulate sh
163 NULLCMD=:
164 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
165 # is contrary to our usage. Disable this feature.
166 alias -g '\${1+\"\$@\"}'='\"\$@\"'
167 setopt NO_GLOB_SUBST
168 else
169 case \`(set -o) 2>/dev/null\` in #(
170 *posix*) :
171 set -o posix ;; #(
172 *) :
173 ;;
174 esac
175 fi
176 "
177 as_required="as_fn_return () { (exit \$1); }
178 as_fn_success () { as_fn_return 0; }
179 as_fn_failure () { as_fn_return 1; }
180 as_fn_ret_success () { return 0; }
181 as_fn_ret_failure () { return 1; }
182
183 exitcode=0
184 as_fn_success || { exitcode=1; echo as_fn_success failed.; }
185 as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
186 as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
187 as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
188 if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
189
190 else
191 exitcode=1; echo positional parameters were not saved.
192 fi
193 test x\$exitcode = x0 || exit 1
194 test -x / || exit 1"
195 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
196 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
197 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
198 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
199 test \$(( 1 + 1 )) = 2 || exit 1"
200 if (eval "$as_required") 2>/dev/null; then :
201 as_have_required=yes
202 else
203 as_have_required=no
204 fi
205 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
206
207 else
208 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
209 as_found=false
210 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
211 do
212 IFS=$as_save_IFS
213 test -z "$as_dir" && as_dir=.
214 as_found=:
215 case $as_dir in #(
216 /*)
217 for as_base in sh bash ksh sh5; do
218 # Try only shells that exist, to save several forks.
219 as_shell=$as_dir/$as_base
220 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
221 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
222 CONFIG_SHELL=$as_shell as_have_required=yes
223 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
224 break 2
225 fi
226 fi
227 done;;
228 esac
229 as_found=false
230 done
231 $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
232 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
233 CONFIG_SHELL=$SHELL as_have_required=yes
234 fi; }
235 IFS=$as_save_IFS
236
237
238 if test "x$CONFIG_SHELL" != x; then :
239 export CONFIG_SHELL
240 # We cannot yet assume a decent shell, so we have to provide a
241 # neutralization value for shells without unset; and this also
242 # works around shells that cannot unset nonexistent variables.
243 # Preserve -v and -x to the replacement shell.
244 BASH_ENV=/dev/null
245 ENV=/dev/null
246 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
247 case $- in # ((((
248 *v*x* | *x*v* ) as_opts=-vx ;;
249 *v* ) as_opts=-v ;;
250 *x* ) as_opts=-x ;;
251 * ) as_opts= ;;
252 esac
253 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
254 # Admittedly, this is quite paranoid, since all the known shells bail
255 # out after a failed `exec'.
256 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
257 exit 255
258 fi
259
260 if test x$as_have_required = xno; then :
261 $as_echo "$0: This script requires a shell more modern than all"
262 $as_echo "$0: the shells that I found on your system."
263 if test x${ZSH_VERSION+set} = xset ; then
264 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
265 $as_echo "$0: be upgraded to zsh 4.3.4 or later."
266 else
267 $as_echo "$0: Please tell bug-autoconf@gnu.org about your system,
268 $0: including any error possibly output before this
269 $0: message. Then install a modern shell, or manually run
270 $0: the script under such a shell if you do have one."
271 fi
272 exit 1
273 fi
274 fi
275 fi
276 SHELL=${CONFIG_SHELL-/bin/sh}
277 export SHELL
278 # Unset more variables known to interfere with behavior of common tools.
279 CLICOLOR_FORCE= GREP_OPTIONS=
280 unset CLICOLOR_FORCE GREP_OPTIONS
281
282 ## --------------------- ##
283 ## M4sh Shell Functions. ##
284 ## --------------------- ##
285 # as_fn_unset VAR
286 # ---------------
287 # Portably unset VAR.
288 as_fn_unset ()
289 {
290 { eval $1=; unset $1;}
291 }
292 as_unset=as_fn_unset
293
294 # as_fn_set_status STATUS
295 # -----------------------
296 # Set $? to STATUS, without forking.
297 as_fn_set_status ()
298 {
299 return $1
300 } # as_fn_set_status
301
302 # as_fn_exit STATUS
303 # -----------------
304 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
305 as_fn_exit ()
306 {
307 set +e
308 as_fn_set_status $1
309 exit $1
310 } # as_fn_exit
311
312 # as_fn_mkdir_p
313 # -------------
314 # Create "$as_dir" as a directory, including parents if necessary.
315 as_fn_mkdir_p ()
316 {
317
318 case $as_dir in #(
319 -*) as_dir=./$as_dir;;
320 esac
321 test -d "$as_dir" || eval $as_mkdir_p || {
322 as_dirs=
323 while :; do
324 case $as_dir in #(
325 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
326 *) as_qdir=$as_dir;;
327 esac
328 as_dirs="'$as_qdir' $as_dirs"
329 as_dir=`$as_dirname -- "$as_dir" ||
330 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
331 X"$as_dir" : 'X\(//\)[^/]' \| \
332 X"$as_dir" : 'X\(//\)$' \| \
333 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
334 $as_echo X"$as_dir" |
335 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
336 s//\1/
337 q
338 }
339 /^X\(\/\/\)[^/].*/{
340 s//\1/
341 q
342 }
343 /^X\(\/\/\)$/{
344 s//\1/
345 q
346 }
347 /^X\(\/\).*/{
348 s//\1/
349 q
350 }
351 s/.*/./; q'`
352 test -d "$as_dir" && break
353 done
354 test -z "$as_dirs" || eval "mkdir $as_dirs"
355 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
356
357
358 } # as_fn_mkdir_p
359
360 # as_fn_executable_p FILE
361 # -----------------------
362 # Test if FILE is an executable regular file.
363 as_fn_executable_p ()
364 {
365 test -f "$1" && test -x "$1"
366 } # as_fn_executable_p
367 # as_fn_append VAR VALUE
368 # ----------------------
369 # Append the text in VALUE to the end of the definition contained in VAR. Take
370 # advantage of any shell optimizations that allow amortized linear growth over
371 # repeated appends, instead of the typical quadratic growth present in naive
372 # implementations.
373 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
374 eval 'as_fn_append ()
375 {
376 eval $1+=\$2
377 }'
378 else
379 as_fn_append ()
380 {
381 eval $1=\$$1\$2
382 }
383 fi # as_fn_append
384
385 # as_fn_arith ARG...
386 # ------------------
387 # Perform arithmetic evaluation on the ARGs, and store the result in the
388 # global $as_val. Take advantage of shells that can avoid forks. The arguments
389 # must be portable across $(()) and expr.
390 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
391 eval 'as_fn_arith ()
392 {
393 as_val=$(( $* ))
394 }'
395 else
396 as_fn_arith ()
397 {
398 as_val=`expr "$@" || test $? -eq 1`
399 }
400 fi # as_fn_arith
401
402
403 # as_fn_error STATUS ERROR [LINENO LOG_FD]
404 # ----------------------------------------
405 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
406 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
407 # script with STATUS, using 1 if that was 0.
408 as_fn_error ()
409 {
410 as_status=$1; test $as_status -eq 0 && as_status=1
411 if test "$4"; then
412 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
413 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
414 fi
415 $as_echo "$as_me: error: $2" >&2
416 as_fn_exit $as_status
417 } # as_fn_error
418
419 if expr a : '\(a\)' >/dev/null 2>&1 &&
420 test "X`expr 00001 : '.*\(...\)'`" = X001; then
421 as_expr=expr
422 else
423 as_expr=false
424 fi
425
426 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
427 as_basename=basename
428 else
429 as_basename=false
430 fi
431
432 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
433 as_dirname=dirname
434 else
435 as_dirname=false
436 fi
437
438 as_me=`$as_basename -- "$0" ||
439 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
440 X"$0" : 'X\(//\)$' \| \
441 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
442 $as_echo X/"$0" |
443 sed '/^.*\/\([^/][^/]*\)\/*$/{
444 s//\1/
445 q
446 }
447 /^X\/\(\/\/\)$/{
448 s//\1/
449 q
450 }
451 /^X\/\(\/\).*/{
452 s//\1/
453 q
454 }
455 s/.*/./; q'`
456
457 # Avoid depending upon Character Ranges.
458 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
459 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
460 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
461 as_cr_digits='0123456789'
462 as_cr_alnum=$as_cr_Letters$as_cr_digits
463
464
465 as_lineno_1=$LINENO as_lineno_1a=$LINENO
466 as_lineno_2=$LINENO as_lineno_2a=$LINENO
467 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
468 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
469 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
470 sed -n '
471 p
472 /[$]LINENO/=
473 ' <$as_myself |
474 sed '
475 s/[$]LINENO.*/&-/
476 t lineno
477 b
478 :lineno
479 N
480 :loop
481 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
482 t loop
483 s/-\n.*//
484 ' >$as_me.lineno &&
485 chmod +x "$as_me.lineno" ||
486 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
487
488 # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
489 # already done that, so ensure we don't try to do so again and fall
490 # in an infinite loop. This has already happened in practice.
491 _as_can_reexec=no; export _as_can_reexec
492 # Don't try to exec as it changes $[0], causing all sort of problems
493 # (the dirname of $[0] is not the place where we might find the
494 # original and so on. Autoconf is especially sensitive to this).
495 . "./$as_me.lineno"
496 # Exit status is that of the last command.
497 exit
498 }
499
500 ECHO_C= ECHO_N= ECHO_T=
501 case `echo -n x` in #(((((
502 -n*)
503 case `echo 'xy\c'` in
504 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
505 xy) ECHO_C='\c';;
506 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
507 ECHO_T=' ';;
508 esac;;
509 *)
510 ECHO_N='-n';;
511 esac
512
513 rm -f conf$$ conf$$.exe conf$$.file
514 if test -d conf$$.dir; then
515 rm -f conf$$.dir/conf$$.file
516 else
517 rm -f conf$$.dir
518 mkdir conf$$.dir 2>/dev/null
519 fi
520 if (echo >conf$$.file) 2>/dev/null; then
521 if ln -s conf$$.file conf$$ 2>/dev/null; then
522 as_ln_s='ln -s'
523 # ... but there are two gotchas:
524 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
525 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
526 # In both cases, we have to default to `cp -pR'.
527 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
528 as_ln_s='cp -pR'
529 elif ln conf$$.file conf$$ 2>/dev/null; then
530 as_ln_s=ln
531 else
532 as_ln_s='cp -pR'
533 fi
534 else
535 as_ln_s='cp -pR'
536 fi
537 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
538 rmdir conf$$.dir 2>/dev/null
539
540 if mkdir -p . 2>/dev/null; then
541 as_mkdir_p='mkdir -p "$as_dir"'
542 else
543 test -d ./-p && rmdir ./-p
544 as_mkdir_p=false
545 fi
546
547 as_test_x='test -x'
548 as_executable_p=as_fn_executable_p
549
550 # Sed expression to map a string onto a valid CPP name.
551 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
552
553 # Sed expression to map a string onto a valid variable name.
554 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
555
556
557 test -n "$DJDIR" || exec 7<&0 </dev/null
558 exec 6>&1
559
560 # Name of the host.
561 # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
562 # so uname gets run too.
563 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
564
565 #
566 # Initializations.
567 #
568 ac_default_prefix=/usr/local
569 ac_clean_files=
570 ac_config_libobj_dir=.
571 LIBOBJS=
572 cross_compiling=no
573 subdirs=
574 MFLAGS=
575 MAKEFLAGS=
576
577 # Identity of this package.
578 PACKAGE_NAME=
579 PACKAGE_TARNAME=
580 PACKAGE_VERSION=
581 PACKAGE_STRING=
582 PACKAGE_BUGREPORT=
583 PACKAGE_URL=
584
585 ac_unique_file="pcap.c"
586 # Factoring default headers for most tests.
587 ac_includes_default="\
588 #include <stdio.h>
589 #ifdef HAVE_SYS_TYPES_H
590 # include <sys/types.h>
591 #endif
592 #ifdef HAVE_SYS_STAT_H
593 # include <sys/stat.h>
594 #endif
595 #ifdef STDC_HEADERS
596 # include <stdlib.h>
597 # include <stddef.h>
598 #else
599 # ifdef HAVE_STDLIB_H
600 # include <stdlib.h>
601 # endif
602 #endif
603 #ifdef HAVE_STRING_H
604 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
605 # include <memory.h>
606 # endif
607 # include <string.h>
608 #endif
609 #ifdef HAVE_STRINGS_H
610 # include <strings.h>
611 #endif
612 #ifdef HAVE_INTTYPES_H
613 # include <inttypes.h>
614 #endif
615 #ifdef HAVE_STDINT_H
616 # include <stdint.h>
617 #endif
618 #ifdef HAVE_UNISTD_H
619 # include <unistd.h>
620 #endif"
621
622 ac_subst_vars='LTLIBOBJS
623 INSTALL_DATA
624 INSTALL_SCRIPT
625 INSTALL_PROGRAM
626 PCAP_SUPPORT_PACKET_RING
627 DBUS_SRC
628 PCAP_SUPPORT_DBUS
629 PKGCONFIG
630 CAN_SRC
631 PCAP_SUPPORT_CAN
632 CANUSB_SRC
633 PCAP_SUPPORT_CANUSB
634 BT_MONITOR_SRC
635 BT_SRC
636 PCAP_SUPPORT_BT
637 NETFILTER_SRC
638 PCAP_SUPPORT_NETFILTER
639 USB_SRC
640 PCAP_SUPPORT_USB
641 MAN_MISC_INFO
642 MAN_FILE_FORMATS
643 DYEXT
644 SSRC
645 ADDLARCHIVEOBJS
646 ADDLOBJS
647 V_RPATH_OPT
648 V_SONAME_OPT
649 V_SHLIB_OPT
650 V_SHLIB_CMD
651 V_PCAP
652 V_INCLS
653 V_FINDALLDEVS
654 V_DEFS
655 V_CCOPT
656 MKDEP
657 DEPENDENCY_CFLAG
658 LN_S
659 AR
660 RANLIB
661 V_YACC
662 V_LEX
663 HAVE_LINUX_TPACKET_AUXDATA
664 LIBOBJS
665 EGREP
666 GREP
667 CPP
668 OBJEXT
669 EXEEXT
670 ac_ct_CC
671 CPPFLAGS
672 LDFLAGS
673 CFLAGS
674 CC
675 SHLICC2
676 target_os
677 target_vendor
678 target_cpu
679 target
680 host_os
681 host_vendor
682 host_cpu
683 host
684 build_os
685 build_vendor
686 build_cpu
687 build
688 target_alias
689 host_alias
690 build_alias
691 LIBS
692 ECHO_T
693 ECHO_N
694 ECHO_C
695 DEFS
696 mandir
697 localedir
698 libdir
699 psdir
700 pdfdir
701 dvidir
702 htmldir
703 infodir
704 docdir
705 oldincludedir
706 includedir
707 localstatedir
708 sharedstatedir
709 sysconfdir
710 datadir
711 datarootdir
712 libexecdir
713 sbindir
714 bindir
715 program_transform_name
716 prefix
717 exec_prefix
718 PACKAGE_URL
719 PACKAGE_BUGREPORT
720 PACKAGE_STRING
721 PACKAGE_VERSION
722 PACKAGE_TARNAME
723 PACKAGE_NAME
724 PATH_SEPARATOR
725 SHELL'
726 ac_subst_files=''
727 ac_user_opts='
728 enable_option_checking
729 with_gcc
730 enable_largefile
731 enable_protochain
732 with_sita
733 with_pcap
734 with_libnl
735 enable_ipv6
736 enable_optimizer_dbg
737 enable_yydebug
738 with_dag
739 with_dag_includes
740 with_dag_libraries
741 with_septel
742 with_snf
743 with_snf_includes
744 with_snf_libraries
745 with_turbocap
746 with_flex
747 with_bison
748 enable_universal
749 enable_shared
750 enable_usb
751 enable_bluetooth
752 enable_canusb
753 enable_can
754 enable_dbus
755 enable_packet_ring
756 '
757 ac_precious_vars='build_alias
758 host_alias
759 target_alias
760 CC
761 CFLAGS
762 LDFLAGS
763 LIBS
764 CPPFLAGS
765 CPP'
766
767
768 # Initialize some variables set by options.
769 ac_init_help=
770 ac_init_version=false
771 ac_unrecognized_opts=
772 ac_unrecognized_sep=
773 # The variables have the same names as the options, with
774 # dashes changed to underlines.
775 cache_file=/dev/null
776 exec_prefix=NONE
777 no_create=
778 no_recursion=
779 prefix=NONE
780 program_prefix=NONE
781 program_suffix=NONE
782 program_transform_name=s,x,x,
783 silent=
784 site=
785 srcdir=
786 verbose=
787 x_includes=NONE
788 x_libraries=NONE
789
790 # Installation directory options.
791 # These are left unexpanded so users can "make install exec_prefix=/foo"
792 # and all the variables that are supposed to be based on exec_prefix
793 # by default will actually change.
794 # Use braces instead of parens because sh, perl, etc. also accept them.
795 # (The list follows the same order as the GNU Coding Standards.)
796 bindir='${exec_prefix}/bin'
797 sbindir='${exec_prefix}/sbin'
798 libexecdir='${exec_prefix}/libexec'
799 datarootdir='${prefix}/share'
800 datadir='${datarootdir}'
801 sysconfdir='${prefix}/etc'
802 sharedstatedir='${prefix}/com'
803 localstatedir='${prefix}/var'
804 includedir='${prefix}/include'
805 oldincludedir='/usr/include'
806 docdir='${datarootdir}/doc/${PACKAGE}'
807 infodir='${datarootdir}/info'
808 htmldir='${docdir}'
809 dvidir='${docdir}'
810 pdfdir='${docdir}'
811 psdir='${docdir}'
812 libdir='${exec_prefix}/lib'
813 localedir='${datarootdir}/locale'
814 mandir='${datarootdir}/man'
815
816 ac_prev=
817 ac_dashdash=
818 for ac_option
819 do
820 # If the previous option needs an argument, assign it.
821 if test -n "$ac_prev"; then
822 eval $ac_prev=\$ac_option
823 ac_prev=
824 continue
825 fi
826
827 case $ac_option in
828 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
829 *=) ac_optarg= ;;
830 *) ac_optarg=yes ;;
831 esac
832
833 # Accept the important Cygnus configure options, so we can diagnose typos.
834
835 case $ac_dashdash$ac_option in
836 --)
837 ac_dashdash=yes ;;
838
839 -bindir | --bindir | --bindi | --bind | --bin | --bi)
840 ac_prev=bindir ;;
841 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
842 bindir=$ac_optarg ;;
843
844 -build | --build | --buil | --bui | --bu)
845 ac_prev=build_alias ;;
846 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
847 build_alias=$ac_optarg ;;
848
849 -cache-file | --cache-file | --cache-fil | --cache-fi \
850 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
851 ac_prev=cache_file ;;
852 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
853 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
854 cache_file=$ac_optarg ;;
855
856 --config-cache | -C)
857 cache_file=config.cache ;;
858
859 -datadir | --datadir | --datadi | --datad)
860 ac_prev=datadir ;;
861 -datadir=* | --datadir=* | --datadi=* | --datad=*)
862 datadir=$ac_optarg ;;
863
864 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
865 | --dataroo | --dataro | --datar)
866 ac_prev=datarootdir ;;
867 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
868 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
869 datarootdir=$ac_optarg ;;
870
871 -disable-* | --disable-*)
872 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
873 # Reject names that are not valid shell variable names.
874 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
875 as_fn_error $? "invalid feature name: $ac_useropt"
876 ac_useropt_orig=$ac_useropt
877 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
878 case $ac_user_opts in
879 *"
880 "enable_$ac_useropt"
881 "*) ;;
882 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
883 ac_unrecognized_sep=', ';;
884 esac
885 eval enable_$ac_useropt=no ;;
886
887 -docdir | --docdir | --docdi | --doc | --do)
888 ac_prev=docdir ;;
889 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
890 docdir=$ac_optarg ;;
891
892 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
893 ac_prev=dvidir ;;
894 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
895 dvidir=$ac_optarg ;;
896
897 -enable-* | --enable-*)
898 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
899 # Reject names that are not valid shell variable names.
900 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
901 as_fn_error $? "invalid feature name: $ac_useropt"
902 ac_useropt_orig=$ac_useropt
903 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
904 case $ac_user_opts in
905 *"
906 "enable_$ac_useropt"
907 "*) ;;
908 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
909 ac_unrecognized_sep=', ';;
910 esac
911 eval enable_$ac_useropt=\$ac_optarg ;;
912
913 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
914 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
915 | --exec | --exe | --ex)
916 ac_prev=exec_prefix ;;
917 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
918 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
919 | --exec=* | --exe=* | --ex=*)
920 exec_prefix=$ac_optarg ;;
921
922 -gas | --gas | --ga | --g)
923 # Obsolete; use --with-gas.
924 with_gas=yes ;;
925
926 -help | --help | --hel | --he | -h)
927 ac_init_help=long ;;
928 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
929 ac_init_help=recursive ;;
930 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
931 ac_init_help=short ;;
932
933 -host | --host | --hos | --ho)
934 ac_prev=host_alias ;;
935 -host=* | --host=* | --hos=* | --ho=*)
936 host_alias=$ac_optarg ;;
937
938 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
939 ac_prev=htmldir ;;
940 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
941 | --ht=*)
942 htmldir=$ac_optarg ;;
943
944 -includedir | --includedir | --includedi | --included | --include \
945 | --includ | --inclu | --incl | --inc)
946 ac_prev=includedir ;;
947 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
948 | --includ=* | --inclu=* | --incl=* | --inc=*)
949 includedir=$ac_optarg ;;
950
951 -infodir | --infodir | --infodi | --infod | --info | --inf)
952 ac_prev=infodir ;;
953 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
954 infodir=$ac_optarg ;;
955
956 -libdir | --libdir | --libdi | --libd)
957 ac_prev=libdir ;;
958 -libdir=* | --libdir=* | --libdi=* | --libd=*)
959 libdir=$ac_optarg ;;
960
961 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
962 | --libexe | --libex | --libe)
963 ac_prev=libexecdir ;;
964 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
965 | --libexe=* | --libex=* | --libe=*)
966 libexecdir=$ac_optarg ;;
967
968 -localedir | --localedir | --localedi | --localed | --locale)
969 ac_prev=localedir ;;
970 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
971 localedir=$ac_optarg ;;
972
973 -localstatedir | --localstatedir | --localstatedi | --localstated \
974 | --localstate | --localstat | --localsta | --localst | --locals)
975 ac_prev=localstatedir ;;
976 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
977 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
978 localstatedir=$ac_optarg ;;
979
980 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
981 ac_prev=mandir ;;
982 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
983 mandir=$ac_optarg ;;
984
985 -nfp | --nfp | --nf)
986 # Obsolete; use --without-fp.
987 with_fp=no ;;
988
989 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
990 | --no-cr | --no-c | -n)
991 no_create=yes ;;
992
993 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
994 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
995 no_recursion=yes ;;
996
997 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
998 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
999 | --oldin | --oldi | --old | --ol | --o)
1000 ac_prev=oldincludedir ;;
1001 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1002 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1003 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1004 oldincludedir=$ac_optarg ;;
1005
1006 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1007 ac_prev=prefix ;;
1008 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1009 prefix=$ac_optarg ;;
1010
1011 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1012 | --program-pre | --program-pr | --program-p)
1013 ac_prev=program_prefix ;;
1014 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1015 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1016 program_prefix=$ac_optarg ;;
1017
1018 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1019 | --program-suf | --program-su | --program-s)
1020 ac_prev=program_suffix ;;
1021 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1022 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1023 program_suffix=$ac_optarg ;;
1024
1025 -program-transform-name | --program-transform-name \
1026 | --program-transform-nam | --program-transform-na \
1027 | --program-transform-n | --program-transform- \
1028 | --program-transform | --program-transfor \
1029 | --program-transfo | --program-transf \
1030 | --program-trans | --program-tran \
1031 | --progr-tra | --program-tr | --program-t)
1032 ac_prev=program_transform_name ;;
1033 -program-transform-name=* | --program-transform-name=* \
1034 | --program-transform-nam=* | --program-transform-na=* \
1035 | --program-transform-n=* | --program-transform-=* \
1036 | --program-transform=* | --program-transfor=* \
1037 | --program-transfo=* | --program-transf=* \
1038 | --program-trans=* | --program-tran=* \
1039 | --progr-tra=* | --program-tr=* | --program-t=*)
1040 program_transform_name=$ac_optarg ;;
1041
1042 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1043 ac_prev=pdfdir ;;
1044 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1045 pdfdir=$ac_optarg ;;
1046
1047 -psdir | --psdir | --psdi | --psd | --ps)
1048 ac_prev=psdir ;;
1049 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1050 psdir=$ac_optarg ;;
1051
1052 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1053 | -silent | --silent | --silen | --sile | --sil)
1054 silent=yes ;;
1055
1056 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1057 ac_prev=sbindir ;;
1058 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1059 | --sbi=* | --sb=*)
1060 sbindir=$ac_optarg ;;
1061
1062 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1063 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1064 | --sharedst | --shareds | --shared | --share | --shar \
1065 | --sha | --sh)
1066 ac_prev=sharedstatedir ;;
1067 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1068 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1069 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1070 | --sha=* | --sh=*)
1071 sharedstatedir=$ac_optarg ;;
1072
1073 -site | --site | --sit)
1074 ac_prev=site ;;
1075 -site=* | --site=* | --sit=*)
1076 site=$ac_optarg ;;
1077
1078 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1079 ac_prev=srcdir ;;
1080 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1081 srcdir=$ac_optarg ;;
1082
1083 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1084 | --syscon | --sysco | --sysc | --sys | --sy)
1085 ac_prev=sysconfdir ;;
1086 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1087 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1088 sysconfdir=$ac_optarg ;;
1089
1090 -target | --target | --targe | --targ | --tar | --ta | --t)
1091 ac_prev=target_alias ;;
1092 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1093 target_alias=$ac_optarg ;;
1094
1095 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1096 verbose=yes ;;
1097
1098 -version | --version | --versio | --versi | --vers | -V)
1099 ac_init_version=: ;;
1100
1101 -with-* | --with-*)
1102 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1103 # Reject names that are not valid shell variable names.
1104 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1105 as_fn_error $? "invalid package name: $ac_useropt"
1106 ac_useropt_orig=$ac_useropt
1107 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1108 case $ac_user_opts in
1109 *"
1110 "with_$ac_useropt"
1111 "*) ;;
1112 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1113 ac_unrecognized_sep=', ';;
1114 esac
1115 eval with_$ac_useropt=\$ac_optarg ;;
1116
1117 -without-* | --without-*)
1118 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1119 # Reject names that are not valid shell variable names.
1120 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1121 as_fn_error $? "invalid package name: $ac_useropt"
1122 ac_useropt_orig=$ac_useropt
1123 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1124 case $ac_user_opts in
1125 *"
1126 "with_$ac_useropt"
1127 "*) ;;
1128 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1129 ac_unrecognized_sep=', ';;
1130 esac
1131 eval with_$ac_useropt=no ;;
1132
1133 --x)
1134 # Obsolete; use --with-x.
1135 with_x=yes ;;
1136
1137 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1138 | --x-incl | --x-inc | --x-in | --x-i)
1139 ac_prev=x_includes ;;
1140 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1141 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1142 x_includes=$ac_optarg ;;
1143
1144 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1145 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1146 ac_prev=x_libraries ;;
1147 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1148 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1149 x_libraries=$ac_optarg ;;
1150
1151 -*) as_fn_error $? "unrecognized option: \`$ac_option'
1152 Try \`$0 --help' for more information"
1153 ;;
1154
1155 *=*)
1156 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1157 # Reject names that are not valid shell variable names.
1158 case $ac_envvar in #(
1159 '' | [0-9]* | *[!_$as_cr_alnum]* )
1160 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1161 esac
1162 eval $ac_envvar=\$ac_optarg
1163 export $ac_envvar ;;
1164
1165 *)
1166 # FIXME: should be removed in autoconf 3.0.
1167 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1168 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1169 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1170 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1171 ;;
1172
1173 esac
1174 done
1175
1176 if test -n "$ac_prev"; then
1177 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1178 as_fn_error $? "missing argument to $ac_option"
1179 fi
1180
1181 if test -n "$ac_unrecognized_opts"; then
1182 case $enable_option_checking in
1183 no) ;;
1184 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1185 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1186 esac
1187 fi
1188
1189 # Check all directory arguments for consistency.
1190 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1191 datadir sysconfdir sharedstatedir localstatedir includedir \
1192 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1193 libdir localedir mandir
1194 do
1195 eval ac_val=\$$ac_var
1196 # Remove trailing slashes.
1197 case $ac_val in
1198 */ )
1199 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1200 eval $ac_var=\$ac_val;;
1201 esac
1202 # Be sure to have absolute directory names.
1203 case $ac_val in
1204 [\\/$]* | ?:[\\/]* ) continue;;
1205 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1206 esac
1207 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1208 done
1209
1210 # There might be people who depend on the old broken behavior: `$host'
1211 # used to hold the argument of --host etc.
1212 # FIXME: To remove some day.
1213 build=$build_alias
1214 host=$host_alias
1215 target=$target_alias
1216
1217 # FIXME: To remove some day.
1218 if test "x$host_alias" != x; then
1219 if test "x$build_alias" = x; then
1220 cross_compiling=maybe
1221 elif test "x$build_alias" != "x$host_alias"; then
1222 cross_compiling=yes
1223 fi
1224 fi
1225
1226 ac_tool_prefix=
1227 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1228
1229 test "$silent" = yes && exec 6>/dev/null
1230
1231
1232 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1233 ac_ls_di=`ls -di .` &&
1234 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1235 as_fn_error $? "working directory cannot be determined"
1236 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1237 as_fn_error $? "pwd does not report name of working directory"
1238
1239
1240 # Find the source files, if location was not specified.
1241 if test -z "$srcdir"; then
1242 ac_srcdir_defaulted=yes
1243 # Try the directory containing this script, then the parent directory.
1244 ac_confdir=`$as_dirname -- "$as_myself" ||
1245 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1246 X"$as_myself" : 'X\(//\)[^/]' \| \
1247 X"$as_myself" : 'X\(//\)$' \| \
1248 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1249 $as_echo X"$as_myself" |
1250 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1251 s//\1/
1252 q
1253 }
1254 /^X\(\/\/\)[^/].*/{
1255 s//\1/
1256 q
1257 }
1258 /^X\(\/\/\)$/{
1259 s//\1/
1260 q
1261 }
1262 /^X\(\/\).*/{
1263 s//\1/
1264 q
1265 }
1266 s/.*/./; q'`
1267 srcdir=$ac_confdir
1268 if test ! -r "$srcdir/$ac_unique_file"; then
1269 srcdir=..
1270 fi
1271 else
1272 ac_srcdir_defaulted=no
1273 fi
1274 if test ! -r "$srcdir/$ac_unique_file"; then
1275 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1276 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1277 fi
1278 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1279 ac_abs_confdir=`(
1280 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1281 pwd)`
1282 # When building in place, set srcdir=.
1283 if test "$ac_abs_confdir" = "$ac_pwd"; then
1284 srcdir=.
1285 fi
1286 # Remove unnecessary trailing slashes from srcdir.
1287 # Double slashes in file names in object file debugging info
1288 # mess up M-x gdb in Emacs.
1289 case $srcdir in
1290 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1291 esac
1292 for ac_var in $ac_precious_vars; do
1293 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1294 eval ac_env_${ac_var}_value=\$${ac_var}
1295 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1296 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1297 done
1298
1299 #
1300 # Report the --help message.
1301 #
1302 if test "$ac_init_help" = "long"; then
1303 # Omit some internal or obsolete options to make the list less imposing.
1304 # This message is too long to be a string in the A/UX 3.1 sh.
1305 cat <<_ACEOF
1306 \`configure' configures this package to adapt to many kinds of systems.
1307
1308 Usage: $0 [OPTION]... [VAR=VALUE]...
1309
1310 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1311 VAR=VALUE. See below for descriptions of some of the useful variables.
1312
1313 Defaults for the options are specified in brackets.
1314
1315 Configuration:
1316 -h, --help display this help and exit
1317 --help=short display options specific to this package
1318 --help=recursive display the short help of all the included packages
1319 -V, --version display version information and exit
1320 -q, --quiet, --silent do not print \`checking ...' messages
1321 --cache-file=FILE cache test results in FILE [disabled]
1322 -C, --config-cache alias for \`--cache-file=config.cache'
1323 -n, --no-create do not create output files
1324 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1325
1326 Installation directories:
1327 --prefix=PREFIX install architecture-independent files in PREFIX
1328 [$ac_default_prefix]
1329 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
1330 [PREFIX]
1331
1332 By default, \`make install' will install all the files in
1333 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1334 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1335 for instance \`--prefix=\$HOME'.
1336
1337 For better control, use the options below.
1338
1339 Fine tuning of the installation directories:
1340 --bindir=DIR user executables [EPREFIX/bin]
1341 --sbindir=DIR system admin executables [EPREFIX/sbin]
1342 --libexecdir=DIR program executables [EPREFIX/libexec]
1343 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1344 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1345 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1346 --libdir=DIR object code libraries [EPREFIX/lib]
1347 --includedir=DIR C header files [PREFIX/include]
1348 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1349 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1350 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1351 --infodir=DIR info documentation [DATAROOTDIR/info]
1352 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1353 --mandir=DIR man documentation [DATAROOTDIR/man]
1354 --docdir=DIR documentation root [DATAROOTDIR/doc/PACKAGE]
1355 --htmldir=DIR html documentation [DOCDIR]
1356 --dvidir=DIR dvi documentation [DOCDIR]
1357 --pdfdir=DIR pdf documentation [DOCDIR]
1358 --psdir=DIR ps documentation [DOCDIR]
1359 _ACEOF
1360
1361 cat <<\_ACEOF
1362
1363 System types:
1364 --build=BUILD configure for building on BUILD [guessed]
1365 --host=HOST cross-compile to build programs to run on HOST [BUILD]
1366 --target=TARGET configure for building compilers for TARGET [HOST]
1367 _ACEOF
1368 fi
1369
1370 if test -n "$ac_init_help"; then
1371
1372 cat <<\_ACEOF
1373
1374 Optional Features:
1375 --disable-option-checking ignore unrecognized --enable/--with options
1376 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1377 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
1378 --disable-largefile omit support for large files
1379 --disable-protochain disable \"protochain\" insn
1380 --enable-ipv6 build IPv6-capable version [default=yes, if
1381 getaddrinfo available]
1382 --enable-optimizer-dbg build optimizer debugging code
1383 --enable-yydebug build parser debugging code
1384 --disable-universal don't build universal on OS X
1385 --enable-shared build shared libraries [default=yes, if support
1386 available]
1387 --enable-usb enable nusb support [default=yes, if support
1388 available]
1389 --enable-bluetooth enable Bluetooth support [default=yes, if support
1390 available]
1391 --enable-canusb enable canusb support [default=yes, if support
1392 available]
1393 --enable-can enable CAN support [default=yes, if support
1394 available]
1395 --enable-dbus enable D-Bus capture support [default=yes, if
1396 support available]
1397 --enable-packet-ring enable Linux packet ring support [default=yes]
1398
1399 Optional Packages:
1400 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
1401 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
1402 --without-gcc don't use gcc
1403 --with-sita include SITA support
1404 --with-pcap=TYPE use packet capture TYPE
1405 --without-libnl disable libnl support [default=yes, on Linux, if
1406 present]
1407 --with-dag[=DIR] include Endace DAG support (located in directory
1408 DIR, if supplied). [default=yes, if present]
1409 --with-dag-includes=IDIR
1410 Endace DAG include directory, if not DIR/include
1411 --with-dag-libraries=LDIR
1412 Endace DAG library directory, if not DIR/lib
1413 --with-septel[=DIR] include Septel support (located in directory DIR, if
1414 supplied). [default=yes, if present]
1415 --with-snf[=DIR] include Myricom SNF support (located in directory
1416 DIR, if supplied). [default=yes, if present]
1417 --with-snf-includes=IDIR
1418 Myricom SNF include directory, if not DIR/include
1419 --with-snf-libraries=LDIR
1420 Myricom SNF library directory, if not DIR/lib
1421 --with-turbocap[=DIR] include Riverbed TurboCap support (located in
1422 directory DIR, if supplied). [default=yes, if
1423 present]
1424 --without-flex don't use flex
1425 --without-bison don't use bison
1426
1427 Some influential environment variables:
1428 CC C compiler command
1429 CFLAGS C compiler flags
1430 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
1431 nonstandard directory <lib dir>
1432 LIBS libraries to pass to the linker, e.g. -l<library>
1433 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
1434 you have headers in a nonstandard directory <include dir>
1435 CPP C preprocessor
1436
1437 Use these variables to override the choices made by `configure' or to help
1438 it to find libraries and programs with nonstandard names/locations.
1439
1440 Report bugs to the package provider.
1441 _ACEOF
1442 ac_status=$?
1443 fi
1444
1445 if test "$ac_init_help" = "recursive"; then
1446 # If there are subdirs, report their specific --help.
1447 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1448 test -d "$ac_dir" ||
1449 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1450 continue
1451 ac_builddir=.
1452
1453 case "$ac_dir" in
1454 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1455 *)
1456 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1457 # A ".." for each directory in $ac_dir_suffix.
1458 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1459 case $ac_top_builddir_sub in
1460 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1461 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1462 esac ;;
1463 esac
1464 ac_abs_top_builddir=$ac_pwd
1465 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1466 # for backward compatibility:
1467 ac_top_builddir=$ac_top_build_prefix
1468
1469 case $srcdir in
1470 .) # We are building in place.
1471 ac_srcdir=.
1472 ac_top_srcdir=$ac_top_builddir_sub
1473 ac_abs_top_srcdir=$ac_pwd ;;
1474 [\\/]* | ?:[\\/]* ) # Absolute name.
1475 ac_srcdir=$srcdir$ac_dir_suffix;
1476 ac_top_srcdir=$srcdir
1477 ac_abs_top_srcdir=$srcdir ;;
1478 *) # Relative name.
1479 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1480 ac_top_srcdir=$ac_top_build_prefix$srcdir
1481 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1482 esac
1483 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1484
1485 cd "$ac_dir" || { ac_status=$?; continue; }
1486 # Check for guested configure.
1487 if test -f "$ac_srcdir/configure.gnu"; then
1488 echo &&
1489 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1490 elif test -f "$ac_srcdir/configure"; then
1491 echo &&
1492 $SHELL "$ac_srcdir/configure" --help=recursive
1493 else
1494 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1495 fi || ac_status=$?
1496 cd "$ac_pwd" || { ac_status=$?; break; }
1497 done
1498 fi
1499
1500 test -n "$ac_init_help" && exit $ac_status
1501 if $ac_init_version; then
1502 cat <<\_ACEOF
1503 configure
1504 generated by GNU Autoconf 2.69
1505
1506 Copyright (C) 2012 Free Software Foundation, Inc.
1507 This configure script is free software; the Free Software Foundation
1508 gives unlimited permission to copy, distribute and modify it.
1509 _ACEOF
1510 exit
1511 fi
1512
1513 ## ------------------------ ##
1514 ## Autoconf initialization. ##
1515 ## ------------------------ ##
1516
1517 # ac_fn_c_try_compile LINENO
1518 # --------------------------
1519 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1520 ac_fn_c_try_compile ()
1521 {
1522 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1523 rm -f conftest.$ac_objext
1524 if { { ac_try="$ac_compile"
1525 case "(($ac_try" in
1526 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1527 *) ac_try_echo=$ac_try;;
1528 esac
1529 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1530 $as_echo "$ac_try_echo"; } >&5
1531 (eval "$ac_compile") 2>conftest.err
1532 ac_status=$?
1533 if test -s conftest.err; then
1534 grep -v '^ *+' conftest.err >conftest.er1
1535 cat conftest.er1 >&5
1536 mv -f conftest.er1 conftest.err
1537 fi
1538 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1539 test $ac_status = 0; } && {
1540 test -z "$ac_c_werror_flag" ||
1541 test ! -s conftest.err
1542 } && test -s conftest.$ac_objext; then :
1543 ac_retval=0
1544 else
1545 $as_echo "$as_me: failed program was:" >&5
1546 sed 's/^/| /' conftest.$ac_ext >&5
1547
1548 ac_retval=1
1549 fi
1550 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1551 as_fn_set_status $ac_retval
1552
1553 } # ac_fn_c_try_compile
1554
1555 # ac_fn_c_try_cpp LINENO
1556 # ----------------------
1557 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1558 ac_fn_c_try_cpp ()
1559 {
1560 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1561 if { { ac_try="$ac_cpp conftest.$ac_ext"
1562 case "(($ac_try" in
1563 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1564 *) ac_try_echo=$ac_try;;
1565 esac
1566 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1567 $as_echo "$ac_try_echo"; } >&5
1568 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1569 ac_status=$?
1570 if test -s conftest.err; then
1571 grep -v '^ *+' conftest.err >conftest.er1
1572 cat conftest.er1 >&5
1573 mv -f conftest.er1 conftest.err
1574 fi
1575 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1576 test $ac_status = 0; } > conftest.i && {
1577 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1578 test ! -s conftest.err
1579 }; then :
1580 ac_retval=0
1581 else
1582 $as_echo "$as_me: failed program was:" >&5
1583 sed 's/^/| /' conftest.$ac_ext >&5
1584
1585 ac_retval=1
1586 fi
1587 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1588 as_fn_set_status $ac_retval
1589
1590 } # ac_fn_c_try_cpp
1591
1592 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
1593 # -------------------------------------------------------
1594 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
1595 # the include files in INCLUDES and setting the cache variable VAR
1596 # accordingly.
1597 ac_fn_c_check_header_mongrel ()
1598 {
1599 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1600 if eval \${$3+:} false; then :
1601 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1602 $as_echo_n "checking for $2... " >&6; }
1603 if eval \${$3+:} false; then :
1604 $as_echo_n "(cached) " >&6
1605 fi
1606 eval ac_res=\$$3
1607 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1608 $as_echo "$ac_res" >&6; }
1609 else
1610 # Is the header compilable?
1611 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
1612 $as_echo_n "checking $2 usability... " >&6; }
1613 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1614 /* end confdefs.h. */
1615 $4
1616 #include <$2>
1617 _ACEOF
1618 if ac_fn_c_try_compile "$LINENO"; then :
1619 ac_header_compiler=yes
1620 else
1621 ac_header_compiler=no
1622 fi
1623 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
1625 $as_echo "$ac_header_compiler" >&6; }
1626
1627 # Is the header present?
1628 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
1629 $as_echo_n "checking $2 presence... " >&6; }
1630 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1631 /* end confdefs.h. */
1632 #include <$2>
1633 _ACEOF
1634 if ac_fn_c_try_cpp "$LINENO"; then :
1635 ac_header_preproc=yes
1636 else
1637 ac_header_preproc=no
1638 fi
1639 rm -f conftest.err conftest.i conftest.$ac_ext
1640 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
1641 $as_echo "$ac_header_preproc" >&6; }
1642
1643 # So? What about this header?
1644 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
1645 yes:no: )
1646 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
1647 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
1648 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1649 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1650 ;;
1651 no:yes:* )
1652 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
1653 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
1654 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
1655 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
1656 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
1657 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
1658 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
1659 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
1660 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1661 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1662 ;;
1663 esac
1664 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1665 $as_echo_n "checking for $2... " >&6; }
1666 if eval \${$3+:} false; then :
1667 $as_echo_n "(cached) " >&6
1668 else
1669 eval "$3=\$ac_header_compiler"
1670 fi
1671 eval ac_res=\$$3
1672 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1673 $as_echo "$ac_res" >&6; }
1674 fi
1675 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1676
1677 } # ac_fn_c_check_header_mongrel
1678
1679 # ac_fn_c_try_run LINENO
1680 # ----------------------
1681 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
1682 # that executables *can* be run.
1683 ac_fn_c_try_run ()
1684 {
1685 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1686 if { { ac_try="$ac_link"
1687 case "(($ac_try" in
1688 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1689 *) ac_try_echo=$ac_try;;
1690 esac
1691 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1692 $as_echo "$ac_try_echo"; } >&5
1693 (eval "$ac_link") 2>&5
1694 ac_status=$?
1695 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1696 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1697 { { case "(($ac_try" in
1698 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1699 *) ac_try_echo=$ac_try;;
1700 esac
1701 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1702 $as_echo "$ac_try_echo"; } >&5
1703 (eval "$ac_try") 2>&5
1704 ac_status=$?
1705 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1706 test $ac_status = 0; }; }; then :
1707 ac_retval=0
1708 else
1709 $as_echo "$as_me: program exited with status $ac_status" >&5
1710 $as_echo "$as_me: failed program was:" >&5
1711 sed 's/^/| /' conftest.$ac_ext >&5
1712
1713 ac_retval=$ac_status
1714 fi
1715 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1716 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1717 as_fn_set_status $ac_retval
1718
1719 } # ac_fn_c_try_run
1720
1721 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
1722 # -------------------------------------------------------
1723 # Tests whether HEADER exists and can be compiled using the include files in
1724 # INCLUDES, setting the cache variable VAR accordingly.
1725 ac_fn_c_check_header_compile ()
1726 {
1727 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1728 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1729 $as_echo_n "checking for $2... " >&6; }
1730 if eval \${$3+:} false; then :
1731 $as_echo_n "(cached) " >&6
1732 else
1733 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1734 /* end confdefs.h. */
1735 $4
1736 #include <$2>
1737 _ACEOF
1738 if ac_fn_c_try_compile "$LINENO"; then :
1739 eval "$3=yes"
1740 else
1741 eval "$3=no"
1742 fi
1743 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1744 fi
1745 eval ac_res=\$$3
1746 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1747 $as_echo "$ac_res" >&6; }
1748 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1749
1750 } # ac_fn_c_check_header_compile
1751
1752 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
1753 # -------------------------------------------
1754 # Tests whether TYPE exists after having included INCLUDES, setting cache
1755 # variable VAR accordingly.
1756 ac_fn_c_check_type ()
1757 {
1758 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1759 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1760 $as_echo_n "checking for $2... " >&6; }
1761 if eval \${$3+:} false; then :
1762 $as_echo_n "(cached) " >&6
1763 else
1764 eval "$3=no"
1765 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1766 /* end confdefs.h. */
1767 $4
1768 int
1769 main ()
1770 {
1771 if (sizeof ($2))
1772 return 0;
1773 ;
1774 return 0;
1775 }
1776 _ACEOF
1777 if ac_fn_c_try_compile "$LINENO"; then :
1778 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1779 /* end confdefs.h. */
1780 $4
1781 int
1782 main ()
1783 {
1784 if (sizeof (($2)))
1785 return 0;
1786 ;
1787 return 0;
1788 }
1789 _ACEOF
1790 if ac_fn_c_try_compile "$LINENO"; then :
1791
1792 else
1793 eval "$3=yes"
1794 fi
1795 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1796 fi
1797 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1798 fi
1799 eval ac_res=\$$3
1800 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1801 $as_echo "$ac_res" >&6; }
1802 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1803
1804 } # ac_fn_c_check_type
1805
1806 # ac_fn_c_try_link LINENO
1807 # -----------------------
1808 # Try to link conftest.$ac_ext, and return whether this succeeded.
1809 ac_fn_c_try_link ()
1810 {
1811 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1812 rm -f conftest.$ac_objext conftest$ac_exeext
1813 if { { ac_try="$ac_link"
1814 case "(($ac_try" in
1815 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1816 *) ac_try_echo=$ac_try;;
1817 esac
1818 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1819 $as_echo "$ac_try_echo"; } >&5
1820 (eval "$ac_link") 2>conftest.err
1821 ac_status=$?
1822 if test -s conftest.err; then
1823 grep -v '^ *+' conftest.err >conftest.er1
1824 cat conftest.er1 >&5
1825 mv -f conftest.er1 conftest.err
1826 fi
1827 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1828 test $ac_status = 0; } && {
1829 test -z "$ac_c_werror_flag" ||
1830 test ! -s conftest.err
1831 } && test -s conftest$ac_exeext && {
1832 test "$cross_compiling" = yes ||
1833 test -x conftest$ac_exeext
1834 }; then :
1835 ac_retval=0
1836 else
1837 $as_echo "$as_me: failed program was:" >&5
1838 sed 's/^/| /' conftest.$ac_ext >&5
1839
1840 ac_retval=1
1841 fi
1842 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
1843 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
1844 # interfere with the next link command; also delete a directory that is
1845 # left behind by Apple's compiler. We do this before executing the actions.
1846 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1847 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1848 as_fn_set_status $ac_retval
1849
1850 } # ac_fn_c_try_link
1851
1852 # ac_fn_c_check_func LINENO FUNC VAR
1853 # ----------------------------------
1854 # Tests whether FUNC exists, setting the cache variable VAR accordingly
1855 ac_fn_c_check_func ()
1856 {
1857 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1858 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1859 $as_echo_n "checking for $2... " >&6; }
1860 if eval \${$3+:} false; then :
1861 $as_echo_n "(cached) " >&6
1862 else
1863 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1864 /* end confdefs.h. */
1865 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
1866 For example, HP-UX 11i <limits.h> declares gettimeofday. */
1867 #define $2 innocuous_$2
1868
1869 /* System header to define __stub macros and hopefully few prototypes,
1870 which can conflict with char $2 (); below.
1871 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
1872 <limits.h> exists even on freestanding compilers. */
1873
1874 #ifdef __STDC__
1875 # include <limits.h>
1876 #else
1877 # include <assert.h>
1878 #endif
1879
1880 #undef $2
1881
1882 /* Override any GCC internal prototype to avoid an error.
1883 Use char because int might match the return type of a GCC
1884 builtin and then its argument prototype would still apply. */
1885 #ifdef __cplusplus
1886 extern "C"
1887 #endif
1888 char $2 ();
1889 /* The GNU C library defines this for functions which it implements
1890 to always fail with ENOSYS. Some functions are actually named
1891 something starting with __ and the normal name is an alias. */
1892 #if defined __stub_$2 || defined __stub___$2
1893 choke me
1894 #endif
1895
1896 int
1897 main ()
1898 {
1899 return $2 ();
1900 ;
1901 return 0;
1902 }
1903 _ACEOF
1904 if ac_fn_c_try_link "$LINENO"; then :
1905 eval "$3=yes"
1906 else
1907 eval "$3=no"
1908 fi
1909 rm -f core conftest.err conftest.$ac_objext \
1910 conftest$ac_exeext conftest.$ac_ext
1911 fi
1912 eval ac_res=\$$3
1913 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1914 $as_echo "$ac_res" >&6; }
1915 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1916
1917 } # ac_fn_c_check_func
1918
1919 # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
1920 # ---------------------------------------------
1921 # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
1922 # accordingly.
1923 ac_fn_c_check_decl ()
1924 {
1925 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1926 as_decl_name=`echo $2|sed 's/ *(.*//'`
1927 as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
1928 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
1929 $as_echo_n "checking whether $as_decl_name is declared... " >&6; }
1930 if eval \${$3+:} false; then :
1931 $as_echo_n "(cached) " >&6
1932 else
1933 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1934 /* end confdefs.h. */
1935 $4
1936 int
1937 main ()
1938 {
1939 #ifndef $as_decl_name
1940 #ifdef __cplusplus
1941 (void) $as_decl_use;
1942 #else
1943 (void) $as_decl_name;
1944 #endif
1945 #endif
1946
1947 ;
1948 return 0;
1949 }
1950 _ACEOF
1951 if ac_fn_c_try_compile "$LINENO"; then :
1952 eval "$3=yes"
1953 else
1954 eval "$3=no"
1955 fi
1956 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1957 fi
1958 eval ac_res=\$$3
1959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1960 $as_echo "$ac_res" >&6; }
1961 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1962
1963 } # ac_fn_c_check_decl
1964 cat >config.log <<_ACEOF
1965 This file contains any messages produced by compilers while
1966 running configure, to aid debugging if configure makes a mistake.
1967
1968 It was created by $as_me, which was
1969 generated by GNU Autoconf 2.69. Invocation command line was
1970
1971 $ $0 $@
1972
1973 _ACEOF
1974 exec 5>>config.log
1975 {
1976 cat <<_ASUNAME
1977 ## --------- ##
1978 ## Platform. ##
1979 ## --------- ##
1980
1981 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1982 uname -m = `(uname -m) 2>/dev/null || echo unknown`
1983 uname -r = `(uname -r) 2>/dev/null || echo unknown`
1984 uname -s = `(uname -s) 2>/dev/null || echo unknown`
1985 uname -v = `(uname -v) 2>/dev/null || echo unknown`
1986
1987 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1988 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
1989
1990 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
1991 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
1992 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1993 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
1994 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
1995 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
1996 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
1997
1998 _ASUNAME
1999
2000 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2001 for as_dir in $PATH
2002 do
2003 IFS=$as_save_IFS
2004 test -z "$as_dir" && as_dir=.
2005 $as_echo "PATH: $as_dir"
2006 done
2007 IFS=$as_save_IFS
2008
2009 } >&5
2010
2011 cat >&5 <<_ACEOF
2012
2013
2014 ## ----------- ##
2015 ## Core tests. ##
2016 ## ----------- ##
2017
2018 _ACEOF
2019
2020
2021 # Keep a trace of the command line.
2022 # Strip out --no-create and --no-recursion so they do not pile up.
2023 # Strip out --silent because we don't want to record it for future runs.
2024 # Also quote any args containing shell meta-characters.
2025 # Make two passes to allow for proper duplicate-argument suppression.
2026 ac_configure_args=
2027 ac_configure_args0=
2028 ac_configure_args1=
2029 ac_must_keep_next=false
2030 for ac_pass in 1 2
2031 do
2032 for ac_arg
2033 do
2034 case $ac_arg in
2035 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2036 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2037 | -silent | --silent | --silen | --sile | --sil)
2038 continue ;;
2039 *\'*)
2040 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2041 esac
2042 case $ac_pass in
2043 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2044 2)
2045 as_fn_append ac_configure_args1 " '$ac_arg'"
2046 if test $ac_must_keep_next = true; then
2047 ac_must_keep_next=false # Got value, back to normal.
2048 else
2049 case $ac_arg in
2050 *=* | --config-cache | -C | -disable-* | --disable-* \
2051 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2052 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2053 | -with-* | --with-* | -without-* | --without-* | --x)
2054 case "$ac_configure_args0 " in
2055 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2056 esac
2057 ;;
2058 -* ) ac_must_keep_next=true ;;
2059 esac
2060 fi
2061 as_fn_append ac_configure_args " '$ac_arg'"
2062 ;;
2063 esac
2064 done
2065 done
2066 { ac_configure_args0=; unset ac_configure_args0;}
2067 { ac_configure_args1=; unset ac_configure_args1;}
2068
2069 # When interrupted or exit'd, cleanup temporary files, and complete
2070 # config.log. We remove comments because anyway the quotes in there
2071 # would cause problems or look ugly.
2072 # WARNING: Use '\'' to represent an apostrophe within the trap.
2073 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2074 trap 'exit_status=$?
2075 # Save into config.log some information that might help in debugging.
2076 {
2077 echo
2078
2079 $as_echo "## ---------------- ##
2080 ## Cache variables. ##
2081 ## ---------------- ##"
2082 echo
2083 # The following way of writing the cache mishandles newlines in values,
2084 (
2085 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2086 eval ac_val=\$$ac_var
2087 case $ac_val in #(
2088 *${as_nl}*)
2089 case $ac_var in #(
2090 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2091 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2092 esac
2093 case $ac_var in #(
2094 _ | IFS | as_nl) ;; #(
2095 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2096 *) { eval $ac_var=; unset $ac_var;} ;;
2097 esac ;;
2098 esac
2099 done
2100 (set) 2>&1 |
2101 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2102 *${as_nl}ac_space=\ *)
2103 sed -n \
2104 "s/'\''/'\''\\\\'\'''\''/g;
2105 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2106 ;; #(
2107 *)
2108 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2109 ;;
2110 esac |
2111 sort
2112 )
2113 echo
2114
2115 $as_echo "## ----------------- ##
2116 ## Output variables. ##
2117 ## ----------------- ##"
2118 echo
2119 for ac_var in $ac_subst_vars
2120 do
2121 eval ac_val=\$$ac_var
2122 case $ac_val in
2123 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2124 esac
2125 $as_echo "$ac_var='\''$ac_val'\''"
2126 done | sort
2127 echo
2128
2129 if test -n "$ac_subst_files"; then
2130 $as_echo "## ------------------- ##
2131 ## File substitutions. ##
2132 ## ------------------- ##"
2133 echo
2134 for ac_var in $ac_subst_files
2135 do
2136 eval ac_val=\$$ac_var
2137 case $ac_val in
2138 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2139 esac
2140 $as_echo "$ac_var='\''$ac_val'\''"
2141 done | sort
2142 echo
2143 fi
2144
2145 if test -s confdefs.h; then
2146 $as_echo "## ----------- ##
2147 ## confdefs.h. ##
2148 ## ----------- ##"
2149 echo
2150 cat confdefs.h
2151 echo
2152 fi
2153 test "$ac_signal" != 0 &&
2154 $as_echo "$as_me: caught signal $ac_signal"
2155 $as_echo "$as_me: exit $exit_status"
2156 } >&5
2157 rm -f core *.core core.conftest.* &&
2158 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2159 exit $exit_status
2160 ' 0
2161 for ac_signal in 1 2 13 15; do
2162 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2163 done
2164 ac_signal=0
2165
2166 # confdefs.h avoids OS command line length limits that DEFS can exceed.
2167 rm -f -r conftest* confdefs.h
2168
2169 $as_echo "/* confdefs.h */" > confdefs.h
2170
2171 # Predefined preprocessor variables.
2172
2173 cat >>confdefs.h <<_ACEOF
2174 #define PACKAGE_NAME "$PACKAGE_NAME"
2175 _ACEOF
2176
2177 cat >>confdefs.h <<_ACEOF
2178 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2179 _ACEOF
2180
2181 cat >>confdefs.h <<_ACEOF
2182 #define PACKAGE_VERSION "$PACKAGE_VERSION"
2183 _ACEOF
2184
2185 cat >>confdefs.h <<_ACEOF
2186 #define PACKAGE_STRING "$PACKAGE_STRING"
2187 _ACEOF
2188
2189 cat >>confdefs.h <<_ACEOF
2190 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2191 _ACEOF
2192
2193 cat >>confdefs.h <<_ACEOF
2194 #define PACKAGE_URL "$PACKAGE_URL"
2195 _ACEOF
2196
2197
2198 # Let the site file select an alternate cache file if it wants to.
2199 # Prefer an explicitly selected file to automatically selected ones.
2200 ac_site_file1=NONE
2201 ac_site_file2=NONE
2202 if test -n "$CONFIG_SITE"; then
2203 # We do not want a PATH search for config.site.
2204 case $CONFIG_SITE in #((
2205 -*) ac_site_file1=./$CONFIG_SITE;;
2206 */*) ac_site_file1=$CONFIG_SITE;;
2207 *) ac_site_file1=./$CONFIG_SITE;;
2208 esac
2209 elif test "x$prefix" != xNONE; then
2210 ac_site_file1=$prefix/share/config.site
2211 ac_site_file2=$prefix/etc/config.site
2212 else
2213 ac_site_file1=$ac_default_prefix/share/config.site
2214 ac_site_file2=$ac_default_prefix/etc/config.site
2215 fi
2216 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2217 do
2218 test "x$ac_site_file" = xNONE && continue
2219 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
2220 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2221 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
2222 sed 's/^/| /' "$ac_site_file" >&5
2223 . "$ac_site_file" \
2224 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2225 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2226 as_fn_error $? "failed to load site script $ac_site_file
2227 See \`config.log' for more details" "$LINENO" 5; }
2228 fi
2229 done
2230
2231 if test -r "$cache_file"; then
2232 # Some versions of bash will fail to source /dev/null (special files
2233 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
2234 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2235 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2236 $as_echo "$as_me: loading cache $cache_file" >&6;}
2237 case $cache_file in
2238 [\\/]* | ?:[\\/]* ) . "$cache_file";;
2239 *) . "./$cache_file";;
2240 esac
2241 fi
2242 else
2243 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2244 $as_echo "$as_me: creating cache $cache_file" >&6;}
2245 >$cache_file
2246 fi
2247
2248 # Check that the precious variables saved in the cache have kept the same
2249 # value.
2250 ac_cache_corrupted=false
2251 for ac_var in $ac_precious_vars; do
2252 eval ac_old_set=\$ac_cv_env_${ac_var}_set
2253 eval ac_new_set=\$ac_env_${ac_var}_set
2254 eval ac_old_val=\$ac_cv_env_${ac_var}_value
2255 eval ac_new_val=\$ac_env_${ac_var}_value
2256 case $ac_old_set,$ac_new_set in
2257 set,)
2258 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2259 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2260 ac_cache_corrupted=: ;;
2261 ,set)
2262 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2263 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2264 ac_cache_corrupted=: ;;
2265 ,);;
2266 *)
2267 if test "x$ac_old_val" != "x$ac_new_val"; then
2268 # differences in whitespace do not lead to failure.
2269 ac_old_val_w=`echo x $ac_old_val`
2270 ac_new_val_w=`echo x $ac_new_val`
2271 if test "$ac_old_val_w" != "$ac_new_val_w"; then
2272 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2273 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2274 ac_cache_corrupted=:
2275 else
2276 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2277 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2278 eval $ac_var=\$ac_old_val
2279 fi
2280 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
2281 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
2282 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
2283 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
2284 fi;;
2285 esac
2286 # Pass precious variables to config.status.
2287 if test "$ac_new_set" = set; then
2288 case $ac_new_val in
2289 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2290 *) ac_arg=$ac_var=$ac_new_val ;;
2291 esac
2292 case " $ac_configure_args " in
2293 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
2294 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2295 esac
2296 fi
2297 done
2298 if $ac_cache_corrupted; then
2299 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2300 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2301 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2302 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2303 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
2304 fi
2305 ## -------------------- ##
2306 ## Main body of script. ##
2307 ## -------------------- ##
2308
2309 ac_ext=c
2310 ac_cpp='$CPP $CPPFLAGS'
2311 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2312 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2313 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2314
2315
2316
2317 ac_aux_dir=
2318 for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
2319 if test -f "$ac_dir/install-sh"; then
2320 ac_aux_dir=$ac_dir
2321 ac_install_sh="$ac_aux_dir/install-sh -c"
2322 break
2323 elif test -f "$ac_dir/install.sh"; then
2324 ac_aux_dir=$ac_dir
2325 ac_install_sh="$ac_aux_dir/install.sh -c"
2326 break
2327 elif test -f "$ac_dir/shtool"; then
2328 ac_aux_dir=$ac_dir
2329 ac_install_sh="$ac_aux_dir/shtool install -c"
2330 break
2331 fi
2332 done
2333 if test -z "$ac_aux_dir"; then
2334 as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
2335 fi
2336
2337 # These three variables are undocumented and unsupported,
2338 # and are intended to be withdrawn in a future Autoconf release.
2339 # They can cause serious problems if a builder's source tree is in a directory
2340 # whose full name contains unusual characters.
2341 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
2342 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
2343 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
2344
2345
2346 # Make sure we can run config.sub.
2347 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
2348 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
2349
2350 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
2351 $as_echo_n "checking build system type... " >&6; }
2352 if ${ac_cv_build+:} false; then :
2353 $as_echo_n "(cached) " >&6
2354 else
2355 ac_build_alias=$build_alias
2356 test "x$ac_build_alias" = x &&
2357 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
2358 test "x$ac_build_alias" = x &&
2359 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
2360 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
2361 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
2362
2363 fi
2364 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
2365 $as_echo "$ac_cv_build" >&6; }
2366 case $ac_cv_build in
2367 *-*-*) ;;
2368 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
2369 esac
2370 build=$ac_cv_build
2371 ac_save_IFS=$IFS; IFS='-'
2372 set x $ac_cv_build
2373 shift
2374 build_cpu=$1
2375 build_vendor=$2
2376 shift; shift
2377 # Remember, the first character of IFS is used to create $*,
2378 # except with old shells:
2379 build_os=$*
2380 IFS=$ac_save_IFS
2381 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
2382
2383
2384 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
2385 $as_echo_n "checking host system type... " >&6; }
2386 if ${ac_cv_host+:} false; then :
2387 $as_echo_n "(cached) " >&6
2388 else
2389 if test "x$host_alias" = x; then
2390 ac_cv_host=$ac_cv_build
2391 else
2392 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
2393 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
2394 fi
2395
2396 fi
2397 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
2398 $as_echo "$ac_cv_host" >&6; }
2399 case $ac_cv_host in
2400 *-*-*) ;;
2401 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
2402 esac
2403 host=$ac_cv_host
2404 ac_save_IFS=$IFS; IFS='-'
2405 set x $ac_cv_host
2406 shift
2407 host_cpu=$1
2408 host_vendor=$2
2409 shift; shift
2410 # Remember, the first character of IFS is used to create $*,
2411 # except with old shells:
2412 host_os=$*
2413 IFS=$ac_save_IFS
2414 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
2415
2416
2417 { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
2418 $as_echo_n "checking target system type... " >&6; }
2419 if ${ac_cv_target+:} false; then :
2420 $as_echo_n "(cached) " >&6
2421 else
2422 if test "x$target_alias" = x; then
2423 ac_cv_target=$ac_cv_host
2424 else
2425 ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
2426 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
2427 fi
2428
2429 fi
2430 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
2431 $as_echo "$ac_cv_target" >&6; }
2432 case $ac_cv_target in
2433 *-*-*) ;;
2434 *) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;;
2435 esac
2436 target=$ac_cv_target
2437 ac_save_IFS=$IFS; IFS='-'
2438 set x $ac_cv_target
2439 shift
2440 target_cpu=$1
2441 target_vendor=$2
2442 shift; shift
2443 # Remember, the first character of IFS is used to create $*,
2444 # except with old shells:
2445 target_os=$*
2446 IFS=$ac_save_IFS
2447 case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
2448
2449
2450 # The aliases save the names the user supplied, while $host etc.
2451 # will get canonicalized.
2452 test -n "$target_alias" &&
2453 test "$program_prefix$program_suffix$program_transform_name" = \
2454 NONENONEs,x,x, &&
2455 program_prefix=${target_alias}-
2456
2457
2458
2459
2460
2461
2462
2463
2464 # Check whether --with-gcc was given.
2465 if test "${with_gcc+set}" = set; then :
2466 withval=$with_gcc;
2467 fi
2468
2469 V_CCOPT=""
2470 if test "${srcdir}" != "." ; then
2471 V_CCOPT="-I\$(srcdir)"
2472 fi
2473 if test "${CFLAGS+set}" = set; then
2474 LBL_CFLAGS="$CFLAGS"
2475 fi
2476 if test -z "$CC" ; then
2477 case "$host_os" in
2478
2479 bsdi*)
2480 # Extract the first word of "shlicc2", so it can be a program name with args.
2481 set dummy shlicc2; ac_word=$2
2482 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2483 $as_echo_n "checking for $ac_word... " >&6; }
2484 if ${ac_cv_prog_SHLICC2+:} false; then :
2485 $as_echo_n "(cached) " >&6
2486 else
2487 if test -n "$SHLICC2"; then
2488 ac_cv_prog_SHLICC2="$SHLICC2" # Let the user override the test.
2489 else
2490 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2491 for as_dir in $PATH
2492 do
2493 IFS=$as_save_IFS
2494 test -z "$as_dir" && as_dir=.
2495 for ac_exec_ext in '' $ac_executable_extensions; do
2496 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2497 ac_cv_prog_SHLICC2="yes"
2498 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2499 break 2
2500 fi
2501 done
2502 done
2503 IFS=$as_save_IFS
2504
2505 test -z "$ac_cv_prog_SHLICC2" && ac_cv_prog_SHLICC2="no"
2506 fi
2507 fi
2508 SHLICC2=$ac_cv_prog_SHLICC2
2509 if test -n "$SHLICC2"; then
2510 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SHLICC2" >&5
2511 $as_echo "$SHLICC2" >&6; }
2512 else
2513 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2514 $as_echo "no" >&6; }
2515 fi
2516
2517
2518 if test $SHLICC2 = yes ; then
2519 CC=shlicc2
2520 export CC
2521 fi
2522 ;;
2523 esac
2524 fi
2525 if test -z "$CC" -a "$with_gcc" = no ; then
2526 CC=cc
2527 export CC
2528 fi
2529
2530 ac_ext=c
2531 ac_cpp='$CPP $CPPFLAGS'
2532 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2533 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2534 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2535 if test -n "$ac_tool_prefix"; then
2536 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
2537 set dummy ${ac_tool_prefix}gcc; ac_word=$2
2538 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2539 $as_echo_n "checking for $ac_word... " >&6; }
2540 if ${ac_cv_prog_CC+:} false; then :
2541 $as_echo_n "(cached) " >&6
2542 else
2543 if test -n "$CC"; then
2544 ac_cv_prog_CC="$CC" # Let the user override the test.
2545 else
2546 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2547 for as_dir in $PATH
2548 do
2549 IFS=$as_save_IFS
2550 test -z "$as_dir" && as_dir=.
2551 for ac_exec_ext in '' $ac_executable_extensions; do
2552 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2553 ac_cv_prog_CC="${ac_tool_prefix}gcc"
2554 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2555 break 2
2556 fi
2557 done
2558 done
2559 IFS=$as_save_IFS
2560
2561 fi
2562 fi
2563 CC=$ac_cv_prog_CC
2564 if test -n "$CC"; then
2565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2566 $as_echo "$CC" >&6; }
2567 else
2568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2569 $as_echo "no" >&6; }
2570 fi
2571
2572
2573 fi
2574 if test -z "$ac_cv_prog_CC"; then
2575 ac_ct_CC=$CC
2576 # Extract the first word of "gcc", so it can be a program name with args.
2577 set dummy gcc; ac_word=$2
2578 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2579 $as_echo_n "checking for $ac_word... " >&6; }
2580 if ${ac_cv_prog_ac_ct_CC+:} false; then :
2581 $as_echo_n "(cached) " >&6
2582 else
2583 if test -n "$ac_ct_CC"; then
2584 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2585 else
2586 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2587 for as_dir in $PATH
2588 do
2589 IFS=$as_save_IFS
2590 test -z "$as_dir" && as_dir=.
2591 for ac_exec_ext in '' $ac_executable_extensions; do
2592 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2593 ac_cv_prog_ac_ct_CC="gcc"
2594 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2595 break 2
2596 fi
2597 done
2598 done
2599 IFS=$as_save_IFS
2600
2601 fi
2602 fi
2603 ac_ct_CC=$ac_cv_prog_ac_ct_CC
2604 if test -n "$ac_ct_CC"; then
2605 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
2606 $as_echo "$ac_ct_CC" >&6; }
2607 else
2608 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2609 $as_echo "no" >&6; }
2610 fi
2611
2612 if test "x$ac_ct_CC" = x; then
2613 CC=""
2614 else
2615 case $cross_compiling:$ac_tool_warned in
2616 yes:)
2617 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
2618 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
2619 ac_tool_warned=yes ;;
2620 esac
2621 CC=$ac_ct_CC
2622 fi
2623 else
2624 CC="$ac_cv_prog_CC"
2625 fi
2626
2627 if test -z "$CC"; then
2628 if test -n "$ac_tool_prefix"; then
2629 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
2630 set dummy ${ac_tool_prefix}cc; ac_word=$2
2631 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2632 $as_echo_n "checking for $ac_word... " >&6; }
2633 if ${ac_cv_prog_CC+:} false; then :
2634 $as_echo_n "(cached) " >&6
2635 else
2636 if test -n "$CC"; then
2637 ac_cv_prog_CC="$CC" # Let the user override the test.
2638 else
2639 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2640 for as_dir in $PATH
2641 do
2642 IFS=$as_save_IFS
2643 test -z "$as_dir" && as_dir=.
2644 for ac_exec_ext in '' $ac_executable_extensions; do
2645 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2646 ac_cv_prog_CC="${ac_tool_prefix}cc"
2647 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2648 break 2
2649 fi
2650 done
2651 done
2652 IFS=$as_save_IFS
2653
2654 fi
2655 fi
2656 CC=$ac_cv_prog_CC
2657 if test -n "$CC"; then
2658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2659 $as_echo "$CC" >&6; }
2660 else
2661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2662 $as_echo "no" >&6; }
2663 fi
2664
2665
2666 fi
2667 fi
2668 if test -z "$CC"; then
2669 # Extract the first word of "cc", so it can be a program name with args.
2670 set dummy cc; ac_word=$2
2671 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2672 $as_echo_n "checking for $ac_word... " >&6; }
2673 if ${ac_cv_prog_CC+:} false; then :
2674 $as_echo_n "(cached) " >&6
2675 else
2676 if test -n "$CC"; then
2677 ac_cv_prog_CC="$CC" # Let the user override the test.
2678 else
2679 ac_prog_rejected=no
2680 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2681 for as_dir in $PATH
2682 do
2683 IFS=$as_save_IFS
2684 test -z "$as_dir" && as_dir=.
2685 for ac_exec_ext in '' $ac_executable_extensions; do
2686 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2687 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
2688 ac_prog_rejected=yes
2689 continue
2690 fi
2691 ac_cv_prog_CC="cc"
2692 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2693 break 2
2694 fi
2695 done
2696 done
2697 IFS=$as_save_IFS
2698
2699 if test $ac_prog_rejected = yes; then
2700 # We found a bogon in the path, so make sure we never use it.
2701 set dummy $ac_cv_prog_CC
2702 shift
2703 if test $# != 0; then
2704 # We chose a different compiler from the bogus one.
2705 # However, it has the same basename, so the bogon will be chosen
2706 # first if we set CC to just the basename; use the full file name.
2707 shift
2708 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
2709 fi
2710 fi
2711 fi
2712 fi
2713 CC=$ac_cv_prog_CC
2714 if test -n "$CC"; then
2715 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2716 $as_echo "$CC" >&6; }
2717 else
2718 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2719 $as_echo "no" >&6; }
2720 fi
2721
2722
2723 fi
2724 if test -z "$CC"; then
2725 if test -n "$ac_tool_prefix"; then
2726 for ac_prog in cl.exe
2727 do
2728 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2729 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
2730 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2731 $as_echo_n "checking for $ac_word... " >&6; }
2732 if ${ac_cv_prog_CC+:} false; then :
2733 $as_echo_n "(cached) " >&6
2734 else
2735 if test -n "$CC"; then
2736 ac_cv_prog_CC="$CC" # Let the user override the test.
2737 else
2738 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2739 for as_dir in $PATH
2740 do
2741 IFS=$as_save_IFS
2742 test -z "$as_dir" && as_dir=.
2743 for ac_exec_ext in '' $ac_executable_extensions; do
2744 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2745 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
2746 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2747 break 2
2748 fi
2749 done
2750 done
2751 IFS=$as_save_IFS
2752
2753 fi
2754 fi
2755 CC=$ac_cv_prog_CC
2756 if test -n "$CC"; then
2757 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2758 $as_echo "$CC" >&6; }
2759 else
2760 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2761 $as_echo "no" >&6; }
2762 fi
2763
2764
2765 test -n "$CC" && break
2766 done
2767 fi
2768 if test -z "$CC"; then
2769 ac_ct_CC=$CC
2770 for ac_prog in cl.exe
2771 do
2772 # Extract the first word of "$ac_prog", so it can be a program name with args.
2773 set dummy $ac_prog; ac_word=$2
2774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2775 $as_echo_n "checking for $ac_word... " >&6; }
2776 if ${ac_cv_prog_ac_ct_CC+:} false; then :
2777 $as_echo_n "(cached) " >&6
2778 else
2779 if test -n "$ac_ct_CC"; then
2780 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2781 else
2782 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2783 for as_dir in $PATH
2784 do
2785 IFS=$as_save_IFS
2786 test -z "$as_dir" && as_dir=.
2787 for ac_exec_ext in '' $ac_executable_extensions; do
2788 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2789 ac_cv_prog_ac_ct_CC="$ac_prog"
2790 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2791 break 2
2792 fi
2793 done
2794 done
2795 IFS=$as_save_IFS
2796
2797 fi
2798 fi
2799 ac_ct_CC=$ac_cv_prog_ac_ct_CC
2800 if test -n "$ac_ct_CC"; then
2801 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
2802 $as_echo "$ac_ct_CC" >&6; }
2803 else
2804 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2805 $as_echo "no" >&6; }
2806 fi
2807
2808
2809 test -n "$ac_ct_CC" && break
2810 done
2811
2812 if test "x$ac_ct_CC" = x; then
2813 CC=""
2814 else
2815 case $cross_compiling:$ac_tool_warned in
2816 yes:)
2817 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
2818 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
2819 ac_tool_warned=yes ;;
2820 esac
2821 CC=$ac_ct_CC
2822 fi
2823 fi
2824
2825 fi
2826
2827
2828 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2829 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2830 as_fn_error $? "no acceptable C compiler found in \$PATH
2831 See \`config.log' for more details" "$LINENO" 5; }
2832
2833 # Provide some information about the compiler.
2834 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
2835 set X $ac_compile
2836 ac_compiler=$2
2837 for ac_option in --version -v -V -qversion; do
2838 { { ac_try="$ac_compiler $ac_option >&5"
2839 case "(($ac_try" in
2840 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2841 *) ac_try_echo=$ac_try;;
2842 esac
2843 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2844 $as_echo "$ac_try_echo"; } >&5
2845 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
2846 ac_status=$?
2847 if test -s conftest.err; then
2848 sed '10a\
2849 ... rest of stderr output deleted ...
2850 10q' conftest.err >conftest.er1
2851 cat conftest.er1 >&5
2852 fi
2853 rm -f conftest.er1 conftest.err
2854 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2855 test $ac_status = 0; }
2856 done
2857
2858 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2859 /* end confdefs.h. */
2860
2861 int
2862 main ()
2863 {
2864
2865 ;
2866 return 0;
2867 }
2868 _ACEOF
2869 ac_clean_files_save=$ac_clean_files
2870 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
2871 # Try to create an executable without -o first, disregard a.out.
2872 # It will help us diagnose broken compilers, and finding out an intuition
2873 # of exeext.
2874 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
2875 $as_echo_n "checking whether the C compiler works... " >&6; }
2876 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
2877
2878 # The possible output files:
2879 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
2880
2881 ac_rmfiles=
2882 for ac_file in $ac_files
2883 do
2884 case $ac_file in
2885 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
2886 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
2887 esac
2888 done
2889 rm -f $ac_rmfiles
2890
2891 if { { ac_try="$ac_link_default"
2892 case "(($ac_try" in
2893 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2894 *) ac_try_echo=$ac_try;;
2895 esac
2896 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2897 $as_echo "$ac_try_echo"; } >&5
2898 (eval "$ac_link_default") 2>&5
2899 ac_status=$?
2900 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2901 test $ac_status = 0; }; then :
2902 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
2903 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
2904 # in a Makefile. We should not override ac_cv_exeext if it was cached,
2905 # so that the user can short-circuit this test for compilers unknown to
2906 # Autoconf.
2907 for ac_file in $ac_files ''
2908 do
2909 test -f "$ac_file" || continue
2910 case $ac_file in
2911 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
2912 ;;
2913 [ab].out )
2914 # We found the default executable, but exeext='' is most
2915 # certainly right.
2916 break;;
2917 *.* )
2918 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
2919 then :; else
2920 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2921 fi
2922 # We set ac_cv_exeext here because the later test for it is not
2923 # safe: cross compilers may not add the suffix if given an `-o'
2924 # argument, so we may need to know it at that point already.
2925 # Even if this section looks crufty: it has the advantage of
2926 # actually working.
2927 break;;
2928 * )
2929 break;;
2930 esac
2931 done
2932 test "$ac_cv_exeext" = no && ac_cv_exeext=
2933
2934 else
2935 ac_file=''
2936 fi
2937 if test -z "$ac_file"; then :
2938 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2939 $as_echo "no" >&6; }
2940 $as_echo "$as_me: failed program was:" >&5
2941 sed 's/^/| /' conftest.$ac_ext >&5
2942
2943 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2944 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2945 as_fn_error 77 "C compiler cannot create executables
2946 See \`config.log' for more details" "$LINENO" 5; }
2947 else
2948 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
2949 $as_echo "yes" >&6; }
2950 fi
2951 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
2952 $as_echo_n "checking for C compiler default output file name... " >&6; }
2953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
2954 $as_echo "$ac_file" >&6; }
2955 ac_exeext=$ac_cv_exeext
2956
2957 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
2958 ac_clean_files=$ac_clean_files_save
2959 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
2960 $as_echo_n "checking for suffix of executables... " >&6; }
2961 if { { ac_try="$ac_link"
2962 case "(($ac_try" in
2963 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2964 *) ac_try_echo=$ac_try;;
2965 esac
2966 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2967 $as_echo "$ac_try_echo"; } >&5
2968 (eval "$ac_link") 2>&5
2969 ac_status=$?
2970 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2971 test $ac_status = 0; }; then :
2972 # If both `conftest.exe' and `conftest' are `present' (well, observable)
2973 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
2974 # work properly (i.e., refer to `conftest.exe'), while it won't with
2975 # `rm'.
2976 for ac_file in conftest.exe conftest conftest.*; do
2977 test -f "$ac_file" || continue
2978 case $ac_file in
2979 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
2980 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2981 break;;
2982 * ) break;;
2983 esac
2984 done
2985 else
2986 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2987 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2988 as_fn_error $? "cannot compute suffix of executables: cannot compile and link
2989 See \`config.log' for more details" "$LINENO" 5; }
2990 fi
2991 rm -f conftest conftest$ac_cv_exeext
2992 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
2993 $as_echo "$ac_cv_exeext" >&6; }
2994
2995 rm -f conftest.$ac_ext
2996 EXEEXT=$ac_cv_exeext
2997 ac_exeext=$EXEEXT
2998 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2999 /* end confdefs.h. */
3000 #include <stdio.h>
3001 int
3002 main ()
3003 {
3004 FILE *f = fopen ("conftest.out", "w");
3005 return ferror (f) || fclose (f) != 0;
3006
3007 ;
3008 return 0;
3009 }
3010 _ACEOF
3011 ac_clean_files="$ac_clean_files conftest.out"
3012 # Check that the compiler produces executables we can run. If not, either
3013 # the compiler is broken, or we cross compile.
3014 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
3015 $as_echo_n "checking whether we are cross compiling... " >&6; }
3016 if test "$cross_compiling" != yes; then
3017 { { ac_try="$ac_link"
3018 case "(($ac_try" in
3019 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3020 *) ac_try_echo=$ac_try;;
3021 esac
3022 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3023 $as_echo "$ac_try_echo"; } >&5
3024 (eval "$ac_link") 2>&5
3025 ac_status=$?
3026 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3027 test $ac_status = 0; }
3028 if { ac_try='./conftest$ac_cv_exeext'
3029 { { case "(($ac_try" in
3030 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3031 *) ac_try_echo=$ac_try;;
3032 esac
3033 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3034 $as_echo "$ac_try_echo"; } >&5
3035 (eval "$ac_try") 2>&5
3036 ac_status=$?
3037 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3038 test $ac_status = 0; }; }; then
3039 cross_compiling=no
3040 else
3041 if test "$cross_compiling" = maybe; then
3042 cross_compiling=yes
3043 else
3044 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3045 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3046 as_fn_error $? "cannot run C compiled programs.
3047 If you meant to cross compile, use \`--host'.
3048 See \`config.log' for more details" "$LINENO" 5; }
3049 fi
3050 fi
3051 fi
3052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
3053 $as_echo "$cross_compiling" >&6; }
3054
3055 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
3056 ac_clean_files=$ac_clean_files_save
3057 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
3058 $as_echo_n "checking for suffix of object files... " >&6; }
3059 if ${ac_cv_objext+:} false; then :
3060 $as_echo_n "(cached) " >&6
3061 else
3062 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3063 /* end confdefs.h. */
3064
3065 int
3066 main ()
3067 {
3068
3069 ;
3070 return 0;
3071 }
3072 _ACEOF
3073 rm -f conftest.o conftest.obj
3074 if { { ac_try="$ac_compile"
3075 case "(($ac_try" in
3076 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3077 *) ac_try_echo=$ac_try;;
3078 esac
3079 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3080 $as_echo "$ac_try_echo"; } >&5
3081 (eval "$ac_compile") 2>&5
3082 ac_status=$?
3083 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3084 test $ac_status = 0; }; then :
3085 for ac_file in conftest.o conftest.obj conftest.*; do
3086 test -f "$ac_file" || continue;
3087 case $ac_file in
3088 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
3089 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3090 break;;
3091 esac
3092 done
3093 else
3094 $as_echo "$as_me: failed program was:" >&5
3095 sed 's/^/| /' conftest.$ac_ext >&5
3096
3097 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3098 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3099 as_fn_error $? "cannot compute suffix of object files: cannot compile
3100 See \`config.log' for more details" "$LINENO" 5; }
3101 fi
3102 rm -f conftest.$ac_cv_objext conftest.$ac_ext
3103 fi
3104 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
3105 $as_echo "$ac_cv_objext" >&6; }
3106 OBJEXT=$ac_cv_objext
3107 ac_objext=$OBJEXT
3108 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
3109 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
3110 if ${ac_cv_c_compiler_gnu+:} false; then :
3111 $as_echo_n "(cached) " >&6
3112 else
3113 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3114 /* end confdefs.h. */
3115
3116 int
3117 main ()
3118 {
3119 #ifndef __GNUC__
3120 choke me
3121 #endif
3122
3123 ;
3124 return 0;
3125 }
3126 _ACEOF
3127 if ac_fn_c_try_compile "$LINENO"; then :
3128 ac_compiler_gnu=yes
3129 else
3130 ac_compiler_gnu=no
3131 fi
3132 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3133 ac_cv_c_compiler_gnu=$ac_compiler_gnu
3134
3135 fi
3136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
3137 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
3138 if test $ac_compiler_gnu = yes; then
3139 GCC=yes
3140 else
3141 GCC=
3142 fi
3143 ac_test_CFLAGS=${CFLAGS+set}
3144 ac_save_CFLAGS=$CFLAGS
3145 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
3146 $as_echo_n "checking whether $CC accepts -g... " >&6; }
3147 if ${ac_cv_prog_cc_g+:} false; then :
3148 $as_echo_n "(cached) " >&6
3149 else
3150 ac_save_c_werror_flag=$ac_c_werror_flag
3151 ac_c_werror_flag=yes
3152 ac_cv_prog_cc_g=no
3153 CFLAGS="-g"
3154 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3155 /* end confdefs.h. */
3156
3157 int
3158 main ()
3159 {
3160
3161 ;
3162 return 0;
3163 }
3164 _ACEOF
3165 if ac_fn_c_try_compile "$LINENO"; then :
3166 ac_cv_prog_cc_g=yes
3167 else
3168 CFLAGS=""
3169 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3170 /* end confdefs.h. */
3171
3172 int
3173 main ()
3174 {
3175
3176 ;
3177 return 0;
3178 }
3179 _ACEOF
3180 if ac_fn_c_try_compile "$LINENO"; then :
3181
3182 else
3183 ac_c_werror_flag=$ac_save_c_werror_flag
3184 CFLAGS="-g"
3185 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3186 /* end confdefs.h. */
3187
3188 int
3189 main ()
3190 {
3191
3192 ;
3193 return 0;
3194 }
3195 _ACEOF
3196 if ac_fn_c_try_compile "$LINENO"; then :
3197 ac_cv_prog_cc_g=yes
3198 fi
3199 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3200 fi
3201 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3202 fi
3203 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3204 ac_c_werror_flag=$ac_save_c_werror_flag
3205 fi
3206 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
3207 $as_echo "$ac_cv_prog_cc_g" >&6; }
3208 if test "$ac_test_CFLAGS" = set; then
3209 CFLAGS=$ac_save_CFLAGS
3210 elif test $ac_cv_prog_cc_g = yes; then
3211 if test "$GCC" = yes; then
3212 CFLAGS="-g -O2"
3213 else
3214 CFLAGS="-g"
3215 fi
3216 else
3217 if test "$GCC" = yes; then
3218 CFLAGS="-O2"
3219 else
3220 CFLAGS=
3221 fi
3222 fi
3223 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
3224 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
3225 if ${ac_cv_prog_cc_c89+:} false; then :
3226 $as_echo_n "(cached) " >&6
3227 else
3228 ac_cv_prog_cc_c89=no
3229 ac_save_CC=$CC
3230 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3231 /* end confdefs.h. */
3232 #include <stdarg.h>
3233 #include <stdio.h>
3234 struct stat;
3235 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
3236 struct buf { int x; };
3237 FILE * (*rcsopen) (struct buf *, struct stat *, int);
3238 static char *e (p, i)
3239 char **p;
3240 int i;
3241 {
3242 return p[i];
3243 }
3244 static char *f (char * (*g) (char **, int), char **p, ...)
3245 {
3246 char *s;
3247 va_list v;
3248 va_start (v,p);
3249 s = g (p, va_arg (v,int));
3250 va_end (v);
3251 return s;
3252 }
3253
3254 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
3255 function prototypes and stuff, but not '\xHH' hex character constants.
3256 These don't provoke an error unfortunately, instead are silently treated
3257 as 'x'. The following induces an error, until -std is added to get
3258 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
3259 array size at least. It's necessary to write '\x00'==0 to get something
3260 that's true only with -std. */
3261 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3262
3263 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3264 inside strings and character constants. */
3265 #define FOO(x) 'x'
3266 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3267
3268 int test (int i, double x);
3269 struct s1 {int (*f) (int a);};
3270 struct s2 {int (*f) (double a);};
3271 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3272 int argc;
3273 char **argv;
3274 int
3275 main ()
3276 {
3277 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
3278 ;
3279 return 0;
3280 }
3281 _ACEOF
3282 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3283 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3284 do
3285 CC="$ac_save_CC $ac_arg"
3286 if ac_fn_c_try_compile "$LINENO"; then :
3287 ac_cv_prog_cc_c89=$ac_arg
3288 fi
3289 rm -f core conftest.err conftest.$ac_objext
3290 test "x$ac_cv_prog_cc_c89" != "xno" && break
3291 done
3292 rm -f conftest.$ac_ext
3293 CC=$ac_save_CC
3294
3295 fi
3296 # AC_CACHE_VAL
3297 case "x$ac_cv_prog_cc_c89" in
3298 x)
3299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
3300 $as_echo "none needed" >&6; } ;;
3301 xno)
3302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
3303 $as_echo "unsupported" >&6; } ;;
3304 *)
3305 CC="$CC $ac_cv_prog_cc_c89"
3306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
3307 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
3308 esac
3309 if test "x$ac_cv_prog_cc_c89" != xno; then :
3310
3311 fi
3312
3313 ac_ext=c
3314 ac_cpp='$CPP $CPPFLAGS'
3315 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3316 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3317 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3318
3319
3320
3321
3322
3323 if test "$GCC" = yes ; then
3324 #
3325 # -Werror forces warnings to be errors.
3326 #
3327 ac_lbl_cc_force_warning_errors=-Werror
3328 else
3329 V_INCLS="$V_INCLS -I/usr/local/include"
3330 LDFLAGS="$LDFLAGS -L/usr/local/lib"
3331
3332 case "$host_os" in
3333
3334 darwin*)
3335 #
3336 # This is assumed either to be GCC or clang, both
3337 # of which use -Werror to force warnings to be errors.
3338 #
3339 ac_lbl_cc_force_warning_errors=-Werror
3340 ;;
3341
3342 hpux*)
3343 #
3344 # HP C, which is what we presume we're using, doesn't
3345 # exit with a non-zero exit status if we hand it an
3346 # invalid -W flag, can't be forced to do so even with
3347 # +We, and doesn't handle GCC-style -W flags, so we
3348 # don't want to try using GCC-style -W flags.
3349 #
3350 ac_lbl_cc_dont_try_gcc_dashW=yes
3351 ;;
3352
3353 irix*)
3354 #
3355 # MIPS C, which is what we presume we're using, doesn't
3356 # necessarily exit with a non-zero exit status if we
3357 # hand it an invalid -W flag, can't be forced to do
3358 # so, and doesn't handle GCC-style -W flags, so we
3359 # don't want to try using GCC-style -W flags.
3360 #
3361 ac_lbl_cc_dont_try_gcc_dashW=yes
3362 #
3363 # It also, apparently, defaults to "char" being
3364 # unsigned, unlike most other C implementations;
3365 # I suppose we could say "signed char" whenever
3366 # we want to guarantee a signed "char", but let's
3367 # just force signed chars.
3368 #
3369 # -xansi is normally the default, but the
3370 # configure script was setting it; perhaps -cckr
3371 # was the default in the Old Days. (Then again,
3372 # that would probably be for backwards compatibility
3373 # in the days when ANSI C was Shiny and New, i.e.
3374 # 1989 and the early '90's, so maybe we can just
3375 # drop support for those compilers.)
3376 #
3377 # -g is equivalent to -g2, which turns off
3378 # optimization; we choose -g3, which generates
3379 # debugging information but doesn't turn off
3380 # optimization (even if the optimization would
3381 # cause inaccuracies in debugging).
3382 #
3383 V_CCOPT="$V_CCOPT -xansi -signed -g3"
3384 ;;
3385
3386 osf*)
3387 #
3388 # Presumed to be DEC OSF/1, Digital UNIX, or
3389 # Tru64 UNIX.
3390 #
3391 # The DEC C compiler, which is what we presume we're
3392 # using, doesn't exit with a non-zero exit status if we
3393 # hand it an invalid -W flag, can't be forced to do
3394 # so, and doesn't handle GCC-style -W flags, so we
3395 # don't want to try using GCC-style -W flags.
3396 #
3397 ac_lbl_cc_dont_try_gcc_dashW=yes
3398 #
3399 # -g is equivalent to -g2, which turns off
3400 # optimization; we choose -g3, which generates
3401 # debugging information but doesn't turn off
3402 # optimization (even if the optimization would
3403 # cause inaccuracies in debugging).
3404 #
3405 V_CCOPT="$V_CCOPT -g3"
3406 ;;
3407
3408 solaris*)
3409 #
3410 # Assumed to be Sun C, which requires -errwarn to force
3411 # warnings to be treated as errors.
3412 #
3413 ac_lbl_cc_force_warning_errors=-errwarn
3414 ;;
3415
3416 ultrix*)
3417 { $as_echo "$as_me:${as_lineno-$LINENO}: checking that Ultrix $CC hacks const in prototypes" >&5
3418 $as_echo_n "checking that Ultrix $CC hacks const in prototypes... " >&6; }
3419 if ${ac_cv_lbl_cc_const_proto+:} false; then :
3420 $as_echo_n "(cached) " >&6
3421 else
3422
3423 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3424 /* end confdefs.h. */
3425 #include <sys/types.h>
3426 int
3427 main ()
3428 {
3429 struct a { int b; };
3430 void c(const struct a *)
3431 ;
3432 return 0;
3433 }
3434 _ACEOF
3435 if ac_fn_c_try_compile "$LINENO"; then :
3436 ac_cv_lbl_cc_const_proto=yes
3437 else
3438 ac_cv_lbl_cc_const_proto=no
3439 fi
3440 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3441 fi
3442
3443 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_cc_const_proto" >&5
3444 $as_echo "$ac_cv_lbl_cc_const_proto" >&6; }
3445 if test $ac_cv_lbl_cc_const_proto = no ; then
3446
3447 $as_echo "#define const /**/" >>confdefs.h
3448
3449 fi
3450 ;;
3451 esac
3452 V_CCOPT="$V_CCOPT -O"
3453 fi
3454
3455
3456 if test "$GCC" = yes ; then
3457 #
3458 # On platforms where we build a shared library:
3459 #
3460 # add options to generate position-independent code,
3461 # if necessary (it's the default in AIX and Darwin/OS X);
3462 #
3463 # define option to set the soname of the shared library,
3464 # if the OS supports that;
3465 #
3466 # add options to specify, at link time, a directory to
3467 # add to the run-time search path, if that's necessary.
3468 #
3469 V_SHLIB_CMD="\$(CC)"
3470 V_SHLIB_OPT="-shared"
3471 case "$host_os" in
3472
3473 aix*)
3474 ;;
3475
3476 freebsd*|netbsd*|openbsd*|dragonfly*|linux*|osf*)
3477 #
3478 # Platforms where the linker is the GNU linker
3479 # or accepts command-line arguments like
3480 # those the GNU linker accepts.
3481 #
3482 # Some instruction sets require -fPIC on some
3483 # operating systems. Check for them. If you
3484 # have a combination that requires it, add it
3485 # here.
3486 #
3487 PIC_OPT=-fpic
3488 case "$host_cpu" in
3489
3490 sparc64*)
3491 case "$host_os" in
3492
3493 freebsd*|openbsd*)
3494 PIC_OPT=-fPIC
3495 ;;
3496 esac
3497 ;;
3498 esac
3499 V_CCOPT="$V_CCOPT $PIC_OPT"
3500 V_SONAME_OPT="-Wl,-soname,"
3501 V_RPATH_OPT="-Wl,-rpath,"
3502 ;;
3503
3504 hpux*)
3505 V_CCOPT="$V_CCOPT -fpic"
3506 #
3507 # XXX - this assumes GCC is using the HP linker,
3508 # rather than the GNU linker, and that the "+h"
3509 # option is used on all HP-UX platforms, both .sl
3510 # and .so.
3511 #
3512 V_SONAME_OPT="-Wl,+h,"
3513 #
3514 # By default, directories specifed with -L
3515 # are added to the run-time search path, so
3516 # we don't add them in pcap-config.
3517 #
3518 ;;
3519
3520 solaris*)
3521 V_CCOPT="$V_CCOPT -fpic"
3522 #
3523 # XXX - this assumes GCC is using the Sun linker,
3524 # rather than the GNU linker.
3525 #
3526 V_SONAME_OPT="-Wl,-h,"
3527 V_RPATH_OPT="-Wl,-R,"
3528 ;;
3529 esac
3530 else
3531 #
3532 # Set the appropriate compiler flags and, on platforms
3533 # where we build a shared library:
3534 #
3535 # add options to generate position-independent code,
3536 # if necessary (it's the default in Darwin/OS X);
3537 #
3538 # if we generate ".so" shared libraries, define the
3539 # appropriate options for building the shared library;
3540 #
3541 # add options to specify, at link time, a directory to
3542 # add to the run-time search path, if that's necessary.
3543 #
3544 # Note: spaces after V_SONAME_OPT are significant; on
3545 # some platforms the soname is passed with a GCC-like
3546 # "-Wl,-soname,{soname}" option, with the soname part
3547 # of the option, while on other platforms the C compiler
3548 # driver takes it as a regular option with the soname
3549 # following the option. The same applies to V_RPATH_OPT.
3550 #
3551 case "$host_os" in
3552
3553 aix*)
3554 V_SHLIB_CMD="\$(CC)"
3555 V_SHLIB_OPT="-G -bnoentry -bexpall"
3556 ;;
3557
3558 freebsd*|netbsd*|openbsd*|dragonfly*|linux*)
3559 #
3560 # "cc" is GCC.
3561 #
3562 V_CCOPT="$V_CCOPT -fpic"
3563 V_SHLIB_CMD="\$(CC)"
3564 V_SHLIB_OPT="-shared"
3565 V_SONAME_OPT="-Wl,-soname,"
3566 V_RPATH_OPT="-Wl,-rpath,"
3567 ;;
3568
3569 hpux*)
3570 V_CCOPT="$V_CCOPT +z"
3571 V_SHLIB_CMD="\$(LD)"
3572 V_SHLIB_OPT="-b"
3573 V_SONAME_OPT="+h "
3574 #
3575 # By default, directories specifed with -L
3576 # are added to the run-time search path, so
3577 # we don't add them in pcap-config.
3578 #
3579 ;;
3580
3581 osf*)
3582 #
3583 # Presumed to be DEC OSF/1, Digital UNIX, or
3584 # Tru64 UNIX.
3585 #
3586 V_SHLIB_CMD="\$(CC)"
3587 V_SHLIB_OPT="-shared"
3588 V_SONAME_OPT="-soname "
3589 V_RPATH_OPT="-rpath "
3590 ;;
3591
3592 solaris*)
3593 V_CCOPT="$V_CCOPT -Kpic"
3594 V_SHLIB_CMD="\$(CC)"
3595 V_SHLIB_OPT="-G"
3596 V_SONAME_OPT="-h "
3597 V_RPATH_OPT="-R"
3598 ;;
3599 esac
3600 fi
3601
3602 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
3603 $as_echo_n "checking for inline... " >&6; }
3604 save_CFLAGS="$CFLAGS"
3605 CFLAGS="$V_CCOPT"
3606 if ${ac_cv_lbl_inline+:} false; then :
3607 $as_echo_n "(cached) " >&6
3608 else
3609
3610 ac_cv_lbl_inline=""
3611 ac_lbl_cc_inline=no
3612 for ac_lbl_inline in inline __inline__ __inline
3613 do
3614 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3615 /* end confdefs.h. */
3616 #define inline $ac_lbl_inline
3617 static inline struct iltest *foo(void);
3618 struct iltest {
3619 int iltest1;
3620 int iltest2;
3621 };
3622
3623 static inline struct iltest *
3624 foo()
3625 {
3626 static struct iltest xxx;
3627
3628 return &xxx;
3629 }
3630 int
3631 main ()
3632 {
3633
3634 ;
3635 return 0;
3636 }
3637 _ACEOF
3638 if ac_fn_c_try_compile "$LINENO"; then :
3639 ac_lbl_cc_inline=yes
3640 fi
3641 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3642 if test "$ac_lbl_cc_inline" = yes ; then
3643 break;
3644 fi
3645 done
3646 if test "$ac_lbl_cc_inline" = yes ; then
3647 ac_cv_lbl_inline=$ac_lbl_inline
3648 fi
3649 fi
3650
3651 CFLAGS="$save_CFLAGS"
3652 if test ! -z "$ac_cv_lbl_inline" ; then
3653 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_inline" >&5
3654 $as_echo "$ac_cv_lbl_inline" >&6; }
3655 else
3656 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3657 $as_echo "no" >&6; }
3658 fi
3659
3660 cat >>confdefs.h <<_ACEOF
3661 #define inline $ac_cv_lbl_inline
3662 _ACEOF
3663
3664
3665 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __attribute__" >&5
3666 $as_echo_n "checking for __attribute__... " >&6; }
3667 if ${ac_cv___attribute__+:} false; then :
3668 $as_echo_n "(cached) " >&6
3669 else
3670
3671 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3672 /* end confdefs.h. */
3673
3674
3675 #include <stdlib.h>
3676
3677 static void foo(void) __attribute__ ((noreturn));
3678
3679 static void
3680 foo(void)
3681 {
3682 exit(1);
3683 }
3684
3685 int
3686 main(int argc, char **argv)
3687 {
3688 foo();
3689 }
3690
3691 _ACEOF
3692 if ac_fn_c_try_compile "$LINENO"; then :
3693 ac_cv___attribute__=yes
3694 else
3695 ac_cv___attribute__=no
3696 fi
3697 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3698 fi
3699
3700 if test "$ac_cv___attribute__" = "yes"; then
3701
3702 $as_echo "#define HAVE___ATTRIBUTE__ 1" >>confdefs.h
3703
3704 else
3705 #
3706 # We can't use __attribute__, so we can't use __attribute__((unused)),
3707 # so we define _U_ to an empty string.
3708 #
3709 V_DEFS="$V_DEFS -D_U_=\"\""
3710 fi
3711 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv___attribute__" >&5
3712 $as_echo "$ac_cv___attribute__" >&6; }
3713
3714 if test "$ac_cv___attribute__" = "yes"; then
3715
3716 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether __attribute__((unused)) can be used without warnings" >&5
3717 $as_echo_n "checking whether __attribute__((unused)) can be used without warnings... " >&6; }
3718 if ${ac_cv___attribute___unused+:} false; then :
3719 $as_echo_n "(cached) " >&6
3720 else
3721
3722 save_CFLAGS="$CFLAGS"
3723 CFLAGS="$CFLAGS $ac_lbl_cc_force_warning_errors"
3724 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3725 /* end confdefs.h. */
3726
3727
3728 #include <stdlib.h>
3729 #include <stdio.h>
3730
3731 int
3732 main(int argc __attribute((unused)), char **argv __attribute((unused)))
3733 {
3734 printf("Hello, world!\n");
3735 return 0;
3736 }
3737
3738 _ACEOF
3739 if ac_fn_c_try_compile "$LINENO"; then :
3740 ac_cv___attribute___unused=yes
3741 else
3742 ac_cv___attribute___unused=no
3743 fi
3744 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3745 fi
3746
3747 CFLAGS="$save_CFLAGS"
3748 if test "$ac_cv___attribute___unused" = "yes"; then
3749 V_DEFS="$V_DEFS -D_U_=\"__attribute__((unused))\""
3750 else
3751 V_DEFS="$V_DEFS -D_U_=\"\""
3752 fi
3753 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv___attribute___unused" >&5
3754 $as_echo "$ac_cv___attribute___unused" >&6; }
3755
3756
3757 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether __attribute__((format)) can be used without warnings" >&5
3758 $as_echo_n "checking whether __attribute__((format)) can be used without warnings... " >&6; }
3759 if ${ac_cv___attribute___format+:} false; then :
3760 $as_echo_n "(cached) " >&6
3761 else
3762
3763 save_CFLAGS="$CFLAGS"
3764 CFLAGS="$CFLAGS $ac_lbl_cc_force_warning_errors"
3765 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3766 /* end confdefs.h. */
3767
3768
3769 #include <stdlib.h>
3770
3771 extern int foo(const char *fmt, ...)
3772 __attribute__ ((format (printf, 1, 2)));
3773
3774 int
3775 main(int argc, char **argv)
3776 {
3777 foo("%s", "test");
3778 }
3779
3780 _ACEOF
3781 if ac_fn_c_try_compile "$LINENO"; then :
3782 ac_cv___attribute___format=yes
3783 else
3784 ac_cv___attribute___format=no
3785 fi
3786 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3787 fi
3788
3789 CFLAGS="$save_CFLAGS"
3790 if test "$ac_cv___attribute___format" = "yes"; then
3791
3792 $as_echo "#define __ATTRIBUTE___FORMAT_OK 1" >>confdefs.h
3793
3794 fi
3795 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv___attribute___format" >&5
3796 $as_echo "$ac_cv___attribute___format" >&6; }
3797
3798 fi
3799
3800 ac_ext=c
3801 ac_cpp='$CPP $CPPFLAGS'
3802 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3803 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3804 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3805 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
3806 $as_echo_n "checking how to run the C preprocessor... " >&6; }
3807 # On Suns, sometimes $CPP names a directory.
3808 if test -n "$CPP" && test -d "$CPP"; then
3809 CPP=
3810 fi
3811 if test -z "$CPP"; then
3812 if ${ac_cv_prog_CPP+:} false; then :
3813 $as_echo_n "(cached) " >&6
3814 else
3815 # Double quotes because CPP needs to be expanded
3816 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3817 do
3818 ac_preproc_ok=false
3819 for ac_c_preproc_warn_flag in '' yes
3820 do
3821 # Use a header file that comes with gcc, so configuring glibc
3822 # with a fresh cross-compiler works.
3823 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3824 # <limits.h> exists even on freestanding compilers.
3825 # On the NeXT, cc -E runs the code through the compiler's parser,
3826 # not just through cpp. "Syntax error" is here to catch this case.
3827 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3828 /* end confdefs.h. */
3829 #ifdef __STDC__
3830 # include <limits.h>
3831 #else
3832 # include <assert.h>
3833 #endif
3834 Syntax error
3835 _ACEOF
3836 if ac_fn_c_try_cpp "$LINENO"; then :
3837
3838 else
3839 # Broken: fails on valid input.
3840 continue
3841 fi
3842 rm -f conftest.err conftest.i conftest.$ac_ext
3843
3844 # OK, works on sane cases. Now check whether nonexistent headers
3845 # can be detected and how.
3846 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3847 /* end confdefs.h. */
3848 #include <ac_nonexistent.h>
3849 _ACEOF
3850 if ac_fn_c_try_cpp "$LINENO"; then :
3851 # Broken: success on invalid input.
3852 continue
3853 else
3854 # Passes both tests.
3855 ac_preproc_ok=:
3856 break
3857 fi
3858 rm -f conftest.err conftest.i conftest.$ac_ext
3859
3860 done
3861 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3862 rm -f conftest.i conftest.err conftest.$ac_ext
3863 if $ac_preproc_ok; then :
3864 break
3865 fi
3866
3867 done
3868 ac_cv_prog_CPP=$CPP
3869
3870 fi
3871 CPP=$ac_cv_prog_CPP
3872 else
3873 ac_cv_prog_CPP=$CPP
3874 fi
3875 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
3876 $as_echo "$CPP" >&6; }
3877 ac_preproc_ok=false
3878 for ac_c_preproc_warn_flag in '' yes
3879 do
3880 # Use a header file that comes with gcc, so configuring glibc
3881 # with a fresh cross-compiler works.
3882 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3883 # <limits.h> exists even on freestanding compilers.
3884 # On the NeXT, cc -E runs the code through the compiler's parser,
3885 # not just through cpp. "Syntax error" is here to catch this case.
3886 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3887 /* end confdefs.h. */
3888 #ifdef __STDC__
3889 # include <limits.h>
3890 #else
3891 # include <assert.h>
3892 #endif
3893 Syntax error
3894 _ACEOF
3895 if ac_fn_c_try_cpp "$LINENO"; then :
3896
3897 else
3898 # Broken: fails on valid input.
3899 continue
3900 fi
3901 rm -f conftest.err conftest.i conftest.$ac_ext
3902
3903 # OK, works on sane cases. Now check whether nonexistent headers
3904 # can be detected and how.
3905 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3906 /* end confdefs.h. */
3907 #include <ac_nonexistent.h>
3908 _ACEOF
3909 if ac_fn_c_try_cpp "$LINENO"; then :
3910 # Broken: success on invalid input.
3911 continue
3912 else
3913 # Passes both tests.
3914 ac_preproc_ok=:
3915 break
3916 fi
3917 rm -f conftest.err conftest.i conftest.$ac_ext
3918
3919 done
3920 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3921 rm -f conftest.i conftest.err conftest.$ac_ext
3922 if $ac_preproc_ok; then :
3923
3924 else
3925 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3926 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3927 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
3928 See \`config.log' for more details" "$LINENO" 5; }
3929 fi
3930
3931 ac_ext=c
3932 ac_cpp='$CPP $CPPFLAGS'
3933 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3934 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3935 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3936
3937
3938 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
3939 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
3940 if ${ac_cv_path_GREP+:} false; then :
3941 $as_echo_n "(cached) " >&6
3942 else
3943 if test -z "$GREP"; then
3944 ac_path_GREP_found=false
3945 # Loop through the user's path and test for each of PROGNAME-LIST
3946 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3947 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
3948 do
3949 IFS=$as_save_IFS
3950 test -z "$as_dir" && as_dir=.
3951 for ac_prog in grep ggrep; do
3952 for ac_exec_ext in '' $ac_executable_extensions; do
3953 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
3954 as_fn_executable_p "$ac_path_GREP" || continue
3955 # Check for GNU ac_path_GREP and select it if it is found.
3956 # Check for GNU $ac_path_GREP
3957 case `"$ac_path_GREP" --version 2>&1` in
3958 *GNU*)
3959 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
3960 *)
3961 ac_count=0
3962 $as_echo_n 0123456789 >"conftest.in"
3963 while :
3964 do
3965 cat "conftest.in" "conftest.in" >"conftest.tmp"
3966 mv "conftest.tmp" "conftest.in"
3967 cp "conftest.in" "conftest.nl"
3968 $as_echo 'GREP' >> "conftest.nl"
3969 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
3970 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
3971 as_fn_arith $ac_count + 1 && ac_count=$as_val
3972 if test $ac_count -gt ${ac_path_GREP_max-0}; then
3973 # Best one so far, save it but keep looking for a better one
3974 ac_cv_path_GREP="$ac_path_GREP"
3975 ac_path_GREP_max=$ac_count
3976 fi
3977 # 10*(2^10) chars as input seems more than enough
3978 test $ac_count -gt 10 && break
3979 done
3980 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
3981 esac
3982
3983 $ac_path_GREP_found && break 3
3984 done
3985 done
3986 done
3987 IFS=$as_save_IFS
3988 if test -z "$ac_cv_path_GREP"; then
3989 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
3990 fi
3991 else
3992 ac_cv_path_GREP=$GREP
3993 fi
3994
3995 fi
3996 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
3997 $as_echo "$ac_cv_path_GREP" >&6; }
3998 GREP="$ac_cv_path_GREP"
3999
4000
4001 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
4002 $as_echo_n "checking for egrep... " >&6; }
4003 if ${ac_cv_path_EGREP+:} false; then :
4004 $as_echo_n "(cached) " >&6
4005 else
4006 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
4007 then ac_cv_path_EGREP="$GREP -E"
4008 else
4009 if test -z "$EGREP"; then
4010 ac_path_EGREP_found=false
4011 # Loop through the user's path and test for each of PROGNAME-LIST
4012 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4013 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4014 do
4015 IFS=$as_save_IFS
4016 test -z "$as_dir" && as_dir=.
4017 for ac_prog in egrep; do
4018 for ac_exec_ext in '' $ac_executable_extensions; do
4019 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
4020 as_fn_executable_p "$ac_path_EGREP" || continue
4021 # Check for GNU ac_path_EGREP and select it if it is found.
4022 # Check for GNU $ac_path_EGREP
4023 case `"$ac_path_EGREP" --version 2>&1` in
4024 *GNU*)
4025 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
4026 *)
4027 ac_count=0
4028 $as_echo_n 0123456789 >"conftest.in"
4029 while :
4030 do
4031 cat "conftest.in" "conftest.in" >"conftest.tmp"
4032 mv "conftest.tmp" "conftest.in"
4033 cp "conftest.in" "conftest.nl"
4034 $as_echo 'EGREP' >> "conftest.nl"
4035 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4036 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4037 as_fn_arith $ac_count + 1 && ac_count=$as_val
4038 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
4039 # Best one so far, save it but keep looking for a better one
4040 ac_cv_path_EGREP="$ac_path_EGREP"
4041 ac_path_EGREP_max=$ac_count
4042 fi
4043 # 10*(2^10) chars as input seems more than enough
4044 test $ac_count -gt 10 && break
4045 done
4046 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4047 esac
4048
4049 $ac_path_EGREP_found && break 3
4050 done
4051 done
4052 done
4053 IFS=$as_save_IFS
4054 if test -z "$ac_cv_path_EGREP"; then
4055 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4056 fi
4057 else
4058 ac_cv_path_EGREP=$EGREP
4059 fi
4060
4061 fi
4062 fi
4063 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
4064 $as_echo "$ac_cv_path_EGREP" >&6; }
4065 EGREP="$ac_cv_path_EGREP"
4066
4067
4068 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
4069 $as_echo_n "checking for ANSI C header files... " >&6; }
4070 if ${ac_cv_header_stdc+:} false; then :
4071 $as_echo_n "(cached) " >&6
4072 else
4073 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4074 /* end confdefs.h. */
4075 #include <stdlib.h>
4076 #include <stdarg.h>
4077 #include <string.h>
4078 #include <float.h>
4079
4080 int
4081 main ()
4082 {
4083
4084 ;
4085 return 0;
4086 }
4087 _ACEOF
4088 if ac_fn_c_try_compile "$LINENO"; then :
4089 ac_cv_header_stdc=yes
4090 else
4091 ac_cv_header_stdc=no
4092 fi
4093 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4094
4095 if test $ac_cv_header_stdc = yes; then
4096 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
4097 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4098 /* end confdefs.h. */
4099 #include <string.h>
4100
4101 _ACEOF
4102 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4103 $EGREP "memchr" >/dev/null 2>&1; then :
4104
4105 else
4106 ac_cv_header_stdc=no
4107 fi
4108 rm -f conftest*
4109
4110 fi
4111
4112 if test $ac_cv_header_stdc = yes; then
4113 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
4114 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4115 /* end confdefs.h. */
4116 #include <stdlib.h>
4117
4118 _ACEOF
4119 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4120 $EGREP "free" >/dev/null 2>&1; then :
4121
4122 else
4123 ac_cv_header_stdc=no
4124 fi
4125 rm -f conftest*
4126
4127 fi
4128
4129 if test $ac_cv_header_stdc = yes; then
4130 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
4131 if test "$cross_compiling" = yes; then :
4132 :
4133 else
4134 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4135 /* end confdefs.h. */
4136 #include <ctype.h>
4137 #include <stdlib.h>
4138 #if ((' ' & 0x0FF) == 0x020)
4139 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4140 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4141 #else
4142 # define ISLOWER(c) \
4143 (('a' <= (c) && (c) <= 'i') \
4144 || ('j' <= (c) && (c) <= 'r') \
4145 || ('s' <= (c) && (c) <= 'z'))
4146 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4147 #endif
4148
4149 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4150 int
4151 main ()
4152 {
4153 int i;
4154 for (i = 0; i < 256; i++)
4155 if (XOR (islower (i), ISLOWER (i))
4156 || toupper (i) != TOUPPER (i))
4157 return 2;
4158 return 0;
4159 }
4160 _ACEOF
4161 if ac_fn_c_try_run "$LINENO"; then :
4162
4163 else
4164 ac_cv_header_stdc=no
4165 fi
4166 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
4167 conftest.$ac_objext conftest.beam conftest.$ac_ext
4168 fi
4169
4170 fi
4171 fi
4172 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
4173 $as_echo "$ac_cv_header_stdc" >&6; }
4174 if test $ac_cv_header_stdc = yes; then
4175
4176 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
4177
4178 fi
4179
4180 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
4181 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
4182 inttypes.h stdint.h unistd.h
4183 do :
4184 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
4185 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
4186 "
4187 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
4188 cat >>confdefs.h <<_ACEOF
4189 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
4190 _ACEOF
4191
4192 fi
4193
4194 done
4195
4196
4197 for ac_header in sys/bitypes.h
4198 do :
4199 ac_fn_c_check_header_mongrel "$LINENO" "sys/bitypes.h" "ac_cv_header_sys_bitypes_h" "$ac_includes_default"
4200 if test "x$ac_cv_header_sys_bitypes_h" = xyes; then :
4201 cat >>confdefs.h <<_ACEOF
4202 #define HAVE_SYS_BITYPES_H 1
4203 _ACEOF
4204
4205 fi
4206
4207 done
4208
4209
4210 ac_fn_c_check_type "$LINENO" "int8_t" "ac_cv_type_int8_t" "$ac_includes_default
4211 #ifdef HAVE_SYS_BITYPES_H
4212 #include <sys/bitypes.h>
4213 #endif
4214 "
4215 if test "x$ac_cv_type_int8_t" = xyes; then :
4216
4217 else
4218
4219 $as_echo "#define int8_t signed char" >>confdefs.h
4220
4221 fi
4222
4223 ac_fn_c_check_type "$LINENO" "u_int8_t" "ac_cv_type_u_int8_t" "$ac_includes_default
4224 #ifdef HAVE_SYS_BITYPES_H
4225 #include <sys/bitypes.h>
4226 #endif
4227 "
4228 if test "x$ac_cv_type_u_int8_t" = xyes; then :
4229
4230 else
4231
4232 $as_echo "#define u_int8_t unsigned char" >>confdefs.h
4233
4234 fi
4235
4236 ac_fn_c_check_type "$LINENO" "int16_t" "ac_cv_type_int16_t" "$ac_includes_default"
4237 if test "x$ac_cv_type_int16_t" = xyes; then :
4238
4239 else
4240
4241 $as_echo "#define int16_t short" >>confdefs.h
4242
4243 $ac_includes_default
4244 #ifdef HAVE_SYS_BITYPES_H
4245 #include <sys/bitypes.h>
4246 #endif
4247 fi
4248
4249 ac_fn_c_check_type "$LINENO" "u_int16_t" "ac_cv_type_u_int16_t" "$ac_includes_default
4250 #ifdef HAVE_SYS_BITYPES_H
4251 #include <sys/bitypes.h>
4252 #endif
4253 "
4254 if test "x$ac_cv_type_u_int16_t" = xyes; then :
4255
4256 else
4257
4258 $as_echo "#define u_int16_t unsigned short" >>confdefs.h
4259
4260 fi
4261
4262 ac_fn_c_check_type "$LINENO" "int32_t" "ac_cv_type_int32_t" "$ac_includes_default
4263 #ifdef HAVE_SYS_BITYPES_H
4264 #include <sys/bitypes.h>
4265 #endif
4266 "
4267 if test "x$ac_cv_type_int32_t" = xyes; then :
4268
4269 else
4270
4271 $as_echo "#define int32_t int" >>confdefs.h
4272
4273 fi
4274
4275 ac_fn_c_check_type "$LINENO" "u_int32_t" "ac_cv_type_u_int32_t" "$ac_includes_default
4276 #ifdef HAVE_SYS_BITYPES_H
4277 #include <sys/bitypes.h>
4278 #endif
4279 "
4280 if test "x$ac_cv_type_u_int32_t" = xyes; then :
4281
4282 else
4283
4284 $as_echo "#define u_int32_t unsigned int" >>confdefs.h
4285
4286 fi
4287
4288 ac_fn_c_check_type "$LINENO" "int64_t" "ac_cv_type_int64_t" "$ac_includes_default
4289 #ifdef HAVE_SYS_BITYPES_H
4290 #include <sys/bitypes.h>
4291 #endif
4292 "
4293 if test "x$ac_cv_type_int64_t" = xyes; then :
4294
4295 else
4296
4297 $as_echo "#define int64_t long long" >>confdefs.h
4298
4299 fi
4300
4301 ac_fn_c_check_type "$LINENO" "u_int64_t" "ac_cv_type_u_int64_t" "$ac_includes_default
4302 #ifdef HAVE_SYS_BITYPES_H
4303 #include <sys/bitypes.h>
4304 #endif
4305 "
4306 if test "x$ac_cv_type_u_int64_t" = xyes; then :
4307
4308 else
4309
4310 $as_echo "#define u_int64_t unsigned long long" >>confdefs.h
4311
4312 fi
4313
4314
4315 #
4316 # Try to arrange for large file support.
4317 #
4318 # Check whether --enable-largefile was given.
4319 if test "${enable_largefile+set}" = set; then :
4320 enableval=$enable_largefile;
4321 fi
4322
4323 if test "$enable_largefile" != no; then
4324
4325 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
4326 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
4327 if ${ac_cv_sys_largefile_CC+:} false; then :
4328 $as_echo_n "(cached) " >&6
4329 else
4330 ac_cv_sys_largefile_CC=no
4331 if test "$GCC" != yes; then
4332 ac_save_CC=$CC
4333 while :; do
4334 # IRIX 6.2 and later do not support large files by default,
4335 # so use the C compiler's -n32 option if that helps.
4336 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4337 /* end confdefs.h. */
4338 #include <sys/types.h>
4339 /* Check that off_t can represent 2**63 - 1 correctly.
4340 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4341 since some C++ compilers masquerading as C compilers
4342 incorrectly reject 9223372036854775807. */
4343 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4344 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4345 && LARGE_OFF_T % 2147483647 == 1)
4346 ? 1 : -1];
4347 int
4348 main ()
4349 {
4350
4351 ;
4352 return 0;
4353 }
4354 _ACEOF
4355 if ac_fn_c_try_compile "$LINENO"; then :
4356 break
4357 fi
4358 rm -f core conftest.err conftest.$ac_objext
4359 CC="$CC -n32"
4360 if ac_fn_c_try_compile "$LINENO"; then :
4361 ac_cv_sys_largefile_CC=' -n32'; break
4362 fi
4363 rm -f core conftest.err conftest.$ac_objext
4364 break
4365 done
4366 CC=$ac_save_CC
4367 rm -f conftest.$ac_ext
4368 fi
4369 fi
4370 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
4371 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
4372 if test "$ac_cv_sys_largefile_CC" != no; then
4373 CC=$CC$ac_cv_sys_largefile_CC
4374 fi
4375
4376 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
4377 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
4378 if ${ac_cv_sys_file_offset_bits+:} false; then :
4379 $as_echo_n "(cached) " >&6
4380 else
4381 while :; do
4382 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4383 /* end confdefs.h. */
4384 #include <sys/types.h>
4385 /* Check that off_t can represent 2**63 - 1 correctly.
4386 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4387 since some C++ compilers masquerading as C compilers
4388 incorrectly reject 9223372036854775807. */
4389 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4390 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4391 && LARGE_OFF_T % 2147483647 == 1)
4392 ? 1 : -1];
4393 int
4394 main ()
4395 {
4396
4397 ;
4398 return 0;
4399 }
4400 _ACEOF
4401 if ac_fn_c_try_compile "$LINENO"; then :
4402 ac_cv_sys_file_offset_bits=no; break
4403 fi
4404 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4405 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4406 /* end confdefs.h. */
4407 #define _FILE_OFFSET_BITS 64
4408 #include <sys/types.h>
4409 /* Check that off_t can represent 2**63 - 1 correctly.
4410 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4411 since some C++ compilers masquerading as C compilers
4412 incorrectly reject 9223372036854775807. */
4413 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4414 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4415 && LARGE_OFF_T % 2147483647 == 1)
4416 ? 1 : -1];
4417 int
4418 main ()
4419 {
4420
4421 ;
4422 return 0;
4423 }
4424 _ACEOF
4425 if ac_fn_c_try_compile "$LINENO"; then :
4426 ac_cv_sys_file_offset_bits=64; break
4427 fi
4428 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4429 ac_cv_sys_file_offset_bits=unknown
4430 break
4431 done
4432 fi
4433 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
4434 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
4435 case $ac_cv_sys_file_offset_bits in #(
4436 no | unknown) ;;
4437 *)
4438 cat >>confdefs.h <<_ACEOF
4439 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
4440 _ACEOF
4441 ;;
4442 esac
4443 rm -rf conftest*
4444 if test $ac_cv_sys_file_offset_bits = unknown; then
4445 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
4446 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
4447 if ${ac_cv_sys_large_files+:} false; then :
4448 $as_echo_n "(cached) " >&6
4449 else
4450 while :; do
4451 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4452 /* end confdefs.h. */
4453 #include <sys/types.h>
4454 /* Check that off_t can represent 2**63 - 1 correctly.
4455 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4456 since some C++ compilers masquerading as C compilers
4457 incorrectly reject 9223372036854775807. */
4458 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4459 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4460 && LARGE_OFF_T % 2147483647 == 1)
4461 ? 1 : -1];
4462 int
4463 main ()
4464 {
4465
4466 ;
4467 return 0;
4468 }
4469 _ACEOF
4470 if ac_fn_c_try_compile "$LINENO"; then :
4471 ac_cv_sys_large_files=no; break
4472 fi
4473 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4474 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4475 /* end confdefs.h. */
4476 #define _LARGE_FILES 1
4477 #include <sys/types.h>
4478 /* Check that off_t can represent 2**63 - 1 correctly.
4479 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4480 since some C++ compilers masquerading as C compilers
4481 incorrectly reject 9223372036854775807. */
4482 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4483 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4484 && LARGE_OFF_T % 2147483647 == 1)
4485 ? 1 : -1];
4486 int
4487 main ()
4488 {
4489
4490 ;
4491 return 0;
4492 }
4493 _ACEOF
4494 if ac_fn_c_try_compile "$LINENO"; then :
4495 ac_cv_sys_large_files=1; break
4496 fi
4497 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4498 ac_cv_sys_large_files=unknown
4499 break
4500 done
4501 fi
4502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
4503 $as_echo "$ac_cv_sys_large_files" >&6; }
4504 case $ac_cv_sys_large_files in #(
4505 no | unknown) ;;
4506 *)
4507 cat >>confdefs.h <<_ACEOF
4508 #define _LARGE_FILES $ac_cv_sys_large_files
4509 _ACEOF
4510 ;;
4511 esac
4512 rm -rf conftest*
4513 fi
4514
4515
4516 fi
4517
4518 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
4519 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
4520 if ${ac_cv_sys_largefile_source+:} false; then :
4521 $as_echo_n "(cached) " >&6
4522 else
4523 while :; do
4524 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4525 /* end confdefs.h. */
4526 #include <sys/types.h> /* for off_t */
4527 #include <stdio.h>
4528 int
4529 main ()
4530 {
4531 int (*fp) (FILE *, off_t, int) = fseeko;
4532 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
4533 ;
4534 return 0;
4535 }
4536 _ACEOF
4537 if ac_fn_c_try_link "$LINENO"; then :
4538 ac_cv_sys_largefile_source=no; break
4539 fi
4540 rm -f core conftest.err conftest.$ac_objext \
4541 conftest$ac_exeext conftest.$ac_ext
4542 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4543 /* end confdefs.h. */
4544 #define _LARGEFILE_SOURCE 1
4545 #include <sys/types.h> /* for off_t */
4546 #include <stdio.h>
4547 int
4548 main ()
4549 {
4550 int (*fp) (FILE *, off_t, int) = fseeko;
4551 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
4552 ;
4553 return 0;
4554 }
4555 _ACEOF
4556 if ac_fn_c_try_link "$LINENO"; then :
4557 ac_cv_sys_largefile_source=1; break
4558 fi
4559 rm -f core conftest.err conftest.$ac_objext \
4560 conftest$ac_exeext conftest.$ac_ext
4561 ac_cv_sys_largefile_source=unknown
4562 break
4563 done
4564 fi
4565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
4566 $as_echo "$ac_cv_sys_largefile_source" >&6; }
4567 case $ac_cv_sys_largefile_source in #(
4568 no | unknown) ;;
4569 *)
4570 cat >>confdefs.h <<_ACEOF
4571 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
4572 _ACEOF
4573 ;;
4574 esac
4575 rm -rf conftest*
4576
4577 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
4578 # in glibc 2.1.3, but that breaks too many other things.
4579 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
4580 if test $ac_cv_sys_largefile_source != unknown; then
4581
4582 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
4583
4584 fi
4585
4586
4587 for ac_header in sys/ioccom.h sys/sockio.h limits.h paths.h
4588 do :
4589 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
4590 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
4591 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
4592 cat >>confdefs.h <<_ACEOF
4593 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
4594 _ACEOF
4595
4596 fi
4597
4598 done
4599
4600 for ac_header in linux/types.h
4601 do :
4602 ac_fn_c_check_header_mongrel "$LINENO" "linux/types.h" "ac_cv_header_linux_types_h" "$ac_includes_default"
4603 if test "x$ac_cv_header_linux_types_h" = xyes; then :
4604 cat >>confdefs.h <<_ACEOF
4605 #define HAVE_LINUX_TYPES_H 1
4606 _ACEOF
4607
4608 fi
4609
4610 done
4611
4612 for ac_header in linux/if_packet.h netpacket/packet.h netpacket/if_packet.h
4613 do :
4614 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
4615 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
4616 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
4617 cat >>confdefs.h <<_ACEOF
4618 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
4619 _ACEOF
4620
4621 fi
4622
4623 done
4624
4625 for ac_header in net/pfvar.h
4626 do :
4627 ac_fn_c_check_header_compile "$LINENO" "net/pfvar.h" "ac_cv_header_net_pfvar_h" "#include <sys/types.h>
4628 #include <sys/socket.h>
4629 #include <net/if.h>
4630 "
4631 if test "x$ac_cv_header_net_pfvar_h" = xyes; then :
4632 cat >>confdefs.h <<_ACEOF
4633 #define HAVE_NET_PFVAR_H 1
4634 _ACEOF
4635
4636 fi
4637
4638 done
4639
4640 if test "$ac_cv_header_net_pfvar_h" = yes; then
4641 #
4642 # Check for various PF actions.
4643 #
4644 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether net/pfvar.h defines PF_NAT through PF_NORDR" >&5
4645 $as_echo_n "checking whether net/pfvar.h defines PF_NAT through PF_NORDR... " >&6; }
4646 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4647 /* end confdefs.h. */
4648 #include <sys/types.h>
4649 #include <sys/socket.h>
4650 #include <net/if.h>
4651 #include <net/pfvar.h>
4652 int
4653 main ()
4654 {
4655 return PF_NAT+PF_NONAT+PF_BINAT+PF_NOBINAT+PF_RDR+PF_NORDR;
4656 ;
4657 return 0;
4658 }
4659 _ACEOF
4660 if ac_fn_c_try_compile "$LINENO"; then :
4661
4662 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4663 $as_echo "yes" >&6; }
4664
4665 $as_echo "#define HAVE_PF_NAT_THROUGH_PF_NORDR 1" >>confdefs.h
4666
4667
4668 else
4669 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4670 $as_echo "no" >&6; }
4671 fi
4672 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4673 fi
4674 for ac_header in netinet/if_ether.h
4675 do :
4676 ac_fn_c_check_header_compile "$LINENO" "netinet/if_ether.h" "ac_cv_header_netinet_if_ether_h" "#include <sys/types.h>
4677 #include <sys/socket.h>
4678 "
4679 if test "x$ac_cv_header_netinet_if_ether_h" = xyes; then :
4680 cat >>confdefs.h <<_ACEOF
4681 #define HAVE_NETINET_IF_ETHER_H 1
4682 _ACEOF
4683
4684 fi
4685
4686 done
4687
4688 if test "$ac_cv_header_netinet_if_ether_h" != yes; then
4689 #
4690 # The simple test didn't work.
4691 # Do we need to include <net/if.h> first?
4692 # Unset ac_cv_header_netinet_if_ether_h so we don't
4693 # treat the previous failure as a cached value and
4694 # suppress the next test.
4695 #
4696 { $as_echo "$as_me:${as_lineno-$LINENO}: Rechecking with some additional includes" >&5
4697 $as_echo "$as_me: Rechecking with some additional includes" >&6;}
4698 unset ac_cv_header_netinet_if_ether_h
4699 for ac_header in netinet/if_ether.h
4700 do :
4701 ac_fn_c_check_header_compile "$LINENO" "netinet/if_ether.h" "ac_cv_header_netinet_if_ether_h" "#include <sys/types.h>
4702 #include <sys/socket.h>
4703 #include <netinet/in.h>
4704 struct mbuf;
4705 struct rtentry;
4706 #include <net/if.h>
4707 "
4708 if test "x$ac_cv_header_netinet_if_ether_h" = xyes; then :
4709 cat >>confdefs.h <<_ACEOF
4710 #define HAVE_NETINET_IF_ETHER_H 1
4711 _ACEOF
4712
4713 fi
4714
4715 done
4716
4717 fi
4718
4719 case "$host_os" in
4720 linux*|uclinux*)
4721 for ac_header in linux/sockios.h linux/if_bonding.h
4722 do :
4723 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
4724 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "
4725 #include <sys/socket.h>
4726 #include <linux/if.h>
4727
4728 "
4729 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
4730 cat >>confdefs.h <<_ACEOF
4731 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
4732 _ACEOF
4733
4734 fi
4735
4736 done
4737
4738 ;;
4739 esac
4740
4741 if test "$GCC" = yes ; then
4742 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI ioctl definitions" >&5
4743 $as_echo_n "checking for ANSI ioctl definitions... " >&6; }
4744 if ${ac_cv_lbl_gcc_fixincludes+:} false; then :
4745 $as_echo_n "(cached) " >&6
4746 else
4747 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4748 /* end confdefs.h. */
4749 /*
4750 * This generates a "duplicate case value" when fixincludes
4751 * has not be run.
4752 */
4753 # include <sys/types.h>
4754 # include <sys/time.h>
4755 # include <sys/ioctl.h>
4756 # ifdef HAVE_SYS_IOCCOM_H
4757 # include <sys/ioccom.h>
4758 # endif
4759 int
4760 main ()
4761 {
4762 switch (0) {
4763 case _IO('A', 1):;
4764 case _IO('B', 1):;
4765 }
4766 ;
4767 return 0;
4768 }
4769 _ACEOF
4770 if ac_fn_c_try_compile "$LINENO"; then :
4771 ac_cv_lbl_gcc_fixincludes=yes
4772 else
4773 ac_cv_lbl_gcc_fixincludes=no
4774 fi
4775 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4776 fi
4777
4778 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_gcc_fixincludes" >&5
4779 $as_echo "$ac_cv_lbl_gcc_fixincludes" >&6; }
4780 if test $ac_cv_lbl_gcc_fixincludes = no ; then
4781 # Don't cache failure
4782 unset ac_cv_lbl_gcc_fixincludes
4783 as_fn_error $? "see the INSTALL for more info" "$LINENO" 5
4784 fi
4785 fi
4786
4787 for ac_func in strerror strlcpy
4788 do :
4789 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
4790 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
4791 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
4792 cat >>confdefs.h <<_ACEOF
4793 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
4794 _ACEOF
4795
4796 fi
4797 done
4798
4799
4800 needsnprintf=no
4801 for ac_func in vsnprintf snprintf
4802 do :
4803 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
4804 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
4805 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
4806 cat >>confdefs.h <<_ACEOF
4807 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
4808 _ACEOF
4809
4810 else
4811 needsnprintf=yes
4812 fi
4813 done
4814
4815 if test $needsnprintf = yes; then
4816 case " $LIBOBJS " in
4817 *" snprintf.$ac_objext "* ) ;;
4818 *) LIBOBJS="$LIBOBJS snprintf.$ac_objext"
4819 ;;
4820 esac
4821
4822 fi
4823
4824 #
4825 # Do this before checking for ether_hostton(), as it's a
4826 # "gethostbyname() -ish function".
4827 #
4828
4829 # Most operating systems have gethostbyname() in the default searched
4830 # libraries (i.e. libc):
4831 # Some OSes (eg. Solaris) place it in libnsl
4832 # Some strange OSes (SINIX) have it in libsocket:
4833 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing gethostbyname" >&5
4834 $as_echo_n "checking for library containing gethostbyname... " >&6; }
4835 if ${ac_cv_search_gethostbyname+:} false; then :
4836 $as_echo_n "(cached) " >&6
4837 else
4838 ac_func_search_save_LIBS=$LIBS
4839 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4840 /* end confdefs.h. */
4841
4842 /* Override any GCC internal prototype to avoid an error.
4843 Use char because int might match the return type of a GCC
4844 builtin and then its argument prototype would still apply. */
4845 #ifdef __cplusplus
4846 extern "C"
4847 #endif
4848 char gethostbyname ();
4849 int
4850 main ()
4851 {
4852 return gethostbyname ();
4853 ;
4854 return 0;
4855 }
4856 _ACEOF
4857 for ac_lib in '' nsl socket resolv; do
4858 if test -z "$ac_lib"; then
4859 ac_res="none required"
4860 else
4861 ac_res=-l$ac_lib
4862 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
4863 fi
4864 if ac_fn_c_try_link "$LINENO"; then :
4865 ac_cv_search_gethostbyname=$ac_res
4866 fi
4867 rm -f core conftest.err conftest.$ac_objext \
4868 conftest$ac_exeext
4869 if ${ac_cv_search_gethostbyname+:} false; then :
4870 break
4871 fi
4872 done
4873 if ${ac_cv_search_gethostbyname+:} false; then :
4874
4875 else
4876 ac_cv_search_gethostbyname=no
4877 fi
4878 rm conftest.$ac_ext
4879 LIBS=$ac_func_search_save_LIBS
4880 fi
4881 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_gethostbyname" >&5
4882 $as_echo "$ac_cv_search_gethostbyname" >&6; }
4883 ac_res=$ac_cv_search_gethostbyname
4884 if test "$ac_res" != no; then :
4885 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
4886
4887 fi
4888
4889 # Unfortunately libsocket sometimes depends on libnsl and
4890 # AC_SEARCH_LIBS isn't up to the task of handling dependencies like this.
4891 if test "$ac_cv_search_gethostbyname" = "no"
4892 then
4893 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lsocket" >&5
4894 $as_echo_n "checking for gethostbyname in -lsocket... " >&6; }
4895 if ${ac_cv_lib_socket_gethostbyname+:} false; then :
4896 $as_echo_n "(cached) " >&6
4897 else
4898 ac_check_lib_save_LIBS=$LIBS
4899 LIBS="-lsocket -lnsl $LIBS"
4900 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4901 /* end confdefs.h. */
4902
4903 /* Override any GCC internal prototype to avoid an error.
4904 Use char because int might match the return type of a GCC
4905 builtin and then its argument prototype would still apply. */
4906 #ifdef __cplusplus
4907 extern "C"
4908 #endif
4909 char gethostbyname ();
4910 int
4911 main ()
4912 {
4913 return gethostbyname ();
4914 ;
4915 return 0;
4916 }
4917 _ACEOF
4918 if ac_fn_c_try_link "$LINENO"; then :
4919 ac_cv_lib_socket_gethostbyname=yes
4920 else
4921 ac_cv_lib_socket_gethostbyname=no
4922 fi
4923 rm -f core conftest.err conftest.$ac_objext \
4924 conftest$ac_exeext conftest.$ac_ext
4925 LIBS=$ac_check_lib_save_LIBS
4926 fi
4927 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_gethostbyname" >&5
4928 $as_echo "$ac_cv_lib_socket_gethostbyname" >&6; }
4929 if test "x$ac_cv_lib_socket_gethostbyname" = xyes; then :
4930 LIBS="-lsocket -lnsl $LIBS"
4931 fi
4932
4933 fi
4934 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing socket" >&5
4935 $as_echo_n "checking for library containing socket... " >&6; }
4936 if ${ac_cv_search_socket+:} false; then :
4937 $as_echo_n "(cached) " >&6
4938 else
4939 ac_func_search_save_LIBS=$LIBS
4940 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4941 /* end confdefs.h. */
4942
4943 /* Override any GCC internal prototype to avoid an error.
4944 Use char because int might match the return type of a GCC
4945 builtin and then its argument prototype would still apply. */
4946 #ifdef __cplusplus
4947 extern "C"
4948 #endif
4949 char socket ();
4950 int
4951 main ()
4952 {
4953 return socket ();
4954 ;
4955 return 0;
4956 }
4957 _ACEOF
4958 for ac_lib in '' socket; do
4959 if test -z "$ac_lib"; then
4960 ac_res="none required"
4961 else
4962 ac_res=-l$ac_lib
4963 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
4964 fi
4965 if ac_fn_c_try_link "$LINENO"; then :
4966 ac_cv_search_socket=$ac_res
4967 fi
4968 rm -f core conftest.err conftest.$ac_objext \
4969 conftest$ac_exeext
4970 if ${ac_cv_search_socket+:} false; then :
4971 break
4972 fi
4973 done
4974 if ${ac_cv_search_socket+:} false; then :
4975
4976 else
4977 ac_cv_search_socket=no
4978 fi
4979 rm conftest.$ac_ext
4980 LIBS=$ac_func_search_save_LIBS
4981 fi
4982 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_socket" >&5
4983 $as_echo "$ac_cv_search_socket" >&6; }
4984 ac_res=$ac_cv_search_socket
4985 if test "$ac_res" != no; then :
4986 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
4987
4988 else
4989 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socket in -lsocket" >&5
4990 $as_echo_n "checking for socket in -lsocket... " >&6; }
4991 if ${ac_cv_lib_socket_socket+:} false; then :
4992 $as_echo_n "(cached) " >&6
4993 else
4994 ac_check_lib_save_LIBS=$LIBS
4995 LIBS="-lsocket -lnsl $LIBS"
4996 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4997 /* end confdefs.h. */
4998
4999 /* Override any GCC internal prototype to avoid an error.
5000 Use char because int might match the return type of a GCC
5001 builtin and then its argument prototype would still apply. */
5002 #ifdef __cplusplus
5003 extern "C"
5004 #endif
5005 char socket ();
5006 int
5007 main ()
5008 {
5009 return socket ();
5010 ;
5011 return 0;
5012 }
5013 _ACEOF
5014 if ac_fn_c_try_link "$LINENO"; then :
5015 ac_cv_lib_socket_socket=yes
5016 else
5017 ac_cv_lib_socket_socket=no
5018 fi
5019 rm -f core conftest.err conftest.$ac_objext \
5020 conftest$ac_exeext conftest.$ac_ext
5021 LIBS=$ac_check_lib_save_LIBS
5022 fi
5023 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_socket" >&5
5024 $as_echo "$ac_cv_lib_socket_socket" >&6; }
5025 if test "x$ac_cv_lib_socket_socket" = xyes; then :
5026 LIBS="-lsocket -lnsl $LIBS"
5027 fi
5028
5029 fi
5030
5031 # DLPI needs putmsg under HPUX so test for -lstr while we're at it
5032 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing putmsg" >&5
5033 $as_echo_n "checking for library containing putmsg... " >&6; }
5034 if ${ac_cv_search_putmsg+:} false; then :
5035 $as_echo_n "(cached) " >&6
5036 else
5037 ac_func_search_save_LIBS=$LIBS
5038 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5039 /* end confdefs.h. */
5040
5041 /* Override any GCC internal prototype to avoid an error.
5042 Use char because int might match the return type of a GCC
5043 builtin and then its argument prototype would still apply. */
5044 #ifdef __cplusplus
5045 extern "C"
5046 #endif
5047 char putmsg ();
5048 int
5049 main ()
5050 {
5051 return putmsg ();
5052 ;
5053 return 0;
5054 }
5055 _ACEOF
5056 for ac_lib in '' str; do
5057 if test -z "$ac_lib"; then
5058 ac_res="none required"
5059 else
5060 ac_res=-l$ac_lib
5061 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
5062 fi
5063 if ac_fn_c_try_link "$LINENO"; then :
5064 ac_cv_search_putmsg=$ac_res
5065 fi
5066 rm -f core conftest.err conftest.$ac_objext \
5067 conftest$ac_exeext
5068 if ${ac_cv_search_putmsg+:} false; then :
5069 break
5070 fi
5071 done
5072 if ${ac_cv_search_putmsg+:} false; then :
5073
5074 else
5075 ac_cv_search_putmsg=no
5076 fi
5077 rm conftest.$ac_ext
5078 LIBS=$ac_func_search_save_LIBS
5079 fi
5080 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_putmsg" >&5
5081 $as_echo "$ac_cv_search_putmsg" >&6; }
5082 ac_res=$ac_cv_search_putmsg
5083 if test "$ac_res" != no; then :
5084 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
5085
5086 fi
5087
5088
5089
5090 #
5091 # You are in a twisty little maze of UN*Xes, all different.
5092 # Some might not have ether_hostton().
5093 # Some might have it, but not declare it in any header file.
5094 # Some might have it, but declare it in <netinet/if_ether.h>.
5095 # Some might have it, but declare it in <netinet/ether.h>
5096 # (And some might have it but document it as something declared in
5097 # <netinet/ethernet.h>, although <netinet/if_ether.h> appears to work.)
5098 #
5099 # Before you is a C compiler.
5100 #
5101 for ac_func in ether_hostton
5102 do :
5103 ac_fn_c_check_func "$LINENO" "ether_hostton" "ac_cv_func_ether_hostton"
5104 if test "x$ac_cv_func_ether_hostton" = xyes; then :
5105 cat >>confdefs.h <<_ACEOF
5106 #define HAVE_ETHER_HOSTTON 1
5107 _ACEOF
5108
5109 fi
5110 done
5111
5112 if test "$ac_cv_func_ether_hostton" = yes; then
5113 #
5114 # OK, we have ether_hostton(). Do we have <netinet/if_ether.h>?
5115 #
5116 if test "$ac_cv_header_netinet_if_ether_h" = yes; then
5117 #
5118 # Yes. Does it declare ether_hostton()?
5119 #
5120 ac_fn_c_check_decl "$LINENO" "ether_hostton" "ac_cv_have_decl_ether_hostton" "
5121 #include <sys/types.h>
5122 #include <sys/socket.h>
5123 #include <netinet/in.h>
5124 #include <arpa/inet.h>
5125 struct mbuf;
5126 struct rtentry;
5127 #include <net/if.h>
5128 #include <netinet/if_ether.h>
5129
5130 "
5131 if test "x$ac_cv_have_decl_ether_hostton" = xyes; then :
5132
5133
5134 $as_echo "#define NETINET_IF_ETHER_H_DECLARES_ETHER_HOSTTON /**/" >>confdefs.h
5135
5136
5137 fi
5138
5139 fi
5140 #
5141 # Did that succeed?
5142 #
5143 if test "$ac_cv_have_decl_ether_hostton" != yes; then
5144 #
5145 # No, how about <netinet/ether.h>, as on Linux?
5146 #
5147 for ac_header in netinet/ether.h
5148 do :
5149 ac_fn_c_check_header_mongrel "$LINENO" "netinet/ether.h" "ac_cv_header_netinet_ether_h" "$ac_includes_default"
5150 if test "x$ac_cv_header_netinet_ether_h" = xyes; then :
5151 cat >>confdefs.h <<_ACEOF
5152 #define HAVE_NETINET_ETHER_H 1
5153 _ACEOF
5154
5155 fi
5156
5157 done
5158
5159 if test "$ac_cv_header_netinet_ether_h" = yes; then
5160 #
5161 # We have it - does it declare ether_hostton()?
5162 # Unset ac_cv_have_decl_ether_hostton so we don't
5163 # treat the previous failure as a cached value and
5164 # suppress the next test.
5165 #
5166 unset ac_cv_have_decl_ether_hostton
5167 ac_fn_c_check_decl "$LINENO" "ether_hostton" "ac_cv_have_decl_ether_hostton" "
5168 #include <netinet/ether.h>
5169
5170 "
5171 if test "x$ac_cv_have_decl_ether_hostton" = xyes; then :
5172
5173
5174 $as_echo "#define NETINET_ETHER_H_DECLARES_ETHER_HOSTTON /**/" >>confdefs.h
5175
5176
5177 fi
5178
5179 fi
5180 fi
5181 #
5182 # Is ether_hostton() declared?
5183 #
5184 if test "$ac_cv_have_decl_ether_hostton" != yes; then
5185 #
5186 # No, we'll have to declare it ourselves.
5187 # Do we have "struct ether_addr"?
5188 #
5189 ac_fn_c_check_type "$LINENO" "struct ether_addr" "ac_cv_type_struct_ether_addr" "
5190 #include <sys/types.h>
5191 #include <sys/socket.h>
5192 #include <netinet/in.h>
5193 #include <arpa/inet.h>
5194 struct mbuf;
5195 struct rtentry;
5196 #include <net/if.h>
5197 #include <netinet/if_ether.h>
5198
5199 "
5200 if test "x$ac_cv_type_struct_ether_addr" = xyes; then :
5201
5202 cat >>confdefs.h <<_ACEOF
5203 #define HAVE_STRUCT_ETHER_ADDR 1
5204 _ACEOF
5205
5206
5207 fi
5208
5209
5210 $as_echo "#define HAVE_DECL_ETHER_HOSTTON 0" >>confdefs.h
5211
5212 else
5213
5214 $as_echo "#define HAVE_DECL_ETHER_HOSTTON 1" >>confdefs.h
5215
5216 fi
5217 fi
5218
5219 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if --disable-protochain option is specified" >&5
5220 $as_echo_n "checking if --disable-protochain option is specified... " >&6; }
5221 # Check whether --enable-protochain was given.
5222 if test "${enable_protochain+set}" = set; then :
5223 enableval=$enable_protochain;
5224 fi
5225
5226 case "x$enable_protochain" in
5227 xyes) enable_protochain=enabled ;;
5228 xno) enable_protochain=disabled ;;
5229 x) enable_protochain=enabled ;;
5230 esac
5231
5232 if test "$enable_protochain" = "disabled"; then
5233
5234 $as_echo "#define NO_PROTOCHAIN 1" >>confdefs.h
5235
5236 fi
5237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${enable_protochain}" >&5
5238 $as_echo "${enable_protochain}" >&6; }
5239
5240 #
5241 # SITA support is mutually exclusive with native capture support;
5242 # "--with-sita" selects SITA support.
5243 #
5244
5245 # Check whether --with-sita was given.
5246 if test "${with_sita+set}" = set; then :
5247 withval=$with_sita;
5248 if test ! "x$withval" = "xno" ; then
5249
5250 $as_echo "#define SITA 1" >>confdefs.h
5251
5252 { $as_echo "$as_me:${as_lineno-$LINENO}: Enabling SITA ACN support" >&5
5253 $as_echo "$as_me: Enabling SITA ACN support" >&6;}
5254 V_PCAP=sita
5255 V_FINDALLDEVS=sita
5256 fi
5257
5258 else
5259
5260 if test -z "$with_pcap" && test "$cross_compiling" = yes; then
5261 as_fn_error $? "pcap type not determined when cross-compiling; use --with-pcap=..." "$LINENO" 5
5262 fi
5263
5264 # Check whether --with-pcap was given.
5265 if test "${with_pcap+set}" = set; then :
5266 withval=$with_pcap;
5267 fi
5268
5269 { $as_echo "$as_me:${as_lineno-$LINENO}: checking packet capture type" >&5
5270 $as_echo_n "checking packet capture type... " >&6; }
5271 if test ! -z "$with_pcap" ; then
5272 V_PCAP="$withval"
5273 elif test -r /dev/bpf -o -h /dev/bpf ; then
5274 #
5275 # Cloning BPF device.
5276 #
5277 V_PCAP=bpf
5278
5279 $as_echo "#define HAVE_CLONING_BPF 1" >>confdefs.h
5280
5281 elif test -r /dev/bpf0 ; then
5282 V_PCAP=bpf
5283 elif test -r /usr/include/net/pfilt.h ; then
5284 V_PCAP=pf
5285 elif test -r /dev/enet ; then
5286 V_PCAP=enet
5287 elif test -r /dev/nit ; then
5288 V_PCAP=snit
5289 elif test -r /usr/include/sys/net/nit.h ; then
5290 V_PCAP=nit
5291 elif test -r /usr/include/linux/socket.h ; then
5292 V_PCAP=linux
5293 elif test -r /usr/include/net/raw.h ; then
5294 V_PCAP=snoop
5295 elif test -r /usr/include/odmi.h ; then
5296 #
5297 # On AIX, the BPF devices might not yet be present - they're
5298 # created the first time libpcap runs after booting.
5299 # We check for odmi.h instead.
5300 #
5301 V_PCAP=bpf
5302 elif test -c /dev/bpf0 ; then # check again in case not readable
5303 V_PCAP=bpf
5304 elif test -r /usr/include/sys/dlpi.h ; then
5305 V_PCAP=dlpi
5306 elif test -c /dev/enet ; then # check again in case not readable
5307 V_PCAP=enet
5308 elif test -c /dev/nit ; then # check again in case not readable
5309 V_PCAP=snit
5310 else
5311 V_PCAP=null
5312 fi
5313 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $V_PCAP" >&5
5314 $as_echo "$V_PCAP" >&6; }
5315
5316 #
5317 # Do capture-mechanism-dependent tests.
5318 #
5319 case "$V_PCAP" in
5320 dlpi)
5321 #
5322 # Needed for common functions used by pcap-[dlpi,libdlpi].c
5323 #
5324 SSRC="dlpisubs.c"
5325
5326 #
5327 # Checks for some header files.
5328 #
5329 for ac_header in sys/bufmod.h sys/dlpi_ext.h
5330 do :
5331 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
5332 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
5333 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
5334 cat >>confdefs.h <<_ACEOF
5335 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
5336 _ACEOF
5337
5338 fi
5339
5340 done
5341
5342
5343 #
5344 # Checks to see if Solaris has the public libdlpi(3LIB) library.
5345 # Note: The existence of /usr/include/libdlpi.h does not mean it is the
5346 # public libdlpi(3LIB) version. Before libdlpi was made public, a
5347 # private version also existed, which did not have the same APIs.
5348 # Due to a gcc bug, the default search path for 32-bit libraries does
5349 # not include /lib, we add it explicitly here.
5350 # [http://bugs.opensolaris.org/view_bug.do?bug_id=6619485].
5351 # Also, due to the bug above applications that link to libpcap with
5352 # libdlpi will have to add "-L/lib" option to "configure".
5353 #
5354 saved_ldflags=$LDFLAGS
5355 LDFLAGS="$LIBS -L/lib"
5356 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlpi_walk in -ldlpi" >&5
5357 $as_echo_n "checking for dlpi_walk in -ldlpi... " >&6; }
5358 if ${ac_cv_lib_dlpi_dlpi_walk+:} false; then :
5359 $as_echo_n "(cached) " >&6
5360 else
5361 ac_check_lib_save_LIBS=$LIBS
5362 LIBS="-ldlpi $LIBS"
5363 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5364 /* end confdefs.h. */
5365
5366 /* Override any GCC internal prototype to avoid an error.
5367 Use char because int might match the return type of a GCC
5368 builtin and then its argument prototype would still apply. */
5369 #ifdef __cplusplus
5370 extern "C"
5371 #endif
5372 char dlpi_walk ();
5373 int
5374 main ()
5375 {
5376 return dlpi_walk ();
5377 ;
5378 return 0;
5379 }
5380 _ACEOF
5381 if ac_fn_c_try_link "$LINENO"; then :
5382 ac_cv_lib_dlpi_dlpi_walk=yes
5383 else
5384 ac_cv_lib_dlpi_dlpi_walk=no
5385 fi
5386 rm -f core conftest.err conftest.$ac_objext \
5387 conftest$ac_exeext conftest.$ac_ext
5388 LIBS=$ac_check_lib_save_LIBS
5389 fi
5390 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dlpi_dlpi_walk" >&5
5391 $as_echo "$ac_cv_lib_dlpi_dlpi_walk" >&6; }
5392 if test "x$ac_cv_lib_dlpi_dlpi_walk" = xyes; then :
5393
5394 LIBS="-ldlpi $LIBS"
5395 V_PCAP=libdlpi
5396
5397 $as_echo "#define HAVE_LIBDLPI 1" >>confdefs.h
5398
5399
5400 else
5401 V_PCAP=dlpi
5402 fi
5403
5404 LDFLAGS=$saved_ldflags
5405
5406 #
5407 # Checks whether <sys/dlpi.h> is usable, to catch weird SCO
5408 # versions of DLPI.
5409 #
5410 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/dlpi.h> is usable" >&5
5411 $as_echo_n "checking whether <sys/dlpi.h> is usable... " >&6; }
5412 if ${ac_cv_sys_dlpi_usable+:} false; then :
5413 $as_echo_n "(cached) " >&6
5414 else
5415 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5416 /* end confdefs.h. */
5417
5418 #include <sys/types.h>
5419 #include <sys/time.h>
5420 #include <sys/dlpi.h>
5421
5422 int
5423 main ()
5424 {
5425 int i = DL_PROMISC_PHYS;
5426 ;
5427 return 0;
5428 }
5429 _ACEOF
5430 if ac_fn_c_try_compile "$LINENO"; then :
5431 ac_cv_sys_dlpi_usable=yes
5432 else
5433 ac_cv_sys_dlpi_usable=no
5434 fi
5435 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5436 fi
5437
5438 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_dlpi_usable" >&5
5439 $as_echo "$ac_cv_sys_dlpi_usable" >&6; }
5440 if test $ac_cv_sys_dlpi_usable = no ; then
5441 as_fn_error $? "<sys/dlpi.h> is not usable on this system; it probably has a non-standard DLPI" "$LINENO" 5
5442 fi
5443
5444 #
5445 # Check whether we have a /dev/dlpi device or have multiple devices.
5446 #
5447 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /dev/dlpi device" >&5
5448 $as_echo_n "checking for /dev/dlpi device... " >&6; }
5449 if test -c /dev/dlpi ; then
5450 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5451 $as_echo "yes" >&6; }
5452
5453 $as_echo "#define HAVE_DEV_DLPI 1" >>confdefs.h
5454
5455 else
5456 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5457 $as_echo "no" >&6; }
5458 dir="/dev/dlpi"
5459 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $dir directory" >&5
5460 $as_echo_n "checking for $dir directory... " >&6; }
5461 if test -d $dir ; then
5462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5463 $as_echo "yes" >&6; }
5464
5465 cat >>confdefs.h <<_ACEOF
5466 #define PCAP_DEV_PREFIX "$dir"
5467 _ACEOF
5468
5469 else
5470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5471 $as_echo "no" >&6; }
5472 fi
5473 fi
5474
5475 #
5476 # This check is for Solaris with DLPI support for passive modes.
5477 # See dlpi(7P) for more details.
5478 #
5479 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if dl_passive_req_t struct exists" >&5
5480 $as_echo_n "checking if dl_passive_req_t struct exists... " >&6; }
5481 if ${ac_cv_lbl_has_dl_passive_req_t+:} false; then :
5482 $as_echo_n "(cached) " >&6
5483 else
5484 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5485 /* end confdefs.h. */
5486
5487 # include <sys/types.h>
5488 # include <sys/dlpi.h>
5489 int
5490 main ()
5491 {
5492 u_int i = sizeof(dl_passive_req_t)
5493 ;
5494 return 0;
5495 }
5496 _ACEOF
5497 if ac_fn_c_try_compile "$LINENO"; then :
5498 ac_cv_lbl_has_dl_passive_req_t=yes
5499 else
5500 ac_cv_lbl_has_dl_passive_req_t=no
5501 fi
5502 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5503 fi
5504
5505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_has_dl_passive_req_t" >&5
5506 $as_echo "$ac_cv_lbl_has_dl_passive_req_t" >&6; }
5507 if test $ac_cv_lbl_has_dl_passive_req_t = yes ; then
5508
5509 $as_echo "#define HAVE_DLPI_PASSIVE 1" >>confdefs.h
5510
5511 fi
5512 ;;
5513
5514 linux)
5515 #
5516 # Do we have the wireless extensions?
5517 #
5518 for ac_header in linux/wireless.h
5519 do :
5520 ac_fn_c_check_header_compile "$LINENO" "linux/wireless.h" "ac_cv_header_linux_wireless_h" "
5521 #include <sys/socket.h>
5522 #include <linux/if.h>
5523 #include <linux/types.h>
5524
5525 "
5526 if test "x$ac_cv_header_linux_wireless_h" = xyes; then :
5527 cat >>confdefs.h <<_ACEOF
5528 #define HAVE_LINUX_WIRELESS_H 1
5529 _ACEOF
5530
5531 fi
5532
5533 done
5534
5535
5536 #
5537 # Do we have libnl?
5538 #
5539
5540 # Check whether --with-libnl was given.
5541 if test "${with_libnl+set}" = set; then :
5542 withval=$with_libnl; with_libnl=$withval
5543 fi
5544
5545
5546 if test x$with_libnl != xno ; then
5547 have_any_nl="no"
5548
5549 incdir=-I/usr/include/libnl3
5550 libnldir=
5551 if test x$withval != x ; then
5552 libnldir=-L${withval}/lib/.libs
5553 incdir=-I${withval}/include
5554 fi
5555
5556 #
5557 # Try libnl 3.x first.
5558 #
5559 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_socket_alloc in -lnl-3" >&5
5560 $as_echo_n "checking for nl_socket_alloc in -lnl-3... " >&6; }
5561 if ${ac_cv_lib_nl_3_nl_socket_alloc+:} false; then :
5562 $as_echo_n "(cached) " >&6
5563 else
5564 ac_check_lib_save_LIBS=$LIBS
5565 LIBS="-lnl-3 ${incdir} ${libnldir} -lnl-genl-3 -lnl-3 $LIBS"
5566 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5567 /* end confdefs.h. */
5568
5569 /* Override any GCC internal prototype to avoid an error.
5570 Use char because int might match the return type of a GCC
5571 builtin and then its argument prototype would still apply. */
5572 #ifdef __cplusplus
5573 extern "C"
5574 #endif
5575 char nl_socket_alloc ();
5576 int
5577 main ()
5578 {
5579 return nl_socket_alloc ();
5580 ;
5581 return 0;
5582 }
5583 _ACEOF
5584 if ac_fn_c_try_link "$LINENO"; then :
5585 ac_cv_lib_nl_3_nl_socket_alloc=yes
5586 else
5587 ac_cv_lib_nl_3_nl_socket_alloc=no
5588 fi
5589 rm -f core conftest.err conftest.$ac_objext \
5590 conftest$ac_exeext conftest.$ac_ext
5591 LIBS=$ac_check_lib_save_LIBS
5592 fi
5593 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nl_3_nl_socket_alloc" >&5
5594 $as_echo "$ac_cv_lib_nl_3_nl_socket_alloc" >&6; }
5595 if test "x$ac_cv_lib_nl_3_nl_socket_alloc" = xyes; then :
5596
5597 #
5598 # Yes, we have libnl 3.x.
5599 #
5600 LIBS="${libnldir} -lnl-genl-3 -lnl-3 $LIBS"
5601
5602 $as_echo "#define HAVE_LIBNL 1" >>confdefs.h
5603
5604
5605 $as_echo "#define HAVE_LIBNL_3_x 1" >>confdefs.h
5606
5607
5608 $as_echo "#define HAVE_LIBNL_NLE 1" >>confdefs.h
5609
5610
5611 $as_echo "#define HAVE_LIBNL_SOCKETS 1" >>confdefs.h
5612
5613 V_INCLS="$V_INCLS ${incdir}"
5614 have_any_nl="yes"
5615
5616 fi
5617
5618
5619 if test x$have_any_nl = xno ; then
5620 #
5621 # Try libnl 2.x
5622 #
5623 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_socket_alloc in -lnl" >&5
5624 $as_echo_n "checking for nl_socket_alloc in -lnl... " >&6; }
5625 if ${ac_cv_lib_nl_nl_socket_alloc+:} false; then :
5626 $as_echo_n "(cached) " >&6
5627 else
5628 ac_check_lib_save_LIBS=$LIBS
5629 LIBS="-lnl $LIBS"
5630 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5631 /* end confdefs.h. */
5632
5633 /* Override any GCC internal prototype to avoid an error.
5634 Use char because int might match the return type of a GCC
5635 builtin and then its argument prototype would still apply. */
5636 #ifdef __cplusplus
5637 extern "C"
5638 #endif
5639 char nl_socket_alloc ();
5640 int
5641 main ()
5642 {
5643 return nl_socket_alloc ();
5644 ;
5645 return 0;
5646 }
5647 _ACEOF
5648 if ac_fn_c_try_link "$LINENO"; then :
5649 ac_cv_lib_nl_nl_socket_alloc=yes
5650 else
5651 ac_cv_lib_nl_nl_socket_alloc=no
5652 fi
5653 rm -f core conftest.err conftest.$ac_objext \
5654 conftest$ac_exeext conftest.$ac_ext
5655 LIBS=$ac_check_lib_save_LIBS
5656 fi
5657 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nl_nl_socket_alloc" >&5
5658 $as_echo "$ac_cv_lib_nl_nl_socket_alloc" >&6; }
5659 if test "x$ac_cv_lib_nl_nl_socket_alloc" = xyes; then :
5660
5661 #
5662 # Yes, we have libnl 2.x.
5663 #
5664 LIBS="${libnldir} -lnl-genl -lnl $LIBS"
5665
5666 $as_echo "#define HAVE_LIBNL 1" >>confdefs.h
5667
5668
5669 $as_echo "#define HAVE_LIBNL_2_x 1" >>confdefs.h
5670
5671
5672 $as_echo "#define HAVE_LIBNL_NLE 1" >>confdefs.h
5673
5674
5675 $as_echo "#define HAVE_LIBNL_SOCKETS 1" >>confdefs.h
5676
5677 have_any_nl="yes"
5678
5679 fi
5680
5681 fi
5682
5683 if test x$have_any_nl = xno ; then
5684 #
5685 # No, we don't; do we have libnl 1.x?
5686 #
5687 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_handle_alloc in -lnl" >&5
5688 $as_echo_n "checking for nl_handle_alloc in -lnl... " >&6; }
5689 if ${ac_cv_lib_nl_nl_handle_alloc+:} false; then :
5690 $as_echo_n "(cached) " >&6
5691 else
5692 ac_check_lib_save_LIBS=$LIBS
5693 LIBS="-lnl $LIBS"
5694 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5695 /* end confdefs.h. */
5696
5697 /* Override any GCC internal prototype to avoid an error.
5698 Use char because int might match the return type of a GCC
5699 builtin and then its argument prototype would still apply. */
5700 #ifdef __cplusplus
5701 extern "C"
5702 #endif
5703 char nl_handle_alloc ();
5704 int
5705 main ()
5706 {
5707 return nl_handle_alloc ();
5708 ;
5709 return 0;
5710 }
5711 _ACEOF
5712 if ac_fn_c_try_link "$LINENO"; then :
5713 ac_cv_lib_nl_nl_handle_alloc=yes
5714 else
5715 ac_cv_lib_nl_nl_handle_alloc=no
5716 fi
5717 rm -f core conftest.err conftest.$ac_objext \
5718 conftest$ac_exeext conftest.$ac_ext
5719 LIBS=$ac_check_lib_save_LIBS
5720 fi
5721 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nl_nl_handle_alloc" >&5
5722 $as_echo "$ac_cv_lib_nl_nl_handle_alloc" >&6; }
5723 if test "x$ac_cv_lib_nl_nl_handle_alloc" = xyes; then :
5724
5725 #
5726 # Yes.
5727 #
5728 LIBS="${libnldir} -lnl $LIBS"
5729
5730 $as_echo "#define HAVE_LIBNL 1" >>confdefs.h
5731
5732 have_any_nl="yes"
5733
5734 fi
5735
5736 fi
5737
5738 if test x$have_any_nl = xno ; then
5739 #
5740 # No, we don't have libnl at all.
5741 #
5742 if test x$with_libnl = xyes ; then
5743 as_fn_error $? "libnl support requested but libnl not found" "$LINENO" 5
5744 fi
5745 fi
5746 fi
5747
5748 for ac_header in linux/ethtool.h
5749 do :
5750 ac_fn_c_check_header_compile "$LINENO" "linux/ethtool.h" "ac_cv_header_linux_ethtool_h" "
5751 $ac_includes_default
5752 #include <linux/types.h>
5753
5754 "
5755 if test "x$ac_cv_header_linux_ethtool_h" = xyes; then :
5756 cat >>confdefs.h <<_ACEOF
5757 #define HAVE_LINUX_ETHTOOL_H 1
5758 _ACEOF
5759
5760 fi
5761
5762 done
5763
5764 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if if_packet.h has tpacket_stats defined" >&5
5765 $as_echo_n "checking if if_packet.h has tpacket_stats defined... " >&6; }
5766 if ${ac_cv_lbl_tpacket_stats+:} false; then :
5767 $as_echo_n "(cached) " >&6
5768 else
5769 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5770 /* end confdefs.h. */
5771
5772 # include <linux/if_packet.h>
5773 int
5774 main ()
5775 {
5776 struct tpacket_stats stats
5777 ;
5778 return 0;
5779 }
5780 _ACEOF
5781 if ac_fn_c_try_compile "$LINENO"; then :
5782 ac_cv_lbl_tpacket_stats=yes
5783 else
5784 ac_cv_lbl_tpacket_stats=no
5785 fi
5786 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5787 fi
5788
5789 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_tpacket_stats" >&5
5790 $as_echo "$ac_cv_lbl_tpacket_stats" >&6; }
5791 if test $ac_cv_lbl_tpacket_stats = yes; then
5792
5793 $as_echo "#define HAVE_TPACKET_STATS 1" >>confdefs.h
5794
5795 fi
5796 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if tpacket_auxdata struct has tp_vlan_tci member" >&5
5797 $as_echo_n "checking if tpacket_auxdata struct has tp_vlan_tci member... " >&6; }
5798 if ${ac_cv_lbl_linux_tpacket_auxdata_tp_vlan_tci+:} false; then :
5799 $as_echo_n "(cached) " >&6
5800 else
5801 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5802 /* end confdefs.h. */
5803
5804 # include <sys/types.h>
5805 # include <linux/if_packet.h>
5806 int
5807 main ()
5808 {
5809 u_int i = sizeof(((struct tpacket_auxdata *)0)->tp_vlan_tci)
5810 ;
5811 return 0;
5812 }
5813 _ACEOF
5814 if ac_fn_c_try_compile "$LINENO"; then :
5815 ac_cv_lbl_linux_tpacket_auxdata_tp_vlan_tci=yes
5816 else
5817 ac_cv_lbl_linux_tpacket_auxdata_tp_vlan_tci=no
5818 fi
5819 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5820 fi
5821
5822 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_linux_tpacket_auxdata_tp_vlan_tci" >&5
5823 $as_echo "$ac_cv_lbl_linux_tpacket_auxdata_tp_vlan_tci" >&6; }
5824 if test $ac_cv_lbl_linux_tpacket_auxdata_tp_vlan_tci = yes ; then
5825 HAVE_LINUX_TPACKET_AUXDATA=tp_vlan_tci
5826
5827
5828 $as_echo "#define HAVE_LINUX_TPACKET_AUXDATA_TP_VLAN_TCI 1" >>confdefs.h
5829
5830 fi
5831 ;;
5832
5833 bpf)
5834 #
5835 # Check whether we have the *BSD-style ioctls.
5836 #
5837 for ac_header in net/if_media.h
5838 do :
5839 ac_fn_c_check_header_mongrel "$LINENO" "net/if_media.h" "ac_cv_header_net_if_media_h" "$ac_includes_default"
5840 if test "x$ac_cv_header_net_if_media_h" = xyes; then :
5841 cat >>confdefs.h <<_ACEOF
5842 #define HAVE_NET_IF_MEDIA_H 1
5843 _ACEOF
5844
5845 fi
5846
5847 done
5848
5849
5850 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the system supports zerocopy BPF" >&5
5851 $as_echo_n "checking whether the system supports zerocopy BPF... " >&6; }
5852 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5853 /* end confdefs.h. */
5854 #include <sys/socket.h>
5855 #include <sys/ioctl.h>
5856 #include <net/if.h>
5857 #include <net/bpf.h>
5858 int
5859 main ()
5860 {
5861 return (BIOCROTZBUF + BPF_BUFMODE_ZBUF);
5862 ;
5863 return 0;
5864 }
5865 _ACEOF
5866 if ac_fn_c_try_compile "$LINENO"; then :
5867
5868 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5869 $as_echo "yes" >&6; }
5870
5871 $as_echo "#define HAVE_ZEROCOPY_BPF 1" >>confdefs.h
5872
5873
5874 else
5875 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5876 $as_echo "no" >&6; }
5877 fi
5878 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5879
5880 #
5881 # Check whether we have struct BPF_TIMEVAL.
5882 #
5883 ac_fn_c_check_type "$LINENO" "struct BPF_TIMEVAL" "ac_cv_type_struct_BPF_TIMEVAL" "
5884 #include <sys/types.h>
5885 #include <sys/ioctl.h>
5886 #ifdef HAVE_SYS_IOCCOM_H
5887 #include <sys/ioccom.h>
5888 #endif
5889 #include <net/bpf.h>
5890
5891 "
5892 if test "x$ac_cv_type_struct_BPF_TIMEVAL" = xyes; then :
5893
5894 cat >>confdefs.h <<_ACEOF
5895 #define HAVE_STRUCT_BPF_TIMEVAL 1
5896 _ACEOF
5897
5898
5899 fi
5900
5901 ;;
5902
5903 dag)
5904 V_DEFS="$V_DEFS -DDAG_ONLY"
5905 ;;
5906
5907 septel)
5908 V_DEFS="$V_DEFS -DSEPTEL_ONLY"
5909 ;;
5910
5911 snf)
5912 V_DEFS="$V_DEFS -DSNF_ONLY"
5913 ;;
5914
5915 null)
5916 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot determine packet capture interface" >&5
5917 $as_echo "$as_me: WARNING: cannot determine packet capture interface" >&2;}
5918 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: (see the INSTALL doc for more info)" >&5
5919 $as_echo "$as_me: WARNING: (see the INSTALL doc for more info)" >&2;}
5920 ;;
5921 esac
5922
5923 if test "$V_PCAP" = null
5924 then
5925 #
5926 # We can't capture, so we can't open any capture
5927 # devices, so we won't return any interfaces.
5928 #
5929 V_FINDALLDEVS=null
5930 else
5931 ac_fn_c_check_func "$LINENO" "getifaddrs" "ac_cv_func_getifaddrs"
5932 if test "x$ac_cv_func_getifaddrs" = xyes; then :
5933
5934 #
5935 # We have "getifaddrs()"; make sure we have <ifaddrs.h>
5936 # as well, just in case some platform is really weird.
5937 #
5938 ac_fn_c_check_header_mongrel "$LINENO" "ifaddrs.h" "ac_cv_header_ifaddrs_h" "$ac_includes_default"
5939 if test "x$ac_cv_header_ifaddrs_h" = xyes; then :
5940
5941 #
5942 # We have the header, so we use "getifaddrs()" to
5943 # get the list of interfaces.
5944 #
5945 V_FINDALLDEVS=getad
5946
5947 else
5948
5949 #
5950 # We don't have the header - give up.
5951 # XXX - we could also fall back on some other
5952 # mechanism, but, for now, this'll catch this
5953 # problem so that we can at least try to figure
5954 # out something to do on systems with "getifaddrs()"
5955 # but without "ifaddrs.h", if there is something
5956 # we can do on those systems.
5957 #
5958 as_fn_error $? "Your system has getifaddrs() but doesn't have a usable <ifaddrs.h>." "$LINENO" 5
5959
5960 fi
5961
5962
5963
5964 else
5965
5966 #
5967 # Well, we don't have "getifaddrs()", so we have to use
5968 # some other mechanism; determine what that mechanism is.
5969 #
5970 # The first thing we use is the type of capture mechanism,
5971 # which is somewhat of a proxy for the OS we're using.
5972 #
5973 case "$V_PCAP" in
5974
5975 dlpi|libdlpi)
5976 #
5977 # This might be Solaris 8 or later, with
5978 # SIOCGLIFCONF, or it might be some other OS
5979 # or some older version of Solaris, with
5980 # just SIOCGIFCONF.
5981 #
5982 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we have SIOCGLIFCONF" >&5
5983 $as_echo_n "checking whether we have SIOCGLIFCONF... " >&6; }
5984 if ${ac_cv_lbl_have_siocglifconf+:} false; then :
5985 $as_echo_n "(cached) " >&6
5986 else
5987 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5988 /* end confdefs.h. */
5989 #include <sys/param.h>
5990 #include <sys/file.h>
5991 #include <sys/ioctl.h>
5992 #include <sys/socket.h>
5993 #include <sys/sockio.h>
5994 int
5995 main ()
5996 {
5997 ioctl(0, SIOCGLIFCONF, (char *)0);
5998 ;
5999 return 0;
6000 }
6001 _ACEOF
6002 if ac_fn_c_try_compile "$LINENO"; then :
6003 ac_cv_lbl_have_siocglifconf=yes
6004 else
6005 ac_cv_lbl_have_siocglifconf=no
6006 fi
6007 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6008 fi
6009
6010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_have_siocglifconf" >&5
6011 $as_echo "$ac_cv_lbl_have_siocglifconf" >&6; }
6012 if test $ac_cv_lbl_have_siocglifconf = yes ; then
6013 V_FINDALLDEVS=glifc
6014 else
6015 V_FINDALLDEVS=gifc
6016 fi
6017 ;;
6018
6019 *)
6020 #
6021 # Assume we just have SIOCGIFCONF.
6022 # (XXX - on at least later Linux kernels, there's
6023 # another mechanism, and we should be using that
6024 # instead.)
6025 #
6026 V_FINDALLDEVS=gifc
6027 ;;
6028 esac
6029 fi
6030
6031 fi
6032
6033 fi
6034
6035
6036 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socklen_t" >&5
6037 $as_echo_n "checking for socklen_t... " >&6; }
6038 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6039 /* end confdefs.h. */
6040
6041 #include <sys/types.h>
6042 #include <sys/socket.h>
6043
6044 int
6045 main ()
6046 {
6047 socklen_t x;
6048 ;
6049 return 0;
6050 }
6051 _ACEOF
6052 if ac_fn_c_try_compile "$LINENO"; then :
6053 have_socklen_t=yes
6054 else
6055 have_socklen_t=no
6056 fi
6057 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6058 if test "x$have_socklen_t" = "xyes"; then
6059
6060 $as_echo "#define HAVE_SOCKLEN_T 1" >>confdefs.h
6061
6062 fi
6063 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_socklen_t" >&5
6064 $as_echo "$have_socklen_t" >&6; }
6065
6066 # Check whether --enable-ipv6 was given.
6067 if test "${enable_ipv6+set}" = set; then :
6068 enableval=$enable_ipv6;
6069 else
6070 enable_ipv6=ifavailable
6071 fi
6072
6073 if test "$enable_ipv6" != "no"; then
6074 ac_fn_c_check_func "$LINENO" "getaddrinfo" "ac_cv_func_getaddrinfo"
6075 if test "x$ac_cv_func_getaddrinfo" = xyes; then :
6076
6077
6078 $as_echo "#define INET6 1" >>confdefs.h
6079
6080
6081 else
6082
6083 if test "$enable_ipv6" != "ifavailable"; then
6084 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
6085 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
6086 as_fn_error $? "--enable-ipv6 was given, but getaddrinfo isn't available
6087 See \`config.log' for more details" "$LINENO" 5; }
6088 fi
6089
6090 fi
6091
6092 fi
6093
6094 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build optimizer debugging code" >&5
6095 $as_echo_n "checking whether to build optimizer debugging code... " >&6; }
6096 # Check whether --enable-optimizer-dbg was given.
6097 if test "${enable_optimizer_dbg+set}" = set; then :
6098 enableval=$enable_optimizer_dbg;
6099 fi
6100
6101 if test "$enable_optimizer_dbg" = "yes"; then
6102
6103 $as_echo "#define BDEBUG 1" >>confdefs.h
6104
6105 fi
6106 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${enable_optimizer_dbg-no}" >&5
6107 $as_echo "${enable_optimizer_dbg-no}" >&6; }
6108
6109 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build parser debugging code" >&5
6110 $as_echo_n "checking whether to build parser debugging code... " >&6; }
6111 # Check whether --enable-yydebug was given.
6112 if test "${enable_yydebug+set}" = set; then :
6113 enableval=$enable_yydebug;
6114 fi
6115
6116 if test "$enable_yydebug" = "yes"; then
6117
6118 $as_echo "#define YYDEBUG 1" >>confdefs.h
6119
6120 fi
6121 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${enable_yydebug-no}" >&5
6122 $as_echo "${enable_yydebug-no}" >&6; }
6123
6124 # Check for Endace DAG card support.
6125
6126 # Check whether --with-dag was given.
6127 if test "${with_dag+set}" = set; then :
6128 withval=$with_dag;
6129 if test "$withval" = no
6130 then
6131 # User doesn't want DAG support.
6132 want_dag=no
6133 elif test "$withval" = yes
6134 then
6135 # User wants DAG support but hasn't specified a directory.
6136 want_dag=yes
6137 else
6138 # User wants DAG support and has specified a directory, so use the provided value.
6139 want_dag=yes
6140 dag_root=$withval
6141 fi
6142
6143 else
6144
6145 if test "$V_PCAP" = dag; then
6146 # User requested DAG-only libpcap, so we'd better have
6147 # the DAG API.
6148 want_dag=yes
6149 else
6150 #
6151 # Use DAG API if present, otherwise don't
6152 #
6153 want_dag=ifpresent
6154 fi
6155
6156 fi
6157
6158
6159
6160 # Check whether --with-dag-includes was given.
6161 if test "${with_dag_includes+set}" = set; then :
6162 withval=$with_dag_includes;
6163 # User wants DAG support and has specified a header directory, so use the provided value.
6164 want_dag=yes
6165 dag_include_dir=$withval
6166
6167 fi
6168
6169
6170
6171 # Check whether --with-dag-libraries was given.
6172 if test "${with_dag_libraries+set}" = set; then :
6173 withval=$with_dag_libraries;
6174 # User wants DAG support and has specified a library directory, so use the provided value.
6175 want_dag=yes
6176 dag_lib_dir=$withval
6177
6178 fi
6179
6180
6181 ac_cv_lbl_dag_api=no
6182 if test "$want_dag" != no; then
6183
6184 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we have DAG API headers" >&5
6185 $as_echo_n "checking whether we have DAG API headers... " >&6; }
6186
6187 # If necessary, set default paths for DAG API headers and libraries.
6188 if test -z "$dag_root"; then
6189 dag_root=/usr/local
6190 fi
6191
6192 if test -z "$dag_include_dir"; then
6193 dag_include_dir="$dag_root/include"
6194 fi
6195
6196 if test -z "$dag_lib_dir"; then
6197 dag_lib_dir="$dag_root/lib"
6198 fi
6199
6200 if test -z "$dag_tools_dir"; then
6201 dag_tools_dir="$dag_root/tools"
6202 fi
6203
6204 if test -r $dag_include_dir/dagapi.h; then
6205 ac_cv_lbl_dag_api=yes
6206 fi
6207
6208 if test "$ac_cv_lbl_dag_api" = yes; then
6209 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes ($dag_include_dir)" >&5
6210 $as_echo "yes ($dag_include_dir)" >&6; }
6211
6212 V_INCLS="$V_INCLS -I$dag_include_dir"
6213
6214 if test $V_PCAP != dag ; then
6215 SSRC="$SSRC pcap-dag.c"
6216 fi
6217
6218 # See if we can find a general version string.
6219 # Don't need to save and restore LIBS to prevent -ldag being
6220 # included if there's a found-action (arg 3).
6221 saved_ldflags=$LDFLAGS
6222 LDFLAGS="-L$dag_lib_dir"
6223 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dag_attach_stream in -ldag" >&5
6224 $as_echo_n "checking for dag_attach_stream in -ldag... " >&6; }
6225 if ${ac_cv_lib_dag_dag_attach_stream+:} false; then :
6226 $as_echo_n "(cached) " >&6
6227 else
6228 ac_check_lib_save_LIBS=$LIBS
6229 LIBS="-ldag $LIBS"
6230 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6231 /* end confdefs.h. */
6232
6233 /* Override any GCC internal prototype to avoid an error.
6234 Use char because int might match the return type of a GCC
6235 builtin and then its argument prototype would still apply. */
6236 #ifdef __cplusplus
6237 extern "C"
6238 #endif
6239 char dag_attach_stream ();
6240 int
6241 main ()
6242 {
6243 return dag_attach_stream ();
6244 ;
6245 return 0;
6246 }
6247 _ACEOF
6248 if ac_fn_c_try_link "$LINENO"; then :
6249 ac_cv_lib_dag_dag_attach_stream=yes
6250 else
6251 ac_cv_lib_dag_dag_attach_stream=no
6252 fi
6253 rm -f core conftest.err conftest.$ac_objext \
6254 conftest$ac_exeext conftest.$ac_ext
6255 LIBS=$ac_check_lib_save_LIBS
6256 fi
6257 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dag_dag_attach_stream" >&5
6258 $as_echo "$ac_cv_lib_dag_dag_attach_stream" >&6; }
6259 if test "x$ac_cv_lib_dag_dag_attach_stream" = xyes; then :
6260 dag_streams="1"
6261 else
6262 dag_streams="0"
6263 fi
6264
6265 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dag_get_erf_types in -ldag" >&5
6266 $as_echo_n "checking for dag_get_erf_types in -ldag... " >&6; }
6267 if ${ac_cv_lib_dag_dag_get_erf_types+:} false; then :
6268 $as_echo_n "(cached) " >&6
6269 else
6270 ac_check_lib_save_LIBS=$LIBS
6271 LIBS="-ldag $LIBS"
6272 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6273 /* end confdefs.h. */
6274
6275 /* Override any GCC internal prototype to avoid an error.
6276 Use char because int might match the return type of a GCC
6277 builtin and then its argument prototype would still apply. */
6278 #ifdef __cplusplus
6279 extern "C"
6280 #endif
6281 char dag_get_erf_types ();
6282 int
6283 main ()
6284 {
6285 return dag_get_erf_types ();
6286 ;
6287 return 0;
6288 }
6289 _ACEOF
6290 if ac_fn_c_try_link "$LINENO"; then :
6291 ac_cv_lib_dag_dag_get_erf_types=yes
6292 else
6293 ac_cv_lib_dag_dag_get_erf_types=no
6294 fi
6295 rm -f core conftest.err conftest.$ac_objext \
6296 conftest$ac_exeext conftest.$ac_ext
6297 LIBS=$ac_check_lib_save_LIBS
6298 fi
6299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dag_dag_get_erf_types" >&5
6300 $as_echo "$ac_cv_lib_dag_dag_get_erf_types" >&6; }
6301 if test "x$ac_cv_lib_dag_dag_get_erf_types" = xyes; then :
6302
6303
6304 $as_echo "#define HAVE_DAG_GET_ERF_TYPES 1" >>confdefs.h
6305
6306 fi
6307
6308 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dag_get_stream_erf_types in -ldag" >&5
6309 $as_echo_n "checking for dag_get_stream_erf_types in -ldag... " >&6; }
6310 if ${ac_cv_lib_dag_dag_get_stream_erf_types+:} false; then :
6311 $as_echo_n "(cached) " >&6
6312 else
6313 ac_check_lib_save_LIBS=$LIBS
6314 LIBS="-ldag $LIBS"
6315 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6316 /* end confdefs.h. */
6317
6318 /* Override any GCC internal prototype to avoid an error.
6319 Use char because int might match the return type of a GCC
6320 builtin and then its argument prototype would still apply. */
6321 #ifdef __cplusplus
6322 extern "C"
6323 #endif
6324 char dag_get_stream_erf_types ();
6325 int
6326 main ()
6327 {
6328 return dag_get_stream_erf_types ();
6329 ;
6330 return 0;
6331 }
6332 _ACEOF
6333 if ac_fn_c_try_link "$LINENO"; then :
6334 ac_cv_lib_dag_dag_get_stream_erf_types=yes
6335 else
6336 ac_cv_lib_dag_dag_get_stream_erf_types=no
6337 fi
6338 rm -f core conftest.err conftest.$ac_objext \
6339 conftest$ac_exeext conftest.$ac_ext
6340 LIBS=$ac_check_lib_save_LIBS
6341 fi
6342 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dag_dag_get_stream_erf_types" >&5
6343 $as_echo "$ac_cv_lib_dag_dag_get_stream_erf_types" >&6; }
6344 if test "x$ac_cv_lib_dag_dag_get_stream_erf_types" = xyes; then :
6345
6346
6347 $as_echo "#define HAVE_DAG_GET_STREAM_ERF_TYPES 1" >>confdefs.h
6348
6349 fi
6350
6351
6352 LDFLAGS=$saved_ldflags
6353
6354 if test "$dag_streams" = 1; then
6355
6356 $as_echo "#define HAVE_DAG_STREAMS_API 1" >>confdefs.h
6357
6358 LIBS="$LIBS -ldag"
6359 LDFLAGS="$LDFLAGS -L$dag_lib_dir"
6360
6361 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for vdag_set_device_info in -lvdag" >&5
6362 $as_echo_n "checking for vdag_set_device_info in -lvdag... " >&6; }
6363 if ${ac_cv_lib_vdag_vdag_set_device_info+:} false; then :
6364 $as_echo_n "(cached) " >&6
6365 else
6366 ac_check_lib_save_LIBS=$LIBS
6367 LIBS="-lvdag $LIBS"
6368 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6369 /* end confdefs.h. */
6370
6371 /* Override any GCC internal prototype to avoid an error.
6372 Use char because int might match the return type of a GCC
6373 builtin and then its argument prototype would still apply. */
6374 #ifdef __cplusplus
6375 extern "C"
6376 #endif
6377 char vdag_set_device_info ();
6378 int
6379 main ()
6380 {
6381 return vdag_set_device_info ();
6382 ;
6383 return 0;
6384 }
6385 _ACEOF
6386 if ac_fn_c_try_link "$LINENO"; then :
6387 ac_cv_lib_vdag_vdag_set_device_info=yes
6388 else
6389 ac_cv_lib_vdag_vdag_set_device_info=no
6390 fi
6391 rm -f core conftest.err conftest.$ac_objext \
6392 conftest$ac_exeext conftest.$ac_ext
6393 LIBS=$ac_check_lib_save_LIBS
6394 fi
6395 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_vdag_vdag_set_device_info" >&5
6396 $as_echo "$ac_cv_lib_vdag_vdag_set_device_info" >&6; }
6397 if test "x$ac_cv_lib_vdag_vdag_set_device_info" = xyes; then :
6398 ac_dag_have_vdag="1"
6399 else
6400 ac_dag_have_vdag="0"
6401 fi
6402
6403 if test "$ac_dag_have_vdag" = 1; then
6404
6405 $as_echo "#define HAVE_DAG_VDAG 1" >>confdefs.h
6406
6407 LIBS="$LIBS -lpthread"
6408 fi
6409 fi
6410
6411
6412 $as_echo "#define HAVE_DAG_API 1" >>confdefs.h
6413
6414 else
6415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6416 $as_echo "no" >&6; }
6417
6418 if test "$V_PCAP" = dag; then
6419 # User requested "dag" capture type but we couldn't
6420 # find the DAG API support.
6421 as_fn_error $? "DAG support requested with --with-pcap=dag, but the DAG headers weren't found at $dag_include_dir: make sure the DAG support is installed, specify a different path or paths if necessary, or don't request DAG support" "$LINENO" 5
6422 fi
6423
6424 if test "$want_dag" = yes; then
6425 # User wanted DAG support but we couldn't find it.
6426 as_fn_error $? "DAG support requested with --with-dag, but the DAG headers weren't found at $dag_include_dir: make sure the DAG support is installed, specify a different path or paths if necessary, or don't request DAG support" "$LINENO" 5
6427 fi
6428 fi
6429 fi
6430
6431
6432 # Check whether --with-septel was given.
6433 if test "${with_septel+set}" = set; then :
6434 withval=$with_septel;
6435 if test "$withval" = no
6436 then
6437 want_septel=no
6438 elif test "$withval" = yes
6439 then
6440 want_septel=yes
6441 septel_root=
6442 else
6443 want_septel=yes
6444 septel_root=$withval
6445 fi
6446
6447 else
6448
6449 if test "$V_PCAP" = septel; then
6450 # User requested Septel-only libpcap, so we'd better have
6451 # the Septel API.
6452 want_septel=yes
6453 else
6454 #
6455 # Use Septel API if present, otherwise don't
6456 #
6457 want_septel=ifpresent
6458 fi
6459
6460 fi
6461
6462
6463 ac_cv_lbl_septel_api=no
6464 if test "$with_septel" != no; then
6465
6466 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we have Septel API headers" >&5
6467 $as_echo_n "checking whether we have Septel API headers... " >&6; }
6468
6469 # If necessary, set default paths for Septel API headers and libraries.
6470 if test -z "$septel_root"; then
6471 septel_root=$srcdir/../septel
6472 fi
6473
6474 septel_tools_dir="$septel_root"
6475 septel_include_dir="$septel_root/INC"
6476
6477 if test -r "$septel_include_dir/msg.h"; then
6478 ac_cv_lbl_septel_api=yes
6479 fi
6480
6481 if test "$ac_cv_lbl_septel_api" = yes; then
6482 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes ($septel_include_dir)" >&5
6483 $as_echo "yes ($septel_include_dir)" >&6; }
6484
6485 V_INCLS="$V_INCLS -I$septel_include_dir"
6486 ADDLOBJS="$ADDLOBJS $septel_tools_dir/asciibin.o $septel_tools_dir/bit2byte.o $septel_tools_dir/confirm.o $septel_tools_dir/fmtmsg.o $septel_tools_dir/gct_unix.o $septel_tools_dir/hqueue.o $septel_tools_dir/ident.o $septel_tools_dir/mem.o $septel_tools_dir/pack.o $septel_tools_dir/parse.o $septel_tools_dir/pool.o $septel_tools_dir/sdlsig.o $septel_tools_dir/strtonum.o $septel_tools_dir/timer.o $septel_tools_dir/trace.o"
6487 ADDLARCHIVEOBJS="$ADDLARCHIVEOBJS $septel_tools_dir/asciibin.o $septel_tools_dir/bit2byte.o $septel_tools_dir/confirm.o $septel_tools_dir/fmtmsg.o $septel_tools_dir/gct_unix.o $septel_tools_dir/hqueue.o $septel_tools_dir/ident.o $septel_tools_dir/mem.o $septel_tools_dir/pack.o $septel_tools_dir/parse.o $septel_tools_dir/pool.o $septel_tools_dir/sdlsig.o $septel_tools_dir/strtonum.o $septel_tools_dir/timer.o $septel_tools_dir/trace.o"
6488
6489 if test "$V_PCAP" != septel ; then
6490 SSRC="$SSRC pcap-septel.c"
6491 fi
6492
6493
6494 $as_echo "#define HAVE_SEPTEL_API 1" >>confdefs.h
6495
6496 else
6497 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6498 $as_echo "no" >&6; }
6499
6500 if test "$V_PCAP" = septel; then
6501 # User requested "septel" capture type but
6502 # we couldn't find the Septel API support.
6503 as_fn_error $? "Septel support requested with --with-pcap=septel, but the Septel headers weren't found at $septel_include_dir: make sure the Septel support is installed, specify a different path or paths if necessary, or don't request Septel support" "$LINENO" 5
6504 fi
6505
6506 if test "$want_septel" = yes; then
6507 # User wanted Septel support but we couldn't find it.
6508 as_fn_error $? "Septel support requested with --with-septel, but the Septel headers weren't found at $septel_include_dir: make sure the Septel support is installed, specify a different path or paths if necessary, or don't request Septel support" "$LINENO" 5
6509 fi
6510 fi
6511 fi
6512
6513 # Check for Myricom SNF support.
6514
6515 # Check whether --with-snf was given.
6516 if test "${with_snf+set}" = set; then :
6517 withval=$with_snf;
6518 if test "$withval" = no
6519 then
6520 # User explicitly doesn't want SNF
6521 want_snf=no
6522 elif test "$withval" = yes
6523 then
6524 # User wants SNF support but hasn't specified a directory.
6525 want_snf=yes
6526 else
6527 # User wants SNF support with a specified directory.
6528 want_snf=yes
6529 snf_root=$withval
6530 fi
6531
6532 else
6533
6534 if test "$V_PCAP" = snf; then
6535 # User requested Sniffer-only libpcap, so we'd better have
6536 # the Sniffer API.
6537 want_snf=yes
6538 else
6539 #
6540 # Use Sniffer API if present, otherwise don't
6541 #
6542 want_snf=ifpresent
6543 fi
6544
6545 fi
6546
6547
6548
6549 # Check whether --with-snf-includes was given.
6550 if test "${with_snf_includes+set}" = set; then :
6551 withval=$with_snf_includes;
6552 # User wants SNF with specific header directory
6553 want_snf=yes
6554 snf_include_dir=$withval
6555
6556 fi
6557
6558
6559
6560 # Check whether --with-snf-libraries was given.
6561 if test "${with_snf_libraries+set}" = set; then :
6562 withval=$with_snf_libraries;
6563 # User wants SNF with specific lib directory
6564 want_snf=yes
6565 snf_lib_dir=$withval
6566
6567 fi
6568
6569
6570 ac_cv_lbl_snf_api=no
6571 if test "$with_snf" != no; then
6572
6573 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we have Myricom Sniffer API" >&5
6574 $as_echo_n "checking whether we have Myricom Sniffer API... " >&6; }
6575
6576 # If necessary, set default paths for Sniffer headers and libraries.
6577 if test -z "$snf_root"; then
6578 snf_root=/opt/snf
6579 fi
6580
6581 if test -z "$snf_include_dir"; then
6582 snf_include_dir="$snf_root/include"
6583 fi
6584
6585 if test -z "$snf_lib_dir"; then
6586 snf_lib_dir="$snf_root/lib"
6587 fi
6588
6589 if test -f "$snf_include_dir/snf.h"; then
6590 # We found a header; make sure we can link with the library
6591 saved_ldflags=$LDFLAGS
6592 LDFLAGS="$LDFLAGS -L$snf_lib_dir"
6593 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for snf_init in -lsnf" >&5
6594 $as_echo_n "checking for snf_init in -lsnf... " >&6; }
6595 if ${ac_cv_lib_snf_snf_init+:} false; then :
6596 $as_echo_n "(cached) " >&6
6597 else
6598 ac_check_lib_save_LIBS=$LIBS
6599 LIBS="-lsnf $LIBS"
6600 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6601 /* end confdefs.h. */
6602
6603 /* Override any GCC internal prototype to avoid an error.
6604 Use char because int might match the return type of a GCC
6605 builtin and then its argument prototype would still apply. */
6606 #ifdef __cplusplus
6607 extern "C"
6608 #endif
6609 char snf_init ();
6610 int
6611 main ()
6612 {
6613 return snf_init ();
6614 ;
6615 return 0;
6616 }
6617 _ACEOF
6618 if ac_fn_c_try_link "$LINENO"; then :
6619 ac_cv_lib_snf_snf_init=yes
6620 else
6621 ac_cv_lib_snf_snf_init=no
6622 fi
6623 rm -f core conftest.err conftest.$ac_objext \
6624 conftest$ac_exeext conftest.$ac_ext
6625 LIBS=$ac_check_lib_save_LIBS
6626 fi
6627 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_snf_snf_init" >&5
6628 $as_echo "$ac_cv_lib_snf_snf_init" >&6; }
6629 if test "x$ac_cv_lib_snf_snf_init" = xyes; then :
6630 ac_cv_lbl_snf_api="yes"
6631 fi
6632
6633 LDFLAGS="$saved_ldflags"
6634 if test "$ac_cv_lbl_snf_api" = no; then
6635 as_fn_error $? "SNF API cannot correctly be linked; check config.log" "$LINENO" 5
6636 fi
6637 fi
6638
6639 if test "$ac_cv_lbl_snf_api" = yes; then
6640 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes ($snf_root)" >&5
6641 $as_echo "yes ($snf_root)" >&6; }
6642
6643 V_INCLS="$V_INCLS -I$snf_include_dir"
6644 LIBS="$LIBS -lsnf"
6645 LDFLAGS="$LDFLAGS -L$snf_lib_dir"
6646
6647 if test "$V_PCAP" != snf ; then
6648 SSRC="$SSRC pcap-snf.c"
6649 fi
6650
6651
6652 $as_echo "#define HAVE_SNF_API 1" >>confdefs.h
6653
6654 else
6655 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6656 $as_echo "no" >&6; }
6657
6658 if test "$want_snf" = yes; then
6659 # User requested "snf" capture type but
6660 # we couldn't find the Sniffer API support.
6661 as_fn_error $? "Myricom Sniffer support requested with --with-pcap=snf, but the Sniffer headers weren't found at $snf_include_dir: make sure the Sniffer support is installed, specify a different path or paths if necessary, or don't request Sniffer support" "$LINENO" 5
6662 fi
6663
6664 if test "$want_snf" = yes; then
6665 as_fn_error $? "Myricom Sniffer support requested with --with-snf, but the Sniffer headers weren't found at $snf_include_dir: make sure the Sniffer support is installed, specify a different path or paths if necessary, or don't request Sniffer support" "$LINENO" 5
6666 fi
6667 fi
6668 fi
6669
6670 # Check for Riverbed TurboCap support.
6671
6672 # Check whether --with-turbocap was given.
6673 if test "${with_turbocap+set}" = set; then :
6674 withval=$with_turbocap;
6675 if test "$withval" = no
6676 then
6677 # User explicitly doesn't want TurboCap
6678 want_turbocap=no
6679 elif test "$withval" = yes
6680 then
6681 # User wants TurboCap support but hasn't specified a directory.
6682 want_turbocap=yes
6683 else
6684 # User wants TurboCap support with a specified directory.
6685 want_turbocap=yes
6686 turbocap_root=$withval
6687 fi
6688
6689 else
6690
6691 #
6692 # Use TurboCap API if present, otherwise don't
6693 #
6694 want_turbocap=ifpresent
6695
6696 fi
6697
6698
6699 ac_cv_lbl_turbocap_api=no
6700 if test "$want_turbocap" != no; then
6701
6702 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether TurboCap is supported" >&5
6703 $as_echo_n "checking whether TurboCap is supported... " >&6; }
6704
6705 save_CFLAGS="$CFLAGS"
6706 save_LIBS="$LIBS"
6707 if test ! -z "$turbocap_root"; then
6708 TURBOCAP_CFLAGS="-I$turbocap_root/include"
6709 TURBOCAP_LIBS="-L$turbocap_root/lib"
6710 CFLAGS="$CFLAGS $TURBOCAP_CFLAGS"
6711 fi
6712
6713 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6714 /* end confdefs.h. */
6715
6716 #include <TcApi.h>
6717
6718 int
6719 main ()
6720 {
6721
6722 TC_INSTANCE a; TC_PORT b; TC_BOARD c;
6723 TC_INSTANCE i;
6724 (void)TcInstanceCreateByName("foo", &i);
6725
6726 ;
6727 return 0;
6728 }
6729 _ACEOF
6730 if ac_fn_c_try_compile "$LINENO"; then :
6731 ac_cv_lbl_turbocap_api=yes
6732 fi
6733 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6734
6735 CFLAGS="$save_CFLAGS"
6736 if test $ac_cv_lbl_turbocap_api = yes; then
6737 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6738 $as_echo "yes" >&6; }
6739
6740 SSRC="$SSRC pcap-tc.c"
6741 V_INCLS="$V_INCLS $TURBOCAP_CFLAGS"
6742 LIBS="$LIBS $TURBOCAP_LIBS -lTcApi -lpthread -lstdc++"
6743
6744
6745 $as_echo "#define HAVE_TC_API 1" >>confdefs.h
6746
6747 else
6748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6749 $as_echo "no" >&6; }
6750
6751 if test "$want_turbocap" = yes; then
6752 # User wanted Turbo support but we couldn't find it.
6753 as_fn_error $? "TurboCap support requested with --with-turbocap, but the TurboCap headers weren't found: make sure the TurboCap support is installed or don't request TurboCap support" "$LINENO" 5
6754 fi
6755 fi
6756 fi
6757
6758
6759 # Check whether --with-flex was given.
6760 if test "${with_flex+set}" = set; then :
6761 withval=$with_flex;
6762 fi
6763
6764
6765 # Check whether --with-bison was given.
6766 if test "${with_bison+set}" = set; then :
6767 withval=$with_bison;
6768 fi
6769
6770 if test "$with_flex" = no ; then
6771 V_LEX=lex
6772 else
6773 for ac_prog in flex
6774 do
6775 # Extract the first word of "$ac_prog", so it can be a program name with args.
6776 set dummy $ac_prog; ac_word=$2
6777 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6778 $as_echo_n "checking for $ac_word... " >&6; }
6779 if ${ac_cv_prog_V_LEX+:} false; then :
6780 $as_echo_n "(cached) " >&6
6781 else
6782 if test -n "$V_LEX"; then
6783 ac_cv_prog_V_LEX="$V_LEX" # Let the user override the test.
6784 else
6785 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6786 for as_dir in $PATH
6787 do
6788 IFS=$as_save_IFS
6789 test -z "$as_dir" && as_dir=.
6790 for ac_exec_ext in '' $ac_executable_extensions; do
6791 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6792 ac_cv_prog_V_LEX="$ac_prog"
6793 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6794 break 2
6795 fi
6796 done
6797 done
6798 IFS=$as_save_IFS
6799
6800 fi
6801 fi
6802 V_LEX=$ac_cv_prog_V_LEX
6803 if test -n "$V_LEX"; then
6804 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $V_LEX" >&5
6805 $as_echo "$V_LEX" >&6; }
6806 else
6807 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6808 $as_echo "no" >&6; }
6809 fi
6810
6811
6812 test -n "$V_LEX" && break
6813 done
6814 test -n "$V_LEX" || V_LEX="lex"
6815
6816 fi
6817 if test "$V_LEX" = flex ; then
6818 # The -V flag was added in 2.4
6819 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for flex 2.4 or higher" >&5
6820 $as_echo_n "checking for flex 2.4 or higher... " >&6; }
6821 if ${ac_cv_lbl_flex_v24+:} false; then :
6822 $as_echo_n "(cached) " >&6
6823 else
6824 if flex -V >/dev/null 2>&1; then
6825 ac_cv_lbl_flex_v24=yes
6826 else
6827 ac_cv_lbl_flex_v24=no
6828 fi
6829 fi
6830
6831 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_flex_v24" >&5
6832 $as_echo "$ac_cv_lbl_flex_v24" >&6; }
6833 if test $ac_cv_lbl_flex_v24 = no ; then
6834 s="2.4 or higher required"
6835 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ignoring obsolete flex executable ($s)" >&5
6836 $as_echo "$as_me: WARNING: ignoring obsolete flex executable ($s)" >&2;}
6837 V_LEX=lex
6838 fi
6839 fi
6840 if test "$with_bison" = no ; then
6841 V_YACC=yacc
6842 else
6843 for ac_prog in bison
6844 do
6845 # Extract the first word of "$ac_prog", so it can be a program name with args.
6846 set dummy $ac_prog; ac_word=$2
6847 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6848 $as_echo_n "checking for $ac_word... " >&6; }
6849 if ${ac_cv_prog_V_YACC+:} false; then :
6850 $as_echo_n "(cached) " >&6
6851 else
6852 if test -n "$V_YACC"; then
6853 ac_cv_prog_V_YACC="$V_YACC" # Let the user override the test.
6854 else
6855 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6856 for as_dir in $PATH
6857 do
6858 IFS=$as_save_IFS
6859 test -z "$as_dir" && as_dir=.
6860 for ac_exec_ext in '' $ac_executable_extensions; do
6861 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6862 ac_cv_prog_V_YACC="$ac_prog"
6863 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6864 break 2
6865 fi
6866 done
6867 done
6868 IFS=$as_save_IFS
6869
6870 fi
6871 fi
6872 V_YACC=$ac_cv_prog_V_YACC
6873 if test -n "$V_YACC"; then
6874 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $V_YACC" >&5
6875 $as_echo "$V_YACC" >&6; }
6876 else
6877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6878 $as_echo "no" >&6; }
6879 fi
6880
6881
6882 test -n "$V_YACC" && break
6883 done
6884 test -n "$V_YACC" || V_YACC="yacc"
6885
6886 fi
6887 if test "$V_YACC" = bison ; then
6888 V_YACC="$V_YACC -y"
6889 fi
6890 if test "$V_LEX" != lex -a "$V_YACC" = yacc -o "$V_LEX" = lex -a "$V_YACC" != yacc ; then
6891 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: don't have both flex and bison; reverting to lex/yacc" >&5
6892 $as_echo "$as_me: WARNING: don't have both flex and bison; reverting to lex/yacc" >&2;}
6893 V_LEX=lex
6894 V_YACC=yacc
6895 fi
6896 if test "$V_LEX" = flex -a -n "pcap_" ; then
6897 V_LEX="$V_LEX -Ppcap_"
6898 V_YACC="$V_YACC -p pcap_"
6899 else
6900
6901 $as_echo "#define NEED_YYPARSE_WRAPPER 1" >>confdefs.h
6902
6903 fi
6904 if test "$V_LEX" = lex ; then
6905 # Some versions of lex can't handle the definitions section of scanner.l .
6906 # Try lexing it and complain if it can't deal.
6907 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for capable lex" >&5
6908 $as_echo_n "checking for capable lex... " >&6; }
6909 if ${tcpdump_cv_capable_lex+:} false; then :
6910 $as_echo_n "(cached) " >&6
6911 else
6912 if lex -t scanner.l > /dev/null 2>&1; then
6913 tcpdump_cv_capable_lex=yes
6914 else
6915 tcpdump_cv_capable_lex=insufficient
6916 fi
6917 fi
6918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tcpdump_cv_capable_lex" >&5
6919 $as_echo "$tcpdump_cv_capable_lex" >&6; }
6920 if test $tcpdump_cv_capable_lex = insufficient ; then
6921 as_fn_error $? "Your operating system's lex is insufficient to compile
6922 libpcap. flex is a lex replacement that has many advantages, including
6923 being able to compile libpcap. For more information, see
6924 http://www.gnu.org/software/flex/flex.html ." "$LINENO" 5
6925 fi
6926 fi
6927
6928 #
6929 # Assume, by default, no support for shared libraries and V7/BSD convention
6930 # for man pages (file formats in section 5, miscellaneous info in section 7).
6931 # Individual cases can override this.
6932 #
6933 DYEXT="none"
6934 MAN_FILE_FORMATS=5
6935 MAN_MISC_INFO=7
6936 case "$host_os" in
6937
6938 aix*)
6939
6940 $as_echo "#define _SUN 1" >>confdefs.h
6941
6942
6943 #
6944 # AIX makes it fun to build shared and static libraries,
6945 # because they're *both* ".a" archive libraries. We
6946 # build the static library for the benefit of the traditional
6947 # scheme of building libpcap and tcpdump in subdirectories of
6948 # the same directory, with tcpdump statically linked with the
6949 # libpcap in question, but we also build a shared library as
6950 # "libpcap.shareda" and install *it*, rather than the static
6951 # library, as "libpcap.a".
6952 #
6953 DYEXT="shareda"
6954
6955 case "$V_PCAP" in
6956
6957 dlpi)
6958 #
6959 # If we're using DLPI, applications will need to
6960 # use /lib/pse.exp if present, as we use the
6961 # STREAMS routines.
6962 #
6963 pseexe="/lib/pse.exp"
6964 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $pseexe" >&5
6965 $as_echo_n "checking for $pseexe... " >&6; }
6966 if test -f $pseexe ; then
6967 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6968 $as_echo "yes" >&6; }
6969 LIBS="-I:$pseexe"
6970 fi
6971 ;;
6972
6973 bpf)
6974 #
6975 # If we're using BPF, we need "-lodm" and "-lcfg", as
6976 # we use them to load the BPF module.
6977 #
6978 LIBS="-lodm -lcfg"
6979 ;;
6980 esac
6981 ;;
6982
6983 darwin*)
6984 DYEXT="dylib"
6985 V_CCOPT="$V_CCOPT -fno-common"
6986 # Check whether --enable-universal was given.
6987 if test "${enable_universal+set}" = set; then :
6988 enableval=$enable_universal;
6989 fi
6990
6991 if test "$enable_universal" != "no"; then
6992 case "$host_os" in
6993
6994 darwin0-7.*)
6995 #
6996 # Pre-Tiger. Build only for 32-bit PowerPC; no
6997 # need for any special compiler or linker flags.
6998 #
6999 ;;
7000
7001 darwin8.0123*)
7002 #
7003 # Tiger, prior to Intel support. Build for 32-bit
7004 # PowerPC and 64-bit PowerPC, with 32-bit PowerPC
7005 # first. (I'm guessing that's what Apple does.)
7006 #
7007 V_CCOPT="$V_CCOPT -arch ppc -arch ppc64"
7008 LDFLAGS="$LDFLAGS -arch ppc -arch ppc64"
7009 ;;
7010
7011 darwin8.456*)
7012 #
7013 # Tiger, subsequent to Intel support but prior to
7014 # x86-64 support. Build for 32-bit PowerPC, 64-bit
7015 # PowerPC, and x86, with 32-bit PowerPC first.
7016 # (I'm guessing that's what Apple does.)
7017 #
7018 V_CCOPT="$V_CCOPT -arch ppc -arch ppc64 -arch i386"
7019 LDFLAGS="$LDFLAGS -arch ppc -arch ppc64 -arch i386"
7020 ;;
7021
7022 darwin8.*)
7023 #
7024 # All other Tiger, so subsequent to x86-64
7025 # support. Build for 32-bit PowerPC, 64-bit
7026 # PowerPC, x86, and x86-64, and with 32-bit PowerPC
7027 # first. (I'm guessing that's what Apple does.)
7028 #
7029 V_CCOPT="$V_CCOPT -arch ppc -arch ppc64 -arch i386 -arch x86_64"
7030 LDFLAGS="$LDFLAGS -arch ppc -arch ppc64 -arch i386 -arch x86_64"
7031 ;;
7032
7033 darwin9.*)
7034 #
7035 # Leopard. Build for 32-bit PowerPC, 64-bit
7036 # PowerPC, x86, and x86-64, with 32-bit PowerPC
7037 # first. (That's what Apple does.)
7038 #
7039 V_CCOPT="$V_CCOPT -arch ppc -arch ppc64 -arch i386 -arch x86_64"
7040 LDFLAGS="$LDFLAGS -arch ppc -arch ppc64 -arch i386 -arch x86_64"
7041 ;;
7042
7043 darwin10.*)
7044 #
7045 # Snow Leopard. Build for x86-64, x86, and
7046 # 32-bit PowerPC, with x86-64 first. (That's
7047 # what Apple does, even though Snow Leopard
7048 # doesn't run on PPC, so PPC libpcap runs under
7049 # Rosetta, and Rosetta doesn't support BPF
7050 # ioctls, so PPC programs can't do live
7051 # captures.)
7052 #
7053 V_CCOPT="$V_CCOPT -arch x86_64 -arch i386 -arch ppc"
7054 LDFLAGS="$LDFLAGS -arch x86_64 -arch i386 -arch ppc"
7055 ;;
7056
7057 darwin*)
7058 #
7059 # Post-Snow Leopard. Build for x86-64 and
7060 # x86, with x86-64 first. (That's probably what
7061 # Apple does, given that Rosetta is gone.)
7062 # XXX - update if and when Apple drops support
7063 # for 32-bit x86 code.
7064 #
7065 V_CCOPT="$V_CCOPT -arch x86_64 -arch i386"
7066 LDFLAGS="$LDFLAGS -arch x86_64 -arch i386"
7067 ;;
7068 esac
7069 fi
7070 ;;
7071
7072 hpux9*)
7073
7074 $as_echo "#define HAVE_HPUX9 1" >>confdefs.h
7075
7076
7077 #
7078 # Use System V conventions for man pages.
7079 #
7080 MAN_FILE_FORMATS=4
7081 MAN_MISC_INFO=5
7082 ;;
7083
7084 hpux10.0*)
7085
7086 #
7087 # Use System V conventions for man pages.
7088 #
7089 MAN_FILE_FORMATS=4
7090 MAN_MISC_INFO=5
7091 ;;
7092
7093 hpux10.1*)
7094
7095 #
7096 # Use System V conventions for man pages.
7097 #
7098 MAN_FILE_FORMATS=4
7099 MAN_MISC_INFO=5
7100 ;;
7101
7102 hpux*)
7103
7104 $as_echo "#define HAVE_HPUX10_20_OR_LATER 1" >>confdefs.h
7105
7106 if test "`uname -m`" = "ia64"; then
7107 DYEXT="so"
7108 else
7109 DYEXT="sl"
7110 fi
7111
7112 #
7113 # "-b" builds a shared library; "+h" sets the soname.
7114 #
7115 SHLIB_OPT="-b"
7116 SONAME_OPT="+h"
7117
7118 #
7119 # Use System V conventions for man pages.
7120 #
7121 MAN_FILE_FORMATS=4
7122 MAN_MISC_INFO=5
7123 ;;
7124
7125 irix*)
7126 #
7127 # Use System V conventions for man pages.
7128 #
7129 MAN_FILE_FORMATS=4
7130 MAN_MISC_INFO=5
7131 ;;
7132
7133 linux*|freebsd*|netbsd*|openbsd*|dragonfly*|kfreebsd*|gnu*)
7134 DYEXT="so"
7135
7136 #
7137 # Compiler assumed to be GCC; run-time linker may require a -R
7138 # flag.
7139 #
7140 if test "$libdir" != "/usr/lib"; then
7141 V_RFLAGS=-Wl,-R$libdir
7142 fi
7143 ;;
7144
7145 osf*)
7146 DYEXT="so"
7147
7148 #
7149 # Use System V conventions for man pages.
7150 #
7151 MAN_FILE_FORMATS=4
7152 MAN_MISC_INFO=5
7153 ;;
7154
7155 sinix*)
7156 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if SINIX compiler defines sinix" >&5
7157 $as_echo_n "checking if SINIX compiler defines sinix... " >&6; }
7158 if ${ac_cv_cc_sinix_defined+:} false; then :
7159 $as_echo_n "(cached) " >&6
7160 else
7161 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7162 /* end confdefs.h. */
7163
7164 int
7165 main ()
7166 {
7167 int i = sinix;
7168 ;
7169 return 0;
7170 }
7171 _ACEOF
7172 if ac_fn_c_try_compile "$LINENO"; then :
7173 ac_cv_cc_sinix_defined=yes
7174 else
7175 ac_cv_cc_sinix_defined=no
7176 fi
7177 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7178 fi
7179
7180 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cc_sinix_defined" >&5
7181 $as_echo "$ac_cv_cc_sinix_defined" >&6; }
7182 if test $ac_cv_cc_sinix_defined = no ; then
7183
7184 $as_echo "#define sinix 1" >>confdefs.h
7185
7186 fi
7187 ;;
7188
7189 solaris*)
7190
7191 $as_echo "#define HAVE_SOLARIS 1" >>confdefs.h
7192
7193
7194 DYEXT="so"
7195 #
7196 # Use System V conventions for man pages.
7197 #
7198 MAN_FILE_FORMATS=4
7199 MAN_MISC_INFO=5
7200 ;;
7201 esac
7202
7203 # Check whether --enable-shared was given.
7204 if test "${enable_shared+set}" = set; then :
7205 enableval=$enable_shared;
7206 fi
7207
7208 test "x$enable_shared" = "xno" && DYEXT="none"
7209
7210 if test -n "$ac_tool_prefix"; then
7211 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
7212 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
7213 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7214 $as_echo_n "checking for $ac_word... " >&6; }
7215 if ${ac_cv_prog_RANLIB+:} false; then :
7216 $as_echo_n "(cached) " >&6
7217 else
7218 if test -n "$RANLIB"; then
7219 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
7220 else
7221 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7222 for as_dir in $PATH
7223 do
7224 IFS=$as_save_IFS
7225 test -z "$as_dir" && as_dir=.
7226 for ac_exec_ext in '' $ac_executable_extensions; do
7227 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7228 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
7229 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7230 break 2
7231 fi
7232 done
7233 done
7234 IFS=$as_save_IFS
7235
7236 fi
7237 fi
7238 RANLIB=$ac_cv_prog_RANLIB
7239 if test -n "$RANLIB"; then
7240 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
7241 $as_echo "$RANLIB" >&6; }
7242 else
7243 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7244 $as_echo "no" >&6; }
7245 fi
7246
7247
7248 fi
7249 if test -z "$ac_cv_prog_RANLIB"; then
7250 ac_ct_RANLIB=$RANLIB
7251 # Extract the first word of "ranlib", so it can be a program name with args.
7252 set dummy ranlib; ac_word=$2
7253 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7254 $as_echo_n "checking for $ac_word... " >&6; }
7255 if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
7256 $as_echo_n "(cached) " >&6
7257 else
7258 if test -n "$ac_ct_RANLIB"; then
7259 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
7260 else
7261 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7262 for as_dir in $PATH
7263 do
7264 IFS=$as_save_IFS
7265 test -z "$as_dir" && as_dir=.
7266 for ac_exec_ext in '' $ac_executable_extensions; do
7267 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7268 ac_cv_prog_ac_ct_RANLIB="ranlib"
7269 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7270 break 2
7271 fi
7272 done
7273 done
7274 IFS=$as_save_IFS
7275
7276 fi
7277 fi
7278 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
7279 if test -n "$ac_ct_RANLIB"; then
7280 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
7281 $as_echo "$ac_ct_RANLIB" >&6; }
7282 else
7283 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7284 $as_echo "no" >&6; }
7285 fi
7286
7287 if test "x$ac_ct_RANLIB" = x; then
7288 RANLIB=":"
7289 else
7290 case $cross_compiling:$ac_tool_warned in
7291 yes:)
7292 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7293 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7294 ac_tool_warned=yes ;;
7295 esac
7296 RANLIB=$ac_ct_RANLIB
7297 fi
7298 else
7299 RANLIB="$ac_cv_prog_RANLIB"
7300 fi
7301
7302 if test -n "$ac_tool_prefix"; then
7303 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
7304 set dummy ${ac_tool_prefix}ar; ac_word=$2
7305 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7306 $as_echo_n "checking for $ac_word... " >&6; }
7307 if ${ac_cv_prog_AR+:} false; then :
7308 $as_echo_n "(cached) " >&6
7309 else
7310 if test -n "$AR"; then
7311 ac_cv_prog_AR="$AR" # Let the user override the test.
7312 else
7313 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7314 for as_dir in $PATH
7315 do
7316 IFS=$as_save_IFS
7317 test -z "$as_dir" && as_dir=.
7318 for ac_exec_ext in '' $ac_executable_extensions; do
7319 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7320 ac_cv_prog_AR="${ac_tool_prefix}ar"
7321 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7322 break 2
7323 fi
7324 done
7325 done
7326 IFS=$as_save_IFS
7327
7328 fi
7329 fi
7330 AR=$ac_cv_prog_AR
7331 if test -n "$AR"; then
7332 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
7333 $as_echo "$AR" >&6; }
7334 else
7335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7336 $as_echo "no" >&6; }
7337 fi
7338
7339
7340 fi
7341 if test -z "$ac_cv_prog_AR"; then
7342 ac_ct_AR=$AR
7343 # Extract the first word of "ar", so it can be a program name with args.
7344 set dummy ar; ac_word=$2
7345 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7346 $as_echo_n "checking for $ac_word... " >&6; }
7347 if ${ac_cv_prog_ac_ct_AR+:} false; then :
7348 $as_echo_n "(cached) " >&6
7349 else
7350 if test -n "$ac_ct_AR"; then
7351 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
7352 else
7353 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7354 for as_dir in $PATH
7355 do
7356 IFS=$as_save_IFS
7357 test -z "$as_dir" && as_dir=.
7358 for ac_exec_ext in '' $ac_executable_extensions; do
7359 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7360 ac_cv_prog_ac_ct_AR="ar"
7361 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7362 break 2
7363 fi
7364 done
7365 done
7366 IFS=$as_save_IFS
7367
7368 fi
7369 fi
7370 ac_ct_AR=$ac_cv_prog_ac_ct_AR
7371 if test -n "$ac_ct_AR"; then
7372 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
7373 $as_echo "$ac_ct_AR" >&6; }
7374 else
7375 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7376 $as_echo "no" >&6; }
7377 fi
7378
7379 if test "x$ac_ct_AR" = x; then
7380 AR=""
7381 else
7382 case $cross_compiling:$ac_tool_warned in
7383 yes:)
7384 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7385 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7386 ac_tool_warned=yes ;;
7387 esac
7388 AR=$ac_ct_AR
7389 fi
7390 else
7391 AR="$ac_cv_prog_AR"
7392 fi
7393
7394
7395 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
7396 $as_echo_n "checking whether ln -s works... " >&6; }
7397 LN_S=$as_ln_s
7398 if test "$LN_S" = "ln -s"; then
7399 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7400 $as_echo "yes" >&6; }
7401 else
7402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
7403 $as_echo "no, using $LN_S" >&6; }
7404 fi
7405
7406
7407
7408 rm -f os-proto.h
7409 if test "${LBL_CFLAGS+set}" = set; then
7410 V_CCOPT="$V_CCOPT ${LBL_CFLAGS}"
7411 fi
7412 if test -f .devel ; then
7413 #
7414 # Skip all the warning option stuff on some compilers.
7415 #
7416 if test "$ac_lbl_cc_dont_try_gcc_dashW" != yes; then
7417
7418 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler fails when given an unknown warning option" >&5
7419 $as_echo_n "checking whether the compiler fails when given an unknown warning option... " >&6; }
7420 save_CFLAGS="$CFLAGS"
7421 CFLAGS="$CFLAGS -Wxyzzy-this-will-never-succeed-xyzzy"
7422 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7423 /* end confdefs.h. */
7424
7425 int
7426 main ()
7427 {
7428 return 0
7429 ;
7430 return 0;
7431 }
7432 _ACEOF
7433 if ac_fn_c_try_compile "$LINENO"; then :
7434
7435 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7436 $as_echo "no" >&6; }
7437 #
7438 # We're assuming this is clang, where
7439 # -Werror=unknown-warning-option is the appropriate
7440 # option to force the compiler to fail.
7441 #
7442 ac_lbl_unknown_warning_option_error="-Werror=unknown-warning-option"
7443
7444 else
7445
7446 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7447 $as_echo "yes" >&6; }
7448
7449 fi
7450 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7451 CFLAGS="$save_CFLAGS"
7452
7453
7454 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports the -Wall option" >&5
7455 $as_echo_n "checking whether the compiler supports the -Wall option... " >&6; }
7456 save_CFLAGS="$CFLAGS"
7457 CFLAGS="$CFLAGS $ac_lbl_unknown_warning_option_error -Wall"
7458 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7459 /* end confdefs.h. */
7460
7461 int
7462 main ()
7463 {
7464 return 0
7465 ;
7466 return 0;
7467 }
7468 _ACEOF
7469 if ac_fn_c_try_compile "$LINENO"; then :
7470
7471 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7472 $as_echo "yes" >&6; }
7473 CFLAGS="$save_CFLAGS"
7474 V_CCOPT="$V_CCOPT -Wall"
7475
7476 else
7477
7478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7479 $as_echo "no" >&6; }
7480 CFLAGS="$save_CFLAGS"
7481
7482 fi
7483 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7484
7485
7486 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports the -Wmissing-prototypes option" >&5
7487 $as_echo_n "checking whether the compiler supports the -Wmissing-prototypes option... " >&6; }
7488 save_CFLAGS="$CFLAGS"
7489 CFLAGS="$CFLAGS $ac_lbl_unknown_warning_option_error -Wmissing-prototypes"
7490 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7491 /* end confdefs.h. */
7492
7493 int
7494 main ()
7495 {
7496 return 0
7497 ;
7498 return 0;
7499 }
7500 _ACEOF
7501 if ac_fn_c_try_compile "$LINENO"; then :
7502
7503 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7504 $as_echo "yes" >&6; }
7505 CFLAGS="$save_CFLAGS"
7506 V_CCOPT="$V_CCOPT -Wmissing-prototypes"
7507
7508 else
7509
7510 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7511 $as_echo "no" >&6; }
7512 CFLAGS="$save_CFLAGS"
7513
7514 fi
7515 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7516
7517
7518 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports the -Wstrict-prototypes option" >&5
7519 $as_echo_n "checking whether the compiler supports the -Wstrict-prototypes option... " >&6; }
7520 save_CFLAGS="$CFLAGS"
7521 CFLAGS="$CFLAGS $ac_lbl_unknown_warning_option_error -Wstrict-prototypes"
7522 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7523 /* end confdefs.h. */
7524
7525 int
7526 main ()
7527 {
7528 return 0
7529 ;
7530 return 0;
7531 }
7532 _ACEOF
7533 if ac_fn_c_try_compile "$LINENO"; then :
7534
7535 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7536 $as_echo "yes" >&6; }
7537 CFLAGS="$save_CFLAGS"
7538 V_CCOPT="$V_CCOPT -Wstrict-prototypes"
7539
7540 else
7541
7542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7543 $as_echo "no" >&6; }
7544 CFLAGS="$save_CFLAGS"
7545
7546 fi
7547 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7548
7549
7550 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports the -Wdeclaration-after-statement option" >&5
7551 $as_echo_n "checking whether the compiler supports the -Wdeclaration-after-statement option... " >&6; }
7552 save_CFLAGS="$CFLAGS"
7553 CFLAGS="$CFLAGS $ac_lbl_unknown_warning_option_error -Wdeclaration-after-statement"
7554 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7555 /* end confdefs.h. */
7556
7557 int
7558 main ()
7559 {
7560 return 0
7561 ;
7562 return 0;
7563 }
7564 _ACEOF
7565 if ac_fn_c_try_compile "$LINENO"; then :
7566
7567 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7568 $as_echo "yes" >&6; }
7569 CFLAGS="$save_CFLAGS"
7570 V_CCOPT="$V_CCOPT -Wdeclaration-after-statement"
7571
7572 else
7573
7574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7575 $as_echo "no" >&6; }
7576 CFLAGS="$save_CFLAGS"
7577
7578 fi
7579 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7580
7581 fi
7582
7583 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports generating dependencies" >&5
7584 $as_echo_n "checking whether the compiler supports generating dependencies... " >&6; }
7585 if test "$GCC" = yes ; then
7586 #
7587 # GCC, or a compiler deemed to be GCC by AC_PROG_CC (even
7588 # though it's not); we assume that, in this case, the flag
7589 # would be -M.
7590 #
7591 ac_lbl_dependency_flag="-M"
7592 else
7593 #
7594 # Not GCC or a compiler deemed to be GCC; what platform is
7595 # this? (We're assuming that if the compiler isn't GCC
7596 # it's the compiler from the vendor of the OS; that won't
7597 # necessarily be true for x86 platforms, where it might be
7598 # the Intel C compiler.)
7599 #
7600 case "$host_os" in
7601
7602 irix*|osf*|darwin*)
7603 #
7604 # MIPS C for IRIX, DEC C, and clang all use -M.
7605 #
7606 ac_lbl_dependency_flag="-M"
7607 ;;
7608
7609 solaris*)
7610 #
7611 # Sun C uses -xM.
7612 #
7613 ac_lbl_dependency_flag="-xM"
7614 ;;
7615
7616 hpux*)
7617 #
7618 # HP's older C compilers don't support this.
7619 # HP's newer C compilers support this with
7620 # either +M or +Make; the older compilers
7621 # interpret +M as something completely
7622 # different, so we use +Make so we don't
7623 # think it works with the older compilers.
7624 #
7625 ac_lbl_dependency_flag="+Make"
7626 ;;
7627
7628 *)
7629 #
7630 # Not one of the above; assume no support for
7631 # generating dependencies.
7632 #
7633 ac_lbl_dependency_flag=""
7634 ;;
7635 esac
7636 fi
7637
7638 #
7639 # Is ac_lbl_dependency_flag defined and, if so, does the compiler
7640 # complain about it?
7641 #
7642 # Note: clang doesn't seem to exit with an error status when handed
7643 # an unknown non-warning error, even if you pass it
7644 # -Werror=unknown-warning-option. However, it always supports
7645 # -M, so the fact that this test always succeeds with clang
7646 # isn't an issue.
7647 #
7648 if test ! -z "$ac_lbl_dependency_flag"; then
7649 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7650 /* end confdefs.h. */
7651 int main(void) { return 0; }
7652 _ACEOF
7653 echo "$CC" $ac_lbl_dependency_flag conftest.c >&5
7654 if "$CC" $ac_lbl_dependency_flag conftest.c >/dev/null 2>&1; then
7655 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, with $ac_lbl_dependency_flag" >&5
7656 $as_echo "yes, with $ac_lbl_dependency_flag" >&6; }
7657 DEPENDENCY_CFLAG="$ac_lbl_dependency_flag"
7658 MKDEP='${srcdir}/mkdep'
7659 else
7660 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7661 $as_echo "no" >&6; }
7662 #
7663 # We can't run mkdep, so have "make depend" do
7664 # nothing.
7665 #
7666 MKDEP=:
7667 fi
7668 rm -rf conftest*
7669 else
7670 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7671 $as_echo "no" >&6; }
7672 #
7673 # We can't run mkdep, so have "make depend" do
7674 # nothing.
7675 #
7676 MKDEP=:
7677 fi
7678
7679
7680
7681 #
7682 # We used to set -n32 for IRIX 6 when not using GCC (presumed
7683 # to mean that we're using MIPS C or MIPSpro C); it specified
7684 # the "new" faster 32-bit ABI, introduced in IRIX 6.2. I'm
7685 # not sure why that would be something to do *only* with a
7686 # .devel file; why should the ABI for which we produce code
7687 # depend on .devel?
7688 #
7689 os=`echo $host_os | sed -e 's/\([0-9][0-9]*\)[^0-9].*$/\1/'`
7690 name="lbl/os-$os.h"
7691 if test -f $name ; then
7692 ln -s $name os-proto.h
7693
7694 $as_echo "#define HAVE_OS_PROTO_H 1" >>confdefs.h
7695
7696 else
7697 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: can't find $name" >&5
7698 $as_echo "$as_me: WARNING: can't find $name" >&2;}
7699 fi
7700 fi
7701
7702 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sockaddr struct has the sa_len member" >&5
7703 $as_echo_n "checking if sockaddr struct has the sa_len member... " >&6; }
7704 if ${ac_cv_lbl_sockaddr_has_sa_len+:} false; then :
7705 $as_echo_n "(cached) " >&6
7706 else
7707 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7708 /* end confdefs.h. */
7709
7710 # include <sys/types.h>
7711 # include <sys/socket.h>
7712 int
7713 main ()
7714 {
7715 u_int i = sizeof(((struct sockaddr *)0)->sa_len)
7716 ;
7717 return 0;
7718 }
7719 _ACEOF
7720 if ac_fn_c_try_compile "$LINENO"; then :
7721 ac_cv_lbl_sockaddr_has_sa_len=yes
7722 else
7723 ac_cv_lbl_sockaddr_has_sa_len=no
7724 fi
7725 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7726 fi
7727
7728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_sockaddr_has_sa_len" >&5
7729 $as_echo "$ac_cv_lbl_sockaddr_has_sa_len" >&6; }
7730 if test $ac_cv_lbl_sockaddr_has_sa_len = yes ; then
7731
7732 $as_echo "#define HAVE_SOCKADDR_SA_LEN 1" >>confdefs.h
7733
7734 fi
7735
7736 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sockaddr_storage struct exists" >&5
7737 $as_echo_n "checking if sockaddr_storage struct exists... " >&6; }
7738 if ${ac_cv_lbl_has_sockaddr_storage+:} false; then :
7739 $as_echo_n "(cached) " >&6
7740 else
7741 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7742 /* end confdefs.h. */
7743
7744 # include <sys/types.h>
7745 # include <sys/socket.h>
7746 int
7747 main ()
7748 {
7749 u_int i = sizeof (struct sockaddr_storage)
7750 ;
7751 return 0;
7752 }
7753 _ACEOF
7754 if ac_fn_c_try_compile "$LINENO"; then :
7755 ac_cv_lbl_has_sockaddr_storage=yes
7756 else
7757 ac_cv_lbl_has_sockaddr_storage=no
7758 fi
7759 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7760 fi
7761
7762 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_has_sockaddr_storage" >&5
7763 $as_echo "$ac_cv_lbl_has_sockaddr_storage" >&6; }
7764 if test $ac_cv_lbl_has_sockaddr_storage = yes ; then
7765
7766 $as_echo "#define HAVE_SOCKADDR_STORAGE 1" >>confdefs.h
7767
7768 fi
7769
7770 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if dl_hp_ppa_info_t struct has dl_module_id_1 member" >&5
7771 $as_echo_n "checking if dl_hp_ppa_info_t struct has dl_module_id_1 member... " >&6; }
7772 if ${ac_cv_lbl_dl_hp_ppa_info_t_has_dl_module_id_1+:} false; then :
7773 $as_echo_n "(cached) " >&6
7774 else
7775 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7776 /* end confdefs.h. */
7777
7778 # include <sys/types.h>
7779 # include <sys/dlpi.h>
7780 # include <sys/dlpi_ext.h>
7781 int
7782 main ()
7783 {
7784 u_int i = sizeof(((dl_hp_ppa_info_t *)0)->dl_module_id_1)
7785 ;
7786 return 0;
7787 }
7788 _ACEOF
7789 if ac_fn_c_try_compile "$LINENO"; then :
7790 ac_cv_lbl_dl_hp_ppa_info_t_has_dl_module_id_1=yes
7791 else
7792 ac_cv_lbl_dl_hp_ppa_info_t_has_dl_module_id_1=no
7793 fi
7794 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7795 fi
7796
7797 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_dl_hp_ppa_info_t_has_dl_module_id_1" >&5
7798 $as_echo "$ac_cv_lbl_dl_hp_ppa_info_t_has_dl_module_id_1" >&6; }
7799 if test $ac_cv_lbl_dl_hp_ppa_info_t_has_dl_module_id_1 = yes ; then
7800
7801 $as_echo "#define HAVE_HP_PPA_INFO_T_DL_MODULE_ID_1 1" >>confdefs.h
7802
7803 fi
7804
7805 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if unaligned accesses fail" >&5
7806 $as_echo_n "checking if unaligned accesses fail... " >&6; }
7807 if ${ac_cv_lbl_unaligned_fail+:} false; then :
7808 $as_echo_n "(cached) " >&6
7809 else
7810 case "$host_cpu" in
7811
7812 #
7813 # These are CPU types where:
7814 #
7815 # the CPU faults on an unaligned access, but at least some
7816 # OSes that support that CPU catch the fault and simulate
7817 # the unaligned access (e.g., Alpha/{Digital,Tru64} UNIX) -
7818 # the simulation is slow, so we don't want to use it;
7819 #
7820 # the CPU, I infer (from the old
7821 #
7822 # XXX: should also check that they don't do weird things (like on arm)
7823 #
7824 # comment) doesn't fault on unaligned accesses, but doesn't
7825 # do a normal unaligned fetch, either (e.g., presumably, ARM);
7826 #
7827 # for whatever reason, the test program doesn't work
7828 # (this has been claimed to be the case for several of those
7829 # CPUs - I don't know what the problem is; the problem
7830 # was reported as "the test program dumps core" for SuperH,
7831 # but that's what the test program is *supposed* to do -
7832 # it dumps core before it writes anything, so the test
7833 # for an empty output file should find an empty output
7834 # file and conclude that unaligned accesses don't work).
7835 #
7836 # This run-time test won't work if you're cross-compiling, so
7837 # in order to support cross-compiling for a particular CPU,
7838 # we have to wire in the list of CPU types anyway, as far as
7839 # I know, so perhaps we should just have a set of CPUs on
7840 # which we know it doesn't work, a set of CPUs on which we
7841 # know it does work, and have the script just fail on other
7842 # cpu types and update it when such a failure occurs.
7843 #
7844 alpha*|arm*|bfin*|hp*|mips*|sh*|sparc*|ia64|nv1)
7845 ac_cv_lbl_unaligned_fail=yes
7846 ;;
7847
7848 *)
7849 cat >conftest.c <<EOF
7850 # include <sys/types.h>
7851 # include <sys/wait.h>
7852 # include <stdio.h>
7853 unsigned char a[5] = { 1, 2, 3, 4, 5 };
7854 main() {
7855 unsigned int i;
7856 pid_t pid;
7857 int status;
7858 /* avoid "core dumped" message */
7859 pid = fork();
7860 if (pid < 0)
7861 exit(2);
7862 if (pid > 0) {
7863 /* parent */
7864 pid = waitpid(pid, &status, 0);
7865 if (pid < 0)
7866 exit(3);
7867 exit(!WIFEXITED(status));
7868 }
7869 /* child */
7870 i = *(unsigned int *)&a[1];
7871 printf("%d\n", i);
7872 exit(0);
7873 }
7874 EOF
7875 ${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS \
7876 conftest.c $LIBS >/dev/null 2>&1
7877 if test ! -x conftest ; then
7878 ac_cv_lbl_unaligned_fail=yes
7879 else
7880 ./conftest >conftest.out
7881 if test ! -s conftest.out ; then
7882 ac_cv_lbl_unaligned_fail=yes
7883 else
7884 ac_cv_lbl_unaligned_fail=no
7885 fi
7886 fi
7887 rm -f -r conftest* core core.conftest
7888 ;;
7889 esac
7890 fi
7891
7892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_unaligned_fail" >&5
7893 $as_echo "$ac_cv_lbl_unaligned_fail" >&6; }
7894 if test $ac_cv_lbl_unaligned_fail = yes ; then
7895
7896 $as_echo "#define LBL_ALIGN 1" >>confdefs.h
7897
7898 fi
7899
7900 #
7901 # Makefile.in includes rules to generate version.h, so we assume
7902 # that it will be generated if autoconf is used.
7903 #
7904
7905 $as_echo "#define HAVE_VERSION_H 1" >>confdefs.h
7906
7907
7908 rm -f net
7909 ln -s ${srcdir}/bpf/net net
7910
7911
7912
7913
7914
7915
7916
7917
7918
7919
7920
7921
7922
7923
7924
7925
7926
7927
7928
7929 # Check whether --enable-usb was given.
7930 if test "${enable_usb+set}" = set; then :
7931 enableval=$enable_usb;
7932 else
7933 enable_usb=yes
7934 fi
7935
7936
7937 if test "x$enable_usb" != "xno" ; then
7938 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for USB sniffing support" >&5
7939 $as_echo_n "checking for USB sniffing support... " >&6; }
7940 case "$host_os" in
7941 linux*)
7942
7943 $as_echo "#define PCAP_SUPPORT_USB 1" >>confdefs.h
7944
7945 USB_SRC=pcap-usb-linux.c
7946 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7947 $as_echo "yes" >&6; }
7948 ac_usb_dev_name=`udevinfo -q name -p /sys/class/usb_device/usbmon 2>/dev/null`
7949 if test $? -ne 0 ; then
7950 ac_usb_dev_name="usbmon"
7951 fi
7952
7953 cat >>confdefs.h <<_ACEOF
7954 #define LINUX_USB_MON_DEV "/dev/$ac_usb_dev_name"
7955 _ACEOF
7956
7957 { $as_echo "$as_me:${as_lineno-$LINENO}: Device for USB sniffing is /dev/$ac_usb_dev_name" >&5
7958 $as_echo "$as_me: Device for USB sniffing is /dev/$ac_usb_dev_name" >&6;}
7959 #
7960 # Do we have a version of <linux/compiler.h> available?
7961 # If so, we might need it for <linux/usbdevice_fs.h>.
7962 #
7963 for ac_header in linux/compiler.h
7964 do :
7965 ac_fn_c_check_header_mongrel "$LINENO" "linux/compiler.h" "ac_cv_header_linux_compiler_h" "$ac_includes_default"
7966 if test "x$ac_cv_header_linux_compiler_h" = xyes; then :
7967 cat >>confdefs.h <<_ACEOF
7968 #define HAVE_LINUX_COMPILER_H 1
7969 _ACEOF
7970
7971 fi
7972
7973 done
7974
7975 if test "$ac_cv_header_linux_compiler_h" = yes; then
7976 #
7977 # Yes - include it when testing for <linux/usbdevice_fs.h>.
7978 #
7979 for ac_header in linux/usbdevice_fs.h
7980 do :
7981 ac_fn_c_check_header_compile "$LINENO" "linux/usbdevice_fs.h" "ac_cv_header_linux_usbdevice_fs_h" "#include <linux/compiler.h>
7982 "
7983 if test "x$ac_cv_header_linux_usbdevice_fs_h" = xyes; then :
7984 cat >>confdefs.h <<_ACEOF
7985 #define HAVE_LINUX_USBDEVICE_FS_H 1
7986 _ACEOF
7987
7988 fi
7989
7990 done
7991
7992 else
7993 for ac_header in linux/usbdevice_fs.h
7994 do :
7995 ac_fn_c_check_header_mongrel "$LINENO" "linux/usbdevice_fs.h" "ac_cv_header_linux_usbdevice_fs_h" "$ac_includes_default"
7996 if test "x$ac_cv_header_linux_usbdevice_fs_h" = xyes; then :
7997 cat >>confdefs.h <<_ACEOF
7998 #define HAVE_LINUX_USBDEVICE_FS_H 1
7999 _ACEOF
8000
8001 fi
8002
8003 done
8004
8005 fi
8006 if test "$ac_cv_header_linux_usbdevice_fs_h" = yes; then
8007 #
8008 # OK, does it define bRequestType? Older versions of the kernel
8009 # define fields with names like "requesttype, "request", and
8010 # "value", rather than "bRequestType", "bRequest", and
8011 # "wValue".
8012 #
8013 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if usbdevfs_ctrltransfer struct has bRequestType member" >&5
8014 $as_echo_n "checking if usbdevfs_ctrltransfer struct has bRequestType member... " >&6; }
8015 if ${ac_cv_usbdevfs_ctrltransfer_has_bRequestType+:} false; then :
8016 $as_echo_n "(cached) " >&6
8017 else
8018 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8019 /* end confdefs.h. */
8020
8021 $ac_includes_default
8022 #ifdef HAVE_SYS_BITYPES_H
8023 #include <sys/bitypes.h>
8024 #endif
8025 #ifdef HAVE_LINUX_COMPILER_H
8026 #include <linux/compiler.h>
8027 #endif
8028 #include <linux/usbdevice_fs.h>
8029 int
8030 main ()
8031 {
8032 u_int i = sizeof(((struct usbdevfs_ctrltransfer *)0)->bRequestType)
8033 ;
8034 return 0;
8035 }
8036 _ACEOF
8037 if ac_fn_c_try_compile "$LINENO"; then :
8038 ac_cv_usbdevfs_ctrltransfer_has_bRequestType=yes
8039 else
8040 ac_cv_usbdevfs_ctrltransfer_has_bRequestType=no
8041 fi
8042 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8043 fi
8044
8045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_usbdevfs_ctrltransfer_has_bRequestType" >&5
8046 $as_echo "$ac_cv_usbdevfs_ctrltransfer_has_bRequestType" >&6; }
8047 if test $ac_cv_usbdevfs_ctrltransfer_has_bRequestType = yes ; then
8048
8049 $as_echo "#define HAVE_USBDEVFS_CTRLTRANSFER_BREQUESTTYPE 1" >>confdefs.h
8050
8051 fi
8052 fi
8053 ;;
8054 *)
8055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8056 $as_echo "no" >&6; }
8057 ;;
8058 esac
8059 fi
8060
8061
8062
8063 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the platform could support netfilter sniffing" >&5
8064 $as_echo_n "checking whether the platform could support netfilter sniffing... " >&6; }
8065 case "$host_os" in
8066 linux*)
8067 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8068 $as_echo "yes" >&6; }
8069 #
8070 # Life's too short to deal with trying to get this to compile
8071 # if you don't get the right types defined with
8072 # __KERNEL_STRICT_NAMES getting defined by some other include.
8073 #
8074 # Check whether the includes Just Work. If not, don't turn on
8075 # netfilter support.
8076 #
8077 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we can compile the netfilter support" >&5
8078 $as_echo_n "checking whether we can compile the netfilter support... " >&6; }
8079 if ${ac_cv_netfilter_can_compile+:} false; then :
8080 $as_echo_n "(cached) " >&6
8081 else
8082 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8083 /* end confdefs.h. */
8084
8085 $ac_includes_default
8086 #include <sys/socket.h>
8087 #include <netinet/in.h>
8088 #include <linux/types.h>
8089
8090 #include <linux/netlink.h>
8091 #include <linux/netfilter.h>
8092 #include <linux/netfilter/nfnetlink.h>
8093 #include <linux/netfilter/nfnetlink_log.h>
8094 #include <linux/netfilter/nfnetlink_queue.h>
8095 int
8096 main ()
8097 {
8098
8099 ;
8100 return 0;
8101 }
8102 _ACEOF
8103 if ac_fn_c_try_compile "$LINENO"; then :
8104 ac_cv_netfilter_can_compile=yes
8105 else
8106 ac_cv_netfilter_can_compile=no
8107 fi
8108 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8109 fi
8110
8111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_netfilter_can_compile" >&5
8112 $as_echo "$ac_cv_netfilter_can_compile" >&6; }
8113 if test $ac_cv_netfilter_can_compile = yes ; then
8114
8115 $as_echo "#define PCAP_SUPPORT_NETFILTER 1" >>confdefs.h
8116
8117 NETFILTER_SRC=pcap-netfilter-linux.c
8118 fi
8119 ;;
8120 *)
8121 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8122 $as_echo "no" >&6; }
8123 ;;
8124 esac
8125
8126
8127
8128 # Check whether --enable-bluetooth was given.
8129 if test "${enable_bluetooth+set}" = set; then :
8130 enableval=$enable_bluetooth;
8131 else
8132 enable_bluetooth=ifsupportavailable
8133 fi
8134
8135
8136 if test "x$enable_bluetooth" != "xno" ; then
8137 case "$host_os" in
8138 linux*)
8139 ac_fn_c_check_header_mongrel "$LINENO" "bluetooth/bluetooth.h" "ac_cv_header_bluetooth_bluetooth_h" "$ac_includes_default"
8140 if test "x$ac_cv_header_bluetooth_bluetooth_h" = xyes; then :
8141
8142
8143 $as_echo "#define PCAP_SUPPORT_BT 1" >>confdefs.h
8144
8145 BT_SRC=pcap-bt-linux.c
8146 { $as_echo "$as_me:${as_lineno-$LINENO}: Bluetooth sniffing is supported" >&5
8147 $as_echo "$as_me: Bluetooth sniffing is supported" >&6;}
8148
8149 #
8150 # OK, does struct sockaddr_hci have an hci_channel
8151 # member?
8152 #
8153 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if struct sockaddr_hci has hci_channel member" >&5
8154 $as_echo_n "checking if struct sockaddr_hci has hci_channel member... " >&6; }
8155 if ${ac_cv_lbl_sockaddr_hci_has_hci_channel+:} false; then :
8156 $as_echo_n "(cached) " >&6
8157 else
8158 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8159 /* end confdefs.h. */
8160
8161 #include <bluetooth/bluetooth.h>
8162 #include <bluetooth/hci.h>
8163
8164 int
8165 main ()
8166 {
8167 u_int i = sizeof(((struct sockaddr_hci *)0)->hci_channel)
8168 ;
8169 return 0;
8170 }
8171 _ACEOF
8172 if ac_fn_c_try_compile "$LINENO"; then :
8173 ac_cv_lbl_sockaddr_hci_has_hci_channel=yes
8174 else
8175 ac_cv_lbl_sockaddr_hci_has_hci_channel=no
8176 fi
8177 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8178 fi
8179
8180 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_sockaddr_hci_has_hci_channel" >&5
8181 $as_echo "$ac_cv_lbl_sockaddr_hci_has_hci_channel" >&6; }
8182 if test $ac_cv_lbl_sockaddr_hci_has_hci_channel = yes ; then
8183
8184 $as_echo "#define SOCKADDR_HCI_HAS_HCI_CHANNEL /**/" >>confdefs.h
8185
8186
8187 #
8188 # OK, is HCI_CHANNEL_MONITOR defined?
8189 #
8190 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if HCI_CHANNEL_MONITOR is defined" >&5
8191 $as_echo_n "checking if HCI_CHANNEL_MONITOR is defined... " >&6; }
8192 if ${ac_cv_lbl_hci_channel_monitor_is_defined+:} false; then :
8193 $as_echo_n "(cached) " >&6
8194 else
8195 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8196 /* end confdefs.h. */
8197
8198 #include <bluetooth/bluetooth.h>
8199 #include <bluetooth/hci.h>
8200
8201 int
8202 main ()
8203 {
8204 u_int i = HCI_CHANNEL_MONITOR
8205 ;
8206 return 0;
8207 }
8208 _ACEOF
8209 if ac_fn_c_try_compile "$LINENO"; then :
8210 ac_cv_lbl_hci_channel_monitor_is_defined=yes
8211 else
8212 ac_cv_lbl_hci_channel_monitor_is_defined=no
8213 fi
8214 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8215 fi
8216
8217 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_hci_channel_monitor_is_defined" >&5
8218 $as_echo "$ac_cv_lbl_hci_channel_monitor_is_defined" >&6; }
8219 if test $ac_cv_lbl_hci_channel_monitor_is_defined = yes ; then
8220
8221 $as_echo "#define PCAP_SUPPORT_BT_MONITOR /**/" >>confdefs.h
8222
8223 BT_MONITOR_SRC=pcap-bt-monitor-linux.c
8224 fi
8225 fi
8226 ac_lbl_bluetooth_available=yes
8227
8228 else
8229 ac_lbl_bluetooth_available=no
8230
8231 fi
8232
8233
8234 if test "x$ac_lbl_bluetooth_available" == "xno" ; then
8235 if test "x$enable_bluetooth" = "xyes" ; then
8236 as_fn_error $? "Bluetooth sniffing is not supported; install bluez-lib devel to enable it" "$LINENO" 5
8237 else
8238 { $as_echo "$as_me:${as_lineno-$LINENO}: Bluetooth sniffing is not supported; install bluez-lib devel to enable it" >&5
8239 $as_echo "$as_me: Bluetooth sniffing is not supported; install bluez-lib devel to enable it" >&6;}
8240 fi
8241 fi
8242 ;;
8243 *)
8244 if test "x$enable_bluetooth" = "xyes" ; then
8245 as_fn_error $? "no Bluetooth sniffing support implemented for $host_os" "$LINENO" 5
8246 else
8247 { $as_echo "$as_me:${as_lineno-$LINENO}: no Bluetooth sniffing support implemented for $host_os" >&5
8248 $as_echo "$as_me: no Bluetooth sniffing support implemented for $host_os" >&6;}
8249 fi
8250 ;;
8251 esac
8252
8253
8254
8255 fi
8256
8257 # Check whether --enable-canusb was given.
8258 if test "${enable_canusb+set}" = set; then :
8259 enableval=$enable_canusb;
8260 else
8261 enable_canusb=ifsupportavailable
8262 fi
8263
8264
8265 if test "x$enable_canusb" != "xno" ; then
8266 case "$host_os" in
8267 linux*|uclinux*)
8268 ac_fn_c_check_header_mongrel "$LINENO" "libusb-1.0/libusb.h" "ac_cv_header_libusb_1_0_libusb_h" "$ac_includes_default"
8269 if test "x$ac_cv_header_libusb_1_0_libusb_h" = xyes; then :
8270
8271 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libusb_init in -lusb-1.0" >&5
8272 $as_echo_n "checking for libusb_init in -lusb-1.0... " >&6; }
8273 if ${ac_cv_lib_usb_1_0_libusb_init+:} false; then :
8274 $as_echo_n "(cached) " >&6
8275 else
8276 ac_check_lib_save_LIBS=$LIBS
8277 LIBS="-lusb-1.0 -lpthread
8278 $LIBS"
8279 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8280 /* end confdefs.h. */
8281
8282 /* Override any GCC internal prototype to avoid an error.
8283 Use char because int might match the return type of a GCC
8284 builtin and then its argument prototype would still apply. */
8285 #ifdef __cplusplus
8286 extern "C"
8287 #endif
8288 char libusb_init ();
8289 int
8290 main ()
8291 {
8292 return libusb_init ();
8293 ;
8294 return 0;
8295 }
8296 _ACEOF
8297 if ac_fn_c_try_link "$LINENO"; then :
8298 ac_cv_lib_usb_1_0_libusb_init=yes
8299 else
8300 ac_cv_lib_usb_1_0_libusb_init=no
8301 fi
8302 rm -f core conftest.err conftest.$ac_objext \
8303 conftest$ac_exeext conftest.$ac_ext
8304 LIBS=$ac_check_lib_save_LIBS
8305 fi
8306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_usb_1_0_libusb_init" >&5
8307 $as_echo "$ac_cv_lib_usb_1_0_libusb_init" >&6; }
8308 if test "x$ac_cv_lib_usb_1_0_libusb_init" = xyes; then :
8309
8310
8311 $as_echo "#define PCAP_SUPPORT_CANUSB 1" >>confdefs.h
8312
8313 CANUSB_SRC=pcap-canusb-linux.c
8314 LIBS="-lusb-1.0 -lpthread $LIBS"
8315 ac_lbl_has_libusb=yes
8316
8317 else
8318 ac_lbl_has_libusb=no
8319 fi
8320
8321
8322 else
8323 ac_lbl_has_libusb=no
8324
8325 fi
8326
8327
8328 if test "x$ac_lbl_has_libusb" = "xyes" ; then
8329 { $as_echo "$as_me:${as_lineno-$LINENO}: canusb sniffing is supported" >&5
8330 $as_echo "$as_me: canusb sniffing is supported" >&6;}
8331 else
8332 if test "x$enable_canusb" = "xyes" ; then
8333 as_fn_error $? "canusb sniffing is not supported; install libusb1.0 lib devel to enable it" "$LINENO" 5
8334 else
8335 { $as_echo "$as_me:${as_lineno-$LINENO}: canusb sniffing is not supported; install libusb1.0 lib devel to enable it" >&5
8336 $as_echo "$as_me: canusb sniffing is not supported; install libusb1.0 lib devel to enable it" >&6;}
8337 fi
8338 fi
8339 ;;
8340 *)
8341 if test "x$enable_canusb" = "xyes" ; then
8342 as_fn_error $? "no canusb support implemented for $host_os" "$LINENO" 5
8343 else
8344 { $as_echo "$as_me:${as_lineno-$LINENO}: no canusb support implemented for $host_os" >&5
8345 $as_echo "$as_me: no canusb support implemented for $host_os" >&6;}
8346 fi
8347 ;;
8348 esac
8349
8350
8351 fi
8352
8353 # Check whether --enable-can was given.
8354 if test "${enable_can+set}" = set; then :
8355 enableval=$enable_can;
8356 else
8357 enable_can=ifsupportavailable
8358 fi
8359
8360
8361 if test "x$enable_can" != "xno" ; then
8362 case "$host_os" in
8363 linux*)
8364 ac_fn_c_check_header_compile "$LINENO" "linux/can.h" "ac_cv_header_linux_can_h" "#include <sys/socket.h>
8365
8366 "
8367 if test "x$ac_cv_header_linux_can_h" = xyes; then :
8368
8369
8370 $as_echo "#define PCAP_SUPPORT_CAN 1" >>confdefs.h
8371
8372 CAN_SRC=pcap-can-linux.c
8373 { $as_echo "$as_me:${as_lineno-$LINENO}: CAN sniffing is supported" >&5
8374 $as_echo "$as_me: CAN sniffing is supported" >&6;}
8375
8376 else
8377
8378 if test "x$enable_can" = "xyes" ; then
8379 as_fn_error $? "CAN sniffing is not supported" "$LINENO" 5
8380 else
8381 { $as_echo "$as_me:${as_lineno-$LINENO}: CAN sniffing is not supported" >&5
8382 $as_echo "$as_me: CAN sniffing is not supported" >&6;}
8383 fi
8384
8385 fi
8386
8387
8388 ;;
8389 *)
8390 if test "x$enable_can" = "xyes" ; then
8391 as_fn_error $? "no CAN sniffing support implemented for $host_os" "$LINENO" 5
8392 else
8393 { $as_echo "$as_me:${as_lineno-$LINENO}: no CAN sniffing support implemented for $host_os" >&5
8394 $as_echo "$as_me: no CAN sniffing support implemented for $host_os" >&6;}
8395 fi
8396 ;;
8397 esac
8398
8399
8400 fi
8401
8402 # Check whether --enable-dbus was given.
8403 if test "${enable_dbus+set}" = set; then :
8404 enableval=$enable_dbus;
8405 else
8406 enable_dbus=ifavailable
8407 fi
8408
8409
8410 if test "x$enable_dbus" != "xno"; then
8411 if test "x$enable_dbus" = "xyes"; then
8412 case "$host_os" in
8413
8414 darwin*)
8415 #
8416 # We don't support D-Bus sniffing on OS X; see
8417 #
8418 # https://bugs.freedesktop.org/show_bug.cgi?id=74029
8419 #
8420 # The user requested it, so fail.
8421 #
8422 as_fn_error $? "Due to freedesktop.org bug 74029, D-Bus capture support is not available on OS X" "$LINENO" 5
8423 esac
8424 else
8425 case "$host_os" in
8426
8427 darwin*)
8428 #
8429 # We don't support D-Bus sniffing on OS X; see
8430 #
8431 # https://bugs.freedesktop.org/show_bug.cgi?id=74029
8432 #
8433 # The user dind't explicitly request it, so just
8434 # silently refuse to enable it.
8435 #
8436 enable_dbus="no"
8437 ;;
8438 esac
8439 fi
8440 fi
8441
8442 if test "x$enable_dbus" != "xno"; then
8443 # Extract the first word of "pkg-config", so it can be a program name with args.
8444 set dummy pkg-config; ac_word=$2
8445 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8446 $as_echo_n "checking for $ac_word... " >&6; }
8447 if ${ac_cv_prog_PKGCONFIG+:} false; then :
8448 $as_echo_n "(cached) " >&6
8449 else
8450 if test -n "$PKGCONFIG"; then
8451 ac_cv_prog_PKGCONFIG="$PKGCONFIG" # Let the user override the test.
8452 else
8453 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8454 for as_dir in $PATH
8455 do
8456 IFS=$as_save_IFS
8457 test -z "$as_dir" && as_dir=.
8458 for ac_exec_ext in '' $ac_executable_extensions; do
8459 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8460 ac_cv_prog_PKGCONFIG="pkg-config"
8461 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8462 break 2
8463 fi
8464 done
8465 done
8466 IFS=$as_save_IFS
8467
8468 test -z "$ac_cv_prog_PKGCONFIG" && ac_cv_prog_PKGCONFIG="no"
8469 fi
8470 fi
8471 PKGCONFIG=$ac_cv_prog_PKGCONFIG
8472 if test -n "$PKGCONFIG"; then
8473 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
8474 $as_echo "$PKGCONFIG" >&6; }
8475 else
8476 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8477 $as_echo "no" >&6; }
8478 fi
8479
8480
8481 if test "x$PKGCONFIG" != "xno"; then
8482 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for D-Bus" >&5
8483 $as_echo_n "checking for D-Bus... " >&6; }
8484 if "$PKGCONFIG" dbus-1; then
8485 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8486 $as_echo "yes" >&6; }
8487 DBUS_CFLAGS=`"$PKGCONFIG" --cflags dbus-1`
8488 DBUS_LIBS=`"$PKGCONFIG" --libs dbus-1`
8489 save_CFLAGS="$CFLAGS"
8490 save_LIBS="$LIBS"
8491 CFLAGS="$CFLAGS $DBUS_CFLAGS"
8492 LIBS="$LIBS $DBUS_LIBS"
8493 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the D-Bus library defines dbus_connection_read_write" >&5
8494 $as_echo_n "checking whether the D-Bus library defines dbus_connection_read_write... " >&6; }
8495 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8496 /* end confdefs.h. */
8497 #include <string.h>
8498
8499 #include <time.h>
8500 #include <sys/time.h>
8501
8502 #include <dbus/dbus.h>
8503 int
8504 main ()
8505 {
8506 return dbus_connection_read_write(NULL, 0);
8507 ;
8508 return 0;
8509 }
8510 _ACEOF
8511 if ac_fn_c_try_link "$LINENO"; then :
8512
8513 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8514 $as_echo "yes" >&6; }
8515
8516 $as_echo "#define PCAP_SUPPORT_DBUS 1" >>confdefs.h
8517
8518 DBUS_SRC=pcap-dbus.c
8519 V_INCLS="$V_INCLS $DBUS_CFLAGS"
8520
8521 else
8522
8523 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8524 $as_echo "no" >&6; }
8525 if test "x$enable_dbus" = "xyes"; then
8526 as_fn_error $? "--enable-dbus was given, but the D-Bus library doesn't define dbus_connection_read_write()" "$LINENO" 5
8527 fi
8528 LIBS="$save_LIBS"
8529
8530 fi
8531 rm -f core conftest.err conftest.$ac_objext \
8532 conftest$ac_exeext conftest.$ac_ext
8533 CFLAGS="$save_CFLAGS"
8534 else
8535 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8536 $as_echo "no" >&6; }
8537 if test "x$enable_dbus" = "xyes"; then
8538 as_fn_error $? "--enable-dbus was given, but the dbus-1 package is not installed" "$LINENO" 5
8539 fi
8540 fi
8541 fi
8542
8543
8544 fi
8545
8546 case "$host_os" in
8547 linux*)
8548 for ac_header in linux/net_tstamp.h
8549 do :
8550 ac_fn_c_check_header_mongrel "$LINENO" "linux/net_tstamp.h" "ac_cv_header_linux_net_tstamp_h" "$ac_includes_default"
8551 if test "x$ac_cv_header_linux_net_tstamp_h" = xyes; then :
8552 cat >>confdefs.h <<_ACEOF
8553 #define HAVE_LINUX_NET_TSTAMP_H 1
8554 _ACEOF
8555
8556 fi
8557
8558 done
8559
8560 ;;
8561 *)
8562 { $as_echo "$as_me:${as_lineno-$LINENO}: no hardware timestamp support implemented for $host_os" >&5
8563 $as_echo "$as_me: no hardware timestamp support implemented for $host_os" >&6;}
8564 ;;
8565 esac
8566
8567 # Check whether --enable-packet-ring was given.
8568 if test "${enable_packet_ring+set}" = set; then :
8569 enableval=$enable_packet_ring;
8570 else
8571 enable_packet_ring=yes
8572 fi
8573
8574
8575 if test "x$enable_packet_ring" != "xno" ; then
8576
8577 $as_echo "#define PCAP_SUPPORT_PACKET_RING 1" >>confdefs.h
8578
8579
8580 fi
8581
8582 # Find a good install program. We prefer a C program (faster),
8583 # so one script is as good as another. But avoid the broken or
8584 # incompatible versions:
8585 # SysV /etc/install, /usr/sbin/install
8586 # SunOS /usr/etc/install
8587 # IRIX /sbin/install
8588 # AIX /bin/install
8589 # AmigaOS /C/install, which installs bootblocks on floppy discs
8590 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
8591 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
8592 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
8593 # OS/2's system install, which has a completely different semantic
8594 # ./install, which can be erroneously created by make from ./install.sh.
8595 # Reject install programs that cannot install multiple files.
8596 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
8597 $as_echo_n "checking for a BSD-compatible install... " >&6; }
8598 if test -z "$INSTALL"; then
8599 if ${ac_cv_path_install+:} false; then :
8600 $as_echo_n "(cached) " >&6
8601 else
8602 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8603 for as_dir in $PATH
8604 do
8605 IFS=$as_save_IFS
8606 test -z "$as_dir" && as_dir=.
8607 # Account for people who put trailing slashes in PATH elements.
8608 case $as_dir/ in #((
8609 ./ | .// | /[cC]/* | \
8610 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
8611 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
8612 /usr/ucb/* ) ;;
8613 *)
8614 # OSF1 and SCO ODT 3.0 have their own names for install.
8615 # Don't use installbsd from OSF since it installs stuff as root
8616 # by default.
8617 for ac_prog in ginstall scoinst install; do
8618 for ac_exec_ext in '' $ac_executable_extensions; do
8619 if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
8620 if test $ac_prog = install &&
8621 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
8622 # AIX install. It has an incompatible calling convention.
8623 :
8624 elif test $ac_prog = install &&
8625 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
8626 # program-specific install script used by HP pwplus--don't use.
8627 :
8628 else
8629 rm -rf conftest.one conftest.two conftest.dir
8630 echo one > conftest.one
8631 echo two > conftest.two
8632 mkdir conftest.dir
8633 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
8634 test -s conftest.one && test -s conftest.two &&
8635 test -s conftest.dir/conftest.one &&
8636 test -s conftest.dir/conftest.two
8637 then
8638 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
8639 break 3
8640 fi
8641 fi
8642 fi
8643 done
8644 done
8645 ;;
8646 esac
8647
8648 done
8649 IFS=$as_save_IFS
8650
8651 rm -rf conftest.one conftest.two conftest.dir
8652
8653 fi
8654 if test "${ac_cv_path_install+set}" = set; then
8655 INSTALL=$ac_cv_path_install
8656 else
8657 # As a last resort, use the slow shell script. Don't cache a
8658 # value for INSTALL within a source directory, because that will
8659 # break other packages using the cache if that directory is
8660 # removed, or if the value is a relative name.
8661 INSTALL=$ac_install_sh
8662 fi
8663 fi
8664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
8665 $as_echo "$INSTALL" >&6; }
8666
8667 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
8668 # It thinks the first close brace ends the variable substitution.
8669 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
8670
8671 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
8672
8673 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
8674
8675
8676 ac_config_headers="$ac_config_headers config.h"
8677
8678
8679 ac_config_commands="$ac_config_commands default-1"
8680
8681 ac_config_files="$ac_config_files Makefile pcap-filter.manmisc pcap-linktype.manmisc pcap-tstamp.manmisc pcap-savefile.manfile pcap.3pcap pcap_compile.3pcap pcap_datalink.3pcap pcap_dump_open.3pcap pcap_get_tstamp_precision.3pcap pcap_list_datalinks.3pcap pcap_list_tstamp_types.3pcap pcap_open_dead.3pcap pcap_open_offline.3pcap pcap_set_tstamp_precision.3pcap pcap_set_tstamp_type.3pcap"
8682
8683 cat >confcache <<\_ACEOF
8684 # This file is a shell script that caches the results of configure
8685 # tests run on this system so they can be shared between configure
8686 # scripts and configure runs, see configure's option --config-cache.
8687 # It is not useful on other systems. If it contains results you don't
8688 # want to keep, you may remove or edit it.
8689 #
8690 # config.status only pays attention to the cache file if you give it
8691 # the --recheck option to rerun configure.
8692 #
8693 # `ac_cv_env_foo' variables (set or unset) will be overridden when
8694 # loading this file, other *unset* `ac_cv_foo' will be assigned the
8695 # following values.
8696
8697 _ACEOF
8698
8699 # The following way of writing the cache mishandles newlines in values,
8700 # but we know of no workaround that is simple, portable, and efficient.
8701 # So, we kill variables containing newlines.
8702 # Ultrix sh set writes to stderr and can't be redirected directly,
8703 # and sets the high bit in the cache file unless we assign to the vars.
8704 (
8705 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
8706 eval ac_val=\$$ac_var
8707 case $ac_val in #(
8708 *${as_nl}*)
8709 case $ac_var in #(
8710 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
8711 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
8712 esac
8713 case $ac_var in #(
8714 _ | IFS | as_nl) ;; #(
8715 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
8716 *) { eval $ac_var=; unset $ac_var;} ;;
8717 esac ;;
8718 esac
8719 done
8720
8721 (set) 2>&1 |
8722 case $as_nl`(ac_space=' '; set) 2>&1` in #(
8723 *${as_nl}ac_space=\ *)
8724 # `set' does not quote correctly, so add quotes: double-quote
8725 # substitution turns \\\\ into \\, and sed turns \\ into \.
8726 sed -n \
8727 "s/'/'\\\\''/g;
8728 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
8729 ;; #(
8730 *)
8731 # `set' quotes correctly as required by POSIX, so do not add quotes.
8732 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
8733 ;;
8734 esac |
8735 sort
8736 ) |
8737 sed '
8738 /^ac_cv_env_/b end
8739 t clear
8740 :clear
8741 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
8742 t end
8743 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
8744 :end' >>confcache
8745 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
8746 if test -w "$cache_file"; then
8747 if test "x$cache_file" != "x/dev/null"; then
8748 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
8749 $as_echo "$as_me: updating cache $cache_file" >&6;}
8750 if test ! -f "$cache_file" || test -h "$cache_file"; then
8751 cat confcache >"$cache_file"
8752 else
8753 case $cache_file in #(
8754 */* | ?:*)
8755 mv -f confcache "$cache_file"$$ &&
8756 mv -f "$cache_file"$$ "$cache_file" ;; #(
8757 *)
8758 mv -f confcache "$cache_file" ;;
8759 esac
8760 fi
8761 fi
8762 else
8763 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
8764 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
8765 fi
8766 fi
8767 rm -f confcache
8768
8769 test "x$prefix" = xNONE && prefix=$ac_default_prefix
8770 # Let make expand exec_prefix.
8771 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
8772
8773 DEFS=-DHAVE_CONFIG_H
8774
8775 ac_libobjs=
8776 ac_ltlibobjs=
8777 U=
8778 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
8779 # 1. Remove the extension, and $U if already installed.
8780 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
8781 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
8782 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
8783 # will be set to the directory where LIBOBJS objects are built.
8784 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
8785 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
8786 done
8787 LIBOBJS=$ac_libobjs
8788
8789 LTLIBOBJS=$ac_ltlibobjs
8790
8791
8792
8793 : "${CONFIG_STATUS=./config.status}"
8794 ac_write_fail=0
8795 ac_clean_files_save=$ac_clean_files
8796 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
8797 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
8798 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
8799 as_write_fail=0
8800 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
8801 #! $SHELL
8802 # Generated by $as_me.
8803 # Run this file to recreate the current configuration.
8804 # Compiler output produced by configure, useful for debugging
8805 # configure, is in config.log if it exists.
8806
8807 debug=false
8808 ac_cs_recheck=false
8809 ac_cs_silent=false
8810
8811 SHELL=\${CONFIG_SHELL-$SHELL}
8812 export SHELL
8813 _ASEOF
8814 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
8815 ## -------------------- ##
8816 ## M4sh Initialization. ##
8817 ## -------------------- ##
8818
8819 # Be more Bourne compatible
8820 DUALCASE=1; export DUALCASE # for MKS sh
8821 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
8822 emulate sh
8823 NULLCMD=:
8824 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
8825 # is contrary to our usage. Disable this feature.
8826 alias -g '${1+"$@"}'='"$@"'
8827 setopt NO_GLOB_SUBST
8828 else
8829 case `(set -o) 2>/dev/null` in #(
8830 *posix*) :
8831 set -o posix ;; #(
8832 *) :
8833 ;;
8834 esac
8835 fi
8836
8837
8838 as_nl='
8839 '
8840 export as_nl
8841 # Printing a long string crashes Solaris 7 /usr/bin/printf.
8842 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
8843 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
8844 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
8845 # Prefer a ksh shell builtin over an external printf program on Solaris,
8846 # but without wasting forks for bash or zsh.
8847 if test -z "$BASH_VERSION$ZSH_VERSION" \
8848 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
8849 as_echo='print -r --'
8850 as_echo_n='print -rn --'
8851 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
8852 as_echo='printf %s\n'
8853 as_echo_n='printf %s'
8854 else
8855 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
8856 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
8857 as_echo_n='/usr/ucb/echo -n'
8858 else
8859 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
8860 as_echo_n_body='eval
8861 arg=$1;
8862 case $arg in #(
8863 *"$as_nl"*)
8864 expr "X$arg" : "X\\(.*\\)$as_nl";
8865 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
8866 esac;
8867 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
8868 '
8869 export as_echo_n_body
8870 as_echo_n='sh -c $as_echo_n_body as_echo'
8871 fi
8872 export as_echo_body
8873 as_echo='sh -c $as_echo_body as_echo'
8874 fi
8875
8876 # The user is always right.
8877 if test "${PATH_SEPARATOR+set}" != set; then
8878 PATH_SEPARATOR=:
8879 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
8880 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
8881 PATH_SEPARATOR=';'
8882 }
8883 fi
8884
8885
8886 # IFS
8887 # We need space, tab and new line, in precisely that order. Quoting is
8888 # there to prevent editors from complaining about space-tab.
8889 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
8890 # splitting by setting IFS to empty value.)
8891 IFS=" "" $as_nl"
8892
8893 # Find who we are. Look in the path if we contain no directory separator.
8894 as_myself=
8895 case $0 in #((
8896 *[\\/]* ) as_myself=$0 ;;
8897 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8898 for as_dir in $PATH
8899 do
8900 IFS=$as_save_IFS
8901 test -z "$as_dir" && as_dir=.
8902 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
8903 done
8904 IFS=$as_save_IFS
8905
8906 ;;
8907 esac
8908 # We did not find ourselves, most probably we were run as `sh COMMAND'
8909 # in which case we are not to be found in the path.
8910 if test "x$as_myself" = x; then
8911 as_myself=$0
8912 fi
8913 if test ! -f "$as_myself"; then
8914 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
8915 exit 1
8916 fi
8917
8918 # Unset variables that we do not need and which cause bugs (e.g. in
8919 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
8920 # suppresses any "Segmentation fault" message there. '((' could
8921 # trigger a bug in pdksh 5.2.14.
8922 for as_var in BASH_ENV ENV MAIL MAILPATH
8923 do eval test x\${$as_var+set} = xset \
8924 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
8925 done
8926 PS1='$ '
8927 PS2='> '
8928 PS4='+ '
8929
8930 # NLS nuisances.
8931 LC_ALL=C
8932 export LC_ALL
8933 LANGUAGE=C
8934 export LANGUAGE
8935
8936 # CDPATH.
8937 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
8938
8939
8940 # as_fn_error STATUS ERROR [LINENO LOG_FD]
8941 # ----------------------------------------
8942 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
8943 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
8944 # script with STATUS, using 1 if that was 0.
8945 as_fn_error ()
8946 {
8947 as_status=$1; test $as_status -eq 0 && as_status=1
8948 if test "$4"; then
8949 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
8950 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
8951 fi
8952 $as_echo "$as_me: error: $2" >&2
8953 as_fn_exit $as_status
8954 } # as_fn_error
8955
8956
8957 # as_fn_set_status STATUS
8958 # -----------------------
8959 # Set $? to STATUS, without forking.
8960 as_fn_set_status ()
8961 {
8962 return $1
8963 } # as_fn_set_status
8964
8965 # as_fn_exit STATUS
8966 # -----------------
8967 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
8968 as_fn_exit ()
8969 {
8970 set +e
8971 as_fn_set_status $1
8972 exit $1
8973 } # as_fn_exit
8974
8975 # as_fn_unset VAR
8976 # ---------------
8977 # Portably unset VAR.
8978 as_fn_unset ()
8979 {
8980 { eval $1=; unset $1;}
8981 }
8982 as_unset=as_fn_unset
8983 # as_fn_append VAR VALUE
8984 # ----------------------
8985 # Append the text in VALUE to the end of the definition contained in VAR. Take
8986 # advantage of any shell optimizations that allow amortized linear growth over
8987 # repeated appends, instead of the typical quadratic growth present in naive
8988 # implementations.
8989 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
8990 eval 'as_fn_append ()
8991 {
8992 eval $1+=\$2
8993 }'
8994 else
8995 as_fn_append ()
8996 {
8997 eval $1=\$$1\$2
8998 }
8999 fi # as_fn_append
9000
9001 # as_fn_arith ARG...
9002 # ------------------
9003 # Perform arithmetic evaluation on the ARGs, and store the result in the
9004 # global $as_val. Take advantage of shells that can avoid forks. The arguments
9005 # must be portable across $(()) and expr.
9006 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
9007 eval 'as_fn_arith ()
9008 {
9009 as_val=$(( $* ))
9010 }'
9011 else
9012 as_fn_arith ()
9013 {
9014 as_val=`expr "$@" || test $? -eq 1`
9015 }
9016 fi # as_fn_arith
9017
9018
9019 if expr a : '\(a\)' >/dev/null 2>&1 &&
9020 test "X`expr 00001 : '.*\(...\)'`" = X001; then
9021 as_expr=expr
9022 else
9023 as_expr=false
9024 fi
9025
9026 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
9027 as_basename=basename
9028 else
9029 as_basename=false
9030 fi
9031
9032 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
9033 as_dirname=dirname
9034 else
9035 as_dirname=false
9036 fi
9037
9038 as_me=`$as_basename -- "$0" ||
9039 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
9040 X"$0" : 'X\(//\)$' \| \
9041 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
9042 $as_echo X/"$0" |
9043 sed '/^.*\/\([^/][^/]*\)\/*$/{
9044 s//\1/
9045 q
9046 }
9047 /^X\/\(\/\/\)$/{
9048 s//\1/
9049 q
9050 }
9051 /^X\/\(\/\).*/{
9052 s//\1/
9053 q
9054 }
9055 s/.*/./; q'`
9056
9057 # Avoid depending upon Character Ranges.
9058 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
9059 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
9060 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
9061 as_cr_digits='0123456789'
9062 as_cr_alnum=$as_cr_Letters$as_cr_digits
9063
9064 ECHO_C= ECHO_N= ECHO_T=
9065 case `echo -n x` in #(((((
9066 -n*)
9067 case `echo 'xy\c'` in
9068 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
9069 xy) ECHO_C='\c';;
9070 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
9071 ECHO_T=' ';;
9072 esac;;
9073 *)
9074 ECHO_N='-n';;
9075 esac
9076
9077 rm -f conf$$ conf$$.exe conf$$.file
9078 if test -d conf$$.dir; then
9079 rm -f conf$$.dir/conf$$.file
9080 else
9081 rm -f conf$$.dir
9082 mkdir conf$$.dir 2>/dev/null
9083 fi
9084 if (echo >conf$$.file) 2>/dev/null; then
9085 if ln -s conf$$.file conf$$ 2>/dev/null; then
9086 as_ln_s='ln -s'
9087 # ... but there are two gotchas:
9088 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
9089 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
9090 # In both cases, we have to default to `cp -pR'.
9091 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
9092 as_ln_s='cp -pR'
9093 elif ln conf$$.file conf$$ 2>/dev/null; then
9094 as_ln_s=ln
9095 else
9096 as_ln_s='cp -pR'
9097 fi
9098 else
9099 as_ln_s='cp -pR'
9100 fi
9101 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
9102 rmdir conf$$.dir 2>/dev/null
9103
9104
9105 # as_fn_mkdir_p
9106 # -------------
9107 # Create "$as_dir" as a directory, including parents if necessary.
9108 as_fn_mkdir_p ()
9109 {
9110
9111 case $as_dir in #(
9112 -*) as_dir=./$as_dir;;
9113 esac
9114 test -d "$as_dir" || eval $as_mkdir_p || {
9115 as_dirs=
9116 while :; do
9117 case $as_dir in #(
9118 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
9119 *) as_qdir=$as_dir;;
9120 esac
9121 as_dirs="'$as_qdir' $as_dirs"
9122 as_dir=`$as_dirname -- "$as_dir" ||
9123 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
9124 X"$as_dir" : 'X\(//\)[^/]' \| \
9125 X"$as_dir" : 'X\(//\)$' \| \
9126 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
9127 $as_echo X"$as_dir" |
9128 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
9129 s//\1/
9130 q
9131 }
9132 /^X\(\/\/\)[^/].*/{
9133 s//\1/
9134 q
9135 }
9136 /^X\(\/\/\)$/{
9137 s//\1/
9138 q
9139 }
9140 /^X\(\/\).*/{
9141 s//\1/
9142 q
9143 }
9144 s/.*/./; q'`
9145 test -d "$as_dir" && break
9146 done
9147 test -z "$as_dirs" || eval "mkdir $as_dirs"
9148 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
9149
9150
9151 } # as_fn_mkdir_p
9152 if mkdir -p . 2>/dev/null; then
9153 as_mkdir_p='mkdir -p "$as_dir"'
9154 else
9155 test -d ./-p && rmdir ./-p
9156 as_mkdir_p=false
9157 fi
9158
9159
9160 # as_fn_executable_p FILE
9161 # -----------------------
9162 # Test if FILE is an executable regular file.
9163 as_fn_executable_p ()
9164 {
9165 test -f "$1" && test -x "$1"
9166 } # as_fn_executable_p
9167 as_test_x='test -x'
9168 as_executable_p=as_fn_executable_p
9169
9170 # Sed expression to map a string onto a valid CPP name.
9171 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
9172
9173 # Sed expression to map a string onto a valid variable name.
9174 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
9175
9176
9177 exec 6>&1
9178 ## ----------------------------------- ##
9179 ## Main body of $CONFIG_STATUS script. ##
9180 ## ----------------------------------- ##
9181 _ASEOF
9182 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
9183
9184 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
9185 # Save the log message, to keep $0 and so on meaningful, and to
9186 # report actual input values of CONFIG_FILES etc. instead of their
9187 # values after options handling.
9188 ac_log="
9189 This file was extended by $as_me, which was
9190 generated by GNU Autoconf 2.69. Invocation command line was
9191
9192 CONFIG_FILES = $CONFIG_FILES
9193 CONFIG_HEADERS = $CONFIG_HEADERS
9194 CONFIG_LINKS = $CONFIG_LINKS
9195 CONFIG_COMMANDS = $CONFIG_COMMANDS
9196 $ $0 $@
9197
9198 on `(hostname || uname -n) 2>/dev/null | sed 1q`
9199 "
9200
9201 _ACEOF
9202
9203 case $ac_config_files in *"
9204 "*) set x $ac_config_files; shift; ac_config_files=$*;;
9205 esac
9206
9207 case $ac_config_headers in *"
9208 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
9209 esac
9210
9211
9212 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
9213 # Files that config.status was made for.
9214 config_files="$ac_config_files"
9215 config_headers="$ac_config_headers"
9216 config_commands="$ac_config_commands"
9217
9218 _ACEOF
9219
9220 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
9221 ac_cs_usage="\
9222 \`$as_me' instantiates files and other configuration actions
9223 from templates according to the current configuration. Unless the files
9224 and actions are specified as TAGs, all are instantiated by default.
9225
9226 Usage: $0 [OPTION]... [TAG]...
9227
9228 -h, --help print this help, then exit
9229 -V, --version print version number and configuration settings, then exit
9230 --config print configuration, then exit
9231 -q, --quiet, --silent
9232 do not print progress messages
9233 -d, --debug don't remove temporary files
9234 --recheck update $as_me by reconfiguring in the same conditions
9235 --file=FILE[:TEMPLATE]
9236 instantiate the configuration file FILE
9237 --header=FILE[:TEMPLATE]
9238 instantiate the configuration header FILE
9239
9240 Configuration files:
9241 $config_files
9242
9243 Configuration headers:
9244 $config_headers
9245
9246 Configuration commands:
9247 $config_commands
9248
9249 Report bugs to the package provider."
9250
9251 _ACEOF
9252 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
9253 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
9254 ac_cs_version="\\
9255 config.status
9256 configured by $0, generated by GNU Autoconf 2.69,
9257 with options \\"\$ac_cs_config\\"
9258
9259 Copyright (C) 2012 Free Software Foundation, Inc.
9260 This config.status script is free software; the Free Software Foundation
9261 gives unlimited permission to copy, distribute and modify it."
9262
9263 ac_pwd='$ac_pwd'
9264 srcdir='$srcdir'
9265 INSTALL='$INSTALL'
9266 test -n "\$AWK" || AWK=awk
9267 _ACEOF
9268
9269 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
9270 # The default lists apply if the user does not specify any file.
9271 ac_need_defaults=:
9272 while test $# != 0
9273 do
9274 case $1 in
9275 --*=?*)
9276 ac_option=`expr "X$1" : 'X\([^=]*\)='`
9277 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
9278 ac_shift=:
9279 ;;
9280 --*=)
9281 ac_option=`expr "X$1" : 'X\([^=]*\)='`
9282 ac_optarg=
9283 ac_shift=:
9284 ;;
9285 *)
9286 ac_option=$1
9287 ac_optarg=$2
9288 ac_shift=shift
9289 ;;
9290 esac
9291
9292 case $ac_option in
9293 # Handling of the options.
9294 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
9295 ac_cs_recheck=: ;;
9296 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
9297 $as_echo "$ac_cs_version"; exit ;;
9298 --config | --confi | --conf | --con | --co | --c )
9299 $as_echo "$ac_cs_config"; exit ;;
9300 --debug | --debu | --deb | --de | --d | -d )
9301 debug=: ;;
9302 --file | --fil | --fi | --f )
9303 $ac_shift
9304 case $ac_optarg in
9305 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
9306 '') as_fn_error $? "missing file argument" ;;
9307 esac
9308 as_fn_append CONFIG_FILES " '$ac_optarg'"
9309 ac_need_defaults=false;;
9310 --header | --heade | --head | --hea )
9311 $ac_shift
9312 case $ac_optarg in
9313 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
9314 esac
9315 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
9316 ac_need_defaults=false;;
9317 --he | --h)
9318 # Conflict between --help and --header
9319 as_fn_error $? "ambiguous option: \`$1'
9320 Try \`$0 --help' for more information.";;
9321 --help | --hel | -h )
9322 $as_echo "$ac_cs_usage"; exit ;;
9323 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
9324 | -silent | --silent | --silen | --sile | --sil | --si | --s)
9325 ac_cs_silent=: ;;
9326
9327 # This is an error.
9328 -*) as_fn_error $? "unrecognized option: \`$1'
9329 Try \`$0 --help' for more information." ;;
9330
9331 *) as_fn_append ac_config_targets " $1"
9332 ac_need_defaults=false ;;
9333
9334 esac
9335 shift
9336 done
9337
9338 ac_configure_extra_args=
9339
9340 if $ac_cs_silent; then
9341 exec 6>/dev/null
9342 ac_configure_extra_args="$ac_configure_extra_args --silent"
9343 fi
9344
9345 _ACEOF
9346 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
9347 if \$ac_cs_recheck; then
9348 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
9349 shift
9350 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
9351 CONFIG_SHELL='$SHELL'
9352 export CONFIG_SHELL
9353 exec "\$@"
9354 fi
9355
9356 _ACEOF
9357 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
9358 exec 5>>config.log
9359 {
9360 echo
9361 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
9362 ## Running $as_me. ##
9363 _ASBOX
9364 $as_echo "$ac_log"
9365 } >&5
9366
9367 _ACEOF
9368 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
9369 #
9370 # INIT-COMMANDS
9371 #
9372
9373
9374 _ACEOF
9375
9376 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
9377
9378 # Handling of arguments.
9379 for ac_config_target in $ac_config_targets
9380 do
9381 case $ac_config_target in
9382 "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;;
9383 "default-1") CONFIG_COMMANDS="$CONFIG_COMMANDS default-1" ;;
9384 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
9385 "pcap-filter.manmisc") CONFIG_FILES="$CONFIG_FILES pcap-filter.manmisc" ;;
9386 "pcap-linktype.manmisc") CONFIG_FILES="$CONFIG_FILES pcap-linktype.manmisc" ;;
9387 "pcap-tstamp.manmisc") CONFIG_FILES="$CONFIG_FILES pcap-tstamp.manmisc" ;;
9388 "pcap-savefile.manfile") CONFIG_FILES="$CONFIG_FILES pcap-savefile.manfile" ;;
9389 "pcap.3pcap") CONFIG_FILES="$CONFIG_FILES pcap.3pcap" ;;
9390 "pcap_compile.3pcap") CONFIG_FILES="$CONFIG_FILES pcap_compile.3pcap" ;;
9391 "pcap_datalink.3pcap") CONFIG_FILES="$CONFIG_FILES pcap_datalink.3pcap" ;;
9392 "pcap_dump_open.3pcap") CONFIG_FILES="$CONFIG_FILES pcap_dump_open.3pcap" ;;
9393 "pcap_get_tstamp_precision.3pcap") CONFIG_FILES="$CONFIG_FILES pcap_get_tstamp_precision.3pcap" ;;
9394 "pcap_list_datalinks.3pcap") CONFIG_FILES="$CONFIG_FILES pcap_list_datalinks.3pcap" ;;
9395 "pcap_list_tstamp_types.3pcap") CONFIG_FILES="$CONFIG_FILES pcap_list_tstamp_types.3pcap" ;;
9396 "pcap_open_dead.3pcap") CONFIG_FILES="$CONFIG_FILES pcap_open_dead.3pcap" ;;
9397 "pcap_open_offline.3pcap") CONFIG_FILES="$CONFIG_FILES pcap_open_offline.3pcap" ;;
9398 "pcap_set_tstamp_precision.3pcap") CONFIG_FILES="$CONFIG_FILES pcap_set_tstamp_precision.3pcap" ;;
9399 "pcap_set_tstamp_type.3pcap") CONFIG_FILES="$CONFIG_FILES pcap_set_tstamp_type.3pcap" ;;
9400
9401 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
9402 esac
9403 done
9404
9405
9406 # If the user did not use the arguments to specify the items to instantiate,
9407 # then the envvar interface is used. Set only those that are not.
9408 # We use the long form for the default assignment because of an extremely
9409 # bizarre bug on SunOS 4.1.3.
9410 if $ac_need_defaults; then
9411 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
9412 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
9413 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
9414 fi
9415
9416 # Have a temporary directory for convenience. Make it in the build tree
9417 # simply because there is no reason against having it here, and in addition,
9418 # creating and moving files from /tmp can sometimes cause problems.
9419 # Hook for its removal unless debugging.
9420 # Note that there is a small window in which the directory will not be cleaned:
9421 # after its creation but before its name has been assigned to `$tmp'.
9422 $debug ||
9423 {
9424 tmp= ac_tmp=
9425 trap 'exit_status=$?
9426 : "${ac_tmp:=$tmp}"
9427 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
9428 ' 0
9429 trap 'as_fn_exit 1' 1 2 13 15
9430 }
9431 # Create a (secure) tmp directory for tmp files.
9432
9433 {
9434 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
9435 test -d "$tmp"
9436 } ||
9437 {
9438 tmp=./conf$$-$RANDOM
9439 (umask 077 && mkdir "$tmp")
9440 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
9441 ac_tmp=$tmp
9442
9443 # Set up the scripts for CONFIG_FILES section.
9444 # No need to generate them if there are no CONFIG_FILES.
9445 # This happens for instance with `./config.status config.h'.
9446 if test -n "$CONFIG_FILES"; then
9447
9448
9449 ac_cr=`echo X | tr X '\015'`
9450 # On cygwin, bash can eat \r inside `` if the user requested igncr.
9451 # But we know of no other shell where ac_cr would be empty at this
9452 # point, so we can use a bashism as a fallback.
9453 if test "x$ac_cr" = x; then
9454 eval ac_cr=\$\'\\r\'
9455 fi
9456 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
9457 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
9458 ac_cs_awk_cr='\\r'
9459 else
9460 ac_cs_awk_cr=$ac_cr
9461 fi
9462
9463 echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
9464 _ACEOF
9465
9466
9467 {
9468 echo "cat >conf$$subs.awk <<_ACEOF" &&
9469 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
9470 echo "_ACEOF"
9471 } >conf$$subs.sh ||
9472 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
9473 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
9474 ac_delim='%!_!# '
9475 for ac_last_try in false false false false false :; do
9476 . ./conf$$subs.sh ||
9477 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
9478
9479 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
9480 if test $ac_delim_n = $ac_delim_num; then
9481 break
9482 elif $ac_last_try; then
9483 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
9484 else
9485 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
9486 fi
9487 done
9488 rm -f conf$$subs.sh
9489
9490 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
9491 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
9492 _ACEOF
9493 sed -n '
9494 h
9495 s/^/S["/; s/!.*/"]=/
9496 p
9497 g
9498 s/^[^!]*!//
9499 :repl
9500 t repl
9501 s/'"$ac_delim"'$//
9502 t delim
9503 :nl
9504 h
9505 s/\(.\{148\}\)..*/\1/
9506 t more1
9507 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
9508 p
9509 n
9510 b repl
9511 :more1
9512 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
9513 p
9514 g
9515 s/.\{148\}//
9516 t nl
9517 :delim
9518 h
9519 s/\(.\{148\}\)..*/\1/
9520 t more2
9521 s/["\\]/\\&/g; s/^/"/; s/$/"/
9522 p
9523 b
9524 :more2
9525 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
9526 p
9527 g
9528 s/.\{148\}//
9529 t delim
9530 ' <conf$$subs.awk | sed '
9531 /^[^""]/{
9532 N
9533 s/\n//
9534 }
9535 ' >>$CONFIG_STATUS || ac_write_fail=1
9536 rm -f conf$$subs.awk
9537 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
9538 _ACAWK
9539 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
9540 for (key in S) S_is_set[key] = 1
9541 FS = "\a"
9542
9543 }
9544 {
9545 line = $ 0
9546 nfields = split(line, field, "@")
9547 substed = 0
9548 len = length(field[1])
9549 for (i = 2; i < nfields; i++) {
9550 key = field[i]
9551 keylen = length(key)
9552 if (S_is_set[key]) {
9553 value = S[key]
9554 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
9555 len += length(value) + length(field[++i])
9556 substed = 1
9557 } else
9558 len += 1 + keylen
9559 }
9560
9561 print line
9562 }
9563
9564 _ACAWK
9565 _ACEOF
9566 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
9567 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
9568 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
9569 else
9570 cat
9571 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
9572 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
9573 _ACEOF
9574
9575 # VPATH may cause trouble with some makes, so we remove sole $(srcdir),
9576 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
9577 # trailing colons and then remove the whole line if VPATH becomes empty
9578 # (actually we leave an empty line to preserve line numbers).
9579 if test "x$srcdir" = x.; then
9580 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
9581 h
9582 s///
9583 s/^/:/
9584 s/[ ]*$/:/
9585 s/:\$(srcdir):/:/g
9586 s/:\${srcdir}:/:/g
9587 s/:@srcdir@:/:/g
9588 s/^:*//
9589 s/:*$//
9590 x
9591 s/\(=[ ]*\).*/\1/
9592 G
9593 s/\n//
9594 s/^[^=]*=[ ]*$//
9595 }'
9596 fi
9597
9598 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
9599 fi # test -n "$CONFIG_FILES"
9600
9601 # Set up the scripts for CONFIG_HEADERS section.
9602 # No need to generate them if there are no CONFIG_HEADERS.
9603 # This happens for instance with `./config.status Makefile'.
9604 if test -n "$CONFIG_HEADERS"; then
9605 cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
9606 BEGIN {
9607 _ACEOF
9608
9609 # Transform confdefs.h into an awk script `defines.awk', embedded as
9610 # here-document in config.status, that substitutes the proper values into
9611 # config.h.in to produce config.h.
9612
9613 # Create a delimiter string that does not exist in confdefs.h, to ease
9614 # handling of long lines.
9615 ac_delim='%!_!# '
9616 for ac_last_try in false false :; do
9617 ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
9618 if test -z "$ac_tt"; then
9619 break
9620 elif $ac_last_try; then
9621 as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
9622 else
9623 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
9624 fi
9625 done
9626
9627 # For the awk script, D is an array of macro values keyed by name,
9628 # likewise P contains macro parameters if any. Preserve backslash
9629 # newline sequences.
9630
9631 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
9632 sed -n '
9633 s/.\{148\}/&'"$ac_delim"'/g
9634 t rset
9635 :rset
9636 s/^[ ]*#[ ]*define[ ][ ]*/ /
9637 t def
9638 d
9639 :def
9640 s/\\$//
9641 t bsnl
9642 s/["\\]/\\&/g
9643 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
9644 D["\1"]=" \3"/p
9645 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
9646 d
9647 :bsnl
9648 s/["\\]/\\&/g
9649 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
9650 D["\1"]=" \3\\\\\\n"\\/p
9651 t cont
9652 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
9653 t cont
9654 d
9655 :cont
9656 n
9657 s/.\{148\}/&'"$ac_delim"'/g
9658 t clear
9659 :clear
9660 s/\\$//
9661 t bsnlc
9662 s/["\\]/\\&/g; s/^/"/; s/$/"/p
9663 d
9664 :bsnlc
9665 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
9666 b cont
9667 ' <confdefs.h | sed '
9668 s/'"$ac_delim"'/"\\\
9669 "/g' >>$CONFIG_STATUS || ac_write_fail=1
9670
9671 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
9672 for (key in D) D_is_set[key] = 1
9673 FS = "\a"
9674 }
9675 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
9676 line = \$ 0
9677 split(line, arg, " ")
9678 if (arg[1] == "#") {
9679 defundef = arg[2]
9680 mac1 = arg[3]
9681 } else {
9682 defundef = substr(arg[1], 2)
9683 mac1 = arg[2]
9684 }
9685 split(mac1, mac2, "(") #)
9686 macro = mac2[1]
9687 prefix = substr(line, 1, index(line, defundef) - 1)
9688 if (D_is_set[macro]) {
9689 # Preserve the white space surrounding the "#".
9690 print prefix "define", macro P[macro] D[macro]
9691 next
9692 } else {
9693 # Replace #undef with comments. This is necessary, for example,
9694 # in the case of _POSIX_SOURCE, which is predefined and required
9695 # on some systems where configure will not decide to define it.
9696 if (defundef == "undef") {
9697 print "/*", prefix defundef, macro, "*/"
9698 next
9699 }
9700 }
9701 }
9702 { print }
9703 _ACAWK
9704 _ACEOF
9705 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
9706 as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
9707 fi # test -n "$CONFIG_HEADERS"
9708
9709
9710 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
9711 shift
9712 for ac_tag
9713 do
9714 case $ac_tag in
9715 :[FHLC]) ac_mode=$ac_tag; continue;;
9716 esac
9717 case $ac_mode$ac_tag in
9718 :[FHL]*:*);;
9719 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
9720 :[FH]-) ac_tag=-:-;;
9721 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
9722 esac
9723 ac_save_IFS=$IFS
9724 IFS=:
9725 set x $ac_tag
9726 IFS=$ac_save_IFS
9727 shift
9728 ac_file=$1
9729 shift
9730
9731 case $ac_mode in
9732 :L) ac_source=$1;;
9733 :[FH])
9734 ac_file_inputs=
9735 for ac_f
9736 do
9737 case $ac_f in
9738 -) ac_f="$ac_tmp/stdin";;
9739 *) # Look for the file first in the build tree, then in the source tree
9740 # (if the path is not absolute). The absolute path cannot be DOS-style,
9741 # because $ac_f cannot contain `:'.
9742 test -f "$ac_f" ||
9743 case $ac_f in
9744 [\\/$]*) false;;
9745 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
9746 esac ||
9747 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
9748 esac
9749 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
9750 as_fn_append ac_file_inputs " '$ac_f'"
9751 done
9752
9753 # Let's still pretend it is `configure' which instantiates (i.e., don't
9754 # use $as_me), people would be surprised to read:
9755 # /* config.h. Generated by config.status. */
9756 configure_input='Generated from '`
9757 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
9758 `' by configure.'
9759 if test x"$ac_file" != x-; then
9760 configure_input="$ac_file. $configure_input"
9761 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
9762 $as_echo "$as_me: creating $ac_file" >&6;}
9763 fi
9764 # Neutralize special characters interpreted by sed in replacement strings.
9765 case $configure_input in #(
9766 *\&* | *\|* | *\\* )
9767 ac_sed_conf_input=`$as_echo "$configure_input" |
9768 sed 's/[\\\\&|]/\\\\&/g'`;; #(
9769 *) ac_sed_conf_input=$configure_input;;
9770 esac
9771
9772 case $ac_tag in
9773 *:-:* | *:-) cat >"$ac_tmp/stdin" \
9774 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
9775 esac
9776 ;;
9777 esac
9778
9779 ac_dir=`$as_dirname -- "$ac_file" ||
9780 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
9781 X"$ac_file" : 'X\(//\)[^/]' \| \
9782 X"$ac_file" : 'X\(//\)$' \| \
9783 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
9784 $as_echo X"$ac_file" |
9785 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
9786 s//\1/
9787 q
9788 }
9789 /^X\(\/\/\)[^/].*/{
9790 s//\1/
9791 q
9792 }
9793 /^X\(\/\/\)$/{
9794 s//\1/
9795 q
9796 }
9797 /^X\(\/\).*/{
9798 s//\1/
9799 q
9800 }
9801 s/.*/./; q'`
9802 as_dir="$ac_dir"; as_fn_mkdir_p
9803 ac_builddir=.
9804
9805 case "$ac_dir" in
9806 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
9807 *)
9808 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
9809 # A ".." for each directory in $ac_dir_suffix.
9810 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
9811 case $ac_top_builddir_sub in
9812 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
9813 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
9814 esac ;;
9815 esac
9816 ac_abs_top_builddir=$ac_pwd
9817 ac_abs_builddir=$ac_pwd$ac_dir_suffix
9818 # for backward compatibility:
9819 ac_top_builddir=$ac_top_build_prefix
9820
9821 case $srcdir in
9822 .) # We are building in place.
9823 ac_srcdir=.
9824 ac_top_srcdir=$ac_top_builddir_sub
9825 ac_abs_top_srcdir=$ac_pwd ;;
9826 [\\/]* | ?:[\\/]* ) # Absolute name.
9827 ac_srcdir=$srcdir$ac_dir_suffix;
9828 ac_top_srcdir=$srcdir
9829 ac_abs_top_srcdir=$srcdir ;;
9830 *) # Relative name.
9831 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
9832 ac_top_srcdir=$ac_top_build_prefix$srcdir
9833 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
9834 esac
9835 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
9836
9837
9838 case $ac_mode in
9839 :F)
9840 #
9841 # CONFIG_FILE
9842 #
9843
9844 case $INSTALL in
9845 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
9846 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
9847 esac
9848 _ACEOF
9849
9850 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
9851 # If the template does not know about datarootdir, expand it.
9852 # FIXME: This hack should be removed a few years after 2.60.
9853 ac_datarootdir_hack=; ac_datarootdir_seen=
9854 ac_sed_dataroot='
9855 /datarootdir/ {
9856 p
9857 q
9858 }
9859 /@datadir@/p
9860 /@docdir@/p
9861 /@infodir@/p
9862 /@localedir@/p
9863 /@mandir@/p'
9864 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
9865 *datarootdir*) ac_datarootdir_seen=yes;;
9866 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
9867 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
9868 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
9869 _ACEOF
9870 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
9871 ac_datarootdir_hack='
9872 s&@datadir@&$datadir&g
9873 s&@docdir@&$docdir&g
9874 s&@infodir@&$infodir&g
9875 s&@localedir@&$localedir&g
9876 s&@mandir@&$mandir&g
9877 s&\\\${datarootdir}&$datarootdir&g' ;;
9878 esac
9879 _ACEOF
9880
9881 # Neutralize VPATH when `$srcdir' = `.'.
9882 # Shell code in configure.ac might set extrasub.
9883 # FIXME: do we really want to maintain this feature?
9884 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
9885 ac_sed_extra="$ac_vpsub
9886 $extrasub
9887 _ACEOF
9888 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
9889 :t
9890 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
9891 s|@configure_input@|$ac_sed_conf_input|;t t
9892 s&@top_builddir@&$ac_top_builddir_sub&;t t
9893 s&@top_build_prefix@&$ac_top_build_prefix&;t t
9894 s&@srcdir@&$ac_srcdir&;t t
9895 s&@abs_srcdir@&$ac_abs_srcdir&;t t
9896 s&@top_srcdir@&$ac_top_srcdir&;t t
9897 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
9898 s&@builddir@&$ac_builddir&;t t
9899 s&@abs_builddir@&$ac_abs_builddir&;t t
9900 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
9901 s&@INSTALL@&$ac_INSTALL&;t t
9902 $ac_datarootdir_hack
9903 "
9904 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
9905 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
9906
9907 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
9908 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
9909 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
9910 "$ac_tmp/out"`; test -z "$ac_out"; } &&
9911 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
9912 which seems to be undefined. Please make sure it is defined" >&5
9913 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
9914 which seems to be undefined. Please make sure it is defined" >&2;}
9915
9916 rm -f "$ac_tmp/stdin"
9917 case $ac_file in
9918 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
9919 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
9920 esac \
9921 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
9922 ;;
9923 :H)
9924 #
9925 # CONFIG_HEADER
9926 #
9927 if test x"$ac_file" != x-; then
9928 {
9929 $as_echo "/* $configure_input */" \
9930 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
9931 } >"$ac_tmp/config.h" \
9932 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
9933 if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
9934 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
9935 $as_echo "$as_me: $ac_file is unchanged" >&6;}
9936 else
9937 rm -f "$ac_file"
9938 mv "$ac_tmp/config.h" "$ac_file" \
9939 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
9940 fi
9941 else
9942 $as_echo "/* $configure_input */" \
9943 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
9944 || as_fn_error $? "could not create -" "$LINENO" 5
9945 fi
9946 ;;
9947
9948 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
9949 $as_echo "$as_me: executing $ac_file commands" >&6;}
9950 ;;
9951 esac
9952
9953
9954 case $ac_file$ac_mode in
9955 "default-1":C) if test -f .devel; then
9956 echo timestamp > stamp-h
9957 cat Makefile-devel-adds >> Makefile
9958 make depend
9959 fi ;;
9960
9961 esac
9962 done # for ac_tag
9963
9964
9965 as_fn_exit 0
9966 _ACEOF
9967 ac_clean_files=$ac_clean_files_save
9968
9969 test $ac_write_fail = 0 ||
9970 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
9971
9972
9973 # configure is writing to config.log, and then calls config.status.
9974 # config.status does its own redirection, appending to config.log.
9975 # Unfortunately, on DOS this fails, as config.log is still kept open
9976 # by configure, so config.status won't be able to write to it; its
9977 # output is simply discarded. So we exec the FD to /dev/null,
9978 # effectively closing config.log, so it can be properly (re)opened and
9979 # appended to by config.status. When coming back to configure, we
9980 # need to make the FD available again.
9981 if test "$no_create" != yes; then
9982 ac_cs_success=:
9983 ac_config_status_args=
9984 test "$silent" = yes &&
9985 ac_config_status_args="$ac_config_status_args --quiet"
9986 exec 5>/dev/null
9987 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
9988 exec 5>>config.log
9989 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
9990 # would make configure fail if this is the last instruction.
9991 $ac_cs_success || as_fn_exit 1
9992 fi
9993 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
9994 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
9995 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
9996 fi
9997
9998 exit 0