Mention support for AMD/znver5 in GAS
[binutils-gdb.git] / gdbserver / configure
blob0942ef173d453249d9fa31e347ac58a9ba4c9542
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 GNULIB_STDINT_H
627 extra_libraries
628 IPA_DEPFILES
629 srv_xmlfiles
630 srv_xmlbuiltin
631 GDBSERVER_LIBS
632 GDBSERVER_DEPFILES
633 RDYNAMIC
634 REPORT_BUGS_TEXI
635 REPORT_BUGS_TO
636 PKGVERSION
637 WERROR_CFLAGS
638 WARN_CFLAGS
639 ustinc
640 ustlibs
641 CCDEPMODE
642 CONFIG_SRC_SUBDIR
643 CATOBJEXT
644 GENCAT
645 INSTOBJEXT
646 DATADIRNAME
647 CATALOGS
648 INCINTL
649 LIBINTL_DEP
650 POSUB
651 LTLIBINTL
652 LIBINTL
653 INTLLIBS
654 LTLIBICONV
655 LIBICONV
656 INTL_MACOSX_LIBS
657 MSGMERGE
658 XGETTEXT
659 GMSGFMT
660 MSGFMT
661 USE_NLS
662 MKINSTALLDIRS
663 SET_MAKE
664 DEPDIR
665 am__leading_dot
666 host_noncanonical
667 target_noncanonical
668 WIN32APILIBS
669 LTLIBXXHASH
670 LIBXXHASH
671 HAVE_LIBXXHASH
672 LTLIBIPT
673 LIBIPT
674 HAVE_LIBIPT
675 PTHREAD_CFLAGS
676 PTHREAD_LIBS
677 PTHREAD_CC
678 ax_pthread_config
680 ALLOCA
681 CXX_DIALECT
682 HAVE_CXX17
683 RANLIB
685 INSTALL_DATA
686 INSTALL_SCRIPT
687 INSTALL_PROGRAM
688 target_os
689 target_vendor
690 target_cpu
691 target
692 host_os
693 host_vendor
694 host_cpu
695 host
696 build_os
697 build_vendor
698 build_cpu
699 build
700 INSTALL_STRIP_PROGRAM
701 STRIP
702 install_sh
703 EGREP
704 GREP
706 ac_ct_CXX
707 CXXFLAGS
709 OBJEXT
710 EXEEXT
711 ac_ct_CC
712 CPPFLAGS
713 LDFLAGS
714 CFLAGS
716 MAINT
717 MAINTAINER_MODE_FALSE
718 MAINTAINER_MODE_TRUE
719 target_alias
720 host_alias
721 build_alias
722 LIBS
723 ECHO_T
724 ECHO_N
725 ECHO_C
726 DEFS
727 mandir
728 localedir
729 libdir
730 psdir
731 pdfdir
732 dvidir
733 htmldir
734 infodir
735 docdir
736 oldincludedir
737 includedir
738 localstatedir
739 sharedstatedir
740 sysconfdir
741 datadir
742 datarootdir
743 libexecdir
744 sbindir
745 bindir
746 program_transform_name
747 prefix
748 exec_prefix
749 PACKAGE_URL
750 PACKAGE_BUGREPORT
751 PACKAGE_STRING
752 PACKAGE_VERSION
753 PACKAGE_TARNAME
754 PACKAGE_NAME
755 PATH_SEPARATOR
756 SHELL'
757 ac_subst_files=''
758 ac_user_opts='
759 enable_option_checking
760 enable_maintainer_mode
761 enable_largefile
762 enable_threading
763 with_intel_pt
764 with_gnu_ld
765 enable_rpath
766 with_libipt_prefix
767 with_libipt_type
768 with_xxhash
769 with_libxxhash_prefix
770 with_libxxhash_type
771 enable_unit_tests
772 enable_nls
773 with_libiconv_prefix
774 with_libiconv_type
775 with_libintl_prefix
776 with_libintl_type
777 with_ust
778 with_ust_include
779 with_ust_lib
780 enable_werror
781 enable_build_warnings
782 enable_gdb_build_warnings
783 with_pkgversion
784 with_bugurl
785 with_libthread_db
786 enable_inprocess_agent
788 ac_precious_vars='build_alias
789 host_alias
790 target_alias
792 CFLAGS
793 LDFLAGS
794 LIBS
795 CPPFLAGS
797 CXXFLAGS
799 CPP'
802 # Initialize some variables set by options.
803 ac_init_help=
804 ac_init_version=false
805 ac_unrecognized_opts=
806 ac_unrecognized_sep=
807 # The variables have the same names as the options, with
808 # dashes changed to underlines.
809 cache_file=/dev/null
810 exec_prefix=NONE
811 no_create=
812 no_recursion=
813 prefix=NONE
814 program_prefix=NONE
815 program_suffix=NONE
816 program_transform_name=s,x,x,
817 silent=
818 site=
819 srcdir=
820 verbose=
821 x_includes=NONE
822 x_libraries=NONE
824 # Installation directory options.
825 # These are left unexpanded so users can "make install exec_prefix=/foo"
826 # and all the variables that are supposed to be based on exec_prefix
827 # by default will actually change.
828 # Use braces instead of parens because sh, perl, etc. also accept them.
829 # (The list follows the same order as the GNU Coding Standards.)
830 bindir='${exec_prefix}/bin'
831 sbindir='${exec_prefix}/sbin'
832 libexecdir='${exec_prefix}/libexec'
833 datarootdir='${prefix}/share'
834 datadir='${datarootdir}'
835 sysconfdir='${prefix}/etc'
836 sharedstatedir='${prefix}/com'
837 localstatedir='${prefix}/var'
838 includedir='${prefix}/include'
839 oldincludedir='/usr/include'
840 docdir='${datarootdir}/doc/${PACKAGE}'
841 infodir='${datarootdir}/info'
842 htmldir='${docdir}'
843 dvidir='${docdir}'
844 pdfdir='${docdir}'
845 psdir='${docdir}'
846 libdir='${exec_prefix}/lib'
847 localedir='${datarootdir}/locale'
848 mandir='${datarootdir}/man'
850 ac_prev=
851 ac_dashdash=
852 for ac_option
854 # If the previous option needs an argument, assign it.
855 if test -n "$ac_prev"; then
856 eval $ac_prev=\$ac_option
857 ac_prev=
858 continue
861 case $ac_option in
862 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
863 *=) ac_optarg= ;;
864 *) ac_optarg=yes ;;
865 esac
867 # Accept the important Cygnus configure options, so we can diagnose typos.
869 case $ac_dashdash$ac_option in
871 ac_dashdash=yes ;;
873 -bindir | --bindir | --bindi | --bind | --bin | --bi)
874 ac_prev=bindir ;;
875 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
876 bindir=$ac_optarg ;;
878 -build | --build | --buil | --bui | --bu)
879 ac_prev=build_alias ;;
880 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
881 build_alias=$ac_optarg ;;
883 -cache-file | --cache-file | --cache-fil | --cache-fi \
884 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
885 ac_prev=cache_file ;;
886 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
887 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
888 cache_file=$ac_optarg ;;
890 --config-cache | -C)
891 cache_file=config.cache ;;
893 -datadir | --datadir | --datadi | --datad)
894 ac_prev=datadir ;;
895 -datadir=* | --datadir=* | --datadi=* | --datad=*)
896 datadir=$ac_optarg ;;
898 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
899 | --dataroo | --dataro | --datar)
900 ac_prev=datarootdir ;;
901 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
902 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
903 datarootdir=$ac_optarg ;;
905 -disable-* | --disable-*)
906 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
907 # Reject names that are not valid shell variable names.
908 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
909 as_fn_error $? "invalid feature name: $ac_useropt"
910 ac_useropt_orig=$ac_useropt
911 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
912 case $ac_user_opts in
914 "enable_$ac_useropt"
915 "*) ;;
916 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
917 ac_unrecognized_sep=', ';;
918 esac
919 eval enable_$ac_useropt=no ;;
921 -docdir | --docdir | --docdi | --doc | --do)
922 ac_prev=docdir ;;
923 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
924 docdir=$ac_optarg ;;
926 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
927 ac_prev=dvidir ;;
928 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
929 dvidir=$ac_optarg ;;
931 -enable-* | --enable-*)
932 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
933 # Reject names that are not valid shell variable names.
934 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
935 as_fn_error $? "invalid feature name: $ac_useropt"
936 ac_useropt_orig=$ac_useropt
937 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
938 case $ac_user_opts in
940 "enable_$ac_useropt"
941 "*) ;;
942 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
943 ac_unrecognized_sep=', ';;
944 esac
945 eval enable_$ac_useropt=\$ac_optarg ;;
947 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
948 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
949 | --exec | --exe | --ex)
950 ac_prev=exec_prefix ;;
951 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
952 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
953 | --exec=* | --exe=* | --ex=*)
954 exec_prefix=$ac_optarg ;;
956 -gas | --gas | --ga | --g)
957 # Obsolete; use --with-gas.
958 with_gas=yes ;;
960 -help | --help | --hel | --he | -h)
961 ac_init_help=long ;;
962 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
963 ac_init_help=recursive ;;
964 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
965 ac_init_help=short ;;
967 -host | --host | --hos | --ho)
968 ac_prev=host_alias ;;
969 -host=* | --host=* | --hos=* | --ho=*)
970 host_alias=$ac_optarg ;;
972 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
973 ac_prev=htmldir ;;
974 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
975 | --ht=*)
976 htmldir=$ac_optarg ;;
978 -includedir | --includedir | --includedi | --included | --include \
979 | --includ | --inclu | --incl | --inc)
980 ac_prev=includedir ;;
981 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
982 | --includ=* | --inclu=* | --incl=* | --inc=*)
983 includedir=$ac_optarg ;;
985 -infodir | --infodir | --infodi | --infod | --info | --inf)
986 ac_prev=infodir ;;
987 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
988 infodir=$ac_optarg ;;
990 -libdir | --libdir | --libdi | --libd)
991 ac_prev=libdir ;;
992 -libdir=* | --libdir=* | --libdi=* | --libd=*)
993 libdir=$ac_optarg ;;
995 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
996 | --libexe | --libex | --libe)
997 ac_prev=libexecdir ;;
998 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
999 | --libexe=* | --libex=* | --libe=*)
1000 libexecdir=$ac_optarg ;;
1002 -localedir | --localedir | --localedi | --localed | --locale)
1003 ac_prev=localedir ;;
1004 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1005 localedir=$ac_optarg ;;
1007 -localstatedir | --localstatedir | --localstatedi | --localstated \
1008 | --localstate | --localstat | --localsta | --localst | --locals)
1009 ac_prev=localstatedir ;;
1010 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1011 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1012 localstatedir=$ac_optarg ;;
1014 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1015 ac_prev=mandir ;;
1016 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1017 mandir=$ac_optarg ;;
1019 -nfp | --nfp | --nf)
1020 # Obsolete; use --without-fp.
1021 with_fp=no ;;
1023 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1024 | --no-cr | --no-c | -n)
1025 no_create=yes ;;
1027 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1028 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1029 no_recursion=yes ;;
1031 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1032 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1033 | --oldin | --oldi | --old | --ol | --o)
1034 ac_prev=oldincludedir ;;
1035 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1036 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1037 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1038 oldincludedir=$ac_optarg ;;
1040 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1041 ac_prev=prefix ;;
1042 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1043 prefix=$ac_optarg ;;
1045 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1046 | --program-pre | --program-pr | --program-p)
1047 ac_prev=program_prefix ;;
1048 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1049 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1050 program_prefix=$ac_optarg ;;
1052 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1053 | --program-suf | --program-su | --program-s)
1054 ac_prev=program_suffix ;;
1055 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1056 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1057 program_suffix=$ac_optarg ;;
1059 -program-transform-name | --program-transform-name \
1060 | --program-transform-nam | --program-transform-na \
1061 | --program-transform-n | --program-transform- \
1062 | --program-transform | --program-transfor \
1063 | --program-transfo | --program-transf \
1064 | --program-trans | --program-tran \
1065 | --progr-tra | --program-tr | --program-t)
1066 ac_prev=program_transform_name ;;
1067 -program-transform-name=* | --program-transform-name=* \
1068 | --program-transform-nam=* | --program-transform-na=* \
1069 | --program-transform-n=* | --program-transform-=* \
1070 | --program-transform=* | --program-transfor=* \
1071 | --program-transfo=* | --program-transf=* \
1072 | --program-trans=* | --program-tran=* \
1073 | --progr-tra=* | --program-tr=* | --program-t=*)
1074 program_transform_name=$ac_optarg ;;
1076 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1077 ac_prev=pdfdir ;;
1078 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1079 pdfdir=$ac_optarg ;;
1081 -psdir | --psdir | --psdi | --psd | --ps)
1082 ac_prev=psdir ;;
1083 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1084 psdir=$ac_optarg ;;
1086 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1087 | -silent | --silent | --silen | --sile | --sil)
1088 silent=yes ;;
1090 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1091 ac_prev=sbindir ;;
1092 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1093 | --sbi=* | --sb=*)
1094 sbindir=$ac_optarg ;;
1096 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1097 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1098 | --sharedst | --shareds | --shared | --share | --shar \
1099 | --sha | --sh)
1100 ac_prev=sharedstatedir ;;
1101 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1102 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1103 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1104 | --sha=* | --sh=*)
1105 sharedstatedir=$ac_optarg ;;
1107 -site | --site | --sit)
1108 ac_prev=site ;;
1109 -site=* | --site=* | --sit=*)
1110 site=$ac_optarg ;;
1112 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1113 ac_prev=srcdir ;;
1114 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1115 srcdir=$ac_optarg ;;
1117 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1118 | --syscon | --sysco | --sysc | --sys | --sy)
1119 ac_prev=sysconfdir ;;
1120 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1121 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1122 sysconfdir=$ac_optarg ;;
1124 -target | --target | --targe | --targ | --tar | --ta | --t)
1125 ac_prev=target_alias ;;
1126 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1127 target_alias=$ac_optarg ;;
1129 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1130 verbose=yes ;;
1132 -version | --version | --versio | --versi | --vers | -V)
1133 ac_init_version=: ;;
1135 -with-* | --with-*)
1136 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1137 # Reject names that are not valid shell variable names.
1138 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1139 as_fn_error $? "invalid package name: $ac_useropt"
1140 ac_useropt_orig=$ac_useropt
1141 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1142 case $ac_user_opts in
1144 "with_$ac_useropt"
1145 "*) ;;
1146 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1147 ac_unrecognized_sep=', ';;
1148 esac
1149 eval with_$ac_useropt=\$ac_optarg ;;
1151 -without-* | --without-*)
1152 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1153 # Reject names that are not valid shell variable names.
1154 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1155 as_fn_error $? "invalid package name: $ac_useropt"
1156 ac_useropt_orig=$ac_useropt
1157 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1158 case $ac_user_opts in
1160 "with_$ac_useropt"
1161 "*) ;;
1162 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1163 ac_unrecognized_sep=', ';;
1164 esac
1165 eval with_$ac_useropt=no ;;
1167 --x)
1168 # Obsolete; use --with-x.
1169 with_x=yes ;;
1171 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1172 | --x-incl | --x-inc | --x-in | --x-i)
1173 ac_prev=x_includes ;;
1174 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1175 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1176 x_includes=$ac_optarg ;;
1178 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1179 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1180 ac_prev=x_libraries ;;
1181 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1182 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1183 x_libraries=$ac_optarg ;;
1185 -*) as_fn_error $? "unrecognized option: \`$ac_option'
1186 Try \`$0 --help' for more information"
1189 *=*)
1190 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1191 # Reject names that are not valid shell variable names.
1192 case $ac_envvar in #(
1193 '' | [0-9]* | *[!_$as_cr_alnum]* )
1194 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1195 esac
1196 eval $ac_envvar=\$ac_optarg
1197 export $ac_envvar ;;
1200 # FIXME: should be removed in autoconf 3.0.
1201 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1202 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1203 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1204 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1207 esac
1208 done
1210 if test -n "$ac_prev"; then
1211 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1212 as_fn_error $? "missing argument to $ac_option"
1215 if test -n "$ac_unrecognized_opts"; then
1216 case $enable_option_checking in
1217 no) ;;
1218 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1219 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1220 esac
1223 # Check all directory arguments for consistency.
1224 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1225 datadir sysconfdir sharedstatedir localstatedir includedir \
1226 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1227 libdir localedir mandir
1229 eval ac_val=\$$ac_var
1230 # Remove trailing slashes.
1231 case $ac_val in
1232 */ )
1233 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1234 eval $ac_var=\$ac_val;;
1235 esac
1236 # Be sure to have absolute directory names.
1237 case $ac_val in
1238 [\\/$]* | ?:[\\/]* ) continue;;
1239 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1240 esac
1241 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1242 done
1244 # There might be people who depend on the old broken behavior: `$host'
1245 # used to hold the argument of --host etc.
1246 # FIXME: To remove some day.
1247 build=$build_alias
1248 host=$host_alias
1249 target=$target_alias
1251 # FIXME: To remove some day.
1252 if test "x$host_alias" != x; then
1253 if test "x$build_alias" = x; then
1254 cross_compiling=maybe
1255 elif test "x$build_alias" != "x$host_alias"; then
1256 cross_compiling=yes
1260 ac_tool_prefix=
1261 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1263 test "$silent" = yes && exec 6>/dev/null
1266 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1267 ac_ls_di=`ls -di .` &&
1268 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1269 as_fn_error $? "working directory cannot be determined"
1270 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1271 as_fn_error $? "pwd does not report name of working directory"
1274 # Find the source files, if location was not specified.
1275 if test -z "$srcdir"; then
1276 ac_srcdir_defaulted=yes
1277 # Try the directory containing this script, then the parent directory.
1278 ac_confdir=`$as_dirname -- "$as_myself" ||
1279 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1280 X"$as_myself" : 'X\(//\)[^/]' \| \
1281 X"$as_myself" : 'X\(//\)$' \| \
1282 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1283 $as_echo X"$as_myself" |
1284 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1285 s//\1/
1288 /^X\(\/\/\)[^/].*/{
1289 s//\1/
1292 /^X\(\/\/\)$/{
1293 s//\1/
1296 /^X\(\/\).*/{
1297 s//\1/
1300 s/.*/./; q'`
1301 srcdir=$ac_confdir
1302 if test ! -r "$srcdir/$ac_unique_file"; then
1303 srcdir=..
1305 else
1306 ac_srcdir_defaulted=no
1308 if test ! -r "$srcdir/$ac_unique_file"; then
1309 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1310 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1312 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1313 ac_abs_confdir=`(
1314 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1315 pwd)`
1316 # When building in place, set srcdir=.
1317 if test "$ac_abs_confdir" = "$ac_pwd"; then
1318 srcdir=.
1320 # Remove unnecessary trailing slashes from srcdir.
1321 # Double slashes in file names in object file debugging info
1322 # mess up M-x gdb in Emacs.
1323 case $srcdir in
1324 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1325 esac
1326 for ac_var in $ac_precious_vars; do
1327 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1328 eval ac_env_${ac_var}_value=\$${ac_var}
1329 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1330 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1331 done
1334 # Report the --help message.
1336 if test "$ac_init_help" = "long"; then
1337 # Omit some internal or obsolete options to make the list less imposing.
1338 # This message is too long to be a string in the A/UX 3.1 sh.
1339 cat <<_ACEOF
1340 \`configure' configures this package to adapt to many kinds of systems.
1342 Usage: $0 [OPTION]... [VAR=VALUE]...
1344 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1345 VAR=VALUE. See below for descriptions of some of the useful variables.
1347 Defaults for the options are specified in brackets.
1349 Configuration:
1350 -h, --help display this help and exit
1351 --help=short display options specific to this package
1352 --help=recursive display the short help of all the included packages
1353 -V, --version display version information and exit
1354 -q, --quiet, --silent do not print \`checking ...' messages
1355 --cache-file=FILE cache test results in FILE [disabled]
1356 -C, --config-cache alias for \`--cache-file=config.cache'
1357 -n, --no-create do not create output files
1358 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1360 Installation directories:
1361 --prefix=PREFIX install architecture-independent files in PREFIX
1362 [$ac_default_prefix]
1363 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
1364 [PREFIX]
1366 By default, \`make install' will install all the files in
1367 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1368 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1369 for instance \`--prefix=\$HOME'.
1371 For better control, use the options below.
1373 Fine tuning of the installation directories:
1374 --bindir=DIR user executables [EPREFIX/bin]
1375 --sbindir=DIR system admin executables [EPREFIX/sbin]
1376 --libexecdir=DIR program executables [EPREFIX/libexec]
1377 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1378 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1379 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1380 --libdir=DIR object code libraries [EPREFIX/lib]
1381 --includedir=DIR C header files [PREFIX/include]
1382 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1383 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1384 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1385 --infodir=DIR info documentation [DATAROOTDIR/info]
1386 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1387 --mandir=DIR man documentation [DATAROOTDIR/man]
1388 --docdir=DIR documentation root [DATAROOTDIR/doc/PACKAGE]
1389 --htmldir=DIR html documentation [DOCDIR]
1390 --dvidir=DIR dvi documentation [DOCDIR]
1391 --pdfdir=DIR pdf documentation [DOCDIR]
1392 --psdir=DIR ps documentation [DOCDIR]
1393 _ACEOF
1395 cat <<\_ACEOF
1397 Program names:
1398 --program-prefix=PREFIX prepend PREFIX to installed program names
1399 --program-suffix=SUFFIX append SUFFIX to installed program names
1400 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
1402 System types:
1403 --build=BUILD configure for building on BUILD [guessed]
1404 --host=HOST cross-compile to build programs to run on HOST [BUILD]
1405 --target=TARGET configure for building compilers for TARGET [HOST]
1406 _ACEOF
1409 if test -n "$ac_init_help"; then
1411 cat <<\_ACEOF
1413 Optional Features:
1414 --disable-option-checking ignore unrecognized --enable/--with options
1415 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1416 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
1417 --enable-maintainer-mode
1418 enable make rules and dependencies not useful (and
1419 sometimes confusing) to the casual installer
1420 --disable-largefile omit support for large files
1421 --enable-threading include support for parallel processing of data
1422 (yes/no)
1423 --disable-rpath do not hardcode runtime library paths
1424 --enable-unit-tests Enable the inclusion of unit tests when compiling
1426 --disable-nls do not use Native Language Support
1427 --enable-werror treat compile warnings as errors
1428 --enable-build-warnings enable build-time compiler warnings if gcc is used
1429 --enable-gdb-build-warnings
1430 enable GDB specific build-time compiler warnings if
1431 gcc is used
1432 --enable-inprocess-agent
1433 inprocess agent
1435 Optional Packages:
1436 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
1437 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
1438 --with-intel-pt include Intel Processor Trace support (auto/yes/no)
1439 --with-gnu-ld assume the C compiler uses GNU ld default=no
1440 --with-libipt-prefix[=DIR] search for libipt in DIR/include and DIR/lib
1441 --without-libipt-prefix don't search for libipt in includedir and libdir
1442 --with-libipt-type=TYPE type of library to search for (auto/static/shared)
1443 --with-xxhash use libxxhash for hashing (faster) (auto/yes/no)
1444 --with-libxxhash-prefix[=DIR] search for libxxhash in DIR/include and DIR/lib
1445 --without-libxxhash-prefix don't search for libxxhash in includedir and libdir
1446 --with-libxxhash-type=TYPE type of library to search for (auto/static/shared)
1447 --with-libiconv-prefix[=DIR] search for libiconv in DIR/include and DIR/lib
1448 --without-libiconv-prefix don't search for libiconv in includedir and libdir
1449 --with-libiconv-type=TYPE type of library to search for (auto/static/shared)
1450 --with-libintl-prefix[=DIR] search for libintl in DIR/include and DIR/lib
1451 --without-libintl-prefix don't search for libintl in includedir and libdir
1452 --with-libintl-type=TYPE type of library to search for (auto/static/shared)
1453 --with-ust=PATH Specify prefix directory for the installed UST package
1454 Equivalent to --with-ust-include=PATH/include
1455 plus --with-ust-lib=PATH/lib
1456 --with-ust-include=PATH Specify directory for installed UST include files
1457 --with-ust-lib=PATH Specify the directory for the installed UST library
1458 --with-pkgversion=PKG Use PKG in the version string in place of "GDB"
1459 --with-bugurl=URL Direct users to URL to report a bug
1460 --with-libthread-db=PATH
1461 use given libthread_db directly
1463 Some influential environment variables:
1464 CC C compiler command
1465 CFLAGS C compiler flags
1466 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
1467 nonstandard directory <lib dir>
1468 LIBS libraries to pass to the linker, e.g. -l<library>
1469 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
1470 you have headers in a nonstandard directory <include dir>
1471 CXX C++ compiler command
1472 CXXFLAGS C++ compiler flags
1473 CPP C preprocessor
1475 Use these variables to override the choices made by `configure' or to help
1476 it to find libraries and programs with nonstandard names/locations.
1478 Report bugs to the package provider.
1479 _ACEOF
1480 ac_status=$?
1483 if test "$ac_init_help" = "recursive"; then
1484 # If there are subdirs, report their specific --help.
1485 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1486 test -d "$ac_dir" ||
1487 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1488 continue
1489 ac_builddir=.
1491 case "$ac_dir" in
1492 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1494 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1495 # A ".." for each directory in $ac_dir_suffix.
1496 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1497 case $ac_top_builddir_sub in
1498 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1499 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1500 esac ;;
1501 esac
1502 ac_abs_top_builddir=$ac_pwd
1503 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1504 # for backward compatibility:
1505 ac_top_builddir=$ac_top_build_prefix
1507 case $srcdir in
1508 .) # We are building in place.
1509 ac_srcdir=.
1510 ac_top_srcdir=$ac_top_builddir_sub
1511 ac_abs_top_srcdir=$ac_pwd ;;
1512 [\\/]* | ?:[\\/]* ) # Absolute name.
1513 ac_srcdir=$srcdir$ac_dir_suffix;
1514 ac_top_srcdir=$srcdir
1515 ac_abs_top_srcdir=$srcdir ;;
1516 *) # Relative name.
1517 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1518 ac_top_srcdir=$ac_top_build_prefix$srcdir
1519 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1520 esac
1521 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1523 cd "$ac_dir" || { ac_status=$?; continue; }
1524 # Check for guested configure.
1525 if test -f "$ac_srcdir/configure.gnu"; then
1526 echo &&
1527 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1528 elif test -f "$ac_srcdir/configure"; then
1529 echo &&
1530 $SHELL "$ac_srcdir/configure" --help=recursive
1531 else
1532 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1533 fi || ac_status=$?
1534 cd "$ac_pwd" || { ac_status=$?; break; }
1535 done
1538 test -n "$ac_init_help" && exit $ac_status
1539 if $ac_init_version; then
1540 cat <<\_ACEOF
1541 configure
1542 generated by GNU Autoconf 2.69
1544 Copyright (C) 2012 Free Software Foundation, Inc.
1545 This configure script is free software; the Free Software Foundation
1546 gives unlimited permission to copy, distribute and modify it.
1547 _ACEOF
1548 exit
1551 ## ------------------------ ##
1552 ## Autoconf initialization. ##
1553 ## ------------------------ ##
1555 # ac_fn_c_try_compile LINENO
1556 # --------------------------
1557 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1558 ac_fn_c_try_compile ()
1560 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1561 rm -f conftest.$ac_objext
1562 if { { ac_try="$ac_compile"
1563 case "(($ac_try" in
1564 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1565 *) ac_try_echo=$ac_try;;
1566 esac
1567 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1568 $as_echo "$ac_try_echo"; } >&5
1569 (eval "$ac_compile") 2>conftest.err
1570 ac_status=$?
1571 if test -s conftest.err; then
1572 grep -v '^ *+' conftest.err >conftest.er1
1573 cat conftest.er1 >&5
1574 mv -f conftest.er1 conftest.err
1576 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1577 test $ac_status = 0; } && {
1578 test -z "$ac_c_werror_flag" ||
1579 test ! -s conftest.err
1580 } && test -s conftest.$ac_objext; then :
1581 ac_retval=0
1582 else
1583 $as_echo "$as_me: failed program was:" >&5
1584 sed 's/^/| /' conftest.$ac_ext >&5
1586 ac_retval=1
1588 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1589 as_fn_set_status $ac_retval
1591 } # ac_fn_c_try_compile
1593 # ac_fn_cxx_try_compile LINENO
1594 # ----------------------------
1595 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1596 ac_fn_cxx_try_compile ()
1598 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1599 rm -f conftest.$ac_objext
1600 if { { ac_try="$ac_compile"
1601 case "(($ac_try" in
1602 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1603 *) ac_try_echo=$ac_try;;
1604 esac
1605 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1606 $as_echo "$ac_try_echo"; } >&5
1607 (eval "$ac_compile") 2>conftest.err
1608 ac_status=$?
1609 if test -s conftest.err; then
1610 grep -v '^ *+' conftest.err >conftest.er1
1611 cat conftest.er1 >&5
1612 mv -f conftest.er1 conftest.err
1614 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1615 test $ac_status = 0; } && {
1616 test -z "$ac_cxx_werror_flag" ||
1617 test ! -s conftest.err
1618 } && test -s conftest.$ac_objext; then :
1619 ac_retval=0
1620 else
1621 $as_echo "$as_me: failed program was:" >&5
1622 sed 's/^/| /' conftest.$ac_ext >&5
1624 ac_retval=1
1626 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1627 as_fn_set_status $ac_retval
1629 } # ac_fn_cxx_try_compile
1631 # ac_fn_c_try_cpp LINENO
1632 # ----------------------
1633 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1634 ac_fn_c_try_cpp ()
1636 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1637 if { { ac_try="$ac_cpp conftest.$ac_ext"
1638 case "(($ac_try" in
1639 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1640 *) ac_try_echo=$ac_try;;
1641 esac
1642 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1643 $as_echo "$ac_try_echo"; } >&5
1644 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1645 ac_status=$?
1646 if test -s conftest.err; then
1647 grep -v '^ *+' conftest.err >conftest.er1
1648 cat conftest.er1 >&5
1649 mv -f conftest.er1 conftest.err
1651 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1652 test $ac_status = 0; } > conftest.i && {
1653 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1654 test ! -s conftest.err
1655 }; then :
1656 ac_retval=0
1657 else
1658 $as_echo "$as_me: failed program was:" >&5
1659 sed 's/^/| /' conftest.$ac_ext >&5
1661 ac_retval=1
1663 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1664 as_fn_set_status $ac_retval
1666 } # ac_fn_c_try_cpp
1668 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
1669 # -------------------------------------------------------
1670 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
1671 # the include files in INCLUDES and setting the cache variable VAR
1672 # accordingly.
1673 ac_fn_c_check_header_mongrel ()
1675 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1676 if eval \${$3+:} false; then :
1677 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1678 $as_echo_n "checking for $2... " >&6; }
1679 if eval \${$3+:} false; then :
1680 $as_echo_n "(cached) " >&6
1682 eval ac_res=\$$3
1683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1684 $as_echo "$ac_res" >&6; }
1685 else
1686 # Is the header compilable?
1687 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
1688 $as_echo_n "checking $2 usability... " >&6; }
1689 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1690 /* end confdefs.h. */
1692 #include <$2>
1693 _ACEOF
1694 if ac_fn_c_try_compile "$LINENO"; then :
1695 ac_header_compiler=yes
1696 else
1697 ac_header_compiler=no
1699 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1700 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
1701 $as_echo "$ac_header_compiler" >&6; }
1703 # Is the header present?
1704 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
1705 $as_echo_n "checking $2 presence... " >&6; }
1706 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1707 /* end confdefs.h. */
1708 #include <$2>
1709 _ACEOF
1710 if ac_fn_c_try_cpp "$LINENO"; then :
1711 ac_header_preproc=yes
1712 else
1713 ac_header_preproc=no
1715 rm -f conftest.err conftest.i conftest.$ac_ext
1716 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
1717 $as_echo "$ac_header_preproc" >&6; }
1719 # So? What about this header?
1720 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
1721 yes:no: )
1722 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
1723 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
1724 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1725 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1727 no:yes:* )
1728 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
1729 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
1730 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
1731 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
1732 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
1733 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
1734 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
1735 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
1736 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1737 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1739 esac
1740 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1741 $as_echo_n "checking for $2... " >&6; }
1742 if eval \${$3+:} false; then :
1743 $as_echo_n "(cached) " >&6
1744 else
1745 eval "$3=\$ac_header_compiler"
1747 eval ac_res=\$$3
1748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1749 $as_echo "$ac_res" >&6; }
1751 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1753 } # ac_fn_c_check_header_mongrel
1755 # ac_fn_c_try_run LINENO
1756 # ----------------------
1757 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
1758 # that executables *can* be run.
1759 ac_fn_c_try_run ()
1761 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1762 if { { ac_try="$ac_link"
1763 case "(($ac_try" in
1764 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1765 *) ac_try_echo=$ac_try;;
1766 esac
1767 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1768 $as_echo "$ac_try_echo"; } >&5
1769 (eval "$ac_link") 2>&5
1770 ac_status=$?
1771 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1772 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1773 { { case "(($ac_try" in
1774 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1775 *) ac_try_echo=$ac_try;;
1776 esac
1777 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1778 $as_echo "$ac_try_echo"; } >&5
1779 (eval "$ac_try") 2>&5
1780 ac_status=$?
1781 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1782 test $ac_status = 0; }; }; then :
1783 ac_retval=0
1784 else
1785 $as_echo "$as_me: program exited with status $ac_status" >&5
1786 $as_echo "$as_me: failed program was:" >&5
1787 sed 's/^/| /' conftest.$ac_ext >&5
1789 ac_retval=$ac_status
1791 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1792 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1793 as_fn_set_status $ac_retval
1795 } # ac_fn_c_try_run
1797 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
1798 # -------------------------------------------------------
1799 # Tests whether HEADER exists and can be compiled using the include files in
1800 # INCLUDES, setting the cache variable VAR accordingly.
1801 ac_fn_c_check_header_compile ()
1803 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1804 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1805 $as_echo_n "checking for $2... " >&6; }
1806 if eval \${$3+:} false; then :
1807 $as_echo_n "(cached) " >&6
1808 else
1809 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1810 /* end confdefs.h. */
1812 #include <$2>
1813 _ACEOF
1814 if ac_fn_c_try_compile "$LINENO"; then :
1815 eval "$3=yes"
1816 else
1817 eval "$3=no"
1819 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1821 eval ac_res=\$$3
1822 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1823 $as_echo "$ac_res" >&6; }
1824 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1826 } # ac_fn_c_check_header_compile
1828 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
1829 # -------------------------------------------
1830 # Tests whether TYPE exists after having included INCLUDES, setting cache
1831 # variable VAR accordingly.
1832 ac_fn_c_check_type ()
1834 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1835 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1836 $as_echo_n "checking for $2... " >&6; }
1837 if eval \${$3+:} false; then :
1838 $as_echo_n "(cached) " >&6
1839 else
1840 eval "$3=no"
1841 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1842 /* end confdefs.h. */
1845 main ()
1847 if (sizeof ($2))
1848 return 0;
1850 return 0;
1852 _ACEOF
1853 if ac_fn_c_try_compile "$LINENO"; then :
1854 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1855 /* end confdefs.h. */
1858 main ()
1860 if (sizeof (($2)))
1861 return 0;
1863 return 0;
1865 _ACEOF
1866 if ac_fn_c_try_compile "$LINENO"; then :
1868 else
1869 eval "$3=yes"
1871 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1873 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1875 eval ac_res=\$$3
1876 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1877 $as_echo "$ac_res" >&6; }
1878 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1880 } # ac_fn_c_check_type
1882 # ac_fn_c_try_link LINENO
1883 # -----------------------
1884 # Try to link conftest.$ac_ext, and return whether this succeeded.
1885 ac_fn_c_try_link ()
1887 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1888 rm -f conftest.$ac_objext conftest$ac_exeext
1889 if { { ac_try="$ac_link"
1890 case "(($ac_try" in
1891 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1892 *) ac_try_echo=$ac_try;;
1893 esac
1894 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1895 $as_echo "$ac_try_echo"; } >&5
1896 (eval "$ac_link") 2>conftest.err
1897 ac_status=$?
1898 if test -s conftest.err; then
1899 grep -v '^ *+' conftest.err >conftest.er1
1900 cat conftest.er1 >&5
1901 mv -f conftest.er1 conftest.err
1903 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1904 test $ac_status = 0; } && {
1905 test -z "$ac_c_werror_flag" ||
1906 test ! -s conftest.err
1907 } && test -s conftest$ac_exeext && {
1908 test "$cross_compiling" = yes ||
1909 test -x conftest$ac_exeext
1910 }; then :
1911 ac_retval=0
1912 else
1913 $as_echo "$as_me: failed program was:" >&5
1914 sed 's/^/| /' conftest.$ac_ext >&5
1916 ac_retval=1
1918 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
1919 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
1920 # interfere with the next link command; also delete a directory that is
1921 # left behind by Apple's compiler. We do this before executing the actions.
1922 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1923 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1924 as_fn_set_status $ac_retval
1926 } # ac_fn_c_try_link
1928 # ac_fn_c_check_func LINENO FUNC VAR
1929 # ----------------------------------
1930 # Tests whether FUNC exists, setting the cache variable VAR accordingly
1931 ac_fn_c_check_func ()
1933 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1934 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1935 $as_echo_n "checking for $2... " >&6; }
1936 if eval \${$3+:} false; then :
1937 $as_echo_n "(cached) " >&6
1938 else
1939 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1940 /* end confdefs.h. */
1941 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
1942 For example, HP-UX 11i <limits.h> declares gettimeofday. */
1943 #define $2 innocuous_$2
1945 /* System header to define __stub macros and hopefully few prototypes,
1946 which can conflict with char $2 (); below.
1947 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
1948 <limits.h> exists even on freestanding compilers. */
1950 #ifdef __STDC__
1951 # include <limits.h>
1952 #else
1953 # include <assert.h>
1954 #endif
1956 #undef $2
1958 /* Override any GCC internal prototype to avoid an error.
1959 Use char because int might match the return type of a GCC
1960 builtin and then its argument prototype would still apply. */
1961 #ifdef __cplusplus
1962 extern "C"
1963 #endif
1964 char $2 ();
1965 /* The GNU C library defines this for functions which it implements
1966 to always fail with ENOSYS. Some functions are actually named
1967 something starting with __ and the normal name is an alias. */
1968 #if defined __stub_$2 || defined __stub___$2
1969 choke me
1970 #endif
1973 main ()
1975 return $2 ();
1977 return 0;
1979 _ACEOF
1980 if ac_fn_c_try_link "$LINENO"; then :
1981 eval "$3=yes"
1982 else
1983 eval "$3=no"
1985 rm -f core conftest.err conftest.$ac_objext \
1986 conftest$ac_exeext conftest.$ac_ext
1988 eval ac_res=\$$3
1989 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1990 $as_echo "$ac_res" >&6; }
1991 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1993 } # ac_fn_c_check_func
1995 # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
1996 # ---------------------------------------------
1997 # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
1998 # accordingly.
1999 ac_fn_c_check_decl ()
2001 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2002 as_decl_name=`echo $2|sed 's/ *(.*//'`
2003 as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
2004 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
2005 $as_echo_n "checking whether $as_decl_name is declared... " >&6; }
2006 if eval \${$3+:} false; then :
2007 $as_echo_n "(cached) " >&6
2008 else
2009 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2010 /* end confdefs.h. */
2013 main ()
2015 #ifndef $as_decl_name
2016 #ifdef __cplusplus
2017 (void) $as_decl_use;
2018 #else
2019 (void) $as_decl_name;
2020 #endif
2021 #endif
2024 return 0;
2026 _ACEOF
2027 if ac_fn_c_try_compile "$LINENO"; then :
2028 eval "$3=yes"
2029 else
2030 eval "$3=no"
2032 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2034 eval ac_res=\$$3
2035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2036 $as_echo "$ac_res" >&6; }
2037 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2039 } # ac_fn_c_check_decl
2041 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2042 # ----------------------------------------------------
2043 # Tries to find if the field MEMBER exists in type AGGR, after including
2044 # INCLUDES, setting cache variable VAR accordingly.
2045 ac_fn_c_check_member ()
2047 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2048 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2049 $as_echo_n "checking for $2.$3... " >&6; }
2050 if eval \${$4+:} false; then :
2051 $as_echo_n "(cached) " >&6
2052 else
2053 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2054 /* end confdefs.h. */
2057 main ()
2059 static $2 ac_aggr;
2060 if (ac_aggr.$3)
2061 return 0;
2063 return 0;
2065 _ACEOF
2066 if ac_fn_c_try_compile "$LINENO"; then :
2067 eval "$4=yes"
2068 else
2069 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2070 /* end confdefs.h. */
2073 main ()
2075 static $2 ac_aggr;
2076 if (sizeof ac_aggr.$3)
2077 return 0;
2079 return 0;
2081 _ACEOF
2082 if ac_fn_c_try_compile "$LINENO"; then :
2083 eval "$4=yes"
2084 else
2085 eval "$4=no"
2087 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2089 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2091 eval ac_res=\$$4
2092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2093 $as_echo "$ac_res" >&6; }
2094 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2096 } # ac_fn_c_check_member
2098 # ac_fn_cxx_try_link LINENO
2099 # -------------------------
2100 # Try to link conftest.$ac_ext, and return whether this succeeded.
2101 ac_fn_cxx_try_link ()
2103 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2104 rm -f conftest.$ac_objext conftest$ac_exeext
2105 if { { ac_try="$ac_link"
2106 case "(($ac_try" in
2107 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2108 *) ac_try_echo=$ac_try;;
2109 esac
2110 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2111 $as_echo "$ac_try_echo"; } >&5
2112 (eval "$ac_link") 2>conftest.err
2113 ac_status=$?
2114 if test -s conftest.err; then
2115 grep -v '^ *+' conftest.err >conftest.er1
2116 cat conftest.er1 >&5
2117 mv -f conftest.er1 conftest.err
2119 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2120 test $ac_status = 0; } && {
2121 test -z "$ac_cxx_werror_flag" ||
2122 test ! -s conftest.err
2123 } && test -s conftest$ac_exeext && {
2124 test "$cross_compiling" = yes ||
2125 test -x conftest$ac_exeext
2126 }; then :
2127 ac_retval=0
2128 else
2129 $as_echo "$as_me: failed program was:" >&5
2130 sed 's/^/| /' conftest.$ac_ext >&5
2132 ac_retval=1
2134 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2135 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2136 # interfere with the next link command; also delete a directory that is
2137 # left behind by Apple's compiler. We do this before executing the actions.
2138 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2139 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2140 as_fn_set_status $ac_retval
2142 } # ac_fn_cxx_try_link
2144 # ac_fn_cxx_check_func LINENO FUNC VAR
2145 # ------------------------------------
2146 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2147 ac_fn_cxx_check_func ()
2149 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2150 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2151 $as_echo_n "checking for $2... " >&6; }
2152 if eval \${$3+:} false; then :
2153 $as_echo_n "(cached) " >&6
2154 else
2155 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2156 /* end confdefs.h. */
2157 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2158 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2159 #define $2 innocuous_$2
2161 /* System header to define __stub macros and hopefully few prototypes,
2162 which can conflict with char $2 (); below.
2163 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2164 <limits.h> exists even on freestanding compilers. */
2166 #ifdef __STDC__
2167 # include <limits.h>
2168 #else
2169 # include <assert.h>
2170 #endif
2172 #undef $2
2174 /* Override any GCC internal prototype to avoid an error.
2175 Use char because int might match the return type of a GCC
2176 builtin and then its argument prototype would still apply. */
2177 #ifdef __cplusplus
2178 extern "C"
2179 #endif
2180 char $2 ();
2181 /* The GNU C library defines this for functions which it implements
2182 to always fail with ENOSYS. Some functions are actually named
2183 something starting with __ and the normal name is an alias. */
2184 #if defined __stub_$2 || defined __stub___$2
2185 choke me
2186 #endif
2189 main ()
2191 return $2 ();
2193 return 0;
2195 _ACEOF
2196 if ac_fn_cxx_try_link "$LINENO"; then :
2197 eval "$3=yes"
2198 else
2199 eval "$3=no"
2201 rm -f core conftest.err conftest.$ac_objext \
2202 conftest$ac_exeext conftest.$ac_ext
2204 eval ac_res=\$$3
2205 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2206 $as_echo "$ac_res" >&6; }
2207 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2209 } # ac_fn_cxx_check_func
2211 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2212 # --------------------------------------------
2213 # Tries to find the compile-time value of EXPR in a program that includes
2214 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2215 # computed
2216 ac_fn_c_compute_int ()
2218 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2219 if test "$cross_compiling" = yes; then
2220 # Depending upon the size, compute the lo and hi bounds.
2221 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2222 /* end confdefs.h. */
2225 main ()
2227 static int test_array [1 - 2 * !(($2) >= 0)];
2228 test_array [0] = 0;
2229 return test_array [0];
2232 return 0;
2234 _ACEOF
2235 if ac_fn_c_try_compile "$LINENO"; then :
2236 ac_lo=0 ac_mid=0
2237 while :; do
2238 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2239 /* end confdefs.h. */
2242 main ()
2244 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2245 test_array [0] = 0;
2246 return test_array [0];
2249 return 0;
2251 _ACEOF
2252 if ac_fn_c_try_compile "$LINENO"; then :
2253 ac_hi=$ac_mid; break
2254 else
2255 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2256 if test $ac_lo -le $ac_mid; then
2257 ac_lo= ac_hi=
2258 break
2260 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2262 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2263 done
2264 else
2265 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2266 /* end confdefs.h. */
2269 main ()
2271 static int test_array [1 - 2 * !(($2) < 0)];
2272 test_array [0] = 0;
2273 return test_array [0];
2276 return 0;
2278 _ACEOF
2279 if ac_fn_c_try_compile "$LINENO"; then :
2280 ac_hi=-1 ac_mid=-1
2281 while :; do
2282 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2283 /* end confdefs.h. */
2286 main ()
2288 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2289 test_array [0] = 0;
2290 return test_array [0];
2293 return 0;
2295 _ACEOF
2296 if ac_fn_c_try_compile "$LINENO"; then :
2297 ac_lo=$ac_mid; break
2298 else
2299 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2300 if test $ac_mid -le $ac_hi; then
2301 ac_lo= ac_hi=
2302 break
2304 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2306 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2307 done
2308 else
2309 ac_lo= ac_hi=
2311 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2313 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2314 # Binary search between lo and hi bounds.
2315 while test "x$ac_lo" != "x$ac_hi"; do
2316 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2317 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2318 /* end confdefs.h. */
2321 main ()
2323 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2324 test_array [0] = 0;
2325 return test_array [0];
2328 return 0;
2330 _ACEOF
2331 if ac_fn_c_try_compile "$LINENO"; then :
2332 ac_hi=$ac_mid
2333 else
2334 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2336 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2337 done
2338 case $ac_lo in #((
2339 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2340 '') ac_retval=1 ;;
2341 esac
2342 else
2343 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2344 /* end confdefs.h. */
2346 static long int longval () { return $2; }
2347 static unsigned long int ulongval () { return $2; }
2348 #include <stdio.h>
2349 #include <stdlib.h>
2351 main ()
2354 FILE *f = fopen ("conftest.val", "w");
2355 if (! f)
2356 return 1;
2357 if (($2) < 0)
2359 long int i = longval ();
2360 if (i != ($2))
2361 return 1;
2362 fprintf (f, "%ld", i);
2364 else
2366 unsigned long int i = ulongval ();
2367 if (i != ($2))
2368 return 1;
2369 fprintf (f, "%lu", i);
2371 /* Do not output a trailing newline, as this causes \r\n confusion
2372 on some platforms. */
2373 return ferror (f) || fclose (f) != 0;
2376 return 0;
2378 _ACEOF
2379 if ac_fn_c_try_run "$LINENO"; then :
2380 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2381 else
2382 ac_retval=1
2384 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2385 conftest.$ac_objext conftest.beam conftest.$ac_ext
2386 rm -f conftest.val
2389 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2390 as_fn_set_status $ac_retval
2392 } # ac_fn_c_compute_int
2393 cat >config.log <<_ACEOF
2394 This file contains any messages produced by compilers while
2395 running configure, to aid debugging if configure makes a mistake.
2397 It was created by $as_me, which was
2398 generated by GNU Autoconf 2.69. Invocation command line was
2400 $ $0 $@
2402 _ACEOF
2403 exec 5>>config.log
2405 cat <<_ASUNAME
2406 ## --------- ##
2407 ## Platform. ##
2408 ## --------- ##
2410 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2411 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2412 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2413 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2414 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2416 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2417 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
2419 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2420 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2421 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2422 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2423 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2424 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2425 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
2427 _ASUNAME
2429 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2430 for as_dir in $PATH
2432 IFS=$as_save_IFS
2433 test -z "$as_dir" && as_dir=.
2434 $as_echo "PATH: $as_dir"
2435 done
2436 IFS=$as_save_IFS
2438 } >&5
2440 cat >&5 <<_ACEOF
2443 ## ----------- ##
2444 ## Core tests. ##
2445 ## ----------- ##
2447 _ACEOF
2450 # Keep a trace of the command line.
2451 # Strip out --no-create and --no-recursion so they do not pile up.
2452 # Strip out --silent because we don't want to record it for future runs.
2453 # Also quote any args containing shell meta-characters.
2454 # Make two passes to allow for proper duplicate-argument suppression.
2455 ac_configure_args=
2456 ac_configure_args0=
2457 ac_configure_args1=
2458 ac_must_keep_next=false
2459 for ac_pass in 1 2
2461 for ac_arg
2463 case $ac_arg in
2464 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2465 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2466 | -silent | --silent | --silen | --sile | --sil)
2467 continue ;;
2468 *\'*)
2469 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2470 esac
2471 case $ac_pass in
2472 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2474 as_fn_append ac_configure_args1 " '$ac_arg'"
2475 if test $ac_must_keep_next = true; then
2476 ac_must_keep_next=false # Got value, back to normal.
2477 else
2478 case $ac_arg in
2479 *=* | --config-cache | -C | -disable-* | --disable-* \
2480 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2481 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2482 | -with-* | --with-* | -without-* | --without-* | --x)
2483 case "$ac_configure_args0 " in
2484 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2485 esac
2487 -* ) ac_must_keep_next=true ;;
2488 esac
2490 as_fn_append ac_configure_args " '$ac_arg'"
2492 esac
2493 done
2494 done
2495 { ac_configure_args0=; unset ac_configure_args0;}
2496 { ac_configure_args1=; unset ac_configure_args1;}
2498 # When interrupted or exit'd, cleanup temporary files, and complete
2499 # config.log. We remove comments because anyway the quotes in there
2500 # would cause problems or look ugly.
2501 # WARNING: Use '\'' to represent an apostrophe within the trap.
2502 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2503 trap 'exit_status=$?
2504 # Save into config.log some information that might help in debugging.
2506 echo
2508 $as_echo "## ---------------- ##
2509 ## Cache variables. ##
2510 ## ---------------- ##"
2511 echo
2512 # The following way of writing the cache mishandles newlines in values,
2514 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2515 eval ac_val=\$$ac_var
2516 case $ac_val in #(
2517 *${as_nl}*)
2518 case $ac_var in #(
2519 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2520 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2521 esac
2522 case $ac_var in #(
2523 _ | IFS | as_nl) ;; #(
2524 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2525 *) { eval $ac_var=; unset $ac_var;} ;;
2526 esac ;;
2527 esac
2528 done
2529 (set) 2>&1 |
2530 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2531 *${as_nl}ac_space=\ *)
2532 sed -n \
2533 "s/'\''/'\''\\\\'\'''\''/g;
2534 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2535 ;; #(
2537 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2539 esac |
2540 sort
2542 echo
2544 $as_echo "## ----------------- ##
2545 ## Output variables. ##
2546 ## ----------------- ##"
2547 echo
2548 for ac_var in $ac_subst_vars
2550 eval ac_val=\$$ac_var
2551 case $ac_val in
2552 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2553 esac
2554 $as_echo "$ac_var='\''$ac_val'\''"
2555 done | sort
2556 echo
2558 if test -n "$ac_subst_files"; then
2559 $as_echo "## ------------------- ##
2560 ## File substitutions. ##
2561 ## ------------------- ##"
2562 echo
2563 for ac_var in $ac_subst_files
2565 eval ac_val=\$$ac_var
2566 case $ac_val in
2567 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2568 esac
2569 $as_echo "$ac_var='\''$ac_val'\''"
2570 done | sort
2571 echo
2574 if test -s confdefs.h; then
2575 $as_echo "## ----------- ##
2576 ## confdefs.h. ##
2577 ## ----------- ##"
2578 echo
2579 cat confdefs.h
2580 echo
2582 test "$ac_signal" != 0 &&
2583 $as_echo "$as_me: caught signal $ac_signal"
2584 $as_echo "$as_me: exit $exit_status"
2585 } >&5
2586 rm -f core *.core core.conftest.* &&
2587 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2588 exit $exit_status
2590 for ac_signal in 1 2 13 15; do
2591 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2592 done
2593 ac_signal=0
2595 # confdefs.h avoids OS command line length limits that DEFS can exceed.
2596 rm -f -r conftest* confdefs.h
2598 $as_echo "/* confdefs.h */" > confdefs.h
2600 # Predefined preprocessor variables.
2602 cat >>confdefs.h <<_ACEOF
2603 #define PACKAGE_NAME "$PACKAGE_NAME"
2604 _ACEOF
2606 cat >>confdefs.h <<_ACEOF
2607 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2608 _ACEOF
2610 cat >>confdefs.h <<_ACEOF
2611 #define PACKAGE_VERSION "$PACKAGE_VERSION"
2612 _ACEOF
2614 cat >>confdefs.h <<_ACEOF
2615 #define PACKAGE_STRING "$PACKAGE_STRING"
2616 _ACEOF
2618 cat >>confdefs.h <<_ACEOF
2619 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2620 _ACEOF
2622 cat >>confdefs.h <<_ACEOF
2623 #define PACKAGE_URL "$PACKAGE_URL"
2624 _ACEOF
2627 # Let the site file select an alternate cache file if it wants to.
2628 # Prefer an explicitly selected file to automatically selected ones.
2629 ac_site_file1=NONE
2630 ac_site_file2=NONE
2631 if test -n "$CONFIG_SITE"; then
2632 # We do not want a PATH search for config.site.
2633 case $CONFIG_SITE in #((
2634 -*) ac_site_file1=./$CONFIG_SITE;;
2635 */*) ac_site_file1=$CONFIG_SITE;;
2636 *) ac_site_file1=./$CONFIG_SITE;;
2637 esac
2638 elif test "x$prefix" != xNONE; then
2639 ac_site_file1=$prefix/share/config.site
2640 ac_site_file2=$prefix/etc/config.site
2641 else
2642 ac_site_file1=$ac_default_prefix/share/config.site
2643 ac_site_file2=$ac_default_prefix/etc/config.site
2645 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2647 test "x$ac_site_file" = xNONE && continue
2648 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
2649 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2650 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
2651 sed 's/^/| /' "$ac_site_file" >&5
2652 . "$ac_site_file" \
2653 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2654 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2655 as_fn_error $? "failed to load site script $ac_site_file
2656 See \`config.log' for more details" "$LINENO" 5; }
2658 done
2660 if test -r "$cache_file"; then
2661 # Some versions of bash will fail to source /dev/null (special files
2662 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
2663 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2664 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2665 $as_echo "$as_me: loading cache $cache_file" >&6;}
2666 case $cache_file in
2667 [\\/]* | ?:[\\/]* ) . "$cache_file";;
2668 *) . "./$cache_file";;
2669 esac
2671 else
2672 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2673 $as_echo "$as_me: creating cache $cache_file" >&6;}
2674 >$cache_file
2677 as_fn_append ac_header_list " stdlib.h"
2678 as_fn_append ac_header_list " unistd.h"
2679 as_fn_append ac_header_list " sys/param.h"
2680 gt_needs="$gt_needs "
2681 # Check that the precious variables saved in the cache have kept the same
2682 # value.
2683 ac_cache_corrupted=false
2684 for ac_var in $ac_precious_vars; do
2685 eval ac_old_set=\$ac_cv_env_${ac_var}_set
2686 eval ac_new_set=\$ac_env_${ac_var}_set
2687 eval ac_old_val=\$ac_cv_env_${ac_var}_value
2688 eval ac_new_val=\$ac_env_${ac_var}_value
2689 case $ac_old_set,$ac_new_set in
2690 set,)
2691 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2692 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2693 ac_cache_corrupted=: ;;
2694 ,set)
2695 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2696 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2697 ac_cache_corrupted=: ;;
2698 ,);;
2700 if test "x$ac_old_val" != "x$ac_new_val"; then
2701 # differences in whitespace do not lead to failure.
2702 ac_old_val_w=`echo x $ac_old_val`
2703 ac_new_val_w=`echo x $ac_new_val`
2704 if test "$ac_old_val_w" != "$ac_new_val_w"; then
2705 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2706 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2707 ac_cache_corrupted=:
2708 else
2709 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2710 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2711 eval $ac_var=\$ac_old_val
2713 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
2714 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
2715 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
2716 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
2717 fi;;
2718 esac
2719 # Pass precious variables to config.status.
2720 if test "$ac_new_set" = set; then
2721 case $ac_new_val in
2722 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2723 *) ac_arg=$ac_var=$ac_new_val ;;
2724 esac
2725 case " $ac_configure_args " in
2726 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
2727 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2728 esac
2730 done
2731 if $ac_cache_corrupted; then
2732 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2733 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2734 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2735 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2736 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
2738 ## -------------------- ##
2739 ## Main body of script. ##
2740 ## -------------------- ##
2742 ac_ext=c
2743 ac_cpp='$CPP $CPPFLAGS'
2744 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2745 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2746 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2754 ac_config_headers="$ac_config_headers config.h:config.in"
2758 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5
2759 $as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
2760 # Check whether --enable-maintainer-mode was given.
2761 if test "${enable_maintainer_mode+set}" = set; then :
2762 enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
2763 else
2764 USE_MAINTAINER_MODE=no
2767 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5
2768 $as_echo "$USE_MAINTAINER_MODE" >&6; }
2769 if test $USE_MAINTAINER_MODE = yes; then
2770 MAINTAINER_MODE_TRUE=
2771 MAINTAINER_MODE_FALSE='#'
2772 else
2773 MAINTAINER_MODE_TRUE='#'
2774 MAINTAINER_MODE_FALSE=
2777 MAINT=$MAINTAINER_MODE_TRUE
2781 ac_ext=c
2782 ac_cpp='$CPP $CPPFLAGS'
2783 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2784 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2785 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2786 if test -n "$ac_tool_prefix"; then
2787 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
2788 set dummy ${ac_tool_prefix}gcc; ac_word=$2
2789 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2790 $as_echo_n "checking for $ac_word... " >&6; }
2791 if ${ac_cv_prog_CC+:} false; then :
2792 $as_echo_n "(cached) " >&6
2793 else
2794 if test -n "$CC"; then
2795 ac_cv_prog_CC="$CC" # Let the user override the test.
2796 else
2797 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2798 for as_dir in $PATH
2800 IFS=$as_save_IFS
2801 test -z "$as_dir" && as_dir=.
2802 for ac_exec_ext in '' $ac_executable_extensions; do
2803 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2804 ac_cv_prog_CC="${ac_tool_prefix}gcc"
2805 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2806 break 2
2808 done
2809 done
2810 IFS=$as_save_IFS
2814 CC=$ac_cv_prog_CC
2815 if test -n "$CC"; then
2816 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2817 $as_echo "$CC" >&6; }
2818 else
2819 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2820 $as_echo "no" >&6; }
2825 if test -z "$ac_cv_prog_CC"; then
2826 ac_ct_CC=$CC
2827 # Extract the first word of "gcc", so it can be a program name with args.
2828 set dummy gcc; ac_word=$2
2829 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2830 $as_echo_n "checking for $ac_word... " >&6; }
2831 if ${ac_cv_prog_ac_ct_CC+:} false; then :
2832 $as_echo_n "(cached) " >&6
2833 else
2834 if test -n "$ac_ct_CC"; then
2835 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2836 else
2837 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2838 for as_dir in $PATH
2840 IFS=$as_save_IFS
2841 test -z "$as_dir" && as_dir=.
2842 for ac_exec_ext in '' $ac_executable_extensions; do
2843 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2844 ac_cv_prog_ac_ct_CC="gcc"
2845 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2846 break 2
2848 done
2849 done
2850 IFS=$as_save_IFS
2854 ac_ct_CC=$ac_cv_prog_ac_ct_CC
2855 if test -n "$ac_ct_CC"; then
2856 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
2857 $as_echo "$ac_ct_CC" >&6; }
2858 else
2859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2860 $as_echo "no" >&6; }
2863 if test "x$ac_ct_CC" = x; then
2864 CC=""
2865 else
2866 case $cross_compiling:$ac_tool_warned in
2867 yes:)
2868 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
2869 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
2870 ac_tool_warned=yes ;;
2871 esac
2872 CC=$ac_ct_CC
2874 else
2875 CC="$ac_cv_prog_CC"
2878 if test -z "$CC"; then
2879 if test -n "$ac_tool_prefix"; then
2880 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
2881 set dummy ${ac_tool_prefix}cc; ac_word=$2
2882 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2883 $as_echo_n "checking for $ac_word... " >&6; }
2884 if ${ac_cv_prog_CC+:} false; then :
2885 $as_echo_n "(cached) " >&6
2886 else
2887 if test -n "$CC"; then
2888 ac_cv_prog_CC="$CC" # Let the user override the test.
2889 else
2890 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2891 for as_dir in $PATH
2893 IFS=$as_save_IFS
2894 test -z "$as_dir" && as_dir=.
2895 for ac_exec_ext in '' $ac_executable_extensions; do
2896 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2897 ac_cv_prog_CC="${ac_tool_prefix}cc"
2898 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2899 break 2
2901 done
2902 done
2903 IFS=$as_save_IFS
2907 CC=$ac_cv_prog_CC
2908 if test -n "$CC"; then
2909 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2910 $as_echo "$CC" >&6; }
2911 else
2912 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2913 $as_echo "no" >&6; }
2919 if test -z "$CC"; then
2920 # Extract the first word of "cc", so it can be a program name with args.
2921 set dummy cc; ac_word=$2
2922 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2923 $as_echo_n "checking for $ac_word... " >&6; }
2924 if ${ac_cv_prog_CC+:} false; then :
2925 $as_echo_n "(cached) " >&6
2926 else
2927 if test -n "$CC"; then
2928 ac_cv_prog_CC="$CC" # Let the user override the test.
2929 else
2930 ac_prog_rejected=no
2931 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2932 for as_dir in $PATH
2934 IFS=$as_save_IFS
2935 test -z "$as_dir" && as_dir=.
2936 for ac_exec_ext in '' $ac_executable_extensions; do
2937 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2938 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
2939 ac_prog_rejected=yes
2940 continue
2942 ac_cv_prog_CC="cc"
2943 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2944 break 2
2946 done
2947 done
2948 IFS=$as_save_IFS
2950 if test $ac_prog_rejected = yes; then
2951 # We found a bogon in the path, so make sure we never use it.
2952 set dummy $ac_cv_prog_CC
2953 shift
2954 if test $# != 0; then
2955 # We chose a different compiler from the bogus one.
2956 # However, it has the same basename, so the bogon will be chosen
2957 # first if we set CC to just the basename; use the full file name.
2958 shift
2959 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
2964 CC=$ac_cv_prog_CC
2965 if test -n "$CC"; then
2966 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2967 $as_echo "$CC" >&6; }
2968 else
2969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2970 $as_echo "no" >&6; }
2975 if test -z "$CC"; then
2976 if test -n "$ac_tool_prefix"; then
2977 for ac_prog in cl.exe
2979 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2980 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
2981 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2982 $as_echo_n "checking for $ac_word... " >&6; }
2983 if ${ac_cv_prog_CC+:} false; then :
2984 $as_echo_n "(cached) " >&6
2985 else
2986 if test -n "$CC"; then
2987 ac_cv_prog_CC="$CC" # Let the user override the test.
2988 else
2989 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2990 for as_dir in $PATH
2992 IFS=$as_save_IFS
2993 test -z "$as_dir" && as_dir=.
2994 for ac_exec_ext in '' $ac_executable_extensions; do
2995 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2996 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
2997 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2998 break 2
3000 done
3001 done
3002 IFS=$as_save_IFS
3006 CC=$ac_cv_prog_CC
3007 if test -n "$CC"; then
3008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3009 $as_echo "$CC" >&6; }
3010 else
3011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3012 $as_echo "no" >&6; }
3016 test -n "$CC" && break
3017 done
3019 if test -z "$CC"; then
3020 ac_ct_CC=$CC
3021 for ac_prog in cl.exe
3023 # Extract the first word of "$ac_prog", so it can be a program name with args.
3024 set dummy $ac_prog; ac_word=$2
3025 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3026 $as_echo_n "checking for $ac_word... " >&6; }
3027 if ${ac_cv_prog_ac_ct_CC+:} false; then :
3028 $as_echo_n "(cached) " >&6
3029 else
3030 if test -n "$ac_ct_CC"; then
3031 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3032 else
3033 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3034 for as_dir in $PATH
3036 IFS=$as_save_IFS
3037 test -z "$as_dir" && as_dir=.
3038 for ac_exec_ext in '' $ac_executable_extensions; do
3039 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3040 ac_cv_prog_ac_ct_CC="$ac_prog"
3041 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3042 break 2
3044 done
3045 done
3046 IFS=$as_save_IFS
3050 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3051 if test -n "$ac_ct_CC"; then
3052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3053 $as_echo "$ac_ct_CC" >&6; }
3054 else
3055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3056 $as_echo "no" >&6; }
3060 test -n "$ac_ct_CC" && break
3061 done
3063 if test "x$ac_ct_CC" = x; then
3064 CC=""
3065 else
3066 case $cross_compiling:$ac_tool_warned in
3067 yes:)
3068 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3069 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3070 ac_tool_warned=yes ;;
3071 esac
3072 CC=$ac_ct_CC
3079 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3080 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3081 as_fn_error $? "no acceptable C compiler found in \$PATH
3082 See \`config.log' for more details" "$LINENO" 5; }
3084 # Provide some information about the compiler.
3085 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
3086 set X $ac_compile
3087 ac_compiler=$2
3088 for ac_option in --version -v -V -qversion; do
3089 { { ac_try="$ac_compiler $ac_option >&5"
3090 case "(($ac_try" in
3091 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3092 *) ac_try_echo=$ac_try;;
3093 esac
3094 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3095 $as_echo "$ac_try_echo"; } >&5
3096 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3097 ac_status=$?
3098 if test -s conftest.err; then
3099 sed '10a\
3100 ... rest of stderr output deleted ...
3101 10q' conftest.err >conftest.er1
3102 cat conftest.er1 >&5
3104 rm -f conftest.er1 conftest.err
3105 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3106 test $ac_status = 0; }
3107 done
3109 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3110 /* end confdefs.h. */
3113 main ()
3117 return 0;
3119 _ACEOF
3120 ac_clean_files_save=$ac_clean_files
3121 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
3122 # Try to create an executable without -o first, disregard a.out.
3123 # It will help us diagnose broken compilers, and finding out an intuition
3124 # of exeext.
3125 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
3126 $as_echo_n "checking whether the C compiler works... " >&6; }
3127 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3129 # The possible output files:
3130 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3132 ac_rmfiles=
3133 for ac_file in $ac_files
3135 case $ac_file in
3136 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3137 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3138 esac
3139 done
3140 rm -f $ac_rmfiles
3142 if { { ac_try="$ac_link_default"
3143 case "(($ac_try" in
3144 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3145 *) ac_try_echo=$ac_try;;
3146 esac
3147 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3148 $as_echo "$ac_try_echo"; } >&5
3149 (eval "$ac_link_default") 2>&5
3150 ac_status=$?
3151 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3152 test $ac_status = 0; }; then :
3153 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3154 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3155 # in a Makefile. We should not override ac_cv_exeext if it was cached,
3156 # so that the user can short-circuit this test for compilers unknown to
3157 # Autoconf.
3158 for ac_file in $ac_files ''
3160 test -f "$ac_file" || continue
3161 case $ac_file in
3162 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
3164 [ab].out )
3165 # We found the default executable, but exeext='' is most
3166 # certainly right.
3167 break;;
3168 *.* )
3169 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3170 then :; else
3171 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3173 # We set ac_cv_exeext here because the later test for it is not
3174 # safe: cross compilers may not add the suffix if given an `-o'
3175 # argument, so we may need to know it at that point already.
3176 # Even if this section looks crufty: it has the advantage of
3177 # actually working.
3178 break;;
3180 break;;
3181 esac
3182 done
3183 test "$ac_cv_exeext" = no && ac_cv_exeext=
3185 else
3186 ac_file=''
3188 if test -z "$ac_file"; then :
3189 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3190 $as_echo "no" >&6; }
3191 $as_echo "$as_me: failed program was:" >&5
3192 sed 's/^/| /' conftest.$ac_ext >&5
3194 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3195 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3196 as_fn_error 77 "C compiler cannot create executables
3197 See \`config.log' for more details" "$LINENO" 5; }
3198 else
3199 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3200 $as_echo "yes" >&6; }
3202 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
3203 $as_echo_n "checking for C compiler default output file name... " >&6; }
3204 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
3205 $as_echo "$ac_file" >&6; }
3206 ac_exeext=$ac_cv_exeext
3208 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
3209 ac_clean_files=$ac_clean_files_save
3210 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
3211 $as_echo_n "checking for suffix of executables... " >&6; }
3212 if { { ac_try="$ac_link"
3213 case "(($ac_try" in
3214 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3215 *) ac_try_echo=$ac_try;;
3216 esac
3217 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3218 $as_echo "$ac_try_echo"; } >&5
3219 (eval "$ac_link") 2>&5
3220 ac_status=$?
3221 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3222 test $ac_status = 0; }; then :
3223 # If both `conftest.exe' and `conftest' are `present' (well, observable)
3224 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
3225 # work properly (i.e., refer to `conftest.exe'), while it won't with
3226 # `rm'.
3227 for ac_file in conftest.exe conftest conftest.*; do
3228 test -f "$ac_file" || continue
3229 case $ac_file in
3230 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3231 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3232 break;;
3233 * ) break;;
3234 esac
3235 done
3236 else
3237 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3238 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3239 as_fn_error $? "cannot compute suffix of executables: cannot compile and link
3240 See \`config.log' for more details" "$LINENO" 5; }
3242 rm -f conftest conftest$ac_cv_exeext
3243 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
3244 $as_echo "$ac_cv_exeext" >&6; }
3246 rm -f conftest.$ac_ext
3247 EXEEXT=$ac_cv_exeext
3248 ac_exeext=$EXEEXT
3249 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3250 /* end confdefs.h. */
3251 #include <stdio.h>
3253 main ()
3255 FILE *f = fopen ("conftest.out", "w");
3256 return ferror (f) || fclose (f) != 0;
3259 return 0;
3261 _ACEOF
3262 ac_clean_files="$ac_clean_files conftest.out"
3263 # Check that the compiler produces executables we can run. If not, either
3264 # the compiler is broken, or we cross compile.
3265 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
3266 $as_echo_n "checking whether we are cross compiling... " >&6; }
3267 if test "$cross_compiling" != yes; then
3268 { { ac_try="$ac_link"
3269 case "(($ac_try" in
3270 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3271 *) ac_try_echo=$ac_try;;
3272 esac
3273 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3274 $as_echo "$ac_try_echo"; } >&5
3275 (eval "$ac_link") 2>&5
3276 ac_status=$?
3277 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3278 test $ac_status = 0; }
3279 if { ac_try='./conftest$ac_cv_exeext'
3280 { { case "(($ac_try" in
3281 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3282 *) ac_try_echo=$ac_try;;
3283 esac
3284 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3285 $as_echo "$ac_try_echo"; } >&5
3286 (eval "$ac_try") 2>&5
3287 ac_status=$?
3288 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3289 test $ac_status = 0; }; }; then
3290 cross_compiling=no
3291 else
3292 if test "$cross_compiling" = maybe; then
3293 cross_compiling=yes
3294 else
3295 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3296 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3297 as_fn_error $? "cannot run C compiled programs.
3298 If you meant to cross compile, use \`--host'.
3299 See \`config.log' for more details" "$LINENO" 5; }
3303 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
3304 $as_echo "$cross_compiling" >&6; }
3306 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
3307 ac_clean_files=$ac_clean_files_save
3308 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
3309 $as_echo_n "checking for suffix of object files... " >&6; }
3310 if ${ac_cv_objext+:} false; then :
3311 $as_echo_n "(cached) " >&6
3312 else
3313 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3314 /* end confdefs.h. */
3317 main ()
3321 return 0;
3323 _ACEOF
3324 rm -f conftest.o conftest.obj
3325 if { { ac_try="$ac_compile"
3326 case "(($ac_try" in
3327 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3328 *) ac_try_echo=$ac_try;;
3329 esac
3330 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3331 $as_echo "$ac_try_echo"; } >&5
3332 (eval "$ac_compile") 2>&5
3333 ac_status=$?
3334 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3335 test $ac_status = 0; }; then :
3336 for ac_file in conftest.o conftest.obj conftest.*; do
3337 test -f "$ac_file" || continue;
3338 case $ac_file in
3339 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
3340 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3341 break;;
3342 esac
3343 done
3344 else
3345 $as_echo "$as_me: failed program was:" >&5
3346 sed 's/^/| /' conftest.$ac_ext >&5
3348 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3349 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3350 as_fn_error $? "cannot compute suffix of object files: cannot compile
3351 See \`config.log' for more details" "$LINENO" 5; }
3353 rm -f conftest.$ac_cv_objext conftest.$ac_ext
3355 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
3356 $as_echo "$ac_cv_objext" >&6; }
3357 OBJEXT=$ac_cv_objext
3358 ac_objext=$OBJEXT
3359 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
3360 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
3361 if ${ac_cv_c_compiler_gnu+:} false; then :
3362 $as_echo_n "(cached) " >&6
3363 else
3364 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3365 /* end confdefs.h. */
3368 main ()
3370 #ifndef __GNUC__
3371 choke me
3372 #endif
3375 return 0;
3377 _ACEOF
3378 if ac_fn_c_try_compile "$LINENO"; then :
3379 ac_compiler_gnu=yes
3380 else
3381 ac_compiler_gnu=no
3383 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3384 ac_cv_c_compiler_gnu=$ac_compiler_gnu
3387 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
3388 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
3389 if test $ac_compiler_gnu = yes; then
3390 GCC=yes
3391 else
3392 GCC=
3394 ac_test_CFLAGS=${CFLAGS+set}
3395 ac_save_CFLAGS=$CFLAGS
3396 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
3397 $as_echo_n "checking whether $CC accepts -g... " >&6; }
3398 if ${ac_cv_prog_cc_g+:} false; then :
3399 $as_echo_n "(cached) " >&6
3400 else
3401 ac_save_c_werror_flag=$ac_c_werror_flag
3402 ac_c_werror_flag=yes
3403 ac_cv_prog_cc_g=no
3404 CFLAGS="-g"
3405 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3406 /* end confdefs.h. */
3409 main ()
3413 return 0;
3415 _ACEOF
3416 if ac_fn_c_try_compile "$LINENO"; then :
3417 ac_cv_prog_cc_g=yes
3418 else
3419 CFLAGS=""
3420 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3421 /* end confdefs.h. */
3424 main ()
3428 return 0;
3430 _ACEOF
3431 if ac_fn_c_try_compile "$LINENO"; then :
3433 else
3434 ac_c_werror_flag=$ac_save_c_werror_flag
3435 CFLAGS="-g"
3436 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3437 /* end confdefs.h. */
3440 main ()
3444 return 0;
3446 _ACEOF
3447 if ac_fn_c_try_compile "$LINENO"; then :
3448 ac_cv_prog_cc_g=yes
3450 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3452 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3454 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3455 ac_c_werror_flag=$ac_save_c_werror_flag
3457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
3458 $as_echo "$ac_cv_prog_cc_g" >&6; }
3459 if test "$ac_test_CFLAGS" = set; then
3460 CFLAGS=$ac_save_CFLAGS
3461 elif test $ac_cv_prog_cc_g = yes; then
3462 if test "$GCC" = yes; then
3463 CFLAGS="-g -O2"
3464 else
3465 CFLAGS="-g"
3467 else
3468 if test "$GCC" = yes; then
3469 CFLAGS="-O2"
3470 else
3471 CFLAGS=
3474 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
3475 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
3476 if ${ac_cv_prog_cc_c89+:} false; then :
3477 $as_echo_n "(cached) " >&6
3478 else
3479 ac_cv_prog_cc_c89=no
3480 ac_save_CC=$CC
3481 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3482 /* end confdefs.h. */
3483 #include <stdarg.h>
3484 #include <stdio.h>
3485 struct stat;
3486 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
3487 struct buf { int x; };
3488 FILE * (*rcsopen) (struct buf *, struct stat *, int);
3489 static char *e (p, i)
3490 char **p;
3491 int i;
3493 return p[i];
3495 static char *f (char * (*g) (char **, int), char **p, ...)
3497 char *s;
3498 va_list v;
3499 va_start (v,p);
3500 s = g (p, va_arg (v,int));
3501 va_end (v);
3502 return s;
3505 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
3506 function prototypes and stuff, but not '\xHH' hex character constants.
3507 These don't provoke an error unfortunately, instead are silently treated
3508 as 'x'. The following induces an error, until -std is added to get
3509 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
3510 array size at least. It's necessary to write '\x00'==0 to get something
3511 that's true only with -std. */
3512 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3514 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3515 inside strings and character constants. */
3516 #define FOO(x) 'x'
3517 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3519 int test (int i, double x);
3520 struct s1 {int (*f) (int a);};
3521 struct s2 {int (*f) (double a);};
3522 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3523 int argc;
3524 char **argv;
3526 main ()
3528 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
3530 return 0;
3532 _ACEOF
3533 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3534 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3536 CC="$ac_save_CC $ac_arg"
3537 if ac_fn_c_try_compile "$LINENO"; then :
3538 ac_cv_prog_cc_c89=$ac_arg
3540 rm -f core conftest.err conftest.$ac_objext
3541 test "x$ac_cv_prog_cc_c89" != "xno" && break
3542 done
3543 rm -f conftest.$ac_ext
3544 CC=$ac_save_CC
3547 # AC_CACHE_VAL
3548 case "x$ac_cv_prog_cc_c89" in
3550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
3551 $as_echo "none needed" >&6; } ;;
3552 xno)
3553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
3554 $as_echo "unsupported" >&6; } ;;
3556 CC="$CC $ac_cv_prog_cc_c89"
3557 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
3558 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
3559 esac
3560 if test "x$ac_cv_prog_cc_c89" != xno; then :
3564 ac_ext=c
3565 ac_cpp='$CPP $CPPFLAGS'
3566 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3567 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3568 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3570 ac_ext=cpp
3571 ac_cpp='$CXXCPP $CPPFLAGS'
3572 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3573 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3574 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
3575 if test -z "$CXX"; then
3576 if test -n "$CCC"; then
3577 CXX=$CCC
3578 else
3579 if test -n "$ac_tool_prefix"; then
3580 for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
3582 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3583 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3584 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3585 $as_echo_n "checking for $ac_word... " >&6; }
3586 if ${ac_cv_prog_CXX+:} false; then :
3587 $as_echo_n "(cached) " >&6
3588 else
3589 if test -n "$CXX"; then
3590 ac_cv_prog_CXX="$CXX" # Let the user override the test.
3591 else
3592 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3593 for as_dir in $PATH
3595 IFS=$as_save_IFS
3596 test -z "$as_dir" && as_dir=.
3597 for ac_exec_ext in '' $ac_executable_extensions; do
3598 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3599 ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
3600 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3601 break 2
3603 done
3604 done
3605 IFS=$as_save_IFS
3609 CXX=$ac_cv_prog_CXX
3610 if test -n "$CXX"; then
3611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
3612 $as_echo "$CXX" >&6; }
3613 else
3614 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3615 $as_echo "no" >&6; }
3619 test -n "$CXX" && break
3620 done
3622 if test -z "$CXX"; then
3623 ac_ct_CXX=$CXX
3624 for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
3626 # Extract the first word of "$ac_prog", so it can be a program name with args.
3627 set dummy $ac_prog; ac_word=$2
3628 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3629 $as_echo_n "checking for $ac_word... " >&6; }
3630 if ${ac_cv_prog_ac_ct_CXX+:} false; then :
3631 $as_echo_n "(cached) " >&6
3632 else
3633 if test -n "$ac_ct_CXX"; then
3634 ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
3635 else
3636 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3637 for as_dir in $PATH
3639 IFS=$as_save_IFS
3640 test -z "$as_dir" && as_dir=.
3641 for ac_exec_ext in '' $ac_executable_extensions; do
3642 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3643 ac_cv_prog_ac_ct_CXX="$ac_prog"
3644 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3645 break 2
3647 done
3648 done
3649 IFS=$as_save_IFS
3653 ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
3654 if test -n "$ac_ct_CXX"; then
3655 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
3656 $as_echo "$ac_ct_CXX" >&6; }
3657 else
3658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3659 $as_echo "no" >&6; }
3663 test -n "$ac_ct_CXX" && break
3664 done
3666 if test "x$ac_ct_CXX" = x; then
3667 CXX="g++"
3668 else
3669 case $cross_compiling:$ac_tool_warned in
3670 yes:)
3671 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3672 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3673 ac_tool_warned=yes ;;
3674 esac
3675 CXX=$ac_ct_CXX
3681 # Provide some information about the compiler.
3682 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
3683 set X $ac_compile
3684 ac_compiler=$2
3685 for ac_option in --version -v -V -qversion; do
3686 { { ac_try="$ac_compiler $ac_option >&5"
3687 case "(($ac_try" in
3688 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3689 *) ac_try_echo=$ac_try;;
3690 esac
3691 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3692 $as_echo "$ac_try_echo"; } >&5
3693 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3694 ac_status=$?
3695 if test -s conftest.err; then
3696 sed '10a\
3697 ... rest of stderr output deleted ...
3698 10q' conftest.err >conftest.er1
3699 cat conftest.er1 >&5
3701 rm -f conftest.er1 conftest.err
3702 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3703 test $ac_status = 0; }
3704 done
3706 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5
3707 $as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; }
3708 if ${ac_cv_cxx_compiler_gnu+:} false; then :
3709 $as_echo_n "(cached) " >&6
3710 else
3711 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3712 /* end confdefs.h. */
3715 main ()
3717 #ifndef __GNUC__
3718 choke me
3719 #endif
3722 return 0;
3724 _ACEOF
3725 if ac_fn_cxx_try_compile "$LINENO"; then :
3726 ac_compiler_gnu=yes
3727 else
3728 ac_compiler_gnu=no
3730 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3731 ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
3734 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
3735 $as_echo "$ac_cv_cxx_compiler_gnu" >&6; }
3736 if test $ac_compiler_gnu = yes; then
3737 GXX=yes
3738 else
3739 GXX=
3741 ac_test_CXXFLAGS=${CXXFLAGS+set}
3742 ac_save_CXXFLAGS=$CXXFLAGS
3743 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
3744 $as_echo_n "checking whether $CXX accepts -g... " >&6; }
3745 if ${ac_cv_prog_cxx_g+:} false; then :
3746 $as_echo_n "(cached) " >&6
3747 else
3748 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
3749 ac_cxx_werror_flag=yes
3750 ac_cv_prog_cxx_g=no
3751 CXXFLAGS="-g"
3752 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3753 /* end confdefs.h. */
3756 main ()
3760 return 0;
3762 _ACEOF
3763 if ac_fn_cxx_try_compile "$LINENO"; then :
3764 ac_cv_prog_cxx_g=yes
3765 else
3766 CXXFLAGS=""
3767 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3768 /* end confdefs.h. */
3771 main ()
3775 return 0;
3777 _ACEOF
3778 if ac_fn_cxx_try_compile "$LINENO"; then :
3780 else
3781 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
3782 CXXFLAGS="-g"
3783 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3784 /* end confdefs.h. */
3787 main ()
3791 return 0;
3793 _ACEOF
3794 if ac_fn_cxx_try_compile "$LINENO"; then :
3795 ac_cv_prog_cxx_g=yes
3797 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3799 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3801 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3802 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
3804 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
3805 $as_echo "$ac_cv_prog_cxx_g" >&6; }
3806 if test "$ac_test_CXXFLAGS" = set; then
3807 CXXFLAGS=$ac_save_CXXFLAGS
3808 elif test $ac_cv_prog_cxx_g = yes; then
3809 if test "$GXX" = yes; then
3810 CXXFLAGS="-g -O2"
3811 else
3812 CXXFLAGS="-g"
3814 else
3815 if test "$GXX" = yes; then
3816 CXXFLAGS="-O2"
3817 else
3818 CXXFLAGS=
3821 ac_ext=c
3822 ac_cpp='$CPP $CPPFLAGS'
3823 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3824 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3825 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3828 ac_ext=c
3829 ac_cpp='$CPP $CPPFLAGS'
3830 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3831 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3832 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3833 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
3834 $as_echo_n "checking how to run the C preprocessor... " >&6; }
3835 # On Suns, sometimes $CPP names a directory.
3836 if test -n "$CPP" && test -d "$CPP"; then
3837 CPP=
3839 if test -z "$CPP"; then
3840 if ${ac_cv_prog_CPP+:} false; then :
3841 $as_echo_n "(cached) " >&6
3842 else
3843 # Double quotes because CPP needs to be expanded
3844 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3846 ac_preproc_ok=false
3847 for ac_c_preproc_warn_flag in '' yes
3849 # Use a header file that comes with gcc, so configuring glibc
3850 # with a fresh cross-compiler works.
3851 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3852 # <limits.h> exists even on freestanding compilers.
3853 # On the NeXT, cc -E runs the code through the compiler's parser,
3854 # not just through cpp. "Syntax error" is here to catch this case.
3855 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3856 /* end confdefs.h. */
3857 #ifdef __STDC__
3858 # include <limits.h>
3859 #else
3860 # include <assert.h>
3861 #endif
3862 Syntax error
3863 _ACEOF
3864 if ac_fn_c_try_cpp "$LINENO"; then :
3866 else
3867 # Broken: fails on valid input.
3868 continue
3870 rm -f conftest.err conftest.i conftest.$ac_ext
3872 # OK, works on sane cases. Now check whether nonexistent headers
3873 # can be detected and how.
3874 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3875 /* end confdefs.h. */
3876 #include <ac_nonexistent.h>
3877 _ACEOF
3878 if ac_fn_c_try_cpp "$LINENO"; then :
3879 # Broken: success on invalid input.
3880 continue
3881 else
3882 # Passes both tests.
3883 ac_preproc_ok=:
3884 break
3886 rm -f conftest.err conftest.i conftest.$ac_ext
3888 done
3889 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3890 rm -f conftest.i conftest.err conftest.$ac_ext
3891 if $ac_preproc_ok; then :
3892 break
3895 done
3896 ac_cv_prog_CPP=$CPP
3899 CPP=$ac_cv_prog_CPP
3900 else
3901 ac_cv_prog_CPP=$CPP
3903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
3904 $as_echo "$CPP" >&6; }
3905 ac_preproc_ok=false
3906 for ac_c_preproc_warn_flag in '' yes
3908 # Use a header file that comes with gcc, so configuring glibc
3909 # with a fresh cross-compiler works.
3910 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3911 # <limits.h> exists even on freestanding compilers.
3912 # On the NeXT, cc -E runs the code through the compiler's parser,
3913 # not just through cpp. "Syntax error" is here to catch this case.
3914 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3915 /* end confdefs.h. */
3916 #ifdef __STDC__
3917 # include <limits.h>
3918 #else
3919 # include <assert.h>
3920 #endif
3921 Syntax error
3922 _ACEOF
3923 if ac_fn_c_try_cpp "$LINENO"; then :
3925 else
3926 # Broken: fails on valid input.
3927 continue
3929 rm -f conftest.err conftest.i conftest.$ac_ext
3931 # OK, works on sane cases. Now check whether nonexistent headers
3932 # can be detected and how.
3933 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3934 /* end confdefs.h. */
3935 #include <ac_nonexistent.h>
3936 _ACEOF
3937 if ac_fn_c_try_cpp "$LINENO"; then :
3938 # Broken: success on invalid input.
3939 continue
3940 else
3941 # Passes both tests.
3942 ac_preproc_ok=:
3943 break
3945 rm -f conftest.err conftest.i conftest.$ac_ext
3947 done
3948 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3949 rm -f conftest.i conftest.err conftest.$ac_ext
3950 if $ac_preproc_ok; then :
3952 else
3953 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3954 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3955 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
3956 See \`config.log' for more details" "$LINENO" 5; }
3959 ac_ext=c
3960 ac_cpp='$CPP $CPPFLAGS'
3961 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3962 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3963 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3966 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
3967 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
3968 if ${ac_cv_path_GREP+:} false; then :
3969 $as_echo_n "(cached) " >&6
3970 else
3971 if test -z "$GREP"; then
3972 ac_path_GREP_found=false
3973 # Loop through the user's path and test for each of PROGNAME-LIST
3974 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3975 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
3977 IFS=$as_save_IFS
3978 test -z "$as_dir" && as_dir=.
3979 for ac_prog in grep ggrep; do
3980 for ac_exec_ext in '' $ac_executable_extensions; do
3981 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
3982 as_fn_executable_p "$ac_path_GREP" || continue
3983 # Check for GNU ac_path_GREP and select it if it is found.
3984 # Check for GNU $ac_path_GREP
3985 case `"$ac_path_GREP" --version 2>&1` in
3986 *GNU*)
3987 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
3989 ac_count=0
3990 $as_echo_n 0123456789 >"conftest.in"
3991 while :
3993 cat "conftest.in" "conftest.in" >"conftest.tmp"
3994 mv "conftest.tmp" "conftest.in"
3995 cp "conftest.in" "conftest.nl"
3996 $as_echo 'GREP' >> "conftest.nl"
3997 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
3998 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
3999 as_fn_arith $ac_count + 1 && ac_count=$as_val
4000 if test $ac_count -gt ${ac_path_GREP_max-0}; then
4001 # Best one so far, save it but keep looking for a better one
4002 ac_cv_path_GREP="$ac_path_GREP"
4003 ac_path_GREP_max=$ac_count
4005 # 10*(2^10) chars as input seems more than enough
4006 test $ac_count -gt 10 && break
4007 done
4008 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4009 esac
4011 $ac_path_GREP_found && break 3
4012 done
4013 done
4014 done
4015 IFS=$as_save_IFS
4016 if test -z "$ac_cv_path_GREP"; then
4017 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4019 else
4020 ac_cv_path_GREP=$GREP
4024 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
4025 $as_echo "$ac_cv_path_GREP" >&6; }
4026 GREP="$ac_cv_path_GREP"
4029 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
4030 $as_echo_n "checking for egrep... " >&6; }
4031 if ${ac_cv_path_EGREP+:} false; then :
4032 $as_echo_n "(cached) " >&6
4033 else
4034 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
4035 then ac_cv_path_EGREP="$GREP -E"
4036 else
4037 if test -z "$EGREP"; then
4038 ac_path_EGREP_found=false
4039 # Loop through the user's path and test for each of PROGNAME-LIST
4040 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4041 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4043 IFS=$as_save_IFS
4044 test -z "$as_dir" && as_dir=.
4045 for ac_prog in egrep; do
4046 for ac_exec_ext in '' $ac_executable_extensions; do
4047 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
4048 as_fn_executable_p "$ac_path_EGREP" || continue
4049 # Check for GNU ac_path_EGREP and select it if it is found.
4050 # Check for GNU $ac_path_EGREP
4051 case `"$ac_path_EGREP" --version 2>&1` in
4052 *GNU*)
4053 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
4055 ac_count=0
4056 $as_echo_n 0123456789 >"conftest.in"
4057 while :
4059 cat "conftest.in" "conftest.in" >"conftest.tmp"
4060 mv "conftest.tmp" "conftest.in"
4061 cp "conftest.in" "conftest.nl"
4062 $as_echo 'EGREP' >> "conftest.nl"
4063 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4064 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4065 as_fn_arith $ac_count + 1 && ac_count=$as_val
4066 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
4067 # Best one so far, save it but keep looking for a better one
4068 ac_cv_path_EGREP="$ac_path_EGREP"
4069 ac_path_EGREP_max=$ac_count
4071 # 10*(2^10) chars as input seems more than enough
4072 test $ac_count -gt 10 && break
4073 done
4074 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4075 esac
4077 $ac_path_EGREP_found && break 3
4078 done
4079 done
4080 done
4081 IFS=$as_save_IFS
4082 if test -z "$ac_cv_path_EGREP"; then
4083 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4085 else
4086 ac_cv_path_EGREP=$EGREP
4091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
4092 $as_echo "$ac_cv_path_EGREP" >&6; }
4093 EGREP="$ac_cv_path_EGREP"
4096 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
4097 $as_echo_n "checking for ANSI C header files... " >&6; }
4098 if ${ac_cv_header_stdc+:} false; then :
4099 $as_echo_n "(cached) " >&6
4100 else
4101 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4102 /* end confdefs.h. */
4103 #include <stdlib.h>
4104 #include <stdarg.h>
4105 #include <string.h>
4106 #include <float.h>
4109 main ()
4113 return 0;
4115 _ACEOF
4116 if ac_fn_c_try_compile "$LINENO"; then :
4117 ac_cv_header_stdc=yes
4118 else
4119 ac_cv_header_stdc=no
4121 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4123 if test $ac_cv_header_stdc = yes; then
4124 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
4125 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4126 /* end confdefs.h. */
4127 #include <string.h>
4129 _ACEOF
4130 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4131 $EGREP "memchr" >/dev/null 2>&1; then :
4133 else
4134 ac_cv_header_stdc=no
4136 rm -f conftest*
4140 if test $ac_cv_header_stdc = yes; then
4141 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
4142 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4143 /* end confdefs.h. */
4144 #include <stdlib.h>
4146 _ACEOF
4147 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4148 $EGREP "free" >/dev/null 2>&1; then :
4150 else
4151 ac_cv_header_stdc=no
4153 rm -f conftest*
4157 if test $ac_cv_header_stdc = yes; then
4158 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
4159 if test "$cross_compiling" = yes; then :
4161 else
4162 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4163 /* end confdefs.h. */
4164 #include <ctype.h>
4165 #include <stdlib.h>
4166 #if ((' ' & 0x0FF) == 0x020)
4167 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4168 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4169 #else
4170 # define ISLOWER(c) \
4171 (('a' <= (c) && (c) <= 'i') \
4172 || ('j' <= (c) && (c) <= 'r') \
4173 || ('s' <= (c) && (c) <= 'z'))
4174 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4175 #endif
4177 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4179 main ()
4181 int i;
4182 for (i = 0; i < 256; i++)
4183 if (XOR (islower (i), ISLOWER (i))
4184 || toupper (i) != TOUPPER (i))
4185 return 2;
4186 return 0;
4188 _ACEOF
4189 if ac_fn_c_try_run "$LINENO"; then :
4191 else
4192 ac_cv_header_stdc=no
4194 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
4195 conftest.$ac_objext conftest.beam conftest.$ac_ext
4200 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
4201 $as_echo "$ac_cv_header_stdc" >&6; }
4202 if test $ac_cv_header_stdc = yes; then
4204 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
4208 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
4209 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
4210 inttypes.h stdint.h unistd.h
4211 do :
4212 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
4213 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
4215 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
4216 cat >>confdefs.h <<_ACEOF
4217 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
4218 _ACEOF
4222 done
4226 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
4227 if test "x$ac_cv_header_minix_config_h" = xyes; then :
4228 MINIX=yes
4229 else
4230 MINIX=
4234 if test "$MINIX" = yes; then
4236 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
4239 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
4242 $as_echo "#define _MINIX 1" >>confdefs.h
4247 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
4248 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
4249 if ${ac_cv_safe_to_define___extensions__+:} false; then :
4250 $as_echo_n "(cached) " >&6
4251 else
4252 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4253 /* end confdefs.h. */
4255 # define __EXTENSIONS__ 1
4256 $ac_includes_default
4258 main ()
4262 return 0;
4264 _ACEOF
4265 if ac_fn_c_try_compile "$LINENO"; then :
4266 ac_cv_safe_to_define___extensions__=yes
4267 else
4268 ac_cv_safe_to_define___extensions__=no
4270 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4272 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
4273 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
4274 test $ac_cv_safe_to_define___extensions__ = yes &&
4275 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
4277 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
4279 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
4281 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
4283 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
4286 # Check whether --enable-largefile was given.
4287 if test "${enable_largefile+set}" = set; then :
4288 enableval=$enable_largefile;
4291 if test "$enable_largefile" != no; then
4293 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
4294 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
4295 if ${ac_cv_sys_largefile_CC+:} false; then :
4296 $as_echo_n "(cached) " >&6
4297 else
4298 ac_cv_sys_largefile_CC=no
4299 if test "$GCC" != yes; then
4300 ac_save_CC=$CC
4301 while :; do
4302 # IRIX 6.2 and later do not support large files by default,
4303 # so use the C compiler's -n32 option if that helps.
4304 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4305 /* end confdefs.h. */
4306 #include <sys/types.h>
4307 /* Check that off_t can represent 2**63 - 1 correctly.
4308 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4309 since some C++ compilers masquerading as C compilers
4310 incorrectly reject 9223372036854775807. */
4311 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4312 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4313 && LARGE_OFF_T % 2147483647 == 1)
4314 ? 1 : -1];
4316 main ()
4320 return 0;
4322 _ACEOF
4323 if ac_fn_c_try_compile "$LINENO"; then :
4324 break
4326 rm -f core conftest.err conftest.$ac_objext
4327 CC="$CC -n32"
4328 if ac_fn_c_try_compile "$LINENO"; then :
4329 ac_cv_sys_largefile_CC=' -n32'; break
4331 rm -f core conftest.err conftest.$ac_objext
4332 break
4333 done
4334 CC=$ac_save_CC
4335 rm -f conftest.$ac_ext
4338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
4339 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
4340 if test "$ac_cv_sys_largefile_CC" != no; then
4341 CC=$CC$ac_cv_sys_largefile_CC
4344 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
4345 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
4346 if ${ac_cv_sys_file_offset_bits+:} false; then :
4347 $as_echo_n "(cached) " >&6
4348 else
4349 while :; do
4350 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4351 /* end confdefs.h. */
4352 #include <sys/types.h>
4353 /* Check that off_t can represent 2**63 - 1 correctly.
4354 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4355 since some C++ compilers masquerading as C compilers
4356 incorrectly reject 9223372036854775807. */
4357 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4358 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4359 && LARGE_OFF_T % 2147483647 == 1)
4360 ? 1 : -1];
4362 main ()
4366 return 0;
4368 _ACEOF
4369 if ac_fn_c_try_compile "$LINENO"; then :
4370 ac_cv_sys_file_offset_bits=no; break
4372 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4373 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4374 /* end confdefs.h. */
4375 #define _FILE_OFFSET_BITS 64
4376 #include <sys/types.h>
4377 /* Check that off_t can represent 2**63 - 1 correctly.
4378 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4379 since some C++ compilers masquerading as C compilers
4380 incorrectly reject 9223372036854775807. */
4381 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4382 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4383 && LARGE_OFF_T % 2147483647 == 1)
4384 ? 1 : -1];
4386 main ()
4390 return 0;
4392 _ACEOF
4393 if ac_fn_c_try_compile "$LINENO"; then :
4394 ac_cv_sys_file_offset_bits=64; break
4396 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4397 ac_cv_sys_file_offset_bits=unknown
4398 break
4399 done
4401 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
4402 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
4403 case $ac_cv_sys_file_offset_bits in #(
4404 no | unknown) ;;
4406 cat >>confdefs.h <<_ACEOF
4407 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
4408 _ACEOF
4410 esac
4411 rm -rf conftest*
4412 if test $ac_cv_sys_file_offset_bits = unknown; then
4413 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
4414 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
4415 if ${ac_cv_sys_large_files+:} false; then :
4416 $as_echo_n "(cached) " >&6
4417 else
4418 while :; do
4419 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4420 /* end confdefs.h. */
4421 #include <sys/types.h>
4422 /* Check that off_t can represent 2**63 - 1 correctly.
4423 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4424 since some C++ compilers masquerading as C compilers
4425 incorrectly reject 9223372036854775807. */
4426 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4427 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4428 && LARGE_OFF_T % 2147483647 == 1)
4429 ? 1 : -1];
4431 main ()
4435 return 0;
4437 _ACEOF
4438 if ac_fn_c_try_compile "$LINENO"; then :
4439 ac_cv_sys_large_files=no; break
4441 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4442 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4443 /* end confdefs.h. */
4444 #define _LARGE_FILES 1
4445 #include <sys/types.h>
4446 /* Check that off_t can represent 2**63 - 1 correctly.
4447 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4448 since some C++ compilers masquerading as C compilers
4449 incorrectly reject 9223372036854775807. */
4450 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4451 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4452 && LARGE_OFF_T % 2147483647 == 1)
4453 ? 1 : -1];
4455 main ()
4459 return 0;
4461 _ACEOF
4462 if ac_fn_c_try_compile "$LINENO"; then :
4463 ac_cv_sys_large_files=1; break
4465 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4466 ac_cv_sys_large_files=unknown
4467 break
4468 done
4470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
4471 $as_echo "$ac_cv_sys_large_files" >&6; }
4472 case $ac_cv_sys_large_files in #(
4473 no | unknown) ;;
4475 cat >>confdefs.h <<_ACEOF
4476 #define _LARGE_FILES $ac_cv_sys_large_files
4477 _ACEOF
4479 esac
4480 rm -rf conftest*
4486 ac_aux_dir=
4487 for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
4488 if test -f "$ac_dir/install-sh"; then
4489 ac_aux_dir=$ac_dir
4490 ac_install_sh="$ac_aux_dir/install-sh -c"
4491 break
4492 elif test -f "$ac_dir/install.sh"; then
4493 ac_aux_dir=$ac_dir
4494 ac_install_sh="$ac_aux_dir/install.sh -c"
4495 break
4496 elif test -f "$ac_dir/shtool"; then
4497 ac_aux_dir=$ac_dir
4498 ac_install_sh="$ac_aux_dir/shtool install -c"
4499 break
4501 done
4502 if test -z "$ac_aux_dir"; then
4503 as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
4506 # These three variables are undocumented and unsupported,
4507 # and are intended to be withdrawn in a future Autoconf release.
4508 # They can cause serious problems if a builder's source tree is in a directory
4509 # whose full name contains unusual characters.
4510 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
4511 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
4512 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
4515 # Expand $ac_aux_dir to an absolute path.
4516 am_aux_dir=`cd "$ac_aux_dir" && pwd`
4518 if test x"${install_sh+set}" != xset; then
4519 case $am_aux_dir in
4520 *\ * | *\ *)
4521 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
4523 install_sh="\${SHELL} $am_aux_dir/install-sh"
4524 esac
4527 # Installed binaries are usually stripped using 'strip' when the user
4528 # run "make install-strip". However 'strip' might not be the right
4529 # tool to use in cross-compilation environments, therefore Automake
4530 # will honor the 'STRIP' environment variable to overrule this program.
4531 if test "$cross_compiling" != no; then
4532 if test -n "$ac_tool_prefix"; then
4533 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
4534 set dummy ${ac_tool_prefix}strip; ac_word=$2
4535 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4536 $as_echo_n "checking for $ac_word... " >&6; }
4537 if ${ac_cv_prog_STRIP+:} false; then :
4538 $as_echo_n "(cached) " >&6
4539 else
4540 if test -n "$STRIP"; then
4541 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
4542 else
4543 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4544 for as_dir in $PATH
4546 IFS=$as_save_IFS
4547 test -z "$as_dir" && as_dir=.
4548 for ac_exec_ext in '' $ac_executable_extensions; do
4549 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4550 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
4551 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4552 break 2
4554 done
4555 done
4556 IFS=$as_save_IFS
4560 STRIP=$ac_cv_prog_STRIP
4561 if test -n "$STRIP"; then
4562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
4563 $as_echo "$STRIP" >&6; }
4564 else
4565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4566 $as_echo "no" >&6; }
4571 if test -z "$ac_cv_prog_STRIP"; then
4572 ac_ct_STRIP=$STRIP
4573 # Extract the first word of "strip", so it can be a program name with args.
4574 set dummy strip; ac_word=$2
4575 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4576 $as_echo_n "checking for $ac_word... " >&6; }
4577 if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
4578 $as_echo_n "(cached) " >&6
4579 else
4580 if test -n "$ac_ct_STRIP"; then
4581 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
4582 else
4583 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4584 for as_dir in $PATH
4586 IFS=$as_save_IFS
4587 test -z "$as_dir" && as_dir=.
4588 for ac_exec_ext in '' $ac_executable_extensions; do
4589 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4590 ac_cv_prog_ac_ct_STRIP="strip"
4591 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4592 break 2
4594 done
4595 done
4596 IFS=$as_save_IFS
4600 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
4601 if test -n "$ac_ct_STRIP"; then
4602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
4603 $as_echo "$ac_ct_STRIP" >&6; }
4604 else
4605 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4606 $as_echo "no" >&6; }
4609 if test "x$ac_ct_STRIP" = x; then
4610 STRIP=":"
4611 else
4612 case $cross_compiling:$ac_tool_warned in
4613 yes:)
4614 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4615 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4616 ac_tool_warned=yes ;;
4617 esac
4618 STRIP=$ac_ct_STRIP
4620 else
4621 STRIP="$ac_cv_prog_STRIP"
4625 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
4628 # Set build, build_cpu, build_vendor and build_os.
4629 # Make sure we can run config.sub.
4630 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
4631 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
4633 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
4634 $as_echo_n "checking build system type... " >&6; }
4635 if ${ac_cv_build+:} false; then :
4636 $as_echo_n "(cached) " >&6
4637 else
4638 ac_build_alias=$build_alias
4639 test "x$ac_build_alias" = x &&
4640 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
4641 test "x$ac_build_alias" = x &&
4642 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
4643 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
4644 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
4647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
4648 $as_echo "$ac_cv_build" >&6; }
4649 case $ac_cv_build in
4650 *-*-*) ;;
4651 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
4652 esac
4653 build=$ac_cv_build
4654 ac_save_IFS=$IFS; IFS='-'
4655 set x $ac_cv_build
4656 shift
4657 build_cpu=$1
4658 build_vendor=$2
4659 shift; shift
4660 # Remember, the first character of IFS is used to create $*,
4661 # except with old shells:
4662 build_os=$*
4663 IFS=$ac_save_IFS
4664 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
4668 # Set host, host_cpu, host_vendor, and host_os.
4669 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
4670 $as_echo_n "checking host system type... " >&6; }
4671 if ${ac_cv_host+:} false; then :
4672 $as_echo_n "(cached) " >&6
4673 else
4674 if test "x$host_alias" = x; then
4675 ac_cv_host=$ac_cv_build
4676 else
4677 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
4678 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
4682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
4683 $as_echo "$ac_cv_host" >&6; }
4684 case $ac_cv_host in
4685 *-*-*) ;;
4686 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
4687 esac
4688 host=$ac_cv_host
4689 ac_save_IFS=$IFS; IFS='-'
4690 set x $ac_cv_host
4691 shift
4692 host_cpu=$1
4693 host_vendor=$2
4694 shift; shift
4695 # Remember, the first character of IFS is used to create $*,
4696 # except with old shells:
4697 host_os=$*
4698 IFS=$ac_save_IFS
4699 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
4703 # Set target, target_cpu, target_vendor, and target_os.
4704 { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
4705 $as_echo_n "checking target system type... " >&6; }
4706 if ${ac_cv_target+:} false; then :
4707 $as_echo_n "(cached) " >&6
4708 else
4709 if test "x$target_alias" = x; then
4710 ac_cv_target=$ac_cv_host
4711 else
4712 ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
4713 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
4717 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
4718 $as_echo "$ac_cv_target" >&6; }
4719 case $ac_cv_target in
4720 *-*-*) ;;
4721 *) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;;
4722 esac
4723 target=$ac_cv_target
4724 ac_save_IFS=$IFS; IFS='-'
4725 set x $ac_cv_target
4726 shift
4727 target_cpu=$1
4728 target_vendor=$2
4729 shift; shift
4730 # Remember, the first character of IFS is used to create $*,
4731 # except with old shells:
4732 target_os=$*
4733 IFS=$ac_save_IFS
4734 case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
4737 # The aliases save the names the user supplied, while $host etc.
4738 # will get canonicalized.
4739 test -n "$target_alias" &&
4740 test "$program_prefix$program_suffix$program_transform_name" = \
4741 NONENONEs,x,x, &&
4742 program_prefix=${target_alias}-
4744 # Find a good install program. We prefer a C program (faster),
4745 # so one script is as good as another. But avoid the broken or
4746 # incompatible versions:
4747 # SysV /etc/install, /usr/sbin/install
4748 # SunOS /usr/etc/install
4749 # IRIX /sbin/install
4750 # AIX /bin/install
4751 # AmigaOS /C/install, which installs bootblocks on floppy discs
4752 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
4753 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
4754 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
4755 # OS/2's system install, which has a completely different semantic
4756 # ./install, which can be erroneously created by make from ./install.sh.
4757 # Reject install programs that cannot install multiple files.
4758 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
4759 $as_echo_n "checking for a BSD-compatible install... " >&6; }
4760 if test -z "$INSTALL"; then
4761 if ${ac_cv_path_install+:} false; then :
4762 $as_echo_n "(cached) " >&6
4763 else
4764 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4765 for as_dir in $PATH
4767 IFS=$as_save_IFS
4768 test -z "$as_dir" && as_dir=.
4769 # Account for people who put trailing slashes in PATH elements.
4770 case $as_dir/ in #((
4771 ./ | .// | /[cC]/* | \
4772 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
4773 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
4774 /usr/ucb/* ) ;;
4776 # OSF1 and SCO ODT 3.0 have their own names for install.
4777 # Don't use installbsd from OSF since it installs stuff as root
4778 # by default.
4779 for ac_prog in ginstall scoinst install; do
4780 for ac_exec_ext in '' $ac_executable_extensions; do
4781 if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
4782 if test $ac_prog = install &&
4783 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
4784 # AIX install. It has an incompatible calling convention.
4786 elif test $ac_prog = install &&
4787 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
4788 # program-specific install script used by HP pwplus--don't use.
4790 else
4791 rm -rf conftest.one conftest.two conftest.dir
4792 echo one > conftest.one
4793 echo two > conftest.two
4794 mkdir conftest.dir
4795 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
4796 test -s conftest.one && test -s conftest.two &&
4797 test -s conftest.dir/conftest.one &&
4798 test -s conftest.dir/conftest.two
4799 then
4800 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
4801 break 3
4805 done
4806 done
4808 esac
4810 done
4811 IFS=$as_save_IFS
4813 rm -rf conftest.one conftest.two conftest.dir
4816 if test "${ac_cv_path_install+set}" = set; then
4817 INSTALL=$ac_cv_path_install
4818 else
4819 # As a last resort, use the slow shell script. Don't cache a
4820 # value for INSTALL within a source directory, because that will
4821 # break other packages using the cache if that directory is
4822 # removed, or if the value is a relative name.
4823 INSTALL=$ac_install_sh
4826 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
4827 $as_echo "$INSTALL" >&6; }
4829 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
4830 # It thinks the first close brace ends the variable substitution.
4831 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
4833 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
4835 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
4837 if test -n "$ac_tool_prefix"; then
4838 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
4839 set dummy ${ac_tool_prefix}ar; ac_word=$2
4840 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4841 $as_echo_n "checking for $ac_word... " >&6; }
4842 if ${ac_cv_prog_AR+:} false; then :
4843 $as_echo_n "(cached) " >&6
4844 else
4845 if test -n "$AR"; then
4846 ac_cv_prog_AR="$AR" # Let the user override the test.
4847 else
4848 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4849 for as_dir in $PATH
4851 IFS=$as_save_IFS
4852 test -z "$as_dir" && as_dir=.
4853 for ac_exec_ext in '' $ac_executable_extensions; do
4854 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4855 ac_cv_prog_AR="${ac_tool_prefix}ar"
4856 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4857 break 2
4859 done
4860 done
4861 IFS=$as_save_IFS
4865 AR=$ac_cv_prog_AR
4866 if test -n "$AR"; then
4867 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
4868 $as_echo "$AR" >&6; }
4869 else
4870 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4871 $as_echo "no" >&6; }
4876 if test -z "$ac_cv_prog_AR"; then
4877 ac_ct_AR=$AR
4878 # Extract the first word of "ar", so it can be a program name with args.
4879 set dummy ar; ac_word=$2
4880 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4881 $as_echo_n "checking for $ac_word... " >&6; }
4882 if ${ac_cv_prog_ac_ct_AR+:} false; then :
4883 $as_echo_n "(cached) " >&6
4884 else
4885 if test -n "$ac_ct_AR"; then
4886 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
4887 else
4888 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4889 for as_dir in $PATH
4891 IFS=$as_save_IFS
4892 test -z "$as_dir" && as_dir=.
4893 for ac_exec_ext in '' $ac_executable_extensions; do
4894 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4895 ac_cv_prog_ac_ct_AR="ar"
4896 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4897 break 2
4899 done
4900 done
4901 IFS=$as_save_IFS
4905 ac_ct_AR=$ac_cv_prog_ac_ct_AR
4906 if test -n "$ac_ct_AR"; then
4907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
4908 $as_echo "$ac_ct_AR" >&6; }
4909 else
4910 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4911 $as_echo "no" >&6; }
4914 if test "x$ac_ct_AR" = x; then
4915 AR=""
4916 else
4917 case $cross_compiling:$ac_tool_warned in
4918 yes:)
4919 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4920 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4921 ac_tool_warned=yes ;;
4922 esac
4923 AR=$ac_ct_AR
4925 else
4926 AR="$ac_cv_prog_AR"
4929 if test -n "$ac_tool_prefix"; then
4930 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
4931 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
4932 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4933 $as_echo_n "checking for $ac_word... " >&6; }
4934 if ${ac_cv_prog_RANLIB+:} false; then :
4935 $as_echo_n "(cached) " >&6
4936 else
4937 if test -n "$RANLIB"; then
4938 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
4939 else
4940 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4941 for as_dir in $PATH
4943 IFS=$as_save_IFS
4944 test -z "$as_dir" && as_dir=.
4945 for ac_exec_ext in '' $ac_executable_extensions; do
4946 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4947 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
4948 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4949 break 2
4951 done
4952 done
4953 IFS=$as_save_IFS
4957 RANLIB=$ac_cv_prog_RANLIB
4958 if test -n "$RANLIB"; then
4959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
4960 $as_echo "$RANLIB" >&6; }
4961 else
4962 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4963 $as_echo "no" >&6; }
4968 if test -z "$ac_cv_prog_RANLIB"; then
4969 ac_ct_RANLIB=$RANLIB
4970 # Extract the first word of "ranlib", so it can be a program name with args.
4971 set dummy ranlib; ac_word=$2
4972 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4973 $as_echo_n "checking for $ac_word... " >&6; }
4974 if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
4975 $as_echo_n "(cached) " >&6
4976 else
4977 if test -n "$ac_ct_RANLIB"; then
4978 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
4979 else
4980 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4981 for as_dir in $PATH
4983 IFS=$as_save_IFS
4984 test -z "$as_dir" && as_dir=.
4985 for ac_exec_ext in '' $ac_executable_extensions; do
4986 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4987 ac_cv_prog_ac_ct_RANLIB="ranlib"
4988 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4989 break 2
4991 done
4992 done
4993 IFS=$as_save_IFS
4997 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
4998 if test -n "$ac_ct_RANLIB"; then
4999 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
5000 $as_echo "$ac_ct_RANLIB" >&6; }
5001 else
5002 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5003 $as_echo "no" >&6; }
5006 if test "x$ac_ct_RANLIB" = x; then
5007 RANLIB=":"
5008 else
5009 case $cross_compiling:$ac_tool_warned in
5010 yes:)
5011 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5012 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5013 ac_tool_warned=yes ;;
5014 esac
5015 RANLIB=$ac_ct_RANLIB
5017 else
5018 RANLIB="$ac_cv_prog_RANLIB"
5022 test "$program_prefix" != NONE &&
5023 program_transform_name="s&^&$program_prefix&;$program_transform_name"
5024 # Use a double $ so make ignores it.
5025 test "$program_suffix" != NONE &&
5026 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
5027 # Double any \ or $.
5028 # By default was `s,x,x', remove it if useless.
5029 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
5030 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
5033 # We require a C++17 compiler. Check if one is available, and if
5034 # necessary, set CXX_DIALECT to some -std=xxx switch.
5036 ax_cxx_compile_alternatives="17 1z" ax_cxx_compile_cxx17_required=true
5037 ac_ext=cpp
5038 ac_cpp='$CXXCPP $CPPFLAGS'
5039 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5040 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5041 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5042 CXX_DIALECT=""
5043 ac_success=no
5045 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++17 features by default" >&5
5046 $as_echo_n "checking whether $CXX supports C++17 features by default... " >&6; }
5047 if ${ax_cv_cxx_compile_cxx17+:} false; then :
5048 $as_echo_n "(cached) " >&6
5049 else
5050 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5051 /* end confdefs.h. */
5054 // If the compiler admits that it is not ready for C++11, why torture it?
5055 // Hopefully, this will speed up the test.
5057 #ifndef __cplusplus
5059 #error "This is not a C++ compiler"
5061 // MSVC always sets __cplusplus to 199711L in older versions; newer versions
5062 // only set it correctly if /Zc:__cplusplus is specified as well as a
5063 // /std:c++NN switch:
5064 // https://devblogs.microsoft.com/cppblog/msvc-now-correctly-reports-__cplusplus/
5065 #elif __cplusplus < 201103L && !defined _MSC_VER
5067 #error "This is not a C++11 compiler"
5069 #else
5071 namespace cxx11
5074 namespace test_static_assert
5077 template <typename T>
5078 struct check
5080 static_assert(sizeof(int) <= sizeof(T), "not big enough");
5085 namespace test_final_override
5088 struct Base
5090 virtual ~Base() {}
5091 virtual void f() {}
5094 struct Derived : public Base
5096 virtual ~Derived() override {}
5097 virtual void f() override {}
5102 namespace test_double_right_angle_brackets
5105 template < typename T >
5106 struct check {};
5108 typedef check<void> single_type;
5109 typedef check<check<void>> double_type;
5110 typedef check<check<check<void>>> triple_type;
5111 typedef check<check<check<check<void>>>> quadruple_type;
5115 namespace test_decltype
5121 int a = 1;
5122 decltype(a) b = 2;
5123 return a + b;
5128 namespace test_type_deduction
5131 template < typename T1, typename T2 >
5132 struct is_same
5134 static const bool value = false;
5137 template < typename T >
5138 struct is_same<T, T>
5140 static const bool value = true;
5143 template < typename T1, typename T2 >
5144 auto
5145 add(T1 a1, T2 a2) -> decltype(a1 + a2)
5147 return a1 + a2;
5151 test(const int c, volatile int v)
5153 static_assert(is_same<int, decltype(0)>::value == true, "");
5154 static_assert(is_same<int, decltype(c)>::value == false, "");
5155 static_assert(is_same<int, decltype(v)>::value == false, "");
5156 auto ac = c;
5157 auto av = v;
5158 auto sumi = ac + av + 'x';
5159 auto sumf = ac + av + 1.0;
5160 static_assert(is_same<int, decltype(ac)>::value == true, "");
5161 static_assert(is_same<int, decltype(av)>::value == true, "");
5162 static_assert(is_same<int, decltype(sumi)>::value == true, "");
5163 static_assert(is_same<int, decltype(sumf)>::value == false, "");
5164 static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
5165 return (sumf > 0.0) ? sumi : add(c, v);
5170 namespace test_noexcept
5173 int f() { return 0; }
5174 int g() noexcept { return 0; }
5176 static_assert(noexcept(f()) == false, "");
5177 static_assert(noexcept(g()) == true, "");
5181 namespace test_constexpr
5184 template < typename CharT >
5185 unsigned long constexpr
5186 strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
5188 return *s ? strlen_c_r(s + 1, acc + 1) : acc;
5191 template < typename CharT >
5192 unsigned long constexpr
5193 strlen_c(const CharT *const s) noexcept
5195 return strlen_c_r(s, 0UL);
5198 static_assert(strlen_c("") == 0UL, "");
5199 static_assert(strlen_c("1") == 1UL, "");
5200 static_assert(strlen_c("example") == 7UL, "");
5201 static_assert(strlen_c("another\0example") == 7UL, "");
5205 namespace test_rvalue_references
5208 template < int N >
5209 struct answer
5211 static constexpr int value = N;
5214 answer<1> f(int&) { return answer<1>(); }
5215 answer<2> f(const int&) { return answer<2>(); }
5216 answer<3> f(int&&) { return answer<3>(); }
5218 void
5219 test()
5221 int i = 0;
5222 const int c = 0;
5223 static_assert(decltype(f(i))::value == 1, "");
5224 static_assert(decltype(f(c))::value == 2, "");
5225 static_assert(decltype(f(0))::value == 3, "");
5230 namespace test_uniform_initialization
5233 struct test
5235 static const int zero {};
5236 static const int one {1};
5239 static_assert(test::zero == 0, "");
5240 static_assert(test::one == 1, "");
5244 namespace test_lambdas
5247 void
5248 test1()
5250 auto lambda1 = [](){};
5251 auto lambda2 = lambda1;
5252 lambda1();
5253 lambda2();
5257 test2()
5259 auto a = [](int i, int j){ return i + j; }(1, 2);
5260 auto b = []() -> int { return '0'; }();
5261 auto c = [=](){ return a + b; }();
5262 auto d = [&](){ return c; }();
5263 auto e = [a, &b](int x) mutable {
5264 const auto identity = [](int y){ return y; };
5265 for (auto i = 0; i < a; ++i)
5266 a += b--;
5267 return x + identity(a + b);
5268 }(0);
5269 return a + b + c + d + e;
5273 test3()
5275 const auto nullary = [](){ return 0; };
5276 const auto unary = [](int x){ return x; };
5277 using nullary_t = decltype(nullary);
5278 using unary_t = decltype(unary);
5279 const auto higher1st = [](nullary_t f){ return f(); };
5280 const auto higher2nd = [unary](nullary_t f1){
5281 return [unary, f1](unary_t f2){ return f2(unary(f1())); };
5283 return higher1st(nullary) + higher2nd(nullary)(unary);
5288 namespace test_variadic_templates
5291 template <int...>
5292 struct sum;
5294 template <int N0, int... N1toN>
5295 struct sum<N0, N1toN...>
5297 static constexpr auto value = N0 + sum<N1toN...>::value;
5300 template <>
5301 struct sum<>
5303 static constexpr auto value = 0;
5306 static_assert(sum<>::value == 0, "");
5307 static_assert(sum<1>::value == 1, "");
5308 static_assert(sum<23>::value == 23, "");
5309 static_assert(sum<1, 2>::value == 3, "");
5310 static_assert(sum<5, 5, 11>::value == 21, "");
5311 static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
5315 // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
5316 // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
5317 // because of this.
5318 namespace test_template_alias_sfinae
5321 struct foo {};
5323 template<typename T>
5324 using member = typename T::member_type;
5326 template<typename T>
5327 void func(...) {}
5329 template<typename T>
5330 void func(member<T>*) {}
5332 void test();
5334 void test() { func<foo>(0); }
5338 } // namespace cxx11
5340 #endif // __cplusplus >= 201103L
5345 // If the compiler admits that it is not ready for C++14, why torture it?
5346 // Hopefully, this will speed up the test.
5348 #ifndef __cplusplus
5350 #error "This is not a C++ compiler"
5352 #elif __cplusplus < 201402L && !defined _MSC_VER
5354 #error "This is not a C++14 compiler"
5356 #else
5358 namespace cxx14
5361 namespace test_polymorphic_lambdas
5365 test()
5367 const auto lambda = [](auto&&... args){
5368 const auto istiny = [](auto x){
5369 return (sizeof(x) == 1UL) ? 1 : 0;
5371 const int aretiny[] = { istiny(args)... };
5372 return aretiny[0];
5374 return lambda(1, 1L, 1.0f, '1');
5379 namespace test_binary_literals
5382 constexpr auto ivii = 0b0000000000101010;
5383 static_assert(ivii == 42, "wrong value");
5387 namespace test_generalized_constexpr
5390 template < typename CharT >
5391 constexpr unsigned long
5392 strlen_c(const CharT *const s) noexcept
5394 auto length = 0UL;
5395 for (auto p = s; *p; ++p)
5396 ++length;
5397 return length;
5400 static_assert(strlen_c("") == 0UL, "");
5401 static_assert(strlen_c("x") == 1UL, "");
5402 static_assert(strlen_c("test") == 4UL, "");
5403 static_assert(strlen_c("another\0test") == 7UL, "");
5407 namespace test_lambda_init_capture
5411 test()
5413 auto x = 0;
5414 const auto lambda1 = [a = x](int b){ return a + b; };
5415 const auto lambda2 = [a = lambda1(x)](){ return a; };
5416 return lambda2();
5421 namespace test_digit_separators
5424 constexpr auto ten_million = 100'000'000;
5425 static_assert(ten_million == 100000000, "");
5429 namespace test_return_type_deduction
5432 auto f(int& x) { return x; }
5433 decltype(auto) g(int& x) { return x; }
5435 template < typename T1, typename T2 >
5436 struct is_same
5438 static constexpr auto value = false;
5441 template < typename T >
5442 struct is_same<T, T>
5444 static constexpr auto value = true;
5448 test()
5450 auto x = 0;
5451 static_assert(is_same<int, decltype(f(x))>::value, "");
5452 static_assert(is_same<int&, decltype(g(x))>::value, "");
5453 return x;
5458 } // namespace cxx14
5460 #endif // __cplusplus >= 201402L
5465 // If the compiler admits that it is not ready for C++17, why torture it?
5466 // Hopefully, this will speed up the test.
5468 #ifndef __cplusplus
5470 #error "This is not a C++ compiler"
5472 #elif __cplusplus < 201703L && !defined _MSC_VER
5474 #error "This is not a C++17 compiler"
5476 #else
5478 #include <initializer_list>
5479 #include <utility>
5480 #include <type_traits>
5482 namespace cxx17
5485 namespace test_constexpr_lambdas
5488 constexpr int foo = [](){return 42;}();
5492 namespace test::nested_namespace::definitions
5497 namespace test_fold_expression
5500 template<typename... Args>
5501 int multiply(Args... args)
5503 return (args * ... * 1);
5506 template<typename... Args>
5507 bool all(Args... args)
5509 return (args && ...);
5514 namespace test_extended_static_assert
5517 static_assert (true);
5521 namespace test_auto_brace_init_list
5524 auto foo = {5};
5525 auto bar {5};
5527 static_assert(std::is_same<std::initializer_list<int>, decltype(foo)>::value);
5528 static_assert(std::is_same<int, decltype(bar)>::value);
5531 namespace test_typename_in_template_template_parameter
5534 template<template<typename> typename X> struct D;
5538 namespace test_fallthrough_nodiscard_maybe_unused_attributes
5541 int f1()
5543 return 42;
5546 [[nodiscard]] int f2()
5548 [[maybe_unused]] auto unused = f1();
5550 switch (f1())
5552 case 17:
5553 f1();
5554 [[fallthrough]];
5555 case 42:
5556 f1();
5558 return f1();
5563 namespace test_extended_aggregate_initialization
5566 struct base1
5568 int b1, b2 = 42;
5571 struct base2
5573 base2() {
5574 b3 = 42;
5576 int b3;
5579 struct derived : base1, base2
5581 int d;
5584 derived d1 {{1, 2}, {}, 4}; // full initialization
5585 derived d2 {{}, {}, 4}; // value-initialized bases
5589 namespace test_general_range_based_for_loop
5592 struct iter
5594 int i;
5596 int& operator* ()
5598 return i;
5601 const int& operator* () const
5603 return i;
5606 iter& operator++()
5608 ++i;
5609 return *this;
5613 struct sentinel
5615 int i;
5618 bool operator== (const iter& i, const sentinel& s)
5620 return i.i == s.i;
5623 bool operator!= (const iter& i, const sentinel& s)
5625 return !(i == s);
5628 struct range
5630 iter begin() const
5632 return {0};
5635 sentinel end() const
5637 return {5};
5641 void f()
5643 range r {};
5645 for (auto i : r)
5647 [[maybe_unused]] auto v = i;
5653 namespace test_lambda_capture_asterisk_this_by_value
5656 struct t
5658 int i;
5659 int foo()
5661 return [*this]()
5663 return i;
5664 }();
5670 namespace test_enum_class_construction
5673 enum class byte : unsigned char
5676 byte foo {42};
5680 namespace test_constexpr_if
5683 template <bool cond>
5684 int f ()
5686 if constexpr(cond)
5688 return 13;
5690 else
5692 return 42;
5698 namespace test_selection_statement_with_initializer
5701 int f()
5703 return 13;
5706 int f2()
5708 if (auto i = f(); i > 0)
5710 return 3;
5713 switch (auto i = f(); i + 4)
5715 case 17:
5716 return 2;
5718 default:
5719 return 1;
5725 namespace test_template_argument_deduction_for_class_templates
5728 template <typename T1, typename T2>
5729 struct pair
5731 pair (T1 p1, T2 p2)
5732 : m1 {p1},
5733 m2 {p2}
5736 T1 m1;
5737 T2 m2;
5740 void f()
5742 [[maybe_unused]] auto p = pair{13, 42u};
5747 namespace test_non_type_auto_template_parameters
5750 template <auto n>
5751 struct B
5754 B<5> b1;
5755 B<'a'> b2;
5759 namespace test_structured_bindings
5762 int arr[2] = { 1, 2 };
5763 std::pair<int, int> pr = { 1, 2 };
5765 auto f1() -> int(&)[2]
5767 return arr;
5770 auto f2() -> std::pair<int, int>&
5772 return pr;
5775 struct S
5777 int x1 : 2;
5778 volatile double y1;
5781 S f3()
5783 return {};
5786 auto [ x1, y1 ] = f1();
5787 auto& [ xr1, yr1 ] = f1();
5788 auto [ x2, y2 ] = f2();
5789 auto& [ xr2, yr2 ] = f2();
5790 const auto [ x3, y3 ] = f3();
5794 namespace test_exception_spec_type_system
5797 struct Good {};
5798 struct Bad {};
5800 void g1() noexcept;
5801 void g2();
5803 template<typename T>
5805 f(T*, T*);
5807 template<typename T1, typename T2>
5808 Good
5809 f(T1*, T2*);
5811 static_assert (std::is_same_v<Good, decltype(f(g1, g2))>);
5815 namespace test_inline_variables
5818 template<class T> void f(T)
5821 template<class T> inline T g(T)
5823 return T{};
5826 template<> inline void f<>(int)
5829 template<> int g<>(int)
5831 return 5;
5836 } // namespace cxx17
5838 #endif // __cplusplus < 201703L && !defined _MSC_VER
5842 _ACEOF
5843 if ac_fn_cxx_try_compile "$LINENO"; then :
5844 ax_cv_cxx_compile_cxx17=yes
5845 else
5846 ax_cv_cxx_compile_cxx17=no
5848 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5850 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_cxx_compile_cxx17" >&5
5851 $as_echo "$ax_cv_cxx_compile_cxx17" >&6; }
5852 if test x$ax_cv_cxx_compile_cxx17 = xyes; then
5853 ac_success=yes
5856 if test x$ac_success = xno; then
5857 for alternative in ${ax_cxx_compile_alternatives}; do
5858 switch="-std=gnu++${alternative}"
5859 cachevar=`$as_echo "ax_cv_cxx_compile_cxx17_$switch" | $as_tr_sh`
5860 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++17 features with $switch" >&5
5861 $as_echo_n "checking whether $CXX supports C++17 features with $switch... " >&6; }
5862 if eval \${$cachevar+:} false; then :
5863 $as_echo_n "(cached) " >&6
5864 else
5865 ac_save_CXX="$CXX"
5866 CXX="$CXX $switch"
5867 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5868 /* end confdefs.h. */
5871 // If the compiler admits that it is not ready for C++11, why torture it?
5872 // Hopefully, this will speed up the test.
5874 #ifndef __cplusplus
5876 #error "This is not a C++ compiler"
5878 // MSVC always sets __cplusplus to 199711L in older versions; newer versions
5879 // only set it correctly if /Zc:__cplusplus is specified as well as a
5880 // /std:c++NN switch:
5881 // https://devblogs.microsoft.com/cppblog/msvc-now-correctly-reports-__cplusplus/
5882 #elif __cplusplus < 201103L && !defined _MSC_VER
5884 #error "This is not a C++11 compiler"
5886 #else
5888 namespace cxx11
5891 namespace test_static_assert
5894 template <typename T>
5895 struct check
5897 static_assert(sizeof(int) <= sizeof(T), "not big enough");
5902 namespace test_final_override
5905 struct Base
5907 virtual ~Base() {}
5908 virtual void f() {}
5911 struct Derived : public Base
5913 virtual ~Derived() override {}
5914 virtual void f() override {}
5919 namespace test_double_right_angle_brackets
5922 template < typename T >
5923 struct check {};
5925 typedef check<void> single_type;
5926 typedef check<check<void>> double_type;
5927 typedef check<check<check<void>>> triple_type;
5928 typedef check<check<check<check<void>>>> quadruple_type;
5932 namespace test_decltype
5938 int a = 1;
5939 decltype(a) b = 2;
5940 return a + b;
5945 namespace test_type_deduction
5948 template < typename T1, typename T2 >
5949 struct is_same
5951 static const bool value = false;
5954 template < typename T >
5955 struct is_same<T, T>
5957 static const bool value = true;
5960 template < typename T1, typename T2 >
5961 auto
5962 add(T1 a1, T2 a2) -> decltype(a1 + a2)
5964 return a1 + a2;
5968 test(const int c, volatile int v)
5970 static_assert(is_same<int, decltype(0)>::value == true, "");
5971 static_assert(is_same<int, decltype(c)>::value == false, "");
5972 static_assert(is_same<int, decltype(v)>::value == false, "");
5973 auto ac = c;
5974 auto av = v;
5975 auto sumi = ac + av + 'x';
5976 auto sumf = ac + av + 1.0;
5977 static_assert(is_same<int, decltype(ac)>::value == true, "");
5978 static_assert(is_same<int, decltype(av)>::value == true, "");
5979 static_assert(is_same<int, decltype(sumi)>::value == true, "");
5980 static_assert(is_same<int, decltype(sumf)>::value == false, "");
5981 static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
5982 return (sumf > 0.0) ? sumi : add(c, v);
5987 namespace test_noexcept
5990 int f() { return 0; }
5991 int g() noexcept { return 0; }
5993 static_assert(noexcept(f()) == false, "");
5994 static_assert(noexcept(g()) == true, "");
5998 namespace test_constexpr
6001 template < typename CharT >
6002 unsigned long constexpr
6003 strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
6005 return *s ? strlen_c_r(s + 1, acc + 1) : acc;
6008 template < typename CharT >
6009 unsigned long constexpr
6010 strlen_c(const CharT *const s) noexcept
6012 return strlen_c_r(s, 0UL);
6015 static_assert(strlen_c("") == 0UL, "");
6016 static_assert(strlen_c("1") == 1UL, "");
6017 static_assert(strlen_c("example") == 7UL, "");
6018 static_assert(strlen_c("another\0example") == 7UL, "");
6022 namespace test_rvalue_references
6025 template < int N >
6026 struct answer
6028 static constexpr int value = N;
6031 answer<1> f(int&) { return answer<1>(); }
6032 answer<2> f(const int&) { return answer<2>(); }
6033 answer<3> f(int&&) { return answer<3>(); }
6035 void
6036 test()
6038 int i = 0;
6039 const int c = 0;
6040 static_assert(decltype(f(i))::value == 1, "");
6041 static_assert(decltype(f(c))::value == 2, "");
6042 static_assert(decltype(f(0))::value == 3, "");
6047 namespace test_uniform_initialization
6050 struct test
6052 static const int zero {};
6053 static const int one {1};
6056 static_assert(test::zero == 0, "");
6057 static_assert(test::one == 1, "");
6061 namespace test_lambdas
6064 void
6065 test1()
6067 auto lambda1 = [](){};
6068 auto lambda2 = lambda1;
6069 lambda1();
6070 lambda2();
6074 test2()
6076 auto a = [](int i, int j){ return i + j; }(1, 2);
6077 auto b = []() -> int { return '0'; }();
6078 auto c = [=](){ return a + b; }();
6079 auto d = [&](){ return c; }();
6080 auto e = [a, &b](int x) mutable {
6081 const auto identity = [](int y){ return y; };
6082 for (auto i = 0; i < a; ++i)
6083 a += b--;
6084 return x + identity(a + b);
6085 }(0);
6086 return a + b + c + d + e;
6090 test3()
6092 const auto nullary = [](){ return 0; };
6093 const auto unary = [](int x){ return x; };
6094 using nullary_t = decltype(nullary);
6095 using unary_t = decltype(unary);
6096 const auto higher1st = [](nullary_t f){ return f(); };
6097 const auto higher2nd = [unary](nullary_t f1){
6098 return [unary, f1](unary_t f2){ return f2(unary(f1())); };
6100 return higher1st(nullary) + higher2nd(nullary)(unary);
6105 namespace test_variadic_templates
6108 template <int...>
6109 struct sum;
6111 template <int N0, int... N1toN>
6112 struct sum<N0, N1toN...>
6114 static constexpr auto value = N0 + sum<N1toN...>::value;
6117 template <>
6118 struct sum<>
6120 static constexpr auto value = 0;
6123 static_assert(sum<>::value == 0, "");
6124 static_assert(sum<1>::value == 1, "");
6125 static_assert(sum<23>::value == 23, "");
6126 static_assert(sum<1, 2>::value == 3, "");
6127 static_assert(sum<5, 5, 11>::value == 21, "");
6128 static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
6132 // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
6133 // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
6134 // because of this.
6135 namespace test_template_alias_sfinae
6138 struct foo {};
6140 template<typename T>
6141 using member = typename T::member_type;
6143 template<typename T>
6144 void func(...) {}
6146 template<typename T>
6147 void func(member<T>*) {}
6149 void test();
6151 void test() { func<foo>(0); }
6155 } // namespace cxx11
6157 #endif // __cplusplus >= 201103L
6162 // If the compiler admits that it is not ready for C++14, why torture it?
6163 // Hopefully, this will speed up the test.
6165 #ifndef __cplusplus
6167 #error "This is not a C++ compiler"
6169 #elif __cplusplus < 201402L && !defined _MSC_VER
6171 #error "This is not a C++14 compiler"
6173 #else
6175 namespace cxx14
6178 namespace test_polymorphic_lambdas
6182 test()
6184 const auto lambda = [](auto&&... args){
6185 const auto istiny = [](auto x){
6186 return (sizeof(x) == 1UL) ? 1 : 0;
6188 const int aretiny[] = { istiny(args)... };
6189 return aretiny[0];
6191 return lambda(1, 1L, 1.0f, '1');
6196 namespace test_binary_literals
6199 constexpr auto ivii = 0b0000000000101010;
6200 static_assert(ivii == 42, "wrong value");
6204 namespace test_generalized_constexpr
6207 template < typename CharT >
6208 constexpr unsigned long
6209 strlen_c(const CharT *const s) noexcept
6211 auto length = 0UL;
6212 for (auto p = s; *p; ++p)
6213 ++length;
6214 return length;
6217 static_assert(strlen_c("") == 0UL, "");
6218 static_assert(strlen_c("x") == 1UL, "");
6219 static_assert(strlen_c("test") == 4UL, "");
6220 static_assert(strlen_c("another\0test") == 7UL, "");
6224 namespace test_lambda_init_capture
6228 test()
6230 auto x = 0;
6231 const auto lambda1 = [a = x](int b){ return a + b; };
6232 const auto lambda2 = [a = lambda1(x)](){ return a; };
6233 return lambda2();
6238 namespace test_digit_separators
6241 constexpr auto ten_million = 100'000'000;
6242 static_assert(ten_million == 100000000, "");
6246 namespace test_return_type_deduction
6249 auto f(int& x) { return x; }
6250 decltype(auto) g(int& x) { return x; }
6252 template < typename T1, typename T2 >
6253 struct is_same
6255 static constexpr auto value = false;
6258 template < typename T >
6259 struct is_same<T, T>
6261 static constexpr auto value = true;
6265 test()
6267 auto x = 0;
6268 static_assert(is_same<int, decltype(f(x))>::value, "");
6269 static_assert(is_same<int&, decltype(g(x))>::value, "");
6270 return x;
6275 } // namespace cxx14
6277 #endif // __cplusplus >= 201402L
6282 // If the compiler admits that it is not ready for C++17, why torture it?
6283 // Hopefully, this will speed up the test.
6285 #ifndef __cplusplus
6287 #error "This is not a C++ compiler"
6289 #elif __cplusplus < 201703L && !defined _MSC_VER
6291 #error "This is not a C++17 compiler"
6293 #else
6295 #include <initializer_list>
6296 #include <utility>
6297 #include <type_traits>
6299 namespace cxx17
6302 namespace test_constexpr_lambdas
6305 constexpr int foo = [](){return 42;}();
6309 namespace test::nested_namespace::definitions
6314 namespace test_fold_expression
6317 template<typename... Args>
6318 int multiply(Args... args)
6320 return (args * ... * 1);
6323 template<typename... Args>
6324 bool all(Args... args)
6326 return (args && ...);
6331 namespace test_extended_static_assert
6334 static_assert (true);
6338 namespace test_auto_brace_init_list
6341 auto foo = {5};
6342 auto bar {5};
6344 static_assert(std::is_same<std::initializer_list<int>, decltype(foo)>::value);
6345 static_assert(std::is_same<int, decltype(bar)>::value);
6348 namespace test_typename_in_template_template_parameter
6351 template<template<typename> typename X> struct D;
6355 namespace test_fallthrough_nodiscard_maybe_unused_attributes
6358 int f1()
6360 return 42;
6363 [[nodiscard]] int f2()
6365 [[maybe_unused]] auto unused = f1();
6367 switch (f1())
6369 case 17:
6370 f1();
6371 [[fallthrough]];
6372 case 42:
6373 f1();
6375 return f1();
6380 namespace test_extended_aggregate_initialization
6383 struct base1
6385 int b1, b2 = 42;
6388 struct base2
6390 base2() {
6391 b3 = 42;
6393 int b3;
6396 struct derived : base1, base2
6398 int d;
6401 derived d1 {{1, 2}, {}, 4}; // full initialization
6402 derived d2 {{}, {}, 4}; // value-initialized bases
6406 namespace test_general_range_based_for_loop
6409 struct iter
6411 int i;
6413 int& operator* ()
6415 return i;
6418 const int& operator* () const
6420 return i;
6423 iter& operator++()
6425 ++i;
6426 return *this;
6430 struct sentinel
6432 int i;
6435 bool operator== (const iter& i, const sentinel& s)
6437 return i.i == s.i;
6440 bool operator!= (const iter& i, const sentinel& s)
6442 return !(i == s);
6445 struct range
6447 iter begin() const
6449 return {0};
6452 sentinel end() const
6454 return {5};
6458 void f()
6460 range r {};
6462 for (auto i : r)
6464 [[maybe_unused]] auto v = i;
6470 namespace test_lambda_capture_asterisk_this_by_value
6473 struct t
6475 int i;
6476 int foo()
6478 return [*this]()
6480 return i;
6481 }();
6487 namespace test_enum_class_construction
6490 enum class byte : unsigned char
6493 byte foo {42};
6497 namespace test_constexpr_if
6500 template <bool cond>
6501 int f ()
6503 if constexpr(cond)
6505 return 13;
6507 else
6509 return 42;
6515 namespace test_selection_statement_with_initializer
6518 int f()
6520 return 13;
6523 int f2()
6525 if (auto i = f(); i > 0)
6527 return 3;
6530 switch (auto i = f(); i + 4)
6532 case 17:
6533 return 2;
6535 default:
6536 return 1;
6542 namespace test_template_argument_deduction_for_class_templates
6545 template <typename T1, typename T2>
6546 struct pair
6548 pair (T1 p1, T2 p2)
6549 : m1 {p1},
6550 m2 {p2}
6553 T1 m1;
6554 T2 m2;
6557 void f()
6559 [[maybe_unused]] auto p = pair{13, 42u};
6564 namespace test_non_type_auto_template_parameters
6567 template <auto n>
6568 struct B
6571 B<5> b1;
6572 B<'a'> b2;
6576 namespace test_structured_bindings
6579 int arr[2] = { 1, 2 };
6580 std::pair<int, int> pr = { 1, 2 };
6582 auto f1() -> int(&)[2]
6584 return arr;
6587 auto f2() -> std::pair<int, int>&
6589 return pr;
6592 struct S
6594 int x1 : 2;
6595 volatile double y1;
6598 S f3()
6600 return {};
6603 auto [ x1, y1 ] = f1();
6604 auto& [ xr1, yr1 ] = f1();
6605 auto [ x2, y2 ] = f2();
6606 auto& [ xr2, yr2 ] = f2();
6607 const auto [ x3, y3 ] = f3();
6611 namespace test_exception_spec_type_system
6614 struct Good {};
6615 struct Bad {};
6617 void g1() noexcept;
6618 void g2();
6620 template<typename T>
6622 f(T*, T*);
6624 template<typename T1, typename T2>
6625 Good
6626 f(T1*, T2*);
6628 static_assert (std::is_same_v<Good, decltype(f(g1, g2))>);
6632 namespace test_inline_variables
6635 template<class T> void f(T)
6638 template<class T> inline T g(T)
6640 return T{};
6643 template<> inline void f<>(int)
6646 template<> int g<>(int)
6648 return 5;
6653 } // namespace cxx17
6655 #endif // __cplusplus < 201703L && !defined _MSC_VER
6659 _ACEOF
6660 if ac_fn_cxx_try_compile "$LINENO"; then :
6661 eval $cachevar=yes
6662 else
6663 eval $cachevar=no
6665 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6666 CXX="$ac_save_CXX"
6668 eval ac_res=\$$cachevar
6669 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
6670 $as_echo "$ac_res" >&6; }
6671 if eval test x\$$cachevar = xyes; then
6672 CXX_DIALECT="$switch"
6673 CXX="$CXX $switch"
6674 if test -n "$CXXCPP" ; then
6675 CXXCPP="$CXXCPP $switch"
6677 ac_success=yes
6678 break
6680 done
6683 if test x$ac_success = xno; then
6684 for alternative in ${ax_cxx_compile_alternatives}; do
6685 for switch in -std=c++${alternative} +std=c++${alternative} "-h std=c++${alternative}" MSVC; do
6686 if test x"$switch" = xMSVC; then
6687 switch=-std:c++${alternative}
6688 cachevar=`$as_echo "ax_cv_cxx_compile_cxx17_${switch}_MSVC" | $as_tr_sh`
6689 else
6690 cachevar=`$as_echo "ax_cv_cxx_compile_cxx17_$switch" | $as_tr_sh`
6692 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++17 features with $switch" >&5
6693 $as_echo_n "checking whether $CXX supports C++17 features with $switch... " >&6; }
6694 if eval \${$cachevar+:} false; then :
6695 $as_echo_n "(cached) " >&6
6696 else
6697 ac_save_CXX="$CXX"
6698 CXX="$CXX $switch"
6699 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6700 /* end confdefs.h. */
6703 // If the compiler admits that it is not ready for C++11, why torture it?
6704 // Hopefully, this will speed up the test.
6706 #ifndef __cplusplus
6708 #error "This is not a C++ compiler"
6710 // MSVC always sets __cplusplus to 199711L in older versions; newer versions
6711 // only set it correctly if /Zc:__cplusplus is specified as well as a
6712 // /std:c++NN switch:
6713 // https://devblogs.microsoft.com/cppblog/msvc-now-correctly-reports-__cplusplus/
6714 #elif __cplusplus < 201103L && !defined _MSC_VER
6716 #error "This is not a C++11 compiler"
6718 #else
6720 namespace cxx11
6723 namespace test_static_assert
6726 template <typename T>
6727 struct check
6729 static_assert(sizeof(int) <= sizeof(T), "not big enough");
6734 namespace test_final_override
6737 struct Base
6739 virtual ~Base() {}
6740 virtual void f() {}
6743 struct Derived : public Base
6745 virtual ~Derived() override {}
6746 virtual void f() override {}
6751 namespace test_double_right_angle_brackets
6754 template < typename T >
6755 struct check {};
6757 typedef check<void> single_type;
6758 typedef check<check<void>> double_type;
6759 typedef check<check<check<void>>> triple_type;
6760 typedef check<check<check<check<void>>>> quadruple_type;
6764 namespace test_decltype
6770 int a = 1;
6771 decltype(a) b = 2;
6772 return a + b;
6777 namespace test_type_deduction
6780 template < typename T1, typename T2 >
6781 struct is_same
6783 static const bool value = false;
6786 template < typename T >
6787 struct is_same<T, T>
6789 static const bool value = true;
6792 template < typename T1, typename T2 >
6793 auto
6794 add(T1 a1, T2 a2) -> decltype(a1 + a2)
6796 return a1 + a2;
6800 test(const int c, volatile int v)
6802 static_assert(is_same<int, decltype(0)>::value == true, "");
6803 static_assert(is_same<int, decltype(c)>::value == false, "");
6804 static_assert(is_same<int, decltype(v)>::value == false, "");
6805 auto ac = c;
6806 auto av = v;
6807 auto sumi = ac + av + 'x';
6808 auto sumf = ac + av + 1.0;
6809 static_assert(is_same<int, decltype(ac)>::value == true, "");
6810 static_assert(is_same<int, decltype(av)>::value == true, "");
6811 static_assert(is_same<int, decltype(sumi)>::value == true, "");
6812 static_assert(is_same<int, decltype(sumf)>::value == false, "");
6813 static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
6814 return (sumf > 0.0) ? sumi : add(c, v);
6819 namespace test_noexcept
6822 int f() { return 0; }
6823 int g() noexcept { return 0; }
6825 static_assert(noexcept(f()) == false, "");
6826 static_assert(noexcept(g()) == true, "");
6830 namespace test_constexpr
6833 template < typename CharT >
6834 unsigned long constexpr
6835 strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
6837 return *s ? strlen_c_r(s + 1, acc + 1) : acc;
6840 template < typename CharT >
6841 unsigned long constexpr
6842 strlen_c(const CharT *const s) noexcept
6844 return strlen_c_r(s, 0UL);
6847 static_assert(strlen_c("") == 0UL, "");
6848 static_assert(strlen_c("1") == 1UL, "");
6849 static_assert(strlen_c("example") == 7UL, "");
6850 static_assert(strlen_c("another\0example") == 7UL, "");
6854 namespace test_rvalue_references
6857 template < int N >
6858 struct answer
6860 static constexpr int value = N;
6863 answer<1> f(int&) { return answer<1>(); }
6864 answer<2> f(const int&) { return answer<2>(); }
6865 answer<3> f(int&&) { return answer<3>(); }
6867 void
6868 test()
6870 int i = 0;
6871 const int c = 0;
6872 static_assert(decltype(f(i))::value == 1, "");
6873 static_assert(decltype(f(c))::value == 2, "");
6874 static_assert(decltype(f(0))::value == 3, "");
6879 namespace test_uniform_initialization
6882 struct test
6884 static const int zero {};
6885 static const int one {1};
6888 static_assert(test::zero == 0, "");
6889 static_assert(test::one == 1, "");
6893 namespace test_lambdas
6896 void
6897 test1()
6899 auto lambda1 = [](){};
6900 auto lambda2 = lambda1;
6901 lambda1();
6902 lambda2();
6906 test2()
6908 auto a = [](int i, int j){ return i + j; }(1, 2);
6909 auto b = []() -> int { return '0'; }();
6910 auto c = [=](){ return a + b; }();
6911 auto d = [&](){ return c; }();
6912 auto e = [a, &b](int x) mutable {
6913 const auto identity = [](int y){ return y; };
6914 for (auto i = 0; i < a; ++i)
6915 a += b--;
6916 return x + identity(a + b);
6917 }(0);
6918 return a + b + c + d + e;
6922 test3()
6924 const auto nullary = [](){ return 0; };
6925 const auto unary = [](int x){ return x; };
6926 using nullary_t = decltype(nullary);
6927 using unary_t = decltype(unary);
6928 const auto higher1st = [](nullary_t f){ return f(); };
6929 const auto higher2nd = [unary](nullary_t f1){
6930 return [unary, f1](unary_t f2){ return f2(unary(f1())); };
6932 return higher1st(nullary) + higher2nd(nullary)(unary);
6937 namespace test_variadic_templates
6940 template <int...>
6941 struct sum;
6943 template <int N0, int... N1toN>
6944 struct sum<N0, N1toN...>
6946 static constexpr auto value = N0 + sum<N1toN...>::value;
6949 template <>
6950 struct sum<>
6952 static constexpr auto value = 0;
6955 static_assert(sum<>::value == 0, "");
6956 static_assert(sum<1>::value == 1, "");
6957 static_assert(sum<23>::value == 23, "");
6958 static_assert(sum<1, 2>::value == 3, "");
6959 static_assert(sum<5, 5, 11>::value == 21, "");
6960 static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
6964 // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
6965 // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
6966 // because of this.
6967 namespace test_template_alias_sfinae
6970 struct foo {};
6972 template<typename T>
6973 using member = typename T::member_type;
6975 template<typename T>
6976 void func(...) {}
6978 template<typename T>
6979 void func(member<T>*) {}
6981 void test();
6983 void test() { func<foo>(0); }
6987 } // namespace cxx11
6989 #endif // __cplusplus >= 201103L
6994 // If the compiler admits that it is not ready for C++14, why torture it?
6995 // Hopefully, this will speed up the test.
6997 #ifndef __cplusplus
6999 #error "This is not a C++ compiler"
7001 #elif __cplusplus < 201402L && !defined _MSC_VER
7003 #error "This is not a C++14 compiler"
7005 #else
7007 namespace cxx14
7010 namespace test_polymorphic_lambdas
7014 test()
7016 const auto lambda = [](auto&&... args){
7017 const auto istiny = [](auto x){
7018 return (sizeof(x) == 1UL) ? 1 : 0;
7020 const int aretiny[] = { istiny(args)... };
7021 return aretiny[0];
7023 return lambda(1, 1L, 1.0f, '1');
7028 namespace test_binary_literals
7031 constexpr auto ivii = 0b0000000000101010;
7032 static_assert(ivii == 42, "wrong value");
7036 namespace test_generalized_constexpr
7039 template < typename CharT >
7040 constexpr unsigned long
7041 strlen_c(const CharT *const s) noexcept
7043 auto length = 0UL;
7044 for (auto p = s; *p; ++p)
7045 ++length;
7046 return length;
7049 static_assert(strlen_c("") == 0UL, "");
7050 static_assert(strlen_c("x") == 1UL, "");
7051 static_assert(strlen_c("test") == 4UL, "");
7052 static_assert(strlen_c("another\0test") == 7UL, "");
7056 namespace test_lambda_init_capture
7060 test()
7062 auto x = 0;
7063 const auto lambda1 = [a = x](int b){ return a + b; };
7064 const auto lambda2 = [a = lambda1(x)](){ return a; };
7065 return lambda2();
7070 namespace test_digit_separators
7073 constexpr auto ten_million = 100'000'000;
7074 static_assert(ten_million == 100000000, "");
7078 namespace test_return_type_deduction
7081 auto f(int& x) { return x; }
7082 decltype(auto) g(int& x) { return x; }
7084 template < typename T1, typename T2 >
7085 struct is_same
7087 static constexpr auto value = false;
7090 template < typename T >
7091 struct is_same<T, T>
7093 static constexpr auto value = true;
7097 test()
7099 auto x = 0;
7100 static_assert(is_same<int, decltype(f(x))>::value, "");
7101 static_assert(is_same<int&, decltype(g(x))>::value, "");
7102 return x;
7107 } // namespace cxx14
7109 #endif // __cplusplus >= 201402L
7114 // If the compiler admits that it is not ready for C++17, why torture it?
7115 // Hopefully, this will speed up the test.
7117 #ifndef __cplusplus
7119 #error "This is not a C++ compiler"
7121 #elif __cplusplus < 201703L && !defined _MSC_VER
7123 #error "This is not a C++17 compiler"
7125 #else
7127 #include <initializer_list>
7128 #include <utility>
7129 #include <type_traits>
7131 namespace cxx17
7134 namespace test_constexpr_lambdas
7137 constexpr int foo = [](){return 42;}();
7141 namespace test::nested_namespace::definitions
7146 namespace test_fold_expression
7149 template<typename... Args>
7150 int multiply(Args... args)
7152 return (args * ... * 1);
7155 template<typename... Args>
7156 bool all(Args... args)
7158 return (args && ...);
7163 namespace test_extended_static_assert
7166 static_assert (true);
7170 namespace test_auto_brace_init_list
7173 auto foo = {5};
7174 auto bar {5};
7176 static_assert(std::is_same<std::initializer_list<int>, decltype(foo)>::value);
7177 static_assert(std::is_same<int, decltype(bar)>::value);
7180 namespace test_typename_in_template_template_parameter
7183 template<template<typename> typename X> struct D;
7187 namespace test_fallthrough_nodiscard_maybe_unused_attributes
7190 int f1()
7192 return 42;
7195 [[nodiscard]] int f2()
7197 [[maybe_unused]] auto unused = f1();
7199 switch (f1())
7201 case 17:
7202 f1();
7203 [[fallthrough]];
7204 case 42:
7205 f1();
7207 return f1();
7212 namespace test_extended_aggregate_initialization
7215 struct base1
7217 int b1, b2 = 42;
7220 struct base2
7222 base2() {
7223 b3 = 42;
7225 int b3;
7228 struct derived : base1, base2
7230 int d;
7233 derived d1 {{1, 2}, {}, 4}; // full initialization
7234 derived d2 {{}, {}, 4}; // value-initialized bases
7238 namespace test_general_range_based_for_loop
7241 struct iter
7243 int i;
7245 int& operator* ()
7247 return i;
7250 const int& operator* () const
7252 return i;
7255 iter& operator++()
7257 ++i;
7258 return *this;
7262 struct sentinel
7264 int i;
7267 bool operator== (const iter& i, const sentinel& s)
7269 return i.i == s.i;
7272 bool operator!= (const iter& i, const sentinel& s)
7274 return !(i == s);
7277 struct range
7279 iter begin() const
7281 return {0};
7284 sentinel end() const
7286 return {5};
7290 void f()
7292 range r {};
7294 for (auto i : r)
7296 [[maybe_unused]] auto v = i;
7302 namespace test_lambda_capture_asterisk_this_by_value
7305 struct t
7307 int i;
7308 int foo()
7310 return [*this]()
7312 return i;
7313 }();
7319 namespace test_enum_class_construction
7322 enum class byte : unsigned char
7325 byte foo {42};
7329 namespace test_constexpr_if
7332 template <bool cond>
7333 int f ()
7335 if constexpr(cond)
7337 return 13;
7339 else
7341 return 42;
7347 namespace test_selection_statement_with_initializer
7350 int f()
7352 return 13;
7355 int f2()
7357 if (auto i = f(); i > 0)
7359 return 3;
7362 switch (auto i = f(); i + 4)
7364 case 17:
7365 return 2;
7367 default:
7368 return 1;
7374 namespace test_template_argument_deduction_for_class_templates
7377 template <typename T1, typename T2>
7378 struct pair
7380 pair (T1 p1, T2 p2)
7381 : m1 {p1},
7382 m2 {p2}
7385 T1 m1;
7386 T2 m2;
7389 void f()
7391 [[maybe_unused]] auto p = pair{13, 42u};
7396 namespace test_non_type_auto_template_parameters
7399 template <auto n>
7400 struct B
7403 B<5> b1;
7404 B<'a'> b2;
7408 namespace test_structured_bindings
7411 int arr[2] = { 1, 2 };
7412 std::pair<int, int> pr = { 1, 2 };
7414 auto f1() -> int(&)[2]
7416 return arr;
7419 auto f2() -> std::pair<int, int>&
7421 return pr;
7424 struct S
7426 int x1 : 2;
7427 volatile double y1;
7430 S f3()
7432 return {};
7435 auto [ x1, y1 ] = f1();
7436 auto& [ xr1, yr1 ] = f1();
7437 auto [ x2, y2 ] = f2();
7438 auto& [ xr2, yr2 ] = f2();
7439 const auto [ x3, y3 ] = f3();
7443 namespace test_exception_spec_type_system
7446 struct Good {};
7447 struct Bad {};
7449 void g1() noexcept;
7450 void g2();
7452 template<typename T>
7454 f(T*, T*);
7456 template<typename T1, typename T2>
7457 Good
7458 f(T1*, T2*);
7460 static_assert (std::is_same_v<Good, decltype(f(g1, g2))>);
7464 namespace test_inline_variables
7467 template<class T> void f(T)
7470 template<class T> inline T g(T)
7472 return T{};
7475 template<> inline void f<>(int)
7478 template<> int g<>(int)
7480 return 5;
7485 } // namespace cxx17
7487 #endif // __cplusplus < 201703L && !defined _MSC_VER
7491 _ACEOF
7492 if ac_fn_cxx_try_compile "$LINENO"; then :
7493 eval $cachevar=yes
7494 else
7495 eval $cachevar=no
7497 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7498 CXX="$ac_save_CXX"
7500 eval ac_res=\$$cachevar
7501 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
7502 $as_echo "$ac_res" >&6; }
7503 if eval test x\$$cachevar = xyes; then
7504 CXX_DIALECT="$switch"
7505 CXX="$CXX $switch"
7506 if test -n "$CXXCPP" ; then
7507 CXXCPP="$CXXCPP $switch"
7509 ac_success=yes
7510 break
7512 done
7513 if test x$ac_success = xyes; then
7514 break
7516 done
7518 ac_ext=c
7519 ac_cpp='$CPP $CPPFLAGS'
7520 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7521 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7522 ac_compiler_gnu=$ac_cv_c_compiler_gnu
7524 if test x$ax_cxx_compile_cxx17_required = xtrue; then
7525 if test x$ac_success = xno; then
7526 as_fn_error $? "*** A compiler with support for C++17 language features is required." "$LINENO" 5
7529 if test x$ac_success = xno; then
7530 HAVE_CXX17=0
7531 { $as_echo "$as_me:${as_lineno-$LINENO}: No compiler with C++17 support was found" >&5
7532 $as_echo "$as_me: No compiler with C++17 support was found" >&6;}
7533 else
7534 HAVE_CXX17=1
7536 $as_echo "#define HAVE_CXX17 1" >>confdefs.h
7543 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
7544 $as_echo_n "checking for ANSI C header files... " >&6; }
7545 if ${ac_cv_header_stdc+:} false; then :
7546 $as_echo_n "(cached) " >&6
7547 else
7548 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7549 /* end confdefs.h. */
7550 #include <stdlib.h>
7551 #include <stdarg.h>
7552 #include <string.h>
7553 #include <float.h>
7556 main ()
7560 return 0;
7562 _ACEOF
7563 if ac_fn_c_try_compile "$LINENO"; then :
7564 ac_cv_header_stdc=yes
7565 else
7566 ac_cv_header_stdc=no
7568 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7570 if test $ac_cv_header_stdc = yes; then
7571 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
7572 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7573 /* end confdefs.h. */
7574 #include <string.h>
7576 _ACEOF
7577 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7578 $EGREP "memchr" >/dev/null 2>&1; then :
7580 else
7581 ac_cv_header_stdc=no
7583 rm -f conftest*
7587 if test $ac_cv_header_stdc = yes; then
7588 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
7589 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7590 /* end confdefs.h. */
7591 #include <stdlib.h>
7593 _ACEOF
7594 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7595 $EGREP "free" >/dev/null 2>&1; then :
7597 else
7598 ac_cv_header_stdc=no
7600 rm -f conftest*
7604 if test $ac_cv_header_stdc = yes; then
7605 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
7606 if test "$cross_compiling" = yes; then :
7608 else
7609 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7610 /* end confdefs.h. */
7611 #include <ctype.h>
7612 #include <stdlib.h>
7613 #if ((' ' & 0x0FF) == 0x020)
7614 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
7615 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
7616 #else
7617 # define ISLOWER(c) \
7618 (('a' <= (c) && (c) <= 'i') \
7619 || ('j' <= (c) && (c) <= 'r') \
7620 || ('s' <= (c) && (c) <= 'z'))
7621 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
7622 #endif
7624 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
7626 main ()
7628 int i;
7629 for (i = 0; i < 256; i++)
7630 if (XOR (islower (i), ISLOWER (i))
7631 || toupper (i) != TOUPPER (i))
7632 return 2;
7633 return 0;
7635 _ACEOF
7636 if ac_fn_c_try_run "$LINENO"; then :
7638 else
7639 ac_cv_header_stdc=no
7641 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7642 conftest.$ac_objext conftest.beam conftest.$ac_ext
7647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
7648 $as_echo "$ac_cv_header_stdc" >&6; }
7649 if test $ac_cv_header_stdc = yes; then
7651 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
7656 ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
7657 if test "x$ac_cv_type_size_t" = xyes; then :
7659 else
7661 cat >>confdefs.h <<_ACEOF
7662 #define size_t unsigned int
7663 _ACEOF
7670 for ac_header in $ac_header_list
7671 do :
7672 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
7673 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
7675 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
7676 cat >>confdefs.h <<_ACEOF
7677 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
7678 _ACEOF
7682 done
7690 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
7691 if test "x$ac_cv_type_pid_t" = xyes; then :
7693 else
7695 cat >>confdefs.h <<_ACEOF
7696 #define pid_t int
7697 _ACEOF
7701 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
7702 $as_echo_n "checking for a sed that does not truncate output... " >&6; }
7703 if ${ac_cv_path_SED+:} false; then :
7704 $as_echo_n "(cached) " >&6
7705 else
7706 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
7707 for ac_i in 1 2 3 4 5 6 7; do
7708 ac_script="$ac_script$as_nl$ac_script"
7709 done
7710 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
7711 { ac_script=; unset ac_script;}
7712 if test -z "$SED"; then
7713 ac_path_SED_found=false
7714 # Loop through the user's path and test for each of PROGNAME-LIST
7715 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7716 for as_dir in $PATH
7718 IFS=$as_save_IFS
7719 test -z "$as_dir" && as_dir=.
7720 for ac_prog in sed gsed; do
7721 for ac_exec_ext in '' $ac_executable_extensions; do
7722 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
7723 as_fn_executable_p "$ac_path_SED" || continue
7724 # Check for GNU ac_path_SED and select it if it is found.
7725 # Check for GNU $ac_path_SED
7726 case `"$ac_path_SED" --version 2>&1` in
7727 *GNU*)
7728 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
7730 ac_count=0
7731 $as_echo_n 0123456789 >"conftest.in"
7732 while :
7734 cat "conftest.in" "conftest.in" >"conftest.tmp"
7735 mv "conftest.tmp" "conftest.in"
7736 cp "conftest.in" "conftest.nl"
7737 $as_echo '' >> "conftest.nl"
7738 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
7739 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
7740 as_fn_arith $ac_count + 1 && ac_count=$as_val
7741 if test $ac_count -gt ${ac_path_SED_max-0}; then
7742 # Best one so far, save it but keep looking for a better one
7743 ac_cv_path_SED="$ac_path_SED"
7744 ac_path_SED_max=$ac_count
7746 # 10*(2^10) chars as input seems more than enough
7747 test $ac_count -gt 10 && break
7748 done
7749 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
7750 esac
7752 $ac_path_SED_found && break 3
7753 done
7754 done
7755 done
7756 IFS=$as_save_IFS
7757 if test -z "$ac_cv_path_SED"; then
7758 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
7760 else
7761 ac_cv_path_SED=$SED
7765 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
7766 $as_echo "$ac_cv_path_SED" >&6; }
7767 SED="$ac_cv_path_SED"
7768 rm -f conftest.sed
7771 if test "X$prefix" = "XNONE"; then
7772 acl_final_prefix="$ac_default_prefix"
7773 else
7774 acl_final_prefix="$prefix"
7776 if test "X$exec_prefix" = "XNONE"; then
7777 acl_final_exec_prefix='${prefix}'
7778 else
7779 acl_final_exec_prefix="$exec_prefix"
7781 acl_save_prefix="$prefix"
7782 prefix="$acl_final_prefix"
7783 eval acl_final_exec_prefix=\"$acl_final_exec_prefix\"
7784 prefix="$acl_save_prefix"
7787 # Check whether --with-gnu-ld was given.
7788 if test "${with_gnu_ld+set}" = set; then :
7789 withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
7790 else
7791 with_gnu_ld=no
7794 # Prepare PATH_SEPARATOR.
7795 # The user is always right.
7796 if test "${PATH_SEPARATOR+set}" != set; then
7797 echo "#! /bin/sh" >conf$$.sh
7798 echo "exit 0" >>conf$$.sh
7799 chmod +x conf$$.sh
7800 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
7801 PATH_SEPARATOR=';'
7802 else
7803 PATH_SEPARATOR=:
7805 rm -f conf$$.sh
7807 ac_prog=ld
7808 if test "$GCC" = yes; then
7809 # Check if gcc -print-prog-name=ld gives a path.
7810 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by GCC" >&5
7811 $as_echo_n "checking for ld used by GCC... " >&6; }
7812 case $host in
7813 *-*-mingw*)
7814 # gcc leaves a trailing carriage return which upsets mingw
7815 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
7817 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
7818 esac
7819 case $ac_prog in
7820 # Accept absolute paths.
7821 [\\/]* | [A-Za-z]:[\\/]*)
7822 re_direlt='/[^/][^/]*/\.\./'
7823 # Canonicalize the path of ld
7824 ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
7825 while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
7826 ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
7827 done
7828 test -z "$LD" && LD="$ac_prog"
7831 # If it fails, then pretend we aren't using GCC.
7832 ac_prog=ld
7835 # If it is relative, then search for the first ld in PATH.
7836 with_gnu_ld=unknown
7838 esac
7839 elif test "$with_gnu_ld" = yes; then
7840 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
7841 $as_echo_n "checking for GNU ld... " >&6; }
7842 else
7843 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
7844 $as_echo_n "checking for non-GNU ld... " >&6; }
7846 if ${acl_cv_path_LD+:} false; then :
7847 $as_echo_n "(cached) " >&6
7848 else
7849 if test -z "$LD"; then
7850 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
7851 for ac_dir in $PATH; do
7852 test -z "$ac_dir" && ac_dir=.
7853 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
7854 acl_cv_path_LD="$ac_dir/$ac_prog"
7855 # Check to see if the program is GNU ld. I'd rather use --version,
7856 # but apparently some GNU ld's only accept -v.
7857 # Break only if it was the GNU/non-GNU ld that we prefer.
7858 if "$acl_cv_path_LD" -v 2>&1 < /dev/null | $EGREP '(GNU|with BFD)' > /dev/null; then
7859 test "$with_gnu_ld" != no && break
7860 else
7861 test "$with_gnu_ld" != yes && break
7864 done
7865 IFS="$ac_save_ifs"
7866 else
7867 acl_cv_path_LD="$LD" # Let the user override the test with a path.
7871 LD="$acl_cv_path_LD"
7872 if test -n "$LD"; then
7873 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
7874 $as_echo "$LD" >&6; }
7875 else
7876 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7877 $as_echo "no" >&6; }
7879 test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
7880 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
7881 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
7882 if ${acl_cv_prog_gnu_ld+:} false; then :
7883 $as_echo_n "(cached) " >&6
7884 else
7885 # I'd rather use --version here, but apparently some GNU ld's only accept -v.
7886 if $LD -v 2>&1 </dev/null | $EGREP '(GNU|with BFD)' 1>&5; then
7887 acl_cv_prog_gnu_ld=yes
7888 else
7889 acl_cv_prog_gnu_ld=no
7892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_prog_gnu_ld" >&5
7893 $as_echo "$acl_cv_prog_gnu_ld" >&6; }
7894 with_gnu_ld=$acl_cv_prog_gnu_ld
7898 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shared library run path origin" >&5
7899 $as_echo_n "checking for shared library run path origin... " >&6; }
7900 if ${acl_cv_rpath+:} false; then :
7901 $as_echo_n "(cached) " >&6
7902 else
7904 CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
7905 ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
7906 . ./conftest.sh
7907 rm -f ./conftest.sh
7908 acl_cv_rpath=done
7911 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_rpath" >&5
7912 $as_echo "$acl_cv_rpath" >&6; }
7913 wl="$acl_cv_wl"
7914 libext="$acl_cv_libext"
7915 shlibext="$acl_cv_shlibext"
7916 hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
7917 hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
7918 hardcode_direct="$acl_cv_hardcode_direct"
7919 hardcode_minus_L="$acl_cv_hardcode_minus_L"
7920 # Check whether --enable-rpath was given.
7921 if test "${enable_rpath+set}" = set; then :
7922 enableval=$enable_rpath; :
7923 else
7924 enable_rpath=yes
7929 # Set the 'development' global.
7930 . $srcdir/../bfd/development.sh
7932 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
7933 $as_echo_n "checking for ANSI C header files... " >&6; }
7934 if ${ac_cv_header_stdc+:} false; then :
7935 $as_echo_n "(cached) " >&6
7936 else
7937 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7938 /* end confdefs.h. */
7939 #include <stdlib.h>
7940 #include <stdarg.h>
7941 #include <string.h>
7942 #include <float.h>
7945 main ()
7949 return 0;
7951 _ACEOF
7952 if ac_fn_c_try_compile "$LINENO"; then :
7953 ac_cv_header_stdc=yes
7954 else
7955 ac_cv_header_stdc=no
7957 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7959 if test $ac_cv_header_stdc = yes; then
7960 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
7961 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7962 /* end confdefs.h. */
7963 #include <string.h>
7965 _ACEOF
7966 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7967 $EGREP "memchr" >/dev/null 2>&1; then :
7969 else
7970 ac_cv_header_stdc=no
7972 rm -f conftest*
7976 if test $ac_cv_header_stdc = yes; then
7977 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
7978 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7979 /* end confdefs.h. */
7980 #include <stdlib.h>
7982 _ACEOF
7983 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7984 $EGREP "free" >/dev/null 2>&1; then :
7986 else
7987 ac_cv_header_stdc=no
7989 rm -f conftest*
7993 if test $ac_cv_header_stdc = yes; then
7994 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
7995 if test "$cross_compiling" = yes; then :
7997 else
7998 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7999 /* end confdefs.h. */
8000 #include <ctype.h>
8001 #include <stdlib.h>
8002 #if ((' ' & 0x0FF) == 0x020)
8003 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
8004 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
8005 #else
8006 # define ISLOWER(c) \
8007 (('a' <= (c) && (c) <= 'i') \
8008 || ('j' <= (c) && (c) <= 'r') \
8009 || ('s' <= (c) && (c) <= 'z'))
8010 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
8011 #endif
8013 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
8015 main ()
8017 int i;
8018 for (i = 0; i < 256; i++)
8019 if (XOR (islower (i), ISLOWER (i))
8020 || toupper (i) != TOUPPER (i))
8021 return 2;
8022 return 0;
8024 _ACEOF
8025 if ac_fn_c_try_run "$LINENO"; then :
8027 else
8028 ac_cv_header_stdc=no
8030 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8031 conftest.$ac_objext conftest.beam conftest.$ac_ext
8036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
8037 $as_echo "$ac_cv_header_stdc" >&6; }
8038 if test $ac_cv_header_stdc = yes; then
8040 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
8044 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
8045 # for constant arguments. Useless!
8046 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
8047 $as_echo_n "checking for working alloca.h... " >&6; }
8048 if ${ac_cv_working_alloca_h+:} false; then :
8049 $as_echo_n "(cached) " >&6
8050 else
8051 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8052 /* end confdefs.h. */
8053 #include <alloca.h>
8055 main ()
8057 char *p = (char *) alloca (2 * sizeof (int));
8058 if (p) return 0;
8060 return 0;
8062 _ACEOF
8063 if ac_fn_c_try_link "$LINENO"; then :
8064 ac_cv_working_alloca_h=yes
8065 else
8066 ac_cv_working_alloca_h=no
8068 rm -f core conftest.err conftest.$ac_objext \
8069 conftest$ac_exeext conftest.$ac_ext
8071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
8072 $as_echo "$ac_cv_working_alloca_h" >&6; }
8073 if test $ac_cv_working_alloca_h = yes; then
8075 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
8079 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
8080 $as_echo_n "checking for alloca... " >&6; }
8081 if ${ac_cv_func_alloca_works+:} false; then :
8082 $as_echo_n "(cached) " >&6
8083 else
8084 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8085 /* end confdefs.h. */
8086 #ifdef __GNUC__
8087 # define alloca __builtin_alloca
8088 #else
8089 # ifdef _MSC_VER
8090 # include <malloc.h>
8091 # define alloca _alloca
8092 # else
8093 # ifdef HAVE_ALLOCA_H
8094 # include <alloca.h>
8095 # else
8096 # ifdef _AIX
8097 #pragma alloca
8098 # else
8099 # ifndef alloca /* predefined by HP cc +Olibcalls */
8100 void *alloca (size_t);
8101 # endif
8102 # endif
8103 # endif
8104 # endif
8105 #endif
8108 main ()
8110 char *p = (char *) alloca (1);
8111 if (p) return 0;
8113 return 0;
8115 _ACEOF
8116 if ac_fn_c_try_link "$LINENO"; then :
8117 ac_cv_func_alloca_works=yes
8118 else
8119 ac_cv_func_alloca_works=no
8121 rm -f core conftest.err conftest.$ac_objext \
8122 conftest$ac_exeext conftest.$ac_ext
8124 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
8125 $as_echo "$ac_cv_func_alloca_works" >&6; }
8127 if test $ac_cv_func_alloca_works = yes; then
8129 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
8131 else
8132 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
8133 # that cause trouble. Some versions do not even contain alloca or
8134 # contain a buggy version. If you still want to use their alloca,
8135 # use ar to extract alloca.o from them instead of compiling alloca.c.
8137 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
8139 $as_echo "#define C_ALLOCA 1" >>confdefs.h
8142 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5
8143 $as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; }
8144 if ${ac_cv_os_cray+:} false; then :
8145 $as_echo_n "(cached) " >&6
8146 else
8147 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8148 /* end confdefs.h. */
8149 #if defined CRAY && ! defined CRAY2
8150 webecray
8151 #else
8152 wenotbecray
8153 #endif
8155 _ACEOF
8156 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8157 $EGREP "webecray" >/dev/null 2>&1; then :
8158 ac_cv_os_cray=yes
8159 else
8160 ac_cv_os_cray=no
8162 rm -f conftest*
8165 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
8166 $as_echo "$ac_cv_os_cray" >&6; }
8167 if test $ac_cv_os_cray = yes; then
8168 for ac_func in _getb67 GETB67 getb67; do
8169 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
8170 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
8171 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
8173 cat >>confdefs.h <<_ACEOF
8174 #define CRAY_STACKSEG_END $ac_func
8175 _ACEOF
8177 break
8180 done
8183 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
8184 $as_echo_n "checking stack direction for C alloca... " >&6; }
8185 if ${ac_cv_c_stack_direction+:} false; then :
8186 $as_echo_n "(cached) " >&6
8187 else
8188 if test "$cross_compiling" = yes; then :
8189 ac_cv_c_stack_direction=0
8190 else
8191 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8192 /* end confdefs.h. */
8193 $ac_includes_default
8195 find_stack_direction (int *addr, int depth)
8197 int dir, dummy = 0;
8198 if (! addr)
8199 addr = &dummy;
8200 *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
8201 dir = depth ? find_stack_direction (addr, depth - 1) : 0;
8202 return dir + dummy;
8206 main (int argc, char **argv)
8208 return find_stack_direction (0, argc + !argv + 20) < 0;
8210 _ACEOF
8211 if ac_fn_c_try_run "$LINENO"; then :
8212 ac_cv_c_stack_direction=1
8213 else
8214 ac_cv_c_stack_direction=-1
8216 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8217 conftest.$ac_objext conftest.beam conftest.$ac_ext
8221 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
8222 $as_echo "$ac_cv_c_stack_direction" >&6; }
8223 cat >>confdefs.h <<_ACEOF
8224 #define STACK_DIRECTION $ac_cv_c_stack_direction
8225 _ACEOF
8231 WIN32APILIBS=
8232 case ${host} in
8233 *mingw32*)
8235 $as_echo "#define USE_WIN32API 1" >>confdefs.h
8237 WIN32APILIBS="-lws2_32"
8239 esac
8242 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
8243 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
8244 if ${am_cv_langinfo_codeset+:} false; then :
8245 $as_echo_n "(cached) " >&6
8246 else
8247 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8248 /* end confdefs.h. */
8249 #include <langinfo.h>
8251 main ()
8253 char* cs = nl_langinfo(CODESET);
8255 return 0;
8257 _ACEOF
8258 if ac_fn_c_try_link "$LINENO"; then :
8259 am_cv_langinfo_codeset=yes
8260 else
8261 am_cv_langinfo_codeset=no
8263 rm -f core conftest.err conftest.$ac_objext \
8264 conftest$ac_exeext conftest.$ac_ext
8267 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_langinfo_codeset" >&5
8268 $as_echo "$am_cv_langinfo_codeset" >&6; }
8269 if test $am_cv_langinfo_codeset = yes; then
8271 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
8276 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
8277 do :
8278 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8279 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
8280 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
8281 cat >>confdefs.h <<_ACEOF
8282 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8283 _ACEOF
8287 done
8291 for ac_func in getpagesize
8292 do :
8293 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
8294 if test "x$ac_cv_func_getpagesize" = xyes; then :
8295 cat >>confdefs.h <<_ACEOF
8296 #define HAVE_GETPAGESIZE 1
8297 _ACEOF
8300 done
8302 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
8303 $as_echo_n "checking for working mmap... " >&6; }
8304 if ${ac_cv_func_mmap_fixed_mapped+:} false; then :
8305 $as_echo_n "(cached) " >&6
8306 else
8307 if test "$cross_compiling" = yes; then :
8308 ac_cv_func_mmap_fixed_mapped=no
8309 else
8310 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8311 /* end confdefs.h. */
8312 $ac_includes_default
8313 /* malloc might have been renamed as rpl_malloc. */
8314 #undef malloc
8316 /* Thanks to Mike Haertel and Jim Avera for this test.
8317 Here is a matrix of mmap possibilities:
8318 mmap private not fixed
8319 mmap private fixed at somewhere currently unmapped
8320 mmap private fixed at somewhere already mapped
8321 mmap shared not fixed
8322 mmap shared fixed at somewhere currently unmapped
8323 mmap shared fixed at somewhere already mapped
8324 For private mappings, we should verify that changes cannot be read()
8325 back from the file, nor mmap's back from the file at a different
8326 address. (There have been systems where private was not correctly
8327 implemented like the infamous i386 svr4.0, and systems where the
8328 VM page cache was not coherent with the file system buffer cache
8329 like early versions of FreeBSD and possibly contemporary NetBSD.)
8330 For shared mappings, we should conversely verify that changes get
8331 propagated back to all the places they're supposed to be.
8333 Grep wants private fixed already mapped.
8334 The main things grep needs to know about mmap are:
8335 * does it exist and is it safe to write into the mmap'd area
8336 * how to use it (BSD variants) */
8338 #include <fcntl.h>
8339 #include <sys/mman.h>
8341 #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
8342 char *malloc ();
8343 #endif
8345 /* This mess was copied from the GNU getpagesize.h. */
8346 #ifndef HAVE_GETPAGESIZE
8347 # ifdef _SC_PAGESIZE
8348 # define getpagesize() sysconf(_SC_PAGESIZE)
8349 # else /* no _SC_PAGESIZE */
8350 # ifdef HAVE_SYS_PARAM_H
8351 # include <sys/param.h>
8352 # ifdef EXEC_PAGESIZE
8353 # define getpagesize() EXEC_PAGESIZE
8354 # else /* no EXEC_PAGESIZE */
8355 # ifdef NBPG
8356 # define getpagesize() NBPG * CLSIZE
8357 # ifndef CLSIZE
8358 # define CLSIZE 1
8359 # endif /* no CLSIZE */
8360 # else /* no NBPG */
8361 # ifdef NBPC
8362 # define getpagesize() NBPC
8363 # else /* no NBPC */
8364 # ifdef PAGESIZE
8365 # define getpagesize() PAGESIZE
8366 # endif /* PAGESIZE */
8367 # endif /* no NBPC */
8368 # endif /* no NBPG */
8369 # endif /* no EXEC_PAGESIZE */
8370 # else /* no HAVE_SYS_PARAM_H */
8371 # define getpagesize() 8192 /* punt totally */
8372 # endif /* no HAVE_SYS_PARAM_H */
8373 # endif /* no _SC_PAGESIZE */
8375 #endif /* no HAVE_GETPAGESIZE */
8378 main ()
8380 char *data, *data2, *data3;
8381 const char *cdata2;
8382 int i, pagesize;
8383 int fd, fd2;
8385 pagesize = getpagesize ();
8387 /* First, make a file with some known garbage in it. */
8388 data = (char *) malloc (pagesize);
8389 if (!data)
8390 return 1;
8391 for (i = 0; i < pagesize; ++i)
8392 *(data + i) = rand ();
8393 umask (0);
8394 fd = creat ("conftest.mmap", 0600);
8395 if (fd < 0)
8396 return 2;
8397 if (write (fd, data, pagesize) != pagesize)
8398 return 3;
8399 close (fd);
8401 /* Next, check that the tail of a page is zero-filled. File must have
8402 non-zero length, otherwise we risk SIGBUS for entire page. */
8403 fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
8404 if (fd2 < 0)
8405 return 4;
8406 cdata2 = "";
8407 if (write (fd2, cdata2, 1) != 1)
8408 return 5;
8409 data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
8410 if (data2 == MAP_FAILED)
8411 return 6;
8412 for (i = 0; i < pagesize; ++i)
8413 if (*(data2 + i))
8414 return 7;
8415 close (fd2);
8416 if (munmap (data2, pagesize))
8417 return 8;
8419 /* Next, try to mmap the file at a fixed address which already has
8420 something else allocated at it. If we can, also make sure that
8421 we see the same garbage. */
8422 fd = open ("conftest.mmap", O_RDWR);
8423 if (fd < 0)
8424 return 9;
8425 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
8426 MAP_PRIVATE | MAP_FIXED, fd, 0L))
8427 return 10;
8428 for (i = 0; i < pagesize; ++i)
8429 if (*(data + i) != *(data2 + i))
8430 return 11;
8432 /* Finally, make sure that changes to the mapped area do not
8433 percolate back to the file as seen by read(). (This is a bug on
8434 some variants of i386 svr4.0.) */
8435 for (i = 0; i < pagesize; ++i)
8436 *(data2 + i) = *(data2 + i) + 1;
8437 data3 = (char *) malloc (pagesize);
8438 if (!data3)
8439 return 12;
8440 if (read (fd, data3, pagesize) != pagesize)
8441 return 13;
8442 for (i = 0; i < pagesize; ++i)
8443 if (*(data + i) != *(data3 + i))
8444 return 14;
8445 close (fd);
8446 return 0;
8448 _ACEOF
8449 if ac_fn_c_try_run "$LINENO"; then :
8450 ac_cv_func_mmap_fixed_mapped=yes
8451 else
8452 ac_cv_func_mmap_fixed_mapped=no
8454 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8455 conftest.$ac_objext conftest.beam conftest.$ac_ext
8459 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
8460 $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
8461 if test $ac_cv_func_mmap_fixed_mapped = yes; then
8463 $as_echo "#define HAVE_MMAP 1" >>confdefs.h
8466 rm -f conftest.mmap conftest.txt
8468 for ac_header in vfork.h
8469 do :
8470 ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
8471 if test "x$ac_cv_header_vfork_h" = xyes; then :
8472 cat >>confdefs.h <<_ACEOF
8473 #define HAVE_VFORK_H 1
8474 _ACEOF
8478 done
8480 for ac_func in fork vfork
8481 do :
8482 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
8483 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
8484 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
8485 cat >>confdefs.h <<_ACEOF
8486 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
8487 _ACEOF
8490 done
8492 if test "x$ac_cv_func_fork" = xyes; then
8493 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
8494 $as_echo_n "checking for working fork... " >&6; }
8495 if ${ac_cv_func_fork_works+:} false; then :
8496 $as_echo_n "(cached) " >&6
8497 else
8498 if test "$cross_compiling" = yes; then :
8499 ac_cv_func_fork_works=cross
8500 else
8501 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8502 /* end confdefs.h. */
8503 $ac_includes_default
8505 main ()
8508 /* By Ruediger Kuhlmann. */
8509 return fork () < 0;
8512 return 0;
8514 _ACEOF
8515 if ac_fn_c_try_run "$LINENO"; then :
8516 ac_cv_func_fork_works=yes
8517 else
8518 ac_cv_func_fork_works=no
8520 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8521 conftest.$ac_objext conftest.beam conftest.$ac_ext
8525 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
8526 $as_echo "$ac_cv_func_fork_works" >&6; }
8528 else
8529 ac_cv_func_fork_works=$ac_cv_func_fork
8531 if test "x$ac_cv_func_fork_works" = xcross; then
8532 case $host in
8533 *-*-amigaos* | *-*-msdosdjgpp*)
8534 # Override, as these systems have only a dummy fork() stub
8535 ac_cv_func_fork_works=no
8538 ac_cv_func_fork_works=yes
8540 esac
8541 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
8542 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
8544 ac_cv_func_vfork_works=$ac_cv_func_vfork
8545 if test "x$ac_cv_func_vfork" = xyes; then
8546 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
8547 $as_echo_n "checking for working vfork... " >&6; }
8548 if ${ac_cv_func_vfork_works+:} false; then :
8549 $as_echo_n "(cached) " >&6
8550 else
8551 if test "$cross_compiling" = yes; then :
8552 ac_cv_func_vfork_works=cross
8553 else
8554 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8555 /* end confdefs.h. */
8556 /* Thanks to Paul Eggert for this test. */
8557 $ac_includes_default
8558 #include <sys/wait.h>
8559 #ifdef HAVE_VFORK_H
8560 # include <vfork.h>
8561 #endif
8562 /* On some sparc systems, changes by the child to local and incoming
8563 argument registers are propagated back to the parent. The compiler
8564 is told about this with #include <vfork.h>, but some compilers
8565 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
8566 static variable whose address is put into a register that is
8567 clobbered by the vfork. */
8568 static void
8569 #ifdef __cplusplus
8570 sparc_address_test (int arg)
8571 # else
8572 sparc_address_test (arg) int arg;
8573 #endif
8575 static pid_t child;
8576 if (!child) {
8577 child = vfork ();
8578 if (child < 0) {
8579 perror ("vfork");
8580 _exit(2);
8582 if (!child) {
8583 arg = getpid();
8584 write(-1, "", 0);
8585 _exit (arg);
8591 main ()
8593 pid_t parent = getpid ();
8594 pid_t child;
8596 sparc_address_test (0);
8598 child = vfork ();
8600 if (child == 0) {
8601 /* Here is another test for sparc vfork register problems. This
8602 test uses lots of local variables, at least as many local
8603 variables as main has allocated so far including compiler
8604 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
8605 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
8606 reuse the register of parent for one of the local variables,
8607 since it will think that parent can't possibly be used any more
8608 in this routine. Assigning to the local variable will thus
8609 munge parent in the parent process. */
8610 pid_t
8611 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
8612 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
8613 /* Convince the compiler that p..p7 are live; otherwise, it might
8614 use the same hardware register for all 8 local variables. */
8615 if (p != p1 || p != p2 || p != p3 || p != p4
8616 || p != p5 || p != p6 || p != p7)
8617 _exit(1);
8619 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
8620 from child file descriptors. If the child closes a descriptor
8621 before it execs or exits, this munges the parent's descriptor
8622 as well. Test for this by closing stdout in the child. */
8623 _exit(close(fileno(stdout)) != 0);
8624 } else {
8625 int status;
8626 struct stat st;
8628 while (wait(&status) != child)
8630 return (
8631 /* Was there some problem with vforking? */
8632 child < 0
8634 /* Did the child fail? (This shouldn't happen.) */
8635 || status
8637 /* Did the vfork/compiler bug occur? */
8638 || parent != getpid()
8640 /* Did the file descriptor bug occur? */
8641 || fstat(fileno(stdout), &st) != 0
8645 _ACEOF
8646 if ac_fn_c_try_run "$LINENO"; then :
8647 ac_cv_func_vfork_works=yes
8648 else
8649 ac_cv_func_vfork_works=no
8651 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8652 conftest.$ac_objext conftest.beam conftest.$ac_ext
8656 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
8657 $as_echo "$ac_cv_func_vfork_works" >&6; }
8660 if test "x$ac_cv_func_fork_works" = xcross; then
8661 ac_cv_func_vfork_works=$ac_cv_func_vfork
8662 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
8663 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
8666 if test "x$ac_cv_func_vfork_works" = xyes; then
8668 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
8670 else
8672 $as_echo "#define vfork fork" >>confdefs.h
8675 if test "x$ac_cv_func_fork_works" = xyes; then
8677 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
8681 # Some systems (e.g. Solaris) have `socketpair' in libsocket.
8682 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing socketpair" >&5
8683 $as_echo_n "checking for library containing socketpair... " >&6; }
8684 if ${ac_cv_search_socketpair+:} false; then :
8685 $as_echo_n "(cached) " >&6
8686 else
8687 ac_func_search_save_LIBS=$LIBS
8688 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8689 /* end confdefs.h. */
8691 /* Override any GCC internal prototype to avoid an error.
8692 Use char because int might match the return type of a GCC
8693 builtin and then its argument prototype would still apply. */
8694 #ifdef __cplusplus
8695 extern "C"
8696 #endif
8697 char socketpair ();
8699 main ()
8701 return socketpair ();
8703 return 0;
8705 _ACEOF
8706 for ac_lib in '' socket; do
8707 if test -z "$ac_lib"; then
8708 ac_res="none required"
8709 else
8710 ac_res=-l$ac_lib
8711 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
8713 if ac_fn_c_try_link "$LINENO"; then :
8714 ac_cv_search_socketpair=$ac_res
8716 rm -f core conftest.err conftest.$ac_objext \
8717 conftest$ac_exeext
8718 if ${ac_cv_search_socketpair+:} false; then :
8719 break
8721 done
8722 if ${ac_cv_search_socketpair+:} false; then :
8724 else
8725 ac_cv_search_socketpair=no
8727 rm conftest.$ac_ext
8728 LIBS=$ac_func_search_save_LIBS
8730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_socketpair" >&5
8731 $as_echo "$ac_cv_search_socketpair" >&6; }
8732 ac_res=$ac_cv_search_socketpair
8733 if test "$ac_res" != no; then :
8734 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8738 for ac_func in fdwalk getrlimit pipe pipe2 poll socketpair sigaction \
8739 ptrace64 sbrk setns sigaltstack sigprocmask \
8740 setpgid setpgrp getrusage getauxval sigtimedwait
8741 do :
8742 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
8743 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
8744 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
8745 cat >>confdefs.h <<_ACEOF
8746 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
8747 _ACEOF
8750 done
8753 # This is needed for RHEL 5 and uclibc-ng < 1.0.39.
8754 # These did not define ADDR_NO_RANDOMIZE in sys/personality.h,
8755 # only in linux/personality.h.
8756 ac_fn_c_check_decl "$LINENO" "ADDR_NO_RANDOMIZE" "ac_cv_have_decl_ADDR_NO_RANDOMIZE" "#include <sys/personality.h>
8758 if test "x$ac_cv_have_decl_ADDR_NO_RANDOMIZE" = xyes; then :
8759 ac_have_decl=1
8760 else
8761 ac_have_decl=0
8764 cat >>confdefs.h <<_ACEOF
8765 #define HAVE_DECL_ADDR_NO_RANDOMIZE $ac_have_decl
8766 _ACEOF
8769 ac_fn_c_check_decl "$LINENO" "strstr" "ac_cv_have_decl_strstr" "$ac_includes_default"
8770 if test "x$ac_cv_have_decl_strstr" = xyes; then :
8771 ac_have_decl=1
8772 else
8773 ac_have_decl=0
8776 cat >>confdefs.h <<_ACEOF
8777 #define HAVE_DECL_STRSTR $ac_have_decl
8778 _ACEOF
8781 # ----------------------- #
8782 # Checks for structures. #
8783 # ----------------------- #
8785 ac_fn_c_check_member "$LINENO" "struct stat" "st_blocks" "ac_cv_member_struct_stat_st_blocks" "$ac_includes_default"
8786 if test "x$ac_cv_member_struct_stat_st_blocks" = xyes; then :
8788 cat >>confdefs.h <<_ACEOF
8789 #define HAVE_STRUCT_STAT_ST_BLOCKS 1
8790 _ACEOF
8794 ac_fn_c_check_member "$LINENO" "struct stat" "st_blksize" "ac_cv_member_struct_stat_st_blksize" "$ac_includes_default"
8795 if test "x$ac_cv_member_struct_stat_st_blksize" = xyes; then :
8797 cat >>confdefs.h <<_ACEOF
8798 #define HAVE_STRUCT_STAT_ST_BLKSIZE 1
8799 _ACEOF
8805 # On FreeBSD we need libutil for the kinfo_get* functions. On
8806 # GNU/kFreeBSD systems, FreeBSD libutil is renamed to libutil-freebsd.
8807 # Figure out which one to use.
8808 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing kinfo_getfile" >&5
8809 $as_echo_n "checking for library containing kinfo_getfile... " >&6; }
8810 if ${ac_cv_search_kinfo_getfile+:} false; then :
8811 $as_echo_n "(cached) " >&6
8812 else
8813 ac_func_search_save_LIBS=$LIBS
8814 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8815 /* end confdefs.h. */
8817 /* Override any GCC internal prototype to avoid an error.
8818 Use char because int might match the return type of a GCC
8819 builtin and then its argument prototype would still apply. */
8820 #ifdef __cplusplus
8821 extern "C"
8822 #endif
8823 char kinfo_getfile ();
8825 main ()
8827 return kinfo_getfile ();
8829 return 0;
8831 _ACEOF
8832 for ac_lib in '' util util-freebsd; do
8833 if test -z "$ac_lib"; then
8834 ac_res="none required"
8835 else
8836 ac_res=-l$ac_lib
8837 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
8839 if ac_fn_c_try_link "$LINENO"; then :
8840 ac_cv_search_kinfo_getfile=$ac_res
8842 rm -f core conftest.err conftest.$ac_objext \
8843 conftest$ac_exeext
8844 if ${ac_cv_search_kinfo_getfile+:} false; then :
8845 break
8847 done
8848 if ${ac_cv_search_kinfo_getfile+:} false; then :
8850 else
8851 ac_cv_search_kinfo_getfile=no
8853 rm conftest.$ac_ext
8854 LIBS=$ac_func_search_save_LIBS
8856 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_kinfo_getfile" >&5
8857 $as_echo "$ac_cv_search_kinfo_getfile" >&6; }
8858 ac_res=$ac_cv_search_kinfo_getfile
8859 if test "$ac_res" != no; then :
8860 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8865 # Define HAVE_KINFO_GETFILE if kinfo_getfile is available.
8866 for ac_func in kinfo_getfile
8867 do :
8868 ac_fn_c_check_func "$LINENO" "kinfo_getfile" "ac_cv_func_kinfo_getfile"
8869 if test "x$ac_cv_func_kinfo_getfile" = xyes; then :
8870 cat >>confdefs.h <<_ACEOF
8871 #define HAVE_KINFO_GETFILE 1
8872 _ACEOF
8875 done
8878 # ----------------------- #
8879 # Check for threading. #
8880 # ----------------------- #
8882 # Check whether --enable-threading was given.
8883 if test "${enable_threading+set}" = set; then :
8884 enableval=$enable_threading; case "$enableval" in
8885 yes) want_threading=yes ;;
8886 no) want_threading=no ;;
8887 *) as_fn_error $? "bad value $enableval for threading" "$LINENO" 5 ;;
8888 esac
8889 else
8890 want_threading=yes
8894 # Check for std::thread. This does not work on some platforms, like
8895 # mingw and DJGPP.
8896 ac_ext=cpp
8897 ac_cpp='$CXXCPP $CPPFLAGS'
8898 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
8899 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
8900 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
8906 ac_ext=c
8907 ac_cpp='$CPP $CPPFLAGS'
8908 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
8909 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
8910 ac_compiler_gnu=$ac_cv_c_compiler_gnu
8912 ax_pthread_ok=no
8914 # We used to check for pthread.h first, but this fails if pthread.h
8915 # requires special compiler flags (e.g. on Tru64 or Sequent).
8916 # It gets checked for in the link test anyway.
8918 # First of all, check if the user has set any of the PTHREAD_LIBS,
8919 # etcetera environment variables, and if threads linking works using
8920 # them:
8921 if test "x$PTHREAD_CFLAGS$PTHREAD_LIBS" != "x"; then
8922 ax_pthread_save_CC="$CC"
8923 ax_pthread_save_CFLAGS="$CFLAGS"
8924 ax_pthread_save_LIBS="$LIBS"
8925 if test "x$PTHREAD_CC" != "x"; then :
8926 CC="$PTHREAD_CC"
8928 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
8929 LIBS="$PTHREAD_LIBS $LIBS"
8930 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_join using $CC $PTHREAD_CFLAGS $PTHREAD_LIBS" >&5
8931 $as_echo_n "checking for pthread_join using $CC $PTHREAD_CFLAGS $PTHREAD_LIBS... " >&6; }
8932 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8933 /* end confdefs.h. */
8935 /* Override any GCC internal prototype to avoid an error.
8936 Use char because int might match the return type of a GCC
8937 builtin and then its argument prototype would still apply. */
8938 #ifdef __cplusplus
8939 extern "C"
8940 #endif
8941 char pthread_join ();
8943 main ()
8945 return pthread_join ();
8947 return 0;
8949 _ACEOF
8950 if ac_fn_c_try_link "$LINENO"; then :
8951 ax_pthread_ok=yes
8953 rm -f core conftest.err conftest.$ac_objext \
8954 conftest$ac_exeext conftest.$ac_ext
8955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5
8956 $as_echo "$ax_pthread_ok" >&6; }
8957 if test "x$ax_pthread_ok" = "xno"; then
8958 PTHREAD_LIBS=""
8959 PTHREAD_CFLAGS=""
8961 CC="$ax_pthread_save_CC"
8962 CFLAGS="$ax_pthread_save_CFLAGS"
8963 LIBS="$ax_pthread_save_LIBS"
8966 # We must check for the threads library under a number of different
8967 # names; the ordering is very important because some systems
8968 # (e.g. DEC) have both -lpthread and -lpthreads, where one of the
8969 # libraries is broken (non-POSIX).
8971 # Create a list of thread flags to try. Items starting with a "-" are
8972 # C compiler flags, and other items are library names, except for "none"
8973 # which indicates that we try without any flags at all, and "pthread-config"
8974 # which is a program returning the flags for the Pth emulation library.
8976 ax_pthread_flags="pthreads none -Kthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config"
8978 # The ordering *is* (sometimes) important. Some notes on the
8979 # individual items follow:
8981 # pthreads: AIX (must check this before -lpthread)
8982 # none: in case threads are in libc; should be tried before -Kthread and
8983 # other compiler flags to prevent continual compiler warnings
8984 # -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
8985 # -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads), Tru64
8986 # (Note: HP C rejects this with "bad form for `-t' option")
8987 # -pthreads: Solaris/gcc (Note: HP C also rejects)
8988 # -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
8989 # doesn't hurt to check since this sometimes defines pthreads and
8990 # -D_REENTRANT too), HP C (must be checked before -lpthread, which
8991 # is present but should not be used directly; and before -mthreads,
8992 # because the compiler interprets this as "-mt" + "-hreads")
8993 # -mthreads: Mingw32/gcc, Lynx/gcc
8994 # pthread: Linux, etcetera
8995 # --thread-safe: KAI C++
8996 # pthread-config: use pthread-config program (for GNU Pth library)
8998 case $host_os in
9000 freebsd*)
9002 # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
9003 # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
9005 ax_pthread_flags="-kthread lthread $ax_pthread_flags"
9008 hpux*)
9010 # From the cc(1) man page: "[-mt] Sets various -D flags to enable
9011 # multi-threading and also sets -lpthread."
9013 ax_pthread_flags="-mt -pthread pthread $ax_pthread_flags"
9016 openedition*)
9018 # IBM z/OS requires a feature-test macro to be defined in order to
9019 # enable POSIX threads at all, so give the user a hint if this is
9020 # not set. (We don't define these ourselves, as they can affect
9021 # other portions of the system API in unpredictable ways.)
9023 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9024 /* end confdefs.h. */
9026 # if !defined(_OPEN_THREADS) && !defined(_UNIX03_THREADS)
9027 AX_PTHREAD_ZOS_MISSING
9028 # endif
9030 _ACEOF
9031 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9032 $EGREP "AX_PTHREAD_ZOS_MISSING" >/dev/null 2>&1; then :
9033 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: IBM z/OS requires -D_OPEN_THREADS or -D_UNIX03_THREADS to enable pthreads support." >&5
9034 $as_echo "$as_me: WARNING: IBM z/OS requires -D_OPEN_THREADS or -D_UNIX03_THREADS to enable pthreads support." >&2;}
9036 rm -f conftest*
9040 solaris*)
9042 # On Solaris (at least, for some versions), libc contains stubbed
9043 # (non-functional) versions of the pthreads routines, so link-based
9044 # tests will erroneously succeed. (N.B.: The stubs are missing
9045 # pthread_cleanup_push, or rather a function called by this macro,
9046 # so we could check for that, but who knows whether they'll stub
9047 # that too in a future libc.) So we'll check first for the
9048 # standard Solaris way of linking pthreads (-mt -lpthread).
9050 ax_pthread_flags="-mt,pthread pthread $ax_pthread_flags"
9052 esac
9054 # GCC generally uses -pthread, or -pthreads on some platforms (e.g. SPARC)
9056 if test "x$GCC" = "xyes"; then :
9057 ax_pthread_flags="-pthread -pthreads $ax_pthread_flags"
9060 # The presence of a feature test macro requesting re-entrant function
9061 # definitions is, on some systems, a strong hint that pthreads support is
9062 # correctly enabled
9064 case $host_os in
9065 darwin* | hpux* | linux* | osf* | solaris*)
9066 ax_pthread_check_macro="_REENTRANT"
9069 aix*)
9070 ax_pthread_check_macro="_THREAD_SAFE"
9074 ax_pthread_check_macro="--"
9076 esac
9077 if test "x$ax_pthread_check_macro" = "x--"; then :
9078 ax_pthread_check_cond=0
9079 else
9080 ax_pthread_check_cond="!defined($ax_pthread_check_macro)"
9083 # Are we compiling with Clang?
9085 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC is Clang" >&5
9086 $as_echo_n "checking whether $CC is Clang... " >&6; }
9087 if ${ax_cv_PTHREAD_CLANG+:} false; then :
9088 $as_echo_n "(cached) " >&6
9089 else
9090 ax_cv_PTHREAD_CLANG=no
9091 # Note that Autoconf sets GCC=yes for Clang as well as GCC
9092 if test "x$GCC" = "xyes"; then
9093 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9094 /* end confdefs.h. */
9095 /* Note: Clang 2.7 lacks __clang_[a-z]+__ */
9096 # if defined(__clang__) && defined(__llvm__)
9097 AX_PTHREAD_CC_IS_CLANG
9098 # endif
9100 _ACEOF
9101 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9102 $EGREP "AX_PTHREAD_CC_IS_CLANG" >/dev/null 2>&1; then :
9103 ax_cv_PTHREAD_CLANG=yes
9105 rm -f conftest*
9110 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_CLANG" >&5
9111 $as_echo "$ax_cv_PTHREAD_CLANG" >&6; }
9112 ax_pthread_clang="$ax_cv_PTHREAD_CLANG"
9114 ax_pthread_clang_warning=no
9116 # Clang needs special handling, because older versions handle the -pthread
9117 # option in a rather... idiosyncratic way
9119 if test "x$ax_pthread_clang" = "xyes"; then
9121 # Clang takes -pthread; it has never supported any other flag
9123 # (Note 1: This will need to be revisited if a system that Clang
9124 # supports has POSIX threads in a separate library. This tends not
9125 # to be the way of modern systems, but it's conceivable.)
9127 # (Note 2: On some systems, notably Darwin, -pthread is not needed
9128 # to get POSIX threads support; the API is always present and
9129 # active. We could reasonably leave PTHREAD_CFLAGS empty. But
9130 # -pthread does define _REENTRANT, and while the Darwin headers
9131 # ignore this macro, third-party headers might not.)
9133 PTHREAD_CFLAGS="-pthread"
9134 PTHREAD_LIBS=
9136 ax_pthread_ok=yes
9138 # However, older versions of Clang make a point of warning the user
9139 # that, in an invocation where only linking and no compilation is
9140 # taking place, the -pthread option has no effect ("argument unused
9141 # during compilation"). They expect -pthread to be passed in only
9142 # when source code is being compiled.
9144 # Problem is, this is at odds with the way Automake and most other
9145 # C build frameworks function, which is that the same flags used in
9146 # compilation (CFLAGS) are also used in linking. Many systems
9147 # supported by AX_PTHREAD require exactly this for POSIX threads
9148 # support, and in fact it is often not straightforward to specify a
9149 # flag that is used only in the compilation phase and not in
9150 # linking. Such a scenario is extremely rare in practice.
9152 # Even though use of the -pthread flag in linking would only print
9153 # a warning, this can be a nuisance for well-run software projects
9154 # that build with -Werror. So if the active version of Clang has
9155 # this misfeature, we search for an option to squash it.
9157 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether Clang needs flag to prevent \"argument unused\" warning when linking with -pthread" >&5
9158 $as_echo_n "checking whether Clang needs flag to prevent \"argument unused\" warning when linking with -pthread... " >&6; }
9159 if ${ax_cv_PTHREAD_CLANG_NO_WARN_FLAG+:} false; then :
9160 $as_echo_n "(cached) " >&6
9161 else
9162 ax_cv_PTHREAD_CLANG_NO_WARN_FLAG=unknown
9163 # Create an alternate version of $ac_link that compiles and
9164 # links in two steps (.c -> .o, .o -> exe) instead of one
9165 # (.c -> exe), because the warning occurs only in the second
9166 # step
9167 ax_pthread_save_ac_link="$ac_link"
9168 ax_pthread_sed='s/conftest\.\$ac_ext/conftest.$ac_objext/g'
9169 ax_pthread_link_step=`$as_echo "$ac_link" | sed "$ax_pthread_sed"`
9170 ax_pthread_2step_ac_link="($ac_compile) && (echo ==== >&5) && ($ax_pthread_link_step)"
9171 ax_pthread_save_CFLAGS="$CFLAGS"
9172 for ax_pthread_try in '' -Qunused-arguments -Wno-unused-command-line-argument unknown; do
9173 if test "x$ax_pthread_try" = "xunknown"; then :
9174 break
9176 CFLAGS="-Werror -Wunknown-warning-option $ax_pthread_try -pthread $ax_pthread_save_CFLAGS"
9177 ac_link="$ax_pthread_save_ac_link"
9178 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9179 /* end confdefs.h. */
9180 int main(void){return 0;}
9181 _ACEOF
9182 if ac_fn_c_try_link "$LINENO"; then :
9183 ac_link="$ax_pthread_2step_ac_link"
9184 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9185 /* end confdefs.h. */
9186 int main(void){return 0;}
9187 _ACEOF
9188 if ac_fn_c_try_link "$LINENO"; then :
9189 break
9191 rm -f core conftest.err conftest.$ac_objext \
9192 conftest$ac_exeext conftest.$ac_ext
9195 rm -f core conftest.err conftest.$ac_objext \
9196 conftest$ac_exeext conftest.$ac_ext
9197 done
9198 ac_link="$ax_pthread_save_ac_link"
9199 CFLAGS="$ax_pthread_save_CFLAGS"
9200 if test "x$ax_pthread_try" = "x"; then :
9201 ax_pthread_try=no
9203 ax_cv_PTHREAD_CLANG_NO_WARN_FLAG="$ax_pthread_try"
9206 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" >&5
9207 $as_echo "$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" >&6; }
9209 case "$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" in
9210 no | unknown) ;;
9211 *) PTHREAD_CFLAGS="$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG $PTHREAD_CFLAGS" ;;
9212 esac
9214 fi # $ax_pthread_clang = yes
9216 if test "x$ax_pthread_ok" = "xno"; then
9217 for ax_pthread_try_flag in $ax_pthread_flags; do
9219 case $ax_pthread_try_flag in
9220 none)
9221 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work without any flags" >&5
9222 $as_echo_n "checking whether pthreads work without any flags... " >&6; }
9225 -mt,pthread)
9226 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with -mt -lpthread" >&5
9227 $as_echo_n "checking whether pthreads work with -mt -lpthread... " >&6; }
9228 PTHREAD_CFLAGS="-mt"
9229 PTHREAD_LIBS="-lpthread"
9233 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with $ax_pthread_try_flag" >&5
9234 $as_echo_n "checking whether pthreads work with $ax_pthread_try_flag... " >&6; }
9235 PTHREAD_CFLAGS="$ax_pthread_try_flag"
9238 pthread-config)
9239 # Extract the first word of "pthread-config", so it can be a program name with args.
9240 set dummy pthread-config; ac_word=$2
9241 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9242 $as_echo_n "checking for $ac_word... " >&6; }
9243 if ${ac_cv_prog_ax_pthread_config+:} false; then :
9244 $as_echo_n "(cached) " >&6
9245 else
9246 if test -n "$ax_pthread_config"; then
9247 ac_cv_prog_ax_pthread_config="$ax_pthread_config" # Let the user override the test.
9248 else
9249 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9250 for as_dir in $PATH
9252 IFS=$as_save_IFS
9253 test -z "$as_dir" && as_dir=.
9254 for ac_exec_ext in '' $ac_executable_extensions; do
9255 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9256 ac_cv_prog_ax_pthread_config="yes"
9257 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9258 break 2
9260 done
9261 done
9262 IFS=$as_save_IFS
9264 test -z "$ac_cv_prog_ax_pthread_config" && ac_cv_prog_ax_pthread_config="no"
9267 ax_pthread_config=$ac_cv_prog_ax_pthread_config
9268 if test -n "$ax_pthread_config"; then
9269 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_config" >&5
9270 $as_echo "$ax_pthread_config" >&6; }
9271 else
9272 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9273 $as_echo "no" >&6; }
9277 if test "x$ax_pthread_config" = "xno"; then :
9278 continue
9280 PTHREAD_CFLAGS="`pthread-config --cflags`"
9281 PTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
9285 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the pthreads library -l$ax_pthread_try_flag" >&5
9286 $as_echo_n "checking for the pthreads library -l$ax_pthread_try_flag... " >&6; }
9287 PTHREAD_LIBS="-l$ax_pthread_try_flag"
9289 esac
9291 ax_pthread_save_CFLAGS="$CFLAGS"
9292 ax_pthread_save_LIBS="$LIBS"
9293 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
9294 LIBS="$PTHREAD_LIBS $LIBS"
9296 # Check for various functions. We must include pthread.h,
9297 # since some functions may be macros. (On the Sequent, we
9298 # need a special flag -Kthread to make this header compile.)
9299 # We check for pthread_join because it is in -lpthread on IRIX
9300 # while pthread_create is in libc. We check for pthread_attr_init
9301 # due to DEC craziness with -lpthreads. We check for
9302 # pthread_cleanup_push because it is one of the few pthread
9303 # functions on Solaris that doesn't have a non-functional libc stub.
9304 # We try pthread_create on general principles.
9306 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9307 /* end confdefs.h. */
9308 #include <pthread.h>
9309 # if $ax_pthread_check_cond
9310 # error "$ax_pthread_check_macro must be defined"
9311 # endif
9312 static void routine(void *a) { a = 0; }
9313 static void *start_routine(void *a) { return a; }
9315 main ()
9317 pthread_t th; pthread_attr_t attr;
9318 pthread_create(&th, 0, start_routine, 0);
9319 pthread_join(th, 0);
9320 pthread_attr_init(&attr);
9321 pthread_cleanup_push(routine, 0);
9322 pthread_cleanup_pop(0) /* ; */
9324 return 0;
9326 _ACEOF
9327 if ac_fn_c_try_link "$LINENO"; then :
9328 ax_pthread_ok=yes
9330 rm -f core conftest.err conftest.$ac_objext \
9331 conftest$ac_exeext conftest.$ac_ext
9333 CFLAGS="$ax_pthread_save_CFLAGS"
9334 LIBS="$ax_pthread_save_LIBS"
9336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5
9337 $as_echo "$ax_pthread_ok" >&6; }
9338 if test "x$ax_pthread_ok" = "xyes"; then :
9339 break
9342 PTHREAD_LIBS=""
9343 PTHREAD_CFLAGS=""
9344 done
9347 # Various other checks:
9348 if test "x$ax_pthread_ok" = "xyes"; then
9349 ax_pthread_save_CFLAGS="$CFLAGS"
9350 ax_pthread_save_LIBS="$LIBS"
9351 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
9352 LIBS="$PTHREAD_LIBS $LIBS"
9354 # Detect AIX lossage: JOINABLE attribute is called UNDETACHED.
9355 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for joinable pthread attribute" >&5
9356 $as_echo_n "checking for joinable pthread attribute... " >&6; }
9357 if ${ax_cv_PTHREAD_JOINABLE_ATTR+:} false; then :
9358 $as_echo_n "(cached) " >&6
9359 else
9360 ax_cv_PTHREAD_JOINABLE_ATTR=unknown
9361 for ax_pthread_attr in PTHREAD_CREATE_JOINABLE PTHREAD_CREATE_UNDETACHED; do
9362 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9363 /* end confdefs.h. */
9364 #include <pthread.h>
9366 main ()
9368 int attr = $ax_pthread_attr; return attr /* ; */
9370 return 0;
9372 _ACEOF
9373 if ac_fn_c_try_link "$LINENO"; then :
9374 ax_cv_PTHREAD_JOINABLE_ATTR=$ax_pthread_attr; break
9376 rm -f core conftest.err conftest.$ac_objext \
9377 conftest$ac_exeext conftest.$ac_ext
9378 done
9381 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_JOINABLE_ATTR" >&5
9382 $as_echo "$ax_cv_PTHREAD_JOINABLE_ATTR" >&6; }
9383 if test "x$ax_cv_PTHREAD_JOINABLE_ATTR" != "xunknown" && \
9384 test "x$ax_cv_PTHREAD_JOINABLE_ATTR" != "xPTHREAD_CREATE_JOINABLE" && \
9385 test "x$ax_pthread_joinable_attr_defined" != "xyes"; then :
9387 cat >>confdefs.h <<_ACEOF
9388 #define PTHREAD_CREATE_JOINABLE $ax_cv_PTHREAD_JOINABLE_ATTR
9389 _ACEOF
9391 ax_pthread_joinable_attr_defined=yes
9395 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether more special flags are required for pthreads" >&5
9396 $as_echo_n "checking whether more special flags are required for pthreads... " >&6; }
9397 if ${ax_cv_PTHREAD_SPECIAL_FLAGS+:} false; then :
9398 $as_echo_n "(cached) " >&6
9399 else
9400 ax_cv_PTHREAD_SPECIAL_FLAGS=no
9401 case $host_os in
9402 solaris*)
9403 ax_cv_PTHREAD_SPECIAL_FLAGS="-D_POSIX_PTHREAD_SEMANTICS"
9405 esac
9408 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_SPECIAL_FLAGS" >&5
9409 $as_echo "$ax_cv_PTHREAD_SPECIAL_FLAGS" >&6; }
9410 if test "x$ax_cv_PTHREAD_SPECIAL_FLAGS" != "xno" && \
9411 test "x$ax_pthread_special_flags_added" != "xyes"; then :
9412 PTHREAD_CFLAGS="$ax_cv_PTHREAD_SPECIAL_FLAGS $PTHREAD_CFLAGS"
9413 ax_pthread_special_flags_added=yes
9416 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTHREAD_PRIO_INHERIT" >&5
9417 $as_echo_n "checking for PTHREAD_PRIO_INHERIT... " >&6; }
9418 if ${ax_cv_PTHREAD_PRIO_INHERIT+:} false; then :
9419 $as_echo_n "(cached) " >&6
9420 else
9421 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9422 /* end confdefs.h. */
9423 #include <pthread.h>
9425 main ()
9427 int i = PTHREAD_PRIO_INHERIT;
9429 return 0;
9431 _ACEOF
9432 if ac_fn_c_try_link "$LINENO"; then :
9433 ax_cv_PTHREAD_PRIO_INHERIT=yes
9434 else
9435 ax_cv_PTHREAD_PRIO_INHERIT=no
9437 rm -f core conftest.err conftest.$ac_objext \
9438 conftest$ac_exeext conftest.$ac_ext
9441 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_PRIO_INHERIT" >&5
9442 $as_echo "$ax_cv_PTHREAD_PRIO_INHERIT" >&6; }
9443 if test "x$ax_cv_PTHREAD_PRIO_INHERIT" = "xyes" && \
9444 test "x$ax_pthread_prio_inherit_defined" != "xyes"; then :
9446 $as_echo "#define HAVE_PTHREAD_PRIO_INHERIT 1" >>confdefs.h
9448 ax_pthread_prio_inherit_defined=yes
9452 CFLAGS="$ax_pthread_save_CFLAGS"
9453 LIBS="$ax_pthread_save_LIBS"
9455 # More AIX lossage: compile with *_r variant
9456 if test "x$GCC" != "xyes"; then
9457 case $host_os in
9458 aix*)
9459 case "x/$CC" in #(
9460 x*/c89|x*/c89_128|x*/c99|x*/c99_128|x*/cc|x*/cc128|x*/xlc|x*/xlc_v6|x*/xlc128|x*/xlc128_v6) :
9461 #handle absolute path differently from PATH based program lookup
9462 case "x$CC" in #(
9463 x/*) :
9464 if as_fn_executable_p ${CC}_r; then :
9465 PTHREAD_CC="${CC}_r"
9466 fi ;; #(
9467 *) :
9468 for ac_prog in ${CC}_r
9470 # Extract the first word of "$ac_prog", so it can be a program name with args.
9471 set dummy $ac_prog; ac_word=$2
9472 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9473 $as_echo_n "checking for $ac_word... " >&6; }
9474 if ${ac_cv_prog_PTHREAD_CC+:} false; then :
9475 $as_echo_n "(cached) " >&6
9476 else
9477 if test -n "$PTHREAD_CC"; then
9478 ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
9479 else
9480 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9481 for as_dir in $PATH
9483 IFS=$as_save_IFS
9484 test -z "$as_dir" && as_dir=.
9485 for ac_exec_ext in '' $ac_executable_extensions; do
9486 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9487 ac_cv_prog_PTHREAD_CC="$ac_prog"
9488 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9489 break 2
9491 done
9492 done
9493 IFS=$as_save_IFS
9497 PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
9498 if test -n "$PTHREAD_CC"; then
9499 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PTHREAD_CC" >&5
9500 $as_echo "$PTHREAD_CC" >&6; }
9501 else
9502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9503 $as_echo "no" >&6; }
9507 test -n "$PTHREAD_CC" && break
9508 done
9509 test -n "$PTHREAD_CC" || PTHREAD_CC="$CC"
9511 esac ;; #(
9512 *) :
9514 esac
9516 esac
9520 test -n "$PTHREAD_CC" || PTHREAD_CC="$CC"
9526 # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
9527 if test "x$ax_pthread_ok" = "xyes"; then
9528 threads=yes
9530 else
9531 ax_pthread_ok=no
9532 threads=no
9534 ac_ext=cpp
9535 ac_cpp='$CXXCPP $CPPFLAGS'
9536 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
9537 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
9538 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
9541 save_LIBS="$LIBS"
9542 LIBS="$PTHREAD_LIBS $LIBS"
9543 save_CXXFLAGS="$CXXFLAGS"
9544 CXXFLAGS="$PTHREAD_CFLAGS $save_CXXFLAGS"
9545 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for std::thread" >&5
9546 $as_echo_n "checking for std::thread... " >&6; }
9547 if ${gdb_cv_cxx_std_thread+:} false; then :
9548 $as_echo_n "(cached) " >&6
9549 else
9550 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9551 /* end confdefs.h. */
9552 #if defined (__MINGW32__) || defined (__CYGWIN__)
9553 # ifdef _WIN32_WINNT
9554 # if _WIN32_WINNT < 0x0501
9555 # undef _WIN32_WINNT
9556 # define _WIN32_WINNT 0x0501
9557 # endif
9558 # else
9559 # define _WIN32_WINNT 0x0501
9560 # endif
9561 #endif /* __MINGW32__ || __CYGWIN__ */
9562 #include <thread>
9563 void callback() { }
9565 main ()
9567 std::thread t(callback);
9569 return 0;
9571 _ACEOF
9572 if ac_fn_cxx_try_compile "$LINENO"; then :
9573 gdb_cv_cxx_std_thread=yes
9574 else
9575 gdb_cv_cxx_std_thread=no
9577 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9579 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_cxx_std_thread" >&5
9580 $as_echo "$gdb_cv_cxx_std_thread" >&6; }
9582 if test "$threads" = "yes"; then
9583 # This check must be here, while LIBS includes any necessary
9584 # threading library.
9585 for ac_func in pthread_sigmask pthread_setname_np
9586 do :
9587 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
9588 ac_fn_cxx_check_func "$LINENO" "$ac_func" "$as_ac_var"
9589 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
9590 cat >>confdefs.h <<_ACEOF
9591 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
9592 _ACEOF
9595 done
9598 LIBS="$save_LIBS"
9599 CXXFLAGS="$save_CXXFLAGS"
9601 if test "$want_threading" = "yes"; then
9602 if test "$gdb_cv_cxx_std_thread" = "yes"; then
9604 $as_echo "#define CXX_STD_THREAD 1" >>confdefs.h
9608 ac_ext=c
9609 ac_cpp='$CPP $CPPFLAGS'
9610 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
9611 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
9612 ac_compiler_gnu=$ac_cv_c_compiler_gnu
9615 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigsetjmp" >&5
9616 $as_echo_n "checking for sigsetjmp... " >&6; }
9617 if ${gdb_cv_func_sigsetjmp+:} false; then :
9618 $as_echo_n "(cached) " >&6
9619 else
9620 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9621 /* end confdefs.h. */
9622 #include <setjmp.h>
9624 main ()
9626 sigjmp_buf env;
9627 while (! sigsetjmp (env, 1))
9628 siglongjmp (env, 1);
9631 return 0;
9633 _ACEOF
9634 if ac_fn_c_try_compile "$LINENO"; then :
9635 gdb_cv_func_sigsetjmp=yes
9636 else
9637 gdb_cv_func_sigsetjmp=no
9640 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_func_sigsetjmp" >&5
9644 $as_echo "$gdb_cv_func_sigsetjmp" >&6; }
9645 if test "$gdb_cv_func_sigsetjmp" = "yes"; then
9647 $as_echo "#define HAVE_SIGSETJMP 1" >>confdefs.h
9652 # Check whether --with-intel_pt was given.
9653 if test "${with_intel_pt+set}" = set; then :
9654 withval=$with_intel_pt;
9655 else
9656 with_intel_pt=auto
9659 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use intel pt" >&5
9660 $as_echo_n "checking whether to use intel pt... " >&6; }
9661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_intel_pt" >&5
9662 $as_echo "$with_intel_pt" >&6; }
9664 if test "${with_intel_pt}" = no; then
9665 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Intel Processor Trace support disabled; some features may be unavailable." >&5
9666 $as_echo "$as_me: WARNING: Intel Processor Trace support disabled; some features may be unavailable." >&2;}
9667 HAVE_LIBIPT=no
9668 else
9669 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9670 /* end confdefs.h. */
9672 #include <linux/perf_event.h>
9673 #ifndef PERF_ATTR_SIZE_VER5
9674 # error
9675 #endif
9677 _ACEOF
9678 if ac_fn_c_try_cpp "$LINENO"; then :
9679 perf_event=yes
9680 else
9681 perf_event=no
9683 rm -f conftest.err conftest.i conftest.$ac_ext
9684 if test "$perf_event" != yes; then
9685 if test "$with_intel_pt" = yes; then
9686 as_fn_error $? "linux/perf_event.h missing or too old" "$LINENO" 5
9687 else
9688 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: linux/perf_event.h missing or too old; some features may be unavailable." >&5
9689 $as_echo "$as_me: WARNING: linux/perf_event.h missing or too old; some features may be unavailable." >&2;}
9701 use_additional=yes
9703 acl_save_prefix="$prefix"
9704 prefix="$acl_final_prefix"
9705 acl_save_exec_prefix="$exec_prefix"
9706 exec_prefix="$acl_final_exec_prefix"
9708 eval additional_includedir=\"$includedir\"
9709 eval additional_libdir=\"$libdir\"
9711 exec_prefix="$acl_save_exec_prefix"
9712 prefix="$acl_save_prefix"
9715 # Check whether --with-libipt-prefix was given.
9716 if test "${with_libipt_prefix+set}" = set; then :
9717 withval=$with_libipt_prefix;
9718 if test "X$withval" = "Xno"; then
9719 use_additional=no
9720 else
9721 if test "X$withval" = "X"; then
9723 acl_save_prefix="$prefix"
9724 prefix="$acl_final_prefix"
9725 acl_save_exec_prefix="$exec_prefix"
9726 exec_prefix="$acl_final_exec_prefix"
9728 eval additional_includedir=\"$includedir\"
9729 eval additional_libdir=\"$libdir\"
9731 exec_prefix="$acl_save_exec_prefix"
9732 prefix="$acl_save_prefix"
9734 else
9735 additional_includedir="$withval/include"
9736 additional_libdir="$withval/lib"
9743 # Check whether --with-libipt-type was given.
9744 if test "${with_libipt_type+set}" = set; then :
9745 withval=$with_libipt_type; with_libipt_type=$withval
9746 else
9747 with_libipt_type=auto
9750 lib_type=`eval echo \$with_libipt_type`
9752 LIBIPT=
9753 LTLIBIPT=
9754 INCIPT=
9755 rpathdirs=
9756 ltrpathdirs=
9757 names_already_handled=
9758 names_next_round='ipt '
9759 while test -n "$names_next_round"; do
9760 names_this_round="$names_next_round"
9761 names_next_round=
9762 for name in $names_this_round; do
9763 already_handled=
9764 for n in $names_already_handled; do
9765 if test "$n" = "$name"; then
9766 already_handled=yes
9767 break
9769 done
9770 if test -z "$already_handled"; then
9771 names_already_handled="$names_already_handled $name"
9772 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
9773 eval value=\"\$HAVE_LIB$uppername\"
9774 if test -n "$value"; then
9775 if test "$value" = yes; then
9776 eval value=\"\$LIB$uppername\"
9777 test -z "$value" || LIBIPT="${LIBIPT}${LIBIPT:+ }$value"
9778 eval value=\"\$LTLIB$uppername\"
9779 test -z "$value" || LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }$value"
9780 else
9783 else
9784 found_dir=
9785 found_la=
9786 found_so=
9787 found_a=
9788 if test $use_additional = yes; then
9789 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
9790 found_dir="$additional_libdir"
9791 found_so="$additional_libdir/lib$name.$shlibext"
9792 if test -f "$additional_libdir/lib$name.la"; then
9793 found_la="$additional_libdir/lib$name.la"
9795 elif test x$lib_type != xshared; then
9796 if test -f "$additional_libdir/lib$name.$libext"; then
9797 found_dir="$additional_libdir"
9798 found_a="$additional_libdir/lib$name.$libext"
9799 if test -f "$additional_libdir/lib$name.la"; then
9800 found_la="$additional_libdir/lib$name.la"
9805 if test "X$found_dir" = "X"; then
9806 for x in $LDFLAGS $LTLIBIPT; do
9808 acl_save_prefix="$prefix"
9809 prefix="$acl_final_prefix"
9810 acl_save_exec_prefix="$exec_prefix"
9811 exec_prefix="$acl_final_exec_prefix"
9812 eval x=\"$x\"
9813 exec_prefix="$acl_save_exec_prefix"
9814 prefix="$acl_save_prefix"
9816 case "$x" in
9817 -L*)
9818 dir=`echo "X$x" | sed -e 's/^X-L//'`
9819 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
9820 found_dir="$dir"
9821 found_so="$dir/lib$name.$shlibext"
9822 if test -f "$dir/lib$name.la"; then
9823 found_la="$dir/lib$name.la"
9825 elif test x$lib_type != xshared; then
9826 if test -f "$dir/lib$name.$libext"; then
9827 found_dir="$dir"
9828 found_a="$dir/lib$name.$libext"
9829 if test -f "$dir/lib$name.la"; then
9830 found_la="$dir/lib$name.la"
9835 esac
9836 if test "X$found_dir" != "X"; then
9837 break
9839 done
9841 if test "X$found_dir" != "X"; then
9842 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-L$found_dir -l$name"
9843 if test "X$found_so" != "X"; then
9844 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
9845 LIBIPT="${LIBIPT}${LIBIPT:+ }$found_so"
9846 else
9847 haveit=
9848 for x in $ltrpathdirs; do
9849 if test "X$x" = "X$found_dir"; then
9850 haveit=yes
9851 break
9853 done
9854 if test -z "$haveit"; then
9855 ltrpathdirs="$ltrpathdirs $found_dir"
9857 if test "$hardcode_direct" = yes; then
9858 LIBIPT="${LIBIPT}${LIBIPT:+ }$found_so"
9859 else
9860 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
9861 LIBIPT="${LIBIPT}${LIBIPT:+ }$found_so"
9862 haveit=
9863 for x in $rpathdirs; do
9864 if test "X$x" = "X$found_dir"; then
9865 haveit=yes
9866 break
9868 done
9869 if test -z "$haveit"; then
9870 rpathdirs="$rpathdirs $found_dir"
9872 else
9873 haveit=
9874 for x in $LDFLAGS $LIBIPT; do
9876 acl_save_prefix="$prefix"
9877 prefix="$acl_final_prefix"
9878 acl_save_exec_prefix="$exec_prefix"
9879 exec_prefix="$acl_final_exec_prefix"
9880 eval x=\"$x\"
9881 exec_prefix="$acl_save_exec_prefix"
9882 prefix="$acl_save_prefix"
9884 if test "X$x" = "X-L$found_dir"; then
9885 haveit=yes
9886 break
9888 done
9889 if test -z "$haveit"; then
9890 LIBIPT="${LIBIPT}${LIBIPT:+ }-L$found_dir"
9892 if test "$hardcode_minus_L" != no; then
9893 LIBIPT="${LIBIPT}${LIBIPT:+ }$found_so"
9894 else
9895 LIBIPT="${LIBIPT}${LIBIPT:+ }-l$name"
9900 else
9901 if test "X$found_a" != "X"; then
9902 LIBIPT="${LIBIPT}${LIBIPT:+ }$found_a"
9903 else
9904 LIBIPT="${LIBIPT}${LIBIPT:+ }-L$found_dir -l$name"
9907 additional_includedir=
9908 case "$found_dir" in
9909 */lib | */lib/)
9910 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
9911 additional_includedir="$basedir/include"
9913 esac
9914 if test "X$additional_includedir" != "X"; then
9915 if test "X$additional_includedir" != "X/usr/include"; then
9916 haveit=
9917 if test "X$additional_includedir" = "X/usr/local/include"; then
9918 if test -n "$GCC"; then
9919 case $host_os in
9920 linux*) haveit=yes;;
9921 esac
9924 if test -z "$haveit"; then
9925 for x in $CPPFLAGS $INCIPT; do
9927 acl_save_prefix="$prefix"
9928 prefix="$acl_final_prefix"
9929 acl_save_exec_prefix="$exec_prefix"
9930 exec_prefix="$acl_final_exec_prefix"
9931 eval x=\"$x\"
9932 exec_prefix="$acl_save_exec_prefix"
9933 prefix="$acl_save_prefix"
9935 if test "X$x" = "X-I$additional_includedir"; then
9936 haveit=yes
9937 break
9939 done
9940 if test -z "$haveit"; then
9941 if test -d "$additional_includedir"; then
9942 INCIPT="${INCIPT}${INCIPT:+ }-I$additional_includedir"
9948 if test -n "$found_la"; then
9949 save_libdir="$libdir"
9950 case "$found_la" in
9951 */* | *\\*) . "$found_la" ;;
9952 *) . "./$found_la" ;;
9953 esac
9954 libdir="$save_libdir"
9955 for dep in $dependency_libs; do
9956 case "$dep" in
9957 -L*)
9958 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
9959 if test "X$additional_libdir" != "X/usr/lib"; then
9960 haveit=
9961 if test "X$additional_libdir" = "X/usr/local/lib"; then
9962 if test -n "$GCC"; then
9963 case $host_os in
9964 linux*) haveit=yes;;
9965 esac
9968 if test -z "$haveit"; then
9969 haveit=
9970 for x in $LDFLAGS $LIBIPT; do
9972 acl_save_prefix="$prefix"
9973 prefix="$acl_final_prefix"
9974 acl_save_exec_prefix="$exec_prefix"
9975 exec_prefix="$acl_final_exec_prefix"
9976 eval x=\"$x\"
9977 exec_prefix="$acl_save_exec_prefix"
9978 prefix="$acl_save_prefix"
9980 if test "X$x" = "X-L$additional_libdir"; then
9981 haveit=yes
9982 break
9984 done
9985 if test -z "$haveit"; then
9986 if test -d "$additional_libdir"; then
9987 LIBIPT="${LIBIPT}${LIBIPT:+ }-L$additional_libdir"
9990 haveit=
9991 for x in $LDFLAGS $LTLIBIPT; do
9993 acl_save_prefix="$prefix"
9994 prefix="$acl_final_prefix"
9995 acl_save_exec_prefix="$exec_prefix"
9996 exec_prefix="$acl_final_exec_prefix"
9997 eval x=\"$x\"
9998 exec_prefix="$acl_save_exec_prefix"
9999 prefix="$acl_save_prefix"
10001 if test "X$x" = "X-L$additional_libdir"; then
10002 haveit=yes
10003 break
10005 done
10006 if test -z "$haveit"; then
10007 if test -d "$additional_libdir"; then
10008 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-L$additional_libdir"
10014 -R*)
10015 dir=`echo "X$dep" | sed -e 's/^X-R//'`
10016 if test "$enable_rpath" != no; then
10017 haveit=
10018 for x in $rpathdirs; do
10019 if test "X$x" = "X$dir"; then
10020 haveit=yes
10021 break
10023 done
10024 if test -z "$haveit"; then
10025 rpathdirs="$rpathdirs $dir"
10027 haveit=
10028 for x in $ltrpathdirs; do
10029 if test "X$x" = "X$dir"; then
10030 haveit=yes
10031 break
10033 done
10034 if test -z "$haveit"; then
10035 ltrpathdirs="$ltrpathdirs $dir"
10039 -l*)
10040 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
10042 *.la)
10043 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
10046 LIBIPT="${LIBIPT}${LIBIPT:+ }$dep"
10047 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }$dep"
10049 esac
10050 done
10052 else
10053 if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
10054 LIBIPT="${LIBIPT}${LIBIPT:+ }-l$name"
10055 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-l$name"
10056 else
10057 LIBIPT="${LIBIPT}${LIBIPT:+ }-l:lib$name.$libext"
10058 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-l:lib$name.$libext"
10063 done
10064 done
10065 if test "X$rpathdirs" != "X"; then
10066 if test -n "$hardcode_libdir_separator"; then
10067 alldirs=
10068 for found_dir in $rpathdirs; do
10069 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
10070 done
10071 acl_save_libdir="$libdir"
10072 libdir="$alldirs"
10073 eval flag=\"$hardcode_libdir_flag_spec\"
10074 libdir="$acl_save_libdir"
10075 LIBIPT="${LIBIPT}${LIBIPT:+ }$flag"
10076 else
10077 for found_dir in $rpathdirs; do
10078 acl_save_libdir="$libdir"
10079 libdir="$found_dir"
10080 eval flag=\"$hardcode_libdir_flag_spec\"
10081 libdir="$acl_save_libdir"
10082 LIBIPT="${LIBIPT}${LIBIPT:+ }$flag"
10083 done
10086 if test "X$ltrpathdirs" != "X"; then
10087 for found_dir in $ltrpathdirs; do
10088 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-R$found_dir"
10089 done
10093 ac_save_CPPFLAGS="$CPPFLAGS"
10095 for element in $INCIPT; do
10096 haveit=
10097 for x in $CPPFLAGS; do
10099 acl_save_prefix="$prefix"
10100 prefix="$acl_final_prefix"
10101 acl_save_exec_prefix="$exec_prefix"
10102 exec_prefix="$acl_final_exec_prefix"
10103 eval x=\"$x\"
10104 exec_prefix="$acl_save_exec_prefix"
10105 prefix="$acl_save_prefix"
10107 if test "X$x" = "X$element"; then
10108 haveit=yes
10109 break
10111 done
10112 if test -z "$haveit"; then
10113 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
10115 done
10118 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libipt" >&5
10119 $as_echo_n "checking for libipt... " >&6; }
10120 if ${ac_cv_libipt+:} false; then :
10121 $as_echo_n "(cached) " >&6
10122 else
10124 ac_save_LIBS="$LIBS"
10125 LIBS="$LIBS $LIBIPT"
10126 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10127 /* end confdefs.h. */
10128 #include "intel-pt.h"
10130 main ()
10132 pt_insn_alloc_decoder (0);
10134 return 0;
10136 _ACEOF
10137 if ac_fn_c_try_link "$LINENO"; then :
10138 ac_cv_libipt=yes
10139 else
10140 ac_cv_libipt=no
10142 rm -f core conftest.err conftest.$ac_objext \
10143 conftest$ac_exeext conftest.$ac_ext
10144 LIBS="$ac_save_LIBS"
10147 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libipt" >&5
10148 $as_echo "$ac_cv_libipt" >&6; }
10149 if test "$ac_cv_libipt" = yes; then
10150 HAVE_LIBIPT=yes
10152 $as_echo "#define HAVE_LIBIPT 1" >>confdefs.h
10154 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libipt" >&5
10155 $as_echo_n "checking how to link with libipt... " >&6; }
10156 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBIPT" >&5
10157 $as_echo "$LIBIPT" >&6; }
10158 else
10159 HAVE_LIBIPT=no
10160 CPPFLAGS="$ac_save_CPPFLAGS"
10161 LIBIPT=
10162 LTLIBIPT=
10170 if test "$HAVE_LIBIPT" != yes; then
10171 if test "$with_intel_pt" = yes; then
10172 as_fn_error $? "libipt is missing or unusable" "$LINENO" 5
10173 else
10174 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libipt is missing or unusable; some features may be unavailable." >&5
10175 $as_echo "$as_me: WARNING: libipt is missing or unusable; some features may be unavailable." >&2;}
10177 else
10178 save_LIBS=$LIBS
10179 LIBS="$LIBS $LIBIPT"
10180 for ac_func in pt_insn_event
10181 do :
10182 ac_fn_c_check_func "$LINENO" "pt_insn_event" "ac_cv_func_pt_insn_event"
10183 if test "x$ac_cv_func_pt_insn_event" = xyes; then :
10184 cat >>confdefs.h <<_ACEOF
10185 #define HAVE_PT_INSN_EVENT 1
10186 _ACEOF
10189 done
10191 ac_fn_c_check_member "$LINENO" "struct pt_insn" "enabled" "ac_cv_member_struct_pt_insn_enabled" "#include <intel-pt.h>
10193 if test "x$ac_cv_member_struct_pt_insn_enabled" = xyes; then :
10195 cat >>confdefs.h <<_ACEOF
10196 #define HAVE_STRUCT_PT_INSN_ENABLED 1
10197 _ACEOF
10201 ac_fn_c_check_member "$LINENO" "struct pt_insn" "resynced" "ac_cv_member_struct_pt_insn_resynced" "#include <intel-pt.h>
10203 if test "x$ac_cv_member_struct_pt_insn_resynced" = xyes; then :
10205 cat >>confdefs.h <<_ACEOF
10206 #define HAVE_STRUCT_PT_INSN_RESYNCED 1
10207 _ACEOF
10212 LIBS=$save_LIBS
10216 # Check if the compiler and runtime support printing long longs.
10218 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long support in printf" >&5
10219 $as_echo_n "checking for long long support in printf... " >&6; }
10220 if ${gdb_cv_printf_has_long_long+:} false; then :
10221 $as_echo_n "(cached) " >&6
10222 else
10223 if test "$cross_compiling" = yes; then :
10224 gdb_cv_printf_has_long_long=no
10225 else
10226 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10227 /* end confdefs.h. */
10228 $ac_includes_default
10230 main ()
10232 char buf[32];
10233 long long l = 0;
10234 l = (l << 16) + 0x0123;
10235 l = (l << 16) + 0x4567;
10236 l = (l << 16) + 0x89ab;
10237 l = (l << 16) + 0xcdef;
10238 sprintf (buf, "0x%016llx", l);
10239 return (strcmp ("0x0123456789abcdef", buf));
10241 return 0;
10243 _ACEOF
10244 if ac_fn_c_try_run "$LINENO"; then :
10245 gdb_cv_printf_has_long_long=yes
10246 else
10247 gdb_cv_printf_has_long_long=no
10249 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10250 conftest.$ac_objext conftest.beam conftest.$ac_ext
10254 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_printf_has_long_long" >&5
10255 $as_echo "$gdb_cv_printf_has_long_long" >&6; }
10256 if test "$gdb_cv_printf_has_long_long" = yes; then
10258 $as_echo "#define PRINTF_HAS_LONG_LONG 1" >>confdefs.h
10263 $as_echo "#define _STRUCTURED_PROC 1" >>confdefs.h
10265 for ac_header in sys/procfs.h
10266 do :
10267 ac_fn_c_check_header_mongrel "$LINENO" "sys/procfs.h" "ac_cv_header_sys_procfs_h" "$ac_includes_default"
10268 if test "x$ac_cv_header_sys_procfs_h" = xyes; then :
10269 cat >>confdefs.h <<_ACEOF
10270 #define HAVE_SYS_PROCFS_H 1
10271 _ACEOF
10275 done
10277 if test "$ac_cv_header_sys_procfs_h" = yes; then
10279 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gregset_t in sys/procfs.h" >&5
10280 $as_echo_n "checking for gregset_t in sys/procfs.h... " >&6; }
10281 if ${bfd_cv_have_sys_procfs_type_gregset_t+:} false; then :
10282 $as_echo_n "(cached) " >&6
10283 else
10284 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10285 /* end confdefs.h. */
10287 #define _SYSCALL32
10288 #include <sys/procfs.h>
10290 main ()
10292 gregset_t avar
10294 return 0;
10296 _ACEOF
10297 if ac_fn_c_try_compile "$LINENO"; then :
10298 bfd_cv_have_sys_procfs_type_gregset_t=yes
10299 else
10300 bfd_cv_have_sys_procfs_type_gregset_t=no
10303 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10306 if test $bfd_cv_have_sys_procfs_type_gregset_t = yes; then
10308 $as_echo "#define HAVE_GREGSET_T 1" >>confdefs.h
10311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_gregset_t" >&5
10312 $as_echo "$bfd_cv_have_sys_procfs_type_gregset_t" >&6; }
10315 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fpregset_t in sys/procfs.h" >&5
10316 $as_echo_n "checking for fpregset_t in sys/procfs.h... " >&6; }
10317 if ${bfd_cv_have_sys_procfs_type_fpregset_t+:} false; then :
10318 $as_echo_n "(cached) " >&6
10319 else
10320 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10321 /* end confdefs.h. */
10323 #define _SYSCALL32
10324 #include <sys/procfs.h>
10326 main ()
10328 fpregset_t avar
10330 return 0;
10332 _ACEOF
10333 if ac_fn_c_try_compile "$LINENO"; then :
10334 bfd_cv_have_sys_procfs_type_fpregset_t=yes
10335 else
10336 bfd_cv_have_sys_procfs_type_fpregset_t=no
10339 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10342 if test $bfd_cv_have_sys_procfs_type_fpregset_t = yes; then
10344 $as_echo "#define HAVE_FPREGSET_T 1" >>confdefs.h
10347 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_fpregset_t" >&5
10348 $as_echo "$bfd_cv_have_sys_procfs_type_fpregset_t" >&6; }
10351 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prgregset_t in sys/procfs.h" >&5
10352 $as_echo_n "checking for prgregset_t in sys/procfs.h... " >&6; }
10353 if ${bfd_cv_have_sys_procfs_type_prgregset_t+:} false; then :
10354 $as_echo_n "(cached) " >&6
10355 else
10356 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10357 /* end confdefs.h. */
10359 #define _SYSCALL32
10360 #include <sys/procfs.h>
10362 main ()
10364 prgregset_t avar
10366 return 0;
10368 _ACEOF
10369 if ac_fn_c_try_compile "$LINENO"; then :
10370 bfd_cv_have_sys_procfs_type_prgregset_t=yes
10371 else
10372 bfd_cv_have_sys_procfs_type_prgregset_t=no
10375 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10378 if test $bfd_cv_have_sys_procfs_type_prgregset_t = yes; then
10380 $as_echo "#define HAVE_PRGREGSET_T 1" >>confdefs.h
10383 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prgregset_t" >&5
10384 $as_echo "$bfd_cv_have_sys_procfs_type_prgregset_t" >&6; }
10387 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prfpregset_t in sys/procfs.h" >&5
10388 $as_echo_n "checking for prfpregset_t in sys/procfs.h... " >&6; }
10389 if ${bfd_cv_have_sys_procfs_type_prfpregset_t+:} false; then :
10390 $as_echo_n "(cached) " >&6
10391 else
10392 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10393 /* end confdefs.h. */
10395 #define _SYSCALL32
10396 #include <sys/procfs.h>
10398 main ()
10400 prfpregset_t avar
10402 return 0;
10404 _ACEOF
10405 if ac_fn_c_try_compile "$LINENO"; then :
10406 bfd_cv_have_sys_procfs_type_prfpregset_t=yes
10407 else
10408 bfd_cv_have_sys_procfs_type_prfpregset_t=no
10411 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10414 if test $bfd_cv_have_sys_procfs_type_prfpregset_t = yes; then
10416 $as_echo "#define HAVE_PRFPREGSET_T 1" >>confdefs.h
10419 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prfpregset_t" >&5
10420 $as_echo "$bfd_cv_have_sys_procfs_type_prfpregset_t" >&6; }
10423 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prgregset32_t in sys/procfs.h" >&5
10424 $as_echo_n "checking for prgregset32_t in sys/procfs.h... " >&6; }
10425 if ${bfd_cv_have_sys_procfs_type_prgregset32_t+:} false; then :
10426 $as_echo_n "(cached) " >&6
10427 else
10428 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10429 /* end confdefs.h. */
10431 #define _SYSCALL32
10432 #include <sys/procfs.h>
10434 main ()
10436 prgregset32_t avar
10438 return 0;
10440 _ACEOF
10441 if ac_fn_c_try_compile "$LINENO"; then :
10442 bfd_cv_have_sys_procfs_type_prgregset32_t=yes
10443 else
10444 bfd_cv_have_sys_procfs_type_prgregset32_t=no
10447 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10450 if test $bfd_cv_have_sys_procfs_type_prgregset32_t = yes; then
10452 $as_echo "#define HAVE_PRGREGSET32_T 1" >>confdefs.h
10455 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prgregset32_t" >&5
10456 $as_echo "$bfd_cv_have_sys_procfs_type_prgregset32_t" >&6; }
10459 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lwpid_t in sys/procfs.h" >&5
10460 $as_echo_n "checking for lwpid_t in sys/procfs.h... " >&6; }
10461 if ${bfd_cv_have_sys_procfs_type_lwpid_t+:} false; then :
10462 $as_echo_n "(cached) " >&6
10463 else
10464 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10465 /* end confdefs.h. */
10467 #define _SYSCALL32
10468 #include <sys/procfs.h>
10470 main ()
10472 lwpid_t avar
10474 return 0;
10476 _ACEOF
10477 if ac_fn_c_try_compile "$LINENO"; then :
10478 bfd_cv_have_sys_procfs_type_lwpid_t=yes
10479 else
10480 bfd_cv_have_sys_procfs_type_lwpid_t=no
10483 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10486 if test $bfd_cv_have_sys_procfs_type_lwpid_t = yes; then
10488 $as_echo "#define HAVE_LWPID_T 1" >>confdefs.h
10491 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_lwpid_t" >&5
10492 $as_echo "$bfd_cv_have_sys_procfs_type_lwpid_t" >&6; }
10495 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for psaddr_t in sys/procfs.h" >&5
10496 $as_echo_n "checking for psaddr_t in sys/procfs.h... " >&6; }
10497 if ${bfd_cv_have_sys_procfs_type_psaddr_t+:} false; then :
10498 $as_echo_n "(cached) " >&6
10499 else
10500 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10501 /* end confdefs.h. */
10503 #define _SYSCALL32
10504 #include <sys/procfs.h>
10506 main ()
10508 psaddr_t avar
10510 return 0;
10512 _ACEOF
10513 if ac_fn_c_try_compile "$LINENO"; then :
10514 bfd_cv_have_sys_procfs_type_psaddr_t=yes
10515 else
10516 bfd_cv_have_sys_procfs_type_psaddr_t=no
10519 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10522 if test $bfd_cv_have_sys_procfs_type_psaddr_t = yes; then
10524 $as_echo "#define HAVE_PSADDR_T 1" >>confdefs.h
10527 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_psaddr_t" >&5
10528 $as_echo "$bfd_cv_have_sys_procfs_type_psaddr_t" >&6; }
10531 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for elf_fpregset_t in sys/procfs.h" >&5
10532 $as_echo_n "checking for elf_fpregset_t in sys/procfs.h... " >&6; }
10533 if ${bfd_cv_have_sys_procfs_type_elf_fpregset_t+:} false; then :
10534 $as_echo_n "(cached) " >&6
10535 else
10536 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10537 /* end confdefs.h. */
10539 #define _SYSCALL32
10540 #include <sys/procfs.h>
10542 main ()
10544 elf_fpregset_t avar
10546 return 0;
10548 _ACEOF
10549 if ac_fn_c_try_compile "$LINENO"; then :
10550 bfd_cv_have_sys_procfs_type_elf_fpregset_t=yes
10551 else
10552 bfd_cv_have_sys_procfs_type_elf_fpregset_t=no
10555 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10558 if test $bfd_cv_have_sys_procfs_type_elf_fpregset_t = yes; then
10560 $as_echo "#define HAVE_ELF_FPREGSET_T 1" >>confdefs.h
10563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_elf_fpregset_t" >&5
10564 $as_echo "$bfd_cv_have_sys_procfs_type_elf_fpregset_t" >&6; }
10568 # Check for xxhash
10570 # Check whether --with-xxhash was given.
10571 if test "${with_xxhash+set}" = set; then :
10572 withval=$with_xxhash;
10573 else
10574 with_xxhash=auto
10578 if test "x$with_xxhash" != "xno"; then
10587 use_additional=yes
10589 acl_save_prefix="$prefix"
10590 prefix="$acl_final_prefix"
10591 acl_save_exec_prefix="$exec_prefix"
10592 exec_prefix="$acl_final_exec_prefix"
10594 eval additional_includedir=\"$includedir\"
10595 eval additional_libdir=\"$libdir\"
10597 exec_prefix="$acl_save_exec_prefix"
10598 prefix="$acl_save_prefix"
10601 # Check whether --with-libxxhash-prefix was given.
10602 if test "${with_libxxhash_prefix+set}" = set; then :
10603 withval=$with_libxxhash_prefix;
10604 if test "X$withval" = "Xno"; then
10605 use_additional=no
10606 else
10607 if test "X$withval" = "X"; then
10609 acl_save_prefix="$prefix"
10610 prefix="$acl_final_prefix"
10611 acl_save_exec_prefix="$exec_prefix"
10612 exec_prefix="$acl_final_exec_prefix"
10614 eval additional_includedir=\"$includedir\"
10615 eval additional_libdir=\"$libdir\"
10617 exec_prefix="$acl_save_exec_prefix"
10618 prefix="$acl_save_prefix"
10620 else
10621 additional_includedir="$withval/include"
10622 additional_libdir="$withval/lib"
10629 # Check whether --with-libxxhash-type was given.
10630 if test "${with_libxxhash_type+set}" = set; then :
10631 withval=$with_libxxhash_type; with_libxxhash_type=$withval
10632 else
10633 with_libxxhash_type=auto
10636 lib_type=`eval echo \$with_libxxhash_type`
10638 LIBXXHASH=
10639 LTLIBXXHASH=
10640 INCXXHASH=
10641 rpathdirs=
10642 ltrpathdirs=
10643 names_already_handled=
10644 names_next_round='xxhash '
10645 while test -n "$names_next_round"; do
10646 names_this_round="$names_next_round"
10647 names_next_round=
10648 for name in $names_this_round; do
10649 already_handled=
10650 for n in $names_already_handled; do
10651 if test "$n" = "$name"; then
10652 already_handled=yes
10653 break
10655 done
10656 if test -z "$already_handled"; then
10657 names_already_handled="$names_already_handled $name"
10658 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
10659 eval value=\"\$HAVE_LIB$uppername\"
10660 if test -n "$value"; then
10661 if test "$value" = yes; then
10662 eval value=\"\$LIB$uppername\"
10663 test -z "$value" || LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$value"
10664 eval value=\"\$LTLIB$uppername\"
10665 test -z "$value" || LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }$value"
10666 else
10669 else
10670 found_dir=
10671 found_la=
10672 found_so=
10673 found_a=
10674 if test $use_additional = yes; then
10675 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
10676 found_dir="$additional_libdir"
10677 found_so="$additional_libdir/lib$name.$shlibext"
10678 if test -f "$additional_libdir/lib$name.la"; then
10679 found_la="$additional_libdir/lib$name.la"
10681 elif test x$lib_type != xshared; then
10682 if test -f "$additional_libdir/lib$name.$libext"; then
10683 found_dir="$additional_libdir"
10684 found_a="$additional_libdir/lib$name.$libext"
10685 if test -f "$additional_libdir/lib$name.la"; then
10686 found_la="$additional_libdir/lib$name.la"
10691 if test "X$found_dir" = "X"; then
10692 for x in $LDFLAGS $LTLIBXXHASH; do
10694 acl_save_prefix="$prefix"
10695 prefix="$acl_final_prefix"
10696 acl_save_exec_prefix="$exec_prefix"
10697 exec_prefix="$acl_final_exec_prefix"
10698 eval x=\"$x\"
10699 exec_prefix="$acl_save_exec_prefix"
10700 prefix="$acl_save_prefix"
10702 case "$x" in
10703 -L*)
10704 dir=`echo "X$x" | sed -e 's/^X-L//'`
10705 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
10706 found_dir="$dir"
10707 found_so="$dir/lib$name.$shlibext"
10708 if test -f "$dir/lib$name.la"; then
10709 found_la="$dir/lib$name.la"
10711 elif test x$lib_type != xshared; then
10712 if test -f "$dir/lib$name.$libext"; then
10713 found_dir="$dir"
10714 found_a="$dir/lib$name.$libext"
10715 if test -f "$dir/lib$name.la"; then
10716 found_la="$dir/lib$name.la"
10721 esac
10722 if test "X$found_dir" != "X"; then
10723 break
10725 done
10727 if test "X$found_dir" != "X"; then
10728 LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }-L$found_dir -l$name"
10729 if test "X$found_so" != "X"; then
10730 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
10731 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$found_so"
10732 else
10733 haveit=
10734 for x in $ltrpathdirs; do
10735 if test "X$x" = "X$found_dir"; then
10736 haveit=yes
10737 break
10739 done
10740 if test -z "$haveit"; then
10741 ltrpathdirs="$ltrpathdirs $found_dir"
10743 if test "$hardcode_direct" = yes; then
10744 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$found_so"
10745 else
10746 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
10747 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$found_so"
10748 haveit=
10749 for x in $rpathdirs; do
10750 if test "X$x" = "X$found_dir"; then
10751 haveit=yes
10752 break
10754 done
10755 if test -z "$haveit"; then
10756 rpathdirs="$rpathdirs $found_dir"
10758 else
10759 haveit=
10760 for x in $LDFLAGS $LIBXXHASH; do
10762 acl_save_prefix="$prefix"
10763 prefix="$acl_final_prefix"
10764 acl_save_exec_prefix="$exec_prefix"
10765 exec_prefix="$acl_final_exec_prefix"
10766 eval x=\"$x\"
10767 exec_prefix="$acl_save_exec_prefix"
10768 prefix="$acl_save_prefix"
10770 if test "X$x" = "X-L$found_dir"; then
10771 haveit=yes
10772 break
10774 done
10775 if test -z "$haveit"; then
10776 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }-L$found_dir"
10778 if test "$hardcode_minus_L" != no; then
10779 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$found_so"
10780 else
10781 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }-l$name"
10786 else
10787 if test "X$found_a" != "X"; then
10788 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$found_a"
10789 else
10790 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }-L$found_dir -l$name"
10793 additional_includedir=
10794 case "$found_dir" in
10795 */lib | */lib/)
10796 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
10797 additional_includedir="$basedir/include"
10799 esac
10800 if test "X$additional_includedir" != "X"; then
10801 if test "X$additional_includedir" != "X/usr/include"; then
10802 haveit=
10803 if test "X$additional_includedir" = "X/usr/local/include"; then
10804 if test -n "$GCC"; then
10805 case $host_os in
10806 linux*) haveit=yes;;
10807 esac
10810 if test -z "$haveit"; then
10811 for x in $CPPFLAGS $INCXXHASH; do
10813 acl_save_prefix="$prefix"
10814 prefix="$acl_final_prefix"
10815 acl_save_exec_prefix="$exec_prefix"
10816 exec_prefix="$acl_final_exec_prefix"
10817 eval x=\"$x\"
10818 exec_prefix="$acl_save_exec_prefix"
10819 prefix="$acl_save_prefix"
10821 if test "X$x" = "X-I$additional_includedir"; then
10822 haveit=yes
10823 break
10825 done
10826 if test -z "$haveit"; then
10827 if test -d "$additional_includedir"; then
10828 INCXXHASH="${INCXXHASH}${INCXXHASH:+ }-I$additional_includedir"
10834 if test -n "$found_la"; then
10835 save_libdir="$libdir"
10836 case "$found_la" in
10837 */* | *\\*) . "$found_la" ;;
10838 *) . "./$found_la" ;;
10839 esac
10840 libdir="$save_libdir"
10841 for dep in $dependency_libs; do
10842 case "$dep" in
10843 -L*)
10844 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
10845 if test "X$additional_libdir" != "X/usr/lib"; then
10846 haveit=
10847 if test "X$additional_libdir" = "X/usr/local/lib"; then
10848 if test -n "$GCC"; then
10849 case $host_os in
10850 linux*) haveit=yes;;
10851 esac
10854 if test -z "$haveit"; then
10855 haveit=
10856 for x in $LDFLAGS $LIBXXHASH; do
10858 acl_save_prefix="$prefix"
10859 prefix="$acl_final_prefix"
10860 acl_save_exec_prefix="$exec_prefix"
10861 exec_prefix="$acl_final_exec_prefix"
10862 eval x=\"$x\"
10863 exec_prefix="$acl_save_exec_prefix"
10864 prefix="$acl_save_prefix"
10866 if test "X$x" = "X-L$additional_libdir"; then
10867 haveit=yes
10868 break
10870 done
10871 if test -z "$haveit"; then
10872 if test -d "$additional_libdir"; then
10873 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }-L$additional_libdir"
10876 haveit=
10877 for x in $LDFLAGS $LTLIBXXHASH; 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 LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }-L$additional_libdir"
10900 -R*)
10901 dir=`echo "X$dep" | sed -e 's/^X-R//'`
10902 if test "$enable_rpath" != no; then
10903 haveit=
10904 for x in $rpathdirs; do
10905 if test "X$x" = "X$dir"; then
10906 haveit=yes
10907 break
10909 done
10910 if test -z "$haveit"; then
10911 rpathdirs="$rpathdirs $dir"
10913 haveit=
10914 for x in $ltrpathdirs; do
10915 if test "X$x" = "X$dir"; then
10916 haveit=yes
10917 break
10919 done
10920 if test -z "$haveit"; then
10921 ltrpathdirs="$ltrpathdirs $dir"
10925 -l*)
10926 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
10928 *.la)
10929 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
10932 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$dep"
10933 LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }$dep"
10935 esac
10936 done
10938 else
10939 if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
10940 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }-l$name"
10941 LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }-l$name"
10942 else
10943 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }-l:lib$name.$libext"
10944 LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }-l:lib$name.$libext"
10949 done
10950 done
10951 if test "X$rpathdirs" != "X"; then
10952 if test -n "$hardcode_libdir_separator"; then
10953 alldirs=
10954 for found_dir in $rpathdirs; do
10955 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
10956 done
10957 acl_save_libdir="$libdir"
10958 libdir="$alldirs"
10959 eval flag=\"$hardcode_libdir_flag_spec\"
10960 libdir="$acl_save_libdir"
10961 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$flag"
10962 else
10963 for found_dir in $rpathdirs; do
10964 acl_save_libdir="$libdir"
10965 libdir="$found_dir"
10966 eval flag=\"$hardcode_libdir_flag_spec\"
10967 libdir="$acl_save_libdir"
10968 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$flag"
10969 done
10972 if test "X$ltrpathdirs" != "X"; then
10973 for found_dir in $ltrpathdirs; do
10974 LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }-R$found_dir"
10975 done
10979 ac_save_CPPFLAGS="$CPPFLAGS"
10981 for element in $INCXXHASH; do
10982 haveit=
10983 for x in $CPPFLAGS; do
10985 acl_save_prefix="$prefix"
10986 prefix="$acl_final_prefix"
10987 acl_save_exec_prefix="$exec_prefix"
10988 exec_prefix="$acl_final_exec_prefix"
10989 eval x=\"$x\"
10990 exec_prefix="$acl_save_exec_prefix"
10991 prefix="$acl_save_prefix"
10993 if test "X$x" = "X$element"; then
10994 haveit=yes
10995 break
10997 done
10998 if test -z "$haveit"; then
10999 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
11001 done
11004 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libxxhash" >&5
11005 $as_echo_n "checking for libxxhash... " >&6; }
11006 if ${ac_cv_libxxhash+:} false; then :
11007 $as_echo_n "(cached) " >&6
11008 else
11010 ac_save_LIBS="$LIBS"
11011 LIBS="$LIBS $LIBXXHASH"
11012 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11013 /* end confdefs.h. */
11014 #include <xxhash.h>
11016 main ()
11018 XXH32("foo", 3, 0);
11021 return 0;
11023 _ACEOF
11024 if ac_fn_c_try_link "$LINENO"; then :
11025 ac_cv_libxxhash=yes
11026 else
11027 ac_cv_libxxhash=no
11029 rm -f core conftest.err conftest.$ac_objext \
11030 conftest$ac_exeext conftest.$ac_ext
11031 LIBS="$ac_save_LIBS"
11034 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libxxhash" >&5
11035 $as_echo "$ac_cv_libxxhash" >&6; }
11036 if test "$ac_cv_libxxhash" = yes; then
11037 HAVE_LIBXXHASH=yes
11039 $as_echo "#define HAVE_LIBXXHASH 1" >>confdefs.h
11041 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libxxhash" >&5
11042 $as_echo_n "checking how to link with libxxhash... " >&6; }
11043 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBXXHASH" >&5
11044 $as_echo "$LIBXXHASH" >&6; }
11045 else
11046 HAVE_LIBXXHASH=no
11047 CPPFLAGS="$ac_save_CPPFLAGS"
11048 LIBXXHASH=
11049 LTLIBXXHASH=
11057 if test "$HAVE_LIBXXHASH" != yes; then
11058 if test "$with_xxhash" = yes; then
11059 as_fn_error $? "xxhash is missing or unusable" "$LINENO" 5
11062 if test "x$with_xxhash" = "xauto"; then
11063 with_xxhash="$HAVE_LIBXXHASH"
11067 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use xxhash" >&5
11068 $as_echo_n "checking whether to use xxhash... " >&6; }
11069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_xxhash" >&5
11070 $as_echo "$with_xxhash" >&6; }
11072 # This is set by GDB_AC_COMMON.
11076 # Check whether we will enable the inclusion of unit tests when
11077 # compiling GDB.
11079 # The default value of this option changes depending whether we're on
11080 # development mode (in which case it's "true") or not (in which case
11081 # it's "false"). The $development variable is set by the GDB_AC_COMMON
11082 # macro, which must therefore be used before GDB_AC_SELFTEST.
11084 if test "x$development" != xtrue && test "x$development" != xfalse; then :
11085 as_fn_error $? "Invalid value for \$development, got \"$development\", expecting \"true\" or \"false\"." "$LINENO" 5
11088 # Check whether --enable-unit-tests was given.
11089 if test "${enable_unit_tests+set}" = set; then :
11090 enableval=$enable_unit_tests; case "${enableval}" in
11091 yes) enable_unittests=true ;;
11092 no) enable_unittests=false ;;
11093 *) as_fn_error $? "bad value ${enableval} for --{enable,disable}-unit-tests option" "$LINENO" 5 ;;
11094 esac
11095 else
11096 enable_unittests=$development
11100 if $enable_unittests; then
11102 $as_echo "#define GDB_SELF_TEST 1" >>confdefs.h
11108 case ${build_alias} in
11109 "") build_noncanonical=${build} ;;
11110 *) build_noncanonical=${build_alias} ;;
11111 esac
11113 case ${host_alias} in
11114 "") host_noncanonical=${build_noncanonical} ;;
11115 *) host_noncanonical=${host_alias} ;;
11116 esac
11118 case ${target_alias} in
11119 "") target_noncanonical=${host_noncanonical} ;;
11120 *) target_noncanonical=${target_alias} ;;
11121 esac
11128 # Dependency checking.
11129 rm -rf .tst 2>/dev/null
11130 mkdir .tst 2>/dev/null
11131 if test -d .tst; then
11132 am__leading_dot=.
11133 else
11134 am__leading_dot=_
11136 rmdir .tst 2>/dev/null
11138 DEPDIR="${am__leading_dot}deps"
11140 ac_config_commands="$ac_config_commands depdir"
11144 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
11145 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
11146 set x ${MAKE-make}
11147 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
11148 if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then :
11149 $as_echo_n "(cached) " >&6
11150 else
11151 cat >conftest.make <<\_ACEOF
11152 SHELL = /bin/sh
11153 all:
11154 @echo '@@@%%%=$(MAKE)=@@@%%%'
11155 _ACEOF
11156 # GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
11157 case `${MAKE-make} -f conftest.make 2>/dev/null` in
11158 *@@@%%%=?*=@@@%%%*)
11159 eval ac_cv_prog_make_${ac_make}_set=yes;;
11161 eval ac_cv_prog_make_${ac_make}_set=no;;
11162 esac
11163 rm -f conftest.make
11165 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
11166 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11167 $as_echo "yes" >&6; }
11168 SET_MAKE=
11169 else
11170 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11171 $as_echo "no" >&6; }
11172 SET_MAKE="MAKE=${MAKE-make}"
11176 MKINSTALLDIRS=
11177 if test -n "$ac_aux_dir"; then
11178 case "$ac_aux_dir" in
11179 /*) MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" ;;
11180 *) MKINSTALLDIRS="\$(top_builddir)/$ac_aux_dir/mkinstalldirs" ;;
11181 esac
11183 if test -z "$MKINSTALLDIRS"; then
11184 MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs"
11189 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5
11190 $as_echo_n "checking whether NLS is requested... " >&6; }
11191 # Check whether --enable-nls was given.
11192 if test "${enable_nls+set}" = set; then :
11193 enableval=$enable_nls; USE_NLS=$enableval
11194 else
11195 USE_NLS=yes
11198 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5
11199 $as_echo "$USE_NLS" >&6; }
11206 # Prepare PATH_SEPARATOR.
11207 # The user is always right.
11208 if test "${PATH_SEPARATOR+set}" != set; then
11209 echo "#! /bin/sh" >conf$$.sh
11210 echo "exit 0" >>conf$$.sh
11211 chmod +x conf$$.sh
11212 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
11213 PATH_SEPARATOR=';'
11214 else
11215 PATH_SEPARATOR=:
11217 rm -f conf$$.sh
11220 # Find out how to test for executable files. Don't use a zero-byte file,
11221 # as systems may use methods other than mode bits to determine executability.
11222 cat >conf$$.file <<_ASEOF
11223 #! /bin/sh
11224 exit 0
11225 _ASEOF
11226 chmod +x conf$$.file
11227 if test -x conf$$.file >/dev/null 2>&1; then
11228 ac_executable_p="test -x"
11229 else
11230 ac_executable_p="test -f"
11232 rm -f conf$$.file
11234 # Extract the first word of "msgfmt", so it can be a program name with args.
11235 set dummy msgfmt; ac_word=$2
11236 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11237 $as_echo_n "checking for $ac_word... " >&6; }
11238 if ${ac_cv_path_MSGFMT+:} false; then :
11239 $as_echo_n "(cached) " >&6
11240 else
11241 case "$MSGFMT" in
11242 [\\/]* | ?:[\\/]*)
11243 ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
11246 ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
11247 for ac_dir in $PATH; do
11248 IFS="$ac_save_IFS"
11249 test -z "$ac_dir" && ac_dir=.
11250 for ac_exec_ext in '' $ac_executable_extensions; do
11251 if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
11252 if $ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1 &&
11253 (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
11254 ac_cv_path_MSGFMT="$ac_dir/$ac_word$ac_exec_ext"
11255 break 2
11258 done
11259 done
11260 IFS="$ac_save_IFS"
11261 test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":"
11263 esac
11265 MSGFMT="$ac_cv_path_MSGFMT"
11266 if test "$MSGFMT" != ":"; then
11267 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5
11268 $as_echo "$MSGFMT" >&6; }
11269 else
11270 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11271 $as_echo "no" >&6; }
11274 # Extract the first word of "gmsgfmt", so it can be a program name with args.
11275 set dummy gmsgfmt; ac_word=$2
11276 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11277 $as_echo_n "checking for $ac_word... " >&6; }
11278 if ${ac_cv_path_GMSGFMT+:} false; then :
11279 $as_echo_n "(cached) " >&6
11280 else
11281 case $GMSGFMT in
11282 [\\/]* | ?:[\\/]*)
11283 ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
11286 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11287 for as_dir in $PATH
11289 IFS=$as_save_IFS
11290 test -z "$as_dir" && as_dir=.
11291 for ac_exec_ext in '' $ac_executable_extensions; do
11292 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11293 ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext"
11294 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11295 break 2
11297 done
11298 done
11299 IFS=$as_save_IFS
11301 test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
11303 esac
11305 GMSGFMT=$ac_cv_path_GMSGFMT
11306 if test -n "$GMSGFMT"; then
11307 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GMSGFMT" >&5
11308 $as_echo "$GMSGFMT" >&6; }
11309 else
11310 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11311 $as_echo "no" >&6; }
11317 # Prepare PATH_SEPARATOR.
11318 # The user is always right.
11319 if test "${PATH_SEPARATOR+set}" != set; then
11320 echo "#! /bin/sh" >conf$$.sh
11321 echo "exit 0" >>conf$$.sh
11322 chmod +x conf$$.sh
11323 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
11324 PATH_SEPARATOR=';'
11325 else
11326 PATH_SEPARATOR=:
11328 rm -f conf$$.sh
11331 # Find out how to test for executable files. Don't use a zero-byte file,
11332 # as systems may use methods other than mode bits to determine executability.
11333 cat >conf$$.file <<_ASEOF
11334 #! /bin/sh
11335 exit 0
11336 _ASEOF
11337 chmod +x conf$$.file
11338 if test -x conf$$.file >/dev/null 2>&1; then
11339 ac_executable_p="test -x"
11340 else
11341 ac_executable_p="test -f"
11343 rm -f conf$$.file
11345 # Extract the first word of "xgettext", so it can be a program name with args.
11346 set dummy xgettext; ac_word=$2
11347 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11348 $as_echo_n "checking for $ac_word... " >&6; }
11349 if ${ac_cv_path_XGETTEXT+:} false; then :
11350 $as_echo_n "(cached) " >&6
11351 else
11352 case "$XGETTEXT" in
11353 [\\/]* | ?:[\\/]*)
11354 ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
11357 ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
11358 for ac_dir in $PATH; do
11359 IFS="$ac_save_IFS"
11360 test -z "$ac_dir" && ac_dir=.
11361 for ac_exec_ext in '' $ac_executable_extensions; do
11362 if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
11363 if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
11364 (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
11365 ac_cv_path_XGETTEXT="$ac_dir/$ac_word$ac_exec_ext"
11366 break 2
11369 done
11370 done
11371 IFS="$ac_save_IFS"
11372 test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
11374 esac
11376 XGETTEXT="$ac_cv_path_XGETTEXT"
11377 if test "$XGETTEXT" != ":"; then
11378 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5
11379 $as_echo "$XGETTEXT" >&6; }
11380 else
11381 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11382 $as_echo "no" >&6; }
11385 rm -f messages.po
11388 # Prepare PATH_SEPARATOR.
11389 # The user is always right.
11390 if test "${PATH_SEPARATOR+set}" != set; then
11391 echo "#! /bin/sh" >conf$$.sh
11392 echo "exit 0" >>conf$$.sh
11393 chmod +x conf$$.sh
11394 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
11395 PATH_SEPARATOR=';'
11396 else
11397 PATH_SEPARATOR=:
11399 rm -f conf$$.sh
11402 # Find out how to test for executable files. Don't use a zero-byte file,
11403 # as systems may use methods other than mode bits to determine executability.
11404 cat >conf$$.file <<_ASEOF
11405 #! /bin/sh
11406 exit 0
11407 _ASEOF
11408 chmod +x conf$$.file
11409 if test -x conf$$.file >/dev/null 2>&1; then
11410 ac_executable_p="test -x"
11411 else
11412 ac_executable_p="test -f"
11414 rm -f conf$$.file
11416 # Extract the first word of "msgmerge", so it can be a program name with args.
11417 set dummy msgmerge; ac_word=$2
11418 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11419 $as_echo_n "checking for $ac_word... " >&6; }
11420 if ${ac_cv_path_MSGMERGE+:} false; then :
11421 $as_echo_n "(cached) " >&6
11422 else
11423 case "$MSGMERGE" in
11424 [\\/]* | ?:[\\/]*)
11425 ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path.
11428 ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
11429 for ac_dir in $PATH; do
11430 IFS="$ac_save_IFS"
11431 test -z "$ac_dir" && ac_dir=.
11432 for ac_exec_ext in '' $ac_executable_extensions; do
11433 if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
11434 if $ac_dir/$ac_word --update -q /dev/null /dev/null >/dev/null 2>&1; then
11435 ac_cv_path_MSGMERGE="$ac_dir/$ac_word$ac_exec_ext"
11436 break 2
11439 done
11440 done
11441 IFS="$ac_save_IFS"
11442 test -z "$ac_cv_path_MSGMERGE" && ac_cv_path_MSGMERGE=":"
11444 esac
11446 MSGMERGE="$ac_cv_path_MSGMERGE"
11447 if test "$MSGMERGE" != ":"; then
11448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5
11449 $as_echo "$MSGMERGE" >&6; }
11450 else
11451 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11452 $as_echo "no" >&6; }
11456 if test "$GMSGFMT" != ":"; then
11457 if $GMSGFMT --statistics /dev/null >/dev/null 2>&1 &&
11458 (if $GMSGFMT --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
11460 else
11461 GMSGFMT=`echo "$GMSGFMT" | sed -e 's,^.*/,,'`
11462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found $GMSGFMT program is not GNU msgfmt; ignore it" >&5
11463 $as_echo "found $GMSGFMT program is not GNU msgfmt; ignore it" >&6; }
11464 GMSGFMT=":"
11468 if test "$XGETTEXT" != ":"; then
11469 if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
11470 (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
11472 else
11473 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found xgettext program is not GNU xgettext; ignore it" >&5
11474 $as_echo "found xgettext program is not GNU xgettext; ignore it" >&6; }
11475 XGETTEXT=":"
11477 rm -f messages.po
11480 ac_config_commands="$ac_config_commands default-1"
11489 use_additional=yes
11491 acl_save_prefix="$prefix"
11492 prefix="$acl_final_prefix"
11493 acl_save_exec_prefix="$exec_prefix"
11494 exec_prefix="$acl_final_exec_prefix"
11496 eval additional_includedir=\"$includedir\"
11497 eval additional_libdir=\"$libdir\"
11499 exec_prefix="$acl_save_exec_prefix"
11500 prefix="$acl_save_prefix"
11503 # Check whether --with-libiconv-prefix was given.
11504 if test "${with_libiconv_prefix+set}" = set; then :
11505 withval=$with_libiconv_prefix;
11506 if test "X$withval" = "Xno"; then
11507 use_additional=no
11508 else
11509 if test "X$withval" = "X"; then
11511 acl_save_prefix="$prefix"
11512 prefix="$acl_final_prefix"
11513 acl_save_exec_prefix="$exec_prefix"
11514 exec_prefix="$acl_final_exec_prefix"
11516 eval additional_includedir=\"$includedir\"
11517 eval additional_libdir=\"$libdir\"
11519 exec_prefix="$acl_save_exec_prefix"
11520 prefix="$acl_save_prefix"
11522 else
11523 additional_includedir="$withval/include"
11524 additional_libdir="$withval/lib"
11531 # Check whether --with-libiconv-type was given.
11532 if test "${with_libiconv_type+set}" = set; then :
11533 withval=$with_libiconv_type; with_libiconv_type=$withval
11534 else
11535 with_libiconv_type=auto
11538 lib_type=`eval echo \$with_libiconv_type`
11540 LIBICONV=
11541 LTLIBICONV=
11542 INCICONV=
11543 rpathdirs=
11544 ltrpathdirs=
11545 names_already_handled=
11546 names_next_round='iconv '
11547 while test -n "$names_next_round"; do
11548 names_this_round="$names_next_round"
11549 names_next_round=
11550 for name in $names_this_round; do
11551 already_handled=
11552 for n in $names_already_handled; do
11553 if test "$n" = "$name"; then
11554 already_handled=yes
11555 break
11557 done
11558 if test -z "$already_handled"; then
11559 names_already_handled="$names_already_handled $name"
11560 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
11561 eval value=\"\$HAVE_LIB$uppername\"
11562 if test -n "$value"; then
11563 if test "$value" = yes; then
11564 eval value=\"\$LIB$uppername\"
11565 test -z "$value" || LIBICONV="${LIBICONV}${LIBICONV:+ }$value"
11566 eval value=\"\$LTLIB$uppername\"
11567 test -z "$value" || LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$value"
11568 else
11571 else
11572 found_dir=
11573 found_la=
11574 found_so=
11575 found_a=
11576 if test $use_additional = yes; then
11577 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
11578 found_dir="$additional_libdir"
11579 found_so="$additional_libdir/lib$name.$shlibext"
11580 if test -f "$additional_libdir/lib$name.la"; then
11581 found_la="$additional_libdir/lib$name.la"
11583 elif test x$lib_type != xshared; then
11584 if test -f "$additional_libdir/lib$name.$libext"; then
11585 found_dir="$additional_libdir"
11586 found_a="$additional_libdir/lib$name.$libext"
11587 if test -f "$additional_libdir/lib$name.la"; then
11588 found_la="$additional_libdir/lib$name.la"
11593 if test "X$found_dir" = "X"; then
11594 for x in $LDFLAGS $LTLIBICONV; do
11596 acl_save_prefix="$prefix"
11597 prefix="$acl_final_prefix"
11598 acl_save_exec_prefix="$exec_prefix"
11599 exec_prefix="$acl_final_exec_prefix"
11600 eval x=\"$x\"
11601 exec_prefix="$acl_save_exec_prefix"
11602 prefix="$acl_save_prefix"
11604 case "$x" in
11605 -L*)
11606 dir=`echo "X$x" | sed -e 's/^X-L//'`
11607 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
11608 found_dir="$dir"
11609 found_so="$dir/lib$name.$shlibext"
11610 if test -f "$dir/lib$name.la"; then
11611 found_la="$dir/lib$name.la"
11613 elif test x$lib_type != xshared; then
11614 if test -f "$dir/lib$name.$libext"; then
11615 found_dir="$dir"
11616 found_a="$dir/lib$name.$libext"
11617 if test -f "$dir/lib$name.la"; then
11618 found_la="$dir/lib$name.la"
11623 esac
11624 if test "X$found_dir" != "X"; then
11625 break
11627 done
11629 if test "X$found_dir" != "X"; then
11630 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$found_dir -l$name"
11631 if test "X$found_so" != "X"; then
11632 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
11633 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
11634 else
11635 haveit=
11636 for x in $ltrpathdirs; do
11637 if test "X$x" = "X$found_dir"; then
11638 haveit=yes
11639 break
11641 done
11642 if test -z "$haveit"; then
11643 ltrpathdirs="$ltrpathdirs $found_dir"
11645 if test "$hardcode_direct" = yes; then
11646 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
11647 else
11648 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
11649 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
11650 haveit=
11651 for x in $rpathdirs; do
11652 if test "X$x" = "X$found_dir"; then
11653 haveit=yes
11654 break
11656 done
11657 if test -z "$haveit"; then
11658 rpathdirs="$rpathdirs $found_dir"
11660 else
11661 haveit=
11662 for x in $LDFLAGS $LIBICONV; do
11664 acl_save_prefix="$prefix"
11665 prefix="$acl_final_prefix"
11666 acl_save_exec_prefix="$exec_prefix"
11667 exec_prefix="$acl_final_exec_prefix"
11668 eval x=\"$x\"
11669 exec_prefix="$acl_save_exec_prefix"
11670 prefix="$acl_save_prefix"
11672 if test "X$x" = "X-L$found_dir"; then
11673 haveit=yes
11674 break
11676 done
11677 if test -z "$haveit"; then
11678 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir"
11680 if test "$hardcode_minus_L" != no; then
11681 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
11682 else
11683 LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
11688 else
11689 if test "X$found_a" != "X"; then
11690 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_a"
11691 else
11692 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir -l$name"
11695 additional_includedir=
11696 case "$found_dir" in
11697 */lib | */lib/)
11698 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
11699 additional_includedir="$basedir/include"
11701 esac
11702 if test "X$additional_includedir" != "X"; then
11703 if test "X$additional_includedir" != "X/usr/include"; then
11704 haveit=
11705 if test "X$additional_includedir" = "X/usr/local/include"; then
11706 if test -n "$GCC"; then
11707 case $host_os in
11708 linux*) haveit=yes;;
11709 esac
11712 if test -z "$haveit"; then
11713 for x in $CPPFLAGS $INCICONV; do
11715 acl_save_prefix="$prefix"
11716 prefix="$acl_final_prefix"
11717 acl_save_exec_prefix="$exec_prefix"
11718 exec_prefix="$acl_final_exec_prefix"
11719 eval x=\"$x\"
11720 exec_prefix="$acl_save_exec_prefix"
11721 prefix="$acl_save_prefix"
11723 if test "X$x" = "X-I$additional_includedir"; then
11724 haveit=yes
11725 break
11727 done
11728 if test -z "$haveit"; then
11729 if test -d "$additional_includedir"; then
11730 INCICONV="${INCICONV}${INCICONV:+ }-I$additional_includedir"
11736 if test -n "$found_la"; then
11737 save_libdir="$libdir"
11738 case "$found_la" in
11739 */* | *\\*) . "$found_la" ;;
11740 *) . "./$found_la" ;;
11741 esac
11742 libdir="$save_libdir"
11743 for dep in $dependency_libs; do
11744 case "$dep" in
11745 -L*)
11746 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
11747 if test "X$additional_libdir" != "X/usr/lib"; then
11748 haveit=
11749 if test "X$additional_libdir" = "X/usr/local/lib"; then
11750 if test -n "$GCC"; then
11751 case $host_os in
11752 linux*) haveit=yes;;
11753 esac
11756 if test -z "$haveit"; then
11757 haveit=
11758 for x in $LDFLAGS $LIBICONV; do
11760 acl_save_prefix="$prefix"
11761 prefix="$acl_final_prefix"
11762 acl_save_exec_prefix="$exec_prefix"
11763 exec_prefix="$acl_final_exec_prefix"
11764 eval x=\"$x\"
11765 exec_prefix="$acl_save_exec_prefix"
11766 prefix="$acl_save_prefix"
11768 if test "X$x" = "X-L$additional_libdir"; then
11769 haveit=yes
11770 break
11772 done
11773 if test -z "$haveit"; then
11774 if test -d "$additional_libdir"; then
11775 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$additional_libdir"
11778 haveit=
11779 for x in $LDFLAGS $LTLIBICONV; 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 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$additional_libdir"
11802 -R*)
11803 dir=`echo "X$dep" | sed -e 's/^X-R//'`
11804 if test "$enable_rpath" != no; then
11805 haveit=
11806 for x in $rpathdirs; do
11807 if test "X$x" = "X$dir"; then
11808 haveit=yes
11809 break
11811 done
11812 if test -z "$haveit"; then
11813 rpathdirs="$rpathdirs $dir"
11815 haveit=
11816 for x in $ltrpathdirs; do
11817 if test "X$x" = "X$dir"; then
11818 haveit=yes
11819 break
11821 done
11822 if test -z "$haveit"; then
11823 ltrpathdirs="$ltrpathdirs $dir"
11827 -l*)
11828 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
11830 *.la)
11831 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
11834 LIBICONV="${LIBICONV}${LIBICONV:+ }$dep"
11835 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$dep"
11837 esac
11838 done
11840 else
11841 if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
11842 LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
11843 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l$name"
11844 else
11845 LIBICONV="${LIBICONV}${LIBICONV:+ }-l:lib$name.$libext"
11846 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l:lib$name.$libext"
11851 done
11852 done
11853 if test "X$rpathdirs" != "X"; then
11854 if test -n "$hardcode_libdir_separator"; then
11855 alldirs=
11856 for found_dir in $rpathdirs; do
11857 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
11858 done
11859 acl_save_libdir="$libdir"
11860 libdir="$alldirs"
11861 eval flag=\"$hardcode_libdir_flag_spec\"
11862 libdir="$acl_save_libdir"
11863 LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
11864 else
11865 for found_dir in $rpathdirs; do
11866 acl_save_libdir="$libdir"
11867 libdir="$found_dir"
11868 eval flag=\"$hardcode_libdir_flag_spec\"
11869 libdir="$acl_save_libdir"
11870 LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
11871 done
11874 if test "X$ltrpathdirs" != "X"; then
11875 for found_dir in $ltrpathdirs; do
11876 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-R$found_dir"
11877 done
11884 if test -f ../gettext/uninstalled-config.sh; then
11885 relative_builddir='$(top_builddir)/../gettext'
11886 . ../gettext/uninstalled-config.sh
11887 else
11888 # The sister gettext directory doesn't exist and won't collect information on
11889 # using gettext for us. Call a bundled AM_GNU_GETTEXT.
11913 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFPreferencesCopyAppValue" >&5
11914 $as_echo_n "checking for CFPreferencesCopyAppValue... " >&6; }
11915 if ${gt_cv_func_CFPreferencesCopyAppValue+:} false; then :
11916 $as_echo_n "(cached) " >&6
11917 else
11918 gt_save_LIBS="$LIBS"
11919 LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
11920 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11921 /* end confdefs.h. */
11922 #include <CoreFoundation/CFPreferences.h>
11924 main ()
11926 CFPreferencesCopyAppValue(NULL, NULL)
11928 return 0;
11930 _ACEOF
11931 if ac_fn_c_try_link "$LINENO"; then :
11932 gt_cv_func_CFPreferencesCopyAppValue=yes
11933 else
11934 gt_cv_func_CFPreferencesCopyAppValue=no
11936 rm -f core conftest.err conftest.$ac_objext \
11937 conftest$ac_exeext conftest.$ac_ext
11938 LIBS="$gt_save_LIBS"
11940 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFPreferencesCopyAppValue" >&5
11941 $as_echo "$gt_cv_func_CFPreferencesCopyAppValue" >&6; }
11942 if test $gt_cv_func_CFPreferencesCopyAppValue = yes; then
11944 $as_echo "#define HAVE_CFPREFERENCESCOPYAPPVALUE 1" >>confdefs.h
11947 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFLocaleCopyPreferredLanguages" >&5
11948 $as_echo_n "checking for CFLocaleCopyPreferredLanguages... " >&6; }
11949 if ${gt_cv_func_CFLocaleCopyPreferredLanguages+:} false; then :
11950 $as_echo_n "(cached) " >&6
11951 else
11952 gt_save_LIBS="$LIBS"
11953 LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
11954 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11955 /* end confdefs.h. */
11956 #include <CoreFoundation/CFLocale.h>
11958 main ()
11960 CFLocaleCopyPreferredLanguages();
11962 return 0;
11964 _ACEOF
11965 if ac_fn_c_try_link "$LINENO"; then :
11966 gt_cv_func_CFLocaleCopyPreferredLanguages=yes
11967 else
11968 gt_cv_func_CFLocaleCopyPreferredLanguages=no
11970 rm -f core conftest.err conftest.$ac_objext \
11971 conftest$ac_exeext conftest.$ac_ext
11972 LIBS="$gt_save_LIBS"
11974 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFLocaleCopyPreferredLanguages" >&5
11975 $as_echo "$gt_cv_func_CFLocaleCopyPreferredLanguages" >&6; }
11976 if test $gt_cv_func_CFLocaleCopyPreferredLanguages = yes; then
11978 $as_echo "#define HAVE_CFLOCALECOPYPREFERREDLANGUAGES 1" >>confdefs.h
11981 INTL_MACOSX_LIBS=
11982 if test $gt_cv_func_CFPreferencesCopyAppValue = yes \
11983 || test $gt_cv_func_CFLocaleCopyPreferredLanguages = yes; then
11984 INTL_MACOSX_LIBS="-Wl,-framework -Wl,CoreFoundation -Wl,-framework -Wl,CoreServices"
11992 LIBINTL=
11993 LTLIBINTL=
11994 POSUB=
11996 case " $gt_needs " in
11997 *" need-formatstring-macros "*) gt_api_version=3 ;;
11998 *" need-ngettext "*) gt_api_version=2 ;;
11999 *) gt_api_version=1 ;;
12000 esac
12001 gt_func_gnugettext_libc="gt_cv_func_gnugettext${gt_api_version}_libc"
12002 gt_func_gnugettext_libintl="gt_cv_func_gnugettext${gt_api_version}_libintl"
12004 if test "$USE_NLS" = "yes"; then
12005 gt_use_preinstalled_gnugettext=no
12008 if test $gt_api_version -ge 3; then
12009 gt_revision_test_code='
12010 #ifndef __GNU_GETTEXT_SUPPORTED_REVISION
12011 #define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 0 : -1)
12012 #endif
12013 typedef int array [2 * (__GNU_GETTEXT_SUPPORTED_REVISION(0) >= 1) - 1];
12015 else
12016 gt_revision_test_code=
12018 if test $gt_api_version -ge 2; then
12019 gt_expression_test_code=' + * ngettext ("", "", 0)'
12020 else
12021 gt_expression_test_code=
12024 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libc" >&5
12025 $as_echo_n "checking for GNU gettext in libc... " >&6; }
12026 if eval \${$gt_func_gnugettext_libc+:} false; then :
12027 $as_echo_n "(cached) " >&6
12028 else
12029 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12030 /* end confdefs.h. */
12032 #include <libintl.h>
12033 #ifndef __GNU_GETTEXT_SUPPORTED_REVISION
12034 extern int _nl_msg_cat_cntr;
12035 extern int *_nl_domain_bindings;
12036 #define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_domain_bindings)
12037 #else
12038 #define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
12039 #endif
12040 $gt_revision_test_code
12043 main ()
12046 bindtextdomain ("", "");
12047 return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
12050 return 0;
12052 _ACEOF
12053 if ac_fn_c_try_link "$LINENO"; then :
12054 eval "$gt_func_gnugettext_libc=yes"
12055 else
12056 eval "$gt_func_gnugettext_libc=no"
12058 rm -f core conftest.err conftest.$ac_objext \
12059 conftest$ac_exeext conftest.$ac_ext
12061 eval ac_res=\$$gt_func_gnugettext_libc
12062 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
12063 $as_echo "$ac_res" >&6; }
12065 if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" != "yes"; }; then
12071 am_save_CPPFLAGS="$CPPFLAGS"
12073 for element in $INCICONV; do
12074 haveit=
12075 for x in $CPPFLAGS; do
12077 acl_save_prefix="$prefix"
12078 prefix="$acl_final_prefix"
12079 acl_save_exec_prefix="$exec_prefix"
12080 exec_prefix="$acl_final_exec_prefix"
12081 eval x=\"$x\"
12082 exec_prefix="$acl_save_exec_prefix"
12083 prefix="$acl_save_prefix"
12085 if test "X$x" = "X$element"; then
12086 haveit=yes
12087 break
12089 done
12090 if test -z "$haveit"; then
12091 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
12093 done
12096 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5
12097 $as_echo_n "checking for iconv... " >&6; }
12098 if ${am_cv_func_iconv+:} false; then :
12099 $as_echo_n "(cached) " >&6
12100 else
12102 am_cv_func_iconv="no, consider installing GNU libiconv"
12103 am_cv_lib_iconv=no
12104 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12105 /* end confdefs.h. */
12107 #include <stdlib.h>
12108 #include <iconv.h>
12111 main ()
12113 iconv_t cd = iconv_open("","");
12114 iconv(cd,NULL,NULL,NULL,NULL);
12115 iconv_close(cd);
12117 return 0;
12119 _ACEOF
12120 if ac_fn_c_try_link "$LINENO"; then :
12121 am_cv_func_iconv=yes
12123 rm -f core conftest.err conftest.$ac_objext \
12124 conftest$ac_exeext conftest.$ac_ext
12125 if test "$am_cv_func_iconv" != yes; then
12126 am_save_LIBS="$LIBS"
12127 LIBS="$LIBS $LIBICONV"
12128 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12129 /* end confdefs.h. */
12131 #include <stdlib.h>
12132 #include <iconv.h>
12135 main ()
12137 iconv_t cd = iconv_open("","");
12138 iconv(cd,NULL,NULL,NULL,NULL);
12139 iconv_close(cd);
12141 return 0;
12143 _ACEOF
12144 if ac_fn_c_try_link "$LINENO"; then :
12145 am_cv_lib_iconv=yes
12146 am_cv_func_iconv=yes
12148 rm -f core conftest.err conftest.$ac_objext \
12149 conftest$ac_exeext conftest.$ac_ext
12150 LIBS="$am_save_LIBS"
12154 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5
12155 $as_echo "$am_cv_func_iconv" >&6; }
12156 if test "$am_cv_func_iconv" = yes; then
12157 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working iconv" >&5
12158 $as_echo_n "checking for working iconv... " >&6; }
12159 if ${am_cv_func_iconv_works+:} false; then :
12160 $as_echo_n "(cached) " >&6
12161 else
12163 am_save_LIBS="$LIBS"
12164 if test $am_cv_lib_iconv = yes; then
12165 LIBS="$LIBS $LIBICONV"
12167 am_cv_func_iconv_works=no
12168 for ac_iconv_const in '' 'const'; do
12169 if test "$cross_compiling" = yes; then :
12170 case "$host_os" in
12171 aix* | hpux*) am_cv_func_iconv_works="guessing no" ;;
12172 *) am_cv_func_iconv_works="guessing yes" ;;
12173 esac
12174 else
12175 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12176 /* end confdefs.h. */
12178 #include <iconv.h>
12179 #include <string.h>
12181 #ifndef ICONV_CONST
12182 # define ICONV_CONST $ac_iconv_const
12183 #endif
12186 main ()
12188 int result = 0;
12189 /* Test against AIX 5.1...7.2 bug: Failures are not distinguishable from
12190 successful returns. This is even documented in
12191 <https://www.ibm.com/support/knowledgecenter/ssw_aix_72/i_bostechref/iconv.html> */
12193 iconv_t cd_utf8_to_88591 = iconv_open ("ISO8859-1", "UTF-8");
12194 if (cd_utf8_to_88591 != (iconv_t)(-1))
12196 static ICONV_CONST char input[] = "\342\202\254"; /* EURO SIGN */
12197 char buf[10];
12198 ICONV_CONST char *inptr = input;
12199 size_t inbytesleft = strlen (input);
12200 char *outptr = buf;
12201 size_t outbytesleft = sizeof (buf);
12202 size_t res = iconv (cd_utf8_to_88591,
12203 &inptr, &inbytesleft,
12204 &outptr, &outbytesleft);
12205 if (res == 0)
12206 result |= 1;
12207 iconv_close (cd_utf8_to_88591);
12210 /* Test against Solaris 10 bug: Failures are not distinguishable from
12211 successful returns. */
12213 iconv_t cd_ascii_to_88591 = iconv_open ("ISO8859-1", "646");
12214 if (cd_ascii_to_88591 != (iconv_t)(-1))
12216 static ICONV_CONST char input[] = "\263";
12217 char buf[10];
12218 ICONV_CONST char *inptr = input;
12219 size_t inbytesleft = strlen (input);
12220 char *outptr = buf;
12221 size_t outbytesleft = sizeof (buf);
12222 size_t res = iconv (cd_ascii_to_88591,
12223 &inptr, &inbytesleft,
12224 &outptr, &outbytesleft);
12225 if (res == 0)
12226 result |= 2;
12227 iconv_close (cd_ascii_to_88591);
12230 /* Test against AIX 6.1..7.1 bug: Buffer overrun. */
12232 iconv_t cd_88591_to_utf8 = iconv_open ("UTF-8", "ISO-8859-1");
12233 if (cd_88591_to_utf8 != (iconv_t)(-1))
12235 static ICONV_CONST char input[] = "\304";
12236 static char buf[2] = { (char)0xDE, (char)0xAD };
12237 ICONV_CONST char *inptr = input;
12238 size_t inbytesleft = 1;
12239 char *outptr = buf;
12240 size_t outbytesleft = 1;
12241 size_t res = iconv (cd_88591_to_utf8,
12242 &inptr, &inbytesleft,
12243 &outptr, &outbytesleft);
12244 if (res != (size_t)(-1) || outptr - buf > 1 || buf[1] != (char)0xAD)
12245 result |= 4;
12246 iconv_close (cd_88591_to_utf8);
12249 #if 0 /* This bug could be worked around by the caller. */
12250 /* Test against HP-UX 11.11 bug: Positive return value instead of 0. */
12252 iconv_t cd_88591_to_utf8 = iconv_open ("utf8", "iso88591");
12253 if (cd_88591_to_utf8 != (iconv_t)(-1))
12255 static ICONV_CONST char input[] = "\304rger mit b\366sen B\374bchen ohne Augenma\337";
12256 char buf[50];
12257 ICONV_CONST char *inptr = input;
12258 size_t inbytesleft = strlen (input);
12259 char *outptr = buf;
12260 size_t outbytesleft = sizeof (buf);
12261 size_t res = iconv (cd_88591_to_utf8,
12262 &inptr, &inbytesleft,
12263 &outptr, &outbytesleft);
12264 if ((int)res > 0)
12265 result |= 8;
12266 iconv_close (cd_88591_to_utf8);
12269 #endif
12270 /* Test against HP-UX 11.11 bug: No converter from EUC-JP to UTF-8 is
12271 provided. */
12273 /* Try standardized names. */
12274 iconv_t cd1 = iconv_open ("UTF-8", "EUC-JP");
12275 /* Try IRIX, OSF/1 names. */
12276 iconv_t cd2 = iconv_open ("UTF-8", "eucJP");
12277 /* Try AIX names. */
12278 iconv_t cd3 = iconv_open ("UTF-8", "IBM-eucJP");
12279 /* Try HP-UX names. */
12280 iconv_t cd4 = iconv_open ("utf8", "eucJP");
12281 if (cd1 == (iconv_t)(-1) && cd2 == (iconv_t)(-1)
12282 && cd3 == (iconv_t)(-1) && cd4 == (iconv_t)(-1))
12283 result |= 16;
12284 if (cd1 != (iconv_t)(-1))
12285 iconv_close (cd1);
12286 if (cd2 != (iconv_t)(-1))
12287 iconv_close (cd2);
12288 if (cd3 != (iconv_t)(-1))
12289 iconv_close (cd3);
12290 if (cd4 != (iconv_t)(-1))
12291 iconv_close (cd4);
12293 return result;
12296 return 0;
12298 _ACEOF
12299 if ac_fn_c_try_run "$LINENO"; then :
12300 am_cv_func_iconv_works=yes
12302 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12303 conftest.$ac_objext conftest.beam conftest.$ac_ext
12306 test "$am_cv_func_iconv_works" = no || break
12307 done
12308 LIBS="$am_save_LIBS"
12311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv_works" >&5
12312 $as_echo "$am_cv_func_iconv_works" >&6; }
12313 case "$am_cv_func_iconv_works" in
12314 *no) am_func_iconv=no am_cv_lib_iconv=no ;;
12315 *) am_func_iconv=yes ;;
12316 esac
12317 else
12318 am_func_iconv=no am_cv_lib_iconv=no
12320 if test "$am_func_iconv" = yes; then
12322 $as_echo "#define HAVE_ICONV 1" >>confdefs.h
12325 if test "$am_cv_lib_iconv" = yes; then
12326 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libiconv" >&5
12327 $as_echo_n "checking how to link with libiconv... " >&6; }
12328 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBICONV" >&5
12329 $as_echo "$LIBICONV" >&6; }
12330 else
12331 CPPFLAGS="$am_save_CPPFLAGS"
12332 LIBICONV=
12333 LTLIBICONV=
12341 use_additional=yes
12343 acl_save_prefix="$prefix"
12344 prefix="$acl_final_prefix"
12345 acl_save_exec_prefix="$exec_prefix"
12346 exec_prefix="$acl_final_exec_prefix"
12348 eval additional_includedir=\"$includedir\"
12349 eval additional_libdir=\"$libdir\"
12351 exec_prefix="$acl_save_exec_prefix"
12352 prefix="$acl_save_prefix"
12355 # Check whether --with-libintl-prefix was given.
12356 if test "${with_libintl_prefix+set}" = set; then :
12357 withval=$with_libintl_prefix;
12358 if test "X$withval" = "Xno"; then
12359 use_additional=no
12360 else
12361 if test "X$withval" = "X"; then
12363 acl_save_prefix="$prefix"
12364 prefix="$acl_final_prefix"
12365 acl_save_exec_prefix="$exec_prefix"
12366 exec_prefix="$acl_final_exec_prefix"
12368 eval additional_includedir=\"$includedir\"
12369 eval additional_libdir=\"$libdir\"
12371 exec_prefix="$acl_save_exec_prefix"
12372 prefix="$acl_save_prefix"
12374 else
12375 additional_includedir="$withval/include"
12376 additional_libdir="$withval/lib"
12383 # Check whether --with-libintl-type was given.
12384 if test "${with_libintl_type+set}" = set; then :
12385 withval=$with_libintl_type; with_libintl_type=$withval
12386 else
12387 with_libintl_type=auto
12390 lib_type=`eval echo \$with_libintl_type`
12392 LIBINTL=
12393 LTLIBINTL=
12394 INCINTL=
12395 rpathdirs=
12396 ltrpathdirs=
12397 names_already_handled=
12398 names_next_round='intl '
12399 while test -n "$names_next_round"; do
12400 names_this_round="$names_next_round"
12401 names_next_round=
12402 for name in $names_this_round; do
12403 already_handled=
12404 for n in $names_already_handled; do
12405 if test "$n" = "$name"; then
12406 already_handled=yes
12407 break
12409 done
12410 if test -z "$already_handled"; then
12411 names_already_handled="$names_already_handled $name"
12412 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
12413 eval value=\"\$HAVE_LIB$uppername\"
12414 if test -n "$value"; then
12415 if test "$value" = yes; then
12416 eval value=\"\$LIB$uppername\"
12417 test -z "$value" || LIBINTL="${LIBINTL}${LIBINTL:+ }$value"
12418 eval value=\"\$LTLIB$uppername\"
12419 test -z "$value" || LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$value"
12420 else
12423 else
12424 found_dir=
12425 found_la=
12426 found_so=
12427 found_a=
12428 if test $use_additional = yes; then
12429 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
12430 found_dir="$additional_libdir"
12431 found_so="$additional_libdir/lib$name.$shlibext"
12432 if test -f "$additional_libdir/lib$name.la"; then
12433 found_la="$additional_libdir/lib$name.la"
12435 elif test x$lib_type != xshared; then
12436 if test -f "$additional_libdir/lib$name.$libext"; then
12437 found_dir="$additional_libdir"
12438 found_a="$additional_libdir/lib$name.$libext"
12439 if test -f "$additional_libdir/lib$name.la"; then
12440 found_la="$additional_libdir/lib$name.la"
12445 if test "X$found_dir" = "X"; then
12446 for x in $LDFLAGS $LTLIBINTL; do
12448 acl_save_prefix="$prefix"
12449 prefix="$acl_final_prefix"
12450 acl_save_exec_prefix="$exec_prefix"
12451 exec_prefix="$acl_final_exec_prefix"
12452 eval x=\"$x\"
12453 exec_prefix="$acl_save_exec_prefix"
12454 prefix="$acl_save_prefix"
12456 case "$x" in
12457 -L*)
12458 dir=`echo "X$x" | sed -e 's/^X-L//'`
12459 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
12460 found_dir="$dir"
12461 found_so="$dir/lib$name.$shlibext"
12462 if test -f "$dir/lib$name.la"; then
12463 found_la="$dir/lib$name.la"
12465 elif test x$lib_type != xshared; then
12466 if test -f "$dir/lib$name.$libext"; then
12467 found_dir="$dir"
12468 found_a="$dir/lib$name.$libext"
12469 if test -f "$dir/lib$name.la"; then
12470 found_la="$dir/lib$name.la"
12475 esac
12476 if test "X$found_dir" != "X"; then
12477 break
12479 done
12481 if test "X$found_dir" != "X"; then
12482 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$found_dir -l$name"
12483 if test "X$found_so" != "X"; then
12484 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
12485 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
12486 else
12487 haveit=
12488 for x in $ltrpathdirs; do
12489 if test "X$x" = "X$found_dir"; then
12490 haveit=yes
12491 break
12493 done
12494 if test -z "$haveit"; then
12495 ltrpathdirs="$ltrpathdirs $found_dir"
12497 if test "$hardcode_direct" = yes; then
12498 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
12499 else
12500 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
12501 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
12502 haveit=
12503 for x in $rpathdirs; do
12504 if test "X$x" = "X$found_dir"; then
12505 haveit=yes
12506 break
12508 done
12509 if test -z "$haveit"; then
12510 rpathdirs="$rpathdirs $found_dir"
12512 else
12513 haveit=
12514 for x in $LDFLAGS $LIBINTL; do
12516 acl_save_prefix="$prefix"
12517 prefix="$acl_final_prefix"
12518 acl_save_exec_prefix="$exec_prefix"
12519 exec_prefix="$acl_final_exec_prefix"
12520 eval x=\"$x\"
12521 exec_prefix="$acl_save_exec_prefix"
12522 prefix="$acl_save_prefix"
12524 if test "X$x" = "X-L$found_dir"; then
12525 haveit=yes
12526 break
12528 done
12529 if test -z "$haveit"; then
12530 LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir"
12532 if test "$hardcode_minus_L" != no; then
12533 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
12534 else
12535 LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name"
12540 else
12541 if test "X$found_a" != "X"; then
12542 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_a"
12543 else
12544 LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir -l$name"
12547 additional_includedir=
12548 case "$found_dir" in
12549 */lib | */lib/)
12550 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
12551 additional_includedir="$basedir/include"
12553 esac
12554 if test "X$additional_includedir" != "X"; then
12555 if test "X$additional_includedir" != "X/usr/include"; then
12556 haveit=
12557 if test "X$additional_includedir" = "X/usr/local/include"; then
12558 if test -n "$GCC"; then
12559 case $host_os in
12560 linux*) haveit=yes;;
12561 esac
12564 if test -z "$haveit"; then
12565 for x in $CPPFLAGS $INCINTL; do
12567 acl_save_prefix="$prefix"
12568 prefix="$acl_final_prefix"
12569 acl_save_exec_prefix="$exec_prefix"
12570 exec_prefix="$acl_final_exec_prefix"
12571 eval x=\"$x\"
12572 exec_prefix="$acl_save_exec_prefix"
12573 prefix="$acl_save_prefix"
12575 if test "X$x" = "X-I$additional_includedir"; then
12576 haveit=yes
12577 break
12579 done
12580 if test -z "$haveit"; then
12581 if test -d "$additional_includedir"; then
12582 INCINTL="${INCINTL}${INCINTL:+ }-I$additional_includedir"
12588 if test -n "$found_la"; then
12589 save_libdir="$libdir"
12590 case "$found_la" in
12591 */* | *\\*) . "$found_la" ;;
12592 *) . "./$found_la" ;;
12593 esac
12594 libdir="$save_libdir"
12595 for dep in $dependency_libs; do
12596 case "$dep" in
12597 -L*)
12598 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
12599 if test "X$additional_libdir" != "X/usr/lib"; then
12600 haveit=
12601 if test "X$additional_libdir" = "X/usr/local/lib"; then
12602 if test -n "$GCC"; then
12603 case $host_os in
12604 linux*) haveit=yes;;
12605 esac
12608 if test -z "$haveit"; then
12609 haveit=
12610 for x in $LDFLAGS $LIBINTL; do
12612 acl_save_prefix="$prefix"
12613 prefix="$acl_final_prefix"
12614 acl_save_exec_prefix="$exec_prefix"
12615 exec_prefix="$acl_final_exec_prefix"
12616 eval x=\"$x\"
12617 exec_prefix="$acl_save_exec_prefix"
12618 prefix="$acl_save_prefix"
12620 if test "X$x" = "X-L$additional_libdir"; then
12621 haveit=yes
12622 break
12624 done
12625 if test -z "$haveit"; then
12626 if test -d "$additional_libdir"; then
12627 LIBINTL="${LIBINTL}${LIBINTL:+ }-L$additional_libdir"
12630 haveit=
12631 for x in $LDFLAGS $LTLIBINTL; 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 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$additional_libdir"
12654 -R*)
12655 dir=`echo "X$dep" | sed -e 's/^X-R//'`
12656 if test "$enable_rpath" != no; then
12657 haveit=
12658 for x in $rpathdirs; do
12659 if test "X$x" = "X$dir"; then
12660 haveit=yes
12661 break
12663 done
12664 if test -z "$haveit"; then
12665 rpathdirs="$rpathdirs $dir"
12667 haveit=
12668 for x in $ltrpathdirs; do
12669 if test "X$x" = "X$dir"; then
12670 haveit=yes
12671 break
12673 done
12674 if test -z "$haveit"; then
12675 ltrpathdirs="$ltrpathdirs $dir"
12679 -l*)
12680 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
12682 *.la)
12683 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
12686 LIBINTL="${LIBINTL}${LIBINTL:+ }$dep"
12687 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$dep"
12689 esac
12690 done
12692 else
12693 if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
12694 LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name"
12695 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-l$name"
12696 else
12697 LIBINTL="${LIBINTL}${LIBINTL:+ }-l:lib$name.$libext"
12698 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-l:lib$name.$libext"
12703 done
12704 done
12705 if test "X$rpathdirs" != "X"; then
12706 if test -n "$hardcode_libdir_separator"; then
12707 alldirs=
12708 for found_dir in $rpathdirs; do
12709 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
12710 done
12711 acl_save_libdir="$libdir"
12712 libdir="$alldirs"
12713 eval flag=\"$hardcode_libdir_flag_spec\"
12714 libdir="$acl_save_libdir"
12715 LIBINTL="${LIBINTL}${LIBINTL:+ }$flag"
12716 else
12717 for found_dir in $rpathdirs; do
12718 acl_save_libdir="$libdir"
12719 libdir="$found_dir"
12720 eval flag=\"$hardcode_libdir_flag_spec\"
12721 libdir="$acl_save_libdir"
12722 LIBINTL="${LIBINTL}${LIBINTL:+ }$flag"
12723 done
12726 if test "X$ltrpathdirs" != "X"; then
12727 for found_dir in $ltrpathdirs; do
12728 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-R$found_dir"
12729 done
12732 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libintl" >&5
12733 $as_echo_n "checking for GNU gettext in libintl... " >&6; }
12734 if eval \${$gt_func_gnugettext_libintl+:} false; then :
12735 $as_echo_n "(cached) " >&6
12736 else
12737 gt_save_CPPFLAGS="$CPPFLAGS"
12738 CPPFLAGS="$CPPFLAGS $INCINTL"
12739 gt_save_LIBS="$LIBS"
12740 LIBS="$LIBS $LIBINTL"
12741 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12742 /* end confdefs.h. */
12744 #include <libintl.h>
12745 #ifndef __GNU_GETTEXT_SUPPORTED_REVISION
12746 extern int _nl_msg_cat_cntr;
12747 extern
12748 #ifdef __cplusplus
12750 #endif
12751 const char *_nl_expand_alias (const char *);
12752 #define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_expand_alias (""))
12753 #else
12754 #define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
12755 #endif
12756 $gt_revision_test_code
12759 main ()
12762 bindtextdomain ("", "");
12763 return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
12766 return 0;
12768 _ACEOF
12769 if ac_fn_c_try_link "$LINENO"; then :
12770 eval "$gt_func_gnugettext_libintl=yes"
12771 else
12772 eval "$gt_func_gnugettext_libintl=no"
12774 rm -f core conftest.err conftest.$ac_objext \
12775 conftest$ac_exeext conftest.$ac_ext
12776 if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" != yes; } && test -n "$LIBICONV"; then
12777 LIBS="$LIBS $LIBICONV"
12778 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12779 /* end confdefs.h. */
12781 #include <libintl.h>
12782 #ifndef __GNU_GETTEXT_SUPPORTED_REVISION
12783 extern int _nl_msg_cat_cntr;
12784 extern
12785 #ifdef __cplusplus
12787 #endif
12788 const char *_nl_expand_alias (const char *);
12789 #define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_expand_alias (""))
12790 #else
12791 #define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
12792 #endif
12793 $gt_revision_test_code
12796 main ()
12799 bindtextdomain ("", "");
12800 return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
12803 return 0;
12805 _ACEOF
12806 if ac_fn_c_try_link "$LINENO"; then :
12807 LIBINTL="$LIBINTL $LIBICONV"
12808 LTLIBINTL="$LTLIBINTL $LTLIBICONV"
12809 eval "$gt_func_gnugettext_libintl=yes"
12812 rm -f core conftest.err conftest.$ac_objext \
12813 conftest$ac_exeext conftest.$ac_ext
12815 CPPFLAGS="$gt_save_CPPFLAGS"
12816 LIBS="$gt_save_LIBS"
12818 eval ac_res=\$$gt_func_gnugettext_libintl
12819 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
12820 $as_echo "$ac_res" >&6; }
12823 if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" = "yes"; } \
12824 || { { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; } \
12825 && test "$PACKAGE" != gettext-runtime \
12826 && test "$PACKAGE" != gettext-tools; }; then
12827 gt_use_preinstalled_gnugettext=yes
12828 else
12829 LIBINTL=
12830 LTLIBINTL=
12831 INCINTL=
12836 if test -n "$INTL_MACOSX_LIBS"; then
12837 if test "$gt_use_preinstalled_gnugettext" = "yes" \
12838 || test "$nls_cv_use_gnu_gettext" = "yes"; then
12839 LIBINTL="$LIBINTL $INTL_MACOSX_LIBS"
12840 LTLIBINTL="$LTLIBINTL $INTL_MACOSX_LIBS"
12844 if test "$gt_use_preinstalled_gnugettext" = "yes" \
12845 || test "$nls_cv_use_gnu_gettext" = "yes"; then
12847 $as_echo "#define ENABLE_NLS 1" >>confdefs.h
12849 else
12850 USE_NLS=no
12854 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use NLS" >&5
12855 $as_echo_n "checking whether to use NLS... " >&6; }
12856 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5
12857 $as_echo "$USE_NLS" >&6; }
12858 if test "$USE_NLS" = "yes"; then
12859 { $as_echo "$as_me:${as_lineno-$LINENO}: checking where the gettext function comes from" >&5
12860 $as_echo_n "checking where the gettext function comes from... " >&6; }
12861 if test "$gt_use_preinstalled_gnugettext" = "yes"; then
12862 if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
12863 gt_source="external libintl"
12864 else
12865 gt_source="libc"
12867 else
12868 gt_source="included intl directory"
12870 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_source" >&5
12871 $as_echo "$gt_source" >&6; }
12874 if test "$USE_NLS" = "yes"; then
12876 if test "$gt_use_preinstalled_gnugettext" = "yes"; then
12877 if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
12878 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libintl" >&5
12879 $as_echo_n "checking how to link with libintl... " >&6; }
12880 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBINTL" >&5
12881 $as_echo "$LIBINTL" >&6; }
12883 for element in $INCINTL; do
12884 haveit=
12885 for x in $CPPFLAGS; do
12887 acl_save_prefix="$prefix"
12888 prefix="$acl_final_prefix"
12889 acl_save_exec_prefix="$exec_prefix"
12890 exec_prefix="$acl_final_exec_prefix"
12891 eval x=\"$x\"
12892 exec_prefix="$acl_save_exec_prefix"
12893 prefix="$acl_save_prefix"
12895 if test "X$x" = "X$element"; then
12896 haveit=yes
12897 break
12899 done
12900 if test -z "$haveit"; then
12901 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
12903 done
12908 $as_echo "#define HAVE_GETTEXT 1" >>confdefs.h
12911 $as_echo "#define HAVE_DCGETTEXT 1" >>confdefs.h
12915 POSUB=po
12920 INTLLIBS="$LIBINTL"
12939 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5
12940 $as_echo_n "checking whether NLS is requested... " >&6; }
12941 if test x"$USE_NLS" != xyes; then
12942 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12943 $as_echo "no" >&6; }
12944 else
12945 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12946 $as_echo "yes" >&6; }
12948 $as_echo "#define ENABLE_NLS 1" >>confdefs.h
12951 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for catalogs to be installed" >&5
12952 $as_echo_n "checking for catalogs to be installed... " >&6; }
12953 # Look for .po and .gmo files in the source directory.
12954 CATALOGS=
12955 XLINGUAS=
12956 for cat in $srcdir/po/*.gmo $srcdir/po/*.po; do
12957 # If there aren't any .gmo files the shell will give us the
12958 # literal string "../path/to/srcdir/po/*.gmo" which has to be
12959 # weeded out.
12960 case "$cat" in *\**)
12961 continue;;
12962 esac
12963 # The quadruple backslash is collapsed to a double backslash
12964 # by the backticks, then collapsed again by the double quotes,
12965 # leaving us with one backslash in the sed expression (right
12966 # before the dot that mustn't act as a wildcard).
12967 cat=`echo $cat | sed -e "s!$srcdir/po/!!" -e "s!\\\\.po!.gmo!"`
12968 lang=`echo $cat | sed -e "s!\\\\.gmo!!"`
12969 # The user is allowed to set LINGUAS to a list of languages to
12970 # install catalogs for. If it's empty that means "all of them."
12971 if test "x$LINGUAS" = x; then
12972 CATALOGS="$CATALOGS $cat"
12973 XLINGUAS="$XLINGUAS $lang"
12974 else
12975 case "$LINGUAS" in *$lang*)
12976 CATALOGS="$CATALOGS $cat"
12977 XLINGUAS="$XLINGUAS $lang"
12979 esac
12981 done
12982 LINGUAS="$XLINGUAS"
12983 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINGUAS" >&5
12984 $as_echo "$LINGUAS" >&6; }
12987 DATADIRNAME=share
12989 INSTOBJEXT=.mo
12991 GENCAT=gencat
12993 CATOBJEXT=.gmo
12997 # Create sub-directories for objects and dependencies.
12998 CONFIG_SRC_SUBDIR="arch gdbsupport nat target"
13001 ac_config_commands="$ac_config_commands gdbdepdir"
13004 depcc="$CC" am_compiler_list=
13006 am_depcomp=$ac_aux_dir/depcomp
13007 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
13008 $as_echo_n "checking dependency style of $depcc... " >&6; }
13009 if ${am_cv_CC_dependencies_compiler_type+:} false; then :
13010 $as_echo_n "(cached) " >&6
13011 else
13012 if test -f "$am_depcomp"; then
13013 # We make a subdir and do the tests there. Otherwise we can end up
13014 # making bogus files that we don't know about and never remove. For
13015 # instance it was reported that on HP-UX the gcc test will end up
13016 # making a dummy file named `D' -- because `-MD' means `put the output
13017 # in D'.
13018 mkdir conftest.dir
13019 # Copy depcomp to subdir because otherwise we won't find it if we're
13020 # using a relative directory.
13021 cp "$am_depcomp" conftest.dir
13022 cd conftest.dir
13023 # We will build objects and dependencies in a subdirectory because
13024 # it helps to detect inapplicable dependency modes. For instance
13025 # both Tru64's cc and ICC support -MD to output dependencies as a
13026 # side effect of compilation, but ICC will put the dependencies in
13027 # the current directory while Tru64 will put them in the object
13028 # directory.
13029 mkdir sub
13031 am_cv_CC_dependencies_compiler_type=none
13032 if test "$am_compiler_list" = ""; then
13033 am_compiler_list=`sed -n 's/^\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
13035 for depmode in $am_compiler_list; do
13036 if test $depmode = none; then break; fi
13038 $as_echo "$as_me:$LINENO: trying $depmode" >&5
13039 # Setup a source with many dependencies, because some compilers
13040 # like to wrap large dependency lists on column 80 (with \), and
13041 # we should not choose a depcomp mode which is confused by this.
13043 # We need to recreate these files for each test, as the compiler may
13044 # overwrite some of them when testing with obscure command lines.
13045 # This happens at least with the AIX C compiler.
13046 : > sub/conftest.c
13047 for i in 1 2 3 4 5 6; do
13048 echo '#include "conftst'$i'.h"' >> sub/conftest.c
13049 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
13050 # Solaris 8's {/usr,}/bin/sh.
13051 touch sub/conftst$i.h
13052 done
13053 echo "include sub/conftest.Po" > confmf
13055 # We check with `-c' and `-o' for the sake of the "dashmstdout"
13056 # mode. It turns out that the SunPro C++ compiler does not properly
13057 # handle `-M -o', and we need to detect this.
13058 depcmd="depmode=$depmode \
13059 source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
13060 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
13061 $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c"
13062 echo "| $depcmd" | sed -e 's/ */ /g' >&5
13063 if env $depcmd > conftest.err 2>&1 &&
13064 grep sub/conftst6.h sub/conftest.Po >>conftest.err 2>&1 &&
13065 grep sub/conftest.${OBJEXT-o} sub/conftest.Po >>conftest.err 2>&1 &&
13066 ${MAKE-make} -s -f confmf >>conftest.err 2>&1; then
13067 # icc doesn't choke on unknown options, it will just issue warnings
13068 # or remarks (even with -Werror). So we grep stderr for any message
13069 # that says an option was ignored or not supported.
13070 # When given -MP, icc 7.0 and 7.1 complain thusly:
13071 # icc: Command line warning: ignoring option '-M'; no argument required
13072 # The diagnosis changed in icc 8.0:
13073 # icc: Command line remark: option '-MP' not supported
13074 if (grep 'ignoring option' conftest.err ||
13075 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
13076 am_cv_CC_dependencies_compiler_type=$depmode
13077 $as_echo "$as_me:$LINENO: success" >&5
13078 break
13081 $as_echo "$as_me:$LINENO: failure, diagnostics are:" >&5
13082 sed -e 's/^/| /' < conftest.err >&5
13083 done
13085 cd ..
13086 rm -rf conftest.dir
13087 else
13088 am_cv_CC_dependencies_compiler_type=none
13092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
13093 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
13094 if test x${am_cv_CC_dependencies_compiler_type-none} = xnone
13095 then as_fn_error $? "no usable dependency style found" "$LINENO" 5
13096 else CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
13101 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
13102 do :
13103 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13104 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
13105 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
13106 cat >>confdefs.h <<_ACEOF
13107 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13108 _ACEOF
13112 done
13114 for ac_header in vfork.h
13115 do :
13116 ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
13117 if test "x$ac_cv_header_vfork_h" = xyes; then :
13118 cat >>confdefs.h <<_ACEOF
13119 #define HAVE_VFORK_H 1
13120 _ACEOF
13124 done
13126 for ac_func in fork vfork
13127 do :
13128 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13129 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13130 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
13131 cat >>confdefs.h <<_ACEOF
13132 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13133 _ACEOF
13136 done
13138 if test "x$ac_cv_func_fork" = xyes; then
13139 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
13140 $as_echo_n "checking for working fork... " >&6; }
13141 if ${ac_cv_func_fork_works+:} false; then :
13142 $as_echo_n "(cached) " >&6
13143 else
13144 if test "$cross_compiling" = yes; then :
13145 ac_cv_func_fork_works=cross
13146 else
13147 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13148 /* end confdefs.h. */
13149 $ac_includes_default
13151 main ()
13154 /* By Ruediger Kuhlmann. */
13155 return fork () < 0;
13158 return 0;
13160 _ACEOF
13161 if ac_fn_c_try_run "$LINENO"; then :
13162 ac_cv_func_fork_works=yes
13163 else
13164 ac_cv_func_fork_works=no
13166 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13167 conftest.$ac_objext conftest.beam conftest.$ac_ext
13171 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
13172 $as_echo "$ac_cv_func_fork_works" >&6; }
13174 else
13175 ac_cv_func_fork_works=$ac_cv_func_fork
13177 if test "x$ac_cv_func_fork_works" = xcross; then
13178 case $host in
13179 *-*-amigaos* | *-*-msdosdjgpp*)
13180 # Override, as these systems have only a dummy fork() stub
13181 ac_cv_func_fork_works=no
13184 ac_cv_func_fork_works=yes
13186 esac
13187 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
13188 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
13190 ac_cv_func_vfork_works=$ac_cv_func_vfork
13191 if test "x$ac_cv_func_vfork" = xyes; then
13192 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
13193 $as_echo_n "checking for working vfork... " >&6; }
13194 if ${ac_cv_func_vfork_works+:} false; then :
13195 $as_echo_n "(cached) " >&6
13196 else
13197 if test "$cross_compiling" = yes; then :
13198 ac_cv_func_vfork_works=cross
13199 else
13200 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13201 /* end confdefs.h. */
13202 /* Thanks to Paul Eggert for this test. */
13203 $ac_includes_default
13204 #include <sys/wait.h>
13205 #ifdef HAVE_VFORK_H
13206 # include <vfork.h>
13207 #endif
13208 /* On some sparc systems, changes by the child to local and incoming
13209 argument registers are propagated back to the parent. The compiler
13210 is told about this with #include <vfork.h>, but some compilers
13211 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
13212 static variable whose address is put into a register that is
13213 clobbered by the vfork. */
13214 static void
13215 #ifdef __cplusplus
13216 sparc_address_test (int arg)
13217 # else
13218 sparc_address_test (arg) int arg;
13219 #endif
13221 static pid_t child;
13222 if (!child) {
13223 child = vfork ();
13224 if (child < 0) {
13225 perror ("vfork");
13226 _exit(2);
13228 if (!child) {
13229 arg = getpid();
13230 write(-1, "", 0);
13231 _exit (arg);
13237 main ()
13239 pid_t parent = getpid ();
13240 pid_t child;
13242 sparc_address_test (0);
13244 child = vfork ();
13246 if (child == 0) {
13247 /* Here is another test for sparc vfork register problems. This
13248 test uses lots of local variables, at least as many local
13249 variables as main has allocated so far including compiler
13250 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
13251 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
13252 reuse the register of parent for one of the local variables,
13253 since it will think that parent can't possibly be used any more
13254 in this routine. Assigning to the local variable will thus
13255 munge parent in the parent process. */
13256 pid_t
13257 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
13258 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
13259 /* Convince the compiler that p..p7 are live; otherwise, it might
13260 use the same hardware register for all 8 local variables. */
13261 if (p != p1 || p != p2 || p != p3 || p != p4
13262 || p != p5 || p != p6 || p != p7)
13263 _exit(1);
13265 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
13266 from child file descriptors. If the child closes a descriptor
13267 before it execs or exits, this munges the parent's descriptor
13268 as well. Test for this by closing stdout in the child. */
13269 _exit(close(fileno(stdout)) != 0);
13270 } else {
13271 int status;
13272 struct stat st;
13274 while (wait(&status) != child)
13276 return (
13277 /* Was there some problem with vforking? */
13278 child < 0
13280 /* Did the child fail? (This shouldn't happen.) */
13281 || status
13283 /* Did the vfork/compiler bug occur? */
13284 || parent != getpid()
13286 /* Did the file descriptor bug occur? */
13287 || fstat(fileno(stdout), &st) != 0
13291 _ACEOF
13292 if ac_fn_c_try_run "$LINENO"; then :
13293 ac_cv_func_vfork_works=yes
13294 else
13295 ac_cv_func_vfork_works=no
13297 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13298 conftest.$ac_objext conftest.beam conftest.$ac_ext
13302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
13303 $as_echo "$ac_cv_func_vfork_works" >&6; }
13306 if test "x$ac_cv_func_fork_works" = xcross; then
13307 ac_cv_func_vfork_works=$ac_cv_func_vfork
13308 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
13309 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
13312 if test "x$ac_cv_func_vfork_works" = xyes; then
13314 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
13316 else
13318 $as_echo "#define vfork fork" >>confdefs.h
13321 if test "x$ac_cv_func_fork_works" = xyes; then
13323 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
13327 for ac_func in pread pwrite pread64
13328 do :
13329 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13330 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13331 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
13332 cat >>confdefs.h <<_ACEOF
13333 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13334 _ACEOF
13337 done
13340 # Check the return and argument types of ptrace.
13343 for ac_header in sys/ptrace.h ptrace.h
13344 do :
13345 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13346 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
13347 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
13348 cat >>confdefs.h <<_ACEOF
13349 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13350 _ACEOF
13354 done
13357 gdb_ptrace_headers='
13358 #include <sys/types.h>
13359 #if HAVE_SYS_PTRACE_H
13360 # include <sys/ptrace.h>
13361 #endif
13362 #if HAVE_UNISTD_H
13363 # include <unistd.h>
13364 #endif
13367 # Check return type. Varargs (used on GNU/Linux) conflict with the
13368 # empty argument list, so check for that explicitly.
13369 { $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of ptrace" >&5
13370 $as_echo_n "checking return type of ptrace... " >&6; }
13371 if ${gdb_cv_func_ptrace_ret+:} false; then :
13372 $as_echo_n "(cached) " >&6
13373 else
13374 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13375 /* end confdefs.h. */
13376  $gdb_ptrace_headers
13378 main ()
13380 extern long ptrace (enum __ptrace_request, ...);
13383 return 0;
13385 _ACEOF
13386 if ac_fn_c_try_compile "$LINENO"; then :
13387 gdb_cv_func_ptrace_ret='long'
13388 else
13389 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13390 /* end confdefs.h. */
13391 $gdb_ptrace_headers
13393 main ()
13395 extern int ptrace ();
13398 return 0;
13400 _ACEOF
13401 if ac_fn_c_try_compile "$LINENO"; then :
13402 gdb_cv_func_ptrace_ret='int'
13403 else
13404 gdb_cv_func_ptrace_ret='long'
13407 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13410 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13413 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_func_ptrace_ret" >&5
13414 $as_echo "$gdb_cv_func_ptrace_ret" >&6; }
13417 cat >>confdefs.h <<_ACEOF
13418 #define PTRACE_TYPE_RET $gdb_cv_func_ptrace_ret
13419 _ACEOF
13422 # Check argument types.
13423 { $as_echo "$as_me:${as_lineno-$LINENO}: checking types of arguments for ptrace" >&5
13424 $as_echo_n "checking types of arguments for ptrace... " >&6; }
13425 if ${gdb_cv_func_ptrace_args+:} false; then :
13426 $as_echo_n "(cached) " >&6
13427 else
13428 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13429 /* end confdefs.h. */
13430 $gdb_ptrace_headers
13432 main ()
13434 extern long ptrace (enum __ptrace_request, ...);
13437 return 0;
13439 _ACEOF
13440 if ac_fn_c_try_compile "$LINENO"; then :
13441 gdb_cv_func_ptrace_args='enum __ptrace_request,int,long,long'
13442 else
13443 for gdb_arg1 in 'int' 'long'; do
13444 for gdb_arg2 in 'pid_t' 'int' 'long'; do
13445 for gdb_arg3 in 'int *' 'caddr_t' 'int' 'long' 'void *'; do
13446 for gdb_arg4 in 'int' 'long' 'void *'; do
13447 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13448 /* end confdefs.h. */
13449 $gdb_ptrace_headers
13451 main ()
13453 extern $gdb_cv_func_ptrace_ret ptrace ($gdb_arg1, $gdb_arg2, $gdb_arg3, $gdb_arg4);
13456 return 0;
13458 _ACEOF
13459 if ac_fn_c_try_compile "$LINENO"; then :
13460 gdb_cv_func_ptrace_args="$gdb_arg1,$gdb_arg2,$gdb_arg3,$gdb_arg4";
13461 break 4;
13464 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13466 for gdb_arg5 in 'int *' 'int' 'long'; do
13467 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13468 /* end confdefs.h. */
13469 $gdb_ptrace_headers
13471 main ()
13473 extern $gdb_cv_func_ptrace_ret ptrace ($gdb_arg1, $gdb_arg2, $gdb_arg3, $gdb_arg4, $gdb_arg5);
13476 return 0;
13478 _ACEOF
13479 if ac_fn_c_try_compile "$LINENO"; then :
13480 gdb_cv_func_ptrace_args="$gdb_arg1,$gdb_arg2,$gdb_arg3,$gdb_arg4,$gdb_arg5";
13481 break 5;
13484 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13485 done
13486 done
13487 done
13488 done
13489 done
13490 # Provide a safe default value.
13491 : ${gdb_cv_func_ptrace_args='int,int,long,long'}
13494 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13497 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_func_ptrace_args" >&5
13498 $as_echo "$gdb_cv_func_ptrace_args" >&6; }
13500 ac_save_IFS=$IFS; IFS=','
13501 set dummy `echo "$gdb_cv_func_ptrace_args" | sed 's/\*/\*/g'`
13502 IFS=$ac_save_IFS
13503 shift
13505 cat >>confdefs.h <<_ACEOF
13506 #define PTRACE_TYPE_ARG1 $1
13507 _ACEOF
13510 cat >>confdefs.h <<_ACEOF
13511 #define PTRACE_TYPE_ARG3 $3
13512 _ACEOF
13515 cat >>confdefs.h <<_ACEOF
13516 #define PTRACE_TYPE_ARG4 $4
13517 _ACEOF
13519 if test -n "$5"; then
13521 cat >>confdefs.h <<_ACEOF
13522 #define PTRACE_TYPE_ARG5 $5
13523 _ACEOF
13528 # Check for UST
13529 ustlibs=""
13530 ustinc=""
13533 # Check whether --with-ust was given.
13534 if test "${with_ust+set}" = set; then :
13535 withval=$with_ust;
13539 # Check whether --with-ust_include was given.
13540 if test "${with_ust_include+set}" = set; then :
13541 withval=$with_ust_include;
13545 # Check whether --with-ust_lib was given.
13546 if test "${with_ust_lib+set}" = set; then :
13547 withval=$with_ust_lib;
13551 case $with_ust in
13553 ustlibs=
13554 ustinc=
13556 "" | yes)
13557 ustlibs=" -lust "
13558 ustinc=""
13561 ustlibs="-L$with_ust/lib -lust"
13562 ustinc="-I$with_ust/include "
13564 esac
13565 if test "x$with_ust_include" != x; then
13566 ustinc="-I$with_ust_include "
13568 if test "x$with_ust_lib" != x; then
13569 ustlibs="-L$with_ust_lib -lust"
13572 if test "x$with_ust" != "xno"; then
13573 saved_CFLAGS="$CFLAGS"
13574 CFLAGS="$CFLAGS $ustinc"
13575 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ust" >&5
13576 $as_echo_n "checking for ust... " >&6; }
13577 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13578 /* end confdefs.h. */
13580 #define CONFIG_UST_GDB_INTEGRATION
13581 #include <ust/ust.h>
13584 main ()
13589 return 0;
13591 _ACEOF
13592 if ac_fn_c_try_compile "$LINENO"; then :
13593 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13594 $as_echo "yes" >&6; };
13596 $as_echo "#define HAVE_UST 1" >>confdefs.h
13598 else
13599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13600 $as_echo "no" >&6; }
13601 ustlibs= ; ustinc=
13604 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13605 CFLAGS="$saved_CFLAGS"
13608 # Flags needed for UST
13614 { $as_echo "$as_me:${as_lineno-$LINENO}: checking the compiler type" >&5
13615 $as_echo_n "checking the compiler type... " >&6; }
13616 if ${gdb_cv_compiler_type+:} false; then :
13617 $as_echo_n "(cached) " >&6
13618 else
13619 gdb_cv_compiler_type=unknown
13620 if test "$gdb_cv_compiler_type" = unknown; then
13621 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13622 /* end confdefs.h. */
13625 main ()
13628 #if !defined __GNUC__ || defined __clang__
13629 #error not gcc
13630 #endif
13633 return 0;
13635 _ACEOF
13636 if ac_fn_c_try_compile "$LINENO"; then :
13637 gdb_cv_compiler_type=gcc
13639 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13642 if test "$gdb_cv_compiler_type" = unknown; then
13643 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13644 /* end confdefs.h. */
13647 main ()
13650 #ifndef __clang__
13651 #error not clang
13652 #endif
13655 return 0;
13657 _ACEOF
13658 if ac_fn_c_try_compile "$LINENO"; then :
13659 gdb_cv_compiler_type=clang
13661 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_compiler_type" >&5
13666 $as_echo "$gdb_cv_compiler_type" >&6; }
13668 GDB_COMPILER_TYPE="$gdb_cv_compiler_type"
13671 # Check whether --enable-werror was given.
13672 if test "${enable_werror+set}" = set; then :
13673 enableval=$enable_werror; case "${enableval}" in
13674 yes | y) ERROR_ON_WARNING="yes" ;;
13675 no | n) ERROR_ON_WARNING="no" ;;
13676 *) as_fn_error $? "bad value ${enableval} for --enable-werror" "$LINENO" 5 ;;
13677 esac
13681 # Enable -Werror by default when using gcc. Turn it off for releases.
13682 if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" && $development; then
13683 ERROR_ON_WARNING=yes
13686 WERROR_CFLAGS=""
13687 if test "${ERROR_ON_WARNING}" = yes ; then
13688 WERROR_CFLAGS="-Werror"
13691 # The options we'll try to enable.
13692 build_warnings="-Wall -Wpointer-arith \
13693 -Wno-unused -Wunused-value -Wunused-variable -Wunused-function \
13694 -Wno-switch -Wno-char-subscripts \
13695 -Wempty-body -Wunused-but-set-parameter -Wunused-but-set-variable \
13696 -Wno-sign-compare -Wno-error=maybe-uninitialized \
13697 -Wno-mismatched-tags \
13698 -Wno-error=deprecated-register \
13699 -Wsuggest-override \
13700 -Wimplicit-fallthrough=5 \
13701 -Wduplicated-cond \
13702 -Wshadow=local \
13703 -Wdeprecated-copy \
13704 -Wdeprecated-copy-dtor \
13705 -Wredundant-move \
13706 -Wmissing-declarations \
13707 -Wstrict-null-sentinel \
13710 # The -Wmissing-prototypes flag will be accepted by GCC, but results
13711 # in a warning being printed about the flag not being valid for C++,
13712 # this is something to do with using ccache, and argument ordering.
13713 if test "$GDB_COMPILER_TYPE" != gcc; then
13714 build_warnings="$build_warnings -Wmissing-prototypes"
13717 case "${host}" in
13718 *-*-mingw32*)
13719 # Enable -Wno-format by default when using gcc on mingw since many
13720 # GCC versions complain about %I64.
13721 build_warnings="$build_warnings -Wno-format" ;;
13722 *-*-solaris*)
13723 # Solaris 11.4 <python2.7/ceval.h> uses #pragma no_inline that GCC
13724 # doesn't understand.
13725 build_warnings="$build_warnings -Wno-unknown-pragmas"
13726 # Solaris 11 <unistd.h> marks vfork deprecated.
13727 build_warnings="$build_warnings -Wno-deprecated-declarations" ;;
13729 # Note that gcc requires -Wformat for -Wformat-nonliteral to work,
13730 # but there's a special case for this below.
13731 build_warnings="$build_warnings -Wformat-nonliteral" ;;
13732 esac
13734 # Check whether --enable-build-warnings was given.
13735 if test "${enable_build_warnings+set}" = set; then :
13736 enableval=$enable_build_warnings; case "${enableval}" in
13737 yes) ;;
13738 no) build_warnings="-w";;
13739 ,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
13740 build_warnings="${build_warnings} ${t}";;
13741 *,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
13742 build_warnings="${t} ${build_warnings}";;
13743 *) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
13744 esac
13745 if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
13746 echo "Setting compiler warning flags = $build_warnings" 6>&1
13749 # Check whether --enable-gdb-build-warnings was given.
13750 if test "${enable_gdb_build_warnings+set}" = set; then :
13751 enableval=$enable_gdb_build_warnings; case "${enableval}" in
13752 yes) ;;
13753 no) build_warnings="-w";;
13754 ,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
13755 build_warnings="${build_warnings} ${t}";;
13756 *,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
13757 build_warnings="${t} ${build_warnings}";;
13758 *) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
13759 esac
13760 if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
13761 echo "Setting GDB specific compiler warning flags = $build_warnings" 6>&1
13765 # The set of warnings supported by a C++ compiler is not the same as
13766 # of the C compiler.
13767 ac_ext=cpp
13768 ac_cpp='$CXXCPP $CPPFLAGS'
13769 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
13770 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
13771 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
13774 WARN_CFLAGS=""
13775 if test "x${build_warnings}" != x -a "x$GCC" = xyes
13776 then
13777 { $as_echo "$as_me:${as_lineno-$LINENO}: checking compiler warning flags" >&5
13778 $as_echo_n "checking compiler warning flags... " >&6; }
13779 # Separate out the -Werror flag as some files just cannot be
13780 # compiled with it enabled.
13781 for w in ${build_warnings}; do
13782 # GCC does not complain about -Wno-unknown-warning. Invert
13783 # and test -Wunknown-warning instead.
13784 case $w in
13785 -Wno-*)
13786 wtest=`echo $w | sed 's/-Wno-/-W/g'` ;;
13787 -Wformat-nonliteral)
13788 # gcc requires -Wformat before -Wformat-nonliteral
13789 # will work, so stick them together.
13790 w="-Wformat $w"
13791 wtest="$w"
13794 wtest=$w ;;
13795 esac
13797 case $w in
13798 -Werr*) WERROR_CFLAGS=-Werror ;;
13800 # Check whether GCC accepts it.
13801 saved_CFLAGS="$CFLAGS"
13802 CFLAGS="$CFLAGS -Werror $wtest"
13803 saved_CXXFLAGS="$CXXFLAGS"
13804 CXXFLAGS="$CXXFLAGS -Werror $wtest"
13805 if test "x$w" = "x-Wunused-variable"; then
13806 # Check for https://gcc.gnu.org/bugzilla/show_bug.cgi?id=38958,
13807 # fixed in GCC 4.9. This test is derived from the gdb
13808 # source code that triggered this bug in GCC.
13809 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13810 /* end confdefs.h. */
13811 struct scoped_restore_base {};
13812 struct scoped_restore_tmpl : public scoped_restore_base {
13813 ~scoped_restore_tmpl() {}
13816 main ()
13818 const scoped_restore_base &b = scoped_restore_tmpl();
13821 return 0;
13823 _ACEOF
13824 if ac_fn_cxx_try_compile "$LINENO"; then :
13825 WARN_CFLAGS="${WARN_CFLAGS} $w"
13827 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13828 else
13829 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13830 /* end confdefs.h. */
13833 main ()
13837 return 0;
13839 _ACEOF
13840 if ac_fn_cxx_try_compile "$LINENO"; then :
13841 WARN_CFLAGS="${WARN_CFLAGS} $w"
13843 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13845 CFLAGS="$saved_CFLAGS"
13846 CXXFLAGS="$saved_CXXFLAGS"
13847 esac
13848 done
13849 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${WARN_CFLAGS} ${WERROR_CFLAGS}" >&5
13850 $as_echo "${WARN_CFLAGS} ${WERROR_CFLAGS}" >&6; }
13855 ac_ext=c
13856 ac_cpp='$CPP $CPPFLAGS'
13857 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
13858 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
13859 ac_compiler_gnu=$ac_cv_c_compiler_gnu
13863 old_LIBS="$LIBS"
13864 LIBS="$LIBS -ldl"
13865 for ac_func in dladdr
13866 do :
13867 ac_fn_c_check_func "$LINENO" "dladdr" "ac_cv_func_dladdr"
13868 if test "x$ac_cv_func_dladdr" = xyes; then :
13869 cat >>confdefs.h <<_ACEOF
13870 #define HAVE_DLADDR 1
13871 _ACEOF
13874 done
13876 LIBS="$old_LIBS"
13878 ac_fn_c_check_decl "$LINENO" "ffs" "ac_cv_have_decl_ffs" "$ac_includes_default"
13879 if test "x$ac_cv_have_decl_ffs" = xyes; then :
13880 ac_have_decl=1
13881 else
13882 ac_have_decl=0
13885 cat >>confdefs.h <<_ACEOF
13886 #define HAVE_DECL_FFS $ac_have_decl
13887 _ACEOF
13889 ac_fn_c_check_decl "$LINENO" "asprintf" "ac_cv_have_decl_asprintf" "$ac_includes_default"
13890 if test "x$ac_cv_have_decl_asprintf" = xyes; then :
13891 ac_have_decl=1
13892 else
13893 ac_have_decl=0
13896 cat >>confdefs.h <<_ACEOF
13897 #define HAVE_DECL_ASPRINTF $ac_have_decl
13898 _ACEOF
13900 ac_fn_c_check_decl "$LINENO" "vasprintf" "ac_cv_have_decl_vasprintf" "$ac_includes_default"
13901 if test "x$ac_cv_have_decl_vasprintf" = xyes; then :
13902 ac_have_decl=1
13903 else
13904 ac_have_decl=0
13907 cat >>confdefs.h <<_ACEOF
13908 #define HAVE_DECL_VASPRINTF $ac_have_decl
13909 _ACEOF
13911 ac_fn_c_check_decl "$LINENO" "snprintf" "ac_cv_have_decl_snprintf" "$ac_includes_default"
13912 if test "x$ac_cv_have_decl_snprintf" = xyes; then :
13913 ac_have_decl=1
13914 else
13915 ac_have_decl=0
13918 cat >>confdefs.h <<_ACEOF
13919 #define HAVE_DECL_SNPRINTF $ac_have_decl
13920 _ACEOF
13922 ac_fn_c_check_decl "$LINENO" "vsnprintf" "ac_cv_have_decl_vsnprintf" "$ac_includes_default"
13923 if test "x$ac_cv_have_decl_vsnprintf" = xyes; then :
13924 ac_have_decl=1
13925 else
13926 ac_have_decl=0
13929 cat >>confdefs.h <<_ACEOF
13930 #define HAVE_DECL_VSNPRINTF $ac_have_decl
13931 _ACEOF
13933 ac_fn_c_check_decl "$LINENO" "strtol" "ac_cv_have_decl_strtol" "$ac_includes_default"
13934 if test "x$ac_cv_have_decl_strtol" = xyes; then :
13935 ac_have_decl=1
13936 else
13937 ac_have_decl=0
13940 cat >>confdefs.h <<_ACEOF
13941 #define HAVE_DECL_STRTOL $ac_have_decl
13942 _ACEOF
13944 ac_fn_c_check_decl "$LINENO" "strtoul" "ac_cv_have_decl_strtoul" "$ac_includes_default"
13945 if test "x$ac_cv_have_decl_strtoul" = xyes; then :
13946 ac_have_decl=1
13947 else
13948 ac_have_decl=0
13951 cat >>confdefs.h <<_ACEOF
13952 #define HAVE_DECL_STRTOUL $ac_have_decl
13953 _ACEOF
13955 ac_fn_c_check_decl "$LINENO" "strtoll" "ac_cv_have_decl_strtoll" "$ac_includes_default"
13956 if test "x$ac_cv_have_decl_strtoll" = xyes; then :
13957 ac_have_decl=1
13958 else
13959 ac_have_decl=0
13962 cat >>confdefs.h <<_ACEOF
13963 #define HAVE_DECL_STRTOLL $ac_have_decl
13964 _ACEOF
13966 ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default"
13967 if test "x$ac_cv_have_decl_strtoull" = xyes; then :
13968 ac_have_decl=1
13969 else
13970 ac_have_decl=0
13973 cat >>confdefs.h <<_ACEOF
13974 #define HAVE_DECL_STRTOULL $ac_have_decl
13975 _ACEOF
13977 ac_fn_c_check_decl "$LINENO" "strverscmp" "ac_cv_have_decl_strverscmp" "$ac_includes_default"
13978 if test "x$ac_cv_have_decl_strverscmp" = xyes; then :
13979 ac_have_decl=1
13980 else
13981 ac_have_decl=0
13984 cat >>confdefs.h <<_ACEOF
13985 #define HAVE_DECL_STRVERSCMP $ac_have_decl
13986 _ACEOF
13988 ac_fn_c_check_type "$LINENO" "long long" "ac_cv_type_long_long" "$ac_includes_default"
13989 if test "x$ac_cv_type_long_long" = xyes; then :
13991 cat >>confdefs.h <<_ACEOF
13992 #define HAVE_LONG_LONG 1
13993 _ACEOF
13995 # The cast to long int works around a bug in the HP C Compiler
13996 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
13997 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
13998 # This bug is HP SR number 8606223364.
13999 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5
14000 $as_echo_n "checking size of long long... " >&6; }
14001 if ${ac_cv_sizeof_long_long+:} false; then :
14002 $as_echo_n "(cached) " >&6
14003 else
14004 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long" "$ac_includes_default"; then :
14006 else
14007 if test "$ac_cv_type_long_long" = yes; then
14008 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
14009 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
14010 as_fn_error 77 "cannot compute sizeof (long long)
14011 See \`config.log' for more details" "$LINENO" 5; }
14012 else
14013 ac_cv_sizeof_long_long=0
14018 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5
14019 $as_echo "$ac_cv_sizeof_long_long" >&6; }
14023 cat >>confdefs.h <<_ACEOF
14024 #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
14025 _ACEOF
14031 as_ac_Symbol=`$as_echo "ac_cv_have_decl_basename(char *)" | $as_tr_sh`
14032 ac_fn_c_check_decl "$LINENO" "basename(char *)" "$as_ac_Symbol" "$ac_includes_default"
14033 if eval test \"x\$"$as_ac_Symbol"\" = x"yes"; then :
14034 ac_have_decl=1
14035 else
14036 ac_have_decl=0
14039 cat >>confdefs.h <<_ACEOF
14040 #define HAVE_DECL_BASENAME $ac_have_decl
14041 _ACEOF
14048 ac_fn_c_check_decl "$LINENO" "perror" "ac_cv_have_decl_perror" "$ac_includes_default"
14049 if test "x$ac_cv_have_decl_perror" = xyes; then :
14050 ac_have_decl=1
14051 else
14052 ac_have_decl=0
14055 cat >>confdefs.h <<_ACEOF
14056 #define HAVE_DECL_PERROR $ac_have_decl
14057 _ACEOF
14058 ac_fn_c_check_decl "$LINENO" "vasprintf" "ac_cv_have_decl_vasprintf" "$ac_includes_default"
14059 if test "x$ac_cv_have_decl_vasprintf" = xyes; then :
14060 ac_have_decl=1
14061 else
14062 ac_have_decl=0
14065 cat >>confdefs.h <<_ACEOF
14066 #define HAVE_DECL_VASPRINTF $ac_have_decl
14067 _ACEOF
14068 ac_fn_c_check_decl "$LINENO" "vsnprintf" "ac_cv_have_decl_vsnprintf" "$ac_includes_default"
14069 if test "x$ac_cv_have_decl_vsnprintf" = xyes; then :
14070 ac_have_decl=1
14071 else
14072 ac_have_decl=0
14075 cat >>confdefs.h <<_ACEOF
14076 #define HAVE_DECL_VSNPRINTF $ac_have_decl
14077 _ACEOF
14080 ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "#include <sys/types.h>
14081 #if HAVE_SYS_SOCKET_H
14082 # include <sys/socket.h>
14083 #elif HAVE_WS2TCPIP_H
14084 # include <ws2tcpip.h>
14085 #endif
14088 if test "x$ac_cv_type_socklen_t" = xyes; then :
14090 cat >>confdefs.h <<_ACEOF
14091 #define HAVE_SOCKLEN_T 1
14092 _ACEOF
14098 case "${target}" in
14099 *-android*)
14100 # Starting with NDK version 9, <elf.h> actually includes definitions
14101 # of Elf32_auxv_t and Elf64_auxv_t. But sadly, <elf.h> includes
14102 # <sys/exec_elf.h> which defines some of the ELF types incorrectly,
14103 # leading to conflicts with the defintions from <linux/elf.h>.
14104 # This makes it impossible for us to include both <elf.h> and
14105 # <linux/elf.h>, which means that, in practice, we do not have
14106 # access to Elf32_auxv_t and Elf64_auxv_t on this platform.
14107 # Therefore, do not try to auto-detect availability, as it would
14108 # get it wrong on this platform.
14111 ac_fn_c_check_type "$LINENO" "Elf32_auxv_t" "ac_cv_type_Elf32_auxv_t" "#include <elf.h>
14114 if test "x$ac_cv_type_Elf32_auxv_t" = xyes; then :
14116 cat >>confdefs.h <<_ACEOF
14117 #define HAVE_ELF32_AUXV_T 1
14118 _ACEOF
14122 ac_fn_c_check_type "$LINENO" "Elf64_auxv_t" "ac_cv_type_Elf64_auxv_t" "#include <elf.h>
14125 if test "x$ac_cv_type_Elf64_auxv_t" = xyes; then :
14127 cat >>confdefs.h <<_ACEOF
14128 #define HAVE_ELF64_AUXV_T 1
14129 _ACEOF
14134 esac
14138 # Check whether --with-pkgversion was given.
14139 if test "${with_pkgversion+set}" = set; then :
14140 withval=$with_pkgversion; case "$withval" in
14141 yes) as_fn_error $? "package version not specified" "$LINENO" 5 ;;
14142 no) PKGVERSION= ;;
14143 *) PKGVERSION="($withval) " ;;
14144 esac
14145 else
14146 PKGVERSION="(GDB) "
14154 # Check whether --with-bugurl was given.
14155 if test "${with_bugurl+set}" = set; then :
14156 withval=$with_bugurl; case "$withval" in
14157 yes) as_fn_error $? "bug URL not specified" "$LINENO" 5 ;;
14158 no) BUGURL=
14160 *) BUGURL="$withval"
14162 esac
14163 else
14164 BUGURL="http://www.gnu.org/software/gdb/bugs/"
14168 case ${BUGURL} in
14170 REPORT_BUGS_TO=
14171 REPORT_BUGS_TEXI=
14174 REPORT_BUGS_TO="<$BUGURL>"
14175 REPORT_BUGS_TEXI=@uref{`echo "$BUGURL" | sed 's/@/@@/g'`}
14177 esac;
14182 cat >>confdefs.h <<_ACEOF
14183 #define PKGVERSION "$PKGVERSION"
14184 _ACEOF
14187 cat >>confdefs.h <<_ACEOF
14188 #define REPORT_BUGS_TO "$REPORT_BUGS_TO"
14189 _ACEOF
14192 # Check for various supplementary target information (beyond the
14193 # triplet) which might affect the choices in configure.srv.
14194 case "${target}" in
14195 i[34567]86-*-linux*)
14196 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if building for x86-64" >&5
14197 $as_echo_n "checking if building for x86-64... " >&6; }
14198 if ${gdb_cv_i386_is_x86_64+:} false; then :
14199 $as_echo_n "(cached) " >&6
14200 else
14201 save_CPPFLAGS="$CPPFLAGS"
14202 CPPFLAGS="$CPPFLAGS $CFLAGS"
14203 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14204 /* end confdefs.h. */
14206 #if __x86_64__
14207 got it
14208 #endif
14210 _ACEOF
14211 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14212 $EGREP "got it" >/dev/null 2>&1; then :
14213 gdb_cv_i386_is_x86_64=yes
14214 else
14215 gdb_cv_i386_is_x86_64=no
14217 rm -f conftest*
14219 CPPFLAGS="$save_CPPFLAGS"
14221 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_i386_is_x86_64" >&5
14222 $as_echo "$gdb_cv_i386_is_x86_64" >&6; }
14225 x86_64-*-linux*)
14226 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if building for x32" >&5
14227 $as_echo_n "checking if building for x32... " >&6; }
14228 if ${gdb_cv_x86_is_x32+:} false; then :
14229 $as_echo_n "(cached) " >&6
14230 else
14231 save_CPPFLAGS="$CPPFLAGS"
14232 CPPFLAGS="$CPPFLAGS $CFLAGS"
14233 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14234 /* end confdefs.h. */
14236 #if __x86_64__ && __ILP32__
14237 got it
14238 #endif
14240 _ACEOF
14241 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14242 $EGREP "got it" >/dev/null 2>&1; then :
14243 gdb_cv_x86_is_x32=yes
14244 else
14245 gdb_cv_x86_is_x32=no
14247 rm -f conftest*
14249 CPPFLAGS="$save_CPPFLAGS"
14251 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_x86_is_x32" >&5
14252 $as_echo "$gdb_cv_x86_is_x32" >&6; }
14255 m68k-*-*)
14256 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if building for Coldfire" >&5
14257 $as_echo_n "checking if building for Coldfire... " >&6; }
14258 if ${gdb_cv_m68k_is_coldfire+:} false; then :
14259 $as_echo_n "(cached) " >&6
14260 else
14261 save_CPPFLAGS="$CPPFLAGS"
14262 CPPFLAGS="$CPPFLAGS $CFLAGS"
14263 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14264 /* end confdefs.h. */
14266 #ifdef __mcoldfire__
14267 got it
14268 #endif
14270 _ACEOF
14271 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14272 $EGREP "got it" >/dev/null 2>&1; then :
14273 gdb_cv_m68k_is_coldfire=yes
14274 else
14275 gdb_cv_m68k_is_coldfire=no
14277 rm -f conftest*
14279 CPPFLAGS="$save_CPPFLAGS"
14281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_m68k_is_coldfire" >&5
14282 $as_echo "$gdb_cv_m68k_is_coldfire" >&6; }
14284 esac
14286 . ${srcdir}/configure.srv
14288 if test "${srv_mingwce}" = "yes"; then
14289 LIBS="$LIBS -lws2"
14290 elif test "${srv_mingw}" = "yes"; then
14291 # WIN32APILIBS is set by GDB_AC_COMMON.
14292 LIBS="$LIBS $WIN32APILIBS"
14295 if test "${srv_linux_usrregs}" = "yes"; then
14297 $as_echo "#define HAVE_LINUX_USRREGS 1" >>confdefs.h
14301 if test "${srv_linux_regsets}" = "yes"; then
14303 $as_echo "#define HAVE_LINUX_REGSETS 1" >>confdefs.h
14306 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTRACE_GETREGS" >&5
14307 $as_echo_n "checking for PTRACE_GETREGS... " >&6; }
14308 if ${gdbsrv_cv_have_ptrace_getregs+:} false; then :
14309 $as_echo_n "(cached) " >&6
14310 else
14311 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14312 /* end confdefs.h. */
14313 #include <sys/ptrace.h>
14315 main ()
14317 PTRACE_GETREGS;
14319 return 0;
14321 _ACEOF
14322 if ac_fn_c_try_compile "$LINENO"; then :
14323 gdbsrv_cv_have_ptrace_getregs=yes
14324 else
14325 gdbsrv_cv_have_ptrace_getregs=no
14328 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14332 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdbsrv_cv_have_ptrace_getregs" >&5
14333 $as_echo "$gdbsrv_cv_have_ptrace_getregs" >&6; }
14334 if test "${gdbsrv_cv_have_ptrace_getregs}" = "yes"; then
14336 $as_echo "#define HAVE_PTRACE_GETREGS 1" >>confdefs.h
14340 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTRACE_GETFPXREGS" >&5
14341 $as_echo_n "checking for PTRACE_GETFPXREGS... " >&6; }
14342 if ${gdbsrv_cv_have_ptrace_getfpxregs+:} false; then :
14343 $as_echo_n "(cached) " >&6
14344 else
14345 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14346 /* end confdefs.h. */
14347 #include <sys/ptrace.h>
14349 main ()
14351 PTRACE_GETFPXREGS;
14353 return 0;
14355 _ACEOF
14356 if ac_fn_c_try_compile "$LINENO"; then :
14357 gdbsrv_cv_have_ptrace_getfpxregs=yes
14358 else
14359 gdbsrv_cv_have_ptrace_getfpxregs=no
14362 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdbsrv_cv_have_ptrace_getfpxregs" >&5
14367 $as_echo "$gdbsrv_cv_have_ptrace_getfpxregs" >&6; }
14368 if test "${gdbsrv_cv_have_ptrace_getfpxregs}" = "yes"; then
14370 $as_echo "#define HAVE_PTRACE_GETFPXREGS 1" >>confdefs.h
14375 if test "${srv_linux_btrace}" = "yes"; then
14377 $as_echo "#define HAVE_LINUX_BTRACE 1" >>confdefs.h
14381 if test "$bfd_cv_have_sys_procfs_type_lwpid_t" != yes; then
14382 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lwpid_t in thread_db.h" >&5
14383 $as_echo_n "checking for lwpid_t in thread_db.h... " >&6; }
14384 if ${gdbserver_cv_have_thread_db_type_lwpid_t+:} false; then :
14385 $as_echo_n "(cached) " >&6
14386 else
14387 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14388 /* end confdefs.h. */
14389 #include <thread_db.h>
14391 main ()
14393 lwpid_t avar
14395 return 0;
14397 _ACEOF
14398 if ac_fn_c_try_compile "$LINENO"; then :
14399 gdbserver_cv_have_thread_db_type_lwpid_t=yes
14400 else
14401 gdbserver_cv_have_thread_db_type_lwpid_t=no
14404 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14408 if test $gdbserver_cv_have_thread_db_type_lwpid_t = yes; then
14410 $as_echo "#define HAVE_LWPID_T 1" >>confdefs.h
14413 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdbserver_cv_have_thread_db_type_lwpid_t" >&5
14414 $as_echo "$gdbserver_cv_have_thread_db_type_lwpid_t" >&6; }
14418 if test "$bfd_cv_have_sys_procfs_type_psaddr_t" != yes; then
14419 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for psaddr_t in thread_db.h" >&5
14420 $as_echo_n "checking for psaddr_t in thread_db.h... " >&6; }
14421 if ${gdbserver_cv_have_thread_db_type_psaddr_t+:} false; then :
14422 $as_echo_n "(cached) " >&6
14423 else
14424 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14425 /* end confdefs.h. */
14426 #include <thread_db.h>
14428 main ()
14430 psaddr_t avar
14432 return 0;
14434 _ACEOF
14435 if ac_fn_c_try_compile "$LINENO"; then :
14436 gdbserver_cv_have_thread_db_type_psaddr_t=yes
14437 else
14438 gdbserver_cv_have_thread_db_type_psaddr_t=no
14441 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14445 if test $gdbserver_cv_have_thread_db_type_psaddr_t = yes; then
14447 $as_echo "#define HAVE_PSADDR_T 1" >>confdefs.h
14450 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdbserver_cv_have_thread_db_type_psaddr_t" >&5
14451 $as_echo "$gdbserver_cv_have_thread_db_type_psaddr_t" >&6; }
14455 old_LIBS="$LIBS"
14456 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
14457 $as_echo_n "checking for dlopen in -ldl... " >&6; }
14458 if ${ac_cv_lib_dl_dlopen+:} false; then :
14459 $as_echo_n "(cached) " >&6
14460 else
14461 ac_check_lib_save_LIBS=$LIBS
14462 LIBS="-ldl $LIBS"
14463 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14464 /* end confdefs.h. */
14466 /* Override any GCC internal prototype to avoid an error.
14467 Use char because int might match the return type of a GCC
14468 builtin and then its argument prototype would still apply. */
14469 #ifdef __cplusplus
14470 extern "C"
14471 #endif
14472 char dlopen ();
14474 main ()
14476 return dlopen ();
14478 return 0;
14480 _ACEOF
14481 if ac_fn_c_try_link "$LINENO"; then :
14482 ac_cv_lib_dl_dlopen=yes
14483 else
14484 ac_cv_lib_dl_dlopen=no
14486 rm -f core conftest.err conftest.$ac_objext \
14487 conftest$ac_exeext conftest.$ac_ext
14488 LIBS=$ac_check_lib_save_LIBS
14490 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
14491 $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
14492 if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
14493 cat >>confdefs.h <<_ACEOF
14494 #define HAVE_LIBDL 1
14495 _ACEOF
14497 LIBS="-ldl $LIBS"
14501 LIBS="$old_LIBS"
14503 srv_thread_depfiles=
14504 srv_libs=
14506 if test "$srv_linux_thread_db" = "yes"; then
14507 if test "$ac_cv_lib_dl_dlopen" = "yes"; then
14508 srv_libs="-ldl"
14509 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the dynamic export flag" >&5
14510 $as_echo_n "checking for the dynamic export flag... " >&6; }
14511 old_LDFLAGS="$LDFLAGS"
14512 # Older GNU ld supports --export-dynamic but --dynamic-list may not be
14513 # supported there.
14514 RDYNAMIC="-Wl,--dynamic-list=${srcdir}/proc-service.list"
14515 LDFLAGS="$LDFLAGS $RDYNAMIC"
14516 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14517 /* end confdefs.h. */
14520 main ()
14524 return 0;
14526 _ACEOF
14527 if ac_fn_c_try_link "$LINENO"; then :
14528 found="-Wl,--dynamic-list"
14529 RDYNAMIC='-Wl,--dynamic-list=$(srcdir)/proc-service.list'
14530 else
14531 RDYNAMIC="-rdynamic"
14532 LDFLAGS="$old_LDFLAGS $RDYNAMIC"
14533 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14534 /* end confdefs.h. */
14537 main ()
14541 return 0;
14543 _ACEOF
14544 if ac_fn_c_try_link "$LINENO"; then :
14545 found="-rdynamic"
14546 else
14547 found="no"
14548 RDYNAMIC=""
14551 rm -f core conftest.err conftest.$ac_objext \
14552 conftest$ac_exeext conftest.$ac_ext
14555 rm -f core conftest.err conftest.$ac_objext \
14556 conftest$ac_exeext conftest.$ac_ext
14558 LDFLAGS="$old_LDFLAGS"
14559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $found" >&5
14560 $as_echo "$found" >&6; }
14561 else
14562 srv_libs="-lthread_db"
14565 srv_thread_depfiles="thread-db.o proc-service.o"
14567 $as_echo "#define USE_THREAD_DB 1" >>confdefs.h
14569 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TD_VERSION" >&5
14570 $as_echo_n "checking for TD_VERSION... " >&6; }
14571 if ${gdbsrv_cv_have_td_version+:} false; then :
14572 $as_echo_n "(cached) " >&6
14573 else
14574 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14575 /* end confdefs.h. */
14576 #include <thread_db.h>
14578 main ()
14580 TD_VERSION;
14582 return 0;
14584 _ACEOF
14585 if ac_fn_c_try_compile "$LINENO"; then :
14586 gdbsrv_cv_have_td_version=yes
14587 else
14588 gdbsrv_cv_have_td_version=no
14591 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14594 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdbsrv_cv_have_td_version" >&5
14595 $as_echo "$gdbsrv_cv_have_td_version" >&6; }
14596 if test "$gdbsrv_cv_have_td_version" = yes; then
14598 $as_echo "#define HAVE_TD_VERSION 1" >>confdefs.h
14604 # Check whether --with-libthread-db was given.
14605 if test "${with_libthread_db+set}" = set; then :
14606 withval=$with_libthread_db; srv_libthread_db_path="${withval}"
14607 srv_libs="$srv_libthread_db_path"
14612 if test "$srv_libs" != "" -a "$srv_libs" != "-ldl"; then
14614 $as_echo "#define USE_LIBTHREAD_DB_DIRECTLY 1" >>confdefs.h
14618 if test "$srv_xmlfiles" != ""; then
14619 srv_xmlbuiltin="xml-builtin.o"
14621 $as_echo "#define USE_XML 1" >>confdefs.h
14624 tmp_xmlfiles=$srv_xmlfiles
14625 srv_xmlfiles=""
14626 for f in $tmp_xmlfiles; do
14627 srv_xmlfiles="$srv_xmlfiles \$(XML_DIR)/$f"
14628 done
14631 GDBSERVER_DEPFILES="$srv_regobj $srv_tgtobj $srv_thread_depfiles"
14632 GDBSERVER_LIBS="$srv_libs"
14634 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the target supports __sync_*_compare_and_swap" >&5
14635 $as_echo_n "checking whether the target supports __sync_*_compare_and_swap... " >&6; }
14636 if ${gdbsrv_cv_have_sync_builtins+:} false; then :
14637 $as_echo_n "(cached) " >&6
14638 else
14639 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14640 /* end confdefs.h. */
14643 main ()
14645 int foo, bar;
14646 bar = __sync_val_compare_and_swap(&foo, 0, 1);
14649 return 0;
14651 _ACEOF
14652 if ac_fn_c_try_link "$LINENO"; then :
14653 gdbsrv_cv_have_sync_builtins=yes
14654 else
14655 gdbsrv_cv_have_sync_builtins=no
14658 rm -f core conftest.err conftest.$ac_objext \
14659 conftest$ac_exeext conftest.$ac_ext
14662 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdbsrv_cv_have_sync_builtins" >&5
14663 $as_echo "$gdbsrv_cv_have_sync_builtins" >&6; }
14664 if test "$gdbsrv_cv_have_sync_builtins" = yes; then
14666 $as_echo "#define HAVE_SYNC_BUILTINS 1" >>confdefs.h
14670 saved_cflags="$CFLAGS"
14671 CFLAGS="$CFLAGS -fvisibility=hidden"
14672 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14673 /* end confdefs.h. */
14676 main ()
14680 return 0;
14682 _ACEOF
14683 if ac_fn_c_try_compile "$LINENO"; then :
14684 gdbsrv_cv_have_visibility_hidden=yes
14685 else
14686 gdbsrv_cv_have_visibility_hidden=no
14688 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14689 CFLAGS="$saved_cflags"
14691 IPA_DEPFILES=""
14692 extra_libraries=""
14694 # check whether to enable the inprocess agent
14695 if test "$ipa_obj" != "" \
14696 -a "$gdbsrv_cv_have_sync_builtins" = yes \
14697 -a "$gdbsrv_cv_have_visibility_hidden" = yes; then
14698 have_ipa=true
14699 else
14700 have_ipa=false
14703 # Check whether --enable-inprocess-agent was given.
14704 if test "${enable_inprocess_agent+set}" = set; then :
14705 enableval=$enable_inprocess_agent; case "$enableval" in
14706 yes) want_ipa=true ;;
14707 no) want_ipa=false ;;
14708 *) as_fn_error $? "bad value $enableval for inprocess-agent" "$LINENO" 5 ;;
14709 esac
14710 else
14711 want_ipa=$have_ipa
14715 if $want_ipa ; then
14716 if $have_ipa ; then
14717 IPA_DEPFILES="$ipa_obj"
14718 extra_libraries="$extra_libraries libinproctrace.so"
14719 else
14720 as_fn_error $? "inprocess agent not supported for this target" "$LINENO" 5
14731 GNULIB=../gnulib/import
14733 GNULIB_STDINT_H=
14734 if test x"$STDINT_H" != x; then
14735 GNULIB_STDINT_H=$GNULIB/$STDINT_H
14739 ac_config_files="$ac_config_files Makefile"
14742 cat >confcache <<\_ACEOF
14743 # This file is a shell script that caches the results of configure
14744 # tests run on this system so they can be shared between configure
14745 # scripts and configure runs, see configure's option --config-cache.
14746 # It is not useful on other systems. If it contains results you don't
14747 # want to keep, you may remove or edit it.
14749 # config.status only pays attention to the cache file if you give it
14750 # the --recheck option to rerun configure.
14752 # `ac_cv_env_foo' variables (set or unset) will be overridden when
14753 # loading this file, other *unset* `ac_cv_foo' will be assigned the
14754 # following values.
14756 _ACEOF
14758 # The following way of writing the cache mishandles newlines in values,
14759 # but we know of no workaround that is simple, portable, and efficient.
14760 # So, we kill variables containing newlines.
14761 # Ultrix sh set writes to stderr and can't be redirected directly,
14762 # and sets the high bit in the cache file unless we assign to the vars.
14764 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
14765 eval ac_val=\$$ac_var
14766 case $ac_val in #(
14767 *${as_nl}*)
14768 case $ac_var in #(
14769 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
14770 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
14771 esac
14772 case $ac_var in #(
14773 _ | IFS | as_nl) ;; #(
14774 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
14775 *) { eval $ac_var=; unset $ac_var;} ;;
14776 esac ;;
14777 esac
14778 done
14780 (set) 2>&1 |
14781 case $as_nl`(ac_space=' '; set) 2>&1` in #(
14782 *${as_nl}ac_space=\ *)
14783 # `set' does not quote correctly, so add quotes: double-quote
14784 # substitution turns \\\\ into \\, and sed turns \\ into \.
14785 sed -n \
14786 "s/'/'\\\\''/g;
14787 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
14788 ;; #(
14790 # `set' quotes correctly as required by POSIX, so do not add quotes.
14791 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
14793 esac |
14794 sort
14796 sed '
14797 /^ac_cv_env_/b end
14798 t clear
14799 :clear
14800 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
14801 t end
14802 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
14803 :end' >>confcache
14804 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
14805 if test -w "$cache_file"; then
14806 if test "x$cache_file" != "x/dev/null"; then
14807 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
14808 $as_echo "$as_me: updating cache $cache_file" >&6;}
14809 if test ! -f "$cache_file" || test -h "$cache_file"; then
14810 cat confcache >"$cache_file"
14811 else
14812 case $cache_file in #(
14813 */* | ?:*)
14814 mv -f confcache "$cache_file"$$ &&
14815 mv -f "$cache_file"$$ "$cache_file" ;; #(
14817 mv -f confcache "$cache_file" ;;
14818 esac
14821 else
14822 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
14823 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
14826 rm -f confcache
14828 test "x$prefix" = xNONE && prefix=$ac_default_prefix
14829 # Let make expand exec_prefix.
14830 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
14832 DEFS=-DHAVE_CONFIG_H
14834 ac_libobjs=
14835 ac_ltlibobjs=
14837 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
14838 # 1. Remove the extension, and $U if already installed.
14839 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
14840 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
14841 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
14842 # will be set to the directory where LIBOBJS objects are built.
14843 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
14844 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
14845 done
14846 LIBOBJS=$ac_libobjs
14848 LTLIBOBJS=$ac_ltlibobjs
14851 if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
14852 as_fn_error $? "conditional \"MAINTAINER_MODE\" was never defined.
14853 Usually this means the macro was only invoked conditionally." "$LINENO" 5
14856 : "${CONFIG_STATUS=./config.status}"
14857 ac_write_fail=0
14858 ac_clean_files_save=$ac_clean_files
14859 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
14860 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
14861 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
14862 as_write_fail=0
14863 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
14864 #! $SHELL
14865 # Generated by $as_me.
14866 # Run this file to recreate the current configuration.
14867 # Compiler output produced by configure, useful for debugging
14868 # configure, is in config.log if it exists.
14870 debug=false
14871 ac_cs_recheck=false
14872 ac_cs_silent=false
14874 SHELL=\${CONFIG_SHELL-$SHELL}
14875 export SHELL
14876 _ASEOF
14877 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
14878 ## -------------------- ##
14879 ## M4sh Initialization. ##
14880 ## -------------------- ##
14882 # Be more Bourne compatible
14883 DUALCASE=1; export DUALCASE # for MKS sh
14884 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
14885 emulate sh
14886 NULLCMD=:
14887 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
14888 # is contrary to our usage. Disable this feature.
14889 alias -g '${1+"$@"}'='"$@"'
14890 setopt NO_GLOB_SUBST
14891 else
14892 case `(set -o) 2>/dev/null` in #(
14893 *posix*) :
14894 set -o posix ;; #(
14895 *) :
14897 esac
14901 as_nl='
14903 export as_nl
14904 # Printing a long string crashes Solaris 7 /usr/bin/printf.
14905 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
14906 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
14907 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
14908 # Prefer a ksh shell builtin over an external printf program on Solaris,
14909 # but without wasting forks for bash or zsh.
14910 if test -z "$BASH_VERSION$ZSH_VERSION" \
14911 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
14912 as_echo='print -r --'
14913 as_echo_n='print -rn --'
14914 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
14915 as_echo='printf %s\n'
14916 as_echo_n='printf %s'
14917 else
14918 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
14919 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
14920 as_echo_n='/usr/ucb/echo -n'
14921 else
14922 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
14923 as_echo_n_body='eval
14924 arg=$1;
14925 case $arg in #(
14926 *"$as_nl"*)
14927 expr "X$arg" : "X\\(.*\\)$as_nl";
14928 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
14929 esac;
14930 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
14932 export as_echo_n_body
14933 as_echo_n='sh -c $as_echo_n_body as_echo'
14935 export as_echo_body
14936 as_echo='sh -c $as_echo_body as_echo'
14939 # The user is always right.
14940 if test "${PATH_SEPARATOR+set}" != set; then
14941 PATH_SEPARATOR=:
14942 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
14943 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
14944 PATH_SEPARATOR=';'
14949 # IFS
14950 # We need space, tab and new line, in precisely that order. Quoting is
14951 # there to prevent editors from complaining about space-tab.
14952 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
14953 # splitting by setting IFS to empty value.)
14954 IFS=" "" $as_nl"
14956 # Find who we are. Look in the path if we contain no directory separator.
14957 as_myself=
14958 case $0 in #((
14959 *[\\/]* ) as_myself=$0 ;;
14960 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14961 for as_dir in $PATH
14963 IFS=$as_save_IFS
14964 test -z "$as_dir" && as_dir=.
14965 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
14966 done
14967 IFS=$as_save_IFS
14970 esac
14971 # We did not find ourselves, most probably we were run as `sh COMMAND'
14972 # in which case we are not to be found in the path.
14973 if test "x$as_myself" = x; then
14974 as_myself=$0
14976 if test ! -f "$as_myself"; then
14977 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
14978 exit 1
14981 # Unset variables that we do not need and which cause bugs (e.g. in
14982 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
14983 # suppresses any "Segmentation fault" message there. '((' could
14984 # trigger a bug in pdksh 5.2.14.
14985 for as_var in BASH_ENV ENV MAIL MAILPATH
14986 do eval test x\${$as_var+set} = xset \
14987 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
14988 done
14989 PS1='$ '
14990 PS2='> '
14991 PS4='+ '
14993 # NLS nuisances.
14994 LC_ALL=C
14995 export LC_ALL
14996 LANGUAGE=C
14997 export LANGUAGE
14999 # CDPATH.
15000 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
15003 # as_fn_error STATUS ERROR [LINENO LOG_FD]
15004 # ----------------------------------------
15005 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
15006 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
15007 # script with STATUS, using 1 if that was 0.
15008 as_fn_error ()
15010 as_status=$1; test $as_status -eq 0 && as_status=1
15011 if test "$4"; then
15012 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
15013 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
15015 $as_echo "$as_me: error: $2" >&2
15016 as_fn_exit $as_status
15017 } # as_fn_error
15020 # as_fn_set_status STATUS
15021 # -----------------------
15022 # Set $? to STATUS, without forking.
15023 as_fn_set_status ()
15025 return $1
15026 } # as_fn_set_status
15028 # as_fn_exit STATUS
15029 # -----------------
15030 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
15031 as_fn_exit ()
15033 set +e
15034 as_fn_set_status $1
15035 exit $1
15036 } # as_fn_exit
15038 # as_fn_unset VAR
15039 # ---------------
15040 # Portably unset VAR.
15041 as_fn_unset ()
15043 { eval $1=; unset $1;}
15045 as_unset=as_fn_unset
15046 # as_fn_append VAR VALUE
15047 # ----------------------
15048 # Append the text in VALUE to the end of the definition contained in VAR. Take
15049 # advantage of any shell optimizations that allow amortized linear growth over
15050 # repeated appends, instead of the typical quadratic growth present in naive
15051 # implementations.
15052 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
15053 eval 'as_fn_append ()
15055 eval $1+=\$2
15057 else
15058 as_fn_append ()
15060 eval $1=\$$1\$2
15062 fi # as_fn_append
15064 # as_fn_arith ARG...
15065 # ------------------
15066 # Perform arithmetic evaluation on the ARGs, and store the result in the
15067 # global $as_val. Take advantage of shells that can avoid forks. The arguments
15068 # must be portable across $(()) and expr.
15069 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
15070 eval 'as_fn_arith ()
15072 as_val=$(( $* ))
15074 else
15075 as_fn_arith ()
15077 as_val=`expr "$@" || test $? -eq 1`
15079 fi # as_fn_arith
15082 if expr a : '\(a\)' >/dev/null 2>&1 &&
15083 test "X`expr 00001 : '.*\(...\)'`" = X001; then
15084 as_expr=expr
15085 else
15086 as_expr=false
15089 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
15090 as_basename=basename
15091 else
15092 as_basename=false
15095 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
15096 as_dirname=dirname
15097 else
15098 as_dirname=false
15101 as_me=`$as_basename -- "$0" ||
15102 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
15103 X"$0" : 'X\(//\)$' \| \
15104 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
15105 $as_echo X/"$0" |
15106 sed '/^.*\/\([^/][^/]*\)\/*$/{
15107 s//\1/
15110 /^X\/\(\/\/\)$/{
15111 s//\1/
15114 /^X\/\(\/\).*/{
15115 s//\1/
15118 s/.*/./; q'`
15120 # Avoid depending upon Character Ranges.
15121 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
15122 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
15123 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
15124 as_cr_digits='0123456789'
15125 as_cr_alnum=$as_cr_Letters$as_cr_digits
15127 ECHO_C= ECHO_N= ECHO_T=
15128 case `echo -n x` in #(((((
15129 -n*)
15130 case `echo 'xy\c'` in
15131 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
15132 xy) ECHO_C='\c';;
15133 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
15134 ECHO_T=' ';;
15135 esac;;
15137 ECHO_N='-n';;
15138 esac
15140 rm -f conf$$ conf$$.exe conf$$.file
15141 if test -d conf$$.dir; then
15142 rm -f conf$$.dir/conf$$.file
15143 else
15144 rm -f conf$$.dir
15145 mkdir conf$$.dir 2>/dev/null
15147 if (echo >conf$$.file) 2>/dev/null; then
15148 if ln -s conf$$.file conf$$ 2>/dev/null; then
15149 as_ln_s='ln -s'
15150 # ... but there are two gotchas:
15151 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
15152 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
15153 # In both cases, we have to default to `cp -pR'.
15154 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
15155 as_ln_s='cp -pR'
15156 elif ln conf$$.file conf$$ 2>/dev/null; then
15157 as_ln_s=ln
15158 else
15159 as_ln_s='cp -pR'
15161 else
15162 as_ln_s='cp -pR'
15164 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
15165 rmdir conf$$.dir 2>/dev/null
15168 # as_fn_mkdir_p
15169 # -------------
15170 # Create "$as_dir" as a directory, including parents if necessary.
15171 as_fn_mkdir_p ()
15174 case $as_dir in #(
15175 -*) as_dir=./$as_dir;;
15176 esac
15177 test -d "$as_dir" || eval $as_mkdir_p || {
15178 as_dirs=
15179 while :; do
15180 case $as_dir in #(
15181 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
15182 *) as_qdir=$as_dir;;
15183 esac
15184 as_dirs="'$as_qdir' $as_dirs"
15185 as_dir=`$as_dirname -- "$as_dir" ||
15186 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
15187 X"$as_dir" : 'X\(//\)[^/]' \| \
15188 X"$as_dir" : 'X\(//\)$' \| \
15189 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
15190 $as_echo X"$as_dir" |
15191 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
15192 s//\1/
15195 /^X\(\/\/\)[^/].*/{
15196 s//\1/
15199 /^X\(\/\/\)$/{
15200 s//\1/
15203 /^X\(\/\).*/{
15204 s//\1/
15207 s/.*/./; q'`
15208 test -d "$as_dir" && break
15209 done
15210 test -z "$as_dirs" || eval "mkdir $as_dirs"
15211 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
15214 } # as_fn_mkdir_p
15215 if mkdir -p . 2>/dev/null; then
15216 as_mkdir_p='mkdir -p "$as_dir"'
15217 else
15218 test -d ./-p && rmdir ./-p
15219 as_mkdir_p=false
15223 # as_fn_executable_p FILE
15224 # -----------------------
15225 # Test if FILE is an executable regular file.
15226 as_fn_executable_p ()
15228 test -f "$1" && test -x "$1"
15229 } # as_fn_executable_p
15230 as_test_x='test -x'
15231 as_executable_p=as_fn_executable_p
15233 # Sed expression to map a string onto a valid CPP name.
15234 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
15236 # Sed expression to map a string onto a valid variable name.
15237 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
15240 exec 6>&1
15241 ## ----------------------------------- ##
15242 ## Main body of $CONFIG_STATUS script. ##
15243 ## ----------------------------------- ##
15244 _ASEOF
15245 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
15247 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15248 # Save the log message, to keep $0 and so on meaningful, and to
15249 # report actual input values of CONFIG_FILES etc. instead of their
15250 # values after options handling.
15251 ac_log="
15252 This file was extended by $as_me, which was
15253 generated by GNU Autoconf 2.69. Invocation command line was
15255 CONFIG_FILES = $CONFIG_FILES
15256 CONFIG_HEADERS = $CONFIG_HEADERS
15257 CONFIG_LINKS = $CONFIG_LINKS
15258 CONFIG_COMMANDS = $CONFIG_COMMANDS
15259 $ $0 $@
15261 on `(hostname || uname -n) 2>/dev/null | sed 1q`
15264 _ACEOF
15266 case $ac_config_files in *"
15267 "*) set x $ac_config_files; shift; ac_config_files=$*;;
15268 esac
15270 case $ac_config_headers in *"
15271 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
15272 esac
15275 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15276 # Files that config.status was made for.
15277 config_files="$ac_config_files"
15278 config_headers="$ac_config_headers"
15279 config_commands="$ac_config_commands"
15281 _ACEOF
15283 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15284 ac_cs_usage="\
15285 \`$as_me' instantiates files and other configuration actions
15286 from templates according to the current configuration. Unless the files
15287 and actions are specified as TAGs, all are instantiated by default.
15289 Usage: $0 [OPTION]... [TAG]...
15291 -h, --help print this help, then exit
15292 -V, --version print version number and configuration settings, then exit
15293 --config print configuration, then exit
15294 -q, --quiet, --silent
15295 do not print progress messages
15296 -d, --debug don't remove temporary files
15297 --recheck update $as_me by reconfiguring in the same conditions
15298 --file=FILE[:TEMPLATE]
15299 instantiate the configuration file FILE
15300 --header=FILE[:TEMPLATE]
15301 instantiate the configuration header FILE
15303 Configuration files:
15304 $config_files
15306 Configuration headers:
15307 $config_headers
15309 Configuration commands:
15310 $config_commands
15312 Report bugs to the package provider."
15314 _ACEOF
15315 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15316 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
15317 ac_cs_version="\\
15318 config.status
15319 configured by $0, generated by GNU Autoconf 2.69,
15320 with options \\"\$ac_cs_config\\"
15322 Copyright (C) 2012 Free Software Foundation, Inc.
15323 This config.status script is free software; the Free Software Foundation
15324 gives unlimited permission to copy, distribute and modify it."
15326 ac_pwd='$ac_pwd'
15327 srcdir='$srcdir'
15328 INSTALL='$INSTALL'
15329 test -n "\$AWK" || AWK=awk
15330 _ACEOF
15332 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15333 # The default lists apply if the user does not specify any file.
15334 ac_need_defaults=:
15335 while test $# != 0
15337 case $1 in
15338 --*=?*)
15339 ac_option=`expr "X$1" : 'X\([^=]*\)='`
15340 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
15341 ac_shift=:
15343 --*=)
15344 ac_option=`expr "X$1" : 'X\([^=]*\)='`
15345 ac_optarg=
15346 ac_shift=:
15349 ac_option=$1
15350 ac_optarg=$2
15351 ac_shift=shift
15353 esac
15355 case $ac_option in
15356 # Handling of the options.
15357 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
15358 ac_cs_recheck=: ;;
15359 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
15360 $as_echo "$ac_cs_version"; exit ;;
15361 --config | --confi | --conf | --con | --co | --c )
15362 $as_echo "$ac_cs_config"; exit ;;
15363 --debug | --debu | --deb | --de | --d | -d )
15364 debug=: ;;
15365 --file | --fil | --fi | --f )
15366 $ac_shift
15367 case $ac_optarg in
15368 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
15369 '') as_fn_error $? "missing file argument" ;;
15370 esac
15371 as_fn_append CONFIG_FILES " '$ac_optarg'"
15372 ac_need_defaults=false;;
15373 --header | --heade | --head | --hea )
15374 $ac_shift
15375 case $ac_optarg in
15376 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
15377 esac
15378 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
15379 ac_need_defaults=false;;
15380 --he | --h)
15381 # Conflict between --help and --header
15382 as_fn_error $? "ambiguous option: \`$1'
15383 Try \`$0 --help' for more information.";;
15384 --help | --hel | -h )
15385 $as_echo "$ac_cs_usage"; exit ;;
15386 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
15387 | -silent | --silent | --silen | --sile | --sil | --si | --s)
15388 ac_cs_silent=: ;;
15390 # This is an error.
15391 -*) as_fn_error $? "unrecognized option: \`$1'
15392 Try \`$0 --help' for more information." ;;
15394 *) as_fn_append ac_config_targets " $1"
15395 ac_need_defaults=false ;;
15397 esac
15398 shift
15399 done
15401 ac_configure_extra_args=
15403 if $ac_cs_silent; then
15404 exec 6>/dev/null
15405 ac_configure_extra_args="$ac_configure_extra_args --silent"
15408 _ACEOF
15409 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15410 if \$ac_cs_recheck; then
15411 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
15412 shift
15413 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
15414 CONFIG_SHELL='$SHELL'
15415 export CONFIG_SHELL
15416 exec "\$@"
15419 _ACEOF
15420 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15421 exec 5>>config.log
15423 echo
15424 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
15425 ## Running $as_me. ##
15426 _ASBOX
15427 $as_echo "$ac_log"
15428 } >&5
15430 _ACEOF
15431 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15433 # INIT-COMMANDS
15435 ac_aux_dir=$ac_aux_dir DEPDIR=$DEPDIR
15436 # Capture the value of obsolete ALL_LINGUAS because we need it to compute
15437 # POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES, CATALOGS. But hide it
15438 # from automake.
15439 eval 'OBSOLETE_ALL_LINGUAS''="$ALL_LINGUAS"'
15440 # Capture the value of LINGUAS because we need it to compute CATALOGS.
15441 LINGUAS="${LINGUAS-%UNSET%}"
15443 ac_aux_dir=$ac_aux_dir DEPDIR=$DEPDIR CONFIG_SRC_SUBDIR="$CONFIG_SRC_SUBDIR"
15445 _ACEOF
15447 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15449 # Handling of arguments.
15450 for ac_config_target in $ac_config_targets
15452 case $ac_config_target in
15453 "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h:config.in" ;;
15454 "depdir") CONFIG_COMMANDS="$CONFIG_COMMANDS depdir" ;;
15455 "default-1") CONFIG_COMMANDS="$CONFIG_COMMANDS default-1" ;;
15456 "gdbdepdir") CONFIG_COMMANDS="$CONFIG_COMMANDS gdbdepdir" ;;
15457 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
15459 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
15460 esac
15461 done
15464 # If the user did not use the arguments to specify the items to instantiate,
15465 # then the envvar interface is used. Set only those that are not.
15466 # We use the long form for the default assignment because of an extremely
15467 # bizarre bug on SunOS 4.1.3.
15468 if $ac_need_defaults; then
15469 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
15470 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
15471 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
15474 # Have a temporary directory for convenience. Make it in the build tree
15475 # simply because there is no reason against having it here, and in addition,
15476 # creating and moving files from /tmp can sometimes cause problems.
15477 # Hook for its removal unless debugging.
15478 # Note that there is a small window in which the directory will not be cleaned:
15479 # after its creation but before its name has been assigned to `$tmp'.
15480 $debug ||
15482 tmp= ac_tmp=
15483 trap 'exit_status=$?
15484 : "${ac_tmp:=$tmp}"
15485 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
15487 trap 'as_fn_exit 1' 1 2 13 15
15489 # Create a (secure) tmp directory for tmp files.
15492 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
15493 test -d "$tmp"
15494 } ||
15496 tmp=./conf$$-$RANDOM
15497 (umask 077 && mkdir "$tmp")
15498 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
15499 ac_tmp=$tmp
15501 # Set up the scripts for CONFIG_FILES section.
15502 # No need to generate them if there are no CONFIG_FILES.
15503 # This happens for instance with `./config.status config.h'.
15504 if test -n "$CONFIG_FILES"; then
15507 ac_cr=`echo X | tr X '\015'`
15508 # On cygwin, bash can eat \r inside `` if the user requested igncr.
15509 # But we know of no other shell where ac_cr would be empty at this
15510 # point, so we can use a bashism as a fallback.
15511 if test "x$ac_cr" = x; then
15512 eval ac_cr=\$\'\\r\'
15514 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
15515 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
15516 ac_cs_awk_cr='\\r'
15517 else
15518 ac_cs_awk_cr=$ac_cr
15521 echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
15522 _ACEOF
15526 echo "cat >conf$$subs.awk <<_ACEOF" &&
15527 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
15528 echo "_ACEOF"
15529 } >conf$$subs.sh ||
15530 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
15531 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
15532 ac_delim='%!_!# '
15533 for ac_last_try in false false false false false :; do
15534 . ./conf$$subs.sh ||
15535 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
15537 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
15538 if test $ac_delim_n = $ac_delim_num; then
15539 break
15540 elif $ac_last_try; then
15541 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
15542 else
15543 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
15545 done
15546 rm -f conf$$subs.sh
15548 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15549 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
15550 _ACEOF
15551 sed -n '
15553 s/^/S["/; s/!.*/"]=/
15556 s/^[^!]*!//
15557 :repl
15558 t repl
15559 s/'"$ac_delim"'$//
15560 t delim
15563 s/\(.\{148\}\)..*/\1/
15564 t more1
15565 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
15568 b repl
15569 :more1
15570 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
15573 s/.\{148\}//
15574 t nl
15575 :delim
15577 s/\(.\{148\}\)..*/\1/
15578 t more2
15579 s/["\\]/\\&/g; s/^/"/; s/$/"/
15582 :more2
15583 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
15586 s/.\{148\}//
15587 t delim
15588 ' <conf$$subs.awk | sed '
15589 /^[^""]/{
15591 s/\n//
15593 ' >>$CONFIG_STATUS || ac_write_fail=1
15594 rm -f conf$$subs.awk
15595 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15596 _ACAWK
15597 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
15598 for (key in S) S_is_set[key] = 1
15599 FS = "\a"
15603 line = $ 0
15604 nfields = split(line, field, "@")
15605 substed = 0
15606 len = length(field[1])
15607 for (i = 2; i < nfields; i++) {
15608 key = field[i]
15609 keylen = length(key)
15610 if (S_is_set[key]) {
15611 value = S[key]
15612 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
15613 len += length(value) + length(field[++i])
15614 substed = 1
15615 } else
15616 len += 1 + keylen
15619 print line
15622 _ACAWK
15623 _ACEOF
15624 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15625 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
15626 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
15627 else
15629 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
15630 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
15631 _ACEOF
15633 # VPATH may cause trouble with some makes, so we remove sole $(srcdir),
15634 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
15635 # trailing colons and then remove the whole line if VPATH becomes empty
15636 # (actually we leave an empty line to preserve line numbers).
15637 if test "x$srcdir" = x.; then
15638 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
15640 s///
15641 s/^/:/
15642 s/[ ]*$/:/
15643 s/:\$(srcdir):/:/g
15644 s/:\${srcdir}:/:/g
15645 s/:@srcdir@:/:/g
15646 s/^:*//
15647 s/:*$//
15649 s/\(=[ ]*\).*/\1/
15651 s/\n//
15652 s/^[^=]*=[ ]*$//
15656 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15657 fi # test -n "$CONFIG_FILES"
15659 # Set up the scripts for CONFIG_HEADERS section.
15660 # No need to generate them if there are no CONFIG_HEADERS.
15661 # This happens for instance with `./config.status Makefile'.
15662 if test -n "$CONFIG_HEADERS"; then
15663 cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
15664 BEGIN {
15665 _ACEOF
15667 # Transform confdefs.h into an awk script `defines.awk', embedded as
15668 # here-document in config.status, that substitutes the proper values into
15669 # config.h.in to produce config.h.
15671 # Create a delimiter string that does not exist in confdefs.h, to ease
15672 # handling of long lines.
15673 ac_delim='%!_!# '
15674 for ac_last_try in false false :; do
15675 ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
15676 if test -z "$ac_tt"; then
15677 break
15678 elif $ac_last_try; then
15679 as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
15680 else
15681 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
15683 done
15685 # For the awk script, D is an array of macro values keyed by name,
15686 # likewise P contains macro parameters if any. Preserve backslash
15687 # newline sequences.
15689 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
15690 sed -n '
15691 s/.\{148\}/&'"$ac_delim"'/g
15692 t rset
15693 :rset
15694 s/^[ ]*#[ ]*define[ ][ ]*/ /
15695 t def
15697 :def
15698 s/\\$//
15699 t bsnl
15700 s/["\\]/\\&/g
15701 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
15702 D["\1"]=" \3"/p
15703 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
15705 :bsnl
15706 s/["\\]/\\&/g
15707 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
15708 D["\1"]=" \3\\\\\\n"\\/p
15709 t cont
15710 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
15711 t cont
15713 :cont
15715 s/.\{148\}/&'"$ac_delim"'/g
15716 t clear
15717 :clear
15718 s/\\$//
15719 t bsnlc
15720 s/["\\]/\\&/g; s/^/"/; s/$/"/p
15722 :bsnlc
15723 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
15724 b cont
15725 ' <confdefs.h | sed '
15726 s/'"$ac_delim"'/"\\\
15727 "/g' >>$CONFIG_STATUS || ac_write_fail=1
15729 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15730 for (key in D) D_is_set[key] = 1
15731 FS = "\a"
15733 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
15734 line = \$ 0
15735 split(line, arg, " ")
15736 if (arg[1] == "#") {
15737 defundef = arg[2]
15738 mac1 = arg[3]
15739 } else {
15740 defundef = substr(arg[1], 2)
15741 mac1 = arg[2]
15743 split(mac1, mac2, "(") #)
15744 macro = mac2[1]
15745 prefix = substr(line, 1, index(line, defundef) - 1)
15746 if (D_is_set[macro]) {
15747 # Preserve the white space surrounding the "#".
15748 print prefix "define", macro P[macro] D[macro]
15749 next
15750 } else {
15751 # Replace #undef with comments. This is necessary, for example,
15752 # in the case of _POSIX_SOURCE, which is predefined and required
15753 # on some systems where configure will not decide to define it.
15754 if (defundef == "undef") {
15755 print "/*", prefix defundef, macro, "*/"
15756 next
15760 { print }
15761 _ACAWK
15762 _ACEOF
15763 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15764 as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
15765 fi # test -n "$CONFIG_HEADERS"
15768 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
15769 shift
15770 for ac_tag
15772 case $ac_tag in
15773 :[FHLC]) ac_mode=$ac_tag; continue;;
15774 esac
15775 case $ac_mode$ac_tag in
15776 :[FHL]*:*);;
15777 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
15778 :[FH]-) ac_tag=-:-;;
15779 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
15780 esac
15781 ac_save_IFS=$IFS
15782 IFS=:
15783 set x $ac_tag
15784 IFS=$ac_save_IFS
15785 shift
15786 ac_file=$1
15787 shift
15789 case $ac_mode in
15790 :L) ac_source=$1;;
15791 :[FH])
15792 ac_file_inputs=
15793 for ac_f
15795 case $ac_f in
15796 -) ac_f="$ac_tmp/stdin";;
15797 *) # Look for the file first in the build tree, then in the source tree
15798 # (if the path is not absolute). The absolute path cannot be DOS-style,
15799 # because $ac_f cannot contain `:'.
15800 test -f "$ac_f" ||
15801 case $ac_f in
15802 [\\/$]*) false;;
15803 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
15804 esac ||
15805 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
15806 esac
15807 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
15808 as_fn_append ac_file_inputs " '$ac_f'"
15809 done
15811 # Let's still pretend it is `configure' which instantiates (i.e., don't
15812 # use $as_me), people would be surprised to read:
15813 # /* config.h. Generated by config.status. */
15814 configure_input='Generated from '`
15815 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
15816 `' by configure.'
15817 if test x"$ac_file" != x-; then
15818 configure_input="$ac_file. $configure_input"
15819 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
15820 $as_echo "$as_me: creating $ac_file" >&6;}
15822 # Neutralize special characters interpreted by sed in replacement strings.
15823 case $configure_input in #(
15824 *\&* | *\|* | *\\* )
15825 ac_sed_conf_input=`$as_echo "$configure_input" |
15826 sed 's/[\\\\&|]/\\\\&/g'`;; #(
15827 *) ac_sed_conf_input=$configure_input;;
15828 esac
15830 case $ac_tag in
15831 *:-:* | *:-) cat >"$ac_tmp/stdin" \
15832 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
15833 esac
15835 esac
15837 ac_dir=`$as_dirname -- "$ac_file" ||
15838 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
15839 X"$ac_file" : 'X\(//\)[^/]' \| \
15840 X"$ac_file" : 'X\(//\)$' \| \
15841 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
15842 $as_echo X"$ac_file" |
15843 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
15844 s//\1/
15847 /^X\(\/\/\)[^/].*/{
15848 s//\1/
15851 /^X\(\/\/\)$/{
15852 s//\1/
15855 /^X\(\/\).*/{
15856 s//\1/
15859 s/.*/./; q'`
15860 as_dir="$ac_dir"; as_fn_mkdir_p
15861 ac_builddir=.
15863 case "$ac_dir" in
15864 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
15866 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
15867 # A ".." for each directory in $ac_dir_suffix.
15868 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
15869 case $ac_top_builddir_sub in
15870 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
15871 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
15872 esac ;;
15873 esac
15874 ac_abs_top_builddir=$ac_pwd
15875 ac_abs_builddir=$ac_pwd$ac_dir_suffix
15876 # for backward compatibility:
15877 ac_top_builddir=$ac_top_build_prefix
15879 case $srcdir in
15880 .) # We are building in place.
15881 ac_srcdir=.
15882 ac_top_srcdir=$ac_top_builddir_sub
15883 ac_abs_top_srcdir=$ac_pwd ;;
15884 [\\/]* | ?:[\\/]* ) # Absolute name.
15885 ac_srcdir=$srcdir$ac_dir_suffix;
15886 ac_top_srcdir=$srcdir
15887 ac_abs_top_srcdir=$srcdir ;;
15888 *) # Relative name.
15889 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
15890 ac_top_srcdir=$ac_top_build_prefix$srcdir
15891 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
15892 esac
15893 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
15896 case $ac_mode in
15899 # CONFIG_FILE
15902 case $INSTALL in
15903 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
15904 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
15905 esac
15906 _ACEOF
15908 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15909 # If the template does not know about datarootdir, expand it.
15910 # FIXME: This hack should be removed a few years after 2.60.
15911 ac_datarootdir_hack=; ac_datarootdir_seen=
15912 ac_sed_dataroot='
15913 /datarootdir/ {
15917 /@datadir@/p
15918 /@docdir@/p
15919 /@infodir@/p
15920 /@localedir@/p
15921 /@mandir@/p'
15922 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
15923 *datarootdir*) ac_datarootdir_seen=yes;;
15924 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
15925 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
15926 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
15927 _ACEOF
15928 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15929 ac_datarootdir_hack='
15930 s&@datadir@&$datadir&g
15931 s&@docdir@&$docdir&g
15932 s&@infodir@&$infodir&g
15933 s&@localedir@&$localedir&g
15934 s&@mandir@&$mandir&g
15935 s&\\\${datarootdir}&$datarootdir&g' ;;
15936 esac
15937 _ACEOF
15939 # Neutralize VPATH when `$srcdir' = `.'.
15940 # Shell code in configure.ac might set extrasub.
15941 # FIXME: do we really want to maintain this feature?
15942 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15943 ac_sed_extra="$ac_vpsub
15944 $extrasub
15945 _ACEOF
15946 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15948 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
15949 s|@configure_input@|$ac_sed_conf_input|;t t
15950 s&@top_builddir@&$ac_top_builddir_sub&;t t
15951 s&@top_build_prefix@&$ac_top_build_prefix&;t t
15952 s&@srcdir@&$ac_srcdir&;t t
15953 s&@abs_srcdir@&$ac_abs_srcdir&;t t
15954 s&@top_srcdir@&$ac_top_srcdir&;t t
15955 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
15956 s&@builddir@&$ac_builddir&;t t
15957 s&@abs_builddir@&$ac_abs_builddir&;t t
15958 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
15959 s&@INSTALL@&$ac_INSTALL&;t t
15960 $ac_datarootdir_hack
15962 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
15963 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
15965 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
15966 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
15967 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
15968 "$ac_tmp/out"`; test -z "$ac_out"; } &&
15969 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
15970 which seems to be undefined. Please make sure it is defined" >&5
15971 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
15972 which seems to be undefined. Please make sure it is defined" >&2;}
15974 rm -f "$ac_tmp/stdin"
15975 case $ac_file in
15976 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
15977 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
15978 esac \
15979 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
15983 # CONFIG_HEADER
15985 if test x"$ac_file" != x-; then
15987 $as_echo "/* $configure_input */" \
15988 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
15989 } >"$ac_tmp/config.h" \
15990 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
15991 if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
15992 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
15993 $as_echo "$as_me: $ac_file is unchanged" >&6;}
15994 else
15995 rm -f "$ac_file"
15996 mv "$ac_tmp/config.h" "$ac_file" \
15997 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
15999 else
16000 $as_echo "/* $configure_input */" \
16001 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
16002 || as_fn_error $? "could not create -" "$LINENO" 5
16006 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
16007 $as_echo "$as_me: executing $ac_file commands" >&6;}
16009 esac
16012 case $ac_file$ac_mode in
16013 "config.h":H) echo > stamp-h ;;
16014 "depdir":C) $SHELL $ac_aux_dir/mkinstalldirs $DEPDIR ;;
16015 "default-1":C)
16016 for ac_file in $CONFIG_FILES; do
16017 # Support "outfile[:infile[:infile...]]"
16018 case "$ac_file" in
16019 *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
16020 esac
16021 # PO directories have a Makefile.in generated from Makefile.in.in.
16022 case "$ac_file" in */Makefile.in)
16023 # Adjust a relative srcdir.
16024 ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
16025 ac_dir_suffix=/`echo "$ac_dir"|sed 's%^\./%%'`
16026 ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
16027 # In autoconf-2.13 it is called $ac_given_srcdir.
16028 # In autoconf-2.50 it is called $srcdir.
16029 test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
16030 case "$ac_given_srcdir" in
16031 .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
16032 /*) top_srcdir="$ac_given_srcdir" ;;
16033 *) top_srcdir="$ac_dots$ac_given_srcdir" ;;
16034 esac
16035 if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
16036 rm -f "$ac_dir/POTFILES"
16037 test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES"
16038 cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES"
16039 POMAKEFILEDEPS="POTFILES.in"
16040 # ALL_LINGUAS, POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES depend
16041 # on $ac_dir but don't depend on user-specified configuration
16042 # parameters.
16043 if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
16044 # The LINGUAS file contains the set of available languages.
16045 if test -n "$OBSOLETE_ALL_LINGUAS"; then
16046 test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.ac is obsolete" || echo "setting ALL_LINGUAS in configure.ac is obsolete"
16048 ALL_LINGUAS_=`sed -e "/^#/d" "$ac_given_srcdir/$ac_dir/LINGUAS"`
16049 # Hide the ALL_LINGUAS assigment from automake.
16050 eval 'ALL_LINGUAS''=$ALL_LINGUAS_'
16051 POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS"
16052 else
16053 # The set of available languages was given in configure.ac.
16054 eval 'ALL_LINGUAS''=$OBSOLETE_ALL_LINGUAS'
16056 case "$ac_given_srcdir" in
16057 .) srcdirpre= ;;
16058 *) srcdirpre='$(srcdir)/' ;;
16059 esac
16060 POFILES=
16061 GMOFILES=
16062 UPDATEPOFILES=
16063 DUMMYPOFILES=
16064 for lang in $ALL_LINGUAS; do
16065 POFILES="$POFILES $srcdirpre$lang.po"
16066 GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
16067 UPDATEPOFILES="$UPDATEPOFILES $lang.po-update"
16068 DUMMYPOFILES="$DUMMYPOFILES $lang.nop"
16069 done
16070 # CATALOGS depends on both $ac_dir and the user's LINGUAS
16071 # environment variable.
16072 INST_LINGUAS=
16073 if test -n "$ALL_LINGUAS"; then
16074 for presentlang in $ALL_LINGUAS; do
16075 useit=no
16076 if test "%UNSET%" != "$LINGUAS"; then
16077 desiredlanguages="$LINGUAS"
16078 else
16079 desiredlanguages="$ALL_LINGUAS"
16081 for desiredlang in $desiredlanguages; do
16082 # Use the presentlang catalog if desiredlang is
16083 # a. equal to presentlang, or
16084 # b. a variant of presentlang (because in this case,
16085 # presentlang can be used as a fallback for messages
16086 # which are not translated in the desiredlang catalog).
16087 case "$desiredlang" in
16088 "$presentlang"*) useit=yes;;
16089 esac
16090 done
16091 if test $useit = yes; then
16092 INST_LINGUAS="$INST_LINGUAS $presentlang"
16094 done
16096 CATALOGS=
16097 if test -n "$INST_LINGUAS"; then
16098 for lang in $INST_LINGUAS; do
16099 CATALOGS="$CATALOGS $lang.gmo"
16100 done
16102 test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile"
16103 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"
16104 for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do
16105 if test -f "$f"; then
16106 case "$f" in
16107 *.orig | *.bak | *~) ;;
16108 *) cat "$f" >> "$ac_dir/Makefile" ;;
16109 esac
16111 done
16114 esac
16115 done ;;
16116 "gdbdepdir":C)
16117 for subdir in ${CONFIG_SRC_SUBDIR}
16119 $SHELL $ac_aux_dir/mkinstalldirs $subdir/$DEPDIR
16120 done ;;
16122 esac
16123 done # for ac_tag
16126 as_fn_exit 0
16127 _ACEOF
16128 ac_clean_files=$ac_clean_files_save
16130 test $ac_write_fail = 0 ||
16131 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
16134 # configure is writing to config.log, and then calls config.status.
16135 # config.status does its own redirection, appending to config.log.
16136 # Unfortunately, on DOS this fails, as config.log is still kept open
16137 # by configure, so config.status won't be able to write to it; its
16138 # output is simply discarded. So we exec the FD to /dev/null,
16139 # effectively closing config.log, so it can be properly (re)opened and
16140 # appended to by config.status. When coming back to configure, we
16141 # need to make the FD available again.
16142 if test "$no_create" != yes; then
16143 ac_cs_success=:
16144 ac_config_status_args=
16145 test "$silent" = yes &&
16146 ac_config_status_args="$ac_config_status_args --quiet"
16147 exec 5>/dev/null
16148 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
16149 exec 5>>config.log
16150 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
16151 # would make configure fail if this is the last instruction.
16152 $ac_cs_success || as_fn_exit 1
16154 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
16155 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
16156 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}