]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blame - gdb/configure
Fix doc build dependencies for --with-system-readline
[thirdparty/binutils-gdb.git] / gdb / configure
CommitLineData
c906108c 1#! /bin/sh
c906108c 2# Guess values for system-dependent variables and create Makefiles.
d0ac1c44
SM
3# Generated by GNU Autoconf 2.69.
4#
5#
6# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
81ecdfbb 7#
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.
d0ac1c44 90as_myself=
81ecdfbb
RW
91case $0 in #((
92 *[\\/]* ) as_myself=$0 ;;
93 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
94for as_dir in $PATH
95do
96 IFS=$as_save_IFS
97 test -z "$as_dir" && as_dir=.
98 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
99 done
100IFS=$as_save_IFS
101
102 ;;
103esac
104# We did not find ourselves, most probably we were run as `sh COMMAND'
105# in which case we are not to be found in the path.
106if test "x$as_myself" = x; then
107 as_myself=$0
108fi
109if test ! -f "$as_myself"; then
110 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
111 exit 1
112fi
113
114# Unset variables that we do not need and which cause bugs (e.g. in
115# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
116# suppresses any "Segmentation fault" message there. '((' could
117# trigger a bug in pdksh 5.2.14.
118for as_var in BASH_ENV ENV MAIL MAILPATH
119do eval test x\${$as_var+set} = xset \
120 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
121done
bec39cab
AC
122PS1='$ '
123PS2='> '
124PS4='+ '
125
126# NLS nuisances.
81ecdfbb
RW
127LC_ALL=C
128export LC_ALL
129LANGUAGE=C
130export LANGUAGE
131
132# CDPATH.
133(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
134
d0ac1c44
SM
135# Use a proper internal environment variable to ensure we don't fall
136 # into an infinite loop, continuously re-executing ourselves.
137 if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
138 _as_can_reexec=no; export _as_can_reexec;
139 # We cannot yet assume a decent shell, so we have to provide a
140# neutralization value for shells without unset; and this also
141# works around shells that cannot unset nonexistent variables.
142# Preserve -v and -x to the replacement shell.
143BASH_ENV=/dev/null
144ENV=/dev/null
145(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
146case $- in # ((((
147 *v*x* | *x*v* ) as_opts=-vx ;;
148 *v* ) as_opts=-v ;;
149 *x* ) as_opts=-x ;;
150 * ) as_opts= ;;
151esac
152exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
153# Admittedly, this is quite paranoid, since all the known shells bail
154# out after a failed `exec'.
155$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
156as_fn_exit 255
157 fi
158 # We don't want this to propagate to other subprocesses.
159 { _as_can_reexec=; unset _as_can_reexec;}
81ecdfbb
RW
160if test "x$CONFIG_SHELL" = x; then
161 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
162 emulate sh
163 NULLCMD=:
164 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
165 # is contrary to our usage. Disable this feature.
166 alias -g '\${1+\"\$@\"}'='\"\$@\"'
167 setopt NO_GLOB_SUBST
168else
169 case \`(set -o) 2>/dev/null\` in #(
170 *posix*) :
171 set -o posix ;; #(
172 *) :
173 ;;
174esac
175fi
176"
177 as_required="as_fn_return () { (exit \$1); }
178as_fn_success () { as_fn_return 0; }
179as_fn_failure () { as_fn_return 1; }
180as_fn_ret_success () { return 0; }
181as_fn_ret_failure () { return 1; }
182
183exitcode=0
184as_fn_success || { exitcode=1; echo as_fn_success failed.; }
185as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
186as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
187as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
188if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
189
190else
191 exitcode=1; echo positional parameters were not saved.
192fi
d0ac1c44
SM
193test x\$exitcode = x0 || exit 1
194test -x / || exit 1"
81ecdfbb
RW
195 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
196 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
197 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
198 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
b686ecb5
JM
199test \$(( 1 + 1 )) = 2 || exit 1
200
201 test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || (
202 ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
203 ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
204 ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
205 PATH=/empty FPATH=/empty; export PATH FPATH
206 test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\
207 || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1"
81ecdfbb
RW
208 if (eval "$as_required") 2>/dev/null; then :
209 as_have_required=yes
210else
211 as_have_required=no
212fi
213 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
214
215else
216 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
217as_found=false
218for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
bec39cab 219do
81ecdfbb
RW
220 IFS=$as_save_IFS
221 test -z "$as_dir" && as_dir=.
222 as_found=:
223 case $as_dir in #(
224 /*)
225 for as_base in sh bash ksh sh5; do
226 # Try only shells that exist, to save several forks.
227 as_shell=$as_dir/$as_base
228 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
229 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
230 CONFIG_SHELL=$as_shell as_have_required=yes
231 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
232 break 2
233fi
234fi
235 done;;
236 esac
237 as_found=false
238done
239$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
240 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
241 CONFIG_SHELL=$SHELL as_have_required=yes
242fi; }
243IFS=$as_save_IFS
244
245
246 if test "x$CONFIG_SHELL" != x; then :
d0ac1c44
SM
247 export CONFIG_SHELL
248 # We cannot yet assume a decent shell, so we have to provide a
249# neutralization value for shells without unset; and this also
250# works around shells that cannot unset nonexistent variables.
251# Preserve -v and -x to the replacement shell.
252BASH_ENV=/dev/null
253ENV=/dev/null
254(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
255case $- in # ((((
256 *v*x* | *x*v* ) as_opts=-vx ;;
257 *v* ) as_opts=-v ;;
258 *x* ) as_opts=-x ;;
259 * ) as_opts= ;;
260esac
261exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
262# Admittedly, this is quite paranoid, since all the known shells bail
263# out after a failed `exec'.
264$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
265exit 255
81ecdfbb
RW
266fi
267
268 if test x$as_have_required = xno; then :
269 $as_echo "$0: This script requires a shell more modern than all"
270 $as_echo "$0: the shells that I found on your system."
271 if test x${ZSH_VERSION+set} = xset ; then
272 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
273 $as_echo "$0: be upgraded to zsh 4.3.4 or later."
bec39cab 274 else
81ecdfbb
RW
275 $as_echo "$0: Please tell bug-autoconf@gnu.org about your system,
276$0: including any error possibly output before this
277$0: message. Then install a modern shell, or manually run
278$0: the script under such a shell if you do have one."
bec39cab 279 fi
81ecdfbb
RW
280 exit 1
281fi
282fi
283fi
284SHELL=${CONFIG_SHELL-/bin/sh}
285export SHELL
286# Unset more variables known to interfere with behavior of common tools.
287CLICOLOR_FORCE= GREP_OPTIONS=
288unset CLICOLOR_FORCE GREP_OPTIONS
289
290## --------------------- ##
291## M4sh Shell Functions. ##
292## --------------------- ##
293# as_fn_unset VAR
294# ---------------
295# Portably unset VAR.
296as_fn_unset ()
297{
298 { eval $1=; unset $1;}
299}
300as_unset=as_fn_unset
301
302# as_fn_set_status STATUS
303# -----------------------
304# Set $? to STATUS, without forking.
305as_fn_set_status ()
306{
307 return $1
308} # as_fn_set_status
bec39cab 309
81ecdfbb
RW
310# as_fn_exit STATUS
311# -----------------
312# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
313as_fn_exit ()
314{
315 set +e
316 as_fn_set_status $1
317 exit $1
318} # as_fn_exit
319
320# as_fn_mkdir_p
321# -------------
322# Create "$as_dir" as a directory, including parents if necessary.
323as_fn_mkdir_p ()
324{
325
326 case $as_dir in #(
327 -*) as_dir=./$as_dir;;
328 esac
329 test -d "$as_dir" || eval $as_mkdir_p || {
330 as_dirs=
331 while :; do
332 case $as_dir in #(
333 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
334 *) as_qdir=$as_dir;;
335 esac
336 as_dirs="'$as_qdir' $as_dirs"
337 as_dir=`$as_dirname -- "$as_dir" ||
338$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
339 X"$as_dir" : 'X\(//\)[^/]' \| \
340 X"$as_dir" : 'X\(//\)$' \| \
341 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
342$as_echo X"$as_dir" |
343 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
344 s//\1/
345 q
346 }
347 /^X\(\/\/\)[^/].*/{
348 s//\1/
349 q
350 }
351 /^X\(\/\/\)$/{
352 s//\1/
353 q
354 }
355 /^X\(\/\).*/{
356 s//\1/
357 q
358 }
359 s/.*/./; q'`
360 test -d "$as_dir" && break
361 done
362 test -z "$as_dirs" || eval "mkdir $as_dirs"
d0ac1c44 363 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
81ecdfbb
RW
364
365
366} # as_fn_mkdir_p
d0ac1c44
SM
367
368# as_fn_executable_p FILE
369# -----------------------
370# Test if FILE is an executable regular file.
371as_fn_executable_p ()
372{
373 test -f "$1" && test -x "$1"
374} # as_fn_executable_p
81ecdfbb
RW
375# as_fn_append VAR VALUE
376# ----------------------
377# Append the text in VALUE to the end of the definition contained in VAR. Take
378# advantage of any shell optimizations that allow amortized linear growth over
379# repeated appends, instead of the typical quadratic growth present in naive
380# implementations.
381if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
382 eval 'as_fn_append ()
383 {
384 eval $1+=\$2
385 }'
386else
387 as_fn_append ()
388 {
389 eval $1=\$$1\$2
390 }
391fi # as_fn_append
392
393# as_fn_arith ARG...
394# ------------------
395# Perform arithmetic evaluation on the ARGs, and store the result in the
396# global $as_val. Take advantage of shells that can avoid forks. The arguments
397# must be portable across $(()) and expr.
398if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
399 eval 'as_fn_arith ()
400 {
401 as_val=$(( $* ))
402 }'
403else
404 as_fn_arith ()
405 {
406 as_val=`expr "$@" || test $? -eq 1`
407 }
408fi # as_fn_arith
409
410
d0ac1c44
SM
411# as_fn_error STATUS ERROR [LINENO LOG_FD]
412# ----------------------------------------
81ecdfbb
RW
413# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
414# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
d0ac1c44 415# script with STATUS, using 1 if that was 0.
81ecdfbb
RW
416as_fn_error ()
417{
d0ac1c44
SM
418 as_status=$1; test $as_status -eq 0 && as_status=1
419 if test "$4"; then
420 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
421 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
81ecdfbb 422 fi
d0ac1c44 423 $as_echo "$as_me: error: $2" >&2
81ecdfbb
RW
424 as_fn_exit $as_status
425} # as_fn_error
426
427if expr a : '\(a\)' >/dev/null 2>&1 &&
428 test "X`expr 00001 : '.*\(...\)'`" = X001; then
bec39cab
AC
429 as_expr=expr
430else
431 as_expr=false
432fi
433
81ecdfbb 434if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
bec39cab
AC
435 as_basename=basename
436else
437 as_basename=false
438fi
439
81ecdfbb
RW
440if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
441 as_dirname=dirname
442else
443 as_dirname=false
444fi
bec39cab 445
81ecdfbb 446as_me=`$as_basename -- "$0" ||
bec39cab
AC
447$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
448 X"$0" : 'X\(//\)$' \| \
81ecdfbb
RW
449 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
450$as_echo X/"$0" |
451 sed '/^.*\/\([^/][^/]*\)\/*$/{
452 s//\1/
453 q
454 }
455 /^X\/\(\/\/\)$/{
456 s//\1/
457 q
458 }
459 /^X\/\(\/\).*/{
460 s//\1/
461 q
462 }
463 s/.*/./; q'`
bec39cab 464
b4e70030
JB
465# Avoid depending upon Character Ranges.
466as_cr_letters='abcdefghijklmnopqrstuvwxyz'
467as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
468as_cr_Letters=$as_cr_letters$as_cr_LETTERS
469as_cr_digits='0123456789'
470as_cr_alnum=$as_cr_Letters$as_cr_digits
4e8d927d 471
bec39cab 472
81ecdfbb
RW
473 as_lineno_1=$LINENO as_lineno_1a=$LINENO
474 as_lineno_2=$LINENO as_lineno_2a=$LINENO
475 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
476 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
477 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
478 sed -n '
479 p
480 /[$]LINENO/=
481 ' <$as_myself |
bec39cab 482 sed '
81ecdfbb
RW
483 s/[$]LINENO.*/&-/
484 t lineno
485 b
486 :lineno
bec39cab 487 N
81ecdfbb
RW
488 :loop
489 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
bec39cab 490 t loop
81ecdfbb 491 s/-\n.*//
bec39cab 492 ' >$as_me.lineno &&
81ecdfbb
RW
493 chmod +x "$as_me.lineno" ||
494 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
bec39cab 495
d0ac1c44
SM
496 # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
497 # already done that, so ensure we don't try to do so again and fall
498 # in an infinite loop. This has already happened in practice.
499 _as_can_reexec=no; export _as_can_reexec
bec39cab
AC
500 # Don't try to exec as it changes $[0], causing all sort of problems
501 # (the dirname of $[0] is not the place where we might find the
81ecdfbb
RW
502 # original and so on. Autoconf is especially sensitive to this).
503 . "./$as_me.lineno"
bec39cab
AC
504 # Exit status is that of the last command.
505 exit
506}
507
81ecdfbb
RW
508ECHO_C= ECHO_N= ECHO_T=
509case `echo -n x` in #(((((
510-n*)
511 case `echo 'xy\c'` in
512 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
513 xy) ECHO_C='\c';;
514 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
515 ECHO_T=' ';;
516 esac;;
517*)
518 ECHO_N='-n';;
bec39cab
AC
519esac
520
81ecdfbb
RW
521rm -f conf$$ conf$$.exe conf$$.file
522if test -d conf$$.dir; then
523 rm -f conf$$.dir/conf$$.file
bec39cab 524else
81ecdfbb
RW
525 rm -f conf$$.dir
526 mkdir conf$$.dir 2>/dev/null
bec39cab 527fi
81ecdfbb
RW
528if (echo >conf$$.file) 2>/dev/null; then
529 if ln -s conf$$.file conf$$ 2>/dev/null; then
b4e70030 530 as_ln_s='ln -s'
81ecdfbb
RW
531 # ... but there are two gotchas:
532 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
533 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
d0ac1c44 534 # In both cases, we have to default to `cp -pR'.
81ecdfbb 535 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
d0ac1c44 536 as_ln_s='cp -pR'
81ecdfbb
RW
537 elif ln conf$$.file conf$$ 2>/dev/null; then
538 as_ln_s=ln
539 else
d0ac1c44 540 as_ln_s='cp -pR'
b4e70030 541 fi
bec39cab 542else
d0ac1c44 543 as_ln_s='cp -pR'
bec39cab 544fi
81ecdfbb
RW
545rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
546rmdir conf$$.dir 2>/dev/null
bec39cab
AC
547
548if mkdir -p . 2>/dev/null; then
81ecdfbb 549 as_mkdir_p='mkdir -p "$as_dir"'
bec39cab
AC
550else
551 test -d ./-p && rmdir ./-p
552 as_mkdir_p=false
553fi
554
d0ac1c44
SM
555as_test_x='test -x'
556as_executable_p=as_fn_executable_p
bec39cab
AC
557
558# Sed expression to map a string onto a valid CPP name.
559as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
560
561# Sed expression to map a string onto a valid variable name.
562as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
563
b686ecb5
JM
564SHELL=${CONFIG_SHELL-/bin/sh}
565
bec39cab 566
d0ac1c44
SM
567test -n "$DJDIR" || exec 7<&0 </dev/null
568exec 6>&1
c906108c 569
bec39cab 570# Name of the host.
d0ac1c44 571# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
bec39cab
AC
572# so uname gets run too.
573ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
574
bec39cab
AC
575#
576# Initializations.
577#
c906108c 578ac_default_prefix=/usr/local
81ecdfbb 579ac_clean_files=
bec39cab 580ac_config_libobj_dir=.
81ecdfbb 581LIBOBJS=
bec39cab
AC
582cross_compiling=no
583subdirs=
584MFLAGS=
585MAKEFLAGS=
b4e70030 586
bec39cab
AC
587# Identity of this package.
588PACKAGE_NAME=
589PACKAGE_TARNAME=
590PACKAGE_VERSION=
591PACKAGE_STRING=
592PACKAGE_BUGREPORT=
81ecdfbb 593PACKAGE_URL=
bec39cab
AC
594
595ac_unique_file="main.c"
596# Factoring default headers for most tests.
597ac_includes_default="\
598#include <stdio.h>
81ecdfbb 599#ifdef HAVE_SYS_TYPES_H
bec39cab
AC
600# include <sys/types.h>
601#endif
81ecdfbb 602#ifdef HAVE_SYS_STAT_H
bec39cab
AC
603# include <sys/stat.h>
604#endif
81ecdfbb 605#ifdef STDC_HEADERS
bec39cab
AC
606# include <stdlib.h>
607# include <stddef.h>
608#else
81ecdfbb 609# ifdef HAVE_STDLIB_H
bec39cab
AC
610# include <stdlib.h>
611# endif
612#endif
81ecdfbb
RW
613#ifdef HAVE_STRING_H
614# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
bec39cab
AC
615# include <memory.h>
616# endif
617# include <string.h>
618#endif
81ecdfbb 619#ifdef HAVE_STRINGS_H
bec39cab
AC
620# include <strings.h>
621#endif
81ecdfbb 622#ifdef HAVE_INTTYPES_H
bec39cab 623# include <inttypes.h>
bec39cab 624#endif
81ecdfbb
RW
625#ifdef HAVE_STDINT_H
626# include <stdint.h>
627#endif
628#ifdef HAVE_UNISTD_H
bec39cab
AC
629# include <unistd.h>
630#endif"
631
f99d1d37 632enable_option_checking=no
a100a945 633ac_header_list=
c971b7fa 634ac_subst_vars='LTLIBOBJS
81ecdfbb 635LIBOBJS
b292c783
JK
636GCORE_TRANSFORM_NAME
637GDB_TRANSFORM_NAME
e3487908 638XSLTPROC
a0a461e5 639NM_H
81ecdfbb 640GDB_NM_FILE
1776e3e5
NA
641CTF_DEPS
642LIBCTF
393fd4c3
YQ
643LTLIBBABELTRACE
644LIBBABELTRACE
645HAVE_LIBBABELTRACE
abbbd4a3
AB
646LIBBACKTRACE_LIB
647LIBBACKTRACE_INC
21ea5acd
SDJ
648HAVE_NATIVE_GCORE_HOST
649NAT_GENERATED_FILES
650XM_CLIBS
651MH_CFLAGS
652LOADLIBES
653NAT_CDEPS
654NATDEPFILES
655NAT_FILE
81ecdfbb
RW
656target_subdir
657CONFIG_UNINSTALL
658CONFIG_INSTALL
659CONFIG_CLEAN
660CONFIG_ALL
661CONFIG_SRCS
662CONFIG_DEPS
663CONFIG_OBS
664PROFILE_CFLAGS
665ENABLE_CFLAGS
666SIM_OBS
667SIM
668XMKMF
669GDBTK_SRC_DIR
670GDBTK_CFLAGS
671GDBTKLIBS
672X_LIBS
673X_LDFLAGS
674X_CFLAGS
675TK_XINCLUDES
676TK_DEPS
677TK_LIBRARY
678TK_INCLUDE
679TK_STUB_LIB_SPEC
680TK_STUB_LIB_FLAG
681TK_STUB_LIB_FILE
682TK_LIB_SPEC
683TK_LIB_FLAG
684TK_LIB_FILE
685TK_SRC_DIR
686TK_BIN_DIR
687TK_VERSION
688TCL_DEPS
689TCL_LIBRARY
690TCL_INCLUDE
691TCL_STUB_LIB_SPEC
692TCL_STUB_LIB_FLAG
693TCL_STUB_LIB_FILE
694TCL_LIB_SPEC
695TCL_LIB_FLAG
696TCL_LIB_FILE
697TCL_SRC_DIR
698TCL_BIN_DIR
699TCL_PATCH_LEVEL
700TCL_VERSION
701WIN32LDAPP
b2ceabe8 702WIN32LIBS
81ecdfbb
RW
703GUI_CFLAGS_X
704LIBGUI
608e2dbb
TT
705LTLIBLZMA
706LIBLZMA
707HAVE_LIBLZMA
81ecdfbb
RW
708SER_HARDWIRE
709WERROR_CFLAGS
710WARN_CFLAGS
ed2a2229 711SYSTEM_GDBINIT_DIR
81ecdfbb 712SYSTEM_GDBINIT
81ecdfbb
RW
713TARGET_SYSTEM_ROOT
714CONFIG_LDFLAGS
f6528abd 715RDYNAMIC
8b35ed1f
SM
716LTLIBXXHASH
717LIBXXHASH
718HAVE_LIBXXHASH
05ea2a05
TT
719LTLIBIPT
720LIBIPT
721HAVE_LIBIPT
5e030278
TT
722PTHREAD_CFLAGS
723PTHREAD_LIBS
724PTHREAD_CC
725ax_pthread_config
81ecdfbb 726ALLOCA
62f29fda
TT
727SRCHIGH_CFLAGS
728SRCHIGH_LIBS
4df42755
DE
729HAVE_GUILE_FALSE
730HAVE_GUILE_TRUE
ed3ef339
DE
731GUILE_LIBS
732GUILE_CPPFLAGS
e76c5d17
DE
733GUILD_TARGET_FLAG
734GUILD
ed3ef339 735pkg_config_prog_path
4df42755
DE
736HAVE_PYTHON_FALSE
737HAVE_PYTHON_TRUE
ac534cba
JB
738PYTHON_LIBS
739PYTHON_CPPFLAGS
81ecdfbb 740PYTHON_CFLAGS
ec685c5e 741python_prog_path
99118062
AP
742GMPINC
743GMPLIBS
81ecdfbb
RW
744LTLIBEXPAT
745LIBEXPAT
746HAVE_LIBEXPAT
b8e0a31c 747JIT_READER_DIR
f997c383 748TARGET_PTR
14d0e681 749READLINE_DOC_SOURCE_INCLUDES
39037522 750READLINE_TEXI_INCFLAG
81ecdfbb
RW
751READLINE_CFLAGS
752READLINE_DEPS
753READLINE
016a3251
DD
754LTLIBICONV
755LIBICONV
2cac01e3
FS
756ZSTD_LIBS
757ZSTD_CFLAGS
711a72d3
L
758zlibinc
759zlibdir
81ecdfbb
RW
760MIG
761WINDRES
762DLLTOOL
81ecdfbb
RW
763YFLAGS
764YACC
c971b7fa
PA
765INSTALL_DATA
766INSTALL_SCRIPT
767INSTALL_PROGRAM
81ecdfbb
RW
768REPORT_BUGS_TEXI
769REPORT_BUGS_TO
770PKGVERSION
44cee4fd 771CODESIGN_CERT
f6720b1c
AM
772DEBUGINFOD_LIBS
773DEBUGINFOD_CFLAGS
b292c783 774HAVE_NATIVE_GCORE_TARGET
81ecdfbb 775TARGET_OBS
18b4d073
SM
776AMD_DBGAPI_LIBS
777AMD_DBGAPI_CFLAGS
1d5269c9
MF
778ENABLE_BFD_64_BIT_FALSE
779ENABLE_BFD_64_BIT_TRUE
a100a945 780subdirs
81ecdfbb
RW
781GDB_DATADIR
782DEBUGDIR
5048e516
JK
783MAKEINFO_EXTRA_FLAGS
784MAKEINFOFLAGS
785MAKEINFO
81ecdfbb 786PACKAGE
81ecdfbb
RW
787CATOBJEXT
788GENCAT
789INSTOBJEXT
790DATADIRNAME
791CATALOGS
792POSUB
793GMSGFMT
794XGETTEXT
795INCINTL
796LIBINTL_DEP
797LIBINTL
798USE_NLS
18b4d073
SM
799PKG_CONFIG_LIBDIR
800PKG_CONFIG_PATH
801PKG_CONFIG
81ecdfbb
RW
802CCDEPMODE
803DEPDIR
804am__leading_dot
0bcda685
PA
805CXX_DIALECT
806HAVE_CXX11
b686ecb5
JM
807CXXCPP
808OTOOL64
809OTOOL
810LIPO
811NMEDIT
812DSYMUTIL
813AWK
814RANLIB
815AR
816OBJDUMP
817LN_S
818NM
819ac_ct_DUMPBIN
820DUMPBIN
821LD
822FGREP
823SED
824LIBTOOL
b316465f 825target_noncanonical
4869db5e
RM
826INSTALL_STRIP_PROGRAM
827STRIP
828install_sh
c8693053 829LARGEFILE_CPPFLAGS
81ecdfbb
RW
830target_os
831target_vendor
832target_cpu
833target
834host_os
835host_vendor
836host_cpu
837host
838build_os
839build_vendor
840build_cpu
841build
c971b7fa
PA
842EGREP
843GREP
844CPP
3bc3d82a
PA
845ac_ct_CXX
846CXXFLAGS
847CXX
81ecdfbb
RW
848OBJEXT
849EXEEXT
850ac_ct_CC
851CPPFLAGS
852LDFLAGS
853CFLAGS
854CC
855MAINT
856MAINTAINER_MODE_FALSE
857MAINTAINER_MODE_TRUE
858target_alias
859host_alias
860build_alias
861LIBS
862ECHO_T
863ECHO_N
864ECHO_C
865DEFS
866mandir
867localedir
868libdir
869psdir
870pdfdir
871dvidir
872htmldir
873infodir
874docdir
875oldincludedir
876includedir
877localstatedir
878sharedstatedir
879sysconfdir
880datadir
881datarootdir
882libexecdir
883sbindir
884bindir
885program_transform_name
886prefix
887exec_prefix
888PACKAGE_URL
889PACKAGE_BUGREPORT
890PACKAGE_STRING
891PACKAGE_VERSION
892PACKAGE_TARNAME
893PACKAGE_NAME
894PATH_SEPARATOR
895SHELL'
2b351b19 896ac_subst_files='nat_makefile_frag'
81ecdfbb
RW
897ac_user_opts='
898enable_option_checking
899enable_maintainer_mode
da2f07f1
JK
900enable_plugins
901enable_largefile
b686ecb5
JM
902enable_shared
903enable_static
904with_pic
905enable_fast_install
906with_gnu_ld
907enable_libtool_lock
81ecdfbb
RW
908with_separate_debug_dir
909with_gdb_datadir
910with_relocated_sources
7349ff92 911with_auto_load_dir
bccbefd2 912with_auto_load_safe_path
81ecdfbb
RW
913enable_targets
914enable_64_bit_bfd
18b4d073 915with_amd_dbgapi
81ecdfbb
RW
916enable_gdbmi
917enable_tui
918enable_gdbtk
0d79cdc4 919with_debuginfod
05e7c244 920with_libunwind_ia64
81ecdfbb
RW
921with_curses
922enable_profiling
44cee4fd 923enable_codesign
81ecdfbb
RW
924with_pkgversion
925with_bugurl
711a72d3 926with_system_zlib
2cac01e3 927with_zstd
016a3251 928enable_rpath
81ecdfbb 929with_libiconv_prefix
9f1528a1 930with_libiconv_type
478aac75 931with_iconv_bin
81ecdfbb 932with_system_readline
b8e0a31c 933with_jit_reader_dir
81ecdfbb 934with_expat
81ecdfbb 935with_libexpat_prefix
9f1528a1 936with_libexpat_type
81ecdfbb 937with_python
d13c7322 938with_python_libdir
ed3ef339 939with_guile
189b8c2e 940enable_source_highlight
261b0748 941enable_threading
58bfce93
MM
942with_intel_pt
943with_libipt_prefix
9f1528a1 944with_libipt_type
8b35ed1f
SM
945with_xxhash
946with_libxxhash_prefix
947with_libxxhash_type
81ecdfbb
RW
948with_sysroot
949with_system_gdbinit
ed2a2229 950with_system_gdbinit_dir
81ecdfbb
RW
951enable_werror
952enable_build_warnings
953enable_gdb_build_warnings
f35d5ade 954enable_ubsan
608e2dbb
TT
955with_lzma
956with_liblzma_prefix
9f1528a1 957with_liblzma_type
81ecdfbb
RW
958with_tcl
959with_tk
960with_x
961enable_sim
abbbd4a3 962enable_libbacktrace
393fd4c3
YQ
963with_babeltrace
964with_libbabeltrace_prefix
9f1528a1 965with_libbabeltrace_type
1776e3e5 966enable_libctf
8ecfd7bd 967enable_unit_tests
81ecdfbb
RW
968'
969 ac_precious_vars='build_alias
970host_alias
971target_alias
972CC
973CFLAGS
974LDFLAGS
975LIBS
976CPPFLAGS
3bc3d82a
PA
977CXX
978CXXFLAGS
979CCC
81ecdfbb 980CPP
b686ecb5 981CXXCPP
f6720b1c
AM
982PKG_CONFIG
983PKG_CONFIG_PATH
984PKG_CONFIG_LIBDIR
18b4d073
SM
985MAKEINFO
986MAKEINFOFLAGS
987AMD_DBGAPI_CFLAGS
988AMD_DBGAPI_LIBS
f6720b1c
AM
989DEBUGINFOD_CFLAGS
990DEBUGINFOD_LIBS
81ecdfbb
RW
991YACC
992YFLAGS
2cac01e3
FS
993ZSTD_CFLAGS
994ZSTD_LIBS
99118062
AP
995GMPLIBS
996GMPINC
81ecdfbb 997XMKMF'
a100a945
SM
998ac_subdirs_all='testsuite
999gdbtk'
c906108c
SS
1000
1001# Initialize some variables set by options.
bec39cab
AC
1002ac_init_help=
1003ac_init_version=false
81ecdfbb
RW
1004ac_unrecognized_opts=
1005ac_unrecognized_sep=
c906108c
SS
1006# The variables have the same names as the options, with
1007# dashes changed to underlines.
bec39cab 1008cache_file=/dev/null
c906108c 1009exec_prefix=NONE
c906108c 1010no_create=
c906108c
SS
1011no_recursion=
1012prefix=NONE
1013program_prefix=NONE
1014program_suffix=NONE
1015program_transform_name=s,x,x,
1016silent=
1017site=
1018srcdir=
c906108c
SS
1019verbose=
1020x_includes=NONE
1021x_libraries=NONE
bec39cab
AC
1022
1023# Installation directory options.
1024# These are left unexpanded so users can "make install exec_prefix=/foo"
1025# and all the variables that are supposed to be based on exec_prefix
1026# by default will actually change.
1027# Use braces instead of parens because sh, perl, etc. also accept them.
81ecdfbb 1028# (The list follows the same order as the GNU Coding Standards.)
c906108c
SS
1029bindir='${exec_prefix}/bin'
1030sbindir='${exec_prefix}/sbin'
1031libexecdir='${exec_prefix}/libexec'
81ecdfbb
RW
1032datarootdir='${prefix}/share'
1033datadir='${datarootdir}'
c906108c
SS
1034sysconfdir='${prefix}/etc'
1035sharedstatedir='${prefix}/com'
1036localstatedir='${prefix}/var'
c906108c
SS
1037includedir='${prefix}/include'
1038oldincludedir='/usr/include'
81ecdfbb
RW
1039docdir='${datarootdir}/doc/${PACKAGE}'
1040infodir='${datarootdir}/info'
1041htmldir='${docdir}'
1042dvidir='${docdir}'
1043pdfdir='${docdir}'
1044psdir='${docdir}'
1045libdir='${exec_prefix}/lib'
1046localedir='${datarootdir}/locale'
1047mandir='${datarootdir}/man'
c906108c 1048
c906108c 1049ac_prev=
81ecdfbb 1050ac_dashdash=
c906108c
SS
1051for ac_option
1052do
c906108c
SS
1053 # If the previous option needs an argument, assign it.
1054 if test -n "$ac_prev"; then
81ecdfbb 1055 eval $ac_prev=\$ac_option
c906108c
SS
1056 ac_prev=
1057 continue
1058 fi
1059
81ecdfbb 1060 case $ac_option in
d0ac1c44
SM
1061 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1062 *=) ac_optarg= ;;
1063 *) ac_optarg=yes ;;
81ecdfbb 1064 esac
c906108c
SS
1065
1066 # Accept the important Cygnus configure options, so we can diagnose typos.
1067
81ecdfbb
RW
1068 case $ac_dashdash$ac_option in
1069 --)
1070 ac_dashdash=yes ;;
c906108c
SS
1071
1072 -bindir | --bindir | --bindi | --bind | --bin | --bi)
1073 ac_prev=bindir ;;
1074 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
bec39cab 1075 bindir=$ac_optarg ;;
c906108c
SS
1076
1077 -build | --build | --buil | --bui | --bu)
bec39cab 1078 ac_prev=build_alias ;;
c906108c 1079 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
bec39cab 1080 build_alias=$ac_optarg ;;
c906108c
SS
1081
1082 -cache-file | --cache-file | --cache-fil | --cache-fi \
1083 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1084 ac_prev=cache_file ;;
1085 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1086 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
bec39cab
AC
1087 cache_file=$ac_optarg ;;
1088
1089 --config-cache | -C)
1090 cache_file=config.cache ;;
c906108c 1091
81ecdfbb 1092 -datadir | --datadir | --datadi | --datad)
c906108c 1093 ac_prev=datadir ;;
81ecdfbb 1094 -datadir=* | --datadir=* | --datadi=* | --datad=*)
bec39cab 1095 datadir=$ac_optarg ;;
c906108c 1096
81ecdfbb
RW
1097 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1098 | --dataroo | --dataro | --datar)
1099 ac_prev=datarootdir ;;
1100 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1101 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1102 datarootdir=$ac_optarg ;;
1103
c906108c 1104 -disable-* | --disable-*)
81ecdfbb 1105 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
c906108c 1106 # Reject names that are not valid shell variable names.
81ecdfbb 1107 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
d0ac1c44 1108 as_fn_error $? "invalid feature name: $ac_useropt"
81ecdfbb
RW
1109 ac_useropt_orig=$ac_useropt
1110 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1111 case $ac_user_opts in
1112 *"
1113"enable_$ac_useropt"
1114"*) ;;
1115 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1116 ac_unrecognized_sep=', ';;
1117 esac
1118 eval enable_$ac_useropt=no ;;
1119
1120 -docdir | --docdir | --docdi | --doc | --do)
1121 ac_prev=docdir ;;
1122 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1123 docdir=$ac_optarg ;;
1124
1125 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1126 ac_prev=dvidir ;;
1127 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1128 dvidir=$ac_optarg ;;
c906108c
SS
1129
1130 -enable-* | --enable-*)
81ecdfbb 1131 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
c906108c 1132 # Reject names that are not valid shell variable names.
81ecdfbb 1133 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
d0ac1c44 1134 as_fn_error $? "invalid feature name: $ac_useropt"
81ecdfbb
RW
1135 ac_useropt_orig=$ac_useropt
1136 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1137 case $ac_user_opts in
1138 *"
1139"enable_$ac_useropt"
1140"*) ;;
1141 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1142 ac_unrecognized_sep=', ';;
b4e70030 1143 esac
81ecdfbb 1144 eval enable_$ac_useropt=\$ac_optarg ;;
c906108c
SS
1145
1146 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1147 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1148 | --exec | --exe | --ex)
1149 ac_prev=exec_prefix ;;
1150 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1151 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1152 | --exec=* | --exe=* | --ex=*)
bec39cab 1153 exec_prefix=$ac_optarg ;;
c906108c
SS
1154
1155 -gas | --gas | --ga | --g)
1156 # Obsolete; use --with-gas.
1157 with_gas=yes ;;
1158
bec39cab
AC
1159 -help | --help | --hel | --he | -h)
1160 ac_init_help=long ;;
1161 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1162 ac_init_help=recursive ;;
1163 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1164 ac_init_help=short ;;
c906108c
SS
1165
1166 -host | --host | --hos | --ho)
bec39cab 1167 ac_prev=host_alias ;;
c906108c 1168 -host=* | --host=* | --hos=* | --ho=*)
bec39cab 1169 host_alias=$ac_optarg ;;
c906108c 1170
81ecdfbb
RW
1171 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1172 ac_prev=htmldir ;;
1173 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1174 | --ht=*)
1175 htmldir=$ac_optarg ;;
1176
c906108c
SS
1177 -includedir | --includedir | --includedi | --included | --include \
1178 | --includ | --inclu | --incl | --inc)
1179 ac_prev=includedir ;;
1180 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1181 | --includ=* | --inclu=* | --incl=* | --inc=*)
bec39cab 1182 includedir=$ac_optarg ;;
c906108c
SS
1183
1184 -infodir | --infodir | --infodi | --infod | --info | --inf)
1185 ac_prev=infodir ;;
1186 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
bec39cab 1187 infodir=$ac_optarg ;;
c906108c
SS
1188
1189 -libdir | --libdir | --libdi | --libd)
1190 ac_prev=libdir ;;
1191 -libdir=* | --libdir=* | --libdi=* | --libd=*)
bec39cab 1192 libdir=$ac_optarg ;;
c906108c
SS
1193
1194 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1195 | --libexe | --libex | --libe)
1196 ac_prev=libexecdir ;;
1197 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1198 | --libexe=* | --libex=* | --libe=*)
bec39cab 1199 libexecdir=$ac_optarg ;;
c906108c 1200
81ecdfbb
RW
1201 -localedir | --localedir | --localedi | --localed | --locale)
1202 ac_prev=localedir ;;
1203 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1204 localedir=$ac_optarg ;;
1205
c906108c 1206 -localstatedir | --localstatedir | --localstatedi | --localstated \
81ecdfbb 1207 | --localstate | --localstat | --localsta | --localst | --locals)
c906108c
SS
1208 ac_prev=localstatedir ;;
1209 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
81ecdfbb 1210 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
bec39cab 1211 localstatedir=$ac_optarg ;;
c906108c
SS
1212
1213 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1214 ac_prev=mandir ;;
1215 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
bec39cab 1216 mandir=$ac_optarg ;;
c906108c
SS
1217
1218 -nfp | --nfp | --nf)
1219 # Obsolete; use --without-fp.
1220 with_fp=no ;;
1221
1222 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
bec39cab 1223 | --no-cr | --no-c | -n)
c906108c
SS
1224 no_create=yes ;;
1225
1226 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1227 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1228 no_recursion=yes ;;
1229
1230 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1231 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1232 | --oldin | --oldi | --old | --ol | --o)
1233 ac_prev=oldincludedir ;;
1234 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1235 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1236 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
bec39cab 1237 oldincludedir=$ac_optarg ;;
c906108c
SS
1238
1239 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1240 ac_prev=prefix ;;
1241 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
bec39cab 1242 prefix=$ac_optarg ;;
c906108c
SS
1243
1244 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1245 | --program-pre | --program-pr | --program-p)
1246 ac_prev=program_prefix ;;
1247 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1248 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
bec39cab 1249 program_prefix=$ac_optarg ;;
c906108c
SS
1250
1251 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1252 | --program-suf | --program-su | --program-s)
1253 ac_prev=program_suffix ;;
1254 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1255 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
bec39cab 1256 program_suffix=$ac_optarg ;;
c906108c
SS
1257
1258 -program-transform-name | --program-transform-name \
1259 | --program-transform-nam | --program-transform-na \
1260 | --program-transform-n | --program-transform- \
1261 | --program-transform | --program-transfor \
1262 | --program-transfo | --program-transf \
1263 | --program-trans | --program-tran \
1264 | --progr-tra | --program-tr | --program-t)
1265 ac_prev=program_transform_name ;;
1266 -program-transform-name=* | --program-transform-name=* \
1267 | --program-transform-nam=* | --program-transform-na=* \
1268 | --program-transform-n=* | --program-transform-=* \
1269 | --program-transform=* | --program-transfor=* \
1270 | --program-transfo=* | --program-transf=* \
1271 | --program-trans=* | --program-tran=* \
1272 | --progr-tra=* | --program-tr=* | --program-t=*)
bec39cab 1273 program_transform_name=$ac_optarg ;;
c906108c 1274
81ecdfbb
RW
1275 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1276 ac_prev=pdfdir ;;
1277 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1278 pdfdir=$ac_optarg ;;
1279
1280 -psdir | --psdir | --psdi | --psd | --ps)
1281 ac_prev=psdir ;;
1282 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1283 psdir=$ac_optarg ;;
1284
c906108c
SS
1285 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1286 | -silent | --silent | --silen | --sile | --sil)
1287 silent=yes ;;
1288
1289 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1290 ac_prev=sbindir ;;
1291 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1292 | --sbi=* | --sb=*)
bec39cab 1293 sbindir=$ac_optarg ;;
c906108c
SS
1294
1295 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1296 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1297 | --sharedst | --shareds | --shared | --share | --shar \
1298 | --sha | --sh)
1299 ac_prev=sharedstatedir ;;
1300 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1301 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1302 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1303 | --sha=* | --sh=*)
bec39cab 1304 sharedstatedir=$ac_optarg ;;
c906108c
SS
1305
1306 -site | --site | --sit)
1307 ac_prev=site ;;
1308 -site=* | --site=* | --sit=*)
bec39cab 1309 site=$ac_optarg ;;
3ace7edb 1310
c906108c
SS
1311 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1312 ac_prev=srcdir ;;
1313 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
bec39cab 1314 srcdir=$ac_optarg ;;
c906108c
SS
1315
1316 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1317 | --syscon | --sysco | --sysc | --sys | --sy)
1318 ac_prev=sysconfdir ;;
1319 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1320 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
bec39cab 1321 sysconfdir=$ac_optarg ;;
c906108c
SS
1322
1323 -target | --target | --targe | --targ | --tar | --ta | --t)
bec39cab 1324 ac_prev=target_alias ;;
c906108c 1325 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
bec39cab 1326 target_alias=$ac_optarg ;;
c906108c
SS
1327
1328 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1329 verbose=yes ;;
1330
bec39cab
AC
1331 -version | --version | --versio | --versi | --vers | -V)
1332 ac_init_version=: ;;
c906108c
SS
1333
1334 -with-* | --with-*)
81ecdfbb 1335 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
c906108c 1336 # Reject names that are not valid shell variable names.
81ecdfbb 1337 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
d0ac1c44 1338 as_fn_error $? "invalid package name: $ac_useropt"
81ecdfbb
RW
1339 ac_useropt_orig=$ac_useropt
1340 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1341 case $ac_user_opts in
1342 *"
1343"with_$ac_useropt"
1344"*) ;;
1345 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1346 ac_unrecognized_sep=', ';;
b4e70030 1347 esac
81ecdfbb 1348 eval with_$ac_useropt=\$ac_optarg ;;
c906108c
SS
1349
1350 -without-* | --without-*)
81ecdfbb 1351 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
c906108c 1352 # Reject names that are not valid shell variable names.
81ecdfbb 1353 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
d0ac1c44 1354 as_fn_error $? "invalid package name: $ac_useropt"
81ecdfbb
RW
1355 ac_useropt_orig=$ac_useropt
1356 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1357 case $ac_user_opts in
1358 *"
1359"with_$ac_useropt"
1360"*) ;;
1361 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1362 ac_unrecognized_sep=', ';;
1363 esac
1364 eval with_$ac_useropt=no ;;
c906108c
SS
1365
1366 --x)
1367 # Obsolete; use --with-x.
1368 with_x=yes ;;
1369
1370 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1371 | --x-incl | --x-inc | --x-in | --x-i)
1372 ac_prev=x_includes ;;
1373 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1374 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
bec39cab 1375 x_includes=$ac_optarg ;;
c906108c
SS
1376
1377 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1378 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1379 ac_prev=x_libraries ;;
1380 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1381 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
bec39cab 1382 x_libraries=$ac_optarg ;;
c906108c 1383
d0ac1c44
SM
1384 -*) as_fn_error $? "unrecognized option: \`$ac_option'
1385Try \`$0 --help' for more information"
c906108c
SS
1386 ;;
1387
bec39cab
AC
1388 *=*)
1389 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1390 # Reject names that are not valid shell variable names.
81ecdfbb
RW
1391 case $ac_envvar in #(
1392 '' | [0-9]* | *[!_$as_cr_alnum]* )
d0ac1c44 1393 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
81ecdfbb
RW
1394 esac
1395 eval $ac_envvar=\$ac_optarg
bec39cab
AC
1396 export $ac_envvar ;;
1397
c906108c 1398 *)
bec39cab 1399 # FIXME: should be removed in autoconf 3.0.
81ecdfbb 1400 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
bec39cab 1401 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
81ecdfbb 1402 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
d0ac1c44 1403 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
c906108c
SS
1404 ;;
1405
1406 esac
1407done
1408
1409if test -n "$ac_prev"; then
bec39cab 1410 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
d0ac1c44 1411 as_fn_error $? "missing argument to $ac_option"
c906108c 1412fi
c906108c 1413
81ecdfbb
RW
1414if test -n "$ac_unrecognized_opts"; then
1415 case $enable_option_checking in
1416 no) ;;
d0ac1c44 1417 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
81ecdfbb 1418 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
b4e70030 1419 esac
81ecdfbb 1420fi
b4e70030 1421
81ecdfbb
RW
1422# Check all directory arguments for consistency.
1423for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1424 datadir sysconfdir sharedstatedir localstatedir includedir \
1425 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1426 libdir localedir mandir
b4e70030 1427do
81ecdfbb
RW
1428 eval ac_val=\$$ac_var
1429 # Remove trailing slashes.
1430 case $ac_val in
1431 */ )
1432 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1433 eval $ac_var=\$ac_val;;
1434 esac
1435 # Be sure to have absolute directory names.
b4e70030 1436 case $ac_val in
81ecdfbb
RW
1437 [\\/$]* | ?:[\\/]* ) continue;;
1438 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
c906108c 1439 esac
d0ac1c44 1440 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
c906108c
SS
1441done
1442
bec39cab
AC
1443# There might be people who depend on the old broken behavior: `$host'
1444# used to hold the argument of --host etc.
1445# FIXME: To remove some day.
1446build=$build_alias
1447host=$host_alias
1448target=$target_alias
1449
1450# FIXME: To remove some day.
1451if test "x$host_alias" != x; then
1452 if test "x$build_alias" = x; then
1453 cross_compiling=maybe
bec39cab
AC
1454 elif test "x$build_alias" != "x$host_alias"; then
1455 cross_compiling=yes
1456 fi
1457fi
c906108c 1458
bec39cab
AC
1459ac_tool_prefix=
1460test -n "$host_alias" && ac_tool_prefix=$host_alias-
1461
1462test "$silent" = yes && exec 6>/dev/null
c906108c 1463
c906108c 1464
81ecdfbb
RW
1465ac_pwd=`pwd` && test -n "$ac_pwd" &&
1466ac_ls_di=`ls -di .` &&
1467ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
d0ac1c44 1468 as_fn_error $? "working directory cannot be determined"
81ecdfbb 1469test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
d0ac1c44 1470 as_fn_error $? "pwd does not report name of working directory"
81ecdfbb
RW
1471
1472
c906108c
SS
1473# Find the source files, if location was not specified.
1474if test -z "$srcdir"; then
1475 ac_srcdir_defaulted=yes
81ecdfbb
RW
1476 # Try the directory containing this script, then the parent directory.
1477 ac_confdir=`$as_dirname -- "$as_myself" ||
1478$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1479 X"$as_myself" : 'X\(//\)[^/]' \| \
1480 X"$as_myself" : 'X\(//\)$' \| \
1481 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1482$as_echo X"$as_myself" |
1483 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1484 s//\1/
1485 q
1486 }
1487 /^X\(\/\/\)[^/].*/{
1488 s//\1/
1489 q
1490 }
1491 /^X\(\/\/\)$/{
1492 s//\1/
1493 q
1494 }
1495 /^X\(\/\).*/{
1496 s//\1/
1497 q
1498 }
1499 s/.*/./; q'`
c906108c 1500 srcdir=$ac_confdir
81ecdfbb 1501 if test ! -r "$srcdir/$ac_unique_file"; then
c906108c
SS
1502 srcdir=..
1503 fi
1504else
1505 ac_srcdir_defaulted=no
1506fi
81ecdfbb
RW
1507if test ! -r "$srcdir/$ac_unique_file"; then
1508 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
d0ac1c44 1509 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
81ecdfbb
RW
1510fi
1511ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1512ac_abs_confdir=`(
d0ac1c44 1513 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
81ecdfbb
RW
1514 pwd)`
1515# When building in place, set srcdir=.
1516if test "$ac_abs_confdir" = "$ac_pwd"; then
1517 srcdir=.
1518fi
1519# Remove unnecessary trailing slashes from srcdir.
1520# Double slashes in file names in object file debugging info
1521# mess up M-x gdb in Emacs.
1522case $srcdir in
1523*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1524esac
1525for ac_var in $ac_precious_vars; do
1526 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1527 eval ac_env_${ac_var}_value=\$${ac_var}
1528 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1529 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1530done
c906108c 1531
bec39cab
AC
1532#
1533# Report the --help message.
1534#
1535if test "$ac_init_help" = "long"; then
1536 # Omit some internal or obsolete options to make the list less imposing.
1537 # This message is too long to be a string in the A/UX 3.1 sh.
1538 cat <<_ACEOF
1539\`configure' configures this package to adapt to many kinds of systems.
1540
1541Usage: $0 [OPTION]... [VAR=VALUE]...
1542
1543To assign environment variables (e.g., CC, CFLAGS...), specify them as
1544VAR=VALUE. See below for descriptions of some of the useful variables.
1545
1546Defaults for the options are specified in brackets.
1547
1548Configuration:
1549 -h, --help display this help and exit
1550 --help=short display options specific to this package
1551 --help=recursive display the short help of all the included packages
1552 -V, --version display version information and exit
d0ac1c44 1553 -q, --quiet, --silent do not print \`checking ...' messages
bec39cab
AC
1554 --cache-file=FILE cache test results in FILE [disabled]
1555 -C, --config-cache alias for \`--cache-file=config.cache'
1556 -n, --no-create do not create output files
1557 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1558
bec39cab
AC
1559Installation directories:
1560 --prefix=PREFIX install architecture-independent files in PREFIX
81ecdfbb 1561 [$ac_default_prefix]
bec39cab 1562 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
81ecdfbb 1563 [PREFIX]
bec39cab
AC
1564
1565By default, \`make install' will install all the files in
1566\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1567an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1568for instance \`--prefix=\$HOME'.
1569
1570For better control, use the options below.
1571
1572Fine tuning of the installation directories:
81ecdfbb
RW
1573 --bindir=DIR user executables [EPREFIX/bin]
1574 --sbindir=DIR system admin executables [EPREFIX/sbin]
1575 --libexecdir=DIR program executables [EPREFIX/libexec]
1576 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1577 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1578 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1579 --libdir=DIR object code libraries [EPREFIX/lib]
1580 --includedir=DIR C header files [PREFIX/include]
1581 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1582 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1583 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1584 --infodir=DIR info documentation [DATAROOTDIR/info]
1585 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1586 --mandir=DIR man documentation [DATAROOTDIR/man]
1587 --docdir=DIR documentation root [DATAROOTDIR/doc/PACKAGE]
1588 --htmldir=DIR html documentation [DOCDIR]
1589 --dvidir=DIR dvi documentation [DOCDIR]
1590 --pdfdir=DIR pdf documentation [DOCDIR]
1591 --psdir=DIR ps documentation [DOCDIR]
bec39cab
AC
1592_ACEOF
1593
1594 cat <<\_ACEOF
1595
9009e1ae
MR
1596Program names:
1597 --program-prefix=PREFIX prepend PREFIX to installed program names
1598 --program-suffix=SUFFIX append SUFFIX to installed program names
1599 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
1600
bec39cab
AC
1601X features:
1602 --x-includes=DIR X include files are in DIR
1603 --x-libraries=DIR X library files are in DIR
1604
1605System types:
1606 --build=BUILD configure for building on BUILD [guessed]
1607 --host=HOST cross-compile to build programs to run on HOST [BUILD]
1608 --target=TARGET configure for building compilers for TARGET [HOST]
1609_ACEOF
1610fi
1611
1612if test -n "$ac_init_help"; then
1613
1614 cat <<\_ACEOF
1615
1616Optional Features:
81ecdfbb 1617 --disable-option-checking ignore unrecognized --enable/--with options
bec39cab
AC
1618 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1619 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
d0ac1c44
SM
1620 --enable-maintainer-mode
1621 enable make rules and dependencies not useful (and
1622 sometimes confusing) to the casual installer
2974be62 1623 --enable-plugins Enable support for plugins
da2f07f1 1624 --disable-largefile omit support for large files
b686ecb5
JM
1625 --enable-shared[=PKGS] build shared libraries [default=yes]
1626 --enable-static[=PKGS] build static libraries [default=yes]
1627 --enable-fast-install[=PKGS]
1628 optimize for fast installation [default=yes]
1629 --disable-libtool-lock avoid locking (might break parallel builds)
a1220294
TT
1630 --enable-targets=TARGETS
1631 alternative target configurations
c0993dbe 1632 --enable-64-bit-bfd 64-bit support (on hosts with narrower word sizes)
bec39cab
AC
1633 --disable-gdbmi disable machine-interface (MI)
1634 --enable-tui enable full-screen terminal user interface (TUI)
1635 --enable-gdbtk enable gdbtk graphical user interface (GUI)
1636 --enable-profiling enable profiling of GDB
44cee4fd 1637 --enable-codesign=CERT sign gdb with 'codesign -s CERT'
3841debe 1638 --disable-rpath do not hardcode runtime library paths
189b8c2e
ST
1639 --enable-source-highlight
1640 enable source-highlight for source listings
261b0748
LM
1641 --enable-threading include support for parallel processing of data
1642 (yes/no)
a1220294 1643 --enable-werror treat compile warnings as errors
32c1c914 1644 --enable-build-warnings enable build-time compiler warnings if gcc is used
a1220294 1645 --enable-gdb-build-warnings
32c1c914 1646 enable GDB specific build-time compiler warnings if
a1220294 1647 gcc is used
f35d5ade 1648 --enable-ubsan enable undefined behavior sanitizer (auto/yes/no)
32c1c914 1649 --enable-sim link gdb with simulator
abbbd4a3
AB
1650 --enable-libbacktrace use libbacktrace to write a backtrace after a fatal
1651 signal.
1776e3e5 1652 --enable-libctf Handle .ctf type-info sections [default=yes]
8ecfd7bd
SDJ
1653 --enable-unit-tests Enable the inclusion of unit tests when compiling
1654 GDB
bec39cab
AC
1655
1656Optional Packages:
1657 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
1658 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
b686ecb5
JM
1659 --with-pic try to use only PIC/non-PIC objects [default=use
1660 both]
1661 --with-gnu-ld assume the C compiler uses GNU ld [default=no]
a1220294 1662 --with-separate-debug-dir=PATH
32c1c914 1663 look for global separate debug info in this path
62e4f60c 1664 [LIBDIR/debug]
b14b1491
TT
1665 --with-gdb-datadir=PATH look for global separate data files in this path
1666 [DATADIR/gdb]
29b0e8a2 1667 --with-relocated-sources=PATH
32c1c914 1668 automatically relocate this path for source files
7349ff92 1669 --with-auto-load-dir=PATH
aff139ff 1670 directories from which to load auto-loaded scripts
1564a261 1671 [$debugdir:$datadir/auto-load]
bccbefd2 1672 --with-auto-load-safe-path=PATH
aff139ff 1673 directories safe to hold auto-loaded files
7349ff92 1674 [--with-auto-load-dir]
bccbefd2
JK
1675 --without-auto-load-safe-path
1676 do not restrict auto-loaded files locations
18b4d073 1677 --with-amd-dbgapi support for the amd-dbgapi target (yes / no / auto)
0d79cdc4
AM
1678 --with-debuginfod Enable debuginfo lookups with debuginfod
1679 (auto/yes/no)
05e7c244 1680 --with-libunwind-ia64 use libunwind frame unwinding for ia64 targets
cb01cfba
JB
1681 --with-curses use the curses library instead of the termcap
1682 library
c16158bc
JM
1683 --with-pkgversion=PKG Use PKG in the version string in place of "GDB"
1684 --with-bugurl=URL Direct users to URL to report a bug
711a72d3 1685 --with-system-zlib use installed libz
2cac01e3
FS
1686 --with-zstd support zstd compressed debug sections
1687 (default=auto)
016a3251
DD
1688 --with-gnu-ld assume the C compiler uses GNU ld default=no
1689 --with-libiconv-prefix[=DIR] search for libiconv in DIR/include and DIR/lib
1690 --without-libiconv-prefix don't search for libiconv in includedir and libdir
9f1528a1 1691 --with-libiconv-type=TYPE type of library to search for (auto/static/shared)
478aac75 1692 --with-iconv-bin=PATH specify where to find the iconv program
6a30b0a5 1693 --with-system-readline use installed readline library
b8e0a31c
SD
1694 --with-jit-reader-dir=PATH
1695 directory to load the JIT readers from
5c39566f 1696 --with-expat include expat support (auto/yes/no)
3841debe
DJ
1697 --with-libexpat-prefix[=DIR] search for libexpat in DIR/include and DIR/lib
1698 --without-libexpat-prefix don't search for libexpat in includedir and libdir
9f1528a1 1699 --with-libexpat-type=TYPE type of library to search for (auto/static/shared)
0c4a4063
DE
1700 --with-python[=PYTHON] include python support
1701 (auto/yes/no/<python-program>)
d13c7322
AB
1702 --with-python-libdir[=DIR]
1703 search for python's libraries in DIR
ed3ef339
DE
1704 --with-guile[=GUILE] include guile support
1705 (auto/yes/no/<guile-version>/<pkg-config-program>)
bc504a31 1706 --with-intel-pt include Intel Processor Trace support (auto/yes/no)
58bfce93
MM
1707 --with-libipt-prefix[=DIR] search for libipt in DIR/include and DIR/lib
1708 --without-libipt-prefix don't search for libipt in includedir and libdir
9f1528a1 1709 --with-libipt-type=TYPE type of library to search for (auto/static/shared)
8b35ed1f
SM
1710 --with-xxhash use libxxhash for hashing (faster) (auto/yes/no)
1711 --with-libxxhash-prefix[=DIR] search for libxxhash in DIR/include and DIR/lib
1712 --without-libxxhash-prefix don't search for libxxhash in includedir and libdir
1713 --with-libxxhash-type=TYPE type of library to search for (auto/static/shared)
81ecdfbb 1714 --with-sysroot[=DIR] search for usr/lib et al within DIR
b14b1491 1715 --with-system-gdbinit=PATH
32c1c914 1716 automatically load a system-wide gdbinit file
ed2a2229
CB
1717 --with-system-gdbinit-dir=PATH
1718 automatically load system-wide gdbinit files from
1719 this directory
608e2dbb
TT
1720 --with-lzma support lzma compression (auto/yes/no)
1721 --with-liblzma-prefix[=DIR] search for liblzma in DIR/include and DIR/lib
1722 --without-liblzma-prefix don't search for liblzma in includedir and libdir
9f1528a1 1723 --with-liblzma-type=TYPE type of library to search for (auto/static/shared)
5062cc19
KS
1724 --with-tcl directory containing tcl configuration (tclConfig.sh)
1725 --with-tk directory containing tk configuration (tkConfig.sh)
bec39cab 1726 --with-x use the X Window System
393fd4c3
YQ
1727 --with-babeltrace include babeltrace support (auto/yes/no)
1728 --with-libbabeltrace-prefix[=DIR] search for libbabeltrace in DIR/include and DIR/lib
1729 --without-libbabeltrace-prefix don't search for libbabeltrace in includedir and libdir
9f1528a1 1730 --with-libbabeltrace-type=TYPE type of library to search for (auto/static/shared)
bec39cab
AC
1731
1732Some influential environment variables:
1733 CC C compiler command
1734 CFLAGS C compiler flags
1735 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
1736 nonstandard directory <lib dir>
81ecdfbb 1737 LIBS libraries to pass to the linker, e.g. -l<library>
d0ac1c44 1738 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
81ecdfbb 1739 you have headers in a nonstandard directory <include dir>
3bc3d82a
PA
1740 CXX C++ compiler command
1741 CXXFLAGS C++ compiler flags
bec39cab 1742 CPP C preprocessor
b686ecb5 1743 CXXCPP C++ preprocessor
f6720b1c
AM
1744 PKG_CONFIG path to pkg-config utility
1745 PKG_CONFIG_PATH
1746 directories to add to pkg-config's search path
1747 PKG_CONFIG_LIBDIR
1748 path overriding pkg-config's built-in search path
18b4d073
SM
1749 MAKEINFO Parent configure detects if it is of sufficient version.
1750 MAKEINFOFLAGS
1751 Parameters for MAKEINFO.
1752 AMD_DBGAPI_CFLAGS
1753 C compiler flags for AMD_DBGAPI, overriding pkg-config
1754 AMD_DBGAPI_LIBS
1755 linker flags for AMD_DBGAPI, overriding pkg-config
f6720b1c
AM
1756 DEBUGINFOD_CFLAGS
1757 C compiler flags for DEBUGINFOD, overriding pkg-config
1758 DEBUGINFOD_LIBS
1759 linker flags for DEBUGINFOD, overriding pkg-config
d0ac1c44
SM
1760 YACC The `Yet Another Compiler Compiler' implementation to use.
1761 Defaults to the first program found out of: `bison -y', `byacc',
1762 `yacc'.
81ecdfbb
RW
1763 YFLAGS The list of arguments that will be passed by default to $YACC.
1764 This script will default YFLAGS to the empty string to avoid a
1765 default value of `-d' given by some make applications.
2cac01e3
FS
1766 ZSTD_CFLAGS C compiler flags for ZSTD, overriding pkg-config
1767 ZSTD_LIBS linker flags for ZSTD, overriding pkg-config
99118062
AP
1768 GMPLIBS How to link GMP
1769 GMPINC How to find GMP include files
81ecdfbb 1770 XMKMF Path to xmkmf, Makefile generator for X Window System
bec39cab
AC
1771
1772Use these variables to override the choices made by `configure' or to help
1773it to find libraries and programs with nonstandard names/locations.
1774
81ecdfbb 1775Report bugs to the package provider.
bec39cab 1776_ACEOF
81ecdfbb 1777ac_status=$?
bec39cab
AC
1778fi
1779
1780if test "$ac_init_help" = "recursive"; then
1781 # If there are subdirs, report their specific --help.
bec39cab 1782 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
81ecdfbb
RW
1783 test -d "$ac_dir" ||
1784 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1785 continue
bec39cab
AC
1786 ac_builddir=.
1787
81ecdfbb
RW
1788case "$ac_dir" in
1789.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1790*)
1791 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1792 # A ".." for each directory in $ac_dir_suffix.
1793 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1794 case $ac_top_builddir_sub in
1795 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1796 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1797 esac ;;
1798esac
1799ac_abs_top_builddir=$ac_pwd
1800ac_abs_builddir=$ac_pwd$ac_dir_suffix
1801# for backward compatibility:
1802ac_top_builddir=$ac_top_build_prefix
bec39cab
AC
1803
1804case $srcdir in
81ecdfbb 1805 .) # We are building in place.
bec39cab 1806 ac_srcdir=.
81ecdfbb
RW
1807 ac_top_srcdir=$ac_top_builddir_sub
1808 ac_abs_top_srcdir=$ac_pwd ;;
1809 [\\/]* | ?:[\\/]* ) # Absolute name.
bec39cab 1810 ac_srcdir=$srcdir$ac_dir_suffix;
81ecdfbb
RW
1811 ac_top_srcdir=$srcdir
1812 ac_abs_top_srcdir=$srcdir ;;
1813 *) # Relative name.
1814 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1815 ac_top_srcdir=$ac_top_build_prefix$srcdir
1816 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
bec39cab 1817esac
81ecdfbb 1818ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
bec39cab 1819
81ecdfbb
RW
1820 cd "$ac_dir" || { ac_status=$?; continue; }
1821 # Check for guested configure.
1822 if test -f "$ac_srcdir/configure.gnu"; then
1823 echo &&
1824 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1825 elif test -f "$ac_srcdir/configure"; then
1826 echo &&
1827 $SHELL "$ac_srcdir/configure" --help=recursive
3ace7edb 1828 else
81ecdfbb
RW
1829 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1830 fi || ac_status=$?
1831 cd "$ac_pwd" || { ac_status=$?; break; }
bec39cab
AC
1832 done
1833fi
1834
81ecdfbb 1835test -n "$ac_init_help" && exit $ac_status
bec39cab
AC
1836if $ac_init_version; then
1837 cat <<\_ACEOF
81ecdfbb 1838configure
d0ac1c44 1839generated by GNU Autoconf 2.69
bec39cab 1840
d0ac1c44 1841Copyright (C) 2012 Free Software Foundation, Inc.
bec39cab
AC
1842This configure script is free software; the Free Software Foundation
1843gives unlimited permission to copy, distribute and modify it.
1844_ACEOF
81ecdfbb 1845 exit
bec39cab 1846fi
bec39cab 1847
81ecdfbb
RW
1848## ------------------------ ##
1849## Autoconf initialization. ##
1850## ------------------------ ##
bec39cab 1851
81ecdfbb
RW
1852# ac_fn_c_try_compile LINENO
1853# --------------------------
1854# Try to compile conftest.$ac_ext, and return whether this succeeded.
1855ac_fn_c_try_compile ()
1856{
1857 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1858 rm -f conftest.$ac_objext
1859 if { { ac_try="$ac_compile"
1860case "(($ac_try" in
1861 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1862 *) ac_try_echo=$ac_try;;
1863esac
1864eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1865$as_echo "$ac_try_echo"; } >&5
1866 (eval "$ac_compile") 2>conftest.err
1867 ac_status=$?
1868 if test -s conftest.err; then
1869 grep -v '^ *+' conftest.err >conftest.er1
1870 cat conftest.er1 >&5
1871 mv -f conftest.er1 conftest.err
1872 fi
1873 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1874 test $ac_status = 0; } && {
1875 test -z "$ac_c_werror_flag" ||
1876 test ! -s conftest.err
1877 } && test -s conftest.$ac_objext; then :
1878 ac_retval=0
1879else
1880 $as_echo "$as_me: failed program was:" >&5
1881sed 's/^/| /' conftest.$ac_ext >&5
bec39cab 1882
81ecdfbb
RW
1883 ac_retval=1
1884fi
d0ac1c44
SM
1885 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1886 as_fn_set_status $ac_retval
81ecdfbb
RW
1887
1888} # ac_fn_c_try_compile
1889
3bc3d82a
PA
1890# ac_fn_cxx_try_compile LINENO
1891# ----------------------------
1892# Try to compile conftest.$ac_ext, and return whether this succeeded.
1893ac_fn_cxx_try_compile ()
1894{
1895 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1896 rm -f conftest.$ac_objext
1897 if { { ac_try="$ac_compile"
1898case "(($ac_try" in
1899 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1900 *) ac_try_echo=$ac_try;;
1901esac
1902eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1903$as_echo "$ac_try_echo"; } >&5
1904 (eval "$ac_compile") 2>conftest.err
1905 ac_status=$?
1906 if test -s conftest.err; then
1907 grep -v '^ *+' conftest.err >conftest.er1
1908 cat conftest.er1 >&5
1909 mv -f conftest.er1 conftest.err
1910 fi
1911 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1912 test $ac_status = 0; } && {
1913 test -z "$ac_cxx_werror_flag" ||
1914 test ! -s conftest.err
1915 } && test -s conftest.$ac_objext; then :
1916 ac_retval=0
1917else
1918 $as_echo "$as_me: failed program was:" >&5
1919sed 's/^/| /' conftest.$ac_ext >&5
1920
1921 ac_retval=1
1922fi
d0ac1c44
SM
1923 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1924 as_fn_set_status $ac_retval
3bc3d82a
PA
1925
1926} # ac_fn_cxx_try_compile
1927
81ecdfbb
RW
1928# ac_fn_c_try_cpp LINENO
1929# ----------------------
1930# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1931ac_fn_c_try_cpp ()
bec39cab 1932{
81ecdfbb
RW
1933 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1934 if { { ac_try="$ac_cpp conftest.$ac_ext"
1935case "(($ac_try" in
1936 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1937 *) ac_try_echo=$ac_try;;
1938esac
1939eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1940$as_echo "$ac_try_echo"; } >&5
1941 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1942 ac_status=$?
1943 if test -s conftest.err; then
1944 grep -v '^ *+' conftest.err >conftest.er1
1945 cat conftest.er1 >&5
1946 mv -f conftest.er1 conftest.err
1947 fi
1948 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
d0ac1c44 1949 test $ac_status = 0; } > conftest.i && {
81ecdfbb
RW
1950 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1951 test ! -s conftest.err
1952 }; then :
1953 ac_retval=0
1954else
1955 $as_echo "$as_me: failed program was:" >&5
1956sed 's/^/| /' conftest.$ac_ext >&5
bec39cab 1957
81ecdfbb
RW
1958 ac_retval=1
1959fi
d0ac1c44
SM
1960 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1961 as_fn_set_status $ac_retval
bec39cab 1962
81ecdfbb 1963} # ac_fn_c_try_cpp
bec39cab 1964
81ecdfbb
RW
1965# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
1966# -------------------------------------------------------
1967# Tests whether HEADER exists, giving a warning if it cannot be compiled using
1968# the include files in INCLUDES and setting the cache variable VAR
1969# accordingly.
1970ac_fn_c_check_header_mongrel ()
1971{
1972 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
d0ac1c44 1973 if eval \${$3+:} false; then :
81ecdfbb
RW
1974 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1975$as_echo_n "checking for $2... " >&6; }
d0ac1c44 1976if eval \${$3+:} false; then :
81ecdfbb
RW
1977 $as_echo_n "(cached) " >&6
1978fi
1979eval ac_res=\$$3
1980 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1981$as_echo "$ac_res" >&6; }
1982else
1983 # Is the header compilable?
1984{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
1985$as_echo_n "checking $2 usability... " >&6; }
1986cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1987/* end confdefs.h. */
1988$4
1989#include <$2>
1990_ACEOF
1991if ac_fn_c_try_compile "$LINENO"; then :
1992 ac_header_compiler=yes
1993else
1994 ac_header_compiler=no
1995fi
1996rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1997{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
1998$as_echo "$ac_header_compiler" >&6; }
bec39cab 1999
81ecdfbb
RW
2000# Is the header present?
2001{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2002$as_echo_n "checking $2 presence... " >&6; }
2003cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2004/* end confdefs.h. */
2005#include <$2>
2006_ACEOF
2007if ac_fn_c_try_cpp "$LINENO"; then :
2008 ac_header_preproc=yes
2009else
2010 ac_header_preproc=no
2011fi
d0ac1c44 2012rm -f conftest.err conftest.i conftest.$ac_ext
81ecdfbb
RW
2013{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2014$as_echo "$ac_header_preproc" >&6; }
bec39cab 2015
81ecdfbb
RW
2016# So? What about this header?
2017case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
2018 yes:no: )
2019 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2020$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2021 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2022$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2023 ;;
2024 no:yes:* )
2025 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2026$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2027 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
2028$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
2029 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2030$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2031 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
2032$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
2033 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2034$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2035 ;;
2036esac
2037 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2038$as_echo_n "checking for $2... " >&6; }
d0ac1c44 2039if eval \${$3+:} false; then :
81ecdfbb
RW
2040 $as_echo_n "(cached) " >&6
2041else
2042 eval "$3=\$ac_header_compiler"
2043fi
2044eval ac_res=\$$3
2045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2046$as_echo "$ac_res" >&6; }
2047fi
d0ac1c44 2048 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
bec39cab 2049
81ecdfbb 2050} # ac_fn_c_check_header_mongrel
bec39cab 2051
81ecdfbb
RW
2052# ac_fn_c_try_run LINENO
2053# ----------------------
2054# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2055# that executables *can* be run.
2056ac_fn_c_try_run ()
2057{
2058 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2059 if { { ac_try="$ac_link"
2060case "(($ac_try" in
2061 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2062 *) ac_try_echo=$ac_try;;
2063esac
2064eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2065$as_echo "$ac_try_echo"; } >&5
2066 (eval "$ac_link") 2>&5
2067 ac_status=$?
2068 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2069 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2070 { { case "(($ac_try" in
2071 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2072 *) ac_try_echo=$ac_try;;
2073esac
2074eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2075$as_echo "$ac_try_echo"; } >&5
2076 (eval "$ac_try") 2>&5
2077 ac_status=$?
2078 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2079 test $ac_status = 0; }; }; then :
2080 ac_retval=0
2081else
2082 $as_echo "$as_me: program exited with status $ac_status" >&5
2083 $as_echo "$as_me: failed program was:" >&5
2084sed 's/^/| /' conftest.$ac_ext >&5
bec39cab 2085
81ecdfbb
RW
2086 ac_retval=$ac_status
2087fi
2088 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
d0ac1c44
SM
2089 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2090 as_fn_set_status $ac_retval
bec39cab 2091
81ecdfbb 2092} # ac_fn_c_try_run
bec39cab 2093
81ecdfbb
RW
2094# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2095# -------------------------------------------------------
2096# Tests whether HEADER exists and can be compiled using the include files in
2097# INCLUDES, setting the cache variable VAR accordingly.
2098ac_fn_c_check_header_compile ()
2099{
2100 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2101 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2102$as_echo_n "checking for $2... " >&6; }
d0ac1c44 2103if eval \${$3+:} false; then :
81ecdfbb
RW
2104 $as_echo_n "(cached) " >&6
2105else
2106 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2107/* end confdefs.h. */
2108$4
2109#include <$2>
bec39cab 2110_ACEOF
81ecdfbb
RW
2111if ac_fn_c_try_compile "$LINENO"; then :
2112 eval "$3=yes"
2113else
2114 eval "$3=no"
2115fi
2116rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2117fi
2118eval ac_res=\$$3
2119 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2120$as_echo "$ac_res" >&6; }
d0ac1c44 2121 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
bec39cab 2122
81ecdfbb 2123} # ac_fn_c_check_header_compile
bec39cab 2124
2974be62
AM
2125# ac_fn_c_try_link LINENO
2126# -----------------------
2127# Try to link conftest.$ac_ext, and return whether this succeeded.
2128ac_fn_c_try_link ()
2129{
2130 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2131 rm -f conftest.$ac_objext conftest$ac_exeext
2132 if { { ac_try="$ac_link"
2133case "(($ac_try" in
2134 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2135 *) ac_try_echo=$ac_try;;
2136esac
2137eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2138$as_echo "$ac_try_echo"; } >&5
2139 (eval "$ac_link") 2>conftest.err
2140 ac_status=$?
2141 if test -s conftest.err; then
2142 grep -v '^ *+' conftest.err >conftest.er1
2143 cat conftest.er1 >&5
2144 mv -f conftest.er1 conftest.err
2145 fi
2146 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2147 test $ac_status = 0; } && {
2148 test -z "$ac_c_werror_flag" ||
2149 test ! -s conftest.err
2150 } && test -s conftest$ac_exeext && {
2151 test "$cross_compiling" = yes ||
d0ac1c44 2152 test -x conftest$ac_exeext
2974be62
AM
2153 }; then :
2154 ac_retval=0
2155else
2156 $as_echo "$as_me: failed program was:" >&5
2157sed 's/^/| /' conftest.$ac_ext >&5
2158
2159 ac_retval=1
2160fi
2161 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2162 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2163 # interfere with the next link command; also delete a directory that is
2164 # left behind by Apple's compiler. We do this before executing the actions.
2165 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
d0ac1c44
SM
2166 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2167 as_fn_set_status $ac_retval
2974be62
AM
2168
2169} # ac_fn_c_try_link
2170
b686ecb5
JM
2171# ac_fn_c_check_func LINENO FUNC VAR
2172# ----------------------------------
2173# Tests whether FUNC exists, setting the cache variable VAR accordingly
2174ac_fn_c_check_func ()
2175{
2176 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2177 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2178$as_echo_n "checking for $2... " >&6; }
2179if eval \${$3+:} false; then :
2180 $as_echo_n "(cached) " >&6
2181else
2182 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2183/* end confdefs.h. */
2184/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2185 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2186#define $2 innocuous_$2
2187
2188/* System header to define __stub macros and hopefully few prototypes,
2189 which can conflict with char $2 (); below.
2190 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2191 <limits.h> exists even on freestanding compilers. */
2192
2193#ifdef __STDC__
2194# include <limits.h>
2195#else
2196# include <assert.h>
2197#endif
2198
2199#undef $2
2200
2201/* Override any GCC internal prototype to avoid an error.
2202 Use char because int might match the return type of a GCC
2203 builtin and then its argument prototype would still apply. */
2204#ifdef __cplusplus
2205extern "C"
2206#endif
2207char $2 ();
2208/* The GNU C library defines this for functions which it implements
2209 to always fail with ENOSYS. Some functions are actually named
2210 something starting with __ and the normal name is an alias. */
2211#if defined __stub_$2 || defined __stub___$2
2212choke me
2213#endif
2214
2215int
2216main ()
2217{
2218return $2 ();
2219 ;
2220 return 0;
2221}
2222_ACEOF
2223if ac_fn_c_try_link "$LINENO"; then :
2224 eval "$3=yes"
2225else
2226 eval "$3=no"
2227fi
2228rm -f core conftest.err conftest.$ac_objext \
2229 conftest$ac_exeext conftest.$ac_ext
2230fi
2231eval ac_res=\$$3
2232 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2233$as_echo "$ac_res" >&6; }
2234 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2235
2236} # ac_fn_c_check_func
2237
2238# ac_fn_cxx_try_cpp LINENO
2239# ------------------------
2240# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2241ac_fn_cxx_try_cpp ()
2242{
2243 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2244 if { { ac_try="$ac_cpp conftest.$ac_ext"
2245case "(($ac_try" in
2246 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2247 *) ac_try_echo=$ac_try;;
2248esac
2249eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2250$as_echo "$ac_try_echo"; } >&5
2251 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2252 ac_status=$?
2253 if test -s conftest.err; then
2254 grep -v '^ *+' conftest.err >conftest.er1
2255 cat conftest.er1 >&5
2256 mv -f conftest.er1 conftest.err
2257 fi
2258 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2259 test $ac_status = 0; } > conftest.i && {
2260 test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" ||
2261 test ! -s conftest.err
2262 }; then :
2263 ac_retval=0
2264else
2265 $as_echo "$as_me: failed program was:" >&5
2266sed 's/^/| /' conftest.$ac_ext >&5
2267
2268 ac_retval=1
2269fi
2270 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2271 as_fn_set_status $ac_retval
2272
2273} # ac_fn_cxx_try_cpp
2274
2275# ac_fn_cxx_try_link LINENO
2276# -------------------------
2277# Try to link conftest.$ac_ext, and return whether this succeeded.
2278ac_fn_cxx_try_link ()
2279{
2280 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2281 rm -f conftest.$ac_objext conftest$ac_exeext
2282 if { { ac_try="$ac_link"
2283case "(($ac_try" in
2284 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2285 *) ac_try_echo=$ac_try;;
2286esac
2287eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2288$as_echo "$ac_try_echo"; } >&5
2289 (eval "$ac_link") 2>conftest.err
2290 ac_status=$?
2291 if test -s conftest.err; then
2292 grep -v '^ *+' conftest.err >conftest.er1
2293 cat conftest.er1 >&5
2294 mv -f conftest.er1 conftest.err
2295 fi
2296 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2297 test $ac_status = 0; } && {
2298 test -z "$ac_cxx_werror_flag" ||
2299 test ! -s conftest.err
2300 } && test -s conftest$ac_exeext && {
2301 test "$cross_compiling" = yes ||
2302 test -x conftest$ac_exeext
2303 }; then :
2304 ac_retval=0
2305else
2306 $as_echo "$as_me: failed program was:" >&5
2307sed 's/^/| /' conftest.$ac_ext >&5
2308
2309 ac_retval=1
2310fi
2311 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2312 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2313 # interfere with the next link command; also delete a directory that is
2314 # left behind by Apple's compiler. We do this before executing the actions.
2315 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2316 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2317 as_fn_set_status $ac_retval
2318
2319} # ac_fn_cxx_try_link
2320
81ecdfbb
RW
2321# ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2322# --------------------------------------------
2323# Tries to find the compile-time value of EXPR in a program that includes
2324# INCLUDES, setting VAR accordingly. Returns whether the value could be
2325# computed
2326ac_fn_c_compute_int ()
2327{
2328 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2329 if test "$cross_compiling" = yes; then
2330 # Depending upon the size, compute the lo and hi bounds.
2331cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2332/* end confdefs.h. */
2333$4
2334int
2335main ()
2336{
2337static int test_array [1 - 2 * !(($2) >= 0)];
d0ac1c44
SM
2338test_array [0] = 0;
2339return test_array [0];
bec39cab 2340
81ecdfbb
RW
2341 ;
2342 return 0;
2343}
2344_ACEOF
2345if ac_fn_c_try_compile "$LINENO"; then :
2346 ac_lo=0 ac_mid=0
2347 while :; do
2348 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2349/* end confdefs.h. */
2350$4
2351int
2352main ()
2353{
2354static int test_array [1 - 2 * !(($2) <= $ac_mid)];
d0ac1c44
SM
2355test_array [0] = 0;
2356return test_array [0];
bec39cab 2357
81ecdfbb
RW
2358 ;
2359 return 0;
2360}
2361_ACEOF
2362if ac_fn_c_try_compile "$LINENO"; then :
2363 ac_hi=$ac_mid; break
2364else
2365 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2366 if test $ac_lo -le $ac_mid; then
2367 ac_lo= ac_hi=
2368 break
2369 fi
2370 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
c906108c 2371fi
81ecdfbb
RW
2372rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2373 done
c906108c 2374else
81ecdfbb
RW
2375 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2376/* end confdefs.h. */
2377$4
2378int
2379main ()
2380{
2381static int test_array [1 - 2 * !(($2) < 0)];
d0ac1c44
SM
2382test_array [0] = 0;
2383return test_array [0];
bec39cab 2384
81ecdfbb
RW
2385 ;
2386 return 0;
2387}
2388_ACEOF
2389if ac_fn_c_try_compile "$LINENO"; then :
2390 ac_hi=-1 ac_mid=-1
2391 while :; do
2392 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2393/* end confdefs.h. */
2394$4
2395int
2396main ()
2397{
2398static int test_array [1 - 2 * !(($2) >= $ac_mid)];
d0ac1c44
SM
2399test_array [0] = 0;
2400return test_array [0];
bec39cab 2401
81ecdfbb
RW
2402 ;
2403 return 0;
2404}
2405_ACEOF
2406if ac_fn_c_try_compile "$LINENO"; then :
2407 ac_lo=$ac_mid; break
2408else
2409 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2410 if test $ac_mid -le $ac_hi; then
2411 ac_lo= ac_hi=
2412 break
2413 fi
2414 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2415fi
2416rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2417 done
2418else
2419 ac_lo= ac_hi=
2420fi
2421rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2422fi
2423rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2424# Binary search between lo and hi bounds.
2425while test "x$ac_lo" != "x$ac_hi"; do
2426 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2427 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2428/* end confdefs.h. */
2429$4
2430int
2431main ()
2432{
2433static int test_array [1 - 2 * !(($2) <= $ac_mid)];
d0ac1c44
SM
2434test_array [0] = 0;
2435return test_array [0];
bec39cab 2436
81ecdfbb
RW
2437 ;
2438 return 0;
2439}
2440_ACEOF
2441if ac_fn_c_try_compile "$LINENO"; then :
2442 ac_hi=$ac_mid
2443else
2444 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2445fi
2446rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2447done
2448case $ac_lo in #((
2449?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2450'') ac_retval=1 ;;
2451esac
2452 else
2453 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2454/* end confdefs.h. */
2455$4
2456static long int longval () { return $2; }
2457static unsigned long int ulongval () { return $2; }
2458#include <stdio.h>
2459#include <stdlib.h>
2460int
2461main ()
2462{
bec39cab 2463
81ecdfbb
RW
2464 FILE *f = fopen ("conftest.val", "w");
2465 if (! f)
2466 return 1;
2467 if (($2) < 0)
2468 {
2469 long int i = longval ();
2470 if (i != ($2))
2471 return 1;
2472 fprintf (f, "%ld", i);
2473 }
2474 else
2475 {
2476 unsigned long int i = ulongval ();
2477 if (i != ($2))
2478 return 1;
2479 fprintf (f, "%lu", i);
2480 }
2481 /* Do not output a trailing newline, as this causes \r\n confusion
2482 on some platforms. */
2483 return ferror (f) || fclose (f) != 0;
bec39cab 2484
81ecdfbb
RW
2485 ;
2486 return 0;
2487}
2488_ACEOF
2489if ac_fn_c_try_run "$LINENO"; then :
2490 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2491else
2492 ac_retval=1
2493fi
2494rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2495 conftest.$ac_objext conftest.beam conftest.$ac_ext
2496rm -f conftest.val
bec39cab 2497
81ecdfbb 2498 fi
d0ac1c44
SM
2499 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2500 as_fn_set_status $ac_retval
bec39cab 2501
81ecdfbb 2502} # ac_fn_c_compute_int
bec39cab 2503
b686ecb5
JM
2504# ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2505# -------------------------------------------
2506# Tests whether TYPE exists after having included INCLUDES, setting cache
2507# variable VAR accordingly.
2508ac_fn_c_check_type ()
81ecdfbb
RW
2509{
2510 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2511 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2512$as_echo_n "checking for $2... " >&6; }
d0ac1c44 2513if eval \${$3+:} false; then :
81ecdfbb
RW
2514 $as_echo_n "(cached) " >&6
2515else
b686ecb5 2516 eval "$3=no"
81ecdfbb
RW
2517 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2518/* end confdefs.h. */
b686ecb5 2519$4
55a8c076
YQ
2520int
2521main ()
2522{
b686ecb5
JM
2523if (sizeof ($2))
2524 return 0;
55a8c076
YQ
2525 ;
2526 return 0;
2527}
2528_ACEOF
b686ecb5
JM
2529if ac_fn_c_try_compile "$LINENO"; then :
2530 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2531/* end confdefs.h. */
2532$4
2533int
2534main ()
2535{
2536if (sizeof (($2)))
2537 return 0;
2538 ;
2539 return 0;
2540}
2541_ACEOF
2542if ac_fn_c_try_compile "$LINENO"; then :
2543
55a8c076 2544else
b686ecb5 2545 eval "$3=yes"
55a8c076 2546fi
b686ecb5
JM
2547rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2548fi
2549rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
55a8c076
YQ
2550fi
2551eval ac_res=\$$3
2552 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2553$as_echo "$ac_res" >&6; }
d0ac1c44 2554 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
55a8c076 2555
b686ecb5 2556} # ac_fn_c_check_type
55a8c076 2557
b686ecb5
JM
2558# ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
2559# ---------------------------------------------
2560# Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
2561# accordingly.
2562ac_fn_c_check_decl ()
f6720b1c
AM
2563{
2564 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2565 as_decl_name=`echo $2|sed 's/ *(.*//'`
2566 as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
2567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
2568$as_echo_n "checking whether $as_decl_name is declared... " >&6; }
2569if eval \${$3+:} false; then :
2570 $as_echo_n "(cached) " >&6
2571else
2572 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2573/* end confdefs.h. */
2574$4
2575int
2576main ()
2577{
2578#ifndef $as_decl_name
2579#ifdef __cplusplus
2580 (void) $as_decl_use;
2581#else
2582 (void) $as_decl_name;
2583#endif
2584#endif
2585
2586 ;
2587 return 0;
2588}
2589_ACEOF
2590if ac_fn_c_try_compile "$LINENO"; then :
2591 eval "$3=yes"
2592else
2593 eval "$3=no"
2594fi
2595rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2596fi
2597eval ac_res=\$$3
2598 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2599$as_echo "$ac_res" >&6; }
2600 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2601
2602} # ac_fn_c_check_decl
2603
05ea2a05
TT
2604# ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2605# ----------------------------------------------------
2606# Tries to find if the field MEMBER exists in type AGGR, after including
2607# INCLUDES, setting cache variable VAR accordingly.
2608ac_fn_c_check_member ()
2609{
2610 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2611 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2612$as_echo_n "checking for $2.$3... " >&6; }
2613if eval \${$4+:} false; then :
2614 $as_echo_n "(cached) " >&6
2615else
2616 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2617/* end confdefs.h. */
2618$5
2619int
2620main ()
2621{
2622static $2 ac_aggr;
2623if (ac_aggr.$3)
2624return 0;
2625 ;
2626 return 0;
2627}
2628_ACEOF
2629if ac_fn_c_try_compile "$LINENO"; then :
2630 eval "$4=yes"
2631else
2632 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2633/* end confdefs.h. */
2634$5
2635int
2636main ()
2637{
2638static $2 ac_aggr;
2639if (sizeof ac_aggr.$3)
2640return 0;
2641 ;
2642 return 0;
2643}
2644_ACEOF
2645if ac_fn_c_try_compile "$LINENO"; then :
2646 eval "$4=yes"
2647else
2648 eval "$4=no"
2649fi
2650rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2651fi
2652rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2653fi
2654eval ac_res=\$$4
2655 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2656$as_echo "$ac_res" >&6; }
2657 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2658
2659} # ac_fn_c_check_member
2660
21987b9c
TT
2661# ac_fn_cxx_check_func LINENO FUNC VAR
2662# ------------------------------------
2663# Tests whether FUNC exists, setting the cache variable VAR accordingly
2664ac_fn_cxx_check_func ()
2665{
2666 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2667 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2668$as_echo_n "checking for $2... " >&6; }
2669if eval \${$3+:} false; then :
2670 $as_echo_n "(cached) " >&6
2671else
2672 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2673/* end confdefs.h. */
2674/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2675 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2676#define $2 innocuous_$2
2677
2678/* System header to define __stub macros and hopefully few prototypes,
2679 which can conflict with char $2 (); below.
2680 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2681 <limits.h> exists even on freestanding compilers. */
2682
2683#ifdef __STDC__
2684# include <limits.h>
2685#else
2686# include <assert.h>
2687#endif
2688
2689#undef $2
2690
2691/* Override any GCC internal prototype to avoid an error.
2692 Use char because int might match the return type of a GCC
2693 builtin and then its argument prototype would still apply. */
2694#ifdef __cplusplus
2695extern "C"
2696#endif
2697char $2 ();
2698/* The GNU C library defines this for functions which it implements
2699 to always fail with ENOSYS. Some functions are actually named
2700 something starting with __ and the normal name is an alias. */
2701#if defined __stub_$2 || defined __stub___$2
2702choke me
2703#endif
2704
2705int
2706main ()
2707{
2708return $2 ();
2709 ;
2710 return 0;
2711}
2712_ACEOF
2713if ac_fn_cxx_try_link "$LINENO"; then :
2714 eval "$3=yes"
2715else
2716 eval "$3=no"
2717fi
2718rm -f core conftest.err conftest.$ac_objext \
2719 conftest$ac_exeext conftest.$ac_ext
2720fi
2721eval ac_res=\$$3
2722 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2723$as_echo "$ac_res" >&6; }
2724 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2725
2726} # ac_fn_cxx_check_func
81ecdfbb
RW
2727cat >config.log <<_ACEOF
2728This file contains any messages produced by compilers while
2729running configure, to aid debugging if configure makes a mistake.
d5af19ba 2730
81ecdfbb 2731It was created by $as_me, which was
d0ac1c44 2732generated by GNU Autoconf 2.69. Invocation command line was
b4e70030 2733
81ecdfbb 2734 $ $0 $@
413ccac7 2735
81ecdfbb
RW
2736_ACEOF
2737exec 5>>config.log
2738{
2739cat <<_ASUNAME
2740## --------- ##
2741## Platform. ##
2742## --------- ##
413ccac7 2743
81ecdfbb
RW
2744hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2745uname -m = `(uname -m) 2>/dev/null || echo unknown`
2746uname -r = `(uname -r) 2>/dev/null || echo unknown`
2747uname -s = `(uname -s) 2>/dev/null || echo unknown`
2748uname -v = `(uname -v) 2>/dev/null || echo unknown`
85981d60 2749
81ecdfbb
RW
2750/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2751/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
413ccac7 2752
81ecdfbb
RW
2753/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2754/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2755/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2756/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2757/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2758/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2759/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
c906108c 2760
81ecdfbb 2761_ASUNAME
bec39cab 2762
bec39cab
AC
2763as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2764for as_dir in $PATH
2765do
2766 IFS=$as_save_IFS
2767 test -z "$as_dir" && as_dir=.
81ecdfbb
RW
2768 $as_echo "PATH: $as_dir"
2769 done
2770IFS=$as_save_IFS
bec39cab 2771
81ecdfbb 2772} >&5
bec39cab 2773
81ecdfbb 2774cat >&5 <<_ACEOF
bec39cab 2775
bec39cab 2776
81ecdfbb
RW
2777## ----------- ##
2778## Core tests. ##
2779## ----------- ##
2780
2781_ACEOF
2782
2783
2784# Keep a trace of the command line.
2785# Strip out --no-create and --no-recursion so they do not pile up.
2786# Strip out --silent because we don't want to record it for future runs.
2787# Also quote any args containing shell meta-characters.
2788# Make two passes to allow for proper duplicate-argument suppression.
2789ac_configure_args=
2790ac_configure_args0=
2791ac_configure_args1=
2792ac_must_keep_next=false
2793for ac_pass in 1 2
2794do
2795 for ac_arg
2796 do
2797 case $ac_arg in
2798 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2799 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2800 | -silent | --silent | --silen | --sile | --sil)
2801 continue ;;
2802 *\'*)
2803 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2804 esac
2805 case $ac_pass in
2806 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2807 2)
2808 as_fn_append ac_configure_args1 " '$ac_arg'"
2809 if test $ac_must_keep_next = true; then
2810 ac_must_keep_next=false # Got value, back to normal.
2811 else
2812 case $ac_arg in
2813 *=* | --config-cache | -C | -disable-* | --disable-* \
2814 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2815 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2816 | -with-* | --with-* | -without-* | --without-* | --x)
2817 case "$ac_configure_args0 " in
2818 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2819 esac
2820 ;;
2821 -* ) ac_must_keep_next=true ;;
2822 esac
2823 fi
2824 as_fn_append ac_configure_args " '$ac_arg'"
2825 ;;
2826 esac
2827 done
2828done
2829{ ac_configure_args0=; unset ac_configure_args0;}
2830{ ac_configure_args1=; unset ac_configure_args1;}
2831
2832# When interrupted or exit'd, cleanup temporary files, and complete
2833# config.log. We remove comments because anyway the quotes in there
2834# would cause problems or look ugly.
2835# WARNING: Use '\'' to represent an apostrophe within the trap.
2836# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2837trap 'exit_status=$?
2838 # Save into config.log some information that might help in debugging.
2839 {
2840 echo
2841
d0ac1c44 2842 $as_echo "## ---------------- ##
81ecdfbb 2843## Cache variables. ##
d0ac1c44 2844## ---------------- ##"
81ecdfbb
RW
2845 echo
2846 # The following way of writing the cache mishandles newlines in values,
2847(
2848 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2849 eval ac_val=\$$ac_var
2850 case $ac_val in #(
2851 *${as_nl}*)
2852 case $ac_var in #(
2853 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2854$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2855 esac
2856 case $ac_var in #(
2857 _ | IFS | as_nl) ;; #(
2858 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2859 *) { eval $ac_var=; unset $ac_var;} ;;
2860 esac ;;
2861 esac
2862 done
2863 (set) 2>&1 |
2864 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2865 *${as_nl}ac_space=\ *)
2866 sed -n \
2867 "s/'\''/'\''\\\\'\'''\''/g;
2868 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2869 ;; #(
2870 *)
2871 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2872 ;;
2873 esac |
2874 sort
2875)
2876 echo
2877
d0ac1c44 2878 $as_echo "## ----------------- ##
81ecdfbb 2879## Output variables. ##
d0ac1c44 2880## ----------------- ##"
81ecdfbb
RW
2881 echo
2882 for ac_var in $ac_subst_vars
2883 do
2884 eval ac_val=\$$ac_var
2885 case $ac_val in
2886 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2887 esac
2888 $as_echo "$ac_var='\''$ac_val'\''"
2889 done | sort
2890 echo
2891
2892 if test -n "$ac_subst_files"; then
d0ac1c44 2893 $as_echo "## ------------------- ##
81ecdfbb 2894## File substitutions. ##
d0ac1c44 2895## ------------------- ##"
81ecdfbb
RW
2896 echo
2897 for ac_var in $ac_subst_files
2898 do
2899 eval ac_val=\$$ac_var
2900 case $ac_val in
2901 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2902 esac
2903 $as_echo "$ac_var='\''$ac_val'\''"
2904 done | sort
2905 echo
2906 fi
2907
2908 if test -s confdefs.h; then
d0ac1c44 2909 $as_echo "## ----------- ##
81ecdfbb 2910## confdefs.h. ##
d0ac1c44 2911## ----------- ##"
81ecdfbb
RW
2912 echo
2913 cat confdefs.h
2914 echo
2915 fi
2916 test "$ac_signal" != 0 &&
2917 $as_echo "$as_me: caught signal $ac_signal"
2918 $as_echo "$as_me: exit $exit_status"
2919 } >&5
2920 rm -f core *.core core.conftest.* &&
2921 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2922 exit $exit_status
2923' 0
2924for ac_signal in 1 2 13 15; do
2925 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2926done
2927ac_signal=0
2928
2929# confdefs.h avoids OS command line length limits that DEFS can exceed.
2930rm -f -r conftest* confdefs.h
2931
2932$as_echo "/* confdefs.h */" > confdefs.h
2933
2934# Predefined preprocessor variables.
2935
2936cat >>confdefs.h <<_ACEOF
2937#define PACKAGE_NAME "$PACKAGE_NAME"
2938_ACEOF
2939
2940cat >>confdefs.h <<_ACEOF
2941#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2942_ACEOF
2943
2944cat >>confdefs.h <<_ACEOF
2945#define PACKAGE_VERSION "$PACKAGE_VERSION"
2946_ACEOF
2947
2948cat >>confdefs.h <<_ACEOF
2949#define PACKAGE_STRING "$PACKAGE_STRING"
2950_ACEOF
2951
2952cat >>confdefs.h <<_ACEOF
2953#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2954_ACEOF
2955
2956cat >>confdefs.h <<_ACEOF
2957#define PACKAGE_URL "$PACKAGE_URL"
2958_ACEOF
2959
2960
2961# Let the site file select an alternate cache file if it wants to.
2962# Prefer an explicitly selected file to automatically selected ones.
2963ac_site_file1=NONE
2964ac_site_file2=NONE
2965if test -n "$CONFIG_SITE"; then
d0ac1c44
SM
2966 # We do not want a PATH search for config.site.
2967 case $CONFIG_SITE in #((
2968 -*) ac_site_file1=./$CONFIG_SITE;;
2969 */*) ac_site_file1=$CONFIG_SITE;;
2970 *) ac_site_file1=./$CONFIG_SITE;;
2971 esac
81ecdfbb
RW
2972elif test "x$prefix" != xNONE; then
2973 ac_site_file1=$prefix/share/config.site
2974 ac_site_file2=$prefix/etc/config.site
2975else
2976 ac_site_file1=$ac_default_prefix/share/config.site
2977 ac_site_file2=$ac_default_prefix/etc/config.site
2978fi
2979for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2980do
2981 test "x$ac_site_file" = xNONE && continue
d0ac1c44 2982 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
81ecdfbb
RW
2983 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2984$as_echo "$as_me: loading site script $ac_site_file" >&6;}
2985 sed 's/^/| /' "$ac_site_file" >&5
d0ac1c44
SM
2986 . "$ac_site_file" \
2987 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2988$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2989as_fn_error $? "failed to load site script $ac_site_file
2990See \`config.log' for more details" "$LINENO" 5; }
81ecdfbb
RW
2991 fi
2992done
2993
2994if test -r "$cache_file"; then
d0ac1c44
SM
2995 # Some versions of bash will fail to source /dev/null (special files
2996 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
2997 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
81ecdfbb
RW
2998 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2999$as_echo "$as_me: loading cache $cache_file" >&6;}
3000 case $cache_file in
3001 [\\/]* | ?:[\\/]* ) . "$cache_file";;
3002 *) . "./$cache_file";;
3003 esac
3004 fi
3005else
3006 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
3007$as_echo "$as_me: creating cache $cache_file" >&6;}
3008 >$cache_file
bec39cab
AC
3009fi
3010
d0ac1c44
SM
3011as_fn_append ac_header_list " stdlib.h"
3012as_fn_append ac_header_list " unistd.h"
3013as_fn_append ac_header_list " sys/param.h"
81ecdfbb
RW
3014# Check that the precious variables saved in the cache have kept the same
3015# value.
3016ac_cache_corrupted=false
3017for ac_var in $ac_precious_vars; do
3018 eval ac_old_set=\$ac_cv_env_${ac_var}_set
3019 eval ac_new_set=\$ac_env_${ac_var}_set
3020 eval ac_old_val=\$ac_cv_env_${ac_var}_value
3021 eval ac_new_val=\$ac_env_${ac_var}_value
3022 case $ac_old_set,$ac_new_set in
3023 set,)
3024 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3025$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3026 ac_cache_corrupted=: ;;
3027 ,set)
3028 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3029$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3030 ac_cache_corrupted=: ;;
3031 ,);;
3032 *)
3033 if test "x$ac_old_val" != "x$ac_new_val"; then
3034 # differences in whitespace do not lead to failure.
3035 ac_old_val_w=`echo x $ac_old_val`
3036 ac_new_val_w=`echo x $ac_new_val`
3037 if test "$ac_old_val_w" != "$ac_new_val_w"; then
3038 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3039$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
3040 ac_cache_corrupted=:
3041 else
3042 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3043$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
3044 eval $ac_var=\$ac_old_val
3045 fi
3046 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
3047$as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
3048 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
3049$as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
3050 fi;;
3051 esac
3052 # Pass precious variables to config.status.
3053 if test "$ac_new_set" = set; then
3054 case $ac_new_val in
3055 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3056 *) ac_arg=$ac_var=$ac_new_val ;;
3057 esac
3058 case " $ac_configure_args " in
3059 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
3060 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3061 esac
3062 fi
3063done
3064if $ac_cache_corrupted; then
3065 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3066$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3067 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3068$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
d0ac1c44 3069 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
81ecdfbb
RW
3070fi
3071## -------------------- ##
3072## Main body of script. ##
3073## -------------------- ##
3074
3075ac_ext=c
3076ac_cpp='$CPP $CPPFLAGS'
3077ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3078ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3079ac_compiler_gnu=$ac_cv_c_compiler_gnu
3080
3081
3082
3083
3084
5593a99a 3085
7e3941ac 3086
81ecdfbb
RW
3087ac_config_headers="$ac_config_headers config.h:config.in"
3088
3089
3090{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5
3091$as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
3092 # Check whether --enable-maintainer-mode was given.
3093if test "${enable_maintainer_mode+set}" = set; then :
3094 enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
3095else
3096 USE_MAINTAINER_MODE=no
3097fi
3098
3099 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5
3100$as_echo "$USE_MAINTAINER_MODE" >&6; }
3101 if test $USE_MAINTAINER_MODE = yes; then
3102 MAINTAINER_MODE_TRUE=
3103 MAINTAINER_MODE_FALSE='#'
3104else
3105 MAINTAINER_MODE_TRUE='#'
3106 MAINTAINER_MODE_FALSE=
3107fi
3108
3109 MAINT=$MAINTAINER_MODE_TRUE
3110
3111
3112
3113ac_ext=c
3114ac_cpp='$CPP $CPPFLAGS'
3115ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3116ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3117ac_compiler_gnu=$ac_cv_c_compiler_gnu
3118if test -n "$ac_tool_prefix"; then
3119 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
3120set dummy ${ac_tool_prefix}gcc; ac_word=$2
3121{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3122$as_echo_n "checking for $ac_word... " >&6; }
d0ac1c44 3123if ${ac_cv_prog_CC+:} false; then :
81ecdfbb 3124 $as_echo_n "(cached) " >&6
c906108c
SS
3125else
3126 if test -n "$CC"; then
3127 ac_cv_prog_CC="$CC" # Let the user override the test.
3128else
bec39cab
AC
3129as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3130for as_dir in $PATH
3131do
3132 IFS=$as_save_IFS
3133 test -z "$as_dir" && as_dir=.
81ecdfbb 3134 for ac_exec_ext in '' $ac_executable_extensions; do
d0ac1c44 3135 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
81ecdfbb
RW
3136 ac_cv_prog_CC="${ac_tool_prefix}gcc"
3137 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
bec39cab
AC
3138 break 2
3139 fi
3140done
81ecdfbb
RW
3141 done
3142IFS=$as_save_IFS
bec39cab 3143
c906108c
SS
3144fi
3145fi
bec39cab 3146CC=$ac_cv_prog_CC
c906108c 3147if test -n "$CC"; then
81ecdfbb
RW
3148 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3149$as_echo "$CC" >&6; }
c906108c 3150else
81ecdfbb
RW
3151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3152$as_echo "no" >&6; }
c906108c
SS
3153fi
3154
81ecdfbb 3155
b4e70030
JB
3156fi
3157if test -z "$ac_cv_prog_CC"; then
3158 ac_ct_CC=$CC
81ecdfbb
RW
3159 # Extract the first word of "gcc", so it can be a program name with args.
3160set dummy gcc; ac_word=$2
3161{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3162$as_echo_n "checking for $ac_word... " >&6; }
d0ac1c44 3163if ${ac_cv_prog_ac_ct_CC+:} false; then :
81ecdfbb 3164 $as_echo_n "(cached) " >&6
b4e70030
JB
3165else
3166 if test -n "$ac_ct_CC"; then
3167 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3168else
3169as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3170for as_dir in $PATH
3171do
3172 IFS=$as_save_IFS
3173 test -z "$as_dir" && as_dir=.
81ecdfbb 3174 for ac_exec_ext in '' $ac_executable_extensions; do
d0ac1c44 3175 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
81ecdfbb
RW
3176 ac_cv_prog_ac_ct_CC="gcc"
3177 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
b4e70030 3178 break 2
4e8d927d 3179 fi
b4e70030 3180done
81ecdfbb
RW
3181 done
3182IFS=$as_save_IFS
b4e70030
JB
3183
3184fi
3185fi
3186ac_ct_CC=$ac_cv_prog_ac_ct_CC
3187if test -n "$ac_ct_CC"; then
81ecdfbb
RW
3188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3189$as_echo "$ac_ct_CC" >&6; }
b4e70030 3190else
81ecdfbb
RW
3191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3192$as_echo "no" >&6; }
b4e70030
JB
3193fi
3194
81ecdfbb
RW
3195 if test "x$ac_ct_CC" = x; then
3196 CC=""
3197 else
3198 case $cross_compiling:$ac_tool_warned in
3199yes:)
3200{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3201$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3202ac_tool_warned=yes ;;
3203esac
3204 CC=$ac_ct_CC
3205 fi
b4e70030
JB
3206else
3207 CC="$ac_cv_prog_CC"
3208fi
3209
c906108c 3210if test -z "$CC"; then
81ecdfbb
RW
3211 if test -n "$ac_tool_prefix"; then
3212 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
3213set dummy ${ac_tool_prefix}cc; ac_word=$2
3214{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3215$as_echo_n "checking for $ac_word... " >&6; }
d0ac1c44 3216if ${ac_cv_prog_CC+:} false; then :
81ecdfbb 3217 $as_echo_n "(cached) " >&6
c906108c
SS
3218else
3219 if test -n "$CC"; then
3220 ac_cv_prog_CC="$CC" # Let the user override the test.
3221else
bec39cab
AC
3222as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3223for as_dir in $PATH
3224do
3225 IFS=$as_save_IFS
3226 test -z "$as_dir" && as_dir=.
81ecdfbb 3227 for ac_exec_ext in '' $ac_executable_extensions; do
d0ac1c44 3228 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
81ecdfbb
RW
3229 ac_cv_prog_CC="${ac_tool_prefix}cc"
3230 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
bec39cab
AC
3231 break 2
3232 fi
3233done
81ecdfbb
RW
3234 done
3235IFS=$as_save_IFS
3236
3237fi
3238fi
3239CC=$ac_cv_prog_CC
3240if test -n "$CC"; then
3241 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3242$as_echo "$CC" >&6; }
3243else
3244 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3245$as_echo "no" >&6; }
3246fi
3247
3248
3249 fi
3250fi
3251if test -z "$CC"; then
3252 # Extract the first word of "cc", so it can be a program name with args.
3253set dummy cc; ac_word=$2
3254{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3255$as_echo_n "checking for $ac_word... " >&6; }
d0ac1c44 3256if ${ac_cv_prog_CC+:} false; then :
81ecdfbb
RW
3257 $as_echo_n "(cached) " >&6
3258else
3259 if test -n "$CC"; then
3260 ac_cv_prog_CC="$CC" # Let the user override the test.
3261else
3262 ac_prog_rejected=no
3263as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3264for as_dir in $PATH
3265do
3266 IFS=$as_save_IFS
3267 test -z "$as_dir" && as_dir=.
3268 for ac_exec_ext in '' $ac_executable_extensions; do
d0ac1c44 3269 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
81ecdfbb
RW
3270 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
3271 ac_prog_rejected=yes
3272 continue
3273 fi
3274 ac_cv_prog_CC="cc"
3275 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3276 break 2
3277 fi
3278done
3279 done
3280IFS=$as_save_IFS
bec39cab 3281
c906108c
SS
3282if test $ac_prog_rejected = yes; then
3283 # We found a bogon in the path, so make sure we never use it.
3284 set dummy $ac_cv_prog_CC
3285 shift
bec39cab 3286 if test $# != 0; then
c906108c
SS
3287 # We chose a different compiler from the bogus one.
3288 # However, it has the same basename, so the bogon will be chosen
3289 # first if we set CC to just the basename; use the full file name.
3290 shift
bec39cab 3291 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
c906108c
SS
3292 fi
3293fi
3294fi
3295fi
bec39cab 3296CC=$ac_cv_prog_CC
c906108c 3297if test -n "$CC"; then
81ecdfbb
RW
3298 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3299$as_echo "$CC" >&6; }
c906108c 3300else
81ecdfbb
RW
3301 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3302$as_echo "no" >&6; }
c906108c
SS
3303fi
3304
81ecdfbb 3305
bec39cab
AC
3306fi
3307if test -z "$CC"; then
3308 if test -n "$ac_tool_prefix"; then
81ecdfbb 3309 for ac_prog in cl.exe
bec39cab
AC
3310 do
3311 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3312set dummy $ac_tool_prefix$ac_prog; ac_word=$2
81ecdfbb
RW
3313{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3314$as_echo_n "checking for $ac_word... " >&6; }
d0ac1c44 3315if ${ac_cv_prog_CC+:} false; then :
81ecdfbb 3316 $as_echo_n "(cached) " >&6
c906108c
SS
3317else
3318 if test -n "$CC"; then
3319 ac_cv_prog_CC="$CC" # Let the user override the test.
3320else
bec39cab
AC
3321as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3322for as_dir in $PATH
3323do
3324 IFS=$as_save_IFS
3325 test -z "$as_dir" && as_dir=.
81ecdfbb 3326 for ac_exec_ext in '' $ac_executable_extensions; do
d0ac1c44 3327 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
bec39cab 3328 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
81ecdfbb 3329 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
bec39cab
AC
3330 break 2
3331 fi
3332done
81ecdfbb
RW
3333 done
3334IFS=$as_save_IFS
bec39cab 3335
c906108c
SS
3336fi
3337fi
bec39cab 3338CC=$ac_cv_prog_CC
c906108c 3339if test -n "$CC"; then
81ecdfbb
RW
3340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3341$as_echo "$CC" >&6; }
c906108c 3342else
81ecdfbb
RW
3343 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3344$as_echo "no" >&6; }
c906108c 3345fi
bec39cab 3346
81ecdfbb 3347
bec39cab
AC
3348 test -n "$CC" && break
3349 done
3350fi
3351if test -z "$CC"; then
3352 ac_ct_CC=$CC
81ecdfbb 3353 for ac_prog in cl.exe
bec39cab
AC
3354do
3355 # Extract the first word of "$ac_prog", so it can be a program name with args.
3356set dummy $ac_prog; ac_word=$2
81ecdfbb
RW
3357{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3358$as_echo_n "checking for $ac_word... " >&6; }
d0ac1c44 3359if ${ac_cv_prog_ac_ct_CC+:} false; then :
81ecdfbb 3360 $as_echo_n "(cached) " >&6
bec39cab
AC
3361else
3362 if test -n "$ac_ct_CC"; then
3363 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3364else
3365as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3366for as_dir in $PATH
3367do
3368 IFS=$as_save_IFS
3369 test -z "$as_dir" && as_dir=.
81ecdfbb 3370 for ac_exec_ext in '' $ac_executable_extensions; do
d0ac1c44 3371 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
bec39cab 3372 ac_cv_prog_ac_ct_CC="$ac_prog"
81ecdfbb 3373 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
bec39cab 3374 break 2
c906108c 3375 fi
bec39cab 3376done
81ecdfbb
RW
3377 done
3378IFS=$as_save_IFS
bec39cab
AC
3379
3380fi
3381fi
3382ac_ct_CC=$ac_cv_prog_ac_ct_CC
3383if test -n "$ac_ct_CC"; then
81ecdfbb
RW
3384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3385$as_echo "$ac_ct_CC" >&6; }
bec39cab 3386else
81ecdfbb
RW
3387 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3388$as_echo "no" >&6; }
c906108c
SS
3389fi
3390
81ecdfbb 3391
bec39cab
AC
3392 test -n "$ac_ct_CC" && break
3393done
c906108c 3394
81ecdfbb
RW
3395 if test "x$ac_ct_CC" = x; then
3396 CC=""
3397 else
3398 case $cross_compiling:$ac_tool_warned in
3399yes:)
3400{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3401$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3402ac_tool_warned=yes ;;
3403esac
3404 CC=$ac_ct_CC
3405 fi
bec39cab
AC
3406fi
3407
3408fi
3409
3410
81ecdfbb
RW
3411test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3412$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
d0ac1c44
SM
3413as_fn_error $? "no acceptable C compiler found in \$PATH
3414See \`config.log' for more details" "$LINENO" 5; }
bec39cab
AC
3415
3416# Provide some information about the compiler.
81ecdfbb
RW
3417$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
3418set X $ac_compile
3419ac_compiler=$2
3420for ac_option in --version -v -V -qversion; do
3421 { { ac_try="$ac_compiler $ac_option >&5"
3422case "(($ac_try" in
3423 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3424 *) ac_try_echo=$ac_try;;
3425esac
3426eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3427$as_echo "$ac_try_echo"; } >&5
3428 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
bec39cab 3429 ac_status=$?
81ecdfbb
RW
3430 if test -s conftest.err; then
3431 sed '10a\
3432... rest of stderr output deleted ...
3433 10q' conftest.err >conftest.er1
3434 cat conftest.er1 >&5
81ecdfbb 3435 fi
d0ac1c44 3436 rm -f conftest.er1 conftest.err
81ecdfbb
RW
3437 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3438 test $ac_status = 0; }
3439done
bec39cab 3440
81ecdfbb 3441cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab
AC
3442/* end confdefs.h. */
3443
3444int
3445main ()
3446{
3447
3448 ;
3449 return 0;
3450}
3451_ACEOF
3452ac_clean_files_save=$ac_clean_files
d0ac1c44 3453ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
bec39cab
AC
3454# Try to create an executable without -o first, disregard a.out.
3455# It will help us diagnose broken compilers, and finding out an intuition
3456# of exeext.
d0ac1c44
SM
3457{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
3458$as_echo_n "checking whether the C compiler works... " >&6; }
81ecdfbb
RW
3459ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3460
3461# The possible output files:
3462ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3463
3464ac_rmfiles=
3465for ac_file in $ac_files
3466do
3467 case $ac_file in
3468 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3469 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3470 esac
3471done
3472rm -f $ac_rmfiles
3473
3474if { { ac_try="$ac_link_default"
3475case "(($ac_try" in
3476 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3477 *) ac_try_echo=$ac_try;;
3478esac
3479eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3480$as_echo "$ac_try_echo"; } >&5
3481 (eval "$ac_link_default") 2>&5
3482 ac_status=$?
3483 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3484 test $ac_status = 0; }; then :
3485 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3486# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3487# in a Makefile. We should not override ac_cv_exeext if it was cached,
3488# so that the user can short-circuit this test for compilers unknown to
3489# Autoconf.
3490for ac_file in $ac_files ''
bec39cab
AC
3491do
3492 test -f "$ac_file" || continue
3493 case $ac_file in
81ecdfbb 3494 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
b4e70030
JB
3495 ;;
3496 [ab].out )
3497 # We found the default executable, but exeext='' is most
3498 # certainly right.
3499 break;;
3500 *.* )
81ecdfbb
RW
3501 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3502 then :; else
3503 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3504 fi
3505 # We set ac_cv_exeext here because the later test for it is not
3506 # safe: cross compilers may not add the suffix if given an `-o'
3507 # argument, so we may need to know it at that point already.
3508 # Even if this section looks crufty: it has the advantage of
3509 # actually working.
b4e70030
JB
3510 break;;
3511 * )
3512 break;;
bec39cab
AC
3513 esac
3514done
81ecdfbb
RW
3515test "$ac_cv_exeext" = no && ac_cv_exeext=
3516
bec39cab 3517else
81ecdfbb
RW
3518 ac_file=''
3519fi
81ecdfbb 3520if test -z "$ac_file"; then :
d0ac1c44
SM
3521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3522$as_echo "no" >&6; }
3523$as_echo "$as_me: failed program was:" >&5
bec39cab
AC
3524sed 's/^/| /' conftest.$ac_ext >&5
3525
81ecdfbb
RW
3526{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3527$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
d0ac1c44
SM
3528as_fn_error 77 "C compiler cannot create executables
3529See \`config.log' for more details" "$LINENO" 5; }
3530else
3531 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3532$as_echo "yes" >&6; }
bec39cab 3533fi
d0ac1c44
SM
3534{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
3535$as_echo_n "checking for C compiler default output file name... " >&6; }
3536{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
3537$as_echo "$ac_file" >&6; }
b4e70030 3538ac_exeext=$ac_cv_exeext
b4e70030 3539
d0ac1c44 3540rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
b4e70030 3541ac_clean_files=$ac_clean_files_save
81ecdfbb
RW
3542{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
3543$as_echo_n "checking for suffix of executables... " >&6; }
3544if { { ac_try="$ac_link"
3545case "(($ac_try" in
3546 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3547 *) ac_try_echo=$ac_try;;
3548esac
3549eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3550$as_echo "$ac_try_echo"; } >&5
3551 (eval "$ac_link") 2>&5
bec39cab 3552 ac_status=$?
81ecdfbb
RW
3553 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3554 test $ac_status = 0; }; then :
b4e70030
JB
3555 # If both `conftest.exe' and `conftest' are `present' (well, observable)
3556# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
3557# work properly (i.e., refer to `conftest.exe'), while it won't with
3558# `rm'.
3559for ac_file in conftest.exe conftest conftest.*; do
3560 test -f "$ac_file" || continue
3561 case $ac_file in
81ecdfbb 3562 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
b4e70030 3563 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
b4e70030
JB
3564 break;;
3565 * ) break;;
3566 esac
3567done
c906108c 3568else
81ecdfbb
RW
3569 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3570$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
d0ac1c44
SM
3571as_fn_error $? "cannot compute suffix of executables: cannot compile and link
3572See \`config.log' for more details" "$LINENO" 5; }
c906108c 3573fi
d0ac1c44 3574rm -f conftest conftest$ac_cv_exeext
81ecdfbb
RW
3575{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
3576$as_echo "$ac_cv_exeext" >&6; }
c906108c 3577
b4e70030 3578rm -f conftest.$ac_ext
bec39cab
AC
3579EXEEXT=$ac_cv_exeext
3580ac_exeext=$EXEEXT
d0ac1c44
SM
3581cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3582/* end confdefs.h. */
3583#include <stdio.h>
3584int
3585main ()
3586{
3587FILE *f = fopen ("conftest.out", "w");
3588 return ferror (f) || fclose (f) != 0;
3589
3590 ;
3591 return 0;
3592}
3593_ACEOF
3594ac_clean_files="$ac_clean_files conftest.out"
3595# Check that the compiler produces executables we can run. If not, either
3596# the compiler is broken, or we cross compile.
3597{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
3598$as_echo_n "checking whether we are cross compiling... " >&6; }
3599if test "$cross_compiling" != yes; then
3600 { { ac_try="$ac_link"
3601case "(($ac_try" in
3602 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3603 *) ac_try_echo=$ac_try;;
3604esac
3605eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3606$as_echo "$ac_try_echo"; } >&5
3607 (eval "$ac_link") 2>&5
3608 ac_status=$?
3609 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3610 test $ac_status = 0; }
3611 if { ac_try='./conftest$ac_cv_exeext'
3612 { { case "(($ac_try" in
3613 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3614 *) ac_try_echo=$ac_try;;
3615esac
3616eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3617$as_echo "$ac_try_echo"; } >&5
3618 (eval "$ac_try") 2>&5
3619 ac_status=$?
3620 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3621 test $ac_status = 0; }; }; then
3622 cross_compiling=no
3623 else
3624 if test "$cross_compiling" = maybe; then
3625 cross_compiling=yes
3626 else
3627 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3628$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3629as_fn_error $? "cannot run C compiled programs.
3630If you meant to cross compile, use \`--host'.
3631See \`config.log' for more details" "$LINENO" 5; }
3632 fi
3633 fi
3634fi
3635{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
3636$as_echo "$cross_compiling" >&6; }
3637
3638rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
3639ac_clean_files=$ac_clean_files_save
81ecdfbb
RW
3640{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
3641$as_echo_n "checking for suffix of object files... " >&6; }
d0ac1c44 3642if ${ac_cv_objext+:} false; then :
81ecdfbb 3643 $as_echo_n "(cached) " >&6
bec39cab 3644else
81ecdfbb 3645 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
b4e70030
JB
3646/* end confdefs.h. */
3647
3648int
3649main ()
3650{
3651
3652 ;
3653 return 0;
3654}
3655_ACEOF
3656rm -f conftest.o conftest.obj
81ecdfbb
RW
3657if { { ac_try="$ac_compile"
3658case "(($ac_try" in
3659 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3660 *) ac_try_echo=$ac_try;;
3661esac
3662eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3663$as_echo "$ac_try_echo"; } >&5
3664 (eval "$ac_compile") 2>&5
3665 ac_status=$?
3666 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3667 test $ac_status = 0; }; then :
3668 for ac_file in conftest.o conftest.obj conftest.*; do
3669 test -f "$ac_file" || continue;
bec39cab 3670 case $ac_file in
81ecdfbb 3671 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
bec39cab
AC
3672 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3673 break;;
3674 esac
3675done
c906108c 3676else
81ecdfbb 3677 $as_echo "$as_me: failed program was:" >&5
bec39cab
AC
3678sed 's/^/| /' conftest.$ac_ext >&5
3679
81ecdfbb
RW
3680{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3681$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
d0ac1c44
SM
3682as_fn_error $? "cannot compute suffix of object files: cannot compile
3683See \`config.log' for more details" "$LINENO" 5; }
c906108c 3684fi
b4e70030 3685rm -f conftest.$ac_cv_objext conftest.$ac_ext
bec39cab 3686fi
81ecdfbb
RW
3687{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
3688$as_echo "$ac_cv_objext" >&6; }
bec39cab
AC
3689OBJEXT=$ac_cv_objext
3690ac_objext=$OBJEXT
81ecdfbb
RW
3691{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
3692$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
d0ac1c44 3693if ${ac_cv_c_compiler_gnu+:} false; then :
81ecdfbb 3694 $as_echo_n "(cached) " >&6
c906108c 3695else
81ecdfbb 3696 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab
AC
3697/* end confdefs.h. */
3698
3699int
3700main ()
3701{
3702#ifndef __GNUC__
3703 choke me
3704#endif
3705
3706 ;
3707 return 0;
3708}
3709_ACEOF
81ecdfbb 3710if ac_fn_c_try_compile "$LINENO"; then :
bec39cab
AC
3711 ac_compiler_gnu=yes
3712else
81ecdfbb 3713 ac_compiler_gnu=no
bec39cab 3714fi
81ecdfbb 3715rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
bec39cab
AC
3716ac_cv_c_compiler_gnu=$ac_compiler_gnu
3717
3718fi
81ecdfbb
RW
3719{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
3720$as_echo "$ac_cv_c_compiler_gnu" >&6; }
3721if test $ac_compiler_gnu = yes; then
3722 GCC=yes
3723else
3724 GCC=
3725fi
bec39cab
AC
3726ac_test_CFLAGS=${CFLAGS+set}
3727ac_save_CFLAGS=$CFLAGS
81ecdfbb
RW
3728{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
3729$as_echo_n "checking whether $CC accepts -g... " >&6; }
d0ac1c44 3730if ${ac_cv_prog_cc_g+:} false; then :
81ecdfbb 3731 $as_echo_n "(cached) " >&6
bec39cab 3732else
81ecdfbb
RW
3733 ac_save_c_werror_flag=$ac_c_werror_flag
3734 ac_c_werror_flag=yes
3735 ac_cv_prog_cc_g=no
3736 CFLAGS="-g"
3737 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab
AC
3738/* end confdefs.h. */
3739
3740int
3741main ()
3742{
3743
3744 ;
3745 return 0;
3746}
3747_ACEOF
81ecdfbb 3748if ac_fn_c_try_compile "$LINENO"; then :
c906108c
SS
3749 ac_cv_prog_cc_g=yes
3750else
81ecdfbb
RW
3751 CFLAGS=""
3752 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3753/* end confdefs.h. */
3754
3755int
3756main ()
3757{
3758
3759 ;
3760 return 0;
3761}
3762_ACEOF
3763if ac_fn_c_try_compile "$LINENO"; then :
3764
3765else
3766 ac_c_werror_flag=$ac_save_c_werror_flag
3767 CFLAGS="-g"
3768 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3769/* end confdefs.h. */
3770
3771int
3772main ()
3773{
c906108c 3774
81ecdfbb
RW
3775 ;
3776 return 0;
3777}
3778_ACEOF
3779if ac_fn_c_try_compile "$LINENO"; then :
3780 ac_cv_prog_cc_g=yes
3781fi
3782rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3783fi
3784rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4e8d927d 3785fi
81ecdfbb
RW
3786rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3787 ac_c_werror_flag=$ac_save_c_werror_flag
bec39cab 3788fi
81ecdfbb
RW
3789{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
3790$as_echo "$ac_cv_prog_cc_g" >&6; }
c906108c 3791if test "$ac_test_CFLAGS" = set; then
bec39cab 3792 CFLAGS=$ac_save_CFLAGS
c906108c
SS
3793elif test $ac_cv_prog_cc_g = yes; then
3794 if test "$GCC" = yes; then
3795 CFLAGS="-g -O2"
3796 else
3797 CFLAGS="-g"
3798 fi
3799else
3800 if test "$GCC" = yes; then
3801 CFLAGS="-O2"
3802 else
3803 CFLAGS=
3804 fi
3805fi
81ecdfbb
RW
3806{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
3807$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
d0ac1c44 3808if ${ac_cv_prog_cc_c89+:} false; then :
81ecdfbb 3809 $as_echo_n "(cached) " >&6
bec39cab 3810else
81ecdfbb 3811 ac_cv_prog_cc_c89=no
bec39cab 3812ac_save_CC=$CC
81ecdfbb 3813cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 3814/* end confdefs.h. */
c906108c
SS
3815#include <stdarg.h>
3816#include <stdio.h>
d0ac1c44 3817struct stat;
c906108c
SS
3818/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
3819struct buf { int x; };
3820FILE * (*rcsopen) (struct buf *, struct stat *, int);
3821static char *e (p, i)
3822 char **p;
3823 int i;
3824{
3825 return p[i];
3826}
3827static char *f (char * (*g) (char **, int), char **p, ...)
3828{
3829 char *s;
3830 va_list v;
3831 va_start (v,p);
3832 s = g (p, va_arg (v,int));
3833 va_end (v);
3834 return s;
3835}
bec39cab
AC
3836
3837/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
3838 function prototypes and stuff, but not '\xHH' hex character constants.
3839 These don't provoke an error unfortunately, instead are silently treated
81ecdfbb 3840 as 'x'. The following induces an error, until -std is added to get
bec39cab
AC
3841 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
3842 array size at least. It's necessary to write '\x00'==0 to get something
81ecdfbb 3843 that's true only with -std. */
bec39cab
AC
3844int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3845
81ecdfbb
RW
3846/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3847 inside strings and character constants. */
3848#define FOO(x) 'x'
3849int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3850
c906108c
SS
3851int test (int i, double x);
3852struct s1 {int (*f) (int a);};
3853struct s2 {int (*f) (double a);};
3854int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3855int argc;
3856char **argv;
bec39cab
AC
3857int
3858main ()
3859{
c906108c 3860return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
bec39cab
AC
3861 ;
3862 return 0;
3863}
3864_ACEOF
81ecdfbb
RW
3865for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3866 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
bec39cab
AC
3867do
3868 CC="$ac_save_CC $ac_arg"
81ecdfbb
RW
3869 if ac_fn_c_try_compile "$LINENO"; then :
3870 ac_cv_prog_cc_c89=$ac_arg
c906108c 3871fi
81ecdfbb
RW
3872rm -f core conftest.err conftest.$ac_objext
3873 test "x$ac_cv_prog_cc_c89" != "xno" && break
c906108c 3874done
81ecdfbb 3875rm -f conftest.$ac_ext
bec39cab 3876CC=$ac_save_CC
c906108c
SS
3877
3878fi
81ecdfbb
RW
3879# AC_CACHE_VAL
3880case "x$ac_cv_prog_cc_c89" in
3881 x)
3882 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
3883$as_echo "none needed" >&6; } ;;
3884 xno)
3885 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
3886$as_echo "unsupported" >&6; } ;;
bec39cab 3887 *)
81ecdfbb
RW
3888 CC="$CC $ac_cv_prog_cc_c89"
3889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
3890$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
c906108c 3891esac
81ecdfbb 3892if test "x$ac_cv_prog_cc_c89" != xno; then :
c906108c 3893
b4e70030
JB
3894fi
3895
bec39cab
AC
3896ac_ext=c
3897ac_cpp='$CPP $CPPFLAGS'
3898ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3899ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3900ac_compiler_gnu=$ac_cv_c_compiler_gnu
c906108c 3901
3bc3d82a
PA
3902ac_ext=cpp
3903ac_cpp='$CXXCPP $CPPFLAGS'
3904ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3905ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3906ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
3907if test -z "$CXX"; then
3908 if test -n "$CCC"; then
3909 CXX=$CCC
3910 else
3911 if test -n "$ac_tool_prefix"; then
3912 for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
3913 do
3914 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3915set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3916{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3917$as_echo_n "checking for $ac_word... " >&6; }
d0ac1c44 3918if ${ac_cv_prog_CXX+:} false; then :
3bc3d82a
PA
3919 $as_echo_n "(cached) " >&6
3920else
3921 if test -n "$CXX"; then
3922 ac_cv_prog_CXX="$CXX" # Let the user override the test.
3923else
3924as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3925for as_dir in $PATH
3926do
3927 IFS=$as_save_IFS
3928 test -z "$as_dir" && as_dir=.
3929 for ac_exec_ext in '' $ac_executable_extensions; do
d0ac1c44 3930 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3bc3d82a
PA
3931 ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
3932 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3933 break 2
3934 fi
3935done
3936 done
3937IFS=$as_save_IFS
3938
3939fi
3940fi
3941CXX=$ac_cv_prog_CXX
3942if test -n "$CXX"; then
3943 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
3944$as_echo "$CXX" >&6; }
3945else
3946 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3947$as_echo "no" >&6; }
3948fi
3949
3950
3951 test -n "$CXX" && break
3952 done
3953fi
3954if test -z "$CXX"; then
3955 ac_ct_CXX=$CXX
3956 for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
3957do
3958 # Extract the first word of "$ac_prog", so it can be a program name with args.
3959set dummy $ac_prog; ac_word=$2
3960{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3961$as_echo_n "checking for $ac_word... " >&6; }
d0ac1c44 3962if ${ac_cv_prog_ac_ct_CXX+:} false; then :
3bc3d82a
PA
3963 $as_echo_n "(cached) " >&6
3964else
3965 if test -n "$ac_ct_CXX"; then
3966 ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
3967else
3968as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3969for as_dir in $PATH
3970do
3971 IFS=$as_save_IFS
3972 test -z "$as_dir" && as_dir=.
3973 for ac_exec_ext in '' $ac_executable_extensions; do
d0ac1c44 3974 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3bc3d82a
PA
3975 ac_cv_prog_ac_ct_CXX="$ac_prog"
3976 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3977 break 2
3978 fi
3979done
3980 done
3981IFS=$as_save_IFS
3982
3983fi
3984fi
3985ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
3986if test -n "$ac_ct_CXX"; then
3987 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
3988$as_echo "$ac_ct_CXX" >&6; }
3989else
3990 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3991$as_echo "no" >&6; }
3992fi
3993
3994
3995 test -n "$ac_ct_CXX" && break
3996done
3997
3998 if test "x$ac_ct_CXX" = x; then
3999 CXX="g++"
4000 else
4001 case $cross_compiling:$ac_tool_warned in
4002yes:)
4003{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4004$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4005ac_tool_warned=yes ;;
4006esac
4007 CXX=$ac_ct_CXX
4008 fi
4009fi
4010
4011 fi
4012fi
4013# Provide some information about the compiler.
4014$as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
4015set X $ac_compile
4016ac_compiler=$2
4017for ac_option in --version -v -V -qversion; do
4018 { { ac_try="$ac_compiler $ac_option >&5"
4019case "(($ac_try" in
4020 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4021 *) ac_try_echo=$ac_try;;
4022esac
4023eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4024$as_echo "$ac_try_echo"; } >&5
4025 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
4026 ac_status=$?
4027 if test -s conftest.err; then
4028 sed '10a\
4029... rest of stderr output deleted ...
4030 10q' conftest.err >conftest.er1
4031 cat conftest.er1 >&5
3bc3d82a 4032 fi
d0ac1c44 4033 rm -f conftest.er1 conftest.err
3bc3d82a
PA
4034 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4035 test $ac_status = 0; }
4036done
4037
4038{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5
4039$as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; }
d0ac1c44 4040if ${ac_cv_cxx_compiler_gnu+:} false; then :
3bc3d82a
PA
4041 $as_echo_n "(cached) " >&6
4042else
4043 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4044/* end confdefs.h. */
4045
4046int
4047main ()
4048{
4049#ifndef __GNUC__
4050 choke me
4051#endif
4052
4053 ;
4054 return 0;
4055}
4056_ACEOF
4057if ac_fn_cxx_try_compile "$LINENO"; then :
4058 ac_compiler_gnu=yes
4059else
4060 ac_compiler_gnu=no
4061fi
4062rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4063ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
4064
4065fi
4066{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
4067$as_echo "$ac_cv_cxx_compiler_gnu" >&6; }
4068if test $ac_compiler_gnu = yes; then
4069 GXX=yes
4070else
4071 GXX=
4072fi
4073ac_test_CXXFLAGS=${CXXFLAGS+set}
4074ac_save_CXXFLAGS=$CXXFLAGS
4075{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
4076$as_echo_n "checking whether $CXX accepts -g... " >&6; }
d0ac1c44 4077if ${ac_cv_prog_cxx_g+:} false; then :
3bc3d82a
PA
4078 $as_echo_n "(cached) " >&6
4079else
4080 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
4081 ac_cxx_werror_flag=yes
4082 ac_cv_prog_cxx_g=no
4083 CXXFLAGS="-g"
4084 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4085/* end confdefs.h. */
4086
4087int
4088main ()
4089{
4090
4091 ;
4092 return 0;
4093}
4094_ACEOF
4095if ac_fn_cxx_try_compile "$LINENO"; then :
4096 ac_cv_prog_cxx_g=yes
4097else
4098 CXXFLAGS=""
4099 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4100/* end confdefs.h. */
4101
4102int
4103main ()
4104{
4105
4106 ;
4107 return 0;
4108}
4109_ACEOF
4110if ac_fn_cxx_try_compile "$LINENO"; then :
4111
4112else
4113 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
4114 CXXFLAGS="-g"
4115 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4116/* end confdefs.h. */
4117
4118int
4119main ()
4120{
4121
4122 ;
4123 return 0;
4124}
4125_ACEOF
4126if ac_fn_cxx_try_compile "$LINENO"; then :
4127 ac_cv_prog_cxx_g=yes
4128fi
4129rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4130fi
4131rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4132fi
4133rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4134 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
4135fi
4136{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
4137$as_echo "$ac_cv_prog_cxx_g" >&6; }
4138if test "$ac_test_CXXFLAGS" = set; then
4139 CXXFLAGS=$ac_save_CXXFLAGS
4140elif test $ac_cv_prog_cxx_g = yes; then
4141 if test "$GXX" = yes; then
4142 CXXFLAGS="-g -O2"
4143 else
4144 CXXFLAGS="-g"
4145 fi
4146else
4147 if test "$GXX" = yes; then
4148 CXXFLAGS="-O2"
4149 else
4150 CXXFLAGS=
4151 fi
4152fi
4153ac_ext=c
4154ac_cpp='$CPP $CPPFLAGS'
4155ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4156ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4157ac_compiler_gnu=$ac_cv_c_compiler_gnu
4158
4159
60ca704f 4160
bec39cab
AC
4161ac_ext=c
4162ac_cpp='$CPP $CPPFLAGS'
4163ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4164ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4165ac_compiler_gnu=$ac_cv_c_compiler_gnu
81ecdfbb
RW
4166{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
4167$as_echo_n "checking how to run the C preprocessor... " >&6; }
bec39cab
AC
4168# On Suns, sometimes $CPP names a directory.
4169if test -n "$CPP" && test -d "$CPP"; then
4170 CPP=
8bb2c122 4171fi
bec39cab 4172if test -z "$CPP"; then
d0ac1c44 4173 if ${ac_cv_prog_CPP+:} false; then :
81ecdfbb 4174 $as_echo_n "(cached) " >&6
bec39cab
AC
4175else
4176 # Double quotes because CPP needs to be expanded
4177 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
4178 do
4179 ac_preproc_ok=false
4180for ac_c_preproc_warn_flag in '' yes
4181do
4182 # Use a header file that comes with gcc, so configuring glibc
4183 # with a fresh cross-compiler works.
4184 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4185 # <limits.h> exists even on freestanding compilers.
4186 # On the NeXT, cc -E runs the code through the compiler's parser,
4187 # not just through cpp. "Syntax error" is here to catch this case.
81ecdfbb 4188 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab
AC
4189/* end confdefs.h. */
4190#ifdef __STDC__
4191# include <limits.h>
4192#else
4193# include <assert.h>
4194#endif
4195 Syntax error
4196_ACEOF
81ecdfbb 4197if ac_fn_c_try_cpp "$LINENO"; then :
bec39cab 4198
81ecdfbb 4199else
bec39cab
AC
4200 # Broken: fails on valid input.
4201continue
4202fi
d0ac1c44 4203rm -f conftest.err conftest.i conftest.$ac_ext
bec39cab 4204
81ecdfbb 4205 # OK, works on sane cases. Now check whether nonexistent headers
bec39cab 4206 # can be detected and how.
81ecdfbb 4207 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab
AC
4208/* end confdefs.h. */
4209#include <ac_nonexistent.h>
4210_ACEOF
81ecdfbb 4211if ac_fn_c_try_cpp "$LINENO"; then :
bec39cab
AC
4212 # Broken: success on invalid input.
4213continue
8bb2c122 4214else
bec39cab
AC
4215 # Passes both tests.
4216ac_preproc_ok=:
4217break
8bb2c122 4218fi
d0ac1c44 4219rm -f conftest.err conftest.i conftest.$ac_ext
8bb2c122 4220
bec39cab
AC
4221done
4222# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
d0ac1c44 4223rm -f conftest.i conftest.err conftest.$ac_ext
81ecdfbb 4224if $ac_preproc_ok; then :
bec39cab
AC
4225 break
4226fi
8bb2c122 4227
bec39cab
AC
4228 done
4229 ac_cv_prog_CPP=$CPP
ddc9cd0f 4230
c906108c 4231fi
bec39cab
AC
4232 CPP=$ac_cv_prog_CPP
4233else
4234 ac_cv_prog_CPP=$CPP
c906108c 4235fi
81ecdfbb
RW
4236{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
4237$as_echo "$CPP" >&6; }
bec39cab
AC
4238ac_preproc_ok=false
4239for ac_c_preproc_warn_flag in '' yes
4240do
4241 # Use a header file that comes with gcc, so configuring glibc
4242 # with a fresh cross-compiler works.
4243 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4244 # <limits.h> exists even on freestanding compilers.
4245 # On the NeXT, cc -E runs the code through the compiler's parser,
4246 # not just through cpp. "Syntax error" is here to catch this case.
81ecdfbb 4247 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab
AC
4248/* end confdefs.h. */
4249#ifdef __STDC__
4250# include <limits.h>
4251#else
4252# include <assert.h>
4253#endif
4254 Syntax error
4255_ACEOF
81ecdfbb 4256if ac_fn_c_try_cpp "$LINENO"; then :
bec39cab 4257
81ecdfbb 4258else
bec39cab
AC
4259 # Broken: fails on valid input.
4260continue
4261fi
d0ac1c44 4262rm -f conftest.err conftest.i conftest.$ac_ext
bec39cab 4263
81ecdfbb 4264 # OK, works on sane cases. Now check whether nonexistent headers
bec39cab 4265 # can be detected and how.
81ecdfbb 4266 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab
AC
4267/* end confdefs.h. */
4268#include <ac_nonexistent.h>
4269_ACEOF
81ecdfbb 4270if ac_fn_c_try_cpp "$LINENO"; then :
bec39cab
AC
4271 # Broken: success on invalid input.
4272continue
c906108c 4273else
bec39cab
AC
4274 # Passes both tests.
4275ac_preproc_ok=:
4276break
c906108c 4277fi
d0ac1c44 4278rm -f conftest.err conftest.i conftest.$ac_ext
c906108c 4279
bec39cab
AC
4280done
4281# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
d0ac1c44 4282rm -f conftest.i conftest.err conftest.$ac_ext
81ecdfbb
RW
4283if $ac_preproc_ok; then :
4284
c906108c 4285else
81ecdfbb
RW
4286 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4287$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
d0ac1c44
SM
4288as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
4289See \`config.log' for more details" "$LINENO" 5; }
c906108c 4290fi
c906108c 4291
bec39cab
AC
4292ac_ext=c
4293ac_cpp='$CPP $CPPFLAGS'
4294ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4295ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4296ac_compiler_gnu=$ac_cv_c_compiler_gnu
4297
4298
81ecdfbb
RW
4299{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
4300$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
d0ac1c44 4301if ${ac_cv_path_GREP+:} false; then :
81ecdfbb 4302 $as_echo_n "(cached) " >&6
4e8d927d 4303else
81ecdfbb
RW
4304 if test -z "$GREP"; then
4305 ac_path_GREP_found=false
4306 # Loop through the user's path and test for each of PROGNAME-LIST
4307 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4308for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4309do
4310 IFS=$as_save_IFS
4311 test -z "$as_dir" && as_dir=.
4312 for ac_prog in grep ggrep; do
4313 for ac_exec_ext in '' $ac_executable_extensions; do
4314 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
d0ac1c44 4315 as_fn_executable_p "$ac_path_GREP" || continue
81ecdfbb
RW
4316# Check for GNU ac_path_GREP and select it if it is found.
4317 # Check for GNU $ac_path_GREP
4318case `"$ac_path_GREP" --version 2>&1` in
4319*GNU*)
4320 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
4321*)
4322 ac_count=0
4323 $as_echo_n 0123456789 >"conftest.in"
4324 while :
4325 do
4326 cat "conftest.in" "conftest.in" >"conftest.tmp"
4327 mv "conftest.tmp" "conftest.in"
4328 cp "conftest.in" "conftest.nl"
4329 $as_echo 'GREP' >> "conftest.nl"
4330 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4331 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4332 as_fn_arith $ac_count + 1 && ac_count=$as_val
4333 if test $ac_count -gt ${ac_path_GREP_max-0}; then
4334 # Best one so far, save it but keep looking for a better one
4335 ac_cv_path_GREP="$ac_path_GREP"
4336 ac_path_GREP_max=$ac_count
bec39cab 4337 fi
81ecdfbb
RW
4338 # 10*(2^10) chars as input seems more than enough
4339 test $ac_count -gt 10 && break
4340 done
4341 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4342esac
bec39cab 4343
81ecdfbb
RW
4344 $ac_path_GREP_found && break 3
4345 done
4346 done
4347 done
4348IFS=$as_save_IFS
4349 if test -z "$ac_cv_path_GREP"; then
d0ac1c44 4350 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
81ecdfbb 4351 fi
c906108c 4352else
81ecdfbb 4353 ac_cv_path_GREP=$GREP
c906108c 4354fi
c906108c 4355
81ecdfbb
RW
4356fi
4357{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
4358$as_echo "$ac_cv_path_GREP" >&6; }
4359 GREP="$ac_cv_path_GREP"
c906108c 4360
c906108c 4361
81ecdfbb
RW
4362{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
4363$as_echo_n "checking for egrep... " >&6; }
d0ac1c44 4364if ${ac_cv_path_EGREP+:} false; then :
81ecdfbb 4365 $as_echo_n "(cached) " >&6
783e057b 4366else
81ecdfbb
RW
4367 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
4368 then ac_cv_path_EGREP="$GREP -E"
4369 else
4370 if test -z "$EGREP"; then
4371 ac_path_EGREP_found=false
4372 # Loop through the user's path and test for each of PROGNAME-LIST
4373 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4374for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
783e057b
DJ
4375do
4376 IFS=$as_save_IFS
4377 test -z "$as_dir" && as_dir=.
81ecdfbb
RW
4378 for ac_prog in egrep; do
4379 for ac_exec_ext in '' $ac_executable_extensions; do
4380 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
d0ac1c44 4381 as_fn_executable_p "$ac_path_EGREP" || continue
81ecdfbb
RW
4382# Check for GNU ac_path_EGREP and select it if it is found.
4383 # Check for GNU $ac_path_EGREP
4384case `"$ac_path_EGREP" --version 2>&1` in
4385*GNU*)
4386 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
4387*)
4388 ac_count=0
4389 $as_echo_n 0123456789 >"conftest.in"
4390 while :
4391 do
4392 cat "conftest.in" "conftest.in" >"conftest.tmp"
4393 mv "conftest.tmp" "conftest.in"
4394 cp "conftest.in" "conftest.nl"
4395 $as_echo 'EGREP' >> "conftest.nl"
4396 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4397 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4398 as_fn_arith $ac_count + 1 && ac_count=$as_val
4399 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
4400 # Best one so far, save it but keep looking for a better one
4401 ac_cv_path_EGREP="$ac_path_EGREP"
4402 ac_path_EGREP_max=$ac_count
4403 fi
4404 # 10*(2^10) chars as input seems more than enough
4405 test $ac_count -gt 10 && break
4406 done
4407 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4408esac
bec39cab 4409
81ecdfbb
RW
4410 $ac_path_EGREP_found && break 3
4411 done
4412 done
4413 done
4414IFS=$as_save_IFS
4415 if test -z "$ac_cv_path_EGREP"; then
d0ac1c44 4416 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
783e057b 4417 fi
783e057b 4418else
81ecdfbb 4419 ac_cv_path_EGREP=$EGREP
783e057b
DJ
4420fi
4421
81ecdfbb 4422 fi
783e057b 4423fi
81ecdfbb
RW
4424{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
4425$as_echo "$ac_cv_path_EGREP" >&6; }
4426 EGREP="$ac_cv_path_EGREP"
4427
783e057b 4428
81ecdfbb
RW
4429{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
4430$as_echo_n "checking for ANSI C header files... " >&6; }
d0ac1c44 4431if ${ac_cv_header_stdc+:} false; then :
81ecdfbb 4432 $as_echo_n "(cached) " >&6
783e057b 4433else
81ecdfbb 4434 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 4435/* end confdefs.h. */
783e057b 4436#include <stdlib.h>
bec39cab 4437#include <stdarg.h>
783e057b
DJ
4438#include <string.h>
4439#include <float.h>
c906108c 4440
bec39cab
AC
4441int
4442main ()
4443{
c906108c 4444
bec39cab
AC
4445 ;
4446 return 0;
4447}
4448_ACEOF
81ecdfbb 4449if ac_fn_c_try_compile "$LINENO"; then :
783e057b 4450 ac_cv_header_stdc=yes
c906108c 4451else
81ecdfbb 4452 ac_cv_header_stdc=no
c906108c 4453fi
81ecdfbb 4454rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
c906108c 4455
783e057b
DJ
4456if test $ac_cv_header_stdc = yes; then
4457 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
81ecdfbb 4458 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
783e057b
DJ
4459/* end confdefs.h. */
4460#include <string.h>
c906108c 4461
783e057b
DJ
4462_ACEOF
4463if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
81ecdfbb
RW
4464 $EGREP "memchr" >/dev/null 2>&1; then :
4465
c906108c 4466else
783e057b 4467 ac_cv_header_stdc=no
c906108c 4468fi
783e057b 4469rm -f conftest*
c906108c
SS
4470
4471fi
4472
783e057b
DJ
4473if test $ac_cv_header_stdc = yes; then
4474 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
81ecdfbb 4475 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
783e057b
DJ
4476/* end confdefs.h. */
4477#include <stdlib.h>
bec39cab 4478
783e057b
DJ
4479_ACEOF
4480if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
81ecdfbb
RW
4481 $EGREP "free" >/dev/null 2>&1; then :
4482
bec39cab 4483else
783e057b 4484 ac_cv_header_stdc=no
bec39cab 4485fi
783e057b 4486rm -f conftest*
bec39cab
AC
4487
4488fi
bec39cab 4489
783e057b
DJ
4490if test $ac_cv_header_stdc = yes; then
4491 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
81ecdfbb 4492 if test "$cross_compiling" = yes; then :
783e057b 4493 :
bec39cab 4494else
81ecdfbb 4495 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
783e057b
DJ
4496/* end confdefs.h. */
4497#include <ctype.h>
81ecdfbb 4498#include <stdlib.h>
783e057b
DJ
4499#if ((' ' & 0x0FF) == 0x020)
4500# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4501# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4502#else
4503# define ISLOWER(c) \
4504 (('a' <= (c) && (c) <= 'i') \
4505 || ('j' <= (c) && (c) <= 'r') \
4506 || ('s' <= (c) && (c) <= 'z'))
4507# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4508#endif
4509
4510#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4511int
4512main ()
4513{
4514 int i;
4515 for (i = 0; i < 256; i++)
4516 if (XOR (islower (i), ISLOWER (i))
4517 || toupper (i) != TOUPPER (i))
81ecdfbb
RW
4518 return 2;
4519 return 0;
783e057b
DJ
4520}
4521_ACEOF
81ecdfbb 4522if ac_fn_c_try_run "$LINENO"; then :
783e057b 4523
81ecdfbb
RW
4524else
4525 ac_cv_header_stdc=no
783e057b 4526fi
81ecdfbb
RW
4527rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
4528 conftest.$ac_objext conftest.beam conftest.$ac_ext
783e057b 4529fi
81ecdfbb 4530
783e057b
DJ
4531fi
4532fi
81ecdfbb
RW
4533{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
4534$as_echo "$ac_cv_header_stdc" >&6; }
783e057b
DJ
4535if test $ac_cv_header_stdc = yes; then
4536
81ecdfbb 4537$as_echo "#define STDC_HEADERS 1" >>confdefs.h
783e057b
DJ
4538
4539fi
4540
4541# On IRIX 5.3, sys/types and inttypes.h are conflicting.
783e057b
DJ
4542for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
4543 inttypes.h stdint.h unistd.h
81ecdfbb
RW
4544do :
4545 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
4546ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
4547"
d0ac1c44 4548if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
783e057b 4549 cat >>confdefs.h <<_ACEOF
81ecdfbb 4550#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
783e057b
DJ
4551_ACEOF
4552
4553fi
4554
4555done
4556
4557
4558
81ecdfbb 4559 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
d0ac1c44 4560if test "x$ac_cv_header_minix_config_h" = xyes; then :
783e057b
DJ
4561 MINIX=yes
4562else
4563 MINIX=
4564fi
4565
4566
4567 if test "$MINIX" = yes; then
4568
81ecdfbb 4569$as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
783e057b
DJ
4570
4571
81ecdfbb 4572$as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
783e057b
DJ
4573
4574
81ecdfbb 4575$as_echo "#define _MINIX 1" >>confdefs.h
783e057b
DJ
4576
4577 fi
4578
4579
81ecdfbb
RW
4580 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
4581$as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
d0ac1c44 4582if ${ac_cv_safe_to_define___extensions__+:} false; then :
81ecdfbb 4583 $as_echo_n "(cached) " >&6
783e057b 4584else
81ecdfbb 4585 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
783e057b
DJ
4586/* end confdefs.h. */
4587
d0ac1c44
SM
4588# define __EXTENSIONS__ 1
4589 $ac_includes_default
783e057b
DJ
4590int
4591main ()
4592{
4593
4594 ;
4595 return 0;
4596}
4597_ACEOF
81ecdfbb 4598if ac_fn_c_try_compile "$LINENO"; then :
783e057b
DJ
4599 ac_cv_safe_to_define___extensions__=yes
4600else
81ecdfbb 4601 ac_cv_safe_to_define___extensions__=no
783e057b 4602fi
81ecdfbb 4603rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
783e057b 4604fi
81ecdfbb
RW
4605{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
4606$as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
783e057b 4607 test $ac_cv_safe_to_define___extensions__ = yes &&
81ecdfbb 4608 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
783e057b 4609
81ecdfbb 4610 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
783e057b 4611
81ecdfbb 4612 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
783e057b 4613
81ecdfbb 4614 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
783e057b 4615
81ecdfbb 4616 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
783e057b
DJ
4617
4618
c971b7fa
PA
4619ac_aux_dir=
4620for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
d0ac1c44
SM
4621 if test -f "$ac_dir/install-sh"; then
4622 ac_aux_dir=$ac_dir
4623 ac_install_sh="$ac_aux_dir/install-sh -c"
4624 break
4625 elif test -f "$ac_dir/install.sh"; then
4626 ac_aux_dir=$ac_dir
4627 ac_install_sh="$ac_aux_dir/install.sh -c"
4628 break
4629 elif test -f "$ac_dir/shtool"; then
4630 ac_aux_dir=$ac_dir
4631 ac_install_sh="$ac_aux_dir/shtool install -c"
4632 break
4633 fi
c971b7fa
PA
4634done
4635if test -z "$ac_aux_dir"; then
d0ac1c44 4636 as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
c971b7fa 4637fi
770d76d7 4638
c971b7fa
PA
4639# These three variables are undocumented and unsupported,
4640# and are intended to be withdrawn in a future Autoconf release.
4641# They can cause serious problems if a builder's source tree is in a directory
4642# whose full name contains unusual characters.
4643ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
4644ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
4645ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
770d76d7 4646
770d76d7 4647
c971b7fa
PA
4648# Make sure we can run config.sub.
4649$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
d0ac1c44 4650 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
770d76d7 4651
c971b7fa
PA
4652{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
4653$as_echo_n "checking build system type... " >&6; }
d0ac1c44 4654if ${ac_cv_build+:} false; then :
c971b7fa 4655 $as_echo_n "(cached) " >&6
770d76d7 4656else
c971b7fa
PA
4657 ac_build_alias=$build_alias
4658test "x$ac_build_alias" = x &&
4659 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
4660test "x$ac_build_alias" = x &&
d0ac1c44 4661 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
c971b7fa 4662ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
d0ac1c44 4663 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
c971b7fa 4664
770d76d7 4665fi
c971b7fa
PA
4666{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
4667$as_echo "$ac_cv_build" >&6; }
4668case $ac_cv_build in
4669*-*-*) ;;
d0ac1c44 4670*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
770d76d7 4671esac
c971b7fa
PA
4672build=$ac_cv_build
4673ac_save_IFS=$IFS; IFS='-'
4674set x $ac_cv_build
4675shift
4676build_cpu=$1
4677build_vendor=$2
4678shift; shift
4679# Remember, the first character of IFS is used to create $*,
4680# except with old shells:
4681build_os=$*
4682IFS=$ac_save_IFS
4683case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
770d76d7
PA
4684
4685
c971b7fa
PA
4686{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
4687$as_echo_n "checking host system type... " >&6; }
d0ac1c44 4688if ${ac_cv_host+:} false; then :
81ecdfbb
RW
4689 $as_echo_n "(cached) " >&6
4690else
c971b7fa
PA
4691 if test "x$host_alias" = x; then
4692 ac_cv_host=$ac_cv_build
81ecdfbb 4693else
c971b7fa 4694 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
d0ac1c44 4695 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
81ecdfbb 4696fi
81ecdfbb
RW
4697
4698fi
c971b7fa
PA
4699{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
4700$as_echo "$ac_cv_host" >&6; }
4701case $ac_cv_host in
4702*-*-*) ;;
d0ac1c44 4703*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
81ecdfbb 4704esac
c971b7fa
PA
4705host=$ac_cv_host
4706ac_save_IFS=$IFS; IFS='-'
4707set x $ac_cv_host
4708shift
4709host_cpu=$1
4710host_vendor=$2
4711shift; shift
4712# Remember, the first character of IFS is used to create $*,
4713# except with old shells:
4714host_os=$*
4715IFS=$ac_save_IFS
4716case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
3388710e
JM
4717
4718
4719{ $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
4720$as_echo_n "checking target system type... " >&6; }
d0ac1c44 4721if ${ac_cv_target+:} false; then :
3388710e
JM
4722 $as_echo_n "(cached) " >&6
4723else
4724 if test "x$target_alias" = x; then
4725 ac_cv_target=$ac_cv_host
4726else
4727 ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
d0ac1c44 4728 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
3388710e
JM
4729fi
4730
4731fi
4732{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
4733$as_echo "$ac_cv_target" >&6; }
4734case $ac_cv_target in
4735*-*-*) ;;
d0ac1c44 4736*) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;;
3388710e
JM
4737esac
4738target=$ac_cv_target
4739ac_save_IFS=$IFS; IFS='-'
4740set x $ac_cv_target
4741shift
4742target_cpu=$1
4743target_vendor=$2
4744shift; shift
4745# Remember, the first character of IFS is used to create $*,
4746# except with old shells:
4747target_os=$*
4748IFS=$ac_save_IFS
4749case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
4750
4751
4752# The aliases save the names the user supplied, while $host etc.
4753# will get canonicalized.
4754test -n "$target_alias" &&
4755 test "$program_prefix$program_suffix$program_transform_name" = \
4756 NONENONEs,x,x, &&
4757 program_prefix=${target_alias}-
4758
4759# The tests for host and target for $enable_largefile require
4760# canonical names.
4761
4762
81ecdfbb 4763
da2f07f1
JK
4764# As the $enable_largefile decision depends on --enable-plugins we must set it
4765# even in directories otherwise not depending on the $plugins option.
4766
4767
2974be62
AM
4768 maybe_plugins=no
4769 for ac_header in dlfcn.h
4770do :
4771 ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
4772"
d0ac1c44 4773if test "x$ac_cv_header_dlfcn_h" = xyes; then :
2974be62
AM
4774 cat >>confdefs.h <<_ACEOF
4775#define HAVE_DLFCN_H 1
4776_ACEOF
4777 maybe_plugins=yes
4778fi
4779
4780done
4781
4782 for ac_header in windows.h
4783do :
4784 ac_fn_c_check_header_compile "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default
4785"
d0ac1c44 4786if test "x$ac_cv_header_windows_h" = xyes; then :
2974be62
AM
4787 cat >>confdefs.h <<_ACEOF
4788#define HAVE_WINDOWS_H 1
4789_ACEOF
4790 maybe_plugins=yes
4791fi
4792
4793done
4794
4795
4796 # Check whether --enable-plugins was given.
da2f07f1
JK
4797if test "${enable_plugins+set}" = set; then :
4798 enableval=$enable_plugins; case "${enableval}" in
2974be62
AM
4799 no) plugins=no ;;
4800 *) plugins=yes
4801 if test "$maybe_plugins" != "yes" ; then
d0ac1c44 4802 as_fn_error $? "Building with plugin support requires a host that supports dlopen." "$LINENO" 5
2974be62
AM
4803 fi ;;
4804 esac
da2f07f1 4805else
2974be62
AM
4806 plugins=$maybe_plugins
4807
da2f07f1
JK
4808fi
4809
2974be62 4810 if test "$plugins" = "yes"; then
458412c3
TT
4811 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlsym" >&5
4812$as_echo_n "checking for library containing dlsym... " >&6; }
d0ac1c44 4813if ${ac_cv_search_dlsym+:} false; then :
2974be62
AM
4814 $as_echo_n "(cached) " >&6
4815else
4816 ac_func_search_save_LIBS=$LIBS
4817cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4818/* end confdefs.h. */
4819
4820/* Override any GCC internal prototype to avoid an error.
4821 Use char because int might match the return type of a GCC
4822 builtin and then its argument prototype would still apply. */
4823#ifdef __cplusplus
4824extern "C"
4825#endif
458412c3 4826char dlsym ();
2974be62
AM
4827int
4828main ()
4829{
458412c3 4830return dlsym ();
2974be62
AM
4831 ;
4832 return 0;
4833}
4834_ACEOF
4835for ac_lib in '' dl; do
4836 if test -z "$ac_lib"; then
4837 ac_res="none required"
4838 else
4839 ac_res=-l$ac_lib
4840 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
4841 fi
4842 if ac_fn_c_try_link "$LINENO"; then :
458412c3 4843 ac_cv_search_dlsym=$ac_res
2974be62
AM
4844fi
4845rm -f core conftest.err conftest.$ac_objext \
4846 conftest$ac_exeext
d0ac1c44 4847 if ${ac_cv_search_dlsym+:} false; then :
2974be62
AM
4848 break
4849fi
4850done
d0ac1c44 4851if ${ac_cv_search_dlsym+:} false; then :
2974be62
AM
4852
4853else
458412c3 4854 ac_cv_search_dlsym=no
2974be62
AM
4855fi
4856rm conftest.$ac_ext
4857LIBS=$ac_func_search_save_LIBS
4858fi
458412c3
TT
4859{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlsym" >&5
4860$as_echo "$ac_cv_search_dlsym" >&6; }
4861ac_res=$ac_cv_search_dlsym
2974be62
AM
4862if test "$ac_res" != no; then :
4863 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
4864
4865fi
4866
4867 fi
da2f07f1
JK
4868
4869
4870case "${host}" in
c8693053
RO
4871 sparc-*-solaris*|i?86-*-solaris*)
4872 # On native 32-bit Solaris/SPARC and x86, large-file and procfs support
4873 # were mutually exclusive until Solaris 11.3. Without procfs support,
4874 # the bfd/ elf module cannot provide certain routines such as
4875 # elfcore_write_prpsinfo or elfcore_write_prstatus. So unless the user
4876 # explicitly requested large-file support through the
4877 # --enable-largefile switch, disable large-file support in favor of
4878 # procfs support.
4879 #
4880 # Check if <sys/procfs.h> is incompatible with large-file support.
4881 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4882/* end confdefs.h. */
4883#define _FILE_OFFSET_BITS 64
4884#define _STRUCTURED_PROC 1
4885#include <sys/procfs.h>
4886int
4887main ()
4888{
4889
4890 ;
4891 return 0;
4892}
4893_ACEOF
4894if ac_fn_c_try_compile "$LINENO"; then :
4895 acx_cv_procfs_lfs=yes
4896else
4897 acx_cv_procfs_lfs=no
4898fi
4899rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4900 #
4901 # Forcefully disable large-file support only if necessary, gdb is in
4902 # tree and enabled.
4903 if test "${target}" = "${host}" -a "$acx_cv_procfs_lfs" = no \
4904 -a -d $srcdir/../gdb -a "$enable_gdb" != no; then
4905 : ${enable_largefile="no"}
4906 if test "$plugins" = yes; then
4907 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
4908plugin support disabled; require large-file support which is incompatible with GDB." >&5
4909$as_echo "$as_me: WARNING:
4910plugin support disabled; require large-file support which is incompatible with GDB." >&2;}
4911 plugins=no
4912 fi
4913 fi
4914 #
4915 # Explicitly undef _FILE_OFFSET_BITS if enable_largefile=no for the
4916 # benefit of g++ 9+ which predefines it on Solaris.
4917 if test "$enable_largefile" = no; then
4918 LARGEFILE_CPPFLAGS="-U_FILE_OFFSET_BITS"
4919
4920 fi
da2f07f1
JK
4921 ;;
4922esac
4923
4924# Check whether --enable-largefile was given.
4925if test "${enable_largefile+set}" = set; then :
4926 enableval=$enable_largefile;
4927fi
4928
4929if test "$enable_largefile" != no; then
4930
4931 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
4932$as_echo_n "checking for special C compiler options needed for large files... " >&6; }
d0ac1c44 4933if ${ac_cv_sys_largefile_CC+:} false; then :
da2f07f1
JK
4934 $as_echo_n "(cached) " >&6
4935else
4936 ac_cv_sys_largefile_CC=no
4937 if test "$GCC" != yes; then
4938 ac_save_CC=$CC
4939 while :; do
4940 # IRIX 6.2 and later do not support large files by default,
4941 # so use the C compiler's -n32 option if that helps.
4942 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4943/* end confdefs.h. */
4944#include <sys/types.h>
4945 /* Check that off_t can represent 2**63 - 1 correctly.
4946 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4947 since some C++ compilers masquerading as C compilers
4948 incorrectly reject 9223372036854775807. */
4949#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4950 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4951 && LARGE_OFF_T % 2147483647 == 1)
4952 ? 1 : -1];
4953int
4954main ()
4955{
4956
4957 ;
4958 return 0;
4959}
4960_ACEOF
4961 if ac_fn_c_try_compile "$LINENO"; then :
4962 break
4963fi
4964rm -f core conftest.err conftest.$ac_objext
4965 CC="$CC -n32"
4966 if ac_fn_c_try_compile "$LINENO"; then :
4967 ac_cv_sys_largefile_CC=' -n32'; break
4968fi
4969rm -f core conftest.err conftest.$ac_objext
4970 break
4971 done
4972 CC=$ac_save_CC
4973 rm -f conftest.$ac_ext
4974 fi
4975fi
4976{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
4977$as_echo "$ac_cv_sys_largefile_CC" >&6; }
4978 if test "$ac_cv_sys_largefile_CC" != no; then
4979 CC=$CC$ac_cv_sys_largefile_CC
4980 fi
4981
4982 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
4983$as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
d0ac1c44 4984if ${ac_cv_sys_file_offset_bits+:} false; then :
da2f07f1
JK
4985 $as_echo_n "(cached) " >&6
4986else
4987 while :; do
4988 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4989/* end confdefs.h. */
4990#include <sys/types.h>
4991 /* Check that off_t can represent 2**63 - 1 correctly.
4992 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4993 since some C++ compilers masquerading as C compilers
4994 incorrectly reject 9223372036854775807. */
4995#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4996 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4997 && LARGE_OFF_T % 2147483647 == 1)
4998 ? 1 : -1];
4999int
5000main ()
5001{
5002
5003 ;
5004 return 0;
5005}
5006_ACEOF
5007if ac_fn_c_try_compile "$LINENO"; then :
5008 ac_cv_sys_file_offset_bits=no; break
5009fi
5010rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5011 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5012/* end confdefs.h. */
5013#define _FILE_OFFSET_BITS 64
5014#include <sys/types.h>
5015 /* Check that off_t can represent 2**63 - 1 correctly.
5016 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5017 since some C++ compilers masquerading as C compilers
5018 incorrectly reject 9223372036854775807. */
5019#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5020 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5021 && LARGE_OFF_T % 2147483647 == 1)
5022 ? 1 : -1];
5023int
5024main ()
5025{
5026
5027 ;
5028 return 0;
5029}
5030_ACEOF
5031if ac_fn_c_try_compile "$LINENO"; then :
5032 ac_cv_sys_file_offset_bits=64; break
5033fi
5034rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5035 ac_cv_sys_file_offset_bits=unknown
5036 break
5037done
5038fi
5039{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
5040$as_echo "$ac_cv_sys_file_offset_bits" >&6; }
5041case $ac_cv_sys_file_offset_bits in #(
5042 no | unknown) ;;
5043 *)
5044cat >>confdefs.h <<_ACEOF
5045#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
5046_ACEOF
5047;;
5048esac
5049rm -rf conftest*
5050 if test $ac_cv_sys_file_offset_bits = unknown; then
5051 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
5052$as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
d0ac1c44 5053if ${ac_cv_sys_large_files+:} false; then :
da2f07f1
JK
5054 $as_echo_n "(cached) " >&6
5055else
5056 while :; do
5057 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5058/* end confdefs.h. */
5059#include <sys/types.h>
5060 /* Check that off_t can represent 2**63 - 1 correctly.
5061 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5062 since some C++ compilers masquerading as C compilers
5063 incorrectly reject 9223372036854775807. */
5064#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5065 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5066 && LARGE_OFF_T % 2147483647 == 1)
5067 ? 1 : -1];
5068int
5069main ()
5070{
5071
5072 ;
5073 return 0;
5074}
5075_ACEOF
5076if ac_fn_c_try_compile "$LINENO"; then :
5077 ac_cv_sys_large_files=no; break
5078fi
5079rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5080 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5081/* end confdefs.h. */
5082#define _LARGE_FILES 1
5083#include <sys/types.h>
5084 /* Check that off_t can represent 2**63 - 1 correctly.
5085 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5086 since some C++ compilers masquerading as C compilers
5087 incorrectly reject 9223372036854775807. */
5088#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5089 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5090 && LARGE_OFF_T % 2147483647 == 1)
5091 ? 1 : -1];
5092int
5093main ()
5094{
5095
5096 ;
5097 return 0;
5098}
5099_ACEOF
5100if ac_fn_c_try_compile "$LINENO"; then :
5101 ac_cv_sys_large_files=1; break
5102fi
5103rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5104 ac_cv_sys_large_files=unknown
5105 break
5106done
5107fi
5108{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
5109$as_echo "$ac_cv_sys_large_files" >&6; }
5110case $ac_cv_sys_large_files in #(
5111 no | unknown) ;;
5112 *)
5113cat >>confdefs.h <<_ACEOF
5114#define _LARGE_FILES $ac_cv_sys_large_files
5115_ACEOF
5116;;
5117esac
5118rm -rf conftest*
5119 fi
d0ac1c44
SM
5120
5121
da2f07f1
JK
5122fi
5123
5124
d0ac1c44
SM
5125# Expand $ac_aux_dir to an absolute path.
5126am_aux_dir=`cd "$ac_aux_dir" && pwd`
4869db5e 5127
d0ac1c44 5128if test x"${install_sh+set}" != xset; then
4869db5e
RM
5129 case $am_aux_dir in
5130 *\ * | *\ *)
5131 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
5132 *)
5133 install_sh="\${SHELL} $am_aux_dir/install-sh"
5134 esac
5135fi
5136
d0ac1c44
SM
5137# Installed binaries are usually stripped using 'strip' when the user
5138# run "make install-strip". However 'strip' might not be the right
4869db5e 5139# tool to use in cross-compilation environments, therefore Automake
d0ac1c44 5140# will honor the 'STRIP' environment variable to overrule this program.
4869db5e
RM
5141if test "$cross_compiling" != no; then
5142 if test -n "$ac_tool_prefix"; then
5143 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
5144set dummy ${ac_tool_prefix}strip; ac_word=$2
5145{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5146$as_echo_n "checking for $ac_word... " >&6; }
d0ac1c44 5147if ${ac_cv_prog_STRIP+:} false; then :
4869db5e
RM
5148 $as_echo_n "(cached) " >&6
5149else
5150 if test -n "$STRIP"; then
5151 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
5152else
5153as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5154for as_dir in $PATH
5155do
5156 IFS=$as_save_IFS
5157 test -z "$as_dir" && as_dir=.
5158 for ac_exec_ext in '' $ac_executable_extensions; do
d0ac1c44 5159 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4869db5e
RM
5160 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
5161 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5162 break 2
5163 fi
5164done
5165 done
5166IFS=$as_save_IFS
5167
5168fi
5169fi
5170STRIP=$ac_cv_prog_STRIP
5171if test -n "$STRIP"; then
5172 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
5173$as_echo "$STRIP" >&6; }
5174else
5175 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5176$as_echo "no" >&6; }
5177fi
5178
5179
5180fi
5181if test -z "$ac_cv_prog_STRIP"; then
5182 ac_ct_STRIP=$STRIP
5183 # Extract the first word of "strip", so it can be a program name with args.
5184set dummy strip; ac_word=$2
5185{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5186$as_echo_n "checking for $ac_word... " >&6; }
d0ac1c44 5187if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
4869db5e
RM
5188 $as_echo_n "(cached) " >&6
5189else
5190 if test -n "$ac_ct_STRIP"; then
5191 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
5192else
5193as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5194for as_dir in $PATH
5195do
5196 IFS=$as_save_IFS
5197 test -z "$as_dir" && as_dir=.
5198 for ac_exec_ext in '' $ac_executable_extensions; do
d0ac1c44 5199 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4869db5e
RM
5200 ac_cv_prog_ac_ct_STRIP="strip"
5201 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5202 break 2
5203 fi
5204done
5205 done
5206IFS=$as_save_IFS
5207
5208fi
5209fi
5210ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
5211if test -n "$ac_ct_STRIP"; then
5212 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
5213$as_echo "$ac_ct_STRIP" >&6; }
5214else
5215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5216$as_echo "no" >&6; }
5217fi
5218
5219 if test "x$ac_ct_STRIP" = x; then
5220 STRIP=":"
5221 else
5222 case $cross_compiling:$ac_tool_warned in
5223yes:)
5224{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5225$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5226ac_tool_warned=yes ;;
5227esac
5228 STRIP=$ac_ct_STRIP
5229 fi
5230else
5231 STRIP="$ac_cv_prog_STRIP"
5232fi
5233
5234fi
5235INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
5236
783e057b
DJ
5237
5238ac_aux_dir=
81ecdfbb 5239for ac_dir in .. "$srcdir"/..; do
d0ac1c44
SM
5240 if test -f "$ac_dir/install-sh"; then
5241 ac_aux_dir=$ac_dir
5242 ac_install_sh="$ac_aux_dir/install-sh -c"
5243 break
5244 elif test -f "$ac_dir/install.sh"; then
5245 ac_aux_dir=$ac_dir
5246 ac_install_sh="$ac_aux_dir/install.sh -c"
5247 break
5248 elif test -f "$ac_dir/shtool"; then
5249 ac_aux_dir=$ac_dir
5250 ac_install_sh="$ac_aux_dir/shtool install -c"
5251 break
5252 fi
783e057b
DJ
5253done
5254if test -z "$ac_aux_dir"; then
d0ac1c44 5255 as_fn_error $? "cannot find install-sh, install.sh, or shtool in .. \"$srcdir\"/.." "$LINENO" 5
783e057b 5256fi
81ecdfbb
RW
5257
5258# These three variables are undocumented and unsupported,
5259# and are intended to be withdrawn in a future Autoconf release.
5260# They can cause serious problems if a builder's source tree is in a directory
5261# whose full name contains unusual characters.
5262ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
5263ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
5264ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
5265
783e057b 5266
783e057b 5267
91e1a0ed
SM
5268# Set build, build_cpu, build_vendor and build_os.
5269
5270
5271# Set host, host_cpu, host_vendor, and host_os.
5272
5273
5274# Set target, target_cpu, target_vendor, and target_os.
5275
5276
b316465f
TT
5277 case ${build_alias} in
5278 "") build_noncanonical=${build} ;;
5279 *) build_noncanonical=${build_alias} ;;
5280esac
5281
5282 case ${host_alias} in
5283 "") host_noncanonical=${build_noncanonical} ;;
5284 *) host_noncanonical=${host_alias} ;;
5285esac
5286
5287 case ${target_alias} in
5288 "") target_noncanonical=${host_noncanonical} ;;
5289 *) target_noncanonical=${target_alias} ;;
5290esac
5291
5292
5293
5294
9009e1ae
MR
5295test "$program_prefix" != NONE &&
5296 program_transform_name="s&^&$program_prefix&;$program_transform_name"
5297# Use a double $ so make ignores it.
5298test "$program_suffix" != NONE &&
5299 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
5300# Double any \ or $.
5301# By default was `s,x,x', remove it if useless.
5302ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
5303program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
5304
81ecdfbb 5305
b686ecb5
JM
5306# We require libtool to link with the in-tree libtool libraries
5307# the proper way.
5308case `pwd` in
5309 *\ * | *\ *)
5310 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5
5311$as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;;
5312esac
0bcda685
PA
5313
5314
0bcda685 5315
b686ecb5
JM
5316macro_version='2.2.7a'
5317macro_revision='1.3134'
0bcda685 5318
0bcda685 5319
0bcda685 5320
0bcda685 5321
0bcda685 5322
0bcda685 5323
0bcda685 5324
0bcda685 5325
0bcda685 5326
0bcda685 5327
0bcda685 5328
0bcda685 5329
0bcda685 5330
b686ecb5 5331ltmain="$ac_aux_dir/ltmain.sh"
0bcda685 5332
b686ecb5
JM
5333# Backslashify metacharacters that are still active within
5334# double-quoted strings.
5335sed_quote_subst='s/\(["`$\\]\)/\\\1/g'
0bcda685 5336
b686ecb5
JM
5337# Same as above, but do not quote variable references.
5338double_quote_subst='s/\(["`\\]\)/\\\1/g'
0bcda685 5339
b686ecb5
JM
5340# Sed substitution to delay expansion of an escaped shell variable in a
5341# double_quote_subst'ed string.
5342delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
0bcda685 5343
b686ecb5
JM
5344# Sed substitution to delay expansion of an escaped single quote.
5345delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
0bcda685 5346
b686ecb5
JM
5347# Sed substitution to avoid accidental globbing in evaled expressions
5348no_glob_subst='s/\*/\\\*/g'
0bcda685 5349
b686ecb5
JM
5350ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
5351ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
5352ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
0bcda685 5353
b686ecb5
JM
5354{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
5355$as_echo_n "checking how to print strings... " >&6; }
5356# Test print first, because it will be a builtin if present.
5357if test "X`print -r -- -n 2>/dev/null`" = X-n && \
5358 test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
5359 ECHO='print -r --'
5360elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
5361 ECHO='printf %s\n'
5362else
5363 # Use this function as a fallback that always works.
5364 func_fallback_echo ()
0bcda685 5365 {
b686ecb5
JM
5366 eval 'cat <<_LTECHO_EOF
5367$1
5368_LTECHO_EOF'
0bcda685 5369 }
b686ecb5
JM
5370 ECHO='func_fallback_echo'
5371fi
0bcda685 5372
b686ecb5
JM
5373# func_echo_all arg...
5374# Invoke $ECHO with all args, space-separated.
5375func_echo_all ()
5376{
5377 $ECHO ""
5378}
0bcda685 5379
b686ecb5
JM
5380case "$ECHO" in
5381 printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5
5382$as_echo "printf" >&6; } ;;
5383 print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5
5384$as_echo "print -r" >&6; } ;;
5385 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5
5386$as_echo "cat" >&6; } ;;
5387esac
0bcda685 5388
0bcda685 5389
0bcda685 5390
0bcda685 5391
0bcda685 5392
0bcda685 5393
0bcda685 5394
0bcda685 5395
0bcda685 5396
0bcda685 5397
0bcda685 5398
0bcda685 5399
0bcda685 5400
0bcda685 5401
b686ecb5
JM
5402{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
5403$as_echo_n "checking for a sed that does not truncate output... " >&6; }
5404if ${ac_cv_path_SED+:} false; then :
5405 $as_echo_n "(cached) " >&6
5406else
5407 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
5408 for ac_i in 1 2 3 4 5 6 7; do
5409 ac_script="$ac_script$as_nl$ac_script"
5410 done
5411 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
5412 { ac_script=; unset ac_script;}
5413 if test -z "$SED"; then
5414 ac_path_SED_found=false
5415 # Loop through the user's path and test for each of PROGNAME-LIST
5416 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5417for as_dir in $PATH
5418do
5419 IFS=$as_save_IFS
5420 test -z "$as_dir" && as_dir=.
5421 for ac_prog in sed gsed; do
5422 for ac_exec_ext in '' $ac_executable_extensions; do
5423 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
5424 as_fn_executable_p "$ac_path_SED" || continue
5425# Check for GNU ac_path_SED and select it if it is found.
5426 # Check for GNU $ac_path_SED
5427case `"$ac_path_SED" --version 2>&1` in
5428*GNU*)
5429 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
5430*)
5431 ac_count=0
5432 $as_echo_n 0123456789 >"conftest.in"
5433 while :
5434 do
5435 cat "conftest.in" "conftest.in" >"conftest.tmp"
5436 mv "conftest.tmp" "conftest.in"
5437 cp "conftest.in" "conftest.nl"
5438 $as_echo '' >> "conftest.nl"
5439 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
5440 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5441 as_fn_arith $ac_count + 1 && ac_count=$as_val
5442 if test $ac_count -gt ${ac_path_SED_max-0}; then
5443 # Best one so far, save it but keep looking for a better one
5444 ac_cv_path_SED="$ac_path_SED"
5445 ac_path_SED_max=$ac_count
5446 fi
5447 # 10*(2^10) chars as input seems more than enough
5448 test $ac_count -gt 10 && break
5449 done
5450 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5451esac
0bcda685 5452
b686ecb5
JM
5453 $ac_path_SED_found && break 3
5454 done
5455 done
5456 done
5457IFS=$as_save_IFS
5458 if test -z "$ac_cv_path_SED"; then
5459 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
5460 fi
5461else
5462 ac_cv_path_SED=$SED
5463fi
0bcda685 5464
b686ecb5
JM
5465fi
5466{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
5467$as_echo "$ac_cv_path_SED" >&6; }
5468 SED="$ac_cv_path_SED"
5469 rm -f conftest.sed
0bcda685 5470
b686ecb5
JM
5471test -z "$SED" && SED=sed
5472Xsed="$SED -e 1s/^X//"
0bcda685 5473
0bcda685 5474
0bcda685 5475
0bcda685 5476
0bcda685 5477
0bcda685 5478
0bcda685 5479
0bcda685 5480
0bcda685 5481
0bcda685
PA
5482
5483
b686ecb5
JM
5484{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
5485$as_echo_n "checking for fgrep... " >&6; }
5486if ${ac_cv_path_FGREP+:} false; then :
5487 $as_echo_n "(cached) " >&6
5488else
5489 if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
5490 then ac_cv_path_FGREP="$GREP -F"
5491 else
5492 if test -z "$FGREP"; then
5493 ac_path_FGREP_found=false
5494 # Loop through the user's path and test for each of PROGNAME-LIST
5495 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5496for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5497do
5498 IFS=$as_save_IFS
5499 test -z "$as_dir" && as_dir=.
5500 for ac_prog in fgrep; do
5501 for ac_exec_ext in '' $ac_executable_extensions; do
5502 ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
5503 as_fn_executable_p "$ac_path_FGREP" || continue
5504# Check for GNU ac_path_FGREP and select it if it is found.
5505 # Check for GNU $ac_path_FGREP
5506case `"$ac_path_FGREP" --version 2>&1` in
5507*GNU*)
5508 ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
5509*)
5510 ac_count=0
5511 $as_echo_n 0123456789 >"conftest.in"
5512 while :
5513 do
5514 cat "conftest.in" "conftest.in" >"conftest.tmp"
5515 mv "conftest.tmp" "conftest.in"
5516 cp "conftest.in" "conftest.nl"
5517 $as_echo 'FGREP' >> "conftest.nl"
5518 "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
5519 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5520 as_fn_arith $ac_count + 1 && ac_count=$as_val
5521 if test $ac_count -gt ${ac_path_FGREP_max-0}; then
5522 # Best one so far, save it but keep looking for a better one
5523 ac_cv_path_FGREP="$ac_path_FGREP"
5524 ac_path_FGREP_max=$ac_count
5525 fi
5526 # 10*(2^10) chars as input seems more than enough
5527 test $ac_count -gt 10 && break
5528 done
5529 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5530esac
0bcda685 5531
b686ecb5
JM
5532 $ac_path_FGREP_found && break 3
5533 done
5534 done
5535 done
5536IFS=$as_save_IFS
5537 if test -z "$ac_cv_path_FGREP"; then
5538 as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
5539 fi
0bcda685 5540else
b686ecb5 5541 ac_cv_path_FGREP=$FGREP
0bcda685 5542fi
b686ecb5
JM
5543
5544 fi
0bcda685 5545fi
b686ecb5
JM
5546{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5
5547$as_echo "$ac_cv_path_FGREP" >&6; }
5548 FGREP="$ac_cv_path_FGREP"
0bcda685 5549
0bcda685 5550
b686ecb5 5551test -z "$GREP" && GREP=grep
0bcda685 5552
0bcda685 5553
0bcda685 5554
0bcda685 5555
0bcda685 5556
0bcda685 5557
0bcda685 5558
0bcda685 5559
0bcda685 5560
0bcda685 5561
0bcda685 5562
0bcda685 5563
0bcda685 5564
0bcda685 5565
0bcda685 5566
0bcda685 5567
0bcda685 5568
0bcda685 5569
0bcda685 5570
b686ecb5
JM
5571# Check whether --with-gnu-ld was given.
5572if test "${with_gnu_ld+set}" = set; then :
5573 withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
5574else
5575 with_gnu_ld=no
5576fi
0bcda685 5577
b686ecb5
JM
5578ac_prog=ld
5579if test "$GCC" = yes; then
5580 # Check if gcc -print-prog-name=ld gives a path.
5581 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
5582$as_echo_n "checking for ld used by $CC... " >&6; }
5583 case $host in
5584 *-*-mingw*)
5585 # gcc leaves a trailing carriage return which upsets mingw
5586 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
5587 *)
5588 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
5589 esac
5590 case $ac_prog in
5591 # Accept absolute paths.
5592 [\\/]* | ?:[\\/]*)
5593 re_direlt='/[^/][^/]*/\.\./'
5594 # Canonicalize the pathname of ld
5595 ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
5596 while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
5597 ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
5598 done
5599 test -z "$LD" && LD="$ac_prog"
5600 ;;
5601 "")
5602 # If it fails, then pretend we aren't using GCC.
5603 ac_prog=ld
5604 ;;
5605 *)
5606 # If it is relative, then search for the first ld in PATH.
5607 with_gnu_ld=unknown
5608 ;;
5609 esac
5610elif test "$with_gnu_ld" = yes; then
5611 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
5612$as_echo_n "checking for GNU ld... " >&6; }
5613else
5614 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
5615$as_echo_n "checking for non-GNU ld... " >&6; }
5616fi
5617if ${lt_cv_path_LD+:} false; then :
5618 $as_echo_n "(cached) " >&6
5619else
5620 if test -z "$LD"; then
5621 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
5622 for ac_dir in $PATH; do
5623 IFS="$lt_save_ifs"
5624 test -z "$ac_dir" && ac_dir=.
5625 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
5626 lt_cv_path_LD="$ac_dir/$ac_prog"
5627 # Check to see if the program is GNU ld. I'd rather use --version,
5628 # but apparently some variants of GNU ld only accept -v.
5629 # Break only if it was the GNU/non-GNU ld that we prefer.
5630 case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
5631 *GNU* | *'with BFD'*)
5632 test "$with_gnu_ld" != no && break
5633 ;;
5634 *)
5635 test "$with_gnu_ld" != yes && break
5636 ;;
5637 esac
5638 fi
5639 done
5640 IFS="$lt_save_ifs"
5641else
5642 lt_cv_path_LD="$LD" # Let the user override the test with a path.
5643fi
5644fi
0bcda685 5645
b686ecb5
JM
5646LD="$lt_cv_path_LD"
5647if test -n "$LD"; then
5648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
5649$as_echo "$LD" >&6; }
5650else
5651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5652$as_echo "no" >&6; }
5653fi
5654test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
5655{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
5656$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
5657if ${lt_cv_prog_gnu_ld+:} false; then :
5658 $as_echo_n "(cached) " >&6
5659else
5660 # I'd rather use --version here, but apparently some GNU lds only accept -v.
5661case `$LD -v 2>&1 </dev/null` in
5662*GNU* | *'with BFD'*)
5663 lt_cv_prog_gnu_ld=yes
5664 ;;
5665*)
5666 lt_cv_prog_gnu_ld=no
5667 ;;
5668esac
5669fi
5670{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5
5671$as_echo "$lt_cv_prog_gnu_ld" >&6; }
5672with_gnu_ld=$lt_cv_prog_gnu_ld
0bcda685 5673
0bcda685 5674
0bcda685 5675
0bcda685 5676
0bcda685 5677
0bcda685 5678
0bcda685 5679
0bcda685 5680
0bcda685 5681
b686ecb5
JM
5682{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5
5683$as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; }
5684if ${lt_cv_path_NM+:} false; then :
5685 $as_echo_n "(cached) " >&6
5686else
5687 if test -n "$NM"; then
5688 # Let the user override the nm to test.
5689 lt_nm_to_check="$NM"
5690 else
5691 lt_nm_to_check="${ac_tool_prefix}nm"
5692 if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
5693 lt_nm_to_check="$lt_nm_to_check nm"
5694 fi
5695 fi
5696 for lt_tmp_nm in "$lt_nm_to_check"; do
5697 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
5698 for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
5699 IFS="$lt_save_ifs"
5700 test -z "$ac_dir" && ac_dir=.
5701 # Strip out any user-provided options from the nm to test twice,
5702 # the first time to test to see if nm (rather than its options) has
5703 # an explicit path, the second time to yield a file which can be
5704 # nm'ed itself.
5705 tmp_nm_path="`$ECHO "$lt_tmp_nm" | sed 's, -.*$,,'`"
5706 case "$tmp_nm_path" in
5707 */*|*\\*) tmp_nm="$lt_tmp_nm";;
5708 *) tmp_nm="$ac_dir/$lt_tmp_nm";;
5709 esac
5710 tmp_nm_to_nm="`$ECHO "$tmp_nm" | sed 's, -.*$,,'`"
5711 if test -f "$tmp_nm_to_nm" || test -f "$tmp_nm_to_nm$ac_exeext" ; then
5712 # Check to see if the nm accepts a BSD-compat flag.
5713 # Adding the `sed 1q' prevents false positives on HP-UX, which says:
5714 # nm: unknown option "B" ignored
5715 case `"$tmp_nm" -B "$tmp_nm_to_nm" 2>&1 | grep -v '^ *$' | sed '1q'` in
5716 *$tmp_nm*) lt_cv_path_NM="$tmp_nm -B"
5717 break
5718 ;;
5719 *)
5720 case `"$tmp_nm" -p "$tmp_nm_to_nm" 2>&1 | grep -v '^ *$' | sed '1q'` in
5721 *$tmp_nm*)
5722 lt_cv_path_NM="$tmp_nm -p"
5723 break
5724 ;;
5725 *)
5726 lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
5727 continue # so that we can try to find one that supports BSD flags
5728 ;;
5729 esac
5730 ;;
5731 esac
5732 fi
5733 done
5734 IFS="$lt_save_ifs"
5735 done
5736 : ${lt_cv_path_NM=no}
5737fi
5738{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5
5739$as_echo "$lt_cv_path_NM" >&6; }
5740if test "$lt_cv_path_NM" != "no"; then
5741 NM="$lt_cv_path_NM"
5742else
5743 # Didn't find any BSD compatible name lister, look for dumpbin.
5744 if test -n "$DUMPBIN"; then :
5745 # Let the user override the test.
5746 else
5747 if test -n "$ac_tool_prefix"; then
5748 for ac_prog in dumpbin "link -dump"
5749 do
5750 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
5751set dummy $ac_tool_prefix$ac_prog; ac_word=$2
5752{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5753$as_echo_n "checking for $ac_word... " >&6; }
5754if ${ac_cv_prog_DUMPBIN+:} false; then :
5755 $as_echo_n "(cached) " >&6
5756else
5757 if test -n "$DUMPBIN"; then
5758 ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test.
5759else
5760as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5761for as_dir in $PATH
5762do
5763 IFS=$as_save_IFS
5764 test -z "$as_dir" && as_dir=.
5765 for ac_exec_ext in '' $ac_executable_extensions; do
5766 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5767 ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog"
5768 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5769 break 2
5770 fi
5771done
5772 done
5773IFS=$as_save_IFS
0bcda685 5774
b686ecb5
JM
5775fi
5776fi
5777DUMPBIN=$ac_cv_prog_DUMPBIN
5778if test -n "$DUMPBIN"; then
5779 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5
5780$as_echo "$DUMPBIN" >&6; }
5781else
5782 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5783$as_echo "no" >&6; }
5784fi
0bcda685 5785
0bcda685 5786
b686ecb5
JM
5787 test -n "$DUMPBIN" && break
5788 done
5789fi
5790if test -z "$DUMPBIN"; then
5791 ac_ct_DUMPBIN=$DUMPBIN
5792 for ac_prog in dumpbin "link -dump"
5793do
5794 # Extract the first word of "$ac_prog", so it can be a program name with args.
5795set dummy $ac_prog; ac_word=$2
5796{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5797$as_echo_n "checking for $ac_word... " >&6; }
5798if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then :
5799 $as_echo_n "(cached) " >&6
5800else
5801 if test -n "$ac_ct_DUMPBIN"; then
5802 ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test.
5803else
5804as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5805for as_dir in $PATH
5806do
5807 IFS=$as_save_IFS
5808 test -z "$as_dir" && as_dir=.
5809 for ac_exec_ext in '' $ac_executable_extensions; do
5810 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5811 ac_cv_prog_ac_ct_DUMPBIN="$ac_prog"
5812 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5813 break 2
5814 fi
5815done
5816 done
5817IFS=$as_save_IFS
0bcda685 5818
b686ecb5
JM
5819fi
5820fi
5821ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN
5822if test -n "$ac_ct_DUMPBIN"; then
5823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5
5824$as_echo "$ac_ct_DUMPBIN" >&6; }
5825else
5826 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5827$as_echo "no" >&6; }
5828fi
0bcda685 5829
0bcda685 5830
b686ecb5
JM
5831 test -n "$ac_ct_DUMPBIN" && break
5832done
0bcda685 5833
b686ecb5
JM
5834 if test "x$ac_ct_DUMPBIN" = x; then
5835 DUMPBIN=":"
5836 else
5837 case $cross_compiling:$ac_tool_warned in
5838yes:)
5839{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5840$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5841ac_tool_warned=yes ;;
5842esac
5843 DUMPBIN=$ac_ct_DUMPBIN
5844 fi
5845fi
0bcda685 5846
b686ecb5
JM
5847 case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in
5848 *COFF*)
5849 DUMPBIN="$DUMPBIN -symbols"
5850 ;;
5851 *)
5852 DUMPBIN=:
5853 ;;
5854 esac
5855 fi
0bcda685 5856
b686ecb5
JM
5857 if test "$DUMPBIN" != ":"; then
5858 NM="$DUMPBIN"
5859 fi
5860fi
5861test -z "$NM" && NM=nm
0bcda685 5862
0bcda685 5863
0bcda685 5864
0bcda685 5865
0bcda685 5866
0bcda685 5867
b686ecb5
JM
5868{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5
5869$as_echo_n "checking the name lister ($NM) interface... " >&6; }
5870if ${lt_cv_nm_interface+:} false; then :
5871 $as_echo_n "(cached) " >&6
5872else
5873 lt_cv_nm_interface="BSD nm"
5874 echo "int some_variable = 0;" > conftest.$ac_ext
5875 (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5)
5876 (eval "$ac_compile" 2>conftest.err)
5877 cat conftest.err >&5
5878 (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
5879 (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
5880 cat conftest.err >&5
5881 (eval echo "\"\$as_me:$LINENO: output\"" >&5)
5882 cat conftest.out >&5
5883 if $GREP 'External.*some_variable' conftest.out > /dev/null; then
5884 lt_cv_nm_interface="MS dumpbin"
5885 fi
5886 rm -f conftest*
5887fi
5888{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5
5889$as_echo "$lt_cv_nm_interface" >&6; }
0bcda685 5890
b686ecb5
JM
5891{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
5892$as_echo_n "checking whether ln -s works... " >&6; }
5893LN_S=$as_ln_s
5894if test "$LN_S" = "ln -s"; then
5895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5896$as_echo "yes" >&6; }
5897else
5898 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
5899$as_echo "no, using $LN_S" >&6; }
5900fi
0bcda685 5901
b686ecb5
JM
5902# find the maximum length of command line arguments
5903{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5
5904$as_echo_n "checking the maximum length of command line arguments... " >&6; }
5905if ${lt_cv_sys_max_cmd_len+:} false; then :
5906 $as_echo_n "(cached) " >&6
5907else
5908 i=0
5909 teststring="ABCD"
0bcda685 5910
b686ecb5
JM
5911 case $build_os in
5912 msdosdjgpp*)
5913 # On DJGPP, this test can blow up pretty badly due to problems in libc
5914 # (any single argument exceeding 2000 bytes causes a buffer overrun
5915 # during glob expansion). Even if it were fixed, the result of this
5916 # check would be larger than it should be.
5917 lt_cv_sys_max_cmd_len=12288; # 12K is about right
5918 ;;
0bcda685 5919
b686ecb5
JM
5920 gnu*)
5921 # Under GNU Hurd, this test is not required because there is
5922 # no limit to the length of command line arguments.
5923 # Libtool will interpret -1 as no limit whatsoever
5924 lt_cv_sys_max_cmd_len=-1;
5925 ;;
0bcda685 5926
b686ecb5
JM
5927 cygwin* | mingw* | cegcc*)
5928 # On Win9x/ME, this test blows up -- it succeeds, but takes
5929 # about 5 minutes as the teststring grows exponentially.
5930 # Worse, since 9x/ME are not pre-emptively multitasking,
5931 # you end up with a "frozen" computer, even though with patience
5932 # the test eventually succeeds (with a max line length of 256k).
5933 # Instead, let's just punt: use the minimum linelength reported by
5934 # all of the supported platforms: 8192 (on NT/2K/XP).
5935 lt_cv_sys_max_cmd_len=8192;
5936 ;;
0bcda685 5937
b686ecb5
JM
5938 mint*)
5939 # On MiNT this can take a long time and run out of memory.
5940 lt_cv_sys_max_cmd_len=8192;
5941 ;;
0bcda685 5942
b686ecb5
JM
5943 amigaos*)
5944 # On AmigaOS with pdksh, this test takes hours, literally.
5945 # So we just punt and use a minimum line length of 8192.
5946 lt_cv_sys_max_cmd_len=8192;
5947 ;;
0bcda685 5948
b686ecb5
JM
5949 netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
5950 # This has been around since 386BSD, at least. Likely further.
5951 if test -x /sbin/sysctl; then
5952 lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
5953 elif test -x /usr/sbin/sysctl; then
5954 lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
5955 else
5956 lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
5957 fi
5958 # And add a safety zone
5959 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
5960 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
5961 ;;
0bcda685 5962
b686ecb5
JM
5963 interix*)
5964 # We know the value 262144 and hardcode it with a safety zone (like BSD)
5965 lt_cv_sys_max_cmd_len=196608
5966 ;;
0bcda685 5967
b686ecb5
JM
5968 osf*)
5969 # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
5970 # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
5971 # nice to cause kernel panics so lets avoid the loop below.
5972 # First set a reasonable default.
5973 lt_cv_sys_max_cmd_len=16384
5974 #
5975 if test -x /sbin/sysconfig; then
5976 case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
5977 *1*) lt_cv_sys_max_cmd_len=-1 ;;
5978 esac
5979 fi
5980 ;;
5981 sco3.2v5*)
5982 lt_cv_sys_max_cmd_len=102400
5983 ;;
5984 sysv5* | sco5v6* | sysv4.2uw2*)
5985 kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
5986 if test -n "$kargmax"; then
5987 lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ ]//'`
5988 else
5989 lt_cv_sys_max_cmd_len=32768
5990 fi
5991 ;;
5992 *)
5993 lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
5994 if test -n "$lt_cv_sys_max_cmd_len"; then
5995 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
5996 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
5997 else
5998 # Make teststring a little bigger before we do anything with it.
5999 # a 1K string should be a reasonable start.
6000 for i in 1 2 3 4 5 6 7 8 ; do
6001 teststring=$teststring$teststring
6002 done
6003 SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
6004 # If test is not a shell built-in, we'll probably end up computing a
6005 # maximum length that is only half of the actual maximum length, but
6006 # we can't tell.
6007 while { test "X"`func_fallback_echo "$teststring$teststring" 2>/dev/null` \
6008 = "X$teststring$teststring"; } >/dev/null 2>&1 &&
6009 test $i != 17 # 1/2 MB should be enough
6010 do
6011 i=`expr $i + 1`
6012 teststring=$teststring$teststring
6013 done
6014 # Only check the string length outside the loop.
6015 lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
6016 teststring=
6017 # Add a significant safety factor because C++ compilers can tack on
6018 # massive amounts of additional arguments before passing them to the
6019 # linker. It appears as though 1/2 is a usable value.
6020 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
6021 fi
6022 ;;
6023 esac
0bcda685 6024
b686ecb5 6025fi
0bcda685 6026
b686ecb5
JM
6027if test -n $lt_cv_sys_max_cmd_len ; then
6028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5
6029$as_echo "$lt_cv_sys_max_cmd_len" >&6; }
6030else
6031 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5
6032$as_echo "none" >&6; }
6033fi
6034max_cmd_len=$lt_cv_sys_max_cmd_len
0bcda685 6035
0bcda685 6036
0bcda685 6037
0bcda685 6038
0bcda685 6039
0bcda685 6040
b686ecb5
JM
6041: ${CP="cp -f"}
6042: ${MV="mv -f"}
6043: ${RM="rm -f"}
0bcda685 6044
b686ecb5
JM
6045{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands some XSI constructs" >&5
6046$as_echo_n "checking whether the shell understands some XSI constructs... " >&6; }
6047# Try some XSI features
6048xsi_shell=no
6049( _lt_dummy="a/b/c"
6050 test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \
6051 = c,a/b,, \
6052 && eval 'test $(( 1 + 1 )) -eq 2 \
6053 && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
6054 && xsi_shell=yes
6055{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $xsi_shell" >&5
6056$as_echo "$xsi_shell" >&6; }
0bcda685 6057
0bcda685 6058
b686ecb5
JM
6059{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands \"+=\"" >&5
6060$as_echo_n "checking whether the shell understands \"+=\"... " >&6; }
6061lt_shell_append=no
6062( foo=bar; set foo baz; eval "$1+=\$2" && test "$foo" = barbaz ) \
6063 >/dev/null 2>&1 \
6064 && lt_shell_append=yes
6065{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_shell_append" >&5
6066$as_echo "$lt_shell_append" >&6; }
0bcda685
PA
6067
6068
b686ecb5
JM
6069if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
6070 lt_unset=unset
0bcda685 6071else
b686ecb5 6072 lt_unset=false
0bcda685 6073fi
0bcda685 6074
0bcda685 6075
0bcda685 6076
0bcda685 6077
0bcda685 6078
b686ecb5
JM
6079# test EBCDIC or ASCII
6080case `echo X|tr X '\101'` in
6081 A) # ASCII based system
6082 # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
6083 lt_SP2NL='tr \040 \012'
6084 lt_NL2SP='tr \015\012 \040\040'
6085 ;;
6086 *) # EBCDIC based system
6087 lt_SP2NL='tr \100 \n'
6088 lt_NL2SP='tr \r\n \100\100'
6089 ;;
6090esac
0bcda685 6091
0bcda685 6092
0bcda685 6093
0bcda685 6094
0bcda685 6095
0bcda685 6096
0bcda685 6097
0bcda685 6098
0bcda685 6099
b686ecb5
JM
6100{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
6101$as_echo_n "checking for $LD option to reload object files... " >&6; }
6102if ${lt_cv_ld_reload_flag+:} false; then :
6103 $as_echo_n "(cached) " >&6
6104else
6105 lt_cv_ld_reload_flag='-r'
6106fi
6107{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5
6108$as_echo "$lt_cv_ld_reload_flag" >&6; }
6109reload_flag=$lt_cv_ld_reload_flag
6110case $reload_flag in
6111"" | " "*) ;;
6112*) reload_flag=" $reload_flag" ;;
6113esac
6114reload_cmds='$LD$reload_flag -o $output$reload_objs'
6115case $host_os in
6116 darwin*)
6117 if test "$GCC" = yes; then
6118 reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
6119 else
6120 reload_cmds='$LD$reload_flag -o $output$reload_objs'
6121 fi
6122 ;;
6123esac
0bcda685 6124
0bcda685 6125
0bcda685 6126
0bcda685 6127
0bcda685 6128
0bcda685 6129
0bcda685 6130
0bcda685 6131
0bcda685 6132
b686ecb5
JM
6133if test -n "$ac_tool_prefix"; then
6134 # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
6135set dummy ${ac_tool_prefix}objdump; ac_word=$2
6136{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6137$as_echo_n "checking for $ac_word... " >&6; }
6138if ${ac_cv_prog_OBJDUMP+:} false; then :
6139 $as_echo_n "(cached) " >&6
6140else
6141 if test -n "$OBJDUMP"; then
6142 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
6143else
6144as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6145for as_dir in $PATH
6146do
6147 IFS=$as_save_IFS
6148 test -z "$as_dir" && as_dir=.
6149 for ac_exec_ext in '' $ac_executable_extensions; do
6150 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6151 ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
6152 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6153 break 2
6154 fi
6155done
6156 done
6157IFS=$as_save_IFS
0bcda685 6158
b686ecb5
JM
6159fi
6160fi
6161OBJDUMP=$ac_cv_prog_OBJDUMP
6162if test -n "$OBJDUMP"; then
6163 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
6164$as_echo "$OBJDUMP" >&6; }
6165else
6166 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6167$as_echo "no" >&6; }
6168fi
0bcda685 6169
0bcda685 6170
b686ecb5
JM
6171fi
6172if test -z "$ac_cv_prog_OBJDUMP"; then
6173 ac_ct_OBJDUMP=$OBJDUMP
6174 # Extract the first word of "objdump", so it can be a program name with args.
6175set dummy objdump; ac_word=$2
6176{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6177$as_echo_n "checking for $ac_word... " >&6; }
6178if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
6179 $as_echo_n "(cached) " >&6
6180else
6181 if test -n "$ac_ct_OBJDUMP"; then
6182 ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
6183else
6184as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6185for as_dir in $PATH
6186do
6187 IFS=$as_save_IFS
6188 test -z "$as_dir" && as_dir=.
6189 for ac_exec_ext in '' $ac_executable_extensions; do
6190 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6191 ac_cv_prog_ac_ct_OBJDUMP="objdump"
6192 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6193 break 2
6194 fi
6195done
6196 done
6197IFS=$as_save_IFS
0bcda685 6198
b686ecb5
JM
6199fi
6200fi
6201ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
6202if test -n "$ac_ct_OBJDUMP"; then
6203 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
6204$as_echo "$ac_ct_OBJDUMP" >&6; }
6205else
6206 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6207$as_echo "no" >&6; }
6208fi
0bcda685 6209
b686ecb5
JM
6210 if test "x$ac_ct_OBJDUMP" = x; then
6211 OBJDUMP="false"
6212 else
6213 case $cross_compiling:$ac_tool_warned in
6214yes:)
6215{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6216$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6217ac_tool_warned=yes ;;
6218esac
6219 OBJDUMP=$ac_ct_OBJDUMP
6220 fi
6221else
6222 OBJDUMP="$ac_cv_prog_OBJDUMP"
6223fi
0bcda685 6224
b686ecb5 6225test -z "$OBJDUMP" && OBJDUMP=objdump
0bcda685 6226
0bcda685 6227
0bcda685 6228
0bcda685 6229
0bcda685 6230
0bcda685 6231
0bcda685 6232
0bcda685 6233
0bcda685 6234
b686ecb5
JM
6235{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5
6236$as_echo_n "checking how to recognize dependent libraries... " >&6; }
6237if ${lt_cv_deplibs_check_method+:} false; then :
6238 $as_echo_n "(cached) " >&6
6239else
6240 lt_cv_file_magic_cmd='$MAGIC_CMD'
6241lt_cv_file_magic_test_file=
6242lt_cv_deplibs_check_method='unknown'
6243# Need to set the preceding variable on all platforms that support
6244# interlibrary dependencies.
6245# 'none' -- dependencies not supported.
6246# `unknown' -- same as none, but documents that we really don't know.
6247# 'pass_all' -- all dependencies passed with no checks.
6248# 'test_compile' -- check by making test program.
6249# 'file_magic [[regex]]' -- check by looking for files in library path
6250# which responds to the $file_magic_cmd with a given extended regex.
6251# If you have `file' or equivalent on your system and you're not sure
6252# whether `pass_all' will *always* work, you probably want this one.
0bcda685 6253
b686ecb5
JM
6254case $host_os in
6255aix[4-9]*)
6256 lt_cv_deplibs_check_method=pass_all
6257 ;;
0bcda685 6258
b686ecb5
JM
6259beos*)
6260 lt_cv_deplibs_check_method=pass_all
6261 ;;
0bcda685 6262
b686ecb5
JM
6263bsdi[45]*)
6264 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
6265 lt_cv_file_magic_cmd='/usr/bin/file -L'
6266 lt_cv_file_magic_test_file=/shlib/libc.so
6267 ;;
0bcda685 6268
b686ecb5
JM
6269cygwin*)
6270 # func_win32_libid is a shell function defined in ltmain.sh
6271 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
6272 lt_cv_file_magic_cmd='func_win32_libid'
6273 ;;
0bcda685 6274
b686ecb5
JM
6275mingw* | pw32*)
6276 # Base MSYS/MinGW do not provide the 'file' command needed by
6277 # func_win32_libid shell function, so use a weaker test based on 'objdump',
6278 # unless we find 'file', for example because we are cross-compiling.
6279 # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin.
6280 if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then
6281 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
6282 lt_cv_file_magic_cmd='func_win32_libid'
6283 else
6284 lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
6285 lt_cv_file_magic_cmd='$OBJDUMP -f'
6286 fi
6287 ;;
0bcda685 6288
b686ecb5
JM
6289cegcc*)
6290 # use the weaker test based on 'objdump'. See mingw*.
6291 lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
6292 lt_cv_file_magic_cmd='$OBJDUMP -f'
6293 ;;
0bcda685 6294
b686ecb5
JM
6295darwin* | rhapsody*)
6296 lt_cv_deplibs_check_method=pass_all
6297 ;;
0bcda685 6298
b686ecb5
JM
6299freebsd* | dragonfly*)
6300 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
6301 case $host_cpu in
6302 i*86 )
6303 # Not sure whether the presence of OpenBSD here was a mistake.
6304 # Let's accept both of them until this is cleared up.
6305 lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library'
6306 lt_cv_file_magic_cmd=/usr/bin/file
6307 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
6308 ;;
6309 esac
6310 else
6311 lt_cv_deplibs_check_method=pass_all
6312 fi
6313 ;;
0bcda685 6314
b686ecb5
JM
6315gnu*)
6316 lt_cv_deplibs_check_method=pass_all
6317 ;;
0bcda685 6318
b686ecb5
JM
6319haiku*)
6320 lt_cv_deplibs_check_method=pass_all
6321 ;;
0bcda685 6322
b686ecb5
JM
6323hpux10.20* | hpux11*)
6324 lt_cv_file_magic_cmd=/usr/bin/file
6325 case $host_cpu in
6326 ia64*)
6327 lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64'
6328 lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
6329 ;;
6330 hppa*64*)
6331 lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]'
6332 lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
6333 ;;
6334 *)
6335 lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library'
6336 lt_cv_file_magic_test_file=/usr/lib/libc.sl
6337 ;;
6338 esac
6339 ;;
0bcda685 6340
b686ecb5
JM
6341interix[3-9]*)
6342 # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
6343 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$'
6344 ;;
0bcda685 6345
b686ecb5
JM
6346irix5* | irix6* | nonstopux*)
6347 case $LD in
6348 *-32|*"-32 ") libmagic=32-bit;;
6349 *-n32|*"-n32 ") libmagic=N32;;
6350 *-64|*"-64 ") libmagic=64-bit;;
6351 *) libmagic=never-match;;
6352 esac
6353 lt_cv_deplibs_check_method=pass_all
6354 ;;
0bcda685 6355
b686ecb5
JM
6356# This must be Linux ELF.
6357linux* | k*bsd*-gnu | kopensolaris*-gnu)
6358 lt_cv_deplibs_check_method=pass_all
6359 ;;
0bcda685 6360
b686ecb5
JM
6361netbsd*)
6362 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
6363 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
6364 else
6365 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$'
6366 fi
6367 ;;
0bcda685 6368
b686ecb5
JM
6369newos6*)
6370 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
6371 lt_cv_file_magic_cmd=/usr/bin/file
6372 lt_cv_file_magic_test_file=/usr/lib/libnls.so
6373 ;;
0bcda685 6374
b686ecb5
JM
6375*nto* | *qnx*)
6376 lt_cv_deplibs_check_method=pass_all
6377 ;;
0bcda685 6378
b686ecb5
JM
6379openbsd*)
6380 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
6381 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$'
6382 else
6383 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
6384 fi
6385 ;;
0bcda685 6386
b686ecb5
JM
6387osf3* | osf4* | osf5*)
6388 lt_cv_deplibs_check_method=pass_all
6389 ;;
0bcda685 6390
b686ecb5
JM
6391rdos*)
6392 lt_cv_deplibs_check_method=pass_all
6393 ;;
0bcda685 6394
b686ecb5
JM
6395solaris*)
6396 lt_cv_deplibs_check_method=pass_all
6397 ;;
0bcda685 6398
b686ecb5
JM
6399sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
6400 lt_cv_deplibs_check_method=pass_all
6401 ;;
0bcda685 6402
b686ecb5
JM
6403sysv4 | sysv4.3*)
6404 case $host_vendor in
6405 motorola)
6406 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]'
6407 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
6408 ;;
6409 ncr)
6410 lt_cv_deplibs_check_method=pass_all
6411 ;;
6412 sequent)
6413 lt_cv_file_magic_cmd='/bin/file'
6414 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
6415 ;;
6416 sni)
6417 lt_cv_file_magic_cmd='/bin/file'
6418 lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"
6419 lt_cv_file_magic_test_file=/lib/libc.so
6420 ;;
6421 siemens)
6422 lt_cv_deplibs_check_method=pass_all
6423 ;;
6424 pc)
6425 lt_cv_deplibs_check_method=pass_all
6426 ;;
6427 esac
6428 ;;
0bcda685 6429
b686ecb5
JM
6430tpf*)
6431 lt_cv_deplibs_check_method=pass_all
6432 ;;
6433esac
0bcda685 6434
b686ecb5
JM
6435fi
6436{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
6437$as_echo "$lt_cv_deplibs_check_method" >&6; }
6438file_magic_cmd=$lt_cv_file_magic_cmd
6439deplibs_check_method=$lt_cv_deplibs_check_method
6440test -z "$deplibs_check_method" && deplibs_check_method=unknown
0bcda685 6441
0bcda685 6442
0bcda685 6443
0bcda685
PA
6444
6445
6446
0bcda685 6447
0bcda685 6448
0bcda685 6449
0bcda685
PA
6450
6451
6452
b686ecb5
JM
6453plugin_option=
6454plugin_names="liblto_plugin.so liblto_plugin-0.dll cyglto_plugin-0.dll"
6455for plugin in $plugin_names; do
6456 plugin_so=`${CC} ${CFLAGS} --print-prog-name $plugin`
6457 if test x$plugin_so = x$plugin; then
6458 plugin_so=`${CC} ${CFLAGS} --print-file-name $plugin`
6459 fi
6460 if test x$plugin_so != x$plugin; then
6461 plugin_option="--plugin $plugin_so"
6462 break
6463 fi
6464done
0bcda685 6465
b686ecb5
JM
6466if test -n "$ac_tool_prefix"; then
6467 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
6468set dummy ${ac_tool_prefix}ar; ac_word=$2
6469{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6470$as_echo_n "checking for $ac_word... " >&6; }
6471if ${ac_cv_prog_AR+:} false; then :
6472 $as_echo_n "(cached) " >&6
a417dc56 6473else
b686ecb5
JM
6474 if test -n "$AR"; then
6475 ac_cv_prog_AR="$AR" # Let the user override the test.
6476else
6477as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6478for as_dir in $PATH
6479do
6480 IFS=$as_save_IFS
6481 test -z "$as_dir" && as_dir=.
6482 for ac_exec_ext in '' $ac_executable_extensions; do
6483 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6484 ac_cv_prog_AR="${ac_tool_prefix}ar"
6485 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6486 break 2
6487 fi
6488done
6489 done
6490IFS=$as_save_IFS
a417dc56 6491
b686ecb5
JM
6492fi
6493fi
6494AR=$ac_cv_prog_AR
6495if test -n "$AR"; then
6496 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
6497$as_echo "$AR" >&6; }
6498else
6499 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6500$as_echo "no" >&6; }
6501fi
a417dc56 6502
a417dc56 6503
b686ecb5
JM
6504fi
6505if test -z "$ac_cv_prog_AR"; then
6506 ac_ct_AR=$AR
6507 # Extract the first word of "ar", so it can be a program name with args.
6508set dummy ar; ac_word=$2
6509{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6510$as_echo_n "checking for $ac_word... " >&6; }
6511if ${ac_cv_prog_ac_ct_AR+:} false; then :
81ecdfbb 6512 $as_echo_n "(cached) " >&6
a417dc56 6513else
b686ecb5
JM
6514 if test -n "$ac_ct_AR"; then
6515 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
6516else
6517as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6518for as_dir in $PATH
6519do
6520 IFS=$as_save_IFS
6521 test -z "$as_dir" && as_dir=.
6522 for ac_exec_ext in '' $ac_executable_extensions; do
6523 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6524 ac_cv_prog_ac_ct_AR="ar"
6525 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6526 break 2
a417dc56 6527 fi
b686ecb5 6528done
a417dc56 6529 done
b686ecb5 6530IFS=$as_save_IFS
a417dc56 6531
b686ecb5
JM
6532fi
6533fi
6534ac_ct_AR=$ac_cv_prog_ac_ct_AR
6535if test -n "$ac_ct_AR"; then
6536 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
6537$as_echo "$ac_ct_AR" >&6; }
a417dc56 6538else
b686ecb5
JM
6539 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6540$as_echo "no" >&6; }
a417dc56
RW
6541fi
6542
b686ecb5
JM
6543 if test "x$ac_ct_AR" = x; then
6544 AR="false"
6545 else
6546 case $cross_compiling:$ac_tool_warned in
6547yes:)
6548{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6549$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6550ac_tool_warned=yes ;;
6551esac
6552 AR=$ac_ct_AR
6553 fi
6554else
6555 AR="$ac_cv_prog_AR"
a417dc56 6556fi
a417dc56 6557
b686ecb5
JM
6558test -z "$AR" && AR=ar
6559if test -n "$plugin_option"; then
6560 if $AR --help 2>&1 | grep -q "\--plugin"; then
6561 touch conftest.c
6562 $AR $plugin_option rc conftest.a conftest.c
6563 if test "$?" != 0; then
6564 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
6565$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
6566 else
6567 AR="$AR $plugin_option"
6568 fi
6569 rm -f conftest.*
6570 fi
a417dc56 6571fi
b686ecb5 6572test -z "$AR_FLAGS" && AR_FLAGS=cru
a417dc56
RW
6573
6574
c971b7fa 6575
c971b7fa 6576
c971b7fa 6577
783e057b 6578
783e057b 6579
783e057b
DJ
6580
6581
c971b7fa 6582
c971b7fa 6583
b686ecb5
JM
6584if test -n "$ac_tool_prefix"; then
6585 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
6586set dummy ${ac_tool_prefix}strip; ac_word=$2
6587{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6588$as_echo_n "checking for $ac_word... " >&6; }
6589if ${ac_cv_prog_STRIP+:} false; then :
6590 $as_echo_n "(cached) " >&6
6591else
6592 if test -n "$STRIP"; then
6593 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
6594else
6595as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6596for as_dir in $PATH
6597do
6598 IFS=$as_save_IFS
6599 test -z "$as_dir" && as_dir=.
6600 for ac_exec_ext in '' $ac_executable_extensions; do
6601 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6602 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
6603 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6604 break 2
6605 fi
6606done
6607 done
6608IFS=$as_save_IFS
e28b3332 6609
e28b3332 6610fi
b686ecb5
JM
6611fi
6612STRIP=$ac_cv_prog_STRIP
6613if test -n "$STRIP"; then
6614 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
6615$as_echo "$STRIP" >&6; }
6616else
6617 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6618$as_echo "no" >&6; }
6619fi
e28b3332 6620
c971b7fa 6621
b686ecb5
JM
6622fi
6623if test -z "$ac_cv_prog_STRIP"; then
6624 ac_ct_STRIP=$STRIP
6625 # Extract the first word of "strip", so it can be a program name with args.
6626set dummy strip; ac_word=$2
6627{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6628$as_echo_n "checking for $ac_word... " >&6; }
6629if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
6630 $as_echo_n "(cached) " >&6
6631else
6632 if test -n "$ac_ct_STRIP"; then
6633 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
6634else
6635as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6636for as_dir in $PATH
6637do
6638 IFS=$as_save_IFS
6639 test -z "$as_dir" && as_dir=.
6640 for ac_exec_ext in '' $ac_executable_extensions; do
6641 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6642 ac_cv_prog_ac_ct_STRIP="strip"
6643 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6644 break 2
6645 fi
6646done
6647 done
6648IFS=$as_save_IFS
c971b7fa 6649
b686ecb5
JM
6650fi
6651fi
6652ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
6653if test -n "$ac_ct_STRIP"; then
6654 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
6655$as_echo "$ac_ct_STRIP" >&6; }
6656else
6657 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6658$as_echo "no" >&6; }
e28b3332 6659fi
e28b3332 6660
b686ecb5
JM
6661 if test "x$ac_ct_STRIP" = x; then
6662 STRIP=":"
6663 else
6664 case $cross_compiling:$ac_tool_warned in
6665yes:)
6666{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6667$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6668ac_tool_warned=yes ;;
6669esac
6670 STRIP=$ac_ct_STRIP
6671 fi
6672else
6673 STRIP="$ac_cv_prog_STRIP"
6674fi
c971b7fa 6675
b686ecb5 6676test -z "$STRIP" && STRIP=:
c971b7fa
PA
6677
6678
6679
c971b7fa
PA
6680
6681
6682
b686ecb5
JM
6683if test -n "$ac_tool_prefix"; then
6684 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
6685set dummy ${ac_tool_prefix}ranlib; ac_word=$2
6686{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6687$as_echo_n "checking for $ac_word... " >&6; }
6688if ${ac_cv_prog_RANLIB+:} false; then :
c971b7fa
PA
6689 $as_echo_n "(cached) " >&6
6690else
b686ecb5
JM
6691 if test -n "$RANLIB"; then
6692 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
6693else
6694as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6695for as_dir in $PATH
6696do
6697 IFS=$as_save_IFS
6698 test -z "$as_dir" && as_dir=.
6699 for ac_exec_ext in '' $ac_executable_extensions; do
6700 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6701 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
6702 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6703 break 2
c971b7fa 6704 fi
b686ecb5
JM
6705done
6706 done
6707IFS=$as_save_IFS
6708
c971b7fa 6709fi
b686ecb5
JM
6710fi
6711RANLIB=$ac_cv_prog_RANLIB
6712if test -n "$RANLIB"; then
6713 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
6714$as_echo "$RANLIB" >&6; }
6715else
6716 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6717$as_echo "no" >&6; }
c971b7fa 6718fi
e28b3332
DJ
6719
6720
b686ecb5
JM
6721fi
6722if test -z "$ac_cv_prog_RANLIB"; then
6723 ac_ct_RANLIB=$RANLIB
6724 # Extract the first word of "ranlib", so it can be a program name with args.
6725set dummy ranlib; ac_word=$2
6726{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6727$as_echo_n "checking for $ac_word... " >&6; }
6728if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
6729 $as_echo_n "(cached) " >&6
6730else
6731 if test -n "$ac_ct_RANLIB"; then
6732 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6733else
6734as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6735for as_dir in $PATH
6736do
6737 IFS=$as_save_IFS
6738 test -z "$as_dir" && as_dir=.
6739 for ac_exec_ext in '' $ac_executable_extensions; do
6740 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6741 ac_cv_prog_ac_ct_RANLIB="ranlib"
6742 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6743 break 2
6744 fi
6745done
6746 done
6747IFS=$as_save_IFS
bec39cab 6748
b686ecb5
JM
6749fi
6750fi
6751ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6752if test -n "$ac_ct_RANLIB"; then
6753 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
6754$as_echo "$ac_ct_RANLIB" >&6; }
6755else
6756 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6757$as_echo "no" >&6; }
6758fi
bec39cab 6759
b686ecb5
JM
6760 if test "x$ac_ct_RANLIB" = x; then
6761 RANLIB=":"
6762 else
6763 case $cross_compiling:$ac_tool_warned in
6764yes:)
6765{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6766$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6767ac_tool_warned=yes ;;
6768esac
6769 RANLIB=$ac_ct_RANLIB
6770 fi
b14b1491 6771else
b686ecb5 6772 RANLIB="$ac_cv_prog_RANLIB"
81ecdfbb
RW
6773fi
6774
b686ecb5
JM
6775test -z "$RANLIB" && RANLIB=:
6776if test -n "$plugin_option" && test "$RANLIB" != ":"; then
6777 if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
6778 RANLIB="$RANLIB $plugin_option"
6779 fi
6780fi
20e95c23 6781
20e95c23 6782
20e95c23 6783
20e95c23 6784
20e95c23 6785
0c4a4063 6786
b686ecb5
JM
6787# Determine commands to create old-style static archives.
6788old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
6789old_postinstall_cmds='chmod 644 $oldlib'
6790old_postuninstall_cmds=
6791
6792if test -n "$RANLIB"; then
6793 case $host_os in
6794 openbsd*)
6795 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
6796 ;;
6797 *)
6798 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
6799 ;;
b14b1491 6800 esac
b686ecb5
JM
6801 old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
6802fi
b14b1491 6803
b686ecb5
JM
6804case $host_os in
6805 darwin*)
6806 lock_old_archive_extraction=yes ;;
6807 *)
6808 lock_old_archive_extraction=no ;;
6809esac
b14b1491
TT
6810
6811
6812
0c4a4063 6813
f83d8a90 6814
f83d8a90 6815
f83d8a90
DE
6816
6817
6818
b14b1491
TT
6819
6820
6821
81ecdfbb 6822
20e95c23 6823
b14b1491 6824
20e95c23 6825
b14b1491
TT
6826
6827
0c4a4063 6828
b686ecb5
JM
6829
6830
6831for ac_prog in gawk mawk nawk awk
6832do
6833 # Extract the first word of "$ac_prog", so it can be a program name with args.
6834set dummy $ac_prog; ac_word=$2
6835{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6836$as_echo_n "checking for $ac_word... " >&6; }
6837if ${ac_cv_prog_AWK+:} false; then :
6838 $as_echo_n "(cached) " >&6
6839else
6840 if test -n "$AWK"; then
6841 ac_cv_prog_AWK="$AWK" # Let the user override the test.
6842else
6843as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6844for as_dir in $PATH
6845do
6846 IFS=$as_save_IFS
6847 test -z "$as_dir" && as_dir=.
6848 for ac_exec_ext in '' $ac_executable_extensions; do
6849 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6850 ac_cv_prog_AWK="$ac_prog"
6851 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6852 break 2
b14b1491 6853 fi
b686ecb5
JM
6854done
6855 done
6856IFS=$as_save_IFS
b14b1491 6857
b686ecb5
JM
6858fi
6859fi
6860AWK=$ac_cv_prog_AWK
6861if test -n "$AWK"; then
6862 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
6863$as_echo "$AWK" >&6; }
6864else
6865 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6866$as_echo "no" >&6; }
6867fi
b14b1491
TT
6868
6869
b686ecb5
JM
6870 test -n "$AWK" && break
6871done
783e057b 6872
20e95c23 6873
0c4a4063 6874
29b0e8a2 6875
29b0e8a2 6876
29b0e8a2
JM
6877
6878
6879
81ecdfbb 6880
29b0e8a2 6881
7349ff92 6882
7349ff92 6883
7349ff92 6884
7349ff92 6885
7349ff92
JK
6886
6887
7349ff92 6888
bccbefd2 6889
bccbefd2 6890
b686ecb5
JM
6891# If no C compiler was specified, use CC.
6892LTCC=${LTCC-"$CC"}
bccbefd2 6893
b686ecb5
JM
6894# If no C compiler flags were specified, use CFLAGS.
6895LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
bccbefd2 6896
b686ecb5
JM
6897# Allow CC to be a program name with arguments.
6898compiler=$CC
bccbefd2
JK
6899
6900
b686ecb5
JM
6901# Check for command to grab the raw symbol name followed by C symbol from nm.
6902{ $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5
6903$as_echo_n "checking command to parse $NM output from $compiler object... " >&6; }
6904if ${lt_cv_sys_global_symbol_pipe+:} false; then :
6905 $as_echo_n "(cached) " >&6
6906else
bccbefd2 6907
b686ecb5
JM
6908# These are sane defaults that work on at least a few old systems.
6909# [They come from Ultrix. What could be older than Ultrix?!! ;)]
29b0e8a2 6910
b686ecb5
JM
6911# Character class describing NM global symbol codes.
6912symcode='[BCDEGRST]'
20e95c23 6913
b686ecb5
JM
6914# Regexp to match symbols that can be accessed directly from C.
6915sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
20e95c23 6916
b686ecb5
JM
6917# Define system-specific variables.
6918case $host_os in
6919aix*)
6920 symcode='[BCDT]'
6921 ;;
6922cygwin* | mingw* | pw32* | cegcc*)
6923 symcode='[ABCDGISTW]'
6924 ;;
6925hpux*)
6926 if test "$host_cpu" = ia64; then
6927 symcode='[ABCDEGRST]'
6928 fi
6929 ;;
6930irix* | nonstopux*)
6931 symcode='[BCDEGRST]'
6932 ;;
6933osf*)
6934 symcode='[BCDEGQRST]'
6935 ;;
6936solaris*)
6937 symcode='[BCDRT]'
6938 ;;
6939sco3.2v5*)
6940 symcode='[DT]'
6941 ;;
6942sysv4.2uw2*)
6943 symcode='[DT]'
6944 ;;
6945sysv5* | sco5v6* | unixware* | OpenUNIX*)
6946 symcode='[ABDT]'
6947 ;;
6948sysv4)
6949 symcode='[DFNSTU]'
6950 ;;
6951esac
20e95c23 6952
b686ecb5
JM
6953# If we're using GNU nm, then use its standard symbol codes.
6954case `$NM -V 2>&1` in
6955*GNU* | *'with BFD'*)
6956 symcode='[ABCDGIRSTW]' ;;
783e057b 6957esac
81ecdfbb 6958
b686ecb5
JM
6959# Transform an extracted symbol line into a proper C declaration.
6960# Some systems (esp. on ia64) link data and code symbols differently,
6961# so use this general approach.
6962lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
20e95c23 6963
b686ecb5
JM
6964# Transform an extracted symbol line into symbol name and symbol address
6965lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'"
6966lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"lib\2\", (void *) \&\2},/p'"
6967
6968# Handle CRLF in mingw tool chain
6969opt_cr=
6970case $build_os in
6971mingw*)
6972 opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
6973 ;;
783e057b 6974esac
1d5269c9 6975
b686ecb5
JM
6976# Try without a prefix underscore, then with it.
6977for ac_symprfx in "" "_"; do
6978
6979 # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
6980 symxfrm="\\1 $ac_symprfx\\2 \\2"
6981
6982 # Write the raw and C identifiers.
6983 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
6984 # Fake it for dumpbin and say T for any non-static function
6985 # and D for any global variable.
6986 # Also find C++ and __fastcall symbols from MSVC++,
6987 # which start with @ or ?.
6988 lt_cv_sys_global_symbol_pipe="$AWK '"\
6989" {last_section=section; section=\$ 3};"\
6990" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
6991" \$ 0!~/External *\|/{next};"\
6992" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
6993" {if(hide[section]) next};"\
6994" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\
6995" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\
6996" s[1]~/^[@?]/{print s[1], s[1]; next};"\
6997" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\
6998" ' prfx=^$ac_symprfx"
6999 else
7000 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
7001 fi
1d5269c9 7002
b686ecb5
JM
7003 # Check to see that the pipe works correctly.
7004 pipe_works=no
1d5269c9 7005
b686ecb5
JM
7006 rm -f conftest*
7007 cat > conftest.$ac_ext <<_LT_EOF
7008#ifdef __cplusplus
7009extern "C" {
7010#endif
7011char nm_test_var;
7012void nm_test_func(void);
7013void nm_test_func(void){}
7014#ifdef __cplusplus
7015}
7016#endif
7017int main(){nm_test_var='a';nm_test_func();return(0);}
7018_LT_EOF
1d5269c9 7019
b686ecb5
JM
7020 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
7021 (eval $ac_compile) 2>&5
7022 ac_status=$?
7023 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
7024 test $ac_status = 0; }; then
7025 # Now try to grab the symbols.
7026 nlist=conftest.nm
7027 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5
7028 (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5
7029 ac_status=$?
7030 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
7031 test $ac_status = 0; } && test -s "$nlist"; then
7032 # Try sorting and uniquifying the output.
7033 if sort "$nlist" | uniq > "$nlist"T; then
7034 mv -f "$nlist"T "$nlist"
7035 else
7036 rm -f "$nlist"T
7037 fi
1d5269c9 7038
b686ecb5
JM
7039 # Make sure that we snagged all the symbols we need.
7040 if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
7041 if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
7042 cat <<_LT_EOF > conftest.$ac_ext
7043#ifdef __cplusplus
7044extern "C" {
7045#endif
1d5269c9 7046
b686ecb5
JM
7047_LT_EOF
7048 # Now generate the symbol file.
7049 eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
1d5269c9 7050
b686ecb5 7051 cat <<_LT_EOF >> conftest.$ac_ext
1d5269c9 7052
b686ecb5
JM
7053/* The mapping between symbol names and symbols. */
7054const struct {
7055 const char *name;
7056 void *address;
7057}
7058lt__PROGRAM__LTX_preloaded_symbols[] =
7059{
7060 { "@PROGRAM@", (void *) 0 },
7061_LT_EOF
7062 $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
7063 cat <<\_LT_EOF >> conftest.$ac_ext
7064 {0, (void *) 0}
7065};
7066
7067/* This works around a problem in FreeBSD linker */
7068#ifdef FREEBSD_WORKAROUND
7069static const void *lt_preloaded_setup() {
7070 return lt__PROGRAM__LTX_preloaded_symbols;
7071}
7072#endif
1d5269c9 7073
b686ecb5
JM
7074#ifdef __cplusplus
7075}
7076#endif
7077_LT_EOF
7078 # Now try linking the two files.
7079 mv conftest.$ac_objext conftstm.$ac_objext
7080 lt_save_LIBS="$LIBS"
7081 lt_save_CFLAGS="$CFLAGS"
7082 LIBS="conftstm.$ac_objext"
7083 CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
7084 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
7085 (eval $ac_link) 2>&5
7086 ac_status=$?
7087 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
7088 test $ac_status = 0; } && test -s conftest${ac_exeext}; then
7089 pipe_works=yes
7090 fi
7091 LIBS="$lt_save_LIBS"
7092 CFLAGS="$lt_save_CFLAGS"
7093 else
7094 echo "cannot find nm_test_func in $nlist" >&5
7095 fi
7096 else
7097 echo "cannot find nm_test_var in $nlist" >&5
7098 fi
7099 else
7100 echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5
7101 fi
7102 else
7103 echo "$progname: failed program was:" >&5
7104 cat conftest.$ac_ext >&5
7105 fi
7106 rm -rf conftest* conftst*
7107
7108 # Do not use the global_symbol_pipe unless it works.
7109 if test "$pipe_works" = yes; then
7110 break
7111 else
7112 lt_cv_sys_global_symbol_pipe=
7113 fi
7114done
1d5269c9
MF
7115
7116fi
7117
b686ecb5
JM
7118if test -z "$lt_cv_sys_global_symbol_pipe"; then
7119 lt_cv_sys_global_symbol_to_cdecl=
7120fi
7121if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
7122 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
7123$as_echo "failed" >&6; }
1d5269c9 7124else
b686ecb5
JM
7125 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
7126$as_echo "ok" >&6; }
81ecdfbb
RW
7127fi
7128
1d5269c9
MF
7129
7130
20e95c23
DJ
7131
7132
7133
7134
7135
bf307134 7136
b292c783 7137
20e95c23 7138
c0993dbe
UW
7139
7140
7141
b292c783 7142
c0993dbe 7143
c0993dbe 7144
c0993dbe 7145
c0993dbe 7146
c0993dbe 7147
c0993dbe 7148
c0993dbe 7149
b686ecb5
JM
7150# Check whether --enable-libtool-lock was given.
7151if test "${enable_libtool_lock+set}" = set; then :
7152 enableval=$enable_libtool_lock;
c0993dbe
UW
7153fi
7154
b686ecb5 7155test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
81ecdfbb 7156
b686ecb5
JM
7157# Some flags need to be propagated to the compiler or linker for good
7158# libtool support.
7159case $host in
7160ia64-*-hpux*)
7161 # Find out which ABI we are using.
7162 echo 'int i;' > conftest.$ac_ext
7163 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
7164 (eval $ac_compile) 2>&5
7165 ac_status=$?
7166 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
7167 test $ac_status = 0; }; then
7168 case `/usr/bin/file conftest.$ac_objext` in
7169 *ELF-32*)
7170 HPUX_IA64_MODE="32"
7171 ;;
7172 *ELF-64*)
7173 HPUX_IA64_MODE="64"
7174 ;;
7175 esac
c0993dbe 7176 fi
b686ecb5
JM
7177 rm -rf conftest*
7178 ;;
7179*-*-irix6*)
7180 # Find out which ABI we are using.
7181 echo '#line '$LINENO' "configure"' > conftest.$ac_ext
7182 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
7183 (eval $ac_compile) 2>&5
7184 ac_status=$?
7185 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
7186 test $ac_status = 0; }; then
7187 if test "$lt_cv_prog_gnu_ld" = yes; then
7188 case `/usr/bin/file conftest.$ac_objext` in
7189 *32-bit*)
7190 LD="${LD-ld} -melf32bsmip"
7191 ;;
7192 *N32*)
7193 LD="${LD-ld} -melf32bmipn32"
7194 ;;
7195 *64-bit*)
7196 LD="${LD-ld} -melf64bmip"
7197 ;;
7198 esac
7199 else
7200 case `/usr/bin/file conftest.$ac_objext` in
7201 *32-bit*)
7202 LD="${LD-ld} -32"
7203 ;;
7204 *N32*)
7205 LD="${LD-ld} -n32"
7206 ;;
7207 *64-bit*)
7208 LD="${LD-ld} -64"
7209 ;;
7210 esac
7211 fi
7212 fi
7213 rm -rf conftest*
7214 ;;
c0993dbe 7215
b686ecb5
JM
7216x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \
7217s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
7218 # Find out which ABI we are using.
7219 echo 'int i;' > conftest.$ac_ext
7220 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
7221 (eval $ac_compile) 2>&5
7222 ac_status=$?
7223 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
7224 test $ac_status = 0; }; then
7225 case `/usr/bin/file conftest.o` in
7226 *32-bit*)
7227 case $host in
7228 x86_64-*kfreebsd*-gnu)
7229 LD="${LD-ld} -m elf_i386_fbsd"
7230 ;;
7231 x86_64-*linux*)
7232 case `/usr/bin/file conftest.o` in
7233 *x86-64*)
7234 LD="${LD-ld} -m elf32_x86_64"
7235 ;;
7236 *)
7237 LD="${LD-ld} -m elf_i386"
7238 ;;
7239 esac
7240 ;;
7241 powerpc64le-*linux*)
7242 LD="${LD-ld} -m elf32lppclinux"
7243 ;;
7244 powerpc64-*linux*)
7245 LD="${LD-ld} -m elf32ppclinux"
7246 ;;
7247 s390x-*linux*)
7248 LD="${LD-ld} -m elf_s390"
7249 ;;
7250 sparc64-*linux*)
7251 LD="${LD-ld} -m elf32_sparc"
7252 ;;
7253 esac
7254 ;;
7255 *64-bit*)
7256 case $host in
7257 x86_64-*kfreebsd*-gnu)
7258 LD="${LD-ld} -m elf_x86_64_fbsd"
7259 ;;
7260 x86_64-*linux*)
7261 LD="${LD-ld} -m elf_x86_64"
7262 ;;
7263 powerpcle-*linux*)
7264 LD="${LD-ld} -m elf64lppc"
7265 ;;
7266 powerpc-*linux*)
7267 LD="${LD-ld} -m elf64ppc"
7268 ;;
7269 s390*-*linux*|s390*-*tpf*)
7270 LD="${LD-ld} -m elf64_s390"
7271 ;;
7272 sparc*-*linux*)
7273 LD="${LD-ld} -m elf64_sparc"
7274 ;;
7275 esac
7276 ;;
7277 esac
7278 fi
7279 rm -rf conftest*
7280 ;;
4fd404c2 7281
b686ecb5
JM
7282*-*-sco3.2v5*)
7283 # On SCO OpenServer 5, we need -belf to get full-featured binaries.
7284 SAVE_CFLAGS="$CFLAGS"
7285 CFLAGS="$CFLAGS -belf"
7286 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5
7287$as_echo_n "checking whether the C compiler needs -belf... " >&6; }
7288if ${lt_cv_cc_needs_belf+:} false; then :
7289 $as_echo_n "(cached) " >&6
c0993dbe 7290else
b686ecb5
JM
7291 ac_ext=c
7292ac_cpp='$CPP $CPPFLAGS'
7293ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7294ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7295ac_compiler_gnu=$ac_cv_c_compiler_gnu
81ecdfbb 7296
b686ecb5
JM
7297 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7298/* end confdefs.h. */
c0993dbe 7299
b686ecb5
JM
7300int
7301main ()
7302{
4fd404c2 7303
b686ecb5
JM
7304 ;
7305 return 0;
7306}
7307_ACEOF
7308if ac_fn_c_try_link "$LINENO"; then :
7309 lt_cv_cc_needs_belf=yes
c0993dbe 7310else
b686ecb5 7311 lt_cv_cc_needs_belf=no
81ecdfbb 7312fi
b686ecb5
JM
7313rm -f core conftest.err conftest.$ac_objext \
7314 conftest$ac_exeext conftest.$ac_ext
7315 ac_ext=c
7316ac_cpp='$CPP $CPPFLAGS'
7317ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7318ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7319ac_compiler_gnu=$ac_cv_c_compiler_gnu
81ecdfbb 7320
b686ecb5
JM
7321fi
7322{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5
7323$as_echo "$lt_cv_cc_needs_belf" >&6; }
7324 if test x"$lt_cv_cc_needs_belf" != x"yes"; then
7325 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
7326 CFLAGS="$SAVE_CFLAGS"
7327 fi
7328 ;;
7329sparc*-*solaris*)
7330 # Find out which ABI we are using.
7331 echo 'int i;' > conftest.$ac_ext
7332 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
7333 (eval $ac_compile) 2>&5
7334 ac_status=$?
7335 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
7336 test $ac_status = 0; }; then
7337 case `/usr/bin/file conftest.o` in
7338 *64-bit*)
7339 case $lt_cv_prog_gnu_ld in
7340 yes*) LD="${LD-ld} -m elf64_sparc" ;;
7341 *)
7342 if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
7343 LD="${LD-ld} -64"
7344 fi
7345 ;;
7346 esac
7347 ;;
7348 esac
7349 fi
7350 rm -rf conftest*
7351 ;;
c0993dbe
UW
7352esac
7353
b686ecb5 7354need_locks="$enable_libtool_lock"
f6720b1c
AM
7355
7356
b686ecb5
JM
7357 case $host_os in
7358 rhapsody* | darwin*)
7359 if test -n "$ac_tool_prefix"; then
7360 # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args.
7361set dummy ${ac_tool_prefix}dsymutil; ac_word=$2
f6720b1c
AM
7362{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7363$as_echo_n "checking for $ac_word... " >&6; }
b686ecb5 7364if ${ac_cv_prog_DSYMUTIL+:} false; then :
f6720b1c
AM
7365 $as_echo_n "(cached) " >&6
7366else
b686ecb5
JM
7367 if test -n "$DSYMUTIL"; then
7368 ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
7369else
7370as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
f6720b1c
AM
7371for as_dir in $PATH
7372do
7373 IFS=$as_save_IFS
7374 test -z "$as_dir" && as_dir=.
7375 for ac_exec_ext in '' $ac_executable_extensions; do
7376 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
b686ecb5 7377 ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil"
f6720b1c
AM
7378 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7379 break 2
7380 fi
7381done
7382 done
7383IFS=$as_save_IFS
7384
f6720b1c 7385fi
b686ecb5
JM
7386fi
7387DSYMUTIL=$ac_cv_prog_DSYMUTIL
7388if test -n "$DSYMUTIL"; then
7389 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
7390$as_echo "$DSYMUTIL" >&6; }
f6720b1c
AM
7391else
7392 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7393$as_echo "no" >&6; }
7394fi
7395
7396
7397fi
b686ecb5
JM
7398if test -z "$ac_cv_prog_DSYMUTIL"; then
7399 ac_ct_DSYMUTIL=$DSYMUTIL
7400 # Extract the first word of "dsymutil", so it can be a program name with args.
7401set dummy dsymutil; ac_word=$2
f6720b1c
AM
7402{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7403$as_echo_n "checking for $ac_word... " >&6; }
b686ecb5 7404if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then :
f6720b1c
AM
7405 $as_echo_n "(cached) " >&6
7406else
b686ecb5
JM
7407 if test -n "$ac_ct_DSYMUTIL"; then
7408 ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test.
7409else
7410as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
f6720b1c
AM
7411for as_dir in $PATH
7412do
7413 IFS=$as_save_IFS
7414 test -z "$as_dir" && as_dir=.
7415 for ac_exec_ext in '' $ac_executable_extensions; do
7416 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
b686ecb5 7417 ac_cv_prog_ac_ct_DSYMUTIL="dsymutil"
f6720b1c
AM
7418 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7419 break 2
7420 fi
7421done
7422 done
7423IFS=$as_save_IFS
7424
f6720b1c 7425fi
b686ecb5
JM
7426fi
7427ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL
7428if test -n "$ac_ct_DSYMUTIL"; then
7429 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5
7430$as_echo "$ac_ct_DSYMUTIL" >&6; }
f6720b1c
AM
7431else
7432 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7433$as_echo "no" >&6; }
7434fi
7435
b686ecb5
JM
7436 if test "x$ac_ct_DSYMUTIL" = x; then
7437 DSYMUTIL=":"
f6720b1c
AM
7438 else
7439 case $cross_compiling:$ac_tool_warned in
7440yes:)
7441{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7442$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7443ac_tool_warned=yes ;;
7444esac
b686ecb5 7445 DSYMUTIL=$ac_ct_DSYMUTIL
f6720b1c
AM
7446 fi
7447else
b686ecb5 7448 DSYMUTIL="$ac_cv_prog_DSYMUTIL"
f6720b1c
AM
7449fi
7450
b686ecb5
JM
7451 if test -n "$ac_tool_prefix"; then
7452 # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args.
7453set dummy ${ac_tool_prefix}nmedit; ac_word=$2
7454{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7455$as_echo_n "checking for $ac_word... " >&6; }
7456if ${ac_cv_prog_NMEDIT+:} false; then :
7457 $as_echo_n "(cached) " >&6
7458else
7459 if test -n "$NMEDIT"; then
7460 ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test.
7461else
7462as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7463for as_dir in $PATH
7464do
7465 IFS=$as_save_IFS
7466 test -z "$as_dir" && as_dir=.
7467 for ac_exec_ext in '' $ac_executable_extensions; do
7468 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7469 ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit"
7470 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7471 break 2
7472 fi
7473done
7474 done
7475IFS=$as_save_IFS
0d79cdc4 7476
b686ecb5
JM
7477fi
7478fi
7479NMEDIT=$ac_cv_prog_NMEDIT
7480if test -n "$NMEDIT"; then
7481 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5
7482$as_echo "$NMEDIT" >&6; }
0d79cdc4 7483else
b686ecb5
JM
7484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7485$as_echo "no" >&6; }
0d79cdc4
AM
7486fi
7487
f6720b1c 7488
b686ecb5
JM
7489fi
7490if test -z "$ac_cv_prog_NMEDIT"; then
7491 ac_ct_NMEDIT=$NMEDIT
7492 # Extract the first word of "nmedit", so it can be a program name with args.
7493set dummy nmedit; ac_word=$2
7494{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7495$as_echo_n "checking for $ac_word... " >&6; }
7496if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then :
7497 $as_echo_n "(cached) " >&6
0d79cdc4 7498else
b686ecb5
JM
7499 if test -n "$ac_ct_NMEDIT"; then
7500 ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test.
7501else
7502as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7503for as_dir in $PATH
7504do
7505 IFS=$as_save_IFS
7506 test -z "$as_dir" && as_dir=.
7507 for ac_exec_ext in '' $ac_executable_extensions; do
7508 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7509 ac_cv_prog_ac_ct_NMEDIT="nmedit"
7510 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7511 break 2
7512 fi
7513done
7514 done
7515IFS=$as_save_IFS
7516
0d79cdc4 7517fi
0d79cdc4 7518fi
b686ecb5
JM
7519ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT
7520if test -n "$ac_ct_NMEDIT"; then
7521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5
7522$as_echo "$ac_ct_NMEDIT" >&6; }
f6720b1c 7523else
b686ecb5
JM
7524 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7525$as_echo "no" >&6; }
0d79cdc4 7526fi
bec39cab 7527
b686ecb5
JM
7528 if test "x$ac_ct_NMEDIT" = x; then
7529 NMEDIT=":"
7530 else
7531 case $cross_compiling:$ac_tool_warned in
7532yes:)
7533{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7534$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7535ac_tool_warned=yes ;;
7536esac
7537 NMEDIT=$ac_ct_NMEDIT
7538 fi
7539else
7540 NMEDIT="$ac_cv_prog_NMEDIT"
7541fi
377170fa 7542
b686ecb5
JM
7543 if test -n "$ac_tool_prefix"; then
7544 # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args.
7545set dummy ${ac_tool_prefix}lipo; ac_word=$2
7546{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7547$as_echo_n "checking for $ac_word... " >&6; }
7548if ${ac_cv_prog_LIPO+:} false; then :
7549 $as_echo_n "(cached) " >&6
d70f978b 7550else
b686ecb5
JM
7551 if test -n "$LIPO"; then
7552 ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
7553else
7554as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7555for as_dir in $PATH
7556do
7557 IFS=$as_save_IFS
7558 test -z "$as_dir" && as_dir=.
7559 for ac_exec_ext in '' $ac_executable_extensions; do
7560 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7561 ac_cv_prog_LIPO="${ac_tool_prefix}lipo"
7562 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7563 break 2
7564 fi
7565done
7566 done
7567IFS=$as_save_IFS
7568
d70f978b 7569fi
b686ecb5
JM
7570fi
7571LIPO=$ac_cv_prog_LIPO
7572if test -n "$LIPO"; then
7573 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
7574$as_echo "$LIPO" >&6; }
7575else
7576 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7577$as_echo "no" >&6; }
377170fa 7578fi
d70f978b 7579
0d79cdc4 7580
b686ecb5
JM
7581fi
7582if test -z "$ac_cv_prog_LIPO"; then
7583 ac_ct_LIPO=$LIPO
7584 # Extract the first word of "lipo", so it can be a program name with args.
7585set dummy lipo; ac_word=$2
7586{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7587$as_echo_n "checking for $ac_word... " >&6; }
7588if ${ac_cv_prog_ac_ct_LIPO+:} false; then :
7589 $as_echo_n "(cached) " >&6
7590else
7591 if test -n "$ac_ct_LIPO"; then
7592 ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test.
7593else
7594as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7595for as_dir in $PATH
7596do
7597 IFS=$as_save_IFS
7598 test -z "$as_dir" && as_dir=.
7599 for ac_exec_ext in '' $ac_executable_extensions; do
7600 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7601 ac_cv_prog_ac_ct_LIPO="lipo"
7602 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7603 break 2
7604 fi
7605done
7606 done
7607IFS=$as_save_IFS
0d79cdc4 7608
b686ecb5
JM
7609fi
7610fi
7611ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO
7612if test -n "$ac_ct_LIPO"; then
7613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5
7614$as_echo "$ac_ct_LIPO" >&6; }
7615else
7616 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
f6720b1c 7617$as_echo "no" >&6; }
b686ecb5 7618fi
0d79cdc4 7619
b686ecb5
JM
7620 if test "x$ac_ct_LIPO" = x; then
7621 LIPO=":"
7622 else
7623 case $cross_compiling:$ac_tool_warned in
7624yes:)
7625{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7626$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7627ac_tool_warned=yes ;;
7628esac
7629 LIPO=$ac_ct_LIPO
7630 fi
f6720b1c 7631else
b686ecb5 7632 LIPO="$ac_cv_prog_LIPO"
f6720b1c 7633fi
0d79cdc4 7634
b686ecb5
JM
7635 if test -n "$ac_tool_prefix"; then
7636 # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args.
7637set dummy ${ac_tool_prefix}otool; ac_word=$2
7638{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7639$as_echo_n "checking for $ac_word... " >&6; }
7640if ${ac_cv_prog_OTOOL+:} false; then :
7641 $as_echo_n "(cached) " >&6
f6720b1c 7642else
b686ecb5
JM
7643 if test -n "$OTOOL"; then
7644 ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
7645else
7646as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7647for as_dir in $PATH
7648do
7649 IFS=$as_save_IFS
7650 test -z "$as_dir" && as_dir=.
7651 for ac_exec_ext in '' $ac_executable_extensions; do
7652 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7653 ac_cv_prog_OTOOL="${ac_tool_prefix}otool"
7654 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7655 break 2
7656 fi
7657done
7658 done
7659IFS=$as_save_IFS
f6720b1c
AM
7660
7661fi
0d79cdc4 7662fi
b686ecb5
JM
7663OTOOL=$ac_cv_prog_OTOOL
7664if test -n "$OTOOL"; then
7665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
7666$as_echo "$OTOOL" >&6; }
bec39cab 7667else
b686ecb5
JM
7668 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7669$as_echo "no" >&6; }
05e7c244 7670fi
bec39cab 7671
05e7c244 7672
05e7c244 7673fi
b686ecb5
JM
7674if test -z "$ac_cv_prog_OTOOL"; then
7675 ac_ct_OTOOL=$OTOOL
7676 # Extract the first word of "otool", so it can be a program name with args.
7677set dummy otool; ac_word=$2
7678{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7679$as_echo_n "checking for $ac_word... " >&6; }
7680if ${ac_cv_prog_ac_ct_OTOOL+:} false; then :
7681 $as_echo_n "(cached) " >&6
7682else
7683 if test -n "$ac_ct_OTOOL"; then
7684 ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test.
7685else
7686as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7687for as_dir in $PATH
7688do
7689 IFS=$as_save_IFS
7690 test -z "$as_dir" && as_dir=.
7691 for ac_exec_ext in '' $ac_executable_extensions; do
7692 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7693 ac_cv_prog_ac_ct_OTOOL="otool"
7694 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7695 break 2
7696 fi
7697done
7698 done
7699IFS=$as_save_IFS
bec39cab 7700
b686ecb5
JM
7701fi
7702fi
7703ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL
7704if test -n "$ac_ct_OTOOL"; then
7705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5
7706$as_echo "$ac_ct_OTOOL" >&6; }
7707else
7708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7709$as_echo "no" >&6; }
bec39cab
AC
7710fi
7711
b686ecb5
JM
7712 if test "x$ac_ct_OTOOL" = x; then
7713 OTOOL=":"
7714 else
7715 case $cross_compiling:$ac_tool_warned in
7716yes:)
7717{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7718$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7719ac_tool_warned=yes ;;
05e7c244 7720esac
b686ecb5
JM
7721 OTOOL=$ac_ct_OTOOL
7722 fi
7723else
7724 OTOOL="$ac_cv_prog_OTOOL"
7725fi
bec39cab 7726
b686ecb5
JM
7727 if test -n "$ac_tool_prefix"; then
7728 # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args.
7729set dummy ${ac_tool_prefix}otool64; ac_word=$2
7730{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7731$as_echo_n "checking for $ac_word... " >&6; }
7732if ${ac_cv_prog_OTOOL64+:} false; then :
7733 $as_echo_n "(cached) " >&6
7734else
7735 if test -n "$OTOOL64"; then
7736 ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test.
7737else
7738as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7739for as_dir in $PATH
7740do
7741 IFS=$as_save_IFS
7742 test -z "$as_dir" && as_dir=.
7743 for ac_exec_ext in '' $ac_executable_extensions; do
7744 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7745 ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64"
7746 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7747 break 2
7748 fi
7749done
7750 done
7751IFS=$as_save_IFS
bec39cab
AC
7752
7753fi
b686ecb5
JM
7754fi
7755OTOOL64=$ac_cv_prog_OTOOL64
7756if test -n "$OTOOL64"; then
7757 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5
7758$as_echo "$OTOOL64" >&6; }
7759else
7760 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7761$as_echo "no" >&6; }
7762fi
7763
bec39cab 7764
b686ecb5
JM
7765fi
7766if test -z "$ac_cv_prog_OTOOL64"; then
7767 ac_ct_OTOOL64=$OTOOL64
7768 # Extract the first word of "otool64", so it can be a program name with args.
7769set dummy otool64; ac_word=$2
7770{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7771$as_echo_n "checking for $ac_word... " >&6; }
7772if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then :
7773 $as_echo_n "(cached) " >&6
7774else
7775 if test -n "$ac_ct_OTOOL64"; then
7776 ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test.
7777else
7778as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7779for as_dir in $PATH
7780do
7781 IFS=$as_save_IFS
7782 test -z "$as_dir" && as_dir=.
7783 for ac_exec_ext in '' $ac_executable_extensions; do
7784 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7785 ac_cv_prog_ac_ct_OTOOL64="otool64"
7786 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7787 break 2
7788 fi
bec39cab 7789done
b686ecb5
JM
7790 done
7791IFS=$as_save_IFS
bec39cab 7792
b686ecb5
JM
7793fi
7794fi
7795ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64
7796if test -n "$ac_ct_OTOOL64"; then
7797 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5
7798$as_echo "$ac_ct_OTOOL64" >&6; }
7799else
7800 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7801$as_echo "no" >&6; }
7802fi
7803
7804 if test "x$ac_ct_OTOOL64" = x; then
7805 OTOOL64=":"
7806 else
7807 case $cross_compiling:$ac_tool_warned in
7808yes:)
7809{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7810$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7811ac_tool_warned=yes ;;
7812esac
7813 OTOOL64=$ac_ct_OTOOL64
05e7c244 7814 fi
b686ecb5
JM
7815else
7816 OTOOL64="$ac_cv_prog_OTOOL64"
a9322a30
TT
7817fi
7818
cb01cfba 7819
81ecdfbb 7820
cb01cfba 7821
cb01cfba 7822
4fd404c2 7823
bec39cab 7824
a9322a30 7825
a9322a30 7826
a9322a30 7827
5593a99a 7828
5593a99a 7829
5593a99a 7830
60ca704f 7831
bec39cab 7832
b686ecb5
JM
7833
7834
7835
7836
7837
7838
7839
7840
7841
7842
7843
7844
7845 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5
7846$as_echo_n "checking for -single_module linker flag... " >&6; }
7847if ${lt_cv_apple_cc_single_mod+:} false; then :
7848 $as_echo_n "(cached) " >&6
7849else
7850 lt_cv_apple_cc_single_mod=no
7851 if test -z "${LT_MULTI_MODULE}"; then
7852 # By default we will add the -single_module flag. You can override
7853 # by either setting the environment variable LT_MULTI_MODULE
7854 # non-empty at configure time, or by adding -multi_module to the
7855 # link flags.
7856 rm -rf libconftest.dylib*
7857 echo "int foo(void){return 1;}" > conftest.c
7858 echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
7859-dynamiclib -Wl,-single_module conftest.c" >&5
7860 $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
7861 -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
7862 _lt_result=$?
7863 if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then
7864 lt_cv_apple_cc_single_mod=yes
7865 else
7866 cat conftest.err >&5
7867 fi
7868 rm -rf libconftest.dylib*
7869 rm -f conftest.*
7870 fi
bec39cab 7871fi
b686ecb5
JM
7872{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5
7873$as_echo "$lt_cv_apple_cc_single_mod" >&6; }
7874 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5
7875$as_echo_n "checking for -exported_symbols_list linker flag... " >&6; }
7876if ${lt_cv_ld_exported_symbols_list+:} false; then :
81ecdfbb 7877 $as_echo_n "(cached) " >&6
bec39cab 7878else
b686ecb5
JM
7879 lt_cv_ld_exported_symbols_list=no
7880 save_LDFLAGS=$LDFLAGS
7881 echo "_main" > conftest.sym
7882 LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
7883 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 7884/* end confdefs.h. */
b686ecb5 7885
bec39cab
AC
7886int
7887main ()
7888{
5593a99a 7889
bec39cab
AC
7890 ;
7891 return 0;
7892}
7893_ACEOF
81ecdfbb 7894if ac_fn_c_try_link "$LINENO"; then :
b686ecb5 7895 lt_cv_ld_exported_symbols_list=yes
bec39cab 7896else
b686ecb5 7897 lt_cv_ld_exported_symbols_list=no
bec39cab 7898fi
81ecdfbb
RW
7899rm -f core conftest.err conftest.$ac_objext \
7900 conftest$ac_exeext conftest.$ac_ext
b686ecb5 7901 LDFLAGS="$save_LDFLAGS"
5593a99a 7902
bec39cab 7903fi
b686ecb5
JM
7904{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5
7905$as_echo "$lt_cv_ld_exported_symbols_list" >&6; }
7906 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5
7907$as_echo_n "checking for -force_load linker flag... " >&6; }
7908if ${lt_cv_ld_force_load+:} false; then :
7909 $as_echo_n "(cached) " >&6
7910else
7911 lt_cv_ld_force_load=no
7912 cat > conftest.c << _LT_EOF
7913int forced_loaded() { return 2;}
7914_LT_EOF
7915 echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5
7916 $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
7917 echo "$AR cru libconftest.a conftest.o" >&5
7918 $AR cru libconftest.a conftest.o 2>&5
7919 cat > conftest.c << _LT_EOF
7920int main() { return 0;}
7921_LT_EOF
7922 echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5
7923 $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
7924 _lt_result=$?
7925 if test -f conftest && test ! -s conftest.err && test $_lt_result = 0 && $GREP forced_load conftest 2>&1 >/dev/null; then
7926 lt_cv_ld_force_load=yes
7927 else
7928 cat conftest.err >&5
7929 fi
7930 rm -f conftest.err libconftest.a conftest conftest.c
7931 rm -rf conftest.dSYM
7932
7933fi
7934{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5
7935$as_echo "$lt_cv_ld_force_load" >&6; }
7936 case $host_os in
7937 rhapsody* | darwin1.[012])
7938 _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
7939 darwin1.*)
7940 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
7941 darwin*) # darwin 5.x on
7942 # if running on 10.5 or later, the deployment target defaults
7943 # to the OS version, if on x86, and 10.4, the deployment
7944 # target defaults to 10.4. Don't you love it?
7945 case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
7946 10.0,*86*-darwin8*|10.0,*-darwin[91]*)
7947 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
7948 10.[012][,.]*)
7949 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
7950 10.*)
7951 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
7952 esac
7953 ;;
7954 esac
7955 if test "$lt_cv_apple_cc_single_mod" = "yes"; then
7956 _lt_dar_single_mod='$single_module'
7957 fi
7958 if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
7959 _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
7960 else
7961 _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
7962 fi
7963 if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then
7964 _lt_dsymutil='~$DSYMUTIL $lib || :'
7965 else
7966 _lt_dsymutil=
7967 fi
7968 ;;
7969 esac
a9322a30 7970
b686ecb5
JM
7971for ac_header in dlfcn.h
7972do :
7973 ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
7974"
7975if test "x$ac_cv_header_dlfcn_h" = xyes; then :
7976 cat >>confdefs.h <<_ACEOF
7977#define HAVE_DLFCN_H 1
7978_ACEOF
bec39cab
AC
7979
7980fi
bec39cab 7981
b686ecb5 7982done
bec39cab 7983
5593a99a 7984
5593a99a 7985
bec39cab 7986
bec39cab 7987
bec39cab 7988
b686ecb5 7989# Set options
44cee4fd
TT
7990
7991
7992
b686ecb5 7993 enable_dlopen=no
c16158bc
JM
7994
7995
b686ecb5
JM
7996 enable_win32_dll=no
7997
7998
7999 # Check whether --enable-shared was given.
8000if test "${enable_shared+set}" = set; then :
8001 enableval=$enable_shared; p=${PACKAGE-default}
8002 case $enableval in
8003 yes) enable_shared=yes ;;
8004 no) enable_shared=no ;;
8005 *)
8006 enable_shared=no
8007 # Look at the argument we got. We use all the common list separators.
8008 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
8009 for pkg in $enableval; do
8010 IFS="$lt_save_ifs"
8011 if test "X$pkg" = "X$p"; then
8012 enable_shared=yes
8013 fi
8014 done
8015 IFS="$lt_save_ifs"
8016 ;;
8017 esac
c16158bc 8018else
b686ecb5
JM
8019 enable_shared=yes
8020fi
8021
8022
8023
8024
c16158bc 8025
b686ecb5
JM
8026
8027
8028
8029
8030 # Check whether --enable-static was given.
8031if test "${enable_static+set}" = set; then :
8032 enableval=$enable_static; p=${PACKAGE-default}
8033 case $enableval in
8034 yes) enable_static=yes ;;
8035 no) enable_static=no ;;
8036 *)
8037 enable_static=no
8038 # Look at the argument we got. We use all the common list separators.
8039 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
8040 for pkg in $enableval; do
8041 IFS="$lt_save_ifs"
8042 if test "X$pkg" = "X$p"; then
8043 enable_static=yes
8044 fi
8045 done
8046 IFS="$lt_save_ifs"
8047 ;;
8048 esac
8049else
8050 enable_static=yes
81ecdfbb 8051fi
c16158bc
JM
8052
8053
8054
8055
81ecdfbb 8056
b686ecb5
JM
8057
8058
8059
8060
8061
8062# Check whether --with-pic was given.
8063if test "${with_pic+set}" = set; then :
8064 withval=$with_pic; pic_mode="$withval"
c16158bc 8065else
b686ecb5
JM
8066 pic_mode=default
8067fi
8068
8069
8070test -z "$pic_mode" && pic_mode=default
8071
8072
8073
8074
c16158bc 8075
b686ecb5
JM
8076
8077
8078 # Check whether --enable-fast-install was given.
8079if test "${enable_fast_install+set}" = set; then :
8080 enableval=$enable_fast_install; p=${PACKAGE-default}
8081 case $enableval in
8082 yes) enable_fast_install=yes ;;
8083 no) enable_fast_install=no ;;
8084 *)
8085 enable_fast_install=no
8086 # Look at the argument we got. We use all the common list separators.
8087 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
8088 for pkg in $enableval; do
8089 IFS="$lt_save_ifs"
8090 if test "X$pkg" = "X$p"; then
8091 enable_fast_install=yes
8092 fi
8093 done
8094 IFS="$lt_save_ifs"
8095 ;;
8096 esac
8097else
8098 enable_fast_install=yes
81ecdfbb
RW
8099fi
8100
c16158bc
JM
8101
8102
8103
8104
c16158bc
JM
8105
8106
c16158bc
JM
8107
8108
bec39cab 8109
b686ecb5
JM
8110
8111# This can be used to rebuild libtool when needed
8112LIBTOOL_DEPS="$ltmain"
8113
8114# Always use our own libtool.
8115LIBTOOL='$(SHELL) $(top_builddir)/libtool'
8116
8117
8118
8119
8120
8121
8122
8123
8124
8125
8126
8127
8128
8129
8130
8131
8132
8133
8134
8135
8136
8137
8138
8139
8140
8141
8142test -z "$LN_S" && LN_S="ln -s"
8143
8144
8145
8146
8147
8148
8149
8150
8151
8152
8153
8154
8155
8156
8157if test -n "${ZSH_VERSION+set}" ; then
8158 setopt NO_GLOB_SUBST
8159fi
8160
8161{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5
8162$as_echo_n "checking for objdir... " >&6; }
8163if ${lt_cv_objdir+:} false; then :
81ecdfbb 8164 $as_echo_n "(cached) " >&6
bec39cab 8165else
b686ecb5
JM
8166 rm -f .libs 2>/dev/null
8167mkdir .libs 2>/dev/null
8168if test -d .libs; then
8169 lt_cv_objdir=.libs
bec39cab 8170else
b686ecb5
JM
8171 # MS-DOS does not allow filenames that begin with a dot.
8172 lt_cv_objdir=_libs
8173fi
8174rmdir .libs 2>/dev/null
8175fi
8176{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5
8177$as_echo "$lt_cv_objdir" >&6; }
8178objdir=$lt_cv_objdir
8179
8180
8181
8182
8183
8184cat >>confdefs.h <<_ACEOF
8185#define LT_OBJDIR "$lt_cv_objdir/"
8186_ACEOF
8187
8188
8189
8190
8191case $host_os in
8192aix3*)
8193 # AIX sometimes has problems with the GCC collect2 program. For some
8194 # reason, if we set the COLLECT_NAMES environment variable, the problems
8195 # vanish in a puff of smoke.
8196 if test "X${COLLECT_NAMES+set}" != Xset; then
8197 COLLECT_NAMES=
8198 export COLLECT_NAMES
bec39cab 8199 fi
b686ecb5
JM
8200 ;;
8201esac
8202
8203# Global variables:
8204ofile=libtool
8205can_build_shared=yes
8206
8207# All known linkers require a `.a' archive for static linking (except MSVC,
8208# which needs '.lib').
8209libext=a
8210
8211with_gnu_ld="$lt_cv_prog_gnu_ld"
8212
8213old_CC="$CC"
8214old_CFLAGS="$CFLAGS"
8215
8216# Set sane defaults for various variables
8217test -z "$CC" && CC=cc
8218test -z "$LTCC" && LTCC=$CC
8219test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
8220test -z "$LD" && LD=ld
8221test -z "$ac_objext" && ac_objext=o
8222
8223for cc_temp in $compiler""; do
8224 case $cc_temp in
8225 compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
8226 distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
8227 \-*) ;;
8228 *) break;;
8229 esac
bec39cab 8230done
b686ecb5 8231cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
bec39cab 8232
b686ecb5
JM
8233
8234# Only perform the check for file, if the check method requires it
8235test -z "$MAGIC_CMD" && MAGIC_CMD=file
8236case $deplibs_check_method in
8237file_magic*)
8238 if test "$file_magic_cmd" = '$MAGIC_CMD'; then
8239 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5
8240$as_echo_n "checking for ${ac_tool_prefix}file... " >&6; }
8241if ${lt_cv_path_MAGIC_CMD+:} false; then :
8242 $as_echo_n "(cached) " >&6
8243else
8244 case $MAGIC_CMD in
8245[\\/*] | ?:[\\/]*)
8246 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
8247 ;;
8248*)
8249 lt_save_MAGIC_CMD="$MAGIC_CMD"
8250 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
8251 ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
8252 for ac_dir in $ac_dummy; do
8253 IFS="$lt_save_ifs"
8254 test -z "$ac_dir" && ac_dir=.
8255 if test -f $ac_dir/${ac_tool_prefix}file; then
8256 lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file"
8257 if test -n "$file_magic_test_file"; then
8258 case $deplibs_check_method in
8259 "file_magic "*)
8260 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
8261 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
8262 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
8263 $EGREP "$file_magic_regex" > /dev/null; then
8264 :
8265 else
8266 cat <<_LT_EOF 1>&2
8267
8268*** Warning: the command libtool uses to detect shared libraries,
8269*** $file_magic_cmd, produces output that libtool cannot recognize.
8270*** The result is that libtool may fail to recognize shared libraries
8271*** as such. This will affect the creation of libtool libraries that
8272*** depend on shared libraries, but programs linked with such libtool
8273*** libraries will work regardless of this problem. Nevertheless, you
8274*** may want to report the problem to your system manager and/or to
8275*** bug-libtool@gnu.org
8276
8277_LT_EOF
8278 fi ;;
8279 esac
8280 fi
8281 break
8282 fi
8283 done
8284 IFS="$lt_save_ifs"
8285 MAGIC_CMD="$lt_save_MAGIC_CMD"
8286 ;;
8287esac
bec39cab 8288fi
b686ecb5
JM
8289
8290MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
8291if test -n "$MAGIC_CMD"; then
8292 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
8293$as_echo "$MAGIC_CMD" >&6; }
bec39cab 8294else
81ecdfbb
RW
8295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8296$as_echo "no" >&6; }
bec39cab
AC
8297fi
8298
bec39cab 8299
bec39cab 8300
b686ecb5
JM
8301
8302
8303if test -z "$lt_cv_path_MAGIC_CMD"; then
8304 if test -n "$ac_tool_prefix"; then
8305 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5
8306$as_echo_n "checking for file... " >&6; }
8307if ${lt_cv_path_MAGIC_CMD+:} false; then :
c971b7fa
PA
8308 $as_echo_n "(cached) " >&6
8309else
b686ecb5
JM
8310 case $MAGIC_CMD in
8311[\\/*] | ?:[\\/]*)
8312 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
8313 ;;
8314*)
8315 lt_save_MAGIC_CMD="$MAGIC_CMD"
8316 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
8317 ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
8318 for ac_dir in $ac_dummy; do
8319 IFS="$lt_save_ifs"
8320 test -z "$ac_dir" && ac_dir=.
8321 if test -f $ac_dir/file; then
8322 lt_cv_path_MAGIC_CMD="$ac_dir/file"
8323 if test -n "$file_magic_test_file"; then
8324 case $deplibs_check_method in
8325 "file_magic "*)
8326 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
8327 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
8328 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
8329 $EGREP "$file_magic_regex" > /dev/null; then
c971b7fa
PA
8330 :
8331 else
b686ecb5
JM
8332 cat <<_LT_EOF 1>&2
8333
8334*** Warning: the command libtool uses to detect shared libraries,
8335*** $file_magic_cmd, produces output that libtool cannot recognize.
8336*** The result is that libtool may fail to recognize shared libraries
8337*** as such. This will affect the creation of libtool libraries that
8338*** depend on shared libraries, but programs linked with such libtool
8339*** libraries will work regardless of this problem. Nevertheless, you
8340*** may want to report the problem to your system manager and/or to
8341*** bug-libtool@gnu.org
8342
8343_LT_EOF
8344 fi ;;
8345 esac
8346 fi
8347 break
8348 fi
8349 done
8350 IFS="$lt_save_ifs"
8351 MAGIC_CMD="$lt_save_MAGIC_CMD"
8352 ;;
c971b7fa 8353esac
b686ecb5 8354fi
c971b7fa 8355
b686ecb5
JM
8356MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
8357if test -n "$MAGIC_CMD"; then
8358 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
8359$as_echo "$MAGIC_CMD" >&6; }
8360else
8361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8362$as_echo "no" >&6; }
8363fi
c971b7fa 8364
c971b7fa 8365
c971b7fa 8366 else
b686ecb5 8367 MAGIC_CMD=:
c971b7fa
PA
8368 fi
8369fi
c971b7fa 8370
b686ecb5
JM
8371 fi
8372 ;;
8373esac
c971b7fa 8374
b686ecb5 8375# Use C for the default configuration in the libtool script
c971b7fa 8376
b686ecb5
JM
8377lt_save_CC="$CC"
8378ac_ext=c
8379ac_cpp='$CPP $CPPFLAGS'
8380ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
8381ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
8382ac_compiler_gnu=$ac_cv_c_compiler_gnu
bec39cab 8383
bec39cab 8384
b686ecb5
JM
8385# Source file extension for C test sources.
8386ac_ext=c
bec39cab 8387
b686ecb5
JM
8388# Object file extension for compiled C test sources.
8389objext=o
8390objext=$objext
bec39cab 8391
b686ecb5
JM
8392# Code to be used in simple compile tests
8393lt_simple_compile_test_code="int some_variable = 0;"
81ecdfbb 8394
b686ecb5
JM
8395# Code to be used in simple link tests
8396lt_simple_link_test_code='int main(){return(0);}'
8397
8398
8399
8400
8401
8402
8403
8404# If no C compiler was specified, use CC.
8405LTCC=${LTCC-"$CC"}
8406
8407# If no C compiler flags were specified, use CFLAGS.
8408LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
8409
8410# Allow CC to be a program name with arguments.
8411compiler=$CC
8412
8413# Save the default compiler, since it gets overwritten when the other
8414# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
8415compiler_DEFAULT=$CC
8416
8417# save warnings/boilerplate of simple test code
8418ac_outfile=conftest.$ac_objext
8419echo "$lt_simple_compile_test_code" >conftest.$ac_ext
8420eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
8421_lt_compiler_boilerplate=`cat conftest.err`
8422$RM conftest*
8423
8424ac_outfile=conftest.$ac_objext
8425echo "$lt_simple_link_test_code" >conftest.$ac_ext
8426eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
8427_lt_linker_boilerplate=`cat conftest.err`
8428$RM -r conftest*
8429
8430
8431## CAVEAT EMPTOR:
8432## There is no encapsulation within the following macros, do not change
8433## the running order or otherwise move them around unless you know exactly
8434## what you are doing...
8435if test -n "$compiler"; then
8436
8437lt_prog_compiler_no_builtin_flag=
8438
8439if test "$GCC" = yes; then
8440 case $cc_basename in
8441 nvcc*)
8442 lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;;
8443 *)
8444 lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;;
8445 esac
8446
8447 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
8448$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; }
8449if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then :
81ecdfbb 8450 $as_echo_n "(cached) " >&6
bec39cab 8451else
b686ecb5
JM
8452 lt_cv_prog_compiler_rtti_exceptions=no
8453 ac_outfile=conftest.$ac_objext
8454 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
8455 lt_compiler_flag="-fno-rtti -fno-exceptions"
8456 # Insert the option either (1) after the last *FLAGS variable, or
8457 # (2) before a word containing "conftest.", or (3) at the end.
8458 # Note that $ac_compile itself does not contain backslashes and begins
8459 # with a dollar sign (not a hyphen), so the echo should work correctly.
8460 # The option is referenced via a variable to avoid confusing sed.
8461 lt_compile=`echo "$ac_compile" | $SED \
8462 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
8463 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
8464 -e 's:$: $lt_compiler_flag:'`
8465 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
8466 (eval "$lt_compile" 2>conftest.err)
8467 ac_status=$?
8468 cat conftest.err >&5
8469 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8470 if (exit $ac_status) && test -s "$ac_outfile"; then
8471 # The compiler can only warn and ignore the option if not recognized
8472 # So say no if there are warnings other than the usual output.
8473 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
8474 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
8475 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
8476 lt_cv_prog_compiler_rtti_exceptions=yes
8477 fi
8478 fi
8479 $RM conftest*
bec39cab 8480
bec39cab 8481fi
b686ecb5
JM
8482{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
8483$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; }
8484
8485if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then
8486 lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions"
bec39cab 8487else
b686ecb5 8488 :
bec39cab
AC
8489fi
8490
bec39cab
AC
8491fi
8492
bec39cab 8493
bec39cab 8494
81ecdfbb 8495
bec39cab
AC
8496
8497
b686ecb5
JM
8498 lt_prog_compiler_wl=
8499lt_prog_compiler_pic=
8500lt_prog_compiler_static=
bec39cab 8501
b686ecb5
JM
8502{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
8503$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
bec39cab 8504
b686ecb5
JM
8505 if test "$GCC" = yes; then
8506 lt_prog_compiler_wl='-Wl,'
8507 lt_prog_compiler_static='-static'
8508
8509 case $host_os in
8510 aix*)
8511 # All AIX code is PIC.
8512 if test "$host_cpu" = ia64; then
8513 # AIX 5 now supports IA64 processor
8514 lt_prog_compiler_static='-Bstatic'
8515 fi
8516 lt_prog_compiler_pic='-fPIC'
8517 ;;
81ecdfbb 8518
b686ecb5
JM
8519 amigaos*)
8520 case $host_cpu in
8521 powerpc)
8522 # see comment about AmigaOS4 .so support
8523 lt_prog_compiler_pic='-fPIC'
8524 ;;
8525 m68k)
8526 # FIXME: we need at least 68020 code to build shared libraries, but
8527 # adding the `-m68020' flag to GCC prevents building anything better,
8528 # like `-m68040'.
8529 lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4'
8530 ;;
8531 esac
8532 ;;
bec39cab 8533
b686ecb5
JM
8534 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
8535 # PIC is the default for these OSes.
8536 ;;
bec39cab 8537
b686ecb5
JM
8538 mingw* | cygwin* | pw32* | os2* | cegcc*)
8539 # This hack is so that the source file can tell whether it is being
8540 # built for inclusion in a dll (and should export symbols for example).
8541 # Although the cygwin gcc ignores -fPIC, still need this for old-style
8542 # (--disable-auto-import) libraries
8543 lt_prog_compiler_pic='-DDLL_EXPORT'
8544 ;;
8545
8546 darwin* | rhapsody*)
8547 # PIC is the default on this platform
8548 # Common symbols not allowed in MH_DYLIB files
8549 lt_prog_compiler_pic='-fno-common'
8550 ;;
8551
8552 haiku*)
8553 # PIC is the default for Haiku.
8554 # The "-static" flag exists, but is broken.
8555 lt_prog_compiler_static=
8556 ;;
8557
8558 hpux*)
8559 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
8560 # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
8561 # sets the default TLS model and affects inlining.
8562 case $host_cpu in
8563 hppa*64*)
8564 # +Z the default
8565 ;;
8566 *)
8567 lt_prog_compiler_pic='-fPIC'
8568 ;;
8569 esac
8570 ;;
8571
8572 interix[3-9]*)
8573 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
8574 # Instead, we relocate shared libraries at runtime.
8575 ;;
8576
8577 msdosdjgpp*)
8578 # Just because we use GCC doesn't mean we suddenly get shared libraries
8579 # on systems that don't support them.
8580 lt_prog_compiler_can_build_shared=no
8581 enable_shared=no
8582 ;;
8583
8584 *nto* | *qnx*)
8585 # QNX uses GNU C++, but need to define -shared option too, otherwise
8586 # it will coredump.
8587 lt_prog_compiler_pic='-fPIC -shared'
8588 ;;
8589
8590 sysv4*MP*)
8591 if test -d /usr/nec; then
8592 lt_prog_compiler_pic=-Kconform_pic
8593 fi
8594 ;;
8595
8596 *)
8597 lt_prog_compiler_pic='-fPIC'
8598 ;;
8599 esac
8600
8601 case $cc_basename in
8602 nvcc*) # Cuda Compiler Driver 2.2
8603 lt_prog_compiler_wl='-Xlinker '
8604 lt_prog_compiler_pic='-Xcompiler -fPIC'
8605 ;;
8606 esac
81ecdfbb 8607 else
b686ecb5
JM
8608 # PORTME Check for flag to pass linker flags through the system compiler.
8609 case $host_os in
8610 aix*)
8611 lt_prog_compiler_wl='-Wl,'
8612 if test "$host_cpu" = ia64; then
8613 # AIX 5 now supports IA64 processor
8614 lt_prog_compiler_static='-Bstatic'
8615 else
8616 lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp'
8617 fi
8618 ;;
8619
8620 mingw* | cygwin* | pw32* | os2* | cegcc*)
8621 # This hack is so that the source file can tell whether it is being
8622 # built for inclusion in a dll (and should export symbols for example).
8623 lt_prog_compiler_pic='-DDLL_EXPORT'
8624 ;;
8625
8626 hpux9* | hpux10* | hpux11*)
8627 lt_prog_compiler_wl='-Wl,'
8628 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
8629 # not for PA HP-UX.
8630 case $host_cpu in
8631 hppa*64*|ia64*)
8632 # +Z the default
8633 ;;
8634 *)
8635 lt_prog_compiler_pic='+Z'
8636 ;;
8637 esac
8638 # Is there a better lt_prog_compiler_static that works with the bundled CC?
8639 lt_prog_compiler_static='${wl}-a ${wl}archive'
8640 ;;
8641
8642 irix5* | irix6* | nonstopux*)
8643 lt_prog_compiler_wl='-Wl,'
8644 # PIC (with -KPIC) is the default.
8645 lt_prog_compiler_static='-non_shared'
8646 ;;
8647
8648 linux* | k*bsd*-gnu | kopensolaris*-gnu)
8649 case $cc_basename in
8650 # old Intel for x86_64 which still supported -KPIC.
8651 ecc*)
8652 lt_prog_compiler_wl='-Wl,'
8653 lt_prog_compiler_pic='-KPIC'
8654 lt_prog_compiler_static='-static'
8655 ;;
8656 # icc used to be incompatible with GCC.
8657 # ICC 10 doesn't accept -KPIC any more.
8658 icc* | ifort*)
8659 lt_prog_compiler_wl='-Wl,'
8660 lt_prog_compiler_pic='-fPIC'
8661 lt_prog_compiler_static='-static'
8662 ;;
8663 # Lahey Fortran 8.1.
8664 lf95*)
8665 lt_prog_compiler_wl='-Wl,'
8666 lt_prog_compiler_pic='--shared'
8667 lt_prog_compiler_static='--static'
8668 ;;
8669 pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
8670 # Portland Group compilers (*not* the Pentium gcc compiler,
8671 # which looks to be a dead project)
8672 lt_prog_compiler_wl='-Wl,'
8673 lt_prog_compiler_pic='-fpic'
8674 lt_prog_compiler_static='-Bstatic'
8675 ;;
8676 ccc*)
8677 lt_prog_compiler_wl='-Wl,'
8678 # All Alpha code is PIC.
8679 lt_prog_compiler_static='-non_shared'
8680 ;;
8681 xl* | bgxl* | bgf* | mpixl*)
8682 # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
8683 lt_prog_compiler_wl='-Wl,'
8684 lt_prog_compiler_pic='-qpic'
8685 lt_prog_compiler_static='-qstaticlink'
8686 ;;
8687 *)
8688 case `$CC -V 2>&1 | sed 5q` in
8689 *Sun\ F* | *Sun*Fortran*)
8690 # Sun Fortran 8.3 passes all unrecognized flags to the linker
8691 lt_prog_compiler_pic='-KPIC'
8692 lt_prog_compiler_static='-Bstatic'
8693 lt_prog_compiler_wl=''
8694 ;;
8695 *Sun\ C*)
8696 # Sun C 5.9
8697 lt_prog_compiler_pic='-KPIC'
8698 lt_prog_compiler_static='-Bstatic'
8699 lt_prog_compiler_wl='-Wl,'
8700 ;;
8701 esac
8702 ;;
8703 esac
8704 ;;
8705
8706 newsos6)
8707 lt_prog_compiler_pic='-KPIC'
8708 lt_prog_compiler_static='-Bstatic'
8709 ;;
8710
8711 *nto* | *qnx*)
8712 # QNX uses GNU C++, but need to define -shared option too, otherwise
8713 # it will coredump.
8714 lt_prog_compiler_pic='-fPIC -shared'
8715 ;;
8716
8717 osf3* | osf4* | osf5*)
8718 lt_prog_compiler_wl='-Wl,'
8719 # All OSF/1 code is PIC.
8720 lt_prog_compiler_static='-non_shared'
8721 ;;
8722
8723 rdos*)
8724 lt_prog_compiler_static='-non_shared'
8725 ;;
8726
8727 solaris*)
8728 lt_prog_compiler_pic='-KPIC'
8729 lt_prog_compiler_static='-Bstatic'
8730 case $cc_basename in
8731 f77* | f90* | f95*)
8732 lt_prog_compiler_wl='-Qoption ld ';;
8733 *)
8734 lt_prog_compiler_wl='-Wl,';;
8735 esac
8736 ;;
8737
8738 sunos4*)
8739 lt_prog_compiler_wl='-Qoption ld '
8740 lt_prog_compiler_pic='-PIC'
8741 lt_prog_compiler_static='-Bstatic'
8742 ;;
8743
8744 sysv4 | sysv4.2uw2* | sysv4.3*)
8745 lt_prog_compiler_wl='-Wl,'
8746 lt_prog_compiler_pic='-KPIC'
8747 lt_prog_compiler_static='-Bstatic'
8748 ;;
8749
8750 sysv4*MP*)
8751 if test -d /usr/nec ;then
8752 lt_prog_compiler_pic='-Kconform_pic'
8753 lt_prog_compiler_static='-Bstatic'
8754 fi
8755 ;;
8756
8757 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
8758 lt_prog_compiler_wl='-Wl,'
8759 lt_prog_compiler_pic='-KPIC'
8760 lt_prog_compiler_static='-Bstatic'
8761 ;;
8762
8763 unicos*)
8764 lt_prog_compiler_wl='-Wl,'
8765 lt_prog_compiler_can_build_shared=no
8766 ;;
8767
8768 uts4*)
8769 lt_prog_compiler_pic='-pic'
8770 lt_prog_compiler_static='-Bstatic'
8771 ;;
8772
8773 *)
8774 lt_prog_compiler_can_build_shared=no
8775 ;;
8776 esac
81ecdfbb 8777 fi
bec39cab 8778
b686ecb5
JM
8779case $host_os in
8780 # For platforms which do not support PIC, -DPIC is meaningless:
8781 *djgpp*)
8782 lt_prog_compiler_pic=
8783 ;;
8784 *)
8785 lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
8786 ;;
8787esac
8788{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic" >&5
8789$as_echo "$lt_prog_compiler_pic" >&6; }
8790
8791
8792
8793
8794
8795
8796#
8797# Check to make sure the PIC flag actually works.
8798#
8799if test -n "$lt_prog_compiler_pic"; then
8800 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
8801$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; }
8802if ${lt_cv_prog_compiler_pic_works+:} false; then :
81ecdfbb 8803 $as_echo_n "(cached) " >&6
bec39cab 8804else
b686ecb5
JM
8805 lt_cv_prog_compiler_pic_works=no
8806 ac_outfile=conftest.$ac_objext
8807 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
8808 lt_compiler_flag="$lt_prog_compiler_pic -DPIC"
8809 # Insert the option either (1) after the last *FLAGS variable, or
8810 # (2) before a word containing "conftest.", or (3) at the end.
8811 # Note that $ac_compile itself does not contain backslashes and begins
8812 # with a dollar sign (not a hyphen), so the echo should work correctly.
8813 # The option is referenced via a variable to avoid confusing sed.
8814 lt_compile=`echo "$ac_compile" | $SED \
8815 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
8816 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
8817 -e 's:$: $lt_compiler_flag:'`
8818 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
8819 (eval "$lt_compile" 2>conftest.err)
8820 ac_status=$?
8821 cat conftest.err >&5
8822 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8823 if (exit $ac_status) && test -s "$ac_outfile"; then
8824 # The compiler can only warn and ignore the option if not recognized
8825 # So say no if there are warnings other than the usual output.
8826 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
8827 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
8828 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
8829 lt_cv_prog_compiler_pic_works=yes
8830 fi
8831 fi
8832 $RM conftest*
bec39cab
AC
8833
8834fi
b686ecb5
JM
8835{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5
8836$as_echo "$lt_cv_prog_compiler_pic_works" >&6; }
8837
8838if test x"$lt_cv_prog_compiler_pic_works" = xyes; then
8839 case $lt_prog_compiler_pic in
8840 "" | " "*) ;;
8841 *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;;
8842 esac
bec39cab 8843else
b686ecb5
JM
8844 lt_prog_compiler_pic=
8845 lt_prog_compiler_can_build_shared=no
bec39cab
AC
8846fi
8847
8848fi
b686ecb5
JM
8849
8850
8851
8852
8853
8854
8855#
8856# Check to make sure the static flag actually works.
8857#
8858wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\"
8859{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5
8860$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
8861if ${lt_cv_prog_compiler_static_works+:} false; then :
81ecdfbb 8862 $as_echo_n "(cached) " >&6
bec39cab 8863else
b686ecb5
JM
8864 lt_cv_prog_compiler_static_works=no
8865 save_LDFLAGS="$LDFLAGS"
8866 LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
8867 echo "$lt_simple_link_test_code" > conftest.$ac_ext
8868 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
8869 # The linker can only warn and ignore the option if not recognized
8870 # So say no if there are warnings
8871 if test -s conftest.err; then
8872 # Append any errors to the config.log.
8873 cat conftest.err 1>&5
8874 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
8875 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
8876 if diff conftest.exp conftest.er2 >/dev/null; then
8877 lt_cv_prog_compiler_static_works=yes
8878 fi
8879 else
8880 lt_cv_prog_compiler_static_works=yes
8881 fi
8882 fi
8883 $RM -r conftest*
8884 LDFLAGS="$save_LDFLAGS"
bec39cab
AC
8885
8886fi
b686ecb5
JM
8887{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5
8888$as_echo "$lt_cv_prog_compiler_static_works" >&6; }
8889
8890if test x"$lt_cv_prog_compiler_static_works" = xyes; then
8891 :
bec39cab 8892else
b686ecb5 8893 lt_prog_compiler_static=
bec39cab
AC
8894fi
8895
b686ecb5
JM
8896
8897
8898
8899
8900
8901
8902 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
8903$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
8904if ${lt_cv_prog_compiler_c_o+:} false; then :
8905 $as_echo_n "(cached) " >&6
bec39cab 8906else
b686ecb5
JM
8907 lt_cv_prog_compiler_c_o=no
8908 $RM -r conftest 2>/dev/null
8909 mkdir conftest
8910 cd conftest
8911 mkdir out
8912 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
8913
8914 lt_compiler_flag="-o out/conftest2.$ac_objext"
8915 # Insert the option either (1) after the last *FLAGS variable, or
8916 # (2) before a word containing "conftest.", or (3) at the end.
8917 # Note that $ac_compile itself does not contain backslashes and begins
8918 # with a dollar sign (not a hyphen), so the echo should work correctly.
8919 lt_compile=`echo "$ac_compile" | $SED \
8920 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
8921 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
8922 -e 's:$: $lt_compiler_flag:'`
8923 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
8924 (eval "$lt_compile" 2>out/conftest.err)
8925 ac_status=$?
8926 cat out/conftest.err >&5
8927 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8928 if (exit $ac_status) && test -s out/conftest2.$ac_objext
8929 then
8930 # The compiler can only warn and ignore the option if not recognized
8931 # So say no if there are warnings
8932 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
8933 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
8934 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
8935 lt_cv_prog_compiler_c_o=yes
8936 fi
8937 fi
8938 chmod u+w . 2>&5
8939 $RM conftest*
8940 # SGI C++ compiler will create directory out/ii_files/ for
8941 # template instantiation
8942 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
8943 $RM out/* && rmdir out
8944 cd ..
8945 $RM -r conftest
8946 $RM conftest*
8947
bec39cab 8948fi
b686ecb5
JM
8949{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
8950$as_echo "$lt_cv_prog_compiler_c_o" >&6; }
bec39cab 8951
b686ecb5
JM
8952
8953
8954
8955
8956
8957 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
8958$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
8959if ${lt_cv_prog_compiler_c_o+:} false; then :
81ecdfbb 8960 $as_echo_n "(cached) " >&6
bec39cab 8961else
b686ecb5
JM
8962 lt_cv_prog_compiler_c_o=no
8963 $RM -r conftest 2>/dev/null
8964 mkdir conftest
8965 cd conftest
8966 mkdir out
8967 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
8968
8969 lt_compiler_flag="-o out/conftest2.$ac_objext"
8970 # Insert the option either (1) after the last *FLAGS variable, or
8971 # (2) before a word containing "conftest.", or (3) at the end.
8972 # Note that $ac_compile itself does not contain backslashes and begins
8973 # with a dollar sign (not a hyphen), so the echo should work correctly.
8974 lt_compile=`echo "$ac_compile" | $SED \
8975 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
8976 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
8977 -e 's:$: $lt_compiler_flag:'`
8978 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
8979 (eval "$lt_compile" 2>out/conftest.err)
8980 ac_status=$?
8981 cat out/conftest.err >&5
8982 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8983 if (exit $ac_status) && test -s out/conftest2.$ac_objext
8984 then
8985 # The compiler can only warn and ignore the option if not recognized
8986 # So say no if there are warnings
8987 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
8988 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
8989 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
8990 lt_cv_prog_compiler_c_o=yes
8991 fi
8992 fi
8993 chmod u+w . 2>&5
8994 $RM conftest*
8995 # SGI C++ compiler will create directory out/ii_files/ for
8996 # template instantiation
8997 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
8998 $RM out/* && rmdir out
8999 cd ..
9000 $RM -r conftest
9001 $RM conftest*
9002
9003fi
9004{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
9005$as_echo "$lt_cv_prog_compiler_c_o" >&6; }
9006
9007
9008
9009
9010hard_links="nottested"
9011if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then
9012 # do not overwrite the value of need_locks provided by the user
9013 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5
9014$as_echo_n "checking if we can lock with hard links... " >&6; }
9015 hard_links=yes
9016 $RM conftest*
9017 ln conftest.a conftest.b 2>/dev/null && hard_links=no
9018 touch conftest.a
9019 ln conftest.a conftest.b 2>&5 || hard_links=no
9020 ln conftest.a conftest.b 2>/dev/null && hard_links=no
9021 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5
9022$as_echo "$hard_links" >&6; }
9023 if test "$hard_links" = no; then
9024 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
9025$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
9026 need_locks=warn
9027 fi
bec39cab 9028else
b686ecb5
JM
9029 need_locks=no
9030fi
9031
9032
9033
9034
9035
9036
9037 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
9038$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
9039
9040 runpath_var=
9041 allow_undefined_flag=
9042 always_export_symbols=no
9043 archive_cmds=
9044 archive_expsym_cmds=
9045 compiler_needs_object=no
9046 enable_shared_with_static_runtimes=no
9047 export_dynamic_flag_spec=
9048 export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
9049 hardcode_automatic=no
9050 hardcode_direct=no
9051 hardcode_direct_absolute=no
9052 hardcode_libdir_flag_spec=
9053 hardcode_libdir_flag_spec_ld=
9054 hardcode_libdir_separator=
9055 hardcode_minus_L=no
9056 hardcode_shlibpath_var=unsupported
9057 inherit_rpath=no
9058 link_all_deplibs=unknown
9059 module_cmds=
9060 module_expsym_cmds=
9061 old_archive_from_new_cmds=
9062 old_archive_from_expsyms_cmds=
9063 thread_safe_flag_spec=
9064 whole_archive_flag_spec=
9065 # include_expsyms should be a list of space-separated symbols to be *always*
9066 # included in the symbol list
9067 include_expsyms=
9068 # exclude_expsyms can be an extended regexp of symbols to exclude
9069 # it will be wrapped by ` (' and `)$', so one must not match beginning or
9070 # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
9071 # as well as any symbol that contains `d'.
9072 exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
9073 # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
9074 # platforms (ab)use it in PIC code, but their linkers get confused if
9075 # the symbol is explicitly referenced. Since portable code cannot
9076 # rely on this symbol name, it's probably fine to never include it in
9077 # preloaded symbol tables.
9078 # Exclude shared library initialization/finalization symbols.
9079 extract_expsyms_cmds=
9080
9081 case $host_os in
9082 cygwin* | mingw* | pw32* | cegcc*)
9083 # FIXME: the MSVC++ port hasn't been tested in a loooong time
9084 # When not using gcc, we currently assume that we are using
9085 # Microsoft Visual C++.
9086 if test "$GCC" != yes; then
9087 with_gnu_ld=no
9088 fi
9089 ;;
9090 interix*)
9091 # we just hope/assume this is gcc and not c89 (= MSVC++)
9092 with_gnu_ld=yes
9093 ;;
9094 openbsd*)
9095 with_gnu_ld=no
9096 ;;
9097 esac
81ecdfbb 9098
b686ecb5
JM
9099 ld_shlibs=yes
9100
9101 # On some targets, GNU ld is compatible enough with the native linker
9102 # that we're better off using the native interface for both.
9103 lt_use_gnu_ld_interface=no
9104 if test "$with_gnu_ld" = yes; then
9105 case $host_os in
9106 aix*)
9107 # The AIX port of GNU ld has always aspired to compatibility
9108 # with the native linker. However, as the warning in the GNU ld
9109 # block says, versions before 2.19.5* couldn't really create working
9110 # shared libraries, regardless of the interface used.
9111 case `$LD -v 2>&1` in
9112 *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
9113 *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;;
9114 *\ \(GNU\ Binutils\)\ [3-9]*) ;;
9115 *)
9116 lt_use_gnu_ld_interface=yes
9117 ;;
9118 esac
9119 ;;
9120 *)
9121 lt_use_gnu_ld_interface=yes
9122 ;;
9123 esac
bec39cab 9124 fi
bec39cab 9125
b686ecb5
JM
9126 if test "$lt_use_gnu_ld_interface" = yes; then
9127 # If archive_cmds runs LD, not CC, wlarc should be empty
9128 wlarc='${wl}'
9129
9130 # Set some defaults for GNU ld with shared library support. These
9131 # are reset later if shared libraries are not supported. Putting them
9132 # here allows them to be overridden if necessary.
9133 runpath_var=LD_RUN_PATH
9134 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
9135 export_dynamic_flag_spec='${wl}--export-dynamic'
9136 # ancient GNU ld didn't support --whole-archive et. al.
9137 if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
9138 whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
9139 else
9140 whole_archive_flag_spec=
9141 fi
9142 supports_anon_versioning=no
9143 case `$LD -v 2>&1` in
9144 *GNU\ gold*) supports_anon_versioning=yes ;;
9145 *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
9146 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
9147 *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
9148 *\ 2.11.*) ;; # other 2.11 versions
9149 *) supports_anon_versioning=yes ;;
9150 esac
bec39cab 9151
b686ecb5
JM
9152 # See if GNU ld supports shared libraries.
9153 case $host_os in
9154 aix[3-9]*)
9155 # On AIX/PPC, the GNU linker is very broken
9156 if test "$host_cpu" != ia64; then
9157 ld_shlibs=no
9158 cat <<_LT_EOF 1>&2
9159
9160*** Warning: the GNU linker, at least up to release 2.19, is reported
9161*** to be unable to reliably create shared libraries on AIX.
9162*** Therefore, libtool is disabling shared libraries support. If you
9163*** really care for shared libraries, you may want to install binutils
9164*** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
9165*** You will then need to restart the configuration process.
9166
9167_LT_EOF
9168 fi
9169 ;;
c906108c 9170
b686ecb5
JM
9171 amigaos*)
9172 case $host_cpu in
9173 powerpc)
9174 # see comment about AmigaOS4 .so support
9175 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
9176 archive_expsym_cmds=''
9177 ;;
9178 m68k)
9179 archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
9180 hardcode_libdir_flag_spec='-L$libdir'
9181 hardcode_minus_L=yes
9182 ;;
9183 esac
9184 ;;
bec39cab 9185
b686ecb5
JM
9186 beos*)
9187 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
9188 allow_undefined_flag=unsupported
9189 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
9190 # support --undefined. This deserves some investigation. FIXME
9191 archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
9192 else
9193 ld_shlibs=no
9194 fi
9195 ;;
bec39cab 9196
b686ecb5
JM
9197 cygwin* | mingw* | pw32* | cegcc*)
9198 # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless,
9199 # as there is no search path for DLLs.
9200 hardcode_libdir_flag_spec='-L$libdir'
9201 export_dynamic_flag_spec='${wl}--export-all-symbols'
9202 allow_undefined_flag=unsupported
9203 always_export_symbols=no
9204 enable_shared_with_static_runtimes=yes
9205 export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
9206
9207 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
9208 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
9209 # If the export-symbols file already is a .def file (1st line
9210 # is EXPORTS), use it as is; otherwise, prepend...
9211 archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
9212 cp $export_symbols $output_objdir/$soname.def;
9213 else
9214 echo EXPORTS > $output_objdir/$soname.def;
9215 cat $export_symbols >> $output_objdir/$soname.def;
9216 fi~
9217 $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
9218 else
9219 ld_shlibs=no
9220 fi
9221 ;;
c906108c 9222
b686ecb5
JM
9223 haiku*)
9224 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
9225 link_all_deplibs=yes
9226 ;;
81ecdfbb 9227
b686ecb5
JM
9228 interix[3-9]*)
9229 hardcode_direct=no
9230 hardcode_shlibpath_var=no
9231 hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
9232 export_dynamic_flag_spec='${wl}-E'
9233 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
9234 # Instead, shared libraries are loaded at an image base (0x10000000 by
9235 # default) and relocated if they conflict, which is a slow very memory
9236 # consuming and fragmenting process. To avoid this, we pick a random,
9237 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
9238 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
9239 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
9240 archive_expsym_cmds='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
9241 ;;
c906108c 9242
b686ecb5
JM
9243 gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
9244 tmp_diet=no
9245 if test "$host_os" = linux-dietlibc; then
9246 case $cc_basename in
9247 diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn)
9248 esac
9249 fi
9250 if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
9251 && test "$tmp_diet" = no
9252 then
9253 tmp_addflag=' $pic_flag'
9254 tmp_sharedflag='-shared'
9255 case $cc_basename,$host_cpu in
9256 pgcc*) # Portland Group C compiler
9257 whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
9258 tmp_addflag=' $pic_flag'
9259 ;;
9260 pgf77* | pgf90* | pgf95* | pgfortran*)
9261 # Portland Group f77 and f90 compilers
9262 whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
9263 tmp_addflag=' $pic_flag -Mnomain' ;;
9264 ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
9265 tmp_addflag=' -i_dynamic' ;;
9266 efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
9267 tmp_addflag=' -i_dynamic -nofor_main' ;;
9268 ifc* | ifort*) # Intel Fortran compiler
9269 tmp_addflag=' -nofor_main' ;;
9270 lf95*) # Lahey Fortran 8.1
9271 whole_archive_flag_spec=
9272 tmp_sharedflag='--shared' ;;
9273 xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below)
9274 tmp_sharedflag='-qmkshrobj'
9275 tmp_addflag= ;;
9276 nvcc*) # Cuda Compiler Driver 2.2
9277 whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
9278 compiler_needs_object=yes
9279 ;;
9280 esac
9281 case `$CC -V 2>&1 | sed 5q` in
9282 *Sun\ C*) # Sun C 5.9
9283 whole_archive_flag_spec='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
9284 compiler_needs_object=yes
9285 tmp_sharedflag='-G' ;;
9286 *Sun\ F*) # Sun Fortran 8.3
9287 tmp_sharedflag='-G' ;;
9288 esac
9289 archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
c906108c 9290
b686ecb5
JM
9291 if test "x$supports_anon_versioning" = xyes; then
9292 archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
9293 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
9294 echo "local: *; };" >> $output_objdir/$libname.ver~
9295 $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
9296 fi
c906108c 9297
b686ecb5
JM
9298 case $cc_basename in
9299 xlf* | bgf* | bgxlf* | mpixlf*)
9300 # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
9301 whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
9302 hardcode_libdir_flag_spec=
9303 hardcode_libdir_flag_spec_ld='-rpath $libdir'
9304 archive_cmds='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib'
9305 if test "x$supports_anon_versioning" = xyes; then
9306 archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
9307 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
9308 echo "local: *; };" >> $output_objdir/$libname.ver~
9309 $LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
9310 fi
9311 ;;
9312 esac
9313 else
9314 ld_shlibs=no
9315 fi
9316 ;;
c906108c 9317
b686ecb5
JM
9318 netbsd*)
9319 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
9320 archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
9321 wlarc=
9322 else
9323 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
9324 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
9325 fi
9326 ;;
c906108c 9327
b686ecb5
JM
9328 solaris*)
9329 if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
9330 ld_shlibs=no
9331 cat <<_LT_EOF 1>&2
9332
9333*** Warning: The releases 2.8.* of the GNU linker cannot reliably
9334*** create shared libraries on Solaris systems. Therefore, libtool
9335*** is disabling shared libraries support. We urge you to upgrade GNU
9336*** binutils to release 2.9.1 or newer. Another option is to modify
9337*** your PATH or compiler configuration so that the native linker is
9338*** used, and then restart.
9339
9340_LT_EOF
9341 elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
9342 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
9343 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
9344 else
9345 ld_shlibs=no
9346 fi
9347 ;;
c906108c 9348
b686ecb5
JM
9349 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
9350 case `$LD -v 2>&1` in
9351 *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*)
9352 ld_shlibs=no
9353 cat <<_LT_EOF 1>&2
c906108c 9354
b686ecb5
JM
9355*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
9356*** reliably create shared libraries on SCO systems. Therefore, libtool
9357*** is disabling shared libraries support. We urge you to upgrade GNU
9358*** binutils to release 2.16.91.0.3 or newer. Another option is to modify
9359*** your PATH or compiler configuration so that the native linker is
9360*** used, and then restart.
bec39cab 9361
b686ecb5
JM
9362_LT_EOF
9363 ;;
9364 *)
9365 # For security reasons, it is highly recommended that you always
9366 # use absolute paths for naming shared libraries, and exclude the
9367 # DT_RUNPATH tag from executables and libraries. But doing so
9368 # requires that you compile everything twice, which is a pain.
9369 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
9370 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
9371 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
9372 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
9373 else
9374 ld_shlibs=no
9375 fi
9376 ;;
9377 esac
9378 ;;
c906108c 9379
b686ecb5
JM
9380 sunos4*)
9381 archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
9382 wlarc=
9383 hardcode_direct=yes
9384 hardcode_shlibpath_var=no
9385 ;;
bec39cab 9386
b686ecb5
JM
9387 *)
9388 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
9389 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
9390 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
9391 else
9392 ld_shlibs=no
9393 fi
9394 ;;
9395 esac
bec39cab 9396
b686ecb5
JM
9397 if test "$ld_shlibs" = no; then
9398 runpath_var=
9399 hardcode_libdir_flag_spec=
9400 export_dynamic_flag_spec=
9401 whole_archive_flag_spec=
9402 fi
9403 else
9404 # PORTME fill in a description of your system's linker (not GNU ld)
9405 case $host_os in
9406 aix3*)
9407 allow_undefined_flag=unsupported
9408 always_export_symbols=yes
9409 archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname'
9410 # Note: this linker hardcodes the directories in LIBPATH if there
9411 # are no directories specified by -L.
9412 hardcode_minus_L=yes
9413 if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
9414 # Neither direct hardcoding nor static linking is supported with a
9415 # broken collect2.
9416 hardcode_direct=unsupported
9417 fi
9418 ;;
9419
9420 aix[4-9]*)
9421 if test "$host_cpu" = ia64; then
9422 # On IA64, the linker does run time linking by default, so we don't
9423 # have to do anything special.
9424 aix_use_runtimelinking=no
9425 exp_sym_flag='-Bexport'
9426 no_entry_flag=""
9427 else
9428 # If we're using GNU nm, then we don't want the "-C" option.
9429 # -C means demangle to AIX nm, but means don't demangle with GNU nm
9430 # Also, AIX nm treats weak defined symbols like other global
9431 # defined symbols, whereas GNU nm marks them as "W".
9432 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
9433 export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
9434 else
9435 export_symbols_cmds='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
9436 fi
9437 aix_use_runtimelinking=no
9438
9439 # Test if we are trying to use run time linking or normal
9440 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
9441 # need to do runtime linking.
9442 case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
9443 for ld_flag in $LDFLAGS; do
9444 if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
9445 aix_use_runtimelinking=yes
9446 break
9447 fi
9448 done
9449 ;;
9450 esac
9451
9452 exp_sym_flag='-bexport'
9453 no_entry_flag='-bnoentry'
9454 fi
9455
9456 # When large executables or shared objects are built, AIX ld can
9457 # have problems creating the table of contents. If linking a library
9458 # or program results in "error TOC overflow" add -mminimal-toc to
9459 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
9460 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
9461
9462 archive_cmds=''
9463 hardcode_direct=yes
9464 hardcode_direct_absolute=yes
9465 hardcode_libdir_separator=':'
9466 link_all_deplibs=yes
9467 file_list_spec='${wl}-f,'
9468
9469 if test "$GCC" = yes; then
9470 case $host_os in aix4.[012]|aix4.[012].*)
9471 # We only want to do this on AIX 4.2 and lower, the check
9472 # below for broken collect2 doesn't work under 4.3+
9473 collect2name=`${CC} -print-prog-name=collect2`
9474 if test -f "$collect2name" &&
9475 strings "$collect2name" | $GREP resolve_lib_name >/dev/null
9476 then
9477 # We have reworked collect2
9478 :
9479 else
9480 # We have old collect2
9481 hardcode_direct=unsupported
9482 # It fails to find uninstalled libraries when the uninstalled
9483 # path is not listed in the libpath. Setting hardcode_minus_L
9484 # to unsupported forces relinking
9485 hardcode_minus_L=yes
9486 hardcode_libdir_flag_spec='-L$libdir'
9487 hardcode_libdir_separator=
9488 fi
9489 ;;
9490 esac
9491 shared_flag='-shared'
9492 if test "$aix_use_runtimelinking" = yes; then
9493 shared_flag="$shared_flag "'${wl}-G'
9494 fi
9495 else
9496 # not using gcc
9497 if test "$host_cpu" = ia64; then
9498 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
9499 # chokes on -Wl,-G. The following line is correct:
9500 shared_flag='-G'
9501 else
9502 if test "$aix_use_runtimelinking" = yes; then
9503 shared_flag='${wl}-G'
9504 else
9505 shared_flag='${wl}-bM:SRE'
9506 fi
9507 fi
9508 fi
9509
9510 export_dynamic_flag_spec='${wl}-bexpall'
9511 # It seems that -bexpall does not export symbols beginning with
9512 # underscore (_), so it is better to generate a list of symbols to export.
9513 always_export_symbols=yes
9514 if test "$aix_use_runtimelinking" = yes; then
9515 # Warning - without using the other runtime loading flags (-brtl),
9516 # -berok will link without error, but may produce a broken library.
9517 allow_undefined_flag='-berok'
9518 # Determine the default libpath from the value encoded in an
9519 # empty executable.
9520 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 9521/* end confdefs.h. */
ddc9cd0f 9522
bec39cab
AC
9523int
9524main ()
9525{
b686ecb5 9526
bec39cab
AC
9527 ;
9528 return 0;
9529}
9530_ACEOF
b686ecb5 9531if ac_fn_c_try_link "$LINENO"; then :
ddc9cd0f 9532
b686ecb5
JM
9533lt_aix_libpath_sed='
9534 /Import File Strings/,/^$/ {
9535 /^0/ {
9536 s/^0 *\(.*\)$/\1/
9537 p
9538 }
9539 }'
9540aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
9541# Check for a 64-bit object if we didn't find anything.
9542if test -z "$aix_libpath"; then
9543 aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
bec39cab 9544fi
bec39cab 9545fi
b686ecb5
JM
9546rm -f core conftest.err conftest.$ac_objext \
9547 conftest$ac_exeext conftest.$ac_ext
9548if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
96baa820 9549
b686ecb5
JM
9550 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
9551 archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
9552 else
9553 if test "$host_cpu" = ia64; then
9554 hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
9555 allow_undefined_flag="-z nodefs"
9556 archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
9557 else
9558 # Determine the default libpath from the value encoded in an
9559 # empty executable.
9560 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
b4e70030
JB
9561/* end confdefs.h. */
9562
b4e70030
JB
9563int
9564main ()
9565{
b686ecb5 9566
b4e70030
JB
9567 ;
9568 return 0;
9569}
9570_ACEOF
b686ecb5 9571if ac_fn_c_try_link "$LINENO"; then :
b4e70030 9572
b686ecb5
JM
9573lt_aix_libpath_sed='
9574 /Import File Strings/,/^$/ {
9575 /^0/ {
9576 s/^0 *\(.*\)$/\1/
9577 p
9578 }
9579 }'
9580aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
9581# Check for a 64-bit object if we didn't find anything.
9582if test -z "$aix_libpath"; then
9583 aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
b4e70030 9584fi
b4e70030 9585fi
b686ecb5
JM
9586rm -f core conftest.err conftest.$ac_objext \
9587 conftest$ac_exeext conftest.$ac_ext
9588if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
9589
9590 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
9591 # Warning - without using the other run time loading flags,
9592 # -berok will link without error, but may produce a broken library.
9593 no_undefined_flag=' ${wl}-bernotok'
9594 allow_undefined_flag=' ${wl}-berok'
9595 if test "$with_gnu_ld" = yes; then
9596 # We only use this code for GNU lds that support --whole-archive.
9597 whole_archive_flag_spec='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
9598 else
9599 # Exported symbols can be pulled into shared objects from archives
9600 whole_archive_flag_spec='$convenience'
9601 fi
9602 archive_cmds_need_lc=yes
9603 # This is similar to how AIX traditionally builds its shared libraries.
9604 archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
9605 fi
9606 fi
9607 ;;
b4e70030 9608
b686ecb5
JM
9609 amigaos*)
9610 case $host_cpu in
9611 powerpc)
9612 # see comment about AmigaOS4 .so support
9613 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
9614 archive_expsym_cmds=''
9615 ;;
9616 m68k)
9617 archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
9618 hardcode_libdir_flag_spec='-L$libdir'
9619 hardcode_minus_L=yes
9620 ;;
9621 esac
9622 ;;
b4e70030 9623
b686ecb5
JM
9624 bsdi[45]*)
9625 export_dynamic_flag_spec=-rdynamic
9626 ;;
b4e70030 9627
b686ecb5
JM
9628 cygwin* | mingw* | pw32* | cegcc*)
9629 # When not using gcc, we currently assume that we are using
9630 # Microsoft Visual C++.
9631 # hardcode_libdir_flag_spec is actually meaningless, as there is
9632 # no search path for DLLs.
9633 hardcode_libdir_flag_spec=' '
9634 allow_undefined_flag=unsupported
9635 # Tell ltmain to make .lib files, not .a files.
9636 libext=lib
9637 # Tell ltmain to make .dll files, not .so files.
9638 shrext_cmds=".dll"
9639 # FIXME: Setting linknames here is a bad hack.
9640 archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
9641 # The linker will automatically build a .lib file if we build a DLL.
9642 old_archive_from_new_cmds='true'
9643 # FIXME: Should let the user specify the lib program.
9644 old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
9645 fix_srcfile_path='`cygpath -w "$srcfile"`'
9646 enable_shared_with_static_runtimes=yes
9647 ;;
b040ad30 9648
b686ecb5 9649 darwin* | rhapsody*)
b040ad30 9650
b040ad30 9651
b686ecb5
JM
9652 archive_cmds_need_lc=no
9653 hardcode_direct=no
9654 hardcode_automatic=yes
9655 hardcode_shlibpath_var=unsupported
9656 if test "$lt_cv_ld_force_load" = "yes"; then
9657 whole_archive_flag_spec='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
9658 else
9659 whole_archive_flag_spec=''
9660 fi
9661 link_all_deplibs=yes
9662 allow_undefined_flag="$_lt_dar_allow_undefined"
9663 case $cc_basename in
9664 ifort*) _lt_dar_can_shared=yes ;;
9665 *) _lt_dar_can_shared=$GCC ;;
9666 esac
9667 if test "$_lt_dar_can_shared" = "yes"; then
9668 output_verbose_link_cmd=func_echo_all
9669 archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
9670 module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
9671 archive_expsym_cmds="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
9672 module_expsym_cmds="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}"
233a11ab 9673
b686ecb5
JM
9674 else
9675 ld_shlibs=no
9676 fi
233a11ab 9677
b686ecb5 9678 ;;
233a11ab 9679
b686ecb5
JM
9680 dgux*)
9681 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
9682 hardcode_libdir_flag_spec='-L$libdir'
9683 hardcode_shlibpath_var=no
9684 ;;
b040ad30 9685
b686ecb5
JM
9686 # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
9687 # support. Future versions do this automatically, but an explicit c++rt0.o
9688 # does not break anything, and helps significantly (at the cost of a little
9689 # extra space).
9690 freebsd2.2*)
9691 archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
9692 hardcode_libdir_flag_spec='-R$libdir'
9693 hardcode_direct=yes
9694 hardcode_shlibpath_var=no
9695 ;;
233a11ab 9696
b686ecb5
JM
9697 # Unfortunately, older versions of FreeBSD 2 do not have this feature.
9698 freebsd2.*)
9699 archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
9700 hardcode_direct=yes
9701 hardcode_minus_L=yes
9702 hardcode_shlibpath_var=no
9703 ;;
77f120bf 9704
b686ecb5
JM
9705 # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
9706 freebsd* | dragonfly*)
9707 archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
9708 hardcode_libdir_flag_spec='-R$libdir'
9709 hardcode_direct=yes
9710 hardcode_shlibpath_var=no
9711 ;;
2cac01e3 9712
b686ecb5
JM
9713 hpux9*)
9714 if test "$GCC" = yes; then
9715 archive_cmds='$RM $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
9716 else
9717 archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
9718 fi
9719 hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
9720 hardcode_libdir_separator=:
9721 hardcode_direct=yes
9722
9723 # hardcode_minus_L: Not really in the search PATH,
9724 # but as the default location of the library.
9725 hardcode_minus_L=yes
9726 export_dynamic_flag_spec='${wl}-E'
9727 ;;
2cac01e3 9728
b686ecb5
JM
9729 hpux10*)
9730 if test "$GCC" = yes && test "$with_gnu_ld" = no; then
9731 archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
9732 else
9733 archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
9734 fi
9735 if test "$with_gnu_ld" = no; then
9736 hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
9737 hardcode_libdir_flag_spec_ld='+b $libdir'
9738 hardcode_libdir_separator=:
9739 hardcode_direct=yes
9740 hardcode_direct_absolute=yes
9741 export_dynamic_flag_spec='${wl}-E'
9742 # hardcode_minus_L: Not really in the search PATH,
9743 # but as the default location of the library.
9744 hardcode_minus_L=yes
9745 fi
9746 ;;
2cac01e3 9747
b686ecb5
JM
9748 hpux11*)
9749 if test "$GCC" = yes && test "$with_gnu_ld" = no; then
9750 case $host_cpu in
9751 hppa*64*)
9752 archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
9753 ;;
9754 ia64*)
9755 archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
9756 ;;
9757 *)
9758 archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
9759 ;;
9760 esac
9761 else
9762 case $host_cpu in
9763 hppa*64*)
9764 archive_cmds='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
9765 ;;
9766 ia64*)
9767 archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
9768 ;;
9769 *)
2cac01e3 9770
b686ecb5
JM
9771 # Older versions of the 11.00 compiler do not understand -b yet
9772 # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
9773 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5
9774$as_echo_n "checking if $CC understands -b... " >&6; }
9775if ${lt_cv_prog_compiler__b+:} false; then :
9776 $as_echo_n "(cached) " >&6
2cac01e3 9777else
b686ecb5
JM
9778 lt_cv_prog_compiler__b=no
9779 save_LDFLAGS="$LDFLAGS"
9780 LDFLAGS="$LDFLAGS -b"
9781 echo "$lt_simple_link_test_code" > conftest.$ac_ext
9782 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
9783 # The linker can only warn and ignore the option if not recognized
9784 # So say no if there are warnings
9785 if test -s conftest.err; then
9786 # Append any errors to the config.log.
9787 cat conftest.err 1>&5
9788 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
9789 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
9790 if diff conftest.exp conftest.er2 >/dev/null; then
9791 lt_cv_prog_compiler__b=yes
9792 fi
9793 else
9794 lt_cv_prog_compiler__b=yes
9795 fi
9796 fi
9797 $RM -r conftest*
9798 LDFLAGS="$save_LDFLAGS"
9799
2cac01e3 9800fi
b686ecb5
JM
9801{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5
9802$as_echo "$lt_cv_prog_compiler__b" >&6; }
9803
9804if test x"$lt_cv_prog_compiler__b" = xyes; then
9805 archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
2cac01e3 9806else
b686ecb5 9807 archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
2cac01e3
FS
9808fi
9809
b686ecb5
JM
9810 ;;
9811 esac
9812 fi
9813 if test "$with_gnu_ld" = no; then
9814 hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
9815 hardcode_libdir_separator=:
9816
9817 case $host_cpu in
9818 hppa*64*|ia64*)
9819 hardcode_direct=no
9820 hardcode_shlibpath_var=no
9821 ;;
9822 *)
9823 hardcode_direct=yes
9824 hardcode_direct_absolute=yes
9825 export_dynamic_flag_spec='${wl}-E'
9826
9827 # hardcode_minus_L: Not really in the search PATH,
9828 # but as the default location of the library.
9829 hardcode_minus_L=yes
9830 ;;
9831 esac
9832 fi
9833 ;;
2cac01e3 9834
b686ecb5
JM
9835 irix5* | irix6* | nonstopux*)
9836 if test "$GCC" = yes; then
9837 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
9838 # Try to use the -exported_symbol ld option, if it does not
9839 # work, assume that -exports_file does not work either and
9840 # implicitly export all symbols.
9841 save_LDFLAGS="$LDFLAGS"
9842 LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
9843 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9844/* end confdefs.h. */
9845int foo(void) {}
2cac01e3
FS
9846_ACEOF
9847if ac_fn_c_try_link "$LINENO"; then :
b686ecb5 9848 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
2cac01e3 9849
2cac01e3
FS
9850fi
9851rm -f core conftest.err conftest.$ac_objext \
9852 conftest$ac_exeext conftest.$ac_ext
b686ecb5
JM
9853 LDFLAGS="$save_LDFLAGS"
9854 else
9855 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
9856 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
9857 fi
9858 archive_cmds_need_lc='no'
9859 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
9860 hardcode_libdir_separator=:
9861 inherit_rpath=yes
9862 link_all_deplibs=yes
9863 ;;
2cac01e3 9864
b686ecb5
JM
9865 netbsd*)
9866 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
9867 archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
9868 else
9869 archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
9870 fi
9871 hardcode_libdir_flag_spec='-R$libdir'
9872 hardcode_direct=yes
9873 hardcode_shlibpath_var=no
9874 ;;
2cac01e3 9875
b686ecb5
JM
9876 newsos6)
9877 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
9878 hardcode_direct=yes
9879 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
9880 hardcode_libdir_separator=:
9881 hardcode_shlibpath_var=no
9882 ;;
2cac01e3 9883
b686ecb5
JM
9884 *nto* | *qnx*)
9885 ;;
2cac01e3 9886
b686ecb5
JM
9887 openbsd*)
9888 if test -f /usr/libexec/ld.so; then
9889 hardcode_direct=yes
9890 hardcode_shlibpath_var=no
9891 hardcode_direct_absolute=yes
9892 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
9893 archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
9894 archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
9895 hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
9896 export_dynamic_flag_spec='${wl}-E'
9897 else
9898 case $host_os in
9899 openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
9900 archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
9901 hardcode_libdir_flag_spec='-R$libdir'
9902 ;;
9903 *)
9904 archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
9905 hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
9906 ;;
9907 esac
9908 fi
9909 else
9910 ld_shlibs=no
9911 fi
9912 ;;
2cac01e3 9913
b686ecb5
JM
9914 os2*)
9915 hardcode_libdir_flag_spec='-L$libdir'
9916 hardcode_minus_L=yes
9917 allow_undefined_flag=unsupported
9918 archive_cmds='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~echo DATA >> $output_objdir/$libname.def~echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
9919 old_archive_from_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
9920 ;;
2cac01e3 9921
b686ecb5
JM
9922 osf3*)
9923 if test "$GCC" = yes; then
9924 allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
9925 archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
9926 else
9927 allow_undefined_flag=' -expect_unresolved \*'
9928 archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
9929 fi
9930 archive_cmds_need_lc='no'
9931 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
9932 hardcode_libdir_separator=:
9933 ;;
2cac01e3 9934
b686ecb5
JM
9935 osf4* | osf5*) # as osf3* with the addition of -msym flag
9936 if test "$GCC" = yes; then
9937 allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
9938 archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
9939 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
9940 else
9941 allow_undefined_flag=' -expect_unresolved \*'
9942 archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
9943 archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~
9944 $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
2cac01e3 9945
b686ecb5
JM
9946 # Both c and cxx compiler support -rpath directly
9947 hardcode_libdir_flag_spec='-rpath $libdir'
9948 fi
9949 archive_cmds_need_lc='no'
9950 hardcode_libdir_separator=:
9951 ;;
2cac01e3 9952
b686ecb5
JM
9953 solaris*)
9954 no_undefined_flag=' -z defs'
9955 if test "$GCC" = yes; then
9956 wlarc='${wl}'
9957 archive_cmds='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
9958 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
9959 $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
9960 else
9961 case `$CC -V 2>&1` in
9962 *"Compilers 5.0"*)
9963 wlarc=''
9964 archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
9965 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
9966 $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
9967 ;;
9968 *)
9969 wlarc='${wl}'
9970 archive_cmds='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags'
9971 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
9972 $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
9973 ;;
9974 esac
9975 fi
9976 hardcode_libdir_flag_spec='-R$libdir'
9977 hardcode_shlibpath_var=no
9978 case $host_os in
9979 solaris2.[0-5] | solaris2.[0-5].*) ;;
9980 *)
9981 # The compiler driver will combine and reorder linker options,
9982 # but understands `-z linker_flag'. GCC discards it without `$wl',
9983 # but is careful enough not to reorder.
9984 # Supported since Solaris 2.6 (maybe 2.5.1?)
9985 if test "$GCC" = yes; then
9986 whole_archive_flag_spec='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
9987 else
9988 whole_archive_flag_spec='-z allextract$convenience -z defaultextract'
9989 fi
9990 ;;
9991 esac
9992 link_all_deplibs=yes
9993 ;;
9994
9995 sunos4*)
9996 if test "x$host_vendor" = xsequent; then
9997 # Use $CC to link under sequent, because it throws in some extra .o
9998 # files that make .init and .fini sections work.
9999 archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
10000 else
10001 archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
10002 fi
10003 hardcode_libdir_flag_spec='-L$libdir'
10004 hardcode_direct=yes
10005 hardcode_minus_L=yes
10006 hardcode_shlibpath_var=no
10007 ;;
2cac01e3 10008
b686ecb5
JM
10009 sysv4)
10010 case $host_vendor in
10011 sni)
10012 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
10013 hardcode_direct=yes # is this really true???
10014 ;;
10015 siemens)
10016 ## LD is ld it makes a PLAMLIB
10017 ## CC just makes a GrossModule.
10018 archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
10019 reload_cmds='$CC -r -o $output$reload_objs'
10020 hardcode_direct=no
10021 ;;
10022 motorola)
10023 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
10024 hardcode_direct=no #Motorola manual says yes, but my tests say they lie
10025 ;;
10026 esac
10027 runpath_var='LD_RUN_PATH'
10028 hardcode_shlibpath_var=no
10029 ;;
2cac01e3 10030
b686ecb5
JM
10031 sysv4.3*)
10032 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
10033 hardcode_shlibpath_var=no
10034 export_dynamic_flag_spec='-Bexport'
10035 ;;
2cac01e3 10036
b686ecb5
JM
10037 sysv4*MP*)
10038 if test -d /usr/nec; then
10039 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
10040 hardcode_shlibpath_var=no
10041 runpath_var=LD_RUN_PATH
10042 hardcode_runpath_var=yes
10043 ld_shlibs=yes
10044 fi
10045 ;;
2cac01e3 10046
b686ecb5
JM
10047 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
10048 no_undefined_flag='${wl}-z,text'
10049 archive_cmds_need_lc=no
10050 hardcode_shlibpath_var=no
10051 runpath_var='LD_RUN_PATH'
2cac01e3 10052
b686ecb5
JM
10053 if test "$GCC" = yes; then
10054 archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
10055 archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
10056 else
10057 archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
10058 archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
10059 fi
10060 ;;
2cac01e3 10061
b686ecb5
JM
10062 sysv5* | sco3.2v5* | sco5v6*)
10063 # Note: We can NOT use -z defs as we might desire, because we do not
10064 # link with -lc, and that would cause any symbols used from libc to
10065 # always be unresolved, which means just about no library would
10066 # ever link correctly. If we're not using GNU ld we use -z text
10067 # though, which does catch some bad symbols but isn't as heavy-handed
10068 # as -z defs.
10069 no_undefined_flag='${wl}-z,text'
10070 allow_undefined_flag='${wl}-z,nodefs'
10071 archive_cmds_need_lc=no
10072 hardcode_shlibpath_var=no
10073 hardcode_libdir_flag_spec='${wl}-R,$libdir'
10074 hardcode_libdir_separator=':'
10075 link_all_deplibs=yes
10076 export_dynamic_flag_spec='${wl}-Bexport'
10077 runpath_var='LD_RUN_PATH'
10078
10079 if test "$GCC" = yes; then
10080 archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
10081 archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
10082 else
10083 archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
10084 archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
10085 fi
10086 ;;
2cac01e3 10087
b686ecb5
JM
10088 uts4*)
10089 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
10090 hardcode_libdir_flag_spec='-L$libdir'
10091 hardcode_shlibpath_var=no
10092 ;;
2cac01e3 10093
b686ecb5
JM
10094 *)
10095 ld_shlibs=no
10096 ;;
10097 esac
10098
10099 if test x$host_vendor = xsni; then
10100 case $host in
10101 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
10102 export_dynamic_flag_spec='${wl}-Blargedynsym'
10103 ;;
10104 esac
10105 fi
016a3251 10106 fi
016a3251 10107
b686ecb5
JM
10108{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5
10109$as_echo "$ld_shlibs" >&6; }
10110test "$ld_shlibs" = no && can_build_shared=no
016a3251 10111
b686ecb5 10112with_gnu_ld=$with_gnu_ld
016a3251 10113
b686ecb5
JM
10114
10115
10116
10117
10118
10119
10120
10121
10122
10123
10124
10125
10126
10127
10128#
10129# Do we need to explicitly link libc?
10130#
10131case "x$archive_cmds_need_lc" in
10132x|xyes)
10133 # Assume -lc should be added
10134 archive_cmds_need_lc=yes
10135
10136 if test "$enable_shared" = yes && test "$GCC" = yes; then
10137 case $archive_cmds in
10138 *'~'*)
10139 # FIXME: we may have to deal with multi-command sequences.
016a3251 10140 ;;
b686ecb5
JM
10141 '$CC '*)
10142 # Test whether the compiler implicitly links with -lc since on some
10143 # systems, -lgcc has to come before -lc. If gcc already passes -lc
10144 # to ld, don't add -lc before -lgcc.
10145 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5
10146$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; }
10147if ${lt_cv_archive_cmds_need_lc+:} false; then :
016a3251
DD
10148 $as_echo_n "(cached) " >&6
10149else
b686ecb5
JM
10150 $RM conftest*
10151 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
10152
10153 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
10154 (eval $ac_compile) 2>&5
10155 ac_status=$?
10156 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
10157 test $ac_status = 0; } 2>conftest.err; then
10158 soname=conftest
10159 lib=conftest
10160 libobjs=conftest.$ac_objext
10161 deplibs=
10162 wl=$lt_prog_compiler_wl
10163 pic_flag=$lt_prog_compiler_pic
10164 compiler_flags=-v
10165 linker_flags=-v
10166 verstring=
10167 output_objdir=.
10168 libname=conftest
10169 lt_save_allow_undefined_flag=$allow_undefined_flag
10170 allow_undefined_flag=
10171 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5
10172 (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5
10173 ac_status=$?
10174 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
10175 test $ac_status = 0; }
10176 then
10177 lt_cv_archive_cmds_need_lc=no
10178 else
10179 lt_cv_archive_cmds_need_lc=yes
10180 fi
10181 allow_undefined_flag=$lt_save_allow_undefined_flag
10182 else
10183 cat conftest.err 1>&5
10184 fi
10185 $RM conftest*
016a3251 10186
016a3251 10187fi
b686ecb5
JM
10188{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5
10189$as_echo "$lt_cv_archive_cmds_need_lc" >&6; }
10190 archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc
10191 ;;
10192 esac
10193 fi
10194 ;;
10195esac
016a3251
DD
10196
10197
10198
016a3251 10199
016a3251 10200
016a3251
DD
10201
10202
10203
10204
10205
10206
10207
10208
016a3251 10209
016a3251 10210
016a3251 10211
77f120bf 10212
6c7a06a3 10213
016a3251 10214
016a3251 10215
016a3251 10216
016a3251 10217
6c7a06a3 10218
81ecdfbb 10219
9f1528a1 10220
9f1528a1 10221
9f1528a1 10222
016a3251 10223
016a3251 10224
016a3251 10225
016a3251 10226
016a3251 10227
016a3251 10228
016a3251 10229
016a3251 10230
016a3251 10231
016a3251 10232
016a3251
DD
10233
10234
10235
10236
10237
6c7a06a3 10238
6c7a06a3 10239
6c7a06a3 10240
94ae1714 10241
94ae1714 10242
6c7a06a3 10243
016a3251 10244
94ae1714 10245
016a3251 10246
016a3251 10247
016a3251 10248
016a3251 10249
94ae1714 10250
6c7a06a3 10251
6c7a06a3 10252
6c7a06a3 10253
b4e70030 10254
6c7a06a3 10255
6c7a06a3 10256
6c7a06a3 10257
6c7a06a3 10258
6c7a06a3 10259
6c7a06a3
TT
10260
10261
478aac75
DE
10262
10263
478aac75 10264
478aac75
DE
10265
10266
478aac75 10267
478aac75
DE
10268
10269
10270
478aac75
DE
10271
10272
cb01cfba 10273
6c7a06a3 10274
81ecdfbb 10275
6c7a06a3 10276
6c7a06a3
TT
10277
10278
cb01cfba 10279
6c7a06a3 10280
6c7a06a3 10281
6c7a06a3 10282
6c7a06a3 10283
6c7a06a3 10284
6c7a06a3 10285
06825bd1 10286
06825bd1 10287
8ee53726 10288
3841debe 10289
6a30b0a5 10290
6a30b0a5 10291
7c26f8da 10292
7c26f8da 10293
5593a99a 10294
5593a99a 10295
5593a99a 10296
86c6b807 10297
6a30b0a5
AS
10298
10299
10300
10301
10302
f997c383 10303
f997c383 10304
f997c383 10305
f997c383 10306
f997c383
SD
10307
10308
10309
f997c383
SD
10310
10311
f997c383 10312
f997c383 10313
f997c383
SD
10314
10315
10316
f997c383
SD
10317
10318
f997c383 10319
f997c383 10320
f997c383
SD
10321
10322
10323
f997c383
SD
10324
10325
10326
f997c383
SD
10327
10328
f997c383
SD
10329
10330
a2d08b9e 10331
a2d08b9e 10332
a2d08b9e 10333
a2d08b9e
SD
10334
10335
39037522 10336
b8e0a31c 10337
b8e0a31c
SD
10338
10339
b8e0a31c 10340
b8e0a31c
SD
10341
10342
10343
10344
b8e0a31c 10345
b8e0a31c
SD
10346
10347
10348
10349
10350
81ecdfbb 10351
5c39566f 10352
b686ecb5
JM
10353 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5
10354$as_echo_n "checking dynamic linker characteristics... " >&6; }
5c39566f 10355
b686ecb5
JM
10356if test "$GCC" = yes; then
10357 case $host_os in
10358 darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
10359 *) lt_awk_arg="/^libraries:/" ;;
10360 esac
10361 case $host_os in
10362 mingw* | cegcc*) lt_sed_strip_eq="s,=\([A-Za-z]:\),\1,g" ;;
10363 *) lt_sed_strip_eq="s,=/,/,g" ;;
10364 esac
10365 lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
10366 case $lt_search_path_spec in
10367 *\;*)
10368 # if the path contains ";" then we assume it to be the separator
10369 # otherwise default to the standard path separator (i.e. ":") - it is
10370 # assumed that no part of a normal pathname contains ";" but that should
10371 # okay in the real world where ";" in dirpaths is itself problematic.
10372 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
10373 ;;
10374 *)
10375 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
10376 ;;
10377 esac
10378 # Ok, now we have the path, separated by spaces, we can step through it
10379 # and add multilib dir if necessary.
10380 lt_tmp_lt_search_path_spec=
10381 lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
10382 for lt_sys_path in $lt_search_path_spec; do
10383 if test -d "$lt_sys_path/$lt_multi_os_dir"; then
10384 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
10385 else
10386 test -d "$lt_sys_path" && \
10387 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
10388 fi
10389 done
10390 lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
10391BEGIN {RS=" "; FS="/|\n";} {
10392 lt_foo="";
10393 lt_count=0;
10394 for (lt_i = NF; lt_i > 0; lt_i--) {
10395 if ($lt_i != "" && $lt_i != ".") {
10396 if ($lt_i == "..") {
10397 lt_count++;
10398 } else {
10399 if (lt_count == 0) {
10400 lt_foo="/" $lt_i lt_foo;
10401 } else {
10402 lt_count--;
10403 }
10404 }
10405 }
10406 }
10407 if (lt_foo != "") { lt_freq[lt_foo]++; }
10408 if (lt_freq[lt_foo] == 1) { print lt_foo; }
10409}'`
10410 # AWK program above erroneously prepends '/' to C:/dos/paths
10411 # for these hosts.
10412 case $host_os in
10413 mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
10414 $SED 's,/\([A-Za-z]:\),\1,g'` ;;
10415 esac
10416 sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
10417else
10418 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
10419fi
10420library_names_spec=
10421libname_spec='lib$name'
10422soname_spec=
10423shrext_cmds=".so"
10424postinstall_cmds=
10425postuninstall_cmds=
10426finish_cmds=
10427finish_eval=
10428shlibpath_var=
10429shlibpath_overrides_runpath=unknown
10430version_type=none
10431dynamic_linker="$host_os ld.so"
10432sys_lib_dlsearch_path_spec="/lib /usr/lib"
10433need_lib_prefix=unknown
10434hardcode_into_libs=no
10435
10436# when you set need_version to no, make sure it does not cause -set_version
10437# flags to be left without arguments
10438need_version=unknown
3841debe 10439
b686ecb5
JM
10440case $host_os in
10441aix3*)
10442 version_type=linux
10443 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
10444 shlibpath_var=LIBPATH
3841debe 10445
b686ecb5
JM
10446 # AIX 3 has no versioning support, so we append a major version to the name.
10447 soname_spec='${libname}${release}${shared_ext}$major'
10448 ;;
3841debe 10449
b686ecb5
JM
10450aix[4-9]*)
10451 version_type=linux
10452 need_lib_prefix=no
10453 need_version=no
10454 hardcode_into_libs=yes
10455 if test "$host_cpu" = ia64; then
10456 # AIX 5 supports IA64
10457 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
10458 shlibpath_var=LD_LIBRARY_PATH
10459 else
10460 # With GCC up to 2.95.x, collect2 would create an import file
10461 # for dependence libraries. The import file would start with
10462 # the line `#! .'. This would cause the generated library to
10463 # depend on `.', always an invalid library. This was fixed in
10464 # development snapshots of GCC prior to 3.0.
10465 case $host_os in
10466 aix4 | aix4.[01] | aix4.[01].*)
10467 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
10468 echo ' yes '
10469 echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
10470 :
10471 else
10472 can_build_shared=no
10473 fi
10474 ;;
10475 esac
10476 # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
10477 # soname into executable. Probably we can add versioning support to
10478 # collect2, so additional links can be useful in future.
10479 if test "$aix_use_runtimelinking" = yes; then
10480 # If using run time linking (on AIX 4.2 or later) use lib<name>.so
10481 # instead of lib<name>.a to let people know that these are not
10482 # typical AIX shared libraries.
10483 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10484 else
10485 # We preserve .a as extension for shared libraries through AIX4.2
10486 # and later when we are not doing run time linking.
10487 library_names_spec='${libname}${release}.a $libname.a'
10488 soname_spec='${libname}${release}${shared_ext}$major'
10489 fi
10490 shlibpath_var=LIBPATH
10491 fi
10492 ;;
3841debe 10493
b686ecb5
JM
10494amigaos*)
10495 case $host_cpu in
10496 powerpc)
10497 # Since July 2007 AmigaOS4 officially supports .so libraries.
10498 # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
10499 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10500 ;;
10501 m68k)
10502 library_names_spec='$libname.ixlibrary $libname.a'
10503 # Create ${libname}_ixlibrary.a entries in /sys/libs.
10504 finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
10505 ;;
10506 esac
10507 ;;
3841debe 10508
b686ecb5
JM
10509beos*)
10510 library_names_spec='${libname}${shared_ext}'
10511 dynamic_linker="$host_os ld.so"
10512 shlibpath_var=LIBRARY_PATH
10513 ;;
3841debe 10514
b686ecb5
JM
10515bsdi[45]*)
10516 version_type=linux
10517 need_version=no
10518 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10519 soname_spec='${libname}${release}${shared_ext}$major'
10520 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
10521 shlibpath_var=LD_LIBRARY_PATH
10522 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
10523 sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
10524 # the default ld.so.conf also contains /usr/contrib/lib and
10525 # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
10526 # libtool to hard-code these into programs
10527 ;;
3841debe 10528
b686ecb5
JM
10529cygwin* | mingw* | pw32* | cegcc*)
10530 version_type=windows
10531 shrext_cmds=".dll"
10532 need_version=no
10533 need_lib_prefix=no
10534
10535 case $GCC,$host_os in
10536 yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*)
10537 library_names_spec='$libname.dll.a'
10538 # DLL is installed to $(libdir)/../bin by postinstall_cmds
10539 postinstall_cmds='base_file=`basename \${file}`~
10540 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
10541 dldir=$destdir/`dirname \$dlpath`~
10542 test -d \$dldir || mkdir -p \$dldir~
10543 $install_prog $dir/$dlname \$dldir/$dlname~
10544 chmod a+x \$dldir/$dlname~
10545 if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
10546 eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
10547 fi'
10548 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
10549 dlpath=$dir/\$dldll~
10550 $RM \$dlpath'
10551 shlibpath_overrides_runpath=yes
10552
10553 case $host_os in
10554 cygwin*)
10555 # Cygwin DLLs use 'cyg' prefix rather than 'lib'
10556 soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
10557
10558 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"
10559 ;;
10560 mingw* | cegcc*)
10561 # MinGW DLLs use traditional 'lib' prefix
10562 soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
10563 ;;
10564 pw32*)
10565 # pw32 DLLs use 'pw' prefix rather than 'lib'
10566 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
10567 ;;
10568 esac
10569 ;;
3841debe 10570
b686ecb5
JM
10571 *)
10572 library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
10573 ;;
10574 esac
10575 dynamic_linker='Win32 ld.exe'
10576 # FIXME: first we should search . and the directory the executable is in
10577 shlibpath_var=PATH
10578 ;;
3841debe 10579
b686ecb5
JM
10580darwin* | rhapsody*)
10581 dynamic_linker="$host_os dyld"
10582 version_type=darwin
10583 need_lib_prefix=no
10584 need_version=no
10585 library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
10586 soname_spec='${libname}${release}${major}$shared_ext'
10587 shlibpath_overrides_runpath=yes
10588 shlibpath_var=DYLD_LIBRARY_PATH
10589 shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
10590
10591 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"
10592 sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
10593 ;;
3841debe 10594
b686ecb5
JM
10595dgux*)
10596 version_type=linux
10597 need_lib_prefix=no
10598 need_version=no
10599 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
10600 soname_spec='${libname}${release}${shared_ext}$major'
10601 shlibpath_var=LD_LIBRARY_PATH
10602 ;;
3841debe 10603
b686ecb5
JM
10604freebsd* | dragonfly*)
10605 # DragonFly does not have aout. When/if they implement a new
10606 # versioning mechanism, adjust this.
10607 if test -x /usr/bin/objformat; then
10608 objformat=`/usr/bin/objformat`
10609 else
10610 case $host_os in
10611 freebsd[23].*) objformat=aout ;;
10612 *) objformat=elf ;;
10613 esac
10614 fi
10615 version_type=freebsd-$objformat
10616 case $version_type in
10617 freebsd-elf*)
10618 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
10619 need_version=no
10620 need_lib_prefix=no
10621 ;;
10622 freebsd-*)
10623 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
10624 need_version=yes
10625 ;;
10626 esac
10627 shlibpath_var=LD_LIBRARY_PATH
10628 case $host_os in
10629 freebsd2.*)
10630 shlibpath_overrides_runpath=yes
10631 ;;
10632 freebsd3.[01]* | freebsdelf3.[01]*)
10633 shlibpath_overrides_runpath=yes
10634 hardcode_into_libs=yes
10635 ;;
10636 freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
10637 freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
10638 shlibpath_overrides_runpath=no
10639 hardcode_into_libs=yes
10640 ;;
10641 *) # from 4.6 on, and DragonFly
10642 shlibpath_overrides_runpath=yes
10643 hardcode_into_libs=yes
10644 ;;
10645 esac
10646 ;;
3841debe 10647
b686ecb5
JM
10648haiku*)
10649 version_type=linux
10650 need_lib_prefix=no
10651 need_version=no
10652 dynamic_linker="$host_os runtime_loader"
10653 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
10654 soname_spec='${libname}${release}${shared_ext}$major'
10655 shlibpath_var=LIBRARY_PATH
10656 shlibpath_overrides_runpath=yes
10657 sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
10658 hardcode_into_libs=yes
10659 ;;
10660
10661hpux9* | hpux10* | hpux11*)
10662 # Give a soname corresponding to the major version so that dld.sl refuses to
10663 # link against other versions.
10664 version_type=sunos
10665 need_lib_prefix=no
10666 need_version=no
10667 case $host_cpu in
10668 ia64*)
10669 shrext_cmds='.so'
10670 hardcode_into_libs=yes
10671 dynamic_linker="$host_os dld.so"
10672 shlibpath_var=LD_LIBRARY_PATH
10673 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
10674 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10675 soname_spec='${libname}${release}${shared_ext}$major'
10676 if test "X$HPUX_IA64_MODE" = X32; then
10677 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
3841debe 10678 else
b686ecb5
JM
10679 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
10680 fi
10681 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
10682 ;;
10683 hppa*64*)
10684 shrext_cmds='.sl'
10685 hardcode_into_libs=yes
10686 dynamic_linker="$host_os dld.sl"
10687 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
10688 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
10689 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10690 soname_spec='${libname}${release}${shared_ext}$major'
10691 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
10692 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
10693 ;;
10694 *)
10695 shrext_cmds='.sl'
10696 dynamic_linker="$host_os dld.sl"
10697 shlibpath_var=SHLIB_PATH
10698 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
10699 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10700 soname_spec='${libname}${release}${shared_ext}$major'
10701 ;;
10702 esac
10703 # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
10704 postinstall_cmds='chmod 555 $lib'
10705 # or fails outright, so override atomically:
10706 install_override_mode=555
10707 ;;
3841debe 10708
b686ecb5
JM
10709interix[3-9]*)
10710 version_type=linux
10711 need_lib_prefix=no
10712 need_version=no
10713 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
10714 soname_spec='${libname}${release}${shared_ext}$major'
10715 dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
10716 shlibpath_var=LD_LIBRARY_PATH
10717 shlibpath_overrides_runpath=no
10718 hardcode_into_libs=yes
10719 ;;
3841debe 10720
b686ecb5
JM
10721irix5* | irix6* | nonstopux*)
10722 case $host_os in
10723 nonstopux*) version_type=nonstopux ;;
10724 *)
10725 if test "$lt_cv_prog_gnu_ld" = yes; then
10726 version_type=linux
10727 else
10728 version_type=irix
10729 fi ;;
10730 esac
10731 need_lib_prefix=no
10732 need_version=no
10733 soname_spec='${libname}${release}${shared_ext}$major'
10734 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
10735 case $host_os in
10736 irix5* | nonstopux*)
10737 libsuff= shlibsuff=
10738 ;;
10739 *)
10740 case $LD in # libtool.m4 will add one of these switches to LD
10741 *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
10742 libsuff= shlibsuff= libmagic=32-bit;;
10743 *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
10744 libsuff=32 shlibsuff=N32 libmagic=N32;;
10745 *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
10746 libsuff=64 shlibsuff=64 libmagic=64-bit;;
10747 *) libsuff= shlibsuff= libmagic=never-match;;
10748 esac
10749 ;;
10750 esac
10751 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
10752 shlibpath_overrides_runpath=no
10753 sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
10754 sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
10755 hardcode_into_libs=yes
10756 ;;
3841debe 10757
b686ecb5
JM
10758# No shared lib support for Linux oldld, aout, or coff.
10759linux*oldld* | linux*aout* | linux*coff*)
10760 dynamic_linker=no
10761 ;;
3841debe 10762
b686ecb5
JM
10763# This must be Linux ELF.
10764linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
10765 version_type=linux
10766 need_lib_prefix=no
10767 need_version=no
10768 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10769 soname_spec='${libname}${release}${shared_ext}$major'
10770 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
10771 shlibpath_var=LD_LIBRARY_PATH
10772 shlibpath_overrides_runpath=no
10773
10774 # Some binutils ld are patched to set DT_RUNPATH
10775 if ${lt_cv_shlibpath_overrides_runpath+:} false; then :
10776 $as_echo_n "(cached) " >&6
10777else
10778 lt_cv_shlibpath_overrides_runpath=no
10779 save_LDFLAGS=$LDFLAGS
10780 save_libdir=$libdir
10781 eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \
10782 LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\""
10783 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10784/* end confdefs.h. */
3841debe 10785
b686ecb5
JM
10786int
10787main ()
10788{
81ecdfbb 10789
b686ecb5
JM
10790 ;
10791 return 0;
10792}
10793_ACEOF
10794if ac_fn_c_try_link "$LINENO"; then :
10795 if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then :
10796 lt_cv_shlibpath_overrides_runpath=yes
10797fi
10798fi
10799rm -f core conftest.err conftest.$ac_objext \
10800 conftest$ac_exeext conftest.$ac_ext
10801 LDFLAGS=$save_LDFLAGS
10802 libdir=$save_libdir
9f1528a1 10803
9f1528a1
AB
10804fi
10805
b686ecb5 10806 shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
9f1528a1 10807
b686ecb5
JM
10808 # This implies no fast_install, which is unacceptable.
10809 # Some rework will be needed to allow for fast_install
10810 # before this can be enabled.
10811 hardcode_into_libs=yes
3841debe 10812
b686ecb5
JM
10813 # Append ld.so.conf contents to the search path
10814 if test -f /etc/ld.so.conf; then
10815 lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
10816 sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
10817 fi
3841debe 10818
b686ecb5
JM
10819 # We used to test for /lib/ld.so.1 and disable shared libraries on
10820 # powerpc, because MkLinux only supported shared libraries with the
10821 # GNU dynamic linker. Since this was broken with cross compilers,
10822 # most powerpc-linux boxes support dynamic linking these days and
10823 # people can always --disable-shared, the test was removed, and we
10824 # assume the GNU/Linux dynamic linker is in use.
10825 dynamic_linker='GNU/Linux ld.so'
10826 ;;
3841debe 10827
b686ecb5
JM
10828netbsd*)
10829 version_type=sunos
10830 need_lib_prefix=no
10831 need_version=no
10832 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
10833 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
10834 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
10835 dynamic_linker='NetBSD (a.out) ld.so'
10836 else
10837 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
10838 soname_spec='${libname}${release}${shared_ext}$major'
10839 dynamic_linker='NetBSD ld.elf_so'
10840 fi
10841 shlibpath_var=LD_LIBRARY_PATH
10842 shlibpath_overrides_runpath=yes
10843 hardcode_into_libs=yes
10844 ;;
3841debe 10845
b686ecb5
JM
10846newsos6)
10847 version_type=linux
10848 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10849 shlibpath_var=LD_LIBRARY_PATH
10850 shlibpath_overrides_runpath=yes
10851 ;;
3841debe 10852
b686ecb5
JM
10853*nto* | *qnx*)
10854 version_type=qnx
10855 need_lib_prefix=no
10856 need_version=no
10857 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10858 soname_spec='${libname}${release}${shared_ext}$major'
10859 shlibpath_var=LD_LIBRARY_PATH
10860 shlibpath_overrides_runpath=no
10861 hardcode_into_libs=yes
10862 dynamic_linker='ldqnx.so'
10863 ;;
3841debe 10864
b686ecb5
JM
10865openbsd*)
10866 version_type=sunos
10867 sys_lib_dlsearch_path_spec="/usr/lib"
10868 need_lib_prefix=no
10869 # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
10870 case $host_os in
10871 openbsd3.3 | openbsd3.3.*) need_version=yes ;;
10872 *) need_version=no ;;
10873 esac
10874 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
10875 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
10876 shlibpath_var=LD_LIBRARY_PATH
10877 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
10878 case $host_os in
10879 openbsd2.[89] | openbsd2.[89].*)
10880 shlibpath_overrides_runpath=no
10881 ;;
10882 *)
10883 shlibpath_overrides_runpath=yes
10884 ;;
10885 esac
10886 else
10887 shlibpath_overrides_runpath=yes
10888 fi
10889 ;;
3841debe 10890
b686ecb5
JM
10891os2*)
10892 libname_spec='$name'
10893 shrext_cmds=".dll"
10894 need_lib_prefix=no
10895 library_names_spec='$libname${shared_ext} $libname.a'
10896 dynamic_linker='OS/2 ld.exe'
10897 shlibpath_var=LIBPATH
10898 ;;
3841debe 10899
b686ecb5
JM
10900osf3* | osf4* | osf5*)
10901 version_type=osf
10902 need_lib_prefix=no
10903 need_version=no
10904 soname_spec='${libname}${release}${shared_ext}$major'
10905 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10906 shlibpath_var=LD_LIBRARY_PATH
10907 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
10908 sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
10909 ;;
3841debe 10910
b686ecb5
JM
10911rdos*)
10912 dynamic_linker=no
10913 ;;
3841debe 10914
b686ecb5
JM
10915solaris*)
10916 version_type=linux
10917 need_lib_prefix=no
10918 need_version=no
10919 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10920 soname_spec='${libname}${release}${shared_ext}$major'
10921 shlibpath_var=LD_LIBRARY_PATH
10922 shlibpath_overrides_runpath=yes
10923 hardcode_into_libs=yes
10924 # ldd complains unless libraries are executable
10925 postinstall_cmds='chmod +x $lib'
10926 ;;
a9322a30 10927
b686ecb5
JM
10928sunos4*)
10929 version_type=sunos
10930 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
10931 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
10932 shlibpath_var=LD_LIBRARY_PATH
10933 shlibpath_overrides_runpath=yes
10934 if test "$with_gnu_ld" = yes; then
10935 need_lib_prefix=no
10936 fi
10937 need_version=yes
10938 ;;
a9322a30 10939
b686ecb5
JM
10940sysv4 | sysv4.3*)
10941 version_type=linux
10942 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10943 soname_spec='${libname}${release}${shared_ext}$major'
10944 shlibpath_var=LD_LIBRARY_PATH
10945 case $host_vendor in
10946 sni)
10947 shlibpath_overrides_runpath=no
10948 need_lib_prefix=no
10949 runpath_var=LD_RUN_PATH
10950 ;;
10951 siemens)
10952 need_lib_prefix=no
10953 ;;
10954 motorola)
10955 need_lib_prefix=no
10956 need_version=no
10957 shlibpath_overrides_runpath=no
10958 sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
10959 ;;
10960 esac
10961 ;;
a9322a30 10962
b686ecb5
JM
10963sysv4*MP*)
10964 if test -d /usr/nec ;then
10965 version_type=linux
10966 library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
10967 soname_spec='$libname${shared_ext}.$major'
10968 shlibpath_var=LD_LIBRARY_PATH
10969 fi
10970 ;;
a9322a30 10971
b686ecb5
JM
10972sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
10973 version_type=freebsd-elf
10974 need_lib_prefix=no
10975 need_version=no
10976 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
10977 soname_spec='${libname}${release}${shared_ext}$major'
10978 shlibpath_var=LD_LIBRARY_PATH
10979 shlibpath_overrides_runpath=yes
10980 hardcode_into_libs=yes
10981 if test "$with_gnu_ld" = yes; then
10982 sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
10983 else
10984 sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
10985 case $host_os in
10986 sco3.2v5*)
10987 sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
10988 ;;
10989 esac
10990 fi
10991 sys_lib_dlsearch_path_spec='/usr/lib'
10992 ;;
a8111142 10993
b686ecb5
JM
10994tpf*)
10995 # TPF is a cross-target only. Preferred cross-host = GNU/Linux.
10996 version_type=linux
10997 need_lib_prefix=no
10998 need_version=no
10999 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
11000 shlibpath_var=LD_LIBRARY_PATH
11001 shlibpath_overrides_runpath=no
11002 hardcode_into_libs=yes
11003 ;;
a9322a30 11004
b686ecb5
JM
11005uts4*)
11006 version_type=linux
11007 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
11008 soname_spec='${libname}${release}${shared_ext}$major'
11009 shlibpath_var=LD_LIBRARY_PATH
11010 ;;
a9322a30 11011
b686ecb5
JM
11012*)
11013 dynamic_linker=no
11014 ;;
11015esac
11016{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5
11017$as_echo "$dynamic_linker" >&6; }
11018test "$dynamic_linker" = no && can_build_shared=no
bec39cab 11019
b686ecb5
JM
11020variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
11021if test "$GCC" = yes; then
11022 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
bec39cab 11023fi
c906108c 11024
b686ecb5
JM
11025if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
11026 sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
11027fi
11028if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
11029 sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
95ca63c4 11030fi
bec39cab 11031
bec39cab 11032
95ca63c4
CF
11033
11034
11035
7cb9022a
MK
11036
11037
bec39cab 11038
95ca63c4 11039
95ca63c4 11040
a9322a30 11041
2c947d9b
JB
11042
11043
11044
11045
11046
11047
11048
11049
2c947d9b 11050
2c947d9b 11051
2c947d9b 11052
2c947d9b
JB
11053
11054
2c947d9b 11055
2c947d9b 11056
2c947d9b 11057
2c947d9b 11058
2c947d9b 11059
2c947d9b
JB
11060
11061
2c947d9b 11062
2c947d9b 11063
2c947d9b 11064
2c947d9b 11065
2c947d9b 11066
2c947d9b 11067
2c947d9b 11068
2c947d9b 11069
2c947d9b 11070
2c947d9b 11071
2c947d9b 11072
2c947d9b 11073
2c947d9b
JB
11074
11075
2c947d9b 11076
2c947d9b 11077
2c947d9b 11078
2c947d9b
JB
11079
11080
2c947d9b 11081
2c947d9b 11082
2c947d9b 11083
2c947d9b 11084
2c947d9b
JB
11085
11086
11087
11088
11089
11090
11091
2400729e 11092
2400729e 11093
2400729e 11094
2400729e
UW
11095
11096
11097
11098
11099
11100
11101
11102
2400729e 11103
2400729e 11104
2400729e 11105
2400729e
UW
11106
11107
2400729e 11108
2400729e 11109
2400729e 11110
2400729e 11111
2400729e 11112
2400729e 11113
9f1528a1 11114
b686ecb5
JM
11115
11116
11117
11118
11119
11120
11121
11122
11123 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5
11124$as_echo_n "checking how to hardcode library paths into programs... " >&6; }
11125hardcode_action=
11126if test -n "$hardcode_libdir_flag_spec" ||
11127 test -n "$runpath_var" ||
11128 test "X$hardcode_automatic" = "Xyes" ; then
11129
11130 # We can hardcode non-existent directories.
11131 if test "$hardcode_direct" != no &&
11132 # If the only mechanism to avoid hardcoding is shlibpath_var, we
11133 # have to relink, otherwise we might link with an installed library
11134 # when we should be linking with a yet-to-be-installed one
11135 ## test "$_LT_TAGVAR(hardcode_shlibpath_var, )" != no &&
11136 test "$hardcode_minus_L" != no; then
11137 # Linking always hardcodes the temporary library directory.
11138 hardcode_action=relink
11139 else
11140 # We can link without hardcoding, and we can hardcode nonexisting dirs.
11141 hardcode_action=immediate
11142 fi
9f1528a1 11143else
b686ecb5
JM
11144 # We cannot hardcode anything, or else we can only hardcode existing
11145 # directories.
11146 hardcode_action=unsupported
9f1528a1 11147fi
b686ecb5
JM
11148{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5
11149$as_echo "$hardcode_action" >&6; }
9f1528a1 11150
b686ecb5
JM
11151if test "$hardcode_action" = relink ||
11152 test "$inherit_rpath" = yes; then
11153 # Fast installation is not supported
11154 enable_fast_install=no
11155elif test "$shlibpath_overrides_runpath" = yes ||
11156 test "$enable_shared" = no; then
11157 # Fast installation is not necessary
11158 enable_fast_install=needless
11159fi
9f1528a1 11160
2400729e 11161
2400729e 11162
2400729e 11163
2400729e 11164
2400729e 11165
b686ecb5
JM
11166 if test "x$enable_dlopen" != xyes; then
11167 enable_dlopen=unknown
11168 enable_dlopen_self=unknown
11169 enable_dlopen_self_static=unknown
11170else
11171 lt_cv_dlopen=no
11172 lt_cv_dlopen_libs=
2400729e 11173
b686ecb5
JM
11174 case $host_os in
11175 beos*)
11176 lt_cv_dlopen="load_add_on"
11177 lt_cv_dlopen_libs=
11178 lt_cv_dlopen_self=yes
11179 ;;
2400729e 11180
b686ecb5
JM
11181 mingw* | pw32* | cegcc*)
11182 lt_cv_dlopen="LoadLibrary"
11183 lt_cv_dlopen_libs=
11184 ;;
2400729e 11185
b686ecb5
JM
11186 cygwin*)
11187 lt_cv_dlopen="dlopen"
11188 lt_cv_dlopen_libs=
11189 ;;
2400729e 11190
b686ecb5
JM
11191 darwin*)
11192 # if libdl is installed we need to link against it
11193 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
11194$as_echo_n "checking for dlopen in -ldl... " >&6; }
11195if ${ac_cv_lib_dl_dlopen+:} false; then :
11196 $as_echo_n "(cached) " >&6
11197else
11198 ac_check_lib_save_LIBS=$LIBS
11199LIBS="-ldl $LIBS"
11200cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11201/* end confdefs.h. */
2400729e 11202
b686ecb5
JM
11203/* Override any GCC internal prototype to avoid an error.
11204 Use char because int might match the return type of a GCC
11205 builtin and then its argument prototype would still apply. */
11206#ifdef __cplusplus
11207extern "C"
11208#endif
11209char dlopen ();
11210int
11211main ()
11212{
11213return dlopen ();
11214 ;
11215 return 0;
11216}
11217_ACEOF
11218if ac_fn_c_try_link "$LINENO"; then :
11219 ac_cv_lib_dl_dlopen=yes
11220else
11221 ac_cv_lib_dl_dlopen=no
11222fi
11223rm -f core conftest.err conftest.$ac_objext \
11224 conftest$ac_exeext conftest.$ac_ext
11225LIBS=$ac_check_lib_save_LIBS
11226fi
11227{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
11228$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
11229if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
11230 lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
11231else
2400729e 11232
b686ecb5
JM
11233 lt_cv_dlopen="dyld"
11234 lt_cv_dlopen_libs=
11235 lt_cv_dlopen_self=yes
2400729e 11236
b686ecb5 11237fi
2400729e 11238
b686ecb5 11239 ;;
2400729e 11240
b686ecb5
JM
11241 *)
11242 ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load"
11243if test "x$ac_cv_func_shl_load" = xyes; then :
11244 lt_cv_dlopen="shl_load"
11245else
11246 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5
11247$as_echo_n "checking for shl_load in -ldld... " >&6; }
11248if ${ac_cv_lib_dld_shl_load+:} false; then :
11249 $as_echo_n "(cached) " >&6
11250else
11251 ac_check_lib_save_LIBS=$LIBS
11252LIBS="-ldld $LIBS"
11253cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11254/* end confdefs.h. */
2400729e 11255
b686ecb5
JM
11256/* Override any GCC internal prototype to avoid an error.
11257 Use char because int might match the return type of a GCC
11258 builtin and then its argument prototype would still apply. */
11259#ifdef __cplusplus
11260extern "C"
11261#endif
11262char shl_load ();
11263int
11264main ()
11265{
11266return shl_load ();
11267 ;
11268 return 0;
11269}
11270_ACEOF
11271if ac_fn_c_try_link "$LINENO"; then :
11272 ac_cv_lib_dld_shl_load=yes
11273else
11274 ac_cv_lib_dld_shl_load=no
11275fi
11276rm -f core conftest.err conftest.$ac_objext \
11277 conftest$ac_exeext conftest.$ac_ext
11278LIBS=$ac_check_lib_save_LIBS
11279fi
11280{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5
11281$as_echo "$ac_cv_lib_dld_shl_load" >&6; }
11282if test "x$ac_cv_lib_dld_shl_load" = xyes; then :
11283 lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"
11284else
11285 ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen"
11286if test "x$ac_cv_func_dlopen" = xyes; then :
11287 lt_cv_dlopen="dlopen"
11288else
11289 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
11290$as_echo_n "checking for dlopen in -ldl... " >&6; }
11291if ${ac_cv_lib_dl_dlopen+:} false; then :
11292 $as_echo_n "(cached) " >&6
11293else
11294 ac_check_lib_save_LIBS=$LIBS
11295LIBS="-ldl $LIBS"
11296cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11297/* end confdefs.h. */
2400729e 11298
b686ecb5
JM
11299/* Override any GCC internal prototype to avoid an error.
11300 Use char because int might match the return type of a GCC
11301 builtin and then its argument prototype would still apply. */
11302#ifdef __cplusplus
11303extern "C"
11304#endif
11305char dlopen ();
11306int
11307main ()
11308{
11309return dlopen ();
11310 ;
11311 return 0;
11312}
11313_ACEOF
11314if ac_fn_c_try_link "$LINENO"; then :
11315 ac_cv_lib_dl_dlopen=yes
11316else
11317 ac_cv_lib_dl_dlopen=no
11318fi
11319rm -f core conftest.err conftest.$ac_objext \
11320 conftest$ac_exeext conftest.$ac_ext
11321LIBS=$ac_check_lib_save_LIBS
11322fi
11323{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
11324$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
11325if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
11326 lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
11327else
11328 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5
11329$as_echo_n "checking for dlopen in -lsvld... " >&6; }
11330if ${ac_cv_lib_svld_dlopen+:} false; then :
2400729e
UW
11331 $as_echo_n "(cached) " >&6
11332else
b686ecb5
JM
11333 ac_check_lib_save_LIBS=$LIBS
11334LIBS="-lsvld $LIBS"
11335cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11336/* end confdefs.h. */
2400729e 11337
b686ecb5
JM
11338/* Override any GCC internal prototype to avoid an error.
11339 Use char because int might match the return type of a GCC
11340 builtin and then its argument prototype would still apply. */
11341#ifdef __cplusplus
11342extern "C"
11343#endif
11344char dlopen ();
11345int
11346main ()
11347{
11348return dlopen ();
11349 ;
11350 return 0;
11351}
11352_ACEOF
11353if ac_fn_c_try_link "$LINENO"; then :
11354 ac_cv_lib_svld_dlopen=yes
11355else
11356 ac_cv_lib_svld_dlopen=no
11357fi
11358rm -f core conftest.err conftest.$ac_objext \
11359 conftest$ac_exeext conftest.$ac_ext
11360LIBS=$ac_check_lib_save_LIBS
11361fi
11362{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5
11363$as_echo "$ac_cv_lib_svld_dlopen" >&6; }
11364if test "x$ac_cv_lib_svld_dlopen" = xyes; then :
11365 lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"
11366else
11367 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5
11368$as_echo_n "checking for dld_link in -ldld... " >&6; }
11369if ${ac_cv_lib_dld_dld_link+:} false; then :
11370 $as_echo_n "(cached) " >&6
11371else
11372 ac_check_lib_save_LIBS=$LIBS
11373LIBS="-ldld $LIBS"
11374cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2400729e 11375/* end confdefs.h. */
b686ecb5
JM
11376
11377/* Override any GCC internal prototype to avoid an error.
11378 Use char because int might match the return type of a GCC
11379 builtin and then its argument prototype would still apply. */
11380#ifdef __cplusplus
11381extern "C"
11382#endif
11383char dld_link ();
2400729e
UW
11384int
11385main ()
11386{
b686ecb5 11387return dld_link ();
2400729e
UW
11388 ;
11389 return 0;
11390}
11391_ACEOF
11392if ac_fn_c_try_link "$LINENO"; then :
b686ecb5 11393 ac_cv_lib_dld_dld_link=yes
2400729e 11394else
b686ecb5 11395 ac_cv_lib_dld_dld_link=no
2400729e
UW
11396fi
11397rm -f core conftest.err conftest.$ac_objext \
11398 conftest$ac_exeext conftest.$ac_ext
b686ecb5
JM
11399LIBS=$ac_check_lib_save_LIBS
11400fi
11401{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5
11402$as_echo "$ac_cv_lib_dld_dld_link" >&6; }
11403if test "x$ac_cv_lib_dld_dld_link" = xyes; then :
11404 lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"
11405fi
11406
2400729e
UW
11407
11408fi
2400729e 11409
2400729e 11410
b686ecb5 11411fi
2400729e
UW
11412
11413
b686ecb5 11414fi
2400729e
UW
11415
11416
b686ecb5 11417fi
2400729e
UW
11418
11419
2400729e
UW
11420fi
11421
b686ecb5
JM
11422 ;;
11423 esac
a9322a30 11424
b686ecb5
JM
11425 if test "x$lt_cv_dlopen" != xno; then
11426 enable_dlopen=yes
11427 else
11428 enable_dlopen=no
11429 fi
a9322a30 11430
b686ecb5
JM
11431 case $lt_cv_dlopen in
11432 dlopen)
11433 save_CPPFLAGS="$CPPFLAGS"
11434 test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
a9322a30 11435
b686ecb5
JM
11436 save_LDFLAGS="$LDFLAGS"
11437 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
ec685c5e 11438
b686ecb5
JM
11439 save_LIBS="$LIBS"
11440 LIBS="$lt_cv_dlopen_libs $LIBS"
0c4a4063 11441
b686ecb5
JM
11442 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5
11443$as_echo_n "checking whether a program can dlopen itself... " >&6; }
11444if ${lt_cv_dlopen_self+:} false; then :
11445 $as_echo_n "(cached) " >&6
bec39cab 11446else
b686ecb5
JM
11447 if test "$cross_compiling" = yes; then :
11448 lt_cv_dlopen_self=cross
11449else
11450 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
11451 lt_status=$lt_dlunknown
11452 cat > conftest.$ac_ext <<_LT_EOF
14d0e681 11453#line 11453 "configure"
b686ecb5 11454#include "confdefs.h"
bec39cab 11455
b686ecb5
JM
11456#if HAVE_DLFCN_H
11457#include <dlfcn.h>
11458#endif
9a156167 11459
b686ecb5 11460#include <stdio.h>
ec685c5e 11461
b686ecb5
JM
11462#ifdef RTLD_GLOBAL
11463# define LT_DLGLOBAL RTLD_GLOBAL
11464#else
11465# ifdef DL_GLOBAL
11466# define LT_DLGLOBAL DL_GLOBAL
11467# else
11468# define LT_DLGLOBAL 0
11469# endif
11470#endif
ec685c5e 11471
b686ecb5
JM
11472/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
11473 find out it does not work in some platform. */
11474#ifndef LT_DLLAZY_OR_NOW
11475# ifdef RTLD_LAZY
11476# define LT_DLLAZY_OR_NOW RTLD_LAZY
11477# else
11478# ifdef DL_LAZY
11479# define LT_DLLAZY_OR_NOW DL_LAZY
11480# else
11481# ifdef RTLD_NOW
11482# define LT_DLLAZY_OR_NOW RTLD_NOW
11483# else
11484# ifdef DL_NOW
11485# define LT_DLLAZY_OR_NOW DL_NOW
11486# else
11487# define LT_DLLAZY_OR_NOW 0
11488# endif
11489# endif
11490# endif
11491# endif
11492#endif
ec685c5e 11493
b686ecb5
JM
11494/* When -fvisbility=hidden is used, assume the code has been annotated
11495 correspondingly for the symbols needed. */
11496#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
11497void fnord () __attribute__((visibility("default")));
11498#endif
602d2b52 11499
b686ecb5
JM
11500void fnord () { int i=42; }
11501int main ()
11502{
11503 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
11504 int status = $lt_dlunknown;
11505
11506 if (self)
11507 {
11508 if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
ec685c5e 11509 else
b686ecb5
JM
11510 {
11511 if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
11512 else puts (dlerror ());
11513 }
11514 /* dlclose (self); */
11515 }
11516 else
11517 puts (dlerror ());
11518
11519 return status;
11520}
11521_LT_EOF
11522 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
11523 (eval $ac_link) 2>&5
11524 ac_status=$?
11525 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
11526 test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then
11527 (./conftest; exit; ) >&5 2>/dev/null
11528 lt_status=$?
11529 case x$lt_status in
11530 x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
11531 x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
11532 x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;;
11533 esac
11534 else :
11535 # compilation failed
11536 lt_cv_dlopen_self=no
ec685c5e 11537 fi
b686ecb5
JM
11538fi
11539rm -fr conftest*
11540
ec685c5e 11541
ec685c5e 11542fi
b686ecb5
JM
11543{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5
11544$as_echo "$lt_cv_dlopen_self" >&6; }
11545
11546 if test "x$lt_cv_dlopen_self" = xyes; then
11547 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
11548 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5
11549$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; }
11550if ${lt_cv_dlopen_self_static+:} false; then :
11551 $as_echo_n "(cached) " >&6
ec685c5e 11552else
b686ecb5
JM
11553 if test "$cross_compiling" = yes; then :
11554 lt_cv_dlopen_self_static=cross
11555else
11556 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
11557 lt_status=$lt_dlunknown
11558 cat > conftest.$ac_ext <<_LT_EOF
14d0e681 11559#line 11559 "configure"
b686ecb5 11560#include "confdefs.h"
ec685c5e 11561
b686ecb5
JM
11562#if HAVE_DLFCN_H
11563#include <dlfcn.h>
11564#endif
ec685c5e 11565
b686ecb5 11566#include <stdio.h>
81ecdfbb 11567
b686ecb5
JM
11568#ifdef RTLD_GLOBAL
11569# define LT_DLGLOBAL RTLD_GLOBAL
11570#else
11571# ifdef DL_GLOBAL
11572# define LT_DLGLOBAL DL_GLOBAL
11573# else
11574# define LT_DLGLOBAL 0
11575# endif
11576#endif
bec39cab 11577
b686ecb5
JM
11578/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
11579 find out it does not work in some platform. */
11580#ifndef LT_DLLAZY_OR_NOW
11581# ifdef RTLD_LAZY
11582# define LT_DLLAZY_OR_NOW RTLD_LAZY
11583# else
11584# ifdef DL_LAZY
11585# define LT_DLLAZY_OR_NOW DL_LAZY
11586# else
11587# ifdef RTLD_NOW
11588# define LT_DLLAZY_OR_NOW RTLD_NOW
11589# else
11590# ifdef DL_NOW
11591# define LT_DLLAZY_OR_NOW DL_NOW
11592# else
11593# define LT_DLLAZY_OR_NOW 0
11594# endif
11595# endif
11596# endif
11597# endif
11598#endif
81ecdfbb 11599
b686ecb5
JM
11600/* When -fvisbility=hidden is used, assume the code has been annotated
11601 correspondingly for the symbols needed. */
11602#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
11603void fnord () __attribute__((visibility("default")));
11604#endif
71737c43 11605
b686ecb5
JM
11606void fnord () { int i=42; }
11607int main ()
11608{
11609 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
11610 int status = $lt_dlunknown;
ec685c5e 11611
b686ecb5
JM
11612 if (self)
11613 {
11614 if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
11615 else
11616 {
11617 if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
11618 else puts (dlerror ());
11619 }
11620 /* dlclose (self); */
11621 }
11622 else
11623 puts (dlerror ());
420697bb 11624
b686ecb5 11625 return status;
ec685c5e 11626}
b686ecb5
JM
11627_LT_EOF
11628 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
11629 (eval $ac_link) 2>&5
11630 ac_status=$?
11631 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
11632 test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then
11633 (./conftest; exit; ) >&5 2>/dev/null
11634 lt_status=$?
11635 case x$lt_status in
11636 x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
11637 x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
11638 x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;;
11639 esac
11640 else :
11641 # compilation failed
11642 lt_cv_dlopen_self_static=no
11643 fi
ec685c5e 11644fi
b686ecb5 11645rm -fr conftest*
81ecdfbb 11646
ec685c5e 11647
b686ecb5
JM
11648fi
11649{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5
11650$as_echo "$lt_cv_dlopen_self_static" >&6; }
11651 fi
0c4a4063 11652
b686ecb5
JM
11653 CPPFLAGS="$save_CPPFLAGS"
11654 LDFLAGS="$save_LDFLAGS"
11655 LIBS="$save_LIBS"
11656 ;;
11657 esac
0c4a4063 11658
b686ecb5
JM
11659 case $lt_cv_dlopen_self in
11660 yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
11661 *) enable_dlopen_self=unknown ;;
11662 esac
0c4a4063 11663
b686ecb5
JM
11664 case $lt_cv_dlopen_self_static in
11665 yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
11666 *) enable_dlopen_self_static=unknown ;;
0c4a4063 11667 esac
b686ecb5 11668fi
0c4a4063 11669
0c4a4063
DE
11670
11671
436868fb 11672
d13c7322 11673
d13c7322 11674
d13c7322 11675
d13c7322
AB
11676
11677
436868fb 11678
436868fb 11679
436868fb 11680
d13c7322 11681
d13c7322
AB
11682
11683
d13c7322 11684
d13c7322 11685
b686ecb5
JM
11686striplib=
11687old_striplib=
11688{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5
11689$as_echo_n "checking whether stripping libraries is possible... " >&6; }
11690if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
11691 test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
11692 test -z "$striplib" && striplib="$STRIP --strip-unneeded"
11693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11694$as_echo "yes" >&6; }
11695else
11696# FIXME - insert some real tests, host_os isn't really good enough
11697 case $host_os in
11698 darwin*)
11699 if test -n "$STRIP" ; then
11700 striplib="$STRIP -x"
11701 old_striplib="$STRIP -S"
11702 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11703$as_echo "yes" >&6; }
11704 else
11705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11706$as_echo "no" >&6; }
11707 fi
11708 ;;
11709 *)
11710 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11711$as_echo "no" >&6; }
11712 ;;
11713 esac
11714fi
d13c7322 11715
d13c7322 11716
436868fb 11717
81ecdfbb 11718
a9322a30 11719
043b6510 11720
c83393b9 11721
9a156167 11722
a4a1c157
PA
11723
11724
ed3ef339
DE
11725
11726
b686ecb5
JM
11727 # Report which library types will actually be built
11728 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5
11729$as_echo_n "checking if libtool supports shared libraries... " >&6; }
11730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5
11731$as_echo "$can_build_shared" >&6; }
4df42755 11732
b686ecb5
JM
11733 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5
11734$as_echo_n "checking whether to build shared libraries... " >&6; }
11735 test "$can_build_shared" = "no" && enable_shared=no
ed3ef339 11736
b686ecb5
JM
11737 # On AIX, shared libraries and static libraries use the same namespace, and
11738 # are all built from PIC.
11739 case $host_os in
11740 aix3*)
11741 test "$enable_shared" = yes && enable_static=no
11742 if test -n "$RANLIB"; then
11743 archive_cmds="$archive_cmds~\$RANLIB \$lib"
11744 postinstall_cmds='$RANLIB $lib'
11745 fi
11746 ;;
ed3ef339 11747
b686ecb5
JM
11748 aix[4-9]*)
11749 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
11750 test "$enable_shared" = yes && enable_static=no
11751 fi
11752 ;;
11753 esac
11754 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5
11755$as_echo "$enable_shared" >&6; }
ed3ef339 11756
b686ecb5
JM
11757 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5
11758$as_echo_n "checking whether to build static libraries... " >&6; }
11759 # Make sure either enable_shared or enable_static is yes.
11760 test "$enable_shared" = yes || enable_static=yes
11761 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5
11762$as_echo "$enable_static" >&6; }
e1402065
DE
11763
11764
11765
11766
e1402065 11767fi
b686ecb5
JM
11768ac_ext=c
11769ac_cpp='$CPP $CPPFLAGS'
11770ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
11771ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
11772ac_compiler_gnu=$ac_cv_c_compiler_gnu
e1402065 11773
b686ecb5 11774CC="$lt_save_CC"
e1402065 11775
b686ecb5
JM
11776 if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
11777 ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
11778 (test "X$CXX" != "Xg++"))) ; then
11779 ac_ext=cpp
11780ac_cpp='$CXXCPP $CPPFLAGS'
11781ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
11782ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
11783ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
11784{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5
11785$as_echo_n "checking how to run the C++ preprocessor... " >&6; }
11786if test -z "$CXXCPP"; then
11787 if ${ac_cv_prog_CXXCPP+:} false; then :
ed3ef339
DE
11788 $as_echo_n "(cached) " >&6
11789else
b686ecb5
JM
11790 # Double quotes because CXXCPP needs to be expanded
11791 for CXXCPP in "$CXX -E" "/lib/cpp"
11792 do
11793 ac_preproc_ok=false
11794for ac_cxx_preproc_warn_flag in '' yes
ed3ef339 11795do
b686ecb5
JM
11796 # Use a header file that comes with gcc, so configuring glibc
11797 # with a fresh cross-compiler works.
11798 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11799 # <limits.h> exists even on freestanding compilers.
11800 # On the NeXT, cc -E runs the code through the compiler's parser,
11801 # not just through cpp. "Syntax error" is here to catch this case.
11802 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11803/* end confdefs.h. */
11804#ifdef __STDC__
11805# include <limits.h>
11806#else
11807# include <assert.h>
11808#endif
11809 Syntax error
11810_ACEOF
11811if ac_fn_cxx_try_cpp "$LINENO"; then :
ed3ef339 11812
b686ecb5
JM
11813else
11814 # Broken: fails on valid input.
11815continue
ed3ef339 11816fi
b686ecb5
JM
11817rm -f conftest.err conftest.i conftest.$ac_ext
11818
11819 # OK, works on sane cases. Now check whether nonexistent headers
11820 # can be detected and how.
11821 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11822/* end confdefs.h. */
11823#include <ac_nonexistent.h>
11824_ACEOF
11825if ac_fn_cxx_try_cpp "$LINENO"; then :
11826 # Broken: success on invalid input.
11827continue
ed3ef339 11828else
b686ecb5
JM
11829 # Passes both tests.
11830ac_preproc_ok=:
11831break
ed3ef339 11832fi
b686ecb5 11833rm -f conftest.err conftest.i conftest.$ac_ext
ed3ef339 11834
b686ecb5
JM
11835done
11836# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
11837rm -f conftest.i conftest.err conftest.$ac_ext
11838if $ac_preproc_ok; then :
11839 break
11840fi
ed3ef339 11841
b686ecb5
JM
11842 done
11843 ac_cv_prog_CXXCPP=$CXXCPP
ed3ef339 11844
b686ecb5
JM
11845fi
11846 CXXCPP=$ac_cv_prog_CXXCPP
11847else
11848 ac_cv_prog_CXXCPP=$CXXCPP
11849fi
11850{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5
11851$as_echo "$CXXCPP" >&6; }
11852ac_preproc_ok=false
11853for ac_cxx_preproc_warn_flag in '' yes
11854do
11855 # Use a header file that comes with gcc, so configuring glibc
11856 # with a fresh cross-compiler works.
11857 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11858 # <limits.h> exists even on freestanding compilers.
11859 # On the NeXT, cc -E runs the code through the compiler's parser,
11860 # not just through cpp. "Syntax error" is here to catch this case.
11861 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11862/* end confdefs.h. */
11863#ifdef __STDC__
11864# include <limits.h>
11865#else
11866# include <assert.h>
11867#endif
11868 Syntax error
11869_ACEOF
11870if ac_fn_cxx_try_cpp "$LINENO"; then :
ed3ef339 11871
b686ecb5
JM
11872else
11873 # Broken: fails on valid input.
11874continue
11875fi
11876rm -f conftest.err conftest.i conftest.$ac_ext
ed3ef339 11877
b686ecb5
JM
11878 # OK, works on sane cases. Now check whether nonexistent headers
11879 # can be detected and how.
11880 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
ed3ef339 11881/* end confdefs.h. */
b686ecb5 11882#include <ac_nonexistent.h>
ed3ef339 11883_ACEOF
b686ecb5
JM
11884if ac_fn_cxx_try_cpp "$LINENO"; then :
11885 # Broken: success on invalid input.
11886continue
ed3ef339 11887else
b686ecb5
JM
11888 # Passes both tests.
11889ac_preproc_ok=:
11890break
ed3ef339 11891fi
b686ecb5 11892rm -f conftest.err conftest.i conftest.$ac_ext
92fab5a6 11893
b686ecb5
JM
11894done
11895# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
11896rm -f conftest.i conftest.err conftest.$ac_ext
11897if $ac_preproc_ok; then :
92fab5a6 11898
b686ecb5
JM
11899else
11900 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
ed3ef339 11901$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
b686ecb5 11902as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check
d0ac1c44 11903See \`config.log' for more details" "$LINENO" 5; }
b686ecb5 11904fi
ed3ef339 11905
b686ecb5
JM
11906ac_ext=c
11907ac_cpp='$CPP $CPPFLAGS'
11908ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
11909ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
11910ac_compiler_gnu=$ac_cv_c_compiler_gnu
ed3ef339 11911
ed3ef339 11912else
b686ecb5 11913 _lt_caught_CXX_error=yes
ed3ef339 11914fi
92fab5a6 11915
b686ecb5
JM
11916ac_ext=cpp
11917ac_cpp='$CXXCPP $CPPFLAGS'
11918ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
11919ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
11920ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
92fab5a6 11921
b686ecb5
JM
11922archive_cmds_need_lc_CXX=no
11923allow_undefined_flag_CXX=
11924always_export_symbols_CXX=no
11925archive_expsym_cmds_CXX=
11926compiler_needs_object_CXX=no
11927export_dynamic_flag_spec_CXX=
11928hardcode_direct_CXX=no
11929hardcode_direct_absolute_CXX=no
11930hardcode_libdir_flag_spec_CXX=
11931hardcode_libdir_flag_spec_ld_CXX=
11932hardcode_libdir_separator_CXX=
11933hardcode_minus_L_CXX=no
11934hardcode_shlibpath_var_CXX=unsupported
11935hardcode_automatic_CXX=no
11936inherit_rpath_CXX=no
11937module_cmds_CXX=
11938module_expsym_cmds_CXX=
11939link_all_deplibs_CXX=unknown
11940old_archive_cmds_CXX=$old_archive_cmds
11941reload_flag_CXX=$reload_flag
11942reload_cmds_CXX=$reload_cmds
11943no_undefined_flag_CXX=
11944whole_archive_flag_spec_CXX=
11945enable_shared_with_static_runtimes_CXX=no
11946
11947# Source file extension for C++ test sources.
11948ac_ext=cpp
92fab5a6 11949
b686ecb5
JM
11950# Object file extension for compiled C++ test sources.
11951objext=o
11952objext_CXX=$objext
92fab5a6 11953
b686ecb5
JM
11954# No sense in running all these tests if we already determined that
11955# the CXX compiler isn't working. Some variables (like enable_shared)
11956# are currently assumed to apply to all compilers on this platform,
11957# and will be corrupted by setting them based on a non-working compiler.
11958if test "$_lt_caught_CXX_error" != yes; then
11959 # Code to be used in simple compile tests
11960 lt_simple_compile_test_code="int some_variable = 0;"
ed3ef339 11961
b686ecb5
JM
11962 # Code to be used in simple link tests
11963 lt_simple_link_test_code='int main(int, char *[]) { return(0); }'
ed3ef339 11964
b686ecb5 11965 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
ed3ef339 11966
92fab5a6 11967
92fab5a6
AW
11968
11969
92fab5a6 11970
ed3ef339 11971
b686ecb5
JM
11972# If no C compiler was specified, use CC.
11973LTCC=${LTCC-"$CC"}
11974
11975# If no C compiler flags were specified, use CFLAGS.
11976LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
11977
11978# Allow CC to be a program name with arguments.
11979compiler=$CC
11980
11981
11982 # save warnings/boilerplate of simple test code
11983 ac_outfile=conftest.$ac_objext
11984echo "$lt_simple_compile_test_code" >conftest.$ac_ext
11985eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
11986_lt_compiler_boilerplate=`cat conftest.err`
11987$RM conftest*
11988
11989 ac_outfile=conftest.$ac_objext
11990echo "$lt_simple_link_test_code" >conftest.$ac_ext
11991eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
11992_lt_linker_boilerplate=`cat conftest.err`
11993$RM -r conftest*
11994
11995
11996 # Allow CC to be a program name with arguments.
11997 lt_save_CC=$CC
11998 lt_save_LD=$LD
11999 lt_save_GCC=$GCC
12000 GCC=$GXX
12001 lt_save_with_gnu_ld=$with_gnu_ld
12002 lt_save_path_LD=$lt_cv_path_LD
12003 if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
12004 lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
e1402065 12005 else
b686ecb5 12006 $as_unset lt_cv_prog_gnu_ld
e1402065 12007 fi
b686ecb5
JM
12008 if test -n "${lt_cv_path_LDCXX+set}"; then
12009 lt_cv_path_LD=$lt_cv_path_LDCXX
12010 else
12011 $as_unset lt_cv_path_LD
e1402065 12012 fi
b686ecb5
JM
12013 test -z "${LDCXX+set}" || LD=$LDCXX
12014 CC=${CXX-"c++"}
12015 compiler=$CC
12016 compiler_CXX=$CC
12017 for cc_temp in $compiler""; do
12018 case $cc_temp in
12019 compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
12020 distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
12021 \-*) ;;
12022 *) break;;
12023 esac
12024done
12025cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
ed3ef339 12026
ed3ef339 12027
b686ecb5
JM
12028 if test -n "$compiler"; then
12029 # We don't want -fno-exception when compiling C++ code, so set the
12030 # no_builtin_flag separately
12031 if test "$GXX" = yes; then
12032 lt_prog_compiler_no_builtin_flag_CXX=' -fno-builtin'
ed3ef339 12033 else
b686ecb5 12034 lt_prog_compiler_no_builtin_flag_CXX=
ed3ef339 12035 fi
92fab5a6 12036
b686ecb5
JM
12037 if test "$GXX" = yes; then
12038 # Set up default GNU C++ configuration
12039
92fab5a6
AW
12040
12041
b686ecb5
JM
12042# Check whether --with-gnu-ld was given.
12043if test "${with_gnu_ld+set}" = set; then :
12044 withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
12045else
12046 with_gnu_ld=no
92fab5a6
AW
12047fi
12048
b686ecb5
JM
12049ac_prog=ld
12050if test "$GCC" = yes; then
12051 # Check if gcc -print-prog-name=ld gives a path.
12052 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
12053$as_echo_n "checking for ld used by $CC... " >&6; }
12054 case $host in
12055 *-*-mingw*)
12056 # gcc leaves a trailing carriage return which upsets mingw
12057 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
12058 *)
12059 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
12060 esac
12061 case $ac_prog in
12062 # Accept absolute paths.
12063 [\\/]* | ?:[\\/]*)
12064 re_direlt='/[^/][^/]*/\.\./'
12065 # Canonicalize the pathname of ld
12066 ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
12067 while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
12068 ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
12069 done
12070 test -z "$LD" && LD="$ac_prog"
12071 ;;
12072 "")
12073 # If it fails, then pretend we aren't using GCC.
12074 ac_prog=ld
12075 ;;
12076 *)
12077 # If it is relative, then search for the first ld in PATH.
12078 with_gnu_ld=unknown
12079 ;;
12080 esac
12081elif test "$with_gnu_ld" = yes; then
12082 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
12083$as_echo_n "checking for GNU ld... " >&6; }
12084else
12085 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
12086$as_echo_n "checking for non-GNU ld... " >&6; }
12087fi
12088if ${lt_cv_path_LD+:} false; then :
12089 $as_echo_n "(cached) " >&6
12090else
12091 if test -z "$LD"; then
12092 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
12093 for ac_dir in $PATH; do
12094 IFS="$lt_save_ifs"
12095 test -z "$ac_dir" && ac_dir=.
12096 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
12097 lt_cv_path_LD="$ac_dir/$ac_prog"
12098 # Check to see if the program is GNU ld. I'd rather use --version,
12099 # but apparently some variants of GNU ld only accept -v.
12100 # Break only if it was the GNU/non-GNU ld that we prefer.
12101 case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
12102 *GNU* | *'with BFD'*)
12103 test "$with_gnu_ld" != no && break
12104 ;;
12105 *)
12106 test "$with_gnu_ld" != yes && break
12107 ;;
12108 esac
ed3ef339 12109 fi
b686ecb5
JM
12110 done
12111 IFS="$lt_save_ifs"
12112else
12113 lt_cv_path_LD="$LD" # Let the user override the test with a path.
12114fi
12115fi
ed3ef339 12116
b686ecb5
JM
12117LD="$lt_cv_path_LD"
12118if test -n "$LD"; then
12119 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
12120$as_echo "$LD" >&6; }
12121else
12122 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12123$as_echo "no" >&6; }
12124fi
12125test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
12126{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
12127$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
12128if ${lt_cv_prog_gnu_ld+:} false; then :
12129 $as_echo_n "(cached) " >&6
12130else
12131 # I'd rather use --version here, but apparently some GNU lds only accept -v.
12132case `$LD -v 2>&1 </dev/null` in
12133*GNU* | *'with BFD'*)
12134 lt_cv_prog_gnu_ld=yes
12135 ;;
12136*)
12137 lt_cv_prog_gnu_ld=no
ed3ef339
DE
12138 ;;
12139esac
b686ecb5
JM
12140fi
12141{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5
12142$as_echo "$lt_cv_prog_gnu_ld" >&6; }
12143with_gnu_ld=$lt_cv_prog_gnu_ld
ed3ef339 12144
e76c5d17 12145
e76c5d17 12146
e76c5d17 12147
e76c5d17 12148
e76c5d17 12149
e76c5d17 12150
b686ecb5
JM
12151 # Check if GNU C++ uses GNU ld as the underlying linker, since the
12152 # archiving commands below assume that GNU ld is being used.
12153 if test "$with_gnu_ld" = yes; then
12154 archive_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
12155 archive_expsym_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
e76c5d17 12156
b686ecb5
JM
12157 hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
12158 export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
e76c5d17 12159
b686ecb5
JM
12160 # If archive_cmds runs LD, not CC, wlarc should be empty
12161 # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
12162 # investigate it a little bit more. (MM)
12163 wlarc='${wl}'
e76c5d17 12164
b686ecb5
JM
12165 # ancient GNU ld didn't support --whole-archive et. al.
12166 if eval "`$CC -print-prog-name=ld` --help 2>&1" |
12167 $GREP 'no-whole-archive' > /dev/null; then
12168 whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
12169 else
12170 whole_archive_flag_spec_CXX=
12171 fi
12172 else
12173 with_gnu_ld=no
12174 wlarc=
12175
12176 # A generic and very simple default shared library creation
12177 # command for GNU C++ for the case where it uses the native
12178 # linker, instead of GNU ld. If possible, this setting should
12179 # overridden to take advantage of the native linker features on
12180 # the platform it is being used on.
12181 archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
12182 fi
e76c5d17 12183
b686ecb5
JM
12184 # Commands to make compiler produce verbose output that lists
12185 # what "hidden" libraries, object files and flags are used when
12186 # linking a shared library.
12187 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
e76c5d17 12188
b686ecb5
JM
12189 else
12190 GXX=no
12191 with_gnu_ld=no
12192 wlarc=
12193 fi
e76c5d17 12194
b686ecb5
JM
12195 # PORTME: fill in a description of your system's C++ link characteristics
12196 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
12197$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
12198 ld_shlibs_CXX=yes
12199 case $host_os in
12200 aix3*)
12201 # FIXME: insert proper C++ library support
12202 ld_shlibs_CXX=no
12203 ;;
12204 aix[4-9]*)
12205 if test "$host_cpu" = ia64; then
12206 # On IA64, the linker does run time linking by default, so we don't
12207 # have to do anything special.
12208 aix_use_runtimelinking=no
12209 exp_sym_flag='-Bexport'
12210 no_entry_flag=""
12211 else
12212 aix_use_runtimelinking=no
12213
12214 # Test if we are trying to use run time linking or normal
12215 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
12216 # need to do runtime linking.
12217 case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
12218 for ld_flag in $LDFLAGS; do
12219 case $ld_flag in
12220 *-brtl*)
12221 aix_use_runtimelinking=yes
12222 break
12223 ;;
12224 esac
12225 done
12226 ;;
12227 esac
e76c5d17 12228
b686ecb5
JM
12229 exp_sym_flag='-bexport'
12230 no_entry_flag='-bnoentry'
12231 fi
e76c5d17 12232
b686ecb5
JM
12233 # When large executables or shared objects are built, AIX ld can
12234 # have problems creating the table of contents. If linking a library
12235 # or program results in "error TOC overflow" add -mminimal-toc to
12236 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
12237 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
12238
12239 archive_cmds_CXX=''
12240 hardcode_direct_CXX=yes
12241 hardcode_direct_absolute_CXX=yes
12242 hardcode_libdir_separator_CXX=':'
12243 link_all_deplibs_CXX=yes
12244 file_list_spec_CXX='${wl}-f,'
12245
12246 if test "$GXX" = yes; then
12247 case $host_os in aix4.[012]|aix4.[012].*)
12248 # We only want to do this on AIX 4.2 and lower, the check
12249 # below for broken collect2 doesn't work under 4.3+
12250 collect2name=`${CC} -print-prog-name=collect2`
12251 if test -f "$collect2name" &&
12252 strings "$collect2name" | $GREP resolve_lib_name >/dev/null
12253 then
12254 # We have reworked collect2
12255 :
12256 else
12257 # We have old collect2
12258 hardcode_direct_CXX=unsupported
12259 # It fails to find uninstalled libraries when the uninstalled
12260 # path is not listed in the libpath. Setting hardcode_minus_L
12261 # to unsupported forces relinking
12262 hardcode_minus_L_CXX=yes
12263 hardcode_libdir_flag_spec_CXX='-L$libdir'
12264 hardcode_libdir_separator_CXX=
12265 fi
12266 esac
12267 shared_flag='-shared'
12268 if test "$aix_use_runtimelinking" = yes; then
12269 shared_flag="$shared_flag "'${wl}-G'
12270 fi
12271 else
12272 # not using gcc
12273 if test "$host_cpu" = ia64; then
12274 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
12275 # chokes on -Wl,-G. The following line is correct:
12276 shared_flag='-G'
12277 else
12278 if test "$aix_use_runtimelinking" = yes; then
12279 shared_flag='${wl}-G'
12280 else
12281 shared_flag='${wl}-bM:SRE'
12282 fi
12283 fi
12284 fi
ed3ef339 12285
b686ecb5
JM
12286 export_dynamic_flag_spec_CXX='${wl}-bexpall'
12287 # It seems that -bexpall does not export symbols beginning with
12288 # underscore (_), so it is better to generate a list of symbols to
12289 # export.
12290 always_export_symbols_CXX=yes
12291 if test "$aix_use_runtimelinking" = yes; then
12292 # Warning - without using the other runtime loading flags (-brtl),
12293 # -berok will link without error, but may produce a broken library.
12294 allow_undefined_flag_CXX='-berok'
12295 # Determine the default libpath from the value encoded in an empty
12296 # executable.
12297 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12298/* end confdefs.h. */
ed3ef339 12299
b686ecb5
JM
12300int
12301main ()
12302{
16954d5d 12303
b686ecb5
JM
12304 ;
12305 return 0;
12306}
16954d5d 12307_ACEOF
b686ecb5 12308if ac_fn_cxx_try_link "$LINENO"; then :
16954d5d 12309
b686ecb5
JM
12310lt_aix_libpath_sed='
12311 /Import File Strings/,/^$/ {
12312 /^0/ {
12313 s/^0 *\(.*\)$/\1/
12314 p
12315 }
12316 }'
12317aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
12318# Check for a 64-bit object if we didn't find anything.
12319if test -z "$aix_libpath"; then
12320 aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
16954d5d 12321fi
189b8c2e 12322fi
b686ecb5
JM
12323rm -f core conftest.err conftest.$ac_objext \
12324 conftest$ac_exeext conftest.$ac_ext
12325if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
189b8c2e 12326
b686ecb5 12327 hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath"
189b8c2e 12328
b686ecb5
JM
12329 archive_expsym_cmds_CXX='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
12330 else
12331 if test "$host_cpu" = ia64; then
12332 hardcode_libdir_flag_spec_CXX='${wl}-R $libdir:/usr/lib:/lib'
12333 allow_undefined_flag_CXX="-z nodefs"
12334 archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
12335 else
12336 # Determine the default libpath from the value encoded in an
12337 # empty executable.
12338 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
0f8f2de1 12339/* end confdefs.h. */
b686ecb5 12340
0f8f2de1
TV
12341int
12342main ()
12343{
0f8f2de1
TV
12344
12345 ;
12346 return 0;
12347}
12348_ACEOF
12349if ac_fn_cxx_try_link "$LINENO"; then :
0f8f2de1 12350
b686ecb5
JM
12351lt_aix_libpath_sed='
12352 /Import File Strings/,/^$/ {
12353 /^0/ {
12354 s/^0 *\(.*\)$/\1/
12355 p
12356 }
12357 }'
12358aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
12359# Check for a 64-bit object if we didn't find anything.
12360if test -z "$aix_libpath"; then
12361 aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
12362fi
0f8f2de1
TV
12363fi
12364rm -f core conftest.err conftest.$ac_objext \
12365 conftest$ac_exeext conftest.$ac_ext
b686ecb5
JM
12366if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
12367
12368 hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath"
12369 # Warning - without using the other run time loading flags,
12370 # -berok will link without error, but may produce a broken library.
12371 no_undefined_flag_CXX=' ${wl}-bernotok'
12372 allow_undefined_flag_CXX=' ${wl}-berok'
12373 if test "$with_gnu_ld" = yes; then
12374 # We only use this code for GNU lds that support --whole-archive.
12375 whole_archive_flag_spec_CXX='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
12376 else
12377 # Exported symbols can be pulled into shared objects from archives
12378 whole_archive_flag_spec_CXX='$convenience'
12379 fi
12380 archive_cmds_need_lc_CXX=yes
12381 # This is similar to how AIX traditionally builds its shared
12382 # libraries.
12383 archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
12384 fi
12385 fi
12386 ;;
0f8f2de1 12387
b686ecb5
JM
12388 beos*)
12389 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
12390 allow_undefined_flag_CXX=unsupported
12391 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
12392 # support --undefined. This deserves some investigation. FIXME
12393 archive_cmds_CXX='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
12394 else
12395 ld_shlibs_CXX=no
12396 fi
12397 ;;
62f29fda 12398
b686ecb5
JM
12399 chorus*)
12400 case $cc_basename in
12401 *)
12402 # FIXME: insert proper C++ library support
12403 ld_shlibs_CXX=no
12404 ;;
12405 esac
12406 ;;
62f29fda 12407
b686ecb5
JM
12408 cygwin* | mingw* | pw32* | cegcc*)
12409 # _LT_TAGVAR(hardcode_libdir_flag_spec, CXX) is actually meaningless,
12410 # as there is no search path for DLLs.
12411 hardcode_libdir_flag_spec_CXX='-L$libdir'
12412 export_dynamic_flag_spec_CXX='${wl}--export-all-symbols'
12413 allow_undefined_flag_CXX=unsupported
12414 always_export_symbols_CXX=no
12415 enable_shared_with_static_runtimes_CXX=yes
12416
12417 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
12418 archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
12419 # If the export-symbols file already is a .def file (1st line
12420 # is EXPORTS), use it as is; otherwise, prepend...
12421 archive_expsym_cmds_CXX='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
12422 cp $export_symbols $output_objdir/$soname.def;
12423 else
12424 echo EXPORTS > $output_objdir/$soname.def;
12425 cat $export_symbols >> $output_objdir/$soname.def;
12426 fi~
12427 $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
12428 else
12429 ld_shlibs_CXX=no
0f8f2de1 12430 fi
b686ecb5
JM
12431 ;;
12432 darwin* | rhapsody*)
12433
12434
12435 archive_cmds_need_lc_CXX=no
12436 hardcode_direct_CXX=no
12437 hardcode_automatic_CXX=yes
12438 hardcode_shlibpath_var_CXX=unsupported
12439 if test "$lt_cv_ld_force_load" = "yes"; then
12440 whole_archive_flag_spec_CXX='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
12441 else
12442 whole_archive_flag_spec_CXX=''
12443 fi
12444 link_all_deplibs_CXX=yes
12445 allow_undefined_flag_CXX="$_lt_dar_allow_undefined"
12446 case $cc_basename in
12447 ifort*) _lt_dar_can_shared=yes ;;
12448 *) _lt_dar_can_shared=$GCC ;;
12449 esac
12450 if test "$_lt_dar_can_shared" = "yes"; then
12451 output_verbose_link_cmd=func_echo_all
12452 archive_cmds_CXX="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
12453 module_cmds_CXX="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
12454 archive_expsym_cmds_CXX="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
12455 module_expsym_cmds_CXX="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}"
12456 if test "$lt_cv_apple_cc_single_mod" != "yes"; then
12457 archive_cmds_CXX="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}"
12458 archive_expsym_cmds_CXX="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}"
189b8c2e 12459 fi
b686ecb5
JM
12460
12461 else
12462 ld_shlibs_CXX=no
189b8c2e 12463 fi
62f29fda 12464
b686ecb5 12465 ;;
62f29fda 12466
b686ecb5
JM
12467 dgux*)
12468 case $cc_basename in
12469 ec++*)
12470 # FIXME: insert proper C++ library support
12471 ld_shlibs_CXX=no
12472 ;;
12473 ghcx*)
12474 # Green Hills C++ Compiler
12475 # FIXME: insert proper C++ library support
12476 ld_shlibs_CXX=no
12477 ;;
12478 *)
12479 # FIXME: insert proper C++ library support
12480 ld_shlibs_CXX=no
12481 ;;
12482 esac
12483 ;;
62f29fda 12484
b686ecb5
JM
12485 freebsd2.*)
12486 # C++ shared libraries reported to be fairly broken before
12487 # switch to ELF
12488 ld_shlibs_CXX=no
12489 ;;
58bfce93 12490
b686ecb5
JM
12491 freebsd-elf*)
12492 archive_cmds_need_lc_CXX=no
12493 ;;
5599c404 12494
b686ecb5
JM
12495 freebsd* | dragonfly*)
12496 # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
12497 # conventions
12498 ld_shlibs_CXX=yes
12499 ;;
58bfce93 12500
b686ecb5
JM
12501 gnu*)
12502 ;;
58bfce93 12503
b686ecb5
JM
12504 haiku*)
12505 archive_cmds_CXX='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
12506 link_all_deplibs_CXX=yes
12507 ;;
58bfce93 12508
b686ecb5
JM
12509 hpux9*)
12510 hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir'
12511 hardcode_libdir_separator_CXX=:
12512 export_dynamic_flag_spec_CXX='${wl}-E'
12513 hardcode_direct_CXX=yes
12514 hardcode_minus_L_CXX=yes # Not in the search PATH,
12515 # but as the default
12516 # location of the library.
12517
12518 case $cc_basename in
12519 CC*)
12520 # FIXME: insert proper C++ library support
12521 ld_shlibs_CXX=no
12522 ;;
12523 aCC*)
12524 archive_cmds_CXX='$RM $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
12525 # Commands to make compiler produce verbose output that lists
12526 # what "hidden" libraries, object files and flags are used when
12527 # linking a shared library.
12528 #
12529 # There doesn't appear to be a way to prevent this compiler from
12530 # explicitly linking system object files so we need to strip them
12531 # from the output so that they don't get included in the library
12532 # dependencies.
12533 output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
12534 ;;
12535 *)
12536 if test "$GXX" = yes; then
12537 archive_cmds_CXX='$RM $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
12538 else
12539 # FIXME: insert proper C++ library support
12540 ld_shlibs_CXX=no
12541 fi
12542 ;;
12543 esac
12544 ;;
58bfce93 12545
b686ecb5
JM
12546 hpux10*|hpux11*)
12547 if test $with_gnu_ld = no; then
12548 hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir'
12549 hardcode_libdir_separator_CXX=:
12550
12551 case $host_cpu in
12552 hppa*64*|ia64*)
12553 ;;
12554 *)
12555 export_dynamic_flag_spec_CXX='${wl}-E'
12556 ;;
12557 esac
12558 fi
12559 case $host_cpu in
12560 hppa*64*|ia64*)
12561 hardcode_direct_CXX=no
12562 hardcode_shlibpath_var_CXX=no
12563 ;;
12564 *)
12565 hardcode_direct_CXX=yes
12566 hardcode_direct_absolute_CXX=yes
12567 hardcode_minus_L_CXX=yes # Not in the search PATH,
12568 # but as the default
12569 # location of the library.
12570 ;;
12571 esac
58bfce93 12572
b686ecb5
JM
12573 case $cc_basename in
12574 CC*)
12575 # FIXME: insert proper C++ library support
12576 ld_shlibs_CXX=no
12577 ;;
12578 aCC*)
12579 case $host_cpu in
12580 hppa*64*)
12581 archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
12582 ;;
12583 ia64*)
12584 archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
12585 ;;
12586 *)
12587 archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
12588 ;;
12589 esac
12590 # Commands to make compiler produce verbose output that lists
12591 # what "hidden" libraries, object files and flags are used when
12592 # linking a shared library.
12593 #
12594 # There doesn't appear to be a way to prevent this compiler from
12595 # explicitly linking system object files so we need to strip them
12596 # from the output so that they don't get included in the library
12597 # dependencies.
12598 output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
12599 ;;
12600 *)
12601 if test "$GXX" = yes; then
12602 if test $with_gnu_ld = no; then
12603 case $host_cpu in
12604 hppa*64*)
12605 archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
12606 ;;
12607 ia64*)
12608 archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
12609 ;;
12610 *)
12611 archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
12612 ;;
12613 esac
12614 fi
12615 else
12616 # FIXME: insert proper C++ library support
12617 ld_shlibs_CXX=no
12618 fi
12619 ;;
12620 esac
12621 ;;
58bfce93 12622
b686ecb5
JM
12623 interix[3-9]*)
12624 hardcode_direct_CXX=no
12625 hardcode_shlibpath_var_CXX=no
12626 hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
12627 export_dynamic_flag_spec_CXX='${wl}-E'
12628 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
12629 # Instead, shared libraries are loaded at an image base (0x10000000 by
12630 # default) and relocated if they conflict, which is a slow very memory
12631 # consuming and fragmenting process. To avoid this, we pick a random,
12632 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
12633 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
12634 archive_cmds_CXX='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
12635 archive_expsym_cmds_CXX='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
12636 ;;
12637 irix5* | irix6*)
12638 case $cc_basename in
12639 CC*)
12640 # SGI C++
12641 archive_cmds_CXX='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
12642
12643 # Archives containing C++ object files must be created using
12644 # "CC -ar", where "CC" is the IRIX C++ compiler. This is
12645 # necessary to make sure instantiated templates are included
12646 # in the archive.
12647 old_archive_cmds_CXX='$CC -ar -WR,-u -o $oldlib $oldobjs'
12648 ;;
12649 *)
12650 if test "$GXX" = yes; then
12651 if test "$with_gnu_ld" = no; then
12652 archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
12653 else
12654 archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` -o $lib'
12655 fi
12656 fi
12657 link_all_deplibs_CXX=yes
12658 ;;
12659 esac
12660 hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
12661 hardcode_libdir_separator_CXX=:
12662 inherit_rpath_CXX=yes
12663 ;;
58bfce93 12664
b686ecb5
JM
12665 linux* | k*bsd*-gnu | kopensolaris*-gnu)
12666 case $cc_basename in
12667 KCC*)
12668 # Kuck and Associates, Inc. (KAI) C++ Compiler
12669
12670 # KCC will only create a shared library if the output file
12671 # ends with ".so" (or ".sl" for HP-UX), so rename the library
12672 # to its proper name (with version) after linking.
12673 archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
12674 archive_expsym_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib'
12675 # Commands to make compiler produce verbose output that lists
12676 # what "hidden" libraries, object files and flags are used when
12677 # linking a shared library.
12678 #
12679 # There doesn't appear to be a way to prevent this compiler from
12680 # explicitly linking system object files so we need to strip them
12681 # from the output so that they don't get included in the library
12682 # dependencies.
12683 output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
12684
12685 hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
12686 export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
12687
12688 # Archives containing C++ object files must be created using
12689 # "CC -Bstatic", where "CC" is the KAI C++ compiler.
12690 old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs'
12691 ;;
12692 icpc* | ecpc* )
12693 # Intel C++
12694 with_gnu_ld=yes
12695 # version 8.0 and above of icpc choke on multiply defined symbols
12696 # if we add $predep_objects and $postdep_objects, however 7.1 and
12697 # earlier do not add the objects themselves.
12698 case `$CC -V 2>&1` in
12699 *"Version 7."*)
12700 archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
12701 archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
12702 ;;
12703 *) # Version 8.0 or newer
12704 tmp_idyn=
12705 case $host_cpu in
12706 ia64*) tmp_idyn=' -i_dynamic';;
12707 esac
12708 archive_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
12709 archive_expsym_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
12710 ;;
12711 esac
12712 archive_cmds_need_lc_CXX=no
12713 hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
12714 export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
12715 whole_archive_flag_spec_CXX='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
12716 ;;
12717 pgCC* | pgcpp*)
12718 # Portland Group C++ compiler
12719 case `$CC -V` in
12720 *pgCC\ [1-5].* | *pgcpp\ [1-5].*)
12721 prelink_cmds_CXX='tpldir=Template.dir~
12722 rm -rf $tpldir~
12723 $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~
12724 compile_command="$compile_command `find $tpldir -name \*.o | $NL2SP`"'
12725 old_archive_cmds_CXX='tpldir=Template.dir~
12726 rm -rf $tpldir~
12727 $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~
12728 $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | $NL2SP`~
12729 $RANLIB $oldlib'
12730 archive_cmds_CXX='tpldir=Template.dir~
12731 rm -rf $tpldir~
12732 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
12733 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
12734 archive_expsym_cmds_CXX='tpldir=Template.dir~
12735 rm -rf $tpldir~
12736 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
12737 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
12738 ;;
12739 *) # Version 6 and above use weak symbols
12740 archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
12741 archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
12742 ;;
12743 esac
58bfce93 12744
b686ecb5
JM
12745 hardcode_libdir_flag_spec_CXX='${wl}--rpath ${wl}$libdir'
12746 export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
12747 whole_archive_flag_spec_CXX='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
12748 ;;
12749 cxx*)
12750 # Compaq C++
12751 archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
12752 archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib ${wl}-retain-symbols-file $wl$export_symbols'
12753
12754 runpath_var=LD_RUN_PATH
12755 hardcode_libdir_flag_spec_CXX='-rpath $libdir'
12756 hardcode_libdir_separator_CXX=:
12757
12758 # Commands to make compiler produce verbose output that lists
12759 # what "hidden" libraries, object files and flags are used when
12760 # linking a shared library.
12761 #
12762 # There doesn't appear to be a way to prevent this compiler from
12763 # explicitly linking system object files so we need to strip them
12764 # from the output so that they don't get included in the library
12765 # dependencies.
12766 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed'
12767 ;;
12768 xl* | mpixl* | bgxl*)
12769 # IBM XL 8.0 on PPC, with GNU ld
12770 hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
12771 export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
12772 archive_cmds_CXX='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
12773 if test "x$supports_anon_versioning" = xyes; then
12774 archive_expsym_cmds_CXX='echo "{ global:" > $output_objdir/$libname.ver~
12775 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
12776 echo "local: *; };" >> $output_objdir/$libname.ver~
12777 $CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
12778 fi
12779 ;;
12780 *)
12781 case `$CC -V 2>&1 | sed 5q` in
12782 *Sun\ C*)
12783 # Sun C++ 5.9
12784 no_undefined_flag_CXX=' -zdefs'
12785 archive_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
12786 archive_expsym_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols'
12787 hardcode_libdir_flag_spec_CXX='-R$libdir'
12788 whole_archive_flag_spec_CXX='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
12789 compiler_needs_object_CXX=yes
12790
12791 # Not sure whether something based on
12792 # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1
12793 # would be better.
12794 output_verbose_link_cmd='func_echo_all'
12795
12796 # Archives containing C++ object files must be created using
12797 # "CC -xar", where "CC" is the Sun C++ compiler. This is
12798 # necessary to make sure instantiated templates are included
12799 # in the archive.
12800 old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs'
12801 ;;
12802 esac
12803 ;;
12804 esac
12805 ;;
58bfce93 12806
b686ecb5
JM
12807 lynxos*)
12808 # FIXME: insert proper C++ library support
12809 ld_shlibs_CXX=no
12810 ;;
58bfce93 12811
b686ecb5
JM
12812 m88k*)
12813 # FIXME: insert proper C++ library support
12814 ld_shlibs_CXX=no
12815 ;;
58bfce93 12816
b686ecb5
JM
12817 mvs*)
12818 case $cc_basename in
12819 cxx*)
12820 # FIXME: insert proper C++ library support
12821 ld_shlibs_CXX=no
12822 ;;
12823 *)
12824 # FIXME: insert proper C++ library support
12825 ld_shlibs_CXX=no
12826 ;;
12827 esac
12828 ;;
58bfce93 12829
b686ecb5
JM
12830 netbsd*)
12831 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
12832 archive_cmds_CXX='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
12833 wlarc=
12834 hardcode_libdir_flag_spec_CXX='-R$libdir'
12835 hardcode_direct_CXX=yes
12836 hardcode_shlibpath_var_CXX=no
12837 fi
12838 # Workaround some broken pre-1.5 toolchains
12839 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
12840 ;;
58bfce93 12841
b686ecb5
JM
12842 *nto* | *qnx*)
12843 ld_shlibs_CXX=yes
12844 ;;
58bfce93 12845
b686ecb5
JM
12846 openbsd2*)
12847 # C++ shared libraries are fairly broken
12848 ld_shlibs_CXX=no
12849 ;;
58bfce93 12850
b686ecb5
JM
12851 openbsd*)
12852 if test -f /usr/libexec/ld.so; then
12853 hardcode_direct_CXX=yes
12854 hardcode_shlibpath_var_CXX=no
12855 hardcode_direct_absolute_CXX=yes
12856 archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
12857 hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
12858 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
12859 archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib'
12860 export_dynamic_flag_spec_CXX='${wl}-E'
12861 whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
12862 fi
12863 output_verbose_link_cmd=func_echo_all
12864 else
12865 ld_shlibs_CXX=no
12866 fi
12867 ;;
58bfce93 12868
b686ecb5
JM
12869 osf3* | osf4* | osf5*)
12870 case $cc_basename in
12871 KCC*)
12872 # Kuck and Associates, Inc. (KAI) C++ Compiler
58bfce93 12873
b686ecb5
JM
12874 # KCC will only create a shared library if the output file
12875 # ends with ".so" (or ".sl" for HP-UX), so rename the library
12876 # to its proper name (with version) after linking.
12877 archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
58bfce93 12878
b686ecb5
JM
12879 hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
12880 hardcode_libdir_separator_CXX=:
58bfce93 12881
b686ecb5
JM
12882 # Archives containing C++ object files must be created using
12883 # the KAI C++ compiler.
12884 case $host in
12885 osf3*) old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs' ;;
12886 *) old_archive_cmds_CXX='$CC -o $oldlib $oldobjs' ;;
12887 esac
12888 ;;
12889 RCC*)
12890 # Rational C++ 2.4.1
12891 # FIXME: insert proper C++ library support
12892 ld_shlibs_CXX=no
12893 ;;
12894 cxx*)
12895 case $host in
12896 osf3*)
12897 allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*'
12898 archive_cmds_CXX='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && func_echo_all "${wl}-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
12899 hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
12900 ;;
12901 *)
12902 allow_undefined_flag_CXX=' -expect_unresolved \*'
12903 archive_cmds_CXX='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
12904 archive_expsym_cmds_CXX='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
12905 echo "-hidden">> $lib.exp~
12906 $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname ${wl}-input ${wl}$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~
12907 $RM $lib.exp'
12908 hardcode_libdir_flag_spec_CXX='-rpath $libdir'
12909 ;;
12910 esac
58bfce93 12911
b686ecb5
JM
12912 hardcode_libdir_separator_CXX=:
12913
12914 # Commands to make compiler produce verbose output that lists
12915 # what "hidden" libraries, object files and flags are used when
12916 # linking a shared library.
12917 #
12918 # There doesn't appear to be a way to prevent this compiler from
12919 # explicitly linking system object files so we need to strip them
12920 # from the output so that they don't get included in the library
12921 # dependencies.
12922 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
12923 ;;
12924 *)
12925 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
12926 allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*'
12927 case $host in
12928 osf3*)
12929 archive_cmds_CXX='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
12930 ;;
12931 *)
12932 archive_cmds_CXX='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
12933 ;;
12934 esac
12935
12936 hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
12937 hardcode_libdir_separator_CXX=:
12938
12939 # Commands to make compiler produce verbose output that lists
12940 # what "hidden" libraries, object files and flags are used when
12941 # linking a shared library.
12942 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
58bfce93 12943
b686ecb5
JM
12944 else
12945 # FIXME: insert proper C++ library support
12946 ld_shlibs_CXX=no
12947 fi
12948 ;;
12949 esac
12950 ;;
58bfce93 12951
b686ecb5
JM
12952 psos*)
12953 # FIXME: insert proper C++ library support
12954 ld_shlibs_CXX=no
12955 ;;
58bfce93 12956
b686ecb5
JM
12957 sunos4*)
12958 case $cc_basename in
12959 CC*)
12960 # Sun C++ 4.x
12961 # FIXME: insert proper C++ library support
12962 ld_shlibs_CXX=no
12963 ;;
12964 lcc*)
12965 # Lucid
12966 # FIXME: insert proper C++ library support
12967 ld_shlibs_CXX=no
12968 ;;
12969 *)
12970 # FIXME: insert proper C++ library support
12971 ld_shlibs_CXX=no
12972 ;;
12973 esac
12974 ;;
58bfce93 12975
b686ecb5
JM
12976 solaris*)
12977 case $cc_basename in
12978 CC*)
12979 # Sun C++ 4.2, 5.x and Centerline C++
12980 archive_cmds_need_lc_CXX=yes
12981 no_undefined_flag_CXX=' -zdefs'
12982 archive_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
12983 archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
12984 $CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
12985
12986 hardcode_libdir_flag_spec_CXX='-R$libdir'
12987 hardcode_shlibpath_var_CXX=no
12988 case $host_os in
12989 solaris2.[0-5] | solaris2.[0-5].*) ;;
12990 *)
12991 # The compiler driver will combine and reorder linker options,
12992 # but understands `-z linker_flag'.
12993 # Supported since Solaris 2.6 (maybe 2.5.1?)
12994 whole_archive_flag_spec_CXX='-z allextract$convenience -z defaultextract'
12995 ;;
12996 esac
12997 link_all_deplibs_CXX=yes
58bfce93 12998
b686ecb5 12999 output_verbose_link_cmd='func_echo_all'
58bfce93 13000
b686ecb5
JM
13001 # Archives containing C++ object files must be created using
13002 # "CC -xar", where "CC" is the Sun C++ compiler. This is
13003 # necessary to make sure instantiated templates are included
13004 # in the archive.
13005 old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs'
13006 ;;
13007 gcx*)
13008 # Green Hills C++ Compiler
13009 archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
58bfce93 13010
b686ecb5
JM
13011 # The C++ compiler must be used to create the archive.
13012 old_archive_cmds_CXX='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
13013 ;;
13014 *)
13015 # GNU C++ compiler with Solaris linker
13016 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
13017 no_undefined_flag_CXX=' ${wl}-z ${wl}defs'
13018 if $CC --version | $GREP -v '^2\.7' > /dev/null; then
13019 archive_cmds_CXX='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
13020 archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
13021 $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
13022
13023 # Commands to make compiler produce verbose output that lists
13024 # what "hidden" libraries, object files and flags are used when
13025 # linking a shared library.
13026 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
13027 else
13028 # g++ 2.7 appears to require `-G' NOT `-shared' on this
13029 # platform.
13030 archive_cmds_CXX='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
13031 archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
13032 $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
13033
13034 # Commands to make compiler produce verbose output that lists
13035 # what "hidden" libraries, object files and flags are used when
13036 # linking a shared library.
13037 output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
13038 fi
58bfce93 13039
b686ecb5
JM
13040 hardcode_libdir_flag_spec_CXX='${wl}-R $wl$libdir'
13041 case $host_os in
13042 solaris2.[0-5] | solaris2.[0-5].*) ;;
13043 *)
13044 whole_archive_flag_spec_CXX='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
13045 ;;
13046 esac
13047 fi
13048 ;;
13049 esac
13050 ;;
58bfce93 13051
b686ecb5
JM
13052 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
13053 no_undefined_flag_CXX='${wl}-z,text'
13054 archive_cmds_need_lc_CXX=no
13055 hardcode_shlibpath_var_CXX=no
13056 runpath_var='LD_RUN_PATH'
13057
13058 case $cc_basename in
13059 CC*)
13060 archive_cmds_CXX='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
13061 archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
13062 ;;
13063 *)
13064 archive_cmds_CXX='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
13065 archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
13066 ;;
13067 esac
13068 ;;
58bfce93 13069
b686ecb5
JM
13070 sysv5* | sco3.2v5* | sco5v6*)
13071 # Note: We can NOT use -z defs as we might desire, because we do not
13072 # link with -lc, and that would cause any symbols used from libc to
13073 # always be unresolved, which means just about no library would
13074 # ever link correctly. If we're not using GNU ld we use -z text
13075 # though, which does catch some bad symbols but isn't as heavy-handed
13076 # as -z defs.
13077 no_undefined_flag_CXX='${wl}-z,text'
13078 allow_undefined_flag_CXX='${wl}-z,nodefs'
13079 archive_cmds_need_lc_CXX=no
13080 hardcode_shlibpath_var_CXX=no
13081 hardcode_libdir_flag_spec_CXX='${wl}-R,$libdir'
13082 hardcode_libdir_separator_CXX=':'
13083 link_all_deplibs_CXX=yes
13084 export_dynamic_flag_spec_CXX='${wl}-Bexport'
13085 runpath_var='LD_RUN_PATH'
13086
13087 case $cc_basename in
13088 CC*)
13089 archive_cmds_CXX='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
13090 archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
13091 old_archive_cmds_CXX='$CC -Tprelink_objects $oldobjs~
13092 '"$old_archive_cmds_CXX"
13093 reload_cmds_CXX='$CC -Tprelink_objects $reload_objs~
13094 '"$reload_cmds_CXX"
13095 ;;
13096 *)
13097 archive_cmds_CXX='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
13098 archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
13099 ;;
13100 esac
13101 ;;
58bfce93 13102
b686ecb5
JM
13103 tandem*)
13104 case $cc_basename in
13105 NCC*)
13106 # NonStop-UX NCC 3.20
13107 # FIXME: insert proper C++ library support
13108 ld_shlibs_CXX=no
13109 ;;
13110 *)
13111 # FIXME: insert proper C++ library support
13112 ld_shlibs_CXX=no
13113 ;;
13114 esac
13115 ;;
05a6b8c2 13116
b686ecb5
JM
13117 vxworks*)
13118 # FIXME: insert proper C++ library support
13119 ld_shlibs_CXX=no
13120 ;;
05a6b8c2 13121
b686ecb5
JM
13122 *)
13123 # FIXME: insert proper C++ library support
13124 ld_shlibs_CXX=no
13125 ;;
13126 esac
05a6b8c2 13127
b686ecb5
JM
13128 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5
13129$as_echo "$ld_shlibs_CXX" >&6; }
13130 test "$ld_shlibs_CXX" = no && can_build_shared=no
13131
13132 GCC_CXX="$GXX"
13133 LD_CXX="$LD"
13134
13135 ## CAVEAT EMPTOR:
13136 ## There is no encapsulation within the following macros, do not change
13137 ## the running order or otherwise move them around unless you know exactly
13138 ## what you are doing...
13139 # Dependencies to place before and after the object being linked:
13140predep_objects_CXX=
13141postdep_objects_CXX=
13142predeps_CXX=
13143postdeps_CXX=
13144compiler_lib_search_path_CXX=
13145
13146cat > conftest.$ac_ext <<_LT_EOF
13147class Foo
13148{
13149public:
13150 Foo (void) { a = 0; }
13151private:
13152 int a;
13153};
13154_LT_EOF
13155
13156if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
13157 (eval $ac_compile) 2>&5
13158 ac_status=$?
13159 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
13160 test $ac_status = 0; }; then
13161 # Parse the compiler output and extract the necessary
13162 # objects, libraries and library flags.
13163
13164 # Sentinel used to keep track of whether or not we are before
13165 # the conftest object file.
13166 pre_test_object_deps_done=no
13167
13168 for p in `eval "$output_verbose_link_cmd"`; do
13169 case $p in
13170
13171 -L* | -R* | -l*)
13172 # Some compilers place space between "-{L,R}" and the path.
13173 # Remove the space.
13174 if test $p = "-L" ||
13175 test $p = "-R"; then
13176 prev=$p
13177 continue
13178 else
13179 prev=
13180 fi
13181
13182 if test "$pre_test_object_deps_done" = no; then
13183 case $p in
13184 -L* | -R*)
13185 # Internal compiler library paths should come after those
13186 # provided the user. The postdeps already come after the
13187 # user supplied libs so there is no need to process them.
13188 if test -z "$compiler_lib_search_path_CXX"; then
13189 compiler_lib_search_path_CXX="${prev}${p}"
13190 else
13191 compiler_lib_search_path_CXX="${compiler_lib_search_path_CXX} ${prev}${p}"
13192 fi
13193 ;;
13194 # The "-l" case would never come before the object being
13195 # linked, so don't bother handling this case.
13196 esac
13197 else
13198 if test -z "$postdeps_CXX"; then
13199 postdeps_CXX="${prev}${p}"
13200 else
13201 postdeps_CXX="${postdeps_CXX} ${prev}${p}"
13202 fi
13203 fi
13204 ;;
13205
13206 *.$objext)
13207 # This assumes that the test object file only shows up
13208 # once in the compiler output.
13209 if test "$p" = "conftest.$objext"; then
13210 pre_test_object_deps_done=yes
13211 continue
13212 fi
13213
13214 if test "$pre_test_object_deps_done" = no; then
13215 if test -z "$predep_objects_CXX"; then
13216 predep_objects_CXX="$p"
13217 else
13218 predep_objects_CXX="$predep_objects_CXX $p"
13219 fi
13220 else
13221 if test -z "$postdep_objects_CXX"; then
13222 postdep_objects_CXX="$p"
13223 else
13224 postdep_objects_CXX="$postdep_objects_CXX $p"
13225 fi
13226 fi
13227 ;;
05a6b8c2 13228
b686ecb5 13229 *) ;; # Ignore the rest.
05a6b8c2 13230
b686ecb5
JM
13231 esac
13232 done
6aa4f97c 13233
b686ecb5
JM
13234 # Clean up.
13235 rm -f a.out a.exe
13236else
13237 echo "libtool.m4: error: problem compiling CXX test program"
6aa4f97c
AB
13238fi
13239
b686ecb5 13240$RM -f confest.$objext
05a6b8c2 13241
b686ecb5
JM
13242# PORTME: override above test on systems where it is broken
13243case $host_os in
13244interix[3-9]*)
13245 # Interix 3.5 installs completely hosed .la files for C++, so rather than
13246 # hack all around it, let's just trust "g++" to DTRT.
13247 predep_objects_CXX=
13248 postdep_objects_CXX=
13249 postdeps_CXX=
13250 ;;
58bfce93 13251
b686ecb5
JM
13252linux*)
13253 case `$CC -V 2>&1 | sed 5q` in
13254 *Sun\ C*)
13255 # Sun C++ 5.9
13256
13257 # The more standards-conforming stlport4 library is
13258 # incompatible with the Cstd library. Avoid specifying
13259 # it if it's in CXXFLAGS. Ignore libCrun as
13260 # -library=stlport4 depends on it.
13261 case " $CXX $CXXFLAGS " in
13262 *" -library=stlport4 "*)
13263 solaris_use_stlport4=yes
13264 ;;
13265 esac
58bfce93 13266
b686ecb5
JM
13267 if test "$solaris_use_stlport4" != yes; then
13268 postdeps_CXX='-library=Cstd -library=Crun'
13269 fi
13270 ;;
13271 esac
13272 ;;
58bfce93 13273
b686ecb5
JM
13274solaris*)
13275 case $cc_basename in
13276 CC*)
13277 # The more standards-conforming stlport4 library is
13278 # incompatible with the Cstd library. Avoid specifying
13279 # it if it's in CXXFLAGS. Ignore libCrun as
13280 # -library=stlport4 depends on it.
13281 case " $CXX $CXXFLAGS " in
13282 *" -library=stlport4 "*)
13283 solaris_use_stlport4=yes
13284 ;;
13285 esac
05ea2a05 13286
b686ecb5
JM
13287 # Adding this requires a known-good setup of shared libraries for
13288 # Sun compiler versions before 5.6, else PIC objects from an old
13289 # archive will be linked into the output, leading to subtle bugs.
13290 if test "$solaris_use_stlport4" != yes; then
13291 postdeps_CXX='-library=Cstd -library=Crun'
13292 fi
13293 ;;
13294 esac
13295 ;;
13296esac
58bfce93 13297
58bfce93 13298
b686ecb5
JM
13299case " $postdeps_CXX " in
13300*" -lc "*) archive_cmds_need_lc_CXX=no ;;
13301esac
13302 compiler_lib_search_dirs_CXX=
13303if test -n "${compiler_lib_search_path_CXX}"; then
13304 compiler_lib_search_dirs_CXX=`echo " ${compiler_lib_search_path_CXX}" | ${SED} -e 's! -L! !g' -e 's!^ !!'`
58bfce93 13305fi
58bfce93
MM
13306
13307
13308
13309
c56ccc05 13310
c56ccc05 13311
c56ccc05 13312
c56ccc05 13313
58bfce93 13314
c890192f 13315
81ecdfbb 13316
a9322a30 13317
bec39cab 13318
bec39cab 13319
bec39cab 13320
81ecdfbb 13321
81ecdfbb 13322
81ecdfbb 13323
06825bd1 13324
bec39cab 13325
81ecdfbb 13326
05ea2a05 13327
bec39cab 13328
bec39cab 13329
5ee754fc 13330
bec39cab 13331
05ea2a05 13332
05ea2a05 13333
05ea2a05 13334
c906108c 13335
05ea2a05 13336
b686ecb5
JM
13337 lt_prog_compiler_wl_CXX=
13338lt_prog_compiler_pic_CXX=
13339lt_prog_compiler_static_CXX=
81ecdfbb 13340
b686ecb5
JM
13341{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
13342$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
81ecdfbb 13343
b686ecb5
JM
13344 # C++ specific cases for pic, static, wl, etc.
13345 if test "$GXX" = yes; then
13346 lt_prog_compiler_wl_CXX='-Wl,'
13347 lt_prog_compiler_static_CXX='-static'
13348
13349 case $host_os in
13350 aix*)
13351 # All AIX code is PIC.
13352 if test "$host_cpu" = ia64; then
13353 # AIX 5 now supports IA64 processor
13354 lt_prog_compiler_static_CXX='-Bstatic'
13355 fi
13356 lt_prog_compiler_pic_CXX='-fPIC'
13357 ;;
a9322a30 13358
b686ecb5
JM
13359 amigaos*)
13360 case $host_cpu in
13361 powerpc)
13362 # see comment about AmigaOS4 .so support
13363 lt_prog_compiler_pic_CXX='-fPIC'
13364 ;;
13365 m68k)
13366 # FIXME: we need at least 68020 code to build shared libraries, but
13367 # adding the `-m68020' flag to GCC prevents building anything better,
13368 # like `-m68040'.
13369 lt_prog_compiler_pic_CXX='-m68020 -resident32 -malways-restore-a4'
13370 ;;
13371 esac
13372 ;;
bec39cab 13373
b686ecb5
JM
13374 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
13375 # PIC is the default for these OSes.
13376 ;;
13377 mingw* | cygwin* | os2* | pw32* | cegcc*)
13378 # This hack is so that the source file can tell whether it is being
13379 # built for inclusion in a dll (and should export symbols for example).
13380 # Although the cygwin gcc ignores -fPIC, still need this for old-style
13381 # (--disable-auto-import) libraries
13382 lt_prog_compiler_pic_CXX='-DDLL_EXPORT'
13383 ;;
13384 darwin* | rhapsody*)
13385 # PIC is the default on this platform
13386 # Common symbols not allowed in MH_DYLIB files
13387 lt_prog_compiler_pic_CXX='-fno-common'
13388 ;;
13389 *djgpp*)
13390 # DJGPP does not support shared libraries at all
13391 lt_prog_compiler_pic_CXX=
13392 ;;
13393 haiku*)
13394 # PIC is the default for Haiku.
13395 # The "-static" flag exists, but is broken.
13396 lt_prog_compiler_static_CXX=
13397 ;;
13398 interix[3-9]*)
13399 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
13400 # Instead, we relocate shared libraries at runtime.
13401 ;;
13402 sysv4*MP*)
13403 if test -d /usr/nec; then
13404 lt_prog_compiler_pic_CXX=-Kconform_pic
13405 fi
13406 ;;
13407 hpux*)
13408 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
13409 # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
13410 # sets the default TLS model and affects inlining.
13411 case $host_cpu in
13412 hppa*64*)
13413 ;;
13414 *)
13415 lt_prog_compiler_pic_CXX='-fPIC'
13416 ;;
13417 esac
13418 ;;
13419 *qnx* | *nto*)
13420 # QNX uses GNU C++, but need to define -shared option too, otherwise
13421 # it will coredump.
13422 lt_prog_compiler_pic_CXX='-fPIC -shared'
13423 ;;
13424 *)
13425 lt_prog_compiler_pic_CXX='-fPIC'
13426 ;;
13427 esac
13428 else
13429 case $host_os in
13430 aix[4-9]*)
13431 # All AIX code is PIC.
13432 if test "$host_cpu" = ia64; then
13433 # AIX 5 now supports IA64 processor
13434 lt_prog_compiler_static_CXX='-Bstatic'
13435 else
13436 lt_prog_compiler_static_CXX='-bnso -bI:/lib/syscalls.exp'
13437 fi
13438 ;;
13439 chorus*)
13440 case $cc_basename in
13441 cxch68*)
13442 # Green Hills C++ Compiler
13443 # _LT_TAGVAR(lt_prog_compiler_static, CXX)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a"
13444 ;;
13445 esac
13446 ;;
13447 dgux*)
13448 case $cc_basename in
13449 ec++*)
13450 lt_prog_compiler_pic_CXX='-KPIC'
13451 ;;
13452 ghcx*)
13453 # Green Hills C++ Compiler
13454 lt_prog_compiler_pic_CXX='-pic'
13455 ;;
13456 *)
13457 ;;
13458 esac
13459 ;;
13460 freebsd* | dragonfly*)
13461 # FreeBSD uses GNU C++
13462 ;;
13463 hpux9* | hpux10* | hpux11*)
13464 case $cc_basename in
13465 CC*)
13466 lt_prog_compiler_wl_CXX='-Wl,'
13467 lt_prog_compiler_static_CXX='${wl}-a ${wl}archive'
13468 if test "$host_cpu" != ia64; then
13469 lt_prog_compiler_pic_CXX='+Z'
13470 fi
13471 ;;
13472 aCC*)
13473 lt_prog_compiler_wl_CXX='-Wl,'
13474 lt_prog_compiler_static_CXX='${wl}-a ${wl}archive'
13475 case $host_cpu in
13476 hppa*64*|ia64*)
13477 # +Z the default
13478 ;;
13479 *)
13480 lt_prog_compiler_pic_CXX='+Z'
13481 ;;
13482 esac
13483 ;;
13484 *)
13485 ;;
13486 esac
13487 ;;
13488 interix*)
13489 # This is c89, which is MS Visual C++ (no shared libs)
13490 # Anyone wants to do a port?
13491 ;;
13492 irix5* | irix6* | nonstopux*)
13493 case $cc_basename in
13494 CC*)
13495 lt_prog_compiler_wl_CXX='-Wl,'
13496 lt_prog_compiler_static_CXX='-non_shared'
13497 # CC pic flag -KPIC is the default.
13498 ;;
13499 *)
13500 ;;
13501 esac
13502 ;;
13503 linux* | k*bsd*-gnu | kopensolaris*-gnu)
13504 case $cc_basename in
13505 KCC*)
13506 # KAI C++ Compiler
13507 lt_prog_compiler_wl_CXX='--backend -Wl,'
13508 lt_prog_compiler_pic_CXX='-fPIC'
13509 ;;
13510 ecpc* )
13511 # old Intel C++ for x86_64 which still supported -KPIC.
13512 lt_prog_compiler_wl_CXX='-Wl,'
13513 lt_prog_compiler_pic_CXX='-KPIC'
13514 lt_prog_compiler_static_CXX='-static'
13515 ;;
13516 icpc* )
13517 # Intel C++, used to be incompatible with GCC.
13518 # ICC 10 doesn't accept -KPIC any more.
13519 lt_prog_compiler_wl_CXX='-Wl,'
13520 lt_prog_compiler_pic_CXX='-fPIC'
13521 lt_prog_compiler_static_CXX='-static'
13522 ;;
13523 pgCC* | pgcpp*)
13524 # Portland Group C++ compiler
13525 lt_prog_compiler_wl_CXX='-Wl,'
13526 lt_prog_compiler_pic_CXX='-fpic'
13527 lt_prog_compiler_static_CXX='-Bstatic'
13528 ;;
13529 cxx*)
13530 # Compaq C++
13531 # Make sure the PIC flag is empty. It appears that all Alpha
13532 # Linux and Compaq Tru64 Unix objects are PIC.
13533 lt_prog_compiler_pic_CXX=
13534 lt_prog_compiler_static_CXX='-non_shared'
13535 ;;
13536 xlc* | xlC* | bgxl[cC]* | mpixl[cC]*)
13537 # IBM XL 8.0, 9.0 on PPC and BlueGene
13538 lt_prog_compiler_wl_CXX='-Wl,'
13539 lt_prog_compiler_pic_CXX='-qpic'
13540 lt_prog_compiler_static_CXX='-qstaticlink'
13541 ;;
13542 *)
13543 case `$CC -V 2>&1 | sed 5q` in
13544 *Sun\ C*)
13545 # Sun C++ 5.9
13546 lt_prog_compiler_pic_CXX='-KPIC'
13547 lt_prog_compiler_static_CXX='-Bstatic'
13548 lt_prog_compiler_wl_CXX='-Qoption ld '
13549 ;;
13550 esac
13551 ;;
13552 esac
13553 ;;
13554 lynxos*)
13555 ;;
13556 m88k*)
13557 ;;
13558 mvs*)
13559 case $cc_basename in
13560 cxx*)
13561 lt_prog_compiler_pic_CXX='-W c,exportall'
13562 ;;
13563 *)
13564 ;;
13565 esac
13566 ;;
13567 netbsd*)
13568 ;;
13569 *qnx* | *nto*)
13570 # QNX uses GNU C++, but need to define -shared option too, otherwise
13571 # it will coredump.
13572 lt_prog_compiler_pic_CXX='-fPIC -shared'
13573 ;;
13574 osf3* | osf4* | osf5*)
13575 case $cc_basename in
13576 KCC*)
13577 lt_prog_compiler_wl_CXX='--backend -Wl,'
13578 ;;
13579 RCC*)
13580 # Rational C++ 2.4.1
13581 lt_prog_compiler_pic_CXX='-pic'
13582 ;;
13583 cxx*)
13584 # Digital/Compaq C++
13585 lt_prog_compiler_wl_CXX='-Wl,'
13586 # Make sure the PIC flag is empty. It appears that all Alpha
13587 # Linux and Compaq Tru64 Unix objects are PIC.
13588 lt_prog_compiler_pic_CXX=
13589 lt_prog_compiler_static_CXX='-non_shared'
13590 ;;
13591 *)
13592 ;;
13593 esac
13594 ;;
13595 psos*)
13596 ;;
13597 solaris*)
13598 case $cc_basename in
13599 CC*)
13600 # Sun C++ 4.2, 5.x and Centerline C++
13601 lt_prog_compiler_pic_CXX='-KPIC'
13602 lt_prog_compiler_static_CXX='-Bstatic'
13603 lt_prog_compiler_wl_CXX='-Qoption ld '
13604 ;;
13605 gcx*)
13606 # Green Hills C++ Compiler
13607 lt_prog_compiler_pic_CXX='-PIC'
13608 ;;
13609 *)
13610 ;;
13611 esac
13612 ;;
13613 sunos4*)
13614 case $cc_basename in
13615 CC*)
13616 # Sun C++ 4.x
13617 lt_prog_compiler_pic_CXX='-pic'
13618 lt_prog_compiler_static_CXX='-Bstatic'
13619 ;;
13620 lcc*)
13621 # Lucid
13622 lt_prog_compiler_pic_CXX='-pic'
13623 ;;
13624 *)
13625 ;;
13626 esac
13627 ;;
13628 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
13629 case $cc_basename in
13630 CC*)
13631 lt_prog_compiler_wl_CXX='-Wl,'
13632 lt_prog_compiler_pic_CXX='-KPIC'
13633 lt_prog_compiler_static_CXX='-Bstatic'
13634 ;;
13635 esac
13636 ;;
13637 tandem*)
13638 case $cc_basename in
13639 NCC*)
13640 # NonStop-UX NCC 3.20
13641 lt_prog_compiler_pic_CXX='-KPIC'
13642 ;;
13643 *)
13644 ;;
13645 esac
13646 ;;
13647 vxworks*)
13648 ;;
13649 *)
13650 lt_prog_compiler_can_build_shared_CXX=no
13651 ;;
13652 esac
13653 fi
bec39cab 13654
b686ecb5
JM
13655case $host_os in
13656 # For platforms which do not support PIC, -DPIC is meaningless:
13657 *djgpp*)
13658 lt_prog_compiler_pic_CXX=
13659 ;;
13660 *)
13661 lt_prog_compiler_pic_CXX="$lt_prog_compiler_pic_CXX -DPIC"
13662 ;;
13663esac
13664{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic_CXX" >&5
13665$as_echo "$lt_prog_compiler_pic_CXX" >&6; }
5ee754fc 13666
5ee754fc 13667
b686ecb5
JM
13668
13669#
13670# Check to make sure the PIC flag actually works.
13671#
13672if test -n "$lt_prog_compiler_pic_CXX"; then
13673 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works" >&5
13674$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works... " >&6; }
13675if ${lt_cv_prog_compiler_pic_works_CXX+:} false; then :
13676 $as_echo_n "(cached) " >&6
05ea2a05 13677else
b686ecb5
JM
13678 lt_cv_prog_compiler_pic_works_CXX=no
13679 ac_outfile=conftest.$ac_objext
13680 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
13681 lt_compiler_flag="$lt_prog_compiler_pic_CXX -DPIC"
13682 # Insert the option either (1) after the last *FLAGS variable, or
13683 # (2) before a word containing "conftest.", or (3) at the end.
13684 # Note that $ac_compile itself does not contain backslashes and begins
13685 # with a dollar sign (not a hyphen), so the echo should work correctly.
13686 # The option is referenced via a variable to avoid confusing sed.
13687 lt_compile=`echo "$ac_compile" | $SED \
13688 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
13689 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
13690 -e 's:$: $lt_compiler_flag:'`
13691 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
13692 (eval "$lt_compile" 2>conftest.err)
13693 ac_status=$?
13694 cat conftest.err >&5
13695 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13696 if (exit $ac_status) && test -s "$ac_outfile"; then
13697 # The compiler can only warn and ignore the option if not recognized
13698 # So say no if there are warnings other than the usual output.
13699 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
13700 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
13701 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
13702 lt_cv_prog_compiler_pic_works_CXX=yes
13703 fi
13704 fi
13705 $RM conftest*
13706
5ee754fc 13707fi
b686ecb5
JM
13708{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works_CXX" >&5
13709$as_echo "$lt_cv_prog_compiler_pic_works_CXX" >&6; }
5ee754fc 13710
b686ecb5
JM
13711if test x"$lt_cv_prog_compiler_pic_works_CXX" = xyes; then
13712 case $lt_prog_compiler_pic_CXX in
13713 "" | " "*) ;;
13714 *) lt_prog_compiler_pic_CXX=" $lt_prog_compiler_pic_CXX" ;;
13715 esac
13716else
13717 lt_prog_compiler_pic_CXX=
13718 lt_prog_compiler_can_build_shared_CXX=no
13719fi
bec39cab 13720
05ea2a05
TT
13721fi
13722
b686ecb5
JM
13723
13724
13725#
13726# Check to make sure the static flag actually works.
13727#
13728wl=$lt_prog_compiler_wl_CXX eval lt_tmp_static_flag=\"$lt_prog_compiler_static_CXX\"
13729{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5
13730$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
13731if ${lt_cv_prog_compiler_static_works_CXX+:} false; then :
05ea2a05
TT
13732 $as_echo_n "(cached) " >&6
13733else
b686ecb5
JM
13734 lt_cv_prog_compiler_static_works_CXX=no
13735 save_LDFLAGS="$LDFLAGS"
13736 LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
13737 echo "$lt_simple_link_test_code" > conftest.$ac_ext
13738 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
13739 # The linker can only warn and ignore the option if not recognized
13740 # So say no if there are warnings
13741 if test -s conftest.err; then
13742 # Append any errors to the config.log.
13743 cat conftest.err 1>&5
13744 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
13745 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
13746 if diff conftest.exp conftest.er2 >/dev/null; then
13747 lt_cv_prog_compiler_static_works_CXX=yes
13748 fi
13749 else
13750 lt_cv_prog_compiler_static_works_CXX=yes
13751 fi
13752 fi
13753 $RM -r conftest*
13754 LDFLAGS="$save_LDFLAGS"
bec39cab 13755
a8111142 13756fi
b686ecb5
JM
13757{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works_CXX" >&5
13758$as_echo "$lt_cv_prog_compiler_static_works_CXX" >&6; }
a8111142 13759
b686ecb5
JM
13760if test x"$lt_cv_prog_compiler_static_works_CXX" = xyes; then
13761 :
13762else
13763 lt_prog_compiler_static_CXX=
05ea2a05 13764fi
a8111142 13765
07697489 13766
b686ecb5
JM
13767
13768
13769 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
13770$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
13771if ${lt_cv_prog_compiler_c_o_CXX+:} false; then :
07697489
PA
13772 $as_echo_n "(cached) " >&6
13773else
b686ecb5
JM
13774 lt_cv_prog_compiler_c_o_CXX=no
13775 $RM -r conftest 2>/dev/null
13776 mkdir conftest
13777 cd conftest
13778 mkdir out
13779 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
13780
13781 lt_compiler_flag="-o out/conftest2.$ac_objext"
13782 # Insert the option either (1) after the last *FLAGS variable, or
13783 # (2) before a word containing "conftest.", or (3) at the end.
13784 # Note that $ac_compile itself does not contain backslashes and begins
13785 # with a dollar sign (not a hyphen), so the echo should work correctly.
13786 lt_compile=`echo "$ac_compile" | $SED \
13787 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
13788 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
13789 -e 's:$: $lt_compiler_flag:'`
13790 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
13791 (eval "$lt_compile" 2>out/conftest.err)
13792 ac_status=$?
13793 cat out/conftest.err >&5
13794 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13795 if (exit $ac_status) && test -s out/conftest2.$ac_objext
13796 then
13797 # The compiler can only warn and ignore the option if not recognized
13798 # So say no if there are warnings
13799 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
13800 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
13801 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
13802 lt_cv_prog_compiler_c_o_CXX=yes
13803 fi
13804 fi
13805 chmod u+w . 2>&5
13806 $RM conftest*
13807 # SGI C++ compiler will create directory out/ii_files/ for
13808 # template instantiation
13809 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
13810 $RM out/* && rmdir out
13811 cd ..
13812 $RM -r conftest
13813 $RM conftest*
07697489
PA
13814
13815fi
b686ecb5
JM
13816{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_CXX" >&5
13817$as_echo "$lt_cv_prog_compiler_c_o_CXX" >&6; }
07697489 13818
07697489
PA
13819
13820
b686ecb5
JM
13821 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
13822$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
13823if ${lt_cv_prog_compiler_c_o_CXX+:} false; then :
13824 $as_echo_n "(cached) " >&6
07697489 13825else
b686ecb5
JM
13826 lt_cv_prog_compiler_c_o_CXX=no
13827 $RM -r conftest 2>/dev/null
13828 mkdir conftest
13829 cd conftest
13830 mkdir out
13831 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
13832
13833 lt_compiler_flag="-o out/conftest2.$ac_objext"
13834 # Insert the option either (1) after the last *FLAGS variable, or
13835 # (2) before a word containing "conftest.", or (3) at the end.
13836 # Note that $ac_compile itself does not contain backslashes and begins
13837 # with a dollar sign (not a hyphen), so the echo should work correctly.
13838 lt_compile=`echo "$ac_compile" | $SED \
13839 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
13840 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
13841 -e 's:$: $lt_compiler_flag:'`
13842 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
13843 (eval "$lt_compile" 2>out/conftest.err)
13844 ac_status=$?
13845 cat out/conftest.err >&5
13846 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13847 if (exit $ac_status) && test -s out/conftest2.$ac_objext
13848 then
13849 # The compiler can only warn and ignore the option if not recognized
13850 # So say no if there are warnings
13851 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
13852 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
13853 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
13854 lt_cv_prog_compiler_c_o_CXX=yes
13855 fi
13856 fi
13857 chmod u+w . 2>&5
13858 $RM conftest*
13859 # SGI C++ compiler will create directory out/ii_files/ for
13860 # template instantiation
13861 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
13862 $RM out/* && rmdir out
13863 cd ..
13864 $RM -r conftest
13865 $RM conftest*
13866
13867fi
13868{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_CXX" >&5
13869$as_echo "$lt_cv_prog_compiler_c_o_CXX" >&6; }
13870
13871
13872
13873
13874hard_links="nottested"
13875if test "$lt_cv_prog_compiler_c_o_CXX" = no && test "$need_locks" != no; then
13876 # do not overwrite the value of need_locks provided by the user
13877 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5
13878$as_echo_n "checking if we can lock with hard links... " >&6; }
13879 hard_links=yes
13880 $RM conftest*
13881 ln conftest.a conftest.b 2>/dev/null && hard_links=no
13882 touch conftest.a
13883 ln conftest.a conftest.b 2>&5 || hard_links=no
13884 ln conftest.a conftest.b 2>/dev/null && hard_links=no
13885 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5
13886$as_echo "$hard_links" >&6; }
13887 if test "$hard_links" = no; then
13888 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
13889$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
13890 need_locks=warn
13891 fi
13892else
13893 need_locks=no
07697489
PA
13894fi
13895
07697489 13896
07697489 13897
b686ecb5
JM
13898 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
13899$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
07697489 13900
b686ecb5
JM
13901 export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
13902 case $host_os in
13903 aix[4-9]*)
13904 # If we're using GNU nm, then we don't want the "-C" option.
13905 # -C means demangle to AIX nm, but means don't demangle with GNU nm
13906 # Also, AIX nm treats weak defined symbols like other global defined
13907 # symbols, whereas GNU nm marks them as "W".
13908 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
13909 export_symbols_cmds_CXX='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
13910 else
13911 export_symbols_cmds_CXX='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
05ea2a05 13912 fi
b686ecb5
JM
13913 ;;
13914 pw32*)
13915 export_symbols_cmds_CXX="$ltdll_cmds"
13916 ;;
13917 cygwin* | mingw* | cegcc*)
13918 export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;/^.*[ ]__nm__/s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols'
13919 ;;
13920 *)
13921 export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
13922 ;;
13923 esac
13924 exclude_expsyms_CXX='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
07697489 13925
b686ecb5
JM
13926{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5
13927$as_echo "$ld_shlibs_CXX" >&6; }
13928test "$ld_shlibs_CXX" = no && can_build_shared=no
07697489 13929
b686ecb5 13930with_gnu_ld_CXX=$with_gnu_ld
05ea2a05 13931
07697489 13932
07697489 13933
07697489
PA
13934
13935
13936
b686ecb5
JM
13937#
13938# Do we need to explicitly link libc?
13939#
13940case "x$archive_cmds_need_lc_CXX" in
13941x|xyes)
13942 # Assume -lc should be added
13943 archive_cmds_need_lc_CXX=yes
13944
13945 if test "$enable_shared" = yes && test "$GCC" = yes; then
13946 case $archive_cmds_CXX in
13947 *'~'*)
13948 # FIXME: we may have to deal with multi-command sequences.
13949 ;;
13950 '$CC '*)
13951 # Test whether the compiler implicitly links with -lc since on some
13952 # systems, -lgcc has to come before -lc. If gcc already passes -lc
13953 # to ld, don't add -lc before -lgcc.
13954 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5
13955$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; }
13956if ${lt_cv_archive_cmds_need_lc_CXX+:} false; then :
13957 $as_echo_n "(cached) " >&6
13958else
13959 $RM conftest*
13960 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
81ecdfbb 13961
b686ecb5
JM
13962 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
13963 (eval $ac_compile) 2>&5
13964 ac_status=$?
13965 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
13966 test $ac_status = 0; } 2>conftest.err; then
13967 soname=conftest
13968 lib=conftest
13969 libobjs=conftest.$ac_objext
13970 deplibs=
13971 wl=$lt_prog_compiler_wl_CXX
13972 pic_flag=$lt_prog_compiler_pic_CXX
13973 compiler_flags=-v
13974 linker_flags=-v
13975 verstring=
13976 output_objdir=.
13977 libname=conftest
13978 lt_save_allow_undefined_flag=$allow_undefined_flag_CXX
13979 allow_undefined_flag_CXX=
13980 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds_CXX 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5
13981 (eval $archive_cmds_CXX 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5
13982 ac_status=$?
13983 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
13984 test $ac_status = 0; }
13985 then
13986 lt_cv_archive_cmds_need_lc_CXX=no
13987 else
13988 lt_cv_archive_cmds_need_lc_CXX=yes
13989 fi
13990 allow_undefined_flag_CXX=$lt_save_allow_undefined_flag
13991 else
13992 cat conftest.err 1>&5
13993 fi
13994 $RM conftest*
5ee754fc 13995
05ea2a05 13996fi
b686ecb5
JM
13997{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc_CXX" >&5
13998$as_echo "$lt_cv_archive_cmds_need_lc_CXX" >&6; }
13999 archive_cmds_need_lc_CXX=$lt_cv_archive_cmds_need_lc_CXX
14000 ;;
14001 esac
14002 fi
14003 ;;
14004esac
5ee754fc 14005
05ea2a05 14006
05ea2a05 14007
bec39cab 14008
81ecdfbb 14009
81ecdfbb
RW
14010
14011
81ecdfbb 14012
7eb368b3 14013
7eb368b3 14014
7eb368b3 14015
a9322a30 14016
7eb368b3 14017
7eb368b3
NR
14018
14019
a9322a30 14020
05ea2a05
TT
14021
14022
14023
14024
14025
14026
05ea2a05 14027
bec39cab 14028
a9322a30 14029
05ea2a05 14030
a9322a30 14031
a9322a30
TT
14032
14033
a9322a30 14034
db6878ac 14035
a9322a30 14036
d0ac1c44 14037
bec39cab 14038
bec39cab 14039
bec39cab 14040
05ea2a05 14041
05ea2a05 14042
a9322a30 14043
bec39cab 14044
5ee754fc 14045
bec39cab 14046
a9322a30 14047
a9322a30 14048
bec39cab 14049
81ecdfbb 14050
05ea2a05 14051
81ecdfbb 14052
05ea2a05 14053
7eb368b3 14054
05ea2a05 14055
05ea2a05 14056
81ecdfbb 14057
d3ea6809
MM
14058
14059
14060
d0ac1c44
SM
14061
14062
14063
05ea2a05 14064
05ea2a05 14065
05ea2a05 14066
05ea2a05 14067
05ea2a05 14068
b686ecb5
JM
14069 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5
14070$as_echo_n "checking dynamic linker characteristics... " >&6; }
05ea2a05 14071
b686ecb5
JM
14072library_names_spec=
14073libname_spec='lib$name'
14074soname_spec=
14075shrext_cmds=".so"
14076postinstall_cmds=
14077postuninstall_cmds=
14078finish_cmds=
14079finish_eval=
14080shlibpath_var=
14081shlibpath_overrides_runpath=unknown
14082version_type=none
14083dynamic_linker="$host_os ld.so"
14084sys_lib_dlsearch_path_spec="/lib /usr/lib"
14085need_lib_prefix=unknown
14086hardcode_into_libs=no
05ea2a05 14087
b686ecb5
JM
14088# when you set need_version to no, make sure it does not cause -set_version
14089# flags to be left without arguments
14090need_version=unknown
05ea2a05 14091
b686ecb5
JM
14092case $host_os in
14093aix3*)
14094 version_type=linux
14095 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
14096 shlibpath_var=LIBPATH
05ea2a05 14097
b686ecb5
JM
14098 # AIX 3 has no versioning support, so we append a major version to the name.
14099 soname_spec='${libname}${release}${shared_ext}$major'
14100 ;;
05ea2a05 14101
b686ecb5
JM
14102aix[4-9]*)
14103 version_type=linux
14104 need_lib_prefix=no
14105 need_version=no
14106 hardcode_into_libs=yes
14107 if test "$host_cpu" = ia64; then
14108 # AIX 5 supports IA64
14109 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
14110 shlibpath_var=LD_LIBRARY_PATH
14111 else
14112 # With GCC up to 2.95.x, collect2 would create an import file
14113 # for dependence libraries. The import file would start with
14114 # the line `#! .'. This would cause the generated library to
14115 # depend on `.', always an invalid library. This was fixed in
14116 # development snapshots of GCC prior to 3.0.
14117 case $host_os in
14118 aix4 | aix4.[01] | aix4.[01].*)
14119 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
14120 echo ' yes '
14121 echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
14122 :
14123 else
14124 can_build_shared=no
14125 fi
14126 ;;
14127 esac
14128 # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
14129 # soname into executable. Probably we can add versioning support to
14130 # collect2, so additional links can be useful in future.
14131 if test "$aix_use_runtimelinking" = yes; then
14132 # If using run time linking (on AIX 4.2 or later) use lib<name>.so
14133 # instead of lib<name>.a to let people know that these are not
14134 # typical AIX shared libraries.
14135 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
14136 else
14137 # We preserve .a as extension for shared libraries through AIX4.2
14138 # and later when we are not doing run time linking.
14139 library_names_spec='${libname}${release}.a $libname.a'
14140 soname_spec='${libname}${release}${shared_ext}$major'
14141 fi
14142 shlibpath_var=LIBPATH
14143 fi
14144 ;;
05ea2a05 14145
b686ecb5
JM
14146amigaos*)
14147 case $host_cpu in
14148 powerpc)
14149 # Since July 2007 AmigaOS4 officially supports .so libraries.
14150 # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
14151 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
14152 ;;
14153 m68k)
14154 library_names_spec='$libname.ixlibrary $libname.a'
14155 # Create ${libname}_ixlibrary.a entries in /sys/libs.
14156 finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
14157 ;;
14158 esac
14159 ;;
05ea2a05 14160
b686ecb5
JM
14161beos*)
14162 library_names_spec='${libname}${shared_ext}'
14163 dynamic_linker="$host_os ld.so"
14164 shlibpath_var=LIBRARY_PATH
14165 ;;
05ea2a05 14166
b686ecb5
JM
14167bsdi[45]*)
14168 version_type=linux
14169 need_version=no
14170 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
14171 soname_spec='${libname}${release}${shared_ext}$major'
14172 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
14173 shlibpath_var=LD_LIBRARY_PATH
14174 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
14175 sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
14176 # the default ld.so.conf also contains /usr/contrib/lib and
14177 # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
14178 # libtool to hard-code these into programs
14179 ;;
05ea2a05 14180
b686ecb5
JM
14181cygwin* | mingw* | pw32* | cegcc*)
14182 version_type=windows
14183 shrext_cmds=".dll"
14184 need_version=no
14185 need_lib_prefix=no
14186
14187 case $GCC,$host_os in
14188 yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*)
14189 library_names_spec='$libname.dll.a'
14190 # DLL is installed to $(libdir)/../bin by postinstall_cmds
14191 postinstall_cmds='base_file=`basename \${file}`~
14192 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
14193 dldir=$destdir/`dirname \$dlpath`~
14194 test -d \$dldir || mkdir -p \$dldir~
14195 $install_prog $dir/$dlname \$dldir/$dlname~
14196 chmod a+x \$dldir/$dlname~
14197 if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
14198 eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
14199 fi'
14200 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
14201 dlpath=$dir/\$dldll~
14202 $RM \$dlpath'
14203 shlibpath_overrides_runpath=yes
14204
14205 case $host_os in
14206 cygwin*)
14207 # Cygwin DLLs use 'cyg' prefix rather than 'lib'
14208 soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
14209
14210 ;;
14211 mingw* | cegcc*)
14212 # MinGW DLLs use traditional 'lib' prefix
14213 soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
05ea2a05 14214 ;;
b686ecb5
JM
14215 pw32*)
14216 # pw32 DLLs use 'pw' prefix rather than 'lib'
14217 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
14218 ;;
14219 esac
14220 ;;
14221
14222 *)
14223 library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
14224 ;;
05ea2a05 14225 esac
b686ecb5
JM
14226 dynamic_linker='Win32 ld.exe'
14227 # FIXME: first we should search . and the directory the executable is in
14228 shlibpath_var=PATH
14229 ;;
05ea2a05 14230
b686ecb5
JM
14231darwin* | rhapsody*)
14232 dynamic_linker="$host_os dyld"
14233 version_type=darwin
14234 need_lib_prefix=no
14235 need_version=no
14236 library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
14237 soname_spec='${libname}${release}${major}$shared_ext'
14238 shlibpath_overrides_runpath=yes
14239 shlibpath_var=DYLD_LIBRARY_PATH
14240 shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
14241
14242 sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
14243 ;;
05ea2a05 14244
b686ecb5
JM
14245dgux*)
14246 version_type=linux
14247 need_lib_prefix=no
14248 need_version=no
14249 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
14250 soname_spec='${libname}${release}${shared_ext}$major'
14251 shlibpath_var=LD_LIBRARY_PATH
14252 ;;
14253
14254freebsd* | dragonfly*)
14255 # DragonFly does not have aout. When/if they implement a new
14256 # versioning mechanism, adjust this.
14257 if test -x /usr/bin/objformat; then
14258 objformat=`/usr/bin/objformat`
14259 else
14260 case $host_os in
14261 freebsd[23].*) objformat=aout ;;
14262 *) objformat=elf ;;
14263 esac
14264 fi
14265 version_type=freebsd-$objformat
14266 case $version_type in
14267 freebsd-elf*)
14268 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
14269 need_version=no
14270 need_lib_prefix=no
14271 ;;
14272 freebsd-*)
14273 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
14274 need_version=yes
14275 ;;
14276 esac
14277 shlibpath_var=LD_LIBRARY_PATH
14278 case $host_os in
14279 freebsd2.*)
14280 shlibpath_overrides_runpath=yes
14281 ;;
14282 freebsd3.[01]* | freebsdelf3.[01]*)
14283 shlibpath_overrides_runpath=yes
14284 hardcode_into_libs=yes
14285 ;;
14286 freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
14287 freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
14288 shlibpath_overrides_runpath=no
14289 hardcode_into_libs=yes
14290 ;;
14291 *) # from 4.6 on, and DragonFly
14292 shlibpath_overrides_runpath=yes
14293 hardcode_into_libs=yes
14294 ;;
14295 esac
14296 ;;
14297
14298haiku*)
14299 version_type=linux
14300 need_lib_prefix=no
14301 need_version=no
14302 dynamic_linker="$host_os runtime_loader"
14303 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
14304 soname_spec='${libname}${release}${shared_ext}$major'
14305 shlibpath_var=LIBRARY_PATH
14306 shlibpath_overrides_runpath=yes
14307 sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
14308 hardcode_into_libs=yes
14309 ;;
14310
14311hpux9* | hpux10* | hpux11*)
14312 # Give a soname corresponding to the major version so that dld.sl refuses to
14313 # link against other versions.
14314 version_type=sunos
14315 need_lib_prefix=no
14316 need_version=no
14317 case $host_cpu in
14318 ia64*)
14319 shrext_cmds='.so'
14320 hardcode_into_libs=yes
14321 dynamic_linker="$host_os dld.so"
14322 shlibpath_var=LD_LIBRARY_PATH
14323 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
14324 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
14325 soname_spec='${libname}${release}${shared_ext}$major'
14326 if test "X$HPUX_IA64_MODE" = X32; then
14327 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
14328 else
14329 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
14330 fi
14331 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
14332 ;;
14333 hppa*64*)
14334 shrext_cmds='.sl'
14335 hardcode_into_libs=yes
14336 dynamic_linker="$host_os dld.sl"
14337 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
14338 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
14339 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
14340 soname_spec='${libname}${release}${shared_ext}$major'
14341 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
14342 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
14343 ;;
14344 *)
14345 shrext_cmds='.sl'
14346 dynamic_linker="$host_os dld.sl"
14347 shlibpath_var=SHLIB_PATH
14348 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
14349 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
14350 soname_spec='${libname}${release}${shared_ext}$major'
14351 ;;
14352 esac
14353 # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
14354 postinstall_cmds='chmod 555 $lib'
14355 # or fails outright, so override atomically:
14356 install_override_mode=555
14357 ;;
14358
14359interix[3-9]*)
14360 version_type=linux
14361 need_lib_prefix=no
14362 need_version=no
14363 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
14364 soname_spec='${libname}${release}${shared_ext}$major'
14365 dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
14366 shlibpath_var=LD_LIBRARY_PATH
14367 shlibpath_overrides_runpath=no
14368 hardcode_into_libs=yes
14369 ;;
14370
14371irix5* | irix6* | nonstopux*)
14372 case $host_os in
14373 nonstopux*) version_type=nonstopux ;;
14374 *)
14375 if test "$lt_cv_prog_gnu_ld" = yes; then
14376 version_type=linux
14377 else
14378 version_type=irix
14379 fi ;;
14380 esac
14381 need_lib_prefix=no
14382 need_version=no
14383 soname_spec='${libname}${release}${shared_ext}$major'
14384 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
14385 case $host_os in
14386 irix5* | nonstopux*)
14387 libsuff= shlibsuff=
14388 ;;
14389 *)
14390 case $LD in # libtool.m4 will add one of these switches to LD
14391 *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
14392 libsuff= shlibsuff= libmagic=32-bit;;
14393 *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
14394 libsuff=32 shlibsuff=N32 libmagic=N32;;
14395 *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
14396 libsuff=64 shlibsuff=64 libmagic=64-bit;;
14397 *) libsuff= shlibsuff= libmagic=never-match;;
14398 esac
14399 ;;
14400 esac
14401 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
14402 shlibpath_overrides_runpath=no
14403 sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
14404 sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
14405 hardcode_into_libs=yes
14406 ;;
14407
14408# No shared lib support for Linux oldld, aout, or coff.
14409linux*oldld* | linux*aout* | linux*coff*)
14410 dynamic_linker=no
14411 ;;
14412
14413# This must be Linux ELF.
14414linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
14415 version_type=linux
14416 need_lib_prefix=no
14417 need_version=no
14418 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
14419 soname_spec='${libname}${release}${shared_ext}$major'
14420 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
14421 shlibpath_var=LD_LIBRARY_PATH
14422 shlibpath_overrides_runpath=no
14423
14424 # Some binutils ld are patched to set DT_RUNPATH
14425 if ${lt_cv_shlibpath_overrides_runpath+:} false; then :
05ea2a05
TT
14426 $as_echo_n "(cached) " >&6
14427else
b686ecb5
JM
14428 lt_cv_shlibpath_overrides_runpath=no
14429 save_LDFLAGS=$LDFLAGS
14430 save_libdir=$libdir
14431 eval "libdir=/foo; wl=\"$lt_prog_compiler_wl_CXX\"; \
14432 LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec_CXX\""
14433 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
05ea2a05 14434/* end confdefs.h. */
b686ecb5 14435
05ea2a05
TT
14436int
14437main ()
14438{
b686ecb5 14439
05ea2a05
TT
14440 ;
14441 return 0;
14442}
14443_ACEOF
b686ecb5
JM
14444if ac_fn_cxx_try_link "$LINENO"; then :
14445 if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then :
14446 lt_cv_shlibpath_overrides_runpath=yes
14447fi
05ea2a05
TT
14448fi
14449rm -f core conftest.err conftest.$ac_objext \
14450 conftest$ac_exeext conftest.$ac_ext
b686ecb5
JM
14451 LDFLAGS=$save_LDFLAGS
14452 libdir=$save_libdir
05ea2a05
TT
14453
14454fi
05ea2a05 14455
b686ecb5
JM
14456 shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
14457
14458 # This implies no fast_install, which is unacceptable.
14459 # Some rework will be needed to allow for fast_install
14460 # before this can be enabled.
14461 hardcode_into_libs=yes
05ea2a05 14462
b686ecb5
JM
14463 # Append ld.so.conf contents to the search path
14464 if test -f /etc/ld.so.conf; then
14465 lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
14466 sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
05ea2a05
TT
14467 fi
14468
b686ecb5
JM
14469 # We used to test for /lib/ld.so.1 and disable shared libraries on
14470 # powerpc, because MkLinux only supported shared libraries with the
14471 # GNU dynamic linker. Since this was broken with cross compilers,
14472 # most powerpc-linux boxes support dynamic linking these days and
14473 # people can always --disable-shared, the test was removed, and we
14474 # assume the GNU/Linux dynamic linker is in use.
14475 dynamic_linker='GNU/Linux ld.so'
14476 ;;
05ea2a05 14477
b686ecb5
JM
14478netbsd*)
14479 version_type=sunos
14480 need_lib_prefix=no
14481 need_version=no
14482 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
14483 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
14484 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
14485 dynamic_linker='NetBSD (a.out) ld.so'
14486 else
14487 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
14488 soname_spec='${libname}${release}${shared_ext}$major'
14489 dynamic_linker='NetBSD ld.elf_so'
14490 fi
14491 shlibpath_var=LD_LIBRARY_PATH
14492 shlibpath_overrides_runpath=yes
14493 hardcode_into_libs=yes
14494 ;;
b757528f 14495
b686ecb5
JM
14496newsos6)
14497 version_type=linux
14498 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
14499 shlibpath_var=LD_LIBRARY_PATH
14500 shlibpath_overrides_runpath=yes
14501 ;;
bec39cab 14502
b686ecb5
JM
14503*nto* | *qnx*)
14504 version_type=qnx
14505 need_lib_prefix=no
14506 need_version=no
14507 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
14508 soname_spec='${libname}${release}${shared_ext}$major'
14509 shlibpath_var=LD_LIBRARY_PATH
14510 shlibpath_overrides_runpath=no
14511 hardcode_into_libs=yes
14512 dynamic_linker='ldqnx.so'
14513 ;;
a3828db0 14514
b686ecb5
JM
14515openbsd*)
14516 version_type=sunos
14517 sys_lib_dlsearch_path_spec="/usr/lib"
14518 need_lib_prefix=no
14519 # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
14520 case $host_os in
14521 openbsd3.3 | openbsd3.3.*) need_version=yes ;;
14522 *) need_version=no ;;
14523 esac
14524 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
14525 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
14526 shlibpath_var=LD_LIBRARY_PATH
14527 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
14528 case $host_os in
14529 openbsd2.[89] | openbsd2.[89].*)
14530 shlibpath_overrides_runpath=no
14531 ;;
14532 *)
14533 shlibpath_overrides_runpath=yes
14534 ;;
14535 esac
14536 else
14537 shlibpath_overrides_runpath=yes
14538 fi
14539 ;;
d0ac1c44 14540
b686ecb5
JM
14541os2*)
14542 libname_spec='$name'
14543 shrext_cmds=".dll"
14544 need_lib_prefix=no
14545 library_names_spec='$libname${shared_ext} $libname.a'
14546 dynamic_linker='OS/2 ld.exe'
14547 shlibpath_var=LIBPATH
14548 ;;
d0ac1c44 14549
b686ecb5
JM
14550osf3* | osf4* | osf5*)
14551 version_type=osf
14552 need_lib_prefix=no
14553 need_version=no
14554 soname_spec='${libname}${release}${shared_ext}$major'
14555 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
14556 shlibpath_var=LD_LIBRARY_PATH
14557 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
14558 sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
14559 ;;
bcb3dc3d 14560
b686ecb5
JM
14561rdos*)
14562 dynamic_linker=no
14563 ;;
bcb3dc3d 14564
b686ecb5
JM
14565solaris*)
14566 version_type=linux
14567 need_lib_prefix=no
14568 need_version=no
14569 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
14570 soname_spec='${libname}${release}${shared_ext}$major'
14571 shlibpath_var=LD_LIBRARY_PATH
14572 shlibpath_overrides_runpath=yes
14573 hardcode_into_libs=yes
14574 # ldd complains unless libraries are executable
14575 postinstall_cmds='chmod +x $lib'
14576 ;;
bec39cab 14577
b686ecb5
JM
14578sunos4*)
14579 version_type=sunos
14580 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
14581 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
14582 shlibpath_var=LD_LIBRARY_PATH
14583 shlibpath_overrides_runpath=yes
14584 if test "$with_gnu_ld" = yes; then
14585 need_lib_prefix=no
14586 fi
14587 need_version=yes
14588 ;;
bec39cab 14589
b686ecb5
JM
14590sysv4 | sysv4.3*)
14591 version_type=linux
14592 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
14593 soname_spec='${libname}${release}${shared_ext}$major'
14594 shlibpath_var=LD_LIBRARY_PATH
14595 case $host_vendor in
14596 sni)
14597 shlibpath_overrides_runpath=no
14598 need_lib_prefix=no
14599 runpath_var=LD_RUN_PATH
14600 ;;
14601 siemens)
14602 need_lib_prefix=no
14603 ;;
14604 motorola)
14605 need_lib_prefix=no
14606 need_version=no
14607 shlibpath_overrides_runpath=no
14608 sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
14609 ;;
14610 esac
14611 ;;
8b9cf735 14612
b686ecb5
JM
14613sysv4*MP*)
14614 if test -d /usr/nec ;then
14615 version_type=linux
14616 library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
14617 soname_spec='$libname${shared_ext}.$major'
14618 shlibpath_var=LD_LIBRARY_PATH
14619 fi
14620 ;;
8b9cf735 14621
b686ecb5
JM
14622sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
14623 version_type=freebsd-elf
14624 need_lib_prefix=no
14625 need_version=no
14626 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
14627 soname_spec='${libname}${release}${shared_ext}$major'
14628 shlibpath_var=LD_LIBRARY_PATH
14629 shlibpath_overrides_runpath=yes
14630 hardcode_into_libs=yes
14631 if test "$with_gnu_ld" = yes; then
14632 sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
14633 else
14634 sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
14635 case $host_os in
14636 sco3.2v5*)
14637 sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
14638 ;;
14639 esac
14640 fi
14641 sys_lib_dlsearch_path_spec='/usr/lib'
14642 ;;
a3828db0 14643
b686ecb5
JM
14644tpf*)
14645 # TPF is a cross-target only. Preferred cross-host = GNU/Linux.
14646 version_type=linux
14647 need_lib_prefix=no
14648 need_version=no
14649 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
14650 shlibpath_var=LD_LIBRARY_PATH
14651 shlibpath_overrides_runpath=no
14652 hardcode_into_libs=yes
14653 ;;
a9322a30 14654
b686ecb5
JM
14655uts4*)
14656 version_type=linux
14657 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
14658 soname_spec='${libname}${release}${shared_ext}$major'
14659 shlibpath_var=LD_LIBRARY_PATH
14660 ;;
a9322a30 14661
b686ecb5
JM
14662*)
14663 dynamic_linker=no
14664 ;;
14665esac
14666{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5
14667$as_echo "$dynamic_linker" >&6; }
14668test "$dynamic_linker" = no && can_build_shared=no
a9322a30 14669
b686ecb5
JM
14670variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
14671if test "$GCC" = yes; then
14672 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
14673fi
a9322a30 14674
b686ecb5
JM
14675if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
14676 sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
14677fi
14678if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
14679 sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
14680fi
a9322a30 14681
d0ac1c44 14682
a9322a30 14683
b686ecb5
JM
14684
14685
14686
14687
14688
14689
14690
14691
14692
14693
14694
14695
14696
14697
14698
14699
14700
14701
14702
14703
14704
14705
14706
14707
14708
14709
14710
14711
14712
14713
14714
14715
14716
14717
14718
14719 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5
14720$as_echo_n "checking how to hardcode library paths into programs... " >&6; }
14721hardcode_action_CXX=
14722if test -n "$hardcode_libdir_flag_spec_CXX" ||
14723 test -n "$runpath_var_CXX" ||
14724 test "X$hardcode_automatic_CXX" = "Xyes" ; then
14725
14726 # We can hardcode non-existent directories.
14727 if test "$hardcode_direct_CXX" != no &&
14728 # If the only mechanism to avoid hardcoding is shlibpath_var, we
14729 # have to relink, otherwise we might link with an installed library
14730 # when we should be linking with a yet-to-be-installed one
14731 ## test "$_LT_TAGVAR(hardcode_shlibpath_var, CXX)" != no &&
14732 test "$hardcode_minus_L_CXX" != no; then
14733 # Linking always hardcodes the temporary library directory.
14734 hardcode_action_CXX=relink
14735 else
14736 # We can link without hardcoding, and we can hardcode nonexisting dirs.
14737 hardcode_action_CXX=immediate
14738 fi
086ec9eb 14739else
b686ecb5
JM
14740 # We cannot hardcode anything, or else we can only hardcode existing
14741 # directories.
14742 hardcode_action_CXX=unsupported
a3828db0 14743fi
b686ecb5
JM
14744{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action_CXX" >&5
14745$as_echo "$hardcode_action_CXX" >&6; }
81ecdfbb 14746
b686ecb5
JM
14747if test "$hardcode_action_CXX" = relink ||
14748 test "$inherit_rpath_CXX" = yes; then
14749 # Fast installation is not supported
14750 enable_fast_install=no
14751elif test "$shlibpath_overrides_runpath" = yes ||
14752 test "$enable_shared" = no; then
14753 # Fast installation is not necessary
14754 enable_fast_install=needless
a9322a30 14755fi
a9322a30 14756
a3828db0 14757
a3828db0 14758
c906108c 14759
a9322a30 14760
c906108c 14761
b83266a0 14762
b686ecb5 14763 fi # test -n "$compiler"
b83266a0 14764
b686ecb5
JM
14765 CC=$lt_save_CC
14766 LDCXX=$LD
14767 LD=$lt_save_LD
14768 GCC=$lt_save_GCC
14769 with_gnu_ld=$lt_save_with_gnu_ld
14770 lt_cv_path_LDCXX=$lt_cv_path_LD
14771 lt_cv_path_LD=$lt_save_path_LD
14772 lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
14773 lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
14774fi # test "$_lt_caught_CXX_error" != yes
14775
14776ac_ext=c
14777ac_cpp='$CPP $CPPFLAGS'
14778ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
14779ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
14780ac_compiler_gnu=$ac_cv_c_compiler_gnu
14781
14782
14783
14784
14785
14786
14787
14788
14789
14790
14791
14792
14793
14794 ac_config_commands="$ac_config_commands libtool"
14795
14796
14797
14798
14799# Only expand once:
14800
14801
5218fa9e
JM
14802# ... and we need it soon, since it is used by some of the
14803# link tests in the configure script.
14804: ${CONFIG_LT=./config.lt}
14805{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_LT" >&5
14806$as_echo "$as_me: creating $CONFIG_LT" >&6;}
14807as_write_fail=0
14808cat >"$CONFIG_LT" <<_ASEOF || as_write_fail=1
14809#! $SHELL
14810# Generated by $as_me.
14811# Run this file to recreate a libtool stub with the current configuration.
14812SHELL=\${CONFIG_SHELL-$SHELL}
14813export SHELL
14814_ASEOF
14815cat >>"$CONFIG_LT" <<\_ASEOF || as_write_fail=1
14816## -------------------- ##
14817## M4sh Initialization. ##
14818## -------------------- ##
14819
14820# Be more Bourne compatible
14821DUALCASE=1; export DUALCASE # for MKS sh
14822if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
14823 emulate sh
14824 NULLCMD=:
14825 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
14826 # is contrary to our usage. Disable this feature.
14827 alias -g '${1+"$@"}'='"$@"'
14828 setopt NO_GLOB_SUBST
14829else
14830 case `(set -o) 2>/dev/null` in #(
14831 *posix*) :
14832 set -o posix ;; #(
14833 *) :
14834 ;;
14835esac
14836fi
14837
14838
14839as_nl='
14840'
14841export as_nl
14842# Printing a long string crashes Solaris 7 /usr/bin/printf.
14843as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
14844as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
14845as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
14846# Prefer a ksh shell builtin over an external printf program on Solaris,
14847# but without wasting forks for bash or zsh.
14848if test -z "$BASH_VERSION$ZSH_VERSION" \
14849 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
14850 as_echo='print -r --'
14851 as_echo_n='print -rn --'
14852elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
14853 as_echo='printf %s\n'
14854 as_echo_n='printf %s'
14855else
14856 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
14857 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
14858 as_echo_n='/usr/ucb/echo -n'
14859 else
14860 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
14861 as_echo_n_body='eval
14862 arg=$1;
14863 case $arg in #(
14864 *"$as_nl"*)
14865 expr "X$arg" : "X\\(.*\\)$as_nl";
14866 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
14867 esac;
14868 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
14869 '
14870 export as_echo_n_body
14871 as_echo_n='sh -c $as_echo_n_body as_echo'
14872 fi
14873 export as_echo_body
14874 as_echo='sh -c $as_echo_body as_echo'
14875fi
14876
14877# The user is always right.
14878if test "${PATH_SEPARATOR+set}" != set; then
14879 PATH_SEPARATOR=:
14880 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
14881 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
14882 PATH_SEPARATOR=';'
14883 }
14884fi
14885
14886
14887# IFS
14888# We need space, tab and new line, in precisely that order. Quoting is
14889# there to prevent editors from complaining about space-tab.
14890# (If _AS_PATH_WALK were called with IFS unset, it would disable word
14891# splitting by setting IFS to empty value.)
14892IFS=" "" $as_nl"
14893
14894# Find who we are. Look in the path if we contain no directory separator.
14895as_myself=
14896case $0 in #((
14897 *[\\/]* ) as_myself=$0 ;;
14898 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14899for as_dir in $PATH
14900do
14901 IFS=$as_save_IFS
14902 test -z "$as_dir" && as_dir=.
14903 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
14904 done
14905IFS=$as_save_IFS
14906
14907 ;;
14908esac
14909# We did not find ourselves, most probably we were run as `sh COMMAND'
14910# in which case we are not to be found in the path.
14911if test "x$as_myself" = x; then
14912 as_myself=$0
14913fi
14914if test ! -f "$as_myself"; then
14915 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
14916 exit 1
14917fi
14918
14919# Unset variables that we do not need and which cause bugs (e.g. in
14920# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
14921# suppresses any "Segmentation fault" message there. '((' could
14922# trigger a bug in pdksh 5.2.14.
14923for as_var in BASH_ENV ENV MAIL MAILPATH
14924do eval test x\${$as_var+set} = xset \
14925 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
14926done
14927PS1='$ '
14928PS2='> '
14929PS4='+ '
14930
14931# NLS nuisances.
14932LC_ALL=C
14933export LC_ALL
14934LANGUAGE=C
14935export LANGUAGE
14936
14937# CDPATH.
14938(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
14939
14940
14941# as_fn_error STATUS ERROR [LINENO LOG_FD]
14942# ----------------------------------------
14943# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
14944# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
14945# script with STATUS, using 1 if that was 0.
14946as_fn_error ()
14947{
14948 as_status=$1; test $as_status -eq 0 && as_status=1
14949 if test "$4"; then
14950 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
14951 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
14952 fi
14953 $as_echo "$as_me: error: $2" >&2
14954 as_fn_exit $as_status
14955} # as_fn_error
14956
14957
14958# as_fn_set_status STATUS
14959# -----------------------
14960# Set $? to STATUS, without forking.
14961as_fn_set_status ()
14962{
14963 return $1
14964} # as_fn_set_status
14965
14966# as_fn_exit STATUS
14967# -----------------
14968# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
14969as_fn_exit ()
14970{
14971 set +e
14972 as_fn_set_status $1
14973 exit $1
14974} # as_fn_exit
14975
14976# as_fn_unset VAR
14977# ---------------
14978# Portably unset VAR.
14979as_fn_unset ()
14980{
14981 { eval $1=; unset $1;}
14982}
14983as_unset=as_fn_unset
14984# as_fn_append VAR VALUE
14985# ----------------------
14986# Append the text in VALUE to the end of the definition contained in VAR. Take
14987# advantage of any shell optimizations that allow amortized linear growth over
14988# repeated appends, instead of the typical quadratic growth present in naive
14989# implementations.
14990if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
14991 eval 'as_fn_append ()
14992 {
14993 eval $1+=\$2
14994 }'
14995else
14996 as_fn_append ()
14997 {
14998 eval $1=\$$1\$2
14999 }
15000fi # as_fn_append
15001
15002# as_fn_arith ARG...
15003# ------------------
15004# Perform arithmetic evaluation on the ARGs, and store the result in the
15005# global $as_val. Take advantage of shells that can avoid forks. The arguments
15006# must be portable across $(()) and expr.
15007if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
15008 eval 'as_fn_arith ()
15009 {
15010 as_val=$(( $* ))
15011 }'
15012else
15013 as_fn_arith ()
15014 {
15015 as_val=`expr "$@" || test $? -eq 1`
15016 }
15017fi # as_fn_arith
15018
15019
15020if expr a : '\(a\)' >/dev/null 2>&1 &&
15021 test "X`expr 00001 : '.*\(...\)'`" = X001; then
15022 as_expr=expr
15023else
15024 as_expr=false
15025fi
15026
15027if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
15028 as_basename=basename
15029else
15030 as_basename=false
15031fi
15032
15033if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
15034 as_dirname=dirname
15035else
15036 as_dirname=false
15037fi
15038
15039as_me=`$as_basename -- "$0" ||
15040$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
15041 X"$0" : 'X\(//\)$' \| \
15042 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
15043$as_echo X/"$0" |
15044 sed '/^.*\/\([^/][^/]*\)\/*$/{
15045 s//\1/
15046 q
15047 }
15048 /^X\/\(\/\/\)$/{
15049 s//\1/
15050 q
15051 }
15052 /^X\/\(\/\).*/{
15053 s//\1/
15054 q
15055 }
15056 s/.*/./; q'`
15057
15058# Avoid depending upon Character Ranges.
15059as_cr_letters='abcdefghijklmnopqrstuvwxyz'
15060as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
15061as_cr_Letters=$as_cr_letters$as_cr_LETTERS
15062as_cr_digits='0123456789'
15063as_cr_alnum=$as_cr_Letters$as_cr_digits
15064
15065ECHO_C= ECHO_N= ECHO_T=
15066case `echo -n x` in #(((((
15067-n*)
15068 case `echo 'xy\c'` in
15069 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
15070 xy) ECHO_C='\c';;
15071 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
15072 ECHO_T=' ';;
15073 esac;;
15074*)
15075 ECHO_N='-n';;
15076esac
15077
15078rm -f conf$$ conf$$.exe conf$$.file
15079if test -d conf$$.dir; then
15080 rm -f conf$$.dir/conf$$.file
15081else
15082 rm -f conf$$.dir
15083 mkdir conf$$.dir 2>/dev/null
15084fi
15085if (echo >conf$$.file) 2>/dev/null; then
15086 if ln -s conf$$.file conf$$ 2>/dev/null; then
15087 as_ln_s='ln -s'
15088 # ... but there are two gotchas:
15089 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
15090 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
15091 # In both cases, we have to default to `cp -pR'.
15092 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
15093 as_ln_s='cp -pR'
15094 elif ln conf$$.file conf$$ 2>/dev/null; then
15095 as_ln_s=ln
15096 else
15097 as_ln_s='cp -pR'
15098 fi
15099else
15100 as_ln_s='cp -pR'
15101fi
15102rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
15103rmdir conf$$.dir 2>/dev/null
15104
15105
15106# as_fn_mkdir_p
15107# -------------
15108# Create "$as_dir" as a directory, including parents if necessary.
15109as_fn_mkdir_p ()
15110{
15111
15112 case $as_dir in #(
15113 -*) as_dir=./$as_dir;;
15114 esac
15115 test -d "$as_dir" || eval $as_mkdir_p || {
15116 as_dirs=
15117 while :; do
15118 case $as_dir in #(
15119 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
15120 *) as_qdir=$as_dir;;
15121 esac
15122 as_dirs="'$as_qdir' $as_dirs"
15123 as_dir=`$as_dirname -- "$as_dir" ||
15124$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
15125 X"$as_dir" : 'X\(//\)[^/]' \| \
15126 X"$as_dir" : 'X\(//\)$' \| \
15127 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
15128$as_echo X"$as_dir" |
15129 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
15130 s//\1/
15131 q
15132 }
15133 /^X\(\/\/\)[^/].*/{
15134 s//\1/
15135 q
15136 }
15137 /^X\(\/\/\)$/{
15138 s//\1/
15139 q
15140 }
15141 /^X\(\/\).*/{
15142 s//\1/
15143 q
15144 }
15145 s/.*/./; q'`
15146 test -d "$as_dir" && break
15147 done
15148 test -z "$as_dirs" || eval "mkdir $as_dirs"
15149 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
15150
15151
15152} # as_fn_mkdir_p
15153if mkdir -p . 2>/dev/null; then
15154 as_mkdir_p='mkdir -p "$as_dir"'
15155else
15156 test -d ./-p && rmdir ./-p
15157 as_mkdir_p=false
15158fi
15159
15160
15161# as_fn_executable_p FILE
15162# -----------------------
15163# Test if FILE is an executable regular file.
15164as_fn_executable_p ()
15165{
15166 test -f "$1" && test -x "$1"
15167} # as_fn_executable_p
15168as_test_x='test -x'
15169as_executable_p=as_fn_executable_p
15170
15171# Sed expression to map a string onto a valid CPP name.
15172as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
15173
15174# Sed expression to map a string onto a valid variable name.
15175as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
15176
15177
15178exec 6>&1
15179## --------------------------------- ##
15180## Main body of "$CONFIG_LT" script. ##
15181## --------------------------------- ##
15182_ASEOF
15183test $as_write_fail = 0 && chmod +x "$CONFIG_LT"
15184
15185cat >>"$CONFIG_LT" <<\_LTEOF
15186lt_cl_silent=false
15187exec 5>>config.log
15188{
15189 echo
15190 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
15191## Running $as_me. ##
15192_ASBOX
15193} >&5
15194
15195lt_cl_help="\
15196\`$as_me' creates a local libtool stub from the current configuration,
15197for use in further configure time tests before the real libtool is
15198generated.
15199
15200Usage: $0 [OPTIONS]
15201
15202 -h, --help print this help, then exit
15203 -V, --version print version number, then exit
15204 -q, --quiet do not print progress messages
15205 -d, --debug don't remove temporary files
15206
15207Report bugs to <bug-libtool@gnu.org>."
15208
15209lt_cl_version="\
15210config.lt
15211configured by $0, generated by GNU Autoconf 2.69.
15212
15213Copyright (C) 2009 Free Software Foundation, Inc.
15214This config.lt script is free software; the Free Software Foundation
15215gives unlimited permision to copy, distribute and modify it."
15216
15217while test $# != 0
15218do
15219 case $1 in
15220 --version | --v* | -V )
15221 echo "$lt_cl_version"; exit 0 ;;
15222 --help | --h* | -h )
15223 echo "$lt_cl_help"; exit 0 ;;
15224 --debug | --d* | -d )
15225 debug=: ;;
15226 --quiet | --q* | --silent | --s* | -q )
15227 lt_cl_silent=: ;;
15228
15229 -*) as_fn_error $? "unrecognized option: $1
15230Try \`$0 --help' for more information." "$LINENO" 5 ;;
15231
15232 *) as_fn_error $? "unrecognized argument: $1
15233Try \`$0 --help' for more information." "$LINENO" 5 ;;
15234 esac
15235 shift
15236done
15237
15238if $lt_cl_silent; then
15239 exec 6>/dev/null
15240fi
15241_LTEOF
15242
15243cat >>"$CONFIG_LT" <<_LTEOF
15244
15245
15246# The HP-UX ksh and POSIX shell print the target directory to stdout
15247# if CDPATH is set.
15248(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
15249
15250sed_quote_subst='$sed_quote_subst'
15251double_quote_subst='$double_quote_subst'
15252delay_variable_subst='$delay_variable_subst'
15253macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`'
15254macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`'
15255enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`'
15256enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`'
15257pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`'
15258enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`'
15259SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`'
15260ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`'
15261host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`'
15262host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`'
15263host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`'
15264build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`'
15265build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`'
15266build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`'
15267SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`'
15268Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`'
15269GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`'
15270EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`'
15271FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`'
15272LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`'
15273NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`'
15274LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`'
15275max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`'
15276ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`'
15277exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
15278lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
15279lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
15280lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
15281reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`'
15282reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`'
15283OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`'
15284deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`'
15285file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`'
15286AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`'
15287AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`'
15288STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
15289RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
15290old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
15291old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
15292old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`'
15293lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`'
15294CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`'
15295CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`'
15296compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`'
15297GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`'
15298lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`'
15299lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
15300lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
15301lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
15302objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`'
15303MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`'
15304lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`'
15305lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
15306lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`'
15307lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`'
15308lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`'
15309need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`'
15310DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
15311NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
15312LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
15313OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`'
15314OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`'
15315libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`'
15316shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`'
15317extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
15318archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`'
15319enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`'
15320export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`'
15321whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`'
15322compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`'
15323old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`'
15324old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
15325archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`'
15326archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`'
15327module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`'
15328module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`'
15329with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`'
15330allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`'
15331no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`'
15332hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`'
15333hardcode_libdir_flag_spec_ld='`$ECHO "$hardcode_libdir_flag_spec_ld" | $SED "$delay_single_quote_subst"`'
15334hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`'
15335hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`'
15336hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`'
15337hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`'
15338hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`'
15339hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
15340inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
15341link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
15342fix_srcfile_path='`$ECHO "$fix_srcfile_path" | $SED "$delay_single_quote_subst"`'
15343always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`'
15344export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`'
15345exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`'
15346include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`'
15347prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`'
15348file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
15349variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
15350need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
15351need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`'
15352version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`'
15353runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`'
15354shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`'
15355shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`'
15356libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`'
15357library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`'
15358soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`'
15359install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`'
15360postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`'
15361postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
15362finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`'
15363finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`'
15364hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`'
15365sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`'
15366sys_lib_dlsearch_path_spec='`$ECHO "$sys_lib_dlsearch_path_spec" | $SED "$delay_single_quote_subst"`'
15367hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`'
15368enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`'
15369enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`'
15370enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`'
15371old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`'
15372striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`'
15373compiler_lib_search_dirs='`$ECHO "$compiler_lib_search_dirs" | $SED "$delay_single_quote_subst"`'
15374predep_objects='`$ECHO "$predep_objects" | $SED "$delay_single_quote_subst"`'
15375postdep_objects='`$ECHO "$postdep_objects" | $SED "$delay_single_quote_subst"`'
15376predeps='`$ECHO "$predeps" | $SED "$delay_single_quote_subst"`'
15377postdeps='`$ECHO "$postdeps" | $SED "$delay_single_quote_subst"`'
15378compiler_lib_search_path='`$ECHO "$compiler_lib_search_path" | $SED "$delay_single_quote_subst"`'
15379LD_CXX='`$ECHO "$LD_CXX" | $SED "$delay_single_quote_subst"`'
15380reload_flag_CXX='`$ECHO "$reload_flag_CXX" | $SED "$delay_single_quote_subst"`'
15381reload_cmds_CXX='`$ECHO "$reload_cmds_CXX" | $SED "$delay_single_quote_subst"`'
15382old_archive_cmds_CXX='`$ECHO "$old_archive_cmds_CXX" | $SED "$delay_single_quote_subst"`'
15383compiler_CXX='`$ECHO "$compiler_CXX" | $SED "$delay_single_quote_subst"`'
15384GCC_CXX='`$ECHO "$GCC_CXX" | $SED "$delay_single_quote_subst"`'
15385lt_prog_compiler_no_builtin_flag_CXX='`$ECHO "$lt_prog_compiler_no_builtin_flag_CXX" | $SED "$delay_single_quote_subst"`'
15386lt_prog_compiler_wl_CXX='`$ECHO "$lt_prog_compiler_wl_CXX" | $SED "$delay_single_quote_subst"`'
15387lt_prog_compiler_pic_CXX='`$ECHO "$lt_prog_compiler_pic_CXX" | $SED "$delay_single_quote_subst"`'
15388lt_prog_compiler_static_CXX='`$ECHO "$lt_prog_compiler_static_CXX" | $SED "$delay_single_quote_subst"`'
15389lt_cv_prog_compiler_c_o_CXX='`$ECHO "$lt_cv_prog_compiler_c_o_CXX" | $SED "$delay_single_quote_subst"`'
15390archive_cmds_need_lc_CXX='`$ECHO "$archive_cmds_need_lc_CXX" | $SED "$delay_single_quote_subst"`'
15391enable_shared_with_static_runtimes_CXX='`$ECHO "$enable_shared_with_static_runtimes_CXX" | $SED "$delay_single_quote_subst"`'
15392export_dynamic_flag_spec_CXX='`$ECHO "$export_dynamic_flag_spec_CXX" | $SED "$delay_single_quote_subst"`'
15393whole_archive_flag_spec_CXX='`$ECHO "$whole_archive_flag_spec_CXX" | $SED "$delay_single_quote_subst"`'
15394compiler_needs_object_CXX='`$ECHO "$compiler_needs_object_CXX" | $SED "$delay_single_quote_subst"`'
15395old_archive_from_new_cmds_CXX='`$ECHO "$old_archive_from_new_cmds_CXX" | $SED "$delay_single_quote_subst"`'
15396old_archive_from_expsyms_cmds_CXX='`$ECHO "$old_archive_from_expsyms_cmds_CXX" | $SED "$delay_single_quote_subst"`'
15397archive_cmds_CXX='`$ECHO "$archive_cmds_CXX" | $SED "$delay_single_quote_subst"`'
15398archive_expsym_cmds_CXX='`$ECHO "$archive_expsym_cmds_CXX" | $SED "$delay_single_quote_subst"`'
15399module_cmds_CXX='`$ECHO "$module_cmds_CXX" | $SED "$delay_single_quote_subst"`'
15400module_expsym_cmds_CXX='`$ECHO "$module_expsym_cmds_CXX" | $SED "$delay_single_quote_subst"`'
15401with_gnu_ld_CXX='`$ECHO "$with_gnu_ld_CXX" | $SED "$delay_single_quote_subst"`'
15402allow_undefined_flag_CXX='`$ECHO "$allow_undefined_flag_CXX" | $SED "$delay_single_quote_subst"`'
15403no_undefined_flag_CXX='`$ECHO "$no_undefined_flag_CXX" | $SED "$delay_single_quote_subst"`'
15404hardcode_libdir_flag_spec_CXX='`$ECHO "$hardcode_libdir_flag_spec_CXX" | $SED "$delay_single_quote_subst"`'
15405hardcode_libdir_flag_spec_ld_CXX='`$ECHO "$hardcode_libdir_flag_spec_ld_CXX" | $SED "$delay_single_quote_subst"`'
15406hardcode_libdir_separator_CXX='`$ECHO "$hardcode_libdir_separator_CXX" | $SED "$delay_single_quote_subst"`'
15407hardcode_direct_CXX='`$ECHO "$hardcode_direct_CXX" | $SED "$delay_single_quote_subst"`'
15408hardcode_direct_absolute_CXX='`$ECHO "$hardcode_direct_absolute_CXX" | $SED "$delay_single_quote_subst"`'
15409hardcode_minus_L_CXX='`$ECHO "$hardcode_minus_L_CXX" | $SED "$delay_single_quote_subst"`'
15410hardcode_shlibpath_var_CXX='`$ECHO "$hardcode_shlibpath_var_CXX" | $SED "$delay_single_quote_subst"`'
15411hardcode_automatic_CXX='`$ECHO "$hardcode_automatic_CXX" | $SED "$delay_single_quote_subst"`'
15412inherit_rpath_CXX='`$ECHO "$inherit_rpath_CXX" | $SED "$delay_single_quote_subst"`'
15413link_all_deplibs_CXX='`$ECHO "$link_all_deplibs_CXX" | $SED "$delay_single_quote_subst"`'
15414fix_srcfile_path_CXX='`$ECHO "$fix_srcfile_path_CXX" | $SED "$delay_single_quote_subst"`'
15415always_export_symbols_CXX='`$ECHO "$always_export_symbols_CXX" | $SED "$delay_single_quote_subst"`'
15416export_symbols_cmds_CXX='`$ECHO "$export_symbols_cmds_CXX" | $SED "$delay_single_quote_subst"`'
15417exclude_expsyms_CXX='`$ECHO "$exclude_expsyms_CXX" | $SED "$delay_single_quote_subst"`'
15418include_expsyms_CXX='`$ECHO "$include_expsyms_CXX" | $SED "$delay_single_quote_subst"`'
15419prelink_cmds_CXX='`$ECHO "$prelink_cmds_CXX" | $SED "$delay_single_quote_subst"`'
15420file_list_spec_CXX='`$ECHO "$file_list_spec_CXX" | $SED "$delay_single_quote_subst"`'
15421hardcode_action_CXX='`$ECHO "$hardcode_action_CXX" | $SED "$delay_single_quote_subst"`'
15422compiler_lib_search_dirs_CXX='`$ECHO "$compiler_lib_search_dirs_CXX" | $SED "$delay_single_quote_subst"`'
15423predep_objects_CXX='`$ECHO "$predep_objects_CXX" | $SED "$delay_single_quote_subst"`'
15424postdep_objects_CXX='`$ECHO "$postdep_objects_CXX" | $SED "$delay_single_quote_subst"`'
15425predeps_CXX='`$ECHO "$predeps_CXX" | $SED "$delay_single_quote_subst"`'
15426postdeps_CXX='`$ECHO "$postdeps_CXX" | $SED "$delay_single_quote_subst"`'
15427compiler_lib_search_path_CXX='`$ECHO "$compiler_lib_search_path_CXX" | $SED "$delay_single_quote_subst"`'
15428
15429LTCC='$LTCC'
15430LTCFLAGS='$LTCFLAGS'
15431compiler='$compiler_DEFAULT'
15432
15433# A function that is used when there is no print builtin or printf.
15434func_fallback_echo ()
15435{
15436 eval 'cat <<_LTECHO_EOF
15437\$1
15438_LTECHO_EOF'
15439}
15440
15441# Quote evaled strings.
15442for var in SHELL \
15443ECHO \
15444SED \
15445GREP \
15446EGREP \
15447FGREP \
15448LD \
15449NM \
15450LN_S \
15451lt_SP2NL \
15452lt_NL2SP \
15453reload_flag \
15454OBJDUMP \
15455deplibs_check_method \
15456file_magic_cmd \
15457AR \
15458AR_FLAGS \
15459STRIP \
15460RANLIB \
15461CC \
15462CFLAGS \
15463compiler \
15464lt_cv_sys_global_symbol_pipe \
15465lt_cv_sys_global_symbol_to_cdecl \
15466lt_cv_sys_global_symbol_to_c_name_address \
15467lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
15468lt_prog_compiler_no_builtin_flag \
15469lt_prog_compiler_wl \
15470lt_prog_compiler_pic \
15471lt_prog_compiler_static \
15472lt_cv_prog_compiler_c_o \
15473need_locks \
15474DSYMUTIL \
15475NMEDIT \
15476LIPO \
15477OTOOL \
15478OTOOL64 \
15479shrext_cmds \
15480export_dynamic_flag_spec \
15481whole_archive_flag_spec \
15482compiler_needs_object \
15483with_gnu_ld \
15484allow_undefined_flag \
15485no_undefined_flag \
15486hardcode_libdir_flag_spec \
15487hardcode_libdir_flag_spec_ld \
15488hardcode_libdir_separator \
15489fix_srcfile_path \
15490exclude_expsyms \
15491include_expsyms \
15492file_list_spec \
15493variables_saved_for_relink \
15494libname_spec \
15495library_names_spec \
15496soname_spec \
15497install_override_mode \
15498finish_eval \
15499old_striplib \
15500striplib \
15501compiler_lib_search_dirs \
15502predep_objects \
15503postdep_objects \
15504predeps \
15505postdeps \
15506compiler_lib_search_path \
15507LD_CXX \
15508reload_flag_CXX \
15509compiler_CXX \
15510lt_prog_compiler_no_builtin_flag_CXX \
15511lt_prog_compiler_wl_CXX \
15512lt_prog_compiler_pic_CXX \
15513lt_prog_compiler_static_CXX \
15514lt_cv_prog_compiler_c_o_CXX \
15515export_dynamic_flag_spec_CXX \
15516whole_archive_flag_spec_CXX \
15517compiler_needs_object_CXX \
15518with_gnu_ld_CXX \
15519allow_undefined_flag_CXX \
15520no_undefined_flag_CXX \
15521hardcode_libdir_flag_spec_CXX \
15522hardcode_libdir_flag_spec_ld_CXX \
15523hardcode_libdir_separator_CXX \
15524fix_srcfile_path_CXX \
15525exclude_expsyms_CXX \
15526include_expsyms_CXX \
15527file_list_spec_CXX \
15528compiler_lib_search_dirs_CXX \
15529predep_objects_CXX \
15530postdep_objects_CXX \
15531predeps_CXX \
15532postdeps_CXX \
15533compiler_lib_search_path_CXX; do
15534 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
15535 *[\\\\\\\`\\"\\\$]*)
15536 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
15537 ;;
15538 *)
15539 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
15540 ;;
15541 esac
15542done
15543
15544# Double-quote double-evaled strings.
15545for var in reload_cmds \
15546old_postinstall_cmds \
15547old_postuninstall_cmds \
15548old_archive_cmds \
15549extract_expsyms_cmds \
15550old_archive_from_new_cmds \
15551old_archive_from_expsyms_cmds \
15552archive_cmds \
15553archive_expsym_cmds \
15554module_cmds \
15555module_expsym_cmds \
15556export_symbols_cmds \
15557prelink_cmds \
15558postinstall_cmds \
15559postuninstall_cmds \
15560finish_cmds \
15561sys_lib_search_path_spec \
15562sys_lib_dlsearch_path_spec \
15563reload_cmds_CXX \
15564old_archive_cmds_CXX \
15565old_archive_from_new_cmds_CXX \
15566old_archive_from_expsyms_cmds_CXX \
15567archive_cmds_CXX \
15568archive_expsym_cmds_CXX \
15569module_cmds_CXX \
15570module_expsym_cmds_CXX \
15571export_symbols_cmds_CXX \
15572prelink_cmds_CXX; do
15573 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
15574 *[\\\\\\\`\\"\\\$]*)
15575 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
15576 ;;
15577 *)
15578 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
15579 ;;
15580 esac
15581done
15582
15583ac_aux_dir='$ac_aux_dir'
15584xsi_shell='$xsi_shell'
15585lt_shell_append='$lt_shell_append'
15586
15587# See if we are running on zsh, and set the options which allow our
15588# commands through without removal of \ escapes INIT.
15589if test -n "\${ZSH_VERSION+set}" ; then
15590 setopt NO_GLOB_SUBST
15591fi
15592
15593
15594 PACKAGE='$PACKAGE'
15595 VERSION='$VERSION'
15596 TIMESTAMP='$TIMESTAMP'
15597 RM='$RM'
15598 ofile='$ofile'
15599
15600
15601
15602
15603
15604_LTEOF
15605
15606cat >>"$CONFIG_LT" <<\_LTEOF
15607{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $ofile" >&5
15608$as_echo "$as_me: creating $ofile" >&6;}
15609
15610
15611 # See if we are running on zsh, and set the options which allow our
15612 # commands through without removal of \ escapes.
15613 if test -n "${ZSH_VERSION+set}" ; then
15614 setopt NO_GLOB_SUBST
15615 fi
15616
15617 cfgfile="${ofile}T"
15618 trap "$RM \"$cfgfile\"; exit 1" 1 2 15
15619 $RM "$cfgfile"
15620
15621 cat <<_LT_EOF >> "$cfgfile"
15622#! $SHELL
15623
15624# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
15625# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION
15626# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
15627# NOTE: Changes made to this file will be lost: look at ltmain.sh.
15628#
15629# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
15630# 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
15631# Written by Gordon Matzigkeit, 1996
15632#
15633# This file is part of GNU Libtool.
15634#
15635# GNU Libtool is free software; you can redistribute it and/or
15636# modify it under the terms of the GNU General Public License as
15637# published by the Free Software Foundation; either version 2 of
15638# the License, or (at your option) any later version.
15639#
15640# As a special exception to the GNU General Public License,
15641# if you distribute this file as part of a program or library that
15642# is built using GNU Libtool, you may include this file under the
15643# same distribution terms that you use for the rest of that program.
15644#
15645# GNU Libtool is distributed in the hope that it will be useful,
15646# but WITHOUT ANY WARRANTY; without even the implied warranty of
15647# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15648# GNU General Public License for more details.
15649#
15650# You should have received a copy of the GNU General Public License
15651# along with GNU Libtool; see the file COPYING. If not, a copy
15652# can be downloaded from http://www.gnu.org/licenses/gpl.html, or
15653# obtained by writing to the Free Software Foundation, Inc.,
15654# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
15655
15656
15657# The names of the tagged configurations supported by this script.
15658available_tags="CXX "
15659
15660# ### BEGIN LIBTOOL CONFIG
15661
15662# Which release of libtool.m4 was used?
15663macro_version=$macro_version
15664macro_revision=$macro_revision
15665
15666# Whether or not to build shared libraries.
15667build_libtool_libs=$enable_shared
15668
15669# Whether or not to build static libraries.
15670build_old_libs=$enable_static
15671
15672# What type of objects to build.
15673pic_mode=$pic_mode
15674
15675# Whether or not to optimize for fast installation.
15676fast_install=$enable_fast_install
15677
15678# Shell to use when invoking shell scripts.
15679SHELL=$lt_SHELL
15680
15681# An echo program that protects backslashes.
15682ECHO=$lt_ECHO
15683
15684# The host system.
15685host_alias=$host_alias
15686host=$host
15687host_os=$host_os
15688
15689# The build system.
15690build_alias=$build_alias
15691build=$build
15692build_os=$build_os
15693
15694# A sed program that does not truncate output.
15695SED=$lt_SED
15696
15697# Sed that helps us avoid accidentally triggering echo(1) options like -n.
15698Xsed="\$SED -e 1s/^X//"
15699
15700# A grep program that handles long lines.
15701GREP=$lt_GREP
15702
15703# An ERE matcher.
15704EGREP=$lt_EGREP
15705
15706# A literal string matcher.
15707FGREP=$lt_FGREP
15708
15709# A BSD- or MS-compatible name lister.
15710NM=$lt_NM
15711
15712# Whether we need soft or hard links.
15713LN_S=$lt_LN_S
15714
15715# What is the maximum length of a command?
15716max_cmd_len=$max_cmd_len
15717
15718# Object file suffix (normally "o").
15719objext=$ac_objext
15720
15721# Executable file suffix (normally "").
15722exeext=$exeext
15723
15724# whether the shell understands "unset".
15725lt_unset=$lt_unset
15726
15727# turn spaces into newlines.
15728SP2NL=$lt_lt_SP2NL
15729
15730# turn newlines into spaces.
15731NL2SP=$lt_lt_NL2SP
15732
15733# An object symbol dumper.
15734OBJDUMP=$lt_OBJDUMP
15735
15736# Method to check whether dependent libraries are shared objects.
15737deplibs_check_method=$lt_deplibs_check_method
15738
15739# Command to use when deplibs_check_method == "file_magic".
15740file_magic_cmd=$lt_file_magic_cmd
15741
15742# The archiver.
15743AR=$lt_AR
15744AR_FLAGS=$lt_AR_FLAGS
15745
15746# A symbol stripping program.
15747STRIP=$lt_STRIP
15748
15749# Commands used to install an old-style archive.
15750RANLIB=$lt_RANLIB
15751old_postinstall_cmds=$lt_old_postinstall_cmds
15752old_postuninstall_cmds=$lt_old_postuninstall_cmds
15753
15754# Whether to use a lock for old archive extraction.
15755lock_old_archive_extraction=$lock_old_archive_extraction
15756
15757# A C compiler.
15758LTCC=$lt_CC
15759
15760# LTCC compiler flags.
15761LTCFLAGS=$lt_CFLAGS
15762
15763# Take the output of nm and produce a listing of raw symbols and C names.
15764global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
15765
15766# Transform the output of nm in a proper C declaration.
15767global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
15768
15769# Transform the output of nm in a C name address pair.
15770global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
15771
15772# Transform the output of nm in a C name address pair when lib prefix is needed.
15773global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
15774
15775# The name of the directory that contains temporary libtool files.
15776objdir=$objdir
15777
15778# Used to examine libraries when file_magic_cmd begins with "file".
15779MAGIC_CMD=$MAGIC_CMD
15780
15781# Must we lock files when doing compilation?
15782need_locks=$lt_need_locks
15783
15784# Tool to manipulate archived DWARF debug symbol files on Mac OS X.
15785DSYMUTIL=$lt_DSYMUTIL
15786
15787# Tool to change global to local symbols on Mac OS X.
15788NMEDIT=$lt_NMEDIT
15789
15790# Tool to manipulate fat objects and archives on Mac OS X.
15791LIPO=$lt_LIPO
15792
15793# ldd/readelf like tool for Mach-O binaries on Mac OS X.
15794OTOOL=$lt_OTOOL
15795
15796# ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4.
15797OTOOL64=$lt_OTOOL64
15798
15799# Old archive suffix (normally "a").
15800libext=$libext
15801
15802# Shared library suffix (normally ".so").
15803shrext_cmds=$lt_shrext_cmds
15804
15805# The commands to extract the exported symbol list from a shared archive.
15806extract_expsyms_cmds=$lt_extract_expsyms_cmds
15807
15808# Variables whose values should be saved in libtool wrapper scripts and
15809# restored at link time.
15810variables_saved_for_relink=$lt_variables_saved_for_relink
15811
15812# Do we need the "lib" prefix for modules?
15813need_lib_prefix=$need_lib_prefix
15814
15815# Do we need a version for libraries?
15816need_version=$need_version
15817
15818# Library versioning type.
15819version_type=$version_type
15820
15821# Shared library runtime path variable.
15822runpath_var=$runpath_var
15823
15824# Shared library path variable.
15825shlibpath_var=$shlibpath_var
15826
15827# Is shlibpath searched before the hard-coded library search path?
15828shlibpath_overrides_runpath=$shlibpath_overrides_runpath
15829
15830# Format of library name prefix.
15831libname_spec=$lt_libname_spec
15832
15833# List of archive names. First name is the real one, the rest are links.
15834# The last name is the one that the linker finds with -lNAME
15835library_names_spec=$lt_library_names_spec
15836
15837# The coded name of the library, if different from the real name.
15838soname_spec=$lt_soname_spec
15839
15840# Permission mode override for installation of shared libraries.
15841install_override_mode=$lt_install_override_mode
15842
15843# Command to use after installation of a shared archive.
15844postinstall_cmds=$lt_postinstall_cmds
15845
15846# Command to use after uninstallation of a shared archive.
15847postuninstall_cmds=$lt_postuninstall_cmds
15848
15849# Commands used to finish a libtool library installation in a directory.
15850finish_cmds=$lt_finish_cmds
15851
15852# As "finish_cmds", except a single script fragment to be evaled but
15853# not shown.
15854finish_eval=$lt_finish_eval
15855
15856# Whether we should hardcode library paths into libraries.
15857hardcode_into_libs=$hardcode_into_libs
15858
15859# Compile-time system search path for libraries.
15860sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
15861
15862# Run-time system search path for libraries.
15863sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
15864
15865# Whether dlopen is supported.
15866dlopen_support=$enable_dlopen
15867
15868# Whether dlopen of programs is supported.
15869dlopen_self=$enable_dlopen_self
15870
15871# Whether dlopen of statically linked programs is supported.
15872dlopen_self_static=$enable_dlopen_self_static
15873
15874# Commands to strip libraries.
15875old_striplib=$lt_old_striplib
15876striplib=$lt_striplib
15877
15878
15879# The linker used to build libraries.
15880LD=$lt_LD
15881
15882# How to create reloadable object files.
15883reload_flag=$lt_reload_flag
15884reload_cmds=$lt_reload_cmds
15885
15886# Commands used to build an old-style archive.
15887old_archive_cmds=$lt_old_archive_cmds
15888
15889# A language specific compiler.
15890CC=$lt_compiler
15891
15892# Is the compiler the GNU compiler?
15893with_gcc=$GCC
15894
15895# Compiler flag to turn off builtin functions.
15896no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
15897
15898# How to pass a linker flag through the compiler.
15899wl=$lt_lt_prog_compiler_wl
15900
15901# Additional compiler flags for building library objects.
15902pic_flag=$lt_lt_prog_compiler_pic
15903
15904# Compiler flag to prevent dynamic linking.
15905link_static_flag=$lt_lt_prog_compiler_static
15906
15907# Does compiler simultaneously support -c and -o options?
15908compiler_c_o=$lt_lt_cv_prog_compiler_c_o
15909
15910# Whether or not to add -lc for building shared libraries.
15911build_libtool_need_lc=$archive_cmds_need_lc
15912
15913# Whether or not to disallow shared libs when runtime libs are static.
15914allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes
15915
15916# Compiler flag to allow reflexive dlopens.
15917export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
15918
15919# Compiler flag to generate shared objects directly from archives.
15920whole_archive_flag_spec=$lt_whole_archive_flag_spec
15921
15922# Whether the compiler copes with passing no objects directly.
15923compiler_needs_object=$lt_compiler_needs_object
15924
15925# Create an old-style archive from a shared archive.
15926old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
15927
15928# Create a temporary old-style archive to link instead of a shared archive.
15929old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
15930
15931# Commands used to build a shared archive.
15932archive_cmds=$lt_archive_cmds
15933archive_expsym_cmds=$lt_archive_expsym_cmds
15934
15935# Commands used to build a loadable module if different from building
15936# a shared archive.
15937module_cmds=$lt_module_cmds
15938module_expsym_cmds=$lt_module_expsym_cmds
15939
15940# Whether we are building with GNU ld or not.
15941with_gnu_ld=$lt_with_gnu_ld
15942
15943# Flag that allows shared libraries with undefined symbols to be built.
15944allow_undefined_flag=$lt_allow_undefined_flag
15945
15946# Flag that enforces no undefined symbols.
15947no_undefined_flag=$lt_no_undefined_flag
15948
15949# Flag to hardcode \$libdir into a binary during linking.
15950# This must work even if \$libdir does not exist
15951hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
15952
15953# If ld is used when linking, flag to hardcode \$libdir into a binary
15954# during linking. This must work even if \$libdir does not exist.
15955hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld
15956
15957# Whether we need a single "-rpath" flag with a separated argument.
15958hardcode_libdir_separator=$lt_hardcode_libdir_separator
15959
15960# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
15961# DIR into the resulting binary.
15962hardcode_direct=$hardcode_direct
15963
15964# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
15965# DIR into the resulting binary and the resulting library dependency is
15966# "absolute",i.e impossible to change by setting \${shlibpath_var} if the
15967# library is relocated.
15968hardcode_direct_absolute=$hardcode_direct_absolute
15969
15970# Set to "yes" if using the -LDIR flag during linking hardcodes DIR
15971# into the resulting binary.
15972hardcode_minus_L=$hardcode_minus_L
15973
15974# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
15975# into the resulting binary.
15976hardcode_shlibpath_var=$hardcode_shlibpath_var
15977
15978# Set to "yes" if building a shared library automatically hardcodes DIR
15979# into the library and all subsequent libraries and executables linked
15980# against it.
15981hardcode_automatic=$hardcode_automatic
15982
15983# Set to yes if linker adds runtime paths of dependent libraries
15984# to runtime path list.
15985inherit_rpath=$inherit_rpath
15986
15987# Whether libtool must link a program against all its dependency libraries.
15988link_all_deplibs=$link_all_deplibs
15989
15990# Fix the shell variable \$srcfile for the compiler.
15991fix_srcfile_path=$lt_fix_srcfile_path
15992
15993# Set to "yes" if exported symbols are required.
15994always_export_symbols=$always_export_symbols
15995
15996# The commands to list exported symbols.
15997export_symbols_cmds=$lt_export_symbols_cmds
15998
15999# Symbols that should not be listed in the preloaded symbols.
16000exclude_expsyms=$lt_exclude_expsyms
16001
16002# Symbols that must always be exported.
16003include_expsyms=$lt_include_expsyms
16004
16005# Commands necessary for linking programs (against libraries) with templates.
16006prelink_cmds=$lt_prelink_cmds
16007
16008# Specify filename containing input files.
16009file_list_spec=$lt_file_list_spec
16010
16011# How to hardcode a shared library path into an executable.
16012hardcode_action=$hardcode_action
16013
16014# The directories searched by this compiler when creating a shared library.
16015compiler_lib_search_dirs=$lt_compiler_lib_search_dirs
16016
16017# Dependencies to place before and after the objects being linked to
16018# create a shared library.
16019predep_objects=$lt_predep_objects
16020postdep_objects=$lt_postdep_objects
16021predeps=$lt_predeps
16022postdeps=$lt_postdeps
16023
16024# The library search path used internally by the compiler when linking
16025# a shared library.
16026compiler_lib_search_path=$lt_compiler_lib_search_path
16027
16028# ### END LIBTOOL CONFIG
16029
16030_LT_EOF
16031
16032 case $host_os in
16033 aix3*)
16034 cat <<\_LT_EOF >> "$cfgfile"
16035# AIX sometimes has problems with the GCC collect2 program. For some
16036# reason, if we set the COLLECT_NAMES environment variable, the problems
16037# vanish in a puff of smoke.
16038if test "X${COLLECT_NAMES+set}" != Xset; then
16039 COLLECT_NAMES=
16040 export COLLECT_NAMES
16041fi
16042_LT_EOF
16043 ;;
16044 esac
16045
16046
16047ltmain="$ac_aux_dir/ltmain.sh"
16048
16049
16050 # We use sed instead of cat because bash on DJGPP gets confused if
16051 # if finds mixed CR/LF and LF-only lines. Since sed operates in
16052 # text mode, it properly converts lines to CR/LF. This bash problem
16053 # is reportedly fixed, but why not run on old versions too?
16054 sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \
16055 || (rm -f "$cfgfile"; exit 1)
16056
16057 case $xsi_shell in
16058 yes)
16059 cat << \_LT_EOF >> "$cfgfile"
16060
16061# func_dirname file append nondir_replacement
16062# Compute the dirname of FILE. If nonempty, add APPEND to the result,
16063# otherwise set result to NONDIR_REPLACEMENT.
16064func_dirname ()
16065{
16066 case ${1} in
16067 */*) func_dirname_result="${1%/*}${2}" ;;
16068 * ) func_dirname_result="${3}" ;;
16069 esac
16070}
16071
16072# func_basename file
16073func_basename ()
16074{
16075 func_basename_result="${1##*/}"
16076}
16077
16078# func_dirname_and_basename file append nondir_replacement
16079# perform func_basename and func_dirname in a single function
16080# call:
16081# dirname: Compute the dirname of FILE. If nonempty,
16082# add APPEND to the result, otherwise set result
16083# to NONDIR_REPLACEMENT.
16084# value returned in "$func_dirname_result"
16085# basename: Compute filename of FILE.
16086# value retuned in "$func_basename_result"
16087# Implementation must be kept synchronized with func_dirname
16088# and func_basename. For efficiency, we do not delegate to
16089# those functions but instead duplicate the functionality here.
16090func_dirname_and_basename ()
16091{
16092 case ${1} in
16093 */*) func_dirname_result="${1%/*}${2}" ;;
16094 * ) func_dirname_result="${3}" ;;
16095 esac
16096 func_basename_result="${1##*/}"
16097}
16098
16099# func_stripname prefix suffix name
16100# strip PREFIX and SUFFIX off of NAME.
16101# PREFIX and SUFFIX must not contain globbing or regex special
16102# characters, hashes, percent signs, but SUFFIX may contain a leading
16103# dot (in which case that matches only a dot).
16104func_stripname ()
16105{
16106 # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
16107 # positional parameters, so assign one to ordinary parameter first.
16108 func_stripname_result=${3}
16109 func_stripname_result=${func_stripname_result#"${1}"}
16110 func_stripname_result=${func_stripname_result%"${2}"}
16111}
16112
16113# func_opt_split
16114func_opt_split ()
16115{
16116 func_opt_split_opt=${1%%=*}
16117 func_opt_split_arg=${1#*=}
16118}
16119
16120# func_lo2o object
16121func_lo2o ()
16122{
16123 case ${1} in
16124 *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
16125 *) func_lo2o_result=${1} ;;
16126 esac
16127}
16128
16129# func_xform libobj-or-source
16130func_xform ()
16131{
16132 func_xform_result=${1%.*}.lo
16133}
16134
16135# func_arith arithmetic-term...
16136func_arith ()
16137{
16138 func_arith_result=$(( $* ))
16139}
16140
16141# func_len string
16142# STRING may not start with a hyphen.
16143func_len ()
16144{
16145 func_len_result=${#1}
16146}
16147
16148_LT_EOF
16149 ;;
16150 *) # Bourne compatible functions.
16151 cat << \_LT_EOF >> "$cfgfile"
16152
16153# func_dirname file append nondir_replacement
16154# Compute the dirname of FILE. If nonempty, add APPEND to the result,
16155# otherwise set result to NONDIR_REPLACEMENT.
16156func_dirname ()
16157{
16158 # Extract subdirectory from the argument.
16159 func_dirname_result=`$ECHO "${1}" | $SED "$dirname"`
16160 if test "X$func_dirname_result" = "X${1}"; then
16161 func_dirname_result="${3}"
16162 else
16163 func_dirname_result="$func_dirname_result${2}"
16164 fi
16165}
16166
16167# func_basename file
16168func_basename ()
16169{
16170 func_basename_result=`$ECHO "${1}" | $SED "$basename"`
16171}
16172
16173
16174# func_stripname prefix suffix name
16175# strip PREFIX and SUFFIX off of NAME.
16176# PREFIX and SUFFIX must not contain globbing or regex special
16177# characters, hashes, percent signs, but SUFFIX may contain a leading
16178# dot (in which case that matches only a dot).
16179# func_strip_suffix prefix name
16180func_stripname ()
16181{
16182 case ${2} in
16183 .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
16184 *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
16185 esac
16186}
16187
16188# sed scripts:
16189my_sed_long_opt='1s/^\(-[^=]*\)=.*/\1/;q'
16190my_sed_long_arg='1s/^-[^=]*=//'
16191
16192# func_opt_split
16193func_opt_split ()
16194{
16195 func_opt_split_opt=`$ECHO "${1}" | $SED "$my_sed_long_opt"`
16196 func_opt_split_arg=`$ECHO "${1}" | $SED "$my_sed_long_arg"`
16197}
16198
16199# func_lo2o object
16200func_lo2o ()
16201{
16202 func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"`
16203}
16204
16205# func_xform libobj-or-source
16206func_xform ()
16207{
16208 func_xform_result=`$ECHO "${1}" | $SED 's/\.[^.]*$/.lo/'`
16209}
16210
16211# func_arith arithmetic-term...
16212func_arith ()
16213{
16214 func_arith_result=`expr "$@"`
16215}
16216
16217# func_len string
16218# STRING may not start with a hyphen.
16219func_len ()
16220{
16221 func_len_result=`expr "$1" : ".*" 2>/dev/null || echo $max_cmd_len`
16222}
16223
16224_LT_EOF
16225esac
16226
16227case $lt_shell_append in
16228 yes)
16229 cat << \_LT_EOF >> "$cfgfile"
16230
16231# func_append var value
16232# Append VALUE to the end of shell variable VAR.
16233func_append ()
16234{
16235 eval "$1+=\$2"
16236}
16237_LT_EOF
16238 ;;
16239 *)
16240 cat << \_LT_EOF >> "$cfgfile"
16241
16242# func_append var value
16243# Append VALUE to the end of shell variable VAR.
16244func_append ()
16245{
16246 eval "$1=\$$1\$2"
16247}
16248
16249_LT_EOF
16250 ;;
16251 esac
16252
16253
16254 sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
16255 || (rm -f "$cfgfile"; exit 1)
16256
16257 mv -f "$cfgfile" "$ofile" ||
16258 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
16259 chmod +x "$ofile"
16260
16261
16262 cat <<_LT_EOF >> "$ofile"
16263
16264# ### BEGIN LIBTOOL TAG CONFIG: CXX
16265
16266# The linker used to build libraries.
16267LD=$lt_LD_CXX
16268
16269# How to create reloadable object files.
16270reload_flag=$lt_reload_flag_CXX
16271reload_cmds=$lt_reload_cmds_CXX
16272
16273# Commands used to build an old-style archive.
16274old_archive_cmds=$lt_old_archive_cmds_CXX
16275
16276# A language specific compiler.
16277CC=$lt_compiler_CXX
16278
16279# Is the compiler the GNU compiler?
16280with_gcc=$GCC_CXX
16281
16282# Compiler flag to turn off builtin functions.
16283no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_CXX
16284
16285# How to pass a linker flag through the compiler.
16286wl=$lt_lt_prog_compiler_wl_CXX
16287
16288# Additional compiler flags for building library objects.
16289pic_flag=$lt_lt_prog_compiler_pic_CXX
16290
16291# Compiler flag to prevent dynamic linking.
16292link_static_flag=$lt_lt_prog_compiler_static_CXX
16293
16294# Does compiler simultaneously support -c and -o options?
16295compiler_c_o=$lt_lt_cv_prog_compiler_c_o_CXX
16296
16297# Whether or not to add -lc for building shared libraries.
16298build_libtool_need_lc=$archive_cmds_need_lc_CXX
16299
16300# Whether or not to disallow shared libs when runtime libs are static.
16301allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_CXX
16302
16303# Compiler flag to allow reflexive dlopens.
16304export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_CXX
16305
16306# Compiler flag to generate shared objects directly from archives.
16307whole_archive_flag_spec=$lt_whole_archive_flag_spec_CXX
16308
16309# Whether the compiler copes with passing no objects directly.
16310compiler_needs_object=$lt_compiler_needs_object_CXX
16311
16312# Create an old-style archive from a shared archive.
16313old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_CXX
16314
16315# Create a temporary old-style archive to link instead of a shared archive.
16316old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_CXX
16317
16318# Commands used to build a shared archive.
16319archive_cmds=$lt_archive_cmds_CXX
16320archive_expsym_cmds=$lt_archive_expsym_cmds_CXX
16321
16322# Commands used to build a loadable module if different from building
16323# a shared archive.
16324module_cmds=$lt_module_cmds_CXX
16325module_expsym_cmds=$lt_module_expsym_cmds_CXX
16326
16327# Whether we are building with GNU ld or not.
16328with_gnu_ld=$lt_with_gnu_ld_CXX
16329
16330# Flag that allows shared libraries with undefined symbols to be built.
16331allow_undefined_flag=$lt_allow_undefined_flag_CXX
16332
16333# Flag that enforces no undefined symbols.
16334no_undefined_flag=$lt_no_undefined_flag_CXX
16335
16336# Flag to hardcode \$libdir into a binary during linking.
16337# This must work even if \$libdir does not exist
16338hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_CXX
16339
16340# If ld is used when linking, flag to hardcode \$libdir into a binary
16341# during linking. This must work even if \$libdir does not exist.
16342hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_CXX
16343
16344# Whether we need a single "-rpath" flag with a separated argument.
16345hardcode_libdir_separator=$lt_hardcode_libdir_separator_CXX
16346
16347# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
16348# DIR into the resulting binary.
16349hardcode_direct=$hardcode_direct_CXX
16350
16351# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
16352# DIR into the resulting binary and the resulting library dependency is
16353# "absolute",i.e impossible to change by setting \${shlibpath_var} if the
16354# library is relocated.
16355hardcode_direct_absolute=$hardcode_direct_absolute_CXX
16356
16357# Set to "yes" if using the -LDIR flag during linking hardcodes DIR
16358# into the resulting binary.
16359hardcode_minus_L=$hardcode_minus_L_CXX
16360
16361# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
16362# into the resulting binary.
16363hardcode_shlibpath_var=$hardcode_shlibpath_var_CXX
16364
16365# Set to "yes" if building a shared library automatically hardcodes DIR
16366# into the library and all subsequent libraries and executables linked
16367# against it.
16368hardcode_automatic=$hardcode_automatic_CXX
16369
16370# Set to yes if linker adds runtime paths of dependent libraries
16371# to runtime path list.
16372inherit_rpath=$inherit_rpath_CXX
16373
16374# Whether libtool must link a program against all its dependency libraries.
16375link_all_deplibs=$link_all_deplibs_CXX
16376
16377# Fix the shell variable \$srcfile for the compiler.
16378fix_srcfile_path=$lt_fix_srcfile_path_CXX
16379
16380# Set to "yes" if exported symbols are required.
16381always_export_symbols=$always_export_symbols_CXX
16382
16383# The commands to list exported symbols.
16384export_symbols_cmds=$lt_export_symbols_cmds_CXX
16385
16386# Symbols that should not be listed in the preloaded symbols.
16387exclude_expsyms=$lt_exclude_expsyms_CXX
16388
16389# Symbols that must always be exported.
16390include_expsyms=$lt_include_expsyms_CXX
16391
16392# Commands necessary for linking programs (against libraries) with templates.
16393prelink_cmds=$lt_prelink_cmds_CXX
16394
16395# Specify filename containing input files.
16396file_list_spec=$lt_file_list_spec_CXX
16397
16398# How to hardcode a shared library path into an executable.
16399hardcode_action=$hardcode_action_CXX
16400
16401# The directories searched by this compiler when creating a shared library.
16402compiler_lib_search_dirs=$lt_compiler_lib_search_dirs_CXX
16403
16404# Dependencies to place before and after the objects being linked to
16405# create a shared library.
16406predep_objects=$lt_predep_objects_CXX
16407postdep_objects=$lt_postdep_objects_CXX
16408predeps=$lt_predeps_CXX
16409postdeps=$lt_postdeps_CXX
16410
16411# The library search path used internally by the compiler when linking
16412# a shared library.
16413compiler_lib_search_path=$lt_compiler_lib_search_path_CXX
16414
16415# ### END LIBTOOL TAG CONFIG: CXX
16416_LT_EOF
16417
16418
16419as_fn_exit 0
16420_LTEOF
16421chmod +x "$CONFIG_LT"
16422
16423# configure is writing to config.log, but config.lt does its own redirection,
16424# appending to config.log, which fails on DOS, as config.log is still kept
16425# open by configure. Here we exec the FD to /dev/null, effectively closing
16426# config.log, so it can be properly (re)opened and appended to by config.lt.
16427lt_cl_success=:
16428test "$silent" = yes &&
16429 lt_config_lt_args="$lt_config_lt_args --quiet"
16430exec 5>/dev/null
16431$SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false
16432exec 5>>config.log
16433$lt_cl_success || as_fn_exit 1
16434
b686ecb5
JM
16435
16436# We require a C++11 compiler. Check if one is available, and if
16437# necessary, set CXX_DIALECT to some -std=xxx switch.
16438 ax_cxx_compile_alternatives="11 0x" ax_cxx_compile_cxx11_required=true
16439 ac_ext=cpp
16440ac_cpp='$CXXCPP $CPPFLAGS'
16441ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
16442ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
16443ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
16444 CXX_DIALECT=""
16445 ac_success=no
16446 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features by default" >&5
16447$as_echo_n "checking whether $CXX supports C++11 features by default... " >&6; }
16448if ${ax_cv_cxx_compile_cxx11+:} false; then :
81ecdfbb 16449 $as_echo_n "(cached) " >&6
a9322a30 16450else
81ecdfbb
RW
16451 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16452/* end confdefs.h. */
81ecdfbb 16453
81ecdfbb 16454
b686ecb5
JM
16455// If the compiler admits that it is not ready for C++11, why torture it?
16456// Hopefully, this will speed up the test.
81ecdfbb 16457
b686ecb5 16458#ifndef __cplusplus
a9322a30 16459
b686ecb5 16460#error "This is not a C++ compiler"
a9322a30 16461
b686ecb5 16462#elif __cplusplus < 201103L
a9322a30 16463
b686ecb5 16464#error "This is not a C++11 compiler"
a9322a30 16465
b686ecb5 16466#else
a9322a30 16467
b686ecb5
JM
16468namespace cxx11
16469{
a9322a30 16470
b686ecb5
JM
16471 namespace test_static_assert
16472 {
a9322a30 16473
b686ecb5
JM
16474 template <typename T>
16475 struct check
16476 {
16477 static_assert(sizeof(int) <= sizeof(T), "not big enough");
16478 };
a9322a30 16479
a9322a30 16480 }
a9322a30 16481
b686ecb5
JM
16482 namespace test_final_override
16483 {
a9322a30 16484
b686ecb5
JM
16485 struct Base
16486 {
16487 virtual void f() {}
16488 };
a9322a30 16489
b686ecb5
JM
16490 struct Derived : public Base
16491 {
16492 virtual void f() override {}
16493 };
a9322a30 16494
b686ecb5 16495 }
a9322a30 16496
b686ecb5
JM
16497 namespace test_double_right_angle_brackets
16498 {
a9322a30 16499
b686ecb5
JM
16500 template < typename T >
16501 struct check {};
a9322a30 16502
b686ecb5
JM
16503 typedef check<void> single_type;
16504 typedef check<check<void>> double_type;
16505 typedef check<check<check<void>>> triple_type;
16506 typedef check<check<check<check<void>>>> quadruple_type;
a9322a30 16507
b686ecb5 16508 }
a9322a30 16509
b686ecb5
JM
16510 namespace test_decltype
16511 {
6c7a06a3 16512
b686ecb5
JM
16513 int
16514 f()
16515 {
16516 int a = 1;
16517 decltype(a) b = 2;
16518 return a + b;
16519 }
6c7a06a3 16520
b686ecb5 16521 }
6c7a06a3 16522
b686ecb5
JM
16523 namespace test_type_deduction
16524 {
0b03c6f0 16525
b686ecb5
JM
16526 template < typename T1, typename T2 >
16527 struct is_same
16528 {
16529 static const bool value = false;
16530 };
0b03c6f0 16531
b686ecb5
JM
16532 template < typename T >
16533 struct is_same<T, T>
16534 {
16535 static const bool value = true;
16536 };
0b03c6f0 16537
b686ecb5
JM
16538 template < typename T1, typename T2 >
16539 auto
16540 add(T1 a1, T2 a2) -> decltype(a1 + a2)
16541 {
16542 return a1 + a2;
16543 }
d0ac1c44 16544
b686ecb5
JM
16545 int
16546 test(const int c, volatile int v)
16547 {
16548 static_assert(is_same<int, decltype(0)>::value == true, "");
16549 static_assert(is_same<int, decltype(c)>::value == false, "");
16550 static_assert(is_same<int, decltype(v)>::value == false, "");
16551 auto ac = c;
16552 auto av = v;
16553 auto sumi = ac + av + 'x';
16554 auto sumf = ac + av + 1.0;
16555 static_assert(is_same<int, decltype(ac)>::value == true, "");
16556 static_assert(is_same<int, decltype(av)>::value == true, "");
16557 static_assert(is_same<int, decltype(sumi)>::value == true, "");
16558 static_assert(is_same<int, decltype(sumf)>::value == false, "");
16559 static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
16560 return (sumf > 0.0) ? sumi : add(c, v);
16561 }
05ea2a05 16562
b686ecb5 16563 }
05ea2a05 16564
b686ecb5
JM
16565 namespace test_noexcept
16566 {
05ea2a05 16567
b686ecb5
JM
16568 int f() { return 0; }
16569 int g() noexcept { return 0; }
05ea2a05 16570
b686ecb5
JM
16571 static_assert(noexcept(f()) == false, "");
16572 static_assert(noexcept(g()) == true, "");
d0ac1c44 16573
b686ecb5 16574 }
05ea2a05 16575
b686ecb5
JM
16576 namespace test_constexpr
16577 {
d0ac1c44 16578
b686ecb5
JM
16579 template < typename CharT >
16580 unsigned long constexpr
16581 strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
16582 {
16583 return *s ? strlen_c_r(s + 1, acc + 1) : acc;
16584 }
05ea2a05 16585
b686ecb5
JM
16586 template < typename CharT >
16587 unsigned long constexpr
16588 strlen_c(const CharT *const s) noexcept
16589 {
16590 return strlen_c_r(s, 0UL);
16591 }
05ea2a05 16592
b686ecb5
JM
16593 static_assert(strlen_c("") == 0UL, "");
16594 static_assert(strlen_c("1") == 1UL, "");
16595 static_assert(strlen_c("example") == 7UL, "");
16596 static_assert(strlen_c("another\0example") == 7UL, "");
05ea2a05 16597
b686ecb5 16598 }
05ea2a05 16599
b686ecb5
JM
16600 namespace test_rvalue_references
16601 {
3266f10b 16602
b686ecb5
JM
16603 template < int N >
16604 struct answer
16605 {
16606 static constexpr int value = N;
16607 };
3266f10b 16608
b686ecb5
JM
16609 answer<1> f(int&) { return answer<1>(); }
16610 answer<2> f(const int&) { return answer<2>(); }
16611 answer<3> f(int&&) { return answer<3>(); }
05ea2a05 16612
b686ecb5
JM
16613 void
16614 test()
16615 {
16616 int i = 0;
16617 const int c = 0;
16618 static_assert(decltype(f(i))::value == 1, "");
16619 static_assert(decltype(f(c))::value == 2, "");
16620 static_assert(decltype(f(0))::value == 3, "");
16621 }
e911c666 16622
b686ecb5 16623 }
e911c666 16624
b686ecb5
JM
16625 namespace test_uniform_initialization
16626 {
3266f10b 16627
b686ecb5
JM
16628 struct test
16629 {
16630 static const int zero {};
16631 static const int one {1};
16632 };
3266f10b 16633
b686ecb5
JM
16634 static_assert(test::zero == 0, "");
16635 static_assert(test::one == 1, "");
3266f10b 16636
b686ecb5 16637 }
261b0748 16638
b686ecb5
JM
16639 namespace test_lambdas
16640 {
261b0748 16641
b686ecb5
JM
16642 void
16643 test1()
16644 {
16645 auto lambda1 = [](){};
16646 auto lambda2 = lambda1;
16647 lambda1();
16648 lambda2();
16649 }
261b0748 16650
b686ecb5
JM
16651 int
16652 test2()
16653 {
16654 auto a = [](int i, int j){ return i + j; }(1, 2);
16655 auto b = []() -> int { return '0'; }();
16656 auto c = [=](){ return a + b; }();
16657 auto d = [&](){ return c; }();
16658 auto e = [a, &b](int x) mutable {
16659 const auto identity = [](int y){ return y; };
16660 for (auto i = 0; i < a; ++i)
16661 a += b--;
16662 return x + identity(a + b);
16663 }(0);
16664 return a + b + c + d + e;
16665 }
3266f10b 16666
b686ecb5
JM
16667 int
16668 test3()
16669 {
16670 const auto nullary = [](){ return 0; };
16671 const auto unary = [](int x){ return x; };
16672 using nullary_t = decltype(nullary);
16673 using unary_t = decltype(unary);
16674 const auto higher1st = [](nullary_t f){ return f(); };
16675 const auto higher2nd = [unary](nullary_t f1){
16676 return [unary, f1](unary_t f2){ return f2(unary(f1())); };
16677 };
16678 return higher1st(nullary) + higher2nd(nullary)(unary);
16679 }
3266f10b 16680
b686ecb5 16681 }
3266f10b 16682
b686ecb5
JM
16683 namespace test_variadic_templates
16684 {
3266f10b 16685
b686ecb5
JM
16686 template <int...>
16687 struct sum;
3266f10b 16688
b686ecb5
JM
16689 template <int N0, int... N1toN>
16690 struct sum<N0, N1toN...>
16691 {
16692 static constexpr auto value = N0 + sum<N1toN...>::value;
16693 };
3266f10b 16694
b686ecb5
JM
16695 template <>
16696 struct sum<>
16697 {
16698 static constexpr auto value = 0;
16699 };
3266f10b 16700
b686ecb5
JM
16701 static_assert(sum<>::value == 0, "");
16702 static_assert(sum<1>::value == 1, "");
16703 static_assert(sum<23>::value == 23, "");
16704 static_assert(sum<1, 2>::value == 3, "");
16705 static_assert(sum<5, 5, 11>::value == 21, "");
16706 static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
3266f10b 16707
b686ecb5 16708 }
05ea2a05 16709
b686ecb5
JM
16710 // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
16711 // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
16712 // because of this.
16713 namespace test_template_alias_sfinae
16714 {
3266f10b 16715
b686ecb5 16716 struct foo {};
3266f10b 16717
b686ecb5
JM
16718 template<typename T>
16719 using member = typename T::member_type;
3266f10b 16720
b686ecb5
JM
16721 template<typename T>
16722 void func(...) {}
3266f10b 16723
b686ecb5
JM
16724 template<typename T>
16725 void func(member<T>*) {}
3266f10b 16726
b686ecb5 16727 void test();
3266f10b 16728
b686ecb5 16729 void test() { func<foo>(0); }
3266f10b 16730
b686ecb5 16731 }
3266f10b 16732
b686ecb5 16733} // namespace cxx11
3266f10b 16734
b686ecb5 16735#endif // __cplusplus >= 201103L
05ea2a05 16736
05ea2a05 16737
05ea2a05 16738
b686ecb5
JM
16739_ACEOF
16740if ac_fn_cxx_try_compile "$LINENO"; then :
16741 ax_cv_cxx_compile_cxx11=yes
16742else
16743 ax_cv_cxx_compile_cxx11=no
16744fi
16745rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16746fi
16747{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_cxx_compile_cxx11" >&5
16748$as_echo "$ax_cv_cxx_compile_cxx11" >&6; }
16749 if test x$ax_cv_cxx_compile_cxx11 = xyes; then
16750 ac_success=yes
16751 fi
05ea2a05 16752
b686ecb5
JM
16753 if test x$ac_success = xno; then
16754 for alternative in ${ax_cxx_compile_alternatives}; do
16755 switch="-std=gnu++${alternative}"
16756 cachevar=`$as_echo "ax_cv_cxx_compile_cxx11_$switch" | $as_tr_sh`
16757 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features with $switch" >&5
16758$as_echo_n "checking whether $CXX supports C++11 features with $switch... " >&6; }
16759if eval \${$cachevar+:} false; then :
16760 $as_echo_n "(cached) " >&6
16761else
16762 ac_save_CXX="$CXX"
16763 CXX="$CXX $switch"
16764 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3266f10b 16765/* end confdefs.h. */
05ea2a05 16766
3266f10b 16767
b686ecb5
JM
16768// If the compiler admits that it is not ready for C++11, why torture it?
16769// Hopefully, this will speed up the test.
3266f10b 16770
b686ecb5 16771#ifndef __cplusplus
3266f10b 16772
b686ecb5 16773#error "This is not a C++ compiler"
3266f10b 16774
b686ecb5 16775#elif __cplusplus < 201103L
05ea2a05 16776
b686ecb5 16777#error "This is not a C++11 compiler"
05ea2a05 16778
b686ecb5 16779#else
05ea2a05 16780
b686ecb5
JM
16781namespace cxx11
16782{
3266f10b 16783
b686ecb5
JM
16784 namespace test_static_assert
16785 {
05ea2a05 16786
b686ecb5
JM
16787 template <typename T>
16788 struct check
16789 {
16790 static_assert(sizeof(int) <= sizeof(T), "not big enough");
16791 };
05ea2a05 16792
b686ecb5 16793 }
05ea2a05 16794
b686ecb5
JM
16795 namespace test_final_override
16796 {
3266f10b 16797
b686ecb5
JM
16798 struct Base
16799 {
16800 virtual void f() {}
16801 };
05ea2a05 16802
b686ecb5
JM
16803 struct Derived : public Base
16804 {
16805 virtual void f() override {}
16806 };
3266f10b 16807
b686ecb5 16808 }
05ea2a05 16809
b686ecb5
JM
16810 namespace test_double_right_angle_brackets
16811 {
3266f10b 16812
b686ecb5
JM
16813 template < typename T >
16814 struct check {};
3266f10b 16815
b686ecb5
JM
16816 typedef check<void> single_type;
16817 typedef check<check<void>> double_type;
16818 typedef check<check<check<void>>> triple_type;
16819 typedef check<check<check<check<void>>>> quadruple_type;
3266f10b 16820
b686ecb5 16821 }
3266f10b 16822
b686ecb5
JM
16823 namespace test_decltype
16824 {
3266f10b 16825
b686ecb5
JM
16826 int
16827 f()
16828 {
16829 int a = 1;
16830 decltype(a) b = 2;
16831 return a + b;
16832 }
b2ceabe8 16833
b686ecb5 16834 }
b2ceabe8 16835
b686ecb5
JM
16836 namespace test_type_deduction
16837 {
b2ceabe8 16838
b686ecb5
JM
16839 template < typename T1, typename T2 >
16840 struct is_same
16841 {
16842 static const bool value = false;
16843 };
3266f10b 16844
b686ecb5
JM
16845 template < typename T >
16846 struct is_same<T, T>
16847 {
16848 static const bool value = true;
16849 };
05ea2a05 16850
b686ecb5
JM
16851 template < typename T1, typename T2 >
16852 auto
16853 add(T1 a1, T2 a2) -> decltype(a1 + a2)
16854 {
16855 return a1 + a2;
16856 }
05ea2a05 16857
b686ecb5
JM
16858 int
16859 test(const int c, volatile int v)
16860 {
16861 static_assert(is_same<int, decltype(0)>::value == true, "");
16862 static_assert(is_same<int, decltype(c)>::value == false, "");
16863 static_assert(is_same<int, decltype(v)>::value == false, "");
16864 auto ac = c;
16865 auto av = v;
16866 auto sumi = ac + av + 'x';
16867 auto sumf = ac + av + 1.0;
16868 static_assert(is_same<int, decltype(ac)>::value == true, "");
16869 static_assert(is_same<int, decltype(av)>::value == true, "");
16870 static_assert(is_same<int, decltype(sumi)>::value == true, "");
16871 static_assert(is_same<int, decltype(sumf)>::value == false, "");
16872 static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
16873 return (sumf > 0.0) ? sumi : add(c, v);
16874 }
3266f10b 16875
b686ecb5 16876 }
3266f10b 16877
b686ecb5
JM
16878 namespace test_noexcept
16879 {
3266f10b 16880
b686ecb5
JM
16881 int f() { return 0; }
16882 int g() noexcept { return 0; }
3266f10b 16883
b686ecb5
JM
16884 static_assert(noexcept(f()) == false, "");
16885 static_assert(noexcept(g()) == true, "");
3266f10b 16886
b686ecb5 16887 }
3266f10b 16888
b686ecb5
JM
16889 namespace test_constexpr
16890 {
3266f10b 16891
b686ecb5
JM
16892 template < typename CharT >
16893 unsigned long constexpr
16894 strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
16895 {
16896 return *s ? strlen_c_r(s + 1, acc + 1) : acc;
16897 }
3266f10b 16898
b686ecb5
JM
16899 template < typename CharT >
16900 unsigned long constexpr
16901 strlen_c(const CharT *const s) noexcept
16902 {
16903 return strlen_c_r(s, 0UL);
16904 }
3266f10b 16905
b686ecb5
JM
16906 static_assert(strlen_c("") == 0UL, "");
16907 static_assert(strlen_c("1") == 1UL, "");
16908 static_assert(strlen_c("example") == 7UL, "");
16909 static_assert(strlen_c("another\0example") == 7UL, "");
3266f10b 16910
b686ecb5 16911 }
3266f10b 16912
b686ecb5
JM
16913 namespace test_rvalue_references
16914 {
5e030278 16915
b686ecb5
JM
16916 template < int N >
16917 struct answer
16918 {
16919 static constexpr int value = N;
16920 };
5e030278 16921
b686ecb5
JM
16922 answer<1> f(int&) { return answer<1>(); }
16923 answer<2> f(const int&) { return answer<2>(); }
16924 answer<3> f(int&&) { return answer<3>(); }
5e030278 16925
b686ecb5
JM
16926 void
16927 test()
16928 {
16929 int i = 0;
16930 const int c = 0;
16931 static_assert(decltype(f(i))::value == 1, "");
16932 static_assert(decltype(f(c))::value == 2, "");
16933 static_assert(decltype(f(0))::value == 3, "");
16934 }
05ea2a05 16935
b686ecb5 16936 }
05ea2a05 16937
b686ecb5
JM
16938 namespace test_uniform_initialization
16939 {
05ea2a05 16940
b686ecb5
JM
16941 struct test
16942 {
16943 static const int zero {};
16944 static const int one {1};
16945 };
05ea2a05 16946
b686ecb5
JM
16947 static_assert(test::zero == 0, "");
16948 static_assert(test::one == 1, "");
5e030278 16949
b686ecb5 16950 }
5e030278 16951
b686ecb5
JM
16952 namespace test_lambdas
16953 {
5e030278 16954
b686ecb5
JM
16955 void
16956 test1()
16957 {
16958 auto lambda1 = [](){};
16959 auto lambda2 = lambda1;
16960 lambda1();
16961 lambda2();
16962 }
5e030278 16963
b686ecb5
JM
16964 int
16965 test2()
16966 {
16967 auto a = [](int i, int j){ return i + j; }(1, 2);
16968 auto b = []() -> int { return '0'; }();
16969 auto c = [=](){ return a + b; }();
16970 auto d = [&](){ return c; }();
16971 auto e = [a, &b](int x) mutable {
16972 const auto identity = [](int y){ return y; };
16973 for (auto i = 0; i < a; ++i)
16974 a += b--;
16975 return x + identity(a + b);
16976 }(0);
16977 return a + b + c + d + e;
16978 }
5e030278 16979
b686ecb5
JM
16980 int
16981 test3()
16982 {
16983 const auto nullary = [](){ return 0; };
16984 const auto unary = [](int x){ return x; };
16985 using nullary_t = decltype(nullary);
16986 using unary_t = decltype(unary);
16987 const auto higher1st = [](nullary_t f){ return f(); };
16988 const auto higher2nd = [unary](nullary_t f1){
16989 return [unary, f1](unary_t f2){ return f2(unary(f1())); };
16990 };
16991 return higher1st(nullary) + higher2nd(nullary)(unary);
16992 }
5e030278 16993
b686ecb5 16994 }
5e030278 16995
b686ecb5
JM
16996 namespace test_variadic_templates
16997 {
5e030278 16998
b686ecb5
JM
16999 template <int...>
17000 struct sum;
5e030278 17001
b686ecb5
JM
17002 template <int N0, int... N1toN>
17003 struct sum<N0, N1toN...>
17004 {
17005 static constexpr auto value = N0 + sum<N1toN...>::value;
17006 };
5e030278 17007
b686ecb5
JM
17008 template <>
17009 struct sum<>
17010 {
17011 static constexpr auto value = 0;
17012 };
5e030278 17013
b686ecb5
JM
17014 static_assert(sum<>::value == 0, "");
17015 static_assert(sum<1>::value == 1, "");
17016 static_assert(sum<23>::value == 23, "");
17017 static_assert(sum<1, 2>::value == 3, "");
17018 static_assert(sum<5, 5, 11>::value == 21, "");
17019 static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
5e030278 17020
b686ecb5 17021 }
5e030278 17022
b686ecb5
JM
17023 // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
17024 // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
17025 // because of this.
17026 namespace test_template_alias_sfinae
17027 {
5e030278 17028
b686ecb5 17029 struct foo {};
5e030278 17030
b686ecb5
JM
17031 template<typename T>
17032 using member = typename T::member_type;
5e030278 17033
b686ecb5
JM
17034 template<typename T>
17035 void func(...) {}
5e030278 17036
b686ecb5
JM
17037 template<typename T>
17038 void func(member<T>*) {}
5e030278 17039
b686ecb5 17040 void test();
5e030278 17041
b686ecb5 17042 void test() { func<foo>(0); }
5e030278 17043
b686ecb5 17044 }
5e030278 17045
b686ecb5 17046} // namespace cxx11
5e030278 17047
b686ecb5 17048#endif // __cplusplus >= 201103L
5e030278 17049
5e030278 17050
5e030278 17051
5e030278 17052_ACEOF
05ea2a05 17053if ac_fn_cxx_try_compile "$LINENO"; then :
b686ecb5 17054 eval $cachevar=yes
05ea2a05 17055else
b686ecb5 17056 eval $cachevar=no
5e030278 17057fi
05ea2a05 17058rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
b686ecb5 17059 CXX="$ac_save_CXX"
05ea2a05 17060fi
b686ecb5
JM
17061eval ac_res=\$$cachevar
17062 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
17063$as_echo "$ac_res" >&6; }
17064 if eval test x\$$cachevar = xyes; then
17065 CXX_DIALECT="$switch"
17066 CXX="$CXX $switch"
17067 if test -n "$CXXCPP" ; then
17068 CXXCPP="$CXXCPP $switch"
17069 fi
17070 ac_success=yes
17071 break
17072 fi
17073 done
05ea2a05 17074 fi
5e030278 17075
b686ecb5
JM
17076 if test x$ac_success = xno; then
17077 for alternative in ${ax_cxx_compile_alternatives}; do
17078 for switch in -std=c++${alternative} +std=c++${alternative} "-h std=c++${alternative}"; do
17079 cachevar=`$as_echo "ax_cv_cxx_compile_cxx11_$switch" | $as_tr_sh`
17080 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features with $switch" >&5
17081$as_echo_n "checking whether $CXX supports C++11 features with $switch... " >&6; }
17082if eval \${$cachevar+:} false; then :
05ea2a05
TT
17083 $as_echo_n "(cached) " >&6
17084else
b686ecb5
JM
17085 ac_save_CXX="$CXX"
17086 CXX="$CXX $switch"
17087 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
05ea2a05 17088/* end confdefs.h. */
b9442ec1 17089
b9442ec1 17090
b686ecb5
JM
17091// If the compiler admits that it is not ready for C++11, why torture it?
17092// Hopefully, this will speed up the test.
b9442ec1 17093
b686ecb5 17094#ifndef __cplusplus
5e030278 17095
b686ecb5 17096#error "This is not a C++ compiler"
5e030278 17097
b686ecb5 17098#elif __cplusplus < 201103L
05ea2a05 17099
b686ecb5 17100#error "This is not a C++11 compiler"
05ea2a05 17101
b686ecb5 17102#else
05ea2a05 17103
b686ecb5
JM
17104namespace cxx11
17105{
05ea2a05 17106
b686ecb5
JM
17107 namespace test_static_assert
17108 {
5e030278 17109
b686ecb5
JM
17110 template <typename T>
17111 struct check
17112 {
17113 static_assert(sizeof(int) <= sizeof(T), "not big enough");
17114 };
5e030278 17115
b686ecb5 17116 }
5e030278 17117
b686ecb5
JM
17118 namespace test_final_override
17119 {
5e030278 17120
b686ecb5
JM
17121 struct Base
17122 {
17123 virtual void f() {}
17124 };
5e030278 17125
b686ecb5
JM
17126 struct Derived : public Base
17127 {
17128 virtual void f() override {}
17129 };
5e030278 17130
b686ecb5 17131 }
5e030278 17132
b686ecb5
JM
17133 namespace test_double_right_angle_brackets
17134 {
5e030278 17135
b686ecb5
JM
17136 template < typename T >
17137 struct check {};
5e030278 17138
b686ecb5
JM
17139 typedef check<void> single_type;
17140 typedef check<check<void>> double_type;
17141 typedef check<check<check<void>>> triple_type;
17142 typedef check<check<check<check<void>>>> quadruple_type;
5e030278 17143
b686ecb5 17144 }
5e030278 17145
b686ecb5
JM
17146 namespace test_decltype
17147 {
5e030278 17148
b686ecb5
JM
17149 int
17150 f()
17151 {
17152 int a = 1;
17153 decltype(a) b = 2;
17154 return a + b;
17155 }
5e030278 17156
b686ecb5 17157 }
5e030278 17158
b686ecb5
JM
17159 namespace test_type_deduction
17160 {
5e030278 17161
b686ecb5
JM
17162 template < typename T1, typename T2 >
17163 struct is_same
17164 {
17165 static const bool value = false;
17166 };
5e030278 17167
b686ecb5
JM
17168 template < typename T >
17169 struct is_same<T, T>
17170 {
17171 static const bool value = true;
17172 };
5e030278 17173
b686ecb5
JM
17174 template < typename T1, typename T2 >
17175 auto
17176 add(T1 a1, T2 a2) -> decltype(a1 + a2)
17177 {
17178 return a1 + a2;
17179 }
5e030278 17180
b686ecb5
JM
17181 int
17182 test(const int c, volatile int v)
17183 {
17184 static_assert(is_same<int, decltype(0)>::value == true, "");
17185 static_assert(is_same<int, decltype(c)>::value == false, "");
17186 static_assert(is_same<int, decltype(v)>::value == false, "");
17187 auto ac = c;
17188 auto av = v;
17189 auto sumi = ac + av + 'x';
17190 auto sumf = ac + av + 1.0;
17191 static_assert(is_same<int, decltype(ac)>::value == true, "");
17192 static_assert(is_same<int, decltype(av)>::value == true, "");
17193 static_assert(is_same<int, decltype(sumi)>::value == true, "");
17194 static_assert(is_same<int, decltype(sumf)>::value == false, "");
17195 static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
17196 return (sumf > 0.0) ? sumi : add(c, v);
17197 }
5e030278 17198
b686ecb5 17199 }
5e030278 17200
b686ecb5
JM
17201 namespace test_noexcept
17202 {
5e030278 17203
b686ecb5
JM
17204 int f() { return 0; }
17205 int g() noexcept { return 0; }
5e030278 17206
b686ecb5
JM
17207 static_assert(noexcept(f()) == false, "");
17208 static_assert(noexcept(g()) == true, "");
9f1528a1 17209
b686ecb5 17210 }
9f1528a1 17211
b686ecb5
JM
17212 namespace test_constexpr
17213 {
9f1528a1 17214
b686ecb5
JM
17215 template < typename CharT >
17216 unsigned long constexpr
17217 strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
17218 {
17219 return *s ? strlen_c_r(s + 1, acc + 1) : acc;
17220 }
17221
17222 template < typename CharT >
17223 unsigned long constexpr
17224 strlen_c(const CharT *const s) noexcept
17225 {
17226 return strlen_c_r(s, 0UL);
17227 }
17228
17229 static_assert(strlen_c("") == 0UL, "");
17230 static_assert(strlen_c("1") == 1UL, "");
17231 static_assert(strlen_c("example") == 7UL, "");
17232 static_assert(strlen_c("another\0example") == 7UL, "");
17233
17234 }
17235
17236 namespace test_rvalue_references
17237 {
17238
17239 template < int N >
17240 struct answer
17241 {
17242 static constexpr int value = N;
17243 };
17244
17245 answer<1> f(int&) { return answer<1>(); }
17246 answer<2> f(const int&) { return answer<2>(); }
17247 answer<3> f(int&&) { return answer<3>(); }
17248
17249 void
17250 test()
17251 {
17252 int i = 0;
17253 const int c = 0;
17254 static_assert(decltype(f(i))::value == 1, "");
17255 static_assert(decltype(f(c))::value == 2, "");
17256 static_assert(decltype(f(0))::value == 3, "");
17257 }
17258
17259 }
17260
17261 namespace test_uniform_initialization
17262 {
17263
17264 struct test
17265 {
17266 static const int zero {};
17267 static const int one {1};
17268 };
17269
17270 static_assert(test::zero == 0, "");
17271 static_assert(test::one == 1, "");
17272
17273 }
17274
17275 namespace test_lambdas
17276 {
17277
17278 void
17279 test1()
17280 {
17281 auto lambda1 = [](){};
17282 auto lambda2 = lambda1;
17283 lambda1();
17284 lambda2();
17285 }
17286
17287 int
17288 test2()
17289 {
17290 auto a = [](int i, int j){ return i + j; }(1, 2);
17291 auto b = []() -> int { return '0'; }();
17292 auto c = [=](){ return a + b; }();
17293 auto d = [&](){ return c; }();
17294 auto e = [a, &b](int x) mutable {
17295 const auto identity = [](int y){ return y; };
17296 for (auto i = 0; i < a; ++i)
17297 a += b--;
17298 return x + identity(a + b);
17299 }(0);
17300 return a + b + c + d + e;
17301 }
17302
17303 int
17304 test3()
17305 {
17306 const auto nullary = [](){ return 0; };
17307 const auto unary = [](int x){ return x; };
17308 using nullary_t = decltype(nullary);
17309 using unary_t = decltype(unary);
17310 const auto higher1st = [](nullary_t f){ return f(); };
17311 const auto higher2nd = [unary](nullary_t f1){
17312 return [unary, f1](unary_t f2){ return f2(unary(f1())); };
17313 };
17314 return higher1st(nullary) + higher2nd(nullary)(unary);
17315 }
17316
17317 }
17318
17319 namespace test_variadic_templates
17320 {
17321
17322 template <int...>
17323 struct sum;
17324
17325 template <int N0, int... N1toN>
17326 struct sum<N0, N1toN...>
17327 {
17328 static constexpr auto value = N0 + sum<N1toN...>::value;
17329 };
17330
17331 template <>
17332 struct sum<>
17333 {
17334 static constexpr auto value = 0;
17335 };
17336
17337 static_assert(sum<>::value == 0, "");
17338 static_assert(sum<1>::value == 1, "");
17339 static_assert(sum<23>::value == 23, "");
17340 static_assert(sum<1, 2>::value == 3, "");
17341 static_assert(sum<5, 5, 11>::value == 21, "");
17342 static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
17343
17344 }
17345
17346 // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
17347 // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
17348 // because of this.
17349 namespace test_template_alias_sfinae
17350 {
17351
17352 struct foo {};
17353
17354 template<typename T>
17355 using member = typename T::member_type;
17356
17357 template<typename T>
17358 void func(...) {}
17359
17360 template<typename T>
17361 void func(member<T>*) {}
17362
17363 void test();
17364
17365 void test() { func<foo>(0); }
17366
17367 }
17368
17369} // namespace cxx11
17370
17371#endif // __cplusplus >= 201103L
17372
17373
17374
17375_ACEOF
17376if ac_fn_cxx_try_compile "$LINENO"; then :
17377 eval $cachevar=yes
17378else
17379 eval $cachevar=no
17380fi
17381rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17382 CXX="$ac_save_CXX"
17383fi
17384eval ac_res=\$$cachevar
17385 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
17386$as_echo "$ac_res" >&6; }
17387 if eval test x\$$cachevar = xyes; then
17388 CXX_DIALECT="$switch"
17389 CXX="$CXX $switch"
17390 if test -n "$CXXCPP" ; then
17391 CXXCPP="$CXXCPP $switch"
17392 fi
17393 ac_success=yes
17394 break
17395 fi
17396 done
17397 if test x$ac_success = xyes; then
17398 break
17399 fi
17400 done
17401 fi
17402 ac_ext=c
17403ac_cpp='$CPP $CPPFLAGS'
17404ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
17405ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
17406ac_compiler_gnu=$ac_cv_c_compiler_gnu
17407
17408 if test x$ax_cxx_compile_cxx11_required = xtrue; then
17409 if test x$ac_success = xno; then
17410 as_fn_error $? "*** A compiler with support for C++11 language features is required." "$LINENO" 5
17411 fi
17412 fi
17413 if test x$ac_success = xno; then
17414 HAVE_CXX11=0
17415 { $as_echo "$as_me:${as_lineno-$LINENO}: No compiler with C++11 support was found" >&5
17416$as_echo "$as_me: No compiler with C++11 support was found" >&6;}
17417 else
17418 HAVE_CXX11=1
17419
17420$as_echo "#define HAVE_CXX11 1" >>confdefs.h
17421
17422 fi
17423
17424
17425
17426
17427# Dependency checking.
17428rm -rf .tst 2>/dev/null
17429mkdir .tst 2>/dev/null
17430if test -d .tst; then
17431 am__leading_dot=.
17432else
17433 am__leading_dot=_
17434fi
17435rmdir .tst 2>/dev/null
17436
17437DEPDIR="${am__leading_dot}deps"
17438
17439ac_config_commands="$ac_config_commands depdir"
17440
17441
17442depcc="$CC" am_compiler_list=
17443
17444am_depcomp=$ac_aux_dir/depcomp
17445{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
17446$as_echo_n "checking dependency style of $depcc... " >&6; }
17447if ${am_cv_CC_dependencies_compiler_type+:} false; then :
17448 $as_echo_n "(cached) " >&6
17449else
17450 if test -f "$am_depcomp"; then
17451 # We make a subdir and do the tests there. Otherwise we can end up
17452 # making bogus files that we don't know about and never remove. For
17453 # instance it was reported that on HP-UX the gcc test will end up
17454 # making a dummy file named `D' -- because `-MD' means `put the output
17455 # in D'.
17456 mkdir conftest.dir
17457 # Copy depcomp to subdir because otherwise we won't find it if we're
17458 # using a relative directory.
17459 cp "$am_depcomp" conftest.dir
17460 cd conftest.dir
17461 # We will build objects and dependencies in a subdirectory because
17462 # it helps to detect inapplicable dependency modes. For instance
17463 # both Tru64's cc and ICC support -MD to output dependencies as a
17464 # side effect of compilation, but ICC will put the dependencies in
17465 # the current directory while Tru64 will put them in the object
17466 # directory.
17467 mkdir sub
17468
17469 am_cv_CC_dependencies_compiler_type=none
17470 if test "$am_compiler_list" = ""; then
17471 am_compiler_list=`sed -n 's/^\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
17472 fi
17473 for depmode in $am_compiler_list; do
17474 if test $depmode = none; then break; fi
17475
17476 $as_echo "$as_me:$LINENO: trying $depmode" >&5
17477 # Setup a source with many dependencies, because some compilers
17478 # like to wrap large dependency lists on column 80 (with \), and
17479 # we should not choose a depcomp mode which is confused by this.
17480 #
17481 # We need to recreate these files for each test, as the compiler may
17482 # overwrite some of them when testing with obscure command lines.
17483 # This happens at least with the AIX C compiler.
17484 : > sub/conftest.c
17485 for i in 1 2 3 4 5 6; do
17486 echo '#include "conftst'$i'.h"' >> sub/conftest.c
17487 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
17488 # Solaris 8's {/usr,}/bin/sh.
17489 touch sub/conftst$i.h
17490 done
17491 echo "include sub/conftest.Po" > confmf
17492
17493 # We check with `-c' and `-o' for the sake of the "dashmstdout"
17494 # mode. It turns out that the SunPro C++ compiler does not properly
17495 # handle `-M -o', and we need to detect this.
17496 depcmd="depmode=$depmode \
17497 source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
17498 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
17499 $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c"
17500 echo "| $depcmd" | sed -e 's/ */ /g' >&5
17501 if env $depcmd > conftest.err 2>&1 &&
17502 grep sub/conftst6.h sub/conftest.Po >>conftest.err 2>&1 &&
17503 grep sub/conftest.${OBJEXT-o} sub/conftest.Po >>conftest.err 2>&1 &&
17504 ${MAKE-make} -s -f confmf >>conftest.err 2>&1; then
17505 # icc doesn't choke on unknown options, it will just issue warnings
17506 # or remarks (even with -Werror). So we grep stderr for any message
17507 # that says an option was ignored or not supported.
17508 # When given -MP, icc 7.0 and 7.1 complain thusly:
17509 # icc: Command line warning: ignoring option '-M'; no argument required
17510 # The diagnosis changed in icc 8.0:
17511 # icc: Command line remark: option '-MP' not supported
17512 if (grep 'ignoring option' conftest.err ||
17513 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
17514 am_cv_CC_dependencies_compiler_type=$depmode
17515 $as_echo "$as_me:$LINENO: success" >&5
17516 break
17517 fi
17518 fi
17519 $as_echo "$as_me:$LINENO: failure, diagnostics are:" >&5
17520 sed -e 's/^/| /' < conftest.err >&5
17521 done
17522
17523 cd ..
17524 rm -rf conftest.dir
17525else
17526 am_cv_CC_dependencies_compiler_type=none
17527fi
17528
17529fi
17530{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
17531$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
17532if test x${am_cv_CC_dependencies_compiler_type-none} = xnone
17533then as_fn_error $? "no usable dependency style found" "$LINENO" 5
17534else CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
17535
17536fi
17537
17538
18b4d073
SM
17539# Since the first call to PKG_CHECK_MODULES may not happen (is guarded by
17540# a condition), we must call PKG_PROG_PKG_CONFIG explicitly to probe for
17541# pkg-config.
17542
17543
17544
17545
17546
17547
17548
17549if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
17550 if test -n "$ac_tool_prefix"; then
17551 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
17552set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
17553{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17554$as_echo_n "checking for $ac_word... " >&6; }
17555if ${ac_cv_path_PKG_CONFIG+:} false; then :
17556 $as_echo_n "(cached) " >&6
17557else
17558 case $PKG_CONFIG in
17559 [\\/]* | ?:[\\/]*)
17560 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
17561 ;;
17562 *)
17563 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17564for as_dir in $PATH
17565do
17566 IFS=$as_save_IFS
17567 test -z "$as_dir" && as_dir=.
17568 for ac_exec_ext in '' $ac_executable_extensions; do
17569 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17570 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
17571 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17572 break 2
17573 fi
17574done
17575 done
17576IFS=$as_save_IFS
17577
17578 ;;
17579esac
17580fi
17581PKG_CONFIG=$ac_cv_path_PKG_CONFIG
17582if test -n "$PKG_CONFIG"; then
17583 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
17584$as_echo "$PKG_CONFIG" >&6; }
17585else
17586 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17587$as_echo "no" >&6; }
17588fi
17589
17590
17591fi
17592if test -z "$ac_cv_path_PKG_CONFIG"; then
17593 ac_pt_PKG_CONFIG=$PKG_CONFIG
17594 # Extract the first word of "pkg-config", so it can be a program name with args.
17595set dummy pkg-config; ac_word=$2
17596{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17597$as_echo_n "checking for $ac_word... " >&6; }
17598if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then :
17599 $as_echo_n "(cached) " >&6
17600else
17601 case $ac_pt_PKG_CONFIG in
17602 [\\/]* | ?:[\\/]*)
17603 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
17604 ;;
17605 *)
17606 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17607for as_dir in $PATH
17608do
17609 IFS=$as_save_IFS
17610 test -z "$as_dir" && as_dir=.
17611 for ac_exec_ext in '' $ac_executable_extensions; do
17612 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17613 ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
17614 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17615 break 2
17616 fi
17617done
17618 done
17619IFS=$as_save_IFS
17620
17621 ;;
17622esac
17623fi
17624ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
17625if test -n "$ac_pt_PKG_CONFIG"; then
17626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
17627$as_echo "$ac_pt_PKG_CONFIG" >&6; }
17628else
17629 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17630$as_echo "no" >&6; }
17631fi
17632
17633 if test "x$ac_pt_PKG_CONFIG" = x; then
17634 PKG_CONFIG=""
17635 else
17636 case $cross_compiling:$ac_tool_warned in
17637yes:)
17638{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
17639$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
17640ac_tool_warned=yes ;;
17641esac
17642 PKG_CONFIG=$ac_pt_PKG_CONFIG
17643 fi
17644else
17645 PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
17646fi
17647
17648fi
17649if test -n "$PKG_CONFIG"; then
17650 _pkg_min_version=0.9.0
17651 { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
17652$as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; }
17653 if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
17654 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17655$as_echo "yes" >&6; }
17656 else
17657 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17658$as_echo "no" >&6; }
17659 PKG_CONFIG=""
17660 fi
17661fi
17662
b686ecb5
JM
17663
17664CONFIG_OBS=
17665CONFIG_DEPS=
17666CONFIG_SRCS=
17667ENABLE_CFLAGS=
17668
17669CONFIG_ALL=
17670CONFIG_CLEAN=
17671CONFIG_INSTALL=
17672CONFIG_UNINSTALL=
17673
17674# If we haven't got the data from the intl directory,
17675# assume NLS is disabled.
17676USE_NLS=no
17677LIBINTL=
17678LIBINTL_DEP=
17679INCINTL=
17680XGETTEXT=
17681GMSGFMT=
17682POSUB=
17683
17684if test -f ../intl/config.intl; then
17685 . ../intl/config.intl
17686fi
17687{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5
17688$as_echo_n "checking whether NLS is requested... " >&6; }
17689if test x"$USE_NLS" != xyes; then
17690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17691$as_echo "no" >&6; }
17692else
17693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17694$as_echo "yes" >&6; }
17695
17696$as_echo "#define ENABLE_NLS 1" >>confdefs.h
17697
17698
17699 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for catalogs to be installed" >&5
17700$as_echo_n "checking for catalogs to be installed... " >&6; }
17701 # Look for .po and .gmo files in the source directory.
17702 CATALOGS=
17703 XLINGUAS=
17704 for cat in $srcdir/po/*.gmo $srcdir/po/*.po; do
17705 # If there aren't any .gmo files the shell will give us the
17706 # literal string "../path/to/srcdir/po/*.gmo" which has to be
17707 # weeded out.
17708 case "$cat" in *\**)
17709 continue;;
17710 esac
17711 # The quadruple backslash is collapsed to a double backslash
17712 # by the backticks, then collapsed again by the double quotes,
17713 # leaving us with one backslash in the sed expression (right
17714 # before the dot that mustn't act as a wildcard).
17715 cat=`echo $cat | sed -e "s!$srcdir/po/!!" -e "s!\\\\.po!.gmo!"`
17716 lang=`echo $cat | sed -e "s!\\\\.gmo!!"`
17717 # The user is allowed to set LINGUAS to a list of languages to
17718 # install catalogs for. If it's empty that means "all of them."
17719 if test "x$LINGUAS" = x; then
17720 CATALOGS="$CATALOGS $cat"
17721 XLINGUAS="$XLINGUAS $lang"
17722 else
17723 case "$LINGUAS" in *$lang*)
17724 CATALOGS="$CATALOGS $cat"
17725 XLINGUAS="$XLINGUAS $lang"
17726 ;;
17727 esac
17728 fi
17729 done
17730 LINGUAS="$XLINGUAS"
17731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINGUAS" >&5
17732$as_echo "$LINGUAS" >&6; }
17733
17734
17735 DATADIRNAME=share
17736
17737 INSTOBJEXT=.mo
17738
17739 GENCAT=gencat
17740
17741 CATOBJEXT=.gmo
17742
17743fi
17744
17745localedir='${datadir}/locale'
17746
17747
17748if test x"$USE_NLS" = xyes; then
17749 CONFIG_ALL="$CONFIG_ALL all-po"
17750 CONFIG_CLEAN="$CONFIG_CLEAN clean-po"
17751 CONFIG_INSTALL="$CONFIG_INSTALL install-po"
17752 CONFIG_UNINSTALL="$CONFIG_UNINSTALL uninstall-po"
17753fi
17754
17755PACKAGE=gdb
17756
17757cat >>confdefs.h <<_ACEOF
17758#define PACKAGE "$PACKAGE"
17759_ACEOF
17760
17761
17762
17763# We never need to detect it in this sub-configure.
17764# But preserve it for config.status --recheck.
17765
17766
17767
17768MAKEINFO_EXTRA_FLAGS=""
17769{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $MAKEINFO supports @click" >&5
17770$as_echo_n "checking whether $MAKEINFO supports @click... " >&6; }
17771if ${gdb_cv_have_makeinfo_click+:} false; then :
17772 $as_echo_n "(cached) " >&6
17773else
17774 echo '@clicksequence{a @click{} b}' >conftest.texinfo
17775 if eval "$MAKEINFO conftest.texinfo >&5 2>&5"; then
17776 gdb_cv_have_makeinfo_click=yes
17777 else
17778 gdb_cv_have_makeinfo_click=no
17779 fi
17780fi
17781{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_makeinfo_click" >&5
17782$as_echo "$gdb_cv_have_makeinfo_click" >&6; }
17783if test x"$gdb_cv_have_makeinfo_click" = xyes; then
17784 MAKEINFO_EXTRA_FLAGS="$MAKEINFO_EXTRA_FLAGS -DHAVE_MAKEINFO_CLICK"
17785fi
17786
17787
17788
17789
17790# Check whether --with-separate-debug-dir was given.
17791if test "${with_separate_debug_dir+set}" = set; then :
17792 withval=$with_separate_debug_dir;
17793 DEBUGDIR=$withval
17794else
17795 DEBUGDIR=${libdir}/debug
17796fi
17797
17798
17799 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
17800 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
17801 ac_define_dir=`eval echo $DEBUGDIR`
17802 ac_define_dir=`eval echo $ac_define_dir`
17803
17804cat >>confdefs.h <<_ACEOF
17805#define DEBUGDIR "$ac_define_dir"
17806_ACEOF
17807
17808
17809
17810
17811 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
17812 if test "x$prefix" = xNONE; then
17813 test_prefix=/usr/local
17814 else
17815 test_prefix=$prefix
17816 fi
17817 else
17818 test_prefix=$exec_prefix
17819 fi
17820 value=0
17821 case ${ac_define_dir} in
17822 "${test_prefix}"|"${test_prefix}/"*|\
17823 '${exec_prefix}'|'${exec_prefix}/'*)
17824 value=1
17825 ;;
17826 esac
17827
17828cat >>confdefs.h <<_ACEOF
17829#define DEBUGDIR_RELOCATABLE $value
17830_ACEOF
17831
17832
17833
17834
17835# We can't pass paths as command line arguments.
17836# Mingw32 tries to be clever and will convert the paths for us.
17837# For example -DBINDIR="/usr/local/bin" passed on the command line may get
17838# converted to -DBINDIR="E:/msys/mingw32/msys/1.0/local/bin".
17839# This breaks GDB's relocatable path conversions since paths passed in
17840# config.h would not get so translated, the path prefixes no longer match.
17841
17842 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
17843 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
17844 ac_define_dir=`eval echo $bindir`
17845 ac_define_dir=`eval echo $ac_define_dir`
17846
17847cat >>confdefs.h <<_ACEOF
17848#define BINDIR "$ac_define_dir"
17849_ACEOF
17850
17851
17852
17853# GDB's datadir relocation
17854
17855
17856
17857# Check whether --with-gdb-datadir was given.
17858if test "${with_gdb_datadir+set}" = set; then :
17859 withval=$with_gdb_datadir;
17860 GDB_DATADIR=$withval
17861else
17862 GDB_DATADIR=${datadir}/gdb
17863fi
17864
17865
17866 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
17867 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
17868 ac_define_dir=`eval echo $GDB_DATADIR`
17869 ac_define_dir=`eval echo $ac_define_dir`
17870
17871cat >>confdefs.h <<_ACEOF
17872#define GDB_DATADIR "$ac_define_dir"
17873_ACEOF
17874
17875
17876
17877
17878 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
17879 if test "x$prefix" = xNONE; then
17880 test_prefix=/usr/local
17881 else
17882 test_prefix=$prefix
17883 fi
17884 else
17885 test_prefix=$exec_prefix
17886 fi
17887 value=0
17888 case ${ac_define_dir} in
17889 "${test_prefix}"|"${test_prefix}/"*|\
17890 '${exec_prefix}'|'${exec_prefix}/'*)
17891 value=1
17892 ;;
17893 esac
17894
17895cat >>confdefs.h <<_ACEOF
17896#define GDB_DATADIR_RELOCATABLE $value
17897_ACEOF
17898
17899
17900
17901
17902
17903# Check whether --with-relocated-sources was given.
17904if test "${with_relocated_sources+set}" = set; then :
17905 withval=$with_relocated_sources; reloc_srcdir="${withval}"
17906
17907 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
17908 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
17909 ac_define_dir=`eval echo $reloc_srcdir`
17910 ac_define_dir=`eval echo $ac_define_dir`
17911
17912cat >>confdefs.h <<_ACEOF
17913#define RELOC_SRCDIR "$ac_define_dir"
17914_ACEOF
17915
17916
17917
17918fi
17919
17920
17921{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for default auto-load directory" >&5
17922$as_echo_n "checking for default auto-load directory... " >&6; }
17923
17924# Check whether --with-auto-load-dir was given.
17925if test "${with_auto_load_dir+set}" = set; then :
17926 withval=$with_auto_load_dir;
17927else
17928 with_auto_load_dir='$debugdir:$datadir/auto-load'
17929fi
17930
17931escape_dir=`echo $with_auto_load_dir | sed -e 's/[$]datadir\>/\\\\\\\\\\\\&/g' -e 's/[$]debugdir\>/\\\\\\\\\\\\&/g'`
17932
17933 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
17934 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
17935 ac_define_dir=`eval echo $escape_dir`
17936 ac_define_dir=`eval echo $ac_define_dir`
17937
17938cat >>confdefs.h <<_ACEOF
17939#define AUTO_LOAD_DIR "$ac_define_dir"
17940_ACEOF
17941
17942
17943{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_auto_load_dir" >&5
17944$as_echo "$with_auto_load_dir" >&6; }
17945
17946{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for default auto-load safe-path" >&5
17947$as_echo_n "checking for default auto-load safe-path... " >&6; }
17948
17949# Check whether --with-auto-load-safe-path was given.
17950if test "${with_auto_load_safe_path+set}" = set; then :
17951 withval=$with_auto_load_safe_path; if test "$with_auto_load_safe_path" = "no"; then
17952 with_auto_load_safe_path="/"
17953 fi
17954else
17955 with_auto_load_safe_path="$with_auto_load_dir"
17956fi
17957
17958escape_dir=`echo $with_auto_load_safe_path | sed -e 's/[$]datadir\>/\\\\\\\\\\\\&/g' -e 's/[$]debugdir\>/\\\\\\\\\\\\&/g'`
17959
17960 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
17961 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
17962 ac_define_dir=`eval echo $escape_dir`
17963 ac_define_dir=`eval echo $ac_define_dir`
17964
17965cat >>confdefs.h <<_ACEOF
17966#define AUTO_LOAD_SAFE_PATH "$ac_define_dir"
17967_ACEOF
17968
17969
17970{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_auto_load_safe_path" >&5
17971$as_echo "$with_auto_load_safe_path" >&6; }
17972
17973
17974
17975subdirs="$subdirs testsuite"
17976
17977
17978# Check whether to support alternative target configurations
17979# Check whether --enable-targets was given.
17980if test "${enable_targets+set}" = set; then :
17981 enableval=$enable_targets; case "${enableval}" in
17982 yes | "") as_fn_error $? "enable-targets option must specify target names or 'all'" "$LINENO" 5
17983 ;;
17984 no) enable_targets= ;;
17985 *) enable_targets=$enableval ;;
17986esac
17987fi
17988
17989
17990# Check whether --enable-64-bit-bfd was given.
17991if test "${enable_64_bit_bfd+set}" = set; then :
17992 enableval=$enable_64_bit_bfd; case $enableval in #(
17993 yes|no) :
17994 ;; #(
17995 *) :
17996 as_fn_error $? "bad value ${enableval} for 64-bit-bfd option" "$LINENO" 5 ;; #(
17997 *) :
17998 ;;
17999esac
18000else
18001 enable_64_bit_bfd=no
18002fi
18003
18004
18005if test "x$enable_64_bit_bfd" = "xno"; then :
18006 # The cast to long int works around a bug in the HP C Compiler
18007# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
18008# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
18009# This bug is HP SR number 8606223364.
18010{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of void *" >&5
18011$as_echo_n "checking size of void *... " >&6; }
18012if ${ac_cv_sizeof_void_p+:} false; then :
18013 $as_echo_n "(cached) " >&6
18014else
18015 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (void *))" "ac_cv_sizeof_void_p" "$ac_includes_default"; then :
18016
18017else
18018 if test "$ac_cv_type_void_p" = yes; then
18019 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
18020$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18021as_fn_error 77 "cannot compute sizeof (void *)
18022See \`config.log' for more details" "$LINENO" 5; }
18023 else
18024 ac_cv_sizeof_void_p=0
18025 fi
18026fi
18027
18028fi
18029{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_void_p" >&5
18030$as_echo "$ac_cv_sizeof_void_p" >&6; }
18031
18032
18033
18034cat >>confdefs.h <<_ACEOF
18035#define SIZEOF_VOID_P $ac_cv_sizeof_void_p
18036_ACEOF
18037
18038
18039 if test "x$ac_cv_sizeof_void_p" = "x8"; then :
18040 enable_64_bit_bfd=yes
18041fi
18042
18043fi
18044
18045 if test "x$enable_64_bit_bfd" = "xyes"; then
18046 ENABLE_BFD_64_BIT_TRUE=
18047 ENABLE_BFD_64_BIT_FALSE='#'
18048else
18049 ENABLE_BFD_64_BIT_TRUE='#'
18050 ENABLE_BFD_64_BIT_FALSE=
18051fi
18052
18053
18054
18055# Provide defaults for some variables set by the per-host and per-target
18056# configuration.
18057gdb_host_obs=posix-hdep.o
18058
18059if test "${target}" = "${host}"; then
18060 gdb_native=yes
18061else
18062 gdb_native=no
18063fi
18064
18065. $srcdir/configure.host
18066
18067# Accumulate some settings from configure.tgt over all enabled targets
18068
18069TARGET_OBS=
18070all_targets=
18071HAVE_NATIVE_GCORE_TARGET=
18072
18073for targ_alias in `echo $target_alias $enable_targets | sed 's/,/ /g'`
18074do
18075 if test "$targ_alias" = "all"; then
18076 all_targets=true
18077 else
18078 # Canonicalize the secondary target names.
18079 result=`$ac_config_sub $targ_alias 2>/dev/null`
18080 if test -n "$result"; then
18081 targ=$result
18082 else
18083 targ=$targ_alias
18084 fi
18085
18086 . ${srcdir}/configure.tgt
18087
18088 if test -z "${gdb_target_obs}"; then :
18089 as_fn_error $? "configuration ${targ} is unsupported." "$LINENO" 5
18090fi
18091
18092 # Target-specific object files
18093 for i in ${gdb_target_obs}; do
18094 case " $TARGET_OBS " in
18095 *" ${i} "*) ;;
18096 *)
18097 TARGET_OBS="$TARGET_OBS ${i}"
18098 ;;
18099 esac
18100 done
18101
18102 # Check whether this target needs 64-bit CORE_ADDR
18103 if test x${enable_64_bit_bfd} = xno; then
18104 . ${srcdir}/../bfd/config.bfd
18105 fi
18106
18107 # Check whether this target is native and supports gcore.
18108 if test $gdb_native = yes -a "$targ_alias" = "$target_alias" \
18109 && $gdb_have_gcore; then
18110 HAVE_NATIVE_GCORE_TARGET=1
18111 fi
18112 fi
18113done
18114
18115if test x${all_targets} = xtrue; then
18116 if test x${enable_64_bit_bfd} = xyes; then
18117 TARGET_OBS='$(ALL_TARGET_OBS) $(ALL_64_TARGET_OBS)'
18118 else
18119 TARGET_OBS='$(ALL_TARGET_OBS)'
18120 fi
18121fi
18122
18b4d073
SM
18123# AMD debugger API support.
18124
18125
18126# Check whether --with-amd-dbgapi was given.
18127if test "${with_amd_dbgapi+set}" = set; then :
18128 withval=$with_amd_dbgapi;
18129 case $withval in
18130 yes | no | auto)
18131 ;;
18132 *)
18133 as_fn_error $? "bad value $withval for --with-amd-dbgapi" "$LINENO" 5
18134 ;;
18135 esac
18136
18137else
18138 with_amd_dbgapi=auto
18139fi
18140
18141
18142# If the user passes --without-amd-dbgapi but also explicitly enables a target
18143# that requires amd-dbgapi, it is an error.
18144if test "$with_amd_dbgapi" = no -a "$gdb_require_amd_dbgapi" = true; then
18145 as_fn_error $? "an explicitly enabled target requires amd-dbgapi, but amd-dbgapi is explicitly disabled" "$LINENO" 5
18146fi
18147
18148# Look for amd-dbgapi if:
18149#
18150# - a target architecture requiring it has explicitly been enabled, or
18151# - --enable-targets=all was provided and the user did not explicitly disable
18152# amd-dbgapi support
18153if test "$gdb_require_amd_dbgapi" = true \
18154 -o \( "$all_targets" = true -a "$with_amd_dbgapi" != no \); then
18155 # amd-dbgapi version 0.68 is part of ROCm 5.4. There is no guarantee of API
18156 # stability until amd-dbgapi hits 1.0, but for convenience, still check for
18157 # greater or equal that version. It can be handy when testing with a newer
18158 # version of the library.
18159
18160pkg_failed=no
18161{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for amd-dbgapi >= 0.68.0" >&5
18162$as_echo_n "checking for amd-dbgapi >= 0.68.0... " >&6; }
18163
18164if test -n "$AMD_DBGAPI_CFLAGS"; then
18165 pkg_cv_AMD_DBGAPI_CFLAGS="$AMD_DBGAPI_CFLAGS"
18166 elif test -n "$PKG_CONFIG"; then
18167 if test -n "$PKG_CONFIG" && \
18168 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"amd-dbgapi >= 0.68.0\""; } >&5
18169 ($PKG_CONFIG --exists --print-errors "amd-dbgapi >= 0.68.0") 2>&5
18170 ac_status=$?
18171 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
18172 test $ac_status = 0; }; then
18173 pkg_cv_AMD_DBGAPI_CFLAGS=`$PKG_CONFIG --cflags "amd-dbgapi >= 0.68.0" 2>/dev/null`
18174 test "x$?" != "x0" && pkg_failed=yes
18175else
18176 pkg_failed=yes
18177fi
18178 else
18179 pkg_failed=untried
18180fi
18181if test -n "$AMD_DBGAPI_LIBS"; then
18182 pkg_cv_AMD_DBGAPI_LIBS="$AMD_DBGAPI_LIBS"
18183 elif test -n "$PKG_CONFIG"; then
18184 if test -n "$PKG_CONFIG" && \
18185 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"amd-dbgapi >= 0.68.0\""; } >&5
18186 ($PKG_CONFIG --exists --print-errors "amd-dbgapi >= 0.68.0") 2>&5
18187 ac_status=$?
18188 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
18189 test $ac_status = 0; }; then
18190 pkg_cv_AMD_DBGAPI_LIBS=`$PKG_CONFIG --libs "amd-dbgapi >= 0.68.0" 2>/dev/null`
18191 test "x$?" != "x0" && pkg_failed=yes
18192else
18193 pkg_failed=yes
18194fi
18195 else
18196 pkg_failed=untried
18197fi
18198
18199if test $pkg_failed = no; then
18200 pkg_save_LDFLAGS="$LDFLAGS"
18201 LDFLAGS="$LDFLAGS $pkg_cv_AMD_DBGAPI_LIBS"
18202 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18203/* end confdefs.h. */
18204
18205int
18206main ()
18207{
18208
18209 ;
18210 return 0;
18211}
18212_ACEOF
18213if ac_fn_c_try_link "$LINENO"; then :
18214
18215else
18216 pkg_failed=yes
18217fi
18218rm -f core conftest.err conftest.$ac_objext \
18219 conftest$ac_exeext conftest.$ac_ext
18220 LDFLAGS=$pkg_save_LDFLAGS
18221fi
18222
18223
18224
18225if test $pkg_failed = yes; then
18226 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18227$as_echo "no" >&6; }
18228
18229if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
18230 _pkg_short_errors_supported=yes
18231else
18232 _pkg_short_errors_supported=no
18233fi
18234 if test $_pkg_short_errors_supported = yes; then
18235 AMD_DBGAPI_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "amd-dbgapi >= 0.68.0" 2>&1`
18236 else
18237 AMD_DBGAPI_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "amd-dbgapi >= 0.68.0" 2>&1`
18238 fi
18239 # Put the nasty error message in config.log where it belongs
18240 echo "$AMD_DBGAPI_PKG_ERRORS" >&5
18241
18242 has_amd_dbgapi=no
18243elif test $pkg_failed = untried; then
18244 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18245$as_echo "no" >&6; }
18246 has_amd_dbgapi=no
18247else
18248 AMD_DBGAPI_CFLAGS=$pkg_cv_AMD_DBGAPI_CFLAGS
18249 AMD_DBGAPI_LIBS=$pkg_cv_AMD_DBGAPI_LIBS
18250 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18251$as_echo "yes" >&6; }
18252 has_amd_dbgapi=yes
18253fi
18254
18255 if test "$has_amd_dbgapi" = "yes"; then
08d8af48
LS
18256
18257$as_echo "#define HAVE_AMD_DBGAPI 1" >>confdefs.h
18258
18b4d073
SM
18259 TARGET_OBS="$TARGET_OBS amd-dbgapi-target.o"
18260
18261 # If --enable-targets=all was provided, use the list of all files depending
18262 # on amd-dbgapi that is hardcoded in the Makefile. Else, the appropriate
18263 # architecture entry in configure.tgt will have added the files to
18264 # gdb_target_obs.
18265 if test "$all_targets" = true; then
18266 TARGET_OBS="$TARGET_OBS \$(ALL_AMD_DBGAPI_TARGET_OBS)"
18267 fi
18268 elif test "$gdb_require_amd_dbgapi" = true -o "$with_amd_dbgapi" = yes; then
18269 # amd-dbgapi was not found and...
18270 #
18271 # - a target requiring it was explicitly enabled, or
18272 # - the user explicitly wants to enable amd-dbgapi
18273 as_fn_error $? "amd-dbgapi is required, but cannot find an appropriate version: $AMD_DBGAPI_PKG_ERRORS" "$LINENO" 5
18274 fi
18275fi
18276
b686ecb5
JM
18277
18278
18279
18280# For other settings, only the main target counts.
18281gdb_sim=
18282gdb_osabi=
18283targ=$target; . ${srcdir}/configure.tgt
18284
18285# Fetch the default architecture and default target vector from BFD.
18286targ=$target; . $srcdir/../bfd/config.bfd
18287
18288# We only want the first architecture, so strip off the others if
18289# there is more than one.
18290targ_archs=`echo $targ_archs | sed 's/ .*//'`
18291
18292if test "x$targ_archs" != x; then
18293
18294cat >>confdefs.h <<_ACEOF
18295#define DEFAULT_BFD_ARCH $targ_archs
18296_ACEOF
18297
18298fi
18299if test "x$targ_defvec" != x; then
18300
18301cat >>confdefs.h <<_ACEOF
18302#define DEFAULT_BFD_VEC $targ_defvec
18303_ACEOF
18304
18305fi
18306
18307# Enable MI.
18308# Check whether --enable-gdbmi was given.
18309if test "${enable_gdbmi+set}" = set; then :
18310 enableval=$enable_gdbmi;
18311 case $enableval in
18312 yes | no)
18313 ;;
18314 *)
18315 as_fn_error $? "bad value $enableval for --enable-gdbmi" "$LINENO" 5
18316 ;;
18317 esac
18318
18319else
18320 enable_gdbmi=yes
18321fi
18322
18323if test x"$enable_gdbmi" = xyes; then
18324 if test -d "$srcdir/mi"; then
18325 CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_MI_OBS)"
18326 CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_MI_DEPS)"
18327 CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_MI_SRCS)"
18328 ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_MI_CFLAGS)"
18329 fi
18330fi
18331
18332# Enable TUI.
18333# Check whether --enable-tui was given.
18334if test "${enable_tui+set}" = set; then :
18335 enableval=$enable_tui;
18336 case $enableval in
18337 yes | no | auto)
18338 ;;
18339 *)
18340 as_fn_error $? "bad value $enableval for --enable-tui" "$LINENO" 5
18341 ;;
18342 esac
18343
18344else
18345 enable_tui=auto
18346fi
18347
18348
18349# Enable gdbtk.
18350# Check whether --enable-gdbtk was given.
18351if test "${enable_gdbtk+set}" = set; then :
18352 enableval=$enable_gdbtk;
18353 case $enableval in
18354 yes | no)
18355 ;;
18356 *)
18357 as_fn_error $? "bad value $enableval for --enable-gdbtk" "$LINENO" 5
18358 ;;
18359 esac
18360
18361else
18362 if test -d "$srcdir/gdbtk"; then
18363 enable_gdbtk=yes
18364 else
18365 enable_gdbtk=no
18366 fi
18367fi
18368
18369# We unconditionally disable gdbtk tests on selected platforms.
18370case $host_os in
18371 go32* | windows*)
18372 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: gdbtk isn't supported on $host; disabling" >&5
18373$as_echo "$as_me: WARNING: gdbtk isn't supported on $host; disabling" >&2;}
18374 enable_gdbtk=no ;;
18375esac
18376
18377# Handle optional debuginfod support
18378
b686ecb5
JM
18379# Handle optional debuginfod support
18380
18381# Check whether --with-debuginfod was given.
18382if test "${with_debuginfod+set}" = set; then :
18383 withval=$with_debuginfod;
18384else
18385 with_debuginfod=auto
18386fi
18387
18388{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use debuginfod" >&5
18389$as_echo_n "checking whether to use debuginfod... " >&6; }
18390{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_debuginfod" >&5
18391$as_echo "$with_debuginfod" >&6; }
18392
18393if test "x$with_debuginfod" != xno; then
18394
18395pkg_failed=no
18396{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for libdebuginfod >= 0.179" >&5
18397$as_echo_n "checking for libdebuginfod >= 0.179... " >&6; }
18398
18399if test -n "$DEBUGINFOD_CFLAGS"; then
18400 pkg_cv_DEBUGINFOD_CFLAGS="$DEBUGINFOD_CFLAGS"
18401 elif test -n "$PKG_CONFIG"; then
18402 if test -n "$PKG_CONFIG" && \
18403 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libdebuginfod >= 0.179\""; } >&5
18404 ($PKG_CONFIG --exists --print-errors "libdebuginfod >= 0.179") 2>&5
18405 ac_status=$?
18406 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
18407 test $ac_status = 0; }; then
18408 pkg_cv_DEBUGINFOD_CFLAGS=`$PKG_CONFIG --cflags "libdebuginfod >= 0.179" 2>/dev/null`
18409 test "x$?" != "x0" && pkg_failed=yes
18410else
18411 pkg_failed=yes
18412fi
18413 else
18414 pkg_failed=untried
18415fi
18416if test -n "$DEBUGINFOD_LIBS"; then
18417 pkg_cv_DEBUGINFOD_LIBS="$DEBUGINFOD_LIBS"
18418 elif test -n "$PKG_CONFIG"; then
18419 if test -n "$PKG_CONFIG" && \
18420 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libdebuginfod >= 0.179\""; } >&5
18421 ($PKG_CONFIG --exists --print-errors "libdebuginfod >= 0.179") 2>&5
18422 ac_status=$?
18423 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
18424 test $ac_status = 0; }; then
18425 pkg_cv_DEBUGINFOD_LIBS=`$PKG_CONFIG --libs "libdebuginfod >= 0.179" 2>/dev/null`
18426 test "x$?" != "x0" && pkg_failed=yes
18427else
18428 pkg_failed=yes
18429fi
18430 else
18431 pkg_failed=untried
18432fi
18433
18434if test $pkg_failed = no; then
18435 pkg_save_LDFLAGS="$LDFLAGS"
18436 LDFLAGS="$LDFLAGS $pkg_cv_DEBUGINFOD_LIBS"
18437 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18438/* end confdefs.h. */
18439
18440int
18441main ()
18442{
18443
18444 ;
18445 return 0;
18446}
18447_ACEOF
18448if ac_fn_c_try_link "$LINENO"; then :
18449
18450else
18451 pkg_failed=yes
18452fi
18453rm -f core conftest.err conftest.$ac_objext \
18454 conftest$ac_exeext conftest.$ac_ext
18455 LDFLAGS=$pkg_save_LDFLAGS
18456fi
18457
18458
18459
18460if test $pkg_failed = yes; then
18461 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18462$as_echo "no" >&6; }
18463
18464if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
18465 _pkg_short_errors_supported=yes
18466else
18467 _pkg_short_errors_supported=no
18468fi
18469 if test $_pkg_short_errors_supported = yes; then
18470 DEBUGINFOD_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libdebuginfod >= 0.179" 2>&1`
18471 else
18472 DEBUGINFOD_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libdebuginfod >= 0.179" 2>&1`
18473 fi
18474 # Put the nasty error message in config.log where it belongs
18475 echo "$DEBUGINFOD_PKG_ERRORS" >&5
18476
18477 if test "x$with_debuginfod" = xyes; then
18478 as_fn_error $? "\"--with-debuginfod was given, but libdebuginfod is missing or unusable.\"" "$LINENO" 5
18479 else
18480 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libdebuginfod is missing or unusable; some features may be unavailable." >&5
18481$as_echo "$as_me: WARNING: libdebuginfod is missing or unusable; some features may be unavailable." >&2;}
18482 fi
18483elif test $pkg_failed = untried; then
18484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18485$as_echo "no" >&6; }
18486 if test "x$with_debuginfod" = xyes; then
18487 as_fn_error $? "\"--with-debuginfod was given, but libdebuginfod is missing or unusable.\"" "$LINENO" 5
18488 else
18489 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libdebuginfod is missing or unusable; some features may be unavailable." >&5
18490$as_echo "$as_me: WARNING: libdebuginfod is missing or unusable; some features may be unavailable." >&2;}
18491 fi
18492else
18493 DEBUGINFOD_CFLAGS=$pkg_cv_DEBUGINFOD_CFLAGS
18494 DEBUGINFOD_LIBS=$pkg_cv_DEBUGINFOD_LIBS
18495 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18496$as_echo "yes" >&6; }
18497
18498$as_echo "#define HAVE_LIBDEBUGINFOD 1" >>confdefs.h
18499
18500fi
18501else
18502 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: debuginfod support disabled; some features may be unavailable." >&5
18503$as_echo "$as_me: WARNING: debuginfod support disabled; some features may be unavailable." >&2;}
18504fi
18505
18506
18507# Libunwind support for ia64.
18508
18509# Check whether --with-libunwind-ia64 was given.
18510if test "${with_libunwind_ia64+set}" = set; then :
18511 withval=$with_libunwind_ia64;
18512else
18513 with_libunwind_ia64=auto
18514fi
18515
18516
18517# Backward compatibility option.
18518if test "${with_libunwind+set}" = set; then
18519 if test x"$with_libunwind_ia64" != xauto; then
18520 as_fn_error $? "option --with-libunwind is deprecated, use --with-libunwind-ia64" "$LINENO" 5
18521 fi
18522 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: option --with-libunwind is deprecated, use --with-libunwind-ia64" >&5
18523$as_echo "$as_me: WARNING: option --with-libunwind is deprecated, use --with-libunwind-ia64" >&2;}
18524 with_libunwind_ia64="$with_libunwind"
18525fi
18526
18527case "$with_libunwind_ia64" in
18528 yes | no)
18529 ;;
18530 auto)
18531 for ac_header in libunwind-ia64.h
18532do :
18533 ac_fn_c_check_header_mongrel "$LINENO" "libunwind-ia64.h" "ac_cv_header_libunwind_ia64_h" "$ac_includes_default"
18534if test "x$ac_cv_header_libunwind_ia64_h" = xyes; then :
18535 cat >>confdefs.h <<_ACEOF
18536#define HAVE_LIBUNWIND_IA64_H 1
18537_ACEOF
18538
18539fi
18540
18541done
18542
18543 with_libunwind_ia64=$ac_cv_header_libunwind_ia64_h
18544 ;;
18545 *)
18546 as_fn_error $? "bad value $with_libunwind_ia64 for GDB --with-libunwind-ia64 option" "$LINENO" 5
18547 ;;
18548esac
18549
18550if test x"$with_libunwind_ia64" = xyes; then
18551 for ac_header in libunwind-ia64.h
18552do :
18553 ac_fn_c_check_header_mongrel "$LINENO" "libunwind-ia64.h" "ac_cv_header_libunwind_ia64_h" "$ac_includes_default"
18554if test "x$ac_cv_header_libunwind_ia64_h" = xyes; then :
18555 cat >>confdefs.h <<_ACEOF
18556#define HAVE_LIBUNWIND_IA64_H 1
18557_ACEOF
18558
18559fi
18560
18561done
18562
18563 if test x"$ac_cv_header_libunwind_ia64_h" != xyes; then
18564 as_fn_error $? "GDB option --with-libunwind-ia64 requires libunwind-ia64.h" "$LINENO" 5
18565 fi
18566 CONFIG_OBS="$CONFIG_OBS ia64-libunwind-tdep.o"
18567 CONFIG_DEPS="$CONFIG_DEPS ia64-libunwind-tdep.o"
18568 CONFIG_SRCS="$CONFIG_SRCS ia64-libunwind-tdep.c"
18569fi
18570
18571opt_curses=no
18572
18573# Check whether --with-curses was given.
18574if test "${with_curses+set}" = set; then :
18575 withval=$with_curses; opt_curses=$withval
18576fi
18577
18578
18579prefer_curses=no
18580if test "$opt_curses" = "yes"; then
18581 prefer_curses=yes
18582fi
18583
18584# Profiling support.
18585# Check whether --enable-profiling was given.
18586if test "${enable_profiling+set}" = set; then :
18587 enableval=$enable_profiling;
18588 case $enableval in
18589 yes | no)
18590 ;;
18591 *)
18592 as_fn_error $? "bad value $enableval for --enable-profiling" "$LINENO" 5
18593 ;;
18594 esac
18595
18596else
18597 enable_profiling=no
18598fi
18599
18600
18601for ac_func in monstartup _mcleanup
18602do :
18603 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
18604ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
18605if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
18606 cat >>confdefs.h <<_ACEOF
18607#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
18608_ACEOF
18609
18610fi
18611done
18612
18613{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for _etext" >&5
18614$as_echo_n "checking for _etext... " >&6; }
18615if ${ac_cv_var__etext+:} false; then :
18616 $as_echo_n "(cached) " >&6
18617else
18618 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18619/* end confdefs.h. */
18620#include <stdlib.h>
18621 extern char _etext;
18622int
18623main ()
18624{
18625free (&_etext);
18626
18627 ;
18628 return 0;
18629}
18630_ACEOF
18631if ac_fn_c_try_link "$LINENO"; then :
18632 ac_cv_var__etext=yes
18633else
18634 ac_cv_var__etext=no
18635
18636fi
18637rm -f core conftest.err conftest.$ac_objext \
18638 conftest$ac_exeext conftest.$ac_ext
18639
18640fi
18641{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var__etext" >&5
18642$as_echo "$ac_cv_var__etext" >&6; }
18643if test "$ac_cv_var__etext" = yes; then
18644
18645$as_echo "#define HAVE__ETEXT 1" >>confdefs.h
18646
18647fi
18648{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for etext" >&5
18649$as_echo_n "checking for etext... " >&6; }
18650if ${ac_cv_var_etext+:} false; then :
18651 $as_echo_n "(cached) " >&6
18652else
18653 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18654/* end confdefs.h. */
18655#include <stdlib.h>
18656 extern char etext;
18657int
18658main ()
18659{
18660free (&etext);
18661
18662 ;
18663 return 0;
18664}
18665_ACEOF
18666if ac_fn_c_try_link "$LINENO"; then :
18667 ac_cv_var_etext=yes
18668else
18669 ac_cv_var_etext=no
18670
18671fi
18672rm -f core conftest.err conftest.$ac_objext \
18673 conftest$ac_exeext conftest.$ac_ext
18674
18675fi
18676{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_etext" >&5
18677$as_echo "$ac_cv_var_etext" >&6; }
18678if test "$ac_cv_var_etext" = yes; then
18679
18680$as_echo "#define HAVE_ETEXT 1" >>confdefs.h
18681
18682fi
18683if test "$enable_profiling" = yes ; then
18684 if test "$ac_cv_func_monstartup" = no || test "$ac_cv_func__mcleanup" = no; then
18685 as_fn_error $? "--enable-profiling requires monstartup and _mcleanup" "$LINENO" 5
18686 fi
18687 PROFILE_CFLAGS=-pg
18688 OLD_CFLAGS="$CFLAGS"
18689 CFLAGS="$CFLAGS $PROFILE_CFLAGS"
18690
18691 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -pg" >&5
18692$as_echo_n "checking whether $CC supports -pg... " >&6; }
18693if ${ac_cv_cc_supports_pg+:} false; then :
18694 $as_echo_n "(cached) " >&6
18695else
18696 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18697/* end confdefs.h. */
18698
18699int
18700main ()
18701{
18702int x;
18703 ;
18704 return 0;
18705}
18706_ACEOF
18707if ac_fn_c_try_compile "$LINENO"; then :
18708 ac_cv_cc_supports_pg=yes
18709else
18710 ac_cv_cc_supports_pg=no
18711
18712fi
18713rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18714
18715fi
18716{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cc_supports_pg" >&5
18717$as_echo "$ac_cv_cc_supports_pg" >&6; }
18718
18719 if test "$ac_cv_cc_supports_pg" = no; then
18720 as_fn_error $? "--enable-profiling requires a compiler which supports -pg" "$LINENO" 5
18721 fi
18722
18723 CFLAGS="$OLD_CFLAGS"
18724fi
18725
18726CODESIGN_CERT=
18727# Check whether --enable-codesign was given.
18728if test "${enable_codesign+set}" = set; then :
18729 enableval=$enable_codesign; CODESIGN_CERT=$enableval
18730fi
18731
18732
18733
18734
18735
18736# Check whether --with-pkgversion was given.
18737if test "${with_pkgversion+set}" = set; then :
18738 withval=$with_pkgversion; case "$withval" in
18739 yes) as_fn_error $? "package version not specified" "$LINENO" 5 ;;
18740 no) PKGVERSION= ;;
18741 *) PKGVERSION="($withval) " ;;
18742 esac
18743else
18744 PKGVERSION="(GDB) "
18745
18746fi
18747
18748
18749
18750
18751
18752# Check whether --with-bugurl was given.
18753if test "${with_bugurl+set}" = set; then :
18754 withval=$with_bugurl; case "$withval" in
18755 yes) as_fn_error $? "bug URL not specified" "$LINENO" 5 ;;
18756 no) BUGURL=
18757 ;;
18758 *) BUGURL="$withval"
18759 ;;
18760 esac
18761else
18762 BUGURL="https://www.gnu.org/software/gdb/bugs/"
18763
18764fi
18765
18766 case ${BUGURL} in
18767 "")
18768 REPORT_BUGS_TO=
18769 REPORT_BUGS_TEXI=
18770 ;;
18771 *)
18772 REPORT_BUGS_TO="<$BUGURL>"
18773 REPORT_BUGS_TEXI=@uref{`echo "$BUGURL" | sed 's/@/@@/g'`}
18774 ;;
18775 esac;
18776
18777
18778
18779
18780cat >>confdefs.h <<_ACEOF
18781#define PKGVERSION "$PKGVERSION"
18782_ACEOF
18783
18784
18785cat >>confdefs.h <<_ACEOF
18786#define REPORT_BUGS_TO "$REPORT_BUGS_TO"
18787_ACEOF
18788
18789
18790# --------------------- #
18791# Checks for programs. #
18792# --------------------- #
18793
18794for ac_prog in gawk mawk nawk awk
18795do
18796 # Extract the first word of "$ac_prog", so it can be a program name with args.
18797set dummy $ac_prog; ac_word=$2
18798{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18799$as_echo_n "checking for $ac_word... " >&6; }
18800if ${ac_cv_prog_AWK+:} false; then :
18801 $as_echo_n "(cached) " >&6
18802else
18803 if test -n "$AWK"; then
18804 ac_cv_prog_AWK="$AWK" # Let the user override the test.
18805else
18806as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18807for as_dir in $PATH
18808do
18809 IFS=$as_save_IFS
18810 test -z "$as_dir" && as_dir=.
18811 for ac_exec_ext in '' $ac_executable_extensions; do
18812 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18813 ac_cv_prog_AWK="$ac_prog"
18814 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18815 break 2
18816 fi
18817done
18818 done
18819IFS=$as_save_IFS
18820
18821fi
18822fi
18823AWK=$ac_cv_prog_AWK
18824if test -n "$AWK"; then
18825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
18826$as_echo "$AWK" >&6; }
18827else
18828 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18829$as_echo "no" >&6; }
18830fi
18831
18832
18833 test -n "$AWK" && break
18834done
18835
18836# Find a good install program. We prefer a C program (faster),
18837# so one script is as good as another. But avoid the broken or
18838# incompatible versions:
18839# SysV /etc/install, /usr/sbin/install
18840# SunOS /usr/etc/install
18841# IRIX /sbin/install
18842# AIX /bin/install
18843# AmigaOS /C/install, which installs bootblocks on floppy discs
18844# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
18845# AFS /usr/afsws/bin/install, which mishandles nonexistent args
18846# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
18847# OS/2's system install, which has a completely different semantic
18848# ./install, which can be erroneously created by make from ./install.sh.
18849# Reject install programs that cannot install multiple files.
18850{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
18851$as_echo_n "checking for a BSD-compatible install... " >&6; }
18852if test -z "$INSTALL"; then
18853if ${ac_cv_path_install+:} false; then :
18854 $as_echo_n "(cached) " >&6
18855else
18856 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18857for as_dir in $PATH
18858do
18859 IFS=$as_save_IFS
18860 test -z "$as_dir" && as_dir=.
18861 # Account for people who put trailing slashes in PATH elements.
18862case $as_dir/ in #((
18863 ./ | .// | /[cC]/* | \
18864 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
18865 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
18866 /usr/ucb/* ) ;;
18867 *)
18868 # OSF1 and SCO ODT 3.0 have their own names for install.
18869 # Don't use installbsd from OSF since it installs stuff as root
18870 # by default.
18871 for ac_prog in ginstall scoinst install; do
18872 for ac_exec_ext in '' $ac_executable_extensions; do
18873 if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
18874 if test $ac_prog = install &&
18875 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
18876 # AIX install. It has an incompatible calling convention.
18877 :
18878 elif test $ac_prog = install &&
18879 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
18880 # program-specific install script used by HP pwplus--don't use.
18881 :
18882 else
18883 rm -rf conftest.one conftest.two conftest.dir
18884 echo one > conftest.one
18885 echo two > conftest.two
18886 mkdir conftest.dir
18887 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
18888 test -s conftest.one && test -s conftest.two &&
18889 test -s conftest.dir/conftest.one &&
18890 test -s conftest.dir/conftest.two
18891 then
18892 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
18893 break 3
18894 fi
18895 fi
18896 fi
18897 done
18898 done
18899 ;;
18900esac
18901
18902 done
18903IFS=$as_save_IFS
18904
18905rm -rf conftest.one conftest.two conftest.dir
18906
18907fi
18908 if test "${ac_cv_path_install+set}" = set; then
18909 INSTALL=$ac_cv_path_install
18910 else
18911 # As a last resort, use the slow shell script. Don't cache a
18912 # value for INSTALL within a source directory, because that will
18913 # break other packages using the cache if that directory is
18914 # removed, or if the value is a relative name.
18915 INSTALL=$ac_install_sh
18916 fi
18917fi
18918{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
18919$as_echo "$INSTALL" >&6; }
18920
18921# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
18922# It thinks the first close brace ends the variable substitution.
18923test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
18924
18925test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
18926
18927test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
18928
18929{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
18930$as_echo_n "checking whether ln -s works... " >&6; }
18931LN_S=$as_ln_s
18932if test "$LN_S" = "ln -s"; then
18933 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18934$as_echo "yes" >&6; }
18935else
18936 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
18937$as_echo "no, using $LN_S" >&6; }
18938fi
18939
18940if test -n "$ac_tool_prefix"; then
18941 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
18942set dummy ${ac_tool_prefix}ranlib; ac_word=$2
18943{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18944$as_echo_n "checking for $ac_word... " >&6; }
18945if ${ac_cv_prog_RANLIB+:} false; then :
18946 $as_echo_n "(cached) " >&6
18947else
18948 if test -n "$RANLIB"; then
18949 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
18950else
18951as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18952for as_dir in $PATH
18953do
18954 IFS=$as_save_IFS
18955 test -z "$as_dir" && as_dir=.
18956 for ac_exec_ext in '' $ac_executable_extensions; do
18957 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18958 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
18959 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18960 break 2
18961 fi
18962done
18963 done
18964IFS=$as_save_IFS
18965
18966fi
18967fi
18968RANLIB=$ac_cv_prog_RANLIB
18969if test -n "$RANLIB"; then
18970 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
18971$as_echo "$RANLIB" >&6; }
18972else
18973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18974$as_echo "no" >&6; }
18975fi
18976
18977
18978fi
18979if test -z "$ac_cv_prog_RANLIB"; then
18980 ac_ct_RANLIB=$RANLIB
18981 # Extract the first word of "ranlib", so it can be a program name with args.
18982set dummy ranlib; ac_word=$2
18983{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18984$as_echo_n "checking for $ac_word... " >&6; }
18985if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
18986 $as_echo_n "(cached) " >&6
18987else
18988 if test -n "$ac_ct_RANLIB"; then
18989 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
18990else
18991as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18992for as_dir in $PATH
18993do
18994 IFS=$as_save_IFS
18995 test -z "$as_dir" && as_dir=.
18996 for ac_exec_ext in '' $ac_executable_extensions; do
18997 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18998 ac_cv_prog_ac_ct_RANLIB="ranlib"
18999 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19000 break 2
19001 fi
19002done
19003 done
19004IFS=$as_save_IFS
19005
19006fi
19007fi
19008ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
19009if test -n "$ac_ct_RANLIB"; then
19010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
19011$as_echo "$ac_ct_RANLIB" >&6; }
19012else
19013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19014$as_echo "no" >&6; }
19015fi
19016
19017 if test "x$ac_ct_RANLIB" = x; then
19018 RANLIB=":"
19019 else
19020 case $cross_compiling:$ac_tool_warned in
19021yes:)
19022{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
19023$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
19024ac_tool_warned=yes ;;
19025esac
19026 RANLIB=$ac_ct_RANLIB
19027 fi
19028else
19029 RANLIB="$ac_cv_prog_RANLIB"
19030fi
19031
19032for ac_prog in 'bison -y' byacc
19033do
19034 # Extract the first word of "$ac_prog", so it can be a program name with args.
19035set dummy $ac_prog; ac_word=$2
19036{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19037$as_echo_n "checking for $ac_word... " >&6; }
19038if ${ac_cv_prog_YACC+:} false; then :
19039 $as_echo_n "(cached) " >&6
19040else
19041 if test -n "$YACC"; then
19042 ac_cv_prog_YACC="$YACC" # Let the user override the test.
19043else
19044as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19045for as_dir in $PATH
19046do
19047 IFS=$as_save_IFS
19048 test -z "$as_dir" && as_dir=.
19049 for ac_exec_ext in '' $ac_executable_extensions; do
19050 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19051 ac_cv_prog_YACC="$ac_prog"
19052 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19053 break 2
19054 fi
19055done
19056 done
19057IFS=$as_save_IFS
19058
19059fi
19060fi
19061YACC=$ac_cv_prog_YACC
19062if test -n "$YACC"; then
19063 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $YACC" >&5
19064$as_echo "$YACC" >&6; }
19065else
19066 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19067$as_echo "no" >&6; }
19068fi
19069
19070
19071 test -n "$YACC" && break
19072done
19073test -n "$YACC" || YACC="yacc"
19074
19075
19076if test -n "$ac_tool_prefix"; then
19077 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
19078set dummy ${ac_tool_prefix}ar; ac_word=$2
19079{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19080$as_echo_n "checking for $ac_word... " >&6; }
19081if ${ac_cv_prog_AR+:} false; then :
19082 $as_echo_n "(cached) " >&6
19083else
19084 if test -n "$AR"; then
19085 ac_cv_prog_AR="$AR" # Let the user override the test.
19086else
19087as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19088for as_dir in $PATH
19089do
19090 IFS=$as_save_IFS
19091 test -z "$as_dir" && as_dir=.
19092 for ac_exec_ext in '' $ac_executable_extensions; do
19093 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19094 ac_cv_prog_AR="${ac_tool_prefix}ar"
19095 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19096 break 2
19097 fi
19098done
19099 done
19100IFS=$as_save_IFS
19101
19102fi
19103fi
19104AR=$ac_cv_prog_AR
19105if test -n "$AR"; then
19106 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
19107$as_echo "$AR" >&6; }
19108else
19109 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19110$as_echo "no" >&6; }
19111fi
19112
19113
19114fi
19115if test -z "$ac_cv_prog_AR"; then
19116 ac_ct_AR=$AR
19117 # Extract the first word of "ar", so it can be a program name with args.
19118set dummy ar; ac_word=$2
19119{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19120$as_echo_n "checking for $ac_word... " >&6; }
19121if ${ac_cv_prog_ac_ct_AR+:} false; then :
19122 $as_echo_n "(cached) " >&6
19123else
19124 if test -n "$ac_ct_AR"; then
19125 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
19126else
19127as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19128for as_dir in $PATH
19129do
19130 IFS=$as_save_IFS
19131 test -z "$as_dir" && as_dir=.
19132 for ac_exec_ext in '' $ac_executable_extensions; do
19133 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19134 ac_cv_prog_ac_ct_AR="ar"
19135 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19136 break 2
19137 fi
19138done
19139 done
19140IFS=$as_save_IFS
19141
19142fi
19143fi
19144ac_ct_AR=$ac_cv_prog_ac_ct_AR
19145if test -n "$ac_ct_AR"; then
19146 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
19147$as_echo "$ac_ct_AR" >&6; }
19148else
19149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19150$as_echo "no" >&6; }
19151fi
19152
19153 if test "x$ac_ct_AR" = x; then
19154 AR=""
19155 else
19156 case $cross_compiling:$ac_tool_warned in
19157yes:)
19158{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
19159$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
19160ac_tool_warned=yes ;;
19161esac
19162 AR=$ac_ct_AR
19163 fi
19164else
19165 AR="$ac_cv_prog_AR"
19166fi
19167
19168if test -n "$ac_tool_prefix"; then
19169 # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
19170set dummy ${ac_tool_prefix}dlltool; ac_word=$2
19171{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19172$as_echo_n "checking for $ac_word... " >&6; }
19173if ${ac_cv_prog_DLLTOOL+:} false; then :
19174 $as_echo_n "(cached) " >&6
19175else
19176 if test -n "$DLLTOOL"; then
19177 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
19178else
19179as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19180for as_dir in $PATH
19181do
19182 IFS=$as_save_IFS
19183 test -z "$as_dir" && as_dir=.
19184 for ac_exec_ext in '' $ac_executable_extensions; do
19185 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19186 ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
19187 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19188 break 2
19189 fi
19190done
19191 done
19192IFS=$as_save_IFS
19193
19194fi
19195fi
19196DLLTOOL=$ac_cv_prog_DLLTOOL
19197if test -n "$DLLTOOL"; then
19198 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
19199$as_echo "$DLLTOOL" >&6; }
19200else
19201 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19202$as_echo "no" >&6; }
19203fi
19204
19205
19206fi
19207if test -z "$ac_cv_prog_DLLTOOL"; then
19208 ac_ct_DLLTOOL=$DLLTOOL
19209 # Extract the first word of "dlltool", so it can be a program name with args.
19210set dummy dlltool; ac_word=$2
19211{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19212$as_echo_n "checking for $ac_word... " >&6; }
19213if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then :
19214 $as_echo_n "(cached) " >&6
19215else
19216 if test -n "$ac_ct_DLLTOOL"; then
19217 ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
19218else
19219as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19220for as_dir in $PATH
19221do
19222 IFS=$as_save_IFS
19223 test -z "$as_dir" && as_dir=.
19224 for ac_exec_ext in '' $ac_executable_extensions; do
19225 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19226 ac_cv_prog_ac_ct_DLLTOOL="dlltool"
19227 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19228 break 2
19229 fi
19230done
19231 done
19232IFS=$as_save_IFS
19233
19234fi
19235fi
19236ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
19237if test -n "$ac_ct_DLLTOOL"; then
19238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
19239$as_echo "$ac_ct_DLLTOOL" >&6; }
19240else
19241 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19242$as_echo "no" >&6; }
19243fi
19244
19245 if test "x$ac_ct_DLLTOOL" = x; then
19246 DLLTOOL=""
19247 else
19248 case $cross_compiling:$ac_tool_warned in
19249yes:)
19250{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
19251$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
19252ac_tool_warned=yes ;;
19253esac
19254 DLLTOOL=$ac_ct_DLLTOOL
19255 fi
19256else
19257 DLLTOOL="$ac_cv_prog_DLLTOOL"
19258fi
19259
19260if test -n "$ac_tool_prefix"; then
19261 # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
19262set dummy ${ac_tool_prefix}windres; ac_word=$2
19263{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19264$as_echo_n "checking for $ac_word... " >&6; }
19265if ${ac_cv_prog_WINDRES+:} false; then :
19266 $as_echo_n "(cached) " >&6
19267else
19268 if test -n "$WINDRES"; then
19269 ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
19270else
19271as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19272for as_dir in $PATH
19273do
19274 IFS=$as_save_IFS
19275 test -z "$as_dir" && as_dir=.
19276 for ac_exec_ext in '' $ac_executable_extensions; do
19277 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19278 ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
19279 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19280 break 2
19281 fi
19282done
19283 done
19284IFS=$as_save_IFS
19285
19286fi
19287fi
19288WINDRES=$ac_cv_prog_WINDRES
19289if test -n "$WINDRES"; then
19290 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
19291$as_echo "$WINDRES" >&6; }
19292else
19293 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19294$as_echo "no" >&6; }
19295fi
19296
19297
19298fi
19299if test -z "$ac_cv_prog_WINDRES"; then
19300 ac_ct_WINDRES=$WINDRES
19301 # Extract the first word of "windres", so it can be a program name with args.
19302set dummy windres; ac_word=$2
19303{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19304$as_echo_n "checking for $ac_word... " >&6; }
19305if ${ac_cv_prog_ac_ct_WINDRES+:} false; then :
19306 $as_echo_n "(cached) " >&6
19307else
19308 if test -n "$ac_ct_WINDRES"; then
19309 ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test.
19310else
19311as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19312for as_dir in $PATH
19313do
19314 IFS=$as_save_IFS
19315 test -z "$as_dir" && as_dir=.
19316 for ac_exec_ext in '' $ac_executable_extensions; do
19317 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19318 ac_cv_prog_ac_ct_WINDRES="windres"
19319 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19320 break 2
19321 fi
19322done
19323 done
19324IFS=$as_save_IFS
19325
19326fi
19327fi
19328ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
19329if test -n "$ac_ct_WINDRES"; then
19330 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_WINDRES" >&5
19331$as_echo "$ac_ct_WINDRES" >&6; }
19332else
19333 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19334$as_echo "no" >&6; }
19335fi
19336
19337 if test "x$ac_ct_WINDRES" = x; then
19338 WINDRES=""
19339 else
19340 case $cross_compiling:$ac_tool_warned in
19341yes:)
19342{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
19343$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
19344ac_tool_warned=yes ;;
19345esac
19346 WINDRES=$ac_ct_WINDRES
19347 fi
19348else
19349 WINDRES="$ac_cv_prog_WINDRES"
19350fi
19351
19352
19353case $host_os in
19354 gnu*)
19355 # Needed for GNU Hurd hosts.
19356 if test -n "$ac_tool_prefix"; then
19357 # Extract the first word of "${ac_tool_prefix}mig", so it can be a program name with args.
19358set dummy ${ac_tool_prefix}mig; ac_word=$2
19359{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19360$as_echo_n "checking for $ac_word... " >&6; }
19361if ${ac_cv_prog_MIG+:} false; then :
19362 $as_echo_n "(cached) " >&6
19363else
19364 if test -n "$MIG"; then
19365 ac_cv_prog_MIG="$MIG" # Let the user override the test.
19366else
19367as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19368for as_dir in $PATH
19369do
19370 IFS=$as_save_IFS
19371 test -z "$as_dir" && as_dir=.
19372 for ac_exec_ext in '' $ac_executable_extensions; do
19373 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19374 ac_cv_prog_MIG="${ac_tool_prefix}mig"
19375 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19376 break 2
19377 fi
19378done
19379 done
19380IFS=$as_save_IFS
19381
19382fi
19383fi
19384MIG=$ac_cv_prog_MIG
19385if test -n "$MIG"; then
19386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MIG" >&5
19387$as_echo "$MIG" >&6; }
19388else
19389 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19390$as_echo "no" >&6; }
19391fi
19392
19393
19394fi
19395if test -z "$ac_cv_prog_MIG"; then
19396 ac_ct_MIG=$MIG
19397 # Extract the first word of "mig", so it can be a program name with args.
19398set dummy mig; ac_word=$2
19399{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19400$as_echo_n "checking for $ac_word... " >&6; }
19401if ${ac_cv_prog_ac_ct_MIG+:} false; then :
19402 $as_echo_n "(cached) " >&6
19403else
19404 if test -n "$ac_ct_MIG"; then
19405 ac_cv_prog_ac_ct_MIG="$ac_ct_MIG" # Let the user override the test.
19406else
19407as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19408for as_dir in $PATH
19409do
19410 IFS=$as_save_IFS
19411 test -z "$as_dir" && as_dir=.
19412 for ac_exec_ext in '' $ac_executable_extensions; do
19413 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19414 ac_cv_prog_ac_ct_MIG="mig"
19415 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19416 break 2
19417 fi
19418done
19419 done
19420IFS=$as_save_IFS
19421
19422fi
19423fi
19424ac_ct_MIG=$ac_cv_prog_ac_ct_MIG
19425if test -n "$ac_ct_MIG"; then
19426 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MIG" >&5
19427$as_echo "$ac_ct_MIG" >&6; }
19428else
19429 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19430$as_echo "no" >&6; }
19431fi
19432
19433 if test "x$ac_ct_MIG" = x; then
19434 MIG=""
19435 else
19436 case $cross_compiling:$ac_tool_warned in
19437yes:)
19438{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
19439$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
19440ac_tool_warned=yes ;;
19441esac
19442 MIG=$ac_ct_MIG
19443 fi
19444else
19445 MIG="$ac_cv_prog_MIG"
19446fi
19447
19448 if test x"$MIG" = x; then
19449 as_fn_error $? "MIG not found but required for $host hosts" "$LINENO" 5
19450 fi
19451 ;;
19452esac
19453
19454# ---------------------- #
19455# Checks for libraries. #
19456# ---------------------- #
19457
19458# We might need to link with -lm; most simulators need it.
19459{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lm" >&5
19460$as_echo_n "checking for main in -lm... " >&6; }
19461if ${ac_cv_lib_m_main+:} false; then :
19462 $as_echo_n "(cached) " >&6
19463else
19464 ac_check_lib_save_LIBS=$LIBS
19465LIBS="-lm $LIBS"
19466cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19467/* end confdefs.h. */
19468
19469
19470int
19471main ()
19472{
19473return main ();
19474 ;
19475 return 0;
19476}
19477_ACEOF
19478if ac_fn_c_try_link "$LINENO"; then :
19479 ac_cv_lib_m_main=yes
19480else
19481 ac_cv_lib_m_main=no
19482fi
19483rm -f core conftest.err conftest.$ac_objext \
19484 conftest$ac_exeext conftest.$ac_ext
19485LIBS=$ac_check_lib_save_LIBS
19486fi
19487{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_main" >&5
19488$as_echo "$ac_cv_lib_m_main" >&6; }
19489if test "x$ac_cv_lib_m_main" = xyes; then :
19490 cat >>confdefs.h <<_ACEOF
19491#define HAVE_LIBM 1
19492_ACEOF
19493
19494 LIBS="-lm $LIBS"
19495
19496fi
19497
19498
19499# Some systems (e.g. Solaris) have `gethostbyname' in libnsl.
19500{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing gethostbyname" >&5
19501$as_echo_n "checking for library containing gethostbyname... " >&6; }
19502if ${ac_cv_search_gethostbyname+:} false; then :
19503 $as_echo_n "(cached) " >&6
19504else
19505 ac_func_search_save_LIBS=$LIBS
19506cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19507/* end confdefs.h. */
19508
19509/* Override any GCC internal prototype to avoid an error.
19510 Use char because int might match the return type of a GCC
19511 builtin and then its argument prototype would still apply. */
19512#ifdef __cplusplus
19513extern "C"
19514#endif
19515char gethostbyname ();
19516int
19517main ()
19518{
19519return gethostbyname ();
19520 ;
19521 return 0;
19522}
19523_ACEOF
19524for ac_lib in '' nsl; do
19525 if test -z "$ac_lib"; then
19526 ac_res="none required"
19527 else
19528 ac_res=-l$ac_lib
19529 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
19530 fi
19531 if ac_fn_c_try_link "$LINENO"; then :
19532 ac_cv_search_gethostbyname=$ac_res
19533fi
19534rm -f core conftest.err conftest.$ac_objext \
19535 conftest$ac_exeext
19536 if ${ac_cv_search_gethostbyname+:} false; then :
19537 break
19538fi
19539done
19540if ${ac_cv_search_gethostbyname+:} false; then :
19541
19542else
19543 ac_cv_search_gethostbyname=no
19544fi
19545rm conftest.$ac_ext
19546LIBS=$ac_func_search_save_LIBS
19547fi
19548{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_gethostbyname" >&5
19549$as_echo "$ac_cv_search_gethostbyname" >&6; }
19550ac_res=$ac_cv_search_gethostbyname
19551if test "$ac_res" != no; then :
19552 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
19553
19554fi
19555
19556
19557# Some systems (e.g. Solaris) have `socketpair' in libsocket.
19558{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing socketpair" >&5
19559$as_echo_n "checking for library containing socketpair... " >&6; }
19560if ${ac_cv_search_socketpair+:} false; then :
19561 $as_echo_n "(cached) " >&6
19562else
19563 ac_func_search_save_LIBS=$LIBS
19564cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19565/* end confdefs.h. */
19566
19567/* Override any GCC internal prototype to avoid an error.
19568 Use char because int might match the return type of a GCC
19569 builtin and then its argument prototype would still apply. */
19570#ifdef __cplusplus
19571extern "C"
19572#endif
19573char socketpair ();
19574int
19575main ()
19576{
19577return socketpair ();
19578 ;
19579 return 0;
19580}
19581_ACEOF
19582for ac_lib in '' socket; do
19583 if test -z "$ac_lib"; then
19584 ac_res="none required"
19585 else
19586 ac_res=-l$ac_lib
19587 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
19588 fi
19589 if ac_fn_c_try_link "$LINENO"; then :
19590 ac_cv_search_socketpair=$ac_res
19591fi
19592rm -f core conftest.err conftest.$ac_objext \
19593 conftest$ac_exeext
19594 if ${ac_cv_search_socketpair+:} false; then :
19595 break
19596fi
19597done
19598if ${ac_cv_search_socketpair+:} false; then :
19599
19600else
19601 ac_cv_search_socketpair=no
19602fi
19603rm conftest.$ac_ext
19604LIBS=$ac_func_search_save_LIBS
19605fi
19606{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_socketpair" >&5
19607$as_echo "$ac_cv_search_socketpair" >&6; }
19608ac_res=$ac_cv_search_socketpair
19609if test "$ac_res" != no; then :
19610 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
19611
19612fi
19613
19614
19615# Link in zlib/zstd if we can. This allows us to read compressed debug
19616# sections.
19617
19618 # Use the system's zlib library.
19619 zlibdir="-L\$(top_builddir)/../zlib"
19620 zlibinc="-I\$(top_srcdir)/../zlib"
19621
19622# Check whether --with-system-zlib was given.
19623if test "${with_system_zlib+set}" = set; then :
19624 withval=$with_system_zlib; if test x$with_system_zlib = xyes ; then
19625 zlibdir=
19626 zlibinc=
19627 fi
19628
19629fi
19630
19631
19632
19633
19634
19635
19636# Check whether --with-zstd was given.
19637if test "${with_zstd+set}" = set; then :
19638 withval=$with_zstd;
19639else
19640 with_zstd=auto
19641fi
19642
19643
19644if test "$with_zstd" != no; then :
19645
19646pkg_failed=no
19647{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for libzstd >= 1.4.0" >&5
19648$as_echo_n "checking for libzstd >= 1.4.0... " >&6; }
19649
19650if test -n "$ZSTD_CFLAGS"; then
19651 pkg_cv_ZSTD_CFLAGS="$ZSTD_CFLAGS"
19652 elif test -n "$PKG_CONFIG"; then
19653 if test -n "$PKG_CONFIG" && \
19654 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libzstd >= 1.4.0\""; } >&5
19655 ($PKG_CONFIG --exists --print-errors "libzstd >= 1.4.0") 2>&5
19656 ac_status=$?
19657 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
19658 test $ac_status = 0; }; then
19659 pkg_cv_ZSTD_CFLAGS=`$PKG_CONFIG --cflags "libzstd >= 1.4.0" 2>/dev/null`
19660 test "x$?" != "x0" && pkg_failed=yes
19661else
19662 pkg_failed=yes
19663fi
19664 else
19665 pkg_failed=untried
19666fi
19667if test -n "$ZSTD_LIBS"; then
19668 pkg_cv_ZSTD_LIBS="$ZSTD_LIBS"
19669 elif test -n "$PKG_CONFIG"; then
19670 if test -n "$PKG_CONFIG" && \
19671 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libzstd >= 1.4.0\""; } >&5
19672 ($PKG_CONFIG --exists --print-errors "libzstd >= 1.4.0") 2>&5
19673 ac_status=$?
19674 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
19675 test $ac_status = 0; }; then
19676 pkg_cv_ZSTD_LIBS=`$PKG_CONFIG --libs "libzstd >= 1.4.0" 2>/dev/null`
19677 test "x$?" != "x0" && pkg_failed=yes
19678else
19679 pkg_failed=yes
19680fi
19681 else
19682 pkg_failed=untried
19683fi
19684
19685if test $pkg_failed = no; then
19686 pkg_save_LDFLAGS="$LDFLAGS"
19687 LDFLAGS="$LDFLAGS $pkg_cv_ZSTD_LIBS"
19688 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19689/* end confdefs.h. */
19690
19691int
19692main ()
19693{
19694
19695 ;
19696 return 0;
19697}
19698_ACEOF
19699if ac_fn_c_try_link "$LINENO"; then :
19700
19701else
19702 pkg_failed=yes
19703fi
19704rm -f core conftest.err conftest.$ac_objext \
19705 conftest$ac_exeext conftest.$ac_ext
19706 LDFLAGS=$pkg_save_LDFLAGS
19707fi
19708
19709
19710
19711if test $pkg_failed = yes; then
19712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19713$as_echo "no" >&6; }
19714
19715if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
19716 _pkg_short_errors_supported=yes
19717else
19718 _pkg_short_errors_supported=no
19719fi
19720 if test $_pkg_short_errors_supported = yes; then
19721 ZSTD_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libzstd >= 1.4.0" 2>&1`
19722 else
19723 ZSTD_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libzstd >= 1.4.0" 2>&1`
19724 fi
19725 # Put the nasty error message in config.log where it belongs
19726 echo "$ZSTD_PKG_ERRORS" >&5
19727
19728
19729 if test "$with_zstd" = yes; then
19730 as_fn_error $? "--with-zstd was given, but pkgconfig/libzstd.pc is not found" "$LINENO" 5
19731 fi
19732
19733elif test $pkg_failed = untried; then
19734 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19735$as_echo "no" >&6; }
19736
19737 if test "$with_zstd" = yes; then
19738 as_fn_error $? "--with-zstd was given, but pkgconfig/libzstd.pc is not found" "$LINENO" 5
19739 fi
19740
19741else
19742 ZSTD_CFLAGS=$pkg_cv_ZSTD_CFLAGS
19743 ZSTD_LIBS=$pkg_cv_ZSTD_LIBS
19744 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19745$as_echo "yes" >&6; }
19746
19747
19748$as_echo "#define HAVE_ZSTD 1" >>confdefs.h
19749
19750
19751fi
19752
19753fi
19754
19755
19756
19757 if test "X$prefix" = "XNONE"; then
19758 acl_final_prefix="$ac_default_prefix"
19759 else
19760 acl_final_prefix="$prefix"
19761 fi
19762 if test "X$exec_prefix" = "XNONE"; then
19763 acl_final_exec_prefix='${prefix}'
19764 else
19765 acl_final_exec_prefix="$exec_prefix"
19766 fi
19767 acl_save_prefix="$prefix"
19768 prefix="$acl_final_prefix"
19769 eval acl_final_exec_prefix=\"$acl_final_exec_prefix\"
19770 prefix="$acl_save_prefix"
19771
19772
19773# Check whether --with-gnu-ld was given.
19774if test "${with_gnu_ld+set}" = set; then :
19775 withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
19776else
19777 with_gnu_ld=no
19778fi
19779
19780# Prepare PATH_SEPARATOR.
19781# The user is always right.
19782if test "${PATH_SEPARATOR+set}" != set; then
19783 echo "#! /bin/sh" >conf$$.sh
19784 echo "exit 0" >>conf$$.sh
19785 chmod +x conf$$.sh
19786 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
19787 PATH_SEPARATOR=';'
19788 else
19789 PATH_SEPARATOR=:
19790 fi
19791 rm -f conf$$.sh
19792fi
19793ac_prog=ld
19794if test "$GCC" = yes; then
19795 # Check if gcc -print-prog-name=ld gives a path.
19796 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by GCC" >&5
19797$as_echo_n "checking for ld used by GCC... " >&6; }
19798 case $host in
19799 *-*-mingw*)
19800 # gcc leaves a trailing carriage return which upsets mingw
19801 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
19802 *)
19803 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
19804 esac
19805 case $ac_prog in
19806 # Accept absolute paths.
19807 [\\/]* | [A-Za-z]:[\\/]*)
19808 re_direlt='/[^/][^/]*/\.\./'
19809 # Canonicalize the path of ld
19810 ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
19811 while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
19812 ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
19813 done
19814 test -z "$LD" && LD="$ac_prog"
19815 ;;
19816 "")
19817 # If it fails, then pretend we aren't using GCC.
19818 ac_prog=ld
19819 ;;
19820 *)
19821 # If it is relative, then search for the first ld in PATH.
19822 with_gnu_ld=unknown
19823 ;;
19824 esac
19825elif test "$with_gnu_ld" = yes; then
19826 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
19827$as_echo_n "checking for GNU ld... " >&6; }
19828else
19829 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
19830$as_echo_n "checking for non-GNU ld... " >&6; }
19831fi
19832if ${acl_cv_path_LD+:} false; then :
19833 $as_echo_n "(cached) " >&6
19834else
19835 if test -z "$LD"; then
19836 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
19837 for ac_dir in $PATH; do
19838 test -z "$ac_dir" && ac_dir=.
19839 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
19840 acl_cv_path_LD="$ac_dir/$ac_prog"
19841 # Check to see if the program is GNU ld. I'd rather use --version,
19842 # but apparently some GNU ld's only accept -v.
19843 # Break only if it was the GNU/non-GNU ld that we prefer.
19844 if "$acl_cv_path_LD" -v 2>&1 < /dev/null | $EGREP '(GNU|with BFD)' > /dev/null; then
19845 test "$with_gnu_ld" != no && break
19846 else
19847 test "$with_gnu_ld" != yes && break
19848 fi
19849 fi
19850 done
19851 IFS="$ac_save_ifs"
19852else
19853 acl_cv_path_LD="$LD" # Let the user override the test with a path.
19854fi
19855fi
19856
19857LD="$acl_cv_path_LD"
19858if test -n "$LD"; then
19859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
19860$as_echo "$LD" >&6; }
19861else
19862 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19863$as_echo "no" >&6; }
19864fi
19865test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
19866{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
19867$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
19868if ${acl_cv_prog_gnu_ld+:} false; then :
19869 $as_echo_n "(cached) " >&6
19870else
19871 # I'd rather use --version here, but apparently some GNU ld's only accept -v.
19872if $LD -v 2>&1 </dev/null | $EGREP '(GNU|with BFD)' 1>&5; then
19873 acl_cv_prog_gnu_ld=yes
19874else
19875 acl_cv_prog_gnu_ld=no
19876fi
19877fi
19878{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_prog_gnu_ld" >&5
19879$as_echo "$acl_cv_prog_gnu_ld" >&6; }
19880with_gnu_ld=$acl_cv_prog_gnu_ld
19881
19882
19883
19884 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shared library run path origin" >&5
19885$as_echo_n "checking for shared library run path origin... " >&6; }
19886if ${acl_cv_rpath+:} false; then :
19887 $as_echo_n "(cached) " >&6
19888else
19889
19890 CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
19891 ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
19892 . ./conftest.sh
19893 rm -f ./conftest.sh
19894 acl_cv_rpath=done
19895
19896fi
19897{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_rpath" >&5
19898$as_echo "$acl_cv_rpath" >&6; }
19899 wl="$acl_cv_wl"
19900 libext="$acl_cv_libext"
19901 shlibext="$acl_cv_shlibext"
19902 hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
19903 hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
19904 hardcode_direct="$acl_cv_hardcode_direct"
19905 hardcode_minus_L="$acl_cv_hardcode_minus_L"
19906 # Check whether --enable-rpath was given.
19907if test "${enable_rpath+set}" = set; then :
19908 enableval=$enable_rpath; :
19909else
19910 enable_rpath=yes
19911fi
19912
19913
19914
19915
19916
19917
19918
19919
19920 use_additional=yes
19921
19922 acl_save_prefix="$prefix"
19923 prefix="$acl_final_prefix"
19924 acl_save_exec_prefix="$exec_prefix"
19925 exec_prefix="$acl_final_exec_prefix"
19926
19927 eval additional_includedir=\"$includedir\"
19928 eval additional_libdir=\"$libdir\"
19929
19930 exec_prefix="$acl_save_exec_prefix"
19931 prefix="$acl_save_prefix"
19932
19933
19934# Check whether --with-libiconv-prefix was given.
19935if test "${with_libiconv_prefix+set}" = set; then :
19936 withval=$with_libiconv_prefix;
19937 if test "X$withval" = "Xno"; then
19938 use_additional=no
19939 else
19940 if test "X$withval" = "X"; then
19941
19942 acl_save_prefix="$prefix"
19943 prefix="$acl_final_prefix"
19944 acl_save_exec_prefix="$exec_prefix"
19945 exec_prefix="$acl_final_exec_prefix"
19946
19947 eval additional_includedir=\"$includedir\"
19948 eval additional_libdir=\"$libdir\"
19949
19950 exec_prefix="$acl_save_exec_prefix"
19951 prefix="$acl_save_prefix"
19952
19953 else
19954 additional_includedir="$withval/include"
19955 additional_libdir="$withval/lib"
19956 fi
19957 fi
19958
19959fi
19960
19961
19962# Check whether --with-libiconv-type was given.
19963if test "${with_libiconv_type+set}" = set; then :
19964 withval=$with_libiconv_type; with_libiconv_type=$withval
19965else
19966 with_libiconv_type=auto
19967fi
19968
19969 lib_type=`eval echo \$with_libiconv_type`
19970
19971 LIBICONV=
19972 LTLIBICONV=
19973 INCICONV=
19974 rpathdirs=
19975 ltrpathdirs=
19976 names_already_handled=
19977 names_next_round='iconv '
19978 while test -n "$names_next_round"; do
19979 names_this_round="$names_next_round"
19980 names_next_round=
19981 for name in $names_this_round; do
19982 already_handled=
19983 for n in $names_already_handled; do
19984 if test "$n" = "$name"; then
19985 already_handled=yes
19986 break
19987 fi
19988 done
19989 if test -z "$already_handled"; then
19990 names_already_handled="$names_already_handled $name"
19991 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
19992 eval value=\"\$HAVE_LIB$uppername\"
19993 if test -n "$value"; then
19994 if test "$value" = yes; then
19995 eval value=\"\$LIB$uppername\"
19996 test -z "$value" || LIBICONV="${LIBICONV}${LIBICONV:+ }$value"
19997 eval value=\"\$LTLIB$uppername\"
19998 test -z "$value" || LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$value"
19999 else
20000 :
20001 fi
20002 else
20003 found_dir=
20004 found_la=
20005 found_so=
20006 found_a=
20007 if test $use_additional = yes; then
20008 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
20009 found_dir="$additional_libdir"
20010 found_so="$additional_libdir/lib$name.$shlibext"
20011 if test -f "$additional_libdir/lib$name.la"; then
20012 found_la="$additional_libdir/lib$name.la"
20013 fi
20014 elif test x$lib_type != xshared; then
20015 if test -f "$additional_libdir/lib$name.$libext"; then
20016 found_dir="$additional_libdir"
20017 found_a="$additional_libdir/lib$name.$libext"
20018 if test -f "$additional_libdir/lib$name.la"; then
20019 found_la="$additional_libdir/lib$name.la"
20020 fi
20021 fi
20022 fi
20023 fi
20024 if test "X$found_dir" = "X"; then
20025 for x in $LDFLAGS $LTLIBICONV; do
20026
20027 acl_save_prefix="$prefix"
20028 prefix="$acl_final_prefix"
20029 acl_save_exec_prefix="$exec_prefix"
20030 exec_prefix="$acl_final_exec_prefix"
20031 eval x=\"$x\"
20032 exec_prefix="$acl_save_exec_prefix"
20033 prefix="$acl_save_prefix"
20034
20035 case "$x" in
20036 -L*)
20037 dir=`echo "X$x" | sed -e 's/^X-L//'`
20038 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
20039 found_dir="$dir"
20040 found_so="$dir/lib$name.$shlibext"
20041 if test -f "$dir/lib$name.la"; then
20042 found_la="$dir/lib$name.la"
20043 fi
20044 elif test x$lib_type != xshared; then
20045 if test -f "$dir/lib$name.$libext"; then
20046 found_dir="$dir"
20047 found_a="$dir/lib$name.$libext"
20048 if test -f "$dir/lib$name.la"; then
20049 found_la="$dir/lib$name.la"
20050 fi
20051 fi
20052 fi
20053 ;;
20054 esac
20055 if test "X$found_dir" != "X"; then
20056 break
20057 fi
20058 done
20059 fi
20060 if test "X$found_dir" != "X"; then
20061 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$found_dir -l$name"
20062 if test "X$found_so" != "X"; then
20063 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
20064 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
20065 else
20066 haveit=
20067 for x in $ltrpathdirs; do
20068 if test "X$x" = "X$found_dir"; then
20069 haveit=yes
20070 break
20071 fi
20072 done
20073 if test -z "$haveit"; then
20074 ltrpathdirs="$ltrpathdirs $found_dir"
20075 fi
20076 if test "$hardcode_direct" = yes; then
20077 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
20078 else
20079 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
20080 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
20081 haveit=
20082 for x in $rpathdirs; do
20083 if test "X$x" = "X$found_dir"; then
20084 haveit=yes
20085 break
20086 fi
20087 done
20088 if test -z "$haveit"; then
20089 rpathdirs="$rpathdirs $found_dir"
20090 fi
20091 else
20092 haveit=
20093 for x in $LDFLAGS $LIBICONV; do
20094
20095 acl_save_prefix="$prefix"
20096 prefix="$acl_final_prefix"
20097 acl_save_exec_prefix="$exec_prefix"
20098 exec_prefix="$acl_final_exec_prefix"
20099 eval x=\"$x\"
20100 exec_prefix="$acl_save_exec_prefix"
20101 prefix="$acl_save_prefix"
20102
20103 if test "X$x" = "X-L$found_dir"; then
20104 haveit=yes
20105 break
20106 fi
20107 done
20108 if test -z "$haveit"; then
20109 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir"
20110 fi
20111 if test "$hardcode_minus_L" != no; then
20112 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
20113 else
20114 LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
20115 fi
20116 fi
20117 fi
20118 fi
20119 else
20120 if test "X$found_a" != "X"; then
20121 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_a"
20122 else
20123 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir -l$name"
20124 fi
20125 fi
20126 additional_includedir=
20127 case "$found_dir" in
20128 */lib | */lib/)
20129 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
20130 additional_includedir="$basedir/include"
20131 ;;
20132 esac
20133 if test "X$additional_includedir" != "X"; then
20134 if test "X$additional_includedir" != "X/usr/include"; then
20135 haveit=
20136 if test "X$additional_includedir" = "X/usr/local/include"; then
20137 if test -n "$GCC"; then
20138 case $host_os in
20139 linux*) haveit=yes;;
20140 esac
20141 fi
20142 fi
20143 if test -z "$haveit"; then
20144 for x in $CPPFLAGS $INCICONV; do
20145
20146 acl_save_prefix="$prefix"
20147 prefix="$acl_final_prefix"
20148 acl_save_exec_prefix="$exec_prefix"
20149 exec_prefix="$acl_final_exec_prefix"
20150 eval x=\"$x\"
20151 exec_prefix="$acl_save_exec_prefix"
20152 prefix="$acl_save_prefix"
20153
20154 if test "X$x" = "X-I$additional_includedir"; then
20155 haveit=yes
20156 break
20157 fi
20158 done
20159 if test -z "$haveit"; then
20160 if test -d "$additional_includedir"; then
20161 INCICONV="${INCICONV}${INCICONV:+ }-I$additional_includedir"
20162 fi
20163 fi
20164 fi
20165 fi
20166 fi
20167 if test -n "$found_la"; then
20168 save_libdir="$libdir"
20169 case "$found_la" in
20170 */* | *\\*) . "$found_la" ;;
20171 *) . "./$found_la" ;;
20172 esac
20173 libdir="$save_libdir"
20174 for dep in $dependency_libs; do
20175 case "$dep" in
20176 -L*)
20177 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
20178 if test "X$additional_libdir" != "X/usr/lib"; then
20179 haveit=
20180 if test "X$additional_libdir" = "X/usr/local/lib"; then
20181 if test -n "$GCC"; then
20182 case $host_os in
20183 linux*) haveit=yes;;
20184 esac
20185 fi
20186 fi
20187 if test -z "$haveit"; then
20188 haveit=
20189 for x in $LDFLAGS $LIBICONV; do
20190
20191 acl_save_prefix="$prefix"
20192 prefix="$acl_final_prefix"
20193 acl_save_exec_prefix="$exec_prefix"
20194 exec_prefix="$acl_final_exec_prefix"
20195 eval x=\"$x\"
20196 exec_prefix="$acl_save_exec_prefix"
20197 prefix="$acl_save_prefix"
20198
20199 if test "X$x" = "X-L$additional_libdir"; then
20200 haveit=yes
20201 break
20202 fi
20203 done
20204 if test -z "$haveit"; then
20205 if test -d "$additional_libdir"; then
20206 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$additional_libdir"
20207 fi
20208 fi
20209 haveit=
20210 for x in $LDFLAGS $LTLIBICONV; do
20211
20212 acl_save_prefix="$prefix"
20213 prefix="$acl_final_prefix"
20214 acl_save_exec_prefix="$exec_prefix"
20215 exec_prefix="$acl_final_exec_prefix"
20216 eval x=\"$x\"
20217 exec_prefix="$acl_save_exec_prefix"
20218 prefix="$acl_save_prefix"
20219
20220 if test "X$x" = "X-L$additional_libdir"; then
20221 haveit=yes
20222 break
20223 fi
20224 done
20225 if test -z "$haveit"; then
20226 if test -d "$additional_libdir"; then
20227 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$additional_libdir"
20228 fi
20229 fi
20230 fi
20231 fi
20232 ;;
20233 -R*)
20234 dir=`echo "X$dep" | sed -e 's/^X-R//'`
20235 if test "$enable_rpath" != no; then
20236 haveit=
20237 for x in $rpathdirs; do
20238 if test "X$x" = "X$dir"; then
20239 haveit=yes
20240 break
20241 fi
20242 done
20243 if test -z "$haveit"; then
20244 rpathdirs="$rpathdirs $dir"
20245 fi
20246 haveit=
20247 for x in $ltrpathdirs; do
20248 if test "X$x" = "X$dir"; then
20249 haveit=yes
20250 break
20251 fi
20252 done
20253 if test -z "$haveit"; then
20254 ltrpathdirs="$ltrpathdirs $dir"
20255 fi
20256 fi
20257 ;;
20258 -l*)
20259 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
20260 ;;
20261 *.la)
20262 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
20263 ;;
20264 *)
20265 LIBICONV="${LIBICONV}${LIBICONV:+ }$dep"
20266 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$dep"
20267 ;;
20268 esac
20269 done
20270 fi
20271 else
20272 if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
20273 LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
20274 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l$name"
20275 else
20276 LIBICONV="${LIBICONV}${LIBICONV:+ }-l:lib$name.$libext"
20277 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l:lib$name.$libext"
20278 fi
20279 fi
20280 fi
20281 fi
20282 done
20283 done
20284 if test "X$rpathdirs" != "X"; then
20285 if test -n "$hardcode_libdir_separator"; then
20286 alldirs=
20287 for found_dir in $rpathdirs; do
20288 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
20289 done
20290 acl_save_libdir="$libdir"
20291 libdir="$alldirs"
20292 eval flag=\"$hardcode_libdir_flag_spec\"
20293 libdir="$acl_save_libdir"
20294 LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
20295 else
20296 for found_dir in $rpathdirs; do
20297 acl_save_libdir="$libdir"
20298 libdir="$found_dir"
20299 eval flag=\"$hardcode_libdir_flag_spec\"
20300 libdir="$acl_save_libdir"
20301 LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
20302 done
20303 fi
20304 fi
20305 if test "X$ltrpathdirs" != "X"; then
20306 for found_dir in $ltrpathdirs; do
20307 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-R$found_dir"
20308 done
20309 fi
20310
20311
20312
20313
20314
20315
20316
20317 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5
20318$as_echo_n "checking for iconv... " >&6; }
20319if ${am_cv_func_iconv+:} false; then :
20320 $as_echo_n "(cached) " >&6
20321else
20322
20323 am_cv_func_iconv="no, consider installing GNU libiconv"
20324 am_cv_lib_iconv=no
20325 am_save_CPPFLAGS="$CPPFLAGS"
20326 CPPFLAGS="$CPPFLAGS $INCICONV"
20327 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20328/* end confdefs.h. */
20329#include <stdlib.h>
20330#include <iconv.h>
20331int
20332main ()
20333{
20334iconv_t cd = iconv_open("","");
20335 iconv(cd,NULL,NULL,NULL,NULL);
20336 iconv_close(cd);
20337 ;
20338 return 0;
20339}
20340_ACEOF
20341if ac_fn_c_try_link "$LINENO"; then :
20342 am_cv_func_iconv=yes
20343fi
20344rm -f core conftest.err conftest.$ac_objext \
20345 conftest$ac_exeext conftest.$ac_ext
20346 CPPFLAGS="$am_save_CPPFLAGS"
20347
20348 if test "$am_cv_func_iconv" != yes && test -d ../libiconv; then
20349 for _libs in .libs _libs; do
20350 am_save_CPPFLAGS="$CPPFLAGS"
20351 am_save_LIBS="$LIBS"
20352 CPPFLAGS="$CPPFLAGS -I../libiconv/include"
20353 LIBS="$LIBS ../libiconv/lib/$_libs/libiconv.a"
20354 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20355/* end confdefs.h. */
20356#include <stdlib.h>
20357#include <iconv.h>
20358int
20359main ()
20360{
20361iconv_t cd = iconv_open("","");
20362 iconv(cd,NULL,NULL,NULL,NULL);
20363 iconv_close(cd);
20364 ;
20365 return 0;
20366}
20367_ACEOF
20368if ac_fn_c_try_link "$LINENO"; then :
20369 INCICONV="-I../libiconv/include"
20370 LIBICONV='${top_builddir}'/../libiconv/lib/$_libs/libiconv.a
20371 LTLIBICONV='${top_builddir}'/../libiconv/lib/libiconv.la
20372 am_cv_lib_iconv=yes
20373 am_cv_func_iconv=yes
20374fi
20375rm -f core conftest.err conftest.$ac_objext \
20376 conftest$ac_exeext conftest.$ac_ext
20377 CPPFLAGS="$am_save_CPPFLAGS"
20378 LIBS="$am_save_LIBS"
20379 if test "$am_cv_func_iconv" = "yes"; then
20380 break
20381 fi
20382 done
20383 fi
20384
20385 if test "$am_cv_func_iconv" != yes; then
20386 am_save_CPPFLAGS="$CPPFLAGS"
20387 am_save_LIBS="$LIBS"
20388 CPPFLAGS="$CPPFLAGS $INCICONV"
20389 LIBS="$LIBS $LIBICONV"
20390 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20391/* end confdefs.h. */
20392#include <stdlib.h>
20393#include <iconv.h>
20394int
20395main ()
20396{
20397iconv_t cd = iconv_open("","");
20398 iconv(cd,NULL,NULL,NULL,NULL);
20399 iconv_close(cd);
20400 ;
20401 return 0;
20402}
20403_ACEOF
20404if ac_fn_c_try_link "$LINENO"; then :
20405 am_cv_lib_iconv=yes
20406 am_cv_func_iconv=yes
20407fi
20408rm -f core conftest.err conftest.$ac_objext \
20409 conftest$ac_exeext conftest.$ac_ext
20410 CPPFLAGS="$am_save_CPPFLAGS"
20411 LIBS="$am_save_LIBS"
20412 fi
20413
20414fi
20415{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5
20416$as_echo "$am_cv_func_iconv" >&6; }
20417 if test "$am_cv_func_iconv" = yes; then
20418
20419$as_echo "#define HAVE_ICONV 1" >>confdefs.h
20420
20421 fi
20422 if test "$am_cv_lib_iconv" = yes; then
20423
20424 for element in $INCICONV; do
20425 haveit=
20426 for x in $CPPFLAGS; do
20427
20428 acl_save_prefix="$prefix"
20429 prefix="$acl_final_prefix"
20430 acl_save_exec_prefix="$exec_prefix"
20431 exec_prefix="$acl_final_exec_prefix"
20432 eval x=\"$x\"
20433 exec_prefix="$acl_save_exec_prefix"
20434 prefix="$acl_save_prefix"
20435
20436 if test "X$x" = "X$element"; then
20437 haveit=yes
20438 break
20439 fi
20440 done
20441 if test -z "$haveit"; then
20442 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
20443 fi
20444 done
20445
20446 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libiconv" >&5
20447$as_echo_n "checking how to link with libiconv... " >&6; }
20448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBICONV" >&5
20449$as_echo "$LIBICONV" >&6; }
20450 else
20451 LIBICONV=
20452 LTLIBICONV=
20453 fi
20454
20455
20456
20457 if test "$am_cv_func_iconv" = yes; then
20458 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv declaration" >&5
20459$as_echo_n "checking for iconv declaration... " >&6; }
20460 if ${am_cv_proto_iconv+:} false; then :
20461 $as_echo_n "(cached) " >&6
20462else
20463
20464 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20465/* end confdefs.h. */
20466
20467#include <stdlib.h>
20468#include <iconv.h>
20469extern
20470#ifdef __cplusplus
20471"C"
20472#endif
20473#if defined(__STDC__) || defined(__cplusplus)
20474size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);
20475#else
20476size_t iconv();
20477#endif
20478
20479int
20480main ()
20481{
20482
20483 ;
20484 return 0;
20485}
20486_ACEOF
20487if ac_fn_c_try_compile "$LINENO"; then :
20488 am_cv_proto_iconv_arg1=""
20489else
20490 am_cv_proto_iconv_arg1="const"
20491fi
20492rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20493 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);"
20494fi
20495
20496 am_cv_proto_iconv=`echo "$am_cv_proto_iconv" | tr -s ' ' | sed -e 's/( /(/'`
20497 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${ac_t:-
20498 }$am_cv_proto_iconv" >&5
20499$as_echo "${ac_t:-
20500 }$am_cv_proto_iconv" >&6; }
20501
20502cat >>confdefs.h <<_ACEOF
20503#define ICONV_CONST $am_cv_proto_iconv_arg1
20504_ACEOF
20505
20506 fi
20507
20508
20509# GDB may fork/exec the iconv program to get the list of supported character
20510# sets. Allow the user to specify where to find it.
20511# There are several factors affecting the choice of option name:
20512# - There is already --with-libiconv-prefix but we can't use it, it specifies
20513# the build-time location of libiconv files.
20514# - The program we need to find is iconv, which comes with glibc. The user
20515# doesn't necessarily have libiconv installed. Therefore naming this
20516# --with-libiconv-foo feels wrong.
20517# - We want the path to be relocatable, but GDB_AC_DEFINE_RELOCATABLE is
20518# defined to work on directories not files (though it really doesn't know
20519# the difference).
20520# - Calling this --with-iconv-prefix is perceived to cause too much confusion
20521# with --with-libiconv-prefix.
20522# Putting these together is why the option name is --with-iconv-bin.
20523
20524
20525# Check whether --with-iconv-bin was given.
20526if test "${with_iconv_bin+set}" = set; then :
20527 withval=$with_iconv_bin; iconv_bin="${withval}"
20528
20529cat >>confdefs.h <<_ACEOF
20530#define ICONV_BIN "${iconv_bin}"
20531_ACEOF
20532
20533
20534 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
20535 if test "x$prefix" = xNONE; then
20536 test_prefix=/usr/local
20537 else
20538 test_prefix=$prefix
20539 fi
20540 else
20541 test_prefix=$exec_prefix
20542 fi
20543 value=0
20544 case ${iconv_bin} in
20545 "${test_prefix}"|"${test_prefix}/"*|\
20546 '${exec_prefix}'|'${exec_prefix}/'*)
20547 value=1
20548 ;;
20549 esac
20550
20551cat >>confdefs.h <<_ACEOF
20552#define ICONV_BIN_RELOCATABLE $value
20553_ACEOF
20554
20555
20556
20557fi
20558
20559
20560# For the TUI, we need enhanced curses functionality.
20561if test x"$enable_tui" != xno; then
20562 prefer_curses=yes
20563fi
20564
20565curses_found=no
20566if test x"$prefer_curses" = xyes; then
20567 # FIXME: kettenis/20040905: We prefer ncurses over the vendor-supplied
20568 # curses library because the latter might not provide all the
20569 # functionality we need. However, this leads to problems on systems
20570 # where the linker searches /usr/local/lib, but the compiler doesn't
20571 # search /usr/local/include, if ncurses is installed in /usr/local. A
20572 # default installation of ncurses on alpha*-dec-osf* will lead to such
20573 # a situation.
20574 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing waddstr" >&5
20575$as_echo_n "checking for library containing waddstr... " >&6; }
20576if ${ac_cv_search_waddstr+:} false; then :
20577 $as_echo_n "(cached) " >&6
20578else
20579 ac_func_search_save_LIBS=$LIBS
20580cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20581/* end confdefs.h. */
20582
20583/* Override any GCC internal prototype to avoid an error.
20584 Use char because int might match the return type of a GCC
20585 builtin and then its argument prototype would still apply. */
20586#ifdef __cplusplus
20587extern "C"
20588#endif
20589char waddstr ();
20590int
20591main ()
20592{
20593return waddstr ();
20594 ;
20595 return 0;
20596}
20597_ACEOF
20598for ac_lib in '' ncursesw ncurses cursesX curses; do
20599 if test -z "$ac_lib"; then
20600 ac_res="none required"
20601 else
20602 ac_res=-l$ac_lib
20603 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
20604 fi
20605 if ac_fn_c_try_link "$LINENO"; then :
20606 ac_cv_search_waddstr=$ac_res
20607fi
20608rm -f core conftest.err conftest.$ac_objext \
20609 conftest$ac_exeext
20610 if ${ac_cv_search_waddstr+:} false; then :
20611 break
20612fi
20613done
20614if ${ac_cv_search_waddstr+:} false; then :
20615
20616else
20617 ac_cv_search_waddstr=no
20618fi
20619rm conftest.$ac_ext
20620LIBS=$ac_func_search_save_LIBS
20621fi
20622{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_waddstr" >&5
20623$as_echo "$ac_cv_search_waddstr" >&6; }
20624ac_res=$ac_cv_search_waddstr
20625if test "$ac_res" != no; then :
20626 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
20627
20628fi
20629
20630
20631 if test "$ac_cv_search_waddstr" != no; then
20632 curses_found=yes
20633 fi
20634fi
20635
20636# Check whether we should enable the TUI, but only do so if we really
20637# can.
20638if test x"$enable_tui" != xno; then
20639 if test -d "$srcdir/tui"; then
20640 if test "$curses_found" != no; then
20641 CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_TUI_OBS)"
20642 CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_TUI_DEPS)"
20643 CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_TUI_SRCS)"
20644 ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_TUI_CFLAGS)"
20645 else
20646 if test x"$enable_tui" = xyes; then
20647 as_fn_error $? "no enhanced curses library found; disable TUI" "$LINENO" 5
20648 else
20649 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no enhanced curses library found; disabling TUI" >&5
20650$as_echo "$as_me: WARNING: no enhanced curses library found; disabling TUI" >&2;}
20651 fi
20652 fi
20653 fi
20654fi
20655
20656# Since GDB uses Readline, we need termcap functionality. In many
20657# cases this will be provided by the curses library, but some systems
20658# have a separate termcap library, or no curses library at all.
20659
20660case $host_os in
20661 cygwin*)
20662 if test -d "$srcdir/libtermcap"; then
20663 LIBS="../libtermcap/libtermcap.a $LIBS"
20664 ac_cv_search_tgetent="../libtermcap/libtermcap.a"
20665 fi ;;
20666 go32* | *djgpp*)
20667 ac_cv_search_tgetent="none required"
20668 ;;
20669esac
20670
20671# These are the libraries checked by Readline.
20672{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing tgetent" >&5
20673$as_echo_n "checking for library containing tgetent... " >&6; }
20674if ${ac_cv_search_tgetent+:} false; then :
20675 $as_echo_n "(cached) " >&6
20676else
20677 ac_func_search_save_LIBS=$LIBS
20678cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20679/* end confdefs.h. */
20680
20681/* Override any GCC internal prototype to avoid an error.
20682 Use char because int might match the return type of a GCC
20683 builtin and then its argument prototype would still apply. */
20684#ifdef __cplusplus
20685extern "C"
20686#endif
20687char tgetent ();
20688int
20689main ()
20690{
20691return tgetent ();
20692 ;
20693 return 0;
20694}
20695_ACEOF
20696for ac_lib in '' termcap tinfow tinfo curses ncursesw ncurses; do
20697 if test -z "$ac_lib"; then
20698 ac_res="none required"
20699 else
20700 ac_res=-l$ac_lib
20701 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
20702 fi
20703 if ac_fn_c_try_link "$LINENO"; then :
20704 ac_cv_search_tgetent=$ac_res
20705fi
20706rm -f core conftest.err conftest.$ac_objext \
20707 conftest$ac_exeext
20708 if ${ac_cv_search_tgetent+:} false; then :
20709 break
20710fi
20711done
20712if ${ac_cv_search_tgetent+:} false; then :
20713
20714else
20715 ac_cv_search_tgetent=no
20716fi
20717rm conftest.$ac_ext
20718LIBS=$ac_func_search_save_LIBS
20719fi
20720{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_tgetent" >&5
20721$as_echo "$ac_cv_search_tgetent" >&6; }
20722ac_res=$ac_cv_search_tgetent
20723if test "$ac_res" != no; then :
20724 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
20725
20726fi
20727
20728
20729if test "$ac_cv_search_tgetent" = no; then
20730 CONFIG_OBS="$CONFIG_OBS stub-termcap.o"
20731fi
20732
20733
20734# Check whether --with-system-readline was given.
20735if test "${with_system_readline+set}" = set; then :
20736 withval=$with_system_readline;
20737fi
20738
20739
20740if test "$with_system_readline" = yes; then
20741 for ac_header in readline/readline.h
20742do :
20743 ac_fn_c_check_header_mongrel "$LINENO" "readline/readline.h" "ac_cv_header_readline_readline_h" "$ac_includes_default"
20744if test "x$ac_cv_header_readline_readline_h" = xyes; then :
20745 cat >>confdefs.h <<_ACEOF
20746#define HAVE_READLINE_READLINE_H 1
20747_ACEOF
20748 readline_h=yes
20749else
20750 readline_h=no
20751fi
20752
20753done
20754
20755 if test "$readline_h" = "no"; then
20756 as_fn_error $? "readline development packages are probably missing" "$LINENO" 5
20757 fi
20758 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system readline is new enough" >&5
20759$as_echo_n "checking whether system readline is new enough... " >&6; }
20760if ${gdb_cv_readline_ok+:} false; then :
20761 $as_echo_n "(cached) " >&6
20762else
20763 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20764/* end confdefs.h. */
20765#include <stdio.h>
20766 #include <readline/readline.h>
20767int
20768main ()
20769{
20770#if RL_VERSION_MAJOR < 7
20771 # error "readline version 7 required"
20772 #endif
20773
20774 ;
20775 return 0;
20776}
20777_ACEOF
20778if ac_fn_c_try_compile "$LINENO"; then :
20779 gdb_cv_readline_ok=yes
20780else
20781 gdb_cv_readline_ok=no
20782
20783fi
20784rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20785
20786fi
20787{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_readline_ok" >&5
20788$as_echo "$gdb_cv_readline_ok" >&6; }
20789 if test "$gdb_cv_readline_ok" != yes; then
20790 as_fn_error $? "system readline is not new enough" "$LINENO" 5
20791 fi
20792
20793 READLINE=-lreadline
20794 READLINE_DEPS=
20795 READLINE_CFLAGS=
20796 READLINE_TEXI_INCFLAG=
14d0e681 20797 READLINE_DOC_SOURCE_INCLUDES='$(READLINE_SYSTEM_DOC_INCLUDES)'
b686ecb5
JM
20798else
20799 READLINE='$(READLINE_DIR)/libreadline.a'
20800 READLINE_DEPS='$(READLINE)'
20801 READLINE_CFLAGS='-I$(READLINE_SRC)/..'
20802 READLINE_TEXI_INCFLAG='-I $(READLINE_DIR)'
14d0e681 20803 READLINE_DOC_SOURCE_INCLUDES='$(READLINE_INTREE_DOC_INCLUDES)'
b686ecb5
JM
20804fi
20805
20806
20807
20808
20809
14d0e681 20810
b686ecb5
JM
20811# Generate jit-reader.h
20812
20813# This is typedeffed to GDB_CORE_ADDR in jit-reader.h
20814TARGET_PTR=
20815
20816# The cast to long int works around a bug in the HP C Compiler
20817# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
20818# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
20819# This bug is HP SR number 8606223364.
20820{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of unsigned long long" >&5
20821$as_echo_n "checking size of unsigned long long... " >&6; }
20822if ${ac_cv_sizeof_unsigned_long_long+:} false; then :
20823 $as_echo_n "(cached) " >&6
20824else
20825 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (unsigned long long))" "ac_cv_sizeof_unsigned_long_long" "$ac_includes_default"; then :
20826
20827else
20828 if test "$ac_cv_type_unsigned_long_long" = yes; then
20829 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
20830$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
20831as_fn_error 77 "cannot compute sizeof (unsigned long long)
20832See \`config.log' for more details" "$LINENO" 5; }
20833 else
20834 ac_cv_sizeof_unsigned_long_long=0
20835 fi
20836fi
20837
20838fi
20839{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_unsigned_long_long" >&5
20840$as_echo "$ac_cv_sizeof_unsigned_long_long" >&6; }
20841
20842
20843
20844cat >>confdefs.h <<_ACEOF
20845#define SIZEOF_UNSIGNED_LONG_LONG $ac_cv_sizeof_unsigned_long_long
20846_ACEOF
20847
20848
20849# The cast to long int works around a bug in the HP C Compiler
20850# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
20851# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
20852# This bug is HP SR number 8606223364.
20853{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of unsigned long" >&5
20854$as_echo_n "checking size of unsigned long... " >&6; }
20855if ${ac_cv_sizeof_unsigned_long+:} false; then :
20856 $as_echo_n "(cached) " >&6
20857else
20858 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (unsigned long))" "ac_cv_sizeof_unsigned_long" "$ac_includes_default"; then :
20859
20860else
20861 if test "$ac_cv_type_unsigned_long" = yes; then
20862 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
20863$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
20864as_fn_error 77 "cannot compute sizeof (unsigned long)
20865See \`config.log' for more details" "$LINENO" 5; }
20866 else
20867 ac_cv_sizeof_unsigned_long=0
20868 fi
20869fi
20870
20871fi
20872{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_unsigned_long" >&5
20873$as_echo "$ac_cv_sizeof_unsigned_long" >&6; }
20874
20875
20876
20877cat >>confdefs.h <<_ACEOF
20878#define SIZEOF_UNSIGNED_LONG $ac_cv_sizeof_unsigned_long
20879_ACEOF
20880
20881
20882# The cast to long int works around a bug in the HP C Compiler
20883# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
20884# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
20885# This bug is HP SR number 8606223364.
20886{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of unsigned __int128" >&5
20887$as_echo_n "checking size of unsigned __int128... " >&6; }
20888if ${ac_cv_sizeof_unsigned___int128+:} false; then :
20889 $as_echo_n "(cached) " >&6
20890else
20891 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (unsigned __int128))" "ac_cv_sizeof_unsigned___int128" "$ac_includes_default"; then :
20892
20893else
20894 if test "$ac_cv_type_unsigned___int128" = yes; then
20895 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
20896$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
20897as_fn_error 77 "cannot compute sizeof (unsigned __int128)
20898See \`config.log' for more details" "$LINENO" 5; }
20899 else
20900 ac_cv_sizeof_unsigned___int128=0
20901 fi
20902fi
20903
20904fi
20905{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_unsigned___int128" >&5
20906$as_echo "$ac_cv_sizeof_unsigned___int128" >&6; }
20907
20908
20909
20910cat >>confdefs.h <<_ACEOF
20911#define SIZEOF_UNSIGNED___INT128 $ac_cv_sizeof_unsigned___int128
20912_ACEOF
20913
20914
20915
20916if test "x${ac_cv_sizeof_unsigned_long}" = "x8"; then
20917 TARGET_PTR="unsigned long"
20918elif test "x${ac_cv_sizeof_unsigned_long_long}" = "x8"; then
20919 TARGET_PTR="unsigned long long"
20920elif test "x${ac_cv_sizeof_unsigned___int128}" = "x16"; then
20921 TARGET_PTR="unsigned __int128"
20922else
20923 TARGET_PTR="unsigned long"
20924fi
20925
20926
20927ac_config_files="$ac_config_files jit-reader.h:jit-reader.in"
20928
20929
20930{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlopen" >&5
20931$as_echo_n "checking for library containing dlopen... " >&6; }
20932if ${ac_cv_search_dlopen+:} false; then :
20933 $as_echo_n "(cached) " >&6
20934else
20935 ac_func_search_save_LIBS=$LIBS
20936cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20937/* end confdefs.h. */
20938
20939/* Override any GCC internal prototype to avoid an error.
20940 Use char because int might match the return type of a GCC
20941 builtin and then its argument prototype would still apply. */
20942#ifdef __cplusplus
20943extern "C"
20944#endif
20945char dlopen ();
20946int
20947main ()
20948{
20949return dlopen ();
20950 ;
20951 return 0;
20952}
20953_ACEOF
20954for ac_lib in '' dl; do
20955 if test -z "$ac_lib"; then
20956 ac_res="none required"
20957 else
20958 ac_res=-l$ac_lib
20959 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
20960 fi
20961 if ac_fn_c_try_link "$LINENO"; then :
20962 ac_cv_search_dlopen=$ac_res
20963fi
20964rm -f core conftest.err conftest.$ac_objext \
20965 conftest$ac_exeext
20966 if ${ac_cv_search_dlopen+:} false; then :
20967 break
20968fi
20969done
20970if ${ac_cv_search_dlopen+:} false; then :
20971
20972else
20973 ac_cv_search_dlopen=no
20974fi
20975rm conftest.$ac_ext
20976LIBS=$ac_func_search_save_LIBS
20977fi
20978{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlopen" >&5
20979$as_echo "$ac_cv_search_dlopen" >&6; }
20980ac_res=$ac_cv_search_dlopen
20981if test "$ac_res" != no; then :
20982 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
20983
20984fi
20985
20986
20987
20988
20989# Check whether --with-jit-reader-dir was given.
20990if test "${with_jit_reader_dir+set}" = set; then :
20991 withval=$with_jit_reader_dir;
20992 JIT_READER_DIR=$withval
20993else
20994 JIT_READER_DIR=${libdir}/gdb
20995fi
20996
20997
20998 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
20999 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
21000 ac_define_dir=`eval echo $JIT_READER_DIR`
21001 ac_define_dir=`eval echo $ac_define_dir`
21002
21003cat >>confdefs.h <<_ACEOF
21004#define JIT_READER_DIR "$ac_define_dir"
21005_ACEOF
21006
21007
21008
21009
21010 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
21011 if test "x$prefix" = xNONE; then
21012 test_prefix=/usr/local
21013 else
21014 test_prefix=$prefix
21015 fi
21016 else
21017 test_prefix=$exec_prefix
21018 fi
21019 value=0
21020 case ${ac_define_dir} in
21021 "${test_prefix}"|"${test_prefix}/"*|\
21022 '${exec_prefix}'|'${exec_prefix}/'*)
21023 value=1
21024 ;;
21025 esac
21026
21027cat >>confdefs.h <<_ACEOF
21028#define JIT_READER_DIR_RELOCATABLE $value
21029_ACEOF
21030
21031
21032
21033
21034
21035# Check whether --with-expat was given.
21036if test "${with_expat+set}" = set; then :
21037 withval=$with_expat;
21038else
21039 with_expat=auto
21040fi
21041
21042{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use expat" >&5
21043$as_echo_n "checking whether to use expat... " >&6; }
21044{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_expat" >&5
21045$as_echo "$with_expat" >&6; }
21046
21047if test "${with_expat}" = no; then
21048 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: expat support disabled; some features may be unavailable." >&5
21049$as_echo "$as_me: WARNING: expat support disabled; some features may be unavailable." >&2;}
21050 HAVE_LIBEXPAT=no
21051else
21052
21053
21054
21055
21056
21057
21058
21059
21060 use_additional=yes
21061
21062 acl_save_prefix="$prefix"
21063 prefix="$acl_final_prefix"
21064 acl_save_exec_prefix="$exec_prefix"
21065 exec_prefix="$acl_final_exec_prefix"
21066
21067 eval additional_includedir=\"$includedir\"
21068 eval additional_libdir=\"$libdir\"
21069
21070 exec_prefix="$acl_save_exec_prefix"
21071 prefix="$acl_save_prefix"
21072
21073
21074# Check whether --with-libexpat-prefix was given.
21075if test "${with_libexpat_prefix+set}" = set; then :
21076 withval=$with_libexpat_prefix;
21077 if test "X$withval" = "Xno"; then
21078 use_additional=no
21079 else
21080 if test "X$withval" = "X"; then
21081
21082 acl_save_prefix="$prefix"
21083 prefix="$acl_final_prefix"
21084 acl_save_exec_prefix="$exec_prefix"
21085 exec_prefix="$acl_final_exec_prefix"
21086
21087 eval additional_includedir=\"$includedir\"
21088 eval additional_libdir=\"$libdir\"
21089
21090 exec_prefix="$acl_save_exec_prefix"
21091 prefix="$acl_save_prefix"
21092
21093 else
21094 additional_includedir="$withval/include"
21095 additional_libdir="$withval/lib"
21096 fi
21097 fi
21098
21099fi
21100
21101
21102# Check whether --with-libexpat-type was given.
21103if test "${with_libexpat_type+set}" = set; then :
21104 withval=$with_libexpat_type; with_libexpat_type=$withval
21105else
21106 with_libexpat_type=auto
21107fi
21108
21109 lib_type=`eval echo \$with_libexpat_type`
21110
21111 LIBEXPAT=
21112 LTLIBEXPAT=
21113 INCEXPAT=
21114 rpathdirs=
21115 ltrpathdirs=
21116 names_already_handled=
21117 names_next_round='expat '
21118 while test -n "$names_next_round"; do
21119 names_this_round="$names_next_round"
21120 names_next_round=
21121 for name in $names_this_round; do
21122 already_handled=
21123 for n in $names_already_handled; do
21124 if test "$n" = "$name"; then
21125 already_handled=yes
21126 break
21127 fi
21128 done
21129 if test -z "$already_handled"; then
21130 names_already_handled="$names_already_handled $name"
21131 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
21132 eval value=\"\$HAVE_LIB$uppername\"
21133 if test -n "$value"; then
21134 if test "$value" = yes; then
21135 eval value=\"\$LIB$uppername\"
21136 test -z "$value" || LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$value"
21137 eval value=\"\$LTLIB$uppername\"
21138 test -z "$value" || LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }$value"
21139 else
21140 :
21141 fi
21142 else
21143 found_dir=
21144 found_la=
21145 found_so=
21146 found_a=
21147 if test $use_additional = yes; then
21148 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
21149 found_dir="$additional_libdir"
21150 found_so="$additional_libdir/lib$name.$shlibext"
21151 if test -f "$additional_libdir/lib$name.la"; then
21152 found_la="$additional_libdir/lib$name.la"
21153 fi
21154 elif test x$lib_type != xshared; then
21155 if test -f "$additional_libdir/lib$name.$libext"; then
21156 found_dir="$additional_libdir"
21157 found_a="$additional_libdir/lib$name.$libext"
21158 if test -f "$additional_libdir/lib$name.la"; then
21159 found_la="$additional_libdir/lib$name.la"
21160 fi
21161 fi
21162 fi
21163 fi
21164 if test "X$found_dir" = "X"; then
21165 for x in $LDFLAGS $LTLIBEXPAT; do
21166
21167 acl_save_prefix="$prefix"
21168 prefix="$acl_final_prefix"
21169 acl_save_exec_prefix="$exec_prefix"
21170 exec_prefix="$acl_final_exec_prefix"
21171 eval x=\"$x\"
21172 exec_prefix="$acl_save_exec_prefix"
21173 prefix="$acl_save_prefix"
21174
21175 case "$x" in
21176 -L*)
21177 dir=`echo "X$x" | sed -e 's/^X-L//'`
21178 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
21179 found_dir="$dir"
21180 found_so="$dir/lib$name.$shlibext"
21181 if test -f "$dir/lib$name.la"; then
21182 found_la="$dir/lib$name.la"
21183 fi
21184 elif test x$lib_type != xshared; then
21185 if test -f "$dir/lib$name.$libext"; then
21186 found_dir="$dir"
21187 found_a="$dir/lib$name.$libext"
21188 if test -f "$dir/lib$name.la"; then
21189 found_la="$dir/lib$name.la"
21190 fi
21191 fi
21192 fi
21193 ;;
21194 esac
21195 if test "X$found_dir" != "X"; then
21196 break
21197 fi
21198 done
21199 fi
21200 if test "X$found_dir" != "X"; then
21201 LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-L$found_dir -l$name"
21202 if test "X$found_so" != "X"; then
21203 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
21204 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_so"
21205 else
21206 haveit=
21207 for x in $ltrpathdirs; do
21208 if test "X$x" = "X$found_dir"; then
21209 haveit=yes
21210 break
21211 fi
21212 done
21213 if test -z "$haveit"; then
21214 ltrpathdirs="$ltrpathdirs $found_dir"
21215 fi
21216 if test "$hardcode_direct" = yes; then
21217 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_so"
21218 else
21219 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
21220 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_so"
21221 haveit=
21222 for x in $rpathdirs; do
21223 if test "X$x" = "X$found_dir"; then
21224 haveit=yes
21225 break
21226 fi
21227 done
21228 if test -z "$haveit"; then
21229 rpathdirs="$rpathdirs $found_dir"
21230 fi
21231 else
21232 haveit=
21233 for x in $LDFLAGS $LIBEXPAT; do
21234
21235 acl_save_prefix="$prefix"
21236 prefix="$acl_final_prefix"
21237 acl_save_exec_prefix="$exec_prefix"
21238 exec_prefix="$acl_final_exec_prefix"
21239 eval x=\"$x\"
21240 exec_prefix="$acl_save_exec_prefix"
21241 prefix="$acl_save_prefix"
21242
21243 if test "X$x" = "X-L$found_dir"; then
21244 haveit=yes
21245 break
21246 fi
21247 done
21248 if test -z "$haveit"; then
21249 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-L$found_dir"
21250 fi
21251 if test "$hardcode_minus_L" != no; then
21252 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_so"
21253 else
21254 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-l$name"
21255 fi
21256 fi
21257 fi
21258 fi
21259 else
21260 if test "X$found_a" != "X"; then
21261 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_a"
21262 else
21263 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-L$found_dir -l$name"
21264 fi
21265 fi
21266 additional_includedir=
21267 case "$found_dir" in
21268 */lib | */lib/)
21269 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
21270 additional_includedir="$basedir/include"
21271 ;;
21272 esac
21273 if test "X$additional_includedir" != "X"; then
21274 if test "X$additional_includedir" != "X/usr/include"; then
21275 haveit=
21276 if test "X$additional_includedir" = "X/usr/local/include"; then
21277 if test -n "$GCC"; then
21278 case $host_os in
21279 linux*) haveit=yes;;
21280 esac
21281 fi
21282 fi
21283 if test -z "$haveit"; then
21284 for x in $CPPFLAGS $INCEXPAT; do
21285
21286 acl_save_prefix="$prefix"
21287 prefix="$acl_final_prefix"
21288 acl_save_exec_prefix="$exec_prefix"
21289 exec_prefix="$acl_final_exec_prefix"
21290 eval x=\"$x\"
21291 exec_prefix="$acl_save_exec_prefix"
21292 prefix="$acl_save_prefix"
21293
21294 if test "X$x" = "X-I$additional_includedir"; then
21295 haveit=yes
21296 break
21297 fi
21298 done
21299 if test -z "$haveit"; then
21300 if test -d "$additional_includedir"; then
21301 INCEXPAT="${INCEXPAT}${INCEXPAT:+ }-I$additional_includedir"
21302 fi
21303 fi
21304 fi
21305 fi
21306 fi
21307 if test -n "$found_la"; then
21308 save_libdir="$libdir"
21309 case "$found_la" in
21310 */* | *\\*) . "$found_la" ;;
21311 *) . "./$found_la" ;;
21312 esac
21313 libdir="$save_libdir"
21314 for dep in $dependency_libs; do
21315 case "$dep" in
21316 -L*)
21317 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
21318 if test "X$additional_libdir" != "X/usr/lib"; then
21319 haveit=
21320 if test "X$additional_libdir" = "X/usr/local/lib"; then
21321 if test -n "$GCC"; then
21322 case $host_os in
21323 linux*) haveit=yes;;
21324 esac
21325 fi
21326 fi
21327 if test -z "$haveit"; then
21328 haveit=
21329 for x in $LDFLAGS $LIBEXPAT; do
21330
21331 acl_save_prefix="$prefix"
21332 prefix="$acl_final_prefix"
21333 acl_save_exec_prefix="$exec_prefix"
21334 exec_prefix="$acl_final_exec_prefix"
21335 eval x=\"$x\"
21336 exec_prefix="$acl_save_exec_prefix"
21337 prefix="$acl_save_prefix"
21338
21339 if test "X$x" = "X-L$additional_libdir"; then
21340 haveit=yes
21341 break
21342 fi
21343 done
21344 if test -z "$haveit"; then
21345 if test -d "$additional_libdir"; then
21346 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-L$additional_libdir"
21347 fi
21348 fi
21349 haveit=
21350 for x in $LDFLAGS $LTLIBEXPAT; do
21351
21352 acl_save_prefix="$prefix"
21353 prefix="$acl_final_prefix"
21354 acl_save_exec_prefix="$exec_prefix"
21355 exec_prefix="$acl_final_exec_prefix"
21356 eval x=\"$x\"
21357 exec_prefix="$acl_save_exec_prefix"
21358 prefix="$acl_save_prefix"
21359
21360 if test "X$x" = "X-L$additional_libdir"; then
21361 haveit=yes
21362 break
21363 fi
21364 done
21365 if test -z "$haveit"; then
21366 if test -d "$additional_libdir"; then
21367 LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-L$additional_libdir"
21368 fi
21369 fi
21370 fi
21371 fi
21372 ;;
21373 -R*)
21374 dir=`echo "X$dep" | sed -e 's/^X-R//'`
21375 if test "$enable_rpath" != no; then
21376 haveit=
21377 for x in $rpathdirs; do
21378 if test "X$x" = "X$dir"; then
21379 haveit=yes
21380 break
21381 fi
21382 done
21383 if test -z "$haveit"; then
21384 rpathdirs="$rpathdirs $dir"
21385 fi
21386 haveit=
21387 for x in $ltrpathdirs; do
21388 if test "X$x" = "X$dir"; then
21389 haveit=yes
21390 break
21391 fi
21392 done
21393 if test -z "$haveit"; then
21394 ltrpathdirs="$ltrpathdirs $dir"
21395 fi
21396 fi
21397 ;;
21398 -l*)
21399 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
21400 ;;
21401 *.la)
21402 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
21403 ;;
21404 *)
21405 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$dep"
21406 LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }$dep"
21407 ;;
21408 esac
21409 done
21410 fi
21411 else
21412 if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
21413 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-l$name"
21414 LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-l$name"
21415 else
21416 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-l:lib$name.$libext"
21417 LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-l:lib$name.$libext"
21418 fi
21419 fi
21420 fi
21421 fi
21422 done
21423 done
21424 if test "X$rpathdirs" != "X"; then
21425 if test -n "$hardcode_libdir_separator"; then
21426 alldirs=
21427 for found_dir in $rpathdirs; do
21428 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
21429 done
21430 acl_save_libdir="$libdir"
21431 libdir="$alldirs"
21432 eval flag=\"$hardcode_libdir_flag_spec\"
21433 libdir="$acl_save_libdir"
21434 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$flag"
21435 else
21436 for found_dir in $rpathdirs; do
21437 acl_save_libdir="$libdir"
21438 libdir="$found_dir"
21439 eval flag=\"$hardcode_libdir_flag_spec\"
21440 libdir="$acl_save_libdir"
21441 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$flag"
21442 done
21443 fi
21444 fi
21445 if test "X$ltrpathdirs" != "X"; then
21446 for found_dir in $ltrpathdirs; do
21447 LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-R$found_dir"
21448 done
21449 fi
21450
21451
21452 ac_save_CPPFLAGS="$CPPFLAGS"
21453
21454 for element in $INCEXPAT; do
21455 haveit=
21456 for x in $CPPFLAGS; do
21457
21458 acl_save_prefix="$prefix"
21459 prefix="$acl_final_prefix"
21460 acl_save_exec_prefix="$exec_prefix"
21461 exec_prefix="$acl_final_exec_prefix"
21462 eval x=\"$x\"
21463 exec_prefix="$acl_save_exec_prefix"
21464 prefix="$acl_save_prefix"
21465
21466 if test "X$x" = "X$element"; then
21467 haveit=yes
21468 break
21469 fi
21470 done
21471 if test -z "$haveit"; then
21472 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
21473 fi
21474 done
21475
21476
21477 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libexpat" >&5
21478$as_echo_n "checking for libexpat... " >&6; }
21479if ${ac_cv_libexpat+:} false; then :
21480 $as_echo_n "(cached) " >&6
21481else
21482
21483 ac_save_LIBS="$LIBS"
21484 LIBS="$LIBS $LIBEXPAT"
21485 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21486/* end confdefs.h. */
21487#include "expat.h"
21488int
21489main ()
21490{
21491XML_Parser p = XML_ParserCreate (0);
21492 ;
21493 return 0;
21494}
21495_ACEOF
21496if ac_fn_c_try_link "$LINENO"; then :
21497 ac_cv_libexpat=yes
21498else
21499 ac_cv_libexpat=no
21500fi
21501rm -f core conftest.err conftest.$ac_objext \
21502 conftest$ac_exeext conftest.$ac_ext
21503 LIBS="$ac_save_LIBS"
21504
21505fi
21506{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libexpat" >&5
21507$as_echo "$ac_cv_libexpat" >&6; }
21508 if test "$ac_cv_libexpat" = yes; then
21509 HAVE_LIBEXPAT=yes
21510
21511$as_echo "#define HAVE_LIBEXPAT 1" >>confdefs.h
21512
21513 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libexpat" >&5
21514$as_echo_n "checking how to link with libexpat... " >&6; }
21515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBEXPAT" >&5
21516$as_echo "$LIBEXPAT" >&6; }
21517 else
21518 HAVE_LIBEXPAT=no
21519 CPPFLAGS="$ac_save_CPPFLAGS"
21520 LIBEXPAT=
21521 LTLIBEXPAT=
21522 fi
21523
21524
21525
21526
21527
21528
21529 if test "$HAVE_LIBEXPAT" != yes; then
21530 if test "$with_expat" = yes; then
21531 as_fn_error $? "expat is missing or unusable" "$LINENO" 5
21532 else
21533 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: expat is missing or unusable; some features may be unavailable." >&5
21534$as_echo "$as_me: WARNING: expat is missing or unusable; some features may be unavailable." >&2;}
21535 fi
21536 else
21537 save_LIBS=$LIBS
21538 LIBS="$LIBS $LIBEXPAT"
21539 for ac_func in XML_StopParser
21540do :
21541 ac_fn_c_check_func "$LINENO" "XML_StopParser" "ac_cv_func_XML_StopParser"
21542if test "x$ac_cv_func_XML_StopParser" = xyes; then :
21543 cat >>confdefs.h <<_ACEOF
21544#define HAVE_XML_STOPPARSER 1
21545_ACEOF
21546
21547fi
21548done
21549
21550 LIBS=$save_LIBS
21551 fi
21552fi
21553
b686ecb5
JM
21554
21555
21556
b686ecb5
JM
21557# --------------------- #
21558# Check for libpython. #
21559# --------------------- #
21560
21561
21562
21563
21564
21565
21566# Check whether --with-python was given.
21567if test "${with_python+set}" = set; then :
21568 withval=$with_python;
21569else
21570 with_python=auto
21571fi
21572
21573{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use python" >&5
21574$as_echo_n "checking whether to use python... " >&6; }
21575{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_python" >&5
21576$as_echo "$with_python" >&6; }
21577
21578if test "${with_python}" = no; then
21579 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: python support disabled; some features may be unavailable." >&5
21580$as_echo "$as_me: WARNING: python support disabled; some features may be unavailable." >&2;}
21581 have_libpython=no
21582else
21583 case "${with_python}" in
21584 [\\/]* | ?:[\\/]*)
21585 if test -d "${with_python}"; then
21586 # Assume the python binary is ${with_python}/bin/python.
21587 python_prog="${with_python}/bin/python"
21588 python_prefix=
21589 # If python does not exit ${with_python}/bin, then try in
21590 # ${with_python}. On Windows/MinGW, this is where the Python
21591 # executable is.
21592 if test ! -x "${python_prog}"; then
21593 python_prog="${with_python}/python"
21594 python_prefix=
21595 fi
21596 if test ! -x "${python_prog}"; then
21597 # Fall back to gdb 7.0/7.1 behaviour.
21598 python_prog=missing
21599 python_prefix=${with_python}
21600 fi
21601 elif test -x "${with_python}"; then
21602 # While we can't run python compiled for $host (unless host == build),
21603 # the user could write a script that provides the needed information,
21604 # so we support that.
21605 python_prog=${with_python}
21606 python_prefix=
21607 else
21608 as_fn_error $? "invalid value for --with-python" "$LINENO" 5
21609 fi
21610 ;;
21611 */*)
21612 # Disallow --with-python=foo/bar.
21613 as_fn_error $? "invalid value for --with-python" "$LINENO" 5
21614 ;;
21615 *)
21616 # The user has either specified auto, yes, or the name of the python
21617 # program assumed to be in $PATH.
21618 python_prefix=
21619 case "${with_python}" in
21620 yes | auto)
21621 if test "${build}" = "${host}"; then
21622 # Look first for 'python', then 'python3'.
21623 for ac_prog in python python3
21624do
21625 # Extract the first word of "$ac_prog", so it can be a program name with args.
21626set dummy $ac_prog; ac_word=$2
21627{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
21628$as_echo_n "checking for $ac_word... " >&6; }
21629if ${ac_cv_path_python_prog_path+:} false; then :
21630 $as_echo_n "(cached) " >&6
21631else
21632 case $python_prog_path in
21633 [\\/]* | ?:[\\/]*)
21634 ac_cv_path_python_prog_path="$python_prog_path" # Let the user override the test with a path.
21635 ;;
21636 *)
21637 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21638for as_dir in $PATH
21639do
21640 IFS=$as_save_IFS
21641 test -z "$as_dir" && as_dir=.
21642 for ac_exec_ext in '' $ac_executable_extensions; do
21643 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21644 ac_cv_path_python_prog_path="$as_dir/$ac_word$ac_exec_ext"
21645 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
21646 break 2
21647 fi
21648done
21649 done
21650IFS=$as_save_IFS
21651
21652 ;;
21653esac
21654fi
21655python_prog_path=$ac_cv_path_python_prog_path
21656if test -n "$python_prog_path"; then
21657 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $python_prog_path" >&5
21658$as_echo "$python_prog_path" >&6; }
21659else
21660 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21661$as_echo "no" >&6; }
21662fi
21663
21664
21665 test -n "$python_prog_path" && break
21666done
21667test -n "$python_prog_path" || python_prog_path="missing"
21668
21669 if test "${python_prog_path}" = missing; then
21670 python_prog=missing
21671 else
21672 python_prog=${python_prog_path}
21673 fi
21674 else
21675 # Not much we can do except assume the cross-compiler will find the
21676 # right files.
21677 python_prog=missing
21678 fi
21679 ;;
21680 *)
21681 # While we can't run python compiled for $host (unless host == build),
21682 # the user could write a script that provides the needed information,
21683 # so we support that.
21684 python_prog="${with_python}"
21685 # Extract the first word of "${python_prog}", so it can be a program name with args.
21686set dummy ${python_prog}; ac_word=$2
21687{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
21688$as_echo_n "checking for $ac_word... " >&6; }
21689if ${ac_cv_path_python_prog_path+:} false; then :
21690 $as_echo_n "(cached) " >&6
21691else
21692 case $python_prog_path in
21693 [\\/]* | ?:[\\/]*)
21694 ac_cv_path_python_prog_path="$python_prog_path" # Let the user override the test with a path.
21695 ;;
21696 *)
21697 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21698for as_dir in $PATH
21699do
21700 IFS=$as_save_IFS
21701 test -z "$as_dir" && as_dir=.
21702 for ac_exec_ext in '' $ac_executable_extensions; do
21703 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21704 ac_cv_path_python_prog_path="$as_dir/$ac_word$ac_exec_ext"
21705 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
21706 break 2
21707 fi
21708done
21709 done
21710IFS=$as_save_IFS
21711
21712 test -z "$ac_cv_path_python_prog_path" && ac_cv_path_python_prog_path="missing"
21713 ;;
21714esac
21715fi
21716python_prog_path=$ac_cv_path_python_prog_path
21717if test -n "$python_prog_path"; then
21718 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $python_prog_path" >&5
21719$as_echo "$python_prog_path" >&6; }
21720else
21721 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21722$as_echo "no" >&6; }
21723fi
21724
21725
21726 if test "${python_prog_path}" = missing; then
21727 as_fn_error $? "unable to find python program ${python_prog}" "$LINENO" 5
21728 fi
21729 ;;
21730 esac
21731 esac
21732
21733 if test "${python_prog}" != missing; then
21734 # We have a python program to use, but it may be too old.
21735 # Don't flag an error for --with-python=auto (the default).
21736 have_python_config=yes
21737 python_includes=`${python_prog} ${srcdir}/python/python-config.py --includes`
21738 if test $? != 0; then
21739 have_python_config=failed
21740 if test "${with_python}" != auto; then
21741 as_fn_error $? "failure running python-config --includes" "$LINENO" 5
21742 fi
21743 fi
21744 python_libs=`${python_prog} ${srcdir}/python/python-config.py --ldflags`
21745 if test $? != 0; then
21746 have_python_config=failed
21747 if test "${with_python}" != auto; then
21748 as_fn_error $? "failure running python-config --ldflags" "$LINENO" 5
21749 fi
21750 fi
21751 python_prefix=`${python_prog} ${srcdir}/python/python-config.py --exec-prefix`
21752 if test $? != 0; then
21753 have_python_config=failed
21754 if test "${with_python}" != auto; then
21755 as_fn_error $? "failure running python-config --exec-prefix" "$LINENO" 5
21756 fi
21757 fi
21758 else
21759 # We do not have a python executable we can use to determine where
21760 # to find the Python headers and libs. We cannot guess the include
21761 # path from the python_prefix either, because that include path
21762 # depends on the Python version. So, there is nothing much we can
21763 # do except assume that the compiler will be able to find those files.
21764 python_includes=
21765 python_libs=
21766 have_python_config=no
21767 fi
21768
21769 # If we have python-config, only try the configuration it provides.
21770 # Otherwise fallback on the old way of trying different versions of
21771 # python in turn.
21772
21773 have_libpython=no
21774 if test "${have_python_config}" = yes; then
21775
21776
21777 new_CPPFLAGS=${python_includes}
21778 new_LIBS=${python_libs}
21779 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for python" >&5
21780$as_echo_n "checking for python... " >&6; }
21781 save_CPPFLAGS=$CPPFLAGS
21782 save_LIBS=$LIBS
21783 CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
21784 LIBS="$new_LIBS $LIBS"
21785 found_usable_python=no
21786 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21787/* end confdefs.h. */
21788#include "Python.h"
21789int
21790main ()
21791{
21792
21793 #if PY_MAJOR_VERSION != 3
21794 # error "We only support Python 3"
21795 #endif
21796 Py_Initialize ();
21797
21798 ;
21799 return 0;
21800}
21801_ACEOF
21802if ac_fn_c_try_link "$LINENO"; then :
21803 have_libpython=yes
21804 found_usable_python=yes
21805 PYTHON_CPPFLAGS=$new_CPPFLAGS
21806 PYTHON_LIBS=$new_LIBS
21807fi
21808rm -f core conftest.err conftest.$ac_objext \
21809 conftest$ac_exeext conftest.$ac_ext
21810 CPPFLAGS=$save_CPPFLAGS
21811 LIBS=$save_LIBS
21812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_python}" >&5
21813$as_echo "${found_usable_python}" >&6; }
21814
21815 fi
21816
21817 if test "${have_libpython}" = no; then
21818 case "${with_python}" in
21819 yes)
21820 as_fn_error $? "python is missing or unusable" "$LINENO" 5
21821 ;;
21822 auto)
21823 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: python is missing or unusable; some features may be unavailable." >&5
21824$as_echo "$as_me: WARNING: python is missing or unusable; some features may be unavailable." >&2;}
21825 ;;
21826 *)
21827 as_fn_error $? "no usable python found at ${with_python}" "$LINENO" 5
21828 ;;
21829 esac
21830 else
21831 if test -n "${python_prefix}"; then
21832
21833cat >>confdefs.h <<_ACEOF
21834#define WITH_PYTHON_PATH "${python_prefix}"
21835_ACEOF
21836
21837
21838 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
21839 if test "x$prefix" = xNONE; then
21840 test_prefix=/usr/local
21841 else
21842 test_prefix=$prefix
21843 fi
21844 else
21845 test_prefix=$exec_prefix
21846 fi
21847 value=0
21848 case ${python_prefix} in
21849 "${test_prefix}"|"${test_prefix}/"*|\
21850 '${exec_prefix}'|'${exec_prefix}/'*)
21851 value=1
21852 ;;
21853 esac
21854
21855cat >>confdefs.h <<_ACEOF
21856#define PYTHON_PATH_RELOCATABLE $value
21857_ACEOF
21858
21859
21860 fi
21861 fi
21862fi
21863
21864
21865# Check whether --with-python-libdir was given.
21866if test "${with_python_libdir+set}" = set; then :
21867 withval=$with_python_libdir;
21868else
21869
21870 # If no python libdir is specified then select one based on
21871 # python's prefix path.
21872 if test -n "${python_prefix}"; then
21873 with_python_libdir=${python_prefix}/lib
21874 fi
21875
21876fi
21877
21878
21879if test "${have_libpython}" != no; then
21880
21881$as_echo "#define HAVE_PYTHON 1" >>confdefs.h
21882
21883 CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_PYTHON_OBS)"
21884 CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_PYTHON_DEPS)"
21885 CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_PYTHON_SRCS)"
21886 CONFIG_INSTALL="$CONFIG_INSTALL install-python"
21887 ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_PYTHON_CFLAGS)"
21888
21889 if test -n "${with_python_libdir}"; then
21890
21891cat >>confdefs.h <<_ACEOF
21892#define WITH_PYTHON_LIBDIR "${with_python_libdir}"
21893_ACEOF
21894
21895
21896 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
21897 if test "x$prefix" = xNONE; then
21898 test_prefix=/usr/local
21899 else
21900 test_prefix=$prefix
21901 fi
21902 else
21903 test_prefix=$exec_prefix
21904 fi
21905 value=0
21906 case ${with_python_libdir} in
21907 "${test_prefix}"|"${test_prefix}/"*|\
21908 '${exec_prefix}'|'${exec_prefix}/'*)
21909 value=1
21910 ;;
21911 esac
21912
21913cat >>confdefs.h <<_ACEOF
21914#define PYTHON_LIBDIR_RELOCATABLE $value
21915_ACEOF
21916
21917
21918 fi
21919
21920 # Flags needed to compile Python code (taken from python-config --cflags).
21921 # We cannot call python-config directly because it will output whatever was
21922 # used when compiling the Python interpreter itself, including flags which
21923 # would make the python-related objects be compiled differently from the
21924 # rest of GDB (e.g., -O2 and -fPIC).
21925 if test "${GCC}" = yes; then
21926 tentative_python_cflags="-fno-strict-aliasing -fwrapv"
21927 # Python headers recommend -DNDEBUG, but it's unclear if that just
21928 # refers to building Python itself. In release mode, though, it
21929 # doesn't hurt for the Python code in gdb to follow.
21930 $development || tentative_python_cflags="$tentative_python_cflags -DNDEBUG"
21931 fi
21932
21933 if test "x${tentative_python_cflags}" != x; then
21934 { $as_echo "$as_me:${as_lineno-$LINENO}: checking compiler flags for python code" >&5
21935$as_echo_n "checking compiler flags for python code... " >&6; }
21936 for flag in ${tentative_python_cflags}; do
21937 # Check that the compiler accepts it
21938 saved_CFLAGS="$CFLAGS"
21939 CFLAGS="$CFLAGS $flag"
21940 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21941/* end confdefs.h. */
21942
21943int
21944main ()
21945{
21946
21947 ;
21948 return 0;
21949}
21950_ACEOF
21951if ac_fn_c_try_compile "$LINENO"; then :
21952 PYTHON_CFLAGS="${PYTHON_CFLAGS} $flag"
21953fi
21954rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21955 CFLAGS="$saved_CFLAGS"
21956 done
21957 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${PYTHON_CFLAGS}" >&5
21958$as_echo "${PYTHON_CFLAGS}" >&6; }
21959 fi
21960
21961 # On x64 Windows, Python's include headers, and pyconfig.h in
21962 # particular, rely on MS_WIN64 macro to detect that it's a 64bit
21963 # version of Windows. Unfortunately, MS_WIN64 is only defined if
21964 # _MSC_VER, a Microsoft-specific macro, is defined. So, when
21965 # building on x64 Windows with GCC, we define MS_WIN64 ourselves.
21966 # The issue was reported to the Python community, but still isn't
21967 # solved as of 2012-10-02 (http://bugs.python.org/issue4709).
21968
21969 case "$gdb_host" in
21970 mingw64)
21971 if test "${GCC}" = yes; then
21972 CPPFLAGS="$CPPFLAGS -DMS_WIN64"
21973 fi
21974 ;;
21975 esac
21976else
21977 # Even if Python support is not compiled in, we need to have this file
21978 # included so that the "python" command, et.al., still exists.
21979 CONFIG_OBS="$CONFIG_OBS python/python.o"
21980 CONFIG_SRCS="$CONFIG_SRCS python/python.c"
21981fi
21982
21983# Work around Python http://bugs.python.org/issue10112. See also
21984# http://bugs.python.org/issue11410, otherwise -Wl,--dynamic-list has
21985# no effect. Note that the only test after this that uses Python is
21986# the -rdynamic/-Wl,--dynamic-list test, and we do want that one to be
21987# run without -export-dynamic too.
21988PYTHON_LIBS=`echo $PYTHON_LIBS | sed -e 's/-Xlinker -export-dynamic//'`
21989
21990
21991
21992
21993 if test "${have_libpython}" != no; then
21994 HAVE_PYTHON_TRUE=
21995 HAVE_PYTHON_FALSE='#'
21996else
21997 HAVE_PYTHON_TRUE='#'
21998 HAVE_PYTHON_FALSE=
21999fi
22000
22001
22002# -------------------- #
22003# Check for libguile. #
22004# -------------------- #
22005
22006
22007
22008
22009
22010
22011# Check whether --with-guile was given.
22012if test "${with_guile+set}" = set; then :
22013 withval=$with_guile;
22014else
22015 with_guile=auto
22016fi
22017
22018{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use guile" >&5
22019$as_echo_n "checking whether to use guile... " >&6; }
22020{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_guile" >&5
22021$as_echo "$with_guile" >&6; }
22022
22023# Extract the first word of "pkg-config", so it can be a program name with args.
22024set dummy pkg-config; ac_word=$2
22025{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
22026$as_echo_n "checking for $ac_word... " >&6; }
22027if ${ac_cv_path_pkg_config_prog_path+:} false; then :
22028 $as_echo_n "(cached) " >&6
22029else
22030 case $pkg_config_prog_path in
22031 [\\/]* | ?:[\\/]*)
22032 ac_cv_path_pkg_config_prog_path="$pkg_config_prog_path" # Let the user override the test with a path.
22033 ;;
22034 *)
22035 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22036for as_dir in $PATH
22037do
22038 IFS=$as_save_IFS
22039 test -z "$as_dir" && as_dir=.
22040 for ac_exec_ext in '' $ac_executable_extensions; do
22041 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
22042 ac_cv_path_pkg_config_prog_path="$as_dir/$ac_word$ac_exec_ext"
22043 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
22044 break 2
22045 fi
22046done
22047 done
22048IFS=$as_save_IFS
22049
22050 test -z "$ac_cv_path_pkg_config_prog_path" && ac_cv_path_pkg_config_prog_path="missing"
22051 ;;
22052esac
22053fi
22054pkg_config_prog_path=$ac_cv_path_pkg_config_prog_path
22055if test -n "$pkg_config_prog_path"; then
22056 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pkg_config_prog_path" >&5
22057$as_echo "$pkg_config_prog_path" >&6; }
22058else
22059 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22060$as_echo "no" >&6; }
22061fi
22062
22063
22064
22065try_guile_versions="guile-3.0 guile-2.2 guile-2.0"
22066have_libguile=no
22067case "${with_guile}" in
22068no)
22069 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: guile support disabled; some features will be unavailable." >&5
22070$as_echo "$as_me: WARNING: guile support disabled; some features will be unavailable." >&2;}
22071 ;;
22072auto)
22073 if test "${pkg_config_prog_path}" = "missing"; then
22074 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: pkg-config not found, guile support disabled" >&5
22075$as_echo "$as_me: WARNING: pkg-config not found, guile support disabled" >&2;}
22076 else
22077
22078 pkg_config=${pkg_config_prog_path}
22079 guile_version_list=${try_guile_versions}
22080 flag_errors=no
22081
22082 found_usable_guile=checking
22083 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable guile from ${pkg_config}" >&5
22084$as_echo_n "checking for usable guile from ${pkg_config}... " >&6; }
22085 for guile_version in ${guile_version_list}; do
22086 ${pkg_config} --exists ${guile_version} 2>/dev/null
22087 if test $? != 0; then
22088 continue
22089 fi
22090 new_CPPFLAGS=`${pkg_config} --cflags ${guile_version}`
22091 if test $? != 0; then
22092 as_fn_error $? "failure running pkg-config --cflags ${guile_version}" "$LINENO" 5
22093 fi
22094 new_LIBS=`${pkg_config} --libs ${guile_version}`
22095 if test $? != 0; then
22096 as_fn_error $? "failure running pkg-config --libs ${guile_version}" "$LINENO" 5
22097 fi
22098 found_usable_guile=${guile_version}
22099 break
22100 done
22101 if test "${found_usable_guile}" = "checking"; then
22102 if test "${flag_errors}" = "yes"; then
22103 as_fn_error $? "unable to find usable guile version from \"${guile_version_list}\"" "$LINENO" 5
22104 else
22105 found_usable_guile=no
22106 fi
22107 fi
22108 if test "${found_usable_guile}" != no; then
22109 save_CPPFLAGS=$CPPFLAGS
22110 save_LIBS=$LIBS
22111 CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
22112 LIBS="$LIBS $new_LIBS"
22113 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22114/* end confdefs.h. */
22115#include "libguile.h"
22116int
22117main ()
22118{
22119scm_init_guile ();
22120 ;
22121 return 0;
22122}
22123_ACEOF
22124if ac_fn_c_try_link "$LINENO"; then :
22125 have_libguile=yes
22126 GUILE_CPPFLAGS=$new_CPPFLAGS
22127 GUILE_LIBS=$new_LIBS
22128else
22129 found_usable_guile=no
22130fi
22131rm -f core conftest.err conftest.$ac_objext \
22132 conftest$ac_exeext conftest.$ac_ext
22133 ac_fn_c_check_func "$LINENO" "scm_set_automatic_finalization_enabled" "ac_cv_func_scm_set_automatic_finalization_enabled"
22134if test "x$ac_cv_func_scm_set_automatic_finalization_enabled" = xyes; then :
22135
22136$as_echo "#define HAVE_GUILE_MANUAL_FINALIZATION 1" >>confdefs.h
22137
22138
22139fi
22140
22141 CPPFLAGS=$save_CPPFLAGS
22142 LIBS=$save_LIBS
22143 if test "${found_usable_guile}" = no; then
22144 if test "${flag_errors}" = yes; then
22145 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
22146$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
22147as_fn_error $? "linking guile version ${guile_version} test program failed
22148See \`config.log' for more details" "$LINENO" 5; }
22149 fi
22150 fi
22151 fi
22152 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_guile}" >&5
22153$as_echo "${found_usable_guile}" >&6; }
22154
22155 fi
22156 ;;
22157yes)
22158 if test "${pkg_config_prog_path}" = "missing"; then
22159 as_fn_error $? "pkg-config not found" "$LINENO" 5
22160 fi
22161
22162 pkg_config=${pkg_config_prog_path}
22163 guile_version_list=${try_guile_versions}
22164 flag_errors=yes
22165
22166 found_usable_guile=checking
22167 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable guile from ${pkg_config}" >&5
22168$as_echo_n "checking for usable guile from ${pkg_config}... " >&6; }
22169 for guile_version in ${guile_version_list}; do
22170 ${pkg_config} --exists ${guile_version} 2>/dev/null
22171 if test $? != 0; then
22172 continue
22173 fi
22174 new_CPPFLAGS=`${pkg_config} --cflags ${guile_version}`
22175 if test $? != 0; then
22176 as_fn_error $? "failure running pkg-config --cflags ${guile_version}" "$LINENO" 5
22177 fi
22178 new_LIBS=`${pkg_config} --libs ${guile_version}`
22179 if test $? != 0; then
22180 as_fn_error $? "failure running pkg-config --libs ${guile_version}" "$LINENO" 5
22181 fi
22182 found_usable_guile=${guile_version}
22183 break
22184 done
22185 if test "${found_usable_guile}" = "checking"; then
22186 if test "${flag_errors}" = "yes"; then
22187 as_fn_error $? "unable to find usable guile version from \"${guile_version_list}\"" "$LINENO" 5
22188 else
22189 found_usable_guile=no
22190 fi
22191 fi
22192 if test "${found_usable_guile}" != no; then
22193 save_CPPFLAGS=$CPPFLAGS
22194 save_LIBS=$LIBS
22195 CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
22196 LIBS="$LIBS $new_LIBS"
22197 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22198/* end confdefs.h. */
22199#include "libguile.h"
22200int
22201main ()
22202{
22203scm_init_guile ();
22204 ;
22205 return 0;
22206}
22207_ACEOF
22208if ac_fn_c_try_link "$LINENO"; then :
22209 have_libguile=yes
22210 GUILE_CPPFLAGS=$new_CPPFLAGS
22211 GUILE_LIBS=$new_LIBS
22212else
22213 found_usable_guile=no
22214fi
22215rm -f core conftest.err conftest.$ac_objext \
22216 conftest$ac_exeext conftest.$ac_ext
22217 ac_fn_c_check_func "$LINENO" "scm_set_automatic_finalization_enabled" "ac_cv_func_scm_set_automatic_finalization_enabled"
22218if test "x$ac_cv_func_scm_set_automatic_finalization_enabled" = xyes; then :
22219
22220$as_echo "#define HAVE_GUILE_MANUAL_FINALIZATION 1" >>confdefs.h
22221
22222
22223fi
22224
22225 CPPFLAGS=$save_CPPFLAGS
22226 LIBS=$save_LIBS
22227 if test "${found_usable_guile}" = no; then
22228 if test "${flag_errors}" = yes; then
22229 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
22230$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
22231as_fn_error $? "linking guile version ${guile_version} test program failed
22232See \`config.log' for more details" "$LINENO" 5; }
22233 fi
22234 fi
22235 fi
22236 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_guile}" >&5
22237$as_echo "${found_usable_guile}" >&6; }
22238
22239 ;;
22240[\\/]* | ?:[\\/]*)
22241 if test -x "${with_guile}"; then
22242
22243 pkg_config=${with_guile}
22244 guile_version_list=${try_guile_versions}
22245 flag_errors=yes
22246
22247 found_usable_guile=checking
22248 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable guile from ${pkg_config}" >&5
22249$as_echo_n "checking for usable guile from ${pkg_config}... " >&6; }
22250 for guile_version in ${guile_version_list}; do
22251 ${pkg_config} --exists ${guile_version} 2>/dev/null
22252 if test $? != 0; then
22253 continue
22254 fi
22255 new_CPPFLAGS=`${pkg_config} --cflags ${guile_version}`
22256 if test $? != 0; then
22257 as_fn_error $? "failure running pkg-config --cflags ${guile_version}" "$LINENO" 5
22258 fi
22259 new_LIBS=`${pkg_config} --libs ${guile_version}`
22260 if test $? != 0; then
22261 as_fn_error $? "failure running pkg-config --libs ${guile_version}" "$LINENO" 5
22262 fi
22263 found_usable_guile=${guile_version}
22264 break
22265 done
22266 if test "${found_usable_guile}" = "checking"; then
22267 if test "${flag_errors}" = "yes"; then
22268 as_fn_error $? "unable to find usable guile version from \"${guile_version_list}\"" "$LINENO" 5
22269 else
22270 found_usable_guile=no
22271 fi
22272 fi
22273 if test "${found_usable_guile}" != no; then
22274 save_CPPFLAGS=$CPPFLAGS
22275 save_LIBS=$LIBS
22276 CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
22277 LIBS="$LIBS $new_LIBS"
22278 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22279/* end confdefs.h. */
22280#include "libguile.h"
22281int
22282main ()
22283{
22284scm_init_guile ();
22285 ;
22286 return 0;
22287}
22288_ACEOF
22289if ac_fn_c_try_link "$LINENO"; then :
22290 have_libguile=yes
22291 GUILE_CPPFLAGS=$new_CPPFLAGS
22292 GUILE_LIBS=$new_LIBS
22293else
22294 found_usable_guile=no
22295fi
22296rm -f core conftest.err conftest.$ac_objext \
22297 conftest$ac_exeext conftest.$ac_ext
22298 ac_fn_c_check_func "$LINENO" "scm_set_automatic_finalization_enabled" "ac_cv_func_scm_set_automatic_finalization_enabled"
22299if test "x$ac_cv_func_scm_set_automatic_finalization_enabled" = xyes; then :
22300
22301$as_echo "#define HAVE_GUILE_MANUAL_FINALIZATION 1" >>confdefs.h
22302
22303
22304fi
22305
22306 CPPFLAGS=$save_CPPFLAGS
22307 LIBS=$save_LIBS
22308 if test "${found_usable_guile}" = no; then
22309 if test "${flag_errors}" = yes; then
22310 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
22311$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
22312as_fn_error $? "linking guile version ${guile_version} test program failed
22313See \`config.log' for more details" "$LINENO" 5; }
22314 fi
22315 fi
22316 fi
22317 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_guile}" >&5
22318$as_echo "${found_usable_guile}" >&6; }
22319
22320 else
22321 as_fn_error $? "Guile config program not executable: ${with_guile}" "$LINENO" 5
22322 fi
22323 ;;
22324"" | */*)
22325 # Disallow --with=guile="" and --with-guile=foo/bar.
22326 as_fn_error $? "invalid value for --with-guile" "$LINENO" 5
22327 ;;
22328*)
22329 # A space separate list of guile versions to try, in order.
22330 if test "${pkg_config_prog_path}" = "missing"; then
22331 as_fn_error $? "pkg-config not found" "$LINENO" 5
22332 fi
22333
22334 pkg_config=${pkg_config_prog_path}
22335 guile_version_list=${with_guile}
22336 flag_errors=yes
22337
22338 found_usable_guile=checking
22339 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable guile from ${pkg_config}" >&5
22340$as_echo_n "checking for usable guile from ${pkg_config}... " >&6; }
22341 for guile_version in ${guile_version_list}; do
22342 ${pkg_config} --exists ${guile_version} 2>/dev/null
22343 if test $? != 0; then
22344 continue
22345 fi
22346 new_CPPFLAGS=`${pkg_config} --cflags ${guile_version}`
22347 if test $? != 0; then
22348 as_fn_error $? "failure running pkg-config --cflags ${guile_version}" "$LINENO" 5
22349 fi
22350 new_LIBS=`${pkg_config} --libs ${guile_version}`
22351 if test $? != 0; then
22352 as_fn_error $? "failure running pkg-config --libs ${guile_version}" "$LINENO" 5
22353 fi
22354 found_usable_guile=${guile_version}
22355 break
22356 done
22357 if test "${found_usable_guile}" = "checking"; then
22358 if test "${flag_errors}" = "yes"; then
22359 as_fn_error $? "unable to find usable guile version from \"${guile_version_list}\"" "$LINENO" 5
22360 else
22361 found_usable_guile=no
22362 fi
22363 fi
22364 if test "${found_usable_guile}" != no; then
22365 save_CPPFLAGS=$CPPFLAGS
22366 save_LIBS=$LIBS
22367 CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
22368 LIBS="$LIBS $new_LIBS"
22369 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22370/* end confdefs.h. */
22371#include "libguile.h"
22372int
22373main ()
22374{
22375scm_init_guile ();
22376 ;
22377 return 0;
22378}
22379_ACEOF
22380if ac_fn_c_try_link "$LINENO"; then :
22381 have_libguile=yes
22382 GUILE_CPPFLAGS=$new_CPPFLAGS
22383 GUILE_LIBS=$new_LIBS
22384else
22385 found_usable_guile=no
22386fi
22387rm -f core conftest.err conftest.$ac_objext \
22388 conftest$ac_exeext conftest.$ac_ext
22389 ac_fn_c_check_func "$LINENO" "scm_set_automatic_finalization_enabled" "ac_cv_func_scm_set_automatic_finalization_enabled"
22390if test "x$ac_cv_func_scm_set_automatic_finalization_enabled" = xyes; then :
22391
22392$as_echo "#define HAVE_GUILE_MANUAL_FINALIZATION 1" >>confdefs.h
22393
22394
22395fi
22396
22397 CPPFLAGS=$save_CPPFLAGS
22398 LIBS=$save_LIBS
22399 if test "${found_usable_guile}" = no; then
22400 if test "${flag_errors}" = yes; then
22401 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
22402$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
22403as_fn_error $? "linking guile version ${guile_version} test program failed
22404See \`config.log' for more details" "$LINENO" 5; }
22405 fi
22406 fi
22407 fi
22408 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_guile}" >&5
22409$as_echo "${found_usable_guile}" >&6; }
22410
22411 ;;
22412esac
22413
22414if test "${have_libguile}" != no; then
22415 case "${with_guile}" in
22416 [\\/]* | ?:[\\/]*)
22417
22418 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the absolute file name of the 'guild' command" >&5
22419$as_echo_n "checking for the absolute file name of the 'guild' command... " >&6; }
22420if ${ac_cv_guild_program_name+:} false; then :
22421 $as_echo_n "(cached) " >&6
22422else
22423 ac_cv_guild_program_name="`"${with_guile}" --variable guild "${guile_version}"`"
22424
22425 # In Guile up to 2.0.11 included, guile-2.0.pc would not define
22426 # the 'guild' and 'bindir' variables. In that case, try to guess
22427 # what the program name is, at the risk of getting it wrong if
22428 # Guile was configured with '--program-suffix' or similar.
22429 if test "x$ac_cv_guild_program_name" = "x"; then
22430 guile_exec_prefix="`"${with_guile}" --variable exec_prefix "${guile_version}"`"
22431 ac_cv_guild_program_name="$guile_exec_prefix/bin/guild"
22432 fi
22433
22434fi
22435{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_guild_program_name" >&5
22436$as_echo "$ac_cv_guild_program_name" >&6; }
22437
22438 if ! "$ac_cv_guild_program_name" --version >&5 2>&5; then
22439 as_fn_error $? "'$ac_cv_guild_program_name' appears to be unusable" "$LINENO" 5
22440 fi
22441
22442 GUILD="$ac_cv_guild_program_name"
22443
22444
22445 ;;
22446 *)
22447
22448 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the absolute file name of the 'guild' command" >&5
22449$as_echo_n "checking for the absolute file name of the 'guild' command... " >&6; }
22450if ${ac_cv_guild_program_name+:} false; then :
22451 $as_echo_n "(cached) " >&6
22452else
22453 ac_cv_guild_program_name="`"${pkg_config_prog_path}" --variable guild "${guile_version}"`"
22454
22455 # In Guile up to 2.0.11 included, guile-2.0.pc would not define
22456 # the 'guild' and 'bindir' variables. In that case, try to guess
22457 # what the program name is, at the risk of getting it wrong if
22458 # Guile was configured with '--program-suffix' or similar.
22459 if test "x$ac_cv_guild_program_name" = "x"; then
22460 guile_exec_prefix="`"${pkg_config_prog_path}" --variable exec_prefix "${guile_version}"`"
22461 ac_cv_guild_program_name="$guile_exec_prefix/bin/guild"
22462 fi
22463
22464fi
22465{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_guild_program_name" >&5
22466$as_echo "$ac_cv_guild_program_name" >&6; }
22467
22468 if ! "$ac_cv_guild_program_name" --version >&5 2>&5; then
22469 as_fn_error $? "'$ac_cv_guild_program_name' appears to be unusable" "$LINENO" 5
22470 fi
22471
22472 GUILD="$ac_cv_guild_program_name"
22473
22474
22475 ;;
22476 esac
22477
22478
22479 if test "$cross_compiling" = no; then
22480 GUILD_TARGET_FLAG=
22481 else
22482 GUILD_TARGET_FLAG="--target=$host"
22483 fi
22484
22485
22486
22487
22488 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether guild supports this host" >&5
22489$as_echo_n "checking whether guild supports this host... " >&6; }
22490if ${ac_cv_guild_ok+:} false; then :
22491 $as_echo_n "(cached) " >&6
22492else
22493 echo "$ac_cv_guild_program_name compile $GUILD_TARGET_FLAG -o conftest.go $srcdir/guile/lib/gdb/support.scm" >&5
22494 if "$ac_cv_guild_program_name" compile $GUILD_TARGET_FLAG -o conftest.go "$srcdir/guile/lib/gdb/support.scm" >&5 2>&5; then
22495 ac_cv_guild_ok=yes
22496 else
22497 ac_cv_guild_ok=no
22498 fi
22499fi
22500{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_guild_ok" >&5
22501$as_echo "$ac_cv_guild_ok" >&6; }
22502
22503 if test "$ac_cv_guild_ok" = no; then
22504 have_libguile=no
22505 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: disabling guile support" >&5
22506$as_echo "$as_me: WARNING: disabling guile support" >&2;}
22507 fi
22508fi
22509
22510if test "${have_libguile}" != no; then
22511
22512$as_echo "#define HAVE_GUILE 1" >>confdefs.h
22513
22514 CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_GUILE_OBS)"
22515 CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_GUILE_DEPS)"
22516 CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_GUILE_SRCS)"
22517 CONFIG_INSTALL="$CONFIG_INSTALL install-guile"
22518 ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_GUILE_CFLAGS)"
22519
22520 save_LIBS="$LIBS"
22521 save_CPPFLAGS="$CPPFLAGS"
22522 LIBS="$GUILE_LIBS"
22523 CPPFLAGS="$GUILE_CPPFLAGS"
22524 for ac_func in scm_new_smob
22525do :
22526 ac_fn_c_check_func "$LINENO" "scm_new_smob" "ac_cv_func_scm_new_smob"
22527if test "x$ac_cv_func_scm_new_smob" = xyes; then :
22528 cat >>confdefs.h <<_ACEOF
22529#define HAVE_SCM_NEW_SMOB 1
22530_ACEOF
22531
22532fi
22533done
22534
22535 LIBS="$save_LIBS"
22536 CPPFLAGS="$save_CPPFLAGS"
22537else
22538 # Even if Guile support is not compiled in, we need to have these files
22539 # included.
22540 CONFIG_OBS="$CONFIG_OBS guile/guile.o"
22541 CONFIG_SRCS="$CONFIG_SRCS guile/guile.c"
22542fi
22543
22544
22545 if test "${have_libguile}" != no; then
22546 HAVE_GUILE_TRUE=
22547 HAVE_GUILE_FALSE='#'
22548else
22549 HAVE_GUILE_TRUE='#'
22550 HAVE_GUILE_FALSE=
22551fi
22552
22553
22554# ---------------------------- #
22555# Check for source highlight. #
22556# ---------------------------- #
22557
22558SRCHIGH_LIBS=
22559SRCHIGH_CFLAGS=
22560
22561# Check whether --enable-source-highlight was given.
22562if test "${enable_source_highlight+set}" = set; then :
22563 enableval=$enable_source_highlight;
22564 case $enableval in
22565 yes | no | auto)
22566 ;;
22567 *)
22568 as_fn_error $? "bad value $enableval for --enable-source-highlight" "$LINENO" 5
22569 ;;
22570 esac
22571
22572else
22573 enable_source_highlight=auto
22574fi
22575
22576
22577if test "${enable_source_highlight}" != "no"; then
22578 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the source-highlight library" >&5
22579$as_echo_n "checking for the source-highlight library... " >&6; }
22580 if test "${pkg_config_prog_path}" = "missing"; then
22581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no - pkg-config not found" >&5
22582$as_echo "no - pkg-config not found" >&6; }
22583 if test "${enable_source_highlight}" = "yes"; then
22584 as_fn_error $? "pkg-config was not found in your system" "$LINENO" 5
22585 fi
22586 else
22587 if ${pkg_config_prog_path} --exists source-highlight; then
22588 case "$LDFLAGS" in
22589 *static-libstdc*)
22590 as_fn_error $? "source highlight is incompatible with -static-libstdc++; either use --disable-source-highlight or --without-static-standard-libraries" "$LINENO" 5
22591 ;;
22592 esac
22593
22594 srchigh_pkg_cflags=`${pkg_config_prog_path} --cflags source-highlight`
22595 srchigh_pkg_libs=`${pkg_config_prog_path} --libs source-highlight`
22596
22597 # Now that we have found a source-highlight library, check if we can use
22598 # it. In particular, we're trying to detect the situation that the
22599 # library is using the new libstdc++ library abi ( see
22600 # https://gcc.gnu.org/onlinedocs/libstdc++/manual/using_dual_abi.html )
22601 # while the compiler being used to compile gdb is using the old abi.
22602 # Such a situation will result in an undefined reference to
22603 # srchilite::SourceHighlight::SourceHighlight(std::string const&).
22604 # This situation can occur for instance when using a source highlight
22605 # library compiled with g++ 7.5.0 while building gdb with g++ 4.8.5.
22606 ac_ext=cpp
22607ac_cpp='$CXXCPP $CPPFLAGS'
22608ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
22609ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
22610ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
22611
22612 save_CXXFLAGS="$CXXFLAGS"
22613 save_LIBS="$LIBS"
22614 CXXFLAGS="$CXXFLAGS $srchigh_pkg_cflags"
22615 LIBS="$LIBS $srchigh_pkg_libs"
22616 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22617/* end confdefs.h. */
22618#include <srchilite/sourcehighlight.h>
22619int
22620main ()
22621{
22622std::string outlang = "esc.outlang";
22623 new srchilite::SourceHighlight (outlang);
22624
22625 ;
22626 return 0;
22627}
22628_ACEOF
22629if ac_fn_cxx_try_link "$LINENO"; then :
22630 have_usable_source_highlight=yes
22631else
22632 have_usable_source_highlight=no
22633
22634fi
22635rm -f core conftest.err conftest.$ac_objext \
22636 conftest$ac_exeext conftest.$ac_ext
22637 CXXFLAGS="$save_CXXFLAGS"
22638 LIBS="$save_LIBS"
22639 ac_ext=c
22640ac_cpp='$CPP $CPPFLAGS'
22641ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
22642ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
22643ac_compiler_gnu=$ac_cv_c_compiler_gnu
22644
22645
22646 if test "${have_usable_source_highlight}" = "yes"; then
22647
22648$as_echo "#define HAVE_SOURCE_HIGHLIGHT 1" >>confdefs.h
22649
22650 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22651$as_echo "yes" >&6; }
22652 SRCHIGH_CFLAGS="$srchigh_pkg_cflags"
22653 SRCHIGH_LIBS="$srchigh_pkg_libs"
22654 else
22655 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22656$as_echo "no" >&6; }
22657 if test "${enable_source_highlight}" = "yes"; then
22658 as_fn_error $? "source-highlight in your system could not be used" "$LINENO" 5
22659 fi
22660 fi
22661 else
22662 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22663$as_echo "no" >&6; }
22664 if test "${enable_source_highlight}" = "yes"; then
22665 as_fn_error $? "source-highlight was not found in your system" "$LINENO" 5
22666 fi
22667 fi
22668 fi
22669fi
22670
22671
22672
22673# ------------------------- #
22674# Checks for header files. #
22675# ------------------------- #
22676
22677{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
22678$as_echo_n "checking for ANSI C header files... " >&6; }
22679if ${ac_cv_header_stdc+:} false; then :
22680 $as_echo_n "(cached) " >&6
22681else
22682 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22683/* end confdefs.h. */
22684#include <stdlib.h>
22685#include <stdarg.h>
22686#include <string.h>
22687#include <float.h>
22688
22689int
22690main ()
22691{
22692
22693 ;
22694 return 0;
22695}
22696_ACEOF
22697if ac_fn_c_try_compile "$LINENO"; then :
22698 ac_cv_header_stdc=yes
22699else
22700 ac_cv_header_stdc=no
22701fi
22702rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22703
22704if test $ac_cv_header_stdc = yes; then
22705 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
22706 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22707/* end confdefs.h. */
22708#include <string.h>
22709
22710_ACEOF
22711if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
22712 $EGREP "memchr" >/dev/null 2>&1; then :
22713
22714else
22715 ac_cv_header_stdc=no
22716fi
22717rm -f conftest*
22718
22719fi
22720
22721if test $ac_cv_header_stdc = yes; then
22722 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
22723 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22724/* end confdefs.h. */
22725#include <stdlib.h>
22726
22727_ACEOF
22728if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
22729 $EGREP "free" >/dev/null 2>&1; then :
22730
22731else
22732 ac_cv_header_stdc=no
22733fi
22734rm -f conftest*
22735
22736fi
22737
22738if test $ac_cv_header_stdc = yes; then
22739 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
22740 if test "$cross_compiling" = yes; then :
22741 :
22742else
22743 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22744/* end confdefs.h. */
22745#include <ctype.h>
22746#include <stdlib.h>
22747#if ((' ' & 0x0FF) == 0x020)
22748# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
22749# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
22750#else
22751# define ISLOWER(c) \
22752 (('a' <= (c) && (c) <= 'i') \
22753 || ('j' <= (c) && (c) <= 'r') \
22754 || ('s' <= (c) && (c) <= 'z'))
22755# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
22756#endif
22757
22758#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
22759int
22760main ()
22761{
22762 int i;
22763 for (i = 0; i < 256; i++)
22764 if (XOR (islower (i), ISLOWER (i))
22765 || toupper (i) != TOUPPER (i))
22766 return 2;
22767 return 0;
22768}
22769_ACEOF
22770if ac_fn_c_try_run "$LINENO"; then :
22771
22772else
22773 ac_cv_header_stdc=no
22774fi
22775rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22776 conftest.$ac_objext conftest.beam conftest.$ac_ext
22777fi
22778
22779fi
22780fi
22781{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
22782$as_echo "$ac_cv_header_stdc" >&6; }
22783if test $ac_cv_header_stdc = yes; then
22784
22785$as_echo "#define STDC_HEADERS 1" >>confdefs.h
22786
22787fi
22788
22789# elf_hp.h is for HP/UX 64-bit shared library support.
22790for ac_header in nlist.h machine/reg.h \
22791 thread_db.h \
22792 sys/file.h sys/filio.h sys/ioctl.h sys/param.h \
22793 sys/procctl.h sys/resource.h sys/ptrace.h ptrace.h \
22794 sys/reg.h sys/debugreg.h \
22795 termios.h elf_hp.h
22796do :
22797 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
22798ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
22799if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
22800 cat >>confdefs.h <<_ACEOF
22801#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
22802_ACEOF
22803
22804fi
22805
22806done
22807
22808for ac_header in sys/user.h
22809do :
22810 ac_fn_c_check_header_compile "$LINENO" "sys/user.h" "ac_cv_header_sys_user_h" "#if HAVE_SYS_PARAM_H
22811# include <sys/param.h>
22812#endif
22813
22814"
22815if test "x$ac_cv_header_sys_user_h" = xyes; then :
22816 cat >>confdefs.h <<_ACEOF
22817#define HAVE_SYS_USER_H 1
22818_ACEOF
22819
22820fi
22821
22822done
22823
22824
22825for ac_header in curses.h cursesX.h ncurses.h ncursesw/ncurses.h ncurses/ncurses.h ncurses/term.h
22826do :
22827 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
22828ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
22829if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
22830 cat >>confdefs.h <<_ACEOF
22831#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
22832_ACEOF
22833
22834fi
22835
22836done
22837
22838for ac_header in term.h
22839do :
22840 ac_fn_c_check_header_compile "$LINENO" "term.h" "ac_cv_header_term_h" "#if HAVE_CURSES_H
22841# include <curses.h>
22842#endif
22843
22844"
22845if test "x$ac_cv_header_term_h" = xyes; then :
22846 cat >>confdefs.h <<_ACEOF
22847#define HAVE_TERM_H 1
22848_ACEOF
22849
22850fi
22851
22852done
22853
22854
22855for ac_header in sys/socket.h
22856do :
22857 ac_fn_c_check_header_mongrel "$LINENO" "sys/socket.h" "ac_cv_header_sys_socket_h" "$ac_includes_default"
22858if test "x$ac_cv_header_sys_socket_h" = xyes; then :
22859 cat >>confdefs.h <<_ACEOF
22860#define HAVE_SYS_SOCKET_H 1
22861_ACEOF
22862
22863fi
22864
22865done
22866
22867for ac_header in ws2tcpip.h
22868do :
22869 ac_fn_c_check_header_mongrel "$LINENO" "ws2tcpip.h" "ac_cv_header_ws2tcpip_h" "$ac_includes_default"
22870if test "x$ac_cv_header_ws2tcpip_h" = xyes; then :
22871 cat >>confdefs.h <<_ACEOF
22872#define HAVE_WS2TCPIP_H 1
22873_ACEOF
22874
22875fi
22876
22877done
22878
22879for ac_header in execinfo.h
22880do :
22881 ac_fn_c_check_header_mongrel "$LINENO" "execinfo.h" "ac_cv_header_execinfo_h" "$ac_includes_default"
22882if test "x$ac_cv_header_execinfo_h" = xyes; then :
22883 cat >>confdefs.h <<_ACEOF
22884#define HAVE_EXECINFO_H 1
22885_ACEOF
22886
22887fi
22888
22889done
22890
22891
22892# ------------------------- #
22893# Checks for declarations. #
22894# ------------------------- #
22895
22896
22897 # Check for presence and size of long long.
22898 ac_fn_c_check_type "$LINENO" "long long" "ac_cv_type_long_long" "$ac_includes_default"
22899if test "x$ac_cv_type_long_long" = xyes; then :
22900
22901cat >>confdefs.h <<_ACEOF
22902#define HAVE_LONG_LONG 1
22903_ACEOF
22904
22905# The cast to long int works around a bug in the HP C Compiler
22906# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
22907# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
22908# This bug is HP SR number 8606223364.
22909{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5
22910$as_echo_n "checking size of long long... " >&6; }
22911if ${ac_cv_sizeof_long_long+:} false; then :
22912 $as_echo_n "(cached) " >&6
22913else
22914 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long" "$ac_includes_default"; then :
22915
22916else
22917 if test "$ac_cv_type_long_long" = yes; then
22918 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
22919$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
22920as_fn_error 77 "cannot compute sizeof (long long)
22921See \`config.log' for more details" "$LINENO" 5; }
22922 else
22923 ac_cv_sizeof_long_long=0
22924 fi
22925fi
22926
22927fi
22928{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5
22929$as_echo "$ac_cv_sizeof_long_long" >&6; }
22930
22931
22932
22933cat >>confdefs.h <<_ACEOF
22934#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
22935_ACEOF
22936
22937
22938fi
22939
22940
22941 as_ac_Symbol=`$as_echo "ac_cv_have_decl_basename(char *)" | $as_tr_sh`
22942ac_fn_c_check_decl "$LINENO" "basename(char *)" "$as_ac_Symbol" "$ac_includes_default"
22943if eval test \"x\$"$as_ac_Symbol"\" = x"yes"; then :
22944 ac_have_decl=1
22945else
22946 ac_have_decl=0
22947fi
22948
22949cat >>confdefs.h <<_ACEOF
22950#define HAVE_DECL_BASENAME $ac_have_decl
22951_ACEOF
22952ac_fn_c_check_decl "$LINENO" "ffs" "ac_cv_have_decl_ffs" "$ac_includes_default"
22953if test "x$ac_cv_have_decl_ffs" = xyes; then :
22954 ac_have_decl=1
22955else
22956 ac_have_decl=0
22957fi
22958
22959cat >>confdefs.h <<_ACEOF
22960#define HAVE_DECL_FFS $ac_have_decl
22961_ACEOF
22962ac_fn_c_check_decl "$LINENO" "asprintf" "ac_cv_have_decl_asprintf" "$ac_includes_default"
22963if test "x$ac_cv_have_decl_asprintf" = xyes; then :
22964 ac_have_decl=1
22965else
22966 ac_have_decl=0
22967fi
22968
22969cat >>confdefs.h <<_ACEOF
22970#define HAVE_DECL_ASPRINTF $ac_have_decl
22971_ACEOF
22972ac_fn_c_check_decl "$LINENO" "vasprintf" "ac_cv_have_decl_vasprintf" "$ac_includes_default"
22973if test "x$ac_cv_have_decl_vasprintf" = xyes; then :
22974 ac_have_decl=1
22975else
22976 ac_have_decl=0
22977fi
22978
22979cat >>confdefs.h <<_ACEOF
22980#define HAVE_DECL_VASPRINTF $ac_have_decl
22981_ACEOF
22982ac_fn_c_check_decl "$LINENO" "snprintf" "ac_cv_have_decl_snprintf" "$ac_includes_default"
22983if test "x$ac_cv_have_decl_snprintf" = xyes; then :
22984 ac_have_decl=1
22985else
22986 ac_have_decl=0
22987fi
22988
22989cat >>confdefs.h <<_ACEOF
22990#define HAVE_DECL_SNPRINTF $ac_have_decl
22991_ACEOF
22992ac_fn_c_check_decl "$LINENO" "vsnprintf" "ac_cv_have_decl_vsnprintf" "$ac_includes_default"
22993if test "x$ac_cv_have_decl_vsnprintf" = xyes; then :
22994 ac_have_decl=1
22995else
22996 ac_have_decl=0
22997fi
22998
22999cat >>confdefs.h <<_ACEOF
23000#define HAVE_DECL_VSNPRINTF $ac_have_decl
23001_ACEOF
23002
23003 ac_fn_c_check_decl "$LINENO" "strtol" "ac_cv_have_decl_strtol" "$ac_includes_default"
23004if test "x$ac_cv_have_decl_strtol" = xyes; then :
23005 ac_have_decl=1
23006else
23007 ac_have_decl=0
23008fi
23009
23010cat >>confdefs.h <<_ACEOF
23011#define HAVE_DECL_STRTOL $ac_have_decl
23012_ACEOF
23013ac_fn_c_check_decl "$LINENO" "strtoul" "ac_cv_have_decl_strtoul" "$ac_includes_default"
23014if test "x$ac_cv_have_decl_strtoul" = xyes; then :
23015 ac_have_decl=1
23016else
23017 ac_have_decl=0
23018fi
23019
23020cat >>confdefs.h <<_ACEOF
23021#define HAVE_DECL_STRTOUL $ac_have_decl
23022_ACEOF
23023ac_fn_c_check_decl "$LINENO" "strtoll" "ac_cv_have_decl_strtoll" "$ac_includes_default"
23024if test "x$ac_cv_have_decl_strtoll" = xyes; then :
23025 ac_have_decl=1
23026else
23027 ac_have_decl=0
23028fi
23029
23030cat >>confdefs.h <<_ACEOF
23031#define HAVE_DECL_STRTOLL $ac_have_decl
23032_ACEOF
23033ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default"
23034if test "x$ac_cv_have_decl_strtoull" = xyes; then :
23035 ac_have_decl=1
23036else
23037 ac_have_decl=0
23038fi
23039
23040cat >>confdefs.h <<_ACEOF
23041#define HAVE_DECL_STRTOULL $ac_have_decl
23042_ACEOF
23043
23044 ac_fn_c_check_decl "$LINENO" "strverscmp" "ac_cv_have_decl_strverscmp" "$ac_includes_default"
23045if test "x$ac_cv_have_decl_strverscmp" = xyes; then :
23046 ac_have_decl=1
23047else
23048 ac_have_decl=0
23049fi
23050
23051cat >>confdefs.h <<_ACEOF
23052#define HAVE_DECL_STRVERSCMP $ac_have_decl
23053_ACEOF
23054
23055
23056
23057ac_fn_c_check_decl "$LINENO" "snprintf" "ac_cv_have_decl_snprintf" "$ac_includes_default"
23058if test "x$ac_cv_have_decl_snprintf" = xyes; then :
23059 ac_have_decl=1
23060else
23061 ac_have_decl=0
23062fi
23063
23064cat >>confdefs.h <<_ACEOF
23065#define HAVE_DECL_SNPRINTF $ac_have_decl
23066_ACEOF
23067
23068
23069 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LC_MESSAGES" >&5
23070$as_echo_n "checking for LC_MESSAGES... " >&6; }
23071if ${am_cv_val_LC_MESSAGES+:} false; then :
23072 $as_echo_n "(cached) " >&6
23073else
23074 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23075/* end confdefs.h. */
23076#include <locale.h>
23077int
23078main ()
23079{
23080return LC_MESSAGES
23081 ;
23082 return 0;
23083}
23084_ACEOF
23085if ac_fn_c_try_link "$LINENO"; then :
23086 am_cv_val_LC_MESSAGES=yes
23087else
23088 am_cv_val_LC_MESSAGES=no
23089fi
23090rm -f core conftest.err conftest.$ac_objext \
23091 conftest$ac_exeext conftest.$ac_ext
23092fi
23093{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_val_LC_MESSAGES" >&5
23094$as_echo "$am_cv_val_LC_MESSAGES" >&6; }
23095 if test $am_cv_val_LC_MESSAGES = yes; then
23096
23097$as_echo "#define HAVE_LC_MESSAGES 1" >>confdefs.h
23098
23099 fi
23100
23101
23102# ------------------ #
23103# Checks for types. #
23104# ------------------ #
23105
23106ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "#include <sys/types.h>
23107#if HAVE_SYS_SOCKET_H
23108# include <sys/socket.h>
23109#elif HAVE_WS2TCPIP_H
23110# include <ws2tcpip.h>
23111#endif
23112
23113"
23114if test "x$ac_cv_type_socklen_t" = xyes; then :
23115
23116cat >>confdefs.h <<_ACEOF
23117#define HAVE_SOCKLEN_T 1
23118_ACEOF
23119
23120
23121fi
23122
23123
23124# ------------------------------------- #
23125# Checks for compiler characteristics. #
23126# ------------------------------------- #
23127
23128{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
23129$as_echo_n "checking for an ANSI C-conforming const... " >&6; }
23130if ${ac_cv_c_const+:} false; then :
23131 $as_echo_n "(cached) " >&6
23132else
23133 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23134/* end confdefs.h. */
23135
23136int
23137main ()
23138{
23139
23140#ifndef __cplusplus
23141 /* Ultrix mips cc rejects this sort of thing. */
23142 typedef int charset[2];
23143 const charset cs = { 0, 0 };
23144 /* SunOS 4.1.1 cc rejects this. */
23145 char const *const *pcpcc;
23146 char **ppc;
23147 /* NEC SVR4.0.2 mips cc rejects this. */
23148 struct point {int x, y;};
23149 static struct point const zero = {0,0};
23150 /* AIX XL C 1.02.0.0 rejects this.
23151 It does not let you subtract one const X* pointer from another in
23152 an arm of an if-expression whose if-part is not a constant
23153 expression */
23154 const char *g = "string";
23155 pcpcc = &g + (g ? g-g : 0);
23156 /* HPUX 7.0 cc rejects these. */
23157 ++pcpcc;
23158 ppc = (char**) pcpcc;
23159 pcpcc = (char const *const *) ppc;
23160 { /* SCO 3.2v4 cc rejects this sort of thing. */
23161 char tx;
23162 char *t = &tx;
23163 char const *s = 0 ? (char *) 0 : (char const *) 0;
23164
23165 *t++ = 0;
23166 if (s) return 0;
23167 }
23168 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
23169 int x[] = {25, 17};
23170 const int *foo = &x[0];
23171 ++foo;
23172 }
23173 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
23174 typedef const int *iptr;
23175 iptr p = 0;
23176 ++p;
23177 }
23178 { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying
23179 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
23180 struct s { int j; const int *ap[3]; } bx;
23181 struct s *b = &bx; b->j = 5;
23182 }
23183 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
23184 const int foo = 10;
23185 if (!foo) return 0;
23186 }
23187 return !cs[0] && !zero.x;
23188#endif
23189
23190 ;
23191 return 0;
23192}
23193_ACEOF
23194if ac_fn_c_try_compile "$LINENO"; then :
23195 ac_cv_c_const=yes
23196else
23197 ac_cv_c_const=no
23198fi
23199rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23200fi
23201{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
23202$as_echo "$ac_cv_c_const" >&6; }
23203if test $ac_cv_c_const = no; then
23204
23205$as_echo "#define const /**/" >>confdefs.h
23206
23207fi
23208
23209{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
23210$as_echo_n "checking for inline... " >&6; }
23211if ${ac_cv_c_inline+:} false; then :
23212 $as_echo_n "(cached) " >&6
23213else
23214 ac_cv_c_inline=no
23215for ac_kw in inline __inline__ __inline; do
23216 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23217/* end confdefs.h. */
23218#ifndef __cplusplus
23219typedef int foo_t;
23220static $ac_kw foo_t static_foo () {return 0; }
23221$ac_kw foo_t foo () {return 0; }
23222#endif
23223
23224_ACEOF
23225if ac_fn_c_try_compile "$LINENO"; then :
23226 ac_cv_c_inline=$ac_kw
23227fi
23228rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23229 test "$ac_cv_c_inline" != no && break
23230done
23231
23232fi
23233{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
23234$as_echo "$ac_cv_c_inline" >&6; }
23235
23236case $ac_cv_c_inline in
23237 inline | yes) ;;
23238 *)
23239 case $ac_cv_c_inline in
23240 no) ac_val=;;
23241 *) ac_val=$ac_cv_c_inline;;
23242 esac
23243 cat >>confdefs.h <<_ACEOF
23244#ifndef __cplusplus
23245#define inline $ac_val
23246#endif
23247_ACEOF
23248 ;;
23249esac
23250
23251 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
23252$as_echo_n "checking whether byte ordering is bigendian... " >&6; }
23253if ${ac_cv_c_bigendian+:} false; then :
23254 $as_echo_n "(cached) " >&6
23255else
23256 ac_cv_c_bigendian=unknown
23257 # See if we're dealing with a universal compiler.
23258 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23259/* end confdefs.h. */
23260#ifndef __APPLE_CC__
23261 not a universal capable compiler
23262 #endif
23263 typedef int dummy;
23264
23265_ACEOF
23266if ac_fn_c_try_compile "$LINENO"; then :
23267
23268 # Check for potential -arch flags. It is not universal unless
23269 # there are at least two -arch flags with different values.
23270 ac_arch=
23271 ac_prev=
23272 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
23273 if test -n "$ac_prev"; then
23274 case $ac_word in
23275 i?86 | x86_64 | ppc | ppc64)
23276 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
23277 ac_arch=$ac_word
23278 else
23279 ac_cv_c_bigendian=universal
23280 break
23281 fi
23282 ;;
23283 esac
23284 ac_prev=
23285 elif test "x$ac_word" = "x-arch"; then
23286 ac_prev=arch
23287 fi
23288 done
23289fi
23290rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23291 if test $ac_cv_c_bigendian = unknown; then
23292 # See if sys/param.h defines the BYTE_ORDER macro.
23293 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23294/* end confdefs.h. */
23295#include <sys/types.h>
23296 #include <sys/param.h>
23297
23298int
23299main ()
23300{
23301#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
23302 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
23303 && LITTLE_ENDIAN)
23304 bogus endian macros
23305 #endif
23306
23307 ;
23308 return 0;
23309}
23310_ACEOF
23311if ac_fn_c_try_compile "$LINENO"; then :
23312 # It does; now see whether it defined to BIG_ENDIAN or not.
23313 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23314/* end confdefs.h. */
23315#include <sys/types.h>
23316 #include <sys/param.h>
23317
23318int
23319main ()
23320{
23321#if BYTE_ORDER != BIG_ENDIAN
23322 not big endian
23323 #endif
23324
23325 ;
23326 return 0;
23327}
23328_ACEOF
23329if ac_fn_c_try_compile "$LINENO"; then :
23330 ac_cv_c_bigendian=yes
23331else
23332 ac_cv_c_bigendian=no
23333fi
23334rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23335fi
23336rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23337 fi
23338 if test $ac_cv_c_bigendian = unknown; then
23339 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
23340 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23341/* end confdefs.h. */
23342#include <limits.h>
23343
23344int
23345main ()
23346{
23347#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
23348 bogus endian macros
23349 #endif
23350
23351 ;
23352 return 0;
23353}
23354_ACEOF
23355if ac_fn_c_try_compile "$LINENO"; then :
23356 # It does; now see whether it defined to _BIG_ENDIAN or not.
23357 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23358/* end confdefs.h. */
23359#include <limits.h>
23360
23361int
23362main ()
23363{
23364#ifndef _BIG_ENDIAN
23365 not big endian
23366 #endif
23367
23368 ;
23369 return 0;
23370}
23371_ACEOF
23372if ac_fn_c_try_compile "$LINENO"; then :
23373 ac_cv_c_bigendian=yes
23374else
23375 ac_cv_c_bigendian=no
23376fi
23377rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23378fi
23379rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23380 fi
23381 if test $ac_cv_c_bigendian = unknown; then
23382 # Compile a test program.
23383 if test "$cross_compiling" = yes; then :
23384 # Try to guess by grepping values from an object file.
23385 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23386/* end confdefs.h. */
23387short int ascii_mm[] =
23388 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
23389 short int ascii_ii[] =
23390 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
23391 int use_ascii (int i) {
23392 return ascii_mm[i] + ascii_ii[i];
23393 }
23394 short int ebcdic_ii[] =
23395 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
23396 short int ebcdic_mm[] =
23397 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
23398 int use_ebcdic (int i) {
23399 return ebcdic_mm[i] + ebcdic_ii[i];
23400 }
23401 extern int foo;
23402
23403int
23404main ()
23405{
23406return use_ascii (foo) == use_ebcdic (foo);
23407 ;
23408 return 0;
23409}
23410_ACEOF
23411if ac_fn_c_try_compile "$LINENO"; then :
23412 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
23413 ac_cv_c_bigendian=yes
23414 fi
23415 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
23416 if test "$ac_cv_c_bigendian" = unknown; then
23417 ac_cv_c_bigendian=no
23418 else
23419 # finding both strings is unlikely to happen, but who knows?
23420 ac_cv_c_bigendian=unknown
23421 fi
23422 fi
23423fi
23424rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23425else
23426 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23427/* end confdefs.h. */
23428$ac_includes_default
23429int
23430main ()
23431{
23432
23433 /* Are we little or big endian? From Harbison&Steele. */
23434 union
23435 {
23436 long int l;
23437 char c[sizeof (long int)];
23438 } u;
23439 u.l = 1;
23440 return u.c[sizeof (long int) - 1] == 1;
23441
23442 ;
23443 return 0;
23444}
23445_ACEOF
23446if ac_fn_c_try_run "$LINENO"; then :
23447 ac_cv_c_bigendian=no
23448else
23449 ac_cv_c_bigendian=yes
23450fi
23451rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23452 conftest.$ac_objext conftest.beam conftest.$ac_ext
23453fi
23454
23455 fi
23456fi
23457{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
23458$as_echo "$ac_cv_c_bigendian" >&6; }
23459 case $ac_cv_c_bigendian in #(
23460 yes)
23461 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
23462;; #(
23463 no)
23464 ;; #(
23465 universal)
23466
23467$as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
23468
23469 ;; #(
23470 *)
23471 as_fn_error $? "unknown endianness
23472 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
23473 esac
23474
23475
23476# ------------------------------ #
23477# Checks for library functions. #
23478# ------------------------------ #
23479
23480for ac_func in getuid getgid \
23481 pipe pread pread64 pwrite resize_term \
23482 getpgid setsid \
23483 sigaction sigsetmask socketpair \
23484 ttrace wborder wresize setlocale iconvlist libiconvlist btowc \
23485 setrlimit getrlimit posix_madvise waitpid \
23486 use_default_colors
23487do :
23488 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
23489ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
23490if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
23491 cat >>confdefs.h <<_ACEOF
23492#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
23493_ACEOF
23494
23495fi
23496done
23497
23498
23499 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
23500$as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
23501if ${am_cv_langinfo_codeset+:} false; then :
23502 $as_echo_n "(cached) " >&6
23503else
23504 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23505/* end confdefs.h. */
23506#include <langinfo.h>
23507int
23508main ()
23509{
23510char* cs = nl_langinfo(CODESET);
23511 ;
23512 return 0;
23513}
23514_ACEOF
23515if ac_fn_c_try_link "$LINENO"; then :
23516 am_cv_langinfo_codeset=yes
23517else
23518 am_cv_langinfo_codeset=no
23519fi
23520rm -f core conftest.err conftest.$ac_objext \
23521 conftest$ac_exeext conftest.$ac_ext
23522
23523fi
23524{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_langinfo_codeset" >&5
23525$as_echo "$am_cv_langinfo_codeset" >&6; }
23526 if test $am_cv_langinfo_codeset = yes; then
23527
23528$as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
23529
23530 fi
23531
23532ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
23533if test "x$ac_cv_type_size_t" = xyes; then :
23534
23535else
23536
23537cat >>confdefs.h <<_ACEOF
23538#define size_t unsigned int
23539_ACEOF
23540
23541fi
23542
23543
23544
23545
23546 for ac_header in $ac_header_list
23547do :
23548 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
23549ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
23550"
23551if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
23552 cat >>confdefs.h <<_ACEOF
23553#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
23554_ACEOF
23555
23556fi
23557
23558done
23559
23560
23561
23562
23563
23564
23565
23566ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
23567if test "x$ac_cv_type_pid_t" = xyes; then :
23568
23569else
23570
23571cat >>confdefs.h <<_ACEOF
23572#define pid_t int
23573_ACEOF
23574
23575fi
23576
23577
23578 # Set the 'development' global.
23579 . $srcdir/../bfd/development.sh
23580
23581 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
23582$as_echo_n "checking for ANSI C header files... " >&6; }
23583if ${ac_cv_header_stdc+:} false; then :
23584 $as_echo_n "(cached) " >&6
23585else
23586 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23587/* end confdefs.h. */
23588#include <stdlib.h>
23589#include <stdarg.h>
23590#include <string.h>
23591#include <float.h>
23592
23593int
23594main ()
23595{
23596
23597 ;
23598 return 0;
23599}
23600_ACEOF
23601if ac_fn_c_try_compile "$LINENO"; then :
23602 ac_cv_header_stdc=yes
23603else
23604 ac_cv_header_stdc=no
23605fi
23606rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23607
23608if test $ac_cv_header_stdc = yes; then
23609 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
23610 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23611/* end confdefs.h. */
23612#include <string.h>
23613
23614_ACEOF
23615if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
23616 $EGREP "memchr" >/dev/null 2>&1; then :
23617
23618else
23619 ac_cv_header_stdc=no
23620fi
23621rm -f conftest*
23622
23623fi
23624
23625if test $ac_cv_header_stdc = yes; then
23626 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
23627 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23628/* end confdefs.h. */
23629#include <stdlib.h>
23630
23631_ACEOF
23632if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
23633 $EGREP "free" >/dev/null 2>&1; then :
23634
23635else
23636 ac_cv_header_stdc=no
23637fi
23638rm -f conftest*
23639
23640fi
23641
23642if test $ac_cv_header_stdc = yes; then
23643 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
23644 if test "$cross_compiling" = yes; then :
23645 :
23646else
23647 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23648/* end confdefs.h. */
23649#include <ctype.h>
23650#include <stdlib.h>
23651#if ((' ' & 0x0FF) == 0x020)
23652# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
23653# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
23654#else
23655# define ISLOWER(c) \
23656 (('a' <= (c) && (c) <= 'i') \
23657 || ('j' <= (c) && (c) <= 'r') \
23658 || ('s' <= (c) && (c) <= 'z'))
23659# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
23660#endif
23661
23662#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
23663int
23664main ()
23665{
23666 int i;
23667 for (i = 0; i < 256; i++)
23668 if (XOR (islower (i), ISLOWER (i))
23669 || toupper (i) != TOUPPER (i))
23670 return 2;
23671 return 0;
23672}
23673_ACEOF
23674if ac_fn_c_try_run "$LINENO"; then :
23675
23676else
23677 ac_cv_header_stdc=no
23678fi
23679rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23680 conftest.$ac_objext conftest.beam conftest.$ac_ext
23681fi
23682
23683fi
23684fi
23685{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
23686$as_echo "$ac_cv_header_stdc" >&6; }
23687if test $ac_cv_header_stdc = yes; then
23688
23689$as_echo "#define STDC_HEADERS 1" >>confdefs.h
23690
23691fi
23692
23693 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
23694# for constant arguments. Useless!
23695{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
23696$as_echo_n "checking for working alloca.h... " >&6; }
23697if ${ac_cv_working_alloca_h+:} false; then :
23698 $as_echo_n "(cached) " >&6
23699else
23700 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23701/* end confdefs.h. */
23702#include <alloca.h>
23703int
23704main ()
23705{
23706char *p = (char *) alloca (2 * sizeof (int));
23707 if (p) return 0;
23708 ;
23709 return 0;
23710}
23711_ACEOF
23712if ac_fn_c_try_link "$LINENO"; then :
23713 ac_cv_working_alloca_h=yes
23714else
23715 ac_cv_working_alloca_h=no
23716fi
23717rm -f core conftest.err conftest.$ac_objext \
23718 conftest$ac_exeext conftest.$ac_ext
23719fi
23720{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
23721$as_echo "$ac_cv_working_alloca_h" >&6; }
23722if test $ac_cv_working_alloca_h = yes; then
23723
23724$as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
23725
23726fi
23727
23728{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
23729$as_echo_n "checking for alloca... " >&6; }
23730if ${ac_cv_func_alloca_works+:} false; then :
23731 $as_echo_n "(cached) " >&6
23732else
23733 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23734/* end confdefs.h. */
23735#ifdef __GNUC__
23736# define alloca __builtin_alloca
23737#else
23738# ifdef _MSC_VER
23739# include <malloc.h>
23740# define alloca _alloca
23741# else
23742# ifdef HAVE_ALLOCA_H
23743# include <alloca.h>
23744# else
23745# ifdef _AIX
23746 #pragma alloca
23747# else
23748# ifndef alloca /* predefined by HP cc +Olibcalls */
23749void *alloca (size_t);
23750# endif
23751# endif
23752# endif
23753# endif
23754#endif
23755
23756int
23757main ()
23758{
23759char *p = (char *) alloca (1);
23760 if (p) return 0;
23761 ;
23762 return 0;
23763}
23764_ACEOF
23765if ac_fn_c_try_link "$LINENO"; then :
23766 ac_cv_func_alloca_works=yes
23767else
23768 ac_cv_func_alloca_works=no
23769fi
23770rm -f core conftest.err conftest.$ac_objext \
23771 conftest$ac_exeext conftest.$ac_ext
23772fi
23773{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
23774$as_echo "$ac_cv_func_alloca_works" >&6; }
23775
23776if test $ac_cv_func_alloca_works = yes; then
23777
23778$as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
23779
23780else
23781 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
23782# that cause trouble. Some versions do not even contain alloca or
23783# contain a buggy version. If you still want to use their alloca,
23784# use ar to extract alloca.o from them instead of compiling alloca.c.
23785
23786ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
23787
23788$as_echo "#define C_ALLOCA 1" >>confdefs.h
23789
23790
23791{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5
23792$as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; }
23793if ${ac_cv_os_cray+:} false; then :
23794 $as_echo_n "(cached) " >&6
23795else
23796 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23797/* end confdefs.h. */
23798#if defined CRAY && ! defined CRAY2
23799webecray
23800#else
23801wenotbecray
23802#endif
23803
23804_ACEOF
23805if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
23806 $EGREP "webecray" >/dev/null 2>&1; then :
23807 ac_cv_os_cray=yes
23808else
23809 ac_cv_os_cray=no
23810fi
23811rm -f conftest*
23812
23813fi
23814{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
23815$as_echo "$ac_cv_os_cray" >&6; }
23816if test $ac_cv_os_cray = yes; then
23817 for ac_func in _getb67 GETB67 getb67; do
23818 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
23819ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
23820if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
23821
23822cat >>confdefs.h <<_ACEOF
23823#define CRAY_STACKSEG_END $ac_func
23824_ACEOF
23825
23826 break
23827fi
23828
23829 done
23830fi
23831
23832{ $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
23833$as_echo_n "checking stack direction for C alloca... " >&6; }
23834if ${ac_cv_c_stack_direction+:} false; then :
23835 $as_echo_n "(cached) " >&6
23836else
23837 if test "$cross_compiling" = yes; then :
23838 ac_cv_c_stack_direction=0
23839else
23840 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23841/* end confdefs.h. */
23842$ac_includes_default
23843int
23844find_stack_direction (int *addr, int depth)
23845{
23846 int dir, dummy = 0;
23847 if (! addr)
23848 addr = &dummy;
23849 *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
23850 dir = depth ? find_stack_direction (addr, depth - 1) : 0;
23851 return dir + dummy;
23852}
23853
23854int
23855main (int argc, char **argv)
23856{
23857 return find_stack_direction (0, argc + !argv + 20) < 0;
23858}
23859_ACEOF
23860if ac_fn_c_try_run "$LINENO"; then :
23861 ac_cv_c_stack_direction=1
23862else
23863 ac_cv_c_stack_direction=-1
23864fi
23865rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23866 conftest.$ac_objext conftest.beam conftest.$ac_ext
23867fi
23868
23869fi
23870{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
23871$as_echo "$ac_cv_c_stack_direction" >&6; }
23872cat >>confdefs.h <<_ACEOF
23873#define STACK_DIRECTION $ac_cv_c_stack_direction
23874_ACEOF
23875
23876
23877fi
23878
23879
23880 WIN32APILIBS=
23881 case ${host} in
23882 *mingw32*)
23883
23884$as_echo "#define USE_WIN32API 1" >>confdefs.h
23885
23886 WIN32APILIBS="-lws2_32"
23887 ;;
23888 esac
23889
23890
23891 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
23892$as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
23893if ${am_cv_langinfo_codeset+:} false; then :
23894 $as_echo_n "(cached) " >&6
23895else
23896 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23897/* end confdefs.h. */
23898#include <langinfo.h>
23899int
23900main ()
23901{
23902char* cs = nl_langinfo(CODESET);
23903 ;
23904 return 0;
23905}
23906_ACEOF
23907if ac_fn_c_try_link "$LINENO"; then :
23908 am_cv_langinfo_codeset=yes
23909else
23910 am_cv_langinfo_codeset=no
23911fi
23912rm -f core conftest.err conftest.$ac_objext \
23913 conftest$ac_exeext conftest.$ac_ext
23914
23915fi
23916{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_langinfo_codeset" >&5
23917$as_echo "$am_cv_langinfo_codeset" >&6; }
23918 if test $am_cv_langinfo_codeset = yes; then
23919
23920$as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
23921
23922 fi
23923
23924
23925 for ac_header in linux/perf_event.h locale.h memory.h signal.h sys/resource.h sys/socket.h sys/un.h sys/wait.h thread_db.h wait.h termios.h dlfcn.h linux/elf.h proc_service.h poll.h sys/poll.h sys/select.h
23926do :
23927 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
23928ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
23929if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
23930 cat >>confdefs.h <<_ACEOF
23931#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
23932_ACEOF
23933
23934fi
23935
23936done
23937
23938
23939
23940for ac_func in getpagesize
23941do :
23942 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
23943if test "x$ac_cv_func_getpagesize" = xyes; then :
23944 cat >>confdefs.h <<_ACEOF
23945#define HAVE_GETPAGESIZE 1
23946_ACEOF
23947
23948fi
23949done
23950
23951{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
23952$as_echo_n "checking for working mmap... " >&6; }
23953if ${ac_cv_func_mmap_fixed_mapped+:} false; then :
23954 $as_echo_n "(cached) " >&6
23955else
23956 if test "$cross_compiling" = yes; then :
23957 ac_cv_func_mmap_fixed_mapped=no
23958else
23959 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23960/* end confdefs.h. */
23961$ac_includes_default
23962/* malloc might have been renamed as rpl_malloc. */
23963#undef malloc
23964
23965/* Thanks to Mike Haertel and Jim Avera for this test.
23966 Here is a matrix of mmap possibilities:
23967 mmap private not fixed
23968 mmap private fixed at somewhere currently unmapped
23969 mmap private fixed at somewhere already mapped
23970 mmap shared not fixed
23971 mmap shared fixed at somewhere currently unmapped
23972 mmap shared fixed at somewhere already mapped
23973 For private mappings, we should verify that changes cannot be read()
23974 back from the file, nor mmap's back from the file at a different
23975 address. (There have been systems where private was not correctly
23976 implemented like the infamous i386 svr4.0, and systems where the
23977 VM page cache was not coherent with the file system buffer cache
23978 like early versions of FreeBSD and possibly contemporary NetBSD.)
23979 For shared mappings, we should conversely verify that changes get
23980 propagated back to all the places they're supposed to be.
23981
23982 Grep wants private fixed already mapped.
23983 The main things grep needs to know about mmap are:
23984 * does it exist and is it safe to write into the mmap'd area
23985 * how to use it (BSD variants) */
23986
23987#include <fcntl.h>
23988#include <sys/mman.h>
23989
23990#if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
23991char *malloc ();
23992#endif
23993
23994/* This mess was copied from the GNU getpagesize.h. */
23995#ifndef HAVE_GETPAGESIZE
23996# ifdef _SC_PAGESIZE
23997# define getpagesize() sysconf(_SC_PAGESIZE)
23998# else /* no _SC_PAGESIZE */
23999# ifdef HAVE_SYS_PARAM_H
24000# include <sys/param.h>
24001# ifdef EXEC_PAGESIZE
24002# define getpagesize() EXEC_PAGESIZE
24003# else /* no EXEC_PAGESIZE */
24004# ifdef NBPG
24005# define getpagesize() NBPG * CLSIZE
24006# ifndef CLSIZE
24007# define CLSIZE 1
24008# endif /* no CLSIZE */
24009# else /* no NBPG */
24010# ifdef NBPC
24011# define getpagesize() NBPC
24012# else /* no NBPC */
24013# ifdef PAGESIZE
24014# define getpagesize() PAGESIZE
24015# endif /* PAGESIZE */
24016# endif /* no NBPC */
24017# endif /* no NBPG */
24018# endif /* no EXEC_PAGESIZE */
24019# else /* no HAVE_SYS_PARAM_H */
24020# define getpagesize() 8192 /* punt totally */
24021# endif /* no HAVE_SYS_PARAM_H */
24022# endif /* no _SC_PAGESIZE */
24023
24024#endif /* no HAVE_GETPAGESIZE */
24025
24026int
24027main ()
24028{
24029 char *data, *data2, *data3;
24030 const char *cdata2;
24031 int i, pagesize;
24032 int fd, fd2;
24033
24034 pagesize = getpagesize ();
24035
24036 /* First, make a file with some known garbage in it. */
24037 data = (char *) malloc (pagesize);
24038 if (!data)
24039 return 1;
24040 for (i = 0; i < pagesize; ++i)
24041 *(data + i) = rand ();
24042 umask (0);
24043 fd = creat ("conftest.mmap", 0600);
24044 if (fd < 0)
24045 return 2;
24046 if (write (fd, data, pagesize) != pagesize)
24047 return 3;
24048 close (fd);
24049
24050 /* Next, check that the tail of a page is zero-filled. File must have
24051 non-zero length, otherwise we risk SIGBUS for entire page. */
24052 fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
24053 if (fd2 < 0)
24054 return 4;
24055 cdata2 = "";
24056 if (write (fd2, cdata2, 1) != 1)
24057 return 5;
24058 data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
24059 if (data2 == MAP_FAILED)
24060 return 6;
24061 for (i = 0; i < pagesize; ++i)
24062 if (*(data2 + i))
24063 return 7;
24064 close (fd2);
24065 if (munmap (data2, pagesize))
24066 return 8;
24067
24068 /* Next, try to mmap the file at a fixed address which already has
24069 something else allocated at it. If we can, also make sure that
24070 we see the same garbage. */
24071 fd = open ("conftest.mmap", O_RDWR);
24072 if (fd < 0)
24073 return 9;
24074 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
24075 MAP_PRIVATE | MAP_FIXED, fd, 0L))
24076 return 10;
24077 for (i = 0; i < pagesize; ++i)
24078 if (*(data + i) != *(data2 + i))
24079 return 11;
24080
24081 /* Finally, make sure that changes to the mapped area do not
24082 percolate back to the file as seen by read(). (This is a bug on
24083 some variants of i386 svr4.0.) */
24084 for (i = 0; i < pagesize; ++i)
24085 *(data2 + i) = *(data2 + i) + 1;
24086 data3 = (char *) malloc (pagesize);
24087 if (!data3)
24088 return 12;
24089 if (read (fd, data3, pagesize) != pagesize)
24090 return 13;
24091 for (i = 0; i < pagesize; ++i)
24092 if (*(data + i) != *(data3 + i))
24093 return 14;
24094 close (fd);
24095 return 0;
24096}
24097_ACEOF
24098if ac_fn_c_try_run "$LINENO"; then :
24099 ac_cv_func_mmap_fixed_mapped=yes
24100else
24101 ac_cv_func_mmap_fixed_mapped=no
24102fi
24103rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24104 conftest.$ac_objext conftest.beam conftest.$ac_ext
24105fi
24106
24107fi
24108{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
24109$as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
24110if test $ac_cv_func_mmap_fixed_mapped = yes; then
24111
24112$as_echo "#define HAVE_MMAP 1" >>confdefs.h
24113
24114fi
24115rm -f conftest.mmap conftest.txt
24116
24117 for ac_header in vfork.h
24118do :
24119 ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
24120if test "x$ac_cv_header_vfork_h" = xyes; then :
24121 cat >>confdefs.h <<_ACEOF
24122#define HAVE_VFORK_H 1
24123_ACEOF
24124
24125fi
24126
24127done
24128
24129for ac_func in fork vfork
24130do :
24131 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
24132ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
24133if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
24134 cat >>confdefs.h <<_ACEOF
24135#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
24136_ACEOF
24137
24138fi
24139done
24140
24141if test "x$ac_cv_func_fork" = xyes; then
24142 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
24143$as_echo_n "checking for working fork... " >&6; }
24144if ${ac_cv_func_fork_works+:} false; then :
24145 $as_echo_n "(cached) " >&6
24146else
24147 if test "$cross_compiling" = yes; then :
24148 ac_cv_func_fork_works=cross
24149else
24150 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24151/* end confdefs.h. */
24152$ac_includes_default
24153int
24154main ()
24155{
24156
24157 /* By Ruediger Kuhlmann. */
24158 return fork () < 0;
24159
24160 ;
24161 return 0;
24162}
24163_ACEOF
24164if ac_fn_c_try_run "$LINENO"; then :
24165 ac_cv_func_fork_works=yes
24166else
24167 ac_cv_func_fork_works=no
24168fi
24169rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24170 conftest.$ac_objext conftest.beam conftest.$ac_ext
24171fi
24172
24173fi
24174{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
24175$as_echo "$ac_cv_func_fork_works" >&6; }
24176
24177else
24178 ac_cv_func_fork_works=$ac_cv_func_fork
24179fi
24180if test "x$ac_cv_func_fork_works" = xcross; then
24181 case $host in
24182 *-*-amigaos* | *-*-msdosdjgpp*)
24183 # Override, as these systems have only a dummy fork() stub
24184 ac_cv_func_fork_works=no
24185 ;;
24186 *)
24187 ac_cv_func_fork_works=yes
24188 ;;
24189 esac
24190 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
24191$as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
24192fi
24193ac_cv_func_vfork_works=$ac_cv_func_vfork
24194if test "x$ac_cv_func_vfork" = xyes; then
24195 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
24196$as_echo_n "checking for working vfork... " >&6; }
24197if ${ac_cv_func_vfork_works+:} false; then :
24198 $as_echo_n "(cached) " >&6
24199else
24200 if test "$cross_compiling" = yes; then :
24201 ac_cv_func_vfork_works=cross
24202else
24203 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24204/* end confdefs.h. */
24205/* Thanks to Paul Eggert for this test. */
24206$ac_includes_default
24207#include <sys/wait.h>
24208#ifdef HAVE_VFORK_H
24209# include <vfork.h>
24210#endif
24211/* On some sparc systems, changes by the child to local and incoming
24212 argument registers are propagated back to the parent. The compiler
24213 is told about this with #include <vfork.h>, but some compilers
24214 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
24215 static variable whose address is put into a register that is
24216 clobbered by the vfork. */
24217static void
24218#ifdef __cplusplus
24219sparc_address_test (int arg)
24220# else
24221sparc_address_test (arg) int arg;
24222#endif
24223{
24224 static pid_t child;
24225 if (!child) {
24226 child = vfork ();
24227 if (child < 0) {
24228 perror ("vfork");
24229 _exit(2);
24230 }
24231 if (!child) {
24232 arg = getpid();
24233 write(-1, "", 0);
24234 _exit (arg);
24235 }
24236 }
24237}
24238
24239int
24240main ()
24241{
24242 pid_t parent = getpid ();
24243 pid_t child;
24244
24245 sparc_address_test (0);
24246
24247 child = vfork ();
24248
24249 if (child == 0) {
24250 /* Here is another test for sparc vfork register problems. This
24251 test uses lots of local variables, at least as many local
24252 variables as main has allocated so far including compiler
24253 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
24254 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
24255 reuse the register of parent for one of the local variables,
24256 since it will think that parent can't possibly be used any more
24257 in this routine. Assigning to the local variable will thus
24258 munge parent in the parent process. */
24259 pid_t
24260 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
24261 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
24262 /* Convince the compiler that p..p7 are live; otherwise, it might
24263 use the same hardware register for all 8 local variables. */
24264 if (p != p1 || p != p2 || p != p3 || p != p4
24265 || p != p5 || p != p6 || p != p7)
24266 _exit(1);
24267
24268 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
24269 from child file descriptors. If the child closes a descriptor
24270 before it execs or exits, this munges the parent's descriptor
24271 as well. Test for this by closing stdout in the child. */
24272 _exit(close(fileno(stdout)) != 0);
24273 } else {
24274 int status;
24275 struct stat st;
24276
24277 while (wait(&status) != child)
24278 ;
24279 return (
24280 /* Was there some problem with vforking? */
24281 child < 0
24282
24283 /* Did the child fail? (This shouldn't happen.) */
24284 || status
24285
24286 /* Did the vfork/compiler bug occur? */
24287 || parent != getpid()
24288
24289 /* Did the file descriptor bug occur? */
24290 || fstat(fileno(stdout), &st) != 0
24291 );
24292 }
24293}
24294_ACEOF
24295if ac_fn_c_try_run "$LINENO"; then :
24296 ac_cv_func_vfork_works=yes
24297else
24298 ac_cv_func_vfork_works=no
24299fi
24300rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24301 conftest.$ac_objext conftest.beam conftest.$ac_ext
24302fi
24303
24304fi
24305{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
24306$as_echo "$ac_cv_func_vfork_works" >&6; }
24307
24308fi;
24309if test "x$ac_cv_func_fork_works" = xcross; then
24310 ac_cv_func_vfork_works=$ac_cv_func_vfork
24311 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
24312$as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
24313fi
24314
24315if test "x$ac_cv_func_vfork_works" = xyes; then
24316
24317$as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
24318
24319else
24320
24321$as_echo "#define vfork fork" >>confdefs.h
24322
24323fi
24324if test "x$ac_cv_func_fork_works" = xyes; then
24325
24326$as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
24327
24328fi
24329
24330 for ac_func in fdwalk getrlimit pipe pipe2 poll socketpair sigaction \
24331 ptrace64 sbrk setns sigaltstack sigprocmask \
24332 setpgid setpgrp getrusage getauxval sigtimedwait
24333do :
24334 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
24335ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
24336if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
24337 cat >>confdefs.h <<_ACEOF
24338#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
24339_ACEOF
24340
24341fi
24342done
24343
24344
24345 # This is needed for RHEL 5 and uclibc-ng < 1.0.39.
24346 # These did not define ADDR_NO_RANDOMIZE in sys/personality.h,
24347 # only in linux/personality.h.
24348 ac_fn_c_check_decl "$LINENO" "ADDR_NO_RANDOMIZE" "ac_cv_have_decl_ADDR_NO_RANDOMIZE" "#include <sys/personality.h>
24349"
24350if test "x$ac_cv_have_decl_ADDR_NO_RANDOMIZE" = xyes; then :
24351 ac_have_decl=1
24352else
24353 ac_have_decl=0
24354fi
24355
24356cat >>confdefs.h <<_ACEOF
24357#define HAVE_DECL_ADDR_NO_RANDOMIZE $ac_have_decl
24358_ACEOF
24359
24360
24361 ac_fn_c_check_decl "$LINENO" "strstr" "ac_cv_have_decl_strstr" "$ac_includes_default"
24362if test "x$ac_cv_have_decl_strstr" = xyes; then :
24363 ac_have_decl=1
24364else
24365 ac_have_decl=0
24366fi
24367
24368cat >>confdefs.h <<_ACEOF
24369#define HAVE_DECL_STRSTR $ac_have_decl
24370_ACEOF
24371
24372
24373 # ----------------------- #
24374 # Checks for structures. #
24375 # ----------------------- #
24376
24377 ac_fn_c_check_member "$LINENO" "struct stat" "st_blocks" "ac_cv_member_struct_stat_st_blocks" "$ac_includes_default"
24378if test "x$ac_cv_member_struct_stat_st_blocks" = xyes; then :
24379
24380cat >>confdefs.h <<_ACEOF
24381#define HAVE_STRUCT_STAT_ST_BLOCKS 1
24382_ACEOF
24383
24384
24385fi
24386ac_fn_c_check_member "$LINENO" "struct stat" "st_blksize" "ac_cv_member_struct_stat_st_blksize" "$ac_includes_default"
24387if test "x$ac_cv_member_struct_stat_st_blksize" = xyes; then :
24388
24389cat >>confdefs.h <<_ACEOF
24390#define HAVE_STRUCT_STAT_ST_BLKSIZE 1
24391_ACEOF
24392
24393
24394fi
24395
24396
24397 # On FreeBSD we need libutil for the kinfo_get* functions. On
24398 # GNU/kFreeBSD systems, FreeBSD libutil is renamed to libutil-freebsd.
24399 # Figure out which one to use.
24400 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing kinfo_getfile" >&5
24401$as_echo_n "checking for library containing kinfo_getfile... " >&6; }
24402if ${ac_cv_search_kinfo_getfile+:} false; then :
24403 $as_echo_n "(cached) " >&6
24404else
24405 ac_func_search_save_LIBS=$LIBS
24406cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24407/* end confdefs.h. */
24408
24409/* Override any GCC internal prototype to avoid an error.
24410 Use char because int might match the return type of a GCC
24411 builtin and then its argument prototype would still apply. */
24412#ifdef __cplusplus
24413extern "C"
24414#endif
24415char kinfo_getfile ();
24416int
24417main ()
24418{
24419return kinfo_getfile ();
24420 ;
24421 return 0;
24422}
24423_ACEOF
24424for ac_lib in '' util util-freebsd; do
24425 if test -z "$ac_lib"; then
24426 ac_res="none required"
24427 else
24428 ac_res=-l$ac_lib
24429 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
24430 fi
24431 if ac_fn_c_try_link "$LINENO"; then :
24432 ac_cv_search_kinfo_getfile=$ac_res
24433fi
24434rm -f core conftest.err conftest.$ac_objext \
24435 conftest$ac_exeext
24436 if ${ac_cv_search_kinfo_getfile+:} false; then :
24437 break
24438fi
24439done
24440if ${ac_cv_search_kinfo_getfile+:} false; then :
24441
24442else
24443 ac_cv_search_kinfo_getfile=no
24444fi
24445rm conftest.$ac_ext
24446LIBS=$ac_func_search_save_LIBS
24447fi
24448{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_kinfo_getfile" >&5
24449$as_echo "$ac_cv_search_kinfo_getfile" >&6; }
24450ac_res=$ac_cv_search_kinfo_getfile
24451if test "$ac_res" != no; then :
24452 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
24453
24454fi
24455
24456
24457 # Define HAVE_KINFO_GETFILE if kinfo_getfile is available.
24458 for ac_func in kinfo_getfile
24459do :
24460 ac_fn_c_check_func "$LINENO" "kinfo_getfile" "ac_cv_func_kinfo_getfile"
24461if test "x$ac_cv_func_kinfo_getfile" = xyes; then :
24462 cat >>confdefs.h <<_ACEOF
24463#define HAVE_KINFO_GETFILE 1
24464_ACEOF
24465
24466fi
24467done
24468
24469
24470 # ----------------------- #
24471 # Check for threading. #
24472 # ----------------------- #
24473
24474 # Check whether --enable-threading was given.
24475if test "${enable_threading+set}" = set; then :
24476 enableval=$enable_threading; case "$enableval" in
24477 yes) want_threading=yes ;;
24478 no) want_threading=no ;;
24479 *) as_fn_error $? "bad value $enableval for threading" "$LINENO" 5 ;;
24480 esac
24481else
24482 want_threading=yes
24483fi
24484
24485
24486 # Check for std::thread. This does not work on some platforms, like
24487 # mingw and DJGPP.
24488 ac_ext=cpp
24489ac_cpp='$CXXCPP $CPPFLAGS'
24490ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
24491ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
24492ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
24493
24494
24495
24496
24497
24498ac_ext=c
24499ac_cpp='$CPP $CPPFLAGS'
24500ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
24501ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
24502ac_compiler_gnu=$ac_cv_c_compiler_gnu
24503
24504ax_pthread_ok=no
24505
24506# We used to check for pthread.h first, but this fails if pthread.h
24507# requires special compiler flags (e.g. on Tru64 or Sequent).
24508# It gets checked for in the link test anyway.
24509
24510# First of all, check if the user has set any of the PTHREAD_LIBS,
24511# etcetera environment variables, and if threads linking works using
24512# them:
24513if test "x$PTHREAD_CFLAGS$PTHREAD_LIBS" != "x"; then
24514 ax_pthread_save_CC="$CC"
24515 ax_pthread_save_CFLAGS="$CFLAGS"
24516 ax_pthread_save_LIBS="$LIBS"
24517 if test "x$PTHREAD_CC" != "x"; then :
24518 CC="$PTHREAD_CC"
24519fi
24520 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
24521 LIBS="$PTHREAD_LIBS $LIBS"
24522 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_join using $CC $PTHREAD_CFLAGS $PTHREAD_LIBS" >&5
24523$as_echo_n "checking for pthread_join using $CC $PTHREAD_CFLAGS $PTHREAD_LIBS... " >&6; }
24524 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24525/* end confdefs.h. */
24526
24527/* Override any GCC internal prototype to avoid an error.
24528 Use char because int might match the return type of a GCC
24529 builtin and then its argument prototype would still apply. */
24530#ifdef __cplusplus
24531extern "C"
24532#endif
24533char pthread_join ();
24534int
24535main ()
24536{
24537return pthread_join ();
24538 ;
24539 return 0;
24540}
24541_ACEOF
24542if ac_fn_c_try_link "$LINENO"; then :
24543 ax_pthread_ok=yes
24544fi
24545rm -f core conftest.err conftest.$ac_objext \
24546 conftest$ac_exeext conftest.$ac_ext
24547 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5
24548$as_echo "$ax_pthread_ok" >&6; }
24549 if test "x$ax_pthread_ok" = "xno"; then
24550 PTHREAD_LIBS=""
24551 PTHREAD_CFLAGS=""
24552 fi
24553 CC="$ax_pthread_save_CC"
24554 CFLAGS="$ax_pthread_save_CFLAGS"
24555 LIBS="$ax_pthread_save_LIBS"
24556fi
24557
24558# We must check for the threads library under a number of different
24559# names; the ordering is very important because some systems
24560# (e.g. DEC) have both -lpthread and -lpthreads, where one of the
24561# libraries is broken (non-POSIX).
24562
24563# Create a list of thread flags to try. Items starting with a "-" are
24564# C compiler flags, and other items are library names, except for "none"
24565# which indicates that we try without any flags at all, and "pthread-config"
24566# which is a program returning the flags for the Pth emulation library.
24567
24568ax_pthread_flags="pthreads none -Kthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config"
24569
24570# The ordering *is* (sometimes) important. Some notes on the
24571# individual items follow:
24572
24573# pthreads: AIX (must check this before -lpthread)
24574# none: in case threads are in libc; should be tried before -Kthread and
24575# other compiler flags to prevent continual compiler warnings
24576# -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
24577# -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads), Tru64
24578# (Note: HP C rejects this with "bad form for `-t' option")
24579# -pthreads: Solaris/gcc (Note: HP C also rejects)
24580# -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
24581# doesn't hurt to check since this sometimes defines pthreads and
24582# -D_REENTRANT too), HP C (must be checked before -lpthread, which
24583# is present but should not be used directly; and before -mthreads,
24584# because the compiler interprets this as "-mt" + "-hreads")
24585# -mthreads: Mingw32/gcc, Lynx/gcc
24586# pthread: Linux, etcetera
24587# --thread-safe: KAI C++
24588# pthread-config: use pthread-config program (for GNU Pth library)
24589
24590case $host_os in
24591
24592 freebsd*)
24593
24594 # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
24595 # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
24596
24597 ax_pthread_flags="-kthread lthread $ax_pthread_flags"
24598 ;;
24599
24600 hpux*)
24601
24602 # From the cc(1) man page: "[-mt] Sets various -D flags to enable
24603 # multi-threading and also sets -lpthread."
24604
24605 ax_pthread_flags="-mt -pthread pthread $ax_pthread_flags"
24606 ;;
24607
24608 openedition*)
24609
24610 # IBM z/OS requires a feature-test macro to be defined in order to
24611 # enable POSIX threads at all, so give the user a hint if this is
24612 # not set. (We don't define these ourselves, as they can affect
24613 # other portions of the system API in unpredictable ways.)
24614
24615 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24616/* end confdefs.h. */
24617
24618# if !defined(_OPEN_THREADS) && !defined(_UNIX03_THREADS)
24619 AX_PTHREAD_ZOS_MISSING
24620# endif
24621
24622_ACEOF
24623if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
24624 $EGREP "AX_PTHREAD_ZOS_MISSING" >/dev/null 2>&1; then :
24625 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: IBM z/OS requires -D_OPEN_THREADS or -D_UNIX03_THREADS to enable pthreads support." >&5
24626$as_echo "$as_me: WARNING: IBM z/OS requires -D_OPEN_THREADS or -D_UNIX03_THREADS to enable pthreads support." >&2;}
24627fi
24628rm -f conftest*
24629
24630 ;;
24631
24632 solaris*)
24633
24634 # On Solaris (at least, for some versions), libc contains stubbed
24635 # (non-functional) versions of the pthreads routines, so link-based
24636 # tests will erroneously succeed. (N.B.: The stubs are missing
24637 # pthread_cleanup_push, or rather a function called by this macro,
24638 # so we could check for that, but who knows whether they'll stub
24639 # that too in a future libc.) So we'll check first for the
24640 # standard Solaris way of linking pthreads (-mt -lpthread).
24641
24642 ax_pthread_flags="-mt,pthread pthread $ax_pthread_flags"
24643 ;;
24644esac
24645
24646# GCC generally uses -pthread, or -pthreads on some platforms (e.g. SPARC)
24647
24648if test "x$GCC" = "xyes"; then :
24649 ax_pthread_flags="-pthread -pthreads $ax_pthread_flags"
24650fi
24651
24652# The presence of a feature test macro requesting re-entrant function
24653# definitions is, on some systems, a strong hint that pthreads support is
24654# correctly enabled
24655
24656case $host_os in
24657 darwin* | hpux* | linux* | osf* | solaris*)
24658 ax_pthread_check_macro="_REENTRANT"
24659 ;;
24660
24661 aix*)
24662 ax_pthread_check_macro="_THREAD_SAFE"
24663 ;;
24664
24665 *)
24666 ax_pthread_check_macro="--"
24667 ;;
24668esac
24669if test "x$ax_pthread_check_macro" = "x--"; then :
24670 ax_pthread_check_cond=0
24671else
24672 ax_pthread_check_cond="!defined($ax_pthread_check_macro)"
24673fi
24674
24675# Are we compiling with Clang?
24676
24677{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC is Clang" >&5
24678$as_echo_n "checking whether $CC is Clang... " >&6; }
24679if ${ax_cv_PTHREAD_CLANG+:} false; then :
24680 $as_echo_n "(cached) " >&6
24681else
24682 ax_cv_PTHREAD_CLANG=no
24683 # Note that Autoconf sets GCC=yes for Clang as well as GCC
24684 if test "x$GCC" = "xyes"; then
24685 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24686/* end confdefs.h. */
24687/* Note: Clang 2.7 lacks __clang_[a-z]+__ */
24688# if defined(__clang__) && defined(__llvm__)
24689 AX_PTHREAD_CC_IS_CLANG
24690# endif
24691
24692_ACEOF
24693if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
24694 $EGREP "AX_PTHREAD_CC_IS_CLANG" >/dev/null 2>&1; then :
24695 ax_cv_PTHREAD_CLANG=yes
24696fi
24697rm -f conftest*
24698
24699 fi
24700
24701fi
24702{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_CLANG" >&5
24703$as_echo "$ax_cv_PTHREAD_CLANG" >&6; }
24704ax_pthread_clang="$ax_cv_PTHREAD_CLANG"
24705
24706ax_pthread_clang_warning=no
24707
24708# Clang needs special handling, because older versions handle the -pthread
24709# option in a rather... idiosyncratic way
24710
24711if test "x$ax_pthread_clang" = "xyes"; then
24712
24713 # Clang takes -pthread; it has never supported any other flag
24714
24715 # (Note 1: This will need to be revisited if a system that Clang
24716 # supports has POSIX threads in a separate library. This tends not
24717 # to be the way of modern systems, but it's conceivable.)
24718
24719 # (Note 2: On some systems, notably Darwin, -pthread is not needed
24720 # to get POSIX threads support; the API is always present and
24721 # active. We could reasonably leave PTHREAD_CFLAGS empty. But
24722 # -pthread does define _REENTRANT, and while the Darwin headers
24723 # ignore this macro, third-party headers might not.)
24724
24725 PTHREAD_CFLAGS="-pthread"
24726 PTHREAD_LIBS=
24727
24728 ax_pthread_ok=yes
24729
24730 # However, older versions of Clang make a point of warning the user
24731 # that, in an invocation where only linking and no compilation is
24732 # taking place, the -pthread option has no effect ("argument unused
24733 # during compilation"). They expect -pthread to be passed in only
24734 # when source code is being compiled.
24735 #
24736 # Problem is, this is at odds with the way Automake and most other
24737 # C build frameworks function, which is that the same flags used in
24738 # compilation (CFLAGS) are also used in linking. Many systems
24739 # supported by AX_PTHREAD require exactly this for POSIX threads
24740 # support, and in fact it is often not straightforward to specify a
24741 # flag that is used only in the compilation phase and not in
24742 # linking. Such a scenario is extremely rare in practice.
24743 #
24744 # Even though use of the -pthread flag in linking would only print
24745 # a warning, this can be a nuisance for well-run software projects
24746 # that build with -Werror. So if the active version of Clang has
24747 # this misfeature, we search for an option to squash it.
24748
24749 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether Clang needs flag to prevent \"argument unused\" warning when linking with -pthread" >&5
24750$as_echo_n "checking whether Clang needs flag to prevent \"argument unused\" warning when linking with -pthread... " >&6; }
24751if ${ax_cv_PTHREAD_CLANG_NO_WARN_FLAG+:} false; then :
24752 $as_echo_n "(cached) " >&6
24753else
24754 ax_cv_PTHREAD_CLANG_NO_WARN_FLAG=unknown
24755 # Create an alternate version of $ac_link that compiles and
24756 # links in two steps (.c -> .o, .o -> exe) instead of one
24757 # (.c -> exe), because the warning occurs only in the second
24758 # step
24759 ax_pthread_save_ac_link="$ac_link"
24760 ax_pthread_sed='s/conftest\.\$ac_ext/conftest.$ac_objext/g'
24761 ax_pthread_link_step=`$as_echo "$ac_link" | sed "$ax_pthread_sed"`
24762 ax_pthread_2step_ac_link="($ac_compile) && (echo ==== >&5) && ($ax_pthread_link_step)"
24763 ax_pthread_save_CFLAGS="$CFLAGS"
24764 for ax_pthread_try in '' -Qunused-arguments -Wno-unused-command-line-argument unknown; do
24765 if test "x$ax_pthread_try" = "xunknown"; then :
24766 break
24767fi
24768 CFLAGS="-Werror -Wunknown-warning-option $ax_pthread_try -pthread $ax_pthread_save_CFLAGS"
24769 ac_link="$ax_pthread_save_ac_link"
24770 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24771/* end confdefs.h. */
24772int main(void){return 0;}
24773_ACEOF
24774if ac_fn_c_try_link "$LINENO"; then :
24775 ac_link="$ax_pthread_2step_ac_link"
24776 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24777/* end confdefs.h. */
24778int main(void){return 0;}
24779_ACEOF
24780if ac_fn_c_try_link "$LINENO"; then :
24781 break
24782fi
24783rm -f core conftest.err conftest.$ac_objext \
24784 conftest$ac_exeext conftest.$ac_ext
24785
24786fi
24787rm -f core conftest.err conftest.$ac_objext \
24788 conftest$ac_exeext conftest.$ac_ext
24789 done
24790 ac_link="$ax_pthread_save_ac_link"
24791 CFLAGS="$ax_pthread_save_CFLAGS"
24792 if test "x$ax_pthread_try" = "x"; then :
24793 ax_pthread_try=no
24794fi
24795 ax_cv_PTHREAD_CLANG_NO_WARN_FLAG="$ax_pthread_try"
24796
24797fi
24798{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" >&5
24799$as_echo "$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" >&6; }
24800
24801 case "$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" in
24802 no | unknown) ;;
24803 *) PTHREAD_CFLAGS="$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG $PTHREAD_CFLAGS" ;;
24804 esac
24805
24806fi # $ax_pthread_clang = yes
24807
24808if test "x$ax_pthread_ok" = "xno"; then
24809for ax_pthread_try_flag in $ax_pthread_flags; do
24810
24811 case $ax_pthread_try_flag in
24812 none)
24813 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work without any flags" >&5
24814$as_echo_n "checking whether pthreads work without any flags... " >&6; }
24815 ;;
24816
24817 -mt,pthread)
24818 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with -mt -lpthread" >&5
24819$as_echo_n "checking whether pthreads work with -mt -lpthread... " >&6; }
24820 PTHREAD_CFLAGS="-mt"
24821 PTHREAD_LIBS="-lpthread"
24822 ;;
24823
24824 -*)
24825 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with $ax_pthread_try_flag" >&5
24826$as_echo_n "checking whether pthreads work with $ax_pthread_try_flag... " >&6; }
24827 PTHREAD_CFLAGS="$ax_pthread_try_flag"
24828 ;;
24829
24830 pthread-config)
24831 # Extract the first word of "pthread-config", so it can be a program name with args.
24832set dummy pthread-config; ac_word=$2
24833{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
24834$as_echo_n "checking for $ac_word... " >&6; }
24835if ${ac_cv_prog_ax_pthread_config+:} false; then :
24836 $as_echo_n "(cached) " >&6
24837else
24838 if test -n "$ax_pthread_config"; then
24839 ac_cv_prog_ax_pthread_config="$ax_pthread_config" # Let the user override the test.
24840else
24841as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24842for as_dir in $PATH
24843do
24844 IFS=$as_save_IFS
24845 test -z "$as_dir" && as_dir=.
24846 for ac_exec_ext in '' $ac_executable_extensions; do
24847 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
24848 ac_cv_prog_ax_pthread_config="yes"
24849 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
24850 break 2
24851 fi
24852done
24853 done
24854IFS=$as_save_IFS
24855
24856 test -z "$ac_cv_prog_ax_pthread_config" && ac_cv_prog_ax_pthread_config="no"
24857fi
24858fi
24859ax_pthread_config=$ac_cv_prog_ax_pthread_config
24860if test -n "$ax_pthread_config"; then
24861 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_config" >&5
24862$as_echo "$ax_pthread_config" >&6; }
24863else
24864 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24865$as_echo "no" >&6; }
24866fi
24867
24868
24869 if test "x$ax_pthread_config" = "xno"; then :
24870 continue
24871fi
24872 PTHREAD_CFLAGS="`pthread-config --cflags`"
24873 PTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
24874 ;;
24875
24876 *)
24877 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the pthreads library -l$ax_pthread_try_flag" >&5
24878$as_echo_n "checking for the pthreads library -l$ax_pthread_try_flag... " >&6; }
24879 PTHREAD_LIBS="-l$ax_pthread_try_flag"
24880 ;;
24881 esac
24882
24883 ax_pthread_save_CFLAGS="$CFLAGS"
24884 ax_pthread_save_LIBS="$LIBS"
24885 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
24886 LIBS="$PTHREAD_LIBS $LIBS"
24887
24888 # Check for various functions. We must include pthread.h,
24889 # since some functions may be macros. (On the Sequent, we
24890 # need a special flag -Kthread to make this header compile.)
24891 # We check for pthread_join because it is in -lpthread on IRIX
24892 # while pthread_create is in libc. We check for pthread_attr_init
24893 # due to DEC craziness with -lpthreads. We check for
24894 # pthread_cleanup_push because it is one of the few pthread
24895 # functions on Solaris that doesn't have a non-functional libc stub.
24896 # We try pthread_create on general principles.
24897
24898 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24899/* end confdefs.h. */
24900#include <pthread.h>
24901# if $ax_pthread_check_cond
24902# error "$ax_pthread_check_macro must be defined"
24903# endif
24904 static void routine(void *a) { a = 0; }
24905 static void *start_routine(void *a) { return a; }
24906int
24907main ()
24908{
24909pthread_t th; pthread_attr_t attr;
24910 pthread_create(&th, 0, start_routine, 0);
24911 pthread_join(th, 0);
24912 pthread_attr_init(&attr);
24913 pthread_cleanup_push(routine, 0);
24914 pthread_cleanup_pop(0) /* ; */
24915 ;
24916 return 0;
24917}
24918_ACEOF
24919if ac_fn_c_try_link "$LINENO"; then :
24920 ax_pthread_ok=yes
24921fi
24922rm -f core conftest.err conftest.$ac_objext \
24923 conftest$ac_exeext conftest.$ac_ext
24924
24925 CFLAGS="$ax_pthread_save_CFLAGS"
24926 LIBS="$ax_pthread_save_LIBS"
24927
24928 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5
24929$as_echo "$ax_pthread_ok" >&6; }
24930 if test "x$ax_pthread_ok" = "xyes"; then :
24931 break
24932fi
24933
24934 PTHREAD_LIBS=""
24935 PTHREAD_CFLAGS=""
24936done
24937fi
24938
24939# Various other checks:
24940if test "x$ax_pthread_ok" = "xyes"; then
24941 ax_pthread_save_CFLAGS="$CFLAGS"
24942 ax_pthread_save_LIBS="$LIBS"
24943 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
24944 LIBS="$PTHREAD_LIBS $LIBS"
24945
24946 # Detect AIX lossage: JOINABLE attribute is called UNDETACHED.
24947 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for joinable pthread attribute" >&5
24948$as_echo_n "checking for joinable pthread attribute... " >&6; }
24949if ${ax_cv_PTHREAD_JOINABLE_ATTR+:} false; then :
24950 $as_echo_n "(cached) " >&6
24951else
24952 ax_cv_PTHREAD_JOINABLE_ATTR=unknown
24953 for ax_pthread_attr in PTHREAD_CREATE_JOINABLE PTHREAD_CREATE_UNDETACHED; do
24954 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24955/* end confdefs.h. */
24956#include <pthread.h>
24957int
24958main ()
24959{
24960int attr = $ax_pthread_attr; return attr /* ; */
24961 ;
24962 return 0;
24963}
24964_ACEOF
24965if ac_fn_c_try_link "$LINENO"; then :
24966 ax_cv_PTHREAD_JOINABLE_ATTR=$ax_pthread_attr; break
24967fi
24968rm -f core conftest.err conftest.$ac_objext \
24969 conftest$ac_exeext conftest.$ac_ext
24970 done
24971
24972fi
24973{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_JOINABLE_ATTR" >&5
24974$as_echo "$ax_cv_PTHREAD_JOINABLE_ATTR" >&6; }
24975 if test "x$ax_cv_PTHREAD_JOINABLE_ATTR" != "xunknown" && \
24976 test "x$ax_cv_PTHREAD_JOINABLE_ATTR" != "xPTHREAD_CREATE_JOINABLE" && \
24977 test "x$ax_pthread_joinable_attr_defined" != "xyes"; then :
24978
24979cat >>confdefs.h <<_ACEOF
24980#define PTHREAD_CREATE_JOINABLE $ax_cv_PTHREAD_JOINABLE_ATTR
24981_ACEOF
24982
24983 ax_pthread_joinable_attr_defined=yes
24984
24985fi
24986
24987 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether more special flags are required for pthreads" >&5
24988$as_echo_n "checking whether more special flags are required for pthreads... " >&6; }
24989if ${ax_cv_PTHREAD_SPECIAL_FLAGS+:} false; then :
24990 $as_echo_n "(cached) " >&6
24991else
24992 ax_cv_PTHREAD_SPECIAL_FLAGS=no
24993 case $host_os in
24994 solaris*)
24995 ax_cv_PTHREAD_SPECIAL_FLAGS="-D_POSIX_PTHREAD_SEMANTICS"
24996 ;;
24997 esac
24998
24999fi
25000{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_SPECIAL_FLAGS" >&5
25001$as_echo "$ax_cv_PTHREAD_SPECIAL_FLAGS" >&6; }
25002 if test "x$ax_cv_PTHREAD_SPECIAL_FLAGS" != "xno" && \
25003 test "x$ax_pthread_special_flags_added" != "xyes"; then :
25004 PTHREAD_CFLAGS="$ax_cv_PTHREAD_SPECIAL_FLAGS $PTHREAD_CFLAGS"
25005 ax_pthread_special_flags_added=yes
25006fi
25007
25008 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTHREAD_PRIO_INHERIT" >&5
25009$as_echo_n "checking for PTHREAD_PRIO_INHERIT... " >&6; }
25010if ${ax_cv_PTHREAD_PRIO_INHERIT+:} false; then :
25011 $as_echo_n "(cached) " >&6
25012else
25013 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25014/* end confdefs.h. */
25015#include <pthread.h>
25016int
25017main ()
25018{
25019int i = PTHREAD_PRIO_INHERIT;
25020 ;
25021 return 0;
25022}
25023_ACEOF
25024if ac_fn_c_try_link "$LINENO"; then :
25025 ax_cv_PTHREAD_PRIO_INHERIT=yes
25026else
25027 ax_cv_PTHREAD_PRIO_INHERIT=no
25028fi
25029rm -f core conftest.err conftest.$ac_objext \
25030 conftest$ac_exeext conftest.$ac_ext
25031
25032fi
25033{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_PRIO_INHERIT" >&5
25034$as_echo "$ax_cv_PTHREAD_PRIO_INHERIT" >&6; }
25035 if test "x$ax_cv_PTHREAD_PRIO_INHERIT" = "xyes" && \
25036 test "x$ax_pthread_prio_inherit_defined" != "xyes"; then :
25037
25038$as_echo "#define HAVE_PTHREAD_PRIO_INHERIT 1" >>confdefs.h
25039
25040 ax_pthread_prio_inherit_defined=yes
25041
25042fi
25043
25044 CFLAGS="$ax_pthread_save_CFLAGS"
25045 LIBS="$ax_pthread_save_LIBS"
25046
25047 # More AIX lossage: compile with *_r variant
25048 if test "x$GCC" != "xyes"; then
25049 case $host_os in
25050 aix*)
25051 case "x/$CC" in #(
25052 x*/c89|x*/c89_128|x*/c99|x*/c99_128|x*/cc|x*/cc128|x*/xlc|x*/xlc_v6|x*/xlc128|x*/xlc128_v6) :
25053 #handle absolute path differently from PATH based program lookup
25054 case "x$CC" in #(
25055 x/*) :
25056 if as_fn_executable_p ${CC}_r; then :
25057 PTHREAD_CC="${CC}_r"
25058fi ;; #(
25059 *) :
25060 for ac_prog in ${CC}_r
25061do
25062 # Extract the first word of "$ac_prog", so it can be a program name with args.
25063set dummy $ac_prog; ac_word=$2
25064{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25065$as_echo_n "checking for $ac_word... " >&6; }
25066if ${ac_cv_prog_PTHREAD_CC+:} false; then :
25067 $as_echo_n "(cached) " >&6
25068else
25069 if test -n "$PTHREAD_CC"; then
25070 ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
25071else
25072as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25073for as_dir in $PATH
25074do
25075 IFS=$as_save_IFS
25076 test -z "$as_dir" && as_dir=.
25077 for ac_exec_ext in '' $ac_executable_extensions; do
25078 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25079 ac_cv_prog_PTHREAD_CC="$ac_prog"
25080 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25081 break 2
25082 fi
25083done
25084 done
25085IFS=$as_save_IFS
25086
25087fi
25088fi
25089PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
25090if test -n "$PTHREAD_CC"; then
25091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PTHREAD_CC" >&5
25092$as_echo "$PTHREAD_CC" >&6; }
25093else
25094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25095$as_echo "no" >&6; }
25096fi
25097
25098
25099 test -n "$PTHREAD_CC" && break
25100done
25101test -n "$PTHREAD_CC" || PTHREAD_CC="$CC"
25102 ;;
25103esac ;; #(
25104 *) :
25105 ;;
25106esac
25107 ;;
25108 esac
25109 fi
25110fi
25111
25112test -n "$PTHREAD_CC" || PTHREAD_CC="$CC"
25113
25114
25115
25116
25117
25118# Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
25119if test "x$ax_pthread_ok" = "xyes"; then
25120 threads=yes
25121 :
25122else
25123 ax_pthread_ok=no
25124 threads=no
25125fi
25126ac_ext=cpp
25127ac_cpp='$CXXCPP $CPPFLAGS'
25128ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
25129ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
25130ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
25131
25132
25133 save_LIBS="$LIBS"
25134 LIBS="$PTHREAD_LIBS $LIBS"
25135 save_CXXFLAGS="$CXXFLAGS"
25136 CXXFLAGS="$PTHREAD_CFLAGS $save_CXXFLAGS"
25137 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for std::thread" >&5
25138$as_echo_n "checking for std::thread... " >&6; }
25139if ${gdb_cv_cxx_std_thread+:} false; then :
25140 $as_echo_n "(cached) " >&6
25141else
25142 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25143/* end confdefs.h. */
2124b2de
TT
25144 #if defined (__MINGW32__) || defined (__CYGWIN__)
25145 # ifdef _WIN32_WINNT
25146 # if _WIN32_WINNT < 0x0501
25147 # undef _WIN32_WINNT
25148 # define _WIN32_WINNT 0x0501
25149 # endif
25150 # else
25151 # define _WIN32_WINNT 0x0501
25152 # endif
25153 #endif /* __MINGW32__ || __CYGWIN__ */
25154 #include <thread>
b686ecb5
JM
25155 void callback() { }
25156int
25157main ()
25158{
25159std::thread t(callback);
25160 ;
25161 return 0;
25162}
25163_ACEOF
25164if ac_fn_cxx_try_compile "$LINENO"; then :
25165 gdb_cv_cxx_std_thread=yes
25166else
25167 gdb_cv_cxx_std_thread=no
25168fi
25169rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25170fi
25171{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_cxx_std_thread" >&5
25172$as_echo "$gdb_cv_cxx_std_thread" >&6; }
25173
25174 if test "$threads" = "yes"; then
25175 # This check must be here, while LIBS includes any necessary
25176 # threading library.
25177 for ac_func in pthread_sigmask pthread_setname_np
25178do :
25179 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
25180ac_fn_cxx_check_func "$LINENO" "$ac_func" "$as_ac_var"
25181if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
25182 cat >>confdefs.h <<_ACEOF
25183#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
25184_ACEOF
25185
25186fi
25187done
25188
25189 fi
25190 LIBS="$save_LIBS"
25191 CXXFLAGS="$save_CXXFLAGS"
25192
25193 if test "$want_threading" = "yes"; then
25194 if test "$gdb_cv_cxx_std_thread" = "yes"; then
25195
25196$as_echo "#define CXX_STD_THREAD 1" >>confdefs.h
25197
25198 fi
25199 fi
25200 ac_ext=c
25201ac_cpp='$CPP $CPPFLAGS'
25202ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
25203ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
25204ac_compiler_gnu=$ac_cv_c_compiler_gnu
25205
25206
25207 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigsetjmp" >&5
25208$as_echo_n "checking for sigsetjmp... " >&6; }
25209if ${gdb_cv_func_sigsetjmp+:} false; then :
25210 $as_echo_n "(cached) " >&6
25211else
25212 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25213/* end confdefs.h. */
25214#include <setjmp.h>
25215int
25216main ()
25217{
25218sigjmp_buf env;
25219 while (! sigsetjmp (env, 1))
25220 siglongjmp (env, 1);
25221
25222 ;
25223 return 0;
25224}
25225_ACEOF
25226if ac_fn_c_try_compile "$LINENO"; then :
25227 gdb_cv_func_sigsetjmp=yes
25228else
25229 gdb_cv_func_sigsetjmp=no
25230
25231fi
25232rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25233
25234fi
25235{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_func_sigsetjmp" >&5
25236$as_echo "$gdb_cv_func_sigsetjmp" >&6; }
25237 if test "$gdb_cv_func_sigsetjmp" = "yes"; then
25238
25239$as_echo "#define HAVE_SIGSETJMP 1" >>confdefs.h
25240
25241 fi
25242
25243
25244# Check whether --with-intel_pt was given.
25245if test "${with_intel_pt+set}" = set; then :
25246 withval=$with_intel_pt;
25247else
25248 with_intel_pt=auto
25249fi
25250
25251 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use intel pt" >&5
25252$as_echo_n "checking whether to use intel pt... " >&6; }
25253 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_intel_pt" >&5
25254$as_echo "$with_intel_pt" >&6; }
25255
25256 if test "${with_intel_pt}" = no; then
25257 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Intel Processor Trace support disabled; some features may be unavailable." >&5
25258$as_echo "$as_me: WARNING: Intel Processor Trace support disabled; some features may be unavailable." >&2;}
25259 HAVE_LIBIPT=no
25260 else
25261 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25262/* end confdefs.h. */
25263
25264 #include <linux/perf_event.h>
25265 #ifndef PERF_ATTR_SIZE_VER5
25266 # error
25267 #endif
25268
25269_ACEOF
25270if ac_fn_c_try_cpp "$LINENO"; then :
25271 perf_event=yes
25272else
25273 perf_event=no
25274fi
25275rm -f conftest.err conftest.i conftest.$ac_ext
25276 if test "$perf_event" != yes; then
25277 if test "$with_intel_pt" = yes; then
25278 as_fn_error $? "linux/perf_event.h missing or too old" "$LINENO" 5
25279 else
25280 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: linux/perf_event.h missing or too old; some features may be unavailable." >&5
25281$as_echo "$as_me: WARNING: linux/perf_event.h missing or too old; some features may be unavailable." >&2;}
25282 fi
25283 fi
25284
25285
25286
25287
25288
25289
25290
25291
25292
25293 use_additional=yes
25294
25295 acl_save_prefix="$prefix"
25296 prefix="$acl_final_prefix"
25297 acl_save_exec_prefix="$exec_prefix"
25298 exec_prefix="$acl_final_exec_prefix"
25299
25300 eval additional_includedir=\"$includedir\"
25301 eval additional_libdir=\"$libdir\"
25302
25303 exec_prefix="$acl_save_exec_prefix"
25304 prefix="$acl_save_prefix"
25305
25306
25307# Check whether --with-libipt-prefix was given.
25308if test "${with_libipt_prefix+set}" = set; then :
25309 withval=$with_libipt_prefix;
25310 if test "X$withval" = "Xno"; then
25311 use_additional=no
25312 else
25313 if test "X$withval" = "X"; then
25314
25315 acl_save_prefix="$prefix"
25316 prefix="$acl_final_prefix"
25317 acl_save_exec_prefix="$exec_prefix"
25318 exec_prefix="$acl_final_exec_prefix"
25319
25320 eval additional_includedir=\"$includedir\"
25321 eval additional_libdir=\"$libdir\"
25322
25323 exec_prefix="$acl_save_exec_prefix"
25324 prefix="$acl_save_prefix"
25325
25326 else
25327 additional_includedir="$withval/include"
25328 additional_libdir="$withval/lib"
25329 fi
25330 fi
25331
25332fi
25333
25334
25335# Check whether --with-libipt-type was given.
25336if test "${with_libipt_type+set}" = set; then :
25337 withval=$with_libipt_type; with_libipt_type=$withval
25338else
25339 with_libipt_type=auto
25340fi
25341
25342 lib_type=`eval echo \$with_libipt_type`
25343
25344 LIBIPT=
25345 LTLIBIPT=
25346 INCIPT=
25347 rpathdirs=
25348 ltrpathdirs=
05ea2a05
TT
25349 names_already_handled=
25350 names_next_round='ipt '
25351 while test -n "$names_next_round"; do
25352 names_this_round="$names_next_round"
25353 names_next_round=
25354 for name in $names_this_round; do
25355 already_handled=
25356 for n in $names_already_handled; do
25357 if test "$n" = "$name"; then
25358 already_handled=yes
25359 break
25360 fi
25361 done
25362 if test -z "$already_handled"; then
25363 names_already_handled="$names_already_handled $name"
25364 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
25365 eval value=\"\$HAVE_LIB$uppername\"
25366 if test -n "$value"; then
25367 if test "$value" = yes; then
25368 eval value=\"\$LIB$uppername\"
25369 test -z "$value" || LIBIPT="${LIBIPT}${LIBIPT:+ }$value"
25370 eval value=\"\$LTLIB$uppername\"
25371 test -z "$value" || LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }$value"
25372 else
25373 :
25374 fi
25375 else
25376 found_dir=
25377 found_la=
25378 found_so=
25379 found_a=
25380 if test $use_additional = yes; then
9f1528a1 25381 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
05ea2a05
TT
25382 found_dir="$additional_libdir"
25383 found_so="$additional_libdir/lib$name.$shlibext"
25384 if test -f "$additional_libdir/lib$name.la"; then
25385 found_la="$additional_libdir/lib$name.la"
25386 fi
9f1528a1 25387 elif test x$lib_type != xshared; then
05ea2a05
TT
25388 if test -f "$additional_libdir/lib$name.$libext"; then
25389 found_dir="$additional_libdir"
25390 found_a="$additional_libdir/lib$name.$libext"
25391 if test -f "$additional_libdir/lib$name.la"; then
25392 found_la="$additional_libdir/lib$name.la"
25393 fi
25394 fi
25395 fi
25396 fi
25397 if test "X$found_dir" = "X"; then
25398 for x in $LDFLAGS $LTLIBIPT; do
5e030278 25399
05ea2a05
TT
25400 acl_save_prefix="$prefix"
25401 prefix="$acl_final_prefix"
25402 acl_save_exec_prefix="$exec_prefix"
25403 exec_prefix="$acl_final_exec_prefix"
25404 eval x=\"$x\"
25405 exec_prefix="$acl_save_exec_prefix"
25406 prefix="$acl_save_prefix"
5e030278 25407
05ea2a05
TT
25408 case "$x" in
25409 -L*)
25410 dir=`echo "X$x" | sed -e 's/^X-L//'`
9f1528a1 25411 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
05ea2a05
TT
25412 found_dir="$dir"
25413 found_so="$dir/lib$name.$shlibext"
25414 if test -f "$dir/lib$name.la"; then
25415 found_la="$dir/lib$name.la"
25416 fi
9f1528a1 25417 elif test x$lib_type != xshared; then
05ea2a05
TT
25418 if test -f "$dir/lib$name.$libext"; then
25419 found_dir="$dir"
25420 found_a="$dir/lib$name.$libext"
25421 if test -f "$dir/lib$name.la"; then
25422 found_la="$dir/lib$name.la"
25423 fi
25424 fi
25425 fi
25426 ;;
25427 esac
25428 if test "X$found_dir" != "X"; then
25429 break
25430 fi
25431 done
25432 fi
25433 if test "X$found_dir" != "X"; then
25434 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-L$found_dir -l$name"
25435 if test "X$found_so" != "X"; then
25436 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
25437 LIBIPT="${LIBIPT}${LIBIPT:+ }$found_so"
25438 else
25439 haveit=
25440 for x in $ltrpathdirs; do
25441 if test "X$x" = "X$found_dir"; then
25442 haveit=yes
25443 break
25444 fi
25445 done
25446 if test -z "$haveit"; then
25447 ltrpathdirs="$ltrpathdirs $found_dir"
25448 fi
25449 if test "$hardcode_direct" = yes; then
25450 LIBIPT="${LIBIPT}${LIBIPT:+ }$found_so"
25451 else
25452 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
25453 LIBIPT="${LIBIPT}${LIBIPT:+ }$found_so"
25454 haveit=
25455 for x in $rpathdirs; do
25456 if test "X$x" = "X$found_dir"; then
25457 haveit=yes
25458 break
25459 fi
25460 done
25461 if test -z "$haveit"; then
25462 rpathdirs="$rpathdirs $found_dir"
25463 fi
25464 else
25465 haveit=
25466 for x in $LDFLAGS $LIBIPT; do
5e030278 25467
05ea2a05
TT
25468 acl_save_prefix="$prefix"
25469 prefix="$acl_final_prefix"
25470 acl_save_exec_prefix="$exec_prefix"
25471 exec_prefix="$acl_final_exec_prefix"
25472 eval x=\"$x\"
25473 exec_prefix="$acl_save_exec_prefix"
25474 prefix="$acl_save_prefix"
5e030278 25475
05ea2a05
TT
25476 if test "X$x" = "X-L$found_dir"; then
25477 haveit=yes
25478 break
25479 fi
25480 done
25481 if test -z "$haveit"; then
25482 LIBIPT="${LIBIPT}${LIBIPT:+ }-L$found_dir"
25483 fi
25484 if test "$hardcode_minus_L" != no; then
25485 LIBIPT="${LIBIPT}${LIBIPT:+ }$found_so"
25486 else
25487 LIBIPT="${LIBIPT}${LIBIPT:+ }-l$name"
25488 fi
25489 fi
25490 fi
25491 fi
25492 else
25493 if test "X$found_a" != "X"; then
25494 LIBIPT="${LIBIPT}${LIBIPT:+ }$found_a"
25495 else
25496 LIBIPT="${LIBIPT}${LIBIPT:+ }-L$found_dir -l$name"
25497 fi
25498 fi
25499 additional_includedir=
25500 case "$found_dir" in
25501 */lib | */lib/)
25502 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
25503 additional_includedir="$basedir/include"
25504 ;;
25505 esac
25506 if test "X$additional_includedir" != "X"; then
25507 if test "X$additional_includedir" != "X/usr/include"; then
25508 haveit=
25509 if test "X$additional_includedir" = "X/usr/local/include"; then
25510 if test -n "$GCC"; then
25511 case $host_os in
25512 linux*) haveit=yes;;
25513 esac
25514 fi
25515 fi
25516 if test -z "$haveit"; then
25517 for x in $CPPFLAGS $INCIPT; do
5e030278 25518
05ea2a05
TT
25519 acl_save_prefix="$prefix"
25520 prefix="$acl_final_prefix"
25521 acl_save_exec_prefix="$exec_prefix"
25522 exec_prefix="$acl_final_exec_prefix"
25523 eval x=\"$x\"
25524 exec_prefix="$acl_save_exec_prefix"
25525 prefix="$acl_save_prefix"
5e030278 25526
05ea2a05
TT
25527 if test "X$x" = "X-I$additional_includedir"; then
25528 haveit=yes
25529 break
25530 fi
25531 done
25532 if test -z "$haveit"; then
25533 if test -d "$additional_includedir"; then
25534 INCIPT="${INCIPT}${INCIPT:+ }-I$additional_includedir"
25535 fi
25536 fi
25537 fi
25538 fi
25539 fi
25540 if test -n "$found_la"; then
25541 save_libdir="$libdir"
25542 case "$found_la" in
25543 */* | *\\*) . "$found_la" ;;
25544 *) . "./$found_la" ;;
25545 esac
25546 libdir="$save_libdir"
25547 for dep in $dependency_libs; do
25548 case "$dep" in
25549 -L*)
25550 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
25551 if test "X$additional_libdir" != "X/usr/lib"; then
25552 haveit=
25553 if test "X$additional_libdir" = "X/usr/local/lib"; then
25554 if test -n "$GCC"; then
25555 case $host_os in
25556 linux*) haveit=yes;;
25557 esac
25558 fi
25559 fi
25560 if test -z "$haveit"; then
25561 haveit=
25562 for x in $LDFLAGS $LIBIPT; do
5e030278 25563
05ea2a05
TT
25564 acl_save_prefix="$prefix"
25565 prefix="$acl_final_prefix"
25566 acl_save_exec_prefix="$exec_prefix"
25567 exec_prefix="$acl_final_exec_prefix"
25568 eval x=\"$x\"
25569 exec_prefix="$acl_save_exec_prefix"
25570 prefix="$acl_save_prefix"
5e030278 25571
05ea2a05
TT
25572 if test "X$x" = "X-L$additional_libdir"; then
25573 haveit=yes
25574 break
25575 fi
25576 done
25577 if test -z "$haveit"; then
25578 if test -d "$additional_libdir"; then
25579 LIBIPT="${LIBIPT}${LIBIPT:+ }-L$additional_libdir"
25580 fi
25581 fi
25582 haveit=
25583 for x in $LDFLAGS $LTLIBIPT; do
5e030278 25584
05ea2a05
TT
25585 acl_save_prefix="$prefix"
25586 prefix="$acl_final_prefix"
25587 acl_save_exec_prefix="$exec_prefix"
25588 exec_prefix="$acl_final_exec_prefix"
25589 eval x=\"$x\"
25590 exec_prefix="$acl_save_exec_prefix"
25591 prefix="$acl_save_prefix"
5e030278 25592
05ea2a05
TT
25593 if test "X$x" = "X-L$additional_libdir"; then
25594 haveit=yes
25595 break
25596 fi
25597 done
25598 if test -z "$haveit"; then
25599 if test -d "$additional_libdir"; then
25600 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-L$additional_libdir"
25601 fi
25602 fi
25603 fi
25604 fi
25605 ;;
25606 -R*)
25607 dir=`echo "X$dep" | sed -e 's/^X-R//'`
25608 if test "$enable_rpath" != no; then
25609 haveit=
25610 for x in $rpathdirs; do
25611 if test "X$x" = "X$dir"; then
25612 haveit=yes
25613 break
25614 fi
25615 done
25616 if test -z "$haveit"; then
25617 rpathdirs="$rpathdirs $dir"
25618 fi
25619 haveit=
25620 for x in $ltrpathdirs; do
25621 if test "X$x" = "X$dir"; then
25622 haveit=yes
25623 break
25624 fi
25625 done
25626 if test -z "$haveit"; then
25627 ltrpathdirs="$ltrpathdirs $dir"
25628 fi
25629 fi
25630 ;;
25631 -l*)
25632 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
25633 ;;
25634 *.la)
25635 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
25636 ;;
25637 *)
25638 LIBIPT="${LIBIPT}${LIBIPT:+ }$dep"
25639 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }$dep"
25640 ;;
25641 esac
25642 done
25643 fi
25644 else
9f1528a1
AB
25645 if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
25646 LIBIPT="${LIBIPT}${LIBIPT:+ }-l$name"
25647 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-l$name"
25648 else
25649 LIBIPT="${LIBIPT}${LIBIPT:+ }-l:lib$name.$libext"
25650 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-l:lib$name.$libext"
25651 fi
05ea2a05 25652 fi
5e030278 25653 fi
05ea2a05
TT
25654 fi
25655 done
25656 done
25657 if test "X$rpathdirs" != "X"; then
25658 if test -n "$hardcode_libdir_separator"; then
25659 alldirs=
25660 for found_dir in $rpathdirs; do
25661 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
25662 done
25663 acl_save_libdir="$libdir"
25664 libdir="$alldirs"
25665 eval flag=\"$hardcode_libdir_flag_spec\"
25666 libdir="$acl_save_libdir"
25667 LIBIPT="${LIBIPT}${LIBIPT:+ }$flag"
25668 else
25669 for found_dir in $rpathdirs; do
25670 acl_save_libdir="$libdir"
25671 libdir="$found_dir"
25672 eval flag=\"$hardcode_libdir_flag_spec\"
25673 libdir="$acl_save_libdir"
25674 LIBIPT="${LIBIPT}${LIBIPT:+ }$flag"
25675 done
25676 fi
25677 fi
25678 if test "X$ltrpathdirs" != "X"; then
25679 for found_dir in $ltrpathdirs; do
25680 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-R$found_dir"
25681 done
25682 fi
5e030278
TT
25683
25684
05ea2a05 25685 ac_save_CPPFLAGS="$CPPFLAGS"
5e030278 25686
05ea2a05
TT
25687 for element in $INCIPT; do
25688 haveit=
25689 for x in $CPPFLAGS; do
5e030278 25690
05ea2a05
TT
25691 acl_save_prefix="$prefix"
25692 prefix="$acl_final_prefix"
25693 acl_save_exec_prefix="$exec_prefix"
25694 exec_prefix="$acl_final_exec_prefix"
25695 eval x=\"$x\"
25696 exec_prefix="$acl_save_exec_prefix"
25697 prefix="$acl_save_prefix"
5e030278 25698
05ea2a05
TT
25699 if test "X$x" = "X$element"; then
25700 haveit=yes
25701 break
25702 fi
25703 done
25704 if test -z "$haveit"; then
25705 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
25706 fi
25707 done
5e030278
TT
25708
25709
05ea2a05
TT
25710 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libipt" >&5
25711$as_echo_n "checking for libipt... " >&6; }
25712if ${ac_cv_libipt+:} false; then :
5e030278
TT
25713 $as_echo_n "(cached) " >&6
25714else
05ea2a05
TT
25715
25716 ac_save_LIBS="$LIBS"
25717 LIBS="$LIBS $LIBIPT"
25718 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5e030278 25719/* end confdefs.h. */
05ea2a05 25720#include "intel-pt.h"
5e030278
TT
25721int
25722main ()
25723{
05ea2a05 25724pt_insn_alloc_decoder (0);
5e030278
TT
25725 ;
25726 return 0;
25727}
25728_ACEOF
05ea2a05
TT
25729if ac_fn_c_try_link "$LINENO"; then :
25730 ac_cv_libipt=yes
5e030278 25731else
05ea2a05 25732 ac_cv_libipt=no
5e030278 25733fi
05ea2a05
TT
25734rm -f core conftest.err conftest.$ac_objext \
25735 conftest$ac_exeext conftest.$ac_ext
25736 LIBS="$ac_save_LIBS"
25737
5e030278 25738fi
05ea2a05
TT
25739{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libipt" >&5
25740$as_echo "$ac_cv_libipt" >&6; }
25741 if test "$ac_cv_libipt" = yes; then
25742 HAVE_LIBIPT=yes
21987b9c 25743
05ea2a05
TT
25744$as_echo "#define HAVE_LIBIPT 1" >>confdefs.h
25745
25746 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libipt" >&5
25747$as_echo_n "checking how to link with libipt... " >&6; }
25748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBIPT" >&5
25749$as_echo "$LIBIPT" >&6; }
25750 else
25751 HAVE_LIBIPT=no
25752 CPPFLAGS="$ac_save_CPPFLAGS"
25753 LIBIPT=
25754 LTLIBIPT=
25755 fi
25756
25757
25758
25759
25760
25761
25762 if test "$HAVE_LIBIPT" != yes; then
25763 if test "$with_intel_pt" = yes; then
25764 as_fn_error $? "libipt is missing or unusable" "$LINENO" 5
25765 else
25766 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libipt is missing or unusable; some features may be unavailable." >&5
25767$as_echo "$as_me: WARNING: libipt is missing or unusable; some features may be unavailable." >&2;}
25768 fi
25769 else
25770 save_LIBS=$LIBS
25771 LIBS="$LIBS $LIBIPT"
25772 for ac_func in pt_insn_event
21987b9c 25773do :
05ea2a05
TT
25774 ac_fn_c_check_func "$LINENO" "pt_insn_event" "ac_cv_func_pt_insn_event"
25775if test "x$ac_cv_func_pt_insn_event" = xyes; then :
21987b9c 25776 cat >>confdefs.h <<_ACEOF
05ea2a05 25777#define HAVE_PT_INSN_EVENT 1
21987b9c
TT
25778_ACEOF
25779
25780fi
25781done
25782
05ea2a05
TT
25783 ac_fn_c_check_member "$LINENO" "struct pt_insn" "enabled" "ac_cv_member_struct_pt_insn_enabled" "#include <intel-pt.h>
25784"
25785if test "x$ac_cv_member_struct_pt_insn_enabled" = xyes; then :
21987b9c 25786
05ea2a05
TT
25787cat >>confdefs.h <<_ACEOF
25788#define HAVE_STRUCT_PT_INSN_ENABLED 1
25789_ACEOF
5e030278 25790
5e030278 25791
05ea2a05
TT
25792fi
25793ac_fn_c_check_member "$LINENO" "struct pt_insn" "resynced" "ac_cv_member_struct_pt_insn_resynced" "#include <intel-pt.h>
25794"
25795if test "x$ac_cv_member_struct_pt_insn_resynced" = xyes; then :
25796
25797cat >>confdefs.h <<_ACEOF
25798#define HAVE_STRUCT_PT_INSN_RESYNCED 1
25799_ACEOF
5e030278
TT
25800
25801
05ea2a05
TT
25802fi
25803
25804 LIBS=$save_LIBS
25805 fi
25806 fi
25807
5dfe4bfc
TT
25808 # Check if the compiler and runtime support printing long longs.
25809
25810 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long support in printf" >&5
25811$as_echo_n "checking for long long support in printf... " >&6; }
25812if ${gdb_cv_printf_has_long_long+:} false; then :
25813 $as_echo_n "(cached) " >&6
25814else
25815 if test "$cross_compiling" = yes; then :
25816 gdb_cv_printf_has_long_long=no
25817else
25818 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25819/* end confdefs.h. */
25820$ac_includes_default
25821int
25822main ()
25823{
25824char buf[32];
25825 long long l = 0;
25826 l = (l << 16) + 0x0123;
25827 l = (l << 16) + 0x4567;
25828 l = (l << 16) + 0x89ab;
25829 l = (l << 16) + 0xcdef;
25830 sprintf (buf, "0x%016llx", l);
25831 return (strcmp ("0x0123456789abcdef", buf));
25832 ;
25833 return 0;
25834}
25835_ACEOF
25836if ac_fn_c_try_run "$LINENO"; then :
25837 gdb_cv_printf_has_long_long=yes
25838else
25839 gdb_cv_printf_has_long_long=no
25840fi
25841rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25842 conftest.$ac_objext conftest.beam conftest.$ac_ext
25843fi
25844
25845fi
25846{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_printf_has_long_long" >&5
25847$as_echo "$gdb_cv_printf_has_long_long" >&6; }
25848 if test "$gdb_cv_printf_has_long_long" = yes; then
25849
25850$as_echo "#define PRINTF_HAS_LONG_LONG 1" >>confdefs.h
25851
25852 fi
25853
c8693053
RO
25854
25855$as_echo "#define _STRUCTURED_PROC 1" >>confdefs.h
25856
25857 for ac_header in sys/procfs.h
25858do :
25859 ac_fn_c_check_header_mongrel "$LINENO" "sys/procfs.h" "ac_cv_header_sys_procfs_h" "$ac_includes_default"
25860if test "x$ac_cv_header_sys_procfs_h" = xyes; then :
25861 cat >>confdefs.h <<_ACEOF
25862#define HAVE_SYS_PROCFS_H 1
25863_ACEOF
25864
25865fi
25866
25867done
25868
05ea2a05 25869 if test "$ac_cv_header_sys_procfs_h" = yes; then
c8693053
RO
25870
25871 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gregset_t in sys/procfs.h" >&5
05ea2a05
TT
25872$as_echo_n "checking for gregset_t in sys/procfs.h... " >&6; }
25873 if ${bfd_cv_have_sys_procfs_type_gregset_t+:} false; then :
e9bcb658
GB
25874 $as_echo_n "(cached) " >&6
25875else
25876 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25877/* end confdefs.h. */
25878
05ea2a05 25879#define _SYSCALL32
05ea2a05 25880#include <sys/procfs.h>
e9bcb658
GB
25881int
25882main ()
25883{
05ea2a05 25884gregset_t avar
e9bcb658
GB
25885 ;
25886 return 0;
25887}
25888_ACEOF
25889if ac_fn_c_try_compile "$LINENO"; then :
05ea2a05 25890 bfd_cv_have_sys_procfs_type_gregset_t=yes
e9bcb658 25891else
05ea2a05 25892 bfd_cv_have_sys_procfs_type_gregset_t=no
54019719
PA
25893
25894fi
05ea2a05 25895rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
06825bd1 25896fi
06825bd1 25897
05ea2a05 25898 if test $bfd_cv_have_sys_procfs_type_gregset_t = yes; then
a3828db0 25899
05ea2a05 25900$as_echo "#define HAVE_GREGSET_T 1" >>confdefs.h
06825bd1 25901
05ea2a05
TT
25902 fi
25903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_gregset_t" >&5
25904$as_echo "$bfd_cv_have_sys_procfs_type_gregset_t" >&6; }
25905
c8693053
RO
25906
25907 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fpregset_t in sys/procfs.h" >&5
05ea2a05
TT
25908$as_echo_n "checking for fpregset_t in sys/procfs.h... " >&6; }
25909 if ${bfd_cv_have_sys_procfs_type_fpregset_t+:} false; then :
81ecdfbb 25910 $as_echo_n "(cached) " >&6
bec39cab 25911else
81ecdfbb 25912 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 25913/* end confdefs.h. */
05ea2a05
TT
25914
25915#define _SYSCALL32
05ea2a05 25916#include <sys/procfs.h>
bec39cab
AC
25917int
25918main ()
25919{
05ea2a05 25920fpregset_t avar
064ef605
DJ
25921 ;
25922 return 0;
25923}
25924_ACEOF
9b30624b 25925if ac_fn_c_try_compile "$LINENO"; then :
05ea2a05
TT
25926 bfd_cv_have_sys_procfs_type_fpregset_t=yes
25927else
25928 bfd_cv_have_sys_procfs_type_fpregset_t=no
25929
25930fi
25931rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25932fi
25933
25934 if test $bfd_cv_have_sys_procfs_type_fpregset_t = yes; then
25935
25936$as_echo "#define HAVE_FPREGSET_T 1" >>confdefs.h
25937
25938 fi
25939 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_fpregset_t" >&5
25940$as_echo "$bfd_cv_have_sys_procfs_type_fpregset_t" >&6; }
25941
c8693053
RO
25942
25943 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prgregset_t in sys/procfs.h" >&5
05ea2a05
TT
25944$as_echo_n "checking for prgregset_t in sys/procfs.h... " >&6; }
25945 if ${bfd_cv_have_sys_procfs_type_prgregset_t+:} false; then :
25946 $as_echo_n "(cached) " >&6
064ef605 25947else
81ecdfbb 25948 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
064ef605 25949/* end confdefs.h. */
05ea2a05
TT
25950
25951#define _SYSCALL32
05ea2a05 25952#include <sys/procfs.h>
064ef605
DJ
25953int
25954main ()
25955{
05ea2a05 25956prgregset_t avar
bec39cab
AC
25957 ;
25958 return 0;
25959}
25960_ACEOF
9b30624b 25961if ac_fn_c_try_compile "$LINENO"; then :
05ea2a05 25962 bfd_cv_have_sys_procfs_type_prgregset_t=yes
70f9f479 25963else
05ea2a05
TT
25964 bfd_cv_have_sys_procfs_type_prgregset_t=no
25965
70f9f479 25966fi
81ecdfbb 25967rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
064ef605 25968fi
bec39cab 25969
05ea2a05 25970 if test $bfd_cv_have_sys_procfs_type_prgregset_t = yes; then
70f9f479 25971
05ea2a05
TT
25972$as_echo "#define HAVE_PRGREGSET_T 1" >>confdefs.h
25973
25974 fi
25975 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prgregset_t" >&5
25976$as_echo "$bfd_cv_have_sys_procfs_type_prgregset_t" >&6; }
25977
c8693053
RO
25978
25979 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prfpregset_t in sys/procfs.h" >&5
05ea2a05
TT
25980$as_echo_n "checking for prfpregset_t in sys/procfs.h... " >&6; }
25981 if ${bfd_cv_have_sys_procfs_type_prfpregset_t+:} false; then :
81ecdfbb 25982 $as_echo_n "(cached) " >&6
bec39cab 25983else
81ecdfbb 25984 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
064ef605 25985/* end confdefs.h. */
05ea2a05
TT
25986
25987#define _SYSCALL32
05ea2a05 25988#include <sys/procfs.h>
064ef605
DJ
25989int
25990main ()
25991{
05ea2a05 25992prfpregset_t avar
064ef605
DJ
25993 ;
25994 return 0;
25995}
25996_ACEOF
9b30624b 25997if ac_fn_c_try_compile "$LINENO"; then :
05ea2a05 25998 bfd_cv_have_sys_procfs_type_prfpregset_t=yes
064ef605 25999else
05ea2a05 26000 bfd_cv_have_sys_procfs_type_prfpregset_t=no
064ef605 26001
5c7f2947 26002fi
81ecdfbb 26003rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
05ea2a05
TT
26004fi
26005
26006 if test $bfd_cv_have_sys_procfs_type_prfpregset_t = yes; then
26007
26008$as_echo "#define HAVE_PRFPREGSET_T 1" >>confdefs.h
26009
26010 fi
26011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prfpregset_t" >&5
26012$as_echo "$bfd_cv_have_sys_procfs_type_prfpregset_t" >&6; }
26013
c8693053
RO
26014
26015 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prgregset32_t in sys/procfs.h" >&5
05ea2a05
TT
26016$as_echo_n "checking for prgregset32_t in sys/procfs.h... " >&6; }
26017 if ${bfd_cv_have_sys_procfs_type_prgregset32_t+:} false; then :
26018 $as_echo_n "(cached) " >&6
26019else
26020 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 26021/* end confdefs.h. */
05ea2a05
TT
26022
26023#define _SYSCALL32
05ea2a05 26024#include <sys/procfs.h>
bec39cab
AC
26025int
26026main ()
26027{
05ea2a05 26028prgregset32_t avar
bec39cab
AC
26029 ;
26030 return 0;
26031}
26032_ACEOF
9b30624b 26033if ac_fn_c_try_compile "$LINENO"; then :
05ea2a05
TT
26034 bfd_cv_have_sys_procfs_type_prgregset32_t=yes
26035else
26036 bfd_cv_have_sys_procfs_type_prgregset32_t=no
a3828db0 26037
064ef605 26038fi
81ecdfbb 26039rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
78434e59 26040fi
96d7229d 26041
05ea2a05 26042 if test $bfd_cv_have_sys_procfs_type_prgregset32_t = yes; then
78434e59 26043
05ea2a05 26044$as_echo "#define HAVE_PRGREGSET32_T 1" >>confdefs.h
78434e59 26045
05ea2a05
TT
26046 fi
26047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prgregset32_t" >&5
26048$as_echo "$bfd_cv_have_sys_procfs_type_prgregset32_t" >&6; }
54019719 26049
c8693053
RO
26050
26051 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lwpid_t in sys/procfs.h" >&5
05ea2a05
TT
26052$as_echo_n "checking for lwpid_t in sys/procfs.h... " >&6; }
26053 if ${bfd_cv_have_sys_procfs_type_lwpid_t+:} false; then :
81ecdfbb 26054 $as_echo_n "(cached) " >&6
bec39cab 26055else
81ecdfbb 26056 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 26057/* end confdefs.h. */
05ea2a05
TT
26058
26059#define _SYSCALL32
05ea2a05 26060#include <sys/procfs.h>
bec39cab
AC
26061int
26062main ()
26063{
05ea2a05 26064lwpid_t avar
bec39cab
AC
26065 ;
26066 return 0;
26067}
26068_ACEOF
05ea2a05
TT
26069if ac_fn_c_try_compile "$LINENO"; then :
26070 bfd_cv_have_sys_procfs_type_lwpid_t=yes
c906108c 26071else
05ea2a05
TT
26072 bfd_cv_have_sys_procfs_type_lwpid_t=no
26073
c906108c 26074fi
05ea2a05 26075rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
97bf5e38 26076fi
81ecdfbb 26077
05ea2a05 26078 if test $bfd_cv_have_sys_procfs_type_lwpid_t = yes; then
a3828db0 26079
05ea2a05 26080$as_echo "#define HAVE_LWPID_T 1" >>confdefs.h
97bf5e38 26081
05ea2a05
TT
26082 fi
26083 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_lwpid_t" >&5
26084$as_echo "$bfd_cv_have_sys_procfs_type_lwpid_t" >&6; }
a3828db0 26085
c8693053
RO
26086
26087 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for psaddr_t in sys/procfs.h" >&5
05ea2a05
TT
26088$as_echo_n "checking for psaddr_t in sys/procfs.h... " >&6; }
26089 if ${bfd_cv_have_sys_procfs_type_psaddr_t+:} false; then :
81ecdfbb 26090 $as_echo_n "(cached) " >&6
97bf5e38 26091else
81ecdfbb 26092 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 26093/* end confdefs.h. */
a3828db0 26094
05ea2a05 26095#define _SYSCALL32
05ea2a05 26096#include <sys/procfs.h>
bec39cab
AC
26097int
26098main ()
26099{
05ea2a05 26100psaddr_t avar
bec39cab
AC
26101 ;
26102 return 0;
26103}
26104_ACEOF
81ecdfbb 26105if ac_fn_c_try_compile "$LINENO"; then :
05ea2a05 26106 bfd_cv_have_sys_procfs_type_psaddr_t=yes
c906108c 26107else
05ea2a05
TT
26108 bfd_cv_have_sys_procfs_type_psaddr_t=no
26109
c906108c 26110fi
81ecdfbb 26111rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
c906108c 26112fi
c3f6f71d 26113
05ea2a05 26114 if test $bfd_cv_have_sys_procfs_type_psaddr_t = yes; then
c906108c 26115
05ea2a05 26116$as_echo "#define HAVE_PSADDR_T 1" >>confdefs.h
db1ff28b 26117
05ea2a05
TT
26118 fi
26119 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_psaddr_t" >&5
26120$as_echo "$bfd_cv_have_sys_procfs_type_psaddr_t" >&6; }
26121
c8693053
RO
26122
26123 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for elf_fpregset_t in sys/procfs.h" >&5
05ea2a05
TT
26124$as_echo_n "checking for elf_fpregset_t in sys/procfs.h... " >&6; }
26125 if ${bfd_cv_have_sys_procfs_type_elf_fpregset_t+:} false; then :
db1ff28b
JK
26126 $as_echo_n "(cached) " >&6
26127else
26128 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26129/* end confdefs.h. */
05ea2a05
TT
26130
26131#define _SYSCALL32
05ea2a05 26132#include <sys/procfs.h>
db1ff28b
JK
26133int
26134main ()
26135{
05ea2a05 26136elf_fpregset_t avar
db1ff28b
JK
26137 ;
26138 return 0;
26139}
26140_ACEOF
26141if ac_fn_c_try_compile "$LINENO"; then :
05ea2a05 26142 bfd_cv_have_sys_procfs_type_elf_fpregset_t=yes
db1ff28b 26143else
05ea2a05
TT
26144 bfd_cv_have_sys_procfs_type_elf_fpregset_t=no
26145
db1ff28b
JK
26146fi
26147rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26148fi
db1ff28b 26149
05ea2a05 26150 if test $bfd_cv_have_sys_procfs_type_elf_fpregset_t = yes; then
db1ff28b 26151
05ea2a05 26152$as_echo "#define HAVE_ELF_FPREGSET_T 1" >>confdefs.h
db1ff28b 26153
05ea2a05
TT
26154 fi
26155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_elf_fpregset_t" >&5
26156$as_echo "$bfd_cv_have_sys_procfs_type_elf_fpregset_t" >&6; }
db1ff28b 26157
05ea2a05
TT
26158 fi
26159
8b35ed1f 26160 # Check for xxhash
05ea2a05 26161
8b35ed1f
SM
26162# Check whether --with-xxhash was given.
26163if test "${with_xxhash+set}" = set; then :
26164 withval=$with_xxhash;
27ca5dad 26165else
8b35ed1f 26166 with_xxhash=auto
27ca5dad 26167fi
b6fb30ed 26168
3862412b 26169
8b35ed1f 26170 if test "x$with_xxhash" != "xno"; then
b6fb30ed 26171
5164c117 26172
5164c117 26173
b6fb30ed 26174
b6fb30ed 26175
5164c117 26176
6fea9e18
L
26177
26178
8b35ed1f 26179 use_additional=yes
b6fb30ed 26180
8b35ed1f
SM
26181 acl_save_prefix="$prefix"
26182 prefix="$acl_final_prefix"
26183 acl_save_exec_prefix="$exec_prefix"
26184 exec_prefix="$acl_final_exec_prefix"
b6fb30ed 26185
8b35ed1f
SM
26186 eval additional_includedir=\"$includedir\"
26187 eval additional_libdir=\"$libdir\"
6fea9e18 26188
8b35ed1f
SM
26189 exec_prefix="$acl_save_exec_prefix"
26190 prefix="$acl_save_prefix"
6fea9e18
L
26191
26192
8b35ed1f
SM
26193# Check whether --with-libxxhash-prefix was given.
26194if test "${with_libxxhash_prefix+set}" = set; then :
26195 withval=$with_libxxhash_prefix;
26196 if test "X$withval" = "Xno"; then
26197 use_additional=no
26198 else
26199 if test "X$withval" = "X"; then
451928c5 26200
8b35ed1f
SM
26201 acl_save_prefix="$prefix"
26202 prefix="$acl_final_prefix"
26203 acl_save_exec_prefix="$exec_prefix"
26204 exec_prefix="$acl_final_exec_prefix"
60ca704f 26205
8b35ed1f
SM
26206 eval additional_includedir=\"$includedir\"
26207 eval additional_libdir=\"$libdir\"
05ea2a05 26208
8b35ed1f
SM
26209 exec_prefix="$acl_save_exec_prefix"
26210 prefix="$acl_save_prefix"
05ea2a05 26211
8b35ed1f
SM
26212 else
26213 additional_includedir="$withval/include"
26214 additional_libdir="$withval/lib"
26215 fi
26216 fi
451928c5 26217
97bf5e38 26218fi
451928c5 26219
05ea2a05 26220
8b35ed1f
SM
26221# Check whether --with-libxxhash-type was given.
26222if test "${with_libxxhash_type+set}" = set; then :
26223 withval=$with_libxxhash_type; with_libxxhash_type=$withval
451928c5 26224else
8b35ed1f 26225 with_libxxhash_type=auto
05ea2a05 26226fi
60ca704f 26227
8b35ed1f 26228 lib_type=`eval echo \$with_libxxhash_type`
451928c5 26229
8b35ed1f
SM
26230 LIBXXHASH=
26231 LTLIBXXHASH=
26232 INCXXHASH=
26233 rpathdirs=
26234 ltrpathdirs=
26235 names_already_handled=
26236 names_next_round='xxhash '
26237 while test -n "$names_next_round"; do
26238 names_this_round="$names_next_round"
26239 names_next_round=
26240 for name in $names_this_round; do
26241 already_handled=
26242 for n in $names_already_handled; do
26243 if test "$n" = "$name"; then
26244 already_handled=yes
26245 break
26246 fi
26247 done
26248 if test -z "$already_handled"; then
26249 names_already_handled="$names_already_handled $name"
26250 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
26251 eval value=\"\$HAVE_LIB$uppername\"
26252 if test -n "$value"; then
26253 if test "$value" = yes; then
26254 eval value=\"\$LIB$uppername\"
26255 test -z "$value" || LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$value"
26256 eval value=\"\$LTLIB$uppername\"
26257 test -z "$value" || LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }$value"
26258 else
26259 :
26260 fi
26261 else
26262 found_dir=
26263 found_la=
26264 found_so=
26265 found_a=
26266 if test $use_additional = yes; then
26267 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
26268 found_dir="$additional_libdir"
26269 found_so="$additional_libdir/lib$name.$shlibext"
26270 if test -f "$additional_libdir/lib$name.la"; then
26271 found_la="$additional_libdir/lib$name.la"
26272 fi
26273 elif test x$lib_type != xshared; then
26274 if test -f "$additional_libdir/lib$name.$libext"; then
26275 found_dir="$additional_libdir"
26276 found_a="$additional_libdir/lib$name.$libext"
26277 if test -f "$additional_libdir/lib$name.la"; then
26278 found_la="$additional_libdir/lib$name.la"
26279 fi
26280 fi
26281 fi
26282 fi
26283 if test "X$found_dir" = "X"; then
26284 for x in $LDFLAGS $LTLIBXXHASH; do
5593a99a 26285
8b35ed1f
SM
26286 acl_save_prefix="$prefix"
26287 prefix="$acl_final_prefix"
26288 acl_save_exec_prefix="$exec_prefix"
26289 exec_prefix="$acl_final_exec_prefix"
26290 eval x=\"$x\"
26291 exec_prefix="$acl_save_exec_prefix"
26292 prefix="$acl_save_prefix"
d45fe813 26293
8b35ed1f
SM
26294 case "$x" in
26295 -L*)
26296 dir=`echo "X$x" | sed -e 's/^X-L//'`
26297 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
26298 found_dir="$dir"
26299 found_so="$dir/lib$name.$shlibext"
26300 if test -f "$dir/lib$name.la"; then
26301 found_la="$dir/lib$name.la"
26302 fi
26303 elif test x$lib_type != xshared; then
26304 if test -f "$dir/lib$name.$libext"; then
26305 found_dir="$dir"
26306 found_a="$dir/lib$name.$libext"
26307 if test -f "$dir/lib$name.la"; then
26308 found_la="$dir/lib$name.la"
26309 fi
26310 fi
26311 fi
26312 ;;
26313 esac
26314 if test "X$found_dir" != "X"; then
26315 break
26316 fi
26317 done
26318 fi
26319 if test "X$found_dir" != "X"; then
26320 LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }-L$found_dir -l$name"
26321 if test "X$found_so" != "X"; then
26322 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
26323 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$found_so"
26324 else
26325 haveit=
26326 for x in $ltrpathdirs; do
26327 if test "X$x" = "X$found_dir"; then
26328 haveit=yes
26329 break
26330 fi
26331 done
26332 if test -z "$haveit"; then
26333 ltrpathdirs="$ltrpathdirs $found_dir"
26334 fi
26335 if test "$hardcode_direct" = yes; then
26336 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$found_so"
26337 else
26338 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
26339 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$found_so"
26340 haveit=
26341 for x in $rpathdirs; do
26342 if test "X$x" = "X$found_dir"; then
26343 haveit=yes
26344 break
26345 fi
26346 done
26347 if test -z "$haveit"; then
26348 rpathdirs="$rpathdirs $found_dir"
26349 fi
26350 else
26351 haveit=
26352 for x in $LDFLAGS $LIBXXHASH; do
bec39cab 26353
8b35ed1f
SM
26354 acl_save_prefix="$prefix"
26355 prefix="$acl_final_prefix"
26356 acl_save_exec_prefix="$exec_prefix"
26357 exec_prefix="$acl_final_exec_prefix"
26358 eval x=\"$x\"
26359 exec_prefix="$acl_save_exec_prefix"
26360 prefix="$acl_save_prefix"
d45fe813 26361
8b35ed1f
SM
26362 if test "X$x" = "X-L$found_dir"; then
26363 haveit=yes
26364 break
26365 fi
26366 done
26367 if test -z "$haveit"; then
26368 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }-L$found_dir"
26369 fi
26370 if test "$hardcode_minus_L" != no; then
26371 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$found_so"
26372 else
26373 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }-l$name"
26374 fi
26375 fi
26376 fi
26377 fi
26378 else
26379 if test "X$found_a" != "X"; then
26380 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$found_a"
26381 else
26382 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }-L$found_dir -l$name"
26383 fi
26384 fi
26385 additional_includedir=
26386 case "$found_dir" in
26387 */lib | */lib/)
26388 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
26389 additional_includedir="$basedir/include"
26390 ;;
26391 esac
26392 if test "X$additional_includedir" != "X"; then
26393 if test "X$additional_includedir" != "X/usr/include"; then
26394 haveit=
26395 if test "X$additional_includedir" = "X/usr/local/include"; then
26396 if test -n "$GCC"; then
26397 case $host_os in
26398 linux*) haveit=yes;;
26399 esac
26400 fi
26401 fi
26402 if test -z "$haveit"; then
26403 for x in $CPPFLAGS $INCXXHASH; do
c906108c 26404
8b35ed1f
SM
26405 acl_save_prefix="$prefix"
26406 prefix="$acl_final_prefix"
26407 acl_save_exec_prefix="$exec_prefix"
26408 exec_prefix="$acl_final_exec_prefix"
26409 eval x=\"$x\"
26410 exec_prefix="$acl_save_exec_prefix"
26411 prefix="$acl_save_prefix"
43b7e92b 26412
8b35ed1f
SM
26413 if test "X$x" = "X-I$additional_includedir"; then
26414 haveit=yes
26415 break
26416 fi
26417 done
26418 if test -z "$haveit"; then
26419 if test -d "$additional_includedir"; then
26420 INCXXHASH="${INCXXHASH}${INCXXHASH:+ }-I$additional_includedir"
26421 fi
26422 fi
26423 fi
26424 fi
26425 fi
26426 if test -n "$found_la"; then
26427 save_libdir="$libdir"
26428 case "$found_la" in
26429 */* | *\\*) . "$found_la" ;;
26430 *) . "./$found_la" ;;
26431 esac
26432 libdir="$save_libdir"
26433 for dep in $dependency_libs; do
26434 case "$dep" in
26435 -L*)
26436 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
26437 if test "X$additional_libdir" != "X/usr/lib"; then
26438 haveit=
26439 if test "X$additional_libdir" = "X/usr/local/lib"; then
26440 if test -n "$GCC"; then
26441 case $host_os in
26442 linux*) haveit=yes;;
26443 esac
26444 fi
26445 fi
26446 if test -z "$haveit"; then
26447 haveit=
26448 for x in $LDFLAGS $LIBXXHASH; do
43b7e92b 26449
8b35ed1f
SM
26450 acl_save_prefix="$prefix"
26451 prefix="$acl_final_prefix"
26452 acl_save_exec_prefix="$exec_prefix"
26453 exec_prefix="$acl_final_exec_prefix"
26454 eval x=\"$x\"
26455 exec_prefix="$acl_save_exec_prefix"
26456 prefix="$acl_save_prefix"
05ea2a05 26457
8b35ed1f
SM
26458 if test "X$x" = "X-L$additional_libdir"; then
26459 haveit=yes
26460 break
26461 fi
26462 done
26463 if test -z "$haveit"; then
26464 if test -d "$additional_libdir"; then
26465 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }-L$additional_libdir"
26466 fi
26467 fi
26468 haveit=
26469 for x in $LDFLAGS $LTLIBXXHASH; do
43b7e92b 26470
8b35ed1f
SM
26471 acl_save_prefix="$prefix"
26472 prefix="$acl_final_prefix"
26473 acl_save_exec_prefix="$exec_prefix"
26474 exec_prefix="$acl_final_exec_prefix"
26475 eval x=\"$x\"
26476 exec_prefix="$acl_save_exec_prefix"
26477 prefix="$acl_save_prefix"
43b7e92b 26478
8b35ed1f
SM
26479 if test "X$x" = "X-L$additional_libdir"; then
26480 haveit=yes
26481 break
26482 fi
26483 done
26484 if test -z "$haveit"; then
26485 if test -d "$additional_libdir"; then
26486 LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }-L$additional_libdir"
26487 fi
26488 fi
26489 fi
26490 fi
26491 ;;
26492 -R*)
26493 dir=`echo "X$dep" | sed -e 's/^X-R//'`
26494 if test "$enable_rpath" != no; then
26495 haveit=
26496 for x in $rpathdirs; do
26497 if test "X$x" = "X$dir"; then
26498 haveit=yes
26499 break
26500 fi
26501 done
26502 if test -z "$haveit"; then
26503 rpathdirs="$rpathdirs $dir"
26504 fi
26505 haveit=
26506 for x in $ltrpathdirs; do
26507 if test "X$x" = "X$dir"; then
26508 haveit=yes
26509 break
26510 fi
26511 done
26512 if test -z "$haveit"; then
26513 ltrpathdirs="$ltrpathdirs $dir"
26514 fi
26515 fi
26516 ;;
26517 -l*)
26518 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
26519 ;;
26520 *.la)
26521 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
26522 ;;
26523 *)
26524 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$dep"
26525 LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }$dep"
26526 ;;
26527 esac
26528 done
26529 fi
26530 else
26531 if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
26532 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }-l$name"
26533 LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }-l$name"
26534 else
26535 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }-l:lib$name.$libext"
26536 LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }-l:lib$name.$libext"
26537 fi
26538 fi
26539 fi
26540 fi
26541 done
26542 done
26543 if test "X$rpathdirs" != "X"; then
26544 if test -n "$hardcode_libdir_separator"; then
26545 alldirs=
26546 for found_dir in $rpathdirs; do
26547 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
26548 done
26549 acl_save_libdir="$libdir"
26550 libdir="$alldirs"
26551 eval flag=\"$hardcode_libdir_flag_spec\"
26552 libdir="$acl_save_libdir"
26553 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$flag"
26554 else
26555 for found_dir in $rpathdirs; do
26556 acl_save_libdir="$libdir"
26557 libdir="$found_dir"
26558 eval flag=\"$hardcode_libdir_flag_spec\"
26559 libdir="$acl_save_libdir"
26560 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$flag"
26561 done
26562 fi
26563 fi
26564 if test "X$ltrpathdirs" != "X"; then
26565 for found_dir in $ltrpathdirs; do
26566 LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }-R$found_dir"
26567 done
26568 fi
05ea2a05 26569
43b7e92b 26570
8b35ed1f 26571 ac_save_CPPFLAGS="$CPPFLAGS"
43b7e92b 26572
8b35ed1f
SM
26573 for element in $INCXXHASH; do
26574 haveit=
26575 for x in $CPPFLAGS; do
26576
26577 acl_save_prefix="$prefix"
26578 prefix="$acl_final_prefix"
26579 acl_save_exec_prefix="$exec_prefix"
26580 exec_prefix="$acl_final_exec_prefix"
26581 eval x=\"$x\"
26582 exec_prefix="$acl_save_exec_prefix"
26583 prefix="$acl_save_prefix"
c906108c 26584
8b35ed1f
SM
26585 if test "X$x" = "X$element"; then
26586 haveit=yes
26587 break
26588 fi
26589 done
26590 if test -z "$haveit"; then
26591 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
26592 fi
26593 done
05ea2a05 26594
c906108c 26595
8b35ed1f
SM
26596 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libxxhash" >&5
26597$as_echo_n "checking for libxxhash... " >&6; }
26598if ${ac_cv_libxxhash+:} false; then :
81ecdfbb 26599 $as_echo_n "(cached) " >&6
97bf5e38 26600else
8b35ed1f
SM
26601
26602 ac_save_LIBS="$LIBS"
26603 LIBS="$LIBS $LIBXXHASH"
26604 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 26605/* end confdefs.h. */
8b35ed1f 26606#include <xxhash.h>
bec39cab
AC
26607int
26608main ()
26609{
8b35ed1f
SM
26610XXH32("foo", 3, 0);
26611
bec39cab
AC
26612 ;
26613 return 0;
26614}
26615_ACEOF
8b35ed1f
SM
26616if ac_fn_c_try_link "$LINENO"; then :
26617 ac_cv_libxxhash=yes
97bf5e38 26618else
8b35ed1f 26619 ac_cv_libxxhash=no
97bf5e38 26620fi
8b35ed1f
SM
26621rm -f core conftest.err conftest.$ac_objext \
26622 conftest$ac_exeext conftest.$ac_ext
26623 LIBS="$ac_save_LIBS"
26624
97bf5e38 26625fi
8b35ed1f
SM
26626{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libxxhash" >&5
26627$as_echo "$ac_cv_libxxhash" >&6; }
26628 if test "$ac_cv_libxxhash" = yes; then
26629 HAVE_LIBXXHASH=yes
97bf5e38 26630
8b35ed1f 26631$as_echo "#define HAVE_LIBXXHASH 1" >>confdefs.h
1a619819 26632
8b35ed1f
SM
26633 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libxxhash" >&5
26634$as_echo_n "checking how to link with libxxhash... " >&6; }
26635 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBXXHASH" >&5
26636$as_echo "$LIBXXHASH" >&6; }
26637 else
26638 HAVE_LIBXXHASH=no
26639 CPPFLAGS="$ac_save_CPPFLAGS"
26640 LIBXXHASH=
26641 LTLIBXXHASH=
26642 fi
81ecdfbb 26643
1a619819 26644
1a619819 26645
1a619819 26646
97bf5e38 26647
c906108c 26648
8b35ed1f
SM
26649 if test "$HAVE_LIBXXHASH" != yes; then
26650 if test "$with_xxhash" = yes; then
26651 as_fn_error $? "xxhash is missing or unusable" "$LINENO" 5
26652 fi
26653 fi
26654 if test "x$with_xxhash" = "xauto"; then
26655 with_xxhash="$HAVE_LIBXXHASH"
26656 fi
26657 fi
97bf5e38 26658
8b35ed1f
SM
26659 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use xxhash" >&5
26660$as_echo_n "checking whether to use xxhash... " >&6; }
26661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_xxhash" >&5
26662$as_echo "$with_xxhash" >&6; }
97bf5e38
MK
26663
26664
8b35ed1f
SM
26665# Check the return and argument types of ptrace.
26666
26667
26668for ac_header in sys/ptrace.h ptrace.h
26669do :
26670 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
26671ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
26672if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
26673 cat >>confdefs.h <<_ACEOF
26674#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
bec39cab 26675_ACEOF
81ecdfbb 26676
c906108c 26677fi
bc8bcb4b 26678
8b35ed1f 26679done
97bf5e38 26680
97bf5e38 26681
8b35ed1f
SM
26682gdb_ptrace_headers='
26683#include <sys/types.h>
26684#if HAVE_SYS_PTRACE_H
26685# include <sys/ptrace.h>
26686#endif
26687#if HAVE_UNISTD_H
26688# include <unistd.h>
26689#endif
26690'
97bf5e38 26691
8b35ed1f
SM
26692# Check return type. Varargs (used on GNU/Linux) conflict with the
26693# empty argument list, so check for that explicitly.
26694{ $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of ptrace" >&5
26695$as_echo_n "checking return type of ptrace... " >&6; }
26696if ${gdb_cv_func_ptrace_ret+:} false; then :
81ecdfbb 26697 $as_echo_n "(cached) " >&6
97bf5e38 26698else
81ecdfbb 26699 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 26700/* end confdefs.h. */
8b35ed1f 26701 $gdb_ptrace_headers
bc8bcb4b
MK
26702int
26703main ()
26704{
8b35ed1f
SM
26705extern long ptrace (enum __ptrace_request, ...);
26706
bc8bcb4b
MK
26707 ;
26708 return 0;
97bf5e38 26709}
bec39cab 26710_ACEOF
8b35ed1f
SM
26711if ac_fn_c_try_compile "$LINENO"; then :
26712 gdb_cv_func_ptrace_ret='long'
438013df 26713else
8b35ed1f 26714 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 26715/* end confdefs.h. */
8b35ed1f 26716$gdb_ptrace_headers
bec39cab
AC
26717int
26718main ()
26719{
8b35ed1f
SM
26720extern int ptrace ();
26721
bec39cab
AC
26722 ;
26723 return 0;
26724}
26725_ACEOF
8b35ed1f
SM
26726if ac_fn_c_try_compile "$LINENO"; then :
26727 gdb_cv_func_ptrace_ret='int'
81ecdfbb 26728else
8b35ed1f 26729 gdb_cv_func_ptrace_ret='long'
5593a99a 26730
438013df 26731fi
8b35ed1f 26732rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
438013df 26733
bec39cab 26734fi
8b35ed1f
SM
26735rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26736
26737fi
26738{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_func_ptrace_ret" >&5
26739$as_echo "$gdb_cv_func_ptrace_ret" >&6; }
26740
26741
26742cat >>confdefs.h <<_ACEOF
26743#define PTRACE_TYPE_RET $gdb_cv_func_ptrace_ret
26744_ACEOF
438013df 26745
f6528abd 26746
8b35ed1f
SM
26747# Check argument types.
26748{ $as_echo "$as_me:${as_lineno-$LINENO}: checking types of arguments for ptrace" >&5
26749$as_echo_n "checking types of arguments for ptrace... " >&6; }
26750if ${gdb_cv_func_ptrace_args+:} false; then :
26751 $as_echo_n "(cached) " >&6
26752else
26753 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26754/* end confdefs.h. */
26755$gdb_ptrace_headers
f6528abd
JK
26756int
26757main ()
26758{
8b35ed1f 26759extern long ptrace (enum __ptrace_request, ...);
f6528abd
JK
26760
26761 ;
26762 return 0;
26763}
26764_ACEOF
8b35ed1f
SM
26765if ac_fn_c_try_compile "$LINENO"; then :
26766 gdb_cv_func_ptrace_args='enum __ptrace_request,int,long,long'
f6528abd 26767else
8b35ed1f
SM
26768 for gdb_arg1 in 'int' 'long'; do
26769 for gdb_arg2 in 'pid_t' 'int' 'long'; do
26770 for gdb_arg3 in 'int *' 'caddr_t' 'int' 'long' 'void *'; do
26771 for gdb_arg4 in 'int' 'long' 'void *'; do
26772 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3bebe2f2 26773/* end confdefs.h. */
8b35ed1f 26774$gdb_ptrace_headers
3bebe2f2
JK
26775int
26776main ()
26777{
8b35ed1f
SM
26778extern $gdb_cv_func_ptrace_ret ptrace ($gdb_arg1, $gdb_arg2, $gdb_arg3, $gdb_arg4);
26779
3bebe2f2
JK
26780 ;
26781 return 0;
26782}
26783_ACEOF
8b35ed1f
SM
26784if ac_fn_c_try_compile "$LINENO"; then :
26785 gdb_cv_func_ptrace_args="$gdb_arg1,$gdb_arg2,$gdb_arg3,$gdb_arg4";
26786 break 4;
3bebe2f2 26787
f6528abd 26788fi
8b35ed1f 26789rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
f6528abd 26790
8b35ed1f
SM
26791 for gdb_arg5 in 'int *' 'int' 'long'; do
26792 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6aa4f97c 26793/* end confdefs.h. */
8b35ed1f 26794$gdb_ptrace_headers
6aa4f97c
AB
26795int
26796main ()
26797{
8b35ed1f 26798extern $gdb_cv_func_ptrace_ret ptrace ($gdb_arg1, $gdb_arg2, $gdb_arg3, $gdb_arg4, $gdb_arg5);
6aa4f97c
AB
26799
26800 ;
26801 return 0;
26802}
26803_ACEOF
8b35ed1f
SM
26804if ac_fn_c_try_compile "$LINENO"; then :
26805 gdb_cv_func_ptrace_args="$gdb_arg1,$gdb_arg2,$gdb_arg3,$gdb_arg4,$gdb_arg5";
26806 break 5;
26807
6aa4f97c 26808fi
8b35ed1f
SM
26809rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26810 done
26811 done
26812 done
26813 done
26814 done
26815 # Provide a safe default value.
26816 : ${gdb_cv_func_ptrace_args='int,int,long,long'}
26817
6aa4f97c 26818fi
8b35ed1f 26819rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6aa4f97c 26820
8b35ed1f
SM
26821fi
26822{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_func_ptrace_args" >&5
26823$as_echo "$gdb_cv_func_ptrace_args" >&6; }
26824
26825ac_save_IFS=$IFS; IFS=','
26826set dummy `echo "$gdb_cv_func_ptrace_args" | sed 's/\*/\*/g'`
26827IFS=$ac_save_IFS
26828shift
26829
26830cat >>confdefs.h <<_ACEOF
26831#define PTRACE_TYPE_ARG1 $1
26832_ACEOF
26833
26834
26835cat >>confdefs.h <<_ACEOF
26836#define PTRACE_TYPE_ARG3 $3
26837_ACEOF
26838
26839
26840cat >>confdefs.h <<_ACEOF
26841#define PTRACE_TYPE_ARG4 $4
26842_ACEOF
26843
26844if test -n "$5"; then
26845
26846cat >>confdefs.h <<_ACEOF
26847#define PTRACE_TYPE_ARG5 $5
26848_ACEOF
6aa4f97c
AB
26849
26850fi
26851
f6528abd 26852
8b35ed1f
SM
26853if test "$cross_compiling" = no; then
26854 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether setpgrp takes no argument" >&5
26855$as_echo_n "checking whether setpgrp takes no argument... " >&6; }
26856if ${ac_cv_func_setpgrp_void+:} false; then :
81ecdfbb 26857 $as_echo_n "(cached) " >&6
8b35ed1f
SM
26858else
26859 if test "$cross_compiling" = yes; then :
26860 as_fn_error $? "cannot check setpgrp when cross compiling" "$LINENO" 5
bec39cab 26861else
81ecdfbb 26862 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 26863/* end confdefs.h. */
8b35ed1f 26864$ac_includes_default
bec39cab
AC
26865int
26866main ()
26867{
8b35ed1f
SM
26868/* If this system has a BSD-style setpgrp which takes arguments,
26869 setpgrp(1, 1) will fail with ESRCH and return -1, in that case
26870 exit successfully. */
26871 return setpgrp (1,1) != -1;
bec39cab
AC
26872 ;
26873 return 0;
26874}
26875_ACEOF
8b35ed1f
SM
26876if ac_fn_c_try_run "$LINENO"; then :
26877 ac_cv_func_setpgrp_void=no
d92419e5 26878else
8b35ed1f 26879 ac_cv_func_setpgrp_void=yes
d92419e5 26880fi
8b35ed1f
SM
26881rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
26882 conftest.$ac_objext conftest.beam conftest.$ac_ext
d92419e5
JB
26883fi
26884
d645e32e 26885fi
8b35ed1f
SM
26886{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_setpgrp_void" >&5
26887$as_echo "$ac_cv_func_setpgrp_void" >&6; }
26888if test $ac_cv_func_setpgrp_void = yes; then
d645e32e 26889
8b35ed1f 26890$as_echo "#define SETPGRP_VOID 1" >>confdefs.h
bec39cab 26891
c906108c 26892fi
8b35ed1f
SM
26893
26894else
26895 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether setpgrp takes no argument" >&5
26896$as_echo_n "checking whether setpgrp takes no argument... " >&6; }
26897if ${ac_cv_func_setpgrp_void+:} false; then :
81ecdfbb 26898 $as_echo_n "(cached) " >&6
bec39cab 26899else
81ecdfbb 26900 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 26901/* end confdefs.h. */
8b35ed1f 26902#include <unistd.h>
bec39cab
AC
26903int
26904main ()
26905{
8b35ed1f
SM
26906if (setpgrp(1,1) == -1)
26907 exit (0);
26908 else
26909 exit (1);
5593a99a 26910
bec39cab
AC
26911 ;
26912 return 0;
26913}
26914_ACEOF
81ecdfbb 26915if ac_fn_c_try_compile "$LINENO"; then :
8b35ed1f 26916 ac_cv_func_setpgrp_void=no
3f47be5c 26917else
8b35ed1f 26918 ac_cv_func_setpgrp_void=yes
bec39cab 26919
3f47be5c 26920fi
81ecdfbb 26921rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3f47be5c 26922
bec39cab 26923fi
8b35ed1f
SM
26924{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_setpgrp_void" >&5
26925$as_echo "$ac_cv_func_setpgrp_void" >&6; }
26926if test "$ac_cv_func_setpgrp_void" = yes; then
26927 $as_echo "#define SETPGRP_VOID 1" >>confdefs.h
5593a99a 26928
8b35ed1f
SM
26929fi
26930fi
26931
26932# Check if <sys/proc.h> defines `struct thread' with a td_pcb member.
26933ac_fn_c_check_member "$LINENO" "struct thread" "td_pcb" "ac_cv_member_struct_thread_td_pcb" "#include <sys/param.h>
26934#include <sys/proc.h>
26935
26936"
26937if test "x$ac_cv_member_struct_thread_td_pcb" = xyes; then :
26938
26939cat >>confdefs.h <<_ACEOF
26940#define HAVE_STRUCT_THREAD_TD_PCB 1
26941_ACEOF
26942
26943
26944fi
26945
26946
26947# See if <sys/lwp.h> defines `struct lwp`.
26948{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct lwp" >&5
26949$as_echo_n "checking for struct lwp... " >&6; }
26950if ${gdb_cv_struct_lwp+:} false; then :
81ecdfbb 26951 $as_echo_n "(cached) " >&6
59f80f10 26952else
81ecdfbb 26953 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
59f80f10 26954/* end confdefs.h. */
8b35ed1f
SM
26955#include <sys/param.h>
26956 #define _KMEMUSER
26957 #include <sys/lwp.h>
59f80f10
DJ
26958int
26959main ()
26960{
8b35ed1f 26961struct lwp l;
5593a99a 26962
59f80f10
DJ
26963 ;
26964 return 0;
26965}
26966_ACEOF
81ecdfbb 26967if ac_fn_c_try_compile "$LINENO"; then :
8b35ed1f 26968 gdb_cv_struct_lwp=yes
59f80f10 26969else
8b35ed1f 26970 gdb_cv_struct_lwp=no
59f80f10
DJ
26971
26972fi
81ecdfbb 26973rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
59f80f10
DJ
26974
26975fi
8b35ed1f
SM
26976{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_struct_lwp" >&5
26977$as_echo "$gdb_cv_struct_lwp" >&6; }
26978if test "$gdb_cv_struct_lwp" = yes; then
5593a99a 26979
8b35ed1f
SM
26980$as_echo "#define HAVE_STRUCT_LWP 1" >>confdefs.h
26981
26982fi
26983
26984# See if <machine/reg.h> degines `struct reg'.
26985{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct reg in machine/reg.h" >&5
26986$as_echo_n "checking for struct reg in machine/reg.h... " >&6; }
26987if ${gdb_cv_struct_reg+:} false; then :
81ecdfbb 26988 $as_echo_n "(cached) " >&6
59f80f10 26989else
81ecdfbb 26990 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
59f80f10 26991/* end confdefs.h. */
8b35ed1f
SM
26992#include <sys/types.h>
26993 #include <machine/reg.h>
59f80f10
DJ
26994int
26995main ()
26996{
8b35ed1f 26997struct reg r;
5593a99a 26998
59f80f10
DJ
26999 ;
27000 return 0;
27001}
27002_ACEOF
81ecdfbb 27003if ac_fn_c_try_compile "$LINENO"; then :
8b35ed1f 27004 gdb_cv_struct_reg=yes
59f80f10 27005else
8b35ed1f 27006 gdb_cv_struct_reg=no
59f80f10
DJ
27007
27008fi
81ecdfbb 27009rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
59f80f10
DJ
27010
27011fi
8b35ed1f
SM
27012{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_struct_reg" >&5
27013$as_echo "$gdb_cv_struct_reg" >&6; }
27014if test "$gdb_cv_struct_reg" = yes; then
59f80f10 27015
8b35ed1f 27016$as_echo "#define HAVE_STRUCT_REG 1" >>confdefs.h
59f80f10 27017
3f47be5c
EZ
27018fi
27019
8b35ed1f
SM
27020# See if <machine/reg.h> supports the %fs and %gs i386 segment registers.
27021# Older i386 BSD's don't have the r_fs and r_gs members of `struct reg'.
27022ac_fn_c_check_member "$LINENO" "struct reg" "r_fs" "ac_cv_member_struct_reg_r_fs" "#include <sys/types.h>
27023#include <machine/reg.h>
27024"
27025if test "x$ac_cv_member_struct_reg_r_fs" = xyes; then :
fb40c209 27026
92e4e97a 27027cat >>confdefs.h <<_ACEOF
8b35ed1f 27028#define HAVE_STRUCT_REG_R_FS 1
92e4e97a
AB
27029_ACEOF
27030
27031
f83d8a90 27032fi
8b35ed1f
SM
27033ac_fn_c_check_member "$LINENO" "struct reg" "r_gs" "ac_cv_member_struct_reg_r_gs" "#include <sys/types.h>
27034#include <machine/reg.h>
27035"
27036if test "x$ac_cv_member_struct_reg_r_gs" = xyes; then :
030292b7 27037
f83d8a90 27038cat >>confdefs.h <<_ACEOF
8b35ed1f 27039#define HAVE_STRUCT_REG_R_GS 1
f83d8a90 27040_ACEOF
bec39cab 27041
030292b7 27042
8b35ed1f 27043fi
b14b1491 27044
f83d8a90 27045
8b35ed1f
SM
27046# See if <sys/ptrace.h> provides the PTRACE_GETREGS request.
27047{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTRACE_GETREGS" >&5
27048$as_echo_n "checking for PTRACE_GETREGS... " >&6; }
27049if ${gdb_cv_have_ptrace_getregs+:} false; then :
27050 $as_echo_n "(cached) " >&6
27051else
27052 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27053/* end confdefs.h. */
27054#include <sys/ptrace.h>
27055int
27056main ()
27057{
27058PTRACE_GETREGS;
27059 ;
27060 return 0;
27061}
f83d8a90 27062_ACEOF
8b35ed1f
SM
27063if ac_fn_c_try_compile "$LINENO"; then :
27064 gdb_cv_have_ptrace_getregs=yes
27065else
27066 gdb_cv_have_ptrace_getregs=no
030292b7 27067
8b35ed1f
SM
27068fi
27069rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
030292b7 27070
8b35ed1f 27071fi
030292b7 27072
8b35ed1f
SM
27073{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_ptrace_getregs" >&5
27074$as_echo "$gdb_cv_have_ptrace_getregs" >&6; }
27075if test "$gdb_cv_have_ptrace_getregs" = yes; then
16e7150e 27076
8b35ed1f 27077$as_echo "#define HAVE_PTRACE_GETREGS 1" >>confdefs.h
16e7150e 27078
81ecdfbb
RW
27079fi
27080
8b35ed1f
SM
27081# See if <sys/ptrace.h> provides the PTRACE_GETFPXREGS request.
27082{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTRACE_GETFPXREGS" >&5
27083$as_echo_n "checking for PTRACE_GETFPXREGS... " >&6; }
27084if ${gdb_cv_have_ptrace_getfpxregs+:} false; then :
27085 $as_echo_n "(cached) " >&6
27086else
27087 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27088/* end confdefs.h. */
27089#include <sys/ptrace.h>
27090int
27091main ()
27092{
27093PTRACE_GETFPXREGS;
27094 ;
27095 return 0;
27096}
27097_ACEOF
27098if ac_fn_c_try_compile "$LINENO"; then :
27099 gdb_cv_have_ptrace_getfpxregs=yes
27100else
27101 gdb_cv_have_ptrace_getfpxregs=no
16e7150e 27102
8b35ed1f
SM
27103fi
27104rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16e7150e 27105
8b35ed1f 27106fi
16e7150e 27107
8b35ed1f
SM
27108{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_ptrace_getfpxregs" >&5
27109$as_echo "$gdb_cv_have_ptrace_getfpxregs" >&6; }
27110if test "$gdb_cv_have_ptrace_getfpxregs" = yes; then
16e7150e 27111
8b35ed1f 27112$as_echo "#define HAVE_PTRACE_GETFPXREGS 1" >>confdefs.h
16e7150e 27113
8b35ed1f 27114fi
0c4a4063 27115
8b35ed1f
SM
27116# See if <sys/ptrace.h> provides the PT_GETDBREGS request.
27117{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for PT_GETDBREGS" >&5
27118$as_echo_n "checking for PT_GETDBREGS... " >&6; }
27119if ${gdb_cv_have_pt_getdbregs+:} false; then :
27120 $as_echo_n "(cached) " >&6
27121else
27122 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27123/* end confdefs.h. */
27124#include <sys/types.h>
27125 #include <sys/ptrace.h>
27126int
27127main ()
27128{
27129PT_GETDBREGS;
16e7150e 27130
8b35ed1f
SM
27131 ;
27132 return 0;
27133}
16e7150e 27134_ACEOF
8b35ed1f
SM
27135if ac_fn_c_try_compile "$LINENO"; then :
27136 gdb_cv_have_pt_getdbregs=yes
27137else
27138 gdb_cv_have_pt_getdbregs=no
16e7150e 27139
8b35ed1f
SM
27140fi
27141rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
b14b1491 27142
8b35ed1f 27143fi
16e7150e 27144
8b35ed1f
SM
27145{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_pt_getdbregs" >&5
27146$as_echo "$gdb_cv_have_pt_getdbregs" >&6; }
27147if test "$gdb_cv_have_pt_getdbregs" = yes; then
0c4a4063 27148
8b35ed1f 27149$as_echo "#define HAVE_PT_GETDBREGS 1" >>confdefs.h
b835bb52 27150
ed2a2229
CB
27151fi
27152
8b35ed1f
SM
27153# See if <sys/ptrace.h> supports LWP names on FreeBSD
27154# Older FreeBSD versions don't have the pl_tdname member of
27155# `struct ptrace_lwpinfo'.
27156ac_fn_c_check_member "$LINENO" "struct ptrace_lwpinfo" "pl_tdname" "ac_cv_member_struct_ptrace_lwpinfo_pl_tdname" "#include <sys/ptrace.h>
27157"
27158if test "x$ac_cv_member_struct_ptrace_lwpinfo_pl_tdname" = xyes; then :
ed2a2229
CB
27159
27160cat >>confdefs.h <<_ACEOF
8b35ed1f 27161#define HAVE_STRUCT_PTRACE_LWPINFO_PL_TDNAME 1
ed2a2229
CB
27162_ACEOF
27163
27164
8b35ed1f 27165fi
ed2a2229
CB
27166
27167
8b35ed1f
SM
27168# See if <sys/ptrace.h> supports syscall fields on FreeBSD. The
27169# pl_syscall_code member of `struct ptrace_lwpinfo' was added in
27170# FreeBSD 10.3.
27171ac_fn_c_check_member "$LINENO" "struct ptrace_lwpinfo" "pl_syscall_code" "ac_cv_member_struct_ptrace_lwpinfo_pl_syscall_code" "#include <sys/ptrace.h>
27172"
27173if test "x$ac_cv_member_struct_ptrace_lwpinfo_pl_syscall_code" = xyes; then :
ed2a2229
CB
27174
27175cat >>confdefs.h <<_ACEOF
8b35ed1f 27176#define HAVE_STRUCT_PTRACE_LWPINFO_PL_SYSCALL_CODE 1
ed2a2229
CB
27177_ACEOF
27178
27179
8b35ed1f 27180fi
ed2a2229
CB
27181
27182
8b35ed1f 27183# Check if the compiler supports the `long long' type.
ed2a2229 27184
8b35ed1f
SM
27185{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long support in compiler" >&5
27186$as_echo_n "checking for long long support in compiler... " >&6; }
27187if ${gdb_cv_c_long_long+:} false; then :
4b74833d
AB
27188 $as_echo_n "(cached) " >&6
27189else
8b35ed1f 27190 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4b74833d 27191/* end confdefs.h. */
8b35ed1f 27192extern long long foo;
4b74833d
AB
27193int
27194main ()
27195{
8b35ed1f 27196switch (foo & 2) { case 0: return 1; }
4b74833d
AB
27197 ;
27198 return 0;
27199}
27200_ACEOF
27201if ac_fn_c_try_compile "$LINENO"; then :
8b35ed1f
SM
27202 gdb_cv_c_long_long=yes
27203else
27204 gdb_cv_c_long_long=no
4b74833d
AB
27205fi
27206rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8b35ed1f
SM
27207fi
27208{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_c_long_long" >&5
27209$as_echo "$gdb_cv_c_long_long" >&6; }
27210if test "$gdb_cv_c_long_long" != yes; then
27211 # libdecnumber requires long long.
27212 as_fn_error $? "Compiler must support long long for GDB." "$LINENO" 5
27213fi
4b74833d 27214
8b35ed1f 27215# Check if the compiler and runtime support printing decfloats.
4b74833d 27216
8b35ed1f
SM
27217{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for decfloat support in printf" >&5
27218$as_echo_n "checking for decfloat support in printf... " >&6; }
27219if ${gdb_cv_printf_has_decfloat+:} false; then :
27220 $as_echo_n "(cached) " >&6
27221else
27222 if test "$cross_compiling" = yes; then :
27223 gdb_cv_printf_has_decfloat=no
27224else
27225 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27226/* end confdefs.h. */
27227$ac_includes_default
4b74833d
AB
27228int
27229main ()
27230{
8b35ed1f
SM
27231char buf[64];
27232 _Decimal32 d32 = 1.2345df;
27233 _Decimal64 d64 = 1.2345dd;
27234 _Decimal128 d128 = 1.2345dl;
27235 sprintf (buf, "Decimal32: %H\nDecimal64: %D\nDecimal128: %DD", d32, d64, d128);
27236 return (strcmp ("Decimal32: 1.2345\nDecimal64: 1.2345\nDecimal128: 1.2345", buf));
4b74833d
AB
27237 ;
27238 return 0;
27239}
27240_ACEOF
8b35ed1f
SM
27241if ac_fn_c_try_run "$LINENO"; then :
27242 gdb_cv_printf_has_decfloat=yes
27243else
27244 gdb_cv_printf_has_decfloat=no
4b74833d 27245fi
8b35ed1f
SM
27246rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27247 conftest.$ac_objext conftest.beam conftest.$ac_ext
4b74833d 27248fi
4b74833d 27249
8b35ed1f
SM
27250fi
27251{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_printf_has_decfloat" >&5
27252$as_echo "$gdb_cv_printf_has_decfloat" >&6; }
27253if test "$gdb_cv_printf_has_decfloat" = yes; then
4b74833d 27254
8b35ed1f 27255$as_echo "#define PRINTF_HAS_DECFLOAT 1" >>confdefs.h
4b74833d 27256
81ecdfbb
RW
27257fi
27258
8b35ed1f
SM
27259# Check if the compiler supports the `long double' type. We can't use
27260# AC_C_LONG_DOUBLE because that one does additional checks on the
27261# constants defined in <float.h> that fail on some systems,
27262# e.g. FreeBSD/i386 4.7 and OpenBSD/i386 3.6.
094a342e 27263
8b35ed1f
SM
27264{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double support in compiler" >&5
27265$as_echo_n "checking for long double support in compiler... " >&6; }
27266if ${gdb_cv_c_long_double+:} false; then :
27267 $as_echo_n "(cached) " >&6
27268else
27269 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27270/* end confdefs.h. */
27271long double foo;
27272_ACEOF
27273if ac_fn_c_try_compile "$LINENO"; then :
27274 gdb_cv_c_long_double=yes
27275else
27276 gdb_cv_c_long_double=no
094a342e 27277fi
8b35ed1f 27278rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
094a342e 27279fi
8b35ed1f
SM
27280{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_c_long_double" >&5
27281$as_echo "$gdb_cv_c_long_double" >&6; }
27282if test "$gdb_cv_c_long_double" = yes; then
094a342e 27283
8b35ed1f 27284$as_echo "#define HAVE_LONG_DOUBLE 1" >>confdefs.h
3bc3d82a 27285
4b74833d
AB
27286fi
27287
8b35ed1f 27288# Check if the compiler and runtime support printing long doubles.
3526781e 27289
8b35ed1f
SM
27290{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double support in printf" >&5
27291$as_echo_n "checking for long double support in printf... " >&6; }
27292if ${gdb_cv_printf_has_long_double+:} false; then :
27293 $as_echo_n "(cached) " >&6
27294else
27295 if test "$cross_compiling" = yes; then :
27296 gdb_cv_printf_has_long_double=no
27297else
27298 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27299/* end confdefs.h. */
27300$ac_includes_default
27301int
27302main ()
27303{
27304char buf[16];
27305 long double f = 3.141592653;
27306 sprintf (buf, "%Lg", f);
27307 return (strncmp ("3.14159", buf, 7));
27308 ;
27309 return 0;
27310}
27311_ACEOF
27312if ac_fn_c_try_run "$LINENO"; then :
27313 gdb_cv_printf_has_long_double=yes
27314else
27315 gdb_cv_printf_has_long_double=no
81ecdfbb 27316fi
8b35ed1f
SM
27317rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27318 conftest.$ac_objext conftest.beam conftest.$ac_ext
3b851bce 27319fi
8b35ed1f 27320
81ecdfbb 27321fi
8b35ed1f
SM
27322{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_printf_has_long_double" >&5
27323$as_echo "$gdb_cv_printf_has_long_double" >&6; }
27324if test "$gdb_cv_printf_has_long_double" = yes; then
3bc3d82a 27325
8b35ed1f 27326$as_echo "#define PRINTF_HAS_LONG_DOUBLE 1" >>confdefs.h
3bc3d82a 27327
8b35ed1f 27328fi
3bc3d82a 27329
8b35ed1f 27330# Check if the compiler and runtime support scanning long doubles.
7544db95 27331
8b35ed1f
SM
27332{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double support in scanf" >&5
27333$as_echo_n "checking for long double support in scanf... " >&6; }
27334if ${gdb_cv_scanf_has_long_double+:} false; then :
27335 $as_echo_n "(cached) " >&6
27336else
27337 if test "$cross_compiling" = yes; then :
27338 gdb_cv_scanf_has_long_double=no
27339else
27340 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
a0de763e 27341/* end confdefs.h. */
8b35ed1f 27342#include <stdio.h>
a0de763e
TT
27343int
27344main ()
27345{
8b35ed1f
SM
27346char *buf = "3.141592653";
27347 long double f = 0;
27348 sscanf (buf, "%Lg", &f);
27349 return !(f > 3.14159 && f < 3.14160);
a0de763e
TT
27350 ;
27351 return 0;
27352}
27353_ACEOF
8b35ed1f
SM
27354if ac_fn_c_try_run "$LINENO"; then :
27355 gdb_cv_scanf_has_long_double=yes
27356else
27357 gdb_cv_scanf_has_long_double=no
a0de763e 27358fi
8b35ed1f
SM
27359rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27360 conftest.$ac_objext conftest.beam conftest.$ac_ext
27361fi
27362
27363fi
27364{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_scanf_has_long_double" >&5
27365$as_echo "$gdb_cv_scanf_has_long_double" >&6; }
27366if test "$gdb_cv_scanf_has_long_double" = yes; then
27367
27368$as_echo "#define SCANF_HAS_LONG_DOUBLE 1" >>confdefs.h
27369
27370fi
27371
27372case ${host_os} in
27373aix*)
27374 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -bbigtoc option" >&5
27375$as_echo_n "checking for -bbigtoc option... " >&6; }
27376if ${gdb_cv_bigtoc+:} false; then :
27377 $as_echo_n "(cached) " >&6
27378else
27379 SAVE_LDFLAGS=$LDFLAGS
27380
27381 case $GCC in
27382 yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
27383 *) gdb_cv_bigtoc=-bbigtoc ;;
27384 esac
27385
27386 LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
27387 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 27388/* end confdefs.h. */
4536bbc6 27389
bec39cab
AC
27390int
27391main ()
27392{
8b35ed1f 27393int i;
bec39cab
AC
27394 ;
27395 return 0;
27396}
27397_ACEOF
8b35ed1f 27398if ac_fn_c_try_link "$LINENO"; then :
c906108c 27399
8b35ed1f
SM
27400else
27401 gdb_cv_bigtoc=
c906108c 27402
8b35ed1f
SM
27403fi
27404rm -f core conftest.err conftest.$ac_objext \
27405 conftest$ac_exeext conftest.$ac_ext
27406 LDFLAGS="${SAVE_LDFLAGS}"
104c1213 27407
8b35ed1f
SM
27408fi
27409{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_bigtoc" >&5
27410$as_echo "$gdb_cv_bigtoc" >&6; }
27411 CONFIG_LDFLAGS="${CONFIG_LDFLAGS} ${gdb_cv_bigtoc}"
27412 ;;
27413esac
3bc3d82a 27414
8b35ed1f
SM
27415{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for the dynamic export flag" >&5
27416$as_echo_n "checking for the dynamic export flag... " >&6; }
27417dynamic_list=false
27418if test "${gdb_native}" = yes; then
27419 # The dynamically loaded libthread_db needs access to symbols in the gdb
27420 # executable. Older GNU ld supports --export-dynamic but --dynamic-list
27421 # may not be supported there.
27422 old_LDFLAGS="$LDFLAGS"
27423 # Older GNU ld supports --export-dynamic but --dynamic-list it does not.
27424 RDYNAMIC="-Wl,--dynamic-list=${srcdir}/proc-service.list"
27425 LDFLAGS="$LDFLAGS $RDYNAMIC"
27426 if test "${have_libpython}" = no; then
27427 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27428/* end confdefs.h. */
3bc3d82a 27429
8b35ed1f
SM
27430int
27431main ()
27432{
b835bb52 27433
8b35ed1f
SM
27434 ;
27435 return 0;
27436}
27437_ACEOF
27438if ac_fn_c_try_link "$LINENO"; then :
27439 dynamic_list=true
27440fi
27441rm -f core conftest.err conftest.$ac_objext \
27442 conftest$ac_exeext conftest.$ac_ext
27443 else
27444 # Workaround http://bugs.python.org/issue4434 where static
27445 # libpythonX.Y.a would get its symbols required for
27446 # pythonX.Y/lib-dynload/*.so modules hidden by -Wl,--dynamic-list.
27447 # Problem does not happen for the recommended libpythonX.Y.so linkage.
27448
27449 # Note the workaround for Python
27450 # http://bugs.python.org/issue10112 earlier has removed
27451 # -export-dynamic from PYTHON_LIBS. That's exactly what we want
27452 # here too, as otherwise it'd make this -Wl,--dynamic-list test
27453 # always pass.
27454 old_CFLAGS="$CFLAGS"
27455 CFLAGS="$CFLAGS $PYTHON_CFLAGS"
27456 old_LIBS="$LIBS"
27457 LIBS="$LIBS $PYTHON_LIBS"
27458 old_CPPFLAGS="$CPPFLAGS"
27459 CPPFLAGS="$CPPFLAGS $PYTHON_CPPFLAGS"
27460 if test "$cross_compiling" = yes; then :
27461 true
f35d5ade 27462else
8b35ed1f
SM
27463 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27464/* end confdefs.h. */
27465#include "Python.h"
27466int
27467main ()
27468{
27469int err;
27470 Py_Initialize ();
27471 err = PyRun_SimpleString ("import ctypes\n");
27472 Py_Finalize ();
27473 return err == 0 ? 0 : 1;
27474 ;
27475 return 0;
27476}
27477_ACEOF
27478if ac_fn_c_try_run "$LINENO"; then :
27479 dynamic_list=true
27480fi
27481rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27482 conftest.$ac_objext conftest.beam conftest.$ac_ext
f35d5ade
TT
27483fi
27484
8b35ed1f
SM
27485 LIBS="$old_LIBS"
27486 CFLAGS="$old_CFLAGS"
27487 CPPFLAGS="$old_CPPFLAGS"
27488 fi
27489 LDFLAGS="$old_LDFLAGS"
f35d5ade 27490fi
8b35ed1f
SM
27491if $dynamic_list; then
27492 found="-Wl,--dynamic-list"
27493 RDYNAMIC='-Wl,--dynamic-list=$(srcdir)/proc-service.list'
27494else
27495 found="-rdynamic"
27496 RDYNAMIC="-rdynamic"
27497fi
27498
27499{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $found" >&5
27500$as_echo "$found" >&6; }
f35d5ade 27501
8b35ed1f
SM
27502{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether execinfo.h backtrace is available" >&5
27503$as_echo_n "checking whether execinfo.h backtrace is available... " >&6; }
27504if ${gdb_cv_execinfo_backtrace+:} false; then :
27505 $as_echo_n "(cached) " >&6
27506else
27507 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
f35d5ade
TT
27508/* end confdefs.h. */
27509
8b35ed1f
SM
27510 #include <execinfo.h>
27511
f35d5ade
TT
27512int
27513main ()
27514{
27515
8b35ed1f
SM
27516 int f;
27517 void *b[2];
27518 f = backtrace (b, 2);
27519 backtrace_symbols_fd (b, f, 2);
27520
f35d5ade
TT
27521 ;
27522 return 0;
27523}
27524_ACEOF
8b35ed1f
SM
27525if ac_fn_c_try_link "$LINENO"; then :
27526 gdb_cv_execinfo_backtrace=yes
f35d5ade 27527else
8b35ed1f 27528 gdb_cv_execinfo_backtrace=no
f35d5ade
TT
27529fi
27530rm -f core conftest.err conftest.$ac_objext \
27531 conftest$ac_exeext conftest.$ac_ext
f35d5ade 27532fi
8b35ed1f
SM
27533{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_execinfo_backtrace" >&5
27534$as_echo "$gdb_cv_execinfo_backtrace" >&6; }
27535if test "$gdb_cv_execinfo_backtrace" = yes; then
f35d5ade 27536
8b35ed1f 27537$as_echo "#define HAVE_EXECINFO_BACKTRACE 1" >>confdefs.h
f35d5ade 27538
8b35ed1f 27539fi
f35d5ade 27540
8b35ed1f
SM
27541
27542if test "${build}" = "${host}" -a "${host}" = "${target}" ; then
27543 case ${host_os} in
27544 aix*)
27545 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AiX thread debugging library" >&5
27546$as_echo_n "checking for AiX thread debugging library... " >&6; }
27547 if ${gdb_cv_have_aix_thread_debug+:} false; then :
81ecdfbb 27548 $as_echo_n "(cached) " >&6
bec39cab 27549else
81ecdfbb 27550 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
bec39cab 27551/* end confdefs.h. */
8b35ed1f
SM
27552#include <sys/pthdebug.h>
27553int
27554main ()
27555{
27556#ifndef PTHDB_VERSION_3
27557 #error
27558 #endif
7a292a7a 27559
8b35ed1f
SM
27560 ;
27561 return 0;
27562}
bec39cab 27563_ACEOF
8b35ed1f
SM
27564if ac_fn_c_try_compile "$LINENO"; then :
27565 gdb_cv_have_aix_thread_debug=yes
7a292a7a 27566else
8b35ed1f 27567 gdb_cv_have_aix_thread_debug=no
7a292a7a
SS
27568
27569fi
8b35ed1f 27570rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
aff38e61 27571
8b35ed1f 27572fi
aff38e61 27573
8b35ed1f
SM
27574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_aix_thread_debug" >&5
27575$as_echo "$gdb_cv_have_aix_thread_debug" >&6; }
27576 if test "$gdb_cv_have_aix_thread_debug" = yes; then
27577 CONFIG_SRCS="${CONFIG_SRCS} aix-thread.c"
27578 CONFIG_OBS="${CONFIG_OBS} aix-thread.o"
27579 LIBS="$LIBS -lpthdebug"
aff38e61 27580
8b35ed1f
SM
27581 # Older versions of AIX do not provide the declaration for
27582 # the getthrds function (it appears that it was introduced
27583 # with AIX 6.x).
27584 ac_fn_c_check_decl "$LINENO" "getthrds" "ac_cv_have_decl_getthrds" "#include <procinfo.h>
27585"
27586if test "x$ac_cv_have_decl_getthrds" = xyes; then :
27587 ac_have_decl=1
27588else
27589 ac_have_decl=0
cd0fc7c3 27590fi
c906108c 27591
8b35ed1f
SM
27592cat >>confdefs.h <<_ACEOF
27593#define HAVE_DECL_GETTHRDS $ac_have_decl
27594_ACEOF
7a292a7a 27595
8b35ed1f
SM
27596 fi
27597 ;;
27598 esac
def63ff0 27599
8b35ed1f
SM
27600fi
27601
27602if test "x$ac_cv_header_thread_db_h" = "xyes"; then
27603 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <thread_db.h> has TD_NOTALLOC" >&5
27604$as_echo_n "checking whether <thread_db.h> has TD_NOTALLOC... " >&6; }
27605if ${gdb_cv_thread_db_h_has_td_notalloc+:} false; then :
81ecdfbb 27606 $as_echo_n "(cached) " >&6
31d99776 27607else
81ecdfbb 27608 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31d99776 27609/* end confdefs.h. */
8b35ed1f 27610#include <thread_db.h>
31d99776
DJ
27611int
27612main ()
27613{
8b35ed1f 27614int i = TD_NOTALLOC;
294f2697 27615
31d99776
DJ
27616 ;
27617 return 0;
27618}
27619_ACEOF
8b35ed1f
SM
27620if ac_fn_c_try_compile "$LINENO"; then :
27621 gdb_cv_thread_db_h_has_td_notalloc=yes
31d99776 27622else
8b35ed1f 27623 gdb_cv_thread_db_h_has_td_notalloc=no
294f2697 27624
31d99776 27625fi
8b35ed1f 27626rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
294f2697 27627
31d99776 27628fi
8b35ed1f
SM
27629{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_thread_db_h_has_td_notalloc" >&5
27630$as_echo "$gdb_cv_thread_db_h_has_td_notalloc" >&6; }
31d99776 27631
8b35ed1f
SM
27632 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <thread_db.h> has TD_VERSION" >&5
27633$as_echo_n "checking whether <thread_db.h> has TD_VERSION... " >&6; }
27634if ${gdb_cv_thread_db_h_has_td_version+:} false; then :
a48b32c0
L
27635 $as_echo_n "(cached) " >&6
27636else
8b35ed1f 27637 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
a48b32c0 27638/* end confdefs.h. */
8b35ed1f 27639#include <thread_db.h>
a48b32c0
L
27640int
27641main ()
27642{
8b35ed1f
SM
27643int i = TD_VERSION;
27644
a48b32c0
L
27645 ;
27646 return 0;
27647}
27648_ACEOF
8b35ed1f
SM
27649if ac_fn_c_try_compile "$LINENO"; then :
27650 gdb_cv_thread_db_h_has_td_version=yes
a48b32c0 27651else
8b35ed1f 27652 gdb_cv_thread_db_h_has_td_version=no
a48b32c0
L
27653
27654fi
8b35ed1f 27655rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
a48b32c0 27656
31d99776 27657fi
8b35ed1f
SM
27658{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_thread_db_h_has_td_version" >&5
27659$as_echo "$gdb_cv_thread_db_h_has_td_version" >&6; }
31d99776 27660
8b35ed1f
SM
27661 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <thread_db.h> has TD_NOTLS" >&5
27662$as_echo_n "checking whether <thread_db.h> has TD_NOTLS... " >&6; }
27663if ${gdb_cv_thread_db_h_has_td_notls+:} false; then :
4f05add4 27664 $as_echo_n "(cached) " >&6
8b35ed1f
SM
27665else
27666 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27667/* end confdefs.h. */
27668#include <thread_db.h>
4f05add4
TT
27669int
27670main ()
27671{
8b35ed1f 27672int i = TD_NOTLS;
294f2697 27673
4f05add4
TT
27674 ;
27675 return 0;
27676}
27677_ACEOF
8b35ed1f
SM
27678if ac_fn_c_try_compile "$LINENO"; then :
27679 gdb_cv_thread_db_h_has_td_notls=yes
4f05add4 27680else
8b35ed1f 27681 gdb_cv_thread_db_h_has_td_notls=no
294f2697 27682
4f05add4 27683fi
8b35ed1f 27684rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
294f2697 27685
4f05add4 27686fi
8b35ed1f
SM
27687{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_thread_db_h_has_td_notls" >&5
27688$as_echo "$gdb_cv_thread_db_h_has_td_notls" >&6; }
4f05add4 27689fi
8b35ed1f 27690if test "x$gdb_cv_thread_db_h_has_td_notalloc" = "xyes"; then
4f05add4 27691
8b35ed1f 27692$as_echo "#define THREAD_DB_HAS_TD_NOTALLOC 1" >>confdefs.h
608e2dbb 27693
608e2dbb 27694fi
8b35ed1f 27695if test "x$gdb_cv_thread_db_h_has_td_version" = "xyes"; then
608e2dbb 27696
8b35ed1f 27697$as_echo "#define THREAD_DB_HAS_TD_VERSION 1" >>confdefs.h
608e2dbb 27698
8b35ed1f
SM
27699fi
27700if test "x$gdb_cv_thread_db_h_has_td_notls" = "xyes"; then
608e2dbb 27701
8b35ed1f 27702$as_echo "#define THREAD_DB_HAS_TD_NOTLS 1" >>confdefs.h
608e2dbb 27703
8b35ed1f 27704fi
608e2dbb 27705
8b35ed1f
SM
27706case $host_os in
27707 go32* | *djgpp*)
27708 gdbinit=gdb.ini
27709 ;;
27710 *)
27711 gdbinit=.gdbinit
27712 ;;
27713esac
608e2dbb 27714
8b35ed1f
SM
27715cat >>confdefs.h <<_ACEOF
27716#define GDBINIT "$gdbinit"
27717_ACEOF
608e2dbb 27718
608e2dbb 27719
608e2dbb 27720
8b35ed1f
SM
27721cat >>confdefs.h <<_ACEOF
27722#define GDBEARLYINIT ".gdbearlyinit"
27723_ACEOF
608e2dbb 27724
608e2dbb 27725
608e2dbb 27726
8b35ed1f
SM
27727# Support for --with-sysroot is a copy of GDB_AC_WITH_DIR,
27728# except that the argument to --with-sysroot is optional.
27729# --with-sysroot (or --with-sysroot=yes) sets the default sysroot path.
27730if test "x$with_sysroot" = xyes; then
27731 with_sysroot="${exec_prefix}/${target_alias}/sys-root"
608e2dbb
TT
27732fi
27733
8b35ed1f
SM
27734# Check whether --with-sysroot was given.
27735if test "${with_sysroot+set}" = set; then :
27736 withval=$with_sysroot; TARGET_SYSTEM_ROOT=$withval
9f1528a1 27737else
8b35ed1f 27738 TARGET_SYSTEM_ROOT=
9f1528a1
AB
27739fi
27740
9f1528a1 27741
8b35ed1f
SM
27742 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
27743 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
27744 ac_define_dir=`eval echo $TARGET_SYSTEM_ROOT`
27745 ac_define_dir=`eval echo $ac_define_dir`
608e2dbb 27746
8b35ed1f
SM
27747cat >>confdefs.h <<_ACEOF
27748#define TARGET_SYSTEM_ROOT "$ac_define_dir"
27749_ACEOF
608e2dbb 27750
608e2dbb 27751
608e2dbb 27752
608e2dbb 27753
8b35ed1f
SM
27754 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
27755 if test "x$prefix" = xNONE; then
27756 test_prefix=/usr/local
27757 else
27758 test_prefix=$prefix
27759 fi
27760 else
27761 test_prefix=$exec_prefix
27762 fi
27763 value=0
27764 case ${ac_define_dir} in
27765 "${test_prefix}"|"${test_prefix}/"*|\
27766 '${exec_prefix}'|'${exec_prefix}/'*)
27767 value=1
27768 ;;
27769 esac
27770
27771cat >>confdefs.h <<_ACEOF
27772#define TARGET_SYSTEM_ROOT_RELOCATABLE $value
27773_ACEOF
27774
27775
608e2dbb 27776
608e2dbb 27777
608e2dbb 27778
8b35ed1f
SM
27779# Check whether --with-system-gdbinit was given.
27780if test "${with_system_gdbinit+set}" = set; then :
27781 withval=$with_system_gdbinit;
27782 SYSTEM_GDBINIT=$withval
27783else
27784 SYSTEM_GDBINIT=
27785fi
608e2dbb 27786
608e2dbb 27787
8b35ed1f
SM
27788 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
27789 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
27790 ac_define_dir=`eval echo $SYSTEM_GDBINIT`
27791 ac_define_dir=`eval echo $ac_define_dir`
27792
27793cat >>confdefs.h <<_ACEOF
27794#define SYSTEM_GDBINIT "$ac_define_dir"
27795_ACEOF
27796
27797
27798
27799
27800 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
27801 if test "x$prefix" = xNONE; then
27802 test_prefix=/usr/local
27803 else
27804 test_prefix=$prefix
27805 fi
27806 else
27807 test_prefix=$exec_prefix
608e2dbb 27808 fi
8b35ed1f
SM
27809 value=0
27810 case ${ac_define_dir} in
27811 "${test_prefix}"|"${test_prefix}/"*|\
27812 '${exec_prefix}'|'${exec_prefix}/'*)
27813 value=1
27814 ;;
27815 esac
27816
27817cat >>confdefs.h <<_ACEOF
27818#define SYSTEM_GDBINIT_RELOCATABLE $value
27819_ACEOF
27820
27821
27822
27823
27824
27825# Check whether --with-system-gdbinit-dir was given.
27826if test "${with_system_gdbinit_dir+set}" = set; then :
27827 withval=$with_system_gdbinit_dir;
27828 SYSTEM_GDBINIT_DIR=$withval
27829else
27830 SYSTEM_GDBINIT_DIR=
27831fi
27832
27833
27834 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
27835 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
27836 ac_define_dir=`eval echo $SYSTEM_GDBINIT_DIR`
27837 ac_define_dir=`eval echo $ac_define_dir`
27838
27839cat >>confdefs.h <<_ACEOF
27840#define SYSTEM_GDBINIT_DIR "$ac_define_dir"
27841_ACEOF
27842
27843
27844
27845
27846 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
27847 if test "x$prefix" = xNONE; then
27848 test_prefix=/usr/local
27849 else
27850 test_prefix=$prefix
27851 fi
27852 else
27853 test_prefix=$exec_prefix
608e2dbb 27854 fi
8b35ed1f
SM
27855 value=0
27856 case ${ac_define_dir} in
27857 "${test_prefix}"|"${test_prefix}/"*|\
27858 '${exec_prefix}'|'${exec_prefix}/'*)
27859 value=1
27860 ;;
27861 esac
608e2dbb 27862
8b35ed1f
SM
27863cat >>confdefs.h <<_ACEOF
27864#define SYSTEM_GDBINIT_DIR_RELOCATABLE $value
27865_ACEOF
608e2dbb 27866
608e2dbb 27867
608e2dbb 27868
608e2dbb 27869
608e2dbb
TT
27870
27871
8b35ed1f
SM
27872 { $as_echo "$as_me:${as_lineno-$LINENO}: checking the compiler type" >&5
27873$as_echo_n "checking the compiler type... " >&6; }
27874if ${gdb_cv_compiler_type+:} false; then :
608e2dbb
TT
27875 $as_echo_n "(cached) " >&6
27876else
8b35ed1f
SM
27877 gdb_cv_compiler_type=unknown
27878 if test "$gdb_cv_compiler_type" = unknown; then
27879 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27880/* end confdefs.h. */
608e2dbb 27881
8b35ed1f
SM
27882int
27883main ()
27884{
27885
27886 #if !defined __GNUC__ || defined __clang__
27887 #error not gcc
27888 #endif
27889
27890 ;
27891 return 0;
27892}
27893_ACEOF
27894if ac_fn_c_try_compile "$LINENO"; then :
27895 gdb_cv_compiler_type=gcc
27896fi
27897rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27898 fi
27899
27900 if test "$gdb_cv_compiler_type" = unknown; then
27901 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27902/* end confdefs.h. */
27903
27904int
27905main ()
27906{
27907
27908 #ifndef __clang__
27909 #error not clang
27910 #endif
27911
27912 ;
27913 return 0;
27914}
27915_ACEOF
27916if ac_fn_c_try_compile "$LINENO"; then :
27917 gdb_cv_compiler_type=clang
27918fi
27919rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27920 fi
27921
27922fi
27923{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_compiler_type" >&5
27924$as_echo "$gdb_cv_compiler_type" >&6; }
27925
27926 GDB_COMPILER_TYPE="$gdb_cv_compiler_type"
27927
27928
27929# Check whether --enable-werror was given.
27930if test "${enable_werror+set}" = set; then :
27931 enableval=$enable_werror; case "${enableval}" in
27932 yes | y) ERROR_ON_WARNING="yes" ;;
27933 no | n) ERROR_ON_WARNING="no" ;;
27934 *) as_fn_error $? "bad value ${enableval} for --enable-werror" "$LINENO" 5 ;;
27935 esac
27936fi
27937
27938
27939# Enable -Werror by default when using gcc. Turn it off for releases.
27940if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" && $development; then
27941 ERROR_ON_WARNING=yes
27942fi
27943
27944WERROR_CFLAGS=""
27945if test "${ERROR_ON_WARNING}" = yes ; then
27946 WERROR_CFLAGS="-Werror"
27947fi
27948
27949# The options we'll try to enable.
27950build_warnings="-Wall -Wpointer-arith \
27951-Wno-unused -Wunused-value -Wunused-variable -Wunused-function \
27952-Wno-switch -Wno-char-subscripts \
27953-Wempty-body -Wunused-but-set-parameter -Wunused-but-set-variable \
27954-Wno-sign-compare -Wno-error=maybe-uninitialized \
27955-Wno-mismatched-tags \
27956-Wno-error=deprecated-register \
27957-Wsuggest-override \
27958-Wimplicit-fallthrough=3 \
27959-Wduplicated-cond \
27960-Wshadow=local \
27961-Wdeprecated-copy \
27962-Wdeprecated-copy-dtor \
27963-Wredundant-move \
27964-Wmissing-declarations \
27965-Wstrict-null-sentinel \
27966"
27967
27968# The -Wmissing-prototypes flag will be accepted by GCC, but results
27969# in a warning being printed about the flag not being valid for C++,
27970# this is something to do with using ccache, and argument ordering.
27971if test "$GDB_COMPILER_TYPE" != gcc; then
27972 build_warnings="$build_warnings -Wmissing-prototypes"
27973fi
27974
27975case "${host}" in
27976 *-*-mingw32*)
27977 # Enable -Wno-format by default when using gcc on mingw since many
27978 # GCC versions complain about %I64.
27979 build_warnings="$build_warnings -Wno-format" ;;
27980 *-*-solaris*)
27981 # Solaris 11.4 <python2.7/ceval.h> uses #pragma no_inline that GCC
27982 # doesn't understand.
27983 build_warnings="$build_warnings -Wno-unknown-pragmas"
27984 # Solaris 11 <unistd.h> marks vfork deprecated.
27985 build_warnings="$build_warnings -Wno-deprecated-declarations" ;;
27986 *)
27987 # Note that gcc requires -Wformat for -Wformat-nonliteral to work,
27988 # but there's a special case for this below.
27989 build_warnings="$build_warnings -Wformat-nonliteral" ;;
27990esac
27991
27992# Check whether --enable-build-warnings was given.
27993if test "${enable_build_warnings+set}" = set; then :
27994 enableval=$enable_build_warnings; case "${enableval}" in
27995 yes) ;;
27996 no) build_warnings="-w";;
27997 ,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
27998 build_warnings="${build_warnings} ${t}";;
27999 *,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
28000 build_warnings="${t} ${build_warnings}";;
28001 *) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
28002esac
28003if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
28004 echo "Setting compiler warning flags = $build_warnings" 6>&1
28005fi
28006fi
28007# Check whether --enable-gdb-build-warnings was given.
28008if test "${enable_gdb_build_warnings+set}" = set; then :
28009 enableval=$enable_gdb_build_warnings; case "${enableval}" in
28010 yes) ;;
28011 no) build_warnings="-w";;
28012 ,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
28013 build_warnings="${build_warnings} ${t}";;
28014 *,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
28015 build_warnings="${t} ${build_warnings}";;
28016 *) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
28017esac
28018if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
28019 echo "Setting GDB specific compiler warning flags = $build_warnings" 6>&1
28020fi
28021fi
28022
28023# The set of warnings supported by a C++ compiler is not the same as
28024# of the C compiler.
28025ac_ext=cpp
28026ac_cpp='$CXXCPP $CPPFLAGS'
28027ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
28028ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
28029ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
28030
28031
28032WARN_CFLAGS=""
28033if test "x${build_warnings}" != x -a "x$GCC" = xyes
28034then
28035 { $as_echo "$as_me:${as_lineno-$LINENO}: checking compiler warning flags" >&5
28036$as_echo_n "checking compiler warning flags... " >&6; }
28037 # Separate out the -Werror flag as some files just cannot be
28038 # compiled with it enabled.
28039 for w in ${build_warnings}; do
28040 # GCC does not complain about -Wno-unknown-warning. Invert
28041 # and test -Wunknown-warning instead.
28042 case $w in
28043 -Wno-*)
28044 wtest=`echo $w | sed 's/-Wno-/-W/g'` ;;
28045 -Wformat-nonliteral)
28046 # gcc requires -Wformat before -Wformat-nonliteral
28047 # will work, so stick them together.
28048 w="-Wformat $w"
28049 wtest="$w"
28050 ;;
28051 *)
28052 wtest=$w ;;
28053 esac
28054
28055 case $w in
28056 -Werr*) WERROR_CFLAGS=-Werror ;;
28057 *)
28058 # Check whether GCC accepts it.
28059 saved_CFLAGS="$CFLAGS"
28060 CFLAGS="$CFLAGS -Werror $wtest"
28061 saved_CXXFLAGS="$CXXFLAGS"
28062 CXXFLAGS="$CXXFLAGS -Werror $wtest"
28063 if test "x$w" = "x-Wunused-variable"; then
28064 # Check for https://gcc.gnu.org/bugzilla/show_bug.cgi?id=38958,
28065 # fixed in GCC 4.9. This test is derived from the gdb
28066 # source code that triggered this bug in GCC.
28067 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
608e2dbb 28068/* end confdefs.h. */
8b35ed1f
SM
28069struct scoped_restore_base {};
28070 struct scoped_restore_tmpl : public scoped_restore_base {
28071 ~scoped_restore_tmpl() {}
28072 };
608e2dbb
TT
28073int
28074main ()
28075{
8b35ed1f
SM
28076const scoped_restore_base &b = scoped_restore_tmpl();
28077
608e2dbb
TT
28078 ;
28079 return 0;
28080}
28081_ACEOF
8b35ed1f
SM
28082if ac_fn_cxx_try_compile "$LINENO"; then :
28083 WARN_CFLAGS="${WARN_CFLAGS} $w"
608e2dbb 28084fi
8b35ed1f
SM
28085rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28086 else
28087 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28088/* end confdefs.h. */
608e2dbb 28089
8b35ed1f
SM
28090int
28091main ()
28092{
608e2dbb 28093
8b35ed1f
SM
28094 ;
28095 return 0;
28096}
28097_ACEOF
28098if ac_fn_cxx_try_compile "$LINENO"; then :
28099 WARN_CFLAGS="${WARN_CFLAGS} $w"
28100fi
28101rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28102 fi
28103 CFLAGS="$saved_CFLAGS"
28104 CXXFLAGS="$saved_CXXFLAGS"
28105 esac
28106 done
28107 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${WARN_CFLAGS} ${WERROR_CFLAGS}" >&5
28108$as_echo "${WARN_CFLAGS} ${WERROR_CFLAGS}" >&6; }
28109fi
608e2dbb 28110
608e2dbb
TT
28111
28112
8b35ed1f
SM
28113ac_ext=c
28114ac_cpp='$CPP $CPPFLAGS'
28115ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
28116ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
28117ac_compiler_gnu=$ac_cv_c_compiler_gnu
608e2dbb
TT
28118
28119
28120
8b35ed1f
SM
28121# Check whether --enable-ubsan was given.
28122if test "${enable_ubsan+set}" = set; then :
28123 enableval=$enable_ubsan;
28124else
28125 enable_ubsan=no
28126fi
608e2dbb 28127
8b35ed1f
SM
28128if test "x$enable_ubsan" = xauto; then
28129 if $development; then
28130 enable_ubsan=yes
608e2dbb
TT
28131 fi
28132fi
8b35ed1f
SM
28133ac_ext=cpp
28134ac_cpp='$CXXCPP $CPPFLAGS'
28135ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
28136ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
28137ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
608e2dbb 28138
8b35ed1f
SM
28139if test "x$enable_ubsan" = xyes; then
28140 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -fsanitize=undefined is accepted" >&5
28141$as_echo_n "checking whether -fsanitize=undefined is accepted... " >&6; }
28142 saved_CXXFLAGS="$CXXFLAGS"
28143 CXXFLAGS="$CXXFLAGS -fsanitize=undefined -fno-sanitize-recover=undefined"
28144 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28145/* end confdefs.h. */
3fc11d3e 28146
8b35ed1f
SM
28147int
28148main ()
28149{
d1c3b63a 28150
8b35ed1f
SM
28151 ;
28152 return 0;
28153}
28154_ACEOF
28155if ac_fn_cxx_try_link "$LINENO"; then :
28156 enable_ubsan=yes
28157else
28158 enable_ubsan=no
bec39cab 28159
8b35ed1f
SM
28160fi
28161rm -f core conftest.err conftest.$ac_objext \
28162 conftest$ac_exeext conftest.$ac_ext
28163 CXXFLAGS="$saved_CXXFLAGS"
28164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_ubsan" >&5
28165$as_echo "$enable_ubsan" >&6; }
28166 if test "x$enable_ubsan" = xyes; then
28167 WARN_CFLAGS="$WARN_CFLAGS -fsanitize=undefined -fno-sanitize-recover=undefined"
28168 CONFIG_LDFLAGS="$CONFIG_LDFLAGS -fsanitize=undefined"
28169 fi
28170fi
28171ac_ext=c
28172ac_cpp='$CPP $CPPFLAGS'
28173ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
28174ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
28175ac_compiler_gnu=$ac_cv_c_compiler_gnu
3fc11d3e 28176
bec39cab 28177
81ecdfbb 28178
8b35ed1f
SM
28179# In the Cygwin environment, we need some additional flags.
28180{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for cygwin" >&5
28181$as_echo_n "checking for cygwin... " >&6; }
28182if ${gdb_cv_os_cygwin+:} false; then :
81ecdfbb 28183 $as_echo_n "(cached) " >&6
3fc11d3e 28184else
8b35ed1f
SM
28185 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28186/* end confdefs.h. */
bec39cab 28187
8b35ed1f
SM
28188#if defined (__CYGWIN__) || defined (__CYGWIN32__)
28189lose
28190#endif
28191_ACEOF
28192if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
28193 $EGREP "^lose$" >/dev/null 2>&1; then :
28194 gdb_cv_os_cygwin=yes
28195else
28196 gdb_cv_os_cygwin=no
28197fi
28198rm -f conftest*
3fc11d3e 28199
8b35ed1f
SM
28200fi
28201{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_os_cygwin" >&5
28202$as_echo "$gdb_cv_os_cygwin" >&6; }
5062cc19 28203
3fc11d3e 28204
8b35ed1f
SM
28205SER_HARDWIRE="ser-base.o ser-unix.o ser-pipe.o ser-tcp.o"
28206case ${host} in
28207 *go32* ) SER_HARDWIRE=ser-go32.o ;;
28208 *djgpp* ) SER_HARDWIRE=ser-go32.o ;;
28209 *mingw32*) SER_HARDWIRE="ser-base.o ser-tcp.o ser-mingw.o" ;;
28210 *) SER_HARDWIRE="$SER_HARDWIRE ser-uds.o" ;;
28211esac
bec39cab 28212
3fc11d3e 28213
8b35ed1f
SM
28214# libreadline needs libuser32.a in a cygwin environment
28215WIN32LIBS=
28216if test x"$gdb_cv_os_cygwin" = xyes; then
28217 WIN32LIBS="-luser32"
28218 case "${target}" in
28219 *cygwin*) WIN32LIBS="$WIN32LIBS -limagehlp"
28220 ;;
28221 esac
28222fi
5062cc19 28223
8b35ed1f
SM
28224# The ser-tcp.c module requires sockets.
28225# Note that WIN32APILIBS is set by GDB_AC_COMMON.
28226WIN32LIBS="$WIN32LIBS $WIN32APILIBS"
3fc11d3e 28227
8b35ed1f 28228# Add ELF support to GDB, but only if BFD includes ELF support.
bec39cab 28229
8b35ed1f
SM
28230 OLD_CFLAGS=$CFLAGS
28231 OLD_LDFLAGS=$LDFLAGS
28232 OLD_LIBS=$LIBS
28233 OLD_CC=$CC
28234 # Put the old CFLAGS/LDFLAGS last, in case the user's (C|LD)FLAGS
28235 # points somewhere with bfd, with -I/foo/lib and -L/foo/lib. We
28236 # always want our bfd.
28237 CFLAGS="-I${srcdir}/../include -I../bfd -I${srcdir}/../bfd $CFLAGS"
28238 LDFLAGS="-L../bfd -L../libiberty"
28239 intl=`echo $LIBINTL | sed 's,${top_builddir}/,,g'`
28240 LIBS="-lbfd -liberty $intl $LIBS"
28241 CC="./libtool --quiet --mode=link $CC"
28242 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ELF support in BFD" >&5
28243$as_echo_n "checking for ELF support in BFD... " >&6; }
28244if ${gdb_cv_var_elf+:} false; then :
28245 $as_echo_n "(cached) " >&6
28246else
28247 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28248/* end confdefs.h. */
28249#include <stdlib.h>
28250 #include <string.h>
28251 #include "bfd.h"
28252 #include "elf-bfd.h"
28253int
28254main ()
28255{
28256return bfd_get_elf_phdr_upper_bound (NULL);
bec39cab 28257
8b35ed1f
SM
28258 ;
28259 return 0;
28260}
28261_ACEOF
28262if ac_fn_c_try_link "$LINENO"; then :
28263 gdb_cv_var_elf=yes
28264else
28265 gdb_cv_var_elf=no
3fc11d3e 28266
8b35ed1f
SM
28267fi
28268rm -f core conftest.err conftest.$ac_objext \
28269 conftest$ac_exeext conftest.$ac_ext
bec39cab 28270
81ecdfbb 28271fi
8b35ed1f
SM
28272{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_var_elf" >&5
28273$as_echo "$gdb_cv_var_elf" >&6; }
28274 CC=$OLD_CC
28275 CFLAGS=$OLD_CFLAGS
28276 LDFLAGS=$OLD_LDFLAGS
28277 LIBS=$OLD_LIBS
28278if test "$gdb_cv_var_elf" = yes; then
28279 CONFIG_OBS="$CONFIG_OBS elfread.o stap-probe.o dtrace-probe.o \
28280 gcore-elf.o elf-none-tdep.o"
81ecdfbb 28281
8b35ed1f
SM
28282$as_echo "#define HAVE_ELF 1" >>confdefs.h
28283
28284 # -ldl is provided by bfd/Makfile.am (LIBDL) <PLUGINS>.
28285 if test "$plugins" = "yes"; then
28286 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlopen" >&5
28287$as_echo_n "checking for library containing dlopen... " >&6; }
28288if ${ac_cv_search_dlopen+:} false; then :
81ecdfbb 28289 $as_echo_n "(cached) " >&6
bec39cab 28290else
8b35ed1f
SM
28291 ac_func_search_save_LIBS=$LIBS
28292cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28293/* end confdefs.h. */
28294
28295/* Override any GCC internal prototype to avoid an error.
28296 Use char because int might match the return type of a GCC
28297 builtin and then its argument prototype would still apply. */
28298#ifdef __cplusplus
28299extern "C"
28300#endif
28301char dlopen ();
28302int
28303main ()
28304{
28305return dlopen ();
28306 ;
28307 return 0;
28308}
28309_ACEOF
28310for ac_lib in '' dl; do
28311 if test -z "$ac_lib"; then
28312 ac_res="none required"
28313 else
28314 ac_res=-l$ac_lib
28315 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
28316 fi
28317 if ac_fn_c_try_link "$LINENO"; then :
28318 ac_cv_search_dlopen=$ac_res
28319fi
28320rm -f core conftest.err conftest.$ac_objext \
28321 conftest$ac_exeext
28322 if ${ac_cv_search_dlopen+:} false; then :
28323 break
28324fi
28325done
28326if ${ac_cv_search_dlopen+:} false; then :
28327
28328else
28329 ac_cv_search_dlopen=no
28330fi
28331rm conftest.$ac_ext
28332LIBS=$ac_func_search_save_LIBS
28333fi
28334{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlopen" >&5
28335$as_echo "$ac_cv_search_dlopen" >&6; }
28336ac_res=$ac_cv_search_dlopen
28337if test "$ac_res" != no; then :
28338 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
3fc11d3e 28339
8b35ed1f 28340fi
3fc11d3e 28341
8b35ed1f
SM
28342 fi
28343fi
3fc11d3e 28344
8b35ed1f 28345# Add macho support to GDB, but only if BFD includes it.
5062cc19 28346
8b35ed1f
SM
28347 OLD_CFLAGS=$CFLAGS
28348 OLD_LDFLAGS=$LDFLAGS
28349 OLD_LIBS=$LIBS
28350 OLD_CC=$CC
28351 # Put the old CFLAGS/LDFLAGS last, in case the user's (C|LD)FLAGS
28352 # points somewhere with bfd, with -I/foo/lib and -L/foo/lib. We
28353 # always want our bfd.
28354 CFLAGS="-I${srcdir}/../include -I../bfd -I${srcdir}/../bfd $CFLAGS"
28355 LDFLAGS="-L../bfd -L../libiberty"
28356 intl=`echo $LIBINTL | sed 's,${top_builddir}/,,g'`
28357 LIBS="-lbfd -liberty $intl $LIBS"
28358 CC="./libtool --quiet --mode=link $CC"
28359 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Mach-O support in BFD" >&5
28360$as_echo_n "checking for Mach-O support in BFD... " >&6; }
28361if ${gdb_cv_var_macho+:} false; then :
28362 $as_echo_n "(cached) " >&6
28363else
28364 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28365/* end confdefs.h. */
28366#include <stdlib.h>
28367 #include <string.h>
28368 #include "bfd.h"
28369 #include "mach-o.h"
28370int
28371main ()
28372{
28373return bfd_mach_o_lookup_command (NULL, 0, NULL);
5062cc19 28374
8b35ed1f
SM
28375 ;
28376 return 0;
28377}
28378_ACEOF
28379if ac_fn_c_try_link "$LINENO"; then :
28380 gdb_cv_var_macho=yes
28381else
28382 gdb_cv_var_macho=no
3fc11d3e 28383
3fc11d3e 28384fi
8b35ed1f
SM
28385rm -f core conftest.err conftest.$ac_objext \
28386 conftest$ac_exeext conftest.$ac_ext
3fc11d3e 28387
8b35ed1f
SM
28388fi
28389{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_var_macho" >&5
28390$as_echo "$gdb_cv_var_macho" >&6; }
28391 CC=$OLD_CC
28392 CFLAGS=$OLD_CFLAGS
28393 LDFLAGS=$OLD_LDFLAGS
28394 LIBS=$OLD_LIBS
28395if test "$gdb_cv_var_macho" = yes; then
28396 CONFIG_OBS="$CONFIG_OBS machoread.o"
28397fi
3fc11d3e 28398
8b35ed1f
SM
28399# Add any host-specific objects to GDB.
28400CONFIG_OBS="${CONFIG_OBS} ${gdb_host_obs}"
dd2504ab 28401
8b35ed1f
SM
28402# If building on ELF, look for lzma support for embedded compressed debug info.
28403if test "$gdb_cv_var_elf" = yes; then
85541719 28404
8b35ed1f
SM
28405# Check whether --with-lzma was given.
28406if test "${with_lzma+set}" = set; then :
28407 withval=$with_lzma;
28408else
28409 with_lzma=auto
28410fi
85541719 28411
8b35ed1f
SM
28412 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use lzma" >&5
28413$as_echo_n "checking whether to use lzma... " >&6; }
28414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_lzma" >&5
28415$as_echo "$with_lzma" >&6; }
85541719 28416
8b35ed1f 28417 if test "${with_lzma}" != no; then
85541719 28418
85541719 28419
85541719
DE
28420
28421
28422
28423
28424
28425
8b35ed1f 28426 use_additional=yes
85541719 28427
8b35ed1f
SM
28428 acl_save_prefix="$prefix"
28429 prefix="$acl_final_prefix"
28430 acl_save_exec_prefix="$exec_prefix"
28431 exec_prefix="$acl_final_exec_prefix"
85541719 28432
8b35ed1f
SM
28433 eval additional_includedir=\"$includedir\"
28434 eval additional_libdir=\"$libdir\"
85541719 28435
8b35ed1f
SM
28436 exec_prefix="$acl_save_exec_prefix"
28437 prefix="$acl_save_prefix"
85541719
DE
28438
28439
8b35ed1f
SM
28440# Check whether --with-liblzma-prefix was given.
28441if test "${with_liblzma_prefix+set}" = set; then :
28442 withval=$with_liblzma_prefix;
28443 if test "X$withval" = "Xno"; then
28444 use_additional=no
28445 else
28446 if test "X$withval" = "X"; then
85541719 28447
8b35ed1f
SM
28448 acl_save_prefix="$prefix"
28449 prefix="$acl_final_prefix"
28450 acl_save_exec_prefix="$exec_prefix"
28451 exec_prefix="$acl_final_exec_prefix"
85541719 28452
8b35ed1f
SM
28453 eval additional_includedir=\"$includedir\"
28454 eval additional_libdir=\"$libdir\"
85541719 28455
8b35ed1f
SM
28456 exec_prefix="$acl_save_exec_prefix"
28457 prefix="$acl_save_prefix"
85541719 28458
8b35ed1f
SM
28459 else
28460 additional_includedir="$withval/include"
28461 additional_libdir="$withval/lib"
28462 fi
28463 fi
85541719 28464
8b35ed1f 28465fi
85541719 28466
85541719 28467
8b35ed1f
SM
28468# Check whether --with-liblzma-type was given.
28469if test "${with_liblzma_type+set}" = set; then :
28470 withval=$with_liblzma_type; with_liblzma_type=$withval
28471else
28472 with_liblzma_type=auto
28473fi
85541719 28474
8b35ed1f 28475 lib_type=`eval echo \$with_liblzma_type`
85541719 28476
8b35ed1f
SM
28477 LIBLZMA=
28478 LTLIBLZMA=
28479 INCLZMA=
28480 rpathdirs=
28481 ltrpathdirs=
28482 names_already_handled=
28483 names_next_round='lzma '
28484 while test -n "$names_next_round"; do
28485 names_this_round="$names_next_round"
28486 names_next_round=
28487 for name in $names_this_round; do
28488 already_handled=
28489 for n in $names_already_handled; do
28490 if test "$n" = "$name"; then
28491 already_handled=yes
28492 break
85541719 28493 fi
8b35ed1f
SM
28494 done
28495 if test -z "$already_handled"; then
28496 names_already_handled="$names_already_handled $name"
28497 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
28498 eval value=\"\$HAVE_LIB$uppername\"
28499 if test -n "$value"; then
28500 if test "$value" = yes; then
28501 eval value=\"\$LIB$uppername\"
28502 test -z "$value" || LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$value"
28503 eval value=\"\$LTLIB$uppername\"
28504 test -z "$value" || LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }$value"
28505 else
28506 :
28507 fi
28508 else
28509 found_dir=
28510 found_la=
28511 found_so=
28512 found_a=
28513 if test $use_additional = yes; then
28514 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
28515 found_dir="$additional_libdir"
28516 found_so="$additional_libdir/lib$name.$shlibext"
28517 if test -f "$additional_libdir/lib$name.la"; then
28518 found_la="$additional_libdir/lib$name.la"
28519 fi
28520 elif test x$lib_type != xshared; then
28521 if test -f "$additional_libdir/lib$name.$libext"; then
28522 found_dir="$additional_libdir"
28523 found_a="$additional_libdir/lib$name.$libext"
28524 if test -f "$additional_libdir/lib$name.la"; then
28525 found_la="$additional_libdir/lib$name.la"
28526 fi
28527 fi
28528 fi
28529 fi
28530 if test "X$found_dir" = "X"; then
28531 for x in $LDFLAGS $LTLIBLZMA; do
28532
28533 acl_save_prefix="$prefix"
28534 prefix="$acl_final_prefix"
28535 acl_save_exec_prefix="$exec_prefix"
28536 exec_prefix="$acl_final_exec_prefix"
28537 eval x=\"$x\"
28538 exec_prefix="$acl_save_exec_prefix"
28539 prefix="$acl_save_prefix"
28540
28541 case "$x" in
28542 -L*)
28543 dir=`echo "X$x" | sed -e 's/^X-L//'`
28544 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
28545 found_dir="$dir"
28546 found_so="$dir/lib$name.$shlibext"
28547 if test -f "$dir/lib$name.la"; then
28548 found_la="$dir/lib$name.la"
28549 fi
28550 elif test x$lib_type != xshared; then
28551 if test -f "$dir/lib$name.$libext"; then
28552 found_dir="$dir"
28553 found_a="$dir/lib$name.$libext"
28554 if test -f "$dir/lib$name.la"; then
28555 found_la="$dir/lib$name.la"
28556 fi
28557 fi
28558 fi
28559 ;;
28560 esac
28561 if test "X$found_dir" != "X"; then
28562 break
28563 fi
28564 done
28565 fi
28566 if test "X$found_dir" != "X"; then
28567 LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }-L$found_dir -l$name"
28568 if test "X$found_so" != "X"; then
28569 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
28570 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$found_so"
28571 else
28572 haveit=
28573 for x in $ltrpathdirs; do
28574 if test "X$x" = "X$found_dir"; then
28575 haveit=yes
28576 break
28577 fi
28578 done
28579 if test -z "$haveit"; then
28580 ltrpathdirs="$ltrpathdirs $found_dir"
28581 fi
28582 if test "$hardcode_direct" = yes; then
28583 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$found_so"
28584 else
28585 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
28586 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$found_so"
28587 haveit=
28588 for x in $rpathdirs; do
28589 if test "X$x" = "X$found_dir"; then
28590 haveit=yes
28591 break
28592 fi
28593 done
28594 if test -z "$haveit"; then
28595 rpathdirs="$rpathdirs $found_dir"
28596 fi
28597 else
28598 haveit=
28599 for x in $LDFLAGS $LIBLZMA; do
85541719 28600
8b35ed1f
SM
28601 acl_save_prefix="$prefix"
28602 prefix="$acl_final_prefix"
28603 acl_save_exec_prefix="$exec_prefix"
28604 exec_prefix="$acl_final_exec_prefix"
28605 eval x=\"$x\"
28606 exec_prefix="$acl_save_exec_prefix"
28607 prefix="$acl_save_prefix"
85541719 28608
8b35ed1f
SM
28609 if test "X$x" = "X-L$found_dir"; then
28610 haveit=yes
28611 break
28612 fi
28613 done
28614 if test -z "$haveit"; then
28615 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }-L$found_dir"
28616 fi
28617 if test "$hardcode_minus_L" != no; then
28618 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$found_so"
28619 else
28620 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }-l$name"
28621 fi
28622 fi
28623 fi
28624 fi
28625 else
28626 if test "X$found_a" != "X"; then
28627 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$found_a"
28628 else
28629 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }-L$found_dir -l$name"
28630 fi
28631 fi
28632 additional_includedir=
28633 case "$found_dir" in
28634 */lib | */lib/)
28635 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
28636 additional_includedir="$basedir/include"
28637 ;;
28638 esac
28639 if test "X$additional_includedir" != "X"; then
28640 if test "X$additional_includedir" != "X/usr/include"; then
28641 haveit=
28642 if test "X$additional_includedir" = "X/usr/local/include"; then
28643 if test -n "$GCC"; then
28644 case $host_os in
28645 linux*) haveit=yes;;
28646 esac
28647 fi
28648 fi
28649 if test -z "$haveit"; then
28650 for x in $CPPFLAGS $INCLZMA; do
85541719 28651
8b35ed1f
SM
28652 acl_save_prefix="$prefix"
28653 prefix="$acl_final_prefix"
28654 acl_save_exec_prefix="$exec_prefix"
28655 exec_prefix="$acl_final_exec_prefix"
28656 eval x=\"$x\"
28657 exec_prefix="$acl_save_exec_prefix"
28658 prefix="$acl_save_prefix"
85541719 28659
8b35ed1f
SM
28660 if test "X$x" = "X-I$additional_includedir"; then
28661 haveit=yes
28662 break
28663 fi
28664 done
28665 if test -z "$haveit"; then
28666 if test -d "$additional_includedir"; then
28667 INCLZMA="${INCLZMA}${INCLZMA:+ }-I$additional_includedir"
28668 fi
28669 fi
28670 fi
28671 fi
28672 fi
28673 if test -n "$found_la"; then
28674 save_libdir="$libdir"
28675 case "$found_la" in
28676 */* | *\\*) . "$found_la" ;;
28677 *) . "./$found_la" ;;
28678 esac
28679 libdir="$save_libdir"
28680 for dep in $dependency_libs; do
28681 case "$dep" in
28682 -L*)
28683 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
28684 if test "X$additional_libdir" != "X/usr/lib"; then
28685 haveit=
28686 if test "X$additional_libdir" = "X/usr/local/lib"; then
28687 if test -n "$GCC"; then
28688 case $host_os in
28689 linux*) haveit=yes;;
28690 esac
28691 fi
28692 fi
28693 if test -z "$haveit"; then
28694 haveit=
28695 for x in $LDFLAGS $LIBLZMA; do
85541719 28696
8b35ed1f
SM
28697 acl_save_prefix="$prefix"
28698 prefix="$acl_final_prefix"
28699 acl_save_exec_prefix="$exec_prefix"
28700 exec_prefix="$acl_final_exec_prefix"
28701 eval x=\"$x\"
28702 exec_prefix="$acl_save_exec_prefix"
28703 prefix="$acl_save_prefix"
dd2504ab 28704
8b35ed1f
SM
28705 if test "X$x" = "X-L$additional_libdir"; then
28706 haveit=yes
28707 break
28708 fi
28709 done
28710 if test -z "$haveit"; then
28711 if test -d "$additional_libdir"; then
28712 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }-L$additional_libdir"
28713 fi
28714 fi
28715 haveit=
28716 for x in $LDFLAGS $LTLIBLZMA; do
bec39cab 28717
8b35ed1f
SM
28718 acl_save_prefix="$prefix"
28719 prefix="$acl_final_prefix"
28720 acl_save_exec_prefix="$exec_prefix"
28721 exec_prefix="$acl_final_exec_prefix"
28722 eval x=\"$x\"
28723 exec_prefix="$acl_save_exec_prefix"
28724 prefix="$acl_save_prefix"
5062cc19 28725
8b35ed1f
SM
28726 if test "X$x" = "X-L$additional_libdir"; then
28727 haveit=yes
28728 break
28729 fi
28730 done
28731 if test -z "$haveit"; then
28732 if test -d "$additional_libdir"; then
28733 LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }-L$additional_libdir"
28734 fi
28735 fi
28736 fi
28737 fi
28738 ;;
28739 -R*)
28740 dir=`echo "X$dep" | sed -e 's/^X-R//'`
28741 if test "$enable_rpath" != no; then
28742 haveit=
28743 for x in $rpathdirs; do
28744 if test "X$x" = "X$dir"; then
28745 haveit=yes
28746 break
28747 fi
28748 done
28749 if test -z "$haveit"; then
28750 rpathdirs="$rpathdirs $dir"
28751 fi
28752 haveit=
28753 for x in $ltrpathdirs; do
28754 if test "X$x" = "X$dir"; then
28755 haveit=yes
28756 break
28757 fi
28758 done
28759 if test -z "$haveit"; then
28760 ltrpathdirs="$ltrpathdirs $dir"
28761 fi
28762 fi
28763 ;;
28764 -l*)
28765 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
28766 ;;
28767 *.la)
28768 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
28769 ;;
28770 *)
28771 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$dep"
28772 LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }$dep"
28773 ;;
28774 esac
28775 done
28776 fi
28777 else
28778 if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
28779 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }-l$name"
28780 LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }-l$name"
28781 else
28782 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }-l:lib$name.$libext"
28783 LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }-l:lib$name.$libext"
28784 fi
28785 fi
28786 fi
28787 fi
28788 done
28789 done
28790 if test "X$rpathdirs" != "X"; then
28791 if test -n "$hardcode_libdir_separator"; then
28792 alldirs=
28793 for found_dir in $rpathdirs; do
28794 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
28795 done
28796 acl_save_libdir="$libdir"
28797 libdir="$alldirs"
28798 eval flag=\"$hardcode_libdir_flag_spec\"
28799 libdir="$acl_save_libdir"
28800 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$flag"
28801 else
28802 for found_dir in $rpathdirs; do
28803 acl_save_libdir="$libdir"
28804 libdir="$found_dir"
28805 eval flag=\"$hardcode_libdir_flag_spec\"
28806 libdir="$acl_save_libdir"
28807 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$flag"
28808 done
3fc11d3e 28809 fi
8b35ed1f
SM
28810 fi
28811 if test "X$ltrpathdirs" != "X"; then
28812 for found_dir in $ltrpathdirs; do
28813 LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }-R$found_dir"
28814 done
28815 fi
bec39cab
AC
28816
28817
8b35ed1f 28818 ac_save_CPPFLAGS="$CPPFLAGS"
bec39cab 28819
8b35ed1f
SM
28820 for element in $INCLZMA; do
28821 haveit=
28822 for x in $CPPFLAGS; do
bec39cab 28823
8b35ed1f
SM
28824 acl_save_prefix="$prefix"
28825 prefix="$acl_final_prefix"
28826 acl_save_exec_prefix="$exec_prefix"
28827 exec_prefix="$acl_final_exec_prefix"
28828 eval x=\"$x\"
28829 exec_prefix="$acl_save_exec_prefix"
28830 prefix="$acl_save_prefix"
3fc11d3e 28831
8b35ed1f
SM
28832 if test "X$x" = "X$element"; then
28833 haveit=yes
28834 break
28835 fi
28836 done
28837 if test -z "$haveit"; then
28838 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
28839 fi
28840 done
3fc11d3e 28841
bec39cab 28842
8b35ed1f
SM
28843 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for liblzma" >&5
28844$as_echo_n "checking for liblzma... " >&6; }
28845if ${ac_cv_liblzma+:} false; then :
28846 $as_echo_n "(cached) " >&6
28847else
bec39cab 28848
8b35ed1f
SM
28849 ac_save_LIBS="$LIBS"
28850 LIBS="$LIBS $LIBLZMA"
28851 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28852/* end confdefs.h. */
28853#include "lzma.h"
28854int
28855main ()
28856{
28857lzma_index_iter iter;
28858 lzma_index_iter_init (&iter, 0);
28859 lzma_mf_is_supported (LZMA_MF_HC3);
28860 ;
28861 return 0;
28862}
28863_ACEOF
28864if ac_fn_c_try_link "$LINENO"; then :
28865 ac_cv_liblzma=yes
28866else
28867 ac_cv_liblzma=no
28868fi
28869rm -f core conftest.err conftest.$ac_objext \
28870 conftest$ac_exeext conftest.$ac_ext
28871 LIBS="$ac_save_LIBS"
3fc11d3e 28872
8b35ed1f
SM
28873fi
28874{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_liblzma" >&5
28875$as_echo "$ac_cv_liblzma" >&6; }
28876 if test "$ac_cv_liblzma" = yes; then
28877 HAVE_LIBLZMA=yes
3fc11d3e 28878
8b35ed1f 28879$as_echo "#define HAVE_LIBLZMA 1" >>confdefs.h
bec39cab 28880
8b35ed1f
SM
28881 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with liblzma" >&5
28882$as_echo_n "checking how to link with liblzma... " >&6; }
28883 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBLZMA" >&5
28884$as_echo "$LIBLZMA" >&6; }
3fc11d3e 28885 else
8b35ed1f
SM
28886 HAVE_LIBLZMA=no
28887 CPPFLAGS="$ac_save_CPPFLAGS"
28888 LIBLZMA=
28889 LTLIBLZMA=
3fc11d3e 28890 fi
3fc11d3e 28891
3fc11d3e 28892
4226a5a5 28893
3fc11d3e 28894
ffc6a242 28895
3ace7edb 28896
8b35ed1f
SM
28897 if test "$HAVE_LIBLZMA" != yes; then
28898 if test "$with_lzma" = yes; then
28899 as_fn_error $? "missing liblzma for --with-lzma" "$LINENO" 5
28900 fi
85541719 28901 fi
8b35ed1f 28902 fi
3fc11d3e
JM
28903fi
28904
8b35ed1f
SM
28905LIBGUI="../libgui/src/libgui.a"
28906GUI_CFLAGS_X="-I${srcdir}/../libgui/src"
3fc11d3e
JM
28907
28908
28909
8b35ed1f 28910WIN32LDAPP=
3fc11d3e
JM
28911
28912
28913
8b35ed1f
SM
28914case "${host}" in
28915*-*-cygwin* | *-*-mingw* )
28916 configdir="win"
28917 ;;
28918*)
28919 configdir="unix"
28920 ;;
28921esac
3fc11d3e 28922
8b35ed1f
SM
28923GDBTKLIBS=
28924if test "${enable_gdbtk}" = "yes"; then
bec39cab 28925
8b35ed1f
SM
28926 # Gdbtk must have an absolute path to srcdir in order to run
28927 # properly when not installed.
28928 here=`pwd`
28929 cd ${srcdir}
28930 GDBTK_SRC_DIR=`pwd`
28931 cd $here
c906108c 28932
c906108c 28933
8b35ed1f
SM
28934 #
28935 # Ok, lets find the tcl configuration
28936 # First, look for one uninstalled.
28937 # the alternative search directory is invoked by --with-tcl
28938 #
c906108c 28939
8b35ed1f
SM
28940 if test x"${no_tcl}" = x ; then
28941 # we reset no_tcl in case something fails here
28942 no_tcl=true
28943
28944# Check whether --with-tcl was given.
28945if test "${with_tcl+set}" = set; then :
28946 withval=$with_tcl; with_tclconfig=${withval}
28947fi
b686ecb5 28948
8b35ed1f
SM
28949 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Tcl configuration" >&5
28950$as_echo_n "checking for Tcl configuration... " >&6; }
28951 if ${ac_cv_c_tclconfig+:} false; then :
28952 $as_echo_n "(cached) " >&6
28953else
b686ecb5 28954
b686ecb5 28955
8b35ed1f
SM
28956 # First check to see if --with-tcl was specified.
28957 case "${host}" in
28958 *-*-cygwin*) platDir="win" ;;
28959 *) platDir="unix" ;;
28960 esac
28961 if test x"${with_tclconfig}" != x ; then
28962 if test -f "${with_tclconfig}/tclConfig.sh" ; then
28963 ac_cv_c_tclconfig=`(cd ${with_tclconfig}; pwd)`
28964 else
28965 as_fn_error $? "${with_tclconfig} directory doesn't contain tclConfig.sh" "$LINENO" 5
28966 fi
28967 fi
b686ecb5 28968
8b35ed1f
SM
28969 # then check for a private Tcl installation
28970 if test x"${ac_cv_c_tclconfig}" = x ; then
28971 for i in \
28972 ../tcl \
28973 `ls -dr ../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
28974 `ls -dr ../tcl[8-9].[0-9] 2>/dev/null` \
28975 `ls -dr ../tcl[8-9].[0-9]* 2>/dev/null` \
28976 ../../tcl \
28977 `ls -dr ../../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
28978 `ls -dr ../../tcl[8-9].[0-9] 2>/dev/null` \
28979 `ls -dr ../../tcl[8-9].[0-9]* 2>/dev/null` \
28980 ../../../tcl \
28981 `ls -dr ../../../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
28982 `ls -dr ../../../tcl[8-9].[0-9] 2>/dev/null` \
28983 `ls -dr ../../../tcl[8-9].[0-9]* 2>/dev/null` ; do
28984 if test -f "$i/$platDir/tclConfig.sh" ; then
28985 ac_cv_c_tclconfig=`(cd $i/$platDir; pwd)`
28986 break
28987 fi
28988 done
28989 fi
b686ecb5 28990
8b35ed1f
SM
28991 # on Darwin, check in Framework installation locations
28992 if test "`uname -s`" = "Darwin" -a x"${ac_cv_c_tclconfig}" = x ; then
28993 for i in `ls -d ~/Library/Frameworks 2>/dev/null` \
28994 `ls -d /Library/Frameworks 2>/dev/null` \
28995 `ls -d /Network/Library/Frameworks 2>/dev/null` \
28996 `ls -d /System/Library/Frameworks 2>/dev/null` \
28997 ; do
28998 if test -f "$i/Tcl.framework/tclConfig.sh" ; then
28999 ac_cv_c_tclconfig=`(cd $i/Tcl.framework; pwd)`
29000 break
29001 fi
29002 done
29003 fi
b686ecb5 29004
8b35ed1f
SM
29005 # check in a few common install locations
29006 if test x"${ac_cv_c_tclconfig}" = x ; then
29007 for i in `ls -d ${libdir} 2>/dev/null` \
29008 `ls -d ${exec_prefix}/lib 2>/dev/null` \
29009 `ls -d ${prefix}/lib 2>/dev/null` \
29010 `ls -d /usr/local/lib 2>/dev/null` \
29011 `ls -d /usr/contrib/lib 2>/dev/null` \
29012 `ls -d /usr/lib 2>/dev/null` \
29013 ; do
29014 if test -f "$i/tclConfig.sh" ; then
29015 ac_cv_c_tclconfig=`(cd $i; pwd)`
29016 break
29017 fi
29018 done
29019 fi
29020
29021 # check in a few other private locations
29022 if test x"${ac_cv_c_tclconfig}" = x ; then
29023 for i in \
29024 ${srcdir}/../tcl \
29025 `ls -dr ${srcdir}/../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
29026 `ls -dr ${srcdir}/../tcl[8-9].[0-9] 2>/dev/null` \
29027 `ls -dr ${srcdir}/../tcl[8-9].[0-9]* 2>/dev/null` ; do
29028 if test -f "$i/$platDir/tclConfig.sh" ; then
29029 ac_cv_c_tclconfig=`(cd $i/$platDir; pwd)`
29030 break
29031 fi
29032 done
29033 fi
b686ecb5 29034
b686ecb5 29035fi
b686ecb5 29036
8b35ed1f
SM
29037
29038 if test x"${ac_cv_c_tclconfig}" = x ; then
29039 TCL_BIN_DIR="# no Tcl configs found"
29040 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Can't find Tcl configuration definitions" >&5
29041$as_echo "$as_me: WARNING: Can't find Tcl configuration definitions" >&2;}
29042 else
29043 no_tcl=
29044 TCL_BIN_DIR=${ac_cv_c_tclconfig}
29045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found ${TCL_BIN_DIR}/tclConfig.sh" >&5
29046$as_echo "found ${TCL_BIN_DIR}/tclConfig.sh" >&6; }
29047 fi
b686ecb5 29048 fi
b686ecb5 29049
b686ecb5 29050
8b35ed1f
SM
29051 # If $no_tk is nonempty, then we can't do Tk, and there is no
29052 # point to doing Tcl.
b686ecb5 29053
8b35ed1f
SM
29054 #
29055 # Ok, lets find the tk configuration
29056 # First, look for one uninstalled.
29057 # the alternative search directory is invoked by --with-tk
29058 #
b686ecb5 29059
8b35ed1f
SM
29060 if test x"${no_tk}" = x ; then
29061 # we reset no_tk in case something fails here
29062 no_tk=true
29063
29064# Check whether --with-tk was given.
29065if test "${with_tk+set}" = set; then :
29066 withval=$with_tk; with_tkconfig=${withval}
b686ecb5
JM
29067fi
29068
8b35ed1f
SM
29069 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Tk configuration" >&5
29070$as_echo_n "checking for Tk configuration... " >&6; }
29071 if ${ac_cv_c_tkconfig+:} false; then :
29072 $as_echo_n "(cached) " >&6
29073else
b686ecb5 29074
b686ecb5 29075
8b35ed1f
SM
29076 # First check to see if --with-tkconfig was specified.
29077 if test x"${with_tkconfig}" != x ; then
29078 if test -f "${with_tkconfig}/tkConfig.sh" ; then
29079 ac_cv_c_tkconfig=`(cd ${with_tkconfig}; pwd)`
29080 else
29081 as_fn_error $? "${with_tkconfig} directory doesn't contain tkConfig.sh" "$LINENO" 5
29082 fi
29083 fi
b686ecb5 29084
8b35ed1f
SM
29085 # then check for a private Tk library
29086 case "${host}" in
29087 *-*-cygwin*) platDir="win" ;;
29088 *) platDir="unix" ;;
29089 esac
29090 if test x"${ac_cv_c_tkconfig}" = x ; then
29091 for i in \
29092 ../tk \
29093 `ls -dr ../tk[8-9].[0-9].[0-9]* 2>/dev/null` \
29094 `ls -dr ../tk[8-9].[0-9] 2>/dev/null` \
29095 `ls -dr ../tk[8-9].[0-9]* 2>/dev/null` \
29096 ../../tk \
29097 `ls -dr ../../tk[8-9].[0-9].[0-9]* 2>/dev/null` \
29098 `ls -dr ../../tk[8-9].[0-9] 2>/dev/null` \
29099 `ls -dr ../../tk[8-9].[0-9]* 2>/dev/null` \
29100 ../../../tk \
29101 `ls -dr ../../../tk[8-9].[0-9].[0-9]* 2>/dev/null` \
29102 `ls -dr ../../../tk[8-9].[0-9] 2>/dev/null` \
29103 `ls -dr ../../../tk[8-9].[0-9]* 2>/dev/null` ; do
29104 if test -f "$i/$platDir/tkConfig.sh" ; then
29105 ac_cv_c_tkconfig=`(cd $i/$platDir; pwd)`
29106 break
29107 fi
29108 done
29109 fi
b686ecb5 29110
8b35ed1f
SM
29111 # on Darwin, check in Framework installation locations
29112 if test "`uname -s`" = "Darwin" -a x"${ac_cv_c_tkconfig}" = x ; then
29113 for i in `ls -d ~/Library/Frameworks 2>/dev/null` \
29114 `ls -d /Library/Frameworks 2>/dev/null` \
29115 `ls -d /Network/Library/Frameworks 2>/dev/null` \
29116 `ls -d /System/Library/Frameworks 2>/dev/null` \
29117 ; do
29118 if test -f "$i/Tk.framework/tkConfig.sh" ; then
29119 ac_cv_c_tkconfig=`(cd $i/Tk.framework; pwd)`
29120 break
29121 fi
29122 done
29123 fi
29124
29125 # check in a few common install locations
29126 if test x"${ac_cv_c_tkconfig}" = x ; then
29127 for i in `ls -d ${libdir} 2>/dev/null` \
29128 `ls -d ${exec_prefix}/lib 2>/dev/null` \
29129 `ls -d ${prefix}/lib 2>/dev/null` \
29130 `ls -d /usr/local/lib 2>/dev/null` \
29131 `ls -d /usr/contrib/lib 2>/dev/null` \
29132 `ls -d /usr/lib 2>/dev/null` \
29133 ; do
29134 if test -f "$i/tkConfig.sh" ; then
29135 ac_cv_c_tkconfig=`(cd $i; pwd)`
29136 break
29137 fi
29138 done
29139 fi
29140 # check in a few other private locations
29141 if test x"${ac_cv_c_tkconfig}" = x ; then
29142 for i in \
29143 ${srcdir}/../tk \
29144 `ls -dr ${srcdir}/../tk[8-9].[0-9].[0-9]* 2>/dev/null` \
29145 `ls -dr ${srcdir}/../tk[8-9].[0-9] 2>/dev/null` \
29146 `ls -dr ${srcdir}/../tk[8-9].[0-9]* 2>/dev/null` ; do
29147 if test -f "$i/$platDir/tkConfig.sh" ; then
29148 ac_cv_c_tkconfig=`(cd $i/$platDir; pwd)`
29149 break
29150 fi
29151 done
29152 fi
b686ecb5 29153
b686ecb5
JM
29154fi
29155
29156
8b35ed1f
SM
29157 if test x"${ac_cv_c_tkconfig}" = x ; then
29158 TK_BIN_DIR="# no Tk configs found"
29159 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Can't find Tk configuration definitions" >&5
29160$as_echo "$as_me: WARNING: Can't find Tk configuration definitions" >&2;}
29161 else
29162 no_tk=
29163 TK_BIN_DIR=${ac_cv_c_tkconfig}
29164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found ${TK_BIN_DIR}/tkConfig.sh" >&5
29165$as_echo "found ${TK_BIN_DIR}/tkConfig.sh" >&6; }
29166 fi
29167 fi
b686ecb5
JM
29168
29169
8b35ed1f 29170 if test -z "${no_tcl}" -a -z "${no_tk}"; then
b686ecb5 29171
8b35ed1f
SM
29172 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for existence of ${TCL_BIN_DIR}/tclConfig.sh" >&5
29173$as_echo_n "checking for existence of ${TCL_BIN_DIR}/tclConfig.sh... " >&6; }
b686ecb5 29174
8b35ed1f
SM
29175 if test -f "${TCL_BIN_DIR}/tclConfig.sh" ; then
29176 { $as_echo "$as_me:${as_lineno-$LINENO}: result: loading" >&5
29177$as_echo "loading" >&6; }
29178 . ${TCL_BIN_DIR}/tclConfig.sh
29179 else
29180 { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not find ${TCL_BIN_DIR}/tclConfig.sh" >&5
29181$as_echo "could not find ${TCL_BIN_DIR}/tclConfig.sh" >&6; }
29182 fi
b686ecb5 29183
8b35ed1f
SM
29184 # eval is required to do the TCL_DBGX substitution
29185 eval "TCL_LIB_FILE=\"${TCL_LIB_FILE}\""
29186 eval "TCL_STUB_LIB_FILE=\"${TCL_STUB_LIB_FILE}\""
b686ecb5 29187
8b35ed1f
SM
29188 # If the TCL_BIN_DIR is the build directory (not the install directory),
29189 # then set the common variable name to the value of the build variables.
29190 # For example, the variable TCL_LIB_SPEC will be set to the value
29191 # of TCL_BUILD_LIB_SPEC. An extension should make use of TCL_LIB_SPEC
29192 # instead of TCL_BUILD_LIB_SPEC since it will work with both an
29193 # installed and uninstalled version of Tcl.
29194 if test -f "${TCL_BIN_DIR}/Makefile" ; then
29195 TCL_LIB_SPEC=${TCL_BUILD_LIB_SPEC}
29196 TCL_STUB_LIB_SPEC=${TCL_BUILD_STUB_LIB_SPEC}
29197 TCL_STUB_LIB_PATH=${TCL_BUILD_STUB_LIB_PATH}
29198 elif test "`uname -s`" = "Darwin"; then
29199 # If Tcl was built as a framework, attempt to use the libraries
29200 # from the framework at the given location so that linking works
29201 # against Tcl.framework installed in an arbitrary location.
29202 case ${TCL_DEFS} in
29203 *TCL_FRAMEWORK*)
29204 if test -f "${TCL_BIN_DIR}/${TCL_LIB_FILE}"; then
29205 for i in "`cd ${TCL_BIN_DIR}; pwd`" \
29206 "`cd ${TCL_BIN_DIR}/../..; pwd`"; do
29207 if test "`basename "$i"`" = "${TCL_LIB_FILE}.framework"; then
29208 TCL_LIB_SPEC="-F`dirname "$i"` -framework ${TCL_LIB_FILE}"
29209 break
29210 fi
29211 done
29212 fi
29213 if test -f "${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}"; then
29214 TCL_STUB_LIB_SPEC="-L${TCL_BIN_DIR} ${TCL_STUB_LIB_FLAG}"
29215 TCL_STUB_LIB_PATH="${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}"
29216 fi
29217 ;;
29218 esac
29219 fi
b686ecb5 29220
8b35ed1f
SM
29221 # eval is required to do the TCL_DBGX substitution
29222 eval "TCL_LIB_FLAG=\"${TCL_LIB_FLAG}\""
29223 eval "TCL_LIB_SPEC=\"${TCL_LIB_SPEC}\""
29224 eval "TCL_STUB_LIB_FLAG=\"${TCL_STUB_LIB_FLAG}\""
29225 eval "TCL_STUB_LIB_SPEC=\"${TCL_STUB_LIB_SPEC}\""
b686ecb5
JM
29226
29227
29228
29229
29230
b686ecb5 29231
b686ecb5
JM
29232
29233
b686ecb5
JM
29234
29235
b686ecb5
JM
29236
29237
b686ecb5
JM
29238
29239
b686ecb5 29240
8b35ed1f
SM
29241 # Check for in-tree tcl
29242 here=`pwd`
29243 cd ${srcdir}/..
29244 topdir=`pwd`
29245 cd ${here}
b686ecb5 29246
8b35ed1f
SM
29247 intree="no"
29248 if test "${TCL_SRC_DIR}" = "${topdir}/tcl"; then
29249 intree="yes"
29250 fi
b686ecb5 29251
8b35ed1f
SM
29252 # Find Tcl private headers
29253 if test x"${intree}" = xno; then
b686ecb5 29254
8b35ed1f
SM
29255 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Tcl private headers" >&5
29256$as_echo_n "checking for Tcl private headers... " >&6; }
29257 private_dir=""
29258 dir=`echo ${TCL_INCLUDE_SPEC}/tcl-private/generic | sed -e s/-I//`
29259 if test -f ${dir}/tclInt.h ; then
29260 private_dir=${dir}
29261 fi
b686ecb5 29262
8b35ed1f
SM
29263 if test x"${private_dir}" = x; then
29264 as_fn_error $? "could not find private Tcl headers" "$LINENO" 5
29265 else
29266 TCL_PRIVATE_INCLUDE="-I${private_dir}"
29267 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${private_dir}" >&5
29268$as_echo "${private_dir}" >&6; }
29269 fi
b686ecb5 29270
8b35ed1f
SM
29271 TCL_INCLUDE="${TCL_INCLUDE_SPEC} ${TCL_PRIVATE_INCLUDE}"
29272 TCL_LIBRARY="${TCL_LIB_SPEC}"
29273 TCL_DEPS=""
29274 else
29275 # If building tcl in the same src tree, private headers
29276 # are not needed, but we need to be sure to use the right
29277 # headers library
29278 TCL_INCLUDE="-I${TCL_SRC_DIR}/generic"
29279 TCL_LIBRARY="${TCL_BUILD_LIB_SPEC}"
29280 TCL_DEPS="../tcl/${configdir}${TCL_LIB_FILE}"
29281 fi
b686ecb5
JM
29282
29283
29284
29285
29286
8b35ed1f
SM
29287 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for existence of ${TK_BIN_DIR}/tkConfig.sh" >&5
29288$as_echo_n "checking for existence of ${TK_BIN_DIR}/tkConfig.sh... " >&6; }
b686ecb5 29289
8b35ed1f
SM
29290 if test -f "${TK_BIN_DIR}/tkConfig.sh" ; then
29291 { $as_echo "$as_me:${as_lineno-$LINENO}: result: loading" >&5
29292$as_echo "loading" >&6; }
29293 . ${TK_BIN_DIR}/tkConfig.sh
29294 else
29295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not find ${TK_BIN_DIR}/tkConfig.sh" >&5
29296$as_echo "could not find ${TK_BIN_DIR}/tkConfig.sh" >&6; }
29297 fi
b686ecb5 29298
8b35ed1f
SM
29299 # eval is required to do the TK_DBGX substitution
29300 eval "TK_LIB_FILE=\"${TK_LIB_FILE}\""
29301 eval "TK_STUB_LIB_FILE=\"${TK_STUB_LIB_FILE}\""
b686ecb5 29302
8b35ed1f
SM
29303 # If the TK_BIN_DIR is the build directory (not the install directory),
29304 # then set the common variable name to the value of the build variables.
29305 # For example, the variable TK_LIB_SPEC will be set to the value
29306 # of TK_BUILD_LIB_SPEC. An extension should make use of TK_LIB_SPEC
29307 # instead of TK_BUILD_LIB_SPEC since it will work with both an
29308 # installed and uninstalled version of Tcl.
29309 if test -f "${TK_BIN_DIR}/Makefile" ; then
29310 TK_LIB_SPEC=${TK_BUILD_LIB_SPEC}
29311 TK_STUB_LIB_SPEC=${TK_BUILD_STUB_LIB_SPEC}
29312 TK_STUB_LIB_PATH=${TK_BUILD_STUB_LIB_PATH}
29313 elif test "`uname -s`" = "Darwin"; then
29314 # If Tk was built as a framework, attempt to use the libraries
29315 # from the framework at the given location so that linking works
29316 # against Tk.framework installed in an arbitrary location.
29317 case ${TK_DEFS} in
29318 *TK_FRAMEWORK*)
29319 if test -f "${TK_BIN_DIR}/${TK_LIB_FILE}"; then
29320 for i in "`cd ${TK_BIN_DIR}; pwd`" \
29321 "`cd ${TK_BIN_DIR}/../..; pwd`"; do
29322 if test "`basename "$i"`" = "${TK_LIB_FILE}.framework"; then
29323 TK_LIB_SPEC="-F`dirname "$i"` -framework ${TK_LIB_FILE}"
29324 break
29325 fi
29326 done
29327 fi
29328 if test -f "${TK_BIN_DIR}/${TK_STUB_LIB_FILE}"; then
29329 TK_STUB_LIB_SPEC="-L${TK_BIN_DIR} ${TK_STUB_LIB_FLAG}"
29330 TK_STUB_LIB_PATH="${TK_BIN_DIR}/${TK_STUB_LIB_FILE}"
29331 fi
29332 ;;
29333 esac
29334 fi
b686ecb5 29335
8b35ed1f
SM
29336 # eval is required to do the TK_DBGX substitution
29337 eval "TK_LIB_FLAG=\"${TK_LIB_FLAG}\""
29338 eval "TK_LIB_SPEC=\"${TK_LIB_SPEC}\""
29339 eval "TK_STUB_LIB_FLAG=\"${TK_STUB_LIB_FLAG}\""
29340 eval "TK_STUB_LIB_SPEC=\"${TK_STUB_LIB_SPEC}\""
b686ecb5 29341
bec39cab 29342
bec39cab 29343
bec39cab 29344
bec39cab 29345
bec39cab 29346
bec39cab 29347
bec39cab 29348
b686ecb5 29349
c906108c 29350
b686ecb5 29351
b686ecb5
JM
29352
29353
29354
8b35ed1f
SM
29355 # Check for in-tree Tk
29356 intree="no"
29357 if test "${TK_SRC_DIR}" = "${topdir}/tk"; then
29358 intree="yes"
29359 fi
b686ecb5 29360
8b35ed1f
SM
29361 # Find Tk private headers
29362 if test x"${intree}" = xno; then
b686ecb5 29363
8b35ed1f
SM
29364 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Tk private headers" >&5
29365$as_echo_n "checking for Tk private headers... " >&6; }
29366 private_dir=""
29367 dir=`echo ${TK_INCLUDE_SPEC}/tk-private/generic | sed -e s/-I//`
29368 if test -f ${dir}/tkInt.h; then
29369 private_dir=${dir}
29370 fi
b686ecb5 29371
8b35ed1f
SM
29372 if test x"${private_dir}" = x; then
29373 as_fn_error $? "could not find Tk private headers" "$LINENO" 5
29374 else
29375 TK_PRIVATE_INCLUDE="-I${private_dir}"
29376 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${private_dir}" >&5
29377$as_echo "${private_dir}" >&6; }
29378 fi
b686ecb5 29379
8b35ed1f
SM
29380 TK_INCLUDE="${TK_INCLUDE_SPEC} ${TK_PRIVATE_INCLUDE}"
29381 TK_LIBRARY=${TK_LIB_SPEC}
29382 TK_DEPS=""
29383 else
29384 TK_INCLUDE="-I${TK_SRC_DIR}/generic"
29385 TK_LIBRARY="${TK_BUILD_LIB_SPEC}"
29386 TK_DEPS="../tk/${configdir}/${TK_LIB_FILE}"
29387 fi
b686ecb5 29388
b686ecb5 29389
b686ecb5 29390
b686ecb5 29391
b686ecb5 29392
8b35ed1f 29393 ENABLE_CFLAGS="${ENABLE_CFLAGS} \$(SUBDIR_GDBTK_CFLAGS)"
b686ecb5 29394
8b35ed1f
SM
29395 # Include some libraries that Tcl and Tk want.
29396 TCL_LIBS='$(LIBGUI) $(TK) $(TCL) $(X11_LDFLAGS) $(X11_LIBS)'
29397 # Yes, the ordering seems wrong here. But it isn't.
29398 # TK_LIBS is the list of libraries that need to be linked
29399 # after Tcl/Tk. Note that this isn't put into LIBS. If it
29400 # were in LIBS then any link tests after this point would
29401 # try to include things like `$(LIBGUI)', which wouldn't work.
29402 GDBTKLIBS="${TCL_LIBS} ${TK_LIBS}"
b686ecb5 29403
8b35ed1f
SM
29404 CONFIG_OBS="${CONFIG_OBS} \$(SUBDIR_GDBTK_OBS)"
29405 CONFIG_DEPS="${CONFIG_DEPS} \$(SUBDIR_GDBTK_DEPS)"
29406 CONFIG_SRCS="${CONFIG_SRCS} \$(SUBDIR_GDBTK_SRCS)"
29407 CONFIG_ALL="${CONFIG_ALL} all-gdbtk"
29408 CONFIG_CLEAN="${CONFIG_CLEAN} clean-gdbtk"
29409 CONFIG_INSTALL="${CONFIG_INSTALL} install-gdbtk"
29410 CONFIG_UNINSTALL="${CONFIG_UNINSTALL} uninstall-gdbtk"
b686ecb5 29411
8b35ed1f
SM
29412 if test x"$gdb_cv_os_cygwin" = xyes; then
29413 WIN32LIBS="${WIN32LIBS} -lshell32 -lgdi32 -lcomdlg32 -ladvapi32"
29414 WIN32LDAPP="-Wl,--subsystem,console"
29415 CONFIG_OBS="${CONFIG_OBS} gdbres.o"
29416 fi
b686ecb5 29417
8b35ed1f 29418 subdirs="$subdirs gdbtk"
b686ecb5 29419
c906108c 29420 fi
c906108c
SS
29421fi
29422
7a292a7a 29423
7a292a7a 29424
60ca704f 29425
976102cd 29426
976102cd 29427
b686ecb5 29428
b686ecb5 29429
8b35ed1f
SM
29430{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
29431$as_echo_n "checking for X... " >&6; }
29432
29433
29434# Check whether --with-x was given.
29435if test "${with_x+set}" = set; then :
29436 withval=$with_x;
29437fi
29438
29439# $have_x is `yes', `no', `disabled', or empty when we do not yet know.
29440if test "x$with_x" = xno; then
29441 # The user explicitly disabled X.
29442 have_x=disabled
29443else
29444 case $x_includes,$x_libraries in #(
29445 *\'*) as_fn_error $? "cannot use X directory names containing '" "$LINENO" 5;; #(
29446 *,NONE | NONE,*) if ${ac_cv_have_x+:} false; then :
29447 $as_echo_n "(cached) " >&6
29448else
29449 # One or both of the vars are not set, and there is no cached value.
29450ac_x_includes=no ac_x_libraries=no
29451rm -f -r conftest.dir
29452if mkdir conftest.dir; then
29453 cd conftest.dir
29454 cat >Imakefile <<'_ACEOF'
29455incroot:
29456 @echo incroot='${INCROOT}'
29457usrlibdir:
29458 @echo usrlibdir='${USRLIBDIR}'
29459libdir:
29460 @echo libdir='${LIBDIR}'
29461_ACEOF
29462 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
29463 # GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
29464 for ac_var in incroot usrlibdir libdir; do
29465 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
b686ecb5 29466 done
8b35ed1f
SM
29467 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
29468 for ac_extension in a so sl dylib la dll; do
29469 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
29470 test -f "$ac_im_libdir/libX11.$ac_extension"; then
29471 ac_im_usrlibdir=$ac_im_libdir; break
29472 fi
b686ecb5 29473 done
8b35ed1f
SM
29474 # Screen out bogus values from the imake configuration. They are
29475 # bogus both because they are the default anyway, and because
29476 # using them would break gcc on systems where it needs fixed includes.
29477 case $ac_im_incroot in
29478 /usr/include) ac_x_includes= ;;
29479 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
29480 esac
29481 case $ac_im_usrlibdir in
29482 /usr/lib | /usr/lib64 | /lib | /lib64) ;;
29483 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
29484 esac
9b624dbe 29485 fi
8b35ed1f
SM
29486 cd ..
29487 rm -f -r conftest.dir
29488fi
dfcd3bfb 29489
8b35ed1f
SM
29490# Standard set of common directories for X headers.
29491# Check X11 before X11Rn because it is often a symlink to the current release.
29492ac_x_header_dirs='
29493/usr/X11/include
29494/usr/X11R7/include
29495/usr/X11R6/include
29496/usr/X11R5/include
29497/usr/X11R4/include
e56ac5c3 29498
8b35ed1f
SM
29499/usr/include/X11
29500/usr/include/X11R7
29501/usr/include/X11R6
29502/usr/include/X11R5
29503/usr/include/X11R4
e56ac5c3 29504
8b35ed1f
SM
29505/usr/local/X11/include
29506/usr/local/X11R7/include
29507/usr/local/X11R6/include
29508/usr/local/X11R5/include
29509/usr/local/X11R4/include
b3a90332 29510
8b35ed1f
SM
29511/usr/local/include/X11
29512/usr/local/include/X11R7
29513/usr/local/include/X11R6
29514/usr/local/include/X11R5
29515/usr/local/include/X11R4
b3a90332 29516
8b35ed1f
SM
29517/usr/X386/include
29518/usr/x386/include
29519/usr/XFree86/include/X11
29520
29521/usr/include
29522/usr/local/include
29523/usr/unsupported/include
29524/usr/athena/include
29525/usr/local/x11r5/include
29526/usr/lpp/Xamples/include
bec39cab 29527
8b35ed1f
SM
29528/usr/openwin/include
29529/usr/openwin/share/include'
c35f4ffc 29530
8b35ed1f
SM
29531if test "$ac_x_includes" = no; then
29532 # Guess where to find include files, by looking for Xlib.h.
29533 # First, try using that file with no special directory specified.
29534 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29535/* end confdefs.h. */
29536#include <X11/Xlib.h>
29537_ACEOF
29538if ac_fn_c_try_cpp "$LINENO"; then :
29539 # We can compile using X headers with no special include directory.
29540ac_x_includes=
b686ecb5 29541else
8b35ed1f
SM
29542 for ac_dir in $ac_x_header_dirs; do
29543 if test -r "$ac_dir/X11/Xlib.h"; then
29544 ac_x_includes=$ac_dir
29545 break
29546 fi
29547done
29548fi
29549rm -f conftest.err conftest.i conftest.$ac_ext
29550fi # $ac_x_includes = no
bec39cab 29551
8b35ed1f
SM
29552if test "$ac_x_libraries" = no; then
29553 # Check for the libraries.
29554 # See if we find them without any special options.
29555 # Don't add to $LIBS permanently.
29556 ac_save_LIBS=$LIBS
29557 LIBS="-lX11 $LIBS"
29558 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
b686ecb5 29559/* end confdefs.h. */
8b35ed1f 29560#include <X11/Xlib.h>
b686ecb5
JM
29561int
29562main ()
29563{
8b35ed1f 29564XrmInitialize ()
b686ecb5
JM
29565 ;
29566 return 0;
29567}
bec39cab 29568_ACEOF
b686ecb5 29569if ac_fn_c_try_link "$LINENO"; then :
8b35ed1f
SM
29570 LIBS=$ac_save_LIBS
29571# We can link X programs with no special library path.
29572ac_x_libraries=
b686ecb5 29573else
8b35ed1f
SM
29574 LIBS=$ac_save_LIBS
29575for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
29576do
29577 # Don't even attempt the hair of trying to link an X program!
29578 for ac_extension in a so sl dylib la dll; do
29579 if test -r "$ac_dir/libX11.$ac_extension"; then
29580 ac_x_libraries=$ac_dir
29581 break 2
29582 fi
29583 done
29584done
c906108c 29585fi
b686ecb5
JM
29586rm -f core conftest.err conftest.$ac_objext \
29587 conftest$ac_exeext conftest.$ac_ext
8b35ed1f
SM
29588fi # $ac_x_libraries = no
29589
29590case $ac_x_includes,$ac_x_libraries in #(
29591 no,* | *,no | *\'*)
29592 # Didn't find X, or a directory has "'" in its name.
29593 ac_cv_have_x="have_x=no";; #(
29594 *)
29595 # Record where we found X for the cache.
29596 ac_cv_have_x="have_x=yes\
29597 ac_x_includes='$ac_x_includes'\
29598 ac_x_libraries='$ac_x_libraries'"
29599esac
29600fi
29601;; #(
29602 *) have_x=yes;;
29603 esac
29604 eval "$ac_cv_have_x"
29605fi # $with_x != no
c906108c 29606
8b35ed1f
SM
29607if test "$have_x" != yes; then
29608 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
29609$as_echo "$have_x" >&6; }
29610 no_x=yes
29611else
29612 # If each of the values was on the command line, it overrides each guess.
29613 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
29614 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
29615 # Update the cache value to reflect the command line values.
29616 ac_cv_have_x="have_x=yes\
29617 ac_x_includes='$x_includes'\
29618 ac_x_libraries='$x_libraries'"
29619 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
29620$as_echo "libraries $x_libraries, headers $x_includes" >&6; }
c906108c 29621fi
c906108c 29622
c906108c 29623
8b35ed1f
SM
29624# Unlike the sim directory, whether a simulator is linked is controlled by
29625# presence of a gdb_sim definition in the target configure.tgt entry.
29626# This code just checks for a few cases where we'd like to ignore those
29627# definitions, even when they're present in the '.mt' file. These cases
29628# are when --disable-sim is specified, or if the simulator directory is
29629# not part of the source tree.
29630#
29631# Check whether --enable-sim was given.
29632if test "${enable_sim+set}" = set; then :
29633 enableval=$enable_sim; echo "enable_sim = $enable_sim";
29634 echo "enableval = ${enableval}";
29635 case "${enableval}" in
29636 yes) ignore_sim=false ;;
29637 no) ignore_sim=true ;;
29638 *) ignore_sim=false ;;
29639 esac
29640else
29641 ignore_sim=false
29642fi
29643
29644
29645if test ! -d "${srcdir}/../sim"; then
29646 ignore_sim=true
29647fi
29648
29649SIM=
29650SIM_OBS=
29651if test "${ignore_sim}" = "false"; then
29652 if test x"${gdb_sim}" != x ; then
29653 SIM="${gdb_sim}"
29654 SIM_OBS="remote-sim.o"
29655
29656 # Some tdep code should only be compiled in when the ppc sim is
29657 # built. PR sim/13418.
29658 case $target in
29659 powerpc*-*-*)
29660
29661$as_echo "#define WITH_PPC_SIM 1" >>confdefs.h
29662
29663 ;;
29664 esac
b686ecb5 29665 fi
8b35ed1f
SM
29666fi
29667
29668
29669
29670
29671
29672
29673
29674
29675
29676
29677
29678
29679
29680
29681# List of host floatformats.
29682
29683cat >>confdefs.h <<_ACEOF
29684#define GDB_HOST_FLOAT_FORMAT $gdb_host_float_format
29685_ACEOF
29686
29687
29688cat >>confdefs.h <<_ACEOF
29689#define GDB_HOST_DOUBLE_FORMAT $gdb_host_double_format
29690_ACEOF
29691
29692
29693cat >>confdefs.h <<_ACEOF
29694#define GDB_HOST_LONG_DOUBLE_FORMAT $gdb_host_long_double_format
29695_ACEOF
29696
29697
29698# target_subdir is used by the testsuite to find the target libraries.
29699target_subdir=
29700if test "${host}" != "${target}"; then
29701 target_subdir="${target_alias}/"
29702fi
29703
29704
29705# Import nat definitions.
29706nat_makefile_frag=/dev/null
29707if test "${gdb_native}" = "yes"; then
29708 . ${srcdir}/configure.nat
29709 nativefile=$NAT_FILE
29710fi
c906108c
SS
29711
29712
21ea5acd
SDJ
29713
29714
29715
29716
29717
8b35ed1f
SM
29718
29719
29720
29721
29722if test x"${gdb_osabi}" != x ; then
29723
29724cat >>confdefs.h <<_ACEOF
29725#define GDB_OSABI_DEFAULT $gdb_osabi
29726_ACEOF
29727
b00a8037
DJ
29728fi
29729
8b35ed1f
SM
29730# Setup possible use of libbacktrace.
29731# Check whether --enable-libbacktrace was given.
29732if test "${enable_libbacktrace+set}" = set; then :
29733 enableval=$enable_libbacktrace;
29734 case $enableval in
29735 yes | no)
29736 ;;
29737 *)
29738 as_fn_error $? "bad value $enableval for --enable-libbacktrace" "$LINENO" 5
29739 ;;
29740 esac
4fd404c2 29741
abbbd4a3 29742else
8b35ed1f 29743 enable_libbacktrace=yes
abbbd4a3
AB
29744fi
29745
29746
8b35ed1f
SM
29747if test "${enable_libbacktrace}" = "yes"; then
29748 LIBBACKTRACE_INC="-I$srcdir/../libbacktrace/ -I../libbacktrace/"
29749 LIBBACKTRACE_LIB=../libbacktrace/libbacktrace.la
29750
29751$as_echo "#define HAVE_LIBBACKTRACE 1" >>confdefs.h
abbbd4a3
AB
29752
29753else
8b35ed1f
SM
29754 LIBBACKTRACE_INC=
29755 LIBBACKTRACE_LIB=
abbbd4a3
AB
29756fi
29757
29758
29759
29760
8b35ed1f
SM
29761# Check for babeltrace and babeltrace-ctf
29762
29763# Check whether --with-babeltrace was given.
29764if test "${with_babeltrace+set}" = set; then :
29765 withval=$with_babeltrace;
393fd4c3 29766else
8b35ed1f 29767 with_babeltrace=auto
393fd4c3
YQ
29768fi
29769
8b35ed1f
SM
29770{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use babeltrace" >&5
29771$as_echo_n "checking whether to use babeltrace... " >&6; }
29772{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_babeltrace" >&5
29773$as_echo "$with_babeltrace" >&6; }
393fd4c3 29774
8b35ed1f
SM
29775if test "x$with_babeltrace" = "xno"; then
29776 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: babletrace support disabled; GDB is unable to read CTF data." >&5
29777$as_echo "$as_me: WARNING: babletrace support disabled; GDB is unable to read CTF data." >&2;}
29778else
29779 # Append -Werror to CFLAGS so that configure can catch the warning
29780 # "assignment from incompatible pointer type", which is related to
29781 # the babeltrace change from 1.0.3 to 1.1.0. Babeltrace 1.1.0 works
29782 # in GDB, while babeltrace 1.0.3 is broken.
29783 # AC_LIB_HAVE_LINKFLAGS may modify CPPFLAGS in it, so it should be
29784 # safe to save and restore CFLAGS here.
29785 saved_CFLAGS=$CFLAGS
29786 CFLAGS="$CFLAGS -Werror"
393fd4c3
YQ
29787
29788
29789
29790
29791
29792
29793
29794
29795 use_additional=yes
29796
29797 acl_save_prefix="$prefix"
29798 prefix="$acl_final_prefix"
29799 acl_save_exec_prefix="$exec_prefix"
29800 exec_prefix="$acl_final_exec_prefix"
29801
29802 eval additional_includedir=\"$includedir\"
29803 eval additional_libdir=\"$libdir\"
29804
29805 exec_prefix="$acl_save_exec_prefix"
29806 prefix="$acl_save_prefix"
29807
29808
8b35ed1f
SM
29809# Check whether --with-libbabeltrace-prefix was given.
29810if test "${with_libbabeltrace_prefix+set}" = set; then :
29811 withval=$with_libbabeltrace_prefix;
393fd4c3
YQ
29812 if test "X$withval" = "Xno"; then
29813 use_additional=no
29814 else
29815 if test "X$withval" = "X"; then
29816
29817 acl_save_prefix="$prefix"
29818 prefix="$acl_final_prefix"
29819 acl_save_exec_prefix="$exec_prefix"
29820 exec_prefix="$acl_final_exec_prefix"
29821
29822 eval additional_includedir=\"$includedir\"
29823 eval additional_libdir=\"$libdir\"
29824
29825 exec_prefix="$acl_save_exec_prefix"
29826 prefix="$acl_save_prefix"
29827
29828 else
29829 additional_includedir="$withval/include"
29830 additional_libdir="$withval/lib"
29831 fi
29832 fi
29833
29834fi
29835
9f1528a1 29836
8b35ed1f
SM
29837# Check whether --with-libbabeltrace-type was given.
29838if test "${with_libbabeltrace_type+set}" = set; then :
29839 withval=$with_libbabeltrace_type; with_libbabeltrace_type=$withval
9f1528a1 29840else
8b35ed1f 29841 with_libbabeltrace_type=auto
9f1528a1
AB
29842fi
29843
8b35ed1f 29844 lib_type=`eval echo \$with_libbabeltrace_type`
9f1528a1 29845
8b35ed1f
SM
29846 LIBBABELTRACE=
29847 LTLIBBABELTRACE=
29848 INCBABELTRACE=
393fd4c3
YQ
29849 rpathdirs=
29850 ltrpathdirs=
29851 names_already_handled=
8b35ed1f 29852 names_next_round='babeltrace babeltrace-ctf'
393fd4c3
YQ
29853 while test -n "$names_next_round"; do
29854 names_this_round="$names_next_round"
29855 names_next_round=
29856 for name in $names_this_round; do
29857 already_handled=
29858 for n in $names_already_handled; do
29859 if test "$n" = "$name"; then
29860 already_handled=yes
29861 break
29862 fi
29863 done
29864 if test -z "$already_handled"; then
29865 names_already_handled="$names_already_handled $name"
29866 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
29867 eval value=\"\$HAVE_LIB$uppername\"
29868 if test -n "$value"; then
29869 if test "$value" = yes; then
29870 eval value=\"\$LIB$uppername\"
8b35ed1f 29871 test -z "$value" || LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$value"
393fd4c3 29872 eval value=\"\$LTLIB$uppername\"
8b35ed1f 29873 test -z "$value" || LTLIBBABELTRACE="${LTLIBBABELTRACE}${LTLIBBABELTRACE:+ }$value"
393fd4c3
YQ
29874 else
29875 :
29876 fi
29877 else
29878 found_dir=
29879 found_la=
29880 found_so=
29881 found_a=
29882 if test $use_additional = yes; then
9f1528a1 29883 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
393fd4c3
YQ
29884 found_dir="$additional_libdir"
29885 found_so="$additional_libdir/lib$name.$shlibext"
29886 if test -f "$additional_libdir/lib$name.la"; then
29887 found_la="$additional_libdir/lib$name.la"
29888 fi
9f1528a1 29889 elif test x$lib_type != xshared; then
393fd4c3
YQ
29890 if test -f "$additional_libdir/lib$name.$libext"; then
29891 found_dir="$additional_libdir"
29892 found_a="$additional_libdir/lib$name.$libext"
29893 if test -f "$additional_libdir/lib$name.la"; then
29894 found_la="$additional_libdir/lib$name.la"
29895 fi
29896 fi
29897 fi
29898 fi
29899 if test "X$found_dir" = "X"; then
8b35ed1f 29900 for x in $LDFLAGS $LTLIBBABELTRACE; do
393fd4c3
YQ
29901
29902 acl_save_prefix="$prefix"
29903 prefix="$acl_final_prefix"
29904 acl_save_exec_prefix="$exec_prefix"
29905 exec_prefix="$acl_final_exec_prefix"
29906 eval x=\"$x\"
29907 exec_prefix="$acl_save_exec_prefix"
29908 prefix="$acl_save_prefix"
29909
29910 case "$x" in
29911 -L*)
29912 dir=`echo "X$x" | sed -e 's/^X-L//'`
9f1528a1 29913 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
393fd4c3
YQ
29914 found_dir="$dir"
29915 found_so="$dir/lib$name.$shlibext"
29916 if test -f "$dir/lib$name.la"; then
29917 found_la="$dir/lib$name.la"
29918 fi
9f1528a1 29919 elif test x$lib_type != xshared; then
393fd4c3
YQ
29920 if test -f "$dir/lib$name.$libext"; then
29921 found_dir="$dir"
29922 found_a="$dir/lib$name.$libext"
29923 if test -f "$dir/lib$name.la"; then
29924 found_la="$dir/lib$name.la"
29925 fi
29926 fi
29927 fi
29928 ;;
29929 esac
29930 if test "X$found_dir" != "X"; then
29931 break
29932 fi
29933 done
29934 fi
29935 if test "X$found_dir" != "X"; then
8b35ed1f 29936 LTLIBBABELTRACE="${LTLIBBABELTRACE}${LTLIBBABELTRACE:+ }-L$found_dir -l$name"
393fd4c3
YQ
29937 if test "X$found_so" != "X"; then
29938 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
8b35ed1f 29939 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$found_so"
393fd4c3
YQ
29940 else
29941 haveit=
29942 for x in $ltrpathdirs; do
29943 if test "X$x" = "X$found_dir"; then
29944 haveit=yes
29945 break
29946 fi
29947 done
29948 if test -z "$haveit"; then
29949 ltrpathdirs="$ltrpathdirs $found_dir"
29950 fi
29951 if test "$hardcode_direct" = yes; then
8b35ed1f 29952 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$found_so"
393fd4c3
YQ
29953 else
29954 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
8b35ed1f 29955 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$found_so"
393fd4c3
YQ
29956 haveit=
29957 for x in $rpathdirs; do
29958 if test "X$x" = "X$found_dir"; then
29959 haveit=yes
29960 break
29961 fi
29962 done
29963 if test -z "$haveit"; then
29964 rpathdirs="$rpathdirs $found_dir"
29965 fi
29966 else
29967 haveit=
8b35ed1f 29968 for x in $LDFLAGS $LIBBABELTRACE; do
393fd4c3
YQ
29969
29970 acl_save_prefix="$prefix"
29971 prefix="$acl_final_prefix"
29972 acl_save_exec_prefix="$exec_prefix"
29973 exec_prefix="$acl_final_exec_prefix"
29974 eval x=\"$x\"
29975 exec_prefix="$acl_save_exec_prefix"
29976 prefix="$acl_save_prefix"
29977
29978 if test "X$x" = "X-L$found_dir"; then
29979 haveit=yes
29980 break
29981 fi
29982 done
29983 if test -z "$haveit"; then
8b35ed1f 29984 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }-L$found_dir"
393fd4c3
YQ
29985 fi
29986 if test "$hardcode_minus_L" != no; then
8b35ed1f 29987 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$found_so"
393fd4c3 29988 else
8b35ed1f 29989 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }-l$name"
393fd4c3
YQ
29990 fi
29991 fi
29992 fi
29993 fi
29994 else
29995 if test "X$found_a" != "X"; then
8b35ed1f 29996 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$found_a"
393fd4c3 29997 else
8b35ed1f 29998 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }-L$found_dir -l$name"
393fd4c3
YQ
29999 fi
30000 fi
30001 additional_includedir=
30002 case "$found_dir" in
30003 */lib | */lib/)
30004 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
30005 additional_includedir="$basedir/include"
30006 ;;
30007 esac
30008 if test "X$additional_includedir" != "X"; then
30009 if test "X$additional_includedir" != "X/usr/include"; then
30010 haveit=
30011 if test "X$additional_includedir" = "X/usr/local/include"; then
30012 if test -n "$GCC"; then
30013 case $host_os in
30014 linux*) haveit=yes;;
30015 esac
30016 fi
30017 fi
30018 if test -z "$haveit"; then
8b35ed1f 30019 for x in $CPPFLAGS $INCBABELTRACE; do
393fd4c3
YQ
30020
30021 acl_save_prefix="$prefix"
30022 prefix="$acl_final_prefix"
30023 acl_save_exec_prefix="$exec_prefix"
30024 exec_prefix="$acl_final_exec_prefix"
30025 eval x=\"$x\"
30026 exec_prefix="$acl_save_exec_prefix"
30027 prefix="$acl_save_prefix"
30028
30029 if test "X$x" = "X-I$additional_includedir"; then
30030 haveit=yes
30031 break
30032 fi
30033 done
30034 if test -z "$haveit"; then
30035 if test -d "$additional_includedir"; then
8b35ed1f 30036 INCBABELTRACE="${INCBABELTRACE}${INCBABELTRACE:+ }-I$additional_includedir"
393fd4c3
YQ
30037 fi
30038 fi
30039 fi
30040 fi
30041 fi
30042 if test -n "$found_la"; then
30043 save_libdir="$libdir"
30044 case "$found_la" in
30045 */* | *\\*) . "$found_la" ;;
30046 *) . "./$found_la" ;;
30047 esac
30048 libdir="$save_libdir"
30049 for dep in $dependency_libs; do
30050 case "$dep" in
30051 -L*)
30052 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
30053 if test "X$additional_libdir" != "X/usr/lib"; then
30054 haveit=
30055 if test "X$additional_libdir" = "X/usr/local/lib"; then
30056 if test -n "$GCC"; then
30057 case $host_os in
30058 linux*) haveit=yes;;
30059 esac
30060 fi
30061 fi
30062 if test -z "$haveit"; then
30063 haveit=
8b35ed1f 30064 for x in $LDFLAGS $LIBBABELTRACE; do
393fd4c3
YQ
30065
30066 acl_save_prefix="$prefix"
30067 prefix="$acl_final_prefix"
30068 acl_save_exec_prefix="$exec_prefix"
30069 exec_prefix="$acl_final_exec_prefix"
30070 eval x=\"$x\"
30071 exec_prefix="$acl_save_exec_prefix"
30072 prefix="$acl_save_prefix"
30073
30074 if test "X$x" = "X-L$additional_libdir"; then
30075 haveit=yes
30076 break
30077 fi
30078 done
30079 if test -z "$haveit"; then
30080 if test -d "$additional_libdir"; then
8b35ed1f 30081 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }-L$additional_libdir"
393fd4c3
YQ
30082 fi
30083 fi
30084 haveit=
8b35ed1f 30085 for x in $LDFLAGS $LTLIBBABELTRACE; do
393fd4c3
YQ
30086
30087 acl_save_prefix="$prefix"
30088 prefix="$acl_final_prefix"
30089 acl_save_exec_prefix="$exec_prefix"
30090 exec_prefix="$acl_final_exec_prefix"
30091 eval x=\"$x\"
30092 exec_prefix="$acl_save_exec_prefix"
30093 prefix="$acl_save_prefix"
30094
30095 if test "X$x" = "X-L$additional_libdir"; then
30096 haveit=yes
30097 break
30098 fi
30099 done
30100 if test -z "$haveit"; then
30101 if test -d "$additional_libdir"; then
8b35ed1f 30102 LTLIBBABELTRACE="${LTLIBBABELTRACE}${LTLIBBABELTRACE:+ }-L$additional_libdir"
393fd4c3
YQ
30103 fi
30104 fi
30105 fi
30106 fi
30107 ;;
30108 -R*)
30109 dir=`echo "X$dep" | sed -e 's/^X-R//'`
30110 if test "$enable_rpath" != no; then
30111 haveit=
30112 for x in $rpathdirs; do
30113 if test "X$x" = "X$dir"; then
30114 haveit=yes
30115 break
30116 fi
30117 done
30118 if test -z "$haveit"; then
30119 rpathdirs="$rpathdirs $dir"
30120 fi
30121 haveit=
30122 for x in $ltrpathdirs; do
30123 if test "X$x" = "X$dir"; then
30124 haveit=yes
30125 break
30126 fi
30127 done
30128 if test -z "$haveit"; then
30129 ltrpathdirs="$ltrpathdirs $dir"
30130 fi
30131 fi
30132 ;;
30133 -l*)
30134 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
30135 ;;
30136 *.la)
30137 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
30138 ;;
30139 *)
8b35ed1f
SM
30140 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$dep"
30141 LTLIBBABELTRACE="${LTLIBBABELTRACE}${LTLIBBABELTRACE:+ }$dep"
393fd4c3
YQ
30142 ;;
30143 esac
30144 done
30145 fi
30146 else
9f1528a1 30147 if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
8b35ed1f
SM
30148 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }-l$name"
30149 LTLIBBABELTRACE="${LTLIBBABELTRACE}${LTLIBBABELTRACE:+ }-l$name"
9f1528a1 30150 else
8b35ed1f
SM
30151 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }-l:lib$name.$libext"
30152 LTLIBBABELTRACE="${LTLIBBABELTRACE}${LTLIBBABELTRACE:+ }-l:lib$name.$libext"
9f1528a1 30153 fi
393fd4c3
YQ
30154 fi
30155 fi
30156 fi
30157 done
30158 done
30159 if test "X$rpathdirs" != "X"; then
30160 if test -n "$hardcode_libdir_separator"; then
30161 alldirs=
30162 for found_dir in $rpathdirs; do
30163 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
30164 done
30165 acl_save_libdir="$libdir"
30166 libdir="$alldirs"
30167 eval flag=\"$hardcode_libdir_flag_spec\"
30168 libdir="$acl_save_libdir"
8b35ed1f 30169 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$flag"
393fd4c3
YQ
30170 else
30171 for found_dir in $rpathdirs; do
30172 acl_save_libdir="$libdir"
30173 libdir="$found_dir"
30174 eval flag=\"$hardcode_libdir_flag_spec\"
30175 libdir="$acl_save_libdir"
8b35ed1f 30176 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$flag"
393fd4c3
YQ
30177 done
30178 fi
30179 fi
b686ecb5
JM
30180 if test "X$ltrpathdirs" != "X"; then
30181 for found_dir in $ltrpathdirs; do
8b35ed1f 30182 LTLIBBABELTRACE="${LTLIBBABELTRACE}${LTLIBBABELTRACE:+ }-R$found_dir"
b686ecb5
JM
30183 done
30184 fi
30185
30186
30187 ac_save_CPPFLAGS="$CPPFLAGS"
30188
8b35ed1f 30189 for element in $INCBABELTRACE; do
b686ecb5
JM
30190 haveit=
30191 for x in $CPPFLAGS; do
30192
30193 acl_save_prefix="$prefix"
30194 prefix="$acl_final_prefix"
30195 acl_save_exec_prefix="$exec_prefix"
30196 exec_prefix="$acl_final_exec_prefix"
30197 eval x=\"$x\"
30198 exec_prefix="$acl_save_exec_prefix"
30199 prefix="$acl_save_prefix"
30200
30201 if test "X$x" = "X$element"; then
30202 haveit=yes
30203 break
30204 fi
30205 done
30206 if test -z "$haveit"; then
30207 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
30208 fi
30209 done
30210
30211
8b35ed1f
SM
30212 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libbabeltrace" >&5
30213$as_echo_n "checking for libbabeltrace... " >&6; }
30214if ${ac_cv_libbabeltrace+:} false; then :
b686ecb5
JM
30215 $as_echo_n "(cached) " >&6
30216else
30217
30218 ac_save_LIBS="$LIBS"
8b35ed1f 30219 LIBS="$LIBS $LIBBABELTRACE"
b686ecb5
JM
30220 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30221/* end confdefs.h. */
8b35ed1f
SM
30222#include <babeltrace/babeltrace.h>
30223 #include <babeltrace/ctf/events.h>
30224 #include <babeltrace/ctf/iterator.h>
b686ecb5
JM
30225int
30226main ()
30227{
8b35ed1f
SM
30228struct bt_iter_pos *pos = bt_iter_get_pos (bt_ctf_get_iter (NULL));
30229 struct bt_ctf_event *event = NULL;
30230 const struct bt_definition *scope;
30231
30232 pos->type = BT_SEEK_BEGIN;
30233 bt_iter_set_pos (bt_ctf_get_iter (NULL), pos);
30234 scope = bt_ctf_get_top_level_scope (event,
30235 BT_STREAM_EVENT_HEADER);
30236 bt_ctf_get_uint64 (bt_ctf_get_field (event, scope, "id"));
b686ecb5
JM
30237
30238 ;
30239 return 0;
30240}
30241_ACEOF
30242if ac_fn_c_try_link "$LINENO"; then :
8b35ed1f 30243 ac_cv_libbabeltrace=yes
b686ecb5 30244else
8b35ed1f 30245 ac_cv_libbabeltrace=no
b686ecb5
JM
30246fi
30247rm -f core conftest.err conftest.$ac_objext \
30248 conftest$ac_exeext conftest.$ac_ext
30249 LIBS="$ac_save_LIBS"
30250
30251fi
8b35ed1f
SM
30252{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libbabeltrace" >&5
30253$as_echo "$ac_cv_libbabeltrace" >&6; }
30254 if test "$ac_cv_libbabeltrace" = yes; then
30255 HAVE_LIBBABELTRACE=yes
b686ecb5 30256
8b35ed1f 30257$as_echo "#define HAVE_LIBBABELTRACE 1" >>confdefs.h
b686ecb5 30258
8b35ed1f
SM
30259 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libbabeltrace" >&5
30260$as_echo_n "checking how to link with libbabeltrace... " >&6; }
30261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBBABELTRACE" >&5
30262$as_echo "$LIBBABELTRACE" >&6; }
b686ecb5 30263 else
8b35ed1f 30264 HAVE_LIBBABELTRACE=no
b686ecb5 30265 CPPFLAGS="$ac_save_CPPFLAGS"
8b35ed1f
SM
30266 LIBBABELTRACE=
30267 LTLIBBABELTRACE=
b686ecb5
JM
30268 fi
30269
30270
30271
30272
30273
30274
8b35ed1f
SM
30275 CFLAGS=$saved_CFLAGS
30276
30277 if test "$HAVE_LIBBABELTRACE" != yes; then
30278 if test "$with_babeltrace" = yes; then
30279 as_fn_error $? "babeltrace is missing or unusable" "$LINENO" 5
30280 else
30281 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: babeltrace is missing or unusable; GDB is unable to read CTF data." >&5
30282$as_echo "$as_me: WARNING: babeltrace is missing or unusable; GDB is unable to read CTF data." >&2;}
30283 fi
b686ecb5
JM
30284 fi
30285fi
30286
8b35ed1f
SM
30287 # Check whether --enable-libctf was given.
30288if test "${enable_libctf+set}" = set; then :
30289 enableval=$enable_libctf;
30290 case "$enableval" in
30291 yes|no) ;;
30292 *) as_fn_error $? "Argument to enable/disable libctf must be yes or no" "$LINENO" 5 ;;
30293 esac
30294
30295else
30296 enable_libctf=yes
30297fi
30298
30299
30300if test "${enable_libctf}" = yes; then
30301
30302$as_echo "#define ENABLE_LIBCTF 1" >>confdefs.h
30303
30304 LIBCTF="../libctf/libctf.la"
30305 CTF_DEPS="../libctf/libctf.la"
30306else
30307 LIBCTF=
30308 CTF_DEPS=
30309fi
30310
30311
30312
30313# If nativefile (NAT_FILE) is not set in configure.nat, we link to an
30314# empty version.
b686ecb5
JM
30315
30316NM_H=
30317rm -f nm.h
30318if test "${nativefile}" != ""; then
30319 case "${nativefile}" in
30320 nm-*.h ) GDB_NM_FILE="config/${gdb_host_cpu}/${nativefile}" ;;
30321 * ) GDB_NM_FILE="${nativefile}"
30322 esac
30323 ac_config_links="$ac_config_links nm.h:$GDB_NM_FILE"
30324
30325
30326cat >>confdefs.h <<_ACEOF
30327#define GDB_NM_FILE "${GDB_NM_FILE}"
30328_ACEOF
30329
30330 NM_H=nm.h
30331fi
30332
30333
30334
30335for ac_prog in xsltproc
30336do
30337 # Extract the first word of "$ac_prog", so it can be a program name with args.
30338set dummy $ac_prog; ac_word=$2
30339{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
30340$as_echo_n "checking for $ac_word... " >&6; }
30341if ${ac_cv_path_XSLTPROC+:} false; then :
30342 $as_echo_n "(cached) " >&6
30343else
30344 case $XSLTPROC in
30345 [\\/]* | ?:[\\/]*)
30346 ac_cv_path_XSLTPROC="$XSLTPROC" # Let the user override the test with a path.
30347 ;;
30348 *)
30349 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
30350for as_dir in $PATH
30351do
30352 IFS=$as_save_IFS
30353 test -z "$as_dir" && as_dir=.
30354 for ac_exec_ext in '' $ac_executable_extensions; do
30355 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
30356 ac_cv_path_XSLTPROC="$as_dir/$ac_word$ac_exec_ext"
30357 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
30358 break 2
30359 fi
30360done
30361 done
30362IFS=$as_save_IFS
30363
30364 ;;
30365esac
30366fi
30367XSLTPROC=$ac_cv_path_XSLTPROC
30368if test -n "$XSLTPROC"; then
30369 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XSLTPROC" >&5
30370$as_echo "$XSLTPROC" >&6; }
30371else
30372 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30373$as_echo "no" >&6; }
30374fi
30375
30376
30377 test -n "$XSLTPROC" && break
30378done
30379test -n "$XSLTPROC" || XSLTPROC="missing"
30380
30381if test "x$USE_MAINTAINER_MODE" = xyes; then
30382 if test "${XSLTPROC}" = missing; then
30383 as_fn_error $? "unable to find xsltproc. maintainer-mode requires xsltproc." "$LINENO" 5
30384 fi
30385fi
30386
30387
30388
30389
30390
30391$as_echo "#define GDB_DEFAULT_HOST_CHARSET \"UTF-8\"" >>confdefs.h
30392
30393
30394
30395# Check whether we will enable the inclusion of unit tests when
30396# compiling GDB.
30397#
30398# The default value of this option changes depending whether we're on
30399# development mode (in which case it's "true") or not (in which case
30400# it's "false"). The $development variable is set by the GDB_AC_COMMON
30401# macro, which must therefore be used before GDB_AC_SELFTEST.
30402
30403if test "x$development" != xtrue && test "x$development" != xfalse; then :
30404 as_fn_error $? "Invalid value for \$development, got \"$development\", expecting \"true\" or \"false\"." "$LINENO" 5
30405fi
30406
30407# Check whether --enable-unit-tests was given.
30408if test "${enable_unit_tests+set}" = set; then :
30409 enableval=$enable_unit_tests; case "${enableval}" in
30410 yes) enable_unittests=true ;;
30411 no) enable_unittests=false ;;
30412 *) as_fn_error $? "bad value ${enableval} for --{enable,disable}-unit-tests option" "$LINENO" 5 ;;
30413esac
30414else
30415 enable_unittests=$development
30416fi
30417
30418
30419if $enable_unittests; then
30420
30421$as_echo "#define GDB_SELF_TEST 1" >>confdefs.h
30422
30423
30424 CONFIG_OBS="$CONFIG_OBS \$(SELFTESTS_OBS)"
30425 CONFIG_SRCS="$CONFIG_SRCS \$(SELFTESTS_SRCS)"
30426
30427fi
30428
30429
30430
30431 gdb_ac_transform=`echo "$program_transform_name" | sed -e 's/\\$\\$/\\$/g'`
30432 GDB_TRANSFORM_NAME=`echo gdb | sed -e "$gdb_ac_transform"`
30433 if test "x$GDB_TRANSFORM_NAME" = x; then
30434 GDB_TRANSFORM_NAME=gdb
30435 fi
30436
30437
30438
30439 gdb_ac_transform=`echo "$program_transform_name" | sed -e 's/\\$\\$/\\$/g'`
30440 GCORE_TRANSFORM_NAME=`echo gcore | sed -e "$gdb_ac_transform"`
30441 if test "x$GCORE_TRANSFORM_NAME" = x; then
30442 GCORE_TRANSFORM_NAME=gcore
393fd4c3
YQ
30443 fi
30444
30445
b686ecb5 30446ac_config_files="$ac_config_files gcore"
393fd4c3 30447
b686ecb5 30448ac_config_files="$ac_config_files Makefile gdb-gdb.gdb gdb-gdb.py doc/Makefile data-directory/Makefile"
393fd4c3 30449
393fd4c3 30450
b686ecb5
JM
30451cat >confcache <<\_ACEOF
30452# This file is a shell script that caches the results of configure
30453# tests run on this system so they can be shared between configure
30454# scripts and configure runs, see configure's option --config-cache.
30455# It is not useful on other systems. If it contains results you don't
30456# want to keep, you may remove or edit it.
30457#
30458# config.status only pays attention to the cache file if you give it
30459# the --recheck option to rerun configure.
30460#
30461# `ac_cv_env_foo' variables (set or unset) will be overridden when
30462# loading this file, other *unset* `ac_cv_foo' will be assigned the
30463# following values.
30464
30465_ACEOF
30466
30467# The following way of writing the cache mishandles newlines in values,
30468# but we know of no workaround that is simple, portable, and efficient.
30469# So, we kill variables containing newlines.
30470# Ultrix sh set writes to stderr and can't be redirected directly,
30471# and sets the high bit in the cache file unless we assign to the vars.
30472(
30473 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
30474 eval ac_val=\$$ac_var
30475 case $ac_val in #(
30476 *${as_nl}*)
30477 case $ac_var in #(
30478 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
30479$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
30480 esac
30481 case $ac_var in #(
30482 _ | IFS | as_nl) ;; #(
30483 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
30484 *) { eval $ac_var=; unset $ac_var;} ;;
30485 esac ;;
30486 esac
30487 done
30488
30489 (set) 2>&1 |
30490 case $as_nl`(ac_space=' '; set) 2>&1` in #(
30491 *${as_nl}ac_space=\ *)
30492 # `set' does not quote correctly, so add quotes: double-quote
30493 # substitution turns \\\\ into \\, and sed turns \\ into \.
30494 sed -n \
30495 "s/'/'\\\\''/g;
30496 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
30497 ;; #(
30498 *)
30499 # `set' quotes correctly as required by POSIX, so do not add quotes.
30500 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
30501 ;;
30502 esac |
30503 sort
30504) |
30505 sed '
30506 /^ac_cv_env_/b end
30507 t clear
30508 :clear
30509 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
30510 t end
30511 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
30512 :end' >>confcache
30513if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
30514 if test -w "$cache_file"; then
30515 if test "x$cache_file" != "x/dev/null"; then
30516 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
30517$as_echo "$as_me: updating cache $cache_file" >&6;}
30518 if test ! -f "$cache_file" || test -h "$cache_file"; then
30519 cat confcache >"$cache_file"
30520 else
30521 case $cache_file in #(
30522 */* | ?:*)
30523 mv -f confcache "$cache_file"$$ &&
30524 mv -f "$cache_file"$$ "$cache_file" ;; #(
30525 *)
30526 mv -f confcache "$cache_file" ;;
30527 esac
393fd4c3 30528 fi
393fd4c3 30529 fi
b686ecb5
JM
30530 else
30531 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
30532$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
30533 fi
30534fi
30535rm -f confcache
30536
30537test "x$prefix" = xNONE && prefix=$ac_default_prefix
30538# Let make expand exec_prefix.
30539test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
30540
30541DEFS=-DHAVE_CONFIG_H
30542
30543ac_libobjs=
30544ac_ltlibobjs=
30545U=
30546for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
30547 # 1. Remove the extension, and $U if already installed.
30548 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
30549 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
30550 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
30551 # will be set to the directory where LIBOBJS objects are built.
30552 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
30553 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
30554done
30555LIBOBJS=$ac_libobjs
30556
30557LTLIBOBJS=$ac_ltlibobjs
30558
30559
30560if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
30561 as_fn_error $? "conditional \"MAINTAINER_MODE\" was never defined.
30562Usually this means the macro was only invoked conditionally." "$LINENO" 5
30563fi
30564if test -z "${ENABLE_BFD_64_BIT_TRUE}" && test -z "${ENABLE_BFD_64_BIT_FALSE}"; then
30565 as_fn_error $? "conditional \"ENABLE_BFD_64_BIT\" was never defined.
30566Usually this means the macro was only invoked conditionally." "$LINENO" 5
30567fi
30568if test -z "${HAVE_PYTHON_TRUE}" && test -z "${HAVE_PYTHON_FALSE}"; then
30569 as_fn_error $? "conditional \"HAVE_PYTHON\" was never defined.
30570Usually this means the macro was only invoked conditionally." "$LINENO" 5
30571fi
30572if test -z "${HAVE_GUILE_TRUE}" && test -z "${HAVE_GUILE_FALSE}"; then
30573 as_fn_error $? "conditional \"HAVE_GUILE\" was never defined.
30574Usually this means the macro was only invoked conditionally." "$LINENO" 5
30575fi
30576
30577
30578: "${CONFIG_STATUS=./config.status}"
30579ac_write_fail=0
30580ac_clean_files_save=$ac_clean_files
30581ac_clean_files="$ac_clean_files $CONFIG_STATUS"
30582{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
30583$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
30584as_write_fail=0
30585cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
30586#! $SHELL
30587# Generated by $as_me.
30588# Run this file to recreate the current configuration.
30589# Compiler output produced by configure, useful for debugging
30590# configure, is in config.log if it exists.
30591
30592debug=false
30593ac_cs_recheck=false
30594ac_cs_silent=false
30595
30596SHELL=\${CONFIG_SHELL-$SHELL}
30597export SHELL
30598_ASEOF
30599cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
30600## -------------------- ##
30601## M4sh Initialization. ##
30602## -------------------- ##
30603
30604# Be more Bourne compatible
30605DUALCASE=1; export DUALCASE # for MKS sh
30606if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
30607 emulate sh
30608 NULLCMD=:
30609 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
30610 # is contrary to our usage. Disable this feature.
30611 alias -g '${1+"$@"}'='"$@"'
30612 setopt NO_GLOB_SUBST
30613else
30614 case `(set -o) 2>/dev/null` in #(
30615 *posix*) :
30616 set -o posix ;; #(
30617 *) :
30618 ;;
30619esac
30620fi
30621
30622
30623as_nl='
30624'
30625export as_nl
30626# Printing a long string crashes Solaris 7 /usr/bin/printf.
30627as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
30628as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
30629as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
30630# Prefer a ksh shell builtin over an external printf program on Solaris,
30631# but without wasting forks for bash or zsh.
30632if test -z "$BASH_VERSION$ZSH_VERSION" \
30633 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
30634 as_echo='print -r --'
30635 as_echo_n='print -rn --'
30636elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
30637 as_echo='printf %s\n'
30638 as_echo_n='printf %s'
30639else
30640 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
30641 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
30642 as_echo_n='/usr/ucb/echo -n'
30643 else
30644 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
30645 as_echo_n_body='eval
30646 arg=$1;
30647 case $arg in #(
30648 *"$as_nl"*)
30649 expr "X$arg" : "X\\(.*\\)$as_nl";
30650 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
30651 esac;
30652 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
30653 '
30654 export as_echo_n_body
30655 as_echo_n='sh -c $as_echo_n_body as_echo'
30656 fi
30657 export as_echo_body
30658 as_echo='sh -c $as_echo_body as_echo'
30659fi
393fd4c3 30660
b686ecb5
JM
30661# The user is always right.
30662if test "${PATH_SEPARATOR+set}" != set; then
30663 PATH_SEPARATOR=:
30664 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
30665 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
30666 PATH_SEPARATOR=';'
30667 }
30668fi
393fd4c3 30669
393fd4c3 30670
b686ecb5
JM
30671# IFS
30672# We need space, tab and new line, in precisely that order. Quoting is
30673# there to prevent editors from complaining about space-tab.
30674# (If _AS_PATH_WALK were called with IFS unset, it would disable word
30675# splitting by setting IFS to empty value.)
30676IFS=" "" $as_nl"
393fd4c3 30677
b686ecb5
JM
30678# Find who we are. Look in the path if we contain no directory separator.
30679as_myself=
30680case $0 in #((
30681 *[\\/]* ) as_myself=$0 ;;
30682 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
30683for as_dir in $PATH
30684do
30685 IFS=$as_save_IFS
30686 test -z "$as_dir" && as_dir=.
30687 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
30688 done
30689IFS=$as_save_IFS
393fd4c3 30690
b686ecb5
JM
30691 ;;
30692esac
30693# We did not find ourselves, most probably we were run as `sh COMMAND'
30694# in which case we are not to be found in the path.
30695if test "x$as_myself" = x; then
30696 as_myself=$0
393fd4c3 30697fi
b686ecb5
JM
30698if test ! -f "$as_myself"; then
30699 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
30700 exit 1
393fd4c3 30701fi
393fd4c3 30702
b686ecb5
JM
30703# Unset variables that we do not need and which cause bugs (e.g. in
30704# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
30705# suppresses any "Segmentation fault" message there. '((' could
30706# trigger a bug in pdksh 5.2.14.
30707for as_var in BASH_ENV ENV MAIL MAILPATH
30708do eval test x\${$as_var+set} = xset \
30709 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
30710done
30711PS1='$ '
30712PS2='> '
30713PS4='+ '
393fd4c3 30714
b686ecb5
JM
30715# NLS nuisances.
30716LC_ALL=C
30717export LC_ALL
30718LANGUAGE=C
30719export LANGUAGE
393fd4c3 30720
b686ecb5
JM
30721# CDPATH.
30722(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
393fd4c3
YQ
30723
30724
b686ecb5
JM
30725# as_fn_error STATUS ERROR [LINENO LOG_FD]
30726# ----------------------------------------
30727# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
30728# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
30729# script with STATUS, using 1 if that was 0.
30730as_fn_error ()
30731{
30732 as_status=$1; test $as_status -eq 0 && as_status=1
30733 if test "$4"; then
30734 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
30735 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
30736 fi
30737 $as_echo "$as_me: error: $2" >&2
30738 as_fn_exit $as_status
30739} # as_fn_error
30740
393fd4c3 30741
b686ecb5
JM
30742# as_fn_set_status STATUS
30743# -----------------------
30744# Set $? to STATUS, without forking.
30745as_fn_set_status ()
30746{
30747 return $1
30748} # as_fn_set_status
393fd4c3 30749
b686ecb5
JM
30750# as_fn_exit STATUS
30751# -----------------
30752# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
30753as_fn_exit ()
30754{
30755 set +e
30756 as_fn_set_status $1
30757 exit $1
30758} # as_fn_exit
393fd4c3 30759
b686ecb5
JM
30760# as_fn_unset VAR
30761# ---------------
30762# Portably unset VAR.
30763as_fn_unset ()
30764{
30765 { eval $1=; unset $1;}
30766}
30767as_unset=as_fn_unset
30768# as_fn_append VAR VALUE
30769# ----------------------
30770# Append the text in VALUE to the end of the definition contained in VAR. Take
30771# advantage of any shell optimizations that allow amortized linear growth over
30772# repeated appends, instead of the typical quadratic growth present in naive
30773# implementations.
30774if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
30775 eval 'as_fn_append ()
30776 {
30777 eval $1+=\$2
30778 }'
30779else
30780 as_fn_append ()
30781 {
30782 eval $1=\$$1\$2
30783 }
30784fi # as_fn_append
393fd4c3 30785
b686ecb5
JM
30786# as_fn_arith ARG...
30787# ------------------
30788# Perform arithmetic evaluation on the ARGs, and store the result in the
30789# global $as_val. Take advantage of shells that can avoid forks. The arguments
30790# must be portable across $(()) and expr.
30791if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
30792 eval 'as_fn_arith ()
30793 {
30794 as_val=$(( $* ))
30795 }'
30796else
30797 as_fn_arith ()
30798 {
30799 as_val=`expr "$@" || test $? -eq 1`
30800 }
30801fi # as_fn_arith
393fd4c3 30802
ccb1ba62 30803
b686ecb5
JM
30804if expr a : '\(a\)' >/dev/null 2>&1 &&
30805 test "X`expr 00001 : '.*\(...\)'`" = X001; then
30806 as_expr=expr
ccb1ba62 30807else
b686ecb5 30808 as_expr=false
ccb1ba62
CB
30809fi
30810
b686ecb5
JM
30811if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
30812 as_basename=basename
30813else
30814 as_basename=false
30815fi
ccb1ba62 30816
b686ecb5
JM
30817if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
30818 as_dirname=dirname
1776e3e5 30819else
b686ecb5 30820 as_dirname=false
1776e3e5
NA
30821fi
30822
b686ecb5
JM
30823as_me=`$as_basename -- "$0" ||
30824$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
30825 X"$0" : 'X\(//\)$' \| \
30826 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
30827$as_echo X/"$0" |
30828 sed '/^.*\/\([^/][^/]*\)\/*$/{
30829 s//\1/
30830 q
30831 }
30832 /^X\/\(\/\/\)$/{
30833 s//\1/
30834 q
30835 }
30836 /^X\/\(\/\).*/{
30837 s//\1/
30838 q
30839 }
30840 s/.*/./; q'`
30841
30842# Avoid depending upon Character Ranges.
30843as_cr_letters='abcdefghijklmnopqrstuvwxyz'
30844as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
30845as_cr_Letters=$as_cr_letters$as_cr_LETTERS
30846as_cr_digits='0123456789'
30847as_cr_alnum=$as_cr_Letters$as_cr_digits
30848
30849ECHO_C= ECHO_N= ECHO_T=
30850case `echo -n x` in #(((((
30851-n*)
30852 case `echo 'xy\c'` in
30853 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
30854 xy) ECHO_C='\c';;
30855 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
30856 ECHO_T=' ';;
30857 esac;;
30858*)
30859 ECHO_N='-n';;
30860esac
1776e3e5 30861
b686ecb5
JM
30862rm -f conf$$ conf$$.exe conf$$.file
30863if test -d conf$$.dir; then
30864 rm -f conf$$.dir/conf$$.file
1776e3e5 30865else
b686ecb5
JM
30866 rm -f conf$$.dir
30867 mkdir conf$$.dir 2>/dev/null
1776e3e5 30868fi
b686ecb5
JM
30869if (echo >conf$$.file) 2>/dev/null; then
30870 if ln -s conf$$.file conf$$ 2>/dev/null; then
30871 as_ln_s='ln -s'
30872 # ... but there are two gotchas:
30873 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
30874 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
30875 # In both cases, we have to default to `cp -pR'.
30876 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
30877 as_ln_s='cp -pR'
30878 elif ln conf$$.file conf$$ 2>/dev/null; then
30879 as_ln_s=ln
30880 else
30881 as_ln_s='cp -pR'
30882 fi
1776e3e5 30883else
b686ecb5 30884 as_ln_s='cp -pR'
1776e3e5 30885fi
b686ecb5
JM
30886rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
30887rmdir conf$$.dir 2>/dev/null
1776e3e5
NA
30888
30889
b686ecb5
JM
30890# as_fn_mkdir_p
30891# -------------
30892# Create "$as_dir" as a directory, including parents if necessary.
30893as_fn_mkdir_p ()
30894{
1776e3e5 30895
b686ecb5
JM
30896 case $as_dir in #(
30897 -*) as_dir=./$as_dir;;
30898 esac
30899 test -d "$as_dir" || eval $as_mkdir_p || {
30900 as_dirs=
30901 while :; do
30902 case $as_dir in #(
30903 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
30904 *) as_qdir=$as_dir;;
30905 esac
30906 as_dirs="'$as_qdir' $as_dirs"
30907 as_dir=`$as_dirname -- "$as_dir" ||
30908$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30909 X"$as_dir" : 'X\(//\)[^/]' \| \
30910 X"$as_dir" : 'X\(//\)$' \| \
30911 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
30912$as_echo X"$as_dir" |
30913 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30914 s//\1/
30915 q
30916 }
30917 /^X\(\/\/\)[^/].*/{
30918 s//\1/
30919 q
30920 }
30921 /^X\(\/\/\)$/{
30922 s//\1/
30923 q
30924 }
30925 /^X\(\/\).*/{
30926 s//\1/
30927 q
30928 }
30929 s/.*/./; q'`
30930 test -d "$as_dir" && break
30931 done
30932 test -z "$as_dirs" || eval "mkdir $as_dirs"
30933 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
ccb1ba62 30934
9f1528a1 30935
b686ecb5
JM
30936} # as_fn_mkdir_p
30937if mkdir -p . 2>/dev/null; then
30938 as_mkdir_p='mkdir -p "$as_dir"'
9f1528a1 30939else
b686ecb5
JM
30940 test -d ./-p && rmdir ./-p
30941 as_mkdir_p=false
9f1528a1
AB
30942fi
30943
ccb1ba62 30944
b686ecb5
JM
30945# as_fn_executable_p FILE
30946# -----------------------
30947# Test if FILE is an executable regular file.
30948as_fn_executable_p ()
30949{
30950 test -f "$1" && test -x "$1"
30951} # as_fn_executable_p
30952as_test_x='test -x'
30953as_executable_p=as_fn_executable_p
ccb1ba62 30954
b686ecb5
JM
30955# Sed expression to map a string onto a valid CPP name.
30956as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
ccb1ba62 30957
b686ecb5
JM
30958# Sed expression to map a string onto a valid variable name.
30959as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
ccb1ba62 30960
ccb1ba62 30961
b686ecb5
JM
30962exec 6>&1
30963## ----------------------------------- ##
30964## Main body of $CONFIG_STATUS script. ##
30965## ----------------------------------- ##
30966_ASEOF
30967test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
ccb1ba62 30968
b686ecb5
JM
30969cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30970# Save the log message, to keep $0 and so on meaningful, and to
30971# report actual input values of CONFIG_FILES etc. instead of their
30972# values after options handling.
30973ac_log="
30974This file was extended by $as_me, which was
30975generated by GNU Autoconf 2.69. Invocation command line was
ccb1ba62 30976
b686ecb5
JM
30977 CONFIG_FILES = $CONFIG_FILES
30978 CONFIG_HEADERS = $CONFIG_HEADERS
30979 CONFIG_LINKS = $CONFIG_LINKS
30980 CONFIG_COMMANDS = $CONFIG_COMMANDS
30981 $ $0 $@
ccb1ba62 30982
b686ecb5
JM
30983on `(hostname || uname -n) 2>/dev/null | sed 1q`
30984"
ccb1ba62 30985
b686ecb5
JM
30986_ACEOF
30987
30988case $ac_config_files in *"
30989"*) set x $ac_config_files; shift; ac_config_files=$*;;
30990esac
30991
30992case $ac_config_headers in *"
30993"*) set x $ac_config_headers; shift; ac_config_headers=$*;;
30994esac
30995
30996
30997cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30998# Files that config.status was made for.
30999config_files="$ac_config_files"
31000config_headers="$ac_config_headers"
31001config_links="$ac_config_links"
31002config_commands="$ac_config_commands"
31003
31004_ACEOF
ccb1ba62 31005
b686ecb5
JM
31006cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
31007ac_cs_usage="\
31008\`$as_me' instantiates files and other configuration actions
31009from templates according to the current configuration. Unless the files
31010and actions are specified as TAGs, all are instantiated by default.
ccb1ba62 31011
b686ecb5 31012Usage: $0 [OPTION]... [TAG]...
ccb1ba62 31013
b686ecb5
JM
31014 -h, --help print this help, then exit
31015 -V, --version print version number and configuration settings, then exit
31016 --config print configuration, then exit
31017 -q, --quiet, --silent
31018 do not print progress messages
31019 -d, --debug don't remove temporary files
31020 --recheck update $as_me by reconfiguring in the same conditions
31021 --file=FILE[:TEMPLATE]
31022 instantiate the configuration file FILE
31023 --header=FILE[:TEMPLATE]
31024 instantiate the configuration header FILE
ccb1ba62 31025
b686ecb5
JM
31026Configuration files:
31027$config_files
ccb1ba62 31028
b686ecb5
JM
31029Configuration headers:
31030$config_headers
ccb1ba62 31031
b686ecb5
JM
31032Configuration links:
31033$config_links
ccb1ba62 31034
b686ecb5
JM
31035Configuration commands:
31036$config_commands
ccb1ba62 31037
b686ecb5 31038Report bugs to the package provider."
ccb1ba62 31039
ccb1ba62 31040_ACEOF
b686ecb5
JM
31041cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
31042ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
31043ac_cs_version="\\
31044config.status
31045configured by $0, generated by GNU Autoconf 2.69,
31046 with options \\"\$ac_cs_config\\"
ccb1ba62 31047
b686ecb5
JM
31048Copyright (C) 2012 Free Software Foundation, Inc.
31049This config.status script is free software; the Free Software Foundation
31050gives unlimited permission to copy, distribute and modify it."
ccb1ba62 31051
b686ecb5
JM
31052ac_pwd='$ac_pwd'
31053srcdir='$srcdir'
31054INSTALL='$INSTALL'
31055AWK='$AWK'
31056test -n "\$AWK" || AWK=awk
31057_ACEOF
ccb1ba62 31058
b686ecb5
JM
31059cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
31060# The default lists apply if the user does not specify any file.
31061ac_need_defaults=:
31062while test $# != 0
31063do
31064 case $1 in
31065 --*=?*)
31066 ac_option=`expr "X$1" : 'X\([^=]*\)='`
31067 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
31068 ac_shift=:
31069 ;;
31070 --*=)
31071 ac_option=`expr "X$1" : 'X\([^=]*\)='`
31072 ac_optarg=
31073 ac_shift=:
31074 ;;
31075 *)
31076 ac_option=$1
31077 ac_optarg=$2
31078 ac_shift=shift
31079 ;;
31080 esac
ccb1ba62 31081
b686ecb5
JM
31082 case $ac_option in
31083 # Handling of the options.
31084 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
31085 ac_cs_recheck=: ;;
31086 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
31087 $as_echo "$ac_cs_version"; exit ;;
31088 --config | --confi | --conf | --con | --co | --c )
31089 $as_echo "$ac_cs_config"; exit ;;
31090 --debug | --debu | --deb | --de | --d | -d )
31091 debug=: ;;
31092 --file | --fil | --fi | --f )
31093 $ac_shift
31094 case $ac_optarg in
31095 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
31096 '') as_fn_error $? "missing file argument" ;;
31097 esac
31098 as_fn_append CONFIG_FILES " '$ac_optarg'"
31099 ac_need_defaults=false;;
31100 --header | --heade | --head | --hea )
31101 $ac_shift
31102 case $ac_optarg in
31103 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
31104 esac
31105 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
31106 ac_need_defaults=false;;
31107 --he | --h)
31108 # Conflict between --help and --header
31109 as_fn_error $? "ambiguous option: \`$1'
31110Try \`$0 --help' for more information.";;
31111 --help | --hel | -h )
31112 $as_echo "$ac_cs_usage"; exit ;;
31113 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
31114 | -silent | --silent | --silen | --sile | --sil | --si | --s)
31115 ac_cs_silent=: ;;
ccb1ba62 31116
b686ecb5
JM
31117 # This is an error.
31118 -*) as_fn_error $? "unrecognized option: \`$1'
31119Try \`$0 --help' for more information." ;;
ccb1ba62 31120
b686ecb5
JM
31121 *) as_fn_append ac_config_targets " $1"
31122 ac_need_defaults=false ;;
ccb1ba62 31123
b686ecb5
JM
31124 esac
31125 shift
31126done
ccb1ba62 31127
b686ecb5 31128ac_configure_extra_args=
ccb1ba62 31129
b686ecb5
JM
31130if $ac_cs_silent; then
31131 exec 6>/dev/null
31132 ac_configure_extra_args="$ac_configure_extra_args --silent"
ccb1ba62
CB
31133fi
31134
b686ecb5
JM
31135_ACEOF
31136cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
31137if \$ac_cs_recheck; then
31138 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
31139 shift
31140 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
31141 CONFIG_SHELL='$SHELL'
31142 export CONFIG_SHELL
31143 exec "\$@"
31144fi
a0a461e5 31145
b686ecb5
JM
31146_ACEOF
31147cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
31148exec 5>>config.log
31149{
31150 echo
31151 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
31152## Running $as_me. ##
31153_ASBOX
31154 $as_echo "$ac_log"
31155} >&5
60ca704f 31156
bec39cab 31157_ACEOF
b686ecb5
JM
31158cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
31159#
31160# INIT-COMMANDS
31161#
5a2402b8 31162
5a2402b8 31163
b686ecb5
JM
31164# The HP-UX ksh and POSIX shell print the target directory to stdout
31165# if CDPATH is set.
31166(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
5a2402b8 31167
b686ecb5
JM
31168sed_quote_subst='$sed_quote_subst'
31169double_quote_subst='$double_quote_subst'
31170delay_variable_subst='$delay_variable_subst'
31171macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`'
31172macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`'
31173enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`'
31174enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`'
31175pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`'
31176enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`'
31177SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`'
31178ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`'
31179host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`'
31180host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`'
31181host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`'
31182build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`'
31183build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`'
31184build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`'
31185SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`'
31186Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`'
31187GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`'
31188EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`'
31189FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`'
31190LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`'
31191NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`'
31192LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`'
31193max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`'
31194ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`'
31195exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
31196lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
31197lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
31198lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
31199reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`'
31200reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`'
31201OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`'
31202deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`'
31203file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`'
31204AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`'
31205AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`'
31206STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
31207RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
31208old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
31209old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
31210old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`'
31211lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`'
31212CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`'
31213CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`'
31214compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`'
31215GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`'
31216lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`'
31217lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
31218lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
31219lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
31220objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`'
31221MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`'
31222lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`'
31223lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
31224lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`'
31225lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`'
31226lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`'
31227need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`'
31228DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
31229NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
31230LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
31231OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`'
31232OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`'
31233libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`'
31234shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`'
31235extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
31236archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`'
31237enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`'
31238export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`'
31239whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`'
31240compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`'
31241old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`'
31242old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
31243archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`'
31244archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`'
31245module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`'
31246module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`'
31247with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`'
31248allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`'
31249no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`'
31250hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`'
31251hardcode_libdir_flag_spec_ld='`$ECHO "$hardcode_libdir_flag_spec_ld" | $SED "$delay_single_quote_subst"`'
31252hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`'
31253hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`'
31254hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`'
31255hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`'
31256hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`'
31257hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
31258inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
31259link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
31260fix_srcfile_path='`$ECHO "$fix_srcfile_path" | $SED "$delay_single_quote_subst"`'
31261always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`'
31262export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`'
31263exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`'
31264include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`'
31265prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`'
31266file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
31267variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
31268need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
31269need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`'
31270version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`'
31271runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`'
31272shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`'
31273shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`'
31274libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`'
31275library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`'
31276soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`'
31277install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`'
31278postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`'
31279postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
31280finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`'
31281finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`'
31282hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`'
31283sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`'
31284sys_lib_dlsearch_path_spec='`$ECHO "$sys_lib_dlsearch_path_spec" | $SED "$delay_single_quote_subst"`'
31285hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`'
31286enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`'
31287enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`'
31288enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`'
31289old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`'
31290striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`'
31291compiler_lib_search_dirs='`$ECHO "$compiler_lib_search_dirs" | $SED "$delay_single_quote_subst"`'
31292predep_objects='`$ECHO "$predep_objects" | $SED "$delay_single_quote_subst"`'
31293postdep_objects='`$ECHO "$postdep_objects" | $SED "$delay_single_quote_subst"`'
31294predeps='`$ECHO "$predeps" | $SED "$delay_single_quote_subst"`'
31295postdeps='`$ECHO "$postdeps" | $SED "$delay_single_quote_subst"`'
31296compiler_lib_search_path='`$ECHO "$compiler_lib_search_path" | $SED "$delay_single_quote_subst"`'
31297LD_CXX='`$ECHO "$LD_CXX" | $SED "$delay_single_quote_subst"`'
31298reload_flag_CXX='`$ECHO "$reload_flag_CXX" | $SED "$delay_single_quote_subst"`'
31299reload_cmds_CXX='`$ECHO "$reload_cmds_CXX" | $SED "$delay_single_quote_subst"`'
31300old_archive_cmds_CXX='`$ECHO "$old_archive_cmds_CXX" | $SED "$delay_single_quote_subst"`'
31301compiler_CXX='`$ECHO "$compiler_CXX" | $SED "$delay_single_quote_subst"`'
31302GCC_CXX='`$ECHO "$GCC_CXX" | $SED "$delay_single_quote_subst"`'
31303lt_prog_compiler_no_builtin_flag_CXX='`$ECHO "$lt_prog_compiler_no_builtin_flag_CXX" | $SED "$delay_single_quote_subst"`'
31304lt_prog_compiler_wl_CXX='`$ECHO "$lt_prog_compiler_wl_CXX" | $SED "$delay_single_quote_subst"`'
31305lt_prog_compiler_pic_CXX='`$ECHO "$lt_prog_compiler_pic_CXX" | $SED "$delay_single_quote_subst"`'
31306lt_prog_compiler_static_CXX='`$ECHO "$lt_prog_compiler_static_CXX" | $SED "$delay_single_quote_subst"`'
31307lt_cv_prog_compiler_c_o_CXX='`$ECHO "$lt_cv_prog_compiler_c_o_CXX" | $SED "$delay_single_quote_subst"`'
31308archive_cmds_need_lc_CXX='`$ECHO "$archive_cmds_need_lc_CXX" | $SED "$delay_single_quote_subst"`'
31309enable_shared_with_static_runtimes_CXX='`$ECHO "$enable_shared_with_static_runtimes_CXX" | $SED "$delay_single_quote_subst"`'
31310export_dynamic_flag_spec_CXX='`$ECHO "$export_dynamic_flag_spec_CXX" | $SED "$delay_single_quote_subst"`'
31311whole_archive_flag_spec_CXX='`$ECHO "$whole_archive_flag_spec_CXX" | $SED "$delay_single_quote_subst"`'
31312compiler_needs_object_CXX='`$ECHO "$compiler_needs_object_CXX" | $SED "$delay_single_quote_subst"`'
31313old_archive_from_new_cmds_CXX='`$ECHO "$old_archive_from_new_cmds_CXX" | $SED "$delay_single_quote_subst"`'
31314old_archive_from_expsyms_cmds_CXX='`$ECHO "$old_archive_from_expsyms_cmds_CXX" | $SED "$delay_single_quote_subst"`'
31315archive_cmds_CXX='`$ECHO "$archive_cmds_CXX" | $SED "$delay_single_quote_subst"`'
31316archive_expsym_cmds_CXX='`$ECHO "$archive_expsym_cmds_CXX" | $SED "$delay_single_quote_subst"`'
31317module_cmds_CXX='`$ECHO "$module_cmds_CXX" | $SED "$delay_single_quote_subst"`'
31318module_expsym_cmds_CXX='`$ECHO "$module_expsym_cmds_CXX" | $SED "$delay_single_quote_subst"`'
31319with_gnu_ld_CXX='`$ECHO "$with_gnu_ld_CXX" | $SED "$delay_single_quote_subst"`'
31320allow_undefined_flag_CXX='`$ECHO "$allow_undefined_flag_CXX" | $SED "$delay_single_quote_subst"`'
31321no_undefined_flag_CXX='`$ECHO "$no_undefined_flag_CXX" | $SED "$delay_single_quote_subst"`'
31322hardcode_libdir_flag_spec_CXX='`$ECHO "$hardcode_libdir_flag_spec_CXX" | $SED "$delay_single_quote_subst"`'
31323hardcode_libdir_flag_spec_ld_CXX='`$ECHO "$hardcode_libdir_flag_spec_ld_CXX" | $SED "$delay_single_quote_subst"`'
31324hardcode_libdir_separator_CXX='`$ECHO "$hardcode_libdir_separator_CXX" | $SED "$delay_single_quote_subst"`'
31325hardcode_direct_CXX='`$ECHO "$hardcode_direct_CXX" | $SED "$delay_single_quote_subst"`'
31326hardcode_direct_absolute_CXX='`$ECHO "$hardcode_direct_absolute_CXX" | $SED "$delay_single_quote_subst"`'
31327hardcode_minus_L_CXX='`$ECHO "$hardcode_minus_L_CXX" | $SED "$delay_single_quote_subst"`'
31328hardcode_shlibpath_var_CXX='`$ECHO "$hardcode_shlibpath_var_CXX" | $SED "$delay_single_quote_subst"`'
31329hardcode_automatic_CXX='`$ECHO "$hardcode_automatic_CXX" | $SED "$delay_single_quote_subst"`'
31330inherit_rpath_CXX='`$ECHO "$inherit_rpath_CXX" | $SED "$delay_single_quote_subst"`'
31331link_all_deplibs_CXX='`$ECHO "$link_all_deplibs_CXX" | $SED "$delay_single_quote_subst"`'
31332fix_srcfile_path_CXX='`$ECHO "$fix_srcfile_path_CXX" | $SED "$delay_single_quote_subst"`'
31333always_export_symbols_CXX='`$ECHO "$always_export_symbols_CXX" | $SED "$delay_single_quote_subst"`'
31334export_symbols_cmds_CXX='`$ECHO "$export_symbols_cmds_CXX" | $SED "$delay_single_quote_subst"`'
31335exclude_expsyms_CXX='`$ECHO "$exclude_expsyms_CXX" | $SED "$delay_single_quote_subst"`'
31336include_expsyms_CXX='`$ECHO "$include_expsyms_CXX" | $SED "$delay_single_quote_subst"`'
31337prelink_cmds_CXX='`$ECHO "$prelink_cmds_CXX" | $SED "$delay_single_quote_subst"`'
31338file_list_spec_CXX='`$ECHO "$file_list_spec_CXX" | $SED "$delay_single_quote_subst"`'
31339hardcode_action_CXX='`$ECHO "$hardcode_action_CXX" | $SED "$delay_single_quote_subst"`'
31340compiler_lib_search_dirs_CXX='`$ECHO "$compiler_lib_search_dirs_CXX" | $SED "$delay_single_quote_subst"`'
31341predep_objects_CXX='`$ECHO "$predep_objects_CXX" | $SED "$delay_single_quote_subst"`'
31342postdep_objects_CXX='`$ECHO "$postdep_objects_CXX" | $SED "$delay_single_quote_subst"`'
31343predeps_CXX='`$ECHO "$predeps_CXX" | $SED "$delay_single_quote_subst"`'
31344postdeps_CXX='`$ECHO "$postdeps_CXX" | $SED "$delay_single_quote_subst"`'
31345compiler_lib_search_path_CXX='`$ECHO "$compiler_lib_search_path_CXX" | $SED "$delay_single_quote_subst"`'
31346
31347LTCC='$LTCC'
31348LTCFLAGS='$LTCFLAGS'
31349compiler='$compiler_DEFAULT'
31350
31351# A function that is used when there is no print builtin or printf.
31352func_fallback_echo ()
31353{
31354 eval 'cat <<_LTECHO_EOF
31355\$1
31356_LTECHO_EOF'
31357}
a0a461e5 31358
b686ecb5
JM
31359# Quote evaled strings.
31360for var in SHELL \
31361ECHO \
31362SED \
31363GREP \
31364EGREP \
31365FGREP \
31366LD \
31367NM \
31368LN_S \
31369lt_SP2NL \
31370lt_NL2SP \
31371reload_flag \
31372OBJDUMP \
31373deplibs_check_method \
31374file_magic_cmd \
31375AR \
31376AR_FLAGS \
31377STRIP \
31378RANLIB \
31379CC \
31380CFLAGS \
31381compiler \
31382lt_cv_sys_global_symbol_pipe \
31383lt_cv_sys_global_symbol_to_cdecl \
31384lt_cv_sys_global_symbol_to_c_name_address \
31385lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
31386lt_prog_compiler_no_builtin_flag \
31387lt_prog_compiler_wl \
31388lt_prog_compiler_pic \
31389lt_prog_compiler_static \
31390lt_cv_prog_compiler_c_o \
31391need_locks \
31392DSYMUTIL \
31393NMEDIT \
31394LIPO \
31395OTOOL \
31396OTOOL64 \
31397shrext_cmds \
31398export_dynamic_flag_spec \
31399whole_archive_flag_spec \
31400compiler_needs_object \
31401with_gnu_ld \
31402allow_undefined_flag \
31403no_undefined_flag \
31404hardcode_libdir_flag_spec \
31405hardcode_libdir_flag_spec_ld \
31406hardcode_libdir_separator \
31407fix_srcfile_path \
31408exclude_expsyms \
31409include_expsyms \
31410file_list_spec \
31411variables_saved_for_relink \
31412libname_spec \
31413library_names_spec \
31414soname_spec \
31415install_override_mode \
31416finish_eval \
31417old_striplib \
31418striplib \
31419compiler_lib_search_dirs \
31420predep_objects \
31421postdep_objects \
31422predeps \
31423postdeps \
31424compiler_lib_search_path \
31425LD_CXX \
31426reload_flag_CXX \
31427compiler_CXX \
31428lt_prog_compiler_no_builtin_flag_CXX \
31429lt_prog_compiler_wl_CXX \
31430lt_prog_compiler_pic_CXX \
31431lt_prog_compiler_static_CXX \
31432lt_cv_prog_compiler_c_o_CXX \
31433export_dynamic_flag_spec_CXX \
31434whole_archive_flag_spec_CXX \
31435compiler_needs_object_CXX \
31436with_gnu_ld_CXX \
31437allow_undefined_flag_CXX \
31438no_undefined_flag_CXX \
31439hardcode_libdir_flag_spec_CXX \
31440hardcode_libdir_flag_spec_ld_CXX \
31441hardcode_libdir_separator_CXX \
31442fix_srcfile_path_CXX \
31443exclude_expsyms_CXX \
31444include_expsyms_CXX \
31445file_list_spec_CXX \
31446compiler_lib_search_dirs_CXX \
31447predep_objects_CXX \
31448postdep_objects_CXX \
31449predeps_CXX \
31450postdeps_CXX \
31451compiler_lib_search_path_CXX; do
31452 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
31453 *[\\\\\\\`\\"\\\$]*)
31454 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
31455 ;;
31456 *)
31457 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
31458 ;;
31459 esac
31460done
31461
31462# Double-quote double-evaled strings.
31463for var in reload_cmds \
31464old_postinstall_cmds \
31465old_postuninstall_cmds \
31466old_archive_cmds \
31467extract_expsyms_cmds \
31468old_archive_from_new_cmds \
31469old_archive_from_expsyms_cmds \
31470archive_cmds \
31471archive_expsym_cmds \
31472module_cmds \
31473module_expsym_cmds \
31474export_symbols_cmds \
31475prelink_cmds \
31476postinstall_cmds \
31477postuninstall_cmds \
31478finish_cmds \
31479sys_lib_search_path_spec \
31480sys_lib_dlsearch_path_spec \
31481reload_cmds_CXX \
31482old_archive_cmds_CXX \
31483old_archive_from_new_cmds_CXX \
31484old_archive_from_expsyms_cmds_CXX \
31485archive_cmds_CXX \
31486archive_expsym_cmds_CXX \
31487module_cmds_CXX \
31488module_expsym_cmds_CXX \
31489export_symbols_cmds_CXX \
31490prelink_cmds_CXX; do
31491 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
31492 *[\\\\\\\`\\"\\\$]*)
31493 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
31494 ;;
31495 *)
31496 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
31497 ;;
31498 esac
e3487908 31499done
e3487908 31500
b686ecb5
JM
31501ac_aux_dir='$ac_aux_dir'
31502xsi_shell='$xsi_shell'
31503lt_shell_append='$lt_shell_append'
31504
31505# See if we are running on zsh, and set the options which allow our
31506# commands through without removal of \ escapes INIT.
31507if test -n "\${ZSH_VERSION+set}" ; then
31508 setopt NO_GLOB_SUBST
e3487908
GKB
31509fi
31510
31511
b686ecb5
JM
31512 PACKAGE='$PACKAGE'
31513 VERSION='$VERSION'
31514 TIMESTAMP='$TIMESTAMP'
31515 RM='$RM'
31516 ofile='$ofile'
31517
e3487908 31518
e3487908 31519
5218fa9e 31520ac_aux_dir='$ac_aux_dir'
e3487908 31521
c906108c 31522
b686ecb5
JM
31523ac_aux_dir=$ac_aux_dir DEPDIR=$DEPDIR
31524GDB_NM_FILE=$GDB_NM_FILE
c906108c 31525
b686ecb5 31526_ACEOF
c906108c 31527
b686ecb5 31528cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
bec39cab 31529
b686ecb5
JM
31530# Handling of arguments.
31531for ac_config_target in $ac_config_targets
31532do
31533 case $ac_config_target in
31534 "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h:config.in" ;;
31535 "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;;
31536 "depdir") CONFIG_COMMANDS="$CONFIG_COMMANDS depdir" ;;
31537 "jit-reader.h") CONFIG_FILES="$CONFIG_FILES jit-reader.h:jit-reader.in" ;;
31538 "nm.h") CONFIG_LINKS="$CONFIG_LINKS nm.h:$GDB_NM_FILE" ;;
31539 "gcore") CONFIG_FILES="$CONFIG_FILES gcore" ;;
31540 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
31541 "gdb-gdb.gdb") CONFIG_FILES="$CONFIG_FILES gdb-gdb.gdb" ;;
31542 "gdb-gdb.py") CONFIG_FILES="$CONFIG_FILES gdb-gdb.py" ;;
31543 "doc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/Makefile" ;;
31544 "data-directory/Makefile") CONFIG_FILES="$CONFIG_FILES data-directory/Makefile" ;;
bec39cab 31545
b686ecb5
JM
31546 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
31547 esac
31548done
8ecfd7bd 31549
4d696a5c 31550
b686ecb5
JM
31551# If the user did not use the arguments to specify the items to instantiate,
31552# then the envvar interface is used. Set only those that are not.
31553# We use the long form for the default assignment because of an extremely
31554# bizarre bug on SunOS 4.1.3.
31555if $ac_need_defaults; then
31556 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
31557 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
31558 test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
31559 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
4d696a5c
SM
31560fi
31561
b686ecb5
JM
31562# Have a temporary directory for convenience. Make it in the build tree
31563# simply because there is no reason against having it here, and in addition,
31564# creating and moving files from /tmp can sometimes cause problems.
31565# Hook for its removal unless debugging.
31566# Note that there is a small window in which the directory will not be cleaned:
31567# after its creation but before its name has been assigned to `$tmp'.
31568$debug ||
31569{
31570 tmp= ac_tmp=
31571 trap 'exit_status=$?
31572 : "${ac_tmp:=$tmp}"
31573 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
31574' 0
31575 trap 'as_fn_exit 1' 1 2 13 15
31576}
31577# Create a (secure) tmp directory for tmp files.
31578
31579{
31580 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
31581 test -d "$tmp"
31582} ||
31583{
31584 tmp=./conf$$-$RANDOM
31585 (umask 077 && mkdir "$tmp")
31586} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
31587ac_tmp=$tmp
31588
31589# Set up the scripts for CONFIG_FILES section.
31590# No need to generate them if there are no CONFIG_FILES.
31591# This happens for instance with `./config.status config.h'.
31592if test -n "$CONFIG_FILES"; then
31593
31594if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
31595 ac_cs_awk_getline=:
31596 ac_cs_awk_pipe_init=
31597 ac_cs_awk_read_file='
31598 while ((getline aline < (F[key])) > 0)
31599 print(aline)
31600 close(F[key])'
31601 ac_cs_awk_pipe_fini=
8ecfd7bd 31602else
b686ecb5
JM
31603 ac_cs_awk_getline=false
31604 ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
31605 ac_cs_awk_read_file='
31606 print "|#_!!_#|"
31607 print "cat " F[key] " &&"
31608 '$ac_cs_awk_pipe_init
31609 # The final `:' finishes the AND list.
31610 ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
31611fi
31612ac_cr=`echo X | tr X '\015'`
31613# On cygwin, bash can eat \r inside `` if the user requested igncr.
31614# But we know of no other shell where ac_cr would be empty at this
31615# point, so we can use a bashism as a fallback.
31616if test "x$ac_cr" = x; then
31617 eval ac_cr=\$\'\\r\'
31618fi
31619ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
31620if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
31621 ac_cs_awk_cr='\\r'
31622else
31623 ac_cs_awk_cr=$ac_cr
8ecfd7bd
SDJ
31624fi
31625
b686ecb5
JM
31626echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
31627_ACEOF
8ecfd7bd 31628
b686ecb5
JM
31629# Create commands to substitute file output variables.
31630{
31631 echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
31632 echo 'cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&' &&
31633 echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
31634 echo "_ACAWK" &&
31635 echo "_ACEOF"
31636} >conf$$files.sh &&
31637. ./conf$$files.sh ||
31638 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
31639rm -f conf$$files.sh
dcd1f979 31640
b686ecb5
JM
31641{
31642 echo "cat >conf$$subs.awk <<_ACEOF" &&
31643 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
31644 echo "_ACEOF"
31645} >conf$$subs.sh ||
31646 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
31647ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
31648ac_delim='%!_!# '
31649for ac_last_try in false false false false false :; do
31650 . ./conf$$subs.sh ||
31651 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
dcd1f979 31652
b686ecb5
JM
31653 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
31654 if test $ac_delim_n = $ac_delim_num; then
31655 break
31656 elif $ac_last_try; then
31657 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
31658 else
31659 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
31660 fi
31661done
31662rm -f conf$$subs.sh
8ecfd7bd 31663
b686ecb5
JM
31664cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
31665cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
31666_ACEOF
31667sed -n '
31668h
31669s/^/S["/; s/!.*/"]=/
31670p
31671g
31672s/^[^!]*!//
31673:repl
31674t repl
31675s/'"$ac_delim"'$//
31676t delim
31677:nl
31678h
31679s/\(.\{148\}\)..*/\1/
31680t more1
31681s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
31682p
31683n
31684b repl
31685:more1
31686s/["\\]/\\&/g; s/^/"/; s/$/"\\/
31687p
31688g
31689s/.\{148\}//
31690t nl
31691:delim
31692h
31693s/\(.\{148\}\)..*/\1/
31694t more2
31695s/["\\]/\\&/g; s/^/"/; s/$/"/
31696p
31697b
31698:more2
31699s/["\\]/\\&/g; s/^/"/; s/$/"\\/
31700p
31701g
31702s/.\{148\}//
31703t delim
31704' <conf$$subs.awk | sed '
31705/^[^""]/{
31706 N
31707 s/\n//
31708}
31709' >>$CONFIG_STATUS || ac_write_fail=1
31710rm -f conf$$subs.awk
31711cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
31712_ACAWK
31713cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
31714 for (key in S) S_is_set[key] = 1
31715 FS = "\a"
31716 \$ac_cs_awk_pipe_init
31717}
31718{
31719 line = $ 0
31720 nfields = split(line, field, "@")
31721 substed = 0
31722 len = length(field[1])
31723 for (i = 2; i < nfields; i++) {
31724 key = field[i]
31725 keylen = length(key)
31726 if (S_is_set[key]) {
31727 value = S[key]
31728 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
31729 len += length(value) + length(field[++i])
31730 substed = 1
31731 } else
31732 len += 1 + keylen
31733 }
31734 if (nfields == 3 && !substed) {
31735 key = field[2]
31736 if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) {
31737 \$ac_cs_awk_read_file
31738 next
31739 }
31740 }
31741 print line
31742}
31743\$ac_cs_awk_pipe_fini
31744_ACAWK
31745_ACEOF
31746cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
31747if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
31748 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
31749else
31750 cat
31751fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
31752 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
31753_ACEOF
8ecfd7bd 31754
b686ecb5
JM
31755# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
31756# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
31757# trailing colons and then remove the whole line if VPATH becomes empty
31758# (actually we leave an empty line to preserve line numbers).
31759if test "x$srcdir" = x.; then
31760 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
31761h
31762s///
31763s/^/:/
31764s/[ ]*$/:/
31765s/:\$(srcdir):/:/g
31766s/:\${srcdir}:/:/g
31767s/:@srcdir@:/:/g
31768s/^:*//
31769s/:*$//
31770x
31771s/\(=[ ]*\).*/\1/
31772G
31773s/\n//
31774s/^[^=]*=[ ]*$//
31775}'
dcd1f979
TT
31776fi
31777
b686ecb5
JM
31778cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
31779fi # test -n "$CONFIG_FILES"
b292c783 31780
b686ecb5
JM
31781# Set up the scripts for CONFIG_HEADERS section.
31782# No need to generate them if there are no CONFIG_HEADERS.
31783# This happens for instance with `./config.status Makefile'.
31784if test -n "$CONFIG_HEADERS"; then
31785cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
31786BEGIN {
31787_ACEOF
8ecfd7bd 31788
b686ecb5
JM
31789# Transform confdefs.h into an awk script `defines.awk', embedded as
31790# here-document in config.status, that substitutes the proper values into
31791# config.h.in to produce config.h.
f6a88844 31792
b686ecb5
JM
31793# Create a delimiter string that does not exist in confdefs.h, to ease
31794# handling of long lines.
31795ac_delim='%!_!# '
31796for ac_last_try in false false :; do
31797 ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
31798 if test -z "$ac_tt"; then
31799 break
31800 elif $ac_last_try; then
31801 as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
31802 else
31803 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
f6a88844 31804 fi
b686ecb5 31805done
f6a88844 31806
b686ecb5
JM
31807# For the awk script, D is an array of macro values keyed by name,
31808# likewise P contains macro parameters if any. Preserve backslash
31809# newline sequences.
b292c783 31810
b686ecb5
JM
31811ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
31812sed -n '
31813s/.\{148\}/&'"$ac_delim"'/g
31814t rset
31815:rset
31816s/^[ ]*#[ ]*define[ ][ ]*/ /
31817t def
31818d
31819:def
31820s/\\$//
31821t bsnl
31822s/["\\]/\\&/g
31823s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
31824D["\1"]=" \3"/p
31825s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
31826d
31827:bsnl
31828s/["\\]/\\&/g
31829s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
31830D["\1"]=" \3\\\\\\n"\\/p
31831t cont
31832s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
31833t cont
31834d
31835:cont
31836n
31837s/.\{148\}/&'"$ac_delim"'/g
31838t clear
31839:clear
31840s/\\$//
31841t bsnlc
31842s/["\\]/\\&/g; s/^/"/; s/$/"/p
31843d
31844:bsnlc
31845s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
31846b cont
31847' <confdefs.h | sed '
31848s/'"$ac_delim"'/"\\\
31849"/g' >>$CONFIG_STATUS || ac_write_fail=1
bec39cab 31850
b686ecb5
JM
31851cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
31852 for (key in D) D_is_set[key] = 1
31853 FS = "\a"
31854}
31855/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
31856 line = \$ 0
31857 split(line, arg, " ")
31858 if (arg[1] == "#") {
31859 defundef = arg[2]
31860 mac1 = arg[3]
31861 } else {
31862 defundef = substr(arg[1], 2)
31863 mac1 = arg[2]
31864 }
31865 split(mac1, mac2, "(") #)
31866 macro = mac2[1]
31867 prefix = substr(line, 1, index(line, defundef) - 1)
31868 if (D_is_set[macro]) {
31869 # Preserve the white space surrounding the "#".
31870 print prefix "define", macro P[macro] D[macro]
31871 next
31872 } else {
31873 # Replace #undef with comments. This is necessary, for example,
31874 # in the case of _POSIX_SOURCE, which is predefined and required
31875 # on some systems where configure will not decide to define it.
31876 if (defundef == "undef") {
31877 print "/*", prefix defundef, macro, "*/"
31878 next
31879 }
31880 }
31881}
31882{ print }
31883_ACAWK
bec39cab 31884_ACEOF
b686ecb5
JM
31885cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
31886 as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
31887fi # test -n "$CONFIG_HEADERS"
bec39cab 31888
bec39cab 31889
b686ecb5
JM
31890eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :L $CONFIG_LINKS :C $CONFIG_COMMANDS"
31891shift
31892for ac_tag
31893do
31894 case $ac_tag in
31895 :[FHLC]) ac_mode=$ac_tag; continue;;
31896 esac
31897 case $ac_mode$ac_tag in
31898 :[FHL]*:*);;
31899 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
31900 :[FH]-) ac_tag=-:-;;
31901 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
31902 esac
31903 ac_save_IFS=$IFS
31904 IFS=:
31905 set x $ac_tag
31906 IFS=$ac_save_IFS
31907 shift
31908 ac_file=$1
31909 shift
bec39cab 31910
b686ecb5
JM
31911 case $ac_mode in
31912 :L) ac_source=$1;;
31913 :[FH])
31914 ac_file_inputs=
31915 for ac_f
31916 do
31917 case $ac_f in
31918 -) ac_f="$ac_tmp/stdin";;
31919 *) # Look for the file first in the build tree, then in the source tree
31920 # (if the path is not absolute). The absolute path cannot be DOS-style,
31921 # because $ac_f cannot contain `:'.
31922 test -f "$ac_f" ||
31923 case $ac_f in
31924 [\\/$]*) false;;
31925 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
31926 esac ||
31927 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
31928 esac
31929 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
31930 as_fn_append ac_file_inputs " '$ac_f'"
31931 done
bec39cab 31932
b686ecb5
JM
31933 # Let's still pretend it is `configure' which instantiates (i.e., don't
31934 # use $as_me), people would be surprised to read:
31935 # /* config.h. Generated by config.status. */
31936 configure_input='Generated from '`
31937 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
31938 `' by configure.'
31939 if test x"$ac_file" != x-; then
31940 configure_input="$ac_file. $configure_input"
31941 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
31942$as_echo "$as_me: creating $ac_file" >&6;}
31943 fi
31944 # Neutralize special characters interpreted by sed in replacement strings.
31945 case $configure_input in #(
31946 *\&* | *\|* | *\\* )
31947 ac_sed_conf_input=`$as_echo "$configure_input" |
31948 sed 's/[\\\\&|]/\\\\&/g'`;; #(
31949 *) ac_sed_conf_input=$configure_input;;
31950 esac
bec39cab 31951
b686ecb5
JM
31952 case $ac_tag in
31953 *:-:* | *:-) cat >"$ac_tmp/stdin" \
31954 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
31955 esac
31956 ;;
31957 esac
bec39cab 31958
b686ecb5
JM
31959 ac_dir=`$as_dirname -- "$ac_file" ||
31960$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
31961 X"$ac_file" : 'X\(//\)[^/]' \| \
31962 X"$ac_file" : 'X\(//\)$' \| \
31963 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
31964$as_echo X"$ac_file" |
31965 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
31966 s//\1/
31967 q
31968 }
31969 /^X\(\/\/\)[^/].*/{
31970 s//\1/
31971 q
31972 }
31973 /^X\(\/\/\)$/{
31974 s//\1/
31975 q
31976 }
31977 /^X\(\/\).*/{
31978 s//\1/
31979 q
31980 }
31981 s/.*/./; q'`
31982 as_dir="$ac_dir"; as_fn_mkdir_p
31983 ac_builddir=.
bec39cab 31984
b686ecb5
JM
31985case "$ac_dir" in
31986.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
31987*)
31988 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
31989 # A ".." for each directory in $ac_dir_suffix.
31990 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
31991 case $ac_top_builddir_sub in
31992 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
31993 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
31994 esac ;;
31995esac
31996ac_abs_top_builddir=$ac_pwd
31997ac_abs_builddir=$ac_pwd$ac_dir_suffix
31998# for backward compatibility:
31999ac_top_builddir=$ac_top_build_prefix
81ecdfbb 32000
b686ecb5
JM
32001case $srcdir in
32002 .) # We are building in place.
32003 ac_srcdir=.
32004 ac_top_srcdir=$ac_top_builddir_sub
32005 ac_abs_top_srcdir=$ac_pwd ;;
32006 [\\/]* | ?:[\\/]* ) # Absolute name.
32007 ac_srcdir=$srcdir$ac_dir_suffix;
32008 ac_top_srcdir=$srcdir
32009 ac_abs_top_srcdir=$srcdir ;;
32010 *) # Relative name.
32011 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
32012 ac_top_srcdir=$ac_top_build_prefix$srcdir
32013 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
32014esac
32015ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
81ecdfbb 32016
bec39cab 32017
b686ecb5
JM
32018 case $ac_mode in
32019 :F)
32020 #
32021 # CONFIG_FILE
32022 #
bec39cab 32023
b686ecb5
JM
32024 case $INSTALL in
32025 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
32026 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
32027 esac
32028_ACEOF
81ecdfbb 32029
b686ecb5
JM
32030cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
32031# If the template does not know about datarootdir, expand it.
32032# FIXME: This hack should be removed a few years after 2.60.
32033ac_datarootdir_hack=; ac_datarootdir_seen=
32034ac_sed_dataroot='
32035/datarootdir/ {
32036 p
32037 q
32038}
32039/@datadir@/p
32040/@docdir@/p
32041/@infodir@/p
32042/@localedir@/p
32043/@mandir@/p'
32044case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
32045*datarootdir*) ac_datarootdir_seen=yes;;
32046*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
32047 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
32048$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
32049_ACEOF
32050cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
32051 ac_datarootdir_hack='
32052 s&@datadir@&$datadir&g
32053 s&@docdir@&$docdir&g
32054 s&@infodir@&$infodir&g
32055 s&@localedir@&$localedir&g
32056 s&@mandir@&$mandir&g
32057 s&\\\${datarootdir}&$datarootdir&g' ;;
81ecdfbb 32058esac
b686ecb5 32059_ACEOF
81ecdfbb 32060
b686ecb5
JM
32061# Neutralize VPATH when `$srcdir' = `.'.
32062# Shell code in configure.ac might set extrasub.
32063# FIXME: do we really want to maintain this feature?
32064cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
32065ac_sed_extra="$ac_vpsub
32066$extrasub
32067_ACEOF
32068cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
32069:t
32070/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
32071s|@configure_input@|$ac_sed_conf_input|;t t
32072s&@top_builddir@&$ac_top_builddir_sub&;t t
32073s&@top_build_prefix@&$ac_top_build_prefix&;t t
32074s&@srcdir@&$ac_srcdir&;t t
32075s&@abs_srcdir@&$ac_abs_srcdir&;t t
32076s&@top_srcdir@&$ac_top_srcdir&;t t
32077s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
32078s&@builddir@&$ac_builddir&;t t
32079s&@abs_builddir@&$ac_abs_builddir&;t t
32080s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
32081s&@INSTALL@&$ac_INSTALL&;t t
32082$ac_datarootdir_hack
32083"
32084eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
32085if $ac_cs_awk_getline; then
32086 $AWK -f "$ac_tmp/subs.awk"
32087else
32088 $AWK -f "$ac_tmp/subs.awk" | $SHELL
32089fi \
32090 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
81ecdfbb 32091
b686ecb5
JM
32092test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
32093 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
32094 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
32095 "$ac_tmp/out"`; test -z "$ac_out"; } &&
32096 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
32097which seems to be undefined. Please make sure it is defined" >&5
32098$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
32099which seems to be undefined. Please make sure it is defined" >&2;}
bec39cab 32100
b686ecb5
JM
32101 rm -f "$ac_tmp/stdin"
32102 case $ac_file in
32103 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
32104 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
32105 esac \
32106 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
32107 ;;
32108 :H)
32109 #
32110 # CONFIG_HEADER
32111 #
32112 if test x"$ac_file" != x-; then
32113 {
32114 $as_echo "/* $configure_input */" \
32115 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
32116 } >"$ac_tmp/config.h" \
32117 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
32118 if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
32119 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
32120$as_echo "$as_me: $ac_file is unchanged" >&6;}
32121 else
32122 rm -f "$ac_file"
32123 mv "$ac_tmp/config.h" "$ac_file" \
32124 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
32125 fi
32126 else
32127 $as_echo "/* $configure_input */" \
32128 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
32129 || as_fn_error $? "could not create -" "$LINENO" 5
32130 fi
32131 ;;
32132 :L)
32133 #
32134 # CONFIG_LINK
32135 #
bec39cab 32136
b686ecb5
JM
32137 if test "$ac_source" = "$ac_file" && test "$srcdir" = '.'; then
32138 :
32139 else
32140 # Prefer the file from the source tree if names are identical.
32141 if test "$ac_source" = "$ac_file" || test ! -r "$ac_source"; then
32142 ac_source=$srcdir/$ac_source
32143 fi
81ecdfbb 32144
b686ecb5
JM
32145 { $as_echo "$as_me:${as_lineno-$LINENO}: linking $ac_source to $ac_file" >&5
32146$as_echo "$as_me: linking $ac_source to $ac_file" >&6;}
81ecdfbb 32147
b686ecb5
JM
32148 if test ! -r "$ac_source"; then
32149 as_fn_error $? "$ac_source: file not found" "$LINENO" 5
32150 fi
32151 rm -f "$ac_file"
81ecdfbb 32152
b686ecb5
JM
32153 # Try a relative symlink, then a hard link, then a copy.
32154 case $ac_source in
32155 [\\/$]* | ?:[\\/]* ) ac_rel_source=$ac_source ;;
32156 *) ac_rel_source=$ac_top_build_prefix$ac_source ;;
32157 esac
32158 ln -s "$ac_rel_source" "$ac_file" 2>/dev/null ||
32159 ln "$ac_source" "$ac_file" 2>/dev/null ||
32160 cp -p "$ac_source" "$ac_file" ||
32161 as_fn_error $? "cannot link or copy $ac_source to $ac_file" "$LINENO" 5
32162 fi
32163 ;;
32164 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
32165$as_echo "$as_me: executing $ac_file commands" >&6;}
32166 ;;
32167 esac
bec39cab 32168
81ecdfbb 32169
b686ecb5
JM
32170 case $ac_file$ac_mode in
32171 "config.h":H) echo > stamp-h ;;
32172 "libtool":C)
81ecdfbb 32173
b686ecb5
JM
32174 # See if we are running on zsh, and set the options which allow our
32175 # commands through without removal of \ escapes.
32176 if test -n "${ZSH_VERSION+set}" ; then
32177 setopt NO_GLOB_SUBST
32178 fi
81ecdfbb 32179
b686ecb5
JM
32180 cfgfile="${ofile}T"
32181 trap "$RM \"$cfgfile\"; exit 1" 1 2 15
32182 $RM "$cfgfile"
81ecdfbb 32183
b686ecb5
JM
32184 cat <<_LT_EOF >> "$cfgfile"
32185#! $SHELL
81ecdfbb 32186
b686ecb5
JM
32187# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
32188# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION
32189# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
32190# NOTE: Changes made to this file will be lost: look at ltmain.sh.
32191#
32192# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
32193# 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
32194# Written by Gordon Matzigkeit, 1996
32195#
32196# This file is part of GNU Libtool.
32197#
32198# GNU Libtool is free software; you can redistribute it and/or
32199# modify it under the terms of the GNU General Public License as
32200# published by the Free Software Foundation; either version 2 of
32201# the License, or (at your option) any later version.
32202#
32203# As a special exception to the GNU General Public License,
32204# if you distribute this file as part of a program or library that
32205# is built using GNU Libtool, you may include this file under the
32206# same distribution terms that you use for the rest of that program.
32207#
32208# GNU Libtool is distributed in the hope that it will be useful,
32209# but WITHOUT ANY WARRANTY; without even the implied warranty of
32210# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
32211# GNU General Public License for more details.
32212#
32213# You should have received a copy of the GNU General Public License
32214# along with GNU Libtool; see the file COPYING. If not, a copy
32215# can be downloaded from http://www.gnu.org/licenses/gpl.html, or
32216# obtained by writing to the Free Software Foundation, Inc.,
32217# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
81ecdfbb 32218
81ecdfbb 32219
b686ecb5
JM
32220# The names of the tagged configurations supported by this script.
32221available_tags="CXX "
81ecdfbb 32222
b686ecb5 32223# ### BEGIN LIBTOOL CONFIG
bec39cab 32224
b686ecb5
JM
32225# Which release of libtool.m4 was used?
32226macro_version=$macro_version
32227macro_revision=$macro_revision
81ecdfbb 32228
b686ecb5
JM
32229# Whether or not to build shared libraries.
32230build_libtool_libs=$enable_shared
bec39cab 32231
b686ecb5
JM
32232# Whether or not to build static libraries.
32233build_old_libs=$enable_static
bec39cab 32234
b686ecb5
JM
32235# What type of objects to build.
32236pic_mode=$pic_mode
bec39cab 32237
b686ecb5
JM
32238# Whether or not to optimize for fast installation.
32239fast_install=$enable_fast_install
b4e70030 32240
b686ecb5
JM
32241# Shell to use when invoking shell scripts.
32242SHELL=$lt_SHELL
b4e70030 32243
b686ecb5
JM
32244# An echo program that protects backslashes.
32245ECHO=$lt_ECHO
bec39cab 32246
b686ecb5
JM
32247# The host system.
32248host_alias=$host_alias
32249host=$host
32250host_os=$host_os
81ecdfbb 32251
b686ecb5
JM
32252# The build system.
32253build_alias=$build_alias
32254build=$build
32255build_os=$build_os
81ecdfbb 32256
b686ecb5
JM
32257# A sed program that does not truncate output.
32258SED=$lt_SED
81ecdfbb 32259
b686ecb5
JM
32260# Sed that helps us avoid accidentally triggering echo(1) options like -n.
32261Xsed="\$SED -e 1s/^X//"
81ecdfbb 32262
b686ecb5
JM
32263# A grep program that handles long lines.
32264GREP=$lt_GREP
bec39cab 32265
b686ecb5
JM
32266# An ERE matcher.
32267EGREP=$lt_EGREP
bec39cab 32268
b686ecb5
JM
32269# A literal string matcher.
32270FGREP=$lt_FGREP
d0ac1c44 32271
b686ecb5
JM
32272# A BSD- or MS-compatible name lister.
32273NM=$lt_NM
bec39cab 32274
b686ecb5
JM
32275# Whether we need soft or hard links.
32276LN_S=$lt_LN_S
bec39cab 32277
b686ecb5
JM
32278# What is the maximum length of a command?
32279max_cmd_len=$max_cmd_len
bec39cab 32280
b686ecb5
JM
32281# Object file suffix (normally "o").
32282objext=$ac_objext
bec39cab 32283
b686ecb5
JM
32284# Executable file suffix (normally "").
32285exeext=$exeext
81ecdfbb 32286
b686ecb5
JM
32287# whether the shell understands "unset".
32288lt_unset=$lt_unset
bec39cab 32289
b686ecb5
JM
32290# turn spaces into newlines.
32291SP2NL=$lt_lt_SP2NL
bec39cab 32292
b686ecb5
JM
32293# turn newlines into spaces.
32294NL2SP=$lt_lt_NL2SP
81ecdfbb 32295
b686ecb5
JM
32296# An object symbol dumper.
32297OBJDUMP=$lt_OBJDUMP
bec39cab 32298
b686ecb5
JM
32299# Method to check whether dependent libraries are shared objects.
32300deplibs_check_method=$lt_deplibs_check_method
234b45d4 32301
b686ecb5
JM
32302# Command to use when deplibs_check_method == "file_magic".
32303file_magic_cmd=$lt_file_magic_cmd
b4e70030 32304
b686ecb5
JM
32305# The archiver.
32306AR=$lt_AR
32307AR_FLAGS=$lt_AR_FLAGS
b4e70030 32308
b686ecb5
JM
32309# A symbol stripping program.
32310STRIP=$lt_STRIP
234b45d4 32311
b686ecb5
JM
32312# Commands used to install an old-style archive.
32313RANLIB=$lt_RANLIB
32314old_postinstall_cmds=$lt_old_postinstall_cmds
32315old_postuninstall_cmds=$lt_old_postuninstall_cmds
b4e70030 32316
b686ecb5
JM
32317# Whether to use a lock for old archive extraction.
32318lock_old_archive_extraction=$lock_old_archive_extraction
234b45d4 32319
b686ecb5
JM
32320# A C compiler.
32321LTCC=$lt_CC
234b45d4 32322
b686ecb5
JM
32323# LTCC compiler flags.
32324LTCFLAGS=$lt_CFLAGS
234b45d4 32325
b686ecb5
JM
32326# Take the output of nm and produce a listing of raw symbols and C names.
32327global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
234b45d4 32328
b686ecb5
JM
32329# Transform the output of nm in a proper C declaration.
32330global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
234b45d4 32331
b686ecb5
JM
32332# Transform the output of nm in a C name address pair.
32333global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
234b45d4 32334
b686ecb5
JM
32335# Transform the output of nm in a C name address pair when lib prefix is needed.
32336global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
bec39cab 32337
b686ecb5
JM
32338# The name of the directory that contains temporary libtool files.
32339objdir=$objdir
b4e70030 32340
b686ecb5
JM
32341# Used to examine libraries when file_magic_cmd begins with "file".
32342MAGIC_CMD=$MAGIC_CMD
bec39cab 32343
b686ecb5
JM
32344# Must we lock files when doing compilation?
32345need_locks=$lt_need_locks
81ecdfbb 32346
b686ecb5
JM
32347# Tool to manipulate archived DWARF debug symbol files on Mac OS X.
32348DSYMUTIL=$lt_DSYMUTIL
bec39cab 32349
b686ecb5
JM
32350# Tool to change global to local symbols on Mac OS X.
32351NMEDIT=$lt_NMEDIT
c906108c 32352
b686ecb5
JM
32353# Tool to manipulate fat objects and archives on Mac OS X.
32354LIPO=$lt_LIPO
32355
32356# ldd/readelf like tool for Mach-O binaries on Mac OS X.
32357OTOOL=$lt_OTOOL
32358
32359# ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4.
32360OTOOL64=$lt_OTOOL64
32361
32362# Old archive suffix (normally "a").
32363libext=$libext
32364
32365# Shared library suffix (normally ".so").
32366shrext_cmds=$lt_shrext_cmds
32367
32368# The commands to extract the exported symbol list from a shared archive.
32369extract_expsyms_cmds=$lt_extract_expsyms_cmds
32370
32371# Variables whose values should be saved in libtool wrapper scripts and
32372# restored at link time.
32373variables_saved_for_relink=$lt_variables_saved_for_relink
32374
32375# Do we need the "lib" prefix for modules?
32376need_lib_prefix=$need_lib_prefix
32377
32378# Do we need a version for libraries?
32379need_version=$need_version
32380
32381# Library versioning type.
32382version_type=$version_type
32383
32384# Shared library runtime path variable.
32385runpath_var=$runpath_var
32386
32387# Shared library path variable.
32388shlibpath_var=$shlibpath_var
32389
32390# Is shlibpath searched before the hard-coded library search path?
32391shlibpath_overrides_runpath=$shlibpath_overrides_runpath
32392
32393# Format of library name prefix.
32394libname_spec=$lt_libname_spec
32395
32396# List of archive names. First name is the real one, the rest are links.
32397# The last name is the one that the linker finds with -lNAME
32398library_names_spec=$lt_library_names_spec
32399
32400# The coded name of the library, if different from the real name.
32401soname_spec=$lt_soname_spec
32402
32403# Permission mode override for installation of shared libraries.
32404install_override_mode=$lt_install_override_mode
32405
32406# Command to use after installation of a shared archive.
32407postinstall_cmds=$lt_postinstall_cmds
c906108c 32408
b686ecb5
JM
32409# Command to use after uninstallation of a shared archive.
32410postuninstall_cmds=$lt_postuninstall_cmds
c906108c 32411
b686ecb5
JM
32412# Commands used to finish a libtool library installation in a directory.
32413finish_cmds=$lt_finish_cmds
c906108c 32414
b686ecb5
JM
32415# As "finish_cmds", except a single script fragment to be evaled but
32416# not shown.
32417finish_eval=$lt_finish_eval
c906108c 32418
b686ecb5
JM
32419# Whether we should hardcode library paths into libraries.
32420hardcode_into_libs=$hardcode_into_libs
c906108c 32421
b686ecb5
JM
32422# Compile-time system search path for libraries.
32423sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
c906108c 32424
b686ecb5
JM
32425# Run-time system search path for libraries.
32426sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
bec39cab 32427
b686ecb5
JM
32428# Whether dlopen is supported.
32429dlopen_support=$enable_dlopen
bec39cab 32430
b686ecb5
JM
32431# Whether dlopen of programs is supported.
32432dlopen_self=$enable_dlopen_self
b4e70030 32433
b686ecb5
JM
32434# Whether dlopen of statically linked programs is supported.
32435dlopen_self_static=$enable_dlopen_self_static
bec39cab 32436
b686ecb5
JM
32437# Commands to strip libraries.
32438old_striplib=$lt_old_striplib
32439striplib=$lt_striplib
4e8d927d 32440
81ecdfbb 32441
b686ecb5
JM
32442# The linker used to build libraries.
32443LD=$lt_LD
c906108c 32444
b686ecb5
JM
32445# How to create reloadable object files.
32446reload_flag=$lt_reload_flag
32447reload_cmds=$lt_reload_cmds
81ecdfbb 32448
b686ecb5
JM
32449# Commands used to build an old-style archive.
32450old_archive_cmds=$lt_old_archive_cmds
bec39cab 32451
b686ecb5
JM
32452# A language specific compiler.
32453CC=$lt_compiler
81ecdfbb 32454
b686ecb5
JM
32455# Is the compiler the GNU compiler?
32456with_gcc=$GCC
81ecdfbb 32457
b686ecb5
JM
32458# Compiler flag to turn off builtin functions.
32459no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
81ecdfbb 32460
b686ecb5
JM
32461# How to pass a linker flag through the compiler.
32462wl=$lt_lt_prog_compiler_wl
81ecdfbb 32463
b686ecb5
JM
32464# Additional compiler flags for building library objects.
32465pic_flag=$lt_lt_prog_compiler_pic
81ecdfbb 32466
b686ecb5
JM
32467# Compiler flag to prevent dynamic linking.
32468link_static_flag=$lt_lt_prog_compiler_static
81ecdfbb 32469
b686ecb5
JM
32470# Does compiler simultaneously support -c and -o options?
32471compiler_c_o=$lt_lt_cv_prog_compiler_c_o
81ecdfbb 32472
b686ecb5
JM
32473# Whether or not to add -lc for building shared libraries.
32474build_libtool_need_lc=$archive_cmds_need_lc
81ecdfbb 32475
b686ecb5
JM
32476# Whether or not to disallow shared libs when runtime libs are static.
32477allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes
32478
32479# Compiler flag to allow reflexive dlopens.
32480export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
32481
32482# Compiler flag to generate shared objects directly from archives.
32483whole_archive_flag_spec=$lt_whole_archive_flag_spec
32484
32485# Whether the compiler copes with passing no objects directly.
32486compiler_needs_object=$lt_compiler_needs_object
81ecdfbb 32487
b686ecb5
JM
32488# Create an old-style archive from a shared archive.
32489old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
81ecdfbb 32490
b686ecb5
JM
32491# Create a temporary old-style archive to link instead of a shared archive.
32492old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
81ecdfbb 32493
b686ecb5
JM
32494# Commands used to build a shared archive.
32495archive_cmds=$lt_archive_cmds
32496archive_expsym_cmds=$lt_archive_expsym_cmds
81ecdfbb 32497
b686ecb5
JM
32498# Commands used to build a loadable module if different from building
32499# a shared archive.
32500module_cmds=$lt_module_cmds
32501module_expsym_cmds=$lt_module_expsym_cmds
4e8d927d 32502
b686ecb5
JM
32503# Whether we are building with GNU ld or not.
32504with_gnu_ld=$lt_with_gnu_ld
4e8d927d 32505
b686ecb5
JM
32506# Flag that allows shared libraries with undefined symbols to be built.
32507allow_undefined_flag=$lt_allow_undefined_flag
81ecdfbb 32508
b686ecb5
JM
32509# Flag that enforces no undefined symbols.
32510no_undefined_flag=$lt_no_undefined_flag
81ecdfbb 32511
b686ecb5
JM
32512# Flag to hardcode \$libdir into a binary during linking.
32513# This must work even if \$libdir does not exist
32514hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
4e8d927d 32515
b686ecb5
JM
32516# If ld is used when linking, flag to hardcode \$libdir into a binary
32517# during linking. This must work even if \$libdir does not exist.
32518hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld
4e8d927d 32519
b686ecb5
JM
32520# Whether we need a single "-rpath" flag with a separated argument.
32521hardcode_libdir_separator=$lt_hardcode_libdir_separator
4e8d927d 32522
b686ecb5
JM
32523# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
32524# DIR into the resulting binary.
32525hardcode_direct=$hardcode_direct
81ecdfbb 32526
b686ecb5
JM
32527# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
32528# DIR into the resulting binary and the resulting library dependency is
32529# "absolute",i.e impossible to change by setting \${shlibpath_var} if the
32530# library is relocated.
32531hardcode_direct_absolute=$hardcode_direct_absolute
4e8d927d 32532
b686ecb5
JM
32533# Set to "yes" if using the -LDIR flag during linking hardcodes DIR
32534# into the resulting binary.
32535hardcode_minus_L=$hardcode_minus_L
32536
32537# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
32538# into the resulting binary.
32539hardcode_shlibpath_var=$hardcode_shlibpath_var
32540
32541# Set to "yes" if building a shared library automatically hardcodes DIR
32542# into the library and all subsequent libraries and executables linked
32543# against it.
32544hardcode_automatic=$hardcode_automatic
32545
32546# Set to yes if linker adds runtime paths of dependent libraries
32547# to runtime path list.
32548inherit_rpath=$inherit_rpath
32549
32550# Whether libtool must link a program against all its dependency libraries.
32551link_all_deplibs=$link_all_deplibs
32552
32553# Fix the shell variable \$srcfile for the compiler.
32554fix_srcfile_path=$lt_fix_srcfile_path
32555
32556# Set to "yes" if exported symbols are required.
32557always_export_symbols=$always_export_symbols
32558
32559# The commands to list exported symbols.
32560export_symbols_cmds=$lt_export_symbols_cmds
32561
32562# Symbols that should not be listed in the preloaded symbols.
32563exclude_expsyms=$lt_exclude_expsyms
32564
32565# Symbols that must always be exported.
32566include_expsyms=$lt_include_expsyms
32567
32568# Commands necessary for linking programs (against libraries) with templates.
32569prelink_cmds=$lt_prelink_cmds
32570
32571# Specify filename containing input files.
32572file_list_spec=$lt_file_list_spec
32573
32574# How to hardcode a shared library path into an executable.
32575hardcode_action=$hardcode_action
32576
32577# The directories searched by this compiler when creating a shared library.
32578compiler_lib_search_dirs=$lt_compiler_lib_search_dirs
32579
32580# Dependencies to place before and after the objects being linked to
32581# create a shared library.
32582predep_objects=$lt_predep_objects
32583postdep_objects=$lt_postdep_objects
32584predeps=$lt_predeps
32585postdeps=$lt_postdeps
32586
32587# The library search path used internally by the compiler when linking
32588# a shared library.
32589compiler_lib_search_path=$lt_compiler_lib_search_path
32590
32591# ### END LIBTOOL CONFIG
32592
32593_LT_EOF
32594
32595 case $host_os in
32596 aix3*)
32597 cat <<\_LT_EOF >> "$cfgfile"
32598# AIX sometimes has problems with the GCC collect2 program. For some
32599# reason, if we set the COLLECT_NAMES environment variable, the problems
32600# vanish in a puff of smoke.
32601if test "X${COLLECT_NAMES+set}" != Xset; then
32602 COLLECT_NAMES=
32603 export COLLECT_NAMES
32604fi
32605_LT_EOF
81ecdfbb 32606 ;;
c906108c
SS
32607 esac
32608
bec39cab 32609
b686ecb5
JM
32610ltmain="$ac_aux_dir/ltmain.sh"
32611
32612
32613 # We use sed instead of cat because bash on DJGPP gets confused if
32614 # if finds mixed CR/LF and LF-only lines. Since sed operates in
32615 # text mode, it properly converts lines to CR/LF. This bash problem
32616 # is reportedly fixed, but why not run on old versions too?
32617 sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \
32618 || (rm -f "$cfgfile"; exit 1)
32619
32620 case $xsi_shell in
32621 yes)
32622 cat << \_LT_EOF >> "$cfgfile"
32623
32624# func_dirname file append nondir_replacement
32625# Compute the dirname of FILE. If nonempty, add APPEND to the result,
32626# otherwise set result to NONDIR_REPLACEMENT.
32627func_dirname ()
32628{
32629 case ${1} in
32630 */*) func_dirname_result="${1%/*}${2}" ;;
32631 * ) func_dirname_result="${3}" ;;
32632 esac
32633}
32634
32635# func_basename file
32636func_basename ()
32637{
32638 func_basename_result="${1##*/}"
32639}
bec39cab 32640
b686ecb5
JM
32641# func_dirname_and_basename file append nondir_replacement
32642# perform func_basename and func_dirname in a single function
32643# call:
32644# dirname: Compute the dirname of FILE. If nonempty,
32645# add APPEND to the result, otherwise set result
32646# to NONDIR_REPLACEMENT.
32647# value returned in "$func_dirname_result"
32648# basename: Compute filename of FILE.
32649# value retuned in "$func_basename_result"
32650# Implementation must be kept synchronized with func_dirname
32651# and func_basename. For efficiency, we do not delegate to
32652# those functions but instead duplicate the functionality here.
32653func_dirname_and_basename ()
32654{
32655 case ${1} in
32656 */*) func_dirname_result="${1%/*}${2}" ;;
32657 * ) func_dirname_result="${3}" ;;
32658 esac
32659 func_basename_result="${1##*/}"
32660}
bec39cab 32661
b686ecb5
JM
32662# func_stripname prefix suffix name
32663# strip PREFIX and SUFFIX off of NAME.
32664# PREFIX and SUFFIX must not contain globbing or regex special
32665# characters, hashes, percent signs, but SUFFIX may contain a leading
32666# dot (in which case that matches only a dot).
32667func_stripname ()
32668{
32669 # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
32670 # positional parameters, so assign one to ordinary parameter first.
32671 func_stripname_result=${3}
32672 func_stripname_result=${func_stripname_result#"${1}"}
32673 func_stripname_result=${func_stripname_result%"${2}"}
32674}
c906108c 32675
b686ecb5
JM
32676# func_opt_split
32677func_opt_split ()
32678{
32679 func_opt_split_opt=${1%%=*}
32680 func_opt_split_arg=${1#*=}
32681}
c906108c 32682
b686ecb5
JM
32683# func_lo2o object
32684func_lo2o ()
32685{
32686 case ${1} in
32687 *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
32688 *) func_lo2o_result=${1} ;;
c906108c 32689 esac
b686ecb5 32690}
121ce6e5 32691
b686ecb5
JM
32692# func_xform libobj-or-source
32693func_xform ()
32694{
32695 func_xform_result=${1%.*}.lo
81ecdfbb 32696}
81ecdfbb 32697
b686ecb5
JM
32698# func_arith arithmetic-term...
32699func_arith ()
32700{
32701 func_arith_result=$(( $* ))
32702}
81ecdfbb 32703
b686ecb5
JM
32704# func_len string
32705# STRING may not start with a hyphen.
32706func_len ()
32707{
32708 func_len_result=${#1}
32709}
81ecdfbb 32710
b686ecb5
JM
32711_LT_EOF
32712 ;;
32713 *) # Bourne compatible functions.
32714 cat << \_LT_EOF >> "$cfgfile"
32715
32716# func_dirname file append nondir_replacement
32717# Compute the dirname of FILE. If nonempty, add APPEND to the result,
32718# otherwise set result to NONDIR_REPLACEMENT.
32719func_dirname ()
32720{
32721 # Extract subdirectory from the argument.
32722 func_dirname_result=`$ECHO "${1}" | $SED "$dirname"`
32723 if test "X$func_dirname_result" = "X${1}"; then
32724 func_dirname_result="${3}"
bec39cab 32725 else
b686ecb5 32726 func_dirname_result="$func_dirname_result${2}"
bec39cab 32727 fi
b686ecb5 32728}
c906108c 32729
b686ecb5
JM
32730# func_basename file
32731func_basename ()
32732{
32733 func_basename_result=`$ECHO "${1}" | $SED "$basename"`
32734}
b4e70030 32735
b4e70030 32736
b686ecb5
JM
32737# func_stripname prefix suffix name
32738# strip PREFIX and SUFFIX off of NAME.
32739# PREFIX and SUFFIX must not contain globbing or regex special
32740# characters, hashes, percent signs, but SUFFIX may contain a leading
32741# dot (in which case that matches only a dot).
32742# func_strip_suffix prefix name
32743func_stripname ()
32744{
32745 case ${2} in
32746 .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
32747 *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
32748 esac
32749}
bec39cab 32750
b686ecb5
JM
32751# sed scripts:
32752my_sed_long_opt='1s/^\(-[^=]*\)=.*/\1/;q'
32753my_sed_long_arg='1s/^-[^=]*=//'
32754
32755# func_opt_split
32756func_opt_split ()
32757{
32758 func_opt_split_opt=`$ECHO "${1}" | $SED "$my_sed_long_opt"`
32759 func_opt_split_arg=`$ECHO "${1}" | $SED "$my_sed_long_arg"`
32760}
32761
32762# func_lo2o object
32763func_lo2o ()
32764{
32765 func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"`
32766}
32767
32768# func_xform libobj-or-source
32769func_xform ()
32770{
32771 func_xform_result=`$ECHO "${1}" | $SED 's/\.[^.]*$/.lo/'`
32772}
32773
32774# func_arith arithmetic-term...
32775func_arith ()
32776{
32777 func_arith_result=`expr "$@"`
32778}
32779
32780# func_len string
32781# STRING may not start with a hyphen.
32782func_len ()
32783{
32784 func_len_result=`expr "$1" : ".*" 2>/dev/null || echo $max_cmd_len`
32785}
32786
32787_LT_EOF
32788esac
32789
32790case $lt_shell_append in
32791 yes)
32792 cat << \_LT_EOF >> "$cfgfile"
32793
32794# func_append var value
32795# Append VALUE to the end of shell variable VAR.
32796func_append ()
32797{
32798 eval "$1+=\$2"
32799}
32800_LT_EOF
32801 ;;
32802 *)
32803 cat << \_LT_EOF >> "$cfgfile"
32804
32805# func_append var value
32806# Append VALUE to the end of shell variable VAR.
32807func_append ()
32808{
32809 eval "$1=\$$1\$2"
32810}
32811
32812_LT_EOF
32813 ;;
c906108c 32814 esac
b4e70030 32815
bec39cab 32816
b686ecb5
JM
32817 sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
32818 || (rm -f "$cfgfile"; exit 1)
32819
32820 mv -f "$cfgfile" "$ofile" ||
32821 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
32822 chmod +x "$ofile"
32823
32824
32825 cat <<_LT_EOF >> "$ofile"
32826
32827# ### BEGIN LIBTOOL TAG CONFIG: CXX
32828
32829# The linker used to build libraries.
32830LD=$lt_LD_CXX
32831
32832# How to create reloadable object files.
32833reload_flag=$lt_reload_flag_CXX
32834reload_cmds=$lt_reload_cmds_CXX
32835
32836# Commands used to build an old-style archive.
32837old_archive_cmds=$lt_old_archive_cmds_CXX
32838
32839# A language specific compiler.
32840CC=$lt_compiler_CXX
32841
32842# Is the compiler the GNU compiler?
32843with_gcc=$GCC_CXX
32844
32845# Compiler flag to turn off builtin functions.
32846no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_CXX
32847
32848# How to pass a linker flag through the compiler.
32849wl=$lt_lt_prog_compiler_wl_CXX
32850
32851# Additional compiler flags for building library objects.
32852pic_flag=$lt_lt_prog_compiler_pic_CXX
32853
32854# Compiler flag to prevent dynamic linking.
32855link_static_flag=$lt_lt_prog_compiler_static_CXX
32856
32857# Does compiler simultaneously support -c and -o options?
32858compiler_c_o=$lt_lt_cv_prog_compiler_c_o_CXX
32859
32860# Whether or not to add -lc for building shared libraries.
32861build_libtool_need_lc=$archive_cmds_need_lc_CXX
32862
32863# Whether or not to disallow shared libs when runtime libs are static.
32864allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_CXX
32865
32866# Compiler flag to allow reflexive dlopens.
32867export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_CXX
32868
32869# Compiler flag to generate shared objects directly from archives.
32870whole_archive_flag_spec=$lt_whole_archive_flag_spec_CXX
32871
32872# Whether the compiler copes with passing no objects directly.
32873compiler_needs_object=$lt_compiler_needs_object_CXX
32874
32875# Create an old-style archive from a shared archive.
32876old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_CXX
32877
32878# Create a temporary old-style archive to link instead of a shared archive.
32879old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_CXX
32880
32881# Commands used to build a shared archive.
32882archive_cmds=$lt_archive_cmds_CXX
32883archive_expsym_cmds=$lt_archive_expsym_cmds_CXX
32884
32885# Commands used to build a loadable module if different from building
32886# a shared archive.
32887module_cmds=$lt_module_cmds_CXX
32888module_expsym_cmds=$lt_module_expsym_cmds_CXX
32889
32890# Whether we are building with GNU ld or not.
32891with_gnu_ld=$lt_with_gnu_ld_CXX
32892
32893# Flag that allows shared libraries with undefined symbols to be built.
32894allow_undefined_flag=$lt_allow_undefined_flag_CXX
32895
32896# Flag that enforces no undefined symbols.
32897no_undefined_flag=$lt_no_undefined_flag_CXX
32898
32899# Flag to hardcode \$libdir into a binary during linking.
32900# This must work even if \$libdir does not exist
32901hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_CXX
32902
32903# If ld is used when linking, flag to hardcode \$libdir into a binary
32904# during linking. This must work even if \$libdir does not exist.
32905hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_CXX
32906
32907# Whether we need a single "-rpath" flag with a separated argument.
32908hardcode_libdir_separator=$lt_hardcode_libdir_separator_CXX
32909
32910# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
32911# DIR into the resulting binary.
32912hardcode_direct=$hardcode_direct_CXX
32913
32914# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
32915# DIR into the resulting binary and the resulting library dependency is
32916# "absolute",i.e impossible to change by setting \${shlibpath_var} if the
32917# library is relocated.
32918hardcode_direct_absolute=$hardcode_direct_absolute_CXX
32919
32920# Set to "yes" if using the -LDIR flag during linking hardcodes DIR
32921# into the resulting binary.
32922hardcode_minus_L=$hardcode_minus_L_CXX
32923
32924# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
32925# into the resulting binary.
32926hardcode_shlibpath_var=$hardcode_shlibpath_var_CXX
32927
32928# Set to "yes" if building a shared library automatically hardcodes DIR
32929# into the library and all subsequent libraries and executables linked
32930# against it.
32931hardcode_automatic=$hardcode_automatic_CXX
32932
32933# Set to yes if linker adds runtime paths of dependent libraries
32934# to runtime path list.
32935inherit_rpath=$inherit_rpath_CXX
32936
32937# Whether libtool must link a program against all its dependency libraries.
32938link_all_deplibs=$link_all_deplibs_CXX
32939
32940# Fix the shell variable \$srcfile for the compiler.
32941fix_srcfile_path=$lt_fix_srcfile_path_CXX
32942
32943# Set to "yes" if exported symbols are required.
32944always_export_symbols=$always_export_symbols_CXX
32945
32946# The commands to list exported symbols.
32947export_symbols_cmds=$lt_export_symbols_cmds_CXX
32948
32949# Symbols that should not be listed in the preloaded symbols.
32950exclude_expsyms=$lt_exclude_expsyms_CXX
32951
32952# Symbols that must always be exported.
32953include_expsyms=$lt_include_expsyms_CXX
32954
32955# Commands necessary for linking programs (against libraries) with templates.
32956prelink_cmds=$lt_prelink_cmds_CXX
32957
32958# Specify filename containing input files.
32959file_list_spec=$lt_file_list_spec_CXX
32960
32961# How to hardcode a shared library path into an executable.
32962hardcode_action=$hardcode_action_CXX
32963
32964# The directories searched by this compiler when creating a shared library.
32965compiler_lib_search_dirs=$lt_compiler_lib_search_dirs_CXX
32966
32967# Dependencies to place before and after the objects being linked to
32968# create a shared library.
32969predep_objects=$lt_predep_objects_CXX
32970postdep_objects=$lt_postdep_objects_CXX
32971predeps=$lt_predeps_CXX
32972postdeps=$lt_postdeps_CXX
32973
32974# The library search path used internally by the compiler when linking
32975# a shared library.
32976compiler_lib_search_path=$lt_compiler_lib_search_path_CXX
32977
32978# ### END LIBTOOL TAG CONFIG: CXX
32979_LT_EOF
32980
32981 ;;
81ecdfbb 32982 "depdir":C) $SHELL $ac_aux_dir/mkinstalldirs $DEPDIR ;;
a0a461e5 32983 "nm.h":L) echo > stamp-nmh ;;
b292c783 32984 "gcore":F) chmod +x gcore ;;
81ecdfbb 32985
bec39cab 32986 esac
81ecdfbb 32987done # for ac_tag
c906108c 32988
bec39cab 32989
81ecdfbb 32990as_fn_exit 0
bec39cab 32991_ACEOF
bec39cab
AC
32992ac_clean_files=$ac_clean_files_save
32993
81ecdfbb 32994test $ac_write_fail = 0 ||
d0ac1c44 32995 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
81ecdfbb 32996
bec39cab
AC
32997
32998# configure is writing to config.log, and then calls config.status.
32999# config.status does its own redirection, appending to config.log.
33000# Unfortunately, on DOS this fails, as config.log is still kept open
33001# by configure, so config.status won't be able to write to it; its
33002# output is simply discarded. So we exec the FD to /dev/null,
33003# effectively closing config.log, so it can be properly (re)opened and
33004# appended to by config.status. When coming back to configure, we
33005# need to make the FD available again.
33006if test "$no_create" != yes; then
33007 ac_cs_success=:
33008 ac_config_status_args=
33009 test "$silent" = yes &&
33010 ac_config_status_args="$ac_config_status_args --quiet"
33011 exec 5>/dev/null
33012 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
33013 exec 5>>config.log
33014 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
33015 # would make configure fail if this is the last instruction.
d0ac1c44 33016 $ac_cs_success || as_fn_exit 1
bec39cab 33017fi
c906108c 33018
bec39cab 33019#
81ecdfbb 33020# CONFIG_SUBDIRS section.
bec39cab 33021#
c906108c
SS
33022if test "$no_recursion" != yes; then
33023
81ecdfbb
RW
33024 # Remove --cache-file, --srcdir, and --disable-option-checking arguments
33025 # so they do not pile up.
c906108c
SS
33026 ac_sub_configure_args=
33027 ac_prev=
fdc59709
PB
33028 eval "set x $ac_configure_args"
33029 shift
33030 for ac_arg
33031 do
c906108c
SS
33032 if test -n "$ac_prev"; then
33033 ac_prev=
33034 continue
33035 fi
bec39cab 33036 case $ac_arg in
c906108c
SS
33037 -cache-file | --cache-file | --cache-fil | --cache-fi \
33038 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
33039 ac_prev=cache_file ;;
33040 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
bec39cab
AC
33041 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* \
33042 | --c=*)
33043 ;;
33044 --config-cache | -C)
c906108c
SS
33045 ;;
33046 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
33047 ac_prev=srcdir ;;
33048 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
33049 ;;
bec39cab
AC
33050 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
33051 ac_prev=prefix ;;
33052 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
33053 ;;
81ecdfbb
RW
33054 --disable-option-checking)
33055 ;;
fdc59709
PB
33056 *)
33057 case $ac_arg in
81ecdfbb 33058 *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
fdc59709 33059 esac
81ecdfbb 33060 as_fn_append ac_sub_configure_args " '$ac_arg'" ;;
c906108c
SS
33061 esac
33062 done
33063
bec39cab
AC
33064 # Always prepend --prefix to ensure using the same prefix
33065 # in subdir configurations.
fdc59709
PB
33066 ac_arg="--prefix=$prefix"
33067 case $ac_arg in
81ecdfbb 33068 *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
fdc59709 33069 esac
81ecdfbb
RW
33070 ac_sub_configure_args="'$ac_arg' $ac_sub_configure_args"
33071
33072 # Pass --silent
33073 if test "$silent" = yes; then
33074 ac_sub_configure_args="--silent $ac_sub_configure_args"
33075 fi
33076
33077 # Always prepend --disable-option-checking to silence warnings, since
33078 # different subdirs can have different --enable and --with options.
33079 ac_sub_configure_args="--disable-option-checking $ac_sub_configure_args"
bec39cab 33080
b4e70030 33081 ac_popdir=`pwd`
bec39cab 33082 for ac_dir in : $subdirs; do test "x$ac_dir" = x: && continue
c906108c
SS
33083
33084 # Do not complain, so a configure script can configure whichever
33085 # parts of a large source tree are present.
fdc59709 33086 test -d "$srcdir/$ac_dir" || continue
c906108c 33087
81ecdfbb
RW
33088 ac_msg="=== configuring in $ac_dir (`pwd`/$ac_dir)"
33089 $as_echo "$as_me:${as_lineno-$LINENO}: $ac_msg" >&5
33090 $as_echo "$ac_msg" >&6
33091 as_dir="$ac_dir"; as_fn_mkdir_p
bec39cab
AC
33092 ac_builddir=.
33093
81ecdfbb
RW
33094case "$ac_dir" in
33095.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
33096*)
33097 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
33098 # A ".." for each directory in $ac_dir_suffix.
33099 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
33100 case $ac_top_builddir_sub in
33101 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
33102 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
33103 esac ;;
33104esac
33105ac_abs_top_builddir=$ac_pwd
33106ac_abs_builddir=$ac_pwd$ac_dir_suffix
33107# for backward compatibility:
33108ac_top_builddir=$ac_top_build_prefix
bec39cab
AC
33109
33110case $srcdir in
81ecdfbb 33111 .) # We are building in place.
bec39cab 33112 ac_srcdir=.
81ecdfbb
RW
33113 ac_top_srcdir=$ac_top_builddir_sub
33114 ac_abs_top_srcdir=$ac_pwd ;;
33115 [\\/]* | ?:[\\/]* ) # Absolute name.
bec39cab 33116 ac_srcdir=$srcdir$ac_dir_suffix;
81ecdfbb
RW
33117 ac_top_srcdir=$srcdir
33118 ac_abs_top_srcdir=$srcdir ;;
33119 *) # Relative name.
33120 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
33121 ac_top_srcdir=$ac_top_build_prefix$srcdir
33122 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
bec39cab 33123esac
81ecdfbb 33124ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
c906108c 33125
c906108c 33126
fdc59709 33127 cd "$ac_dir"
c906108c
SS
33128
33129 # Check for guested configure; otherwise get Cygnus style configure.
fdc59709
PB
33130 if test -f "$ac_srcdir/configure.gnu"; then
33131 ac_sub_configure=$ac_srcdir/configure.gnu
33132 elif test -f "$ac_srcdir/configure"; then
33133 ac_sub_configure=$ac_srcdir/configure
33134 elif test -f "$ac_srcdir/configure.in"; then
33135 # This should be Cygnus configure.
33136 ac_sub_configure=$ac_aux_dir/configure
c906108c 33137 else
81ecdfbb
RW
33138 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no configuration information is in $ac_dir" >&5
33139$as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2;}
c906108c
SS
33140 ac_sub_configure=
33141 fi
33142
33143 # The recursion is here.
33144 if test -n "$ac_sub_configure"; then
c906108c 33145 # Make the cache file name correct relative to the subdirectory.
bec39cab
AC
33146 case $cache_file in
33147 [\\/]* | ?:[\\/]* ) ac_sub_cache_file=$cache_file ;;
81ecdfbb
RW
33148 *) # Relative name.
33149 ac_sub_cache_file=$ac_top_build_prefix$cache_file ;;
c906108c 33150 esac
c906108c 33151
81ecdfbb
RW
33152 { $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
33153$as_echo "$as_me: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&6;}
c906108c 33154 # The eval makes quoting arguments work.
fdc59709
PB
33155 eval "\$SHELL \"\$ac_sub_configure\" $ac_sub_configure_args \
33156 --cache-file=\"\$ac_sub_cache_file\" --srcdir=\"\$ac_srcdir\"" ||
d0ac1c44 33157 as_fn_error $? "$ac_sub_configure failed for $ac_dir" "$LINENO" 5
c906108c
SS
33158 fi
33159
fdc59709 33160 cd "$ac_popdir"
c906108c
SS
33161 done
33162fi
81ecdfbb
RW
33163if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
33164 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
33165$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
33166fi
c906108c 33167