RISC-V: Don't report warnings when linking different privileged spec objects.
[binutils-gdb.git] / gdbserver / configure
blob09cb3c5bf434b564da794a636a0ff7148cbb6695
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.69.
6 # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
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 ## -------------------- ##
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 *) :
30 esac
34 as_nl='
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"
65 export as_echo_n_body
66 as_echo_n='sh -c $as_echo_n_body as_echo'
68 export as_echo_body
69 as_echo='sh -c $as_echo_body as_echo'
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=';'
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"
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
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
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
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
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='+ '
126 # NLS nuisances.
127 LC_ALL=C
128 export LC_ALL
129 LANGUAGE=C
130 export LANGUAGE
132 # CDPATH.
133 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
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
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 *) :
174 esac
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; }
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 :
190 else
191 exitcode=1; echo positional parameters were not saved.
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
205 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
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
212 IFS=$as_save_IFS
213 test -z "$as_dir" && as_dir=.
214 as_found=:
215 case $as_dir in #(
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
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
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
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."
272 exit 1
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
282 ## --------------------- ##
283 ## M4sh Shell Functions. ##
284 ## --------------------- ##
285 # as_fn_unset VAR
286 # ---------------
287 # Portably unset VAR.
288 as_fn_unset ()
290 { eval $1=; unset $1;}
292 as_unset=as_fn_unset
294 # as_fn_set_status STATUS
295 # -----------------------
296 # Set $? to STATUS, without forking.
297 as_fn_set_status ()
299 return $1
300 } # as_fn_set_status
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 ()
307 set +e
308 as_fn_set_status $1
309 exit $1
310 } # as_fn_exit
312 # as_fn_mkdir_p
313 # -------------
314 # Create "$as_dir" as a directory, including parents if necessary.
315 as_fn_mkdir_p ()
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/
339 /^X\(\/\/\)[^/].*/{
340 s//\1/
343 /^X\(\/\/\)$/{
344 s//\1/
347 /^X\(\/\).*/{
348 s//\1/
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"
358 } # as_fn_mkdir_p
360 # as_fn_executable_p FILE
361 # -----------------------
362 # Test if FILE is an executable regular file.
363 as_fn_executable_p ()
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 ()
376 eval $1+=\$2
378 else
379 as_fn_append ()
381 eval $1=\$$1\$2
383 fi # as_fn_append
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 ()
393 as_val=$(( $* ))
395 else
396 as_fn_arith ()
398 as_val=`expr "$@" || test $? -eq 1`
400 fi # as_fn_arith
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 ()
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
415 $as_echo "$as_me: error: $2" >&2
416 as_fn_exit $as_status
417 } # as_fn_error
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
426 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
427 as_basename=basename
428 else
429 as_basename=false
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
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/
447 /^X\/\(\/\/\)$/{
448 s//\1/
451 /^X\/\(\/\).*/{
452 s//\1/
455 s/.*/./; q'`
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
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 '
472 /[$]LINENO/=
473 ' <$as_myself |
474 sed '
475 s/[$]LINENO.*/&-/
476 t lineno
478 :lineno
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; }
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
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;;
510 ECHO_N='-n';;
511 esac
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
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'
534 else
535 as_ln_s='cp -pR'
537 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
538 rmdir conf$$.dir 2>/dev/null
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
547 as_test_x='test -x'
548 as_executable_p=as_fn_executable_p
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'"
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'"
557 test -n "$DJDIR" || exec 7<&0 </dev/null
558 exec 6>&1
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`
566 # Initializations.
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=
577 # Identity of this package.
578 PACKAGE_NAME=
579 PACKAGE_TARNAME=
580 PACKAGE_VERSION=
581 PACKAGE_STRING=
582 PACKAGE_BUGREPORT=
583 PACKAGE_URL=
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"
622 ac_header_list=
623 gt_needs=
624 ac_subst_vars='LTLIBOBJS
625 LIBOBJS
626 MAYBE_LIBICONV
627 GNULIB_STDINT_H
628 extra_libraries
629 IPA_DEPFILES
630 srv_xmlfiles
631 srv_xmlbuiltin
632 GDBSERVER_LIBS
633 GDBSERVER_DEPFILES
634 RDYNAMIC
635 REPORT_BUGS_TEXI
636 REPORT_BUGS_TO
637 PKGVERSION
638 WERROR_CFLAGS
639 WARN_CFLAGS
640 ustinc
641 ustlibs
642 CCDEPMODE
643 CONFIG_SRC_SUBDIR
644 CATOBJEXT
645 GENCAT
646 INSTOBJEXT
647 DATADIRNAME
648 CATALOGS
649 INCINTL
650 LIBINTL_DEP
651 POSUB
652 LTLIBINTL
653 LIBINTL
654 INTLLIBS
655 LTLIBICONV
656 LIBICONV
657 INTL_MACOSX_LIBS
658 MSGMERGE
659 XGETTEXT
660 GMSGFMT
661 MSGFMT
662 USE_NLS
663 MKINSTALLDIRS
664 SET_MAKE
665 DEPDIR
666 am__leading_dot
667 host_noncanonical
668 target_noncanonical
669 WIN32APILIBS
670 LTLIBXXHASH
671 LIBXXHASH
672 HAVE_LIBXXHASH
673 LTLIBIPT
674 LIBIPT
675 HAVE_LIBIPT
676 PTHREAD_CFLAGS
677 PTHREAD_LIBS
678 PTHREAD_CC
679 ax_pthread_config
681 ALLOCA
682 CXX_DIALECT
683 HAVE_CXX17
684 RANLIB
686 INSTALL_DATA
687 INSTALL_SCRIPT
688 INSTALL_PROGRAM
689 target_os
690 target_vendor
691 target_cpu
692 target
693 host_os
694 host_vendor
695 host_cpu
696 host
697 build_os
698 build_vendor
699 build_cpu
700 build
701 INSTALL_STRIP_PROGRAM
702 STRIP
703 install_sh
704 EGREP
705 GREP
707 ac_ct_CXX
708 CXXFLAGS
710 OBJEXT
711 EXEEXT
712 ac_ct_CC
713 CPPFLAGS
714 LDFLAGS
715 CFLAGS
717 MAINT
718 MAINTAINER_MODE_FALSE
719 MAINTAINER_MODE_TRUE
720 target_alias
721 host_alias
722 build_alias
723 LIBS
724 ECHO_T
725 ECHO_N
726 ECHO_C
727 DEFS
728 mandir
729 localedir
730 libdir
731 psdir
732 pdfdir
733 dvidir
734 htmldir
735 infodir
736 docdir
737 oldincludedir
738 includedir
739 localstatedir
740 sharedstatedir
741 sysconfdir
742 datadir
743 datarootdir
744 libexecdir
745 sbindir
746 bindir
747 program_transform_name
748 prefix
749 exec_prefix
750 PACKAGE_URL
751 PACKAGE_BUGREPORT
752 PACKAGE_STRING
753 PACKAGE_VERSION
754 PACKAGE_TARNAME
755 PACKAGE_NAME
756 PATH_SEPARATOR
757 SHELL'
758 ac_subst_files=''
759 ac_user_opts='
760 enable_option_checking
761 enable_maintainer_mode
762 enable_largefile
763 enable_threading
764 with_intel_pt
765 with_gnu_ld
766 enable_rpath
767 with_libipt_prefix
768 with_libipt_type
769 with_xxhash
770 with_libxxhash_prefix
771 with_libxxhash_type
772 enable_unit_tests
773 enable_nls
774 with_libiconv_prefix
775 with_libiconv_type
776 with_libintl_prefix
777 with_libintl_type
778 with_ust
779 with_ust_include
780 with_ust_lib
781 enable_werror
782 enable_build_warnings
783 enable_gdb_build_warnings
784 with_pkgversion
785 with_bugurl
786 with_libthread_db
787 enable_inprocess_agent
789 ac_precious_vars='build_alias
790 host_alias
791 target_alias
793 CFLAGS
794 LDFLAGS
795 LIBS
796 CPPFLAGS
798 CXXFLAGS
800 CPP'
803 # Initialize some variables set by options.
804 ac_init_help=
805 ac_init_version=false
806 ac_unrecognized_opts=
807 ac_unrecognized_sep=
808 # The variables have the same names as the options, with
809 # dashes changed to underlines.
810 cache_file=/dev/null
811 exec_prefix=NONE
812 no_create=
813 no_recursion=
814 prefix=NONE
815 program_prefix=NONE
816 program_suffix=NONE
817 program_transform_name=s,x,x,
818 silent=
819 site=
820 srcdir=
821 verbose=
822 x_includes=NONE
823 x_libraries=NONE
825 # Installation directory options.
826 # These are left unexpanded so users can "make install exec_prefix=/foo"
827 # and all the variables that are supposed to be based on exec_prefix
828 # by default will actually change.
829 # Use braces instead of parens because sh, perl, etc. also accept them.
830 # (The list follows the same order as the GNU Coding Standards.)
831 bindir='${exec_prefix}/bin'
832 sbindir='${exec_prefix}/sbin'
833 libexecdir='${exec_prefix}/libexec'
834 datarootdir='${prefix}/share'
835 datadir='${datarootdir}'
836 sysconfdir='${prefix}/etc'
837 sharedstatedir='${prefix}/com'
838 localstatedir='${prefix}/var'
839 includedir='${prefix}/include'
840 oldincludedir='/usr/include'
841 docdir='${datarootdir}/doc/${PACKAGE}'
842 infodir='${datarootdir}/info'
843 htmldir='${docdir}'
844 dvidir='${docdir}'
845 pdfdir='${docdir}'
846 psdir='${docdir}'
847 libdir='${exec_prefix}/lib'
848 localedir='${datarootdir}/locale'
849 mandir='${datarootdir}/man'
851 ac_prev=
852 ac_dashdash=
853 for ac_option
855 # If the previous option needs an argument, assign it.
856 if test -n "$ac_prev"; then
857 eval $ac_prev=\$ac_option
858 ac_prev=
859 continue
862 case $ac_option in
863 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
864 *=) ac_optarg= ;;
865 *) ac_optarg=yes ;;
866 esac
868 # Accept the important Cygnus configure options, so we can diagnose typos.
870 case $ac_dashdash$ac_option in
872 ac_dashdash=yes ;;
874 -bindir | --bindir | --bindi | --bind | --bin | --bi)
875 ac_prev=bindir ;;
876 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
877 bindir=$ac_optarg ;;
879 -build | --build | --buil | --bui | --bu)
880 ac_prev=build_alias ;;
881 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
882 build_alias=$ac_optarg ;;
884 -cache-file | --cache-file | --cache-fil | --cache-fi \
885 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
886 ac_prev=cache_file ;;
887 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
888 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
889 cache_file=$ac_optarg ;;
891 --config-cache | -C)
892 cache_file=config.cache ;;
894 -datadir | --datadir | --datadi | --datad)
895 ac_prev=datadir ;;
896 -datadir=* | --datadir=* | --datadi=* | --datad=*)
897 datadir=$ac_optarg ;;
899 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
900 | --dataroo | --dataro | --datar)
901 ac_prev=datarootdir ;;
902 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
903 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
904 datarootdir=$ac_optarg ;;
906 -disable-* | --disable-*)
907 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
908 # Reject names that are not valid shell variable names.
909 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
910 as_fn_error $? "invalid feature name: $ac_useropt"
911 ac_useropt_orig=$ac_useropt
912 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
913 case $ac_user_opts in
915 "enable_$ac_useropt"
916 "*) ;;
917 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
918 ac_unrecognized_sep=', ';;
919 esac
920 eval enable_$ac_useropt=no ;;
922 -docdir | --docdir | --docdi | --doc | --do)
923 ac_prev=docdir ;;
924 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
925 docdir=$ac_optarg ;;
927 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
928 ac_prev=dvidir ;;
929 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
930 dvidir=$ac_optarg ;;
932 -enable-* | --enable-*)
933 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
934 # Reject names that are not valid shell variable names.
935 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
936 as_fn_error $? "invalid feature name: $ac_useropt"
937 ac_useropt_orig=$ac_useropt
938 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
939 case $ac_user_opts in
941 "enable_$ac_useropt"
942 "*) ;;
943 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
944 ac_unrecognized_sep=', ';;
945 esac
946 eval enable_$ac_useropt=\$ac_optarg ;;
948 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
949 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
950 | --exec | --exe | --ex)
951 ac_prev=exec_prefix ;;
952 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
953 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
954 | --exec=* | --exe=* | --ex=*)
955 exec_prefix=$ac_optarg ;;
957 -gas | --gas | --ga | --g)
958 # Obsolete; use --with-gas.
959 with_gas=yes ;;
961 -help | --help | --hel | --he | -h)
962 ac_init_help=long ;;
963 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
964 ac_init_help=recursive ;;
965 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
966 ac_init_help=short ;;
968 -host | --host | --hos | --ho)
969 ac_prev=host_alias ;;
970 -host=* | --host=* | --hos=* | --ho=*)
971 host_alias=$ac_optarg ;;
973 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
974 ac_prev=htmldir ;;
975 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
976 | --ht=*)
977 htmldir=$ac_optarg ;;
979 -includedir | --includedir | --includedi | --included | --include \
980 | --includ | --inclu | --incl | --inc)
981 ac_prev=includedir ;;
982 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
983 | --includ=* | --inclu=* | --incl=* | --inc=*)
984 includedir=$ac_optarg ;;
986 -infodir | --infodir | --infodi | --infod | --info | --inf)
987 ac_prev=infodir ;;
988 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
989 infodir=$ac_optarg ;;
991 -libdir | --libdir | --libdi | --libd)
992 ac_prev=libdir ;;
993 -libdir=* | --libdir=* | --libdi=* | --libd=*)
994 libdir=$ac_optarg ;;
996 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
997 | --libexe | --libex | --libe)
998 ac_prev=libexecdir ;;
999 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1000 | --libexe=* | --libex=* | --libe=*)
1001 libexecdir=$ac_optarg ;;
1003 -localedir | --localedir | --localedi | --localed | --locale)
1004 ac_prev=localedir ;;
1005 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1006 localedir=$ac_optarg ;;
1008 -localstatedir | --localstatedir | --localstatedi | --localstated \
1009 | --localstate | --localstat | --localsta | --localst | --locals)
1010 ac_prev=localstatedir ;;
1011 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1012 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1013 localstatedir=$ac_optarg ;;
1015 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1016 ac_prev=mandir ;;
1017 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1018 mandir=$ac_optarg ;;
1020 -nfp | --nfp | --nf)
1021 # Obsolete; use --without-fp.
1022 with_fp=no ;;
1024 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1025 | --no-cr | --no-c | -n)
1026 no_create=yes ;;
1028 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1029 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1030 no_recursion=yes ;;
1032 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1033 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1034 | --oldin | --oldi | --old | --ol | --o)
1035 ac_prev=oldincludedir ;;
1036 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1037 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1038 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1039 oldincludedir=$ac_optarg ;;
1041 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1042 ac_prev=prefix ;;
1043 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1044 prefix=$ac_optarg ;;
1046 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1047 | --program-pre | --program-pr | --program-p)
1048 ac_prev=program_prefix ;;
1049 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1050 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1051 program_prefix=$ac_optarg ;;
1053 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1054 | --program-suf | --program-su | --program-s)
1055 ac_prev=program_suffix ;;
1056 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1057 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1058 program_suffix=$ac_optarg ;;
1060 -program-transform-name | --program-transform-name \
1061 | --program-transform-nam | --program-transform-na \
1062 | --program-transform-n | --program-transform- \
1063 | --program-transform | --program-transfor \
1064 | --program-transfo | --program-transf \
1065 | --program-trans | --program-tran \
1066 | --progr-tra | --program-tr | --program-t)
1067 ac_prev=program_transform_name ;;
1068 -program-transform-name=* | --program-transform-name=* \
1069 | --program-transform-nam=* | --program-transform-na=* \
1070 | --program-transform-n=* | --program-transform-=* \
1071 | --program-transform=* | --program-transfor=* \
1072 | --program-transfo=* | --program-transf=* \
1073 | --program-trans=* | --program-tran=* \
1074 | --progr-tra=* | --program-tr=* | --program-t=*)
1075 program_transform_name=$ac_optarg ;;
1077 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1078 ac_prev=pdfdir ;;
1079 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1080 pdfdir=$ac_optarg ;;
1082 -psdir | --psdir | --psdi | --psd | --ps)
1083 ac_prev=psdir ;;
1084 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1085 psdir=$ac_optarg ;;
1087 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1088 | -silent | --silent | --silen | --sile | --sil)
1089 silent=yes ;;
1091 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1092 ac_prev=sbindir ;;
1093 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1094 | --sbi=* | --sb=*)
1095 sbindir=$ac_optarg ;;
1097 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1098 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1099 | --sharedst | --shareds | --shared | --share | --shar \
1100 | --sha | --sh)
1101 ac_prev=sharedstatedir ;;
1102 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1103 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1104 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1105 | --sha=* | --sh=*)
1106 sharedstatedir=$ac_optarg ;;
1108 -site | --site | --sit)
1109 ac_prev=site ;;
1110 -site=* | --site=* | --sit=*)
1111 site=$ac_optarg ;;
1113 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1114 ac_prev=srcdir ;;
1115 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1116 srcdir=$ac_optarg ;;
1118 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1119 | --syscon | --sysco | --sysc | --sys | --sy)
1120 ac_prev=sysconfdir ;;
1121 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1122 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1123 sysconfdir=$ac_optarg ;;
1125 -target | --target | --targe | --targ | --tar | --ta | --t)
1126 ac_prev=target_alias ;;
1127 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1128 target_alias=$ac_optarg ;;
1130 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1131 verbose=yes ;;
1133 -version | --version | --versio | --versi | --vers | -V)
1134 ac_init_version=: ;;
1136 -with-* | --with-*)
1137 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1138 # Reject names that are not valid shell variable names.
1139 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1140 as_fn_error $? "invalid package name: $ac_useropt"
1141 ac_useropt_orig=$ac_useropt
1142 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1143 case $ac_user_opts in
1145 "with_$ac_useropt"
1146 "*) ;;
1147 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1148 ac_unrecognized_sep=', ';;
1149 esac
1150 eval with_$ac_useropt=\$ac_optarg ;;
1152 -without-* | --without-*)
1153 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1154 # Reject names that are not valid shell variable names.
1155 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1156 as_fn_error $? "invalid package name: $ac_useropt"
1157 ac_useropt_orig=$ac_useropt
1158 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1159 case $ac_user_opts in
1161 "with_$ac_useropt"
1162 "*) ;;
1163 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1164 ac_unrecognized_sep=', ';;
1165 esac
1166 eval with_$ac_useropt=no ;;
1168 --x)
1169 # Obsolete; use --with-x.
1170 with_x=yes ;;
1172 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1173 | --x-incl | --x-inc | --x-in | --x-i)
1174 ac_prev=x_includes ;;
1175 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1176 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1177 x_includes=$ac_optarg ;;
1179 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1180 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1181 ac_prev=x_libraries ;;
1182 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1183 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1184 x_libraries=$ac_optarg ;;
1186 -*) as_fn_error $? "unrecognized option: \`$ac_option'
1187 Try \`$0 --help' for more information"
1190 *=*)
1191 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1192 # Reject names that are not valid shell variable names.
1193 case $ac_envvar in #(
1194 '' | [0-9]* | *[!_$as_cr_alnum]* )
1195 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1196 esac
1197 eval $ac_envvar=\$ac_optarg
1198 export $ac_envvar ;;
1201 # FIXME: should be removed in autoconf 3.0.
1202 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1203 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1204 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1205 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1208 esac
1209 done
1211 if test -n "$ac_prev"; then
1212 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1213 as_fn_error $? "missing argument to $ac_option"
1216 if test -n "$ac_unrecognized_opts"; then
1217 case $enable_option_checking in
1218 no) ;;
1219 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1220 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1221 esac
1224 # Check all directory arguments for consistency.
1225 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1226 datadir sysconfdir sharedstatedir localstatedir includedir \
1227 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1228 libdir localedir mandir
1230 eval ac_val=\$$ac_var
1231 # Remove trailing slashes.
1232 case $ac_val in
1233 */ )
1234 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1235 eval $ac_var=\$ac_val;;
1236 esac
1237 # Be sure to have absolute directory names.
1238 case $ac_val in
1239 [\\/$]* | ?:[\\/]* ) continue;;
1240 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1241 esac
1242 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1243 done
1245 # There might be people who depend on the old broken behavior: `$host'
1246 # used to hold the argument of --host etc.
1247 # FIXME: To remove some day.
1248 build=$build_alias
1249 host=$host_alias
1250 target=$target_alias
1252 # FIXME: To remove some day.
1253 if test "x$host_alias" != x; then
1254 if test "x$build_alias" = x; then
1255 cross_compiling=maybe
1256 elif test "x$build_alias" != "x$host_alias"; then
1257 cross_compiling=yes
1261 ac_tool_prefix=
1262 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1264 test "$silent" = yes && exec 6>/dev/null
1267 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1268 ac_ls_di=`ls -di .` &&
1269 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1270 as_fn_error $? "working directory cannot be determined"
1271 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1272 as_fn_error $? "pwd does not report name of working directory"
1275 # Find the source files, if location was not specified.
1276 if test -z "$srcdir"; then
1277 ac_srcdir_defaulted=yes
1278 # Try the directory containing this script, then the parent directory.
1279 ac_confdir=`$as_dirname -- "$as_myself" ||
1280 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1281 X"$as_myself" : 'X\(//\)[^/]' \| \
1282 X"$as_myself" : 'X\(//\)$' \| \
1283 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1284 $as_echo X"$as_myself" |
1285 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1286 s//\1/
1289 /^X\(\/\/\)[^/].*/{
1290 s//\1/
1293 /^X\(\/\/\)$/{
1294 s//\1/
1297 /^X\(\/\).*/{
1298 s//\1/
1301 s/.*/./; q'`
1302 srcdir=$ac_confdir
1303 if test ! -r "$srcdir/$ac_unique_file"; then
1304 srcdir=..
1306 else
1307 ac_srcdir_defaulted=no
1309 if test ! -r "$srcdir/$ac_unique_file"; then
1310 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1311 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1313 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1314 ac_abs_confdir=`(
1315 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1316 pwd)`
1317 # When building in place, set srcdir=.
1318 if test "$ac_abs_confdir" = "$ac_pwd"; then
1319 srcdir=.
1321 # Remove unnecessary trailing slashes from srcdir.
1322 # Double slashes in file names in object file debugging info
1323 # mess up M-x gdb in Emacs.
1324 case $srcdir in
1325 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1326 esac
1327 for ac_var in $ac_precious_vars; do
1328 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1329 eval ac_env_${ac_var}_value=\$${ac_var}
1330 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1331 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1332 done
1335 # Report the --help message.
1337 if test "$ac_init_help" = "long"; then
1338 # Omit some internal or obsolete options to make the list less imposing.
1339 # This message is too long to be a string in the A/UX 3.1 sh.
1340 cat <<_ACEOF
1341 \`configure' configures this package to adapt to many kinds of systems.
1343 Usage: $0 [OPTION]... [VAR=VALUE]...
1345 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1346 VAR=VALUE. See below for descriptions of some of the useful variables.
1348 Defaults for the options are specified in brackets.
1350 Configuration:
1351 -h, --help display this help and exit
1352 --help=short display options specific to this package
1353 --help=recursive display the short help of all the included packages
1354 -V, --version display version information and exit
1355 -q, --quiet, --silent do not print \`checking ...' messages
1356 --cache-file=FILE cache test results in FILE [disabled]
1357 -C, --config-cache alias for \`--cache-file=config.cache'
1358 -n, --no-create do not create output files
1359 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1361 Installation directories:
1362 --prefix=PREFIX install architecture-independent files in PREFIX
1363 [$ac_default_prefix]
1364 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
1365 [PREFIX]
1367 By default, \`make install' will install all the files in
1368 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1369 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1370 for instance \`--prefix=\$HOME'.
1372 For better control, use the options below.
1374 Fine tuning of the installation directories:
1375 --bindir=DIR user executables [EPREFIX/bin]
1376 --sbindir=DIR system admin executables [EPREFIX/sbin]
1377 --libexecdir=DIR program executables [EPREFIX/libexec]
1378 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1379 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1380 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1381 --libdir=DIR object code libraries [EPREFIX/lib]
1382 --includedir=DIR C header files [PREFIX/include]
1383 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1384 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1385 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1386 --infodir=DIR info documentation [DATAROOTDIR/info]
1387 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1388 --mandir=DIR man documentation [DATAROOTDIR/man]
1389 --docdir=DIR documentation root [DATAROOTDIR/doc/PACKAGE]
1390 --htmldir=DIR html documentation [DOCDIR]
1391 --dvidir=DIR dvi documentation [DOCDIR]
1392 --pdfdir=DIR pdf documentation [DOCDIR]
1393 --psdir=DIR ps documentation [DOCDIR]
1394 _ACEOF
1396 cat <<\_ACEOF
1398 Program names:
1399 --program-prefix=PREFIX prepend PREFIX to installed program names
1400 --program-suffix=SUFFIX append SUFFIX to installed program names
1401 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
1403 System types:
1404 --build=BUILD configure for building on BUILD [guessed]
1405 --host=HOST cross-compile to build programs to run on HOST [BUILD]
1406 --target=TARGET configure for building compilers for TARGET [HOST]
1407 _ACEOF
1410 if test -n "$ac_init_help"; then
1412 cat <<\_ACEOF
1414 Optional Features:
1415 --disable-option-checking ignore unrecognized --enable/--with options
1416 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1417 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
1418 --enable-maintainer-mode
1419 enable make rules and dependencies not useful (and
1420 sometimes confusing) to the casual installer
1421 --disable-largefile omit support for large files
1422 --enable-threading include support for parallel processing of data
1423 (yes/no)
1424 --disable-rpath do not hardcode runtime library paths
1425 --enable-unit-tests Enable the inclusion of unit tests when compiling
1427 --disable-nls do not use Native Language Support
1428 --enable-werror treat compile warnings as errors
1429 --enable-build-warnings enable build-time compiler warnings if gcc is used
1430 --enable-gdb-build-warnings
1431 enable GDB specific build-time compiler warnings if
1432 gcc is used
1433 --enable-inprocess-agent
1434 inprocess agent
1436 Optional Packages:
1437 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
1438 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
1439 --with-intel-pt include Intel Processor Trace support (auto/yes/no)
1440 --with-gnu-ld assume the C compiler uses GNU ld default=no
1441 --with-libipt-prefix[=DIR] search for libipt in DIR/include and DIR/lib
1442 --without-libipt-prefix don't search for libipt in includedir and libdir
1443 --with-libipt-type=TYPE type of library to search for (auto/static/shared)
1444 --with-xxhash use libxxhash for hashing (faster) (auto/yes/no)
1445 --with-libxxhash-prefix[=DIR] search for libxxhash in DIR/include and DIR/lib
1446 --without-libxxhash-prefix don't search for libxxhash in includedir and libdir
1447 --with-libxxhash-type=TYPE type of library to search for (auto/static/shared)
1448 --with-libiconv-prefix[=DIR] search for libiconv in DIR/include and DIR/lib
1449 --without-libiconv-prefix don't search for libiconv in includedir and libdir
1450 --with-libiconv-type=TYPE type of library to search for (auto/static/shared)
1451 --with-libintl-prefix[=DIR] search for libintl in DIR/include and DIR/lib
1452 --without-libintl-prefix don't search for libintl in includedir and libdir
1453 --with-libintl-type=TYPE type of library to search for (auto/static/shared)
1454 --with-ust=PATH Specify prefix directory for the installed UST package
1455 Equivalent to --with-ust-include=PATH/include
1456 plus --with-ust-lib=PATH/lib
1457 --with-ust-include=PATH Specify directory for installed UST include files
1458 --with-ust-lib=PATH Specify the directory for the installed UST library
1459 --with-pkgversion=PKG Use PKG in the version string in place of "GDB"
1460 --with-bugurl=URL Direct users to URL to report a bug
1461 --with-libthread-db=PATH
1462 use given libthread_db directly
1464 Some influential environment variables:
1465 CC C compiler command
1466 CFLAGS C compiler flags
1467 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
1468 nonstandard directory <lib dir>
1469 LIBS libraries to pass to the linker, e.g. -l<library>
1470 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
1471 you have headers in a nonstandard directory <include dir>
1472 CXX C++ compiler command
1473 CXXFLAGS C++ compiler flags
1474 CPP C preprocessor
1476 Use these variables to override the choices made by `configure' or to help
1477 it to find libraries and programs with nonstandard names/locations.
1479 Report bugs to the package provider.
1480 _ACEOF
1481 ac_status=$?
1484 if test "$ac_init_help" = "recursive"; then
1485 # If there are subdirs, report their specific --help.
1486 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1487 test -d "$ac_dir" ||
1488 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1489 continue
1490 ac_builddir=.
1492 case "$ac_dir" in
1493 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1495 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1496 # A ".." for each directory in $ac_dir_suffix.
1497 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1498 case $ac_top_builddir_sub in
1499 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1500 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1501 esac ;;
1502 esac
1503 ac_abs_top_builddir=$ac_pwd
1504 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1505 # for backward compatibility:
1506 ac_top_builddir=$ac_top_build_prefix
1508 case $srcdir in
1509 .) # We are building in place.
1510 ac_srcdir=.
1511 ac_top_srcdir=$ac_top_builddir_sub
1512 ac_abs_top_srcdir=$ac_pwd ;;
1513 [\\/]* | ?:[\\/]* ) # Absolute name.
1514 ac_srcdir=$srcdir$ac_dir_suffix;
1515 ac_top_srcdir=$srcdir
1516 ac_abs_top_srcdir=$srcdir ;;
1517 *) # Relative name.
1518 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1519 ac_top_srcdir=$ac_top_build_prefix$srcdir
1520 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1521 esac
1522 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1524 cd "$ac_dir" || { ac_status=$?; continue; }
1525 # Check for guested configure.
1526 if test -f "$ac_srcdir/configure.gnu"; then
1527 echo &&
1528 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1529 elif test -f "$ac_srcdir/configure"; then
1530 echo &&
1531 $SHELL "$ac_srcdir/configure" --help=recursive
1532 else
1533 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1534 fi || ac_status=$?
1535 cd "$ac_pwd" || { ac_status=$?; break; }
1536 done
1539 test -n "$ac_init_help" && exit $ac_status
1540 if $ac_init_version; then
1541 cat <<\_ACEOF
1542 configure
1543 generated by GNU Autoconf 2.69
1545 Copyright (C) 2012 Free Software Foundation, Inc.
1546 This configure script is free software; the Free Software Foundation
1547 gives unlimited permission to copy, distribute and modify it.
1548 _ACEOF
1549 exit
1552 ## ------------------------ ##
1553 ## Autoconf initialization. ##
1554 ## ------------------------ ##
1556 # ac_fn_c_try_compile LINENO
1557 # --------------------------
1558 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1559 ac_fn_c_try_compile ()
1561 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1562 rm -f conftest.$ac_objext
1563 if { { ac_try="$ac_compile"
1564 case "(($ac_try" in
1565 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1566 *) ac_try_echo=$ac_try;;
1567 esac
1568 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1569 $as_echo "$ac_try_echo"; } >&5
1570 (eval "$ac_compile") 2>conftest.err
1571 ac_status=$?
1572 if test -s conftest.err; then
1573 grep -v '^ *+' conftest.err >conftest.er1
1574 cat conftest.er1 >&5
1575 mv -f conftest.er1 conftest.err
1577 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1578 test $ac_status = 0; } && {
1579 test -z "$ac_c_werror_flag" ||
1580 test ! -s conftest.err
1581 } && test -s conftest.$ac_objext; then :
1582 ac_retval=0
1583 else
1584 $as_echo "$as_me: failed program was:" >&5
1585 sed 's/^/| /' conftest.$ac_ext >&5
1587 ac_retval=1
1589 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1590 as_fn_set_status $ac_retval
1592 } # ac_fn_c_try_compile
1594 # ac_fn_cxx_try_compile LINENO
1595 # ----------------------------
1596 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1597 ac_fn_cxx_try_compile ()
1599 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1600 rm -f conftest.$ac_objext
1601 if { { ac_try="$ac_compile"
1602 case "(($ac_try" in
1603 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1604 *) ac_try_echo=$ac_try;;
1605 esac
1606 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1607 $as_echo "$ac_try_echo"; } >&5
1608 (eval "$ac_compile") 2>conftest.err
1609 ac_status=$?
1610 if test -s conftest.err; then
1611 grep -v '^ *+' conftest.err >conftest.er1
1612 cat conftest.er1 >&5
1613 mv -f conftest.er1 conftest.err
1615 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1616 test $ac_status = 0; } && {
1617 test -z "$ac_cxx_werror_flag" ||
1618 test ! -s conftest.err
1619 } && test -s conftest.$ac_objext; then :
1620 ac_retval=0
1621 else
1622 $as_echo "$as_me: failed program was:" >&5
1623 sed 's/^/| /' conftest.$ac_ext >&5
1625 ac_retval=1
1627 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1628 as_fn_set_status $ac_retval
1630 } # ac_fn_cxx_try_compile
1632 # ac_fn_c_try_cpp LINENO
1633 # ----------------------
1634 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1635 ac_fn_c_try_cpp ()
1637 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1638 if { { ac_try="$ac_cpp conftest.$ac_ext"
1639 case "(($ac_try" in
1640 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1641 *) ac_try_echo=$ac_try;;
1642 esac
1643 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1644 $as_echo "$ac_try_echo"; } >&5
1645 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1646 ac_status=$?
1647 if test -s conftest.err; then
1648 grep -v '^ *+' conftest.err >conftest.er1
1649 cat conftest.er1 >&5
1650 mv -f conftest.er1 conftest.err
1652 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1653 test $ac_status = 0; } > conftest.i && {
1654 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1655 test ! -s conftest.err
1656 }; then :
1657 ac_retval=0
1658 else
1659 $as_echo "$as_me: failed program was:" >&5
1660 sed 's/^/| /' conftest.$ac_ext >&5
1662 ac_retval=1
1664 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1665 as_fn_set_status $ac_retval
1667 } # ac_fn_c_try_cpp
1669 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
1670 # -------------------------------------------------------
1671 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
1672 # the include files in INCLUDES and setting the cache variable VAR
1673 # accordingly.
1674 ac_fn_c_check_header_mongrel ()
1676 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1677 if eval \${$3+:} false; then :
1678 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1679 $as_echo_n "checking for $2... " >&6; }
1680 if eval \${$3+:} false; then :
1681 $as_echo_n "(cached) " >&6
1683 eval ac_res=\$$3
1684 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1685 $as_echo "$ac_res" >&6; }
1686 else
1687 # Is the header compilable?
1688 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
1689 $as_echo_n "checking $2 usability... " >&6; }
1690 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1691 /* end confdefs.h. */
1693 #include <$2>
1694 _ACEOF
1695 if ac_fn_c_try_compile "$LINENO"; then :
1696 ac_header_compiler=yes
1697 else
1698 ac_header_compiler=no
1700 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1701 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
1702 $as_echo "$ac_header_compiler" >&6; }
1704 # Is the header present?
1705 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
1706 $as_echo_n "checking $2 presence... " >&6; }
1707 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1708 /* end confdefs.h. */
1709 #include <$2>
1710 _ACEOF
1711 if ac_fn_c_try_cpp "$LINENO"; then :
1712 ac_header_preproc=yes
1713 else
1714 ac_header_preproc=no
1716 rm -f conftest.err conftest.i conftest.$ac_ext
1717 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
1718 $as_echo "$ac_header_preproc" >&6; }
1720 # So? What about this header?
1721 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
1722 yes:no: )
1723 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
1724 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
1725 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1726 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1728 no:yes:* )
1729 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
1730 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
1731 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
1732 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
1733 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
1734 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
1735 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
1736 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
1737 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1738 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1740 esac
1741 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1742 $as_echo_n "checking for $2... " >&6; }
1743 if eval \${$3+:} false; then :
1744 $as_echo_n "(cached) " >&6
1745 else
1746 eval "$3=\$ac_header_compiler"
1748 eval ac_res=\$$3
1749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1750 $as_echo "$ac_res" >&6; }
1752 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1754 } # ac_fn_c_check_header_mongrel
1756 # ac_fn_c_try_run LINENO
1757 # ----------------------
1758 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
1759 # that executables *can* be run.
1760 ac_fn_c_try_run ()
1762 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1763 if { { ac_try="$ac_link"
1764 case "(($ac_try" in
1765 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1766 *) ac_try_echo=$ac_try;;
1767 esac
1768 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1769 $as_echo "$ac_try_echo"; } >&5
1770 (eval "$ac_link") 2>&5
1771 ac_status=$?
1772 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1773 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1774 { { case "(($ac_try" in
1775 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1776 *) ac_try_echo=$ac_try;;
1777 esac
1778 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1779 $as_echo "$ac_try_echo"; } >&5
1780 (eval "$ac_try") 2>&5
1781 ac_status=$?
1782 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1783 test $ac_status = 0; }; }; then :
1784 ac_retval=0
1785 else
1786 $as_echo "$as_me: program exited with status $ac_status" >&5
1787 $as_echo "$as_me: failed program was:" >&5
1788 sed 's/^/| /' conftest.$ac_ext >&5
1790 ac_retval=$ac_status
1792 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1793 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1794 as_fn_set_status $ac_retval
1796 } # ac_fn_c_try_run
1798 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
1799 # -------------------------------------------------------
1800 # Tests whether HEADER exists and can be compiled using the include files in
1801 # INCLUDES, setting the cache variable VAR accordingly.
1802 ac_fn_c_check_header_compile ()
1804 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1805 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1806 $as_echo_n "checking for $2... " >&6; }
1807 if eval \${$3+:} false; then :
1808 $as_echo_n "(cached) " >&6
1809 else
1810 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1811 /* end confdefs.h. */
1813 #include <$2>
1814 _ACEOF
1815 if ac_fn_c_try_compile "$LINENO"; then :
1816 eval "$3=yes"
1817 else
1818 eval "$3=no"
1820 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1822 eval ac_res=\$$3
1823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1824 $as_echo "$ac_res" >&6; }
1825 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1827 } # ac_fn_c_check_header_compile
1829 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
1830 # -------------------------------------------
1831 # Tests whether TYPE exists after having included INCLUDES, setting cache
1832 # variable VAR accordingly.
1833 ac_fn_c_check_type ()
1835 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1836 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1837 $as_echo_n "checking for $2... " >&6; }
1838 if eval \${$3+:} false; then :
1839 $as_echo_n "(cached) " >&6
1840 else
1841 eval "$3=no"
1842 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1843 /* end confdefs.h. */
1846 main ()
1848 if (sizeof ($2))
1849 return 0;
1851 return 0;
1853 _ACEOF
1854 if ac_fn_c_try_compile "$LINENO"; then :
1855 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1856 /* end confdefs.h. */
1859 main ()
1861 if (sizeof (($2)))
1862 return 0;
1864 return 0;
1866 _ACEOF
1867 if ac_fn_c_try_compile "$LINENO"; then :
1869 else
1870 eval "$3=yes"
1872 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1874 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1876 eval ac_res=\$$3
1877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1878 $as_echo "$ac_res" >&6; }
1879 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1881 } # ac_fn_c_check_type
1883 # ac_fn_c_try_link LINENO
1884 # -----------------------
1885 # Try to link conftest.$ac_ext, and return whether this succeeded.
1886 ac_fn_c_try_link ()
1888 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1889 rm -f conftest.$ac_objext conftest$ac_exeext
1890 if { { ac_try="$ac_link"
1891 case "(($ac_try" in
1892 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1893 *) ac_try_echo=$ac_try;;
1894 esac
1895 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1896 $as_echo "$ac_try_echo"; } >&5
1897 (eval "$ac_link") 2>conftest.err
1898 ac_status=$?
1899 if test -s conftest.err; then
1900 grep -v '^ *+' conftest.err >conftest.er1
1901 cat conftest.er1 >&5
1902 mv -f conftest.er1 conftest.err
1904 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1905 test $ac_status = 0; } && {
1906 test -z "$ac_c_werror_flag" ||
1907 test ! -s conftest.err
1908 } && test -s conftest$ac_exeext && {
1909 test "$cross_compiling" = yes ||
1910 test -x conftest$ac_exeext
1911 }; then :
1912 ac_retval=0
1913 else
1914 $as_echo "$as_me: failed program was:" >&5
1915 sed 's/^/| /' conftest.$ac_ext >&5
1917 ac_retval=1
1919 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
1920 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
1921 # interfere with the next link command; also delete a directory that is
1922 # left behind by Apple's compiler. We do this before executing the actions.
1923 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1924 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1925 as_fn_set_status $ac_retval
1927 } # ac_fn_c_try_link
1929 # ac_fn_c_check_func LINENO FUNC VAR
1930 # ----------------------------------
1931 # Tests whether FUNC exists, setting the cache variable VAR accordingly
1932 ac_fn_c_check_func ()
1934 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1935 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1936 $as_echo_n "checking for $2... " >&6; }
1937 if eval \${$3+:} false; then :
1938 $as_echo_n "(cached) " >&6
1939 else
1940 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1941 /* end confdefs.h. */
1942 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
1943 For example, HP-UX 11i <limits.h> declares gettimeofday. */
1944 #define $2 innocuous_$2
1946 /* System header to define __stub macros and hopefully few prototypes,
1947 which can conflict with char $2 (); below.
1948 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
1949 <limits.h> exists even on freestanding compilers. */
1951 #ifdef __STDC__
1952 # include <limits.h>
1953 #else
1954 # include <assert.h>
1955 #endif
1957 #undef $2
1959 /* Override any GCC internal prototype to avoid an error.
1960 Use char because int might match the return type of a GCC
1961 builtin and then its argument prototype would still apply. */
1962 #ifdef __cplusplus
1963 extern "C"
1964 #endif
1965 char $2 ();
1966 /* The GNU C library defines this for functions which it implements
1967 to always fail with ENOSYS. Some functions are actually named
1968 something starting with __ and the normal name is an alias. */
1969 #if defined __stub_$2 || defined __stub___$2
1970 choke me
1971 #endif
1974 main ()
1976 return $2 ();
1978 return 0;
1980 _ACEOF
1981 if ac_fn_c_try_link "$LINENO"; then :
1982 eval "$3=yes"
1983 else
1984 eval "$3=no"
1986 rm -f core conftest.err conftest.$ac_objext \
1987 conftest$ac_exeext conftest.$ac_ext
1989 eval ac_res=\$$3
1990 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1991 $as_echo "$ac_res" >&6; }
1992 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1994 } # ac_fn_c_check_func
1996 # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
1997 # ---------------------------------------------
1998 # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
1999 # accordingly.
2000 ac_fn_c_check_decl ()
2002 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2003 as_decl_name=`echo $2|sed 's/ *(.*//'`
2004 as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
2005 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
2006 $as_echo_n "checking whether $as_decl_name is declared... " >&6; }
2007 if eval \${$3+:} false; then :
2008 $as_echo_n "(cached) " >&6
2009 else
2010 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2011 /* end confdefs.h. */
2014 main ()
2016 #ifndef $as_decl_name
2017 #ifdef __cplusplus
2018 (void) $as_decl_use;
2019 #else
2020 (void) $as_decl_name;
2021 #endif
2022 #endif
2025 return 0;
2027 _ACEOF
2028 if ac_fn_c_try_compile "$LINENO"; then :
2029 eval "$3=yes"
2030 else
2031 eval "$3=no"
2033 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2035 eval ac_res=\$$3
2036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2037 $as_echo "$ac_res" >&6; }
2038 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2040 } # ac_fn_c_check_decl
2042 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2043 # ----------------------------------------------------
2044 # Tries to find if the field MEMBER exists in type AGGR, after including
2045 # INCLUDES, setting cache variable VAR accordingly.
2046 ac_fn_c_check_member ()
2048 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2049 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2050 $as_echo_n "checking for $2.$3... " >&6; }
2051 if eval \${$4+:} false; then :
2052 $as_echo_n "(cached) " >&6
2053 else
2054 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2055 /* end confdefs.h. */
2058 main ()
2060 static $2 ac_aggr;
2061 if (ac_aggr.$3)
2062 return 0;
2064 return 0;
2066 _ACEOF
2067 if ac_fn_c_try_compile "$LINENO"; then :
2068 eval "$4=yes"
2069 else
2070 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2071 /* end confdefs.h. */
2074 main ()
2076 static $2 ac_aggr;
2077 if (sizeof ac_aggr.$3)
2078 return 0;
2080 return 0;
2082 _ACEOF
2083 if ac_fn_c_try_compile "$LINENO"; then :
2084 eval "$4=yes"
2085 else
2086 eval "$4=no"
2088 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2090 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2092 eval ac_res=\$$4
2093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2094 $as_echo "$ac_res" >&6; }
2095 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2097 } # ac_fn_c_check_member
2099 # ac_fn_cxx_try_link LINENO
2100 # -------------------------
2101 # Try to link conftest.$ac_ext, and return whether this succeeded.
2102 ac_fn_cxx_try_link ()
2104 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2105 rm -f conftest.$ac_objext conftest$ac_exeext
2106 if { { ac_try="$ac_link"
2107 case "(($ac_try" in
2108 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2109 *) ac_try_echo=$ac_try;;
2110 esac
2111 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2112 $as_echo "$ac_try_echo"; } >&5
2113 (eval "$ac_link") 2>conftest.err
2114 ac_status=$?
2115 if test -s conftest.err; then
2116 grep -v '^ *+' conftest.err >conftest.er1
2117 cat conftest.er1 >&5
2118 mv -f conftest.er1 conftest.err
2120 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2121 test $ac_status = 0; } && {
2122 test -z "$ac_cxx_werror_flag" ||
2123 test ! -s conftest.err
2124 } && test -s conftest$ac_exeext && {
2125 test "$cross_compiling" = yes ||
2126 test -x conftest$ac_exeext
2127 }; then :
2128 ac_retval=0
2129 else
2130 $as_echo "$as_me: failed program was:" >&5
2131 sed 's/^/| /' conftest.$ac_ext >&5
2133 ac_retval=1
2135 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2136 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2137 # interfere with the next link command; also delete a directory that is
2138 # left behind by Apple's compiler. We do this before executing the actions.
2139 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2140 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2141 as_fn_set_status $ac_retval
2143 } # ac_fn_cxx_try_link
2145 # ac_fn_cxx_check_func LINENO FUNC VAR
2146 # ------------------------------------
2147 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2148 ac_fn_cxx_check_func ()
2150 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2151 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2152 $as_echo_n "checking for $2... " >&6; }
2153 if eval \${$3+:} false; then :
2154 $as_echo_n "(cached) " >&6
2155 else
2156 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2157 /* end confdefs.h. */
2158 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2159 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2160 #define $2 innocuous_$2
2162 /* System header to define __stub macros and hopefully few prototypes,
2163 which can conflict with char $2 (); below.
2164 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2165 <limits.h> exists even on freestanding compilers. */
2167 #ifdef __STDC__
2168 # include <limits.h>
2169 #else
2170 # include <assert.h>
2171 #endif
2173 #undef $2
2175 /* Override any GCC internal prototype to avoid an error.
2176 Use char because int might match the return type of a GCC
2177 builtin and then its argument prototype would still apply. */
2178 #ifdef __cplusplus
2179 extern "C"
2180 #endif
2181 char $2 ();
2182 /* The GNU C library defines this for functions which it implements
2183 to always fail with ENOSYS. Some functions are actually named
2184 something starting with __ and the normal name is an alias. */
2185 #if defined __stub_$2 || defined __stub___$2
2186 choke me
2187 #endif
2190 main ()
2192 return $2 ();
2194 return 0;
2196 _ACEOF
2197 if ac_fn_cxx_try_link "$LINENO"; then :
2198 eval "$3=yes"
2199 else
2200 eval "$3=no"
2202 rm -f core conftest.err conftest.$ac_objext \
2203 conftest$ac_exeext conftest.$ac_ext
2205 eval ac_res=\$$3
2206 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2207 $as_echo "$ac_res" >&6; }
2208 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2210 } # ac_fn_cxx_check_func
2212 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2213 # --------------------------------------------
2214 # Tries to find the compile-time value of EXPR in a program that includes
2215 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2216 # computed
2217 ac_fn_c_compute_int ()
2219 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2220 if test "$cross_compiling" = yes; then
2221 # Depending upon the size, compute the lo and hi bounds.
2222 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2223 /* end confdefs.h. */
2226 main ()
2228 static int test_array [1 - 2 * !(($2) >= 0)];
2229 test_array [0] = 0;
2230 return test_array [0];
2233 return 0;
2235 _ACEOF
2236 if ac_fn_c_try_compile "$LINENO"; then :
2237 ac_lo=0 ac_mid=0
2238 while :; do
2239 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2240 /* end confdefs.h. */
2243 main ()
2245 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2246 test_array [0] = 0;
2247 return test_array [0];
2250 return 0;
2252 _ACEOF
2253 if ac_fn_c_try_compile "$LINENO"; then :
2254 ac_hi=$ac_mid; break
2255 else
2256 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2257 if test $ac_lo -le $ac_mid; then
2258 ac_lo= ac_hi=
2259 break
2261 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2263 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2264 done
2265 else
2266 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2267 /* end confdefs.h. */
2270 main ()
2272 static int test_array [1 - 2 * !(($2) < 0)];
2273 test_array [0] = 0;
2274 return test_array [0];
2277 return 0;
2279 _ACEOF
2280 if ac_fn_c_try_compile "$LINENO"; then :
2281 ac_hi=-1 ac_mid=-1
2282 while :; do
2283 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2284 /* end confdefs.h. */
2287 main ()
2289 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2290 test_array [0] = 0;
2291 return test_array [0];
2294 return 0;
2296 _ACEOF
2297 if ac_fn_c_try_compile "$LINENO"; then :
2298 ac_lo=$ac_mid; break
2299 else
2300 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2301 if test $ac_mid -le $ac_hi; then
2302 ac_lo= ac_hi=
2303 break
2305 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2307 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2308 done
2309 else
2310 ac_lo= ac_hi=
2312 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2314 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2315 # Binary search between lo and hi bounds.
2316 while test "x$ac_lo" != "x$ac_hi"; do
2317 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2318 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2319 /* end confdefs.h. */
2322 main ()
2324 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2325 test_array [0] = 0;
2326 return test_array [0];
2329 return 0;
2331 _ACEOF
2332 if ac_fn_c_try_compile "$LINENO"; then :
2333 ac_hi=$ac_mid
2334 else
2335 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2337 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2338 done
2339 case $ac_lo in #((
2340 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2341 '') ac_retval=1 ;;
2342 esac
2343 else
2344 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2345 /* end confdefs.h. */
2347 static long int longval () { return $2; }
2348 static unsigned long int ulongval () { return $2; }
2349 #include <stdio.h>
2350 #include <stdlib.h>
2352 main ()
2355 FILE *f = fopen ("conftest.val", "w");
2356 if (! f)
2357 return 1;
2358 if (($2) < 0)
2360 long int i = longval ();
2361 if (i != ($2))
2362 return 1;
2363 fprintf (f, "%ld", i);
2365 else
2367 unsigned long int i = ulongval ();
2368 if (i != ($2))
2369 return 1;
2370 fprintf (f, "%lu", i);
2372 /* Do not output a trailing newline, as this causes \r\n confusion
2373 on some platforms. */
2374 return ferror (f) || fclose (f) != 0;
2377 return 0;
2379 _ACEOF
2380 if ac_fn_c_try_run "$LINENO"; then :
2381 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2382 else
2383 ac_retval=1
2385 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2386 conftest.$ac_objext conftest.beam conftest.$ac_ext
2387 rm -f conftest.val
2390 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2391 as_fn_set_status $ac_retval
2393 } # ac_fn_c_compute_int
2394 cat >config.log <<_ACEOF
2395 This file contains any messages produced by compilers while
2396 running configure, to aid debugging if configure makes a mistake.
2398 It was created by $as_me, which was
2399 generated by GNU Autoconf 2.69. Invocation command line was
2401 $ $0 $@
2403 _ACEOF
2404 exec 5>>config.log
2406 cat <<_ASUNAME
2407 ## --------- ##
2408 ## Platform. ##
2409 ## --------- ##
2411 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2412 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2413 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2414 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2415 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2417 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2418 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
2420 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2421 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2422 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2423 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2424 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2425 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2426 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
2428 _ASUNAME
2430 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2431 for as_dir in $PATH
2433 IFS=$as_save_IFS
2434 test -z "$as_dir" && as_dir=.
2435 $as_echo "PATH: $as_dir"
2436 done
2437 IFS=$as_save_IFS
2439 } >&5
2441 cat >&5 <<_ACEOF
2444 ## ----------- ##
2445 ## Core tests. ##
2446 ## ----------- ##
2448 _ACEOF
2451 # Keep a trace of the command line.
2452 # Strip out --no-create and --no-recursion so they do not pile up.
2453 # Strip out --silent because we don't want to record it for future runs.
2454 # Also quote any args containing shell meta-characters.
2455 # Make two passes to allow for proper duplicate-argument suppression.
2456 ac_configure_args=
2457 ac_configure_args0=
2458 ac_configure_args1=
2459 ac_must_keep_next=false
2460 for ac_pass in 1 2
2462 for ac_arg
2464 case $ac_arg in
2465 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2466 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2467 | -silent | --silent | --silen | --sile | --sil)
2468 continue ;;
2469 *\'*)
2470 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2471 esac
2472 case $ac_pass in
2473 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2475 as_fn_append ac_configure_args1 " '$ac_arg'"
2476 if test $ac_must_keep_next = true; then
2477 ac_must_keep_next=false # Got value, back to normal.
2478 else
2479 case $ac_arg in
2480 *=* | --config-cache | -C | -disable-* | --disable-* \
2481 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2482 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2483 | -with-* | --with-* | -without-* | --without-* | --x)
2484 case "$ac_configure_args0 " in
2485 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2486 esac
2488 -* ) ac_must_keep_next=true ;;
2489 esac
2491 as_fn_append ac_configure_args " '$ac_arg'"
2493 esac
2494 done
2495 done
2496 { ac_configure_args0=; unset ac_configure_args0;}
2497 { ac_configure_args1=; unset ac_configure_args1;}
2499 # When interrupted or exit'd, cleanup temporary files, and complete
2500 # config.log. We remove comments because anyway the quotes in there
2501 # would cause problems or look ugly.
2502 # WARNING: Use '\'' to represent an apostrophe within the trap.
2503 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2504 trap 'exit_status=$?
2505 # Save into config.log some information that might help in debugging.
2507 echo
2509 $as_echo "## ---------------- ##
2510 ## Cache variables. ##
2511 ## ---------------- ##"
2512 echo
2513 # The following way of writing the cache mishandles newlines in values,
2515 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2516 eval ac_val=\$$ac_var
2517 case $ac_val in #(
2518 *${as_nl}*)
2519 case $ac_var in #(
2520 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2521 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2522 esac
2523 case $ac_var in #(
2524 _ | IFS | as_nl) ;; #(
2525 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2526 *) { eval $ac_var=; unset $ac_var;} ;;
2527 esac ;;
2528 esac
2529 done
2530 (set) 2>&1 |
2531 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2532 *${as_nl}ac_space=\ *)
2533 sed -n \
2534 "s/'\''/'\''\\\\'\'''\''/g;
2535 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2536 ;; #(
2538 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2540 esac |
2541 sort
2543 echo
2545 $as_echo "## ----------------- ##
2546 ## Output variables. ##
2547 ## ----------------- ##"
2548 echo
2549 for ac_var in $ac_subst_vars
2551 eval ac_val=\$$ac_var
2552 case $ac_val in
2553 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2554 esac
2555 $as_echo "$ac_var='\''$ac_val'\''"
2556 done | sort
2557 echo
2559 if test -n "$ac_subst_files"; then
2560 $as_echo "## ------------------- ##
2561 ## File substitutions. ##
2562 ## ------------------- ##"
2563 echo
2564 for ac_var in $ac_subst_files
2566 eval ac_val=\$$ac_var
2567 case $ac_val in
2568 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2569 esac
2570 $as_echo "$ac_var='\''$ac_val'\''"
2571 done | sort
2572 echo
2575 if test -s confdefs.h; then
2576 $as_echo "## ----------- ##
2577 ## confdefs.h. ##
2578 ## ----------- ##"
2579 echo
2580 cat confdefs.h
2581 echo
2583 test "$ac_signal" != 0 &&
2584 $as_echo "$as_me: caught signal $ac_signal"
2585 $as_echo "$as_me: exit $exit_status"
2586 } >&5
2587 rm -f core *.core core.conftest.* &&
2588 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2589 exit $exit_status
2591 for ac_signal in 1 2 13 15; do
2592 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2593 done
2594 ac_signal=0
2596 # confdefs.h avoids OS command line length limits that DEFS can exceed.
2597 rm -f -r conftest* confdefs.h
2599 $as_echo "/* confdefs.h */" > confdefs.h
2601 # Predefined preprocessor variables.
2603 cat >>confdefs.h <<_ACEOF
2604 #define PACKAGE_NAME "$PACKAGE_NAME"
2605 _ACEOF
2607 cat >>confdefs.h <<_ACEOF
2608 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2609 _ACEOF
2611 cat >>confdefs.h <<_ACEOF
2612 #define PACKAGE_VERSION "$PACKAGE_VERSION"
2613 _ACEOF
2615 cat >>confdefs.h <<_ACEOF
2616 #define PACKAGE_STRING "$PACKAGE_STRING"
2617 _ACEOF
2619 cat >>confdefs.h <<_ACEOF
2620 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2621 _ACEOF
2623 cat >>confdefs.h <<_ACEOF
2624 #define PACKAGE_URL "$PACKAGE_URL"
2625 _ACEOF
2628 # Let the site file select an alternate cache file if it wants to.
2629 # Prefer an explicitly selected file to automatically selected ones.
2630 ac_site_file1=NONE
2631 ac_site_file2=NONE
2632 if test -n "$CONFIG_SITE"; then
2633 # We do not want a PATH search for config.site.
2634 case $CONFIG_SITE in #((
2635 -*) ac_site_file1=./$CONFIG_SITE;;
2636 */*) ac_site_file1=$CONFIG_SITE;;
2637 *) ac_site_file1=./$CONFIG_SITE;;
2638 esac
2639 elif test "x$prefix" != xNONE; then
2640 ac_site_file1=$prefix/share/config.site
2641 ac_site_file2=$prefix/etc/config.site
2642 else
2643 ac_site_file1=$ac_default_prefix/share/config.site
2644 ac_site_file2=$ac_default_prefix/etc/config.site
2646 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2648 test "x$ac_site_file" = xNONE && continue
2649 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
2650 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2651 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
2652 sed 's/^/| /' "$ac_site_file" >&5
2653 . "$ac_site_file" \
2654 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2655 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2656 as_fn_error $? "failed to load site script $ac_site_file
2657 See \`config.log' for more details" "$LINENO" 5; }
2659 done
2661 if test -r "$cache_file"; then
2662 # Some versions of bash will fail to source /dev/null (special files
2663 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
2664 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2665 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2666 $as_echo "$as_me: loading cache $cache_file" >&6;}
2667 case $cache_file in
2668 [\\/]* | ?:[\\/]* ) . "$cache_file";;
2669 *) . "./$cache_file";;
2670 esac
2672 else
2673 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2674 $as_echo "$as_me: creating cache $cache_file" >&6;}
2675 >$cache_file
2678 as_fn_append ac_header_list " stdlib.h"
2679 as_fn_append ac_header_list " unistd.h"
2680 as_fn_append ac_header_list " sys/param.h"
2681 gt_needs="$gt_needs "
2682 # Check that the precious variables saved in the cache have kept the same
2683 # value.
2684 ac_cache_corrupted=false
2685 for ac_var in $ac_precious_vars; do
2686 eval ac_old_set=\$ac_cv_env_${ac_var}_set
2687 eval ac_new_set=\$ac_env_${ac_var}_set
2688 eval ac_old_val=\$ac_cv_env_${ac_var}_value
2689 eval ac_new_val=\$ac_env_${ac_var}_value
2690 case $ac_old_set,$ac_new_set in
2691 set,)
2692 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2693 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2694 ac_cache_corrupted=: ;;
2695 ,set)
2696 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2697 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2698 ac_cache_corrupted=: ;;
2699 ,);;
2701 if test "x$ac_old_val" != "x$ac_new_val"; then
2702 # differences in whitespace do not lead to failure.
2703 ac_old_val_w=`echo x $ac_old_val`
2704 ac_new_val_w=`echo x $ac_new_val`
2705 if test "$ac_old_val_w" != "$ac_new_val_w"; then
2706 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2707 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2708 ac_cache_corrupted=:
2709 else
2710 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2711 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2712 eval $ac_var=\$ac_old_val
2714 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
2715 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
2716 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
2717 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
2718 fi;;
2719 esac
2720 # Pass precious variables to config.status.
2721 if test "$ac_new_set" = set; then
2722 case $ac_new_val in
2723 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2724 *) ac_arg=$ac_var=$ac_new_val ;;
2725 esac
2726 case " $ac_configure_args " in
2727 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
2728 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2729 esac
2731 done
2732 if $ac_cache_corrupted; then
2733 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2734 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2735 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2736 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2737 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
2739 ## -------------------- ##
2740 ## Main body of script. ##
2741 ## -------------------- ##
2743 ac_ext=c
2744 ac_cpp='$CPP $CPPFLAGS'
2745 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2746 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2747 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2755 ac_config_headers="$ac_config_headers config.h:config.in"
2759 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5
2760 $as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
2761 # Check whether --enable-maintainer-mode was given.
2762 if test "${enable_maintainer_mode+set}" = set; then :
2763 enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
2764 else
2765 USE_MAINTAINER_MODE=no
2768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5
2769 $as_echo "$USE_MAINTAINER_MODE" >&6; }
2770 if test $USE_MAINTAINER_MODE = yes; then
2771 MAINTAINER_MODE_TRUE=
2772 MAINTAINER_MODE_FALSE='#'
2773 else
2774 MAINTAINER_MODE_TRUE='#'
2775 MAINTAINER_MODE_FALSE=
2778 MAINT=$MAINTAINER_MODE_TRUE
2782 ac_ext=c
2783 ac_cpp='$CPP $CPPFLAGS'
2784 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2785 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2786 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2787 if test -n "$ac_tool_prefix"; then
2788 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
2789 set dummy ${ac_tool_prefix}gcc; ac_word=$2
2790 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2791 $as_echo_n "checking for $ac_word... " >&6; }
2792 if ${ac_cv_prog_CC+:} false; then :
2793 $as_echo_n "(cached) " >&6
2794 else
2795 if test -n "$CC"; then
2796 ac_cv_prog_CC="$CC" # Let the user override the test.
2797 else
2798 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2799 for as_dir in $PATH
2801 IFS=$as_save_IFS
2802 test -z "$as_dir" && as_dir=.
2803 for ac_exec_ext in '' $ac_executable_extensions; do
2804 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2805 ac_cv_prog_CC="${ac_tool_prefix}gcc"
2806 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2807 break 2
2809 done
2810 done
2811 IFS=$as_save_IFS
2815 CC=$ac_cv_prog_CC
2816 if test -n "$CC"; then
2817 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2818 $as_echo "$CC" >&6; }
2819 else
2820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2821 $as_echo "no" >&6; }
2826 if test -z "$ac_cv_prog_CC"; then
2827 ac_ct_CC=$CC
2828 # Extract the first word of "gcc", so it can be a program name with args.
2829 set dummy gcc; ac_word=$2
2830 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2831 $as_echo_n "checking for $ac_word... " >&6; }
2832 if ${ac_cv_prog_ac_ct_CC+:} false; then :
2833 $as_echo_n "(cached) " >&6
2834 else
2835 if test -n "$ac_ct_CC"; then
2836 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2837 else
2838 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2839 for as_dir in $PATH
2841 IFS=$as_save_IFS
2842 test -z "$as_dir" && as_dir=.
2843 for ac_exec_ext in '' $ac_executable_extensions; do
2844 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2845 ac_cv_prog_ac_ct_CC="gcc"
2846 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2847 break 2
2849 done
2850 done
2851 IFS=$as_save_IFS
2855 ac_ct_CC=$ac_cv_prog_ac_ct_CC
2856 if test -n "$ac_ct_CC"; then
2857 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
2858 $as_echo "$ac_ct_CC" >&6; }
2859 else
2860 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2861 $as_echo "no" >&6; }
2864 if test "x$ac_ct_CC" = x; then
2865 CC=""
2866 else
2867 case $cross_compiling:$ac_tool_warned in
2868 yes:)
2869 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
2870 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
2871 ac_tool_warned=yes ;;
2872 esac
2873 CC=$ac_ct_CC
2875 else
2876 CC="$ac_cv_prog_CC"
2879 if test -z "$CC"; then
2880 if test -n "$ac_tool_prefix"; then
2881 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
2882 set dummy ${ac_tool_prefix}cc; ac_word=$2
2883 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2884 $as_echo_n "checking for $ac_word... " >&6; }
2885 if ${ac_cv_prog_CC+:} false; then :
2886 $as_echo_n "(cached) " >&6
2887 else
2888 if test -n "$CC"; then
2889 ac_cv_prog_CC="$CC" # Let the user override the test.
2890 else
2891 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2892 for as_dir in $PATH
2894 IFS=$as_save_IFS
2895 test -z "$as_dir" && as_dir=.
2896 for ac_exec_ext in '' $ac_executable_extensions; do
2897 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2898 ac_cv_prog_CC="${ac_tool_prefix}cc"
2899 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2900 break 2
2902 done
2903 done
2904 IFS=$as_save_IFS
2908 CC=$ac_cv_prog_CC
2909 if test -n "$CC"; then
2910 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2911 $as_echo "$CC" >&6; }
2912 else
2913 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2914 $as_echo "no" >&6; }
2920 if test -z "$CC"; then
2921 # Extract the first word of "cc", so it can be a program name with args.
2922 set dummy cc; ac_word=$2
2923 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2924 $as_echo_n "checking for $ac_word... " >&6; }
2925 if ${ac_cv_prog_CC+:} false; then :
2926 $as_echo_n "(cached) " >&6
2927 else
2928 if test -n "$CC"; then
2929 ac_cv_prog_CC="$CC" # Let the user override the test.
2930 else
2931 ac_prog_rejected=no
2932 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2933 for as_dir in $PATH
2935 IFS=$as_save_IFS
2936 test -z "$as_dir" && as_dir=.
2937 for ac_exec_ext in '' $ac_executable_extensions; do
2938 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2939 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
2940 ac_prog_rejected=yes
2941 continue
2943 ac_cv_prog_CC="cc"
2944 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2945 break 2
2947 done
2948 done
2949 IFS=$as_save_IFS
2951 if test $ac_prog_rejected = yes; then
2952 # We found a bogon in the path, so make sure we never use it.
2953 set dummy $ac_cv_prog_CC
2954 shift
2955 if test $# != 0; then
2956 # We chose a different compiler from the bogus one.
2957 # However, it has the same basename, so the bogon will be chosen
2958 # first if we set CC to just the basename; use the full file name.
2959 shift
2960 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
2965 CC=$ac_cv_prog_CC
2966 if test -n "$CC"; then
2967 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2968 $as_echo "$CC" >&6; }
2969 else
2970 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2971 $as_echo "no" >&6; }
2976 if test -z "$CC"; then
2977 if test -n "$ac_tool_prefix"; then
2978 for ac_prog in cl.exe
2980 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2981 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
2982 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2983 $as_echo_n "checking for $ac_word... " >&6; }
2984 if ${ac_cv_prog_CC+:} false; then :
2985 $as_echo_n "(cached) " >&6
2986 else
2987 if test -n "$CC"; then
2988 ac_cv_prog_CC="$CC" # Let the user override the test.
2989 else
2990 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2991 for as_dir in $PATH
2993 IFS=$as_save_IFS
2994 test -z "$as_dir" && as_dir=.
2995 for ac_exec_ext in '' $ac_executable_extensions; do
2996 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2997 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
2998 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2999 break 2
3001 done
3002 done
3003 IFS=$as_save_IFS
3007 CC=$ac_cv_prog_CC
3008 if test -n "$CC"; then
3009 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3010 $as_echo "$CC" >&6; }
3011 else
3012 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3013 $as_echo "no" >&6; }
3017 test -n "$CC" && break
3018 done
3020 if test -z "$CC"; then
3021 ac_ct_CC=$CC
3022 for ac_prog in cl.exe
3024 # Extract the first word of "$ac_prog", so it can be a program name with args.
3025 set dummy $ac_prog; ac_word=$2
3026 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3027 $as_echo_n "checking for $ac_word... " >&6; }
3028 if ${ac_cv_prog_ac_ct_CC+:} false; then :
3029 $as_echo_n "(cached) " >&6
3030 else
3031 if test -n "$ac_ct_CC"; then
3032 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3033 else
3034 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3035 for as_dir in $PATH
3037 IFS=$as_save_IFS
3038 test -z "$as_dir" && as_dir=.
3039 for ac_exec_ext in '' $ac_executable_extensions; do
3040 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3041 ac_cv_prog_ac_ct_CC="$ac_prog"
3042 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3043 break 2
3045 done
3046 done
3047 IFS=$as_save_IFS
3051 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3052 if test -n "$ac_ct_CC"; then
3053 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3054 $as_echo "$ac_ct_CC" >&6; }
3055 else
3056 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3057 $as_echo "no" >&6; }
3061 test -n "$ac_ct_CC" && break
3062 done
3064 if test "x$ac_ct_CC" = x; then
3065 CC=""
3066 else
3067 case $cross_compiling:$ac_tool_warned in
3068 yes:)
3069 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3070 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3071 ac_tool_warned=yes ;;
3072 esac
3073 CC=$ac_ct_CC
3080 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3081 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3082 as_fn_error $? "no acceptable C compiler found in \$PATH
3083 See \`config.log' for more details" "$LINENO" 5; }
3085 # Provide some information about the compiler.
3086 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
3087 set X $ac_compile
3088 ac_compiler=$2
3089 for ac_option in --version -v -V -qversion; do
3090 { { ac_try="$ac_compiler $ac_option >&5"
3091 case "(($ac_try" in
3092 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3093 *) ac_try_echo=$ac_try;;
3094 esac
3095 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3096 $as_echo "$ac_try_echo"; } >&5
3097 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3098 ac_status=$?
3099 if test -s conftest.err; then
3100 sed '10a\
3101 ... rest of stderr output deleted ...
3102 10q' conftest.err >conftest.er1
3103 cat conftest.er1 >&5
3105 rm -f conftest.er1 conftest.err
3106 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3107 test $ac_status = 0; }
3108 done
3110 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3111 /* end confdefs.h. */
3114 main ()
3118 return 0;
3120 _ACEOF
3121 ac_clean_files_save=$ac_clean_files
3122 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
3123 # Try to create an executable without -o first, disregard a.out.
3124 # It will help us diagnose broken compilers, and finding out an intuition
3125 # of exeext.
3126 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
3127 $as_echo_n "checking whether the C compiler works... " >&6; }
3128 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3130 # The possible output files:
3131 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3133 ac_rmfiles=
3134 for ac_file in $ac_files
3136 case $ac_file in
3137 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3138 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3139 esac
3140 done
3141 rm -f $ac_rmfiles
3143 if { { ac_try="$ac_link_default"
3144 case "(($ac_try" in
3145 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3146 *) ac_try_echo=$ac_try;;
3147 esac
3148 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3149 $as_echo "$ac_try_echo"; } >&5
3150 (eval "$ac_link_default") 2>&5
3151 ac_status=$?
3152 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3153 test $ac_status = 0; }; then :
3154 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3155 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3156 # in a Makefile. We should not override ac_cv_exeext if it was cached,
3157 # so that the user can short-circuit this test for compilers unknown to
3158 # Autoconf.
3159 for ac_file in $ac_files ''
3161 test -f "$ac_file" || continue
3162 case $ac_file in
3163 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
3165 [ab].out )
3166 # We found the default executable, but exeext='' is most
3167 # certainly right.
3168 break;;
3169 *.* )
3170 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3171 then :; else
3172 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3174 # We set ac_cv_exeext here because the later test for it is not
3175 # safe: cross compilers may not add the suffix if given an `-o'
3176 # argument, so we may need to know it at that point already.
3177 # Even if this section looks crufty: it has the advantage of
3178 # actually working.
3179 break;;
3181 break;;
3182 esac
3183 done
3184 test "$ac_cv_exeext" = no && ac_cv_exeext=
3186 else
3187 ac_file=''
3189 if test -z "$ac_file"; then :
3190 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3191 $as_echo "no" >&6; }
3192 $as_echo "$as_me: failed program was:" >&5
3193 sed 's/^/| /' conftest.$ac_ext >&5
3195 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3196 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3197 as_fn_error 77 "C compiler cannot create executables
3198 See \`config.log' for more details" "$LINENO" 5; }
3199 else
3200 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3201 $as_echo "yes" >&6; }
3203 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
3204 $as_echo_n "checking for C compiler default output file name... " >&6; }
3205 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
3206 $as_echo "$ac_file" >&6; }
3207 ac_exeext=$ac_cv_exeext
3209 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
3210 ac_clean_files=$ac_clean_files_save
3211 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
3212 $as_echo_n "checking for suffix of executables... " >&6; }
3213 if { { ac_try="$ac_link"
3214 case "(($ac_try" in
3215 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3216 *) ac_try_echo=$ac_try;;
3217 esac
3218 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3219 $as_echo "$ac_try_echo"; } >&5
3220 (eval "$ac_link") 2>&5
3221 ac_status=$?
3222 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3223 test $ac_status = 0; }; then :
3224 # If both `conftest.exe' and `conftest' are `present' (well, observable)
3225 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
3226 # work properly (i.e., refer to `conftest.exe'), while it won't with
3227 # `rm'.
3228 for ac_file in conftest.exe conftest conftest.*; do
3229 test -f "$ac_file" || continue
3230 case $ac_file in
3231 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3232 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3233 break;;
3234 * ) break;;
3235 esac
3236 done
3237 else
3238 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3239 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3240 as_fn_error $? "cannot compute suffix of executables: cannot compile and link
3241 See \`config.log' for more details" "$LINENO" 5; }
3243 rm -f conftest conftest$ac_cv_exeext
3244 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
3245 $as_echo "$ac_cv_exeext" >&6; }
3247 rm -f conftest.$ac_ext
3248 EXEEXT=$ac_cv_exeext
3249 ac_exeext=$EXEEXT
3250 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3251 /* end confdefs.h. */
3252 #include <stdio.h>
3254 main ()
3256 FILE *f = fopen ("conftest.out", "w");
3257 return ferror (f) || fclose (f) != 0;
3260 return 0;
3262 _ACEOF
3263 ac_clean_files="$ac_clean_files conftest.out"
3264 # Check that the compiler produces executables we can run. If not, either
3265 # the compiler is broken, or we cross compile.
3266 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
3267 $as_echo_n "checking whether we are cross compiling... " >&6; }
3268 if test "$cross_compiling" != yes; then
3269 { { ac_try="$ac_link"
3270 case "(($ac_try" in
3271 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3272 *) ac_try_echo=$ac_try;;
3273 esac
3274 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3275 $as_echo "$ac_try_echo"; } >&5
3276 (eval "$ac_link") 2>&5
3277 ac_status=$?
3278 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3279 test $ac_status = 0; }
3280 if { ac_try='./conftest$ac_cv_exeext'
3281 { { case "(($ac_try" in
3282 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3283 *) ac_try_echo=$ac_try;;
3284 esac
3285 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3286 $as_echo "$ac_try_echo"; } >&5
3287 (eval "$ac_try") 2>&5
3288 ac_status=$?
3289 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3290 test $ac_status = 0; }; }; then
3291 cross_compiling=no
3292 else
3293 if test "$cross_compiling" = maybe; then
3294 cross_compiling=yes
3295 else
3296 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3297 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3298 as_fn_error $? "cannot run C compiled programs.
3299 If you meant to cross compile, use \`--host'.
3300 See \`config.log' for more details" "$LINENO" 5; }
3304 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
3305 $as_echo "$cross_compiling" >&6; }
3307 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
3308 ac_clean_files=$ac_clean_files_save
3309 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
3310 $as_echo_n "checking for suffix of object files... " >&6; }
3311 if ${ac_cv_objext+:} false; then :
3312 $as_echo_n "(cached) " >&6
3313 else
3314 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3315 /* end confdefs.h. */
3318 main ()
3322 return 0;
3324 _ACEOF
3325 rm -f conftest.o conftest.obj
3326 if { { ac_try="$ac_compile"
3327 case "(($ac_try" in
3328 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3329 *) ac_try_echo=$ac_try;;
3330 esac
3331 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3332 $as_echo "$ac_try_echo"; } >&5
3333 (eval "$ac_compile") 2>&5
3334 ac_status=$?
3335 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3336 test $ac_status = 0; }; then :
3337 for ac_file in conftest.o conftest.obj conftest.*; do
3338 test -f "$ac_file" || continue;
3339 case $ac_file in
3340 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
3341 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3342 break;;
3343 esac
3344 done
3345 else
3346 $as_echo "$as_me: failed program was:" >&5
3347 sed 's/^/| /' conftest.$ac_ext >&5
3349 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3350 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3351 as_fn_error $? "cannot compute suffix of object files: cannot compile
3352 See \`config.log' for more details" "$LINENO" 5; }
3354 rm -f conftest.$ac_cv_objext conftest.$ac_ext
3356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
3357 $as_echo "$ac_cv_objext" >&6; }
3358 OBJEXT=$ac_cv_objext
3359 ac_objext=$OBJEXT
3360 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
3361 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
3362 if ${ac_cv_c_compiler_gnu+:} false; then :
3363 $as_echo_n "(cached) " >&6
3364 else
3365 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3366 /* end confdefs.h. */
3369 main ()
3371 #ifndef __GNUC__
3372 choke me
3373 #endif
3376 return 0;
3378 _ACEOF
3379 if ac_fn_c_try_compile "$LINENO"; then :
3380 ac_compiler_gnu=yes
3381 else
3382 ac_compiler_gnu=no
3384 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3385 ac_cv_c_compiler_gnu=$ac_compiler_gnu
3388 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
3389 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
3390 if test $ac_compiler_gnu = yes; then
3391 GCC=yes
3392 else
3393 GCC=
3395 ac_test_CFLAGS=${CFLAGS+set}
3396 ac_save_CFLAGS=$CFLAGS
3397 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
3398 $as_echo_n "checking whether $CC accepts -g... " >&6; }
3399 if ${ac_cv_prog_cc_g+:} false; then :
3400 $as_echo_n "(cached) " >&6
3401 else
3402 ac_save_c_werror_flag=$ac_c_werror_flag
3403 ac_c_werror_flag=yes
3404 ac_cv_prog_cc_g=no
3405 CFLAGS="-g"
3406 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3407 /* end confdefs.h. */
3410 main ()
3414 return 0;
3416 _ACEOF
3417 if ac_fn_c_try_compile "$LINENO"; then :
3418 ac_cv_prog_cc_g=yes
3419 else
3420 CFLAGS=""
3421 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3422 /* end confdefs.h. */
3425 main ()
3429 return 0;
3431 _ACEOF
3432 if ac_fn_c_try_compile "$LINENO"; then :
3434 else
3435 ac_c_werror_flag=$ac_save_c_werror_flag
3436 CFLAGS="-g"
3437 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3438 /* end confdefs.h. */
3441 main ()
3445 return 0;
3447 _ACEOF
3448 if ac_fn_c_try_compile "$LINENO"; then :
3449 ac_cv_prog_cc_g=yes
3451 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3453 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3455 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3456 ac_c_werror_flag=$ac_save_c_werror_flag
3458 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
3459 $as_echo "$ac_cv_prog_cc_g" >&6; }
3460 if test "$ac_test_CFLAGS" = set; then
3461 CFLAGS=$ac_save_CFLAGS
3462 elif test $ac_cv_prog_cc_g = yes; then
3463 if test "$GCC" = yes; then
3464 CFLAGS="-g -O2"
3465 else
3466 CFLAGS="-g"
3468 else
3469 if test "$GCC" = yes; then
3470 CFLAGS="-O2"
3471 else
3472 CFLAGS=
3475 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
3476 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
3477 if ${ac_cv_prog_cc_c89+:} false; then :
3478 $as_echo_n "(cached) " >&6
3479 else
3480 ac_cv_prog_cc_c89=no
3481 ac_save_CC=$CC
3482 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3483 /* end confdefs.h. */
3484 #include <stdarg.h>
3485 #include <stdio.h>
3486 struct stat;
3487 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
3488 struct buf { int x; };
3489 FILE * (*rcsopen) (struct buf *, struct stat *, int);
3490 static char *e (p, i)
3491 char **p;
3492 int i;
3494 return p[i];
3496 static char *f (char * (*g) (char **, int), char **p, ...)
3498 char *s;
3499 va_list v;
3500 va_start (v,p);
3501 s = g (p, va_arg (v,int));
3502 va_end (v);
3503 return s;
3506 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
3507 function prototypes and stuff, but not '\xHH' hex character constants.
3508 These don't provoke an error unfortunately, instead are silently treated
3509 as 'x'. The following induces an error, until -std is added to get
3510 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
3511 array size at least. It's necessary to write '\x00'==0 to get something
3512 that's true only with -std. */
3513 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3515 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3516 inside strings and character constants. */
3517 #define FOO(x) 'x'
3518 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3520 int test (int i, double x);
3521 struct s1 {int (*f) (int a);};
3522 struct s2 {int (*f) (double a);};
3523 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3524 int argc;
3525 char **argv;
3527 main ()
3529 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
3531 return 0;
3533 _ACEOF
3534 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3535 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3537 CC="$ac_save_CC $ac_arg"
3538 if ac_fn_c_try_compile "$LINENO"; then :
3539 ac_cv_prog_cc_c89=$ac_arg
3541 rm -f core conftest.err conftest.$ac_objext
3542 test "x$ac_cv_prog_cc_c89" != "xno" && break
3543 done
3544 rm -f conftest.$ac_ext
3545 CC=$ac_save_CC
3548 # AC_CACHE_VAL
3549 case "x$ac_cv_prog_cc_c89" in
3551 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
3552 $as_echo "none needed" >&6; } ;;
3553 xno)
3554 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
3555 $as_echo "unsupported" >&6; } ;;
3557 CC="$CC $ac_cv_prog_cc_c89"
3558 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
3559 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
3560 esac
3561 if test "x$ac_cv_prog_cc_c89" != xno; then :
3565 ac_ext=c
3566 ac_cpp='$CPP $CPPFLAGS'
3567 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3568 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3569 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3571 ac_ext=cpp
3572 ac_cpp='$CXXCPP $CPPFLAGS'
3573 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3574 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3575 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
3576 if test -z "$CXX"; then
3577 if test -n "$CCC"; then
3578 CXX=$CCC
3579 else
3580 if test -n "$ac_tool_prefix"; then
3581 for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
3583 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3584 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3585 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3586 $as_echo_n "checking for $ac_word... " >&6; }
3587 if ${ac_cv_prog_CXX+:} false; then :
3588 $as_echo_n "(cached) " >&6
3589 else
3590 if test -n "$CXX"; then
3591 ac_cv_prog_CXX="$CXX" # Let the user override the test.
3592 else
3593 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3594 for as_dir in $PATH
3596 IFS=$as_save_IFS
3597 test -z "$as_dir" && as_dir=.
3598 for ac_exec_ext in '' $ac_executable_extensions; do
3599 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3600 ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
3601 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3602 break 2
3604 done
3605 done
3606 IFS=$as_save_IFS
3610 CXX=$ac_cv_prog_CXX
3611 if test -n "$CXX"; then
3612 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
3613 $as_echo "$CXX" >&6; }
3614 else
3615 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3616 $as_echo "no" >&6; }
3620 test -n "$CXX" && break
3621 done
3623 if test -z "$CXX"; then
3624 ac_ct_CXX=$CXX
3625 for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
3627 # Extract the first word of "$ac_prog", so it can be a program name with args.
3628 set dummy $ac_prog; ac_word=$2
3629 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3630 $as_echo_n "checking for $ac_word... " >&6; }
3631 if ${ac_cv_prog_ac_ct_CXX+:} false; then :
3632 $as_echo_n "(cached) " >&6
3633 else
3634 if test -n "$ac_ct_CXX"; then
3635 ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
3636 else
3637 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3638 for as_dir in $PATH
3640 IFS=$as_save_IFS
3641 test -z "$as_dir" && as_dir=.
3642 for ac_exec_ext in '' $ac_executable_extensions; do
3643 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3644 ac_cv_prog_ac_ct_CXX="$ac_prog"
3645 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3646 break 2
3648 done
3649 done
3650 IFS=$as_save_IFS
3654 ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
3655 if test -n "$ac_ct_CXX"; then
3656 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
3657 $as_echo "$ac_ct_CXX" >&6; }
3658 else
3659 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3660 $as_echo "no" >&6; }
3664 test -n "$ac_ct_CXX" && break
3665 done
3667 if test "x$ac_ct_CXX" = x; then
3668 CXX="g++"
3669 else
3670 case $cross_compiling:$ac_tool_warned in
3671 yes:)
3672 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3673 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3674 ac_tool_warned=yes ;;
3675 esac
3676 CXX=$ac_ct_CXX
3682 # Provide some information about the compiler.
3683 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
3684 set X $ac_compile
3685 ac_compiler=$2
3686 for ac_option in --version -v -V -qversion; do
3687 { { ac_try="$ac_compiler $ac_option >&5"
3688 case "(($ac_try" in
3689 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3690 *) ac_try_echo=$ac_try;;
3691 esac
3692 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3693 $as_echo "$ac_try_echo"; } >&5
3694 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3695 ac_status=$?
3696 if test -s conftest.err; then
3697 sed '10a\
3698 ... rest of stderr output deleted ...
3699 10q' conftest.err >conftest.er1
3700 cat conftest.er1 >&5
3702 rm -f conftest.er1 conftest.err
3703 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3704 test $ac_status = 0; }
3705 done
3707 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5
3708 $as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; }
3709 if ${ac_cv_cxx_compiler_gnu+:} false; then :
3710 $as_echo_n "(cached) " >&6
3711 else
3712 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3713 /* end confdefs.h. */
3716 main ()
3718 #ifndef __GNUC__
3719 choke me
3720 #endif
3723 return 0;
3725 _ACEOF
3726 if ac_fn_cxx_try_compile "$LINENO"; then :
3727 ac_compiler_gnu=yes
3728 else
3729 ac_compiler_gnu=no
3731 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3732 ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
3735 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
3736 $as_echo "$ac_cv_cxx_compiler_gnu" >&6; }
3737 if test $ac_compiler_gnu = yes; then
3738 GXX=yes
3739 else
3740 GXX=
3742 ac_test_CXXFLAGS=${CXXFLAGS+set}
3743 ac_save_CXXFLAGS=$CXXFLAGS
3744 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
3745 $as_echo_n "checking whether $CXX accepts -g... " >&6; }
3746 if ${ac_cv_prog_cxx_g+:} false; then :
3747 $as_echo_n "(cached) " >&6
3748 else
3749 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
3750 ac_cxx_werror_flag=yes
3751 ac_cv_prog_cxx_g=no
3752 CXXFLAGS="-g"
3753 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3754 /* end confdefs.h. */
3757 main ()
3761 return 0;
3763 _ACEOF
3764 if ac_fn_cxx_try_compile "$LINENO"; then :
3765 ac_cv_prog_cxx_g=yes
3766 else
3767 CXXFLAGS=""
3768 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3769 /* end confdefs.h. */
3772 main ()
3776 return 0;
3778 _ACEOF
3779 if ac_fn_cxx_try_compile "$LINENO"; then :
3781 else
3782 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
3783 CXXFLAGS="-g"
3784 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3785 /* end confdefs.h. */
3788 main ()
3792 return 0;
3794 _ACEOF
3795 if ac_fn_cxx_try_compile "$LINENO"; then :
3796 ac_cv_prog_cxx_g=yes
3798 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3800 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3802 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3803 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
3805 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
3806 $as_echo "$ac_cv_prog_cxx_g" >&6; }
3807 if test "$ac_test_CXXFLAGS" = set; then
3808 CXXFLAGS=$ac_save_CXXFLAGS
3809 elif test $ac_cv_prog_cxx_g = yes; then
3810 if test "$GXX" = yes; then
3811 CXXFLAGS="-g -O2"
3812 else
3813 CXXFLAGS="-g"
3815 else
3816 if test "$GXX" = yes; then
3817 CXXFLAGS="-O2"
3818 else
3819 CXXFLAGS=
3822 ac_ext=c
3823 ac_cpp='$CPP $CPPFLAGS'
3824 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3825 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3826 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3829 ac_ext=c
3830 ac_cpp='$CPP $CPPFLAGS'
3831 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3832 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3833 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3834 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
3835 $as_echo_n "checking how to run the C preprocessor... " >&6; }
3836 # On Suns, sometimes $CPP names a directory.
3837 if test -n "$CPP" && test -d "$CPP"; then
3838 CPP=
3840 if test -z "$CPP"; then
3841 if ${ac_cv_prog_CPP+:} false; then :
3842 $as_echo_n "(cached) " >&6
3843 else
3844 # Double quotes because CPP needs to be expanded
3845 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3847 ac_preproc_ok=false
3848 for ac_c_preproc_warn_flag in '' yes
3850 # Use a header file that comes with gcc, so configuring glibc
3851 # with a fresh cross-compiler works.
3852 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3853 # <limits.h> exists even on freestanding compilers.
3854 # On the NeXT, cc -E runs the code through the compiler's parser,
3855 # not just through cpp. "Syntax error" is here to catch this case.
3856 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3857 /* end confdefs.h. */
3858 #ifdef __STDC__
3859 # include <limits.h>
3860 #else
3861 # include <assert.h>
3862 #endif
3863 Syntax error
3864 _ACEOF
3865 if ac_fn_c_try_cpp "$LINENO"; then :
3867 else
3868 # Broken: fails on valid input.
3869 continue
3871 rm -f conftest.err conftest.i conftest.$ac_ext
3873 # OK, works on sane cases. Now check whether nonexistent headers
3874 # can be detected and how.
3875 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3876 /* end confdefs.h. */
3877 #include <ac_nonexistent.h>
3878 _ACEOF
3879 if ac_fn_c_try_cpp "$LINENO"; then :
3880 # Broken: success on invalid input.
3881 continue
3882 else
3883 # Passes both tests.
3884 ac_preproc_ok=:
3885 break
3887 rm -f conftest.err conftest.i conftest.$ac_ext
3889 done
3890 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3891 rm -f conftest.i conftest.err conftest.$ac_ext
3892 if $ac_preproc_ok; then :
3893 break
3896 done
3897 ac_cv_prog_CPP=$CPP
3900 CPP=$ac_cv_prog_CPP
3901 else
3902 ac_cv_prog_CPP=$CPP
3904 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
3905 $as_echo "$CPP" >&6; }
3906 ac_preproc_ok=false
3907 for ac_c_preproc_warn_flag in '' yes
3909 # Use a header file that comes with gcc, so configuring glibc
3910 # with a fresh cross-compiler works.
3911 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3912 # <limits.h> exists even on freestanding compilers.
3913 # On the NeXT, cc -E runs the code through the compiler's parser,
3914 # not just through cpp. "Syntax error" is here to catch this case.
3915 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3916 /* end confdefs.h. */
3917 #ifdef __STDC__
3918 # include <limits.h>
3919 #else
3920 # include <assert.h>
3921 #endif
3922 Syntax error
3923 _ACEOF
3924 if ac_fn_c_try_cpp "$LINENO"; then :
3926 else
3927 # Broken: fails on valid input.
3928 continue
3930 rm -f conftest.err conftest.i conftest.$ac_ext
3932 # OK, works on sane cases. Now check whether nonexistent headers
3933 # can be detected and how.
3934 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3935 /* end confdefs.h. */
3936 #include <ac_nonexistent.h>
3937 _ACEOF
3938 if ac_fn_c_try_cpp "$LINENO"; then :
3939 # Broken: success on invalid input.
3940 continue
3941 else
3942 # Passes both tests.
3943 ac_preproc_ok=:
3944 break
3946 rm -f conftest.err conftest.i conftest.$ac_ext
3948 done
3949 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3950 rm -f conftest.i conftest.err conftest.$ac_ext
3951 if $ac_preproc_ok; then :
3953 else
3954 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3955 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3956 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
3957 See \`config.log' for more details" "$LINENO" 5; }
3960 ac_ext=c
3961 ac_cpp='$CPP $CPPFLAGS'
3962 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3963 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3964 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3967 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
3968 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
3969 if ${ac_cv_path_GREP+:} false; then :
3970 $as_echo_n "(cached) " >&6
3971 else
3972 if test -z "$GREP"; then
3973 ac_path_GREP_found=false
3974 # Loop through the user's path and test for each of PROGNAME-LIST
3975 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3976 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
3978 IFS=$as_save_IFS
3979 test -z "$as_dir" && as_dir=.
3980 for ac_prog in grep ggrep; do
3981 for ac_exec_ext in '' $ac_executable_extensions; do
3982 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
3983 as_fn_executable_p "$ac_path_GREP" || continue
3984 # Check for GNU ac_path_GREP and select it if it is found.
3985 # Check for GNU $ac_path_GREP
3986 case `"$ac_path_GREP" --version 2>&1` in
3987 *GNU*)
3988 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
3990 ac_count=0
3991 $as_echo_n 0123456789 >"conftest.in"
3992 while :
3994 cat "conftest.in" "conftest.in" >"conftest.tmp"
3995 mv "conftest.tmp" "conftest.in"
3996 cp "conftest.in" "conftest.nl"
3997 $as_echo 'GREP' >> "conftest.nl"
3998 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
3999 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4000 as_fn_arith $ac_count + 1 && ac_count=$as_val
4001 if test $ac_count -gt ${ac_path_GREP_max-0}; then
4002 # Best one so far, save it but keep looking for a better one
4003 ac_cv_path_GREP="$ac_path_GREP"
4004 ac_path_GREP_max=$ac_count
4006 # 10*(2^10) chars as input seems more than enough
4007 test $ac_count -gt 10 && break
4008 done
4009 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4010 esac
4012 $ac_path_GREP_found && break 3
4013 done
4014 done
4015 done
4016 IFS=$as_save_IFS
4017 if test -z "$ac_cv_path_GREP"; then
4018 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4020 else
4021 ac_cv_path_GREP=$GREP
4025 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
4026 $as_echo "$ac_cv_path_GREP" >&6; }
4027 GREP="$ac_cv_path_GREP"
4030 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
4031 $as_echo_n "checking for egrep... " >&6; }
4032 if ${ac_cv_path_EGREP+:} false; then :
4033 $as_echo_n "(cached) " >&6
4034 else
4035 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
4036 then ac_cv_path_EGREP="$GREP -E"
4037 else
4038 if test -z "$EGREP"; then
4039 ac_path_EGREP_found=false
4040 # Loop through the user's path and test for each of PROGNAME-LIST
4041 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4042 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4044 IFS=$as_save_IFS
4045 test -z "$as_dir" && as_dir=.
4046 for ac_prog in egrep; do
4047 for ac_exec_ext in '' $ac_executable_extensions; do
4048 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
4049 as_fn_executable_p "$ac_path_EGREP" || continue
4050 # Check for GNU ac_path_EGREP and select it if it is found.
4051 # Check for GNU $ac_path_EGREP
4052 case `"$ac_path_EGREP" --version 2>&1` in
4053 *GNU*)
4054 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
4056 ac_count=0
4057 $as_echo_n 0123456789 >"conftest.in"
4058 while :
4060 cat "conftest.in" "conftest.in" >"conftest.tmp"
4061 mv "conftest.tmp" "conftest.in"
4062 cp "conftest.in" "conftest.nl"
4063 $as_echo 'EGREP' >> "conftest.nl"
4064 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4065 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4066 as_fn_arith $ac_count + 1 && ac_count=$as_val
4067 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
4068 # Best one so far, save it but keep looking for a better one
4069 ac_cv_path_EGREP="$ac_path_EGREP"
4070 ac_path_EGREP_max=$ac_count
4072 # 10*(2^10) chars as input seems more than enough
4073 test $ac_count -gt 10 && break
4074 done
4075 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4076 esac
4078 $ac_path_EGREP_found && break 3
4079 done
4080 done
4081 done
4082 IFS=$as_save_IFS
4083 if test -z "$ac_cv_path_EGREP"; then
4084 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4086 else
4087 ac_cv_path_EGREP=$EGREP
4092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
4093 $as_echo "$ac_cv_path_EGREP" >&6; }
4094 EGREP="$ac_cv_path_EGREP"
4097 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
4098 $as_echo_n "checking for ANSI C header files... " >&6; }
4099 if ${ac_cv_header_stdc+:} false; then :
4100 $as_echo_n "(cached) " >&6
4101 else
4102 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4103 /* end confdefs.h. */
4104 #include <stdlib.h>
4105 #include <stdarg.h>
4106 #include <string.h>
4107 #include <float.h>
4110 main ()
4114 return 0;
4116 _ACEOF
4117 if ac_fn_c_try_compile "$LINENO"; then :
4118 ac_cv_header_stdc=yes
4119 else
4120 ac_cv_header_stdc=no
4122 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4124 if test $ac_cv_header_stdc = yes; then
4125 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
4126 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4127 /* end confdefs.h. */
4128 #include <string.h>
4130 _ACEOF
4131 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4132 $EGREP "memchr" >/dev/null 2>&1; then :
4134 else
4135 ac_cv_header_stdc=no
4137 rm -f conftest*
4141 if test $ac_cv_header_stdc = yes; then
4142 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
4143 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4144 /* end confdefs.h. */
4145 #include <stdlib.h>
4147 _ACEOF
4148 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4149 $EGREP "free" >/dev/null 2>&1; then :
4151 else
4152 ac_cv_header_stdc=no
4154 rm -f conftest*
4158 if test $ac_cv_header_stdc = yes; then
4159 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
4160 if test "$cross_compiling" = yes; then :
4162 else
4163 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4164 /* end confdefs.h. */
4165 #include <ctype.h>
4166 #include <stdlib.h>
4167 #if ((' ' & 0x0FF) == 0x020)
4168 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4169 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4170 #else
4171 # define ISLOWER(c) \
4172 (('a' <= (c) && (c) <= 'i') \
4173 || ('j' <= (c) && (c) <= 'r') \
4174 || ('s' <= (c) && (c) <= 'z'))
4175 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4176 #endif
4178 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4180 main ()
4182 int i;
4183 for (i = 0; i < 256; i++)
4184 if (XOR (islower (i), ISLOWER (i))
4185 || toupper (i) != TOUPPER (i))
4186 return 2;
4187 return 0;
4189 _ACEOF
4190 if ac_fn_c_try_run "$LINENO"; then :
4192 else
4193 ac_cv_header_stdc=no
4195 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
4196 conftest.$ac_objext conftest.beam conftest.$ac_ext
4201 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
4202 $as_echo "$ac_cv_header_stdc" >&6; }
4203 if test $ac_cv_header_stdc = yes; then
4205 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
4209 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
4210 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
4211 inttypes.h stdint.h unistd.h
4212 do :
4213 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
4214 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
4216 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
4217 cat >>confdefs.h <<_ACEOF
4218 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
4219 _ACEOF
4223 done
4227 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
4228 if test "x$ac_cv_header_minix_config_h" = xyes; then :
4229 MINIX=yes
4230 else
4231 MINIX=
4235 if test "$MINIX" = yes; then
4237 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
4240 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
4243 $as_echo "#define _MINIX 1" >>confdefs.h
4248 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
4249 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
4250 if ${ac_cv_safe_to_define___extensions__+:} false; then :
4251 $as_echo_n "(cached) " >&6
4252 else
4253 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4254 /* end confdefs.h. */
4256 # define __EXTENSIONS__ 1
4257 $ac_includes_default
4259 main ()
4263 return 0;
4265 _ACEOF
4266 if ac_fn_c_try_compile "$LINENO"; then :
4267 ac_cv_safe_to_define___extensions__=yes
4268 else
4269 ac_cv_safe_to_define___extensions__=no
4271 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
4274 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
4275 test $ac_cv_safe_to_define___extensions__ = yes &&
4276 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
4278 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
4280 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
4282 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
4284 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
4287 # Check whether --enable-largefile was given.
4288 if test "${enable_largefile+set}" = set; then :
4289 enableval=$enable_largefile;
4292 if test "$enable_largefile" != no; then
4294 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
4295 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
4296 if ${ac_cv_sys_largefile_CC+:} false; then :
4297 $as_echo_n "(cached) " >&6
4298 else
4299 ac_cv_sys_largefile_CC=no
4300 if test "$GCC" != yes; then
4301 ac_save_CC=$CC
4302 while :; do
4303 # IRIX 6.2 and later do not support large files by default,
4304 # so use the C compiler's -n32 option if that helps.
4305 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4306 /* end confdefs.h. */
4307 #include <sys/types.h>
4308 /* Check that off_t can represent 2**63 - 1 correctly.
4309 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4310 since some C++ compilers masquerading as C compilers
4311 incorrectly reject 9223372036854775807. */
4312 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4313 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4314 && LARGE_OFF_T % 2147483647 == 1)
4315 ? 1 : -1];
4317 main ()
4321 return 0;
4323 _ACEOF
4324 if ac_fn_c_try_compile "$LINENO"; then :
4325 break
4327 rm -f core conftest.err conftest.$ac_objext
4328 CC="$CC -n32"
4329 if ac_fn_c_try_compile "$LINENO"; then :
4330 ac_cv_sys_largefile_CC=' -n32'; break
4332 rm -f core conftest.err conftest.$ac_objext
4333 break
4334 done
4335 CC=$ac_save_CC
4336 rm -f conftest.$ac_ext
4339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
4340 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
4341 if test "$ac_cv_sys_largefile_CC" != no; then
4342 CC=$CC$ac_cv_sys_largefile_CC
4345 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
4346 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
4347 if ${ac_cv_sys_file_offset_bits+:} false; then :
4348 $as_echo_n "(cached) " >&6
4349 else
4350 while :; do
4351 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4352 /* end confdefs.h. */
4353 #include <sys/types.h>
4354 /* Check that off_t can represent 2**63 - 1 correctly.
4355 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4356 since some C++ compilers masquerading as C compilers
4357 incorrectly reject 9223372036854775807. */
4358 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4359 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4360 && LARGE_OFF_T % 2147483647 == 1)
4361 ? 1 : -1];
4363 main ()
4367 return 0;
4369 _ACEOF
4370 if ac_fn_c_try_compile "$LINENO"; then :
4371 ac_cv_sys_file_offset_bits=no; break
4373 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4374 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4375 /* end confdefs.h. */
4376 #define _FILE_OFFSET_BITS 64
4377 #include <sys/types.h>
4378 /* Check that off_t can represent 2**63 - 1 correctly.
4379 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4380 since some C++ compilers masquerading as C compilers
4381 incorrectly reject 9223372036854775807. */
4382 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4383 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4384 && LARGE_OFF_T % 2147483647 == 1)
4385 ? 1 : -1];
4387 main ()
4391 return 0;
4393 _ACEOF
4394 if ac_fn_c_try_compile "$LINENO"; then :
4395 ac_cv_sys_file_offset_bits=64; break
4397 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4398 ac_cv_sys_file_offset_bits=unknown
4399 break
4400 done
4402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
4403 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
4404 case $ac_cv_sys_file_offset_bits in #(
4405 no | unknown) ;;
4407 cat >>confdefs.h <<_ACEOF
4408 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
4409 _ACEOF
4411 esac
4412 rm -rf conftest*
4413 if test $ac_cv_sys_file_offset_bits = unknown; then
4414 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
4415 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
4416 if ${ac_cv_sys_large_files+:} false; then :
4417 $as_echo_n "(cached) " >&6
4418 else
4419 while :; do
4420 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4421 /* end confdefs.h. */
4422 #include <sys/types.h>
4423 /* Check that off_t can represent 2**63 - 1 correctly.
4424 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4425 since some C++ compilers masquerading as C compilers
4426 incorrectly reject 9223372036854775807. */
4427 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4428 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4429 && LARGE_OFF_T % 2147483647 == 1)
4430 ? 1 : -1];
4432 main ()
4436 return 0;
4438 _ACEOF
4439 if ac_fn_c_try_compile "$LINENO"; then :
4440 ac_cv_sys_large_files=no; break
4442 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4443 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4444 /* end confdefs.h. */
4445 #define _LARGE_FILES 1
4446 #include <sys/types.h>
4447 /* Check that off_t can represent 2**63 - 1 correctly.
4448 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4449 since some C++ compilers masquerading as C compilers
4450 incorrectly reject 9223372036854775807. */
4451 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4452 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4453 && LARGE_OFF_T % 2147483647 == 1)
4454 ? 1 : -1];
4456 main ()
4460 return 0;
4462 _ACEOF
4463 if ac_fn_c_try_compile "$LINENO"; then :
4464 ac_cv_sys_large_files=1; break
4466 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4467 ac_cv_sys_large_files=unknown
4468 break
4469 done
4471 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
4472 $as_echo "$ac_cv_sys_large_files" >&6; }
4473 case $ac_cv_sys_large_files in #(
4474 no | unknown) ;;
4476 cat >>confdefs.h <<_ACEOF
4477 #define _LARGE_FILES $ac_cv_sys_large_files
4478 _ACEOF
4480 esac
4481 rm -rf conftest*
4487 ac_aux_dir=
4488 for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
4489 if test -f "$ac_dir/install-sh"; then
4490 ac_aux_dir=$ac_dir
4491 ac_install_sh="$ac_aux_dir/install-sh -c"
4492 break
4493 elif test -f "$ac_dir/install.sh"; then
4494 ac_aux_dir=$ac_dir
4495 ac_install_sh="$ac_aux_dir/install.sh -c"
4496 break
4497 elif test -f "$ac_dir/shtool"; then
4498 ac_aux_dir=$ac_dir
4499 ac_install_sh="$ac_aux_dir/shtool install -c"
4500 break
4502 done
4503 if test -z "$ac_aux_dir"; then
4504 as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
4507 # These three variables are undocumented and unsupported,
4508 # and are intended to be withdrawn in a future Autoconf release.
4509 # They can cause serious problems if a builder's source tree is in a directory
4510 # whose full name contains unusual characters.
4511 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
4512 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
4513 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
4516 # Expand $ac_aux_dir to an absolute path.
4517 am_aux_dir=`cd "$ac_aux_dir" && pwd`
4519 if test x"${install_sh+set}" != xset; then
4520 case $am_aux_dir in
4521 *\ * | *\ *)
4522 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
4524 install_sh="\${SHELL} $am_aux_dir/install-sh"
4525 esac
4528 # Installed binaries are usually stripped using 'strip' when the user
4529 # run "make install-strip". However 'strip' might not be the right
4530 # tool to use in cross-compilation environments, therefore Automake
4531 # will honor the 'STRIP' environment variable to overrule this program.
4532 if test "$cross_compiling" != no; then
4533 if test -n "$ac_tool_prefix"; then
4534 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
4535 set dummy ${ac_tool_prefix}strip; ac_word=$2
4536 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4537 $as_echo_n "checking for $ac_word... " >&6; }
4538 if ${ac_cv_prog_STRIP+:} false; then :
4539 $as_echo_n "(cached) " >&6
4540 else
4541 if test -n "$STRIP"; then
4542 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
4543 else
4544 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4545 for as_dir in $PATH
4547 IFS=$as_save_IFS
4548 test -z "$as_dir" && as_dir=.
4549 for ac_exec_ext in '' $ac_executable_extensions; do
4550 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4551 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
4552 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4553 break 2
4555 done
4556 done
4557 IFS=$as_save_IFS
4561 STRIP=$ac_cv_prog_STRIP
4562 if test -n "$STRIP"; then
4563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
4564 $as_echo "$STRIP" >&6; }
4565 else
4566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4567 $as_echo "no" >&6; }
4572 if test -z "$ac_cv_prog_STRIP"; then
4573 ac_ct_STRIP=$STRIP
4574 # Extract the first word of "strip", so it can be a program name with args.
4575 set dummy strip; ac_word=$2
4576 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4577 $as_echo_n "checking for $ac_word... " >&6; }
4578 if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
4579 $as_echo_n "(cached) " >&6
4580 else
4581 if test -n "$ac_ct_STRIP"; then
4582 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
4583 else
4584 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4585 for as_dir in $PATH
4587 IFS=$as_save_IFS
4588 test -z "$as_dir" && as_dir=.
4589 for ac_exec_ext in '' $ac_executable_extensions; do
4590 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4591 ac_cv_prog_ac_ct_STRIP="strip"
4592 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4593 break 2
4595 done
4596 done
4597 IFS=$as_save_IFS
4601 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
4602 if test -n "$ac_ct_STRIP"; then
4603 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
4604 $as_echo "$ac_ct_STRIP" >&6; }
4605 else
4606 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4607 $as_echo "no" >&6; }
4610 if test "x$ac_ct_STRIP" = x; then
4611 STRIP=":"
4612 else
4613 case $cross_compiling:$ac_tool_warned in
4614 yes:)
4615 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4616 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4617 ac_tool_warned=yes ;;
4618 esac
4619 STRIP=$ac_ct_STRIP
4621 else
4622 STRIP="$ac_cv_prog_STRIP"
4626 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
4629 # Set build, build_cpu, build_vendor and build_os.
4630 # Make sure we can run config.sub.
4631 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
4632 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
4634 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
4635 $as_echo_n "checking build system type... " >&6; }
4636 if ${ac_cv_build+:} false; then :
4637 $as_echo_n "(cached) " >&6
4638 else
4639 ac_build_alias=$build_alias
4640 test "x$ac_build_alias" = x &&
4641 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
4642 test "x$ac_build_alias" = x &&
4643 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
4644 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
4645 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
4648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
4649 $as_echo "$ac_cv_build" >&6; }
4650 case $ac_cv_build in
4651 *-*-*) ;;
4652 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
4653 esac
4654 build=$ac_cv_build
4655 ac_save_IFS=$IFS; IFS='-'
4656 set x $ac_cv_build
4657 shift
4658 build_cpu=$1
4659 build_vendor=$2
4660 shift; shift
4661 # Remember, the first character of IFS is used to create $*,
4662 # except with old shells:
4663 build_os=$*
4664 IFS=$ac_save_IFS
4665 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
4669 # Set host, host_cpu, host_vendor, and host_os.
4670 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
4671 $as_echo_n "checking host system type... " >&6; }
4672 if ${ac_cv_host+:} false; then :
4673 $as_echo_n "(cached) " >&6
4674 else
4675 if test "x$host_alias" = x; then
4676 ac_cv_host=$ac_cv_build
4677 else
4678 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
4679 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
4683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
4684 $as_echo "$ac_cv_host" >&6; }
4685 case $ac_cv_host in
4686 *-*-*) ;;
4687 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
4688 esac
4689 host=$ac_cv_host
4690 ac_save_IFS=$IFS; IFS='-'
4691 set x $ac_cv_host
4692 shift
4693 host_cpu=$1
4694 host_vendor=$2
4695 shift; shift
4696 # Remember, the first character of IFS is used to create $*,
4697 # except with old shells:
4698 host_os=$*
4699 IFS=$ac_save_IFS
4700 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
4704 # Set target, target_cpu, target_vendor, and target_os.
4705 { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
4706 $as_echo_n "checking target system type... " >&6; }
4707 if ${ac_cv_target+:} false; then :
4708 $as_echo_n "(cached) " >&6
4709 else
4710 if test "x$target_alias" = x; then
4711 ac_cv_target=$ac_cv_host
4712 else
4713 ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
4714 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
4718 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
4719 $as_echo "$ac_cv_target" >&6; }
4720 case $ac_cv_target in
4721 *-*-*) ;;
4722 *) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;;
4723 esac
4724 target=$ac_cv_target
4725 ac_save_IFS=$IFS; IFS='-'
4726 set x $ac_cv_target
4727 shift
4728 target_cpu=$1
4729 target_vendor=$2
4730 shift; shift
4731 # Remember, the first character of IFS is used to create $*,
4732 # except with old shells:
4733 target_os=$*
4734 IFS=$ac_save_IFS
4735 case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
4738 # The aliases save the names the user supplied, while $host etc.
4739 # will get canonicalized.
4740 test -n "$target_alias" &&
4741 test "$program_prefix$program_suffix$program_transform_name" = \
4742 NONENONEs,x,x, &&
4743 program_prefix=${target_alias}-
4745 # Find a good install program. We prefer a C program (faster),
4746 # so one script is as good as another. But avoid the broken or
4747 # incompatible versions:
4748 # SysV /etc/install, /usr/sbin/install
4749 # SunOS /usr/etc/install
4750 # IRIX /sbin/install
4751 # AIX /bin/install
4752 # AmigaOS /C/install, which installs bootblocks on floppy discs
4753 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
4754 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
4755 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
4756 # OS/2's system install, which has a completely different semantic
4757 # ./install, which can be erroneously created by make from ./install.sh.
4758 # Reject install programs that cannot install multiple files.
4759 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
4760 $as_echo_n "checking for a BSD-compatible install... " >&6; }
4761 if test -z "$INSTALL"; then
4762 if ${ac_cv_path_install+:} false; then :
4763 $as_echo_n "(cached) " >&6
4764 else
4765 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4766 for as_dir in $PATH
4768 IFS=$as_save_IFS
4769 test -z "$as_dir" && as_dir=.
4770 # Account for people who put trailing slashes in PATH elements.
4771 case $as_dir/ in #((
4772 ./ | .// | /[cC]/* | \
4773 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
4774 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
4775 /usr/ucb/* ) ;;
4777 # OSF1 and SCO ODT 3.0 have their own names for install.
4778 # Don't use installbsd from OSF since it installs stuff as root
4779 # by default.
4780 for ac_prog in ginstall scoinst install; do
4781 for ac_exec_ext in '' $ac_executable_extensions; do
4782 if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
4783 if test $ac_prog = install &&
4784 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
4785 # AIX install. It has an incompatible calling convention.
4787 elif test $ac_prog = install &&
4788 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
4789 # program-specific install script used by HP pwplus--don't use.
4791 else
4792 rm -rf conftest.one conftest.two conftest.dir
4793 echo one > conftest.one
4794 echo two > conftest.two
4795 mkdir conftest.dir
4796 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
4797 test -s conftest.one && test -s conftest.two &&
4798 test -s conftest.dir/conftest.one &&
4799 test -s conftest.dir/conftest.two
4800 then
4801 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
4802 break 3
4806 done
4807 done
4809 esac
4811 done
4812 IFS=$as_save_IFS
4814 rm -rf conftest.one conftest.two conftest.dir
4817 if test "${ac_cv_path_install+set}" = set; then
4818 INSTALL=$ac_cv_path_install
4819 else
4820 # As a last resort, use the slow shell script. Don't cache a
4821 # value for INSTALL within a source directory, because that will
4822 # break other packages using the cache if that directory is
4823 # removed, or if the value is a relative name.
4824 INSTALL=$ac_install_sh
4827 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
4828 $as_echo "$INSTALL" >&6; }
4830 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
4831 # It thinks the first close brace ends the variable substitution.
4832 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
4834 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
4836 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
4838 if test -n "$ac_tool_prefix"; then
4839 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
4840 set dummy ${ac_tool_prefix}ar; ac_word=$2
4841 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4842 $as_echo_n "checking for $ac_word... " >&6; }
4843 if ${ac_cv_prog_AR+:} false; then :
4844 $as_echo_n "(cached) " >&6
4845 else
4846 if test -n "$AR"; then
4847 ac_cv_prog_AR="$AR" # Let the user override the test.
4848 else
4849 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4850 for as_dir in $PATH
4852 IFS=$as_save_IFS
4853 test -z "$as_dir" && as_dir=.
4854 for ac_exec_ext in '' $ac_executable_extensions; do
4855 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4856 ac_cv_prog_AR="${ac_tool_prefix}ar"
4857 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4858 break 2
4860 done
4861 done
4862 IFS=$as_save_IFS
4866 AR=$ac_cv_prog_AR
4867 if test -n "$AR"; then
4868 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
4869 $as_echo "$AR" >&6; }
4870 else
4871 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4872 $as_echo "no" >&6; }
4877 if test -z "$ac_cv_prog_AR"; then
4878 ac_ct_AR=$AR
4879 # Extract the first word of "ar", so it can be a program name with args.
4880 set dummy ar; ac_word=$2
4881 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4882 $as_echo_n "checking for $ac_word... " >&6; }
4883 if ${ac_cv_prog_ac_ct_AR+:} false; then :
4884 $as_echo_n "(cached) " >&6
4885 else
4886 if test -n "$ac_ct_AR"; then
4887 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
4888 else
4889 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4890 for as_dir in $PATH
4892 IFS=$as_save_IFS
4893 test -z "$as_dir" && as_dir=.
4894 for ac_exec_ext in '' $ac_executable_extensions; do
4895 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4896 ac_cv_prog_ac_ct_AR="ar"
4897 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4898 break 2
4900 done
4901 done
4902 IFS=$as_save_IFS
4906 ac_ct_AR=$ac_cv_prog_ac_ct_AR
4907 if test -n "$ac_ct_AR"; then
4908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
4909 $as_echo "$ac_ct_AR" >&6; }
4910 else
4911 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4912 $as_echo "no" >&6; }
4915 if test "x$ac_ct_AR" = x; then
4916 AR=""
4917 else
4918 case $cross_compiling:$ac_tool_warned in
4919 yes:)
4920 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4921 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4922 ac_tool_warned=yes ;;
4923 esac
4924 AR=$ac_ct_AR
4926 else
4927 AR="$ac_cv_prog_AR"
4930 if test -n "$ac_tool_prefix"; then
4931 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
4932 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
4933 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4934 $as_echo_n "checking for $ac_word... " >&6; }
4935 if ${ac_cv_prog_RANLIB+:} false; then :
4936 $as_echo_n "(cached) " >&6
4937 else
4938 if test -n "$RANLIB"; then
4939 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
4940 else
4941 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4942 for as_dir in $PATH
4944 IFS=$as_save_IFS
4945 test -z "$as_dir" && as_dir=.
4946 for ac_exec_ext in '' $ac_executable_extensions; do
4947 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4948 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
4949 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4950 break 2
4952 done
4953 done
4954 IFS=$as_save_IFS
4958 RANLIB=$ac_cv_prog_RANLIB
4959 if test -n "$RANLIB"; then
4960 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
4961 $as_echo "$RANLIB" >&6; }
4962 else
4963 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4964 $as_echo "no" >&6; }
4969 if test -z "$ac_cv_prog_RANLIB"; then
4970 ac_ct_RANLIB=$RANLIB
4971 # Extract the first word of "ranlib", so it can be a program name with args.
4972 set dummy ranlib; ac_word=$2
4973 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4974 $as_echo_n "checking for $ac_word... " >&6; }
4975 if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
4976 $as_echo_n "(cached) " >&6
4977 else
4978 if test -n "$ac_ct_RANLIB"; then
4979 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
4980 else
4981 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4982 for as_dir in $PATH
4984 IFS=$as_save_IFS
4985 test -z "$as_dir" && as_dir=.
4986 for ac_exec_ext in '' $ac_executable_extensions; do
4987 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4988 ac_cv_prog_ac_ct_RANLIB="ranlib"
4989 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4990 break 2
4992 done
4993 done
4994 IFS=$as_save_IFS
4998 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
4999 if test -n "$ac_ct_RANLIB"; then
5000 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
5001 $as_echo "$ac_ct_RANLIB" >&6; }
5002 else
5003 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5004 $as_echo "no" >&6; }
5007 if test "x$ac_ct_RANLIB" = x; then
5008 RANLIB=":"
5009 else
5010 case $cross_compiling:$ac_tool_warned in
5011 yes:)
5012 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5013 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5014 ac_tool_warned=yes ;;
5015 esac
5016 RANLIB=$ac_ct_RANLIB
5018 else
5019 RANLIB="$ac_cv_prog_RANLIB"
5023 test "$program_prefix" != NONE &&
5024 program_transform_name="s&^&$program_prefix&;$program_transform_name"
5025 # Use a double $ so make ignores it.
5026 test "$program_suffix" != NONE &&
5027 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
5028 # Double any \ or $.
5029 # By default was `s,x,x', remove it if useless.
5030 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
5031 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
5034 # We require a C++17 compiler. Check if one is available, and if
5035 # necessary, set CXX_DIALECT to some -std=xxx switch.
5037 ax_cxx_compile_alternatives="17 1z" ax_cxx_compile_cxx17_required=true
5038 ac_ext=cpp
5039 ac_cpp='$CXXCPP $CPPFLAGS'
5040 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5041 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5042 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5043 CXX_DIALECT=""
5044 ac_success=no
5046 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++17 features by default" >&5
5047 $as_echo_n "checking whether $CXX supports C++17 features by default... " >&6; }
5048 if ${ax_cv_cxx_compile_cxx17+:} false; then :
5049 $as_echo_n "(cached) " >&6
5050 else
5051 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5052 /* end confdefs.h. */
5055 // If the compiler admits that it is not ready for C++11, why torture it?
5056 // Hopefully, this will speed up the test.
5058 #ifndef __cplusplus
5060 #error "This is not a C++ compiler"
5062 // MSVC always sets __cplusplus to 199711L in older versions; newer versions
5063 // only set it correctly if /Zc:__cplusplus is specified as well as a
5064 // /std:c++NN switch:
5065 // https://devblogs.microsoft.com/cppblog/msvc-now-correctly-reports-__cplusplus/
5066 #elif __cplusplus < 201103L && !defined _MSC_VER
5068 #error "This is not a C++11 compiler"
5070 #else
5072 namespace cxx11
5075 namespace test_static_assert
5078 template <typename T>
5079 struct check
5081 static_assert(sizeof(int) <= sizeof(T), "not big enough");
5086 namespace test_final_override
5089 struct Base
5091 virtual ~Base() {}
5092 virtual void f() {}
5095 struct Derived : public Base
5097 virtual ~Derived() override {}
5098 virtual void f() override {}
5103 namespace test_double_right_angle_brackets
5106 template < typename T >
5107 struct check {};
5109 typedef check<void> single_type;
5110 typedef check<check<void>> double_type;
5111 typedef check<check<check<void>>> triple_type;
5112 typedef check<check<check<check<void>>>> quadruple_type;
5116 namespace test_decltype
5122 int a = 1;
5123 decltype(a) b = 2;
5124 return a + b;
5129 namespace test_type_deduction
5132 template < typename T1, typename T2 >
5133 struct is_same
5135 static const bool value = false;
5138 template < typename T >
5139 struct is_same<T, T>
5141 static const bool value = true;
5144 template < typename T1, typename T2 >
5145 auto
5146 add(T1 a1, T2 a2) -> decltype(a1 + a2)
5148 return a1 + a2;
5152 test(const int c, volatile int v)
5154 static_assert(is_same<int, decltype(0)>::value == true, "");
5155 static_assert(is_same<int, decltype(c)>::value == false, "");
5156 static_assert(is_same<int, decltype(v)>::value == false, "");
5157 auto ac = c;
5158 auto av = v;
5159 auto sumi = ac + av + 'x';
5160 auto sumf = ac + av + 1.0;
5161 static_assert(is_same<int, decltype(ac)>::value == true, "");
5162 static_assert(is_same<int, decltype(av)>::value == true, "");
5163 static_assert(is_same<int, decltype(sumi)>::value == true, "");
5164 static_assert(is_same<int, decltype(sumf)>::value == false, "");
5165 static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
5166 return (sumf > 0.0) ? sumi : add(c, v);
5171 namespace test_noexcept
5174 int f() { return 0; }
5175 int g() noexcept { return 0; }
5177 static_assert(noexcept(f()) == false, "");
5178 static_assert(noexcept(g()) == true, "");
5182 namespace test_constexpr
5185 template < typename CharT >
5186 unsigned long constexpr
5187 strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
5189 return *s ? strlen_c_r(s + 1, acc + 1) : acc;
5192 template < typename CharT >
5193 unsigned long constexpr
5194 strlen_c(const CharT *const s) noexcept
5196 return strlen_c_r(s, 0UL);
5199 static_assert(strlen_c("") == 0UL, "");
5200 static_assert(strlen_c("1") == 1UL, "");
5201 static_assert(strlen_c("example") == 7UL, "");
5202 static_assert(strlen_c("another\0example") == 7UL, "");
5206 namespace test_rvalue_references
5209 template < int N >
5210 struct answer
5212 static constexpr int value = N;
5215 answer<1> f(int&) { return answer<1>(); }
5216 answer<2> f(const int&) { return answer<2>(); }
5217 answer<3> f(int&&) { return answer<3>(); }
5219 void
5220 test()
5222 int i = 0;
5223 const int c = 0;
5224 static_assert(decltype(f(i))::value == 1, "");
5225 static_assert(decltype(f(c))::value == 2, "");
5226 static_assert(decltype(f(0))::value == 3, "");
5231 namespace test_uniform_initialization
5234 struct test
5236 static const int zero {};
5237 static const int one {1};
5240 static_assert(test::zero == 0, "");
5241 static_assert(test::one == 1, "");
5245 namespace test_lambdas
5248 void
5249 test1()
5251 auto lambda1 = [](){};
5252 auto lambda2 = lambda1;
5253 lambda1();
5254 lambda2();
5258 test2()
5260 auto a = [](int i, int j){ return i + j; }(1, 2);
5261 auto b = []() -> int { return '0'; }();
5262 auto c = [=](){ return a + b; }();
5263 auto d = [&](){ return c; }();
5264 auto e = [a, &b](int x) mutable {
5265 const auto identity = [](int y){ return y; };
5266 for (auto i = 0; i < a; ++i)
5267 a += b--;
5268 return x + identity(a + b);
5269 }(0);
5270 return a + b + c + d + e;
5274 test3()
5276 const auto nullary = [](){ return 0; };
5277 const auto unary = [](int x){ return x; };
5278 using nullary_t = decltype(nullary);
5279 using unary_t = decltype(unary);
5280 const auto higher1st = [](nullary_t f){ return f(); };
5281 const auto higher2nd = [unary](nullary_t f1){
5282 return [unary, f1](unary_t f2){ return f2(unary(f1())); };
5284 return higher1st(nullary) + higher2nd(nullary)(unary);
5289 namespace test_variadic_templates
5292 template <int...>
5293 struct sum;
5295 template <int N0, int... N1toN>
5296 struct sum<N0, N1toN...>
5298 static constexpr auto value = N0 + sum<N1toN...>::value;
5301 template <>
5302 struct sum<>
5304 static constexpr auto value = 0;
5307 static_assert(sum<>::value == 0, "");
5308 static_assert(sum<1>::value == 1, "");
5309 static_assert(sum<23>::value == 23, "");
5310 static_assert(sum<1, 2>::value == 3, "");
5311 static_assert(sum<5, 5, 11>::value == 21, "");
5312 static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
5316 // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
5317 // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
5318 // because of this.
5319 namespace test_template_alias_sfinae
5322 struct foo {};
5324 template<typename T>
5325 using member = typename T::member_type;
5327 template<typename T>
5328 void func(...) {}
5330 template<typename T>
5331 void func(member<T>*) {}
5333 void test();
5335 void test() { func<foo>(0); }
5339 } // namespace cxx11
5341 #endif // __cplusplus >= 201103L
5346 // If the compiler admits that it is not ready for C++14, why torture it?
5347 // Hopefully, this will speed up the test.
5349 #ifndef __cplusplus
5351 #error "This is not a C++ compiler"
5353 #elif __cplusplus < 201402L && !defined _MSC_VER
5355 #error "This is not a C++14 compiler"
5357 #else
5359 namespace cxx14
5362 namespace test_polymorphic_lambdas
5366 test()
5368 const auto lambda = [](auto&&... args){
5369 const auto istiny = [](auto x){
5370 return (sizeof(x) == 1UL) ? 1 : 0;
5372 const int aretiny[] = { istiny(args)... };
5373 return aretiny[0];
5375 return lambda(1, 1L, 1.0f, '1');
5380 namespace test_binary_literals
5383 constexpr auto ivii = 0b0000000000101010;
5384 static_assert(ivii == 42, "wrong value");
5388 namespace test_generalized_constexpr
5391 template < typename CharT >
5392 constexpr unsigned long
5393 strlen_c(const CharT *const s) noexcept
5395 auto length = 0UL;
5396 for (auto p = s; *p; ++p)
5397 ++length;
5398 return length;
5401 static_assert(strlen_c("") == 0UL, "");
5402 static_assert(strlen_c("x") == 1UL, "");
5403 static_assert(strlen_c("test") == 4UL, "");
5404 static_assert(strlen_c("another\0test") == 7UL, "");
5408 namespace test_lambda_init_capture
5412 test()
5414 auto x = 0;
5415 const auto lambda1 = [a = x](int b){ return a + b; };
5416 const auto lambda2 = [a = lambda1(x)](){ return a; };
5417 return lambda2();
5422 namespace test_digit_separators
5425 constexpr auto ten_million = 100'000'000;
5426 static_assert(ten_million == 100000000, "");
5430 namespace test_return_type_deduction
5433 auto f(int& x) { return x; }
5434 decltype(auto) g(int& x) { return x; }
5436 template < typename T1, typename T2 >
5437 struct is_same
5439 static constexpr auto value = false;
5442 template < typename T >
5443 struct is_same<T, T>
5445 static constexpr auto value = true;
5449 test()
5451 auto x = 0;
5452 static_assert(is_same<int, decltype(f(x))>::value, "");
5453 static_assert(is_same<int&, decltype(g(x))>::value, "");
5454 return x;
5459 } // namespace cxx14
5461 #endif // __cplusplus >= 201402L
5466 // If the compiler admits that it is not ready for C++17, why torture it?
5467 // Hopefully, this will speed up the test.
5469 #ifndef __cplusplus
5471 #error "This is not a C++ compiler"
5473 #elif __cplusplus < 201703L && !defined _MSC_VER
5475 #error "This is not a C++17 compiler"
5477 #else
5479 #include <initializer_list>
5480 #include <utility>
5481 #include <type_traits>
5483 namespace cxx17
5486 namespace test_constexpr_lambdas
5489 constexpr int foo = [](){return 42;}();
5493 namespace test::nested_namespace::definitions
5498 namespace test_fold_expression
5501 template<typename... Args>
5502 int multiply(Args... args)
5504 return (args * ... * 1);
5507 template<typename... Args>
5508 bool all(Args... args)
5510 return (args && ...);
5515 namespace test_extended_static_assert
5518 static_assert (true);
5522 namespace test_auto_brace_init_list
5525 auto foo = {5};
5526 auto bar {5};
5528 static_assert(std::is_same<std::initializer_list<int>, decltype(foo)>::value);
5529 static_assert(std::is_same<int, decltype(bar)>::value);
5532 namespace test_typename_in_template_template_parameter
5535 template<template<typename> typename X> struct D;
5539 namespace test_fallthrough_nodiscard_maybe_unused_attributes
5542 int f1()
5544 return 42;
5547 [[nodiscard]] int f2()
5549 [[maybe_unused]] auto unused = f1();
5551 switch (f1())
5553 case 17:
5554 f1();
5555 [[fallthrough]];
5556 case 42:
5557 f1();
5559 return f1();
5564 namespace test_extended_aggregate_initialization
5567 struct base1
5569 int b1, b2 = 42;
5572 struct base2
5574 base2() {
5575 b3 = 42;
5577 int b3;
5580 struct derived : base1, base2
5582 int d;
5585 derived d1 {{1, 2}, {}, 4}; // full initialization
5586 derived d2 {{}, {}, 4}; // value-initialized bases
5590 namespace test_general_range_based_for_loop
5593 struct iter
5595 int i;
5597 int& operator* ()
5599 return i;
5602 const int& operator* () const
5604 return i;
5607 iter& operator++()
5609 ++i;
5610 return *this;
5614 struct sentinel
5616 int i;
5619 bool operator== (const iter& i, const sentinel& s)
5621 return i.i == s.i;
5624 bool operator!= (const iter& i, const sentinel& s)
5626 return !(i == s);
5629 struct range
5631 iter begin() const
5633 return {0};
5636 sentinel end() const
5638 return {5};
5642 void f()
5644 range r {};
5646 for (auto i : r)
5648 [[maybe_unused]] auto v = i;
5654 namespace test_lambda_capture_asterisk_this_by_value
5657 struct t
5659 int i;
5660 int foo()
5662 return [*this]()
5664 return i;
5665 }();
5671 namespace test_enum_class_construction
5674 enum class byte : unsigned char
5677 byte foo {42};
5681 namespace test_constexpr_if
5684 template <bool cond>
5685 int f ()
5687 if constexpr(cond)
5689 return 13;
5691 else
5693 return 42;
5699 namespace test_selection_statement_with_initializer
5702 int f()
5704 return 13;
5707 int f2()
5709 if (auto i = f(); i > 0)
5711 return 3;
5714 switch (auto i = f(); i + 4)
5716 case 17:
5717 return 2;
5719 default:
5720 return 1;
5726 namespace test_template_argument_deduction_for_class_templates
5729 template <typename T1, typename T2>
5730 struct pair
5732 pair (T1 p1, T2 p2)
5733 : m1 {p1},
5734 m2 {p2}
5737 T1 m1;
5738 T2 m2;
5741 void f()
5743 [[maybe_unused]] auto p = pair{13, 42u};
5748 namespace test_non_type_auto_template_parameters
5751 template <auto n>
5752 struct B
5755 B<5> b1;
5756 B<'a'> b2;
5760 namespace test_structured_bindings
5763 int arr[2] = { 1, 2 };
5764 std::pair<int, int> pr = { 1, 2 };
5766 auto f1() -> int(&)[2]
5768 return arr;
5771 auto f2() -> std::pair<int, int>&
5773 return pr;
5776 struct S
5778 int x1 : 2;
5779 volatile double y1;
5782 S f3()
5784 return {};
5787 auto [ x1, y1 ] = f1();
5788 auto& [ xr1, yr1 ] = f1();
5789 auto [ x2, y2 ] = f2();
5790 auto& [ xr2, yr2 ] = f2();
5791 const auto [ x3, y3 ] = f3();
5795 namespace test_exception_spec_type_system
5798 struct Good {};
5799 struct Bad {};
5801 void g1() noexcept;
5802 void g2();
5804 template<typename T>
5806 f(T*, T*);
5808 template<typename T1, typename T2>
5809 Good
5810 f(T1*, T2*);
5812 static_assert (std::is_same_v<Good, decltype(f(g1, g2))>);
5816 namespace test_inline_variables
5819 template<class T> void f(T)
5822 template<class T> inline T g(T)
5824 return T{};
5827 template<> inline void f<>(int)
5830 template<> int g<>(int)
5832 return 5;
5837 } // namespace cxx17
5839 #endif // __cplusplus < 201703L && !defined _MSC_VER
5843 _ACEOF
5844 if ac_fn_cxx_try_compile "$LINENO"; then :
5845 ax_cv_cxx_compile_cxx17=yes
5846 else
5847 ax_cv_cxx_compile_cxx17=no
5849 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5851 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_cxx_compile_cxx17" >&5
5852 $as_echo "$ax_cv_cxx_compile_cxx17" >&6; }
5853 if test x$ax_cv_cxx_compile_cxx17 = xyes; then
5854 ac_success=yes
5857 if test x$ac_success = xno; then
5858 for alternative in ${ax_cxx_compile_alternatives}; do
5859 switch="-std=gnu++${alternative}"
5860 cachevar=`$as_echo "ax_cv_cxx_compile_cxx17_$switch" | $as_tr_sh`
5861 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++17 features with $switch" >&5
5862 $as_echo_n "checking whether $CXX supports C++17 features with $switch... " >&6; }
5863 if eval \${$cachevar+:} false; then :
5864 $as_echo_n "(cached) " >&6
5865 else
5866 ac_save_CXX="$CXX"
5867 CXX="$CXX $switch"
5868 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5869 /* end confdefs.h. */
5872 // If the compiler admits that it is not ready for C++11, why torture it?
5873 // Hopefully, this will speed up the test.
5875 #ifndef __cplusplus
5877 #error "This is not a C++ compiler"
5879 // MSVC always sets __cplusplus to 199711L in older versions; newer versions
5880 // only set it correctly if /Zc:__cplusplus is specified as well as a
5881 // /std:c++NN switch:
5882 // https://devblogs.microsoft.com/cppblog/msvc-now-correctly-reports-__cplusplus/
5883 #elif __cplusplus < 201103L && !defined _MSC_VER
5885 #error "This is not a C++11 compiler"
5887 #else
5889 namespace cxx11
5892 namespace test_static_assert
5895 template <typename T>
5896 struct check
5898 static_assert(sizeof(int) <= sizeof(T), "not big enough");
5903 namespace test_final_override
5906 struct Base
5908 virtual ~Base() {}
5909 virtual void f() {}
5912 struct Derived : public Base
5914 virtual ~Derived() override {}
5915 virtual void f() override {}
5920 namespace test_double_right_angle_brackets
5923 template < typename T >
5924 struct check {};
5926 typedef check<void> single_type;
5927 typedef check<check<void>> double_type;
5928 typedef check<check<check<void>>> triple_type;
5929 typedef check<check<check<check<void>>>> quadruple_type;
5933 namespace test_decltype
5939 int a = 1;
5940 decltype(a) b = 2;
5941 return a + b;
5946 namespace test_type_deduction
5949 template < typename T1, typename T2 >
5950 struct is_same
5952 static const bool value = false;
5955 template < typename T >
5956 struct is_same<T, T>
5958 static const bool value = true;
5961 template < typename T1, typename T2 >
5962 auto
5963 add(T1 a1, T2 a2) -> decltype(a1 + a2)
5965 return a1 + a2;
5969 test(const int c, volatile int v)
5971 static_assert(is_same<int, decltype(0)>::value == true, "");
5972 static_assert(is_same<int, decltype(c)>::value == false, "");
5973 static_assert(is_same<int, decltype(v)>::value == false, "");
5974 auto ac = c;
5975 auto av = v;
5976 auto sumi = ac + av + 'x';
5977 auto sumf = ac + av + 1.0;
5978 static_assert(is_same<int, decltype(ac)>::value == true, "");
5979 static_assert(is_same<int, decltype(av)>::value == true, "");
5980 static_assert(is_same<int, decltype(sumi)>::value == true, "");
5981 static_assert(is_same<int, decltype(sumf)>::value == false, "");
5982 static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
5983 return (sumf > 0.0) ? sumi : add(c, v);
5988 namespace test_noexcept
5991 int f() { return 0; }
5992 int g() noexcept { return 0; }
5994 static_assert(noexcept(f()) == false, "");
5995 static_assert(noexcept(g()) == true, "");
5999 namespace test_constexpr
6002 template < typename CharT >
6003 unsigned long constexpr
6004 strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
6006 return *s ? strlen_c_r(s + 1, acc + 1) : acc;
6009 template < typename CharT >
6010 unsigned long constexpr
6011 strlen_c(const CharT *const s) noexcept
6013 return strlen_c_r(s, 0UL);
6016 static_assert(strlen_c("") == 0UL, "");
6017 static_assert(strlen_c("1") == 1UL, "");
6018 static_assert(strlen_c("example") == 7UL, "");
6019 static_assert(strlen_c("another\0example") == 7UL, "");
6023 namespace test_rvalue_references
6026 template < int N >
6027 struct answer
6029 static constexpr int value = N;
6032 answer<1> f(int&) { return answer<1>(); }
6033 answer<2> f(const int&) { return answer<2>(); }
6034 answer<3> f(int&&) { return answer<3>(); }
6036 void
6037 test()
6039 int i = 0;
6040 const int c = 0;
6041 static_assert(decltype(f(i))::value == 1, "");
6042 static_assert(decltype(f(c))::value == 2, "");
6043 static_assert(decltype(f(0))::value == 3, "");
6048 namespace test_uniform_initialization
6051 struct test
6053 static const int zero {};
6054 static const int one {1};
6057 static_assert(test::zero == 0, "");
6058 static_assert(test::one == 1, "");
6062 namespace test_lambdas
6065 void
6066 test1()
6068 auto lambda1 = [](){};
6069 auto lambda2 = lambda1;
6070 lambda1();
6071 lambda2();
6075 test2()
6077 auto a = [](int i, int j){ return i + j; }(1, 2);
6078 auto b = []() -> int { return '0'; }();
6079 auto c = [=](){ return a + b; }();
6080 auto d = [&](){ return c; }();
6081 auto e = [a, &b](int x) mutable {
6082 const auto identity = [](int y){ return y; };
6083 for (auto i = 0; i < a; ++i)
6084 a += b--;
6085 return x + identity(a + b);
6086 }(0);
6087 return a + b + c + d + e;
6091 test3()
6093 const auto nullary = [](){ return 0; };
6094 const auto unary = [](int x){ return x; };
6095 using nullary_t = decltype(nullary);
6096 using unary_t = decltype(unary);
6097 const auto higher1st = [](nullary_t f){ return f(); };
6098 const auto higher2nd = [unary](nullary_t f1){
6099 return [unary, f1](unary_t f2){ return f2(unary(f1())); };
6101 return higher1st(nullary) + higher2nd(nullary)(unary);
6106 namespace test_variadic_templates
6109 template <int...>
6110 struct sum;
6112 template <int N0, int... N1toN>
6113 struct sum<N0, N1toN...>
6115 static constexpr auto value = N0 + sum<N1toN...>::value;
6118 template <>
6119 struct sum<>
6121 static constexpr auto value = 0;
6124 static_assert(sum<>::value == 0, "");
6125 static_assert(sum<1>::value == 1, "");
6126 static_assert(sum<23>::value == 23, "");
6127 static_assert(sum<1, 2>::value == 3, "");
6128 static_assert(sum<5, 5, 11>::value == 21, "");
6129 static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
6133 // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
6134 // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
6135 // because of this.
6136 namespace test_template_alias_sfinae
6139 struct foo {};
6141 template<typename T>
6142 using member = typename T::member_type;
6144 template<typename T>
6145 void func(...) {}
6147 template<typename T>
6148 void func(member<T>*) {}
6150 void test();
6152 void test() { func<foo>(0); }
6156 } // namespace cxx11
6158 #endif // __cplusplus >= 201103L
6163 // If the compiler admits that it is not ready for C++14, why torture it?
6164 // Hopefully, this will speed up the test.
6166 #ifndef __cplusplus
6168 #error "This is not a C++ compiler"
6170 #elif __cplusplus < 201402L && !defined _MSC_VER
6172 #error "This is not a C++14 compiler"
6174 #else
6176 namespace cxx14
6179 namespace test_polymorphic_lambdas
6183 test()
6185 const auto lambda = [](auto&&... args){
6186 const auto istiny = [](auto x){
6187 return (sizeof(x) == 1UL) ? 1 : 0;
6189 const int aretiny[] = { istiny(args)... };
6190 return aretiny[0];
6192 return lambda(1, 1L, 1.0f, '1');
6197 namespace test_binary_literals
6200 constexpr auto ivii = 0b0000000000101010;
6201 static_assert(ivii == 42, "wrong value");
6205 namespace test_generalized_constexpr
6208 template < typename CharT >
6209 constexpr unsigned long
6210 strlen_c(const CharT *const s) noexcept
6212 auto length = 0UL;
6213 for (auto p = s; *p; ++p)
6214 ++length;
6215 return length;
6218 static_assert(strlen_c("") == 0UL, "");
6219 static_assert(strlen_c("x") == 1UL, "");
6220 static_assert(strlen_c("test") == 4UL, "");
6221 static_assert(strlen_c("another\0test") == 7UL, "");
6225 namespace test_lambda_init_capture
6229 test()
6231 auto x = 0;
6232 const auto lambda1 = [a = x](int b){ return a + b; };
6233 const auto lambda2 = [a = lambda1(x)](){ return a; };
6234 return lambda2();
6239 namespace test_digit_separators
6242 constexpr auto ten_million = 100'000'000;
6243 static_assert(ten_million == 100000000, "");
6247 namespace test_return_type_deduction
6250 auto f(int& x) { return x; }
6251 decltype(auto) g(int& x) { return x; }
6253 template < typename T1, typename T2 >
6254 struct is_same
6256 static constexpr auto value = false;
6259 template < typename T >
6260 struct is_same<T, T>
6262 static constexpr auto value = true;
6266 test()
6268 auto x = 0;
6269 static_assert(is_same<int, decltype(f(x))>::value, "");
6270 static_assert(is_same<int&, decltype(g(x))>::value, "");
6271 return x;
6276 } // namespace cxx14
6278 #endif // __cplusplus >= 201402L
6283 // If the compiler admits that it is not ready for C++17, why torture it?
6284 // Hopefully, this will speed up the test.
6286 #ifndef __cplusplus
6288 #error "This is not a C++ compiler"
6290 #elif __cplusplus < 201703L && !defined _MSC_VER
6292 #error "This is not a C++17 compiler"
6294 #else
6296 #include <initializer_list>
6297 #include <utility>
6298 #include <type_traits>
6300 namespace cxx17
6303 namespace test_constexpr_lambdas
6306 constexpr int foo = [](){return 42;}();
6310 namespace test::nested_namespace::definitions
6315 namespace test_fold_expression
6318 template<typename... Args>
6319 int multiply(Args... args)
6321 return (args * ... * 1);
6324 template<typename... Args>
6325 bool all(Args... args)
6327 return (args && ...);
6332 namespace test_extended_static_assert
6335 static_assert (true);
6339 namespace test_auto_brace_init_list
6342 auto foo = {5};
6343 auto bar {5};
6345 static_assert(std::is_same<std::initializer_list<int>, decltype(foo)>::value);
6346 static_assert(std::is_same<int, decltype(bar)>::value);
6349 namespace test_typename_in_template_template_parameter
6352 template<template<typename> typename X> struct D;
6356 namespace test_fallthrough_nodiscard_maybe_unused_attributes
6359 int f1()
6361 return 42;
6364 [[nodiscard]] int f2()
6366 [[maybe_unused]] auto unused = f1();
6368 switch (f1())
6370 case 17:
6371 f1();
6372 [[fallthrough]];
6373 case 42:
6374 f1();
6376 return f1();
6381 namespace test_extended_aggregate_initialization
6384 struct base1
6386 int b1, b2 = 42;
6389 struct base2
6391 base2() {
6392 b3 = 42;
6394 int b3;
6397 struct derived : base1, base2
6399 int d;
6402 derived d1 {{1, 2}, {}, 4}; // full initialization
6403 derived d2 {{}, {}, 4}; // value-initialized bases
6407 namespace test_general_range_based_for_loop
6410 struct iter
6412 int i;
6414 int& operator* ()
6416 return i;
6419 const int& operator* () const
6421 return i;
6424 iter& operator++()
6426 ++i;
6427 return *this;
6431 struct sentinel
6433 int i;
6436 bool operator== (const iter& i, const sentinel& s)
6438 return i.i == s.i;
6441 bool operator!= (const iter& i, const sentinel& s)
6443 return !(i == s);
6446 struct range
6448 iter begin() const
6450 return {0};
6453 sentinel end() const
6455 return {5};
6459 void f()
6461 range r {};
6463 for (auto i : r)
6465 [[maybe_unused]] auto v = i;
6471 namespace test_lambda_capture_asterisk_this_by_value
6474 struct t
6476 int i;
6477 int foo()
6479 return [*this]()
6481 return i;
6482 }();
6488 namespace test_enum_class_construction
6491 enum class byte : unsigned char
6494 byte foo {42};
6498 namespace test_constexpr_if
6501 template <bool cond>
6502 int f ()
6504 if constexpr(cond)
6506 return 13;
6508 else
6510 return 42;
6516 namespace test_selection_statement_with_initializer
6519 int f()
6521 return 13;
6524 int f2()
6526 if (auto i = f(); i > 0)
6528 return 3;
6531 switch (auto i = f(); i + 4)
6533 case 17:
6534 return 2;
6536 default:
6537 return 1;
6543 namespace test_template_argument_deduction_for_class_templates
6546 template <typename T1, typename T2>
6547 struct pair
6549 pair (T1 p1, T2 p2)
6550 : m1 {p1},
6551 m2 {p2}
6554 T1 m1;
6555 T2 m2;
6558 void f()
6560 [[maybe_unused]] auto p = pair{13, 42u};
6565 namespace test_non_type_auto_template_parameters
6568 template <auto n>
6569 struct B
6572 B<5> b1;
6573 B<'a'> b2;
6577 namespace test_structured_bindings
6580 int arr[2] = { 1, 2 };
6581 std::pair<int, int> pr = { 1, 2 };
6583 auto f1() -> int(&)[2]
6585 return arr;
6588 auto f2() -> std::pair<int, int>&
6590 return pr;
6593 struct S
6595 int x1 : 2;
6596 volatile double y1;
6599 S f3()
6601 return {};
6604 auto [ x1, y1 ] = f1();
6605 auto& [ xr1, yr1 ] = f1();
6606 auto [ x2, y2 ] = f2();
6607 auto& [ xr2, yr2 ] = f2();
6608 const auto [ x3, y3 ] = f3();
6612 namespace test_exception_spec_type_system
6615 struct Good {};
6616 struct Bad {};
6618 void g1() noexcept;
6619 void g2();
6621 template<typename T>
6623 f(T*, T*);
6625 template<typename T1, typename T2>
6626 Good
6627 f(T1*, T2*);
6629 static_assert (std::is_same_v<Good, decltype(f(g1, g2))>);
6633 namespace test_inline_variables
6636 template<class T> void f(T)
6639 template<class T> inline T g(T)
6641 return T{};
6644 template<> inline void f<>(int)
6647 template<> int g<>(int)
6649 return 5;
6654 } // namespace cxx17
6656 #endif // __cplusplus < 201703L && !defined _MSC_VER
6660 _ACEOF
6661 if ac_fn_cxx_try_compile "$LINENO"; then :
6662 eval $cachevar=yes
6663 else
6664 eval $cachevar=no
6666 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6667 CXX="$ac_save_CXX"
6669 eval ac_res=\$$cachevar
6670 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
6671 $as_echo "$ac_res" >&6; }
6672 if eval test x\$$cachevar = xyes; then
6673 CXX_DIALECT="$switch"
6674 CXX="$CXX $switch"
6675 if test -n "$CXXCPP" ; then
6676 CXXCPP="$CXXCPP $switch"
6678 ac_success=yes
6679 break
6681 done
6684 if test x$ac_success = xno; then
6685 for alternative in ${ax_cxx_compile_alternatives}; do
6686 for switch in -std=c++${alternative} +std=c++${alternative} "-h std=c++${alternative}" MSVC; do
6687 if test x"$switch" = xMSVC; then
6688 switch=-std:c++${alternative}
6689 cachevar=`$as_echo "ax_cv_cxx_compile_cxx17_${switch}_MSVC" | $as_tr_sh`
6690 else
6691 cachevar=`$as_echo "ax_cv_cxx_compile_cxx17_$switch" | $as_tr_sh`
6693 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++17 features with $switch" >&5
6694 $as_echo_n "checking whether $CXX supports C++17 features with $switch... " >&6; }
6695 if eval \${$cachevar+:} false; then :
6696 $as_echo_n "(cached) " >&6
6697 else
6698 ac_save_CXX="$CXX"
6699 CXX="$CXX $switch"
6700 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6701 /* end confdefs.h. */
6704 // If the compiler admits that it is not ready for C++11, why torture it?
6705 // Hopefully, this will speed up the test.
6707 #ifndef __cplusplus
6709 #error "This is not a C++ compiler"
6711 // MSVC always sets __cplusplus to 199711L in older versions; newer versions
6712 // only set it correctly if /Zc:__cplusplus is specified as well as a
6713 // /std:c++NN switch:
6714 // https://devblogs.microsoft.com/cppblog/msvc-now-correctly-reports-__cplusplus/
6715 #elif __cplusplus < 201103L && !defined _MSC_VER
6717 #error "This is not a C++11 compiler"
6719 #else
6721 namespace cxx11
6724 namespace test_static_assert
6727 template <typename T>
6728 struct check
6730 static_assert(sizeof(int) <= sizeof(T), "not big enough");
6735 namespace test_final_override
6738 struct Base
6740 virtual ~Base() {}
6741 virtual void f() {}
6744 struct Derived : public Base
6746 virtual ~Derived() override {}
6747 virtual void f() override {}
6752 namespace test_double_right_angle_brackets
6755 template < typename T >
6756 struct check {};
6758 typedef check<void> single_type;
6759 typedef check<check<void>> double_type;
6760 typedef check<check<check<void>>> triple_type;
6761 typedef check<check<check<check<void>>>> quadruple_type;
6765 namespace test_decltype
6771 int a = 1;
6772 decltype(a) b = 2;
6773 return a + b;
6778 namespace test_type_deduction
6781 template < typename T1, typename T2 >
6782 struct is_same
6784 static const bool value = false;
6787 template < typename T >
6788 struct is_same<T, T>
6790 static const bool value = true;
6793 template < typename T1, typename T2 >
6794 auto
6795 add(T1 a1, T2 a2) -> decltype(a1 + a2)
6797 return a1 + a2;
6801 test(const int c, volatile int v)
6803 static_assert(is_same<int, decltype(0)>::value == true, "");
6804 static_assert(is_same<int, decltype(c)>::value == false, "");
6805 static_assert(is_same<int, decltype(v)>::value == false, "");
6806 auto ac = c;
6807 auto av = v;
6808 auto sumi = ac + av + 'x';
6809 auto sumf = ac + av + 1.0;
6810 static_assert(is_same<int, decltype(ac)>::value == true, "");
6811 static_assert(is_same<int, decltype(av)>::value == true, "");
6812 static_assert(is_same<int, decltype(sumi)>::value == true, "");
6813 static_assert(is_same<int, decltype(sumf)>::value == false, "");
6814 static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
6815 return (sumf > 0.0) ? sumi : add(c, v);
6820 namespace test_noexcept
6823 int f() { return 0; }
6824 int g() noexcept { return 0; }
6826 static_assert(noexcept(f()) == false, "");
6827 static_assert(noexcept(g()) == true, "");
6831 namespace test_constexpr
6834 template < typename CharT >
6835 unsigned long constexpr
6836 strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
6838 return *s ? strlen_c_r(s + 1, acc + 1) : acc;
6841 template < typename CharT >
6842 unsigned long constexpr
6843 strlen_c(const CharT *const s) noexcept
6845 return strlen_c_r(s, 0UL);
6848 static_assert(strlen_c("") == 0UL, "");
6849 static_assert(strlen_c("1") == 1UL, "");
6850 static_assert(strlen_c("example") == 7UL, "");
6851 static_assert(strlen_c("another\0example") == 7UL, "");
6855 namespace test_rvalue_references
6858 template < int N >
6859 struct answer
6861 static constexpr int value = N;
6864 answer<1> f(int&) { return answer<1>(); }
6865 answer<2> f(const int&) { return answer<2>(); }
6866 answer<3> f(int&&) { return answer<3>(); }
6868 void
6869 test()
6871 int i = 0;
6872 const int c = 0;
6873 static_assert(decltype(f(i))::value == 1, "");
6874 static_assert(decltype(f(c))::value == 2, "");
6875 static_assert(decltype(f(0))::value == 3, "");
6880 namespace test_uniform_initialization
6883 struct test
6885 static const int zero {};
6886 static const int one {1};
6889 static_assert(test::zero == 0, "");
6890 static_assert(test::one == 1, "");
6894 namespace test_lambdas
6897 void
6898 test1()
6900 auto lambda1 = [](){};
6901 auto lambda2 = lambda1;
6902 lambda1();
6903 lambda2();
6907 test2()
6909 auto a = [](int i, int j){ return i + j; }(1, 2);
6910 auto b = []() -> int { return '0'; }();
6911 auto c = [=](){ return a + b; }();
6912 auto d = [&](){ return c; }();
6913 auto e = [a, &b](int x) mutable {
6914 const auto identity = [](int y){ return y; };
6915 for (auto i = 0; i < a; ++i)
6916 a += b--;
6917 return x + identity(a + b);
6918 }(0);
6919 return a + b + c + d + e;
6923 test3()
6925 const auto nullary = [](){ return 0; };
6926 const auto unary = [](int x){ return x; };
6927 using nullary_t = decltype(nullary);
6928 using unary_t = decltype(unary);
6929 const auto higher1st = [](nullary_t f){ return f(); };
6930 const auto higher2nd = [unary](nullary_t f1){
6931 return [unary, f1](unary_t f2){ return f2(unary(f1())); };
6933 return higher1st(nullary) + higher2nd(nullary)(unary);
6938 namespace test_variadic_templates
6941 template <int...>
6942 struct sum;
6944 template <int N0, int... N1toN>
6945 struct sum<N0, N1toN...>
6947 static constexpr auto value = N0 + sum<N1toN...>::value;
6950 template <>
6951 struct sum<>
6953 static constexpr auto value = 0;
6956 static_assert(sum<>::value == 0, "");
6957 static_assert(sum<1>::value == 1, "");
6958 static_assert(sum<23>::value == 23, "");
6959 static_assert(sum<1, 2>::value == 3, "");
6960 static_assert(sum<5, 5, 11>::value == 21, "");
6961 static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
6965 // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
6966 // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
6967 // because of this.
6968 namespace test_template_alias_sfinae
6971 struct foo {};
6973 template<typename T>
6974 using member = typename T::member_type;
6976 template<typename T>
6977 void func(...) {}
6979 template<typename T>
6980 void func(member<T>*) {}
6982 void test();
6984 void test() { func<foo>(0); }
6988 } // namespace cxx11
6990 #endif // __cplusplus >= 201103L
6995 // If the compiler admits that it is not ready for C++14, why torture it?
6996 // Hopefully, this will speed up the test.
6998 #ifndef __cplusplus
7000 #error "This is not a C++ compiler"
7002 #elif __cplusplus < 201402L && !defined _MSC_VER
7004 #error "This is not a C++14 compiler"
7006 #else
7008 namespace cxx14
7011 namespace test_polymorphic_lambdas
7015 test()
7017 const auto lambda = [](auto&&... args){
7018 const auto istiny = [](auto x){
7019 return (sizeof(x) == 1UL) ? 1 : 0;
7021 const int aretiny[] = { istiny(args)... };
7022 return aretiny[0];
7024 return lambda(1, 1L, 1.0f, '1');
7029 namespace test_binary_literals
7032 constexpr auto ivii = 0b0000000000101010;
7033 static_assert(ivii == 42, "wrong value");
7037 namespace test_generalized_constexpr
7040 template < typename CharT >
7041 constexpr unsigned long
7042 strlen_c(const CharT *const s) noexcept
7044 auto length = 0UL;
7045 for (auto p = s; *p; ++p)
7046 ++length;
7047 return length;
7050 static_assert(strlen_c("") == 0UL, "");
7051 static_assert(strlen_c("x") == 1UL, "");
7052 static_assert(strlen_c("test") == 4UL, "");
7053 static_assert(strlen_c("another\0test") == 7UL, "");
7057 namespace test_lambda_init_capture
7061 test()
7063 auto x = 0;
7064 const auto lambda1 = [a = x](int b){ return a + b; };
7065 const auto lambda2 = [a = lambda1(x)](){ return a; };
7066 return lambda2();
7071 namespace test_digit_separators
7074 constexpr auto ten_million = 100'000'000;
7075 static_assert(ten_million == 100000000, "");
7079 namespace test_return_type_deduction
7082 auto f(int& x) { return x; }
7083 decltype(auto) g(int& x) { return x; }
7085 template < typename T1, typename T2 >
7086 struct is_same
7088 static constexpr auto value = false;
7091 template < typename T >
7092 struct is_same<T, T>
7094 static constexpr auto value = true;
7098 test()
7100 auto x = 0;
7101 static_assert(is_same<int, decltype(f(x))>::value, "");
7102 static_assert(is_same<int&, decltype(g(x))>::value, "");
7103 return x;
7108 } // namespace cxx14
7110 #endif // __cplusplus >= 201402L
7115 // If the compiler admits that it is not ready for C++17, why torture it?
7116 // Hopefully, this will speed up the test.
7118 #ifndef __cplusplus
7120 #error "This is not a C++ compiler"
7122 #elif __cplusplus < 201703L && !defined _MSC_VER
7124 #error "This is not a C++17 compiler"
7126 #else
7128 #include <initializer_list>
7129 #include <utility>
7130 #include <type_traits>
7132 namespace cxx17
7135 namespace test_constexpr_lambdas
7138 constexpr int foo = [](){return 42;}();
7142 namespace test::nested_namespace::definitions
7147 namespace test_fold_expression
7150 template<typename... Args>
7151 int multiply(Args... args)
7153 return (args * ... * 1);
7156 template<typename... Args>
7157 bool all(Args... args)
7159 return (args && ...);
7164 namespace test_extended_static_assert
7167 static_assert (true);
7171 namespace test_auto_brace_init_list
7174 auto foo = {5};
7175 auto bar {5};
7177 static_assert(std::is_same<std::initializer_list<int>, decltype(foo)>::value);
7178 static_assert(std::is_same<int, decltype(bar)>::value);
7181 namespace test_typename_in_template_template_parameter
7184 template<template<typename> typename X> struct D;
7188 namespace test_fallthrough_nodiscard_maybe_unused_attributes
7191 int f1()
7193 return 42;
7196 [[nodiscard]] int f2()
7198 [[maybe_unused]] auto unused = f1();
7200 switch (f1())
7202 case 17:
7203 f1();
7204 [[fallthrough]];
7205 case 42:
7206 f1();
7208 return f1();
7213 namespace test_extended_aggregate_initialization
7216 struct base1
7218 int b1, b2 = 42;
7221 struct base2
7223 base2() {
7224 b3 = 42;
7226 int b3;
7229 struct derived : base1, base2
7231 int d;
7234 derived d1 {{1, 2}, {}, 4}; // full initialization
7235 derived d2 {{}, {}, 4}; // value-initialized bases
7239 namespace test_general_range_based_for_loop
7242 struct iter
7244 int i;
7246 int& operator* ()
7248 return i;
7251 const int& operator* () const
7253 return i;
7256 iter& operator++()
7258 ++i;
7259 return *this;
7263 struct sentinel
7265 int i;
7268 bool operator== (const iter& i, const sentinel& s)
7270 return i.i == s.i;
7273 bool operator!= (const iter& i, const sentinel& s)
7275 return !(i == s);
7278 struct range
7280 iter begin() const
7282 return {0};
7285 sentinel end() const
7287 return {5};
7291 void f()
7293 range r {};
7295 for (auto i : r)
7297 [[maybe_unused]] auto v = i;
7303 namespace test_lambda_capture_asterisk_this_by_value
7306 struct t
7308 int i;
7309 int foo()
7311 return [*this]()
7313 return i;
7314 }();
7320 namespace test_enum_class_construction
7323 enum class byte : unsigned char
7326 byte foo {42};
7330 namespace test_constexpr_if
7333 template <bool cond>
7334 int f ()
7336 if constexpr(cond)
7338 return 13;
7340 else
7342 return 42;
7348 namespace test_selection_statement_with_initializer
7351 int f()
7353 return 13;
7356 int f2()
7358 if (auto i = f(); i > 0)
7360 return 3;
7363 switch (auto i = f(); i + 4)
7365 case 17:
7366 return 2;
7368 default:
7369 return 1;
7375 namespace test_template_argument_deduction_for_class_templates
7378 template <typename T1, typename T2>
7379 struct pair
7381 pair (T1 p1, T2 p2)
7382 : m1 {p1},
7383 m2 {p2}
7386 T1 m1;
7387 T2 m2;
7390 void f()
7392 [[maybe_unused]] auto p = pair{13, 42u};
7397 namespace test_non_type_auto_template_parameters
7400 template <auto n>
7401 struct B
7404 B<5> b1;
7405 B<'a'> b2;
7409 namespace test_structured_bindings
7412 int arr[2] = { 1, 2 };
7413 std::pair<int, int> pr = { 1, 2 };
7415 auto f1() -> int(&)[2]
7417 return arr;
7420 auto f2() -> std::pair<int, int>&
7422 return pr;
7425 struct S
7427 int x1 : 2;
7428 volatile double y1;
7431 S f3()
7433 return {};
7436 auto [ x1, y1 ] = f1();
7437 auto& [ xr1, yr1 ] = f1();
7438 auto [ x2, y2 ] = f2();
7439 auto& [ xr2, yr2 ] = f2();
7440 const auto [ x3, y3 ] = f3();
7444 namespace test_exception_spec_type_system
7447 struct Good {};
7448 struct Bad {};
7450 void g1() noexcept;
7451 void g2();
7453 template<typename T>
7455 f(T*, T*);
7457 template<typename T1, typename T2>
7458 Good
7459 f(T1*, T2*);
7461 static_assert (std::is_same_v<Good, decltype(f(g1, g2))>);
7465 namespace test_inline_variables
7468 template<class T> void f(T)
7471 template<class T> inline T g(T)
7473 return T{};
7476 template<> inline void f<>(int)
7479 template<> int g<>(int)
7481 return 5;
7486 } // namespace cxx17
7488 #endif // __cplusplus < 201703L && !defined _MSC_VER
7492 _ACEOF
7493 if ac_fn_cxx_try_compile "$LINENO"; then :
7494 eval $cachevar=yes
7495 else
7496 eval $cachevar=no
7498 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7499 CXX="$ac_save_CXX"
7501 eval ac_res=\$$cachevar
7502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
7503 $as_echo "$ac_res" >&6; }
7504 if eval test x\$$cachevar = xyes; then
7505 CXX_DIALECT="$switch"
7506 CXX="$CXX $switch"
7507 if test -n "$CXXCPP" ; then
7508 CXXCPP="$CXXCPP $switch"
7510 ac_success=yes
7511 break
7513 done
7514 if test x$ac_success = xyes; then
7515 break
7517 done
7519 ac_ext=c
7520 ac_cpp='$CPP $CPPFLAGS'
7521 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7522 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7523 ac_compiler_gnu=$ac_cv_c_compiler_gnu
7525 if test x$ax_cxx_compile_cxx17_required = xtrue; then
7526 if test x$ac_success = xno; then
7527 as_fn_error $? "*** A compiler with support for C++17 language features is required." "$LINENO" 5
7530 if test x$ac_success = xno; then
7531 HAVE_CXX17=0
7532 { $as_echo "$as_me:${as_lineno-$LINENO}: No compiler with C++17 support was found" >&5
7533 $as_echo "$as_me: No compiler with C++17 support was found" >&6;}
7534 else
7535 HAVE_CXX17=1
7537 $as_echo "#define HAVE_CXX17 1" >>confdefs.h
7544 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
7545 $as_echo_n "checking for ANSI C header files... " >&6; }
7546 if ${ac_cv_header_stdc+:} false; then :
7547 $as_echo_n "(cached) " >&6
7548 else
7549 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7550 /* end confdefs.h. */
7551 #include <stdlib.h>
7552 #include <stdarg.h>
7553 #include <string.h>
7554 #include <float.h>
7557 main ()
7561 return 0;
7563 _ACEOF
7564 if ac_fn_c_try_compile "$LINENO"; then :
7565 ac_cv_header_stdc=yes
7566 else
7567 ac_cv_header_stdc=no
7569 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7571 if test $ac_cv_header_stdc = yes; then
7572 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
7573 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7574 /* end confdefs.h. */
7575 #include <string.h>
7577 _ACEOF
7578 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7579 $EGREP "memchr" >/dev/null 2>&1; then :
7581 else
7582 ac_cv_header_stdc=no
7584 rm -f conftest*
7588 if test $ac_cv_header_stdc = yes; then
7589 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
7590 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7591 /* end confdefs.h. */
7592 #include <stdlib.h>
7594 _ACEOF
7595 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7596 $EGREP "free" >/dev/null 2>&1; then :
7598 else
7599 ac_cv_header_stdc=no
7601 rm -f conftest*
7605 if test $ac_cv_header_stdc = yes; then
7606 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
7607 if test "$cross_compiling" = yes; then :
7609 else
7610 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7611 /* end confdefs.h. */
7612 #include <ctype.h>
7613 #include <stdlib.h>
7614 #if ((' ' & 0x0FF) == 0x020)
7615 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
7616 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
7617 #else
7618 # define ISLOWER(c) \
7619 (('a' <= (c) && (c) <= 'i') \
7620 || ('j' <= (c) && (c) <= 'r') \
7621 || ('s' <= (c) && (c) <= 'z'))
7622 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
7623 #endif
7625 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
7627 main ()
7629 int i;
7630 for (i = 0; i < 256; i++)
7631 if (XOR (islower (i), ISLOWER (i))
7632 || toupper (i) != TOUPPER (i))
7633 return 2;
7634 return 0;
7636 _ACEOF
7637 if ac_fn_c_try_run "$LINENO"; then :
7639 else
7640 ac_cv_header_stdc=no
7642 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7643 conftest.$ac_objext conftest.beam conftest.$ac_ext
7648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
7649 $as_echo "$ac_cv_header_stdc" >&6; }
7650 if test $ac_cv_header_stdc = yes; then
7652 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
7657 ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
7658 if test "x$ac_cv_type_size_t" = xyes; then :
7660 else
7662 cat >>confdefs.h <<_ACEOF
7663 #define size_t unsigned int
7664 _ACEOF
7671 for ac_header in $ac_header_list
7672 do :
7673 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
7674 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
7676 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
7677 cat >>confdefs.h <<_ACEOF
7678 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
7679 _ACEOF
7683 done
7691 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
7692 if test "x$ac_cv_type_pid_t" = xyes; then :
7694 else
7696 cat >>confdefs.h <<_ACEOF
7697 #define pid_t int
7698 _ACEOF
7702 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
7703 $as_echo_n "checking for a sed that does not truncate output... " >&6; }
7704 if ${ac_cv_path_SED+:} false; then :
7705 $as_echo_n "(cached) " >&6
7706 else
7707 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
7708 for ac_i in 1 2 3 4 5 6 7; do
7709 ac_script="$ac_script$as_nl$ac_script"
7710 done
7711 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
7712 { ac_script=; unset ac_script;}
7713 if test -z "$SED"; then
7714 ac_path_SED_found=false
7715 # Loop through the user's path and test for each of PROGNAME-LIST
7716 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7717 for as_dir in $PATH
7719 IFS=$as_save_IFS
7720 test -z "$as_dir" && as_dir=.
7721 for ac_prog in sed gsed; do
7722 for ac_exec_ext in '' $ac_executable_extensions; do
7723 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
7724 as_fn_executable_p "$ac_path_SED" || continue
7725 # Check for GNU ac_path_SED and select it if it is found.
7726 # Check for GNU $ac_path_SED
7727 case `"$ac_path_SED" --version 2>&1` in
7728 *GNU*)
7729 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
7731 ac_count=0
7732 $as_echo_n 0123456789 >"conftest.in"
7733 while :
7735 cat "conftest.in" "conftest.in" >"conftest.tmp"
7736 mv "conftest.tmp" "conftest.in"
7737 cp "conftest.in" "conftest.nl"
7738 $as_echo '' >> "conftest.nl"
7739 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
7740 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
7741 as_fn_arith $ac_count + 1 && ac_count=$as_val
7742 if test $ac_count -gt ${ac_path_SED_max-0}; then
7743 # Best one so far, save it but keep looking for a better one
7744 ac_cv_path_SED="$ac_path_SED"
7745 ac_path_SED_max=$ac_count
7747 # 10*(2^10) chars as input seems more than enough
7748 test $ac_count -gt 10 && break
7749 done
7750 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
7751 esac
7753 $ac_path_SED_found && break 3
7754 done
7755 done
7756 done
7757 IFS=$as_save_IFS
7758 if test -z "$ac_cv_path_SED"; then
7759 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
7761 else
7762 ac_cv_path_SED=$SED
7766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
7767 $as_echo "$ac_cv_path_SED" >&6; }
7768 SED="$ac_cv_path_SED"
7769 rm -f conftest.sed
7772 if test "X$prefix" = "XNONE"; then
7773 acl_final_prefix="$ac_default_prefix"
7774 else
7775 acl_final_prefix="$prefix"
7777 if test "X$exec_prefix" = "XNONE"; then
7778 acl_final_exec_prefix='${prefix}'
7779 else
7780 acl_final_exec_prefix="$exec_prefix"
7782 acl_save_prefix="$prefix"
7783 prefix="$acl_final_prefix"
7784 eval acl_final_exec_prefix=\"$acl_final_exec_prefix\"
7785 prefix="$acl_save_prefix"
7788 # Check whether --with-gnu-ld was given.
7789 if test "${with_gnu_ld+set}" = set; then :
7790 withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
7791 else
7792 with_gnu_ld=no
7795 # Prepare PATH_SEPARATOR.
7796 # The user is always right.
7797 if test "${PATH_SEPARATOR+set}" != set; then
7798 echo "#! /bin/sh" >conf$$.sh
7799 echo "exit 0" >>conf$$.sh
7800 chmod +x conf$$.sh
7801 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
7802 PATH_SEPARATOR=';'
7803 else
7804 PATH_SEPARATOR=:
7806 rm -f conf$$.sh
7808 ac_prog=ld
7809 if test "$GCC" = yes; then
7810 # Check if gcc -print-prog-name=ld gives a path.
7811 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by GCC" >&5
7812 $as_echo_n "checking for ld used by GCC... " >&6; }
7813 case $host in
7814 *-*-mingw*)
7815 # gcc leaves a trailing carriage return which upsets mingw
7816 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
7818 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
7819 esac
7820 case $ac_prog in
7821 # Accept absolute paths.
7822 [\\/]* | [A-Za-z]:[\\/]*)
7823 re_direlt='/[^/][^/]*/\.\./'
7824 # Canonicalize the path of ld
7825 ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
7826 while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
7827 ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
7828 done
7829 test -z "$LD" && LD="$ac_prog"
7832 # If it fails, then pretend we aren't using GCC.
7833 ac_prog=ld
7836 # If it is relative, then search for the first ld in PATH.
7837 with_gnu_ld=unknown
7839 esac
7840 elif test "$with_gnu_ld" = yes; then
7841 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
7842 $as_echo_n "checking for GNU ld... " >&6; }
7843 else
7844 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
7845 $as_echo_n "checking for non-GNU ld... " >&6; }
7847 if ${acl_cv_path_LD+:} false; then :
7848 $as_echo_n "(cached) " >&6
7849 else
7850 if test -z "$LD"; then
7851 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
7852 for ac_dir in $PATH; do
7853 test -z "$ac_dir" && ac_dir=.
7854 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
7855 acl_cv_path_LD="$ac_dir/$ac_prog"
7856 # Check to see if the program is GNU ld. I'd rather use --version,
7857 # but apparently some GNU ld's only accept -v.
7858 # Break only if it was the GNU/non-GNU ld that we prefer.
7859 if "$acl_cv_path_LD" -v 2>&1 < /dev/null | $EGREP '(GNU|with BFD)' > /dev/null; then
7860 test "$with_gnu_ld" != no && break
7861 else
7862 test "$with_gnu_ld" != yes && break
7865 done
7866 IFS="$ac_save_ifs"
7867 else
7868 acl_cv_path_LD="$LD" # Let the user override the test with a path.
7872 LD="$acl_cv_path_LD"
7873 if test -n "$LD"; then
7874 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
7875 $as_echo "$LD" >&6; }
7876 else
7877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7878 $as_echo "no" >&6; }
7880 test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
7881 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
7882 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
7883 if ${acl_cv_prog_gnu_ld+:} false; then :
7884 $as_echo_n "(cached) " >&6
7885 else
7886 # I'd rather use --version here, but apparently some GNU ld's only accept -v.
7887 if $LD -v 2>&1 </dev/null | $EGREP '(GNU|with BFD)' 1>&5; then
7888 acl_cv_prog_gnu_ld=yes
7889 else
7890 acl_cv_prog_gnu_ld=no
7893 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_prog_gnu_ld" >&5
7894 $as_echo "$acl_cv_prog_gnu_ld" >&6; }
7895 with_gnu_ld=$acl_cv_prog_gnu_ld
7899 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shared library run path origin" >&5
7900 $as_echo_n "checking for shared library run path origin... " >&6; }
7901 if ${acl_cv_rpath+:} false; then :
7902 $as_echo_n "(cached) " >&6
7903 else
7905 CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
7906 ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
7907 . ./conftest.sh
7908 rm -f ./conftest.sh
7909 acl_cv_rpath=done
7912 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_rpath" >&5
7913 $as_echo "$acl_cv_rpath" >&6; }
7914 wl="$acl_cv_wl"
7915 libext="$acl_cv_libext"
7916 shlibext="$acl_cv_shlibext"
7917 hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
7918 hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
7919 hardcode_direct="$acl_cv_hardcode_direct"
7920 hardcode_minus_L="$acl_cv_hardcode_minus_L"
7921 # Check whether --enable-rpath was given.
7922 if test "${enable_rpath+set}" = set; then :
7923 enableval=$enable_rpath; :
7924 else
7925 enable_rpath=yes
7930 # Set the 'development' global.
7931 . $srcdir/../bfd/development.sh
7933 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
7934 $as_echo_n "checking for ANSI C header files... " >&6; }
7935 if ${ac_cv_header_stdc+:} false; then :
7936 $as_echo_n "(cached) " >&6
7937 else
7938 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7939 /* end confdefs.h. */
7940 #include <stdlib.h>
7941 #include <stdarg.h>
7942 #include <string.h>
7943 #include <float.h>
7946 main ()
7950 return 0;
7952 _ACEOF
7953 if ac_fn_c_try_compile "$LINENO"; then :
7954 ac_cv_header_stdc=yes
7955 else
7956 ac_cv_header_stdc=no
7958 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7960 if test $ac_cv_header_stdc = yes; then
7961 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
7962 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7963 /* end confdefs.h. */
7964 #include <string.h>
7966 _ACEOF
7967 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7968 $EGREP "memchr" >/dev/null 2>&1; then :
7970 else
7971 ac_cv_header_stdc=no
7973 rm -f conftest*
7977 if test $ac_cv_header_stdc = yes; then
7978 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
7979 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7980 /* end confdefs.h. */
7981 #include <stdlib.h>
7983 _ACEOF
7984 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7985 $EGREP "free" >/dev/null 2>&1; then :
7987 else
7988 ac_cv_header_stdc=no
7990 rm -f conftest*
7994 if test $ac_cv_header_stdc = yes; then
7995 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
7996 if test "$cross_compiling" = yes; then :
7998 else
7999 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8000 /* end confdefs.h. */
8001 #include <ctype.h>
8002 #include <stdlib.h>
8003 #if ((' ' & 0x0FF) == 0x020)
8004 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
8005 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
8006 #else
8007 # define ISLOWER(c) \
8008 (('a' <= (c) && (c) <= 'i') \
8009 || ('j' <= (c) && (c) <= 'r') \
8010 || ('s' <= (c) && (c) <= 'z'))
8011 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
8012 #endif
8014 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
8016 main ()
8018 int i;
8019 for (i = 0; i < 256; i++)
8020 if (XOR (islower (i), ISLOWER (i))
8021 || toupper (i) != TOUPPER (i))
8022 return 2;
8023 return 0;
8025 _ACEOF
8026 if ac_fn_c_try_run "$LINENO"; then :
8028 else
8029 ac_cv_header_stdc=no
8031 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8032 conftest.$ac_objext conftest.beam conftest.$ac_ext
8037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
8038 $as_echo "$ac_cv_header_stdc" >&6; }
8039 if test $ac_cv_header_stdc = yes; then
8041 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
8045 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
8046 # for constant arguments. Useless!
8047 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
8048 $as_echo_n "checking for working alloca.h... " >&6; }
8049 if ${ac_cv_working_alloca_h+:} false; then :
8050 $as_echo_n "(cached) " >&6
8051 else
8052 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8053 /* end confdefs.h. */
8054 #include <alloca.h>
8056 main ()
8058 char *p = (char *) alloca (2 * sizeof (int));
8059 if (p) return 0;
8061 return 0;
8063 _ACEOF
8064 if ac_fn_c_try_link "$LINENO"; then :
8065 ac_cv_working_alloca_h=yes
8066 else
8067 ac_cv_working_alloca_h=no
8069 rm -f core conftest.err conftest.$ac_objext \
8070 conftest$ac_exeext conftest.$ac_ext
8072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
8073 $as_echo "$ac_cv_working_alloca_h" >&6; }
8074 if test $ac_cv_working_alloca_h = yes; then
8076 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
8080 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
8081 $as_echo_n "checking for alloca... " >&6; }
8082 if ${ac_cv_func_alloca_works+:} false; then :
8083 $as_echo_n "(cached) " >&6
8084 else
8085 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8086 /* end confdefs.h. */
8087 #ifdef __GNUC__
8088 # define alloca __builtin_alloca
8089 #else
8090 # ifdef _MSC_VER
8091 # include <malloc.h>
8092 # define alloca _alloca
8093 # else
8094 # ifdef HAVE_ALLOCA_H
8095 # include <alloca.h>
8096 # else
8097 # ifdef _AIX
8098 #pragma alloca
8099 # else
8100 # ifndef alloca /* predefined by HP cc +Olibcalls */
8101 void *alloca (size_t);
8102 # endif
8103 # endif
8104 # endif
8105 # endif
8106 #endif
8109 main ()
8111 char *p = (char *) alloca (1);
8112 if (p) return 0;
8114 return 0;
8116 _ACEOF
8117 if ac_fn_c_try_link "$LINENO"; then :
8118 ac_cv_func_alloca_works=yes
8119 else
8120 ac_cv_func_alloca_works=no
8122 rm -f core conftest.err conftest.$ac_objext \
8123 conftest$ac_exeext conftest.$ac_ext
8125 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
8126 $as_echo "$ac_cv_func_alloca_works" >&6; }
8128 if test $ac_cv_func_alloca_works = yes; then
8130 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
8132 else
8133 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
8134 # that cause trouble. Some versions do not even contain alloca or
8135 # contain a buggy version. If you still want to use their alloca,
8136 # use ar to extract alloca.o from them instead of compiling alloca.c.
8138 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
8140 $as_echo "#define C_ALLOCA 1" >>confdefs.h
8143 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5
8144 $as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; }
8145 if ${ac_cv_os_cray+:} false; then :
8146 $as_echo_n "(cached) " >&6
8147 else
8148 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8149 /* end confdefs.h. */
8150 #if defined CRAY && ! defined CRAY2
8151 webecray
8152 #else
8153 wenotbecray
8154 #endif
8156 _ACEOF
8157 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8158 $EGREP "webecray" >/dev/null 2>&1; then :
8159 ac_cv_os_cray=yes
8160 else
8161 ac_cv_os_cray=no
8163 rm -f conftest*
8166 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
8167 $as_echo "$ac_cv_os_cray" >&6; }
8168 if test $ac_cv_os_cray = yes; then
8169 for ac_func in _getb67 GETB67 getb67; do
8170 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
8171 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
8172 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
8174 cat >>confdefs.h <<_ACEOF
8175 #define CRAY_STACKSEG_END $ac_func
8176 _ACEOF
8178 break
8181 done
8184 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
8185 $as_echo_n "checking stack direction for C alloca... " >&6; }
8186 if ${ac_cv_c_stack_direction+:} false; then :
8187 $as_echo_n "(cached) " >&6
8188 else
8189 if test "$cross_compiling" = yes; then :
8190 ac_cv_c_stack_direction=0
8191 else
8192 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8193 /* end confdefs.h. */
8194 $ac_includes_default
8196 find_stack_direction (int *addr, int depth)
8198 int dir, dummy = 0;
8199 if (! addr)
8200 addr = &dummy;
8201 *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
8202 dir = depth ? find_stack_direction (addr, depth - 1) : 0;
8203 return dir + dummy;
8207 main (int argc, char **argv)
8209 return find_stack_direction (0, argc + !argv + 20) < 0;
8211 _ACEOF
8212 if ac_fn_c_try_run "$LINENO"; then :
8213 ac_cv_c_stack_direction=1
8214 else
8215 ac_cv_c_stack_direction=-1
8217 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8218 conftest.$ac_objext conftest.beam conftest.$ac_ext
8222 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
8223 $as_echo "$ac_cv_c_stack_direction" >&6; }
8224 cat >>confdefs.h <<_ACEOF
8225 #define STACK_DIRECTION $ac_cv_c_stack_direction
8226 _ACEOF
8232 WIN32APILIBS=
8233 case ${host} in
8234 *mingw32*)
8236 $as_echo "#define USE_WIN32API 1" >>confdefs.h
8238 WIN32APILIBS="-lws2_32"
8240 esac
8243 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
8244 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
8245 if ${am_cv_langinfo_codeset+:} false; then :
8246 $as_echo_n "(cached) " >&6
8247 else
8248 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8249 /* end confdefs.h. */
8250 #include <langinfo.h>
8252 main ()
8254 char* cs = nl_langinfo(CODESET);
8256 return 0;
8258 _ACEOF
8259 if ac_fn_c_try_link "$LINENO"; then :
8260 am_cv_langinfo_codeset=yes
8261 else
8262 am_cv_langinfo_codeset=no
8264 rm -f core conftest.err conftest.$ac_objext \
8265 conftest$ac_exeext conftest.$ac_ext
8268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_langinfo_codeset" >&5
8269 $as_echo "$am_cv_langinfo_codeset" >&6; }
8270 if test $am_cv_langinfo_codeset = yes; then
8272 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
8277 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
8278 do :
8279 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8280 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
8281 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
8282 cat >>confdefs.h <<_ACEOF
8283 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8284 _ACEOF
8288 done
8292 for ac_func in getpagesize
8293 do :
8294 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
8295 if test "x$ac_cv_func_getpagesize" = xyes; then :
8296 cat >>confdefs.h <<_ACEOF
8297 #define HAVE_GETPAGESIZE 1
8298 _ACEOF
8301 done
8303 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
8304 $as_echo_n "checking for working mmap... " >&6; }
8305 if ${ac_cv_func_mmap_fixed_mapped+:} false; then :
8306 $as_echo_n "(cached) " >&6
8307 else
8308 if test "$cross_compiling" = yes; then :
8309 ac_cv_func_mmap_fixed_mapped=no
8310 else
8311 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8312 /* end confdefs.h. */
8313 $ac_includes_default
8314 /* malloc might have been renamed as rpl_malloc. */
8315 #undef malloc
8317 /* Thanks to Mike Haertel and Jim Avera for this test.
8318 Here is a matrix of mmap possibilities:
8319 mmap private not fixed
8320 mmap private fixed at somewhere currently unmapped
8321 mmap private fixed at somewhere already mapped
8322 mmap shared not fixed
8323 mmap shared fixed at somewhere currently unmapped
8324 mmap shared fixed at somewhere already mapped
8325 For private mappings, we should verify that changes cannot be read()
8326 back from the file, nor mmap's back from the file at a different
8327 address. (There have been systems where private was not correctly
8328 implemented like the infamous i386 svr4.0, and systems where the
8329 VM page cache was not coherent with the file system buffer cache
8330 like early versions of FreeBSD and possibly contemporary NetBSD.)
8331 For shared mappings, we should conversely verify that changes get
8332 propagated back to all the places they're supposed to be.
8334 Grep wants private fixed already mapped.
8335 The main things grep needs to know about mmap are:
8336 * does it exist and is it safe to write into the mmap'd area
8337 * how to use it (BSD variants) */
8339 #include <fcntl.h>
8340 #include <sys/mman.h>
8342 #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
8343 char *malloc ();
8344 #endif
8346 /* This mess was copied from the GNU getpagesize.h. */
8347 #ifndef HAVE_GETPAGESIZE
8348 # ifdef _SC_PAGESIZE
8349 # define getpagesize() sysconf(_SC_PAGESIZE)
8350 # else /* no _SC_PAGESIZE */
8351 # ifdef HAVE_SYS_PARAM_H
8352 # include <sys/param.h>
8353 # ifdef EXEC_PAGESIZE
8354 # define getpagesize() EXEC_PAGESIZE
8355 # else /* no EXEC_PAGESIZE */
8356 # ifdef NBPG
8357 # define getpagesize() NBPG * CLSIZE
8358 # ifndef CLSIZE
8359 # define CLSIZE 1
8360 # endif /* no CLSIZE */
8361 # else /* no NBPG */
8362 # ifdef NBPC
8363 # define getpagesize() NBPC
8364 # else /* no NBPC */
8365 # ifdef PAGESIZE
8366 # define getpagesize() PAGESIZE
8367 # endif /* PAGESIZE */
8368 # endif /* no NBPC */
8369 # endif /* no NBPG */
8370 # endif /* no EXEC_PAGESIZE */
8371 # else /* no HAVE_SYS_PARAM_H */
8372 # define getpagesize() 8192 /* punt totally */
8373 # endif /* no HAVE_SYS_PARAM_H */
8374 # endif /* no _SC_PAGESIZE */
8376 #endif /* no HAVE_GETPAGESIZE */
8379 main ()
8381 char *data, *data2, *data3;
8382 const char *cdata2;
8383 int i, pagesize;
8384 int fd, fd2;
8386 pagesize = getpagesize ();
8388 /* First, make a file with some known garbage in it. */
8389 data = (char *) malloc (pagesize);
8390 if (!data)
8391 return 1;
8392 for (i = 0; i < pagesize; ++i)
8393 *(data + i) = rand ();
8394 umask (0);
8395 fd = creat ("conftest.mmap", 0600);
8396 if (fd < 0)
8397 return 2;
8398 if (write (fd, data, pagesize) != pagesize)
8399 return 3;
8400 close (fd);
8402 /* Next, check that the tail of a page is zero-filled. File must have
8403 non-zero length, otherwise we risk SIGBUS for entire page. */
8404 fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
8405 if (fd2 < 0)
8406 return 4;
8407 cdata2 = "";
8408 if (write (fd2, cdata2, 1) != 1)
8409 return 5;
8410 data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
8411 if (data2 == MAP_FAILED)
8412 return 6;
8413 for (i = 0; i < pagesize; ++i)
8414 if (*(data2 + i))
8415 return 7;
8416 close (fd2);
8417 if (munmap (data2, pagesize))
8418 return 8;
8420 /* Next, try to mmap the file at a fixed address which already has
8421 something else allocated at it. If we can, also make sure that
8422 we see the same garbage. */
8423 fd = open ("conftest.mmap", O_RDWR);
8424 if (fd < 0)
8425 return 9;
8426 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
8427 MAP_PRIVATE | MAP_FIXED, fd, 0L))
8428 return 10;
8429 for (i = 0; i < pagesize; ++i)
8430 if (*(data + i) != *(data2 + i))
8431 return 11;
8433 /* Finally, make sure that changes to the mapped area do not
8434 percolate back to the file as seen by read(). (This is a bug on
8435 some variants of i386 svr4.0.) */
8436 for (i = 0; i < pagesize; ++i)
8437 *(data2 + i) = *(data2 + i) + 1;
8438 data3 = (char *) malloc (pagesize);
8439 if (!data3)
8440 return 12;
8441 if (read (fd, data3, pagesize) != pagesize)
8442 return 13;
8443 for (i = 0; i < pagesize; ++i)
8444 if (*(data + i) != *(data3 + i))
8445 return 14;
8446 close (fd);
8447 return 0;
8449 _ACEOF
8450 if ac_fn_c_try_run "$LINENO"; then :
8451 ac_cv_func_mmap_fixed_mapped=yes
8452 else
8453 ac_cv_func_mmap_fixed_mapped=no
8455 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8456 conftest.$ac_objext conftest.beam conftest.$ac_ext
8460 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
8461 $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
8462 if test $ac_cv_func_mmap_fixed_mapped = yes; then
8464 $as_echo "#define HAVE_MMAP 1" >>confdefs.h
8467 rm -f conftest.mmap conftest.txt
8469 for ac_header in vfork.h
8470 do :
8471 ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
8472 if test "x$ac_cv_header_vfork_h" = xyes; then :
8473 cat >>confdefs.h <<_ACEOF
8474 #define HAVE_VFORK_H 1
8475 _ACEOF
8479 done
8481 for ac_func in fork vfork
8482 do :
8483 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
8484 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
8485 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
8486 cat >>confdefs.h <<_ACEOF
8487 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
8488 _ACEOF
8491 done
8493 if test "x$ac_cv_func_fork" = xyes; then
8494 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
8495 $as_echo_n "checking for working fork... " >&6; }
8496 if ${ac_cv_func_fork_works+:} false; then :
8497 $as_echo_n "(cached) " >&6
8498 else
8499 if test "$cross_compiling" = yes; then :
8500 ac_cv_func_fork_works=cross
8501 else
8502 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8503 /* end confdefs.h. */
8504 $ac_includes_default
8506 main ()
8509 /* By Ruediger Kuhlmann. */
8510 return fork () < 0;
8513 return 0;
8515 _ACEOF
8516 if ac_fn_c_try_run "$LINENO"; then :
8517 ac_cv_func_fork_works=yes
8518 else
8519 ac_cv_func_fork_works=no
8521 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8522 conftest.$ac_objext conftest.beam conftest.$ac_ext
8526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
8527 $as_echo "$ac_cv_func_fork_works" >&6; }
8529 else
8530 ac_cv_func_fork_works=$ac_cv_func_fork
8532 if test "x$ac_cv_func_fork_works" = xcross; then
8533 case $host in
8534 *-*-amigaos* | *-*-msdosdjgpp*)
8535 # Override, as these systems have only a dummy fork() stub
8536 ac_cv_func_fork_works=no
8539 ac_cv_func_fork_works=yes
8541 esac
8542 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
8543 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
8545 ac_cv_func_vfork_works=$ac_cv_func_vfork
8546 if test "x$ac_cv_func_vfork" = xyes; then
8547 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
8548 $as_echo_n "checking for working vfork... " >&6; }
8549 if ${ac_cv_func_vfork_works+:} false; then :
8550 $as_echo_n "(cached) " >&6
8551 else
8552 if test "$cross_compiling" = yes; then :
8553 ac_cv_func_vfork_works=cross
8554 else
8555 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8556 /* end confdefs.h. */
8557 /* Thanks to Paul Eggert for this test. */
8558 $ac_includes_default
8559 #include <sys/wait.h>
8560 #ifdef HAVE_VFORK_H
8561 # include <vfork.h>
8562 #endif
8563 /* On some sparc systems, changes by the child to local and incoming
8564 argument registers are propagated back to the parent. The compiler
8565 is told about this with #include <vfork.h>, but some compilers
8566 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
8567 static variable whose address is put into a register that is
8568 clobbered by the vfork. */
8569 static void
8570 #ifdef __cplusplus
8571 sparc_address_test (int arg)
8572 # else
8573 sparc_address_test (arg) int arg;
8574 #endif
8576 static pid_t child;
8577 if (!child) {
8578 child = vfork ();
8579 if (child < 0) {
8580 perror ("vfork");
8581 _exit(2);
8583 if (!child) {
8584 arg = getpid();
8585 write(-1, "", 0);
8586 _exit (arg);
8592 main ()
8594 pid_t parent = getpid ();
8595 pid_t child;
8597 sparc_address_test (0);
8599 child = vfork ();
8601 if (child == 0) {
8602 /* Here is another test for sparc vfork register problems. This
8603 test uses lots of local variables, at least as many local
8604 variables as main has allocated so far including compiler
8605 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
8606 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
8607 reuse the register of parent for one of the local variables,
8608 since it will think that parent can't possibly be used any more
8609 in this routine. Assigning to the local variable will thus
8610 munge parent in the parent process. */
8611 pid_t
8612 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
8613 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
8614 /* Convince the compiler that p..p7 are live; otherwise, it might
8615 use the same hardware register for all 8 local variables. */
8616 if (p != p1 || p != p2 || p != p3 || p != p4
8617 || p != p5 || p != p6 || p != p7)
8618 _exit(1);
8620 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
8621 from child file descriptors. If the child closes a descriptor
8622 before it execs or exits, this munges the parent's descriptor
8623 as well. Test for this by closing stdout in the child. */
8624 _exit(close(fileno(stdout)) != 0);
8625 } else {
8626 int status;
8627 struct stat st;
8629 while (wait(&status) != child)
8631 return (
8632 /* Was there some problem with vforking? */
8633 child < 0
8635 /* Did the child fail? (This shouldn't happen.) */
8636 || status
8638 /* Did the vfork/compiler bug occur? */
8639 || parent != getpid()
8641 /* Did the file descriptor bug occur? */
8642 || fstat(fileno(stdout), &st) != 0
8646 _ACEOF
8647 if ac_fn_c_try_run "$LINENO"; then :
8648 ac_cv_func_vfork_works=yes
8649 else
8650 ac_cv_func_vfork_works=no
8652 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8653 conftest.$ac_objext conftest.beam conftest.$ac_ext
8657 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
8658 $as_echo "$ac_cv_func_vfork_works" >&6; }
8661 if test "x$ac_cv_func_fork_works" = xcross; then
8662 ac_cv_func_vfork_works=$ac_cv_func_vfork
8663 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
8664 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
8667 if test "x$ac_cv_func_vfork_works" = xyes; then
8669 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
8671 else
8673 $as_echo "#define vfork fork" >>confdefs.h
8676 if test "x$ac_cv_func_fork_works" = xyes; then
8678 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
8682 # Some systems (e.g. Solaris) have `socketpair' in libsocket.
8683 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing socketpair" >&5
8684 $as_echo_n "checking for library containing socketpair... " >&6; }
8685 if ${ac_cv_search_socketpair+:} false; then :
8686 $as_echo_n "(cached) " >&6
8687 else
8688 ac_func_search_save_LIBS=$LIBS
8689 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8690 /* end confdefs.h. */
8692 /* Override any GCC internal prototype to avoid an error.
8693 Use char because int might match the return type of a GCC
8694 builtin and then its argument prototype would still apply. */
8695 #ifdef __cplusplus
8696 extern "C"
8697 #endif
8698 char socketpair ();
8700 main ()
8702 return socketpair ();
8704 return 0;
8706 _ACEOF
8707 for ac_lib in '' socket; do
8708 if test -z "$ac_lib"; then
8709 ac_res="none required"
8710 else
8711 ac_res=-l$ac_lib
8712 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
8714 if ac_fn_c_try_link "$LINENO"; then :
8715 ac_cv_search_socketpair=$ac_res
8717 rm -f core conftest.err conftest.$ac_objext \
8718 conftest$ac_exeext
8719 if ${ac_cv_search_socketpair+:} false; then :
8720 break
8722 done
8723 if ${ac_cv_search_socketpair+:} false; then :
8725 else
8726 ac_cv_search_socketpair=no
8728 rm conftest.$ac_ext
8729 LIBS=$ac_func_search_save_LIBS
8731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_socketpair" >&5
8732 $as_echo "$ac_cv_search_socketpair" >&6; }
8733 ac_res=$ac_cv_search_socketpair
8734 if test "$ac_res" != no; then :
8735 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8739 for ac_func in fdwalk getrlimit pipe pipe2 poll socketpair sigaction \
8740 ptrace64 sbrk setns sigaltstack sigprocmask \
8741 setpgid setpgrp getrusage getauxval sigtimedwait
8742 do :
8743 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
8744 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
8745 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
8746 cat >>confdefs.h <<_ACEOF
8747 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
8748 _ACEOF
8751 done
8754 # This is needed for RHEL 5 and uclibc-ng < 1.0.39.
8755 # These did not define ADDR_NO_RANDOMIZE in sys/personality.h,
8756 # only in linux/personality.h.
8757 ac_fn_c_check_decl "$LINENO" "ADDR_NO_RANDOMIZE" "ac_cv_have_decl_ADDR_NO_RANDOMIZE" "#include <sys/personality.h>
8759 if test "x$ac_cv_have_decl_ADDR_NO_RANDOMIZE" = xyes; then :
8760 ac_have_decl=1
8761 else
8762 ac_have_decl=0
8765 cat >>confdefs.h <<_ACEOF
8766 #define HAVE_DECL_ADDR_NO_RANDOMIZE $ac_have_decl
8767 _ACEOF
8770 ac_fn_c_check_decl "$LINENO" "strstr" "ac_cv_have_decl_strstr" "$ac_includes_default"
8771 if test "x$ac_cv_have_decl_strstr" = xyes; then :
8772 ac_have_decl=1
8773 else
8774 ac_have_decl=0
8777 cat >>confdefs.h <<_ACEOF
8778 #define HAVE_DECL_STRSTR $ac_have_decl
8779 _ACEOF
8782 # ----------------------- #
8783 # Checks for structures. #
8784 # ----------------------- #
8786 ac_fn_c_check_member "$LINENO" "struct stat" "st_blocks" "ac_cv_member_struct_stat_st_blocks" "$ac_includes_default"
8787 if test "x$ac_cv_member_struct_stat_st_blocks" = xyes; then :
8789 cat >>confdefs.h <<_ACEOF
8790 #define HAVE_STRUCT_STAT_ST_BLOCKS 1
8791 _ACEOF
8795 ac_fn_c_check_member "$LINENO" "struct stat" "st_blksize" "ac_cv_member_struct_stat_st_blksize" "$ac_includes_default"
8796 if test "x$ac_cv_member_struct_stat_st_blksize" = xyes; then :
8798 cat >>confdefs.h <<_ACEOF
8799 #define HAVE_STRUCT_STAT_ST_BLKSIZE 1
8800 _ACEOF
8806 # On FreeBSD we need libutil for the kinfo_get* functions. On
8807 # GNU/kFreeBSD systems, FreeBSD libutil is renamed to libutil-freebsd.
8808 # Figure out which one to use.
8809 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing kinfo_getfile" >&5
8810 $as_echo_n "checking for library containing kinfo_getfile... " >&6; }
8811 if ${ac_cv_search_kinfo_getfile+:} false; then :
8812 $as_echo_n "(cached) " >&6
8813 else
8814 ac_func_search_save_LIBS=$LIBS
8815 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8816 /* end confdefs.h. */
8818 /* Override any GCC internal prototype to avoid an error.
8819 Use char because int might match the return type of a GCC
8820 builtin and then its argument prototype would still apply. */
8821 #ifdef __cplusplus
8822 extern "C"
8823 #endif
8824 char kinfo_getfile ();
8826 main ()
8828 return kinfo_getfile ();
8830 return 0;
8832 _ACEOF
8833 for ac_lib in '' util util-freebsd; do
8834 if test -z "$ac_lib"; then
8835 ac_res="none required"
8836 else
8837 ac_res=-l$ac_lib
8838 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
8840 if ac_fn_c_try_link "$LINENO"; then :
8841 ac_cv_search_kinfo_getfile=$ac_res
8843 rm -f core conftest.err conftest.$ac_objext \
8844 conftest$ac_exeext
8845 if ${ac_cv_search_kinfo_getfile+:} false; then :
8846 break
8848 done
8849 if ${ac_cv_search_kinfo_getfile+:} false; then :
8851 else
8852 ac_cv_search_kinfo_getfile=no
8854 rm conftest.$ac_ext
8855 LIBS=$ac_func_search_save_LIBS
8857 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_kinfo_getfile" >&5
8858 $as_echo "$ac_cv_search_kinfo_getfile" >&6; }
8859 ac_res=$ac_cv_search_kinfo_getfile
8860 if test "$ac_res" != no; then :
8861 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8866 # Define HAVE_KINFO_GETFILE if kinfo_getfile is available.
8867 for ac_func in kinfo_getfile
8868 do :
8869 ac_fn_c_check_func "$LINENO" "kinfo_getfile" "ac_cv_func_kinfo_getfile"
8870 if test "x$ac_cv_func_kinfo_getfile" = xyes; then :
8871 cat >>confdefs.h <<_ACEOF
8872 #define HAVE_KINFO_GETFILE 1
8873 _ACEOF
8876 done
8879 # ----------------------- #
8880 # Check for threading. #
8881 # ----------------------- #
8883 # Check whether --enable-threading was given.
8884 if test "${enable_threading+set}" = set; then :
8885 enableval=$enable_threading; case "$enableval" in
8886 yes) want_threading=yes ;;
8887 no) want_threading=no ;;
8888 *) as_fn_error $? "bad value $enableval for threading" "$LINENO" 5 ;;
8889 esac
8890 else
8891 want_threading=auto
8895 # Check for std::thread. This does not work on some platforms, like
8896 # mingw using the win32 threads model with gcc older than 13, and
8897 # DJGPP.
8898 ac_ext=cpp
8899 ac_cpp='$CXXCPP $CPPFLAGS'
8900 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
8901 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
8902 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
8908 ac_ext=c
8909 ac_cpp='$CPP $CPPFLAGS'
8910 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
8911 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
8912 ac_compiler_gnu=$ac_cv_c_compiler_gnu
8914 ax_pthread_ok=no
8916 # We used to check for pthread.h first, but this fails if pthread.h
8917 # requires special compiler flags (e.g. on Tru64 or Sequent).
8918 # It gets checked for in the link test anyway.
8920 # First of all, check if the user has set any of the PTHREAD_LIBS,
8921 # etcetera environment variables, and if threads linking works using
8922 # them:
8923 if test "x$PTHREAD_CFLAGS$PTHREAD_LIBS" != "x"; then
8924 ax_pthread_save_CC="$CC"
8925 ax_pthread_save_CFLAGS="$CFLAGS"
8926 ax_pthread_save_LIBS="$LIBS"
8927 if test "x$PTHREAD_CC" != "x"; then :
8928 CC="$PTHREAD_CC"
8930 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
8931 LIBS="$PTHREAD_LIBS $LIBS"
8932 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_join using $CC $PTHREAD_CFLAGS $PTHREAD_LIBS" >&5
8933 $as_echo_n "checking for pthread_join using $CC $PTHREAD_CFLAGS $PTHREAD_LIBS... " >&6; }
8934 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8935 /* end confdefs.h. */
8937 /* Override any GCC internal prototype to avoid an error.
8938 Use char because int might match the return type of a GCC
8939 builtin and then its argument prototype would still apply. */
8940 #ifdef __cplusplus
8941 extern "C"
8942 #endif
8943 char pthread_join ();
8945 main ()
8947 return pthread_join ();
8949 return 0;
8951 _ACEOF
8952 if ac_fn_c_try_link "$LINENO"; then :
8953 ax_pthread_ok=yes
8955 rm -f core conftest.err conftest.$ac_objext \
8956 conftest$ac_exeext conftest.$ac_ext
8957 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5
8958 $as_echo "$ax_pthread_ok" >&6; }
8959 if test "x$ax_pthread_ok" = "xno"; then
8960 PTHREAD_LIBS=""
8961 PTHREAD_CFLAGS=""
8963 CC="$ax_pthread_save_CC"
8964 CFLAGS="$ax_pthread_save_CFLAGS"
8965 LIBS="$ax_pthread_save_LIBS"
8968 # We must check for the threads library under a number of different
8969 # names; the ordering is very important because some systems
8970 # (e.g. DEC) have both -lpthread and -lpthreads, where one of the
8971 # libraries is broken (non-POSIX).
8973 # Create a list of thread flags to try. Items starting with a "-" are
8974 # C compiler flags, and other items are library names, except for "none"
8975 # which indicates that we try without any flags at all, and "pthread-config"
8976 # which is a program returning the flags for the Pth emulation library.
8978 ax_pthread_flags="pthreads none -Kthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config"
8980 # The ordering *is* (sometimes) important. Some notes on the
8981 # individual items follow:
8983 # pthreads: AIX (must check this before -lpthread)
8984 # none: in case threads are in libc; should be tried before -Kthread and
8985 # other compiler flags to prevent continual compiler warnings
8986 # -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
8987 # -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads), Tru64
8988 # (Note: HP C rejects this with "bad form for `-t' option")
8989 # -pthreads: Solaris/gcc (Note: HP C also rejects)
8990 # -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
8991 # doesn't hurt to check since this sometimes defines pthreads and
8992 # -D_REENTRANT too), HP C (must be checked before -lpthread, which
8993 # is present but should not be used directly; and before -mthreads,
8994 # because the compiler interprets this as "-mt" + "-hreads")
8995 # -mthreads: Mingw32/gcc, Lynx/gcc
8996 # pthread: Linux, etcetera
8997 # --thread-safe: KAI C++
8998 # pthread-config: use pthread-config program (for GNU Pth library)
9000 case $host_os in
9002 freebsd*)
9004 # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
9005 # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
9007 ax_pthread_flags="-kthread lthread $ax_pthread_flags"
9010 hpux*)
9012 # From the cc(1) man page: "[-mt] Sets various -D flags to enable
9013 # multi-threading and also sets -lpthread."
9015 ax_pthread_flags="-mt -pthread pthread $ax_pthread_flags"
9018 openedition*)
9020 # IBM z/OS requires a feature-test macro to be defined in order to
9021 # enable POSIX threads at all, so give the user a hint if this is
9022 # not set. (We don't define these ourselves, as they can affect
9023 # other portions of the system API in unpredictable ways.)
9025 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9026 /* end confdefs.h. */
9028 # if !defined(_OPEN_THREADS) && !defined(_UNIX03_THREADS)
9029 AX_PTHREAD_ZOS_MISSING
9030 # endif
9032 _ACEOF
9033 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9034 $EGREP "AX_PTHREAD_ZOS_MISSING" >/dev/null 2>&1; then :
9035 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: IBM z/OS requires -D_OPEN_THREADS or -D_UNIX03_THREADS to enable pthreads support." >&5
9036 $as_echo "$as_me: WARNING: IBM z/OS requires -D_OPEN_THREADS or -D_UNIX03_THREADS to enable pthreads support." >&2;}
9038 rm -f conftest*
9042 solaris*)
9044 # On Solaris (at least, for some versions), libc contains stubbed
9045 # (non-functional) versions of the pthreads routines, so link-based
9046 # tests will erroneously succeed. (N.B.: The stubs are missing
9047 # pthread_cleanup_push, or rather a function called by this macro,
9048 # so we could check for that, but who knows whether they'll stub
9049 # that too in a future libc.) So we'll check first for the
9050 # standard Solaris way of linking pthreads (-mt -lpthread).
9052 ax_pthread_flags="-mt,pthread pthread $ax_pthread_flags"
9054 esac
9056 # GCC generally uses -pthread, or -pthreads on some platforms (e.g. SPARC)
9058 if test "x$GCC" = "xyes"; then :
9059 ax_pthread_flags="-pthread -pthreads $ax_pthread_flags"
9062 # The presence of a feature test macro requesting re-entrant function
9063 # definitions is, on some systems, a strong hint that pthreads support is
9064 # correctly enabled
9066 case $host_os in
9067 darwin* | hpux* | linux* | osf* | solaris*)
9068 ax_pthread_check_macro="_REENTRANT"
9071 aix*)
9072 ax_pthread_check_macro="_THREAD_SAFE"
9076 ax_pthread_check_macro="--"
9078 esac
9079 if test "x$ax_pthread_check_macro" = "x--"; then :
9080 ax_pthread_check_cond=0
9081 else
9082 ax_pthread_check_cond="!defined($ax_pthread_check_macro)"
9085 # Are we compiling with Clang?
9087 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC is Clang" >&5
9088 $as_echo_n "checking whether $CC is Clang... " >&6; }
9089 if ${ax_cv_PTHREAD_CLANG+:} false; then :
9090 $as_echo_n "(cached) " >&6
9091 else
9092 ax_cv_PTHREAD_CLANG=no
9093 # Note that Autoconf sets GCC=yes for Clang as well as GCC
9094 if test "x$GCC" = "xyes"; then
9095 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9096 /* end confdefs.h. */
9097 /* Note: Clang 2.7 lacks __clang_[a-z]+__ */
9098 # if defined(__clang__) && defined(__llvm__)
9099 AX_PTHREAD_CC_IS_CLANG
9100 # endif
9102 _ACEOF
9103 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9104 $EGREP "AX_PTHREAD_CC_IS_CLANG" >/dev/null 2>&1; then :
9105 ax_cv_PTHREAD_CLANG=yes
9107 rm -f conftest*
9112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_CLANG" >&5
9113 $as_echo "$ax_cv_PTHREAD_CLANG" >&6; }
9114 ax_pthread_clang="$ax_cv_PTHREAD_CLANG"
9116 ax_pthread_clang_warning=no
9118 # Clang needs special handling, because older versions handle the -pthread
9119 # option in a rather... idiosyncratic way
9121 if test "x$ax_pthread_clang" = "xyes"; then
9123 # Clang takes -pthread; it has never supported any other flag
9125 # (Note 1: This will need to be revisited if a system that Clang
9126 # supports has POSIX threads in a separate library. This tends not
9127 # to be the way of modern systems, but it's conceivable.)
9129 # (Note 2: On some systems, notably Darwin, -pthread is not needed
9130 # to get POSIX threads support; the API is always present and
9131 # active. We could reasonably leave PTHREAD_CFLAGS empty. But
9132 # -pthread does define _REENTRANT, and while the Darwin headers
9133 # ignore this macro, third-party headers might not.)
9135 PTHREAD_CFLAGS="-pthread"
9136 PTHREAD_LIBS=
9138 ax_pthread_ok=yes
9140 # However, older versions of Clang make a point of warning the user
9141 # that, in an invocation where only linking and no compilation is
9142 # taking place, the -pthread option has no effect ("argument unused
9143 # during compilation"). They expect -pthread to be passed in only
9144 # when source code is being compiled.
9146 # Problem is, this is at odds with the way Automake and most other
9147 # C build frameworks function, which is that the same flags used in
9148 # compilation (CFLAGS) are also used in linking. Many systems
9149 # supported by AX_PTHREAD require exactly this for POSIX threads
9150 # support, and in fact it is often not straightforward to specify a
9151 # flag that is used only in the compilation phase and not in
9152 # linking. Such a scenario is extremely rare in practice.
9154 # Even though use of the -pthread flag in linking would only print
9155 # a warning, this can be a nuisance for well-run software projects
9156 # that build with -Werror. So if the active version of Clang has
9157 # this misfeature, we search for an option to squash it.
9159 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether Clang needs flag to prevent \"argument unused\" warning when linking with -pthread" >&5
9160 $as_echo_n "checking whether Clang needs flag to prevent \"argument unused\" warning when linking with -pthread... " >&6; }
9161 if ${ax_cv_PTHREAD_CLANG_NO_WARN_FLAG+:} false; then :
9162 $as_echo_n "(cached) " >&6
9163 else
9164 ax_cv_PTHREAD_CLANG_NO_WARN_FLAG=unknown
9165 # Create an alternate version of $ac_link that compiles and
9166 # links in two steps (.c -> .o, .o -> exe) instead of one
9167 # (.c -> exe), because the warning occurs only in the second
9168 # step
9169 ax_pthread_save_ac_link="$ac_link"
9170 ax_pthread_sed='s/conftest\.\$ac_ext/conftest.$ac_objext/g'
9171 ax_pthread_link_step=`$as_echo "$ac_link" | sed "$ax_pthread_sed"`
9172 ax_pthread_2step_ac_link="($ac_compile) && (echo ==== >&5) && ($ax_pthread_link_step)"
9173 ax_pthread_save_CFLAGS="$CFLAGS"
9174 for ax_pthread_try in '' -Qunused-arguments -Wno-unused-command-line-argument unknown; do
9175 if test "x$ax_pthread_try" = "xunknown"; then :
9176 break
9178 CFLAGS="-Werror -Wunknown-warning-option $ax_pthread_try -pthread $ax_pthread_save_CFLAGS"
9179 ac_link="$ax_pthread_save_ac_link"
9180 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9181 /* end confdefs.h. */
9182 int main(void){return 0;}
9183 _ACEOF
9184 if ac_fn_c_try_link "$LINENO"; then :
9185 ac_link="$ax_pthread_2step_ac_link"
9186 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9187 /* end confdefs.h. */
9188 int main(void){return 0;}
9189 _ACEOF
9190 if ac_fn_c_try_link "$LINENO"; then :
9191 break
9193 rm -f core conftest.err conftest.$ac_objext \
9194 conftest$ac_exeext conftest.$ac_ext
9197 rm -f core conftest.err conftest.$ac_objext \
9198 conftest$ac_exeext conftest.$ac_ext
9199 done
9200 ac_link="$ax_pthread_save_ac_link"
9201 CFLAGS="$ax_pthread_save_CFLAGS"
9202 if test "x$ax_pthread_try" = "x"; then :
9203 ax_pthread_try=no
9205 ax_cv_PTHREAD_CLANG_NO_WARN_FLAG="$ax_pthread_try"
9208 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" >&5
9209 $as_echo "$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" >&6; }
9211 case "$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" in
9212 no | unknown) ;;
9213 *) PTHREAD_CFLAGS="$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG $PTHREAD_CFLAGS" ;;
9214 esac
9216 fi # $ax_pthread_clang = yes
9218 if test "x$ax_pthread_ok" = "xno"; then
9219 for ax_pthread_try_flag in $ax_pthread_flags; do
9221 case $ax_pthread_try_flag in
9222 none)
9223 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work without any flags" >&5
9224 $as_echo_n "checking whether pthreads work without any flags... " >&6; }
9227 -mt,pthread)
9228 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with -mt -lpthread" >&5
9229 $as_echo_n "checking whether pthreads work with -mt -lpthread... " >&6; }
9230 PTHREAD_CFLAGS="-mt"
9231 PTHREAD_LIBS="-lpthread"
9235 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with $ax_pthread_try_flag" >&5
9236 $as_echo_n "checking whether pthreads work with $ax_pthread_try_flag... " >&6; }
9237 PTHREAD_CFLAGS="$ax_pthread_try_flag"
9240 pthread-config)
9241 # Extract the first word of "pthread-config", so it can be a program name with args.
9242 set dummy pthread-config; ac_word=$2
9243 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9244 $as_echo_n "checking for $ac_word... " >&6; }
9245 if ${ac_cv_prog_ax_pthread_config+:} false; then :
9246 $as_echo_n "(cached) " >&6
9247 else
9248 if test -n "$ax_pthread_config"; then
9249 ac_cv_prog_ax_pthread_config="$ax_pthread_config" # Let the user override the test.
9250 else
9251 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9252 for as_dir in $PATH
9254 IFS=$as_save_IFS
9255 test -z "$as_dir" && as_dir=.
9256 for ac_exec_ext in '' $ac_executable_extensions; do
9257 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9258 ac_cv_prog_ax_pthread_config="yes"
9259 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9260 break 2
9262 done
9263 done
9264 IFS=$as_save_IFS
9266 test -z "$ac_cv_prog_ax_pthread_config" && ac_cv_prog_ax_pthread_config="no"
9269 ax_pthread_config=$ac_cv_prog_ax_pthread_config
9270 if test -n "$ax_pthread_config"; then
9271 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_config" >&5
9272 $as_echo "$ax_pthread_config" >&6; }
9273 else
9274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9275 $as_echo "no" >&6; }
9279 if test "x$ax_pthread_config" = "xno"; then :
9280 continue
9282 PTHREAD_CFLAGS="`pthread-config --cflags`"
9283 PTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
9287 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the pthreads library -l$ax_pthread_try_flag" >&5
9288 $as_echo_n "checking for the pthreads library -l$ax_pthread_try_flag... " >&6; }
9289 PTHREAD_LIBS="-l$ax_pthread_try_flag"
9291 esac
9293 ax_pthread_save_CFLAGS="$CFLAGS"
9294 ax_pthread_save_LIBS="$LIBS"
9295 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
9296 LIBS="$PTHREAD_LIBS $LIBS"
9298 # Check for various functions. We must include pthread.h,
9299 # since some functions may be macros. (On the Sequent, we
9300 # need a special flag -Kthread to make this header compile.)
9301 # We check for pthread_join because it is in -lpthread on IRIX
9302 # while pthread_create is in libc. We check for pthread_attr_init
9303 # due to DEC craziness with -lpthreads. We check for
9304 # pthread_cleanup_push because it is one of the few pthread
9305 # functions on Solaris that doesn't have a non-functional libc stub.
9306 # We try pthread_create on general principles.
9308 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9309 /* end confdefs.h. */
9310 #include <pthread.h>
9311 # if $ax_pthread_check_cond
9312 # error "$ax_pthread_check_macro must be defined"
9313 # endif
9314 static void routine(void *a) { a = 0; }
9315 static void *start_routine(void *a) { return a; }
9317 main ()
9319 pthread_t th; pthread_attr_t attr;
9320 pthread_create(&th, 0, start_routine, 0);
9321 pthread_join(th, 0);
9322 pthread_attr_init(&attr);
9323 pthread_cleanup_push(routine, 0);
9324 pthread_cleanup_pop(0) /* ; */
9326 return 0;
9328 _ACEOF
9329 if ac_fn_c_try_link "$LINENO"; then :
9330 ax_pthread_ok=yes
9332 rm -f core conftest.err conftest.$ac_objext \
9333 conftest$ac_exeext conftest.$ac_ext
9335 CFLAGS="$ax_pthread_save_CFLAGS"
9336 LIBS="$ax_pthread_save_LIBS"
9338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5
9339 $as_echo "$ax_pthread_ok" >&6; }
9340 if test "x$ax_pthread_ok" = "xyes"; then :
9341 break
9344 PTHREAD_LIBS=""
9345 PTHREAD_CFLAGS=""
9346 done
9349 # Various other checks:
9350 if test "x$ax_pthread_ok" = "xyes"; then
9351 ax_pthread_save_CFLAGS="$CFLAGS"
9352 ax_pthread_save_LIBS="$LIBS"
9353 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
9354 LIBS="$PTHREAD_LIBS $LIBS"
9356 # Detect AIX lossage: JOINABLE attribute is called UNDETACHED.
9357 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for joinable pthread attribute" >&5
9358 $as_echo_n "checking for joinable pthread attribute... " >&6; }
9359 if ${ax_cv_PTHREAD_JOINABLE_ATTR+:} false; then :
9360 $as_echo_n "(cached) " >&6
9361 else
9362 ax_cv_PTHREAD_JOINABLE_ATTR=unknown
9363 for ax_pthread_attr in PTHREAD_CREATE_JOINABLE PTHREAD_CREATE_UNDETACHED; do
9364 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9365 /* end confdefs.h. */
9366 #include <pthread.h>
9368 main ()
9370 int attr = $ax_pthread_attr; return attr /* ; */
9372 return 0;
9374 _ACEOF
9375 if ac_fn_c_try_link "$LINENO"; then :
9376 ax_cv_PTHREAD_JOINABLE_ATTR=$ax_pthread_attr; break
9378 rm -f core conftest.err conftest.$ac_objext \
9379 conftest$ac_exeext conftest.$ac_ext
9380 done
9383 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_JOINABLE_ATTR" >&5
9384 $as_echo "$ax_cv_PTHREAD_JOINABLE_ATTR" >&6; }
9385 if test "x$ax_cv_PTHREAD_JOINABLE_ATTR" != "xunknown" && \
9386 test "x$ax_cv_PTHREAD_JOINABLE_ATTR" != "xPTHREAD_CREATE_JOINABLE" && \
9387 test "x$ax_pthread_joinable_attr_defined" != "xyes"; then :
9389 cat >>confdefs.h <<_ACEOF
9390 #define PTHREAD_CREATE_JOINABLE $ax_cv_PTHREAD_JOINABLE_ATTR
9391 _ACEOF
9393 ax_pthread_joinable_attr_defined=yes
9397 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether more special flags are required for pthreads" >&5
9398 $as_echo_n "checking whether more special flags are required for pthreads... " >&6; }
9399 if ${ax_cv_PTHREAD_SPECIAL_FLAGS+:} false; then :
9400 $as_echo_n "(cached) " >&6
9401 else
9402 ax_cv_PTHREAD_SPECIAL_FLAGS=no
9403 case $host_os in
9404 solaris*)
9405 ax_cv_PTHREAD_SPECIAL_FLAGS="-D_POSIX_PTHREAD_SEMANTICS"
9407 esac
9410 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_SPECIAL_FLAGS" >&5
9411 $as_echo "$ax_cv_PTHREAD_SPECIAL_FLAGS" >&6; }
9412 if test "x$ax_cv_PTHREAD_SPECIAL_FLAGS" != "xno" && \
9413 test "x$ax_pthread_special_flags_added" != "xyes"; then :
9414 PTHREAD_CFLAGS="$ax_cv_PTHREAD_SPECIAL_FLAGS $PTHREAD_CFLAGS"
9415 ax_pthread_special_flags_added=yes
9418 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTHREAD_PRIO_INHERIT" >&5
9419 $as_echo_n "checking for PTHREAD_PRIO_INHERIT... " >&6; }
9420 if ${ax_cv_PTHREAD_PRIO_INHERIT+:} false; then :
9421 $as_echo_n "(cached) " >&6
9422 else
9423 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9424 /* end confdefs.h. */
9425 #include <pthread.h>
9427 main ()
9429 int i = PTHREAD_PRIO_INHERIT;
9431 return 0;
9433 _ACEOF
9434 if ac_fn_c_try_link "$LINENO"; then :
9435 ax_cv_PTHREAD_PRIO_INHERIT=yes
9436 else
9437 ax_cv_PTHREAD_PRIO_INHERIT=no
9439 rm -f core conftest.err conftest.$ac_objext \
9440 conftest$ac_exeext conftest.$ac_ext
9443 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_PRIO_INHERIT" >&5
9444 $as_echo "$ax_cv_PTHREAD_PRIO_INHERIT" >&6; }
9445 if test "x$ax_cv_PTHREAD_PRIO_INHERIT" = "xyes" && \
9446 test "x$ax_pthread_prio_inherit_defined" != "xyes"; then :
9448 $as_echo "#define HAVE_PTHREAD_PRIO_INHERIT 1" >>confdefs.h
9450 ax_pthread_prio_inherit_defined=yes
9454 CFLAGS="$ax_pthread_save_CFLAGS"
9455 LIBS="$ax_pthread_save_LIBS"
9457 # More AIX lossage: compile with *_r variant
9458 if test "x$GCC" != "xyes"; then
9459 case $host_os in
9460 aix*)
9461 case "x/$CC" in #(
9462 x*/c89|x*/c89_128|x*/c99|x*/c99_128|x*/cc|x*/cc128|x*/xlc|x*/xlc_v6|x*/xlc128|x*/xlc128_v6) :
9463 #handle absolute path differently from PATH based program lookup
9464 case "x$CC" in #(
9465 x/*) :
9466 if as_fn_executable_p ${CC}_r; then :
9467 PTHREAD_CC="${CC}_r"
9468 fi ;; #(
9469 *) :
9470 for ac_prog in ${CC}_r
9472 # Extract the first word of "$ac_prog", so it can be a program name with args.
9473 set dummy $ac_prog; ac_word=$2
9474 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9475 $as_echo_n "checking for $ac_word... " >&6; }
9476 if ${ac_cv_prog_PTHREAD_CC+:} false; then :
9477 $as_echo_n "(cached) " >&6
9478 else
9479 if test -n "$PTHREAD_CC"; then
9480 ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
9481 else
9482 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9483 for as_dir in $PATH
9485 IFS=$as_save_IFS
9486 test -z "$as_dir" && as_dir=.
9487 for ac_exec_ext in '' $ac_executable_extensions; do
9488 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9489 ac_cv_prog_PTHREAD_CC="$ac_prog"
9490 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9491 break 2
9493 done
9494 done
9495 IFS=$as_save_IFS
9499 PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
9500 if test -n "$PTHREAD_CC"; then
9501 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PTHREAD_CC" >&5
9502 $as_echo "$PTHREAD_CC" >&6; }
9503 else
9504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9505 $as_echo "no" >&6; }
9509 test -n "$PTHREAD_CC" && break
9510 done
9511 test -n "$PTHREAD_CC" || PTHREAD_CC="$CC"
9513 esac ;; #(
9514 *) :
9516 esac
9518 esac
9522 test -n "$PTHREAD_CC" || PTHREAD_CC="$CC"
9528 # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
9529 if test "x$ax_pthread_ok" = "xyes"; then
9530 threads=yes
9532 else
9533 ax_pthread_ok=no
9534 threads=no
9536 ac_ext=cpp
9537 ac_cpp='$CXXCPP $CPPFLAGS'
9538 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
9539 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
9540 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
9543 save_LIBS="$LIBS"
9544 LIBS="$PTHREAD_LIBS $LIBS"
9545 save_CXXFLAGS="$CXXFLAGS"
9546 CXXFLAGS="$PTHREAD_CFLAGS $save_CXXFLAGS"
9547 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for std::thread" >&5
9548 $as_echo_n "checking for std::thread... " >&6; }
9549 if ${gdb_cv_cxx_std_thread+:} false; then :
9550 $as_echo_n "(cached) " >&6
9551 else
9552 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9553 /* end confdefs.h. */
9554 #if defined (__MINGW32__) || defined (__CYGWIN__)
9555 # ifdef _WIN32_WINNT
9556 # if _WIN32_WINNT < 0x0501
9557 # undef _WIN32_WINNT
9558 # define _WIN32_WINNT 0x0501
9559 # endif
9560 # else
9561 # define _WIN32_WINNT 0x0501
9562 # endif
9563 #endif /* __MINGW32__ || __CYGWIN__ */
9564 #include <thread>
9565 #include <mutex>
9566 void callback() { }
9568 main ()
9570 std::thread t(callback);
9572 return 0;
9574 _ACEOF
9575 if ac_fn_cxx_try_compile "$LINENO"; then :
9576 gdb_cv_cxx_std_thread=yes
9577 else
9578 gdb_cv_cxx_std_thread=no
9580 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9582 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_cxx_std_thread" >&5
9583 $as_echo "$gdb_cv_cxx_std_thread" >&6; }
9585 if test "$threads" = "yes"; then
9586 # This check must be here, while LIBS includes any necessary
9587 # threading library.
9588 for ac_func in pthread_sigmask pthread_setname_np
9589 do :
9590 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
9591 ac_fn_cxx_check_func "$LINENO" "$ac_func" "$as_ac_var"
9592 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
9593 cat >>confdefs.h <<_ACEOF
9594 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
9595 _ACEOF
9598 done
9601 LIBS="$save_LIBS"
9602 CXXFLAGS="$save_CXXFLAGS"
9604 if test "$want_threading" != "no"; then
9605 if test "$gdb_cv_cxx_std_thread" = "yes"; then
9607 $as_echo "#define CXX_STD_THREAD 1" >>confdefs.h
9609 else
9610 if test "$want_threading" = "yes"; then
9611 as_fn_error $? "std::thread does not work; disable threading" "$LINENO" 5
9612 else
9613 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: std::thread does not work; disabling threading" >&5
9614 $as_echo "$as_me: WARNING: std::thread does not work; disabling threading" >&2;}
9618 ac_ext=c
9619 ac_cpp='$CPP $CPPFLAGS'
9620 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
9621 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
9622 ac_compiler_gnu=$ac_cv_c_compiler_gnu
9625 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigsetjmp" >&5
9626 $as_echo_n "checking for sigsetjmp... " >&6; }
9627 if ${gdb_cv_func_sigsetjmp+:} false; then :
9628 $as_echo_n "(cached) " >&6
9629 else
9630 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9631 /* end confdefs.h. */
9632 #include <setjmp.h>
9634 main ()
9636 sigjmp_buf env;
9637 while (! sigsetjmp (env, 1))
9638 siglongjmp (env, 1);
9641 return 0;
9643 _ACEOF
9644 if ac_fn_c_try_compile "$LINENO"; then :
9645 gdb_cv_func_sigsetjmp=yes
9646 else
9647 gdb_cv_func_sigsetjmp=no
9650 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9653 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_func_sigsetjmp" >&5
9654 $as_echo "$gdb_cv_func_sigsetjmp" >&6; }
9655 if test "$gdb_cv_func_sigsetjmp" = "yes"; then
9657 $as_echo "#define HAVE_SIGSETJMP 1" >>confdefs.h
9662 # Check whether --with-intel_pt was given.
9663 if test "${with_intel_pt+set}" = set; then :
9664 withval=$with_intel_pt;
9665 else
9666 with_intel_pt=auto
9669 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use intel pt" >&5
9670 $as_echo_n "checking whether to use intel pt... " >&6; }
9671 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_intel_pt" >&5
9672 $as_echo "$with_intel_pt" >&6; }
9674 if test "${with_intel_pt}" = no; then
9675 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Intel Processor Trace support disabled; some features may be unavailable." >&5
9676 $as_echo "$as_me: WARNING: Intel Processor Trace support disabled; some features may be unavailable." >&2;}
9677 HAVE_LIBIPT=no
9678 else
9679 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9680 /* end confdefs.h. */
9682 #include <linux/perf_event.h>
9683 #ifndef PERF_ATTR_SIZE_VER5
9684 # error
9685 #endif
9687 _ACEOF
9688 if ac_fn_c_try_cpp "$LINENO"; then :
9689 perf_event=yes
9690 else
9691 perf_event=no
9693 rm -f conftest.err conftest.i conftest.$ac_ext
9694 if test "$perf_event" != yes; then
9695 if test "$with_intel_pt" = yes; then
9696 as_fn_error $? "linux/perf_event.h missing or too old" "$LINENO" 5
9697 else
9698 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: linux/perf_event.h missing or too old; some features may be unavailable." >&5
9699 $as_echo "$as_me: WARNING: linux/perf_event.h missing or too old; some features may be unavailable." >&2;}
9711 use_additional=yes
9713 acl_save_prefix="$prefix"
9714 prefix="$acl_final_prefix"
9715 acl_save_exec_prefix="$exec_prefix"
9716 exec_prefix="$acl_final_exec_prefix"
9718 eval additional_includedir=\"$includedir\"
9719 eval additional_libdir=\"$libdir\"
9721 exec_prefix="$acl_save_exec_prefix"
9722 prefix="$acl_save_prefix"
9725 # Check whether --with-libipt-prefix was given.
9726 if test "${with_libipt_prefix+set}" = set; then :
9727 withval=$with_libipt_prefix;
9728 if test "X$withval" = "Xno"; then
9729 use_additional=no
9730 else
9731 if test "X$withval" = "X"; then
9733 acl_save_prefix="$prefix"
9734 prefix="$acl_final_prefix"
9735 acl_save_exec_prefix="$exec_prefix"
9736 exec_prefix="$acl_final_exec_prefix"
9738 eval additional_includedir=\"$includedir\"
9739 eval additional_libdir=\"$libdir\"
9741 exec_prefix="$acl_save_exec_prefix"
9742 prefix="$acl_save_prefix"
9744 else
9745 additional_includedir="$withval/include"
9746 additional_libdir="$withval/lib"
9753 # Check whether --with-libipt-type was given.
9754 if test "${with_libipt_type+set}" = set; then :
9755 withval=$with_libipt_type; with_libipt_type=$withval
9756 else
9757 with_libipt_type=auto
9760 lib_type=`eval echo \$with_libipt_type`
9762 LIBIPT=
9763 LTLIBIPT=
9764 INCIPT=
9765 rpathdirs=
9766 ltrpathdirs=
9767 names_already_handled=
9768 names_next_round='ipt '
9769 while test -n "$names_next_round"; do
9770 names_this_round="$names_next_round"
9771 names_next_round=
9772 for name in $names_this_round; do
9773 already_handled=
9774 for n in $names_already_handled; do
9775 if test "$n" = "$name"; then
9776 already_handled=yes
9777 break
9779 done
9780 if test -z "$already_handled"; then
9781 names_already_handled="$names_already_handled $name"
9782 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
9783 eval value=\"\$HAVE_LIB$uppername\"
9784 if test -n "$value"; then
9785 if test "$value" = yes; then
9786 eval value=\"\$LIB$uppername\"
9787 test -z "$value" || LIBIPT="${LIBIPT}${LIBIPT:+ }$value"
9788 eval value=\"\$LTLIB$uppername\"
9789 test -z "$value" || LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }$value"
9790 else
9793 else
9794 found_dir=
9795 found_la=
9796 found_so=
9797 found_a=
9798 if test $use_additional = yes; then
9799 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
9800 found_dir="$additional_libdir"
9801 found_so="$additional_libdir/lib$name.$shlibext"
9802 if test -f "$additional_libdir/lib$name.la"; then
9803 found_la="$additional_libdir/lib$name.la"
9805 elif test x$lib_type != xshared; then
9806 if test -f "$additional_libdir/lib$name.$libext"; then
9807 found_dir="$additional_libdir"
9808 found_a="$additional_libdir/lib$name.$libext"
9809 if test -f "$additional_libdir/lib$name.la"; then
9810 found_la="$additional_libdir/lib$name.la"
9815 if test "X$found_dir" = "X"; then
9816 for x in $LDFLAGS $LTLIBIPT; do
9818 acl_save_prefix="$prefix"
9819 prefix="$acl_final_prefix"
9820 acl_save_exec_prefix="$exec_prefix"
9821 exec_prefix="$acl_final_exec_prefix"
9822 eval x=\"$x\"
9823 exec_prefix="$acl_save_exec_prefix"
9824 prefix="$acl_save_prefix"
9826 case "$x" in
9827 -L*)
9828 dir=`echo "X$x" | sed -e 's/^X-L//'`
9829 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
9830 found_dir="$dir"
9831 found_so="$dir/lib$name.$shlibext"
9832 if test -f "$dir/lib$name.la"; then
9833 found_la="$dir/lib$name.la"
9835 elif test x$lib_type != xshared; then
9836 if test -f "$dir/lib$name.$libext"; then
9837 found_dir="$dir"
9838 found_a="$dir/lib$name.$libext"
9839 if test -f "$dir/lib$name.la"; then
9840 found_la="$dir/lib$name.la"
9845 esac
9846 if test "X$found_dir" != "X"; then
9847 break
9849 done
9851 if test "X$found_dir" != "X"; then
9852 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-L$found_dir -l$name"
9853 if test "X$found_so" != "X"; then
9854 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
9855 LIBIPT="${LIBIPT}${LIBIPT:+ }$found_so"
9856 else
9857 haveit=
9858 for x in $ltrpathdirs; do
9859 if test "X$x" = "X$found_dir"; then
9860 haveit=yes
9861 break
9863 done
9864 if test -z "$haveit"; then
9865 ltrpathdirs="$ltrpathdirs $found_dir"
9867 if test "$hardcode_direct" = yes; then
9868 LIBIPT="${LIBIPT}${LIBIPT:+ }$found_so"
9869 else
9870 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
9871 LIBIPT="${LIBIPT}${LIBIPT:+ }$found_so"
9872 haveit=
9873 for x in $rpathdirs; do
9874 if test "X$x" = "X$found_dir"; then
9875 haveit=yes
9876 break
9878 done
9879 if test -z "$haveit"; then
9880 rpathdirs="$rpathdirs $found_dir"
9882 else
9883 haveit=
9884 for x in $LDFLAGS $LIBIPT; do
9886 acl_save_prefix="$prefix"
9887 prefix="$acl_final_prefix"
9888 acl_save_exec_prefix="$exec_prefix"
9889 exec_prefix="$acl_final_exec_prefix"
9890 eval x=\"$x\"
9891 exec_prefix="$acl_save_exec_prefix"
9892 prefix="$acl_save_prefix"
9894 if test "X$x" = "X-L$found_dir"; then
9895 haveit=yes
9896 break
9898 done
9899 if test -z "$haveit"; then
9900 LIBIPT="${LIBIPT}${LIBIPT:+ }-L$found_dir"
9902 if test "$hardcode_minus_L" != no; then
9903 LIBIPT="${LIBIPT}${LIBIPT:+ }$found_so"
9904 else
9905 LIBIPT="${LIBIPT}${LIBIPT:+ }-l$name"
9910 else
9911 if test "X$found_a" != "X"; then
9912 LIBIPT="${LIBIPT}${LIBIPT:+ }$found_a"
9913 else
9914 LIBIPT="${LIBIPT}${LIBIPT:+ }-L$found_dir -l$name"
9917 additional_includedir=
9918 case "$found_dir" in
9919 */lib | */lib/)
9920 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
9921 additional_includedir="$basedir/include"
9923 esac
9924 if test "X$additional_includedir" != "X"; then
9925 if test "X$additional_includedir" != "X/usr/include"; then
9926 haveit=
9927 if test "X$additional_includedir" = "X/usr/local/include"; then
9928 if test -n "$GCC"; then
9929 case $host_os in
9930 linux*) haveit=yes;;
9931 esac
9934 if test -z "$haveit"; then
9935 for x in $CPPFLAGS $INCIPT; do
9937 acl_save_prefix="$prefix"
9938 prefix="$acl_final_prefix"
9939 acl_save_exec_prefix="$exec_prefix"
9940 exec_prefix="$acl_final_exec_prefix"
9941 eval x=\"$x\"
9942 exec_prefix="$acl_save_exec_prefix"
9943 prefix="$acl_save_prefix"
9945 if test "X$x" = "X-I$additional_includedir"; then
9946 haveit=yes
9947 break
9949 done
9950 if test -z "$haveit"; then
9951 if test -d "$additional_includedir"; then
9952 INCIPT="${INCIPT}${INCIPT:+ }-I$additional_includedir"
9958 if test -n "$found_la"; then
9959 save_libdir="$libdir"
9960 case "$found_la" in
9961 */* | *\\*) . "$found_la" ;;
9962 *) . "./$found_la" ;;
9963 esac
9964 libdir="$save_libdir"
9965 for dep in $dependency_libs; do
9966 case "$dep" in
9967 -L*)
9968 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
9969 if test "X$additional_libdir" != "X/usr/lib"; then
9970 haveit=
9971 if test "X$additional_libdir" = "X/usr/local/lib"; then
9972 if test -n "$GCC"; then
9973 case $host_os in
9974 linux*) haveit=yes;;
9975 esac
9978 if test -z "$haveit"; then
9979 haveit=
9980 for x in $LDFLAGS $LIBIPT; do
9982 acl_save_prefix="$prefix"
9983 prefix="$acl_final_prefix"
9984 acl_save_exec_prefix="$exec_prefix"
9985 exec_prefix="$acl_final_exec_prefix"
9986 eval x=\"$x\"
9987 exec_prefix="$acl_save_exec_prefix"
9988 prefix="$acl_save_prefix"
9990 if test "X$x" = "X-L$additional_libdir"; then
9991 haveit=yes
9992 break
9994 done
9995 if test -z "$haveit"; then
9996 if test -d "$additional_libdir"; then
9997 LIBIPT="${LIBIPT}${LIBIPT:+ }-L$additional_libdir"
10000 haveit=
10001 for x in $LDFLAGS $LTLIBIPT; do
10003 acl_save_prefix="$prefix"
10004 prefix="$acl_final_prefix"
10005 acl_save_exec_prefix="$exec_prefix"
10006 exec_prefix="$acl_final_exec_prefix"
10007 eval x=\"$x\"
10008 exec_prefix="$acl_save_exec_prefix"
10009 prefix="$acl_save_prefix"
10011 if test "X$x" = "X-L$additional_libdir"; then
10012 haveit=yes
10013 break
10015 done
10016 if test -z "$haveit"; then
10017 if test -d "$additional_libdir"; then
10018 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-L$additional_libdir"
10024 -R*)
10025 dir=`echo "X$dep" | sed -e 's/^X-R//'`
10026 if test "$enable_rpath" != no; then
10027 haveit=
10028 for x in $rpathdirs; do
10029 if test "X$x" = "X$dir"; then
10030 haveit=yes
10031 break
10033 done
10034 if test -z "$haveit"; then
10035 rpathdirs="$rpathdirs $dir"
10037 haveit=
10038 for x in $ltrpathdirs; do
10039 if test "X$x" = "X$dir"; then
10040 haveit=yes
10041 break
10043 done
10044 if test -z "$haveit"; then
10045 ltrpathdirs="$ltrpathdirs $dir"
10049 -l*)
10050 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
10052 *.la)
10053 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
10056 LIBIPT="${LIBIPT}${LIBIPT:+ }$dep"
10057 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }$dep"
10059 esac
10060 done
10062 else
10063 if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
10064 LIBIPT="${LIBIPT}${LIBIPT:+ }-l$name"
10065 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-l$name"
10066 else
10067 LIBIPT="${LIBIPT}${LIBIPT:+ }-l:lib$name.$libext"
10068 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-l:lib$name.$libext"
10073 done
10074 done
10075 if test "X$rpathdirs" != "X"; then
10076 if test -n "$hardcode_libdir_separator"; then
10077 alldirs=
10078 for found_dir in $rpathdirs; do
10079 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
10080 done
10081 acl_save_libdir="$libdir"
10082 libdir="$alldirs"
10083 eval flag=\"$hardcode_libdir_flag_spec\"
10084 libdir="$acl_save_libdir"
10085 LIBIPT="${LIBIPT}${LIBIPT:+ }$flag"
10086 else
10087 for found_dir in $rpathdirs; do
10088 acl_save_libdir="$libdir"
10089 libdir="$found_dir"
10090 eval flag=\"$hardcode_libdir_flag_spec\"
10091 libdir="$acl_save_libdir"
10092 LIBIPT="${LIBIPT}${LIBIPT:+ }$flag"
10093 done
10096 if test "X$ltrpathdirs" != "X"; then
10097 for found_dir in $ltrpathdirs; do
10098 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-R$found_dir"
10099 done
10103 ac_save_CPPFLAGS="$CPPFLAGS"
10105 for element in $INCIPT; do
10106 haveit=
10107 for x in $CPPFLAGS; do
10109 acl_save_prefix="$prefix"
10110 prefix="$acl_final_prefix"
10111 acl_save_exec_prefix="$exec_prefix"
10112 exec_prefix="$acl_final_exec_prefix"
10113 eval x=\"$x\"
10114 exec_prefix="$acl_save_exec_prefix"
10115 prefix="$acl_save_prefix"
10117 if test "X$x" = "X$element"; then
10118 haveit=yes
10119 break
10121 done
10122 if test -z "$haveit"; then
10123 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
10125 done
10128 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libipt" >&5
10129 $as_echo_n "checking for libipt... " >&6; }
10130 if ${ac_cv_libipt+:} false; then :
10131 $as_echo_n "(cached) " >&6
10132 else
10134 ac_save_LIBS="$LIBS"
10135 LIBS="$LIBS $LIBIPT"
10136 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10137 /* end confdefs.h. */
10138 #include "intel-pt.h"
10140 main ()
10142 pt_insn_alloc_decoder (0);
10144 return 0;
10146 _ACEOF
10147 if ac_fn_c_try_link "$LINENO"; then :
10148 ac_cv_libipt=yes
10149 else
10150 ac_cv_libipt=no
10152 rm -f core conftest.err conftest.$ac_objext \
10153 conftest$ac_exeext conftest.$ac_ext
10154 LIBS="$ac_save_LIBS"
10157 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libipt" >&5
10158 $as_echo "$ac_cv_libipt" >&6; }
10159 if test "$ac_cv_libipt" = yes; then
10160 HAVE_LIBIPT=yes
10162 $as_echo "#define HAVE_LIBIPT 1" >>confdefs.h
10164 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libipt" >&5
10165 $as_echo_n "checking how to link with libipt... " >&6; }
10166 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBIPT" >&5
10167 $as_echo "$LIBIPT" >&6; }
10168 else
10169 HAVE_LIBIPT=no
10170 CPPFLAGS="$ac_save_CPPFLAGS"
10171 LIBIPT=
10172 LTLIBIPT=
10180 if test "$HAVE_LIBIPT" != yes; then
10181 if test "$with_intel_pt" = yes; then
10182 as_fn_error $? "libipt is missing or unusable" "$LINENO" 5
10183 else
10184 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libipt is missing or unusable; some features may be unavailable." >&5
10185 $as_echo "$as_me: WARNING: libipt is missing or unusable; some features may be unavailable." >&2;}
10187 else
10188 save_LIBS=$LIBS
10189 LIBS="$LIBS $LIBIPT"
10190 for ac_func in pt_insn_event
10191 do :
10192 ac_fn_c_check_func "$LINENO" "pt_insn_event" "ac_cv_func_pt_insn_event"
10193 if test "x$ac_cv_func_pt_insn_event" = xyes; then :
10194 cat >>confdefs.h <<_ACEOF
10195 #define HAVE_PT_INSN_EVENT 1
10196 _ACEOF
10199 done
10201 ac_fn_c_check_member "$LINENO" "struct pt_insn" "enabled" "ac_cv_member_struct_pt_insn_enabled" "#include <intel-pt.h>
10203 if test "x$ac_cv_member_struct_pt_insn_enabled" = xyes; then :
10205 cat >>confdefs.h <<_ACEOF
10206 #define HAVE_STRUCT_PT_INSN_ENABLED 1
10207 _ACEOF
10211 ac_fn_c_check_member "$LINENO" "struct pt_insn" "resynced" "ac_cv_member_struct_pt_insn_resynced" "#include <intel-pt.h>
10213 if test "x$ac_cv_member_struct_pt_insn_resynced" = xyes; then :
10215 cat >>confdefs.h <<_ACEOF
10216 #define HAVE_STRUCT_PT_INSN_RESYNCED 1
10217 _ACEOF
10222 ac_fn_c_check_member "$LINENO" "struct pt_event" "variant.ptwrite" "ac_cv_member_struct_pt_event_variant_ptwrite" "#include <intel-pt.h>
10224 if test "x$ac_cv_member_struct_pt_event_variant_ptwrite" = xyes; then :
10226 cat >>confdefs.h <<_ACEOF
10227 #define HAVE_STRUCT_PT_EVENT_VARIANT_PTWRITE 1
10228 _ACEOF
10233 LIBS=$save_LIBS
10237 # Check if the compiler and runtime support printing long longs.
10239 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long support in printf" >&5
10240 $as_echo_n "checking for long long support in printf... " >&6; }
10241 if ${gdb_cv_printf_has_long_long+:} false; then :
10242 $as_echo_n "(cached) " >&6
10243 else
10244 if test "$cross_compiling" = yes; then :
10245 gdb_cv_printf_has_long_long=no
10246 else
10247 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10248 /* end confdefs.h. */
10249 $ac_includes_default
10251 main ()
10253 char buf[32];
10254 long long l = 0;
10255 l = (l << 16) + 0x0123;
10256 l = (l << 16) + 0x4567;
10257 l = (l << 16) + 0x89ab;
10258 l = (l << 16) + 0xcdef;
10259 sprintf (buf, "0x%016llx", l);
10260 return (strcmp ("0x0123456789abcdef", buf));
10262 return 0;
10264 _ACEOF
10265 if ac_fn_c_try_run "$LINENO"; then :
10266 gdb_cv_printf_has_long_long=yes
10267 else
10268 gdb_cv_printf_has_long_long=no
10270 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10271 conftest.$ac_objext conftest.beam conftest.$ac_ext
10275 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_printf_has_long_long" >&5
10276 $as_echo "$gdb_cv_printf_has_long_long" >&6; }
10277 if test "$gdb_cv_printf_has_long_long" = yes; then
10279 $as_echo "#define PRINTF_HAS_LONG_LONG 1" >>confdefs.h
10284 $as_echo "#define _STRUCTURED_PROC 1" >>confdefs.h
10286 for ac_header in sys/procfs.h
10287 do :
10288 ac_fn_c_check_header_mongrel "$LINENO" "sys/procfs.h" "ac_cv_header_sys_procfs_h" "$ac_includes_default"
10289 if test "x$ac_cv_header_sys_procfs_h" = xyes; then :
10290 cat >>confdefs.h <<_ACEOF
10291 #define HAVE_SYS_PROCFS_H 1
10292 _ACEOF
10296 done
10298 if test "$ac_cv_header_sys_procfs_h" = yes; then
10300 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gregset_t in sys/procfs.h" >&5
10301 $as_echo_n "checking for gregset_t in sys/procfs.h... " >&6; }
10302 if ${bfd_cv_have_sys_procfs_type_gregset_t+:} false; then :
10303 $as_echo_n "(cached) " >&6
10304 else
10305 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10306 /* end confdefs.h. */
10308 #define _SYSCALL32
10309 #include <sys/procfs.h>
10311 main ()
10313 gregset_t avar
10315 return 0;
10317 _ACEOF
10318 if ac_fn_c_try_compile "$LINENO"; then :
10319 bfd_cv_have_sys_procfs_type_gregset_t=yes
10320 else
10321 bfd_cv_have_sys_procfs_type_gregset_t=no
10324 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10327 if test $bfd_cv_have_sys_procfs_type_gregset_t = yes; then
10329 $as_echo "#define HAVE_GREGSET_T 1" >>confdefs.h
10332 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_gregset_t" >&5
10333 $as_echo "$bfd_cv_have_sys_procfs_type_gregset_t" >&6; }
10336 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fpregset_t in sys/procfs.h" >&5
10337 $as_echo_n "checking for fpregset_t in sys/procfs.h... " >&6; }
10338 if ${bfd_cv_have_sys_procfs_type_fpregset_t+:} false; then :
10339 $as_echo_n "(cached) " >&6
10340 else
10341 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10342 /* end confdefs.h. */
10344 #define _SYSCALL32
10345 #include <sys/procfs.h>
10347 main ()
10349 fpregset_t avar
10351 return 0;
10353 _ACEOF
10354 if ac_fn_c_try_compile "$LINENO"; then :
10355 bfd_cv_have_sys_procfs_type_fpregset_t=yes
10356 else
10357 bfd_cv_have_sys_procfs_type_fpregset_t=no
10360 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10363 if test $bfd_cv_have_sys_procfs_type_fpregset_t = yes; then
10365 $as_echo "#define HAVE_FPREGSET_T 1" >>confdefs.h
10368 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_fpregset_t" >&5
10369 $as_echo "$bfd_cv_have_sys_procfs_type_fpregset_t" >&6; }
10372 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prgregset_t in sys/procfs.h" >&5
10373 $as_echo_n "checking for prgregset_t in sys/procfs.h... " >&6; }
10374 if ${bfd_cv_have_sys_procfs_type_prgregset_t+:} false; then :
10375 $as_echo_n "(cached) " >&6
10376 else
10377 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10378 /* end confdefs.h. */
10380 #define _SYSCALL32
10381 #include <sys/procfs.h>
10383 main ()
10385 prgregset_t avar
10387 return 0;
10389 _ACEOF
10390 if ac_fn_c_try_compile "$LINENO"; then :
10391 bfd_cv_have_sys_procfs_type_prgregset_t=yes
10392 else
10393 bfd_cv_have_sys_procfs_type_prgregset_t=no
10396 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10399 if test $bfd_cv_have_sys_procfs_type_prgregset_t = yes; then
10401 $as_echo "#define HAVE_PRGREGSET_T 1" >>confdefs.h
10404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prgregset_t" >&5
10405 $as_echo "$bfd_cv_have_sys_procfs_type_prgregset_t" >&6; }
10408 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prfpregset_t in sys/procfs.h" >&5
10409 $as_echo_n "checking for prfpregset_t in sys/procfs.h... " >&6; }
10410 if ${bfd_cv_have_sys_procfs_type_prfpregset_t+:} false; then :
10411 $as_echo_n "(cached) " >&6
10412 else
10413 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10414 /* end confdefs.h. */
10416 #define _SYSCALL32
10417 #include <sys/procfs.h>
10419 main ()
10421 prfpregset_t avar
10423 return 0;
10425 _ACEOF
10426 if ac_fn_c_try_compile "$LINENO"; then :
10427 bfd_cv_have_sys_procfs_type_prfpregset_t=yes
10428 else
10429 bfd_cv_have_sys_procfs_type_prfpregset_t=no
10432 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10435 if test $bfd_cv_have_sys_procfs_type_prfpregset_t = yes; then
10437 $as_echo "#define HAVE_PRFPREGSET_T 1" >>confdefs.h
10440 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prfpregset_t" >&5
10441 $as_echo "$bfd_cv_have_sys_procfs_type_prfpregset_t" >&6; }
10444 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prgregset32_t in sys/procfs.h" >&5
10445 $as_echo_n "checking for prgregset32_t in sys/procfs.h... " >&6; }
10446 if ${bfd_cv_have_sys_procfs_type_prgregset32_t+:} false; then :
10447 $as_echo_n "(cached) " >&6
10448 else
10449 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10450 /* end confdefs.h. */
10452 #define _SYSCALL32
10453 #include <sys/procfs.h>
10455 main ()
10457 prgregset32_t avar
10459 return 0;
10461 _ACEOF
10462 if ac_fn_c_try_compile "$LINENO"; then :
10463 bfd_cv_have_sys_procfs_type_prgregset32_t=yes
10464 else
10465 bfd_cv_have_sys_procfs_type_prgregset32_t=no
10468 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10471 if test $bfd_cv_have_sys_procfs_type_prgregset32_t = yes; then
10473 $as_echo "#define HAVE_PRGREGSET32_T 1" >>confdefs.h
10476 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prgregset32_t" >&5
10477 $as_echo "$bfd_cv_have_sys_procfs_type_prgregset32_t" >&6; }
10480 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lwpid_t in sys/procfs.h" >&5
10481 $as_echo_n "checking for lwpid_t in sys/procfs.h... " >&6; }
10482 if ${bfd_cv_have_sys_procfs_type_lwpid_t+:} false; then :
10483 $as_echo_n "(cached) " >&6
10484 else
10485 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10486 /* end confdefs.h. */
10488 #define _SYSCALL32
10489 #include <sys/procfs.h>
10491 main ()
10493 lwpid_t avar
10495 return 0;
10497 _ACEOF
10498 if ac_fn_c_try_compile "$LINENO"; then :
10499 bfd_cv_have_sys_procfs_type_lwpid_t=yes
10500 else
10501 bfd_cv_have_sys_procfs_type_lwpid_t=no
10504 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10507 if test $bfd_cv_have_sys_procfs_type_lwpid_t = yes; then
10509 $as_echo "#define HAVE_LWPID_T 1" >>confdefs.h
10512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_lwpid_t" >&5
10513 $as_echo "$bfd_cv_have_sys_procfs_type_lwpid_t" >&6; }
10516 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for psaddr_t in sys/procfs.h" >&5
10517 $as_echo_n "checking for psaddr_t in sys/procfs.h... " >&6; }
10518 if ${bfd_cv_have_sys_procfs_type_psaddr_t+:} false; then :
10519 $as_echo_n "(cached) " >&6
10520 else
10521 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10522 /* end confdefs.h. */
10524 #define _SYSCALL32
10525 #include <sys/procfs.h>
10527 main ()
10529 psaddr_t avar
10531 return 0;
10533 _ACEOF
10534 if ac_fn_c_try_compile "$LINENO"; then :
10535 bfd_cv_have_sys_procfs_type_psaddr_t=yes
10536 else
10537 bfd_cv_have_sys_procfs_type_psaddr_t=no
10540 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10543 if test $bfd_cv_have_sys_procfs_type_psaddr_t = yes; then
10545 $as_echo "#define HAVE_PSADDR_T 1" >>confdefs.h
10548 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_psaddr_t" >&5
10549 $as_echo "$bfd_cv_have_sys_procfs_type_psaddr_t" >&6; }
10552 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for elf_fpregset_t in sys/procfs.h" >&5
10553 $as_echo_n "checking for elf_fpregset_t in sys/procfs.h... " >&6; }
10554 if ${bfd_cv_have_sys_procfs_type_elf_fpregset_t+:} false; then :
10555 $as_echo_n "(cached) " >&6
10556 else
10557 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10558 /* end confdefs.h. */
10560 #define _SYSCALL32
10561 #include <sys/procfs.h>
10563 main ()
10565 elf_fpregset_t avar
10567 return 0;
10569 _ACEOF
10570 if ac_fn_c_try_compile "$LINENO"; then :
10571 bfd_cv_have_sys_procfs_type_elf_fpregset_t=yes
10572 else
10573 bfd_cv_have_sys_procfs_type_elf_fpregset_t=no
10576 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10579 if test $bfd_cv_have_sys_procfs_type_elf_fpregset_t = yes; then
10581 $as_echo "#define HAVE_ELF_FPREGSET_T 1" >>confdefs.h
10584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_elf_fpregset_t" >&5
10585 $as_echo "$bfd_cv_have_sys_procfs_type_elf_fpregset_t" >&6; }
10589 # Check for xxhash
10591 # Check whether --with-xxhash was given.
10592 if test "${with_xxhash+set}" = set; then :
10593 withval=$with_xxhash;
10594 else
10595 with_xxhash=auto
10599 if test "x$with_xxhash" != "xno"; then
10608 use_additional=yes
10610 acl_save_prefix="$prefix"
10611 prefix="$acl_final_prefix"
10612 acl_save_exec_prefix="$exec_prefix"
10613 exec_prefix="$acl_final_exec_prefix"
10615 eval additional_includedir=\"$includedir\"
10616 eval additional_libdir=\"$libdir\"
10618 exec_prefix="$acl_save_exec_prefix"
10619 prefix="$acl_save_prefix"
10622 # Check whether --with-libxxhash-prefix was given.
10623 if test "${with_libxxhash_prefix+set}" = set; then :
10624 withval=$with_libxxhash_prefix;
10625 if test "X$withval" = "Xno"; then
10626 use_additional=no
10627 else
10628 if test "X$withval" = "X"; then
10630 acl_save_prefix="$prefix"
10631 prefix="$acl_final_prefix"
10632 acl_save_exec_prefix="$exec_prefix"
10633 exec_prefix="$acl_final_exec_prefix"
10635 eval additional_includedir=\"$includedir\"
10636 eval additional_libdir=\"$libdir\"
10638 exec_prefix="$acl_save_exec_prefix"
10639 prefix="$acl_save_prefix"
10641 else
10642 additional_includedir="$withval/include"
10643 additional_libdir="$withval/lib"
10650 # Check whether --with-libxxhash-type was given.
10651 if test "${with_libxxhash_type+set}" = set; then :
10652 withval=$with_libxxhash_type; with_libxxhash_type=$withval
10653 else
10654 with_libxxhash_type=auto
10657 lib_type=`eval echo \$with_libxxhash_type`
10659 LIBXXHASH=
10660 LTLIBXXHASH=
10661 INCXXHASH=
10662 rpathdirs=
10663 ltrpathdirs=
10664 names_already_handled=
10665 names_next_round='xxhash '
10666 while test -n "$names_next_round"; do
10667 names_this_round="$names_next_round"
10668 names_next_round=
10669 for name in $names_this_round; do
10670 already_handled=
10671 for n in $names_already_handled; do
10672 if test "$n" = "$name"; then
10673 already_handled=yes
10674 break
10676 done
10677 if test -z "$already_handled"; then
10678 names_already_handled="$names_already_handled $name"
10679 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
10680 eval value=\"\$HAVE_LIB$uppername\"
10681 if test -n "$value"; then
10682 if test "$value" = yes; then
10683 eval value=\"\$LIB$uppername\"
10684 test -z "$value" || LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$value"
10685 eval value=\"\$LTLIB$uppername\"
10686 test -z "$value" || LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }$value"
10687 else
10690 else
10691 found_dir=
10692 found_la=
10693 found_so=
10694 found_a=
10695 if test $use_additional = yes; then
10696 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
10697 found_dir="$additional_libdir"
10698 found_so="$additional_libdir/lib$name.$shlibext"
10699 if test -f "$additional_libdir/lib$name.la"; then
10700 found_la="$additional_libdir/lib$name.la"
10702 elif test x$lib_type != xshared; then
10703 if test -f "$additional_libdir/lib$name.$libext"; then
10704 found_dir="$additional_libdir"
10705 found_a="$additional_libdir/lib$name.$libext"
10706 if test -f "$additional_libdir/lib$name.la"; then
10707 found_la="$additional_libdir/lib$name.la"
10712 if test "X$found_dir" = "X"; then
10713 for x in $LDFLAGS $LTLIBXXHASH; do
10715 acl_save_prefix="$prefix"
10716 prefix="$acl_final_prefix"
10717 acl_save_exec_prefix="$exec_prefix"
10718 exec_prefix="$acl_final_exec_prefix"
10719 eval x=\"$x\"
10720 exec_prefix="$acl_save_exec_prefix"
10721 prefix="$acl_save_prefix"
10723 case "$x" in
10724 -L*)
10725 dir=`echo "X$x" | sed -e 's/^X-L//'`
10726 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
10727 found_dir="$dir"
10728 found_so="$dir/lib$name.$shlibext"
10729 if test -f "$dir/lib$name.la"; then
10730 found_la="$dir/lib$name.la"
10732 elif test x$lib_type != xshared; then
10733 if test -f "$dir/lib$name.$libext"; then
10734 found_dir="$dir"
10735 found_a="$dir/lib$name.$libext"
10736 if test -f "$dir/lib$name.la"; then
10737 found_la="$dir/lib$name.la"
10742 esac
10743 if test "X$found_dir" != "X"; then
10744 break
10746 done
10748 if test "X$found_dir" != "X"; then
10749 LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }-L$found_dir -l$name"
10750 if test "X$found_so" != "X"; then
10751 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
10752 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$found_so"
10753 else
10754 haveit=
10755 for x in $ltrpathdirs; do
10756 if test "X$x" = "X$found_dir"; then
10757 haveit=yes
10758 break
10760 done
10761 if test -z "$haveit"; then
10762 ltrpathdirs="$ltrpathdirs $found_dir"
10764 if test "$hardcode_direct" = yes; then
10765 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$found_so"
10766 else
10767 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
10768 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$found_so"
10769 haveit=
10770 for x in $rpathdirs; do
10771 if test "X$x" = "X$found_dir"; then
10772 haveit=yes
10773 break
10775 done
10776 if test -z "$haveit"; then
10777 rpathdirs="$rpathdirs $found_dir"
10779 else
10780 haveit=
10781 for x in $LDFLAGS $LIBXXHASH; do
10783 acl_save_prefix="$prefix"
10784 prefix="$acl_final_prefix"
10785 acl_save_exec_prefix="$exec_prefix"
10786 exec_prefix="$acl_final_exec_prefix"
10787 eval x=\"$x\"
10788 exec_prefix="$acl_save_exec_prefix"
10789 prefix="$acl_save_prefix"
10791 if test "X$x" = "X-L$found_dir"; then
10792 haveit=yes
10793 break
10795 done
10796 if test -z "$haveit"; then
10797 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }-L$found_dir"
10799 if test "$hardcode_minus_L" != no; then
10800 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$found_so"
10801 else
10802 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }-l$name"
10807 else
10808 if test "X$found_a" != "X"; then
10809 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$found_a"
10810 else
10811 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }-L$found_dir -l$name"
10814 additional_includedir=
10815 case "$found_dir" in
10816 */lib | */lib/)
10817 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
10818 additional_includedir="$basedir/include"
10820 esac
10821 if test "X$additional_includedir" != "X"; then
10822 if test "X$additional_includedir" != "X/usr/include"; then
10823 haveit=
10824 if test "X$additional_includedir" = "X/usr/local/include"; then
10825 if test -n "$GCC"; then
10826 case $host_os in
10827 linux*) haveit=yes;;
10828 esac
10831 if test -z "$haveit"; then
10832 for x in $CPPFLAGS $INCXXHASH; do
10834 acl_save_prefix="$prefix"
10835 prefix="$acl_final_prefix"
10836 acl_save_exec_prefix="$exec_prefix"
10837 exec_prefix="$acl_final_exec_prefix"
10838 eval x=\"$x\"
10839 exec_prefix="$acl_save_exec_prefix"
10840 prefix="$acl_save_prefix"
10842 if test "X$x" = "X-I$additional_includedir"; then
10843 haveit=yes
10844 break
10846 done
10847 if test -z "$haveit"; then
10848 if test -d "$additional_includedir"; then
10849 INCXXHASH="${INCXXHASH}${INCXXHASH:+ }-I$additional_includedir"
10855 if test -n "$found_la"; then
10856 save_libdir="$libdir"
10857 case "$found_la" in
10858 */* | *\\*) . "$found_la" ;;
10859 *) . "./$found_la" ;;
10860 esac
10861 libdir="$save_libdir"
10862 for dep in $dependency_libs; do
10863 case "$dep" in
10864 -L*)
10865 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
10866 if test "X$additional_libdir" != "X/usr/lib"; then
10867 haveit=
10868 if test "X$additional_libdir" = "X/usr/local/lib"; then
10869 if test -n "$GCC"; then
10870 case $host_os in
10871 linux*) haveit=yes;;
10872 esac
10875 if test -z "$haveit"; then
10876 haveit=
10877 for x in $LDFLAGS $LIBXXHASH; do
10879 acl_save_prefix="$prefix"
10880 prefix="$acl_final_prefix"
10881 acl_save_exec_prefix="$exec_prefix"
10882 exec_prefix="$acl_final_exec_prefix"
10883 eval x=\"$x\"
10884 exec_prefix="$acl_save_exec_prefix"
10885 prefix="$acl_save_prefix"
10887 if test "X$x" = "X-L$additional_libdir"; then
10888 haveit=yes
10889 break
10891 done
10892 if test -z "$haveit"; then
10893 if test -d "$additional_libdir"; then
10894 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }-L$additional_libdir"
10897 haveit=
10898 for x in $LDFLAGS $LTLIBXXHASH; do
10900 acl_save_prefix="$prefix"
10901 prefix="$acl_final_prefix"
10902 acl_save_exec_prefix="$exec_prefix"
10903 exec_prefix="$acl_final_exec_prefix"
10904 eval x=\"$x\"
10905 exec_prefix="$acl_save_exec_prefix"
10906 prefix="$acl_save_prefix"
10908 if test "X$x" = "X-L$additional_libdir"; then
10909 haveit=yes
10910 break
10912 done
10913 if test -z "$haveit"; then
10914 if test -d "$additional_libdir"; then
10915 LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }-L$additional_libdir"
10921 -R*)
10922 dir=`echo "X$dep" | sed -e 's/^X-R//'`
10923 if test "$enable_rpath" != no; then
10924 haveit=
10925 for x in $rpathdirs; do
10926 if test "X$x" = "X$dir"; then
10927 haveit=yes
10928 break
10930 done
10931 if test -z "$haveit"; then
10932 rpathdirs="$rpathdirs $dir"
10934 haveit=
10935 for x in $ltrpathdirs; do
10936 if test "X$x" = "X$dir"; then
10937 haveit=yes
10938 break
10940 done
10941 if test -z "$haveit"; then
10942 ltrpathdirs="$ltrpathdirs $dir"
10946 -l*)
10947 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
10949 *.la)
10950 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
10953 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$dep"
10954 LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }$dep"
10956 esac
10957 done
10959 else
10960 if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
10961 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }-l$name"
10962 LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }-l$name"
10963 else
10964 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }-l:lib$name.$libext"
10965 LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }-l:lib$name.$libext"
10970 done
10971 done
10972 if test "X$rpathdirs" != "X"; then
10973 if test -n "$hardcode_libdir_separator"; then
10974 alldirs=
10975 for found_dir in $rpathdirs; do
10976 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
10977 done
10978 acl_save_libdir="$libdir"
10979 libdir="$alldirs"
10980 eval flag=\"$hardcode_libdir_flag_spec\"
10981 libdir="$acl_save_libdir"
10982 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$flag"
10983 else
10984 for found_dir in $rpathdirs; do
10985 acl_save_libdir="$libdir"
10986 libdir="$found_dir"
10987 eval flag=\"$hardcode_libdir_flag_spec\"
10988 libdir="$acl_save_libdir"
10989 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$flag"
10990 done
10993 if test "X$ltrpathdirs" != "X"; then
10994 for found_dir in $ltrpathdirs; do
10995 LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }-R$found_dir"
10996 done
11000 ac_save_CPPFLAGS="$CPPFLAGS"
11002 for element in $INCXXHASH; do
11003 haveit=
11004 for x in $CPPFLAGS; do
11006 acl_save_prefix="$prefix"
11007 prefix="$acl_final_prefix"
11008 acl_save_exec_prefix="$exec_prefix"
11009 exec_prefix="$acl_final_exec_prefix"
11010 eval x=\"$x\"
11011 exec_prefix="$acl_save_exec_prefix"
11012 prefix="$acl_save_prefix"
11014 if test "X$x" = "X$element"; then
11015 haveit=yes
11016 break
11018 done
11019 if test -z "$haveit"; then
11020 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
11022 done
11025 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libxxhash" >&5
11026 $as_echo_n "checking for libxxhash... " >&6; }
11027 if ${ac_cv_libxxhash+:} false; then :
11028 $as_echo_n "(cached) " >&6
11029 else
11031 ac_save_LIBS="$LIBS"
11032 LIBS="$LIBS $LIBXXHASH"
11033 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11034 /* end confdefs.h. */
11035 #include <xxhash.h>
11037 main ()
11039 XXH32("foo", 3, 0);
11042 return 0;
11044 _ACEOF
11045 if ac_fn_c_try_link "$LINENO"; then :
11046 ac_cv_libxxhash=yes
11047 else
11048 ac_cv_libxxhash=no
11050 rm -f core conftest.err conftest.$ac_objext \
11051 conftest$ac_exeext conftest.$ac_ext
11052 LIBS="$ac_save_LIBS"
11055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libxxhash" >&5
11056 $as_echo "$ac_cv_libxxhash" >&6; }
11057 if test "$ac_cv_libxxhash" = yes; then
11058 HAVE_LIBXXHASH=yes
11060 $as_echo "#define HAVE_LIBXXHASH 1" >>confdefs.h
11062 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libxxhash" >&5
11063 $as_echo_n "checking how to link with libxxhash... " >&6; }
11064 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBXXHASH" >&5
11065 $as_echo "$LIBXXHASH" >&6; }
11066 else
11067 HAVE_LIBXXHASH=no
11068 CPPFLAGS="$ac_save_CPPFLAGS"
11069 LIBXXHASH=
11070 LTLIBXXHASH=
11078 if test "$HAVE_LIBXXHASH" != yes; then
11079 if test "$with_xxhash" = yes; then
11080 as_fn_error $? "xxhash is missing or unusable" "$LINENO" 5
11083 if test "x$with_xxhash" = "xauto"; then
11084 with_xxhash="$HAVE_LIBXXHASH"
11088 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use xxhash" >&5
11089 $as_echo_n "checking whether to use xxhash... " >&6; }
11090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_xxhash" >&5
11091 $as_echo "$with_xxhash" >&6; }
11093 # This is set by GDB_AC_COMMON.
11097 # Check whether we will enable the inclusion of unit tests when
11098 # compiling GDB.
11100 # The default value of this option changes depending whether we're on
11101 # development mode (in which case it's "true") or not (in which case
11102 # it's "false"). The $development variable is set by the GDB_AC_COMMON
11103 # macro, which must therefore be used before GDB_AC_SELFTEST.
11105 if test "x$development" != xtrue && test "x$development" != xfalse; then :
11106 as_fn_error $? "Invalid value for \$development, got \"$development\", expecting \"true\" or \"false\"." "$LINENO" 5
11109 # Check whether --enable-unit-tests was given.
11110 if test "${enable_unit_tests+set}" = set; then :
11111 enableval=$enable_unit_tests; case "${enableval}" in
11112 yes) enable_unittests=true ;;
11113 no) enable_unittests=false ;;
11114 *) as_fn_error $? "bad value ${enableval} for --{enable,disable}-unit-tests option" "$LINENO" 5 ;;
11115 esac
11116 else
11117 enable_unittests=$development
11121 if $enable_unittests; then
11123 $as_echo "#define GDB_SELF_TEST 1" >>confdefs.h
11129 case ${build_alias} in
11130 "") build_noncanonical=${build} ;;
11131 *) build_noncanonical=${build_alias} ;;
11132 esac
11134 case ${host_alias} in
11135 "") host_noncanonical=${build_noncanonical} ;;
11136 *) host_noncanonical=${host_alias} ;;
11137 esac
11139 case ${target_alias} in
11140 "") target_noncanonical=${host_noncanonical} ;;
11141 *) target_noncanonical=${target_alias} ;;
11142 esac
11149 # Dependency checking.
11150 rm -rf .tst 2>/dev/null
11151 mkdir .tst 2>/dev/null
11152 if test -d .tst; then
11153 am__leading_dot=.
11154 else
11155 am__leading_dot=_
11157 rmdir .tst 2>/dev/null
11159 DEPDIR="${am__leading_dot}deps"
11161 ac_config_commands="$ac_config_commands depdir"
11165 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
11166 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
11167 set x ${MAKE-make}
11168 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
11169 if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then :
11170 $as_echo_n "(cached) " >&6
11171 else
11172 cat >conftest.make <<\_ACEOF
11173 SHELL = /bin/sh
11174 all:
11175 @echo '@@@%%%=$(MAKE)=@@@%%%'
11176 _ACEOF
11177 # GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
11178 case `${MAKE-make} -f conftest.make 2>/dev/null` in
11179 *@@@%%%=?*=@@@%%%*)
11180 eval ac_cv_prog_make_${ac_make}_set=yes;;
11182 eval ac_cv_prog_make_${ac_make}_set=no;;
11183 esac
11184 rm -f conftest.make
11186 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
11187 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11188 $as_echo "yes" >&6; }
11189 SET_MAKE=
11190 else
11191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11192 $as_echo "no" >&6; }
11193 SET_MAKE="MAKE=${MAKE-make}"
11197 MKINSTALLDIRS=
11198 if test -n "$ac_aux_dir"; then
11199 case "$ac_aux_dir" in
11200 /*) MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" ;;
11201 *) MKINSTALLDIRS="\$(top_builddir)/$ac_aux_dir/mkinstalldirs" ;;
11202 esac
11204 if test -z "$MKINSTALLDIRS"; then
11205 MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs"
11210 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5
11211 $as_echo_n "checking whether NLS is requested... " >&6; }
11212 # Check whether --enable-nls was given.
11213 if test "${enable_nls+set}" = set; then :
11214 enableval=$enable_nls; USE_NLS=$enableval
11215 else
11216 USE_NLS=yes
11219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5
11220 $as_echo "$USE_NLS" >&6; }
11227 # Prepare PATH_SEPARATOR.
11228 # The user is always right.
11229 if test "${PATH_SEPARATOR+set}" != set; then
11230 echo "#! /bin/sh" >conf$$.sh
11231 echo "exit 0" >>conf$$.sh
11232 chmod +x conf$$.sh
11233 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
11234 PATH_SEPARATOR=';'
11235 else
11236 PATH_SEPARATOR=:
11238 rm -f conf$$.sh
11241 # Find out how to test for executable files. Don't use a zero-byte file,
11242 # as systems may use methods other than mode bits to determine executability.
11243 cat >conf$$.file <<_ASEOF
11244 #! /bin/sh
11245 exit 0
11246 _ASEOF
11247 chmod +x conf$$.file
11248 if test -x conf$$.file >/dev/null 2>&1; then
11249 ac_executable_p="test -x"
11250 else
11251 ac_executable_p="test -f"
11253 rm -f conf$$.file
11255 # Extract the first word of "msgfmt", so it can be a program name with args.
11256 set dummy msgfmt; ac_word=$2
11257 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11258 $as_echo_n "checking for $ac_word... " >&6; }
11259 if ${ac_cv_path_MSGFMT+:} false; then :
11260 $as_echo_n "(cached) " >&6
11261 else
11262 case "$MSGFMT" in
11263 [\\/]* | ?:[\\/]*)
11264 ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
11267 ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
11268 for ac_dir in $PATH; do
11269 IFS="$ac_save_IFS"
11270 test -z "$ac_dir" && ac_dir=.
11271 for ac_exec_ext in '' $ac_executable_extensions; do
11272 if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
11273 if $ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1 &&
11274 (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
11275 ac_cv_path_MSGFMT="$ac_dir/$ac_word$ac_exec_ext"
11276 break 2
11279 done
11280 done
11281 IFS="$ac_save_IFS"
11282 test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":"
11284 esac
11286 MSGFMT="$ac_cv_path_MSGFMT"
11287 if test "$MSGFMT" != ":"; then
11288 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5
11289 $as_echo "$MSGFMT" >&6; }
11290 else
11291 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11292 $as_echo "no" >&6; }
11295 # Extract the first word of "gmsgfmt", so it can be a program name with args.
11296 set dummy gmsgfmt; ac_word=$2
11297 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11298 $as_echo_n "checking for $ac_word... " >&6; }
11299 if ${ac_cv_path_GMSGFMT+:} false; then :
11300 $as_echo_n "(cached) " >&6
11301 else
11302 case $GMSGFMT in
11303 [\\/]* | ?:[\\/]*)
11304 ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
11307 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11308 for as_dir in $PATH
11310 IFS=$as_save_IFS
11311 test -z "$as_dir" && as_dir=.
11312 for ac_exec_ext in '' $ac_executable_extensions; do
11313 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11314 ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext"
11315 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11316 break 2
11318 done
11319 done
11320 IFS=$as_save_IFS
11322 test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
11324 esac
11326 GMSGFMT=$ac_cv_path_GMSGFMT
11327 if test -n "$GMSGFMT"; then
11328 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GMSGFMT" >&5
11329 $as_echo "$GMSGFMT" >&6; }
11330 else
11331 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11332 $as_echo "no" >&6; }
11338 # Prepare PATH_SEPARATOR.
11339 # The user is always right.
11340 if test "${PATH_SEPARATOR+set}" != set; then
11341 echo "#! /bin/sh" >conf$$.sh
11342 echo "exit 0" >>conf$$.sh
11343 chmod +x conf$$.sh
11344 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
11345 PATH_SEPARATOR=';'
11346 else
11347 PATH_SEPARATOR=:
11349 rm -f conf$$.sh
11352 # Find out how to test for executable files. Don't use a zero-byte file,
11353 # as systems may use methods other than mode bits to determine executability.
11354 cat >conf$$.file <<_ASEOF
11355 #! /bin/sh
11356 exit 0
11357 _ASEOF
11358 chmod +x conf$$.file
11359 if test -x conf$$.file >/dev/null 2>&1; then
11360 ac_executable_p="test -x"
11361 else
11362 ac_executable_p="test -f"
11364 rm -f conf$$.file
11366 # Extract the first word of "xgettext", so it can be a program name with args.
11367 set dummy xgettext; ac_word=$2
11368 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11369 $as_echo_n "checking for $ac_word... " >&6; }
11370 if ${ac_cv_path_XGETTEXT+:} false; then :
11371 $as_echo_n "(cached) " >&6
11372 else
11373 case "$XGETTEXT" in
11374 [\\/]* | ?:[\\/]*)
11375 ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
11378 ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
11379 for ac_dir in $PATH; do
11380 IFS="$ac_save_IFS"
11381 test -z "$ac_dir" && ac_dir=.
11382 for ac_exec_ext in '' $ac_executable_extensions; do
11383 if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
11384 if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
11385 (if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
11386 ac_cv_path_XGETTEXT="$ac_dir/$ac_word$ac_exec_ext"
11387 break 2
11390 done
11391 done
11392 IFS="$ac_save_IFS"
11393 test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
11395 esac
11397 XGETTEXT="$ac_cv_path_XGETTEXT"
11398 if test "$XGETTEXT" != ":"; then
11399 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5
11400 $as_echo "$XGETTEXT" >&6; }
11401 else
11402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11403 $as_echo "no" >&6; }
11406 rm -f messages.po
11409 # Prepare PATH_SEPARATOR.
11410 # The user is always right.
11411 if test "${PATH_SEPARATOR+set}" != set; then
11412 echo "#! /bin/sh" >conf$$.sh
11413 echo "exit 0" >>conf$$.sh
11414 chmod +x conf$$.sh
11415 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
11416 PATH_SEPARATOR=';'
11417 else
11418 PATH_SEPARATOR=:
11420 rm -f conf$$.sh
11423 # Find out how to test for executable files. Don't use a zero-byte file,
11424 # as systems may use methods other than mode bits to determine executability.
11425 cat >conf$$.file <<_ASEOF
11426 #! /bin/sh
11427 exit 0
11428 _ASEOF
11429 chmod +x conf$$.file
11430 if test -x conf$$.file >/dev/null 2>&1; then
11431 ac_executable_p="test -x"
11432 else
11433 ac_executable_p="test -f"
11435 rm -f conf$$.file
11437 # Extract the first word of "msgmerge", so it can be a program name with args.
11438 set dummy msgmerge; ac_word=$2
11439 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11440 $as_echo_n "checking for $ac_word... " >&6; }
11441 if ${ac_cv_path_MSGMERGE+:} false; then :
11442 $as_echo_n "(cached) " >&6
11443 else
11444 case "$MSGMERGE" in
11445 [\\/]* | ?:[\\/]*)
11446 ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path.
11449 ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
11450 for ac_dir in $PATH; do
11451 IFS="$ac_save_IFS"
11452 test -z "$ac_dir" && ac_dir=.
11453 for ac_exec_ext in '' $ac_executable_extensions; do
11454 if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
11455 if $ac_dir/$ac_word --update -q /dev/null /dev/null >/dev/null 2>&1; then
11456 ac_cv_path_MSGMERGE="$ac_dir/$ac_word$ac_exec_ext"
11457 break 2
11460 done
11461 done
11462 IFS="$ac_save_IFS"
11463 test -z "$ac_cv_path_MSGMERGE" && ac_cv_path_MSGMERGE=":"
11465 esac
11467 MSGMERGE="$ac_cv_path_MSGMERGE"
11468 if test "$MSGMERGE" != ":"; then
11469 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5
11470 $as_echo "$MSGMERGE" >&6; }
11471 else
11472 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11473 $as_echo "no" >&6; }
11477 if test "$GMSGFMT" != ":"; then
11478 if $GMSGFMT --statistics /dev/null >/dev/null 2>&1 &&
11479 (if $GMSGFMT --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
11481 else
11482 GMSGFMT=`echo "$GMSGFMT" | sed -e 's,^.*/,,'`
11483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found $GMSGFMT program is not GNU msgfmt; ignore it" >&5
11484 $as_echo "found $GMSGFMT program is not GNU msgfmt; ignore it" >&6; }
11485 GMSGFMT=":"
11489 if test "$XGETTEXT" != ":"; then
11490 if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
11491 (if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
11493 else
11494 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found xgettext program is not GNU xgettext; ignore it" >&5
11495 $as_echo "found xgettext program is not GNU xgettext; ignore it" >&6; }
11496 XGETTEXT=":"
11498 rm -f messages.po
11501 ac_config_commands="$ac_config_commands default-1"
11510 use_additional=yes
11512 acl_save_prefix="$prefix"
11513 prefix="$acl_final_prefix"
11514 acl_save_exec_prefix="$exec_prefix"
11515 exec_prefix="$acl_final_exec_prefix"
11517 eval additional_includedir=\"$includedir\"
11518 eval additional_libdir=\"$libdir\"
11520 exec_prefix="$acl_save_exec_prefix"
11521 prefix="$acl_save_prefix"
11524 # Check whether --with-libiconv-prefix was given.
11525 if test "${with_libiconv_prefix+set}" = set; then :
11526 withval=$with_libiconv_prefix;
11527 if test "X$withval" = "Xno"; then
11528 use_additional=no
11529 else
11530 if test "X$withval" = "X"; then
11532 acl_save_prefix="$prefix"
11533 prefix="$acl_final_prefix"
11534 acl_save_exec_prefix="$exec_prefix"
11535 exec_prefix="$acl_final_exec_prefix"
11537 eval additional_includedir=\"$includedir\"
11538 eval additional_libdir=\"$libdir\"
11540 exec_prefix="$acl_save_exec_prefix"
11541 prefix="$acl_save_prefix"
11543 else
11544 additional_includedir="$withval/include"
11545 additional_libdir="$withval/lib"
11552 # Check whether --with-libiconv-type was given.
11553 if test "${with_libiconv_type+set}" = set; then :
11554 withval=$with_libiconv_type; with_libiconv_type=$withval
11555 else
11556 with_libiconv_type=auto
11559 lib_type=`eval echo \$with_libiconv_type`
11561 LIBICONV=
11562 LTLIBICONV=
11563 INCICONV=
11564 rpathdirs=
11565 ltrpathdirs=
11566 names_already_handled=
11567 names_next_round='iconv '
11568 while test -n "$names_next_round"; do
11569 names_this_round="$names_next_round"
11570 names_next_round=
11571 for name in $names_this_round; do
11572 already_handled=
11573 for n in $names_already_handled; do
11574 if test "$n" = "$name"; then
11575 already_handled=yes
11576 break
11578 done
11579 if test -z "$already_handled"; then
11580 names_already_handled="$names_already_handled $name"
11581 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
11582 eval value=\"\$HAVE_LIB$uppername\"
11583 if test -n "$value"; then
11584 if test "$value" = yes; then
11585 eval value=\"\$LIB$uppername\"
11586 test -z "$value" || LIBICONV="${LIBICONV}${LIBICONV:+ }$value"
11587 eval value=\"\$LTLIB$uppername\"
11588 test -z "$value" || LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$value"
11589 else
11592 else
11593 found_dir=
11594 found_la=
11595 found_so=
11596 found_a=
11597 if test $use_additional = yes; then
11598 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
11599 found_dir="$additional_libdir"
11600 found_so="$additional_libdir/lib$name.$shlibext"
11601 if test -f "$additional_libdir/lib$name.la"; then
11602 found_la="$additional_libdir/lib$name.la"
11604 elif test x$lib_type != xshared; then
11605 if test -f "$additional_libdir/lib$name.$libext"; then
11606 found_dir="$additional_libdir"
11607 found_a="$additional_libdir/lib$name.$libext"
11608 if test -f "$additional_libdir/lib$name.la"; then
11609 found_la="$additional_libdir/lib$name.la"
11614 if test "X$found_dir" = "X"; then
11615 for x in $LDFLAGS $LTLIBICONV; do
11617 acl_save_prefix="$prefix"
11618 prefix="$acl_final_prefix"
11619 acl_save_exec_prefix="$exec_prefix"
11620 exec_prefix="$acl_final_exec_prefix"
11621 eval x=\"$x\"
11622 exec_prefix="$acl_save_exec_prefix"
11623 prefix="$acl_save_prefix"
11625 case "$x" in
11626 -L*)
11627 dir=`echo "X$x" | sed -e 's/^X-L//'`
11628 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
11629 found_dir="$dir"
11630 found_so="$dir/lib$name.$shlibext"
11631 if test -f "$dir/lib$name.la"; then
11632 found_la="$dir/lib$name.la"
11634 elif test x$lib_type != xshared; then
11635 if test -f "$dir/lib$name.$libext"; then
11636 found_dir="$dir"
11637 found_a="$dir/lib$name.$libext"
11638 if test -f "$dir/lib$name.la"; then
11639 found_la="$dir/lib$name.la"
11644 esac
11645 if test "X$found_dir" != "X"; then
11646 break
11648 done
11650 if test "X$found_dir" != "X"; then
11651 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$found_dir -l$name"
11652 if test "X$found_so" != "X"; then
11653 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
11654 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
11655 else
11656 haveit=
11657 for x in $ltrpathdirs; do
11658 if test "X$x" = "X$found_dir"; then
11659 haveit=yes
11660 break
11662 done
11663 if test -z "$haveit"; then
11664 ltrpathdirs="$ltrpathdirs $found_dir"
11666 if test "$hardcode_direct" = yes; then
11667 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
11668 else
11669 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
11670 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
11671 haveit=
11672 for x in $rpathdirs; do
11673 if test "X$x" = "X$found_dir"; then
11674 haveit=yes
11675 break
11677 done
11678 if test -z "$haveit"; then
11679 rpathdirs="$rpathdirs $found_dir"
11681 else
11682 haveit=
11683 for x in $LDFLAGS $LIBICONV; do
11685 acl_save_prefix="$prefix"
11686 prefix="$acl_final_prefix"
11687 acl_save_exec_prefix="$exec_prefix"
11688 exec_prefix="$acl_final_exec_prefix"
11689 eval x=\"$x\"
11690 exec_prefix="$acl_save_exec_prefix"
11691 prefix="$acl_save_prefix"
11693 if test "X$x" = "X-L$found_dir"; then
11694 haveit=yes
11695 break
11697 done
11698 if test -z "$haveit"; then
11699 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir"
11701 if test "$hardcode_minus_L" != no; then
11702 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
11703 else
11704 LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
11709 else
11710 if test "X$found_a" != "X"; then
11711 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_a"
11712 else
11713 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir -l$name"
11716 additional_includedir=
11717 case "$found_dir" in
11718 */lib | */lib/)
11719 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
11720 additional_includedir="$basedir/include"
11722 esac
11723 if test "X$additional_includedir" != "X"; then
11724 if test "X$additional_includedir" != "X/usr/include"; then
11725 haveit=
11726 if test "X$additional_includedir" = "X/usr/local/include"; then
11727 if test -n "$GCC"; then
11728 case $host_os in
11729 linux*) haveit=yes;;
11730 esac
11733 if test -z "$haveit"; then
11734 for x in $CPPFLAGS $INCICONV; do
11736 acl_save_prefix="$prefix"
11737 prefix="$acl_final_prefix"
11738 acl_save_exec_prefix="$exec_prefix"
11739 exec_prefix="$acl_final_exec_prefix"
11740 eval x=\"$x\"
11741 exec_prefix="$acl_save_exec_prefix"
11742 prefix="$acl_save_prefix"
11744 if test "X$x" = "X-I$additional_includedir"; then
11745 haveit=yes
11746 break
11748 done
11749 if test -z "$haveit"; then
11750 if test -d "$additional_includedir"; then
11751 INCICONV="${INCICONV}${INCICONV:+ }-I$additional_includedir"
11757 if test -n "$found_la"; then
11758 save_libdir="$libdir"
11759 case "$found_la" in
11760 */* | *\\*) . "$found_la" ;;
11761 *) . "./$found_la" ;;
11762 esac
11763 libdir="$save_libdir"
11764 for dep in $dependency_libs; do
11765 case "$dep" in
11766 -L*)
11767 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
11768 if test "X$additional_libdir" != "X/usr/lib"; then
11769 haveit=
11770 if test "X$additional_libdir" = "X/usr/local/lib"; then
11771 if test -n "$GCC"; then
11772 case $host_os in
11773 linux*) haveit=yes;;
11774 esac
11777 if test -z "$haveit"; then
11778 haveit=
11779 for x in $LDFLAGS $LIBICONV; do
11781 acl_save_prefix="$prefix"
11782 prefix="$acl_final_prefix"
11783 acl_save_exec_prefix="$exec_prefix"
11784 exec_prefix="$acl_final_exec_prefix"
11785 eval x=\"$x\"
11786 exec_prefix="$acl_save_exec_prefix"
11787 prefix="$acl_save_prefix"
11789 if test "X$x" = "X-L$additional_libdir"; then
11790 haveit=yes
11791 break
11793 done
11794 if test -z "$haveit"; then
11795 if test -d "$additional_libdir"; then
11796 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$additional_libdir"
11799 haveit=
11800 for x in $LDFLAGS $LTLIBICONV; do
11802 acl_save_prefix="$prefix"
11803 prefix="$acl_final_prefix"
11804 acl_save_exec_prefix="$exec_prefix"
11805 exec_prefix="$acl_final_exec_prefix"
11806 eval x=\"$x\"
11807 exec_prefix="$acl_save_exec_prefix"
11808 prefix="$acl_save_prefix"
11810 if test "X$x" = "X-L$additional_libdir"; then
11811 haveit=yes
11812 break
11814 done
11815 if test -z "$haveit"; then
11816 if test -d "$additional_libdir"; then
11817 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$additional_libdir"
11823 -R*)
11824 dir=`echo "X$dep" | sed -e 's/^X-R//'`
11825 if test "$enable_rpath" != no; then
11826 haveit=
11827 for x in $rpathdirs; do
11828 if test "X$x" = "X$dir"; then
11829 haveit=yes
11830 break
11832 done
11833 if test -z "$haveit"; then
11834 rpathdirs="$rpathdirs $dir"
11836 haveit=
11837 for x in $ltrpathdirs; do
11838 if test "X$x" = "X$dir"; then
11839 haveit=yes
11840 break
11842 done
11843 if test -z "$haveit"; then
11844 ltrpathdirs="$ltrpathdirs $dir"
11848 -l*)
11849 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
11851 *.la)
11852 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
11855 LIBICONV="${LIBICONV}${LIBICONV:+ }$dep"
11856 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$dep"
11858 esac
11859 done
11861 else
11862 if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
11863 LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
11864 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l$name"
11865 else
11866 LIBICONV="${LIBICONV}${LIBICONV:+ }-l:lib$name.$libext"
11867 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l:lib$name.$libext"
11872 done
11873 done
11874 if test "X$rpathdirs" != "X"; then
11875 if test -n "$hardcode_libdir_separator"; then
11876 alldirs=
11877 for found_dir in $rpathdirs; do
11878 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
11879 done
11880 acl_save_libdir="$libdir"
11881 libdir="$alldirs"
11882 eval flag=\"$hardcode_libdir_flag_spec\"
11883 libdir="$acl_save_libdir"
11884 LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
11885 else
11886 for found_dir in $rpathdirs; do
11887 acl_save_libdir="$libdir"
11888 libdir="$found_dir"
11889 eval flag=\"$hardcode_libdir_flag_spec\"
11890 libdir="$acl_save_libdir"
11891 LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
11892 done
11895 if test "X$ltrpathdirs" != "X"; then
11896 for found_dir in $ltrpathdirs; do
11897 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-R$found_dir"
11898 done
11905 if test -f ../gettext/uninstalled-config.sh; then
11906 relative_builddir='$(top_builddir)/../gettext'
11907 . ../gettext/uninstalled-config.sh
11908 else
11909 # The sister gettext directory doesn't exist and won't collect information on
11910 # using gettext for us. Call a bundled AM_GNU_GETTEXT.
11934 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFPreferencesCopyAppValue" >&5
11935 $as_echo_n "checking for CFPreferencesCopyAppValue... " >&6; }
11936 if ${gt_cv_func_CFPreferencesCopyAppValue+:} false; then :
11937 $as_echo_n "(cached) " >&6
11938 else
11939 gt_save_LIBS="$LIBS"
11940 LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
11941 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11942 /* end confdefs.h. */
11943 #include <CoreFoundation/CFPreferences.h>
11945 main ()
11947 CFPreferencesCopyAppValue(NULL, NULL)
11949 return 0;
11951 _ACEOF
11952 if ac_fn_c_try_link "$LINENO"; then :
11953 gt_cv_func_CFPreferencesCopyAppValue=yes
11954 else
11955 gt_cv_func_CFPreferencesCopyAppValue=no
11957 rm -f core conftest.err conftest.$ac_objext \
11958 conftest$ac_exeext conftest.$ac_ext
11959 LIBS="$gt_save_LIBS"
11961 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFPreferencesCopyAppValue" >&5
11962 $as_echo "$gt_cv_func_CFPreferencesCopyAppValue" >&6; }
11963 if test $gt_cv_func_CFPreferencesCopyAppValue = yes; then
11965 $as_echo "#define HAVE_CFPREFERENCESCOPYAPPVALUE 1" >>confdefs.h
11968 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFLocaleCopyPreferredLanguages" >&5
11969 $as_echo_n "checking for CFLocaleCopyPreferredLanguages... " >&6; }
11970 if ${gt_cv_func_CFLocaleCopyPreferredLanguages+:} false; then :
11971 $as_echo_n "(cached) " >&6
11972 else
11973 gt_save_LIBS="$LIBS"
11974 LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
11975 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11976 /* end confdefs.h. */
11977 #include <CoreFoundation/CFLocale.h>
11979 main ()
11981 CFLocaleCopyPreferredLanguages();
11983 return 0;
11985 _ACEOF
11986 if ac_fn_c_try_link "$LINENO"; then :
11987 gt_cv_func_CFLocaleCopyPreferredLanguages=yes
11988 else
11989 gt_cv_func_CFLocaleCopyPreferredLanguages=no
11991 rm -f core conftest.err conftest.$ac_objext \
11992 conftest$ac_exeext conftest.$ac_ext
11993 LIBS="$gt_save_LIBS"
11995 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFLocaleCopyPreferredLanguages" >&5
11996 $as_echo "$gt_cv_func_CFLocaleCopyPreferredLanguages" >&6; }
11997 if test $gt_cv_func_CFLocaleCopyPreferredLanguages = yes; then
11999 $as_echo "#define HAVE_CFLOCALECOPYPREFERREDLANGUAGES 1" >>confdefs.h
12002 INTL_MACOSX_LIBS=
12003 if test $gt_cv_func_CFPreferencesCopyAppValue = yes \
12004 || test $gt_cv_func_CFLocaleCopyPreferredLanguages = yes; then
12005 INTL_MACOSX_LIBS="-Wl,-framework -Wl,CoreFoundation -Wl,-framework -Wl,CoreServices"
12013 LIBINTL=
12014 LTLIBINTL=
12015 POSUB=
12017 case " $gt_needs " in
12018 *" need-formatstring-macros "*) gt_api_version=3 ;;
12019 *" need-ngettext "*) gt_api_version=2 ;;
12020 *) gt_api_version=1 ;;
12021 esac
12022 gt_func_gnugettext_libc="gt_cv_func_gnugettext${gt_api_version}_libc"
12023 gt_func_gnugettext_libintl="gt_cv_func_gnugettext${gt_api_version}_libintl"
12025 if test "$USE_NLS" = "yes"; then
12026 gt_use_preinstalled_gnugettext=no
12029 if test $gt_api_version -ge 3; then
12030 gt_revision_test_code='
12031 #ifndef __GNU_GETTEXT_SUPPORTED_REVISION
12032 #define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 0 : -1)
12033 #endif
12034 typedef int array [2 * (__GNU_GETTEXT_SUPPORTED_REVISION(0) >= 1) - 1];
12036 else
12037 gt_revision_test_code=
12039 if test $gt_api_version -ge 2; then
12040 gt_expression_test_code=' + * ngettext ("", "", 0)'
12041 else
12042 gt_expression_test_code=
12045 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libc" >&5
12046 $as_echo_n "checking for GNU gettext in libc... " >&6; }
12047 if eval \${$gt_func_gnugettext_libc+:} false; then :
12048 $as_echo_n "(cached) " >&6
12049 else
12050 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12051 /* end confdefs.h. */
12053 #include <libintl.h>
12054 #ifndef __GNU_GETTEXT_SUPPORTED_REVISION
12055 extern int _nl_msg_cat_cntr;
12056 extern int *_nl_domain_bindings;
12057 #define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_domain_bindings)
12058 #else
12059 #define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
12060 #endif
12061 $gt_revision_test_code
12064 main ()
12067 bindtextdomain ("", "");
12068 return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
12071 return 0;
12073 _ACEOF
12074 if ac_fn_c_try_link "$LINENO"; then :
12075 eval "$gt_func_gnugettext_libc=yes"
12076 else
12077 eval "$gt_func_gnugettext_libc=no"
12079 rm -f core conftest.err conftest.$ac_objext \
12080 conftest$ac_exeext conftest.$ac_ext
12082 eval ac_res=\$$gt_func_gnugettext_libc
12083 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
12084 $as_echo "$ac_res" >&6; }
12086 if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" != "yes"; }; then
12092 am_save_CPPFLAGS="$CPPFLAGS"
12094 for element in $INCICONV; do
12095 haveit=
12096 for x in $CPPFLAGS; do
12098 acl_save_prefix="$prefix"
12099 prefix="$acl_final_prefix"
12100 acl_save_exec_prefix="$exec_prefix"
12101 exec_prefix="$acl_final_exec_prefix"
12102 eval x=\"$x\"
12103 exec_prefix="$acl_save_exec_prefix"
12104 prefix="$acl_save_prefix"
12106 if test "X$x" = "X$element"; then
12107 haveit=yes
12108 break
12110 done
12111 if test -z "$haveit"; then
12112 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
12114 done
12117 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5
12118 $as_echo_n "checking for iconv... " >&6; }
12119 if ${am_cv_func_iconv+:} false; then :
12120 $as_echo_n "(cached) " >&6
12121 else
12123 am_cv_func_iconv="no, consider installing GNU libiconv"
12124 am_cv_lib_iconv=no
12125 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12126 /* end confdefs.h. */
12128 #include <stdlib.h>
12129 #include <iconv.h>
12132 main ()
12134 iconv_t cd = iconv_open("","");
12135 iconv(cd,NULL,NULL,NULL,NULL);
12136 iconv_close(cd);
12138 return 0;
12140 _ACEOF
12141 if ac_fn_c_try_link "$LINENO"; then :
12142 am_cv_func_iconv=yes
12144 rm -f core conftest.err conftest.$ac_objext \
12145 conftest$ac_exeext conftest.$ac_ext
12146 if test "$am_cv_func_iconv" != yes; then
12147 am_save_LIBS="$LIBS"
12148 LIBS="$LIBS $LIBICONV"
12149 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12150 /* end confdefs.h. */
12152 #include <stdlib.h>
12153 #include <iconv.h>
12156 main ()
12158 iconv_t cd = iconv_open("","");
12159 iconv(cd,NULL,NULL,NULL,NULL);
12160 iconv_close(cd);
12162 return 0;
12164 _ACEOF
12165 if ac_fn_c_try_link "$LINENO"; then :
12166 am_cv_lib_iconv=yes
12167 am_cv_func_iconv=yes
12169 rm -f core conftest.err conftest.$ac_objext \
12170 conftest$ac_exeext conftest.$ac_ext
12171 LIBS="$am_save_LIBS"
12175 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5
12176 $as_echo "$am_cv_func_iconv" >&6; }
12177 if test "$am_cv_func_iconv" = yes; then
12178 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working iconv" >&5
12179 $as_echo_n "checking for working iconv... " >&6; }
12180 if ${am_cv_func_iconv_works+:} false; then :
12181 $as_echo_n "(cached) " >&6
12182 else
12184 am_save_LIBS="$LIBS"
12185 if test $am_cv_lib_iconv = yes; then
12186 LIBS="$LIBS $LIBICONV"
12188 am_cv_func_iconv_works=no
12189 for ac_iconv_const in '' 'const'; do
12190 if test "$cross_compiling" = yes; then :
12191 case "$host_os" in
12192 aix* | hpux*) am_cv_func_iconv_works="guessing no" ;;
12193 *) am_cv_func_iconv_works="guessing yes" ;;
12194 esac
12195 else
12196 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12197 /* end confdefs.h. */
12199 #include <iconv.h>
12200 #include <string.h>
12202 #ifndef ICONV_CONST
12203 # define ICONV_CONST $ac_iconv_const
12204 #endif
12207 main ()
12209 int result = 0;
12210 /* Test against AIX 5.1...7.2 bug: Failures are not distinguishable from
12211 successful returns. This is even documented in
12212 <https://www.ibm.com/support/knowledgecenter/ssw_aix_72/i_bostechref/iconv.html> */
12214 iconv_t cd_utf8_to_88591 = iconv_open ("ISO8859-1", "UTF-8");
12215 if (cd_utf8_to_88591 != (iconv_t)(-1))
12217 static ICONV_CONST char input[] = "\342\202\254"; /* EURO SIGN */
12218 char buf[10];
12219 ICONV_CONST char *inptr = input;
12220 size_t inbytesleft = strlen (input);
12221 char *outptr = buf;
12222 size_t outbytesleft = sizeof (buf);
12223 size_t res = iconv (cd_utf8_to_88591,
12224 &inptr, &inbytesleft,
12225 &outptr, &outbytesleft);
12226 if (res == 0)
12227 result |= 1;
12228 iconv_close (cd_utf8_to_88591);
12231 /* Test against Solaris 10 bug: Failures are not distinguishable from
12232 successful returns. */
12234 iconv_t cd_ascii_to_88591 = iconv_open ("ISO8859-1", "646");
12235 if (cd_ascii_to_88591 != (iconv_t)(-1))
12237 static ICONV_CONST char input[] = "\263";
12238 char buf[10];
12239 ICONV_CONST char *inptr = input;
12240 size_t inbytesleft = strlen (input);
12241 char *outptr = buf;
12242 size_t outbytesleft = sizeof (buf);
12243 size_t res = iconv (cd_ascii_to_88591,
12244 &inptr, &inbytesleft,
12245 &outptr, &outbytesleft);
12246 if (res == 0)
12247 result |= 2;
12248 iconv_close (cd_ascii_to_88591);
12251 /* Test against AIX 6.1..7.1 bug: Buffer overrun. */
12253 iconv_t cd_88591_to_utf8 = iconv_open ("UTF-8", "ISO-8859-1");
12254 if (cd_88591_to_utf8 != (iconv_t)(-1))
12256 static ICONV_CONST char input[] = "\304";
12257 static char buf[2] = { (char)0xDE, (char)0xAD };
12258 ICONV_CONST char *inptr = input;
12259 size_t inbytesleft = 1;
12260 char *outptr = buf;
12261 size_t outbytesleft = 1;
12262 size_t res = iconv (cd_88591_to_utf8,
12263 &inptr, &inbytesleft,
12264 &outptr, &outbytesleft);
12265 if (res != (size_t)(-1) || outptr - buf > 1 || buf[1] != (char)0xAD)
12266 result |= 4;
12267 iconv_close (cd_88591_to_utf8);
12270 #if 0 /* This bug could be worked around by the caller. */
12271 /* Test against HP-UX 11.11 bug: Positive return value instead of 0. */
12273 iconv_t cd_88591_to_utf8 = iconv_open ("utf8", "iso88591");
12274 if (cd_88591_to_utf8 != (iconv_t)(-1))
12276 static ICONV_CONST char input[] = "\304rger mit b\366sen B\374bchen ohne Augenma\337";
12277 char buf[50];
12278 ICONV_CONST char *inptr = input;
12279 size_t inbytesleft = strlen (input);
12280 char *outptr = buf;
12281 size_t outbytesleft = sizeof (buf);
12282 size_t res = iconv (cd_88591_to_utf8,
12283 &inptr, &inbytesleft,
12284 &outptr, &outbytesleft);
12285 if ((int)res > 0)
12286 result |= 8;
12287 iconv_close (cd_88591_to_utf8);
12290 #endif
12291 /* Test against HP-UX 11.11 bug: No converter from EUC-JP to UTF-8 is
12292 provided. */
12294 /* Try standardized names. */
12295 iconv_t cd1 = iconv_open ("UTF-8", "EUC-JP");
12296 /* Try IRIX, OSF/1 names. */
12297 iconv_t cd2 = iconv_open ("UTF-8", "eucJP");
12298 /* Try AIX names. */
12299 iconv_t cd3 = iconv_open ("UTF-8", "IBM-eucJP");
12300 /* Try HP-UX names. */
12301 iconv_t cd4 = iconv_open ("utf8", "eucJP");
12302 if (cd1 == (iconv_t)(-1) && cd2 == (iconv_t)(-1)
12303 && cd3 == (iconv_t)(-1) && cd4 == (iconv_t)(-1))
12304 result |= 16;
12305 if (cd1 != (iconv_t)(-1))
12306 iconv_close (cd1);
12307 if (cd2 != (iconv_t)(-1))
12308 iconv_close (cd2);
12309 if (cd3 != (iconv_t)(-1))
12310 iconv_close (cd3);
12311 if (cd4 != (iconv_t)(-1))
12312 iconv_close (cd4);
12314 return result;
12317 return 0;
12319 _ACEOF
12320 if ac_fn_c_try_run "$LINENO"; then :
12321 am_cv_func_iconv_works=yes
12323 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12324 conftest.$ac_objext conftest.beam conftest.$ac_ext
12327 test "$am_cv_func_iconv_works" = no || break
12328 done
12329 LIBS="$am_save_LIBS"
12332 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv_works" >&5
12333 $as_echo "$am_cv_func_iconv_works" >&6; }
12334 case "$am_cv_func_iconv_works" in
12335 *no) am_func_iconv=no am_cv_lib_iconv=no ;;
12336 *) am_func_iconv=yes ;;
12337 esac
12338 else
12339 am_func_iconv=no am_cv_lib_iconv=no
12341 if test "$am_func_iconv" = yes; then
12343 $as_echo "#define HAVE_ICONV 1" >>confdefs.h
12346 if test "$am_cv_lib_iconv" = yes; then
12347 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libiconv" >&5
12348 $as_echo_n "checking how to link with libiconv... " >&6; }
12349 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBICONV" >&5
12350 $as_echo "$LIBICONV" >&6; }
12351 else
12352 CPPFLAGS="$am_save_CPPFLAGS"
12353 LIBICONV=
12354 LTLIBICONV=
12362 use_additional=yes
12364 acl_save_prefix="$prefix"
12365 prefix="$acl_final_prefix"
12366 acl_save_exec_prefix="$exec_prefix"
12367 exec_prefix="$acl_final_exec_prefix"
12369 eval additional_includedir=\"$includedir\"
12370 eval additional_libdir=\"$libdir\"
12372 exec_prefix="$acl_save_exec_prefix"
12373 prefix="$acl_save_prefix"
12376 # Check whether --with-libintl-prefix was given.
12377 if test "${with_libintl_prefix+set}" = set; then :
12378 withval=$with_libintl_prefix;
12379 if test "X$withval" = "Xno"; then
12380 use_additional=no
12381 else
12382 if test "X$withval" = "X"; then
12384 acl_save_prefix="$prefix"
12385 prefix="$acl_final_prefix"
12386 acl_save_exec_prefix="$exec_prefix"
12387 exec_prefix="$acl_final_exec_prefix"
12389 eval additional_includedir=\"$includedir\"
12390 eval additional_libdir=\"$libdir\"
12392 exec_prefix="$acl_save_exec_prefix"
12393 prefix="$acl_save_prefix"
12395 else
12396 additional_includedir="$withval/include"
12397 additional_libdir="$withval/lib"
12404 # Check whether --with-libintl-type was given.
12405 if test "${with_libintl_type+set}" = set; then :
12406 withval=$with_libintl_type; with_libintl_type=$withval
12407 else
12408 with_libintl_type=auto
12411 lib_type=`eval echo \$with_libintl_type`
12413 LIBINTL=
12414 LTLIBINTL=
12415 INCINTL=
12416 rpathdirs=
12417 ltrpathdirs=
12418 names_already_handled=
12419 names_next_round='intl '
12420 while test -n "$names_next_round"; do
12421 names_this_round="$names_next_round"
12422 names_next_round=
12423 for name in $names_this_round; do
12424 already_handled=
12425 for n in $names_already_handled; do
12426 if test "$n" = "$name"; then
12427 already_handled=yes
12428 break
12430 done
12431 if test -z "$already_handled"; then
12432 names_already_handled="$names_already_handled $name"
12433 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
12434 eval value=\"\$HAVE_LIB$uppername\"
12435 if test -n "$value"; then
12436 if test "$value" = yes; then
12437 eval value=\"\$LIB$uppername\"
12438 test -z "$value" || LIBINTL="${LIBINTL}${LIBINTL:+ }$value"
12439 eval value=\"\$LTLIB$uppername\"
12440 test -z "$value" || LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$value"
12441 else
12444 else
12445 found_dir=
12446 found_la=
12447 found_so=
12448 found_a=
12449 if test $use_additional = yes; then
12450 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
12451 found_dir="$additional_libdir"
12452 found_so="$additional_libdir/lib$name.$shlibext"
12453 if test -f "$additional_libdir/lib$name.la"; then
12454 found_la="$additional_libdir/lib$name.la"
12456 elif test x$lib_type != xshared; then
12457 if test -f "$additional_libdir/lib$name.$libext"; then
12458 found_dir="$additional_libdir"
12459 found_a="$additional_libdir/lib$name.$libext"
12460 if test -f "$additional_libdir/lib$name.la"; then
12461 found_la="$additional_libdir/lib$name.la"
12466 if test "X$found_dir" = "X"; then
12467 for x in $LDFLAGS $LTLIBINTL; do
12469 acl_save_prefix="$prefix"
12470 prefix="$acl_final_prefix"
12471 acl_save_exec_prefix="$exec_prefix"
12472 exec_prefix="$acl_final_exec_prefix"
12473 eval x=\"$x\"
12474 exec_prefix="$acl_save_exec_prefix"
12475 prefix="$acl_save_prefix"
12477 case "$x" in
12478 -L*)
12479 dir=`echo "X$x" | sed -e 's/^X-L//'`
12480 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
12481 found_dir="$dir"
12482 found_so="$dir/lib$name.$shlibext"
12483 if test -f "$dir/lib$name.la"; then
12484 found_la="$dir/lib$name.la"
12486 elif test x$lib_type != xshared; then
12487 if test -f "$dir/lib$name.$libext"; then
12488 found_dir="$dir"
12489 found_a="$dir/lib$name.$libext"
12490 if test -f "$dir/lib$name.la"; then
12491 found_la="$dir/lib$name.la"
12496 esac
12497 if test "X$found_dir" != "X"; then
12498 break
12500 done
12502 if test "X$found_dir" != "X"; then
12503 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$found_dir -l$name"
12504 if test "X$found_so" != "X"; then
12505 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
12506 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
12507 else
12508 haveit=
12509 for x in $ltrpathdirs; do
12510 if test "X$x" = "X$found_dir"; then
12511 haveit=yes
12512 break
12514 done
12515 if test -z "$haveit"; then
12516 ltrpathdirs="$ltrpathdirs $found_dir"
12518 if test "$hardcode_direct" = yes; then
12519 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
12520 else
12521 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
12522 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
12523 haveit=
12524 for x in $rpathdirs; do
12525 if test "X$x" = "X$found_dir"; then
12526 haveit=yes
12527 break
12529 done
12530 if test -z "$haveit"; then
12531 rpathdirs="$rpathdirs $found_dir"
12533 else
12534 haveit=
12535 for x in $LDFLAGS $LIBINTL; do
12537 acl_save_prefix="$prefix"
12538 prefix="$acl_final_prefix"
12539 acl_save_exec_prefix="$exec_prefix"
12540 exec_prefix="$acl_final_exec_prefix"
12541 eval x=\"$x\"
12542 exec_prefix="$acl_save_exec_prefix"
12543 prefix="$acl_save_prefix"
12545 if test "X$x" = "X-L$found_dir"; then
12546 haveit=yes
12547 break
12549 done
12550 if test -z "$haveit"; then
12551 LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir"
12553 if test "$hardcode_minus_L" != no; then
12554 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
12555 else
12556 LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name"
12561 else
12562 if test "X$found_a" != "X"; then
12563 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_a"
12564 else
12565 LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir -l$name"
12568 additional_includedir=
12569 case "$found_dir" in
12570 */lib | */lib/)
12571 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
12572 additional_includedir="$basedir/include"
12574 esac
12575 if test "X$additional_includedir" != "X"; then
12576 if test "X$additional_includedir" != "X/usr/include"; then
12577 haveit=
12578 if test "X$additional_includedir" = "X/usr/local/include"; then
12579 if test -n "$GCC"; then
12580 case $host_os in
12581 linux*) haveit=yes;;
12582 esac
12585 if test -z "$haveit"; then
12586 for x in $CPPFLAGS $INCINTL; do
12588 acl_save_prefix="$prefix"
12589 prefix="$acl_final_prefix"
12590 acl_save_exec_prefix="$exec_prefix"
12591 exec_prefix="$acl_final_exec_prefix"
12592 eval x=\"$x\"
12593 exec_prefix="$acl_save_exec_prefix"
12594 prefix="$acl_save_prefix"
12596 if test "X$x" = "X-I$additional_includedir"; then
12597 haveit=yes
12598 break
12600 done
12601 if test -z "$haveit"; then
12602 if test -d "$additional_includedir"; then
12603 INCINTL="${INCINTL}${INCINTL:+ }-I$additional_includedir"
12609 if test -n "$found_la"; then
12610 save_libdir="$libdir"
12611 case "$found_la" in
12612 */* | *\\*) . "$found_la" ;;
12613 *) . "./$found_la" ;;
12614 esac
12615 libdir="$save_libdir"
12616 for dep in $dependency_libs; do
12617 case "$dep" in
12618 -L*)
12619 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
12620 if test "X$additional_libdir" != "X/usr/lib"; then
12621 haveit=
12622 if test "X$additional_libdir" = "X/usr/local/lib"; then
12623 if test -n "$GCC"; then
12624 case $host_os in
12625 linux*) haveit=yes;;
12626 esac
12629 if test -z "$haveit"; then
12630 haveit=
12631 for x in $LDFLAGS $LIBINTL; do
12633 acl_save_prefix="$prefix"
12634 prefix="$acl_final_prefix"
12635 acl_save_exec_prefix="$exec_prefix"
12636 exec_prefix="$acl_final_exec_prefix"
12637 eval x=\"$x\"
12638 exec_prefix="$acl_save_exec_prefix"
12639 prefix="$acl_save_prefix"
12641 if test "X$x" = "X-L$additional_libdir"; then
12642 haveit=yes
12643 break
12645 done
12646 if test -z "$haveit"; then
12647 if test -d "$additional_libdir"; then
12648 LIBINTL="${LIBINTL}${LIBINTL:+ }-L$additional_libdir"
12651 haveit=
12652 for x in $LDFLAGS $LTLIBINTL; do
12654 acl_save_prefix="$prefix"
12655 prefix="$acl_final_prefix"
12656 acl_save_exec_prefix="$exec_prefix"
12657 exec_prefix="$acl_final_exec_prefix"
12658 eval x=\"$x\"
12659 exec_prefix="$acl_save_exec_prefix"
12660 prefix="$acl_save_prefix"
12662 if test "X$x" = "X-L$additional_libdir"; then
12663 haveit=yes
12664 break
12666 done
12667 if test -z "$haveit"; then
12668 if test -d "$additional_libdir"; then
12669 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$additional_libdir"
12675 -R*)
12676 dir=`echo "X$dep" | sed -e 's/^X-R//'`
12677 if test "$enable_rpath" != no; then
12678 haveit=
12679 for x in $rpathdirs; do
12680 if test "X$x" = "X$dir"; then
12681 haveit=yes
12682 break
12684 done
12685 if test -z "$haveit"; then
12686 rpathdirs="$rpathdirs $dir"
12688 haveit=
12689 for x in $ltrpathdirs; do
12690 if test "X$x" = "X$dir"; then
12691 haveit=yes
12692 break
12694 done
12695 if test -z "$haveit"; then
12696 ltrpathdirs="$ltrpathdirs $dir"
12700 -l*)
12701 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
12703 *.la)
12704 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
12707 LIBINTL="${LIBINTL}${LIBINTL:+ }$dep"
12708 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$dep"
12710 esac
12711 done
12713 else
12714 if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
12715 LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name"
12716 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-l$name"
12717 else
12718 LIBINTL="${LIBINTL}${LIBINTL:+ }-l:lib$name.$libext"
12719 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-l:lib$name.$libext"
12724 done
12725 done
12726 if test "X$rpathdirs" != "X"; then
12727 if test -n "$hardcode_libdir_separator"; then
12728 alldirs=
12729 for found_dir in $rpathdirs; do
12730 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
12731 done
12732 acl_save_libdir="$libdir"
12733 libdir="$alldirs"
12734 eval flag=\"$hardcode_libdir_flag_spec\"
12735 libdir="$acl_save_libdir"
12736 LIBINTL="${LIBINTL}${LIBINTL:+ }$flag"
12737 else
12738 for found_dir in $rpathdirs; do
12739 acl_save_libdir="$libdir"
12740 libdir="$found_dir"
12741 eval flag=\"$hardcode_libdir_flag_spec\"
12742 libdir="$acl_save_libdir"
12743 LIBINTL="${LIBINTL}${LIBINTL:+ }$flag"
12744 done
12747 if test "X$ltrpathdirs" != "X"; then
12748 for found_dir in $ltrpathdirs; do
12749 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-R$found_dir"
12750 done
12753 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libintl" >&5
12754 $as_echo_n "checking for GNU gettext in libintl... " >&6; }
12755 if eval \${$gt_func_gnugettext_libintl+:} false; then :
12756 $as_echo_n "(cached) " >&6
12757 else
12758 gt_save_CPPFLAGS="$CPPFLAGS"
12759 CPPFLAGS="$CPPFLAGS $INCINTL"
12760 gt_save_LIBS="$LIBS"
12761 LIBS="$LIBS $LIBINTL"
12762 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12763 /* end confdefs.h. */
12765 #include <libintl.h>
12766 #ifndef __GNU_GETTEXT_SUPPORTED_REVISION
12767 extern int _nl_msg_cat_cntr;
12768 extern
12769 #ifdef __cplusplus
12771 #endif
12772 const char *_nl_expand_alias (const char *);
12773 #define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_expand_alias (""))
12774 #else
12775 #define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
12776 #endif
12777 $gt_revision_test_code
12780 main ()
12783 bindtextdomain ("", "");
12784 return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
12787 return 0;
12789 _ACEOF
12790 if ac_fn_c_try_link "$LINENO"; then :
12791 eval "$gt_func_gnugettext_libintl=yes"
12792 else
12793 eval "$gt_func_gnugettext_libintl=no"
12795 rm -f core conftest.err conftest.$ac_objext \
12796 conftest$ac_exeext conftest.$ac_ext
12797 if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" != yes; } && test -n "$LIBICONV"; then
12798 LIBS="$LIBS $LIBICONV"
12799 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12800 /* end confdefs.h. */
12802 #include <libintl.h>
12803 #ifndef __GNU_GETTEXT_SUPPORTED_REVISION
12804 extern int _nl_msg_cat_cntr;
12805 extern
12806 #ifdef __cplusplus
12808 #endif
12809 const char *_nl_expand_alias (const char *);
12810 #define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_expand_alias (""))
12811 #else
12812 #define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
12813 #endif
12814 $gt_revision_test_code
12817 main ()
12820 bindtextdomain ("", "");
12821 return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
12824 return 0;
12826 _ACEOF
12827 if ac_fn_c_try_link "$LINENO"; then :
12828 LIBINTL="$LIBINTL $LIBICONV"
12829 LTLIBINTL="$LTLIBINTL $LTLIBICONV"
12830 eval "$gt_func_gnugettext_libintl=yes"
12833 rm -f core conftest.err conftest.$ac_objext \
12834 conftest$ac_exeext conftest.$ac_ext
12836 CPPFLAGS="$gt_save_CPPFLAGS"
12837 LIBS="$gt_save_LIBS"
12839 eval ac_res=\$$gt_func_gnugettext_libintl
12840 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
12841 $as_echo "$ac_res" >&6; }
12844 if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" = "yes"; } \
12845 || { { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; } \
12846 && test "$PACKAGE" != gettext-runtime \
12847 && test "$PACKAGE" != gettext-tools; }; then
12848 gt_use_preinstalled_gnugettext=yes
12849 else
12850 LIBINTL=
12851 LTLIBINTL=
12852 INCINTL=
12857 if test -n "$INTL_MACOSX_LIBS"; then
12858 if test "$gt_use_preinstalled_gnugettext" = "yes" \
12859 || test "$nls_cv_use_gnu_gettext" = "yes"; then
12860 LIBINTL="$LIBINTL $INTL_MACOSX_LIBS"
12861 LTLIBINTL="$LTLIBINTL $INTL_MACOSX_LIBS"
12865 if test "$gt_use_preinstalled_gnugettext" = "yes" \
12866 || test "$nls_cv_use_gnu_gettext" = "yes"; then
12868 $as_echo "#define ENABLE_NLS 1" >>confdefs.h
12870 else
12871 USE_NLS=no
12875 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use NLS" >&5
12876 $as_echo_n "checking whether to use NLS... " >&6; }
12877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5
12878 $as_echo "$USE_NLS" >&6; }
12879 if test "$USE_NLS" = "yes"; then
12880 { $as_echo "$as_me:${as_lineno-$LINENO}: checking where the gettext function comes from" >&5
12881 $as_echo_n "checking where the gettext function comes from... " >&6; }
12882 if test "$gt_use_preinstalled_gnugettext" = "yes"; then
12883 if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
12884 gt_source="external libintl"
12885 else
12886 gt_source="libc"
12888 else
12889 gt_source="included intl directory"
12891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_source" >&5
12892 $as_echo "$gt_source" >&6; }
12895 if test "$USE_NLS" = "yes"; then
12897 if test "$gt_use_preinstalled_gnugettext" = "yes"; then
12898 if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
12899 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libintl" >&5
12900 $as_echo_n "checking how to link with libintl... " >&6; }
12901 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBINTL" >&5
12902 $as_echo "$LIBINTL" >&6; }
12904 for element in $INCINTL; do
12905 haveit=
12906 for x in $CPPFLAGS; do
12908 acl_save_prefix="$prefix"
12909 prefix="$acl_final_prefix"
12910 acl_save_exec_prefix="$exec_prefix"
12911 exec_prefix="$acl_final_exec_prefix"
12912 eval x=\"$x\"
12913 exec_prefix="$acl_save_exec_prefix"
12914 prefix="$acl_save_prefix"
12916 if test "X$x" = "X$element"; then
12917 haveit=yes
12918 break
12920 done
12921 if test -z "$haveit"; then
12922 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
12924 done
12929 $as_echo "#define HAVE_GETTEXT 1" >>confdefs.h
12932 $as_echo "#define HAVE_DCGETTEXT 1" >>confdefs.h
12936 POSUB=po
12941 INTLLIBS="$LIBINTL"
12960 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5
12961 $as_echo_n "checking whether NLS is requested... " >&6; }
12962 if test x"$USE_NLS" != xyes; then
12963 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12964 $as_echo "no" >&6; }
12965 else
12966 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12967 $as_echo "yes" >&6; }
12969 $as_echo "#define ENABLE_NLS 1" >>confdefs.h
12972 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for catalogs to be installed" >&5
12973 $as_echo_n "checking for catalogs to be installed... " >&6; }
12974 # Look for .po and .gmo files in the source directory.
12975 CATALOGS=
12976 XLINGUAS=
12977 for cat in $srcdir/po/*.gmo $srcdir/po/*.po; do
12978 # If there aren't any .gmo files the shell will give us the
12979 # literal string "../path/to/srcdir/po/*.gmo" which has to be
12980 # weeded out.
12981 case "$cat" in *\**)
12982 continue;;
12983 esac
12984 # The quadruple backslash is collapsed to a double backslash
12985 # by the backticks, then collapsed again by the double quotes,
12986 # leaving us with one backslash in the sed expression (right
12987 # before the dot that mustn't act as a wildcard).
12988 cat=`echo $cat | sed -e "s!$srcdir/po/!!" -e "s!\\\\.po!.gmo!"`
12989 lang=`echo $cat | sed -e "s!\\\\.gmo!!"`
12990 # The user is allowed to set LINGUAS to a list of languages to
12991 # install catalogs for. If it's empty that means "all of them."
12992 if test "x$LINGUAS" = x; then
12993 CATALOGS="$CATALOGS $cat"
12994 XLINGUAS="$XLINGUAS $lang"
12995 else
12996 case "$LINGUAS" in *$lang*)
12997 CATALOGS="$CATALOGS $cat"
12998 XLINGUAS="$XLINGUAS $lang"
13000 esac
13002 done
13003 LINGUAS="$XLINGUAS"
13004 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINGUAS" >&5
13005 $as_echo "$LINGUAS" >&6; }
13008 DATADIRNAME=share
13010 INSTOBJEXT=.mo
13012 GENCAT=gencat
13014 CATOBJEXT=.gmo
13018 # Create sub-directories for objects and dependencies.
13019 CONFIG_SRC_SUBDIR="arch gdbsupport nat target"
13022 ac_config_commands="$ac_config_commands gdbdepdir"
13025 depcc="$CC" am_compiler_list=
13027 am_depcomp=$ac_aux_dir/depcomp
13028 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
13029 $as_echo_n "checking dependency style of $depcc... " >&6; }
13030 if ${am_cv_CC_dependencies_compiler_type+:} false; then :
13031 $as_echo_n "(cached) " >&6
13032 else
13033 if test -f "$am_depcomp"; then
13034 # We make a subdir and do the tests there. Otherwise we can end up
13035 # making bogus files that we don't know about and never remove. For
13036 # instance it was reported that on HP-UX the gcc test will end up
13037 # making a dummy file named `D' -- because `-MD' means `put the output
13038 # in D'.
13039 mkdir conftest.dir
13040 # Copy depcomp to subdir because otherwise we won't find it if we're
13041 # using a relative directory.
13042 cp "$am_depcomp" conftest.dir
13043 cd conftest.dir
13044 # We will build objects and dependencies in a subdirectory because
13045 # it helps to detect inapplicable dependency modes. For instance
13046 # both Tru64's cc and ICC support -MD to output dependencies as a
13047 # side effect of compilation, but ICC will put the dependencies in
13048 # the current directory while Tru64 will put them in the object
13049 # directory.
13050 mkdir sub
13052 am_cv_CC_dependencies_compiler_type=none
13053 if test "$am_compiler_list" = ""; then
13054 am_compiler_list=`sed -n 's/^\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
13056 for depmode in $am_compiler_list; do
13057 if test $depmode = none; then break; fi
13059 $as_echo "$as_me:$LINENO: trying $depmode" >&5
13060 # Setup a source with many dependencies, because some compilers
13061 # like to wrap large dependency lists on column 80 (with \), and
13062 # we should not choose a depcomp mode which is confused by this.
13064 # We need to recreate these files for each test, as the compiler may
13065 # overwrite some of them when testing with obscure command lines.
13066 # This happens at least with the AIX C compiler.
13067 : > sub/conftest.c
13068 for i in 1 2 3 4 5 6; do
13069 echo '#include "conftst'$i'.h"' >> sub/conftest.c
13070 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
13071 # Solaris 8's {/usr,}/bin/sh.
13072 touch sub/conftst$i.h
13073 done
13074 echo "include sub/conftest.Po" > confmf
13076 # We check with `-c' and `-o' for the sake of the "dashmstdout"
13077 # mode. It turns out that the SunPro C++ compiler does not properly
13078 # handle `-M -o', and we need to detect this.
13079 depcmd="depmode=$depmode \
13080 source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
13081 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
13082 $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c"
13083 echo "| $depcmd" | sed -e 's/ */ /g' >&5
13084 if env $depcmd > conftest.err 2>&1 &&
13085 grep sub/conftst6.h sub/conftest.Po >>conftest.err 2>&1 &&
13086 grep sub/conftest.${OBJEXT-o} sub/conftest.Po >>conftest.err 2>&1 &&
13087 ${MAKE-make} -s -f confmf >>conftest.err 2>&1; then
13088 # icc doesn't choke on unknown options, it will just issue warnings
13089 # or remarks (even with -Werror). So we grep stderr for any message
13090 # that says an option was ignored or not supported.
13091 # When given -MP, icc 7.0 and 7.1 complain thusly:
13092 # icc: Command line warning: ignoring option '-M'; no argument required
13093 # The diagnosis changed in icc 8.0:
13094 # icc: Command line remark: option '-MP' not supported
13095 if (grep 'ignoring option' conftest.err ||
13096 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
13097 am_cv_CC_dependencies_compiler_type=$depmode
13098 $as_echo "$as_me:$LINENO: success" >&5
13099 break
13102 $as_echo "$as_me:$LINENO: failure, diagnostics are:" >&5
13103 sed -e 's/^/| /' < conftest.err >&5
13104 done
13106 cd ..
13107 rm -rf conftest.dir
13108 else
13109 am_cv_CC_dependencies_compiler_type=none
13113 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
13114 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
13115 if test x${am_cv_CC_dependencies_compiler_type-none} = xnone
13116 then as_fn_error $? "no usable dependency style found" "$LINENO" 5
13117 else CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
13122 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
13123 do :
13124 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13125 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
13126 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
13127 cat >>confdefs.h <<_ACEOF
13128 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13129 _ACEOF
13133 done
13135 for ac_header in vfork.h
13136 do :
13137 ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
13138 if test "x$ac_cv_header_vfork_h" = xyes; then :
13139 cat >>confdefs.h <<_ACEOF
13140 #define HAVE_VFORK_H 1
13141 _ACEOF
13145 done
13147 for ac_func in fork vfork
13148 do :
13149 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13150 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13151 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
13152 cat >>confdefs.h <<_ACEOF
13153 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13154 _ACEOF
13157 done
13159 if test "x$ac_cv_func_fork" = xyes; then
13160 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
13161 $as_echo_n "checking for working fork... " >&6; }
13162 if ${ac_cv_func_fork_works+:} false; then :
13163 $as_echo_n "(cached) " >&6
13164 else
13165 if test "$cross_compiling" = yes; then :
13166 ac_cv_func_fork_works=cross
13167 else
13168 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13169 /* end confdefs.h. */
13170 $ac_includes_default
13172 main ()
13175 /* By Ruediger Kuhlmann. */
13176 return fork () < 0;
13179 return 0;
13181 _ACEOF
13182 if ac_fn_c_try_run "$LINENO"; then :
13183 ac_cv_func_fork_works=yes
13184 else
13185 ac_cv_func_fork_works=no
13187 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13188 conftest.$ac_objext conftest.beam conftest.$ac_ext
13192 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
13193 $as_echo "$ac_cv_func_fork_works" >&6; }
13195 else
13196 ac_cv_func_fork_works=$ac_cv_func_fork
13198 if test "x$ac_cv_func_fork_works" = xcross; then
13199 case $host in
13200 *-*-amigaos* | *-*-msdosdjgpp*)
13201 # Override, as these systems have only a dummy fork() stub
13202 ac_cv_func_fork_works=no
13205 ac_cv_func_fork_works=yes
13207 esac
13208 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
13209 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
13211 ac_cv_func_vfork_works=$ac_cv_func_vfork
13212 if test "x$ac_cv_func_vfork" = xyes; then
13213 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
13214 $as_echo_n "checking for working vfork... " >&6; }
13215 if ${ac_cv_func_vfork_works+:} false; then :
13216 $as_echo_n "(cached) " >&6
13217 else
13218 if test "$cross_compiling" = yes; then :
13219 ac_cv_func_vfork_works=cross
13220 else
13221 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13222 /* end confdefs.h. */
13223 /* Thanks to Paul Eggert for this test. */
13224 $ac_includes_default
13225 #include <sys/wait.h>
13226 #ifdef HAVE_VFORK_H
13227 # include <vfork.h>
13228 #endif
13229 /* On some sparc systems, changes by the child to local and incoming
13230 argument registers are propagated back to the parent. The compiler
13231 is told about this with #include <vfork.h>, but some compilers
13232 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
13233 static variable whose address is put into a register that is
13234 clobbered by the vfork. */
13235 static void
13236 #ifdef __cplusplus
13237 sparc_address_test (int arg)
13238 # else
13239 sparc_address_test (arg) int arg;
13240 #endif
13242 static pid_t child;
13243 if (!child) {
13244 child = vfork ();
13245 if (child < 0) {
13246 perror ("vfork");
13247 _exit(2);
13249 if (!child) {
13250 arg = getpid();
13251 write(-1, "", 0);
13252 _exit (arg);
13258 main ()
13260 pid_t parent = getpid ();
13261 pid_t child;
13263 sparc_address_test (0);
13265 child = vfork ();
13267 if (child == 0) {
13268 /* Here is another test for sparc vfork register problems. This
13269 test uses lots of local variables, at least as many local
13270 variables as main has allocated so far including compiler
13271 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
13272 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
13273 reuse the register of parent for one of the local variables,
13274 since it will think that parent can't possibly be used any more
13275 in this routine. Assigning to the local variable will thus
13276 munge parent in the parent process. */
13277 pid_t
13278 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
13279 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
13280 /* Convince the compiler that p..p7 are live; otherwise, it might
13281 use the same hardware register for all 8 local variables. */
13282 if (p != p1 || p != p2 || p != p3 || p != p4
13283 || p != p5 || p != p6 || p != p7)
13284 _exit(1);
13286 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
13287 from child file descriptors. If the child closes a descriptor
13288 before it execs or exits, this munges the parent's descriptor
13289 as well. Test for this by closing stdout in the child. */
13290 _exit(close(fileno(stdout)) != 0);
13291 } else {
13292 int status;
13293 struct stat st;
13295 while (wait(&status) != child)
13297 return (
13298 /* Was there some problem with vforking? */
13299 child < 0
13301 /* Did the child fail? (This shouldn't happen.) */
13302 || status
13304 /* Did the vfork/compiler bug occur? */
13305 || parent != getpid()
13307 /* Did the file descriptor bug occur? */
13308 || fstat(fileno(stdout), &st) != 0
13312 _ACEOF
13313 if ac_fn_c_try_run "$LINENO"; then :
13314 ac_cv_func_vfork_works=yes
13315 else
13316 ac_cv_func_vfork_works=no
13318 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13319 conftest.$ac_objext conftest.beam conftest.$ac_ext
13323 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
13324 $as_echo "$ac_cv_func_vfork_works" >&6; }
13327 if test "x$ac_cv_func_fork_works" = xcross; then
13328 ac_cv_func_vfork_works=$ac_cv_func_vfork
13329 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
13330 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
13333 if test "x$ac_cv_func_vfork_works" = xyes; then
13335 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
13337 else
13339 $as_echo "#define vfork fork" >>confdefs.h
13342 if test "x$ac_cv_func_fork_works" = xyes; then
13344 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
13348 for ac_func in pread pwrite pread64
13349 do :
13350 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13351 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13352 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
13353 cat >>confdefs.h <<_ACEOF
13354 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13355 _ACEOF
13358 done
13361 # Check the return and argument types of ptrace.
13364 for ac_header in sys/ptrace.h ptrace.h
13365 do :
13366 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13367 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
13368 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
13369 cat >>confdefs.h <<_ACEOF
13370 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13371 _ACEOF
13375 done
13378 gdb_ptrace_headers='
13379 #include <sys/types.h>
13380 #if HAVE_SYS_PTRACE_H
13381 # include <sys/ptrace.h>
13382 #endif
13383 #if HAVE_UNISTD_H
13384 # include <unistd.h>
13385 #endif
13388 # Check return type. Varargs (used on GNU/Linux) conflict with the
13389 # empty argument list, so check for that explicitly.
13390 { $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of ptrace" >&5
13391 $as_echo_n "checking return type of ptrace... " >&6; }
13392 if ${gdb_cv_func_ptrace_ret+:} false; then :
13393 $as_echo_n "(cached) " >&6
13394 else
13395 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13396 /* end confdefs.h. */
13397  $gdb_ptrace_headers
13399 main ()
13401 extern long ptrace (enum __ptrace_request, ...);
13404 return 0;
13406 _ACEOF
13407 if ac_fn_c_try_compile "$LINENO"; then :
13408 gdb_cv_func_ptrace_ret='long'
13409 else
13410 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13411 /* end confdefs.h. */
13412 $gdb_ptrace_headers
13414 main ()
13416 extern int ptrace ();
13419 return 0;
13421 _ACEOF
13422 if ac_fn_c_try_compile "$LINENO"; then :
13423 gdb_cv_func_ptrace_ret='int'
13424 else
13425 gdb_cv_func_ptrace_ret='long'
13428 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13431 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_func_ptrace_ret" >&5
13435 $as_echo "$gdb_cv_func_ptrace_ret" >&6; }
13438 cat >>confdefs.h <<_ACEOF
13439 #define PTRACE_TYPE_RET $gdb_cv_func_ptrace_ret
13440 _ACEOF
13443 # Check argument types.
13444 { $as_echo "$as_me:${as_lineno-$LINENO}: checking types of arguments for ptrace" >&5
13445 $as_echo_n "checking types of arguments for ptrace... " >&6; }
13446 if ${gdb_cv_func_ptrace_args+:} false; then :
13447 $as_echo_n "(cached) " >&6
13448 else
13449 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13450 /* end confdefs.h. */
13451 $gdb_ptrace_headers
13453 main ()
13455 extern long ptrace (enum __ptrace_request, ...);
13458 return 0;
13460 _ACEOF
13461 if ac_fn_c_try_compile "$LINENO"; then :
13462 gdb_cv_func_ptrace_args='enum __ptrace_request,int,long,long'
13463 else
13464 for gdb_arg1 in 'int' 'long'; do
13465 for gdb_arg2 in 'pid_t' 'int' 'long'; do
13466 for gdb_arg3 in 'int *' 'caddr_t' 'int' 'long' 'void *'; do
13467 for gdb_arg4 in 'int' 'long' 'void *'; do
13468 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13469 /* end confdefs.h. */
13470 $gdb_ptrace_headers
13472 main ()
13474 extern $gdb_cv_func_ptrace_ret ptrace ($gdb_arg1, $gdb_arg2, $gdb_arg3, $gdb_arg4);
13477 return 0;
13479 _ACEOF
13480 if ac_fn_c_try_compile "$LINENO"; then :
13481 gdb_cv_func_ptrace_args="$gdb_arg1,$gdb_arg2,$gdb_arg3,$gdb_arg4";
13482 break 4;
13485 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13487 for gdb_arg5 in 'int *' 'int' 'long'; do
13488 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13489 /* end confdefs.h. */
13490 $gdb_ptrace_headers
13492 main ()
13494 extern $gdb_cv_func_ptrace_ret ptrace ($gdb_arg1, $gdb_arg2, $gdb_arg3, $gdb_arg4, $gdb_arg5);
13497 return 0;
13499 _ACEOF
13500 if ac_fn_c_try_compile "$LINENO"; then :
13501 gdb_cv_func_ptrace_args="$gdb_arg1,$gdb_arg2,$gdb_arg3,$gdb_arg4,$gdb_arg5";
13502 break 5;
13505 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13506 done
13507 done
13508 done
13509 done
13510 done
13511 # Provide a safe default value.
13512 : ${gdb_cv_func_ptrace_args='int,int,long,long'}
13515 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13518 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_func_ptrace_args" >&5
13519 $as_echo "$gdb_cv_func_ptrace_args" >&6; }
13521 ac_save_IFS=$IFS; IFS=','
13522 set dummy `echo "$gdb_cv_func_ptrace_args" | sed 's/\*/\*/g'`
13523 IFS=$ac_save_IFS
13524 shift
13526 cat >>confdefs.h <<_ACEOF
13527 #define PTRACE_TYPE_ARG1 $1
13528 _ACEOF
13531 cat >>confdefs.h <<_ACEOF
13532 #define PTRACE_TYPE_ARG3 $3
13533 _ACEOF
13536 cat >>confdefs.h <<_ACEOF
13537 #define PTRACE_TYPE_ARG4 $4
13538 _ACEOF
13540 if test -n "$5"; then
13542 cat >>confdefs.h <<_ACEOF
13543 #define PTRACE_TYPE_ARG5 $5
13544 _ACEOF
13549 # Check for UST
13550 ustlibs=""
13551 ustinc=""
13554 # Check whether --with-ust was given.
13555 if test "${with_ust+set}" = set; then :
13556 withval=$with_ust;
13560 # Check whether --with-ust_include was given.
13561 if test "${with_ust_include+set}" = set; then :
13562 withval=$with_ust_include;
13566 # Check whether --with-ust_lib was given.
13567 if test "${with_ust_lib+set}" = set; then :
13568 withval=$with_ust_lib;
13572 case $with_ust in
13574 ustlibs=
13575 ustinc=
13577 "" | yes)
13578 ustlibs=" -lust "
13579 ustinc=""
13582 ustlibs="-L$with_ust/lib -lust"
13583 ustinc="-I$with_ust/include "
13585 esac
13586 if test "x$with_ust_include" != x; then
13587 ustinc="-I$with_ust_include "
13589 if test "x$with_ust_lib" != x; then
13590 ustlibs="-L$with_ust_lib -lust"
13593 if test "x$with_ust" != "xno"; then
13594 saved_CFLAGS="$CFLAGS"
13595 CFLAGS="$CFLAGS $ustinc"
13596 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ust" >&5
13597 $as_echo_n "checking for ust... " >&6; }
13598 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13599 /* end confdefs.h. */
13601 #define CONFIG_UST_GDB_INTEGRATION
13602 #include <ust/ust.h>
13605 main ()
13610 return 0;
13612 _ACEOF
13613 if ac_fn_c_try_compile "$LINENO"; then :
13614 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13615 $as_echo "yes" >&6; };
13617 $as_echo "#define HAVE_UST 1" >>confdefs.h
13619 else
13620 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13621 $as_echo "no" >&6; }
13622 ustlibs= ; ustinc=
13625 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13626 CFLAGS="$saved_CFLAGS"
13629 # Flags needed for UST
13635 { $as_echo "$as_me:${as_lineno-$LINENO}: checking the compiler type" >&5
13636 $as_echo_n "checking the compiler type... " >&6; }
13637 if ${gdb_cv_compiler_type+:} false; then :
13638 $as_echo_n "(cached) " >&6
13639 else
13640 gdb_cv_compiler_type=unknown
13641 if test "$gdb_cv_compiler_type" = unknown; then
13642 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13643 /* end confdefs.h. */
13646 main ()
13649 #if !defined __GNUC__ || defined __clang__
13650 #error not gcc
13651 #endif
13654 return 0;
13656 _ACEOF
13657 if ac_fn_c_try_compile "$LINENO"; then :
13658 gdb_cv_compiler_type=gcc
13660 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13663 if test "$gdb_cv_compiler_type" = unknown; then
13664 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13665 /* end confdefs.h. */
13668 main ()
13671 #ifndef __clang__
13672 #error not clang
13673 #endif
13676 return 0;
13678 _ACEOF
13679 if ac_fn_c_try_compile "$LINENO"; then :
13680 gdb_cv_compiler_type=clang
13682 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13686 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_compiler_type" >&5
13687 $as_echo "$gdb_cv_compiler_type" >&6; }
13689 GDB_COMPILER_TYPE="$gdb_cv_compiler_type"
13692 # Check whether --enable-werror was given.
13693 if test "${enable_werror+set}" = set; then :
13694 enableval=$enable_werror; case "${enableval}" in
13695 yes | y) ERROR_ON_WARNING="yes" ;;
13696 no | n) ERROR_ON_WARNING="no" ;;
13697 *) as_fn_error $? "bad value ${enableval} for --enable-werror" "$LINENO" 5 ;;
13698 esac
13702 # Enable -Werror by default when using gcc. Turn it off for releases.
13703 if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" && $development; then
13704 ERROR_ON_WARNING=yes
13707 WERROR_CFLAGS=""
13708 if test "${ERROR_ON_WARNING}" = yes ; then
13709 WERROR_CFLAGS="-Werror"
13712 # The options we'll try to enable.
13713 build_warnings="-Wall -Wpointer-arith \
13714 -Wno-unused -Wunused-value -Wunused-variable -Wunused-function \
13715 -Wno-switch -Wno-char-subscripts \
13716 -Wempty-body -Wunused-but-set-parameter -Wunused-but-set-variable \
13717 -Wno-sign-compare -Wno-error=maybe-uninitialized \
13718 -Wno-mismatched-tags \
13719 -Wno-error=deprecated-register \
13720 -Wsuggest-override \
13721 -Wimplicit-fallthrough=5 \
13722 -Wduplicated-cond \
13723 -Wshadow=local \
13724 -Wdeprecated-copy \
13725 -Wdeprecated-copy-dtor \
13726 -Wredundant-move \
13727 -Wmissing-declarations \
13728 -Wstrict-null-sentinel \
13729 -Wvla \
13732 # The -Wmissing-prototypes flag will be accepted by GCC, but results
13733 # in a warning being printed about the flag not being valid for C++,
13734 # this is something to do with using ccache, and argument ordering.
13735 if test "$GDB_COMPILER_TYPE" != gcc; then
13736 build_warnings="$build_warnings -Wmissing-prototypes"
13739 case "${host}" in
13740 *-*-mingw32*)
13741 # Enable -Wno-format by default when using gcc on mingw since many
13742 # GCC versions complain about %I64.
13743 build_warnings="$build_warnings -Wno-format" ;;
13744 *-*-solaris*)
13745 # Solaris 11.4 <python2.7/ceval.h> uses #pragma no_inline that GCC
13746 # doesn't understand.
13747 build_warnings="$build_warnings -Wno-unknown-pragmas"
13748 # Solaris 11 <unistd.h> marks vfork deprecated.
13749 build_warnings="$build_warnings -Wno-deprecated-declarations" ;;
13751 # Note that gcc requires -Wformat for -Wformat-nonliteral to work,
13752 # but there's a special case for this below.
13753 build_warnings="$build_warnings -Wformat-nonliteral" ;;
13754 esac
13756 # Check whether --enable-build-warnings was given.
13757 if test "${enable_build_warnings+set}" = set; then :
13758 enableval=$enable_build_warnings; case "${enableval}" in
13759 yes) ;;
13760 no) build_warnings="-w";;
13761 ,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
13762 build_warnings="${build_warnings} ${t}";;
13763 *,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
13764 build_warnings="${t} ${build_warnings}";;
13765 *) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
13766 esac
13767 if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
13768 echo "Setting compiler warning flags = $build_warnings" 6>&1
13771 # Check whether --enable-gdb-build-warnings was given.
13772 if test "${enable_gdb_build_warnings+set}" = set; then :
13773 enableval=$enable_gdb_build_warnings; case "${enableval}" in
13774 yes) ;;
13775 no) build_warnings="-w";;
13776 ,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
13777 build_warnings="${build_warnings} ${t}";;
13778 *,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
13779 build_warnings="${t} ${build_warnings}";;
13780 *) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
13781 esac
13782 if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
13783 echo "Setting GDB specific compiler warning flags = $build_warnings" 6>&1
13787 # The set of warnings supported by a C++ compiler is not the same as
13788 # of the C compiler.
13789 ac_ext=cpp
13790 ac_cpp='$CXXCPP $CPPFLAGS'
13791 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
13792 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
13793 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
13796 WARN_CFLAGS=""
13797 if test "x${build_warnings}" != x -a "x$GCC" = xyes
13798 then
13799 { $as_echo "$as_me:${as_lineno-$LINENO}: checking compiler warning flags" >&5
13800 $as_echo_n "checking compiler warning flags... " >&6; }
13801 # Separate out the -Werror flag as some files just cannot be
13802 # compiled with it enabled.
13803 for w in ${build_warnings}; do
13804 # GCC does not complain about -Wno-unknown-warning. Invert
13805 # and test -Wunknown-warning instead.
13806 case $w in
13807 -Wno-*)
13808 wtest=`echo $w | sed 's/-Wno-/-W/g'` ;;
13809 -Wformat-nonliteral)
13810 # gcc requires -Wformat before -Wformat-nonliteral
13811 # will work, so stick them together.
13812 w="-Wformat $w"
13813 wtest="$w"
13816 wtest=$w ;;
13817 esac
13819 case $w in
13820 -Werr*) WERROR_CFLAGS=-Werror ;;
13822 # Check whether GCC accepts it.
13823 saved_CFLAGS="$CFLAGS"
13824 CFLAGS="$CFLAGS -Werror $wtest"
13825 saved_CXXFLAGS="$CXXFLAGS"
13826 CXXFLAGS="$CXXFLAGS -Werror $wtest"
13827 if test "x$w" = "x-Wunused-variable"; then
13828 # Check for https://gcc.gnu.org/bugzilla/show_bug.cgi?id=38958,
13829 # fixed in GCC 4.9. This test is derived from the gdb
13830 # source code that triggered this bug in GCC.
13831 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13832 /* end confdefs.h. */
13833 struct scoped_restore_base {};
13834 struct scoped_restore_tmpl : public scoped_restore_base {
13835 ~scoped_restore_tmpl() {}
13838 main ()
13840 const scoped_restore_base &b = scoped_restore_tmpl();
13843 return 0;
13845 _ACEOF
13846 if ac_fn_cxx_try_compile "$LINENO"; then :
13847 WARN_CFLAGS="${WARN_CFLAGS} $w"
13849 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13850 else
13851 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13852 /* end confdefs.h. */
13855 main ()
13859 return 0;
13861 _ACEOF
13862 if ac_fn_cxx_try_compile "$LINENO"; then :
13863 WARN_CFLAGS="${WARN_CFLAGS} $w"
13865 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13867 CFLAGS="$saved_CFLAGS"
13868 CXXFLAGS="$saved_CXXFLAGS"
13869 esac
13870 done
13871 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${WARN_CFLAGS} ${WERROR_CFLAGS}" >&5
13872 $as_echo "${WARN_CFLAGS} ${WERROR_CFLAGS}" >&6; }
13877 ac_ext=c
13878 ac_cpp='$CPP $CPPFLAGS'
13879 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
13880 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
13881 ac_compiler_gnu=$ac_cv_c_compiler_gnu
13885 old_LIBS="$LIBS"
13886 LIBS="$LIBS -ldl"
13887 for ac_func in dladdr
13888 do :
13889 ac_fn_c_check_func "$LINENO" "dladdr" "ac_cv_func_dladdr"
13890 if test "x$ac_cv_func_dladdr" = xyes; then :
13891 cat >>confdefs.h <<_ACEOF
13892 #define HAVE_DLADDR 1
13893 _ACEOF
13896 done
13898 LIBS="$old_LIBS"
13900 ac_fn_c_check_decl "$LINENO" "ffs" "ac_cv_have_decl_ffs" "$ac_includes_default"
13901 if test "x$ac_cv_have_decl_ffs" = xyes; then :
13902 ac_have_decl=1
13903 else
13904 ac_have_decl=0
13907 cat >>confdefs.h <<_ACEOF
13908 #define HAVE_DECL_FFS $ac_have_decl
13909 _ACEOF
13911 ac_fn_c_check_decl "$LINENO" "asprintf" "ac_cv_have_decl_asprintf" "$ac_includes_default"
13912 if test "x$ac_cv_have_decl_asprintf" = xyes; then :
13913 ac_have_decl=1
13914 else
13915 ac_have_decl=0
13918 cat >>confdefs.h <<_ACEOF
13919 #define HAVE_DECL_ASPRINTF $ac_have_decl
13920 _ACEOF
13922 ac_fn_c_check_decl "$LINENO" "vasprintf" "ac_cv_have_decl_vasprintf" "$ac_includes_default"
13923 if test "x$ac_cv_have_decl_vasprintf" = xyes; then :
13924 ac_have_decl=1
13925 else
13926 ac_have_decl=0
13929 cat >>confdefs.h <<_ACEOF
13930 #define HAVE_DECL_VASPRINTF $ac_have_decl
13931 _ACEOF
13933 ac_fn_c_check_decl "$LINENO" "snprintf" "ac_cv_have_decl_snprintf" "$ac_includes_default"
13934 if test "x$ac_cv_have_decl_snprintf" = xyes; then :
13935 ac_have_decl=1
13936 else
13937 ac_have_decl=0
13940 cat >>confdefs.h <<_ACEOF
13941 #define HAVE_DECL_SNPRINTF $ac_have_decl
13942 _ACEOF
13944 ac_fn_c_check_decl "$LINENO" "vsnprintf" "ac_cv_have_decl_vsnprintf" "$ac_includes_default"
13945 if test "x$ac_cv_have_decl_vsnprintf" = xyes; then :
13946 ac_have_decl=1
13947 else
13948 ac_have_decl=0
13951 cat >>confdefs.h <<_ACEOF
13952 #define HAVE_DECL_VSNPRINTF $ac_have_decl
13953 _ACEOF
13955 ac_fn_c_check_decl "$LINENO" "strtol" "ac_cv_have_decl_strtol" "$ac_includes_default"
13956 if test "x$ac_cv_have_decl_strtol" = xyes; then :
13957 ac_have_decl=1
13958 else
13959 ac_have_decl=0
13962 cat >>confdefs.h <<_ACEOF
13963 #define HAVE_DECL_STRTOL $ac_have_decl
13964 _ACEOF
13966 ac_fn_c_check_decl "$LINENO" "strtoul" "ac_cv_have_decl_strtoul" "$ac_includes_default"
13967 if test "x$ac_cv_have_decl_strtoul" = xyes; then :
13968 ac_have_decl=1
13969 else
13970 ac_have_decl=0
13973 cat >>confdefs.h <<_ACEOF
13974 #define HAVE_DECL_STRTOUL $ac_have_decl
13975 _ACEOF
13977 ac_fn_c_check_decl "$LINENO" "strtoll" "ac_cv_have_decl_strtoll" "$ac_includes_default"
13978 if test "x$ac_cv_have_decl_strtoll" = xyes; then :
13979 ac_have_decl=1
13980 else
13981 ac_have_decl=0
13984 cat >>confdefs.h <<_ACEOF
13985 #define HAVE_DECL_STRTOLL $ac_have_decl
13986 _ACEOF
13988 ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default"
13989 if test "x$ac_cv_have_decl_strtoull" = xyes; then :
13990 ac_have_decl=1
13991 else
13992 ac_have_decl=0
13995 cat >>confdefs.h <<_ACEOF
13996 #define HAVE_DECL_STRTOULL $ac_have_decl
13997 _ACEOF
13999 ac_fn_c_check_decl "$LINENO" "strverscmp" "ac_cv_have_decl_strverscmp" "$ac_includes_default"
14000 if test "x$ac_cv_have_decl_strverscmp" = xyes; then :
14001 ac_have_decl=1
14002 else
14003 ac_have_decl=0
14006 cat >>confdefs.h <<_ACEOF
14007 #define HAVE_DECL_STRVERSCMP $ac_have_decl
14008 _ACEOF
14010 ac_fn_c_check_type "$LINENO" "long long" "ac_cv_type_long_long" "$ac_includes_default"
14011 if test "x$ac_cv_type_long_long" = xyes; then :
14013 cat >>confdefs.h <<_ACEOF
14014 #define HAVE_LONG_LONG 1
14015 _ACEOF
14017 # The cast to long int works around a bug in the HP C Compiler
14018 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
14019 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
14020 # This bug is HP SR number 8606223364.
14021 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5
14022 $as_echo_n "checking size of long long... " >&6; }
14023 if ${ac_cv_sizeof_long_long+:} false; then :
14024 $as_echo_n "(cached) " >&6
14025 else
14026 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long" "$ac_includes_default"; then :
14028 else
14029 if test "$ac_cv_type_long_long" = yes; then
14030 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
14031 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
14032 as_fn_error 77 "cannot compute sizeof (long long)
14033 See \`config.log' for more details" "$LINENO" 5; }
14034 else
14035 ac_cv_sizeof_long_long=0
14040 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5
14041 $as_echo "$ac_cv_sizeof_long_long" >&6; }
14045 cat >>confdefs.h <<_ACEOF
14046 #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
14047 _ACEOF
14053 as_ac_Symbol=`$as_echo "ac_cv_have_decl_basename(char *)" | $as_tr_sh`
14054 ac_fn_c_check_decl "$LINENO" "basename(char *)" "$as_ac_Symbol" "$ac_includes_default"
14055 if eval test \"x\$"$as_ac_Symbol"\" = x"yes"; then :
14056 ac_have_decl=1
14057 else
14058 ac_have_decl=0
14061 cat >>confdefs.h <<_ACEOF
14062 #define HAVE_DECL_BASENAME $ac_have_decl
14063 _ACEOF
14070 ac_fn_c_check_decl "$LINENO" "perror" "ac_cv_have_decl_perror" "$ac_includes_default"
14071 if test "x$ac_cv_have_decl_perror" = xyes; then :
14072 ac_have_decl=1
14073 else
14074 ac_have_decl=0
14077 cat >>confdefs.h <<_ACEOF
14078 #define HAVE_DECL_PERROR $ac_have_decl
14079 _ACEOF
14080 ac_fn_c_check_decl "$LINENO" "vasprintf" "ac_cv_have_decl_vasprintf" "$ac_includes_default"
14081 if test "x$ac_cv_have_decl_vasprintf" = xyes; then :
14082 ac_have_decl=1
14083 else
14084 ac_have_decl=0
14087 cat >>confdefs.h <<_ACEOF
14088 #define HAVE_DECL_VASPRINTF $ac_have_decl
14089 _ACEOF
14090 ac_fn_c_check_decl "$LINENO" "vsnprintf" "ac_cv_have_decl_vsnprintf" "$ac_includes_default"
14091 if test "x$ac_cv_have_decl_vsnprintf" = xyes; then :
14092 ac_have_decl=1
14093 else
14094 ac_have_decl=0
14097 cat >>confdefs.h <<_ACEOF
14098 #define HAVE_DECL_VSNPRINTF $ac_have_decl
14099 _ACEOF
14102 ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "#include <sys/types.h>
14103 #if HAVE_SYS_SOCKET_H
14104 # include <sys/socket.h>
14105 #elif HAVE_WS2TCPIP_H
14106 # include <ws2tcpip.h>
14107 #endif
14110 if test "x$ac_cv_type_socklen_t" = xyes; then :
14112 cat >>confdefs.h <<_ACEOF
14113 #define HAVE_SOCKLEN_T 1
14114 _ACEOF
14120 case "${target}" in
14121 *-android*)
14122 # Starting with NDK version 9, <elf.h> actually includes definitions
14123 # of Elf32_auxv_t and Elf64_auxv_t. But sadly, <elf.h> includes
14124 # <sys/exec_elf.h> which defines some of the ELF types incorrectly,
14125 # leading to conflicts with the defintions from <linux/elf.h>.
14126 # This makes it impossible for us to include both <elf.h> and
14127 # <linux/elf.h>, which means that, in practice, we do not have
14128 # access to Elf32_auxv_t and Elf64_auxv_t on this platform.
14129 # Therefore, do not try to auto-detect availability, as it would
14130 # get it wrong on this platform.
14133 ac_fn_c_check_type "$LINENO" "Elf32_auxv_t" "ac_cv_type_Elf32_auxv_t" "#include <elf.h>
14136 if test "x$ac_cv_type_Elf32_auxv_t" = xyes; then :
14138 cat >>confdefs.h <<_ACEOF
14139 #define HAVE_ELF32_AUXV_T 1
14140 _ACEOF
14144 ac_fn_c_check_type "$LINENO" "Elf64_auxv_t" "ac_cv_type_Elf64_auxv_t" "#include <elf.h>
14147 if test "x$ac_cv_type_Elf64_auxv_t" = xyes; then :
14149 cat >>confdefs.h <<_ACEOF
14150 #define HAVE_ELF64_AUXV_T 1
14151 _ACEOF
14156 esac
14160 # Check whether --with-pkgversion was given.
14161 if test "${with_pkgversion+set}" = set; then :
14162 withval=$with_pkgversion; case "$withval" in
14163 yes) as_fn_error $? "package version not specified" "$LINENO" 5 ;;
14164 no) PKGVERSION= ;;
14165 *) PKGVERSION="($withval) " ;;
14166 esac
14167 else
14168 PKGVERSION="(GDB) "
14176 # Check whether --with-bugurl was given.
14177 if test "${with_bugurl+set}" = set; then :
14178 withval=$with_bugurl; case "$withval" in
14179 yes) as_fn_error $? "bug URL not specified" "$LINENO" 5 ;;
14180 no) BUGURL=
14182 *) BUGURL="$withval"
14184 esac
14185 else
14186 BUGURL="http://www.gnu.org/software/gdb/bugs/"
14190 case ${BUGURL} in
14192 REPORT_BUGS_TO=
14193 REPORT_BUGS_TEXI=
14196 REPORT_BUGS_TO="<$BUGURL>"
14197 REPORT_BUGS_TEXI=@uref{`echo "$BUGURL" | sed 's/@/@@/g'`}
14199 esac;
14204 cat >>confdefs.h <<_ACEOF
14205 #define PKGVERSION "$PKGVERSION"
14206 _ACEOF
14209 cat >>confdefs.h <<_ACEOF
14210 #define REPORT_BUGS_TO "$REPORT_BUGS_TO"
14211 _ACEOF
14214 # Check for various supplementary target information (beyond the
14215 # triplet) which might affect the choices in configure.srv.
14216 case "${target}" in
14217 i[34567]86-*-linux*)
14218 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if building for x86-64" >&5
14219 $as_echo_n "checking if building for x86-64... " >&6; }
14220 if ${gdb_cv_i386_is_x86_64+:} false; then :
14221 $as_echo_n "(cached) " >&6
14222 else
14223 save_CPPFLAGS="$CPPFLAGS"
14224 CPPFLAGS="$CPPFLAGS $CFLAGS"
14225 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14226 /* end confdefs.h. */
14228 #if __x86_64__
14229 got it
14230 #endif
14232 _ACEOF
14233 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14234 $EGREP "got it" >/dev/null 2>&1; then :
14235 gdb_cv_i386_is_x86_64=yes
14236 else
14237 gdb_cv_i386_is_x86_64=no
14239 rm -f conftest*
14241 CPPFLAGS="$save_CPPFLAGS"
14243 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_i386_is_x86_64" >&5
14244 $as_echo "$gdb_cv_i386_is_x86_64" >&6; }
14247 x86_64-*-linux*)
14248 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if building for x32" >&5
14249 $as_echo_n "checking if building for x32... " >&6; }
14250 if ${gdb_cv_x86_is_x32+:} false; then :
14251 $as_echo_n "(cached) " >&6
14252 else
14253 save_CPPFLAGS="$CPPFLAGS"
14254 CPPFLAGS="$CPPFLAGS $CFLAGS"
14255 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14256 /* end confdefs.h. */
14258 #if __x86_64__ && __ILP32__
14259 got it
14260 #endif
14262 _ACEOF
14263 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14264 $EGREP "got it" >/dev/null 2>&1; then :
14265 gdb_cv_x86_is_x32=yes
14266 else
14267 gdb_cv_x86_is_x32=no
14269 rm -f conftest*
14271 CPPFLAGS="$save_CPPFLAGS"
14273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_x86_is_x32" >&5
14274 $as_echo "$gdb_cv_x86_is_x32" >&6; }
14277 m68k-*-*)
14278 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if building for Coldfire" >&5
14279 $as_echo_n "checking if building for Coldfire... " >&6; }
14280 if ${gdb_cv_m68k_is_coldfire+:} false; then :
14281 $as_echo_n "(cached) " >&6
14282 else
14283 save_CPPFLAGS="$CPPFLAGS"
14284 CPPFLAGS="$CPPFLAGS $CFLAGS"
14285 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14286 /* end confdefs.h. */
14288 #ifdef __mcoldfire__
14289 got it
14290 #endif
14292 _ACEOF
14293 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14294 $EGREP "got it" >/dev/null 2>&1; then :
14295 gdb_cv_m68k_is_coldfire=yes
14296 else
14297 gdb_cv_m68k_is_coldfire=no
14299 rm -f conftest*
14301 CPPFLAGS="$save_CPPFLAGS"
14303 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_m68k_is_coldfire" >&5
14304 $as_echo "$gdb_cv_m68k_is_coldfire" >&6; }
14306 esac
14308 . ${srcdir}/configure.srv
14310 if test "${srv_mingwce}" = "yes"; then
14311 LIBS="$LIBS -lws2"
14312 elif test "${srv_mingw}" = "yes"; then
14313 # WIN32APILIBS is set by GDB_AC_COMMON.
14314 LIBS="$LIBS $WIN32APILIBS"
14317 if test "${srv_linux_usrregs}" = "yes"; then
14319 $as_echo "#define HAVE_LINUX_USRREGS 1" >>confdefs.h
14323 if test "${srv_linux_regsets}" = "yes"; then
14325 $as_echo "#define HAVE_LINUX_REGSETS 1" >>confdefs.h
14328 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTRACE_GETREGS" >&5
14329 $as_echo_n "checking for PTRACE_GETREGS... " >&6; }
14330 if ${gdbsrv_cv_have_ptrace_getregs+:} false; then :
14331 $as_echo_n "(cached) " >&6
14332 else
14333 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14334 /* end confdefs.h. */
14335 #include <sys/ptrace.h>
14337 main ()
14339 PTRACE_GETREGS;
14341 return 0;
14343 _ACEOF
14344 if ac_fn_c_try_compile "$LINENO"; then :
14345 gdbsrv_cv_have_ptrace_getregs=yes
14346 else
14347 gdbsrv_cv_have_ptrace_getregs=no
14350 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14354 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdbsrv_cv_have_ptrace_getregs" >&5
14355 $as_echo "$gdbsrv_cv_have_ptrace_getregs" >&6; }
14356 if test "${gdbsrv_cv_have_ptrace_getregs}" = "yes"; then
14358 $as_echo "#define HAVE_PTRACE_GETREGS 1" >>confdefs.h
14362 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTRACE_GETFPXREGS" >&5
14363 $as_echo_n "checking for PTRACE_GETFPXREGS... " >&6; }
14364 if ${gdbsrv_cv_have_ptrace_getfpxregs+:} false; then :
14365 $as_echo_n "(cached) " >&6
14366 else
14367 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14368 /* end confdefs.h. */
14369 #include <sys/ptrace.h>
14371 main ()
14373 PTRACE_GETFPXREGS;
14375 return 0;
14377 _ACEOF
14378 if ac_fn_c_try_compile "$LINENO"; then :
14379 gdbsrv_cv_have_ptrace_getfpxregs=yes
14380 else
14381 gdbsrv_cv_have_ptrace_getfpxregs=no
14384 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14388 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdbsrv_cv_have_ptrace_getfpxregs" >&5
14389 $as_echo "$gdbsrv_cv_have_ptrace_getfpxregs" >&6; }
14390 if test "${gdbsrv_cv_have_ptrace_getfpxregs}" = "yes"; then
14392 $as_echo "#define HAVE_PTRACE_GETFPXREGS 1" >>confdefs.h
14397 if test "${srv_linux_btrace}" = "yes"; then
14399 $as_echo "#define HAVE_LINUX_BTRACE 1" >>confdefs.h
14403 if test "$bfd_cv_have_sys_procfs_type_lwpid_t" != yes; then
14404 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lwpid_t in thread_db.h" >&5
14405 $as_echo_n "checking for lwpid_t in thread_db.h... " >&6; }
14406 if ${gdbserver_cv_have_thread_db_type_lwpid_t+:} false; then :
14407 $as_echo_n "(cached) " >&6
14408 else
14409 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14410 /* end confdefs.h. */
14411 #include <thread_db.h>
14413 main ()
14415 lwpid_t avar
14417 return 0;
14419 _ACEOF
14420 if ac_fn_c_try_compile "$LINENO"; then :
14421 gdbserver_cv_have_thread_db_type_lwpid_t=yes
14422 else
14423 gdbserver_cv_have_thread_db_type_lwpid_t=no
14426 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14430 if test $gdbserver_cv_have_thread_db_type_lwpid_t = yes; then
14432 $as_echo "#define HAVE_LWPID_T 1" >>confdefs.h
14435 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdbserver_cv_have_thread_db_type_lwpid_t" >&5
14436 $as_echo "$gdbserver_cv_have_thread_db_type_lwpid_t" >&6; }
14440 if test "$bfd_cv_have_sys_procfs_type_psaddr_t" != yes; then
14441 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for psaddr_t in thread_db.h" >&5
14442 $as_echo_n "checking for psaddr_t in thread_db.h... " >&6; }
14443 if ${gdbserver_cv_have_thread_db_type_psaddr_t+:} false; then :
14444 $as_echo_n "(cached) " >&6
14445 else
14446 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14447 /* end confdefs.h. */
14448 #include <thread_db.h>
14450 main ()
14452 psaddr_t avar
14454 return 0;
14456 _ACEOF
14457 if ac_fn_c_try_compile "$LINENO"; then :
14458 gdbserver_cv_have_thread_db_type_psaddr_t=yes
14459 else
14460 gdbserver_cv_have_thread_db_type_psaddr_t=no
14463 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14467 if test $gdbserver_cv_have_thread_db_type_psaddr_t = yes; then
14469 $as_echo "#define HAVE_PSADDR_T 1" >>confdefs.h
14472 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdbserver_cv_have_thread_db_type_psaddr_t" >&5
14473 $as_echo "$gdbserver_cv_have_thread_db_type_psaddr_t" >&6; }
14477 old_LIBS="$LIBS"
14478 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
14479 $as_echo_n "checking for dlopen in -ldl... " >&6; }
14480 if ${ac_cv_lib_dl_dlopen+:} false; then :
14481 $as_echo_n "(cached) " >&6
14482 else
14483 ac_check_lib_save_LIBS=$LIBS
14484 LIBS="-ldl $LIBS"
14485 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14486 /* end confdefs.h. */
14488 /* Override any GCC internal prototype to avoid an error.
14489 Use char because int might match the return type of a GCC
14490 builtin and then its argument prototype would still apply. */
14491 #ifdef __cplusplus
14492 extern "C"
14493 #endif
14494 char dlopen ();
14496 main ()
14498 return dlopen ();
14500 return 0;
14502 _ACEOF
14503 if ac_fn_c_try_link "$LINENO"; then :
14504 ac_cv_lib_dl_dlopen=yes
14505 else
14506 ac_cv_lib_dl_dlopen=no
14508 rm -f core conftest.err conftest.$ac_objext \
14509 conftest$ac_exeext conftest.$ac_ext
14510 LIBS=$ac_check_lib_save_LIBS
14512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
14513 $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
14514 if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
14515 cat >>confdefs.h <<_ACEOF
14516 #define HAVE_LIBDL 1
14517 _ACEOF
14519 LIBS="-ldl $LIBS"
14523 LIBS="$old_LIBS"
14525 srv_thread_depfiles=
14526 srv_libs=
14528 if test "$srv_linux_thread_db" = "yes"; then
14529 if test "$ac_cv_lib_dl_dlopen" = "yes"; then
14530 srv_libs="-ldl"
14531 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the dynamic export flag" >&5
14532 $as_echo_n "checking for the dynamic export flag... " >&6; }
14533 old_LDFLAGS="$LDFLAGS"
14534 # Older GNU ld supports --export-dynamic but --dynamic-list may not be
14535 # supported there.
14536 RDYNAMIC="-Wl,--dynamic-list=${srcdir}/proc-service.list"
14537 LDFLAGS="$LDFLAGS $RDYNAMIC"
14538 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14539 /* end confdefs.h. */
14542 main ()
14546 return 0;
14548 _ACEOF
14549 if ac_fn_c_try_link "$LINENO"; then :
14550 found="-Wl,--dynamic-list"
14551 RDYNAMIC='-Wl,--dynamic-list=$(srcdir)/proc-service.list'
14552 else
14553 RDYNAMIC="-rdynamic"
14554 LDFLAGS="$old_LDFLAGS $RDYNAMIC"
14555 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14556 /* end confdefs.h. */
14559 main ()
14563 return 0;
14565 _ACEOF
14566 if ac_fn_c_try_link "$LINENO"; then :
14567 found="-rdynamic"
14568 else
14569 found="no"
14570 RDYNAMIC=""
14573 rm -f core conftest.err conftest.$ac_objext \
14574 conftest$ac_exeext conftest.$ac_ext
14577 rm -f core conftest.err conftest.$ac_objext \
14578 conftest$ac_exeext conftest.$ac_ext
14580 LDFLAGS="$old_LDFLAGS"
14581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $found" >&5
14582 $as_echo "$found" >&6; }
14583 else
14584 srv_libs="-lthread_db"
14587 srv_thread_depfiles="thread-db.o proc-service.o"
14589 $as_echo "#define USE_THREAD_DB 1" >>confdefs.h
14591 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TD_VERSION" >&5
14592 $as_echo_n "checking for TD_VERSION... " >&6; }
14593 if ${gdbsrv_cv_have_td_version+:} false; then :
14594 $as_echo_n "(cached) " >&6
14595 else
14596 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14597 /* end confdefs.h. */
14598 #include <thread_db.h>
14600 main ()
14602 TD_VERSION;
14604 return 0;
14606 _ACEOF
14607 if ac_fn_c_try_compile "$LINENO"; then :
14608 gdbsrv_cv_have_td_version=yes
14609 else
14610 gdbsrv_cv_have_td_version=no
14613 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14616 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdbsrv_cv_have_td_version" >&5
14617 $as_echo "$gdbsrv_cv_have_td_version" >&6; }
14618 if test "$gdbsrv_cv_have_td_version" = yes; then
14620 $as_echo "#define HAVE_TD_VERSION 1" >>confdefs.h
14626 # Check whether --with-libthread-db was given.
14627 if test "${with_libthread_db+set}" = set; then :
14628 withval=$with_libthread_db; srv_libthread_db_path="${withval}"
14629 srv_libs="$srv_libthread_db_path"
14634 if test "$srv_libs" != "" -a "$srv_libs" != "-ldl"; then
14636 $as_echo "#define USE_LIBTHREAD_DB_DIRECTLY 1" >>confdefs.h
14640 if test "$srv_xmlfiles" != ""; then
14641 srv_xmlbuiltin="xml-builtin.o"
14643 $as_echo "#define USE_XML 1" >>confdefs.h
14646 tmp_xmlfiles=$srv_xmlfiles
14647 srv_xmlfiles=""
14648 for f in $tmp_xmlfiles; do
14649 srv_xmlfiles="$srv_xmlfiles \$(XML_DIR)/$f"
14650 done
14653 GDBSERVER_DEPFILES="$srv_regobj $srv_tgtobj $srv_thread_depfiles"
14654 GDBSERVER_LIBS="$srv_libs"
14656 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the target supports __sync_*_compare_and_swap" >&5
14657 $as_echo_n "checking whether the target supports __sync_*_compare_and_swap... " >&6; }
14658 if ${gdbsrv_cv_have_sync_builtins+:} false; then :
14659 $as_echo_n "(cached) " >&6
14660 else
14661 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14662 /* end confdefs.h. */
14665 main ()
14667 int foo, bar;
14668 bar = __sync_val_compare_and_swap(&foo, 0, 1);
14671 return 0;
14673 _ACEOF
14674 if ac_fn_c_try_link "$LINENO"; then :
14675 gdbsrv_cv_have_sync_builtins=yes
14676 else
14677 gdbsrv_cv_have_sync_builtins=no
14680 rm -f core conftest.err conftest.$ac_objext \
14681 conftest$ac_exeext conftest.$ac_ext
14684 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdbsrv_cv_have_sync_builtins" >&5
14685 $as_echo "$gdbsrv_cv_have_sync_builtins" >&6; }
14686 if test "$gdbsrv_cv_have_sync_builtins" = yes; then
14688 $as_echo "#define HAVE_SYNC_BUILTINS 1" >>confdefs.h
14692 saved_cflags="$CFLAGS"
14693 CFLAGS="$CFLAGS -fvisibility=hidden"
14694 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14695 /* end confdefs.h. */
14698 main ()
14702 return 0;
14704 _ACEOF
14705 if ac_fn_c_try_compile "$LINENO"; then :
14706 gdbsrv_cv_have_visibility_hidden=yes
14707 else
14708 gdbsrv_cv_have_visibility_hidden=no
14710 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14711 CFLAGS="$saved_cflags"
14713 IPA_DEPFILES=""
14714 extra_libraries=""
14716 # check whether to enable the inprocess agent
14717 if test "$ipa_obj" != "" \
14718 -a "$gdbsrv_cv_have_sync_builtins" = yes \
14719 -a "$gdbsrv_cv_have_visibility_hidden" = yes; then
14720 have_ipa=true
14721 else
14722 have_ipa=false
14725 # Check whether --enable-inprocess-agent was given.
14726 if test "${enable_inprocess_agent+set}" = set; then :
14727 enableval=$enable_inprocess_agent; case "$enableval" in
14728 yes) want_ipa=true ;;
14729 no) want_ipa=false ;;
14730 *) as_fn_error $? "bad value $enableval for inprocess-agent" "$LINENO" 5 ;;
14731 esac
14732 else
14733 want_ipa=$have_ipa
14737 if $want_ipa ; then
14738 if $have_ipa ; then
14739 IPA_DEPFILES="$ipa_obj"
14740 extra_libraries="$extra_libraries libinproctrace.so"
14741 else
14742 as_fn_error $? "inprocess agent not supported for this target" "$LINENO" 5
14753 GNULIB=../gnulib/import
14755 GNULIB_STDINT_H=
14756 if test x"$STDINT_H" != x; then
14757 GNULIB_STDINT_H=$GNULIB/$STDINT_H
14761 # Check for libiconv. It is a requirement for Linux hosts, and others hosts
14762 # don't use it at all. Define MAYBE_LIBICONV only if the host is Linux.
14768 am_save_CPPFLAGS="$CPPFLAGS"
14770 for element in $INCICONV; do
14771 haveit=
14772 for x in $CPPFLAGS; do
14774 acl_save_prefix="$prefix"
14775 prefix="$acl_final_prefix"
14776 acl_save_exec_prefix="$exec_prefix"
14777 exec_prefix="$acl_final_exec_prefix"
14778 eval x=\"$x\"
14779 exec_prefix="$acl_save_exec_prefix"
14780 prefix="$acl_save_prefix"
14782 if test "X$x" = "X$element"; then
14783 haveit=yes
14784 break
14786 done
14787 if test -z "$haveit"; then
14788 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
14790 done
14793 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5
14794 $as_echo_n "checking for iconv... " >&6; }
14795 if ${am_cv_func_iconv+:} false; then :
14796 $as_echo_n "(cached) " >&6
14797 else
14799 am_cv_func_iconv="no, consider installing GNU libiconv"
14800 am_cv_lib_iconv=no
14801 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14802 /* end confdefs.h. */
14804 #include <stdlib.h>
14805 #include <iconv.h>
14808 main ()
14810 iconv_t cd = iconv_open("","");
14811 iconv(cd,NULL,NULL,NULL,NULL);
14812 iconv_close(cd);
14814 return 0;
14816 _ACEOF
14817 if ac_fn_c_try_link "$LINENO"; then :
14818 am_cv_func_iconv=yes
14820 rm -f core conftest.err conftest.$ac_objext \
14821 conftest$ac_exeext conftest.$ac_ext
14822 if test "$am_cv_func_iconv" != yes; then
14823 am_save_LIBS="$LIBS"
14824 LIBS="$LIBS $LIBICONV"
14825 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14826 /* end confdefs.h. */
14828 #include <stdlib.h>
14829 #include <iconv.h>
14832 main ()
14834 iconv_t cd = iconv_open("","");
14835 iconv(cd,NULL,NULL,NULL,NULL);
14836 iconv_close(cd);
14838 return 0;
14840 _ACEOF
14841 if ac_fn_c_try_link "$LINENO"; then :
14842 am_cv_lib_iconv=yes
14843 am_cv_func_iconv=yes
14845 rm -f core conftest.err conftest.$ac_objext \
14846 conftest$ac_exeext conftest.$ac_ext
14847 LIBS="$am_save_LIBS"
14851 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5
14852 $as_echo "$am_cv_func_iconv" >&6; }
14853 if test "$am_cv_func_iconv" = yes; then
14854 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working iconv" >&5
14855 $as_echo_n "checking for working iconv... " >&6; }
14856 if ${am_cv_func_iconv_works+:} false; then :
14857 $as_echo_n "(cached) " >&6
14858 else
14860 am_save_LIBS="$LIBS"
14861 if test $am_cv_lib_iconv = yes; then
14862 LIBS="$LIBS $LIBICONV"
14864 am_cv_func_iconv_works=no
14865 for ac_iconv_const in '' 'const'; do
14866 if test "$cross_compiling" = yes; then :
14867 case "$host_os" in
14868 aix* | hpux*) am_cv_func_iconv_works="guessing no" ;;
14869 *) am_cv_func_iconv_works="guessing yes" ;;
14870 esac
14871 else
14872 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14873 /* end confdefs.h. */
14875 #include <iconv.h>
14876 #include <string.h>
14878 #ifndef ICONV_CONST
14879 # define ICONV_CONST $ac_iconv_const
14880 #endif
14883 main ()
14885 int result = 0;
14886 /* Test against AIX 5.1...7.2 bug: Failures are not distinguishable from
14887 successful returns. This is even documented in
14888 <https://www.ibm.com/support/knowledgecenter/ssw_aix_72/i_bostechref/iconv.html> */
14890 iconv_t cd_utf8_to_88591 = iconv_open ("ISO8859-1", "UTF-8");
14891 if (cd_utf8_to_88591 != (iconv_t)(-1))
14893 static ICONV_CONST char input[] = "\342\202\254"; /* EURO SIGN */
14894 char buf[10];
14895 ICONV_CONST char *inptr = input;
14896 size_t inbytesleft = strlen (input);
14897 char *outptr = buf;
14898 size_t outbytesleft = sizeof (buf);
14899 size_t res = iconv (cd_utf8_to_88591,
14900 &inptr, &inbytesleft,
14901 &outptr, &outbytesleft);
14902 if (res == 0)
14903 result |= 1;
14904 iconv_close (cd_utf8_to_88591);
14907 /* Test against Solaris 10 bug: Failures are not distinguishable from
14908 successful returns. */
14910 iconv_t cd_ascii_to_88591 = iconv_open ("ISO8859-1", "646");
14911 if (cd_ascii_to_88591 != (iconv_t)(-1))
14913 static ICONV_CONST char input[] = "\263";
14914 char buf[10];
14915 ICONV_CONST char *inptr = input;
14916 size_t inbytesleft = strlen (input);
14917 char *outptr = buf;
14918 size_t outbytesleft = sizeof (buf);
14919 size_t res = iconv (cd_ascii_to_88591,
14920 &inptr, &inbytesleft,
14921 &outptr, &outbytesleft);
14922 if (res == 0)
14923 result |= 2;
14924 iconv_close (cd_ascii_to_88591);
14927 /* Test against AIX 6.1..7.1 bug: Buffer overrun. */
14929 iconv_t cd_88591_to_utf8 = iconv_open ("UTF-8", "ISO-8859-1");
14930 if (cd_88591_to_utf8 != (iconv_t)(-1))
14932 static ICONV_CONST char input[] = "\304";
14933 static char buf[2] = { (char)0xDE, (char)0xAD };
14934 ICONV_CONST char *inptr = input;
14935 size_t inbytesleft = 1;
14936 char *outptr = buf;
14937 size_t outbytesleft = 1;
14938 size_t res = iconv (cd_88591_to_utf8,
14939 &inptr, &inbytesleft,
14940 &outptr, &outbytesleft);
14941 if (res != (size_t)(-1) || outptr - buf > 1 || buf[1] != (char)0xAD)
14942 result |= 4;
14943 iconv_close (cd_88591_to_utf8);
14946 #if 0 /* This bug could be worked around by the caller. */
14947 /* Test against HP-UX 11.11 bug: Positive return value instead of 0. */
14949 iconv_t cd_88591_to_utf8 = iconv_open ("utf8", "iso88591");
14950 if (cd_88591_to_utf8 != (iconv_t)(-1))
14952 static ICONV_CONST char input[] = "\304rger mit b\366sen B\374bchen ohne Augenma\337";
14953 char buf[50];
14954 ICONV_CONST char *inptr = input;
14955 size_t inbytesleft = strlen (input);
14956 char *outptr = buf;
14957 size_t outbytesleft = sizeof (buf);
14958 size_t res = iconv (cd_88591_to_utf8,
14959 &inptr, &inbytesleft,
14960 &outptr, &outbytesleft);
14961 if ((int)res > 0)
14962 result |= 8;
14963 iconv_close (cd_88591_to_utf8);
14966 #endif
14967 /* Test against HP-UX 11.11 bug: No converter from EUC-JP to UTF-8 is
14968 provided. */
14970 /* Try standardized names. */
14971 iconv_t cd1 = iconv_open ("UTF-8", "EUC-JP");
14972 /* Try IRIX, OSF/1 names. */
14973 iconv_t cd2 = iconv_open ("UTF-8", "eucJP");
14974 /* Try AIX names. */
14975 iconv_t cd3 = iconv_open ("UTF-8", "IBM-eucJP");
14976 /* Try HP-UX names. */
14977 iconv_t cd4 = iconv_open ("utf8", "eucJP");
14978 if (cd1 == (iconv_t)(-1) && cd2 == (iconv_t)(-1)
14979 && cd3 == (iconv_t)(-1) && cd4 == (iconv_t)(-1))
14980 result |= 16;
14981 if (cd1 != (iconv_t)(-1))
14982 iconv_close (cd1);
14983 if (cd2 != (iconv_t)(-1))
14984 iconv_close (cd2);
14985 if (cd3 != (iconv_t)(-1))
14986 iconv_close (cd3);
14987 if (cd4 != (iconv_t)(-1))
14988 iconv_close (cd4);
14990 return result;
14993 return 0;
14995 _ACEOF
14996 if ac_fn_c_try_run "$LINENO"; then :
14997 am_cv_func_iconv_works=yes
14999 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15000 conftest.$ac_objext conftest.beam conftest.$ac_ext
15003 test "$am_cv_func_iconv_works" = no || break
15004 done
15005 LIBS="$am_save_LIBS"
15008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv_works" >&5
15009 $as_echo "$am_cv_func_iconv_works" >&6; }
15010 case "$am_cv_func_iconv_works" in
15011 *no) am_func_iconv=no am_cv_lib_iconv=no ;;
15012 *) am_func_iconv=yes ;;
15013 esac
15014 else
15015 am_func_iconv=no am_cv_lib_iconv=no
15017 if test "$am_func_iconv" = yes; then
15019 $as_echo "#define HAVE_ICONV 1" >>confdefs.h
15022 if test "$am_cv_lib_iconv" = yes; then
15023 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libiconv" >&5
15024 $as_echo_n "checking how to link with libiconv... " >&6; }
15025 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBICONV" >&5
15026 $as_echo "$LIBICONV" >&6; }
15027 else
15028 CPPFLAGS="$am_save_CPPFLAGS"
15029 LIBICONV=
15030 LTLIBICONV=
15035 if test "$am_cv_func_iconv" = yes; then
15036 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether iconv is compatible with its POSIX signature" >&5
15037 $as_echo_n "checking whether iconv is compatible with its POSIX signature... " >&6; }
15038 if ${gl_cv_iconv_nonconst+:} false; then :
15039 $as_echo_n "(cached) " >&6
15040 else
15041 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15042 /* end confdefs.h. */
15044 #include <stdlib.h>
15045 #include <iconv.h>
15046 extern
15047 #ifdef __cplusplus
15049 #endif
15050 size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);
15053 main ()
15057 return 0;
15059 _ACEOF
15060 if ac_fn_c_try_compile "$LINENO"; then :
15061 gl_cv_iconv_nonconst=yes
15062 else
15063 gl_cv_iconv_nonconst=no
15065 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15068 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_iconv_nonconst" >&5
15069 $as_echo "$gl_cv_iconv_nonconst" >&6; }
15070 else
15071 gl_cv_iconv_nonconst=yes
15073 if test $gl_cv_iconv_nonconst = yes; then
15074 iconv_arg1=""
15075 else
15076 iconv_arg1="const"
15079 cat >>confdefs.h <<_ACEOF
15080 #define ICONV_CONST $iconv_arg1
15081 _ACEOF
15085 if test "$am_func_iconv" = yes; then
15086 if test -n "$LIBICONV"; then
15087 am_cv_func_iconv_summary='yes, in libiconv'
15088 else
15089 am_cv_func_iconv_summary='yes, in libc'
15091 else
15092 if test "$am_cv_func_iconv" = yes; then
15093 am_cv_func_iconv_summary='not working, consider installing GNU libiconv'
15094 else
15095 am_cv_func_iconv_summary='no, consider installing GNU libiconv'
15099 MAYBE_LIBICONV=
15100 case "$host" in
15101 *linux*)
15102 if test "$am_cv_func_iconv" != yes; then
15103 as_fn_error $? "could not find libiconv (required for host $host)" "$LINENO" 5
15106 MAYBE_LIBICONV="$LIBICONV"
15108 esac
15112 ac_config_files="$ac_config_files Makefile"
15115 cat >confcache <<\_ACEOF
15116 # This file is a shell script that caches the results of configure
15117 # tests run on this system so they can be shared between configure
15118 # scripts and configure runs, see configure's option --config-cache.
15119 # It is not useful on other systems. If it contains results you don't
15120 # want to keep, you may remove or edit it.
15122 # config.status only pays attention to the cache file if you give it
15123 # the --recheck option to rerun configure.
15125 # `ac_cv_env_foo' variables (set or unset) will be overridden when
15126 # loading this file, other *unset* `ac_cv_foo' will be assigned the
15127 # following values.
15129 _ACEOF
15131 # The following way of writing the cache mishandles newlines in values,
15132 # but we know of no workaround that is simple, portable, and efficient.
15133 # So, we kill variables containing newlines.
15134 # Ultrix sh set writes to stderr and can't be redirected directly,
15135 # and sets the high bit in the cache file unless we assign to the vars.
15137 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
15138 eval ac_val=\$$ac_var
15139 case $ac_val in #(
15140 *${as_nl}*)
15141 case $ac_var in #(
15142 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
15143 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
15144 esac
15145 case $ac_var in #(
15146 _ | IFS | as_nl) ;; #(
15147 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
15148 *) { eval $ac_var=; unset $ac_var;} ;;
15149 esac ;;
15150 esac
15151 done
15153 (set) 2>&1 |
15154 case $as_nl`(ac_space=' '; set) 2>&1` in #(
15155 *${as_nl}ac_space=\ *)
15156 # `set' does not quote correctly, so add quotes: double-quote
15157 # substitution turns \\\\ into \\, and sed turns \\ into \.
15158 sed -n \
15159 "s/'/'\\\\''/g;
15160 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
15161 ;; #(
15163 # `set' quotes correctly as required by POSIX, so do not add quotes.
15164 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
15166 esac |
15167 sort
15169 sed '
15170 /^ac_cv_env_/b end
15171 t clear
15172 :clear
15173 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
15174 t end
15175 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
15176 :end' >>confcache
15177 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
15178 if test -w "$cache_file"; then
15179 if test "x$cache_file" != "x/dev/null"; then
15180 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
15181 $as_echo "$as_me: updating cache $cache_file" >&6;}
15182 if test ! -f "$cache_file" || test -h "$cache_file"; then
15183 cat confcache >"$cache_file"
15184 else
15185 case $cache_file in #(
15186 */* | ?:*)
15187 mv -f confcache "$cache_file"$$ &&
15188 mv -f "$cache_file"$$ "$cache_file" ;; #(
15190 mv -f confcache "$cache_file" ;;
15191 esac
15194 else
15195 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
15196 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
15199 rm -f confcache
15201 test "x$prefix" = xNONE && prefix=$ac_default_prefix
15202 # Let make expand exec_prefix.
15203 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
15205 DEFS=-DHAVE_CONFIG_H
15207 ac_libobjs=
15208 ac_ltlibobjs=
15210 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
15211 # 1. Remove the extension, and $U if already installed.
15212 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
15213 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
15214 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
15215 # will be set to the directory where LIBOBJS objects are built.
15216 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
15217 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
15218 done
15219 LIBOBJS=$ac_libobjs
15221 LTLIBOBJS=$ac_ltlibobjs
15224 if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
15225 as_fn_error $? "conditional \"MAINTAINER_MODE\" was never defined.
15226 Usually this means the macro was only invoked conditionally." "$LINENO" 5
15229 : "${CONFIG_STATUS=./config.status}"
15230 ac_write_fail=0
15231 ac_clean_files_save=$ac_clean_files
15232 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
15233 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
15234 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
15235 as_write_fail=0
15236 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
15237 #! $SHELL
15238 # Generated by $as_me.
15239 # Run this file to recreate the current configuration.
15240 # Compiler output produced by configure, useful for debugging
15241 # configure, is in config.log if it exists.
15243 debug=false
15244 ac_cs_recheck=false
15245 ac_cs_silent=false
15247 SHELL=\${CONFIG_SHELL-$SHELL}
15248 export SHELL
15249 _ASEOF
15250 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
15251 ## -------------------- ##
15252 ## M4sh Initialization. ##
15253 ## -------------------- ##
15255 # Be more Bourne compatible
15256 DUALCASE=1; export DUALCASE # for MKS sh
15257 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
15258 emulate sh
15259 NULLCMD=:
15260 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
15261 # is contrary to our usage. Disable this feature.
15262 alias -g '${1+"$@"}'='"$@"'
15263 setopt NO_GLOB_SUBST
15264 else
15265 case `(set -o) 2>/dev/null` in #(
15266 *posix*) :
15267 set -o posix ;; #(
15268 *) :
15270 esac
15274 as_nl='
15276 export as_nl
15277 # Printing a long string crashes Solaris 7 /usr/bin/printf.
15278 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
15279 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
15280 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
15281 # Prefer a ksh shell builtin over an external printf program on Solaris,
15282 # but without wasting forks for bash or zsh.
15283 if test -z "$BASH_VERSION$ZSH_VERSION" \
15284 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
15285 as_echo='print -r --'
15286 as_echo_n='print -rn --'
15287 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
15288 as_echo='printf %s\n'
15289 as_echo_n='printf %s'
15290 else
15291 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
15292 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
15293 as_echo_n='/usr/ucb/echo -n'
15294 else
15295 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
15296 as_echo_n_body='eval
15297 arg=$1;
15298 case $arg in #(
15299 *"$as_nl"*)
15300 expr "X$arg" : "X\\(.*\\)$as_nl";
15301 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
15302 esac;
15303 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
15305 export as_echo_n_body
15306 as_echo_n='sh -c $as_echo_n_body as_echo'
15308 export as_echo_body
15309 as_echo='sh -c $as_echo_body as_echo'
15312 # The user is always right.
15313 if test "${PATH_SEPARATOR+set}" != set; then
15314 PATH_SEPARATOR=:
15315 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
15316 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
15317 PATH_SEPARATOR=';'
15322 # IFS
15323 # We need space, tab and new line, in precisely that order. Quoting is
15324 # there to prevent editors from complaining about space-tab.
15325 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
15326 # splitting by setting IFS to empty value.)
15327 IFS=" "" $as_nl"
15329 # Find who we are. Look in the path if we contain no directory separator.
15330 as_myself=
15331 case $0 in #((
15332 *[\\/]* ) as_myself=$0 ;;
15333 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15334 for as_dir in $PATH
15336 IFS=$as_save_IFS
15337 test -z "$as_dir" && as_dir=.
15338 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
15339 done
15340 IFS=$as_save_IFS
15343 esac
15344 # We did not find ourselves, most probably we were run as `sh COMMAND'
15345 # in which case we are not to be found in the path.
15346 if test "x$as_myself" = x; then
15347 as_myself=$0
15349 if test ! -f "$as_myself"; then
15350 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
15351 exit 1
15354 # Unset variables that we do not need and which cause bugs (e.g. in
15355 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
15356 # suppresses any "Segmentation fault" message there. '((' could
15357 # trigger a bug in pdksh 5.2.14.
15358 for as_var in BASH_ENV ENV MAIL MAILPATH
15359 do eval test x\${$as_var+set} = xset \
15360 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
15361 done
15362 PS1='$ '
15363 PS2='> '
15364 PS4='+ '
15366 # NLS nuisances.
15367 LC_ALL=C
15368 export LC_ALL
15369 LANGUAGE=C
15370 export LANGUAGE
15372 # CDPATH.
15373 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
15376 # as_fn_error STATUS ERROR [LINENO LOG_FD]
15377 # ----------------------------------------
15378 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
15379 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
15380 # script with STATUS, using 1 if that was 0.
15381 as_fn_error ()
15383 as_status=$1; test $as_status -eq 0 && as_status=1
15384 if test "$4"; then
15385 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
15386 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
15388 $as_echo "$as_me: error: $2" >&2
15389 as_fn_exit $as_status
15390 } # as_fn_error
15393 # as_fn_set_status STATUS
15394 # -----------------------
15395 # Set $? to STATUS, without forking.
15396 as_fn_set_status ()
15398 return $1
15399 } # as_fn_set_status
15401 # as_fn_exit STATUS
15402 # -----------------
15403 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
15404 as_fn_exit ()
15406 set +e
15407 as_fn_set_status $1
15408 exit $1
15409 } # as_fn_exit
15411 # as_fn_unset VAR
15412 # ---------------
15413 # Portably unset VAR.
15414 as_fn_unset ()
15416 { eval $1=; unset $1;}
15418 as_unset=as_fn_unset
15419 # as_fn_append VAR VALUE
15420 # ----------------------
15421 # Append the text in VALUE to the end of the definition contained in VAR. Take
15422 # advantage of any shell optimizations that allow amortized linear growth over
15423 # repeated appends, instead of the typical quadratic growth present in naive
15424 # implementations.
15425 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
15426 eval 'as_fn_append ()
15428 eval $1+=\$2
15430 else
15431 as_fn_append ()
15433 eval $1=\$$1\$2
15435 fi # as_fn_append
15437 # as_fn_arith ARG...
15438 # ------------------
15439 # Perform arithmetic evaluation on the ARGs, and store the result in the
15440 # global $as_val. Take advantage of shells that can avoid forks. The arguments
15441 # must be portable across $(()) and expr.
15442 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
15443 eval 'as_fn_arith ()
15445 as_val=$(( $* ))
15447 else
15448 as_fn_arith ()
15450 as_val=`expr "$@" || test $? -eq 1`
15452 fi # as_fn_arith
15455 if expr a : '\(a\)' >/dev/null 2>&1 &&
15456 test "X`expr 00001 : '.*\(...\)'`" = X001; then
15457 as_expr=expr
15458 else
15459 as_expr=false
15462 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
15463 as_basename=basename
15464 else
15465 as_basename=false
15468 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
15469 as_dirname=dirname
15470 else
15471 as_dirname=false
15474 as_me=`$as_basename -- "$0" ||
15475 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
15476 X"$0" : 'X\(//\)$' \| \
15477 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
15478 $as_echo X/"$0" |
15479 sed '/^.*\/\([^/][^/]*\)\/*$/{
15480 s//\1/
15483 /^X\/\(\/\/\)$/{
15484 s//\1/
15487 /^X\/\(\/\).*/{
15488 s//\1/
15491 s/.*/./; q'`
15493 # Avoid depending upon Character Ranges.
15494 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
15495 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
15496 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
15497 as_cr_digits='0123456789'
15498 as_cr_alnum=$as_cr_Letters$as_cr_digits
15500 ECHO_C= ECHO_N= ECHO_T=
15501 case `echo -n x` in #(((((
15502 -n*)
15503 case `echo 'xy\c'` in
15504 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
15505 xy) ECHO_C='\c';;
15506 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
15507 ECHO_T=' ';;
15508 esac;;
15510 ECHO_N='-n';;
15511 esac
15513 rm -f conf$$ conf$$.exe conf$$.file
15514 if test -d conf$$.dir; then
15515 rm -f conf$$.dir/conf$$.file
15516 else
15517 rm -f conf$$.dir
15518 mkdir conf$$.dir 2>/dev/null
15520 if (echo >conf$$.file) 2>/dev/null; then
15521 if ln -s conf$$.file conf$$ 2>/dev/null; then
15522 as_ln_s='ln -s'
15523 # ... but there are two gotchas:
15524 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
15525 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
15526 # In both cases, we have to default to `cp -pR'.
15527 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
15528 as_ln_s='cp -pR'
15529 elif ln conf$$.file conf$$ 2>/dev/null; then
15530 as_ln_s=ln
15531 else
15532 as_ln_s='cp -pR'
15534 else
15535 as_ln_s='cp -pR'
15537 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
15538 rmdir conf$$.dir 2>/dev/null
15541 # as_fn_mkdir_p
15542 # -------------
15543 # Create "$as_dir" as a directory, including parents if necessary.
15544 as_fn_mkdir_p ()
15547 case $as_dir in #(
15548 -*) as_dir=./$as_dir;;
15549 esac
15550 test -d "$as_dir" || eval $as_mkdir_p || {
15551 as_dirs=
15552 while :; do
15553 case $as_dir in #(
15554 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
15555 *) as_qdir=$as_dir;;
15556 esac
15557 as_dirs="'$as_qdir' $as_dirs"
15558 as_dir=`$as_dirname -- "$as_dir" ||
15559 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
15560 X"$as_dir" : 'X\(//\)[^/]' \| \
15561 X"$as_dir" : 'X\(//\)$' \| \
15562 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
15563 $as_echo X"$as_dir" |
15564 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
15565 s//\1/
15568 /^X\(\/\/\)[^/].*/{
15569 s//\1/
15572 /^X\(\/\/\)$/{
15573 s//\1/
15576 /^X\(\/\).*/{
15577 s//\1/
15580 s/.*/./; q'`
15581 test -d "$as_dir" && break
15582 done
15583 test -z "$as_dirs" || eval "mkdir $as_dirs"
15584 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
15587 } # as_fn_mkdir_p
15588 if mkdir -p . 2>/dev/null; then
15589 as_mkdir_p='mkdir -p "$as_dir"'
15590 else
15591 test -d ./-p && rmdir ./-p
15592 as_mkdir_p=false
15596 # as_fn_executable_p FILE
15597 # -----------------------
15598 # Test if FILE is an executable regular file.
15599 as_fn_executable_p ()
15601 test -f "$1" && test -x "$1"
15602 } # as_fn_executable_p
15603 as_test_x='test -x'
15604 as_executable_p=as_fn_executable_p
15606 # Sed expression to map a string onto a valid CPP name.
15607 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
15609 # Sed expression to map a string onto a valid variable name.
15610 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
15613 exec 6>&1
15614 ## ----------------------------------- ##
15615 ## Main body of $CONFIG_STATUS script. ##
15616 ## ----------------------------------- ##
15617 _ASEOF
15618 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
15620 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15621 # Save the log message, to keep $0 and so on meaningful, and to
15622 # report actual input values of CONFIG_FILES etc. instead of their
15623 # values after options handling.
15624 ac_log="
15625 This file was extended by $as_me, which was
15626 generated by GNU Autoconf 2.69. Invocation command line was
15628 CONFIG_FILES = $CONFIG_FILES
15629 CONFIG_HEADERS = $CONFIG_HEADERS
15630 CONFIG_LINKS = $CONFIG_LINKS
15631 CONFIG_COMMANDS = $CONFIG_COMMANDS
15632 $ $0 $@
15634 on `(hostname || uname -n) 2>/dev/null | sed 1q`
15637 _ACEOF
15639 case $ac_config_files in *"
15640 "*) set x $ac_config_files; shift; ac_config_files=$*;;
15641 esac
15643 case $ac_config_headers in *"
15644 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
15645 esac
15648 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15649 # Files that config.status was made for.
15650 config_files="$ac_config_files"
15651 config_headers="$ac_config_headers"
15652 config_commands="$ac_config_commands"
15654 _ACEOF
15656 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15657 ac_cs_usage="\
15658 \`$as_me' instantiates files and other configuration actions
15659 from templates according to the current configuration. Unless the files
15660 and actions are specified as TAGs, all are instantiated by default.
15662 Usage: $0 [OPTION]... [TAG]...
15664 -h, --help print this help, then exit
15665 -V, --version print version number and configuration settings, then exit
15666 --config print configuration, then exit
15667 -q, --quiet, --silent
15668 do not print progress messages
15669 -d, --debug don't remove temporary files
15670 --recheck update $as_me by reconfiguring in the same conditions
15671 --file=FILE[:TEMPLATE]
15672 instantiate the configuration file FILE
15673 --header=FILE[:TEMPLATE]
15674 instantiate the configuration header FILE
15676 Configuration files:
15677 $config_files
15679 Configuration headers:
15680 $config_headers
15682 Configuration commands:
15683 $config_commands
15685 Report bugs to the package provider."
15687 _ACEOF
15688 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15689 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
15690 ac_cs_version="\\
15691 config.status
15692 configured by $0, generated by GNU Autoconf 2.69,
15693 with options \\"\$ac_cs_config\\"
15695 Copyright (C) 2012 Free Software Foundation, Inc.
15696 This config.status script is free software; the Free Software Foundation
15697 gives unlimited permission to copy, distribute and modify it."
15699 ac_pwd='$ac_pwd'
15700 srcdir='$srcdir'
15701 INSTALL='$INSTALL'
15702 test -n "\$AWK" || AWK=awk
15703 _ACEOF
15705 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15706 # The default lists apply if the user does not specify any file.
15707 ac_need_defaults=:
15708 while test $# != 0
15710 case $1 in
15711 --*=?*)
15712 ac_option=`expr "X$1" : 'X\([^=]*\)='`
15713 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
15714 ac_shift=:
15716 --*=)
15717 ac_option=`expr "X$1" : 'X\([^=]*\)='`
15718 ac_optarg=
15719 ac_shift=:
15722 ac_option=$1
15723 ac_optarg=$2
15724 ac_shift=shift
15726 esac
15728 case $ac_option in
15729 # Handling of the options.
15730 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
15731 ac_cs_recheck=: ;;
15732 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
15733 $as_echo "$ac_cs_version"; exit ;;
15734 --config | --confi | --conf | --con | --co | --c )
15735 $as_echo "$ac_cs_config"; exit ;;
15736 --debug | --debu | --deb | --de | --d | -d )
15737 debug=: ;;
15738 --file | --fil | --fi | --f )
15739 $ac_shift
15740 case $ac_optarg in
15741 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
15742 '') as_fn_error $? "missing file argument" ;;
15743 esac
15744 as_fn_append CONFIG_FILES " '$ac_optarg'"
15745 ac_need_defaults=false;;
15746 --header | --heade | --head | --hea )
15747 $ac_shift
15748 case $ac_optarg in
15749 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
15750 esac
15751 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
15752 ac_need_defaults=false;;
15753 --he | --h)
15754 # Conflict between --help and --header
15755 as_fn_error $? "ambiguous option: \`$1'
15756 Try \`$0 --help' for more information.";;
15757 --help | --hel | -h )
15758 $as_echo "$ac_cs_usage"; exit ;;
15759 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
15760 | -silent | --silent | --silen | --sile | --sil | --si | --s)
15761 ac_cs_silent=: ;;
15763 # This is an error.
15764 -*) as_fn_error $? "unrecognized option: \`$1'
15765 Try \`$0 --help' for more information." ;;
15767 *) as_fn_append ac_config_targets " $1"
15768 ac_need_defaults=false ;;
15770 esac
15771 shift
15772 done
15774 ac_configure_extra_args=
15776 if $ac_cs_silent; then
15777 exec 6>/dev/null
15778 ac_configure_extra_args="$ac_configure_extra_args --silent"
15781 _ACEOF
15782 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15783 if \$ac_cs_recheck; then
15784 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
15785 shift
15786 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
15787 CONFIG_SHELL='$SHELL'
15788 export CONFIG_SHELL
15789 exec "\$@"
15792 _ACEOF
15793 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15794 exec 5>>config.log
15796 echo
15797 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
15798 ## Running $as_me. ##
15799 _ASBOX
15800 $as_echo "$ac_log"
15801 } >&5
15803 _ACEOF
15804 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15806 # INIT-COMMANDS
15808 ac_aux_dir=$ac_aux_dir DEPDIR=$DEPDIR
15809 # Capture the value of obsolete ALL_LINGUAS because we need it to compute
15810 # POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES, CATALOGS. But hide it
15811 # from automake.
15812 eval 'OBSOLETE_ALL_LINGUAS''="$ALL_LINGUAS"'
15813 # Capture the value of LINGUAS because we need it to compute CATALOGS.
15814 LINGUAS="${LINGUAS-%UNSET%}"
15816 ac_aux_dir=$ac_aux_dir DEPDIR=$DEPDIR CONFIG_SRC_SUBDIR="$CONFIG_SRC_SUBDIR"
15818 _ACEOF
15820 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15822 # Handling of arguments.
15823 for ac_config_target in $ac_config_targets
15825 case $ac_config_target in
15826 "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h:config.in" ;;
15827 "depdir") CONFIG_COMMANDS="$CONFIG_COMMANDS depdir" ;;
15828 "default-1") CONFIG_COMMANDS="$CONFIG_COMMANDS default-1" ;;
15829 "gdbdepdir") CONFIG_COMMANDS="$CONFIG_COMMANDS gdbdepdir" ;;
15830 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
15832 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
15833 esac
15834 done
15837 # If the user did not use the arguments to specify the items to instantiate,
15838 # then the envvar interface is used. Set only those that are not.
15839 # We use the long form for the default assignment because of an extremely
15840 # bizarre bug on SunOS 4.1.3.
15841 if $ac_need_defaults; then
15842 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
15843 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
15844 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
15847 # Have a temporary directory for convenience. Make it in the build tree
15848 # simply because there is no reason against having it here, and in addition,
15849 # creating and moving files from /tmp can sometimes cause problems.
15850 # Hook for its removal unless debugging.
15851 # Note that there is a small window in which the directory will not be cleaned:
15852 # after its creation but before its name has been assigned to `$tmp'.
15853 $debug ||
15855 tmp= ac_tmp=
15856 trap 'exit_status=$?
15857 : "${ac_tmp:=$tmp}"
15858 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
15860 trap 'as_fn_exit 1' 1 2 13 15
15862 # Create a (secure) tmp directory for tmp files.
15865 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
15866 test -d "$tmp"
15867 } ||
15869 tmp=./conf$$-$RANDOM
15870 (umask 077 && mkdir "$tmp")
15871 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
15872 ac_tmp=$tmp
15874 # Set up the scripts for CONFIG_FILES section.
15875 # No need to generate them if there are no CONFIG_FILES.
15876 # This happens for instance with `./config.status config.h'.
15877 if test -n "$CONFIG_FILES"; then
15880 ac_cr=`echo X | tr X '\015'`
15881 # On cygwin, bash can eat \r inside `` if the user requested igncr.
15882 # But we know of no other shell where ac_cr would be empty at this
15883 # point, so we can use a bashism as a fallback.
15884 if test "x$ac_cr" = x; then
15885 eval ac_cr=\$\'\\r\'
15887 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
15888 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
15889 ac_cs_awk_cr='\\r'
15890 else
15891 ac_cs_awk_cr=$ac_cr
15894 echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
15895 _ACEOF
15899 echo "cat >conf$$subs.awk <<_ACEOF" &&
15900 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
15901 echo "_ACEOF"
15902 } >conf$$subs.sh ||
15903 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
15904 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
15905 ac_delim='%!_!# '
15906 for ac_last_try in false false false false false :; do
15907 . ./conf$$subs.sh ||
15908 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
15910 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
15911 if test $ac_delim_n = $ac_delim_num; then
15912 break
15913 elif $ac_last_try; then
15914 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
15915 else
15916 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
15918 done
15919 rm -f conf$$subs.sh
15921 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15922 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
15923 _ACEOF
15924 sed -n '
15926 s/^/S["/; s/!.*/"]=/
15929 s/^[^!]*!//
15930 :repl
15931 t repl
15932 s/'"$ac_delim"'$//
15933 t delim
15936 s/\(.\{148\}\)..*/\1/
15937 t more1
15938 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
15941 b repl
15942 :more1
15943 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
15946 s/.\{148\}//
15947 t nl
15948 :delim
15950 s/\(.\{148\}\)..*/\1/
15951 t more2
15952 s/["\\]/\\&/g; s/^/"/; s/$/"/
15955 :more2
15956 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
15959 s/.\{148\}//
15960 t delim
15961 ' <conf$$subs.awk | sed '
15962 /^[^""]/{
15964 s/\n//
15966 ' >>$CONFIG_STATUS || ac_write_fail=1
15967 rm -f conf$$subs.awk
15968 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15969 _ACAWK
15970 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
15971 for (key in S) S_is_set[key] = 1
15972 FS = "\a"
15976 line = $ 0
15977 nfields = split(line, field, "@")
15978 substed = 0
15979 len = length(field[1])
15980 for (i = 2; i < nfields; i++) {
15981 key = field[i]
15982 keylen = length(key)
15983 if (S_is_set[key]) {
15984 value = S[key]
15985 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
15986 len += length(value) + length(field[++i])
15987 substed = 1
15988 } else
15989 len += 1 + keylen
15992 print line
15995 _ACAWK
15996 _ACEOF
15997 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15998 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
15999 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
16000 else
16002 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
16003 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
16004 _ACEOF
16006 # VPATH may cause trouble with some makes, so we remove sole $(srcdir),
16007 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
16008 # trailing colons and then remove the whole line if VPATH becomes empty
16009 # (actually we leave an empty line to preserve line numbers).
16010 if test "x$srcdir" = x.; then
16011 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
16013 s///
16014 s/^/:/
16015 s/[ ]*$/:/
16016 s/:\$(srcdir):/:/g
16017 s/:\${srcdir}:/:/g
16018 s/:@srcdir@:/:/g
16019 s/^:*//
16020 s/:*$//
16022 s/\(=[ ]*\).*/\1/
16024 s/\n//
16025 s/^[^=]*=[ ]*$//
16029 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
16030 fi # test -n "$CONFIG_FILES"
16032 # Set up the scripts for CONFIG_HEADERS section.
16033 # No need to generate them if there are no CONFIG_HEADERS.
16034 # This happens for instance with `./config.status Makefile'.
16035 if test -n "$CONFIG_HEADERS"; then
16036 cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
16037 BEGIN {
16038 _ACEOF
16040 # Transform confdefs.h into an awk script `defines.awk', embedded as
16041 # here-document in config.status, that substitutes the proper values into
16042 # config.h.in to produce config.h.
16044 # Create a delimiter string that does not exist in confdefs.h, to ease
16045 # handling of long lines.
16046 ac_delim='%!_!# '
16047 for ac_last_try in false false :; do
16048 ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
16049 if test -z "$ac_tt"; then
16050 break
16051 elif $ac_last_try; then
16052 as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
16053 else
16054 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
16056 done
16058 # For the awk script, D is an array of macro values keyed by name,
16059 # likewise P contains macro parameters if any. Preserve backslash
16060 # newline sequences.
16062 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
16063 sed -n '
16064 s/.\{148\}/&'"$ac_delim"'/g
16065 t rset
16066 :rset
16067 s/^[ ]*#[ ]*define[ ][ ]*/ /
16068 t def
16070 :def
16071 s/\\$//
16072 t bsnl
16073 s/["\\]/\\&/g
16074 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
16075 D["\1"]=" \3"/p
16076 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
16078 :bsnl
16079 s/["\\]/\\&/g
16080 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
16081 D["\1"]=" \3\\\\\\n"\\/p
16082 t cont
16083 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
16084 t cont
16086 :cont
16088 s/.\{148\}/&'"$ac_delim"'/g
16089 t clear
16090 :clear
16091 s/\\$//
16092 t bsnlc
16093 s/["\\]/\\&/g; s/^/"/; s/$/"/p
16095 :bsnlc
16096 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
16097 b cont
16098 ' <confdefs.h | sed '
16099 s/'"$ac_delim"'/"\\\
16100 "/g' >>$CONFIG_STATUS || ac_write_fail=1
16102 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
16103 for (key in D) D_is_set[key] = 1
16104 FS = "\a"
16106 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
16107 line = \$ 0
16108 split(line, arg, " ")
16109 if (arg[1] == "#") {
16110 defundef = arg[2]
16111 mac1 = arg[3]
16112 } else {
16113 defundef = substr(arg[1], 2)
16114 mac1 = arg[2]
16116 split(mac1, mac2, "(") #)
16117 macro = mac2[1]
16118 prefix = substr(line, 1, index(line, defundef) - 1)
16119 if (D_is_set[macro]) {
16120 # Preserve the white space surrounding the "#".
16121 print prefix "define", macro P[macro] D[macro]
16122 next
16123 } else {
16124 # Replace #undef with comments. This is necessary, for example,
16125 # in the case of _POSIX_SOURCE, which is predefined and required
16126 # on some systems where configure will not decide to define it.
16127 if (defundef == "undef") {
16128 print "/*", prefix defundef, macro, "*/"
16129 next
16133 { print }
16134 _ACAWK
16135 _ACEOF
16136 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
16137 as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
16138 fi # test -n "$CONFIG_HEADERS"
16141 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
16142 shift
16143 for ac_tag
16145 case $ac_tag in
16146 :[FHLC]) ac_mode=$ac_tag; continue;;
16147 esac
16148 case $ac_mode$ac_tag in
16149 :[FHL]*:*);;
16150 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
16151 :[FH]-) ac_tag=-:-;;
16152 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
16153 esac
16154 ac_save_IFS=$IFS
16155 IFS=:
16156 set x $ac_tag
16157 IFS=$ac_save_IFS
16158 shift
16159 ac_file=$1
16160 shift
16162 case $ac_mode in
16163 :L) ac_source=$1;;
16164 :[FH])
16165 ac_file_inputs=
16166 for ac_f
16168 case $ac_f in
16169 -) ac_f="$ac_tmp/stdin";;
16170 *) # Look for the file first in the build tree, then in the source tree
16171 # (if the path is not absolute). The absolute path cannot be DOS-style,
16172 # because $ac_f cannot contain `:'.
16173 test -f "$ac_f" ||
16174 case $ac_f in
16175 [\\/$]*) false;;
16176 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
16177 esac ||
16178 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
16179 esac
16180 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
16181 as_fn_append ac_file_inputs " '$ac_f'"
16182 done
16184 # Let's still pretend it is `configure' which instantiates (i.e., don't
16185 # use $as_me), people would be surprised to read:
16186 # /* config.h. Generated by config.status. */
16187 configure_input='Generated from '`
16188 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
16189 `' by configure.'
16190 if test x"$ac_file" != x-; then
16191 configure_input="$ac_file. $configure_input"
16192 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
16193 $as_echo "$as_me: creating $ac_file" >&6;}
16195 # Neutralize special characters interpreted by sed in replacement strings.
16196 case $configure_input in #(
16197 *\&* | *\|* | *\\* )
16198 ac_sed_conf_input=`$as_echo "$configure_input" |
16199 sed 's/[\\\\&|]/\\\\&/g'`;; #(
16200 *) ac_sed_conf_input=$configure_input;;
16201 esac
16203 case $ac_tag in
16204 *:-:* | *:-) cat >"$ac_tmp/stdin" \
16205 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
16206 esac
16208 esac
16210 ac_dir=`$as_dirname -- "$ac_file" ||
16211 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
16212 X"$ac_file" : 'X\(//\)[^/]' \| \
16213 X"$ac_file" : 'X\(//\)$' \| \
16214 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
16215 $as_echo X"$ac_file" |
16216 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
16217 s//\1/
16220 /^X\(\/\/\)[^/].*/{
16221 s//\1/
16224 /^X\(\/\/\)$/{
16225 s//\1/
16228 /^X\(\/\).*/{
16229 s//\1/
16232 s/.*/./; q'`
16233 as_dir="$ac_dir"; as_fn_mkdir_p
16234 ac_builddir=.
16236 case "$ac_dir" in
16237 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
16239 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
16240 # A ".." for each directory in $ac_dir_suffix.
16241 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
16242 case $ac_top_builddir_sub in
16243 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
16244 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
16245 esac ;;
16246 esac
16247 ac_abs_top_builddir=$ac_pwd
16248 ac_abs_builddir=$ac_pwd$ac_dir_suffix
16249 # for backward compatibility:
16250 ac_top_builddir=$ac_top_build_prefix
16252 case $srcdir in
16253 .) # We are building in place.
16254 ac_srcdir=.
16255 ac_top_srcdir=$ac_top_builddir_sub
16256 ac_abs_top_srcdir=$ac_pwd ;;
16257 [\\/]* | ?:[\\/]* ) # Absolute name.
16258 ac_srcdir=$srcdir$ac_dir_suffix;
16259 ac_top_srcdir=$srcdir
16260 ac_abs_top_srcdir=$srcdir ;;
16261 *) # Relative name.
16262 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
16263 ac_top_srcdir=$ac_top_build_prefix$srcdir
16264 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
16265 esac
16266 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
16269 case $ac_mode in
16272 # CONFIG_FILE
16275 case $INSTALL in
16276 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
16277 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
16278 esac
16279 _ACEOF
16281 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
16282 # If the template does not know about datarootdir, expand it.
16283 # FIXME: This hack should be removed a few years after 2.60.
16284 ac_datarootdir_hack=; ac_datarootdir_seen=
16285 ac_sed_dataroot='
16286 /datarootdir/ {
16290 /@datadir@/p
16291 /@docdir@/p
16292 /@infodir@/p
16293 /@localedir@/p
16294 /@mandir@/p'
16295 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
16296 *datarootdir*) ac_datarootdir_seen=yes;;
16297 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
16298 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
16299 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
16300 _ACEOF
16301 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
16302 ac_datarootdir_hack='
16303 s&@datadir@&$datadir&g
16304 s&@docdir@&$docdir&g
16305 s&@infodir@&$infodir&g
16306 s&@localedir@&$localedir&g
16307 s&@mandir@&$mandir&g
16308 s&\\\${datarootdir}&$datarootdir&g' ;;
16309 esac
16310 _ACEOF
16312 # Neutralize VPATH when `$srcdir' = `.'.
16313 # Shell code in configure.ac might set extrasub.
16314 # FIXME: do we really want to maintain this feature?
16315 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
16316 ac_sed_extra="$ac_vpsub
16317 $extrasub
16318 _ACEOF
16319 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
16321 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
16322 s|@configure_input@|$ac_sed_conf_input|;t t
16323 s&@top_builddir@&$ac_top_builddir_sub&;t t
16324 s&@top_build_prefix@&$ac_top_build_prefix&;t t
16325 s&@srcdir@&$ac_srcdir&;t t
16326 s&@abs_srcdir@&$ac_abs_srcdir&;t t
16327 s&@top_srcdir@&$ac_top_srcdir&;t t
16328 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
16329 s&@builddir@&$ac_builddir&;t t
16330 s&@abs_builddir@&$ac_abs_builddir&;t t
16331 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
16332 s&@INSTALL@&$ac_INSTALL&;t t
16333 $ac_datarootdir_hack
16335 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
16336 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
16338 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
16339 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
16340 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
16341 "$ac_tmp/out"`; test -z "$ac_out"; } &&
16342 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
16343 which seems to be undefined. Please make sure it is defined" >&5
16344 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
16345 which seems to be undefined. Please make sure it is defined" >&2;}
16347 rm -f "$ac_tmp/stdin"
16348 case $ac_file in
16349 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
16350 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
16351 esac \
16352 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
16356 # CONFIG_HEADER
16358 if test x"$ac_file" != x-; then
16360 $as_echo "/* $configure_input */" \
16361 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
16362 } >"$ac_tmp/config.h" \
16363 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
16364 if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
16365 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
16366 $as_echo "$as_me: $ac_file is unchanged" >&6;}
16367 else
16368 rm -f "$ac_file"
16369 mv "$ac_tmp/config.h" "$ac_file" \
16370 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
16372 else
16373 $as_echo "/* $configure_input */" \
16374 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
16375 || as_fn_error $? "could not create -" "$LINENO" 5
16379 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
16380 $as_echo "$as_me: executing $ac_file commands" >&6;}
16382 esac
16385 case $ac_file$ac_mode in
16386 "config.h":H) echo > stamp-h ;;
16387 "depdir":C) $SHELL $ac_aux_dir/mkinstalldirs $DEPDIR ;;
16388 "default-1":C)
16389 for ac_file in $CONFIG_FILES; do
16390 # Support "outfile[:infile[:infile...]]"
16391 case "$ac_file" in
16392 *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
16393 esac
16394 # PO directories have a Makefile.in generated from Makefile.in.in.
16395 case "$ac_file" in */Makefile.in)
16396 # Adjust a relative srcdir.
16397 ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
16398 ac_dir_suffix=/`echo "$ac_dir"|sed 's%^\./%%'`
16399 ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
16400 # In autoconf-2.13 it is called $ac_given_srcdir.
16401 # In autoconf-2.50 it is called $srcdir.
16402 test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
16403 case "$ac_given_srcdir" in
16404 .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
16405 /*) top_srcdir="$ac_given_srcdir" ;;
16406 *) top_srcdir="$ac_dots$ac_given_srcdir" ;;
16407 esac
16408 if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
16409 rm -f "$ac_dir/POTFILES"
16410 test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES"
16411 cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES"
16412 POMAKEFILEDEPS="POTFILES.in"
16413 # ALL_LINGUAS, POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES depend
16414 # on $ac_dir but don't depend on user-specified configuration
16415 # parameters.
16416 if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
16417 # The LINGUAS file contains the set of available languages.
16418 if test -n "$OBSOLETE_ALL_LINGUAS"; then
16419 test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.ac is obsolete" || echo "setting ALL_LINGUAS in configure.ac is obsolete"
16421 ALL_LINGUAS_=`sed -e "/^#/d" "$ac_given_srcdir/$ac_dir/LINGUAS"`
16422 # Hide the ALL_LINGUAS assigment from automake.
16423 eval 'ALL_LINGUAS''=$ALL_LINGUAS_'
16424 POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS"
16425 else
16426 # The set of available languages was given in configure.ac.
16427 eval 'ALL_LINGUAS''=$OBSOLETE_ALL_LINGUAS'
16429 case "$ac_given_srcdir" in
16430 .) srcdirpre= ;;
16431 *) srcdirpre='$(srcdir)/' ;;
16432 esac
16433 POFILES=
16434 GMOFILES=
16435 UPDATEPOFILES=
16436 DUMMYPOFILES=
16437 for lang in $ALL_LINGUAS; do
16438 POFILES="$POFILES $srcdirpre$lang.po"
16439 GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
16440 UPDATEPOFILES="$UPDATEPOFILES $lang.po-update"
16441 DUMMYPOFILES="$DUMMYPOFILES $lang.nop"
16442 done
16443 # CATALOGS depends on both $ac_dir and the user's LINGUAS
16444 # environment variable.
16445 INST_LINGUAS=
16446 if test -n "$ALL_LINGUAS"; then
16447 for presentlang in $ALL_LINGUAS; do
16448 useit=no
16449 if test "%UNSET%" != "$LINGUAS"; then
16450 desiredlanguages="$LINGUAS"
16451 else
16452 desiredlanguages="$ALL_LINGUAS"
16454 for desiredlang in $desiredlanguages; do
16455 # Use the presentlang catalog if desiredlang is
16456 # a. equal to presentlang, or
16457 # b. a variant of presentlang (because in this case,
16458 # presentlang can be used as a fallback for messages
16459 # which are not translated in the desiredlang catalog).
16460 case "$desiredlang" in
16461 "$presentlang"*) useit=yes;;
16462 esac
16463 done
16464 if test $useit = yes; then
16465 INST_LINGUAS="$INST_LINGUAS $presentlang"
16467 done
16469 CATALOGS=
16470 if test -n "$INST_LINGUAS"; then
16471 for lang in $INST_LINGUAS; do
16472 CATALOGS="$CATALOGS $lang.gmo"
16473 done
16475 test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile"
16476 sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile"
16477 for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do
16478 if test -f "$f"; then
16479 case "$f" in
16480 *.orig | *.bak | *~) ;;
16481 *) cat "$f" >> "$ac_dir/Makefile" ;;
16482 esac
16484 done
16487 esac
16488 done ;;
16489 "gdbdepdir":C)
16490 for subdir in ${CONFIG_SRC_SUBDIR}
16492 $SHELL $ac_aux_dir/mkinstalldirs $subdir/$DEPDIR
16493 done ;;
16495 esac
16496 done # for ac_tag
16499 as_fn_exit 0
16500 _ACEOF
16501 ac_clean_files=$ac_clean_files_save
16503 test $ac_write_fail = 0 ||
16504 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
16507 # configure is writing to config.log, and then calls config.status.
16508 # config.status does its own redirection, appending to config.log.
16509 # Unfortunately, on DOS this fails, as config.log is still kept open
16510 # by configure, so config.status won't be able to write to it; its
16511 # output is simply discarded. So we exec the FD to /dev/null,
16512 # effectively closing config.log, so it can be properly (re)opened and
16513 # appended to by config.status. When coming back to configure, we
16514 # need to make the FD available again.
16515 if test "$no_create" != yes; then
16516 ac_cs_success=:
16517 ac_config_status_args=
16518 test "$silent" = yes &&
16519 ac_config_status_args="$ac_config_status_args --quiet"
16520 exec 5>/dev/null
16521 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
16522 exec 5>>config.log
16523 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
16524 # would make configure fail if this is the last instruction.
16525 $ac_cs_success || as_fn_exit 1
16527 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
16528 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
16529 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}