[gdb/build] Add CXX_DIALECT to CXX
[deliverable/binutils-gdb.git] / gdbserver / 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="server.cc"
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_header_list=
623 ac_subst_vars='LTLIBOBJS
624 LIBOBJS
625 GNULIB_STDINT_H
626 extra_libraries
627 IPA_DEPFILES
628 srv_xmlfiles
629 srv_xmlbuiltin
630 GDBSERVER_LIBS
631 GDBSERVER_DEPFILES
632 RDYNAMIC
633 REPORT_BUGS_TEXI
634 REPORT_BUGS_TO
635 PKGVERSION
636 WERROR_CFLAGS
637 WARN_CFLAGS
638 ustinc
639 ustlibs
640 CCDEPMODE
641 CONFIG_SRC_SUBDIR
642 CATOBJEXT
643 GENCAT
644 INSTOBJEXT
645 DATADIRNAME
646 CATALOGS
647 POSUB
648 GMSGFMT
649 XGETTEXT
650 INCINTL
651 LIBINTL_DEP
652 LIBINTL
653 USE_NLS
654 DEPDIR
655 am__leading_dot
656 host_noncanonical
657 target_noncanonical
658 WIN32APILIBS
659 LTLIBIPT
660 LIBIPT
661 HAVE_LIBIPT
662 PTHREAD_CFLAGS
663 PTHREAD_LIBS
664 PTHREAD_CC
665 ax_pthread_config
666 SED
667 ALLOCA
668 CXX_DIALECT
669 HAVE_CXX11
670 RANLIB
671 AR
672 INSTALL_DATA
673 INSTALL_SCRIPT
674 INSTALL_PROGRAM
675 target_os
676 target_vendor
677 target_cpu
678 target
679 host_os
680 host_vendor
681 host_cpu
682 host
683 build_os
684 build_vendor
685 build_cpu
686 build
687 INSTALL_STRIP_PROGRAM
688 STRIP
689 install_sh
690 EGREP
691 GREP
692 CPP
693 ac_ct_CXX
694 CXXFLAGS
695 CXX
696 OBJEXT
697 EXEEXT
698 ac_ct_CC
699 CPPFLAGS
700 LDFLAGS
701 CFLAGS
702 CC
703 MAINT
704 MAINTAINER_MODE_FALSE
705 MAINTAINER_MODE_TRUE
706 target_alias
707 host_alias
708 build_alias
709 LIBS
710 ECHO_T
711 ECHO_N
712 ECHO_C
713 DEFS
714 mandir
715 localedir
716 libdir
717 psdir
718 pdfdir
719 dvidir
720 htmldir
721 infodir
722 docdir
723 oldincludedir
724 includedir
725 localstatedir
726 sharedstatedir
727 sysconfdir
728 datadir
729 datarootdir
730 libexecdir
731 sbindir
732 bindir
733 program_transform_name
734 prefix
735 exec_prefix
736 PACKAGE_URL
737 PACKAGE_BUGREPORT
738 PACKAGE_STRING
739 PACKAGE_VERSION
740 PACKAGE_TARNAME
741 PACKAGE_NAME
742 PATH_SEPARATOR
743 SHELL'
744 ac_subst_files=''
745 ac_user_opts='
746 enable_option_checking
747 enable_maintainer_mode
748 enable_largefile
749 with_intel_pt
750 with_gnu_ld
751 enable_rpath
752 with_libipt_prefix
753 with_libipt_type
754 enable_unit_tests
755 with_ust
756 with_ust_include
757 with_ust_lib
758 enable_werror
759 enable_build_warnings
760 enable_gdb_build_warnings
761 with_pkgversion
762 with_bugurl
763 with_libthread_db
764 enable_inprocess_agent
765 '
766 ac_precious_vars='build_alias
767 host_alias
768 target_alias
769 CC
770 CFLAGS
771 LDFLAGS
772 LIBS
773 CPPFLAGS
774 CXX
775 CXXFLAGS
776 CCC
777 CPP'
778
779
780 # Initialize some variables set by options.
781 ac_init_help=
782 ac_init_version=false
783 ac_unrecognized_opts=
784 ac_unrecognized_sep=
785 # The variables have the same names as the options, with
786 # dashes changed to underlines.
787 cache_file=/dev/null
788 exec_prefix=NONE
789 no_create=
790 no_recursion=
791 prefix=NONE
792 program_prefix=NONE
793 program_suffix=NONE
794 program_transform_name=s,x,x,
795 silent=
796 site=
797 srcdir=
798 verbose=
799 x_includes=NONE
800 x_libraries=NONE
801
802 # Installation directory options.
803 # These are left unexpanded so users can "make install exec_prefix=/foo"
804 # and all the variables that are supposed to be based on exec_prefix
805 # by default will actually change.
806 # Use braces instead of parens because sh, perl, etc. also accept them.
807 # (The list follows the same order as the GNU Coding Standards.)
808 bindir='${exec_prefix}/bin'
809 sbindir='${exec_prefix}/sbin'
810 libexecdir='${exec_prefix}/libexec'
811 datarootdir='${prefix}/share'
812 datadir='${datarootdir}'
813 sysconfdir='${prefix}/etc'
814 sharedstatedir='${prefix}/com'
815 localstatedir='${prefix}/var'
816 includedir='${prefix}/include'
817 oldincludedir='/usr/include'
818 docdir='${datarootdir}/doc/${PACKAGE}'
819 infodir='${datarootdir}/info'
820 htmldir='${docdir}'
821 dvidir='${docdir}'
822 pdfdir='${docdir}'
823 psdir='${docdir}'
824 libdir='${exec_prefix}/lib'
825 localedir='${datarootdir}/locale'
826 mandir='${datarootdir}/man'
827
828 ac_prev=
829 ac_dashdash=
830 for ac_option
831 do
832 # If the previous option needs an argument, assign it.
833 if test -n "$ac_prev"; then
834 eval $ac_prev=\$ac_option
835 ac_prev=
836 continue
837 fi
838
839 case $ac_option in
840 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
841 *=) ac_optarg= ;;
842 *) ac_optarg=yes ;;
843 esac
844
845 # Accept the important Cygnus configure options, so we can diagnose typos.
846
847 case $ac_dashdash$ac_option in
848 --)
849 ac_dashdash=yes ;;
850
851 -bindir | --bindir | --bindi | --bind | --bin | --bi)
852 ac_prev=bindir ;;
853 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
854 bindir=$ac_optarg ;;
855
856 -build | --build | --buil | --bui | --bu)
857 ac_prev=build_alias ;;
858 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
859 build_alias=$ac_optarg ;;
860
861 -cache-file | --cache-file | --cache-fil | --cache-fi \
862 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
863 ac_prev=cache_file ;;
864 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
865 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
866 cache_file=$ac_optarg ;;
867
868 --config-cache | -C)
869 cache_file=config.cache ;;
870
871 -datadir | --datadir | --datadi | --datad)
872 ac_prev=datadir ;;
873 -datadir=* | --datadir=* | --datadi=* | --datad=*)
874 datadir=$ac_optarg ;;
875
876 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
877 | --dataroo | --dataro | --datar)
878 ac_prev=datarootdir ;;
879 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
880 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
881 datarootdir=$ac_optarg ;;
882
883 -disable-* | --disable-*)
884 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
885 # Reject names that are not valid shell variable names.
886 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
887 as_fn_error $? "invalid feature name: $ac_useropt"
888 ac_useropt_orig=$ac_useropt
889 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
890 case $ac_user_opts in
891 *"
892 "enable_$ac_useropt"
893 "*) ;;
894 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
895 ac_unrecognized_sep=', ';;
896 esac
897 eval enable_$ac_useropt=no ;;
898
899 -docdir | --docdir | --docdi | --doc | --do)
900 ac_prev=docdir ;;
901 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
902 docdir=$ac_optarg ;;
903
904 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
905 ac_prev=dvidir ;;
906 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
907 dvidir=$ac_optarg ;;
908
909 -enable-* | --enable-*)
910 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
911 # Reject names that are not valid shell variable names.
912 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
913 as_fn_error $? "invalid feature name: $ac_useropt"
914 ac_useropt_orig=$ac_useropt
915 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
916 case $ac_user_opts in
917 *"
918 "enable_$ac_useropt"
919 "*) ;;
920 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
921 ac_unrecognized_sep=', ';;
922 esac
923 eval enable_$ac_useropt=\$ac_optarg ;;
924
925 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
926 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
927 | --exec | --exe | --ex)
928 ac_prev=exec_prefix ;;
929 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
930 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
931 | --exec=* | --exe=* | --ex=*)
932 exec_prefix=$ac_optarg ;;
933
934 -gas | --gas | --ga | --g)
935 # Obsolete; use --with-gas.
936 with_gas=yes ;;
937
938 -help | --help | --hel | --he | -h)
939 ac_init_help=long ;;
940 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
941 ac_init_help=recursive ;;
942 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
943 ac_init_help=short ;;
944
945 -host | --host | --hos | --ho)
946 ac_prev=host_alias ;;
947 -host=* | --host=* | --hos=* | --ho=*)
948 host_alias=$ac_optarg ;;
949
950 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
951 ac_prev=htmldir ;;
952 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
953 | --ht=*)
954 htmldir=$ac_optarg ;;
955
956 -includedir | --includedir | --includedi | --included | --include \
957 | --includ | --inclu | --incl | --inc)
958 ac_prev=includedir ;;
959 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
960 | --includ=* | --inclu=* | --incl=* | --inc=*)
961 includedir=$ac_optarg ;;
962
963 -infodir | --infodir | --infodi | --infod | --info | --inf)
964 ac_prev=infodir ;;
965 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
966 infodir=$ac_optarg ;;
967
968 -libdir | --libdir | --libdi | --libd)
969 ac_prev=libdir ;;
970 -libdir=* | --libdir=* | --libdi=* | --libd=*)
971 libdir=$ac_optarg ;;
972
973 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
974 | --libexe | --libex | --libe)
975 ac_prev=libexecdir ;;
976 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
977 | --libexe=* | --libex=* | --libe=*)
978 libexecdir=$ac_optarg ;;
979
980 -localedir | --localedir | --localedi | --localed | --locale)
981 ac_prev=localedir ;;
982 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
983 localedir=$ac_optarg ;;
984
985 -localstatedir | --localstatedir | --localstatedi | --localstated \
986 | --localstate | --localstat | --localsta | --localst | --locals)
987 ac_prev=localstatedir ;;
988 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
989 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
990 localstatedir=$ac_optarg ;;
991
992 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
993 ac_prev=mandir ;;
994 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
995 mandir=$ac_optarg ;;
996
997 -nfp | --nfp | --nf)
998 # Obsolete; use --without-fp.
999 with_fp=no ;;
1000
1001 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1002 | --no-cr | --no-c | -n)
1003 no_create=yes ;;
1004
1005 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1006 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1007 no_recursion=yes ;;
1008
1009 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1010 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1011 | --oldin | --oldi | --old | --ol | --o)
1012 ac_prev=oldincludedir ;;
1013 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1014 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1015 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1016 oldincludedir=$ac_optarg ;;
1017
1018 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1019 ac_prev=prefix ;;
1020 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1021 prefix=$ac_optarg ;;
1022
1023 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1024 | --program-pre | --program-pr | --program-p)
1025 ac_prev=program_prefix ;;
1026 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1027 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1028 program_prefix=$ac_optarg ;;
1029
1030 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1031 | --program-suf | --program-su | --program-s)
1032 ac_prev=program_suffix ;;
1033 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1034 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1035 program_suffix=$ac_optarg ;;
1036
1037 -program-transform-name | --program-transform-name \
1038 | --program-transform-nam | --program-transform-na \
1039 | --program-transform-n | --program-transform- \
1040 | --program-transform | --program-transfor \
1041 | --program-transfo | --program-transf \
1042 | --program-trans | --program-tran \
1043 | --progr-tra | --program-tr | --program-t)
1044 ac_prev=program_transform_name ;;
1045 -program-transform-name=* | --program-transform-name=* \
1046 | --program-transform-nam=* | --program-transform-na=* \
1047 | --program-transform-n=* | --program-transform-=* \
1048 | --program-transform=* | --program-transfor=* \
1049 | --program-transfo=* | --program-transf=* \
1050 | --program-trans=* | --program-tran=* \
1051 | --progr-tra=* | --program-tr=* | --program-t=*)
1052 program_transform_name=$ac_optarg ;;
1053
1054 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1055 ac_prev=pdfdir ;;
1056 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1057 pdfdir=$ac_optarg ;;
1058
1059 -psdir | --psdir | --psdi | --psd | --ps)
1060 ac_prev=psdir ;;
1061 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1062 psdir=$ac_optarg ;;
1063
1064 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1065 | -silent | --silent | --silen | --sile | --sil)
1066 silent=yes ;;
1067
1068 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1069 ac_prev=sbindir ;;
1070 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1071 | --sbi=* | --sb=*)
1072 sbindir=$ac_optarg ;;
1073
1074 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1075 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1076 | --sharedst | --shareds | --shared | --share | --shar \
1077 | --sha | --sh)
1078 ac_prev=sharedstatedir ;;
1079 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1080 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1081 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1082 | --sha=* | --sh=*)
1083 sharedstatedir=$ac_optarg ;;
1084
1085 -site | --site | --sit)
1086 ac_prev=site ;;
1087 -site=* | --site=* | --sit=*)
1088 site=$ac_optarg ;;
1089
1090 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1091 ac_prev=srcdir ;;
1092 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1093 srcdir=$ac_optarg ;;
1094
1095 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1096 | --syscon | --sysco | --sysc | --sys | --sy)
1097 ac_prev=sysconfdir ;;
1098 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1099 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1100 sysconfdir=$ac_optarg ;;
1101
1102 -target | --target | --targe | --targ | --tar | --ta | --t)
1103 ac_prev=target_alias ;;
1104 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1105 target_alias=$ac_optarg ;;
1106
1107 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1108 verbose=yes ;;
1109
1110 -version | --version | --versio | --versi | --vers | -V)
1111 ac_init_version=: ;;
1112
1113 -with-* | --with-*)
1114 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1115 # Reject names that are not valid shell variable names.
1116 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1117 as_fn_error $? "invalid package name: $ac_useropt"
1118 ac_useropt_orig=$ac_useropt
1119 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1120 case $ac_user_opts in
1121 *"
1122 "with_$ac_useropt"
1123 "*) ;;
1124 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1125 ac_unrecognized_sep=', ';;
1126 esac
1127 eval with_$ac_useropt=\$ac_optarg ;;
1128
1129 -without-* | --without-*)
1130 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1131 # Reject names that are not valid shell variable names.
1132 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1133 as_fn_error $? "invalid package name: $ac_useropt"
1134 ac_useropt_orig=$ac_useropt
1135 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1136 case $ac_user_opts in
1137 *"
1138 "with_$ac_useropt"
1139 "*) ;;
1140 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1141 ac_unrecognized_sep=', ';;
1142 esac
1143 eval with_$ac_useropt=no ;;
1144
1145 --x)
1146 # Obsolete; use --with-x.
1147 with_x=yes ;;
1148
1149 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1150 | --x-incl | --x-inc | --x-in | --x-i)
1151 ac_prev=x_includes ;;
1152 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1153 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1154 x_includes=$ac_optarg ;;
1155
1156 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1157 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1158 ac_prev=x_libraries ;;
1159 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1160 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1161 x_libraries=$ac_optarg ;;
1162
1163 -*) as_fn_error $? "unrecognized option: \`$ac_option'
1164 Try \`$0 --help' for more information"
1165 ;;
1166
1167 *=*)
1168 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1169 # Reject names that are not valid shell variable names.
1170 case $ac_envvar in #(
1171 '' | [0-9]* | *[!_$as_cr_alnum]* )
1172 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1173 esac
1174 eval $ac_envvar=\$ac_optarg
1175 export $ac_envvar ;;
1176
1177 *)
1178 # FIXME: should be removed in autoconf 3.0.
1179 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1180 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1181 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1182 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1183 ;;
1184
1185 esac
1186 done
1187
1188 if test -n "$ac_prev"; then
1189 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1190 as_fn_error $? "missing argument to $ac_option"
1191 fi
1192
1193 if test -n "$ac_unrecognized_opts"; then
1194 case $enable_option_checking in
1195 no) ;;
1196 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1197 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1198 esac
1199 fi
1200
1201 # Check all directory arguments for consistency.
1202 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1203 datadir sysconfdir sharedstatedir localstatedir includedir \
1204 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1205 libdir localedir mandir
1206 do
1207 eval ac_val=\$$ac_var
1208 # Remove trailing slashes.
1209 case $ac_val in
1210 */ )
1211 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1212 eval $ac_var=\$ac_val;;
1213 esac
1214 # Be sure to have absolute directory names.
1215 case $ac_val in
1216 [\\/$]* | ?:[\\/]* ) continue;;
1217 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1218 esac
1219 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1220 done
1221
1222 # There might be people who depend on the old broken behavior: `$host'
1223 # used to hold the argument of --host etc.
1224 # FIXME: To remove some day.
1225 build=$build_alias
1226 host=$host_alias
1227 target=$target_alias
1228
1229 # FIXME: To remove some day.
1230 if test "x$host_alias" != x; then
1231 if test "x$build_alias" = x; then
1232 cross_compiling=maybe
1233 elif test "x$build_alias" != "x$host_alias"; then
1234 cross_compiling=yes
1235 fi
1236 fi
1237
1238 ac_tool_prefix=
1239 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1240
1241 test "$silent" = yes && exec 6>/dev/null
1242
1243
1244 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1245 ac_ls_di=`ls -di .` &&
1246 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1247 as_fn_error $? "working directory cannot be determined"
1248 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1249 as_fn_error $? "pwd does not report name of working directory"
1250
1251
1252 # Find the source files, if location was not specified.
1253 if test -z "$srcdir"; then
1254 ac_srcdir_defaulted=yes
1255 # Try the directory containing this script, then the parent directory.
1256 ac_confdir=`$as_dirname -- "$as_myself" ||
1257 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1258 X"$as_myself" : 'X\(//\)[^/]' \| \
1259 X"$as_myself" : 'X\(//\)$' \| \
1260 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1261 $as_echo X"$as_myself" |
1262 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1263 s//\1/
1264 q
1265 }
1266 /^X\(\/\/\)[^/].*/{
1267 s//\1/
1268 q
1269 }
1270 /^X\(\/\/\)$/{
1271 s//\1/
1272 q
1273 }
1274 /^X\(\/\).*/{
1275 s//\1/
1276 q
1277 }
1278 s/.*/./; q'`
1279 srcdir=$ac_confdir
1280 if test ! -r "$srcdir/$ac_unique_file"; then
1281 srcdir=..
1282 fi
1283 else
1284 ac_srcdir_defaulted=no
1285 fi
1286 if test ! -r "$srcdir/$ac_unique_file"; then
1287 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1288 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1289 fi
1290 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1291 ac_abs_confdir=`(
1292 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1293 pwd)`
1294 # When building in place, set srcdir=.
1295 if test "$ac_abs_confdir" = "$ac_pwd"; then
1296 srcdir=.
1297 fi
1298 # Remove unnecessary trailing slashes from srcdir.
1299 # Double slashes in file names in object file debugging info
1300 # mess up M-x gdb in Emacs.
1301 case $srcdir in
1302 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1303 esac
1304 for ac_var in $ac_precious_vars; do
1305 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1306 eval ac_env_${ac_var}_value=\$${ac_var}
1307 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1308 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1309 done
1310
1311 #
1312 # Report the --help message.
1313 #
1314 if test "$ac_init_help" = "long"; then
1315 # Omit some internal or obsolete options to make the list less imposing.
1316 # This message is too long to be a string in the A/UX 3.1 sh.
1317 cat <<_ACEOF
1318 \`configure' configures this package to adapt to many kinds of systems.
1319
1320 Usage: $0 [OPTION]... [VAR=VALUE]...
1321
1322 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1323 VAR=VALUE. See below for descriptions of some of the useful variables.
1324
1325 Defaults for the options are specified in brackets.
1326
1327 Configuration:
1328 -h, --help display this help and exit
1329 --help=short display options specific to this package
1330 --help=recursive display the short help of all the included packages
1331 -V, --version display version information and exit
1332 -q, --quiet, --silent do not print \`checking ...' messages
1333 --cache-file=FILE cache test results in FILE [disabled]
1334 -C, --config-cache alias for \`--cache-file=config.cache'
1335 -n, --no-create do not create output files
1336 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1337
1338 Installation directories:
1339 --prefix=PREFIX install architecture-independent files in PREFIX
1340 [$ac_default_prefix]
1341 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
1342 [PREFIX]
1343
1344 By default, \`make install' will install all the files in
1345 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1346 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1347 for instance \`--prefix=\$HOME'.
1348
1349 For better control, use the options below.
1350
1351 Fine tuning of the installation directories:
1352 --bindir=DIR user executables [EPREFIX/bin]
1353 --sbindir=DIR system admin executables [EPREFIX/sbin]
1354 --libexecdir=DIR program executables [EPREFIX/libexec]
1355 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1356 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1357 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1358 --libdir=DIR object code libraries [EPREFIX/lib]
1359 --includedir=DIR C header files [PREFIX/include]
1360 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1361 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1362 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1363 --infodir=DIR info documentation [DATAROOTDIR/info]
1364 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1365 --mandir=DIR man documentation [DATAROOTDIR/man]
1366 --docdir=DIR documentation root [DATAROOTDIR/doc/PACKAGE]
1367 --htmldir=DIR html documentation [DOCDIR]
1368 --dvidir=DIR dvi documentation [DOCDIR]
1369 --pdfdir=DIR pdf documentation [DOCDIR]
1370 --psdir=DIR ps documentation [DOCDIR]
1371 _ACEOF
1372
1373 cat <<\_ACEOF
1374
1375 Program names:
1376 --program-prefix=PREFIX prepend PREFIX to installed program names
1377 --program-suffix=SUFFIX append SUFFIX to installed program names
1378 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
1379
1380 System types:
1381 --build=BUILD configure for building on BUILD [guessed]
1382 --host=HOST cross-compile to build programs to run on HOST [BUILD]
1383 --target=TARGET configure for building compilers for TARGET [HOST]
1384 _ACEOF
1385 fi
1386
1387 if test -n "$ac_init_help"; then
1388
1389 cat <<\_ACEOF
1390
1391 Optional Features:
1392 --disable-option-checking ignore unrecognized --enable/--with options
1393 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1394 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
1395 --enable-maintainer-mode
1396 enable make rules and dependencies not useful (and
1397 sometimes confusing) to the casual installer
1398 --disable-largefile omit support for large files
1399 --disable-rpath do not hardcode runtime library paths
1400 --enable-unit-tests Enable the inclusion of unit tests when compiling
1401 GDB
1402 --enable-werror treat compile warnings as errors
1403 --enable-build-warnings enable build-time compiler warnings if gcc is used
1404 --enable-gdb-build-warnings
1405 enable GDB specific build-time compiler warnings if
1406 gcc is used
1407 --enable-inprocess-agent
1408 inprocess agent
1409
1410 Optional Packages:
1411 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
1412 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
1413 --with-intel-pt include Intel Processor Trace support (auto/yes/no)
1414 --with-gnu-ld assume the C compiler uses GNU ld default=no
1415 --with-libipt-prefix[=DIR] search for libipt in DIR/include and DIR/lib
1416 --without-libipt-prefix don't search for libipt in includedir and libdir
1417 --with-libipt-type=TYPE type of library to search for (auto/static/shared)
1418 --with-ust=PATH Specify prefix directory for the installed UST package
1419 Equivalent to --with-ust-include=PATH/include
1420 plus --with-ust-lib=PATH/lib
1421 --with-ust-include=PATH Specify directory for installed UST include files
1422 --with-ust-lib=PATH Specify the directory for the installed UST library
1423 --with-pkgversion=PKG Use PKG in the version string in place of "GDB"
1424 --with-bugurl=URL Direct users to URL to report a bug
1425 --with-libthread-db=PATH
1426 use given libthread_db directly
1427
1428 Some influential environment variables:
1429 CC C compiler command
1430 CFLAGS C compiler flags
1431 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
1432 nonstandard directory <lib dir>
1433 LIBS libraries to pass to the linker, e.g. -l<library>
1434 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
1435 you have headers in a nonstandard directory <include dir>
1436 CXX C++ compiler command
1437 CXXFLAGS C++ compiler flags
1438 CPP C preprocessor
1439
1440 Use these variables to override the choices made by `configure' or to help
1441 it to find libraries and programs with nonstandard names/locations.
1442
1443 Report bugs to the package provider.
1444 _ACEOF
1445 ac_status=$?
1446 fi
1447
1448 if test "$ac_init_help" = "recursive"; then
1449 # If there are subdirs, report their specific --help.
1450 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1451 test -d "$ac_dir" ||
1452 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1453 continue
1454 ac_builddir=.
1455
1456 case "$ac_dir" in
1457 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1458 *)
1459 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1460 # A ".." for each directory in $ac_dir_suffix.
1461 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1462 case $ac_top_builddir_sub in
1463 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1464 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1465 esac ;;
1466 esac
1467 ac_abs_top_builddir=$ac_pwd
1468 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1469 # for backward compatibility:
1470 ac_top_builddir=$ac_top_build_prefix
1471
1472 case $srcdir in
1473 .) # We are building in place.
1474 ac_srcdir=.
1475 ac_top_srcdir=$ac_top_builddir_sub
1476 ac_abs_top_srcdir=$ac_pwd ;;
1477 [\\/]* | ?:[\\/]* ) # Absolute name.
1478 ac_srcdir=$srcdir$ac_dir_suffix;
1479 ac_top_srcdir=$srcdir
1480 ac_abs_top_srcdir=$srcdir ;;
1481 *) # Relative name.
1482 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1483 ac_top_srcdir=$ac_top_build_prefix$srcdir
1484 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1485 esac
1486 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1487
1488 cd "$ac_dir" || { ac_status=$?; continue; }
1489 # Check for guested configure.
1490 if test -f "$ac_srcdir/configure.gnu"; then
1491 echo &&
1492 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1493 elif test -f "$ac_srcdir/configure"; then
1494 echo &&
1495 $SHELL "$ac_srcdir/configure" --help=recursive
1496 else
1497 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1498 fi || ac_status=$?
1499 cd "$ac_pwd" || { ac_status=$?; break; }
1500 done
1501 fi
1502
1503 test -n "$ac_init_help" && exit $ac_status
1504 if $ac_init_version; then
1505 cat <<\_ACEOF
1506 configure
1507 generated by GNU Autoconf 2.69
1508
1509 Copyright (C) 2012 Free Software Foundation, Inc.
1510 This configure script is free software; the Free Software Foundation
1511 gives unlimited permission to copy, distribute and modify it.
1512 _ACEOF
1513 exit
1514 fi
1515
1516 ## ------------------------ ##
1517 ## Autoconf initialization. ##
1518 ## ------------------------ ##
1519
1520 # ac_fn_c_try_compile LINENO
1521 # --------------------------
1522 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1523 ac_fn_c_try_compile ()
1524 {
1525 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1526 rm -f conftest.$ac_objext
1527 if { { ac_try="$ac_compile"
1528 case "(($ac_try" in
1529 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1530 *) ac_try_echo=$ac_try;;
1531 esac
1532 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1533 $as_echo "$ac_try_echo"; } >&5
1534 (eval "$ac_compile") 2>conftest.err
1535 ac_status=$?
1536 if test -s conftest.err; then
1537 grep -v '^ *+' conftest.err >conftest.er1
1538 cat conftest.er1 >&5
1539 mv -f conftest.er1 conftest.err
1540 fi
1541 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1542 test $ac_status = 0; } && {
1543 test -z "$ac_c_werror_flag" ||
1544 test ! -s conftest.err
1545 } && test -s conftest.$ac_objext; then :
1546 ac_retval=0
1547 else
1548 $as_echo "$as_me: failed program was:" >&5
1549 sed 's/^/| /' conftest.$ac_ext >&5
1550
1551 ac_retval=1
1552 fi
1553 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1554 as_fn_set_status $ac_retval
1555
1556 } # ac_fn_c_try_compile
1557
1558 # ac_fn_cxx_try_compile LINENO
1559 # ----------------------------
1560 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1561 ac_fn_cxx_try_compile ()
1562 {
1563 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1564 rm -f conftest.$ac_objext
1565 if { { ac_try="$ac_compile"
1566 case "(($ac_try" in
1567 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1568 *) ac_try_echo=$ac_try;;
1569 esac
1570 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1571 $as_echo "$ac_try_echo"; } >&5
1572 (eval "$ac_compile") 2>conftest.err
1573 ac_status=$?
1574 if test -s conftest.err; then
1575 grep -v '^ *+' conftest.err >conftest.er1
1576 cat conftest.er1 >&5
1577 mv -f conftest.er1 conftest.err
1578 fi
1579 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1580 test $ac_status = 0; } && {
1581 test -z "$ac_cxx_werror_flag" ||
1582 test ! -s conftest.err
1583 } && test -s conftest.$ac_objext; then :
1584 ac_retval=0
1585 else
1586 $as_echo "$as_me: failed program was:" >&5
1587 sed 's/^/| /' conftest.$ac_ext >&5
1588
1589 ac_retval=1
1590 fi
1591 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1592 as_fn_set_status $ac_retval
1593
1594 } # ac_fn_cxx_try_compile
1595
1596 # ac_fn_c_try_cpp LINENO
1597 # ----------------------
1598 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1599 ac_fn_c_try_cpp ()
1600 {
1601 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1602 if { { ac_try="$ac_cpp conftest.$ac_ext"
1603 case "(($ac_try" in
1604 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1605 *) ac_try_echo=$ac_try;;
1606 esac
1607 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1608 $as_echo "$ac_try_echo"; } >&5
1609 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1610 ac_status=$?
1611 if test -s conftest.err; then
1612 grep -v '^ *+' conftest.err >conftest.er1
1613 cat conftest.er1 >&5
1614 mv -f conftest.er1 conftest.err
1615 fi
1616 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1617 test $ac_status = 0; } > conftest.i && {
1618 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1619 test ! -s conftest.err
1620 }; then :
1621 ac_retval=0
1622 else
1623 $as_echo "$as_me: failed program was:" >&5
1624 sed 's/^/| /' conftest.$ac_ext >&5
1625
1626 ac_retval=1
1627 fi
1628 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1629 as_fn_set_status $ac_retval
1630
1631 } # ac_fn_c_try_cpp
1632
1633 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
1634 # -------------------------------------------------------
1635 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
1636 # the include files in INCLUDES and setting the cache variable VAR
1637 # accordingly.
1638 ac_fn_c_check_header_mongrel ()
1639 {
1640 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1641 if eval \${$3+:} false; then :
1642 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1643 $as_echo_n "checking for $2... " >&6; }
1644 if eval \${$3+:} false; then :
1645 $as_echo_n "(cached) " >&6
1646 fi
1647 eval ac_res=\$$3
1648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1649 $as_echo "$ac_res" >&6; }
1650 else
1651 # Is the header compilable?
1652 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
1653 $as_echo_n "checking $2 usability... " >&6; }
1654 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1655 /* end confdefs.h. */
1656 $4
1657 #include <$2>
1658 _ACEOF
1659 if ac_fn_c_try_compile "$LINENO"; then :
1660 ac_header_compiler=yes
1661 else
1662 ac_header_compiler=no
1663 fi
1664 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
1666 $as_echo "$ac_header_compiler" >&6; }
1667
1668 # Is the header present?
1669 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
1670 $as_echo_n "checking $2 presence... " >&6; }
1671 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1672 /* end confdefs.h. */
1673 #include <$2>
1674 _ACEOF
1675 if ac_fn_c_try_cpp "$LINENO"; then :
1676 ac_header_preproc=yes
1677 else
1678 ac_header_preproc=no
1679 fi
1680 rm -f conftest.err conftest.i conftest.$ac_ext
1681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
1682 $as_echo "$ac_header_preproc" >&6; }
1683
1684 # So? What about this header?
1685 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
1686 yes:no: )
1687 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
1688 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
1689 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1690 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1691 ;;
1692 no:yes:* )
1693 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
1694 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
1695 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
1696 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
1697 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
1698 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
1699 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
1700 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
1701 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1702 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1703 ;;
1704 esac
1705 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1706 $as_echo_n "checking for $2... " >&6; }
1707 if eval \${$3+:} false; then :
1708 $as_echo_n "(cached) " >&6
1709 else
1710 eval "$3=\$ac_header_compiler"
1711 fi
1712 eval ac_res=\$$3
1713 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1714 $as_echo "$ac_res" >&6; }
1715 fi
1716 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1717
1718 } # ac_fn_c_check_header_mongrel
1719
1720 # ac_fn_c_try_run LINENO
1721 # ----------------------
1722 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
1723 # that executables *can* be run.
1724 ac_fn_c_try_run ()
1725 {
1726 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1727 if { { ac_try="$ac_link"
1728 case "(($ac_try" in
1729 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1730 *) ac_try_echo=$ac_try;;
1731 esac
1732 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1733 $as_echo "$ac_try_echo"; } >&5
1734 (eval "$ac_link") 2>&5
1735 ac_status=$?
1736 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1737 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1738 { { case "(($ac_try" in
1739 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1740 *) ac_try_echo=$ac_try;;
1741 esac
1742 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1743 $as_echo "$ac_try_echo"; } >&5
1744 (eval "$ac_try") 2>&5
1745 ac_status=$?
1746 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1747 test $ac_status = 0; }; }; then :
1748 ac_retval=0
1749 else
1750 $as_echo "$as_me: program exited with status $ac_status" >&5
1751 $as_echo "$as_me: failed program was:" >&5
1752 sed 's/^/| /' conftest.$ac_ext >&5
1753
1754 ac_retval=$ac_status
1755 fi
1756 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1757 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1758 as_fn_set_status $ac_retval
1759
1760 } # ac_fn_c_try_run
1761
1762 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
1763 # -------------------------------------------------------
1764 # Tests whether HEADER exists and can be compiled using the include files in
1765 # INCLUDES, setting the cache variable VAR accordingly.
1766 ac_fn_c_check_header_compile ()
1767 {
1768 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1769 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1770 $as_echo_n "checking for $2... " >&6; }
1771 if eval \${$3+:} false; then :
1772 $as_echo_n "(cached) " >&6
1773 else
1774 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1775 /* end confdefs.h. */
1776 $4
1777 #include <$2>
1778 _ACEOF
1779 if ac_fn_c_try_compile "$LINENO"; then :
1780 eval "$3=yes"
1781 else
1782 eval "$3=no"
1783 fi
1784 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1785 fi
1786 eval ac_res=\$$3
1787 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1788 $as_echo "$ac_res" >&6; }
1789 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1790
1791 } # ac_fn_c_check_header_compile
1792
1793 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
1794 # -------------------------------------------
1795 # Tests whether TYPE exists after having included INCLUDES, setting cache
1796 # variable VAR accordingly.
1797 ac_fn_c_check_type ()
1798 {
1799 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1800 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1801 $as_echo_n "checking for $2... " >&6; }
1802 if eval \${$3+:} false; then :
1803 $as_echo_n "(cached) " >&6
1804 else
1805 eval "$3=no"
1806 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1807 /* end confdefs.h. */
1808 $4
1809 int
1810 main ()
1811 {
1812 if (sizeof ($2))
1813 return 0;
1814 ;
1815 return 0;
1816 }
1817 _ACEOF
1818 if ac_fn_c_try_compile "$LINENO"; then :
1819 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1820 /* end confdefs.h. */
1821 $4
1822 int
1823 main ()
1824 {
1825 if (sizeof (($2)))
1826 return 0;
1827 ;
1828 return 0;
1829 }
1830 _ACEOF
1831 if ac_fn_c_try_compile "$LINENO"; then :
1832
1833 else
1834 eval "$3=yes"
1835 fi
1836 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1837 fi
1838 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1839 fi
1840 eval ac_res=\$$3
1841 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1842 $as_echo "$ac_res" >&6; }
1843 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1844
1845 } # ac_fn_c_check_type
1846
1847 # ac_fn_c_try_link LINENO
1848 # -----------------------
1849 # Try to link conftest.$ac_ext, and return whether this succeeded.
1850 ac_fn_c_try_link ()
1851 {
1852 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1853 rm -f conftest.$ac_objext conftest$ac_exeext
1854 if { { ac_try="$ac_link"
1855 case "(($ac_try" in
1856 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1857 *) ac_try_echo=$ac_try;;
1858 esac
1859 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1860 $as_echo "$ac_try_echo"; } >&5
1861 (eval "$ac_link") 2>conftest.err
1862 ac_status=$?
1863 if test -s conftest.err; then
1864 grep -v '^ *+' conftest.err >conftest.er1
1865 cat conftest.er1 >&5
1866 mv -f conftest.er1 conftest.err
1867 fi
1868 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1869 test $ac_status = 0; } && {
1870 test -z "$ac_c_werror_flag" ||
1871 test ! -s conftest.err
1872 } && test -s conftest$ac_exeext && {
1873 test "$cross_compiling" = yes ||
1874 test -x conftest$ac_exeext
1875 }; then :
1876 ac_retval=0
1877 else
1878 $as_echo "$as_me: failed program was:" >&5
1879 sed 's/^/| /' conftest.$ac_ext >&5
1880
1881 ac_retval=1
1882 fi
1883 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
1884 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
1885 # interfere with the next link command; also delete a directory that is
1886 # left behind by Apple's compiler. We do this before executing the actions.
1887 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1888 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1889 as_fn_set_status $ac_retval
1890
1891 } # ac_fn_c_try_link
1892
1893 # ac_fn_c_check_func LINENO FUNC VAR
1894 # ----------------------------------
1895 # Tests whether FUNC exists, setting the cache variable VAR accordingly
1896 ac_fn_c_check_func ()
1897 {
1898 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1899 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1900 $as_echo_n "checking for $2... " >&6; }
1901 if eval \${$3+:} false; then :
1902 $as_echo_n "(cached) " >&6
1903 else
1904 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1905 /* end confdefs.h. */
1906 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
1907 For example, HP-UX 11i <limits.h> declares gettimeofday. */
1908 #define $2 innocuous_$2
1909
1910 /* System header to define __stub macros and hopefully few prototypes,
1911 which can conflict with char $2 (); below.
1912 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
1913 <limits.h> exists even on freestanding compilers. */
1914
1915 #ifdef __STDC__
1916 # include <limits.h>
1917 #else
1918 # include <assert.h>
1919 #endif
1920
1921 #undef $2
1922
1923 /* Override any GCC internal prototype to avoid an error.
1924 Use char because int might match the return type of a GCC
1925 builtin and then its argument prototype would still apply. */
1926 #ifdef __cplusplus
1927 extern "C"
1928 #endif
1929 char $2 ();
1930 /* The GNU C library defines this for functions which it implements
1931 to always fail with ENOSYS. Some functions are actually named
1932 something starting with __ and the normal name is an alias. */
1933 #if defined __stub_$2 || defined __stub___$2
1934 choke me
1935 #endif
1936
1937 int
1938 main ()
1939 {
1940 return $2 ();
1941 ;
1942 return 0;
1943 }
1944 _ACEOF
1945 if ac_fn_c_try_link "$LINENO"; then :
1946 eval "$3=yes"
1947 else
1948 eval "$3=no"
1949 fi
1950 rm -f core conftest.err conftest.$ac_objext \
1951 conftest$ac_exeext conftest.$ac_ext
1952 fi
1953 eval ac_res=\$$3
1954 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1955 $as_echo "$ac_res" >&6; }
1956 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1957
1958 } # ac_fn_c_check_func
1959
1960 # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
1961 # ---------------------------------------------
1962 # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
1963 # accordingly.
1964 ac_fn_c_check_decl ()
1965 {
1966 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1967 as_decl_name=`echo $2|sed 's/ *(.*//'`
1968 as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
1969 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
1970 $as_echo_n "checking whether $as_decl_name is declared... " >&6; }
1971 if eval \${$3+:} false; then :
1972 $as_echo_n "(cached) " >&6
1973 else
1974 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1975 /* end confdefs.h. */
1976 $4
1977 int
1978 main ()
1979 {
1980 #ifndef $as_decl_name
1981 #ifdef __cplusplus
1982 (void) $as_decl_use;
1983 #else
1984 (void) $as_decl_name;
1985 #endif
1986 #endif
1987
1988 ;
1989 return 0;
1990 }
1991 _ACEOF
1992 if ac_fn_c_try_compile "$LINENO"; then :
1993 eval "$3=yes"
1994 else
1995 eval "$3=no"
1996 fi
1997 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1998 fi
1999 eval ac_res=\$$3
2000 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2001 $as_echo "$ac_res" >&6; }
2002 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2003
2004 } # ac_fn_c_check_decl
2005
2006 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2007 # ----------------------------------------------------
2008 # Tries to find if the field MEMBER exists in type AGGR, after including
2009 # INCLUDES, setting cache variable VAR accordingly.
2010 ac_fn_c_check_member ()
2011 {
2012 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2013 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2014 $as_echo_n "checking for $2.$3... " >&6; }
2015 if eval \${$4+:} false; then :
2016 $as_echo_n "(cached) " >&6
2017 else
2018 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2019 /* end confdefs.h. */
2020 $5
2021 int
2022 main ()
2023 {
2024 static $2 ac_aggr;
2025 if (ac_aggr.$3)
2026 return 0;
2027 ;
2028 return 0;
2029 }
2030 _ACEOF
2031 if ac_fn_c_try_compile "$LINENO"; then :
2032 eval "$4=yes"
2033 else
2034 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2035 /* end confdefs.h. */
2036 $5
2037 int
2038 main ()
2039 {
2040 static $2 ac_aggr;
2041 if (sizeof ac_aggr.$3)
2042 return 0;
2043 ;
2044 return 0;
2045 }
2046 _ACEOF
2047 if ac_fn_c_try_compile "$LINENO"; then :
2048 eval "$4=yes"
2049 else
2050 eval "$4=no"
2051 fi
2052 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2053 fi
2054 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2055 fi
2056 eval ac_res=\$$4
2057 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2058 $as_echo "$ac_res" >&6; }
2059 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2060
2061 } # ac_fn_c_check_member
2062
2063 # ac_fn_cxx_try_link LINENO
2064 # -------------------------
2065 # Try to link conftest.$ac_ext, and return whether this succeeded.
2066 ac_fn_cxx_try_link ()
2067 {
2068 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2069 rm -f conftest.$ac_objext conftest$ac_exeext
2070 if { { ac_try="$ac_link"
2071 case "(($ac_try" in
2072 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2073 *) ac_try_echo=$ac_try;;
2074 esac
2075 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2076 $as_echo "$ac_try_echo"; } >&5
2077 (eval "$ac_link") 2>conftest.err
2078 ac_status=$?
2079 if test -s conftest.err; then
2080 grep -v '^ *+' conftest.err >conftest.er1
2081 cat conftest.er1 >&5
2082 mv -f conftest.er1 conftest.err
2083 fi
2084 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2085 test $ac_status = 0; } && {
2086 test -z "$ac_cxx_werror_flag" ||
2087 test ! -s conftest.err
2088 } && test -s conftest$ac_exeext && {
2089 test "$cross_compiling" = yes ||
2090 test -x conftest$ac_exeext
2091 }; then :
2092 ac_retval=0
2093 else
2094 $as_echo "$as_me: failed program was:" >&5
2095 sed 's/^/| /' conftest.$ac_ext >&5
2096
2097 ac_retval=1
2098 fi
2099 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2100 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2101 # interfere with the next link command; also delete a directory that is
2102 # left behind by Apple's compiler. We do this before executing the actions.
2103 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2104 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2105 as_fn_set_status $ac_retval
2106
2107 } # ac_fn_cxx_try_link
2108
2109 # ac_fn_cxx_check_func LINENO FUNC VAR
2110 # ------------------------------------
2111 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2112 ac_fn_cxx_check_func ()
2113 {
2114 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2115 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2116 $as_echo_n "checking for $2... " >&6; }
2117 if eval \${$3+:} false; then :
2118 $as_echo_n "(cached) " >&6
2119 else
2120 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2121 /* end confdefs.h. */
2122 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2123 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2124 #define $2 innocuous_$2
2125
2126 /* System header to define __stub macros and hopefully few prototypes,
2127 which can conflict with char $2 (); below.
2128 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2129 <limits.h> exists even on freestanding compilers. */
2130
2131 #ifdef __STDC__
2132 # include <limits.h>
2133 #else
2134 # include <assert.h>
2135 #endif
2136
2137 #undef $2
2138
2139 /* Override any GCC internal prototype to avoid an error.
2140 Use char because int might match the return type of a GCC
2141 builtin and then its argument prototype would still apply. */
2142 #ifdef __cplusplus
2143 extern "C"
2144 #endif
2145 char $2 ();
2146 /* The GNU C library defines this for functions which it implements
2147 to always fail with ENOSYS. Some functions are actually named
2148 something starting with __ and the normal name is an alias. */
2149 #if defined __stub_$2 || defined __stub___$2
2150 choke me
2151 #endif
2152
2153 int
2154 main ()
2155 {
2156 return $2 ();
2157 ;
2158 return 0;
2159 }
2160 _ACEOF
2161 if ac_fn_cxx_try_link "$LINENO"; then :
2162 eval "$3=yes"
2163 else
2164 eval "$3=no"
2165 fi
2166 rm -f core conftest.err conftest.$ac_objext \
2167 conftest$ac_exeext conftest.$ac_ext
2168 fi
2169 eval ac_res=\$$3
2170 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2171 $as_echo "$ac_res" >&6; }
2172 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2173
2174 } # ac_fn_cxx_check_func
2175
2176 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2177 # --------------------------------------------
2178 # Tries to find the compile-time value of EXPR in a program that includes
2179 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2180 # computed
2181 ac_fn_c_compute_int ()
2182 {
2183 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2184 if test "$cross_compiling" = yes; then
2185 # Depending upon the size, compute the lo and hi bounds.
2186 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2187 /* end confdefs.h. */
2188 $4
2189 int
2190 main ()
2191 {
2192 static int test_array [1 - 2 * !(($2) >= 0)];
2193 test_array [0] = 0;
2194 return test_array [0];
2195
2196 ;
2197 return 0;
2198 }
2199 _ACEOF
2200 if ac_fn_c_try_compile "$LINENO"; then :
2201 ac_lo=0 ac_mid=0
2202 while :; do
2203 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2204 /* end confdefs.h. */
2205 $4
2206 int
2207 main ()
2208 {
2209 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2210 test_array [0] = 0;
2211 return test_array [0];
2212
2213 ;
2214 return 0;
2215 }
2216 _ACEOF
2217 if ac_fn_c_try_compile "$LINENO"; then :
2218 ac_hi=$ac_mid; break
2219 else
2220 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2221 if test $ac_lo -le $ac_mid; then
2222 ac_lo= ac_hi=
2223 break
2224 fi
2225 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2226 fi
2227 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2228 done
2229 else
2230 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2231 /* end confdefs.h. */
2232 $4
2233 int
2234 main ()
2235 {
2236 static int test_array [1 - 2 * !(($2) < 0)];
2237 test_array [0] = 0;
2238 return test_array [0];
2239
2240 ;
2241 return 0;
2242 }
2243 _ACEOF
2244 if ac_fn_c_try_compile "$LINENO"; then :
2245 ac_hi=-1 ac_mid=-1
2246 while :; do
2247 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2248 /* end confdefs.h. */
2249 $4
2250 int
2251 main ()
2252 {
2253 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2254 test_array [0] = 0;
2255 return test_array [0];
2256
2257 ;
2258 return 0;
2259 }
2260 _ACEOF
2261 if ac_fn_c_try_compile "$LINENO"; then :
2262 ac_lo=$ac_mid; break
2263 else
2264 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2265 if test $ac_mid -le $ac_hi; then
2266 ac_lo= ac_hi=
2267 break
2268 fi
2269 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2270 fi
2271 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2272 done
2273 else
2274 ac_lo= ac_hi=
2275 fi
2276 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2277 fi
2278 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2279 # Binary search between lo and hi bounds.
2280 while test "x$ac_lo" != "x$ac_hi"; do
2281 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2282 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2283 /* end confdefs.h. */
2284 $4
2285 int
2286 main ()
2287 {
2288 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2289 test_array [0] = 0;
2290 return test_array [0];
2291
2292 ;
2293 return 0;
2294 }
2295 _ACEOF
2296 if ac_fn_c_try_compile "$LINENO"; then :
2297 ac_hi=$ac_mid
2298 else
2299 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2300 fi
2301 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2302 done
2303 case $ac_lo in #((
2304 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2305 '') ac_retval=1 ;;
2306 esac
2307 else
2308 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2309 /* end confdefs.h. */
2310 $4
2311 static long int longval () { return $2; }
2312 static unsigned long int ulongval () { return $2; }
2313 #include <stdio.h>
2314 #include <stdlib.h>
2315 int
2316 main ()
2317 {
2318
2319 FILE *f = fopen ("conftest.val", "w");
2320 if (! f)
2321 return 1;
2322 if (($2) < 0)
2323 {
2324 long int i = longval ();
2325 if (i != ($2))
2326 return 1;
2327 fprintf (f, "%ld", i);
2328 }
2329 else
2330 {
2331 unsigned long int i = ulongval ();
2332 if (i != ($2))
2333 return 1;
2334 fprintf (f, "%lu", i);
2335 }
2336 /* Do not output a trailing newline, as this causes \r\n confusion
2337 on some platforms. */
2338 return ferror (f) || fclose (f) != 0;
2339
2340 ;
2341 return 0;
2342 }
2343 _ACEOF
2344 if ac_fn_c_try_run "$LINENO"; then :
2345 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2346 else
2347 ac_retval=1
2348 fi
2349 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2350 conftest.$ac_objext conftest.beam conftest.$ac_ext
2351 rm -f conftest.val
2352
2353 fi
2354 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2355 as_fn_set_status $ac_retval
2356
2357 } # ac_fn_c_compute_int
2358 cat >config.log <<_ACEOF
2359 This file contains any messages produced by compilers while
2360 running configure, to aid debugging if configure makes a mistake.
2361
2362 It was created by $as_me, which was
2363 generated by GNU Autoconf 2.69. Invocation command line was
2364
2365 $ $0 $@
2366
2367 _ACEOF
2368 exec 5>>config.log
2369 {
2370 cat <<_ASUNAME
2371 ## --------- ##
2372 ## Platform. ##
2373 ## --------- ##
2374
2375 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2376 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2377 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2378 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2379 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2380
2381 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2382 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
2383
2384 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2385 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2386 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2387 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2388 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2389 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2390 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
2391
2392 _ASUNAME
2393
2394 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2395 for as_dir in $PATH
2396 do
2397 IFS=$as_save_IFS
2398 test -z "$as_dir" && as_dir=.
2399 $as_echo "PATH: $as_dir"
2400 done
2401 IFS=$as_save_IFS
2402
2403 } >&5
2404
2405 cat >&5 <<_ACEOF
2406
2407
2408 ## ----------- ##
2409 ## Core tests. ##
2410 ## ----------- ##
2411
2412 _ACEOF
2413
2414
2415 # Keep a trace of the command line.
2416 # Strip out --no-create and --no-recursion so they do not pile up.
2417 # Strip out --silent because we don't want to record it for future runs.
2418 # Also quote any args containing shell meta-characters.
2419 # Make two passes to allow for proper duplicate-argument suppression.
2420 ac_configure_args=
2421 ac_configure_args0=
2422 ac_configure_args1=
2423 ac_must_keep_next=false
2424 for ac_pass in 1 2
2425 do
2426 for ac_arg
2427 do
2428 case $ac_arg in
2429 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2430 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2431 | -silent | --silent | --silen | --sile | --sil)
2432 continue ;;
2433 *\'*)
2434 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2435 esac
2436 case $ac_pass in
2437 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2438 2)
2439 as_fn_append ac_configure_args1 " '$ac_arg'"
2440 if test $ac_must_keep_next = true; then
2441 ac_must_keep_next=false # Got value, back to normal.
2442 else
2443 case $ac_arg in
2444 *=* | --config-cache | -C | -disable-* | --disable-* \
2445 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2446 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2447 | -with-* | --with-* | -without-* | --without-* | --x)
2448 case "$ac_configure_args0 " in
2449 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2450 esac
2451 ;;
2452 -* ) ac_must_keep_next=true ;;
2453 esac
2454 fi
2455 as_fn_append ac_configure_args " '$ac_arg'"
2456 ;;
2457 esac
2458 done
2459 done
2460 { ac_configure_args0=; unset ac_configure_args0;}
2461 { ac_configure_args1=; unset ac_configure_args1;}
2462
2463 # When interrupted or exit'd, cleanup temporary files, and complete
2464 # config.log. We remove comments because anyway the quotes in there
2465 # would cause problems or look ugly.
2466 # WARNING: Use '\'' to represent an apostrophe within the trap.
2467 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2468 trap 'exit_status=$?
2469 # Save into config.log some information that might help in debugging.
2470 {
2471 echo
2472
2473 $as_echo "## ---------------- ##
2474 ## Cache variables. ##
2475 ## ---------------- ##"
2476 echo
2477 # The following way of writing the cache mishandles newlines in values,
2478 (
2479 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2480 eval ac_val=\$$ac_var
2481 case $ac_val in #(
2482 *${as_nl}*)
2483 case $ac_var in #(
2484 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2485 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2486 esac
2487 case $ac_var in #(
2488 _ | IFS | as_nl) ;; #(
2489 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2490 *) { eval $ac_var=; unset $ac_var;} ;;
2491 esac ;;
2492 esac
2493 done
2494 (set) 2>&1 |
2495 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2496 *${as_nl}ac_space=\ *)
2497 sed -n \
2498 "s/'\''/'\''\\\\'\'''\''/g;
2499 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2500 ;; #(
2501 *)
2502 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2503 ;;
2504 esac |
2505 sort
2506 )
2507 echo
2508
2509 $as_echo "## ----------------- ##
2510 ## Output variables. ##
2511 ## ----------------- ##"
2512 echo
2513 for ac_var in $ac_subst_vars
2514 do
2515 eval ac_val=\$$ac_var
2516 case $ac_val in
2517 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2518 esac
2519 $as_echo "$ac_var='\''$ac_val'\''"
2520 done | sort
2521 echo
2522
2523 if test -n "$ac_subst_files"; then
2524 $as_echo "## ------------------- ##
2525 ## File substitutions. ##
2526 ## ------------------- ##"
2527 echo
2528 for ac_var in $ac_subst_files
2529 do
2530 eval ac_val=\$$ac_var
2531 case $ac_val in
2532 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2533 esac
2534 $as_echo "$ac_var='\''$ac_val'\''"
2535 done | sort
2536 echo
2537 fi
2538
2539 if test -s confdefs.h; then
2540 $as_echo "## ----------- ##
2541 ## confdefs.h. ##
2542 ## ----------- ##"
2543 echo
2544 cat confdefs.h
2545 echo
2546 fi
2547 test "$ac_signal" != 0 &&
2548 $as_echo "$as_me: caught signal $ac_signal"
2549 $as_echo "$as_me: exit $exit_status"
2550 } >&5
2551 rm -f core *.core core.conftest.* &&
2552 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2553 exit $exit_status
2554 ' 0
2555 for ac_signal in 1 2 13 15; do
2556 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2557 done
2558 ac_signal=0
2559
2560 # confdefs.h avoids OS command line length limits that DEFS can exceed.
2561 rm -f -r conftest* confdefs.h
2562
2563 $as_echo "/* confdefs.h */" > confdefs.h
2564
2565 # Predefined preprocessor variables.
2566
2567 cat >>confdefs.h <<_ACEOF
2568 #define PACKAGE_NAME "$PACKAGE_NAME"
2569 _ACEOF
2570
2571 cat >>confdefs.h <<_ACEOF
2572 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2573 _ACEOF
2574
2575 cat >>confdefs.h <<_ACEOF
2576 #define PACKAGE_VERSION "$PACKAGE_VERSION"
2577 _ACEOF
2578
2579 cat >>confdefs.h <<_ACEOF
2580 #define PACKAGE_STRING "$PACKAGE_STRING"
2581 _ACEOF
2582
2583 cat >>confdefs.h <<_ACEOF
2584 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2585 _ACEOF
2586
2587 cat >>confdefs.h <<_ACEOF
2588 #define PACKAGE_URL "$PACKAGE_URL"
2589 _ACEOF
2590
2591
2592 # Let the site file select an alternate cache file if it wants to.
2593 # Prefer an explicitly selected file to automatically selected ones.
2594 ac_site_file1=NONE
2595 ac_site_file2=NONE
2596 if test -n "$CONFIG_SITE"; then
2597 # We do not want a PATH search for config.site.
2598 case $CONFIG_SITE in #((
2599 -*) ac_site_file1=./$CONFIG_SITE;;
2600 */*) ac_site_file1=$CONFIG_SITE;;
2601 *) ac_site_file1=./$CONFIG_SITE;;
2602 esac
2603 elif test "x$prefix" != xNONE; then
2604 ac_site_file1=$prefix/share/config.site
2605 ac_site_file2=$prefix/etc/config.site
2606 else
2607 ac_site_file1=$ac_default_prefix/share/config.site
2608 ac_site_file2=$ac_default_prefix/etc/config.site
2609 fi
2610 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2611 do
2612 test "x$ac_site_file" = xNONE && continue
2613 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
2614 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2615 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
2616 sed 's/^/| /' "$ac_site_file" >&5
2617 . "$ac_site_file" \
2618 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2619 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2620 as_fn_error $? "failed to load site script $ac_site_file
2621 See \`config.log' for more details" "$LINENO" 5; }
2622 fi
2623 done
2624
2625 if test -r "$cache_file"; then
2626 # Some versions of bash will fail to source /dev/null (special files
2627 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
2628 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2629 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2630 $as_echo "$as_me: loading cache $cache_file" >&6;}
2631 case $cache_file in
2632 [\\/]* | ?:[\\/]* ) . "$cache_file";;
2633 *) . "./$cache_file";;
2634 esac
2635 fi
2636 else
2637 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2638 $as_echo "$as_me: creating cache $cache_file" >&6;}
2639 >$cache_file
2640 fi
2641
2642 as_fn_append ac_header_list " stdlib.h"
2643 as_fn_append ac_header_list " unistd.h"
2644 as_fn_append ac_header_list " sys/param.h"
2645 # Check that the precious variables saved in the cache have kept the same
2646 # value.
2647 ac_cache_corrupted=false
2648 for ac_var in $ac_precious_vars; do
2649 eval ac_old_set=\$ac_cv_env_${ac_var}_set
2650 eval ac_new_set=\$ac_env_${ac_var}_set
2651 eval ac_old_val=\$ac_cv_env_${ac_var}_value
2652 eval ac_new_val=\$ac_env_${ac_var}_value
2653 case $ac_old_set,$ac_new_set in
2654 set,)
2655 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2656 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2657 ac_cache_corrupted=: ;;
2658 ,set)
2659 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2660 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2661 ac_cache_corrupted=: ;;
2662 ,);;
2663 *)
2664 if test "x$ac_old_val" != "x$ac_new_val"; then
2665 # differences in whitespace do not lead to failure.
2666 ac_old_val_w=`echo x $ac_old_val`
2667 ac_new_val_w=`echo x $ac_new_val`
2668 if test "$ac_old_val_w" != "$ac_new_val_w"; then
2669 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2670 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2671 ac_cache_corrupted=:
2672 else
2673 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2674 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2675 eval $ac_var=\$ac_old_val
2676 fi
2677 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
2678 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
2679 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
2680 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
2681 fi;;
2682 esac
2683 # Pass precious variables to config.status.
2684 if test "$ac_new_set" = set; then
2685 case $ac_new_val in
2686 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2687 *) ac_arg=$ac_var=$ac_new_val ;;
2688 esac
2689 case " $ac_configure_args " in
2690 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
2691 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2692 esac
2693 fi
2694 done
2695 if $ac_cache_corrupted; then
2696 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2697 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2698 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2699 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2700 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
2701 fi
2702 ## -------------------- ##
2703 ## Main body of script. ##
2704 ## -------------------- ##
2705
2706 ac_ext=c
2707 ac_cpp='$CPP $CPPFLAGS'
2708 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2709 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2710 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2711
2712
2713
2714
2715
2716
2717
2718 ac_config_headers="$ac_config_headers config.h:config.in"
2719
2720
2721
2722 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5
2723 $as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
2724 # Check whether --enable-maintainer-mode was given.
2725 if test "${enable_maintainer_mode+set}" = set; then :
2726 enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
2727 else
2728 USE_MAINTAINER_MODE=no
2729 fi
2730
2731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5
2732 $as_echo "$USE_MAINTAINER_MODE" >&6; }
2733 if test $USE_MAINTAINER_MODE = yes; then
2734 MAINTAINER_MODE_TRUE=
2735 MAINTAINER_MODE_FALSE='#'
2736 else
2737 MAINTAINER_MODE_TRUE='#'
2738 MAINTAINER_MODE_FALSE=
2739 fi
2740
2741 MAINT=$MAINTAINER_MODE_TRUE
2742
2743
2744
2745 ac_ext=c
2746 ac_cpp='$CPP $CPPFLAGS'
2747 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2748 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2749 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2750 if test -n "$ac_tool_prefix"; then
2751 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
2752 set dummy ${ac_tool_prefix}gcc; ac_word=$2
2753 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2754 $as_echo_n "checking for $ac_word... " >&6; }
2755 if ${ac_cv_prog_CC+:} false; then :
2756 $as_echo_n "(cached) " >&6
2757 else
2758 if test -n "$CC"; then
2759 ac_cv_prog_CC="$CC" # Let the user override the test.
2760 else
2761 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2762 for as_dir in $PATH
2763 do
2764 IFS=$as_save_IFS
2765 test -z "$as_dir" && as_dir=.
2766 for ac_exec_ext in '' $ac_executable_extensions; do
2767 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2768 ac_cv_prog_CC="${ac_tool_prefix}gcc"
2769 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2770 break 2
2771 fi
2772 done
2773 done
2774 IFS=$as_save_IFS
2775
2776 fi
2777 fi
2778 CC=$ac_cv_prog_CC
2779 if test -n "$CC"; then
2780 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2781 $as_echo "$CC" >&6; }
2782 else
2783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2784 $as_echo "no" >&6; }
2785 fi
2786
2787
2788 fi
2789 if test -z "$ac_cv_prog_CC"; then
2790 ac_ct_CC=$CC
2791 # Extract the first word of "gcc", so it can be a program name with args.
2792 set dummy gcc; ac_word=$2
2793 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2794 $as_echo_n "checking for $ac_word... " >&6; }
2795 if ${ac_cv_prog_ac_ct_CC+:} false; then :
2796 $as_echo_n "(cached) " >&6
2797 else
2798 if test -n "$ac_ct_CC"; then
2799 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2800 else
2801 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2802 for as_dir in $PATH
2803 do
2804 IFS=$as_save_IFS
2805 test -z "$as_dir" && as_dir=.
2806 for ac_exec_ext in '' $ac_executable_extensions; do
2807 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2808 ac_cv_prog_ac_ct_CC="gcc"
2809 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2810 break 2
2811 fi
2812 done
2813 done
2814 IFS=$as_save_IFS
2815
2816 fi
2817 fi
2818 ac_ct_CC=$ac_cv_prog_ac_ct_CC
2819 if test -n "$ac_ct_CC"; then
2820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
2821 $as_echo "$ac_ct_CC" >&6; }
2822 else
2823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2824 $as_echo "no" >&6; }
2825 fi
2826
2827 if test "x$ac_ct_CC" = x; then
2828 CC=""
2829 else
2830 case $cross_compiling:$ac_tool_warned in
2831 yes:)
2832 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
2833 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
2834 ac_tool_warned=yes ;;
2835 esac
2836 CC=$ac_ct_CC
2837 fi
2838 else
2839 CC="$ac_cv_prog_CC"
2840 fi
2841
2842 if test -z "$CC"; then
2843 if test -n "$ac_tool_prefix"; then
2844 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
2845 set dummy ${ac_tool_prefix}cc; ac_word=$2
2846 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2847 $as_echo_n "checking for $ac_word... " >&6; }
2848 if ${ac_cv_prog_CC+:} false; then :
2849 $as_echo_n "(cached) " >&6
2850 else
2851 if test -n "$CC"; then
2852 ac_cv_prog_CC="$CC" # Let the user override the test.
2853 else
2854 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2855 for as_dir in $PATH
2856 do
2857 IFS=$as_save_IFS
2858 test -z "$as_dir" && as_dir=.
2859 for ac_exec_ext in '' $ac_executable_extensions; do
2860 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2861 ac_cv_prog_CC="${ac_tool_prefix}cc"
2862 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2863 break 2
2864 fi
2865 done
2866 done
2867 IFS=$as_save_IFS
2868
2869 fi
2870 fi
2871 CC=$ac_cv_prog_CC
2872 if test -n "$CC"; then
2873 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2874 $as_echo "$CC" >&6; }
2875 else
2876 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2877 $as_echo "no" >&6; }
2878 fi
2879
2880
2881 fi
2882 fi
2883 if test -z "$CC"; then
2884 # Extract the first word of "cc", so it can be a program name with args.
2885 set dummy cc; ac_word=$2
2886 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2887 $as_echo_n "checking for $ac_word... " >&6; }
2888 if ${ac_cv_prog_CC+:} false; then :
2889 $as_echo_n "(cached) " >&6
2890 else
2891 if test -n "$CC"; then
2892 ac_cv_prog_CC="$CC" # Let the user override the test.
2893 else
2894 ac_prog_rejected=no
2895 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2896 for as_dir in $PATH
2897 do
2898 IFS=$as_save_IFS
2899 test -z "$as_dir" && as_dir=.
2900 for ac_exec_ext in '' $ac_executable_extensions; do
2901 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2902 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
2903 ac_prog_rejected=yes
2904 continue
2905 fi
2906 ac_cv_prog_CC="cc"
2907 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2908 break 2
2909 fi
2910 done
2911 done
2912 IFS=$as_save_IFS
2913
2914 if test $ac_prog_rejected = yes; then
2915 # We found a bogon in the path, so make sure we never use it.
2916 set dummy $ac_cv_prog_CC
2917 shift
2918 if test $# != 0; then
2919 # We chose a different compiler from the bogus one.
2920 # However, it has the same basename, so the bogon will be chosen
2921 # first if we set CC to just the basename; use the full file name.
2922 shift
2923 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
2924 fi
2925 fi
2926 fi
2927 fi
2928 CC=$ac_cv_prog_CC
2929 if test -n "$CC"; then
2930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2931 $as_echo "$CC" >&6; }
2932 else
2933 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2934 $as_echo "no" >&6; }
2935 fi
2936
2937
2938 fi
2939 if test -z "$CC"; then
2940 if test -n "$ac_tool_prefix"; then
2941 for ac_prog in cl.exe
2942 do
2943 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2944 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
2945 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2946 $as_echo_n "checking for $ac_word... " >&6; }
2947 if ${ac_cv_prog_CC+:} false; then :
2948 $as_echo_n "(cached) " >&6
2949 else
2950 if test -n "$CC"; then
2951 ac_cv_prog_CC="$CC" # Let the user override the test.
2952 else
2953 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2954 for as_dir in $PATH
2955 do
2956 IFS=$as_save_IFS
2957 test -z "$as_dir" && as_dir=.
2958 for ac_exec_ext in '' $ac_executable_extensions; do
2959 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2960 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
2961 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2962 break 2
2963 fi
2964 done
2965 done
2966 IFS=$as_save_IFS
2967
2968 fi
2969 fi
2970 CC=$ac_cv_prog_CC
2971 if test -n "$CC"; then
2972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2973 $as_echo "$CC" >&6; }
2974 else
2975 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2976 $as_echo "no" >&6; }
2977 fi
2978
2979
2980 test -n "$CC" && break
2981 done
2982 fi
2983 if test -z "$CC"; then
2984 ac_ct_CC=$CC
2985 for ac_prog in cl.exe
2986 do
2987 # Extract the first word of "$ac_prog", so it can be a program name with args.
2988 set dummy $ac_prog; ac_word=$2
2989 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2990 $as_echo_n "checking for $ac_word... " >&6; }
2991 if ${ac_cv_prog_ac_ct_CC+:} false; then :
2992 $as_echo_n "(cached) " >&6
2993 else
2994 if test -n "$ac_ct_CC"; then
2995 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2996 else
2997 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2998 for as_dir in $PATH
2999 do
3000 IFS=$as_save_IFS
3001 test -z "$as_dir" && as_dir=.
3002 for ac_exec_ext in '' $ac_executable_extensions; do
3003 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3004 ac_cv_prog_ac_ct_CC="$ac_prog"
3005 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3006 break 2
3007 fi
3008 done
3009 done
3010 IFS=$as_save_IFS
3011
3012 fi
3013 fi
3014 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3015 if test -n "$ac_ct_CC"; then
3016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3017 $as_echo "$ac_ct_CC" >&6; }
3018 else
3019 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3020 $as_echo "no" >&6; }
3021 fi
3022
3023
3024 test -n "$ac_ct_CC" && break
3025 done
3026
3027 if test "x$ac_ct_CC" = x; then
3028 CC=""
3029 else
3030 case $cross_compiling:$ac_tool_warned in
3031 yes:)
3032 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3033 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3034 ac_tool_warned=yes ;;
3035 esac
3036 CC=$ac_ct_CC
3037 fi
3038 fi
3039
3040 fi
3041
3042
3043 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3044 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3045 as_fn_error $? "no acceptable C compiler found in \$PATH
3046 See \`config.log' for more details" "$LINENO" 5; }
3047
3048 # Provide some information about the compiler.
3049 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
3050 set X $ac_compile
3051 ac_compiler=$2
3052 for ac_option in --version -v -V -qversion; do
3053 { { ac_try="$ac_compiler $ac_option >&5"
3054 case "(($ac_try" in
3055 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3056 *) ac_try_echo=$ac_try;;
3057 esac
3058 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3059 $as_echo "$ac_try_echo"; } >&5
3060 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3061 ac_status=$?
3062 if test -s conftest.err; then
3063 sed '10a\
3064 ... rest of stderr output deleted ...
3065 10q' conftest.err >conftest.er1
3066 cat conftest.er1 >&5
3067 fi
3068 rm -f conftest.er1 conftest.err
3069 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3070 test $ac_status = 0; }
3071 done
3072
3073 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3074 /* end confdefs.h. */
3075
3076 int
3077 main ()
3078 {
3079
3080 ;
3081 return 0;
3082 }
3083 _ACEOF
3084 ac_clean_files_save=$ac_clean_files
3085 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
3086 # Try to create an executable without -o first, disregard a.out.
3087 # It will help us diagnose broken compilers, and finding out an intuition
3088 # of exeext.
3089 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
3090 $as_echo_n "checking whether the C compiler works... " >&6; }
3091 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3092
3093 # The possible output files:
3094 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3095
3096 ac_rmfiles=
3097 for ac_file in $ac_files
3098 do
3099 case $ac_file in
3100 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3101 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3102 esac
3103 done
3104 rm -f $ac_rmfiles
3105
3106 if { { ac_try="$ac_link_default"
3107 case "(($ac_try" in
3108 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3109 *) ac_try_echo=$ac_try;;
3110 esac
3111 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3112 $as_echo "$ac_try_echo"; } >&5
3113 (eval "$ac_link_default") 2>&5
3114 ac_status=$?
3115 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3116 test $ac_status = 0; }; then :
3117 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3118 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3119 # in a Makefile. We should not override ac_cv_exeext if it was cached,
3120 # so that the user can short-circuit this test for compilers unknown to
3121 # Autoconf.
3122 for ac_file in $ac_files ''
3123 do
3124 test -f "$ac_file" || continue
3125 case $ac_file in
3126 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
3127 ;;
3128 [ab].out )
3129 # We found the default executable, but exeext='' is most
3130 # certainly right.
3131 break;;
3132 *.* )
3133 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3134 then :; else
3135 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3136 fi
3137 # We set ac_cv_exeext here because the later test for it is not
3138 # safe: cross compilers may not add the suffix if given an `-o'
3139 # argument, so we may need to know it at that point already.
3140 # Even if this section looks crufty: it has the advantage of
3141 # actually working.
3142 break;;
3143 * )
3144 break;;
3145 esac
3146 done
3147 test "$ac_cv_exeext" = no && ac_cv_exeext=
3148
3149 else
3150 ac_file=''
3151 fi
3152 if test -z "$ac_file"; then :
3153 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3154 $as_echo "no" >&6; }
3155 $as_echo "$as_me: failed program was:" >&5
3156 sed 's/^/| /' conftest.$ac_ext >&5
3157
3158 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3159 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3160 as_fn_error 77 "C compiler cannot create executables
3161 See \`config.log' for more details" "$LINENO" 5; }
3162 else
3163 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3164 $as_echo "yes" >&6; }
3165 fi
3166 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
3167 $as_echo_n "checking for C compiler default output file name... " >&6; }
3168 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
3169 $as_echo "$ac_file" >&6; }
3170 ac_exeext=$ac_cv_exeext
3171
3172 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
3173 ac_clean_files=$ac_clean_files_save
3174 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
3175 $as_echo_n "checking for suffix of executables... " >&6; }
3176 if { { ac_try="$ac_link"
3177 case "(($ac_try" in
3178 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3179 *) ac_try_echo=$ac_try;;
3180 esac
3181 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3182 $as_echo "$ac_try_echo"; } >&5
3183 (eval "$ac_link") 2>&5
3184 ac_status=$?
3185 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3186 test $ac_status = 0; }; then :
3187 # If both `conftest.exe' and `conftest' are `present' (well, observable)
3188 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
3189 # work properly (i.e., refer to `conftest.exe'), while it won't with
3190 # `rm'.
3191 for ac_file in conftest.exe conftest conftest.*; do
3192 test -f "$ac_file" || continue
3193 case $ac_file in
3194 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3195 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3196 break;;
3197 * ) break;;
3198 esac
3199 done
3200 else
3201 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3202 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3203 as_fn_error $? "cannot compute suffix of executables: cannot compile and link
3204 See \`config.log' for more details" "$LINENO" 5; }
3205 fi
3206 rm -f conftest conftest$ac_cv_exeext
3207 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
3208 $as_echo "$ac_cv_exeext" >&6; }
3209
3210 rm -f conftest.$ac_ext
3211 EXEEXT=$ac_cv_exeext
3212 ac_exeext=$EXEEXT
3213 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3214 /* end confdefs.h. */
3215 #include <stdio.h>
3216 int
3217 main ()
3218 {
3219 FILE *f = fopen ("conftest.out", "w");
3220 return ferror (f) || fclose (f) != 0;
3221
3222 ;
3223 return 0;
3224 }
3225 _ACEOF
3226 ac_clean_files="$ac_clean_files conftest.out"
3227 # Check that the compiler produces executables we can run. If not, either
3228 # the compiler is broken, or we cross compile.
3229 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
3230 $as_echo_n "checking whether we are cross compiling... " >&6; }
3231 if test "$cross_compiling" != yes; then
3232 { { ac_try="$ac_link"
3233 case "(($ac_try" in
3234 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3235 *) ac_try_echo=$ac_try;;
3236 esac
3237 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3238 $as_echo "$ac_try_echo"; } >&5
3239 (eval "$ac_link") 2>&5
3240 ac_status=$?
3241 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3242 test $ac_status = 0; }
3243 if { ac_try='./conftest$ac_cv_exeext'
3244 { { case "(($ac_try" in
3245 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3246 *) ac_try_echo=$ac_try;;
3247 esac
3248 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3249 $as_echo "$ac_try_echo"; } >&5
3250 (eval "$ac_try") 2>&5
3251 ac_status=$?
3252 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3253 test $ac_status = 0; }; }; then
3254 cross_compiling=no
3255 else
3256 if test "$cross_compiling" = maybe; then
3257 cross_compiling=yes
3258 else
3259 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3260 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3261 as_fn_error $? "cannot run C compiled programs.
3262 If you meant to cross compile, use \`--host'.
3263 See \`config.log' for more details" "$LINENO" 5; }
3264 fi
3265 fi
3266 fi
3267 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
3268 $as_echo "$cross_compiling" >&6; }
3269
3270 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
3271 ac_clean_files=$ac_clean_files_save
3272 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
3273 $as_echo_n "checking for suffix of object files... " >&6; }
3274 if ${ac_cv_objext+:} false; then :
3275 $as_echo_n "(cached) " >&6
3276 else
3277 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3278 /* end confdefs.h. */
3279
3280 int
3281 main ()
3282 {
3283
3284 ;
3285 return 0;
3286 }
3287 _ACEOF
3288 rm -f conftest.o conftest.obj
3289 if { { ac_try="$ac_compile"
3290 case "(($ac_try" in
3291 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3292 *) ac_try_echo=$ac_try;;
3293 esac
3294 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3295 $as_echo "$ac_try_echo"; } >&5
3296 (eval "$ac_compile") 2>&5
3297 ac_status=$?
3298 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3299 test $ac_status = 0; }; then :
3300 for ac_file in conftest.o conftest.obj conftest.*; do
3301 test -f "$ac_file" || continue;
3302 case $ac_file in
3303 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
3304 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3305 break;;
3306 esac
3307 done
3308 else
3309 $as_echo "$as_me: failed program was:" >&5
3310 sed 's/^/| /' conftest.$ac_ext >&5
3311
3312 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3313 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3314 as_fn_error $? "cannot compute suffix of object files: cannot compile
3315 See \`config.log' for more details" "$LINENO" 5; }
3316 fi
3317 rm -f conftest.$ac_cv_objext conftest.$ac_ext
3318 fi
3319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
3320 $as_echo "$ac_cv_objext" >&6; }
3321 OBJEXT=$ac_cv_objext
3322 ac_objext=$OBJEXT
3323 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
3324 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
3325 if ${ac_cv_c_compiler_gnu+:} false; then :
3326 $as_echo_n "(cached) " >&6
3327 else
3328 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3329 /* end confdefs.h. */
3330
3331 int
3332 main ()
3333 {
3334 #ifndef __GNUC__
3335 choke me
3336 #endif
3337
3338 ;
3339 return 0;
3340 }
3341 _ACEOF
3342 if ac_fn_c_try_compile "$LINENO"; then :
3343 ac_compiler_gnu=yes
3344 else
3345 ac_compiler_gnu=no
3346 fi
3347 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3348 ac_cv_c_compiler_gnu=$ac_compiler_gnu
3349
3350 fi
3351 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
3352 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
3353 if test $ac_compiler_gnu = yes; then
3354 GCC=yes
3355 else
3356 GCC=
3357 fi
3358 ac_test_CFLAGS=${CFLAGS+set}
3359 ac_save_CFLAGS=$CFLAGS
3360 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
3361 $as_echo_n "checking whether $CC accepts -g... " >&6; }
3362 if ${ac_cv_prog_cc_g+:} false; then :
3363 $as_echo_n "(cached) " >&6
3364 else
3365 ac_save_c_werror_flag=$ac_c_werror_flag
3366 ac_c_werror_flag=yes
3367 ac_cv_prog_cc_g=no
3368 CFLAGS="-g"
3369 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3370 /* end confdefs.h. */
3371
3372 int
3373 main ()
3374 {
3375
3376 ;
3377 return 0;
3378 }
3379 _ACEOF
3380 if ac_fn_c_try_compile "$LINENO"; then :
3381 ac_cv_prog_cc_g=yes
3382 else
3383 CFLAGS=""
3384 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3385 /* end confdefs.h. */
3386
3387 int
3388 main ()
3389 {
3390
3391 ;
3392 return 0;
3393 }
3394 _ACEOF
3395 if ac_fn_c_try_compile "$LINENO"; then :
3396
3397 else
3398 ac_c_werror_flag=$ac_save_c_werror_flag
3399 CFLAGS="-g"
3400 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3401 /* end confdefs.h. */
3402
3403 int
3404 main ()
3405 {
3406
3407 ;
3408 return 0;
3409 }
3410 _ACEOF
3411 if ac_fn_c_try_compile "$LINENO"; then :
3412 ac_cv_prog_cc_g=yes
3413 fi
3414 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3415 fi
3416 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3417 fi
3418 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3419 ac_c_werror_flag=$ac_save_c_werror_flag
3420 fi
3421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
3422 $as_echo "$ac_cv_prog_cc_g" >&6; }
3423 if test "$ac_test_CFLAGS" = set; then
3424 CFLAGS=$ac_save_CFLAGS
3425 elif test $ac_cv_prog_cc_g = yes; then
3426 if test "$GCC" = yes; then
3427 CFLAGS="-g -O2"
3428 else
3429 CFLAGS="-g"
3430 fi
3431 else
3432 if test "$GCC" = yes; then
3433 CFLAGS="-O2"
3434 else
3435 CFLAGS=
3436 fi
3437 fi
3438 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
3439 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
3440 if ${ac_cv_prog_cc_c89+:} false; then :
3441 $as_echo_n "(cached) " >&6
3442 else
3443 ac_cv_prog_cc_c89=no
3444 ac_save_CC=$CC
3445 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3446 /* end confdefs.h. */
3447 #include <stdarg.h>
3448 #include <stdio.h>
3449 struct stat;
3450 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
3451 struct buf { int x; };
3452 FILE * (*rcsopen) (struct buf *, struct stat *, int);
3453 static char *e (p, i)
3454 char **p;
3455 int i;
3456 {
3457 return p[i];
3458 }
3459 static char *f (char * (*g) (char **, int), char **p, ...)
3460 {
3461 char *s;
3462 va_list v;
3463 va_start (v,p);
3464 s = g (p, va_arg (v,int));
3465 va_end (v);
3466 return s;
3467 }
3468
3469 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
3470 function prototypes and stuff, but not '\xHH' hex character constants.
3471 These don't provoke an error unfortunately, instead are silently treated
3472 as 'x'. The following induces an error, until -std is added to get
3473 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
3474 array size at least. It's necessary to write '\x00'==0 to get something
3475 that's true only with -std. */
3476 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3477
3478 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3479 inside strings and character constants. */
3480 #define FOO(x) 'x'
3481 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3482
3483 int test (int i, double x);
3484 struct s1 {int (*f) (int a);};
3485 struct s2 {int (*f) (double a);};
3486 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3487 int argc;
3488 char **argv;
3489 int
3490 main ()
3491 {
3492 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
3493 ;
3494 return 0;
3495 }
3496 _ACEOF
3497 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3498 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3499 do
3500 CC="$ac_save_CC $ac_arg"
3501 if ac_fn_c_try_compile "$LINENO"; then :
3502 ac_cv_prog_cc_c89=$ac_arg
3503 fi
3504 rm -f core conftest.err conftest.$ac_objext
3505 test "x$ac_cv_prog_cc_c89" != "xno" && break
3506 done
3507 rm -f conftest.$ac_ext
3508 CC=$ac_save_CC
3509
3510 fi
3511 # AC_CACHE_VAL
3512 case "x$ac_cv_prog_cc_c89" in
3513 x)
3514 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
3515 $as_echo "none needed" >&6; } ;;
3516 xno)
3517 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
3518 $as_echo "unsupported" >&6; } ;;
3519 *)
3520 CC="$CC $ac_cv_prog_cc_c89"
3521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
3522 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
3523 esac
3524 if test "x$ac_cv_prog_cc_c89" != xno; then :
3525
3526 fi
3527
3528 ac_ext=c
3529 ac_cpp='$CPP $CPPFLAGS'
3530 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3531 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3532 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3533
3534 ac_ext=cpp
3535 ac_cpp='$CXXCPP $CPPFLAGS'
3536 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3537 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3538 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
3539 if test -z "$CXX"; then
3540 if test -n "$CCC"; then
3541 CXX=$CCC
3542 else
3543 if test -n "$ac_tool_prefix"; then
3544 for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
3545 do
3546 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3547 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3548 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3549 $as_echo_n "checking for $ac_word... " >&6; }
3550 if ${ac_cv_prog_CXX+:} false; then :
3551 $as_echo_n "(cached) " >&6
3552 else
3553 if test -n "$CXX"; then
3554 ac_cv_prog_CXX="$CXX" # Let the user override the test.
3555 else
3556 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3557 for as_dir in $PATH
3558 do
3559 IFS=$as_save_IFS
3560 test -z "$as_dir" && as_dir=.
3561 for ac_exec_ext in '' $ac_executable_extensions; do
3562 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3563 ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
3564 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3565 break 2
3566 fi
3567 done
3568 done
3569 IFS=$as_save_IFS
3570
3571 fi
3572 fi
3573 CXX=$ac_cv_prog_CXX
3574 if test -n "$CXX"; then
3575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
3576 $as_echo "$CXX" >&6; }
3577 else
3578 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3579 $as_echo "no" >&6; }
3580 fi
3581
3582
3583 test -n "$CXX" && break
3584 done
3585 fi
3586 if test -z "$CXX"; then
3587 ac_ct_CXX=$CXX
3588 for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
3589 do
3590 # Extract the first word of "$ac_prog", so it can be a program name with args.
3591 set dummy $ac_prog; ac_word=$2
3592 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3593 $as_echo_n "checking for $ac_word... " >&6; }
3594 if ${ac_cv_prog_ac_ct_CXX+:} false; then :
3595 $as_echo_n "(cached) " >&6
3596 else
3597 if test -n "$ac_ct_CXX"; then
3598 ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
3599 else
3600 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3601 for as_dir in $PATH
3602 do
3603 IFS=$as_save_IFS
3604 test -z "$as_dir" && as_dir=.
3605 for ac_exec_ext in '' $ac_executable_extensions; do
3606 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3607 ac_cv_prog_ac_ct_CXX="$ac_prog"
3608 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3609 break 2
3610 fi
3611 done
3612 done
3613 IFS=$as_save_IFS
3614
3615 fi
3616 fi
3617 ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
3618 if test -n "$ac_ct_CXX"; then
3619 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
3620 $as_echo "$ac_ct_CXX" >&6; }
3621 else
3622 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3623 $as_echo "no" >&6; }
3624 fi
3625
3626
3627 test -n "$ac_ct_CXX" && break
3628 done
3629
3630 if test "x$ac_ct_CXX" = x; then
3631 CXX="g++"
3632 else
3633 case $cross_compiling:$ac_tool_warned in
3634 yes:)
3635 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3636 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3637 ac_tool_warned=yes ;;
3638 esac
3639 CXX=$ac_ct_CXX
3640 fi
3641 fi
3642
3643 fi
3644 fi
3645 # Provide some information about the compiler.
3646 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
3647 set X $ac_compile
3648 ac_compiler=$2
3649 for ac_option in --version -v -V -qversion; do
3650 { { ac_try="$ac_compiler $ac_option >&5"
3651 case "(($ac_try" in
3652 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3653 *) ac_try_echo=$ac_try;;
3654 esac
3655 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3656 $as_echo "$ac_try_echo"; } >&5
3657 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3658 ac_status=$?
3659 if test -s conftest.err; then
3660 sed '10a\
3661 ... rest of stderr output deleted ...
3662 10q' conftest.err >conftest.er1
3663 cat conftest.er1 >&5
3664 fi
3665 rm -f conftest.er1 conftest.err
3666 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3667 test $ac_status = 0; }
3668 done
3669
3670 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5
3671 $as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; }
3672 if ${ac_cv_cxx_compiler_gnu+:} false; then :
3673 $as_echo_n "(cached) " >&6
3674 else
3675 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3676 /* end confdefs.h. */
3677
3678 int
3679 main ()
3680 {
3681 #ifndef __GNUC__
3682 choke me
3683 #endif
3684
3685 ;
3686 return 0;
3687 }
3688 _ACEOF
3689 if ac_fn_cxx_try_compile "$LINENO"; then :
3690 ac_compiler_gnu=yes
3691 else
3692 ac_compiler_gnu=no
3693 fi
3694 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3695 ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
3696
3697 fi
3698 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
3699 $as_echo "$ac_cv_cxx_compiler_gnu" >&6; }
3700 if test $ac_compiler_gnu = yes; then
3701 GXX=yes
3702 else
3703 GXX=
3704 fi
3705 ac_test_CXXFLAGS=${CXXFLAGS+set}
3706 ac_save_CXXFLAGS=$CXXFLAGS
3707 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
3708 $as_echo_n "checking whether $CXX accepts -g... " >&6; }
3709 if ${ac_cv_prog_cxx_g+:} false; then :
3710 $as_echo_n "(cached) " >&6
3711 else
3712 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
3713 ac_cxx_werror_flag=yes
3714 ac_cv_prog_cxx_g=no
3715 CXXFLAGS="-g"
3716 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3717 /* end confdefs.h. */
3718
3719 int
3720 main ()
3721 {
3722
3723 ;
3724 return 0;
3725 }
3726 _ACEOF
3727 if ac_fn_cxx_try_compile "$LINENO"; then :
3728 ac_cv_prog_cxx_g=yes
3729 else
3730 CXXFLAGS=""
3731 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3732 /* end confdefs.h. */
3733
3734 int
3735 main ()
3736 {
3737
3738 ;
3739 return 0;
3740 }
3741 _ACEOF
3742 if ac_fn_cxx_try_compile "$LINENO"; then :
3743
3744 else
3745 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
3746 CXXFLAGS="-g"
3747 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3748 /* end confdefs.h. */
3749
3750 int
3751 main ()
3752 {
3753
3754 ;
3755 return 0;
3756 }
3757 _ACEOF
3758 if ac_fn_cxx_try_compile "$LINENO"; then :
3759 ac_cv_prog_cxx_g=yes
3760 fi
3761 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3762 fi
3763 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3764 fi
3765 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3766 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
3767 fi
3768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
3769 $as_echo "$ac_cv_prog_cxx_g" >&6; }
3770 if test "$ac_test_CXXFLAGS" = set; then
3771 CXXFLAGS=$ac_save_CXXFLAGS
3772 elif test $ac_cv_prog_cxx_g = yes; then
3773 if test "$GXX" = yes; then
3774 CXXFLAGS="-g -O2"
3775 else
3776 CXXFLAGS="-g"
3777 fi
3778 else
3779 if test "$GXX" = yes; then
3780 CXXFLAGS="-O2"
3781 else
3782 CXXFLAGS=
3783 fi
3784 fi
3785 ac_ext=c
3786 ac_cpp='$CPP $CPPFLAGS'
3787 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3788 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3789 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3790
3791
3792 ac_ext=c
3793 ac_cpp='$CPP $CPPFLAGS'
3794 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3795 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3796 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3797 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
3798 $as_echo_n "checking how to run the C preprocessor... " >&6; }
3799 # On Suns, sometimes $CPP names a directory.
3800 if test -n "$CPP" && test -d "$CPP"; then
3801 CPP=
3802 fi
3803 if test -z "$CPP"; then
3804 if ${ac_cv_prog_CPP+:} false; then :
3805 $as_echo_n "(cached) " >&6
3806 else
3807 # Double quotes because CPP needs to be expanded
3808 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3809 do
3810 ac_preproc_ok=false
3811 for ac_c_preproc_warn_flag in '' yes
3812 do
3813 # Use a header file that comes with gcc, so configuring glibc
3814 # with a fresh cross-compiler works.
3815 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3816 # <limits.h> exists even on freestanding compilers.
3817 # On the NeXT, cc -E runs the code through the compiler's parser,
3818 # not just through cpp. "Syntax error" is here to catch this case.
3819 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3820 /* end confdefs.h. */
3821 #ifdef __STDC__
3822 # include <limits.h>
3823 #else
3824 # include <assert.h>
3825 #endif
3826 Syntax error
3827 _ACEOF
3828 if ac_fn_c_try_cpp "$LINENO"; then :
3829
3830 else
3831 # Broken: fails on valid input.
3832 continue
3833 fi
3834 rm -f conftest.err conftest.i conftest.$ac_ext
3835
3836 # OK, works on sane cases. Now check whether nonexistent headers
3837 # can be detected and how.
3838 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3839 /* end confdefs.h. */
3840 #include <ac_nonexistent.h>
3841 _ACEOF
3842 if ac_fn_c_try_cpp "$LINENO"; then :
3843 # Broken: success on invalid input.
3844 continue
3845 else
3846 # Passes both tests.
3847 ac_preproc_ok=:
3848 break
3849 fi
3850 rm -f conftest.err conftest.i conftest.$ac_ext
3851
3852 done
3853 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3854 rm -f conftest.i conftest.err conftest.$ac_ext
3855 if $ac_preproc_ok; then :
3856 break
3857 fi
3858
3859 done
3860 ac_cv_prog_CPP=$CPP
3861
3862 fi
3863 CPP=$ac_cv_prog_CPP
3864 else
3865 ac_cv_prog_CPP=$CPP
3866 fi
3867 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
3868 $as_echo "$CPP" >&6; }
3869 ac_preproc_ok=false
3870 for ac_c_preproc_warn_flag in '' yes
3871 do
3872 # Use a header file that comes with gcc, so configuring glibc
3873 # with a fresh cross-compiler works.
3874 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3875 # <limits.h> exists even on freestanding compilers.
3876 # On the NeXT, cc -E runs the code through the compiler's parser,
3877 # not just through cpp. "Syntax error" is here to catch this case.
3878 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3879 /* end confdefs.h. */
3880 #ifdef __STDC__
3881 # include <limits.h>
3882 #else
3883 # include <assert.h>
3884 #endif
3885 Syntax error
3886 _ACEOF
3887 if ac_fn_c_try_cpp "$LINENO"; then :
3888
3889 else
3890 # Broken: fails on valid input.
3891 continue
3892 fi
3893 rm -f conftest.err conftest.i conftest.$ac_ext
3894
3895 # OK, works on sane cases. Now check whether nonexistent headers
3896 # can be detected and how.
3897 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3898 /* end confdefs.h. */
3899 #include <ac_nonexistent.h>
3900 _ACEOF
3901 if ac_fn_c_try_cpp "$LINENO"; then :
3902 # Broken: success on invalid input.
3903 continue
3904 else
3905 # Passes both tests.
3906 ac_preproc_ok=:
3907 break
3908 fi
3909 rm -f conftest.err conftest.i conftest.$ac_ext
3910
3911 done
3912 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3913 rm -f conftest.i conftest.err conftest.$ac_ext
3914 if $ac_preproc_ok; then :
3915
3916 else
3917 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3918 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3919 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
3920 See \`config.log' for more details" "$LINENO" 5; }
3921 fi
3922
3923 ac_ext=c
3924 ac_cpp='$CPP $CPPFLAGS'
3925 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3926 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3927 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3928
3929
3930 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
3931 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
3932 if ${ac_cv_path_GREP+:} false; then :
3933 $as_echo_n "(cached) " >&6
3934 else
3935 if test -z "$GREP"; then
3936 ac_path_GREP_found=false
3937 # Loop through the user's path and test for each of PROGNAME-LIST
3938 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3939 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
3940 do
3941 IFS=$as_save_IFS
3942 test -z "$as_dir" && as_dir=.
3943 for ac_prog in grep ggrep; do
3944 for ac_exec_ext in '' $ac_executable_extensions; do
3945 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
3946 as_fn_executable_p "$ac_path_GREP" || continue
3947 # Check for GNU ac_path_GREP and select it if it is found.
3948 # Check for GNU $ac_path_GREP
3949 case `"$ac_path_GREP" --version 2>&1` in
3950 *GNU*)
3951 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
3952 *)
3953 ac_count=0
3954 $as_echo_n 0123456789 >"conftest.in"
3955 while :
3956 do
3957 cat "conftest.in" "conftest.in" >"conftest.tmp"
3958 mv "conftest.tmp" "conftest.in"
3959 cp "conftest.in" "conftest.nl"
3960 $as_echo 'GREP' >> "conftest.nl"
3961 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
3962 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
3963 as_fn_arith $ac_count + 1 && ac_count=$as_val
3964 if test $ac_count -gt ${ac_path_GREP_max-0}; then
3965 # Best one so far, save it but keep looking for a better one
3966 ac_cv_path_GREP="$ac_path_GREP"
3967 ac_path_GREP_max=$ac_count
3968 fi
3969 # 10*(2^10) chars as input seems more than enough
3970 test $ac_count -gt 10 && break
3971 done
3972 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
3973 esac
3974
3975 $ac_path_GREP_found && break 3
3976 done
3977 done
3978 done
3979 IFS=$as_save_IFS
3980 if test -z "$ac_cv_path_GREP"; then
3981 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
3982 fi
3983 else
3984 ac_cv_path_GREP=$GREP
3985 fi
3986
3987 fi
3988 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
3989 $as_echo "$ac_cv_path_GREP" >&6; }
3990 GREP="$ac_cv_path_GREP"
3991
3992
3993 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
3994 $as_echo_n "checking for egrep... " >&6; }
3995 if ${ac_cv_path_EGREP+:} false; then :
3996 $as_echo_n "(cached) " >&6
3997 else
3998 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
3999 then ac_cv_path_EGREP="$GREP -E"
4000 else
4001 if test -z "$EGREP"; then
4002 ac_path_EGREP_found=false
4003 # Loop through the user's path and test for each of PROGNAME-LIST
4004 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4005 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4006 do
4007 IFS=$as_save_IFS
4008 test -z "$as_dir" && as_dir=.
4009 for ac_prog in egrep; do
4010 for ac_exec_ext in '' $ac_executable_extensions; do
4011 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
4012 as_fn_executable_p "$ac_path_EGREP" || continue
4013 # Check for GNU ac_path_EGREP and select it if it is found.
4014 # Check for GNU $ac_path_EGREP
4015 case `"$ac_path_EGREP" --version 2>&1` in
4016 *GNU*)
4017 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
4018 *)
4019 ac_count=0
4020 $as_echo_n 0123456789 >"conftest.in"
4021 while :
4022 do
4023 cat "conftest.in" "conftest.in" >"conftest.tmp"
4024 mv "conftest.tmp" "conftest.in"
4025 cp "conftest.in" "conftest.nl"
4026 $as_echo 'EGREP' >> "conftest.nl"
4027 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4028 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4029 as_fn_arith $ac_count + 1 && ac_count=$as_val
4030 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
4031 # Best one so far, save it but keep looking for a better one
4032 ac_cv_path_EGREP="$ac_path_EGREP"
4033 ac_path_EGREP_max=$ac_count
4034 fi
4035 # 10*(2^10) chars as input seems more than enough
4036 test $ac_count -gt 10 && break
4037 done
4038 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4039 esac
4040
4041 $ac_path_EGREP_found && break 3
4042 done
4043 done
4044 done
4045 IFS=$as_save_IFS
4046 if test -z "$ac_cv_path_EGREP"; then
4047 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4048 fi
4049 else
4050 ac_cv_path_EGREP=$EGREP
4051 fi
4052
4053 fi
4054 fi
4055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
4056 $as_echo "$ac_cv_path_EGREP" >&6; }
4057 EGREP="$ac_cv_path_EGREP"
4058
4059
4060 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
4061 $as_echo_n "checking for ANSI C header files... " >&6; }
4062 if ${ac_cv_header_stdc+:} false; then :
4063 $as_echo_n "(cached) " >&6
4064 else
4065 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4066 /* end confdefs.h. */
4067 #include <stdlib.h>
4068 #include <stdarg.h>
4069 #include <string.h>
4070 #include <float.h>
4071
4072 int
4073 main ()
4074 {
4075
4076 ;
4077 return 0;
4078 }
4079 _ACEOF
4080 if ac_fn_c_try_compile "$LINENO"; then :
4081 ac_cv_header_stdc=yes
4082 else
4083 ac_cv_header_stdc=no
4084 fi
4085 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4086
4087 if test $ac_cv_header_stdc = yes; then
4088 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
4089 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4090 /* end confdefs.h. */
4091 #include <string.h>
4092
4093 _ACEOF
4094 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4095 $EGREP "memchr" >/dev/null 2>&1; then :
4096
4097 else
4098 ac_cv_header_stdc=no
4099 fi
4100 rm -f conftest*
4101
4102 fi
4103
4104 if test $ac_cv_header_stdc = yes; then
4105 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
4106 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4107 /* end confdefs.h. */
4108 #include <stdlib.h>
4109
4110 _ACEOF
4111 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4112 $EGREP "free" >/dev/null 2>&1; then :
4113
4114 else
4115 ac_cv_header_stdc=no
4116 fi
4117 rm -f conftest*
4118
4119 fi
4120
4121 if test $ac_cv_header_stdc = yes; then
4122 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
4123 if test "$cross_compiling" = yes; then :
4124 :
4125 else
4126 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4127 /* end confdefs.h. */
4128 #include <ctype.h>
4129 #include <stdlib.h>
4130 #if ((' ' & 0x0FF) == 0x020)
4131 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4132 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4133 #else
4134 # define ISLOWER(c) \
4135 (('a' <= (c) && (c) <= 'i') \
4136 || ('j' <= (c) && (c) <= 'r') \
4137 || ('s' <= (c) && (c) <= 'z'))
4138 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4139 #endif
4140
4141 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4142 int
4143 main ()
4144 {
4145 int i;
4146 for (i = 0; i < 256; i++)
4147 if (XOR (islower (i), ISLOWER (i))
4148 || toupper (i) != TOUPPER (i))
4149 return 2;
4150 return 0;
4151 }
4152 _ACEOF
4153 if ac_fn_c_try_run "$LINENO"; then :
4154
4155 else
4156 ac_cv_header_stdc=no
4157 fi
4158 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
4159 conftest.$ac_objext conftest.beam conftest.$ac_ext
4160 fi
4161
4162 fi
4163 fi
4164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
4165 $as_echo "$ac_cv_header_stdc" >&6; }
4166 if test $ac_cv_header_stdc = yes; then
4167
4168 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
4169
4170 fi
4171
4172 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
4173 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
4174 inttypes.h stdint.h unistd.h
4175 do :
4176 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
4177 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
4178 "
4179 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
4180 cat >>confdefs.h <<_ACEOF
4181 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
4182 _ACEOF
4183
4184 fi
4185
4186 done
4187
4188
4189
4190 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
4191 if test "x$ac_cv_header_minix_config_h" = xyes; then :
4192 MINIX=yes
4193 else
4194 MINIX=
4195 fi
4196
4197
4198 if test "$MINIX" = yes; then
4199
4200 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
4201
4202
4203 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
4204
4205
4206 $as_echo "#define _MINIX 1" >>confdefs.h
4207
4208 fi
4209
4210
4211 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
4212 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
4213 if ${ac_cv_safe_to_define___extensions__+:} false; then :
4214 $as_echo_n "(cached) " >&6
4215 else
4216 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4217 /* end confdefs.h. */
4218
4219 # define __EXTENSIONS__ 1
4220 $ac_includes_default
4221 int
4222 main ()
4223 {
4224
4225 ;
4226 return 0;
4227 }
4228 _ACEOF
4229 if ac_fn_c_try_compile "$LINENO"; then :
4230 ac_cv_safe_to_define___extensions__=yes
4231 else
4232 ac_cv_safe_to_define___extensions__=no
4233 fi
4234 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4235 fi
4236 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
4237 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
4238 test $ac_cv_safe_to_define___extensions__ = yes &&
4239 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
4240
4241 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
4242
4243 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
4244
4245 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
4246
4247 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
4248
4249
4250 # Check whether --enable-largefile was given.
4251 if test "${enable_largefile+set}" = set; then :
4252 enableval=$enable_largefile;
4253 fi
4254
4255 if test "$enable_largefile" != no; then
4256
4257 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
4258 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
4259 if ${ac_cv_sys_largefile_CC+:} false; then :
4260 $as_echo_n "(cached) " >&6
4261 else
4262 ac_cv_sys_largefile_CC=no
4263 if test "$GCC" != yes; then
4264 ac_save_CC=$CC
4265 while :; do
4266 # IRIX 6.2 and later do not support large files by default,
4267 # so use the C compiler's -n32 option if that helps.
4268 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4269 /* end confdefs.h. */
4270 #include <sys/types.h>
4271 /* Check that off_t can represent 2**63 - 1 correctly.
4272 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4273 since some C++ compilers masquerading as C compilers
4274 incorrectly reject 9223372036854775807. */
4275 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4276 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4277 && LARGE_OFF_T % 2147483647 == 1)
4278 ? 1 : -1];
4279 int
4280 main ()
4281 {
4282
4283 ;
4284 return 0;
4285 }
4286 _ACEOF
4287 if ac_fn_c_try_compile "$LINENO"; then :
4288 break
4289 fi
4290 rm -f core conftest.err conftest.$ac_objext
4291 CC="$CC -n32"
4292 if ac_fn_c_try_compile "$LINENO"; then :
4293 ac_cv_sys_largefile_CC=' -n32'; break
4294 fi
4295 rm -f core conftest.err conftest.$ac_objext
4296 break
4297 done
4298 CC=$ac_save_CC
4299 rm -f conftest.$ac_ext
4300 fi
4301 fi
4302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
4303 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
4304 if test "$ac_cv_sys_largefile_CC" != no; then
4305 CC=$CC$ac_cv_sys_largefile_CC
4306 fi
4307
4308 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
4309 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
4310 if ${ac_cv_sys_file_offset_bits+:} false; then :
4311 $as_echo_n "(cached) " >&6
4312 else
4313 while :; do
4314 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4315 /* end confdefs.h. */
4316 #include <sys/types.h>
4317 /* Check that off_t can represent 2**63 - 1 correctly.
4318 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4319 since some C++ compilers masquerading as C compilers
4320 incorrectly reject 9223372036854775807. */
4321 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4322 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4323 && LARGE_OFF_T % 2147483647 == 1)
4324 ? 1 : -1];
4325 int
4326 main ()
4327 {
4328
4329 ;
4330 return 0;
4331 }
4332 _ACEOF
4333 if ac_fn_c_try_compile "$LINENO"; then :
4334 ac_cv_sys_file_offset_bits=no; break
4335 fi
4336 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4337 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4338 /* end confdefs.h. */
4339 #define _FILE_OFFSET_BITS 64
4340 #include <sys/types.h>
4341 /* Check that off_t can represent 2**63 - 1 correctly.
4342 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4343 since some C++ compilers masquerading as C compilers
4344 incorrectly reject 9223372036854775807. */
4345 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4346 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4347 && LARGE_OFF_T % 2147483647 == 1)
4348 ? 1 : -1];
4349 int
4350 main ()
4351 {
4352
4353 ;
4354 return 0;
4355 }
4356 _ACEOF
4357 if ac_fn_c_try_compile "$LINENO"; then :
4358 ac_cv_sys_file_offset_bits=64; break
4359 fi
4360 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4361 ac_cv_sys_file_offset_bits=unknown
4362 break
4363 done
4364 fi
4365 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
4366 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
4367 case $ac_cv_sys_file_offset_bits in #(
4368 no | unknown) ;;
4369 *)
4370 cat >>confdefs.h <<_ACEOF
4371 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
4372 _ACEOF
4373 ;;
4374 esac
4375 rm -rf conftest*
4376 if test $ac_cv_sys_file_offset_bits = unknown; then
4377 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
4378 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
4379 if ${ac_cv_sys_large_files+:} false; then :
4380 $as_echo_n "(cached) " >&6
4381 else
4382 while :; do
4383 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4384 /* end confdefs.h. */
4385 #include <sys/types.h>
4386 /* Check that off_t can represent 2**63 - 1 correctly.
4387 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4388 since some C++ compilers masquerading as C compilers
4389 incorrectly reject 9223372036854775807. */
4390 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4391 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4392 && LARGE_OFF_T % 2147483647 == 1)
4393 ? 1 : -1];
4394 int
4395 main ()
4396 {
4397
4398 ;
4399 return 0;
4400 }
4401 _ACEOF
4402 if ac_fn_c_try_compile "$LINENO"; then :
4403 ac_cv_sys_large_files=no; break
4404 fi
4405 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4406 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4407 /* end confdefs.h. */
4408 #define _LARGE_FILES 1
4409 #include <sys/types.h>
4410 /* Check that off_t can represent 2**63 - 1 correctly.
4411 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4412 since some C++ compilers masquerading as C compilers
4413 incorrectly reject 9223372036854775807. */
4414 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4415 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4416 && LARGE_OFF_T % 2147483647 == 1)
4417 ? 1 : -1];
4418 int
4419 main ()
4420 {
4421
4422 ;
4423 return 0;
4424 }
4425 _ACEOF
4426 if ac_fn_c_try_compile "$LINENO"; then :
4427 ac_cv_sys_large_files=1; break
4428 fi
4429 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4430 ac_cv_sys_large_files=unknown
4431 break
4432 done
4433 fi
4434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
4435 $as_echo "$ac_cv_sys_large_files" >&6; }
4436 case $ac_cv_sys_large_files in #(
4437 no | unknown) ;;
4438 *)
4439 cat >>confdefs.h <<_ACEOF
4440 #define _LARGE_FILES $ac_cv_sys_large_files
4441 _ACEOF
4442 ;;
4443 esac
4444 rm -rf conftest*
4445 fi
4446
4447
4448 fi
4449
4450 ac_aux_dir=
4451 for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
4452 if test -f "$ac_dir/install-sh"; then
4453 ac_aux_dir=$ac_dir
4454 ac_install_sh="$ac_aux_dir/install-sh -c"
4455 break
4456 elif test -f "$ac_dir/install.sh"; then
4457 ac_aux_dir=$ac_dir
4458 ac_install_sh="$ac_aux_dir/install.sh -c"
4459 break
4460 elif test -f "$ac_dir/shtool"; then
4461 ac_aux_dir=$ac_dir
4462 ac_install_sh="$ac_aux_dir/shtool install -c"
4463 break
4464 fi
4465 done
4466 if test -z "$ac_aux_dir"; then
4467 as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
4468 fi
4469
4470 # These three variables are undocumented and unsupported,
4471 # and are intended to be withdrawn in a future Autoconf release.
4472 # They can cause serious problems if a builder's source tree is in a directory
4473 # whose full name contains unusual characters.
4474 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
4475 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
4476 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
4477
4478
4479 # Expand $ac_aux_dir to an absolute path.
4480 am_aux_dir=`cd "$ac_aux_dir" && pwd`
4481
4482 if test x"${install_sh+set}" != xset; then
4483 case $am_aux_dir in
4484 *\ * | *\ *)
4485 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
4486 *)
4487 install_sh="\${SHELL} $am_aux_dir/install-sh"
4488 esac
4489 fi
4490
4491 # Installed binaries are usually stripped using 'strip' when the user
4492 # run "make install-strip". However 'strip' might not be the right
4493 # tool to use in cross-compilation environments, therefore Automake
4494 # will honor the 'STRIP' environment variable to overrule this program.
4495 if test "$cross_compiling" != no; then
4496 if test -n "$ac_tool_prefix"; then
4497 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
4498 set dummy ${ac_tool_prefix}strip; ac_word=$2
4499 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4500 $as_echo_n "checking for $ac_word... " >&6; }
4501 if ${ac_cv_prog_STRIP+:} false; then :
4502 $as_echo_n "(cached) " >&6
4503 else
4504 if test -n "$STRIP"; then
4505 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
4506 else
4507 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4508 for as_dir in $PATH
4509 do
4510 IFS=$as_save_IFS
4511 test -z "$as_dir" && as_dir=.
4512 for ac_exec_ext in '' $ac_executable_extensions; do
4513 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4514 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
4515 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4516 break 2
4517 fi
4518 done
4519 done
4520 IFS=$as_save_IFS
4521
4522 fi
4523 fi
4524 STRIP=$ac_cv_prog_STRIP
4525 if test -n "$STRIP"; then
4526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
4527 $as_echo "$STRIP" >&6; }
4528 else
4529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4530 $as_echo "no" >&6; }
4531 fi
4532
4533
4534 fi
4535 if test -z "$ac_cv_prog_STRIP"; then
4536 ac_ct_STRIP=$STRIP
4537 # Extract the first word of "strip", so it can be a program name with args.
4538 set dummy strip; ac_word=$2
4539 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4540 $as_echo_n "checking for $ac_word... " >&6; }
4541 if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
4542 $as_echo_n "(cached) " >&6
4543 else
4544 if test -n "$ac_ct_STRIP"; then
4545 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
4546 else
4547 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4548 for as_dir in $PATH
4549 do
4550 IFS=$as_save_IFS
4551 test -z "$as_dir" && as_dir=.
4552 for ac_exec_ext in '' $ac_executable_extensions; do
4553 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4554 ac_cv_prog_ac_ct_STRIP="strip"
4555 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4556 break 2
4557 fi
4558 done
4559 done
4560 IFS=$as_save_IFS
4561
4562 fi
4563 fi
4564 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
4565 if test -n "$ac_ct_STRIP"; then
4566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
4567 $as_echo "$ac_ct_STRIP" >&6; }
4568 else
4569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4570 $as_echo "no" >&6; }
4571 fi
4572
4573 if test "x$ac_ct_STRIP" = x; then
4574 STRIP=":"
4575 else
4576 case $cross_compiling:$ac_tool_warned in
4577 yes:)
4578 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4579 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4580 ac_tool_warned=yes ;;
4581 esac
4582 STRIP=$ac_ct_STRIP
4583 fi
4584 else
4585 STRIP="$ac_cv_prog_STRIP"
4586 fi
4587
4588 fi
4589 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
4590
4591
4592 # Set build, build_cpu, build_vendor and build_os.
4593 # Make sure we can run config.sub.
4594 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
4595 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
4596
4597 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
4598 $as_echo_n "checking build system type... " >&6; }
4599 if ${ac_cv_build+:} false; then :
4600 $as_echo_n "(cached) " >&6
4601 else
4602 ac_build_alias=$build_alias
4603 test "x$ac_build_alias" = x &&
4604 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
4605 test "x$ac_build_alias" = x &&
4606 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
4607 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
4608 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
4609
4610 fi
4611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
4612 $as_echo "$ac_cv_build" >&6; }
4613 case $ac_cv_build in
4614 *-*-*) ;;
4615 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
4616 esac
4617 build=$ac_cv_build
4618 ac_save_IFS=$IFS; IFS='-'
4619 set x $ac_cv_build
4620 shift
4621 build_cpu=$1
4622 build_vendor=$2
4623 shift; shift
4624 # Remember, the first character of IFS is used to create $*,
4625 # except with old shells:
4626 build_os=$*
4627 IFS=$ac_save_IFS
4628 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
4629
4630
4631
4632 # Set host, host_cpu, host_vendor, and host_os.
4633 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
4634 $as_echo_n "checking host system type... " >&6; }
4635 if ${ac_cv_host+:} false; then :
4636 $as_echo_n "(cached) " >&6
4637 else
4638 if test "x$host_alias" = x; then
4639 ac_cv_host=$ac_cv_build
4640 else
4641 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
4642 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
4643 fi
4644
4645 fi
4646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
4647 $as_echo "$ac_cv_host" >&6; }
4648 case $ac_cv_host in
4649 *-*-*) ;;
4650 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
4651 esac
4652 host=$ac_cv_host
4653 ac_save_IFS=$IFS; IFS='-'
4654 set x $ac_cv_host
4655 shift
4656 host_cpu=$1
4657 host_vendor=$2
4658 shift; shift
4659 # Remember, the first character of IFS is used to create $*,
4660 # except with old shells:
4661 host_os=$*
4662 IFS=$ac_save_IFS
4663 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
4664
4665
4666
4667 # Set target, target_cpu, target_vendor, and target_os.
4668 { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
4669 $as_echo_n "checking target system type... " >&6; }
4670 if ${ac_cv_target+:} false; then :
4671 $as_echo_n "(cached) " >&6
4672 else
4673 if test "x$target_alias" = x; then
4674 ac_cv_target=$ac_cv_host
4675 else
4676 ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
4677 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
4678 fi
4679
4680 fi
4681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
4682 $as_echo "$ac_cv_target" >&6; }
4683 case $ac_cv_target in
4684 *-*-*) ;;
4685 *) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;;
4686 esac
4687 target=$ac_cv_target
4688 ac_save_IFS=$IFS; IFS='-'
4689 set x $ac_cv_target
4690 shift
4691 target_cpu=$1
4692 target_vendor=$2
4693 shift; shift
4694 # Remember, the first character of IFS is used to create $*,
4695 # except with old shells:
4696 target_os=$*
4697 IFS=$ac_save_IFS
4698 case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
4699
4700
4701 # The aliases save the names the user supplied, while $host etc.
4702 # will get canonicalized.
4703 test -n "$target_alias" &&
4704 test "$program_prefix$program_suffix$program_transform_name" = \
4705 NONENONEs,x,x, &&
4706 program_prefix=${target_alias}-
4707
4708 # Find a good install program. We prefer a C program (faster),
4709 # so one script is as good as another. But avoid the broken or
4710 # incompatible versions:
4711 # SysV /etc/install, /usr/sbin/install
4712 # SunOS /usr/etc/install
4713 # IRIX /sbin/install
4714 # AIX /bin/install
4715 # AmigaOS /C/install, which installs bootblocks on floppy discs
4716 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
4717 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
4718 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
4719 # OS/2's system install, which has a completely different semantic
4720 # ./install, which can be erroneously created by make from ./install.sh.
4721 # Reject install programs that cannot install multiple files.
4722 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
4723 $as_echo_n "checking for a BSD-compatible install... " >&6; }
4724 if test -z "$INSTALL"; then
4725 if ${ac_cv_path_install+:} false; then :
4726 $as_echo_n "(cached) " >&6
4727 else
4728 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4729 for as_dir in $PATH
4730 do
4731 IFS=$as_save_IFS
4732 test -z "$as_dir" && as_dir=.
4733 # Account for people who put trailing slashes in PATH elements.
4734 case $as_dir/ in #((
4735 ./ | .// | /[cC]/* | \
4736 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
4737 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
4738 /usr/ucb/* ) ;;
4739 *)
4740 # OSF1 and SCO ODT 3.0 have their own names for install.
4741 # Don't use installbsd from OSF since it installs stuff as root
4742 # by default.
4743 for ac_prog in ginstall scoinst install; do
4744 for ac_exec_ext in '' $ac_executable_extensions; do
4745 if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
4746 if test $ac_prog = install &&
4747 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
4748 # AIX install. It has an incompatible calling convention.
4749 :
4750 elif test $ac_prog = install &&
4751 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
4752 # program-specific install script used by HP pwplus--don't use.
4753 :
4754 else
4755 rm -rf conftest.one conftest.two conftest.dir
4756 echo one > conftest.one
4757 echo two > conftest.two
4758 mkdir conftest.dir
4759 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
4760 test -s conftest.one && test -s conftest.two &&
4761 test -s conftest.dir/conftest.one &&
4762 test -s conftest.dir/conftest.two
4763 then
4764 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
4765 break 3
4766 fi
4767 fi
4768 fi
4769 done
4770 done
4771 ;;
4772 esac
4773
4774 done
4775 IFS=$as_save_IFS
4776
4777 rm -rf conftest.one conftest.two conftest.dir
4778
4779 fi
4780 if test "${ac_cv_path_install+set}" = set; then
4781 INSTALL=$ac_cv_path_install
4782 else
4783 # As a last resort, use the slow shell script. Don't cache a
4784 # value for INSTALL within a source directory, because that will
4785 # break other packages using the cache if that directory is
4786 # removed, or if the value is a relative name.
4787 INSTALL=$ac_install_sh
4788 fi
4789 fi
4790 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
4791 $as_echo "$INSTALL" >&6; }
4792
4793 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
4794 # It thinks the first close brace ends the variable substitution.
4795 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
4796
4797 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
4798
4799 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
4800
4801 if test -n "$ac_tool_prefix"; then
4802 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
4803 set dummy ${ac_tool_prefix}ar; ac_word=$2
4804 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4805 $as_echo_n "checking for $ac_word... " >&6; }
4806 if ${ac_cv_prog_AR+:} false; then :
4807 $as_echo_n "(cached) " >&6
4808 else
4809 if test -n "$AR"; then
4810 ac_cv_prog_AR="$AR" # Let the user override the test.
4811 else
4812 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4813 for as_dir in $PATH
4814 do
4815 IFS=$as_save_IFS
4816 test -z "$as_dir" && as_dir=.
4817 for ac_exec_ext in '' $ac_executable_extensions; do
4818 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4819 ac_cv_prog_AR="${ac_tool_prefix}ar"
4820 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4821 break 2
4822 fi
4823 done
4824 done
4825 IFS=$as_save_IFS
4826
4827 fi
4828 fi
4829 AR=$ac_cv_prog_AR
4830 if test -n "$AR"; then
4831 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
4832 $as_echo "$AR" >&6; }
4833 else
4834 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4835 $as_echo "no" >&6; }
4836 fi
4837
4838
4839 fi
4840 if test -z "$ac_cv_prog_AR"; then
4841 ac_ct_AR=$AR
4842 # Extract the first word of "ar", so it can be a program name with args.
4843 set dummy ar; ac_word=$2
4844 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4845 $as_echo_n "checking for $ac_word... " >&6; }
4846 if ${ac_cv_prog_ac_ct_AR+:} false; then :
4847 $as_echo_n "(cached) " >&6
4848 else
4849 if test -n "$ac_ct_AR"; then
4850 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
4851 else
4852 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4853 for as_dir in $PATH
4854 do
4855 IFS=$as_save_IFS
4856 test -z "$as_dir" && as_dir=.
4857 for ac_exec_ext in '' $ac_executable_extensions; do
4858 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4859 ac_cv_prog_ac_ct_AR="ar"
4860 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4861 break 2
4862 fi
4863 done
4864 done
4865 IFS=$as_save_IFS
4866
4867 fi
4868 fi
4869 ac_ct_AR=$ac_cv_prog_ac_ct_AR
4870 if test -n "$ac_ct_AR"; then
4871 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
4872 $as_echo "$ac_ct_AR" >&6; }
4873 else
4874 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4875 $as_echo "no" >&6; }
4876 fi
4877
4878 if test "x$ac_ct_AR" = x; then
4879 AR=""
4880 else
4881 case $cross_compiling:$ac_tool_warned in
4882 yes:)
4883 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4884 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4885 ac_tool_warned=yes ;;
4886 esac
4887 AR=$ac_ct_AR
4888 fi
4889 else
4890 AR="$ac_cv_prog_AR"
4891 fi
4892
4893 if test -n "$ac_tool_prefix"; then
4894 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
4895 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
4896 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4897 $as_echo_n "checking for $ac_word... " >&6; }
4898 if ${ac_cv_prog_RANLIB+:} false; then :
4899 $as_echo_n "(cached) " >&6
4900 else
4901 if test -n "$RANLIB"; then
4902 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
4903 else
4904 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4905 for as_dir in $PATH
4906 do
4907 IFS=$as_save_IFS
4908 test -z "$as_dir" && as_dir=.
4909 for ac_exec_ext in '' $ac_executable_extensions; do
4910 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4911 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
4912 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4913 break 2
4914 fi
4915 done
4916 done
4917 IFS=$as_save_IFS
4918
4919 fi
4920 fi
4921 RANLIB=$ac_cv_prog_RANLIB
4922 if test -n "$RANLIB"; then
4923 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
4924 $as_echo "$RANLIB" >&6; }
4925 else
4926 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4927 $as_echo "no" >&6; }
4928 fi
4929
4930
4931 fi
4932 if test -z "$ac_cv_prog_RANLIB"; then
4933 ac_ct_RANLIB=$RANLIB
4934 # Extract the first word of "ranlib", so it can be a program name with args.
4935 set dummy ranlib; ac_word=$2
4936 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4937 $as_echo_n "checking for $ac_word... " >&6; }
4938 if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
4939 $as_echo_n "(cached) " >&6
4940 else
4941 if test -n "$ac_ct_RANLIB"; then
4942 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
4943 else
4944 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4945 for as_dir in $PATH
4946 do
4947 IFS=$as_save_IFS
4948 test -z "$as_dir" && as_dir=.
4949 for ac_exec_ext in '' $ac_executable_extensions; do
4950 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4951 ac_cv_prog_ac_ct_RANLIB="ranlib"
4952 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4953 break 2
4954 fi
4955 done
4956 done
4957 IFS=$as_save_IFS
4958
4959 fi
4960 fi
4961 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
4962 if test -n "$ac_ct_RANLIB"; then
4963 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
4964 $as_echo "$ac_ct_RANLIB" >&6; }
4965 else
4966 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4967 $as_echo "no" >&6; }
4968 fi
4969
4970 if test "x$ac_ct_RANLIB" = x; then
4971 RANLIB=":"
4972 else
4973 case $cross_compiling:$ac_tool_warned in
4974 yes:)
4975 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4976 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4977 ac_tool_warned=yes ;;
4978 esac
4979 RANLIB=$ac_ct_RANLIB
4980 fi
4981 else
4982 RANLIB="$ac_cv_prog_RANLIB"
4983 fi
4984
4985
4986 test "$program_prefix" != NONE &&
4987 program_transform_name="s&^&$program_prefix&;$program_transform_name"
4988 # Use a double $ so make ignores it.
4989 test "$program_suffix" != NONE &&
4990 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
4991 # Double any \ or $.
4992 # By default was `s,x,x', remove it if useless.
4993 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
4994 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
4995
4996
4997 # We require a C++11 compiler. Check if one is available, and if
4998 # necessary, set CXX_DIALECT to some -std=xxx switch.
4999
5000 ax_cxx_compile_alternatives="11 0x" ax_cxx_compile_cxx11_required=true
5001 ac_ext=cpp
5002 ac_cpp='$CXXCPP $CPPFLAGS'
5003 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5004 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5005 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5006 CXX_DIALECT=""
5007 ac_success=no
5008 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features by default" >&5
5009 $as_echo_n "checking whether $CXX supports C++11 features by default... " >&6; }
5010 if ${ax_cv_cxx_compile_cxx11+:} false; then :
5011 $as_echo_n "(cached) " >&6
5012 else
5013 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5014 /* end confdefs.h. */
5015
5016
5017 // If the compiler admits that it is not ready for C++11, why torture it?
5018 // Hopefully, this will speed up the test.
5019
5020 #ifndef __cplusplus
5021
5022 #error "This is not a C++ compiler"
5023
5024 #elif __cplusplus < 201103L
5025
5026 #error "This is not a C++11 compiler"
5027
5028 #else
5029
5030 namespace cxx11
5031 {
5032
5033 namespace test_static_assert
5034 {
5035
5036 template <typename T>
5037 struct check
5038 {
5039 static_assert(sizeof(int) <= sizeof(T), "not big enough");
5040 };
5041
5042 }
5043
5044 namespace test_final_override
5045 {
5046
5047 struct Base
5048 {
5049 virtual void f() {}
5050 };
5051
5052 struct Derived : public Base
5053 {
5054 virtual void f() override {}
5055 };
5056
5057 }
5058
5059 namespace test_double_right_angle_brackets
5060 {
5061
5062 template < typename T >
5063 struct check {};
5064
5065 typedef check<void> single_type;
5066 typedef check<check<void>> double_type;
5067 typedef check<check<check<void>>> triple_type;
5068 typedef check<check<check<check<void>>>> quadruple_type;
5069
5070 }
5071
5072 namespace test_decltype
5073 {
5074
5075 int
5076 f()
5077 {
5078 int a = 1;
5079 decltype(a) b = 2;
5080 return a + b;
5081 }
5082
5083 }
5084
5085 namespace test_type_deduction
5086 {
5087
5088 template < typename T1, typename T2 >
5089 struct is_same
5090 {
5091 static const bool value = false;
5092 };
5093
5094 template < typename T >
5095 struct is_same<T, T>
5096 {
5097 static const bool value = true;
5098 };
5099
5100 template < typename T1, typename T2 >
5101 auto
5102 add(T1 a1, T2 a2) -> decltype(a1 + a2)
5103 {
5104 return a1 + a2;
5105 }
5106
5107 int
5108 test(const int c, volatile int v)
5109 {
5110 static_assert(is_same<int, decltype(0)>::value == true, "");
5111 static_assert(is_same<int, decltype(c)>::value == false, "");
5112 static_assert(is_same<int, decltype(v)>::value == false, "");
5113 auto ac = c;
5114 auto av = v;
5115 auto sumi = ac + av + 'x';
5116 auto sumf = ac + av + 1.0;
5117 static_assert(is_same<int, decltype(ac)>::value == true, "");
5118 static_assert(is_same<int, decltype(av)>::value == true, "");
5119 static_assert(is_same<int, decltype(sumi)>::value == true, "");
5120 static_assert(is_same<int, decltype(sumf)>::value == false, "");
5121 static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
5122 return (sumf > 0.0) ? sumi : add(c, v);
5123 }
5124
5125 }
5126
5127 namespace test_noexcept
5128 {
5129
5130 int f() { return 0; }
5131 int g() noexcept { return 0; }
5132
5133 static_assert(noexcept(f()) == false, "");
5134 static_assert(noexcept(g()) == true, "");
5135
5136 }
5137
5138 namespace test_constexpr
5139 {
5140
5141 template < typename CharT >
5142 unsigned long constexpr
5143 strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
5144 {
5145 return *s ? strlen_c_r(s + 1, acc + 1) : acc;
5146 }
5147
5148 template < typename CharT >
5149 unsigned long constexpr
5150 strlen_c(const CharT *const s) noexcept
5151 {
5152 return strlen_c_r(s, 0UL);
5153 }
5154
5155 static_assert(strlen_c("") == 0UL, "");
5156 static_assert(strlen_c("1") == 1UL, "");
5157 static_assert(strlen_c("example") == 7UL, "");
5158 static_assert(strlen_c("another\0example") == 7UL, "");
5159
5160 }
5161
5162 namespace test_rvalue_references
5163 {
5164
5165 template < int N >
5166 struct answer
5167 {
5168 static constexpr int value = N;
5169 };
5170
5171 answer<1> f(int&) { return answer<1>(); }
5172 answer<2> f(const int&) { return answer<2>(); }
5173 answer<3> f(int&&) { return answer<3>(); }
5174
5175 void
5176 test()
5177 {
5178 int i = 0;
5179 const int c = 0;
5180 static_assert(decltype(f(i))::value == 1, "");
5181 static_assert(decltype(f(c))::value == 2, "");
5182 static_assert(decltype(f(0))::value == 3, "");
5183 }
5184
5185 }
5186
5187 namespace test_uniform_initialization
5188 {
5189
5190 struct test
5191 {
5192 static const int zero {};
5193 static const int one {1};
5194 };
5195
5196 static_assert(test::zero == 0, "");
5197 static_assert(test::one == 1, "");
5198
5199 }
5200
5201 namespace test_lambdas
5202 {
5203
5204 void
5205 test1()
5206 {
5207 auto lambda1 = [](){};
5208 auto lambda2 = lambda1;
5209 lambda1();
5210 lambda2();
5211 }
5212
5213 int
5214 test2()
5215 {
5216 auto a = [](int i, int j){ return i + j; }(1, 2);
5217 auto b = []() -> int { return '0'; }();
5218 auto c = [=](){ return a + b; }();
5219 auto d = [&](){ return c; }();
5220 auto e = [a, &b](int x) mutable {
5221 const auto identity = [](int y){ return y; };
5222 for (auto i = 0; i < a; ++i)
5223 a += b--;
5224 return x + identity(a + b);
5225 }(0);
5226 return a + b + c + d + e;
5227 }
5228
5229 int
5230 test3()
5231 {
5232 const auto nullary = [](){ return 0; };
5233 const auto unary = [](int x){ return x; };
5234 using nullary_t = decltype(nullary);
5235 using unary_t = decltype(unary);
5236 const auto higher1st = [](nullary_t f){ return f(); };
5237 const auto higher2nd = [unary](nullary_t f1){
5238 return [unary, f1](unary_t f2){ return f2(unary(f1())); };
5239 };
5240 return higher1st(nullary) + higher2nd(nullary)(unary);
5241 }
5242
5243 }
5244
5245 namespace test_variadic_templates
5246 {
5247
5248 template <int...>
5249 struct sum;
5250
5251 template <int N0, int... N1toN>
5252 struct sum<N0, N1toN...>
5253 {
5254 static constexpr auto value = N0 + sum<N1toN...>::value;
5255 };
5256
5257 template <>
5258 struct sum<>
5259 {
5260 static constexpr auto value = 0;
5261 };
5262
5263 static_assert(sum<>::value == 0, "");
5264 static_assert(sum<1>::value == 1, "");
5265 static_assert(sum<23>::value == 23, "");
5266 static_assert(sum<1, 2>::value == 3, "");
5267 static_assert(sum<5, 5, 11>::value == 21, "");
5268 static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
5269
5270 }
5271
5272 // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
5273 // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
5274 // because of this.
5275 namespace test_template_alias_sfinae
5276 {
5277
5278 struct foo {};
5279
5280 template<typename T>
5281 using member = typename T::member_type;
5282
5283 template<typename T>
5284 void func(...) {}
5285
5286 template<typename T>
5287 void func(member<T>*) {}
5288
5289 void test();
5290
5291 void test() { func<foo>(0); }
5292
5293 }
5294
5295 } // namespace cxx11
5296
5297 #endif // __cplusplus >= 201103L
5298
5299
5300
5301 _ACEOF
5302 if ac_fn_cxx_try_compile "$LINENO"; then :
5303 ax_cv_cxx_compile_cxx11=yes
5304 else
5305 ax_cv_cxx_compile_cxx11=no
5306 fi
5307 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5308 fi
5309 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_cxx_compile_cxx11" >&5
5310 $as_echo "$ax_cv_cxx_compile_cxx11" >&6; }
5311 if test x$ax_cv_cxx_compile_cxx11 = xyes; then
5312 ac_success=yes
5313 fi
5314
5315 if test x$ac_success = xno; then
5316 for alternative in ${ax_cxx_compile_alternatives}; do
5317 switch="-std=gnu++${alternative}"
5318 cachevar=`$as_echo "ax_cv_cxx_compile_cxx11_$switch" | $as_tr_sh`
5319 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features with $switch" >&5
5320 $as_echo_n "checking whether $CXX supports C++11 features with $switch... " >&6; }
5321 if eval \${$cachevar+:} false; then :
5322 $as_echo_n "(cached) " >&6
5323 else
5324 ac_save_CXX="$CXX"
5325 CXX="$CXX $switch"
5326 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5327 /* end confdefs.h. */
5328
5329
5330 // If the compiler admits that it is not ready for C++11, why torture it?
5331 // Hopefully, this will speed up the test.
5332
5333 #ifndef __cplusplus
5334
5335 #error "This is not a C++ compiler"
5336
5337 #elif __cplusplus < 201103L
5338
5339 #error "This is not a C++11 compiler"
5340
5341 #else
5342
5343 namespace cxx11
5344 {
5345
5346 namespace test_static_assert
5347 {
5348
5349 template <typename T>
5350 struct check
5351 {
5352 static_assert(sizeof(int) <= sizeof(T), "not big enough");
5353 };
5354
5355 }
5356
5357 namespace test_final_override
5358 {
5359
5360 struct Base
5361 {
5362 virtual void f() {}
5363 };
5364
5365 struct Derived : public Base
5366 {
5367 virtual void f() override {}
5368 };
5369
5370 }
5371
5372 namespace test_double_right_angle_brackets
5373 {
5374
5375 template < typename T >
5376 struct check {};
5377
5378 typedef check<void> single_type;
5379 typedef check<check<void>> double_type;
5380 typedef check<check<check<void>>> triple_type;
5381 typedef check<check<check<check<void>>>> quadruple_type;
5382
5383 }
5384
5385 namespace test_decltype
5386 {
5387
5388 int
5389 f()
5390 {
5391 int a = 1;
5392 decltype(a) b = 2;
5393 return a + b;
5394 }
5395
5396 }
5397
5398 namespace test_type_deduction
5399 {
5400
5401 template < typename T1, typename T2 >
5402 struct is_same
5403 {
5404 static const bool value = false;
5405 };
5406
5407 template < typename T >
5408 struct is_same<T, T>
5409 {
5410 static const bool value = true;
5411 };
5412
5413 template < typename T1, typename T2 >
5414 auto
5415 add(T1 a1, T2 a2) -> decltype(a1 + a2)
5416 {
5417 return a1 + a2;
5418 }
5419
5420 int
5421 test(const int c, volatile int v)
5422 {
5423 static_assert(is_same<int, decltype(0)>::value == true, "");
5424 static_assert(is_same<int, decltype(c)>::value == false, "");
5425 static_assert(is_same<int, decltype(v)>::value == false, "");
5426 auto ac = c;
5427 auto av = v;
5428 auto sumi = ac + av + 'x';
5429 auto sumf = ac + av + 1.0;
5430 static_assert(is_same<int, decltype(ac)>::value == true, "");
5431 static_assert(is_same<int, decltype(av)>::value == true, "");
5432 static_assert(is_same<int, decltype(sumi)>::value == true, "");
5433 static_assert(is_same<int, decltype(sumf)>::value == false, "");
5434 static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
5435 return (sumf > 0.0) ? sumi : add(c, v);
5436 }
5437
5438 }
5439
5440 namespace test_noexcept
5441 {
5442
5443 int f() { return 0; }
5444 int g() noexcept { return 0; }
5445
5446 static_assert(noexcept(f()) == false, "");
5447 static_assert(noexcept(g()) == true, "");
5448
5449 }
5450
5451 namespace test_constexpr
5452 {
5453
5454 template < typename CharT >
5455 unsigned long constexpr
5456 strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
5457 {
5458 return *s ? strlen_c_r(s + 1, acc + 1) : acc;
5459 }
5460
5461 template < typename CharT >
5462 unsigned long constexpr
5463 strlen_c(const CharT *const s) noexcept
5464 {
5465 return strlen_c_r(s, 0UL);
5466 }
5467
5468 static_assert(strlen_c("") == 0UL, "");
5469 static_assert(strlen_c("1") == 1UL, "");
5470 static_assert(strlen_c("example") == 7UL, "");
5471 static_assert(strlen_c("another\0example") == 7UL, "");
5472
5473 }
5474
5475 namespace test_rvalue_references
5476 {
5477
5478 template < int N >
5479 struct answer
5480 {
5481 static constexpr int value = N;
5482 };
5483
5484 answer<1> f(int&) { return answer<1>(); }
5485 answer<2> f(const int&) { return answer<2>(); }
5486 answer<3> f(int&&) { return answer<3>(); }
5487
5488 void
5489 test()
5490 {
5491 int i = 0;
5492 const int c = 0;
5493 static_assert(decltype(f(i))::value == 1, "");
5494 static_assert(decltype(f(c))::value == 2, "");
5495 static_assert(decltype(f(0))::value == 3, "");
5496 }
5497
5498 }
5499
5500 namespace test_uniform_initialization
5501 {
5502
5503 struct test
5504 {
5505 static const int zero {};
5506 static const int one {1};
5507 };
5508
5509 static_assert(test::zero == 0, "");
5510 static_assert(test::one == 1, "");
5511
5512 }
5513
5514 namespace test_lambdas
5515 {
5516
5517 void
5518 test1()
5519 {
5520 auto lambda1 = [](){};
5521 auto lambda2 = lambda1;
5522 lambda1();
5523 lambda2();
5524 }
5525
5526 int
5527 test2()
5528 {
5529 auto a = [](int i, int j){ return i + j; }(1, 2);
5530 auto b = []() -> int { return '0'; }();
5531 auto c = [=](){ return a + b; }();
5532 auto d = [&](){ return c; }();
5533 auto e = [a, &b](int x) mutable {
5534 const auto identity = [](int y){ return y; };
5535 for (auto i = 0; i < a; ++i)
5536 a += b--;
5537 return x + identity(a + b);
5538 }(0);
5539 return a + b + c + d + e;
5540 }
5541
5542 int
5543 test3()
5544 {
5545 const auto nullary = [](){ return 0; };
5546 const auto unary = [](int x){ return x; };
5547 using nullary_t = decltype(nullary);
5548 using unary_t = decltype(unary);
5549 const auto higher1st = [](nullary_t f){ return f(); };
5550 const auto higher2nd = [unary](nullary_t f1){
5551 return [unary, f1](unary_t f2){ return f2(unary(f1())); };
5552 };
5553 return higher1st(nullary) + higher2nd(nullary)(unary);
5554 }
5555
5556 }
5557
5558 namespace test_variadic_templates
5559 {
5560
5561 template <int...>
5562 struct sum;
5563
5564 template <int N0, int... N1toN>
5565 struct sum<N0, N1toN...>
5566 {
5567 static constexpr auto value = N0 + sum<N1toN...>::value;
5568 };
5569
5570 template <>
5571 struct sum<>
5572 {
5573 static constexpr auto value = 0;
5574 };
5575
5576 static_assert(sum<>::value == 0, "");
5577 static_assert(sum<1>::value == 1, "");
5578 static_assert(sum<23>::value == 23, "");
5579 static_assert(sum<1, 2>::value == 3, "");
5580 static_assert(sum<5, 5, 11>::value == 21, "");
5581 static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
5582
5583 }
5584
5585 // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
5586 // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
5587 // because of this.
5588 namespace test_template_alias_sfinae
5589 {
5590
5591 struct foo {};
5592
5593 template<typename T>
5594 using member = typename T::member_type;
5595
5596 template<typename T>
5597 void func(...) {}
5598
5599 template<typename T>
5600 void func(member<T>*) {}
5601
5602 void test();
5603
5604 void test() { func<foo>(0); }
5605
5606 }
5607
5608 } // namespace cxx11
5609
5610 #endif // __cplusplus >= 201103L
5611
5612
5613
5614 _ACEOF
5615 if ac_fn_cxx_try_compile "$LINENO"; then :
5616 eval $cachevar=yes
5617 else
5618 eval $cachevar=no
5619 fi
5620 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5621 CXX="$ac_save_CXX"
5622 fi
5623 eval ac_res=\$$cachevar
5624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
5625 $as_echo "$ac_res" >&6; }
5626 if eval test x\$$cachevar = xyes; then
5627 CXX_DIALECT="$switch"
5628 CXX="$CXX $switch"
5629 if test -n "$CXXCPP" ; then
5630 CXXCPP="$CXXCPP $switch"
5631 fi
5632 ac_success=yes
5633 break
5634 fi
5635 done
5636 fi
5637
5638 if test x$ac_success = xno; then
5639 for alternative in ${ax_cxx_compile_alternatives}; do
5640 for switch in -std=c++${alternative} +std=c++${alternative} "-h std=c++${alternative}"; do
5641 cachevar=`$as_echo "ax_cv_cxx_compile_cxx11_$switch" | $as_tr_sh`
5642 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features with $switch" >&5
5643 $as_echo_n "checking whether $CXX supports C++11 features with $switch... " >&6; }
5644 if eval \${$cachevar+:} false; then :
5645 $as_echo_n "(cached) " >&6
5646 else
5647 ac_save_CXX="$CXX"
5648 CXX="$CXX $switch"
5649 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5650 /* end confdefs.h. */
5651
5652
5653 // If the compiler admits that it is not ready for C++11, why torture it?
5654 // Hopefully, this will speed up the test.
5655
5656 #ifndef __cplusplus
5657
5658 #error "This is not a C++ compiler"
5659
5660 #elif __cplusplus < 201103L
5661
5662 #error "This is not a C++11 compiler"
5663
5664 #else
5665
5666 namespace cxx11
5667 {
5668
5669 namespace test_static_assert
5670 {
5671
5672 template <typename T>
5673 struct check
5674 {
5675 static_assert(sizeof(int) <= sizeof(T), "not big enough");
5676 };
5677
5678 }
5679
5680 namespace test_final_override
5681 {
5682
5683 struct Base
5684 {
5685 virtual void f() {}
5686 };
5687
5688 struct Derived : public Base
5689 {
5690 virtual void f() override {}
5691 };
5692
5693 }
5694
5695 namespace test_double_right_angle_brackets
5696 {
5697
5698 template < typename T >
5699 struct check {};
5700
5701 typedef check<void> single_type;
5702 typedef check<check<void>> double_type;
5703 typedef check<check<check<void>>> triple_type;
5704 typedef check<check<check<check<void>>>> quadruple_type;
5705
5706 }
5707
5708 namespace test_decltype
5709 {
5710
5711 int
5712 f()
5713 {
5714 int a = 1;
5715 decltype(a) b = 2;
5716 return a + b;
5717 }
5718
5719 }
5720
5721 namespace test_type_deduction
5722 {
5723
5724 template < typename T1, typename T2 >
5725 struct is_same
5726 {
5727 static const bool value = false;
5728 };
5729
5730 template < typename T >
5731 struct is_same<T, T>
5732 {
5733 static const bool value = true;
5734 };
5735
5736 template < typename T1, typename T2 >
5737 auto
5738 add(T1 a1, T2 a2) -> decltype(a1 + a2)
5739 {
5740 return a1 + a2;
5741 }
5742
5743 int
5744 test(const int c, volatile int v)
5745 {
5746 static_assert(is_same<int, decltype(0)>::value == true, "");
5747 static_assert(is_same<int, decltype(c)>::value == false, "");
5748 static_assert(is_same<int, decltype(v)>::value == false, "");
5749 auto ac = c;
5750 auto av = v;
5751 auto sumi = ac + av + 'x';
5752 auto sumf = ac + av + 1.0;
5753 static_assert(is_same<int, decltype(ac)>::value == true, "");
5754 static_assert(is_same<int, decltype(av)>::value == true, "");
5755 static_assert(is_same<int, decltype(sumi)>::value == true, "");
5756 static_assert(is_same<int, decltype(sumf)>::value == false, "");
5757 static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
5758 return (sumf > 0.0) ? sumi : add(c, v);
5759 }
5760
5761 }
5762
5763 namespace test_noexcept
5764 {
5765
5766 int f() { return 0; }
5767 int g() noexcept { return 0; }
5768
5769 static_assert(noexcept(f()) == false, "");
5770 static_assert(noexcept(g()) == true, "");
5771
5772 }
5773
5774 namespace test_constexpr
5775 {
5776
5777 template < typename CharT >
5778 unsigned long constexpr
5779 strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
5780 {
5781 return *s ? strlen_c_r(s + 1, acc + 1) : acc;
5782 }
5783
5784 template < typename CharT >
5785 unsigned long constexpr
5786 strlen_c(const CharT *const s) noexcept
5787 {
5788 return strlen_c_r(s, 0UL);
5789 }
5790
5791 static_assert(strlen_c("") == 0UL, "");
5792 static_assert(strlen_c("1") == 1UL, "");
5793 static_assert(strlen_c("example") == 7UL, "");
5794 static_assert(strlen_c("another\0example") == 7UL, "");
5795
5796 }
5797
5798 namespace test_rvalue_references
5799 {
5800
5801 template < int N >
5802 struct answer
5803 {
5804 static constexpr int value = N;
5805 };
5806
5807 answer<1> f(int&) { return answer<1>(); }
5808 answer<2> f(const int&) { return answer<2>(); }
5809 answer<3> f(int&&) { return answer<3>(); }
5810
5811 void
5812 test()
5813 {
5814 int i = 0;
5815 const int c = 0;
5816 static_assert(decltype(f(i))::value == 1, "");
5817 static_assert(decltype(f(c))::value == 2, "");
5818 static_assert(decltype(f(0))::value == 3, "");
5819 }
5820
5821 }
5822
5823 namespace test_uniform_initialization
5824 {
5825
5826 struct test
5827 {
5828 static const int zero {};
5829 static const int one {1};
5830 };
5831
5832 static_assert(test::zero == 0, "");
5833 static_assert(test::one == 1, "");
5834
5835 }
5836
5837 namespace test_lambdas
5838 {
5839
5840 void
5841 test1()
5842 {
5843 auto lambda1 = [](){};
5844 auto lambda2 = lambda1;
5845 lambda1();
5846 lambda2();
5847 }
5848
5849 int
5850 test2()
5851 {
5852 auto a = [](int i, int j){ return i + j; }(1, 2);
5853 auto b = []() -> int { return '0'; }();
5854 auto c = [=](){ return a + b; }();
5855 auto d = [&](){ return c; }();
5856 auto e = [a, &b](int x) mutable {
5857 const auto identity = [](int y){ return y; };
5858 for (auto i = 0; i < a; ++i)
5859 a += b--;
5860 return x + identity(a + b);
5861 }(0);
5862 return a + b + c + d + e;
5863 }
5864
5865 int
5866 test3()
5867 {
5868 const auto nullary = [](){ return 0; };
5869 const auto unary = [](int x){ return x; };
5870 using nullary_t = decltype(nullary);
5871 using unary_t = decltype(unary);
5872 const auto higher1st = [](nullary_t f){ return f(); };
5873 const auto higher2nd = [unary](nullary_t f1){
5874 return [unary, f1](unary_t f2){ return f2(unary(f1())); };
5875 };
5876 return higher1st(nullary) + higher2nd(nullary)(unary);
5877 }
5878
5879 }
5880
5881 namespace test_variadic_templates
5882 {
5883
5884 template <int...>
5885 struct sum;
5886
5887 template <int N0, int... N1toN>
5888 struct sum<N0, N1toN...>
5889 {
5890 static constexpr auto value = N0 + sum<N1toN...>::value;
5891 };
5892
5893 template <>
5894 struct sum<>
5895 {
5896 static constexpr auto value = 0;
5897 };
5898
5899 static_assert(sum<>::value == 0, "");
5900 static_assert(sum<1>::value == 1, "");
5901 static_assert(sum<23>::value == 23, "");
5902 static_assert(sum<1, 2>::value == 3, "");
5903 static_assert(sum<5, 5, 11>::value == 21, "");
5904 static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
5905
5906 }
5907
5908 // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
5909 // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
5910 // because of this.
5911 namespace test_template_alias_sfinae
5912 {
5913
5914 struct foo {};
5915
5916 template<typename T>
5917 using member = typename T::member_type;
5918
5919 template<typename T>
5920 void func(...) {}
5921
5922 template<typename T>
5923 void func(member<T>*) {}
5924
5925 void test();
5926
5927 void test() { func<foo>(0); }
5928
5929 }
5930
5931 } // namespace cxx11
5932
5933 #endif // __cplusplus >= 201103L
5934
5935
5936
5937 _ACEOF
5938 if ac_fn_cxx_try_compile "$LINENO"; then :
5939 eval $cachevar=yes
5940 else
5941 eval $cachevar=no
5942 fi
5943 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5944 CXX="$ac_save_CXX"
5945 fi
5946 eval ac_res=\$$cachevar
5947 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
5948 $as_echo "$ac_res" >&6; }
5949 if eval test x\$$cachevar = xyes; then
5950 CXX_DIALECT="$switch"
5951 CXX="$CXX $switch"
5952 if test -n "$CXXCPP" ; then
5953 CXXCPP="$CXXCPP $switch"
5954 fi
5955 ac_success=yes
5956 break
5957 fi
5958 done
5959 if test x$ac_success = xyes; then
5960 break
5961 fi
5962 done
5963 fi
5964 ac_ext=c
5965 ac_cpp='$CPP $CPPFLAGS'
5966 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5967 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5968 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5969
5970 if test x$ax_cxx_compile_cxx11_required = xtrue; then
5971 if test x$ac_success = xno; then
5972 as_fn_error $? "*** A compiler with support for C++11 language features is required." "$LINENO" 5
5973 fi
5974 fi
5975 if test x$ac_success = xno; then
5976 HAVE_CXX11=0
5977 { $as_echo "$as_me:${as_lineno-$LINENO}: No compiler with C++11 support was found" >&5
5978 $as_echo "$as_me: No compiler with C++11 support was found" >&6;}
5979 else
5980 HAVE_CXX11=1
5981
5982 $as_echo "#define HAVE_CXX11 1" >>confdefs.h
5983
5984 fi
5985
5986
5987
5988
5989 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
5990 $as_echo_n "checking for ANSI C header files... " >&6; }
5991 if ${ac_cv_header_stdc+:} false; then :
5992 $as_echo_n "(cached) " >&6
5993 else
5994 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5995 /* end confdefs.h. */
5996 #include <stdlib.h>
5997 #include <stdarg.h>
5998 #include <string.h>
5999 #include <float.h>
6000
6001 int
6002 main ()
6003 {
6004
6005 ;
6006 return 0;
6007 }
6008 _ACEOF
6009 if ac_fn_c_try_compile "$LINENO"; then :
6010 ac_cv_header_stdc=yes
6011 else
6012 ac_cv_header_stdc=no
6013 fi
6014 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6015
6016 if test $ac_cv_header_stdc = yes; then
6017 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6018 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6019 /* end confdefs.h. */
6020 #include <string.h>
6021
6022 _ACEOF
6023 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6024 $EGREP "memchr" >/dev/null 2>&1; then :
6025
6026 else
6027 ac_cv_header_stdc=no
6028 fi
6029 rm -f conftest*
6030
6031 fi
6032
6033 if test $ac_cv_header_stdc = yes; then
6034 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6035 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6036 /* end confdefs.h. */
6037 #include <stdlib.h>
6038
6039 _ACEOF
6040 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6041 $EGREP "free" >/dev/null 2>&1; then :
6042
6043 else
6044 ac_cv_header_stdc=no
6045 fi
6046 rm -f conftest*
6047
6048 fi
6049
6050 if test $ac_cv_header_stdc = yes; then
6051 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6052 if test "$cross_compiling" = yes; then :
6053 :
6054 else
6055 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6056 /* end confdefs.h. */
6057 #include <ctype.h>
6058 #include <stdlib.h>
6059 #if ((' ' & 0x0FF) == 0x020)
6060 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6061 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6062 #else
6063 # define ISLOWER(c) \
6064 (('a' <= (c) && (c) <= 'i') \
6065 || ('j' <= (c) && (c) <= 'r') \
6066 || ('s' <= (c) && (c) <= 'z'))
6067 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6068 #endif
6069
6070 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6071 int
6072 main ()
6073 {
6074 int i;
6075 for (i = 0; i < 256; i++)
6076 if (XOR (islower (i), ISLOWER (i))
6077 || toupper (i) != TOUPPER (i))
6078 return 2;
6079 return 0;
6080 }
6081 _ACEOF
6082 if ac_fn_c_try_run "$LINENO"; then :
6083
6084 else
6085 ac_cv_header_stdc=no
6086 fi
6087 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6088 conftest.$ac_objext conftest.beam conftest.$ac_ext
6089 fi
6090
6091 fi
6092 fi
6093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
6094 $as_echo "$ac_cv_header_stdc" >&6; }
6095 if test $ac_cv_header_stdc = yes; then
6096
6097 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
6098
6099 fi
6100
6101
6102 ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
6103 if test "x$ac_cv_type_size_t" = xyes; then :
6104
6105 else
6106
6107 cat >>confdefs.h <<_ACEOF
6108 #define size_t unsigned int
6109 _ACEOF
6110
6111 fi
6112
6113
6114
6115
6116 for ac_header in $ac_header_list
6117 do :
6118 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6119 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
6120 "
6121 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
6122 cat >>confdefs.h <<_ACEOF
6123 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
6124 _ACEOF
6125
6126 fi
6127
6128 done
6129
6130
6131
6132
6133
6134
6135
6136 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
6137 if test "x$ac_cv_type_pid_t" = xyes; then :
6138
6139 else
6140
6141 cat >>confdefs.h <<_ACEOF
6142 #define pid_t int
6143 _ACEOF
6144
6145 fi
6146
6147 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
6148 $as_echo_n "checking for a sed that does not truncate output... " >&6; }
6149 if ${ac_cv_path_SED+:} false; then :
6150 $as_echo_n "(cached) " >&6
6151 else
6152 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
6153 for ac_i in 1 2 3 4 5 6 7; do
6154 ac_script="$ac_script$as_nl$ac_script"
6155 done
6156 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
6157 { ac_script=; unset ac_script;}
6158 if test -z "$SED"; then
6159 ac_path_SED_found=false
6160 # Loop through the user's path and test for each of PROGNAME-LIST
6161 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6162 for as_dir in $PATH
6163 do
6164 IFS=$as_save_IFS
6165 test -z "$as_dir" && as_dir=.
6166 for ac_prog in sed gsed; do
6167 for ac_exec_ext in '' $ac_executable_extensions; do
6168 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
6169 as_fn_executable_p "$ac_path_SED" || continue
6170 # Check for GNU ac_path_SED and select it if it is found.
6171 # Check for GNU $ac_path_SED
6172 case `"$ac_path_SED" --version 2>&1` in
6173 *GNU*)
6174 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
6175 *)
6176 ac_count=0
6177 $as_echo_n 0123456789 >"conftest.in"
6178 while :
6179 do
6180 cat "conftest.in" "conftest.in" >"conftest.tmp"
6181 mv "conftest.tmp" "conftest.in"
6182 cp "conftest.in" "conftest.nl"
6183 $as_echo '' >> "conftest.nl"
6184 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
6185 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
6186 as_fn_arith $ac_count + 1 && ac_count=$as_val
6187 if test $ac_count -gt ${ac_path_SED_max-0}; then
6188 # Best one so far, save it but keep looking for a better one
6189 ac_cv_path_SED="$ac_path_SED"
6190 ac_path_SED_max=$ac_count
6191 fi
6192 # 10*(2^10) chars as input seems more than enough
6193 test $ac_count -gt 10 && break
6194 done
6195 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
6196 esac
6197
6198 $ac_path_SED_found && break 3
6199 done
6200 done
6201 done
6202 IFS=$as_save_IFS
6203 if test -z "$ac_cv_path_SED"; then
6204 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
6205 fi
6206 else
6207 ac_cv_path_SED=$SED
6208 fi
6209
6210 fi
6211 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
6212 $as_echo "$ac_cv_path_SED" >&6; }
6213 SED="$ac_cv_path_SED"
6214 rm -f conftest.sed
6215
6216
6217 if test "X$prefix" = "XNONE"; then
6218 acl_final_prefix="$ac_default_prefix"
6219 else
6220 acl_final_prefix="$prefix"
6221 fi
6222 if test "X$exec_prefix" = "XNONE"; then
6223 acl_final_exec_prefix='${prefix}'
6224 else
6225 acl_final_exec_prefix="$exec_prefix"
6226 fi
6227 acl_save_prefix="$prefix"
6228 prefix="$acl_final_prefix"
6229 eval acl_final_exec_prefix=\"$acl_final_exec_prefix\"
6230 prefix="$acl_save_prefix"
6231
6232
6233 # Check whether --with-gnu-ld was given.
6234 if test "${with_gnu_ld+set}" = set; then :
6235 withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
6236 else
6237 with_gnu_ld=no
6238 fi
6239
6240 # Prepare PATH_SEPARATOR.
6241 # The user is always right.
6242 if test "${PATH_SEPARATOR+set}" != set; then
6243 echo "#! /bin/sh" >conf$$.sh
6244 echo "exit 0" >>conf$$.sh
6245 chmod +x conf$$.sh
6246 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
6247 PATH_SEPARATOR=';'
6248 else
6249 PATH_SEPARATOR=:
6250 fi
6251 rm -f conf$$.sh
6252 fi
6253 ac_prog=ld
6254 if test "$GCC" = yes; then
6255 # Check if gcc -print-prog-name=ld gives a path.
6256 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by GCC" >&5
6257 $as_echo_n "checking for ld used by GCC... " >&6; }
6258 case $host in
6259 *-*-mingw*)
6260 # gcc leaves a trailing carriage return which upsets mingw
6261 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
6262 *)
6263 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
6264 esac
6265 case $ac_prog in
6266 # Accept absolute paths.
6267 [\\/]* | [A-Za-z]:[\\/]*)
6268 re_direlt='/[^/][^/]*/\.\./'
6269 # Canonicalize the path of ld
6270 ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
6271 while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
6272 ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
6273 done
6274 test -z "$LD" && LD="$ac_prog"
6275 ;;
6276 "")
6277 # If it fails, then pretend we aren't using GCC.
6278 ac_prog=ld
6279 ;;
6280 *)
6281 # If it is relative, then search for the first ld in PATH.
6282 with_gnu_ld=unknown
6283 ;;
6284 esac
6285 elif test "$with_gnu_ld" = yes; then
6286 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
6287 $as_echo_n "checking for GNU ld... " >&6; }
6288 else
6289 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
6290 $as_echo_n "checking for non-GNU ld... " >&6; }
6291 fi
6292 if ${acl_cv_path_LD+:} false; then :
6293 $as_echo_n "(cached) " >&6
6294 else
6295 if test -z "$LD"; then
6296 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
6297 for ac_dir in $PATH; do
6298 test -z "$ac_dir" && ac_dir=.
6299 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
6300 acl_cv_path_LD="$ac_dir/$ac_prog"
6301 # Check to see if the program is GNU ld. I'd rather use --version,
6302 # but apparently some GNU ld's only accept -v.
6303 # Break only if it was the GNU/non-GNU ld that we prefer.
6304 if "$acl_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
6305 test "$with_gnu_ld" != no && break
6306 else
6307 test "$with_gnu_ld" != yes && break
6308 fi
6309 fi
6310 done
6311 IFS="$ac_save_ifs"
6312 else
6313 acl_cv_path_LD="$LD" # Let the user override the test with a path.
6314 fi
6315 fi
6316
6317 LD="$acl_cv_path_LD"
6318 if test -n "$LD"; then
6319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
6320 $as_echo "$LD" >&6; }
6321 else
6322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6323 $as_echo "no" >&6; }
6324 fi
6325 test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
6326 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
6327 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
6328 if ${acl_cv_prog_gnu_ld+:} false; then :
6329 $as_echo_n "(cached) " >&6
6330 else
6331 # I'd rather use --version here, but apparently some GNU ld's only accept -v.
6332 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
6333 acl_cv_prog_gnu_ld=yes
6334 else
6335 acl_cv_prog_gnu_ld=no
6336 fi
6337 fi
6338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_prog_gnu_ld" >&5
6339 $as_echo "$acl_cv_prog_gnu_ld" >&6; }
6340 with_gnu_ld=$acl_cv_prog_gnu_ld
6341
6342
6343
6344 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shared library run path origin" >&5
6345 $as_echo_n "checking for shared library run path origin... " >&6; }
6346 if ${acl_cv_rpath+:} false; then :
6347 $as_echo_n "(cached) " >&6
6348 else
6349
6350 CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
6351 ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
6352 . ./conftest.sh
6353 rm -f ./conftest.sh
6354 acl_cv_rpath=done
6355
6356 fi
6357 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_rpath" >&5
6358 $as_echo "$acl_cv_rpath" >&6; }
6359 wl="$acl_cv_wl"
6360 libext="$acl_cv_libext"
6361 shlibext="$acl_cv_shlibext"
6362 hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
6363 hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
6364 hardcode_direct="$acl_cv_hardcode_direct"
6365 hardcode_minus_L="$acl_cv_hardcode_minus_L"
6366 # Check whether --enable-rpath was given.
6367 if test "${enable_rpath+set}" = set; then :
6368 enableval=$enable_rpath; :
6369 else
6370 enable_rpath=yes
6371 fi
6372
6373
6374
6375 # Set the 'development' global.
6376 . $srcdir/../bfd/development.sh
6377
6378 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
6379 $as_echo_n "checking for ANSI C header files... " >&6; }
6380 if ${ac_cv_header_stdc+:} false; then :
6381 $as_echo_n "(cached) " >&6
6382 else
6383 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6384 /* end confdefs.h. */
6385 #include <stdlib.h>
6386 #include <stdarg.h>
6387 #include <string.h>
6388 #include <float.h>
6389
6390 int
6391 main ()
6392 {
6393
6394 ;
6395 return 0;
6396 }
6397 _ACEOF
6398 if ac_fn_c_try_compile "$LINENO"; then :
6399 ac_cv_header_stdc=yes
6400 else
6401 ac_cv_header_stdc=no
6402 fi
6403 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6404
6405 if test $ac_cv_header_stdc = yes; then
6406 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6407 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6408 /* end confdefs.h. */
6409 #include <string.h>
6410
6411 _ACEOF
6412 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6413 $EGREP "memchr" >/dev/null 2>&1; then :
6414
6415 else
6416 ac_cv_header_stdc=no
6417 fi
6418 rm -f conftest*
6419
6420 fi
6421
6422 if test $ac_cv_header_stdc = yes; then
6423 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6424 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6425 /* end confdefs.h. */
6426 #include <stdlib.h>
6427
6428 _ACEOF
6429 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6430 $EGREP "free" >/dev/null 2>&1; then :
6431
6432 else
6433 ac_cv_header_stdc=no
6434 fi
6435 rm -f conftest*
6436
6437 fi
6438
6439 if test $ac_cv_header_stdc = yes; then
6440 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6441 if test "$cross_compiling" = yes; then :
6442 :
6443 else
6444 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6445 /* end confdefs.h. */
6446 #include <ctype.h>
6447 #include <stdlib.h>
6448 #if ((' ' & 0x0FF) == 0x020)
6449 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6450 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6451 #else
6452 # define ISLOWER(c) \
6453 (('a' <= (c) && (c) <= 'i') \
6454 || ('j' <= (c) && (c) <= 'r') \
6455 || ('s' <= (c) && (c) <= 'z'))
6456 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6457 #endif
6458
6459 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6460 int
6461 main ()
6462 {
6463 int i;
6464 for (i = 0; i < 256; i++)
6465 if (XOR (islower (i), ISLOWER (i))
6466 || toupper (i) != TOUPPER (i))
6467 return 2;
6468 return 0;
6469 }
6470 _ACEOF
6471 if ac_fn_c_try_run "$LINENO"; then :
6472
6473 else
6474 ac_cv_header_stdc=no
6475 fi
6476 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6477 conftest.$ac_objext conftest.beam conftest.$ac_ext
6478 fi
6479
6480 fi
6481 fi
6482 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
6483 $as_echo "$ac_cv_header_stdc" >&6; }
6484 if test $ac_cv_header_stdc = yes; then
6485
6486 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
6487
6488 fi
6489
6490 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
6491 # for constant arguments. Useless!
6492 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
6493 $as_echo_n "checking for working alloca.h... " >&6; }
6494 if ${ac_cv_working_alloca_h+:} false; then :
6495 $as_echo_n "(cached) " >&6
6496 else
6497 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6498 /* end confdefs.h. */
6499 #include <alloca.h>
6500 int
6501 main ()
6502 {
6503 char *p = (char *) alloca (2 * sizeof (int));
6504 if (p) return 0;
6505 ;
6506 return 0;
6507 }
6508 _ACEOF
6509 if ac_fn_c_try_link "$LINENO"; then :
6510 ac_cv_working_alloca_h=yes
6511 else
6512 ac_cv_working_alloca_h=no
6513 fi
6514 rm -f core conftest.err conftest.$ac_objext \
6515 conftest$ac_exeext conftest.$ac_ext
6516 fi
6517 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
6518 $as_echo "$ac_cv_working_alloca_h" >&6; }
6519 if test $ac_cv_working_alloca_h = yes; then
6520
6521 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
6522
6523 fi
6524
6525 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
6526 $as_echo_n "checking for alloca... " >&6; }
6527 if ${ac_cv_func_alloca_works+:} false; then :
6528 $as_echo_n "(cached) " >&6
6529 else
6530 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6531 /* end confdefs.h. */
6532 #ifdef __GNUC__
6533 # define alloca __builtin_alloca
6534 #else
6535 # ifdef _MSC_VER
6536 # include <malloc.h>
6537 # define alloca _alloca
6538 # else
6539 # ifdef HAVE_ALLOCA_H
6540 # include <alloca.h>
6541 # else
6542 # ifdef _AIX
6543 #pragma alloca
6544 # else
6545 # ifndef alloca /* predefined by HP cc +Olibcalls */
6546 void *alloca (size_t);
6547 # endif
6548 # endif
6549 # endif
6550 # endif
6551 #endif
6552
6553 int
6554 main ()
6555 {
6556 char *p = (char *) alloca (1);
6557 if (p) return 0;
6558 ;
6559 return 0;
6560 }
6561 _ACEOF
6562 if ac_fn_c_try_link "$LINENO"; then :
6563 ac_cv_func_alloca_works=yes
6564 else
6565 ac_cv_func_alloca_works=no
6566 fi
6567 rm -f core conftest.err conftest.$ac_objext \
6568 conftest$ac_exeext conftest.$ac_ext
6569 fi
6570 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
6571 $as_echo "$ac_cv_func_alloca_works" >&6; }
6572
6573 if test $ac_cv_func_alloca_works = yes; then
6574
6575 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
6576
6577 else
6578 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
6579 # that cause trouble. Some versions do not even contain alloca or
6580 # contain a buggy version. If you still want to use their alloca,
6581 # use ar to extract alloca.o from them instead of compiling alloca.c.
6582
6583 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
6584
6585 $as_echo "#define C_ALLOCA 1" >>confdefs.h
6586
6587
6588 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5
6589 $as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; }
6590 if ${ac_cv_os_cray+:} false; then :
6591 $as_echo_n "(cached) " >&6
6592 else
6593 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6594 /* end confdefs.h. */
6595 #if defined CRAY && ! defined CRAY2
6596 webecray
6597 #else
6598 wenotbecray
6599 #endif
6600
6601 _ACEOF
6602 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6603 $EGREP "webecray" >/dev/null 2>&1; then :
6604 ac_cv_os_cray=yes
6605 else
6606 ac_cv_os_cray=no
6607 fi
6608 rm -f conftest*
6609
6610 fi
6611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
6612 $as_echo "$ac_cv_os_cray" >&6; }
6613 if test $ac_cv_os_cray = yes; then
6614 for ac_func in _getb67 GETB67 getb67; do
6615 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
6616 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
6617 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
6618
6619 cat >>confdefs.h <<_ACEOF
6620 #define CRAY_STACKSEG_END $ac_func
6621 _ACEOF
6622
6623 break
6624 fi
6625
6626 done
6627 fi
6628
6629 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
6630 $as_echo_n "checking stack direction for C alloca... " >&6; }
6631 if ${ac_cv_c_stack_direction+:} false; then :
6632 $as_echo_n "(cached) " >&6
6633 else
6634 if test "$cross_compiling" = yes; then :
6635 ac_cv_c_stack_direction=0
6636 else
6637 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6638 /* end confdefs.h. */
6639 $ac_includes_default
6640 int
6641 find_stack_direction (int *addr, int depth)
6642 {
6643 int dir, dummy = 0;
6644 if (! addr)
6645 addr = &dummy;
6646 *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
6647 dir = depth ? find_stack_direction (addr, depth - 1) : 0;
6648 return dir + dummy;
6649 }
6650
6651 int
6652 main (int argc, char **argv)
6653 {
6654 return find_stack_direction (0, argc + !argv + 20) < 0;
6655 }
6656 _ACEOF
6657 if ac_fn_c_try_run "$LINENO"; then :
6658 ac_cv_c_stack_direction=1
6659 else
6660 ac_cv_c_stack_direction=-1
6661 fi
6662 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6663 conftest.$ac_objext conftest.beam conftest.$ac_ext
6664 fi
6665
6666 fi
6667 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
6668 $as_echo "$ac_cv_c_stack_direction" >&6; }
6669 cat >>confdefs.h <<_ACEOF
6670 #define STACK_DIRECTION $ac_cv_c_stack_direction
6671 _ACEOF
6672
6673
6674 fi
6675
6676
6677 WIN32APILIBS=
6678 case ${host} in
6679 *mingw32*)
6680
6681 $as_echo "#define USE_WIN32API 1" >>confdefs.h
6682
6683 WIN32APILIBS="-lws2_32"
6684 ;;
6685 esac
6686
6687
6688 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
6689 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
6690 if ${am_cv_langinfo_codeset+:} false; then :
6691 $as_echo_n "(cached) " >&6
6692 else
6693 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6694 /* end confdefs.h. */
6695 #include <langinfo.h>
6696 int
6697 main ()
6698 {
6699 char* cs = nl_langinfo(CODESET);
6700 ;
6701 return 0;
6702 }
6703 _ACEOF
6704 if ac_fn_c_try_link "$LINENO"; then :
6705 am_cv_langinfo_codeset=yes
6706 else
6707 am_cv_langinfo_codeset=no
6708 fi
6709 rm -f core conftest.err conftest.$ac_objext \
6710 conftest$ac_exeext conftest.$ac_ext
6711
6712 fi
6713 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_langinfo_codeset" >&5
6714 $as_echo "$am_cv_langinfo_codeset" >&6; }
6715 if test $am_cv_langinfo_codeset = yes; then
6716
6717 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
6718
6719 fi
6720
6721
6722 for ac_header in linux/perf_event.h locale.h memory.h signal.h sys/resource.h sys/socket.h sys/un.h sys/wait.h thread_db.h wait.h termios.h dlfcn.h linux/elf.h proc_service.h poll.h sys/poll.h sys/select.h
6723 do :
6724 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6725 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
6726 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
6727 cat >>confdefs.h <<_ACEOF
6728 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
6729 _ACEOF
6730
6731 fi
6732
6733 done
6734
6735
6736
6737 for ac_func in getpagesize
6738 do :
6739 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
6740 if test "x$ac_cv_func_getpagesize" = xyes; then :
6741 cat >>confdefs.h <<_ACEOF
6742 #define HAVE_GETPAGESIZE 1
6743 _ACEOF
6744
6745 fi
6746 done
6747
6748 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
6749 $as_echo_n "checking for working mmap... " >&6; }
6750 if ${ac_cv_func_mmap_fixed_mapped+:} false; then :
6751 $as_echo_n "(cached) " >&6
6752 else
6753 if test "$cross_compiling" = yes; then :
6754 ac_cv_func_mmap_fixed_mapped=no
6755 else
6756 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6757 /* end confdefs.h. */
6758 $ac_includes_default
6759 /* malloc might have been renamed as rpl_malloc. */
6760 #undef malloc
6761
6762 /* Thanks to Mike Haertel and Jim Avera for this test.
6763 Here is a matrix of mmap possibilities:
6764 mmap private not fixed
6765 mmap private fixed at somewhere currently unmapped
6766 mmap private fixed at somewhere already mapped
6767 mmap shared not fixed
6768 mmap shared fixed at somewhere currently unmapped
6769 mmap shared fixed at somewhere already mapped
6770 For private mappings, we should verify that changes cannot be read()
6771 back from the file, nor mmap's back from the file at a different
6772 address. (There have been systems where private was not correctly
6773 implemented like the infamous i386 svr4.0, and systems where the
6774 VM page cache was not coherent with the file system buffer cache
6775 like early versions of FreeBSD and possibly contemporary NetBSD.)
6776 For shared mappings, we should conversely verify that changes get
6777 propagated back to all the places they're supposed to be.
6778
6779 Grep wants private fixed already mapped.
6780 The main things grep needs to know about mmap are:
6781 * does it exist and is it safe to write into the mmap'd area
6782 * how to use it (BSD variants) */
6783
6784 #include <fcntl.h>
6785 #include <sys/mman.h>
6786
6787 #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
6788 char *malloc ();
6789 #endif
6790
6791 /* This mess was copied from the GNU getpagesize.h. */
6792 #ifndef HAVE_GETPAGESIZE
6793 # ifdef _SC_PAGESIZE
6794 # define getpagesize() sysconf(_SC_PAGESIZE)
6795 # else /* no _SC_PAGESIZE */
6796 # ifdef HAVE_SYS_PARAM_H
6797 # include <sys/param.h>
6798 # ifdef EXEC_PAGESIZE
6799 # define getpagesize() EXEC_PAGESIZE
6800 # else /* no EXEC_PAGESIZE */
6801 # ifdef NBPG
6802 # define getpagesize() NBPG * CLSIZE
6803 # ifndef CLSIZE
6804 # define CLSIZE 1
6805 # endif /* no CLSIZE */
6806 # else /* no NBPG */
6807 # ifdef NBPC
6808 # define getpagesize() NBPC
6809 # else /* no NBPC */
6810 # ifdef PAGESIZE
6811 # define getpagesize() PAGESIZE
6812 # endif /* PAGESIZE */
6813 # endif /* no NBPC */
6814 # endif /* no NBPG */
6815 # endif /* no EXEC_PAGESIZE */
6816 # else /* no HAVE_SYS_PARAM_H */
6817 # define getpagesize() 8192 /* punt totally */
6818 # endif /* no HAVE_SYS_PARAM_H */
6819 # endif /* no _SC_PAGESIZE */
6820
6821 #endif /* no HAVE_GETPAGESIZE */
6822
6823 int
6824 main ()
6825 {
6826 char *data, *data2, *data3;
6827 const char *cdata2;
6828 int i, pagesize;
6829 int fd, fd2;
6830
6831 pagesize = getpagesize ();
6832
6833 /* First, make a file with some known garbage in it. */
6834 data = (char *) malloc (pagesize);
6835 if (!data)
6836 return 1;
6837 for (i = 0; i < pagesize; ++i)
6838 *(data + i) = rand ();
6839 umask (0);
6840 fd = creat ("conftest.mmap", 0600);
6841 if (fd < 0)
6842 return 2;
6843 if (write (fd, data, pagesize) != pagesize)
6844 return 3;
6845 close (fd);
6846
6847 /* Next, check that the tail of a page is zero-filled. File must have
6848 non-zero length, otherwise we risk SIGBUS for entire page. */
6849 fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
6850 if (fd2 < 0)
6851 return 4;
6852 cdata2 = "";
6853 if (write (fd2, cdata2, 1) != 1)
6854 return 5;
6855 data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
6856 if (data2 == MAP_FAILED)
6857 return 6;
6858 for (i = 0; i < pagesize; ++i)
6859 if (*(data2 + i))
6860 return 7;
6861 close (fd2);
6862 if (munmap (data2, pagesize))
6863 return 8;
6864
6865 /* Next, try to mmap the file at a fixed address which already has
6866 something else allocated at it. If we can, also make sure that
6867 we see the same garbage. */
6868 fd = open ("conftest.mmap", O_RDWR);
6869 if (fd < 0)
6870 return 9;
6871 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
6872 MAP_PRIVATE | MAP_FIXED, fd, 0L))
6873 return 10;
6874 for (i = 0; i < pagesize; ++i)
6875 if (*(data + i) != *(data2 + i))
6876 return 11;
6877
6878 /* Finally, make sure that changes to the mapped area do not
6879 percolate back to the file as seen by read(). (This is a bug on
6880 some variants of i386 svr4.0.) */
6881 for (i = 0; i < pagesize; ++i)
6882 *(data2 + i) = *(data2 + i) + 1;
6883 data3 = (char *) malloc (pagesize);
6884 if (!data3)
6885 return 12;
6886 if (read (fd, data3, pagesize) != pagesize)
6887 return 13;
6888 for (i = 0; i < pagesize; ++i)
6889 if (*(data + i) != *(data3 + i))
6890 return 14;
6891 close (fd);
6892 return 0;
6893 }
6894 _ACEOF
6895 if ac_fn_c_try_run "$LINENO"; then :
6896 ac_cv_func_mmap_fixed_mapped=yes
6897 else
6898 ac_cv_func_mmap_fixed_mapped=no
6899 fi
6900 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6901 conftest.$ac_objext conftest.beam conftest.$ac_ext
6902 fi
6903
6904 fi
6905 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
6906 $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
6907 if test $ac_cv_func_mmap_fixed_mapped = yes; then
6908
6909 $as_echo "#define HAVE_MMAP 1" >>confdefs.h
6910
6911 fi
6912 rm -f conftest.mmap conftest.txt
6913
6914 for ac_header in vfork.h
6915 do :
6916 ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
6917 if test "x$ac_cv_header_vfork_h" = xyes; then :
6918 cat >>confdefs.h <<_ACEOF
6919 #define HAVE_VFORK_H 1
6920 _ACEOF
6921
6922 fi
6923
6924 done
6925
6926 for ac_func in fork vfork
6927 do :
6928 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
6929 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
6930 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
6931 cat >>confdefs.h <<_ACEOF
6932 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
6933 _ACEOF
6934
6935 fi
6936 done
6937
6938 if test "x$ac_cv_func_fork" = xyes; then
6939 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
6940 $as_echo_n "checking for working fork... " >&6; }
6941 if ${ac_cv_func_fork_works+:} false; then :
6942 $as_echo_n "(cached) " >&6
6943 else
6944 if test "$cross_compiling" = yes; then :
6945 ac_cv_func_fork_works=cross
6946 else
6947 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6948 /* end confdefs.h. */
6949 $ac_includes_default
6950 int
6951 main ()
6952 {
6953
6954 /* By Ruediger Kuhlmann. */
6955 return fork () < 0;
6956
6957 ;
6958 return 0;
6959 }
6960 _ACEOF
6961 if ac_fn_c_try_run "$LINENO"; then :
6962 ac_cv_func_fork_works=yes
6963 else
6964 ac_cv_func_fork_works=no
6965 fi
6966 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6967 conftest.$ac_objext conftest.beam conftest.$ac_ext
6968 fi
6969
6970 fi
6971 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
6972 $as_echo "$ac_cv_func_fork_works" >&6; }
6973
6974 else
6975 ac_cv_func_fork_works=$ac_cv_func_fork
6976 fi
6977 if test "x$ac_cv_func_fork_works" = xcross; then
6978 case $host in
6979 *-*-amigaos* | *-*-msdosdjgpp*)
6980 # Override, as these systems have only a dummy fork() stub
6981 ac_cv_func_fork_works=no
6982 ;;
6983 *)
6984 ac_cv_func_fork_works=yes
6985 ;;
6986 esac
6987 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
6988 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
6989 fi
6990 ac_cv_func_vfork_works=$ac_cv_func_vfork
6991 if test "x$ac_cv_func_vfork" = xyes; then
6992 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
6993 $as_echo_n "checking for working vfork... " >&6; }
6994 if ${ac_cv_func_vfork_works+:} false; then :
6995 $as_echo_n "(cached) " >&6
6996 else
6997 if test "$cross_compiling" = yes; then :
6998 ac_cv_func_vfork_works=cross
6999 else
7000 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7001 /* end confdefs.h. */
7002 /* Thanks to Paul Eggert for this test. */
7003 $ac_includes_default
7004 #include <sys/wait.h>
7005 #ifdef HAVE_VFORK_H
7006 # include <vfork.h>
7007 #endif
7008 /* On some sparc systems, changes by the child to local and incoming
7009 argument registers are propagated back to the parent. The compiler
7010 is told about this with #include <vfork.h>, but some compilers
7011 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
7012 static variable whose address is put into a register that is
7013 clobbered by the vfork. */
7014 static void
7015 #ifdef __cplusplus
7016 sparc_address_test (int arg)
7017 # else
7018 sparc_address_test (arg) int arg;
7019 #endif
7020 {
7021 static pid_t child;
7022 if (!child) {
7023 child = vfork ();
7024 if (child < 0) {
7025 perror ("vfork");
7026 _exit(2);
7027 }
7028 if (!child) {
7029 arg = getpid();
7030 write(-1, "", 0);
7031 _exit (arg);
7032 }
7033 }
7034 }
7035
7036 int
7037 main ()
7038 {
7039 pid_t parent = getpid ();
7040 pid_t child;
7041
7042 sparc_address_test (0);
7043
7044 child = vfork ();
7045
7046 if (child == 0) {
7047 /* Here is another test for sparc vfork register problems. This
7048 test uses lots of local variables, at least as many local
7049 variables as main has allocated so far including compiler
7050 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
7051 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
7052 reuse the register of parent for one of the local variables,
7053 since it will think that parent can't possibly be used any more
7054 in this routine. Assigning to the local variable will thus
7055 munge parent in the parent process. */
7056 pid_t
7057 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
7058 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
7059 /* Convince the compiler that p..p7 are live; otherwise, it might
7060 use the same hardware register for all 8 local variables. */
7061 if (p != p1 || p != p2 || p != p3 || p != p4
7062 || p != p5 || p != p6 || p != p7)
7063 _exit(1);
7064
7065 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
7066 from child file descriptors. If the child closes a descriptor
7067 before it execs or exits, this munges the parent's descriptor
7068 as well. Test for this by closing stdout in the child. */
7069 _exit(close(fileno(stdout)) != 0);
7070 } else {
7071 int status;
7072 struct stat st;
7073
7074 while (wait(&status) != child)
7075 ;
7076 return (
7077 /* Was there some problem with vforking? */
7078 child < 0
7079
7080 /* Did the child fail? (This shouldn't happen.) */
7081 || status
7082
7083 /* Did the vfork/compiler bug occur? */
7084 || parent != getpid()
7085
7086 /* Did the file descriptor bug occur? */
7087 || fstat(fileno(stdout), &st) != 0
7088 );
7089 }
7090 }
7091 _ACEOF
7092 if ac_fn_c_try_run "$LINENO"; then :
7093 ac_cv_func_vfork_works=yes
7094 else
7095 ac_cv_func_vfork_works=no
7096 fi
7097 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7098 conftest.$ac_objext conftest.beam conftest.$ac_ext
7099 fi
7100
7101 fi
7102 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
7103 $as_echo "$ac_cv_func_vfork_works" >&6; }
7104
7105 fi;
7106 if test "x$ac_cv_func_fork_works" = xcross; then
7107 ac_cv_func_vfork_works=$ac_cv_func_vfork
7108 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
7109 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
7110 fi
7111
7112 if test "x$ac_cv_func_vfork_works" = xyes; then
7113
7114 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
7115
7116 else
7117
7118 $as_echo "#define vfork fork" >>confdefs.h
7119
7120 fi
7121 if test "x$ac_cv_func_fork_works" = xyes; then
7122
7123 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
7124
7125 fi
7126
7127 for ac_func in fdwalk getrlimit pipe pipe2 poll socketpair sigaction \
7128 ptrace64 sbrk setns sigaltstack sigprocmask \
7129 setpgid setpgrp getrusage getauxval sigtimedwait
7130 do :
7131 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
7132 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
7133 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
7134 cat >>confdefs.h <<_ACEOF
7135 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
7136 _ACEOF
7137
7138 fi
7139 done
7140
7141
7142 ac_fn_c_check_decl "$LINENO" "strstr" "ac_cv_have_decl_strstr" "$ac_includes_default"
7143 if test "x$ac_cv_have_decl_strstr" = xyes; then :
7144 ac_have_decl=1
7145 else
7146 ac_have_decl=0
7147 fi
7148
7149 cat >>confdefs.h <<_ACEOF
7150 #define HAVE_DECL_STRSTR $ac_have_decl
7151 _ACEOF
7152
7153
7154 # ----------------------- #
7155 # Checks for structures. #
7156 # ----------------------- #
7157
7158 ac_fn_c_check_member "$LINENO" "struct stat" "st_blocks" "ac_cv_member_struct_stat_st_blocks" "$ac_includes_default"
7159 if test "x$ac_cv_member_struct_stat_st_blocks" = xyes; then :
7160
7161 cat >>confdefs.h <<_ACEOF
7162 #define HAVE_STRUCT_STAT_ST_BLOCKS 1
7163 _ACEOF
7164
7165
7166 fi
7167 ac_fn_c_check_member "$LINENO" "struct stat" "st_blksize" "ac_cv_member_struct_stat_st_blksize" "$ac_includes_default"
7168 if test "x$ac_cv_member_struct_stat_st_blksize" = xyes; then :
7169
7170 cat >>confdefs.h <<_ACEOF
7171 #define HAVE_STRUCT_STAT_ST_BLKSIZE 1
7172 _ACEOF
7173
7174
7175 fi
7176
7177
7178 # On FreeBSD we need libutil for the kinfo_get* functions. On
7179 # GNU/kFreeBSD systems, FreeBSD libutil is renamed to libutil-freebsd.
7180 # Figure out which one to use.
7181 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing kinfo_getfile" >&5
7182 $as_echo_n "checking for library containing kinfo_getfile... " >&6; }
7183 if ${ac_cv_search_kinfo_getfile+:} false; then :
7184 $as_echo_n "(cached) " >&6
7185 else
7186 ac_func_search_save_LIBS=$LIBS
7187 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7188 /* end confdefs.h. */
7189
7190 /* Override any GCC internal prototype to avoid an error.
7191 Use char because int might match the return type of a GCC
7192 builtin and then its argument prototype would still apply. */
7193 #ifdef __cplusplus
7194 extern "C"
7195 #endif
7196 char kinfo_getfile ();
7197 int
7198 main ()
7199 {
7200 return kinfo_getfile ();
7201 ;
7202 return 0;
7203 }
7204 _ACEOF
7205 for ac_lib in '' util util-freebsd; do
7206 if test -z "$ac_lib"; then
7207 ac_res="none required"
7208 else
7209 ac_res=-l$ac_lib
7210 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
7211 fi
7212 if ac_fn_c_try_link "$LINENO"; then :
7213 ac_cv_search_kinfo_getfile=$ac_res
7214 fi
7215 rm -f core conftest.err conftest.$ac_objext \
7216 conftest$ac_exeext
7217 if ${ac_cv_search_kinfo_getfile+:} false; then :
7218 break
7219 fi
7220 done
7221 if ${ac_cv_search_kinfo_getfile+:} false; then :
7222
7223 else
7224 ac_cv_search_kinfo_getfile=no
7225 fi
7226 rm conftest.$ac_ext
7227 LIBS=$ac_func_search_save_LIBS
7228 fi
7229 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_kinfo_getfile" >&5
7230 $as_echo "$ac_cv_search_kinfo_getfile" >&6; }
7231 ac_res=$ac_cv_search_kinfo_getfile
7232 if test "$ac_res" != no; then :
7233 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7234
7235 fi
7236
7237
7238 # Define HAVE_KINFO_GETFILE if kinfo_getfile is available.
7239 for ac_func in kinfo_getfile
7240 do :
7241 ac_fn_c_check_func "$LINENO" "kinfo_getfile" "ac_cv_func_kinfo_getfile"
7242 if test "x$ac_cv_func_kinfo_getfile" = xyes; then :
7243 cat >>confdefs.h <<_ACEOF
7244 #define HAVE_KINFO_GETFILE 1
7245 _ACEOF
7246
7247 fi
7248 done
7249
7250
7251 # Check for std::thread. This does not work on some platforms, like
7252 # mingw and DJGPP.
7253 ac_ext=cpp
7254 ac_cpp='$CXXCPP $CPPFLAGS'
7255 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7256 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7257 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
7258
7259
7260
7261
7262
7263 ac_ext=c
7264 ac_cpp='$CPP $CPPFLAGS'
7265 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7266 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7267 ac_compiler_gnu=$ac_cv_c_compiler_gnu
7268
7269 ax_pthread_ok=no
7270
7271 # We used to check for pthread.h first, but this fails if pthread.h
7272 # requires special compiler flags (e.g. on Tru64 or Sequent).
7273 # It gets checked for in the link test anyway.
7274
7275 # First of all, check if the user has set any of the PTHREAD_LIBS,
7276 # etcetera environment variables, and if threads linking works using
7277 # them:
7278 if test "x$PTHREAD_CFLAGS$PTHREAD_LIBS" != "x"; then
7279 ax_pthread_save_CC="$CC"
7280 ax_pthread_save_CFLAGS="$CFLAGS"
7281 ax_pthread_save_LIBS="$LIBS"
7282 if test "x$PTHREAD_CC" != "x"; then :
7283 CC="$PTHREAD_CC"
7284 fi
7285 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
7286 LIBS="$PTHREAD_LIBS $LIBS"
7287 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_join using $CC $PTHREAD_CFLAGS $PTHREAD_LIBS" >&5
7288 $as_echo_n "checking for pthread_join using $CC $PTHREAD_CFLAGS $PTHREAD_LIBS... " >&6; }
7289 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7290 /* end confdefs.h. */
7291
7292 /* Override any GCC internal prototype to avoid an error.
7293 Use char because int might match the return type of a GCC
7294 builtin and then its argument prototype would still apply. */
7295 #ifdef __cplusplus
7296 extern "C"
7297 #endif
7298 char pthread_join ();
7299 int
7300 main ()
7301 {
7302 return pthread_join ();
7303 ;
7304 return 0;
7305 }
7306 _ACEOF
7307 if ac_fn_c_try_link "$LINENO"; then :
7308 ax_pthread_ok=yes
7309 fi
7310 rm -f core conftest.err conftest.$ac_objext \
7311 conftest$ac_exeext conftest.$ac_ext
7312 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5
7313 $as_echo "$ax_pthread_ok" >&6; }
7314 if test "x$ax_pthread_ok" = "xno"; then
7315 PTHREAD_LIBS=""
7316 PTHREAD_CFLAGS=""
7317 fi
7318 CC="$ax_pthread_save_CC"
7319 CFLAGS="$ax_pthread_save_CFLAGS"
7320 LIBS="$ax_pthread_save_LIBS"
7321 fi
7322
7323 # We must check for the threads library under a number of different
7324 # names; the ordering is very important because some systems
7325 # (e.g. DEC) have both -lpthread and -lpthreads, where one of the
7326 # libraries is broken (non-POSIX).
7327
7328 # Create a list of thread flags to try. Items starting with a "-" are
7329 # C compiler flags, and other items are library names, except for "none"
7330 # which indicates that we try without any flags at all, and "pthread-config"
7331 # which is a program returning the flags for the Pth emulation library.
7332
7333 ax_pthread_flags="pthreads none -Kthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config"
7334
7335 # The ordering *is* (sometimes) important. Some notes on the
7336 # individual items follow:
7337
7338 # pthreads: AIX (must check this before -lpthread)
7339 # none: in case threads are in libc; should be tried before -Kthread and
7340 # other compiler flags to prevent continual compiler warnings
7341 # -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
7342 # -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads), Tru64
7343 # (Note: HP C rejects this with "bad form for `-t' option")
7344 # -pthreads: Solaris/gcc (Note: HP C also rejects)
7345 # -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
7346 # doesn't hurt to check since this sometimes defines pthreads and
7347 # -D_REENTRANT too), HP C (must be checked before -lpthread, which
7348 # is present but should not be used directly; and before -mthreads,
7349 # because the compiler interprets this as "-mt" + "-hreads")
7350 # -mthreads: Mingw32/gcc, Lynx/gcc
7351 # pthread: Linux, etcetera
7352 # --thread-safe: KAI C++
7353 # pthread-config: use pthread-config program (for GNU Pth library)
7354
7355 case $host_os in
7356
7357 freebsd*)
7358
7359 # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
7360 # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
7361
7362 ax_pthread_flags="-kthread lthread $ax_pthread_flags"
7363 ;;
7364
7365 hpux*)
7366
7367 # From the cc(1) man page: "[-mt] Sets various -D flags to enable
7368 # multi-threading and also sets -lpthread."
7369
7370 ax_pthread_flags="-mt -pthread pthread $ax_pthread_flags"
7371 ;;
7372
7373 openedition*)
7374
7375 # IBM z/OS requires a feature-test macro to be defined in order to
7376 # enable POSIX threads at all, so give the user a hint if this is
7377 # not set. (We don't define these ourselves, as they can affect
7378 # other portions of the system API in unpredictable ways.)
7379
7380 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7381 /* end confdefs.h. */
7382
7383 # if !defined(_OPEN_THREADS) && !defined(_UNIX03_THREADS)
7384 AX_PTHREAD_ZOS_MISSING
7385 # endif
7386
7387 _ACEOF
7388 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7389 $EGREP "AX_PTHREAD_ZOS_MISSING" >/dev/null 2>&1; then :
7390 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: IBM z/OS requires -D_OPEN_THREADS or -D_UNIX03_THREADS to enable pthreads support." >&5
7391 $as_echo "$as_me: WARNING: IBM z/OS requires -D_OPEN_THREADS or -D_UNIX03_THREADS to enable pthreads support." >&2;}
7392 fi
7393 rm -f conftest*
7394
7395 ;;
7396
7397 solaris*)
7398
7399 # On Solaris (at least, for some versions), libc contains stubbed
7400 # (non-functional) versions of the pthreads routines, so link-based
7401 # tests will erroneously succeed. (N.B.: The stubs are missing
7402 # pthread_cleanup_push, or rather a function called by this macro,
7403 # so we could check for that, but who knows whether they'll stub
7404 # that too in a future libc.) So we'll check first for the
7405 # standard Solaris way of linking pthreads (-mt -lpthread).
7406
7407 ax_pthread_flags="-mt,pthread pthread $ax_pthread_flags"
7408 ;;
7409 esac
7410
7411 # GCC generally uses -pthread, or -pthreads on some platforms (e.g. SPARC)
7412
7413 if test "x$GCC" = "xyes"; then :
7414 ax_pthread_flags="-pthread -pthreads $ax_pthread_flags"
7415 fi
7416
7417 # The presence of a feature test macro requesting re-entrant function
7418 # definitions is, on some systems, a strong hint that pthreads support is
7419 # correctly enabled
7420
7421 case $host_os in
7422 darwin* | hpux* | linux* | osf* | solaris*)
7423 ax_pthread_check_macro="_REENTRANT"
7424 ;;
7425
7426 aix*)
7427 ax_pthread_check_macro="_THREAD_SAFE"
7428 ;;
7429
7430 *)
7431 ax_pthread_check_macro="--"
7432 ;;
7433 esac
7434 if test "x$ax_pthread_check_macro" = "x--"; then :
7435 ax_pthread_check_cond=0
7436 else
7437 ax_pthread_check_cond="!defined($ax_pthread_check_macro)"
7438 fi
7439
7440 # Are we compiling with Clang?
7441
7442 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC is Clang" >&5
7443 $as_echo_n "checking whether $CC is Clang... " >&6; }
7444 if ${ax_cv_PTHREAD_CLANG+:} false; then :
7445 $as_echo_n "(cached) " >&6
7446 else
7447 ax_cv_PTHREAD_CLANG=no
7448 # Note that Autoconf sets GCC=yes for Clang as well as GCC
7449 if test "x$GCC" = "xyes"; then
7450 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7451 /* end confdefs.h. */
7452 /* Note: Clang 2.7 lacks __clang_[a-z]+__ */
7453 # if defined(__clang__) && defined(__llvm__)
7454 AX_PTHREAD_CC_IS_CLANG
7455 # endif
7456
7457 _ACEOF
7458 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7459 $EGREP "AX_PTHREAD_CC_IS_CLANG" >/dev/null 2>&1; then :
7460 ax_cv_PTHREAD_CLANG=yes
7461 fi
7462 rm -f conftest*
7463
7464 fi
7465
7466 fi
7467 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_CLANG" >&5
7468 $as_echo "$ax_cv_PTHREAD_CLANG" >&6; }
7469 ax_pthread_clang="$ax_cv_PTHREAD_CLANG"
7470
7471 ax_pthread_clang_warning=no
7472
7473 # Clang needs special handling, because older versions handle the -pthread
7474 # option in a rather... idiosyncratic way
7475
7476 if test "x$ax_pthread_clang" = "xyes"; then
7477
7478 # Clang takes -pthread; it has never supported any other flag
7479
7480 # (Note 1: This will need to be revisited if a system that Clang
7481 # supports has POSIX threads in a separate library. This tends not
7482 # to be the way of modern systems, but it's conceivable.)
7483
7484 # (Note 2: On some systems, notably Darwin, -pthread is not needed
7485 # to get POSIX threads support; the API is always present and
7486 # active. We could reasonably leave PTHREAD_CFLAGS empty. But
7487 # -pthread does define _REENTRANT, and while the Darwin headers
7488 # ignore this macro, third-party headers might not.)
7489
7490 PTHREAD_CFLAGS="-pthread"
7491 PTHREAD_LIBS=
7492
7493 ax_pthread_ok=yes
7494
7495 # However, older versions of Clang make a point of warning the user
7496 # that, in an invocation where only linking and no compilation is
7497 # taking place, the -pthread option has no effect ("argument unused
7498 # during compilation"). They expect -pthread to be passed in only
7499 # when source code is being compiled.
7500 #
7501 # Problem is, this is at odds with the way Automake and most other
7502 # C build frameworks function, which is that the same flags used in
7503 # compilation (CFLAGS) are also used in linking. Many systems
7504 # supported by AX_PTHREAD require exactly this for POSIX threads
7505 # support, and in fact it is often not straightforward to specify a
7506 # flag that is used only in the compilation phase and not in
7507 # linking. Such a scenario is extremely rare in practice.
7508 #
7509 # Even though use of the -pthread flag in linking would only print
7510 # a warning, this can be a nuisance for well-run software projects
7511 # that build with -Werror. So if the active version of Clang has
7512 # this misfeature, we search for an option to squash it.
7513
7514 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether Clang needs flag to prevent \"argument unused\" warning when linking with -pthread" >&5
7515 $as_echo_n "checking whether Clang needs flag to prevent \"argument unused\" warning when linking with -pthread... " >&6; }
7516 if ${ax_cv_PTHREAD_CLANG_NO_WARN_FLAG+:} false; then :
7517 $as_echo_n "(cached) " >&6
7518 else
7519 ax_cv_PTHREAD_CLANG_NO_WARN_FLAG=unknown
7520 # Create an alternate version of $ac_link that compiles and
7521 # links in two steps (.c -> .o, .o -> exe) instead of one
7522 # (.c -> exe), because the warning occurs only in the second
7523 # step
7524 ax_pthread_save_ac_link="$ac_link"
7525 ax_pthread_sed='s/conftest\.\$ac_ext/conftest.$ac_objext/g'
7526 ax_pthread_link_step=`$as_echo "$ac_link" | sed "$ax_pthread_sed"`
7527 ax_pthread_2step_ac_link="($ac_compile) && (echo ==== >&5) && ($ax_pthread_link_step)"
7528 ax_pthread_save_CFLAGS="$CFLAGS"
7529 for ax_pthread_try in '' -Qunused-arguments -Wno-unused-command-line-argument unknown; do
7530 if test "x$ax_pthread_try" = "xunknown"; then :
7531 break
7532 fi
7533 CFLAGS="-Werror -Wunknown-warning-option $ax_pthread_try -pthread $ax_pthread_save_CFLAGS"
7534 ac_link="$ax_pthread_save_ac_link"
7535 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7536 /* end confdefs.h. */
7537 int main(void){return 0;}
7538 _ACEOF
7539 if ac_fn_c_try_link "$LINENO"; then :
7540 ac_link="$ax_pthread_2step_ac_link"
7541 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7542 /* end confdefs.h. */
7543 int main(void){return 0;}
7544 _ACEOF
7545 if ac_fn_c_try_link "$LINENO"; then :
7546 break
7547 fi
7548 rm -f core conftest.err conftest.$ac_objext \
7549 conftest$ac_exeext conftest.$ac_ext
7550
7551 fi
7552 rm -f core conftest.err conftest.$ac_objext \
7553 conftest$ac_exeext conftest.$ac_ext
7554 done
7555 ac_link="$ax_pthread_save_ac_link"
7556 CFLAGS="$ax_pthread_save_CFLAGS"
7557 if test "x$ax_pthread_try" = "x"; then :
7558 ax_pthread_try=no
7559 fi
7560 ax_cv_PTHREAD_CLANG_NO_WARN_FLAG="$ax_pthread_try"
7561
7562 fi
7563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" >&5
7564 $as_echo "$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" >&6; }
7565
7566 case "$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" in
7567 no | unknown) ;;
7568 *) PTHREAD_CFLAGS="$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG $PTHREAD_CFLAGS" ;;
7569 esac
7570
7571 fi # $ax_pthread_clang = yes
7572
7573 if test "x$ax_pthread_ok" = "xno"; then
7574 for ax_pthread_try_flag in $ax_pthread_flags; do
7575
7576 case $ax_pthread_try_flag in
7577 none)
7578 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work without any flags" >&5
7579 $as_echo_n "checking whether pthreads work without any flags... " >&6; }
7580 ;;
7581
7582 -mt,pthread)
7583 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with -mt -lpthread" >&5
7584 $as_echo_n "checking whether pthreads work with -mt -lpthread... " >&6; }
7585 PTHREAD_CFLAGS="-mt"
7586 PTHREAD_LIBS="-lpthread"
7587 ;;
7588
7589 -*)
7590 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with $ax_pthread_try_flag" >&5
7591 $as_echo_n "checking whether pthreads work with $ax_pthread_try_flag... " >&6; }
7592 PTHREAD_CFLAGS="$ax_pthread_try_flag"
7593 ;;
7594
7595 pthread-config)
7596 # Extract the first word of "pthread-config", so it can be a program name with args.
7597 set dummy pthread-config; ac_word=$2
7598 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7599 $as_echo_n "checking for $ac_word... " >&6; }
7600 if ${ac_cv_prog_ax_pthread_config+:} false; then :
7601 $as_echo_n "(cached) " >&6
7602 else
7603 if test -n "$ax_pthread_config"; then
7604 ac_cv_prog_ax_pthread_config="$ax_pthread_config" # Let the user override the test.
7605 else
7606 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7607 for as_dir in $PATH
7608 do
7609 IFS=$as_save_IFS
7610 test -z "$as_dir" && as_dir=.
7611 for ac_exec_ext in '' $ac_executable_extensions; do
7612 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7613 ac_cv_prog_ax_pthread_config="yes"
7614 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7615 break 2
7616 fi
7617 done
7618 done
7619 IFS=$as_save_IFS
7620
7621 test -z "$ac_cv_prog_ax_pthread_config" && ac_cv_prog_ax_pthread_config="no"
7622 fi
7623 fi
7624 ax_pthread_config=$ac_cv_prog_ax_pthread_config
7625 if test -n "$ax_pthread_config"; then
7626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_config" >&5
7627 $as_echo "$ax_pthread_config" >&6; }
7628 else
7629 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7630 $as_echo "no" >&6; }
7631 fi
7632
7633
7634 if test "x$ax_pthread_config" = "xno"; then :
7635 continue
7636 fi
7637 PTHREAD_CFLAGS="`pthread-config --cflags`"
7638 PTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
7639 ;;
7640
7641 *)
7642 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the pthreads library -l$ax_pthread_try_flag" >&5
7643 $as_echo_n "checking for the pthreads library -l$ax_pthread_try_flag... " >&6; }
7644 PTHREAD_LIBS="-l$ax_pthread_try_flag"
7645 ;;
7646 esac
7647
7648 ax_pthread_save_CFLAGS="$CFLAGS"
7649 ax_pthread_save_LIBS="$LIBS"
7650 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
7651 LIBS="$PTHREAD_LIBS $LIBS"
7652
7653 # Check for various functions. We must include pthread.h,
7654 # since some functions may be macros. (On the Sequent, we
7655 # need a special flag -Kthread to make this header compile.)
7656 # We check for pthread_join because it is in -lpthread on IRIX
7657 # while pthread_create is in libc. We check for pthread_attr_init
7658 # due to DEC craziness with -lpthreads. We check for
7659 # pthread_cleanup_push because it is one of the few pthread
7660 # functions on Solaris that doesn't have a non-functional libc stub.
7661 # We try pthread_create on general principles.
7662
7663 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7664 /* end confdefs.h. */
7665 #include <pthread.h>
7666 # if $ax_pthread_check_cond
7667 # error "$ax_pthread_check_macro must be defined"
7668 # endif
7669 static void routine(void *a) { a = 0; }
7670 static void *start_routine(void *a) { return a; }
7671 int
7672 main ()
7673 {
7674 pthread_t th; pthread_attr_t attr;
7675 pthread_create(&th, 0, start_routine, 0);
7676 pthread_join(th, 0);
7677 pthread_attr_init(&attr);
7678 pthread_cleanup_push(routine, 0);
7679 pthread_cleanup_pop(0) /* ; */
7680 ;
7681 return 0;
7682 }
7683 _ACEOF
7684 if ac_fn_c_try_link "$LINENO"; then :
7685 ax_pthread_ok=yes
7686 fi
7687 rm -f core conftest.err conftest.$ac_objext \
7688 conftest$ac_exeext conftest.$ac_ext
7689
7690 CFLAGS="$ax_pthread_save_CFLAGS"
7691 LIBS="$ax_pthread_save_LIBS"
7692
7693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5
7694 $as_echo "$ax_pthread_ok" >&6; }
7695 if test "x$ax_pthread_ok" = "xyes"; then :
7696 break
7697 fi
7698
7699 PTHREAD_LIBS=""
7700 PTHREAD_CFLAGS=""
7701 done
7702 fi
7703
7704 # Various other checks:
7705 if test "x$ax_pthread_ok" = "xyes"; then
7706 ax_pthread_save_CFLAGS="$CFLAGS"
7707 ax_pthread_save_LIBS="$LIBS"
7708 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
7709 LIBS="$PTHREAD_LIBS $LIBS"
7710
7711 # Detect AIX lossage: JOINABLE attribute is called UNDETACHED.
7712 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for joinable pthread attribute" >&5
7713 $as_echo_n "checking for joinable pthread attribute... " >&6; }
7714 if ${ax_cv_PTHREAD_JOINABLE_ATTR+:} false; then :
7715 $as_echo_n "(cached) " >&6
7716 else
7717 ax_cv_PTHREAD_JOINABLE_ATTR=unknown
7718 for ax_pthread_attr in PTHREAD_CREATE_JOINABLE PTHREAD_CREATE_UNDETACHED; do
7719 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7720 /* end confdefs.h. */
7721 #include <pthread.h>
7722 int
7723 main ()
7724 {
7725 int attr = $ax_pthread_attr; return attr /* ; */
7726 ;
7727 return 0;
7728 }
7729 _ACEOF
7730 if ac_fn_c_try_link "$LINENO"; then :
7731 ax_cv_PTHREAD_JOINABLE_ATTR=$ax_pthread_attr; break
7732 fi
7733 rm -f core conftest.err conftest.$ac_objext \
7734 conftest$ac_exeext conftest.$ac_ext
7735 done
7736
7737 fi
7738 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_JOINABLE_ATTR" >&5
7739 $as_echo "$ax_cv_PTHREAD_JOINABLE_ATTR" >&6; }
7740 if test "x$ax_cv_PTHREAD_JOINABLE_ATTR" != "xunknown" && \
7741 test "x$ax_cv_PTHREAD_JOINABLE_ATTR" != "xPTHREAD_CREATE_JOINABLE" && \
7742 test "x$ax_pthread_joinable_attr_defined" != "xyes"; then :
7743
7744 cat >>confdefs.h <<_ACEOF
7745 #define PTHREAD_CREATE_JOINABLE $ax_cv_PTHREAD_JOINABLE_ATTR
7746 _ACEOF
7747
7748 ax_pthread_joinable_attr_defined=yes
7749
7750 fi
7751
7752 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether more special flags are required for pthreads" >&5
7753 $as_echo_n "checking whether more special flags are required for pthreads... " >&6; }
7754 if ${ax_cv_PTHREAD_SPECIAL_FLAGS+:} false; then :
7755 $as_echo_n "(cached) " >&6
7756 else
7757 ax_cv_PTHREAD_SPECIAL_FLAGS=no
7758 case $host_os in
7759 solaris*)
7760 ax_cv_PTHREAD_SPECIAL_FLAGS="-D_POSIX_PTHREAD_SEMANTICS"
7761 ;;
7762 esac
7763
7764 fi
7765 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_SPECIAL_FLAGS" >&5
7766 $as_echo "$ax_cv_PTHREAD_SPECIAL_FLAGS" >&6; }
7767 if test "x$ax_cv_PTHREAD_SPECIAL_FLAGS" != "xno" && \
7768 test "x$ax_pthread_special_flags_added" != "xyes"; then :
7769 PTHREAD_CFLAGS="$ax_cv_PTHREAD_SPECIAL_FLAGS $PTHREAD_CFLAGS"
7770 ax_pthread_special_flags_added=yes
7771 fi
7772
7773 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTHREAD_PRIO_INHERIT" >&5
7774 $as_echo_n "checking for PTHREAD_PRIO_INHERIT... " >&6; }
7775 if ${ax_cv_PTHREAD_PRIO_INHERIT+:} false; then :
7776 $as_echo_n "(cached) " >&6
7777 else
7778 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7779 /* end confdefs.h. */
7780 #include <pthread.h>
7781 int
7782 main ()
7783 {
7784 int i = PTHREAD_PRIO_INHERIT;
7785 ;
7786 return 0;
7787 }
7788 _ACEOF
7789 if ac_fn_c_try_link "$LINENO"; then :
7790 ax_cv_PTHREAD_PRIO_INHERIT=yes
7791 else
7792 ax_cv_PTHREAD_PRIO_INHERIT=no
7793 fi
7794 rm -f core conftest.err conftest.$ac_objext \
7795 conftest$ac_exeext conftest.$ac_ext
7796
7797 fi
7798 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_PRIO_INHERIT" >&5
7799 $as_echo "$ax_cv_PTHREAD_PRIO_INHERIT" >&6; }
7800 if test "x$ax_cv_PTHREAD_PRIO_INHERIT" = "xyes" && \
7801 test "x$ax_pthread_prio_inherit_defined" != "xyes"; then :
7802
7803 $as_echo "#define HAVE_PTHREAD_PRIO_INHERIT 1" >>confdefs.h
7804
7805 ax_pthread_prio_inherit_defined=yes
7806
7807 fi
7808
7809 CFLAGS="$ax_pthread_save_CFLAGS"
7810 LIBS="$ax_pthread_save_LIBS"
7811
7812 # More AIX lossage: compile with *_r variant
7813 if test "x$GCC" != "xyes"; then
7814 case $host_os in
7815 aix*)
7816 case "x/$CC" in #(
7817 x*/c89|x*/c89_128|x*/c99|x*/c99_128|x*/cc|x*/cc128|x*/xlc|x*/xlc_v6|x*/xlc128|x*/xlc128_v6) :
7818 #handle absolute path differently from PATH based program lookup
7819 case "x$CC" in #(
7820 x/*) :
7821 if as_fn_executable_p ${CC}_r; then :
7822 PTHREAD_CC="${CC}_r"
7823 fi ;; #(
7824 *) :
7825 for ac_prog in ${CC}_r
7826 do
7827 # Extract the first word of "$ac_prog", so it can be a program name with args.
7828 set dummy $ac_prog; ac_word=$2
7829 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7830 $as_echo_n "checking for $ac_word... " >&6; }
7831 if ${ac_cv_prog_PTHREAD_CC+:} false; then :
7832 $as_echo_n "(cached) " >&6
7833 else
7834 if test -n "$PTHREAD_CC"; then
7835 ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
7836 else
7837 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7838 for as_dir in $PATH
7839 do
7840 IFS=$as_save_IFS
7841 test -z "$as_dir" && as_dir=.
7842 for ac_exec_ext in '' $ac_executable_extensions; do
7843 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7844 ac_cv_prog_PTHREAD_CC="$ac_prog"
7845 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7846 break 2
7847 fi
7848 done
7849 done
7850 IFS=$as_save_IFS
7851
7852 fi
7853 fi
7854 PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
7855 if test -n "$PTHREAD_CC"; then
7856 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PTHREAD_CC" >&5
7857 $as_echo "$PTHREAD_CC" >&6; }
7858 else
7859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7860 $as_echo "no" >&6; }
7861 fi
7862
7863
7864 test -n "$PTHREAD_CC" && break
7865 done
7866 test -n "$PTHREAD_CC" || PTHREAD_CC="$CC"
7867 ;;
7868 esac ;; #(
7869 *) :
7870 ;;
7871 esac
7872 ;;
7873 esac
7874 fi
7875 fi
7876
7877 test -n "$PTHREAD_CC" || PTHREAD_CC="$CC"
7878
7879
7880
7881
7882
7883 # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
7884 if test "x$ax_pthread_ok" = "xyes"; then
7885 threads=yes
7886 :
7887 else
7888 ax_pthread_ok=no
7889 threads=no
7890 fi
7891 ac_ext=cpp
7892 ac_cpp='$CXXCPP $CPPFLAGS'
7893 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7894 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7895 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
7896
7897
7898 if test "$threads" = "yes"; then
7899 save_LIBS="$LIBS"
7900 LIBS="$PTHREAD_LIBS $LIBS"
7901 save_CXXFLAGS="$CXXFLAGS"
7902 CXXFLAGS="$PTHREAD_CFLAGS $save_CXXFLAGS"
7903 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for std::thread" >&5
7904 $as_echo_n "checking for std::thread... " >&6; }
7905 if ${gdb_cv_cxx_std_thread+:} false; then :
7906 $as_echo_n "(cached) " >&6
7907 else
7908 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7909 /* end confdefs.h. */
7910 #include <thread>
7911 void callback() { }
7912 int
7913 main ()
7914 {
7915 std::thread t(callback);
7916 ;
7917 return 0;
7918 }
7919 _ACEOF
7920 if ac_fn_cxx_try_compile "$LINENO"; then :
7921 gdb_cv_cxx_std_thread=yes
7922 else
7923 gdb_cv_cxx_std_thread=no
7924 fi
7925 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7926 fi
7927 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_cxx_std_thread" >&5
7928 $as_echo "$gdb_cv_cxx_std_thread" >&6; }
7929
7930 # This check must be here, while LIBS includes any necessary
7931 # threading library.
7932 for ac_func in pthread_sigmask pthread_setname_np
7933 do :
7934 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
7935 ac_fn_cxx_check_func "$LINENO" "$ac_func" "$as_ac_var"
7936 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
7937 cat >>confdefs.h <<_ACEOF
7938 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
7939 _ACEOF
7940
7941 fi
7942 done
7943
7944
7945 LIBS="$save_LIBS"
7946 CXXFLAGS="$save_CXXFLAGS"
7947 fi
7948 if test "$gdb_cv_cxx_std_thread" = "yes"; then
7949
7950 $as_echo "#define CXX_STD_THREAD 1" >>confdefs.h
7951
7952 fi
7953 ac_ext=c
7954 ac_cpp='$CPP $CPPFLAGS'
7955 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7956 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7957 ac_compiler_gnu=$ac_cv_c_compiler_gnu
7958
7959
7960 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigsetjmp" >&5
7961 $as_echo_n "checking for sigsetjmp... " >&6; }
7962 if ${gdb_cv_func_sigsetjmp+:} false; then :
7963 $as_echo_n "(cached) " >&6
7964 else
7965 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7966 /* end confdefs.h. */
7967 #include <setjmp.h>
7968 int
7969 main ()
7970 {
7971 sigjmp_buf env;
7972 while (! sigsetjmp (env, 1))
7973 siglongjmp (env, 1);
7974
7975 ;
7976 return 0;
7977 }
7978 _ACEOF
7979 if ac_fn_c_try_compile "$LINENO"; then :
7980 gdb_cv_func_sigsetjmp=yes
7981 else
7982 gdb_cv_func_sigsetjmp=no
7983
7984 fi
7985 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7986
7987 fi
7988 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_func_sigsetjmp" >&5
7989 $as_echo "$gdb_cv_func_sigsetjmp" >&6; }
7990 if test "$gdb_cv_func_sigsetjmp" = "yes"; then
7991
7992 $as_echo "#define HAVE_SIGSETJMP 1" >>confdefs.h
7993
7994 fi
7995
7996
7997 # Check whether --with-intel_pt was given.
7998 if test "${with_intel_pt+set}" = set; then :
7999 withval=$with_intel_pt;
8000 else
8001 with_intel_pt=auto
8002 fi
8003
8004 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use intel pt" >&5
8005 $as_echo_n "checking whether to use intel pt... " >&6; }
8006 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_intel_pt" >&5
8007 $as_echo "$with_intel_pt" >&6; }
8008
8009 if test "${with_intel_pt}" = no; then
8010 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Intel Processor Trace support disabled; some features may be unavailable." >&5
8011 $as_echo "$as_me: WARNING: Intel Processor Trace support disabled; some features may be unavailable." >&2;}
8012 HAVE_LIBIPT=no
8013 else
8014 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8015 /* end confdefs.h. */
8016
8017 #include <linux/perf_event.h>
8018 #ifndef PERF_ATTR_SIZE_VER5
8019 # error
8020 #endif
8021
8022 _ACEOF
8023 if ac_fn_c_try_cpp "$LINENO"; then :
8024 perf_event=yes
8025 else
8026 perf_event=no
8027 fi
8028 rm -f conftest.err conftest.i conftest.$ac_ext
8029 if test "$perf_event" != yes; then
8030 if test "$with_intel_pt" = yes; then
8031 as_fn_error $? "linux/perf_event.h missing or too old" "$LINENO" 5
8032 else
8033 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: linux/perf_event.h missing or too old; some features may be unavailable." >&5
8034 $as_echo "$as_me: WARNING: linux/perf_event.h missing or too old; some features may be unavailable." >&2;}
8035 fi
8036 fi
8037
8038
8039
8040
8041
8042
8043
8044
8045
8046 use_additional=yes
8047
8048 acl_save_prefix="$prefix"
8049 prefix="$acl_final_prefix"
8050 acl_save_exec_prefix="$exec_prefix"
8051 exec_prefix="$acl_final_exec_prefix"
8052
8053 eval additional_includedir=\"$includedir\"
8054 eval additional_libdir=\"$libdir\"
8055
8056 exec_prefix="$acl_save_exec_prefix"
8057 prefix="$acl_save_prefix"
8058
8059
8060 # Check whether --with-libipt-prefix was given.
8061 if test "${with_libipt_prefix+set}" = set; then :
8062 withval=$with_libipt_prefix;
8063 if test "X$withval" = "Xno"; then
8064 use_additional=no
8065 else
8066 if test "X$withval" = "X"; then
8067
8068 acl_save_prefix="$prefix"
8069 prefix="$acl_final_prefix"
8070 acl_save_exec_prefix="$exec_prefix"
8071 exec_prefix="$acl_final_exec_prefix"
8072
8073 eval additional_includedir=\"$includedir\"
8074 eval additional_libdir=\"$libdir\"
8075
8076 exec_prefix="$acl_save_exec_prefix"
8077 prefix="$acl_save_prefix"
8078
8079 else
8080 additional_includedir="$withval/include"
8081 additional_libdir="$withval/lib"
8082 fi
8083 fi
8084
8085 fi
8086
8087
8088 # Check whether --with-libipt-type was given.
8089 if test "${with_libipt_type+set}" = set; then :
8090 withval=$with_libipt_type; with_libipt_type=$withval
8091 else
8092 with_libipt_type=auto
8093 fi
8094
8095 lib_type=`eval echo \$with_libipt_type`
8096
8097 LIBIPT=
8098 LTLIBIPT=
8099 INCIPT=
8100 rpathdirs=
8101 ltrpathdirs=
8102 names_already_handled=
8103 names_next_round='ipt '
8104 while test -n "$names_next_round"; do
8105 names_this_round="$names_next_round"
8106 names_next_round=
8107 for name in $names_this_round; do
8108 already_handled=
8109 for n in $names_already_handled; do
8110 if test "$n" = "$name"; then
8111 already_handled=yes
8112 break
8113 fi
8114 done
8115 if test -z "$already_handled"; then
8116 names_already_handled="$names_already_handled $name"
8117 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
8118 eval value=\"\$HAVE_LIB$uppername\"
8119 if test -n "$value"; then
8120 if test "$value" = yes; then
8121 eval value=\"\$LIB$uppername\"
8122 test -z "$value" || LIBIPT="${LIBIPT}${LIBIPT:+ }$value"
8123 eval value=\"\$LTLIB$uppername\"
8124 test -z "$value" || LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }$value"
8125 else
8126 :
8127 fi
8128 else
8129 found_dir=
8130 found_la=
8131 found_so=
8132 found_a=
8133 if test $use_additional = yes; then
8134 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
8135 found_dir="$additional_libdir"
8136 found_so="$additional_libdir/lib$name.$shlibext"
8137 if test -f "$additional_libdir/lib$name.la"; then
8138 found_la="$additional_libdir/lib$name.la"
8139 fi
8140 elif test x$lib_type != xshared; then
8141 if test -f "$additional_libdir/lib$name.$libext"; then
8142 found_dir="$additional_libdir"
8143 found_a="$additional_libdir/lib$name.$libext"
8144 if test -f "$additional_libdir/lib$name.la"; then
8145 found_la="$additional_libdir/lib$name.la"
8146 fi
8147 fi
8148 fi
8149 fi
8150 if test "X$found_dir" = "X"; then
8151 for x in $LDFLAGS $LTLIBIPT; do
8152
8153 acl_save_prefix="$prefix"
8154 prefix="$acl_final_prefix"
8155 acl_save_exec_prefix="$exec_prefix"
8156 exec_prefix="$acl_final_exec_prefix"
8157 eval x=\"$x\"
8158 exec_prefix="$acl_save_exec_prefix"
8159 prefix="$acl_save_prefix"
8160
8161 case "$x" in
8162 -L*)
8163 dir=`echo "X$x" | sed -e 's/^X-L//'`
8164 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
8165 found_dir="$dir"
8166 found_so="$dir/lib$name.$shlibext"
8167 if test -f "$dir/lib$name.la"; then
8168 found_la="$dir/lib$name.la"
8169 fi
8170 elif test x$lib_type != xshared; then
8171 if test -f "$dir/lib$name.$libext"; then
8172 found_dir="$dir"
8173 found_a="$dir/lib$name.$libext"
8174 if test -f "$dir/lib$name.la"; then
8175 found_la="$dir/lib$name.la"
8176 fi
8177 fi
8178 fi
8179 ;;
8180 esac
8181 if test "X$found_dir" != "X"; then
8182 break
8183 fi
8184 done
8185 fi
8186 if test "X$found_dir" != "X"; then
8187 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-L$found_dir -l$name"
8188 if test "X$found_so" != "X"; then
8189 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
8190 LIBIPT="${LIBIPT}${LIBIPT:+ }$found_so"
8191 else
8192 haveit=
8193 for x in $ltrpathdirs; do
8194 if test "X$x" = "X$found_dir"; then
8195 haveit=yes
8196 break
8197 fi
8198 done
8199 if test -z "$haveit"; then
8200 ltrpathdirs="$ltrpathdirs $found_dir"
8201 fi
8202 if test "$hardcode_direct" = yes; then
8203 LIBIPT="${LIBIPT}${LIBIPT:+ }$found_so"
8204 else
8205 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
8206 LIBIPT="${LIBIPT}${LIBIPT:+ }$found_so"
8207 haveit=
8208 for x in $rpathdirs; do
8209 if test "X$x" = "X$found_dir"; then
8210 haveit=yes
8211 break
8212 fi
8213 done
8214 if test -z "$haveit"; then
8215 rpathdirs="$rpathdirs $found_dir"
8216 fi
8217 else
8218 haveit=
8219 for x in $LDFLAGS $LIBIPT; do
8220
8221 acl_save_prefix="$prefix"
8222 prefix="$acl_final_prefix"
8223 acl_save_exec_prefix="$exec_prefix"
8224 exec_prefix="$acl_final_exec_prefix"
8225 eval x=\"$x\"
8226 exec_prefix="$acl_save_exec_prefix"
8227 prefix="$acl_save_prefix"
8228
8229 if test "X$x" = "X-L$found_dir"; then
8230 haveit=yes
8231 break
8232 fi
8233 done
8234 if test -z "$haveit"; then
8235 LIBIPT="${LIBIPT}${LIBIPT:+ }-L$found_dir"
8236 fi
8237 if test "$hardcode_minus_L" != no; then
8238 LIBIPT="${LIBIPT}${LIBIPT:+ }$found_so"
8239 else
8240 LIBIPT="${LIBIPT}${LIBIPT:+ }-l$name"
8241 fi
8242 fi
8243 fi
8244 fi
8245 else
8246 if test "X$found_a" != "X"; then
8247 LIBIPT="${LIBIPT}${LIBIPT:+ }$found_a"
8248 else
8249 LIBIPT="${LIBIPT}${LIBIPT:+ }-L$found_dir -l$name"
8250 fi
8251 fi
8252 additional_includedir=
8253 case "$found_dir" in
8254 */lib | */lib/)
8255 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
8256 additional_includedir="$basedir/include"
8257 ;;
8258 esac
8259 if test "X$additional_includedir" != "X"; then
8260 if test "X$additional_includedir" != "X/usr/include"; then
8261 haveit=
8262 if test "X$additional_includedir" = "X/usr/local/include"; then
8263 if test -n "$GCC"; then
8264 case $host_os in
8265 linux*) haveit=yes;;
8266 esac
8267 fi
8268 fi
8269 if test -z "$haveit"; then
8270 for x in $CPPFLAGS $INCIPT; do
8271
8272 acl_save_prefix="$prefix"
8273 prefix="$acl_final_prefix"
8274 acl_save_exec_prefix="$exec_prefix"
8275 exec_prefix="$acl_final_exec_prefix"
8276 eval x=\"$x\"
8277 exec_prefix="$acl_save_exec_prefix"
8278 prefix="$acl_save_prefix"
8279
8280 if test "X$x" = "X-I$additional_includedir"; then
8281 haveit=yes
8282 break
8283 fi
8284 done
8285 if test -z "$haveit"; then
8286 if test -d "$additional_includedir"; then
8287 INCIPT="${INCIPT}${INCIPT:+ }-I$additional_includedir"
8288 fi
8289 fi
8290 fi
8291 fi
8292 fi
8293 if test -n "$found_la"; then
8294 save_libdir="$libdir"
8295 case "$found_la" in
8296 */* | *\\*) . "$found_la" ;;
8297 *) . "./$found_la" ;;
8298 esac
8299 libdir="$save_libdir"
8300 for dep in $dependency_libs; do
8301 case "$dep" in
8302 -L*)
8303 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
8304 if test "X$additional_libdir" != "X/usr/lib"; then
8305 haveit=
8306 if test "X$additional_libdir" = "X/usr/local/lib"; then
8307 if test -n "$GCC"; then
8308 case $host_os in
8309 linux*) haveit=yes;;
8310 esac
8311 fi
8312 fi
8313 if test -z "$haveit"; then
8314 haveit=
8315 for x in $LDFLAGS $LIBIPT; do
8316
8317 acl_save_prefix="$prefix"
8318 prefix="$acl_final_prefix"
8319 acl_save_exec_prefix="$exec_prefix"
8320 exec_prefix="$acl_final_exec_prefix"
8321 eval x=\"$x\"
8322 exec_prefix="$acl_save_exec_prefix"
8323 prefix="$acl_save_prefix"
8324
8325 if test "X$x" = "X-L$additional_libdir"; then
8326 haveit=yes
8327 break
8328 fi
8329 done
8330 if test -z "$haveit"; then
8331 if test -d "$additional_libdir"; then
8332 LIBIPT="${LIBIPT}${LIBIPT:+ }-L$additional_libdir"
8333 fi
8334 fi
8335 haveit=
8336 for x in $LDFLAGS $LTLIBIPT; do
8337
8338 acl_save_prefix="$prefix"
8339 prefix="$acl_final_prefix"
8340 acl_save_exec_prefix="$exec_prefix"
8341 exec_prefix="$acl_final_exec_prefix"
8342 eval x=\"$x\"
8343 exec_prefix="$acl_save_exec_prefix"
8344 prefix="$acl_save_prefix"
8345
8346 if test "X$x" = "X-L$additional_libdir"; then
8347 haveit=yes
8348 break
8349 fi
8350 done
8351 if test -z "$haveit"; then
8352 if test -d "$additional_libdir"; then
8353 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-L$additional_libdir"
8354 fi
8355 fi
8356 fi
8357 fi
8358 ;;
8359 -R*)
8360 dir=`echo "X$dep" | sed -e 's/^X-R//'`
8361 if test "$enable_rpath" != no; then
8362 haveit=
8363 for x in $rpathdirs; do
8364 if test "X$x" = "X$dir"; then
8365 haveit=yes
8366 break
8367 fi
8368 done
8369 if test -z "$haveit"; then
8370 rpathdirs="$rpathdirs $dir"
8371 fi
8372 haveit=
8373 for x in $ltrpathdirs; do
8374 if test "X$x" = "X$dir"; then
8375 haveit=yes
8376 break
8377 fi
8378 done
8379 if test -z "$haveit"; then
8380 ltrpathdirs="$ltrpathdirs $dir"
8381 fi
8382 fi
8383 ;;
8384 -l*)
8385 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
8386 ;;
8387 *.la)
8388 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
8389 ;;
8390 *)
8391 LIBIPT="${LIBIPT}${LIBIPT:+ }$dep"
8392 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }$dep"
8393 ;;
8394 esac
8395 done
8396 fi
8397 else
8398 if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
8399 LIBIPT="${LIBIPT}${LIBIPT:+ }-l$name"
8400 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-l$name"
8401 else
8402 LIBIPT="${LIBIPT}${LIBIPT:+ }-l:lib$name.$libext"
8403 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-l:lib$name.$libext"
8404 fi
8405 fi
8406 fi
8407 fi
8408 done
8409 done
8410 if test "X$rpathdirs" != "X"; then
8411 if test -n "$hardcode_libdir_separator"; then
8412 alldirs=
8413 for found_dir in $rpathdirs; do
8414 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
8415 done
8416 acl_save_libdir="$libdir"
8417 libdir="$alldirs"
8418 eval flag=\"$hardcode_libdir_flag_spec\"
8419 libdir="$acl_save_libdir"
8420 LIBIPT="${LIBIPT}${LIBIPT:+ }$flag"
8421 else
8422 for found_dir in $rpathdirs; do
8423 acl_save_libdir="$libdir"
8424 libdir="$found_dir"
8425 eval flag=\"$hardcode_libdir_flag_spec\"
8426 libdir="$acl_save_libdir"
8427 LIBIPT="${LIBIPT}${LIBIPT:+ }$flag"
8428 done
8429 fi
8430 fi
8431 if test "X$ltrpathdirs" != "X"; then
8432 for found_dir in $ltrpathdirs; do
8433 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-R$found_dir"
8434 done
8435 fi
8436
8437
8438 ac_save_CPPFLAGS="$CPPFLAGS"
8439
8440 for element in $INCIPT; do
8441 haveit=
8442 for x in $CPPFLAGS; do
8443
8444 acl_save_prefix="$prefix"
8445 prefix="$acl_final_prefix"
8446 acl_save_exec_prefix="$exec_prefix"
8447 exec_prefix="$acl_final_exec_prefix"
8448 eval x=\"$x\"
8449 exec_prefix="$acl_save_exec_prefix"
8450 prefix="$acl_save_prefix"
8451
8452 if test "X$x" = "X$element"; then
8453 haveit=yes
8454 break
8455 fi
8456 done
8457 if test -z "$haveit"; then
8458 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
8459 fi
8460 done
8461
8462
8463 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libipt" >&5
8464 $as_echo_n "checking for libipt... " >&6; }
8465 if ${ac_cv_libipt+:} false; then :
8466 $as_echo_n "(cached) " >&6
8467 else
8468
8469 ac_save_LIBS="$LIBS"
8470 LIBS="$LIBS $LIBIPT"
8471 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8472 /* end confdefs.h. */
8473 #include "intel-pt.h"
8474 int
8475 main ()
8476 {
8477 pt_insn_alloc_decoder (0);
8478 ;
8479 return 0;
8480 }
8481 _ACEOF
8482 if ac_fn_c_try_link "$LINENO"; then :
8483 ac_cv_libipt=yes
8484 else
8485 ac_cv_libipt=no
8486 fi
8487 rm -f core conftest.err conftest.$ac_objext \
8488 conftest$ac_exeext conftest.$ac_ext
8489 LIBS="$ac_save_LIBS"
8490
8491 fi
8492 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libipt" >&5
8493 $as_echo "$ac_cv_libipt" >&6; }
8494 if test "$ac_cv_libipt" = yes; then
8495 HAVE_LIBIPT=yes
8496
8497 $as_echo "#define HAVE_LIBIPT 1" >>confdefs.h
8498
8499 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libipt" >&5
8500 $as_echo_n "checking how to link with libipt... " >&6; }
8501 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBIPT" >&5
8502 $as_echo "$LIBIPT" >&6; }
8503 else
8504 HAVE_LIBIPT=no
8505 CPPFLAGS="$ac_save_CPPFLAGS"
8506 LIBIPT=
8507 LTLIBIPT=
8508 fi
8509
8510
8511
8512
8513
8514
8515 if test "$HAVE_LIBIPT" != yes; then
8516 if test "$with_intel_pt" = yes; then
8517 as_fn_error $? "libipt is missing or unusable" "$LINENO" 5
8518 else
8519 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libipt is missing or unusable; some features may be unavailable." >&5
8520 $as_echo "$as_me: WARNING: libipt is missing or unusable; some features may be unavailable." >&2;}
8521 fi
8522 else
8523 save_LIBS=$LIBS
8524 LIBS="$LIBS $LIBIPT"
8525 for ac_func in pt_insn_event
8526 do :
8527 ac_fn_c_check_func "$LINENO" "pt_insn_event" "ac_cv_func_pt_insn_event"
8528 if test "x$ac_cv_func_pt_insn_event" = xyes; then :
8529 cat >>confdefs.h <<_ACEOF
8530 #define HAVE_PT_INSN_EVENT 1
8531 _ACEOF
8532
8533 fi
8534 done
8535
8536 ac_fn_c_check_member "$LINENO" "struct pt_insn" "enabled" "ac_cv_member_struct_pt_insn_enabled" "#include <intel-pt.h>
8537 "
8538 if test "x$ac_cv_member_struct_pt_insn_enabled" = xyes; then :
8539
8540 cat >>confdefs.h <<_ACEOF
8541 #define HAVE_STRUCT_PT_INSN_ENABLED 1
8542 _ACEOF
8543
8544
8545 fi
8546 ac_fn_c_check_member "$LINENO" "struct pt_insn" "resynced" "ac_cv_member_struct_pt_insn_resynced" "#include <intel-pt.h>
8547 "
8548 if test "x$ac_cv_member_struct_pt_insn_resynced" = xyes; then :
8549
8550 cat >>confdefs.h <<_ACEOF
8551 #define HAVE_STRUCT_PT_INSN_RESYNCED 1
8552 _ACEOF
8553
8554
8555 fi
8556
8557 LIBS=$save_LIBS
8558 fi
8559 fi
8560
8561
8562 $as_echo "#define _STRUCTURED_PROC 1" >>confdefs.h
8563
8564 for ac_header in sys/procfs.h
8565 do :
8566 ac_fn_c_check_header_mongrel "$LINENO" "sys/procfs.h" "ac_cv_header_sys_procfs_h" "$ac_includes_default"
8567 if test "x$ac_cv_header_sys_procfs_h" = xyes; then :
8568 cat >>confdefs.h <<_ACEOF
8569 #define HAVE_SYS_PROCFS_H 1
8570 _ACEOF
8571
8572 fi
8573
8574 done
8575
8576 if test "$ac_cv_header_sys_procfs_h" = yes; then
8577
8578 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gregset_t in sys/procfs.h" >&5
8579 $as_echo_n "checking for gregset_t in sys/procfs.h... " >&6; }
8580 if ${bfd_cv_have_sys_procfs_type_gregset_t+:} false; then :
8581 $as_echo_n "(cached) " >&6
8582 else
8583 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8584 /* end confdefs.h. */
8585
8586 #define _SYSCALL32
8587 #include <sys/procfs.h>
8588 int
8589 main ()
8590 {
8591 gregset_t avar
8592 ;
8593 return 0;
8594 }
8595 _ACEOF
8596 if ac_fn_c_try_compile "$LINENO"; then :
8597 bfd_cv_have_sys_procfs_type_gregset_t=yes
8598 else
8599 bfd_cv_have_sys_procfs_type_gregset_t=no
8600
8601 fi
8602 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8603 fi
8604
8605 if test $bfd_cv_have_sys_procfs_type_gregset_t = yes; then
8606
8607 $as_echo "#define HAVE_GREGSET_T 1" >>confdefs.h
8608
8609 fi
8610 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_gregset_t" >&5
8611 $as_echo "$bfd_cv_have_sys_procfs_type_gregset_t" >&6; }
8612
8613
8614 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fpregset_t in sys/procfs.h" >&5
8615 $as_echo_n "checking for fpregset_t in sys/procfs.h... " >&6; }
8616 if ${bfd_cv_have_sys_procfs_type_fpregset_t+:} false; then :
8617 $as_echo_n "(cached) " >&6
8618 else
8619 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8620 /* end confdefs.h. */
8621
8622 #define _SYSCALL32
8623 #include <sys/procfs.h>
8624 int
8625 main ()
8626 {
8627 fpregset_t avar
8628 ;
8629 return 0;
8630 }
8631 _ACEOF
8632 if ac_fn_c_try_compile "$LINENO"; then :
8633 bfd_cv_have_sys_procfs_type_fpregset_t=yes
8634 else
8635 bfd_cv_have_sys_procfs_type_fpregset_t=no
8636
8637 fi
8638 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8639 fi
8640
8641 if test $bfd_cv_have_sys_procfs_type_fpregset_t = yes; then
8642
8643 $as_echo "#define HAVE_FPREGSET_T 1" >>confdefs.h
8644
8645 fi
8646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_fpregset_t" >&5
8647 $as_echo "$bfd_cv_have_sys_procfs_type_fpregset_t" >&6; }
8648
8649
8650 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prgregset_t in sys/procfs.h" >&5
8651 $as_echo_n "checking for prgregset_t in sys/procfs.h... " >&6; }
8652 if ${bfd_cv_have_sys_procfs_type_prgregset_t+:} false; then :
8653 $as_echo_n "(cached) " >&6
8654 else
8655 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8656 /* end confdefs.h. */
8657
8658 #define _SYSCALL32
8659 #include <sys/procfs.h>
8660 int
8661 main ()
8662 {
8663 prgregset_t avar
8664 ;
8665 return 0;
8666 }
8667 _ACEOF
8668 if ac_fn_c_try_compile "$LINENO"; then :
8669 bfd_cv_have_sys_procfs_type_prgregset_t=yes
8670 else
8671 bfd_cv_have_sys_procfs_type_prgregset_t=no
8672
8673 fi
8674 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8675 fi
8676
8677 if test $bfd_cv_have_sys_procfs_type_prgregset_t = yes; then
8678
8679 $as_echo "#define HAVE_PRGREGSET_T 1" >>confdefs.h
8680
8681 fi
8682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prgregset_t" >&5
8683 $as_echo "$bfd_cv_have_sys_procfs_type_prgregset_t" >&6; }
8684
8685
8686 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prfpregset_t in sys/procfs.h" >&5
8687 $as_echo_n "checking for prfpregset_t in sys/procfs.h... " >&6; }
8688 if ${bfd_cv_have_sys_procfs_type_prfpregset_t+:} false; then :
8689 $as_echo_n "(cached) " >&6
8690 else
8691 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8692 /* end confdefs.h. */
8693
8694 #define _SYSCALL32
8695 #include <sys/procfs.h>
8696 int
8697 main ()
8698 {
8699 prfpregset_t avar
8700 ;
8701 return 0;
8702 }
8703 _ACEOF
8704 if ac_fn_c_try_compile "$LINENO"; then :
8705 bfd_cv_have_sys_procfs_type_prfpregset_t=yes
8706 else
8707 bfd_cv_have_sys_procfs_type_prfpregset_t=no
8708
8709 fi
8710 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8711 fi
8712
8713 if test $bfd_cv_have_sys_procfs_type_prfpregset_t = yes; then
8714
8715 $as_echo "#define HAVE_PRFPREGSET_T 1" >>confdefs.h
8716
8717 fi
8718 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prfpregset_t" >&5
8719 $as_echo "$bfd_cv_have_sys_procfs_type_prfpregset_t" >&6; }
8720
8721
8722 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prgregset32_t in sys/procfs.h" >&5
8723 $as_echo_n "checking for prgregset32_t in sys/procfs.h... " >&6; }
8724 if ${bfd_cv_have_sys_procfs_type_prgregset32_t+:} false; then :
8725 $as_echo_n "(cached) " >&6
8726 else
8727 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8728 /* end confdefs.h. */
8729
8730 #define _SYSCALL32
8731 #include <sys/procfs.h>
8732 int
8733 main ()
8734 {
8735 prgregset32_t avar
8736 ;
8737 return 0;
8738 }
8739 _ACEOF
8740 if ac_fn_c_try_compile "$LINENO"; then :
8741 bfd_cv_have_sys_procfs_type_prgregset32_t=yes
8742 else
8743 bfd_cv_have_sys_procfs_type_prgregset32_t=no
8744
8745 fi
8746 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8747 fi
8748
8749 if test $bfd_cv_have_sys_procfs_type_prgregset32_t = yes; then
8750
8751 $as_echo "#define HAVE_PRGREGSET32_T 1" >>confdefs.h
8752
8753 fi
8754 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prgregset32_t" >&5
8755 $as_echo "$bfd_cv_have_sys_procfs_type_prgregset32_t" >&6; }
8756
8757
8758 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lwpid_t in sys/procfs.h" >&5
8759 $as_echo_n "checking for lwpid_t in sys/procfs.h... " >&6; }
8760 if ${bfd_cv_have_sys_procfs_type_lwpid_t+:} false; then :
8761 $as_echo_n "(cached) " >&6
8762 else
8763 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8764 /* end confdefs.h. */
8765
8766 #define _SYSCALL32
8767 #include <sys/procfs.h>
8768 int
8769 main ()
8770 {
8771 lwpid_t avar
8772 ;
8773 return 0;
8774 }
8775 _ACEOF
8776 if ac_fn_c_try_compile "$LINENO"; then :
8777 bfd_cv_have_sys_procfs_type_lwpid_t=yes
8778 else
8779 bfd_cv_have_sys_procfs_type_lwpid_t=no
8780
8781 fi
8782 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8783 fi
8784
8785 if test $bfd_cv_have_sys_procfs_type_lwpid_t = yes; then
8786
8787 $as_echo "#define HAVE_LWPID_T 1" >>confdefs.h
8788
8789 fi
8790 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_lwpid_t" >&5
8791 $as_echo "$bfd_cv_have_sys_procfs_type_lwpid_t" >&6; }
8792
8793
8794 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for psaddr_t in sys/procfs.h" >&5
8795 $as_echo_n "checking for psaddr_t in sys/procfs.h... " >&6; }
8796 if ${bfd_cv_have_sys_procfs_type_psaddr_t+:} false; then :
8797 $as_echo_n "(cached) " >&6
8798 else
8799 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8800 /* end confdefs.h. */
8801
8802 #define _SYSCALL32
8803 #include <sys/procfs.h>
8804 int
8805 main ()
8806 {
8807 psaddr_t avar
8808 ;
8809 return 0;
8810 }
8811 _ACEOF
8812 if ac_fn_c_try_compile "$LINENO"; then :
8813 bfd_cv_have_sys_procfs_type_psaddr_t=yes
8814 else
8815 bfd_cv_have_sys_procfs_type_psaddr_t=no
8816
8817 fi
8818 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8819 fi
8820
8821 if test $bfd_cv_have_sys_procfs_type_psaddr_t = yes; then
8822
8823 $as_echo "#define HAVE_PSADDR_T 1" >>confdefs.h
8824
8825 fi
8826 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_psaddr_t" >&5
8827 $as_echo "$bfd_cv_have_sys_procfs_type_psaddr_t" >&6; }
8828
8829
8830 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for elf_fpregset_t in sys/procfs.h" >&5
8831 $as_echo_n "checking for elf_fpregset_t in sys/procfs.h... " >&6; }
8832 if ${bfd_cv_have_sys_procfs_type_elf_fpregset_t+:} false; then :
8833 $as_echo_n "(cached) " >&6
8834 else
8835 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8836 /* end confdefs.h. */
8837
8838 #define _SYSCALL32
8839 #include <sys/procfs.h>
8840 int
8841 main ()
8842 {
8843 elf_fpregset_t avar
8844 ;
8845 return 0;
8846 }
8847 _ACEOF
8848 if ac_fn_c_try_compile "$LINENO"; then :
8849 bfd_cv_have_sys_procfs_type_elf_fpregset_t=yes
8850 else
8851 bfd_cv_have_sys_procfs_type_elf_fpregset_t=no
8852
8853 fi
8854 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8855 fi
8856
8857 if test $bfd_cv_have_sys_procfs_type_elf_fpregset_t = yes; then
8858
8859 $as_echo "#define HAVE_ELF_FPREGSET_T 1" >>confdefs.h
8860
8861 fi
8862 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_elf_fpregset_t" >&5
8863 $as_echo "$bfd_cv_have_sys_procfs_type_elf_fpregset_t" >&6; }
8864
8865 fi
8866
8867 # This is set by GDB_AC_COMMON.
8868
8869
8870
8871 # Check whether we will enable the inclusion of unit tests when
8872 # compiling GDB.
8873 #
8874 # The default value of this option changes depending whether we're on
8875 # development mode (in which case it's "true") or not (in which case
8876 # it's "false"). The $development variable is set by the GDB_AC_COMMON
8877 # macro, which must therefore be used before GDB_AC_SELFTEST.
8878
8879 if test "x$development" != xtrue && test "x$development" != xfalse; then :
8880 as_fn_error $? "Invalid value for \$development, got \"$development\", expecting \"true\" or \"false\"." "$LINENO" 5
8881 fi
8882
8883 # Check whether --enable-unit-tests was given.
8884 if test "${enable_unit_tests+set}" = set; then :
8885 enableval=$enable_unit_tests; case "${enableval}" in
8886 yes) enable_unittests=true ;;
8887 no) enable_unittests=false ;;
8888 *) as_fn_error $? "bad value ${enableval} for --{enable,disable}-unit-tests option" "$LINENO" 5 ;;
8889 esac
8890 else
8891 enable_unittests=$development
8892 fi
8893
8894
8895 if $enable_unittests; then
8896
8897 $as_echo "#define GDB_SELF_TEST 1" >>confdefs.h
8898
8899
8900 fi
8901
8902
8903 case ${build_alias} in
8904 "") build_noncanonical=${build} ;;
8905 *) build_noncanonical=${build_alias} ;;
8906 esac
8907
8908 case ${host_alias} in
8909 "") host_noncanonical=${build_noncanonical} ;;
8910 *) host_noncanonical=${host_alias} ;;
8911 esac
8912
8913 case ${target_alias} in
8914 "") target_noncanonical=${host_noncanonical} ;;
8915 *) target_noncanonical=${target_alias} ;;
8916 esac
8917
8918
8919
8920
8921
8922
8923 # Dependency checking.
8924 rm -rf .tst 2>/dev/null
8925 mkdir .tst 2>/dev/null
8926 if test -d .tst; then
8927 am__leading_dot=.
8928 else
8929 am__leading_dot=_
8930 fi
8931 rmdir .tst 2>/dev/null
8932
8933 DEPDIR="${am__leading_dot}deps"
8934
8935 ac_config_commands="$ac_config_commands depdir"
8936
8937
8938
8939 # If we haven't got the data from the intl directory,
8940 # assume NLS is disabled.
8941 USE_NLS=no
8942 LIBINTL=
8943 LIBINTL_DEP=
8944 INCINTL=
8945 XGETTEXT=
8946 GMSGFMT=
8947 POSUB=
8948
8949 if test -f ../intl/config.intl; then
8950 . ../intl/config.intl
8951 fi
8952 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5
8953 $as_echo_n "checking whether NLS is requested... " >&6; }
8954 if test x"$USE_NLS" != xyes; then
8955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8956 $as_echo "no" >&6; }
8957 else
8958 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8959 $as_echo "yes" >&6; }
8960
8961 $as_echo "#define ENABLE_NLS 1" >>confdefs.h
8962
8963
8964 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for catalogs to be installed" >&5
8965 $as_echo_n "checking for catalogs to be installed... " >&6; }
8966 # Look for .po and .gmo files in the source directory.
8967 CATALOGS=
8968 XLINGUAS=
8969 for cat in $srcdir/po/*.gmo $srcdir/po/*.po; do
8970 # If there aren't any .gmo files the shell will give us the
8971 # literal string "../path/to/srcdir/po/*.gmo" which has to be
8972 # weeded out.
8973 case "$cat" in *\**)
8974 continue;;
8975 esac
8976 # The quadruple backslash is collapsed to a double backslash
8977 # by the backticks, then collapsed again by the double quotes,
8978 # leaving us with one backslash in the sed expression (right
8979 # before the dot that mustn't act as a wildcard).
8980 cat=`echo $cat | sed -e "s!$srcdir/po/!!" -e "s!\\\\.po!.gmo!"`
8981 lang=`echo $cat | sed -e "s!\\\\.gmo!!"`
8982 # The user is allowed to set LINGUAS to a list of languages to
8983 # install catalogs for. If it's empty that means "all of them."
8984 if test "x$LINGUAS" = x; then
8985 CATALOGS="$CATALOGS $cat"
8986 XLINGUAS="$XLINGUAS $lang"
8987 else
8988 case "$LINGUAS" in *$lang*)
8989 CATALOGS="$CATALOGS $cat"
8990 XLINGUAS="$XLINGUAS $lang"
8991 ;;
8992 esac
8993 fi
8994 done
8995 LINGUAS="$XLINGUAS"
8996 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINGUAS" >&5
8997 $as_echo "$LINGUAS" >&6; }
8998
8999
9000 DATADIRNAME=share
9001
9002 INSTOBJEXT=.mo
9003
9004 GENCAT=gencat
9005
9006 CATOBJEXT=.gmo
9007
9008 fi
9009
9010 # Create sub-directories for objects and dependencies.
9011 CONFIG_SRC_SUBDIR="arch gdbsupport nat target"
9012
9013
9014 ac_config_commands="$ac_config_commands gdbdepdir"
9015
9016
9017 depcc="$CC" am_compiler_list=
9018
9019 am_depcomp=$ac_aux_dir/depcomp
9020 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
9021 $as_echo_n "checking dependency style of $depcc... " >&6; }
9022 if ${am_cv_CC_dependencies_compiler_type+:} false; then :
9023 $as_echo_n "(cached) " >&6
9024 else
9025 if test -f "$am_depcomp"; then
9026 # We make a subdir and do the tests there. Otherwise we can end up
9027 # making bogus files that we don't know about and never remove. For
9028 # instance it was reported that on HP-UX the gcc test will end up
9029 # making a dummy file named `D' -- because `-MD' means `put the output
9030 # in D'.
9031 mkdir conftest.dir
9032 # Copy depcomp to subdir because otherwise we won't find it if we're
9033 # using a relative directory.
9034 cp "$am_depcomp" conftest.dir
9035 cd conftest.dir
9036 # We will build objects and dependencies in a subdirectory because
9037 # it helps to detect inapplicable dependency modes. For instance
9038 # both Tru64's cc and ICC support -MD to output dependencies as a
9039 # side effect of compilation, but ICC will put the dependencies in
9040 # the current directory while Tru64 will put them in the object
9041 # directory.
9042 mkdir sub
9043
9044 am_cv_CC_dependencies_compiler_type=none
9045 if test "$am_compiler_list" = ""; then
9046 am_compiler_list=`sed -n 's/^\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
9047 fi
9048 for depmode in $am_compiler_list; do
9049 if test $depmode = none; then break; fi
9050
9051 $as_echo "$as_me:$LINENO: trying $depmode" >&5
9052 # Setup a source with many dependencies, because some compilers
9053 # like to wrap large dependency lists on column 80 (with \), and
9054 # we should not choose a depcomp mode which is confused by this.
9055 #
9056 # We need to recreate these files for each test, as the compiler may
9057 # overwrite some of them when testing with obscure command lines.
9058 # This happens at least with the AIX C compiler.
9059 : > sub/conftest.c
9060 for i in 1 2 3 4 5 6; do
9061 echo '#include "conftst'$i'.h"' >> sub/conftest.c
9062 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
9063 # Solaris 8's {/usr,}/bin/sh.
9064 touch sub/conftst$i.h
9065 done
9066 echo "include sub/conftest.Po" > confmf
9067
9068 # We check with `-c' and `-o' for the sake of the "dashmstdout"
9069 # mode. It turns out that the SunPro C++ compiler does not properly
9070 # handle `-M -o', and we need to detect this.
9071 depcmd="depmode=$depmode \
9072 source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
9073 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
9074 $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c"
9075 echo "| $depcmd" | sed -e 's/ */ /g' >&5
9076 if env $depcmd > conftest.err 2>&1 &&
9077 grep sub/conftst6.h sub/conftest.Po >>conftest.err 2>&1 &&
9078 grep sub/conftest.${OBJEXT-o} sub/conftest.Po >>conftest.err 2>&1 &&
9079 ${MAKE-make} -s -f confmf >>conftest.err 2>&1; then
9080 # icc doesn't choke on unknown options, it will just issue warnings
9081 # or remarks (even with -Werror). So we grep stderr for any message
9082 # that says an option was ignored or not supported.
9083 # When given -MP, icc 7.0 and 7.1 complain thusly:
9084 # icc: Command line warning: ignoring option '-M'; no argument required
9085 # The diagnosis changed in icc 8.0:
9086 # icc: Command line remark: option '-MP' not supported
9087 if (grep 'ignoring option' conftest.err ||
9088 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
9089 am_cv_CC_dependencies_compiler_type=$depmode
9090 $as_echo "$as_me:$LINENO: success" >&5
9091 break
9092 fi
9093 fi
9094 $as_echo "$as_me:$LINENO: failure, diagnostics are:" >&5
9095 sed -e 's/^/| /' < conftest.err >&5
9096 done
9097
9098 cd ..
9099 rm -rf conftest.dir
9100 else
9101 am_cv_CC_dependencies_compiler_type=none
9102 fi
9103
9104 fi
9105 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
9106 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
9107 if test x${am_cv_CC_dependencies_compiler_type-none} = xnone
9108 then as_fn_error $? "no usable dependency style found" "$LINENO" 5
9109 else CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
9110
9111 fi
9112
9113
9114 for ac_header in termios.h sys/reg.h string.h sys/procfs.h linux/elf.h fcntl.h signal.h sys/file.h sys/ioctl.h netinet/in.h sys/socket.h netdb.h netinet/tcp.h arpa/inet.h ws2tcpip.h
9115 do :
9116 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9117 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
9118 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
9119 cat >>confdefs.h <<_ACEOF
9120 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9121 _ACEOF
9122
9123 fi
9124
9125 done
9126
9127 for ac_header in vfork.h
9128 do :
9129 ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
9130 if test "x$ac_cv_header_vfork_h" = xyes; then :
9131 cat >>confdefs.h <<_ACEOF
9132 #define HAVE_VFORK_H 1
9133 _ACEOF
9134
9135 fi
9136
9137 done
9138
9139 for ac_func in fork vfork
9140 do :
9141 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
9142 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
9143 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
9144 cat >>confdefs.h <<_ACEOF
9145 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
9146 _ACEOF
9147
9148 fi
9149 done
9150
9151 if test "x$ac_cv_func_fork" = xyes; then
9152 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
9153 $as_echo_n "checking for working fork... " >&6; }
9154 if ${ac_cv_func_fork_works+:} false; then :
9155 $as_echo_n "(cached) " >&6
9156 else
9157 if test "$cross_compiling" = yes; then :
9158 ac_cv_func_fork_works=cross
9159 else
9160 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9161 /* end confdefs.h. */
9162 $ac_includes_default
9163 int
9164 main ()
9165 {
9166
9167 /* By Ruediger Kuhlmann. */
9168 return fork () < 0;
9169
9170 ;
9171 return 0;
9172 }
9173 _ACEOF
9174 if ac_fn_c_try_run "$LINENO"; then :
9175 ac_cv_func_fork_works=yes
9176 else
9177 ac_cv_func_fork_works=no
9178 fi
9179 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9180 conftest.$ac_objext conftest.beam conftest.$ac_ext
9181 fi
9182
9183 fi
9184 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
9185 $as_echo "$ac_cv_func_fork_works" >&6; }
9186
9187 else
9188 ac_cv_func_fork_works=$ac_cv_func_fork
9189 fi
9190 if test "x$ac_cv_func_fork_works" = xcross; then
9191 case $host in
9192 *-*-amigaos* | *-*-msdosdjgpp*)
9193 # Override, as these systems have only a dummy fork() stub
9194 ac_cv_func_fork_works=no
9195 ;;
9196 *)
9197 ac_cv_func_fork_works=yes
9198 ;;
9199 esac
9200 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
9201 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
9202 fi
9203 ac_cv_func_vfork_works=$ac_cv_func_vfork
9204 if test "x$ac_cv_func_vfork" = xyes; then
9205 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
9206 $as_echo_n "checking for working vfork... " >&6; }
9207 if ${ac_cv_func_vfork_works+:} false; then :
9208 $as_echo_n "(cached) " >&6
9209 else
9210 if test "$cross_compiling" = yes; then :
9211 ac_cv_func_vfork_works=cross
9212 else
9213 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9214 /* end confdefs.h. */
9215 /* Thanks to Paul Eggert for this test. */
9216 $ac_includes_default
9217 #include <sys/wait.h>
9218 #ifdef HAVE_VFORK_H
9219 # include <vfork.h>
9220 #endif
9221 /* On some sparc systems, changes by the child to local and incoming
9222 argument registers are propagated back to the parent. The compiler
9223 is told about this with #include <vfork.h>, but some compilers
9224 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
9225 static variable whose address is put into a register that is
9226 clobbered by the vfork. */
9227 static void
9228 #ifdef __cplusplus
9229 sparc_address_test (int arg)
9230 # else
9231 sparc_address_test (arg) int arg;
9232 #endif
9233 {
9234 static pid_t child;
9235 if (!child) {
9236 child = vfork ();
9237 if (child < 0) {
9238 perror ("vfork");
9239 _exit(2);
9240 }
9241 if (!child) {
9242 arg = getpid();
9243 write(-1, "", 0);
9244 _exit (arg);
9245 }
9246 }
9247 }
9248
9249 int
9250 main ()
9251 {
9252 pid_t parent = getpid ();
9253 pid_t child;
9254
9255 sparc_address_test (0);
9256
9257 child = vfork ();
9258
9259 if (child == 0) {
9260 /* Here is another test for sparc vfork register problems. This
9261 test uses lots of local variables, at least as many local
9262 variables as main has allocated so far including compiler
9263 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
9264 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
9265 reuse the register of parent for one of the local variables,
9266 since it will think that parent can't possibly be used any more
9267 in this routine. Assigning to the local variable will thus
9268 munge parent in the parent process. */
9269 pid_t
9270 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
9271 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
9272 /* Convince the compiler that p..p7 are live; otherwise, it might
9273 use the same hardware register for all 8 local variables. */
9274 if (p != p1 || p != p2 || p != p3 || p != p4
9275 || p != p5 || p != p6 || p != p7)
9276 _exit(1);
9277
9278 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
9279 from child file descriptors. If the child closes a descriptor
9280 before it execs or exits, this munges the parent's descriptor
9281 as well. Test for this by closing stdout in the child. */
9282 _exit(close(fileno(stdout)) != 0);
9283 } else {
9284 int status;
9285 struct stat st;
9286
9287 while (wait(&status) != child)
9288 ;
9289 return (
9290 /* Was there some problem with vforking? */
9291 child < 0
9292
9293 /* Did the child fail? (This shouldn't happen.) */
9294 || status
9295
9296 /* Did the vfork/compiler bug occur? */
9297 || parent != getpid()
9298
9299 /* Did the file descriptor bug occur? */
9300 || fstat(fileno(stdout), &st) != 0
9301 );
9302 }
9303 }
9304 _ACEOF
9305 if ac_fn_c_try_run "$LINENO"; then :
9306 ac_cv_func_vfork_works=yes
9307 else
9308 ac_cv_func_vfork_works=no
9309 fi
9310 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9311 conftest.$ac_objext conftest.beam conftest.$ac_ext
9312 fi
9313
9314 fi
9315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
9316 $as_echo "$ac_cv_func_vfork_works" >&6; }
9317
9318 fi;
9319 if test "x$ac_cv_func_fork_works" = xcross; then
9320 ac_cv_func_vfork_works=$ac_cv_func_vfork
9321 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
9322 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
9323 fi
9324
9325 if test "x$ac_cv_func_vfork_works" = xyes; then
9326
9327 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
9328
9329 else
9330
9331 $as_echo "#define vfork fork" >>confdefs.h
9332
9333 fi
9334 if test "x$ac_cv_func_fork_works" = xyes; then
9335
9336 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
9337
9338 fi
9339
9340 for ac_func in pread pwrite pread64
9341 do :
9342 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
9343 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
9344 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
9345 cat >>confdefs.h <<_ACEOF
9346 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
9347 _ACEOF
9348
9349 fi
9350 done
9351
9352
9353 # Check the return and argument types of ptrace.
9354
9355
9356 for ac_header in sys/ptrace.h ptrace.h
9357 do :
9358 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9359 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
9360 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
9361 cat >>confdefs.h <<_ACEOF
9362 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9363 _ACEOF
9364
9365 fi
9366
9367 done
9368
9369
9370 gdb_ptrace_headers='
9371 #include <sys/types.h>
9372 #if HAVE_SYS_PTRACE_H
9373 # include <sys/ptrace.h>
9374 #endif
9375 #if HAVE_UNISTD_H
9376 # include <unistd.h>
9377 #endif
9378 '
9379
9380 # Check return type. Varargs (used on GNU/Linux) conflict with the
9381 # empty argument list, so check for that explicitly.
9382 { $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of ptrace" >&5
9383 $as_echo_n "checking return type of ptrace... " >&6; }
9384 if ${gdb_cv_func_ptrace_ret+:} false; then :
9385 $as_echo_n "(cached) " >&6
9386 else
9387 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9388 /* end confdefs.h. */
9389  $gdb_ptrace_headers
9390 int
9391 main ()
9392 {
9393 extern long ptrace (enum __ptrace_request, ...);
9394
9395 ;
9396 return 0;
9397 }
9398 _ACEOF
9399 if ac_fn_c_try_compile "$LINENO"; then :
9400 gdb_cv_func_ptrace_ret='long'
9401 else
9402 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9403 /* end confdefs.h. */
9404 $gdb_ptrace_headers
9405 int
9406 main ()
9407 {
9408 extern int ptrace ();
9409
9410 ;
9411 return 0;
9412 }
9413 _ACEOF
9414 if ac_fn_c_try_compile "$LINENO"; then :
9415 gdb_cv_func_ptrace_ret='int'
9416 else
9417 gdb_cv_func_ptrace_ret='long'
9418
9419 fi
9420 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9421
9422 fi
9423 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9424
9425 fi
9426 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_func_ptrace_ret" >&5
9427 $as_echo "$gdb_cv_func_ptrace_ret" >&6; }
9428
9429
9430 cat >>confdefs.h <<_ACEOF
9431 #define PTRACE_TYPE_RET $gdb_cv_func_ptrace_ret
9432 _ACEOF
9433
9434
9435 # Check argument types.
9436 { $as_echo "$as_me:${as_lineno-$LINENO}: checking types of arguments for ptrace" >&5
9437 $as_echo_n "checking types of arguments for ptrace... " >&6; }
9438 if ${gdb_cv_func_ptrace_args+:} false; then :
9439 $as_echo_n "(cached) " >&6
9440 else
9441 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9442 /* end confdefs.h. */
9443 $gdb_ptrace_headers
9444 int
9445 main ()
9446 {
9447 extern long ptrace (enum __ptrace_request, ...);
9448
9449 ;
9450 return 0;
9451 }
9452 _ACEOF
9453 if ac_fn_c_try_compile "$LINENO"; then :
9454 gdb_cv_func_ptrace_args='enum __ptrace_request,int,long,long'
9455 else
9456 for gdb_arg1 in 'int' 'long'; do
9457 for gdb_arg2 in 'pid_t' 'int' 'long'; do
9458 for gdb_arg3 in 'int *' 'caddr_t' 'int' 'long' 'void *'; do
9459 for gdb_arg4 in 'int' 'long' 'void *'; do
9460 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9461 /* end confdefs.h. */
9462 $gdb_ptrace_headers
9463 int
9464 main ()
9465 {
9466 extern $gdb_cv_func_ptrace_ret ptrace ($gdb_arg1, $gdb_arg2, $gdb_arg3, $gdb_arg4);
9467
9468 ;
9469 return 0;
9470 }
9471 _ACEOF
9472 if ac_fn_c_try_compile "$LINENO"; then :
9473 gdb_cv_func_ptrace_args="$gdb_arg1,$gdb_arg2,$gdb_arg3,$gdb_arg4";
9474 break 4;
9475
9476 fi
9477 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9478
9479 for gdb_arg5 in 'int *' 'int' 'long'; do
9480 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9481 /* end confdefs.h. */
9482 $gdb_ptrace_headers
9483 int
9484 main ()
9485 {
9486 extern $gdb_cv_func_ptrace_ret ptrace ($gdb_arg1, $gdb_arg2, $gdb_arg3, $gdb_arg4, $gdb_arg5);
9487
9488 ;
9489 return 0;
9490 }
9491 _ACEOF
9492 if ac_fn_c_try_compile "$LINENO"; then :
9493 gdb_cv_func_ptrace_args="$gdb_arg1,$gdb_arg2,$gdb_arg3,$gdb_arg4,$gdb_arg5";
9494 break 5;
9495
9496 fi
9497 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9498 done
9499 done
9500 done
9501 done
9502 done
9503 # Provide a safe default value.
9504 : ${gdb_cv_func_ptrace_args='int,int,long,long'}
9505
9506 fi
9507 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9508
9509 fi
9510 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_func_ptrace_args" >&5
9511 $as_echo "$gdb_cv_func_ptrace_args" >&6; }
9512
9513 ac_save_IFS=$IFS; IFS=','
9514 set dummy `echo "$gdb_cv_func_ptrace_args" | sed 's/\*/\*/g'`
9515 IFS=$ac_save_IFS
9516 shift
9517
9518 cat >>confdefs.h <<_ACEOF
9519 #define PTRACE_TYPE_ARG1 $1
9520 _ACEOF
9521
9522
9523 cat >>confdefs.h <<_ACEOF
9524 #define PTRACE_TYPE_ARG3 $3
9525 _ACEOF
9526
9527
9528 cat >>confdefs.h <<_ACEOF
9529 #define PTRACE_TYPE_ARG4 $4
9530 _ACEOF
9531
9532 if test -n "$5"; then
9533
9534 cat >>confdefs.h <<_ACEOF
9535 #define PTRACE_TYPE_ARG5 $5
9536 _ACEOF
9537
9538 fi
9539
9540
9541 # Check for UST
9542 ustlibs=""
9543 ustinc=""
9544
9545
9546 # Check whether --with-ust was given.
9547 if test "${with_ust+set}" = set; then :
9548 withval=$with_ust;
9549 fi
9550
9551
9552 # Check whether --with-ust_include was given.
9553 if test "${with_ust_include+set}" = set; then :
9554 withval=$with_ust_include;
9555 fi
9556
9557
9558 # Check whether --with-ust_lib was given.
9559 if test "${with_ust_lib+set}" = set; then :
9560 withval=$with_ust_lib;
9561 fi
9562
9563
9564 case $with_ust in
9565 no)
9566 ustlibs=
9567 ustinc=
9568 ;;
9569 "" | yes)
9570 ustlibs=" -lust "
9571 ustinc=""
9572 ;;
9573 *)
9574 ustlibs="-L$with_ust/lib -lust"
9575 ustinc="-I$with_ust/include "
9576 ;;
9577 esac
9578 if test "x$with_ust_include" != x; then
9579 ustinc="-I$with_ust_include "
9580 fi
9581 if test "x$with_ust_lib" != x; then
9582 ustlibs="-L$with_ust_lib -lust"
9583 fi
9584
9585 if test "x$with_ust" != "xno"; then
9586 saved_CFLAGS="$CFLAGS"
9587 CFLAGS="$CFLAGS $ustinc"
9588 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ust" >&5
9589 $as_echo_n "checking for ust... " >&6; }
9590 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9591 /* end confdefs.h. */
9592
9593 #define CONFIG_UST_GDB_INTEGRATION
9594 #include <ust/ust.h>
9595
9596 int
9597 main ()
9598 {
9599
9600
9601 ;
9602 return 0;
9603 }
9604 _ACEOF
9605 if ac_fn_c_try_compile "$LINENO"; then :
9606 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9607 $as_echo "yes" >&6; };
9608
9609 $as_echo "#define HAVE_UST 1" >>confdefs.h
9610
9611 else
9612 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9613 $as_echo "no" >&6; }
9614 ustlibs= ; ustinc=
9615
9616 fi
9617 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9618 CFLAGS="$saved_CFLAGS"
9619 fi
9620
9621 # Flags needed for UST
9622
9623
9624
9625
9626 # Check whether --enable-werror was given.
9627 if test "${enable_werror+set}" = set; then :
9628 enableval=$enable_werror; case "${enableval}" in
9629 yes | y) ERROR_ON_WARNING="yes" ;;
9630 no | n) ERROR_ON_WARNING="no" ;;
9631 *) as_fn_error $? "bad value ${enableval} for --enable-werror" "$LINENO" 5 ;;
9632 esac
9633 fi
9634
9635
9636 # Enable -Werror by default when using gcc. Turn it off for releases.
9637 if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" && $development; then
9638 ERROR_ON_WARNING=yes
9639 fi
9640
9641 WERROR_CFLAGS=""
9642 if test "${ERROR_ON_WARNING}" = yes ; then
9643 WERROR_CFLAGS="-Werror"
9644 fi
9645
9646 # The options we'll try to enable.
9647 build_warnings="-Wall -Wpointer-arith \
9648 -Wno-unused -Wunused-value -Wunused-variable -Wunused-function \
9649 -Wno-switch -Wno-char-subscripts \
9650 -Wempty-body -Wunused-but-set-parameter -Wunused-but-set-variable \
9651 -Wno-sign-compare -Wno-error=maybe-uninitialized \
9652 -Wno-mismatched-tags \
9653 -Wno-error=deprecated-register \
9654 -Wsuggest-override \
9655 -Wimplicit-fallthrough=3 \
9656 -Wduplicated-cond \
9657 -Wshadow=local \
9658 -Wdeprecated-copy \
9659 -Wdeprecated-copy-dtor \
9660 -Wredundant-move \
9661 -Wmissing-declarations \
9662 -Wmissing-prototypes \
9663 -Wstrict-null-sentinel \
9664 "
9665
9666 case "${host}" in
9667 *-*-mingw32*)
9668 # Enable -Wno-format by default when using gcc on mingw since many
9669 # GCC versions complain about %I64.
9670 build_warnings="$build_warnings -Wno-format" ;;
9671 *-*-solaris*)
9672 # Solaris 11.4 <python2.7/ceval.h> uses #pragma no_inline that GCC
9673 # doesn't understand.
9674 build_warnings="$build_warnings -Wno-unknown-pragmas"
9675 # Solaris 11 <unistd.h> marks vfork deprecated.
9676 build_warnings="$build_warnings -Wno-deprecated-declarations" ;;
9677 *)
9678 # Note that gcc requires -Wformat for -Wformat-nonliteral to work,
9679 # but there's a special case for this below.
9680 build_warnings="$build_warnings -Wformat-nonliteral" ;;
9681 esac
9682
9683 # Check whether --enable-build-warnings was given.
9684 if test "${enable_build_warnings+set}" = set; then :
9685 enableval=$enable_build_warnings; case "${enableval}" in
9686 yes) ;;
9687 no) build_warnings="-w";;
9688 ,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
9689 build_warnings="${build_warnings} ${t}";;
9690 *,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
9691 build_warnings="${t} ${build_warnings}";;
9692 *) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
9693 esac
9694 if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
9695 echo "Setting compiler warning flags = $build_warnings" 6>&1
9696 fi
9697 fi
9698 # Check whether --enable-gdb-build-warnings was given.
9699 if test "${enable_gdb_build_warnings+set}" = set; then :
9700 enableval=$enable_gdb_build_warnings; case "${enableval}" in
9701 yes) ;;
9702 no) build_warnings="-w";;
9703 ,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
9704 build_warnings="${build_warnings} ${t}";;
9705 *,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
9706 build_warnings="${t} ${build_warnings}";;
9707 *) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
9708 esac
9709 if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
9710 echo "Setting GDB specific compiler warning flags = $build_warnings" 6>&1
9711 fi
9712 fi
9713
9714 # The set of warnings supported by a C++ compiler is not the same as
9715 # of the C compiler.
9716 ac_ext=cpp
9717 ac_cpp='$CXXCPP $CPPFLAGS'
9718 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
9719 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
9720 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
9721
9722
9723 WARN_CFLAGS=""
9724 if test "x${build_warnings}" != x -a "x$GCC" = xyes
9725 then
9726 { $as_echo "$as_me:${as_lineno-$LINENO}: checking compiler warning flags" >&5
9727 $as_echo_n "checking compiler warning flags... " >&6; }
9728 # Separate out the -Werror flag as some files just cannot be
9729 # compiled with it enabled.
9730 for w in ${build_warnings}; do
9731 # GCC does not complain about -Wno-unknown-warning. Invert
9732 # and test -Wunknown-warning instead.
9733 case $w in
9734 -Wno-*)
9735 wtest=`echo $w | sed 's/-Wno-/-W/g'` ;;
9736 -Wformat-nonliteral)
9737 # gcc requires -Wformat before -Wformat-nonliteral
9738 # will work, so stick them together.
9739 w="-Wformat $w"
9740 wtest="$w"
9741 ;;
9742 *)
9743 wtest=$w ;;
9744 esac
9745
9746 case $w in
9747 -Werr*) WERROR_CFLAGS=-Werror ;;
9748 *)
9749 # Check whether GCC accepts it.
9750 saved_CFLAGS="$CFLAGS"
9751 CFLAGS="$CFLAGS -Werror $wtest"
9752 saved_CXXFLAGS="$CXXFLAGS"
9753 CXXFLAGS="$CXXFLAGS -Werror $wtest"
9754 if test "x$w" = "x-Wunused-variable"; then
9755 # Check for https://gcc.gnu.org/bugzilla/show_bug.cgi?id=38958,
9756 # fixed in GCC 4.9. This test is derived from the gdb
9757 # source code that triggered this bug in GCC.
9758 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9759 /* end confdefs.h. */
9760 struct scoped_restore_base {};
9761 struct scoped_restore_tmpl : public scoped_restore_base {
9762 ~scoped_restore_tmpl() {}
9763 };
9764 int
9765 main ()
9766 {
9767 const scoped_restore_base &b = scoped_restore_tmpl();
9768
9769 ;
9770 return 0;
9771 }
9772 _ACEOF
9773 if ac_fn_cxx_try_compile "$LINENO"; then :
9774 WARN_CFLAGS="${WARN_CFLAGS} $w"
9775 fi
9776 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9777 else
9778 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9779 /* end confdefs.h. */
9780
9781 int
9782 main ()
9783 {
9784
9785 ;
9786 return 0;
9787 }
9788 _ACEOF
9789 if ac_fn_cxx_try_compile "$LINENO"; then :
9790 WARN_CFLAGS="${WARN_CFLAGS} $w"
9791 fi
9792 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9793 fi
9794 CFLAGS="$saved_CFLAGS"
9795 CXXFLAGS="$saved_CXXFLAGS"
9796 esac
9797 done
9798 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${WARN_CFLAGS} ${WERROR_CFLAGS}" >&5
9799 $as_echo "${WARN_CFLAGS} ${WERROR_CFLAGS}" >&6; }
9800 fi
9801
9802
9803
9804 ac_ext=c
9805 ac_cpp='$CPP $CPPFLAGS'
9806 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
9807 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
9808 ac_compiler_gnu=$ac_cv_c_compiler_gnu
9809
9810
9811
9812 old_LIBS="$LIBS"
9813 LIBS="$LIBS -ldl"
9814 for ac_func in dladdr
9815 do :
9816 ac_fn_c_check_func "$LINENO" "dladdr" "ac_cv_func_dladdr"
9817 if test "x$ac_cv_func_dladdr" = xyes; then :
9818 cat >>confdefs.h <<_ACEOF
9819 #define HAVE_DLADDR 1
9820 _ACEOF
9821
9822 fi
9823 done
9824
9825 LIBS="$old_LIBS"
9826
9827
9828 # Check for presence and size of long long.
9829 ac_fn_c_check_type "$LINENO" "long long" "ac_cv_type_long_long" "$ac_includes_default"
9830 if test "x$ac_cv_type_long_long" = xyes; then :
9831
9832 cat >>confdefs.h <<_ACEOF
9833 #define HAVE_LONG_LONG 1
9834 _ACEOF
9835
9836 # The cast to long int works around a bug in the HP C Compiler
9837 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9838 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9839 # This bug is HP SR number 8606223364.
9840 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5
9841 $as_echo_n "checking size of long long... " >&6; }
9842 if ${ac_cv_sizeof_long_long+:} false; then :
9843 $as_echo_n "(cached) " >&6
9844 else
9845 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long" "$ac_includes_default"; then :
9846
9847 else
9848 if test "$ac_cv_type_long_long" = yes; then
9849 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9850 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9851 as_fn_error 77 "cannot compute sizeof (long long)
9852 See \`config.log' for more details" "$LINENO" 5; }
9853 else
9854 ac_cv_sizeof_long_long=0
9855 fi
9856 fi
9857
9858 fi
9859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5
9860 $as_echo "$ac_cv_sizeof_long_long" >&6; }
9861
9862
9863
9864 cat >>confdefs.h <<_ACEOF
9865 #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
9866 _ACEOF
9867
9868
9869 fi
9870
9871
9872 as_ac_Symbol=`$as_echo "ac_cv_have_decl_basename(char *)" | $as_tr_sh`
9873 ac_fn_c_check_decl "$LINENO" "basename(char *)" "$as_ac_Symbol" "$ac_includes_default"
9874 if eval test \"x\$"$as_ac_Symbol"\" = x"yes"; then :
9875 ac_have_decl=1
9876 else
9877 ac_have_decl=0
9878 fi
9879
9880 cat >>confdefs.h <<_ACEOF
9881 #define HAVE_DECL_BASENAME $ac_have_decl
9882 _ACEOF
9883 ac_fn_c_check_decl "$LINENO" "ffs" "ac_cv_have_decl_ffs" "$ac_includes_default"
9884 if test "x$ac_cv_have_decl_ffs" = xyes; then :
9885 ac_have_decl=1
9886 else
9887 ac_have_decl=0
9888 fi
9889
9890 cat >>confdefs.h <<_ACEOF
9891 #define HAVE_DECL_FFS $ac_have_decl
9892 _ACEOF
9893 ac_fn_c_check_decl "$LINENO" "asprintf" "ac_cv_have_decl_asprintf" "$ac_includes_default"
9894 if test "x$ac_cv_have_decl_asprintf" = xyes; then :
9895 ac_have_decl=1
9896 else
9897 ac_have_decl=0
9898 fi
9899
9900 cat >>confdefs.h <<_ACEOF
9901 #define HAVE_DECL_ASPRINTF $ac_have_decl
9902 _ACEOF
9903 ac_fn_c_check_decl "$LINENO" "vasprintf" "ac_cv_have_decl_vasprintf" "$ac_includes_default"
9904 if test "x$ac_cv_have_decl_vasprintf" = xyes; then :
9905 ac_have_decl=1
9906 else
9907 ac_have_decl=0
9908 fi
9909
9910 cat >>confdefs.h <<_ACEOF
9911 #define HAVE_DECL_VASPRINTF $ac_have_decl
9912 _ACEOF
9913 ac_fn_c_check_decl "$LINENO" "snprintf" "ac_cv_have_decl_snprintf" "$ac_includes_default"
9914 if test "x$ac_cv_have_decl_snprintf" = xyes; then :
9915 ac_have_decl=1
9916 else
9917 ac_have_decl=0
9918 fi
9919
9920 cat >>confdefs.h <<_ACEOF
9921 #define HAVE_DECL_SNPRINTF $ac_have_decl
9922 _ACEOF
9923 ac_fn_c_check_decl "$LINENO" "vsnprintf" "ac_cv_have_decl_vsnprintf" "$ac_includes_default"
9924 if test "x$ac_cv_have_decl_vsnprintf" = xyes; then :
9925 ac_have_decl=1
9926 else
9927 ac_have_decl=0
9928 fi
9929
9930 cat >>confdefs.h <<_ACEOF
9931 #define HAVE_DECL_VSNPRINTF $ac_have_decl
9932 _ACEOF
9933
9934 ac_fn_c_check_decl "$LINENO" "strtol" "ac_cv_have_decl_strtol" "$ac_includes_default"
9935 if test "x$ac_cv_have_decl_strtol" = xyes; then :
9936 ac_have_decl=1
9937 else
9938 ac_have_decl=0
9939 fi
9940
9941 cat >>confdefs.h <<_ACEOF
9942 #define HAVE_DECL_STRTOL $ac_have_decl
9943 _ACEOF
9944 ac_fn_c_check_decl "$LINENO" "strtoul" "ac_cv_have_decl_strtoul" "$ac_includes_default"
9945 if test "x$ac_cv_have_decl_strtoul" = xyes; then :
9946 ac_have_decl=1
9947 else
9948 ac_have_decl=0
9949 fi
9950
9951 cat >>confdefs.h <<_ACEOF
9952 #define HAVE_DECL_STRTOUL $ac_have_decl
9953 _ACEOF
9954 ac_fn_c_check_decl "$LINENO" "strtoll" "ac_cv_have_decl_strtoll" "$ac_includes_default"
9955 if test "x$ac_cv_have_decl_strtoll" = xyes; then :
9956 ac_have_decl=1
9957 else
9958 ac_have_decl=0
9959 fi
9960
9961 cat >>confdefs.h <<_ACEOF
9962 #define HAVE_DECL_STRTOLL $ac_have_decl
9963 _ACEOF
9964 ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default"
9965 if test "x$ac_cv_have_decl_strtoull" = xyes; then :
9966 ac_have_decl=1
9967 else
9968 ac_have_decl=0
9969 fi
9970
9971 cat >>confdefs.h <<_ACEOF
9972 #define HAVE_DECL_STRTOULL $ac_have_decl
9973 _ACEOF
9974
9975 ac_fn_c_check_decl "$LINENO" "strverscmp" "ac_cv_have_decl_strverscmp" "$ac_includes_default"
9976 if test "x$ac_cv_have_decl_strverscmp" = xyes; then :
9977 ac_have_decl=1
9978 else
9979 ac_have_decl=0
9980 fi
9981
9982 cat >>confdefs.h <<_ACEOF
9983 #define HAVE_DECL_STRVERSCMP $ac_have_decl
9984 _ACEOF
9985
9986
9987
9988 ac_fn_c_check_decl "$LINENO" "perror" "ac_cv_have_decl_perror" "$ac_includes_default"
9989 if test "x$ac_cv_have_decl_perror" = xyes; then :
9990 ac_have_decl=1
9991 else
9992 ac_have_decl=0
9993 fi
9994
9995 cat >>confdefs.h <<_ACEOF
9996 #define HAVE_DECL_PERROR $ac_have_decl
9997 _ACEOF
9998 ac_fn_c_check_decl "$LINENO" "vasprintf" "ac_cv_have_decl_vasprintf" "$ac_includes_default"
9999 if test "x$ac_cv_have_decl_vasprintf" = xyes; then :
10000 ac_have_decl=1
10001 else
10002 ac_have_decl=0
10003 fi
10004
10005 cat >>confdefs.h <<_ACEOF
10006 #define HAVE_DECL_VASPRINTF $ac_have_decl
10007 _ACEOF
10008 ac_fn_c_check_decl "$LINENO" "vsnprintf" "ac_cv_have_decl_vsnprintf" "$ac_includes_default"
10009 if test "x$ac_cv_have_decl_vsnprintf" = xyes; then :
10010 ac_have_decl=1
10011 else
10012 ac_have_decl=0
10013 fi
10014
10015 cat >>confdefs.h <<_ACEOF
10016 #define HAVE_DECL_VSNPRINTF $ac_have_decl
10017 _ACEOF
10018
10019
10020 ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "#include <sys/types.h>
10021 #if HAVE_SYS_SOCKET_H
10022 # include <sys/socket.h>
10023 #elif HAVE_WS2TCPIP_H
10024 # include <ws2tcpip.h>
10025 #endif
10026
10027 "
10028 if test "x$ac_cv_type_socklen_t" = xyes; then :
10029
10030 cat >>confdefs.h <<_ACEOF
10031 #define HAVE_SOCKLEN_T 1
10032 _ACEOF
10033
10034
10035 fi
10036
10037
10038 case "${target}" in
10039 *-android*)
10040 # Starting with NDK version 9, <elf.h> actually includes definitions
10041 # of Elf32_auxv_t and Elf64_auxv_t. But sadly, <elf.h> includes
10042 # <sys/exec_elf.h> which defines some of the ELF types incorrectly,
10043 # leading to conflicts with the defintions from <linux/elf.h>.
10044 # This makes it impossible for us to include both <elf.h> and
10045 # <linux/elf.h>, which means that, in practice, we do not have
10046 # access to Elf32_auxv_t and Elf64_auxv_t on this platform.
10047 # Therefore, do not try to auto-detect availability, as it would
10048 # get it wrong on this platform.
10049 ;;
10050 *)
10051 ac_fn_c_check_type "$LINENO" "Elf32_auxv_t" "ac_cv_type_Elf32_auxv_t" "#include <elf.h>
10052
10053 "
10054 if test "x$ac_cv_type_Elf32_auxv_t" = xyes; then :
10055
10056 cat >>confdefs.h <<_ACEOF
10057 #define HAVE_ELF32_AUXV_T 1
10058 _ACEOF
10059
10060
10061 fi
10062 ac_fn_c_check_type "$LINENO" "Elf64_auxv_t" "ac_cv_type_Elf64_auxv_t" "#include <elf.h>
10063
10064 "
10065 if test "x$ac_cv_type_Elf64_auxv_t" = xyes; then :
10066
10067 cat >>confdefs.h <<_ACEOF
10068 #define HAVE_ELF64_AUXV_T 1
10069 _ACEOF
10070
10071
10072 fi
10073
10074 esac
10075
10076
10077
10078 # Check whether --with-pkgversion was given.
10079 if test "${with_pkgversion+set}" = set; then :
10080 withval=$with_pkgversion; case "$withval" in
10081 yes) as_fn_error $? "package version not specified" "$LINENO" 5 ;;
10082 no) PKGVERSION= ;;
10083 *) PKGVERSION="($withval) " ;;
10084 esac
10085 else
10086 PKGVERSION="(GDB) "
10087
10088 fi
10089
10090
10091
10092
10093
10094 # Check whether --with-bugurl was given.
10095 if test "${with_bugurl+set}" = set; then :
10096 withval=$with_bugurl; case "$withval" in
10097 yes) as_fn_error $? "bug URL not specified" "$LINENO" 5 ;;
10098 no) BUGURL=
10099 ;;
10100 *) BUGURL="$withval"
10101 ;;
10102 esac
10103 else
10104 BUGURL="http://www.gnu.org/software/gdb/bugs/"
10105
10106 fi
10107
10108 case ${BUGURL} in
10109 "")
10110 REPORT_BUGS_TO=
10111 REPORT_BUGS_TEXI=
10112 ;;
10113 *)
10114 REPORT_BUGS_TO="<$BUGURL>"
10115 REPORT_BUGS_TEXI=@uref{`echo "$BUGURL" | sed 's/@/@@/g'`}
10116 ;;
10117 esac;
10118
10119
10120
10121
10122 cat >>confdefs.h <<_ACEOF
10123 #define PKGVERSION "$PKGVERSION"
10124 _ACEOF
10125
10126
10127 cat >>confdefs.h <<_ACEOF
10128 #define REPORT_BUGS_TO "$REPORT_BUGS_TO"
10129 _ACEOF
10130
10131
10132 # Check for various supplementary target information (beyond the
10133 # triplet) which might affect the choices in configure.srv.
10134 case "${target}" in
10135 i[34567]86-*-linux*)
10136 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if building for x86-64" >&5
10137 $as_echo_n "checking if building for x86-64... " >&6; }
10138 if ${gdb_cv_i386_is_x86_64+:} false; then :
10139 $as_echo_n "(cached) " >&6
10140 else
10141 save_CPPFLAGS="$CPPFLAGS"
10142 CPPFLAGS="$CPPFLAGS $CFLAGS"
10143 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10144 /* end confdefs.h. */
10145
10146 #if __x86_64__
10147 got it
10148 #endif
10149
10150 _ACEOF
10151 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10152 $EGREP "got it" >/dev/null 2>&1; then :
10153 gdb_cv_i386_is_x86_64=yes
10154 else
10155 gdb_cv_i386_is_x86_64=no
10156 fi
10157 rm -f conftest*
10158
10159 CPPFLAGS="$save_CPPFLAGS"
10160 fi
10161 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_i386_is_x86_64" >&5
10162 $as_echo "$gdb_cv_i386_is_x86_64" >&6; }
10163 ;;
10164
10165 x86_64-*-linux*)
10166 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if building for x32" >&5
10167 $as_echo_n "checking if building for x32... " >&6; }
10168 if ${gdb_cv_x86_is_x32+:} false; then :
10169 $as_echo_n "(cached) " >&6
10170 else
10171 save_CPPFLAGS="$CPPFLAGS"
10172 CPPFLAGS="$CPPFLAGS $CFLAGS"
10173 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10174 /* end confdefs.h. */
10175
10176 #if __x86_64__ && __ILP32__
10177 got it
10178 #endif
10179
10180 _ACEOF
10181 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10182 $EGREP "got it" >/dev/null 2>&1; then :
10183 gdb_cv_x86_is_x32=yes
10184 else
10185 gdb_cv_x86_is_x32=no
10186 fi
10187 rm -f conftest*
10188
10189 CPPFLAGS="$save_CPPFLAGS"
10190 fi
10191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_x86_is_x32" >&5
10192 $as_echo "$gdb_cv_x86_is_x32" >&6; }
10193 ;;
10194
10195 m68k-*-*)
10196 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if building for Coldfire" >&5
10197 $as_echo_n "checking if building for Coldfire... " >&6; }
10198 if ${gdb_cv_m68k_is_coldfire+:} false; then :
10199 $as_echo_n "(cached) " >&6
10200 else
10201 save_CPPFLAGS="$CPPFLAGS"
10202 CPPFLAGS="$CPPFLAGS $CFLAGS"
10203 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10204 /* end confdefs.h. */
10205
10206 #ifdef __mcoldfire__
10207 got it
10208 #endif
10209
10210 _ACEOF
10211 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10212 $EGREP "got it" >/dev/null 2>&1; then :
10213 gdb_cv_m68k_is_coldfire=yes
10214 else
10215 gdb_cv_m68k_is_coldfire=no
10216 fi
10217 rm -f conftest*
10218
10219 CPPFLAGS="$save_CPPFLAGS"
10220 fi
10221 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_m68k_is_coldfire" >&5
10222 $as_echo "$gdb_cv_m68k_is_coldfire" >&6; }
10223 ;;
10224 esac
10225
10226 . ${srcdir}/configure.srv
10227
10228 if test "${srv_mingwce}" = "yes"; then
10229 LIBS="$LIBS -lws2"
10230 elif test "${srv_mingw}" = "yes"; then
10231 # WIN32APILIBS is set by GDB_AC_COMMON.
10232 LIBS="$LIBS $WIN32APILIBS"
10233 fi
10234
10235 if test "${srv_linux_usrregs}" = "yes"; then
10236
10237 $as_echo "#define HAVE_LINUX_USRREGS 1" >>confdefs.h
10238
10239 fi
10240
10241 if test "${srv_linux_regsets}" = "yes"; then
10242
10243 $as_echo "#define HAVE_LINUX_REGSETS 1" >>confdefs.h
10244
10245
10246 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTRACE_GETREGS" >&5
10247 $as_echo_n "checking for PTRACE_GETREGS... " >&6; }
10248 if ${gdbsrv_cv_have_ptrace_getregs+:} false; then :
10249 $as_echo_n "(cached) " >&6
10250 else
10251 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10252 /* end confdefs.h. */
10253 #include <sys/ptrace.h>
10254 int
10255 main ()
10256 {
10257 PTRACE_GETREGS;
10258 ;
10259 return 0;
10260 }
10261 _ACEOF
10262 if ac_fn_c_try_compile "$LINENO"; then :
10263 gdbsrv_cv_have_ptrace_getregs=yes
10264 else
10265 gdbsrv_cv_have_ptrace_getregs=no
10266
10267 fi
10268 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10269
10270 fi
10271
10272 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdbsrv_cv_have_ptrace_getregs" >&5
10273 $as_echo "$gdbsrv_cv_have_ptrace_getregs" >&6; }
10274 if test "${gdbsrv_cv_have_ptrace_getregs}" = "yes"; then
10275
10276 $as_echo "#define HAVE_PTRACE_GETREGS 1" >>confdefs.h
10277
10278 fi
10279
10280 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTRACE_GETFPXREGS" >&5
10281 $as_echo_n "checking for PTRACE_GETFPXREGS... " >&6; }
10282 if ${gdbsrv_cv_have_ptrace_getfpxregs+:} false; then :
10283 $as_echo_n "(cached) " >&6
10284 else
10285 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10286 /* end confdefs.h. */
10287 #include <sys/ptrace.h>
10288 int
10289 main ()
10290 {
10291 PTRACE_GETFPXREGS;
10292 ;
10293 return 0;
10294 }
10295 _ACEOF
10296 if ac_fn_c_try_compile "$LINENO"; then :
10297 gdbsrv_cv_have_ptrace_getfpxregs=yes
10298 else
10299 gdbsrv_cv_have_ptrace_getfpxregs=no
10300
10301 fi
10302 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10303
10304 fi
10305
10306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdbsrv_cv_have_ptrace_getfpxregs" >&5
10307 $as_echo "$gdbsrv_cv_have_ptrace_getfpxregs" >&6; }
10308 if test "${gdbsrv_cv_have_ptrace_getfpxregs}" = "yes"; then
10309
10310 $as_echo "#define HAVE_PTRACE_GETFPXREGS 1" >>confdefs.h
10311
10312 fi
10313 fi
10314
10315 if test "${srv_linux_btrace}" = "yes"; then
10316
10317 $as_echo "#define HAVE_LINUX_BTRACE 1" >>confdefs.h
10318
10319 fi
10320
10321 if test "$bfd_cv_have_sys_procfs_type_lwpid_t" != yes; then
10322 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lwpid_t in thread_db.h" >&5
10323 $as_echo_n "checking for lwpid_t in thread_db.h... " >&6; }
10324 if ${gdbserver_cv_have_thread_db_type_lwpid_t+:} false; then :
10325 $as_echo_n "(cached) " >&6
10326 else
10327 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10328 /* end confdefs.h. */
10329 #include <thread_db.h>
10330 int
10331 main ()
10332 {
10333 lwpid_t avar
10334 ;
10335 return 0;
10336 }
10337 _ACEOF
10338 if ac_fn_c_try_compile "$LINENO"; then :
10339 gdbserver_cv_have_thread_db_type_lwpid_t=yes
10340 else
10341 gdbserver_cv_have_thread_db_type_lwpid_t=no
10342
10343 fi
10344 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10345
10346 fi
10347
10348 if test $gdbserver_cv_have_thread_db_type_lwpid_t = yes; then
10349
10350 $as_echo "#define HAVE_LWPID_T 1" >>confdefs.h
10351
10352 fi
10353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdbserver_cv_have_thread_db_type_lwpid_t" >&5
10354 $as_echo "$gdbserver_cv_have_thread_db_type_lwpid_t" >&6; }
10355
10356 fi
10357
10358 if test "$bfd_cv_have_sys_procfs_type_psaddr_t" != yes; then
10359 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for psaddr_t in thread_db.h" >&5
10360 $as_echo_n "checking for psaddr_t in thread_db.h... " >&6; }
10361 if ${gdbserver_cv_have_thread_db_type_psaddr_t+:} false; then :
10362 $as_echo_n "(cached) " >&6
10363 else
10364 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10365 /* end confdefs.h. */
10366 #include <thread_db.h>
10367 int
10368 main ()
10369 {
10370 psaddr_t avar
10371 ;
10372 return 0;
10373 }
10374 _ACEOF
10375 if ac_fn_c_try_compile "$LINENO"; then :
10376 gdbserver_cv_have_thread_db_type_psaddr_t=yes
10377 else
10378 gdbserver_cv_have_thread_db_type_psaddr_t=no
10379
10380 fi
10381 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10382
10383 fi
10384
10385 if test $gdbserver_cv_have_thread_db_type_psaddr_t = yes; then
10386
10387 $as_echo "#define HAVE_PSADDR_T 1" >>confdefs.h
10388
10389 fi
10390 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdbserver_cv_have_thread_db_type_psaddr_t" >&5
10391 $as_echo "$gdbserver_cv_have_thread_db_type_psaddr_t" >&6; }
10392
10393 fi
10394
10395 old_LIBS="$LIBS"
10396 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
10397 $as_echo_n "checking for dlopen in -ldl... " >&6; }
10398 if ${ac_cv_lib_dl_dlopen+:} false; then :
10399 $as_echo_n "(cached) " >&6
10400 else
10401 ac_check_lib_save_LIBS=$LIBS
10402 LIBS="-ldl $LIBS"
10403 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10404 /* end confdefs.h. */
10405
10406 /* Override any GCC internal prototype to avoid an error.
10407 Use char because int might match the return type of a GCC
10408 builtin and then its argument prototype would still apply. */
10409 #ifdef __cplusplus
10410 extern "C"
10411 #endif
10412 char dlopen ();
10413 int
10414 main ()
10415 {
10416 return dlopen ();
10417 ;
10418 return 0;
10419 }
10420 _ACEOF
10421 if ac_fn_c_try_link "$LINENO"; then :
10422 ac_cv_lib_dl_dlopen=yes
10423 else
10424 ac_cv_lib_dl_dlopen=no
10425 fi
10426 rm -f core conftest.err conftest.$ac_objext \
10427 conftest$ac_exeext conftest.$ac_ext
10428 LIBS=$ac_check_lib_save_LIBS
10429 fi
10430 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
10431 $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
10432 if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
10433 cat >>confdefs.h <<_ACEOF
10434 #define HAVE_LIBDL 1
10435 _ACEOF
10436
10437 LIBS="-ldl $LIBS"
10438
10439 fi
10440
10441 LIBS="$old_LIBS"
10442
10443 srv_thread_depfiles=
10444 srv_libs=
10445
10446 if test "$srv_linux_thread_db" = "yes"; then
10447 if test "$ac_cv_lib_dl_dlopen" = "yes"; then
10448 srv_libs="-ldl"
10449 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the dynamic export flag" >&5
10450 $as_echo_n "checking for the dynamic export flag... " >&6; }
10451 old_LDFLAGS="$LDFLAGS"
10452 # Older GNU ld supports --export-dynamic but --dynamic-list may not be
10453 # supported there.
10454 RDYNAMIC="-Wl,--dynamic-list=${srcdir}/proc-service.list"
10455 LDFLAGS="$LDFLAGS $RDYNAMIC"
10456 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10457 /* end confdefs.h. */
10458
10459 int
10460 main ()
10461 {
10462
10463 ;
10464 return 0;
10465 }
10466 _ACEOF
10467 if ac_fn_c_try_link "$LINENO"; then :
10468 found="-Wl,--dynamic-list"
10469 RDYNAMIC='-Wl,--dynamic-list=$(srcdir)/proc-service.list'
10470 else
10471 RDYNAMIC="-rdynamic"
10472 LDFLAGS="$old_LDFLAGS $RDYNAMIC"
10473 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10474 /* end confdefs.h. */
10475
10476 int
10477 main ()
10478 {
10479
10480 ;
10481 return 0;
10482 }
10483 _ACEOF
10484 if ac_fn_c_try_link "$LINENO"; then :
10485 found="-rdynamic"
10486 else
10487 found="no"
10488 RDYNAMIC=""
10489
10490 fi
10491 rm -f core conftest.err conftest.$ac_objext \
10492 conftest$ac_exeext conftest.$ac_ext
10493
10494 fi
10495 rm -f core conftest.err conftest.$ac_objext \
10496 conftest$ac_exeext conftest.$ac_ext
10497
10498 LDFLAGS="$old_LDFLAGS"
10499 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $found" >&5
10500 $as_echo "$found" >&6; }
10501 else
10502 srv_libs="-lthread_db"
10503 fi
10504
10505 srv_thread_depfiles="thread-db.o proc-service.o"
10506
10507 $as_echo "#define USE_THREAD_DB 1" >>confdefs.h
10508
10509 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TD_VERSION" >&5
10510 $as_echo_n "checking for TD_VERSION... " >&6; }
10511 if ${gdbsrv_cv_have_td_version+:} false; then :
10512 $as_echo_n "(cached) " >&6
10513 else
10514 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10515 /* end confdefs.h. */
10516 #include <thread_db.h>
10517 int
10518 main ()
10519 {
10520 TD_VERSION;
10521 ;
10522 return 0;
10523 }
10524 _ACEOF
10525 if ac_fn_c_try_compile "$LINENO"; then :
10526 gdbsrv_cv_have_td_version=yes
10527 else
10528 gdbsrv_cv_have_td_version=no
10529
10530 fi
10531 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10532
10533 fi
10534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdbsrv_cv_have_td_version" >&5
10535 $as_echo "$gdbsrv_cv_have_td_version" >&6; }
10536 if test "$gdbsrv_cv_have_td_version" = yes; then
10537
10538 $as_echo "#define HAVE_TD_VERSION 1" >>confdefs.h
10539
10540 fi
10541 fi
10542
10543
10544 # Check whether --with-libthread-db was given.
10545 if test "${with_libthread_db+set}" = set; then :
10546 withval=$with_libthread_db; srv_libthread_db_path="${withval}"
10547 srv_libs="$srv_libthread_db_path"
10548
10549 fi
10550
10551
10552 if test "$srv_libs" != "" -a "$srv_libs" != "-ldl"; then
10553
10554 $as_echo "#define USE_LIBTHREAD_DB_DIRECTLY 1" >>confdefs.h
10555
10556 fi
10557
10558 if test "$srv_xmlfiles" != ""; then
10559 srv_xmlbuiltin="xml-builtin.o"
10560
10561 $as_echo "#define USE_XML 1" >>confdefs.h
10562
10563
10564 tmp_xmlfiles=$srv_xmlfiles
10565 srv_xmlfiles=""
10566 for f in $tmp_xmlfiles; do
10567 srv_xmlfiles="$srv_xmlfiles \$(XML_DIR)/$f"
10568 done
10569 fi
10570
10571 GDBSERVER_DEPFILES="$srv_regobj $srv_tgtobj $srv_thread_depfiles"
10572 GDBSERVER_LIBS="$srv_libs"
10573
10574 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the target supports __sync_*_compare_and_swap" >&5
10575 $as_echo_n "checking whether the target supports __sync_*_compare_and_swap... " >&6; }
10576 if ${gdbsrv_cv_have_sync_builtins+:} false; then :
10577 $as_echo_n "(cached) " >&6
10578 else
10579 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10580 /* end confdefs.h. */
10581
10582 int
10583 main ()
10584 {
10585 int foo, bar;
10586 bar = __sync_val_compare_and_swap(&foo, 0, 1);
10587
10588 ;
10589 return 0;
10590 }
10591 _ACEOF
10592 if ac_fn_c_try_link "$LINENO"; then :
10593 gdbsrv_cv_have_sync_builtins=yes
10594 else
10595 gdbsrv_cv_have_sync_builtins=no
10596
10597 fi
10598 rm -f core conftest.err conftest.$ac_objext \
10599 conftest$ac_exeext conftest.$ac_ext
10600
10601 fi
10602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdbsrv_cv_have_sync_builtins" >&5
10603 $as_echo "$gdbsrv_cv_have_sync_builtins" >&6; }
10604 if test "$gdbsrv_cv_have_sync_builtins" = yes; then
10605
10606 $as_echo "#define HAVE_SYNC_BUILTINS 1" >>confdefs.h
10607
10608 fi
10609
10610 saved_cflags="$CFLAGS"
10611 CFLAGS="$CFLAGS -fvisibility=hidden"
10612 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10613 /* end confdefs.h. */
10614
10615 int
10616 main ()
10617 {
10618
10619 ;
10620 return 0;
10621 }
10622 _ACEOF
10623 if ac_fn_c_try_compile "$LINENO"; then :
10624 gdbsrv_cv_have_visibility_hidden=yes
10625 else
10626 gdbsrv_cv_have_visibility_hidden=no
10627 fi
10628 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10629 CFLAGS="$saved_cflags"
10630
10631 IPA_DEPFILES=""
10632 extra_libraries=""
10633
10634 # check whether to enable the inprocess agent
10635 if test "$ipa_obj" != "" \
10636 -a "$gdbsrv_cv_have_sync_builtins" = yes \
10637 -a "$gdbsrv_cv_have_visibility_hidden" = yes; then
10638 have_ipa=true
10639 else
10640 have_ipa=false
10641 fi
10642
10643 # Check whether --enable-inprocess-agent was given.
10644 if test "${enable_inprocess_agent+set}" = set; then :
10645 enableval=$enable_inprocess_agent; case "$enableval" in
10646 yes) want_ipa=true ;;
10647 no) want_ipa=false ;;
10648 *) as_fn_error $? "bad value $enableval for inprocess-agent" "$LINENO" 5 ;;
10649 esac
10650 else
10651 want_ipa=$have_ipa
10652 fi
10653
10654
10655 if $want_ipa ; then
10656 if $have_ipa ; then
10657 IPA_DEPFILES="$ipa_obj"
10658 extra_libraries="$extra_libraries libinproctrace.so"
10659 else
10660 as_fn_error $? "inprocess agent not supported for this target" "$LINENO" 5
10661 fi
10662 fi
10663
10664
10665
10666
10667
10668
10669
10670
10671 GNULIB=../gnulib/import
10672
10673 GNULIB_STDINT_H=
10674 if test x"$STDINT_H" != x; then
10675 GNULIB_STDINT_H=$GNULIB/$STDINT_H
10676 fi
10677
10678
10679 ac_config_files="$ac_config_files Makefile"
10680
10681
10682 cat >confcache <<\_ACEOF
10683 # This file is a shell script that caches the results of configure
10684 # tests run on this system so they can be shared between configure
10685 # scripts and configure runs, see configure's option --config-cache.
10686 # It is not useful on other systems. If it contains results you don't
10687 # want to keep, you may remove or edit it.
10688 #
10689 # config.status only pays attention to the cache file if you give it
10690 # the --recheck option to rerun configure.
10691 #
10692 # `ac_cv_env_foo' variables (set or unset) will be overridden when
10693 # loading this file, other *unset* `ac_cv_foo' will be assigned the
10694 # following values.
10695
10696 _ACEOF
10697
10698 # The following way of writing the cache mishandles newlines in values,
10699 # but we know of no workaround that is simple, portable, and efficient.
10700 # So, we kill variables containing newlines.
10701 # Ultrix sh set writes to stderr and can't be redirected directly,
10702 # and sets the high bit in the cache file unless we assign to the vars.
10703 (
10704 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
10705 eval ac_val=\$$ac_var
10706 case $ac_val in #(
10707 *${as_nl}*)
10708 case $ac_var in #(
10709 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
10710 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
10711 esac
10712 case $ac_var in #(
10713 _ | IFS | as_nl) ;; #(
10714 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
10715 *) { eval $ac_var=; unset $ac_var;} ;;
10716 esac ;;
10717 esac
10718 done
10719
10720 (set) 2>&1 |
10721 case $as_nl`(ac_space=' '; set) 2>&1` in #(
10722 *${as_nl}ac_space=\ *)
10723 # `set' does not quote correctly, so add quotes: double-quote
10724 # substitution turns \\\\ into \\, and sed turns \\ into \.
10725 sed -n \
10726 "s/'/'\\\\''/g;
10727 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
10728 ;; #(
10729 *)
10730 # `set' quotes correctly as required by POSIX, so do not add quotes.
10731 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
10732 ;;
10733 esac |
10734 sort
10735 ) |
10736 sed '
10737 /^ac_cv_env_/b end
10738 t clear
10739 :clear
10740 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
10741 t end
10742 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
10743 :end' >>confcache
10744 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
10745 if test -w "$cache_file"; then
10746 if test "x$cache_file" != "x/dev/null"; then
10747 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
10748 $as_echo "$as_me: updating cache $cache_file" >&6;}
10749 if test ! -f "$cache_file" || test -h "$cache_file"; then
10750 cat confcache >"$cache_file"
10751 else
10752 case $cache_file in #(
10753 */* | ?:*)
10754 mv -f confcache "$cache_file"$$ &&
10755 mv -f "$cache_file"$$ "$cache_file" ;; #(
10756 *)
10757 mv -f confcache "$cache_file" ;;
10758 esac
10759 fi
10760 fi
10761 else
10762 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
10763 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
10764 fi
10765 fi
10766 rm -f confcache
10767
10768 test "x$prefix" = xNONE && prefix=$ac_default_prefix
10769 # Let make expand exec_prefix.
10770 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
10771
10772 DEFS=-DHAVE_CONFIG_H
10773
10774 ac_libobjs=
10775 ac_ltlibobjs=
10776 U=
10777 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
10778 # 1. Remove the extension, and $U if already installed.
10779 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
10780 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
10781 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
10782 # will be set to the directory where LIBOBJS objects are built.
10783 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
10784 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
10785 done
10786 LIBOBJS=$ac_libobjs
10787
10788 LTLIBOBJS=$ac_ltlibobjs
10789
10790
10791 if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
10792 as_fn_error $? "conditional \"MAINTAINER_MODE\" was never defined.
10793 Usually this means the macro was only invoked conditionally." "$LINENO" 5
10794 fi
10795
10796 : "${CONFIG_STATUS=./config.status}"
10797 ac_write_fail=0
10798 ac_clean_files_save=$ac_clean_files
10799 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
10800 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
10801 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
10802 as_write_fail=0
10803 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
10804 #! $SHELL
10805 # Generated by $as_me.
10806 # Run this file to recreate the current configuration.
10807 # Compiler output produced by configure, useful for debugging
10808 # configure, is in config.log if it exists.
10809
10810 debug=false
10811 ac_cs_recheck=false
10812 ac_cs_silent=false
10813
10814 SHELL=\${CONFIG_SHELL-$SHELL}
10815 export SHELL
10816 _ASEOF
10817 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
10818 ## -------------------- ##
10819 ## M4sh Initialization. ##
10820 ## -------------------- ##
10821
10822 # Be more Bourne compatible
10823 DUALCASE=1; export DUALCASE # for MKS sh
10824 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
10825 emulate sh
10826 NULLCMD=:
10827 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
10828 # is contrary to our usage. Disable this feature.
10829 alias -g '${1+"$@"}'='"$@"'
10830 setopt NO_GLOB_SUBST
10831 else
10832 case `(set -o) 2>/dev/null` in #(
10833 *posix*) :
10834 set -o posix ;; #(
10835 *) :
10836 ;;
10837 esac
10838 fi
10839
10840
10841 as_nl='
10842 '
10843 export as_nl
10844 # Printing a long string crashes Solaris 7 /usr/bin/printf.
10845 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
10846 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
10847 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
10848 # Prefer a ksh shell builtin over an external printf program on Solaris,
10849 # but without wasting forks for bash or zsh.
10850 if test -z "$BASH_VERSION$ZSH_VERSION" \
10851 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
10852 as_echo='print -r --'
10853 as_echo_n='print -rn --'
10854 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
10855 as_echo='printf %s\n'
10856 as_echo_n='printf %s'
10857 else
10858 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
10859 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
10860 as_echo_n='/usr/ucb/echo -n'
10861 else
10862 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
10863 as_echo_n_body='eval
10864 arg=$1;
10865 case $arg in #(
10866 *"$as_nl"*)
10867 expr "X$arg" : "X\\(.*\\)$as_nl";
10868 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
10869 esac;
10870 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
10871 '
10872 export as_echo_n_body
10873 as_echo_n='sh -c $as_echo_n_body as_echo'
10874 fi
10875 export as_echo_body
10876 as_echo='sh -c $as_echo_body as_echo'
10877 fi
10878
10879 # The user is always right.
10880 if test "${PATH_SEPARATOR+set}" != set; then
10881 PATH_SEPARATOR=:
10882 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
10883 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
10884 PATH_SEPARATOR=';'
10885 }
10886 fi
10887
10888
10889 # IFS
10890 # We need space, tab and new line, in precisely that order. Quoting is
10891 # there to prevent editors from complaining about space-tab.
10892 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
10893 # splitting by setting IFS to empty value.)
10894 IFS=" "" $as_nl"
10895
10896 # Find who we are. Look in the path if we contain no directory separator.
10897 as_myself=
10898 case $0 in #((
10899 *[\\/]* ) as_myself=$0 ;;
10900 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10901 for as_dir in $PATH
10902 do
10903 IFS=$as_save_IFS
10904 test -z "$as_dir" && as_dir=.
10905 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
10906 done
10907 IFS=$as_save_IFS
10908
10909 ;;
10910 esac
10911 # We did not find ourselves, most probably we were run as `sh COMMAND'
10912 # in which case we are not to be found in the path.
10913 if test "x$as_myself" = x; then
10914 as_myself=$0
10915 fi
10916 if test ! -f "$as_myself"; then
10917 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
10918 exit 1
10919 fi
10920
10921 # Unset variables that we do not need and which cause bugs (e.g. in
10922 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
10923 # suppresses any "Segmentation fault" message there. '((' could
10924 # trigger a bug in pdksh 5.2.14.
10925 for as_var in BASH_ENV ENV MAIL MAILPATH
10926 do eval test x\${$as_var+set} = xset \
10927 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
10928 done
10929 PS1='$ '
10930 PS2='> '
10931 PS4='+ '
10932
10933 # NLS nuisances.
10934 LC_ALL=C
10935 export LC_ALL
10936 LANGUAGE=C
10937 export LANGUAGE
10938
10939 # CDPATH.
10940 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
10941
10942
10943 # as_fn_error STATUS ERROR [LINENO LOG_FD]
10944 # ----------------------------------------
10945 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
10946 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
10947 # script with STATUS, using 1 if that was 0.
10948 as_fn_error ()
10949 {
10950 as_status=$1; test $as_status -eq 0 && as_status=1
10951 if test "$4"; then
10952 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
10953 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
10954 fi
10955 $as_echo "$as_me: error: $2" >&2
10956 as_fn_exit $as_status
10957 } # as_fn_error
10958
10959
10960 # as_fn_set_status STATUS
10961 # -----------------------
10962 # Set $? to STATUS, without forking.
10963 as_fn_set_status ()
10964 {
10965 return $1
10966 } # as_fn_set_status
10967
10968 # as_fn_exit STATUS
10969 # -----------------
10970 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
10971 as_fn_exit ()
10972 {
10973 set +e
10974 as_fn_set_status $1
10975 exit $1
10976 } # as_fn_exit
10977
10978 # as_fn_unset VAR
10979 # ---------------
10980 # Portably unset VAR.
10981 as_fn_unset ()
10982 {
10983 { eval $1=; unset $1;}
10984 }
10985 as_unset=as_fn_unset
10986 # as_fn_append VAR VALUE
10987 # ----------------------
10988 # Append the text in VALUE to the end of the definition contained in VAR. Take
10989 # advantage of any shell optimizations that allow amortized linear growth over
10990 # repeated appends, instead of the typical quadratic growth present in naive
10991 # implementations.
10992 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
10993 eval 'as_fn_append ()
10994 {
10995 eval $1+=\$2
10996 }'
10997 else
10998 as_fn_append ()
10999 {
11000 eval $1=\$$1\$2
11001 }
11002 fi # as_fn_append
11003
11004 # as_fn_arith ARG...
11005 # ------------------
11006 # Perform arithmetic evaluation on the ARGs, and store the result in the
11007 # global $as_val. Take advantage of shells that can avoid forks. The arguments
11008 # must be portable across $(()) and expr.
11009 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
11010 eval 'as_fn_arith ()
11011 {
11012 as_val=$(( $* ))
11013 }'
11014 else
11015 as_fn_arith ()
11016 {
11017 as_val=`expr "$@" || test $? -eq 1`
11018 }
11019 fi # as_fn_arith
11020
11021
11022 if expr a : '\(a\)' >/dev/null 2>&1 &&
11023 test "X`expr 00001 : '.*\(...\)'`" = X001; then
11024 as_expr=expr
11025 else
11026 as_expr=false
11027 fi
11028
11029 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
11030 as_basename=basename
11031 else
11032 as_basename=false
11033 fi
11034
11035 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
11036 as_dirname=dirname
11037 else
11038 as_dirname=false
11039 fi
11040
11041 as_me=`$as_basename -- "$0" ||
11042 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
11043 X"$0" : 'X\(//\)$' \| \
11044 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
11045 $as_echo X/"$0" |
11046 sed '/^.*\/\([^/][^/]*\)\/*$/{
11047 s//\1/
11048 q
11049 }
11050 /^X\/\(\/\/\)$/{
11051 s//\1/
11052 q
11053 }
11054 /^X\/\(\/\).*/{
11055 s//\1/
11056 q
11057 }
11058 s/.*/./; q'`
11059
11060 # Avoid depending upon Character Ranges.
11061 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
11062 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
11063 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
11064 as_cr_digits='0123456789'
11065 as_cr_alnum=$as_cr_Letters$as_cr_digits
11066
11067 ECHO_C= ECHO_N= ECHO_T=
11068 case `echo -n x` in #(((((
11069 -n*)
11070 case `echo 'xy\c'` in
11071 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
11072 xy) ECHO_C='\c';;
11073 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
11074 ECHO_T=' ';;
11075 esac;;
11076 *)
11077 ECHO_N='-n';;
11078 esac
11079
11080 rm -f conf$$ conf$$.exe conf$$.file
11081 if test -d conf$$.dir; then
11082 rm -f conf$$.dir/conf$$.file
11083 else
11084 rm -f conf$$.dir
11085 mkdir conf$$.dir 2>/dev/null
11086 fi
11087 if (echo >conf$$.file) 2>/dev/null; then
11088 if ln -s conf$$.file conf$$ 2>/dev/null; then
11089 as_ln_s='ln -s'
11090 # ... but there are two gotchas:
11091 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
11092 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
11093 # In both cases, we have to default to `cp -pR'.
11094 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
11095 as_ln_s='cp -pR'
11096 elif ln conf$$.file conf$$ 2>/dev/null; then
11097 as_ln_s=ln
11098 else
11099 as_ln_s='cp -pR'
11100 fi
11101 else
11102 as_ln_s='cp -pR'
11103 fi
11104 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
11105 rmdir conf$$.dir 2>/dev/null
11106
11107
11108 # as_fn_mkdir_p
11109 # -------------
11110 # Create "$as_dir" as a directory, including parents if necessary.
11111 as_fn_mkdir_p ()
11112 {
11113
11114 case $as_dir in #(
11115 -*) as_dir=./$as_dir;;
11116 esac
11117 test -d "$as_dir" || eval $as_mkdir_p || {
11118 as_dirs=
11119 while :; do
11120 case $as_dir in #(
11121 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
11122 *) as_qdir=$as_dir;;
11123 esac
11124 as_dirs="'$as_qdir' $as_dirs"
11125 as_dir=`$as_dirname -- "$as_dir" ||
11126 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
11127 X"$as_dir" : 'X\(//\)[^/]' \| \
11128 X"$as_dir" : 'X\(//\)$' \| \
11129 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
11130 $as_echo X"$as_dir" |
11131 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
11132 s//\1/
11133 q
11134 }
11135 /^X\(\/\/\)[^/].*/{
11136 s//\1/
11137 q
11138 }
11139 /^X\(\/\/\)$/{
11140 s//\1/
11141 q
11142 }
11143 /^X\(\/\).*/{
11144 s//\1/
11145 q
11146 }
11147 s/.*/./; q'`
11148 test -d "$as_dir" && break
11149 done
11150 test -z "$as_dirs" || eval "mkdir $as_dirs"
11151 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
11152
11153
11154 } # as_fn_mkdir_p
11155 if mkdir -p . 2>/dev/null; then
11156 as_mkdir_p='mkdir -p "$as_dir"'
11157 else
11158 test -d ./-p && rmdir ./-p
11159 as_mkdir_p=false
11160 fi
11161
11162
11163 # as_fn_executable_p FILE
11164 # -----------------------
11165 # Test if FILE is an executable regular file.
11166 as_fn_executable_p ()
11167 {
11168 test -f "$1" && test -x "$1"
11169 } # as_fn_executable_p
11170 as_test_x='test -x'
11171 as_executable_p=as_fn_executable_p
11172
11173 # Sed expression to map a string onto a valid CPP name.
11174 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
11175
11176 # Sed expression to map a string onto a valid variable name.
11177 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
11178
11179
11180 exec 6>&1
11181 ## ----------------------------------- ##
11182 ## Main body of $CONFIG_STATUS script. ##
11183 ## ----------------------------------- ##
11184 _ASEOF
11185 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
11186
11187 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
11188 # Save the log message, to keep $0 and so on meaningful, and to
11189 # report actual input values of CONFIG_FILES etc. instead of their
11190 # values after options handling.
11191 ac_log="
11192 This file was extended by $as_me, which was
11193 generated by GNU Autoconf 2.69. Invocation command line was
11194
11195 CONFIG_FILES = $CONFIG_FILES
11196 CONFIG_HEADERS = $CONFIG_HEADERS
11197 CONFIG_LINKS = $CONFIG_LINKS
11198 CONFIG_COMMANDS = $CONFIG_COMMANDS
11199 $ $0 $@
11200
11201 on `(hostname || uname -n) 2>/dev/null | sed 1q`
11202 "
11203
11204 _ACEOF
11205
11206 case $ac_config_files in *"
11207 "*) set x $ac_config_files; shift; ac_config_files=$*;;
11208 esac
11209
11210 case $ac_config_headers in *"
11211 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
11212 esac
11213
11214
11215 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
11216 # Files that config.status was made for.
11217 config_files="$ac_config_files"
11218 config_headers="$ac_config_headers"
11219 config_commands="$ac_config_commands"
11220
11221 _ACEOF
11222
11223 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
11224 ac_cs_usage="\
11225 \`$as_me' instantiates files and other configuration actions
11226 from templates according to the current configuration. Unless the files
11227 and actions are specified as TAGs, all are instantiated by default.
11228
11229 Usage: $0 [OPTION]... [TAG]...
11230
11231 -h, --help print this help, then exit
11232 -V, --version print version number and configuration settings, then exit
11233 --config print configuration, then exit
11234 -q, --quiet, --silent
11235 do not print progress messages
11236 -d, --debug don't remove temporary files
11237 --recheck update $as_me by reconfiguring in the same conditions
11238 --file=FILE[:TEMPLATE]
11239 instantiate the configuration file FILE
11240 --header=FILE[:TEMPLATE]
11241 instantiate the configuration header FILE
11242
11243 Configuration files:
11244 $config_files
11245
11246 Configuration headers:
11247 $config_headers
11248
11249 Configuration commands:
11250 $config_commands
11251
11252 Report bugs to the package provider."
11253
11254 _ACEOF
11255 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
11256 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
11257 ac_cs_version="\\
11258 config.status
11259 configured by $0, generated by GNU Autoconf 2.69,
11260 with options \\"\$ac_cs_config\\"
11261
11262 Copyright (C) 2012 Free Software Foundation, Inc.
11263 This config.status script is free software; the Free Software Foundation
11264 gives unlimited permission to copy, distribute and modify it."
11265
11266 ac_pwd='$ac_pwd'
11267 srcdir='$srcdir'
11268 INSTALL='$INSTALL'
11269 test -n "\$AWK" || AWK=awk
11270 _ACEOF
11271
11272 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
11273 # The default lists apply if the user does not specify any file.
11274 ac_need_defaults=:
11275 while test $# != 0
11276 do
11277 case $1 in
11278 --*=?*)
11279 ac_option=`expr "X$1" : 'X\([^=]*\)='`
11280 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
11281 ac_shift=:
11282 ;;
11283 --*=)
11284 ac_option=`expr "X$1" : 'X\([^=]*\)='`
11285 ac_optarg=
11286 ac_shift=:
11287 ;;
11288 *)
11289 ac_option=$1
11290 ac_optarg=$2
11291 ac_shift=shift
11292 ;;
11293 esac
11294
11295 case $ac_option in
11296 # Handling of the options.
11297 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
11298 ac_cs_recheck=: ;;
11299 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
11300 $as_echo "$ac_cs_version"; exit ;;
11301 --config | --confi | --conf | --con | --co | --c )
11302 $as_echo "$ac_cs_config"; exit ;;
11303 --debug | --debu | --deb | --de | --d | -d )
11304 debug=: ;;
11305 --file | --fil | --fi | --f )
11306 $ac_shift
11307 case $ac_optarg in
11308 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
11309 '') as_fn_error $? "missing file argument" ;;
11310 esac
11311 as_fn_append CONFIG_FILES " '$ac_optarg'"
11312 ac_need_defaults=false;;
11313 --header | --heade | --head | --hea )
11314 $ac_shift
11315 case $ac_optarg in
11316 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
11317 esac
11318 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
11319 ac_need_defaults=false;;
11320 --he | --h)
11321 # Conflict between --help and --header
11322 as_fn_error $? "ambiguous option: \`$1'
11323 Try \`$0 --help' for more information.";;
11324 --help | --hel | -h )
11325 $as_echo "$ac_cs_usage"; exit ;;
11326 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
11327 | -silent | --silent | --silen | --sile | --sil | --si | --s)
11328 ac_cs_silent=: ;;
11329
11330 # This is an error.
11331 -*) as_fn_error $? "unrecognized option: \`$1'
11332 Try \`$0 --help' for more information." ;;
11333
11334 *) as_fn_append ac_config_targets " $1"
11335 ac_need_defaults=false ;;
11336
11337 esac
11338 shift
11339 done
11340
11341 ac_configure_extra_args=
11342
11343 if $ac_cs_silent; then
11344 exec 6>/dev/null
11345 ac_configure_extra_args="$ac_configure_extra_args --silent"
11346 fi
11347
11348 _ACEOF
11349 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
11350 if \$ac_cs_recheck; then
11351 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
11352 shift
11353 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
11354 CONFIG_SHELL='$SHELL'
11355 export CONFIG_SHELL
11356 exec "\$@"
11357 fi
11358
11359 _ACEOF
11360 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
11361 exec 5>>config.log
11362 {
11363 echo
11364 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
11365 ## Running $as_me. ##
11366 _ASBOX
11367 $as_echo "$ac_log"
11368 } >&5
11369
11370 _ACEOF
11371 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
11372 #
11373 # INIT-COMMANDS
11374 #
11375 ac_aux_dir=$ac_aux_dir DEPDIR=$DEPDIR
11376 ac_aux_dir=$ac_aux_dir DEPDIR=$DEPDIR CONFIG_SRC_SUBDIR="$CONFIG_SRC_SUBDIR"
11377
11378 _ACEOF
11379
11380 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
11381
11382 # Handling of arguments.
11383 for ac_config_target in $ac_config_targets
11384 do
11385 case $ac_config_target in
11386 "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h:config.in" ;;
11387 "depdir") CONFIG_COMMANDS="$CONFIG_COMMANDS depdir" ;;
11388 "gdbdepdir") CONFIG_COMMANDS="$CONFIG_COMMANDS gdbdepdir" ;;
11389 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
11390
11391 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
11392 esac
11393 done
11394
11395
11396 # If the user did not use the arguments to specify the items to instantiate,
11397 # then the envvar interface is used. Set only those that are not.
11398 # We use the long form for the default assignment because of an extremely
11399 # bizarre bug on SunOS 4.1.3.
11400 if $ac_need_defaults; then
11401 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
11402 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
11403 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
11404 fi
11405
11406 # Have a temporary directory for convenience. Make it in the build tree
11407 # simply because there is no reason against having it here, and in addition,
11408 # creating and moving files from /tmp can sometimes cause problems.
11409 # Hook for its removal unless debugging.
11410 # Note that there is a small window in which the directory will not be cleaned:
11411 # after its creation but before its name has been assigned to `$tmp'.
11412 $debug ||
11413 {
11414 tmp= ac_tmp=
11415 trap 'exit_status=$?
11416 : "${ac_tmp:=$tmp}"
11417 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
11418 ' 0
11419 trap 'as_fn_exit 1' 1 2 13 15
11420 }
11421 # Create a (secure) tmp directory for tmp files.
11422
11423 {
11424 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
11425 test -d "$tmp"
11426 } ||
11427 {
11428 tmp=./conf$$-$RANDOM
11429 (umask 077 && mkdir "$tmp")
11430 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
11431 ac_tmp=$tmp
11432
11433 # Set up the scripts for CONFIG_FILES section.
11434 # No need to generate them if there are no CONFIG_FILES.
11435 # This happens for instance with `./config.status config.h'.
11436 if test -n "$CONFIG_FILES"; then
11437
11438
11439 ac_cr=`echo X | tr X '\015'`
11440 # On cygwin, bash can eat \r inside `` if the user requested igncr.
11441 # But we know of no other shell where ac_cr would be empty at this
11442 # point, so we can use a bashism as a fallback.
11443 if test "x$ac_cr" = x; then
11444 eval ac_cr=\$\'\\r\'
11445 fi
11446 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
11447 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
11448 ac_cs_awk_cr='\\r'
11449 else
11450 ac_cs_awk_cr=$ac_cr
11451 fi
11452
11453 echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
11454 _ACEOF
11455
11456
11457 {
11458 echo "cat >conf$$subs.awk <<_ACEOF" &&
11459 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
11460 echo "_ACEOF"
11461 } >conf$$subs.sh ||
11462 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
11463 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
11464 ac_delim='%!_!# '
11465 for ac_last_try in false false false false false :; do
11466 . ./conf$$subs.sh ||
11467 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
11468
11469 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
11470 if test $ac_delim_n = $ac_delim_num; then
11471 break
11472 elif $ac_last_try; then
11473 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
11474 else
11475 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
11476 fi
11477 done
11478 rm -f conf$$subs.sh
11479
11480 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
11481 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
11482 _ACEOF
11483 sed -n '
11484 h
11485 s/^/S["/; s/!.*/"]=/
11486 p
11487 g
11488 s/^[^!]*!//
11489 :repl
11490 t repl
11491 s/'"$ac_delim"'$//
11492 t delim
11493 :nl
11494 h
11495 s/\(.\{148\}\)..*/\1/
11496 t more1
11497 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
11498 p
11499 n
11500 b repl
11501 :more1
11502 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
11503 p
11504 g
11505 s/.\{148\}//
11506 t nl
11507 :delim
11508 h
11509 s/\(.\{148\}\)..*/\1/
11510 t more2
11511 s/["\\]/\\&/g; s/^/"/; s/$/"/
11512 p
11513 b
11514 :more2
11515 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
11516 p
11517 g
11518 s/.\{148\}//
11519 t delim
11520 ' <conf$$subs.awk | sed '
11521 /^[^""]/{
11522 N
11523 s/\n//
11524 }
11525 ' >>$CONFIG_STATUS || ac_write_fail=1
11526 rm -f conf$$subs.awk
11527 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
11528 _ACAWK
11529 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
11530 for (key in S) S_is_set[key] = 1
11531 FS = "\a"
11532
11533 }
11534 {
11535 line = $ 0
11536 nfields = split(line, field, "@")
11537 substed = 0
11538 len = length(field[1])
11539 for (i = 2; i < nfields; i++) {
11540 key = field[i]
11541 keylen = length(key)
11542 if (S_is_set[key]) {
11543 value = S[key]
11544 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
11545 len += length(value) + length(field[++i])
11546 substed = 1
11547 } else
11548 len += 1 + keylen
11549 }
11550
11551 print line
11552 }
11553
11554 _ACAWK
11555 _ACEOF
11556 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
11557 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
11558 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
11559 else
11560 cat
11561 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
11562 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
11563 _ACEOF
11564
11565 # VPATH may cause trouble with some makes, so we remove sole $(srcdir),
11566 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
11567 # trailing colons and then remove the whole line if VPATH becomes empty
11568 # (actually we leave an empty line to preserve line numbers).
11569 if test "x$srcdir" = x.; then
11570 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
11571 h
11572 s///
11573 s/^/:/
11574 s/[ ]*$/:/
11575 s/:\$(srcdir):/:/g
11576 s/:\${srcdir}:/:/g
11577 s/:@srcdir@:/:/g
11578 s/^:*//
11579 s/:*$//
11580 x
11581 s/\(=[ ]*\).*/\1/
11582 G
11583 s/\n//
11584 s/^[^=]*=[ ]*$//
11585 }'
11586 fi
11587
11588 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
11589 fi # test -n "$CONFIG_FILES"
11590
11591 # Set up the scripts for CONFIG_HEADERS section.
11592 # No need to generate them if there are no CONFIG_HEADERS.
11593 # This happens for instance with `./config.status Makefile'.
11594 if test -n "$CONFIG_HEADERS"; then
11595 cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
11596 BEGIN {
11597 _ACEOF
11598
11599 # Transform confdefs.h into an awk script `defines.awk', embedded as
11600 # here-document in config.status, that substitutes the proper values into
11601 # config.h.in to produce config.h.
11602
11603 # Create a delimiter string that does not exist in confdefs.h, to ease
11604 # handling of long lines.
11605 ac_delim='%!_!# '
11606 for ac_last_try in false false :; do
11607 ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
11608 if test -z "$ac_tt"; then
11609 break
11610 elif $ac_last_try; then
11611 as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
11612 else
11613 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
11614 fi
11615 done
11616
11617 # For the awk script, D is an array of macro values keyed by name,
11618 # likewise P contains macro parameters if any. Preserve backslash
11619 # newline sequences.
11620
11621 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
11622 sed -n '
11623 s/.\{148\}/&'"$ac_delim"'/g
11624 t rset
11625 :rset
11626 s/^[ ]*#[ ]*define[ ][ ]*/ /
11627 t def
11628 d
11629 :def
11630 s/\\$//
11631 t bsnl
11632 s/["\\]/\\&/g
11633 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
11634 D["\1"]=" \3"/p
11635 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
11636 d
11637 :bsnl
11638 s/["\\]/\\&/g
11639 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
11640 D["\1"]=" \3\\\\\\n"\\/p
11641 t cont
11642 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
11643 t cont
11644 d
11645 :cont
11646 n
11647 s/.\{148\}/&'"$ac_delim"'/g
11648 t clear
11649 :clear
11650 s/\\$//
11651 t bsnlc
11652 s/["\\]/\\&/g; s/^/"/; s/$/"/p
11653 d
11654 :bsnlc
11655 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
11656 b cont
11657 ' <confdefs.h | sed '
11658 s/'"$ac_delim"'/"\\\
11659 "/g' >>$CONFIG_STATUS || ac_write_fail=1
11660
11661 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
11662 for (key in D) D_is_set[key] = 1
11663 FS = "\a"
11664 }
11665 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
11666 line = \$ 0
11667 split(line, arg, " ")
11668 if (arg[1] == "#") {
11669 defundef = arg[2]
11670 mac1 = arg[3]
11671 } else {
11672 defundef = substr(arg[1], 2)
11673 mac1 = arg[2]
11674 }
11675 split(mac1, mac2, "(") #)
11676 macro = mac2[1]
11677 prefix = substr(line, 1, index(line, defundef) - 1)
11678 if (D_is_set[macro]) {
11679 # Preserve the white space surrounding the "#".
11680 print prefix "define", macro P[macro] D[macro]
11681 next
11682 } else {
11683 # Replace #undef with comments. This is necessary, for example,
11684 # in the case of _POSIX_SOURCE, which is predefined and required
11685 # on some systems where configure will not decide to define it.
11686 if (defundef == "undef") {
11687 print "/*", prefix defundef, macro, "*/"
11688 next
11689 }
11690 }
11691 }
11692 { print }
11693 _ACAWK
11694 _ACEOF
11695 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
11696 as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
11697 fi # test -n "$CONFIG_HEADERS"
11698
11699
11700 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
11701 shift
11702 for ac_tag
11703 do
11704 case $ac_tag in
11705 :[FHLC]) ac_mode=$ac_tag; continue;;
11706 esac
11707 case $ac_mode$ac_tag in
11708 :[FHL]*:*);;
11709 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
11710 :[FH]-) ac_tag=-:-;;
11711 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
11712 esac
11713 ac_save_IFS=$IFS
11714 IFS=:
11715 set x $ac_tag
11716 IFS=$ac_save_IFS
11717 shift
11718 ac_file=$1
11719 shift
11720
11721 case $ac_mode in
11722 :L) ac_source=$1;;
11723 :[FH])
11724 ac_file_inputs=
11725 for ac_f
11726 do
11727 case $ac_f in
11728 -) ac_f="$ac_tmp/stdin";;
11729 *) # Look for the file first in the build tree, then in the source tree
11730 # (if the path is not absolute). The absolute path cannot be DOS-style,
11731 # because $ac_f cannot contain `:'.
11732 test -f "$ac_f" ||
11733 case $ac_f in
11734 [\\/$]*) false;;
11735 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
11736 esac ||
11737 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
11738 esac
11739 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
11740 as_fn_append ac_file_inputs " '$ac_f'"
11741 done
11742
11743 # Let's still pretend it is `configure' which instantiates (i.e., don't
11744 # use $as_me), people would be surprised to read:
11745 # /* config.h. Generated by config.status. */
11746 configure_input='Generated from '`
11747 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
11748 `' by configure.'
11749 if test x"$ac_file" != x-; then
11750 configure_input="$ac_file. $configure_input"
11751 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
11752 $as_echo "$as_me: creating $ac_file" >&6;}
11753 fi
11754 # Neutralize special characters interpreted by sed in replacement strings.
11755 case $configure_input in #(
11756 *\&* | *\|* | *\\* )
11757 ac_sed_conf_input=`$as_echo "$configure_input" |
11758 sed 's/[\\\\&|]/\\\\&/g'`;; #(
11759 *) ac_sed_conf_input=$configure_input;;
11760 esac
11761
11762 case $ac_tag in
11763 *:-:* | *:-) cat >"$ac_tmp/stdin" \
11764 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
11765 esac
11766 ;;
11767 esac
11768
11769 ac_dir=`$as_dirname -- "$ac_file" ||
11770 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
11771 X"$ac_file" : 'X\(//\)[^/]' \| \
11772 X"$ac_file" : 'X\(//\)$' \| \
11773 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
11774 $as_echo X"$ac_file" |
11775 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
11776 s//\1/
11777 q
11778 }
11779 /^X\(\/\/\)[^/].*/{
11780 s//\1/
11781 q
11782 }
11783 /^X\(\/\/\)$/{
11784 s//\1/
11785 q
11786 }
11787 /^X\(\/\).*/{
11788 s//\1/
11789 q
11790 }
11791 s/.*/./; q'`
11792 as_dir="$ac_dir"; as_fn_mkdir_p
11793 ac_builddir=.
11794
11795 case "$ac_dir" in
11796 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
11797 *)
11798 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
11799 # A ".." for each directory in $ac_dir_suffix.
11800 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
11801 case $ac_top_builddir_sub in
11802 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
11803 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
11804 esac ;;
11805 esac
11806 ac_abs_top_builddir=$ac_pwd
11807 ac_abs_builddir=$ac_pwd$ac_dir_suffix
11808 # for backward compatibility:
11809 ac_top_builddir=$ac_top_build_prefix
11810
11811 case $srcdir in
11812 .) # We are building in place.
11813 ac_srcdir=.
11814 ac_top_srcdir=$ac_top_builddir_sub
11815 ac_abs_top_srcdir=$ac_pwd ;;
11816 [\\/]* | ?:[\\/]* ) # Absolute name.
11817 ac_srcdir=$srcdir$ac_dir_suffix;
11818 ac_top_srcdir=$srcdir
11819 ac_abs_top_srcdir=$srcdir ;;
11820 *) # Relative name.
11821 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
11822 ac_top_srcdir=$ac_top_build_prefix$srcdir
11823 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
11824 esac
11825 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
11826
11827
11828 case $ac_mode in
11829 :F)
11830 #
11831 # CONFIG_FILE
11832 #
11833
11834 case $INSTALL in
11835 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
11836 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
11837 esac
11838 _ACEOF
11839
11840 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
11841 # If the template does not know about datarootdir, expand it.
11842 # FIXME: This hack should be removed a few years after 2.60.
11843 ac_datarootdir_hack=; ac_datarootdir_seen=
11844 ac_sed_dataroot='
11845 /datarootdir/ {
11846 p
11847 q
11848 }
11849 /@datadir@/p
11850 /@docdir@/p
11851 /@infodir@/p
11852 /@localedir@/p
11853 /@mandir@/p'
11854 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
11855 *datarootdir*) ac_datarootdir_seen=yes;;
11856 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
11857 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
11858 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
11859 _ACEOF
11860 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
11861 ac_datarootdir_hack='
11862 s&@datadir@&$datadir&g
11863 s&@docdir@&$docdir&g
11864 s&@infodir@&$infodir&g
11865 s&@localedir@&$localedir&g
11866 s&@mandir@&$mandir&g
11867 s&\\\${datarootdir}&$datarootdir&g' ;;
11868 esac
11869 _ACEOF
11870
11871 # Neutralize VPATH when `$srcdir' = `.'.
11872 # Shell code in configure.ac might set extrasub.
11873 # FIXME: do we really want to maintain this feature?
11874 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
11875 ac_sed_extra="$ac_vpsub
11876 $extrasub
11877 _ACEOF
11878 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
11879 :t
11880 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
11881 s|@configure_input@|$ac_sed_conf_input|;t t
11882 s&@top_builddir@&$ac_top_builddir_sub&;t t
11883 s&@top_build_prefix@&$ac_top_build_prefix&;t t
11884 s&@srcdir@&$ac_srcdir&;t t
11885 s&@abs_srcdir@&$ac_abs_srcdir&;t t
11886 s&@top_srcdir@&$ac_top_srcdir&;t t
11887 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
11888 s&@builddir@&$ac_builddir&;t t
11889 s&@abs_builddir@&$ac_abs_builddir&;t t
11890 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
11891 s&@INSTALL@&$ac_INSTALL&;t t
11892 $ac_datarootdir_hack
11893 "
11894 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
11895 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
11896
11897 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
11898 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
11899 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
11900 "$ac_tmp/out"`; test -z "$ac_out"; } &&
11901 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
11902 which seems to be undefined. Please make sure it is defined" >&5
11903 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
11904 which seems to be undefined. Please make sure it is defined" >&2;}
11905
11906 rm -f "$ac_tmp/stdin"
11907 case $ac_file in
11908 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
11909 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
11910 esac \
11911 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
11912 ;;
11913 :H)
11914 #
11915 # CONFIG_HEADER
11916 #
11917 if test x"$ac_file" != x-; then
11918 {
11919 $as_echo "/* $configure_input */" \
11920 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
11921 } >"$ac_tmp/config.h" \
11922 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
11923 if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
11924 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
11925 $as_echo "$as_me: $ac_file is unchanged" >&6;}
11926 else
11927 rm -f "$ac_file"
11928 mv "$ac_tmp/config.h" "$ac_file" \
11929 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
11930 fi
11931 else
11932 $as_echo "/* $configure_input */" \
11933 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
11934 || as_fn_error $? "could not create -" "$LINENO" 5
11935 fi
11936 ;;
11937
11938 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
11939 $as_echo "$as_me: executing $ac_file commands" >&6;}
11940 ;;
11941 esac
11942
11943
11944 case $ac_file$ac_mode in
11945 "config.h":H) echo > stamp-h ;;
11946 "depdir":C) $SHELL $ac_aux_dir/mkinstalldirs $DEPDIR ;;
11947 "gdbdepdir":C)
11948 for subdir in ${CONFIG_SRC_SUBDIR}
11949 do
11950 $SHELL $ac_aux_dir/mkinstalldirs $subdir/$DEPDIR
11951 done ;;
11952
11953 esac
11954 done # for ac_tag
11955
11956
11957 as_fn_exit 0
11958 _ACEOF
11959 ac_clean_files=$ac_clean_files_save
11960
11961 test $ac_write_fail = 0 ||
11962 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
11963
11964
11965 # configure is writing to config.log, and then calls config.status.
11966 # config.status does its own redirection, appending to config.log.
11967 # Unfortunately, on DOS this fails, as config.log is still kept open
11968 # by configure, so config.status won't be able to write to it; its
11969 # output is simply discarded. So we exec the FD to /dev/null,
11970 # effectively closing config.log, so it can be properly (re)opened and
11971 # appended to by config.status. When coming back to configure, we
11972 # need to make the FD available again.
11973 if test "$no_create" != yes; then
11974 ac_cs_success=:
11975 ac_config_status_args=
11976 test "$silent" = yes &&
11977 ac_config_status_args="$ac_config_status_args --quiet"
11978 exec 5>/dev/null
11979 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
11980 exec 5>>config.log
11981 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
11982 # would make configure fail if this is the last instruction.
11983 $ac_cs_success || as_fn_exit 1
11984 fi
11985 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
11986 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
11987 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
11988 fi
11989
This page took 0.279511 seconds and 5 git commands to generate.