*** empty log message ***
[deliverable/binutils-gdb.git] / gdb / configure
CommitLineData
c906108c 1#! /bin/sh
c906108c 2# Guess values for system-dependent variables and create Makefiles.
81ecdfbb
RW
3# Generated by GNU Autoconf 2.64.
4#
5# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
6# 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software
7# Foundation, Inc.
c906108c
SS
8#
9# This configure script is free software; the Free Software Foundation
10# gives unlimited permission to copy, distribute and modify it.
81ecdfbb
RW
11## -------------------- ##
12## M4sh Initialization. ##
13## -------------------- ##
bec39cab 14
81ecdfbb
RW
15# Be more Bourne compatible
16DUALCASE=1; export DUALCASE # for MKS sh
17if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
bec39cab
AC
18 emulate sh
19 NULLCMD=:
81ecdfbb 20 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
bec39cab
AC
21 # is contrary to our usage. Disable this feature.
22 alias -g '${1+"$@"}'='"$@"'
81ecdfbb
RW
23 setopt NO_GLOB_SUBST
24else
25 case `(set -o) 2>/dev/null` in #(
26 *posix*) :
27 set -o posix ;; #(
28 *) :
29 ;;
30esac
bec39cab 31fi
bec39cab 32
81ecdfbb
RW
33
34as_nl='
35'
36export as_nl
37# Printing a long string crashes Solaris 7 /usr/bin/printf.
38as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
39as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
40as_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.
43if 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 --'
47elif (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'
50else
51 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
52 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
53 as_echo_n='/usr/ucb/echo -n'
54 else
55 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
56 as_echo_n_body='eval
57 arg=$1;
58 case $arg in #(
59 *"$as_nl"*)
60 expr "X$arg" : "X\\(.*\\)$as_nl";
61 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
62 esac;
63 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
64 '
65 export as_echo_n_body
66 as_echo_n='sh -c $as_echo_n_body as_echo'
67 fi
68 export as_echo_body
69 as_echo='sh -c $as_echo_body as_echo'
70fi
71
72# The user is always right.
73if test "${PATH_SEPARATOR+set}" != set; then
74 PATH_SEPARATOR=:
75 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
76 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
77 PATH_SEPARATOR=';'
78 }
bec39cab
AC
79fi
80
81
81ecdfbb
RW
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.)
87IFS=" "" $as_nl"
88
89# Find who we are. Look in the path if we contain no directory separator.
90case $0 in #((
91 *[\\/]* ) as_myself=$0 ;;
92 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
93for as_dir in $PATH
94do
95 IFS=$as_save_IFS
96 test -z "$as_dir" && as_dir=.
97 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
98 done
99IFS=$as_save_IFS
100
101 ;;
102esac
103# We did not find ourselves, most probably we were run as `sh COMMAND'
104# in which case we are not to be found in the path.
105if test "x$as_myself" = x; then
106 as_myself=$0
107fi
108if test ! -f "$as_myself"; then
109 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
110 exit 1
111fi
112
113# Unset variables that we do not need and which cause bugs (e.g. in
114# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
115# suppresses any "Segmentation fault" message there. '((' could
116# trigger a bug in pdksh 5.2.14.
117for as_var in BASH_ENV ENV MAIL MAILPATH
118do eval test x\${$as_var+set} = xset \
119 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
120done
bec39cab
AC
121PS1='$ '
122PS2='> '
123PS4='+ '
124
125# NLS nuisances.
81ecdfbb
RW
126LC_ALL=C
127export LC_ALL
128LANGUAGE=C
129export LANGUAGE
130
131# CDPATH.
132(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
133
134if test "x$CONFIG_SHELL" = x; then
135 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
136 emulate sh
137 NULLCMD=:
138 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
139 # is contrary to our usage. Disable this feature.
140 alias -g '\${1+\"\$@\"}'='\"\$@\"'
141 setopt NO_GLOB_SUBST
142else
143 case \`(set -o) 2>/dev/null\` in #(
144 *posix*) :
145 set -o posix ;; #(
146 *) :
147 ;;
148esac
149fi
150"
151 as_required="as_fn_return () { (exit \$1); }
152as_fn_success () { as_fn_return 0; }
153as_fn_failure () { as_fn_return 1; }
154as_fn_ret_success () { return 0; }
155as_fn_ret_failure () { return 1; }
156
157exitcode=0
158as_fn_success || { exitcode=1; echo as_fn_success failed.; }
159as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
160as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
161as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
162if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
163
164else
165 exitcode=1; echo positional parameters were not saved.
166fi
167test x\$exitcode = x0 || exit 1"
168 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
169 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
170 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
171 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
172test \$(( 1 + 1 )) = 2 || exit 1"
173 if (eval "$as_required") 2>/dev/null; then :
174 as_have_required=yes
175else
176 as_have_required=no
177fi
178 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
179
180else
181 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
182as_found=false
183for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
bec39cab 184do
81ecdfbb
RW
185 IFS=$as_save_IFS
186 test -z "$as_dir" && as_dir=.
187 as_found=:
188 case $as_dir in #(
189 /*)
190 for as_base in sh bash ksh sh5; do
191 # Try only shells that exist, to save several forks.
192 as_shell=$as_dir/$as_base
193 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
194 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
195 CONFIG_SHELL=$as_shell as_have_required=yes
196 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
197 break 2
198fi
199fi
200 done;;
201 esac
202 as_found=false
203done
204$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
205 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
206 CONFIG_SHELL=$SHELL as_have_required=yes
207fi; }
208IFS=$as_save_IFS
209
210
211 if test "x$CONFIG_SHELL" != x; then :
212 # We cannot yet assume a decent shell, so we have to provide a
213 # neutralization value for shells without unset; and this also
214 # works around shells that cannot unset nonexistent variables.
215 BASH_ENV=/dev/null
216 ENV=/dev/null
217 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
218 export CONFIG_SHELL
219 exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
220fi
221
222 if test x$as_have_required = xno; then :
223 $as_echo "$0: This script requires a shell more modern than all"
224 $as_echo "$0: the shells that I found on your system."
225 if test x${ZSH_VERSION+set} = xset ; then
226 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
227 $as_echo "$0: be upgraded to zsh 4.3.4 or later."
bec39cab 228 else
81ecdfbb
RW
229 $as_echo "$0: Please tell bug-autoconf@gnu.org about your system,
230$0: including any error possibly output before this
231$0: message. Then install a modern shell, or manually run
232$0: the script under such a shell if you do have one."
bec39cab 233 fi
81ecdfbb
RW
234 exit 1
235fi
236fi
237fi
238SHELL=${CONFIG_SHELL-/bin/sh}
239export SHELL
240# Unset more variables known to interfere with behavior of common tools.
241CLICOLOR_FORCE= GREP_OPTIONS=
242unset CLICOLOR_FORCE GREP_OPTIONS
243
244## --------------------- ##
245## M4sh Shell Functions. ##
246## --------------------- ##
247# as_fn_unset VAR
248# ---------------
249# Portably unset VAR.
250as_fn_unset ()
251{
252 { eval $1=; unset $1;}
253}
254as_unset=as_fn_unset
255
256# as_fn_set_status STATUS
257# -----------------------
258# Set $? to STATUS, without forking.
259as_fn_set_status ()
260{
261 return $1
262} # as_fn_set_status
bec39cab 263
81ecdfbb
RW
264# as_fn_exit STATUS
265# -----------------
266# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
267as_fn_exit ()
268{
269 set +e
270 as_fn_set_status $1
271 exit $1
272} # as_fn_exit
273
274# as_fn_mkdir_p
275# -------------
276# Create "$as_dir" as a directory, including parents if necessary.
277as_fn_mkdir_p ()
278{
279
280 case $as_dir in #(
281 -*) as_dir=./$as_dir;;
282 esac
283 test -d "$as_dir" || eval $as_mkdir_p || {
284 as_dirs=
285 while :; do
286 case $as_dir in #(
287 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
288 *) as_qdir=$as_dir;;
289 esac
290 as_dirs="'$as_qdir' $as_dirs"
291 as_dir=`$as_dirname -- "$as_dir" ||
292$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
293 X"$as_dir" : 'X\(//\)[^/]' \| \
294 X"$as_dir" : 'X\(//\)$' \| \
295 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
296$as_echo X"$as_dir" |
297 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
298 s//\1/
299 q
300 }
301 /^X\(\/\/\)[^/].*/{
302 s//\1/
303 q
304 }
305 /^X\(\/\/\)$/{
306 s//\1/
307 q
308 }
309 /^X\(\/\).*/{
310 s//\1/
311 q
312 }
313 s/.*/./; q'`
314 test -d "$as_dir" && break
315 done
316 test -z "$as_dirs" || eval "mkdir $as_dirs"
317 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
318
319
320} # as_fn_mkdir_p
321# as_fn_append VAR VALUE
322# ----------------------
323# Append the text in VALUE to the end of the definition contained in VAR. Take
324# advantage of any shell optimizations that allow amortized linear growth over
325# repeated appends, instead of the typical quadratic growth present in naive
326# implementations.
327if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
328 eval 'as_fn_append ()
329 {
330 eval $1+=\$2
331 }'
332else
333 as_fn_append ()
334 {
335 eval $1=\$$1\$2
336 }
337fi # as_fn_append
338
339# as_fn_arith ARG...
340# ------------------
341# Perform arithmetic evaluation on the ARGs, and store the result in the
342# global $as_val. Take advantage of shells that can avoid forks. The arguments
343# must be portable across $(()) and expr.
344if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
345 eval 'as_fn_arith ()
346 {
347 as_val=$(( $* ))
348 }'
349else
350 as_fn_arith ()
351 {
352 as_val=`expr "$@" || test $? -eq 1`
353 }
354fi # as_fn_arith
355
356
357# as_fn_error ERROR [LINENO LOG_FD]
358# ---------------------------------
359# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
360# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
361# script with status $?, using 1 if that was 0.
362as_fn_error ()
363{
364 as_status=$?; test $as_status -eq 0 && as_status=1
365 if test "$3"; then
366 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
367 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
368 fi
369 $as_echo "$as_me: error: $1" >&2
370 as_fn_exit $as_status
371} # as_fn_error
372
373if expr a : '\(a\)' >/dev/null 2>&1 &&
374 test "X`expr 00001 : '.*\(...\)'`" = X001; then
bec39cab
AC
375 as_expr=expr
376else
377 as_expr=false
378fi
379
81ecdfbb 380if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
bec39cab
AC
381 as_basename=basename
382else
383 as_basename=false
384fi
385
81ecdfbb
RW
386if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
387 as_dirname=dirname
388else
389 as_dirname=false
390fi
bec39cab 391
81ecdfbb 392as_me=`$as_basename -- "$0" ||
bec39cab
AC
393$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
394 X"$0" : 'X\(//\)$' \| \
81ecdfbb
RW
395 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
396$as_echo X/"$0" |
397 sed '/^.*\/\([^/][^/]*\)\/*$/{
398 s//\1/
399 q
400 }
401 /^X\/\(\/\/\)$/{
402 s//\1/
403 q
404 }
405 /^X\/\(\/\).*/{
406 s//\1/
407 q
408 }
409 s/.*/./; q'`
bec39cab 410
b4e70030
JB
411# Avoid depending upon Character Ranges.
412as_cr_letters='abcdefghijklmnopqrstuvwxyz'
413as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
414as_cr_Letters=$as_cr_letters$as_cr_LETTERS
415as_cr_digits='0123456789'
416as_cr_alnum=$as_cr_Letters$as_cr_digits
4e8d927d 417
bec39cab 418
81ecdfbb
RW
419 as_lineno_1=$LINENO as_lineno_1a=$LINENO
420 as_lineno_2=$LINENO as_lineno_2a=$LINENO
421 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
422 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
423 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
424 sed -n '
425 p
426 /[$]LINENO/=
427 ' <$as_myself |
bec39cab 428 sed '
81ecdfbb
RW
429 s/[$]LINENO.*/&-/
430 t lineno
431 b
432 :lineno
bec39cab 433 N
81ecdfbb
RW
434 :loop
435 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
bec39cab 436 t loop
81ecdfbb 437 s/-\n.*//
bec39cab 438 ' >$as_me.lineno &&
81ecdfbb
RW
439 chmod +x "$as_me.lineno" ||
440 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
bec39cab
AC
441
442 # Don't try to exec as it changes $[0], causing all sort of problems
443 # (the dirname of $[0] is not the place where we might find the
81ecdfbb
RW
444 # original and so on. Autoconf is especially sensitive to this).
445 . "./$as_me.lineno"
bec39cab
AC
446 # Exit status is that of the last command.
447 exit
448}
449
81ecdfbb
RW
450ECHO_C= ECHO_N= ECHO_T=
451case `echo -n x` in #(((((
452-n*)
453 case `echo 'xy\c'` in
454 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
455 xy) ECHO_C='\c';;
456 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
457 ECHO_T=' ';;
458 esac;;
459*)
460 ECHO_N='-n';;
bec39cab
AC
461esac
462
81ecdfbb
RW
463rm -f conf$$ conf$$.exe conf$$.file
464if test -d conf$$.dir; then
465 rm -f conf$$.dir/conf$$.file
bec39cab 466else
81ecdfbb
RW
467 rm -f conf$$.dir
468 mkdir conf$$.dir 2>/dev/null
bec39cab 469fi
81ecdfbb
RW
470if (echo >conf$$.file) 2>/dev/null; then
471 if ln -s conf$$.file conf$$ 2>/dev/null; then
b4e70030 472 as_ln_s='ln -s'
81ecdfbb
RW
473 # ... but there are two gotchas:
474 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
475 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
476 # In both cases, we have to default to `cp -p'.
477 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
478 as_ln_s='cp -p'
479 elif ln conf$$.file conf$$ 2>/dev/null; then
480 as_ln_s=ln
481 else
482 as_ln_s='cp -p'
b4e70030 483 fi
bec39cab
AC
484else
485 as_ln_s='cp -p'
486fi
81ecdfbb
RW
487rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
488rmdir conf$$.dir 2>/dev/null
bec39cab
AC
489
490if mkdir -p . 2>/dev/null; then
81ecdfbb 491 as_mkdir_p='mkdir -p "$as_dir"'
bec39cab
AC
492else
493 test -d ./-p && rmdir ./-p
494 as_mkdir_p=false
495fi
496
81ecdfbb
RW
497if test -x / >/dev/null 2>&1; then
498 as_test_x='test -x'
499else
500 if ls -dL / >/dev/null 2>&1; then
501 as_ls_L_option=L
502 else
503 as_ls_L_option=
504 fi
505 as_test_x='
506 eval sh -c '\''
507 if test -d "$1"; then
508 test -d "$1/.";
509 else
510 case $1 in #(
511 -*)set "./$1";;
512 esac;
513 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
514 ???[sx]*):;;*)false;;esac;fi
515 '\'' sh
516 '
517fi
518as_executable_p=$as_test_x
bec39cab
AC
519
520# Sed expression to map a string onto a valid CPP name.
521as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
522
523# Sed expression to map a string onto a valid variable name.
524as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
525
526
81ecdfbb 527exec 7<&0 </dev/null 6>&1
c906108c 528
bec39cab
AC
529# Name of the host.
530# hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
531# so uname gets run too.
532ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
533
bec39cab
AC
534#
535# Initializations.
536#
c906108c 537ac_default_prefix=/usr/local
81ecdfbb 538ac_clean_files=
bec39cab 539ac_config_libobj_dir=.
81ecdfbb 540LIBOBJS=
bec39cab
AC
541cross_compiling=no
542subdirs=
543MFLAGS=
544MAKEFLAGS=
b4e70030 545
bec39cab
AC
546# Identity of this package.
547PACKAGE_NAME=
548PACKAGE_TARNAME=
549PACKAGE_VERSION=
550PACKAGE_STRING=
551PACKAGE_BUGREPORT=
81ecdfbb 552PACKAGE_URL=
bec39cab
AC
553
554ac_unique_file="main.c"
555# Factoring default headers for most tests.
556ac_includes_default="\
557#include <stdio.h>
81ecdfbb 558#ifdef HAVE_SYS_TYPES_H
bec39cab
AC
559# include <sys/types.h>
560#endif
81ecdfbb 561#ifdef HAVE_SYS_STAT_H
bec39cab
AC
562# include <sys/stat.h>
563#endif
81ecdfbb 564#ifdef STDC_HEADERS
bec39cab
AC
565# include <stdlib.h>
566# include <stddef.h>
567#else
81ecdfbb 568# ifdef HAVE_STDLIB_H
bec39cab
AC
569# include <stdlib.h>
570# endif
571#endif
81ecdfbb
RW
572#ifdef HAVE_STRING_H
573# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
bec39cab
AC
574# include <memory.h>
575# endif
576# include <string.h>
577#endif
81ecdfbb 578#ifdef HAVE_STRINGS_H
bec39cab
AC
579# include <strings.h>
580#endif
81ecdfbb 581#ifdef HAVE_INTTYPES_H
bec39cab 582# include <inttypes.h>
bec39cab 583#endif
81ecdfbb
RW
584#ifdef HAVE_STDINT_H
585# include <stdint.h>
586#endif
587#ifdef HAVE_UNISTD_H
bec39cab
AC
588# include <unistd.h>
589#endif"
590
783e057b 591gl_header_list=
f434ba03 592gl_func_list=
81ecdfbb
RW
593enable_option_checking=no
594ac_subst_vars='am__EXEEXT_FALSE
595am__EXEEXT_TRUE
596gltests_LTLIBOBJS
597gltests_LIBOBJS
598gl_LTLIBOBJS
599gl_LIBOBJS
600LTLIBOBJS
601LIBOBJS
602GDB_NM_FILE
603frags
604target_subdir
605CONFIG_UNINSTALL
606CONFIG_INSTALL
607CONFIG_CLEAN
608CONFIG_ALL
609CONFIG_SRCS
610CONFIG_DEPS
611CONFIG_OBS
612PROFILE_CFLAGS
613ENABLE_CFLAGS
614SIM_OBS
615SIM
616XMKMF
617GDBTK_SRC_DIR
618GDBTK_CFLAGS
619GDBTKLIBS
620X_LIBS
621X_LDFLAGS
622X_CFLAGS
623TK_XINCLUDES
624TK_DEPS
625TK_LIBRARY
626TK_INCLUDE
627TK_STUB_LIB_SPEC
628TK_STUB_LIB_FLAG
629TK_STUB_LIB_FILE
630TK_LIB_SPEC
631TK_LIB_FLAG
632TK_LIB_FILE
633TK_SRC_DIR
634TK_BIN_DIR
635TK_VERSION
636TCL_DEPS
637TCL_LIBRARY
638TCL_INCLUDE
639TCL_STUB_LIB_SPEC
640TCL_STUB_LIB_FLAG
641TCL_STUB_LIB_FILE
642TCL_LIB_SPEC
643TCL_LIB_FLAG
644TCL_LIB_FILE
645TCL_SRC_DIR
646TCL_BIN_DIR
647TCL_PATCH_LEVEL
648TCL_VERSION
649WIN32LDAPP
650GUI_CFLAGS_X
651LIBGUI
652WIN32LIBS
653SER_HARDWIRE
654WERROR_CFLAGS
655WARN_CFLAGS
656SYSTEM_GDBINIT
657TARGET_SYSTEM_ROOT_DEFINE
658TARGET_SYSTEM_ROOT
659CONFIG_LDFLAGS
f6528abd 660RDYNAMIC
81ecdfbb
RW
661ALLOCA
662PYTHON_CFLAGS
ec685c5e 663python_prog_path
81ecdfbb
RW
664LTLIBEXPAT
665LIBEXPAT
666HAVE_LIBEXPAT
39037522 667READLINE_TEXI_INCFLAG
81ecdfbb
RW
668READLINE_CFLAGS
669READLINE_DEPS
670READLINE
671MIG
672WINDRES
673DLLTOOL
674AR
675YFLAGS
676YACC
677LN_S
678REPORT_BUGS_TEXI
679REPORT_BUGS_TO
680PKGVERSION
681TARGET_OBS
682subdirs
683GDB_DATADIR
684DEBUGDIR
685am__fastdepCC_FALSE
686am__fastdepCC_TRUE
687AMDEPBACKSLASH
688AMDEP_FALSE
689AMDEP_TRUE
690am__quote
691am__include
692am__untar
693am__tar
694AMTAR
695AWK
696mkdir_p
697MKDIR_P
698INSTALL_STRIP_PROGRAM
699STRIP
700install_sh
701MAKEINFO
702AUTOHEADER
703AUTOMAKE
704AUTOCONF
705ACLOCAL
706VERSION
707CYGPATH_W
708am__isrc
709INSTALL_DATA
710INSTALL_SCRIPT
711INSTALL_PROGRAM
712PACKAGE
713GNULIB_STDINT_H
714LIBGNU_LTLIBDEPS
715LIBGNU_LIBDEPS
f434ba03
PA
716gltests_WITNESS
717HAVE_WINT_T
81ecdfbb 718HAVE_WCHAR_H
f434ba03
PA
719NEXT_AS_FIRST_DIRECTIVE_WCHAR_H
720NEXT_WCHAR_H
81ecdfbb 721REPLACE_WCWIDTH
f434ba03
PA
722REPLACE_WCSNRTOMBS
723REPLACE_WCSRTOMBS
724REPLACE_WCRTOMB
725REPLACE_MBSNRTOWCS
726REPLACE_MBSRTOWCS
727REPLACE_MBRLEN
728REPLACE_MBRTOWC
729REPLACE_MBSINIT
730REPLACE_WCTOB
731REPLACE_BTOWC
732REPLACE_MBSTATE_T
81ecdfbb 733HAVE_DECL_WCWIDTH
f434ba03
PA
734HAVE_DECL_WCTOB
735HAVE_WCSNRTOMBS
736HAVE_WCSRTOMBS
737HAVE_WCRTOMB
738HAVE_MBSNRTOWCS
739HAVE_MBSRTOWCS
740HAVE_MBRLEN
741HAVE_MBRTOWC
742HAVE_MBSINIT
743HAVE_BTOWC
81ecdfbb 744GNULIB_WCWIDTH
f434ba03
PA
745GNULIB_WCSNRTOMBS
746GNULIB_WCSRTOMBS
747GNULIB_WCRTOMB
748GNULIB_MBSNRTOWCS
749GNULIB_MBSRTOWCS
750GNULIB_MBRLEN
751GNULIB_MBRTOWC
752GNULIB_MBSINIT
753GNULIB_WCTOB
754GNULIB_BTOWC
755NEXT_AS_FIRST_DIRECTIVE_STRING_H
81ecdfbb
RW
756NEXT_STRING_H
757STDINT_H
758WINT_T_SUFFIX
759WCHAR_T_SUFFIX
81ecdfbb 760SIG_ATOMIC_T_SUFFIX
f434ba03 761SIZE_T_SUFFIX
81ecdfbb
RW
762PTRDIFF_T_SUFFIX
763HAVE_SIGNED_WINT_T
764HAVE_SIGNED_WCHAR_T
765HAVE_SIGNED_SIG_ATOMIC_T
766BITSIZEOF_WINT_T
767BITSIZEOF_WCHAR_T
81ecdfbb 768BITSIZEOF_SIG_ATOMIC_T
f434ba03 769BITSIZEOF_SIZE_T
81ecdfbb
RW
770BITSIZEOF_PTRDIFF_T
771HAVE_SYS_BITYPES_H
772HAVE_SYS_INTTYPES_H
773HAVE_STDINT_H
f434ba03 774NEXT_AS_FIRST_DIRECTIVE_STDINT_H
81ecdfbb 775NEXT_STDINT_H
81ecdfbb
RW
776HAVE_SYS_TYPES_H
777HAVE_INTTYPES_H
778HAVE_UNSIGNED_LONG_LONG_INT
779HAVE_LONG_LONG_INT
f434ba03
PA
780NEXT_AS_FIRST_DIRECTIVE_STDDEF_H
781NEXT_STDDEF_H
782PRAGMA_SYSTEM_HEADER
783INCLUDE_NEXT_AS_FIRST_DIRECTIVE
784INCLUDE_NEXT
785STDDEF_H
786HAVE_WCHAR_T
787REPLACE_NULL
788APPLE_UNIVERSAL_BUILD
789UNDEFINE_STRTOK_R
790REPLACE_STRTOK_R
81ecdfbb 791REPLACE_STRSIGNAL
f434ba03
PA
792REPLACE_STRNLEN
793REPLACE_STRNDUP
794REPLACE_STRNCAT
81ecdfbb 795REPLACE_STRERROR
f434ba03
PA
796REPLACE_STRCASESTR
797REPLACE_STRSTR
798REPLACE_STRDUP
799REPLACE_STPNCPY
800REPLACE_MEMMEM
801REPLACE_MEMCHR
802HAVE_STRVERSCMP
81ecdfbb 803HAVE_DECL_STRSIGNAL
81ecdfbb
RW
804HAVE_DECL_STRTOK_R
805HAVE_STRCASESTR
806HAVE_STRSEP
807HAVE_STRPBRK
808HAVE_DECL_STRNLEN
809HAVE_DECL_STRNDUP
81ecdfbb
RW
810HAVE_DECL_STRDUP
811HAVE_STRCHRNUL
812HAVE_STPNCPY
813HAVE_STPCPY
f434ba03 814HAVE_RAWMEMCHR
81ecdfbb
RW
815HAVE_DECL_MEMRCHR
816HAVE_MEMPCPY
817HAVE_DECL_MEMMEM
f434ba03
PA
818HAVE_MEMCHR
819HAVE_MBSLEN
820GNULIB_STRVERSCMP
81ecdfbb
RW
821GNULIB_STRSIGNAL
822GNULIB_STRERROR
823GNULIB_MBSTOK_R
824GNULIB_MBSSEP
825GNULIB_MBSSPN
826GNULIB_MBSPBRK
827GNULIB_MBSCSPN
828GNULIB_MBSCASESTR
829GNULIB_MBSPCASECMP
830GNULIB_MBSNCASECMP
831GNULIB_MBSCASECMP
832GNULIB_MBSSTR
833GNULIB_MBSRCHR
834GNULIB_MBSCHR
835GNULIB_MBSNLEN
836GNULIB_MBSLEN
837GNULIB_STRTOK_R
838GNULIB_STRCASESTR
839GNULIB_STRSTR
840GNULIB_STRSEP
841GNULIB_STRPBRK
842GNULIB_STRNLEN
843GNULIB_STRNDUP
f434ba03 844GNULIB_STRNCAT
81ecdfbb
RW
845GNULIB_STRDUP
846GNULIB_STRCHRNUL
847GNULIB_STPNCPY
848GNULIB_STPCPY
f434ba03 849GNULIB_RAWMEMCHR
81ecdfbb
RW
850GNULIB_MEMRCHR
851GNULIB_MEMPCPY
852GNULIB_MEMMEM
f434ba03 853GNULIB_MEMCHR
81ecdfbb
RW
854GL_COND_LIBTOOL_FALSE
855GL_COND_LIBTOOL_TRUE
856CATOBJEXT
857GENCAT
858INSTOBJEXT
859DATADIRNAME
860CATALOGS
861POSUB
862GMSGFMT
863XGETTEXT
864INCINTL
865LIBINTL_DEP
866LIBINTL
867USE_NLS
868SET_MAKE
869GMAKE_FALSE
870GMAKE_TRUE
871MAKE
872CCDEPMODE
873DEPDIR
874am__leading_dot
875target_os
876target_vendor
877target_cpu
878target
f434ba03
PA
879RANLIB
880EGREP
881GREP
882CPP
81ecdfbb
RW
883host_os
884host_vendor
885host_cpu
886host
887build_os
888build_vendor
889build_cpu
890build
81ecdfbb
RW
891OBJEXT
892EXEEXT
893ac_ct_CC
894CPPFLAGS
895LDFLAGS
896CFLAGS
897CC
898MAINT
899MAINTAINER_MODE_FALSE
900MAINTAINER_MODE_TRUE
901target_alias
902host_alias
903build_alias
904LIBS
905ECHO_T
906ECHO_N
907ECHO_C
908DEFS
909mandir
910localedir
911libdir
912psdir
913pdfdir
914dvidir
915htmldir
916infodir
917docdir
918oldincludedir
919includedir
920localstatedir
921sharedstatedir
922sysconfdir
923datadir
924datarootdir
925libexecdir
926sbindir
927bindir
928program_transform_name
929prefix
930exec_prefix
931PACKAGE_URL
932PACKAGE_BUGREPORT
933PACKAGE_STRING
934PACKAGE_VERSION
935PACKAGE_TARNAME
936PACKAGE_NAME
937PATH_SEPARATOR
938SHELL'
a4ce5b0d 939ac_subst_files='host_makefile_frag'
81ecdfbb
RW
940ac_user_opts='
941enable_option_checking
942enable_maintainer_mode
da2f07f1
JK
943enable_plugins
944enable_largefile
81ecdfbb
RW
945enable_dependency_tracking
946with_separate_debug_dir
947with_gdb_datadir
948with_relocated_sources
949enable_targets
950enable_64_bit_bfd
951enable_gdbcli
952enable_gdbmi
953enable_tui
954enable_gdbtk
955with_libunwind
956with_curses
957enable_profiling
958with_pkgversion
959with_bugurl
b040ad30 960with_zlib
81ecdfbb
RW
961with_libiconv_prefix
962with_system_readline
963with_expat
964with_gnu_ld
965enable_rpath
966with_libexpat_prefix
967with_python
968with_included_regex
969with_sysroot
970with_system_gdbinit
971enable_werror
972enable_build_warnings
973enable_gdb_build_warnings
974with_tcl
975with_tk
976with_x
977enable_sim
978enable_multi_ice
496c0e1b 979enable_gdbserver
81ecdfbb
RW
980'
981 ac_precious_vars='build_alias
982host_alias
983target_alias
984CC
985CFLAGS
986LDFLAGS
987LIBS
988CPPFLAGS
989CPP
990YACC
991YFLAGS
992XMKMF'
5ae98d25 993ac_subdirs_all='testsuite
81ecdfbb
RW
994gdbtk
995multi-ice
996gdbserver'
c906108c
SS
997
998# Initialize some variables set by options.
bec39cab
AC
999ac_init_help=
1000ac_init_version=false
81ecdfbb
RW
1001ac_unrecognized_opts=
1002ac_unrecognized_sep=
c906108c
SS
1003# The variables have the same names as the options, with
1004# dashes changed to underlines.
bec39cab 1005cache_file=/dev/null
c906108c 1006exec_prefix=NONE
c906108c 1007no_create=
c906108c
SS
1008no_recursion=
1009prefix=NONE
1010program_prefix=NONE
1011program_suffix=NONE
1012program_transform_name=s,x,x,
1013silent=
1014site=
1015srcdir=
c906108c
SS
1016verbose=
1017x_includes=NONE
1018x_libraries=NONE
bec39cab
AC
1019
1020# Installation directory options.
1021# These are left unexpanded so users can "make install exec_prefix=/foo"
1022# and all the variables that are supposed to be based on exec_prefix
1023# by default will actually change.
1024# Use braces instead of parens because sh, perl, etc. also accept them.
81ecdfbb 1025# (The list follows the same order as the GNU Coding Standards.)
c906108c
SS
1026bindir='${exec_prefix}/bin'
1027sbindir='${exec_prefix}/sbin'
1028libexecdir='${exec_prefix}/libexec'
81ecdfbb
RW
1029datarootdir='${prefix}/share'
1030datadir='${datarootdir}'
c906108c
SS
1031sysconfdir='${prefix}/etc'
1032sharedstatedir='${prefix}/com'
1033localstatedir='${prefix}/var'
c906108c
SS
1034includedir='${prefix}/include'
1035oldincludedir='/usr/include'
81ecdfbb
RW
1036docdir='${datarootdir}/doc/${PACKAGE}'
1037infodir='${datarootdir}/info'
1038htmldir='${docdir}'
1039dvidir='${docdir}'
1040pdfdir='${docdir}'
1041psdir='${docdir}'
1042libdir='${exec_prefix}/lib'
1043localedir='${datarootdir}/locale'
1044mandir='${datarootdir}/man'
c906108c 1045
c906108c 1046ac_prev=
81ecdfbb 1047ac_dashdash=
c906108c
SS
1048for ac_option
1049do
c906108c
SS
1050 # If the previous option needs an argument, assign it.
1051 if test -n "$ac_prev"; then
81ecdfbb 1052 eval $ac_prev=\$ac_option
c906108c
SS
1053 ac_prev=
1054 continue
1055 fi
1056
81ecdfbb
RW
1057 case $ac_option in
1058 *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1059 *) ac_optarg=yes ;;
1060 esac
c906108c
SS
1061
1062 # Accept the important Cygnus configure options, so we can diagnose typos.
1063
81ecdfbb
RW
1064 case $ac_dashdash$ac_option in
1065 --)
1066 ac_dashdash=yes ;;
c906108c
SS
1067
1068 -bindir | --bindir | --bindi | --bind | --bin | --bi)
1069 ac_prev=bindir ;;
1070 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
bec39cab 1071 bindir=$ac_optarg ;;
c906108c
SS
1072
1073 -build | --build | --buil | --bui | --bu)
bec39cab 1074 ac_prev=build_alias ;;
c906108c 1075 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
bec39cab 1076 build_alias=$ac_optarg ;;
c906108c
SS
1077
1078 -cache-file | --cache-file | --cache-fil | --cache-fi \
1079 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1080 ac_prev=cache_file ;;
1081 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1082 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
bec39cab
AC
1083 cache_file=$ac_optarg ;;
1084
1085 --config-cache | -C)
1086 cache_file=config.cache ;;
c906108c 1087
81ecdfbb 1088 -datadir | --datadir | --datadi | --datad)
c906108c 1089 ac_prev=datadir ;;
81ecdfbb 1090 -datadir=* | --datadir=* | --datadi=* | --datad=*)
bec39cab 1091 datadir=$ac_optarg ;;
c906108c 1092
81ecdfbb
RW
1093 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1094 | --dataroo | --dataro | --datar)
1095 ac_prev=datarootdir ;;
1096 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1097 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1098 datarootdir=$ac_optarg ;;
1099
c906108c 1100 -disable-* | --disable-*)
81ecdfbb 1101 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
c906108c 1102 # Reject names that are not valid shell variable names.
81ecdfbb
RW
1103 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1104 as_fn_error "invalid feature name: $ac_useropt"
1105 ac_useropt_orig=$ac_useropt
1106 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1107 case $ac_user_opts in
1108 *"
1109"enable_$ac_useropt"
1110"*) ;;
1111 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1112 ac_unrecognized_sep=', ';;
1113 esac
1114 eval enable_$ac_useropt=no ;;
1115
1116 -docdir | --docdir | --docdi | --doc | --do)
1117 ac_prev=docdir ;;
1118 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1119 docdir=$ac_optarg ;;
1120
1121 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1122 ac_prev=dvidir ;;
1123 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1124 dvidir=$ac_optarg ;;
c906108c
SS
1125
1126 -enable-* | --enable-*)
81ecdfbb 1127 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
c906108c 1128 # Reject names that are not valid shell variable names.
81ecdfbb
RW
1129 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1130 as_fn_error "invalid feature name: $ac_useropt"
1131 ac_useropt_orig=$ac_useropt
1132 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1133 case $ac_user_opts in
1134 *"
1135"enable_$ac_useropt"
1136"*) ;;
1137 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1138 ac_unrecognized_sep=', ';;
b4e70030 1139 esac
81ecdfbb 1140 eval enable_$ac_useropt=\$ac_optarg ;;
c906108c
SS
1141
1142 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1143 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1144 | --exec | --exe | --ex)
1145 ac_prev=exec_prefix ;;
1146 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1147 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1148 | --exec=* | --exe=* | --ex=*)
bec39cab 1149 exec_prefix=$ac_optarg ;;
c906108c
SS
1150
1151 -gas | --gas | --ga | --g)
1152 # Obsolete; use --with-gas.
1153 with_gas=yes ;;
1154
bec39cab
AC
1155 -help | --help | --hel | --he | -h)
1156 ac_init_help=long ;;
1157 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1158 ac_init_help=recursive ;;
1159 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1160 ac_init_help=short ;;
c906108c
SS
1161
1162 -host | --host | --hos | --ho)
bec39cab 1163 ac_prev=host_alias ;;
c906108c 1164 -host=* | --host=* | --hos=* | --ho=*)
bec39cab 1165 host_alias=$ac_optarg ;;
c906108c 1166
81ecdfbb
RW
1167 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1168 ac_prev=htmldir ;;
1169 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1170 | --ht=*)
1171 htmldir=$ac_optarg ;;
1172
c906108c
SS
1173 -includedir | --includedir | --includedi | --included | --include \
1174 | --includ | --inclu | --incl | --inc)
1175 ac_prev=includedir ;;
1176 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1177 | --includ=* | --inclu=* | --incl=* | --inc=*)
bec39cab 1178 includedir=$ac_optarg ;;
c906108c
SS
1179
1180 -infodir | --infodir | --infodi | --infod | --info | --inf)
1181 ac_prev=infodir ;;
1182 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
bec39cab 1183 infodir=$ac_optarg ;;
c906108c
SS
1184
1185 -libdir | --libdir | --libdi | --libd)
1186 ac_prev=libdir ;;
1187 -libdir=* | --libdir=* | --libdi=* | --libd=*)
bec39cab 1188 libdir=$ac_optarg ;;
c906108c
SS
1189
1190 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1191 | --libexe | --libex | --libe)
1192 ac_prev=libexecdir ;;
1193 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1194 | --libexe=* | --libex=* | --libe=*)
bec39cab 1195 libexecdir=$ac_optarg ;;
c906108c 1196
81ecdfbb
RW
1197 -localedir | --localedir | --localedi | --localed | --locale)
1198 ac_prev=localedir ;;
1199 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1200 localedir=$ac_optarg ;;
1201
c906108c 1202 -localstatedir | --localstatedir | --localstatedi | --localstated \
81ecdfbb 1203 | --localstate | --localstat | --localsta | --localst | --locals)
c906108c
SS
1204 ac_prev=localstatedir ;;
1205 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
81ecdfbb 1206 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
bec39cab 1207 localstatedir=$ac_optarg ;;
c906108c
SS
1208
1209 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1210 ac_prev=mandir ;;
1211 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
bec39cab 1212 mandir=$ac_optarg ;;
c906108c
SS
1213
1214 -nfp | --nfp | --nf)
1215 # Obsolete; use --without-fp.
1216 with_fp=no ;;
1217
1218 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
bec39cab 1219 | --no-cr | --no-c | -n)
c906108c
SS
1220 no_create=yes ;;
1221
1222 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1223 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1224 no_recursion=yes ;;
1225
1226 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1227 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1228 | --oldin | --oldi | --old | --ol | --o)
1229 ac_prev=oldincludedir ;;
1230 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1231 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1232 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
bec39cab 1233 oldincludedir=$ac_optarg ;;
c906108c
SS
1234
1235 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1236 ac_prev=prefix ;;
1237 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
bec39cab 1238 prefix=$ac_optarg ;;
c906108c
SS
1239
1240 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1241 | --program-pre | --program-pr | --program-p)
1242 ac_prev=program_prefix ;;
1243 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1244 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
bec39cab 1245 program_prefix=$ac_optarg ;;
c906108c
SS
1246
1247 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1248 | --program-suf | --program-su | --program-s)
1249 ac_prev=program_suffix ;;
1250 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1251 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
bec39cab 1252 program_suffix=$ac_optarg ;;
c906108c
SS
1253
1254 -program-transform-name | --program-transform-name \
1255 | --program-transform-nam | --program-transform-na \
1256 | --program-transform-n | --program-transform- \
1257 | --program-transform | --program-transfor \
1258 | --program-transfo | --program-transf \
1259 | --program-trans | --program-tran \
1260 | --progr-tra | --program-tr | --program-t)
1261 ac_prev=program_transform_name ;;
1262 -program-transform-name=* | --program-transform-name=* \
1263 | --program-transform-nam=* | --program-transform-na=* \
1264 | --program-transform-n=* | --program-transform-=* \
1265 | --program-transform=* | --program-transfor=* \
1266 | --program-transfo=* | --program-transf=* \
1267 | --program-trans=* | --program-tran=* \
1268 | --progr-tra=* | --program-tr=* | --program-t=*)
bec39cab 1269 program_transform_name=$ac_optarg ;;
c906108c 1270
81ecdfbb
RW
1271 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1272 ac_prev=pdfdir ;;
1273 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1274 pdfdir=$ac_optarg ;;
1275
1276 -psdir | --psdir | --psdi | --psd | --ps)
1277 ac_prev=psdir ;;
1278 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1279 psdir=$ac_optarg ;;
1280
c906108c
SS
1281 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1282 | -silent | --silent | --silen | --sile | --sil)
1283 silent=yes ;;
1284
1285 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1286 ac_prev=sbindir ;;
1287 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1288 | --sbi=* | --sb=*)
bec39cab 1289 sbindir=$ac_optarg ;;
c906108c
SS
1290
1291 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1292 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1293 | --sharedst | --shareds | --shared | --share | --shar \
1294 | --sha | --sh)
1295 ac_prev=sharedstatedir ;;
1296 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1297 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1298 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1299 | --sha=* | --sh=*)
bec39cab 1300 sharedstatedir=$ac_optarg ;;
c906108c
SS
1301
1302 -site | --site | --sit)
1303 ac_prev=site ;;
1304 -site=* | --site=* | --sit=*)
bec39cab 1305 site=$ac_optarg ;;
3ace7edb 1306
c906108c
SS
1307 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1308 ac_prev=srcdir ;;
1309 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
bec39cab 1310 srcdir=$ac_optarg ;;
c906108c
SS
1311
1312 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1313 | --syscon | --sysco | --sysc | --sys | --sy)
1314 ac_prev=sysconfdir ;;
1315 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1316 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
bec39cab 1317 sysconfdir=$ac_optarg ;;
c906108c
SS
1318
1319 -target | --target | --targe | --targ | --tar | --ta | --t)
bec39cab 1320 ac_prev=target_alias ;;
c906108c 1321 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
bec39cab 1322 target_alias=$ac_optarg ;;
c906108c
SS
1323
1324 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1325 verbose=yes ;;
1326
bec39cab
AC
1327 -version | --version | --versio | --versi | --vers | -V)
1328 ac_init_version=: ;;
c906108c
SS
1329
1330 -with-* | --with-*)
81ecdfbb 1331 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
c906108c 1332 # Reject names that are not valid shell variable names.
81ecdfbb
RW
1333 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1334 as_fn_error "invalid package name: $ac_useropt"
1335 ac_useropt_orig=$ac_useropt
1336 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1337 case $ac_user_opts in
1338 *"
1339"with_$ac_useropt"
1340"*) ;;
1341 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1342 ac_unrecognized_sep=', ';;
b4e70030 1343 esac
81ecdfbb 1344 eval with_$ac_useropt=\$ac_optarg ;;
c906108c
SS
1345
1346 -without-* | --without-*)
81ecdfbb 1347 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
c906108c 1348 # Reject names that are not valid shell variable names.
81ecdfbb
RW
1349 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1350 as_fn_error "invalid package name: $ac_useropt"
1351 ac_useropt_orig=$ac_useropt
1352 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1353 case $ac_user_opts in
1354 *"
1355"with_$ac_useropt"
1356"*) ;;
1357 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1358 ac_unrecognized_sep=', ';;
1359 esac
1360 eval with_$ac_useropt=no ;;
c906108c
SS
1361
1362 --x)
1363 # Obsolete; use --with-x.
1364 with_x=yes ;;
1365
1366 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1367 | --x-incl | --x-inc | --x-in | --x-i)
1368 ac_prev=x_includes ;;
1369 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1370 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
bec39cab 1371 x_includes=$ac_optarg ;;
c906108c
SS
1372
1373 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1374 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1375 ac_prev=x_libraries ;;
1376 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1377 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
bec39cab 1378 x_libraries=$ac_optarg ;;
c906108c 1379
81ecdfbb
RW
1380 -*) as_fn_error "unrecognized option: \`$ac_option'
1381Try \`$0 --help' for more information."
c906108c
SS
1382 ;;
1383
bec39cab
AC
1384 *=*)
1385 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1386 # Reject names that are not valid shell variable names.
81ecdfbb
RW
1387 case $ac_envvar in #(
1388 '' | [0-9]* | *[!_$as_cr_alnum]* )
1389 as_fn_error "invalid variable name: \`$ac_envvar'" ;;
1390 esac
1391 eval $ac_envvar=\$ac_optarg
bec39cab
AC
1392 export $ac_envvar ;;
1393
c906108c 1394 *)
bec39cab 1395 # FIXME: should be removed in autoconf 3.0.
81ecdfbb 1396 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
bec39cab 1397 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
81ecdfbb 1398 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
bec39cab 1399 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
c906108c
SS
1400 ;;
1401
1402 esac
1403done
1404
1405if test -n "$ac_prev"; then
bec39cab 1406 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
81ecdfbb 1407 as_fn_error "missing argument to $ac_option"
c906108c 1408fi
c906108c 1409
81ecdfbb
RW
1410if test -n "$ac_unrecognized_opts"; then
1411 case $enable_option_checking in
1412 no) ;;
1413 fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;;
1414 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
b4e70030 1415 esac
81ecdfbb 1416fi
b4e70030 1417
81ecdfbb
RW
1418# Check all directory arguments for consistency.
1419for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1420 datadir sysconfdir sharedstatedir localstatedir includedir \
1421 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1422 libdir localedir mandir
b4e70030 1423do
81ecdfbb
RW
1424 eval ac_val=\$$ac_var
1425 # Remove trailing slashes.
1426 case $ac_val in
1427 */ )
1428 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1429 eval $ac_var=\$ac_val;;
1430 esac
1431 # Be sure to have absolute directory names.
b4e70030 1432 case $ac_val in
81ecdfbb
RW
1433 [\\/$]* | ?:[\\/]* ) continue;;
1434 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
c906108c 1435 esac
81ecdfbb 1436 as_fn_error "expected an absolute directory name for --$ac_var: $ac_val"
c906108c
SS
1437done
1438
bec39cab
AC
1439# There might be people who depend on the old broken behavior: `$host'
1440# used to hold the argument of --host etc.
1441# FIXME: To remove some day.
1442build=$build_alias
1443host=$host_alias
1444target=$target_alias
1445
1446# FIXME: To remove some day.
1447if test "x$host_alias" != x; then
1448 if test "x$build_alias" = x; then
1449 cross_compiling=maybe
81ecdfbb 1450 $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
bec39cab
AC
1451 If a cross compiler is detected then cross compile mode will be used." >&2
1452 elif test "x$build_alias" != "x$host_alias"; then
1453 cross_compiling=yes
1454 fi
1455fi
c906108c 1456
bec39cab
AC
1457ac_tool_prefix=
1458test -n "$host_alias" && ac_tool_prefix=$host_alias-
1459
1460test "$silent" = yes && exec 6>/dev/null
c906108c 1461
c906108c 1462
81ecdfbb
RW
1463ac_pwd=`pwd` && test -n "$ac_pwd" &&
1464ac_ls_di=`ls -di .` &&
1465ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1466 as_fn_error "working directory cannot be determined"
1467test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1468 as_fn_error "pwd does not report name of working directory"
1469
1470
c906108c
SS
1471# Find the source files, if location was not specified.
1472if test -z "$srcdir"; then
1473 ac_srcdir_defaulted=yes
81ecdfbb
RW
1474 # Try the directory containing this script, then the parent directory.
1475 ac_confdir=`$as_dirname -- "$as_myself" ||
1476$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1477 X"$as_myself" : 'X\(//\)[^/]' \| \
1478 X"$as_myself" : 'X\(//\)$' \| \
1479 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1480$as_echo X"$as_myself" |
1481 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1482 s//\1/
1483 q
1484 }
1485 /^X\(\/\/\)[^/].*/{
1486 s//\1/
1487 q
1488 }
1489 /^X\(\/\/\)$/{
1490 s//\1/
1491 q
1492 }
1493 /^X\(\/\).*/{
1494 s//\1/
1495 q
1496 }
1497 s/.*/./; q'`
c906108c 1498 srcdir=$ac_confdir
81ecdfbb 1499 if test ! -r "$srcdir/$ac_unique_file"; then
c906108c
SS
1500 srcdir=..
1501 fi
1502else
1503 ac_srcdir_defaulted=no
1504fi
81ecdfbb
RW
1505if test ! -r "$srcdir/$ac_unique_file"; then
1506 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1507 as_fn_error "cannot find sources ($ac_unique_file) in $srcdir"
1508fi
1509ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1510ac_abs_confdir=`(
1511 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg"
1512 pwd)`
1513# When building in place, set srcdir=.
1514if test "$ac_abs_confdir" = "$ac_pwd"; then
1515 srcdir=.
1516fi
1517# Remove unnecessary trailing slashes from srcdir.
1518# Double slashes in file names in object file debugging info
1519# mess up M-x gdb in Emacs.
1520case $srcdir in
1521*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1522esac
1523for ac_var in $ac_precious_vars; do
1524 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1525 eval ac_env_${ac_var}_value=\$${ac_var}
1526 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1527 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1528done
c906108c 1529
bec39cab
AC
1530#
1531# Report the --help message.
1532#
1533if test "$ac_init_help" = "long"; then
1534 # Omit some internal or obsolete options to make the list less imposing.
1535 # This message is too long to be a string in the A/UX 3.1 sh.
1536 cat <<_ACEOF
1537\`configure' configures this package to adapt to many kinds of systems.
1538
1539Usage: $0 [OPTION]... [VAR=VALUE]...
1540
1541To assign environment variables (e.g., CC, CFLAGS...), specify them as
1542VAR=VALUE. See below for descriptions of some of the useful variables.
1543
1544Defaults for the options are specified in brackets.
1545
1546Configuration:
1547 -h, --help display this help and exit
1548 --help=short display options specific to this package
1549 --help=recursive display the short help of all the included packages
1550 -V, --version display version information and exit
1551 -q, --quiet, --silent do not print \`checking...' messages
1552 --cache-file=FILE cache test results in FILE [disabled]
1553 -C, --config-cache alias for \`--cache-file=config.cache'
1554 -n, --no-create do not create output files
1555 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1556
bec39cab
AC
1557Installation directories:
1558 --prefix=PREFIX install architecture-independent files in PREFIX
81ecdfbb 1559 [$ac_default_prefix]
bec39cab 1560 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
81ecdfbb 1561 [PREFIX]
bec39cab
AC
1562
1563By default, \`make install' will install all the files in
1564\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1565an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1566for instance \`--prefix=\$HOME'.
1567
1568For better control, use the options below.
1569
1570Fine tuning of the installation directories:
81ecdfbb
RW
1571 --bindir=DIR user executables [EPREFIX/bin]
1572 --sbindir=DIR system admin executables [EPREFIX/sbin]
1573 --libexecdir=DIR program executables [EPREFIX/libexec]
1574 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1575 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1576 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1577 --libdir=DIR object code libraries [EPREFIX/lib]
1578 --includedir=DIR C header files [PREFIX/include]
1579 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1580 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1581 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1582 --infodir=DIR info documentation [DATAROOTDIR/info]
1583 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1584 --mandir=DIR man documentation [DATAROOTDIR/man]
1585 --docdir=DIR documentation root [DATAROOTDIR/doc/PACKAGE]
1586 --htmldir=DIR html documentation [DOCDIR]
1587 --dvidir=DIR dvi documentation [DOCDIR]
1588 --pdfdir=DIR pdf documentation [DOCDIR]
1589 --psdir=DIR ps documentation [DOCDIR]
bec39cab
AC
1590_ACEOF
1591
1592 cat <<\_ACEOF
1593
1594Program names:
1595 --program-prefix=PREFIX prepend PREFIX to installed program names
1596 --program-suffix=SUFFIX append SUFFIX to installed program names
1597 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
1598
1599X features:
1600 --x-includes=DIR X include files are in DIR
1601 --x-libraries=DIR X library files are in DIR
1602
1603System types:
1604 --build=BUILD configure for building on BUILD [guessed]
1605 --host=HOST cross-compile to build programs to run on HOST [BUILD]
1606 --target=TARGET configure for building compilers for TARGET [HOST]
1607_ACEOF
1608fi
1609
1610if test -n "$ac_init_help"; then
1611
1612 cat <<\_ACEOF
1613
1614Optional Features:
81ecdfbb 1615 --disable-option-checking ignore unrecognized --enable/--with options
bec39cab
AC
1616 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1617 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
85981d60
AC
1618 --enable-maintainer-mode enable make rules and dependencies not useful
1619 (and sometimes confusing) to the casual installer
da2f07f1
JK
1620 --enable-plugins Enable support for plugins (defaults no)
1621 --disable-largefile omit support for large files
e28b3332
DJ
1622 --disable-dependency-tracking speeds up one-time build
1623 --enable-dependency-tracking do not reject slow dependency extractors
a1220294
TT
1624 --enable-targets=TARGETS
1625 alternative target configurations
c0993dbe 1626 --enable-64-bit-bfd 64-bit support (on hosts with narrower word sizes)
bec39cab
AC
1627 --disable-gdbcli disable command-line interface (CLI)
1628 --disable-gdbmi disable machine-interface (MI)
1629 --enable-tui enable full-screen terminal user interface (TUI)
1630 --enable-gdbtk enable gdbtk graphical user interface (GUI)
1631 --enable-profiling enable profiling of GDB
3841debe 1632 --disable-rpath do not hardcode runtime library paths
a1220294 1633 --enable-werror treat compile warnings as errors
32c1c914 1634 --enable-build-warnings enable build-time compiler warnings if gcc is used
a1220294 1635 --enable-gdb-build-warnings
32c1c914 1636 enable GDB specific build-time compiler warnings if
a1220294 1637 gcc is used
32c1c914 1638 --enable-sim link gdb with simulator
bec39cab 1639 --enable-multi-ice build the multi-ice-gdb-server
496c0e1b
JB
1640 --enable-gdbserver automatically build gdbserver (yes/no/auto, default
1641 is auto)
bec39cab
AC
1642
1643Optional Packages:
1644 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
1645 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
a1220294 1646 --with-separate-debug-dir=PATH
32c1c914 1647 look for global separate debug info in this path
62e4f60c 1648 [LIBDIR/debug]
b14b1491
TT
1649 --with-gdb-datadir=PATH look for global separate data files in this path
1650 [DATADIR/gdb]
29b0e8a2 1651 --with-relocated-sources=PATH
32c1c914
TT
1652 automatically relocate this path for source files
1653 --with-libunwind use libunwind frame unwinding support
cb01cfba
JB
1654 --with-curses use the curses library instead of the termcap
1655 library
c16158bc
JM
1656 --with-pkgversion=PKG Use PKG in the version string in place of "GDB"
1657 --with-bugurl=URL Direct users to URL to report a bug
b040ad30 1658 --with-zlib include zlib support (auto/yes/no) default=auto
a1220294
TT
1659 --with-libiconv-prefix=DIR
1660 search for libiconv in DIR/include and DIR/lib
6a30b0a5 1661 --with-system-readline use installed readline library
5c39566f 1662 --with-expat include expat support (auto/yes/no)
3841debe
DJ
1663 --with-gnu-ld assume the C compiler uses GNU ld default=no
1664 --with-libexpat-prefix[=DIR] search for libexpat in DIR/include and DIR/lib
1665 --without-libexpat-prefix don't search for libexpat in includedir and libdir
0c4a4063
DE
1666 --with-python[=PYTHON] include python support
1667 (auto/yes/no/<python-program>)
a1220294
TT
1668 --without-included-regex
1669 don't use included regex; this is the default on
1670 systems with version 2 of the GNU C library (use
1671 with caution on other system)
81ecdfbb 1672 --with-sysroot[=DIR] search for usr/lib et al within DIR
b14b1491 1673 --with-system-gdbinit=PATH
32c1c914 1674 automatically load a system-wide gdbinit file
5062cc19
KS
1675 --with-tcl directory containing tcl configuration (tclConfig.sh)
1676 --with-tk directory containing tk configuration (tkConfig.sh)
bec39cab 1677 --with-x use the X Window System
bec39cab
AC
1678
1679Some influential environment variables:
1680 CC C compiler command
1681 CFLAGS C compiler flags
1682 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
1683 nonstandard directory <lib dir>
81ecdfbb
RW
1684 LIBS libraries to pass to the linker, e.g. -l<library>
1685 CPPFLAGS C/C++/Objective C preprocessor flags, e.g. -I<include dir> if
1686 you have headers in a nonstandard directory <include dir>
bec39cab 1687 CPP C preprocessor
81ecdfbb
RW
1688 YACC The `Yet Another C Compiler' implementation to use. Defaults to
1689 the first program found out of: `bison -y', `byacc', `yacc'.
1690 YFLAGS The list of arguments that will be passed by default to $YACC.
1691 This script will default YFLAGS to the empty string to avoid a
1692 default value of `-d' given by some make applications.
1693 XMKMF Path to xmkmf, Makefile generator for X Window System
bec39cab
AC
1694
1695Use these variables to override the choices made by `configure' or to help
1696it to find libraries and programs with nonstandard names/locations.
1697
81ecdfbb 1698Report bugs to the package provider.
bec39cab 1699_ACEOF
81ecdfbb 1700ac_status=$?
bec39cab
AC
1701fi
1702
1703if test "$ac_init_help" = "recursive"; then
1704 # If there are subdirs, report their specific --help.
bec39cab 1705 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
81ecdfbb
RW
1706 test -d "$ac_dir" ||
1707 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1708 continue
bec39cab
AC
1709 ac_builddir=.
1710
81ecdfbb
RW
1711case "$ac_dir" in
1712.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1713*)
1714 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1715 # A ".." for each directory in $ac_dir_suffix.
1716 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1717 case $ac_top_builddir_sub in
1718 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1719 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1720 esac ;;
1721esac
1722ac_abs_top_builddir=$ac_pwd
1723ac_abs_builddir=$ac_pwd$ac_dir_suffix
1724# for backward compatibility:
1725ac_top_builddir=$ac_top_build_prefix
bec39cab
AC
1726
1727case $srcdir in
81ecdfbb 1728 .) # We are building in place.
bec39cab 1729 ac_srcdir=.
81ecdfbb
RW
1730 ac_top_srcdir=$ac_top_builddir_sub
1731 ac_abs_top_srcdir=$ac_pwd ;;
1732 [\\/]* | ?:[\\/]* ) # Absolute name.
bec39cab 1733 ac_srcdir=$srcdir$ac_dir_suffix;
81ecdfbb
RW
1734 ac_top_srcdir=$srcdir
1735 ac_abs_top_srcdir=$srcdir ;;
1736 *) # Relative name.
1737 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1738 ac_top_srcdir=$ac_top_build_prefix$srcdir
1739 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
bec39cab 1740esac
81ecdfbb 1741ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
bec39cab 1742
81ecdfbb
RW
1743 cd "$ac_dir" || { ac_status=$?; continue; }
1744 # Check for guested configure.
1745 if test -f "$ac_srcdir/configure.gnu"; then
1746 echo &&
1747 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1748 elif test -f "$ac_srcdir/configure"; then
1749 echo &&
1750 $SHELL "$ac_srcdir/configure" --help=recursive
3ace7edb 1751 else
81ecdfbb
RW
1752 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1753 fi || ac_status=$?
1754 cd "$ac_pwd" || { ac_status=$?; break; }
bec39cab
AC
1755 done
1756fi
1757
81ecdfbb 1758test -n "$ac_init_help" && exit $ac_status
bec39cab
AC
1759if $ac_init_version; then
1760 cat <<\_ACEOF
81ecdfbb
RW
1761configure
1762generated by GNU Autoconf 2.64
bec39cab 1763
81ecdfbb 1764Copyright (C) 2009 Free Software Foundation, Inc.
bec39cab
AC
1765This configure script is free software; the Free Software Foundation
1766gives unlimited permission to copy, distribute and modify it.
1767_ACEOF
81ecdfbb 1768 exit
bec39cab 1769fi
bec39cab 1770
81ecdfbb
RW
1771## ------------------------ ##
1772## Autoconf initialization. ##
1773## ------------------------ ##
bec39cab 1774
81ecdfbb
RW
1775# ac_fn_c_try_compile LINENO
1776# --------------------------
1777# Try to compile conftest.$ac_ext, and return whether this succeeded.
1778ac_fn_c_try_compile ()
1779{
1780 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1781 rm -f conftest.$ac_objext
1782 if { { ac_try="$ac_compile"
1783case "(($ac_try" in
1784 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1785 *) ac_try_echo=$ac_try;;
1786esac
1787eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1788$as_echo "$ac_try_echo"; } >&5
1789 (eval "$ac_compile") 2>conftest.err
1790 ac_status=$?
1791 if test -s conftest.err; then
1792 grep -v '^ *+' conftest.err >conftest.er1
1793 cat conftest.er1 >&5
1794 mv -f conftest.er1 conftest.err
1795 fi
1796 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1797 test $ac_status = 0; } && {
1798 test -z "$ac_c_werror_flag" ||
1799 test ! -s conftest.err
1800 } && test -s conftest.$ac_objext; then :
1801 ac_retval=0
1802else
1803 $as_echo "$as_me: failed program was:" >&5
1804sed 's/^/| /' conftest.$ac_ext >&5
bec39cab 1805
81ecdfbb
RW
1806 ac_retval=1
1807fi
1808 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1809 return $ac_retval
1810
1811} # ac_fn_c_try_compile
1812
1813# ac_fn_c_try_cpp LINENO
1814# ----------------------
1815# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1816ac_fn_c_try_cpp ()
bec39cab 1817{
81ecdfbb
RW
1818 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1819 if { { ac_try="$ac_cpp conftest.$ac_ext"
1820case "(($ac_try" in
1821 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1822 *) ac_try_echo=$ac_try;;
1823esac
1824eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1825$as_echo "$ac_try_echo"; } >&5
1826 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1827 ac_status=$?
1828 if test -s conftest.err; then
1829 grep -v '^ *+' conftest.err >conftest.er1
1830 cat conftest.er1 >&5
1831 mv -f conftest.er1 conftest.err
1832 fi
1833 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1834 test $ac_status = 0; } >/dev/null && {
1835 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1836 test ! -s conftest.err
1837 }; then :
1838 ac_retval=0
1839else
1840 $as_echo "$as_me: failed program was:" >&5
1841sed 's/^/| /' conftest.$ac_ext >&5
bec39cab 1842
81ecdfbb
RW
1843 ac_retval=1
1844fi
1845 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1846 return $ac_retval
bec39cab 1847
81ecdfbb 1848} # ac_fn_c_try_cpp
bec39cab 1849
81ecdfbb
RW
1850# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
1851# -------------------------------------------------------
1852# Tests whether HEADER exists, giving a warning if it cannot be compiled using
1853# the include files in INCLUDES and setting the cache variable VAR
1854# accordingly.
1855ac_fn_c_check_header_mongrel ()
1856{
1857 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1858 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1859 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1860$as_echo_n "checking for $2... " >&6; }
1861if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1862 $as_echo_n "(cached) " >&6
1863fi
1864eval ac_res=\$$3
1865 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1866$as_echo "$ac_res" >&6; }
1867else
1868 # Is the header compilable?
1869{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
1870$as_echo_n "checking $2 usability... " >&6; }
1871cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1872/* end confdefs.h. */
1873$4
1874#include <$2>
1875_ACEOF
1876if ac_fn_c_try_compile "$LINENO"; then :
1877 ac_header_compiler=yes
1878else
1879 ac_header_compiler=no
1880fi
1881rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1882{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
1883$as_echo "$ac_header_compiler" >&6; }
bec39cab 1884
81ecdfbb
RW
1885# Is the header present?
1886{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
1887$as_echo_n "checking $2 presence... " >&6; }
1888cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1889/* end confdefs.h. */
1890#include <$2>
1891_ACEOF
1892if ac_fn_c_try_cpp "$LINENO"; then :
1893 ac_header_preproc=yes
1894else
1895 ac_header_preproc=no
1896fi
1897rm -f conftest.err conftest.$ac_ext
1898{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
1899$as_echo "$ac_header_preproc" >&6; }
bec39cab 1900
81ecdfbb
RW
1901# So? What about this header?
1902case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
1903 yes:no: )
1904 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
1905$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
1906 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1907$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1908 ;;
1909 no:yes:* )
1910 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
1911$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
1912 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
1913$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
1914 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
1915$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
1916 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
1917$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
1918 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1919$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1920 ;;
1921esac
1922 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1923$as_echo_n "checking for $2... " >&6; }
1924if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1925 $as_echo_n "(cached) " >&6
1926else
1927 eval "$3=\$ac_header_compiler"
1928fi
1929eval ac_res=\$$3
1930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1931$as_echo "$ac_res" >&6; }
1932fi
1933 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
bec39cab 1934
81ecdfbb 1935} # ac_fn_c_check_header_mongrel
bec39cab 1936
81ecdfbb
RW
1937# ac_fn_c_try_run LINENO
1938# ----------------------
1939# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
1940# that executables *can* be run.
1941ac_fn_c_try_run ()
1942{
1943 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1944 if { { ac_try="$ac_link"
1945case "(($ac_try" in
1946 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1947 *) ac_try_echo=$ac_try;;
1948esac
1949eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1950$as_echo "$ac_try_echo"; } >&5
1951 (eval "$ac_link") 2>&5
1952 ac_status=$?
1953 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1954 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1955 { { case "(($ac_try" in
1956 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1957 *) ac_try_echo=$ac_try;;
1958esac
1959eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1960$as_echo "$ac_try_echo"; } >&5
1961 (eval "$ac_try") 2>&5
1962 ac_status=$?
1963 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1964 test $ac_status = 0; }; }; then :
1965 ac_retval=0
1966else
1967 $as_echo "$as_me: program exited with status $ac_status" >&5
1968 $as_echo "$as_me: failed program was:" >&5
1969sed 's/^/| /' conftest.$ac_ext >&5
bec39cab 1970
81ecdfbb
RW
1971 ac_retval=$ac_status
1972fi
1973 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1974 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1975 return $ac_retval
bec39cab 1976
81ecdfbb 1977} # ac_fn_c_try_run
bec39cab 1978
81ecdfbb
RW
1979# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
1980# -------------------------------------------------------
1981# Tests whether HEADER exists and can be compiled using the include files in
1982# INCLUDES, setting the cache variable VAR accordingly.
1983ac_fn_c_check_header_compile ()
1984{
1985 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1986 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1987$as_echo_n "checking for $2... " >&6; }
1988if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1989 $as_echo_n "(cached) " >&6
1990else
1991 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1992/* end confdefs.h. */
1993$4
1994#include <$2>
bec39cab 1995_ACEOF
81ecdfbb
RW
1996if ac_fn_c_try_compile "$LINENO"; then :
1997 eval "$3=yes"
1998else
1999 eval "$3=no"
2000fi
2001rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2002fi
2003eval ac_res=\$$3
2004 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2005$as_echo "$ac_res" >&6; }
2006 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
bec39cab 2007
81ecdfbb 2008} # ac_fn_c_check_header_compile
bec39cab 2009
81ecdfbb
RW
2010# ac_fn_c_try_link LINENO
2011# -----------------------
2012# Try to link conftest.$ac_ext, and return whether this succeeded.
2013ac_fn_c_try_link ()
b4e70030 2014{
81ecdfbb
RW
2015 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2016 rm -f conftest.$ac_objext conftest$ac_exeext
2017 if { { ac_try="$ac_link"
2018case "(($ac_try" in
2019 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2020 *) ac_try_echo=$ac_try;;
2021esac
2022eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2023$as_echo "$ac_try_echo"; } >&5
2024 (eval "$ac_link") 2>conftest.err
2025 ac_status=$?
2026 if test -s conftest.err; then
2027 grep -v '^ *+' conftest.err >conftest.er1
2028 cat conftest.er1 >&5
2029 mv -f conftest.er1 conftest.err
2030 fi
2031 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2032 test $ac_status = 0; } && {
2033 test -z "$ac_c_werror_flag" ||
2034 test ! -s conftest.err
2035 } && test -s conftest$ac_exeext && {
2036 test "$cross_compiling" = yes ||
2037 $as_test_x conftest$ac_exeext
2038 }; then :
2039 ac_retval=0
2040else
2041 $as_echo "$as_me: failed program was:" >&5
2042sed 's/^/| /' conftest.$ac_ext >&5
bec39cab 2043
81ecdfbb
RW
2044 ac_retval=1
2045fi
2046 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2047 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2048 # interfere with the next link command; also delete a directory that is
2049 # left behind by Apple's compiler. We do this before executing the actions.
2050 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2051 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2052 return $ac_retval
bec39cab 2053
81ecdfbb 2054} # ac_fn_c_try_link
bec39cab 2055
81ecdfbb
RW
2056# ac_fn_c_check_func LINENO FUNC VAR
2057# ----------------------------------
2058# Tests whether FUNC exists, setting the cache variable VAR accordingly
2059ac_fn_c_check_func ()
2060{
2061 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2062 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2063$as_echo_n "checking for $2... " >&6; }
2064if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2065 $as_echo_n "(cached) " >&6
2066else
2067 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2068/* end confdefs.h. */
2069/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2070 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2071#define $2 innocuous_$2
bec39cab 2072
81ecdfbb
RW
2073/* System header to define __stub macros and hopefully few prototypes,
2074 which can conflict with char $2 (); below.
2075 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2076 <limits.h> exists even on freestanding compilers. */
bec39cab 2077
81ecdfbb
RW
2078#ifdef __STDC__
2079# include <limits.h>
2080#else
2081# include <assert.h>
2082#endif
bec39cab 2083
81ecdfbb 2084#undef $2
bec39cab 2085
81ecdfbb
RW
2086/* Override any GCC internal prototype to avoid an error.
2087 Use char because int might match the return type of a GCC
2088 builtin and then its argument prototype would still apply. */
2089#ifdef __cplusplus
2090extern "C"
2091#endif
2092char $2 ();
2093/* The GNU C library defines this for functions which it implements
2094 to always fail with ENOSYS. Some functions are actually named
2095 something starting with __ and the normal name is an alias. */
2096#if defined __stub_$2 || defined __stub___$2
2097choke me
2098#endif
bec39cab 2099
81ecdfbb
RW
2100int
2101main ()
2102{
2103return $2 ();
2104 ;
2105 return 0;
2106}
bec39cab 2107_ACEOF
81ecdfbb
RW
2108if ac_fn_c_try_link "$LINENO"; then :
2109 eval "$3=yes"
2110else
2111 eval "$3=no"
2112fi
2113rm -f core conftest.err conftest.$ac_objext \
2114 conftest$ac_exeext conftest.$ac_ext
2115fi
2116eval ac_res=\$$3
2117 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2118$as_echo "$ac_res" >&6; }
2119 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
bec39cab 2120
81ecdfbb 2121} # ac_fn_c_check_func
bec39cab 2122
81ecdfbb
RW
2123# ac_fn_c_check_decl LINENO SYMBOL VAR
2124# ------------------------------------
2125# Tests whether SYMBOL is declared, setting cache variable VAR accordingly.
2126ac_fn_c_check_decl ()
2127{
2128 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
e7a30f46
DE
2129 as_decl_name=`echo $2|sed 's/ *(.*//'`
2130 as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
2131 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
2132$as_echo_n "checking whether $as_decl_name is declared... " >&6; }
81ecdfbb
RW
2133if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2134 $as_echo_n "(cached) " >&6
2135else
2136 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2137/* end confdefs.h. */
2138$4
2139int
2140main ()
2141{
e7a30f46
DE
2142#ifndef $as_decl_name
2143#ifdef __cplusplus
2144 (void) $as_decl_use;
2145#else
2146 (void) $as_decl_name;
2147#endif
81ecdfbb 2148#endif
bec39cab 2149
81ecdfbb
RW
2150 ;
2151 return 0;
2152}
bec39cab 2153_ACEOF
81ecdfbb
RW
2154if ac_fn_c_try_compile "$LINENO"; then :
2155 eval "$3=yes"
2156else
2157 eval "$3=no"
2158fi
2159rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2160fi
2161eval ac_res=\$$3
2162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2163$as_echo "$ac_res" >&6; }
2164 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
bec39cab 2165
81ecdfbb 2166} # ac_fn_c_check_decl
bec39cab 2167
81ecdfbb
RW
2168# ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2169# --------------------------------------------
2170# Tries to find the compile-time value of EXPR in a program that includes
2171# INCLUDES, setting VAR accordingly. Returns whether the value could be
2172# computed
2173ac_fn_c_compute_int ()
2174{
2175 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2176 if test "$cross_compiling" = yes; then
2177 # Depending upon the size, compute the lo and hi bounds.
2178cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2179/* end confdefs.h. */
2180$4
2181int
2182main ()
2183{
2184static int test_array [1 - 2 * !(($2) >= 0)];
2185test_array [0] = 0
bec39cab 2186
81ecdfbb
RW
2187 ;
2188 return 0;
2189}
2190_ACEOF
2191if ac_fn_c_try_compile "$LINENO"; then :
2192 ac_lo=0 ac_mid=0
2193 while :; do
2194 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2195/* end confdefs.h. */
2196$4
2197int
2198main ()
2199{
2200static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2201test_array [0] = 0
bec39cab 2202
81ecdfbb
RW
2203 ;
2204 return 0;
2205}
2206_ACEOF
2207if ac_fn_c_try_compile "$LINENO"; then :
2208 ac_hi=$ac_mid; break
2209else
2210 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2211 if test $ac_lo -le $ac_mid; then
2212 ac_lo= ac_hi=
2213 break
2214 fi
2215 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
c906108c 2216fi
81ecdfbb
RW
2217rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2218 done
c906108c 2219else
81ecdfbb
RW
2220 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2221/* end confdefs.h. */
2222$4
2223int
2224main ()
2225{
2226static int test_array [1 - 2 * !(($2) < 0)];
2227test_array [0] = 0
bec39cab 2228
81ecdfbb
RW
2229 ;
2230 return 0;
2231}
2232_ACEOF
2233if ac_fn_c_try_compile "$LINENO"; then :
2234 ac_hi=-1 ac_mid=-1
2235 while :; do
2236 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2237/* end confdefs.h. */
2238$4
2239int
2240main ()
2241{
2242static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2243test_array [0] = 0
bec39cab 2244
81ecdfbb
RW
2245 ;
2246 return 0;
2247}
2248_ACEOF
2249if ac_fn_c_try_compile "$LINENO"; then :
2250 ac_lo=$ac_mid; break
2251else
2252 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2253 if test $ac_mid -le $ac_hi; then
2254 ac_lo= ac_hi=
2255 break
2256 fi
2257 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2258fi
2259rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2260 done
2261else
2262 ac_lo= ac_hi=
2263fi
2264rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2265fi
2266rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2267# Binary search between lo and hi bounds.
2268while test "x$ac_lo" != "x$ac_hi"; do
2269 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2270 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2271/* end confdefs.h. */
2272$4
2273int
2274main ()
2275{
2276static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2277test_array [0] = 0
bec39cab 2278
81ecdfbb
RW
2279 ;
2280 return 0;
2281}
2282_ACEOF
2283if ac_fn_c_try_compile "$LINENO"; then :
2284 ac_hi=$ac_mid
2285else
2286 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2287fi
2288rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2289done
2290case $ac_lo in #((
2291?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2292'') ac_retval=1 ;;
2293esac
2294 else
2295 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2296/* end confdefs.h. */
2297$4
2298static long int longval () { return $2; }
2299static unsigned long int ulongval () { return $2; }
2300#include <stdio.h>
2301#include <stdlib.h>
2302int
2303main ()
2304{
bec39cab 2305
81ecdfbb
RW
2306 FILE *f = fopen ("conftest.val", "w");
2307 if (! f)
2308 return 1;
2309 if (($2) < 0)
2310 {
2311 long int i = longval ();
2312 if (i != ($2))
2313 return 1;
2314 fprintf (f, "%ld", i);
2315 }
2316 else
2317 {
2318 unsigned long int i = ulongval ();
2319 if (i != ($2))
2320 return 1;
2321 fprintf (f, "%lu", i);
2322 }
2323 /* Do not output a trailing newline, as this causes \r\n confusion
2324 on some platforms. */
2325 return ferror (f) || fclose (f) != 0;
bec39cab 2326
81ecdfbb
RW
2327 ;
2328 return 0;
2329}
2330_ACEOF
2331if ac_fn_c_try_run "$LINENO"; then :
2332 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2333else
2334 ac_retval=1
2335fi
2336rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2337 conftest.$ac_objext conftest.beam conftest.$ac_ext
2338rm -f conftest.val
bec39cab 2339
81ecdfbb
RW
2340 fi
2341 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2342 return $ac_retval
bec39cab 2343
81ecdfbb 2344} # ac_fn_c_compute_int
bec39cab 2345
81ecdfbb
RW
2346# ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2347# ----------------------------------------------------
2348# Tries to find if the field MEMBER exists in type AGGR, after including
2349# INCLUDES, setting cache variable VAR accordingly.
2350ac_fn_c_check_member ()
2351{
2352 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2353 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2354$as_echo_n "checking for $2.$3... " >&6; }
2355if { as_var=$4; eval "test \"\${$as_var+set}\" = set"; }; then :
2356 $as_echo_n "(cached) " >&6
2357else
2358 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2359/* end confdefs.h. */
2360$5
2361int
2362main ()
2363{
2364static $2 ac_aggr;
2365if (ac_aggr.$3)
2366return 0;
2367 ;
2368 return 0;
2369}
2370_ACEOF
2371if ac_fn_c_try_compile "$LINENO"; then :
2372 eval "$4=yes"
2373else
2374 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2375/* end confdefs.h. */
2376$5
2377int
2378main ()
2379{
2380static $2 ac_aggr;
2381if (sizeof ac_aggr.$3)
2382return 0;
2383 ;
2384 return 0;
2385}
2386_ACEOF
2387if ac_fn_c_try_compile "$LINENO"; then :
2388 eval "$4=yes"
2389else
2390 eval "$4=no"
2391fi
2392rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2393fi
2394rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2395fi
2396eval ac_res=\$$4
2397 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2398$as_echo "$ac_res" >&6; }
2399 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
bec39cab 2400
81ecdfbb 2401} # ac_fn_c_check_member
bec39cab 2402
81ecdfbb
RW
2403# ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2404# -------------------------------------------
2405# Tests whether TYPE exists after having included INCLUDES, setting cache
2406# variable VAR accordingly.
2407ac_fn_c_check_type ()
2408{
2409 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2410 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2411$as_echo_n "checking for $2... " >&6; }
2412if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2413 $as_echo_n "(cached) " >&6
2414else
2415 eval "$3=no"
2416 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2417/* end confdefs.h. */
2418$4
2419int
2420main ()
2421{
2422if (sizeof ($2))
2423 return 0;
2424 ;
2425 return 0;
2426}
2427_ACEOF
2428if ac_fn_c_try_compile "$LINENO"; then :
2429 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2430/* end confdefs.h. */
2431$4
2432int
2433main ()
2434{
2435if (sizeof (($2)))
2436 return 0;
2437 ;
2438 return 0;
2439}
2440_ACEOF
2441if ac_fn_c_try_compile "$LINENO"; then :
d5af19ba 2442
81ecdfbb
RW
2443else
2444 eval "$3=yes"
2445fi
2446rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2447fi
2448rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2449fi
2450eval ac_res=\$$3
2451 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2452$as_echo "$ac_res" >&6; }
2453 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
d5af19ba 2454
81ecdfbb
RW
2455} # ac_fn_c_check_type
2456cat >config.log <<_ACEOF
2457This file contains any messages produced by compilers while
2458running configure, to aid debugging if configure makes a mistake.
d5af19ba 2459
81ecdfbb
RW
2460It was created by $as_me, which was
2461generated by GNU Autoconf 2.64. Invocation command line was
b4e70030 2462
81ecdfbb 2463 $ $0 $@
413ccac7 2464
81ecdfbb
RW
2465_ACEOF
2466exec 5>>config.log
2467{
2468cat <<_ASUNAME
2469## --------- ##
2470## Platform. ##
2471## --------- ##
413ccac7 2472
81ecdfbb
RW
2473hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2474uname -m = `(uname -m) 2>/dev/null || echo unknown`
2475uname -r = `(uname -r) 2>/dev/null || echo unknown`
2476uname -s = `(uname -s) 2>/dev/null || echo unknown`
2477uname -v = `(uname -v) 2>/dev/null || echo unknown`
85981d60 2478
81ecdfbb
RW
2479/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2480/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
413ccac7 2481
81ecdfbb
RW
2482/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2483/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2484/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2485/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2486/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2487/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2488/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
c906108c 2489
81ecdfbb 2490_ASUNAME
bec39cab 2491
bec39cab
AC
2492as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2493for as_dir in $PATH
2494do
2495 IFS=$as_save_IFS
2496 test -z "$as_dir" && as_dir=.
81ecdfbb
RW
2497 $as_echo "PATH: $as_dir"
2498 done
2499IFS=$as_save_IFS
bec39cab 2500
81ecdfbb 2501} >&5
bec39cab 2502
81ecdfbb 2503cat >&5 <<_ACEOF
bec39cab 2504
bec39cab 2505
81ecdfbb
RW
2506## ----------- ##
2507## Core tests. ##
2508## ----------- ##
2509
2510_ACEOF
2511
2512
2513# Keep a trace of the command line.
2514# Strip out --no-create and --no-recursion so they do not pile up.
2515# Strip out --silent because we don't want to record it for future runs.
2516# Also quote any args containing shell meta-characters.
2517# Make two passes to allow for proper duplicate-argument suppression.
2518ac_configure_args=
2519ac_configure_args0=
2520ac_configure_args1=
2521ac_must_keep_next=false
2522for ac_pass in 1 2
2523do
2524 for ac_arg
2525 do
2526 case $ac_arg in
2527 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2528 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2529 | -silent | --silent | --silen | --sile | --sil)
2530 continue ;;
2531 *\'*)
2532 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2533 esac
2534 case $ac_pass in
2535 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2536 2)
2537 as_fn_append ac_configure_args1 " '$ac_arg'"
2538 if test $ac_must_keep_next = true; then
2539 ac_must_keep_next=false # Got value, back to normal.
2540 else
2541 case $ac_arg in
2542 *=* | --config-cache | -C | -disable-* | --disable-* \
2543 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2544 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2545 | -with-* | --with-* | -without-* | --without-* | --x)
2546 case "$ac_configure_args0 " in
2547 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2548 esac
2549 ;;
2550 -* ) ac_must_keep_next=true ;;
2551 esac
2552 fi
2553 as_fn_append ac_configure_args " '$ac_arg'"
2554 ;;
2555 esac
2556 done
2557done
2558{ ac_configure_args0=; unset ac_configure_args0;}
2559{ ac_configure_args1=; unset ac_configure_args1;}
2560
2561# When interrupted or exit'd, cleanup temporary files, and complete
2562# config.log. We remove comments because anyway the quotes in there
2563# would cause problems or look ugly.
2564# WARNING: Use '\'' to represent an apostrophe within the trap.
2565# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2566trap 'exit_status=$?
2567 # Save into config.log some information that might help in debugging.
2568 {
2569 echo
2570
2571 cat <<\_ASBOX
2572## ---------------- ##
2573## Cache variables. ##
2574## ---------------- ##
2575_ASBOX
2576 echo
2577 # The following way of writing the cache mishandles newlines in values,
2578(
2579 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2580 eval ac_val=\$$ac_var
2581 case $ac_val in #(
2582 *${as_nl}*)
2583 case $ac_var in #(
2584 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2585$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2586 esac
2587 case $ac_var in #(
2588 _ | IFS | as_nl) ;; #(
2589 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2590 *) { eval $ac_var=; unset $ac_var;} ;;
2591 esac ;;
2592 esac
2593 done
2594 (set) 2>&1 |
2595 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2596 *${as_nl}ac_space=\ *)
2597 sed -n \
2598 "s/'\''/'\''\\\\'\'''\''/g;
2599 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2600 ;; #(
2601 *)
2602 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2603 ;;
2604 esac |
2605 sort
2606)
2607 echo
2608
2609 cat <<\_ASBOX
2610## ----------------- ##
2611## Output variables. ##
2612## ----------------- ##
2613_ASBOX
2614 echo
2615 for ac_var in $ac_subst_vars
2616 do
2617 eval ac_val=\$$ac_var
2618 case $ac_val in
2619 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2620 esac
2621 $as_echo "$ac_var='\''$ac_val'\''"
2622 done | sort
2623 echo
2624
2625 if test -n "$ac_subst_files"; then
2626 cat <<\_ASBOX
2627## ------------------- ##
2628## File substitutions. ##
2629## ------------------- ##
2630_ASBOX
2631 echo
2632 for ac_var in $ac_subst_files
2633 do
2634 eval ac_val=\$$ac_var
2635 case $ac_val in
2636 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2637 esac
2638 $as_echo "$ac_var='\''$ac_val'\''"
2639 done | sort
2640 echo
2641 fi
2642
2643 if test -s confdefs.h; then
2644 cat <<\_ASBOX
2645## ----------- ##
2646## confdefs.h. ##
2647## ----------- ##
2648_ASBOX
2649 echo
2650 cat confdefs.h
2651 echo
2652 fi
2653 test "$ac_signal" != 0 &&
2654 $as_echo "$as_me: caught signal $ac_signal"
2655 $as_echo "$as_me: exit $exit_status"
2656 } >&5
2657 rm -f core *.core core.conftest.* &&
2658 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2659 exit $exit_status
2660' 0
2661for ac_signal in 1 2 13 15; do
2662 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2663done
2664ac_signal=0
2665
2666# confdefs.h avoids OS command line length limits that DEFS can exceed.
2667rm -f -r conftest* confdefs.h
2668
2669$as_echo "/* confdefs.h */" > confdefs.h
2670
2671# Predefined preprocessor variables.
2672
2673cat >>confdefs.h <<_ACEOF
2674#define PACKAGE_NAME "$PACKAGE_NAME"
2675_ACEOF
2676
2677cat >>confdefs.h <<_ACEOF
2678#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2679_ACEOF
2680
2681cat >>confdefs.h <<_ACEOF
2682#define PACKAGE_VERSION "$PACKAGE_VERSION"
2683_ACEOF
2684
2685cat >>confdefs.h <<_ACEOF
2686#define PACKAGE_STRING "$PACKAGE_STRING"
2687_ACEOF
2688
2689cat >>confdefs.h <<_ACEOF
2690#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2691_ACEOF
2692
2693cat >>confdefs.h <<_ACEOF
2694#define PACKAGE_URL "$PACKAGE_URL"
2695_ACEOF
2696
2697
2698# Let the site file select an alternate cache file if it wants to.
2699# Prefer an explicitly selected file to automatically selected ones.
2700ac_site_file1=NONE
2701ac_site_file2=NONE
2702if test -n "$CONFIG_SITE"; then
2703 ac_site_file1=$CONFIG_SITE
2704elif test "x$prefix" != xNONE; then
2705 ac_site_file1=$prefix/share/config.site
2706 ac_site_file2=$prefix/etc/config.site
2707else
2708 ac_site_file1=$ac_default_prefix/share/config.site
2709 ac_site_file2=$ac_default_prefix/etc/config.site
2710fi
2711for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2712do
2713 test "x$ac_site_file" = xNONE && continue
2714 if test -r "$ac_site_file"; then
2715 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2716$as_echo "$as_me: loading site script $ac_site_file" >&6;}
2717 sed 's/^/| /' "$ac_site_file" >&5
2718 . "$ac_site_file"
2719 fi
2720done
2721
2722if test -r "$cache_file"; then
2723 # Some versions of bash will fail to source /dev/null (special
2724 # files actually), so we avoid doing that.
2725 if test -f "$cache_file"; then
2726 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2727$as_echo "$as_me: loading cache $cache_file" >&6;}
2728 case $cache_file in
2729 [\\/]* | ?:[\\/]* ) . "$cache_file";;
2730 *) . "./$cache_file";;
2731 esac
2732 fi
2733else
2734 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2735$as_echo "$as_me: creating cache $cache_file" >&6;}
2736 >$cache_file
bec39cab
AC
2737fi
2738
f434ba03
PA
2739gl_header_list="$gl_header_list sys/mman.h"
2740gl_func_list="$gl_func_list mprotect"
2741gl_func_list="$gl_func_list memchr"
2742gl_header_list="$gl_header_list stddef.h"
81ecdfbb
RW
2743gl_header_list="$gl_header_list stdint.h"
2744gl_header_list="$gl_header_list wchar.h"
2745gl_header_list="$gl_header_list string.h"
2746# Check that the precious variables saved in the cache have kept the same
2747# value.
2748ac_cache_corrupted=false
2749for ac_var in $ac_precious_vars; do
2750 eval ac_old_set=\$ac_cv_env_${ac_var}_set
2751 eval ac_new_set=\$ac_env_${ac_var}_set
2752 eval ac_old_val=\$ac_cv_env_${ac_var}_value
2753 eval ac_new_val=\$ac_env_${ac_var}_value
2754 case $ac_old_set,$ac_new_set in
2755 set,)
2756 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2757$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2758 ac_cache_corrupted=: ;;
2759 ,set)
2760 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2761$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2762 ac_cache_corrupted=: ;;
2763 ,);;
2764 *)
2765 if test "x$ac_old_val" != "x$ac_new_val"; then
2766 # differences in whitespace do not lead to failure.
2767 ac_old_val_w=`echo x $ac_old_val`
2768 ac_new_val_w=`echo x $ac_new_val`
2769 if test "$ac_old_val_w" != "$ac_new_val_w"; then
2770 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2771$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2772 ac_cache_corrupted=:
2773 else
2774 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2775$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2776 eval $ac_var=\$ac_old_val
2777 fi
2778 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
2779$as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
2780 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
2781$as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
2782 fi;;
2783 esac
2784 # Pass precious variables to config.status.
2785 if test "$ac_new_set" = set; then
2786 case $ac_new_val in
2787 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2788 *) ac_arg=$ac_var=$ac_new_val ;;
2789 esac
2790 case " $ac_configure_args " in
2791 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
2792 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2793 esac
2794 fi
2795done
2796if $ac_cache_corrupted; then
2797 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2798$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2799 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2800$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2801 as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
2802fi
2803## -------------------- ##
2804## Main body of script. ##
2805## -------------------- ##
2806
2807ac_ext=c
2808ac_cpp='$CPP $CPPFLAGS'
2809ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2810ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2811ac_compiler_gnu=$ac_cv_c_compiler_gnu
2812
2813
2814
2815
2816
2817ac_config_headers="$ac_config_headers config.h:config.in"
2818
2819
2820{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5
2821$as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
2822 # Check whether --enable-maintainer-mode was given.
2823if test "${enable_maintainer_mode+set}" = set; then :
2824 enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
2825else
2826 USE_MAINTAINER_MODE=no
2827fi
2828
2829 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5
2830$as_echo "$USE_MAINTAINER_MODE" >&6; }
2831 if test $USE_MAINTAINER_MODE = yes; then
2832 MAINTAINER_MODE_TRUE=
2833 MAINTAINER_MODE_FALSE='#'
2834else
2835 MAINTAINER_MODE_TRUE='#'
2836 MAINTAINER_MODE_FALSE=
2837fi
2838
2839 MAINT=$MAINTAINER_MODE_TRUE
2840
2841
2842
2843ac_ext=c
2844ac_cpp='$CPP $CPPFLAGS'
2845ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2846ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2847ac_compiler_gnu=$ac_cv_c_compiler_gnu
2848if test -n "$ac_tool_prefix"; then
2849 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
2850set dummy ${ac_tool_prefix}gcc; ac_word=$2
2851{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2852$as_echo_n "checking for $ac_word... " >&6; }
2853if test "${ac_cv_prog_CC+set}" = set; then :
2854 $as_echo_n "(cached) " >&6
c906108c
SS
2855else
2856 if test -n "$CC"; then
2857 ac_cv_prog_CC="$CC" # Let the user override the test.
2858else
bec39cab
AC
2859as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2860for as_dir in $PATH
2861do
2862 IFS=$as_save_IFS
2863 test -z "$as_dir" && as_dir=.
81ecdfbb
RW
2864 for ac_exec_ext in '' $ac_executable_extensions; do
2865 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2866 ac_cv_prog_CC="${ac_tool_prefix}gcc"
2867 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
bec39cab
AC
2868 break 2
2869 fi
2870done
81ecdfbb
RW
2871 done
2872IFS=$as_save_IFS
bec39cab 2873
c906108c
SS
2874fi
2875fi
bec39cab 2876CC=$ac_cv_prog_CC
c906108c 2877if test -n "$CC"; then
81ecdfbb
RW
2878 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2879$as_echo "$CC" >&6; }
c906108c 2880else
81ecdfbb
RW
2881 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2882$as_echo "no" >&6; }
c906108c
SS
2883fi
2884
81ecdfbb 2885
b4e70030
JB
2886fi
2887if test -z "$ac_cv_prog_CC"; then
2888 ac_ct_CC=$CC
81ecdfbb
RW
2889 # Extract the first word of "gcc", so it can be a program name with args.
2890set dummy gcc; ac_word=$2
2891{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2892$as_echo_n "checking for $ac_word... " >&6; }
2893if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
2894 $as_echo_n "(cached) " >&6
b4e70030
JB
2895else
2896 if test -n "$ac_ct_CC"; then
2897 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2898else
2899as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2900for as_dir in $PATH
2901do
2902 IFS=$as_save_IFS
2903 test -z "$as_dir" && as_dir=.
81ecdfbb
RW
2904 for ac_exec_ext in '' $ac_executable_extensions; do
2905 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2906 ac_cv_prog_ac_ct_CC="gcc"
2907 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
b4e70030 2908 break 2
4e8d927d 2909 fi
b4e70030 2910done
81ecdfbb
RW
2911 done
2912IFS=$as_save_IFS
b4e70030
JB
2913
2914fi
2915fi
2916ac_ct_CC=$ac_cv_prog_ac_ct_CC
2917if test -n "$ac_ct_CC"; then
81ecdfbb
RW
2918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
2919$as_echo "$ac_ct_CC" >&6; }
b4e70030 2920else
81ecdfbb
RW
2921 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2922$as_echo "no" >&6; }
b4e70030
JB
2923fi
2924
81ecdfbb
RW
2925 if test "x$ac_ct_CC" = x; then
2926 CC=""
2927 else
2928 case $cross_compiling:$ac_tool_warned in
2929yes:)
2930{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
2931$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
2932ac_tool_warned=yes ;;
2933esac
2934 CC=$ac_ct_CC
2935 fi
b4e70030
JB
2936else
2937 CC="$ac_cv_prog_CC"
2938fi
2939
c906108c 2940if test -z "$CC"; then
81ecdfbb
RW
2941 if test -n "$ac_tool_prefix"; then
2942 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
2943set dummy ${ac_tool_prefix}cc; ac_word=$2
2944{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2945$as_echo_n "checking for $ac_word... " >&6; }
2946if test "${ac_cv_prog_CC+set}" = set; then :
2947 $as_echo_n "(cached) " >&6
c906108c
SS
2948else
2949 if test -n "$CC"; then
2950 ac_cv_prog_CC="$CC" # Let the user override the test.
2951else
bec39cab
AC
2952as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2953for as_dir in $PATH
2954do
2955 IFS=$as_save_IFS
2956 test -z "$as_dir" && as_dir=.
81ecdfbb
RW
2957 for ac_exec_ext in '' $ac_executable_extensions; do
2958 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2959 ac_cv_prog_CC="${ac_tool_prefix}cc"
2960 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
bec39cab
AC
2961 break 2
2962 fi
2963done
81ecdfbb
RW
2964 done
2965IFS=$as_save_IFS
2966
2967fi
2968fi
2969CC=$ac_cv_prog_CC
2970if test -n "$CC"; then
2971 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2972$as_echo "$CC" >&6; }
2973else
2974 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2975$as_echo "no" >&6; }
2976fi
2977
2978
2979 fi
2980fi
2981if test -z "$CC"; then
2982 # Extract the first word of "cc", so it can be a program name with args.
2983set dummy cc; ac_word=$2
2984{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2985$as_echo_n "checking for $ac_word... " >&6; }
2986if test "${ac_cv_prog_CC+set}" = set; then :
2987 $as_echo_n "(cached) " >&6
2988else
2989 if test -n "$CC"; then
2990 ac_cv_prog_CC="$CC" # Let the user override the test.
2991else
2992 ac_prog_rejected=no
2993as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2994for as_dir in $PATH
2995do
2996 IFS=$as_save_IFS
2997 test -z "$as_dir" && as_dir=.
2998 for ac_exec_ext in '' $ac_executable_extensions; do
2999 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3000 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
3001 ac_prog_rejected=yes
3002 continue
3003 fi
3004 ac_cv_prog_CC="cc"
3005 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3006 break 2
3007 fi
3008done
3009 done
3010IFS=$as_save_IFS
bec39cab 3011
c906108c
SS
3012if test $ac_prog_rejected = yes; then
3013 # We found a bogon in the path, so make sure we never use it.
3014 set dummy $ac_cv_prog_CC
3015 shift
bec39cab 3016 if test $# != 0; then
c906108c
SS
3017 # We chose a different compiler from the bogus one.
3018 # However, it has the same basename, so the bogon will be chosen
3019 # first if we set CC to just the basename; use the full file name.
3020 shift
bec39cab 3021 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
c906108c
SS
3022 fi
3023fi
3024fi
3025fi
bec39cab 3026CC=$ac_cv_prog_CC
c906108c 3027if test -n "$CC"; then
81ecdfbb
RW
3028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3029$as_echo "$CC" >&6; }
c906108c 3030else
81ecdfbb
RW
3031 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3032$as_echo "no" >&6; }
c906108c
SS
3033fi
3034
81ecdfbb 3035
bec39cab
AC
3036fi
3037if test -z "$CC"; then
3038 if test -n "$ac_tool_prefix"; then
81ecdfbb 3039 for ac_prog in cl.exe
bec39cab
AC
3040 do
3041 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3042set dummy $ac_tool_prefix$ac_prog; ac_word=$2
81ecdfbb
RW
3043{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3044$as_echo_n "checking for $ac_word... " >&6; }
3045if test "${ac_cv_prog_CC+set}" = set; then :
3046 $as_echo_n "(cached) " >&6
c906108c
SS
3047else
3048 if test -n "$CC"; then
3049 ac_cv_prog_CC="$CC" # Let the user override the test.
3050else
bec39cab
AC
3051as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3052for as_dir in $PATH
3053do
3054 IFS=$as_save_IFS
3055 test -z "$as_dir" && as_dir=.
81ecdfbb
RW
3056 for ac_exec_ext in '' $ac_executable_extensions; do
3057 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
bec39cab 3058 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
81ecdfbb 3059 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
bec39cab
AC
3060 break 2
3061 fi
3062done
81ecdfbb
RW
3063 done
3064IFS=$as_save_IFS
bec39cab 3065
c906108c
SS
3066fi
3067fi
bec39cab 3068CC=$ac_cv_prog_CC
c906108c 3069if test -n "$CC"; then
81ecdfbb
RW
3070 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3071$as_echo "$CC" >&6; }
c906108c 3072else
81ecdfbb
RW
3073 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3074$as_echo "no" >&6; }
c906108c 3075fi
bec39cab 3076
81ecdfbb 3077
bec39cab
AC
3078 test -n "$CC" && break
3079 done
3080fi
3081if test -z "$CC"; then
3082 ac_ct_CC=$CC
81ecdfbb 3083 for ac_prog in cl.exe
bec39cab
AC
3084do
3085 # Extract the first word of "$ac_prog", so it can be a program name with args.
3086set dummy $ac_prog; ac_word=$2
81ecdfbb
RW
3087{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3088$as_echo_n "checking for $ac_word... " >&6; }
3089if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
3090 $as_echo_n "(cached) " >&6
bec39cab
AC
3091else
3092 if test -n "$ac_ct_CC"; then
3093 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3094else
3095as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3096for as_dir in $PATH
3097do
3098 IFS=$as_save_IFS
3099 test -z "$as_dir" && as_dir=.
81ecdfbb
RW
3100 for ac_exec_ext in '' $ac_executable_extensions; do
3101 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
bec39cab 3102 ac_cv_prog_ac_ct_CC="$ac_prog"
81ecdfbb 3103 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
bec39cab 3104 break 2
c906108c 3105 fi
bec39cab 3106done
81ecdfbb
RW
3107 done
3108IFS=$as_save_IFS
bec39cab
AC
3109
3110fi
3111fi
3112ac_ct_CC=$ac_cv_prog_ac_ct_CC
3113if test -n "$ac_ct_CC"; then
81ecdfbb
RW
3114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3115$as_echo "$ac_ct_CC" >&6; }
bec39cab 3116else
81ecdfbb
RW
3117 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3118$as_echo "no" >&6; }
c906108c
SS
3119fi
3120
81ecdfbb 3121
bec39cab
AC
3122 test -n "$ac_ct_CC" && break
3123done
c906108c 3124
81ecdfbb
RW
3125 if test "x$ac_ct_CC" = x; then
3126 CC=""
3127 else
3128 case $cross_compiling:$ac_tool_warned in
3129yes:)
3130{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3131$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3132ac_tool_warned=yes ;;
3133esac
3134 CC=$ac_ct_CC
3135 fi
bec39cab
AC
3136fi
3137
3138fi
3139
3140
81ecdfbb
RW
3141test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3142$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3143as_fn_error "no acceptable C compiler found in \$PATH
3144See \`config.log' for more details." "$LINENO" 5; }
bec39cab
AC
3145
3146# Provide some information about the compiler.
81ecdfbb
RW
3147$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
3148set X $ac_compile
3149ac_compiler=$2
3150for ac_option in --version -v -V -qversion; do
3151 { { ac_try="$ac_compiler $ac_option >&5"
3152case "(($ac_try" in
3153 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3154 *) ac_try_echo=$ac_try;;
3155esac
3156eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3157$as_echo "$ac_try_echo"; } >&5
3158 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
bec39cab 3159 ac_status=$?
81ecdfbb
RW
3160 if test -s conftest.err; then
3161 sed '10a\
3162... rest of stderr output deleted ...
3163 10q' conftest.err >conftest.er1
3164 cat conftest.er1 >&5
3165 rm -f conftest.er1 conftest.err
3166 fi
3167 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3168 test $ac_status = 0; }
3169done
bec39cab 3170
81ecdfbb 3171cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab
AC
3172/* end confdefs.h. */
3173
3174int
3175main ()
3176{
3177
3178 ;
3179 return 0;
3180}
3181_ACEOF
3182ac_clean_files_save=$ac_clean_files
81ecdfbb 3183ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out conftest.out"
bec39cab
AC
3184# Try to create an executable without -o first, disregard a.out.
3185# It will help us diagnose broken compilers, and finding out an intuition
3186# of exeext.
81ecdfbb
RW
3187{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
3188$as_echo_n "checking for C compiler default output file name... " >&6; }
3189ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3190
3191# The possible output files:
3192ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3193
3194ac_rmfiles=
3195for ac_file in $ac_files
3196do
3197 case $ac_file in
3198 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3199 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3200 esac
3201done
3202rm -f $ac_rmfiles
3203
3204if { { ac_try="$ac_link_default"
3205case "(($ac_try" in
3206 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3207 *) ac_try_echo=$ac_try;;
3208esac
3209eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3210$as_echo "$ac_try_echo"; } >&5
3211 (eval "$ac_link_default") 2>&5
3212 ac_status=$?
3213 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3214 test $ac_status = 0; }; then :
3215 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3216# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3217# in a Makefile. We should not override ac_cv_exeext if it was cached,
3218# so that the user can short-circuit this test for compilers unknown to
3219# Autoconf.
3220for ac_file in $ac_files ''
bec39cab
AC
3221do
3222 test -f "$ac_file" || continue
3223 case $ac_file in
81ecdfbb 3224 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
b4e70030
JB
3225 ;;
3226 [ab].out )
3227 # We found the default executable, but exeext='' is most
3228 # certainly right.
3229 break;;
3230 *.* )
81ecdfbb
RW
3231 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3232 then :; else
3233 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3234 fi
3235 # We set ac_cv_exeext here because the later test for it is not
3236 # safe: cross compilers may not add the suffix if given an `-o'
3237 # argument, so we may need to know it at that point already.
3238 # Even if this section looks crufty: it has the advantage of
3239 # actually working.
b4e70030
JB
3240 break;;
3241 * )
3242 break;;
bec39cab
AC
3243 esac
3244done
81ecdfbb
RW
3245test "$ac_cv_exeext" = no && ac_cv_exeext=
3246
bec39cab 3247else
81ecdfbb
RW
3248 ac_file=''
3249fi
3250{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
3251$as_echo "$ac_file" >&6; }
3252if test -z "$ac_file"; then :
3253 $as_echo "$as_me: failed program was:" >&5
bec39cab
AC
3254sed 's/^/| /' conftest.$ac_ext >&5
3255
81ecdfbb
RW
3256{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3257$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3258{ as_fn_set_status 77
3259as_fn_error "C compiler cannot create executables
3260See \`config.log' for more details." "$LINENO" 5; }; }
bec39cab 3261fi
b4e70030 3262ac_exeext=$ac_cv_exeext
b4e70030 3263
81ecdfbb 3264# Check that the compiler produces executables we can run. If not, either
bec39cab 3265# the compiler is broken, or we cross compile.
81ecdfbb
RW
3266{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
3267$as_echo_n "checking whether the C compiler works... " >&6; }
bec39cab
AC
3268# If not cross compiling, check that we can run a simple program.
3269if test "$cross_compiling" != yes; then
3270 if { ac_try='./$ac_file'
81ecdfbb
RW
3271 { { case "(($ac_try" in
3272 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3273 *) ac_try_echo=$ac_try;;
3274esac
3275eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3276$as_echo "$ac_try_echo"; } >&5
3277 (eval "$ac_try") 2>&5
bec39cab 3278 ac_status=$?
81ecdfbb
RW
3279 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3280 test $ac_status = 0; }; }; then
bec39cab 3281 cross_compiling=no
c906108c 3282 else
bec39cab
AC
3283 if test "$cross_compiling" = maybe; then
3284 cross_compiling=yes
3285 else
81ecdfbb
RW
3286 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3287$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3288as_fn_error "cannot run C compiled programs.
bec39cab 3289If you meant to cross compile, use \`--host'.
81ecdfbb 3290See \`config.log' for more details." "$LINENO" 5; }
bec39cab 3291 fi
c906108c 3292 fi
bec39cab 3293fi
81ecdfbb
RW
3294{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3295$as_echo "yes" >&6; }
bec39cab 3296
81ecdfbb 3297rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out conftest.out
b4e70030 3298ac_clean_files=$ac_clean_files_save
81ecdfbb 3299# Check that the compiler produces executables we can run. If not, either
b4e70030 3300# the compiler is broken, or we cross compile.
81ecdfbb
RW
3301{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
3302$as_echo_n "checking whether we are cross compiling... " >&6; }
3303{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
3304$as_echo "$cross_compiling" >&6; }
3305
3306{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
3307$as_echo_n "checking for suffix of executables... " >&6; }
3308if { { ac_try="$ac_link"
3309case "(($ac_try" in
3310 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3311 *) ac_try_echo=$ac_try;;
3312esac
3313eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3314$as_echo "$ac_try_echo"; } >&5
3315 (eval "$ac_link") 2>&5
bec39cab 3316 ac_status=$?
81ecdfbb
RW
3317 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3318 test $ac_status = 0; }; then :
b4e70030
JB
3319 # If both `conftest.exe' and `conftest' are `present' (well, observable)
3320# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
3321# work properly (i.e., refer to `conftest.exe'), while it won't with
3322# `rm'.
3323for ac_file in conftest.exe conftest conftest.*; do
3324 test -f "$ac_file" || continue
3325 case $ac_file in
81ecdfbb 3326 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
b4e70030 3327 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
b4e70030
JB
3328 break;;
3329 * ) break;;
3330 esac
3331done
c906108c 3332else
81ecdfbb
RW
3333 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3334$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3335as_fn_error "cannot compute suffix of executables: cannot compile and link
3336See \`config.log' for more details." "$LINENO" 5; }
c906108c 3337fi
b4e70030 3338rm -f conftest$ac_cv_exeext
81ecdfbb
RW
3339{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
3340$as_echo "$ac_cv_exeext" >&6; }
c906108c 3341
b4e70030 3342rm -f conftest.$ac_ext
bec39cab
AC
3343EXEEXT=$ac_cv_exeext
3344ac_exeext=$EXEEXT
81ecdfbb
RW
3345{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
3346$as_echo_n "checking for suffix of object files... " >&6; }
3347if test "${ac_cv_objext+set}" = set; then :
3348 $as_echo_n "(cached) " >&6
bec39cab 3349else
81ecdfbb 3350 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
b4e70030
JB
3351/* end confdefs.h. */
3352
3353int
3354main ()
3355{
3356
3357 ;
3358 return 0;
3359}
3360_ACEOF
3361rm -f conftest.o conftest.obj
81ecdfbb
RW
3362if { { ac_try="$ac_compile"
3363case "(($ac_try" in
3364 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3365 *) ac_try_echo=$ac_try;;
3366esac
3367eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3368$as_echo "$ac_try_echo"; } >&5
3369 (eval "$ac_compile") 2>&5
3370 ac_status=$?
3371 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3372 test $ac_status = 0; }; then :
3373 for ac_file in conftest.o conftest.obj conftest.*; do
3374 test -f "$ac_file" || continue;
bec39cab 3375 case $ac_file in
81ecdfbb 3376 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
bec39cab
AC
3377 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3378 break;;
3379 esac
3380done
c906108c 3381else
81ecdfbb 3382 $as_echo "$as_me: failed program was:" >&5
bec39cab
AC
3383sed 's/^/| /' conftest.$ac_ext >&5
3384
81ecdfbb
RW
3385{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3386$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3387as_fn_error "cannot compute suffix of object files: cannot compile
3388See \`config.log' for more details." "$LINENO" 5; }
c906108c 3389fi
b4e70030 3390rm -f conftest.$ac_cv_objext conftest.$ac_ext
bec39cab 3391fi
81ecdfbb
RW
3392{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
3393$as_echo "$ac_cv_objext" >&6; }
bec39cab
AC
3394OBJEXT=$ac_cv_objext
3395ac_objext=$OBJEXT
81ecdfbb
RW
3396{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
3397$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
3398if test "${ac_cv_c_compiler_gnu+set}" = set; then :
3399 $as_echo_n "(cached) " >&6
c906108c 3400else
81ecdfbb 3401 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab
AC
3402/* end confdefs.h. */
3403
3404int
3405main ()
3406{
3407#ifndef __GNUC__
3408 choke me
3409#endif
3410
3411 ;
3412 return 0;
3413}
3414_ACEOF
81ecdfbb 3415if ac_fn_c_try_compile "$LINENO"; then :
bec39cab
AC
3416 ac_compiler_gnu=yes
3417else
81ecdfbb 3418 ac_compiler_gnu=no
bec39cab 3419fi
81ecdfbb 3420rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
bec39cab
AC
3421ac_cv_c_compiler_gnu=$ac_compiler_gnu
3422
3423fi
81ecdfbb
RW
3424{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
3425$as_echo "$ac_cv_c_compiler_gnu" >&6; }
3426if test $ac_compiler_gnu = yes; then
3427 GCC=yes
3428else
3429 GCC=
3430fi
bec39cab
AC
3431ac_test_CFLAGS=${CFLAGS+set}
3432ac_save_CFLAGS=$CFLAGS
81ecdfbb
RW
3433{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
3434$as_echo_n "checking whether $CC accepts -g... " >&6; }
3435if test "${ac_cv_prog_cc_g+set}" = set; then :
3436 $as_echo_n "(cached) " >&6
bec39cab 3437else
81ecdfbb
RW
3438 ac_save_c_werror_flag=$ac_c_werror_flag
3439 ac_c_werror_flag=yes
3440 ac_cv_prog_cc_g=no
3441 CFLAGS="-g"
3442 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab
AC
3443/* end confdefs.h. */
3444
3445int
3446main ()
3447{
3448
3449 ;
3450 return 0;
3451}
3452_ACEOF
81ecdfbb 3453if ac_fn_c_try_compile "$LINENO"; then :
c906108c
SS
3454 ac_cv_prog_cc_g=yes
3455else
81ecdfbb
RW
3456 CFLAGS=""
3457 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3458/* end confdefs.h. */
3459
3460int
3461main ()
3462{
3463
3464 ;
3465 return 0;
3466}
3467_ACEOF
3468if ac_fn_c_try_compile "$LINENO"; then :
3469
3470else
3471 ac_c_werror_flag=$ac_save_c_werror_flag
3472 CFLAGS="-g"
3473 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3474/* end confdefs.h. */
3475
3476int
3477main ()
3478{
c906108c 3479
81ecdfbb
RW
3480 ;
3481 return 0;
3482}
3483_ACEOF
3484if ac_fn_c_try_compile "$LINENO"; then :
3485 ac_cv_prog_cc_g=yes
3486fi
3487rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3488fi
3489rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4e8d927d 3490fi
81ecdfbb
RW
3491rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3492 ac_c_werror_flag=$ac_save_c_werror_flag
bec39cab 3493fi
81ecdfbb
RW
3494{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
3495$as_echo "$ac_cv_prog_cc_g" >&6; }
c906108c 3496if test "$ac_test_CFLAGS" = set; then
bec39cab 3497 CFLAGS=$ac_save_CFLAGS
c906108c
SS
3498elif test $ac_cv_prog_cc_g = yes; then
3499 if test "$GCC" = yes; then
3500 CFLAGS="-g -O2"
3501 else
3502 CFLAGS="-g"
3503 fi
3504else
3505 if test "$GCC" = yes; then
3506 CFLAGS="-O2"
3507 else
3508 CFLAGS=
3509 fi
3510fi
81ecdfbb
RW
3511{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
3512$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
3513if test "${ac_cv_prog_cc_c89+set}" = set; then :
3514 $as_echo_n "(cached) " >&6
bec39cab 3515else
81ecdfbb 3516 ac_cv_prog_cc_c89=no
bec39cab 3517ac_save_CC=$CC
81ecdfbb 3518cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 3519/* end confdefs.h. */
c906108c
SS
3520#include <stdarg.h>
3521#include <stdio.h>
3522#include <sys/types.h>
3523#include <sys/stat.h>
3524/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
3525struct buf { int x; };
3526FILE * (*rcsopen) (struct buf *, struct stat *, int);
3527static char *e (p, i)
3528 char **p;
3529 int i;
3530{
3531 return p[i];
3532}
3533static char *f (char * (*g) (char **, int), char **p, ...)
3534{
3535 char *s;
3536 va_list v;
3537 va_start (v,p);
3538 s = g (p, va_arg (v,int));
3539 va_end (v);
3540 return s;
3541}
bec39cab
AC
3542
3543/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
3544 function prototypes and stuff, but not '\xHH' hex character constants.
3545 These don't provoke an error unfortunately, instead are silently treated
81ecdfbb 3546 as 'x'. The following induces an error, until -std is added to get
bec39cab
AC
3547 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
3548 array size at least. It's necessary to write '\x00'==0 to get something
81ecdfbb 3549 that's true only with -std. */
bec39cab
AC
3550int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3551
81ecdfbb
RW
3552/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3553 inside strings and character constants. */
3554#define FOO(x) 'x'
3555int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3556
c906108c
SS
3557int test (int i, double x);
3558struct s1 {int (*f) (int a);};
3559struct s2 {int (*f) (double a);};
3560int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3561int argc;
3562char **argv;
bec39cab
AC
3563int
3564main ()
3565{
c906108c 3566return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
bec39cab
AC
3567 ;
3568 return 0;
3569}
3570_ACEOF
81ecdfbb
RW
3571for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3572 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
bec39cab
AC
3573do
3574 CC="$ac_save_CC $ac_arg"
81ecdfbb
RW
3575 if ac_fn_c_try_compile "$LINENO"; then :
3576 ac_cv_prog_cc_c89=$ac_arg
c906108c 3577fi
81ecdfbb
RW
3578rm -f core conftest.err conftest.$ac_objext
3579 test "x$ac_cv_prog_cc_c89" != "xno" && break
c906108c 3580done
81ecdfbb 3581rm -f conftest.$ac_ext
bec39cab 3582CC=$ac_save_CC
c906108c
SS
3583
3584fi
81ecdfbb
RW
3585# AC_CACHE_VAL
3586case "x$ac_cv_prog_cc_c89" in
3587 x)
3588 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
3589$as_echo "none needed" >&6; } ;;
3590 xno)
3591 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
3592$as_echo "unsupported" >&6; } ;;
bec39cab 3593 *)
81ecdfbb
RW
3594 CC="$CC $ac_cv_prog_cc_c89"
3595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
3596$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
c906108c 3597esac
81ecdfbb 3598if test "x$ac_cv_prog_cc_c89" != xno; then :
c906108c 3599
b4e70030
JB
3600fi
3601
bec39cab
AC
3602ac_ext=c
3603ac_cpp='$CPP $CPPFLAGS'
3604ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3605ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3606ac_compiler_gnu=$ac_cv_c_compiler_gnu
c906108c 3607
f434ba03
PA
3608ac_aux_dir=
3609for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
3610 for ac_t in install-sh install.sh shtool; do
3611 if test -f "$ac_dir/$ac_t"; then
3612 ac_aux_dir=$ac_dir
3613 ac_install_sh="$ac_aux_dir/$ac_t -c"
3614 break 2
3615 fi
3616 done
3617done
3618if test -z "$ac_aux_dir"; then
3619 as_fn_error "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
3620fi
3621
3622# These three variables are undocumented and unsupported,
3623# and are intended to be withdrawn in a future Autoconf release.
3624# They can cause serious problems if a builder's source tree is in a directory
3625# whose full name contains unusual characters.
3626ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
3627ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
3628ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
3629
3630
3631# Make sure we can run config.sub.
3632$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
3633 as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
3634
3635{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
3636$as_echo_n "checking build system type... " >&6; }
3637if test "${ac_cv_build+set}" = set; then :
3638 $as_echo_n "(cached) " >&6
3639else
3640 ac_build_alias=$build_alias
3641test "x$ac_build_alias" = x &&
3642 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
3643test "x$ac_build_alias" = x &&
3644 as_fn_error "cannot guess build type; you must specify one" "$LINENO" 5
3645ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
3646 as_fn_error "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
3647
3648fi
3649{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
3650$as_echo "$ac_cv_build" >&6; }
3651case $ac_cv_build in
3652*-*-*) ;;
3653*) as_fn_error "invalid value of canonical build" "$LINENO" 5;;
3654esac
3655build=$ac_cv_build
3656ac_save_IFS=$IFS; IFS='-'
3657set x $ac_cv_build
3658shift
3659build_cpu=$1
3660build_vendor=$2
3661shift; shift
3662# Remember, the first character of IFS is used to create $*,
3663# except with old shells:
3664build_os=$*
3665IFS=$ac_save_IFS
3666case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
3667
3668
3669{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
3670$as_echo_n "checking host system type... " >&6; }
3671if test "${ac_cv_host+set}" = set; then :
3672 $as_echo_n "(cached) " >&6
3673else
3674 if test "x$host_alias" = x; then
3675 ac_cv_host=$ac_cv_build
3676else
3677 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
3678 as_fn_error "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
3679fi
3680
3681fi
3682{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
3683$as_echo "$ac_cv_host" >&6; }
3684case $ac_cv_host in
3685*-*-*) ;;
3686*) as_fn_error "invalid value of canonical host" "$LINENO" 5;;
3687esac
3688host=$ac_cv_host
3689ac_save_IFS=$IFS; IFS='-'
3690set x $ac_cv_host
3691shift
3692host_cpu=$1
3693host_vendor=$2
3694shift; shift
3695# Remember, the first character of IFS is used to create $*,
3696# except with old shells:
3697host_os=$*
3698IFS=$ac_save_IFS
3699case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
3700
3701
60ca704f 3702
bec39cab
AC
3703ac_ext=c
3704ac_cpp='$CPP $CPPFLAGS'
3705ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3706ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3707ac_compiler_gnu=$ac_cv_c_compiler_gnu
81ecdfbb
RW
3708{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
3709$as_echo_n "checking how to run the C preprocessor... " >&6; }
bec39cab
AC
3710# On Suns, sometimes $CPP names a directory.
3711if test -n "$CPP" && test -d "$CPP"; then
3712 CPP=
8bb2c122 3713fi
bec39cab 3714if test -z "$CPP"; then
81ecdfbb
RW
3715 if test "${ac_cv_prog_CPP+set}" = set; then :
3716 $as_echo_n "(cached) " >&6
bec39cab
AC
3717else
3718 # Double quotes because CPP needs to be expanded
3719 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3720 do
3721 ac_preproc_ok=false
3722for ac_c_preproc_warn_flag in '' yes
3723do
3724 # Use a header file that comes with gcc, so configuring glibc
3725 # with a fresh cross-compiler works.
3726 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3727 # <limits.h> exists even on freestanding compilers.
3728 # On the NeXT, cc -E runs the code through the compiler's parser,
3729 # not just through cpp. "Syntax error" is here to catch this case.
81ecdfbb 3730 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab
AC
3731/* end confdefs.h. */
3732#ifdef __STDC__
3733# include <limits.h>
3734#else
3735# include <assert.h>
3736#endif
3737 Syntax error
3738_ACEOF
81ecdfbb 3739if ac_fn_c_try_cpp "$LINENO"; then :
bec39cab 3740
81ecdfbb 3741else
bec39cab
AC
3742 # Broken: fails on valid input.
3743continue
3744fi
3745rm -f conftest.err conftest.$ac_ext
3746
81ecdfbb 3747 # OK, works on sane cases. Now check whether nonexistent headers
bec39cab 3748 # can be detected and how.
81ecdfbb 3749 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab
AC
3750/* end confdefs.h. */
3751#include <ac_nonexistent.h>
3752_ACEOF
81ecdfbb 3753if ac_fn_c_try_cpp "$LINENO"; then :
bec39cab
AC
3754 # Broken: success on invalid input.
3755continue
8bb2c122 3756else
bec39cab
AC
3757 # Passes both tests.
3758ac_preproc_ok=:
3759break
8bb2c122 3760fi
bec39cab 3761rm -f conftest.err conftest.$ac_ext
8bb2c122 3762
bec39cab
AC
3763done
3764# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3765rm -f conftest.err conftest.$ac_ext
81ecdfbb 3766if $ac_preproc_ok; then :
bec39cab
AC
3767 break
3768fi
8bb2c122 3769
bec39cab
AC
3770 done
3771 ac_cv_prog_CPP=$CPP
ddc9cd0f 3772
c906108c 3773fi
bec39cab
AC
3774 CPP=$ac_cv_prog_CPP
3775else
3776 ac_cv_prog_CPP=$CPP
c906108c 3777fi
81ecdfbb
RW
3778{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
3779$as_echo "$CPP" >&6; }
bec39cab
AC
3780ac_preproc_ok=false
3781for ac_c_preproc_warn_flag in '' yes
3782do
3783 # Use a header file that comes with gcc, so configuring glibc
3784 # with a fresh cross-compiler works.
3785 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3786 # <limits.h> exists even on freestanding compilers.
3787 # On the NeXT, cc -E runs the code through the compiler's parser,
3788 # not just through cpp. "Syntax error" is here to catch this case.
81ecdfbb 3789 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab
AC
3790/* end confdefs.h. */
3791#ifdef __STDC__
3792# include <limits.h>
3793#else
3794# include <assert.h>
3795#endif
3796 Syntax error
3797_ACEOF
81ecdfbb 3798if ac_fn_c_try_cpp "$LINENO"; then :
bec39cab 3799
81ecdfbb 3800else
bec39cab
AC
3801 # Broken: fails on valid input.
3802continue
3803fi
3804rm -f conftest.err conftest.$ac_ext
3805
81ecdfbb 3806 # OK, works on sane cases. Now check whether nonexistent headers
bec39cab 3807 # can be detected and how.
81ecdfbb 3808 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab
AC
3809/* end confdefs.h. */
3810#include <ac_nonexistent.h>
3811_ACEOF
81ecdfbb 3812if ac_fn_c_try_cpp "$LINENO"; then :
bec39cab
AC
3813 # Broken: success on invalid input.
3814continue
c906108c 3815else
bec39cab
AC
3816 # Passes both tests.
3817ac_preproc_ok=:
3818break
c906108c 3819fi
bec39cab 3820rm -f conftest.err conftest.$ac_ext
c906108c 3821
bec39cab
AC
3822done
3823# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3824rm -f conftest.err conftest.$ac_ext
81ecdfbb
RW
3825if $ac_preproc_ok; then :
3826
c906108c 3827else
81ecdfbb
RW
3828 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3829$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3830as_fn_error "C preprocessor \"$CPP\" fails sanity check
3831See \`config.log' for more details." "$LINENO" 5; }
c906108c 3832fi
c906108c 3833
bec39cab
AC
3834ac_ext=c
3835ac_cpp='$CPP $CPPFLAGS'
3836ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3837ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3838ac_compiler_gnu=$ac_cv_c_compiler_gnu
3839
3840
81ecdfbb
RW
3841{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
3842$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
3843if test "${ac_cv_path_GREP+set}" = set; then :
3844 $as_echo_n "(cached) " >&6
4e8d927d 3845else
81ecdfbb
RW
3846 if test -z "$GREP"; then
3847 ac_path_GREP_found=false
3848 # Loop through the user's path and test for each of PROGNAME-LIST
3849 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3850for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
3851do
3852 IFS=$as_save_IFS
3853 test -z "$as_dir" && as_dir=.
3854 for ac_prog in grep ggrep; do
3855 for ac_exec_ext in '' $ac_executable_extensions; do
3856 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
3857 { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
3858# Check for GNU ac_path_GREP and select it if it is found.
3859 # Check for GNU $ac_path_GREP
3860case `"$ac_path_GREP" --version 2>&1` in
3861*GNU*)
3862 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
3863*)
3864 ac_count=0
3865 $as_echo_n 0123456789 >"conftest.in"
3866 while :
3867 do
3868 cat "conftest.in" "conftest.in" >"conftest.tmp"
3869 mv "conftest.tmp" "conftest.in"
3870 cp "conftest.in" "conftest.nl"
3871 $as_echo 'GREP' >> "conftest.nl"
3872 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
3873 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
3874 as_fn_arith $ac_count + 1 && ac_count=$as_val
3875 if test $ac_count -gt ${ac_path_GREP_max-0}; then
3876 # Best one so far, save it but keep looking for a better one
3877 ac_cv_path_GREP="$ac_path_GREP"
3878 ac_path_GREP_max=$ac_count
bec39cab 3879 fi
81ecdfbb
RW
3880 # 10*(2^10) chars as input seems more than enough
3881 test $ac_count -gt 10 && break
3882 done
3883 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
3884esac
bec39cab 3885
81ecdfbb
RW
3886 $ac_path_GREP_found && break 3
3887 done
3888 done
3889 done
3890IFS=$as_save_IFS
3891 if test -z "$ac_cv_path_GREP"; then
3892 as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
3893 fi
c906108c 3894else
81ecdfbb 3895 ac_cv_path_GREP=$GREP
c906108c 3896fi
c906108c 3897
81ecdfbb
RW
3898fi
3899{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
3900$as_echo "$ac_cv_path_GREP" >&6; }
3901 GREP="$ac_cv_path_GREP"
c906108c 3902
c906108c 3903
81ecdfbb
RW
3904{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
3905$as_echo_n "checking for egrep... " >&6; }
3906if test "${ac_cv_path_EGREP+set}" = set; then :
3907 $as_echo_n "(cached) " >&6
783e057b 3908else
81ecdfbb
RW
3909 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
3910 then ac_cv_path_EGREP="$GREP -E"
3911 else
3912 if test -z "$EGREP"; then
3913 ac_path_EGREP_found=false
3914 # Loop through the user's path and test for each of PROGNAME-LIST
3915 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3916for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
783e057b
DJ
3917do
3918 IFS=$as_save_IFS
3919 test -z "$as_dir" && as_dir=.
81ecdfbb
RW
3920 for ac_prog in egrep; do
3921 for ac_exec_ext in '' $ac_executable_extensions; do
3922 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
3923 { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
3924# Check for GNU ac_path_EGREP and select it if it is found.
3925 # Check for GNU $ac_path_EGREP
3926case `"$ac_path_EGREP" --version 2>&1` in
3927*GNU*)
3928 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
3929*)
3930 ac_count=0
3931 $as_echo_n 0123456789 >"conftest.in"
3932 while :
3933 do
3934 cat "conftest.in" "conftest.in" >"conftest.tmp"
3935 mv "conftest.tmp" "conftest.in"
3936 cp "conftest.in" "conftest.nl"
3937 $as_echo 'EGREP' >> "conftest.nl"
3938 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
3939 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
3940 as_fn_arith $ac_count + 1 && ac_count=$as_val
3941 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
3942 # Best one so far, save it but keep looking for a better one
3943 ac_cv_path_EGREP="$ac_path_EGREP"
3944 ac_path_EGREP_max=$ac_count
3945 fi
3946 # 10*(2^10) chars as input seems more than enough
3947 test $ac_count -gt 10 && break
3948 done
3949 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
3950esac
bec39cab 3951
81ecdfbb
RW
3952 $ac_path_EGREP_found && break 3
3953 done
3954 done
3955 done
3956IFS=$as_save_IFS
3957 if test -z "$ac_cv_path_EGREP"; then
3958 as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
783e057b 3959 fi
783e057b 3960else
81ecdfbb 3961 ac_cv_path_EGREP=$EGREP
783e057b
DJ
3962fi
3963
81ecdfbb 3964 fi
783e057b 3965fi
81ecdfbb
RW
3966{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
3967$as_echo "$ac_cv_path_EGREP" >&6; }
3968 EGREP="$ac_cv_path_EGREP"
3969
783e057b 3970
81ecdfbb
RW
3971{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
3972$as_echo_n "checking for ANSI C header files... " >&6; }
3973if test "${ac_cv_header_stdc+set}" = set; then :
3974 $as_echo_n "(cached) " >&6
783e057b 3975else
81ecdfbb 3976 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 3977/* end confdefs.h. */
783e057b 3978#include <stdlib.h>
bec39cab 3979#include <stdarg.h>
783e057b
DJ
3980#include <string.h>
3981#include <float.h>
c906108c 3982
bec39cab
AC
3983int
3984main ()
3985{
c906108c 3986
bec39cab
AC
3987 ;
3988 return 0;
3989}
3990_ACEOF
81ecdfbb 3991if ac_fn_c_try_compile "$LINENO"; then :
783e057b 3992 ac_cv_header_stdc=yes
c906108c 3993else
81ecdfbb 3994 ac_cv_header_stdc=no
c906108c 3995fi
81ecdfbb 3996rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
c906108c 3997
783e057b
DJ
3998if test $ac_cv_header_stdc = yes; then
3999 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
81ecdfbb 4000 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
783e057b
DJ
4001/* end confdefs.h. */
4002#include <string.h>
c906108c 4003
783e057b
DJ
4004_ACEOF
4005if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
81ecdfbb
RW
4006 $EGREP "memchr" >/dev/null 2>&1; then :
4007
c906108c 4008else
783e057b 4009 ac_cv_header_stdc=no
c906108c 4010fi
783e057b 4011rm -f conftest*
c906108c
SS
4012
4013fi
4014
783e057b
DJ
4015if test $ac_cv_header_stdc = yes; then
4016 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
81ecdfbb 4017 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
783e057b
DJ
4018/* end confdefs.h. */
4019#include <stdlib.h>
bec39cab 4020
783e057b
DJ
4021_ACEOF
4022if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
81ecdfbb
RW
4023 $EGREP "free" >/dev/null 2>&1; then :
4024
bec39cab 4025else
783e057b 4026 ac_cv_header_stdc=no
bec39cab 4027fi
783e057b 4028rm -f conftest*
bec39cab
AC
4029
4030fi
bec39cab 4031
783e057b
DJ
4032if test $ac_cv_header_stdc = yes; then
4033 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
81ecdfbb 4034 if test "$cross_compiling" = yes; then :
783e057b 4035 :
bec39cab 4036else
81ecdfbb 4037 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
783e057b
DJ
4038/* end confdefs.h. */
4039#include <ctype.h>
81ecdfbb 4040#include <stdlib.h>
783e057b
DJ
4041#if ((' ' & 0x0FF) == 0x020)
4042# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4043# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4044#else
4045# define ISLOWER(c) \
4046 (('a' <= (c) && (c) <= 'i') \
4047 || ('j' <= (c) && (c) <= 'r') \
4048 || ('s' <= (c) && (c) <= 'z'))
4049# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4050#endif
4051
4052#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4053int
4054main ()
4055{
4056 int i;
4057 for (i = 0; i < 256; i++)
4058 if (XOR (islower (i), ISLOWER (i))
4059 || toupper (i) != TOUPPER (i))
81ecdfbb
RW
4060 return 2;
4061 return 0;
783e057b
DJ
4062}
4063_ACEOF
81ecdfbb 4064if ac_fn_c_try_run "$LINENO"; then :
783e057b 4065
81ecdfbb
RW
4066else
4067 ac_cv_header_stdc=no
783e057b 4068fi
81ecdfbb
RW
4069rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
4070 conftest.$ac_objext conftest.beam conftest.$ac_ext
783e057b 4071fi
81ecdfbb 4072
783e057b
DJ
4073fi
4074fi
81ecdfbb
RW
4075{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
4076$as_echo "$ac_cv_header_stdc" >&6; }
783e057b
DJ
4077if test $ac_cv_header_stdc = yes; then
4078
81ecdfbb 4079$as_echo "#define STDC_HEADERS 1" >>confdefs.h
783e057b
DJ
4080
4081fi
4082
4083# On IRIX 5.3, sys/types and inttypes.h are conflicting.
783e057b
DJ
4084for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
4085 inttypes.h stdint.h unistd.h
81ecdfbb
RW
4086do :
4087 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
4088ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
4089"
4090eval as_val=\$$as_ac_Header
4091 if test "x$as_val" = x""yes; then :
783e057b 4092 cat >>confdefs.h <<_ACEOF
81ecdfbb 4093#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
783e057b
DJ
4094_ACEOF
4095
4096fi
4097
4098done
4099
4100
4101
f434ba03
PA
4102
4103
81ecdfbb
RW
4104 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
4105if test "x$ac_cv_header_minix_config_h" = x""yes; then :
783e057b
DJ
4106 MINIX=yes
4107else
4108 MINIX=
4109fi
4110
4111
4112 if test "$MINIX" = yes; then
4113
81ecdfbb 4114$as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
783e057b
DJ
4115
4116
81ecdfbb 4117$as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
783e057b
DJ
4118
4119
81ecdfbb 4120$as_echo "#define _MINIX 1" >>confdefs.h
783e057b
DJ
4121
4122 fi
4123
f434ba03
PA
4124 case "$host_os" in
4125 hpux*)
4126
4127$as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h
4128
4129 ;;
4130 esac
4131
783e057b 4132
81ecdfbb
RW
4133 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
4134$as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
4135if test "${ac_cv_safe_to_define___extensions__+set}" = set; then :
4136 $as_echo_n "(cached) " >&6
783e057b 4137else
81ecdfbb 4138 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
783e057b
DJ
4139/* end confdefs.h. */
4140
f434ba03
PA
4141# define __EXTENSIONS__ 1
4142 $ac_includes_default
783e057b
DJ
4143int
4144main ()
4145{
4146
4147 ;
4148 return 0;
4149}
4150_ACEOF
81ecdfbb 4151if ac_fn_c_try_compile "$LINENO"; then :
783e057b
DJ
4152 ac_cv_safe_to_define___extensions__=yes
4153else
81ecdfbb 4154 ac_cv_safe_to_define___extensions__=no
783e057b 4155fi
81ecdfbb 4156rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
783e057b 4157fi
81ecdfbb
RW
4158{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
4159$as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
783e057b 4160 test $ac_cv_safe_to_define___extensions__ = yes &&
81ecdfbb 4161 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
783e057b 4162
81ecdfbb 4163 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
783e057b 4164
81ecdfbb 4165 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
783e057b 4166
81ecdfbb 4167 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
783e057b 4168
81ecdfbb 4169 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
783e057b
DJ
4170
4171
81ecdfbb
RW
4172if test -n "$ac_tool_prefix"; then
4173 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
4174set dummy ${ac_tool_prefix}ranlib; ac_word=$2
4175{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4176$as_echo_n "checking for $ac_word... " >&6; }
4177if test "${ac_cv_prog_RANLIB+set}" = set; then :
4178 $as_echo_n "(cached) " >&6
4179else
4180 if test -n "$RANLIB"; then
4181 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
4182else
4183as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4184for as_dir in $PATH
4185do
4186 IFS=$as_save_IFS
4187 test -z "$as_dir" && as_dir=.
4188 for ac_exec_ext in '' $ac_executable_extensions; do
4189 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4190 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
4191 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4192 break 2
4193 fi
4194done
4195 done
4196IFS=$as_save_IFS
783e057b 4197
81ecdfbb
RW
4198fi
4199fi
4200RANLIB=$ac_cv_prog_RANLIB
4201if test -n "$RANLIB"; then
4202 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
4203$as_echo "$RANLIB" >&6; }
4204else
4205 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4206$as_echo "no" >&6; }
4207fi
783e057b
DJ
4208
4209
81ecdfbb
RW
4210fi
4211if test -z "$ac_cv_prog_RANLIB"; then
4212 ac_ct_RANLIB=$RANLIB
4213 # Extract the first word of "ranlib", so it can be a program name with args.
4214set dummy ranlib; ac_word=$2
4215{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4216$as_echo_n "checking for $ac_word... " >&6; }
4217if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
4218 $as_echo_n "(cached) " >&6
783e057b 4219else
81ecdfbb
RW
4220 if test -n "$ac_ct_RANLIB"; then
4221 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
4222else
4223as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4224for as_dir in $PATH
4225do
4226 IFS=$as_save_IFS
4227 test -z "$as_dir" && as_dir=.
4228 for ac_exec_ext in '' $ac_executable_extensions; do
4229 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4230 ac_cv_prog_ac_ct_RANLIB="ranlib"
4231 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4232 break 2
4233 fi
4234done
4235 done
4236IFS=$as_save_IFS
4237
4238fi
4239fi
4240ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
4241if test -n "$ac_ct_RANLIB"; then
4242 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
4243$as_echo "$ac_ct_RANLIB" >&6; }
4244else
4245 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4246$as_echo "no" >&6; }
4247fi
4248
4249 if test "x$ac_ct_RANLIB" = x; then
4250 RANLIB=":"
4251 else
4252 case $cross_compiling:$ac_tool_warned in
4253yes:)
4254{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4255$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4256ac_tool_warned=yes ;;
4257esac
4258 RANLIB=$ac_ct_RANLIB
4259 fi
4260else
4261 RANLIB="$ac_cv_prog_RANLIB"
4262fi
4263
4264
4265
4266
4267
4268
3388710e
JM
4269
4270
3388710e 4271
f434ba03
PA
4272 # Code from module arg-nonnull:
4273 # Code from module c++defs:
4274 # Code from module extensions:
3388710e 4275
f434ba03
PA
4276 # Code from module include_next:
4277 # Code from module memchr:
4278 # Code from module memmem:
4279 # Code from module memmem-simple:
4280 # Code from module multiarch:
4281 # Code from module stddef:
4282 # Code from module stdint:
4283 # Code from module string:
4284 # Code from module warn-on-use:
4285 # Code from module wchar:
3388710e
JM
4286
4287{ $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
4288$as_echo_n "checking target system type... " >&6; }
4289if test "${ac_cv_target+set}" = set; then :
4290 $as_echo_n "(cached) " >&6
4291else
4292 if test "x$target_alias" = x; then
4293 ac_cv_target=$ac_cv_host
4294else
4295 ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
4296 as_fn_error "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
4297fi
4298
4299fi
4300{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
4301$as_echo "$ac_cv_target" >&6; }
4302case $ac_cv_target in
4303*-*-*) ;;
4304*) as_fn_error "invalid value of canonical target" "$LINENO" 5;;
4305esac
4306target=$ac_cv_target
4307ac_save_IFS=$IFS; IFS='-'
4308set x $ac_cv_target
4309shift
4310target_cpu=$1
4311target_vendor=$2
4312shift; shift
4313# Remember, the first character of IFS is used to create $*,
4314# except with old shells:
4315target_os=$*
4316IFS=$ac_save_IFS
4317case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
4318
4319
4320# The aliases save the names the user supplied, while $host etc.
4321# will get canonicalized.
4322test -n "$target_alias" &&
4323 test "$program_prefix$program_suffix$program_transform_name" = \
4324 NONENONEs,x,x, &&
4325 program_prefix=${target_alias}-
4326
4327# The tests for host and target for $enable_largefile require
4328# canonical names.
4329
4330
81ecdfbb 4331
da2f07f1
JK
4332# As the $enable_largefile decision depends on --enable-plugins we must set it
4333# even in directories otherwise not depending on the $plugins option.
4334
4335
4336# Check whether --enable-plugins was given.
4337if test "${enable_plugins+set}" = set; then :
4338 enableval=$enable_plugins; case "${enableval}" in
4339 yes | "") plugins=yes ;;
4340 no) plugins=no ;;
4341 *) plugins=yes ;;
4342 esac
4343else
4344 plugins=no
4345fi
4346
4347
4348
4349case "${host}" in
4350 sparc-*-solaris*|i[3-7]86-*-solaris*)
4351 # On native 32bit sparc and ia32 solaris, large-file and procfs support
4352 # are mutually exclusive; and without procfs support, the bfd/ elf module
4353 # cannot provide certain routines such as elfcore_write_prpsinfo
4354 # or elfcore_write_prstatus. So unless the user explicitly requested
4355 # large-file support through the --enable-largefile switch, disable
4356 # large-file support in favor of procfs support.
4357 test "${target}" = "${host}" -a "x$plugins" = xno \
4358 && : ${enable_largefile="no"}
4359 ;;
4360esac
4361
4362# Check whether --enable-largefile was given.
4363if test "${enable_largefile+set}" = set; then :
4364 enableval=$enable_largefile;
4365fi
4366
4367if test "$enable_largefile" != no; then
4368
4369 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
4370$as_echo_n "checking for special C compiler options needed for large files... " >&6; }
4371if test "${ac_cv_sys_largefile_CC+set}" = set; then :
4372 $as_echo_n "(cached) " >&6
4373else
4374 ac_cv_sys_largefile_CC=no
4375 if test "$GCC" != yes; then
4376 ac_save_CC=$CC
4377 while :; do
4378 # IRIX 6.2 and later do not support large files by default,
4379 # so use the C compiler's -n32 option if that helps.
4380 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4381/* end confdefs.h. */
4382#include <sys/types.h>
4383 /* Check that off_t can represent 2**63 - 1 correctly.
4384 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4385 since some C++ compilers masquerading as C compilers
4386 incorrectly reject 9223372036854775807. */
4387#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4388 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4389 && LARGE_OFF_T % 2147483647 == 1)
4390 ? 1 : -1];
4391int
4392main ()
4393{
4394
4395 ;
4396 return 0;
4397}
4398_ACEOF
4399 if ac_fn_c_try_compile "$LINENO"; then :
4400 break
4401fi
4402rm -f core conftest.err conftest.$ac_objext
4403 CC="$CC -n32"
4404 if ac_fn_c_try_compile "$LINENO"; then :
4405 ac_cv_sys_largefile_CC=' -n32'; break
4406fi
4407rm -f core conftest.err conftest.$ac_objext
4408 break
4409 done
4410 CC=$ac_save_CC
4411 rm -f conftest.$ac_ext
4412 fi
4413fi
4414{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
4415$as_echo "$ac_cv_sys_largefile_CC" >&6; }
4416 if test "$ac_cv_sys_largefile_CC" != no; then
4417 CC=$CC$ac_cv_sys_largefile_CC
4418 fi
4419
4420 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
4421$as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
4422if test "${ac_cv_sys_file_offset_bits+set}" = set; then :
4423 $as_echo_n "(cached) " >&6
4424else
4425 while :; do
4426 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4427/* end confdefs.h. */
4428#include <sys/types.h>
4429 /* Check that off_t can represent 2**63 - 1 correctly.
4430 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4431 since some C++ compilers masquerading as C compilers
4432 incorrectly reject 9223372036854775807. */
4433#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4434 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4435 && LARGE_OFF_T % 2147483647 == 1)
4436 ? 1 : -1];
4437int
4438main ()
4439{
4440
4441 ;
4442 return 0;
4443}
4444_ACEOF
4445if ac_fn_c_try_compile "$LINENO"; then :
4446 ac_cv_sys_file_offset_bits=no; break
4447fi
4448rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4449 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4450/* end confdefs.h. */
4451#define _FILE_OFFSET_BITS 64
4452#include <sys/types.h>
4453 /* Check that off_t can represent 2**63 - 1 correctly.
4454 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4455 since some C++ compilers masquerading as C compilers
4456 incorrectly reject 9223372036854775807. */
4457#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4458 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4459 && LARGE_OFF_T % 2147483647 == 1)
4460 ? 1 : -1];
4461int
4462main ()
4463{
4464
4465 ;
4466 return 0;
4467}
4468_ACEOF
4469if ac_fn_c_try_compile "$LINENO"; then :
4470 ac_cv_sys_file_offset_bits=64; break
4471fi
4472rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4473 ac_cv_sys_file_offset_bits=unknown
4474 break
4475done
4476fi
4477{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
4478$as_echo "$ac_cv_sys_file_offset_bits" >&6; }
4479case $ac_cv_sys_file_offset_bits in #(
4480 no | unknown) ;;
4481 *)
4482cat >>confdefs.h <<_ACEOF
4483#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
4484_ACEOF
4485;;
4486esac
4487rm -rf conftest*
4488 if test $ac_cv_sys_file_offset_bits = unknown; then
4489 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
4490$as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
4491if test "${ac_cv_sys_large_files+set}" = set; then :
4492 $as_echo_n "(cached) " >&6
4493else
4494 while :; do
4495 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4496/* end confdefs.h. */
4497#include <sys/types.h>
4498 /* Check that off_t can represent 2**63 - 1 correctly.
4499 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4500 since some C++ compilers masquerading as C compilers
4501 incorrectly reject 9223372036854775807. */
4502#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4503 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4504 && LARGE_OFF_T % 2147483647 == 1)
4505 ? 1 : -1];
4506int
4507main ()
4508{
4509
4510 ;
4511 return 0;
4512}
4513_ACEOF
4514if ac_fn_c_try_compile "$LINENO"; then :
4515 ac_cv_sys_large_files=no; break
4516fi
4517rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4518 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4519/* end confdefs.h. */
4520#define _LARGE_FILES 1
4521#include <sys/types.h>
4522 /* Check that off_t can represent 2**63 - 1 correctly.
4523 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4524 since some C++ compilers masquerading as C compilers
4525 incorrectly reject 9223372036854775807. */
4526#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4527 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4528 && LARGE_OFF_T % 2147483647 == 1)
4529 ? 1 : -1];
4530int
4531main ()
4532{
4533
4534 ;
4535 return 0;
4536}
4537_ACEOF
4538if ac_fn_c_try_compile "$LINENO"; then :
4539 ac_cv_sys_large_files=1; break
4540fi
4541rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4542 ac_cv_sys_large_files=unknown
4543 break
4544done
4545fi
4546{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
4547$as_echo "$ac_cv_sys_large_files" >&6; }
4548case $ac_cv_sys_large_files in #(
4549 no | unknown) ;;
4550 *)
4551cat >>confdefs.h <<_ACEOF
4552#define _LARGE_FILES $ac_cv_sys_large_files
4553_ACEOF
4554;;
4555esac
4556rm -rf conftest*
4557 fi
4558fi
4559
4560
4561
81ecdfbb
RW
4562
4563
4564{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${CC-cc} option to accept ANSI C" >&5
4565$as_echo_n "checking for ${CC-cc} option to accept ANSI C... " >&6; }
4566if test "${am_cv_prog_cc_stdc+set}" = set; then :
4567 $as_echo_n "(cached) " >&6
4568else
4569 am_cv_prog_cc_stdc=no
4570ac_save_CC="$CC"
4571# Don't try gcc -ansi; that turns off useful extensions and
4572# breaks some systems' header files.
4573# AIX -qlanglvl=ansi
4574# Ultrix and OSF/1 -std1
4575# HP-UX 10.20 and later -Ae
4576# HP-UX older versions -Aa -D_HPUX_SOURCE
4577# SVR4 -Xc -D__EXTENSIONS__
4578for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4579do
783e057b 4580 CC="$ac_save_CC $ac_arg"
81ecdfbb 4581 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
783e057b
DJ
4582/* end confdefs.h. */
4583#include <stdarg.h>
4584#include <stdio.h>
4585#include <sys/types.h>
4586#include <sys/stat.h>
4587/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
4588struct buf { int x; };
4589FILE * (*rcsopen) (struct buf *, struct stat *, int);
4590static char *e (p, i)
4591 char **p;
4592 int i;
4593{
4594 return p[i];
4595}
4596static char *f (char * (*g) (char **, int), char **p, ...)
4597{
4598 char *s;
4599 va_list v;
4600 va_start (v,p);
4601 s = g (p, va_arg (v,int));
4602 va_end (v);
4603 return s;
4604}
4605int test (int i, double x);
4606struct s1 {int (*f) (int a);};
4607struct s2 {int (*f) (double a);};
4608int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4609int argc;
4610char **argv;
4611
4612int
4613main ()
4614{
4615
4616return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
4617
4618 ;
4619 return 0;
4620}
4621_ACEOF
81ecdfbb 4622if ac_fn_c_try_compile "$LINENO"; then :
783e057b 4623 am_cv_prog_cc_stdc="$ac_arg"; break
783e057b 4624fi
81ecdfbb 4625rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
783e057b
DJ
4626done
4627CC="$ac_save_CC"
4628
4629fi
4630
4631if test -z "$am_cv_prog_cc_stdc"; then
81ecdfbb
RW
4632 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4633$as_echo "none needed" >&6; }
783e057b 4634else
81ecdfbb
RW
4635 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_stdc" >&5
4636$as_echo "$am_cv_prog_cc_stdc" >&6; }
783e057b
DJ
4637fi
4638case "x$am_cv_prog_cc_stdc" in
4639 x|xno) ;;
4640 *) CC="$CC $am_cv_prog_cc_stdc" ;;
4641esac
4642
4643
4644ac_aux_dir=
81ecdfbb
RW
4645for ac_dir in .. "$srcdir"/..; do
4646 for ac_t in install-sh install.sh shtool; do
4647 if test -f "$ac_dir/$ac_t"; then
4648 ac_aux_dir=$ac_dir
4649 ac_install_sh="$ac_aux_dir/$ac_t -c"
4650 break 2
4651 fi
4652 done
783e057b
DJ
4653done
4654if test -z "$ac_aux_dir"; then
81ecdfbb 4655 as_fn_error "cannot find install-sh, install.sh, or shtool in .. \"$srcdir\"/.." "$LINENO" 5
783e057b 4656fi
81ecdfbb
RW
4657
4658# These three variables are undocumented and unsupported,
4659# and are intended to be withdrawn in a future Autoconf release.
4660# They can cause serious problems if a builder's source tree is in a directory
4661# whose full name contains unusual characters.
4662ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
4663ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
4664ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
4665
783e057b 4666
783e057b 4667
81ecdfbb 4668
a417dc56
RW
4669# Dependency checking.
4670rm -rf .tst 2>/dev/null
4671mkdir .tst 2>/dev/null
4672if test -d .tst; then
4673 am__leading_dot=.
4674else
4675 am__leading_dot=_
4676fi
4677rmdir .tst 2>/dev/null
4678
4679DEPDIR="${am__leading_dot}deps"
4680
81ecdfbb 4681ac_config_commands="$ac_config_commands depdir"
a417dc56
RW
4682
4683
4684depcc="$CC" am_compiler_list=
4685
4686am_depcomp=$ac_aux_dir/depcomp
81ecdfbb
RW
4687{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
4688$as_echo_n "checking dependency style of $depcc... " >&6; }
4689if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then :
4690 $as_echo_n "(cached) " >&6
a417dc56
RW
4691else
4692 if test -f "$am_depcomp"; then
4693 # We make a subdir and do the tests there. Otherwise we can end up
4694 # making bogus files that we don't know about and never remove. For
4695 # instance it was reported that on HP-UX the gcc test will end up
4696 # making a dummy file named `D' -- because `-MD' means `put the output
4697 # in D'.
4698 mkdir conftest.dir
4699 # Copy depcomp to subdir because otherwise we won't find it if we're
4700 # using a relative directory.
4701 cp "$am_depcomp" conftest.dir
4702 cd conftest.dir
4703 # We will build objects and dependencies in a subdirectory because
4704 # it helps to detect inapplicable dependency modes. For instance
4705 # both Tru64's cc and ICC support -MD to output dependencies as a
4706 # side effect of compilation, but ICC will put the dependencies in
4707 # the current directory while Tru64 will put them in the object
4708 # directory.
4709 mkdir sub
4710
4711 am_cv_CC_dependencies_compiler_type=none
4712 if test "$am_compiler_list" = ""; then
4713 am_compiler_list=`sed -n 's/^\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
4714 fi
4715 for depmode in $am_compiler_list; do
4716 if test $depmode = none; then break; fi
4717
81ecdfbb 4718 $as_echo "$as_me:$LINENO: trying $depmode" >&5
a417dc56
RW
4719 # Setup a source with many dependencies, because some compilers
4720 # like to wrap large dependency lists on column 80 (with \), and
4721 # we should not choose a depcomp mode which is confused by this.
4722 #
4723 # We need to recreate these files for each test, as the compiler may
4724 # overwrite some of them when testing with obscure command lines.
4725 # This happens at least with the AIX C compiler.
4726 : > sub/conftest.c
4727 for i in 1 2 3 4 5 6; do
4728 echo '#include "conftst'$i'.h"' >> sub/conftest.c
4729 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
4730 # Solaris 8's {/usr,}/bin/sh.
4731 touch sub/conftst$i.h
4732 done
4733 echo "include sub/conftest.Po" > confmf
4734
4735 # We check with `-c' and `-o' for the sake of the "dashmstdout"
4736 # mode. It turns out that the SunPro C++ compiler does not properly
4737 # handle `-M -o', and we need to detect this.
4738 depcmd="depmode=$depmode \
4739 source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
4740 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
4741 $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c"
4742 echo "| $depcmd" | sed -e 's/ */ /g' >&5
4743 if env $depcmd > conftest.err 2>&1 &&
4744 grep sub/conftst6.h sub/conftest.Po >>conftest.err 2>&1 &&
4745 grep sub/conftest.${OBJEXT-o} sub/conftest.Po >>conftest.err 2>&1 &&
4746 ${MAKE-make} -s -f confmf >>conftest.err 2>&1; then
4747 # icc doesn't choke on unknown options, it will just issue warnings
4748 # or remarks (even with -Werror). So we grep stderr for any message
4749 # that says an option was ignored or not supported.
4750 # When given -MP, icc 7.0 and 7.1 complain thusly:
4751 # icc: Command line warning: ignoring option '-M'; no argument required
4752 # The diagnosis changed in icc 8.0:
4753 # icc: Command line remark: option '-MP' not supported
4754 if (grep 'ignoring option' conftest.err ||
4755 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
4756 am_cv_CC_dependencies_compiler_type=$depmode
81ecdfbb 4757 $as_echo "$as_me:$LINENO: success" >&5
a417dc56
RW
4758 break
4759 fi
4760 fi
81ecdfbb 4761 $as_echo "$as_me:$LINENO: failure, diagnostics are:" >&5
a417dc56
RW
4762 sed -e 's/^/| /' < conftest.err >&5
4763 done
4764
4765 cd ..
4766 rm -rf conftest.dir
4767else
4768 am_cv_CC_dependencies_compiler_type=none
4769fi
4770
4771fi
81ecdfbb
RW
4772{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
4773$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
a417dc56 4774if test x${am_cv_CC_dependencies_compiler_type-none} = xnone
81ecdfbb 4775then as_fn_error "no usable dependency style found" "$LINENO" 5
a417dc56
RW
4776else CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
4777
4778fi
4779
4780
4781# Check for the 'make' the user wants to use.
4782for ac_prog in make
4783do
4784 # Extract the first word of "$ac_prog", so it can be a program name with args.
4785set dummy $ac_prog; ac_word=$2
81ecdfbb
RW
4786{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4787$as_echo_n "checking for $ac_word... " >&6; }
4788if test "${ac_cv_prog_MAKE+set}" = set; then :
4789 $as_echo_n "(cached) " >&6
a417dc56
RW
4790else
4791 if test -n "$MAKE"; then
4792 ac_cv_prog_MAKE="$MAKE" # Let the user override the test.
4793else
4794as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4795for as_dir in $PATH
4796do
4797 IFS=$as_save_IFS
4798 test -z "$as_dir" && as_dir=.
81ecdfbb
RW
4799 for ac_exec_ext in '' $ac_executable_extensions; do
4800 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
a417dc56 4801 ac_cv_prog_MAKE="$ac_prog"
81ecdfbb 4802 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
a417dc56
RW
4803 break 2
4804 fi
4805done
81ecdfbb
RW
4806 done
4807IFS=$as_save_IFS
a417dc56
RW
4808
4809fi
4810fi
4811MAKE=$ac_cv_prog_MAKE
4812if test -n "$MAKE"; then
81ecdfbb
RW
4813 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKE" >&5
4814$as_echo "$MAKE" >&6; }
a417dc56 4815else
81ecdfbb
RW
4816 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4817$as_echo "no" >&6; }
a417dc56
RW
4818fi
4819
81ecdfbb 4820
a417dc56
RW
4821 test -n "$MAKE" && break
4822done
4823
4824MAKE_IS_GNU=
4825case "`$MAKE --version 2>&1 | sed 1q`" in
4826 *GNU*)
4827 MAKE_IS_GNU=yes
4828 ;;
4829esac
81ecdfbb 4830 if test "$MAKE_IS_GNU" = yes; then
a417dc56
RW
4831 GMAKE_TRUE=
4832 GMAKE_FALSE='#'
4833else
4834 GMAKE_TRUE='#'
4835 GMAKE_FALSE=
4836fi
4837
81ecdfbb
RW
4838{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
4839$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
4840set x ${MAKE-make}
4841ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
4842if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
4843 $as_echo_n "(cached) " >&6
a417dc56
RW
4844else
4845 cat >conftest.make <<\_ACEOF
81ecdfbb 4846SHELL = /bin/sh
a417dc56 4847all:
81ecdfbb 4848 @echo '@@@%%%=$(MAKE)=@@@%%%'
a417dc56
RW
4849_ACEOF
4850# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
81ecdfbb
RW
4851case `${MAKE-make} -f conftest.make 2>/dev/null` in
4852 *@@@%%%=?*=@@@%%%*)
4853 eval ac_cv_prog_make_${ac_make}_set=yes;;
4854 *)
4855 eval ac_cv_prog_make_${ac_make}_set=no;;
4856esac
a417dc56
RW
4857rm -f conftest.make
4858fi
81ecdfbb
RW
4859if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
4860 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4861$as_echo "yes" >&6; }
a417dc56
RW
4862 SET_MAKE=
4863else
81ecdfbb
RW
4864 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4865$as_echo "no" >&6; }
a417dc56
RW
4866 SET_MAKE="MAKE=${MAKE-make}"
4867fi
4868
4869
783e057b
DJ
4870
4871CONFIG_OBS=
4872CONFIG_DEPS=
4873CONFIG_SRCS=
4874ENABLE_CFLAGS=
4875
4876CONFIG_ALL=
4877CONFIG_CLEAN=
4878CONFIG_INSTALL=
4879CONFIG_UNINSTALL=
4880
4881# If we haven't got the data from the intl directory,
4882# assume NLS is disabled.
4883USE_NLS=no
4884LIBINTL=
4885LIBINTL_DEP=
4886INCINTL=
4887XGETTEXT=
4888GMSGFMT=
4889POSUB=
4890
4891if test -f ../intl/config.intl; then
4892 . ../intl/config.intl
4893fi
81ecdfbb
RW
4894{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5
4895$as_echo_n "checking whether NLS is requested... " >&6; }
783e057b 4896if test x"$USE_NLS" != xyes; then
81ecdfbb
RW
4897 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4898$as_echo "no" >&6; }
783e057b 4899else
81ecdfbb
RW
4900 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4901$as_echo "yes" >&6; }
783e057b 4902
81ecdfbb 4903$as_echo "#define ENABLE_NLS 1" >>confdefs.h
783e057b
DJ
4904
4905
81ecdfbb
RW
4906 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for catalogs to be installed" >&5
4907$as_echo_n "checking for catalogs to be installed... " >&6; }
783e057b
DJ
4908 # Look for .po and .gmo files in the source directory.
4909 CATALOGS=
4910 XLINGUAS=
4911 for cat in $srcdir/po/*.gmo $srcdir/po/*.po; do
4912 # If there aren't any .gmo files the shell will give us the
4913 # literal string "../path/to/srcdir/po/*.gmo" which has to be
4914 # weeded out.
4915 case "$cat" in *\**)
4916 continue;;
4917 esac
4918 # The quadruple backslash is collapsed to a double backslash
4919 # by the backticks, then collapsed again by the double quotes,
4920 # leaving us with one backslash in the sed expression (right
4921 # before the dot that mustn't act as a wildcard).
4922 cat=`echo $cat | sed -e "s!$srcdir/po/!!" -e "s!\\\\.po!.gmo!"`
4923 lang=`echo $cat | sed -e "s!\\\\.gmo!!"`
4924 # The user is allowed to set LINGUAS to a list of languages to
4925 # install catalogs for. If it's empty that means "all of them."
4926 if test "x$LINGUAS" = x; then
4927 CATALOGS="$CATALOGS $cat"
4928 XLINGUAS="$XLINGUAS $lang"
4929 else
4930 case "$LINGUAS" in *$lang*)
4931 CATALOGS="$CATALOGS $cat"
4932 XLINGUAS="$XLINGUAS $lang"
4933 ;;
4934 esac
4935 fi
4936 done
4937 LINGUAS="$XLINGUAS"
81ecdfbb
RW
4938 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINGUAS" >&5
4939$as_echo "$LINGUAS" >&6; }
783e057b
DJ
4940
4941
4942 DATADIRNAME=share
4943
4944 INSTOBJEXT=.mo
4945
4946 GENCAT=gencat
4947
4948 CATOBJEXT=.gmo
4949
4950fi
4951
4952localedir='${datadir}/locale'
4953
4954
4955if test x"$USE_NLS" = xyes; then
4956 CONFIG_ALL="$CONFIG_ALL all-po"
4957 CONFIG_CLEAN="$CONFIG_CLEAN clean-po"
4958 CONFIG_INSTALL="$CONFIG_INSTALL install-po"
4959 CONFIG_UNINSTALL="$CONFIG_UNINSTALL uninstall-po"
4960fi
4961
4962
f434ba03
PA
4963
4964
4965
4966 LIBC_FATAL_STDERR_=1
4967 export LIBC_FATAL_STDERR_
4968
4969
4970
4971
4972
4973 for ac_header in $gl_header_list
4974do :
4975 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
4976ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
4977eval as_val=\$$as_ac_Header
4978 if test "x$as_val" = x""yes; then :
4979 cat >>confdefs.h <<_ACEOF
4980#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
4981_ACEOF
4982
4983fi
4984
4985done
4986
4987
4988
4989
4990
4991
4992
4993
4994
4995 for ac_func in $gl_func_list
4996do :
4997 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
4998ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
4999eval as_val=\$$as_ac_var
5000 if test "x$as_val" = x""yes; then :
5001 cat >>confdefs.h <<_ACEOF
5002#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
5003_ACEOF
5004
5005fi
5006done
5007
5008
5009
5010
5011
5012
5013 GNULIB_MEMCHR=0;
5014 GNULIB_MEMMEM=0;
5015 GNULIB_MEMPCPY=0;
5016 GNULIB_MEMRCHR=0;
5017 GNULIB_RAWMEMCHR=0;
5018 GNULIB_STPCPY=0;
5019 GNULIB_STPNCPY=0;
5020 GNULIB_STRCHRNUL=0;
5021 GNULIB_STRDUP=0;
5022 GNULIB_STRNCAT=0;
5023 GNULIB_STRNDUP=0;
5024 GNULIB_STRNLEN=0;
5025 GNULIB_STRPBRK=0;
5026 GNULIB_STRSEP=0;
5027 GNULIB_STRSTR=0;
5028 GNULIB_STRCASESTR=0;
5029 GNULIB_STRTOK_R=0;
5030 GNULIB_MBSLEN=0;
5031 GNULIB_MBSNLEN=0;
5032 GNULIB_MBSCHR=0;
5033 GNULIB_MBSRCHR=0;
5034 GNULIB_MBSSTR=0;
5035 GNULIB_MBSCASECMP=0;
5036 GNULIB_MBSNCASECMP=0;
5037 GNULIB_MBSPCASECMP=0;
5038 GNULIB_MBSCASESTR=0;
5039 GNULIB_MBSCSPN=0;
5040 GNULIB_MBSPBRK=0;
5041 GNULIB_MBSSPN=0;
5042 GNULIB_MBSSEP=0;
5043 GNULIB_MBSTOK_R=0;
5044 GNULIB_STRERROR=0;
5045 GNULIB_STRSIGNAL=0;
5046 GNULIB_STRVERSCMP=0;
5047 HAVE_MBSLEN=0;
5048 HAVE_MEMCHR=1;
5049 HAVE_DECL_MEMMEM=1;
5050 HAVE_MEMPCPY=1;
5051 HAVE_DECL_MEMRCHR=1;
5052 HAVE_RAWMEMCHR=1;
5053 HAVE_STPCPY=1;
5054 HAVE_STPNCPY=1;
5055 HAVE_STRCHRNUL=1;
5056 HAVE_DECL_STRDUP=1;
5057 HAVE_DECL_STRNDUP=1;
5058 HAVE_DECL_STRNLEN=1;
5059 HAVE_STRPBRK=1;
5060 HAVE_STRSEP=1;
5061 HAVE_STRCASESTR=1;
5062 HAVE_DECL_STRTOK_R=1;
5063 HAVE_DECL_STRSIGNAL=1;
5064 HAVE_STRVERSCMP=1;
5065 REPLACE_MEMCHR=0;
783e057b 5066 REPLACE_MEMMEM=0;
f434ba03
PA
5067 REPLACE_STPNCPY=0;
5068 REPLACE_STRDUP=0;
783e057b 5069 REPLACE_STRSTR=0;
f434ba03
PA
5070 REPLACE_STRCASESTR=0;
5071 REPLACE_STRERROR=0;
5072 REPLACE_STRNCAT=0;
5073 REPLACE_STRNDUP=0;
5074 REPLACE_STRNLEN=0;
5075 REPLACE_STRSIGNAL=0;
5076 REPLACE_STRTOK_R=0;
5077 UNDEFINE_STRTOK_R=0;
5078
5079
5080
5081
5082
5083
5084
5085
5086
5087
5088
5089
5090
5091 # Check for mmap(). Don't use AC_FUNC_MMAP, because it checks too much: it
5092 # fails on HP-UX 11, because MAP_FIXED mappings do not work. But this is
5093 # irrelevant for anonymous mappings.
5094 ac_fn_c_check_func "$LINENO" "mmap" "ac_cv_func_mmap"
5095if test "x$ac_cv_func_mmap" = x""yes; then :
5096 gl_have_mmap=yes
5097else
5098 gl_have_mmap=no
5099fi
5100
5101
5102 # Try to allow MAP_ANONYMOUS.
5103 gl_have_mmap_anonymous=no
5104 if test $gl_have_mmap = yes; then
5105 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MAP_ANONYMOUS" >&5
5106$as_echo_n "checking for MAP_ANONYMOUS... " >&6; }
5107 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5108/* end confdefs.h. */
5109
5110#include <sys/mman.h>
5111#ifdef MAP_ANONYMOUS
5112 I cant identify this map.
5113#endif
5114
5115_ACEOF
5116if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5117 $EGREP "I cant identify this map." >/dev/null 2>&1; then :
5118 gl_have_mmap_anonymous=yes
5119fi
5120rm -f conftest*
5121
5122 if test $gl_have_mmap_anonymous != yes; then
5123 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5124/* end confdefs.h. */
5125
5126#include <sys/mman.h>
5127#ifdef MAP_ANON
5128 I cant identify this map.
5129#endif
5130
5131_ACEOF
5132if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5133 $EGREP "I cant identify this map." >/dev/null 2>&1; then :
5134
5135$as_echo "#define MAP_ANONYMOUS MAP_ANON" >>confdefs.h
5136
5137 gl_have_mmap_anonymous=yes
5138fi
5139rm -f conftest*
5140
5141 fi
5142 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_have_mmap_anonymous" >&5
5143$as_echo "$gl_have_mmap_anonymous" >&6; }
5144 if test $gl_have_mmap_anonymous = yes; then
5145
5146$as_echo "#define HAVE_MAP_ANONYMOUS 1" >>confdefs.h
5147
5148 fi
5149 fi
5150
5151
5152 :
5153
5154
5155
5156
5157
5158
5159 :
5160
5161
5162
5163
5164
5165
5166
5167
5168 :
5169
5170
5171
5172
5173
5174 if test $ac_cv_func_memchr = yes; then
5175 # Detect platform-specific bugs in some versions of glibc:
5176 # memchr should not dereference anything with length 0
5177 # http://bugzilla.redhat.com/499689
5178 # memchr should not dereference overestimated length after a match
5179 # http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=521737
5180 # http://sourceware.org/bugzilla/show_bug.cgi?id=10162
5181 # Assume that memchr works on platforms that lack mprotect.
5182 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether memchr works" >&5
5183$as_echo_n "checking whether memchr works... " >&6; }
5184if test "${gl_cv_func_memchr_works+set}" = set; then :
5185 $as_echo_n "(cached) " >&6
5186else
5187 if test "$cross_compiling" = yes; then :
5188 gl_cv_func_memchr_works="guessing no"
5189else
5190 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5191/* end confdefs.h. */
5192
5193#include <string.h>
5194#if HAVE_SYS_MMAN_H
5195# include <fcntl.h>
5196# include <unistd.h>
5197# include <sys/types.h>
5198# include <sys/mman.h>
5199# ifndef MAP_FILE
5200# define MAP_FILE 0
5201# endif
5202#endif
5203
5204int
5205main ()
5206{
5207
5208 char *fence = NULL;
5209#if HAVE_SYS_MMAN_H && HAVE_MPROTECT
5210# if HAVE_MAP_ANONYMOUS
5211 const int flags = MAP_ANONYMOUS | MAP_PRIVATE;
5212 const int fd = -1;
5213# else /* !HAVE_MAP_ANONYMOUS */
5214 const int flags = MAP_FILE | MAP_PRIVATE;
5215 int fd = open ("/dev/zero", O_RDONLY, 0666);
5216 if (fd >= 0)
5217# endif
5218 {
5219 int pagesize = getpagesize ();
5220 char *two_pages =
5221 (char *) mmap (NULL, 2 * pagesize, PROT_READ | PROT_WRITE,
5222 flags, fd, 0);
5223 if (two_pages != (char *)(-1)
5224 && mprotect (two_pages + pagesize, pagesize, PROT_NONE) == 0)
5225 fence = two_pages + pagesize;
5226 }
5227#endif
5228 if (fence)
5229 {
5230 if (memchr (fence, 0, 0))
5231 return 1;
5232 strcpy (fence - 9, "12345678");
5233 if (memchr (fence - 9, 0, 79) != fence - 1)
5234 return 2;
5235 }
5236 return 0;
5237
5238 ;
5239 return 0;
5240}
5241_ACEOF
5242if ac_fn_c_try_run "$LINENO"; then :
5243 gl_cv_func_memchr_works=yes
5244else
5245 gl_cv_func_memchr_works=no
5246fi
5247rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
5248 conftest.$ac_objext conftest.beam conftest.$ac_ext
5249fi
5250
5251fi
5252{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_memchr_works" >&5
5253$as_echo "$gl_cv_func_memchr_works" >&6; }
5254 if test "$gl_cv_func_memchr_works" != yes; then
5255 REPLACE_MEMCHR=1
5256 fi
5257 else
5258 HAVE_MEMCHR=0
5259 fi
5260 if test $HAVE_MEMCHR = 0 || test $REPLACE_MEMCHR = 1; then
5261
5262
5263
5264
5265
5266
5267
5268
5269 gl_LIBOBJS="$gl_LIBOBJS memchr.$ac_objext"
5270
5271
5272 for ac_header in bp-sym.h
5273do :
5274 ac_fn_c_check_header_mongrel "$LINENO" "bp-sym.h" "ac_cv_header_bp_sym_h" "$ac_includes_default"
5275if test "x$ac_cv_header_bp_sym_h" = x""yes; then :
5276 cat >>confdefs.h <<_ACEOF
5277#define HAVE_BP_SYM_H 1
5278_ACEOF
5279
5280fi
5281
5282done
5283
5284
5285 fi
783e057b
DJ
5286
5287
81ecdfbb
RW
5288 ac_fn_c_check_decl "$LINENO" "memmem" "ac_cv_have_decl_memmem" "$ac_includes_default"
5289if test "x$ac_cv_have_decl_memmem" = x""yes; then :
5290 ac_have_decl=1
783e057b 5291else
81ecdfbb 5292 ac_have_decl=0
783e057b 5293fi
783e057b
DJ
5294
5295cat >>confdefs.h <<_ACEOF
81ecdfbb 5296#define HAVE_DECL_MEMMEM $ac_have_decl
783e057b
DJ
5297_ACEOF
5298
5299
783e057b
DJ
5300
5301
5302
5303
5304
5305
5306
5307
783e057b 5308
783e057b 5309
783e057b 5310
f434ba03 5311
81ecdfbb
RW
5312 for ac_func in memmem
5313do :
5314 ac_fn_c_check_func "$LINENO" "memmem" "ac_cv_func_memmem"
5315if test "x$ac_cv_func_memmem" = x""yes; then :
783e057b 5316 cat >>confdefs.h <<_ACEOF
81ecdfbb 5317#define HAVE_MEMMEM 1
783e057b
DJ
5318_ACEOF
5319
5320else
5321
5322 gl_LIBOBJS="$gl_LIBOBJS $ac_func.$ac_objext"
5323
5324fi
5325done
5326
5327
5328
5329 :
5330
5331
5332
5333
5334
5335 if test $ac_cv_have_decl_memmem = no; then
5336 HAVE_DECL_MEMMEM=0
5337 fi
5338 :
5339
5340
f434ba03
PA
5341 gl_cv_c_multiarch=no
5342 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5343/* end confdefs.h. */
5344#ifndef __APPLE_CC__
5345 not a universal capable compiler
5346 #endif
5347 typedef int dummy;
5348
5349_ACEOF
5350if ac_fn_c_try_compile "$LINENO"; then :
5351
5352 arch=
5353 prev=
5354 for word in ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}; do
5355 if test -n "$prev"; then
5356 case $word in
5357 i?86 | x86_64 | ppc | ppc64)
5358 if test -z "$arch" || test "$arch" = "$word"; then
5359 arch="$word"
5360 else
5361 gl_cv_c_multiarch=yes
5362 fi
5363 ;;
5364 esac
5365 prev=
5366 else
5367 if test "x$word" = "x-arch"; then
5368 prev=arch
5369 fi
5370 fi
5371 done
5372
5373fi
5374rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5375 if test $gl_cv_c_multiarch = yes; then
5376
5377$as_echo "#define AA_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
5378
5379 APPLE_UNIVERSAL_BUILD=1
5380 else
5381 APPLE_UNIVERSAL_BUILD=0
5382 fi
5383
5384
5385
5386 REPLACE_NULL=0;
5387 HAVE_WCHAR_T=1;
5388 STDDEF_H='';
5389
5390
5391 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchar_t" >&5
5392$as_echo_n "checking for wchar_t... " >&6; }
5393if test "${gt_cv_c_wchar_t+set}" = set; then :
5394 $as_echo_n "(cached) " >&6
5395else
5396 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5397/* end confdefs.h. */
5398#include <stddef.h>
5399 wchar_t foo = (wchar_t)'\0';
5400int
5401main ()
5402{
5403
5404 ;
5405 return 0;
5406}
5407_ACEOF
5408if ac_fn_c_try_compile "$LINENO"; then :
5409 gt_cv_c_wchar_t=yes
5410else
5411 gt_cv_c_wchar_t=no
5412fi
5413rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5414fi
5415{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wchar_t" >&5
5416$as_echo "$gt_cv_c_wchar_t" >&6; }
5417 if test $gt_cv_c_wchar_t = yes; then
5418
5419$as_echo "#define HAVE_WCHAR_T 1" >>confdefs.h
5420
5421 fi
5422
5423
5424
5425 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the preprocessor supports include_next" >&5
5426$as_echo_n "checking whether the preprocessor supports include_next... " >&6; }
5427if test "${gl_cv_have_include_next+set}" = set; then :
5428 $as_echo_n "(cached) " >&6
5429else
5430 rm -rf conftestd1a conftestd1b conftestd2
5431 mkdir conftestd1a conftestd1b conftestd2
5432 cat <<EOF > conftestd1a/conftest.h
5433#define DEFINED_IN_CONFTESTD1
5434#include_next <conftest.h>
5435#ifdef DEFINED_IN_CONFTESTD2
5436int foo;
5437#else
5438#error "include_next doesn't work"
5439#endif
5440EOF
5441 cat <<EOF > conftestd1b/conftest.h
5442#define DEFINED_IN_CONFTESTD1
5443#include <stdio.h>
5444#include_next <conftest.h>
5445#ifdef DEFINED_IN_CONFTESTD2
5446int foo;
5447#else
5448#error "include_next doesn't work"
5449#endif
5450EOF
5451 cat <<EOF > conftestd2/conftest.h
5452#ifndef DEFINED_IN_CONFTESTD1
5453#error "include_next test doesn't work"
5454#endif
5455#define DEFINED_IN_CONFTESTD2
5456EOF
5457 gl_save_CPPFLAGS="$CPPFLAGS"
5458 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1b -Iconftestd2"
5459 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5460/* end confdefs.h. */
5461#include <conftest.h>
5462_ACEOF
5463if ac_fn_c_try_compile "$LINENO"; then :
5464 gl_cv_have_include_next=yes
5465else
5466 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1a -Iconftestd2"
5467 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5468/* end confdefs.h. */
5469#include <conftest.h>
5470_ACEOF
5471if ac_fn_c_try_compile "$LINENO"; then :
5472 gl_cv_have_include_next=buggy
5473else
5474 gl_cv_have_include_next=no
5475fi
5476rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5477
5478fi
5479rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5480 CPPFLAGS="$gl_save_CPPFLAGS"
5481 rm -rf conftestd1a conftestd1b conftestd2
5482
5483fi
5484{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_include_next" >&5
5485$as_echo "$gl_cv_have_include_next" >&6; }
5486 PRAGMA_SYSTEM_HEADER=
5487 if test $gl_cv_have_include_next = yes; then
5488 INCLUDE_NEXT=include_next
5489 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
5490 if test -n "$GCC"; then
5491 PRAGMA_SYSTEM_HEADER='#pragma GCC system_header'
5492 fi
5493 else
5494 if test $gl_cv_have_include_next = buggy; then
5495 INCLUDE_NEXT=include
5496 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
5497 else
5498 INCLUDE_NEXT=include
5499 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include
5500 fi
5501 fi
5502
5503
5504
5505
5506
5507
5508
5509
5510
5511
81ecdfbb
RW
5512 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
5513$as_echo_n "checking for long long int... " >&6; }
5514if test "${ac_cv_type_long_long_int+set}" = set; then :
5515 $as_echo_n "(cached) " >&6
783e057b 5516else
81ecdfbb 5517 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
783e057b 5518/* end confdefs.h. */
81ecdfbb
RW
5519
5520 /* For now, do not test the preprocessor; as of 2007 there are too many
f434ba03
PA
5521 implementations with broken preprocessors. Perhaps this can
5522 be revisited in 2012. In the meantime, code should not expect
5523 #if to work with literals wider than 32 bits. */
783e057b
DJ
5524 /* Test literals. */
5525 long long int ll = 9223372036854775807ll;
5526 long long int nll = -9223372036854775807LL;
5527 unsigned long long int ull = 18446744073709551615ULL;
5528 /* Test constant expressions. */
5529 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
f434ba03 5530 ? 1 : -1)];
783e057b 5531 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
f434ba03 5532 ? 1 : -1)];
783e057b
DJ
5533 int i = 63;
5534int
5535main ()
5536{
5537/* Test availability of runtime routines for shift and division. */
5538 long long int llmax = 9223372036854775807ll;
5539 unsigned long long int ullmax = 18446744073709551615ull;
5540 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
f434ba03
PA
5541 | (llmax / ll) | (llmax % ll)
5542 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
5543 | (ullmax / ull) | (ullmax % ull));
783e057b
DJ
5544 ;
5545 return 0;
5546}
5547
5548_ACEOF
81ecdfbb 5549if ac_fn_c_try_link "$LINENO"; then :
f434ba03 5550 if test "$cross_compiling" = yes; then :
783e057b
DJ
5551 ac_cv_type_long_long_int=yes
5552else
81ecdfbb 5553 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
783e057b
DJ
5554/* end confdefs.h. */
5555#include <limits.h>
f434ba03
PA
5556 #ifndef LLONG_MAX
5557 # define HALF \
5558 (1LL << (sizeof (long long int) * CHAR_BIT - 2))
5559 # define LLONG_MAX (HALF - 1 + HALF)
5560 #endif
783e057b
DJ
5561int
5562main ()
5563{
5564long long int n = 1;
f434ba03
PA
5565 int i;
5566 for (i = 0; ; i++)
5567 {
5568 long long int m = n << i;
5569 if (m >> i != n)
5570 return 1;
5571 if (LLONG_MAX / 2 < m)
5572 break;
5573 }
5574 return 0;
783e057b
DJ
5575 ;
5576 return 0;
5577}
5578_ACEOF
81ecdfbb 5579if ac_fn_c_try_run "$LINENO"; then :
783e057b
DJ
5580 ac_cv_type_long_long_int=yes
5581else
81ecdfbb 5582 ac_cv_type_long_long_int=no
783e057b 5583fi
81ecdfbb
RW
5584rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
5585 conftest.$ac_objext conftest.beam conftest.$ac_ext
783e057b 5586fi
783e057b 5587
81ecdfbb
RW
5588else
5589 ac_cv_type_long_long_int=no
783e057b 5590fi
81ecdfbb
RW
5591rm -f core conftest.err conftest.$ac_objext \
5592 conftest$ac_exeext conftest.$ac_ext
783e057b 5593fi
81ecdfbb
RW
5594{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
5595$as_echo "$ac_cv_type_long_long_int" >&6; }
783e057b
DJ
5596 if test $ac_cv_type_long_long_int = yes; then
5597
81ecdfbb 5598$as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
783e057b
DJ
5599
5600 fi
5601
5602
81ecdfbb
RW
5603 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
5604$as_echo_n "checking for unsigned long long int... " >&6; }
5605if test "${ac_cv_type_unsigned_long_long_int+set}" = set; then :
5606 $as_echo_n "(cached) " >&6
783e057b 5607else
81ecdfbb 5608 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
783e057b 5609/* end confdefs.h. */
81ecdfbb
RW
5610
5611 /* For now, do not test the preprocessor; as of 2007 there are too many
f434ba03
PA
5612 implementations with broken preprocessors. Perhaps this can
5613 be revisited in 2012. In the meantime, code should not expect
5614 #if to work with literals wider than 32 bits. */
783e057b
DJ
5615 /* Test literals. */
5616 long long int ll = 9223372036854775807ll;
5617 long long int nll = -9223372036854775807LL;
5618 unsigned long long int ull = 18446744073709551615ULL;
5619 /* Test constant expressions. */
5620 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
f434ba03 5621 ? 1 : -1)];
783e057b 5622 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
f434ba03 5623 ? 1 : -1)];
783e057b
DJ
5624 int i = 63;
5625int
5626main ()
5627{
5628/* Test availability of runtime routines for shift and division. */
5629 long long int llmax = 9223372036854775807ll;
5630 unsigned long long int ullmax = 18446744073709551615ull;
5631 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
f434ba03
PA
5632 | (llmax / ll) | (llmax % ll)
5633 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
5634 | (ullmax / ull) | (ullmax % ull));
783e057b
DJ
5635 ;
5636 return 0;
5637}
5638
5639_ACEOF
81ecdfbb 5640if ac_fn_c_try_link "$LINENO"; then :
783e057b
DJ
5641 ac_cv_type_unsigned_long_long_int=yes
5642else
81ecdfbb 5643 ac_cv_type_unsigned_long_long_int=no
783e057b 5644fi
81ecdfbb
RW
5645rm -f core conftest.err conftest.$ac_objext \
5646 conftest$ac_exeext conftest.$ac_ext
783e057b 5647fi
81ecdfbb
RW
5648{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
5649$as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
783e057b
DJ
5650 if test $ac_cv_type_unsigned_long_long_int = yes; then
5651
81ecdfbb 5652$as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
783e057b
DJ
5653
5654 fi
5655
5656
5657
783e057b
DJ
5658
5659
5660
5661
5662
5663
5664
5665
81ecdfbb
RW
5666{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5
5667$as_echo_n "checking for C/C++ restrict keyword... " >&6; }
5668if test "${ac_cv_c_restrict+set}" = set; then :
5669 $as_echo_n "(cached) " >&6
783e057b
DJ
5670else
5671 ac_cv_c_restrict=no
5672 # The order here caters to the fact that C++ does not require restrict.
5673 for ac_kw in __restrict __restrict__ _Restrict restrict; do
81ecdfbb 5674 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
783e057b
DJ
5675/* end confdefs.h. */
5676typedef int * int_ptr;
5677 int foo (int_ptr $ac_kw ip) {
5678 return ip[0];
5679 }
5680int
5681main ()
5682{
5683int s[1];
5684 int * $ac_kw t = s;
5685 t[0] = 0;
5686 return foo(t)
5687 ;
5688 return 0;
5689}
5690_ACEOF
81ecdfbb 5691if ac_fn_c_try_compile "$LINENO"; then :
783e057b 5692 ac_cv_c_restrict=$ac_kw
783e057b 5693fi
81ecdfbb 5694rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
783e057b
DJ
5695 test "$ac_cv_c_restrict" != no && break
5696 done
5697
5698fi
81ecdfbb
RW
5699{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5
5700$as_echo "$ac_cv_c_restrict" >&6; }
783e057b
DJ
5701
5702 case $ac_cv_c_restrict in
5703 restrict) ;;
81ecdfbb 5704 no) $as_echo "#define restrict /**/" >>confdefs.h
783e057b
DJ
5705 ;;
5706 *) cat >>confdefs.h <<_ACEOF
5707#define restrict $ac_cv_c_restrict
5708_ACEOF
5709 ;;
5710 esac
5711
5712
5713
5714
5715
5716
5717
5718
5719
5720
5721
5722
f434ba03 5723
783e057b
DJ
5724 :
5725
5726
5727
5728
5729
5730
5731
f434ba03
PA
5732 if test $gl_cv_have_include_next = yes; then
5733 gl_cv_next_string_h='<'string.h'>'
5734 else
5735 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <string.h>" >&5
5736$as_echo_n "checking absolute name of <string.h>... " >&6; }
5737if test "${gl_cv_next_string_h+set}" = set; then :
5738 $as_echo_n "(cached) " >&6
5739else
5740
5741 if test $ac_cv_header_string_h = yes; then
5742 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5743/* end confdefs.h. */
5744#include <string.h>
5745
5746_ACEOF
5747 case "$host_os" in
5748 aix*) gl_absname_cpp="$ac_cpp -C" ;;
5749 *) gl_absname_cpp="$ac_cpp" ;;
5750 esac
5751 gl_cv_next_string_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
5752 sed -n '\#/string.h#{
5753 s#.*"\(.*/string.h\)".*#\1#
5754 s#^/[^/]#//&#
5755 p
5756 q
5757 }'`'"'
5758 else
5759 gl_cv_next_string_h='<'string.h'>'
5760 fi
5761
5762fi
5763{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_string_h" >&5
5764$as_echo "$gl_cv_next_string_h" >&6; }
5765 fi
5766 NEXT_STRING_H=$gl_cv_next_string_h
5767
5768 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
5769 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
5770 gl_next_as_first_directive='<'string.h'>'
5771 else
5772 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
5773 gl_next_as_first_directive=$gl_cv_next_string_h
5774 fi
5775 NEXT_AS_FIRST_DIRECTIVE_STRING_H=$gl_next_as_first_directive
5776
5777
5778
5779
5780
5781 for gl_func in memmem mempcpy memrchr rawmemchr stpcpy stpncpy strchrnul strdup strncat strndup strnlen strpbrk strsep strcasestr strtok_r strsignal strverscmp; do
5782 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
5783 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
5784$as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
5785if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then :
5786 $as_echo_n "(cached) " >&6
5787else
5788 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5789/* end confdefs.h. */
5790#include <string.h>
5791
5792int
5793main ()
5794{
5795#undef $gl_func
5796 (void) $gl_func;
5797 ;
5798 return 0;
5799}
5800_ACEOF
5801if ac_fn_c_try_compile "$LINENO"; then :
5802 eval "$as_gl_Symbol=yes"
5803else
5804 eval "$as_gl_Symbol=no"
5805fi
5806rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5807fi
5808eval ac_res=\$$as_gl_Symbol
5809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
5810$as_echo "$ac_res" >&6; }
5811 eval as_val=\$$as_gl_Symbol
5812 if test "x$as_val" = x""yes; then :
5813 cat >>confdefs.h <<_ACEOF
5814#define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
5815_ACEOF
5816
5817 eval ac_cv_have_decl_$gl_func=yes
5818fi
5819 done
5820
5821
5822
5823 GNULIB_BTOWC=0;
5824 GNULIB_WCTOB=0;
5825 GNULIB_MBSINIT=0;
5826 GNULIB_MBRTOWC=0;
5827 GNULIB_MBRLEN=0;
5828 GNULIB_MBSRTOWCS=0;
5829 GNULIB_MBSNRTOWCS=0;
5830 GNULIB_WCRTOMB=0;
5831 GNULIB_WCSRTOMBS=0;
5832 GNULIB_WCSNRTOMBS=0;
5833 GNULIB_WCWIDTH=0;
5834 HAVE_BTOWC=1;
5835 HAVE_MBSINIT=1;
5836 HAVE_MBRTOWC=1;
5837 HAVE_MBRLEN=1;
5838 HAVE_MBSRTOWCS=1;
5839 HAVE_MBSNRTOWCS=1;
5840 HAVE_WCRTOMB=1;
5841 HAVE_WCSRTOMBS=1;
5842 HAVE_WCSNRTOMBS=1;
5843 HAVE_DECL_WCTOB=1;
5844 HAVE_DECL_WCWIDTH=1;
5845 REPLACE_MBSTATE_T=0;
5846 REPLACE_BTOWC=0;
5847 REPLACE_WCTOB=0;
5848 REPLACE_MBSINIT=0;
5849 REPLACE_MBRTOWC=0;
5850 REPLACE_MBRLEN=0;
5851 REPLACE_MBSRTOWCS=0;
5852 REPLACE_MBSNRTOWCS=0;
5853 REPLACE_WCRTOMB=0;
5854 REPLACE_WCSRTOMBS=0;
5855 REPLACE_WCSNRTOMBS=0;
5856 REPLACE_WCWIDTH=0;
5857
5858
5859 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <wchar.h> uses 'inline' correctly" >&5
5860$as_echo_n "checking whether <wchar.h> uses 'inline' correctly... " >&6; }
5861if test "${gl_cv_header_wchar_h_correct_inline+set}" = set; then :
81ecdfbb 5862 $as_echo_n "(cached) " >&6
783e057b 5863else
f434ba03
PA
5864 gl_cv_header_wchar_h_correct_inline=yes
5865 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5866/* end confdefs.h. */
783e057b 5867
f434ba03
PA
5868 #define wcstod renamed_wcstod
5869#include <wchar.h>
5870extern int zero (void);
5871int main () { return zero(); }
5872
5873_ACEOF
5874 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
5875 (eval $ac_compile) 2>&5
5876 ac_status=$?
5877 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5878 test $ac_status = 0; }; then
5879 mv conftest.$ac_objext conftest1.$ac_objext
5880 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
783e057b 5881/* end confdefs.h. */
f434ba03
PA
5882
5883 #define wcstod renamed_wcstod
5884#include <wchar.h>
5885int zero (void) { return 0; }
783e057b
DJ
5886
5887_ACEOF
f434ba03
PA
5888 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
5889 (eval $ac_compile) 2>&5
5890 ac_status=$?
5891 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5892 test $ac_status = 0; }; then
5893 mv conftest.$ac_objext conftest2.$ac_objext
5894 if $CC -o conftest$ac_exeext $CFLAGS $LDFLAGS conftest1.$ac_objext conftest2.$ac_objext $LIBS >&5 2>&1; then
5895 :
5896 else
5897 gl_cv_header_wchar_h_correct_inline=no
5898 fi
5899 fi
5900 fi
5901 rm -f conftest1.$ac_objext conftest2.$ac_objext conftest$ac_exeext
783e057b
DJ
5902
5903fi
f434ba03
PA
5904{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_wchar_h_correct_inline" >&5
5905$as_echo "$gl_cv_header_wchar_h_correct_inline" >&6; }
5906 if test $gl_cv_header_wchar_h_correct_inline = no; then
5907 as_fn_error "<wchar.h> cannot be used with this compiler ($CC $CFLAGS $CPPFLAGS).
5908This is a known interoperability problem of glibc <= 2.5 with gcc >= 4.3 in
5909C99 mode. You have four options:
5910 - Add the flag -fgnu89-inline to CC and reconfigure, or
5911 - Fix your include files, using parts of
5912 <http://sourceware.org/git/?p=glibc.git;a=commitdiff;h=b037a293a48718af30d706c2e18c929d0e69a621>, or
5913 - Use a gcc version older than 4.3, or
5914 - Don't use the flags -std=c99 or -std=gnu99.
5915Configuration aborted." "$LINENO" 5
5916 fi
783e057b
DJ
5917
5918
f434ba03
PA
5919 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wint_t" >&5
5920$as_echo_n "checking for wint_t... " >&6; }
5921if test "${gt_cv_c_wint_t+set}" = set; then :
5922 $as_echo_n "(cached) " >&6
5923else
5924 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5925/* end confdefs.h. */
783e057b 5926
f434ba03
PA
5927/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
5928 <wchar.h>.
5929 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be included
5930 before <wchar.h>. */
5931#include <stddef.h>
5932#include <stdio.h>
5933#include <time.h>
5934#include <wchar.h>
5935 wint_t foo = (wchar_t)'\0';
5936int
5937main ()
5938{
783e057b 5939
f434ba03
PA
5940 ;
5941 return 0;
5942}
5943_ACEOF
5944if ac_fn_c_try_compile "$LINENO"; then :
5945 gt_cv_c_wint_t=yes
5946else
5947 gt_cv_c_wint_t=no
5948fi
5949rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5950fi
5951{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wint_t" >&5
5952$as_echo "$gt_cv_c_wint_t" >&6; }
5953 if test $gt_cv_c_wint_t = yes; then
783e057b 5954
f434ba03 5955$as_echo "#define HAVE_WINT_T 1" >>confdefs.h
783e057b 5956
f434ba03 5957 fi
783e057b
DJ
5958
5959
81ecdfbb 5960 if false; then
783e057b
DJ
5961 GL_COND_LIBTOOL_TRUE=
5962 GL_COND_LIBTOOL_FALSE='#'
5963else
5964 GL_COND_LIBTOOL_TRUE='#'
5965 GL_COND_LIBTOOL_FALSE=
5966fi
5967
5968 gl_cond_libtool=false
5969 gl_libdeps=
5970 gl_ltlibdeps=
f434ba03 5971 gl_m4_base='gnulib/m4'
783e057b
DJ
5972
5973
5974
783e057b
DJ
5975
5976
5977
5978
5979
5980
f434ba03
PA
5981 gl_source_base='gnulib'
5982 # Code from module arg-nonnull:
5983 # Code from module c++defs:
5984 # Code from module extensions:
5985 # Code from module include_next:
5986 # Code from module memchr:
783e057b 5987
783e057b 5988
783e057b 5989
783e057b 5990
f434ba03 5991 GNULIB_MEMCHR=1
783e057b 5992
783e057b 5993
783e057b 5994
f434ba03 5995$as_echo "#define GNULIB_TEST_MEMCHR 1" >>confdefs.h
783e057b 5996
783e057b
DJ
5997
5998
f434ba03 5999 # Code from module memmem:
783e057b
DJ
6000
6001
f434ba03
PA
6002 if test $ac_cv_have_decl_memmem = yes; then
6003 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether memmem works in linear time" >&5
6004$as_echo_n "checking whether memmem works in linear time... " >&6; }
6005if test "${gl_cv_func_memmem_works+set}" = set; then :
81ecdfbb 6006 $as_echo_n "(cached) " >&6
783e057b 6007else
81ecdfbb 6008 if test "$cross_compiling" = yes; then :
f434ba03 6009 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
783e057b 6010/* end confdefs.h. */
783e057b 6011
f434ba03
PA
6012#include <features.h>
6013#ifdef __GNU_LIBRARY__
6014 #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 9) || (__GLIBC__ > 2)
6015 Lucky user
6016 #endif
6017#endif
6018#ifdef __CYGWIN__
6019 #include <cygwin/version.h>
6020 #if CYGWIN_VERSION_DLL_MAJOR >= 1007
6021 Lucky user
6022 #endif
6023#endif
783e057b 6024
783e057b 6025_ACEOF
f434ba03
PA
6026if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6027 $EGREP "Lucky user" >/dev/null 2>&1; then :
6028 gl_cv_func_memmem_works=yes
783e057b 6029else
f434ba03 6030 gl_cv_func_memmem_works="guessing no"
783e057b 6031fi
f434ba03 6032rm -f conftest*
783e057b
DJ
6033
6034
783e057b 6035else
81ecdfbb 6036 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
783e057b
DJ
6037/* end confdefs.h. */
6038
f434ba03 6039#include <signal.h> /* for signal */
783e057b
DJ
6040#include <string.h> /* for memmem */
6041#include <stdlib.h> /* for malloc */
6042#include <unistd.h> /* for alarm */
6043
6044int
6045main ()
6046{
6047size_t m = 1000000;
6048 char *haystack = (char *) malloc (2 * m + 1);
6049 char *needle = (char *) malloc (m + 1);
6050 void *result = 0;
6051 /* Failure to compile this test due to missing alarm is okay,
6052 since all such platforms (mingw) also lack memmem. */
f434ba03 6053 signal (SIGALRM, SIG_DFL);
783e057b
DJ
6054 alarm (5);
6055 /* Check for quadratic performance. */
6056 if (haystack && needle)
6057 {
f434ba03
PA
6058 memset (haystack, 'A', 2 * m);
6059 haystack[2 * m] = 'B';
6060 memset (needle, 'A', m);
6061 needle[m] = 'B';
6062 result = memmem (haystack, 2 * m + 1, needle, m + 1);
783e057b
DJ
6063 }
6064 /* Check for empty needle behavior. */
6065 return !result || !memmem ("a", 1, 0, 0);
6066 ;
6067 return 0;
6068}
6069_ACEOF
81ecdfbb 6070if ac_fn_c_try_run "$LINENO"; then :
783e057b
DJ
6071 gl_cv_func_memmem_works=yes
6072else
81ecdfbb 6073 gl_cv_func_memmem_works=no
783e057b 6074fi
81ecdfbb
RW
6075rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6076 conftest.$ac_objext conftest.beam conftest.$ac_ext
783e057b 6077fi
81ecdfbb 6078
f434ba03 6079
783e057b 6080fi
81ecdfbb
RW
6081{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_memmem_works" >&5
6082$as_echo "$gl_cv_func_memmem_works" >&6; }
783e057b
DJ
6083 if test "$gl_cv_func_memmem_works" != yes; then
6084 REPLACE_MEMMEM=1
6085
6086
6087
6088
6089
6090
6091
f434ba03 6092
783e057b
DJ
6093 gl_LIBOBJS="$gl_LIBOBJS memmem.$ac_objext"
6094
6095 fi
6096 fi
6097
f434ba03
PA
6098 # Code from module memmem-simple:
6099
783e057b
DJ
6100
6101
6102
6103
6104
6105
6106
6107
6108
6109
6110
81ecdfbb
RW
6111 for ac_func in memmem
6112do :
6113 ac_fn_c_check_func "$LINENO" "memmem" "ac_cv_func_memmem"
6114if test "x$ac_cv_func_memmem" = x""yes; then :
783e057b 6115 cat >>confdefs.h <<_ACEOF
81ecdfbb 6116#define HAVE_MEMMEM 1
783e057b
DJ
6117_ACEOF
6118
6119else
6120
6121 gl_LIBOBJS="$gl_LIBOBJS $ac_func.$ac_objext"
6122
6123fi
6124done
6125
6126
6127
6128 :
6129
6130
6131
6132
6133
6134 if test $ac_cv_have_decl_memmem = no; then
6135 HAVE_DECL_MEMMEM=0
6136 fi
6137 :
6138
6139
6140
f434ba03 6141
783e057b
DJ
6142 GNULIB_MEMMEM=1
6143
6144
6145
f434ba03
PA
6146$as_echo "#define GNULIB_TEST_MEMMEM 1" >>confdefs.h
6147
6148
6149
6150 # Code from module multiarch:
6151
6152 # Code from module stddef:
6153
6154
6155
6156 if test $gt_cv_c_wchar_t = no; then
6157 HAVE_WCHAR_T=0
6158 STDDEF_H=stddef.h
6159 fi
6160 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
6161$as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; }
6162if test "${gl_cv_decl_null_works+set}" = set; then :
6163 $as_echo_n "(cached) " >&6
6164else
6165 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6166/* end confdefs.h. */
6167#include <stddef.h>
6168 int test[2 * (sizeof NULL == sizeof (void *)) -1];
6169
6170int
6171main ()
6172{
6173
6174 ;
6175 return 0;
6176}
6177_ACEOF
6178if ac_fn_c_try_compile "$LINENO"; then :
6179 gl_cv_decl_null_works=yes
6180else
6181 gl_cv_decl_null_works=no
6182fi
6183rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6184fi
6185{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
6186$as_echo "$gl_cv_decl_null_works" >&6; }
6187 if test $gl_cv_decl_null_works = no; then
6188 REPLACE_NULL=1
6189 STDDEF_H=stddef.h
6190 fi
6191 if test -n "$STDDEF_H"; then
6192
6193
6194
6195
6196 :
6197
6198
6199
6200
6201
6202
6203
6204 if test $gl_cv_have_include_next = yes; then
6205 gl_cv_next_stddef_h='<'stddef.h'>'
6206 else
6207 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
6208$as_echo_n "checking absolute name of <stddef.h>... " >&6; }
6209if test "${gl_cv_next_stddef_h+set}" = set; then :
6210 $as_echo_n "(cached) " >&6
6211else
6212
6213 if test $ac_cv_header_stddef_h = yes; then
6214 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6215/* end confdefs.h. */
6216#include <stddef.h>
6217
6218_ACEOF
6219 case "$host_os" in
6220 aix*) gl_absname_cpp="$ac_cpp -C" ;;
6221 *) gl_absname_cpp="$ac_cpp" ;;
6222 esac
6223 gl_cv_next_stddef_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
6224 sed -n '\#/stddef.h#{
6225 s#.*"\(.*/stddef.h\)".*#\1#
6226 s#^/[^/]#//&#
6227 p
6228 q
6229 }'`'"'
6230 else
6231 gl_cv_next_stddef_h='<'stddef.h'>'
6232 fi
6233
6234fi
6235{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
6236$as_echo "$gl_cv_next_stddef_h" >&6; }
6237 fi
6238 NEXT_STDDEF_H=$gl_cv_next_stddef_h
6239
6240 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
6241 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
6242 gl_next_as_first_directive='<'stddef.h'>'
6243 else
6244 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
6245 gl_next_as_first_directive=$gl_cv_next_stddef_h
6246 fi
6247 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive
6248
6249
6250
6251 fi
6252
6253 # Code from module stdint:
6254
6255
783e057b
DJ
6256
6257 if test $ac_cv_type_long_long_int = yes; then
6258 HAVE_LONG_LONG_INT=1
6259 else
6260 HAVE_LONG_LONG_INT=0
6261 fi
6262
6263
6264 if test $ac_cv_type_unsigned_long_long_int = yes; then
6265 HAVE_UNSIGNED_LONG_LONG_INT=1
6266 else
6267 HAVE_UNSIGNED_LONG_LONG_INT=0
6268 fi
6269
6270
6271 if test $ac_cv_header_inttypes_h = yes; then
6272 HAVE_INTTYPES_H=1
6273 else
6274 HAVE_INTTYPES_H=0
6275 fi
6276
6277
6278 if test $ac_cv_header_sys_types_h = yes; then
6279 HAVE_SYS_TYPES_H=1
6280 else
6281 HAVE_SYS_TYPES_H=0
6282 fi
6283
6284
6285
6286
6287
f434ba03 6288
783e057b
DJ
6289 :
6290
6291
6292
6293
6294
6295
6296
6297 if test $gl_cv_have_include_next = yes; then
6298 gl_cv_next_stdint_h='<'stdint.h'>'
6299 else
81ecdfbb
RW
6300 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdint.h>" >&5
6301$as_echo_n "checking absolute name of <stdint.h>... " >&6; }
6302if test "${gl_cv_next_stdint_h+set}" = set; then :
6303 $as_echo_n "(cached) " >&6
783e057b
DJ
6304else
6305
f434ba03
PA
6306 if test $ac_cv_header_stdint_h = yes; then
6307 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
783e057b
DJ
6308/* end confdefs.h. */
6309#include <stdint.h>
6310
6311_ACEOF
f434ba03
PA
6312 case "$host_os" in
6313 aix*) gl_absname_cpp="$ac_cpp -C" ;;
6314 *) gl_absname_cpp="$ac_cpp" ;;
6315 esac
6316 gl_cv_next_stdint_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
6317 sed -n '\#/stdint.h#{
6318 s#.*"\(.*/stdint.h\)".*#\1#
6319 s#^/[^/]#//&#
6320 p
6321 q
6322 }'`'"'
6323 else
6324 gl_cv_next_stdint_h='<'stdint.h'>'
6325 fi
783e057b
DJ
6326
6327fi
81ecdfbb
RW
6328{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdint_h" >&5
6329$as_echo "$gl_cv_next_stdint_h" >&6; }
783e057b
DJ
6330 fi
6331 NEXT_STDINT_H=$gl_cv_next_stdint_h
6332
f434ba03
PA
6333 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
6334 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
6335 gl_next_as_first_directive='<'stdint.h'>'
6336 else
6337 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
6338 gl_next_as_first_directive=$gl_cv_next_stdint_h
6339 fi
6340 NEXT_AS_FIRST_DIRECTIVE_STDINT_H=$gl_next_as_first_directive
6341
783e057b
DJ
6342
6343
6344 if test $ac_cv_header_stdint_h = yes; then
6345 HAVE_STDINT_H=1
6346 else
6347 HAVE_STDINT_H=0
6348 fi
6349
6350
6351 if test $ac_cv_header_stdint_h = yes; then
81ecdfbb
RW
6352 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h conforms to C99" >&5
6353$as_echo_n "checking whether stdint.h conforms to C99... " >&6; }
6354if test "${gl_cv_header_working_stdint_h+set}" = set; then :
6355 $as_echo_n "(cached) " >&6
783e057b
DJ
6356else
6357 gl_cv_header_working_stdint_h=no
81ecdfbb 6358 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
783e057b
DJ
6359/* end confdefs.h. */
6360
81ecdfbb 6361
783e057b
DJ
6362#define __STDC_LIMIT_MACROS 1 /* to make it work also in C++ mode */
6363#define __STDC_CONSTANT_MACROS 1 /* to make it work also in C++ mode */
6364#define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
6365#include <stdint.h>
6366/* Dragonfly defines WCHAR_MIN, WCHAR_MAX only in <wchar.h>. */
6367#if !(defined WCHAR_MIN && defined WCHAR_MAX)
6368#error "WCHAR_MIN, WCHAR_MAX not defined in <stdint.h>"
6369#endif
6370
6371
6372 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
6373 included before <wchar.h>. */
6374 #include <stddef.h>
6375 #include <signal.h>
6376 #if HAVE_WCHAR_H
6377 # include <stdio.h>
6378 # include <time.h>
6379 # include <wchar.h>
6380 #endif
6381
6382
6383#ifdef INT8_MAX
6384int8_t a1 = INT8_MAX;
6385int8_t a1min = INT8_MIN;
6386#endif
6387#ifdef INT16_MAX
6388int16_t a2 = INT16_MAX;
6389int16_t a2min = INT16_MIN;
6390#endif
6391#ifdef INT32_MAX
6392int32_t a3 = INT32_MAX;
6393int32_t a3min = INT32_MIN;
6394#endif
6395#ifdef INT64_MAX
6396int64_t a4 = INT64_MAX;
6397int64_t a4min = INT64_MIN;
6398#endif
6399#ifdef UINT8_MAX
6400uint8_t b1 = UINT8_MAX;
6401#else
6402typedef int b1[(unsigned char) -1 != 255 ? 1 : -1];
6403#endif
6404#ifdef UINT16_MAX
6405uint16_t b2 = UINT16_MAX;
6406#endif
6407#ifdef UINT32_MAX
6408uint32_t b3 = UINT32_MAX;
6409#endif
6410#ifdef UINT64_MAX
6411uint64_t b4 = UINT64_MAX;
6412#endif
6413int_least8_t c1 = INT8_C (0x7f);
6414int_least8_t c1max = INT_LEAST8_MAX;
6415int_least8_t c1min = INT_LEAST8_MIN;
6416int_least16_t c2 = INT16_C (0x7fff);
6417int_least16_t c2max = INT_LEAST16_MAX;
6418int_least16_t c2min = INT_LEAST16_MIN;
6419int_least32_t c3 = INT32_C (0x7fffffff);
6420int_least32_t c3max = INT_LEAST32_MAX;
6421int_least32_t c3min = INT_LEAST32_MIN;
6422int_least64_t c4 = INT64_C (0x7fffffffffffffff);
6423int_least64_t c4max = INT_LEAST64_MAX;
6424int_least64_t c4min = INT_LEAST64_MIN;
6425uint_least8_t d1 = UINT8_C (0xff);
6426uint_least8_t d1max = UINT_LEAST8_MAX;
6427uint_least16_t d2 = UINT16_C (0xffff);
6428uint_least16_t d2max = UINT_LEAST16_MAX;
6429uint_least32_t d3 = UINT32_C (0xffffffff);
6430uint_least32_t d3max = UINT_LEAST32_MAX;
6431uint_least64_t d4 = UINT64_C (0xffffffffffffffff);
6432uint_least64_t d4max = UINT_LEAST64_MAX;
6433int_fast8_t e1 = INT_FAST8_MAX;
6434int_fast8_t e1min = INT_FAST8_MIN;
6435int_fast16_t e2 = INT_FAST16_MAX;
6436int_fast16_t e2min = INT_FAST16_MIN;
6437int_fast32_t e3 = INT_FAST32_MAX;
6438int_fast32_t e3min = INT_FAST32_MIN;
6439int_fast64_t e4 = INT_FAST64_MAX;
6440int_fast64_t e4min = INT_FAST64_MIN;
6441uint_fast8_t f1 = UINT_FAST8_MAX;
6442uint_fast16_t f2 = UINT_FAST16_MAX;
6443uint_fast32_t f3 = UINT_FAST32_MAX;
6444uint_fast64_t f4 = UINT_FAST64_MAX;
6445#ifdef INTPTR_MAX
6446intptr_t g = INTPTR_MAX;
6447intptr_t gmin = INTPTR_MIN;
6448#endif
6449#ifdef UINTPTR_MAX
6450uintptr_t h = UINTPTR_MAX;
6451#endif
6452intmax_t i = INTMAX_MAX;
6453uintmax_t j = UINTMAX_MAX;
6454
6455#include <limits.h> /* for CHAR_BIT */
6456#define TYPE_MINIMUM(t) \
6457 ((t) ((t) 0 < (t) -1 ? (t) 0 : ~ (t) 0 << (sizeof (t) * CHAR_BIT - 1)))
6458#define TYPE_MAXIMUM(t) \
6459 ((t) ((t) 0 < (t) -1 ? (t) -1 : ~ (~ (t) 0 << (sizeof (t) * CHAR_BIT - 1))))
6460struct s {
6461 int check_PTRDIFF:
6462 PTRDIFF_MIN == TYPE_MINIMUM (ptrdiff_t)
6463 && PTRDIFF_MAX == TYPE_MAXIMUM (ptrdiff_t)
6464 ? 1 : -1;
6465 /* Detect bug in FreeBSD 6.0 / ia64. */
6466 int check_SIG_ATOMIC:
6467 SIG_ATOMIC_MIN == TYPE_MINIMUM (sig_atomic_t)
6468 && SIG_ATOMIC_MAX == TYPE_MAXIMUM (sig_atomic_t)
6469 ? 1 : -1;
6470 int check_SIZE: SIZE_MAX == TYPE_MAXIMUM (size_t) ? 1 : -1;
6471 int check_WCHAR:
6472 WCHAR_MIN == TYPE_MINIMUM (wchar_t)
6473 && WCHAR_MAX == TYPE_MAXIMUM (wchar_t)
6474 ? 1 : -1;
6475 /* Detect bug in mingw. */
6476 int check_WINT:
6477 WINT_MIN == TYPE_MINIMUM (wint_t)
6478 && WINT_MAX == TYPE_MAXIMUM (wint_t)
6479 ? 1 : -1;
6480
f434ba03
PA
6481 /* Detect bugs in glibc 2.4 and Solaris 10 stdint.h, among others. */
6482 int check_UINT8_C:
6483 (-1 < UINT8_C (0)) == (-1 < (uint_least8_t) 0) ? 1 : -1;
6484 int check_UINT16_C:
6485 (-1 < UINT16_C (0)) == (-1 < (uint_least16_t) 0) ? 1 : -1;
6486
6487 /* Detect bugs in OpenBSD 3.9 stdint.h. */
6488#ifdef UINT8_MAX
6489 int check_uint8: (uint8_t) -1 == UINT8_MAX ? 1 : -1;
6490#endif
6491#ifdef UINT16_MAX
6492 int check_uint16: (uint16_t) -1 == UINT16_MAX ? 1 : -1;
6493#endif
6494#ifdef UINT32_MAX
6495 int check_uint32: (uint32_t) -1 == UINT32_MAX ? 1 : -1;
6496#endif
6497#ifdef UINT64_MAX
6498 int check_uint64: (uint64_t) -1 == UINT64_MAX ? 1 : -1;
6499#endif
6500 int check_uint_least8: (uint_least8_t) -1 == UINT_LEAST8_MAX ? 1 : -1;
6501 int check_uint_least16: (uint_least16_t) -1 == UINT_LEAST16_MAX ? 1 : -1;
6502 int check_uint_least32: (uint_least32_t) -1 == UINT_LEAST32_MAX ? 1 : -1;
6503 int check_uint_least64: (uint_least64_t) -1 == UINT_LEAST64_MAX ? 1 : -1;
6504 int check_uint_fast8: (uint_fast8_t) -1 == UINT_FAST8_MAX ? 1 : -1;
6505 int check_uint_fast16: (uint_fast16_t) -1 == UINT_FAST16_MAX ? 1 : -1;
6506 int check_uint_fast32: (uint_fast32_t) -1 == UINT_FAST32_MAX ? 1 : -1;
6507 int check_uint_fast64: (uint_fast64_t) -1 == UINT_FAST64_MAX ? 1 : -1;
6508 int check_uintptr: (uintptr_t) -1 == UINTPTR_MAX ? 1 : -1;
6509 int check_uintmax: (uintmax_t) -1 == UINTMAX_MAX ? 1 : -1;
6510 int check_size: (size_t) -1 == SIZE_MAX ? 1 : -1;
6511};
6512
6513int
6514main ()
6515{
6516
6517 ;
6518 return 0;
6519}
6520_ACEOF
6521if ac_fn_c_try_compile "$LINENO"; then :
6522 if test "$cross_compiling" = yes; then :
6523 gl_cv_header_working_stdint_h=yes
6524
6525else
6526 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6527/* end confdefs.h. */
6528
6529
6530#define __STDC_LIMIT_MACROS 1 /* to make it work also in C++ mode */
6531#define __STDC_CONSTANT_MACROS 1 /* to make it work also in C++ mode */
6532#define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
6533#include <stdint.h>
6534
783e057b 6535
f434ba03
PA
6536 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
6537 included before <wchar.h>. */
6538 #include <stddef.h>
6539 #include <signal.h>
6540 #if HAVE_WCHAR_H
6541 # include <stdio.h>
6542 # include <time.h>
6543 # include <wchar.h>
6544 #endif
6545
6546
6547#include <stdio.h>
6548#include <string.h>
6549#define MVAL(macro) MVAL1(macro)
6550#define MVAL1(expression) #expression
6551static const char *macro_values[] =
6552 {
6553#ifdef INT8_MAX
6554 MVAL (INT8_MAX),
6555#endif
6556#ifdef INT16_MAX
6557 MVAL (INT16_MAX),
6558#endif
6559#ifdef INT32_MAX
6560 MVAL (INT32_MAX),
6561#endif
6562#ifdef INT64_MAX
6563 MVAL (INT64_MAX),
6564#endif
783e057b 6565#ifdef UINT8_MAX
f434ba03 6566 MVAL (UINT8_MAX),
783e057b
DJ
6567#endif
6568#ifdef UINT16_MAX
f434ba03 6569 MVAL (UINT16_MAX),
783e057b
DJ
6570#endif
6571#ifdef UINT32_MAX
f434ba03 6572 MVAL (UINT32_MAX),
783e057b
DJ
6573#endif
6574#ifdef UINT64_MAX
f434ba03 6575 MVAL (UINT64_MAX),
783e057b 6576#endif
f434ba03
PA
6577 NULL
6578 };
783e057b
DJ
6579
6580int
6581main ()
6582{
6583
f434ba03
PA
6584 const char **mv;
6585 for (mv = macro_values; *mv != NULL; mv++)
6586 {
6587 const char *value = *mv;
6588 /* Test whether it looks like a cast expression. */
6589 if (strncmp (value, "((unsigned int)"/*)*/, 15) == 0
6590 || strncmp (value, "((unsigned short)"/*)*/, 17) == 0
6591 || strncmp (value, "((unsigned char)"/*)*/, 16) == 0
6592 || strncmp (value, "((int)"/*)*/, 6) == 0
6593 || strncmp (value, "((signed short)"/*)*/, 15) == 0
6594 || strncmp (value, "((signed char)"/*)*/, 14) == 0)
6595 return 1;
6596 }
6597 return 0;
6598
783e057b
DJ
6599 ;
6600 return 0;
6601}
6602_ACEOF
f434ba03 6603if ac_fn_c_try_run "$LINENO"; then :
783e057b 6604 gl_cv_header_working_stdint_h=yes
f434ba03
PA
6605fi
6606rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6607 conftest.$ac_objext conftest.beam conftest.$ac_ext
6608fi
6609
6610
783e057b 6611fi
81ecdfbb 6612rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
f434ba03 6613
783e057b 6614fi
81ecdfbb
RW
6615{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdint_h" >&5
6616$as_echo "$gl_cv_header_working_stdint_h" >&6; }
783e057b
DJ
6617 fi
6618 if test "$gl_cv_header_working_stdint_h" = yes; then
6619 STDINT_H=
6620 else
81ecdfbb
RW
6621 for ac_header in sys/inttypes.h sys/bitypes.h
6622do :
6623 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6624ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
6625eval as_val=\$$as_ac_Header
6626 if test "x$as_val" = x""yes; then :
783e057b 6627 cat >>confdefs.h <<_ACEOF
81ecdfbb 6628#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
783e057b
DJ
6629_ACEOF
6630
6631fi
6632
6633done
6634
6635 if test $ac_cv_header_sys_inttypes_h = yes; then
6636 HAVE_SYS_INTTYPES_H=1
6637 else
6638 HAVE_SYS_INTTYPES_H=0
6639 fi
6640
6641 if test $ac_cv_header_sys_bitypes_h = yes; then
6642 HAVE_SYS_BITYPES_H=1
6643 else
6644 HAVE_SYS_BITYPES_H=0
6645 fi
6646
6647
6648
6649 :
6650
6651
6652
6653
6654
6655
6656
6657
f434ba03
PA
6658 if test $APPLE_UNIVERSAL_BUILD = 0; then
6659
6660
6661 for gltype in ptrdiff_t size_t ; do
6662 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
6663$as_echo_n "checking for bit size of $gltype... " >&6; }
6664if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
6665 $as_echo_n "(cached) " >&6
6666else
6667 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
6668 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
6669 included before <wchar.h>. */
6670 #include <stddef.h>
6671 #include <signal.h>
6672 #if HAVE_WCHAR_H
6673 # include <stdio.h>
6674 # include <time.h>
6675 # include <wchar.h>
6676 #endif
6677
6678#include <limits.h>"; then :
6679
6680else
6681 result=unknown
6682fi
6683
6684 eval gl_cv_bitsizeof_${gltype}=\$result
6685
6686fi
6687eval ac_res=\$gl_cv_bitsizeof_${gltype}
6688 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
6689$as_echo "$ac_res" >&6; }
6690 eval result=\$gl_cv_bitsizeof_${gltype}
6691 if test $result = unknown; then
6692 result=0
6693 fi
6694 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
6695 cat >>confdefs.h <<_ACEOF
6696#define BITSIZEOF_${GLTYPE} $result
6697_ACEOF
6698
6699 eval BITSIZEOF_${GLTYPE}=\$result
6700 done
6701
6702
6703 fi
6704
783e057b 6705
f434ba03 6706 for gltype in sig_atomic_t wchar_t wint_t ; do
81ecdfbb
RW
6707 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
6708$as_echo_n "checking for bit size of $gltype... " >&6; }
6709if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
6710 $as_echo_n "(cached) " >&6
6711else
6712 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
6713 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
6714 included before <wchar.h>. */
6715 #include <stddef.h>
6716 #include <signal.h>
6717 #if HAVE_WCHAR_H
6718 # include <stdio.h>
6719 # include <time.h>
6720 # include <wchar.h>
6721 #endif
6722
6723#include <limits.h>"; then :
6724
6725else
6726 result=unknown
6727fi
6728
6729 eval gl_cv_bitsizeof_${gltype}=\$result
6730
6731fi
6732eval ac_res=\$gl_cv_bitsizeof_${gltype}
6733 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
6734$as_echo "$ac_res" >&6; }
6735 eval result=\$gl_cv_bitsizeof_${gltype}
6736 if test $result = unknown; then
6737 result=0
6738 fi
6739 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
6740 cat >>confdefs.h <<_ACEOF
6741#define BITSIZEOF_${GLTYPE} $result
6742_ACEOF
783e057b 6743
81ecdfbb
RW
6744 eval BITSIZEOF_${GLTYPE}=\$result
6745 done
783e057b
DJ
6746
6747
6748
6749
81ecdfbb
RW
6750 for gltype in sig_atomic_t wchar_t wint_t ; do
6751 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gltype is signed" >&5
6752$as_echo_n "checking whether $gltype is signed... " >&6; }
6753if { as_var=gl_cv_type_${gltype}_signed; eval "test \"\${$as_var+set}\" = set"; }; then :
6754 $as_echo_n "(cached) " >&6
783e057b 6755else
81ecdfbb 6756 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
783e057b
DJ
6757/* end confdefs.h. */
6758
6759 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
6760 included before <wchar.h>. */
6761 #include <stddef.h>
6762 #include <signal.h>
6763 #if HAVE_WCHAR_H
6764 # include <stdio.h>
6765 # include <time.h>
6766 # include <wchar.h>
6767 #endif
6768
6769 int verify[2 * (($gltype) -1 < ($gltype) 0) - 1];
6770int
6771main ()
6772{
6773
6774 ;
6775 return 0;
6776}
6777_ACEOF
81ecdfbb 6778if ac_fn_c_try_compile "$LINENO"; then :
783e057b
DJ
6779 result=yes
6780else
81ecdfbb 6781 result=no
20e95c23 6782fi
81ecdfbb 6783rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
783e057b
DJ
6784 eval gl_cv_type_${gltype}_signed=\$result
6785
6786fi
81ecdfbb
RW
6787eval ac_res=\$gl_cv_type_${gltype}_signed
6788 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
6789$as_echo "$ac_res" >&6; }
783e057b
DJ
6790 eval result=\$gl_cv_type_${gltype}_signed
6791 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
6792 if test "$result" = yes; then
6793 cat >>confdefs.h <<_ACEOF
6794#define HAVE_SIGNED_${GLTYPE} 1
6795_ACEOF
6796
6797 eval HAVE_SIGNED_${GLTYPE}=1
6798 else
6799 eval HAVE_SIGNED_${GLTYPE}=0
6800 fi
6801 done
6802
6803
6804 gl_cv_type_ptrdiff_t_signed=yes
6805 gl_cv_type_size_t_signed=no
f434ba03 6806 if test $APPLE_UNIVERSAL_BUILD = 0; then
783e057b
DJ
6807
6808
f434ba03 6809 for gltype in ptrdiff_t size_t ; do
81ecdfbb
RW
6810 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
6811$as_echo_n "checking for $gltype integer literal suffix... " >&6; }
6812if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
6813 $as_echo_n "(cached) " >&6
c906108c 6814else
783e057b
DJ
6815 eval gl_cv_type_${gltype}_suffix=no
6816 eval result=\$gl_cv_type_${gltype}_signed
6817 if test "$result" = yes; then
6818 glsufu=
6819 else
6820 glsufu=u
6821 fi
6822 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
6823 case $glsuf in
6824 '') gltype1='int';;
f434ba03
PA
6825 l) gltype1='long int';;
6826 ll) gltype1='long long int';;
6827 i64) gltype1='__int64';;
6828 u) gltype1='unsigned int';;
6829 ul) gltype1='unsigned long int';;
6830 ull) gltype1='unsigned long long int';;
783e057b
DJ
6831 ui64)gltype1='unsigned __int64';;
6832 esac
81ecdfbb 6833 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
783e057b
DJ
6834/* end confdefs.h. */
6835
6836 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
6837 included before <wchar.h>. */
6838 #include <stddef.h>
6839 #include <signal.h>
6840 #if HAVE_WCHAR_H
6841 # include <stdio.h>
6842 # include <time.h>
6843 # include <wchar.h>
6844 #endif
6845
6846 extern $gltype foo;
6847 extern $gltype1 foo;
6848int
6849main ()
6850{
6851
6852 ;
6853 return 0;
6854}
6855_ACEOF
81ecdfbb 6856if ac_fn_c_try_compile "$LINENO"; then :
783e057b 6857 eval gl_cv_type_${gltype}_suffix=\$glsuf
783e057b 6858fi
81ecdfbb 6859rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
783e057b
DJ
6860 eval result=\$gl_cv_type_${gltype}_suffix
6861 test "$result" != no && break
6862 done
6863fi
81ecdfbb
RW
6864eval ac_res=\$gl_cv_type_${gltype}_suffix
6865 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
6866$as_echo "$ac_res" >&6; }
783e057b
DJ
6867 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
6868 eval result=\$gl_cv_type_${gltype}_suffix
6869 test "$result" = no && result=
6870 eval ${GLTYPE}_SUFFIX=\$result
6871 cat >>confdefs.h <<_ACEOF
6872#define ${GLTYPE}_SUFFIX $result
6873_ACEOF
6874
6875 done
6876
6877
783e057b
DJ
6878 fi
6879
6880
f434ba03
PA
6881 for gltype in sig_atomic_t wchar_t wint_t ; do
6882 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
6883$as_echo_n "checking for $gltype integer literal suffix... " >&6; }
6884if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
81ecdfbb 6885 $as_echo_n "(cached) " >&6
783e057b 6886else
f434ba03
PA
6887 eval gl_cv_type_${gltype}_suffix=no
6888 eval result=\$gl_cv_type_${gltype}_signed
6889 if test "$result" = yes; then
6890 glsufu=
6891 else
6892 glsufu=u
6893 fi
6894 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
6895 case $glsuf in
6896 '') gltype1='int';;
6897 l) gltype1='long int';;
6898 ll) gltype1='long long int';;
6899 i64) gltype1='__int64';;
6900 u) gltype1='unsigned int';;
6901 ul) gltype1='unsigned long int';;
6902 ull) gltype1='unsigned long long int';;
6903 ui64)gltype1='unsigned __int64';;
6904 esac
6905 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
81ecdfbb 6906/* end confdefs.h. */
f434ba03
PA
6907
6908 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
6909 included before <wchar.h>. */
6910 #include <stddef.h>
6911 #include <signal.h>
6912 #if HAVE_WCHAR_H
6913 # include <stdio.h>
6914 # include <time.h>
6915 # include <wchar.h>
6916 #endif
6917
6918 extern $gltype foo;
6919 extern $gltype1 foo;
6920int
6921main ()
6922{
6923
6924 ;
6925 return 0;
6926}
783e057b 6927_ACEOF
81ecdfbb 6928if ac_fn_c_try_compile "$LINENO"; then :
f434ba03 6929 eval gl_cv_type_${gltype}_suffix=\$glsuf
783e057b 6930fi
81ecdfbb 6931rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
f434ba03
PA
6932 eval result=\$gl_cv_type_${gltype}_suffix
6933 test "$result" != no && break
6934 done
783e057b 6935fi
f434ba03
PA
6936eval ac_res=\$gl_cv_type_${gltype}_suffix
6937 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
6938$as_echo "$ac_res" >&6; }
6939 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
6940 eval result=\$gl_cv_type_${gltype}_suffix
6941 test "$result" = no && result=
6942 eval ${GLTYPE}_SUFFIX=\$result
6943 cat >>confdefs.h <<_ACEOF
6944#define ${GLTYPE}_SUFFIX $result
6945_ACEOF
6946
6947 done
6948
6949
6950
6951 STDINT_H=stdint.h
783e057b
DJ
6952 fi
6953
6954
f434ba03
PA
6955 # Code from module string:
6956
6957
6958
6959 # Code from module warn-on-use:
6960 # Code from module wchar:
6961
6962
6963
6964
783e057b
DJ
6965 :
6966
6967
6968
6969
6970
783e057b
DJ
6971
6972
6973
6974
6975 :
6976
6977
6978
6979
6980
6981
6982
6983 if test $gl_cv_have_include_next = yes; then
6984 gl_cv_next_wchar_h='<'wchar.h'>'
6985 else
81ecdfbb
RW
6986 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <wchar.h>" >&5
6987$as_echo_n "checking absolute name of <wchar.h>... " >&6; }
6988if test "${gl_cv_next_wchar_h+set}" = set; then :
6989 $as_echo_n "(cached) " >&6
783e057b
DJ
6990else
6991
f434ba03
PA
6992 if test $ac_cv_header_wchar_h = yes; then
6993 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
783e057b
DJ
6994/* end confdefs.h. */
6995#include <wchar.h>
6996
6997_ACEOF
f434ba03
PA
6998 case "$host_os" in
6999 aix*) gl_absname_cpp="$ac_cpp -C" ;;
7000 *) gl_absname_cpp="$ac_cpp" ;;
7001 esac
7002 gl_cv_next_wchar_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
7003 sed -n '\#/wchar.h#{
7004 s#.*"\(.*/wchar.h\)".*#\1#
7005 s#^/[^/]#//&#
7006 p
7007 q
7008 }'`'"'
7009 else
7010 gl_cv_next_wchar_h='<'wchar.h'>'
7011 fi
783e057b
DJ
7012
7013fi
81ecdfbb
RW
7014{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_wchar_h" >&5
7015$as_echo "$gl_cv_next_wchar_h" >&6; }
783e057b
DJ
7016 fi
7017 NEXT_WCHAR_H=$gl_cv_next_wchar_h
7018
f434ba03
PA
7019 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
7020 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
7021 gl_next_as_first_directive='<'wchar.h'>'
7022 else
7023 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
7024 gl_next_as_first_directive=$gl_cv_next_wchar_h
7025 fi
7026 NEXT_AS_FIRST_DIRECTIVE_WCHAR_H=$gl_next_as_first_directive
7027
7028
7029
7030 if test $ac_cv_header_wchar_h = yes; then
7031 HAVE_WCHAR_H=1
7032 else
7033 HAVE_WCHAR_H=0
7034 fi
7035
7036
7037
7038 if test $gt_cv_c_wint_t = yes; then
7039 HAVE_WINT_T=1
7040 else
7041 HAVE_WINT_T=0
7042 fi
7043
7044
7045
7046 for gl_func in btowc wctob mbsinit mbrtowc mbrlen mbsrtowcs mbsnrtowcs wcrtomb wcsrtombs wcsnrtombs wcwidth; do
7047 as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh`
7048 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5
7049$as_echo_n "checking whether $gl_func is declared without a macro... " >&6; }
7050if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then :
7051 $as_echo_n "(cached) " >&6
7052else
7053 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7054/* end confdefs.h. */
7055
7056/* Some systems require additional headers. */
7057#ifndef __GLIBC__
7058# include <stddef.h>
7059# include <stdio.h>
7060# include <time.h>
7061#endif
7062#include <wchar.h>
7063
7064int
7065main ()
7066{
7067#undef $gl_func
7068 (void) $gl_func;
7069 ;
7070 return 0;
7071}
7072_ACEOF
7073if ac_fn_c_try_compile "$LINENO"; then :
7074 eval "$as_gl_Symbol=yes"
7075else
7076 eval "$as_gl_Symbol=no"
7077fi
7078rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7079fi
7080eval ac_res=\$$as_gl_Symbol
7081 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
7082$as_echo "$ac_res" >&6; }
7083 eval as_val=\$$as_gl_Symbol
7084 if test "x$as_val" = x""yes; then :
7085 cat >>confdefs.h <<_ACEOF
7086#define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1
7087_ACEOF
7088
7089 eval ac_cv_have_decl_$gl_func=yes
7090fi
7091 done
7092
7093
7094 # Code from module dummy:
7095 # End of code from modules
7096
7097
c906108c 7098
c906108c 7099
c906108c 7100
c906108c 7101
c906108c 7102
c906108c 7103
c906108c 7104
783e057b
DJ
7105 gltests_libdeps=
7106 gltests_ltlibdeps=
20e95c23 7107
20e95c23 7108
20e95c23 7109
f434ba03
PA
7110
7111
7112
7113
7114
7115
783e057b 7116 gl_source_base='tests'
f434ba03
PA
7117 gltests_WITNESS=IN_`echo "${PACKAGE-$PACKAGE_TARNAME}" | LC_ALL=C tr abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ | LC_ALL=C sed -e 's/[^A-Z0-9_]/_/g'`_GNULIB_TESTS
7118
7119 gl_module_indicator_condition=$gltests_WITNESS
7120
7121
7122
7123
7124
c906108c 7125
bec39cab 7126
bec39cab 7127
783e057b
DJ
7128
7129 LIBGNU_LIBDEPS="$gl_libdeps"
7130
7131 LIBGNU_LTLIBDEPS="$gl_ltlibdeps"
7132
7133
e28b3332 7134
d5af19ba
DJ
7135# For Makefile dependencies.
7136GNULIB_STDINT_H=
7137if test x"$STDINT_H" != x; then
7138 GNULIB_STDINT_H=gnulib/$STDINT_H
7139fi
7140
7141
bec39cab
AC
7142PACKAGE=gdb
7143
7144cat >>confdefs.h <<_ACEOF
7145#define PACKAGE "$PACKAGE"
7146_ACEOF
7147
7148
7149
e28b3332
DJ
7150# GDB does not use automake, but gnulib does. This line lets us
7151# generate its Makefile.in.
81ecdfbb
RW
7152am__api_version='1.11'
7153
e28b3332
DJ
7154# Find a good install program. We prefer a C program (faster),
7155# so one script is as good as another. But avoid the broken or
7156# incompatible versions:
7157# SysV /etc/install, /usr/sbin/install
7158# SunOS /usr/etc/install
7159# IRIX /sbin/install
7160# AIX /bin/install
7161# AmigaOS /C/install, which installs bootblocks on floppy discs
7162# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
7163# AFS /usr/afsws/bin/install, which mishandles nonexistent args
7164# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
7165# OS/2's system install, which has a completely different semantic
7166# ./install, which can be erroneously created by make from ./install.sh.
85541719 7167# Reject install programs that cannot install multiple files.
81ecdfbb
RW
7168{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
7169$as_echo_n "checking for a BSD-compatible install... " >&6; }
e28b3332 7170if test -z "$INSTALL"; then
81ecdfbb
RW
7171if test "${ac_cv_path_install+set}" = set; then :
7172 $as_echo_n "(cached) " >&6
e28b3332
DJ
7173else
7174 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7175for as_dir in $PATH
7176do
7177 IFS=$as_save_IFS
7178 test -z "$as_dir" && as_dir=.
81ecdfbb
RW
7179 # Account for people who put trailing slashes in PATH elements.
7180case $as_dir/ in #((
7181 ./ | .// | /[cC]/* | \
e28b3332 7182 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
81ecdfbb 7183 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
e28b3332
DJ
7184 /usr/ucb/* ) ;;
7185 *)
7186 # OSF1 and SCO ODT 3.0 have their own names for install.
7187 # Don't use installbsd from OSF since it installs stuff as root
7188 # by default.
7189 for ac_prog in ginstall scoinst install; do
7190 for ac_exec_ext in '' $ac_executable_extensions; do
81ecdfbb 7191 if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
e28b3332
DJ
7192 if test $ac_prog = install &&
7193 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
7194 # AIX install. It has an incompatible calling convention.
7195 :
7196 elif test $ac_prog = install &&
7197 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
7198 # program-specific install script used by HP pwplus--don't use.
7199 :
7200 else
85541719
DE
7201 rm -rf conftest.one conftest.two conftest.dir
7202 echo one > conftest.one
7203 echo two > conftest.two
7204 mkdir conftest.dir
7205 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
7206 test -s conftest.one && test -s conftest.two &&
7207 test -s conftest.dir/conftest.one &&
7208 test -s conftest.dir/conftest.two
7209 then
7210 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
7211 break 3
7212 fi
e28b3332
DJ
7213 fi
7214 fi
7215 done
7216 done
7217 ;;
7218esac
81ecdfbb
RW
7219
7220 done
7221IFS=$as_save_IFS
e28b3332 7222
85541719 7223rm -rf conftest.one conftest.two conftest.dir
e28b3332
DJ
7224
7225fi
7226 if test "${ac_cv_path_install+set}" = set; then
7227 INSTALL=$ac_cv_path_install
7228 else
85541719
DE
7229 # As a last resort, use the slow shell script. Don't cache a
7230 # value for INSTALL within a source directory, because that will
e28b3332 7231 # break other packages using the cache if that directory is
85541719 7232 # removed, or if the value is a relative name.
e28b3332
DJ
7233 INSTALL=$ac_install_sh
7234 fi
7235fi
81ecdfbb
RW
7236{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
7237$as_echo "$INSTALL" >&6; }
e28b3332
DJ
7238
7239# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
7240# It thinks the first close brace ends the variable substitution.
7241test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
7242
7243test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
7244
7245test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
7246
81ecdfbb
RW
7247{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
7248$as_echo_n "checking whether build environment is sane... " >&6; }
e28b3332
DJ
7249# Just in case
7250sleep 1
7251echo timestamp > conftest.file
81ecdfbb
RW
7252# Reject unsafe characters in $srcdir or the absolute working directory
7253# name. Accept space and tab only in the latter.
7254am_lf='
7255'
7256case `pwd` in
7257 *[\\\"\#\$\&\'\`$am_lf]*)
7258 as_fn_error "unsafe absolute working directory name" "$LINENO" 5;;
7259esac
7260case $srcdir in
7261 *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
7262 as_fn_error "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;;
7263esac
7264
e28b3332
DJ
7265# Do `set' in a subshell so we don't clobber the current shell's
7266# arguments. Must try -L first in case configure is actually a
7267# symlink; some systems play weird games with the mod time of symlinks
7268# (eg FreeBSD returns the mod time of the symlink's containing
7269# directory).
7270if (
81ecdfbb 7271 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
e28b3332
DJ
7272 if test "$*" = "X"; then
7273 # -L didn't work.
81ecdfbb 7274 set X `ls -t "$srcdir/configure" conftest.file`
e28b3332
DJ
7275 fi
7276 rm -f conftest.file
7277 if test "$*" != "X $srcdir/configure conftest.file" \
7278 && test "$*" != "X conftest.file $srcdir/configure"; then
7279
7280 # If neither matched, then we have a broken ls. This can happen
7281 # if, for instance, CONFIG_SHELL is bash and it inherits a
7282 # broken ls alias from the environment. This has actually
7283 # happened. Such a system could not be considered "sane".
81ecdfbb
RW
7284 as_fn_error "ls -t appears to fail. Make sure there is not a broken
7285alias in your environment" "$LINENO" 5
e28b3332
DJ
7286 fi
7287
7288 test "$2" = conftest.file
7289 )
7290then
7291 # Ok.
7292 :
7293else
81ecdfbb
RW
7294 as_fn_error "newly created file is older than distributed files!
7295Check your system clock" "$LINENO" 5
e28b3332 7296fi
81ecdfbb
RW
7297{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7298$as_echo "yes" >&6; }
e28b3332 7299test "$program_prefix" != NONE &&
81ecdfbb 7300 program_transform_name="s&^&$program_prefix&;$program_transform_name"
e28b3332
DJ
7301# Use a double $ so make ignores it.
7302test "$program_suffix" != NONE &&
81ecdfbb
RW
7303 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
7304# Double any \ or $.
e28b3332 7305# By default was `s,x,x', remove it if useless.
81ecdfbb
RW
7306ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
7307program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
e28b3332
DJ
7308
7309# expand $ac_aux_dir to an absolute path
7310am_aux_dir=`cd $ac_aux_dir && pwd`
7311
81ecdfbb
RW
7312if test x"${MISSING+set}" != xset; then
7313 case $am_aux_dir in
7314 *\ * | *\ *)
7315 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
7316 *)
7317 MISSING="\${SHELL} $am_aux_dir/missing" ;;
7318 esac
7319fi
e28b3332
DJ
7320# Use eval to expand $SHELL
7321if eval "$MISSING --run true"; then
7322 am_missing_run="$MISSING --run "
7323else
7324 am_missing_run=
81ecdfbb
RW
7325 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5
7326$as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
7327fi
7328
7329if test x"${install_sh}" != xset; then
7330 case $am_aux_dir in
7331 *\ * | *\ *)
7332 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
7333 *)
7334 install_sh="\${SHELL} $am_aux_dir/install-sh"
7335 esac
7336fi
7337
7338# Installed binaries are usually stripped using `strip' when the user
7339# run `make install-strip'. However `strip' might not be the right
7340# tool to use in cross-compilation environments, therefore Automake
7341# will honor the `STRIP' environment variable to overrule this program.
7342if test "$cross_compiling" != no; then
7343 if test -n "$ac_tool_prefix"; then
7344 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
7345set dummy ${ac_tool_prefix}strip; ac_word=$2
7346{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7347$as_echo_n "checking for $ac_word... " >&6; }
7348if test "${ac_cv_prog_STRIP+set}" = set; then :
7349 $as_echo_n "(cached) " >&6
7350else
7351 if test -n "$STRIP"; then
7352 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
7353else
7354as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7355for as_dir in $PATH
7356do
7357 IFS=$as_save_IFS
7358 test -z "$as_dir" && as_dir=.
7359 for ac_exec_ext in '' $ac_executable_extensions; do
7360 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7361 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
7362 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7363 break 2
7364 fi
7365done
7366 done
7367IFS=$as_save_IFS
7368
7369fi
7370fi
7371STRIP=$ac_cv_prog_STRIP
7372if test -n "$STRIP"; then
7373 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
7374$as_echo "$STRIP" >&6; }
7375else
7376 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7377$as_echo "no" >&6; }
7378fi
7379
7380
7381fi
7382if test -z "$ac_cv_prog_STRIP"; then
7383 ac_ct_STRIP=$STRIP
7384 # Extract the first word of "strip", so it can be a program name with args.
7385set dummy strip; ac_word=$2
7386{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7387$as_echo_n "checking for $ac_word... " >&6; }
7388if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then :
7389 $as_echo_n "(cached) " >&6
7390else
7391 if test -n "$ac_ct_STRIP"; then
7392 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
7393else
7394as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7395for as_dir in $PATH
7396do
7397 IFS=$as_save_IFS
7398 test -z "$as_dir" && as_dir=.
7399 for ac_exec_ext in '' $ac_executable_extensions; do
7400 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7401 ac_cv_prog_ac_ct_STRIP="strip"
7402 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7403 break 2
7404 fi
7405done
7406 done
7407IFS=$as_save_IFS
7408
7409fi
7410fi
7411ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
7412if test -n "$ac_ct_STRIP"; then
7413 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
7414$as_echo "$ac_ct_STRIP" >&6; }
7415else
7416 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7417$as_echo "no" >&6; }
7418fi
7419
7420 if test "x$ac_ct_STRIP" = x; then
7421 STRIP=":"
7422 else
7423 case $cross_compiling:$ac_tool_warned in
7424yes:)
7425{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7426$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7427ac_tool_warned=yes ;;
7428esac
7429 STRIP=$ac_ct_STRIP
7430 fi
7431else
7432 STRIP="$ac_cv_prog_STRIP"
7433fi
7434
7435fi
7436INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
7437
7438{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
7439$as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
7440if test -z "$MKDIR_P"; then
7441 if test "${ac_cv_path_mkdir+set}" = set; then :
7442 $as_echo_n "(cached) " >&6
7443else
7444 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7445for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
7446do
7447 IFS=$as_save_IFS
7448 test -z "$as_dir" && as_dir=.
7449 for ac_prog in mkdir gmkdir; do
7450 for ac_exec_ext in '' $ac_executable_extensions; do
7451 { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
7452 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
7453 'mkdir (GNU coreutils) '* | \
7454 'mkdir (coreutils) '* | \
7455 'mkdir (fileutils) '4.1*)
7456 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
7457 break 3;;
7458 esac
7459 done
7460 done
e28b3332 7461 done
81ecdfbb
RW
7462IFS=$as_save_IFS
7463
7464fi
7465
7466 if test "${ac_cv_path_mkdir+set}" = set; then
7467 MKDIR_P="$ac_cv_path_mkdir -p"
e28b3332 7468 else
81ecdfbb
RW
7469 # As a last resort, use the slow shell script. Don't cache a
7470 # value for MKDIR_P within a source directory, because that will
7471 # break other packages using the cache if that directory is
7472 # removed, or if the value is a relative name.
7473 test -d ./--version && rmdir ./--version
7474 MKDIR_P="$ac_install_sh -d"
e28b3332
DJ
7475 fi
7476fi
81ecdfbb
RW
7477{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
7478$as_echo "$MKDIR_P" >&6; }
7479
f434ba03 7480
81ecdfbb
RW
7481mkdir_p="$MKDIR_P"
7482case $mkdir_p in
7483 [\\/$]* | ?:[\\/]*) ;;
7484 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
7485esac
e28b3332
DJ
7486
7487for ac_prog in gawk mawk nawk awk
7488do
7489 # Extract the first word of "$ac_prog", so it can be a program name with args.
7490set dummy $ac_prog; ac_word=$2
81ecdfbb
RW
7491{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7492$as_echo_n "checking for $ac_word... " >&6; }
7493if test "${ac_cv_prog_AWK+set}" = set; then :
7494 $as_echo_n "(cached) " >&6
e28b3332
DJ
7495else
7496 if test -n "$AWK"; then
7497 ac_cv_prog_AWK="$AWK" # Let the user override the test.
7498else
7499as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7500for as_dir in $PATH
7501do
7502 IFS=$as_save_IFS
7503 test -z "$as_dir" && as_dir=.
81ecdfbb
RW
7504 for ac_exec_ext in '' $ac_executable_extensions; do
7505 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
e28b3332 7506 ac_cv_prog_AWK="$ac_prog"
81ecdfbb 7507 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
e28b3332
DJ
7508 break 2
7509 fi
7510done
81ecdfbb
RW
7511 done
7512IFS=$as_save_IFS
e28b3332
DJ
7513
7514fi
7515fi
7516AWK=$ac_cv_prog_AWK
7517if test -n "$AWK"; then
81ecdfbb
RW
7518 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
7519$as_echo "$AWK" >&6; }
e28b3332 7520else
81ecdfbb
RW
7521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7522$as_echo "no" >&6; }
e28b3332
DJ
7523fi
7524
81ecdfbb 7525
e28b3332
DJ
7526 test -n "$AWK" && break
7527done
7528
81ecdfbb 7529ac_config_commands="$ac_config_commands depfiles"
e28b3332
DJ
7530
7531
7532am_make=${MAKE-make}
7533cat > confinc << 'END'
7534am__doit:
81ecdfbb 7535 @echo this is the am__doit target
e28b3332
DJ
7536.PHONY: am__doit
7537END
7538# If we don't find an include directive, just comment out the code.
81ecdfbb
RW
7539{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
7540$as_echo_n "checking for style of include used by $am_make... " >&6; }
e28b3332
DJ
7541am__include="#"
7542am__quote=
7543_am_result=none
7544# First try GNU make style include.
7545echo "include confinc" > confmf
81ecdfbb
RW
7546# Ignore all kinds of additional output from `make'.
7547case `$am_make -s -f confmf 2> /dev/null` in #(
7548*the\ am__doit\ target*)
7549 am__include=include
7550 am__quote=
7551 _am_result=GNU
7552 ;;
7553esac
e28b3332
DJ
7554# Now try BSD make style include.
7555if test "$am__include" = "#"; then
7556 echo '.include "confinc"' > confmf
81ecdfbb
RW
7557 case `$am_make -s -f confmf 2> /dev/null` in #(
7558 *the\ am__doit\ target*)
7559 am__include=.include
7560 am__quote="\""
7561 _am_result=BSD
7562 ;;
7563 esac
e28b3332
DJ
7564fi
7565
7566
81ecdfbb
RW
7567{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
7568$as_echo "$_am_result" >&6; }
e28b3332
DJ
7569rm -f confinc confmf
7570
81ecdfbb
RW
7571# Check whether --enable-dependency-tracking was given.
7572if test "${enable_dependency_tracking+set}" = set; then :
7573 enableval=$enable_dependency_tracking;
7574fi
e28b3332 7575
e28b3332
DJ
7576if test "x$enable_dependency_tracking" != xno; then
7577 am_depcomp="$ac_aux_dir/depcomp"
7578 AMDEPBACKSLASH='\'
7579fi
81ecdfbb 7580 if test "x$enable_dependency_tracking" != xno; then
e28b3332
DJ
7581 AMDEP_TRUE=
7582 AMDEP_FALSE='#'
7583else
7584 AMDEP_TRUE='#'
7585 AMDEP_FALSE=
7586fi
7587
7588
81ecdfbb
RW
7589if test "`cd $srcdir && pwd`" != "`pwd`"; then
7590 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
7591 # is not polluted with repeated "-I."
7592 am__isrc=' -I$(srcdir)'
7593 # test to see if srcdir already configured
7594 if test -f $srcdir/config.status; then
7595 as_fn_error "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
7596 fi
e28b3332
DJ
7597fi
7598
7599# test whether we have cygpath
7600if test -z "$CYGPATH_W"; then
7601 if (cygpath --version) >/dev/null 2>/dev/null; then
7602 CYGPATH_W='cygpath -w'
7603 else
7604 CYGPATH_W=echo
7605 fi
7606fi
7607
7608
7609# Define the identity of the package.
7610 PACKAGE=gdb
7611 VERSION=UNUSED-VERSION
7612
7613
7614# Some tools Automake needs.
7615
7616ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
7617
7618
7619AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
7620
7621
7622AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
7623
7624
7625AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
7626
7627
7628MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
7629
e28b3332
DJ
7630# We need awk for the "check" target. The system "awk" is bad on
7631# some platforms.
7632# Always define AMTAR for backward compatibility.
7633
7634AMTAR=${AMTAR-"${am_missing_run}tar"}
7635
7636am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'
7637
7638
7639
7640
7641depcc="$CC" am_compiler_list=
7642
81ecdfbb
RW
7643{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
7644$as_echo_n "checking dependency style of $depcc... " >&6; }
7645if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then :
7646 $as_echo_n "(cached) " >&6
e28b3332
DJ
7647else
7648 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
7649 # We make a subdir and do the tests there. Otherwise we can end up
7650 # making bogus files that we don't know about and never remove. For
7651 # instance it was reported that on HP-UX the gcc test will end up
7652 # making a dummy file named `D' -- because `-MD' means `put the output
7653 # in D'.
7654 mkdir conftest.dir
7655 # Copy depcomp to subdir because otherwise we won't find it if we're
7656 # using a relative directory.
7657 cp "$am_depcomp" conftest.dir
7658 cd conftest.dir
7659 # We will build objects and dependencies in a subdirectory because
7660 # it helps to detect inapplicable dependency modes. For instance
7661 # both Tru64's cc and ICC support -MD to output dependencies as a
7662 # side effect of compilation, but ICC will put the dependencies in
7663 # the current directory while Tru64 will put them in the object
7664 # directory.
7665 mkdir sub
7666
7667 am_cv_CC_dependencies_compiler_type=none
7668 if test "$am_compiler_list" = ""; then
7669 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
7670 fi
81ecdfbb
RW
7671 am__universal=false
7672 case " $depcc " in #(
7673 *\ -arch\ *\ -arch\ *) am__universal=true ;;
7674 esac
7675
e28b3332
DJ
7676 for depmode in $am_compiler_list; do
7677 # Setup a source with many dependencies, because some compilers
7678 # like to wrap large dependency lists on column 80 (with \), and
7679 # we should not choose a depcomp mode which is confused by this.
7680 #
7681 # We need to recreate these files for each test, as the compiler may
7682 # overwrite some of them when testing with obscure command lines.
7683 # This happens at least with the AIX C compiler.
7684 : > sub/conftest.c
7685 for i in 1 2 3 4 5 6; do
7686 echo '#include "conftst'$i'.h"' >> sub/conftest.c
7687 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
7688 # Solaris 8's {/usr,}/bin/sh.
7689 touch sub/conftst$i.h
7690 done
7691 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
7692
81ecdfbb
RW
7693 # We check with `-c' and `-o' for the sake of the "dashmstdout"
7694 # mode. It turns out that the SunPro C++ compiler does not properly
7695 # handle `-M -o', and we need to detect this. Also, some Intel
7696 # versions had trouble with output in subdirs
7697 am__obj=sub/conftest.${OBJEXT-o}
7698 am__minus_obj="-o $am__obj"
e28b3332 7699 case $depmode in
81ecdfbb
RW
7700 gcc)
7701 # This depmode causes a compiler race in universal mode.
7702 test "$am__universal" = false || continue
7703 ;;
e28b3332
DJ
7704 nosideeffect)
7705 # after this tag, mechanisms are not by side-effect, so they'll
7706 # only be used when explicitly requested
7707 if test "x$enable_dependency_tracking" = xyes; then
7708 continue
7709 else
7710 break
7711 fi
7712 ;;
81ecdfbb
RW
7713 msvisualcpp | msvcmsys)
7714 # This compiler won't grok `-c -o', but also, the minuso test has
7715 # not run yet. These depmodes are late enough in the game, and
7716 # so weak that their functioning should not be impacted.
7717 am__obj=conftest.${OBJEXT-o}
7718 am__minus_obj=
7719 ;;
e28b3332
DJ
7720 none) break ;;
7721 esac
e28b3332 7722 if depmode=$depmode \
81ecdfbb 7723 source=sub/conftest.c object=$am__obj \
e28b3332 7724 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
81ecdfbb 7725 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
e28b3332 7726 >/dev/null 2>conftest.err &&
81ecdfbb 7727 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
e28b3332 7728 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
81ecdfbb 7729 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
e28b3332
DJ
7730 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
7731 # icc doesn't choke on unknown options, it will just issue warnings
7732 # or remarks (even with -Werror). So we grep stderr for any message
7733 # that says an option was ignored or not supported.
7734 # When given -MP, icc 7.0 and 7.1 complain thusly:
7735 # icc: Command line warning: ignoring option '-M'; no argument required
7736 # The diagnosis changed in icc 8.0:
7737 # icc: Command line remark: option '-MP' not supported
7738 if (grep 'ignoring option' conftest.err ||
7739 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
7740 am_cv_CC_dependencies_compiler_type=$depmode
7741 break
7742 fi
7743 fi
7744 done
7745
7746 cd ..
7747 rm -rf conftest.dir
7748else
7749 am_cv_CC_dependencies_compiler_type=none
7750fi
7751
7752fi
81ecdfbb
RW
7753{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
7754$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
e28b3332
DJ
7755CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
7756
81ecdfbb 7757 if
e28b3332
DJ
7758 test "x$enable_dependency_tracking" != xno \
7759 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
7760 am__fastdepCC_TRUE=
7761 am__fastdepCC_FALSE='#'
7762else
7763 am__fastdepCC_TRUE='#'
7764 am__fastdepCC_FALSE=
7765fi
7766
7767
7768
7769
bec39cab
AC
7770
7771
81ecdfbb
RW
7772# Check whether --with-separate-debug-dir was given.
7773if test "${with_separate_debug_dir+set}" = set; then :
7774 withval=$with_separate_debug_dir;
b14b1491
TT
7775 DEBUGDIR=$withval
7776else
7777 DEBUGDIR=${libdir}/debug
81ecdfbb
RW
7778fi
7779
20e95c23 7780
783e057b
DJ
7781 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
7782 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
b14b1491 7783 ac_define_dir=`eval echo $DEBUGDIR`
783e057b 7784 ac_define_dir=`eval echo $ac_define_dir`
20e95c23 7785
783e057b
DJ
7786cat >>confdefs.h <<_ACEOF
7787#define DEBUGDIR "$ac_define_dir"
20e95c23 7788_ACEOF
20e95c23 7789
20e95c23 7790
20e95c23 7791
0c4a4063 7792
b14b1491
TT
7793 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
7794 if test "x$prefix" = xNONE; then
7795 test_prefix=/usr/local
7796 else
7797 test_prefix=$prefix
7798 fi
783e057b 7799 else
b14b1491 7800 test_prefix=$exec_prefix
783e057b 7801 fi
b14b1491
TT
7802 value=0
7803 case ${ac_define_dir} in
7804 "${test_prefix}"|"${test_prefix}/"*|\
7805 '${exec_prefix}'|'${exec_prefix}/'*)
7806 value=1
7807 ;;
7808 esac
7809
7810cat >>confdefs.h <<_ACEOF
7811#define DEBUGDIR_RELOCATABLE $value
7812_ACEOF
7813
7814
7815
0c4a4063 7816
b14b1491
TT
7817# GDB's datadir relocation
7818
7819
7820
81ecdfbb
RW
7821# Check whether --with-gdb-datadir was given.
7822if test "${with_gdb_datadir+set}" = set; then :
7823 withval=$with_gdb_datadir;
b14b1491 7824 GDB_DATADIR=$withval
20e95c23 7825else
b14b1491 7826 GDB_DATADIR=${datadir}/gdb
81ecdfbb
RW
7827fi
7828
20e95c23 7829
b14b1491
TT
7830 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
7831 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
7832 ac_define_dir=`eval echo $GDB_DATADIR`
7833 ac_define_dir=`eval echo $ac_define_dir`
7834
7835cat >>confdefs.h <<_ACEOF
7836#define GDB_DATADIR "$ac_define_dir"
20e95c23
DJ
7837_ACEOF
7838
b14b1491
TT
7839
7840
0c4a4063 7841
b14b1491
TT
7842 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
7843 if test "x$prefix" = xNONE; then
7844 test_prefix=/usr/local
7845 else
7846 test_prefix=$prefix
7847 fi
7848 else
7849 test_prefix=$exec_prefix
7850 fi
7851 value=0
7852 case ${ac_define_dir} in
7853 "${test_prefix}"|"${test_prefix}/"*|\
7854 '${exec_prefix}'|'${exec_prefix}/'*)
7855 value=1
7856 ;;
7857 esac
7858
7859cat >>confdefs.h <<_ACEOF
7860#define GDB_DATADIR_RELOCATABLE $value
7861_ACEOF
7862
7863
783e057b 7864
20e95c23 7865
0c4a4063 7866
81ecdfbb
RW
7867# Check whether --with-relocated-sources was given.
7868if test "${with_relocated_sources+set}" = set; then :
7869 withval=$with_relocated_sources; reloc_srcdir="${withval}"
29b0e8a2
JM
7870
7871 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
7872 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
7873 ac_define_dir=`eval echo $reloc_srcdir`
7874 ac_define_dir=`eval echo $ac_define_dir`
7875
7876cat >>confdefs.h <<_ACEOF
7877#define RELOC_SRCDIR "$ac_define_dir"
7878_ACEOF
7879
7880
7881
81ecdfbb
RW
7882fi
7883
29b0e8a2
JM
7884
7885
20e95c23 7886
5ae98d25 7887subdirs="$subdirs testsuite"
20e95c23
DJ
7888
7889
783e057b 7890# Check whether to support alternative target configurations
81ecdfbb
RW
7891# Check whether --enable-targets was given.
7892if test "${enable_targets+set}" = set; then :
7893 enableval=$enable_targets; case "${enableval}" in
7894 yes | "") as_fn_error "enable-targets option must specify target names or 'all'" "$LINENO" 5
783e057b
DJ
7895 ;;
7896 no) enable_targets= ;;
7897 *) enable_targets=$enableval ;;
7898esac
81ecdfbb
RW
7899fi
7900
20e95c23 7901
783e057b 7902# Check whether to enable 64-bit support on 32-bit hosts
81ecdfbb
RW
7903# Check whether --enable-64-bit-bfd was given.
7904if test "${enable_64_bit_bfd+set}" = set; then :
7905 enableval=$enable_64_bit_bfd; case "${enableval}" in
783e057b
DJ
7906 yes) want64=true ;;
7907 no) want64=false ;;
81ecdfbb 7908 *) as_fn_error "bad value ${enableval} for 64-bit-bfd option" "$LINENO" 5 ;;
783e057b
DJ
7909esac
7910else
7911 want64=false
81ecdfbb
RW
7912fi
7913
783e057b
DJ
7914# Provide defaults for some variables set by the per-host and per-target
7915# configuration.
7916gdb_host_obs=posix-hdep.o
20e95c23 7917
783e057b
DJ
7918if test "${target}" = "${host}"; then
7919 gdb_native=yes
7920else
7921 gdb_native=no
7922fi
20e95c23 7923
783e057b 7924. $srcdir/configure.host
20e95c23 7925
783e057b 7926# Accumulate some settings from configure.tgt over all enabled targets
20e95c23 7927
783e057b
DJ
7928TARGET_OBS=
7929all_targets=
20e95c23 7930
783e057b 7931for targ_alias in `echo $target_alias $enable_targets | sed 's/,/ /g'`
20e95c23 7932do
783e057b
DJ
7933 if test "$targ_alias" = "all"; then
7934 all_targets=true
7935 else
7936 # Canonicalize the secondary target names.
7937 result=`$ac_config_sub $targ_alias 2>/dev/null`
7938 if test -n "$result"; then
7939 targ=$result
7940 else
7941 targ=$targ_alias
7942 fi
20e95c23 7943
783e057b 7944 . ${srcdir}/configure.tgt
20e95c23 7945
bf307134
JB
7946 if test -z "${gdb_target_obs}"; then :
7947 as_fn_error "configuration ${targ} is unsupported." "$LINENO" 5
7948fi
7949
783e057b
DJ
7950 # Target-specific object files
7951 for i in ${gdb_target_obs}; do
7952 case " $TARGET_OBS " in
7953 *" ${i} "*) ;;
7954 *)
7955 TARGET_OBS="$TARGET_OBS ${i}"
7956 ;;
7957 esac
7958 done
20e95c23 7959
783e057b
DJ
7960 # Check whether this target needs 64-bit CORE_ADDR
7961 if test x${want64} = xfalse; then
7962 . ${srcdir}/../bfd/config.bfd
7963 fi
7964 fi
20e95c23
DJ
7965done
7966
783e057b
DJ
7967if test x${all_targets} = xtrue; then
7968
7969 # We want all 64-bit targets if we either:
7970 # - run on a 64-bit host or
7971 # - already require 64-bit support for some other target or
7972 # - the --enable-64-bit-bfd option was supplied
7973 # Otherwise we only support all 32-bit targets.
7974 #
7975 # NOTE: This test must be in sync with the corresponding
7976 # tests in BFD!
20e95c23 7977
783e057b 7978 if test x${want64} = xfalse; then
81ecdfbb
RW
7979 # The cast to long int works around a bug in the HP C Compiler
7980# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
7981# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
7982# This bug is HP SR number 8606223364.
7983{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
7984$as_echo_n "checking size of long... " >&6; }
7985if test "${ac_cv_sizeof_long+set}" = set; then :
7986 $as_echo_n "(cached) " >&6
c0993dbe 7987else
81ecdfbb 7988 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then :
c0993dbe 7989
81ecdfbb
RW
7990else
7991 if test "$ac_cv_type_long" = yes; then
7992 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
7993$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
7994{ as_fn_set_status 77
7995as_fn_error "cannot compute sizeof (long)
7996See \`config.log' for more details." "$LINENO" 5; }; }
7997 else
7998 ac_cv_sizeof_long=0
7999 fi
c0993dbe 8000fi
81ecdfbb 8001
c0993dbe 8002fi
81ecdfbb
RW
8003{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
8004$as_echo "$ac_cv_sizeof_long" >&6; }
c0993dbe 8005
c0993dbe 8006
c0993dbe 8007
c0993dbe
UW
8008cat >>confdefs.h <<_ACEOF
8009#define SIZEOF_LONG $ac_cv_sizeof_long
8010_ACEOF
8011
8012
8013 if test "x${ac_cv_sizeof_long}" = "x8"; then
8014 want64=true
8015 fi
8016 fi
8017 if test x${want64} = xtrue; then
8018 TARGET_OBS='$(ALL_TARGET_OBS) $(ALL_64_TARGET_OBS)'
8019 else
8020 TARGET_OBS='$(ALL_TARGET_OBS)'
8021 fi
8022fi
8023
8024
8025
8026# For other settings, only the main target counts.
8027gdb_sim=
8028gdb_osabi=
8029build_gdbserver=
8030targ=$target; . ${srcdir}/configure.tgt
8031
8032# Fetch the default architecture and default target vector from BFD.
8033targ=$target; . $srcdir/../bfd/config.bfd
8034
8035# We only want the first architecture, so strip off the others if
8036# there is more than one.
8037targ_archs=`echo $targ_archs | sed 's/ .*//'`
8038
8039if test "x$targ_archs" != x; then
8040
8041cat >>confdefs.h <<_ACEOF
8042#define DEFAULT_BFD_ARCH $targ_archs
8043_ACEOF
8044
8045fi
8046if test "x$targ_defvec" != x; then
8047
8048cat >>confdefs.h <<_ACEOF
8049#define DEFAULT_BFD_VEC $targ_defvec
8050_ACEOF
8051
8052fi
8053
c0993dbe
UW
8054# The CLI cannot be disabled yet, but may be in the future.
8055
8056# Enable CLI.
81ecdfbb
RW
8057# Check whether --enable-gdbcli was given.
8058if test "${enable_gdbcli+set}" = set; then :
8059 enableval=$enable_gdbcli; case $enableval in
c0993dbe
UW
8060 yes)
8061 ;;
8062 no)
81ecdfbb 8063 as_fn_error "the command-line interface cannot be disabled yet" "$LINENO" 5 ;;
c0993dbe 8064 *)
81ecdfbb 8065 as_fn_error "bad value $enableval for --enable-gdbcli" "$LINENO" 5 ;;
c0993dbe
UW
8066 esac
8067else
8068 enable_gdbcli=yes
81ecdfbb
RW
8069fi
8070
c0993dbe
UW
8071if test x"$enable_gdbcli" = xyes; then
8072 if test -d $srcdir/cli; then
8073 CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_CLI_OBS)"
8074 CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_CLI_DEPS)"
8075 CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_CLI_SRCS)"
8076 ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_CLI_CFLAGS)"
8077 fi
8078fi
8079
8080# Enable MI.
81ecdfbb
RW
8081# Check whether --enable-gdbmi was given.
8082if test "${enable_gdbmi+set}" = set; then :
8083 enableval=$enable_gdbmi; case $enableval in
c0993dbe
UW
8084 yes | no)
8085 ;;
8086 *)
81ecdfbb 8087 as_fn_error "bad value $enableval for --enable-gdbmi" "$LINENO" 5 ;;
c0993dbe
UW
8088 esac
8089else
8090 enable_gdbmi=yes
81ecdfbb
RW
8091fi
8092
c0993dbe
UW
8093if test x"$enable_gdbmi" = xyes; then
8094 if test -d $srcdir/mi; then
8095 CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_MI_OBS)"
8096 CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_MI_DEPS)"
8097 CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_MI_SRCS)"
8098 ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_MI_CFLAGS)"
8099 fi
8100fi
8101
8102# Enable TUI.
81ecdfbb
RW
8103# Check whether --enable-tui was given.
8104if test "${enable_tui+set}" = set; then :
8105 enableval=$enable_tui; case $enableval in
3ca64bd3 8106 yes | no | auto)
c0993dbe
UW
8107 ;;
8108 *)
81ecdfbb 8109 as_fn_error "bad value $enableval for --enable-tui" "$LINENO" 5 ;;
c0993dbe
UW
8110 esac
8111else
3ca64bd3 8112 enable_tui=auto
81ecdfbb
RW
8113fi
8114
c0993dbe
UW
8115
8116# Enable gdbtk.
81ecdfbb
RW
8117# Check whether --enable-gdbtk was given.
8118if test "${enable_gdbtk+set}" = set; then :
8119 enableval=$enable_gdbtk; case $enableval in
c0993dbe
UW
8120 yes | no)
8121 ;;
8122 *)
81ecdfbb 8123 as_fn_error "bad value $enableval for --enable-gdbtk" "$LINENO" 5 ;;
c0993dbe
UW
8124 esac
8125else
5062cc19 8126 if test -d $srcdir/gdbtk; then
c0993dbe
UW
8127 enable_gdbtk=yes
8128 else
8129 enable_gdbtk=no
8130 fi
81ecdfbb
RW
8131fi
8132
c0993dbe
UW
8133# We unconditionally disable gdbtk tests on selected platforms.
8134case $host_os in
8135 go32* | windows*)
81ecdfbb
RW
8136 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: gdbtk isn't supported on $host; disabling" >&5
8137$as_echo "$as_me: WARNING: gdbtk isn't supported on $host; disabling" >&2;}
c0993dbe
UW
8138 enable_gdbtk=no ;;
8139esac
8140
8141# Libunwind support.
bec39cab 8142
81ecdfbb
RW
8143# Check whether --with-libunwind was given.
8144if test "${with_libunwind+set}" = set; then :
8145 withval=$with_libunwind; case "${withval}" in
bec39cab
AC
8146 yes) enable_libunwind=yes ;;
8147 no) enable_libunwind=no ;;
81ecdfbb 8148 *) as_fn_error "bad value ${withval} for GDB with-libunwind option" "$LINENO" 5 ;;
bec39cab 8149esac
bec39cab 8150else
bec39cab 8151
81ecdfbb
RW
8152 for ac_header in libunwind.h libunwind-ia64.h
8153do :
8154 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8155ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
8156eval as_val=\$$as_ac_Header
8157 if test "x$as_val" = x""yes; then :
bec39cab 8158 cat >>confdefs.h <<_ACEOF
81ecdfbb 8159#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
bec39cab
AC
8160_ACEOF
8161
8162fi
8163
8164done
8165
a9322a30
TT
8166 if test x"$ac_cv_header_libunwind_h" = xyes -a x"$ac_cv_header_libunwind_ia64_h" = xyes; then
8167 enable_libunwind=yes;
8168 fi
8169
bec39cab 8170fi
bec39cab 8171
bec39cab 8172
81ecdfbb
RW
8173if test x"$enable_libunwind" = xyes; then
8174 for ac_header in libunwind.h libunwind-ia64.h
8175do :
8176 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8177ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
8178eval as_val=\$$as_ac_Header
8179 if test "x$as_val" = x""yes; then :
bec39cab 8180 cat >>confdefs.h <<_ACEOF
81ecdfbb 8181#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
bec39cab
AC
8182_ACEOF
8183
8184fi
8185
8186done
8187
bec39cab 8188
81ecdfbb 8189$as_echo "#define HAVE_LIBUNWIND 1" >>confdefs.h
a9322a30
TT
8190
8191 CONFIG_OBS="$CONFIG_OBS libunwind-frame.o"
8192 CONFIG_DEPS="$CONFIG_DEPS libunwind-frame.o"
8193 CONFIG_SRCS="$CONFIG_SRCS libunwind-frame.c"
8194fi
8195
cb01cfba
JB
8196opt_curses=no
8197
81ecdfbb
RW
8198# Check whether --with-curses was given.
8199if test "${with_curses+set}" = set; then :
8200 withval=$with_curses; opt_curses=$withval
8201fi
8202
cb01cfba 8203
76a39ba7 8204prefer_curses=no
cb01cfba 8205if test "$opt_curses" = "yes"; then
76a39ba7 8206 prefer_curses=yes
cb01cfba
JB
8207fi
8208
a9322a30 8209# Profiling support.
81ecdfbb
RW
8210# Check whether --enable-profiling was given.
8211if test "${enable_profiling+set}" = set; then :
8212 enableval=$enable_profiling; case $enableval in
a9322a30
TT
8213 yes | no)
8214 ;;
8215 *)
81ecdfbb 8216 as_fn_error "bad value $enableval for --enable-profile" "$LINENO" 5 ;;
a9322a30
TT
8217 esac
8218else
8219 enable_profiling=no
81ecdfbb 8220fi
bec39cab 8221
a9322a30
TT
8222
8223for ac_func in monstartup _mcleanup
81ecdfbb
RW
8224do :
8225 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
8226ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
8227eval as_val=\$$as_ac_var
8228 if test "x$as_val" = x""yes; then :
8229 cat >>confdefs.h <<_ACEOF
8230#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
bec39cab 8231_ACEOF
a9322a30 8232
81ecdfbb
RW
8233fi
8234done
a9322a30 8235
81ecdfbb
RW
8236{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for _etext" >&5
8237$as_echo_n "checking for _etext... " >&6; }
8238if test "${ac_cv_var__etext+set}" = set; then :
8239 $as_echo_n "(cached) " >&6
8240else
8241 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8242/* end confdefs.h. */
8243#include <stdlib.h>
8244extern char _etext;
a9322a30
TT
8245
8246int
8247main ()
8248{
8249free (&_etext);
8250 ;
8251 return 0;
8252}
bec39cab 8253_ACEOF
81ecdfbb 8254if ac_fn_c_try_link "$LINENO"; then :
a9322a30 8255 ac_cv_var__etext=yes
bec39cab 8256else
81ecdfbb 8257 ac_cv_var__etext=no
bec39cab 8258fi
81ecdfbb
RW
8259rm -f core conftest.err conftest.$ac_objext \
8260 conftest$ac_exeext conftest.$ac_ext
bec39cab 8261fi
81ecdfbb
RW
8262{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var__etext" >&5
8263$as_echo "$ac_cv_var__etext" >&6; }
a9322a30 8264if test $ac_cv_var__etext = yes; then
60ca704f 8265
81ecdfbb 8266$as_echo "#define HAVE__ETEXT 1" >>confdefs.h
bec39cab 8267
bec39cab 8268fi
81ecdfbb
RW
8269{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for etext" >&5
8270$as_echo_n "checking for etext... " >&6; }
8271if test "${ac_cv_var_etext+set}" = set; then :
8272 $as_echo_n "(cached) " >&6
bec39cab 8273else
81ecdfbb 8274 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 8275/* end confdefs.h. */
a9322a30
TT
8276#include <stdlib.h>
8277extern char etext;
bec39cab
AC
8278
8279int
8280main ()
8281{
a9322a30 8282free (&etext);
bec39cab
AC
8283 ;
8284 return 0;
8285}
8286_ACEOF
81ecdfbb 8287if ac_fn_c_try_link "$LINENO"; then :
a9322a30 8288 ac_cv_var_etext=yes
bec39cab 8289else
81ecdfbb 8290 ac_cv_var_etext=no
bec39cab 8291fi
81ecdfbb
RW
8292rm -f core conftest.err conftest.$ac_objext \
8293 conftest$ac_exeext conftest.$ac_ext
bec39cab 8294fi
81ecdfbb
RW
8295{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_etext" >&5
8296$as_echo "$ac_cv_var_etext" >&6; }
a9322a30
TT
8297if test $ac_cv_var_etext = yes; then
8298
81ecdfbb 8299$as_echo "#define HAVE_ETEXT 1" >>confdefs.h
bec39cab
AC
8300
8301fi
a9322a30
TT
8302if test "$enable_profiling" = yes ; then
8303 if test $ac_cv_func_monstartup = no || test $ac_cv_func__mcleanup = no; then
81ecdfbb 8304 as_fn_error "--enable-profiling requires monstartup and _mcleanup" "$LINENO" 5
a9322a30
TT
8305 fi
8306 PROFILE_CFLAGS=-pg
8307 OLD_CFLAGS="$CFLAGS"
8308 CFLAGS="$CFLAGS $PROFILE_CFLAGS"
bec39cab 8309
81ecdfbb
RW
8310 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -pg" >&5
8311$as_echo_n "checking whether $CC supports -pg... " >&6; }
8312if test "${ac_cv_cc_supports_pg+set}" = set; then :
8313 $as_echo_n "(cached) " >&6
bec39cab 8314else
81ecdfbb 8315 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 8316/* end confdefs.h. */
bec39cab
AC
8317
8318int
8319main ()
8320{
a9322a30 8321int x;
bec39cab
AC
8322 ;
8323 return 0;
8324}
8325_ACEOF
81ecdfbb 8326if ac_fn_c_try_compile "$LINENO"; then :
a9322a30 8327 ac_cv_cc_supports_pg=yes
bec39cab 8328else
81ecdfbb 8329 ac_cv_cc_supports_pg=no
bec39cab 8330fi
81ecdfbb 8331rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
bec39cab 8332fi
81ecdfbb
RW
8333{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cc_supports_pg" >&5
8334$as_echo "$ac_cv_cc_supports_pg" >&6; }
bec39cab 8335
a9322a30 8336 if test $ac_cv_cc_supports_pg = no; then
81ecdfbb 8337 as_fn_error "--enable-profiling requires a compiler which supports -pg" "$LINENO" 5
a9322a30 8338 fi
bec39cab 8339
a9322a30 8340 CFLAGS="$OLD_CFLAGS"
bec39cab
AC
8341fi
8342
c16158bc
JM
8343
8344
81ecdfbb
RW
8345# Check whether --with-pkgversion was given.
8346if test "${with_pkgversion+set}" = set; then :
8347 withval=$with_pkgversion; case "$withval" in
8348 yes) as_fn_error "package version not specified" "$LINENO" 5 ;;
c16158bc
JM
8349 no) PKGVERSION= ;;
8350 *) PKGVERSION="($withval) " ;;
8351 esac
8352else
8353 PKGVERSION="(GDB) "
8354
81ecdfbb 8355fi
c16158bc
JM
8356
8357
8358
8359
81ecdfbb
RW
8360
8361# Check whether --with-bugurl was given.
8362if test "${with_bugurl+set}" = set; then :
8363 withval=$with_bugurl; case "$withval" in
8364 yes) as_fn_error "bug URL not specified" "$LINENO" 5 ;;
c16158bc
JM
8365 no) BUGURL=
8366 ;;
8367 *) BUGURL="$withval"
8368 ;;
8369 esac
8370else
8371 BUGURL="http://www.gnu.org/software/gdb/bugs/"
8372
81ecdfbb
RW
8373fi
8374
c16158bc
JM
8375 case ${BUGURL} in
8376 "")
8377 REPORT_BUGS_TO=
8378 REPORT_BUGS_TEXI=
8379 ;;
8380 *)
8381 REPORT_BUGS_TO="<$BUGURL>"
8382 REPORT_BUGS_TEXI=@uref{`echo "$BUGURL" | sed 's/@/@@/g'`}
8383 ;;
8384 esac;
8385
8386
8387
8388
8389cat >>confdefs.h <<_ACEOF
8390#define PKGVERSION "$PKGVERSION"
8391_ACEOF
8392
8393
8394cat >>confdefs.h <<_ACEOF
8395#define REPORT_BUGS_TO "$REPORT_BUGS_TO"
8396_ACEOF
8397
8398
bec39cab
AC
8399# --------------------- #
8400# Checks for programs. #
8401# --------------------- #
8402
8403for ac_prog in gawk mawk nawk awk
8404do
8405 # Extract the first word of "$ac_prog", so it can be a program name with args.
8406set dummy $ac_prog; ac_word=$2
81ecdfbb
RW
8407{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8408$as_echo_n "checking for $ac_word... " >&6; }
8409if test "${ac_cv_prog_AWK+set}" = set; then :
8410 $as_echo_n "(cached) " >&6
bec39cab
AC
8411else
8412 if test -n "$AWK"; then
8413 ac_cv_prog_AWK="$AWK" # Let the user override the test.
8414else
8415as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8416for as_dir in $PATH
8417do
8418 IFS=$as_save_IFS
8419 test -z "$as_dir" && as_dir=.
81ecdfbb
RW
8420 for ac_exec_ext in '' $ac_executable_extensions; do
8421 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
bec39cab 8422 ac_cv_prog_AWK="$ac_prog"
81ecdfbb 8423 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
bec39cab
AC
8424 break 2
8425 fi
8426done
81ecdfbb
RW
8427 done
8428IFS=$as_save_IFS
bec39cab
AC
8429
8430fi
8431fi
8432AWK=$ac_cv_prog_AWK
8433if test -n "$AWK"; then
81ecdfbb
RW
8434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
8435$as_echo "$AWK" >&6; }
bec39cab 8436else
81ecdfbb
RW
8437 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8438$as_echo "no" >&6; }
bec39cab
AC
8439fi
8440
bec39cab 8441
81ecdfbb 8442 test -n "$AWK" && break
bec39cab
AC
8443done
8444
bec39cab 8445
81ecdfbb
RW
8446{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
8447$as_echo_n "checking whether ln -s works... " >&6; }
bec39cab
AC
8448LN_S=$as_ln_s
8449if test "$LN_S" = "ln -s"; then
81ecdfbb
RW
8450 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8451$as_echo "yes" >&6; }
bec39cab 8452else
81ecdfbb
RW
8453 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
8454$as_echo "no, using $LN_S" >&6; }
bec39cab
AC
8455fi
8456
8457if test -n "$ac_tool_prefix"; then
8458 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
8459set dummy ${ac_tool_prefix}ranlib; ac_word=$2
81ecdfbb
RW
8460{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8461$as_echo_n "checking for $ac_word... " >&6; }
8462if test "${ac_cv_prog_RANLIB+set}" = set; then :
8463 $as_echo_n "(cached) " >&6
bec39cab
AC
8464else
8465 if test -n "$RANLIB"; then
8466 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
8467else
8468as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8469for as_dir in $PATH
8470do
8471 IFS=$as_save_IFS
8472 test -z "$as_dir" && as_dir=.
81ecdfbb
RW
8473 for ac_exec_ext in '' $ac_executable_extensions; do
8474 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
bec39cab 8475 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
81ecdfbb 8476 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
bec39cab
AC
8477 break 2
8478 fi
8479done
81ecdfbb
RW
8480 done
8481IFS=$as_save_IFS
bec39cab
AC
8482
8483fi
8484fi
8485RANLIB=$ac_cv_prog_RANLIB
8486if test -n "$RANLIB"; then
81ecdfbb
RW
8487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
8488$as_echo "$RANLIB" >&6; }
bec39cab 8489else
81ecdfbb
RW
8490 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8491$as_echo "no" >&6; }
bec39cab
AC
8492fi
8493
81ecdfbb 8494
bec39cab
AC
8495fi
8496if test -z "$ac_cv_prog_RANLIB"; then
8497 ac_ct_RANLIB=$RANLIB
8498 # Extract the first word of "ranlib", so it can be a program name with args.
8499set dummy ranlib; ac_word=$2
81ecdfbb
RW
8500{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8501$as_echo_n "checking for $ac_word... " >&6; }
8502if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
8503 $as_echo_n "(cached) " >&6
bec39cab
AC
8504else
8505 if test -n "$ac_ct_RANLIB"; then
8506 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
8507else
8508as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8509for as_dir in $PATH
8510do
8511 IFS=$as_save_IFS
8512 test -z "$as_dir" && as_dir=.
81ecdfbb
RW
8513 for ac_exec_ext in '' $ac_executable_extensions; do
8514 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
bec39cab 8515 ac_cv_prog_ac_ct_RANLIB="ranlib"
81ecdfbb 8516 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
bec39cab
AC
8517 break 2
8518 fi
8519done
81ecdfbb
RW
8520 done
8521IFS=$as_save_IFS
bec39cab 8522
bec39cab
AC
8523fi
8524fi
8525ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
8526if test -n "$ac_ct_RANLIB"; then
81ecdfbb
RW
8527 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
8528$as_echo "$ac_ct_RANLIB" >&6; }
bec39cab 8529else
81ecdfbb
RW
8530 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8531$as_echo "no" >&6; }
bec39cab
AC
8532fi
8533
81ecdfbb
RW
8534 if test "x$ac_ct_RANLIB" = x; then
8535 RANLIB=":"
8536 else
8537 case $cross_compiling:$ac_tool_warned in
8538yes:)
8539{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8540$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8541ac_tool_warned=yes ;;
8542esac
8543 RANLIB=$ac_ct_RANLIB
8544 fi
bec39cab
AC
8545else
8546 RANLIB="$ac_cv_prog_RANLIB"
8547fi
8548
8549for ac_prog in 'bison -y' byacc
8550do
8551 # Extract the first word of "$ac_prog", so it can be a program name with args.
8552set dummy $ac_prog; ac_word=$2
81ecdfbb
RW
8553{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8554$as_echo_n "checking for $ac_word... " >&6; }
8555if test "${ac_cv_prog_YACC+set}" = set; then :
8556 $as_echo_n "(cached) " >&6
bec39cab
AC
8557else
8558 if test -n "$YACC"; then
8559 ac_cv_prog_YACC="$YACC" # Let the user override the test.
8560else
8561as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8562for as_dir in $PATH
8563do
8564 IFS=$as_save_IFS
8565 test -z "$as_dir" && as_dir=.
81ecdfbb
RW
8566 for ac_exec_ext in '' $ac_executable_extensions; do
8567 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
bec39cab 8568 ac_cv_prog_YACC="$ac_prog"
81ecdfbb 8569 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
bec39cab
AC
8570 break 2
8571 fi
8572done
81ecdfbb
RW
8573 done
8574IFS=$as_save_IFS
bec39cab
AC
8575
8576fi
8577fi
8578YACC=$ac_cv_prog_YACC
8579if test -n "$YACC"; then
81ecdfbb
RW
8580 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $YACC" >&5
8581$as_echo "$YACC" >&6; }
bec39cab 8582else
81ecdfbb
RW
8583 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8584$as_echo "no" >&6; }
bec39cab
AC
8585fi
8586
81ecdfbb 8587
bec39cab
AC
8588 test -n "$YACC" && break
8589done
8590test -n "$YACC" || YACC="yacc"
8591
8592
8593if test -n "$ac_tool_prefix"; then
8594 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
8595set dummy ${ac_tool_prefix}ar; ac_word=$2
81ecdfbb
RW
8596{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8597$as_echo_n "checking for $ac_word... " >&6; }
8598if test "${ac_cv_prog_AR+set}" = set; then :
8599 $as_echo_n "(cached) " >&6
bec39cab
AC
8600else
8601 if test -n "$AR"; then
8602 ac_cv_prog_AR="$AR" # Let the user override the test.
8603else
8604as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8605for as_dir in $PATH
8606do
8607 IFS=$as_save_IFS
8608 test -z "$as_dir" && as_dir=.
81ecdfbb
RW
8609 for ac_exec_ext in '' $ac_executable_extensions; do
8610 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
bec39cab 8611 ac_cv_prog_AR="${ac_tool_prefix}ar"
81ecdfbb 8612 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
bec39cab
AC
8613 break 2
8614 fi
8615done
81ecdfbb
RW
8616 done
8617IFS=$as_save_IFS
bec39cab
AC
8618
8619fi
8620fi
8621AR=$ac_cv_prog_AR
8622if test -n "$AR"; then
81ecdfbb
RW
8623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
8624$as_echo "$AR" >&6; }
bec39cab 8625else
81ecdfbb
RW
8626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8627$as_echo "no" >&6; }
bec39cab
AC
8628fi
8629
81ecdfbb 8630
bec39cab
AC
8631fi
8632if test -z "$ac_cv_prog_AR"; then
8633 ac_ct_AR=$AR
8634 # Extract the first word of "ar", so it can be a program name with args.
8635set dummy ar; ac_word=$2
81ecdfbb
RW
8636{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8637$as_echo_n "checking for $ac_word... " >&6; }
8638if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
8639 $as_echo_n "(cached) " >&6
bec39cab
AC
8640else
8641 if test -n "$ac_ct_AR"; then
8642 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
8643else
8644as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8645for as_dir in $PATH
8646do
8647 IFS=$as_save_IFS
8648 test -z "$as_dir" && as_dir=.
81ecdfbb
RW
8649 for ac_exec_ext in '' $ac_executable_extensions; do
8650 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
bec39cab 8651 ac_cv_prog_ac_ct_AR="ar"
81ecdfbb 8652 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
bec39cab
AC
8653 break 2
8654 fi
8655done
81ecdfbb
RW
8656 done
8657IFS=$as_save_IFS
bec39cab
AC
8658
8659fi
8660fi
8661ac_ct_AR=$ac_cv_prog_ac_ct_AR
8662if test -n "$ac_ct_AR"; then
81ecdfbb
RW
8663 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
8664$as_echo "$ac_ct_AR" >&6; }
bec39cab 8665else
81ecdfbb
RW
8666 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8667$as_echo "no" >&6; }
bec39cab
AC
8668fi
8669
81ecdfbb
RW
8670 if test "x$ac_ct_AR" = x; then
8671 AR=""
8672 else
8673 case $cross_compiling:$ac_tool_warned in
8674yes:)
8675{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8676$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8677ac_tool_warned=yes ;;
8678esac
8679 AR=$ac_ct_AR
8680 fi
bec39cab
AC
8681else
8682 AR="$ac_cv_prog_AR"
8683fi
8684
8685if test -n "$ac_tool_prefix"; then
8686 # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
8687set dummy ${ac_tool_prefix}dlltool; ac_word=$2
81ecdfbb
RW
8688{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8689$as_echo_n "checking for $ac_word... " >&6; }
8690if test "${ac_cv_prog_DLLTOOL+set}" = set; then :
8691 $as_echo_n "(cached) " >&6
bec39cab
AC
8692else
8693 if test -n "$DLLTOOL"; then
8694 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
8695else
8696as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8697for as_dir in $PATH
8698do
8699 IFS=$as_save_IFS
8700 test -z "$as_dir" && as_dir=.
81ecdfbb
RW
8701 for ac_exec_ext in '' $ac_executable_extensions; do
8702 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
bec39cab 8703 ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
81ecdfbb 8704 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
bec39cab
AC
8705 break 2
8706 fi
8707done
81ecdfbb
RW
8708 done
8709IFS=$as_save_IFS
bec39cab
AC
8710
8711fi
8712fi
8713DLLTOOL=$ac_cv_prog_DLLTOOL
8714if test -n "$DLLTOOL"; then
81ecdfbb
RW
8715 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
8716$as_echo "$DLLTOOL" >&6; }
bec39cab 8717else
81ecdfbb
RW
8718 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8719$as_echo "no" >&6; }
bec39cab
AC
8720fi
8721
81ecdfbb 8722
bec39cab
AC
8723fi
8724if test -z "$ac_cv_prog_DLLTOOL"; then
8725 ac_ct_DLLTOOL=$DLLTOOL
8726 # Extract the first word of "dlltool", so it can be a program name with args.
8727set dummy dlltool; ac_word=$2
81ecdfbb
RW
8728{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8729$as_echo_n "checking for $ac_word... " >&6; }
8730if test "${ac_cv_prog_ac_ct_DLLTOOL+set}" = set; then :
8731 $as_echo_n "(cached) " >&6
bec39cab
AC
8732else
8733 if test -n "$ac_ct_DLLTOOL"; then
8734 ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
8735else
8736as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8737for as_dir in $PATH
8738do
8739 IFS=$as_save_IFS
8740 test -z "$as_dir" && as_dir=.
81ecdfbb
RW
8741 for ac_exec_ext in '' $ac_executable_extensions; do
8742 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
bec39cab 8743 ac_cv_prog_ac_ct_DLLTOOL="dlltool"
81ecdfbb 8744 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
bec39cab
AC
8745 break 2
8746 fi
8747done
81ecdfbb
RW
8748 done
8749IFS=$as_save_IFS
bec39cab
AC
8750
8751fi
8752fi
8753ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
8754if test -n "$ac_ct_DLLTOOL"; then
81ecdfbb
RW
8755 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
8756$as_echo "$ac_ct_DLLTOOL" >&6; }
bec39cab 8757else
81ecdfbb
RW
8758 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8759$as_echo "no" >&6; }
bec39cab
AC
8760fi
8761
81ecdfbb
RW
8762 if test "x$ac_ct_DLLTOOL" = x; then
8763 DLLTOOL=""
8764 else
8765 case $cross_compiling:$ac_tool_warned in
8766yes:)
8767{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8768$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8769ac_tool_warned=yes ;;
8770esac
8771 DLLTOOL=$ac_ct_DLLTOOL
8772 fi
bec39cab
AC
8773else
8774 DLLTOOL="$ac_cv_prog_DLLTOOL"
8775fi
8776
8777if test -n "$ac_tool_prefix"; then
8778 # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
8779set dummy ${ac_tool_prefix}windres; ac_word=$2
81ecdfbb
RW
8780{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8781$as_echo_n "checking for $ac_word... " >&6; }
8782if test "${ac_cv_prog_WINDRES+set}" = set; then :
8783 $as_echo_n "(cached) " >&6
bec39cab
AC
8784else
8785 if test -n "$WINDRES"; then
8786 ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
8787else
8788as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8789for as_dir in $PATH
8790do
8791 IFS=$as_save_IFS
8792 test -z "$as_dir" && as_dir=.
81ecdfbb
RW
8793 for ac_exec_ext in '' $ac_executable_extensions; do
8794 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
bec39cab 8795 ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
81ecdfbb 8796 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
bec39cab
AC
8797 break 2
8798 fi
8799done
81ecdfbb
RW
8800 done
8801IFS=$as_save_IFS
bec39cab
AC
8802
8803fi
8804fi
8805WINDRES=$ac_cv_prog_WINDRES
8806if test -n "$WINDRES"; then
81ecdfbb
RW
8807 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
8808$as_echo "$WINDRES" >&6; }
bec39cab 8809else
81ecdfbb
RW
8810 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8811$as_echo "no" >&6; }
bec39cab
AC
8812fi
8813
81ecdfbb 8814
bec39cab
AC
8815fi
8816if test -z "$ac_cv_prog_WINDRES"; then
8817 ac_ct_WINDRES=$WINDRES
8818 # Extract the first word of "windres", so it can be a program name with args.
8819set dummy windres; ac_word=$2
81ecdfbb
RW
8820{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8821$as_echo_n "checking for $ac_word... " >&6; }
8822if test "${ac_cv_prog_ac_ct_WINDRES+set}" = set; then :
8823 $as_echo_n "(cached) " >&6
bec39cab
AC
8824else
8825 if test -n "$ac_ct_WINDRES"; then
8826 ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test.
8827else
8828as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8829for as_dir in $PATH
8830do
8831 IFS=$as_save_IFS
8832 test -z "$as_dir" && as_dir=.
81ecdfbb
RW
8833 for ac_exec_ext in '' $ac_executable_extensions; do
8834 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
bec39cab 8835 ac_cv_prog_ac_ct_WINDRES="windres"
81ecdfbb 8836 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
bec39cab
AC
8837 break 2
8838 fi
8839done
81ecdfbb
RW
8840 done
8841IFS=$as_save_IFS
bec39cab
AC
8842
8843fi
8844fi
8845ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
8846if test -n "$ac_ct_WINDRES"; then
81ecdfbb
RW
8847 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_WINDRES" >&5
8848$as_echo "$ac_ct_WINDRES" >&6; }
bec39cab 8849else
81ecdfbb
RW
8850 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8851$as_echo "no" >&6; }
c906108c 8852fi
bec39cab 8853
81ecdfbb
RW
8854 if test "x$ac_ct_WINDRES" = x; then
8855 WINDRES=""
8856 else
8857 case $cross_compiling:$ac_tool_warned in
8858yes:)
8859{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8860$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8861ac_tool_warned=yes ;;
8862esac
8863 WINDRES=$ac_ct_WINDRES
8864 fi
c906108c 8865else
bec39cab 8866 WINDRES="$ac_cv_prog_WINDRES"
c906108c
SS
8867fi
8868
bec39cab
AC
8869
8870# Needed for GNU/Hurd.
8871if test -n "$ac_tool_prefix"; then
8872 # Extract the first word of "${ac_tool_prefix}mig", so it can be a program name with args.
8873set dummy ${ac_tool_prefix}mig; ac_word=$2
81ecdfbb
RW
8874{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8875$as_echo_n "checking for $ac_word... " >&6; }
8876if test "${ac_cv_prog_MIG+set}" = set; then :
8877 $as_echo_n "(cached) " >&6
c906108c 8878else
bec39cab
AC
8879 if test -n "$MIG"; then
8880 ac_cv_prog_MIG="$MIG" # Let the user override the test.
8881else
8882as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8883for as_dir in $PATH
8884do
8885 IFS=$as_save_IFS
8886 test -z "$as_dir" && as_dir=.
81ecdfbb
RW
8887 for ac_exec_ext in '' $ac_executable_extensions; do
8888 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
bec39cab 8889 ac_cv_prog_MIG="${ac_tool_prefix}mig"
81ecdfbb 8890 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
bec39cab
AC
8891 break 2
8892 fi
8893done
81ecdfbb
RW
8894 done
8895IFS=$as_save_IFS
bec39cab 8896
c906108c 8897fi
bec39cab
AC
8898fi
8899MIG=$ac_cv_prog_MIG
8900if test -n "$MIG"; then
81ecdfbb
RW
8901 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MIG" >&5
8902$as_echo "$MIG" >&6; }
c906108c 8903else
81ecdfbb
RW
8904 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8905$as_echo "no" >&6; }
c906108c
SS
8906fi
8907
81ecdfbb 8908
bec39cab
AC
8909fi
8910if test -z "$ac_cv_prog_MIG"; then
8911 ac_ct_MIG=$MIG
8912 # Extract the first word of "mig", so it can be a program name with args.
8913set dummy mig; ac_word=$2
81ecdfbb
RW
8914{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8915$as_echo_n "checking for $ac_word... " >&6; }
8916if test "${ac_cv_prog_ac_ct_MIG+set}" = set; then :
8917 $as_echo_n "(cached) " >&6
bec39cab
AC
8918else
8919 if test -n "$ac_ct_MIG"; then
8920 ac_cv_prog_ac_ct_MIG="$ac_ct_MIG" # Let the user override the test.
8921else
8922as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8923for as_dir in $PATH
8924do
8925 IFS=$as_save_IFS
8926 test -z "$as_dir" && as_dir=.
81ecdfbb
RW
8927 for ac_exec_ext in '' $ac_executable_extensions; do
8928 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
bec39cab 8929 ac_cv_prog_ac_ct_MIG="mig"
81ecdfbb 8930 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
bec39cab
AC
8931 break 2
8932 fi
8933done
81ecdfbb
RW
8934 done
8935IFS=$as_save_IFS
c906108c 8936
bec39cab
AC
8937fi
8938fi
8939ac_ct_MIG=$ac_cv_prog_ac_ct_MIG
8940if test -n "$ac_ct_MIG"; then
81ecdfbb
RW
8941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MIG" >&5
8942$as_echo "$ac_ct_MIG" >&6; }
bec39cab 8943else
81ecdfbb
RW
8944 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8945$as_echo "no" >&6; }
bec39cab 8946fi
c906108c 8947
81ecdfbb
RW
8948 if test "x$ac_ct_MIG" = x; then
8949 MIG=""
8950 else
8951 case $cross_compiling:$ac_tool_warned in
8952yes:)
8953{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8954$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8955ac_tool_warned=yes ;;
8956esac
8957 MIG=$ac_ct_MIG
8958 fi
bec39cab
AC
8959else
8960 MIG="$ac_cv_prog_MIG"
8961fi
c906108c 8962
c906108c 8963
bec39cab
AC
8964# ---------------------- #
8965# Checks for libraries. #
8966# ---------------------- #
c906108c 8967
bec39cab 8968# We might need to link with -lm; most simulators need it.
81ecdfbb
RW
8969{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lm" >&5
8970$as_echo_n "checking for main in -lm... " >&6; }
8971if test "${ac_cv_lib_m_main+set}" = set; then :
8972 $as_echo_n "(cached) " >&6
bec39cab
AC
8973else
8974 ac_check_lib_save_LIBS=$LIBS
8975LIBS="-lm $LIBS"
81ecdfbb 8976cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 8977/* end confdefs.h. */
c906108c 8978
c906108c 8979
bec39cab
AC
8980int
8981main ()
8982{
81ecdfbb 8983return main ();
bec39cab
AC
8984 ;
8985 return 0;
8986}
8987_ACEOF
81ecdfbb 8988if ac_fn_c_try_link "$LINENO"; then :
bec39cab
AC
8989 ac_cv_lib_m_main=yes
8990else
81ecdfbb 8991 ac_cv_lib_m_main=no
bec39cab 8992fi
81ecdfbb
RW
8993rm -f core conftest.err conftest.$ac_objext \
8994 conftest$ac_exeext conftest.$ac_ext
bec39cab
AC
8995LIBS=$ac_check_lib_save_LIBS
8996fi
81ecdfbb
RW
8997{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_main" >&5
8998$as_echo "$ac_cv_lib_m_main" >&6; }
8999if test "x$ac_cv_lib_m_main" = x""yes; then :
bec39cab
AC
9000 cat >>confdefs.h <<_ACEOF
9001#define HAVE_LIBM 1
9002_ACEOF
9003
9004 LIBS="-lm $LIBS"
c906108c 9005
c906108c 9006fi
bec39cab
AC
9007
9008
9009# We need to link with -lw to get `wctype' on Solaris before Solaris
9010# 2.6. Solaris 2.6 and beyond have this function in libc, and have a
9011# libw that some versions of the GNU linker cannot hanle (GNU ld 2.9.1
9012# is known to have this problem). Therefore we avoid libw if we can.
81ecdfbb
RW
9013ac_fn_c_check_func "$LINENO" "wctype" "ac_cv_func_wctype"
9014if test "x$ac_cv_func_wctype" = x""yes; then :
bec39cab 9015
c906108c 9016else
81ecdfbb
RW
9017 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wctype in -lw" >&5
9018$as_echo_n "checking for wctype in -lw... " >&6; }
9019if test "${ac_cv_lib_w_wctype+set}" = set; then :
9020 $as_echo_n "(cached) " >&6
bec39cab
AC
9021else
9022 ac_check_lib_save_LIBS=$LIBS
9023LIBS="-lw $LIBS"
81ecdfbb 9024cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 9025/* end confdefs.h. */
c906108c 9026
81ecdfbb
RW
9027/* Override any GCC internal prototype to avoid an error.
9028 Use char because int might match the return type of a GCC
9029 builtin and then its argument prototype would still apply. */
bec39cab
AC
9030#ifdef __cplusplus
9031extern "C"
9032#endif
bec39cab
AC
9033char wctype ();
9034int
9035main ()
9036{
81ecdfbb 9037return wctype ();
bec39cab
AC
9038 ;
9039 return 0;
9040}
9041_ACEOF
81ecdfbb 9042if ac_fn_c_try_link "$LINENO"; then :
bec39cab
AC
9043 ac_cv_lib_w_wctype=yes
9044else
81ecdfbb 9045 ac_cv_lib_w_wctype=no
bec39cab 9046fi
81ecdfbb
RW
9047rm -f core conftest.err conftest.$ac_objext \
9048 conftest$ac_exeext conftest.$ac_ext
bec39cab
AC
9049LIBS=$ac_check_lib_save_LIBS
9050fi
81ecdfbb
RW
9051{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_w_wctype" >&5
9052$as_echo "$ac_cv_lib_w_wctype" >&6; }
9053if test "x$ac_cv_lib_w_wctype" = x""yes; then :
bec39cab
AC
9054 cat >>confdefs.h <<_ACEOF
9055#define HAVE_LIBW 1
9056_ACEOF
c906108c 9057
bec39cab 9058 LIBS="-lw $LIBS"
c906108c 9059
bec39cab 9060fi
c906108c 9061
bec39cab 9062fi
c906108c 9063
ddc9cd0f 9064
bec39cab 9065# Some systems (e.g. Solaris) have `gethostbyname' in libnsl.
81ecdfbb
RW
9066{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing gethostbyname" >&5
9067$as_echo_n "checking for library containing gethostbyname... " >&6; }
9068if test "${ac_cv_search_gethostbyname+set}" = set; then :
9069 $as_echo_n "(cached) " >&6
bec39cab
AC
9070else
9071 ac_func_search_save_LIBS=$LIBS
81ecdfbb 9072cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 9073/* end confdefs.h. */
ddc9cd0f 9074
81ecdfbb
RW
9075/* Override any GCC internal prototype to avoid an error.
9076 Use char because int might match the return type of a GCC
9077 builtin and then its argument prototype would still apply. */
bec39cab
AC
9078#ifdef __cplusplus
9079extern "C"
9080#endif
bec39cab
AC
9081char gethostbyname ();
9082int
9083main ()
9084{
81ecdfbb 9085return gethostbyname ();
bec39cab
AC
9086 ;
9087 return 0;
9088}
9089_ACEOF
81ecdfbb
RW
9090for ac_lib in '' nsl; do
9091 if test -z "$ac_lib"; then
9092 ac_res="none required"
9093 else
9094 ac_res=-l$ac_lib
b4e70030 9095 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
81ecdfbb
RW
9096 fi
9097 if ac_fn_c_try_link "$LINENO"; then :
9098 ac_cv_search_gethostbyname=$ac_res
9099fi
9100rm -f core conftest.err conftest.$ac_objext \
9101 conftest$ac_exeext
9102 if test "${ac_cv_search_gethostbyname+set}" = set; then :
9103 break
9104fi
9105done
9106if test "${ac_cv_search_gethostbyname+set}" = set; then :
ddc9cd0f 9107
bec39cab 9108else
81ecdfbb 9109 ac_cv_search_gethostbyname=no
bec39cab 9110fi
81ecdfbb 9111rm conftest.$ac_ext
bec39cab
AC
9112LIBS=$ac_func_search_save_LIBS
9113fi
81ecdfbb
RW
9114{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_gethostbyname" >&5
9115$as_echo "$ac_cv_search_gethostbyname" >&6; }
9116ac_res=$ac_cv_search_gethostbyname
9117if test "$ac_res" != no; then :
9118 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
96baa820 9119
bec39cab 9120fi
96baa820 9121
c906108c 9122
b4e70030 9123# Some systems (e.g. Solaris) have `socketpair' in libsocket.
81ecdfbb
RW
9124{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing socketpair" >&5
9125$as_echo_n "checking for library containing socketpair... " >&6; }
9126if test "${ac_cv_search_socketpair+set}" = set; then :
9127 $as_echo_n "(cached) " >&6
b4e70030
JB
9128else
9129 ac_func_search_save_LIBS=$LIBS
81ecdfbb 9130cat confdefs.h - <<_ACEOF >conftest.$ac_ext
b4e70030
JB
9131/* end confdefs.h. */
9132
81ecdfbb
RW
9133/* Override any GCC internal prototype to avoid an error.
9134 Use char because int might match the return type of a GCC
9135 builtin and then its argument prototype would still apply. */
b4e70030
JB
9136#ifdef __cplusplus
9137extern "C"
9138#endif
b4e70030
JB
9139char socketpair ();
9140int
9141main ()
9142{
81ecdfbb 9143return socketpair ();
b4e70030
JB
9144 ;
9145 return 0;
9146}
9147_ACEOF
81ecdfbb
RW
9148for ac_lib in '' socket; do
9149 if test -z "$ac_lib"; then
9150 ac_res="none required"
9151 else
9152 ac_res=-l$ac_lib
b4e70030 9153 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
81ecdfbb
RW
9154 fi
9155 if ac_fn_c_try_link "$LINENO"; then :
9156 ac_cv_search_socketpair=$ac_res
9157fi
9158rm -f core conftest.err conftest.$ac_objext \
9159 conftest$ac_exeext
9160 if test "${ac_cv_search_socketpair+set}" = set; then :
9161 break
9162fi
9163done
9164if test "${ac_cv_search_socketpair+set}" = set; then :
b4e70030 9165
b4e70030 9166else
81ecdfbb 9167 ac_cv_search_socketpair=no
b4e70030 9168fi
81ecdfbb 9169rm conftest.$ac_ext
b4e70030
JB
9170LIBS=$ac_func_search_save_LIBS
9171fi
81ecdfbb
RW
9172{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_socketpair" >&5
9173$as_echo "$ac_cv_search_socketpair" >&6; }
9174ac_res=$ac_cv_search_socketpair
9175if test "$ac_res" != no; then :
9176 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
b4e70030
JB
9177
9178fi
9179
9180
233a11ab 9181# Link in zlib if we can. This allows us to read compressed debug sections.
b040ad30
JB
9182
9183 # See if the user specified whether he wants zlib support or not.
9184
9185# Check whether --with-zlib was given.
9186if test "${with_zlib+set}" = set; then :
9187 withval=$with_zlib;
9188else
9189 with_zlib=auto
9190fi
9191
9192
9193 if test "$with_zlib" != "no"; then
9194 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing zlibVersion" >&5
81ecdfbb
RW
9195$as_echo_n "checking for library containing zlibVersion... " >&6; }
9196if test "${ac_cv_search_zlibVersion+set}" = set; then :
9197 $as_echo_n "(cached) " >&6
233a11ab
CS
9198else
9199 ac_func_search_save_LIBS=$LIBS
81ecdfbb 9200cat confdefs.h - <<_ACEOF >conftest.$ac_ext
233a11ab
CS
9201/* end confdefs.h. */
9202
81ecdfbb
RW
9203/* Override any GCC internal prototype to avoid an error.
9204 Use char because int might match the return type of a GCC
233a11ab 9205 builtin and then its argument prototype would still apply. */
233a11ab
CS
9206#ifdef __cplusplus
9207extern "C"
9208#endif
233a11ab
CS
9209char zlibVersion ();
9210int
9211main ()
9212{
81ecdfbb 9213return zlibVersion ();
233a11ab
CS
9214 ;
9215 return 0;
9216}
9217_ACEOF
81ecdfbb
RW
9218for ac_lib in '' z; do
9219 if test -z "$ac_lib"; then
9220 ac_res="none required"
233a11ab 9221 else
81ecdfbb
RW
9222 ac_res=-l$ac_lib
9223 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
233a11ab 9224 fi
81ecdfbb
RW
9225 if ac_fn_c_try_link "$LINENO"; then :
9226 ac_cv_search_zlibVersion=$ac_res
233a11ab 9227fi
81ecdfbb
RW
9228rm -f core conftest.err conftest.$ac_objext \
9229 conftest$ac_exeext
9230 if test "${ac_cv_search_zlibVersion+set}" = set; then :
9231 break
233a11ab 9232fi
81ecdfbb
RW
9233done
9234if test "${ac_cv_search_zlibVersion+set}" = set; then :
233a11ab 9235
233a11ab 9236else
81ecdfbb 9237 ac_cv_search_zlibVersion=no
233a11ab 9238fi
81ecdfbb
RW
9239rm conftest.$ac_ext
9240LIBS=$ac_func_search_save_LIBS
233a11ab 9241fi
81ecdfbb
RW
9242{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_zlibVersion" >&5
9243$as_echo "$ac_cv_search_zlibVersion" >&6; }
9244ac_res=$ac_cv_search_zlibVersion
9245if test "$ac_res" != no; then :
9246 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
9247 for ac_header in zlib.h
9248do :
9249 ac_fn_c_check_header_mongrel "$LINENO" "zlib.h" "ac_cv_header_zlib_h" "$ac_includes_default"
9250if test "x$ac_cv_header_zlib_h" = x""yes; then :
233a11ab 9251 cat >>confdefs.h <<_ACEOF
81ecdfbb 9252#define HAVE_ZLIB_H 1
233a11ab
CS
9253_ACEOF
9254
9255fi
9256
9257done
9258
9259fi
9260
b040ad30
JB
9261 if test "$with_zlib" = "yes" -a "$ac_cv_header_zlib_h" != "yes"; then
9262 as_fn_error "zlib (libz) library was explicitly requested but not found" "$LINENO" 5
9263 fi
9264 fi
9265
233a11ab 9266
77f120bf 9267# On HP/UX we may need libxpdl for dlgetmodinfo (used by solib-pa64.c).
81ecdfbb
RW
9268{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlgetmodinfo" >&5
9269$as_echo_n "checking for library containing dlgetmodinfo... " >&6; }
9270if test "${ac_cv_search_dlgetmodinfo+set}" = set; then :
9271 $as_echo_n "(cached) " >&6
bec39cab
AC
9272else
9273 ac_func_search_save_LIBS=$LIBS
81ecdfbb 9274cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 9275/* end confdefs.h. */
c906108c 9276
81ecdfbb
RW
9277/* Override any GCC internal prototype to avoid an error.
9278 Use char because int might match the return type of a GCC
9279 builtin and then its argument prototype would still apply. */
bec39cab
AC
9280#ifdef __cplusplus
9281extern "C"
9282#endif
77f120bf 9283char dlgetmodinfo ();
bec39cab
AC
9284int
9285main ()
9286{
81ecdfbb 9287return dlgetmodinfo ();
bec39cab
AC
9288 ;
9289 return 0;
9290}
9291_ACEOF
81ecdfbb
RW
9292for ac_lib in '' dl xpdl; do
9293 if test -z "$ac_lib"; then
9294 ac_res="none required"
9295 else
9296 ac_res=-l$ac_lib
b4e70030 9297 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
81ecdfbb
RW
9298 fi
9299 if ac_fn_c_try_link "$LINENO"; then :
9300 ac_cv_search_dlgetmodinfo=$ac_res
9301fi
9302rm -f core conftest.err conftest.$ac_objext \
9303 conftest$ac_exeext
9304 if test "${ac_cv_search_dlgetmodinfo+set}" = set; then :
9305 break
9306fi
9307done
9308if test "${ac_cv_search_dlgetmodinfo+set}" = set; then :
b4e70030 9309
4e8d927d 9310else
81ecdfbb 9311 ac_cv_search_dlgetmodinfo=no
1ba607ad 9312fi
81ecdfbb 9313rm conftest.$ac_ext
bec39cab
AC
9314LIBS=$ac_func_search_save_LIBS
9315fi
81ecdfbb
RW
9316{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlgetmodinfo" >&5
9317$as_echo "$ac_cv_search_dlgetmodinfo" >&6; }
9318ac_res=$ac_cv_search_dlgetmodinfo
9319if test "$ac_res" != no; then :
9320 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
c906108c 9321
8bb2c122 9322fi
8bb2c122 9323
8bb2c122 9324
77f120bf 9325
77f120bf 9326
6c7a06a3 9327
81ecdfbb
RW
9328# Check whether --with-libiconv-prefix was given.
9329if test "${with_libiconv_prefix+set}" = set; then :
9330 withval=$with_libiconv_prefix;
6c7a06a3 9331 for dir in `echo "$withval" | tr : ' '`; do
94ae1714
TT
9332 if test -d $dir/include; then LIBICONV_INCLUDE="-I$dir/include"; fi
9333 if test -d $dir/lib; then LIBICONV_LIBDIR="-L$dir/lib"; fi
6c7a06a3
TT
9334 done
9335
81ecdfbb
RW
9336fi
9337
6c7a06a3 9338
f18c4681 9339 BUILD_LIBICONV_LIBDIRS="../libiconv/lib/.libs ../libiconv/lib/_libs"
6c7a06a3
TT
9340 BUILD_LIBICONV_INCLUDE="-I../libiconv/include"
9341
81ecdfbb
RW
9342 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5
9343$as_echo_n "checking for iconv... " >&6; }
9344if test "${am_cv_func_iconv+set}" = set; then :
9345 $as_echo_n "(cached) " >&6
d542061a 9346else
6c7a06a3
TT
9347
9348 am_cv_func_iconv="no, consider installing GNU libiconv"
9349 am_cv_lib_iconv=no
9350 am_cv_use_build_libiconv=no
f0f20949 9351 am_cv_build_libiconv_path=
4edb1e84
JB
9352
9353 # If libiconv is part of the build tree, then try using it over
9354 # any system iconv.
9355 if test -d ../libiconv; then
f18c4681
JB
9356 for lib_dir in $BUILD_LIBICONV_LIBDIRS; do
9357 am_save_LIBS="$LIBS"
9358 am_save_CPPFLAGS="$CPPFLAGS"
9359 LIBS="$LIBS $lib_dir/libiconv.a"
9360 CPPFLAGS="$CPPFLAGS $BUILD_LIBICONV_INCLUDE"
9361 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
d542061a 9362/* end confdefs.h. */
6c7a06a3
TT
9363#include <stdlib.h>
9364#include <iconv.h>
d542061a
UW
9365int
9366main ()
9367{
6c7a06a3 9368iconv_t cd = iconv_open("","");
f18c4681
JB
9369 iconv(cd,NULL,NULL,NULL,NULL);
9370 iconv_close(cd);
d542061a
UW
9371 ;
9372 return 0;
9373}
9374_ACEOF
81ecdfbb 9375if ac_fn_c_try_link "$LINENO"; then :
4edb1e84 9376 am_cv_use_build_libiconv=yes
f0f20949 9377 am_cv_build_libiconv_path=$lib_dir/libiconv.a
f18c4681
JB
9378 am_cv_lib_iconv=yes
9379 am_cv_func_iconv=yes
d542061a 9380fi
81ecdfbb
RW
9381rm -f core conftest.err conftest.$ac_objext \
9382 conftest$ac_exeext conftest.$ac_ext
f18c4681
JB
9383 LIBS="$am_save_LIBS"
9384 CPPFLAGS="$am_save_CPPFLAGS"
9385 if test "$am_cv_use_build_libiconv" = "yes"; then
f18c4681
JB
9386 break
9387 fi
9388 done
4edb1e84 9389 fi
94ae1714 9390
4edb1e84 9391 # Next, try to find iconv in libc.
6c7a06a3 9392 if test "$am_cv_func_iconv" != yes; then
81ecdfbb 9393 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
d542061a 9394/* end confdefs.h. */
6c7a06a3
TT
9395#include <stdlib.h>
9396#include <iconv.h>
d542061a
UW
9397int
9398main ()
9399{
6c7a06a3
TT
9400iconv_t cd = iconv_open("","");
9401 iconv(cd,NULL,NULL,NULL,NULL);
9402 iconv_close(cd);
d542061a
UW
9403 ;
9404 return 0;
9405}
9406_ACEOF
81ecdfbb 9407if ac_fn_c_try_link "$LINENO"; then :
4edb1e84 9408 am_cv_func_iconv=yes
d542061a 9409fi
81ecdfbb
RW
9410rm -f core conftest.err conftest.$ac_objext \
9411 conftest$ac_exeext conftest.$ac_ext
77f120bf 9412 fi
94ae1714 9413
4edb1e84
JB
9414 # If iconv was not in libc, try -liconv. In this case, arrange to
9415 # look in the libiconv prefix, if it was specified by the user.
9416 if test "$am_cv_func_iconv" != yes; then
6c7a06a3 9417 am_save_CPPFLAGS="$CPPFLAGS"
4edb1e84
JB
9418 am_save_LIBS="$LIBS"
9419 if test -n "$LIBICONV_INCLUDE"; then
9420 CPPFLAGS="$CPPFLAGS $LIBICONV_INCLUDE"
9421 LIBS="$LIBS $LIBICONV_LIBDIR"
9422 fi
9423 LIBS="$LIBS -liconv"
81ecdfbb 9424 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 9425/* end confdefs.h. */
6c7a06a3
TT
9426#include <stdlib.h>
9427#include <iconv.h>
bec39cab
AC
9428int
9429main ()
9430{
6c7a06a3
TT
9431iconv_t cd = iconv_open("","");
9432 iconv(cd,NULL,NULL,NULL,NULL);
9433 iconv_close(cd);
bec39cab
AC
9434 ;
9435 return 0;
9436}
9437_ACEOF
81ecdfbb 9438if ac_fn_c_try_link "$LINENO"; then :
4edb1e84 9439 am_cv_lib_iconv=yes
6c7a06a3 9440 am_cv_func_iconv=yes
627af7ea 9441fi
81ecdfbb
RW
9442rm -f core conftest.err conftest.$ac_objext \
9443 conftest$ac_exeext conftest.$ac_ext
6c7a06a3 9444 LIBS="$am_save_LIBS"
fc3b640d 9445 CPPFLAGS="$am_save_CPPFLAGS"
6c7a06a3
TT
9446 fi
9447
9448fi
81ecdfbb
RW
9449{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5
9450$as_echo "$am_cv_func_iconv" >&6; }
94ae1714
TT
9451
9452 # Set the various flags based on the cache variables. We can't rely
9453 # on the flags to remain set from the above code, due to caching.
fc3b640d
TT
9454 LIBICONV=
9455 if test "$am_cv_lib_iconv" = yes; then
9456 LIBICONV="-liconv"
94ae1714
TT
9457 else
9458 LIBICONV_LIBDIR=
9459 LIBICONV_INCLUDE=
fc3b640d
TT
9460 fi
9461 if test "$am_cv_use_build_libiconv" = yes; then
f0f20949 9462 LIBICONV="$am_cv_build_libiconv_path"
f18c4681 9463 LIBICONV_LIBDIR=""
fc3b640d
TT
9464 LIBICONV_INCLUDE="$BUILD_LIBICONV_INCLUDE"
9465 fi
9466 CPPFLAGS="$CPPFLAGS $LIBICONV_INCLUDE"
9467 LIBS="$LIBS $LIBICONV_LIBDIR $LIBICONV"
94ae1714 9468
6c7a06a3
TT
9469 if test "$am_cv_func_iconv" = yes; then
9470
81ecdfbb 9471$as_echo "#define HAVE_ICONV 1" >>confdefs.h
6c7a06a3 9472
81ecdfbb
RW
9473 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv declaration" >&5
9474$as_echo_n "checking for iconv declaration... " >&6; }
9475 if test "${am_cv_proto_iconv+set}" = set; then :
9476 $as_echo_n "(cached) " >&6
6c7a06a3
TT
9477else
9478
81ecdfbb 9479 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
b4e70030
JB
9480/* end confdefs.h. */
9481
6c7a06a3
TT
9482#include <stdlib.h>
9483#include <iconv.h>
9484extern
b4e70030 9485#ifdef __cplusplus
6c7a06a3 9486"C"
b4e70030 9487#endif
6c7a06a3
TT
9488#if defined(__STDC__) || defined(__cplusplus)
9489size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);
9490#else
9491size_t iconv();
9492#endif
9493
b4e70030
JB
9494int
9495main ()
9496{
6c7a06a3 9497
b4e70030
JB
9498 ;
9499 return 0;
9500}
9501_ACEOF
81ecdfbb 9502if ac_fn_c_try_compile "$LINENO"; then :
6c7a06a3 9503 am_cv_proto_iconv_arg1=""
4e8d927d 9504else
81ecdfbb 9505 am_cv_proto_iconv_arg1="const"
b4e70030 9506fi
81ecdfbb 9507rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6c7a06a3
TT
9508 am_cv_proto_iconv="extern size_t iconv (iconv_t cd, $am_cv_proto_iconv_arg1 char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);"
9509fi
9510
9511 am_cv_proto_iconv=`echo "$am_cv_proto_iconv" | tr -s ' ' | sed -e 's/( /(/'`
81ecdfbb 9512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${ac_t:-
6c7a06a3 9513 }$am_cv_proto_iconv" >&5
81ecdfbb
RW
9514$as_echo "${ac_t:-
9515 }$am_cv_proto_iconv" >&6; }
6c7a06a3
TT
9516
9517cat >>confdefs.h <<_ACEOF
9518#define ICONV_CONST $am_cv_proto_iconv_arg1
9519_ACEOF
9520
9521 fi
6c7a06a3
TT
9522
9523
9524# On alpha-osf, it appears that libtermcap and libcurses are not compatible.
9525# There is a very specific comment in /usr/include/curses.h explaining that
9526# termcap routines built into libcurses must not be used.
9527#
9528# The symptoms we observed so far is GDB unexpectedly changing
9529# the terminal settings when tgetent is called - this is particularly
9530# visible as the output is missing carriage returns, and so rapidly
9531# becomes very hard to read.
9532#
9533# The readline configure script has already decided that libtermcap
9534# was enough for its purposes, and so decided to build readline using
9535# libtermcap. Since the TUI mode requires curses, building GDB with
9536# TUI enabled results in both libraries to be used at the same time,
9537# which is not allowed. This basically means that GDB with TUI is
9538# broken on alpha-osf.
9539
9540case $host_os in
6bcc772d
RO
9541 osf* )
9542 if test x"$enable_tui" = xyes; then
81ecdfbb 9543 as_fn_error "Building GDB with TUI mode is not supported on this host" "$LINENO" 5
6c7a06a3 9544 fi
6bcc772d 9545 if test x"$enable_tui" = xauto; then
6c7a06a3
TT
9546 enable_tui=no
9547 fi
9548 ;;
9549esac
9550
cb01cfba 9551# For the TUI, we need enhanced curses functionality.
bd8a8e1b 9552if test x"$enable_tui" != xno; then
cb01cfba
JB
9553 prefer_curses=yes
9554fi
9555
9556curses_found=no
9557if test x"$prefer_curses" = xyes; then
9558 # FIXME: kettenis/20040905: We prefer ncurses over the vendor-supplied
9559 # curses library because the latter might not provide all the
9560 # functionality we need. However, this leads to problems on systems
9561 # where the linker searches /usr/local/lib, but the compiler doesn't
9562 # search /usr/local/include, if ncurses is installed in /usr/local. A
9563 # default installation of ncurses on alpha*-dec-osf* will lead to such
9564 # a situation.
81ecdfbb
RW
9565 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing waddstr" >&5
9566$as_echo_n "checking for library containing waddstr... " >&6; }
9567if test "${ac_cv_search_waddstr+set}" = set; then :
9568 $as_echo_n "(cached) " >&6
6c7a06a3
TT
9569else
9570 ac_func_search_save_LIBS=$LIBS
81ecdfbb 9571cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6c7a06a3
TT
9572/* end confdefs.h. */
9573
81ecdfbb
RW
9574/* Override any GCC internal prototype to avoid an error.
9575 Use char because int might match the return type of a GCC
9576 builtin and then its argument prototype would still apply. */
6c7a06a3
TT
9577#ifdef __cplusplus
9578extern "C"
9579#endif
6c7a06a3
TT
9580char waddstr ();
9581int
9582main ()
9583{
81ecdfbb 9584return waddstr ();
6c7a06a3
TT
9585 ;
9586 return 0;
9587}
9588_ACEOF
81ecdfbb
RW
9589for ac_lib in '' ncurses cursesX curses; do
9590 if test -z "$ac_lib"; then
9591 ac_res="none required"
9592 else
9593 ac_res=-l$ac_lib
9594 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
9595 fi
9596 if ac_fn_c_try_link "$LINENO"; then :
9597 ac_cv_search_waddstr=$ac_res
9598fi
9599rm -f core conftest.err conftest.$ac_objext \
9600 conftest$ac_exeext
9601 if test "${ac_cv_search_waddstr+set}" = set; then :
9602 break
9603fi
9604done
9605if test "${ac_cv_search_waddstr+set}" = set; then :
9606
6c7a06a3 9607else
81ecdfbb
RW
9608 ac_cv_search_waddstr=no
9609fi
9610rm conftest.$ac_ext
9611LIBS=$ac_func_search_save_LIBS
9612fi
9613{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_waddstr" >&5
9614$as_echo "$ac_cv_search_waddstr" >&6; }
9615ac_res=$ac_cv_search_waddstr
9616if test "$ac_res" != no; then :
9617 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
6c7a06a3
TT
9618
9619fi
9620
9621
cb01cfba
JB
9622 if test "$ac_cv_search_waddstr" != no; then
9623 curses_found=yes
9624 fi
9625fi
9626
9627# Check whether we should enable the TUI, but only do so if we really
9628# can.
9629if test x"$enable_tui" != xno; then
9630 if test -d $srcdir/tui; then
9631 if test "$curses_found" != no; then
6c7a06a3
TT
9632 CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_TUI_OBS)"
9633 CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_TUI_DEPS)"
9634 CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_TUI_SRCS)"
9635 ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_TUI_CFLAGS)"
9636 CONFIG_ALL="${CONFIG_ALL} all-tui"
9637 CONFIG_CLEAN="${CONFIG_CLEAN} clean-tui"
9638 CONFIG_INSTALL="${CONFIG_INSTALL} install-tui"
9639 CONFIG_UNINSTALL="${CONFIG_UNINSTALL} uninstall-tui"
9640 else
9641 if test x"$enable_tui" = xyes; then
81ecdfbb 9642 as_fn_error "no enhanced curses library found; disable TUI" "$LINENO" 5
6c7a06a3 9643 else
81ecdfbb
RW
9644 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no enhanced curses library found; disabling TUI" >&5
9645$as_echo "$as_me: WARNING: no enhanced curses library found; disabling TUI" >&2;}
6c7a06a3
TT
9646 fi
9647 fi
9648 fi
9649fi
9650
9651# Since GDB uses Readline, we need termcap functionality. In many
9652# cases this will be provided by the curses library, but some systems
9653# have a seperate termcap library, or no curses library at all.
9654
9655case $host_os in
9656 cygwin*)
9657 if test -d $srcdir/libtermcap; then
9658 LIBS="../libtermcap/libtermcap.a $LIBS"
9659 ac_cv_search_tgetent="../libtermcap/libtermcap.a"
9660 fi ;;
9661 go32* | *djgpp*)
9662 ac_cv_search_tgetent="none required"
9663 ;;
9664 *mingw32*)
9665 ac_cv_search_tgetent="none required"
9666 CONFIG_OBS="$CONFIG_OBS windows-termcap.o"
9667 ;;
9668esac
9669
9670# These are the libraries checked by Readline.
81ecdfbb
RW
9671{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing tgetent" >&5
9672$as_echo_n "checking for library containing tgetent... " >&6; }
9673if test "${ac_cv_search_tgetent+set}" = set; then :
9674 $as_echo_n "(cached) " >&6
6c7a06a3
TT
9675else
9676 ac_func_search_save_LIBS=$LIBS
81ecdfbb 9677cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6c7a06a3
TT
9678/* end confdefs.h. */
9679
81ecdfbb
RW
9680/* Override any GCC internal prototype to avoid an error.
9681 Use char because int might match the return type of a GCC
9682 builtin and then its argument prototype would still apply. */
6c7a06a3
TT
9683#ifdef __cplusplus
9684extern "C"
9685#endif
6c7a06a3
TT
9686char tgetent ();
9687int
9688main ()
9689{
81ecdfbb 9690return tgetent ();
6c7a06a3
TT
9691 ;
9692 return 0;
9693}
9694_ACEOF
81ecdfbb
RW
9695for ac_lib in '' termcap tinfo curses ncurses; do
9696 if test -z "$ac_lib"; then
9697 ac_res="none required"
9698 else
9699 ac_res=-l$ac_lib
6c7a06a3 9700 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
81ecdfbb
RW
9701 fi
9702 if ac_fn_c_try_link "$LINENO"; then :
9703 ac_cv_search_tgetent=$ac_res
9704fi
9705rm -f core conftest.err conftest.$ac_objext \
9706 conftest$ac_exeext
9707 if test "${ac_cv_search_tgetent+set}" = set; then :
9708 break
9709fi
9710done
9711if test "${ac_cv_search_tgetent+set}" = set; then :
6c7a06a3 9712
6c7a06a3 9713else
81ecdfbb 9714 ac_cv_search_tgetent=no
6c7a06a3 9715fi
81ecdfbb 9716rm conftest.$ac_ext
6c7a06a3
TT
9717LIBS=$ac_func_search_save_LIBS
9718fi
81ecdfbb
RW
9719{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_tgetent" >&5
9720$as_echo "$ac_cv_search_tgetent" >&6; }
9721ac_res=$ac_cv_search_tgetent
9722if test "$ac_res" != no; then :
9723 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
6c7a06a3 9724
06825bd1
MK
9725fi
9726
06825bd1 9727
bec39cab 9728if test "$ac_cv_search_tgetent" = no; then
81ecdfbb 9729 as_fn_error "no termcap library found" "$LINENO" 5
8ee53726
MK
9730fi
9731
3841debe 9732
81ecdfbb
RW
9733# Check whether --with-system-readline was given.
9734if test "${with_system_readline+set}" = set; then :
9735 withval=$with_system_readline;
9736fi
6a30b0a5 9737
6a30b0a5
AS
9738
9739if test "$with_system_readline" = yes; then
9740 READLINE=-lreadline
9741 READLINE_DEPS=
9742 READLINE_CFLAGS=
39037522 9743 READLINE_TEXI_INCFLAG=
a71e0887
JK
9744
9745 # readline-6.0 started to use the name `_rl_echoing_p'.
9746 # `$(READLINE_DIR)/' of bundled readline would not resolve in configure.
9747
9748 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for readline_echoing_p" >&5
9749$as_echo_n "checking for readline_echoing_p... " >&6; }
9750 save_LIBS=$LIBS
9751 LIBS="$LIBS $READLINE"
9752 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9753/* end confdefs.h. */
9754
9755int
9756main ()
9757{
9758extern int readline_echoing_p;
9759 return readline_echoing_p;
9760 ;
9761 return 0;
9762}
9763_ACEOF
9764if ac_fn_c_try_link "$LINENO"; then :
9765 READLINE_ECHOING_P=yes
9766else
9767 READLINE_ECHOING_P=no
9768
9769$as_echo "#define readline_echoing_p _rl_echoing_p" >>confdefs.h
9770
9771fi
9772rm -f core conftest.err conftest.$ac_objext \
9773 conftest$ac_exeext conftest.$ac_ext
9774 LIBS="$save_LIBS"
9775 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINE_ECHOING_P" >&5
9776$as_echo "$READLINE_ECHOING_P" >&6; }
6a30b0a5
AS
9777else
9778 READLINE='$(READLINE_DIR)/libreadline.a'
9779 READLINE_DEPS='$(READLINE)'
9780 READLINE_CFLAGS='-I$(READLINE_SRC)/..'
39037522 9781 READLINE_TEXI_INCFLAG='-I $(READLINE_DIR)'
6a30b0a5
AS
9782fi
9783
9784
9785
9786
9787
39037522 9788
81ecdfbb
RW
9789# Check whether --with-expat was given.
9790if test "${with_expat+set}" = set; then :
9791 withval=$with_expat;
5c39566f
DJ
9792else
9793 with_expat=auto
81ecdfbb
RW
9794fi
9795
9796{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use expat" >&5
9797$as_echo_n "checking whether to use expat... " >&6; }
9798{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_expat" >&5
9799$as_echo "$with_expat" >&6; }
5c39566f
DJ
9800
9801if test "${with_expat}" = no; then
81ecdfbb
RW
9802 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: expat support disabled; some features may be unavailable." >&5
9803$as_echo "$as_me: WARNING: expat support disabled; some features may be unavailable." >&2;}
5c39566f
DJ
9804 HAVE_LIBEXPAT=no
9805else
9806
3841debe
DJ
9807 if test "X$prefix" = "XNONE"; then
9808 acl_final_prefix="$ac_default_prefix"
9809 else
9810 acl_final_prefix="$prefix"
9811 fi
9812 if test "X$exec_prefix" = "XNONE"; then
9813 acl_final_exec_prefix='${prefix}'
9814 else
9815 acl_final_exec_prefix="$exec_prefix"
9816 fi
9817 acl_save_prefix="$prefix"
9818 prefix="$acl_final_prefix"
9819 eval acl_final_exec_prefix=\"$acl_final_exec_prefix\"
9820 prefix="$acl_save_prefix"
9821
9822
81ecdfbb
RW
9823# Check whether --with-gnu-ld was given.
9824if test "${with_gnu_ld+set}" = set; then :
9825 withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
3841debe
DJ
9826else
9827 with_gnu_ld=no
81ecdfbb
RW
9828fi
9829
3841debe
DJ
9830# Prepare PATH_SEPARATOR.
9831# The user is always right.
9832if test "${PATH_SEPARATOR+set}" != set; then
9833 echo "#! /bin/sh" >conf$$.sh
9834 echo "exit 0" >>conf$$.sh
9835 chmod +x conf$$.sh
9836 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
9837 PATH_SEPARATOR=';'
9838 else
9839 PATH_SEPARATOR=:
9840 fi
9841 rm -f conf$$.sh
9842fi
9843ac_prog=ld
9844if test "$GCC" = yes; then
9845 # Check if gcc -print-prog-name=ld gives a path.
81ecdfbb
RW
9846 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by GCC" >&5
9847$as_echo_n "checking for ld used by GCC... " >&6; }
3841debe
DJ
9848 case $host in
9849 *-*-mingw*)
9850 # gcc leaves a trailing carriage return which upsets mingw
9851 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
9852 *)
9853 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
9854 esac
9855 case $ac_prog in
9856 # Accept absolute paths.
9857 [\\/]* | [A-Za-z]:[\\/]*)
9858 re_direlt='/[^/][^/]*/\.\./'
9859 # Canonicalize the path of ld
9860 ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
9861 while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
9862 ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
9863 done
9864 test -z "$LD" && LD="$ac_prog"
9865 ;;
9866 "")
9867 # If it fails, then pretend we aren't using GCC.
9868 ac_prog=ld
9869 ;;
9870 *)
9871 # If it is relative, then search for the first ld in PATH.
9872 with_gnu_ld=unknown
9873 ;;
9874 esac
9875elif test "$with_gnu_ld" = yes; then
81ecdfbb
RW
9876 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
9877$as_echo_n "checking for GNU ld... " >&6; }
3841debe 9878else
81ecdfbb
RW
9879 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
9880$as_echo_n "checking for non-GNU ld... " >&6; }
3841debe 9881fi
81ecdfbb
RW
9882if test "${acl_cv_path_LD+set}" = set; then :
9883 $as_echo_n "(cached) " >&6
3841debe
DJ
9884else
9885 if test -z "$LD"; then
9886 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
9887 for ac_dir in $PATH; do
9888 test -z "$ac_dir" && ac_dir=.
9889 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
9890 acl_cv_path_LD="$ac_dir/$ac_prog"
9891 # Check to see if the program is GNU ld. I'd rather use --version,
9892 # but apparently some GNU ld's only accept -v.
9893 # Break only if it was the GNU/non-GNU ld that we prefer.
9894 if "$acl_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
9895 test "$with_gnu_ld" != no && break
9896 else
9897 test "$with_gnu_ld" != yes && break
9898 fi
9899 fi
9900 done
9901 IFS="$ac_save_ifs"
9902else
9903 acl_cv_path_LD="$LD" # Let the user override the test with a path.
9904fi
9905fi
9906
9907LD="$acl_cv_path_LD"
9908if test -n "$LD"; then
81ecdfbb
RW
9909 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
9910$as_echo "$LD" >&6; }
3841debe 9911else
81ecdfbb
RW
9912 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9913$as_echo "no" >&6; }
3841debe 9914fi
81ecdfbb
RW
9915test -z "$LD" && as_fn_error "no acceptable ld found in \$PATH" "$LINENO" 5
9916{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
9917$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
9918if test "${acl_cv_prog_gnu_ld+set}" = set; then :
9919 $as_echo_n "(cached) " >&6
3841debe
DJ
9920else
9921 # I'd rather use --version here, but apparently some GNU ld's only accept -v.
9922if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
9923 acl_cv_prog_gnu_ld=yes
9924else
9925 acl_cv_prog_gnu_ld=no
9926fi
9927fi
81ecdfbb
RW
9928{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_prog_gnu_ld" >&5
9929$as_echo "$acl_cv_prog_gnu_ld" >&6; }
3841debe
DJ
9930with_gnu_ld=$acl_cv_prog_gnu_ld
9931
9932
9933
81ecdfbb
RW
9934 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shared library run path origin" >&5
9935$as_echo_n "checking for shared library run path origin... " >&6; }
9936if test "${acl_cv_rpath+set}" = set; then :
9937 $as_echo_n "(cached) " >&6
3841debe
DJ
9938else
9939
9940 CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
9941 ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
9942 . ./conftest.sh
9943 rm -f ./conftest.sh
9944 acl_cv_rpath=done
9945
9946fi
81ecdfbb
RW
9947{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_rpath" >&5
9948$as_echo "$acl_cv_rpath" >&6; }
3841debe
DJ
9949 wl="$acl_cv_wl"
9950 libext="$acl_cv_libext"
9951 shlibext="$acl_cv_shlibext"
9952 hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
9953 hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
9954 hardcode_direct="$acl_cv_hardcode_direct"
9955 hardcode_minus_L="$acl_cv_hardcode_minus_L"
81ecdfbb
RW
9956 # Check whether --enable-rpath was given.
9957if test "${enable_rpath+set}" = set; then :
9958 enableval=$enable_rpath; :
3841debe
DJ
9959else
9960 enable_rpath=yes
81ecdfbb
RW
9961fi
9962
3841debe
DJ
9963
9964
9965
9966
9967
9968
9969
9970
9971
9972 use_additional=yes
9973
9974 acl_save_prefix="$prefix"
9975 prefix="$acl_final_prefix"
9976 acl_save_exec_prefix="$exec_prefix"
9977 exec_prefix="$acl_final_exec_prefix"
9978
9979 eval additional_includedir=\"$includedir\"
9980 eval additional_libdir=\"$libdir\"
9981
9982 exec_prefix="$acl_save_exec_prefix"
9983 prefix="$acl_save_prefix"
9984
9985
81ecdfbb
RW
9986# Check whether --with-libexpat-prefix was given.
9987if test "${with_libexpat_prefix+set}" = set; then :
9988 withval=$with_libexpat_prefix;
3841debe
DJ
9989 if test "X$withval" = "Xno"; then
9990 use_additional=no
9991 else
9992 if test "X$withval" = "X"; then
9993
9994 acl_save_prefix="$prefix"
9995 prefix="$acl_final_prefix"
9996 acl_save_exec_prefix="$exec_prefix"
9997 exec_prefix="$acl_final_exec_prefix"
9998
9999 eval additional_includedir=\"$includedir\"
10000 eval additional_libdir=\"$libdir\"
10001
10002 exec_prefix="$acl_save_exec_prefix"
10003 prefix="$acl_save_prefix"
10004
10005 else
10006 additional_includedir="$withval/include"
10007 additional_libdir="$withval/lib"
10008 fi
10009 fi
10010
81ecdfbb
RW
10011fi
10012
3841debe
DJ
10013 LIBEXPAT=
10014 LTLIBEXPAT=
10015 INCEXPAT=
10016 rpathdirs=
10017 ltrpathdirs=
10018 names_already_handled=
10019 names_next_round='expat '
10020 while test -n "$names_next_round"; do
10021 names_this_round="$names_next_round"
10022 names_next_round=
10023 for name in $names_this_round; do
10024 already_handled=
10025 for n in $names_already_handled; do
10026 if test "$n" = "$name"; then
10027 already_handled=yes
10028 break
10029 fi
10030 done
10031 if test -z "$already_handled"; then
10032 names_already_handled="$names_already_handled $name"
10033 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
10034 eval value=\"\$HAVE_LIB$uppername\"
10035 if test -n "$value"; then
10036 if test "$value" = yes; then
10037 eval value=\"\$LIB$uppername\"
10038 test -z "$value" || LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$value"
10039 eval value=\"\$LTLIB$uppername\"
10040 test -z "$value" || LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }$value"
10041 else
10042 :
10043 fi
10044 else
10045 found_dir=
10046 found_la=
10047 found_so=
10048 found_a=
10049 if test $use_additional = yes; then
10050 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then
10051 found_dir="$additional_libdir"
10052 found_so="$additional_libdir/lib$name.$shlibext"
10053 if test -f "$additional_libdir/lib$name.la"; then
10054 found_la="$additional_libdir/lib$name.la"
10055 fi
10056 else
10057 if test -f "$additional_libdir/lib$name.$libext"; then
10058 found_dir="$additional_libdir"
10059 found_a="$additional_libdir/lib$name.$libext"
10060 if test -f "$additional_libdir/lib$name.la"; then
10061 found_la="$additional_libdir/lib$name.la"
10062 fi
10063 fi
10064 fi
10065 fi
10066 if test "X$found_dir" = "X"; then
10067 for x in $LDFLAGS $LTLIBEXPAT; do
10068
10069 acl_save_prefix="$prefix"
10070 prefix="$acl_final_prefix"
10071 acl_save_exec_prefix="$exec_prefix"
10072 exec_prefix="$acl_final_exec_prefix"
10073 eval x=\"$x\"
10074 exec_prefix="$acl_save_exec_prefix"
10075 prefix="$acl_save_prefix"
10076
10077 case "$x" in
10078 -L*)
10079 dir=`echo "X$x" | sed -e 's/^X-L//'`
10080 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then
10081 found_dir="$dir"
10082 found_so="$dir/lib$name.$shlibext"
10083 if test -f "$dir/lib$name.la"; then
10084 found_la="$dir/lib$name.la"
10085 fi
10086 else
10087 if test -f "$dir/lib$name.$libext"; then
10088 found_dir="$dir"
10089 found_a="$dir/lib$name.$libext"
10090 if test -f "$dir/lib$name.la"; then
10091 found_la="$dir/lib$name.la"
10092 fi
10093 fi
10094 fi
10095 ;;
10096 esac
10097 if test "X$found_dir" != "X"; then
10098 break
10099 fi
10100 done
10101 fi
10102 if test "X$found_dir" != "X"; then
10103 LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-L$found_dir -l$name"
10104 if test "X$found_so" != "X"; then
10105 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
10106 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_so"
10107 else
10108 haveit=
10109 for x in $ltrpathdirs; do
10110 if test "X$x" = "X$found_dir"; then
10111 haveit=yes
10112 break
10113 fi
10114 done
10115 if test -z "$haveit"; then
10116 ltrpathdirs="$ltrpathdirs $found_dir"
10117 fi
10118 if test "$hardcode_direct" = yes; then
10119 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_so"
10120 else
10121 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
10122 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_so"
10123 haveit=
10124 for x in $rpathdirs; do
10125 if test "X$x" = "X$found_dir"; then
10126 haveit=yes
10127 break
10128 fi
10129 done
10130 if test -z "$haveit"; then
10131 rpathdirs="$rpathdirs $found_dir"
10132 fi
10133 else
10134 haveit=
10135 for x in $LDFLAGS $LIBEXPAT; do
10136
10137 acl_save_prefix="$prefix"
10138 prefix="$acl_final_prefix"
10139 acl_save_exec_prefix="$exec_prefix"
10140 exec_prefix="$acl_final_exec_prefix"
10141 eval x=\"$x\"
10142 exec_prefix="$acl_save_exec_prefix"
10143 prefix="$acl_save_prefix"
10144
10145 if test "X$x" = "X-L$found_dir"; then
10146 haveit=yes
10147 break
10148 fi
10149 done
10150 if test -z "$haveit"; then
10151 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-L$found_dir"
10152 fi
10153 if test "$hardcode_minus_L" != no; then
10154 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_so"
10155 else
10156 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-l$name"
10157 fi
10158 fi
10159 fi
10160 fi
10161 else
10162 if test "X$found_a" != "X"; then
10163 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_a"
10164 else
10165 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-L$found_dir -l$name"
10166 fi
10167 fi
10168 additional_includedir=
10169 case "$found_dir" in
10170 */lib | */lib/)
10171 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
10172 additional_includedir="$basedir/include"
10173 ;;
10174 esac
10175 if test "X$additional_includedir" != "X"; then
10176 if test "X$additional_includedir" != "X/usr/include"; then
10177 haveit=
10178 if test "X$additional_includedir" = "X/usr/local/include"; then
10179 if test -n "$GCC"; then
10180 case $host_os in
10181 linux*) haveit=yes;;
10182 esac
10183 fi
10184 fi
10185 if test -z "$haveit"; then
10186 for x in $CPPFLAGS $INCEXPAT; do
10187
10188 acl_save_prefix="$prefix"
10189 prefix="$acl_final_prefix"
10190 acl_save_exec_prefix="$exec_prefix"
10191 exec_prefix="$acl_final_exec_prefix"
10192 eval x=\"$x\"
10193 exec_prefix="$acl_save_exec_prefix"
10194 prefix="$acl_save_prefix"
10195
10196 if test "X$x" = "X-I$additional_includedir"; then
10197 haveit=yes
10198 break
10199 fi
10200 done
10201 if test -z "$haveit"; then
10202 if test -d "$additional_includedir"; then
10203 INCEXPAT="${INCEXPAT}${INCEXPAT:+ }-I$additional_includedir"
10204 fi
10205 fi
10206 fi
10207 fi
10208 fi
10209 if test -n "$found_la"; then
10210 save_libdir="$libdir"
10211 case "$found_la" in
10212 */* | *\\*) . "$found_la" ;;
10213 *) . "./$found_la" ;;
10214 esac
10215 libdir="$save_libdir"
10216 for dep in $dependency_libs; do
10217 case "$dep" in
10218 -L*)
10219 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
10220 if test "X$additional_libdir" != "X/usr/lib"; then
10221 haveit=
10222 if test "X$additional_libdir" = "X/usr/local/lib"; then
10223 if test -n "$GCC"; then
10224 case $host_os in
10225 linux*) haveit=yes;;
10226 esac
10227 fi
10228 fi
10229 if test -z "$haveit"; then
10230 haveit=
10231 for x in $LDFLAGS $LIBEXPAT; do
10232
10233 acl_save_prefix="$prefix"
10234 prefix="$acl_final_prefix"
10235 acl_save_exec_prefix="$exec_prefix"
10236 exec_prefix="$acl_final_exec_prefix"
10237 eval x=\"$x\"
10238 exec_prefix="$acl_save_exec_prefix"
10239 prefix="$acl_save_prefix"
10240
10241 if test "X$x" = "X-L$additional_libdir"; then
10242 haveit=yes
10243 break
10244 fi
10245 done
10246 if test -z "$haveit"; then
10247 if test -d "$additional_libdir"; then
10248 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-L$additional_libdir"
10249 fi
10250 fi
10251 haveit=
10252 for x in $LDFLAGS $LTLIBEXPAT; do
10253
10254 acl_save_prefix="$prefix"
10255 prefix="$acl_final_prefix"
10256 acl_save_exec_prefix="$exec_prefix"
10257 exec_prefix="$acl_final_exec_prefix"
10258 eval x=\"$x\"
10259 exec_prefix="$acl_save_exec_prefix"
10260 prefix="$acl_save_prefix"
10261
10262 if test "X$x" = "X-L$additional_libdir"; then
10263 haveit=yes
10264 break
10265 fi
10266 done
10267 if test -z "$haveit"; then
10268 if test -d "$additional_libdir"; then
10269 LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-L$additional_libdir"
10270 fi
10271 fi
10272 fi
10273 fi
10274 ;;
10275 -R*)
10276 dir=`echo "X$dep" | sed -e 's/^X-R//'`
10277 if test "$enable_rpath" != no; then
10278 haveit=
10279 for x in $rpathdirs; do
10280 if test "X$x" = "X$dir"; then
10281 haveit=yes
10282 break
10283 fi
10284 done
10285 if test -z "$haveit"; then
10286 rpathdirs="$rpathdirs $dir"
10287 fi
10288 haveit=
10289 for x in $ltrpathdirs; do
10290 if test "X$x" = "X$dir"; then
10291 haveit=yes
10292 break
10293 fi
10294 done
10295 if test -z "$haveit"; then
10296 ltrpathdirs="$ltrpathdirs $dir"
10297 fi
10298 fi
10299 ;;
10300 -l*)
10301 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
10302 ;;
10303 *.la)
10304 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
10305 ;;
10306 *)
10307 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$dep"
10308 LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }$dep"
10309 ;;
81ecdfbb
RW
10310 esac
10311 done
10312 fi
10313 else
10314 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-l$name"
10315 LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-l$name"
10316 fi
10317 fi
10318 fi
10319 done
10320 done
10321 if test "X$rpathdirs" != "X"; then
10322 if test -n "$hardcode_libdir_separator"; then
10323 alldirs=
10324 for found_dir in $rpathdirs; do
10325 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
10326 done
10327 acl_save_libdir="$libdir"
10328 libdir="$alldirs"
10329 eval flag=\"$hardcode_libdir_flag_spec\"
10330 libdir="$acl_save_libdir"
10331 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$flag"
10332 else
10333 for found_dir in $rpathdirs; do
10334 acl_save_libdir="$libdir"
10335 libdir="$found_dir"
10336 eval flag=\"$hardcode_libdir_flag_spec\"
10337 libdir="$acl_save_libdir"
10338 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$flag"
10339 done
10340 fi
10341 fi
10342 if test "X$ltrpathdirs" != "X"; then
10343 for found_dir in $ltrpathdirs; do
10344 LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-R$found_dir"
10345 done
10346 fi
a9322a30
TT
10347
10348
81ecdfbb 10349 ac_save_CPPFLAGS="$CPPFLAGS"
a9322a30 10350
81ecdfbb
RW
10351 for element in $INCEXPAT; do
10352 haveit=
10353 for x in $CPPFLAGS; do
a9322a30 10354
81ecdfbb
RW
10355 acl_save_prefix="$prefix"
10356 prefix="$acl_final_prefix"
10357 acl_save_exec_prefix="$exec_prefix"
10358 exec_prefix="$acl_final_exec_prefix"
10359 eval x=\"$x\"
10360 exec_prefix="$acl_save_exec_prefix"
10361 prefix="$acl_save_prefix"
a8111142 10362
81ecdfbb
RW
10363 if test "X$x" = "X$element"; then
10364 haveit=yes
10365 break
10366 fi
10367 done
10368 if test -z "$haveit"; then
10369 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
10370 fi
10371 done
a9322a30
TT
10372
10373
81ecdfbb
RW
10374 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libexpat" >&5
10375$as_echo_n "checking for libexpat... " >&6; }
10376if test "${ac_cv_libexpat+set}" = set; then :
10377 $as_echo_n "(cached) " >&6
bec39cab 10378else
bec39cab 10379
81ecdfbb
RW
10380 ac_save_LIBS="$LIBS"
10381 LIBS="$LIBS $LIBEXPAT"
10382 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 10383/* end confdefs.h. */
81ecdfbb
RW
10384#include "expat.h"
10385int
10386main ()
10387{
10388XML_Parser p = XML_ParserCreate (0);
10389 ;
10390 return 0;
10391}
bec39cab 10392_ACEOF
81ecdfbb
RW
10393if ac_fn_c_try_link "$LINENO"; then :
10394 ac_cv_libexpat=yes
c906108c 10395else
81ecdfbb 10396 ac_cv_libexpat=no
bec39cab 10397fi
81ecdfbb
RW
10398rm -f core conftest.err conftest.$ac_objext \
10399 conftest$ac_exeext conftest.$ac_ext
10400 LIBS="$ac_save_LIBS"
c906108c 10401
95ca63c4 10402fi
81ecdfbb
RW
10403{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libexpat" >&5
10404$as_echo "$ac_cv_libexpat" >&6; }
10405 if test "$ac_cv_libexpat" = yes; then
10406 HAVE_LIBEXPAT=yes
bec39cab 10407
81ecdfbb 10408$as_echo "#define HAVE_LIBEXPAT 1" >>confdefs.h
bec39cab 10409
81ecdfbb
RW
10410 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libexpat" >&5
10411$as_echo_n "checking how to link with libexpat... " >&6; }
10412 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBEXPAT" >&5
10413$as_echo "$LIBEXPAT" >&6; }
10414 else
10415 HAVE_LIBEXPAT=no
10416 CPPFLAGS="$ac_save_CPPFLAGS"
10417 LIBEXPAT=
10418 LTLIBEXPAT=
10419 fi
95ca63c4
CF
10420
10421
10422
7cb9022a
MK
10423
10424
bec39cab 10425
81ecdfbb
RW
10426 if test "$HAVE_LIBEXPAT" != yes; then
10427 if test "$with_expat" = yes; then
10428 as_fn_error "expat is missing or unusable" "$LINENO" 5
10429 else
10430 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: expat is missing or unusable; some features may be unavailable." >&5
10431$as_echo "$as_me: WARNING: expat is missing or unusable; some features may be unavailable." >&2;}
10432 fi
10433 else
10434 save_LIBS=$LIBS
10435 LIBS="$LIBS $LIBEXPAT"
10436 for ac_func in XML_StopParser
10437do :
10438 ac_fn_c_check_func "$LINENO" "XML_StopParser" "ac_cv_func_XML_StopParser"
10439if test "x$ac_cv_func_XML_StopParser" = x""yes; then :
bec39cab 10440 cat >>confdefs.h <<_ACEOF
81ecdfbb 10441#define HAVE_XML_STOPPARSER 1
bec39cab 10442_ACEOF
95ca63c4 10443
bec39cab 10444fi
bec39cab 10445done
95ca63c4 10446
81ecdfbb
RW
10447 LIBS=$save_LIBS
10448 fi
a9322a30
TT
10449fi
10450
a9322a30 10451
a9322a30
TT
10452
10453
ec685c5e 10454
0c4a4063 10455
81ecdfbb
RW
10456# Check whether --with-python was given.
10457if test "${with_python+set}" = set; then :
10458 withval=$with_python;
bec39cab 10459else
81ecdfbb 10460 with_python=auto
bec39cab 10461fi
bec39cab 10462
81ecdfbb
RW
10463{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use python" >&5
10464$as_echo_n "checking whether to use python... " >&6; }
10465{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_python" >&5
10466$as_echo "$with_python" >&6; }
9a156167 10467
81ecdfbb
RW
10468if test "${with_python}" = no; then
10469 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: python support disabled; some features may be unavailable." >&5
10470$as_echo "$as_me: WARNING: python support disabled; some features may be unavailable." >&2;}
10471 have_libpython=no
bec39cab 10472else
81ecdfbb 10473 case "${with_python}" in
81ecdfbb 10474 /*)
ec685c5e
DE
10475 if test -d ${with_python}; then
10476 # Assume the python binary is ${with_python}/bin/python.
ec685c5e 10477 python_prog="${with_python}/bin/python"
0c4a4063 10478 python_prefix=
e7a30f46 10479 if test ! -x "${python_prog}"; then
ec685c5e
DE
10480 # Fall back to gdb 7.0/7.1 behaviour.
10481 python_prog=missing
0c4a4063 10482 python_prefix=${with_python}
ec685c5e 10483 fi
e7a30f46 10484 elif test -x "${with_python}"; then
ec685c5e
DE
10485 # While we can't run python compiled for $host (unless host == build),
10486 # the user could write a script that provides the needed information,
10487 # so we support that.
ec685c5e 10488 python_prog=${with_python}
0c4a4063 10489 python_prefix=
ec685c5e
DE
10490 else
10491 as_fn_error "invalid value for --with-python" "$LINENO" 5
10492 fi
81ecdfbb 10493 ;;
ec685c5e
DE
10494 */*)
10495 # Disallow --with-python=foo/bar.
81ecdfbb
RW
10496 as_fn_error "invalid value for --with-python" "$LINENO" 5
10497 ;;
ec685c5e
DE
10498 *)
10499 # The user has either specified auto, yes, or the name of the python
10500 # program assumed to be in $PATH.
10501 python_prefix=
10502 case "${with_python}" in
10503 yes | auto)
10504 if test ${build} = ${host}; then
10505 # Extract the first word of "python", so it can be a program name with args.
10506set dummy python; ac_word=$2
10507{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10508$as_echo_n "checking for $ac_word... " >&6; }
10509if test "${ac_cv_path_python_prog_path+set}" = set; then :
10510 $as_echo_n "(cached) " >&6
10511else
10512 case $python_prog_path in
10513 [\\/]* | ?:[\\/]*)
10514 ac_cv_path_python_prog_path="$python_prog_path" # Let the user override the test with a path.
10515 ;;
10516 *)
10517 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10518for as_dir in $PATH
10519do
10520 IFS=$as_save_IFS
10521 test -z "$as_dir" && as_dir=.
10522 for ac_exec_ext in '' $ac_executable_extensions; do
10523 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10524 ac_cv_path_python_prog_path="$as_dir/$ac_word$ac_exec_ext"
10525 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10526 break 2
10527 fi
10528done
10529 done
10530IFS=$as_save_IFS
10531
10532 test -z "$ac_cv_path_python_prog_path" && ac_cv_path_python_prog_path="missing"
10533 ;;
10534esac
10535fi
10536python_prog_path=$ac_cv_path_python_prog_path
10537if test -n "$python_prog_path"; then
10538 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $python_prog_path" >&5
10539$as_echo "$python_prog_path" >&6; }
10540else
10541 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10542$as_echo "no" >&6; }
10543fi
10544
10545
10546 if test "${python_prog_path}" = missing; then
10547 python_prog=missing
10548 else
10549 python_prog=${python_prog_path}
10550 fi
10551 else
10552 # Not much we can do except assume the cross-compiler will find the
10553 # right files.
10554 python_prog=missing
10555 fi
10556 ;;
10557 *)
10558 # While we can't run python compiled for $host (unless host == build),
10559 # the user could write a script that provides the needed information,
10560 # so we support that.
10561 python_prog="${with_python}"
10562 # Extract the first word of "${python_prog}", so it can be a program name with args.
10563set dummy ${python_prog}; ac_word=$2
10564{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10565$as_echo_n "checking for $ac_word... " >&6; }
10566if test "${ac_cv_path_python_prog_path+set}" = set; then :
10567 $as_echo_n "(cached) " >&6
10568else
10569 case $python_prog_path in
10570 [\\/]* | ?:[\\/]*)
10571 ac_cv_path_python_prog_path="$python_prog_path" # Let the user override the test with a path.
10572 ;;
10573 *)
10574 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10575for as_dir in $PATH
10576do
10577 IFS=$as_save_IFS
10578 test -z "$as_dir" && as_dir=.
10579 for ac_exec_ext in '' $ac_executable_extensions; do
10580 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10581 ac_cv_path_python_prog_path="$as_dir/$ac_word$ac_exec_ext"
10582 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10583 break 2
10584 fi
10585done
10586 done
10587IFS=$as_save_IFS
10588
10589 test -z "$ac_cv_path_python_prog_path" && ac_cv_path_python_prog_path="missing"
10590 ;;
10591esac
10592fi
10593python_prog_path=$ac_cv_path_python_prog_path
10594if test -n "$python_prog_path"; then
10595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $python_prog_path" >&5
10596$as_echo "$python_prog_path" >&6; }
10597else
10598 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10599$as_echo "no" >&6; }
10600fi
10601
10602
10603 if test "${python_prog_path}" = missing; then
10604 as_fn_error "unable to find python program ${python_prog}" "$LINENO" 5
10605 fi
10606 ;;
10607 esac
81ecdfbb
RW
10608 esac
10609
ec685c5e 10610 if test "${python_prog}" != missing; then
e7a30f46
DE
10611 # We have a python program to use, but it may be too old.
10612 # Don't flag an error for --with-python=auto (the default).
10613 have_python_config=yes
ec685c5e
DE
10614 python_includes=`${python_prog} ${srcdir}/python/python-config.py --includes`
10615 if test $? != 0; then
e7a30f46
DE
10616 have_python_config=failed
10617 if test "${with_python}" != auto; then
10618 as_fn_error "failure running python-config --includes" "$LINENO" 5
10619 fi
ec685c5e
DE
10620 fi
10621 python_libs=`${python_prog} ${srcdir}/python/python-config.py --ldflags`
10622 if test $? != 0; then
e7a30f46
DE
10623 have_python_config=failed
10624 if test "${with_python}" != auto; then
10625 as_fn_error "failure running python-config --ldflags" "$LINENO" 5
10626 fi
ec685c5e 10627 fi
0c4a4063
DE
10628 python_prefix=`${python_prog} ${srcdir}/python/python-config.py --exec-prefix`
10629 if test $? != 0; then
e7a30f46
DE
10630 have_python_config=failed
10631 if test "${with_python}" != auto; then
10632 as_fn_error "failure running python-config --exec-prefix" "$LINENO" 5
10633 fi
0c4a4063 10634 fi
ec685c5e
DE
10635 else
10636 # Fall back to gdb 7.0/7.1 behaviour.
10637 if test -z ${python_prefix}; then
10638 python_includes=
10639 python_libs=
10640 else
10641 python_includes="-I${python_prefix}/include"
10642 python_libs="-L${python_prefix}/lib"
10643 fi
0c4a4063 10644 have_python_config=no
ec685c5e 10645 fi
bec39cab 10646
ec685c5e
DE
10647 # Having "/pythonX.Y" in the include path is awkward.
10648 # All those python headers get bubbled up to the top inviting lots
10649 # of random collisions. GDB originally didn't use python-config to
10650 # find the compilation parameters and includes "pythonX.Y/" in the
10651 # path of the, umm, include file. So strip away this part of the
10652 # output of python-config --includes.
10653 python_includes=`echo "${python_includes} " \
0c4a4063 10654 | sed -e 's,/python[0-9]*[.][0-9]* , ,g'`
bec39cab 10655
ec685c5e
DE
10656 # If we have python-config, only try the configuration it provides.
10657 # Otherwise fallback on the old way of trying different versions of
10658 # python in turn.
81ecdfbb 10659
ec685c5e
DE
10660 have_libpython=no
10661 if test "${have_python_config}" = yes; then
10662 python_version=`echo " ${python_libs} " \
0c4a4063
DE
10663 | sed -e 's,^.* -l\(python[0-9]*[.][0-9]*\) .*$,\1,'`
10664 case "${python_version}" in
10665 python*)
ec685c5e
DE
10666
10667 version=${python_version}
10668
10669 new_CPPFLAGS=${python_includes}
10670 new_LIBS=${python_libs}
81ecdfbb
RW
10671 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${version}" >&5
10672$as_echo_n "checking for ${version}... " >&6; }
ec685c5e 10673 save_CPPFLAGS=$CPPFLAGS
81ecdfbb 10674 save_LIBS=$LIBS
ec685c5e
DE
10675 CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
10676 LIBS="$LIBS $new_LIBS"
10677 found_usable_python=no
81ecdfbb 10678 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 10679/* end confdefs.h. */
81ecdfbb
RW
10680#include "${version}/Python.h"
10681int
10682main ()
10683{
10684Py_Initialize ();
10685 ;
10686 return 0;
10687}
bec39cab 10688_ACEOF
81ecdfbb 10689if ac_fn_c_try_link "$LINENO"; then :
ec685c5e
DE
10690 have_libpython=${version}
10691 found_usable_python=yes
bec39cab 10692else
ec685c5e
DE
10693 CPPFLAGS=$save_CPPFLAGS
10694 LIBS=$save_LIBS
9a156167 10695fi
81ecdfbb
RW
10696rm -f core conftest.err conftest.$ac_objext \
10697 conftest$ac_exeext conftest.$ac_ext
ec685c5e
DE
10698 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_python}" >&5
10699$as_echo "${found_usable_python}" >&6; }
9a156167 10700
0c4a4063
DE
10701 ;;
10702 *)
ec685c5e 10703 as_fn_error "unable to determine python version from ${python_libs}" "$LINENO" 5
0c4a4063
DE
10704 ;;
10705 esac
e7a30f46 10706 elif test "${have_python_config}" != failed; then
ec685c5e 10707 if test "${have_libpython}" = no; then
9a156167 10708
420697bb
TT
10709 version=python2.7
10710
10711 new_CPPFLAGS=${python_includes}
10712 new_LIBS="${python_libs} -lpython2.7"
10713 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${version}" >&5
10714$as_echo_n "checking for ${version}... " >&6; }
10715 save_CPPFLAGS=$CPPFLAGS
10716 save_LIBS=$LIBS
10717 CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
10718 LIBS="$LIBS $new_LIBS"
10719 found_usable_python=no
10720 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10721/* end confdefs.h. */
10722#include "${version}/Python.h"
10723int
10724main ()
10725{
10726Py_Initialize ();
10727 ;
10728 return 0;
10729}
10730_ACEOF
10731if ac_fn_c_try_link "$LINENO"; then :
10732 have_libpython=${version}
10733 found_usable_python=yes
10734else
10735 CPPFLAGS=$save_CPPFLAGS
10736 LIBS=$save_LIBS
10737fi
10738rm -f core conftest.err conftest.$ac_objext \
10739 conftest$ac_exeext conftest.$ac_ext
10740 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_python}" >&5
10741$as_echo "${found_usable_python}" >&6; }
10742
10743 fi
10744 if test "${have_libpython}" = no; then
10745
ec685c5e
DE
10746 version=python2.6
10747
10748 new_CPPFLAGS=${python_includes}
10749 new_LIBS="${python_libs} -lpython2.6"
10750 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${version}" >&5
10751$as_echo_n "checking for ${version}... " >&6; }
10752 save_CPPFLAGS=$CPPFLAGS
10753 save_LIBS=$LIBS
10754 CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
10755 LIBS="$LIBS $new_LIBS"
10756 found_usable_python=no
10757 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10758/* end confdefs.h. */
10759#include "${version}/Python.h"
10760int
10761main ()
10762{
10763Py_Initialize ();
10764 ;
10765 return 0;
10766}
10767_ACEOF
10768if ac_fn_c_try_link "$LINENO"; then :
10769 have_libpython=${version}
10770 found_usable_python=yes
10771else
10772 CPPFLAGS=$save_CPPFLAGS
10773 LIBS=$save_LIBS
10774fi
10775rm -f core conftest.err conftest.$ac_objext \
10776 conftest$ac_exeext conftest.$ac_ext
10777 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_python}" >&5
10778$as_echo "${found_usable_python}" >&6; }
9a156167 10779
81ecdfbb 10780 fi
ec685c5e 10781 if test ${have_libpython} = no; then
9a156167 10782
81ecdfbb 10783 version=python2.5
9a156167 10784
ec685c5e
DE
10785 new_CPPFLAGS=${python_includes}
10786 new_LIBS="${python_libs} -lpython2.5"
81ecdfbb
RW
10787 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${version}" >&5
10788$as_echo_n "checking for ${version}... " >&6; }
ec685c5e 10789 save_CPPFLAGS=$CPPFLAGS
81ecdfbb 10790 save_LIBS=$LIBS
ec685c5e
DE
10791 CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
10792 LIBS="$LIBS $new_LIBS"
10793 found_usable_python=no
81ecdfbb 10794 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
436868fb 10795/* end confdefs.h. */
81ecdfbb
RW
10796#include "${version}/Python.h"
10797int
10798main ()
10799{
10800Py_Initialize ();
10801 ;
10802 return 0;
10803}
436868fb 10804_ACEOF
81ecdfbb 10805if ac_fn_c_try_link "$LINENO"; then :
ec685c5e
DE
10806 have_libpython=${version}
10807 found_usable_python=yes
436868fb 10808else
ec685c5e
DE
10809 CPPFLAGS=$save_CPPFLAGS
10810 LIBS=$save_LIBS
436868fb 10811fi
81ecdfbb
RW
10812rm -f core conftest.err conftest.$ac_objext \
10813 conftest$ac_exeext conftest.$ac_ext
ec685c5e
DE
10814 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_python}" >&5
10815$as_echo "${found_usable_python}" >&6; }
a9322a30 10816
81ecdfbb 10817 fi
ec685c5e 10818 if test ${have_libpython} = no; then
a9322a30 10819
81ecdfbb 10820 version=python2.4
a9322a30 10821
ec685c5e
DE
10822 new_CPPFLAGS=${python_includes}
10823 new_LIBS="${python_libs} -lpython2.4"
81ecdfbb
RW
10824 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${version}" >&5
10825$as_echo_n "checking for ${version}... " >&6; }
ec685c5e 10826 save_CPPFLAGS=$CPPFLAGS
81ecdfbb 10827 save_LIBS=$LIBS
ec685c5e
DE
10828 CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
10829 LIBS="$LIBS $new_LIBS"
10830 found_usable_python=no
81ecdfbb 10831 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
436868fb 10832/* end confdefs.h. */
81ecdfbb 10833#include "${version}/Python.h"
a9322a30
TT
10834int
10835main ()
10836{
81ecdfbb 10837Py_Initialize ();
a9322a30
TT
10838 ;
10839 return 0;
10840}
436868fb 10841_ACEOF
81ecdfbb 10842if ac_fn_c_try_link "$LINENO"; then :
ec685c5e
DE
10843 have_libpython=${version}
10844 found_usable_python=yes
436868fb 10845else
ec685c5e
DE
10846 CPPFLAGS=$save_CPPFLAGS
10847 LIBS=$save_LIBS
436868fb 10848fi
81ecdfbb
RW
10849rm -f core conftest.err conftest.$ac_objext \
10850 conftest$ac_exeext conftest.$ac_ext
ec685c5e
DE
10851 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_python}" >&5
10852$as_echo "${found_usable_python}" >&6; }
81ecdfbb 10853
ec685c5e
DE
10854 fi
10855 fi
11763c18
TT
10856 if test "${have_libpython}" = python2.7; then
10857
10858$as_echo "#define HAVE_LIBPYTHON2_7 1" >>confdefs.h
10859
10860 elif test "${have_libpython}" = python2.6; then
ec685c5e
DE
10861
10862$as_echo "#define HAVE_LIBPYTHON2_6 1" >>confdefs.h
10863
10864 elif test "${have_libpython}" = python2.5; then
10865
10866$as_echo "#define HAVE_LIBPYTHON2_5 1" >>confdefs.h
10867
10868 elif test "${have_libpython}" = python2.4; then
81ecdfbb
RW
10869
10870$as_echo "#define HAVE_LIBPYTHON2_4 1" >>confdefs.h
10871
81ecdfbb 10872 fi
ec685c5e
DE
10873
10874 if test "${have_libpython}" = no; then
81ecdfbb
RW
10875 case "${with_python}" in
10876 yes)
10877 as_fn_error "python is missing or unusable" "$LINENO" 5
10878 ;;
10879 auto)
10880 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: python is missing or unusable; some features may be unavailable." >&5
10881$as_echo "$as_me: WARNING: python is missing or unusable; some features may be unavailable." >&2;}
10882 ;;
10883 *)
10884 as_fn_error "no usable python found at ${with_python}" "$LINENO" 5
10885 ;;
10886 esac
0c4a4063
DE
10887 else
10888 if test -n "${python_prefix}"; then
10889
10890cat >>confdefs.h <<_ACEOF
10891#define WITH_PYTHON_PATH "${python_prefix}"
10892_ACEOF
10893
10894
10895 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
10896 if test "x$prefix" = xNONE; then
10897 test_prefix=/usr/local
10898 else
10899 test_prefix=$prefix
10900 fi
10901 else
10902 test_prefix=$exec_prefix
10903 fi
10904 value=0
10905 case ${python_prefix} in
10906 "${test_prefix}"|"${test_prefix}/"*|\
10907 '${exec_prefix}'|'${exec_prefix}/'*)
10908 value=1
10909 ;;
10910 esac
10911
10912cat >>confdefs.h <<_ACEOF
10913#define PYTHON_PATH_RELOCATABLE $value
10914_ACEOF
10915
10916
10917 fi
81ecdfbb 10918 fi
436868fb 10919fi
436868fb 10920
ec685c5e 10921if test "${have_libpython}" != no; then
436868fb 10922
81ecdfbb 10923$as_echo "#define HAVE_PYTHON 1" >>confdefs.h
436868fb 10924
81ecdfbb
RW
10925 CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_PYTHON_OBS)"
10926 CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_PYTHON_DEPS)"
10927 CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_PYTHON_SRCS)"
94f7449c 10928 CONFIG_INSTALL="$CONFIG_INSTALL install-python"
81ecdfbb 10929 ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_PYTHON_CFLAGS)"
436868fb 10930
81ecdfbb
RW
10931 # Flags needed to compile Python code (taken from python-config --cflags).
10932 # We cannot call python-config directly because it will output whatever was
10933 # used when compiling the Python interpreter itself, including flags which
10934 # would make the python-related objects be compiled differently from the
10935 # rest of GDB (e.g., -O2 and -fPIC).
10936 if test "${GCC}" = yes; then
10937 tentative_python_cflags="-fno-strict-aliasing -DNDEBUG -fwrapv"
10938 fi
436868fb 10939
81ecdfbb
RW
10940 if test "x${tentative_python_cflags}" != x; then
10941 { $as_echo "$as_me:${as_lineno-$LINENO}: checking compiler flags for python code" >&5
10942$as_echo_n "checking compiler flags for python code... " >&6; }
10943 for flag in ${tentative_python_cflags}; do
10944 # Check that the compiler accepts it
10945 saved_CFLAGS="$CFLAGS"
10946 CFLAGS="$CFLAGS $flag"
10947 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 10948/* end confdefs.h. */
81ecdfbb 10949
a9322a30
TT
10950int
10951main ()
10952{
a9322a30
TT
10953
10954 ;
10955 return 0;
10956}
bec39cab 10957_ACEOF
81ecdfbb
RW
10958if ac_fn_c_try_compile "$LINENO"; then :
10959 PYTHON_CFLAGS="${PYTHON_CFLAGS} $flag"
bec39cab 10960fi
81ecdfbb
RW
10961rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10962 CFLAGS="$saved_CFLAGS"
10963 done
10964 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${PYTHON_CFLAGS}" >&5
10965$as_echo "${PYTHON_CFLAGS}" >&6; }
10966 fi
10967else
10968 # Even if Python support is not compiled in, we need to have these files
88a1906b
DE
10969 # included.
10970 CONFIG_OBS="$CONFIG_OBS python.o py-value.o py-prettyprint.o py-auto-load.o"
10971 CONFIG_SRCS="$CONFIG_SRCS python/python.c python/py-value.c \
10972 python/py-prettyprint.c python/py-auto-load.c"
a9322a30 10973fi
9a156167 10974
9a156167 10975
81ecdfbb
RW
10976# ------------------------- #
10977# Checks for header files. #
10978# ------------------------- #
c890192f 10979
81ecdfbb
RW
10980ac_header_dirent=no
10981for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
10982 as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
10983{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5
10984$as_echo_n "checking for $ac_hdr that defines DIR... " >&6; }
10985if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then :
10986 $as_echo_n "(cached) " >&6
bec39cab 10987else
81ecdfbb 10988 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 10989/* end confdefs.h. */
81ecdfbb
RW
10990#include <sys/types.h>
10991#include <$ac_hdr>
10992
a9322a30
TT
10993int
10994main ()
10995{
81ecdfbb
RW
10996if ((DIR *) 0)
10997return 0;
a9322a30
TT
10998 ;
10999 return 0;
11000}
bec39cab 11001_ACEOF
81ecdfbb
RW
11002if ac_fn_c_try_compile "$LINENO"; then :
11003 eval "$as_ac_Header=yes"
bec39cab 11004else
81ecdfbb 11005 eval "$as_ac_Header=no"
bec39cab 11006fi
81ecdfbb 11007rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
a9322a30 11008fi
81ecdfbb
RW
11009eval ac_res=\$$as_ac_Header
11010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
11011$as_echo "$ac_res" >&6; }
11012eval as_val=\$$as_ac_Header
11013 if test "x$as_val" = x""yes; then :
11014 cat >>confdefs.h <<_ACEOF
11015#define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
bec39cab 11016_ACEOF
bec39cab 11017
81ecdfbb
RW
11018ac_header_dirent=$ac_hdr; break
11019fi
bec39cab 11020
81ecdfbb
RW
11021done
11022# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
11023if test $ac_header_dirent = dirent.h; then
11024 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5
11025$as_echo_n "checking for library containing opendir... " >&6; }
11026if test "${ac_cv_search_opendir+set}" = set; then :
11027 $as_echo_n "(cached) " >&6
c890192f 11028else
81ecdfbb
RW
11029 ac_func_search_save_LIBS=$LIBS
11030cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11031/* end confdefs.h. */
11032
11033/* Override any GCC internal prototype to avoid an error.
11034 Use char because int might match the return type of a GCC
11035 builtin and then its argument prototype would still apply. */
11036#ifdef __cplusplus
11037extern "C"
11038#endif
11039char opendir ();
11040int
11041main ()
11042{
11043return opendir ();
11044 ;
11045 return 0;
11046}
bec39cab 11047_ACEOF
81ecdfbb
RW
11048for ac_lib in '' dir; do
11049 if test -z "$ac_lib"; then
11050 ac_res="none required"
11051 else
11052 ac_res=-l$ac_lib
11053 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11054 fi
11055 if ac_fn_c_try_link "$LINENO"; then :
11056 ac_cv_search_opendir=$ac_res
11057fi
11058rm -f core conftest.err conftest.$ac_objext \
11059 conftest$ac_exeext
11060 if test "${ac_cv_search_opendir+set}" = set; then :
11061 break
11062fi
11063done
11064if test "${ac_cv_search_opendir+set}" = set; then :
c890192f 11065
81ecdfbb
RW
11066else
11067 ac_cv_search_opendir=no
11068fi
11069rm conftest.$ac_ext
11070LIBS=$ac_func_search_save_LIBS
11071fi
11072{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5
11073$as_echo "$ac_cv_search_opendir" >&6; }
11074ac_res=$ac_cv_search_opendir
11075if test "$ac_res" != no; then :
11076 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
bec39cab 11077
bec39cab 11078fi
81ecdfbb 11079
bec39cab 11080else
81ecdfbb
RW
11081 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5
11082$as_echo_n "checking for library containing opendir... " >&6; }
11083if test "${ac_cv_search_opendir+set}" = set; then :
11084 $as_echo_n "(cached) " >&6
11085else
11086 ac_func_search_save_LIBS=$LIBS
11087cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 11088/* end confdefs.h. */
81ecdfbb
RW
11089
11090/* Override any GCC internal prototype to avoid an error.
11091 Use char because int might match the return type of a GCC
11092 builtin and then its argument prototype would still apply. */
11093#ifdef __cplusplus
11094extern "C"
11095#endif
11096char opendir ();
a9322a30
TT
11097int
11098main ()
11099{
81ecdfbb 11100return opendir ();
a9322a30
TT
11101 ;
11102 return 0;
11103}
bec39cab 11104_ACEOF
81ecdfbb
RW
11105for ac_lib in '' x; do
11106 if test -z "$ac_lib"; then
11107 ac_res="none required"
11108 else
11109 ac_res=-l$ac_lib
11110 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11111 fi
11112 if ac_fn_c_try_link "$LINENO"; then :
11113 ac_cv_search_opendir=$ac_res
11114fi
11115rm -f core conftest.err conftest.$ac_objext \
11116 conftest$ac_exeext
11117 if test "${ac_cv_search_opendir+set}" = set; then :
11118 break
11119fi
11120done
11121if test "${ac_cv_search_opendir+set}" = set; then :
bec39cab 11122
81ecdfbb
RW
11123else
11124 ac_cv_search_opendir=no
bec39cab 11125fi
81ecdfbb
RW
11126rm conftest.$ac_ext
11127LIBS=$ac_func_search_save_LIBS
a9322a30 11128fi
81ecdfbb
RW
11129{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5
11130$as_echo "$ac_cv_search_opendir" >&6; }
11131ac_res=$ac_cv_search_opendir
11132if test "$ac_res" != no; then :
11133 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
bec39cab 11134
81ecdfbb 11135fi
bec39cab 11136
81ecdfbb 11137fi
bec39cab 11138
81ecdfbb
RW
11139{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5
11140$as_echo_n "checking whether stat file-mode macros are broken... " >&6; }
11141if test "${ac_cv_header_stat_broken+set}" = set; then :
11142 $as_echo_n "(cached) " >&6
9a156167 11143else
81ecdfbb
RW
11144 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11145/* end confdefs.h. */
11146#include <sys/types.h>
11147#include <sys/stat.h>
11148
11149#if defined S_ISBLK && defined S_IFDIR
11150extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1];
11151#endif
11152
11153#if defined S_ISBLK && defined S_IFCHR
11154extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1];
11155#endif
11156
11157#if defined S_ISLNK && defined S_IFREG
11158extern char c3[S_ISLNK (S_IFREG) ? -1 : 1];
11159#endif
11160
11161#if defined S_ISSOCK && defined S_IFREG
11162extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1];
11163#endif
11164
bec39cab 11165_ACEOF
81ecdfbb
RW
11166if ac_fn_c_try_compile "$LINENO"; then :
11167 ac_cv_header_stat_broken=no
11168else
11169 ac_cv_header_stat_broken=yes
11170fi
11171rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11172fi
11173{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5
11174$as_echo "$ac_cv_header_stat_broken" >&6; }
11175if test $ac_cv_header_stat_broken = yes; then
9a156167 11176
81ecdfbb 11177$as_echo "#define STAT_MACROS_BROKEN 1" >>confdefs.h
06825bd1 11178
bec39cab 11179fi
81ecdfbb
RW
11180
11181{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
11182$as_echo_n "checking for ANSI C header files... " >&6; }
11183if test "${ac_cv_header_stdc+set}" = set; then :
11184 $as_echo_n "(cached) " >&6
bec39cab 11185else
81ecdfbb 11186 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 11187/* end confdefs.h. */
81ecdfbb
RW
11188#include <stdlib.h>
11189#include <stdarg.h>
11190#include <string.h>
11191#include <float.h>
11192
a9322a30
TT
11193int
11194main ()
11195{
a9322a30
TT
11196
11197 ;
11198 return 0;
11199}
bec39cab 11200_ACEOF
81ecdfbb
RW
11201if ac_fn_c_try_compile "$LINENO"; then :
11202 ac_cv_header_stdc=yes
bec39cab 11203else
81ecdfbb 11204 ac_cv_header_stdc=no
a9322a30 11205fi
81ecdfbb 11206rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
bec39cab 11207
81ecdfbb
RW
11208if test $ac_cv_header_stdc = yes; then
11209 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
11210 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11211/* end confdefs.h. */
11212#include <string.h>
bec39cab 11213
81ecdfbb
RW
11214_ACEOF
11215if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11216 $EGREP "memchr" >/dev/null 2>&1; then :
bec39cab 11217
bec39cab 11218else
81ecdfbb
RW
11219 ac_cv_header_stdc=no
11220fi
11221rm -f conftest*
11222
11223fi
11224
11225if test $ac_cv_header_stdc = yes; then
11226 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
11227 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11228/* end confdefs.h. */
11229#include <stdlib.h>
11230
bec39cab 11231_ACEOF
81ecdfbb
RW
11232if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11233 $EGREP "free" >/dev/null 2>&1; then :
06825bd1 11234
81ecdfbb
RW
11235else
11236 ac_cv_header_stdc=no
11237fi
11238rm -f conftest*
bec39cab 11239
bec39cab 11240fi
81ecdfbb
RW
11241
11242if test $ac_cv_header_stdc = yes; then
11243 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
11244 if test "$cross_compiling" = yes; then :
11245 :
bec39cab 11246else
81ecdfbb 11247 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 11248/* end confdefs.h. */
81ecdfbb
RW
11249#include <ctype.h>
11250#include <stdlib.h>
11251#if ((' ' & 0x0FF) == 0x020)
11252# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
11253# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
11254#else
11255# define ISLOWER(c) \
11256 (('a' <= (c) && (c) <= 'i') \
11257 || ('j' <= (c) && (c) <= 'r') \
11258 || ('s' <= (c) && (c) <= 'z'))
11259# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
11260#endif
11261
11262#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
a9322a30
TT
11263int
11264main ()
11265{
81ecdfbb
RW
11266 int i;
11267 for (i = 0; i < 256; i++)
11268 if (XOR (islower (i), ISLOWER (i))
11269 || toupper (i) != TOUPPER (i))
11270 return 2;
a9322a30
TT
11271 return 0;
11272}
bec39cab 11273_ACEOF
81ecdfbb
RW
11274if ac_fn_c_try_run "$LINENO"; then :
11275
bec39cab 11276else
81ecdfbb
RW
11277 ac_cv_header_stdc=no
11278fi
11279rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11280 conftest.$ac_objext conftest.beam conftest.$ac_ext
11281fi
bec39cab 11282
bec39cab 11283fi
a9322a30 11284fi
81ecdfbb
RW
11285{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
11286$as_echo "$ac_cv_header_stdc" >&6; }
11287if test $ac_cv_header_stdc = yes; then
bec39cab 11288
81ecdfbb 11289$as_echo "#define STDC_HEADERS 1" >>confdefs.h
5ee754fc 11290
81ecdfbb 11291fi
bec39cab 11292
81ecdfbb
RW
11293# elf_hp.h is for HP/UX 64-bit shared library support.
11294# FIXME: kettenis/20030102: In most cases we include these (ctype.h, time.h)
11295# unconditionally, so what's the point in checking these?
11296for ac_header in nlist.h machine/reg.h poll.h sys/poll.h proc_service.h \
11297 thread_db.h gnu/libc-version.h signal.h stddef.h \
11298 stdlib.h string.h memory.h strings.h sys/fault.h \
11299 sys/file.h sys/filio.h sys/ioctl.h sys/param.h \
11300 sys/resource.h sys/procfs.h sys/ptrace.h ptrace.h \
11301 sys/reg.h sys/debugreg.h sys/select.h sys/syscall.h \
11302 sys/types.h sys/wait.h wait.h termios.h termio.h \
11303 sgtty.h unistd.h elf_hp.h ctype.h time.h locale.h
11304do :
11305 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11306ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
11307eval as_val=\$$as_ac_Header
11308 if test "x$as_val" = x""yes; then :
bec39cab 11309 cat >>confdefs.h <<_ACEOF
81ecdfbb 11310#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
bec39cab 11311_ACEOF
c906108c 11312
bec39cab 11313fi
81ecdfbb
RW
11314
11315done
11316
11317for ac_header in link.h
11318do :
11319 ac_fn_c_check_header_compile "$LINENO" "link.h" "ac_cv_header_link_h" "#if HAVE_SYS_TYPES_H
11320# include <sys/types.h>
11321#endif
11322#if HAVE_NLIST_H
11323# include <nlist.h>
a9322a30
TT
11324#endif
11325
81ecdfbb
RW
11326"
11327if test "x$ac_cv_header_link_h" = x""yes; then :
11328 cat >>confdefs.h <<_ACEOF
11329#define HAVE_LINK_H 1
bec39cab 11330_ACEOF
bec39cab 11331
a9322a30 11332fi
bec39cab 11333
81ecdfbb 11334done
c906108c 11335
81ecdfbb
RW
11336for ac_header in sys/proc.h
11337do :
11338 ac_fn_c_check_header_compile "$LINENO" "sys/proc.h" "ac_cv_header_sys_proc_h" "#if HAVE_SYS_PARAM_H
11339# include <sys/param.h>
11340#endif
c906108c 11341
81ecdfbb
RW
11342"
11343if test "x$ac_cv_header_sys_proc_h" = x""yes; then :
bec39cab 11344 cat >>confdefs.h <<_ACEOF
81ecdfbb 11345#define HAVE_SYS_PROC_H 1
bec39cab 11346_ACEOF
5ee754fc 11347
bec39cab 11348fi
81ecdfbb
RW
11349
11350done
11351
11352for ac_header in sys/user.h
11353do :
11354 ac_fn_c_check_header_compile "$LINENO" "sys/user.h" "ac_cv_header_sys_user_h" "#if HAVE_SYS_PARAM_H
11355# include <sys/param.h>
a9322a30
TT
11356#endif
11357
81ecdfbb
RW
11358"
11359if test "x$ac_cv_header_sys_user_h" = x""yes; then :
11360 cat >>confdefs.h <<_ACEOF
11361#define HAVE_SYS_USER_H 1
bec39cab 11362_ACEOF
bec39cab 11363
a9322a30 11364fi
bec39cab 11365
81ecdfbb 11366done
5ee754fc 11367
5ee754fc 11368
81ecdfbb
RW
11369# On Solaris 2.[789], we need to define _MSE_INT_H to avoid a clash
11370# between <widec.h> and <wchar.h> that would cause AC_CHECK_HEADERS to
11371# think that we don't have <curses.h> if we're using GCC.
11372case $host_os in
11373 solaris2.[789])
11374 if test "$GCC" = yes; then
11375
11376$as_echo "#define _MSE_INT_H 1" >>confdefs.h
11377
11378 fi ;;
11379esac
11380for ac_header in curses.h cursesX.h ncurses.h ncurses/ncurses.h ncurses/term.h
11381do :
11382 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11383ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
11384eval as_val=\$$as_ac_Header
11385 if test "x$as_val" = x""yes; then :
bec39cab 11386 cat >>confdefs.h <<_ACEOF
81ecdfbb 11387#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
bec39cab 11388_ACEOF
5ee754fc
MK
11389
11390fi
11391
81ecdfbb 11392done
bec39cab 11393
81ecdfbb
RW
11394for ac_header in term.h
11395do :
11396 ac_fn_c_check_header_compile "$LINENO" "term.h" "ac_cv_header_term_h" "#if HAVE_CURSES_H
11397# include <curses.h>
11398#endif
bec39cab 11399
81ecdfbb
RW
11400"
11401if test "x$ac_cv_header_term_h" = x""yes; then :
11402 cat >>confdefs.h <<_ACEOF
11403#define HAVE_TERM_H 1
a8111142 11404_ACEOF
a8111142 11405
a8111142 11406fi
a8111142 11407
81ecdfbb 11408done
a8111142
TT
11409
11410
81ecdfbb
RW
11411# ------------------------- #
11412# Checks for declarations. #
11413# ------------------------- #
a9322a30 11414
81ecdfbb
RW
11415ac_fn_c_check_decl "$LINENO" "free" "ac_cv_have_decl_free" "$ac_includes_default"
11416if test "x$ac_cv_have_decl_free" = x""yes; then :
11417 ac_have_decl=1
bec39cab 11418else
81ecdfbb
RW
11419 ac_have_decl=0
11420fi
11421
11422cat >>confdefs.h <<_ACEOF
11423#define HAVE_DECL_FREE $ac_have_decl
bec39cab 11424_ACEOF
81ecdfbb
RW
11425ac_fn_c_check_decl "$LINENO" "malloc" "ac_cv_have_decl_malloc" "$ac_includes_default"
11426if test "x$ac_cv_have_decl_malloc" = x""yes; then :
11427 ac_have_decl=1
11428else
11429 ac_have_decl=0
11430fi
11431
11432cat >>confdefs.h <<_ACEOF
11433#define HAVE_DECL_MALLOC $ac_have_decl
bec39cab 11434_ACEOF
81ecdfbb
RW
11435ac_fn_c_check_decl "$LINENO" "realloc" "ac_cv_have_decl_realloc" "$ac_includes_default"
11436if test "x$ac_cv_have_decl_realloc" = x""yes; then :
11437 ac_have_decl=1
bec39cab 11438else
81ecdfbb
RW
11439 ac_have_decl=0
11440fi
bec39cab 11441
81ecdfbb
RW
11442cat >>confdefs.h <<_ACEOF
11443#define HAVE_DECL_REALLOC $ac_have_decl
bec39cab 11444_ACEOF
81ecdfbb
RW
11445ac_fn_c_check_decl "$LINENO" "strerror" "ac_cv_have_decl_strerror" "$ac_includes_default"
11446if test "x$ac_cv_have_decl_strerror" = x""yes; then :
11447 ac_have_decl=1
11448else
11449 ac_have_decl=0
11450fi
11451
11452cat >>confdefs.h <<_ACEOF
11453#define HAVE_DECL_STRERROR $ac_have_decl
bec39cab 11454_ACEOF
81ecdfbb
RW
11455ac_fn_c_check_decl "$LINENO" "strstr" "ac_cv_have_decl_strstr" "$ac_includes_default"
11456if test "x$ac_cv_have_decl_strstr" = x""yes; then :
11457 ac_have_decl=1
bec39cab 11458else
81ecdfbb
RW
11459 ac_have_decl=0
11460fi
5ee754fc 11461
81ecdfbb
RW
11462cat >>confdefs.h <<_ACEOF
11463#define HAVE_DECL_STRSTR $ac_have_decl
11464_ACEOF
11465ac_fn_c_check_decl "$LINENO" "getopt" "ac_cv_have_decl_getopt" "$ac_includes_default"
11466if test "x$ac_cv_have_decl_getopt" = x""yes; then :
11467 ac_have_decl=1
11468else
11469 ac_have_decl=0
5ee754fc 11470fi
81ecdfbb
RW
11471
11472cat >>confdefs.h <<_ACEOF
11473#define HAVE_DECL_GETOPT $ac_have_decl
11474_ACEOF
11475ac_fn_c_check_decl "$LINENO" "snprintf" "ac_cv_have_decl_snprintf" "$ac_includes_default"
11476if test "x$ac_cv_have_decl_snprintf" = x""yes; then :
11477 ac_have_decl=1
11478else
11479 ac_have_decl=0
5ee754fc 11480fi
81ecdfbb
RW
11481
11482cat >>confdefs.h <<_ACEOF
11483#define HAVE_DECL_SNPRINTF $ac_have_decl
11484_ACEOF
11485ac_fn_c_check_decl "$LINENO" "vsnprintf" "ac_cv_have_decl_vsnprintf" "$ac_includes_default"
11486if test "x$ac_cv_have_decl_vsnprintf" = x""yes; then :
11487 ac_have_decl=1
11488else
11489 ac_have_decl=0
5ee754fc
MK
11490fi
11491
a9322a30 11492cat >>confdefs.h <<_ACEOF
81ecdfbb 11493#define HAVE_DECL_VSNPRINTF $ac_have_decl
a9322a30 11494_ACEOF
5ee754fc 11495
5ee754fc 11496
81ecdfbb
RW
11497 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LC_MESSAGES" >&5
11498$as_echo_n "checking for LC_MESSAGES... " >&6; }
11499if test "${am_cv_val_LC_MESSAGES+set}" = set; then :
11500 $as_echo_n "(cached) " >&6
bec39cab 11501else
81ecdfbb 11502 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 11503/* end confdefs.h. */
81ecdfbb 11504#include <locale.h>
a9322a30
TT
11505int
11506main ()
11507{
81ecdfbb 11508return LC_MESSAGES
a9322a30
TT
11509 ;
11510 return 0;
11511}
bec39cab 11512_ACEOF
81ecdfbb
RW
11513if ac_fn_c_try_link "$LINENO"; then :
11514 am_cv_val_LC_MESSAGES=yes
bec39cab 11515else
81ecdfbb
RW
11516 am_cv_val_LC_MESSAGES=no
11517fi
11518rm -f core conftest.err conftest.$ac_objext \
11519 conftest$ac_exeext conftest.$ac_ext
11520fi
11521{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_val_LC_MESSAGES" >&5
11522$as_echo "$am_cv_val_LC_MESSAGES" >&6; }
11523 if test $am_cv_val_LC_MESSAGES = yes; then
bec39cab 11524
81ecdfbb
RW
11525$as_echo "#define HAVE_LC_MESSAGES 1" >>confdefs.h
11526
11527 fi
11528
11529
11530# ----------------------- #
11531# Checks for structures. #
11532# ----------------------- #
11533
11534ac_fn_c_check_member "$LINENO" "struct stat" "st_blocks" "ac_cv_member_struct_stat_st_blocks" "$ac_includes_default"
11535if test "x$ac_cv_member_struct_stat_st_blocks" = x""yes; then :
11536
11537cat >>confdefs.h <<_ACEOF
11538#define HAVE_STRUCT_STAT_ST_BLOCKS 1
7eb368b3 11539_ACEOF
7eb368b3 11540
81ecdfbb 11541
7eb368b3 11542fi
81ecdfbb
RW
11543ac_fn_c_check_member "$LINENO" "struct stat" "st_blksize" "ac_cv_member_struct_stat_st_blksize" "$ac_includes_default"
11544if test "x$ac_cv_member_struct_stat_st_blksize" = x""yes; then :
7eb368b3 11545
a9322a30
TT
11546cat >>confdefs.h <<_ACEOF
11547#define HAVE_STRUCT_STAT_ST_BLKSIZE 1
7eb368b3
NR
11548_ACEOF
11549
a9322a30 11550
7eb368b3
NR
11551fi
11552
7eb368b3 11553
a9322a30
TT
11554# ------------------ #
11555# Checks for types. #
11556# ------------------ #
7eb368b3 11557
81ecdfbb
RW
11558{ $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of signal handlers" >&5
11559$as_echo_n "checking return type of signal handlers... " >&6; }
11560if test "${ac_cv_type_signal+set}" = set; then :
11561 $as_echo_n "(cached) " >&6
bec39cab 11562else
81ecdfbb 11563 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 11564/* end confdefs.h. */
a9322a30
TT
11565#include <sys/types.h>
11566#include <signal.h>
7cb9022a 11567
a9322a30
TT
11568int
11569main ()
11570{
81ecdfbb 11571return *(signal (0, 0)) (0) == 1;
a9322a30
TT
11572 ;
11573 return 0;
11574}
bec39cab 11575_ACEOF
81ecdfbb
RW
11576if ac_fn_c_try_compile "$LINENO"; then :
11577 ac_cv_type_signal=int
bec39cab 11578else
81ecdfbb 11579 ac_cv_type_signal=void
bec39cab 11580fi
81ecdfbb 11581rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5ee754fc 11582fi
81ecdfbb
RW
11583{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_signal" >&5
11584$as_echo "$ac_cv_type_signal" >&6; }
bec39cab 11585
a9322a30
TT
11586cat >>confdefs.h <<_ACEOF
11587#define RETSIGTYPE $ac_cv_type_signal
11588_ACEOF
5ee754fc 11589
bec39cab 11590
81ecdfbb 11591ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "#include <sys/types.h>
a9322a30
TT
11592#include <sys/socket.h>
11593
81ecdfbb
RW
11594"
11595if test "x$ac_cv_type_socklen_t" = x""yes; then :
bec39cab 11596
a9322a30
TT
11597cat >>confdefs.h <<_ACEOF
11598#define HAVE_SOCKLEN_T 1
11599_ACEOF
11600
11601
11602fi
11603
11604
11605# ------------------------------------- #
11606# Checks for compiler characteristics. #
11607# ------------------------------------- #
11608
81ecdfbb
RW
11609{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
11610$as_echo_n "checking for an ANSI C-conforming const... " >&6; }
11611if test "${ac_cv_c_const+set}" = set; then :
11612 $as_echo_n "(cached) " >&6
a9322a30 11613else
81ecdfbb 11614 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 11615/* end confdefs.h. */
a9322a30
TT
11616
11617int
11618main ()
11619{
11620/* FIXME: Include the comments suggested by Paul. */
11621#ifndef __cplusplus
11622 /* Ultrix mips cc rejects this. */
11623 typedef int charset[2];
81ecdfbb 11624 const charset cs;
a9322a30 11625 /* SunOS 4.1.1 cc rejects this. */
81ecdfbb
RW
11626 char const *const *pcpcc;
11627 char **ppc;
a9322a30
TT
11628 /* NEC SVR4.0.2 mips cc rejects this. */
11629 struct point {int x, y;};
11630 static struct point const zero = {0,0};
11631 /* AIX XL C 1.02.0.0 rejects this.
11632 It does not let you subtract one const X* pointer from another in
11633 an arm of an if-expression whose if-part is not a constant
11634 expression */
11635 const char *g = "string";
81ecdfbb 11636 pcpcc = &g + (g ? g-g : 0);
a9322a30 11637 /* HPUX 7.0 cc rejects these. */
81ecdfbb
RW
11638 ++pcpcc;
11639 ppc = (char**) pcpcc;
11640 pcpcc = (char const *const *) ppc;
a9322a30
TT
11641 { /* SCO 3.2v4 cc rejects this. */
11642 char *t;
11643 char const *s = 0 ? (char *) 0 : (char const *) 0;
11644
11645 *t++ = 0;
81ecdfbb 11646 if (s) return 0;
a9322a30
TT
11647 }
11648 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
11649 int x[] = {25, 17};
11650 const int *foo = &x[0];
11651 ++foo;
11652 }
11653 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
11654 typedef const int *iptr;
11655 iptr p = 0;
11656 ++p;
11657 }
11658 { /* AIX XL C 1.02.0.0 rejects this saying
11659 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
11660 struct s { int j; const int *ap[3]; };
11661 struct s *b; b->j = 5;
11662 }
11663 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
11664 const int foo = 10;
81ecdfbb 11665 if (!foo) return 0;
a9322a30 11666 }
81ecdfbb 11667 return !cs[0] && !zero.x;
a9322a30
TT
11668#endif
11669
11670 ;
11671 return 0;
11672}
bec39cab 11673_ACEOF
81ecdfbb 11674if ac_fn_c_try_compile "$LINENO"; then :
a9322a30 11675 ac_cv_c_const=yes
5ee754fc 11676else
81ecdfbb 11677 ac_cv_c_const=no
5ee754fc 11678fi
81ecdfbb 11679rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5ee754fc 11680fi
81ecdfbb
RW
11681{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
11682$as_echo "$ac_cv_c_const" >&6; }
a9322a30 11683if test $ac_cv_c_const = no; then
bec39cab 11684
81ecdfbb 11685$as_echo "#define const /**/" >>confdefs.h
bec39cab 11686
5ee754fc 11687fi
bec39cab 11688
81ecdfbb
RW
11689{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
11690$as_echo_n "checking for inline... " >&6; }
11691if test "${ac_cv_c_inline+set}" = set; then :
11692 $as_echo_n "(cached) " >&6
bec39cab 11693else
a9322a30
TT
11694 ac_cv_c_inline=no
11695for ac_kw in inline __inline__ __inline; do
81ecdfbb 11696 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 11697/* end confdefs.h. */
a9322a30
TT
11698#ifndef __cplusplus
11699typedef int foo_t;
11700static $ac_kw foo_t static_foo () {return 0; }
11701$ac_kw foo_t foo () {return 0; }
11702#endif
11703
bec39cab 11704_ACEOF
81ecdfbb
RW
11705if ac_fn_c_try_compile "$LINENO"; then :
11706 ac_cv_c_inline=$ac_kw
bec39cab 11707fi
81ecdfbb
RW
11708rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11709 test "$ac_cv_c_inline" != no && break
a9322a30 11710done
bec39cab 11711
5ee754fc 11712fi
81ecdfbb
RW
11713{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
11714$as_echo "$ac_cv_c_inline" >&6; }
5ee754fc 11715
a9322a30
TT
11716case $ac_cv_c_inline in
11717 inline | yes) ;;
11718 *)
11719 case $ac_cv_c_inline in
11720 no) ac_val=;;
11721 *) ac_val=$ac_cv_c_inline;;
11722 esac
11723 cat >>confdefs.h <<_ACEOF
11724#ifndef __cplusplus
11725#define inline $ac_val
11726#endif
11727_ACEOF
bec39cab
AC
11728 ;;
11729esac
bec39cab 11730
81ecdfbb
RW
11731 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
11732$as_echo_n "checking whether byte ordering is bigendian... " >&6; }
11733if test "${ac_cv_c_bigendian+set}" = set; then :
11734 $as_echo_n "(cached) " >&6
bec39cab 11735else
81ecdfbb
RW
11736 ac_cv_c_bigendian=unknown
11737 # See if we're dealing with a universal compiler.
11738 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11739/* end confdefs.h. */
11740#ifndef __APPLE_CC__
11741 not a universal capable compiler
11742 #endif
11743 typedef int dummy;
11744
11745_ACEOF
11746if ac_fn_c_try_compile "$LINENO"; then :
11747
11748 # Check for potential -arch flags. It is not universal unless
11749 # there are at least two -arch flags with different values.
11750 ac_arch=
11751 ac_prev=
11752 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
11753 if test -n "$ac_prev"; then
11754 case $ac_word in
11755 i?86 | x86_64 | ppc | ppc64)
11756 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
11757 ac_arch=$ac_word
11758 else
11759 ac_cv_c_bigendian=universal
11760 break
11761 fi
11762 ;;
11763 esac
11764 ac_prev=
11765 elif test "x$ac_word" = "x-arch"; then
11766 ac_prev=arch
11767 fi
11768 done
11769fi
11770rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11771 if test $ac_cv_c_bigendian = unknown; then
11772 # See if sys/param.h defines the BYTE_ORDER macro.
11773 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 11774/* end confdefs.h. */
a9322a30 11775#include <sys/types.h>
81ecdfbb 11776 #include <sys/param.h>
a9322a30
TT
11777
11778int
11779main ()
11780{
81ecdfbb
RW
11781#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
11782 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
11783 && LITTLE_ENDIAN)
11784 bogus endian macros
11785 #endif
a9322a30
TT
11786
11787 ;
11788 return 0;
11789}
bec39cab 11790_ACEOF
81ecdfbb 11791if ac_fn_c_try_compile "$LINENO"; then :
a9322a30 11792 # It does; now see whether it defined to BIG_ENDIAN or not.
81ecdfbb 11793 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 11794/* end confdefs.h. */
a9322a30 11795#include <sys/types.h>
81ecdfbb 11796 #include <sys/param.h>
a9322a30
TT
11797
11798int
11799main ()
11800{
11801#if BYTE_ORDER != BIG_ENDIAN
81ecdfbb
RW
11802 not big endian
11803 #endif
a9322a30
TT
11804
11805 ;
11806 return 0;
11807}
bec39cab 11808_ACEOF
81ecdfbb 11809if ac_fn_c_try_compile "$LINENO"; then :
a9322a30 11810 ac_cv_c_bigendian=yes
5ee754fc 11811else
81ecdfbb 11812 ac_cv_c_bigendian=no
5ee754fc 11813fi
81ecdfbb
RW
11814rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11815fi
11816rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11817 fi
11818 if test $ac_cv_c_bigendian = unknown; then
11819 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
11820 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11821/* end confdefs.h. */
11822#include <limits.h>
bec39cab 11823
81ecdfbb
RW
11824int
11825main ()
11826{
11827#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
11828 bogus endian macros
11829 #endif
11830
11831 ;
11832 return 0;
11833}
7eb368b3 11834_ACEOF
81ecdfbb
RW
11835if ac_fn_c_try_compile "$LINENO"; then :
11836 # It does; now see whether it defined to _BIG_ENDIAN or not.
11837 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7eb368b3 11838/* end confdefs.h. */
81ecdfbb
RW
11839#include <limits.h>
11840
7eb368b3
NR
11841int
11842main ()
11843{
81ecdfbb
RW
11844#ifndef _BIG_ENDIAN
11845 not big endian
11846 #endif
11847
7eb368b3
NR
11848 ;
11849 return 0;
11850}
11851_ACEOF
81ecdfbb 11852if ac_fn_c_try_compile "$LINENO"; then :
a9322a30 11853 ac_cv_c_bigendian=yes
81ecdfbb
RW
11854else
11855 ac_cv_c_bigendian=no
a9322a30 11856fi
81ecdfbb 11857rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
a9322a30 11858fi
81ecdfbb
RW
11859rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11860 fi
11861 if test $ac_cv_c_bigendian = unknown; then
11862 # Compile a test program.
11863 if test "$cross_compiling" = yes; then :
11864 # Try to guess by grepping values from an object file.
11865 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11866/* end confdefs.h. */
11867short int ascii_mm[] =
11868 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
11869 short int ascii_ii[] =
11870 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
11871 int use_ascii (int i) {
11872 return ascii_mm[i] + ascii_ii[i];
11873 }
11874 short int ebcdic_ii[] =
11875 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
11876 short int ebcdic_mm[] =
11877 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
11878 int use_ebcdic (int i) {
11879 return ebcdic_mm[i] + ebcdic_ii[i];
11880 }
11881 extern int foo;
7eb368b3 11882
81ecdfbb
RW
11883int
11884main ()
11885{
11886return use_ascii (foo) == use_ebcdic (foo);
11887 ;
11888 return 0;
11889}
11890_ACEOF
11891if ac_fn_c_try_compile "$LINENO"; then :
11892 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
11893 ac_cv_c_bigendian=yes
11894 fi
11895 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
11896 if test "$ac_cv_c_bigendian" = unknown; then
11897 ac_cv_c_bigendian=no
11898 else
11899 # finding both strings is unlikely to happen, but who knows?
11900 ac_cv_c_bigendian=unknown
11901 fi
11902 fi
7eb368b3 11903fi
81ecdfbb 11904rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
bec39cab 11905else
81ecdfbb 11906 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 11907/* end confdefs.h. */
81ecdfbb 11908$ac_includes_default
d3ea6809
MM
11909int
11910main ()
11911{
81ecdfbb
RW
11912
11913 /* Are we little or big endian? From Harbison&Steele. */
11914 union
11915 {
11916 long int l;
11917 char c[sizeof (long int)];
11918 } u;
11919 u.l = 1;
11920 return u.c[sizeof (long int) - 1] == 1;
11921
11922 ;
11923 return 0;
d3ea6809
MM
11924}
11925_ACEOF
81ecdfbb 11926if ac_fn_c_try_run "$LINENO"; then :
a9322a30 11927 ac_cv_c_bigendian=no
d3ea6809 11928else
81ecdfbb 11929 ac_cv_c_bigendian=yes
d3ea6809 11930fi
81ecdfbb
RW
11931rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11932 conftest.$ac_objext conftest.beam conftest.$ac_ext
a9322a30 11933fi
a9322a30 11934
81ecdfbb
RW
11935 fi
11936fi
11937{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
11938$as_echo "$ac_cv_c_bigendian" >&6; }
11939 case $ac_cv_c_bigendian in #(
11940 yes)
11941 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
11942;; #(
11943 no)
11944 ;; #(
11945 universal)
11946
11947$as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
11948
11949 ;; #(
11950 *)
11951 as_fn_error "unknown endianness
11952 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
11953 esac
d3ea6809
MM
11954
11955
a9322a30
TT
11956# ------------------------------ #
11957# Checks for library functions. #
11958# ------------------------------ #
d3ea6809 11959
a9322a30
TT
11960# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
11961# for constant arguments. Useless!
81ecdfbb
RW
11962{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
11963$as_echo_n "checking for working alloca.h... " >&6; }
11964if test "${ac_cv_working_alloca_h+set}" = set; then :
11965 $as_echo_n "(cached) " >&6
d3ea6809 11966else
81ecdfbb 11967 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
d3ea6809 11968/* end confdefs.h. */
a9322a30 11969#include <alloca.h>
bec39cab
AC
11970int
11971main ()
11972{
a9322a30 11973char *p = (char *) alloca (2 * sizeof (int));
81ecdfbb 11974 if (p) return 0;
bec39cab
AC
11975 ;
11976 return 0;
11977}
11978_ACEOF
81ecdfbb 11979if ac_fn_c_try_link "$LINENO"; then :
a9322a30 11980 ac_cv_working_alloca_h=yes
bec39cab 11981else
81ecdfbb 11982 ac_cv_working_alloca_h=no
bec39cab 11983fi
81ecdfbb
RW
11984rm -f core conftest.err conftest.$ac_objext \
11985 conftest$ac_exeext conftest.$ac_ext
bec39cab 11986fi
81ecdfbb
RW
11987{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
11988$as_echo "$ac_cv_working_alloca_h" >&6; }
a9322a30
TT
11989if test $ac_cv_working_alloca_h = yes; then
11990
81ecdfbb 11991$as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
c906108c 11992
c906108c 11993fi
bec39cab 11994
81ecdfbb
RW
11995{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
11996$as_echo_n "checking for alloca... " >&6; }
11997if test "${ac_cv_func_alloca_works+set}" = set; then :
11998 $as_echo_n "(cached) " >&6
bec39cab 11999else
81ecdfbb 12000 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 12001/* end confdefs.h. */
a9322a30
TT
12002#ifdef __GNUC__
12003# define alloca __builtin_alloca
b4e70030 12004#else
a9322a30
TT
12005# ifdef _MSC_VER
12006# include <malloc.h>
12007# define alloca _alloca
12008# else
81ecdfbb 12009# ifdef HAVE_ALLOCA_H
a9322a30
TT
12010# include <alloca.h>
12011# else
12012# ifdef _AIX
12013 #pragma alloca
12014# else
12015# ifndef alloca /* predefined by HP cc +Olibcalls */
12016char *alloca ();
12017# endif
12018# endif
12019# endif
12020# endif
c906108c 12021#endif
97bf5e38 12022
bec39cab
AC
12023int
12024main ()
12025{
a9322a30 12026char *p = (char *) alloca (1);
81ecdfbb 12027 if (p) return 0;
bec39cab
AC
12028 ;
12029 return 0;
12030}
12031_ACEOF
81ecdfbb 12032if ac_fn_c_try_link "$LINENO"; then :
a9322a30 12033 ac_cv_func_alloca_works=yes
bec39cab 12034else
81ecdfbb 12035 ac_cv_func_alloca_works=no
bec39cab 12036fi
81ecdfbb
RW
12037rm -f core conftest.err conftest.$ac_objext \
12038 conftest$ac_exeext conftest.$ac_ext
bec39cab 12039fi
81ecdfbb
RW
12040{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
12041$as_echo "$ac_cv_func_alloca_works" >&6; }
a9322a30
TT
12042
12043if test $ac_cv_func_alloca_works = yes; then
12044
81ecdfbb 12045$as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
c906108c 12046
a9322a30
TT
12047else
12048 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
12049# that cause trouble. Some versions do not even contain alloca or
12050# contain a buggy version. If you still want to use their alloca,
12051# use ar to extract alloca.o from them instead of compiling alloca.c.
12052
81ecdfbb 12053ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
a9322a30 12054
81ecdfbb 12055$as_echo "#define C_ALLOCA 1" >>confdefs.h
c906108c 12056
bec39cab 12057
81ecdfbb
RW
12058{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5
12059$as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; }
12060if test "${ac_cv_os_cray+set}" = set; then :
12061 $as_echo_n "(cached) " >&6
a9322a30 12062else
81ecdfbb 12063 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
a9322a30 12064/* end confdefs.h. */
81ecdfbb 12065#if defined CRAY && ! defined CRAY2
a9322a30
TT
12066webecray
12067#else
12068wenotbecray
12069#endif
12070
12071_ACEOF
12072if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
81ecdfbb 12073 $EGREP "webecray" >/dev/null 2>&1; then :
a9322a30
TT
12074 ac_cv_os_cray=yes
12075else
81ecdfbb 12076 ac_cv_os_cray=no
bec39cab 12077fi
81ecdfbb
RW
12078rm -f conftest*
12079
bec39cab 12080fi
81ecdfbb
RW
12081{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
12082$as_echo "$ac_cv_os_cray" >&6; }
12083if test $ac_cv_os_cray = yes; then
12084 for ac_func in _getb67 GETB67 getb67; do
12085 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
12086ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
12087eval as_val=\$$as_ac_var
12088 if test "x$as_val" = x""yes; then :
a9322a30
TT
12089
12090cat >>confdefs.h <<_ACEOF
12091#define CRAY_STACKSEG_END $ac_func
bec39cab 12092_ACEOF
c906108c 12093
a9322a30 12094 break
c906108c
SS
12095fi
12096
a9322a30
TT
12097 done
12098fi
bec39cab 12099
81ecdfbb
RW
12100{ $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
12101$as_echo_n "checking stack direction for C alloca... " >&6; }
12102if test "${ac_cv_c_stack_direction+set}" = set; then :
12103 $as_echo_n "(cached) " >&6
a9322a30 12104else
81ecdfbb 12105 if test "$cross_compiling" = yes; then :
a9322a30 12106 ac_cv_c_stack_direction=0
bec39cab 12107else
81ecdfbb 12108 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 12109/* end confdefs.h. */
81ecdfbb 12110$ac_includes_default
a9322a30
TT
12111int
12112find_stack_direction ()
b4e70030 12113{
a9322a30
TT
12114 static char *addr = 0;
12115 auto char dummy;
12116 if (addr == 0)
12117 {
12118 addr = &dummy;
12119 return find_stack_direction ();
12120 }
12121 else
12122 return (&dummy > addr) ? 1 : -1;
b4e70030 12123}
b757528f 12124
bec39cab
AC
12125int
12126main ()
12127{
81ecdfbb 12128 return find_stack_direction () < 0;
bec39cab
AC
12129}
12130_ACEOF
81ecdfbb 12131if ac_fn_c_try_run "$LINENO"; then :
a9322a30
TT
12132 ac_cv_c_stack_direction=1
12133else
81ecdfbb 12134 ac_cv_c_stack_direction=-1
a9322a30 12135fi
81ecdfbb
RW
12136rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12137 conftest.$ac_objext conftest.beam conftest.$ac_ext
a9322a30 12138fi
a9322a30 12139
81ecdfbb
RW
12140fi
12141{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
12142$as_echo "$ac_cv_c_stack_direction" >&6; }
a9322a30
TT
12143cat >>confdefs.h <<_ACEOF
12144#define STACK_DIRECTION $ac_cv_c_stack_direction
12145_ACEOF
12146
12147
12148fi
12149
a9322a30 12150for ac_header in stdlib.h unistd.h
81ecdfbb
RW
12151do :
12152 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12153ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
12154eval as_val=\$$as_ac_Header
12155 if test "x$as_val" = x""yes; then :
bec39cab 12156 cat >>confdefs.h <<_ACEOF
81ecdfbb 12157#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
bec39cab 12158_ACEOF
b757528f 12159
b757528f 12160fi
bec39cab 12161
a9322a30 12162done
a3828db0 12163
a9322a30 12164for ac_func in getpagesize
81ecdfbb
RW
12165do :
12166 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
12167if test "x$ac_cv_func_getpagesize" = x""yes; then :
bec39cab 12168 cat >>confdefs.h <<_ACEOF
81ecdfbb 12169#define HAVE_GETPAGESIZE 1
bec39cab 12170_ACEOF
bcb3dc3d 12171
bcb3dc3d
MK
12172fi
12173done
12174
81ecdfbb
RW
12175{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
12176$as_echo_n "checking for working mmap... " >&6; }
12177if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then :
12178 $as_echo_n "(cached) " >&6
a9322a30 12179else
81ecdfbb 12180 if test "$cross_compiling" = yes; then :
a9322a30 12181 ac_cv_func_mmap_fixed_mapped=no
bec39cab 12182else
81ecdfbb 12183 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 12184/* end confdefs.h. */
a9322a30
TT
12185$ac_includes_default
12186/* malloc might have been renamed as rpl_malloc. */
12187#undef malloc
bec39cab 12188
a9322a30
TT
12189/* Thanks to Mike Haertel and Jim Avera for this test.
12190 Here is a matrix of mmap possibilities:
12191 mmap private not fixed
12192 mmap private fixed at somewhere currently unmapped
12193 mmap private fixed at somewhere already mapped
12194 mmap shared not fixed
12195 mmap shared fixed at somewhere currently unmapped
12196 mmap shared fixed at somewhere already mapped
12197 For private mappings, we should verify that changes cannot be read()
12198 back from the file, nor mmap's back from the file at a different
12199 address. (There have been systems where private was not correctly
12200 implemented like the infamous i386 svr4.0, and systems where the
12201 VM page cache was not coherent with the file system buffer cache
12202 like early versions of FreeBSD and possibly contemporary NetBSD.)
12203 For shared mappings, we should conversely verify that changes get
12204 propagated back to all the places they're supposed to be.
bec39cab 12205
a9322a30
TT
12206 Grep wants private fixed already mapped.
12207 The main things grep needs to know about mmap are:
12208 * does it exist and is it safe to write into the mmap'd area
12209 * how to use it (BSD variants) */
8b9cf735 12210
a9322a30
TT
12211#include <fcntl.h>
12212#include <sys/mman.h>
8b9cf735 12213
81ecdfbb 12214#if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
a9322a30 12215char *malloc ();
a3828db0
MK
12216#endif
12217
a9322a30 12218/* This mess was copied from the GNU getpagesize.h. */
81ecdfbb 12219#ifndef HAVE_GETPAGESIZE
a9322a30 12220/* Assume that all systems that can run configure have sys/param.h. */
81ecdfbb 12221# ifndef HAVE_SYS_PARAM_H
a9322a30
TT
12222# define HAVE_SYS_PARAM_H 1
12223# endif
12224
12225# ifdef _SC_PAGESIZE
12226# define getpagesize() sysconf(_SC_PAGESIZE)
12227# else /* no _SC_PAGESIZE */
81ecdfbb 12228# ifdef HAVE_SYS_PARAM_H
a9322a30
TT
12229# include <sys/param.h>
12230# ifdef EXEC_PAGESIZE
12231# define getpagesize() EXEC_PAGESIZE
12232# else /* no EXEC_PAGESIZE */
12233# ifdef NBPG
12234# define getpagesize() NBPG * CLSIZE
12235# ifndef CLSIZE
12236# define CLSIZE 1
12237# endif /* no CLSIZE */
12238# else /* no NBPG */
12239# ifdef NBPC
12240# define getpagesize() NBPC
12241# else /* no NBPC */
12242# ifdef PAGESIZE
12243# define getpagesize() PAGESIZE
12244# endif /* PAGESIZE */
12245# endif /* no NBPC */
12246# endif /* no NBPG */
12247# endif /* no EXEC_PAGESIZE */
12248# else /* no HAVE_SYS_PARAM_H */
12249# define getpagesize() 8192 /* punt totally */
12250# endif /* no HAVE_SYS_PARAM_H */
12251# endif /* no _SC_PAGESIZE */
12252
12253#endif /* no HAVE_GETPAGESIZE */
12254
bec39cab
AC
12255int
12256main ()
12257{
a9322a30
TT
12258 char *data, *data2, *data3;
12259 int i, pagesize;
12260 int fd;
12261
12262 pagesize = getpagesize ();
12263
12264 /* First, make a file with some known garbage in it. */
12265 data = (char *) malloc (pagesize);
12266 if (!data)
81ecdfbb 12267 return 1;
a9322a30
TT
12268 for (i = 0; i < pagesize; ++i)
12269 *(data + i) = rand ();
12270 umask (0);
12271 fd = creat ("conftest.mmap", 0600);
12272 if (fd < 0)
81ecdfbb 12273 return 1;
a9322a30 12274 if (write (fd, data, pagesize) != pagesize)
81ecdfbb 12275 return 1;
a9322a30
TT
12276 close (fd);
12277
12278 /* Next, try to mmap the file at a fixed address which already has
12279 something else allocated at it. If we can, also make sure that
12280 we see the same garbage. */
12281 fd = open ("conftest.mmap", O_RDWR);
12282 if (fd < 0)
81ecdfbb 12283 return 1;
a9322a30
TT
12284 data2 = (char *) malloc (2 * pagesize);
12285 if (!data2)
81ecdfbb
RW
12286 return 1;
12287 data2 += (pagesize - ((long int) data2 & (pagesize - 1))) & (pagesize - 1);
a9322a30
TT
12288 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
12289 MAP_PRIVATE | MAP_FIXED, fd, 0L))
81ecdfbb 12290 return 1;
a9322a30
TT
12291 for (i = 0; i < pagesize; ++i)
12292 if (*(data + i) != *(data2 + i))
81ecdfbb 12293 return 1;
a9322a30
TT
12294
12295 /* Finally, make sure that changes to the mapped area do not
12296 percolate back to the file as seen by read(). (This is a bug on
12297 some variants of i386 svr4.0.) */
12298 for (i = 0; i < pagesize; ++i)
12299 *(data2 + i) = *(data2 + i) + 1;
12300 data3 = (char *) malloc (pagesize);
12301 if (!data3)
81ecdfbb 12302 return 1;
a9322a30 12303 if (read (fd, data3, pagesize) != pagesize)
81ecdfbb 12304 return 1;
a9322a30
TT
12305 for (i = 0; i < pagesize; ++i)
12306 if (*(data + i) != *(data3 + i))
81ecdfbb 12307 return 1;
a9322a30 12308 close (fd);
81ecdfbb 12309 return 0;
bec39cab
AC
12310}
12311_ACEOF
81ecdfbb 12312if ac_fn_c_try_run "$LINENO"; then :
a9322a30 12313 ac_cv_func_mmap_fixed_mapped=yes
086ec9eb 12314else
81ecdfbb 12315 ac_cv_func_mmap_fixed_mapped=no
a3828db0 12316fi
81ecdfbb
RW
12317rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12318 conftest.$ac_objext conftest.beam conftest.$ac_ext
a3828db0 12319fi
81ecdfbb 12320
a9322a30 12321fi
81ecdfbb
RW
12322{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
12323$as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
a9322a30
TT
12324if test $ac_cv_func_mmap_fixed_mapped = yes; then
12325
81ecdfbb 12326$as_echo "#define HAVE_MMAP 1" >>confdefs.h
a3828db0 12327
086ec9eb 12328fi
a9322a30 12329rm -f conftest.mmap
a3828db0 12330
81ecdfbb
RW
12331ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
12332if test "x$ac_cv_type_pid_t" = x""yes; then :
bec39cab 12333
a9322a30
TT
12334else
12335
12336cat >>confdefs.h <<_ACEOF
12337#define pid_t int
bec39cab 12338_ACEOF
086ec9eb
MK
12339
12340fi
12341
81ecdfbb
RW
12342for ac_header in vfork.h
12343do :
12344 ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
12345if test "x$ac_cv_header_vfork_h" = x""yes; then :
a3828db0 12346 cat >>confdefs.h <<_ACEOF
81ecdfbb 12347#define HAVE_VFORK_H 1
bec39cab 12348_ACEOF
c906108c
SS
12349
12350fi
a9322a30 12351
a3828db0 12352done
c906108c 12353
a9322a30 12354for ac_func in fork vfork
81ecdfbb
RW
12355do :
12356 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
12357ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
12358eval as_val=\$$as_ac_var
12359 if test "x$as_val" = x""yes; then :
a3828db0 12360 cat >>confdefs.h <<_ACEOF
81ecdfbb 12361#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
bec39cab 12362_ACEOF
b83266a0 12363
97bf5e38 12364fi
a3828db0 12365done
b83266a0 12366
a9322a30 12367if test "x$ac_cv_func_fork" = xyes; then
81ecdfbb
RW
12368 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
12369$as_echo_n "checking for working fork... " >&6; }
12370if test "${ac_cv_func_fork_works+set}" = set; then :
12371 $as_echo_n "(cached) " >&6
a9322a30 12372else
81ecdfbb 12373 if test "$cross_compiling" = yes; then :
a9322a30
TT
12374 ac_cv_func_fork_works=cross
12375else
81ecdfbb
RW
12376 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12377/* end confdefs.h. */
12378$ac_includes_default
12379int
12380main ()
12381{
12382
12383 /* By Ruediger Kuhlmann. */
12384 return fork () < 0;
12385
12386 ;
12387 return 0;
12388}
a9322a30 12389_ACEOF
81ecdfbb 12390if ac_fn_c_try_run "$LINENO"; then :
a9322a30
TT
12391 ac_cv_func_fork_works=yes
12392else
81ecdfbb 12393 ac_cv_func_fork_works=no
a9322a30 12394fi
81ecdfbb
RW
12395rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12396 conftest.$ac_objext conftest.beam conftest.$ac_ext
a9322a30 12397fi
81ecdfbb 12398
a9322a30 12399fi
81ecdfbb
RW
12400{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
12401$as_echo "$ac_cv_func_fork_works" >&6; }
a9322a30
TT
12402
12403else
12404 ac_cv_func_fork_works=$ac_cv_func_fork
12405fi
12406if test "x$ac_cv_func_fork_works" = xcross; then
12407 case $host in
12408 *-*-amigaos* | *-*-msdosdjgpp*)
12409 # Override, as these systems have only a dummy fork() stub
12410 ac_cv_func_fork_works=no
12411 ;;
12412 *)
12413 ac_cv_func_fork_works=yes
12414 ;;
12415 esac
81ecdfbb
RW
12416 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
12417$as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
a9322a30
TT
12418fi
12419ac_cv_func_vfork_works=$ac_cv_func_vfork
12420if test "x$ac_cv_func_vfork" = xyes; then
81ecdfbb
RW
12421 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
12422$as_echo_n "checking for working vfork... " >&6; }
12423if test "${ac_cv_func_vfork_works+set}" = set; then :
12424 $as_echo_n "(cached) " >&6
a9322a30 12425else
81ecdfbb 12426 if test "$cross_compiling" = yes; then :
a9322a30
TT
12427 ac_cv_func_vfork_works=cross
12428else
81ecdfbb 12429 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
a9322a30
TT
12430/* end confdefs.h. */
12431/* Thanks to Paul Eggert for this test. */
81ecdfbb 12432$ac_includes_default
a9322a30 12433#include <sys/wait.h>
81ecdfbb 12434#ifdef HAVE_VFORK_H
a9322a30
TT
12435# include <vfork.h>
12436#endif
12437/* On some sparc systems, changes by the child to local and incoming
12438 argument registers are propagated back to the parent. The compiler
12439 is told about this with #include <vfork.h>, but some compilers
12440 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
12441 static variable whose address is put into a register that is
12442 clobbered by the vfork. */
12443static void
12444#ifdef __cplusplus
12445sparc_address_test (int arg)
12446# else
12447sparc_address_test (arg) int arg;
12448#endif
12449{
12450 static pid_t child;
12451 if (!child) {
12452 child = vfork ();
12453 if (child < 0) {
12454 perror ("vfork");
12455 _exit(2);
12456 }
12457 if (!child) {
12458 arg = getpid();
12459 write(-1, "", 0);
12460 _exit (arg);
12461 }
12462 }
12463}
12464
12465int
12466main ()
12467{
12468 pid_t parent = getpid ();
12469 pid_t child;
12470
12471 sparc_address_test (0);
12472
12473 child = vfork ();
12474
12475 if (child == 0) {
12476 /* Here is another test for sparc vfork register problems. This
12477 test uses lots of local variables, at least as many local
12478 variables as main has allocated so far including compiler
12479 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
12480 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
12481 reuse the register of parent for one of the local variables,
12482 since it will think that parent can't possibly be used any more
12483 in this routine. Assigning to the local variable will thus
12484 munge parent in the parent process. */
12485 pid_t
12486 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
12487 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
12488 /* Convince the compiler that p..p7 are live; otherwise, it might
12489 use the same hardware register for all 8 local variables. */
12490 if (p != p1 || p != p2 || p != p3 || p != p4
12491 || p != p5 || p != p6 || p != p7)
12492 _exit(1);
12493
12494 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
12495 from child file descriptors. If the child closes a descriptor
12496 before it execs or exits, this munges the parent's descriptor
12497 as well. Test for this by closing stdout in the child. */
12498 _exit(close(fileno(stdout)) != 0);
12499 } else {
12500 int status;
12501 struct stat st;
12502
12503 while (wait(&status) != child)
12504 ;
81ecdfbb 12505 return (
a9322a30
TT
12506 /* Was there some problem with vforking? */
12507 child < 0
12508
12509 /* Did the child fail? (This shouldn't happen.) */
12510 || status
12511
12512 /* Did the vfork/compiler bug occur? */
12513 || parent != getpid()
12514
12515 /* Did the file descriptor bug occur? */
12516 || fstat(fileno(stdout), &st) != 0
12517 );
12518 }
12519}
12520_ACEOF
81ecdfbb 12521if ac_fn_c_try_run "$LINENO"; then :
a9322a30
TT
12522 ac_cv_func_vfork_works=yes
12523else
81ecdfbb 12524 ac_cv_func_vfork_works=no
a9322a30 12525fi
81ecdfbb
RW
12526rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12527 conftest.$ac_objext conftest.beam conftest.$ac_ext
a9322a30 12528fi
81ecdfbb 12529
a9322a30 12530fi
81ecdfbb
RW
12531{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
12532$as_echo "$ac_cv_func_vfork_works" >&6; }
a9322a30
TT
12533
12534fi;
12535if test "x$ac_cv_func_fork_works" = xcross; then
12536 ac_cv_func_vfork_works=$ac_cv_func_vfork
81ecdfbb
RW
12537 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
12538$as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
a9322a30
TT
12539fi
12540
12541if test "x$ac_cv_func_vfork_works" = xyes; then
12542
81ecdfbb 12543$as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
a9322a30
TT
12544
12545else
12546
81ecdfbb 12547$as_echo "#define vfork fork" >>confdefs.h
a9322a30
TT
12548
12549fi
12550if test "x$ac_cv_func_fork_works" = xyes; then
12551
81ecdfbb 12552$as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
a9322a30
TT
12553
12554fi
12555
a9322a30 12556for ac_func in canonicalize_file_name realpath getrusage getuid \
db5e03ae 12557 getgid pipe poll pread64 resize_term sbrk setpgid setpgrp setsid \
a9322a30 12558 sigaction sigprocmask sigsetmask socketpair syscall \
110ed339 12559 ttrace wborder wresize setlocale iconvlist libiconvlist btowc \
0a4f61e3 12560 setrlimit getrlimit posix_madvise waitpid
81ecdfbb
RW
12561do :
12562 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
12563ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
12564eval as_val=\$$as_ac_var
12565 if test "x$as_val" = x""yes; then :
6c7a06a3 12566 cat >>confdefs.h <<_ACEOF
81ecdfbb 12567#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
6c7a06a3
TT
12568_ACEOF
12569
12570fi
12571done
12572
12573
81ecdfbb
RW
12574 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
12575$as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
12576if test "${am_cv_langinfo_codeset+set}" = set; then :
12577 $as_echo_n "(cached) " >&6
6c7a06a3 12578else
81ecdfbb 12579 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6c7a06a3
TT
12580/* end confdefs.h. */
12581#include <langinfo.h>
12582int
12583main ()
12584{
12585char* cs = nl_langinfo(CODESET);
bec39cab
AC
12586 ;
12587 return 0;
12588}
12589_ACEOF
81ecdfbb 12590if ac_fn_c_try_link "$LINENO"; then :
6c7a06a3 12591 am_cv_langinfo_codeset=yes
a4db0f07 12592else
81ecdfbb 12593 am_cv_langinfo_codeset=no
a4db0f07 12594fi
81ecdfbb
RW
12595rm -f core conftest.err conftest.$ac_objext \
12596 conftest$ac_exeext conftest.$ac_ext
6c7a06a3 12597
a4db0f07 12598fi
81ecdfbb
RW
12599{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_langinfo_codeset" >&5
12600$as_echo "$am_cv_langinfo_codeset" >&6; }
6c7a06a3
TT
12601 if test $am_cv_langinfo_codeset = yes; then
12602
81ecdfbb 12603$as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
a4db0f07 12604
6c7a06a3 12605 fi
c906108c 12606
06825bd1 12607
a3828db0
MK
12608# Check the return and argument types of ptrace. No canned test for
12609# this, so roll our own.
12610gdb_ptrace_headers='
12611#if HAVE_SYS_TYPES_H
12612# include <sys/types.h>
12613#endif
12614#if HAVE_SYS_PTRACE_H
12615# include <sys/ptrace.h>
12616#endif
12617#if HAVE_UNISTD_H
12618# include <unistd.h>
12619#endif
12620'
12621# There is no point in checking if we don't have a prototype.
81ecdfbb
RW
12622ac_fn_c_check_decl "$LINENO" "ptrace" "ac_cv_have_decl_ptrace" "$gdb_ptrace_headers
12623"
12624if test "x$ac_cv_have_decl_ptrace" = x""yes; then :
12625 ac_have_decl=1
06825bd1 12626else
81ecdfbb 12627 ac_have_decl=0
06825bd1 12628fi
06825bd1 12629
a3828db0 12630cat >>confdefs.h <<_ACEOF
81ecdfbb 12631#define HAVE_DECL_PTRACE $ac_have_decl
a3828db0 12632_ACEOF
81ecdfbb 12633if test $ac_have_decl = 1; then :
bec39cab 12634
a3828db0 12635else
a3828db0
MK
12636
12637 : ${gdb_cv_func_ptrace_ret='int'}
12638 : ${gdb_cv_func_ptrace_args='int,int,long,long'}
12639
06825bd1
MK
12640fi
12641
064ef605
DJ
12642# Check return type. Varargs (used on GNU/Linux) conflict with the
12643# empty argument list, so check for that explicitly.
81ecdfbb
RW
12644{ $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of ptrace" >&5
12645$as_echo_n "checking return type of ptrace... " >&6; }
12646if test "${gdb_cv_func_ptrace_ret+set}" = set; then :
12647 $as_echo_n "(cached) " >&6
bec39cab 12648else
81ecdfbb 12649 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 12650/* end confdefs.h. */
a3828db0 12651$gdb_ptrace_headers
bec39cab
AC
12652int
12653main ()
12654{
064ef605
DJ
12655extern long ptrace (enum __ptrace_request, ...);
12656 ;
12657 return 0;
12658}
12659_ACEOF
81ecdfbb 12660if ac_fn_c_try_compile "$LINENO"; then :
064ef605
DJ
12661 gdb_cv_func_ptrace_ret='long'
12662else
81ecdfbb 12663 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
064ef605
DJ
12664/* end confdefs.h. */
12665$gdb_ptrace_headers
12666int
12667main ()
12668{
a3828db0 12669extern int ptrace ();
bec39cab
AC
12670 ;
12671 return 0;
12672}
12673_ACEOF
81ecdfbb 12674if ac_fn_c_try_compile "$LINENO"; then :
a3828db0 12675 gdb_cv_func_ptrace_ret='int'
70f9f479 12676else
81ecdfbb 12677 gdb_cv_func_ptrace_ret='long'
70f9f479 12678fi
81ecdfbb 12679rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
70f9f479 12680fi
81ecdfbb 12681rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
064ef605 12682fi
81ecdfbb
RW
12683{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_func_ptrace_ret" >&5
12684$as_echo "$gdb_cv_func_ptrace_ret" >&6; }
bec39cab 12685
a3828db0
MK
12686cat >>confdefs.h <<_ACEOF
12687#define PTRACE_TYPE_RET $gdb_cv_func_ptrace_ret
bec39cab 12688_ACEOF
70f9f479 12689
a3828db0 12690# Check argument types.
81ecdfbb
RW
12691{ $as_echo "$as_me:${as_lineno-$LINENO}: checking types of arguments for ptrace" >&5
12692$as_echo_n "checking types of arguments for ptrace... " >&6; }
12693if test "${gdb_cv_func_ptrace_args+set}" = set; then :
12694 $as_echo_n "(cached) " >&6
bec39cab 12695else
a3828db0 12696
81ecdfbb 12697 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
064ef605
DJ
12698/* end confdefs.h. */
12699$gdb_ptrace_headers
12700int
12701main ()
12702{
12703extern long ptrace (enum __ptrace_request, ...);
12704 ;
12705 return 0;
12706}
12707_ACEOF
81ecdfbb 12708if ac_fn_c_try_compile "$LINENO"; then :
064ef605
DJ
12709 gdb_cv_func_ptrace_args='int,int,long,long'
12710else
064ef605 12711
a3828db0
MK
12712for gdb_arg1 in 'int' 'long'; do
12713 for gdb_arg2 in 'pid_t' 'int' 'long'; do
5ed10e6e 12714 for gdb_arg3 in 'int *' 'caddr_t' 'int' 'long' 'void *'; do
a3828db0 12715 for gdb_arg4 in 'int' 'long'; do
81ecdfbb 12716 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 12717/* end confdefs.h. */
a3828db0 12718$gdb_ptrace_headers
bec39cab
AC
12719int
12720main ()
12721{
a3828db0
MK
12722
12723extern $gdb_cv_func_ptrace_ret
12724 ptrace ($gdb_arg1, $gdb_arg2, $gdb_arg3, $gdb_arg4);
12725
bec39cab
AC
12726 ;
12727 return 0;
12728}
12729_ACEOF
81ecdfbb 12730if ac_fn_c_try_compile "$LINENO"; then :
a3828db0
MK
12731 gdb_cv_func_ptrace_args="$gdb_arg1,$gdb_arg2,$gdb_arg3,$gdb_arg4";
12732 break 4;
5c7f2947 12733fi
81ecdfbb 12734rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
a3828db0 12735 for gdb_arg5 in 'int *' 'int' 'long'; do
81ecdfbb 12736 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 12737/* end confdefs.h. */
a3828db0 12738$gdb_ptrace_headers
bec39cab
AC
12739int
12740main ()
12741{
a3828db0
MK
12742
12743extern $gdb_cv_func_ptrace_ret
12744 ptrace ($gdb_arg1, $gdb_arg2, $gdb_arg3, $gdb_arg4, $gdb_arg5);
12745
bec39cab
AC
12746 ;
12747 return 0;
12748}
12749_ACEOF
81ecdfbb 12750if ac_fn_c_try_compile "$LINENO"; then :
a3828db0
MK
12751
12752gdb_cv_func_ptrace_args="$gdb_arg1,$gdb_arg2,$gdb_arg3,$gdb_arg4,$gdb_arg5";
12753 break 5;
78434e59 12754fi
81ecdfbb 12755rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
a3828db0
MK
12756 done
12757 done
12758 done
12759 done
12760done
12761# Provide a safe default value.
12762: ${gdb_cv_func_ptrace_args='int,int,long,long'}
12763
064ef605 12764fi
81ecdfbb 12765rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
78434e59 12766fi
81ecdfbb
RW
12767{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_func_ptrace_args" >&5
12768$as_echo "$gdb_cv_func_ptrace_args" >&6; }
a3828db0
MK
12769ac_save_IFS=$IFS; IFS=','
12770set dummy `echo "$gdb_cv_func_ptrace_args" | sed 's/\*/\*/g'`
12771IFS=$ac_save_IFS
12772shift
bec39cab 12773
a3828db0
MK
12774cat >>confdefs.h <<_ACEOF
12775#define PTRACE_TYPE_ARG3 $3
12776_ACEOF
12777
12778if test -n "$5"; then
12779
12780cat >>confdefs.h <<_ACEOF
12781#define PTRACE_TYPE_ARG5 $5
bec39cab 12782_ACEOF
78434e59
MK
12783
12784fi
12785
a3828db0 12786if test "$cross_compiling" = no; then
81ecdfbb
RW
12787 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether setpgrp takes no argument" >&5
12788$as_echo_n "checking whether setpgrp takes no argument... " >&6; }
12789if test "${ac_cv_func_setpgrp_void+set}" = set; then :
12790 $as_echo_n "(cached) " >&6
a3828db0 12791else
81ecdfbb
RW
12792 if test "$cross_compiling" = yes; then :
12793 as_fn_error "cannot check setpgrp when cross compiling" "$LINENO" 5
bec39cab 12794else
81ecdfbb 12795 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 12796/* end confdefs.h. */
81ecdfbb 12797$ac_includes_default
bec39cab
AC
12798int
12799main ()
12800{
a3828db0
MK
12801/* If this system has a BSD-style setpgrp which takes arguments,
12802 setpgrp(1, 1) will fail with ESRCH and return -1, in that case
12803 exit successfully. */
81ecdfbb 12804 return setpgrp (1,1) != -1;
bec39cab
AC
12805 ;
12806 return 0;
12807}
12808_ACEOF
81ecdfbb 12809if ac_fn_c_try_run "$LINENO"; then :
a3828db0 12810 ac_cv_func_setpgrp_void=no
c906108c 12811else
81ecdfbb 12812 ac_cv_func_setpgrp_void=yes
c906108c 12813fi
81ecdfbb
RW
12814rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12815 conftest.$ac_objext conftest.beam conftest.$ac_ext
97bf5e38 12816fi
81ecdfbb 12817
a3828db0 12818fi
81ecdfbb
RW
12819{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_setpgrp_void" >&5
12820$as_echo "$ac_cv_func_setpgrp_void" >&6; }
a3828db0
MK
12821if test $ac_cv_func_setpgrp_void = yes; then
12822
81ecdfbb 12823$as_echo "#define SETPGRP_VOID 1" >>confdefs.h
97bf5e38
MK
12824
12825fi
a3828db0
MK
12826
12827else
81ecdfbb
RW
12828 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether setpgrp takes no argument" >&5
12829$as_echo_n "checking whether setpgrp takes no argument... " >&6; }
12830if test "${ac_cv_func_setpgrp_void+set}" = set; then :
12831 $as_echo_n "(cached) " >&6
97bf5e38 12832else
81ecdfbb 12833 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 12834/* end confdefs.h. */
a3828db0
MK
12835
12836#include <unistd.h>
12837
bec39cab
AC
12838int
12839main ()
12840{
a3828db0
MK
12841
12842 if (setpgrp(1,1) == -1)
12843 exit (0);
12844 else
12845 exit (1);
12846
bec39cab
AC
12847 ;
12848 return 0;
12849}
12850_ACEOF
81ecdfbb 12851if ac_fn_c_try_compile "$LINENO"; then :
a3828db0 12852 ac_cv_func_setpgrp_void=no
c906108c 12853else
81ecdfbb 12854 ac_cv_func_setpgrp_void=yes
c906108c 12855fi
81ecdfbb 12856rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
c906108c 12857fi
81ecdfbb
RW
12858{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_setpgrp_void" >&5
12859$as_echo "$ac_cv_func_setpgrp_void" >&6; }
a3828db0 12860if test $ac_cv_func_setpgrp_void = yes; then
81ecdfbb 12861 $as_echo "#define SETPGRP_VOID 1" >>confdefs.h
c3f6f71d 12862
a3828db0 12863fi
c906108c
SS
12864fi
12865
a3828db0
MK
12866# Check if sigsetjmp is available. Using AC_CHECK_FUNCS won't do
12867# since sigsetjmp might only be defined as a macro.
81ecdfbb
RW
12868{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigsetjmp" >&5
12869$as_echo_n "checking for sigsetjmp... " >&6; }
12870if test "${gdb_cv_func_sigsetjmp+set}" = set; then :
12871 $as_echo_n "(cached) " >&6
bec39cab 12872else
81ecdfbb 12873 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 12874/* end confdefs.h. */
a3828db0
MK
12875
12876#include <setjmp.h>
12877
bec39cab
AC
12878int
12879main ()
12880{
a3828db0 12881sigjmp_buf env; while (! sigsetjmp (env, 1)) siglongjmp (env, 1);
bec39cab
AC
12882 ;
12883 return 0;
12884}
12885_ACEOF
81ecdfbb 12886if ac_fn_c_try_compile "$LINENO"; then :
a3828db0 12887 gdb_cv_func_sigsetjmp=yes
c906108c 12888else
81ecdfbb 12889 gdb_cv_func_sigsetjmp=no
c906108c 12890fi
81ecdfbb 12891rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
c906108c 12892fi
81ecdfbb
RW
12893{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_func_sigsetjmp" >&5
12894$as_echo "$gdb_cv_func_sigsetjmp" >&6; }
a3828db0 12895if test $gdb_cv_func_sigsetjmp = yes; then
c906108c 12896
81ecdfbb 12897$as_echo "#define HAVE_SIGSETJMP 1" >>confdefs.h
c906108c 12898
97bf5e38 12899fi
c906108c 12900
a3828db0
MK
12901# Assume we'll default to using the included libiberty regex.
12902gdb_use_included_regex=yes
12903
12904# However, if the system regex is GNU regex, then default to *not*
12905# using the included regex.
81ecdfbb
RW
12906{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU regex" >&5
12907$as_echo_n "checking for GNU regex... " >&6; }
12908if test "${gdb_cv_have_gnu_regex+set}" = set; then :
12909 $as_echo_n "(cached) " >&6
bec39cab 12910else
81ecdfbb 12911 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 12912/* end confdefs.h. */
a3828db0 12913#include <gnu-versions.h>
bec39cab
AC
12914int
12915main ()
12916{
81ecdfbb
RW
12917#define REGEX_INTERFACE_VERSION 1
12918#if _GNU_REGEX_INTERFACE_VERSION != REGEX_INTERFACE_VERSION
12919# error "Version mismatch"
12920#endif
5c45e068
MK
12921 ;
12922 return 0;
12923}
12924_ACEOF
81ecdfbb
RW
12925if ac_fn_c_try_compile "$LINENO"; then :
12926 gdb_cv_have_gnu_regex=yes
5c45e068 12927else
81ecdfbb
RW
12928 gdb_cv_have_gnu_regex=no
12929fi
12930rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12931fi
12932{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_gnu_regex" >&5
12933$as_echo "$gdb_cv_have_gnu_regex" >&6; }
12934if test $gdb_cv_have_gnu_regex = yes; then
12935 gdb_use_included_regex=no
5c45e068 12936fi
81ecdfbb
RW
12937
12938
12939# Check whether --with-included-regex was given.
12940if test "${with_included_regex+set}" = set; then :
12941 withval=$with_included_regex; gdb_with_regex=$withval
12942else
12943 gdb_with_regex=$gdb_use_included_regex
c906108c 12944fi
81ecdfbb
RW
12945
12946if test "$gdb_with_regex" = yes; then
12947
12948$as_echo "#define USE_INCLUDED_REGEX 1" >>confdefs.h
12949
c906108c 12950fi
81ecdfbb
RW
12951
12952# Check if <sys/proc.h> defines `struct thread' with a td_pcb member.
12953ac_fn_c_check_member "$LINENO" "struct thread" "td_pcb" "ac_cv_member_struct_thread_td_pcb" "#include <sys/param.h>
12954#include <sys/proc.h>
12955
12956"
12957if test "x$ac_cv_member_struct_thread_td_pcb" = x""yes; then :
c906108c 12958
5c45e068 12959cat >>confdefs.h <<_ACEOF
a3828db0 12960#define HAVE_STRUCT_THREAD_TD_PCB 1
bec39cab 12961_ACEOF
c906108c 12962
5c45e068 12963
97bf5e38 12964fi
c906108c 12965
5c45e068 12966
a3828db0 12967# See if <sys/lwp.h> defines `struct lwp`.
81ecdfbb
RW
12968{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct lwp" >&5
12969$as_echo_n "checking for struct lwp... " >&6; }
12970if test "${gdb_cv_struct_lwp+set}" = set; then :
12971 $as_echo_n "(cached) " >&6
bec39cab 12972else
81ecdfbb 12973 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 12974/* end confdefs.h. */
a3828db0
MK
12975#include <sys/param.h>
12976#include <sys/lwp.h>
bec39cab
AC
12977int
12978main ()
12979{
a3828db0 12980struct lwp l;
bec39cab
AC
12981 ;
12982 return 0;
12983}
12984_ACEOF
81ecdfbb 12985if ac_fn_c_try_compile "$LINENO"; then :
a3828db0 12986 gdb_cv_struct_lwp=yes
c906108c 12987else
81ecdfbb 12988 gdb_cv_struct_lwp=no
c906108c 12989fi
81ecdfbb 12990rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
c906108c 12991fi
81ecdfbb
RW
12992{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_struct_lwp" >&5
12993$as_echo "$gdb_cv_struct_lwp" >&6; }
a3828db0 12994if test $gdb_cv_struct_lwp = yes; then
c906108c 12995
81ecdfbb 12996$as_echo "#define HAVE_STRUCT_LWP 1" >>confdefs.h
c906108c 12997
97bf5e38 12998fi
c906108c 12999
a3828db0 13000# See if <machine/reg.h> degines `struct reg'.
81ecdfbb
RW
13001{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct reg in machine/reg.h" >&5
13002$as_echo_n "checking for struct reg in machine/reg.h... " >&6; }
13003if test "${gdb_cv_struct_reg+set}" = set; then :
13004 $as_echo_n "(cached) " >&6
bec39cab 13005else
81ecdfbb 13006 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 13007/* end confdefs.h. */
a3828db0
MK
13008#include <sys/types.h>
13009#include <machine/reg.h>
bec39cab
AC
13010int
13011main ()
13012{
a3828db0 13013struct reg r;
bec39cab
AC
13014 ;
13015 return 0;
13016}
13017_ACEOF
81ecdfbb 13018if ac_fn_c_try_compile "$LINENO"; then :
a3828db0 13019 gdb_cv_struct_reg=yes
27ca5dad 13020else
81ecdfbb 13021 gdb_cv_struct_reg=no
27ca5dad 13022fi
81ecdfbb 13023rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27ca5dad 13024fi
81ecdfbb
RW
13025{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_struct_reg" >&5
13026$as_echo "$gdb_cv_struct_reg" >&6; }
a3828db0 13027if test $gdb_cv_struct_reg = yes; then
bec39cab 13028
81ecdfbb 13029$as_echo "#define HAVE_STRUCT_REG 1" >>confdefs.h
27ca5dad
MC
13030
13031fi
97bf5e38 13032
a3828db0
MK
13033# See if <machine/reg.h> supports the %fs and %gs i386 segment registers.
13034# Older i386 BSD's don't have the r_fs and r_gs members of `struct reg'.
81ecdfbb
RW
13035ac_fn_c_check_member "$LINENO" "struct reg" "r_fs" "ac_cv_member_struct_reg_r_fs" "#include <machine/reg.h>
13036"
13037if test "x$ac_cv_member_struct_reg_r_fs" = x""yes; then :
5c45e068
MK
13038
13039cat >>confdefs.h <<_ACEOF
a3828db0 13040#define HAVE_STRUCT_REG_R_FS 1
bec39cab 13041_ACEOF
3862412b 13042
5c45e068 13043
97bf5e38 13044fi
81ecdfbb
RW
13045ac_fn_c_check_member "$LINENO" "struct reg" "r_gs" "ac_cv_member_struct_reg_r_gs" "#include <machine/reg.h>
13046"
13047if test "x$ac_cv_member_struct_reg_r_gs" = x""yes; then :
5c45e068
MK
13048
13049cat >>confdefs.h <<_ACEOF
a3828db0 13050#define HAVE_STRUCT_REG_R_GS 1
bec39cab 13051_ACEOF
3862412b 13052
5c45e068 13053
97bf5e38 13054fi
3862412b 13055
5c45e068 13056
a3828db0 13057# See if <sys/ptrace.h> provides the PTRACE_GETREGS request.
81ecdfbb
RW
13058{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTRACE_GETREGS" >&5
13059$as_echo_n "checking for PTRACE_GETREGS... " >&6; }
13060if test "${gdb_cv_have_ptrace_getregs+set}" = set; then :
13061 $as_echo_n "(cached) " >&6
451928c5 13062else
81ecdfbb 13063 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 13064/* end confdefs.h. */
a3828db0 13065#include <sys/ptrace.h>
bec39cab
AC
13066int
13067main ()
13068{
a3828db0 13069PTRACE_GETREGS;
bec39cab
AC
13070 ;
13071 return 0;
13072}
13073_ACEOF
81ecdfbb 13074if ac_fn_c_try_compile "$LINENO"; then :
a3828db0 13075 gdb_cv_have_ptrace_getregs=yes
451928c5 13076else
81ecdfbb 13077 gdb_cv_have_ptrace_getregs=no
451928c5 13078fi
81ecdfbb 13079rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
451928c5
AC
13080fi
13081
81ecdfbb
RW
13082{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_ptrace_getregs" >&5
13083$as_echo "$gdb_cv_have_ptrace_getregs" >&6; }
a3828db0 13084if test $gdb_cv_have_ptrace_getregs = yes; then
60ca704f 13085
81ecdfbb 13086$as_echo "#define HAVE_PTRACE_GETREGS 1" >>confdefs.h
451928c5 13087
97bf5e38 13088fi
451928c5 13089
a3828db0 13090# See if <sys/ptrace.h> provides the PTRACE_GETFPXREGS request.
81ecdfbb
RW
13091{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTRACE_GETFPXREGS" >&5
13092$as_echo_n "checking for PTRACE_GETFPXREGS... " >&6; }
13093if test "${gdb_cv_have_ptrace_getfpxregs+set}" = set; then :
13094 $as_echo_n "(cached) " >&6
451928c5 13095else
81ecdfbb 13096 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 13097/* end confdefs.h. */
a3828db0 13098#include <sys/ptrace.h>
bec39cab
AC
13099int
13100main ()
13101{
a3828db0 13102PTRACE_GETFPXREGS;
bec39cab
AC
13103 ;
13104 return 0;
13105}
13106_ACEOF
81ecdfbb 13107if ac_fn_c_try_compile "$LINENO"; then :
a3828db0 13108 gdb_cv_have_ptrace_getfpxregs=yes
451928c5 13109else
81ecdfbb 13110 gdb_cv_have_ptrace_getfpxregs=no
451928c5 13111fi
81ecdfbb 13112rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
451928c5
AC
13113fi
13114
81ecdfbb
RW
13115{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_ptrace_getfpxregs" >&5
13116$as_echo "$gdb_cv_have_ptrace_getfpxregs" >&6; }
a3828db0 13117if test $gdb_cv_have_ptrace_getfpxregs = yes; then
60ca704f 13118
81ecdfbb 13119$as_echo "#define HAVE_PTRACE_GETFPXREGS 1" >>confdefs.h
451928c5 13120
97bf5e38 13121fi
451928c5 13122
a3828db0 13123# See if <sys/ptrace.h> provides the PT_GETDBREGS request.
81ecdfbb
RW
13124{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for PT_GETDBREGS" >&5
13125$as_echo_n "checking for PT_GETDBREGS... " >&6; }
13126if test "${gdb_cv_have_pt_getdbregs+set}" = set; then :
13127 $as_echo_n "(cached) " >&6
3862412b 13128else
81ecdfbb 13129 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 13130/* end confdefs.h. */
a3828db0
MK
13131#include <sys/types.h>
13132#include <sys/ptrace.h>
bec39cab
AC
13133int
13134main ()
13135{
a3828db0 13136PT_GETDBREGS;
bec39cab
AC
13137 ;
13138 return 0;
13139}
13140_ACEOF
81ecdfbb 13141if ac_fn_c_try_compile "$LINENO"; then :
a3828db0 13142 gdb_cv_have_pt_getdbregs=yes
3862412b 13143else
81ecdfbb 13144 gdb_cv_have_pt_getdbregs=no
3862412b 13145fi
81ecdfbb 13146rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3862412b
MK
13147fi
13148
81ecdfbb
RW
13149{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_pt_getdbregs" >&5
13150$as_echo "$gdb_cv_have_pt_getdbregs" >&6; }
a3828db0 13151if test $gdb_cv_have_pt_getdbregs = yes; then
60ca704f 13152
81ecdfbb 13153$as_echo "#define HAVE_PT_GETDBREGS 1" >>confdefs.h
3862412b 13154
97bf5e38 13155fi
3862412b 13156
a3828db0 13157# See if <sys/ptrace.h> provides the PT_GETXMMREGS request.
81ecdfbb
RW
13158{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for PT_GETXMMREGS" >&5
13159$as_echo_n "checking for PT_GETXMMREGS... " >&6; }
13160if test "${gdb_cv_have_pt_getxmmregs+set}" = set; then :
13161 $as_echo_n "(cached) " >&6
3862412b 13162else
81ecdfbb 13163 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 13164/* end confdefs.h. */
a3828db0
MK
13165#include <sys/types.h>
13166#include <sys/ptrace.h>
bec39cab
AC
13167int
13168main ()
13169{
a3828db0 13170PT_GETXMMREGS;
bec39cab
AC
13171 ;
13172 return 0;
13173}
13174_ACEOF
81ecdfbb 13175if ac_fn_c_try_compile "$LINENO"; then :
a3828db0 13176 gdb_cv_have_pt_getxmmregs=yes
3862412b 13177else
81ecdfbb 13178 gdb_cv_have_pt_getxmmregs=no
3862412b 13179fi
81ecdfbb 13180rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3862412b
MK
13181fi
13182
81ecdfbb
RW
13183{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_pt_getxmmregs" >&5
13184$as_echo "$gdb_cv_have_pt_getxmmregs" >&6; }
a3828db0 13185if test $gdb_cv_have_pt_getxmmregs = yes; then
60ca704f 13186
81ecdfbb 13187$as_echo "#define HAVE_PT_GETXMMREGS 1" >>confdefs.h
3862412b 13188
97bf5e38 13189fi
3862412b 13190
eb368090 13191# Detect which type of /proc is in use, such as for Unixware or Solaris.
97bf5e38
MK
13192
13193if test "${target}" = "${host}"; then
13194 case "${host}" in
97bf5e38 13195 *-*-unixware* | *-*-sysv4.2* | *-*-sysv5* | *-*-interix* )
60ca704f 13196
81ecdfbb 13197$as_echo "#define NEW_PROC_API 1" >>confdefs.h
97bf5e38
MK
13198
13199 ;;
c162e8c9 13200 *-*-solaris2.[6789] | *-*-solaris2.1[0-9]*)
60ca704f 13201
81ecdfbb 13202$as_echo "#define NEW_PROC_API 1" >>confdefs.h
c960c18f
AC
13203
13204 ;;
13205 mips-sgi-irix5*)
13206 # Work around <sys/proc.h> needing _KMEMUSER problem on IRIX 5.
60ca704f 13207
81ecdfbb 13208$as_echo "#define _KMEMUSER 1" >>confdefs.h
97bf5e38
MK
13209
13210 ;;
13211 esac
13212fi
13213
13214if test "$ac_cv_header_sys_procfs_h" = yes; then
81ecdfbb
RW
13215 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pstatus_t in sys/procfs.h" >&5
13216$as_echo_n "checking for pstatus_t in sys/procfs.h... " >&6; }
13217 if test "${bfd_cv_have_sys_procfs_type_pstatus_t+set}" = set; then :
13218 $as_echo_n "(cached) " >&6
bec39cab 13219else
81ecdfbb 13220 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 13221/* end confdefs.h. */
596c9d4b
KB
13222
13223#define _SYSCALL32
d30c5336
JK
13224/* Needed for new procfs interface on sparc-solaris. */
13225#define _STRUCTURED_PROC 1
596c9d4b 13226#include <sys/procfs.h>
bec39cab
AC
13227int
13228main ()
13229{
97bf5e38 13230pstatus_t avar
bec39cab
AC
13231 ;
13232 return 0;
13233}
13234_ACEOF
81ecdfbb 13235if ac_fn_c_try_compile "$LINENO"; then :
97bf5e38 13236 bfd_cv_have_sys_procfs_type_pstatus_t=yes
596c9d4b 13237else
81ecdfbb 13238 bfd_cv_have_sys_procfs_type_pstatus_t=no
bec39cab 13239
596c9d4b 13240fi
81ecdfbb 13241rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
596c9d4b
KB
13242fi
13243
97bf5e38 13244 if test $bfd_cv_have_sys_procfs_type_pstatus_t = yes; then
bec39cab 13245
81ecdfbb 13246$as_echo "#define HAVE_PSTATUS_T 1" >>confdefs.h
596c9d4b
KB
13247
13248 fi
81ecdfbb
RW
13249 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_pstatus_t" >&5
13250$as_echo "$bfd_cv_have_sys_procfs_type_pstatus_t" >&6; }
596c9d4b 13251
81ecdfbb
RW
13252 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prrun_t in sys/procfs.h" >&5
13253$as_echo_n "checking for prrun_t in sys/procfs.h... " >&6; }
13254 if test "${bfd_cv_have_sys_procfs_type_prrun_t+set}" = set; then :
13255 $as_echo_n "(cached) " >&6
596c9d4b 13256else
81ecdfbb 13257 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 13258/* end confdefs.h. */
596c9d4b
KB
13259
13260#define _SYSCALL32
d30c5336
JK
13261/* Needed for new procfs interface on sparc-solaris. */
13262#define _STRUCTURED_PROC 1
596c9d4b 13263#include <sys/procfs.h>
bec39cab
AC
13264int
13265main ()
13266{
97bf5e38 13267prrun_t avar
bec39cab
AC
13268 ;
13269 return 0;
13270}
13271_ACEOF
81ecdfbb 13272if ac_fn_c_try_compile "$LINENO"; then :
97bf5e38 13273 bfd_cv_have_sys_procfs_type_prrun_t=yes
596c9d4b 13274else
81ecdfbb 13275 bfd_cv_have_sys_procfs_type_prrun_t=no
bec39cab 13276
596c9d4b 13277fi
81ecdfbb 13278rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
596c9d4b
KB
13279fi
13280
97bf5e38 13281 if test $bfd_cv_have_sys_procfs_type_prrun_t = yes; then
bec39cab 13282
81ecdfbb 13283$as_echo "#define HAVE_PRRUN_T 1" >>confdefs.h
596c9d4b
KB
13284
13285 fi
81ecdfbb
RW
13286 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prrun_t" >&5
13287$as_echo "$bfd_cv_have_sys_procfs_type_prrun_t" >&6; }
596c9d4b 13288
81ecdfbb
RW
13289 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gregset_t in sys/procfs.h" >&5
13290$as_echo_n "checking for gregset_t in sys/procfs.h... " >&6; }
13291 if test "${bfd_cv_have_sys_procfs_type_gregset_t+set}" = set; then :
13292 $as_echo_n "(cached) " >&6
596c9d4b 13293else
81ecdfbb 13294 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 13295/* end confdefs.h. */
596c9d4b
KB
13296
13297#define _SYSCALL32
d30c5336
JK
13298/* Needed for new procfs interface on sparc-solaris. */
13299#define _STRUCTURED_PROC 1
596c9d4b 13300#include <sys/procfs.h>
bec39cab
AC
13301int
13302main ()
13303{
97bf5e38 13304gregset_t avar
bec39cab
AC
13305 ;
13306 return 0;
13307}
13308_ACEOF
81ecdfbb 13309if ac_fn_c_try_compile "$LINENO"; then :
97bf5e38 13310 bfd_cv_have_sys_procfs_type_gregset_t=yes
596c9d4b 13311else
81ecdfbb 13312 bfd_cv_have_sys_procfs_type_gregset_t=no
bec39cab 13313
596c9d4b 13314fi
81ecdfbb 13315rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
596c9d4b
KB
13316fi
13317
97bf5e38 13318 if test $bfd_cv_have_sys_procfs_type_gregset_t = yes; then
bec39cab 13319
81ecdfbb 13320$as_echo "#define HAVE_GREGSET_T 1" >>confdefs.h
596c9d4b
KB
13321
13322 fi
81ecdfbb
RW
13323 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_gregset_t" >&5
13324$as_echo "$bfd_cv_have_sys_procfs_type_gregset_t" >&6; }
451928c5 13325
81ecdfbb
RW
13326 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fpregset_t in sys/procfs.h" >&5
13327$as_echo_n "checking for fpregset_t in sys/procfs.h... " >&6; }
13328 if test "${bfd_cv_have_sys_procfs_type_fpregset_t+set}" = set; then :
13329 $as_echo_n "(cached) " >&6
d84dd0c5 13330else
81ecdfbb 13331 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 13332/* end confdefs.h. */
97bf5e38
MK
13333
13334#define _SYSCALL32
d30c5336
JK
13335/* Needed for new procfs interface on sparc-solaris. */
13336#define _STRUCTURED_PROC 1
d84dd0c5 13337#include <sys/procfs.h>
bec39cab
AC
13338int
13339main ()
13340{
97bf5e38 13341fpregset_t avar
bec39cab
AC
13342 ;
13343 return 0;
13344}
13345_ACEOF
81ecdfbb 13346if ac_fn_c_try_compile "$LINENO"; then :
97bf5e38 13347 bfd_cv_have_sys_procfs_type_fpregset_t=yes
d84dd0c5 13348else
81ecdfbb 13349 bfd_cv_have_sys_procfs_type_fpregset_t=no
bec39cab 13350
d84dd0c5 13351fi
81ecdfbb 13352rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
d84dd0c5
MK
13353fi
13354
97bf5e38 13355 if test $bfd_cv_have_sys_procfs_type_fpregset_t = yes; then
bec39cab 13356
81ecdfbb 13357$as_echo "#define HAVE_FPREGSET_T 1" >>confdefs.h
d84dd0c5 13358
97bf5e38 13359 fi
81ecdfbb
RW
13360 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_fpregset_t" >&5
13361$as_echo "$bfd_cv_have_sys_procfs_type_fpregset_t" >&6; }
d84dd0c5 13362
81ecdfbb
RW
13363 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prgregset_t in sys/procfs.h" >&5
13364$as_echo_n "checking for prgregset_t in sys/procfs.h... " >&6; }
13365 if test "${bfd_cv_have_sys_procfs_type_prgregset_t+set}" = set; then :
13366 $as_echo_n "(cached) " >&6
c906108c 13367else
81ecdfbb 13368 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 13369/* end confdefs.h. */
c906108c 13370
97bf5e38 13371#define _SYSCALL32
d30c5336
JK
13372/* Needed for new procfs interface on sparc-solaris. */
13373#define _STRUCTURED_PROC 1
97bf5e38 13374#include <sys/procfs.h>
bec39cab
AC
13375int
13376main ()
13377{
97bf5e38 13378prgregset_t avar
bec39cab
AC
13379 ;
13380 return 0;
13381}
13382_ACEOF
81ecdfbb 13383if ac_fn_c_try_compile "$LINENO"; then :
97bf5e38 13384 bfd_cv_have_sys_procfs_type_prgregset_t=yes
c906108c 13385else
81ecdfbb 13386 bfd_cv_have_sys_procfs_type_prgregset_t=no
bec39cab 13387
c906108c 13388fi
81ecdfbb 13389rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
c906108c
SS
13390fi
13391
97bf5e38 13392 if test $bfd_cv_have_sys_procfs_type_prgregset_t = yes; then
bec39cab 13393
81ecdfbb 13394$as_echo "#define HAVE_PRGREGSET_T 1" >>confdefs.h
c906108c 13395
97bf5e38 13396 fi
81ecdfbb
RW
13397 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prgregset_t" >&5
13398$as_echo "$bfd_cv_have_sys_procfs_type_prgregset_t" >&6; }
c906108c 13399
81ecdfbb
RW
13400 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prfpregset_t in sys/procfs.h" >&5
13401$as_echo_n "checking for prfpregset_t in sys/procfs.h... " >&6; }
13402 if test "${bfd_cv_have_sys_procfs_type_prfpregset_t+set}" = set; then :
13403 $as_echo_n "(cached) " >&6
d45fe813 13404else
81ecdfbb 13405 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 13406/* end confdefs.h. */
97bf5e38
MK
13407
13408#define _SYSCALL32
d30c5336
JK
13409/* Needed for new procfs interface on sparc-solaris. */
13410#define _STRUCTURED_PROC 1
97bf5e38 13411#include <sys/procfs.h>
bec39cab
AC
13412int
13413main ()
13414{
97bf5e38 13415prfpregset_t avar
bec39cab
AC
13416 ;
13417 return 0;
13418}
13419_ACEOF
81ecdfbb 13420if ac_fn_c_try_compile "$LINENO"; then :
97bf5e38 13421 bfd_cv_have_sys_procfs_type_prfpregset_t=yes
d45fe813 13422else
81ecdfbb 13423 bfd_cv_have_sys_procfs_type_prfpregset_t=no
bec39cab 13424
d45fe813 13425fi
81ecdfbb 13426rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
d45fe813
KB
13427fi
13428
97bf5e38 13429 if test $bfd_cv_have_sys_procfs_type_prfpregset_t = yes; then
bec39cab 13430
81ecdfbb 13431$as_echo "#define HAVE_PRFPREGSET_T 1" >>confdefs.h
d45fe813 13432
97bf5e38 13433 fi
81ecdfbb
RW
13434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prfpregset_t" >&5
13435$as_echo "$bfd_cv_have_sys_procfs_type_prfpregset_t" >&6; }
d45fe813 13436
81ecdfbb
RW
13437 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prgregset32_t in sys/procfs.h" >&5
13438$as_echo_n "checking for prgregset32_t in sys/procfs.h... " >&6; }
13439 if test "${bfd_cv_have_sys_procfs_type_prgregset32_t+set}" = set; then :
13440 $as_echo_n "(cached) " >&6
d45fe813 13441else
81ecdfbb 13442 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 13443/* end confdefs.h. */
97bf5e38
MK
13444
13445#define _SYSCALL32
d30c5336
JK
13446/* Needed for new procfs interface on sparc-solaris. */
13447#define _STRUCTURED_PROC 1
97bf5e38 13448#include <sys/procfs.h>
bec39cab
AC
13449int
13450main ()
13451{
97bf5e38 13452prgregset32_t avar
bec39cab
AC
13453 ;
13454 return 0;
13455}
13456_ACEOF
81ecdfbb 13457if ac_fn_c_try_compile "$LINENO"; then :
97bf5e38 13458 bfd_cv_have_sys_procfs_type_prgregset32_t=yes
d45fe813 13459else
81ecdfbb 13460 bfd_cv_have_sys_procfs_type_prgregset32_t=no
bec39cab 13461
d45fe813 13462fi
81ecdfbb 13463rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
d45fe813
KB
13464fi
13465
97bf5e38 13466 if test $bfd_cv_have_sys_procfs_type_prgregset32_t = yes; then
bec39cab 13467
81ecdfbb 13468$as_echo "#define HAVE_PRGREGSET32_T 1" >>confdefs.h
d45fe813 13469
97bf5e38 13470 fi
81ecdfbb
RW
13471 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prgregset32_t" >&5
13472$as_echo "$bfd_cv_have_sys_procfs_type_prgregset32_t" >&6; }
d45fe813 13473
81ecdfbb
RW
13474 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prfpregset32_t in sys/procfs.h" >&5
13475$as_echo_n "checking for prfpregset32_t in sys/procfs.h... " >&6; }
13476 if test "${bfd_cv_have_sys_procfs_type_prfpregset32_t+set}" = set; then :
13477 $as_echo_n "(cached) " >&6
d45fe813 13478else
81ecdfbb 13479 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 13480/* end confdefs.h. */
97bf5e38
MK
13481
13482#define _SYSCALL32
d30c5336
JK
13483/* Needed for new procfs interface on sparc-solaris. */
13484#define _STRUCTURED_PROC 1
97bf5e38 13485#include <sys/procfs.h>
bec39cab
AC
13486int
13487main ()
13488{
97bf5e38 13489prfpregset32_t avar
bec39cab
AC
13490 ;
13491 return 0;
13492}
13493_ACEOF
81ecdfbb 13494if ac_fn_c_try_compile "$LINENO"; then :
97bf5e38 13495 bfd_cv_have_sys_procfs_type_prfpregset32_t=yes
d45fe813 13496else
81ecdfbb 13497 bfd_cv_have_sys_procfs_type_prfpregset32_t=no
bec39cab 13498
d45fe813 13499fi
81ecdfbb 13500rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
d45fe813
KB
13501fi
13502
97bf5e38 13503 if test $bfd_cv_have_sys_procfs_type_prfpregset32_t = yes; then
bec39cab 13504
81ecdfbb 13505$as_echo "#define HAVE_PRFPREGSET32_T 1" >>confdefs.h
d45fe813 13506
97bf5e38 13507 fi
81ecdfbb
RW
13508 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prfpregset32_t" >&5
13509$as_echo "$bfd_cv_have_sys_procfs_type_prfpregset32_t" >&6; }
d45fe813 13510
81ecdfbb
RW
13511 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lwpid_t in sys/procfs.h" >&5
13512$as_echo_n "checking for lwpid_t in sys/procfs.h... " >&6; }
13513 if test "${bfd_cv_have_sys_procfs_type_lwpid_t+set}" = set; then :
13514 $as_echo_n "(cached) " >&6
d45fe813 13515else
81ecdfbb 13516 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 13517/* end confdefs.h. */
97bf5e38 13518
d45fe813 13519#define _SYSCALL32
d30c5336
JK
13520/* Needed for new procfs interface on sparc-solaris. */
13521#define _STRUCTURED_PROC 1
97bf5e38 13522#include <sys/procfs.h>
bec39cab
AC
13523int
13524main ()
13525{
97bf5e38 13526lwpid_t avar
bec39cab
AC
13527 ;
13528 return 0;
13529}
13530_ACEOF
81ecdfbb 13531if ac_fn_c_try_compile "$LINENO"; then :
97bf5e38 13532 bfd_cv_have_sys_procfs_type_lwpid_t=yes
d45fe813 13533else
81ecdfbb 13534 bfd_cv_have_sys_procfs_type_lwpid_t=no
bec39cab 13535
d45fe813 13536fi
81ecdfbb 13537rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
d45fe813
KB
13538fi
13539
97bf5e38 13540 if test $bfd_cv_have_sys_procfs_type_lwpid_t = yes; then
bec39cab 13541
81ecdfbb 13542$as_echo "#define HAVE_LWPID_T 1" >>confdefs.h
d45fe813 13543
97bf5e38 13544 fi
81ecdfbb
RW
13545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_lwpid_t" >&5
13546$as_echo "$bfd_cv_have_sys_procfs_type_lwpid_t" >&6; }
c906108c 13547
81ecdfbb
RW
13548 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for psaddr_t in sys/procfs.h" >&5
13549$as_echo_n "checking for psaddr_t in sys/procfs.h... " >&6; }
13550 if test "${bfd_cv_have_sys_procfs_type_psaddr_t+set}" = set; then :
13551 $as_echo_n "(cached) " >&6
c906108c 13552else
81ecdfbb 13553 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 13554/* end confdefs.h. */
c906108c 13555
97bf5e38 13556#define _SYSCALL32
d30c5336
JK
13557/* Needed for new procfs interface on sparc-solaris. */
13558#define _STRUCTURED_PROC 1
97bf5e38 13559#include <sys/procfs.h>
bec39cab
AC
13560int
13561main ()
13562{
97bf5e38 13563psaddr_t avar
bec39cab
AC
13564 ;
13565 return 0;
13566}
13567_ACEOF
81ecdfbb 13568if ac_fn_c_try_compile "$LINENO"; then :
97bf5e38 13569 bfd_cv_have_sys_procfs_type_psaddr_t=yes
c906108c 13570else
81ecdfbb 13571 bfd_cv_have_sys_procfs_type_psaddr_t=no
bec39cab 13572
c906108c 13573fi
81ecdfbb 13574rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
c906108c
SS
13575fi
13576
97bf5e38 13577 if test $bfd_cv_have_sys_procfs_type_psaddr_t = yes; then
bec39cab 13578
81ecdfbb 13579$as_echo "#define HAVE_PSADDR_T 1" >>confdefs.h
c906108c 13580
97bf5e38 13581 fi
81ecdfbb
RW
13582 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_psaddr_t" >&5
13583$as_echo "$bfd_cv_have_sys_procfs_type_psaddr_t" >&6; }
c906108c 13584
81ecdfbb
RW
13585 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prsysent_t in sys/procfs.h" >&5
13586$as_echo_n "checking for prsysent_t in sys/procfs.h... " >&6; }
13587 if test "${bfd_cv_have_sys_procfs_type_prsysent_t+set}" = set; then :
13588 $as_echo_n "(cached) " >&6
c906108c 13589else
81ecdfbb 13590 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 13591/* end confdefs.h. */
c906108c 13592
97bf5e38 13593#define _SYSCALL32
d30c5336
JK
13594/* Needed for new procfs interface on sparc-solaris. */
13595#define _STRUCTURED_PROC 1
97bf5e38 13596#include <sys/procfs.h>
bec39cab
AC
13597int
13598main ()
13599{
97bf5e38 13600prsysent_t avar
bec39cab
AC
13601 ;
13602 return 0;
13603}
13604_ACEOF
81ecdfbb 13605if ac_fn_c_try_compile "$LINENO"; then :
97bf5e38 13606 bfd_cv_have_sys_procfs_type_prsysent_t=yes
c906108c 13607else
81ecdfbb 13608 bfd_cv_have_sys_procfs_type_prsysent_t=no
bec39cab 13609
c906108c 13610fi
81ecdfbb 13611rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
c906108c
SS
13612fi
13613
97bf5e38 13614 if test $bfd_cv_have_sys_procfs_type_prsysent_t = yes; then
bec39cab 13615
81ecdfbb 13616$as_echo "#define HAVE_PRSYSENT_T 1" >>confdefs.h
c906108c 13617
97bf5e38 13618 fi
81ecdfbb
RW
13619 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prsysent_t" >&5
13620$as_echo "$bfd_cv_have_sys_procfs_type_prsysent_t" >&6; }
c906108c 13621
81ecdfbb
RW
13622 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pr_sigset_t in sys/procfs.h" >&5
13623$as_echo_n "checking for pr_sigset_t in sys/procfs.h... " >&6; }
13624 if test "${bfd_cv_have_sys_procfs_type_pr_sigset_t+set}" = set; then :
13625 $as_echo_n "(cached) " >&6
c906108c 13626else
81ecdfbb 13627 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 13628/* end confdefs.h. */
c906108c 13629
97bf5e38 13630#define _SYSCALL32
d30c5336
JK
13631/* Needed for new procfs interface on sparc-solaris. */
13632#define _STRUCTURED_PROC 1
97bf5e38 13633#include <sys/procfs.h>
bec39cab
AC
13634int
13635main ()
13636{
97bf5e38 13637pr_sigset_t avar
bec39cab
AC
13638 ;
13639 return 0;
13640}
13641_ACEOF
81ecdfbb 13642if ac_fn_c_try_compile "$LINENO"; then :
97bf5e38 13643 bfd_cv_have_sys_procfs_type_pr_sigset_t=yes
c906108c 13644else
81ecdfbb 13645 bfd_cv_have_sys_procfs_type_pr_sigset_t=no
bec39cab 13646
c906108c 13647fi
81ecdfbb 13648rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
c906108c
SS
13649fi
13650
97bf5e38 13651 if test $bfd_cv_have_sys_procfs_type_pr_sigset_t = yes; then
bec39cab 13652
81ecdfbb 13653$as_echo "#define HAVE_PR_SIGSET_T 1" >>confdefs.h
c906108c 13654
97bf5e38 13655 fi
81ecdfbb
RW
13656 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_pr_sigset_t" >&5
13657$as_echo "$bfd_cv_have_sys_procfs_type_pr_sigset_t" >&6; }
c906108c 13658
81ecdfbb
RW
13659 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pr_sigaction64_t in sys/procfs.h" >&5
13660$as_echo_n "checking for pr_sigaction64_t in sys/procfs.h... " >&6; }
13661 if test "${bfd_cv_have_sys_procfs_type_pr_sigaction64_t+set}" = set; then :
13662 $as_echo_n "(cached) " >&6
c906108c 13663else
81ecdfbb 13664 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 13665/* end confdefs.h. */
c906108c 13666
97bf5e38 13667#define _SYSCALL32
d30c5336
JK
13668/* Needed for new procfs interface on sparc-solaris. */
13669#define _STRUCTURED_PROC 1
97bf5e38 13670#include <sys/procfs.h>
bec39cab
AC
13671int
13672main ()
13673{
97bf5e38 13674pr_sigaction64_t avar
bec39cab
AC
13675 ;
13676 return 0;
13677}
13678_ACEOF
81ecdfbb 13679if ac_fn_c_try_compile "$LINENO"; then :
97bf5e38 13680 bfd_cv_have_sys_procfs_type_pr_sigaction64_t=yes
c906108c 13681else
81ecdfbb 13682 bfd_cv_have_sys_procfs_type_pr_sigaction64_t=no
bec39cab 13683
c906108c 13684fi
81ecdfbb 13685rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
c906108c
SS
13686fi
13687
97bf5e38 13688 if test $bfd_cv_have_sys_procfs_type_pr_sigaction64_t = yes; then
bec39cab 13689
81ecdfbb 13690$as_echo "#define HAVE_PR_SIGACTION64_T 1" >>confdefs.h
c906108c 13691
97bf5e38 13692 fi
81ecdfbb
RW
13693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_pr_sigaction64_t" >&5
13694$as_echo "$bfd_cv_have_sys_procfs_type_pr_sigaction64_t" >&6; }
97bf5e38 13695
81ecdfbb
RW
13696 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pr_siginfo64_t in sys/procfs.h" >&5
13697$as_echo_n "checking for pr_siginfo64_t in sys/procfs.h... " >&6; }
13698 if test "${bfd_cv_have_sys_procfs_type_pr_siginfo64_t+set}" = set; then :
13699 $as_echo_n "(cached) " >&6
97bf5e38 13700else
81ecdfbb 13701 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 13702/* end confdefs.h. */
97bf5e38
MK
13703
13704#define _SYSCALL32
d30c5336
JK
13705/* Needed for new procfs interface on sparc-solaris. */
13706#define _STRUCTURED_PROC 1
97bf5e38 13707#include <sys/procfs.h>
bec39cab
AC
13708int
13709main ()
13710{
97bf5e38 13711pr_siginfo64_t avar
bec39cab
AC
13712 ;
13713 return 0;
13714}
13715_ACEOF
81ecdfbb 13716if ac_fn_c_try_compile "$LINENO"; then :
97bf5e38
MK
13717 bfd_cv_have_sys_procfs_type_pr_siginfo64_t=yes
13718else
81ecdfbb 13719 bfd_cv_have_sys_procfs_type_pr_siginfo64_t=no
bec39cab 13720
97bf5e38 13721fi
81ecdfbb 13722rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
c906108c 13723fi
c906108c 13724
97bf5e38 13725 if test $bfd_cv_have_sys_procfs_type_pr_siginfo64_t = yes; then
bec39cab 13726
81ecdfbb 13727$as_echo "#define HAVE_PR_SIGINFO64_T 1" >>confdefs.h
c906108c 13728
97bf5e38 13729 fi
81ecdfbb
RW
13730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_pr_siginfo64_t" >&5
13731$as_echo "$bfd_cv_have_sys_procfs_type_pr_siginfo64_t" >&6; }
bec39cab
AC
13732
13733
97bf5e38
MK
13734
13735
13736
97bf5e38 13737 if test $bfd_cv_have_sys_procfs_type_prfpregset_t = yes; then
81ecdfbb
RW
13738 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether prfpregset_t type is broken" >&5
13739$as_echo_n "checking whether prfpregset_t type is broken... " >&6; }
13740 if test "${gdb_cv_prfpregset_t_broken+set}" = set; then :
13741 $as_echo_n "(cached) " >&6
c906108c 13742else
81ecdfbb 13743 if test "$cross_compiling" = yes; then :
97bf5e38 13744 gdb_cv_prfpregset_t_broken=yes
c906108c 13745else
81ecdfbb 13746 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 13747/* end confdefs.h. */
97bf5e38
MK
13748#include <sys/procfs.h>
13749 int main ()
13750 {
13751 if (sizeof (prfpregset_t) == sizeof (void *))
13752 return 1;
13753 return 0;
13754 }
bec39cab 13755_ACEOF
81ecdfbb 13756if ac_fn_c_try_run "$LINENO"; then :
97bf5e38 13757 gdb_cv_prfpregset_t_broken=no
81ecdfbb
RW
13758else
13759 gdb_cv_prfpregset_t_broken=yes
c906108c 13760fi
81ecdfbb
RW
13761rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13762 conftest.$ac_objext conftest.beam conftest.$ac_ext
c906108c 13763fi
81ecdfbb 13764
c906108c
SS
13765fi
13766
81ecdfbb
RW
13767 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_prfpregset_t_broken" >&5
13768$as_echo "$gdb_cv_prfpregset_t_broken" >&6; }
97bf5e38 13769 if test $gdb_cv_prfpregset_t_broken = yes; then
60ca704f 13770
81ecdfbb 13771$as_echo "#define PRFPREGSET_T_BROKEN 1" >>confdefs.h
c906108c 13772
97bf5e38
MK
13773 fi
13774 fi
c906108c 13775
bec39cab 13776
81ecdfbb
RW
13777 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PIOCSET ioctl entry in sys/procfs.h" >&5
13778$as_echo_n "checking for PIOCSET ioctl entry in sys/procfs.h... " >&6; }
13779 if test "${gdb_cv_have_procfs_piocset+set}" = set; then :
13780 $as_echo_n "(cached) " >&6
c906108c 13781else
81ecdfbb 13782 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 13783/* end confdefs.h. */
97bf5e38
MK
13784#include <unistd.h>
13785#include <sys/types.h>
13786#include <sys/procfs.h>
13787
bec39cab
AC
13788int
13789main ()
13790{
97bf5e38
MK
13791
13792 int dummy;;
13793 dummy = ioctl(0, PIOCSET, &dummy);
bec39cab
AC
13794
13795 ;
13796 return 0;
13797}
13798_ACEOF
81ecdfbb 13799if ac_fn_c_try_compile "$LINENO"; then :
97bf5e38 13800 gdb_cv_have_procfs_piocset=yes
c906108c 13801else
81ecdfbb 13802 gdb_cv_have_procfs_piocset=no
c906108c 13803fi
81ecdfbb 13804rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
c906108c 13805fi
97bf5e38 13806
81ecdfbb
RW
13807 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_procfs_piocset" >&5
13808$as_echo "$gdb_cv_have_procfs_piocset" >&6; }
97bf5e38 13809 if test $gdb_cv_have_procfs_piocset = yes; then
60ca704f 13810
81ecdfbb 13811$as_echo "#define HAVE_PROCFS_PIOCSET 1" >>confdefs.h
97bf5e38
MK
13812
13813 fi
c906108c 13814fi
c906108c 13815
97bf5e38 13816if test ${host} = ${target} ; then
bec39cab 13817
81ecdfbb
RW
13818 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for member l_addr in struct link_map" >&5
13819$as_echo_n "checking for member l_addr in struct link_map... " >&6; }
13820 if test "${gdb_cv_have_struct_link_map_with_l_members+set}" = set; then :
13821 $as_echo_n "(cached) " >&6
bec39cab 13822else
81ecdfbb 13823 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 13824/* end confdefs.h. */
97bf5e38 13825#include <link.h>
bec39cab
AC
13826int
13827main ()
13828{
97bf5e38 13829struct link_map lm; (void) lm.l_addr;
bec39cab
AC
13830 ;
13831 return 0;
13832}
13833_ACEOF
81ecdfbb 13834if ac_fn_c_try_compile "$LINENO"; then :
97bf5e38 13835 gdb_cv_have_struct_link_map_with_l_members=yes
c906108c 13836else
81ecdfbb 13837 gdb_cv_have_struct_link_map_with_l_members=no
c906108c 13838fi
81ecdfbb 13839rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
c906108c
SS
13840fi
13841
81ecdfbb
RW
13842 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_struct_link_map_with_l_members" >&5
13843$as_echo "$gdb_cv_have_struct_link_map_with_l_members" >&6; }
97bf5e38 13844 if test $gdb_cv_have_struct_link_map_with_l_members = yes; then
60ca704f 13845
81ecdfbb 13846$as_echo "#define HAVE_STRUCT_LINK_MAP_WITH_L_MEMBERS 1" >>confdefs.h
97bf5e38
MK
13847
13848 fi
13849
bec39cab 13850
81ecdfbb
RW
13851 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for member lm_addr in struct link_map" >&5
13852$as_echo_n "checking for member lm_addr in struct link_map... " >&6; }
13853 if test "${gdb_cv_have_struct_link_map_with_lm_members+set}" = set; then :
13854 $as_echo_n "(cached) " >&6
c906108c 13855else
81ecdfbb 13856 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 13857/* end confdefs.h. */
97bf5e38
MK
13858#include <sys/types.h>
13859#include <link.h>
bec39cab
AC
13860int
13861main ()
13862{
97bf5e38 13863struct link_map lm; (void) lm.lm_addr;
bec39cab
AC
13864 ;
13865 return 0;
13866}
13867_ACEOF
81ecdfbb 13868if ac_fn_c_try_compile "$LINENO"; then :
97bf5e38
MK
13869 gdb_cv_have_struct_link_map_with_lm_members=yes
13870else
81ecdfbb 13871 gdb_cv_have_struct_link_map_with_lm_members=no
97bf5e38 13872fi
81ecdfbb 13873rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
c906108c 13874fi
c906108c 13875
81ecdfbb
RW
13876 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_struct_link_map_with_lm_members" >&5
13877$as_echo "$gdb_cv_have_struct_link_map_with_lm_members" >&6; }
97bf5e38 13878 if test $gdb_cv_have_struct_link_map_with_lm_members = yes; then
60ca704f 13879
81ecdfbb 13880$as_echo "#define HAVE_STRUCT_LINK_MAP_WITH_LM_MEMBERS 1" >>confdefs.h
97bf5e38
MK
13881
13882 fi
13883
bec39cab 13884
81ecdfbb
RW
13885 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for member som_addr in struct so_map" >&5
13886$as_echo_n "checking for member som_addr in struct so_map... " >&6; }
13887 if test "${gdb_cv_have_struct_so_map_with_som_members+set}" = set; then :
13888 $as_echo_n "(cached) " >&6
c906108c 13889else
81ecdfbb 13890 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 13891/* end confdefs.h. */
97bf5e38
MK
13892#include <sys/types.h>
13893#ifdef HAVE_NLIST_H
13894#include <nlist.h>
13895#endif
13896#include <link.h>
bec39cab
AC
13897int
13898main ()
13899{
97bf5e38 13900struct so_map lm; (void) lm.som_addr;
bec39cab
AC
13901 ;
13902 return 0;
13903}
13904_ACEOF
81ecdfbb 13905if ac_fn_c_try_compile "$LINENO"; then :
97bf5e38
MK
13906 gdb_cv_have_struct_so_map_with_som_members=yes
13907else
81ecdfbb 13908 gdb_cv_have_struct_so_map_with_som_members=no
97bf5e38 13909fi
81ecdfbb 13910rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
97bf5e38 13911fi
c906108c 13912
81ecdfbb
RW
13913 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_struct_so_map_with_som_members" >&5
13914$as_echo "$gdb_cv_have_struct_so_map_with_som_members" >&6; }
97bf5e38 13915 if test $gdb_cv_have_struct_so_map_with_som_members = yes; then
60ca704f 13916
81ecdfbb 13917$as_echo "#define HAVE_STRUCT_SO_MAP_WITH_SOM_MEMBERS 1" >>confdefs.h
c906108c 13918
97bf5e38 13919 fi
c906108c 13920
bec39cab 13921
81ecdfbb
RW
13922 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct link_map32 in sys/link.h" >&5
13923$as_echo_n "checking for struct link_map32 in sys/link.h... " >&6; }
13924 if test "${gdb_cv_have_struct_link_map32+set}" = set; then :
13925 $as_echo_n "(cached) " >&6
97bf5e38 13926else
81ecdfbb 13927 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 13928/* end confdefs.h. */
97bf5e38
MK
13929#define _SYSCALL32
13930#include <sys/link.h>
bec39cab
AC
13931int
13932main ()
13933{
97bf5e38 13934struct link_map32 l;
bec39cab
AC
13935 ;
13936 return 0;
13937}
13938_ACEOF
81ecdfbb 13939if ac_fn_c_try_compile "$LINENO"; then :
97bf5e38
MK
13940 gdb_cv_have_struct_link_map32=yes
13941else
81ecdfbb 13942 gdb_cv_have_struct_link_map32=no
97bf5e38 13943fi
81ecdfbb 13944rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
97bf5e38 13945fi
c906108c 13946
81ecdfbb
RW
13947 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_struct_link_map32" >&5
13948$as_echo "$gdb_cv_have_struct_link_map32" >&6; }
97bf5e38 13949 if test $gdb_cv_have_struct_link_map32 = yes; then
60ca704f 13950
81ecdfbb 13951$as_echo "#define HAVE_STRUCT_LINK_MAP32 1" >>confdefs.h
c906108c 13952
60ca704f 13953
81ecdfbb 13954$as_echo "#define _SYSCALL32 1" >>confdefs.h
c906108c 13955
97bf5e38
MK
13956 fi
13957fi
c906108c 13958
bc8bcb4b 13959# Check if the compiler supports the `long long' type.
c906108c 13960
81ecdfbb
RW
13961{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long support in compiler" >&5
13962$as_echo_n "checking for long long support in compiler... " >&6; }
13963if test "${gdb_cv_c_long_long+set}" = set; then :
13964 $as_echo_n "(cached) " >&6
97bf5e38 13965else
81ecdfbb 13966 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 13967/* end confdefs.h. */
bc8bcb4b 13968extern long long foo;
bec39cab
AC
13969int
13970main ()
13971{
bc8bcb4b 13972switch (foo & 2) { case 0: return 1; }
bec39cab
AC
13973 ;
13974 return 0;
13975}
13976_ACEOF
81ecdfbb 13977if ac_fn_c_try_compile "$LINENO"; then :
97bf5e38
MK
13978 gdb_cv_c_long_long=yes
13979else
81ecdfbb 13980 gdb_cv_c_long_long=no
97bf5e38 13981fi
81ecdfbb 13982rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
97bf5e38 13983fi
81ecdfbb
RW
13984{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_c_long_long" >&5
13985$as_echo "$gdb_cv_c_long_long" >&6; }
97bf5e38 13986if test $gdb_cv_c_long_long = yes; then
bc8bcb4b 13987
81ecdfbb 13988$as_echo "#define CC_HAS_LONG_LONG 1" >>confdefs.h
97bf5e38
MK
13989
13990fi
13991
bc8bcb4b 13992# Check if the compiler and runtime support printing long longs.
97bf5e38 13993
81ecdfbb
RW
13994{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long support in printf" >&5
13995$as_echo_n "checking for long long support in printf... " >&6; }
13996if test "${gdb_cv_printf_has_long_long+set}" = set; then :
13997 $as_echo_n "(cached) " >&6
97bf5e38 13998else
81ecdfbb 13999 if test "$cross_compiling" = yes; then :
97bf5e38
MK
14000 gdb_cv_printf_has_long_long=no
14001else
81ecdfbb 14002 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 14003/* end confdefs.h. */
bc8bcb4b
MK
14004$ac_includes_default
14005int
14006main ()
14007{
14008char buf[32];
97bf5e38
MK
14009 long long l = 0;
14010 l = (l << 16) + 0x0123;
14011 l = (l << 16) + 0x4567;
14012 l = (l << 16) + 0x89ab;
14013 l = (l << 16) + 0xcdef;
14014 sprintf (buf, "0x%016llx", l);
14015 return (strcmp ("0x0123456789abcdef", buf));
bc8bcb4b
MK
14016 ;
14017 return 0;
c906108c 14018}
bec39cab 14019_ACEOF
81ecdfbb 14020if ac_fn_c_try_run "$LINENO"; then :
97bf5e38
MK
14021 gdb_cv_printf_has_long_long=yes
14022else
81ecdfbb 14023 gdb_cv_printf_has_long_long=no
97bf5e38 14024fi
81ecdfbb
RW
14025rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14026 conftest.$ac_objext conftest.beam conftest.$ac_ext
97bf5e38 14027fi
81ecdfbb 14028
97bf5e38 14029fi
81ecdfbb
RW
14030{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_printf_has_long_long" >&5
14031$as_echo "$gdb_cv_printf_has_long_long" >&6; }
97bf5e38 14032if test $gdb_cv_printf_has_long_long = yes; then
bc8bcb4b 14033
81ecdfbb 14034$as_echo "#define PRINTF_HAS_LONG_LONG 1" >>confdefs.h
97bf5e38
MK
14035
14036fi
97bf5e38 14037
1a619819
LM
14038# Check if the compiler and runtime support printing decfloats.
14039
81ecdfbb
RW
14040{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for decfloat support in printf" >&5
14041$as_echo_n "checking for decfloat support in printf... " >&6; }
14042if test "${gdb_cv_printf_has_decfloat+set}" = set; then :
14043 $as_echo_n "(cached) " >&6
1a619819 14044else
81ecdfbb 14045 if test "$cross_compiling" = yes; then :
1a619819
LM
14046 gdb_cv_printf_has_decfloat=no
14047else
81ecdfbb 14048 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1a619819
LM
14049/* end confdefs.h. */
14050$ac_includes_default
14051int
14052main ()
14053{
14054char buf[64];
14055 _Decimal32 d32 = 1.2345df;
14056 _Decimal64 d64 = 1.2345dd;
14057 _Decimal128 d128 = 1.2345dl;
14058 sprintf (buf, "Decimal32: %H\nDecimal64: %D\nDecimal128: %DD", d32, d64, d128);
14059 return (strcmp ("Decimal32: 1.2345\nDecimal64: 1.2345\nDecimal128: 1.2345", buf));
14060 ;
14061 return 0;
14062}
14063_ACEOF
81ecdfbb 14064if ac_fn_c_try_run "$LINENO"; then :
1a619819
LM
14065 gdb_cv_printf_has_decfloat=yes
14066else
81ecdfbb 14067 gdb_cv_printf_has_decfloat=no
1a619819 14068fi
81ecdfbb
RW
14069rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14070 conftest.$ac_objext conftest.beam conftest.$ac_ext
1a619819 14071fi
81ecdfbb 14072
1a619819 14073fi
81ecdfbb
RW
14074{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_printf_has_decfloat" >&5
14075$as_echo "$gdb_cv_printf_has_decfloat" >&6; }
1a619819
LM
14076if test $gdb_cv_printf_has_decfloat = yes; then
14077
81ecdfbb 14078$as_echo "#define PRINTF_HAS_DECFLOAT 1" >>confdefs.h
1a619819
LM
14079
14080fi
14081
bc8bcb4b
MK
14082# Check if the compiler supports the `long double' type. We can't use
14083# AC_C_LONG_DOUBLE because that one does additional checks on the
14084# constants defined in <float.h> that fail on some systems,
14085# e.g. FreeBSD/i386 4.7 and OpenBSD/i386 3.6.
97bf5e38 14086
81ecdfbb
RW
14087{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double support in compiler" >&5
14088$as_echo_n "checking for long double support in compiler... " >&6; }
14089if test "${gdb_cv_c_long_double+set}" = set; then :
14090 $as_echo_n "(cached) " >&6
97bf5e38 14091else
81ecdfbb 14092 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 14093/* end confdefs.h. */
97bf5e38 14094long double foo;
bec39cab 14095_ACEOF
81ecdfbb 14096if ac_fn_c_try_compile "$LINENO"; then :
bc8bcb4b 14097 gdb_cv_c_long_double=yes
97bf5e38 14098else
81ecdfbb 14099 gdb_cv_c_long_double=no
97bf5e38 14100fi
81ecdfbb 14101rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
97bf5e38 14102fi
81ecdfbb
RW
14103{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_c_long_double" >&5
14104$as_echo "$gdb_cv_c_long_double" >&6; }
bc8bcb4b 14105if test $gdb_cv_c_long_double = yes; then
c906108c 14106
81ecdfbb 14107$as_echo "#define HAVE_LONG_DOUBLE 1" >>confdefs.h
97bf5e38
MK
14108
14109fi
14110
bc8bcb4b 14111# Check if the compiler and runtime support printing long doubles.
97bf5e38 14112
81ecdfbb
RW
14113{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double support in printf" >&5
14114$as_echo_n "checking for long double support in printf... " >&6; }
14115if test "${gdb_cv_printf_has_long_double+set}" = set; then :
14116 $as_echo_n "(cached) " >&6
97bf5e38 14117else
81ecdfbb 14118 if test "$cross_compiling" = yes; then :
97bf5e38
MK
14119 gdb_cv_printf_has_long_double=no
14120else
81ecdfbb 14121 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 14122/* end confdefs.h. */
bc8bcb4b
MK
14123$ac_includes_default
14124int
14125main ()
14126{
14127char buf[16];
97bf5e38
MK
14128 long double f = 3.141592653;
14129 sprintf (buf, "%Lg", f);
14130 return (strncmp ("3.14159", buf, 7));
bc8bcb4b
MK
14131 ;
14132 return 0;
97bf5e38 14133}
bec39cab 14134_ACEOF
81ecdfbb 14135if ac_fn_c_try_run "$LINENO"; then :
97bf5e38 14136 gdb_cv_printf_has_long_double=yes
c906108c 14137else
81ecdfbb 14138 gdb_cv_printf_has_long_double=no
c906108c 14139fi
81ecdfbb
RW
14140rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14141 conftest.$ac_objext conftest.beam conftest.$ac_ext
c906108c 14142fi
81ecdfbb 14143
c906108c 14144fi
81ecdfbb
RW
14145{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_printf_has_long_double" >&5
14146$as_echo "$gdb_cv_printf_has_long_double" >&6; }
97bf5e38 14147if test $gdb_cv_printf_has_long_double = yes; then
bc8bcb4b 14148
81ecdfbb 14149$as_echo "#define PRINTF_HAS_LONG_DOUBLE 1" >>confdefs.h
97bf5e38
MK
14150
14151fi
97bf5e38 14152
bc8bcb4b 14153# Check if the compiler and runtime support scanning long doubles.
97bf5e38 14154
81ecdfbb
RW
14155{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double support in scanf" >&5
14156$as_echo_n "checking for long double support in scanf... " >&6; }
14157if test "${gdb_cv_scanf_has_long_double+set}" = set; then :
14158 $as_echo_n "(cached) " >&6
97bf5e38 14159else
81ecdfbb 14160 if test "$cross_compiling" = yes; then :
97bf5e38
MK
14161 gdb_cv_scanf_has_long_double=no
14162else
81ecdfbb 14163 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 14164/* end confdefs.h. */
bc8bcb4b
MK
14165#include <stdio.h>
14166int
14167main ()
14168{
14169char *buf = "3.141592653";
97bf5e38
MK
14170 long double f = 0;
14171 sscanf (buf, "%Lg", &f);
14172 return !(f > 3.14159 && f < 3.14160);
bc8bcb4b
MK
14173 ;
14174 return 0;
97bf5e38 14175}
bec39cab 14176_ACEOF
81ecdfbb 14177if ac_fn_c_try_run "$LINENO"; then :
97bf5e38
MK
14178 gdb_cv_scanf_has_long_double=yes
14179else
81ecdfbb 14180 gdb_cv_scanf_has_long_double=no
97bf5e38 14181fi
81ecdfbb
RW
14182rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14183 conftest.$ac_objext conftest.beam conftest.$ac_ext
97bf5e38 14184fi
81ecdfbb 14185
c906108c 14186fi
81ecdfbb
RW
14187{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_scanf_has_long_double" >&5
14188$as_echo "$gdb_cv_scanf_has_long_double" >&6; }
97bf5e38 14189if test $gdb_cv_scanf_has_long_double = yes; then
bc8bcb4b 14190
81ecdfbb 14191$as_echo "#define SCANF_HAS_LONG_DOUBLE 1" >>confdefs.h
97bf5e38
MK
14192
14193fi
c906108c 14194
438013df
AO
14195case ${host_os} in
14196aix*)
81ecdfbb
RW
14197 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -bbigtoc option" >&5
14198$as_echo_n "checking for -bbigtoc option... " >&6; }
14199if test "${gdb_cv_bigtoc+set}" = set; then :
14200 $as_echo_n "(cached) " >&6
438013df 14201else
bec39cab 14202
438013df
AO
14203 SAVE_LDFLAGS=$LDFLAGS
14204
14205 case $GCC in
14206 yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
14207 *) gdb_cv_bigtoc=-bbigtoc ;;
14208 esac
14209
14210 LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
81ecdfbb 14211 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 14212/* end confdefs.h. */
438013df 14213
bec39cab
AC
14214int
14215main ()
14216{
438013df 14217int i;
bec39cab
AC
14218 ;
14219 return 0;
14220}
14221_ACEOF
81ecdfbb 14222if ac_fn_c_try_link "$LINENO"; then :
bec39cab 14223
81ecdfbb
RW
14224else
14225 gdb_cv_bigtoc=
438013df 14226fi
81ecdfbb
RW
14227rm -f core conftest.err conftest.$ac_objext \
14228 conftest$ac_exeext conftest.$ac_ext
ec76baa5 14229 LDFLAGS="${SAVE_LDFLAGS}"
438013df 14230
bec39cab 14231fi
81ecdfbb
RW
14232{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_bigtoc" >&5
14233$as_echo "$gdb_cv_bigtoc" >&6; }
438013df
AO
14234 CONFIG_LDFLAGS="${CONFIG_LDFLAGS} ${gdb_cv_bigtoc}"
14235 ;;
14236esac
14237
38f6b338 14238{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for the dynamic export flag" >&5
f6528abd 14239$as_echo_n "checking for the dynamic export flag... " >&6; }
38f6b338
JK
14240dynamic_list=false
14241if test "${gdb_native}" = yes; then
14242 # The dynamically loaded libthread_db needs access to symbols in the gdb
14243 # executable. Older GNU ld supports --export-dynamic but --dynamic-list
14244 # may not be supported there.
14245 old_LDFLAGS="$LDFLAGS"
14246 # Older GNU ld supports --export-dynamic but --dynamic-list it does not.
14247 RDYNAMIC="-Wl,--dynamic-list=${srcdir}/proc-service.list"
14248 LDFLAGS="$LDFLAGS $RDYNAMIC"
14249 if test "${have_libpython}" = no; then
14250 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
f6528abd
JK
14251/* end confdefs.h. */
14252
14253int
14254main ()
14255{
14256
14257 ;
14258 return 0;
14259}
14260_ACEOF
14261if ac_fn_c_try_link "$LINENO"; then :
3bebe2f2
JK
14262 dynamic_list=true
14263fi
14264rm -f core conftest.err conftest.$ac_objext \
14265 conftest$ac_exeext conftest.$ac_ext
38f6b338
JK
14266 else
14267 # Workaround http://bugs.python.org/issue4434 where static
14268 # libpythonX.Y.a would get its symbols required for
14269 # pythonX.Y/lib-dynload/*.so modules hidden by -Wl,--dynamic-list.
14270 # Problem does not happen for the recommended libpythonX.Y.so linkage.
14271 old_CFLAGS="$CFLAGS"
14272 CFLAGS="$CFLAGS $PYTHON_CFLAGS"
14273 if test "$cross_compiling" = yes; then :
3bebe2f2 14274 true
f6528abd 14275else
3bebe2f2
JK
14276 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14277/* end confdefs.h. */
14278#include "${have_libpython}/Python.h"
14279int
14280main ()
14281{
14282int err;
38f6b338
JK
14283 Py_Initialize ();
14284 err = PyRun_SimpleString ("import itertools\n");
14285 Py_Finalize ();
14286 return err == 0 ? 0 : 1;
3bebe2f2
JK
14287 ;
14288 return 0;
14289}
14290_ACEOF
14291if ac_fn_c_try_run "$LINENO"; then :
14292 dynamic_list=true
14293fi
14294rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14295 conftest.$ac_objext conftest.beam conftest.$ac_ext
14296fi
14297
38f6b338
JK
14298 CFLAGS="$old_CFLAGS"
14299 fi
14300 LDFLAGS="$old_LDFLAGS"
14301fi
14302if $dynamic_list; then
14303 found="-Wl,--dynamic-list"
14304 RDYNAMIC='-Wl,--dynamic-list=$(srcdir)/proc-service.list'
f6528abd 14305else
38f6b338
JK
14306 found="-rdynamic"
14307 RDYNAMIC="-rdynamic"
f6528abd 14308fi
f6528abd 14309
38f6b338 14310{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $found" >&5
f6528abd 14311$as_echo "$found" >&6; }
0407b3f1 14312
f6528abd 14313
0407b3f1 14314if test ${build} = ${host} -a ${host} = ${target} ; then
c906108c
SS
14315 case ${host_os} in
14316 hpux*)
81ecdfbb
RW
14317 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HPUX/OSF thread support" >&5
14318$as_echo_n "checking for HPUX/OSF thread support... " >&6; }
c906108c
SS
14319 if test -f /usr/include/dce/cma_config.h ; then
14320 if test "$GCC" = "yes" ; then
81ecdfbb
RW
14321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14322$as_echo "yes" >&6; }
60ca704f 14323
81ecdfbb 14324$as_echo "#define HAVE_HPUX_THREAD_SUPPORT 1" >>confdefs.h
c906108c 14325
3483b318 14326 CONFIG_OBS="${CONFIG_OBS} hpux-thread.o"
c906108c
SS
14327 CONFIG_SRCS="${CONFIG_SRCS} hpux-thread.c"
14328 else
81ecdfbb
RW
14329 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no (suppressed because you are not using GCC)" >&5
14330$as_echo "no (suppressed because you are not using GCC)" >&6; }
c906108c
SS
14331 fi
14332 else
81ecdfbb
RW
14333 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14334$as_echo "no" >&6; }
c906108c
SS
14335 fi
14336 ;;
14337 solaris*)
d92419e5
JB
14338 # See if thread_db library is around for Solaris thread debugging.
14339 # Note that we must explicitly test for version 1 of the library
14340 # because version 0 (present on Solaris 2.4 or earlier) doesn't have
14341 # the same API.
81ecdfbb
RW
14342 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Solaris thread debugging library" >&5
14343$as_echo_n "checking for Solaris thread debugging library... " >&6; }
c906108c 14344 if test -f /usr/lib/libthread_db.so.1 ; then
81ecdfbb
RW
14345 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14346$as_echo "yes" >&6; }
60ca704f 14347
81ecdfbb 14348$as_echo "#define HAVE_THREAD_DB_LIB 1" >>confdefs.h
c906108c 14349
3483b318 14350 CONFIG_OBS="${CONFIG_OBS} sol-thread.o"
c906108c 14351 CONFIG_SRCS="${CONFIG_SRCS} sol-thread.c"
81ecdfbb
RW
14352 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
14353$as_echo_n "checking for dlopen in -ldl... " >&6; }
14354if test "${ac_cv_lib_dl_dlopen+set}" = set; then :
14355 $as_echo_n "(cached) " >&6
c906108c 14356else
bec39cab 14357 ac_check_lib_save_LIBS=$LIBS
c906108c 14358LIBS="-ldl $LIBS"
81ecdfbb 14359cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab
AC
14360/* end confdefs.h. */
14361
81ecdfbb
RW
14362/* Override any GCC internal prototype to avoid an error.
14363 Use char because int might match the return type of a GCC
14364 builtin and then its argument prototype would still apply. */
bec39cab
AC
14365#ifdef __cplusplus
14366extern "C"
14367#endif
bec39cab
AC
14368char dlopen ();
14369int
14370main ()
14371{
81ecdfbb 14372return dlopen ();
bec39cab
AC
14373 ;
14374 return 0;
14375}
14376_ACEOF
81ecdfbb 14377if ac_fn_c_try_link "$LINENO"; then :
bec39cab
AC
14378 ac_cv_lib_dl_dlopen=yes
14379else
81ecdfbb 14380 ac_cv_lib_dl_dlopen=no
bec39cab 14381fi
81ecdfbb
RW
14382rm -f core conftest.err conftest.$ac_objext \
14383 conftest$ac_exeext conftest.$ac_ext
bec39cab
AC
14384LIBS=$ac_check_lib_save_LIBS
14385fi
81ecdfbb
RW
14386{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
14387$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
14388if test "x$ac_cv_lib_dl_dlopen" = x""yes; then :
bec39cab
AC
14389 cat >>confdefs.h <<_ACEOF
14390#define HAVE_LIBDL 1
14391_ACEOF
c906108c
SS
14392
14393 LIBS="-ldl $LIBS"
14394
c906108c
SS
14395fi
14396
f6528abd 14397 CONFIG_LDFLAGS="${CONFIG_LDFLAGS} $RDYNAMIC"
c906108c
SS
14398 # Sun randomly tweaked the prototypes in <proc_service.h>
14399 # at one point.
81ecdfbb
RW
14400 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if <proc_service.h> is old" >&5
14401$as_echo_n "checking if <proc_service.h> is old... " >&6; }
14402 if test "${gdb_cv_proc_service_is_old+set}" = set; then :
14403 $as_echo_n "(cached) " >&6
c906108c 14404else
bec39cab 14405
81ecdfbb 14406 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 14407/* end confdefs.h. */
c906108c
SS
14408
14409 #include <proc_service.h>
14410 ps_err_e ps_pdwrite
14411 (struct ps_prochandle*, psaddr_t, const void*, size_t);
c906108c 14412
bec39cab
AC
14413int
14414main ()
14415{
14416
14417 ;
14418 return 0;
14419}
14420_ACEOF
81ecdfbb 14421if ac_fn_c_try_compile "$LINENO"; then :
c906108c
SS
14422 gdb_cv_proc_service_is_old=no
14423else
81ecdfbb 14424 gdb_cv_proc_service_is_old=yes
c906108c 14425fi
81ecdfbb 14426rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
bec39cab 14427
c906108c
SS
14428fi
14429
81ecdfbb
RW
14430 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_proc_service_is_old" >&5
14431$as_echo "$gdb_cv_proc_service_is_old" >&6; }
c906108c 14432 if test $gdb_cv_proc_service_is_old = yes; then
60ca704f 14433
81ecdfbb 14434$as_echo "#define PROC_SERVICE_IS_OLD 1" >>confdefs.h
c906108c
SS
14435
14436 fi
14437 else
81ecdfbb
RW
14438 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14439$as_echo "no" >&6; }
c906108c
SS
14440 fi
14441 ;;
d92419e5 14442 aix*)
81ecdfbb
RW
14443 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AiX thread debugging library" >&5
14444$as_echo_n "checking for AiX thread debugging library... " >&6; }
14445 if test "${gdb_cv_have_aix_thread_debug+set}" = set; then :
14446 $as_echo_n "(cached) " >&6
bec39cab 14447else
81ecdfbb 14448 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 14449/* end confdefs.h. */
d92419e5 14450#include <sys/pthdebug.h>
bec39cab
AC
14451int
14452main ()
14453{
d92419e5
JB
14454#ifndef PTHDB_VERSION_3
14455 #error
14456 #endif
bec39cab
AC
14457 ;
14458 return 0;
14459}
14460_ACEOF
81ecdfbb 14461if ac_fn_c_try_compile "$LINENO"; then :
d92419e5
JB
14462 gdb_cv_have_aix_thread_debug=yes
14463else
81ecdfbb 14464 gdb_cv_have_aix_thread_debug=no
d92419e5 14465fi
81ecdfbb 14466rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
d92419e5
JB
14467fi
14468
81ecdfbb
RW
14469 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_aix_thread_debug" >&5
14470$as_echo "$gdb_cv_have_aix_thread_debug" >&6; }
d92419e5
JB
14471 if test $gdb_cv_have_aix_thread_debug = yes; then
14472 CONFIG_SRCS="${CONFIG_SRCS} aix-thread.c"
3483b318 14473 CONFIG_OBS="${CONFIG_OBS} aix-thread.o"
d92419e5
JB
14474 CONFIG_LDFLAGS="${CONFIG_LDFLAGS} -lpthdebug"
14475 fi
14476 ;;
c906108c 14477 esac
bec39cab 14478
c906108c
SS
14479fi
14480
3f47be5c 14481if test "x$ac_cv_header_thread_db_h" = "xyes"; then
81ecdfbb
RW
14482 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <thread_db.h> has TD_NOTALLOC" >&5
14483$as_echo_n "checking whether <thread_db.h> has TD_NOTALLOC... " >&6; }
14484if test "${gdb_cv_thread_db_h_has_td_notalloc+set}" = set; then :
14485 $as_echo_n "(cached) " >&6
bec39cab 14486else
81ecdfbb 14487 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 14488/* end confdefs.h. */
3f47be5c 14489#include <thread_db.h>
bec39cab
AC
14490int
14491main ()
14492{
3f47be5c 14493int i = TD_NOTALLOC;
bec39cab
AC
14494 ;
14495 return 0;
14496}
14497_ACEOF
81ecdfbb 14498if ac_fn_c_try_compile "$LINENO"; then :
3f47be5c
EZ
14499 gdb_cv_thread_db_h_has_td_notalloc=yes
14500else
81ecdfbb 14501 gdb_cv_thread_db_h_has_td_notalloc=no
bec39cab 14502
3f47be5c 14503fi
81ecdfbb 14504rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3f47be5c 14505
bec39cab 14506fi
81ecdfbb
RW
14507{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_thread_db_h_has_td_notalloc" >&5
14508$as_echo "$gdb_cv_thread_db_h_has_td_notalloc" >&6; }
14509 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <thread_db.h> has TD_VERSION" >&5
14510$as_echo_n "checking whether <thread_db.h> has TD_VERSION... " >&6; }
14511if test "${gdb_cv_thread_db_h_has_td_version+set}" = set; then :
14512 $as_echo_n "(cached) " >&6
59f80f10 14513else
81ecdfbb 14514 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
59f80f10
DJ
14515/* end confdefs.h. */
14516#include <thread_db.h>
14517int
14518main ()
14519{
14520int i = TD_VERSION;
14521 ;
14522 return 0;
14523}
14524_ACEOF
81ecdfbb 14525if ac_fn_c_try_compile "$LINENO"; then :
59f80f10
DJ
14526 gdb_cv_thread_db_h_has_td_version=yes
14527else
81ecdfbb 14528 gdb_cv_thread_db_h_has_td_version=no
59f80f10
DJ
14529
14530fi
81ecdfbb 14531rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
59f80f10
DJ
14532
14533fi
81ecdfbb
RW
14534{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_thread_db_h_has_td_version" >&5
14535$as_echo "$gdb_cv_thread_db_h_has_td_version" >&6; }
14536 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <thread_db.h> has TD_NOTLS" >&5
14537$as_echo_n "checking whether <thread_db.h> has TD_NOTLS... " >&6; }
14538if test "${gdb_cv_thread_db_h_has_td_notls+set}" = set; then :
14539 $as_echo_n "(cached) " >&6
59f80f10 14540else
81ecdfbb 14541 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
59f80f10
DJ
14542/* end confdefs.h. */
14543#include <thread_db.h>
14544int
14545main ()
14546{
14547int i = TD_NOTLS;
14548 ;
14549 return 0;
14550}
14551_ACEOF
81ecdfbb 14552if ac_fn_c_try_compile "$LINENO"; then :
59f80f10
DJ
14553 gdb_cv_thread_db_h_has_td_notls=yes
14554else
81ecdfbb 14555 gdb_cv_thread_db_h_has_td_notls=no
59f80f10
DJ
14556
14557fi
81ecdfbb 14558rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
59f80f10
DJ
14559
14560fi
81ecdfbb
RW
14561{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_thread_db_h_has_td_notls" >&5
14562$as_echo "$gdb_cv_thread_db_h_has_td_notls" >&6; }
3f47be5c
EZ
14563fi
14564if test "x$gdb_cv_thread_db_h_has_td_notalloc" = "xyes"; then
bec39cab 14565
81ecdfbb 14566$as_echo "#define THREAD_DB_HAS_TD_NOTALLOC 1" >>confdefs.h
3f47be5c 14567
59f80f10
DJ
14568fi
14569if test "x$gdb_cv_thread_db_h_has_td_version" = "xyes"; then
14570
81ecdfbb 14571$as_echo "#define THREAD_DB_HAS_TD_VERSION 1" >>confdefs.h
59f80f10
DJ
14572
14573fi
14574if test "x$gdb_cv_thread_db_h_has_td_notls" = "xyes"; then
14575
81ecdfbb 14576$as_echo "#define THREAD_DB_HAS_TD_NOTLS 1" >>confdefs.h
59f80f10 14577
3f47be5c
EZ
14578fi
14579
b757528f 14580if test "x$ac_cv_header_sys_syscall_h" = "xyes"; then
81ecdfbb
RW
14581 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/syscall.h> has __NR_tkill" >&5
14582$as_echo_n "checking whether <sys/syscall.h> has __NR_tkill... " >&6; }
14583if test "${gdb_cv_sys_syscall_h_has_tkill+set}" = set; then :
14584 $as_echo_n "(cached) " >&6
bec39cab 14585else
81ecdfbb 14586 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 14587/* end confdefs.h. */
b757528f 14588#include <sys/syscall.h>
bec39cab
AC
14589int
14590main ()
14591{
b757528f 14592int i = __NR_tkill;
bec39cab
AC
14593 ;
14594 return 0;
14595}
14596_ACEOF
81ecdfbb 14597if ac_fn_c_try_compile "$LINENO"; then :
b757528f
JJ
14598 gdb_cv_sys_syscall_h_has_tkill=yes
14599else
81ecdfbb 14600 gdb_cv_sys_syscall_h_has_tkill=no
bec39cab 14601
b757528f 14602fi
81ecdfbb 14603rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
b757528f 14604
bec39cab 14605fi
81ecdfbb
RW
14606{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_sys_syscall_h_has_tkill" >&5
14607$as_echo "$gdb_cv_sys_syscall_h_has_tkill" >&6; }
b757528f
JJ
14608fi
14609if test "x$gdb_cv_sys_syscall_h_has_tkill" = "xyes" && test "x$ac_cv_func_syscall" = "xyes"; then
bec39cab 14610
81ecdfbb 14611$as_echo "#define HAVE_TKILL_SYSCALL 1" >>confdefs.h
b757528f
JJ
14612
14613fi
14614
81ecdfbb
RW
14615ac_fn_c_check_decl "$LINENO" "ADDR_NO_RANDOMIZE" "ac_cv_have_decl_ADDR_NO_RANDOMIZE" "#include <sys/personality.h>
14616"
14617if test "x$ac_cv_have_decl_ADDR_NO_RANDOMIZE" = x""yes; then :
14618 ac_have_decl=1
10568435 14619else
81ecdfbb 14620 ac_have_decl=0
10568435 14621fi
10568435
JK
14622
14623cat >>confdefs.h <<_ACEOF
81ecdfbb 14624#define HAVE_DECL_ADDR_NO_RANDOMIZE $ac_have_decl
10568435
JK
14625_ACEOF
14626
14627
81ecdfbb
RW
14628if test "$cross_compiling" = yes; then :
14629 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10568435
JK
14630/* end confdefs.h. */
14631#include <sys/personality.h>
14632int
14633main ()
14634{
14635
14636# if !HAVE_DECL_ADDR_NO_RANDOMIZE
14637# define ADDR_NO_RANDOMIZE 0x0040000
14638# endif
14639 /* Test the flag could be set and stays set. */
14640 personality (personality (0xffffffff) | ADDR_NO_RANDOMIZE);
14641 if (!(personality (personality (0xffffffff)) & ADDR_NO_RANDOMIZE))
14642 return 1
14643 ;
14644 return 0;
14645}
14646_ACEOF
81ecdfbb 14647if ac_fn_c_try_link "$LINENO"; then :
10568435
JK
14648 have_personality=true
14649else
81ecdfbb 14650 have_personality=false
10568435 14651fi
81ecdfbb
RW
14652rm -f core conftest.err conftest.$ac_objext \
14653 conftest$ac_exeext conftest.$ac_ext
10568435 14654else
81ecdfbb 14655 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10568435
JK
14656/* end confdefs.h. */
14657#include <sys/personality.h>
14658int
14659main ()
14660{
14661
14662# if !HAVE_DECL_ADDR_NO_RANDOMIZE
14663# define ADDR_NO_RANDOMIZE 0x0040000
14664# endif
14665 /* Test the flag could be set and stays set. */
14666 personality (personality (0xffffffff) | ADDR_NO_RANDOMIZE);
14667 if (!(personality (personality (0xffffffff)) & ADDR_NO_RANDOMIZE))
14668 return 1
14669 ;
14670 return 0;
14671}
14672_ACEOF
81ecdfbb 14673if ac_fn_c_try_run "$LINENO"; then :
10568435
JK
14674 have_personality=true
14675else
81ecdfbb 14676 have_personality=false
10568435 14677fi
81ecdfbb
RW
14678rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14679 conftest.$ac_objext conftest.beam conftest.$ac_ext
10568435 14680fi
81ecdfbb 14681
10568435
JK
14682if $have_personality
14683then
14684
81ecdfbb 14685$as_echo "#define HAVE_PERSONALITY 1" >>confdefs.h
10568435
JK
14686
14687fi
14688
fb40c209 14689
b14b1491 14690target_sysroot_reloc=0
bec39cab 14691
81ecdfbb
RW
14692# Check whether --with-sysroot was given.
14693if test "${with_sysroot+set}" = set; then :
14694 withval=$with_sysroot;
030292b7 14695 case ${with_sysroot} in
715d1656 14696 yes) TARGET_SYSTEM_ROOT='${exec_prefix}/${target_alias}/sys-root' ;;
030292b7
DJ
14697 *) TARGET_SYSTEM_ROOT=$with_sysroot ;;
14698 esac
14699
14700 TARGET_SYSTEM_ROOT_DEFINE='-DTARGET_SYSTEM_ROOT=\"$(TARGET_SYSTEM_ROOT)\"'
14701
07abfebf
RS
14702 if test "x$prefix" = xNONE; then
14703 test_prefix=/usr/local
14704 else
14705 test_prefix=$prefix
14706 fi
aa28a74e 14707 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
07abfebf 14708 test_exec_prefix=$test_prefix
030292b7 14709 else
07abfebf 14710 test_exec_prefix=$exec_prefix
030292b7
DJ
14711 fi
14712 case ${TARGET_SYSTEM_ROOT} in
715d1656 14713 "${test_prefix}"|"${test_prefix}/"*|\
07abfebf
RS
14714 "${test_exec_prefix}"|"${test_exec_prefix}/"*|\
14715 '${prefix}'|'${prefix}/'*|\
715d1656 14716 '${exec_prefix}'|'${exec_prefix}/'*)
b14b1491 14717 target_sysroot_reloc=1
030292b7
DJ
14718 ;;
14719 esac
14720
14721else
bec39cab 14722
030292b7
DJ
14723 TARGET_SYSTEM_ROOT=
14724 TARGET_SYSTEM_ROOT_DEFINE='-DTARGET_SYSTEM_ROOT=\"\"'
14725
81ecdfbb 14726fi
b14b1491 14727
81ecdfbb 14728TARGET_SYSTEM_ROOT_DEFINE="$TARGET_SYSTEM_ROOT_DEFINE -DTARGET_SYSTEM_ROOT_RELOCATABLE=$target_sysroot_reloc"
030292b7
DJ
14729
14730
14731
16e7150e 14732
16e7150e 14733
81ecdfbb
RW
14734# Check whether --with-system-gdbinit was given.
14735if test "${with_system_gdbinit+set}" = set; then :
14736 withval=$with_system_gdbinit;
b14b1491
TT
14737 SYSTEM_GDBINIT=$withval
14738else
14739 SYSTEM_GDBINIT=
81ecdfbb
RW
14740fi
14741
16e7150e
JG
14742
14743 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
14744 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
b14b1491 14745 ac_define_dir=`eval echo $SYSTEM_GDBINIT`
16e7150e
JG
14746 ac_define_dir=`eval echo $ac_define_dir`
14747
14748cat >>confdefs.h <<_ACEOF
14749#define SYSTEM_GDBINIT "$ac_define_dir"
14750_ACEOF
14751
14752
14753
0c4a4063 14754
b14b1491
TT
14755 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
14756 if test "x$prefix" = xNONE; then
14757 test_prefix=/usr/local
14758 else
14759 test_prefix=$prefix
14760 fi
14761 else
14762 test_prefix=$exec_prefix
14763 fi
14764 value=0
14765 case ${ac_define_dir} in
14766 "${test_prefix}"|"${test_prefix}/"*|\
14767 '${exec_prefix}'|'${exec_prefix}/'*)
14768 value=1
14769 ;;
14770 esac
16e7150e 14771
b14b1491
TT
14772cat >>confdefs.h <<_ACEOF
14773#define SYSTEM_GDBINIT_RELOCATABLE $value
16e7150e
JG
14774_ACEOF
14775
b14b1491 14776
16e7150e 14777
0c4a4063 14778
81ecdfbb
RW
14779# Check whether --enable-werror was given.
14780if test "${enable_werror+set}" = set; then :
14781 enableval=$enable_werror; case "${enableval}" in
094a342e
MK
14782 yes | y) ERROR_ON_WARNING="yes" ;;
14783 no | n) ERROR_ON_WARNING="no" ;;
81ecdfbb 14784 *) as_fn_error "bad value ${enableval} for --enable-werror" "$LINENO" 5 ;;
094a342e 14785 esac
81ecdfbb
RW
14786fi
14787
094a342e
MK
14788
14789# Enable -Werror by default when using gcc
14790if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" ; then
14791 ERROR_ON_WARNING=yes
14792fi
14793
14794WERROR_CFLAGS=""
14795if test "${ERROR_ON_WARNING}" = yes ; then
14796 WERROR_CFLAGS="-Werror"
14797fi
14798
aa79a185
DJ
14799# The entries after -Wno-pointer-sign are disabled warnings which may
14800# be enabled in the future, which can not currently be used to build
14801# GDB.
14802# NOTE: If you change this list, remember to update
3b851bce 14803# gdb/doc/gdbint.texinfo.
aa79a185
DJ
14804build_warnings="-Wall -Wdeclaration-after-statement -Wpointer-arith \
14805-Wformat-nonliteral -Wno-pointer-sign \
1cb5e2a4
JB
14806-Wno-unused -Wunused-value -Wunused-function \
14807-Wno-switch -Wno-char-subscripts"
a3b362c4 14808
3526781e
DJ
14809# Enable -Wno-format by default when using gcc on mingw since many
14810# GCC versions complain about %I64.
14811case "${host}" in
14812 *-*-mingw32*) build_warnings="$build_warnings -Wno-format" ;;
14813esac
14814
81ecdfbb
RW
14815# Check whether --enable-build-warnings was given.
14816if test "${enable_build_warnings+set}" = set; then :
14817 enableval=$enable_build_warnings; case "${enableval}" in
c906108c
SS
14818 yes) ;;
14819 no) build_warnings="-w";;
14820 ,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
14821 build_warnings="${build_warnings} ${t}";;
14822 *,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
14823 build_warnings="${t} ${build_warnings}";;
14824 *) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
14825esac
d4f3574e 14826if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
746a987d 14827 echo "Setting compiler warning flags = $build_warnings" 6>&1
c906108c 14828fi
81ecdfbb
RW
14829fi
14830# Check whether --enable-gdb-build-warnings was given.
14831if test "${enable_gdb_build_warnings+set}" = set; then :
14832 enableval=$enable_gdb_build_warnings; case "${enableval}" in
3b851bce
AC
14833 yes) ;;
14834 no) build_warnings="-w";;
14835 ,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
14836 build_warnings="${build_warnings} ${t}";;
14837 *,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
14838 build_warnings="${t} ${build_warnings}";;
14839 *) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
14840esac
14841if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
14842 echo "Setting GDB specific compiler warning flags = $build_warnings" 6>&1
14843fi
81ecdfbb
RW
14844fi
14845WARN_CFLAGS=""
c906108c
SS
14846if test "x${build_warnings}" != x -a "x$GCC" = xyes
14847then
81ecdfbb
RW
14848 { $as_echo "$as_me:${as_lineno-$LINENO}: checking compiler warning flags" >&5
14849$as_echo_n "checking compiler warning flags... " >&6; }
746a987d
AC
14850 # Separate out the -Werror flag as some files just cannot be
14851 # compiled with it enabled.
14852 for w in ${build_warnings}; do
14853 case $w in
14854 -Werr*) WERROR_CFLAGS=-Werror ;;
14855 *) # Check that GCC accepts it
4536bbc6
AC
14856 saved_CFLAGS="$CFLAGS"
14857 CFLAGS="$CFLAGS $w"
81ecdfbb 14858 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 14859/* end confdefs.h. */
4536bbc6 14860
bec39cab
AC
14861int
14862main ()
14863{
4536bbc6 14864
bec39cab
AC
14865 ;
14866 return 0;
14867}
14868_ACEOF
81ecdfbb 14869if ac_fn_c_try_compile "$LINENO"; then :
4536bbc6 14870 WARN_CFLAGS="${WARN_CFLAGS} $w"
4536bbc6 14871fi
81ecdfbb 14872rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4536bbc6 14873 CFLAGS="$saved_CFLAGS"
746a987d
AC
14874 esac
14875 done
81ecdfbb
RW
14876 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${WARN_CFLAGS} ${WERROR_CFLAGS}" >&5
14877$as_echo "${WARN_CFLAGS} ${WERROR_CFLAGS}" >&6; }
c906108c
SS
14878fi
14879
14880
104c1213 14881
7a292a7a 14882# In the Cygwin environment, we need some additional flags.
81ecdfbb
RW
14883{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for cygwin" >&5
14884$as_echo_n "checking for cygwin... " >&6; }
14885if test "${gdb_cv_os_cygwin+set}" = set; then :
14886 $as_echo_n "(cached) " >&6
bec39cab 14887else
81ecdfbb 14888 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 14889/* end confdefs.h. */
7a292a7a
SS
14890
14891#if defined (__CYGWIN__) || defined (__CYGWIN32__)
14892lose
14893#endif
bec39cab 14894_ACEOF
7a292a7a 14895if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
81ecdfbb 14896 $EGREP "lose" >/dev/null 2>&1; then :
7a292a7a
SS
14897 gdb_cv_os_cygwin=yes
14898else
7a292a7a
SS
14899 gdb_cv_os_cygwin=no
14900fi
14901rm -f conftest*
14902
14903fi
81ecdfbb
RW
14904{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_os_cygwin" >&5
14905$as_echo "$gdb_cv_os_cygwin" >&6; }
7a292a7a 14906
aff38e61 14907
3eb25fda 14908SER_HARDWIRE="ser-base.o ser-unix.o ser-pipe.o ser-tcp.o"
aff38e61 14909case ${host} in
95cbc983
AC
14910 *go32* ) SER_HARDWIRE=ser-go32.o ;;
14911 *djgpp* ) SER_HARDWIRE=ser-go32.o ;;
0ea3f30e 14912 *mingw32*) SER_HARDWIRE="ser-base.o ser-tcp.o ser-mingw.o" ;;
aff38e61
AC
14913esac
14914
14915
cd0fc7c3
SS
14916# libreadline needs libuser32.a in a cygwin environment
14917WIN32LIBS=
14918if test x$gdb_cv_os_cygwin = xyes; then
c5394b80
JM
14919 WIN32LIBS="-luser32"
14920 case "${target}" in
14921 *cygwin*) WIN32LIBS="$WIN32LIBS -limagehlp"
14922 ;;
14923 esac
cd0fc7c3 14924fi
c906108c 14925
b4505029
MM
14926# The ser-tcp.c module requires sockets.
14927case ${host} in
14928 *mingw32*)
14929
81ecdfbb 14930$as_echo "#define USE_WIN32API 1" >>confdefs.h
b4505029
MM
14931
14932 WIN32LIBS="$WIN32LIBS -lws2_32"
14933 ;;
14934esac
14935
7a292a7a 14936
31d99776
DJ
14937# Add ELF support to GDB, but only if BFD includes ELF support.
14938OLD_CFLAGS=$CFLAGS
14939OLD_LDFLAGS=$LDFLAGS
14940OLD_LIBS=$LIBS
cab58a69 14941CFLAGS="$CFLAGS -I${srcdir}/../include -I../bfd -I${srcdir}/../bfd"
31d99776 14942LDFLAGS="$LDFLAGS -L../bfd -L../libiberty"
7b3200f9 14943intl=`echo $LIBINTL | sed 's,${top_builddir}/,,g'`
075ff26d
JK
14944# -ldl is provided by bfd/Makfile.am (LIBDL) <PLUGINS>.
14945if test "$plugins" = "yes"; then
14946 LIBS="-ldl $LIBS"
14947fi
0f72fb1c 14948LIBS="-lbfd -liberty $intl $LIBS"
81ecdfbb
RW
14949{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ELF support in BFD" >&5
14950$as_echo_n "checking for ELF support in BFD... " >&6; }
14951if test "${gdb_cv_var_elf+set}" = set; then :
14952 $as_echo_n "(cached) " >&6
31d99776 14953else
81ecdfbb 14954 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31d99776
DJ
14955/* end confdefs.h. */
14956#include <stdlib.h>
14957#include "bfd.h"
14958#include "elf-bfd.h"
14959
14960int
14961main ()
14962{
14963bfd *abfd = NULL; bfd_get_elf_phdr_upper_bound (abfd);
14964 ;
14965 return 0;
14966}
14967_ACEOF
81ecdfbb 14968if ac_fn_c_try_link "$LINENO"; then :
31d99776
DJ
14969 gdb_cv_var_elf=yes
14970else
81ecdfbb 14971 gdb_cv_var_elf=no
31d99776 14972fi
81ecdfbb
RW
14973rm -f core conftest.err conftest.$ac_objext \
14974 conftest$ac_exeext conftest.$ac_ext
31d99776 14975fi
81ecdfbb
RW
14976{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_var_elf" >&5
14977$as_echo "$gdb_cv_var_elf" >&6; }
31d99776
DJ
14978if test $gdb_cv_var_elf = yes; then
14979 CONFIG_OBS="$CONFIG_OBS elfread.o"
14980
81ecdfbb 14981$as_echo "#define HAVE_ELF 1" >>confdefs.h
31d99776 14982
075ff26d
JK
14983 # -ldl is provided by bfd/Makfile.am (LIBDL) <PLUGINS>.
14984 if test "$plugins" = "yes"; then
14985 OLD_LIBS="-ldl $OLD_LIBS"
14986 fi
31d99776
DJ
14987fi
14988CFLAGS=$OLD_CFLAGS
14989LDFLAGS=$OLD_LDFLAGS
14990LIBS=$OLD_LIBS
14991
121ce6e5
DJ
14992# Add any host-specific objects to GDB.
14993CONFIG_OBS="${CONFIG_OBS} ${gdb_host_obs}"
14994
3fc11d3e
JM
14995LIBGUI="../libgui/src/libgui.a"
14996GUI_CFLAGS_X="-I${srcdir}/../libgui/src"
14997
14998
7a292a7a 14999
3fc11d3e
JM
15000WIN32LDAPP=
15001
15002
15003
d91670b9 15004case "${host}" in
686a5eed 15005*-*-cygwin* | *-*-mingw* )
d91670b9
CV
15006 configdir="win"
15007 ;;
15008*)
15009 configdir="unix"
15010 ;;
15011esac
3fc11d3e
JM
15012
15013GDBTKLIBS=
15014if test "${enable_gdbtk}" = "yes"; then
15015
d1c3b63a
KS
15016 # Gdbtk must have an absolute path to srcdir in order to run
15017 # properly when not installed.
15018 here=`pwd`
15019 cd ${srcdir}
15020 GDBTK_SRC_DIR=`pwd`
15021 cd $here
15022
bec39cab 15023
5062cc19
KS
15024 #
15025 # Ok, lets find the tcl configuration
15026 # First, look for one uninstalled.
15027 # the alternative search directory is invoked by --with-tcl
15028 #
3fc11d3e 15029
5062cc19
KS
15030 if test x"${no_tcl}" = x ; then
15031 # we reset no_tcl in case something fails here
15032 no_tcl=true
bec39cab 15033
81ecdfbb
RW
15034# Check whether --with-tcl was given.
15035if test "${with_tcl+set}" = set; then :
15036 withval=$with_tcl; with_tclconfig=${withval}
15037fi
15038
15039 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Tcl configuration" >&5
15040$as_echo_n "checking for Tcl configuration... " >&6; }
15041 if test "${ac_cv_c_tclconfig+set}" = set; then :
15042 $as_echo_n "(cached) " >&6
3fc11d3e 15043else
bec39cab 15044
3fc11d3e 15045
5062cc19
KS
15046 # First check to see if --with-tcl was specified.
15047 case "${host}" in
15048 *-*-cygwin*) platDir="win" ;;
15049 *) platDir="unix" ;;
15050 esac
15051 if test x"${with_tclconfig}" != x ; then
15052 if test -f "${with_tclconfig}/tclConfig.sh" ; then
15053 ac_cv_c_tclconfig=`(cd ${with_tclconfig}; pwd)`
15054 else
81ecdfbb 15055 as_fn_error "${with_tclconfig} directory doesn't contain tclConfig.sh" "$LINENO" 5
5062cc19
KS
15056 fi
15057 fi
15058
15059 # then check for a private Tcl installation
15060 if test x"${ac_cv_c_tclconfig}" = x ; then
15061 for i in \
15062 ../tcl \
15063 `ls -dr ../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
15064 `ls -dr ../tcl[8-9].[0-9] 2>/dev/null` \
15065 `ls -dr ../tcl[8-9].[0-9]* 2>/dev/null` \
15066 ../../tcl \
15067 `ls -dr ../../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
15068 `ls -dr ../../tcl[8-9].[0-9] 2>/dev/null` \
15069 `ls -dr ../../tcl[8-9].[0-9]* 2>/dev/null` \
15070 ../../../tcl \
15071 `ls -dr ../../../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
15072 `ls -dr ../../../tcl[8-9].[0-9] 2>/dev/null` \
15073 `ls -dr ../../../tcl[8-9].[0-9]* 2>/dev/null` ; do
15074 if test -f "$i/$platDir/tclConfig.sh" ; then
15075 ac_cv_c_tclconfig=`(cd $i/$platDir; pwd)`
15076 break
15077 fi
15078 done
15079 fi
15080
15081 # on Darwin, check in Framework installation locations
15082 if test "`uname -s`" = "Darwin" -a x"${ac_cv_c_tclconfig}" = x ; then
15083 for i in `ls -d ~/Library/Frameworks 2>/dev/null` \
15084 `ls -d /Library/Frameworks 2>/dev/null` \
15085 `ls -d /Network/Library/Frameworks 2>/dev/null` \
15086 `ls -d /System/Library/Frameworks 2>/dev/null` \
15087 ; do
15088 if test -f "$i/Tcl.framework/tclConfig.sh" ; then
15089 ac_cv_c_tclconfig=`(cd $i/Tcl.framework; pwd)`
15090 break
15091 fi
15092 done
15093 fi
15094
15095 # check in a few common install locations
15096 if test x"${ac_cv_c_tclconfig}" = x ; then
15097 for i in `ls -d ${libdir} 2>/dev/null` \
15098 `ls -d ${exec_prefix}/lib 2>/dev/null` \
15099 `ls -d ${prefix}/lib 2>/dev/null` \
15100 `ls -d /usr/local/lib 2>/dev/null` \
15101 `ls -d /usr/contrib/lib 2>/dev/null` \
15102 `ls -d /usr/lib 2>/dev/null` \
15103 ; do
15104 if test -f "$i/tclConfig.sh" ; then
15105 ac_cv_c_tclconfig=`(cd $i; pwd)`
15106 break
15107 fi
15108 done
15109 fi
3fc11d3e 15110
5062cc19
KS
15111 # check in a few other private locations
15112 if test x"${ac_cv_c_tclconfig}" = x ; then
15113 for i in \
15114 ${srcdir}/../tcl \
15115 `ls -dr ${srcdir}/../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
15116 `ls -dr ${srcdir}/../tcl[8-9].[0-9] 2>/dev/null` \
15117 `ls -dr ${srcdir}/../tcl[8-9].[0-9]* 2>/dev/null` ; do
15118 if test -f "$i/$platDir/tclConfig.sh" ; then
15119 ac_cv_c_tclconfig=`(cd $i/$platDir; pwd)`
15120 break
15121 fi
15122 done
15123 fi
bec39cab 15124
3fc11d3e
JM
15125fi
15126
5062cc19
KS
15127
15128 if test x"${ac_cv_c_tclconfig}" = x ; then
15129 TCL_BIN_DIR="# no Tcl configs found"
81ecdfbb
RW
15130 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Can't find Tcl configuration definitions" >&5
15131$as_echo "$as_me: WARNING: Can't find Tcl configuration definitions" >&2;}
5062cc19
KS
15132 else
15133 no_tcl=
15134 TCL_BIN_DIR=${ac_cv_c_tclconfig}
81ecdfbb
RW
15135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found ${TCL_BIN_DIR}/tclConfig.sh" >&5
15136$as_echo "found ${TCL_BIN_DIR}/tclConfig.sh" >&6; }
5062cc19
KS
15137 fi
15138 fi
3fc11d3e 15139
bec39cab 15140
85541719
DE
15141 # If $no_tk is nonempty, then we can't do Tk, and there is no
15142 # point to doing Tcl.
bec39cab 15143
5062cc19
KS
15144 #
15145 # Ok, lets find the tk configuration
15146 # First, look for one uninstalled.
15147 # the alternative search directory is invoked by --with-tk
15148 #
3fc11d3e 15149
5062cc19
KS
15150 if test x"${no_tk}" = x ; then
15151 # we reset no_tk in case something fails here
15152 no_tk=true
bec39cab 15153
81ecdfbb
RW
15154# Check whether --with-tk was given.
15155if test "${with_tk+set}" = set; then :
15156 withval=$with_tk; with_tkconfig=${withval}
15157fi
15158
15159 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Tk configuration" >&5
15160$as_echo_n "checking for Tk configuration... " >&6; }
15161 if test "${ac_cv_c_tkconfig+set}" = set; then :
15162 $as_echo_n "(cached) " >&6
bec39cab 15163else
3fc11d3e
JM
15164
15165
5062cc19
KS
15166 # First check to see if --with-tkconfig was specified.
15167 if test x"${with_tkconfig}" != x ; then
15168 if test -f "${with_tkconfig}/tkConfig.sh" ; then
15169 ac_cv_c_tkconfig=`(cd ${with_tkconfig}; pwd)`
15170 else
81ecdfbb 15171 as_fn_error "${with_tkconfig} directory doesn't contain tkConfig.sh" "$LINENO" 5
5062cc19
KS
15172 fi
15173 fi
3fc11d3e 15174
5062cc19
KS
15175 # then check for a private Tk library
15176 case "${host}" in
15177 *-*-cygwin*) platDir="win" ;;
15178 *) platDir="unix" ;;
15179 esac
15180 if test x"${ac_cv_c_tkconfig}" = x ; then
15181 for i in \
15182 ../tk \
15183 `ls -dr ../tk[8-9].[0-9].[0-9]* 2>/dev/null` \
15184 `ls -dr ../tk[8-9].[0-9] 2>/dev/null` \
15185 `ls -dr ../tk[8-9].[0-9]* 2>/dev/null` \
15186 ../../tk \
15187 `ls -dr ../../tk[8-9].[0-9].[0-9]* 2>/dev/null` \
15188 `ls -dr ../../tk[8-9].[0-9] 2>/dev/null` \
15189 `ls -dr ../../tk[8-9].[0-9]* 2>/dev/null` \
15190 ../../../tk \
15191 `ls -dr ../../../tk[8-9].[0-9].[0-9]* 2>/dev/null` \
15192 `ls -dr ../../../tk[8-9].[0-9] 2>/dev/null` \
15193 `ls -dr ../../../tk[8-9].[0-9]* 2>/dev/null` ; do
15194 if test -f "$i/$platDir/tkConfig.sh" ; then
15195 ac_cv_c_tkconfig=`(cd $i/$platDir; pwd)`
15196 break
15197 fi
15198 done
15199 fi
15200
15201 # on Darwin, check in Framework installation locations
15202 if test "`uname -s`" = "Darwin" -a x"${ac_cv_c_tkconfig}" = x ; then
15203 for i in `ls -d ~/Library/Frameworks 2>/dev/null` \
15204 `ls -d /Library/Frameworks 2>/dev/null` \
15205 `ls -d /Network/Library/Frameworks 2>/dev/null` \
15206 `ls -d /System/Library/Frameworks 2>/dev/null` \
15207 ; do
15208 if test -f "$i/Tk.framework/tkConfig.sh" ; then
15209 ac_cv_c_tkconfig=`(cd $i/Tk.framework; pwd)`
15210 break
15211 fi
15212 done
15213 fi
15214
15215 # check in a few common install locations
15216 if test x"${ac_cv_c_tkconfig}" = x ; then
15217 for i in `ls -d ${libdir} 2>/dev/null` \
15218 `ls -d ${exec_prefix}/lib 2>/dev/null` \
15219 `ls -d ${prefix}/lib 2>/dev/null` \
15220 `ls -d /usr/local/lib 2>/dev/null` \
15221 `ls -d /usr/contrib/lib 2>/dev/null` \
15222 `ls -d /usr/lib 2>/dev/null` \
15223 ; do
15224 if test -f "$i/tkConfig.sh" ; then
15225 ac_cv_c_tkconfig=`(cd $i; pwd)`
15226 break
15227 fi
15228 done
15229 fi
15230 # check in a few other private locations
15231 if test x"${ac_cv_c_tkconfig}" = x ; then
15232 for i in \
15233 ${srcdir}/../tk \
15234 `ls -dr ${srcdir}/../tk[8-9].[0-9].[0-9]* 2>/dev/null` \
15235 `ls -dr ${srcdir}/../tk[8-9].[0-9] 2>/dev/null` \
15236 `ls -dr ${srcdir}/../tk[8-9].[0-9]* 2>/dev/null` ; do
15237 if test -f "$i/$platDir/tkConfig.sh" ; then
15238 ac_cv_c_tkconfig=`(cd $i/$platDir; pwd)`
15239 break
15240 fi
15241 done
15242 fi
3fc11d3e 15243
3fc11d3e
JM
15244fi
15245
15246
5062cc19
KS
15247 if test x"${ac_cv_c_tkconfig}" = x ; then
15248 TK_BIN_DIR="# no Tk configs found"
81ecdfbb
RW
15249 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Can't find Tk configuration definitions" >&5
15250$as_echo "$as_me: WARNING: Can't find Tk configuration definitions" >&2;}
5062cc19
KS
15251 else
15252 no_tk=
15253 TK_BIN_DIR=${ac_cv_c_tkconfig}
81ecdfbb
RW
15254 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found ${TK_BIN_DIR}/tkConfig.sh" >&5
15255$as_echo "found ${TK_BIN_DIR}/tkConfig.sh" >&6; }
5062cc19 15256 fi
3fc11d3e 15257 fi
dd2504ab 15258
dd2504ab 15259
85541719
DE
15260 if test -z "${no_tcl}" -a -z "${no_tk}"; then
15261
81ecdfbb
RW
15262 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for existence of ${TCL_BIN_DIR}/tclConfig.sh" >&5
15263$as_echo_n "checking for existence of ${TCL_BIN_DIR}/tclConfig.sh... " >&6; }
85541719
DE
15264
15265 if test -f "${TCL_BIN_DIR}/tclConfig.sh" ; then
81ecdfbb
RW
15266 { $as_echo "$as_me:${as_lineno-$LINENO}: result: loading" >&5
15267$as_echo "loading" >&6; }
85541719
DE
15268 . ${TCL_BIN_DIR}/tclConfig.sh
15269 else
81ecdfbb
RW
15270 { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not find ${TCL_BIN_DIR}/tclConfig.sh" >&5
15271$as_echo "could not find ${TCL_BIN_DIR}/tclConfig.sh" >&6; }
85541719
DE
15272 fi
15273
15274 # eval is required to do the TCL_DBGX substitution
15275 eval "TCL_LIB_FILE=\"${TCL_LIB_FILE}\""
15276 eval "TCL_STUB_LIB_FILE=\"${TCL_STUB_LIB_FILE}\""
15277
15278 # If the TCL_BIN_DIR is the build directory (not the install directory),
15279 # then set the common variable name to the value of the build variables.
15280 # For example, the variable TCL_LIB_SPEC will be set to the value
15281 # of TCL_BUILD_LIB_SPEC. An extension should make use of TCL_LIB_SPEC
15282 # instead of TCL_BUILD_LIB_SPEC since it will work with both an
15283 # installed and uninstalled version of Tcl.
15284 if test -f "${TCL_BIN_DIR}/Makefile" ; then
15285 TCL_LIB_SPEC=${TCL_BUILD_LIB_SPEC}
15286 TCL_STUB_LIB_SPEC=${TCL_BUILD_STUB_LIB_SPEC}
15287 TCL_STUB_LIB_PATH=${TCL_BUILD_STUB_LIB_PATH}
15288 elif test "`uname -s`" = "Darwin"; then
15289 # If Tcl was built as a framework, attempt to use the libraries
15290 # from the framework at the given location so that linking works
15291 # against Tcl.framework installed in an arbitary location.
15292 case ${TCL_DEFS} in
15293 *TCL_FRAMEWORK*)
15294 if test -f "${TCL_BIN_DIR}/${TCL_LIB_FILE}"; then
15295 for i in "`cd ${TCL_BIN_DIR}; pwd`" \
15296 "`cd ${TCL_BIN_DIR}/../..; pwd`"; do
15297 if test "`basename "$i"`" = "${TCL_LIB_FILE}.framework"; then
15298 TCL_LIB_SPEC="-F`dirname "$i"` -framework ${TCL_LIB_FILE}"
15299 break
15300 fi
15301 done
15302 fi
15303 if test -f "${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}"; then
15304 TCL_STUB_LIB_SPEC="-L${TCL_BIN_DIR} ${TCL_STUB_LIB_FLAG}"
15305 TCL_STUB_LIB_PATH="${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}"
15306 fi
15307 ;;
15308 esac
15309 fi
15310
15311 # eval is required to do the TCL_DBGX substitution
15312 eval "TCL_LIB_FLAG=\"${TCL_LIB_FLAG}\""
15313 eval "TCL_LIB_SPEC=\"${TCL_LIB_SPEC}\""
15314 eval "TCL_STUB_LIB_FLAG=\"${TCL_STUB_LIB_FLAG}\""
15315 eval "TCL_STUB_LIB_SPEC=\"${TCL_STUB_LIB_SPEC}\""
15316
15317
15318
15319
15320
15321
15322
15323
15324
15325
15326
15327
15328
15329
15330
15331 # Check for in-tree tcl
15332 here=`pwd`
15333 cd ${srcdir}/..
15334 topdir=`pwd`
15335 cd ${here}
15336
15337 intree="no"
15338 if test "${TCL_SRC_DIR}" = "${topdir}/tcl"; then
15339 intree="yes"
15340 fi
15341
15342 # Find Tcl private headers
15343 if test x"${intree}" = xno; then
15344
81ecdfbb
RW
15345 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Tcl private headers" >&5
15346$as_echo_n "checking for Tcl private headers... " >&6; }
85541719
DE
15347 private_dir=""
15348 dir=`echo ${TCL_INCLUDE_SPEC}/tcl-private/generic | sed -e s/-I//`
15349 if test -f ${dir}/tclInt.h ; then
15350 private_dir=${dir}
15351 fi
15352
15353 if test x"${private_dir}" = x; then
81ecdfbb 15354 as_fn_error "could not find private Tcl headers" "$LINENO" 5
85541719
DE
15355 else
15356 TCL_PRIVATE_INCLUDE="-I${private_dir}"
81ecdfbb
RW
15357 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${private_dir}" >&5
15358$as_echo "${private_dir}" >&6; }
85541719
DE
15359 fi
15360
15361 TCL_INCLUDE="${TCL_INCLUDE_SPEC} ${TCL_PRIVATE_INCLUDE}"
15362 TCL_LIBRARY="${TCL_LIB_SPEC}"
15363 TCL_DEPS=""
15364 else
15365 # If building tcl in the same src tree, private headers
15366 # are not needed, but we need to be sure to use the right
15367 # headers library
15368 TCL_INCLUDE="-I${TCL_SRC_DIR}/generic"
15369 TCL_LIBRARY="${TCL_BUILD_LIB_SPEC}"
15370 TCL_DEPS="../tcl/${configdir}${TCL_LIB_FILE}"
15371 fi
15372
15373
15374
15375
15376
81ecdfbb
RW
15377 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for existence of ${TK_BIN_DIR}/tkConfig.sh" >&5
15378$as_echo_n "checking for existence of ${TK_BIN_DIR}/tkConfig.sh... " >&6; }
dd2504ab 15379
5062cc19 15380 if test -f "${TK_BIN_DIR}/tkConfig.sh" ; then
81ecdfbb
RW
15381 { $as_echo "$as_me:${as_lineno-$LINENO}: result: loading" >&5
15382$as_echo "loading" >&6; }
5062cc19 15383 . ${TK_BIN_DIR}/tkConfig.sh
3fc11d3e 15384 else
81ecdfbb
RW
15385 { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not find ${TK_BIN_DIR}/tkConfig.sh" >&5
15386$as_echo "could not find ${TK_BIN_DIR}/tkConfig.sh" >&6; }
3fc11d3e 15387 fi
bec39cab 15388
5062cc19
KS
15389 # eval is required to do the TK_DBGX substitution
15390 eval "TK_LIB_FILE=\"${TK_LIB_FILE}\""
15391 eval "TK_STUB_LIB_FILE=\"${TK_STUB_LIB_FILE}\""
15392
15393 # If the TK_BIN_DIR is the build directory (not the install directory),
15394 # then set the common variable name to the value of the build variables.
15395 # For example, the variable TK_LIB_SPEC will be set to the value
15396 # of TK_BUILD_LIB_SPEC. An extension should make use of TK_LIB_SPEC
15397 # instead of TK_BUILD_LIB_SPEC since it will work with both an
15398 # installed and uninstalled version of Tcl.
85541719 15399 if test -f "${TK_BIN_DIR}/Makefile" ; then
5062cc19
KS
15400 TK_LIB_SPEC=${TK_BUILD_LIB_SPEC}
15401 TK_STUB_LIB_SPEC=${TK_BUILD_STUB_LIB_SPEC}
15402 TK_STUB_LIB_PATH=${TK_BUILD_STUB_LIB_PATH}
15403 elif test "`uname -s`" = "Darwin"; then
15404 # If Tk was built as a framework, attempt to use the libraries
15405 # from the framework at the given location so that linking works
15406 # against Tk.framework installed in an arbitary location.
15407 case ${TK_DEFS} in
15408 *TK_FRAMEWORK*)
85541719 15409 if test -f "${TK_BIN_DIR}/${TK_LIB_FILE}"; then
5062cc19
KS
15410 for i in "`cd ${TK_BIN_DIR}; pwd`" \
15411 "`cd ${TK_BIN_DIR}/../..; pwd`"; do
15412 if test "`basename "$i"`" = "${TK_LIB_FILE}.framework"; then
15413 TK_LIB_SPEC="-F`dirname "$i"` -framework ${TK_LIB_FILE}"
15414 break
15415 fi
15416 done
15417 fi
85541719 15418 if test -f "${TK_BIN_DIR}/${TK_STUB_LIB_FILE}"; then
5062cc19
KS
15419 TK_STUB_LIB_SPEC="-L${TK_BIN_DIR} ${TK_STUB_LIB_FLAG}"
15420 TK_STUB_LIB_PATH="${TK_BIN_DIR}/${TK_STUB_LIB_FILE}"
15421 fi
15422 ;;
15423 esac
3fc11d3e
JM
15424 fi
15425
5062cc19
KS
15426 # eval is required to do the TK_DBGX substitution
15427 eval "TK_LIB_FLAG=\"${TK_LIB_FLAG}\""
15428 eval "TK_LIB_SPEC=\"${TK_LIB_SPEC}\""
15429 eval "TK_STUB_LIB_FLAG=\"${TK_STUB_LIB_FLAG}\""
15430 eval "TK_STUB_LIB_SPEC=\"${TK_STUB_LIB_SPEC}\""
3fc11d3e 15431
3fc11d3e
JM
15432
15433
bec39cab
AC
15434
15435
15436
15437
15438
15439
15440
3fc11d3e 15441
3fc11d3e 15442
bec39cab 15443
bec39cab 15444
85541719
DE
15445 # Check for in-tree Tk
15446 intree="no"
15447 if test "${TK_SRC_DIR}" = "${topdir}/tk"; then
15448 intree="yes"
15449 fi
3fc11d3e 15450
85541719
DE
15451 # Find Tk private headers
15452 if test x"${intree}" = xno; then
3fc11d3e 15453
81ecdfbb
RW
15454 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Tk private headers" >&5
15455$as_echo_n "checking for Tk private headers... " >&6; }
5062cc19
KS
15456 private_dir=""
15457 dir=`echo ${TK_INCLUDE_SPEC}/tk-private/generic | sed -e s/-I//`
15458 if test -f ${dir}/tkInt.h; then
15459 private_dir=${dir}
3fc11d3e 15460 fi
bec39cab 15461
5062cc19 15462 if test x"${private_dir}" = x; then
81ecdfbb 15463 as_fn_error "could not find Tk private headers" "$LINENO" 5
3fc11d3e 15464 else
5062cc19 15465 TK_PRIVATE_INCLUDE="-I${private_dir}"
81ecdfbb
RW
15466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${private_dir}" >&5
15467$as_echo "${private_dir}" >&6; }
3fc11d3e 15468 fi
3fc11d3e 15469
85541719
DE
15470 TK_INCLUDE="${TK_INCLUDE_SPEC} ${TK_PRIVATE_INCLUDE}"
15471 TK_LIBRARY=${TK_LIB_SPEC}
15472 TK_DEPS=""
15473 else
15474 TK_INCLUDE="-I${TK_SRC_DIR}/generic"
15475 TK_LIBRARY="${TK_BUILD_LIB_SPEC}"
15476 TK_DEPS="../tk/${configdir}/${TK_LIB_FILE}"
15477 fi
3fc11d3e
JM
15478
15479
3fc11d3e
JM
15480
15481
3fc11d3e 15482
85541719 15483 ENABLE_CFLAGS="${ENABLE_CFLAGS} \$(SUBDIR_GDBTK_CFLAGS)"
3fc11d3e 15484
85541719
DE
15485 # Include some libraries that Tcl and Tk want.
15486 TCL_LIBS='$(LIBGUI) $(TK) $(TCL) $(X11_LDFLAGS) $(X11_LIBS)'
15487 # Yes, the ordering seems wrong here. But it isn't.
15488 # TK_LIBS is the list of libraries that need to be linked
15489 # after Tcl/Tk. Note that this isn't put into LIBS. If it
15490 # were in LIBS then any link tests after this point would
15491 # try to include things like `$(LIBGUI)', which wouldn't work.
15492 GDBTKLIBS="${TCL_LIBS} ${TK_LIBS}"
4226a5a5 15493
85541719
DE
15494 CONFIG_OBS="${CONFIG_OBS} \$(SUBDIR_GDBTK_OBS)"
15495 CONFIG_DEPS="${CONFIG_DEPS} \$(SUBDIR_GDBTK_DEPS)"
15496 CONFIG_SRCS="${CONFIG_SRCS} \$(SUBDIR_GDBTK_SRCS)"
15497 CONFIG_ALL="${CONFIG_ALL} all-gdbtk"
15498 CONFIG_CLEAN="${CONFIG_CLEAN} clean-gdbtk"
15499 CONFIG_INSTALL="${CONFIG_INSTALL} install-gdbtk"
15500 CONFIG_UNINSTALL="${CONFIG_UNINSTALL} uninstall-gdbtk"
3fc11d3e 15501
85541719
DE
15502 if test x$gdb_cv_os_cygwin = xyes; then
15503 WIN32LIBS="${WIN32LIBS} -lshell32 -lgdi32 -lcomdlg32 -ladvapi32"
15504 WIN32LDAPP="-Wl,--subsystem,console"
15505 CONFIG_OBS="${CONFIG_OBS} gdbres.o"
3fc11d3e 15506 fi
ffc6a242 15507
81ecdfbb 15508 subdirs="$subdirs gdbtk"
3ace7edb 15509
85541719 15510 fi
3fc11d3e
JM
15511fi
15512
15513
15514
15515
15516
15517
15518
15519
81ecdfbb
RW
15520{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
15521$as_echo_n "checking for X... " >&6; }
bec39cab 15522
c906108c 15523
81ecdfbb
RW
15524# Check whether --with-x was given.
15525if test "${with_x+set}" = set; then :
15526 withval=$with_x;
15527fi
c906108c
SS
15528
15529# $have_x is `yes', `no', `disabled', or empty when we do not yet know.
15530if test "x$with_x" = xno; then
15531 # The user explicitly disabled X.
15532 have_x=disabled
15533else
81ecdfbb
RW
15534 case $x_includes,$x_libraries in #(
15535 *\'*) as_fn_error "cannot use X directory names containing '" "$LINENO" 5;; #(
15536 *,NONE | NONE,*) if test "${ac_cv_have_x+set}" = set; then :
15537 $as_echo_n "(cached) " >&6
c906108c
SS
15538else
15539 # One or both of the vars are not set, and there is no cached value.
bec39cab 15540ac_x_includes=no ac_x_libraries=no
81ecdfbb 15541rm -f -r conftest.dir
bec39cab
AC
15542if mkdir conftest.dir; then
15543 cd conftest.dir
bec39cab 15544 cat >Imakefile <<'_ACEOF'
81ecdfbb
RW
15545incroot:
15546 @echo incroot='${INCROOT}'
15547usrlibdir:
15548 @echo usrlibdir='${USRLIBDIR}'
15549libdir:
15550 @echo libdir='${LIBDIR}'
15551_ACEOF
15552 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
c906108c 15553 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
81ecdfbb
RW
15554 for ac_var in incroot usrlibdir libdir; do
15555 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
15556 done
c906108c 15557 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
81ecdfbb
RW
15558 for ac_extension in a so sl dylib la dll; do
15559 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
15560 test -f "$ac_im_libdir/libX11.$ac_extension"; then
bec39cab 15561 ac_im_usrlibdir=$ac_im_libdir; break
c906108c
SS
15562 fi
15563 done
15564 # Screen out bogus values from the imake configuration. They are
15565 # bogus both because they are the default anyway, and because
15566 # using them would break gcc on systems where it needs fixed includes.
bec39cab 15567 case $ac_im_incroot in
81ecdfbb 15568 /usr/include) ac_x_includes= ;;
bec39cab 15569 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
c906108c 15570 esac
bec39cab 15571 case $ac_im_usrlibdir in
81ecdfbb 15572 /usr/lib | /usr/lib64 | /lib | /lib64) ;;
bec39cab 15573 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
c906108c
SS
15574 esac
15575 fi
15576 cd ..
81ecdfbb 15577 rm -f -r conftest.dir
c906108c
SS
15578fi
15579
bec39cab
AC
15580# Standard set of common directories for X headers.
15581# Check X11 before X11Rn because it is often a symlink to the current release.
15582ac_x_header_dirs='
15583/usr/X11/include
81ecdfbb 15584/usr/X11R7/include
bec39cab
AC
15585/usr/X11R6/include
15586/usr/X11R5/include
15587/usr/X11R4/include
15588
15589/usr/include/X11
81ecdfbb 15590/usr/include/X11R7
bec39cab
AC
15591/usr/include/X11R6
15592/usr/include/X11R5
15593/usr/include/X11R4
15594
15595/usr/local/X11/include
81ecdfbb 15596/usr/local/X11R7/include
bec39cab
AC
15597/usr/local/X11R6/include
15598/usr/local/X11R5/include
15599/usr/local/X11R4/include
15600
15601/usr/local/include/X11
81ecdfbb 15602/usr/local/include/X11R7
bec39cab
AC
15603/usr/local/include/X11R6
15604/usr/local/include/X11R5
15605/usr/local/include/X11R4
15606
15607/usr/X386/include
15608/usr/x386/include
15609/usr/XFree86/include/X11
15610
15611/usr/include
15612/usr/local/include
15613/usr/unsupported/include
15614/usr/athena/include
15615/usr/local/x11r5/include
15616/usr/lpp/Xamples/include
15617
15618/usr/openwin/include
15619/usr/openwin/share/include'
15620
15621if test "$ac_x_includes" = no; then
81ecdfbb 15622 # Guess where to find include files, by looking for Xlib.h.
c906108c 15623 # First, try using that file with no special directory specified.
81ecdfbb 15624 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 15625/* end confdefs.h. */
81ecdfbb 15626#include <X11/Xlib.h>
bec39cab 15627_ACEOF
81ecdfbb 15628if ac_fn_c_try_cpp "$LINENO"; then :
c906108c
SS
15629 # We can compile using X headers with no special include directory.
15630ac_x_includes=
15631else
bec39cab 15632 for ac_dir in $ac_x_header_dirs; do
81ecdfbb 15633 if test -r "$ac_dir/X11/Xlib.h"; then
bec39cab
AC
15634 ac_x_includes=$ac_dir
15635 break
15636 fi
15637done
c906108c 15638fi
bec39cab
AC
15639rm -f conftest.err conftest.$ac_ext
15640fi # $ac_x_includes = no
c906108c 15641
bec39cab 15642if test "$ac_x_libraries" = no; then
c906108c 15643 # Check for the libraries.
c906108c
SS
15644 # See if we find them without any special options.
15645 # Don't add to $LIBS permanently.
bec39cab 15646 ac_save_LIBS=$LIBS
81ecdfbb
RW
15647 LIBS="-lX11 $LIBS"
15648 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 15649/* end confdefs.h. */
81ecdfbb 15650#include <X11/Xlib.h>
bec39cab
AC
15651int
15652main ()
15653{
81ecdfbb 15654XrmInitialize ()
bec39cab
AC
15655 ;
15656 return 0;
15657}
15658_ACEOF
81ecdfbb 15659if ac_fn_c_try_link "$LINENO"; then :
bec39cab 15660 LIBS=$ac_save_LIBS
c906108c
SS
15661# We can link X programs with no special library path.
15662ac_x_libraries=
15663else
81ecdfbb
RW
15664 LIBS=$ac_save_LIBS
15665for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
c906108c 15666do
bec39cab 15667 # Don't even attempt the hair of trying to link an X program!
81ecdfbb
RW
15668 for ac_extension in a so sl dylib la dll; do
15669 if test -r "$ac_dir/libX11.$ac_extension"; then
c906108c
SS
15670 ac_x_libraries=$ac_dir
15671 break 2
15672 fi
15673 done
15674done
15675fi
81ecdfbb
RW
15676rm -f core conftest.err conftest.$ac_objext \
15677 conftest$ac_exeext conftest.$ac_ext
bec39cab 15678fi # $ac_x_libraries = no
c906108c 15679
81ecdfbb
RW
15680case $ac_x_includes,$ac_x_libraries in #(
15681 no,* | *,no | *\'*)
15682 # Didn't find X, or a directory has "'" in its name.
15683 ac_cv_have_x="have_x=no";; #(
15684 *)
15685 # Record where we found X for the cache.
15686 ac_cv_have_x="have_x=yes\
15687 ac_x_includes='$ac_x_includes'\
15688 ac_x_libraries='$ac_x_libraries'"
15689esac
c906108c 15690fi
81ecdfbb
RW
15691;; #(
15692 *) have_x=yes;;
15693 esac
c906108c
SS
15694 eval "$ac_cv_have_x"
15695fi # $with_x != no
15696
15697if test "$have_x" != yes; then
81ecdfbb
RW
15698 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
15699$as_echo "$have_x" >&6; }
c906108c
SS
15700 no_x=yes
15701else
15702 # If each of the values was on the command line, it overrides each guess.
15703 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
15704 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
15705 # Update the cache value to reflect the command line values.
81ecdfbb
RW
15706 ac_cv_have_x="have_x=yes\
15707 ac_x_includes='$x_includes'\
15708 ac_x_libraries='$x_libraries'"
15709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
15710$as_echo "libraries $x_libraries, headers $x_includes" >&6; }
c906108c
SS
15711fi
15712
15713
bec39cab 15714# Unlike the sim directory, whether a simulator is linked is controlled by
9b624dbe 15715# presence of a gdb_sim definition in the target configure.tgt entry.
7a292a7a
SS
15716# This code just checks for a few cases where we'd like to ignore those
15717# definitions, even when they're present in the '.mt' file. These cases
15718# are when --disable-sim is specified, or if the simulator directory is
6c5cfe5b 15719# not part of the source tree.
7a292a7a 15720#
81ecdfbb
RW
15721# Check whether --enable-sim was given.
15722if test "${enable_sim+set}" = set; then :
15723 enableval=$enable_sim; echo "enable_sim = $enable_sim";
7a292a7a
SS
15724 echo "enableval = ${enableval}";
15725 case "${enableval}" in
15726 yes) ignore_sim=false ;;
15727 no) ignore_sim=true ;;
15728 *) ignore_sim=false ;;
15729 esac
15730else
15731 ignore_sim=false
81ecdfbb
RW
15732fi
15733
7a292a7a
SS
15734
15735if test ! -d "${srcdir}/../sim"; then
15736 ignore_sim=true
15737fi
15738
9b624dbe
UW
15739SIM=
15740SIM_OBS=
15741if test "${ignore_sim}" = "false"; then
15742 if test x"${gdb_sim}" != x ; then
15743 SIM="${gdb_sim}"
15744 SIM_OBS="remote-sim.o"
60ca704f 15745
81ecdfbb 15746$as_echo "#define WITH_SIM 1" >>confdefs.h
7a292a7a 15747
9b624dbe 15748 fi
7a292a7a
SS
15749fi
15750
15751
15752
c906108c
SS
15753
15754
15755
15756
15757
15758
dfcd3bfb 15759
e56ac5c3
AC
15760
15761
b3a90332
AC
15762
15763
c35f4ffc 15764# List of host floatformats.
bec39cab
AC
15765
15766cat >>confdefs.h <<_ACEOF
c35f4ffc 15767#define GDB_HOST_FLOAT_FORMAT $gdb_host_float_format
bec39cab 15768_ACEOF
c35f4ffc 15769
bec39cab
AC
15770
15771cat >>confdefs.h <<_ACEOF
c35f4ffc 15772#define GDB_HOST_DOUBLE_FORMAT $gdb_host_double_format
bec39cab
AC
15773_ACEOF
15774
c35f4ffc 15775
bec39cab 15776cat >>confdefs.h <<_ACEOF
c35f4ffc 15777#define GDB_HOST_LONG_DOUBLE_FORMAT $gdb_host_long_double_format
bec39cab 15778_ACEOF
c35f4ffc
AC
15779
15780
c906108c
SS
15781# target_subdir is used by the testsuite to find the target libraries.
15782target_subdir=
15783if test "${host}" != "${target}"; then
15784 target_subdir="${target_alias}/"
15785fi
15786
15787
15788frags=
771b4502 15789if test "${gdb_native}" = "yes"; then
0dad8a66
MK
15790 host_makefile_frag=${srcdir}/config/${gdb_host_cpu}/${gdb_host}.mh
15791 if test ! -f ${host_makefile_frag}; then
81ecdfbb 15792 as_fn_error "\"*** Gdb does not support native target ${host}\"" "$LINENO" 5
0dad8a66
MK
15793 fi
15794 frags="$frags $host_makefile_frag"
15795else
15796 host_makefile_frag=/dev/null
c906108c 15797fi
c906108c 15798
c906108c
SS
15799
15800
15801
771b4502 15802if test "${gdb_native}" = "yes"; then
a85f51e7
DJ
15803# We pick this up from the host configuration file (.mh) because we
15804# do not have a native configuration Makefile fragment.
c906108c
SS
15805nativefile=`sed -n '
15806s/NAT_FILE[ ]*=[ ]*\([^ ]*\)/\1/p
15807' ${host_makefile_frag}`
c906108c
SS
15808fi
15809
15810
b00a8037 15811if test x"${gdb_osabi}" != x ; then
bec39cab
AC
15812
15813cat >>confdefs.h <<_ACEOF
b00a8037 15814#define GDB_OSABI_DEFAULT $gdb_osabi
bec39cab 15815_ACEOF
b00a8037
DJ
15816
15817fi
15818
8dcde887 15819# Enable multi-ice-gdb-server.
81ecdfbb
RW
15820# Check whether --enable-multi-ice was given.
15821if test "${enable_multi_ice+set}" = set; then :
15822 enableval=$enable_multi_ice; case $enableval in
8dcde887
MK
15823 yes | no)
15824 ;;
81ecdfbb 15825 *) as_fn_error "bad value $enableval for --enable-multi-ice" "$LINENO" 5 ;;
8dcde887 15826 esac
81ecdfbb 15827fi
b4e70030 15828
81ecdfbb
RW
15829if test "x$enable_multi_ice" = xyes; then
15830 subdirs="$subdirs multi-ice"
3ace7edb 15831
a85f51e7
DJ
15832fi
15833
496c0e1b
JB
15834# Check whether --enable-gdbserver was given.
15835if test "${enable_gdbserver+set}" = set; then :
15836 enableval=$enable_gdbserver; case "${enableval}" in
15837 yes| no|auto) ;;
15838 *) as_fn_error "bad value ${enableval} for --enable-gdbserver option" "$LINENO" 5 ;;
15839esac
15840else
15841 enable_gdbserver=auto
15842fi
15843
15844
15845# We only build gdbserver automatically in a native configuration, and
15846# only if the user did not explicitly disable its build.
15847if test "$gdb_native" = "yes" -a "$enable_gdbserver" != "no"; then
81ecdfbb
RW
15848 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gdbserver is supported on this host" >&5
15849$as_echo_n "checking whether gdbserver is supported on this host... " >&6; }
8dcde887 15850 if test "x$build_gdbserver" = xyes; then
81ecdfbb
RW
15851 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15852$as_echo "yes" >&6; }
15853 subdirs="$subdirs gdbserver"
3ace7edb 15854
496c0e1b 15855 gdbserver_build_enabled=yes
8dcde887 15856 else
81ecdfbb
RW
15857 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15858$as_echo "no" >&6; }
8dcde887
MK
15859 fi
15860fi
15861
496c0e1b
JB
15862# If the user explicitly request the gdbserver to be built, verify that
15863# we were in fact able to enable it.
15864if test "$enable_gdbserver" = "yes" -a "$gdbserver_build_enabled" != "yes"; then
15865 as_fn_error "Automatic gdbserver build is not supported for this configuration" "$LINENO" 5
15866fi
15867
db985757 15868# If nativefile (NAT_FILE) is not set in config/*/*.m[ht] files, we link
2c0fc042 15869# to an empty version.
c906108c
SS
15870
15871files=
15872links=
5a2402b8 15873
c906108c
SS
15874rm -f nm.h
15875if test "${nativefile}" != ""; then
0f475e27
AC
15876 case "${nativefile}" in
15877 nm-*.h ) GDB_NM_FILE="config/${gdb_host_cpu}/${nativefile}" ;;
15878 * ) GDB_NM_FILE="${nativefile}"
15879 esac
5a2402b8
AC
15880 files="${files} ${GDB_NM_FILE}"
15881 links="${links} nm.h"
60ca704f
SE
15882
15883cat >>confdefs.h <<_ACEOF
b78960be 15884#define GDB_NM_FILE "${GDB_NM_FILE}"
bec39cab 15885_ACEOF
5a2402b8 15886
c906108c 15887fi
5a2402b8
AC
15888
15889
bec39cab
AC
15890ac_sources="$files"
15891ac_dests="$links"
15892while test -n "$ac_sources"; do
15893 set $ac_dests; ac_dest=$1; shift; ac_dests=$*
15894 set $ac_sources; ac_source=$1; shift; ac_sources=$*
15895 ac_config_links_1="$ac_config_links_1 $ac_dest:$ac_source"
15896done
81ecdfbb 15897ac_config_links="$ac_config_links $ac_config_links_1"
c906108c
SS
15898
15899
c906108c
SS
15900
15901
c906108c 15902
81ecdfbb 15903$as_echo "#define GDB_DEFAULT_HOST_CHARSET \"UTF-8\"" >>confdefs.h
bec39cab 15904
bec39cab 15905
5ae98d25 15906ac_config_files="$ac_config_files Makefile .gdbinit:gdbinit.in doc/Makefile gnulib/Makefile data-directory/Makefile"
81ecdfbb
RW
15907
15908ac_config_commands="$ac_config_commands default"
89a34d1b 15909
bec39cab
AC
15910cat >confcache <<\_ACEOF
15911# This file is a shell script that caches the results of configure
15912# tests run on this system so they can be shared between configure
15913# scripts and configure runs, see configure's option --config-cache.
15914# It is not useful on other systems. If it contains results you don't
15915# want to keep, you may remove or edit it.
15916#
15917# config.status only pays attention to the cache file if you give it
15918# the --recheck option to rerun configure.
15919#
15920# `ac_cv_env_foo' variables (set or unset) will be overridden when
15921# loading this file, other *unset* `ac_cv_foo' will be assigned the
15922# following values.
15923
15924_ACEOF
15925
15926# The following way of writing the cache mishandles newlines in values,
15927# but we know of no workaround that is simple, portable, and efficient.
81ecdfbb 15928# So, we kill variables containing newlines.
bec39cab
AC
15929# Ultrix sh set writes to stderr and can't be redirected directly,
15930# and sets the high bit in the cache file unless we assign to the vars.
81ecdfbb
RW
15931(
15932 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
15933 eval ac_val=\$$ac_var
15934 case $ac_val in #(
15935 *${as_nl}*)
15936 case $ac_var in #(
15937 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
15938$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
15939 esac
15940 case $ac_var in #(
15941 _ | IFS | as_nl) ;; #(
15942 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
15943 *) { eval $ac_var=; unset $ac_var;} ;;
15944 esac ;;
15945 esac
15946 done
15947
bec39cab 15948 (set) 2>&1 |
81ecdfbb
RW
15949 case $as_nl`(ac_space=' '; set) 2>&1` in #(
15950 *${as_nl}ac_space=\ *)
15951 # `set' does not quote correctly, so add quotes: double-quote
15952 # substitution turns \\\\ into \\, and sed turns \\ into \.
bec39cab
AC
15953 sed -n \
15954 "s/'/'\\\\''/g;
15955 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
81ecdfbb 15956 ;; #(
bec39cab
AC
15957 *)
15958 # `set' quotes correctly as required by POSIX, so do not add quotes.
81ecdfbb 15959 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
bec39cab 15960 ;;
81ecdfbb
RW
15961 esac |
15962 sort
15963) |
bec39cab 15964 sed '
81ecdfbb 15965 /^ac_cv_env_/b end
bec39cab 15966 t clear
81ecdfbb 15967 :clear
bec39cab
AC
15968 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
15969 t end
81ecdfbb
RW
15970 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
15971 :end' >>confcache
15972if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
15973 if test -w "$cache_file"; then
15974 test "x$cache_file" != "x/dev/null" &&
15975 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
15976$as_echo "$as_me: updating cache $cache_file" >&6;}
bec39cab
AC
15977 cat confcache >$cache_file
15978 else
81ecdfbb
RW
15979 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
15980$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
bec39cab
AC
15981 fi
15982fi
15983rm -f confcache
15984
15985test "x$prefix" = xNONE && prefix=$ac_default_prefix
15986# Let make expand exec_prefix.
15987test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
15988
bec39cab
AC
15989DEFS=-DHAVE_CONFIG_H
15990
15991ac_libobjs=
15992ac_ltlibobjs=
15993for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
15994 # 1. Remove the extension, and $U if already installed.
81ecdfbb
RW
15995 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
15996 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
15997 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
15998 # will be set to the directory where LIBOBJS objects are built.
15999 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
16000 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
bec39cab
AC
16001done
16002LIBOBJS=$ac_libobjs
16003
16004LTLIBOBJS=$ac_ltlibobjs
16005
16006
85981d60 16007if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
81ecdfbb
RW
16008 as_fn_error "conditional \"MAINTAINER_MODE\" was never defined.
16009Usually this means the macro was only invoked conditionally." "$LINENO" 5
85981d60 16010fi
a417dc56 16011if test -z "${GMAKE_TRUE}" && test -z "${GMAKE_FALSE}"; then
81ecdfbb
RW
16012 as_fn_error "conditional \"GMAKE\" was never defined.
16013Usually this means the macro was only invoked conditionally." "$LINENO" 5
a417dc56 16014fi
783e057b 16015if test -z "${GL_COND_LIBTOOL_TRUE}" && test -z "${GL_COND_LIBTOOL_FALSE}"; then
81ecdfbb
RW
16016 as_fn_error "conditional \"GL_COND_LIBTOOL\" was never defined.
16017Usually this means the macro was only invoked conditionally." "$LINENO" 5
783e057b
DJ
16018fi
16019
16020 gl_libobjs=
16021 gl_ltlibobjs=
16022 if test -n "$gl_LIBOBJS"; then
16023 # Remove the extension.
16024 sed_drop_objext='s/\.o$//;s/\.obj$//'
f434ba03 16025 for i in `for i in $gl_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
783e057b
DJ
16026 gl_libobjs="$gl_libobjs $i.$ac_objext"
16027 gl_ltlibobjs="$gl_ltlibobjs $i.lo"
16028 done
16029 fi
16030 gl_LIBOBJS=$gl_libobjs
16031
16032 gl_LTLIBOBJS=$gl_ltlibobjs
16033
16034
16035
16036 gltests_libobjs=
16037 gltests_ltlibobjs=
16038 if test -n "$gltests_LIBOBJS"; then
16039 # Remove the extension.
16040 sed_drop_objext='s/\.o$//;s/\.obj$//'
f434ba03 16041 for i in `for i in $gltests_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
783e057b
DJ
16042 gltests_libobjs="$gltests_libobjs $i.$ac_objext"
16043 gltests_ltlibobjs="$gltests_ltlibobjs $i.lo"
16044 done
16045 fi
16046 gltests_LIBOBJS=$gltests_libobjs
16047
16048 gltests_LTLIBOBJS=$gltests_ltlibobjs
16049
16050
e28b3332 16051if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
81ecdfbb
RW
16052 as_fn_error "conditional \"AMDEP\" was never defined.
16053Usually this means the macro was only invoked conditionally." "$LINENO" 5
e28b3332
DJ
16054fi
16055if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
81ecdfbb
RW
16056 as_fn_error "conditional \"am__fastdepCC\" was never defined.
16057Usually this means the macro was only invoked conditionally." "$LINENO" 5
16058fi
16059 if test -n "$EXEEXT"; then
16060 am__EXEEXT_TRUE=
16061 am__EXEEXT_FALSE='#'
16062else
16063 am__EXEEXT_TRUE='#'
16064 am__EXEEXT_FALSE=
e28b3332 16065fi
bec39cab 16066
81ecdfbb
RW
16067
16068
bec39cab 16069: ${CONFIG_STATUS=./config.status}
81ecdfbb 16070ac_write_fail=0
bec39cab
AC
16071ac_clean_files_save=$ac_clean_files
16072ac_clean_files="$ac_clean_files $CONFIG_STATUS"
81ecdfbb
RW
16073{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
16074$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
16075as_write_fail=0
16076cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
bec39cab
AC
16077#! $SHELL
16078# Generated by $as_me.
16079# Run this file to recreate the current configuration.
16080# Compiler output produced by configure, useful for debugging
16081# configure, is in config.log if it exists.
16082
16083debug=false
16084ac_cs_recheck=false
16085ac_cs_silent=false
bec39cab 16086
81ecdfbb
RW
16087SHELL=\${CONFIG_SHELL-$SHELL}
16088export SHELL
16089_ASEOF
16090cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
16091## -------------------- ##
16092## M4sh Initialization. ##
16093## -------------------- ##
16094
16095# Be more Bourne compatible
16096DUALCASE=1; export DUALCASE # for MKS sh
16097if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
bec39cab
AC
16098 emulate sh
16099 NULLCMD=:
81ecdfbb 16100 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
bec39cab
AC
16101 # is contrary to our usage. Disable this feature.
16102 alias -g '${1+"$@"}'='"$@"'
81ecdfbb
RW
16103 setopt NO_GLOB_SUBST
16104else
16105 case `(set -o) 2>/dev/null` in #(
16106 *posix*) :
16107 set -o posix ;; #(
16108 *) :
16109 ;;
16110esac
bec39cab 16111fi
bec39cab 16112
81ecdfbb
RW
16113
16114as_nl='
16115'
16116export as_nl
16117# Printing a long string crashes Solaris 7 /usr/bin/printf.
16118as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
16119as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
16120as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
16121# Prefer a ksh shell builtin over an external printf program on Solaris,
16122# but without wasting forks for bash or zsh.
16123if test -z "$BASH_VERSION$ZSH_VERSION" \
16124 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
16125 as_echo='print -r --'
16126 as_echo_n='print -rn --'
16127elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
16128 as_echo='printf %s\n'
16129 as_echo_n='printf %s'
16130else
16131 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
16132 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
16133 as_echo_n='/usr/ucb/echo -n'
16134 else
16135 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
16136 as_echo_n_body='eval
16137 arg=$1;
16138 case $arg in #(
16139 *"$as_nl"*)
16140 expr "X$arg" : "X\\(.*\\)$as_nl";
16141 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
16142 esac;
16143 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
16144 '
16145 export as_echo_n_body
16146 as_echo_n='sh -c $as_echo_n_body as_echo'
16147 fi
16148 export as_echo_body
16149 as_echo='sh -c $as_echo_body as_echo'
16150fi
16151
16152# The user is always right.
16153if test "${PATH_SEPARATOR+set}" != set; then
16154 PATH_SEPARATOR=:
16155 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
16156 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
16157 PATH_SEPARATOR=';'
16158 }
bec39cab
AC
16159fi
16160
16161
81ecdfbb
RW
16162# IFS
16163# We need space, tab and new line, in precisely that order. Quoting is
16164# there to prevent editors from complaining about space-tab.
16165# (If _AS_PATH_WALK were called with IFS unset, it would disable word
16166# splitting by setting IFS to empty value.)
16167IFS=" "" $as_nl"
16168
16169# Find who we are. Look in the path if we contain no directory separator.
16170case $0 in #((
16171 *[\\/]* ) as_myself=$0 ;;
16172 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16173for as_dir in $PATH
16174do
16175 IFS=$as_save_IFS
16176 test -z "$as_dir" && as_dir=.
16177 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
16178 done
16179IFS=$as_save_IFS
16180
16181 ;;
16182esac
16183# We did not find ourselves, most probably we were run as `sh COMMAND'
16184# in which case we are not to be found in the path.
16185if test "x$as_myself" = x; then
16186 as_myself=$0
16187fi
16188if test ! -f "$as_myself"; then
16189 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
16190 exit 1
16191fi
16192
16193# Unset variables that we do not need and which cause bugs (e.g. in
16194# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
16195# suppresses any "Segmentation fault" message there. '((' could
16196# trigger a bug in pdksh 5.2.14.
16197for as_var in BASH_ENV ENV MAIL MAILPATH
16198do eval test x\${$as_var+set} = xset \
16199 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
16200done
bec39cab
AC
16201PS1='$ '
16202PS2='> '
16203PS4='+ '
16204
16205# NLS nuisances.
81ecdfbb
RW
16206LC_ALL=C
16207export LC_ALL
16208LANGUAGE=C
16209export LANGUAGE
16210
16211# CDPATH.
16212(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
16213
16214
16215# as_fn_error ERROR [LINENO LOG_FD]
16216# ---------------------------------
16217# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
16218# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
16219# script with status $?, using 1 if that was 0.
16220as_fn_error ()
16221{
16222 as_status=$?; test $as_status -eq 0 && as_status=1
16223 if test "$3"; then
16224 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
16225 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
16226 fi
16227 $as_echo "$as_me: error: $1" >&2
16228 as_fn_exit $as_status
16229} # as_fn_error
16230
16231
16232# as_fn_set_status STATUS
16233# -----------------------
16234# Set $? to STATUS, without forking.
16235as_fn_set_status ()
16236{
16237 return $1
16238} # as_fn_set_status
16239
16240# as_fn_exit STATUS
16241# -----------------
16242# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
16243as_fn_exit ()
16244{
16245 set +e
16246 as_fn_set_status $1
16247 exit $1
16248} # as_fn_exit
16249
16250# as_fn_unset VAR
16251# ---------------
16252# Portably unset VAR.
16253as_fn_unset ()
16254{
16255 { eval $1=; unset $1;}
16256}
16257as_unset=as_fn_unset
16258# as_fn_append VAR VALUE
16259# ----------------------
16260# Append the text in VALUE to the end of the definition contained in VAR. Take
16261# advantage of any shell optimizations that allow amortized linear growth over
16262# repeated appends, instead of the typical quadratic growth present in naive
16263# implementations.
16264if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
16265 eval 'as_fn_append ()
16266 {
16267 eval $1+=\$2
16268 }'
16269else
16270 as_fn_append ()
16271 {
16272 eval $1=\$$1\$2
16273 }
16274fi # as_fn_append
16275
16276# as_fn_arith ARG...
16277# ------------------
16278# Perform arithmetic evaluation on the ARGs, and store the result in the
16279# global $as_val. Take advantage of shells that can avoid forks. The arguments
16280# must be portable across $(()) and expr.
16281if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
16282 eval 'as_fn_arith ()
16283 {
16284 as_val=$(( $* ))
16285 }'
16286else
16287 as_fn_arith ()
16288 {
16289 as_val=`expr "$@" || test $? -eq 1`
16290 }
16291fi # as_fn_arith
bec39cab 16292
81ecdfbb
RW
16293
16294if expr a : '\(a\)' >/dev/null 2>&1 &&
16295 test "X`expr 00001 : '.*\(...\)'`" = X001; then
bec39cab
AC
16296 as_expr=expr
16297else
16298 as_expr=false
16299fi
16300
81ecdfbb 16301if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
bec39cab
AC
16302 as_basename=basename
16303else
16304 as_basename=false
16305fi
16306
81ecdfbb
RW
16307if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
16308 as_dirname=dirname
16309else
16310 as_dirname=false
16311fi
bec39cab 16312
81ecdfbb 16313as_me=`$as_basename -- "$0" ||
bec39cab
AC
16314$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
16315 X"$0" : 'X\(//\)$' \| \
81ecdfbb
RW
16316 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
16317$as_echo X/"$0" |
16318 sed '/^.*\/\([^/][^/]*\)\/*$/{
16319 s//\1/
16320 q
16321 }
16322 /^X\/\(\/\/\)$/{
16323 s//\1/
16324 q
16325 }
16326 /^X\/\(\/\).*/{
16327 s//\1/
16328 q
16329 }
16330 s/.*/./; q'`
b4e70030 16331
b4e70030
JB
16332# Avoid depending upon Character Ranges.
16333as_cr_letters='abcdefghijklmnopqrstuvwxyz'
16334as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
16335as_cr_Letters=$as_cr_letters$as_cr_LETTERS
16336as_cr_digits='0123456789'
16337as_cr_alnum=$as_cr_Letters$as_cr_digits
16338
81ecdfbb
RW
16339ECHO_C= ECHO_N= ECHO_T=
16340case `echo -n x` in #(((((
16341-n*)
16342 case `echo 'xy\c'` in
16343 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
16344 xy) ECHO_C='\c';;
16345 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
16346 ECHO_T=' ';;
16347 esac;;
16348*)
16349 ECHO_N='-n';;
bec39cab
AC
16350esac
16351
81ecdfbb
RW
16352rm -f conf$$ conf$$.exe conf$$.file
16353if test -d conf$$.dir; then
16354 rm -f conf$$.dir/conf$$.file
bec39cab 16355else
81ecdfbb
RW
16356 rm -f conf$$.dir
16357 mkdir conf$$.dir 2>/dev/null
bec39cab 16358fi
81ecdfbb
RW
16359if (echo >conf$$.file) 2>/dev/null; then
16360 if ln -s conf$$.file conf$$ 2>/dev/null; then
b4e70030 16361 as_ln_s='ln -s'
81ecdfbb
RW
16362 # ... but there are two gotchas:
16363 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
16364 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
16365 # In both cases, we have to default to `cp -p'.
16366 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
16367 as_ln_s='cp -p'
16368 elif ln conf$$.file conf$$ 2>/dev/null; then
16369 as_ln_s=ln
16370 else
16371 as_ln_s='cp -p'
b4e70030 16372 fi
bec39cab
AC
16373else
16374 as_ln_s='cp -p'
16375fi
81ecdfbb
RW
16376rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
16377rmdir conf$$.dir 2>/dev/null
16378
16379
16380# as_fn_mkdir_p
16381# -------------
16382# Create "$as_dir" as a directory, including parents if necessary.
16383as_fn_mkdir_p ()
16384{
16385
16386 case $as_dir in #(
16387 -*) as_dir=./$as_dir;;
16388 esac
16389 test -d "$as_dir" || eval $as_mkdir_p || {
16390 as_dirs=
16391 while :; do
16392 case $as_dir in #(
16393 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
16394 *) as_qdir=$as_dir;;
16395 esac
16396 as_dirs="'$as_qdir' $as_dirs"
16397 as_dir=`$as_dirname -- "$as_dir" ||
16398$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
16399 X"$as_dir" : 'X\(//\)[^/]' \| \
16400 X"$as_dir" : 'X\(//\)$' \| \
16401 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
16402$as_echo X"$as_dir" |
16403 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
16404 s//\1/
16405 q
16406 }
16407 /^X\(\/\/\)[^/].*/{
16408 s//\1/
16409 q
16410 }
16411 /^X\(\/\/\)$/{
16412 s//\1/
16413 q
16414 }
16415 /^X\(\/\).*/{
16416 s//\1/
16417 q
16418 }
16419 s/.*/./; q'`
16420 test -d "$as_dir" && break
16421 done
16422 test -z "$as_dirs" || eval "mkdir $as_dirs"
16423 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
16424
bec39cab 16425
81ecdfbb 16426} # as_fn_mkdir_p
bec39cab 16427if mkdir -p . 2>/dev/null; then
81ecdfbb 16428 as_mkdir_p='mkdir -p "$as_dir"'
bec39cab
AC
16429else
16430 test -d ./-p && rmdir ./-p
16431 as_mkdir_p=false
16432fi
16433
81ecdfbb
RW
16434if test -x / >/dev/null 2>&1; then
16435 as_test_x='test -x'
16436else
16437 if ls -dL / >/dev/null 2>&1; then
16438 as_ls_L_option=L
16439 else
16440 as_ls_L_option=
16441 fi
16442 as_test_x='
16443 eval sh -c '\''
16444 if test -d "$1"; then
16445 test -d "$1/.";
16446 else
16447 case $1 in #(
16448 -*)set "./$1";;
16449 esac;
16450 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
16451 ???[sx]*):;;*)false;;esac;fi
16452 '\'' sh
16453 '
16454fi
16455as_executable_p=$as_test_x
bec39cab
AC
16456
16457# Sed expression to map a string onto a valid CPP name.
16458as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
16459
16460# Sed expression to map a string onto a valid variable name.
16461as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
16462
16463
bec39cab 16464exec 6>&1
81ecdfbb
RW
16465## ----------------------------------- ##
16466## Main body of $CONFIG_STATUS script. ##
16467## ----------------------------------- ##
16468_ASEOF
16469test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
16470
16471cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
16472# Save the log message, to keep $0 and so on meaningful, and to
bec39cab 16473# report actual input values of CONFIG_FILES etc. instead of their
81ecdfbb
RW
16474# values after options handling.
16475ac_log="
bec39cab 16476This file was extended by $as_me, which was
81ecdfbb 16477generated by GNU Autoconf 2.64. Invocation command line was
bec39cab
AC
16478
16479 CONFIG_FILES = $CONFIG_FILES
16480 CONFIG_HEADERS = $CONFIG_HEADERS
16481 CONFIG_LINKS = $CONFIG_LINKS
16482 CONFIG_COMMANDS = $CONFIG_COMMANDS
16483 $ $0 $@
16484
81ecdfbb
RW
16485on `(hostname || uname -n) 2>/dev/null | sed 1q`
16486"
16487
bec39cab
AC
16488_ACEOF
16489
81ecdfbb
RW
16490case $ac_config_files in *"
16491"*) set x $ac_config_files; shift; ac_config_files=$*;;
16492esac
234b45d4 16493
81ecdfbb
RW
16494case $ac_config_headers in *"
16495"*) set x $ac_config_headers; shift; ac_config_headers=$*;;
16496esac
b4e70030 16497
b4e70030 16498
81ecdfbb
RW
16499cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
16500# Files that config.status was made for.
16501config_files="$ac_config_files"
16502config_headers="$ac_config_headers"
16503config_links="$ac_config_links"
16504config_commands="$ac_config_commands"
234b45d4 16505
81ecdfbb 16506_ACEOF
b4e70030 16507
81ecdfbb 16508cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
bec39cab 16509ac_cs_usage="\
81ecdfbb
RW
16510\`$as_me' instantiates files and other configuration actions
16511from templates according to the current configuration. Unless the files
16512and actions are specified as TAGs, all are instantiated by default.
234b45d4 16513
81ecdfbb 16514Usage: $0 [OPTION]... [TAG]...
234b45d4 16515
bec39cab 16516 -h, --help print this help, then exit
81ecdfbb
RW
16517 -V, --version print version number and configuration settings, then exit
16518 -q, --quiet, --silent
16519 do not print progress messages
bec39cab
AC
16520 -d, --debug don't remove temporary files
16521 --recheck update $as_me by reconfiguring in the same conditions
81ecdfbb
RW
16522 --file=FILE[:TEMPLATE]
16523 instantiate the configuration file FILE
16524 --header=FILE[:TEMPLATE]
16525 instantiate the configuration header FILE
234b45d4 16526
bec39cab
AC
16527Configuration files:
16528$config_files
234b45d4 16529
bec39cab
AC
16530Configuration headers:
16531$config_headers
234b45d4 16532
bec39cab
AC
16533Configuration links:
16534$config_links
234b45d4 16535
bec39cab
AC
16536Configuration commands:
16537$config_commands
16538
81ecdfbb 16539Report bugs to the package provider."
b4e70030 16540
81ecdfbb
RW
16541_ACEOF
16542cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
bec39cab
AC
16543ac_cs_version="\\
16544config.status
81ecdfbb
RW
16545configured by $0, generated by GNU Autoconf 2.64,
16546 with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
bec39cab 16547
81ecdfbb 16548Copyright (C) 2009 Free Software Foundation, Inc.
bec39cab
AC
16549This config.status script is free software; the Free Software Foundation
16550gives unlimited permission to copy, distribute and modify it."
81ecdfbb
RW
16551
16552ac_pwd='$ac_pwd'
16553srcdir='$srcdir'
16554INSTALL='$INSTALL'
16555MKDIR_P='$MKDIR_P'
16556AWK='$AWK'
16557test -n "\$AWK" || AWK=awk
bec39cab
AC
16558_ACEOF
16559
81ecdfbb
RW
16560cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
16561# The default lists apply if the user does not specify any file.
bec39cab
AC
16562ac_need_defaults=:
16563while test $# != 0
16564do
16565 case $1 in
16566 --*=*)
81ecdfbb
RW
16567 ac_option=`expr "X$1" : 'X\([^=]*\)='`
16568 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
bec39cab 16569 ac_shift=:
c906108c 16570 ;;
81ecdfbb 16571 *)
bec39cab
AC
16572 ac_option=$1
16573 ac_optarg=$2
16574 ac_shift=shift
c906108c 16575 ;;
bec39cab 16576 esac
c906108c 16577
bec39cab
AC
16578 case $ac_option in
16579 # Handling of the options.
bec39cab
AC
16580 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
16581 ac_cs_recheck=: ;;
81ecdfbb
RW
16582 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
16583 $as_echo "$ac_cs_version"; exit ;;
16584 --debug | --debu | --deb | --de | --d | -d )
bec39cab
AC
16585 debug=: ;;
16586 --file | --fil | --fi | --f )
16587 $ac_shift
81ecdfbb
RW
16588 case $ac_optarg in
16589 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
16590 esac
16591 as_fn_append CONFIG_FILES " '$ac_optarg'"
bec39cab
AC
16592 ac_need_defaults=false;;
16593 --header | --heade | --head | --hea )
16594 $ac_shift
81ecdfbb
RW
16595 case $ac_optarg in
16596 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
16597 esac
16598 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
bec39cab 16599 ac_need_defaults=false;;
81ecdfbb
RW
16600 --he | --h)
16601 # Conflict between --help and --header
16602 as_fn_error "ambiguous option: \`$1'
16603Try \`$0 --help' for more information.";;
16604 --help | --hel | -h )
16605 $as_echo "$ac_cs_usage"; exit ;;
bec39cab
AC
16606 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
16607 | -silent | --silent | --silen | --sile | --sil | --si | --s)
16608 ac_cs_silent=: ;;
c906108c 16609
bec39cab 16610 # This is an error.
81ecdfbb
RW
16611 -*) as_fn_error "unrecognized option: \`$1'
16612Try \`$0 --help' for more information." ;;
c906108c 16613
81ecdfbb
RW
16614 *) as_fn_append ac_config_targets " $1"
16615 ac_need_defaults=false ;;
c906108c 16616
bec39cab
AC
16617 esac
16618 shift
16619done
c906108c 16620
bec39cab 16621ac_configure_extra_args=
c906108c 16622
bec39cab
AC
16623if $ac_cs_silent; then
16624 exec 6>/dev/null
16625 ac_configure_extra_args="$ac_configure_extra_args --silent"
16626fi
c906108c 16627
bec39cab 16628_ACEOF
81ecdfbb 16629cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
bec39cab 16630if \$ac_cs_recheck; then
81ecdfbb
RW
16631 set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
16632 shift
16633 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
16634 CONFIG_SHELL='$SHELL'
16635 export CONFIG_SHELL
16636 exec "\$@"
bec39cab
AC
16637fi
16638
16639_ACEOF
81ecdfbb
RW
16640cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
16641exec 5>>config.log
16642{
16643 echo
16644 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
16645## Running $as_me. ##
16646_ASBOX
16647 $as_echo "$ac_log"
16648} >&5
bec39cab 16649
81ecdfbb
RW
16650_ACEOF
16651cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
c906108c 16652#
81ecdfbb 16653# INIT-COMMANDS
c906108c 16654#
a417dc56 16655ac_aux_dir=$ac_aux_dir DEPDIR=$DEPDIR
e28b3332 16656AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
b4e70030 16657
bec39cab
AC
16658_ACEOF
16659
81ecdfbb 16660cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
4e8d927d 16661
81ecdfbb 16662# Handling of arguments.
bec39cab 16663for ac_config_target in $ac_config_targets
c906108c 16664do
81ecdfbb
RW
16665 case $ac_config_target in
16666 "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h:config.in" ;;
16667 "depdir") CONFIG_COMMANDS="$CONFIG_COMMANDS depdir" ;;
16668 "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
16669 "$ac_config_links_1") CONFIG_LINKS="$CONFIG_LINKS $ac_config_links_1" ;;
16670 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
16671 ".gdbinit") CONFIG_FILES="$CONFIG_FILES .gdbinit:gdbinit.in" ;;
5ae98d25 16672 "doc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/Makefile" ;;
81ecdfbb 16673 "gnulib/Makefile") CONFIG_FILES="$CONFIG_FILES gnulib/Makefile" ;;
aa2e2d8d 16674 "data-directory/Makefile") CONFIG_FILES="$CONFIG_FILES data-directory/Makefile" ;;
81ecdfbb
RW
16675 "default") CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
16676
16677 *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
c906108c
SS
16678 esac
16679done
16680
81ecdfbb 16681
bec39cab
AC
16682# If the user did not use the arguments to specify the items to instantiate,
16683# then the envvar interface is used. Set only those that are not.
16684# We use the long form for the default assignment because of an extremely
16685# bizarre bug on SunOS 4.1.3.
16686if $ac_need_defaults; then
16687 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
16688 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
16689 test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
16690 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
16691fi
16692
b4e70030 16693# Have a temporary directory for convenience. Make it in the build tree
81ecdfbb 16694# simply because there is no reason against having it here, and in addition,
b4e70030 16695# creating and moving files from /tmp can sometimes cause problems.
81ecdfbb
RW
16696# Hook for its removal unless debugging.
16697# Note that there is a small window in which the directory will not be cleaned:
16698# after its creation but before its name has been assigned to `$tmp'.
b4e70030
JB
16699$debug ||
16700{
81ecdfbb
RW
16701 tmp=
16702 trap 'exit_status=$?
16703 { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
16704' 0
16705 trap 'as_fn_exit 1' 1 2 13 15
16706}
16707# Create a (secure) tmp directory for tmp files.
16708
16709{
16710 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
16711 test -n "$tmp" && test -d "$tmp"
16712} ||
16713{
16714 tmp=./conf$$-$RANDOM
16715 (umask 077 && mkdir "$tmp")
16716} || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5
16717
16718# Set up the scripts for CONFIG_FILES section.
16719# No need to generate them if there are no CONFIG_FILES.
16720# This happens for instance with `./config.status config.h'.
16721if test -n "$CONFIG_FILES"; then
16722
16723if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
16724 ac_cs_awk_getline=:
16725 ac_cs_awk_pipe_init=
16726 ac_cs_awk_read_file='
16727 while ((getline aline < (F[key])) > 0)
16728 print(aline)
16729 close(F[key])'
16730 ac_cs_awk_pipe_fini=
16731else
16732 ac_cs_awk_getline=false
16733 ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
16734 ac_cs_awk_read_file='
16735 print "|#_!!_#|"
16736 print "cat " F[key] " &&"
16737 '$ac_cs_awk_pipe_init
16738 # The final `:' finishes the AND list.
16739 ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
16740fi
16741ac_cr=`echo X | tr X '\015'`
16742# On cygwin, bash can eat \r inside `` if the user requested igncr.
16743# But we know of no other shell where ac_cr would be empty at this
16744# point, so we can use a bashism as a fallback.
16745if test "x$ac_cr" = x; then
16746 eval ac_cr=\$\'\\r\'
16747fi
16748ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
16749if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
16750 ac_cs_awk_cr='\r'
16751else
16752 ac_cs_awk_cr=$ac_cr
16753fi
16754
16755echo 'BEGIN {' >"$tmp/subs1.awk" &&
16756_ACEOF
16757
16758# Create commands to substitute file output variables.
16759{
16760 echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
16761 echo 'cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&' &&
16762 echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
16763 echo "_ACAWK" &&
16764 echo "_ACEOF"
16765} >conf$$files.sh &&
16766. ./conf$$files.sh ||
16767 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
16768rm -f conf$$files.sh
16769
16770{
16771 echo "cat >conf$$subs.awk <<_ACEOF" &&
16772 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
16773 echo "_ACEOF"
16774} >conf$$subs.sh ||
16775 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
16776ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
16777ac_delim='%!_!# '
16778for ac_last_try in false false false false false :; do
16779 . ./conf$$subs.sh ||
16780 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
16781
16782 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
16783 if test $ac_delim_n = $ac_delim_num; then
16784 break
16785 elif $ac_last_try; then
16786 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
16787 else
16788 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
16789 fi
16790done
16791rm -f conf$$subs.sh
16792
16793cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
16794cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
16795_ACEOF
16796sed -n '
16797h
16798s/^/S["/; s/!.*/"]=/
16799p
16800g
16801s/^[^!]*!//
16802:repl
16803t repl
16804s/'"$ac_delim"'$//
16805t delim
16806:nl
16807h
16808s/\(.\{148\}\).*/\1/
16809t more1
16810s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
16811p
16812n
16813b repl
16814:more1
16815s/["\\]/\\&/g; s/^/"/; s/$/"\\/
16816p
16817g
16818s/.\{148\}//
16819t nl
16820:delim
16821h
16822s/\(.\{148\}\).*/\1/
16823t more2
16824s/["\\]/\\&/g; s/^/"/; s/$/"/
16825p
16826b
16827:more2
16828s/["\\]/\\&/g; s/^/"/; s/$/"\\/
16829p
16830g
16831s/.\{148\}//
16832t delim
16833' <conf$$subs.awk | sed '
16834/^[^""]/{
16835 N
16836 s/\n//
16837}
16838' >>$CONFIG_STATUS || ac_write_fail=1
16839rm -f conf$$subs.awk
16840cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
16841_ACAWK
16842cat >>"\$tmp/subs1.awk" <<_ACAWK &&
16843 for (key in S) S_is_set[key] = 1
16844 FS = "\a"
16845 \$ac_cs_awk_pipe_init
16846}
16847{
16848 line = $ 0
16849 nfields = split(line, field, "@")
16850 substed = 0
16851 len = length(field[1])
16852 for (i = 2; i < nfields; i++) {
16853 key = field[i]
16854 keylen = length(key)
16855 if (S_is_set[key]) {
16856 value = S[key]
16857 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
16858 len += length(value) + length(field[++i])
16859 substed = 1
16860 } else
16861 len += 1 + keylen
16862 }
16863 if (nfields == 3 && !substed) {
16864 key = field[2]
16865 if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) {
16866 \$ac_cs_awk_read_file
16867 next
16868 }
16869 }
16870 print line
b4e70030 16871}
81ecdfbb
RW
16872\$ac_cs_awk_pipe_fini
16873_ACAWK
16874_ACEOF
16875cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
16876if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
16877 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
16878else
16879 cat
16880fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
16881 || as_fn_error "could not setup config files machinery" "$LINENO" 5
16882_ACEOF
16883
16884# VPATH may cause trouble with some makes, so we remove $(srcdir),
16885# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
16886# trailing colons and then remove the whole line if VPATH becomes empty
16887# (actually we leave an empty line to preserve line numbers).
16888if test "x$srcdir" = x.; then
16889 ac_vpsub='/^[ ]*VPATH[ ]*=/{
16890s/:*\$(srcdir):*/:/
16891s/:*\${srcdir}:*/:/
16892s/:*@srcdir@:*/:/
16893s/^\([^=]*=[ ]*\):*/\1/
16894s/:*$//
16895s/^[^=]*=[ ]*$//
16896}'
16897fi
16898
16899cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
16900fi # test -n "$CONFIG_FILES"
16901
16902# Set up the scripts for CONFIG_HEADERS section.
16903# No need to generate them if there are no CONFIG_HEADERS.
16904# This happens for instance with `./config.status Makefile'.
16905if test -n "$CONFIG_HEADERS"; then
16906cat >"$tmp/defines.awk" <<\_ACAWK ||
16907BEGIN {
16908_ACEOF
16909
16910# Transform confdefs.h into an awk script `defines.awk', embedded as
16911# here-document in config.status, that substitutes the proper values into
16912# config.h.in to produce config.h.
4e8d927d 16913
81ecdfbb
RW
16914# Create a delimiter string that does not exist in confdefs.h, to ease
16915# handling of long lines.
16916ac_delim='%!_!# '
16917for ac_last_try in false false :; do
16918 ac_t=`sed -n "/$ac_delim/p" confdefs.h`
16919 if test -z "$ac_t"; then
16920 break
16921 elif $ac_last_try; then
16922 as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5
16923 else
16924 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
16925 fi
16926done
4e8d927d 16927
81ecdfbb
RW
16928# For the awk script, D is an array of macro values keyed by name,
16929# likewise P contains macro parameters if any. Preserve backslash
16930# newline sequences.
16931
16932ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
16933sed -n '
16934s/.\{148\}/&'"$ac_delim"'/g
16935t rset
16936:rset
16937s/^[ ]*#[ ]*define[ ][ ]*/ /
16938t def
16939d
16940:def
16941s/\\$//
16942t bsnl
16943s/["\\]/\\&/g
16944s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
16945D["\1"]=" \3"/p
16946s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
16947d
16948:bsnl
16949s/["\\]/\\&/g
16950s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
16951D["\1"]=" \3\\\\\\n"\\/p
16952t cont
16953s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
16954t cont
16955d
16956:cont
16957n
16958s/.\{148\}/&'"$ac_delim"'/g
16959t clear
16960:clear
16961s/\\$//
16962t bsnlc
16963s/["\\]/\\&/g; s/^/"/; s/$/"/p
16964d
16965:bsnlc
16966s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
16967b cont
16968' <confdefs.h | sed '
16969s/'"$ac_delim"'/"\\\
16970"/g' >>$CONFIG_STATUS || ac_write_fail=1
16971
16972cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
16973 for (key in D) D_is_set[key] = 1
16974 FS = "\a"
16975}
16976/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
16977 line = \$ 0
16978 split(line, arg, " ")
16979 if (arg[1] == "#") {
16980 defundef = arg[2]
16981 mac1 = arg[3]
16982 } else {
16983 defundef = substr(arg[1], 2)
16984 mac1 = arg[2]
16985 }
16986 split(mac1, mac2, "(") #)
16987 macro = mac2[1]
16988 prefix = substr(line, 1, index(line, defundef) - 1)
16989 if (D_is_set[macro]) {
16990 # Preserve the white space surrounding the "#".
16991 print prefix "define", macro P[macro] D[macro]
16992 next
16993 } else {
16994 # Replace #undef with comments. This is necessary, for example,
16995 # in the case of _POSIX_SOURCE, which is predefined and required
16996 # on some systems where configure will not decide to define it.
16997 if (defundef == "undef") {
16998 print "/*", prefix defundef, macro, "*/"
16999 next
17000 }
17001 }
b4e70030 17002}
81ecdfbb
RW
17003{ print }
17004_ACAWK
b4e70030 17005_ACEOF
81ecdfbb
RW
17006cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
17007 as_fn_error "could not setup config headers machinery" "$LINENO" 5
17008fi # test -n "$CONFIG_HEADERS"
4e8d927d 17009
4e8d927d 17010
81ecdfbb
RW
17011eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :L $CONFIG_LINKS :C $CONFIG_COMMANDS"
17012shift
17013for ac_tag
17014do
17015 case $ac_tag in
17016 :[FHLC]) ac_mode=$ac_tag; continue;;
17017 esac
17018 case $ac_mode$ac_tag in
17019 :[FHL]*:*);;
17020 :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;;
17021 :[FH]-) ac_tag=-:-;;
17022 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
17023 esac
17024 ac_save_IFS=$IFS
17025 IFS=:
17026 set x $ac_tag
17027 IFS=$ac_save_IFS
17028 shift
17029 ac_file=$1
17030 shift
4e8d927d 17031
81ecdfbb
RW
17032 case $ac_mode in
17033 :L) ac_source=$1;;
17034 :[FH])
17035 ac_file_inputs=
17036 for ac_f
17037 do
17038 case $ac_f in
17039 -) ac_f="$tmp/stdin";;
17040 *) # Look for the file first in the build tree, then in the source tree
17041 # (if the path is not absolute). The absolute path cannot be DOS-style,
17042 # because $ac_f cannot contain `:'.
17043 test -f "$ac_f" ||
17044 case $ac_f in
17045 [\\/$]*) false;;
17046 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
17047 esac ||
17048 as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;;
17049 esac
17050 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
17051 as_fn_append ac_file_inputs " '$ac_f'"
17052 done
17053
17054 # Let's still pretend it is `configure' which instantiates (i.e., don't
17055 # use $as_me), people would be surprised to read:
17056 # /* config.h. Generated by config.status. */
17057 configure_input='Generated from '`
17058 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
17059 `' by configure.'
17060 if test x"$ac_file" != x-; then
17061 configure_input="$ac_file. $configure_input"
17062 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
17063$as_echo "$as_me: creating $ac_file" >&6;}
b4e70030 17064 fi
81ecdfbb
RW
17065 # Neutralize special characters interpreted by sed in replacement strings.
17066 case $configure_input in #(
17067 *\&* | *\|* | *\\* )
17068 ac_sed_conf_input=`$as_echo "$configure_input" |
17069 sed 's/[\\\\&|]/\\\\&/g'`;; #(
17070 *) ac_sed_conf_input=$configure_input;;
17071 esac
4e8d927d 17072
81ecdfbb
RW
17073 case $ac_tag in
17074 *:-:* | *:-) cat >"$tmp/stdin" \
17075 || as_fn_error "could not create $ac_file" "$LINENO" 5 ;;
17076 esac
17077 ;;
c906108c
SS
17078 esac
17079
81ecdfbb 17080 ac_dir=`$as_dirname -- "$ac_file" ||
bec39cab
AC
17081$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
17082 X"$ac_file" : 'X\(//\)[^/]' \| \
17083 X"$ac_file" : 'X\(//\)$' \| \
81ecdfbb
RW
17084 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
17085$as_echo X"$ac_file" |
17086 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
17087 s//\1/
17088 q
17089 }
17090 /^X\(\/\/\)[^/].*/{
17091 s//\1/
17092 q
17093 }
17094 /^X\(\/\/\)$/{
17095 s//\1/
17096 q
17097 }
17098 /^X\(\/\).*/{
17099 s//\1/
17100 q
17101 }
17102 s/.*/./; q'`
17103 as_dir="$ac_dir"; as_fn_mkdir_p
bec39cab
AC
17104 ac_builddir=.
17105
81ecdfbb
RW
17106case "$ac_dir" in
17107.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
17108*)
17109 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
17110 # A ".." for each directory in $ac_dir_suffix.
17111 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
17112 case $ac_top_builddir_sub in
17113 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
17114 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
17115 esac ;;
17116esac
17117ac_abs_top_builddir=$ac_pwd
17118ac_abs_builddir=$ac_pwd$ac_dir_suffix
17119# for backward compatibility:
17120ac_top_builddir=$ac_top_build_prefix
bec39cab
AC
17121
17122case $srcdir in
81ecdfbb 17123 .) # We are building in place.
bec39cab 17124 ac_srcdir=.
81ecdfbb
RW
17125 ac_top_srcdir=$ac_top_builddir_sub
17126 ac_abs_top_srcdir=$ac_pwd ;;
17127 [\\/]* | ?:[\\/]* ) # Absolute name.
bec39cab 17128 ac_srcdir=$srcdir$ac_dir_suffix;
81ecdfbb
RW
17129 ac_top_srcdir=$srcdir
17130 ac_abs_top_srcdir=$srcdir ;;
17131 *) # Relative name.
17132 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
17133 ac_top_srcdir=$ac_top_build_prefix$srcdir
17134 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
bec39cab 17135esac
81ecdfbb 17136ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
bec39cab 17137
c906108c 17138
81ecdfbb
RW
17139 case $ac_mode in
17140 :F)
17141 #
17142 # CONFIG_FILE
17143 #
c906108c 17144
bec39cab
AC
17145 case $INSTALL in
17146 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
81ecdfbb 17147 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
c906108c 17148 esac
81ecdfbb
RW
17149 ac_MKDIR_P=$MKDIR_P
17150 case $MKDIR_P in
17151 [\\/$]* | ?:[\\/]* ) ;;
17152 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
17153 esac
17154_ACEOF
121ce6e5 17155
81ecdfbb
RW
17156cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
17157# If the template does not know about datarootdir, expand it.
17158# FIXME: This hack should be removed a few years after 2.60.
17159ac_datarootdir_hack=; ac_datarootdir_seen=
17160ac_sed_dataroot='
17161/datarootdir/ {
17162 p
17163 q
17164}
17165/@datadir@/p
17166/@docdir@/p
17167/@infodir@/p
17168/@localedir@/p
17169/@mandir@/p'
17170case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
17171*datarootdir*) ac_datarootdir_seen=yes;;
17172*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
17173 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
17174$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
17175_ACEOF
17176cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
17177 ac_datarootdir_hack='
17178 s&@datadir@&$datadir&g
17179 s&@docdir@&$docdir&g
17180 s&@infodir@&$infodir&g
17181 s&@localedir@&$localedir&g
17182 s&@mandir@&$mandir&g
17183 s&\\\${datarootdir}&$datarootdir&g' ;;
17184esac
4e8d927d 17185_ACEOF
81ecdfbb
RW
17186
17187# Neutralize VPATH when `$srcdir' = `.'.
17188# Shell code in configure.ac might set extrasub.
17189# FIXME: do we really want to maintain this feature?
17190cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
17191ac_sed_extra="$ac_vpsub
bec39cab
AC
17192$extrasub
17193_ACEOF
81ecdfbb 17194cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
bec39cab
AC
17195:t
17196/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
81ecdfbb
RW
17197s|@configure_input@|$ac_sed_conf_input|;t t
17198s&@top_builddir@&$ac_top_builddir_sub&;t t
17199s&@top_build_prefix@&$ac_top_build_prefix&;t t
17200s&@srcdir@&$ac_srcdir&;t t
17201s&@abs_srcdir@&$ac_abs_srcdir&;t t
17202s&@top_srcdir@&$ac_top_srcdir&;t t
17203s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
17204s&@builddir@&$ac_builddir&;t t
17205s&@abs_builddir@&$ac_abs_builddir&;t t
17206s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
17207s&@INSTALL@&$ac_INSTALL&;t t
17208s&@MKDIR_P@&$ac_MKDIR_P&;t t
17209$ac_datarootdir_hack
17210"
17211eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
17212if $ac_cs_awk_getline; then
17213 $AWK -f "$tmp/subs.awk"
17214else
17215 $AWK -f "$tmp/subs.awk" | $SHELL
17216fi >$tmp/out \
17217 || as_fn_error "could not create $ac_file" "$LINENO" 5
17218
17219test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
17220 { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
17221 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
17222 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
17223which seems to be undefined. Please make sure it is defined." >&5
17224$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
17225which seems to be undefined. Please make sure it is defined." >&2;}
17226
17227 rm -f "$tmp/stdin"
bec39cab 17228 case $ac_file in
81ecdfbb
RW
17229 -) cat "$tmp/out" && rm -f "$tmp/out";;
17230 *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
17231 esac \
17232 || as_fn_error "could not create $ac_file" "$LINENO" 5
17233 ;;
17234 :H)
17235 #
17236 # CONFIG_HEADER
17237 #
bec39cab 17238 if test x"$ac_file" != x-; then
81ecdfbb
RW
17239 {
17240 $as_echo "/* $configure_input */" \
17241 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
17242 } >"$tmp/config.h" \
17243 || as_fn_error "could not create $ac_file" "$LINENO" 5
17244 if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
17245 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
17246$as_echo "$as_me: $ac_file is unchanged" >&6;}
bec39cab 17247 else
81ecdfbb
RW
17248 rm -f "$ac_file"
17249 mv "$tmp/config.h" "$ac_file" \
17250 || as_fn_error "could not create $ac_file" "$LINENO" 5
bec39cab
AC
17251 fi
17252 else
81ecdfbb
RW
17253 $as_echo "/* $configure_input */" \
17254 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
17255 || as_fn_error "could not create -" "$LINENO" 5
bec39cab 17256 fi
81ecdfbb
RW
17257# Compute "$ac_file"'s index in $config_headers.
17258_am_arg="$ac_file"
e28b3332
DJ
17259_am_stamp_count=1
17260for _am_header in $config_headers :; do
17261 case $_am_header in
81ecdfbb 17262 $_am_arg | $_am_arg:* )
e28b3332
DJ
17263 break ;;
17264 * )
17265 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
17266 esac
17267done
81ecdfbb
RW
17268echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
17269$as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
17270 X"$_am_arg" : 'X\(//\)[^/]' \| \
17271 X"$_am_arg" : 'X\(//\)$' \| \
17272 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
17273$as_echo X"$_am_arg" |
17274 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
17275 s//\1/
17276 q
17277 }
17278 /^X\(\/\/\)[^/].*/{
17279 s//\1/
17280 q
17281 }
17282 /^X\(\/\/\)$/{
17283 s//\1/
17284 q
17285 }
17286 /^X\(\/\).*/{
17287 s//\1/
17288 q
17289 }
17290 s/.*/./; q'`/stamp-h$_am_stamp_count
17291 ;;
17292 :L)
17293 #
17294 # CONFIG_LINK
17295 #
c906108c 17296
81ecdfbb
RW
17297 if test "$ac_source" = "$ac_file" && test "$srcdir" = '.'; then
17298 :
b4e70030 17299 else
81ecdfbb
RW
17300 # Prefer the file from the source tree if names are identical.
17301 if test "$ac_source" = "$ac_file" || test ! -r "$ac_source"; then
17302 ac_source=$srcdir/$ac_source
17303 fi
b4e70030 17304
81ecdfbb
RW
17305 { $as_echo "$as_me:${as_lineno-$LINENO}: linking $ac_source to $ac_file" >&5
17306$as_echo "$as_me: linking $ac_source to $ac_file" >&6;}
b4e70030 17307
81ecdfbb
RW
17308 if test ! -r "$ac_source"; then
17309 as_fn_error "$ac_source: file not found" "$LINENO" 5
17310 fi
17311 rm -f "$ac_file"
bec39cab 17312
81ecdfbb
RW
17313 # Try a relative symlink, then a hard link, then a copy.
17314 case $srcdir in
17315 [\\/$]* | ?:[\\/]* ) ac_rel_source=$ac_source ;;
17316 *) ac_rel_source=$ac_top_build_prefix$ac_source ;;
17317 esac
17318 ln -s "$ac_rel_source" "$ac_file" 2>/dev/null ||
17319 ln "$ac_source" "$ac_file" 2>/dev/null ||
17320 cp -p "$ac_source" "$ac_file" ||
17321 as_fn_error "cannot link or copy $ac_source to $ac_file" "$LINENO" 5
17322 fi
17323 ;;
17324 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
17325$as_echo "$as_me: executing $ac_file commands" >&6;}
17326 ;;
c906108c 17327 esac
b4e70030 17328
bec39cab 17329
81ecdfbb
RW
17330 case $ac_file$ac_mode in
17331 "depdir":C) $SHELL $ac_aux_dir/mkinstalldirs $DEPDIR ;;
17332 "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
17333 # Autoconf 2.62 quotes --file arguments for eval, but not when files
17334 # are listed without --file. Let's play safe and only enable the eval
17335 # if we detect the quoting.
17336 case $CONFIG_FILES in
17337 *\'*) eval set x "$CONFIG_FILES" ;;
17338 *) set x $CONFIG_FILES ;;
17339 esac
17340 shift
17341 for mf
17342 do
17343 # Strip MF so we end up with the name of the file.
17344 mf=`echo "$mf" | sed -e 's/:.*$//'`
17345 # Check whether this is an Automake generated Makefile or not.
17346 # We used to match only the files named `Makefile.in', but
17347 # some people rename them; so instead we look at the file content.
17348 # Grep'ing the first line is not enough: some people post-process
17349 # each Makefile.in and add a new line on top of each file to say so.
17350 # Grep'ing the whole file is not good either: AIX grep has a line
17351 # limit of 2048, but all sed's we know have understand at least 4000.
17352 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
17353 dirpart=`$as_dirname -- "$mf" ||
e28b3332
DJ
17354$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
17355 X"$mf" : 'X\(//\)[^/]' \| \
17356 X"$mf" : 'X\(//\)$' \| \
81ecdfbb
RW
17357 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
17358$as_echo X"$mf" |
17359 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
17360 s//\1/
17361 q
17362 }
17363 /^X\(\/\/\)[^/].*/{
17364 s//\1/
17365 q
17366 }
17367 /^X\(\/\/\)$/{
17368 s//\1/
17369 q
17370 }
17371 /^X\(\/\).*/{
17372 s//\1/
17373 q
17374 }
17375 s/.*/./; q'`
17376 else
17377 continue
17378 fi
17379 # Extract the definition of DEPDIR, am__include, and am__quote
17380 # from the Makefile without running `make'.
17381 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
17382 test -z "$DEPDIR" && continue
17383 am__include=`sed -n 's/^am__include = //p' < "$mf"`
17384 test -z "am__include" && continue
17385 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
17386 # When using ansi2knr, U may be empty or an underscore; expand it
17387 U=`sed -n 's/^U = //p' < "$mf"`
17388 # Find all dependency output files, they are included files with
17389 # $(DEPDIR) in their names. We invoke sed twice because it is the
17390 # simplest approach to changing $(DEPDIR) to its actual value in the
17391 # expansion.
17392 for file in `sed -n "
17393 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
17394 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
17395 # Make sure the directory exists.
17396 test -f "$dirpart/$file" && continue
17397 fdir=`$as_dirname -- "$file" ||
e28b3332
DJ
17398$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
17399 X"$file" : 'X\(//\)[^/]' \| \
17400 X"$file" : 'X\(//\)$' \| \
81ecdfbb
RW
17401 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
17402$as_echo X"$file" |
17403 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
17404 s//\1/
17405 q
17406 }
17407 /^X\(\/\/\)[^/].*/{
17408 s//\1/
17409 q
17410 }
17411 /^X\(\/\/\)$/{
17412 s//\1/
17413 q
17414 }
17415 /^X\(\/\).*/{
17416 s//\1/
17417 q
17418 }
17419 s/.*/./; q'`
17420 as_dir=$dirpart/$fdir; as_fn_mkdir_p
17421 # echo "creating $dirpart/$file"
17422 echo '# dummy' > "$dirpart/$file"
e28b3332 17423 done
e28b3332 17424 done
81ecdfbb 17425}
4e8d927d 17426 ;;
81ecdfbb 17427 "default":C)
c906108c
SS
17428case x$CONFIG_HEADERS in
17429xconfig.h:config.in)
17430echo > stamp-h ;;
17431esac
bec39cab 17432 ;;
81ecdfbb 17433
bec39cab 17434 esac
81ecdfbb 17435done # for ac_tag
c906108c 17436
bec39cab 17437
81ecdfbb 17438as_fn_exit 0
bec39cab 17439_ACEOF
bec39cab
AC
17440ac_clean_files=$ac_clean_files_save
17441
81ecdfbb
RW
17442test $ac_write_fail = 0 ||
17443 as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5
17444
bec39cab
AC
17445
17446# configure is writing to config.log, and then calls config.status.
17447# config.status does its own redirection, appending to config.log.
17448# Unfortunately, on DOS this fails, as config.log is still kept open
17449# by configure, so config.status won't be able to write to it; its
17450# output is simply discarded. So we exec the FD to /dev/null,
17451# effectively closing config.log, so it can be properly (re)opened and
17452# appended to by config.status. When coming back to configure, we
17453# need to make the FD available again.
17454if test "$no_create" != yes; then
17455 ac_cs_success=:
17456 ac_config_status_args=
17457 test "$silent" = yes &&
17458 ac_config_status_args="$ac_config_status_args --quiet"
17459 exec 5>/dev/null
17460 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
17461 exec 5>>config.log
17462 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
17463 # would make configure fail if this is the last instruction.
81ecdfbb 17464 $ac_cs_success || as_fn_exit $?
bec39cab 17465fi
c906108c 17466
bec39cab 17467#
81ecdfbb 17468# CONFIG_SUBDIRS section.
bec39cab 17469#
c906108c
SS
17470if test "$no_recursion" != yes; then
17471
81ecdfbb
RW
17472 # Remove --cache-file, --srcdir, and --disable-option-checking arguments
17473 # so they do not pile up.
c906108c
SS
17474 ac_sub_configure_args=
17475 ac_prev=
fdc59709
PB
17476 eval "set x $ac_configure_args"
17477 shift
17478 for ac_arg
17479 do
c906108c
SS
17480 if test -n "$ac_prev"; then
17481 ac_prev=
17482 continue
17483 fi
bec39cab 17484 case $ac_arg in
c906108c
SS
17485 -cache-file | --cache-file | --cache-fil | --cache-fi \
17486 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
17487 ac_prev=cache_file ;;
17488 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
bec39cab
AC
17489 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* \
17490 | --c=*)
17491 ;;
17492 --config-cache | -C)
c906108c
SS
17493 ;;
17494 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
17495 ac_prev=srcdir ;;
17496 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
17497 ;;
bec39cab
AC
17498 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
17499 ac_prev=prefix ;;
17500 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
17501 ;;
81ecdfbb
RW
17502 --disable-option-checking)
17503 ;;
fdc59709
PB
17504 *)
17505 case $ac_arg in
81ecdfbb 17506 *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
fdc59709 17507 esac
81ecdfbb 17508 as_fn_append ac_sub_configure_args " '$ac_arg'" ;;
c906108c
SS
17509 esac
17510 done
17511
bec39cab
AC
17512 # Always prepend --prefix to ensure using the same prefix
17513 # in subdir configurations.
fdc59709
PB
17514 ac_arg="--prefix=$prefix"
17515 case $ac_arg in
81ecdfbb 17516 *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
fdc59709 17517 esac
81ecdfbb
RW
17518 ac_sub_configure_args="'$ac_arg' $ac_sub_configure_args"
17519
17520 # Pass --silent
17521 if test "$silent" = yes; then
17522 ac_sub_configure_args="--silent $ac_sub_configure_args"
17523 fi
17524
17525 # Always prepend --disable-option-checking to silence warnings, since
17526 # different subdirs can have different --enable and --with options.
17527 ac_sub_configure_args="--disable-option-checking $ac_sub_configure_args"
bec39cab 17528
b4e70030 17529 ac_popdir=`pwd`
bec39cab 17530 for ac_dir in : $subdirs; do test "x$ac_dir" = x: && continue
c906108c
SS
17531
17532 # Do not complain, so a configure script can configure whichever
17533 # parts of a large source tree are present.
fdc59709 17534 test -d "$srcdir/$ac_dir" || continue
c906108c 17535
81ecdfbb
RW
17536 ac_msg="=== configuring in $ac_dir (`pwd`/$ac_dir)"
17537 $as_echo "$as_me:${as_lineno-$LINENO}: $ac_msg" >&5
17538 $as_echo "$ac_msg" >&6
17539 as_dir="$ac_dir"; as_fn_mkdir_p
bec39cab
AC
17540 ac_builddir=.
17541
81ecdfbb
RW
17542case "$ac_dir" in
17543.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
17544*)
17545 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
17546 # A ".." for each directory in $ac_dir_suffix.
17547 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
17548 case $ac_top_builddir_sub in
17549 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
17550 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
17551 esac ;;
17552esac
17553ac_abs_top_builddir=$ac_pwd
17554ac_abs_builddir=$ac_pwd$ac_dir_suffix
17555# for backward compatibility:
17556ac_top_builddir=$ac_top_build_prefix
bec39cab
AC
17557
17558case $srcdir in
81ecdfbb 17559 .) # We are building in place.
bec39cab 17560 ac_srcdir=.
81ecdfbb
RW
17561 ac_top_srcdir=$ac_top_builddir_sub
17562 ac_abs_top_srcdir=$ac_pwd ;;
17563 [\\/]* | ?:[\\/]* ) # Absolute name.
bec39cab 17564 ac_srcdir=$srcdir$ac_dir_suffix;
81ecdfbb
RW
17565 ac_top_srcdir=$srcdir
17566 ac_abs_top_srcdir=$srcdir ;;
17567 *) # Relative name.
17568 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
17569 ac_top_srcdir=$ac_top_build_prefix$srcdir
17570 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
bec39cab 17571esac
81ecdfbb 17572ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
c906108c 17573
c906108c 17574
fdc59709 17575 cd "$ac_dir"
c906108c
SS
17576
17577 # Check for guested configure; otherwise get Cygnus style configure.
fdc59709
PB
17578 if test -f "$ac_srcdir/configure.gnu"; then
17579 ac_sub_configure=$ac_srcdir/configure.gnu
17580 elif test -f "$ac_srcdir/configure"; then
17581 ac_sub_configure=$ac_srcdir/configure
17582 elif test -f "$ac_srcdir/configure.in"; then
17583 # This should be Cygnus configure.
17584 ac_sub_configure=$ac_aux_dir/configure
c906108c 17585 else
81ecdfbb
RW
17586 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no configuration information is in $ac_dir" >&5
17587$as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2;}
c906108c
SS
17588 ac_sub_configure=
17589 fi
17590
17591 # The recursion is here.
17592 if test -n "$ac_sub_configure"; then
c906108c 17593 # Make the cache file name correct relative to the subdirectory.
bec39cab
AC
17594 case $cache_file in
17595 [\\/]* | ?:[\\/]* ) ac_sub_cache_file=$cache_file ;;
81ecdfbb
RW
17596 *) # Relative name.
17597 ac_sub_cache_file=$ac_top_build_prefix$cache_file ;;
c906108c 17598 esac
c906108c 17599
81ecdfbb
RW
17600 { $as_echo "$as_me:${as_lineno-$LINENO}: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&5
17601$as_echo "$as_me: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&6;}
c906108c 17602 # The eval makes quoting arguments work.
fdc59709
PB
17603 eval "\$SHELL \"\$ac_sub_configure\" $ac_sub_configure_args \
17604 --cache-file=\"\$ac_sub_cache_file\" --srcdir=\"\$ac_srcdir\"" ||
81ecdfbb 17605 as_fn_error "$ac_sub_configure failed for $ac_dir" "$LINENO" 5
c906108c
SS
17606 fi
17607
fdc59709 17608 cd "$ac_popdir"
c906108c
SS
17609 done
17610fi
81ecdfbb
RW
17611if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
17612 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
17613$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
17614fi
c906108c
SS
17615
17616
17617exit 0
This page took 2.034335 seconds and 4 git commands to generate.