]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/configure
re PR fortran/37203 (Check ORDER= of RESHAPE)
[thirdparty/gcc.git] / gcc / configure
CommitLineData
005537df 1#! /bin/sh
861bb6c1 2# Guess values for system-dependent variables and create Makefiles.
b61ff9c8 3# Generated by GNU Autoconf 2.59.
861bb6c1 4#
b61ff9c8 5# Copyright (C) 2003 Free Software Foundation, Inc.
861bb6c1
JL
6# This configure script is free software; the Free Software Foundation
7# gives unlimited permission to copy, distribute and modify it.
ba479fd2
NN
8## --------------------- ##
9## M4sh Initialization. ##
10## --------------------- ##
11
b61ff9c8 12# Be Bourne compatible
ba479fd2
NN
13if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
14 emulate sh
15 NULLCMD=:
16 # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
17 # is contrary to our usage. Disable this feature.
18 alias -g '${1+"$@"}'='"$@"'
b61ff9c8
BS
19elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
20 set -o posix
ba479fd2 21fi
b61ff9c8 22DUALCASE=1; export DUALCASE # for MKS sh
ba479fd2
NN
23
24# Support unset when possible.
86da66b5 25if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
ba479fd2
NN
26 as_unset=unset
27else
28 as_unset=false
29fi
30
31
32# Work around bugs in pre-3.0 UWIN ksh.
b61ff9c8 33$as_unset ENV MAIL MAILPATH
ba479fd2
NN
34PS1='$ '
35PS2='> '
36PS4='+ '
37
38# NLS nuisances.
39for as_var in \
40 LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
41 LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
42 LC_TELEPHONE LC_TIME
43do
86da66b5 44 if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
ba479fd2
NN
45 eval $as_var=C; export $as_var
46 else
b61ff9c8 47 $as_unset $as_var
ba479fd2
NN
48 fi
49done
50
51# Required to use basename.
b61ff9c8 52if expr a : '\(a\)' >/dev/null 2>&1; then
ba479fd2
NN
53 as_expr=expr
54else
55 as_expr=false
56fi
57
b61ff9c8 58if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
ba479fd2
NN
59 as_basename=basename
60else
61 as_basename=false
62fi
63
64
65# Name of the executable.
b61ff9c8 66as_me=`$as_basename "$0" ||
ba479fd2
NN
67$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
68 X"$0" : 'X\(//\)$' \| \
b61ff9c8
BS
69 X"$0" : 'X\(/\)$' \| \
70 . : '\(.\)' 2>/dev/null ||
ba479fd2 71echo X/"$0" |
b61ff9c8
BS
72 sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
73 /^X\/\(\/\/\)$/{ s//\1/; q; }
74 /^X\/\(\/\).*/{ s//\1/; q; }
75 s/.*/./; q'`
703d89ab 76
ab22c1fa 77
b61ff9c8
BS
78# PATH needs CR, and LINENO needs CR and PATH.
79# Avoid depending upon Character Ranges.
80as_cr_letters='abcdefghijklmnopqrstuvwxyz'
81as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
82as_cr_Letters=$as_cr_letters$as_cr_LETTERS
83as_cr_digits='0123456789'
84as_cr_alnum=$as_cr_Letters$as_cr_digits
1a4b763e 85
b61ff9c8
BS
86# The user is always right.
87if test "${PATH_SEPARATOR+set}" != set; then
88 echo "#! /bin/sh" >conf$$.sh
89 echo "exit 0" >>conf$$.sh
90 chmod +x conf$$.sh
91 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
92 PATH_SEPARATOR=';'
93 else
94 PATH_SEPARATOR=:
95 fi
96 rm -f conf$$.sh
1a4b763e
BS
97fi
98
1a4b763e 99
b61ff9c8
BS
100 as_lineno_1=$LINENO
101 as_lineno_2=$LINENO
102 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
103 test "x$as_lineno_1" != "x$as_lineno_2" &&
104 test "x$as_lineno_3" = "x$as_lineno_2" || {
105 # Find who we are. Look in the path if we contain no path at all
106 # relative or not.
107 case $0 in
108 *[\\/]* ) as_myself=$0 ;;
109 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
110for as_dir in $PATH
111do
112 IFS=$as_save_IFS
113 test -z "$as_dir" && as_dir=.
114 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
115done
1a4b763e 116
b61ff9c8
BS
117 ;;
118 esac
119 # We did not find ourselves, most probably we were run as `sh COMMAND'
120 # in which case we are not to be found in the path.
121 if test "x$as_myself" = x; then
122 as_myself=$0
123 fi
124 if test ! -f "$as_myself"; then
125 { echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2
126 { (exit 1); exit 1; }; }
127 fi
128 case $CONFIG_SHELL in
129 '')
ba479fd2 130 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
dd7f7a6e 131for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
ba479fd2
NN
132do
133 IFS=$as_save_IFS
134 test -z "$as_dir" && as_dir=.
b61ff9c8
BS
135 for as_base in sh bash ksh sh5; do
136 case $as_dir in
ba479fd2 137 /*)
b61ff9c8 138 if ("$as_dir/$as_base" -c '
1a4b763e
BS
139 as_lineno_1=$LINENO
140 as_lineno_2=$LINENO
b61ff9c8 141 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
1a4b763e 142 test "x$as_lineno_1" != "x$as_lineno_2" &&
b61ff9c8
BS
143 test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then
144 $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
145 $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
146 CONFIG_SHELL=$as_dir/$as_base
147 export CONFIG_SHELL
148 exec "$CONFIG_SHELL" "$0" ${1+"$@"}
149 fi;;
150 esac
151 done
152done
153;;
154 esac
ba479fd2
NN
155
156 # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
157 # uniformly replaced by the line number. The first 'sed' inserts a
b61ff9c8
BS
158 # line-number line before each line; the second 'sed' does the real
159 # work. The second script uses 'N' to pair each line-number line
160 # with the numbered line, and appends trailing '-' during
161 # substitution so that $LINENO is not a special case at line end.
ba479fd2 162 # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
b61ff9c8
BS
163 # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-)
164 sed '=' <$as_myself |
ba479fd2
NN
165 sed '
166 N
b61ff9c8
BS
167 s,$,-,
168 : loop
169 s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
ba479fd2 170 t loop
b61ff9c8
BS
171 s,-$,,
172 s,^['$as_cr_digits']*\n,,
ba479fd2 173 ' >$as_me.lineno &&
b61ff9c8 174 chmod +x $as_me.lineno ||
ba479fd2
NN
175 { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
176 { (exit 1); exit 1; }; }
177
178 # Don't try to exec as it changes $[0], causing all sort of problems
179 # (the dirname of $[0] is not the place where we might find the
b61ff9c8
BS
180 # original and so on. Autoconf is especially sensible to this).
181 . ./$as_me.lineno
ba479fd2
NN
182 # Exit status is that of the last command.
183 exit
184}
185
186
b61ff9c8
BS
187case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
188 *c*,-n*) ECHO_N= ECHO_C='
189' ECHO_T=' ' ;;
190 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
191 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
ba479fd2
NN
192esac
193
b61ff9c8 194if expr a : '\(a\)' >/dev/null 2>&1; then
ba479fd2
NN
195 as_expr=expr
196else
197 as_expr=false
198fi
199
200rm -f conf$$ conf$$.exe conf$$.file
201echo >conf$$.file
202if ln -s conf$$.file conf$$ 2>/dev/null; then
b61ff9c8
BS
203 # We could just check for DJGPP; but this test a) works b) is more generic
204 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
205 if test -f conf$$.exe; then
206 # Don't use ln at all; we don't have any links
ba479fd2 207 as_ln_s='cp -p'
b61ff9c8
BS
208 else
209 as_ln_s='ln -s'
210 fi
ba479fd2
NN
211elif ln conf$$.file conf$$ 2>/dev/null; then
212 as_ln_s=ln
213else
214 as_ln_s='cp -p'
215fi
b61ff9c8 216rm -f conf$$ conf$$.exe conf$$.file
861bb6c1 217
ba479fd2
NN
218if mkdir -p . 2>/dev/null; then
219 as_mkdir_p=:
220else
86da66b5 221 test -d ./-p && rmdir ./-p
ba479fd2
NN
222 as_mkdir_p=false
223fi
224
b61ff9c8 225as_executable_p="test -f"
ba479fd2
NN
226
227# Sed expression to map a string onto a valid CPP name.
86da66b5 228as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
ba479fd2
NN
229
230# Sed expression to map a string onto a valid variable name.
86da66b5 231as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
ba479fd2
NN
232
233
b61ff9c8
BS
234# IFS
235# We need space, tab and new line, in precisely that order.
236as_nl='
237'
238IFS=" $as_nl"
239
240# CDPATH.
241$as_unset CDPATH
ba479fd2
NN
242
243
da0f6381
PB
244
245# Check that we are running under the correct shell.
246SHELL=${CONFIG_SHELL-/bin/sh}
247
248case X$lt_ECHO in
249X*--fallback-echo)
250 # Remove one level of quotation (which was required for Make).
251 ECHO=`echo "$lt_ECHO" | sed 's,\\\\\$\\$0,'$0','`
252 ;;
253esac
254
255ECHO=${lt_ECHO-echo}
256if test "X$1" = X--no-reexec; then
257 # Discard the --no-reexec flag, and continue.
258 shift
259elif test "X$1" = X--fallback-echo; then
260 # Avoid inline document here, it may be left over
261 :
262elif test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' ; then
263 # Yippee, $ECHO works!
264 :
265else
266 # Restart under the correct shell.
267 exec $SHELL "$0" --no-reexec ${1+"$@"}
268fi
269
270if test "X$1" = X--fallback-echo; then
271 # used as fallback echo
272 shift
273 cat <<_LT_EOF
274$*
275_LT_EOF
276 exit 0
277fi
278
279# The HP-UX ksh and POSIX shell print the target directory to stdout
280# if CDPATH is set.
281(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
282
283if test -z "$lt_ECHO"; then
284 if test "X${echo_test_string+set}" != Xset; then
285 # find a string as large as possible, as long as the shell can cope with it
286 for cmd in 'sed 50q "$0"' 'sed 20q "$0"' 'sed 10q "$0"' 'sed 2q "$0"' 'echo test'; do
287 # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ...
288 if { echo_test_string=`eval $cmd`; } 2>/dev/null &&
289 { test "X$echo_test_string" = "X$echo_test_string"; } 2>/dev/null
290 then
291 break
292 fi
293 done
294 fi
295
296 if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' &&
297 echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` &&
298 test "X$echo_testing_string" = "X$echo_test_string"; then
299 :
300 else
301 # The Solaris, AIX, and Digital Unix default echo programs unquote
302 # backslashes. This makes it impossible to quote backslashes using
303 # echo "$something" | sed 's/\\/\\\\/g'
304 #
305 # So, first we look for a working echo in the user's PATH.
306
307 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
308 for dir in $PATH /usr/ucb; do
309 IFS="$lt_save_ifs"
310 if (test -f $dir/echo || test -f $dir/echo$ac_exeext) &&
311 test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' &&
312 echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` &&
313 test "X$echo_testing_string" = "X$echo_test_string"; then
314 ECHO="$dir/echo"
315 break
316 fi
317 done
318 IFS="$lt_save_ifs"
319
320 if test "X$ECHO" = Xecho; then
321 # We didn't find a better echo, so look for alternatives.
322 if test "X`{ print -r '\t'; } 2>/dev/null`" = 'X\t' &&
323 echo_testing_string=`{ print -r "$echo_test_string"; } 2>/dev/null` &&
324 test "X$echo_testing_string" = "X$echo_test_string"; then
325 # This shell has a builtin print -r that does the trick.
326 ECHO='print -r'
327 elif { test -f /bin/ksh || test -f /bin/ksh$ac_exeext; } &&
328 test "X$CONFIG_SHELL" != X/bin/ksh; then
329 # If we have ksh, try running configure again with it.
330 ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
331 export ORIGINAL_CONFIG_SHELL
332 CONFIG_SHELL=/bin/ksh
333 export CONFIG_SHELL
334 exec $CONFIG_SHELL "$0" --no-reexec ${1+"$@"}
335 else
336 # Try using printf.
337 ECHO='printf %s\n'
338 if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' &&
339 echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` &&
340 test "X$echo_testing_string" = "X$echo_test_string"; then
341 # Cool, printf works
342 :
343 elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "$0" --fallback-echo '\t') 2>/dev/null` &&
344 test "X$echo_testing_string" = 'X\t' &&
345 echo_testing_string=`($ORIGINAL_CONFIG_SHELL "$0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
346 test "X$echo_testing_string" = "X$echo_test_string"; then
347 CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL
348 export CONFIG_SHELL
349 SHELL="$CONFIG_SHELL"
350 export SHELL
351 ECHO="$CONFIG_SHELL $0 --fallback-echo"
352 elif echo_testing_string=`($CONFIG_SHELL "$0" --fallback-echo '\t') 2>/dev/null` &&
353 test "X$echo_testing_string" = 'X\t' &&
354 echo_testing_string=`($CONFIG_SHELL "$0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
355 test "X$echo_testing_string" = "X$echo_test_string"; then
356 ECHO="$CONFIG_SHELL $0 --fallback-echo"
357 else
358 # maybe with a smaller string...
359 prev=:
360
361 for cmd in 'echo test' 'sed 2q "$0"' 'sed 10q "$0"' 'sed 20q "$0"' 'sed 50q "$0"'; do
362 if { test "X$echo_test_string" = "X`eval $cmd`"; } 2>/dev/null
363 then
364 break
365 fi
366 prev="$cmd"
367 done
368
369 if test "$prev" != 'sed 50q "$0"'; then
370 echo_test_string=`eval $prev`
371 export echo_test_string
372 exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "$0" ${1+"$@"}
373 else
374 # Oops. We lost completely, so just stick with echo.
375 ECHO=echo
376 fi
377 fi
378 fi
379 fi
380 fi
381fi
382
383# Copy echo and quote the copy suitably for passing to libtool from
384# the Makefile, instead of quoting the original, which is used later.
385lt_ECHO=$ECHO
386if test "X$lt_ECHO" = "X$CONFIG_SHELL $0 --fallback-echo"; then
387 lt_ECHO="$CONFIG_SHELL \\\$\$0 --fallback-echo"
388fi
389
390
391
392
ba479fd2
NN
393# Name of the host.
394# hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
395# so uname gets run too.
396ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
397
b61ff9c8
BS
398exec 6>&1
399
ba479fd2
NN
400#
401# Initializations.
402#
861bb6c1 403ac_default_prefix=/usr/local
ba479fd2
NN
404ac_config_libobj_dir=.
405cross_compiling=no
406subdirs=
407MFLAGS=
408MAKEFLAGS=
409SHELL=${CONFIG_SHELL-/bin/sh}
410
b61ff9c8
BS
411# Maximum number of lines to put in a shell here document.
412# This variable seems obsolete. It should probably be removed, and
413# only ac_max_sed_lines should be used.
414: ${ac_max_here_lines=38}
415
ba479fd2
NN
416# Identity of this package.
417PACKAGE_NAME=
418PACKAGE_TARNAME=
419PACKAGE_VERSION=
420PACKAGE_STRING=
421PACKAGE_BUGREPORT=
422
423ac_unique_file="tree.c"
424# Factoring default headers for most tests.
425ac_includes_default="\
426#include <stdio.h>
b61ff9c8 427#if HAVE_SYS_TYPES_H
ba479fd2
NN
428# include <sys/types.h>
429#endif
b61ff9c8 430#if HAVE_SYS_STAT_H
ba479fd2
NN
431# include <sys/stat.h>
432#endif
b61ff9c8 433#if STDC_HEADERS
ba479fd2
NN
434# include <stdlib.h>
435# include <stddef.h>
436#else
b61ff9c8 437# if HAVE_STDLIB_H
ba479fd2
NN
438# include <stdlib.h>
439# endif
440#endif
b61ff9c8
BS
441#if HAVE_STRING_H
442# if !STDC_HEADERS && HAVE_MEMORY_H
ba479fd2
NN
443# include <memory.h>
444# endif
445# include <string.h>
446#endif
b61ff9c8 447#if HAVE_STRINGS_H
ba479fd2
NN
448# include <strings.h>
449#endif
b61ff9c8 450#if HAVE_INTTYPES_H
ba479fd2 451# include <inttypes.h>
b61ff9c8
BS
452#else
453# if HAVE_STDINT_H
454# include <stdint.h>
455# endif
ba479fd2 456#endif
b61ff9c8 457#if HAVE_UNISTD_H
ba479fd2
NN
458# include <unistd.h>
459#endif"
460
aca600aa 461ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS build build_cpu build_vendor build_os host host_cpu host_vendor host_os target target_cpu target_vendor target_os target_noncanonical build_libsubdir build_subdir host_subdir target_subdir GENINSRC CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT GNATBIND ac_ct_GNATBIND GNATMAKE ac_ct_GNATMAKE NO_MINUS_C_MINUS_O OUTPUT_OPTION CPP EGREP loose_warn strict_warn warn_cflags nocommon_flag TREEBROWSER valgrind_path valgrind_path_defines valgrind_command coverage_flags enable_multilib enable_decimal_float enable_fixed_point enable_shared TARGET_SYSTEM_ROOT TARGET_SYSTEM_ROOT_DEFINE CROSS_SYSTEM_HEADER_DIR onestep PKGVERSION REPORT_BUGS_TO REPORT_BUGS_TEXI datarootdir docdir htmldir SET_MAKE AWK LN_S LN RANLIB ac_ct_RANLIB ranlib_flags INSTALL INSTALL_PROGRAM INSTALL_DATA make_compare_target have_mktemp_command MAKEINFO BUILD_INFO GENERATED_MANPAGES FLEX BISON NM AR COLLECT2_LIBS GNAT_LIBEXC LDEXP_LIB LIBICONV LTLIBICONV LIBICONV_DEP manext objext gthread_flags extra_modes_file extra_opt_files USE_NLS LIBINTL LIBINTL_DEP INCINTL XGETTEXT GMSGFMT POSUB CATALOGS DATADIRNAME INSTOBJEXT GENCAT CATOBJEXT CROSS ALL SYSTEM_HEADER_DIR inhibit_libc CC_FOR_BUILD BUILD_CFLAGS BUILD_LDFLAGS STMP_FIXINC collect2 LIBTOOL SED FGREP GREP LD DUMPBIN ac_ct_DUMPBIN OBJDUMP ac_ct_OBJDUMP ac_ct_AR STRIP ac_ct_STRIP lt_ECHO DSYMUTIL ac_ct_DSYMUTIL NMEDIT ac_ct_NMEDIT LIPO ac_ct_LIPO OTOOL ac_ct_OTOOL OTOOL64 ac_ct_OTOOL64 objdir enable_fast_install gcc_cv_as ORIGINAL_AS_FOR_TARGET gcc_cv_ld ORIGINAL_LD_FOR_TARGET gcc_cv_nm ORIGINAL_NM_FOR_TARGET gcc_cv_objdump gcc_cv_readelf libgcc_visibility GGC zlibdir zlibinc MAINT gcc_tooldir dollar slibdir subdirs srcdir all_compilers all_gtfiles all_lang_makefrags all_lang_makefiles all_languages all_selected_languages build_exeext build_install_headers_dir build_xm_file_list build_xm_include_list build_xm_defines build_file_translate check_languages cpp_install_dir xmake_file tmake_file TM_ENDIAN_CONFIG TM_MULTILIB_CONFIG TM_MULTILIB_EXCEPTIONS_CONFIG extra_gcc_objs extra_headers_list extra_objs extra_parts extra_passes extra_programs float_h_file gcc_config_arguments gcc_gxx_include_dir host_exeext host_xm_file_list host_xm_include_list host_xm_defines out_host_hook_obj install lang_opt_files lang_specs_files lang_tree_files local_prefix md_file objc_boehm_gc out_file out_object_file thread_file tm_file_list tm_include_list tm_defines tm_p_file_list tm_p_include_list xm_file_list xm_include_list xm_defines use_gcc_stdint c_target_objs cxx_target_objs fortran_target_objs target_cpu_default GMPLIBS GMPINC PPLLIBS PPLINC CLOOGLIBS CLOOGINC pluginlibs enable_plugin LIBOBJS LTLIBOBJS'
ba479fd2 462ac_subst_files='language_hooks'
18c04407 463ac_pwd=`pwd`
861bb6c1
JL
464
465# Initialize some variables set by options.
ba479fd2
NN
466ac_init_help=
467ac_init_version=false
861bb6c1
JL
468# The variables have the same names as the options, with
469# dashes changed to underlines.
ba479fd2 470cache_file=/dev/null
861bb6c1 471exec_prefix=NONE
861bb6c1 472no_create=
861bb6c1
JL
473no_recursion=
474prefix=NONE
475program_prefix=NONE
476program_suffix=NONE
477program_transform_name=s,x,x,
478silent=
479site=
480srcdir=
861bb6c1
JL
481verbose=
482x_includes=NONE
483x_libraries=NONE
ba479fd2
NN
484
485# Installation directory options.
486# These are left unexpanded so users can "make install exec_prefix=/foo"
487# and all the variables that are supposed to be based on exec_prefix
488# by default will actually change.
489# Use braces instead of parens because sh, perl, etc. also accept them.
861bb6c1
JL
490bindir='${exec_prefix}/bin'
491sbindir='${exec_prefix}/sbin'
492libexecdir='${exec_prefix}/libexec'
b61ff9c8 493datadir='${prefix}/share'
861bb6c1
JL
494sysconfdir='${prefix}/etc'
495sharedstatedir='${prefix}/com'
496localstatedir='${prefix}/var'
b61ff9c8 497libdir='${exec_prefix}/lib'
861bb6c1
JL
498includedir='${prefix}/include'
499oldincludedir='/usr/include'
b61ff9c8
BS
500infodir='${prefix}/info'
501mandir='${prefix}/man'
861bb6c1 502
861bb6c1
JL
503ac_prev=
504for ac_option
505do
861bb6c1
JL
506 # If the previous option needs an argument, assign it.
507 if test -n "$ac_prev"; then
b61ff9c8 508 eval "$ac_prev=\$ac_option"
861bb6c1
JL
509 ac_prev=
510 continue
511 fi
512
b61ff9c8 513 ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
861bb6c1
JL
514
515 # Accept the important Cygnus configure options, so we can diagnose typos.
516
b61ff9c8 517 case $ac_option in
861bb6c1
JL
518
519 -bindir | --bindir | --bindi | --bind | --bin | --bi)
520 ac_prev=bindir ;;
521 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
ba479fd2 522 bindir=$ac_optarg ;;
861bb6c1
JL
523
524 -build | --build | --buil | --bui | --bu)
ba479fd2 525 ac_prev=build_alias ;;
861bb6c1 526 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
ba479fd2 527 build_alias=$ac_optarg ;;
861bb6c1
JL
528
529 -cache-file | --cache-file | --cache-fil | --cache-fi \
530 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
531 ac_prev=cache_file ;;
532 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
533 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
ba479fd2
NN
534 cache_file=$ac_optarg ;;
535
536 --config-cache | -C)
537 cache_file=config.cache ;;
861bb6c1 538
b61ff9c8 539 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
861bb6c1 540 ac_prev=datadir ;;
b61ff9c8
BS
541 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
542 | --da=*)
ba479fd2 543 datadir=$ac_optarg ;;
861bb6c1
JL
544
545 -disable-* | --disable-*)
ba479fd2 546 ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
861bb6c1 547 # Reject names that are not valid shell variable names.
b61ff9c8 548 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
ba479fd2
NN
549 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
550 { (exit 1); exit 1; }; }
b61ff9c8
BS
551 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
552 eval "enable_$ac_feature=no" ;;
861bb6c1
JL
553
554 -enable-* | --enable-*)
ba479fd2 555 ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
861bb6c1 556 # Reject names that are not valid shell variable names.
b61ff9c8 557 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
ba479fd2
NN
558 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
559 { (exit 1); exit 1; }; }
b61ff9c8
BS
560 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
561 case $ac_option in
562 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
563 *) ac_optarg=yes ;;
564 esac
565 eval "enable_$ac_feature='$ac_optarg'" ;;
861bb6c1
JL
566
567 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
568 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
569 | --exec | --exe | --ex)
570 ac_prev=exec_prefix ;;
571 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
572 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
573 | --exec=* | --exe=* | --ex=*)
ba479fd2 574 exec_prefix=$ac_optarg ;;
861bb6c1
JL
575
576 -gas | --gas | --ga | --g)
577 # Obsolete; use --with-gas.
578 with_gas=yes ;;
579
ba479fd2
NN
580 -help | --help | --hel | --he | -h)
581 ac_init_help=long ;;
582 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
583 ac_init_help=recursive ;;
584 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
585 ac_init_help=short ;;
861bb6c1
JL
586
587 -host | --host | --hos | --ho)
ba479fd2 588 ac_prev=host_alias ;;
861bb6c1 589 -host=* | --host=* | --hos=* | --ho=*)
ba479fd2 590 host_alias=$ac_optarg ;;
861bb6c1
JL
591
592 -includedir | --includedir | --includedi | --included | --include \
593 | --includ | --inclu | --incl | --inc)
594 ac_prev=includedir ;;
595 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
596 | --includ=* | --inclu=* | --incl=* | --inc=*)
ba479fd2 597 includedir=$ac_optarg ;;
861bb6c1
JL
598
599 -infodir | --infodir | --infodi | --infod | --info | --inf)
600 ac_prev=infodir ;;
601 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
ba479fd2 602 infodir=$ac_optarg ;;
861bb6c1
JL
603
604 -libdir | --libdir | --libdi | --libd)
605 ac_prev=libdir ;;
606 -libdir=* | --libdir=* | --libdi=* | --libd=*)
ba479fd2 607 libdir=$ac_optarg ;;
861bb6c1
JL
608
609 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
610 | --libexe | --libex | --libe)
611 ac_prev=libexecdir ;;
612 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
613 | --libexe=* | --libex=* | --libe=*)
ba479fd2 614 libexecdir=$ac_optarg ;;
861bb6c1
JL
615
616 -localstatedir | --localstatedir | --localstatedi | --localstated \
b61ff9c8
BS
617 | --localstate | --localstat | --localsta | --localst \
618 | --locals | --local | --loca | --loc | --lo)
861bb6c1
JL
619 ac_prev=localstatedir ;;
620 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
b61ff9c8
BS
621 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
622 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
ba479fd2 623 localstatedir=$ac_optarg ;;
861bb6c1
JL
624
625 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
626 ac_prev=mandir ;;
627 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
ba479fd2 628 mandir=$ac_optarg ;;
861bb6c1
JL
629
630 -nfp | --nfp | --nf)
631 # Obsolete; use --without-fp.
632 with_fp=no ;;
633
634 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
ba479fd2 635 | --no-cr | --no-c | -n)
861bb6c1
JL
636 no_create=yes ;;
637
638 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
639 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
640 no_recursion=yes ;;
641
642 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
643 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
644 | --oldin | --oldi | --old | --ol | --o)
645 ac_prev=oldincludedir ;;
646 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
647 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
648 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
ba479fd2 649 oldincludedir=$ac_optarg ;;
861bb6c1
JL
650
651 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
652 ac_prev=prefix ;;
653 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
ba479fd2 654 prefix=$ac_optarg ;;
861bb6c1
JL
655
656 -program-prefix | --program-prefix | --program-prefi | --program-pref \
657 | --program-pre | --program-pr | --program-p)
658 ac_prev=program_prefix ;;
659 -program-prefix=* | --program-prefix=* | --program-prefi=* \
660 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
ba479fd2 661 program_prefix=$ac_optarg ;;
861bb6c1
JL
662
663 -program-suffix | --program-suffix | --program-suffi | --program-suff \
664 | --program-suf | --program-su | --program-s)
665 ac_prev=program_suffix ;;
666 -program-suffix=* | --program-suffix=* | --program-suffi=* \
667 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
ba479fd2 668 program_suffix=$ac_optarg ;;
861bb6c1
JL
669
670 -program-transform-name | --program-transform-name \
671 | --program-transform-nam | --program-transform-na \
672 | --program-transform-n | --program-transform- \
673 | --program-transform | --program-transfor \
674 | --program-transfo | --program-transf \
675 | --program-trans | --program-tran \
676 | --progr-tra | --program-tr | --program-t)
677 ac_prev=program_transform_name ;;
678 -program-transform-name=* | --program-transform-name=* \
679 | --program-transform-nam=* | --program-transform-na=* \
680 | --program-transform-n=* | --program-transform-=* \
681 | --program-transform=* | --program-transfor=* \
682 | --program-transfo=* | --program-transf=* \
683 | --program-trans=* | --program-tran=* \
684 | --progr-tra=* | --program-tr=* | --program-t=*)
ba479fd2 685 program_transform_name=$ac_optarg ;;
861bb6c1
JL
686
687 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
688 | -silent | --silent | --silen | --sile | --sil)
689 silent=yes ;;
690
691 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
692 ac_prev=sbindir ;;
693 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
694 | --sbi=* | --sb=*)
ba479fd2 695 sbindir=$ac_optarg ;;
861bb6c1
JL
696
697 -sharedstatedir | --sharedstatedir | --sharedstatedi \
698 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
699 | --sharedst | --shareds | --shared | --share | --shar \
700 | --sha | --sh)
701 ac_prev=sharedstatedir ;;
702 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
703 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
704 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
705 | --sha=* | --sh=*)
ba479fd2 706 sharedstatedir=$ac_optarg ;;
861bb6c1
JL
707
708 -site | --site | --sit)
709 ac_prev=site ;;
710 -site=* | --site=* | --sit=*)
ba479fd2 711 site=$ac_optarg ;;
861bb6c1
JL
712
713 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
714 ac_prev=srcdir ;;
715 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
ba479fd2 716 srcdir=$ac_optarg ;;
861bb6c1
JL
717
718 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
719 | --syscon | --sysco | --sysc | --sys | --sy)
720 ac_prev=sysconfdir ;;
721 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
722 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
ba479fd2 723 sysconfdir=$ac_optarg ;;
861bb6c1
JL
724
725 -target | --target | --targe | --targ | --tar | --ta | --t)
ba479fd2 726 ac_prev=target_alias ;;
861bb6c1 727 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
ba479fd2 728 target_alias=$ac_optarg ;;
861bb6c1
JL
729
730 -v | -verbose | --verbose | --verbos | --verbo | --verb)
731 verbose=yes ;;
732
ba479fd2
NN
733 -version | --version | --versio | --versi | --vers | -V)
734 ac_init_version=: ;;
861bb6c1
JL
735
736 -with-* | --with-*)
ba479fd2 737 ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
861bb6c1 738 # Reject names that are not valid shell variable names.
b61ff9c8 739 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
ba479fd2
NN
740 { echo "$as_me: error: invalid package name: $ac_package" >&2
741 { (exit 1); exit 1; }; }
b61ff9c8
BS
742 ac_package=`echo $ac_package| sed 's/-/_/g'`
743 case $ac_option in
744 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
745 *) ac_optarg=yes ;;
746 esac
747 eval "with_$ac_package='$ac_optarg'" ;;
861bb6c1
JL
748
749 -without-* | --without-*)
ba479fd2 750 ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
861bb6c1 751 # Reject names that are not valid shell variable names.
b61ff9c8 752 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
ba479fd2
NN
753 { echo "$as_me: error: invalid package name: $ac_package" >&2
754 { (exit 1); exit 1; }; }
b61ff9c8
BS
755 ac_package=`echo $ac_package | sed 's/-/_/g'`
756 eval "with_$ac_package=no" ;;
861bb6c1
JL
757
758 --x)
759 # Obsolete; use --with-x.
760 with_x=yes ;;
761
762 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
763 | --x-incl | --x-inc | --x-in | --x-i)
764 ac_prev=x_includes ;;
765 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
766 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
ba479fd2 767 x_includes=$ac_optarg ;;
861bb6c1
JL
768
769 -x-libraries | --x-libraries | --x-librarie | --x-librari \
770 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
771 ac_prev=x_libraries ;;
772 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
773 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
ba479fd2 774 x_libraries=$ac_optarg ;;
861bb6c1 775
ba479fd2
NN
776 -*) { echo "$as_me: error: unrecognized option: $ac_option
777Try \`$0 --help' for more information." >&2
778 { (exit 1); exit 1; }; }
861bb6c1
JL
779 ;;
780
ba479fd2
NN
781 *=*)
782 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
783 # Reject names that are not valid shell variable names.
784 expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
785 { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
786 { (exit 1); exit 1; }; }
b61ff9c8
BS
787 ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
788 eval "$ac_envvar='$ac_optarg'"
ba479fd2
NN
789 export $ac_envvar ;;
790
861bb6c1 791 *)
ba479fd2
NN
792 # FIXME: should be removed in autoconf 3.0.
793 echo "$as_me: WARNING: you should use --build, --host, --target" >&2
794 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
795 echo "$as_me: WARNING: invalid host type: $ac_option" >&2
796 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
861bb6c1
JL
797 ;;
798
799 esac
800done
801
802if test -n "$ac_prev"; then
ba479fd2
NN
803 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
804 { echo "$as_me: error: missing argument to $ac_option" >&2
805 { (exit 1); exit 1; }; }
63cf211a 806fi
63cf211a 807
b61ff9c8
BS
808# Be sure to have absolute paths.
809for ac_var in exec_prefix prefix
861bb6c1 810do
b61ff9c8 811 eval ac_val=$`echo $ac_var`
ba479fd2 812 case $ac_val in
b61ff9c8
BS
813 [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
814 *) { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
815 { (exit 1); exit 1; }; };;
2f41c1d6
PB
816 esac
817done
818
b61ff9c8
BS
819# Be sure to have absolute paths.
820for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \
821 localstatedir libdir includedir oldincludedir infodir mandir
822do
823 eval ac_val=$`echo $ac_var`
824 case $ac_val in
825 [\\/$]* | ?:[\\/]* ) ;;
826 *) { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
827 { (exit 1); exit 1; }; };;
828 esac
829done
830
831# There might be people who depend on the old broken behavior: `$host'
832# used to hold the argument of --host etc.
833# FIXME: To remove some day.
834build=$build_alias
835host=$host_alias
ba479fd2
NN
836target=$target_alias
837
838# FIXME: To remove some day.
839if test "x$host_alias" != x; then
840 if test "x$build_alias" = x; then
841 cross_compiling=maybe
842 echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
843 If a cross compiler is detected then cross compile mode will be used." >&2
844 elif test "x$build_alias" != "x$host_alias"; then
845 cross_compiling=yes
846 fi
847fi
6e3f3080 848
ba479fd2
NN
849ac_tool_prefix=
850test -n "$host_alias" && ac_tool_prefix=$host_alias-
851
852test "$silent" = yes && exec 6>/dev/null
861bb6c1 853
861bb6c1
JL
854
855# Find the source files, if location was not specified.
856if test -z "$srcdir"; then
857 ac_srcdir_defaulted=yes
b61ff9c8
BS
858 # Try the directory containing this script, then its parent.
859 ac_confdir=`(dirname "$0") 2>/dev/null ||
ba479fd2 860$as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
86da66b5
HPN
861 X"$0" : 'X\(//\)[^/]' \| \
862 X"$0" : 'X\(//\)$' \| \
b61ff9c8
BS
863 X"$0" : 'X\(/\)' \| \
864 . : '\(.\)' 2>/dev/null ||
ba479fd2 865echo X"$0" |
b61ff9c8
BS
866 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
867 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
868 /^X\(\/\/\)$/{ s//\1/; q; }
869 /^X\(\/\).*/{ s//\1/; q; }
870 s/.*/./; q'`
861bb6c1 871 srcdir=$ac_confdir
f8c33439 872 if test ! -r $srcdir/$ac_unique_file; then
861bb6c1
JL
873 srcdir=..
874 fi
875else
876 ac_srcdir_defaulted=no
877fi
f8c33439 878if test ! -r $srcdir/$ac_unique_file; then
b61ff9c8
BS
879 if test "$ac_srcdir_defaulted" = yes; then
880 { echo "$as_me: error: cannot find sources ($ac_unique_file) in $ac_confdir or .." >&2
881 { (exit 1); exit 1; }; }
882 else
883 { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
ba479fd2 884 { (exit 1); exit 1; }; }
b61ff9c8 885 fi
dd7f7a6e 886fi
f8c33439 887(cd $srcdir && test -r ./$ac_unique_file) 2>/dev/null ||
b61ff9c8 888 { echo "$as_me: error: sources are in $srcdir, but \`cd $srcdir' does not work" >&2
dd7f7a6e 889 { (exit 1); exit 1; }; }
b61ff9c8
BS
890srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
891ac_env_build_alias_set=${build_alias+set}
892ac_env_build_alias_value=$build_alias
893ac_cv_env_build_alias_set=${build_alias+set}
894ac_cv_env_build_alias_value=$build_alias
895ac_env_host_alias_set=${host_alias+set}
896ac_env_host_alias_value=$host_alias
897ac_cv_env_host_alias_set=${host_alias+set}
898ac_cv_env_host_alias_value=$host_alias
899ac_env_target_alias_set=${target_alias+set}
900ac_env_target_alias_value=$target_alias
901ac_cv_env_target_alias_set=${target_alias+set}
902ac_cv_env_target_alias_value=$target_alias
903ac_env_CC_set=${CC+set}
904ac_env_CC_value=$CC
905ac_cv_env_CC_set=${CC+set}
906ac_cv_env_CC_value=$CC
907ac_env_CFLAGS_set=${CFLAGS+set}
908ac_env_CFLAGS_value=$CFLAGS
909ac_cv_env_CFLAGS_set=${CFLAGS+set}
910ac_cv_env_CFLAGS_value=$CFLAGS
911ac_env_LDFLAGS_set=${LDFLAGS+set}
912ac_env_LDFLAGS_value=$LDFLAGS
913ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
914ac_cv_env_LDFLAGS_value=$LDFLAGS
915ac_env_CPPFLAGS_set=${CPPFLAGS+set}
916ac_env_CPPFLAGS_value=$CPPFLAGS
917ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
918ac_cv_env_CPPFLAGS_value=$CPPFLAGS
919ac_env_CPP_set=${CPP+set}
920ac_env_CPP_value=$CPP
921ac_cv_env_CPP_set=${CPP+set}
922ac_cv_env_CPP_value=$CPP
923ac_env_GMPLIBS_set=${GMPLIBS+set}
924ac_env_GMPLIBS_value=$GMPLIBS
925ac_cv_env_GMPLIBS_set=${GMPLIBS+set}
926ac_cv_env_GMPLIBS_value=$GMPLIBS
927ac_env_GMPINC_set=${GMPINC+set}
928ac_env_GMPINC_value=$GMPINC
929ac_cv_env_GMPINC_set=${GMPINC+set}
930ac_cv_env_GMPINC_value=$GMPINC
f8bf9252
SP
931ac_env_PPLLIBS_set=${PPLLIBS+set}
932ac_env_PPLLIBS_value=$PPLLIBS
933ac_cv_env_PPLLIBS_set=${PPLLIBS+set}
934ac_cv_env_PPLLIBS_value=$PPLLIBS
935ac_env_PPLINC_set=${PPLINC+set}
936ac_env_PPLINC_value=$PPLINC
937ac_cv_env_PPLINC_set=${PPLINC+set}
938ac_cv_env_PPLINC_value=$PPLINC
939ac_env_CLOOGLIBS_set=${CLOOGLIBS+set}
940ac_env_CLOOGLIBS_value=$CLOOGLIBS
941ac_cv_env_CLOOGLIBS_set=${CLOOGLIBS+set}
942ac_cv_env_CLOOGLIBS_value=$CLOOGLIBS
943ac_env_CLOOGINC_set=${CLOOGINC+set}
944ac_env_CLOOGINC_value=$CLOOGINC
945ac_cv_env_CLOOGINC_set=${CLOOGINC+set}
946ac_cv_env_CLOOGINC_value=$CLOOGINC
63cf211a 947
ba479fd2
NN
948#
949# Report the --help message.
950#
951if test "$ac_init_help" = "long"; then
952 # Omit some internal or obsolete options to make the list less imposing.
953 # This message is too long to be a string in the A/UX 3.1 sh.
954 cat <<_ACEOF
955\`configure' configures this package to adapt to many kinds of systems.
861bb6c1 956
ba479fd2 957Usage: $0 [OPTION]... [VAR=VALUE]...
861bb6c1 958
ba479fd2
NN
959To assign environment variables (e.g., CC, CFLAGS...), specify them as
960VAR=VALUE. See below for descriptions of some of the useful variables.
861bb6c1 961
ba479fd2 962Defaults for the options are specified in brackets.
861bb6c1 963
ba479fd2
NN
964Configuration:
965 -h, --help display this help and exit
966 --help=short display options specific to this package
967 --help=recursive display the short help of all the included packages
968 -V, --version display version information and exit
969 -q, --quiet, --silent do not print \`checking...' messages
970 --cache-file=FILE cache test results in FILE [disabled]
971 -C, --config-cache alias for \`--cache-file=config.cache'
972 -n, --no-create do not create output files
973 --srcdir=DIR find the sources in DIR [configure dir or \`..']
974
b61ff9c8
BS
975_ACEOF
976
977 cat <<_ACEOF
ba479fd2
NN
978Installation directories:
979 --prefix=PREFIX install architecture-independent files in PREFIX
86da66b5 980 [$ac_default_prefix]
ba479fd2 981 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
86da66b5 982 [PREFIX]
861bb6c1 983
ba479fd2
NN
984By default, \`make install' will install all the files in
985\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
986an installation prefix other than \`$ac_default_prefix' using \`--prefix',
987for instance \`--prefix=\$HOME'.
13c22933 988
ba479fd2 989For better control, use the options below.
13c22933 990
ba479fd2
NN
991Fine tuning of the installation directories:
992 --bindir=DIR user executables [EPREFIX/bin]
993 --sbindir=DIR system admin executables [EPREFIX/sbin]
994 --libexecdir=DIR program executables [EPREFIX/libexec]
b61ff9c8 995 --datadir=DIR read-only architecture-independent data [PREFIX/share]
ba479fd2
NN
996 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
997 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
998 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
999 --libdir=DIR object code libraries [EPREFIX/lib]
1000 --includedir=DIR C header files [PREFIX/include]
1001 --oldincludedir=DIR C header files for non-gcc [/usr/include]
b61ff9c8
BS
1002 --infodir=DIR info documentation [PREFIX/info]
1003 --mandir=DIR man documentation [PREFIX/man]
ba479fd2 1004_ACEOF
13c22933 1005
ba479fd2 1006 cat <<\_ACEOF
13c22933 1007
ba479fd2
NN
1008Program names:
1009 --program-prefix=PREFIX prepend PREFIX to installed program names
1010 --program-suffix=SUFFIX append SUFFIX to installed program names
1011 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
13c22933 1012
ba479fd2
NN
1013System types:
1014 --build=BUILD configure for building on BUILD [guessed]
1015 --host=HOST cross-compile to build programs to run on HOST [BUILD]
1016 --target=TARGET configure for building compilers for TARGET [HOST]
1017_ACEOF
13c22933
JJ
1018fi
1019
ba479fd2 1020if test -n "$ac_init_help"; then
13c22933 1021
ba479fd2 1022 cat <<\_ACEOF
13c22933 1023
ba479fd2
NN
1024Optional Features:
1025 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1026 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
03787dfd
KC
1027 --enable-generated-files-in-srcdir
1028 put copies of generated files in source dir
1029 intended for creating source tarballs for users
1030 without texinfo bison or flex.
3bbd5a19 1031 --enable-werror-always enable -Werror despite compiler version
ba479fd2
NN
1032 --enable-checking=LIST
1033 enable expensive run-time checks. With LIST,
1034 enable only specific categories of checks.
cdce5c16 1035 Categories are: yes,no,all,none,release.
726a989a 1036 Flags are: assert,df,fold,gc,gcac,gimple,misc,
7e98624c 1037 rtlflag,rtl,runtime,tree,valgrind,types.
ba479fd2 1038 --enable-coverage=LEVEL
fb38008e 1039 enable compiler's code coverage collection.
ba479fd2
NN
1040 Use to measure compiler performance and locate
1041 unused parts of the compiler. With LEVEL, specify
1042 optimization. Values are opt, noopt,
1043 default is noopt
1044 --enable-gather-detailed-mem-stats enable detailed memory allocation stats gathering
1045 --enable-multilib enable library support for multiple ABIs
1046 --enable-__cxa_atexit enable __cxa_atexit for C++
79b87c74
MM
1047 --enable-decimal-float={no,yes,bid,dpd}
1048 enable decimal float extension to C. Selecting 'bid'
1049 or 'dpd' choses which decimal floating point format
1050 to use
ab22c1fa 1051 --enable-fixed-point enable fixed-point arithmetic extension to C
ba479fd2
NN
1052 --enable-threads enable thread usage for target GCC
1053 --enable-threads=LIB use LIB thread package for target GCC
8dea1cca
DD
1054 --enable-tls enable or disable generation of tls code
1055 overriding the assembler check for tls support
ba479fd2
NN
1056 --enable-objc-gc enable the use of Boehm's garbage collector with
1057 the GNU Objective-C runtime
1058 --disable-shared don't provide a shared libgcc
1059 --enable-intermodule build the compiler in one step
f3c9f174 1060 --enable-languages=LIST specify which front-ends to build
dfb77e37 1061 --disable-rpath do not hardcode runtime library paths
ba479fd2
NN
1062 --enable-initfini-array use .init_array/.fini_array sections
1063 --enable-sjlj-exceptions
1064 arrange to use setjmp/longjmp exception handling
7f970b70 1065 --enable-secureplt enable -msecure-plt by default for PowerPC
922e3e33 1066 --enable-cld enable -mcld by default for 32bit x86
ba479fd2
NN
1067 --disable-win32-registry
1068 disable lookup of installation paths in the
1069 Registry on Windows hosts
1070 --enable-win32-registry enable registry lookup (default)
1071 --enable-win32-registry=KEY
1072 use KEY instead of GCC version as the last portion
1073 of the registry key
da0f6381
PB
1074 --enable-shared[=PKGS]
1075 build shared libraries [default=yes]
1076 --enable-static[=PKGS]
1077 build static libraries [default=yes]
1078 --enable-fast-install[=PKGS]
1079 optimize for fast installation [default=yes]
1080 --disable-libtool-lock avoid locking (might break parallel builds)
cd533689
PP
1081 --enable-linker-build-id
1082 compiler will always pass --build-id to linker
ba479fd2
NN
1083 --enable-maintainer-mode
1084 enable make rules and dependencies not useful
1085 (and sometimes confusing) to the casual installer
1086 --enable-version-specific-runtime-libs
1087 specify that runtime libraries should be
1088 installed in a compiler-specific directory
68a607d8 1089 --enable-plugin enable plugin support
093e61a6 1090
ba479fd2
NN
1091Optional Packages:
1092 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
1093 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
1546bb64 1094 --with-build-libsubdir=DIR Directory where to find libraries for build system
ba479fd2
NN
1095 --with-local-prefix=DIR specifies directory to put local include
1096 --with-gxx-include-dir=DIR
1097 specifies directory to put g++ header files
1098 --with-cpp-install-dir=DIR
1099 install the user visible C preprocessor in DIR
1100 (relative to PREFIX) as well as PREFIX/bin
1101 --with-gnu-ld arrange to work with GNU ld.
1102 --with-ld arrange to use the specified ld (full pathname)
d594623a 1103 --with-demangler-in-ld try to use demangler in GNU ld.
ba479fd2
NN
1104 --with-gnu-as arrange to work with GNU as
1105 --with-as arrange to use the specified as (full pathname)
1106 --with-stabs arrange to use stabs instead of host debug format
1107 --with-dwarf2 force the default debug format to be DWARF 2
160633c6
MM
1108 --with-build-sysroot=sysroot
1109 use sysroot as the system root during the build
ba479fd2 1110 --with-sysroot=DIR Search for usr/lib, usr/include, et al, within DIR.
2f41c1d6
PB
1111 --with-pkgversion=PKG Use PKG in the version string in place of "GCC"
1112 --with-bugurl=URL Direct users to URL to report a bug
aca600aa 1113 --with-multilib-list Select multilibs (SH only)
dfb77e37
KC
1114 --with-gnu-ld assume the C compiler uses GNU ld default=no
1115 --with-libiconv-prefix[=DIR] search for libiconv in DIR/include and DIR/lib
1116 --without-libiconv-prefix don't search for libiconv in includedir and libdir
443728bb 1117 --with-system-libunwind use installed libunwind
da0f6381
PB
1118 --with-pic try to use only PIC/non-PIC objects [default=use
1119 both]
1120 --with-gnu-ld assume the C compiler uses GNU ld [default=no]
ed965309 1121 --with-long-double-128 Use 128-bit long double by default.
59415997 1122 --with-gc={page,zone} choose the garbage collection mechanism to use
ba479fd2
NN
1123 with the compiler
1124 --with-system-zlib use installed libz
22482f74
MS
1125 --with-slibdir=DIR shared libraries in DIR [LIBDIR]
1126 --with-datarootdir=DIR Use DIR as the data root [PREFIX/share]
1127 --with-docdir=DIR Install documentation in DIR [DATAROOTDIR]
1128 --with-htmldir=DIR html documentation in in DIR [DOCDIR]
13c22933 1129
ba479fd2
NN
1130Some influential environment variables:
1131 CC C compiler command
1132 CFLAGS C compiler flags
1133 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
1134 nonstandard directory <lib dir>
b61ff9c8
BS
1135 CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
1136 headers in a nonstandard directory <include dir>
ba479fd2 1137 CPP C preprocessor
6de9cd9a
DN
1138 GMPLIBS How to link GMP
1139 GMPINC How to find GMP include files
f8bf9252
SP
1140 PPLLIBS How to link PPL
1141 PPLINC How to find PPL include files
1142 CLOOGLIBS How to link CLOOG
1143 CLOOGINC How to find CLOOG include files
13c22933 1144
ba479fd2
NN
1145Use these variables to override the choices made by `configure' or to help
1146it to find libraries and programs with nonstandard names/locations.
73458fb7 1147
ba479fd2
NN
1148_ACEOF
1149fi
6e3f3080 1150
ba479fd2
NN
1151if test "$ac_init_help" = "recursive"; then
1152 # If there are subdirs, report their specific --help.
b61ff9c8 1153 ac_popdir=`pwd`
ba479fd2 1154 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
b61ff9c8 1155 test -d $ac_dir || continue
ba479fd2
NN
1156 ac_builddir=.
1157
b61ff9c8 1158if test "$ac_dir" != .; then
ba479fd2 1159 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
b61ff9c8
BS
1160 # A "../" for each directory in $ac_dir_suffix.
1161 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
1162else
1163 ac_dir_suffix= ac_top_builddir=
1164fi
ba479fd2
NN
1165
1166case $srcdir in
b61ff9c8 1167 .) # No --srcdir option. We are building in place.
ba479fd2 1168 ac_srcdir=.
b61ff9c8
BS
1169 if test -z "$ac_top_builddir"; then
1170 ac_top_srcdir=.
1171 else
1172 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
1173 fi ;;
1174 [\\/]* | ?:[\\/]* ) # Absolute path.
ba479fd2 1175 ac_srcdir=$srcdir$ac_dir_suffix;
b61ff9c8
BS
1176 ac_top_srcdir=$srcdir ;;
1177 *) # Relative path.
1178 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
1179 ac_top_srcdir=$ac_top_builddir$srcdir ;;
1180esac
1181
1182# Do not use `cd foo && pwd` to compute absolute paths, because
1183# the directories may not exist.
1184case `pwd` in
1185.) ac_abs_builddir="$ac_dir";;
1186*)
1187 case "$ac_dir" in
1188 .) ac_abs_builddir=`pwd`;;
1189 [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
1190 *) ac_abs_builddir=`pwd`/"$ac_dir";;
1191 esac;;
1192esac
1193case $ac_abs_builddir in
1194.) ac_abs_top_builddir=${ac_top_builddir}.;;
1195*)
1196 case ${ac_top_builddir}. in
1197 .) ac_abs_top_builddir=$ac_abs_builddir;;
1198 [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
1199 *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
1200 esac;;
1201esac
1202case $ac_abs_builddir in
1203.) ac_abs_srcdir=$ac_srcdir;;
1204*)
1205 case $ac_srcdir in
1206 .) ac_abs_srcdir=$ac_abs_builddir;;
1207 [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
1208 *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
1209 esac;;
1210esac
1211case $ac_abs_builddir in
1212.) ac_abs_top_srcdir=$ac_top_srcdir;;
1213*)
1214 case $ac_top_srcdir in
1215 .) ac_abs_top_srcdir=$ac_abs_builddir;;
1216 [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
1217 *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
1218 esac;;
86da66b5 1219esac
b61ff9c8
BS
1220
1221 cd $ac_dir
1222 # Check for guested configure; otherwise get Cygnus style configure.
1223 if test -f $ac_srcdir/configure.gnu; then
1224 echo
1225 $SHELL $ac_srcdir/configure.gnu --help=recursive
1226 elif test -f $ac_srcdir/configure; then
1227 echo
1228 $SHELL $ac_srcdir/configure --help=recursive
1229 elif test -f $ac_srcdir/configure.ac ||
1230 test -f $ac_srcdir/configure.in; then
1231 echo
1232 $ac_configure --help
ba479fd2
NN
1233 else
1234 echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
b61ff9c8
BS
1235 fi
1236 cd $ac_popdir
ba479fd2
NN
1237 done
1238fi
1239
b61ff9c8 1240test -n "$ac_init_help" && exit 0
ba479fd2
NN
1241if $ac_init_version; then
1242 cat <<\_ACEOF
1243
b61ff9c8 1244Copyright (C) 2003 Free Software Foundation, Inc.
ba479fd2
NN
1245This configure script is free software; the Free Software Foundation
1246gives unlimited permission to copy, distribute and modify it.
1247_ACEOF
b61ff9c8 1248 exit 0
ba479fd2 1249fi
b61ff9c8
BS
1250exec 5>config.log
1251cat >&5 <<_ACEOF
ba479fd2
NN
1252This file contains any messages produced by compilers while
1253running configure, to aid debugging if configure makes a mistake.
1254
1255It was created by $as_me, which was
b61ff9c8 1256generated by GNU Autoconf 2.59. Invocation command line was
ba479fd2
NN
1257
1258 $ $0 $@
1259
1260_ACEOF
1261{
1262cat <<_ASUNAME
1263## --------- ##
1264## Platform. ##
1265## --------- ##
1266
1267hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1268uname -m = `(uname -m) 2>/dev/null || echo unknown`
1269uname -r = `(uname -r) 2>/dev/null || echo unknown`
1270uname -s = `(uname -s) 2>/dev/null || echo unknown`
1271uname -v = `(uname -v) 2>/dev/null || echo unknown`
1272
1273/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1274/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
1275
1276/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
1277/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
1278/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
b61ff9c8 1279hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
ba479fd2
NN
1280/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
1281/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
1282/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
1283
1284_ASUNAME
1285
1286as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1287for as_dir in $PATH
1288do
1289 IFS=$as_save_IFS
1290 test -z "$as_dir" && as_dir=.
1291 echo "PATH: $as_dir"
1292done
1293
1294} >&5
1295
1296cat >&5 <<_ACEOF
1297
1298
1299## ----------- ##
1300## Core tests. ##
1301## ----------- ##
1302
1303_ACEOF
1304
1305
1306# Keep a trace of the command line.
1307# Strip out --no-create and --no-recursion so they do not pile up.
1308# Strip out --silent because we don't want to record it for future runs.
1309# Also quote any args containing shell meta-characters.
1310# Make two passes to allow for proper duplicate-argument suppression.
1311ac_configure_args=
1312ac_configure_args0=
1313ac_configure_args1=
b61ff9c8 1314ac_sep=
ba479fd2
NN
1315ac_must_keep_next=false
1316for ac_pass in 1 2
1317do
1318 for ac_arg
1319 do
1320 case $ac_arg in
1321 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1322 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1323 | -silent | --silent | --silen | --sile | --sil)
1324 continue ;;
b61ff9c8 1325 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
ba479fd2
NN
1326 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1327 esac
1328 case $ac_pass in
1329 1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1330 2)
1331 ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1332 if test $ac_must_keep_next = true; then
86da66b5 1333 ac_must_keep_next=false # Got value, back to normal.
ba479fd2 1334 else
86da66b5
HPN
1335 case $ac_arg in
1336 *=* | --config-cache | -C | -disable-* | --disable-* \
1337 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1338 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1339 | -with-* | --with-* | -without-* | --without-* | --x)
1340 case "$ac_configure_args0 " in
1341 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1342 esac
1343 ;;
1344 -* ) ac_must_keep_next=true ;;
1345 esac
ba479fd2 1346 fi
b61ff9c8
BS
1347 ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
1348 # Get rid of the leading space.
1349 ac_sep=" "
ba479fd2
NN
1350 ;;
1351 esac
1352 done
1353done
1354$as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1355$as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
1356
1357# When interrupted or exit'd, cleanup temporary files, and complete
1358# config.log. We remove comments because anyway the quotes in there
1359# would cause problems or look ugly.
b61ff9c8
BS
1360# WARNING: Be sure not to use single quotes in there, as some shells,
1361# such as our DU 5.0 friend, will then `close' the trap.
ba479fd2
NN
1362trap 'exit_status=$?
1363 # Save into config.log some information that might help in debugging.
1364 {
1365 echo
1366
1367 cat <<\_ASBOX
1368## ---------------- ##
1369## Cache variables. ##
1370## ---------------- ##
1371_ASBOX
1372 echo
1373 # The following way of writing the cache mishandles newlines in values,
b61ff9c8 1374{
ba479fd2 1375 (set) 2>&1 |
b61ff9c8
BS
1376 case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
1377 *ac_space=\ *)
ba479fd2 1378 sed -n \
b61ff9c8
BS
1379 "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
1380 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
1381 ;;
ba479fd2 1382 *)
b61ff9c8
BS
1383 sed -n \
1384 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
ba479fd2 1385 ;;
b61ff9c8
BS
1386 esac;
1387}
ba479fd2
NN
1388 echo
1389
1390 cat <<\_ASBOX
1391## ----------------- ##
1392## Output variables. ##
1393## ----------------- ##
1394_ASBOX
1395 echo
1396 for ac_var in $ac_subst_vars
1397 do
b61ff9c8
BS
1398 eval ac_val=$`echo $ac_var`
1399 echo "$ac_var='"'"'$ac_val'"'"'"
ba479fd2
NN
1400 done | sort
1401 echo
1402
1403 if test -n "$ac_subst_files"; then
1404 cat <<\_ASBOX
b61ff9c8
BS
1405## ------------- ##
1406## Output files. ##
1407## ------------- ##
ba479fd2
NN
1408_ASBOX
1409 echo
1410 for ac_var in $ac_subst_files
1411 do
b61ff9c8
BS
1412 eval ac_val=$`echo $ac_var`
1413 echo "$ac_var='"'"'$ac_val'"'"'"
ba479fd2
NN
1414 done | sort
1415 echo
1416 fi
1417
1418 if test -s confdefs.h; then
1419 cat <<\_ASBOX
1420## ----------- ##
1421## confdefs.h. ##
1422## ----------- ##
1423_ASBOX
1424 echo
b61ff9c8 1425 sed "/^$/d" confdefs.h | sort
ba479fd2
NN
1426 echo
1427 fi
1428 test "$ac_signal" != 0 &&
1429 echo "$as_me: caught signal $ac_signal"
1430 echo "$as_me: exit $exit_status"
1431 } >&5
b61ff9c8
BS
1432 rm -f core *.core &&
1433 rm -rf conftest* confdefs* conf$$* $ac_clean_files &&
ba479fd2 1434 exit $exit_status
b61ff9c8 1435 ' 0
ba479fd2
NN
1436for ac_signal in 1 2 13 15; do
1437 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1438done
1439ac_signal=0
1440
1441# confdefs.h avoids OS command line length limits that DEFS can exceed.
b61ff9c8
BS
1442rm -rf conftest* confdefs.h
1443# AIX cpp loses on an empty file, so make sure it contains at least a newline.
1444echo >confdefs.h
ba479fd2
NN
1445
1446# Predefined preprocessor variables.
1447
1448cat >>confdefs.h <<_ACEOF
1449#define PACKAGE_NAME "$PACKAGE_NAME"
1450_ACEOF
1451
1452
1453cat >>confdefs.h <<_ACEOF
1454#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1455_ACEOF
1456
1457
1458cat >>confdefs.h <<_ACEOF
1459#define PACKAGE_VERSION "$PACKAGE_VERSION"
1460_ACEOF
1461
1462
1463cat >>confdefs.h <<_ACEOF
1464#define PACKAGE_STRING "$PACKAGE_STRING"
1465_ACEOF
1466
1467
1468cat >>confdefs.h <<_ACEOF
1469#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1470_ACEOF
1471
1472
1473# Let the site file select an alternate cache file if it wants to.
1474# Prefer explicitly selected file to automatically selected ones.
b61ff9c8
BS
1475if test -z "$CONFIG_SITE"; then
1476 if test "x$prefix" != xNONE; then
1477 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
1478 else
1479 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
1480 fi
ba479fd2 1481fi
b61ff9c8 1482for ac_site_file in $CONFIG_SITE; do
ba479fd2
NN
1483 if test -r "$ac_site_file"; then
1484 { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1485echo "$as_me: loading site script $ac_site_file" >&6;}
1486 sed 's/^/| /' "$ac_site_file" >&5
1487 . "$ac_site_file"
1488 fi
1489done
1490
1491if test -r "$cache_file"; then
1492 # Some versions of bash will fail to source /dev/null (special
1493 # files actually), so we avoid doing that.
1494 if test -f "$cache_file"; then
1495 { echo "$as_me:$LINENO: loading cache $cache_file" >&5
1496echo "$as_me: loading cache $cache_file" >&6;}
1497 case $cache_file in
b61ff9c8
BS
1498 [\\/]* | ?:[\\/]* ) . $cache_file;;
1499 *) . ./$cache_file;;
ba479fd2
NN
1500 esac
1501 fi
1502else
1503 { echo "$as_me:$LINENO: creating cache $cache_file" >&5
1504echo "$as_me: creating cache $cache_file" >&6;}
1505 >$cache_file
1506fi
1507
1508# Check that the precious variables saved in the cache have kept the same
1509# value.
1510ac_cache_corrupted=false
b61ff9c8
BS
1511for ac_var in `(set) 2>&1 |
1512 sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
ba479fd2
NN
1513 eval ac_old_set=\$ac_cv_env_${ac_var}_set
1514 eval ac_new_set=\$ac_env_${ac_var}_set
b61ff9c8
BS
1515 eval ac_old_val="\$ac_cv_env_${ac_var}_value"
1516 eval ac_new_val="\$ac_env_${ac_var}_value"
ba479fd2
NN
1517 case $ac_old_set,$ac_new_set in
1518 set,)
1519 { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1520echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1521 ac_cache_corrupted=: ;;
1522 ,set)
1523 { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1524echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1525 ac_cache_corrupted=: ;;
1526 ,);;
1527 *)
1528 if test "x$ac_old_val" != "x$ac_new_val"; then
deb984e6
PB
1529 # differences in whitespace do not lead to failure.
1530 ac_old_val_w=`echo x $ac_old_val`
1531 ac_new_val_w=`echo x $ac_new_val`
1532 if test "$ac_old_val_w" != "$ac_new_val_w"; then
1533 { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
ba479fd2 1534echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
deb984e6
PB
1535 ac_cache_corrupted=:
1536 else
1537 { echo "$as_me:$LINENO: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
1538echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
1539 eval $ac_var=\$ac_old_val
1540 fi
1541 { echo "$as_me:$LINENO: former value: \`$ac_old_val'" >&5
1542echo "$as_me: former value: \`$ac_old_val'" >&2;}
1543 { echo "$as_me:$LINENO: current value: \`$ac_new_val'" >&5
1544echo "$as_me: current value: \`$ac_new_val'" >&2;}
ba479fd2
NN
1545 fi;;
1546 esac
1547 # Pass precious variables to config.status.
1548 if test "$ac_new_set" = set; then
1549 case $ac_new_val in
b61ff9c8
BS
1550 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1551 ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
ba479fd2
NN
1552 *) ac_arg=$ac_var=$ac_new_val ;;
1553 esac
1554 case " $ac_configure_args " in
1555 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
1556 *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1557 esac
1558 fi
1559done
1560if $ac_cache_corrupted; then
18c04407
RW
1561 { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
1562echo "$as_me: error: in \`$ac_pwd':" >&2;}
ba479fd2
NN
1563 { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1564echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1565 { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1566echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1567 { (exit 1); exit 1; }; }
1568fi
1569
b61ff9c8
BS
1570ac_ext=c
1571ac_cpp='$CPP $CPPFLAGS'
1572ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1573ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1574ac_compiler_gnu=$ac_cv_c_compiler_gnu
1575
ba479fd2
NN
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
18c04407
RW
1592
1593
1594
ba479fd2
NN
1595
1596
914c5af7 1597
b61ff9c8 1598 ac_config_headers="$ac_config_headers auto-host.h:config.in"
ba479fd2
NN
1599
1600
9f18db39
PB
1601gcc_version=`cat $srcdir/BASE-VER`
1602
ba479fd2
NN
1603# Determine the host, build, and target systems
1604ac_aux_dir=
b61ff9c8
BS
1605for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
1606 if test -f $ac_dir/install-sh; then
ba479fd2
NN
1607 ac_aux_dir=$ac_dir
1608 ac_install_sh="$ac_aux_dir/install-sh -c"
1609 break
b61ff9c8 1610 elif test -f $ac_dir/install.sh; then
ba479fd2
NN
1611 ac_aux_dir=$ac_dir
1612 ac_install_sh="$ac_aux_dir/install.sh -c"
1613 break
b61ff9c8 1614 elif test -f $ac_dir/shtool; then
ba479fd2
NN
1615 ac_aux_dir=$ac_dir
1616 ac_install_sh="$ac_aux_dir/shtool install -c"
1617 break
1618 fi
1619done
1620if test -z "$ac_aux_dir"; then
b61ff9c8
BS
1621 { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
1622echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
ba479fd2
NN
1623 { (exit 1); exit 1; }; }
1624fi
b61ff9c8
BS
1625ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1626ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1627ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
ba479fd2
NN
1628
1629# Make sure we can run config.sub.
b61ff9c8
BS
1630$ac_config_sub sun4 >/dev/null 2>&1 ||
1631 { { echo "$as_me:$LINENO: error: cannot run $ac_config_sub" >&5
1632echo "$as_me: error: cannot run $ac_config_sub" >&2;}
ba479fd2
NN
1633 { (exit 1); exit 1; }; }
1634
b61ff9c8
BS
1635echo "$as_me:$LINENO: checking build system type" >&5
1636echo $ECHO_N "checking build system type... $ECHO_C" >&6
ba479fd2
NN
1637if test "${ac_cv_build+set}" = set; then
1638 echo $ECHO_N "(cached) $ECHO_C" >&6
1639else
b61ff9c8
BS
1640 ac_cv_build_alias=$build_alias
1641test -z "$ac_cv_build_alias" &&
1642 ac_cv_build_alias=`$ac_config_guess`
1643test -z "$ac_cv_build_alias" &&
ba479fd2
NN
1644 { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
1645echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1646 { (exit 1); exit 1; }; }
b61ff9c8
BS
1647ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
1648 { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_build_alias failed" >&5
1649echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed" >&2;}
ba479fd2
NN
1650 { (exit 1); exit 1; }; }
1651
1652fi
b61ff9c8
BS
1653echo "$as_me:$LINENO: result: $ac_cv_build" >&5
1654echo "${ECHO_T}$ac_cv_build" >&6
ba479fd2 1655build=$ac_cv_build
b61ff9c8
BS
1656build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1657build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1658build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1659
1660
1661echo "$as_me:$LINENO: checking host system type" >&5
1662echo $ECHO_N "checking host system type... $ECHO_C" >&6
ba479fd2
NN
1663if test "${ac_cv_host+set}" = set; then
1664 echo $ECHO_N "(cached) $ECHO_C" >&6
1665else
b61ff9c8
BS
1666 ac_cv_host_alias=$host_alias
1667test -z "$ac_cv_host_alias" &&
1668 ac_cv_host_alias=$ac_cv_build_alias
1669ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
1670 { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1671echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
ba479fd2
NN
1672 { (exit 1); exit 1; }; }
1673
1674fi
b61ff9c8
BS
1675echo "$as_me:$LINENO: result: $ac_cv_host" >&5
1676echo "${ECHO_T}$ac_cv_host" >&6
ba479fd2 1677host=$ac_cv_host
b61ff9c8
BS
1678host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1679host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1680host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1681
1682
1683echo "$as_me:$LINENO: checking target system type" >&5
1684echo $ECHO_N "checking target system type... $ECHO_C" >&6
ba479fd2
NN
1685if test "${ac_cv_target+set}" = set; then
1686 echo $ECHO_N "(cached) $ECHO_C" >&6
1687else
b61ff9c8
BS
1688 ac_cv_target_alias=$target_alias
1689test "x$ac_cv_target_alias" = "x" &&
1690 ac_cv_target_alias=$ac_cv_host_alias
1691ac_cv_target=`$ac_config_sub $ac_cv_target_alias` ||
1692 { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_target_alias failed" >&5
1693echo "$as_me: error: $ac_config_sub $ac_cv_target_alias failed" >&2;}
ba479fd2
NN
1694 { (exit 1); exit 1; }; }
1695
1696fi
b61ff9c8
BS
1697echo "$as_me:$LINENO: result: $ac_cv_target" >&5
1698echo "${ECHO_T}$ac_cv_target" >&6
ba479fd2 1699target=$ac_cv_target
b61ff9c8
BS
1700target_cpu=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1701target_vendor=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1702target_os=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
ba479fd2
NN
1703
1704
1705# The aliases save the names the user supplied, while $host etc.
1706# will get canonicalized.
1707test -n "$target_alias" &&
1708 test "$program_prefix$program_suffix$program_transform_name" = \
1709 NONENONEs,x,x, &&
1710 program_prefix=${target_alias}-
1711
1712# Determine the noncanonical target name, for directory use.
18fc9bd4
RG
1713 case ${build_alias} in
1714 "") build_noncanonical=${build} ;;
1715 *) build_noncanonical=${build_alias} ;;
1716esac
1717
1718 case ${host_alias} in
1719 "") host_noncanonical=${build_noncanonical} ;;
1720 *) host_noncanonical=${host_alias} ;;
1721esac
1722
1723 case ${target_alias} in
1724 "") target_noncanonical=${host_noncanonical} ;;
1725 *) target_noncanonical=${target_alias} ;;
1726esac
1727
1728
1729
8f1529e6
L
1730
1731# Determine the target- and build-specific subdirectories
57255173
PB
1732
1733# post-stage1 host modules use a different CC_FOR_BUILD so, in order to
1734# have matching libraries, they should use host libraries: Makefile.tpl
1735# arranges to pass --with-build-libsubdir=$(HOST_SUBDIR).
1736# However, they still use the build modules, because the corresponding
1737# host modules (e.g. bison) are only built for the host when bootstrap
1738# finishes. So:
1739# - build_subdir is where we find build modules, and never changes.
1740# - build_libsubdir is where we find build libraries, and can be overridden.
1741
1742# Prefix 'build-' so this never conflicts with target_subdir.
18fc9bd4 1743build_subdir="build-${build_noncanonical}"
1546bb64 1744
b61ff9c8 1745# Check whether --with-build-libsubdir or --without-build-libsubdir was given.
1546bb64 1746if test "${with_build_libsubdir+set}" = set; then
b61ff9c8
BS
1747 withval="$with_build_libsubdir"
1748 build_libsubdir="$withval"
1546bb64
PB
1749else
1750 build_libsubdir="$build_subdir"
b61ff9c8 1751fi;
18fc9bd4
RG
1752# --srcdir=. covers the toplevel, while "test -d" covers the subdirectories
1753if ( test $srcdir = . && test -d gcc ) \
1754 || test -d $srcdir/../host-${host_noncanonical}; then
1755 host_subdir="host-${host_noncanonical}"
1756else
1757 host_subdir=.
1758fi
1759# No prefix.
1760target_subdir=${target_noncanonical}
1761
73458fb7 1762
093e61a6 1763# Set program_transform_name
13c22933 1764test "$program_prefix" != NONE &&
b61ff9c8 1765 program_transform_name="s,^,$program_prefix,;$program_transform_name"
13c22933
JJ
1766# Use a double $ so make ignores it.
1767test "$program_suffix" != NONE &&
b61ff9c8 1768 program_transform_name="s,\$,$program_suffix,;$program_transform_name"
ba479fd2
NN
1769# Double any \ or $. echo might interpret backslashes.
1770# By default was `s,x,x', remove it if useless.
1771cat <<\_ACEOF >conftest.sed
1772s/[\\$]/&&/g;s/;s,x,x,$//
1773_ACEOF
1774program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
b61ff9c8 1775rm conftest.sed
13c22933
JJ
1776
1777
34a86c2b
NN
1778# Check for bogus environment variables.
1779# Test if LIBRARY_PATH contains the notation for the current directory
1780# since this would lead to problems installing/building glibc.
1781# LIBRARY_PATH contains the current directory if one of the following
1782# is true:
1783# - one of the terminals (":" and ";") is the first or last sign
1784# - two terminals occur directly after each other
1785# - the path contains an element with a dot in it
b61ff9c8
BS
1786echo "$as_me:$LINENO: checking LIBRARY_PATH variable" >&5
1787echo $ECHO_N "checking LIBRARY_PATH variable... $ECHO_C" >&6
34a86c2b
NN
1788case ${LIBRARY_PATH} in
1789 [:\;]* | *[:\;] | *[:\;][:\;]* | *[:\;]. | .[:\;]*| . | *[:\;].[:\;]* )
1790 library_path_setting="contains current directory"
1791 ;;
1792 *)
1793 library_path_setting="ok"
1794 ;;
1795esac
b61ff9c8
BS
1796echo "$as_me:$LINENO: result: $library_path_setting" >&5
1797echo "${ECHO_T}$library_path_setting" >&6
34a86c2b 1798if test "$library_path_setting" != "ok"; then
ba479fd2 1799{ { echo "$as_me:$LINENO: error:
34a86c2b
NN
1800*** LIBRARY_PATH shouldn't contain the current directory when
1801*** building gcc. Please change the environment variable
ba479fd2
NN
1802*** and run configure again." >&5
1803echo "$as_me: error:
1804*** LIBRARY_PATH shouldn't contain the current directory when
1805*** building gcc. Please change the environment variable
1806*** and run configure again." >&2;}
1807 { (exit 1); exit 1; }; }
e9a25f70
JL
1808fi
1809
34a86c2b
NN
1810# Test if GCC_EXEC_PREFIX contains the notation for the current directory
1811# since this would lead to problems installing/building glibc.
1812# GCC_EXEC_PREFIX contains the current directory if one of the following
1813# is true:
1814# - one of the terminals (":" and ";") is the first or last sign
1815# - two terminals occur directly after each other
1816# - the path contains an element with a dot in it
b61ff9c8
BS
1817echo "$as_me:$LINENO: checking GCC_EXEC_PREFIX variable" >&5
1818echo $ECHO_N "checking GCC_EXEC_PREFIX variable... $ECHO_C" >&6
34a86c2b
NN
1819case ${GCC_EXEC_PREFIX} in
1820 [:\;]* | *[:\;] | *[:\;][:\;]* | *[:\;]. | .[:\;]*| . | *[:\;].[:\;]* )
1821 gcc_exec_prefix_setting="contains current directory"
1822 ;;
1823 *)
1824 gcc_exec_prefix_setting="ok"
1825 ;;
1826esac
b61ff9c8
BS
1827echo "$as_me:$LINENO: result: $gcc_exec_prefix_setting" >&5
1828echo "${ECHO_T}$gcc_exec_prefix_setting" >&6
34a86c2b 1829if test "$gcc_exec_prefix_setting" != "ok"; then
ba479fd2
NN
1830{ { echo "$as_me:$LINENO: error:
1831*** GCC_EXEC_PREFIX shouldn't contain the current directory when
1832*** building gcc. Please change the environment variable
1833*** and run configure again." >&5
1834echo "$as_me: error:
cafe096b
EC
1835*** GCC_EXEC_PREFIX shouldn't contain the current directory when
1836*** building gcc. Please change the environment variable
ba479fd2
NN
1837*** and run configure again." >&2;}
1838 { (exit 1); exit 1; }; }
34a86c2b
NN
1839fi
1840
1841# -----------
1842# Directories
1843# -----------
1844
1845# Specify the local prefix
1846local_prefix=
ba479fd2 1847
b61ff9c8 1848# Check whether --with-local-prefix or --without-local-prefix was given.
34a86c2b 1849if test "${with_local_prefix+set}" = set; then
b61ff9c8
BS
1850 withval="$with_local_prefix"
1851 case "${withval}" in
ba479fd2
NN
1852yes) { { echo "$as_me:$LINENO: error: bad value ${withval} given for local include directory prefix" >&5
1853echo "$as_me: error: bad value ${withval} given for local include directory prefix" >&2;}
1854 { (exit 1); exit 1; }; } ;;
34a86c2b
NN
1855no) ;;
1856*) local_prefix=$with_local_prefix ;;
1857esac
b61ff9c8 1858fi;
34a86c2b
NN
1859
1860# Default local prefix if it is empty
1861if test x$local_prefix = x; then
1862 local_prefix=/usr/local
1863fi
1864
1865# Don't set gcc_gxx_include_dir to gxx_include_dir since that's only
1866# passed in by the toplevel make and thus we'd get different behavior
1867# depending on where we built the sources.
1868gcc_gxx_include_dir=
1869# Specify the g++ header file directory
ba479fd2 1870
b61ff9c8 1871# Check whether --with-gxx-include-dir or --without-gxx-include-dir was given.
34a86c2b 1872if test "${with_gxx_include_dir+set}" = set; then
b61ff9c8
BS
1873 withval="$with_gxx_include_dir"
1874 case "${withval}" in
ba479fd2
NN
1875yes) { { echo "$as_me:$LINENO: error: bad value ${withval} given for g++ include directory" >&5
1876echo "$as_me: error: bad value ${withval} given for g++ include directory" >&2;}
1877 { (exit 1); exit 1; }; } ;;
34a86c2b
NN
1878no) ;;
1879*) gcc_gxx_include_dir=$with_gxx_include_dir ;;
1880esac
b61ff9c8 1881fi;
34a86c2b 1882
0f57bf40 1883# This logic must match libstdc++-v3/acinclude.m4:GLIBCXX_EXPORT_INSTALL_INFO.
34a86c2b
NN
1884if test x${gcc_gxx_include_dir} = x; then
1885 if test x${enable_version_specific_runtime_libs} = xyes; then
1886 gcc_gxx_include_dir='${libsubdir}/include/c++'
1887 else
0f57bf40
MM
1888 libstdcxx_incdir='include/c++/$(version)'
1889 if test x$host != x$target; then
1890 libstdcxx_incdir="$target_alias/$libstdcxx_incdir"
1891 fi
15c723f3 1892 gcc_gxx_include_dir="\$(libsubdir)/\$(libsubdir_to_prefix)$libstdcxx_incdir"
34a86c2b
NN
1893 fi
1894fi
1895
ba479fd2 1896
b61ff9c8 1897# Check whether --with-cpp_install_dir or --without-cpp_install_dir was given.
34a86c2b 1898if test "${with_cpp_install_dir+set}" = set; then
b61ff9c8
BS
1899 withval="$with_cpp_install_dir"
1900 if test x$withval = xyes; then
ba479fd2
NN
1901 { { echo "$as_me:$LINENO: error: option --with-cpp-install-dir requires an argument" >&5
1902echo "$as_me: error: option --with-cpp-install-dir requires an argument" >&2;}
1903 { (exit 1); exit 1; }; }
34a86c2b
NN
1904elif test x$withval != xno; then
1905 cpp_install_dir=$withval
1906fi
b61ff9c8 1907fi;
34a86c2b 1908
51b9ff45 1909# We would like to our source tree to be readonly. However when releases or
ba479fd2 1910# pre-releases are generated, the flex/bison generated files as well as the
51b9ff45 1911# various formats of manuals need to be included along with the rest of the
ba479fd2 1912# sources. Therefore we have --enable-generated-files-in-srcdir to do
51b9ff45
KC
1913# just that.
1914
b61ff9c8
BS
1915echo "$as_me:$LINENO: checking whether to place generated files in the source directory" >&5
1916echo $ECHO_N "checking whether to place generated files in the source directory... $ECHO_C" >&6
1917 # Check whether --enable-generated-files-in-srcdir or --disable-generated-files-in-srcdir was given.
51b9ff45 1918if test "${enable_generated_files_in_srcdir+set}" = set; then
b61ff9c8
BS
1919 enableval="$enable_generated_files_in_srcdir"
1920 generated_files_in_srcdir=$enableval
51b9ff45 1921else
03787dfd 1922 generated_files_in_srcdir=no
b61ff9c8 1923fi;
1a4b763e 1924
b61ff9c8
BS
1925echo "$as_me:$LINENO: result: $generated_files_in_srcdir" >&5
1926echo "${ECHO_T}$generated_files_in_srcdir" >&6
03787dfd
KC
1927
1928if test "$generated_files_in_srcdir" = "yes"; then
1929 GENINSRC=''
03787dfd
KC
1930else
1931 GENINSRC='#'
03787dfd
KC
1932fi
1933
1934
34a86c2b
NN
1935# -------------------
1936# Find default linker
1937# -------------------
1938
1939# With GNU ld
ba479fd2 1940
b61ff9c8 1941# Check whether --with-gnu-ld or --without-gnu-ld was given.
34a86c2b 1942if test "${with_gnu_ld+set}" = set; then
b61ff9c8
BS
1943 withval="$with_gnu_ld"
1944 gnu_ld_flag="$with_gnu_ld"
34a86c2b
NN
1945else
1946 gnu_ld_flag=no
b61ff9c8 1947fi;
6e3f3080 1948
63cf211a 1949# With pre-defined ld
ba479fd2 1950
b61ff9c8 1951# Check whether --with-ld or --without-ld was given.
34a86c2b 1952if test "${with_ld+set}" = set; then
b61ff9c8
BS
1953 withval="$with_ld"
1954 DEFAULT_LINKER="$with_ld"
1955fi;
34a86c2b
NN
1956if test x"${DEFAULT_LINKER+set}" = x"set"; then
1957 if test ! -x "$DEFAULT_LINKER"; then
99c012a8
BE
1958 { { echo "$as_me:$LINENO: error: cannot execute: $DEFAULT_LINKER: check --with-ld or env. var. DEFAULT_LINKER" >&5
1959echo "$as_me: error: cannot execute: $DEFAULT_LINKER: check --with-ld or env. var. DEFAULT_LINKER" >&2;}
1960 { (exit 1); exit 1; }; }
34a86c2b
NN
1961 elif $DEFAULT_LINKER -v < /dev/null 2>&1 | grep GNU > /dev/null; then
1962 gnu_ld_flag=yes
1963 fi
ba479fd2
NN
1964
1965cat >>confdefs.h <<_ACEOF
34a86c2b 1966#define DEFAULT_LINKER "$DEFAULT_LINKER"
ba479fd2 1967_ACEOF
34a86c2b
NN
1968
1969fi
1970
2091ff66
NF
1971gnu_ld=`if test x"$gnu_ld_flag" = x"yes"; then echo 1; else echo 0; fi`
1972
1973cat >>confdefs.h <<_ACEOF
1974#define HAVE_GNU_LD $gnu_ld
1975_ACEOF
1976
1977
b61ff9c8
BS
1978echo "$as_me:$LINENO: checking whether a default linker was specified" >&5
1979echo $ECHO_N "checking whether a default linker was specified... $ECHO_C" >&6
34a86c2b
NN
1980if test x"${DEFAULT_LINKER+set}" = x"set"; then
1981 if test x"$gnu_ld_flag" = x"no"; then
b61ff9c8
BS
1982 echo "$as_me:$LINENO: result: yes ($DEFAULT_LINKER)" >&5
1983echo "${ECHO_T}yes ($DEFAULT_LINKER)" >&6
34a86c2b 1984 else
b61ff9c8
BS
1985 echo "$as_me:$LINENO: result: yes ($DEFAULT_LINKER - GNU ld)" >&5
1986echo "${ECHO_T}yes ($DEFAULT_LINKER - GNU ld)" >&6
34a86c2b
NN
1987 fi
1988else
b61ff9c8
BS
1989 echo "$as_me:$LINENO: result: no" >&5
1990echo "${ECHO_T}no" >&6
34a86c2b
NN
1991fi
1992
d594623a
L
1993# With demangler in GNU ld
1994
b61ff9c8 1995# Check whether --with-demangler-in-ld or --without-demangler-in-ld was given.
d594623a 1996if test "${with_demangler_in_ld+set}" = set; then
b61ff9c8
BS
1997 withval="$with_demangler_in_ld"
1998 demangler_in_ld="$with_demangler_in_ld"
d594623a
L
1999else
2000 demangler_in_ld=no
b61ff9c8 2001fi;
d594623a 2002
34a86c2b
NN
2003# ----------------------
2004# Find default assembler
2005# ----------------------
2006
2007# With GNU as
ba479fd2 2008
b61ff9c8 2009# Check whether --with-gnu-as or --without-gnu-as was given.
34a86c2b 2010if test "${with_gnu_as+set}" = set; then
b61ff9c8
BS
2011 withval="$with_gnu_as"
2012 gas_flag="$with_gnu_as"
34a86c2b
NN
2013else
2014 gas_flag=no
b61ff9c8 2015fi;
ab22c1fa 2016
1a4b763e 2017
b61ff9c8 2018# Check whether --with-as or --without-as was given.
34a86c2b 2019if test "${with_as+set}" = set; then
b61ff9c8
BS
2020 withval="$with_as"
2021 DEFAULT_ASSEMBLER="$with_as"
2022fi;
34a86c2b
NN
2023if test x"${DEFAULT_ASSEMBLER+set}" = x"set"; then
2024 if test ! -x "$DEFAULT_ASSEMBLER"; then
99c012a8
BE
2025 { { echo "$as_me:$LINENO: error: cannot execute: $DEFAULT_ASSEMBLER: check --with-as or env. var. DEFAULT_ASSEMBLER" >&5
2026echo "$as_me: error: cannot execute: $DEFAULT_ASSEMBLER: check --with-as or env. var. DEFAULT_ASSEMBLER" >&2;}
2027 { (exit 1); exit 1; }; }
34a86c2b
NN
2028 elif $DEFAULT_ASSEMBLER -v < /dev/null 2>&1 | grep GNU > /dev/null; then
2029 gas_flag=yes
2030 fi
ba479fd2
NN
2031
2032cat >>confdefs.h <<_ACEOF
34a86c2b 2033#define DEFAULT_ASSEMBLER "$DEFAULT_ASSEMBLER"
ba479fd2 2034_ACEOF
34a86c2b
NN
2035
2036fi
2037
dc60b775
CD
2038gnu_as=`if test x"$gas_flag" = x"yes"; then echo 1; else echo 0; fi`
2039
2040cat >>confdefs.h <<_ACEOF
2041#define HAVE_GNU_AS $gnu_as
2042_ACEOF
2043
2044
b61ff9c8
BS
2045echo "$as_me:$LINENO: checking whether a default assembler was specified" >&5
2046echo $ECHO_N "checking whether a default assembler was specified... $ECHO_C" >&6
34a86c2b
NN
2047if test x"${DEFAULT_ASSEMBLER+set}" = x"set"; then
2048 if test x"$gas_flag" = x"no"; then
b61ff9c8
BS
2049 echo "$as_me:$LINENO: result: yes ($DEFAULT_ASSEMBLER)" >&5
2050echo "${ECHO_T}yes ($DEFAULT_ASSEMBLER)" >&6
34a86c2b 2051 else
b61ff9c8
BS
2052 echo "$as_me:$LINENO: result: yes ($DEFAULT_ASSEMBLER - GNU as)" >&5
2053echo "${ECHO_T}yes ($DEFAULT_ASSEMBLER - GNU as)" >&6
34a86c2b
NN
2054 fi
2055else
b61ff9c8
BS
2056 echo "$as_me:$LINENO: result: no" >&5
2057echo "${ECHO_T}no" >&6
34a86c2b
NN
2058fi
2059
2060# ---------------
2061# Find C compiler
2062# ---------------
2063
426ca3ca
RO
2064# If a non-executable a.out is present (e.g. created by GNU as above even if
2065# invoked with -v only), the IRIX 6 native ld just overwrites the existing
2066# file, even when creating an executable, so an execution test fails.
2067# Remove possible default executable files to avoid this.
2068#
2069# FIXME: This really belongs into AC_PROG_CC and can be removed once
2070# Autoconf includes it.
2071rm -f a.out a.exe b.out
2072
34a86c2b 2073# Find the native compiler
ba479fd2
NN
2074ac_ext=c
2075ac_cpp='$CPP $CPPFLAGS'
2076ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2077ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2078ac_compiler_gnu=$ac_cv_c_compiler_gnu
2079if test -n "$ac_tool_prefix"; then
2080 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
2081set dummy ${ac_tool_prefix}gcc; ac_word=$2
b61ff9c8
BS
2082echo "$as_me:$LINENO: checking for $ac_word" >&5
2083echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
ba479fd2
NN
2084if test "${ac_cv_prog_CC+set}" = set; then
2085 echo $ECHO_N "(cached) $ECHO_C" >&6
2086else
2087 if test -n "$CC"; then
2088 ac_cv_prog_CC="$CC" # Let the user override the test.
2089else
2090as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2091for as_dir in $PATH
2092do
2093 IFS=$as_save_IFS
2094 test -z "$as_dir" && as_dir=.
2095 for ac_exec_ext in '' $ac_executable_extensions; do
b61ff9c8 2096 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ba479fd2
NN
2097 ac_cv_prog_CC="${ac_tool_prefix}gcc"
2098 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2099 break 2
2100 fi
2101done
2102done
2103
2104fi
2105fi
2106CC=$ac_cv_prog_CC
2107if test -n "$CC"; then
b61ff9c8
BS
2108 echo "$as_me:$LINENO: result: $CC" >&5
2109echo "${ECHO_T}$CC" >&6
ba479fd2 2110else
b61ff9c8
BS
2111 echo "$as_me:$LINENO: result: no" >&5
2112echo "${ECHO_T}no" >&6
ba479fd2
NN
2113fi
2114
2115fi
2116if test -z "$ac_cv_prog_CC"; then
2117 ac_ct_CC=$CC
2118 # Extract the first word of "gcc", so it can be a program name with args.
6e3f3080 2119set dummy gcc; ac_word=$2
b61ff9c8
BS
2120echo "$as_me:$LINENO: checking for $ac_word" >&5
2121echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
ba479fd2
NN
2122if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2123 echo $ECHO_N "(cached) $ECHO_C" >&6
2124else
2125 if test -n "$ac_ct_CC"; then
2126 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2127else
2128as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2129for as_dir in $PATH
2130do
2131 IFS=$as_save_IFS
2132 test -z "$as_dir" && as_dir=.
2133 for ac_exec_ext in '' $ac_executable_extensions; do
b61ff9c8 2134 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ba479fd2
NN
2135 ac_cv_prog_ac_ct_CC="gcc"
2136 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2137 break 2
2138 fi
2139done
2140done
2141
2142fi
2143fi
2144ac_ct_CC=$ac_cv_prog_ac_ct_CC
2145if test -n "$ac_ct_CC"; then
b61ff9c8
BS
2146 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
2147echo "${ECHO_T}$ac_ct_CC" >&6
ba479fd2 2148else
b61ff9c8
BS
2149 echo "$as_me:$LINENO: result: no" >&5
2150echo "${ECHO_T}no" >&6
ba479fd2
NN
2151fi
2152
b61ff9c8 2153 CC=$ac_ct_CC
ba479fd2
NN
2154else
2155 CC="$ac_cv_prog_CC"
2156fi
2157
2158if test -z "$CC"; then
b61ff9c8
BS
2159 if test -n "$ac_tool_prefix"; then
2160 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
ba479fd2 2161set dummy ${ac_tool_prefix}cc; ac_word=$2
b61ff9c8
BS
2162echo "$as_me:$LINENO: checking for $ac_word" >&5
2163echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
ba479fd2
NN
2164if test "${ac_cv_prog_CC+set}" = set; then
2165 echo $ECHO_N "(cached) $ECHO_C" >&6
cd9e5e7c
MK
2166else
2167 if test -n "$CC"; then
2168 ac_cv_prog_CC="$CC" # Let the user override the test.
2169else
ba479fd2
NN
2170as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2171for as_dir in $PATH
2172do
2173 IFS=$as_save_IFS
2174 test -z "$as_dir" && as_dir=.
2175 for ac_exec_ext in '' $ac_executable_extensions; do
b61ff9c8 2176 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ba479fd2
NN
2177 ac_cv_prog_CC="${ac_tool_prefix}cc"
2178 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2179 break 2
2180 fi
2181done
2182done
2183
cd9e5e7c
MK
2184fi
2185fi
ba479fd2 2186CC=$ac_cv_prog_CC
cd9e5e7c 2187if test -n "$CC"; then
b61ff9c8
BS
2188 echo "$as_me:$LINENO: result: $CC" >&5
2189echo "${ECHO_T}$CC" >&6
2f41c1d6 2190else
b61ff9c8
BS
2191 echo "$as_me:$LINENO: result: no" >&5
2192echo "${ECHO_T}no" >&6
2f41c1d6
PB
2193fi
2194
b61ff9c8
BS
2195fi
2196if test -z "$ac_cv_prog_CC"; then
2197 ac_ct_CC=$CC
2198 # Extract the first word of "cc", so it can be a program name with args.
2199set dummy cc; ac_word=$2
2200echo "$as_me:$LINENO: checking for $ac_word" >&5
2201echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2202if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2203 echo $ECHO_N "(cached) $ECHO_C" >&6
2204else
2205 if test -n "$ac_ct_CC"; then
2206 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2207else
2208as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2209for as_dir in $PATH
2210do
2211 IFS=$as_save_IFS
2212 test -z "$as_dir" && as_dir=.
2213 for ac_exec_ext in '' $ac_executable_extensions; do
2214 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2215 ac_cv_prog_ac_ct_CC="cc"
2216 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2217 break 2
1a4b763e 2218 fi
b61ff9c8
BS
2219done
2220done
2221
2222fi
2223fi
2224ac_ct_CC=$ac_cv_prog_ac_ct_CC
2225if test -n "$ac_ct_CC"; then
2226 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
2227echo "${ECHO_T}$ac_ct_CC" >&6
2228else
2229 echo "$as_me:$LINENO: result: no" >&5
2230echo "${ECHO_T}no" >&6
2231fi
2232
2233 CC=$ac_ct_CC
2234else
2235 CC="$ac_cv_prog_CC"
2236fi
2237
ba479fd2 2238fi
6e3f3080
NN
2239if test -z "$CC"; then
2240 # Extract the first word of "cc", so it can be a program name with args.
2241set dummy cc; ac_word=$2
b61ff9c8
BS
2242echo "$as_me:$LINENO: checking for $ac_word" >&5
2243echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
ba479fd2
NN
2244if test "${ac_cv_prog_CC+set}" = set; then
2245 echo $ECHO_N "(cached) $ECHO_C" >&6
6e3f3080
NN
2246else
2247 if test -n "$CC"; then
2248 ac_cv_prog_CC="$CC" # Let the user override the test.
2249else
2250 ac_prog_rejected=no
ba479fd2
NN
2251as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2252for as_dir in $PATH
2253do
2254 IFS=$as_save_IFS
2255 test -z "$as_dir" && as_dir=.
2256 for ac_exec_ext in '' $ac_executable_extensions; do
b61ff9c8 2257 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ba479fd2
NN
2258 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
2259 ac_prog_rejected=yes
2260 continue
2261 fi
2262 ac_cv_prog_CC="cc"
2263 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2264 break 2
2265 fi
2266done
2267done
2268
6e3f3080
NN
2269if test $ac_prog_rejected = yes; then
2270 # We found a bogon in the path, so make sure we never use it.
2271 set dummy $ac_cv_prog_CC
2272 shift
ba479fd2 2273 if test $# != 0; then
6e3f3080
NN
2274 # We chose a different compiler from the bogus one.
2275 # However, it has the same basename, so the bogon will be chosen
2276 # first if we set CC to just the basename; use the full file name.
2277 shift
ba479fd2 2278 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
e9a25f70 2279 fi
6e3f3080
NN
2280fi
2281fi
2282fi
ba479fd2 2283CC=$ac_cv_prog_CC
6e3f3080 2284if test -n "$CC"; then
b61ff9c8
BS
2285 echo "$as_me:$LINENO: result: $CC" >&5
2286echo "${ECHO_T}$CC" >&6
e9a25f70 2287else
b61ff9c8
BS
2288 echo "$as_me:$LINENO: result: no" >&5
2289echo "${ECHO_T}no" >&6
e9a25f70 2290fi
6e3f3080 2291
ba479fd2
NN
2292fi
2293if test -z "$CC"; then
2294 if test -n "$ac_tool_prefix"; then
b61ff9c8 2295 for ac_prog in cl
ba479fd2
NN
2296 do
2297 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2298set dummy $ac_tool_prefix$ac_prog; ac_word=$2
b61ff9c8
BS
2299echo "$as_me:$LINENO: checking for $ac_word" >&5
2300echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
ba479fd2
NN
2301if test "${ac_cv_prog_CC+set}" = set; then
2302 echo $ECHO_N "(cached) $ECHO_C" >&6
093e61a6 2303else
6e3f3080
NN
2304 if test -n "$CC"; then
2305 ac_cv_prog_CC="$CC" # Let the user override the test.
2306else
ba479fd2
NN
2307as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2308for as_dir in $PATH
2309do
2310 IFS=$as_save_IFS
2311 test -z "$as_dir" && as_dir=.
2312 for ac_exec_ext in '' $ac_executable_extensions; do
b61ff9c8 2313 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ba479fd2
NN
2314 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
2315 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2316 break 2
2317 fi
2318done
2319done
2320
093e61a6 2321fi
6e3f3080 2322fi
ba479fd2 2323CC=$ac_cv_prog_CC
6e3f3080 2324if test -n "$CC"; then
b61ff9c8
BS
2325 echo "$as_me:$LINENO: result: $CC" >&5
2326echo "${ECHO_T}$CC" >&6
6e3f3080 2327else
b61ff9c8
BS
2328 echo "$as_me:$LINENO: result: no" >&5
2329echo "${ECHO_T}no" >&6
093e61a6 2330fi
cafe096b 2331
ba479fd2
NN
2332 test -n "$CC" && break
2333 done
2334fi
2335if test -z "$CC"; then
2336 ac_ct_CC=$CC
b61ff9c8 2337 for ac_prog in cl
ba479fd2
NN
2338do
2339 # Extract the first word of "$ac_prog", so it can be a program name with args.
2340set dummy $ac_prog; ac_word=$2
b61ff9c8
BS
2341echo "$as_me:$LINENO: checking for $ac_word" >&5
2342echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
ba479fd2
NN
2343if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2344 echo $ECHO_N "(cached) $ECHO_C" >&6
2345else
2346 if test -n "$ac_ct_CC"; then
2347 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2348else
2349as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2350for as_dir in $PATH
2351do
2352 IFS=$as_save_IFS
2353 test -z "$as_dir" && as_dir=.
2354 for ac_exec_ext in '' $ac_executable_extensions; do
b61ff9c8 2355 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ba479fd2
NN
2356 ac_cv_prog_ac_ct_CC="$ac_prog"
2357 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2358 break 2
2359 fi
2360done
2361done
6e3f3080 2362
ba479fd2
NN
2363fi
2364fi
2365ac_ct_CC=$ac_cv_prog_ac_ct_CC
2366if test -n "$ac_ct_CC"; then
b61ff9c8
BS
2367 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
2368echo "${ECHO_T}$ac_ct_CC" >&6
ba479fd2 2369else
b61ff9c8
BS
2370 echo "$as_me:$LINENO: result: no" >&5
2371echo "${ECHO_T}no" >&6
ba479fd2 2372fi
6e3f3080 2373
ba479fd2
NN
2374 test -n "$ac_ct_CC" && break
2375done
63cf211a 2376
b61ff9c8 2377 CC=$ac_ct_CC
ba479fd2
NN
2378fi
2379
2380fi
2381
2382
18c04407
RW
2383test -z "$CC" && { { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
2384echo "$as_me: error: in \`$ac_pwd':" >&2;}
2385{ { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
ba479fd2
NN
2386See \`config.log' for more details." >&5
2387echo "$as_me: error: no acceptable C compiler found in \$PATH
2388See \`config.log' for more details." >&2;}
18c04407 2389 { (exit 1); exit 1; }; }; }
ba479fd2
NN
2390
2391# Provide some information about the compiler.
b61ff9c8
BS
2392echo "$as_me:$LINENO:" \
2393 "checking for C compiler version" >&5
ba479fd2 2394ac_compiler=`set X $ac_compile; echo $2`
b61ff9c8
BS
2395{ (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
2396 (eval $ac_compiler --version </dev/null >&5) 2>&5
ba479fd2
NN
2397 ac_status=$?
2398 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2399 (exit $ac_status); }
b61ff9c8
BS
2400{ (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
2401 (eval $ac_compiler -v </dev/null >&5) 2>&5
ba479fd2
NN
2402 ac_status=$?
2403 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2404 (exit $ac_status); }
b61ff9c8
BS
2405{ (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
2406 (eval $ac_compiler -V </dev/null >&5) 2>&5
ba479fd2
NN
2407 ac_status=$?
2408 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2409 (exit $ac_status); }
2410
2411cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
2412/* confdefs.h. */
2413_ACEOF
2414cat confdefs.h >>conftest.$ac_ext
2415cat >>conftest.$ac_ext <<_ACEOF
2416/* end confdefs.h. */
2417
2418int
2419main ()
2420{
63cf211a 2421
ba479fd2
NN
2422 ;
2423 return 0;
2424}
2425_ACEOF
2426ac_clean_files_save=$ac_clean_files
2427ac_clean_files="$ac_clean_files a.out a.exe b.out"
2428# Try to create an executable without -o first, disregard a.out.
2429# It will help us diagnose broken compilers, and finding out an intuition
2430# of exeext.
b61ff9c8
BS
2431echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
2432echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6
ba479fd2 2433ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
b61ff9c8
BS
2434if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
2435 (eval $ac_link_default) 2>&5
ba479fd2
NN
2436 ac_status=$?
2437 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2438 (exit $ac_status); }; then
b61ff9c8
BS
2439 # Find the output, starting from the most likely. This scheme is
2440# not robust to junk in `.', hence go to wildcards (a.*) only as a last
2441# resort.
2442
2443# Be careful to initialize this variable, since it used to be cached.
2444# Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
2445ac_cv_exeext=
2446# b.out is created by i960 compilers.
2447for ac_file in a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out
ba479fd2
NN
2448do
2449 test -f "$ac_file" || continue
2450 case $ac_file in
b61ff9c8
BS
2451 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj )
2452 ;;
2453 conftest.$ac_ext )
2454 # This is the source file.
86da66b5 2455 ;;
ba479fd2 2456 [ab].out )
86da66b5
HPN
2457 # We found the default executable, but exeext='' is most
2458 # certainly right.
2459 break;;
ba479fd2 2460 *.* )
b61ff9c8
BS
2461 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2462 # FIXME: I believe we export ac_cv_exeext for Libtool,
2463 # but it would be cool to find out if it's true. Does anybody
2464 # maintain Libtool? --akim.
2465 export ac_cv_exeext
86da66b5 2466 break;;
ba479fd2 2467 * )
86da66b5 2468 break;;
ba479fd2
NN
2469 esac
2470done
2471else
2472 echo "$as_me: failed program was:" >&5
2473sed 's/^/| /' conftest.$ac_ext >&5
2474
18c04407
RW
2475{ { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
2476echo "$as_me: error: in \`$ac_pwd':" >&2;}
ba479fd2
NN
2477{ { echo "$as_me:$LINENO: error: C compiler cannot create executables
2478See \`config.log' for more details." >&5
2479echo "$as_me: error: C compiler cannot create executables
2480See \`config.log' for more details." >&2;}
18c04407 2481 { (exit 77); exit 77; }; }; }
ba479fd2
NN
2482fi
2483
2484ac_exeext=$ac_cv_exeext
b61ff9c8
BS
2485echo "$as_me:$LINENO: result: $ac_file" >&5
2486echo "${ECHO_T}$ac_file" >&6
ba479fd2 2487
b61ff9c8 2488# Check the compiler produces executables we can run. If not, either
ba479fd2 2489# the compiler is broken, or we cross compile.
b61ff9c8
BS
2490echo "$as_me:$LINENO: checking whether the C compiler works" >&5
2491echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
ba479fd2
NN
2492# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
2493# If not cross compiling, check that we can run a simple program.
2494if test "$cross_compiling" != yes; then
2495 if { ac_try='./$ac_file'
b61ff9c8
BS
2496 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2497 (eval $ac_try) 2>&5
ba479fd2
NN
2498 ac_status=$?
2499 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2500 (exit $ac_status); }; }; then
2501 cross_compiling=no
6e3f3080 2502 else
ba479fd2
NN
2503 if test "$cross_compiling" = maybe; then
2504 cross_compiling=yes
2505 else
18c04407
RW
2506 { { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
2507echo "$as_me: error: in \`$ac_pwd':" >&2;}
2508{ { echo "$as_me:$LINENO: error: cannot run C compiled programs.
ba479fd2
NN
2509If you meant to cross compile, use \`--host'.
2510See \`config.log' for more details." >&5
2511echo "$as_me: error: cannot run C compiled programs.
2512If you meant to cross compile, use \`--host'.
2513See \`config.log' for more details." >&2;}
18c04407 2514 { (exit 1); exit 1; }; }; }
ba479fd2 2515 fi
6e3f3080
NN
2516 fi
2517fi
b61ff9c8
BS
2518echo "$as_me:$LINENO: result: yes" >&5
2519echo "${ECHO_T}yes" >&6
ba479fd2
NN
2520
2521rm -f a.out a.exe conftest$ac_cv_exeext b.out
2522ac_clean_files=$ac_clean_files_save
b61ff9c8 2523# Check the compiler produces executables we can run. If not, either
ba479fd2 2524# the compiler is broken, or we cross compile.
b61ff9c8
BS
2525echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
2526echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
2527echo "$as_me:$LINENO: result: $cross_compiling" >&5
2528echo "${ECHO_T}$cross_compiling" >&6
2529
2530echo "$as_me:$LINENO: checking for suffix of executables" >&5
2531echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
2532if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
2533 (eval $ac_link) 2>&5
ba479fd2
NN
2534 ac_status=$?
2535 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2536 (exit $ac_status); }; then
2537 # If both `conftest.exe' and `conftest' are `present' (well, observable)
2538# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
2539# work properly (i.e., refer to `conftest.exe'), while it won't with
2540# `rm'.
2541for ac_file in conftest.exe conftest conftest.*; do
2542 test -f "$ac_file" || continue
2543 case $ac_file in
b61ff9c8 2544 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj ) ;;
ba479fd2 2545 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
b61ff9c8 2546 export ac_cv_exeext
86da66b5 2547 break;;
ba479fd2
NN
2548 * ) break;;
2549 esac
2550done
e9a25f70 2551else
18c04407
RW
2552 { { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
2553echo "$as_me: error: in \`$ac_pwd':" >&2;}
2554{ { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
ba479fd2
NN
2555See \`config.log' for more details." >&5
2556echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
2557See \`config.log' for more details." >&2;}
18c04407 2558 { (exit 1); exit 1; }; }; }
ba479fd2
NN
2559fi
2560
2561rm -f conftest$ac_cv_exeext
b61ff9c8
BS
2562echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
2563echo "${ECHO_T}$ac_cv_exeext" >&6
ba479fd2
NN
2564
2565rm -f conftest.$ac_ext
2566EXEEXT=$ac_cv_exeext
2567ac_exeext=$EXEEXT
b61ff9c8
BS
2568echo "$as_me:$LINENO: checking for suffix of object files" >&5
2569echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6
ba479fd2
NN
2570if test "${ac_cv_objext+set}" = set; then
2571 echo $ECHO_N "(cached) $ECHO_C" >&6
2572else
2573 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
2574/* confdefs.h. */
2575_ACEOF
2576cat confdefs.h >>conftest.$ac_ext
2577cat >>conftest.$ac_ext <<_ACEOF
2578/* end confdefs.h. */
2579
2580int
2581main ()
2582{
6e3f3080 2583
ba479fd2
NN
2584 ;
2585 return 0;
2586}
2587_ACEOF
2588rm -f conftest.o conftest.obj
b61ff9c8
BS
2589if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2590 (eval $ac_compile) 2>&5
ba479fd2
NN
2591 ac_status=$?
2592 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2593 (exit $ac_status); }; then
b61ff9c8 2594 for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
ba479fd2 2595 case $ac_file in
b61ff9c8 2596 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg ) ;;
ba479fd2
NN
2597 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
2598 break;;
2599 esac
2600done
63cf211a 2601else
ba479fd2
NN
2602 echo "$as_me: failed program was:" >&5
2603sed 's/^/| /' conftest.$ac_ext >&5
2604
18c04407
RW
2605{ { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
2606echo "$as_me: error: in \`$ac_pwd':" >&2;}
ba479fd2
NN
2607{ { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
2608See \`config.log' for more details." >&5
2609echo "$as_me: error: cannot compute suffix of object files: cannot compile
2610See \`config.log' for more details." >&2;}
18c04407 2611 { (exit 1); exit 1; }; }; }
ba479fd2
NN
2612fi
2613
2614rm -f conftest.$ac_cv_objext conftest.$ac_ext
2615fi
b61ff9c8
BS
2616echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
2617echo "${ECHO_T}$ac_cv_objext" >&6
ba479fd2
NN
2618OBJEXT=$ac_cv_objext
2619ac_objext=$OBJEXT
b61ff9c8
BS
2620echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
2621echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
ba479fd2
NN
2622if test "${ac_cv_c_compiler_gnu+set}" = set; then
2623 echo $ECHO_N "(cached) $ECHO_C" >&6
2624else
2625 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
2626/* confdefs.h. */
2627_ACEOF
2628cat confdefs.h >>conftest.$ac_ext
2629cat >>conftest.$ac_ext <<_ACEOF
2630/* end confdefs.h. */
2631
2632int
2633main ()
2634{
2635#ifndef __GNUC__
2636 choke me
2637#endif
6e3f3080 2638
ba479fd2
NN
2639 ;
2640 return 0;
2641}
2642_ACEOF
2643rm -f conftest.$ac_objext
b61ff9c8
BS
2644if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2645 (eval $ac_compile) 2>conftest.er1
ba479fd2 2646 ac_status=$?
86da66b5
HPN
2647 grep -v '^ *+' conftest.er1 >conftest.err
2648 rm -f conftest.er1
2649 cat conftest.err >&5
ba479fd2 2650 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
2651 (exit $ac_status); } &&
2652 { ac_try='test -z "$ac_c_werror_flag"
2653 || test ! -s conftest.err'
2654 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2655 (eval $ac_try) 2>&5
2656 ac_status=$?
2657 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2658 (exit $ac_status); }; } &&
2659 { ac_try='test -s conftest.$ac_objext'
2660 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2661 (eval $ac_try) 2>&5
2662 ac_status=$?
2663 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2664 (exit $ac_status); }; }; then
ba479fd2
NN
2665 ac_compiler_gnu=yes
2666else
2667 echo "$as_me: failed program was:" >&5
2668sed 's/^/| /' conftest.$ac_ext >&5
2669
b61ff9c8 2670ac_compiler_gnu=no
ba479fd2 2671fi
b61ff9c8 2672rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba479fd2
NN
2673ac_cv_c_compiler_gnu=$ac_compiler_gnu
2674
2675fi
b61ff9c8
BS
2676echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
2677echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
ba479fd2
NN
2678GCC=`test $ac_compiler_gnu = yes && echo yes`
2679ac_test_CFLAGS=${CFLAGS+set}
2680ac_save_CFLAGS=$CFLAGS
b61ff9c8
BS
2681CFLAGS="-g"
2682echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
2683echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
ba479fd2
NN
2684if test "${ac_cv_prog_cc_g+set}" = set; then
2685 echo $ECHO_N "(cached) $ECHO_C" >&6
2686else
b61ff9c8 2687 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
2688/* confdefs.h. */
2689_ACEOF
2690cat confdefs.h >>conftest.$ac_ext
2691cat >>conftest.$ac_ext <<_ACEOF
2692/* end confdefs.h. */
2693
2694int
2695main ()
2696{
2697
2698 ;
2699 return 0;
2700}
2701_ACEOF
2702rm -f conftest.$ac_objext
b61ff9c8
BS
2703if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2704 (eval $ac_compile) 2>conftest.er1
ba479fd2 2705 ac_status=$?
86da66b5
HPN
2706 grep -v '^ *+' conftest.er1 >conftest.err
2707 rm -f conftest.er1
2708 cat conftest.err >&5
ba479fd2 2709 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
2710 (exit $ac_status); } &&
2711 { ac_try='test -z "$ac_c_werror_flag"
2712 || test ! -s conftest.err'
2713 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2714 (eval $ac_try) 2>&5
2715 ac_status=$?
2716 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2717 (exit $ac_status); }; } &&
2718 { ac_try='test -s conftest.$ac_objext'
2719 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2720 (eval $ac_try) 2>&5
2721 ac_status=$?
2722 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2723 (exit $ac_status); }; }; then
1a4b763e
BS
2724 ac_cv_prog_cc_g=yes
2725else
2726 echo "$as_me: failed program was:" >&5
2727sed 's/^/| /' conftest.$ac_ext >&5
2728
b61ff9c8
BS
2729ac_cv_prog_cc_g=no
2730fi
2731rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2732fi
2733echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
2734echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
2735if test "$ac_test_CFLAGS" = set; then
2736 CFLAGS=$ac_save_CFLAGS
2737elif test $ac_cv_prog_cc_g = yes; then
2738 if test "$GCC" = yes; then
2739 CFLAGS="-g -O2"
2740 else
2741 CFLAGS="-g"
2742 fi
2743else
2744 if test "$GCC" = yes; then
2745 CFLAGS="-O2"
2746 else
2747 CFLAGS=
2748 fi
2749fi
2750echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
2751echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
2752if test "${ac_cv_prog_cc_stdc+set}" = set; then
2753 echo $ECHO_N "(cached) $ECHO_C" >&6
2754else
2755 ac_cv_prog_cc_stdc=no
2756ac_save_CC=$CC
2757cat >conftest.$ac_ext <<_ACEOF
1a4b763e
BS
2758/* confdefs.h. */
2759_ACEOF
2760cat confdefs.h >>conftest.$ac_ext
2761cat >>conftest.$ac_ext <<_ACEOF
2762/* end confdefs.h. */
b61ff9c8
BS
2763#include <stdarg.h>
2764#include <stdio.h>
2765#include <sys/types.h>
2766#include <sys/stat.h>
2767/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
2768struct buf { int x; };
2769FILE * (*rcsopen) (struct buf *, struct stat *, int);
2770static char *e (p, i)
2771 char **p;
2772 int i;
1a4b763e 2773{
b61ff9c8 2774 return p[i];
1a4b763e 2775}
b61ff9c8
BS
2776static char *f (char * (*g) (char **, int), char **p, ...)
2777{
2778 char *s;
2779 va_list v;
2780 va_start (v,p);
2781 s = g (p, va_arg (v,int));
2782 va_end (v);
2783 return s;
2784}
2785
2786/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
2787 function prototypes and stuff, but not '\xHH' hex character constants.
2788 These don't provoke an error unfortunately, instead are silently treated
2789 as 'x'. The following induces an error, until -std1 is added to get
2790 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
2791 array size at least. It's necessary to write '\x00'==0 to get something
2792 that's true only with -std1. */
2793int osf4_cc_array ['\x00' == 0 ? 1 : -1];
2794
2795int test (int i, double x);
2796struct s1 {int (*f) (int a);};
2797struct s2 {int (*f) (double a);};
2798int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
2799int argc;
2800char **argv;
2801int
2802main ()
2803{
2804return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
2805 ;
2806 return 0;
2807}
2808_ACEOF
2809# Don't try gcc -ansi; that turns off useful extensions and
2810# breaks some systems' header files.
2811# AIX -qlanglvl=ansi
2812# Ultrix and OSF/1 -std1
2813# HP-UX 10.20 and later -Ae
2814# HP-UX older versions -Aa -D_HPUX_SOURCE
2815# SVR4 -Xc -D__EXTENSIONS__
2816for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
2817do
2818 CC="$ac_save_CC $ac_arg"
2819 rm -f conftest.$ac_objext
2820if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2821 (eval $ac_compile) 2>conftest.er1
2822 ac_status=$?
1a4b763e
BS
2823 grep -v '^ *+' conftest.er1 >conftest.err
2824 rm -f conftest.er1
2825 cat conftest.err >&5
2f41c1d6 2826 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
2827 (exit $ac_status); } &&
2828 { ac_try='test -z "$ac_c_werror_flag"
2829 || test ! -s conftest.err'
2830 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2831 (eval $ac_try) 2>&5
2832 ac_status=$?
2833 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2834 (exit $ac_status); }; } &&
2835 { ac_try='test -s conftest.$ac_objext'
2836 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2837 (eval $ac_try) 2>&5
2838 ac_status=$?
2839 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2840 (exit $ac_status); }; }; then
2841 ac_cv_prog_cc_stdc=$ac_arg
2842break
1a4b763e
BS
2843else
2844 echo "$as_me: failed program was:" >&5
2845sed 's/^/| /' conftest.$ac_ext >&5
2846
b61ff9c8
BS
2847fi
2848rm -f conftest.err conftest.$ac_objext
2849done
2850rm -f conftest.$ac_ext conftest.$ac_objext
2851CC=$ac_save_CC
2852
2853fi
2854
2855case "x$ac_cv_prog_cc_stdc" in
2856 x|xno)
2857 echo "$as_me:$LINENO: result: none needed" >&5
2858echo "${ECHO_T}none needed" >&6 ;;
2859 *)
2860 echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
2861echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
2862 CC="$CC $ac_cv_prog_cc_stdc" ;;
2863esac
2864
2865# Some people use a C++ compiler to compile C. Since we use `exit',
2866# in C++ we need to declare it. In case someone uses the same compiler
2867# for both compiling C and C++ we need to have the C++ compiler decide
2868# the declaration of exit, since it's the most demanding environment.
2869cat >conftest.$ac_ext <<_ACEOF
2870#ifndef __cplusplus
2871 choke me
2872#endif
2873_ACEOF
2874rm -f conftest.$ac_objext
2875if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2876 (eval $ac_compile) 2>conftest.er1
2877 ac_status=$?
2878 grep -v '^ *+' conftest.er1 >conftest.err
2879 rm -f conftest.er1
2880 cat conftest.err >&5
2881 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2882 (exit $ac_status); } &&
2883 { ac_try='test -z "$ac_c_werror_flag"
2884 || test ! -s conftest.err'
2885 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2886 (eval $ac_try) 2>&5
2887 ac_status=$?
2888 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2889 (exit $ac_status); }; } &&
2890 { ac_try='test -s conftest.$ac_objext'
2891 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2892 (eval $ac_try) 2>&5
2893 ac_status=$?
2894 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2895 (exit $ac_status); }; }; then
2896 for ac_declaration in \
2897 '' \
2898 'extern "C" void std::exit (int) throw (); using std::exit;' \
2899 'extern "C" void std::exit (int); using std::exit;' \
2900 'extern "C" void exit (int) throw ();' \
2901 'extern "C" void exit (int);' \
2902 'void exit (int);'
2903do
2904 cat >conftest.$ac_ext <<_ACEOF
1a4b763e
BS
2905/* confdefs.h. */
2906_ACEOF
2907cat confdefs.h >>conftest.$ac_ext
2908cat >>conftest.$ac_ext <<_ACEOF
2909/* end confdefs.h. */
b61ff9c8
BS
2910$ac_declaration
2911#include <stdlib.h>
1a4b763e
BS
2912int
2913main ()
2914{
b61ff9c8 2915exit (42);
1a4b763e
BS
2916 ;
2917 return 0;
2918}
2919_ACEOF
2920rm -f conftest.$ac_objext
b61ff9c8
BS
2921if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2922 (eval $ac_compile) 2>conftest.er1
2f41c1d6 2923 ac_status=$?
1a4b763e
BS
2924 grep -v '^ *+' conftest.er1 >conftest.err
2925 rm -f conftest.er1
2926 cat conftest.err >&5
2f41c1d6 2927 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
2928 (exit $ac_status); } &&
2929 { ac_try='test -z "$ac_c_werror_flag"
2930 || test ! -s conftest.err'
2931 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2932 (eval $ac_try) 2>&5
2933 ac_status=$?
2934 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2935 (exit $ac_status); }; } &&
2936 { ac_try='test -s conftest.$ac_objext'
2937 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2938 (eval $ac_try) 2>&5
2939 ac_status=$?
2940 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2941 (exit $ac_status); }; }; then
2942 :
ab22c1fa
CF
2943else
2944 echo "$as_me: failed program was:" >&5
2945sed 's/^/| /' conftest.$ac_ext >&5
2946
b61ff9c8 2947continue
2f41c1d6 2948fi
b61ff9c8
BS
2949rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2950 cat >conftest.$ac_ext <<_ACEOF
ab22c1fa
CF
2951/* confdefs.h. */
2952_ACEOF
2953cat confdefs.h >>conftest.$ac_ext
2954cat >>conftest.$ac_ext <<_ACEOF
2955/* end confdefs.h. */
b61ff9c8 2956$ac_declaration
2f41c1d6
PB
2957int
2958main ()
2959{
b61ff9c8 2960exit (42);
2f41c1d6
PB
2961 ;
2962 return 0;
2963}
2964_ACEOF
b61ff9c8
BS
2965rm -f conftest.$ac_objext
2966if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2967 (eval $ac_compile) 2>conftest.er1
2f41c1d6 2968 ac_status=$?
ab22c1fa
CF
2969 grep -v '^ *+' conftest.er1 >conftest.err
2970 rm -f conftest.er1
2971 cat conftest.err >&5
a3bba767 2972 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
2973 (exit $ac_status); } &&
2974 { ac_try='test -z "$ac_c_werror_flag"
2975 || test ! -s conftest.err'
2976 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2977 (eval $ac_try) 2>&5
2978 ac_status=$?
2979 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2980 (exit $ac_status); }; } &&
2981 { ac_try='test -s conftest.$ac_objext'
2982 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2983 (eval $ac_try) 2>&5
2984 ac_status=$?
2985 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2986 (exit $ac_status); }; }; then
2987 break
ab22c1fa
CF
2988else
2989 echo "$as_me: failed program was:" >&5
2990sed 's/^/| /' conftest.$ac_ext >&5
2991
2f41c1d6 2992fi
b61ff9c8 2993rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2f41c1d6 2994done
b61ff9c8
BS
2995rm -f conftest*
2996if test -n "$ac_declaration"; then
2997 echo '#ifdef __cplusplus' >>confdefs.h
2998 echo $ac_declaration >>confdefs.h
2999 echo '#endif' >>confdefs.h
2f41c1d6 3000fi
2f41c1d6 3001
b61ff9c8
BS
3002else
3003 echo "$as_me: failed program was:" >&5
3004sed 's/^/| /' conftest.$ac_ext >&5
ba479fd2 3005
b61ff9c8
BS
3006fi
3007rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba479fd2
NN
3008ac_ext=c
3009ac_cpp='$CPP $CPPFLAGS'
3010ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3011ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3012ac_compiler_gnu=$ac_cv_c_compiler_gnu
3013
3014if test "x$CC" != xcc; then
b61ff9c8
BS
3015 echo "$as_me:$LINENO: checking whether $CC and cc understand -c and -o together" >&5
3016echo $ECHO_N "checking whether $CC and cc understand -c and -o together... $ECHO_C" >&6
ba479fd2 3017else
b61ff9c8
BS
3018 echo "$as_me:$LINENO: checking whether cc understands -c and -o together" >&5
3019echo $ECHO_N "checking whether cc understands -c and -o together... $ECHO_C" >&6
ba479fd2
NN
3020fi
3021set dummy $CC; ac_cc=`echo $2 |
3022 sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
b61ff9c8 3023if eval "test \"\${ac_cv_prog_cc_${ac_cc}_c_o+set}\" = set"; then
ba479fd2
NN
3024 echo $ECHO_N "(cached) $ECHO_C" >&6
3025else
3026 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
3027/* confdefs.h. */
3028_ACEOF
3029cat confdefs.h >>conftest.$ac_ext
3030cat >>conftest.$ac_ext <<_ACEOF
3031/* end confdefs.h. */
3032
3033int
3034main ()
3035{
3036
3037 ;
3038 return 0;
3039}
3040_ACEOF
3ec83fc2
RH
3041# Make sure it works both with $CC and with simple cc.
3042# We do the test twice because some compilers refuse to overwrite an
3043# existing .o file with -o, though they will create one.
b61ff9c8
BS
3044ac_try='$CC -c conftest.$ac_ext -o conftest.$ac_objext >&5'
3045if { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3046 (eval $ac_try) 2>&5
ba479fd2
NN
3047 ac_status=$?
3048 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3049 (exit $ac_status); } &&
b61ff9c8
BS
3050 test -f conftest.$ac_objext && { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3051 (eval $ac_try) 2>&5
ba479fd2
NN
3052 ac_status=$?
3053 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3054 (exit $ac_status); };
3ec83fc2
RH
3055then
3056 eval ac_cv_prog_cc_${ac_cc}_c_o=yes
3057 if test "x$CC" != xcc; then
3058 # Test first that cc exists at all.
ba479fd2 3059 if { ac_try='cc -c conftest.$ac_ext >&5'
b61ff9c8
BS
3060 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3061 (eval $ac_try) 2>&5
ba479fd2
NN
3062 ac_status=$?
3063 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3064 (exit $ac_status); }; }; then
b61ff9c8
BS
3065 ac_try='cc -c conftest.$ac_ext -o conftest.$ac_objext >&5'
3066 if { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3067 (eval $ac_try) 2>&5
ba479fd2
NN
3068 ac_status=$?
3069 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3070 (exit $ac_status); } &&
b61ff9c8
BS
3071 test -f conftest.$ac_objext && { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3072 (eval $ac_try) 2>&5
ba479fd2
NN
3073 ac_status=$?
3074 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3075 (exit $ac_status); };
3ec83fc2 3076 then
86da66b5
HPN
3077 # cc works too.
3078 :
3ec83fc2 3079 else
86da66b5
HPN
3080 # cc exists but doesn't like -o.
3081 eval ac_cv_prog_cc_${ac_cc}_c_o=no
3ec83fc2
RH
3082 fi
3083 fi
3084 fi
3085else
3086 eval ac_cv_prog_cc_${ac_cc}_c_o=no
3087fi
b61ff9c8 3088rm -f conftest*
3ec83fc2
RH
3089
3090fi
b61ff9c8
BS
3091if eval "test \"`echo '$ac_cv_prog_cc_'${ac_cc}_c_o`\" = yes"; then
3092 echo "$as_me:$LINENO: result: yes" >&5
3093echo "${ECHO_T}yes" >&6
3ec83fc2 3094else
b61ff9c8
BS
3095 echo "$as_me:$LINENO: result: no" >&5
3096echo "${ECHO_T}no" >&6
ba479fd2
NN
3097
3098cat >>confdefs.h <<\_ACEOF
3ec83fc2 3099#define NO_MINUS_C_MINUS_O 1
ba479fd2 3100_ACEOF
3ec83fc2
RH
3101
3102fi
3103
3b620440
KC
3104# expand $ac_aux_dir to an absolute path
3105am_aux_dir=`cd $ac_aux_dir && pwd`
3106
3107# FIXME: we rely on the cache variable name because
3108# there is no other way.
3109set dummy $CC
3110ac_cc=`echo $2 | sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
3111if eval "test \"`echo '$ac_cv_prog_cc_'${ac_cc}_c_o`\" != yes"; then
3112 # Losing compiler, so override with the script.
3113 # FIXME: It is wrong to rewrite CC.
3114 # But if we don't then we get into trouble of one sort or another.
3115 # A longer-term fix would be to have automake use am__CC in this case,
3116 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
3117 CC="$am_aux_dir/compile $CC"
3118fi
3119
3d4e720a
ST
3120
3121
3122
3123if test -n "$ac_tool_prefix"; then
3124 # Extract the first word of "${ac_tool_prefix}gnatbind", so it can be a program name with args.
3125set dummy ${ac_tool_prefix}gnatbind; ac_word=$2
3126echo "$as_me:$LINENO: checking for $ac_word" >&5
3127echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3128if test "${ac_cv_prog_GNATBIND+set}" = set; then
3129 echo $ECHO_N "(cached) $ECHO_C" >&6
3130else
3131 if test -n "$GNATBIND"; then
3132 ac_cv_prog_GNATBIND="$GNATBIND" # Let the user override the test.
3133else
3134as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3135for as_dir in $PATH
3136do
3137 IFS=$as_save_IFS
3138 test -z "$as_dir" && as_dir=.
3139 for ac_exec_ext in '' $ac_executable_extensions; do
3140 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3141 ac_cv_prog_GNATBIND="${ac_tool_prefix}gnatbind"
3142 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3143 break 2
3144 fi
3145done
3146done
3147
3148fi
3149fi
3150GNATBIND=$ac_cv_prog_GNATBIND
3151if test -n "$GNATBIND"; then
3152 echo "$as_me:$LINENO: result: $GNATBIND" >&5
3153echo "${ECHO_T}$GNATBIND" >&6
3154else
3155 echo "$as_me:$LINENO: result: no" >&5
3156echo "${ECHO_T}no" >&6
3157fi
3158
3159fi
3160if test -z "$ac_cv_prog_GNATBIND"; then
3161 ac_ct_GNATBIND=$GNATBIND
3162 # Extract the first word of "gnatbind", so it can be a program name with args.
3163set dummy gnatbind; ac_word=$2
3164echo "$as_me:$LINENO: checking for $ac_word" >&5
3165echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3166if test "${ac_cv_prog_ac_ct_GNATBIND+set}" = set; then
3167 echo $ECHO_N "(cached) $ECHO_C" >&6
3168else
3169 if test -n "$ac_ct_GNATBIND"; then
3170 ac_cv_prog_ac_ct_GNATBIND="$ac_ct_GNATBIND" # Let the user override the test.
3171else
3172as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3173for as_dir in $PATH
3174do
3175 IFS=$as_save_IFS
3176 test -z "$as_dir" && as_dir=.
3177 for ac_exec_ext in '' $ac_executable_extensions; do
3178 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3179 ac_cv_prog_ac_ct_GNATBIND="gnatbind"
3180 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3181 break 2
3182 fi
3183done
3184done
3185
3186 test -z "$ac_cv_prog_ac_ct_GNATBIND" && ac_cv_prog_ac_ct_GNATBIND="no"
3187fi
3188fi
3189ac_ct_GNATBIND=$ac_cv_prog_ac_ct_GNATBIND
3190if test -n "$ac_ct_GNATBIND"; then
3191 echo "$as_me:$LINENO: result: $ac_ct_GNATBIND" >&5
3192echo "${ECHO_T}$ac_ct_GNATBIND" >&6
3193else
3194 echo "$as_me:$LINENO: result: no" >&5
3195echo "${ECHO_T}no" >&6
3196fi
3197
3198 GNATBIND=$ac_ct_GNATBIND
3199else
3200 GNATBIND="$ac_cv_prog_GNATBIND"
3201fi
3202
3203if test -n "$ac_tool_prefix"; then
3204 # Extract the first word of "${ac_tool_prefix}gnatmake", so it can be a program name with args.
3205set dummy ${ac_tool_prefix}gnatmake; ac_word=$2
3206echo "$as_me:$LINENO: checking for $ac_word" >&5
3207echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3208if test "${ac_cv_prog_GNATMAKE+set}" = set; then
3209 echo $ECHO_N "(cached) $ECHO_C" >&6
3210else
3211 if test -n "$GNATMAKE"; then
3212 ac_cv_prog_GNATMAKE="$GNATMAKE" # Let the user override the test.
3213else
3214as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3215for as_dir in $PATH
3216do
3217 IFS=$as_save_IFS
3218 test -z "$as_dir" && as_dir=.
3219 for ac_exec_ext in '' $ac_executable_extensions; do
3220 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3221 ac_cv_prog_GNATMAKE="${ac_tool_prefix}gnatmake"
3222 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3223 break 2
3224 fi
3225done
3226done
3227
3228fi
3229fi
3230GNATMAKE=$ac_cv_prog_GNATMAKE
3231if test -n "$GNATMAKE"; then
3232 echo "$as_me:$LINENO: result: $GNATMAKE" >&5
3233echo "${ECHO_T}$GNATMAKE" >&6
3234else
3235 echo "$as_me:$LINENO: result: no" >&5
3236echo "${ECHO_T}no" >&6
3237fi
3238
3239fi
3240if test -z "$ac_cv_prog_GNATMAKE"; then
3241 ac_ct_GNATMAKE=$GNATMAKE
3242 # Extract the first word of "gnatmake", so it can be a program name with args.
3243set dummy gnatmake; ac_word=$2
3244echo "$as_me:$LINENO: checking for $ac_word" >&5
3245echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3246if test "${ac_cv_prog_ac_ct_GNATMAKE+set}" = set; then
3247 echo $ECHO_N "(cached) $ECHO_C" >&6
3248else
3249 if test -n "$ac_ct_GNATMAKE"; then
3250 ac_cv_prog_ac_ct_GNATMAKE="$ac_ct_GNATMAKE" # Let the user override the test.
3251else
3252as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3253for as_dir in $PATH
3254do
3255 IFS=$as_save_IFS
3256 test -z "$as_dir" && as_dir=.
3257 for ac_exec_ext in '' $ac_executable_extensions; do
3258 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3259 ac_cv_prog_ac_ct_GNATMAKE="gnatmake"
3260 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3261 break 2
3262 fi
3263done
3264done
3265
3266 test -z "$ac_cv_prog_ac_ct_GNATMAKE" && ac_cv_prog_ac_ct_GNATMAKE="no"
3267fi
3268fi
3269ac_ct_GNATMAKE=$ac_cv_prog_ac_ct_GNATMAKE
3270if test -n "$ac_ct_GNATMAKE"; then
3271 echo "$as_me:$LINENO: result: $ac_ct_GNATMAKE" >&5
3272echo "${ECHO_T}$ac_ct_GNATMAKE" >&6
3273else
3274 echo "$as_me:$LINENO: result: no" >&5
3275echo "${ECHO_T}no" >&6
3276fi
3277
3278 GNATMAKE=$ac_ct_GNATMAKE
3279else
3280 GNATMAKE="$ac_cv_prog_GNATMAKE"
3281fi
3282
3283echo "$as_me:$LINENO: checking whether compiler driver understands Ada" >&5
3284echo $ECHO_N "checking whether compiler driver understands Ada... $ECHO_C" >&6
3285if test "${acx_cv_cc_gcc_supports_ada+set}" = set; then
3286 echo $ECHO_N "(cached) $ECHO_C" >&6
3287else
3288 cat >conftest.adb <<EOF
3289procedure conftest is begin null; end conftest;
3290EOF
3291acx_cv_cc_gcc_supports_ada=no
3292# There is a bug in old released versions of GCC which causes the
3293# driver to exit successfully when the appropriate language module
3294# has not been installed. This is fixed in 2.95.4, 3.0.2, and 3.1.
3295# Therefore we must check for the error message as well as an
3296# unsuccessful exit.
3297# Other compilers, like HP Tru64 UNIX cc, exit successfully when
3298# given a .adb file, but produce no object file. So we must check
3299# if an object file was really produced to guard against this.
3300errors=`(${CC} -I"$srcdir"/ada -c conftest.adb) 2>&1 || echo failure`
3301if test x"$errors" = x && test -f conftest.$ac_objext; then
3302 acx_cv_cc_gcc_supports_ada=yes
3303fi
3304rm -f conftest.*
3305fi
3306echo "$as_me:$LINENO: result: $acx_cv_cc_gcc_supports_ada" >&5
3307echo "${ECHO_T}$acx_cv_cc_gcc_supports_ada" >&6
3308
3309if test x$GNATBIND != xno && test x$GNATMAKE != xno && test x$acx_cv_cc_gcc_supports_ada != xno; then
3310 have_gnat=yes
3311else
3312 have_gnat=no
3313fi
3314
3315
414d23ae
HPN
3316# autoconf is lame and doesn't give us any substitution variable for this.
3317if eval "test \"`echo '$ac_cv_prog_cc_'${ac_cc}_c_o`\" = no"; then
3318 NO_MINUS_C_MINUS_O=yes
3319else
3320 OUTPUT_OPTION='-o $@'
3321fi
3322
3323
3324
ec6c7392
PB
3325# Remove the -O2: for historical reasons, unless bootstrapping we prefer
3326# optimizations to be activated explicitly by the toplevel.
3327case "$CC" in
3328 */prev-gcc/xgcc*) ;;
3329 *) CFLAGS=`echo $CFLAGS | sed "s/-O[s0-9]* *//" ` ;;
3330esac
3331
3332
73458fb7
NN
3333# -------------------------
3334# Check C compiler features
3335# -------------------------
3336
60d26958 3337
ba479fd2
NN
3338ac_ext=c
3339ac_cpp='$CPP $CPPFLAGS'
3340ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3341ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3342ac_compiler_gnu=$ac_cv_c_compiler_gnu
b61ff9c8
BS
3343echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
3344echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
84c041a1
ZW
3345# On Suns, sometimes $CPP names a directory.
3346if test -n "$CPP" && test -d "$CPP"; then
3347 CPP=
3348fi
3349if test -z "$CPP"; then
ba479fd2
NN
3350 if test "${ac_cv_prog_CPP+set}" = set; then
3351 echo $ECHO_N "(cached) $ECHO_C" >&6
3352else
3353 # Double quotes because CPP needs to be expanded
3354 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3355 do
3356 ac_preproc_ok=false
3357for ac_c_preproc_warn_flag in '' yes
3358do
3359 # Use a header file that comes with gcc, so configuring glibc
3360 # with a fresh cross-compiler works.
3361 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3362 # <limits.h> exists even on freestanding compilers.
84c041a1 3363 # On the NeXT, cc -E runs the code through the compiler's parser,
ba479fd2
NN
3364 # not just through cpp. "Syntax error" is here to catch this case.
3365 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
3366/* confdefs.h. */
3367_ACEOF
3368cat confdefs.h >>conftest.$ac_ext
3369cat >>conftest.$ac_ext <<_ACEOF
3370/* end confdefs.h. */
3371#ifdef __STDC__
3372# include <limits.h>
3373#else
3374# include <assert.h>
3375#endif
86da66b5 3376 Syntax error
ba479fd2 3377_ACEOF
b61ff9c8
BS
3378if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
3379 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
ba479fd2
NN
3380 ac_status=$?
3381 grep -v '^ *+' conftest.er1 >conftest.err
3382 rm -f conftest.er1
3383 cat conftest.err >&5
3384 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
3385 (exit $ac_status); } >/dev/null; then
3386 if test -s conftest.err; then
3387 ac_cpp_err=$ac_c_preproc_warn_flag
3388 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
3389 else
3390 ac_cpp_err=
3391 fi
3392else
3393 ac_cpp_err=yes
3394fi
3395if test -z "$ac_cpp_err"; then
093e61a6 3396 :
cafe096b 3397else
ba479fd2
NN
3398 echo "$as_me: failed program was:" >&5
3399sed 's/^/| /' conftest.$ac_ext >&5
3400
3401 # Broken: fails on valid input.
3402continue
3403fi
3404rm -f conftest.err conftest.$ac_ext
3405
b61ff9c8 3406 # OK, works on sane cases. Now check whether non-existent headers
ba479fd2
NN
3407 # can be detected and how.
3408 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
3409/* confdefs.h. */
3410_ACEOF
3411cat confdefs.h >>conftest.$ac_ext
3412cat >>conftest.$ac_ext <<_ACEOF
3413/* end confdefs.h. */
3414#include <ac_nonexistent.h>
3415_ACEOF
b61ff9c8
BS
3416if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
3417 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
ba479fd2
NN
3418 ac_status=$?
3419 grep -v '^ *+' conftest.er1 >conftest.err
3420 rm -f conftest.er1
3421 cat conftest.err >&5
3422 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
3423 (exit $ac_status); } >/dev/null; then
3424 if test -s conftest.err; then
3425 ac_cpp_err=$ac_c_preproc_warn_flag
3426 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
3427 else
3428 ac_cpp_err=
3429 fi
3430else
3431 ac_cpp_err=yes
3432fi
3433if test -z "$ac_cpp_err"; then
ba479fd2
NN
3434 # Broken: success on invalid input.
3435continue
3436else
3437 echo "$as_me: failed program was:" >&5
3438sed 's/^/| /' conftest.$ac_ext >&5
3439
3440 # Passes both tests.
3441ac_preproc_ok=:
3442break
3443fi
3444rm -f conftest.err conftest.$ac_ext
3445
3446done
3447# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3448rm -f conftest.err conftest.$ac_ext
3449if $ac_preproc_ok; then
3450 break
3451fi
3452
3453 done
3454 ac_cv_prog_CPP=$CPP
3455
3456fi
3457 CPP=$ac_cv_prog_CPP
3458else
3459 ac_cv_prog_CPP=$CPP
3460fi
b61ff9c8
BS
3461echo "$as_me:$LINENO: result: $CPP" >&5
3462echo "${ECHO_T}$CPP" >&6
ba479fd2
NN
3463ac_preproc_ok=false
3464for ac_c_preproc_warn_flag in '' yes
3465do
3466 # Use a header file that comes with gcc, so configuring glibc
3467 # with a fresh cross-compiler works.
3468 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3469 # <limits.h> exists even on freestanding compilers.
3470 # On the NeXT, cc -E runs the code through the compiler's parser,
3471 # not just through cpp. "Syntax error" is here to catch this case.
3472 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
3473/* confdefs.h. */
3474_ACEOF
3475cat confdefs.h >>conftest.$ac_ext
3476cat >>conftest.$ac_ext <<_ACEOF
3477/* end confdefs.h. */
3478#ifdef __STDC__
3479# include <limits.h>
3480#else
3481# include <assert.h>
3482#endif
86da66b5 3483 Syntax error
ba479fd2 3484_ACEOF
b61ff9c8
BS
3485if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
3486 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
ba479fd2
NN
3487 ac_status=$?
3488 grep -v '^ *+' conftest.er1 >conftest.err
3489 rm -f conftest.er1
3490 cat conftest.err >&5
3491 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
3492 (exit $ac_status); } >/dev/null; then
3493 if test -s conftest.err; then
3494 ac_cpp_err=$ac_c_preproc_warn_flag
3495 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
3496 else
3497 ac_cpp_err=
3498 fi
3499else
3500 ac_cpp_err=yes
3501fi
3502if test -z "$ac_cpp_err"; then
6e3f3080 3503 :
414d23ae 3504else
ba479fd2
NN
3505 echo "$as_me: failed program was:" >&5
3506sed 's/^/| /' conftest.$ac_ext >&5
3507
3508 # Broken: fails on valid input.
3509continue
3510fi
3511rm -f conftest.err conftest.$ac_ext
3512
b61ff9c8 3513 # OK, works on sane cases. Now check whether non-existent headers
ba479fd2
NN
3514 # can be detected and how.
3515 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
3516/* confdefs.h. */
3517_ACEOF
3518cat confdefs.h >>conftest.$ac_ext
3519cat >>conftest.$ac_ext <<_ACEOF
3520/* end confdefs.h. */
3521#include <ac_nonexistent.h>
3522_ACEOF
b61ff9c8
BS
3523if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
3524 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
ba479fd2
NN
3525 ac_status=$?
3526 grep -v '^ *+' conftest.er1 >conftest.err
3527 rm -f conftest.er1
3528 cat conftest.err >&5
3529 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
3530 (exit $ac_status); } >/dev/null; then
3531 if test -s conftest.err; then
3532 ac_cpp_err=$ac_c_preproc_warn_flag
3533 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
3534 else
3535 ac_cpp_err=
3536 fi
3537else
3538 ac_cpp_err=yes
3539fi
3540if test -z "$ac_cpp_err"; then
ba479fd2
NN
3541 # Broken: success on invalid input.
3542continue
3543else
3544 echo "$as_me: failed program was:" >&5
3545sed 's/^/| /' conftest.$ac_ext >&5
3546
3547 # Passes both tests.
3548ac_preproc_ok=:
3549break
63cf211a 3550fi
ba479fd2
NN
3551rm -f conftest.err conftest.$ac_ext
3552
3553done
3554# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3555rm -f conftest.err conftest.$ac_ext
3556if $ac_preproc_ok; then
3557 :
6e3f3080 3558else
18c04407
RW
3559 { { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3560echo "$as_me: error: in \`$ac_pwd':" >&2;}
3561{ { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
ba479fd2
NN
3562See \`config.log' for more details." >&5
3563echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
3564See \`config.log' for more details." >&2;}
18c04407 3565 { (exit 1); exit 1; }; }; }
6e3f3080
NN
3566fi
3567
ba479fd2
NN
3568ac_ext=c
3569ac_cpp='$CPP $CPPFLAGS'
3570ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3571ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3572ac_compiler_gnu=$ac_cv_c_compiler_gnu
3573
b5472e1d 3574
60d26958
PB
3575echo "$as_me:$LINENO: checking for egrep" >&5
3576echo $ECHO_N "checking for egrep... $ECHO_C" >&6
3577if test "${ac_cv_prog_egrep+set}" = set; then
3578 echo $ECHO_N "(cached) $ECHO_C" >&6
3579else
3580 if echo a | (grep -E '(a|b)') >/dev/null 2>&1
3581 then ac_cv_prog_egrep='grep -E'
3582 else ac_cv_prog_egrep='egrep'
3583 fi
3584fi
3585echo "$as_me:$LINENO: result: $ac_cv_prog_egrep" >&5
3586echo "${ECHO_T}$ac_cv_prog_egrep" >&6
3587 EGREP=$ac_cv_prog_egrep
3588
3589
3590echo "$as_me:$LINENO: checking for ANSI C header files" >&5
3591echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
3592if test "${ac_cv_header_stdc+set}" = set; then
ba479fd2 3593 echo $ECHO_N "(cached) $ECHO_C" >&6
414d23ae 3594else
ba479fd2 3595 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
3596/* confdefs.h. */
3597_ACEOF
3598cat confdefs.h >>conftest.$ac_ext
3599cat >>conftest.$ac_ext <<_ACEOF
3600/* end confdefs.h. */
60d26958
PB
3601#include <stdlib.h>
3602#include <stdarg.h>
3603#include <string.h>
3604#include <float.h>
3605
3606int
3607main ()
3608{
414d23ae 3609
60d26958
PB
3610 ;
3611 return 0;
3612}
ba479fd2
NN
3613_ACEOF
3614rm -f conftest.$ac_objext
b61ff9c8
BS
3615if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
3616 (eval $ac_compile) 2>conftest.er1
ba479fd2 3617 ac_status=$?
86da66b5
HPN
3618 grep -v '^ *+' conftest.er1 >conftest.err
3619 rm -f conftest.er1
3620 cat conftest.err >&5
ba479fd2 3621 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
3622 (exit $ac_status); } &&
3623 { ac_try='test -z "$ac_c_werror_flag"
3624 || test ! -s conftest.err'
3625 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3626 (eval $ac_try) 2>&5
3627 ac_status=$?
3628 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3629 (exit $ac_status); }; } &&
3630 { ac_try='test -s conftest.$ac_objext'
3631 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3632 (eval $ac_try) 2>&5
3633 ac_status=$?
3634 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3635 (exit $ac_status); }; }; then
60d26958 3636 ac_cv_header_stdc=yes
414d23ae 3637else
ba479fd2
NN
3638 echo "$as_me: failed program was:" >&5
3639sed 's/^/| /' conftest.$ac_ext >&5
3640
60d26958 3641ac_cv_header_stdc=no
414d23ae 3642fi
b61ff9c8 3643rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
414d23ae 3644
60d26958
PB
3645if test $ac_cv_header_stdc = yes; then
3646 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
3647 cat >conftest.$ac_ext <<_ACEOF
3648/* confdefs.h. */
3649_ACEOF
3650cat confdefs.h >>conftest.$ac_ext
3651cat >>conftest.$ac_ext <<_ACEOF
3652/* end confdefs.h. */
3653#include <string.h>
3654
3655_ACEOF
3656if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3657 $EGREP "memchr" >/dev/null 2>&1; then
3658 :
3659else
3660 ac_cv_header_stdc=no
414d23ae 3661fi
60d26958 3662rm -f conftest*
86da66b5 3663
60d26958 3664fi
86da66b5 3665
60d26958
PB
3666if test $ac_cv_header_stdc = yes; then
3667 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
3668 cat >conftest.$ac_ext <<_ACEOF
3669/* confdefs.h. */
3670_ACEOF
3671cat confdefs.h >>conftest.$ac_ext
3672cat >>conftest.$ac_ext <<_ACEOF
3673/* end confdefs.h. */
3674#include <stdlib.h>
3675
3676_ACEOF
3677if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3678 $EGREP "free" >/dev/null 2>&1; then
3679 :
3680else
3681 ac_cv_header_stdc=no
3682fi
3683rm -f conftest*
3684
3685fi
3686
3687if test $ac_cv_header_stdc = yes; then
3688 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
3689 if test "$cross_compiling" = yes; then
3690 :
3691else
3692 cat >conftest.$ac_ext <<_ACEOF
3693/* confdefs.h. */
3694_ACEOF
3695cat confdefs.h >>conftest.$ac_ext
3696cat >>conftest.$ac_ext <<_ACEOF
3697/* end confdefs.h. */
3698#include <ctype.h>
3699#if ((' ' & 0x0FF) == 0x020)
3700# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
3701# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
3702#else
3703# define ISLOWER(c) \
3704 (('a' <= (c) && (c) <= 'i') \
3705 || ('j' <= (c) && (c) <= 'r') \
3706 || ('s' <= (c) && (c) <= 'z'))
3707# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
86da66b5 3708#endif
60d26958
PB
3709
3710#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
3711int
3712main ()
3713{
3714 int i;
3715 for (i = 0; i < 256; i++)
3716 if (XOR (islower (i), ISLOWER (i))
3717 || toupper (i) != TOUPPER (i))
3718 exit(2);
3719 exit (0);
3720}
ba479fd2 3721_ACEOF
60d26958
PB
3722rm -f conftest$ac_exeext
3723if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3724 (eval $ac_link) 2>&5
3725 ac_status=$?
3726 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3727 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3728 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3729 (eval $ac_try) 2>&5
3730 ac_status=$?
3731 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3732 (exit $ac_status); }; }; then
3733 :
3734else
3735 echo "$as_me: program exited with status $ac_status" >&5
3736echo "$as_me: failed program was:" >&5
3737sed 's/^/| /' conftest.$ac_ext >&5
414d23ae 3738
60d26958
PB
3739( exit $ac_status )
3740ac_cv_header_stdc=no
3741fi
3742rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
3743fi
3744fi
3745fi
3746echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
3747echo "${ECHO_T}$ac_cv_header_stdc" >&6
3748if test $ac_cv_header_stdc = yes; then
414d23ae 3749
60d26958
PB
3750cat >>confdefs.h <<\_ACEOF
3751#define STDC_HEADERS 1
3752_ACEOF
bf3b7cd3 3753
60d26958
PB
3754fi
3755
3756# On IRIX 5.3, sys/types and inttypes.h are conflicting.
3757
3758
3759
3760
3761
3762
3763
3764
3765
3766for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
3767 inttypes.h stdint.h unistd.h
3768do
3769as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3770echo "$as_me:$LINENO: checking for $ac_header" >&5
3771echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3772if eval "test \"\${$as_ac_Header+set}\" = set"; then
1a4b763e
BS
3773 echo $ECHO_N "(cached) $ECHO_C" >&6
3774else
60d26958
PB
3775 cat >conftest.$ac_ext <<_ACEOF
3776/* confdefs.h. */
3777_ACEOF
3778cat confdefs.h >>conftest.$ac_ext
3779cat >>conftest.$ac_ext <<_ACEOF
3780/* end confdefs.h. */
3781$ac_includes_default
3782
3783#include <$ac_header>
3784_ACEOF
3785rm -f conftest.$ac_objext
3786if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
3787 (eval $ac_compile) 2>conftest.er1
3788 ac_status=$?
3789 grep -v '^ *+' conftest.er1 >conftest.err
3790 rm -f conftest.er1
3791 cat conftest.err >&5
3792 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3793 (exit $ac_status); } &&
3794 { ac_try='test -z "$ac_c_werror_flag"
3795 || test ! -s conftest.err'
3796 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3797 (eval $ac_try) 2>&5
3798 ac_status=$?
3799 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3800 (exit $ac_status); }; } &&
3801 { ac_try='test -s conftest.$ac_objext'
3802 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3803 (eval $ac_try) 2>&5
3804 ac_status=$?
3805 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3806 (exit $ac_status); }; }; then
3807 eval "$as_ac_Header=yes"
3808else
3809 echo "$as_me: failed program was:" >&5
3810sed 's/^/| /' conftest.$ac_ext >&5
3811
3812eval "$as_ac_Header=no"
b61ff9c8 3813fi
60d26958
PB
3814rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
3815fi
3816echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
3817echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
3818if test `eval echo '${'$as_ac_Header'}'` = yes; then
3819 cat >>confdefs.h <<_ACEOF
3820#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
3821_ACEOF
1a4b763e 3822
60d26958 3823fi
1a4b763e 3824
60d26958
PB
3825done
3826
3827
3828
3829 if test "${ac_cv_header_minix_config_h+set}" = set; then
3830 echo "$as_me:$LINENO: checking for minix/config.h" >&5
3831echo $ECHO_N "checking for minix/config.h... $ECHO_C" >&6
3832if test "${ac_cv_header_minix_config_h+set}" = set; then
3833 echo $ECHO_N "(cached) $ECHO_C" >&6
3834fi
3835echo "$as_me:$LINENO: result: $ac_cv_header_minix_config_h" >&5
3836echo "${ECHO_T}$ac_cv_header_minix_config_h" >&6
3837else
3838 # Is the header compilable?
3839echo "$as_me:$LINENO: checking minix/config.h usability" >&5
3840echo $ECHO_N "checking minix/config.h usability... $ECHO_C" >&6
3841cat >conftest.$ac_ext <<_ACEOF
3842/* confdefs.h. */
3843_ACEOF
3844cat confdefs.h >>conftest.$ac_ext
3845cat >>conftest.$ac_ext <<_ACEOF
3846/* end confdefs.h. */
3847$ac_includes_default
3848#include <minix/config.h>
3849_ACEOF
3850rm -f conftest.$ac_objext
3851if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
3852 (eval $ac_compile) 2>conftest.er1
3853 ac_status=$?
3854 grep -v '^ *+' conftest.er1 >conftest.err
3855 rm -f conftest.er1
3856 cat conftest.err >&5
3857 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3858 (exit $ac_status); } &&
3859 { ac_try='test -z "$ac_c_werror_flag"
3860 || test ! -s conftest.err'
3861 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3862 (eval $ac_try) 2>&5
3863 ac_status=$?
3864 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3865 (exit $ac_status); }; } &&
3866 { ac_try='test -s conftest.$ac_objext'
3867 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3868 (eval $ac_try) 2>&5
3869 ac_status=$?
3870 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3871 (exit $ac_status); }; }; then
3872 ac_header_compiler=yes
3873else
3874 echo "$as_me: failed program was:" >&5
3875sed 's/^/| /' conftest.$ac_ext >&5
3876
3877ac_header_compiler=no
3878fi
3879rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
3880echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
3881echo "${ECHO_T}$ac_header_compiler" >&6
3882
3883# Is the header present?
3884echo "$as_me:$LINENO: checking minix/config.h presence" >&5
3885echo $ECHO_N "checking minix/config.h presence... $ECHO_C" >&6
3886cat >conftest.$ac_ext <<_ACEOF
3887/* confdefs.h. */
3888_ACEOF
3889cat confdefs.h >>conftest.$ac_ext
3890cat >>conftest.$ac_ext <<_ACEOF
3891/* end confdefs.h. */
3892#include <minix/config.h>
3893_ACEOF
3894if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
3895 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3896 ac_status=$?
3897 grep -v '^ *+' conftest.er1 >conftest.err
3898 rm -f conftest.er1
3899 cat conftest.err >&5
3900 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3901 (exit $ac_status); } >/dev/null; then
3902 if test -s conftest.err; then
3903 ac_cpp_err=$ac_c_preproc_warn_flag
3904 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
3905 else
3906 ac_cpp_err=
3907 fi
3908else
3909 ac_cpp_err=yes
3910fi
3911if test -z "$ac_cpp_err"; then
3912 ac_header_preproc=yes
3913else
3914 echo "$as_me: failed program was:" >&5
3915sed 's/^/| /' conftest.$ac_ext >&5
3916
3917 ac_header_preproc=no
3918fi
3919rm -f conftest.err conftest.$ac_ext
3920echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
3921echo "${ECHO_T}$ac_header_preproc" >&6
3922
3923# So? What about this header?
3924case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
3925 yes:no: )
3926 { echo "$as_me:$LINENO: WARNING: minix/config.h: accepted by the compiler, rejected by the preprocessor!" >&5
3927echo "$as_me: WARNING: minix/config.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
3928 { echo "$as_me:$LINENO: WARNING: minix/config.h: proceeding with the compiler's result" >&5
3929echo "$as_me: WARNING: minix/config.h: proceeding with the compiler's result" >&2;}
3930 ac_header_preproc=yes
3931 ;;
3932 no:yes:* )
3933 { echo "$as_me:$LINENO: WARNING: minix/config.h: present but cannot be compiled" >&5
3934echo "$as_me: WARNING: minix/config.h: present but cannot be compiled" >&2;}
3935 { echo "$as_me:$LINENO: WARNING: minix/config.h: check for missing prerequisite headers?" >&5
3936echo "$as_me: WARNING: minix/config.h: check for missing prerequisite headers?" >&2;}
3937 { echo "$as_me:$LINENO: WARNING: minix/config.h: see the Autoconf documentation" >&5
3938echo "$as_me: WARNING: minix/config.h: see the Autoconf documentation" >&2;}
3939 { echo "$as_me:$LINENO: WARNING: minix/config.h: section \"Present But Cannot Be Compiled\"" >&5
3940echo "$as_me: WARNING: minix/config.h: section \"Present But Cannot Be Compiled\"" >&2;}
3941 { echo "$as_me:$LINENO: WARNING: minix/config.h: proceeding with the preprocessor's result" >&5
3942echo "$as_me: WARNING: minix/config.h: proceeding with the preprocessor's result" >&2;}
3943 { echo "$as_me:$LINENO: WARNING: minix/config.h: in the future, the compiler will take precedence" >&5
3944echo "$as_me: WARNING: minix/config.h: in the future, the compiler will take precedence" >&2;}
3945 (
3946 cat <<\_ASBOX
3947## ------------------------------------------ ##
3948## Report this to the AC_PACKAGE_NAME lists. ##
3949## ------------------------------------------ ##
3950_ASBOX
3951 ) |
3952 sed "s/^/$as_me: WARNING: /" >&2
3953 ;;
3954esac
3955echo "$as_me:$LINENO: checking for minix/config.h" >&5
3956echo $ECHO_N "checking for minix/config.h... $ECHO_C" >&6
3957if test "${ac_cv_header_minix_config_h+set}" = set; then
3958 echo $ECHO_N "(cached) $ECHO_C" >&6
3959else
3960 ac_cv_header_minix_config_h=$ac_header_preproc
3961fi
3962echo "$as_me:$LINENO: result: $ac_cv_header_minix_config_h" >&5
3963echo "${ECHO_T}$ac_cv_header_minix_config_h" >&6
3964
3965fi
3966if test $ac_cv_header_minix_config_h = yes; then
3967 MINIX=yes
3968else
3969 MINIX=
3970fi
3971
3972
3973 if test "$MINIX" = yes; then
3974
3975cat >>confdefs.h <<\_ACEOF
3976#define _POSIX_SOURCE 1
3977_ACEOF
3978
3979
3980cat >>confdefs.h <<\_ACEOF
3981#define _POSIX_1_SOURCE 2
3982_ACEOF
3983
3984
3985cat >>confdefs.h <<\_ACEOF
3986#define _MINIX 1
3987_ACEOF
3988
3989 fi
3990
3991
3992
3993 echo "$as_me:$LINENO: checking whether it is safe to define __EXTENSIONS__" >&5
3994echo $ECHO_N "checking whether it is safe to define __EXTENSIONS__... $ECHO_C" >&6
3995if test "${ac_cv_safe_to_define___extensions__+set}" = set; then
bf3b7cd3
JD
3996 echo $ECHO_N "(cached) $ECHO_C" >&6
3997else
3998 cat >conftest.$ac_ext <<_ACEOF
3999/* confdefs.h. */
4000_ACEOF
4001cat confdefs.h >>conftest.$ac_ext
4002cat >>conftest.$ac_ext <<_ACEOF
4003/* end confdefs.h. */
bf3b7cd3 4004
60d26958
PB
4005# define __EXTENSIONS__ 1
4006 $ac_includes_default
bf3b7cd3
JD
4007int
4008main ()
4009{
4010
4011 ;
4012 return 0;
4013}
4014_ACEOF
4015rm -f conftest.$ac_objext
b61ff9c8
BS
4016if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4017 (eval $ac_compile) 2>conftest.er1
bf3b7cd3
JD
4018 ac_status=$?
4019 grep -v '^ *+' conftest.er1 >conftest.err
4020 rm -f conftest.er1
4021 cat conftest.err >&5
4022 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
4023 (exit $ac_status); } &&
4024 { ac_try='test -z "$ac_c_werror_flag"
4025 || test ! -s conftest.err'
4026 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4027 (eval $ac_try) 2>&5
4028 ac_status=$?
4029 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4030 (exit $ac_status); }; } &&
4031 { ac_try='test -s conftest.$ac_objext'
4032 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4033 (eval $ac_try) 2>&5
4034 ac_status=$?
4035 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4036 (exit $ac_status); }; }; then
60d26958 4037 ac_cv_safe_to_define___extensions__=yes
bf3b7cd3
JD
4038else
4039 echo "$as_me: failed program was:" >&5
4040sed 's/^/| /' conftest.$ac_ext >&5
4041
60d26958 4042ac_cv_safe_to_define___extensions__=no
bf3b7cd3 4043fi
b61ff9c8 4044rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
60d26958
PB
4045fi
4046echo "$as_me:$LINENO: result: $ac_cv_safe_to_define___extensions__" >&5
4047echo "${ECHO_T}$ac_cv_safe_to_define___extensions__" >&6
4048 test $ac_cv_safe_to_define___extensions__ = yes &&
4049 cat >>confdefs.h <<\_ACEOF
4050#define __EXTENSIONS__ 1
4051_ACEOF
bf3b7cd3 4052
60d26958
PB
4053 cat >>confdefs.h <<\_ACEOF
4054#define _ALL_SOURCE 1
4055_ACEOF
4056
4057 cat >>confdefs.h <<\_ACEOF
4058#define _GNU_SOURCE 1
4059_ACEOF
4060
4061 cat >>confdefs.h <<\_ACEOF
4062#define _POSIX_PTHREAD_SEMANTICS 1
4063_ACEOF
4064
4065 cat >>confdefs.h <<\_ACEOF
4066#define _TANDEM_SOURCE 1
4067_ACEOF
4068
4069
4070ac_ext=c
4071ac_cpp='$CPP $CPPFLAGS'
4072ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4073ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4074ac_compiler_gnu=$ac_cv_c_compiler_gnu
4075echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
4076echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
4077# On Suns, sometimes $CPP names a directory.
4078if test -n "$CPP" && test -d "$CPP"; then
4079 CPP=
4080fi
4081if test -z "$CPP"; then
4082 if test "${ac_cv_prog_CPP+set}" = set; then
4083 echo $ECHO_N "(cached) $ECHO_C" >&6
4084else
4085 # Double quotes because CPP needs to be expanded
4086 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
4087 do
4088 ac_preproc_ok=false
4089for ac_c_preproc_warn_flag in '' yes
4090do
4091 # Use a header file that comes with gcc, so configuring glibc
4092 # with a fresh cross-compiler works.
4093 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4094 # <limits.h> exists even on freestanding compilers.
4095 # On the NeXT, cc -E runs the code through the compiler's parser,
4096 # not just through cpp. "Syntax error" is here to catch this case.
bf3b7cd3
JD
4097 cat >conftest.$ac_ext <<_ACEOF
4098/* confdefs.h. */
4099_ACEOF
4100cat confdefs.h >>conftest.$ac_ext
4101cat >>conftest.$ac_ext <<_ACEOF
4102/* end confdefs.h. */
60d26958
PB
4103#ifdef __STDC__
4104# include <limits.h>
4105#else
4106# include <assert.h>
4107#endif
4108 Syntax error
bf3b7cd3 4109_ACEOF
60d26958
PB
4110if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
4111 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4112 ac_status=$?
4113 grep -v '^ *+' conftest.er1 >conftest.err
4114 rm -f conftest.er1
4115 cat conftest.err >&5
4116 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4117 (exit $ac_status); } >/dev/null; then
4118 if test -s conftest.err; then
4119 ac_cpp_err=$ac_c_preproc_warn_flag
4120 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
4121 else
4122 ac_cpp_err=
4123 fi
4124else
4125 ac_cpp_err=yes
4126fi
4127if test -z "$ac_cpp_err"; then
bf3b7cd3
JD
4128 :
4129else
60d26958
PB
4130 echo "$as_me: failed program was:" >&5
4131sed 's/^/| /' conftest.$ac_ext >&5
4132
4133 # Broken: fails on valid input.
4134continue
bf3b7cd3 4135fi
60d26958
PB
4136rm -f conftest.err conftest.$ac_ext
4137
4138 # OK, works on sane cases. Now check whether non-existent headers
4139 # can be detected and how.
4140 cat >conftest.$ac_ext <<_ACEOF
4141/* confdefs.h. */
4142_ACEOF
4143cat confdefs.h >>conftest.$ac_ext
4144cat >>conftest.$ac_ext <<_ACEOF
4145/* end confdefs.h. */
4146#include <ac_nonexistent.h>
4147_ACEOF
4148if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
4149 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4150 ac_status=$?
4151 grep -v '^ *+' conftest.er1 >conftest.err
4152 rm -f conftest.er1
4153 cat conftest.err >&5
4154 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4155 (exit $ac_status); } >/dev/null; then
4156 if test -s conftest.err; then
4157 ac_cpp_err=$ac_c_preproc_warn_flag
4158 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
4159 else
4160 ac_cpp_err=
4161 fi
4162else
4163 ac_cpp_err=yes
4164fi
4165if test -z "$ac_cpp_err"; then
4166 # Broken: success on invalid input.
4167continue
4168else
4169 echo "$as_me: failed program was:" >&5
4170sed 's/^/| /' conftest.$ac_ext >&5
bf3b7cd3 4171
60d26958
PB
4172 # Passes both tests.
4173ac_preproc_ok=:
4174break
bf3b7cd3 4175fi
60d26958 4176rm -f conftest.err conftest.$ac_ext
bf3b7cd3 4177
60d26958
PB
4178done
4179# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4180rm -f conftest.err conftest.$ac_ext
4181if $ac_preproc_ok; then
4182 break
4183fi
4184
4185 done
4186 ac_cv_prog_CPP=$CPP
4187
4188fi
4189 CPP=$ac_cv_prog_CPP
4190else
4191 ac_cv_prog_CPP=$CPP
4192fi
4193echo "$as_me:$LINENO: result: $CPP" >&5
4194echo "${ECHO_T}$CPP" >&6
4195ac_preproc_ok=false
4196for ac_c_preproc_warn_flag in '' yes
4197do
4198 # Use a header file that comes with gcc, so configuring glibc
4199 # with a fresh cross-compiler works.
4200 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4201 # <limits.h> exists even on freestanding compilers.
4202 # On the NeXT, cc -E runs the code through the compiler's parser,
4203 # not just through cpp. "Syntax error" is here to catch this case.
bf3b7cd3
JD
4204 cat >conftest.$ac_ext <<_ACEOF
4205/* confdefs.h. */
4206_ACEOF
4207cat confdefs.h >>conftest.$ac_ext
4208cat >>conftest.$ac_ext <<_ACEOF
4209/* end confdefs.h. */
60d26958
PB
4210#ifdef __STDC__
4211# include <limits.h>
4212#else
4213# include <assert.h>
4214#endif
4215 Syntax error
bf3b7cd3 4216_ACEOF
60d26958
PB
4217if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
4218 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4219 ac_status=$?
4220 grep -v '^ *+' conftest.er1 >conftest.err
4221 rm -f conftest.er1
4222 cat conftest.err >&5
4223 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4224 (exit $ac_status); } >/dev/null; then
4225 if test -s conftest.err; then
4226 ac_cpp_err=$ac_c_preproc_warn_flag
4227 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
4228 else
4229 ac_cpp_err=
4230 fi
bf3b7cd3 4231else
60d26958 4232 ac_cpp_err=yes
bf3b7cd3 4233fi
60d26958
PB
4234if test -z "$ac_cpp_err"; then
4235 :
4236else
4237 echo "$as_me: failed program was:" >&5
4238sed 's/^/| /' conftest.$ac_ext >&5
bf3b7cd3 4239
60d26958
PB
4240 # Broken: fails on valid input.
4241continue
bf3b7cd3 4242fi
60d26958 4243rm -f conftest.err conftest.$ac_ext
bf3b7cd3 4244
60d26958
PB
4245 # OK, works on sane cases. Now check whether non-existent headers
4246 # can be detected and how.
bf3b7cd3
JD
4247 cat >conftest.$ac_ext <<_ACEOF
4248/* confdefs.h. */
4249_ACEOF
4250cat confdefs.h >>conftest.$ac_ext
4251cat >>conftest.$ac_ext <<_ACEOF
4252/* end confdefs.h. */
60d26958 4253#include <ac_nonexistent.h>
bf3b7cd3 4254_ACEOF
60d26958
PB
4255if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
4256 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
bf3b7cd3 4257 ac_status=$?
60d26958
PB
4258 grep -v '^ *+' conftest.er1 >conftest.err
4259 rm -f conftest.er1
4260 cat conftest.err >&5
bf3b7cd3 4261 echo "$as_me:$LINENO: \$? = $ac_status" >&5
60d26958
PB
4262 (exit $ac_status); } >/dev/null; then
4263 if test -s conftest.err; then
4264 ac_cpp_err=$ac_c_preproc_warn_flag
4265 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
4266 else
4267 ac_cpp_err=
4268 fi
bf3b7cd3 4269else
60d26958
PB
4270 ac_cpp_err=yes
4271fi
4272if test -z "$ac_cpp_err"; then
4273 # Broken: success on invalid input.
4274continue
4275else
4276 echo "$as_me: failed program was:" >&5
bf3b7cd3
JD
4277sed 's/^/| /' conftest.$ac_ext >&5
4278
60d26958
PB
4279 # Passes both tests.
4280ac_preproc_ok=:
4281break
1a4b763e 4282fi
60d26958 4283rm -f conftest.err conftest.$ac_ext
bf3b7cd3 4284
60d26958
PB
4285done
4286# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4287rm -f conftest.err conftest.$ac_ext
4288if $ac_preproc_ok; then
4289 :
4290else
18c04407
RW
4291 { { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
4292echo "$as_me: error: in \`$ac_pwd':" >&2;}
4293{ { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
60d26958
PB
4294See \`config.log' for more details." >&5
4295echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
4296See \`config.log' for more details." >&2;}
18c04407 4297 { (exit 1); exit 1; }; }; }
bf3b7cd3
JD
4298fi
4299
60d26958
PB
4300ac_ext=c
4301ac_cpp='$CPP $CPPFLAGS'
4302ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4303ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4304ac_compiler_gnu=$ac_cv_c_compiler_gnu
bf3b7cd3 4305
60d26958
PB
4306echo "$as_me:$LINENO: checking for inline" >&5
4307echo $ECHO_N "checking for inline... $ECHO_C" >&6
4308if test "${ac_cv_c_inline+set}" = set; then
bf3b7cd3
JD
4309 echo $ECHO_N "(cached) $ECHO_C" >&6
4310else
60d26958
PB
4311 ac_cv_c_inline=no
4312for ac_kw in inline __inline__ __inline; do
bf3b7cd3
JD
4313 cat >conftest.$ac_ext <<_ACEOF
4314/* confdefs.h. */
4315_ACEOF
4316cat confdefs.h >>conftest.$ac_ext
4317cat >>conftest.$ac_ext <<_ACEOF
4318/* end confdefs.h. */
60d26958
PB
4319#ifndef __cplusplus
4320typedef int foo_t;
4321static $ac_kw foo_t static_foo () {return 0; }
4322$ac_kw foo_t foo () {return 0; }
4323#endif
bf3b7cd3 4324
bf3b7cd3
JD
4325_ACEOF
4326rm -f conftest.$ac_objext
b61ff9c8
BS
4327if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4328 (eval $ac_compile) 2>conftest.er1
bf3b7cd3
JD
4329 ac_status=$?
4330 grep -v '^ *+' conftest.er1 >conftest.err
4331 rm -f conftest.er1
4332 cat conftest.err >&5
4333 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
4334 (exit $ac_status); } &&
4335 { ac_try='test -z "$ac_c_werror_flag"
4336 || test ! -s conftest.err'
4337 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4338 (eval $ac_try) 2>&5
4339 ac_status=$?
4340 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4341 (exit $ac_status); }; } &&
4342 { ac_try='test -s conftest.$ac_objext'
4343 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4344 (eval $ac_try) 2>&5
4345 ac_status=$?
4346 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4347 (exit $ac_status); }; }; then
60d26958 4348 ac_cv_c_inline=$ac_kw; break
bf3b7cd3
JD
4349else
4350 echo "$as_me: failed program was:" >&5
4351sed 's/^/| /' conftest.$ac_ext >&5
4352
bf3b7cd3 4353fi
b61ff9c8 4354rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
60d26958 4355done
bf3b7cd3
JD
4356
4357fi
60d26958
PB
4358echo "$as_me:$LINENO: result: $ac_cv_c_inline" >&5
4359echo "${ECHO_T}$ac_cv_c_inline" >&6
bf3b7cd3 4360
60d26958
PB
4361
4362case $ac_cv_c_inline in
4363 inline | yes) ;;
4364 *)
4365 case $ac_cv_c_inline in
4366 no) ac_val=;;
4367 *) ac_val=$ac_cv_c_inline;;
4368 esac
4369 cat >>confdefs.h <<_ACEOF
4370#ifndef __cplusplus
4371#define inline $ac_val
4372#endif
4373_ACEOF
4374 ;;
4375esac
bf3b7cd3
JD
4376
4377
60d26958 4378# sizeof(char) is 1 by definition.
b61ff9c8
BS
4379echo "$as_me:$LINENO: checking for void *" >&5
4380echo $ECHO_N "checking for void *... $ECHO_C" >&6
bf3b7cd3
JD
4381if test "${ac_cv_type_void_p+set}" = set; then
4382 echo $ECHO_N "(cached) $ECHO_C" >&6
4383else
4384 cat >conftest.$ac_ext <<_ACEOF
4385/* confdefs.h. */
4386_ACEOF
4387cat confdefs.h >>conftest.$ac_ext
4388cat >>conftest.$ac_ext <<_ACEOF
4389/* end confdefs.h. */
4390$ac_includes_default
4391int
4392main ()
4393{
b61ff9c8 4394if ((void * *) 0)
bf3b7cd3 4395 return 0;
b61ff9c8 4396if (sizeof (void *))
bf3b7cd3
JD
4397 return 0;
4398 ;
4399 return 0;
4400}
4401_ACEOF
4402rm -f conftest.$ac_objext
b61ff9c8
BS
4403if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4404 (eval $ac_compile) 2>conftest.er1
bf3b7cd3
JD
4405 ac_status=$?
4406 grep -v '^ *+' conftest.er1 >conftest.err
4407 rm -f conftest.er1
4408 cat conftest.err >&5
4409 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
4410 (exit $ac_status); } &&
4411 { ac_try='test -z "$ac_c_werror_flag"
4412 || test ! -s conftest.err'
4413 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4414 (eval $ac_try) 2>&5
4415 ac_status=$?
4416 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4417 (exit $ac_status); }; } &&
4418 { ac_try='test -s conftest.$ac_objext'
4419 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4420 (eval $ac_try) 2>&5
4421 ac_status=$?
4422 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4423 (exit $ac_status); }; }; then
bf3b7cd3
JD
4424 ac_cv_type_void_p=yes
4425else
4426 echo "$as_me: failed program was:" >&5
4427sed 's/^/| /' conftest.$ac_ext >&5
4428
b61ff9c8 4429ac_cv_type_void_p=no
bf3b7cd3 4430fi
b61ff9c8 4431rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
bf3b7cd3 4432fi
b61ff9c8
BS
4433echo "$as_me:$LINENO: result: $ac_cv_type_void_p" >&5
4434echo "${ECHO_T}$ac_cv_type_void_p" >&6
bf3b7cd3 4435
b61ff9c8
BS
4436echo "$as_me:$LINENO: checking size of void *" >&5
4437echo $ECHO_N "checking size of void *... $ECHO_C" >&6
ba479fd2
NN
4438if test "${ac_cv_sizeof_void_p+set}" = set; then
4439 echo $ECHO_N "(cached) $ECHO_C" >&6
75b6f3fd 4440else
b61ff9c8
BS
4441 if test "$ac_cv_type_void_p" = yes; then
4442 # The cast to unsigned long works around a bug in the HP C Compiler
4443 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
4444 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
4445 # This bug is HP SR number 8606223364.
bf3b7cd3
JD
4446 if test "$cross_compiling" = yes; then
4447 # Depending upon the size, compute the lo and hi bounds.
4448cat >conftest.$ac_ext <<_ACEOF
4449/* confdefs.h. */
4450_ACEOF
4451cat confdefs.h >>conftest.$ac_ext
4452cat >>conftest.$ac_ext <<_ACEOF
4453/* end confdefs.h. */
4454$ac_includes_default
4455int
4456main ()
4457{
b61ff9c8 4458static int test_array [1 - 2 * !(((long) (sizeof (void *))) >= 0)];
bf3b7cd3
JD
4459test_array [0] = 0
4460
4461 ;
4462 return 0;
4463}
4464_ACEOF
4465rm -f conftest.$ac_objext
b61ff9c8
BS
4466if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4467 (eval $ac_compile) 2>conftest.er1
bf3b7cd3
JD
4468 ac_status=$?
4469 grep -v '^ *+' conftest.er1 >conftest.err
4470 rm -f conftest.er1
4471 cat conftest.err >&5
4472 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
4473 (exit $ac_status); } &&
4474 { ac_try='test -z "$ac_c_werror_flag"
4475 || test ! -s conftest.err'
4476 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4477 (eval $ac_try) 2>&5
4478 ac_status=$?
4479 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4480 (exit $ac_status); }; } &&
4481 { ac_try='test -s conftest.$ac_objext'
4482 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4483 (eval $ac_try) 2>&5
4484 ac_status=$?
4485 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4486 (exit $ac_status); }; }; then
bf3b7cd3
JD
4487 ac_lo=0 ac_mid=0
4488 while :; do
4489 cat >conftest.$ac_ext <<_ACEOF
4490/* confdefs.h. */
4491_ACEOF
4492cat confdefs.h >>conftest.$ac_ext
4493cat >>conftest.$ac_ext <<_ACEOF
4494/* end confdefs.h. */
4495$ac_includes_default
4496int
4497main ()
4498{
b61ff9c8 4499static int test_array [1 - 2 * !(((long) (sizeof (void *))) <= $ac_mid)];
bf3b7cd3
JD
4500test_array [0] = 0
4501
4502 ;
4503 return 0;
4504}
4505_ACEOF
4506rm -f conftest.$ac_objext
b61ff9c8
BS
4507if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4508 (eval $ac_compile) 2>conftest.er1
bf3b7cd3
JD
4509 ac_status=$?
4510 grep -v '^ *+' conftest.er1 >conftest.err
4511 rm -f conftest.er1
4512 cat conftest.err >&5
4513 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
4514 (exit $ac_status); } &&
4515 { ac_try='test -z "$ac_c_werror_flag"
4516 || test ! -s conftest.err'
4517 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4518 (eval $ac_try) 2>&5
4519 ac_status=$?
4520 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4521 (exit $ac_status); }; } &&
4522 { ac_try='test -s conftest.$ac_objext'
4523 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4524 (eval $ac_try) 2>&5
4525 ac_status=$?
4526 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4527 (exit $ac_status); }; }; then
bf3b7cd3
JD
4528 ac_hi=$ac_mid; break
4529else
4530 echo "$as_me: failed program was:" >&5
4531sed 's/^/| /' conftest.$ac_ext >&5
4532
b61ff9c8
BS
4533ac_lo=`expr $ac_mid + 1`
4534 if test $ac_lo -le $ac_mid; then
4535 ac_lo= ac_hi=
4536 break
4537 fi
4538 ac_mid=`expr 2 '*' $ac_mid + 1`
bf3b7cd3 4539fi
b61ff9c8 4540rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
bf3b7cd3
JD
4541 done
4542else
4543 echo "$as_me: failed program was:" >&5
4544sed 's/^/| /' conftest.$ac_ext >&5
4545
b61ff9c8 4546cat >conftest.$ac_ext <<_ACEOF
bf3b7cd3
JD
4547/* confdefs.h. */
4548_ACEOF
4549cat confdefs.h >>conftest.$ac_ext
4550cat >>conftest.$ac_ext <<_ACEOF
4551/* end confdefs.h. */
4552$ac_includes_default
4553int
4554main ()
4555{
b61ff9c8 4556static int test_array [1 - 2 * !(((long) (sizeof (void *))) < 0)];
bf3b7cd3
JD
4557test_array [0] = 0
4558
4559 ;
4560 return 0;
4561}
4562_ACEOF
4563rm -f conftest.$ac_objext
b61ff9c8
BS
4564if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4565 (eval $ac_compile) 2>conftest.er1
bf3b7cd3
JD
4566 ac_status=$?
4567 grep -v '^ *+' conftest.er1 >conftest.err
4568 rm -f conftest.er1
4569 cat conftest.err >&5
4570 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
4571 (exit $ac_status); } &&
4572 { ac_try='test -z "$ac_c_werror_flag"
4573 || test ! -s conftest.err'
4574 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4575 (eval $ac_try) 2>&5
4576 ac_status=$?
4577 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4578 (exit $ac_status); }; } &&
4579 { ac_try='test -s conftest.$ac_objext'
4580 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4581 (eval $ac_try) 2>&5
4582 ac_status=$?
4583 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4584 (exit $ac_status); }; }; then
bf3b7cd3
JD
4585 ac_hi=-1 ac_mid=-1
4586 while :; do
4587 cat >conftest.$ac_ext <<_ACEOF
4588/* confdefs.h. */
4589_ACEOF
4590cat confdefs.h >>conftest.$ac_ext
4591cat >>conftest.$ac_ext <<_ACEOF
4592/* end confdefs.h. */
4593$ac_includes_default
4594int
4595main ()
4596{
b61ff9c8 4597static int test_array [1 - 2 * !(((long) (sizeof (void *))) >= $ac_mid)];
bf3b7cd3
JD
4598test_array [0] = 0
4599
4600 ;
4601 return 0;
4602}
4603_ACEOF
4604rm -f conftest.$ac_objext
b61ff9c8
BS
4605if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4606 (eval $ac_compile) 2>conftest.er1
bf3b7cd3
JD
4607 ac_status=$?
4608 grep -v '^ *+' conftest.er1 >conftest.err
4609 rm -f conftest.er1
4610 cat conftest.err >&5
4611 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
4612 (exit $ac_status); } &&
4613 { ac_try='test -z "$ac_c_werror_flag"
4614 || test ! -s conftest.err'
4615 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4616 (eval $ac_try) 2>&5
4617 ac_status=$?
4618 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4619 (exit $ac_status); }; } &&
4620 { ac_try='test -s conftest.$ac_objext'
4621 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4622 (eval $ac_try) 2>&5
4623 ac_status=$?
4624 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4625 (exit $ac_status); }; }; then
bf3b7cd3
JD
4626 ac_lo=$ac_mid; break
4627else
4628 echo "$as_me: failed program was:" >&5
4629sed 's/^/| /' conftest.$ac_ext >&5
4630
b61ff9c8
BS
4631ac_hi=`expr '(' $ac_mid ')' - 1`
4632 if test $ac_mid -le $ac_hi; then
4633 ac_lo= ac_hi=
4634 break
4635 fi
4636 ac_mid=`expr 2 '*' $ac_mid`
bf3b7cd3 4637fi
b61ff9c8 4638rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
bf3b7cd3
JD
4639 done
4640else
4641 echo "$as_me: failed program was:" >&5
4642sed 's/^/| /' conftest.$ac_ext >&5
4643
b61ff9c8 4644ac_lo= ac_hi=
bf3b7cd3 4645fi
b61ff9c8 4646rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
bf3b7cd3 4647fi
b61ff9c8 4648rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
bf3b7cd3
JD
4649# Binary search between lo and hi bounds.
4650while test "x$ac_lo" != "x$ac_hi"; do
4651 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
4652 cat >conftest.$ac_ext <<_ACEOF
4653/* confdefs.h. */
4654_ACEOF
4655cat confdefs.h >>conftest.$ac_ext
4656cat >>conftest.$ac_ext <<_ACEOF
4657/* end confdefs.h. */
4658$ac_includes_default
4659int
4660main ()
4661{
b61ff9c8 4662static int test_array [1 - 2 * !(((long) (sizeof (void *))) <= $ac_mid)];
bf3b7cd3
JD
4663test_array [0] = 0
4664
4665 ;
4666 return 0;
4667}
4668_ACEOF
4669rm -f conftest.$ac_objext
b61ff9c8
BS
4670if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4671 (eval $ac_compile) 2>conftest.er1
bf3b7cd3
JD
4672 ac_status=$?
4673 grep -v '^ *+' conftest.er1 >conftest.err
4674 rm -f conftest.er1
4675 cat conftest.err >&5
4676 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
4677 (exit $ac_status); } &&
4678 { ac_try='test -z "$ac_c_werror_flag"
4679 || test ! -s conftest.err'
4680 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4681 (eval $ac_try) 2>&5
4682 ac_status=$?
4683 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4684 (exit $ac_status); }; } &&
4685 { ac_try='test -s conftest.$ac_objext'
4686 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4687 (eval $ac_try) 2>&5
4688 ac_status=$?
4689 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4690 (exit $ac_status); }; }; then
bf3b7cd3
JD
4691 ac_hi=$ac_mid
4692else
4693 echo "$as_me: failed program was:" >&5
4694sed 's/^/| /' conftest.$ac_ext >&5
4695
b61ff9c8 4696ac_lo=`expr '(' $ac_mid ')' + 1`
bf3b7cd3 4697fi
b61ff9c8 4698rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
bf3b7cd3
JD
4699done
4700case $ac_lo in
4701?*) ac_cv_sizeof_void_p=$ac_lo;;
18c04407
RW
4702'') { { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
4703echo "$as_me: error: in \`$ac_pwd':" >&2;}
4704{ { echo "$as_me:$LINENO: error: cannot compute sizeof (void *), 77
bf3b7cd3 4705See \`config.log' for more details." >&5
b61ff9c8 4706echo "$as_me: error: cannot compute sizeof (void *), 77
bf3b7cd3 4707See \`config.log' for more details." >&2;}
18c04407 4708 { (exit 1); exit 1; }; }; } ;;
bf3b7cd3 4709esac
b61ff9c8
BS
4710else
4711 if test "$cross_compiling" = yes; then
18c04407
RW
4712 { { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
4713echo "$as_me: error: in \`$ac_pwd':" >&2;}
4714{ { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
b61ff9c8
BS
4715See \`config.log' for more details." >&5
4716echo "$as_me: error: cannot run test program while cross compiling
4717See \`config.log' for more details." >&2;}
18c04407 4718 { (exit 1); exit 1; }; }; }
bf3b7cd3
JD
4719else
4720 cat >conftest.$ac_ext <<_ACEOF
4721/* confdefs.h. */
4722_ACEOF
4723cat confdefs.h >>conftest.$ac_ext
4724cat >>conftest.$ac_ext <<_ACEOF
4725/* end confdefs.h. */
4726$ac_includes_default
b61ff9c8
BS
4727long longval () { return (long) (sizeof (void *)); }
4728unsigned long ulongval () { return (long) (sizeof (void *)); }
bf3b7cd3
JD
4729#include <stdio.h>
4730#include <stdlib.h>
4731int
4732main ()
4733{
4734
4735 FILE *f = fopen ("conftest.val", "w");
4736 if (! f)
b61ff9c8
BS
4737 exit (1);
4738 if (((long) (sizeof (void *))) < 0)
bf3b7cd3 4739 {
b61ff9c8
BS
4740 long i = longval ();
4741 if (i != ((long) (sizeof (void *))))
4742 exit (1);
bf3b7cd3
JD
4743 fprintf (f, "%ld\n", i);
4744 }
4745 else
4746 {
b61ff9c8
BS
4747 unsigned long i = ulongval ();
4748 if (i != ((long) (sizeof (void *))))
4749 exit (1);
bf3b7cd3
JD
4750 fprintf (f, "%lu\n", i);
4751 }
b61ff9c8 4752 exit (ferror (f) || fclose (f) != 0);
bf3b7cd3
JD
4753
4754 ;
4755 return 0;
4756}
4757_ACEOF
4758rm -f conftest$ac_exeext
b61ff9c8
BS
4759if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4760 (eval $ac_link) 2>&5
bf3b7cd3
JD
4761 ac_status=$?
4762 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4763 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
b61ff9c8
BS
4764 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4765 (eval $ac_try) 2>&5
bf3b7cd3
JD
4766 ac_status=$?
4767 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4768 (exit $ac_status); }; }; then
4769 ac_cv_sizeof_void_p=`cat conftest.val`
4770else
4771 echo "$as_me: program exited with status $ac_status" >&5
4772echo "$as_me: failed program was:" >&5
4773sed 's/^/| /' conftest.$ac_ext >&5
4774
4775( exit $ac_status )
18c04407
RW
4776{ { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
4777echo "$as_me: error: in \`$ac_pwd':" >&2;}
b61ff9c8 4778{ { echo "$as_me:$LINENO: error: cannot compute sizeof (void *), 77
bf3b7cd3 4779See \`config.log' for more details." >&5
b61ff9c8 4780echo "$as_me: error: cannot compute sizeof (void *), 77
bf3b7cd3 4781See \`config.log' for more details." >&2;}
18c04407 4782 { (exit 1); exit 1; }; }; }
b61ff9c8
BS
4783fi
4784rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
bf3b7cd3
JD
4785fi
4786fi
4787rm -f conftest.val
b61ff9c8
BS
4788else
4789 ac_cv_sizeof_void_p=0
bf3b7cd3 4790fi
b61ff9c8
BS
4791fi
4792echo "$as_me:$LINENO: result: $ac_cv_sizeof_void_p" >&5
4793echo "${ECHO_T}$ac_cv_sizeof_void_p" >&6
bf3b7cd3
JD
4794cat >>confdefs.h <<_ACEOF
4795#define SIZEOF_VOID_P $ac_cv_sizeof_void_p
4796_ACEOF
4797
4798
b61ff9c8
BS
4799echo "$as_me:$LINENO: checking for short" >&5
4800echo $ECHO_N "checking for short... $ECHO_C" >&6
bf3b7cd3
JD
4801if test "${ac_cv_type_short+set}" = set; then
4802 echo $ECHO_N "(cached) $ECHO_C" >&6
4803else
4804 cat >conftest.$ac_ext <<_ACEOF
4805/* confdefs.h. */
4806_ACEOF
4807cat confdefs.h >>conftest.$ac_ext
4808cat >>conftest.$ac_ext <<_ACEOF
4809/* end confdefs.h. */
4810$ac_includes_default
4811int
4812main ()
4813{
b61ff9c8 4814if ((short *) 0)
bf3b7cd3 4815 return 0;
b61ff9c8 4816if (sizeof (short))
bf3b7cd3
JD
4817 return 0;
4818 ;
4819 return 0;
4820}
4821_ACEOF
4822rm -f conftest.$ac_objext
b61ff9c8
BS
4823if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4824 (eval $ac_compile) 2>conftest.er1
bf3b7cd3
JD
4825 ac_status=$?
4826 grep -v '^ *+' conftest.er1 >conftest.err
4827 rm -f conftest.er1
4828 cat conftest.err >&5
4829 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
4830 (exit $ac_status); } &&
4831 { ac_try='test -z "$ac_c_werror_flag"
4832 || test ! -s conftest.err'
4833 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4834 (eval $ac_try) 2>&5
4835 ac_status=$?
4836 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4837 (exit $ac_status); }; } &&
4838 { ac_try='test -s conftest.$ac_objext'
4839 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4840 (eval $ac_try) 2>&5
4841 ac_status=$?
4842 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4843 (exit $ac_status); }; }; then
bf3b7cd3
JD
4844 ac_cv_type_short=yes
4845else
4846 echo "$as_me: failed program was:" >&5
4847sed 's/^/| /' conftest.$ac_ext >&5
4848
b61ff9c8 4849ac_cv_type_short=no
bf3b7cd3 4850fi
b61ff9c8 4851rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
bf3b7cd3 4852fi
b61ff9c8
BS
4853echo "$as_me:$LINENO: result: $ac_cv_type_short" >&5
4854echo "${ECHO_T}$ac_cv_type_short" >&6
bf3b7cd3 4855
b61ff9c8
BS
4856echo "$as_me:$LINENO: checking size of short" >&5
4857echo $ECHO_N "checking size of short... $ECHO_C" >&6
bf3b7cd3
JD
4858if test "${ac_cv_sizeof_short+set}" = set; then
4859 echo $ECHO_N "(cached) $ECHO_C" >&6
4860else
b61ff9c8
BS
4861 if test "$ac_cv_type_short" = yes; then
4862 # The cast to unsigned long works around a bug in the HP C Compiler
4863 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
4864 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
4865 # This bug is HP SR number 8606223364.
bf3b7cd3
JD
4866 if test "$cross_compiling" = yes; then
4867 # Depending upon the size, compute the lo and hi bounds.
4868cat >conftest.$ac_ext <<_ACEOF
4869/* confdefs.h. */
4870_ACEOF
4871cat confdefs.h >>conftest.$ac_ext
4872cat >>conftest.$ac_ext <<_ACEOF
4873/* end confdefs.h. */
4874$ac_includes_default
4875int
4876main ()
4877{
b61ff9c8 4878static int test_array [1 - 2 * !(((long) (sizeof (short))) >= 0)];
bf3b7cd3
JD
4879test_array [0] = 0
4880
4881 ;
4882 return 0;
4883}
4884_ACEOF
4885rm -f conftest.$ac_objext
b61ff9c8
BS
4886if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4887 (eval $ac_compile) 2>conftest.er1
bf3b7cd3
JD
4888 ac_status=$?
4889 grep -v '^ *+' conftest.er1 >conftest.err
4890 rm -f conftest.er1
4891 cat conftest.err >&5
4892 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
4893 (exit $ac_status); } &&
4894 { ac_try='test -z "$ac_c_werror_flag"
4895 || test ! -s conftest.err'
4896 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4897 (eval $ac_try) 2>&5
4898 ac_status=$?
4899 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4900 (exit $ac_status); }; } &&
4901 { ac_try='test -s conftest.$ac_objext'
4902 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4903 (eval $ac_try) 2>&5
4904 ac_status=$?
4905 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4906 (exit $ac_status); }; }; then
bf3b7cd3
JD
4907 ac_lo=0 ac_mid=0
4908 while :; do
4909 cat >conftest.$ac_ext <<_ACEOF
4910/* confdefs.h. */
4911_ACEOF
4912cat confdefs.h >>conftest.$ac_ext
4913cat >>conftest.$ac_ext <<_ACEOF
4914/* end confdefs.h. */
4915$ac_includes_default
4916int
4917main ()
4918{
b61ff9c8 4919static int test_array [1 - 2 * !(((long) (sizeof (short))) <= $ac_mid)];
bf3b7cd3
JD
4920test_array [0] = 0
4921
4922 ;
4923 return 0;
4924}
4925_ACEOF
4926rm -f conftest.$ac_objext
b61ff9c8
BS
4927if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4928 (eval $ac_compile) 2>conftest.er1
bf3b7cd3
JD
4929 ac_status=$?
4930 grep -v '^ *+' conftest.er1 >conftest.err
4931 rm -f conftest.er1
4932 cat conftest.err >&5
4933 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
4934 (exit $ac_status); } &&
4935 { ac_try='test -z "$ac_c_werror_flag"
4936 || test ! -s conftest.err'
4937 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4938 (eval $ac_try) 2>&5
4939 ac_status=$?
4940 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4941 (exit $ac_status); }; } &&
4942 { ac_try='test -s conftest.$ac_objext'
4943 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4944 (eval $ac_try) 2>&5
4945 ac_status=$?
4946 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4947 (exit $ac_status); }; }; then
bf3b7cd3
JD
4948 ac_hi=$ac_mid; break
4949else
4950 echo "$as_me: failed program was:" >&5
4951sed 's/^/| /' conftest.$ac_ext >&5
4952
b61ff9c8
BS
4953ac_lo=`expr $ac_mid + 1`
4954 if test $ac_lo -le $ac_mid; then
4955 ac_lo= ac_hi=
4956 break
4957 fi
4958 ac_mid=`expr 2 '*' $ac_mid + 1`
bf3b7cd3 4959fi
b61ff9c8 4960rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
bf3b7cd3
JD
4961 done
4962else
4963 echo "$as_me: failed program was:" >&5
4964sed 's/^/| /' conftest.$ac_ext >&5
4965
b61ff9c8 4966cat >conftest.$ac_ext <<_ACEOF
bf3b7cd3
JD
4967/* confdefs.h. */
4968_ACEOF
4969cat confdefs.h >>conftest.$ac_ext
4970cat >>conftest.$ac_ext <<_ACEOF
4971/* end confdefs.h. */
4972$ac_includes_default
4973int
4974main ()
4975{
b61ff9c8 4976static int test_array [1 - 2 * !(((long) (sizeof (short))) < 0)];
bf3b7cd3
JD
4977test_array [0] = 0
4978
4979 ;
4980 return 0;
4981}
4982_ACEOF
4983rm -f conftest.$ac_objext
b61ff9c8
BS
4984if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4985 (eval $ac_compile) 2>conftest.er1
bf3b7cd3
JD
4986 ac_status=$?
4987 grep -v '^ *+' conftest.er1 >conftest.err
4988 rm -f conftest.er1
4989 cat conftest.err >&5
4990 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
4991 (exit $ac_status); } &&
4992 { ac_try='test -z "$ac_c_werror_flag"
4993 || test ! -s conftest.err'
4994 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4995 (eval $ac_try) 2>&5
4996 ac_status=$?
4997 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4998 (exit $ac_status); }; } &&
4999 { ac_try='test -s conftest.$ac_objext'
5000 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5001 (eval $ac_try) 2>&5
5002 ac_status=$?
5003 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5004 (exit $ac_status); }; }; then
bf3b7cd3
JD
5005 ac_hi=-1 ac_mid=-1
5006 while :; do
5007 cat >conftest.$ac_ext <<_ACEOF
5008/* confdefs.h. */
5009_ACEOF
5010cat confdefs.h >>conftest.$ac_ext
5011cat >>conftest.$ac_ext <<_ACEOF
5012/* end confdefs.h. */
5013$ac_includes_default
5014int
5015main ()
5016{
b61ff9c8 5017static int test_array [1 - 2 * !(((long) (sizeof (short))) >= $ac_mid)];
bf3b7cd3
JD
5018test_array [0] = 0
5019
5020 ;
5021 return 0;
5022}
5023_ACEOF
5024rm -f conftest.$ac_objext
b61ff9c8
BS
5025if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5026 (eval $ac_compile) 2>conftest.er1
bf3b7cd3
JD
5027 ac_status=$?
5028 grep -v '^ *+' conftest.er1 >conftest.err
5029 rm -f conftest.er1
5030 cat conftest.err >&5
5031 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
5032 (exit $ac_status); } &&
5033 { ac_try='test -z "$ac_c_werror_flag"
5034 || test ! -s conftest.err'
5035 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5036 (eval $ac_try) 2>&5
5037 ac_status=$?
5038 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5039 (exit $ac_status); }; } &&
5040 { ac_try='test -s conftest.$ac_objext'
5041 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5042 (eval $ac_try) 2>&5
5043 ac_status=$?
5044 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5045 (exit $ac_status); }; }; then
bf3b7cd3
JD
5046 ac_lo=$ac_mid; break
5047else
5048 echo "$as_me: failed program was:" >&5
5049sed 's/^/| /' conftest.$ac_ext >&5
5050
b61ff9c8
BS
5051ac_hi=`expr '(' $ac_mid ')' - 1`
5052 if test $ac_mid -le $ac_hi; then
5053 ac_lo= ac_hi=
5054 break
5055 fi
5056 ac_mid=`expr 2 '*' $ac_mid`
bf3b7cd3 5057fi
b61ff9c8 5058rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
bf3b7cd3
JD
5059 done
5060else
5061 echo "$as_me: failed program was:" >&5
5062sed 's/^/| /' conftest.$ac_ext >&5
5063
b61ff9c8 5064ac_lo= ac_hi=
bf3b7cd3 5065fi
b61ff9c8 5066rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
bf3b7cd3 5067fi
b61ff9c8 5068rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
bf3b7cd3
JD
5069# Binary search between lo and hi bounds.
5070while test "x$ac_lo" != "x$ac_hi"; do
5071 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
5072 cat >conftest.$ac_ext <<_ACEOF
5073/* confdefs.h. */
5074_ACEOF
5075cat confdefs.h >>conftest.$ac_ext
5076cat >>conftest.$ac_ext <<_ACEOF
5077/* end confdefs.h. */
5078$ac_includes_default
5079int
5080main ()
5081{
b61ff9c8 5082static int test_array [1 - 2 * !(((long) (sizeof (short))) <= $ac_mid)];
bf3b7cd3
JD
5083test_array [0] = 0
5084
5085 ;
5086 return 0;
5087}
5088_ACEOF
5089rm -f conftest.$ac_objext
b61ff9c8
BS
5090if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5091 (eval $ac_compile) 2>conftest.er1
bf3b7cd3
JD
5092 ac_status=$?
5093 grep -v '^ *+' conftest.er1 >conftest.err
5094 rm -f conftest.er1
5095 cat conftest.err >&5
5096 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
5097 (exit $ac_status); } &&
5098 { ac_try='test -z "$ac_c_werror_flag"
5099 || test ! -s conftest.err'
5100 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5101 (eval $ac_try) 2>&5
5102 ac_status=$?
5103 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5104 (exit $ac_status); }; } &&
5105 { ac_try='test -s conftest.$ac_objext'
5106 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5107 (eval $ac_try) 2>&5
5108 ac_status=$?
5109 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5110 (exit $ac_status); }; }; then
bf3b7cd3
JD
5111 ac_hi=$ac_mid
5112else
5113 echo "$as_me: failed program was:" >&5
5114sed 's/^/| /' conftest.$ac_ext >&5
5115
b61ff9c8 5116ac_lo=`expr '(' $ac_mid ')' + 1`
bf3b7cd3 5117fi
b61ff9c8 5118rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
bf3b7cd3
JD
5119done
5120case $ac_lo in
5121?*) ac_cv_sizeof_short=$ac_lo;;
18c04407
RW
5122'') { { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
5123echo "$as_me: error: in \`$ac_pwd':" >&2;}
5124{ { echo "$as_me:$LINENO: error: cannot compute sizeof (short), 77
bf3b7cd3 5125See \`config.log' for more details." >&5
b61ff9c8 5126echo "$as_me: error: cannot compute sizeof (short), 77
bf3b7cd3 5127See \`config.log' for more details." >&2;}
18c04407 5128 { (exit 1); exit 1; }; }; } ;;
bf3b7cd3 5129esac
b61ff9c8
BS
5130else
5131 if test "$cross_compiling" = yes; then
18c04407
RW
5132 { { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
5133echo "$as_me: error: in \`$ac_pwd':" >&2;}
5134{ { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
b61ff9c8
BS
5135See \`config.log' for more details." >&5
5136echo "$as_me: error: cannot run test program while cross compiling
5137See \`config.log' for more details." >&2;}
18c04407 5138 { (exit 1); exit 1; }; }; }
8b1f719a
PB
5139else
5140 cat >conftest.$ac_ext <<_ACEOF
bf3b7cd3
JD
5141/* confdefs.h. */
5142_ACEOF
5143cat confdefs.h >>conftest.$ac_ext
5144cat >>conftest.$ac_ext <<_ACEOF
5145/* end confdefs.h. */
5146$ac_includes_default
b61ff9c8
BS
5147long longval () { return (long) (sizeof (short)); }
5148unsigned long ulongval () { return (long) (sizeof (short)); }
bf3b7cd3
JD
5149#include <stdio.h>
5150#include <stdlib.h>
5151int
5152main ()
5153{
5154
5155 FILE *f = fopen ("conftest.val", "w");
5156 if (! f)
b61ff9c8
BS
5157 exit (1);
5158 if (((long) (sizeof (short))) < 0)
bf3b7cd3 5159 {
b61ff9c8
BS
5160 long i = longval ();
5161 if (i != ((long) (sizeof (short))))
5162 exit (1);
bf3b7cd3
JD
5163 fprintf (f, "%ld\n", i);
5164 }
5165 else
5166 {
b61ff9c8
BS
5167 unsigned long i = ulongval ();
5168 if (i != ((long) (sizeof (short))))
5169 exit (1);
bf3b7cd3
JD
5170 fprintf (f, "%lu\n", i);
5171 }
b61ff9c8 5172 exit (ferror (f) || fclose (f) != 0);
bf3b7cd3
JD
5173
5174 ;
5175 return 0;
5176}
5177_ACEOF
5178rm -f conftest$ac_exeext
b61ff9c8
BS
5179if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5180 (eval $ac_link) 2>&5
bf3b7cd3
JD
5181 ac_status=$?
5182 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5183 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
b61ff9c8
BS
5184 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5185 (eval $ac_try) 2>&5
bf3b7cd3
JD
5186 ac_status=$?
5187 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5188 (exit $ac_status); }; }; then
5189 ac_cv_sizeof_short=`cat conftest.val`
5190else
5191 echo "$as_me: program exited with status $ac_status" >&5
5192echo "$as_me: failed program was:" >&5
5193sed 's/^/| /' conftest.$ac_ext >&5
5194
5195( exit $ac_status )
18c04407
RW
5196{ { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
5197echo "$as_me: error: in \`$ac_pwd':" >&2;}
b61ff9c8 5198{ { echo "$as_me:$LINENO: error: cannot compute sizeof (short), 77
bf3b7cd3 5199See \`config.log' for more details." >&5
b61ff9c8 5200echo "$as_me: error: cannot compute sizeof (short), 77
bf3b7cd3 5201See \`config.log' for more details." >&2;}
18c04407 5202 { (exit 1); exit 1; }; }; }
b61ff9c8
BS
5203fi
5204rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
bf3b7cd3
JD
5205fi
5206fi
5207rm -f conftest.val
b61ff9c8
BS
5208else
5209 ac_cv_sizeof_short=0
bf3b7cd3 5210fi
b61ff9c8
BS
5211fi
5212echo "$as_me:$LINENO: result: $ac_cv_sizeof_short" >&5
5213echo "${ECHO_T}$ac_cv_sizeof_short" >&6
bf3b7cd3
JD
5214cat >>confdefs.h <<_ACEOF
5215#define SIZEOF_SHORT $ac_cv_sizeof_short
5216_ACEOF
5217
5218
b61ff9c8
BS
5219echo "$as_me:$LINENO: checking for int" >&5
5220echo $ECHO_N "checking for int... $ECHO_C" >&6
bf3b7cd3
JD
5221if test "${ac_cv_type_int+set}" = set; then
5222 echo $ECHO_N "(cached) $ECHO_C" >&6
5223else
5224 cat >conftest.$ac_ext <<_ACEOF
5225/* confdefs.h. */
5226_ACEOF
5227cat confdefs.h >>conftest.$ac_ext
5228cat >>conftest.$ac_ext <<_ACEOF
5229/* end confdefs.h. */
5230$ac_includes_default
5231int
5232main ()
5233{
b61ff9c8 5234if ((int *) 0)
bf3b7cd3 5235 return 0;
b61ff9c8 5236if (sizeof (int))
bf3b7cd3
JD
5237 return 0;
5238 ;
5239 return 0;
5240}
5241_ACEOF
5242rm -f conftest.$ac_objext
b61ff9c8
BS
5243if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5244 (eval $ac_compile) 2>conftest.er1
bf3b7cd3
JD
5245 ac_status=$?
5246 grep -v '^ *+' conftest.er1 >conftest.err
5247 rm -f conftest.er1
5248 cat conftest.err >&5
5249 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
5250 (exit $ac_status); } &&
5251 { ac_try='test -z "$ac_c_werror_flag"
5252 || test ! -s conftest.err'
5253 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5254 (eval $ac_try) 2>&5
5255 ac_status=$?
5256 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5257 (exit $ac_status); }; } &&
5258 { ac_try='test -s conftest.$ac_objext'
5259 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5260 (eval $ac_try) 2>&5
5261 ac_status=$?
5262 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5263 (exit $ac_status); }; }; then
bf3b7cd3
JD
5264 ac_cv_type_int=yes
5265else
5266 echo "$as_me: failed program was:" >&5
5267sed 's/^/| /' conftest.$ac_ext >&5
5268
b61ff9c8 5269ac_cv_type_int=no
bf3b7cd3 5270fi
b61ff9c8 5271rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
bf3b7cd3 5272fi
b61ff9c8
BS
5273echo "$as_me:$LINENO: result: $ac_cv_type_int" >&5
5274echo "${ECHO_T}$ac_cv_type_int" >&6
bf3b7cd3 5275
b61ff9c8
BS
5276echo "$as_me:$LINENO: checking size of int" >&5
5277echo $ECHO_N "checking size of int... $ECHO_C" >&6
bf3b7cd3
JD
5278if test "${ac_cv_sizeof_int+set}" = set; then
5279 echo $ECHO_N "(cached) $ECHO_C" >&6
5280else
b61ff9c8
BS
5281 if test "$ac_cv_type_int" = yes; then
5282 # The cast to unsigned long works around a bug in the HP C Compiler
5283 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
5284 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
5285 # This bug is HP SR number 8606223364.
bf3b7cd3
JD
5286 if test "$cross_compiling" = yes; then
5287 # Depending upon the size, compute the lo and hi bounds.
5288cat >conftest.$ac_ext <<_ACEOF
5289/* confdefs.h. */
5290_ACEOF
5291cat confdefs.h >>conftest.$ac_ext
5292cat >>conftest.$ac_ext <<_ACEOF
5293/* end confdefs.h. */
5294$ac_includes_default
5295int
5296main ()
5297{
b61ff9c8 5298static int test_array [1 - 2 * !(((long) (sizeof (int))) >= 0)];
bf3b7cd3
JD
5299test_array [0] = 0
5300
5301 ;
5302 return 0;
5303}
5304_ACEOF
5305rm -f conftest.$ac_objext
b61ff9c8
BS
5306if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5307 (eval $ac_compile) 2>conftest.er1
bf3b7cd3
JD
5308 ac_status=$?
5309 grep -v '^ *+' conftest.er1 >conftest.err
5310 rm -f conftest.er1
5311 cat conftest.err >&5
5312 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
5313 (exit $ac_status); } &&
5314 { ac_try='test -z "$ac_c_werror_flag"
5315 || test ! -s conftest.err'
5316 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5317 (eval $ac_try) 2>&5
5318 ac_status=$?
5319 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5320 (exit $ac_status); }; } &&
5321 { ac_try='test -s conftest.$ac_objext'
5322 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5323 (eval $ac_try) 2>&5
5324 ac_status=$?
5325 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5326 (exit $ac_status); }; }; then
bf3b7cd3
JD
5327 ac_lo=0 ac_mid=0
5328 while :; do
5329 cat >conftest.$ac_ext <<_ACEOF
5330/* confdefs.h. */
5331_ACEOF
5332cat confdefs.h >>conftest.$ac_ext
5333cat >>conftest.$ac_ext <<_ACEOF
5334/* end confdefs.h. */
5335$ac_includes_default
5336int
5337main ()
5338{
b61ff9c8 5339static int test_array [1 - 2 * !(((long) (sizeof (int))) <= $ac_mid)];
bf3b7cd3
JD
5340test_array [0] = 0
5341
5342 ;
5343 return 0;
5344}
5345_ACEOF
5346rm -f conftest.$ac_objext
b61ff9c8
BS
5347if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5348 (eval $ac_compile) 2>conftest.er1
bf3b7cd3
JD
5349 ac_status=$?
5350 grep -v '^ *+' conftest.er1 >conftest.err
5351 rm -f conftest.er1
5352 cat conftest.err >&5
5353 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
5354 (exit $ac_status); } &&
5355 { ac_try='test -z "$ac_c_werror_flag"
5356 || test ! -s conftest.err'
5357 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5358 (eval $ac_try) 2>&5
5359 ac_status=$?
5360 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5361 (exit $ac_status); }; } &&
5362 { ac_try='test -s conftest.$ac_objext'
5363 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5364 (eval $ac_try) 2>&5
5365 ac_status=$?
5366 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5367 (exit $ac_status); }; }; then
bf3b7cd3
JD
5368 ac_hi=$ac_mid; break
5369else
5370 echo "$as_me: failed program was:" >&5
5371sed 's/^/| /' conftest.$ac_ext >&5
5372
b61ff9c8
BS
5373ac_lo=`expr $ac_mid + 1`
5374 if test $ac_lo -le $ac_mid; then
5375 ac_lo= ac_hi=
5376 break
5377 fi
5378 ac_mid=`expr 2 '*' $ac_mid + 1`
bf3b7cd3 5379fi
b61ff9c8 5380rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
bf3b7cd3
JD
5381 done
5382else
5383 echo "$as_me: failed program was:" >&5
5384sed 's/^/| /' conftest.$ac_ext >&5
5385
b61ff9c8 5386cat >conftest.$ac_ext <<_ACEOF
bf3b7cd3
JD
5387/* confdefs.h. */
5388_ACEOF
5389cat confdefs.h >>conftest.$ac_ext
5390cat >>conftest.$ac_ext <<_ACEOF
5391/* end confdefs.h. */
5392$ac_includes_default
5393int
5394main ()
5395{
b61ff9c8 5396static int test_array [1 - 2 * !(((long) (sizeof (int))) < 0)];
bf3b7cd3
JD
5397test_array [0] = 0
5398
5399 ;
5400 return 0;
5401}
5402_ACEOF
5403rm -f conftest.$ac_objext
b61ff9c8
BS
5404if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5405 (eval $ac_compile) 2>conftest.er1
bf3b7cd3
JD
5406 ac_status=$?
5407 grep -v '^ *+' conftest.er1 >conftest.err
5408 rm -f conftest.er1
5409 cat conftest.err >&5
5410 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
5411 (exit $ac_status); } &&
5412 { ac_try='test -z "$ac_c_werror_flag"
5413 || test ! -s conftest.err'
5414 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5415 (eval $ac_try) 2>&5
5416 ac_status=$?
5417 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5418 (exit $ac_status); }; } &&
5419 { ac_try='test -s conftest.$ac_objext'
5420 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5421 (eval $ac_try) 2>&5
5422 ac_status=$?
5423 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5424 (exit $ac_status); }; }; then
bf3b7cd3
JD
5425 ac_hi=-1 ac_mid=-1
5426 while :; do
5427 cat >conftest.$ac_ext <<_ACEOF
5428/* confdefs.h. */
5429_ACEOF
5430cat confdefs.h >>conftest.$ac_ext
5431cat >>conftest.$ac_ext <<_ACEOF
5432/* end confdefs.h. */
5433$ac_includes_default
5434int
5435main ()
5436{
b61ff9c8 5437static int test_array [1 - 2 * !(((long) (sizeof (int))) >= $ac_mid)];
bf3b7cd3
JD
5438test_array [0] = 0
5439
5440 ;
5441 return 0;
5442}
5443_ACEOF
5444rm -f conftest.$ac_objext
b61ff9c8
BS
5445if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5446 (eval $ac_compile) 2>conftest.er1
bf3b7cd3
JD
5447 ac_status=$?
5448 grep -v '^ *+' conftest.er1 >conftest.err
5449 rm -f conftest.er1
5450 cat conftest.err >&5
5451 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
5452 (exit $ac_status); } &&
5453 { ac_try='test -z "$ac_c_werror_flag"
5454 || test ! -s conftest.err'
5455 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5456 (eval $ac_try) 2>&5
5457 ac_status=$?
5458 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5459 (exit $ac_status); }; } &&
5460 { ac_try='test -s conftest.$ac_objext'
5461 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5462 (eval $ac_try) 2>&5
5463 ac_status=$?
5464 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5465 (exit $ac_status); }; }; then
bf3b7cd3
JD
5466 ac_lo=$ac_mid; break
5467else
5468 echo "$as_me: failed program was:" >&5
5469sed 's/^/| /' conftest.$ac_ext >&5
5470
b61ff9c8
BS
5471ac_hi=`expr '(' $ac_mid ')' - 1`
5472 if test $ac_mid -le $ac_hi; then
5473 ac_lo= ac_hi=
5474 break
5475 fi
5476 ac_mid=`expr 2 '*' $ac_mid`
bf3b7cd3 5477fi
b61ff9c8 5478rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
bf3b7cd3
JD
5479 done
5480else
5481 echo "$as_me: failed program was:" >&5
5482sed 's/^/| /' conftest.$ac_ext >&5
5483
b61ff9c8 5484ac_lo= ac_hi=
bf3b7cd3 5485fi
b61ff9c8 5486rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
bf3b7cd3 5487fi
b61ff9c8 5488rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
bf3b7cd3
JD
5489# Binary search between lo and hi bounds.
5490while test "x$ac_lo" != "x$ac_hi"; do
5491 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
5492 cat >conftest.$ac_ext <<_ACEOF
5493/* confdefs.h. */
5494_ACEOF
5495cat confdefs.h >>conftest.$ac_ext
5496cat >>conftest.$ac_ext <<_ACEOF
5497/* end confdefs.h. */
5498$ac_includes_default
5499int
5500main ()
5501{
b61ff9c8 5502static int test_array [1 - 2 * !(((long) (sizeof (int))) <= $ac_mid)];
bf3b7cd3
JD
5503test_array [0] = 0
5504
5505 ;
5506 return 0;
5507}
5508_ACEOF
5509rm -f conftest.$ac_objext
b61ff9c8
BS
5510if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5511 (eval $ac_compile) 2>conftest.er1
bf3b7cd3
JD
5512 ac_status=$?
5513 grep -v '^ *+' conftest.er1 >conftest.err
5514 rm -f conftest.er1
5515 cat conftest.err >&5
5516 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
5517 (exit $ac_status); } &&
5518 { ac_try='test -z "$ac_c_werror_flag"
5519 || test ! -s conftest.err'
5520 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5521 (eval $ac_try) 2>&5
5522 ac_status=$?
5523 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5524 (exit $ac_status); }; } &&
5525 { ac_try='test -s conftest.$ac_objext'
5526 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5527 (eval $ac_try) 2>&5
5528 ac_status=$?
5529 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5530 (exit $ac_status); }; }; then
bf3b7cd3
JD
5531 ac_hi=$ac_mid
5532else
5533 echo "$as_me: failed program was:" >&5
5534sed 's/^/| /' conftest.$ac_ext >&5
5535
b61ff9c8 5536ac_lo=`expr '(' $ac_mid ')' + 1`
bf3b7cd3 5537fi
b61ff9c8 5538rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
bf3b7cd3
JD
5539done
5540case $ac_lo in
5541?*) ac_cv_sizeof_int=$ac_lo;;
18c04407
RW
5542'') { { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
5543echo "$as_me: error: in \`$ac_pwd':" >&2;}
5544{ { echo "$as_me:$LINENO: error: cannot compute sizeof (int), 77
bf3b7cd3 5545See \`config.log' for more details." >&5
b61ff9c8 5546echo "$as_me: error: cannot compute sizeof (int), 77
bf3b7cd3 5547See \`config.log' for more details." >&2;}
18c04407 5548 { (exit 1); exit 1; }; }; } ;;
bf3b7cd3 5549esac
b61ff9c8
BS
5550else
5551 if test "$cross_compiling" = yes; then
18c04407
RW
5552 { { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
5553echo "$as_me: error: in \`$ac_pwd':" >&2;}
5554{ { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
b61ff9c8
BS
5555See \`config.log' for more details." >&5
5556echo "$as_me: error: cannot run test program while cross compiling
5557See \`config.log' for more details." >&2;}
18c04407 5558 { (exit 1); exit 1; }; }; }
bf3b7cd3
JD
5559else
5560 cat >conftest.$ac_ext <<_ACEOF
5561/* confdefs.h. */
5562_ACEOF
5563cat confdefs.h >>conftest.$ac_ext
5564cat >>conftest.$ac_ext <<_ACEOF
5565/* end confdefs.h. */
5566$ac_includes_default
b61ff9c8
BS
5567long longval () { return (long) (sizeof (int)); }
5568unsigned long ulongval () { return (long) (sizeof (int)); }
bf3b7cd3
JD
5569#include <stdio.h>
5570#include <stdlib.h>
5571int
5572main ()
5573{
5574
5575 FILE *f = fopen ("conftest.val", "w");
5576 if (! f)
b61ff9c8
BS
5577 exit (1);
5578 if (((long) (sizeof (int))) < 0)
bf3b7cd3 5579 {
b61ff9c8
BS
5580 long i = longval ();
5581 if (i != ((long) (sizeof (int))))
5582 exit (1);
bf3b7cd3
JD
5583 fprintf (f, "%ld\n", i);
5584 }
5585 else
5586 {
b61ff9c8
BS
5587 unsigned long i = ulongval ();
5588 if (i != ((long) (sizeof (int))))
5589 exit (1);
bf3b7cd3
JD
5590 fprintf (f, "%lu\n", i);
5591 }
b61ff9c8 5592 exit (ferror (f) || fclose (f) != 0);
bf3b7cd3
JD
5593
5594 ;
5595 return 0;
5596}
5597_ACEOF
5598rm -f conftest$ac_exeext
b61ff9c8
BS
5599if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5600 (eval $ac_link) 2>&5
bf3b7cd3
JD
5601 ac_status=$?
5602 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5603 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
b61ff9c8
BS
5604 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5605 (eval $ac_try) 2>&5
bf3b7cd3
JD
5606 ac_status=$?
5607 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5608 (exit $ac_status); }; }; then
5609 ac_cv_sizeof_int=`cat conftest.val`
5610else
5611 echo "$as_me: program exited with status $ac_status" >&5
5612echo "$as_me: failed program was:" >&5
5613sed 's/^/| /' conftest.$ac_ext >&5
5614
5615( exit $ac_status )
18c04407
RW
5616{ { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
5617echo "$as_me: error: in \`$ac_pwd':" >&2;}
b61ff9c8 5618{ { echo "$as_me:$LINENO: error: cannot compute sizeof (int), 77
bf3b7cd3 5619See \`config.log' for more details." >&5
b61ff9c8 5620echo "$as_me: error: cannot compute sizeof (int), 77
bf3b7cd3 5621See \`config.log' for more details." >&2;}
18c04407 5622 { (exit 1); exit 1; }; }; }
b61ff9c8
BS
5623fi
5624rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
bf3b7cd3
JD
5625fi
5626fi
5627rm -f conftest.val
b61ff9c8
BS
5628else
5629 ac_cv_sizeof_int=0
bf3b7cd3 5630fi
b61ff9c8
BS
5631fi
5632echo "$as_me:$LINENO: result: $ac_cv_sizeof_int" >&5
5633echo "${ECHO_T}$ac_cv_sizeof_int" >&6
bf3b7cd3
JD
5634cat >>confdefs.h <<_ACEOF
5635#define SIZEOF_INT $ac_cv_sizeof_int
5636_ACEOF
5637
5638
b61ff9c8
BS
5639echo "$as_me:$LINENO: checking for long" >&5
5640echo $ECHO_N "checking for long... $ECHO_C" >&6
bf3b7cd3
JD
5641if test "${ac_cv_type_long+set}" = set; then
5642 echo $ECHO_N "(cached) $ECHO_C" >&6
5643else
5644 cat >conftest.$ac_ext <<_ACEOF
5645/* confdefs.h. */
5646_ACEOF
5647cat confdefs.h >>conftest.$ac_ext
5648cat >>conftest.$ac_ext <<_ACEOF
5649/* end confdefs.h. */
5650$ac_includes_default
5651int
5652main ()
5653{
b61ff9c8 5654if ((long *) 0)
bf3b7cd3 5655 return 0;
b61ff9c8 5656if (sizeof (long))
bf3b7cd3
JD
5657 return 0;
5658 ;
5659 return 0;
5660}
5661_ACEOF
5662rm -f conftest.$ac_objext
b61ff9c8
BS
5663if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5664 (eval $ac_compile) 2>conftest.er1
bf3b7cd3
JD
5665 ac_status=$?
5666 grep -v '^ *+' conftest.er1 >conftest.err
5667 rm -f conftest.er1
5668 cat conftest.err >&5
5669 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
5670 (exit $ac_status); } &&
5671 { ac_try='test -z "$ac_c_werror_flag"
5672 || test ! -s conftest.err'
5673 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5674 (eval $ac_try) 2>&5
5675 ac_status=$?
5676 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5677 (exit $ac_status); }; } &&
5678 { ac_try='test -s conftest.$ac_objext'
5679 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5680 (eval $ac_try) 2>&5
5681 ac_status=$?
5682 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5683 (exit $ac_status); }; }; then
bf3b7cd3
JD
5684 ac_cv_type_long=yes
5685else
5686 echo "$as_me: failed program was:" >&5
5687sed 's/^/| /' conftest.$ac_ext >&5
5688
b61ff9c8 5689ac_cv_type_long=no
bf3b7cd3 5690fi
b61ff9c8 5691rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
bf3b7cd3 5692fi
b61ff9c8
BS
5693echo "$as_me:$LINENO: result: $ac_cv_type_long" >&5
5694echo "${ECHO_T}$ac_cv_type_long" >&6
bf3b7cd3 5695
b61ff9c8
BS
5696echo "$as_me:$LINENO: checking size of long" >&5
5697echo $ECHO_N "checking size of long... $ECHO_C" >&6
bf3b7cd3
JD
5698if test "${ac_cv_sizeof_long+set}" = set; then
5699 echo $ECHO_N "(cached) $ECHO_C" >&6
5700else
b61ff9c8
BS
5701 if test "$ac_cv_type_long" = yes; then
5702 # The cast to unsigned long works around a bug in the HP C Compiler
5703 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
5704 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
5705 # This bug is HP SR number 8606223364.
bf3b7cd3
JD
5706 if test "$cross_compiling" = yes; then
5707 # Depending upon the size, compute the lo and hi bounds.
5708cat >conftest.$ac_ext <<_ACEOF
5709/* confdefs.h. */
5710_ACEOF
5711cat confdefs.h >>conftest.$ac_ext
5712cat >>conftest.$ac_ext <<_ACEOF
5713/* end confdefs.h. */
5714$ac_includes_default
5715int
5716main ()
5717{
b61ff9c8 5718static int test_array [1 - 2 * !(((long) (sizeof (long))) >= 0)];
bf3b7cd3
JD
5719test_array [0] = 0
5720
5721 ;
5722 return 0;
5723}
5724_ACEOF
5725rm -f conftest.$ac_objext
b61ff9c8
BS
5726if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5727 (eval $ac_compile) 2>conftest.er1
bf3b7cd3
JD
5728 ac_status=$?
5729 grep -v '^ *+' conftest.er1 >conftest.err
5730 rm -f conftest.er1
5731 cat conftest.err >&5
5732 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
5733 (exit $ac_status); } &&
5734 { ac_try='test -z "$ac_c_werror_flag"
5735 || test ! -s conftest.err'
5736 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5737 (eval $ac_try) 2>&5
5738 ac_status=$?
5739 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5740 (exit $ac_status); }; } &&
5741 { ac_try='test -s conftest.$ac_objext'
5742 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5743 (eval $ac_try) 2>&5
5744 ac_status=$?
5745 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5746 (exit $ac_status); }; }; then
bf3b7cd3
JD
5747 ac_lo=0 ac_mid=0
5748 while :; do
5749 cat >conftest.$ac_ext <<_ACEOF
5750/* confdefs.h. */
5751_ACEOF
5752cat confdefs.h >>conftest.$ac_ext
5753cat >>conftest.$ac_ext <<_ACEOF
5754/* end confdefs.h. */
5755$ac_includes_default
5756int
5757main ()
5758{
b61ff9c8 5759static int test_array [1 - 2 * !(((long) (sizeof (long))) <= $ac_mid)];
bf3b7cd3
JD
5760test_array [0] = 0
5761
5762 ;
5763 return 0;
5764}
5765_ACEOF
5766rm -f conftest.$ac_objext
b61ff9c8
BS
5767if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5768 (eval $ac_compile) 2>conftest.er1
bf3b7cd3
JD
5769 ac_status=$?
5770 grep -v '^ *+' conftest.er1 >conftest.err
5771 rm -f conftest.er1
5772 cat conftest.err >&5
5773 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
5774 (exit $ac_status); } &&
5775 { ac_try='test -z "$ac_c_werror_flag"
5776 || test ! -s conftest.err'
5777 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5778 (eval $ac_try) 2>&5
5779 ac_status=$?
5780 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5781 (exit $ac_status); }; } &&
5782 { ac_try='test -s conftest.$ac_objext'
5783 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5784 (eval $ac_try) 2>&5
5785 ac_status=$?
5786 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5787 (exit $ac_status); }; }; then
bf3b7cd3
JD
5788 ac_hi=$ac_mid; break
5789else
5790 echo "$as_me: failed program was:" >&5
5791sed 's/^/| /' conftest.$ac_ext >&5
5792
b61ff9c8
BS
5793ac_lo=`expr $ac_mid + 1`
5794 if test $ac_lo -le $ac_mid; then
5795 ac_lo= ac_hi=
5796 break
5797 fi
5798 ac_mid=`expr 2 '*' $ac_mid + 1`
bf3b7cd3 5799fi
b61ff9c8 5800rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
bf3b7cd3
JD
5801 done
5802else
5803 echo "$as_me: failed program was:" >&5
5804sed 's/^/| /' conftest.$ac_ext >&5
5805
b61ff9c8 5806cat >conftest.$ac_ext <<_ACEOF
bf3b7cd3
JD
5807/* confdefs.h. */
5808_ACEOF
5809cat confdefs.h >>conftest.$ac_ext
5810cat >>conftest.$ac_ext <<_ACEOF
5811/* end confdefs.h. */
5812$ac_includes_default
5813int
5814main ()
5815{
b61ff9c8 5816static int test_array [1 - 2 * !(((long) (sizeof (long))) < 0)];
bf3b7cd3
JD
5817test_array [0] = 0
5818
5819 ;
5820 return 0;
5821}
5822_ACEOF
5823rm -f conftest.$ac_objext
b61ff9c8
BS
5824if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5825 (eval $ac_compile) 2>conftest.er1
bf3b7cd3
JD
5826 ac_status=$?
5827 grep -v '^ *+' conftest.er1 >conftest.err
5828 rm -f conftest.er1
5829 cat conftest.err >&5
5830 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
5831 (exit $ac_status); } &&
5832 { ac_try='test -z "$ac_c_werror_flag"
5833 || test ! -s conftest.err'
5834 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5835 (eval $ac_try) 2>&5
5836 ac_status=$?
5837 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5838 (exit $ac_status); }; } &&
5839 { ac_try='test -s conftest.$ac_objext'
5840 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5841 (eval $ac_try) 2>&5
5842 ac_status=$?
5843 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5844 (exit $ac_status); }; }; then
bf3b7cd3
JD
5845 ac_hi=-1 ac_mid=-1
5846 while :; do
5847 cat >conftest.$ac_ext <<_ACEOF
5848/* confdefs.h. */
5849_ACEOF
5850cat confdefs.h >>conftest.$ac_ext
5851cat >>conftest.$ac_ext <<_ACEOF
5852/* end confdefs.h. */
5853$ac_includes_default
5854int
5855main ()
5856{
b61ff9c8 5857static int test_array [1 - 2 * !(((long) (sizeof (long))) >= $ac_mid)];
bf3b7cd3
JD
5858test_array [0] = 0
5859
5860 ;
5861 return 0;
5862}
5863_ACEOF
5864rm -f conftest.$ac_objext
b61ff9c8
BS
5865if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5866 (eval $ac_compile) 2>conftest.er1
bf3b7cd3
JD
5867 ac_status=$?
5868 grep -v '^ *+' conftest.er1 >conftest.err
5869 rm -f conftest.er1
5870 cat conftest.err >&5
5871 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
5872 (exit $ac_status); } &&
5873 { ac_try='test -z "$ac_c_werror_flag"
5874 || test ! -s conftest.err'
5875 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5876 (eval $ac_try) 2>&5
5877 ac_status=$?
5878 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5879 (exit $ac_status); }; } &&
5880 { ac_try='test -s conftest.$ac_objext'
5881 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5882 (eval $ac_try) 2>&5
5883 ac_status=$?
5884 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5885 (exit $ac_status); }; }; then
bf3b7cd3
JD
5886 ac_lo=$ac_mid; break
5887else
5888 echo "$as_me: failed program was:" >&5
5889sed 's/^/| /' conftest.$ac_ext >&5
5890
b61ff9c8
BS
5891ac_hi=`expr '(' $ac_mid ')' - 1`
5892 if test $ac_mid -le $ac_hi; then
5893 ac_lo= ac_hi=
5894 break
5895 fi
5896 ac_mid=`expr 2 '*' $ac_mid`
bf3b7cd3 5897fi
b61ff9c8 5898rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
bf3b7cd3
JD
5899 done
5900else
5901 echo "$as_me: failed program was:" >&5
5902sed 's/^/| /' conftest.$ac_ext >&5
5903
b61ff9c8 5904ac_lo= ac_hi=
bf3b7cd3 5905fi
b61ff9c8 5906rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
bf3b7cd3 5907fi
b61ff9c8 5908rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
bf3b7cd3
JD
5909# Binary search between lo and hi bounds.
5910while test "x$ac_lo" != "x$ac_hi"; do
5911 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
5912 cat >conftest.$ac_ext <<_ACEOF
5913/* confdefs.h. */
5914_ACEOF
5915cat confdefs.h >>conftest.$ac_ext
5916cat >>conftest.$ac_ext <<_ACEOF
5917/* end confdefs.h. */
5918$ac_includes_default
5919int
5920main ()
5921{
b61ff9c8 5922static int test_array [1 - 2 * !(((long) (sizeof (long))) <= $ac_mid)];
bf3b7cd3
JD
5923test_array [0] = 0
5924
5925 ;
5926 return 0;
5927}
5928_ACEOF
5929rm -f conftest.$ac_objext
b61ff9c8
BS
5930if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5931 (eval $ac_compile) 2>conftest.er1
bf3b7cd3
JD
5932 ac_status=$?
5933 grep -v '^ *+' conftest.er1 >conftest.err
5934 rm -f conftest.er1
5935 cat conftest.err >&5
5936 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
5937 (exit $ac_status); } &&
5938 { ac_try='test -z "$ac_c_werror_flag"
5939 || test ! -s conftest.err'
5940 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5941 (eval $ac_try) 2>&5
5942 ac_status=$?
5943 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5944 (exit $ac_status); }; } &&
5945 { ac_try='test -s conftest.$ac_objext'
5946 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5947 (eval $ac_try) 2>&5
5948 ac_status=$?
5949 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5950 (exit $ac_status); }; }; then
bf3b7cd3
JD
5951 ac_hi=$ac_mid
5952else
5953 echo "$as_me: failed program was:" >&5
5954sed 's/^/| /' conftest.$ac_ext >&5
5955
b61ff9c8 5956ac_lo=`expr '(' $ac_mid ')' + 1`
bf3b7cd3 5957fi
b61ff9c8 5958rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
bf3b7cd3
JD
5959done
5960case $ac_lo in
5961?*) ac_cv_sizeof_long=$ac_lo;;
18c04407
RW
5962'') { { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
5963echo "$as_me: error: in \`$ac_pwd':" >&2;}
5964{ { echo "$as_me:$LINENO: error: cannot compute sizeof (long), 77
bf3b7cd3 5965See \`config.log' for more details." >&5
b61ff9c8 5966echo "$as_me: error: cannot compute sizeof (long), 77
bf3b7cd3 5967See \`config.log' for more details." >&2;}
18c04407 5968 { (exit 1); exit 1; }; }; } ;;
bf3b7cd3 5969esac
b61ff9c8
BS
5970else
5971 if test "$cross_compiling" = yes; then
18c04407
RW
5972 { { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
5973echo "$as_me: error: in \`$ac_pwd':" >&2;}
5974{ { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
b61ff9c8
BS
5975See \`config.log' for more details." >&5
5976echo "$as_me: error: cannot run test program while cross compiling
5977See \`config.log' for more details." >&2;}
18c04407 5978 { (exit 1); exit 1; }; }; }
bf3b7cd3
JD
5979else
5980 cat >conftest.$ac_ext <<_ACEOF
5981/* confdefs.h. */
5982_ACEOF
5983cat confdefs.h >>conftest.$ac_ext
5984cat >>conftest.$ac_ext <<_ACEOF
5985/* end confdefs.h. */
5986$ac_includes_default
b61ff9c8
BS
5987long longval () { return (long) (sizeof (long)); }
5988unsigned long ulongval () { return (long) (sizeof (long)); }
bf3b7cd3
JD
5989#include <stdio.h>
5990#include <stdlib.h>
5991int
5992main ()
5993{
5994
5995 FILE *f = fopen ("conftest.val", "w");
5996 if (! f)
b61ff9c8
BS
5997 exit (1);
5998 if (((long) (sizeof (long))) < 0)
bf3b7cd3 5999 {
b61ff9c8
BS
6000 long i = longval ();
6001 if (i != ((long) (sizeof (long))))
6002 exit (1);
bf3b7cd3
JD
6003 fprintf (f, "%ld\n", i);
6004 }
6005 else
6006 {
b61ff9c8
BS
6007 unsigned long i = ulongval ();
6008 if (i != ((long) (sizeof (long))))
6009 exit (1);
bf3b7cd3
JD
6010 fprintf (f, "%lu\n", i);
6011 }
b61ff9c8 6012 exit (ferror (f) || fclose (f) != 0);
bf3b7cd3
JD
6013
6014 ;
6015 return 0;
6016}
6017_ACEOF
6018rm -f conftest$ac_exeext
b61ff9c8
BS
6019if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6020 (eval $ac_link) 2>&5
bf3b7cd3
JD
6021 ac_status=$?
6022 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6023 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
b61ff9c8
BS
6024 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6025 (eval $ac_try) 2>&5
bf3b7cd3
JD
6026 ac_status=$?
6027 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6028 (exit $ac_status); }; }; then
6029 ac_cv_sizeof_long=`cat conftest.val`
6030else
6031 echo "$as_me: program exited with status $ac_status" >&5
6032echo "$as_me: failed program was:" >&5
6033sed 's/^/| /' conftest.$ac_ext >&5
6034
6035( exit $ac_status )
18c04407
RW
6036{ { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
6037echo "$as_me: error: in \`$ac_pwd':" >&2;}
b61ff9c8 6038{ { echo "$as_me:$LINENO: error: cannot compute sizeof (long), 77
bf3b7cd3 6039See \`config.log' for more details." >&5
b61ff9c8 6040echo "$as_me: error: cannot compute sizeof (long), 77
bf3b7cd3 6041See \`config.log' for more details." >&2;}
18c04407 6042 { (exit 1); exit 1; }; }; }
b61ff9c8
BS
6043fi
6044rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
bf3b7cd3
JD
6045fi
6046fi
6047rm -f conftest.val
b61ff9c8
BS
6048else
6049 ac_cv_sizeof_long=0
bf3b7cd3 6050fi
b61ff9c8
BS
6051fi
6052echo "$as_me:$LINENO: result: $ac_cv_sizeof_long" >&5
6053echo "${ECHO_T}$ac_cv_sizeof_long" >&6
bf3b7cd3
JD
6054cat >>confdefs.h <<_ACEOF
6055#define SIZEOF_LONG $ac_cv_sizeof_long
6056_ACEOF
6057
6058
b61ff9c8
BS
6059echo "$as_me:$LINENO: checking for long long" >&5
6060echo $ECHO_N "checking for long long... $ECHO_C" >&6
5ec1c5e6
KC
6061if test "${ac_cv_type_long_long+set}" = set; then
6062 echo $ECHO_N "(cached) $ECHO_C" >&6
6063else
6064 cat >conftest.$ac_ext <<_ACEOF
6065/* confdefs.h. */
6066_ACEOF
6067cat confdefs.h >>conftest.$ac_ext
6068cat >>conftest.$ac_ext <<_ACEOF
6069/* end confdefs.h. */
6070$ac_includes_default
6071int
6072main ()
6073{
b61ff9c8 6074if ((long long *) 0)
5ec1c5e6 6075 return 0;
b61ff9c8 6076if (sizeof (long long))
5ec1c5e6
KC
6077 return 0;
6078 ;
6079 return 0;
6080}
6081_ACEOF
6082rm -f conftest.$ac_objext
b61ff9c8
BS
6083if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6084 (eval $ac_compile) 2>conftest.er1
5ec1c5e6
KC
6085 ac_status=$?
6086 grep -v '^ *+' conftest.er1 >conftest.err
6087 rm -f conftest.er1
6088 cat conftest.err >&5
6089 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
6090 (exit $ac_status); } &&
6091 { ac_try='test -z "$ac_c_werror_flag"
6092 || test ! -s conftest.err'
6093 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6094 (eval $ac_try) 2>&5
6095 ac_status=$?
6096 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6097 (exit $ac_status); }; } &&
6098 { ac_try='test -s conftest.$ac_objext'
6099 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6100 (eval $ac_try) 2>&5
6101 ac_status=$?
6102 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6103 (exit $ac_status); }; }; then
5ec1c5e6
KC
6104 ac_cv_type_long_long=yes
6105else
6106 echo "$as_me: failed program was:" >&5
6107sed 's/^/| /' conftest.$ac_ext >&5
6108
b61ff9c8 6109ac_cv_type_long_long=no
5ec1c5e6 6110fi
b61ff9c8 6111rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
5ec1c5e6 6112fi
b61ff9c8
BS
6113echo "$as_me:$LINENO: result: $ac_cv_type_long_long" >&5
6114echo "${ECHO_T}$ac_cv_type_long_long" >&6
5ec1c5e6
KC
6115if test $ac_cv_type_long_long = yes; then
6116
6117cat >>confdefs.h <<_ACEOF
6118#define HAVE_LONG_LONG 1
6119_ACEOF
6120
b61ff9c8
BS
6121echo "$as_me:$LINENO: checking for long long" >&5
6122echo $ECHO_N "checking for long long... $ECHO_C" >&6
bf3b7cd3
JD
6123if test "${ac_cv_type_long_long+set}" = set; then
6124 echo $ECHO_N "(cached) $ECHO_C" >&6
6125else
6126 cat >conftest.$ac_ext <<_ACEOF
6127/* confdefs.h. */
6128_ACEOF
6129cat confdefs.h >>conftest.$ac_ext
6130cat >>conftest.$ac_ext <<_ACEOF
6131/* end confdefs.h. */
6132$ac_includes_default
6133int
6134main ()
6135{
b61ff9c8 6136if ((long long *) 0)
bf3b7cd3 6137 return 0;
b61ff9c8 6138if (sizeof (long long))
bf3b7cd3
JD
6139 return 0;
6140 ;
6141 return 0;
6142}
6143_ACEOF
6144rm -f conftest.$ac_objext
b61ff9c8
BS
6145if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6146 (eval $ac_compile) 2>conftest.er1
bf3b7cd3
JD
6147 ac_status=$?
6148 grep -v '^ *+' conftest.er1 >conftest.err
6149 rm -f conftest.er1
6150 cat conftest.err >&5
6151 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
6152 (exit $ac_status); } &&
6153 { ac_try='test -z "$ac_c_werror_flag"
6154 || test ! -s conftest.err'
6155 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6156 (eval $ac_try) 2>&5
6157 ac_status=$?
6158 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6159 (exit $ac_status); }; } &&
6160 { ac_try='test -s conftest.$ac_objext'
6161 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6162 (eval $ac_try) 2>&5
6163 ac_status=$?
6164 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6165 (exit $ac_status); }; }; then
6166 ac_cv_type_long_long=yes
6167else
bf3b7cd3
JD
6168 echo "$as_me: failed program was:" >&5
6169sed 's/^/| /' conftest.$ac_ext >&5
6170
b61ff9c8 6171ac_cv_type_long_long=no
bf3b7cd3 6172fi
b61ff9c8 6173rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
bf3b7cd3 6174fi
b61ff9c8
BS
6175echo "$as_me:$LINENO: result: $ac_cv_type_long_long" >&5
6176echo "${ECHO_T}$ac_cv_type_long_long" >&6
bf3b7cd3 6177
b61ff9c8
BS
6178echo "$as_me:$LINENO: checking size of long long" >&5
6179echo $ECHO_N "checking size of long long... $ECHO_C" >&6
bf3b7cd3
JD
6180if test "${ac_cv_sizeof_long_long+set}" = set; then
6181 echo $ECHO_N "(cached) $ECHO_C" >&6
6182else
b61ff9c8
BS
6183 if test "$ac_cv_type_long_long" = yes; then
6184 # The cast to unsigned long works around a bug in the HP C Compiler
6185 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
6186 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
6187 # This bug is HP SR number 8606223364.
bf3b7cd3
JD
6188 if test "$cross_compiling" = yes; then
6189 # Depending upon the size, compute the lo and hi bounds.
6190cat >conftest.$ac_ext <<_ACEOF
6191/* confdefs.h. */
6192_ACEOF
6193cat confdefs.h >>conftest.$ac_ext
6194cat >>conftest.$ac_ext <<_ACEOF
6195/* end confdefs.h. */
6196$ac_includes_default
6197int
6198main ()
6199{
b61ff9c8 6200static int test_array [1 - 2 * !(((long) (sizeof (long long))) >= 0)];
bf3b7cd3
JD
6201test_array [0] = 0
6202
6203 ;
6204 return 0;
6205}
6206_ACEOF
6207rm -f conftest.$ac_objext
b61ff9c8
BS
6208if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6209 (eval $ac_compile) 2>conftest.er1
bf3b7cd3
JD
6210 ac_status=$?
6211 grep -v '^ *+' conftest.er1 >conftest.err
6212 rm -f conftest.er1
6213 cat conftest.err >&5
6214 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
6215 (exit $ac_status); } &&
6216 { ac_try='test -z "$ac_c_werror_flag"
6217 || test ! -s conftest.err'
6218 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6219 (eval $ac_try) 2>&5
6220 ac_status=$?
6221 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6222 (exit $ac_status); }; } &&
6223 { ac_try='test -s conftest.$ac_objext'
6224 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6225 (eval $ac_try) 2>&5
6226 ac_status=$?
6227 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6228 (exit $ac_status); }; }; then
bf3b7cd3
JD
6229 ac_lo=0 ac_mid=0
6230 while :; do
6231 cat >conftest.$ac_ext <<_ACEOF
6232/* confdefs.h. */
6233_ACEOF
6234cat confdefs.h >>conftest.$ac_ext
6235cat >>conftest.$ac_ext <<_ACEOF
6236/* end confdefs.h. */
6237$ac_includes_default
6238int
6239main ()
6240{
b61ff9c8 6241static int test_array [1 - 2 * !(((long) (sizeof (long long))) <= $ac_mid)];
bf3b7cd3
JD
6242test_array [0] = 0
6243
6244 ;
6245 return 0;
6246}
6247_ACEOF
6248rm -f conftest.$ac_objext
b61ff9c8
BS
6249if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6250 (eval $ac_compile) 2>conftest.er1
bf3b7cd3
JD
6251 ac_status=$?
6252 grep -v '^ *+' conftest.er1 >conftest.err
6253 rm -f conftest.er1
6254 cat conftest.err >&5
6255 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
6256 (exit $ac_status); } &&
6257 { ac_try='test -z "$ac_c_werror_flag"
6258 || test ! -s conftest.err'
6259 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6260 (eval $ac_try) 2>&5
6261 ac_status=$?
6262 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6263 (exit $ac_status); }; } &&
6264 { ac_try='test -s conftest.$ac_objext'
6265 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6266 (eval $ac_try) 2>&5
6267 ac_status=$?
6268 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6269 (exit $ac_status); }; }; then
8b1f719a 6270 ac_hi=$ac_mid; break
bf3b7cd3
JD
6271else
6272 echo "$as_me: failed program was:" >&5
6273sed 's/^/| /' conftest.$ac_ext >&5
6274
b61ff9c8
BS
6275ac_lo=`expr $ac_mid + 1`
6276 if test $ac_lo -le $ac_mid; then
6277 ac_lo= ac_hi=
6278 break
6279 fi
6280 ac_mid=`expr 2 '*' $ac_mid + 1`
8b1f719a 6281fi
b61ff9c8 6282rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8b1f719a
PB
6283 done
6284else
6285 echo "$as_me: failed program was:" >&5
6286sed 's/^/| /' conftest.$ac_ext >&5
6287
b61ff9c8 6288cat >conftest.$ac_ext <<_ACEOF
bf3b7cd3
JD
6289/* confdefs.h. */
6290_ACEOF
6291cat confdefs.h >>conftest.$ac_ext
6292cat >>conftest.$ac_ext <<_ACEOF
6293/* end confdefs.h. */
6294$ac_includes_default
6295int
6296main ()
6297{
b61ff9c8 6298static int test_array [1 - 2 * !(((long) (sizeof (long long))) < 0)];
bf3b7cd3
JD
6299test_array [0] = 0
6300
6301 ;
6302 return 0;
6303}
6304_ACEOF
6305rm -f conftest.$ac_objext
b61ff9c8
BS
6306if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6307 (eval $ac_compile) 2>conftest.er1
bf3b7cd3
JD
6308 ac_status=$?
6309 grep -v '^ *+' conftest.er1 >conftest.err
6310 rm -f conftest.er1
6311 cat conftest.err >&5
6312 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
6313 (exit $ac_status); } &&
6314 { ac_try='test -z "$ac_c_werror_flag"
6315 || test ! -s conftest.err'
6316 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6317 (eval $ac_try) 2>&5
6318 ac_status=$?
6319 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6320 (exit $ac_status); }; } &&
6321 { ac_try='test -s conftest.$ac_objext'
6322 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6323 (eval $ac_try) 2>&5
6324 ac_status=$?
6325 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6326 (exit $ac_status); }; }; then
bf3b7cd3
JD
6327 ac_hi=-1 ac_mid=-1
6328 while :; do
6329 cat >conftest.$ac_ext <<_ACEOF
6330/* confdefs.h. */
6331_ACEOF
6332cat confdefs.h >>conftest.$ac_ext
6333cat >>conftest.$ac_ext <<_ACEOF
6334/* end confdefs.h. */
6335$ac_includes_default
6336int
6337main ()
6338{
b61ff9c8 6339static int test_array [1 - 2 * !(((long) (sizeof (long long))) >= $ac_mid)];
bf3b7cd3
JD
6340test_array [0] = 0
6341
6342 ;
6343 return 0;
6344}
6345_ACEOF
6346rm -f conftest.$ac_objext
b61ff9c8
BS
6347if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6348 (eval $ac_compile) 2>conftest.er1
bf3b7cd3
JD
6349 ac_status=$?
6350 grep -v '^ *+' conftest.er1 >conftest.err
6351 rm -f conftest.er1
6352 cat conftest.err >&5
6353 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
6354 (exit $ac_status); } &&
6355 { ac_try='test -z "$ac_c_werror_flag"
6356 || test ! -s conftest.err'
6357 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6358 (eval $ac_try) 2>&5
6359 ac_status=$?
6360 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6361 (exit $ac_status); }; } &&
6362 { ac_try='test -s conftest.$ac_objext'
6363 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6364 (eval $ac_try) 2>&5
6365 ac_status=$?
6366 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6367 (exit $ac_status); }; }; then
bf3b7cd3
JD
6368 ac_lo=$ac_mid; break
6369else
6370 echo "$as_me: failed program was:" >&5
6371sed 's/^/| /' conftest.$ac_ext >&5
6372
b61ff9c8
BS
6373ac_hi=`expr '(' $ac_mid ')' - 1`
6374 if test $ac_mid -le $ac_hi; then
6375 ac_lo= ac_hi=
6376 break
6377 fi
6378 ac_mid=`expr 2 '*' $ac_mid`
bf3b7cd3 6379fi
b61ff9c8 6380rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
bf3b7cd3
JD
6381 done
6382else
6383 echo "$as_me: failed program was:" >&5
6384sed 's/^/| /' conftest.$ac_ext >&5
6385
b61ff9c8 6386ac_lo= ac_hi=
bf3b7cd3 6387fi
b61ff9c8 6388rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
bf3b7cd3 6389fi
b61ff9c8 6390rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
bf3b7cd3
JD
6391# Binary search between lo and hi bounds.
6392while test "x$ac_lo" != "x$ac_hi"; do
6393 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
6394 cat >conftest.$ac_ext <<_ACEOF
6395/* confdefs.h. */
6396_ACEOF
6397cat confdefs.h >>conftest.$ac_ext
6398cat >>conftest.$ac_ext <<_ACEOF
6399/* end confdefs.h. */
6400$ac_includes_default
6401int
6402main ()
6403{
b61ff9c8 6404static int test_array [1 - 2 * !(((long) (sizeof (long long))) <= $ac_mid)];
bf3b7cd3
JD
6405test_array [0] = 0
6406
6407 ;
6408 return 0;
6409}
6410_ACEOF
6411rm -f conftest.$ac_objext
b61ff9c8
BS
6412if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6413 (eval $ac_compile) 2>conftest.er1
bf3b7cd3
JD
6414 ac_status=$?
6415 grep -v '^ *+' conftest.er1 >conftest.err
6416 rm -f conftest.er1
6417 cat conftest.err >&5
6418 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
6419 (exit $ac_status); } &&
6420 { ac_try='test -z "$ac_c_werror_flag"
6421 || test ! -s conftest.err'
6422 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6423 (eval $ac_try) 2>&5
6424 ac_status=$?
6425 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6426 (exit $ac_status); }; } &&
6427 { ac_try='test -s conftest.$ac_objext'
6428 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6429 (eval $ac_try) 2>&5
6430 ac_status=$?
6431 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6432 (exit $ac_status); }; }; then
bf3b7cd3
JD
6433 ac_hi=$ac_mid
6434else
6435 echo "$as_me: failed program was:" >&5
6436sed 's/^/| /' conftest.$ac_ext >&5
6437
b61ff9c8 6438ac_lo=`expr '(' $ac_mid ')' + 1`
bf3b7cd3 6439fi
b61ff9c8 6440rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
bf3b7cd3
JD
6441done
6442case $ac_lo in
6443?*) ac_cv_sizeof_long_long=$ac_lo;;
18c04407
RW
6444'') { { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
6445echo "$as_me: error: in \`$ac_pwd':" >&2;}
6446{ { echo "$as_me:$LINENO: error: cannot compute sizeof (long long), 77
bf3b7cd3 6447See \`config.log' for more details." >&5
b61ff9c8 6448echo "$as_me: error: cannot compute sizeof (long long), 77
bf3b7cd3 6449See \`config.log' for more details." >&2;}
18c04407 6450 { (exit 1); exit 1; }; }; } ;;
bf3b7cd3 6451esac
b61ff9c8
BS
6452else
6453 if test "$cross_compiling" = yes; then
18c04407
RW
6454 { { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
6455echo "$as_me: error: in \`$ac_pwd':" >&2;}
6456{ { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
b61ff9c8
BS
6457See \`config.log' for more details." >&5
6458echo "$as_me: error: cannot run test program while cross compiling
6459See \`config.log' for more details." >&2;}
18c04407 6460 { (exit 1); exit 1; }; }; }
bf3b7cd3
JD
6461else
6462 cat >conftest.$ac_ext <<_ACEOF
6463/* confdefs.h. */
6464_ACEOF
6465cat confdefs.h >>conftest.$ac_ext
6466cat >>conftest.$ac_ext <<_ACEOF
6467/* end confdefs.h. */
6468$ac_includes_default
b61ff9c8
BS
6469long longval () { return (long) (sizeof (long long)); }
6470unsigned long ulongval () { return (long) (sizeof (long long)); }
bf3b7cd3
JD
6471#include <stdio.h>
6472#include <stdlib.h>
6473int
6474main ()
6475{
6476
6477 FILE *f = fopen ("conftest.val", "w");
6478 if (! f)
b61ff9c8
BS
6479 exit (1);
6480 if (((long) (sizeof (long long))) < 0)
bf3b7cd3 6481 {
b61ff9c8
BS
6482 long i = longval ();
6483 if (i != ((long) (sizeof (long long))))
6484 exit (1);
bf3b7cd3
JD
6485 fprintf (f, "%ld\n", i);
6486 }
6487 else
6488 {
b61ff9c8
BS
6489 unsigned long i = ulongval ();
6490 if (i != ((long) (sizeof (long long))))
6491 exit (1);
bf3b7cd3
JD
6492 fprintf (f, "%lu\n", i);
6493 }
b61ff9c8 6494 exit (ferror (f) || fclose (f) != 0);
bf3b7cd3
JD
6495
6496 ;
6497 return 0;
6498}
6499_ACEOF
6500rm -f conftest$ac_exeext
b61ff9c8
BS
6501if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6502 (eval $ac_link) 2>&5
bf3b7cd3
JD
6503 ac_status=$?
6504 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6505 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
b61ff9c8
BS
6506 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6507 (eval $ac_try) 2>&5
bf3b7cd3
JD
6508 ac_status=$?
6509 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6510 (exit $ac_status); }; }; then
6511 ac_cv_sizeof_long_long=`cat conftest.val`
6512else
6513 echo "$as_me: program exited with status $ac_status" >&5
6514echo "$as_me: failed program was:" >&5
6515sed 's/^/| /' conftest.$ac_ext >&5
6516
6517( exit $ac_status )
18c04407
RW
6518{ { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
6519echo "$as_me: error: in \`$ac_pwd':" >&2;}
b61ff9c8 6520{ { echo "$as_me:$LINENO: error: cannot compute sizeof (long long), 77
bf3b7cd3 6521See \`config.log' for more details." >&5
b61ff9c8 6522echo "$as_me: error: cannot compute sizeof (long long), 77
bf3b7cd3 6523See \`config.log' for more details." >&2;}
18c04407 6524 { (exit 1); exit 1; }; }; }
b61ff9c8
BS
6525fi
6526rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
bf3b7cd3
JD
6527fi
6528fi
6529rm -f conftest.val
b61ff9c8
BS
6530else
6531 ac_cv_sizeof_long_long=0
2f41c1d6 6532fi
b61ff9c8
BS
6533fi
6534echo "$as_me:$LINENO: result: $ac_cv_sizeof_long_long" >&5
6535echo "${ECHO_T}$ac_cv_sizeof_long_long" >&6
bf3b7cd3
JD
6536cat >>confdefs.h <<_ACEOF
6537#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
6538_ACEOF
6539
6540
6541fi
5ec1c5e6 6542
b61ff9c8
BS
6543echo "$as_me:$LINENO: checking for __int64" >&5
6544echo $ECHO_N "checking for __int64... $ECHO_C" >&6
5ec1c5e6
KC
6545if test "${ac_cv_type___int64+set}" = set; then
6546 echo $ECHO_N "(cached) $ECHO_C" >&6
6547else
6548 cat >conftest.$ac_ext <<_ACEOF
6549/* confdefs.h. */
6550_ACEOF
6551cat confdefs.h >>conftest.$ac_ext
6552cat >>conftest.$ac_ext <<_ACEOF
6553/* end confdefs.h. */
6554$ac_includes_default
6555int
6556main ()
6557{
b61ff9c8 6558if ((__int64 *) 0)
5ec1c5e6 6559 return 0;
b61ff9c8 6560if (sizeof (__int64))
5ec1c5e6
KC
6561 return 0;
6562 ;
6563 return 0;
6564}
6565_ACEOF
6566rm -f conftest.$ac_objext
b61ff9c8
BS
6567if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6568 (eval $ac_compile) 2>conftest.er1
5ec1c5e6
KC
6569 ac_status=$?
6570 grep -v '^ *+' conftest.er1 >conftest.err
6571 rm -f conftest.er1
6572 cat conftest.err >&5
6573 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
6574 (exit $ac_status); } &&
6575 { ac_try='test -z "$ac_c_werror_flag"
6576 || test ! -s conftest.err'
6577 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6578 (eval $ac_try) 2>&5
6579 ac_status=$?
6580 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6581 (exit $ac_status); }; } &&
6582 { ac_try='test -s conftest.$ac_objext'
6583 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6584 (eval $ac_try) 2>&5
6585 ac_status=$?
6586 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6587 (exit $ac_status); }; }; then
5ec1c5e6
KC
6588 ac_cv_type___int64=yes
6589else
6590 echo "$as_me: failed program was:" >&5
6591sed 's/^/| /' conftest.$ac_ext >&5
6592
b61ff9c8 6593ac_cv_type___int64=no
5ec1c5e6 6594fi
b61ff9c8 6595rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
5ec1c5e6 6596fi
b61ff9c8
BS
6597echo "$as_me:$LINENO: result: $ac_cv_type___int64" >&5
6598echo "${ECHO_T}$ac_cv_type___int64" >&6
5ec1c5e6
KC
6599if test $ac_cv_type___int64 = yes; then
6600
6601cat >>confdefs.h <<_ACEOF
6602#define HAVE___INT64 1
6603_ACEOF
6604
b61ff9c8
BS
6605echo "$as_me:$LINENO: checking for __int64" >&5
6606echo $ECHO_N "checking for __int64... $ECHO_C" >&6
bf3b7cd3
JD
6607if test "${ac_cv_type___int64+set}" = set; then
6608 echo $ECHO_N "(cached) $ECHO_C" >&6
6609else
ba479fd2 6610 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
6611/* confdefs.h. */
6612_ACEOF
6613cat confdefs.h >>conftest.$ac_ext
6614cat >>conftest.$ac_ext <<_ACEOF
6615/* end confdefs.h. */
bf3b7cd3 6616$ac_includes_default
ba479fd2
NN
6617int
6618main ()
6619{
b61ff9c8 6620if ((__int64 *) 0)
bf3b7cd3 6621 return 0;
b61ff9c8 6622if (sizeof (__int64))
bf3b7cd3 6623 return 0;
ba479fd2
NN
6624 ;
6625 return 0;
6626}
6627_ACEOF
6628rm -f conftest.$ac_objext
b61ff9c8
BS
6629if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6630 (eval $ac_compile) 2>conftest.er1
ba479fd2 6631 ac_status=$?
86da66b5
HPN
6632 grep -v '^ *+' conftest.er1 >conftest.err
6633 rm -f conftest.er1
6634 cat conftest.err >&5
ba479fd2 6635 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
6636 (exit $ac_status); } &&
6637 { ac_try='test -z "$ac_c_werror_flag"
6638 || test ! -s conftest.err'
6639 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6640 (eval $ac_try) 2>&5
6641 ac_status=$?
6642 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6643 (exit $ac_status); }; } &&
6644 { ac_try='test -s conftest.$ac_objext'
6645 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6646 (eval $ac_try) 2>&5
6647 ac_status=$?
6648 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6649 (exit $ac_status); }; }; then
bf3b7cd3 6650 ac_cv_type___int64=yes
75b6f3fd 6651else
ba479fd2
NN
6652 echo "$as_me: failed program was:" >&5
6653sed 's/^/| /' conftest.$ac_ext >&5
6654
b61ff9c8 6655ac_cv_type___int64=no
75b6f3fd 6656fi
b61ff9c8 6657rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
75b6f3fd 6658fi
b61ff9c8
BS
6659echo "$as_me:$LINENO: result: $ac_cv_type___int64" >&5
6660echo "${ECHO_T}$ac_cv_type___int64" >&6
75b6f3fd 6661
b61ff9c8
BS
6662echo "$as_me:$LINENO: checking size of __int64" >&5
6663echo $ECHO_N "checking size of __int64... $ECHO_C" >&6
bf3b7cd3 6664if test "${ac_cv_sizeof___int64+set}" = set; then
ba479fd2 6665 echo $ECHO_N "(cached) $ECHO_C" >&6
414d23ae 6666else
b61ff9c8
BS
6667 if test "$ac_cv_type___int64" = yes; then
6668 # The cast to unsigned long works around a bug in the HP C Compiler
6669 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
6670 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
6671 # This bug is HP SR number 8606223364.
bf3b7cd3
JD
6672 if test "$cross_compiling" = yes; then
6673 # Depending upon the size, compute the lo and hi bounds.
6674cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
6675/* confdefs.h. */
6676_ACEOF
6677cat confdefs.h >>conftest.$ac_ext
6678cat >>conftest.$ac_ext <<_ACEOF
6679/* end confdefs.h. */
bf3b7cd3 6680$ac_includes_default
ba479fd2
NN
6681int
6682main ()
6683{
b61ff9c8 6684static int test_array [1 - 2 * !(((long) (sizeof (__int64))) >= 0)];
bf3b7cd3
JD
6685test_array [0] = 0
6686
ba479fd2
NN
6687 ;
6688 return 0;
6689}
6690_ACEOF
6691rm -f conftest.$ac_objext
b61ff9c8
BS
6692if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6693 (eval $ac_compile) 2>conftest.er1
ba479fd2 6694 ac_status=$?
86da66b5
HPN
6695 grep -v '^ *+' conftest.er1 >conftest.err
6696 rm -f conftest.er1
6697 cat conftest.err >&5
ba479fd2 6698 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
6699 (exit $ac_status); } &&
6700 { ac_try='test -z "$ac_c_werror_flag"
6701 || test ! -s conftest.err'
6702 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6703 (eval $ac_try) 2>&5
6704 ac_status=$?
6705 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6706 (exit $ac_status); }; } &&
6707 { ac_try='test -s conftest.$ac_objext'
6708 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6709 (eval $ac_try) 2>&5
6710 ac_status=$?
6711 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6712 (exit $ac_status); }; }; then
bf3b7cd3
JD
6713 ac_lo=0 ac_mid=0
6714 while :; do
6715 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
6716/* confdefs.h. */
6717_ACEOF
6718cat confdefs.h >>conftest.$ac_ext
6719cat >>conftest.$ac_ext <<_ACEOF
6720/* end confdefs.h. */
bf3b7cd3 6721$ac_includes_default
ba479fd2
NN
6722int
6723main ()
6724{
b61ff9c8 6725static int test_array [1 - 2 * !(((long) (sizeof (__int64))) <= $ac_mid)];
bf3b7cd3
JD
6726test_array [0] = 0
6727
ba479fd2
NN
6728 ;
6729 return 0;
6730}
6731_ACEOF
6732rm -f conftest.$ac_objext
b61ff9c8
BS
6733if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6734 (eval $ac_compile) 2>conftest.er1
ba479fd2 6735 ac_status=$?
86da66b5
HPN
6736 grep -v '^ *+' conftest.er1 >conftest.err
6737 rm -f conftest.er1
6738 cat conftest.err >&5
ba479fd2 6739 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
6740 (exit $ac_status); } &&
6741 { ac_try='test -z "$ac_c_werror_flag"
6742 || test ! -s conftest.err'
6743 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6744 (eval $ac_try) 2>&5
6745 ac_status=$?
6746 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6747 (exit $ac_status); }; } &&
6748 { ac_try='test -s conftest.$ac_objext'
6749 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6750 (eval $ac_try) 2>&5
6751 ac_status=$?
6752 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6753 (exit $ac_status); }; }; then
bf3b7cd3 6754 ac_hi=$ac_mid; break
75e93faa 6755else
ba479fd2
NN
6756 echo "$as_me: failed program was:" >&5
6757sed 's/^/| /' conftest.$ac_ext >&5
6758
b61ff9c8
BS
6759ac_lo=`expr $ac_mid + 1`
6760 if test $ac_lo -le $ac_mid; then
6761 ac_lo= ac_hi=
6762 break
6763 fi
6764 ac_mid=`expr 2 '*' $ac_mid + 1`
75e93faa 6765fi
b61ff9c8 6766rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
bf3b7cd3 6767 done
75e93faa 6768else
bf3b7cd3
JD
6769 echo "$as_me: failed program was:" >&5
6770sed 's/^/| /' conftest.$ac_ext >&5
6771
b61ff9c8 6772cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
6773/* confdefs.h. */
6774_ACEOF
6775cat confdefs.h >>conftest.$ac_ext
6776cat >>conftest.$ac_ext <<_ACEOF
6777/* end confdefs.h. */
bf3b7cd3 6778$ac_includes_default
ba479fd2
NN
6779int
6780main ()
6781{
b61ff9c8 6782static int test_array [1 - 2 * !(((long) (sizeof (__int64))) < 0)];
bf3b7cd3
JD
6783test_array [0] = 0
6784
ba479fd2
NN
6785 ;
6786 return 0;
6787}
6788_ACEOF
6789rm -f conftest.$ac_objext
b61ff9c8
BS
6790if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6791 (eval $ac_compile) 2>conftest.er1
ba479fd2 6792 ac_status=$?
86da66b5
HPN
6793 grep -v '^ *+' conftest.er1 >conftest.err
6794 rm -f conftest.er1
6795 cat conftest.err >&5
ba479fd2 6796 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
6797 (exit $ac_status); } &&
6798 { ac_try='test -z "$ac_c_werror_flag"
6799 || test ! -s conftest.err'
6800 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6801 (eval $ac_try) 2>&5
6802 ac_status=$?
6803 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6804 (exit $ac_status); }; } &&
6805 { ac_try='test -s conftest.$ac_objext'
6806 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6807 (eval $ac_try) 2>&5
6808 ac_status=$?
6809 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6810 (exit $ac_status); }; }; then
bf3b7cd3
JD
6811 ac_hi=-1 ac_mid=-1
6812 while :; do
6813 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
6814/* confdefs.h. */
6815_ACEOF
6816cat confdefs.h >>conftest.$ac_ext
6817cat >>conftest.$ac_ext <<_ACEOF
6818/* end confdefs.h. */
bf3b7cd3 6819$ac_includes_default
ba479fd2
NN
6820int
6821main ()
6822{
b61ff9c8 6823static int test_array [1 - 2 * !(((long) (sizeof (__int64))) >= $ac_mid)];
bf3b7cd3
JD
6824test_array [0] = 0
6825
ba479fd2
NN
6826 ;
6827 return 0;
6828}
6829_ACEOF
6830rm -f conftest.$ac_objext
b61ff9c8
BS
6831if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6832 (eval $ac_compile) 2>conftest.er1
ba479fd2 6833 ac_status=$?
86da66b5
HPN
6834 grep -v '^ *+' conftest.er1 >conftest.err
6835 rm -f conftest.er1
6836 cat conftest.err >&5
ba479fd2 6837 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
6838 (exit $ac_status); } &&
6839 { ac_try='test -z "$ac_c_werror_flag"
6840 || test ! -s conftest.err'
6841 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6842 (eval $ac_try) 2>&5
6843 ac_status=$?
6844 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6845 (exit $ac_status); }; } &&
6846 { ac_try='test -s conftest.$ac_objext'
6847 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6848 (eval $ac_try) 2>&5
6849 ac_status=$?
6850 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6851 (exit $ac_status); }; }; then
bf3b7cd3 6852 ac_lo=$ac_mid; break
04cabffc 6853else
ba479fd2
NN
6854 echo "$as_me: failed program was:" >&5
6855sed 's/^/| /' conftest.$ac_ext >&5
6856
b61ff9c8
BS
6857ac_hi=`expr '(' $ac_mid ')' - 1`
6858 if test $ac_mid -le $ac_hi; then
6859 ac_lo= ac_hi=
6860 break
6861 fi
6862 ac_mid=`expr 2 '*' $ac_mid`
04cabffc 6863fi
b61ff9c8 6864rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
bf3b7cd3
JD
6865 done
6866else
6867 echo "$as_me: failed program was:" >&5
6868sed 's/^/| /' conftest.$ac_ext >&5
04cabffc 6869
b61ff9c8 6870ac_lo= ac_hi=
414d23ae 6871fi
b61ff9c8 6872rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
414d23ae 6873fi
b61ff9c8 6874rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
bf3b7cd3
JD
6875# Binary search between lo and hi bounds.
6876while test "x$ac_lo" != "x$ac_hi"; do
6877 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
ba479fd2 6878 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
6879/* confdefs.h. */
6880_ACEOF
6881cat confdefs.h >>conftest.$ac_ext
6882cat >>conftest.$ac_ext <<_ACEOF
6883/* end confdefs.h. */
bf3b7cd3 6884$ac_includes_default
ba479fd2
NN
6885int
6886main ()
6887{
b61ff9c8 6888static int test_array [1 - 2 * !(((long) (sizeof (__int64))) <= $ac_mid)];
bf3b7cd3
JD
6889test_array [0] = 0
6890
ba479fd2
NN
6891 ;
6892 return 0;
6893}
6894_ACEOF
6895rm -f conftest.$ac_objext
b61ff9c8
BS
6896if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6897 (eval $ac_compile) 2>conftest.er1
ba479fd2 6898 ac_status=$?
86da66b5
HPN
6899 grep -v '^ *+' conftest.er1 >conftest.err
6900 rm -f conftest.er1
6901 cat conftest.err >&5
ba479fd2 6902 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
6903 (exit $ac_status); } &&
6904 { ac_try='test -z "$ac_c_werror_flag"
6905 || test ! -s conftest.err'
6906 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6907 (eval $ac_try) 2>&5
6908 ac_status=$?
6909 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6910 (exit $ac_status); }; } &&
6911 { ac_try='test -s conftest.$ac_objext'
6912 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6913 (eval $ac_try) 2>&5
6914 ac_status=$?
6915 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6916 (exit $ac_status); }; }; then
bf3b7cd3 6917 ac_hi=$ac_mid
75e93faa 6918else
ba479fd2
NN
6919 echo "$as_me: failed program was:" >&5
6920sed 's/^/| /' conftest.$ac_ext >&5
6921
b61ff9c8 6922ac_lo=`expr '(' $ac_mid ')' + 1`
75e93faa 6923fi
b61ff9c8 6924rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
414d23ae 6925done
bf3b7cd3
JD
6926case $ac_lo in
6927?*) ac_cv_sizeof___int64=$ac_lo;;
18c04407
RW
6928'') { { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
6929echo "$as_me: error: in \`$ac_pwd':" >&2;}
6930{ { echo "$as_me:$LINENO: error: cannot compute sizeof (__int64), 77
bf3b7cd3 6931See \`config.log' for more details." >&5
b61ff9c8 6932echo "$as_me: error: cannot compute sizeof (__int64), 77
bf3b7cd3 6933See \`config.log' for more details." >&2;}
18c04407 6934 { (exit 1); exit 1; }; }; } ;;
bf3b7cd3 6935esac
b61ff9c8
BS
6936else
6937 if test "$cross_compiling" = yes; then
18c04407
RW
6938 { { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
6939echo "$as_me: error: in \`$ac_pwd':" >&2;}
6940{ { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
b61ff9c8
BS
6941See \`config.log' for more details." >&5
6942echo "$as_me: error: cannot run test program while cross compiling
6943See \`config.log' for more details." >&2;}
18c04407 6944 { (exit 1); exit 1; }; }; }
bf3b7cd3
JD
6945else
6946 cat >conftest.$ac_ext <<_ACEOF
6947/* confdefs.h. */
6948_ACEOF
6949cat confdefs.h >>conftest.$ac_ext
6950cat >>conftest.$ac_ext <<_ACEOF
6951/* end confdefs.h. */
6952$ac_includes_default
b61ff9c8
BS
6953long longval () { return (long) (sizeof (__int64)); }
6954unsigned long ulongval () { return (long) (sizeof (__int64)); }
bf3b7cd3
JD
6955#include <stdio.h>
6956#include <stdlib.h>
6957int
6958main ()
6959{
414d23ae 6960
bf3b7cd3
JD
6961 FILE *f = fopen ("conftest.val", "w");
6962 if (! f)
b61ff9c8
BS
6963 exit (1);
6964 if (((long) (sizeof (__int64))) < 0)
bf3b7cd3 6965 {
b61ff9c8
BS
6966 long i = longval ();
6967 if (i != ((long) (sizeof (__int64))))
6968 exit (1);
bf3b7cd3
JD
6969 fprintf (f, "%ld\n", i);
6970 }
6971 else
6972 {
b61ff9c8
BS
6973 unsigned long i = ulongval ();
6974 if (i != ((long) (sizeof (__int64))))
6975 exit (1);
bf3b7cd3
JD
6976 fprintf (f, "%lu\n", i);
6977 }
b61ff9c8 6978 exit (ferror (f) || fclose (f) != 0);
bf3b7cd3
JD
6979
6980 ;
6981 return 0;
6982}
6983_ACEOF
6984rm -f conftest$ac_exeext
b61ff9c8
BS
6985if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6986 (eval $ac_link) 2>&5
bf3b7cd3
JD
6987 ac_status=$?
6988 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6989 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
b61ff9c8
BS
6990 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6991 (eval $ac_try) 2>&5
bf3b7cd3
JD
6992 ac_status=$?
6993 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6994 (exit $ac_status); }; }; then
6995 ac_cv_sizeof___int64=`cat conftest.val`
6996else
6997 echo "$as_me: program exited with status $ac_status" >&5
6998echo "$as_me: failed program was:" >&5
6999sed 's/^/| /' conftest.$ac_ext >&5
75e93faa 7000
bf3b7cd3 7001( exit $ac_status )
18c04407
RW
7002{ { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
7003echo "$as_me: error: in \`$ac_pwd':" >&2;}
b61ff9c8 7004{ { echo "$as_me:$LINENO: error: cannot compute sizeof (__int64), 77
bf3b7cd3 7005See \`config.log' for more details." >&5
b61ff9c8 7006echo "$as_me: error: cannot compute sizeof (__int64), 77
bf3b7cd3 7007See \`config.log' for more details." >&2;}
18c04407 7008 { (exit 1); exit 1; }; }; }
b61ff9c8
BS
7009fi
7010rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
bf3b7cd3
JD
7011fi
7012fi
7013rm -f conftest.val
b61ff9c8
BS
7014else
7015 ac_cv_sizeof___int64=0
bf3b7cd3 7016fi
b61ff9c8
BS
7017fi
7018echo "$as_me:$LINENO: result: $ac_cv_sizeof___int64" >&5
7019echo "${ECHO_T}$ac_cv_sizeof___int64" >&6
ba479fd2 7020cat >>confdefs.h <<_ACEOF
414d23ae 7021#define SIZEOF___INT64 $ac_cv_sizeof___int64
ba479fd2 7022_ACEOF
414d23ae 7023
cafe096b 7024
414d23ae
HPN
7025fi
7026
5ec1c5e6 7027
34a86c2b
NN
7028# ---------------------
7029# Warnings and checking
7030# ---------------------
7031
b5472e1d
NN
7032# Check $CC warning features (if it's GCC).
7033# We want to use -pedantic, but we don't want warnings about
7034# * 'long long'
7035# * variadic macros
89a42ac8 7036# * overlong strings
b5472e1d
NN
7037# So, we only use -pedantic if we can disable those warnings.
7038
3bbd5a19
PB
7039loose_warn=
7040save_CFLAGS="$CFLAGS"
f6e377f8 7041for option in -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wcast-qual; do
3bbd5a19
PB
7042 as_acx_Woption=`echo "acx_cv_prog_cc_warning_$option" | $as_tr_sh`
7043
b61ff9c8
BS
7044 echo "$as_me:$LINENO: checking whether $CC supports $option" >&5
7045echo $ECHO_N "checking whether $CC supports $option... $ECHO_C" >&6
7046if eval "test \"\${$as_acx_Woption+set}\" = set"; then
b5472e1d
NN
7047 echo $ECHO_N "(cached) $ECHO_C" >&6
7048else
3bbd5a19
PB
7049 CFLAGS="$option"
7050 cat >conftest.$ac_ext <<_ACEOF
b5472e1d
NN
7051/* confdefs.h. */
7052_ACEOF
7053cat confdefs.h >>conftest.$ac_ext
7054cat >>conftest.$ac_ext <<_ACEOF
7055/* end confdefs.h. */
7056
3bbd5a19
PB
7057int
7058main ()
7059{
7060
7061 ;
7062 return 0;
7063}
b5472e1d
NN
7064_ACEOF
7065rm -f conftest.$ac_objext
b61ff9c8
BS
7066if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7067 (eval $ac_compile) 2>conftest.er1
b5472e1d
NN
7068 ac_status=$?
7069 grep -v '^ *+' conftest.er1 >conftest.err
7070 rm -f conftest.er1
7071 cat conftest.err >&5
7072 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
7073 (exit $ac_status); } &&
7074 { ac_try='test -z "$ac_c_werror_flag"
7075 || test ! -s conftest.err'
7076 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7077 (eval $ac_try) 2>&5
7078 ac_status=$?
7079 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7080 (exit $ac_status); }; } &&
7081 { ac_try='test -s conftest.$ac_objext'
7082 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7083 (eval $ac_try) 2>&5
7084 ac_status=$?
7085 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7086 (exit $ac_status); }; }; then
3bbd5a19 7087 eval "$as_acx_Woption=yes"
b5472e1d
NN
7088else
7089 echo "$as_me: failed program was:" >&5
7090sed 's/^/| /' conftest.$ac_ext >&5
7091
b61ff9c8 7092eval "$as_acx_Woption=no"
b5472e1d 7093fi
b61ff9c8 7094rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
b5472e1d
NN
7095
7096fi
b61ff9c8
BS
7097echo "$as_me:$LINENO: result: `eval echo '${'$as_acx_Woption'}'`" >&5
7098echo "${ECHO_T}`eval echo '${'$as_acx_Woption'}'`" >&6
3bbd5a19
PB
7099 if test `eval echo '${'$as_acx_Woption'}'` = yes; then
7100 loose_warn="$loose_warn${loose_warn:+ }$option"
7101fi
7102
7103 done
7104CFLAGS="$save_CFLAGS"
7105
3bbd5a19
PB
7106strict_warn=
7107save_CFLAGS="$CFLAGS"
f6e377f8 7108for option in -Wold-style-definition -Wc++-compat -Wmissing-format-attribute; do
3bbd5a19
PB
7109 as_acx_Woption=`echo "acx_cv_prog_cc_warning_$option" | $as_tr_sh`
7110
b61ff9c8
BS
7111 echo "$as_me:$LINENO: checking whether $CC supports $option" >&5
7112echo $ECHO_N "checking whether $CC supports $option... $ECHO_C" >&6
7113if eval "test \"\${$as_acx_Woption+set}\" = set"; then
89a42ac8
ZW
7114 echo $ECHO_N "(cached) $ECHO_C" >&6
7115else
3bbd5a19
PB
7116 CFLAGS="$option"
7117 cat >conftest.$ac_ext <<_ACEOF
89a42ac8
ZW
7118/* confdefs.h. */
7119_ACEOF
7120cat confdefs.h >>conftest.$ac_ext
7121cat >>conftest.$ac_ext <<_ACEOF
7122/* end confdefs.h. */
7123
3bbd5a19
PB
7124int
7125main ()
7126{
7127
7128 ;
7129 return 0;
7130}
89a42ac8
ZW
7131_ACEOF
7132rm -f conftest.$ac_objext
b61ff9c8
BS
7133if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7134 (eval $ac_compile) 2>conftest.er1
89a42ac8
ZW
7135 ac_status=$?
7136 grep -v '^ *+' conftest.er1 >conftest.err
7137 rm -f conftest.er1
7138 cat conftest.err >&5
7139 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
7140 (exit $ac_status); } &&
7141 { ac_try='test -z "$ac_c_werror_flag"
7142 || test ! -s conftest.err'
7143 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7144 (eval $ac_try) 2>&5
7145 ac_status=$?
7146 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7147 (exit $ac_status); }; } &&
7148 { ac_try='test -s conftest.$ac_objext'
7149 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7150 (eval $ac_try) 2>&5
7151 ac_status=$?
7152 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7153 (exit $ac_status); }; }; then
3bbd5a19 7154 eval "$as_acx_Woption=yes"
89a42ac8
ZW
7155else
7156 echo "$as_me: failed program was:" >&5
7157sed 's/^/| /' conftest.$ac_ext >&5
7158
b61ff9c8 7159eval "$as_acx_Woption=no"
89a42ac8 7160fi
b61ff9c8 7161rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
89a42ac8
ZW
7162
7163fi
b61ff9c8
BS
7164echo "$as_me:$LINENO: result: `eval echo '${'$as_acx_Woption'}'`" >&5
7165echo "${ECHO_T}`eval echo '${'$as_acx_Woption'}'`" >&6
3bbd5a19
PB
7166 if test `eval echo '${'$as_acx_Woption'}'` = yes; then
7167 strict_warn="$strict_warn${strict_warn:+ }$option"
34a86c2b
NN
7168fi
7169
3bbd5a19
PB
7170 done
7171CFLAGS="$save_CFLAGS"
7172
7173if test "$GCC" = yes; then
f6e377f8
AT
7174 echo "$as_me:$LINENO: checking whether $CC supports -pedantic -Wno-long-long -Wno-variadic-macros -Wno-overlength-strings" >&5
7175echo $ECHO_N "checking whether $CC supports -pedantic -Wno-long-long -Wno-variadic-macros -Wno-overlength-strings... $ECHO_C" >&6
75c9cbe3 7176if test "${acx_cv_prog_cc_pedantic__Wno_long_long__Wno_variadic_macros__Wno_overlength_strings+set}" = set; then
643d3bd2
NN
7177 echo $ECHO_N "(cached) $ECHO_C" >&6
7178else
7179 save_CFLAGS="$CFLAGS"
f6e377f8 7180CFLAGS="-pedantic -Wno-long-long -Wno-variadic-macros -Wno-overlength-strings"
3bbd5a19 7181cat >conftest.$ac_ext <<_ACEOF
643d3bd2
NN
7182/* confdefs.h. */
7183_ACEOF
7184cat confdefs.h >>conftest.$ac_ext
7185cat >>conftest.$ac_ext <<_ACEOF
7186/* end confdefs.h. */
7187
3bbd5a19
PB
7188int
7189main ()
7190{
7191
7192 ;
7193 return 0;
7194}
643d3bd2
NN
7195_ACEOF
7196rm -f conftest.$ac_objext
b61ff9c8
BS
7197if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7198 (eval $ac_compile) 2>conftest.er1
643d3bd2
NN
7199 ac_status=$?
7200 grep -v '^ *+' conftest.er1 >conftest.err
7201 rm -f conftest.er1
7202 cat conftest.err >&5
7203 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
7204 (exit $ac_status); } &&
7205 { ac_try='test -z "$ac_c_werror_flag"
7206 || test ! -s conftest.err'
7207 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7208 (eval $ac_try) 2>&5
7209 ac_status=$?
7210 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7211 (exit $ac_status); }; } &&
7212 { ac_try='test -s conftest.$ac_objext'
7213 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7214 (eval $ac_try) 2>&5
7215 ac_status=$?
7216 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7217 (exit $ac_status); }; }; then
75c9cbe3 7218 acx_cv_prog_cc_pedantic__Wno_long_long__Wno_variadic_macros__Wno_overlength_strings=yes
643d3bd2
NN
7219else
7220 echo "$as_me: failed program was:" >&5
7221sed 's/^/| /' conftest.$ac_ext >&5
7222
75c9cbe3 7223acx_cv_prog_cc_pedantic__Wno_long_long__Wno_variadic_macros__Wno_overlength_strings=no
643d3bd2 7224fi
b61ff9c8 7225rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
3bbd5a19 7226CFLAGS="$save_CFLAGS"
643d3bd2 7227fi
75c9cbe3
AS
7228echo "$as_me:$LINENO: result: $acx_cv_prog_cc_pedantic__Wno_long_long__Wno_variadic_macros__Wno_overlength_strings" >&5
7229echo "${ECHO_T}$acx_cv_prog_cc_pedantic__Wno_long_long__Wno_variadic_macros__Wno_overlength_strings" >&6
7230if test $acx_cv_prog_cc_pedantic__Wno_long_long__Wno_variadic_macros__Wno_overlength_strings = yes; then
f6e377f8 7231 strict_warn="$strict_warn${strict_warn:+ }-pedantic -Wno-long-long -Wno-variadic-macros -Wno-overlength-strings"
643d3bd2
NN
7232fi
7233
ac0f3f39 7234
ac0f3f39 7235fi
ac0f3f39 7236
ac0f3f39 7237
b61ff9c8 7238# Check whether --enable-werror-always or --disable-werror-always was given.
09a9c095 7239if test "${enable_werror_always+set}" = set; then
b61ff9c8
BS
7240 enableval="$enable_werror_always"
7241
09a9c095
NN
7242else
7243 enable_werror_always=no
b61ff9c8 7244fi;
3bbd5a19
PB
7245if test $enable_werror_always = yes; then
7246 strict_warn="$strict_warn${strict_warn:+ }-Werror"
373477bb 7247fi
373477bb 7248
373477bb
GDR
7249
7250
7251
3bbd5a19
PB
7252# The above macros do nothing if the compiler is not GCC. However, the
7253# Makefile has more goo to add other flags, so this variabl is used to
7254# enables warnings only for GCC.
414d23ae
HPN
7255warn_cflags=
7256if test "x$GCC" = "xyes"; then
7257 warn_cflags='$(GCC_WARN_CFLAGS)'
7258fi
7259
7260
8b1f719a 7261# Enable expensive internal checks
a1286ef5
ZW
7262is_release=
7263if test x"`cat $srcdir/DEV-PHASE`" != xexperimental; then
7264 is_release=yes
7265fi
a6ccdbab 7266
b61ff9c8 7267# Check whether --enable-checking or --disable-checking was given.
414d23ae 7268if test "${enable_checking+set}" = set; then
b61ff9c8
BS
7269 enableval="$enable_checking"
7270 ac_checking_flags="${enableval}"
e1bbfc5c
NS
7271else
7272
7273# Determine the default checks.
7274if test x$is_release = x ; then
7275 ac_checking_flags=yes
7276else
7277 ac_checking_flags=release
7278fi
b61ff9c8 7279fi;
e1bbfc5c 7280IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="$IFS,"
04c3028a 7281for check in release $ac_checking_flags
e1bbfc5c
NS
7282do
7283 case $check in
cdce5c16 7284 # these set all the flags to specific states
0d475361 7285 yes) ac_assert_checking=1 ; ac_checking=1 ; ac_df_checking= ;
cdce5c16 7286 ac_fold_checking= ; ac_gc_checking=1 ;
726a989a 7287 ac_gc_always_collect= ; ac_gimple_checking=1 ; ac_rtl_checking= ;
232b67d9 7288 ac_rtlflag_checking=1 ; ac_runtime_checking=1 ;
7e98624c 7289 ac_tree_checking=1 ; ac_valgrind_checking= ;
1b24a790 7290 ac_types_checking=1 ;;
3089f8b5 7291 no|none) ac_assert_checking= ; ac_checking= ; ac_df_checking= ;
cdce5c16 7292 ac_fold_checking= ; ac_gc_checking= ;
726a989a 7293 ac_gc_always_collect= ; ac_gimple_checking= ; ac_rtl_checking= ;
232b67d9 7294 ac_rtlflag_checking= ; ac_runtime_checking= ;
7e98624c
RG
7295 ac_tree_checking= ; ac_valgrind_checking= ;
7296 ac_types_checking= ;;
3089f8b5 7297 all) ac_assert_checking=1 ; ac_checking=1 ; ac_df_checking=1 ;
cdce5c16 7298 ac_fold_checking=1 ; ac_gc_checking=1 ;
726a989a 7299 ac_gc_always_collect=1 ; ac_gimple_checking=1 ; ac_rtl_checking=1 ;
cdce5c16 7300 ac_rtlflag_checking=1 ; ac_runtime_checking=1 ;
7e98624c
RG
7301 ac_tree_checking=1 ; ac_valgrind_checking= ;
7302 ac_types_checking=1 ;;
3089f8b5 7303 release) ac_assert_checking=1 ; ac_checking= ; ac_df_checking= ;
cdce5c16 7304 ac_fold_checking= ; ac_gc_checking= ;
726a989a 7305 ac_gc_always_collect= ; ac_gimple_checking= ; ac_rtl_checking= ;
cdce5c16 7306 ac_rtlflag_checking= ; ac_runtime_checking=1 ;
7e98624c
RG
7307 ac_tree_checking= ; ac_valgrind_checking= ;
7308 ac_types_checking= ;;
cdce5c16 7309 # these enable particular checks
e1bbfc5c 7310 assert) ac_assert_checking=1 ;;
3089f8b5 7311 df) ac_df_checking=1 ;;
e1bbfc5c
NS
7312 fold) ac_fold_checking=1 ;;
7313 gc) ac_gc_checking=1 ;;
7314 gcac) ac_gc_always_collect=1 ;;
726a989a 7315 gimple) ac_gimple_checking=1 ;;
e1bbfc5c 7316 misc) ac_checking=1 ;;
e1bbfc5c 7317 rtl) ac_rtl_checking=1 ;;
cdce5c16 7318 rtlflag) ac_rtlflag_checking=1 ;;
b53ef395 7319 runtime) ac_runtime_checking=1 ;;
e1bbfc5c 7320 tree) ac_tree_checking=1 ;;
7e98624c 7321 types) ac_types_checking=1 ;;
cdce5c16 7322 valgrind) ac_valgrind_checking=1 ;;
e1bbfc5c 7323 *) { { echo "$as_me:$LINENO: error: unknown check category $check" >&5
ba479fd2
NN
7324echo "$as_me: error: unknown check category $check" >&2;}
7325 { (exit 1); exit 1; }; } ;;
e1bbfc5c
NS
7326 esac
7327done
7328IFS="$ac_save_IFS"
06c37c96 7329
ba479fd2
NN
7330nocommon_flag=""
7331if test x$ac_checking != x ; then
7332
7333cat >>confdefs.h <<\_ACEOF
7334#define ENABLE_CHECKING 1
7335_ACEOF
7336
7337 nocommon_flag=-fno-common
7338fi
3bbd5a19 7339
3089f8b5
PB
7340if test x$ac_df_checking != x ; then
7341
7342cat >>confdefs.h <<\_ACEOF
7343#define ENABLE_DF_CHECKING 1
7344_ACEOF
7345
7346fi
06c37c96
NS
7347if test x$ac_assert_checking != x ; then
7348
7349cat >>confdefs.h <<\_ACEOF
7350#define ENABLE_ASSERT_CHECKING 1
7351_ACEOF
7352
726a989a
RB
7353fi
7354if test x$ac_gimple_checking != x ; then
7355
7356cat >>confdefs.h <<\_ACEOF
7357#define ENABLE_GIMPLE_CHECKING 1
7358_ACEOF
7359
b53ef395 7360fi
232b67d9 7361
b53ef395
NS
7362if test x$ac_runtime_checking != x ; then
7363
7364cat >>confdefs.h <<\_ACEOF
7365#define ENABLE_RUNTIME_CHECKING 1
7366_ACEOF
7367
06c37c96 7368fi
ba479fd2
NN
7369if test x$ac_tree_checking != x ; then
7370
7371cat >>confdefs.h <<\_ACEOF
7372#define ENABLE_TREE_CHECKING 1
7373_ACEOF
7374
13f05fd0 7375 TREEBROWSER=tree-browser.o
ba479fd2 7376fi
7e98624c
RG
7377if test x$ac_types_checking != x ; then
7378
7379cat >>confdefs.h <<\_ACEOF
7380#define ENABLE_TYPES_CHECKING 1
7381_ACEOF
7382
7383fi
13f05fd0 7384
ba479fd2
NN
7385if test x$ac_rtl_checking != x ; then
7386
7387cat >>confdefs.h <<\_ACEOF
7388#define ENABLE_RTL_CHECKING 1
7389_ACEOF
7390
7391fi
7392if test x$ac_rtlflag_checking != x ; then
7393
7394cat >>confdefs.h <<\_ACEOF
7395#define ENABLE_RTL_FLAG_CHECKING 1
7396_ACEOF
7397
7398fi
7399if test x$ac_gc_checking != x ; then
7400
7401cat >>confdefs.h <<\_ACEOF
7402#define ENABLE_GC_CHECKING 1
7403_ACEOF
7404
7405fi
7406if test x$ac_gc_always_collect != x ; then
7407
7408cat >>confdefs.h <<\_ACEOF
7409#define ENABLE_GC_ALWAYS_COLLECT 1
7410_ACEOF
7411
7412fi
7413if test x$ac_fold_checking != x ; then
7414
7415cat >>confdefs.h <<\_ACEOF
7416#define ENABLE_FOLD_CHECKING 1
7417_ACEOF
7418
7419fi
7420valgrind_path_defines=
7421valgrind_command=
7422
ba479fd2 7423if test "${ac_cv_header_valgrind_h+set}" = set; then
b61ff9c8
BS
7424 echo "$as_me:$LINENO: checking for valgrind.h" >&5
7425echo $ECHO_N "checking for valgrind.h... $ECHO_C" >&6
ba479fd2
NN
7426if test "${ac_cv_header_valgrind_h+set}" = set; then
7427 echo $ECHO_N "(cached) $ECHO_C" >&6
7428fi
b61ff9c8
BS
7429echo "$as_me:$LINENO: result: $ac_cv_header_valgrind_h" >&5
7430echo "${ECHO_T}$ac_cv_header_valgrind_h" >&6
ba479fd2
NN
7431else
7432 # Is the header compilable?
b61ff9c8
BS
7433echo "$as_me:$LINENO: checking valgrind.h usability" >&5
7434echo $ECHO_N "checking valgrind.h usability... $ECHO_C" >&6
ba479fd2 7435cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
7436/* confdefs.h. */
7437_ACEOF
7438cat confdefs.h >>conftest.$ac_ext
7439cat >>conftest.$ac_ext <<_ACEOF
7440/* end confdefs.h. */
7441$ac_includes_default
63cf211a 7442#include <valgrind.h>
ba479fd2
NN
7443_ACEOF
7444rm -f conftest.$ac_objext
b61ff9c8
BS
7445if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7446 (eval $ac_compile) 2>conftest.er1
ba479fd2 7447 ac_status=$?
86da66b5
HPN
7448 grep -v '^ *+' conftest.er1 >conftest.err
7449 rm -f conftest.er1
7450 cat conftest.err >&5
ba479fd2 7451 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
7452 (exit $ac_status); } &&
7453 { ac_try='test -z "$ac_c_werror_flag"
7454 || test ! -s conftest.err'
7455 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7456 (eval $ac_try) 2>&5
7457 ac_status=$?
7458 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7459 (exit $ac_status); }; } &&
7460 { ac_try='test -s conftest.$ac_objext'
7461 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7462 (eval $ac_try) 2>&5
7463 ac_status=$?
7464 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7465 (exit $ac_status); }; }; then
ba479fd2
NN
7466 ac_header_compiler=yes
7467else
7468 echo "$as_me: failed program was:" >&5
7469sed 's/^/| /' conftest.$ac_ext >&5
7470
b61ff9c8 7471ac_header_compiler=no
ba479fd2 7472fi
b61ff9c8
BS
7473rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7474echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7475echo "${ECHO_T}$ac_header_compiler" >&6
ba479fd2
NN
7476
7477# Is the header present?
b61ff9c8
BS
7478echo "$as_me:$LINENO: checking valgrind.h presence" >&5
7479echo $ECHO_N "checking valgrind.h presence... $ECHO_C" >&6
ba479fd2 7480cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
7481/* confdefs.h. */
7482_ACEOF
7483cat confdefs.h >>conftest.$ac_ext
7484cat >>conftest.$ac_ext <<_ACEOF
7485/* end confdefs.h. */
7486#include <valgrind.h>
7487_ACEOF
b61ff9c8
BS
7488if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7489 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
ba479fd2
NN
7490 ac_status=$?
7491 grep -v '^ *+' conftest.er1 >conftest.err
7492 rm -f conftest.er1
7493 cat conftest.err >&5
7494 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
7495 (exit $ac_status); } >/dev/null; then
7496 if test -s conftest.err; then
7497 ac_cpp_err=$ac_c_preproc_warn_flag
7498 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
7499 else
7500 ac_cpp_err=
7501 fi
7502else
7503 ac_cpp_err=yes
7504fi
7505if test -z "$ac_cpp_err"; then
ba479fd2
NN
7506 ac_header_preproc=yes
7507else
7508 echo "$as_me: failed program was:" >&5
7509sed 's/^/| /' conftest.$ac_ext >&5
7510
7511 ac_header_preproc=no
7512fi
7513rm -f conftest.err conftest.$ac_ext
b61ff9c8
BS
7514echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7515echo "${ECHO_T}$ac_header_preproc" >&6
ba479fd2
NN
7516
7517# So? What about this header?
86da66b5
HPN
7518case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
7519 yes:no: )
ba479fd2
NN
7520 { echo "$as_me:$LINENO: WARNING: valgrind.h: accepted by the compiler, rejected by the preprocessor!" >&5
7521echo "$as_me: WARNING: valgrind.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
86da66b5
HPN
7522 { echo "$as_me:$LINENO: WARNING: valgrind.h: proceeding with the compiler's result" >&5
7523echo "$as_me: WARNING: valgrind.h: proceeding with the compiler's result" >&2;}
7524 ac_header_preproc=yes
ba479fd2 7525 ;;
86da66b5 7526 no:yes:* )
ba479fd2
NN
7527 { echo "$as_me:$LINENO: WARNING: valgrind.h: present but cannot be compiled" >&5
7528echo "$as_me: WARNING: valgrind.h: present but cannot be compiled" >&2;}
86da66b5
HPN
7529 { echo "$as_me:$LINENO: WARNING: valgrind.h: check for missing prerequisite headers?" >&5
7530echo "$as_me: WARNING: valgrind.h: check for missing prerequisite headers?" >&2;}
7531 { echo "$as_me:$LINENO: WARNING: valgrind.h: see the Autoconf documentation" >&5
7532echo "$as_me: WARNING: valgrind.h: see the Autoconf documentation" >&2;}
7533 { echo "$as_me:$LINENO: WARNING: valgrind.h: section \"Present But Cannot Be Compiled\"" >&5
7534echo "$as_me: WARNING: valgrind.h: section \"Present But Cannot Be Compiled\"" >&2;}
ba479fd2
NN
7535 { echo "$as_me:$LINENO: WARNING: valgrind.h: proceeding with the preprocessor's result" >&5
7536echo "$as_me: WARNING: valgrind.h: proceeding with the preprocessor's result" >&2;}
86da66b5
HPN
7537 { echo "$as_me:$LINENO: WARNING: valgrind.h: in the future, the compiler will take precedence" >&5
7538echo "$as_me: WARNING: valgrind.h: in the future, the compiler will take precedence" >&2;}
b61ff9c8
BS
7539 (
7540 cat <<\_ASBOX
7541## ------------------------------------------ ##
7542## Report this to the AC_PACKAGE_NAME lists. ##
7543## ------------------------------------------ ##
7544_ASBOX
7545 ) |
7546 sed "s/^/$as_me: WARNING: /" >&2
ba479fd2
NN
7547 ;;
7548esac
b61ff9c8
BS
7549echo "$as_me:$LINENO: checking for valgrind.h" >&5
7550echo $ECHO_N "checking for valgrind.h... $ECHO_C" >&6
ba479fd2
NN
7551if test "${ac_cv_header_valgrind_h+set}" = set; then
7552 echo $ECHO_N "(cached) $ECHO_C" >&6
7553else
7554 ac_cv_header_valgrind_h=$ac_header_preproc
6938ec6c 7555fi
b61ff9c8
BS
7556echo "$as_me:$LINENO: result: $ac_cv_header_valgrind_h" >&5
7557echo "${ECHO_T}$ac_cv_header_valgrind_h" >&6
ba479fd2 7558
6e3f3080 7559fi
ba479fd2 7560if test $ac_cv_header_valgrind_h = yes; then
6938ec6c
NN
7561 have_valgrind_h=yes
7562else
ba479fd2 7563 have_valgrind_h=no
6938ec6c
NN
7564fi
7565
7566
ba479fd2 7567
cdce5c16 7568if test x$ac_valgrind_checking != x ; then
414d23ae
HPN
7569 # It is certainly possible that there's valgrind but no valgrind.h.
7570 # GCC relies on making annotations so we must have both.
b61ff9c8
BS
7571 echo "$as_me:$LINENO: checking for VALGRIND_DISCARD in <valgrind/memcheck.h>" >&5
7572echo $ECHO_N "checking for VALGRIND_DISCARD in <valgrind/memcheck.h>... $ECHO_C" >&6
ba479fd2 7573 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
7574/* confdefs.h. */
7575_ACEOF
7576cat confdefs.h >>conftest.$ac_ext
7577cat >>conftest.$ac_ext <<_ACEOF
7578/* end confdefs.h. */
a207b594 7579#include <valgrind/memcheck.h>
14011ca4
AJ
7580#ifndef VALGRIND_DISCARD
7581#error VALGRIND_DISCARD not defined
7582#endif
ba479fd2 7583_ACEOF
b61ff9c8
BS
7584if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7585 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
ba479fd2
NN
7586 ac_status=$?
7587 grep -v '^ *+' conftest.er1 >conftest.err
7588 rm -f conftest.er1
7589 cat conftest.err >&5
7590 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
7591 (exit $ac_status); } >/dev/null; then
7592 if test -s conftest.err; then
7593 ac_cpp_err=$ac_c_preproc_warn_flag
7594 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
7595 else
7596 ac_cpp_err=
7597 fi
7598else
7599 ac_cpp_err=yes
7600fi
7601if test -z "$ac_cpp_err"; then
a207b594
HPN
7602 gcc_cv_header_valgrind_memcheck_h=yes
7603else
ba479fd2
NN
7604 echo "$as_me: failed program was:" >&5
7605sed 's/^/| /' conftest.$ac_ext >&5
7606
a207b594
HPN
7607 gcc_cv_header_valgrind_memcheck_h=no
7608fi
ba479fd2 7609rm -f conftest.err conftest.$ac_ext
b61ff9c8
BS
7610 echo "$as_me:$LINENO: result: $gcc_cv_header_valgrind_memcheck_h" >&5
7611echo "${ECHO_T}$gcc_cv_header_valgrind_memcheck_h" >&6
7612 echo "$as_me:$LINENO: checking for VALGRIND_DISCARD in <memcheck.h>" >&5
7613echo $ECHO_N "checking for VALGRIND_DISCARD in <memcheck.h>... $ECHO_C" >&6
ba479fd2 7614 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
7615/* confdefs.h. */
7616_ACEOF
7617cat confdefs.h >>conftest.$ac_ext
7618cat >>conftest.$ac_ext <<_ACEOF
7619/* end confdefs.h. */
a207b594
HPN
7620#include <memcheck.h>
7621#ifndef VALGRIND_DISCARD
7622#error VALGRIND_DISCARD not defined
7623#endif
ba479fd2 7624_ACEOF
b61ff9c8
BS
7625if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7626 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
ba479fd2
NN
7627 ac_status=$?
7628 grep -v '^ *+' conftest.er1 >conftest.err
7629 rm -f conftest.er1
7630 cat conftest.err >&5
7631 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
7632 (exit $ac_status); } >/dev/null; then
7633 if test -s conftest.err; then
7634 ac_cpp_err=$ac_c_preproc_warn_flag
7635 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
7636 else
7637 ac_cpp_err=
7638 fi
7639else
7640 ac_cpp_err=yes
7641fi
7642if test -z "$ac_cpp_err"; then
14011ca4
AJ
7643 gcc_cv_header_memcheck_h=yes
7644else
ba479fd2
NN
7645 echo "$as_me: failed program was:" >&5
7646sed 's/^/| /' conftest.$ac_ext >&5
7647
cafe096b
EC
7648 gcc_cv_header_memcheck_h=no
7649fi
ba479fd2 7650rm -f conftest.err conftest.$ac_ext
b61ff9c8
BS
7651 echo "$as_me:$LINENO: result: $gcc_cv_header_memcheck_h" >&5
7652echo "${ECHO_T}$gcc_cv_header_memcheck_h" >&6
ba479fd2 7653
56694dd9
ZW
7654# Prepare PATH_SEPARATOR.
7655# The user is always right.
7656if test "${PATH_SEPARATOR+set}" != set; then
7657 echo "#! /bin/sh" >conf$$.sh
7658 echo "exit 0" >>conf$$.sh
7659 chmod +x conf$$.sh
7660 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
7661 PATH_SEPARATOR=';'
7662 else
7663 PATH_SEPARATOR=:
7664 fi
7665 rm -f conf$$.sh
7666fi
7667
7668# Find out how to test for executable files. Don't use a zero-byte file,
7669# as systems may use methods other than mode bits to determine executability.
7670cat >conf$$.file <<_ASEOF
7671#! /bin/sh
7672exit 0
7673_ASEOF
7674chmod +x conf$$.file
7675if test -x conf$$.file >/dev/null 2>&1; then
7676 ac_executable_p="test -x"
7677else
7678 ac_executable_p="test -f"
7679fi
7680rm -f conf$$.file
7681
7682# Extract the first word of "valgrind", so it can be a program name with args.
414d23ae 7683set dummy valgrind; ac_word=$2
b61ff9c8
BS
7684echo "$as_me:$LINENO: checking for $ac_word" >&5
7685echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
ba479fd2
NN
7686if test "${ac_cv_path_valgrind_path+set}" = set; then
7687 echo $ECHO_N "(cached) $ECHO_C" >&6
414d23ae
HPN
7688else
7689 case "$valgrind_path" in
56694dd9
ZW
7690 [\\/]* | ?:[\\/]*)
7691 ac_cv_path_valgrind_path="$valgrind_path" # Let the user override the test with a path.
7692 ;;
414d23ae 7693 *)
56694dd9
ZW
7694 ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
7695 for ac_dir in $PATH; do
7696 IFS="$ac_save_IFS"
7697 test -z "$ac_dir" && ac_dir=.
7698 for ac_exec_ext in '' $ac_executable_extensions; do
7699 if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
7700 if $ac_dir/$ac_word --version | grep valgrind- >/dev/null 2>&1; then
7701 ac_cv_path_valgrind_path="$ac_dir/$ac_word$ac_exec_ext"
7702 break 2
7703 fi
7704 fi
7705 done
7706 done
7707 IFS="$ac_save_IFS"
7708 ;;
414d23ae 7709esac
75e93faa 7710fi
414d23ae
HPN
7711valgrind_path="$ac_cv_path_valgrind_path"
7712if test -n "$valgrind_path"; then
b61ff9c8
BS
7713 echo "$as_me:$LINENO: result: $valgrind_path" >&5
7714echo "${ECHO_T}$valgrind_path" >&6
414d23ae 7715else
b61ff9c8
BS
7716 echo "$as_me:$LINENO: result: no" >&5
7717echo "${ECHO_T}no" >&6
414d23ae
HPN
7718fi
7719
a207b594
HPN
7720 if test "x$valgrind_path" = "x" \
7721 || (test $have_valgrind_h = no \
7722 && test $gcc_cv_header_memcheck_h = no \
7723 && test $gcc_cv_header_valgrind_memcheck_h = no); then
ba479fd2
NN
7724 { { echo "$as_me:$LINENO: error: *** Can't find both valgrind and valgrind/memcheck.h, memcheck.h or valgrind.h" >&5
7725echo "$as_me: error: *** Can't find both valgrind and valgrind/memcheck.h, memcheck.h or valgrind.h" >&2;}
7726 { (exit 1); exit 1; }; }
414d23ae
HPN
7727 fi
7728 valgrind_path_defines=-DVALGRIND_PATH='\"'$valgrind_path'\"'
7729 valgrind_command="$valgrind_path -q"
ba479fd2
NN
7730
7731cat >>confdefs.h <<\_ACEOF
414d23ae 7732#define ENABLE_VALGRIND_CHECKING 1
ba479fd2 7733_ACEOF
75e93faa 7734
a207b594 7735 if test $gcc_cv_header_valgrind_memcheck_h = yes; then
ba479fd2
NN
7736
7737cat >>confdefs.h <<\_ACEOF
a207b594 7738#define HAVE_VALGRIND_MEMCHECK_H 1
ba479fd2 7739_ACEOF
a207b594
HPN
7740
7741 fi
14011ca4 7742 if test $gcc_cv_header_memcheck_h = yes; then
ba479fd2
NN
7743
7744cat >>confdefs.h <<\_ACEOF
14011ca4 7745#define HAVE_MEMCHECK_H 1
ba479fd2 7746_ACEOF
14011ca4
AJ
7747
7748 fi
414d23ae 7749fi
75e93faa 7750
75e93faa
ZW
7751
7752
414d23ae 7753# Enable code coverage collection
b61ff9c8 7754# Check whether --enable-coverage or --disable-coverage was given.
414d23ae 7755if test "${enable_coverage+set}" = set; then
b61ff9c8
BS
7756 enableval="$enable_coverage"
7757 case "${enableval}" in
6dd297da
NN
7758 yes|noopt)
7759 coverage_flags="-fprofile-arcs -ftest-coverage -frandom-seed=\$@ -O0"
7760 ;;
7761 opt)
7762 coverage_flags="-fprofile-arcs -ftest-coverage -frandom-seed=\$@ -O2"
7763 ;;
7764 no)
7765 # a.k.a. --disable-coverage
7766 coverage_flags=""
7767 ;;
7768 *)
7769 { { echo "$as_me:$LINENO: error: unknown coverage setting $enableval" >&5
ba479fd2
NN
7770echo "$as_me: error: unknown coverage setting $enableval" >&2;}
7771 { (exit 1); exit 1; }; }
6dd297da 7772 ;;
414d23ae 7773esac
75e93faa 7774else
414d23ae 7775 coverage_flags=""
b61ff9c8 7776fi;
a3bba767 7777
2f41c1d6 7778
b61ff9c8 7779# Check whether --enable-gather-detailed-mem-stats or --disable-gather-detailed-mem-stats was given.
1a4b763e 7780if test "${enable_gather_detailed_mem_stats+set}" = set; then
b61ff9c8
BS
7781 enableval="$enable_gather_detailed_mem_stats"
7782
439a7e54
DN
7783else
7784 enable_gather_detailed_mem_stats=no
b61ff9c8 7785fi;
439a7e54 7786if test x$enable_gather_detailed_mem_stats = xyes ; then
ba479fd2
NN
7787
7788cat >>confdefs.h <<\_ACEOF
439a7e54 7789#define GATHER_STATISTICS 1
ba479fd2 7790_ACEOF
439a7e54
DN
7791
7792fi
7793
73458fb7
NN
7794# -------------------------------
7795# Miscenalleous configure options
7796# -------------------------------
34a86c2b
NN
7797
7798# With stabs
ba479fd2 7799
b61ff9c8 7800# Check whether --with-stabs or --without-stabs was given.
34a86c2b 7801if test "${with_stabs+set}" = set; then
b61ff9c8
BS
7802 withval="$with_stabs"
7803 stabs="$with_stabs"
34a86c2b
NN
7804else
7805 stabs=no
b61ff9c8 7806fi;
cafe096b 7807
34a86c2b 7808# Determine whether or not multilibs are enabled.
b61ff9c8 7809# Check whether --enable-multilib or --disable-multilib was given.
34a86c2b 7810if test "${enable_multilib+set}" = set; then
b61ff9c8
BS
7811 enableval="$enable_multilib"
7812
34a86c2b
NN
7813else
7814 enable_multilib=yes
b61ff9c8 7815fi;
75e93faa 7816
34a86c2b 7817
414d23ae 7818# Enable __cxa_atexit for C++.
b61ff9c8 7819# Check whether --enable-__cxa_atexit or --disable-__cxa_atexit was given.
414d23ae 7820if test "${enable___cxa_atexit+set}" = set; then
b61ff9c8 7821 enableval="$enable___cxa_atexit"
75e93faa 7822
b61ff9c8 7823fi;
75e93faa 7824
486aa804 7825# Enable C extension for decimal float if target supports it.
b61ff9c8 7826# Check whether --enable-decimal-float or --disable-decimal-float was given.
486aa804 7827if test "${enable_decimal_float+set}" = set; then
b61ff9c8
BS
7828 enableval="$enable_decimal_float"
7829
79b87c74
MM
7830 case $enable_decimal_float in
7831 yes | no | bid | dpd) ;;
7832 *) { { echo "$as_me:$LINENO: error: '$enable_decimal_float' is an invalid value for --enable-decimal-float.
7833Valid choices are 'yes', 'bid', 'dpd', and 'no'." >&5
7834echo "$as_me: error: '$enable_decimal_float' is an invalid value for --enable-decimal-float.
7835Valid choices are 'yes', 'bid', 'dpd', and 'no'." >&2;}
7836 { (exit 1); exit 1; }; } ;;
7837 esac
7838
7839else
7840
7841 case $target in
7842 powerpc*-*-linux* | i?86*-*-linux* | x86_64*-*-linux*)
a4a9df5f 7843 enable_decimal_float=yes
486aa804
BE
7844 ;;
7845 *)
7846 { echo "$as_me:$LINENO: WARNING: decimal float is not supported for this target" >&5
7847echo "$as_me: WARNING: decimal float is not supported for this target" >&2;}
7848 enable_decimal_float=no
7849 ;;
79b87c74 7850 esac
486aa804 7851
b61ff9c8 7852fi;
486aa804 7853
79b87c74
MM
7854dfp=`if test $enable_decimal_float != no; then echo 1; else echo 0; fi`
7855
7856cat >>confdefs.h <<_ACEOF
7857#define ENABLE_DECIMAL_FLOAT $dfp
7858_ACEOF
7859
7860
7861# x86's use BID format instead of DPD
7862case x$enable_decimal_float in
7863 xyes)
7864 case $target in
7865 i?86*-*-linux* | x86_64*-*-linux*)
7866 enable_decimal_float=bid
7867 ;;
7868 *)
7869 enable_decimal_float=dpd
7870 ;;
7871 esac
7872 ;;
7873 xno)
7874 # ENABLE_DECIMAL_FLOAT is set to 0. But we have to have proper
7875 # dependency on libdecnumber.
7876 enable_decimal_float=dpd
7877 ;;
7878esac
486aa804
BE
7879
7880
79b87c74 7881bid=`if test $enable_decimal_float = bid; then echo 1; else echo 0; fi`
486aa804
BE
7882
7883cat >>confdefs.h <<_ACEOF
79b87c74 7884#define ENABLE_DECIMAL_BID_FORMAT $bid
486aa804
BE
7885_ACEOF
7886
7887
ab22c1fa 7888# Enable C extension for fixed-point arithmetic.
b61ff9c8 7889# Check whether --enable-fixed-point or --disable-fixed-point was given.
ab22c1fa 7890if test "${enable_fixed_point+set}" = set; then
b61ff9c8
BS
7891 enableval="$enable_fixed_point"
7892
ab22c1fa
CF
7893
7894else
7895
7896 case $target in
7897 mips*-*-*)
d5be1dd4 7898 case $host in
a0e527e3
RW
7899 mips*-sgi-irix*)
7900 { echo "$as_me:$LINENO: WARNING: fixed-point is not supported on IRIX" >&5
7901echo "$as_me: WARNING: fixed-point is not supported on IRIX" >&2;}
d5be1dd4
RS
7902 enable_fixed_point=no
7903 ;;
7904 *)
7905 enable_fixed_point=yes
7906 ;;
7907 esac
ab22c1fa
CF
7908 ;;
7909 *)
7910 { echo "$as_me:$LINENO: WARNING: fixed-point is not supported for this target" >&5
7911echo "$as_me: WARNING: fixed-point is not supported for this target" >&2;}
7912 enable_fixed_point=no
7913 ;;
7914 esac
7915
b61ff9c8 7916fi;
ab22c1fa
CF
7917
7918
7919fixedpoint=`if test $enable_fixed_point = yes; then echo 1; else echo 0; fi`
7920
7921cat >>confdefs.h <<_ACEOF
7922#define ENABLE_FIXED_POINT $fixedpoint
7923_ACEOF
7924
7925
414d23ae
HPN
7926# Enable threads
7927# Pass with no value to take the default
7928# Pass with a value to specify a thread package
b61ff9c8 7929# Check whether --enable-threads or --disable-threads was given.
414d23ae 7930if test "${enable_threads+set}" = set; then
b61ff9c8
BS
7931 enableval="$enable_threads"
7932
414d23ae
HPN
7933else
7934 enable_threads=''
b61ff9c8 7935fi;
2f41c1d6 7936
b61ff9c8 7937# Check whether --enable-tls or --disable-tls was given.
1a4b763e 7938if test "${enable_tls+set}" = set; then
b61ff9c8
BS
7939 enableval="$enable_tls"
7940
8dea1cca
DD
7941 case $enable_tls in
7942 yes | no) ;;
7943 *) { { echo "$as_me:$LINENO: error: '$enable_tls' is an invalid value for --enable-tls.
7944Valid choices are 'yes' and 'no'." >&5
7945echo "$as_me: error: '$enable_tls' is an invalid value for --enable-tls.
7946Valid choices are 'yes' and 'no'." >&2;}
7947 { (exit 1); exit 1; }; } ;;
7948 esac
7949
7950else
7951 enable_tls=''
b61ff9c8 7952fi;
1a4b763e 7953
b61ff9c8 7954# Check whether --enable-objc-gc or --disable-objc-gc was given.
414d23ae 7955if test "${enable_objc_gc+set}" = set; then
b61ff9c8
BS
7956 enableval="$enable_objc_gc"
7957 if test x$enable_objc_gc = xno; then
414d23ae
HPN
7958 objc_boehm_gc=''
7959else
7960 objc_boehm_gc=1
7961fi
7962else
7963 objc_boehm_gc=''
b61ff9c8 7964fi;
75e93faa 7965
a6ccdbab 7966
b61ff9c8 7967# Check whether --with-dwarf2 or --without-dwarf2 was given.
414d23ae 7968if test "${with_dwarf2+set}" = set; then
b61ff9c8
BS
7969 withval="$with_dwarf2"
7970 dwarf2="$with_dwarf2"
75e93faa 7971else
414d23ae 7972 dwarf2=no
b61ff9c8 7973fi;
2f41c1d6 7974
b61ff9c8 7975# Check whether --enable-shared or --disable-shared was given.
1a4b763e 7976if test "${enable_shared+set}" = set; then
b61ff9c8
BS
7977 enableval="$enable_shared"
7978
414d23ae
HPN
7979 case $enable_shared in
7980 yes | no) ;;
7981 *)
7982 enable_shared=no
7983 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
7984 for pkg in $enableval; do
7985 if test "X$pkg" = "Xgcc" || test "X$pkg" = "Xlibgcc"; then
7986 enable_shared=yes
7987 fi
7988 done
7989 IFS="$ac_save_ifs"
7990 ;;
7991 esac
7992
75e93faa 7993else
414d23ae 7994 enable_shared=yes
b61ff9c8 7995fi;
703d89ab 7996
ab22c1fa 7997
1a4b763e 7998
b61ff9c8 7999# Check whether --with-build-sysroot or --without-build-sysroot was given.
160633c6 8000if test "${with_build_sysroot+set}" = set; then
b61ff9c8 8001 withval="$with_build_sysroot"
160633c6 8002
b61ff9c8 8003fi;
160633c6
MM
8004
8005
b61ff9c8 8006# Check whether --with-sysroot or --without-sysroot was given.
4977bab6 8007if test "${with_sysroot+set}" = set; then
b61ff9c8
BS
8008 withval="$with_sysroot"
8009
4977bab6 8010 case ${with_sysroot} in
caa55b1e 8011 yes) TARGET_SYSTEM_ROOT='${exec_prefix}/${target_noncanonical}/sys-root' ;;
4977bab6
ZW
8012 *) TARGET_SYSTEM_ROOT=$with_sysroot ;;
8013 esac
ba479fd2 8014
4977bab6 8015 TARGET_SYSTEM_ROOT_DEFINE='-DTARGET_SYSTEM_ROOT=\"$(TARGET_SYSTEM_ROOT)\"'
14da6073 8016 CROSS_SYSTEM_HEADER_DIR='$(TARGET_SYSTEM_ROOT)$${sysroot_headers_suffix}$(NATIVE_SYSTEM_HEADER_DIR)'
4977bab6 8017
748670c2
RS
8018 if test "x$prefix" = xNONE; then
8019 test_prefix=/usr/local
8020 else
8021 test_prefix=$prefix
8022 fi
047d636f 8023 if test "x$exec_prefix" = xNONE; then
748670c2 8024 test_exec_prefix=$test_prefix
047d636f 8025 else
748670c2 8026 test_exec_prefix=$exec_prefix
047d636f
DJ
8027 fi
8028 case ${TARGET_SYSTEM_ROOT} in
91710e62 8029 "${test_prefix}"|"${test_prefix}/"*|\
748670c2
RS
8030 "${test_exec_prefix}"|"${test_exec_prefix}/"*|\
8031 '${prefix}'|'${prefix}/'*|\
91710e62 8032 '${exec_prefix}'|'${exec_prefix}/'*)
047d636f
DJ
8033 t="$TARGET_SYSTEM_ROOT_DEFINE -DTARGET_SYSTEM_ROOT_RELOCATABLE"
8034 TARGET_SYSTEM_ROOT_DEFINE="$t"
8035 ;;
8036 esac
8037
4977bab6 8038else
ba479fd2 8039
4977bab6 8040 TARGET_SYSTEM_ROOT=
db720d9a 8041 TARGET_SYSTEM_ROOT_DEFINE=
4977bab6
ZW
8042 CROSS_SYSTEM_HEADER_DIR='$(gcc_tooldir)/sys-include'
8043
b61ff9c8 8044fi;
4977bab6
ZW
8045
8046
8047
8048
d1bd0ded 8049# Build with intermodule optimisations
b61ff9c8 8050# Check whether --enable-intermodule or --disable-intermodule was given.
d1bd0ded 8051if test "${enable_intermodule+set}" = set; then
b61ff9c8
BS
8052 enableval="$enable_intermodule"
8053 case ${enable_intermodule} in
0c46c5c7
KC
8054 yes) onestep="-onestep";;
8055 *) onestep="";;
d1bd0ded 8056esac
0c46c5c7
KC
8057else
8058 onestep=""
b61ff9c8 8059fi;
2f41c1d6
PB
8060
8061
8062
8063
b61ff9c8 8064# Check whether --with-pkgversion or --without-pkgversion was given.
2f41c1d6 8065if test "${with_pkgversion+set}" = set; then
b61ff9c8
BS
8066 withval="$with_pkgversion"
8067 case "$withval" in
2f41c1d6
PB
8068 yes) { { echo "$as_me:$LINENO: error: package version not specified" >&5
8069echo "$as_me: error: package version not specified" >&2;}
8070 { (exit 1); exit 1; }; } ;;
8071 no) PKGVERSION= ;;
8072 *) PKGVERSION="($withval) " ;;
8073 esac
8074else
8075 PKGVERSION="(GCC) "
8076
b61ff9c8 8077fi;
2f41c1d6
PB
8078
8079
8080
1a4b763e 8081
b61ff9c8 8082# Check whether --with-bugurl or --without-bugurl was given.
2f41c1d6 8083if test "${with_bugurl+set}" = set; then
b61ff9c8
BS
8084 withval="$with_bugurl"
8085 case "$withval" in
2f41c1d6
PB
8086 yes) { { echo "$as_me:$LINENO: error: bug URL not specified" >&5
8087echo "$as_me: error: bug URL not specified" >&2;}
8088 { (exit 1); exit 1; }; } ;;
8089 no) BUGURL=
8090 ;;
8091 *) BUGURL="$withval"
8092 ;;
8093 esac
8094else
8095 BUGURL="http://gcc.gnu.org/bugs.html"
8096
b61ff9c8 8097fi;
2f41c1d6
PB
8098 case ${BUGURL} in
8099 "")
8100 REPORT_BUGS_TO=
8101 REPORT_BUGS_TEXI=
8102 ;;
8103 *)
8104 REPORT_BUGS_TO="<$BUGURL>"
8105 REPORT_BUGS_TEXI=@uref{`echo "$BUGURL" | sed 's/@/@@/g'`}
8106 ;;
8107 esac;
8108
ab22c1fa 8109
d1bd0ded
GK
8110
8111
f3c9f174
NN
8112# Sanity check enable_languages in case someone does not run the toplevel
8113# configure # script.
b61ff9c8 8114# Check whether --enable-languages or --disable-languages was given.
f3c9f174 8115if test "${enable_languages+set}" = set; then
b61ff9c8
BS
8116 enableval="$enable_languages"
8117 case ,${enable_languages}, in
f3c9f174
NN
8118 ,,|,yes,)
8119 # go safe -- we cannot be much sure without the toplevel
8120 # configure's
8121 # analysis of which target libs are present and usable
8122 enable_languages=c
8123 ;;
8124 *,all,*)
8125 { { echo "$as_me:$LINENO: error: only the toplevel supports --enable-languages=all" >&5
8126echo "$as_me: error: only the toplevel supports --enable-languages=all" >&2;}
8127 { (exit 1); exit 1; }; }
8128 ;;
8129 *,c,*)
8130 ;;
8131 *)
8132 enable_languages=c,${enable_languages}
8133 ;;
8134esac
8135else
8136 enable_languages=c
b61ff9c8 8137fi;
f3c9f174 8138
9288b845
CD
8139# Used by documentation targets
8140
8141
8142
f3c9f174 8143
aca600aa
AS
8144
8145# Check whether --with-multilib-list or --without-multilib-list was given.
8146if test "${with_multilib_list+set}" = set; then
8147 withval="$with_multilib_list"
8148 :
8149else
8150 with_multilib_list=default
8151fi;
8152
73458fb7
NN
8153# -------------------------
8154# Checks for other programs
8155# -------------------------
5b67ad6f 8156
b61ff9c8
BS
8157echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5
8158echo $ECHO_N "checking whether ${MAKE-make} sets \$(MAKE)... $ECHO_C" >&6
8159set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,:./+-,___p_,'`
8160if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
ba479fd2 8161 echo $ECHO_N "(cached) $ECHO_C" >&6
e9a25f70 8162else
ba479fd2 8163 cat >conftest.make <<\_ACEOF
e9a25f70 8164all:
b61ff9c8 8165 @echo 'ac_maketemp="$(MAKE)"'
ba479fd2 8166_ACEOF
e9a25f70 8167# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
b61ff9c8
BS
8168eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
8169if test -n "$ac_maketemp"; then
8170 eval ac_cv_prog_make_${ac_make}_set=yes
8171else
8172 eval ac_cv_prog_make_${ac_make}_set=no
8173fi
ba479fd2 8174rm -f conftest.make
e9a25f70 8175fi
b61ff9c8
BS
8176if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
8177 echo "$as_me:$LINENO: result: yes" >&5
8178echo "${ECHO_T}yes" >&6
e9a25f70
JL
8179 SET_MAKE=
8180else
b61ff9c8
BS
8181 echo "$as_me:$LINENO: result: no" >&5
8182echo "${ECHO_T}no" >&6
e9a25f70
JL
8183 SET_MAKE="MAKE=${MAKE-make}"
8184fi
8185
8186
861bb6c1 8187# Find some useful tools
ba479fd2 8188for ac_prog in gawk mawk nawk awk
861bb6c1 8189do
ba479fd2 8190 # Extract the first word of "$ac_prog", so it can be a program name with args.
861bb6c1 8191set dummy $ac_prog; ac_word=$2
b61ff9c8
BS
8192echo "$as_me:$LINENO: checking for $ac_word" >&5
8193echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
ba479fd2
NN
8194if test "${ac_cv_prog_AWK+set}" = set; then
8195 echo $ECHO_N "(cached) $ECHO_C" >&6
861bb6c1
JL
8196else
8197 if test -n "$AWK"; then
8198 ac_cv_prog_AWK="$AWK" # Let the user override the test.
8199else
ba479fd2
NN
8200as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8201for as_dir in $PATH
8202do
8203 IFS=$as_save_IFS
8204 test -z "$as_dir" && as_dir=.
8205 for ac_exec_ext in '' $ac_executable_extensions; do
b61ff9c8 8206 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ba479fd2
NN
8207 ac_cv_prog_AWK="$ac_prog"
8208 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
8209 break 2
8210 fi
8211done
8212done
8213
861bb6c1
JL
8214fi
8215fi
ba479fd2 8216AWK=$ac_cv_prog_AWK
861bb6c1 8217if test -n "$AWK"; then
b61ff9c8
BS
8218 echo "$as_me:$LINENO: result: $AWK" >&5
8219echo "${ECHO_T}$AWK" >&6
861bb6c1 8220else
b61ff9c8
BS
8221 echo "$as_me:$LINENO: result: no" >&5
8222echo "${ECHO_T}no" >&6
861bb6c1
JL
8223fi
8224
ba479fd2 8225 test -n "$AWK" && break
861bb6c1
JL
8226done
8227
776dc15d 8228# We need awk to create options.c and options.h.
2c4902b9
NN
8229# Bail out if it's missing.
8230case ${AWK} in
ba479fd2
NN
8231 "") { { echo "$as_me:$LINENO: error: can't build without awk, bailing out" >&5
8232echo "$as_me: error: can't build without awk, bailing out" >&2;}
8233 { (exit 1); exit 1; }; } ;;
2c4902b9
NN
8234esac
8235
b61ff9c8
BS
8236echo "$as_me:$LINENO: checking whether ln -s works" >&5
8237echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
ba479fd2
NN
8238if test "${gcc_cv_prog_LN_S+set}" = set; then
8239 echo $ECHO_N "(cached) $ECHO_C" >&6
0a4b6309
RL
8240else
8241 rm -f conftestdata_t
8242echo >conftestdata_f
8243if ln -s conftestdata_f conftestdata_t 2>/dev/null
8244then
8245 gcc_cv_prog_LN_S="ln -s"
8246else
8247 if ln conftestdata_f conftestdata_t 2>/dev/null
8248 then
8249 gcc_cv_prog_LN_S=ln
8250 else
35f06ae4
PB
8251 if cp -p conftestdata_f conftestdata_t 2>/dev/null
8252 then
06c3418c 8253 gcc_cv_prog_LN_S="cp -p"
35f06ae4
PB
8254 else
8255 gcc_cv_prog_LN_S=cp
8256 fi
0a4b6309
RL
8257 fi
8258fi
8259rm -f conftestdata_f conftestdata_t
8260
8261fi
8262LN_S="$gcc_cv_prog_LN_S"
8263if test "$gcc_cv_prog_LN_S" = "ln -s"; then
b61ff9c8
BS
8264 echo "$as_me:$LINENO: result: yes" >&5
8265echo "${ECHO_T}yes" >&6
0a4b6309
RL
8266else
8267 if test "$gcc_cv_prog_LN_S" = "ln"; then
b61ff9c8
BS
8268 echo "$as_me:$LINENO: result: no, using ln" >&5
8269echo "${ECHO_T}no, using ln" >&6
0a4b6309 8270 else
b61ff9c8
BS
8271 echo "$as_me:$LINENO: result: no, and neither does ln, so using $gcc_cv_prog_LN_S" >&5
8272echo "${ECHO_T}no, and neither does ln, so using $gcc_cv_prog_LN_S" >&6
0a4b6309
RL
8273 fi
8274fi
8275
b61ff9c8
BS
8276echo "$as_me:$LINENO: checking whether ln works" >&5
8277echo $ECHO_N "checking whether ln works... $ECHO_C" >&6
18fc9bd4
RG
8278if test "${acx_cv_prog_LN+set}" = set; then
8279 echo $ECHO_N "(cached) $ECHO_C" >&6
8280else
8281 rm -f conftestdata_t
8282echo >conftestdata_f
8283if ln conftestdata_f conftestdata_t 2>/dev/null
8284then
8285 acx_cv_prog_LN=ln
8286else
8287 acx_cv_prog_LN=no
8288fi
8289rm -f conftestdata_f conftestdata_t
8290
8291fi
8292if test $acx_cv_prog_LN = no; then
8293 LN="$LN_S"
b61ff9c8
BS
8294 echo "$as_me:$LINENO: result: no, using $LN" >&5
8295echo "${ECHO_T}no, using $LN" >&6
18fc9bd4
RG
8296else
8297 LN="$acx_cv_prog_LN"
b61ff9c8
BS
8298 echo "$as_me:$LINENO: result: yes" >&5
8299echo "${ECHO_T}yes" >&6
18fc9bd4
RG
8300fi
8301
ba479fd2
NN
8302if test -n "$ac_tool_prefix"; then
8303 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
8304set dummy ${ac_tool_prefix}ranlib; ac_word=$2
b61ff9c8
BS
8305echo "$as_me:$LINENO: checking for $ac_word" >&5
8306echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
ba479fd2
NN
8307if test "${ac_cv_prog_RANLIB+set}" = set; then
8308 echo $ECHO_N "(cached) $ECHO_C" >&6
861bb6c1
JL
8309else
8310 if test -n "$RANLIB"; then
8311 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
8312else
ba479fd2
NN
8313as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8314for as_dir in $PATH
8315do
8316 IFS=$as_save_IFS
8317 test -z "$as_dir" && as_dir=.
8318 for ac_exec_ext in '' $ac_executable_extensions; do
b61ff9c8 8319 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ba479fd2
NN
8320 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
8321 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
8322 break 2
8323 fi
8324done
8325done
8326
6e3f3080
NN
8327fi
8328fi
ba479fd2 8329RANLIB=$ac_cv_prog_RANLIB
6e3f3080 8330if test -n "$RANLIB"; then
b61ff9c8
BS
8331 echo "$as_me:$LINENO: result: $RANLIB" >&5
8332echo "${ECHO_T}$RANLIB" >&6
ba479fd2 8333else
b61ff9c8
BS
8334 echo "$as_me:$LINENO: result: no" >&5
8335echo "${ECHO_T}no" >&6
ba479fd2
NN
8336fi
8337
8338fi
8339if test -z "$ac_cv_prog_RANLIB"; then
8340 ac_ct_RANLIB=$RANLIB
8341 # Extract the first word of "ranlib", so it can be a program name with args.
8342set dummy ranlib; ac_word=$2
b61ff9c8
BS
8343echo "$as_me:$LINENO: checking for $ac_word" >&5
8344echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
ba479fd2
NN
8345if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
8346 echo $ECHO_N "(cached) $ECHO_C" >&6
8347else
8348 if test -n "$ac_ct_RANLIB"; then
8349 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
8350else
8351as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8352for as_dir in $PATH
8353do
8354 IFS=$as_save_IFS
8355 test -z "$as_dir" && as_dir=.
8356 for ac_exec_ext in '' $ac_executable_extensions; do
b61ff9c8 8357 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ba479fd2
NN
8358 ac_cv_prog_ac_ct_RANLIB="ranlib"
8359 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
8360 break 2
8361 fi
8362done
8363done
8364
b61ff9c8 8365 test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
ba479fd2
NN
8366fi
8367fi
8368ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
8369if test -n "$ac_ct_RANLIB"; then
b61ff9c8
BS
8370 echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
8371echo "${ECHO_T}$ac_ct_RANLIB" >&6
6e3f3080 8372else
b61ff9c8
BS
8373 echo "$as_me:$LINENO: result: no" >&5
8374echo "${ECHO_T}no" >&6
ba479fd2
NN
8375fi
8376
b61ff9c8 8377 RANLIB=$ac_ct_RANLIB
ba479fd2
NN
8378else
8379 RANLIB="$ac_cv_prog_RANLIB"
861bb6c1
JL
8380fi
8381
343a6100
MM
8382case "${host}" in
8383*-*-darwin*)
8384 # By default, the Darwin ranlib will not treat common symbols as
8385 # definitions when building the archive table of contents. Other
8386 # ranlibs do that; pass an option to the Darwin ranlib that makes
8387 # it behave similarly.
8388 ranlib_flags="-c"
8389 ;;
8390*)
8391 ranlib_flags=""
8392esac
8393
8394
0a4b6309
RL
8395# Find a good install program. We prefer a C program (faster),
8396# so one script is as good as another. But avoid the broken or
8397# incompatible versions:
8398# SysV /etc/install, /usr/sbin/install
8399# SunOS /usr/etc/install
8400# IRIX /sbin/install
8401# AIX /bin/install
8402# AFS /usr/afsws/bin/install, which mishandles nonexistent args
8403# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
8404# ./install, which can be erroneously created by make from ./install.sh.
b61ff9c8
BS
8405echo "$as_me:$LINENO: checking for a BSD compatible install" >&5
8406echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6
0a4b6309 8407if test -z "$INSTALL"; then
ba479fd2
NN
8408if test "${ac_cv_path_install+set}" = set; then
8409 echo $ECHO_N "(cached) $ECHO_C" >&6
0a4b6309
RL
8410else
8411 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="${IFS}:"
8412 for ac_dir in $PATH; do
8413 # Account for people who put trailing slashes in PATH elements.
8414 case "$ac_dir/" in
8415 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
8416 *)
8417 # OSF1 and SCO ODT 3.0 have their own names for install.
8418 for ac_prog in ginstall scoinst install; do
8419 if test -f $ac_dir/$ac_prog; then
8420 if test $ac_prog = install &&
8421 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
8422 # AIX install. It has an incompatible calling convention.
8423 # OSF/1 installbsd also uses dspmsg, but is usable.
8424 :
8425 else
8426 ac_cv_path_install="$ac_dir/$ac_prog -c"
8427 break 2
8428 fi
8429 fi
8430 done
8431 ;;
8432 esac
8433 done
8434 IFS="$ac_save_IFS"
8435
8436fi
8437 if test "${ac_cv_path_install+set}" = set; then
8438 INSTALL="$ac_cv_path_install"
8439 else
8440 # As a last resort, use the slow shell script. We don't cache a
8441 # path for INSTALL within a source directory, because that will
8442 # break other packages using the cache if that directory is
8443 # removed, or if the path is relative.
8444 INSTALL="$ac_install_sh"
8445 fi
8446fi
b61ff9c8
BS
8447echo "$as_me:$LINENO: result: $INSTALL" >&5
8448echo "${ECHO_T}$INSTALL" >&6
0a4b6309
RL
8449
8450# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
8451# It thinks the first close brace ends the variable substitution.
8452test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
8453
8454test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
8455
861bb6c1 8456
3a000df0 8457# See if cmp has --ignore-initial.
b61ff9c8
BS
8458echo "$as_me:$LINENO: checking for cmp's capabilities" >&5
8459echo $ECHO_N "checking for cmp's capabilities... $ECHO_C" >&6
ba479fd2
NN
8460if test "${gcc_cv_prog_cmp_skip+set}" = set; then
8461 echo $ECHO_N "(cached) $ECHO_C" >&6
3a000df0
KC
8462else
8463 echo abfoo >t1
8464 echo cdfoo >t2
269a7343 8465 gcc_cv_prog_cmp_skip=slowcompare
3a000df0
KC
8466 if cmp --ignore-initial=2 t1 t2 > /dev/null 2>&1; then
8467 if cmp --ignore-initial=1 t1 t2 > /dev/null 2>&1; then
269a7343 8468 :
3a000df0
KC
8469 else
8470 gcc_cv_prog_cmp_skip=gnucompare
8471 fi
269a7343
KG
8472 fi
8473 if test $gcc_cv_prog_cmp_skip = slowcompare ; then
8474 if cmp t1 t2 2 2 > /dev/null 2>&1; then
8475 if cmp t1 t2 1 1 > /dev/null 2>&1; then
8476 :
8477 else
8478 gcc_cv_prog_cmp_skip=fastcompare
8479 fi
8480 fi
3a000df0
KC
8481 fi
8482 rm t1 t2
8483
8484fi
b61ff9c8
BS
8485echo "$as_me:$LINENO: result: $gcc_cv_prog_cmp_skip" >&5
8486echo "${ECHO_T}$gcc_cv_prog_cmp_skip" >&6
3a000df0
KC
8487make_compare_target=$gcc_cv_prog_cmp_skip
8488
8489
8490
73458fb7
NN
8491# See if we have the mktemp command.
8492# Extract the first word of "mktemp", so it can be a program name with args.
8493set dummy mktemp; ac_word=$2
b61ff9c8
BS
8494echo "$as_me:$LINENO: checking for $ac_word" >&5
8495echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
ba479fd2
NN
8496if test "${ac_cv_prog_have_mktemp_command+set}" = set; then
8497 echo $ECHO_N "(cached) $ECHO_C" >&6
73458fb7
NN
8498else
8499 if test -n "$have_mktemp_command"; then
8500 ac_cv_prog_have_mktemp_command="$have_mktemp_command" # Let the user override the test.
8501else
ba479fd2
NN
8502as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8503for as_dir in $PATH
8504do
8505 IFS=$as_save_IFS
8506 test -z "$as_dir" && as_dir=.
8507 for ac_exec_ext in '' $ac_executable_extensions; do
b61ff9c8 8508 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ba479fd2
NN
8509 ac_cv_prog_have_mktemp_command="yes"
8510 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
8511 break 2
8512 fi
8513done
8514done
8515
73458fb7
NN
8516 test -z "$ac_cv_prog_have_mktemp_command" && ac_cv_prog_have_mktemp_command="no"
8517fi
8518fi
ba479fd2 8519have_mktemp_command=$ac_cv_prog_have_mktemp_command
73458fb7 8520if test -n "$have_mktemp_command"; then
b61ff9c8
BS
8521 echo "$as_me:$LINENO: result: $have_mktemp_command" >&5
8522echo "${ECHO_T}$have_mktemp_command" >&6
73458fb7 8523else
b61ff9c8
BS
8524 echo "$as_me:$LINENO: result: no" >&5
8525echo "${ECHO_T}no" >&6
73458fb7
NN
8526fi
8527
8528
7c27e184
PB
8529# See if makeinfo has been installed and is modern enough
8530# that we can use it.
9f18db39 8531
3bbd5a19 8532 # Extract the first word of "makeinfo", so it can be a program name with args.
73458fb7 8533set dummy makeinfo; ac_word=$2
b61ff9c8
BS
8534echo "$as_me:$LINENO: checking for $ac_word" >&5
8535echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
ba479fd2
NN
8536if test "${ac_cv_prog_MAKEINFO+set}" = set; then
8537 echo $ECHO_N "(cached) $ECHO_C" >&6
73458fb7
NN
8538else
8539 if test -n "$MAKEINFO"; then
8540 ac_cv_prog_MAKEINFO="$MAKEINFO" # Let the user override the test.
8541else
ba479fd2
NN
8542as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8543for as_dir in $PATH
8544do
8545 IFS=$as_save_IFS
8546 test -z "$as_dir" && as_dir=.
8547 for ac_exec_ext in '' $ac_executable_extensions; do
b61ff9c8 8548 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ba479fd2
NN
8549 ac_cv_prog_MAKEINFO="makeinfo"
8550 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
8551 break 2
8552 fi
8553done
8554done
8555
73458fb7
NN
8556fi
8557fi
ba479fd2 8558MAKEINFO=$ac_cv_prog_MAKEINFO
73458fb7 8559if test -n "$MAKEINFO"; then
b61ff9c8
BS
8560 echo "$as_me:$LINENO: result: $MAKEINFO" >&5
8561echo "${ECHO_T}$MAKEINFO" >&6
73458fb7 8562else
b61ff9c8
BS
8563 echo "$as_me:$LINENO: result: no" >&5
8564echo "${ECHO_T}no" >&6
73458fb7
NN
8565fi
8566
3bbd5a19
PB
8567 if test -n "$MAKEINFO"; then
8568 # Found it, now check the version.
b61ff9c8
BS
8569 echo "$as_me:$LINENO: checking for modern makeinfo" >&5
8570echo $ECHO_N "checking for modern makeinfo... $ECHO_C" >&6
ba479fd2
NN
8571if test "${gcc_cv_prog_makeinfo_modern+set}" = set; then
8572 echo $ECHO_N "(cached) $ECHO_C" >&6
73458fb7 8573else
3bbd5a19
PB
8574 ac_prog_version=`eval $MAKEINFO --version 2>&1 |
8575 sed -n 's/^.*GNU texinfo.* \([0-9][0-9.]*\).*$/\1/p'`
8576
8577 case $ac_prog_version in
8578 '') gcc_cv_prog_makeinfo_modern=no;;
7326a39e 8579 4.[7-9]*|4.[1-9][0-9]*|[5-9]*|[1-9][0-9]*) gcc_cv_prog_makeinfo_modern=yes;;
3bbd5a19
PB
8580 *) gcc_cv_prog_makeinfo_modern=no;;
8581 esac
73458fb7
NN
8582
8583fi
b61ff9c8
BS
8584echo "$as_me:$LINENO: result: $gcc_cv_prog_makeinfo_modern" >&5
8585echo "${ECHO_T}$gcc_cv_prog_makeinfo_modern" >&6
3bbd5a19
PB
8586 else
8587 gcc_cv_prog_makeinfo_modern=no
8588 fi
8589 if test $gcc_cv_prog_makeinfo_modern = no; then
8590 MAKEINFO="${CONFIG_SHELL-/bin/sh} $ac_aux_dir/missing makeinfo"
8591 fi
73458fb7 8592
73458fb7 8593if test $gcc_cv_prog_makeinfo_modern = no; then
ba479fd2
NN
8594 { echo "$as_me:$LINENO: WARNING:
8595*** Makeinfo is missing or too old.
8596*** Info documentation will not be built." >&5
8597echo "$as_me: WARNING:
cafe096b 8598*** Makeinfo is missing or too old.
ba479fd2 8599*** Info documentation will not be built." >&2;}
73458fb7
NN
8600 BUILD_INFO=
8601else
ba479fd2 8602 BUILD_INFO=info
73458fb7
NN
8603fi
8604
7c27e184 8605
73458fb7 8606# Is pod2man recent enough to regenerate manpages?
b61ff9c8
BS
8607echo "$as_me:$LINENO: checking for recent Pod::Man" >&5
8608echo $ECHO_N "checking for recent Pod::Man... $ECHO_C" >&6
73458fb7 8609if (perl -e 'use 1.10 Pod::Man') >/dev/null 2>&1; then
b61ff9c8
BS
8610 echo "$as_me:$LINENO: result: yes" >&5
8611echo "${ECHO_T}yes" >&6
ba479fd2 8612 GENERATED_MANPAGES=generated-manpages
73458fb7 8613else
b61ff9c8
BS
8614 echo "$as_me:$LINENO: result: no" >&5
8615echo "${ECHO_T}no" >&6
73458fb7
NN
8616 GENERATED_MANPAGES=
8617fi
8618
7c27e184 8619
3bbd5a19
PB
8620MISSING="${CONFIG_SHELL-/bin/sh} $ac_aux_dir/missing"
8621
73458fb7 8622# How about lex?
7c27e184
PB
8623for ac_prog in flex
8624do
8625 # Extract the first word of "$ac_prog", so it can be a program name with args.
8626set dummy $ac_prog; ac_word=$2
b61ff9c8
BS
8627echo "$as_me:$LINENO: checking for $ac_word" >&5
8628echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
ba479fd2
NN
8629if test "${ac_cv_prog_FLEX+set}" = set; then
8630 echo $ECHO_N "(cached) $ECHO_C" >&6
73458fb7
NN
8631else
8632 if test -n "$FLEX"; then
8633 ac_cv_prog_FLEX="$FLEX" # Let the user override the test.
8634else
ba479fd2
NN
8635as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8636for as_dir in $PATH
8637do
8638 IFS=$as_save_IFS
8639 test -z "$as_dir" && as_dir=.
8640 for ac_exec_ext in '' $ac_executable_extensions; do
b61ff9c8 8641 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7c27e184 8642 ac_cv_prog_FLEX="$ac_prog"
ba479fd2
NN
8643 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
8644 break 2
8645 fi
8646done
8647done
8648
73458fb7
NN
8649fi
8650fi
ba479fd2 8651FLEX=$ac_cv_prog_FLEX
73458fb7 8652if test -n "$FLEX"; then
b61ff9c8
BS
8653 echo "$as_me:$LINENO: result: $FLEX" >&5
8654echo "${ECHO_T}$FLEX" >&6
73458fb7 8655else
b61ff9c8
BS
8656 echo "$as_me:$LINENO: result: no" >&5
8657echo "${ECHO_T}no" >&6
73458fb7
NN
8658fi
8659
7c27e184
PB
8660 test -n "$FLEX" && break
8661done
8662test -n "$FLEX" || FLEX="$MISSING flex"
8663
73458fb7
NN
8664
8665# Bison?
7c27e184
PB
8666for ac_prog in bison
8667do
8668 # Extract the first word of "$ac_prog", so it can be a program name with args.
8669set dummy $ac_prog; ac_word=$2
b61ff9c8
BS
8670echo "$as_me:$LINENO: checking for $ac_word" >&5
8671echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
ba479fd2
NN
8672if test "${ac_cv_prog_BISON+set}" = set; then
8673 echo $ECHO_N "(cached) $ECHO_C" >&6
73458fb7
NN
8674else
8675 if test -n "$BISON"; then
8676 ac_cv_prog_BISON="$BISON" # Let the user override the test.
8677else
ba479fd2
NN
8678as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8679for as_dir in $PATH
8680do
8681 IFS=$as_save_IFS
8682 test -z "$as_dir" && as_dir=.
8683 for ac_exec_ext in '' $ac_executable_extensions; do
b61ff9c8 8684 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7c27e184 8685 ac_cv_prog_BISON="$ac_prog"
ba479fd2
NN
8686 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
8687 break 2
8688 fi
8689done
8690done
8691
73458fb7
NN
8692fi
8693fi
ba479fd2 8694BISON=$ac_cv_prog_BISON
73458fb7 8695if test -n "$BISON"; then
b61ff9c8
BS
8696 echo "$as_me:$LINENO: result: $BISON" >&5
8697echo "${ECHO_T}$BISON" >&6
73458fb7 8698else
b61ff9c8
BS
8699 echo "$as_me:$LINENO: result: no" >&5
8700echo "${ECHO_T}no" >&6
73458fb7
NN
8701fi
8702
7c27e184
PB
8703 test -n "$BISON" && break
8704done
8705test -n "$BISON" || BISON="$MISSING bison"
8706
8707
8708# Binutils are not build modules, unlike bison/flex/makeinfo. So we
8709# check for build == host before using them.
73458fb7 8710
f6a874ac 8711# NM
414adbdd
GK
8712if test x${build} = x${host} && test -f $srcdir/../binutils/nm.c \
8713 && test -d ../binutils ; then
f6a874ac
JW
8714 NM='$(objdir)/../binutils/nm-new'
8715else
8716 # Extract the first word of "nm", so it can be a program name with args.
8717set dummy nm; ac_word=$2
b61ff9c8
BS
8718echo "$as_me:$LINENO: checking for $ac_word" >&5
8719echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
f6a874ac
JW
8720if test "${ac_cv_prog_NM+set}" = set; then
8721 echo $ECHO_N "(cached) $ECHO_C" >&6
8722else
8723 if test -n "$NM"; then
8724 ac_cv_prog_NM="$NM" # Let the user override the test.
8725else
8726as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8727for as_dir in $PATH
8728do
8729 IFS=$as_save_IFS
8730 test -z "$as_dir" && as_dir=.
8731 for ac_exec_ext in '' $ac_executable_extensions; do
b61ff9c8 8732 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
f6a874ac
JW
8733 ac_cv_prog_NM="nm"
8734 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
8735 break 2
8736 fi
8737done
8738done
8739
8740 test -z "$ac_cv_prog_NM" && ac_cv_prog_NM="${CONFIG_SHELL-/bin/sh} ${srcdir}/../missing nm"
8741fi
8742fi
8743NM=$ac_cv_prog_NM
8744if test -n "$NM"; then
b61ff9c8
BS
8745 echo "$as_me:$LINENO: result: $NM" >&5
8746echo "${ECHO_T}$NM" >&6
f6a874ac 8747else
b61ff9c8
BS
8748 echo "$as_me:$LINENO: result: no" >&5
8749echo "${ECHO_T}no" >&6
f6a874ac
JW
8750fi
8751
8752fi
8753
8754# AR
414adbdd
GK
8755if test x${build} = x${host} && test -f $srcdir/../binutils/ar.c \
8756 && test -d ../binutils ; then
f6a874ac
JW
8757 AR='$(objdir)/../binutils/ar'
8758else
8759 # Extract the first word of "ar", so it can be a program name with args.
8760set dummy ar; ac_word=$2
b61ff9c8
BS
8761echo "$as_me:$LINENO: checking for $ac_word" >&5
8762echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
f6a874ac
JW
8763if test "${ac_cv_prog_AR+set}" = set; then
8764 echo $ECHO_N "(cached) $ECHO_C" >&6
8765else
8766 if test -n "$AR"; then
8767 ac_cv_prog_AR="$AR" # Let the user override the test.
8768else
8769as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8770for as_dir in $PATH
8771do
8772 IFS=$as_save_IFS
8773 test -z "$as_dir" && as_dir=.
8774 for ac_exec_ext in '' $ac_executable_extensions; do
b61ff9c8 8775 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
f6a874ac
JW
8776 ac_cv_prog_AR="ar"
8777 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
8778 break 2
8779 fi
8780done
8781done
8782
8783 test -z "$ac_cv_prog_AR" && ac_cv_prog_AR="${CONFIG_SHELL-/bin/sh} ${srcdir}/../missing ar"
8784fi
8785fi
8786AR=$ac_cv_prog_AR
8787if test -n "$AR"; then
b61ff9c8
BS
8788 echo "$as_me:$LINENO: result: $AR" >&5
8789echo "${ECHO_T}$AR" >&6
f6a874ac 8790else
b61ff9c8
BS
8791 echo "$as_me:$LINENO: result: no" >&5
8792echo "${ECHO_T}no" >&6
f6a874ac
JW
8793fi
8794
8795fi
8796
8797
73458fb7
NN
8798# --------------------
8799# Checks for C headers
8800# --------------------
8801
ca9bc441
NN
8802# Need to reject headers which give warnings, so that the -Werror bootstrap
8803# works later. *sigh* This needs to come before all header checks.
18fc9bd4 8804
ca9bc441
NN
8805ac_c_preproc_warn_flag=yes
8806
b61ff9c8
BS
8807echo "$as_me:$LINENO: checking for ANSI C header files" >&5
8808echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
ba479fd2
NN
8809if test "${ac_cv_header_stdc+set}" = set; then
8810 echo $ECHO_N "(cached) $ECHO_C" >&6
956d6950 8811else
ba479fd2 8812 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
8813/* confdefs.h. */
8814_ACEOF
8815cat confdefs.h >>conftest.$ac_ext
8816cat >>conftest.$ac_ext <<_ACEOF
8817/* end confdefs.h. */
956d6950
JL
8818#include <stdlib.h>
8819#include <stdarg.h>
8820#include <string.h>
8821#include <float.h>
ba479fd2
NN
8822
8823int
8824main ()
8825{
8826
8827 ;
8828 return 0;
8829}
8830_ACEOF
8831rm -f conftest.$ac_objext
b61ff9c8
BS
8832if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8833 (eval $ac_compile) 2>conftest.er1
ba479fd2 8834 ac_status=$?
86da66b5
HPN
8835 grep -v '^ *+' conftest.er1 >conftest.err
8836 rm -f conftest.er1
8837 cat conftest.err >&5
ba479fd2 8838 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
8839 (exit $ac_status); } &&
8840 { ac_try='test -z "$ac_c_werror_flag"
8841 || test ! -s conftest.err'
8842 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8843 (eval $ac_try) 2>&5
8844 ac_status=$?
8845 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8846 (exit $ac_status); }; } &&
8847 { ac_try='test -s conftest.$ac_objext'
8848 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8849 (eval $ac_try) 2>&5
8850 ac_status=$?
8851 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8852 (exit $ac_status); }; }; then
956d6950
JL
8853 ac_cv_header_stdc=yes
8854else
ba479fd2
NN
8855 echo "$as_me: failed program was:" >&5
8856sed 's/^/| /' conftest.$ac_ext >&5
8857
b61ff9c8 8858ac_cv_header_stdc=no
956d6950 8859fi
b61ff9c8 8860rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
956d6950
JL
8861
8862if test $ac_cv_header_stdc = yes; then
8863 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
ba479fd2 8864 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
8865/* confdefs.h. */
8866_ACEOF
8867cat confdefs.h >>conftest.$ac_ext
8868cat >>conftest.$ac_ext <<_ACEOF
8869/* end confdefs.h. */
956d6950 8870#include <string.h>
ba479fd2
NN
8871
8872_ACEOF
956d6950 8873if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
ba479fd2 8874 $EGREP "memchr" >/dev/null 2>&1; then
956d6950
JL
8875 :
8876else
956d6950
JL
8877 ac_cv_header_stdc=no
8878fi
8879rm -f conftest*
8880
8881fi
8882
8883if test $ac_cv_header_stdc = yes; then
8884 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
ba479fd2 8885 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
8886/* confdefs.h. */
8887_ACEOF
8888cat confdefs.h >>conftest.$ac_ext
8889cat >>conftest.$ac_ext <<_ACEOF
8890/* end confdefs.h. */
956d6950 8891#include <stdlib.h>
ba479fd2
NN
8892
8893_ACEOF
956d6950 8894if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
ba479fd2 8895 $EGREP "free" >/dev/null 2>&1; then
956d6950
JL
8896 :
8897else
956d6950
JL
8898 ac_cv_header_stdc=no
8899fi
8900rm -f conftest*
8901
8902fi
8903
8904if test $ac_cv_header_stdc = yes; then
8905 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
ba479fd2 8906 if test "$cross_compiling" = yes; then
956d6950
JL
8907 :
8908else
ba479fd2 8909 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
8910/* confdefs.h. */
8911_ACEOF
8912cat confdefs.h >>conftest.$ac_ext
8913cat >>conftest.$ac_ext <<_ACEOF
8914/* end confdefs.h. */
956d6950 8915#include <ctype.h>
ba479fd2
NN
8916#if ((' ' & 0x0FF) == 0x020)
8917# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
8918# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
8919#else
8920# define ISLOWER(c) \
86da66b5
HPN
8921 (('a' <= (c) && (c) <= 'i') \
8922 || ('j' <= (c) && (c) <= 'r') \
8923 || ('s' <= (c) && (c) <= 'z'))
ba479fd2
NN
8924# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
8925#endif
63cf211a 8926
ba479fd2
NN
8927#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
8928int
8929main ()
8930{
8931 int i;
8932 for (i = 0; i < 256; i++)
8933 if (XOR (islower (i), ISLOWER (i))
86da66b5 8934 || toupper (i) != TOUPPER (i))
b61ff9c8
BS
8935 exit(2);
8936 exit (0);
ba479fd2
NN
8937}
8938_ACEOF
8939rm -f conftest$ac_exeext
b61ff9c8
BS
8940if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8941 (eval $ac_link) 2>&5
ba479fd2
NN
8942 ac_status=$?
8943 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8944 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
b61ff9c8
BS
8945 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8946 (eval $ac_try) 2>&5
ba479fd2
NN
8947 ac_status=$?
8948 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8949 (exit $ac_status); }; }; then
956d6950
JL
8950 :
8951else
ba479fd2
NN
8952 echo "$as_me: program exited with status $ac_status" >&5
8953echo "$as_me: failed program was:" >&5
8954sed 's/^/| /' conftest.$ac_ext >&5
8955
8956( exit $ac_status )
8957ac_cv_header_stdc=no
956d6950 8958fi
b61ff9c8 8959rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
956d6950 8960fi
956d6950
JL
8961fi
8962fi
b61ff9c8
BS
8963echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
8964echo "${ECHO_T}$ac_cv_header_stdc" >&6
63cf211a 8965if test $ac_cv_header_stdc = yes; then
ba479fd2
NN
8966
8967cat >>confdefs.h <<\_ACEOF
956d6950 8968#define STDC_HEADERS 1
ba479fd2 8969_ACEOF
956d6950
JL
8970
8971fi
8972
b61ff9c8
BS
8973echo "$as_me:$LINENO: checking whether time.h and sys/time.h may both be included" >&5
8974echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
ba479fd2
NN
8975if test "${ac_cv_header_time+set}" = set; then
8976 echo $ECHO_N "(cached) $ECHO_C" >&6
956d6950 8977else
ba479fd2 8978 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
8979/* confdefs.h. */
8980_ACEOF
8981cat confdefs.h >>conftest.$ac_ext
8982cat >>conftest.$ac_ext <<_ACEOF
8983/* end confdefs.h. */
956d6950
JL
8984#include <sys/types.h>
8985#include <sys/time.h>
8986#include <time.h>
ba479fd2
NN
8987
8988int
8989main ()
8990{
8991if ((struct tm *) 0)
8992return 0;
8993 ;
8994 return 0;
8995}
8996_ACEOF
8997rm -f conftest.$ac_objext
b61ff9c8
BS
8998if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8999 (eval $ac_compile) 2>conftest.er1
ba479fd2 9000 ac_status=$?
86da66b5
HPN
9001 grep -v '^ *+' conftest.er1 >conftest.err
9002 rm -f conftest.er1
9003 cat conftest.err >&5
ba479fd2 9004 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
9005 (exit $ac_status); } &&
9006 { ac_try='test -z "$ac_c_werror_flag"
9007 || test ! -s conftest.err'
9008 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9009 (eval $ac_try) 2>&5
9010 ac_status=$?
9011 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9012 (exit $ac_status); }; } &&
9013 { ac_try='test -s conftest.$ac_objext'
9014 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9015 (eval $ac_try) 2>&5
9016 ac_status=$?
9017 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9018 (exit $ac_status); }; }; then
956d6950
JL
9019 ac_cv_header_time=yes
9020else
ba479fd2
NN
9021 echo "$as_me: failed program was:" >&5
9022sed 's/^/| /' conftest.$ac_ext >&5
9023
b61ff9c8 9024ac_cv_header_time=no
956d6950 9025fi
b61ff9c8 9026rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
956d6950 9027fi
b61ff9c8
BS
9028echo "$as_me:$LINENO: result: $ac_cv_header_time" >&5
9029echo "${ECHO_T}$ac_cv_header_time" >&6
63cf211a 9030if test $ac_cv_header_time = yes; then
ba479fd2
NN
9031
9032cat >>confdefs.h <<\_ACEOF
956d6950 9033#define TIME_WITH_SYS_TIME 1
ba479fd2 9034_ACEOF
956d6950
JL
9035
9036fi
9037
b61ff9c8
BS
9038echo "$as_me:$LINENO: checking whether string.h and strings.h may both be included" >&5
9039echo $ECHO_N "checking whether string.h and strings.h may both be included... $ECHO_C" >&6
18fc9bd4
RG
9040if test "${gcc_cv_header_string+set}" = set; then
9041 echo $ECHO_N "(cached) $ECHO_C" >&6
9042else
9043 cat >conftest.$ac_ext <<_ACEOF
9044/* confdefs.h. */
9045_ACEOF
9046cat confdefs.h >>conftest.$ac_ext
9047cat >>conftest.$ac_ext <<_ACEOF
9048/* end confdefs.h. */
9049#include <string.h>
9050#include <strings.h>
9051int
9052main ()
9053{
9054
9055 ;
9056 return 0;
9057}
9058_ACEOF
9059rm -f conftest.$ac_objext
b61ff9c8
BS
9060if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9061 (eval $ac_compile) 2>conftest.er1
18fc9bd4
RG
9062 ac_status=$?
9063 grep -v '^ *+' conftest.er1 >conftest.err
9064 rm -f conftest.er1
9065 cat conftest.err >&5
9066 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
9067 (exit $ac_status); } &&
9068 { ac_try='test -z "$ac_c_werror_flag"
9069 || test ! -s conftest.err'
9070 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9071 (eval $ac_try) 2>&5
9072 ac_status=$?
9073 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9074 (exit $ac_status); }; } &&
9075 { ac_try='test -s conftest.$ac_objext'
9076 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9077 (eval $ac_try) 2>&5
9078 ac_status=$?
9079 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9080 (exit $ac_status); }; }; then
18fc9bd4
RG
9081 gcc_cv_header_string=yes
9082else
9083 echo "$as_me: failed program was:" >&5
9084sed 's/^/| /' conftest.$ac_ext >&5
9085
b61ff9c8 9086gcc_cv_header_string=no
18fc9bd4 9087fi
b61ff9c8 9088rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18fc9bd4 9089fi
b61ff9c8
BS
9090echo "$as_me:$LINENO: result: $gcc_cv_header_string" >&5
9091echo "${ECHO_T}$gcc_cv_header_string" >&6
18fc9bd4
RG
9092if test $gcc_cv_header_string = yes; then
9093
9094cat >>confdefs.h <<\_ACEOF
9095#define STRING_WITH_STRINGS 1
9096_ACEOF
9097
9098fi
9099
b61ff9c8
BS
9100echo "$as_me:$LINENO: checking for sys/wait.h that is POSIX.1 compatible" >&5
9101echo $ECHO_N "checking for sys/wait.h that is POSIX.1 compatible... $ECHO_C" >&6
ba479fd2
NN
9102if test "${ac_cv_header_sys_wait_h+set}" = set; then
9103 echo $ECHO_N "(cached) $ECHO_C" >&6
e9831ca0 9104else
ba479fd2 9105 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
9106/* confdefs.h. */
9107_ACEOF
9108cat confdefs.h >>conftest.$ac_ext
9109cat >>conftest.$ac_ext <<_ACEOF
9110/* end confdefs.h. */
e9831ca0
KG
9111#include <sys/types.h>
9112#include <sys/wait.h>
9113#ifndef WEXITSTATUS
b61ff9c8 9114# define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
e9831ca0
KG
9115#endif
9116#ifndef WIFEXITED
ba479fd2 9117# define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
e9831ca0 9118#endif
ba479fd2
NN
9119
9120int
9121main ()
9122{
9123 int s;
9124 wait (&s);
9125 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
9126 ;
9127 return 0;
9128}
9129_ACEOF
9130rm -f conftest.$ac_objext
b61ff9c8
BS
9131if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9132 (eval $ac_compile) 2>conftest.er1
ba479fd2 9133 ac_status=$?
86da66b5
HPN
9134 grep -v '^ *+' conftest.er1 >conftest.err
9135 rm -f conftest.er1
9136 cat conftest.err >&5
ba479fd2 9137 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
9138 (exit $ac_status); } &&
9139 { ac_try='test -z "$ac_c_werror_flag"
9140 || test ! -s conftest.err'
9141 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9142 (eval $ac_try) 2>&5
9143 ac_status=$?
9144 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9145 (exit $ac_status); }; } &&
9146 { ac_try='test -s conftest.$ac_objext'
9147 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9148 (eval $ac_try) 2>&5
9149 ac_status=$?
9150 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9151 (exit $ac_status); }; }; then
e9831ca0
KG
9152 ac_cv_header_sys_wait_h=yes
9153else
ba479fd2
NN
9154 echo "$as_me: failed program was:" >&5
9155sed 's/^/| /' conftest.$ac_ext >&5
9156
b61ff9c8 9157ac_cv_header_sys_wait_h=no
e9831ca0 9158fi
b61ff9c8 9159rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
e9831ca0 9160fi
b61ff9c8
BS
9161echo "$as_me:$LINENO: result: $ac_cv_header_sys_wait_h" >&5
9162echo "${ECHO_T}$ac_cv_header_sys_wait_h" >&6
63cf211a 9163if test $ac_cv_header_sys_wait_h = yes; then
ba479fd2
NN
9164
9165cat >>confdefs.h <<\_ACEOF
e9831ca0 9166#define HAVE_SYS_WAIT_H 1
ba479fd2 9167_ACEOF
6e3f3080 9168
63cf211a 9169fi
6e3f3080 9170
ba479fd2
NN
9171
9172
9173
9174
9175
9176
9177
9178
9179
9180
9181
9182
9183
9184
9185
9186
9187
9188
9189
9190
9191
dfb77e37
KC
9192
9193for ac_header in limits.h stddef.h string.h strings.h stdlib.h time.h iconv.h \
1072ec3f 9194 fcntl.h unistd.h sys/file.h sys/time.h sys/mman.h \
03c41c05 9195 sys/resource.h sys/param.h sys/times.h sys/stat.h \
56694dd9 9196 direct.h malloc.h langinfo.h ldfcn.h locale.h wchar.h
861bb6c1 9197do
ba479fd2 9198as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
b61ff9c8
BS
9199echo "$as_me:$LINENO: checking for $ac_header" >&5
9200echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9201if eval "test \"\${$as_ac_Header+set}\" = set"; then
ba479fd2 9202 echo $ECHO_N "(cached) $ECHO_C" >&6
ba479fd2 9203else
18fc9bd4 9204 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
9205/* confdefs.h. */
9206_ACEOF
9207cat confdefs.h >>conftest.$ac_ext
9208cat >>conftest.$ac_ext <<_ACEOF
9209/* end confdefs.h. */
9210#include <$ac_header>
9211_ACEOF
b61ff9c8
BS
9212if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9213 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
ba479fd2
NN
9214 ac_status=$?
9215 grep -v '^ *+' conftest.er1 >conftest.err
9216 rm -f conftest.er1
9217 cat conftest.err >&5
9218 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
9219 (exit $ac_status); } >/dev/null; then
9220 if test -s conftest.err; then
9221 ac_cpp_err=$ac_c_preproc_warn_flag
9222 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
9223 else
9224 ac_cpp_err=
9225 fi
9226else
9227 ac_cpp_err=yes
9228fi
9229if test -z "$ac_cpp_err"; then
18fc9bd4 9230 eval "$as_ac_Header=yes"
ba479fd2
NN
9231else
9232 echo "$as_me: failed program was:" >&5
9233sed 's/^/| /' conftest.$ac_ext >&5
9234
18fc9bd4 9235 eval "$as_ac_Header=no"
ba479fd2
NN
9236fi
9237rm -f conftest.err conftest.$ac_ext
6e3f3080 9238fi
b61ff9c8
BS
9239echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9240echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
ba479fd2
NN
9241if test `eval echo '${'$as_ac_Header'}'` = yes; then
9242 cat >>confdefs.h <<_ACEOF
9243#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9244_ACEOF
9245
956d6950
JL
9246fi
9247done
9248
9249
f24af81b 9250# Check for thread headers.
b61ff9c8
BS
9251echo "$as_me:$LINENO: checking for thread.h" >&5
9252echo $ECHO_N "checking for thread.h... $ECHO_C" >&6
ba479fd2
NN
9253if test "${ac_cv_header_thread_h+set}" = set; then
9254 echo $ECHO_N "(cached) $ECHO_C" >&6
ba479fd2 9255else
18fc9bd4 9256 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
9257/* confdefs.h. */
9258_ACEOF
9259cat confdefs.h >>conftest.$ac_ext
9260cat >>conftest.$ac_ext <<_ACEOF
9261/* end confdefs.h. */
9262#include <thread.h>
9263_ACEOF
b61ff9c8
BS
9264if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9265 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
ba479fd2
NN
9266 ac_status=$?
9267 grep -v '^ *+' conftest.er1 >conftest.err
9268 rm -f conftest.er1
9269 cat conftest.err >&5
9270 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
9271 (exit $ac_status); } >/dev/null; then
9272 if test -s conftest.err; then
9273 ac_cpp_err=$ac_c_preproc_warn_flag
9274 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
9275 else
9276 ac_cpp_err=
9277 fi
9278else
9279 ac_cpp_err=yes
9280fi
9281if test -z "$ac_cpp_err"; then
18fc9bd4 9282 ac_cv_header_thread_h=yes
ba479fd2
NN
9283else
9284 echo "$as_me: failed program was:" >&5
9285sed 's/^/| /' conftest.$ac_ext >&5
9286
18fc9bd4 9287 ac_cv_header_thread_h=no
ba479fd2
NN
9288fi
9289rm -f conftest.err conftest.$ac_ext
6e3f3080 9290fi
b61ff9c8
BS
9291echo "$as_me:$LINENO: result: $ac_cv_header_thread_h" >&5
9292echo "${ECHO_T}$ac_cv_header_thread_h" >&6
ba479fd2 9293if test $ac_cv_header_thread_h = yes; then
f24af81b
TT
9294 have_thread_h=yes
9295else
ba479fd2 9296 have_thread_h=
f24af81b
TT
9297fi
9298
b61ff9c8
BS
9299echo "$as_me:$LINENO: checking for pthread.h" >&5
9300echo $ECHO_N "checking for pthread.h... $ECHO_C" >&6
ba479fd2
NN
9301if test "${ac_cv_header_pthread_h+set}" = set; then
9302 echo $ECHO_N "(cached) $ECHO_C" >&6
0f57bf40 9303else
18fc9bd4 9304 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
9305/* confdefs.h. */
9306_ACEOF
9307cat confdefs.h >>conftest.$ac_ext
9308cat >>conftest.$ac_ext <<_ACEOF
9309/* end confdefs.h. */
9310#include <pthread.h>
9311_ACEOF
b61ff9c8
BS
9312if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9313 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
ba479fd2
NN
9314 ac_status=$?
9315 grep -v '^ *+' conftest.er1 >conftest.err
9316 rm -f conftest.er1
9317 cat conftest.err >&5
9318 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
9319 (exit $ac_status); } >/dev/null; then
9320 if test -s conftest.err; then
9321 ac_cpp_err=$ac_c_preproc_warn_flag
9322 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
9323 else
9324 ac_cpp_err=
9325 fi
9326else
9327 ac_cpp_err=yes
9328fi
9329if test -z "$ac_cpp_err"; then
18fc9bd4 9330 ac_cv_header_pthread_h=yes
ba479fd2 9331else
18fc9bd4
RG
9332 echo "$as_me: failed program was:" >&5
9333sed 's/^/| /' conftest.$ac_ext >&5
9334
9335 ac_cv_header_pthread_h=no
9336fi
9337rm -f conftest.err conftest.$ac_ext
6e3f3080 9338fi
b61ff9c8
BS
9339echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
9340echo "${ECHO_T}$ac_cv_header_pthread_h" >&6
ba479fd2 9341if test $ac_cv_header_pthread_h = yes; then
f24af81b
TT
9342 have_pthread_h=yes
9343else
ba479fd2 9344 have_pthread_h=
f24af81b
TT
9345fi
9346
9347
84c041a1 9348# These tests can't be done till we know if we have limits.h.
b61ff9c8
BS
9349echo "$as_me:$LINENO: checking for CHAR_BIT" >&5
9350echo $ECHO_N "checking for CHAR_BIT... $ECHO_C" >&6
ba479fd2
NN
9351if test "${gcc_cv_decl_char_bit+set}" = set; then
9352 echo $ECHO_N "(cached) $ECHO_C" >&6
9353else
9354 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
9355/* confdefs.h. */
9356_ACEOF
9357cat confdefs.h >>conftest.$ac_ext
9358cat >>conftest.$ac_ext <<_ACEOF
9359/* end confdefs.h. */
75e93faa
ZW
9360#ifdef HAVE_LIMITS_H
9361#include <limits.h>
9362#endif
9363#ifdef CHAR_BIT
9364found
9365#endif
ba479fd2 9366_ACEOF
75e93faa 9367if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
ba479fd2 9368 $EGREP "found" >/dev/null 2>&1; then
75e93faa
ZW
9369 gcc_cv_decl_char_bit=yes
9370else
75e93faa
ZW
9371 gcc_cv_decl_char_bit=no
9372fi
9373rm -f conftest*
9374
9375
9376fi
b61ff9c8
BS
9377echo "$as_me:$LINENO: result: $gcc_cv_decl_char_bit" >&5
9378echo "${ECHO_T}$gcc_cv_decl_char_bit" >&6
75e93faa 9379if test $gcc_cv_decl_char_bit = no; then
b61ff9c8
BS
9380 echo "$as_me:$LINENO: checking number of bits in a byte" >&5
9381echo $ECHO_N "checking number of bits in a byte... $ECHO_C" >&6
ba479fd2
NN
9382if test "${gcc_cv_c_nbby+set}" = set; then
9383 echo $ECHO_N "(cached) $ECHO_C" >&6
75e93faa
ZW
9384else
9385 i=8
9386 gcc_cv_c_nbby=
9387 while test $i -lt 65; do
ba479fd2 9388 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
9389/* confdefs.h. */
9390_ACEOF
9391cat confdefs.h >>conftest.$ac_ext
9392cat >>conftest.$ac_ext <<_ACEOF
9393/* end confdefs.h. */
9394
9395int
9396main ()
9397{
4e70264f
ZW
9398switch(0) {
9399 case (unsigned char)((unsigned long)1 << $i) == ((unsigned long)1 << $i):
9400 case (unsigned char)((unsigned long)1<<($i-1)) == ((unsigned long)1<<($i-1)):
9401 ; }
ba479fd2
NN
9402 ;
9403 return 0;
9404}
9405_ACEOF
9406rm -f conftest.$ac_objext
b61ff9c8
BS
9407if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9408 (eval $ac_compile) 2>conftest.er1
ba479fd2 9409 ac_status=$?
86da66b5
HPN
9410 grep -v '^ *+' conftest.er1 >conftest.err
9411 rm -f conftest.er1
9412 cat conftest.err >&5
ba479fd2 9413 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
9414 (exit $ac_status); } &&
9415 { ac_try='test -z "$ac_c_werror_flag"
9416 || test ! -s conftest.err'
9417 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9418 (eval $ac_try) 2>&5
9419 ac_status=$?
9420 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9421 (exit $ac_status); }; } &&
9422 { ac_try='test -s conftest.$ac_objext'
9423 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9424 (eval $ac_try) 2>&5
9425 ac_status=$?
9426 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9427 (exit $ac_status); }; }; then
4e70264f 9428 gcc_cv_c_nbby=$i; break
75e93faa 9429else
ba479fd2
NN
9430 echo "$as_me: failed program was:" >&5
9431sed 's/^/| /' conftest.$ac_ext >&5
9432
75e93faa 9433fi
b61ff9c8 9434rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
75e93faa
ZW
9435 i=`expr $i + 1`
9436 done
9437 test -z "$gcc_cv_c_nbby" && gcc_cv_c_nbby=failed
9438
9439fi
b61ff9c8
BS
9440echo "$as_me:$LINENO: result: $gcc_cv_c_nbby" >&5
9441echo "${ECHO_T}$gcc_cv_c_nbby" >&6
75e93faa 9442if test $gcc_cv_c_nbby = failed; then
ba479fd2
NN
9443 { { echo "$as_me:$LINENO: error: cannot determine number of bits in a byte" >&5
9444echo "$as_me: error: cannot determine number of bits in a byte" >&2;}
9445 { (exit 1); exit 1; }; }
75e93faa 9446else
ba479fd2
NN
9447
9448cat >>confdefs.h <<_ACEOF
75e93faa 9449#define CHAR_BIT $gcc_cv_c_nbby
ba479fd2 9450_ACEOF
75e93faa
ZW
9451
9452fi
9453fi
b61ff9c8
BS
9454echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
9455echo $ECHO_N "checking whether byte ordering is bigendian... $ECHO_C" >&6
ba479fd2
NN
9456if test "${ac_cv_c_bigendian+set}" = set; then
9457 echo $ECHO_N "(cached) $ECHO_C" >&6
84c041a1 9458else
9791c75c 9459 # See if sys/param.h defines the BYTE_ORDER macro.
ba479fd2 9460cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
9461/* confdefs.h. */
9462_ACEOF
9463cat confdefs.h >>conftest.$ac_ext
9464cat >>conftest.$ac_ext <<_ACEOF
9465/* end confdefs.h. */
4977bab6
ZW
9466#include <sys/types.h>
9467#include <sys/param.h>
9791c75c 9468
ba479fd2
NN
9469int
9470main ()
9471{
b61ff9c8 9472#if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
4977bab6 9473 bogus endian macros
84c041a1 9474#endif
9791c75c 9475
ba479fd2
NN
9476 ;
9477 return 0;
9478}
9479_ACEOF
9480rm -f conftest.$ac_objext
b61ff9c8
BS
9481if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9482 (eval $ac_compile) 2>conftest.er1
ba479fd2 9483 ac_status=$?
86da66b5
HPN
9484 grep -v '^ *+' conftest.er1 >conftest.err
9485 rm -f conftest.er1
9486 cat conftest.err >&5
ba479fd2 9487 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
9488 (exit $ac_status); } &&
9489 { ac_try='test -z "$ac_c_werror_flag"
9490 || test ! -s conftest.err'
9491 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9492 (eval $ac_try) 2>&5
9493 ac_status=$?
9494 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9495 (exit $ac_status); }; } &&
9496 { ac_try='test -s conftest.$ac_objext'
9497 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9498 (eval $ac_try) 2>&5
9499 ac_status=$?
9500 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9501 (exit $ac_status); }; }; then
2f41c1d6 9502 # It does; now see whether it defined to BIG_ENDIAN or not.
ba479fd2 9503cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
9504/* confdefs.h. */
9505_ACEOF
9506cat confdefs.h >>conftest.$ac_ext
9507cat >>conftest.$ac_ext <<_ACEOF
9508/* end confdefs.h. */
4977bab6
ZW
9509#include <sys/types.h>
9510#include <sys/param.h>
9791c75c 9511
ba479fd2
NN
9512int
9513main ()
9514{
4977bab6
ZW
9515#if BYTE_ORDER != BIG_ENDIAN
9516 not big endian
84c041a1 9517#endif
9791c75c 9518
ba479fd2
NN
9519 ;
9520 return 0;
9521}
9522_ACEOF
9523rm -f conftest.$ac_objext
b61ff9c8
BS
9524if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9525 (eval $ac_compile) 2>conftest.er1
ba479fd2 9526 ac_status=$?
86da66b5
HPN
9527 grep -v '^ *+' conftest.er1 >conftest.err
9528 rm -f conftest.er1
9529 cat conftest.err >&5
ba479fd2 9530 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
9531 (exit $ac_status); } &&
9532 { ac_try='test -z "$ac_c_werror_flag"
9533 || test ! -s conftest.err'
9534 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9535 (eval $ac_try) 2>&5
9536 ac_status=$?
9537 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9538 (exit $ac_status); }; } &&
9539 { ac_try='test -s conftest.$ac_objext'
9540 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9541 (eval $ac_try) 2>&5
9542 ac_status=$?
9543 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9544 (exit $ac_status); }; }; then
9545 ac_cv_c_bigendian=yes
9546else
9547 echo "$as_me: failed program was:" >&5
ba479fd2
NN
9548sed 's/^/| /' conftest.$ac_ext >&5
9549
b61ff9c8 9550ac_cv_c_bigendian=no
4977bab6 9551fi
b61ff9c8 9552rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
4977bab6 9553else
ba479fd2
NN
9554 echo "$as_me: failed program was:" >&5
9555sed 's/^/| /' conftest.$ac_ext >&5
9556
b61ff9c8 9557# It does not; compile a test program.
9791c75c
KC
9558if test "$cross_compiling" = yes; then
9559 # try to guess the endianness by grepping values into an object file
9560 ac_cv_c_bigendian=unknown
9561 cat >conftest.$ac_ext <<_ACEOF
9562/* confdefs.h. */
9563_ACEOF
9564cat confdefs.h >>conftest.$ac_ext
9565cat >>conftest.$ac_ext <<_ACEOF
9566/* end confdefs.h. */
b61ff9c8
BS
9567short ascii_mm[] = { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
9568short ascii_ii[] = { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
9791c75c 9569void _ascii () { char *s = (char *) ascii_mm; s = (char *) ascii_ii; }
b61ff9c8
BS
9570short ebcdic_ii[] = { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
9571short ebcdic_mm[] = { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
9791c75c
KC
9572void _ebcdic () { char *s = (char *) ebcdic_mm; s = (char *) ebcdic_ii; }
9573int
9574main ()
9575{
9576 _ascii (); _ebcdic ();
9577 ;
9578 return 0;
9579}
9580_ACEOF
9581rm -f conftest.$ac_objext
b61ff9c8
BS
9582if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9583 (eval $ac_compile) 2>conftest.er1
9791c75c
KC
9584 ac_status=$?
9585 grep -v '^ *+' conftest.er1 >conftest.err
9586 rm -f conftest.er1
9587 cat conftest.err >&5
9588 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
9589 (exit $ac_status); } &&
9590 { ac_try='test -z "$ac_c_werror_flag"
9591 || test ! -s conftest.err'
9592 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9593 (eval $ac_try) 2>&5
9594 ac_status=$?
9595 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9596 (exit $ac_status); }; } &&
9597 { ac_try='test -s conftest.$ac_objext'
9598 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9599 (eval $ac_try) 2>&5
9600 ac_status=$?
9601 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9602 (exit $ac_status); }; }; then
8b1f719a
PB
9603 if grep BIGenDianSyS conftest.$ac_objext >/dev/null ; then
9604 ac_cv_c_bigendian=yes
9605fi
9791c75c
KC
9606if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
9607 if test "$ac_cv_c_bigendian" = unknown; then
9608 ac_cv_c_bigendian=no
9609 else
9610 # finding both strings is unlikely to happen, but who knows?
9611 ac_cv_c_bigendian=unknown
9612 fi
9613fi
9614else
9615 echo "$as_me: failed program was:" >&5
9616sed 's/^/| /' conftest.$ac_ext >&5
9617
4977bab6 9618fi
b61ff9c8 9619rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba479fd2
NN
9620else
9621 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
9622/* confdefs.h. */
9623_ACEOF
9624cat confdefs.h >>conftest.$ac_ext
9625cat >>conftest.$ac_ext <<_ACEOF
9626/* end confdefs.h. */
9791c75c
KC
9627int
9628main ()
9629{
4977bab6
ZW
9630 /* Are we little or big endian? From Harbison&Steele. */
9631 union
9632 {
b61ff9c8
BS
9633 long l;
9634 char c[sizeof (long)];
4977bab6
ZW
9635 } u;
9636 u.l = 1;
b61ff9c8 9637 exit (u.c[sizeof (long) - 1] == 1);
4977bab6 9638}
ba479fd2
NN
9639_ACEOF
9640rm -f conftest$ac_exeext
b61ff9c8
BS
9641if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9642 (eval $ac_link) 2>&5
ba479fd2
NN
9643 ac_status=$?
9644 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9645 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
b61ff9c8
BS
9646 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9647 (eval $ac_try) 2>&5
ba479fd2
NN
9648 ac_status=$?
9649 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9650 (exit $ac_status); }; }; then
4977bab6
ZW
9651 ac_cv_c_bigendian=no
9652else
ba479fd2
NN
9653 echo "$as_me: program exited with status $ac_status" >&5
9654echo "$as_me: failed program was:" >&5
9655sed 's/^/| /' conftest.$ac_ext >&5
9656
9657( exit $ac_status )
9658ac_cv_c_bigendian=yes
4977bab6 9659fi
b61ff9c8 9660rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
84c041a1 9661fi
4977bab6 9662fi
b61ff9c8 9663rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
4977bab6 9664fi
b61ff9c8
BS
9665echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
9666echo "${ECHO_T}$ac_cv_c_bigendian" >&6
9791c75c
KC
9667case $ac_cv_c_bigendian in
9668 yes)
ba479fd2
NN
9669
9670cat >>confdefs.h <<\_ACEOF
4977bab6 9671#define WORDS_BIGENDIAN 1
ba479fd2 9672_ACEOF
9791c75c
KC
9673 ;;
9674 no)
9675 ;;
9676 *)
9677 { { echo "$as_me:$LINENO: error: unknown endianness
9678presetting ac_cv_c_bigendian=no (or yes) will help" >&5
9679echo "$as_me: error: unknown endianness
9680presetting ac_cv_c_bigendian=no (or yes) will help" >&2;}
9681 { (exit 1); exit 1; }; } ;;
9682esac
84c041a1 9683
75e93faa 9684
73458fb7
NN
9685# --------
9686# UNSORTED
9687# --------
1e608388 9688
1e608388 9689
4e70264f
ZW
9690# These libraries may be used by collect2.
9691# We may need a special search path to get them linked.
b61ff9c8
BS
9692echo "$as_me:$LINENO: checking for collect2 libraries" >&5
9693echo $ECHO_N "checking for collect2 libraries... $ECHO_C" >&6
ba479fd2
NN
9694if test "${gcc_cv_collect2_libs+set}" = set; then
9695 echo $ECHO_N "(cached) $ECHO_C" >&6
4e70264f
ZW
9696else
9697 save_LIBS="$LIBS"
7f2749d4 9698for libs in '' -lld -lmld \
4e70264f
ZW
9699 '-L/usr/lib/cmplrs/cc2.11 -lmld' \
9700 '-L/usr/lib/cmplrs/cc3.11 -lmld'
9701do
9702 LIBS="$libs"
ba479fd2 9703 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
9704/* confdefs.h. */
9705_ACEOF
9706cat confdefs.h >>conftest.$ac_ext
9707cat >>conftest.$ac_ext <<_ACEOF
9708/* end confdefs.h. */
9709
b61ff9c8 9710/* Override any gcc2 internal prototype to avoid an error. */
ba479fd2
NN
9711#ifdef __cplusplus
9712extern "C"
9713#endif
b61ff9c8
BS
9714/* We use char because int might match the return type of a gcc2
9715 builtin and then its argument prototype would still apply. */
ba479fd2
NN
9716char ldopen ();
9717int
9718main ()
9719{
b61ff9c8 9720ldopen ();
ba479fd2
NN
9721 ;
9722 return 0;
9723}
9724_ACEOF
9725rm -f conftest.$ac_objext conftest$ac_exeext
b61ff9c8
BS
9726if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9727 (eval $ac_link) 2>conftest.er1
ba479fd2 9728 ac_status=$?
86da66b5
HPN
9729 grep -v '^ *+' conftest.er1 >conftest.err
9730 rm -f conftest.er1
9731 cat conftest.err >&5
ba479fd2 9732 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
9733 (exit $ac_status); } &&
9734 { ac_try='test -z "$ac_c_werror_flag"
9735 || test ! -s conftest.err'
9736 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9737 (eval $ac_try) 2>&5
9738 ac_status=$?
9739 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9740 (exit $ac_status); }; } &&
9741 { ac_try='test -s conftest$ac_exeext'
9742 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9743 (eval $ac_try) 2>&5
9744 ac_status=$?
9745 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9746 (exit $ac_status); }; }; then
4e70264f
ZW
9747 gcc_cv_collect2_libs="$libs"; break
9748else
ba479fd2
NN
9749 echo "$as_me: failed program was:" >&5
9750sed 's/^/| /' conftest.$ac_ext >&5
9751
4e70264f 9752fi
b61ff9c8 9753rm -f conftest.err conftest.$ac_objext \
86da66b5 9754 conftest$ac_exeext conftest.$ac_ext
4e70264f
ZW
9755done
9756LIBS="$save_LIBS"
9757test -z "$gcc_cv_collect2_libs" && gcc_cv_collect2_libs='none required'
9758fi
b61ff9c8
BS
9759echo "$as_me:$LINENO: result: $gcc_cv_collect2_libs" >&5
9760echo "${ECHO_T}$gcc_cv_collect2_libs" >&6
4e70264f
ZW
9761case $gcc_cv_collect2_libs in
9762 "none required") ;;
9763 *) COLLECT2_LIBS=$gcc_cv_collect2_libs ;;
9764esac
9765
9766
7f2749d4
RK
9767# When building Ada code on Alpha, we need exc_resume which is usually in
9768# -lexc. So test for it.
9769save_LIBS="$LIBS"
9770LIBS=
b61ff9c8
BS
9771echo "$as_me:$LINENO: checking for library containing exc_resume" >&5
9772echo $ECHO_N "checking for library containing exc_resume... $ECHO_C" >&6
ba479fd2
NN
9773if test "${ac_cv_search_exc_resume+set}" = set; then
9774 echo $ECHO_N "(cached) $ECHO_C" >&6
9775else
9776 ac_func_search_save_LIBS=$LIBS
b61ff9c8 9777ac_cv_search_exc_resume=no
ba479fd2 9778cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
9779/* confdefs.h. */
9780_ACEOF
9781cat confdefs.h >>conftest.$ac_ext
9782cat >>conftest.$ac_ext <<_ACEOF
9783/* end confdefs.h. */
7f2749d4 9784
b61ff9c8 9785/* Override any gcc2 internal prototype to avoid an error. */
ba479fd2
NN
9786#ifdef __cplusplus
9787extern "C"
9788#endif
b61ff9c8
BS
9789/* We use char because int might match the return type of a gcc2
9790 builtin and then its argument prototype would still apply. */
ba479fd2
NN
9791char exc_resume ();
9792int
9793main ()
9794{
b61ff9c8 9795exc_resume ();
ba479fd2
NN
9796 ;
9797 return 0;
9798}
9799_ACEOF
b61ff9c8
BS
9800rm -f conftest.$ac_objext conftest$ac_exeext
9801if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9802 (eval $ac_link) 2>conftest.er1
ba479fd2 9803 ac_status=$?
86da66b5
HPN
9804 grep -v '^ *+' conftest.er1 >conftest.err
9805 rm -f conftest.er1
9806 cat conftest.err >&5
ba479fd2 9807 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
9808 (exit $ac_status); } &&
9809 { ac_try='test -z "$ac_c_werror_flag"
9810 || test ! -s conftest.err'
9811 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9812 (eval $ac_try) 2>&5
9813 ac_status=$?
9814 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9815 (exit $ac_status); }; } &&
9816 { ac_try='test -s conftest$ac_exeext'
9817 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9818 (eval $ac_try) 2>&5
9819 ac_status=$?
9820 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9821 (exit $ac_status); }; }; then
9822 ac_cv_search_exc_resume="none required"
7f2749d4 9823else
ba479fd2
NN
9824 echo "$as_me: failed program was:" >&5
9825sed 's/^/| /' conftest.$ac_ext >&5
9826
ab22c1fa 9827fi
b61ff9c8
BS
9828rm -f conftest.err conftest.$ac_objext \
9829 conftest$ac_exeext conftest.$ac_ext
9830if test "$ac_cv_search_exc_resume" = no; then
9831 for ac_lib in exc; do
9832 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
9833 cat >conftest.$ac_ext <<_ACEOF
9834/* confdefs.h. */
9835_ACEOF
9836cat confdefs.h >>conftest.$ac_ext
9837cat >>conftest.$ac_ext <<_ACEOF
9838/* end confdefs.h. */
2f41c1d6 9839
b61ff9c8
BS
9840/* Override any gcc2 internal prototype to avoid an error. */
9841#ifdef __cplusplus
9842extern "C"
9843#endif
9844/* We use char because int might match the return type of a gcc2
9845 builtin and then its argument prototype would still apply. */
9846char exc_resume ();
9847int
9848main ()
9849{
9850exc_resume ();
9851 ;
9852 return 0;
9853}
9854_ACEOF
9855rm -f conftest.$ac_objext conftest$ac_exeext
9856if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9857 (eval $ac_link) 2>conftest.er1
9858 ac_status=$?
9859 grep -v '^ *+' conftest.er1 >conftest.err
9860 rm -f conftest.er1
9861 cat conftest.err >&5
9862 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9863 (exit $ac_status); } &&
9864 { ac_try='test -z "$ac_c_werror_flag"
9865 || test ! -s conftest.err'
9866 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9867 (eval $ac_try) 2>&5
9868 ac_status=$?
9869 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9870 (exit $ac_status); }; } &&
9871 { ac_try='test -s conftest$ac_exeext'
9872 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9873 (eval $ac_try) 2>&5
9874 ac_status=$?
9875 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9876 (exit $ac_status); }; }; then
9877 ac_cv_search_exc_resume="-l$ac_lib"
9878break
1a4b763e 9879else
b61ff9c8
BS
9880 echo "$as_me: failed program was:" >&5
9881sed 's/^/| /' conftest.$ac_ext >&5
9882
9883fi
9884rm -f conftest.err conftest.$ac_objext \
9885 conftest$ac_exeext conftest.$ac_ext
9886 done
b8ec3cc8 9887fi
b8ec3cc8
EC
9888LIBS=$ac_func_search_save_LIBS
9889fi
b61ff9c8
BS
9890echo "$as_me:$LINENO: result: $ac_cv_search_exc_resume" >&5
9891echo "${ECHO_T}$ac_cv_search_exc_resume" >&6
9892if test "$ac_cv_search_exc_resume" != no; then
9893 test "$ac_cv_search_exc_resume" = "none required" || LIBS="$ac_cv_search_exc_resume $LIBS"
b8ec3cc8
EC
9894
9895fi
9896
dd7f7a6e 9897GNAT_LIBEXC="$LIBS"
b8ec3cc8
EC
9898LIBS="$save_LIBS"
9899
9900
dd7f7a6e
EC
9901# Some systems put ldexp and frexp in libm instead of libc; assume
9902# they're both in the same place. jcf-dump needs them.
9903save_LIBS="$LIBS"
9904LIBS=
b61ff9c8
BS
9905echo "$as_me:$LINENO: checking for library containing ldexp" >&5
9906echo $ECHO_N "checking for library containing ldexp... $ECHO_C" >&6
dd7f7a6e 9907if test "${ac_cv_search_ldexp+set}" = set; then
b8ec3cc8
EC
9908 echo $ECHO_N "(cached) $ECHO_C" >&6
9909else
dd7f7a6e 9910 ac_func_search_save_LIBS=$LIBS
b61ff9c8 9911ac_cv_search_ldexp=no
dd7f7a6e 9912cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
9913/* confdefs.h. */
9914_ACEOF
9915cat confdefs.h >>conftest.$ac_ext
9916cat >>conftest.$ac_ext <<_ACEOF
9917/* end confdefs.h. */
dd7f7a6e 9918
b61ff9c8 9919/* Override any gcc2 internal prototype to avoid an error. */
dd7f7a6e
EC
9920#ifdef __cplusplus
9921extern "C"
9922#endif
b61ff9c8
BS
9923/* We use char because int might match the return type of a gcc2
9924 builtin and then its argument prototype would still apply. */
dd7f7a6e 9925char ldexp ();
ba479fd2
NN
9926int
9927main ()
9928{
b61ff9c8 9929ldexp ();
ba479fd2
NN
9930 ;
9931 return 0;
9932}
9933_ACEOF
b61ff9c8
BS
9934rm -f conftest.$ac_objext conftest$ac_exeext
9935if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9936 (eval $ac_link) 2>conftest.er1
dd7f7a6e
EC
9937 ac_status=$?
9938 grep -v '^ *+' conftest.er1 >conftest.err
9939 rm -f conftest.er1
9940 cat conftest.err >&5
9941 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
9942 (exit $ac_status); } &&
9943 { ac_try='test -z "$ac_c_werror_flag"
9944 || test ! -s conftest.err'
9945 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9946 (eval $ac_try) 2>&5
9947 ac_status=$?
9948 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9949 (exit $ac_status); }; } &&
9950 { ac_try='test -s conftest$ac_exeext'
9951 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9952 (eval $ac_try) 2>&5
9953 ac_status=$?
9954 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9955 (exit $ac_status); }; }; then
9956 ac_cv_search_ldexp="none required"
dd7f7a6e
EC
9957else
9958 echo "$as_me: failed program was:" >&5
9959sed 's/^/| /' conftest.$ac_ext >&5
9960
1a4b763e 9961fi
b61ff9c8
BS
9962rm -f conftest.err conftest.$ac_objext \
9963 conftest$ac_exeext conftest.$ac_ext
9964if test "$ac_cv_search_ldexp" = no; then
9965 for ac_lib in m; do
9966 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
9967 cat >conftest.$ac_ext <<_ACEOF
9968/* confdefs.h. */
9969_ACEOF
9970cat confdefs.h >>conftest.$ac_ext
9971cat >>conftest.$ac_ext <<_ACEOF
9972/* end confdefs.h. */
2f41c1d6 9973
b61ff9c8
BS
9974/* Override any gcc2 internal prototype to avoid an error. */
9975#ifdef __cplusplus
9976extern "C"
9977#endif
9978/* We use char because int might match the return type of a gcc2
9979 builtin and then its argument prototype would still apply. */
9980char ldexp ();
9981int
9982main ()
9983{
9984ldexp ();
9985 ;
9986 return 0;
9987}
9988_ACEOF
9989rm -f conftest.$ac_objext conftest$ac_exeext
9990if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9991 (eval $ac_link) 2>conftest.er1
9992 ac_status=$?
9993 grep -v '^ *+' conftest.er1 >conftest.err
9994 rm -f conftest.er1
9995 cat conftest.err >&5
9996 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9997 (exit $ac_status); } &&
9998 { ac_try='test -z "$ac_c_werror_flag"
9999 || test ! -s conftest.err'
10000 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10001 (eval $ac_try) 2>&5
10002 ac_status=$?
10003 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10004 (exit $ac_status); }; } &&
10005 { ac_try='test -s conftest$ac_exeext'
10006 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10007 (eval $ac_try) 2>&5
10008 ac_status=$?
10009 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10010 (exit $ac_status); }; }; then
10011 ac_cv_search_ldexp="-l$ac_lib"
10012break
1a4b763e 10013else
b61ff9c8
BS
10014 echo "$as_me: failed program was:" >&5
10015sed 's/^/| /' conftest.$ac_ext >&5
10016
10017fi
10018rm -f conftest.err conftest.$ac_objext \
10019 conftest$ac_exeext conftest.$ac_ext
10020 done
dd7f7a6e
EC
10021fi
10022LIBS=$ac_func_search_save_LIBS
10023fi
b61ff9c8
BS
10024echo "$as_me:$LINENO: result: $ac_cv_search_ldexp" >&5
10025echo "${ECHO_T}$ac_cv_search_ldexp" >&6
10026if test "$ac_cv_search_ldexp" != no; then
10027 test "$ac_cv_search_ldexp" = "none required" || LIBS="$ac_cv_search_ldexp $LIBS"
dd7f7a6e
EC
10028
10029fi
10030
10031LDEXP_LIB="$LIBS"
10032LIBS="$save_LIBS"
10033
10034
10035# Use <inttypes.h> only if it exists,
10036# doesn't clash with <sys/types.h>, and declares intmax_t.
b61ff9c8
BS
10037echo "$as_me:$LINENO: checking for inttypes.h" >&5
10038echo $ECHO_N "checking for inttypes.h... $ECHO_C" >&6
dd7f7a6e
EC
10039if test "${gcc_cv_header_inttypes_h+set}" = set; then
10040 echo $ECHO_N "(cached) $ECHO_C" >&6
10041else
10042 cat >conftest.$ac_ext <<_ACEOF
10043/* confdefs.h. */
10044_ACEOF
10045cat confdefs.h >>conftest.$ac_ext
10046cat >>conftest.$ac_ext <<_ACEOF
10047/* end confdefs.h. */
10048#include <sys/types.h>
10049#include <inttypes.h>
10050int
10051main ()
10052{
10053intmax_t i = -1;
10054 ;
10055 return 0;
10056}
10057_ACEOF
10058rm -f conftest.$ac_objext
b61ff9c8
BS
10059if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10060 (eval $ac_compile) 2>conftest.er1
dd7f7a6e
EC
10061 ac_status=$?
10062 grep -v '^ *+' conftest.er1 >conftest.err
10063 rm -f conftest.er1
10064 cat conftest.err >&5
10065 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
10066 (exit $ac_status); } &&
10067 { ac_try='test -z "$ac_c_werror_flag"
10068 || test ! -s conftest.err'
10069 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10070 (eval $ac_try) 2>&5
10071 ac_status=$?
10072 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10073 (exit $ac_status); }; } &&
10074 { ac_try='test -s conftest.$ac_objext'
10075 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10076 (eval $ac_try) 2>&5
10077 ac_status=$?
10078 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10079 (exit $ac_status); }; }; then
dd7f7a6e
EC
10080 gcc_cv_header_inttypes_h=yes
10081else
10082 echo "$as_me: failed program was:" >&5
10083sed 's/^/| /' conftest.$ac_ext >&5
10084
b61ff9c8 10085gcc_cv_header_inttypes_h=no
dd7f7a6e 10086fi
b61ff9c8 10087rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
dd7f7a6e
EC
10088fi
10089
b61ff9c8
BS
10090echo "$as_me:$LINENO: result: $gcc_cv_header_inttypes_h" >&5
10091echo "${ECHO_T}$gcc_cv_header_inttypes_h" >&6
dd7f7a6e
EC
10092if test $gcc_cv_header_inttypes_h = yes; then
10093
10094cat >>confdefs.h <<\_ACEOF
10095#define HAVE_INTTYPES_H 1
10096_ACEOF
10097
0056a9b5 10098fi
956d6950 10099
c149cc37 10100
ba479fd2
NN
10101
10102
10103
10104
10105
10106
10107
10108
10109
10110
10111
10112
10113
10114
10115
10116
0d667716
KG
10117
10118
10119
10120
10121
10122
10123
10124
10125
10126
10127
10128
ba479fd2
NN
10129
10130
10131
ba479fd2
NN
10132
10133
10134
52a6edcc 10135for ac_func in times clock kill getrlimit setrlimit atoll atoq \
d2e506f2 10136 sysconf strsignal getrusage nl_langinfo \
0d667716
KG
10137 gettimeofday mbstowcs wcswidth mmap mincore setlocale \
10138 clearerr_unlocked feof_unlocked ferror_unlocked fflush_unlocked fgetc_unlocked fgets_unlocked fileno_unlocked fprintf_unlocked fputc_unlocked fputs_unlocked fread_unlocked fwrite_unlocked getchar_unlocked getc_unlocked putchar_unlocked putc_unlocked
956d6950 10139do
ba479fd2 10140as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
b61ff9c8
BS
10141echo "$as_me:$LINENO: checking for $ac_func" >&5
10142echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
10143if eval "test \"\${$as_ac_var+set}\" = set"; then
ba479fd2
NN
10144 echo $ECHO_N "(cached) $ECHO_C" >&6
10145else
10146 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
10147/* confdefs.h. */
10148_ACEOF
10149cat confdefs.h >>conftest.$ac_ext
10150cat >>conftest.$ac_ext <<_ACEOF
10151/* end confdefs.h. */
86da66b5
HPN
10152/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
10153 For example, HP-UX 11i <limits.h> declares gettimeofday. */
10154#define $ac_func innocuous_$ac_func
10155
956d6950 10156/* System header to define __stub macros and hopefully few prototypes,
ba479fd2
NN
10157 which can conflict with char $ac_func (); below.
10158 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
10159 <limits.h> exists even on freestanding compilers. */
86da66b5 10160
ba479fd2
NN
10161#ifdef __STDC__
10162# include <limits.h>
10163#else
10164# include <assert.h>
10165#endif
86da66b5
HPN
10166
10167#undef $ac_func
10168
b61ff9c8 10169/* Override any gcc2 internal prototype to avoid an error. */
ba479fd2
NN
10170#ifdef __cplusplus
10171extern "C"
b61ff9c8 10172{
ba479fd2 10173#endif
b61ff9c8
BS
10174/* We use char because int might match the return type of a gcc2
10175 builtin and then its argument prototype would still apply. */
ba479fd2 10176char $ac_func ();
956d6950
JL
10177/* The GNU C library defines this for functions which it implements
10178 to always fail with ENOSYS. Some functions are actually named
10179 something starting with __ and the normal name is an alias. */
b61ff9c8 10180#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
956d6950 10181choke me
b61ff9c8
BS
10182#else
10183char (*f) () = $ac_func;
10184#endif
10185#ifdef __cplusplus
10186}
956d6950
JL
10187#endif
10188
ba479fd2
NN
10189int
10190main ()
10191{
b61ff9c8 10192return f != $ac_func;
ba479fd2
NN
10193 ;
10194 return 0;
10195}
10196_ACEOF
10197rm -f conftest.$ac_objext conftest$ac_exeext
b61ff9c8
BS
10198if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10199 (eval $ac_link) 2>conftest.er1
ba479fd2 10200 ac_status=$?
86da66b5
HPN
10201 grep -v '^ *+' conftest.er1 >conftest.err
10202 rm -f conftest.er1
10203 cat conftest.err >&5
ba479fd2 10204 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
10205 (exit $ac_status); } &&
10206 { ac_try='test -z "$ac_c_werror_flag"
10207 || test ! -s conftest.err'
10208 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10209 (eval $ac_try) 2>&5
10210 ac_status=$?
10211 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10212 (exit $ac_status); }; } &&
10213 { ac_try='test -s conftest$ac_exeext'
10214 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10215 (eval $ac_try) 2>&5
10216 ac_status=$?
10217 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10218 (exit $ac_status); }; }; then
ba479fd2
NN
10219 eval "$as_ac_var=yes"
10220else
10221 echo "$as_me: failed program was:" >&5
10222sed 's/^/| /' conftest.$ac_ext >&5
10223
b61ff9c8 10224eval "$as_ac_var=no"
ba479fd2 10225fi
b61ff9c8 10226rm -f conftest.err conftest.$ac_objext \
86da66b5 10227 conftest$ac_exeext conftest.$ac_ext
ba479fd2 10228fi
b61ff9c8
BS
10229echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
10230echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
ba479fd2
NN
10231if test `eval echo '${'$as_ac_var'}'` = yes; then
10232 cat >>confdefs.h <<_ACEOF
10233#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
10234_ACEOF
956d6950 10235
956d6950
JL
10236fi
10237done
10238
6885fc87 10239
39f6c4c8 10240if test x$ac_cv_func_mbstowcs = xyes; then
b61ff9c8
BS
10241 echo "$as_me:$LINENO: checking whether mbstowcs works" >&5
10242echo $ECHO_N "checking whether mbstowcs works... $ECHO_C" >&6
ba479fd2
NN
10243if test "${gcc_cv_func_mbstowcs_works+set}" = set; then
10244 echo $ECHO_N "(cached) $ECHO_C" >&6
39f6c4c8
KW
10245else
10246 if test "$cross_compiling" = yes; then
10247 gcc_cv_func_mbstowcs_works=yes
10248else
ba479fd2 10249 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
10250/* confdefs.h. */
10251_ACEOF
10252cat confdefs.h >>conftest.$ac_ext
10253cat >>conftest.$ac_ext <<_ACEOF
10254/* end confdefs.h. */
39f6c4c8
KW
10255#include <stdlib.h>
10256int main()
10257{
10258 mbstowcs(0, "", 0);
10259 return 0;
10260}
ba479fd2
NN
10261_ACEOF
10262rm -f conftest$ac_exeext
b61ff9c8
BS
10263if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10264 (eval $ac_link) 2>&5
ba479fd2
NN
10265 ac_status=$?
10266 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10267 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
b61ff9c8
BS
10268 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10269 (eval $ac_try) 2>&5
ba479fd2
NN
10270 ac_status=$?
10271 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10272 (exit $ac_status); }; }; then
39f6c4c8
KW
10273 gcc_cv_func_mbstowcs_works=yes
10274else
ba479fd2
NN
10275 echo "$as_me: program exited with status $ac_status" >&5
10276echo "$as_me: failed program was:" >&5
10277sed 's/^/| /' conftest.$ac_ext >&5
10278
10279( exit $ac_status )
10280gcc_cv_func_mbstowcs_works=no
39f6c4c8 10281fi
b61ff9c8 10282rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
39f6c4c8 10283fi
39f6c4c8 10284fi
b61ff9c8
BS
10285echo "$as_me:$LINENO: result: $gcc_cv_func_mbstowcs_works" >&5
10286echo "${ECHO_T}$gcc_cv_func_mbstowcs_works" >&6
63cf211a 10287 if test x$gcc_cv_func_mbstowcs_works = xyes; then
ba479fd2
NN
10288
10289cat >>confdefs.h <<\_ACEOF
39f6c4c8 10290#define HAVE_WORKING_MBSTOWCS 1
ba479fd2 10291_ACEOF
39f6c4c8
KW
10292
10293 fi
10294fi
10295
b61ff9c8
BS
10296echo "$as_me:$LINENO: checking for ssize_t" >&5
10297echo $ECHO_N "checking for ssize_t... $ECHO_C" >&6
ba479fd2
NN
10298if test "${ac_cv_type_ssize_t+set}" = set; then
10299 echo $ECHO_N "(cached) $ECHO_C" >&6
63cf211a 10300else
ba479fd2 10301 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
10302/* confdefs.h. */
10303_ACEOF
10304cat confdefs.h >>conftest.$ac_ext
10305cat >>conftest.$ac_ext <<_ACEOF
10306/* end confdefs.h. */
8b4fc07a
NN
10307$ac_includes_default
10308int
10309main ()
10310{
b61ff9c8 10311if ((ssize_t *) 0)
8b4fc07a 10312 return 0;
b61ff9c8 10313if (sizeof (ssize_t))
8b4fc07a
NN
10314 return 0;
10315 ;
10316 return 0;
10317}
ba479fd2 10318_ACEOF
8b4fc07a 10319rm -f conftest.$ac_objext
b61ff9c8
BS
10320if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10321 (eval $ac_compile) 2>conftest.er1
8b4fc07a 10322 ac_status=$?
86da66b5
HPN
10323 grep -v '^ *+' conftest.er1 >conftest.err
10324 rm -f conftest.er1
10325 cat conftest.err >&5
8b4fc07a 10326 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
10327 (exit $ac_status); } &&
10328 { ac_try='test -z "$ac_c_werror_flag"
10329 || test ! -s conftest.err'
10330 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10331 (eval $ac_try) 2>&5
10332 ac_status=$?
10333 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10334 (exit $ac_status); }; } &&
10335 { ac_try='test -s conftest.$ac_objext'
10336 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10337 (eval $ac_try) 2>&5
10338 ac_status=$?
10339 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10340 (exit $ac_status); }; }; then
cb65112a 10341 ac_cv_type_ssize_t=yes
f12bc141 10342else
8b4fc07a
NN
10343 echo "$as_me: failed program was:" >&5
10344sed 's/^/| /' conftest.$ac_ext >&5
6e3f3080 10345
b61ff9c8 10346ac_cv_type_ssize_t=no
8b4fc07a 10347fi
b61ff9c8 10348rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
63cf211a 10349fi
b61ff9c8
BS
10350echo "$as_me:$LINENO: result: $ac_cv_type_ssize_t" >&5
10351echo "${ECHO_T}$ac_cv_type_ssize_t" >&6
8b4fc07a
NN
10352if test $ac_cv_type_ssize_t = yes; then
10353 :
10354else
ba479fd2 10355
8b4fc07a 10356cat >>confdefs.h <<_ACEOF
f12bc141 10357#define ssize_t int
ba479fd2 10358_ACEOF
f12bc141
ZW
10359
10360fi
10361
bba09b5a
AT
10362echo "$as_me:$LINENO: checking for caddr_t" >&5
10363echo $ECHO_N "checking for caddr_t... $ECHO_C" >&6
10364if test "${ac_cv_type_caddr_t+set}" = set; then
10365 echo $ECHO_N "(cached) $ECHO_C" >&6
10366else
10367 cat >conftest.$ac_ext <<_ACEOF
10368/* confdefs.h. */
10369_ACEOF
10370cat confdefs.h >>conftest.$ac_ext
10371cat >>conftest.$ac_ext <<_ACEOF
10372/* end confdefs.h. */
10373$ac_includes_default
10374int
10375main ()
10376{
10377if ((caddr_t *) 0)
10378 return 0;
10379if (sizeof (caddr_t))
10380 return 0;
10381 ;
10382 return 0;
10383}
10384_ACEOF
10385rm -f conftest.$ac_objext
10386if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10387 (eval $ac_compile) 2>conftest.er1
10388 ac_status=$?
10389 grep -v '^ *+' conftest.er1 >conftest.err
10390 rm -f conftest.er1
10391 cat conftest.err >&5
10392 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10393 (exit $ac_status); } &&
10394 { ac_try='test -z "$ac_c_werror_flag"
10395 || test ! -s conftest.err'
10396 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10397 (eval $ac_try) 2>&5
10398 ac_status=$?
10399 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10400 (exit $ac_status); }; } &&
10401 { ac_try='test -s conftest.$ac_objext'
10402 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10403 (eval $ac_try) 2>&5
10404 ac_status=$?
10405 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10406 (exit $ac_status); }; }; then
10407 ac_cv_type_caddr_t=yes
10408else
10409 echo "$as_me: failed program was:" >&5
10410sed 's/^/| /' conftest.$ac_ext >&5
10411
10412ac_cv_type_caddr_t=no
10413fi
10414rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10415fi
10416echo "$as_me:$LINENO: result: $ac_cv_type_caddr_t" >&5
10417echo "${ECHO_T}$ac_cv_type_caddr_t" >&6
10418if test $ac_cv_type_caddr_t = yes; then
10419 :
10420else
10421
10422cat >>confdefs.h <<_ACEOF
10423#define caddr_t char *
10424_ACEOF
10425
10426fi
10427
0b9d02c6 10428
3b0727a0 10429
b61ff9c8
BS
10430echo "$as_me:$LINENO: checking for sys/mman.h" >&5
10431echo $ECHO_N "checking for sys/mman.h... $ECHO_C" >&6
3b0727a0
MR
10432if test "${ac_cv_header_sys_mman_h+set}" = set; then
10433 echo $ECHO_N "(cached) $ECHO_C" >&6
0f57bf40 10434else
18fc9bd4 10435 cat >conftest.$ac_ext <<_ACEOF
3b0727a0
MR
10436/* confdefs.h. */
10437_ACEOF
10438cat confdefs.h >>conftest.$ac_ext
10439cat >>conftest.$ac_ext <<_ACEOF
10440/* end confdefs.h. */
10441#include <sys/mman.h>
10442_ACEOF
b61ff9c8
BS
10443if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10444 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3b0727a0
MR
10445 ac_status=$?
10446 grep -v '^ *+' conftest.er1 >conftest.err
10447 rm -f conftest.er1
10448 cat conftest.err >&5
10449 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
10450 (exit $ac_status); } >/dev/null; then
10451 if test -s conftest.err; then
10452 ac_cpp_err=$ac_c_preproc_warn_flag
10453 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
10454 else
10455 ac_cpp_err=
10456 fi
10457else
10458 ac_cpp_err=yes
10459fi
10460if test -z "$ac_cpp_err"; then
10461 ac_cv_header_sys_mman_h=yes
10462else
3b0727a0
MR
10463 echo "$as_me: failed program was:" >&5
10464sed 's/^/| /' conftest.$ac_ext >&5
10465
18fc9bd4 10466 ac_cv_header_sys_mman_h=no
3b0727a0
MR
10467fi
10468rm -f conftest.err conftest.$ac_ext
10469fi
b61ff9c8
BS
10470echo "$as_me:$LINENO: result: $ac_cv_header_sys_mman_h" >&5
10471echo "${ECHO_T}$ac_cv_header_sys_mman_h" >&6
3b0727a0
MR
10472if test $ac_cv_header_sys_mman_h = yes; then
10473 gcc_header_sys_mman_h=yes
10474else
10475 gcc_header_sys_mman_h=no
10476fi
10477
b61ff9c8
BS
10478echo "$as_me:$LINENO: checking for mmap" >&5
10479echo $ECHO_N "checking for mmap... $ECHO_C" >&6
3b0727a0
MR
10480if test "${ac_cv_func_mmap+set}" = set; then
10481 echo $ECHO_N "(cached) $ECHO_C" >&6
10482else
10483 cat >conftest.$ac_ext <<_ACEOF
10484/* confdefs.h. */
10485_ACEOF
10486cat confdefs.h >>conftest.$ac_ext
10487cat >>conftest.$ac_ext <<_ACEOF
10488/* end confdefs.h. */
10489/* Define mmap to an innocuous variant, in case <limits.h> declares mmap.
10490 For example, HP-UX 11i <limits.h> declares gettimeofday. */
10491#define mmap innocuous_mmap
10492
10493/* System header to define __stub macros and hopefully few prototypes,
10494 which can conflict with char mmap (); below.
10495 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
10496 <limits.h> exists even on freestanding compilers. */
10497
10498#ifdef __STDC__
10499# include <limits.h>
10500#else
10501# include <assert.h>
10502#endif
10503
10504#undef mmap
10505
b61ff9c8 10506/* Override any gcc2 internal prototype to avoid an error. */
3b0727a0
MR
10507#ifdef __cplusplus
10508extern "C"
b61ff9c8 10509{
3b0727a0 10510#endif
b61ff9c8
BS
10511/* We use char because int might match the return type of a gcc2
10512 builtin and then its argument prototype would still apply. */
3b0727a0
MR
10513char mmap ();
10514/* The GNU C library defines this for functions which it implements
10515 to always fail with ENOSYS. Some functions are actually named
10516 something starting with __ and the normal name is an alias. */
b61ff9c8 10517#if defined (__stub_mmap) || defined (__stub___mmap)
3b0727a0 10518choke me
b61ff9c8
BS
10519#else
10520char (*f) () = mmap;
10521#endif
10522#ifdef __cplusplus
10523}
3b0727a0
MR
10524#endif
10525
10526int
10527main ()
10528{
b61ff9c8 10529return f != mmap;
3b0727a0
MR
10530 ;
10531 return 0;
10532}
10533_ACEOF
10534rm -f conftest.$ac_objext conftest$ac_exeext
b61ff9c8
BS
10535if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10536 (eval $ac_link) 2>conftest.er1
3b0727a0
MR
10537 ac_status=$?
10538 grep -v '^ *+' conftest.er1 >conftest.err
10539 rm -f conftest.er1
10540 cat conftest.err >&5
10541 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
10542 (exit $ac_status); } &&
10543 { ac_try='test -z "$ac_c_werror_flag"
10544 || test ! -s conftest.err'
10545 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10546 (eval $ac_try) 2>&5
10547 ac_status=$?
10548 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10549 (exit $ac_status); }; } &&
10550 { ac_try='test -s conftest$ac_exeext'
10551 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10552 (eval $ac_try) 2>&5
10553 ac_status=$?
10554 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10555 (exit $ac_status); }; }; then
8b1f719a
PB
10556 ac_cv_func_mmap=yes
10557else
10558 echo "$as_me: failed program was:" >&5
10559sed 's/^/| /' conftest.$ac_ext >&5
a6ccdbab 10560
b61ff9c8 10561ac_cv_func_mmap=no
8b1f719a 10562fi
b61ff9c8 10563rm -f conftest.err conftest.$ac_objext \
3b0727a0
MR
10564 conftest$ac_exeext conftest.$ac_ext
10565fi
b61ff9c8
BS
10566echo "$as_me:$LINENO: result: $ac_cv_func_mmap" >&5
10567echo "${ECHO_T}$ac_cv_func_mmap" >&6
3b0727a0
MR
10568if test $ac_cv_func_mmap = yes; then
10569 gcc_func_mmap=yes
10570else
10571 gcc_func_mmap=no
10572fi
10573
10574if test "$gcc_header_sys_mman_h" != yes \
10575 || test "$gcc_func_mmap" != yes; then
1072ec3f
ZW
10576 gcc_cv_func_mmap_file=no
10577 gcc_cv_func_mmap_dev_zero=no
10578 gcc_cv_func_mmap_anon=no
10579else
b61ff9c8
BS
10580 echo "$as_me:$LINENO: checking whether read-only mmap of a plain file works" >&5
10581echo $ECHO_N "checking whether read-only mmap of a plain file works... $ECHO_C" >&6
ba479fd2
NN
10582if test "${gcc_cv_func_mmap_file+set}" = set; then
10583 echo $ECHO_N "(cached) $ECHO_C" >&6
1072ec3f 10584else
ba479fd2 10585 # Add a system to this blacklist if
1072ec3f
ZW
10586 # mmap(0, stat_size, PROT_READ, MAP_PRIVATE, fd, 0) doesn't return a
10587 # memory area containing the same data that you'd get if you applied
10588 # read() to the same fd. The only system known to have a problem here
10589 # is VMS, where text files have record structure.
10590 case "$host_os" in
ba479fd2 10591 vms* | ultrix*)
1072ec3f
ZW
10592 gcc_cv_func_mmap_file=no ;;
10593 *)
10594 gcc_cv_func_mmap_file=yes;;
10595 esac
10596fi
b61ff9c8
BS
10597echo "$as_me:$LINENO: result: $gcc_cv_func_mmap_file" >&5
10598echo "${ECHO_T}$gcc_cv_func_mmap_file" >&6
10599 echo "$as_me:$LINENO: checking whether mmap from /dev/zero works" >&5
10600echo $ECHO_N "checking whether mmap from /dev/zero works... $ECHO_C" >&6
ba479fd2
NN
10601if test "${gcc_cv_func_mmap_dev_zero+set}" = set; then
10602 echo $ECHO_N "(cached) $ECHO_C" >&6
1072ec3f
ZW
10603else
10604 # Add a system to this blacklist if it has mmap() but /dev/zero
10605 # does not exist, or if mmapping /dev/zero does not give anonymous
10606 # zeroed pages with both the following properties:
10607 # 1. If you map N consecutive pages in with one call, and then
10608 # unmap any subset of those pages, the pages that were not
10609 # explicitly unmapped remain accessible.
10610 # 2. If you map two adjacent blocks of memory and then unmap them
10611 # both at once, they must both go away.
10612 # Systems known to be in this category are Windows (all variants),
10613 # VMS, and Darwin.
10614 case "$host_os" in
2ce240d3 10615 vms* | cygwin* | pe | mingw* | darwin* | ultrix* | hpux10* | hpux11.00)
1072ec3f
ZW
10616 gcc_cv_func_mmap_dev_zero=no ;;
10617 *)
10618 gcc_cv_func_mmap_dev_zero=yes;;
10619 esac
10620fi
b61ff9c8
BS
10621echo "$as_me:$LINENO: result: $gcc_cv_func_mmap_dev_zero" >&5
10622echo "${ECHO_T}$gcc_cv_func_mmap_dev_zero" >&6
1072ec3f
ZW
10623
10624 # Unlike /dev/zero, the MAP_ANON(YMOUS) defines can be probed for.
b61ff9c8
BS
10625 echo "$as_me:$LINENO: checking for MAP_ANON(YMOUS)" >&5
10626echo $ECHO_N "checking for MAP_ANON(YMOUS)... $ECHO_C" >&6
ba479fd2
NN
10627if test "${gcc_cv_decl_map_anon+set}" = set; then
10628 echo $ECHO_N "(cached) $ECHO_C" >&6
10629else
10630 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
10631/* confdefs.h. */
10632_ACEOF
10633cat confdefs.h >>conftest.$ac_ext
10634cat >>conftest.$ac_ext <<_ACEOF
10635/* end confdefs.h. */
1072ec3f
ZW
10636#include <sys/types.h>
10637#include <sys/mman.h>
10638#include <unistd.h>
10639
10640#ifndef MAP_ANONYMOUS
10641#define MAP_ANONYMOUS MAP_ANON
10642#endif
10643
ba479fd2
NN
10644int
10645main ()
10646{
1072ec3f 10647int n = MAP_ANONYMOUS;
ba479fd2
NN
10648 ;
10649 return 0;
10650}
10651_ACEOF
10652rm -f conftest.$ac_objext
b61ff9c8
BS
10653if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10654 (eval $ac_compile) 2>conftest.er1
ba479fd2 10655 ac_status=$?
86da66b5
HPN
10656 grep -v '^ *+' conftest.er1 >conftest.err
10657 rm -f conftest.er1
10658 cat conftest.err >&5
ba479fd2 10659 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
10660 (exit $ac_status); } &&
10661 { ac_try='test -z "$ac_c_werror_flag"
10662 || test ! -s conftest.err'
10663 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10664 (eval $ac_try) 2>&5
10665 ac_status=$?
10666 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10667 (exit $ac_status); }; } &&
10668 { ac_try='test -s conftest.$ac_objext'
10669 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10670 (eval $ac_try) 2>&5
10671 ac_status=$?
10672 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10673 (exit $ac_status); }; }; then
1072ec3f
ZW
10674 gcc_cv_decl_map_anon=yes
10675else
ba479fd2
NN
10676 echo "$as_me: failed program was:" >&5
10677sed 's/^/| /' conftest.$ac_ext >&5
10678
b61ff9c8 10679gcc_cv_decl_map_anon=no
1072ec3f 10680fi
b61ff9c8 10681rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
1072ec3f 10682fi
b61ff9c8
BS
10683echo "$as_me:$LINENO: result: $gcc_cv_decl_map_anon" >&5
10684echo "${ECHO_T}$gcc_cv_decl_map_anon" >&6
1072ec3f
ZW
10685
10686 if test $gcc_cv_decl_map_anon = no; then
10687 gcc_cv_func_mmap_anon=no
10688 else
b61ff9c8
BS
10689 echo "$as_me:$LINENO: checking whether mmap with MAP_ANON(YMOUS) works" >&5
10690echo $ECHO_N "checking whether mmap with MAP_ANON(YMOUS) works... $ECHO_C" >&6
ba479fd2
NN
10691if test "${gcc_cv_func_mmap_anon+set}" = set; then
10692 echo $ECHO_N "(cached) $ECHO_C" >&6
1072ec3f
ZW
10693else
10694 # Add a system to this blacklist if it has mmap() and MAP_ANON or
10695 # MAP_ANONYMOUS, but using mmap(..., MAP_PRIVATE|MAP_ANONYMOUS, -1, 0)
10696 # doesn't give anonymous zeroed pages with the same properties listed
10697 # above for use of /dev/zero.
10698 # Systems known to be in this category are Windows, VMS, and SCO Unix.
10699 case "$host_os" in
10700 vms* | cygwin* | pe | mingw* | sco* | udk* )
10701 gcc_cv_func_mmap_anon=no ;;
10702 *)
10703 gcc_cv_func_mmap_anon=yes;;
10704 esac
10705fi
b61ff9c8
BS
10706echo "$as_me:$LINENO: result: $gcc_cv_func_mmap_anon" >&5
10707echo "${ECHO_T}$gcc_cv_func_mmap_anon" >&6
1072ec3f
ZW
10708 fi
10709fi
10710
10711if test $gcc_cv_func_mmap_file = yes; then
ba479fd2
NN
10712
10713cat >>confdefs.h <<\_ACEOF
1072ec3f 10714#define HAVE_MMAP_FILE 1
ba479fd2 10715_ACEOF
1072ec3f
ZW
10716
10717fi
10718if test $gcc_cv_func_mmap_dev_zero = yes; then
ba479fd2
NN
10719
10720cat >>confdefs.h <<\_ACEOF
1072ec3f 10721#define HAVE_MMAP_DEV_ZERO 1
ba479fd2 10722_ACEOF
1072ec3f
ZW
10723
10724fi
10725if test $gcc_cv_func_mmap_anon = yes; then
ba479fd2
NN
10726
10727cat >>confdefs.h <<\_ACEOF
1072ec3f 10728#define HAVE_MMAP_ANON 1
ba479fd2 10729_ACEOF
1072ec3f
ZW
10730
10731fi
10732
b27d2bd5
MK
10733
10734case "${host}" in
ee262b6f 10735*-*-*vms*)
ba479fd2 10736 # Under VMS, vfork works very differently than on Unix. The standard test
ee262b6f
DR
10737 # won't work, and it isn't easily adaptable. It makes more sense to
10738 # just force it.
10739 ac_cv_func_vfork_works=yes
10740 ;;
b27d2bd5 10741esac
b61ff9c8
BS
10742echo "$as_me:$LINENO: checking for pid_t" >&5
10743echo $ECHO_N "checking for pid_t... $ECHO_C" >&6
ba479fd2
NN
10744if test "${ac_cv_type_pid_t+set}" = set; then
10745 echo $ECHO_N "(cached) $ECHO_C" >&6
10746else
10747 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
10748/* confdefs.h. */
10749_ACEOF
10750cat confdefs.h >>conftest.$ac_ext
10751cat >>conftest.$ac_ext <<_ACEOF
10752/* end confdefs.h. */
10753$ac_includes_default
10754int
10755main ()
10756{
b61ff9c8 10757if ((pid_t *) 0)
ba479fd2 10758 return 0;
b61ff9c8 10759if (sizeof (pid_t))
ba479fd2
NN
10760 return 0;
10761 ;
10762 return 0;
10763}
10764_ACEOF
10765rm -f conftest.$ac_objext
b61ff9c8
BS
10766if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10767 (eval $ac_compile) 2>conftest.er1
ba479fd2 10768 ac_status=$?
86da66b5
HPN
10769 grep -v '^ *+' conftest.er1 >conftest.err
10770 rm -f conftest.er1
10771 cat conftest.err >&5
ba479fd2 10772 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
10773 (exit $ac_status); } &&
10774 { ac_try='test -z "$ac_c_werror_flag"
10775 || test ! -s conftest.err'
10776 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10777 (eval $ac_try) 2>&5
10778 ac_status=$?
10779 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10780 (exit $ac_status); }; } &&
10781 { ac_try='test -s conftest.$ac_objext'
10782 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10783 (eval $ac_try) 2>&5
10784 ac_status=$?
10785 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10786 (exit $ac_status); }; }; then
cb65112a 10787 ac_cv_type_pid_t=yes
c375c43b 10788else
ba479fd2
NN
10789 echo "$as_me: failed program was:" >&5
10790sed 's/^/| /' conftest.$ac_ext >&5
6e3f3080 10791
b61ff9c8 10792ac_cv_type_pid_t=no
ba479fd2 10793fi
b61ff9c8 10794rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
63cf211a 10795fi
b61ff9c8
BS
10796echo "$as_me:$LINENO: result: $ac_cv_type_pid_t" >&5
10797echo "${ECHO_T}$ac_cv_type_pid_t" >&6
ba479fd2
NN
10798if test $ac_cv_type_pid_t = yes; then
10799 :
10800else
10801
10802cat >>confdefs.h <<_ACEOF
c375c43b 10803#define pid_t int
ba479fd2 10804_ACEOF
c375c43b
KG
10805
10806fi
10807
ba479fd2 10808
b61ff9c8
BS
10809
10810for ac_header in unistd.h vfork.h
ba479fd2
NN
10811do
10812as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
b61ff9c8
BS
10813echo "$as_me:$LINENO: checking for $ac_header" >&5
10814echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
10815if eval "test \"\${$as_ac_Header+set}\" = set"; then
ba479fd2 10816 echo $ECHO_N "(cached) $ECHO_C" >&6
0f57bf40 10817else
18fc9bd4 10818 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
10819/* confdefs.h. */
10820_ACEOF
10821cat confdefs.h >>conftest.$ac_ext
10822cat >>conftest.$ac_ext <<_ACEOF
10823/* end confdefs.h. */
10824#include <$ac_header>
10825_ACEOF
b61ff9c8
BS
10826if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10827 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
ba479fd2
NN
10828 ac_status=$?
10829 grep -v '^ *+' conftest.er1 >conftest.err
10830 rm -f conftest.er1
10831 cat conftest.err >&5
10832 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
10833 (exit $ac_status); } >/dev/null; then
10834 if test -s conftest.err; then
10835 ac_cpp_err=$ac_c_preproc_warn_flag
10836 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
10837 else
10838 ac_cpp_err=
10839 fi
10840else
10841 ac_cpp_err=yes
10842fi
10843if test -z "$ac_cpp_err"; then
18fc9bd4 10844 eval "$as_ac_Header=yes"
ba479fd2
NN
10845else
10846 echo "$as_me: failed program was:" >&5
10847sed 's/^/| /' conftest.$ac_ext >&5
10848
18fc9bd4 10849 eval "$as_ac_Header=no"
ba479fd2
NN
10850fi
10851rm -f conftest.err conftest.$ac_ext
c375c43b 10852fi
b61ff9c8
BS
10853echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
10854echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
ba479fd2
NN
10855if test `eval echo '${'$as_ac_Header'}'` = yes; then
10856 cat >>confdefs.h <<_ACEOF
10857#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10858_ACEOF
6e3f3080
NN
10859
10860fi
ba479fd2
NN
10861done
10862
10863
10864
10865for ac_func in fork vfork
10866do
10867as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
b61ff9c8
BS
10868echo "$as_me:$LINENO: checking for $ac_func" >&5
10869echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
10870if eval "test \"\${$as_ac_var+set}\" = set"; then
ba479fd2
NN
10871 echo $ECHO_N "(cached) $ECHO_C" >&6
10872else
10873 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
10874/* confdefs.h. */
10875_ACEOF
10876cat confdefs.h >>conftest.$ac_ext
10877cat >>conftest.$ac_ext <<_ACEOF
10878/* end confdefs.h. */
86da66b5
HPN
10879/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
10880 For example, HP-UX 11i <limits.h> declares gettimeofday. */
10881#define $ac_func innocuous_$ac_func
10882
c375c43b 10883/* System header to define __stub macros and hopefully few prototypes,
ba479fd2
NN
10884 which can conflict with char $ac_func (); below.
10885 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
10886 <limits.h> exists even on freestanding compilers. */
86da66b5 10887
ba479fd2
NN
10888#ifdef __STDC__
10889# include <limits.h>
10890#else
10891# include <assert.h>
10892#endif
86da66b5
HPN
10893
10894#undef $ac_func
10895
b61ff9c8 10896/* Override any gcc2 internal prototype to avoid an error. */
ba479fd2
NN
10897#ifdef __cplusplus
10898extern "C"
b61ff9c8 10899{
ba479fd2 10900#endif
b61ff9c8
BS
10901/* We use char because int might match the return type of a gcc2
10902 builtin and then its argument prototype would still apply. */
ba479fd2 10903char $ac_func ();
c375c43b
KG
10904/* The GNU C library defines this for functions which it implements
10905 to always fail with ENOSYS. Some functions are actually named
10906 something starting with __ and the normal name is an alias. */
b61ff9c8 10907#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
c375c43b 10908choke me
b61ff9c8
BS
10909#else
10910char (*f) () = $ac_func;
10911#endif
10912#ifdef __cplusplus
10913}
c375c43b
KG
10914#endif
10915
ba479fd2
NN
10916int
10917main ()
10918{
b61ff9c8 10919return f != $ac_func;
ba479fd2
NN
10920 ;
10921 return 0;
10922}
10923_ACEOF
10924rm -f conftest.$ac_objext conftest$ac_exeext
b61ff9c8
BS
10925if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10926 (eval $ac_link) 2>conftest.er1
ba479fd2 10927 ac_status=$?
86da66b5
HPN
10928 grep -v '^ *+' conftest.er1 >conftest.err
10929 rm -f conftest.er1
10930 cat conftest.err >&5
ba479fd2 10931 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
10932 (exit $ac_status); } &&
10933 { ac_try='test -z "$ac_c_werror_flag"
10934 || test ! -s conftest.err'
10935 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10936 (eval $ac_try) 2>&5
10937 ac_status=$?
10938 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10939 (exit $ac_status); }; } &&
10940 { ac_try='test -s conftest$ac_exeext'
10941 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10942 (eval $ac_try) 2>&5
10943 ac_status=$?
10944 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10945 (exit $ac_status); }; }; then
ba479fd2
NN
10946 eval "$as_ac_var=yes"
10947else
10948 echo "$as_me: failed program was:" >&5
10949sed 's/^/| /' conftest.$ac_ext >&5
10950
b61ff9c8 10951eval "$as_ac_var=no"
ba479fd2 10952fi
b61ff9c8 10953rm -f conftest.err conftest.$ac_objext \
86da66b5 10954 conftest$ac_exeext conftest.$ac_ext
ba479fd2 10955fi
b61ff9c8
BS
10956echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
10957echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
ba479fd2
NN
10958if test `eval echo '${'$as_ac_var'}'` = yes; then
10959 cat >>confdefs.h <<_ACEOF
10960#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
10961_ACEOF
10962
c375c43b 10963fi
ba479fd2 10964done
c375c43b 10965
ba479fd2 10966if test "x$ac_cv_func_fork" = xyes; then
b61ff9c8
BS
10967 echo "$as_me:$LINENO: checking for working fork" >&5
10968echo $ECHO_N "checking for working fork... $ECHO_C" >&6
ba479fd2
NN
10969if test "${ac_cv_func_fork_works+set}" = set; then
10970 echo $ECHO_N "(cached) $ECHO_C" >&6
c375c43b 10971else
ba479fd2
NN
10972 if test "$cross_compiling" = yes; then
10973 ac_cv_func_fork_works=cross
10974else
10975 cat >conftest.$ac_ext <<_ACEOF
b61ff9c8
BS
10976/* By Ruediger Kuhlmann. */
10977 #include <sys/types.h>
10978 #if HAVE_UNISTD_H
10979 # include <unistd.h>
10980 #endif
10981 /* Some systems only have a dummy stub for fork() */
10982 int main ()
10983 {
10984 if (fork() < 0)
10985 exit (1);
10986 exit (0);
10987 }
1a4b763e
BS
10988_ACEOF
10989rm -f conftest$ac_exeext
b61ff9c8
BS
10990if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10991 (eval $ac_link) 2>&5
1a4b763e
BS
10992 ac_status=$?
10993 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10994 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
b61ff9c8
BS
10995 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10996 (eval $ac_try) 2>&5
ba479fd2
NN
10997 ac_status=$?
10998 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10999 (exit $ac_status); }; }; then
11000 ac_cv_func_fork_works=yes
11001else
11002 echo "$as_me: program exited with status $ac_status" >&5
11003echo "$as_me: failed program was:" >&5
11004sed 's/^/| /' conftest.$ac_ext >&5
11005
11006( exit $ac_status )
11007ac_cv_func_fork_works=no
11008fi
b61ff9c8 11009rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
ba479fd2
NN
11010fi
11011fi
b61ff9c8
BS
11012echo "$as_me:$LINENO: result: $ac_cv_func_fork_works" >&5
11013echo "${ECHO_T}$ac_cv_func_fork_works" >&6
ba479fd2
NN
11014
11015else
11016 ac_cv_func_fork_works=$ac_cv_func_fork
11017fi
11018if test "x$ac_cv_func_fork_works" = xcross; then
11019 case $host in
11020 *-*-amigaos* | *-*-msdosdjgpp*)
11021 # Override, as these systems have only a dummy fork() stub
11022 ac_cv_func_fork_works=no
11023 ;;
11024 *)
11025 ac_cv_func_fork_works=yes
11026 ;;
11027 esac
11028 { echo "$as_me:$LINENO: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
11029echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
c375c43b 11030fi
c375c43b 11031ac_cv_func_vfork_works=$ac_cv_func_vfork
ba479fd2 11032if test "x$ac_cv_func_vfork" = xyes; then
b61ff9c8
BS
11033 echo "$as_me:$LINENO: checking for working vfork" >&5
11034echo $ECHO_N "checking for working vfork... $ECHO_C" >&6
ba479fd2
NN
11035if test "${ac_cv_func_vfork_works+set}" = set; then
11036 echo $ECHO_N "(cached) $ECHO_C" >&6
c375c43b 11037else
ba479fd2
NN
11038 if test "$cross_compiling" = yes; then
11039 ac_cv_func_vfork_works=cross
11040else
11041 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
11042/* confdefs.h. */
11043_ACEOF
11044cat confdefs.h >>conftest.$ac_ext
11045cat >>conftest.$ac_ext <<_ACEOF
11046/* end confdefs.h. */
c375c43b 11047/* Thanks to Paul Eggert for this test. */
b61ff9c8
BS
11048#include <stdio.h>
11049#include <stdlib.h>
11050#include <sys/types.h>
11051#include <sys/stat.h>
ba479fd2 11052#include <sys/wait.h>
b61ff9c8
BS
11053#if HAVE_UNISTD_H
11054# include <unistd.h>
11055#endif
11056#if HAVE_VFORK_H
ba479fd2 11057# include <vfork.h>
c375c43b
KG
11058#endif
11059/* On some sparc systems, changes by the child to local and incoming
ba479fd2
NN
11060 argument registers are propagated back to the parent. The compiler
11061 is told about this with #include <vfork.h>, but some compilers
11062 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
11063 static variable whose address is put into a register that is
11064 clobbered by the vfork. */
11065static void
c375c43b
KG
11066#ifdef __cplusplus
11067sparc_address_test (int arg)
ba479fd2 11068# else
c375c43b
KG
11069sparc_address_test (arg) int arg;
11070#endif
11071{
11072 static pid_t child;
11073 if (!child) {
11074 child = vfork ();
11075 if (child < 0) {
11076 perror ("vfork");
11077 _exit(2);
11078 }
11079 if (!child) {
11080 arg = getpid();
11081 write(-1, "", 0);
11082 _exit (arg);
11083 }
11084 }
11085}
ba479fd2
NN
11086
11087int
11088main ()
11089{
c375c43b
KG
11090 pid_t parent = getpid ();
11091 pid_t child;
11092
ba479fd2 11093 sparc_address_test (0);
c375c43b
KG
11094
11095 child = vfork ();
11096
11097 if (child == 0) {
ba479fd2
NN
11098 /* Here is another test for sparc vfork register problems. This
11099 test uses lots of local variables, at least as many local
11100 variables as main has allocated so far including compiler
11101 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
11102 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
11103 reuse the register of parent for one of the local variables,
11104 since it will think that parent can't possibly be used any more
11105 in this routine. Assigning to the local variable will thus
11106 munge parent in the parent process. */
c375c43b
KG
11107 pid_t
11108 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
11109 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
11110 /* Convince the compiler that p..p7 are live; otherwise, it might
11111 use the same hardware register for all 8 local variables. */
11112 if (p != p1 || p != p2 || p != p3 || p != p4
11113 || p != p5 || p != p6 || p != p7)
11114 _exit(1);
11115
ba479fd2
NN
11116 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
11117 from child file descriptors. If the child closes a descriptor
11118 before it execs or exits, this munges the parent's descriptor
11119 as well. Test for this by closing stdout in the child. */
c375c43b
KG
11120 _exit(close(fileno(stdout)) != 0);
11121 } else {
11122 int status;
11123 struct stat st;
11124
11125 while (wait(&status) != child)
11126 ;
b61ff9c8 11127 exit(
c375c43b
KG
11128 /* Was there some problem with vforking? */
11129 child < 0
11130
11131 /* Did the child fail? (This shouldn't happen.) */
11132 || status
11133
11134 /* Did the vfork/compiler bug occur? */
11135 || parent != getpid()
11136
11137 /* Did the file descriptor bug occur? */
11138 || fstat(fileno(stdout), &st) != 0
11139 );
11140 }
11141}
ba479fd2
NN
11142_ACEOF
11143rm -f conftest$ac_exeext
b61ff9c8
BS
11144if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11145 (eval $ac_link) 2>&5
ba479fd2
NN
11146 ac_status=$?
11147 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11148 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
b61ff9c8
BS
11149 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11150 (eval $ac_try) 2>&5
ba479fd2
NN
11151 ac_status=$?
11152 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11153 (exit $ac_status); }; }; then
c375c43b
KG
11154 ac_cv_func_vfork_works=yes
11155else
ba479fd2
NN
11156 echo "$as_me: program exited with status $ac_status" >&5
11157echo "$as_me: failed program was:" >&5
11158sed 's/^/| /' conftest.$ac_ext >&5
11159
11160( exit $ac_status )
11161ac_cv_func_vfork_works=no
cafe096b 11162fi
b61ff9c8 11163rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6e3f3080 11164fi
ba479fd2 11165fi
b61ff9c8
BS
11166echo "$as_me:$LINENO: result: $ac_cv_func_vfork_works" >&5
11167echo "${ECHO_T}$ac_cv_func_vfork_works" >&6
c375c43b 11168
ba479fd2
NN
11169fi;
11170if test "x$ac_cv_func_fork_works" = xcross; then
86da66b5 11171 ac_cv_func_vfork_works=$ac_cv_func_vfork
ba479fd2
NN
11172 { echo "$as_me:$LINENO: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
11173echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
c375c43b
KG
11174fi
11175
ba479fd2
NN
11176if test "x$ac_cv_func_vfork_works" = xyes; then
11177
11178cat >>confdefs.h <<\_ACEOF
11179#define HAVE_WORKING_VFORK 1
11180_ACEOF
11181
11182else
11183
11184cat >>confdefs.h <<\_ACEOF
c375c43b 11185#define vfork fork
ba479fd2 11186_ACEOF
c375c43b
KG
11187
11188fi
ba479fd2
NN
11189if test "x$ac_cv_func_fork_works" = xyes; then
11190
11191cat >>confdefs.h <<\_ACEOF
11192#define HAVE_WORKING_FORK 1
11193_ACEOF
11194
11195fi
11196
c375c43b 11197
81bf3d9e 11198
dfb77e37
KC
11199 if test "X$prefix" = "XNONE"; then
11200 acl_final_prefix="$ac_default_prefix"
11201 else
11202 acl_final_prefix="$prefix"
11203 fi
11204 if test "X$exec_prefix" = "XNONE"; then
11205 acl_final_exec_prefix='${prefix}'
11206 else
11207 acl_final_exec_prefix="$exec_prefix"
11208 fi
11209 acl_save_prefix="$prefix"
11210 prefix="$acl_final_prefix"
11211 eval acl_final_exec_prefix=\"$acl_final_exec_prefix\"
11212 prefix="$acl_save_prefix"
f91abfce
TT
11213
11214
b61ff9c8 11215# Check whether --with-gnu-ld or --without-gnu-ld was given.
dfb77e37 11216if test "${with_gnu_ld+set}" = set; then
b61ff9c8
BS
11217 withval="$with_gnu_ld"
11218 test "$withval" = no || with_gnu_ld=yes
ba479fd2 11219else
dfb77e37 11220 with_gnu_ld=no
b61ff9c8 11221fi;
dfb77e37
KC
11222# Prepare PATH_SEPARATOR.
11223# The user is always right.
11224if test "${PATH_SEPARATOR+set}" != set; then
11225 echo "#! /bin/sh" >conf$$.sh
11226 echo "exit 0" >>conf$$.sh
11227 chmod +x conf$$.sh
11228 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
11229 PATH_SEPARATOR=';'
ba479fd2 11230 else
dfb77e37 11231 PATH_SEPARATOR=:
ba479fd2 11232 fi
dfb77e37
KC
11233 rm -f conf$$.sh
11234fi
11235ac_prog=ld
11236if test "$GCC" = yes; then
11237 # Check if gcc -print-prog-name=ld gives a path.
b61ff9c8
BS
11238 echo "$as_me:$LINENO: checking for ld used by GCC" >&5
11239echo $ECHO_N "checking for ld used by GCC... $ECHO_C" >&6
dfb77e37
KC
11240 case $host in
11241 *-*-mingw*)
11242 # gcc leaves a trailing carriage return which upsets mingw
11243 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
11244 *)
11245 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
11246 esac
11247 case $ac_prog in
11248 # Accept absolute paths.
11249 [\\/]* | [A-Za-z]:[\\/]*)
11250 re_direlt='/[^/][^/]*/\.\./'
11251 # Canonicalize the path of ld
11252 ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
11253 while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
11254 ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
11255 done
11256 test -z "$LD" && LD="$ac_prog"
11257 ;;
11258 "")
11259 # If it fails, then pretend we aren't using GCC.
11260 ac_prog=ld
11261 ;;
11262 *)
11263 # If it is relative, then search for the first ld in PATH.
11264 with_gnu_ld=unknown
11265 ;;
11266 esac
11267elif test "$with_gnu_ld" = yes; then
b61ff9c8
BS
11268 echo "$as_me:$LINENO: checking for GNU ld" >&5
11269echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6
ba479fd2 11270else
b61ff9c8
BS
11271 echo "$as_me:$LINENO: checking for non-GNU ld" >&5
11272echo $ECHO_N "checking for non-GNU ld... $ECHO_C" >&6
ba479fd2 11273fi
dfb77e37
KC
11274if test "${acl_cv_path_LD+set}" = set; then
11275 echo $ECHO_N "(cached) $ECHO_C" >&6
ba479fd2 11276else
dfb77e37
KC
11277 if test -z "$LD"; then
11278 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
11279 for ac_dir in $PATH; do
11280 test -z "$ac_dir" && ac_dir=.
11281 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
11282 acl_cv_path_LD="$ac_dir/$ac_prog"
11283 # Check to see if the program is GNU ld. I'd rather use --version,
11284 # but apparently some GNU ld's only accept -v.
11285 # Break only if it was the GNU/non-GNU ld that we prefer.
18fc9bd4
RG
11286 if "$acl_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
11287 test "$with_gnu_ld" != no && break
11288 else
11289 test "$with_gnu_ld" != yes && break
11290 fi
dfb77e37
KC
11291 fi
11292 done
11293 IFS="$ac_save_ifs"
11294else
11295 acl_cv_path_LD="$LD" # Let the user override the test with a path.
11296fi
11297fi
ba479fd2 11298
dfb77e37
KC
11299LD="$acl_cv_path_LD"
11300if test -n "$LD"; then
b61ff9c8
BS
11301 echo "$as_me:$LINENO: result: $LD" >&5
11302echo "${ECHO_T}$LD" >&6
dfb77e37 11303else
b61ff9c8
BS
11304 echo "$as_me:$LINENO: result: no" >&5
11305echo "${ECHO_T}no" >&6
ba479fd2 11306fi
dfb77e37
KC
11307test -z "$LD" && { { echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5
11308echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
11309 { (exit 1); exit 1; }; }
b61ff9c8
BS
11310echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
11311echo $ECHO_N "checking if the linker ($LD) is GNU ld... $ECHO_C" >&6
dfb77e37
KC
11312if test "${acl_cv_prog_gnu_ld+set}" = set; then
11313 echo $ECHO_N "(cached) $ECHO_C" >&6
11314else
11315 # I'd rather use --version here, but apparently some GNU ld's only accept -v.
18fc9bd4
RG
11316if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
11317 acl_cv_prog_gnu_ld=yes
11318else
11319 acl_cv_prog_gnu_ld=no
11320fi
dfb77e37 11321fi
b61ff9c8
BS
11322echo "$as_me:$LINENO: result: $acl_cv_prog_gnu_ld" >&5
11323echo "${ECHO_T}$acl_cv_prog_gnu_ld" >&6
dfb77e37
KC
11324with_gnu_ld=$acl_cv_prog_gnu_ld
11325
11326
11327
b61ff9c8
BS
11328 echo "$as_me:$LINENO: checking for shared library run path origin" >&5
11329echo $ECHO_N "checking for shared library run path origin... $ECHO_C" >&6
dfb77e37
KC
11330if test "${acl_cv_rpath+set}" = set; then
11331 echo $ECHO_N "(cached) $ECHO_C" >&6
11332else
11333
11334 CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
11335 ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
11336 . ./conftest.sh
11337 rm -f ./conftest.sh
11338 acl_cv_rpath=done
ba479fd2 11339
eb158727 11340fi
b61ff9c8
BS
11341echo "$as_me:$LINENO: result: $acl_cv_rpath" >&5
11342echo "${ECHO_T}$acl_cv_rpath" >&6
dfb77e37
KC
11343 wl="$acl_cv_wl"
11344 libext="$acl_cv_libext"
11345 shlibext="$acl_cv_shlibext"
11346 hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
11347 hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
11348 hardcode_direct="$acl_cv_hardcode_direct"
11349 hardcode_minus_L="$acl_cv_hardcode_minus_L"
b61ff9c8 11350 # Check whether --enable-rpath or --disable-rpath was given.
dfb77e37 11351if test "${enable_rpath+set}" = set; then
b61ff9c8
BS
11352 enableval="$enable_rpath"
11353 :
dfb77e37
KC
11354else
11355 enable_rpath=yes
b61ff9c8 11356fi;
8b1f719a 11357
a6ccdbab 11358
dfb77e37
KC
11359
11360
11361
11362
11363
b639c3c2
JJ
11364 use_additional=yes
11365
11366 acl_save_prefix="$prefix"
11367 prefix="$acl_final_prefix"
11368 acl_save_exec_prefix="$exec_prefix"
11369 exec_prefix="$acl_final_exec_prefix"
11370
11371 eval additional_includedir=\"$includedir\"
11372 eval additional_libdir=\"$libdir\"
11373
11374 exec_prefix="$acl_save_exec_prefix"
11375 prefix="$acl_save_prefix"
dfb77e37
KC
11376
11377
b61ff9c8 11378# Check whether --with-libiconv-prefix or --without-libiconv-prefix was given.
8b1f719a 11379if test "${with_libiconv_prefix+set}" = set; then
b61ff9c8
BS
11380 withval="$with_libiconv_prefix"
11381
8b1f719a 11382 if test "X$withval" = "Xno"; then
b639c3c2 11383 use_additional=no
8b1f719a
PB
11384 else
11385 if test "X$withval" = "X"; then
dfb77e37
KC
11386
11387 acl_save_prefix="$prefix"
11388 prefix="$acl_final_prefix"
11389 acl_save_exec_prefix="$exec_prefix"
11390 exec_prefix="$acl_final_exec_prefix"
11391
b639c3c2
JJ
11392 eval additional_includedir=\"$includedir\"
11393 eval additional_libdir=\"$libdir\"
dfb77e37
KC
11394
11395 exec_prefix="$acl_save_exec_prefix"
11396 prefix="$acl_save_prefix"
11397
8b1f719a 11398 else
b639c3c2
JJ
11399 additional_includedir="$withval/include"
11400 additional_libdir="$withval/lib"
8b1f719a
PB
11401 fi
11402 fi
11403
b61ff9c8 11404fi;
dfb77e37
KC
11405 LIBICONV=
11406 LTLIBICONV=
11407 INCICONV=
11408 rpathdirs=
11409 ltrpathdirs=
11410 names_already_handled=
11411 names_next_round='iconv '
11412 while test -n "$names_next_round"; do
11413 names_this_round="$names_next_round"
11414 names_next_round=
11415 for name in $names_this_round; do
11416 already_handled=
11417 for n in $names_already_handled; do
11418 if test "$n" = "$name"; then
11419 already_handled=yes
11420 break
11421 fi
11422 done
11423 if test -z "$already_handled"; then
11424 names_already_handled="$names_already_handled $name"
11425 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
11426 eval value=\"\$HAVE_LIB$uppername\"
11427 if test -n "$value"; then
11428 if test "$value" = yes; then
11429 eval value=\"\$LIB$uppername\"
11430 test -z "$value" || LIBICONV="${LIBICONV}${LIBICONV:+ }$value"
11431 eval value=\"\$LTLIB$uppername\"
11432 test -z "$value" || LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$value"
11433 else
11434 :
11435 fi
11436 else
11437 found_dir=
11438 found_la=
11439 found_so=
11440 found_a=
b639c3c2
JJ
11441 if test $use_additional = yes; then
11442 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then
11443 found_dir="$additional_libdir"
11444 found_so="$additional_libdir/lib$name.$shlibext"
11445 if test -f "$additional_libdir/lib$name.la"; then
11446 found_la="$additional_libdir/lib$name.la"
dfb77e37
KC
11447 fi
11448 else
b639c3c2
JJ
11449 if test -f "$additional_libdir/lib$name.$libext"; then
11450 found_dir="$additional_libdir"
11451 found_a="$additional_libdir/lib$name.$libext"
11452 if test -f "$additional_libdir/lib$name.la"; then
11453 found_la="$additional_libdir/lib$name.la"
dfb77e37
KC
11454 fi
11455 fi
11456 fi
11457 fi
11458 if test "X$found_dir" = "X"; then
11459 for x in $LDFLAGS $LTLIBICONV; do
11460
11461 acl_save_prefix="$prefix"
11462 prefix="$acl_final_prefix"
11463 acl_save_exec_prefix="$exec_prefix"
11464 exec_prefix="$acl_final_exec_prefix"
11465 eval x=\"$x\"
11466 exec_prefix="$acl_save_exec_prefix"
11467 prefix="$acl_save_prefix"
11468
11469 case "$x" in
11470 -L*)
11471 dir=`echo "X$x" | sed -e 's/^X-L//'`
11472 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then
11473 found_dir="$dir"
11474 found_so="$dir/lib$name.$shlibext"
11475 if test -f "$dir/lib$name.la"; then
11476 found_la="$dir/lib$name.la"
11477 fi
11478 else
11479 if test -f "$dir/lib$name.$libext"; then
11480 found_dir="$dir"
11481 found_a="$dir/lib$name.$libext"
11482 if test -f "$dir/lib$name.la"; then
11483 found_la="$dir/lib$name.la"
11484 fi
11485 fi
11486 fi
11487 ;;
11488 esac
11489 if test "X$found_dir" != "X"; then
11490 break
11491 fi
11492 done
11493 fi
11494 if test "X$found_dir" != "X"; then
11495 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$found_dir -l$name"
11496 if test "X$found_so" != "X"; then
11497 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
11498 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
11499 else
11500 haveit=
11501 for x in $ltrpathdirs; do
11502 if test "X$x" = "X$found_dir"; then
11503 haveit=yes
11504 break
11505 fi
11506 done
11507 if test -z "$haveit"; then
11508 ltrpathdirs="$ltrpathdirs $found_dir"
11509 fi
11510 if test "$hardcode_direct" = yes; then
11511 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
11512 else
11513 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
11514 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
11515 haveit=
11516 for x in $rpathdirs; do
11517 if test "X$x" = "X$found_dir"; then
11518 haveit=yes
11519 break
11520 fi
11521 done
11522 if test -z "$haveit"; then
11523 rpathdirs="$rpathdirs $found_dir"
11524 fi
11525 else
11526 haveit=
11527 for x in $LDFLAGS $LIBICONV; do
11528
11529 acl_save_prefix="$prefix"
11530 prefix="$acl_final_prefix"
11531 acl_save_exec_prefix="$exec_prefix"
11532 exec_prefix="$acl_final_exec_prefix"
11533 eval x=\"$x\"
11534 exec_prefix="$acl_save_exec_prefix"
11535 prefix="$acl_save_prefix"
11536
11537 if test "X$x" = "X-L$found_dir"; then
11538 haveit=yes
11539 break
11540 fi
11541 done
11542 if test -z "$haveit"; then
11543 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir"
11544 fi
11545 if test "$hardcode_minus_L" != no; then
11546 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
11547 else
11548 LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
11549 fi
11550 fi
11551 fi
11552 fi
11553 else
11554 if test "X$found_a" != "X"; then
11555 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_a"
11556 else
11557 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir -l$name"
11558 fi
11559 fi
11560 additional_includedir=
11561 case "$found_dir" in
11562 */lib | */lib/)
11563 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
11564 additional_includedir="$basedir/include"
11565 ;;
11566 esac
11567 if test "X$additional_includedir" != "X"; then
11568 if test "X$additional_includedir" != "X/usr/include"; then
11569 haveit=
11570 if test "X$additional_includedir" = "X/usr/local/include"; then
11571 if test -n "$GCC"; then
11572 case $host_os in
18fc9bd4 11573 linux*) haveit=yes;;
dfb77e37
KC
11574 esac
11575 fi
11576 fi
11577 if test -z "$haveit"; then
11578 for x in $CPPFLAGS $INCICONV; do
11579
11580 acl_save_prefix="$prefix"
11581 prefix="$acl_final_prefix"
11582 acl_save_exec_prefix="$exec_prefix"
11583 exec_prefix="$acl_final_exec_prefix"
11584 eval x=\"$x\"
11585 exec_prefix="$acl_save_exec_prefix"
11586 prefix="$acl_save_prefix"
11587
11588 if test "X$x" = "X-I$additional_includedir"; then
11589 haveit=yes
11590 break
11591 fi
11592 done
11593 if test -z "$haveit"; then
11594 if test -d "$additional_includedir"; then
11595 INCICONV="${INCICONV}${INCICONV:+ }-I$additional_includedir"
11596 fi
11597 fi
11598 fi
11599 fi
11600 fi
11601 if test -n "$found_la"; then
11602 save_libdir="$libdir"
11603 case "$found_la" in
11604 */* | *\\*) . "$found_la" ;;
11605 *) . "./$found_la" ;;
11606 esac
11607 libdir="$save_libdir"
11608 for dep in $dependency_libs; do
11609 case "$dep" in
11610 -L*)
11611 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
11612 if test "X$additional_libdir" != "X/usr/lib"; then
11613 haveit=
11614 if test "X$additional_libdir" = "X/usr/local/lib"; then
11615 if test -n "$GCC"; then
11616 case $host_os in
18fc9bd4 11617 linux*) haveit=yes;;
dfb77e37
KC
11618 esac
11619 fi
11620 fi
11621 if test -z "$haveit"; then
11622 haveit=
11623 for x in $LDFLAGS $LIBICONV; do
11624
11625 acl_save_prefix="$prefix"
11626 prefix="$acl_final_prefix"
11627 acl_save_exec_prefix="$exec_prefix"
11628 exec_prefix="$acl_final_exec_prefix"
11629 eval x=\"$x\"
11630 exec_prefix="$acl_save_exec_prefix"
11631 prefix="$acl_save_prefix"
11632
11633 if test "X$x" = "X-L$additional_libdir"; then
11634 haveit=yes
11635 break
11636 fi
11637 done
11638 if test -z "$haveit"; then
11639 if test -d "$additional_libdir"; then
11640 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$additional_libdir"
11641 fi
11642 fi
11643 haveit=
11644 for x in $LDFLAGS $LTLIBICONV; do
11645
11646 acl_save_prefix="$prefix"
11647 prefix="$acl_final_prefix"
11648 acl_save_exec_prefix="$exec_prefix"
11649 exec_prefix="$acl_final_exec_prefix"
11650 eval x=\"$x\"
11651 exec_prefix="$acl_save_exec_prefix"
11652 prefix="$acl_save_prefix"
11653
11654 if test "X$x" = "X-L$additional_libdir"; then
11655 haveit=yes
11656 break
11657 fi
11658 done
11659 if test -z "$haveit"; then
11660 if test -d "$additional_libdir"; then
11661 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$additional_libdir"
11662 fi
11663 fi
11664 fi
11665 fi
11666 ;;
11667 -R*)
11668 dir=`echo "X$dep" | sed -e 's/^X-R//'`
11669 if test "$enable_rpath" != no; then
11670 haveit=
11671 for x in $rpathdirs; do
11672 if test "X$x" = "X$dir"; then
11673 haveit=yes
11674 break
11675 fi
11676 done
11677 if test -z "$haveit"; then
11678 rpathdirs="$rpathdirs $dir"
11679 fi
11680 haveit=
11681 for x in $ltrpathdirs; do
11682 if test "X$x" = "X$dir"; then
11683 haveit=yes
11684 break
11685 fi
11686 done
11687 if test -z "$haveit"; then
11688 ltrpathdirs="$ltrpathdirs $dir"
11689 fi
11690 fi
11691 ;;
11692 -l*)
11693 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
11694 ;;
11695 *.la)
11696 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
11697 ;;
11698 *)
11699 LIBICONV="${LIBICONV}${LIBICONV:+ }$dep"
11700 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$dep"
11701 ;;
11702 esac
11703 done
11704 fi
11705 else
11706 LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
11707 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l$name"
11708 fi
11709 fi
11710 fi
11711 done
11712 done
11713 if test "X$rpathdirs" != "X"; then
11714 if test -n "$hardcode_libdir_separator"; then
11715 alldirs=
11716 for found_dir in $rpathdirs; do
11717 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
11718 done
11719 acl_save_libdir="$libdir"
11720 libdir="$alldirs"
11721 eval flag=\"$hardcode_libdir_flag_spec\"
11722 libdir="$acl_save_libdir"
11723 LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
11724 else
11725 for found_dir in $rpathdirs; do
11726 acl_save_libdir="$libdir"
11727 libdir="$found_dir"
11728 eval flag=\"$hardcode_libdir_flag_spec\"
11729 libdir="$acl_save_libdir"
11730 LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
11731 done
11732 fi
11733 fi
11734 if test "X$ltrpathdirs" != "X"; then
11735 for found_dir in $ltrpathdirs; do
11736 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-R$found_dir"
11737 done
11738 fi
11739
11740
11741
11742
11743
11744
11745
11746 am_save_CPPFLAGS="$CPPFLAGS"
11747
11748 for element in $INCICONV; do
11749 haveit=
11750 for x in $CPPFLAGS; do
11751
11752 acl_save_prefix="$prefix"
11753 prefix="$acl_final_prefix"
11754 acl_save_exec_prefix="$exec_prefix"
11755 exec_prefix="$acl_final_exec_prefix"
11756 eval x=\"$x\"
11757 exec_prefix="$acl_save_exec_prefix"
11758 prefix="$acl_save_prefix"
11759
11760 if test "X$x" = "X$element"; then
11761 haveit=yes
11762 break
11763 fi
11764 done
11765 if test -z "$haveit"; then
11766 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
11767 fi
11768 done
eb158727
ZW
11769
11770
b61ff9c8
BS
11771 echo "$as_me:$LINENO: checking for iconv" >&5
11772echo $ECHO_N "checking for iconv... $ECHO_C" >&6
ba479fd2
NN
11773if test "${am_cv_func_iconv+set}" = set; then
11774 echo $ECHO_N "(cached) $ECHO_C" >&6
f91abfce 11775else
ba479fd2 11776
f91abfce
TT
11777 am_cv_func_iconv="no, consider installing GNU libiconv"
11778 am_cv_lib_iconv=no
ba479fd2 11779 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
11780/* confdefs.h. */
11781_ACEOF
11782cat confdefs.h >>conftest.$ac_ext
11783cat >>conftest.$ac_ext <<_ACEOF
11784/* end confdefs.h. */
f91abfce
TT
11785#include <stdlib.h>
11786#include <iconv.h>
ba479fd2
NN
11787int
11788main ()
11789{
f91abfce
TT
11790iconv_t cd = iconv_open("","");
11791 iconv(cd,NULL,NULL,NULL,NULL);
11792 iconv_close(cd);
ba479fd2
NN
11793 ;
11794 return 0;
11795}
11796_ACEOF
11797rm -f conftest.$ac_objext conftest$ac_exeext
b61ff9c8
BS
11798if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11799 (eval $ac_link) 2>conftest.er1
ba479fd2 11800 ac_status=$?
86da66b5
HPN
11801 grep -v '^ *+' conftest.er1 >conftest.err
11802 rm -f conftest.er1
11803 cat conftest.err >&5
ba479fd2 11804 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
11805 (exit $ac_status); } &&
11806 { ac_try='test -z "$ac_c_werror_flag"
11807 || test ! -s conftest.err'
11808 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11809 (eval $ac_try) 2>&5
11810 ac_status=$?
11811 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11812 (exit $ac_status); }; } &&
11813 { ac_try='test -s conftest$ac_exeext'
11814 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11815 (eval $ac_try) 2>&5
11816 ac_status=$?
11817 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11818 (exit $ac_status); }; }; then
f91abfce
TT
11819 am_cv_func_iconv=yes
11820else
ba479fd2
NN
11821 echo "$as_me: failed program was:" >&5
11822sed 's/^/| /' conftest.$ac_ext >&5
11823
f91abfce 11824fi
b61ff9c8 11825rm -f conftest.err conftest.$ac_objext \
86da66b5 11826 conftest$ac_exeext conftest.$ac_ext
f91abfce
TT
11827 if test "$am_cv_func_iconv" != yes; then
11828 am_save_LIBS="$LIBS"
dfb77e37 11829 LIBS="$LIBS $LIBICONV"
ba479fd2 11830 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
11831/* confdefs.h. */
11832_ACEOF
11833cat confdefs.h >>conftest.$ac_ext
11834cat >>conftest.$ac_ext <<_ACEOF
11835/* end confdefs.h. */
f91abfce
TT
11836#include <stdlib.h>
11837#include <iconv.h>
ba479fd2
NN
11838int
11839main ()
11840{
f91abfce
TT
11841iconv_t cd = iconv_open("","");
11842 iconv(cd,NULL,NULL,NULL,NULL);
11843 iconv_close(cd);
ba479fd2
NN
11844 ;
11845 return 0;
11846}
11847_ACEOF
11848rm -f conftest.$ac_objext conftest$ac_exeext
b61ff9c8
BS
11849if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11850 (eval $ac_link) 2>conftest.er1
ba479fd2 11851 ac_status=$?
86da66b5
HPN
11852 grep -v '^ *+' conftest.er1 >conftest.err
11853 rm -f conftest.er1
11854 cat conftest.err >&5
ba479fd2 11855 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
11856 (exit $ac_status); } &&
11857 { ac_try='test -z "$ac_c_werror_flag"
11858 || test ! -s conftest.err'
11859 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11860 (eval $ac_try) 2>&5
11861 ac_status=$?
11862 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11863 (exit $ac_status); }; } &&
11864 { ac_try='test -s conftest$ac_exeext'
11865 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11866 (eval $ac_try) 2>&5
11867 ac_status=$?
11868 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11869 (exit $ac_status); }; }; then
f91abfce
TT
11870 am_cv_lib_iconv=yes
11871 am_cv_func_iconv=yes
11872else
ba479fd2
NN
11873 echo "$as_me: failed program was:" >&5
11874sed 's/^/| /' conftest.$ac_ext >&5
11875
f91abfce 11876fi
b61ff9c8 11877rm -f conftest.err conftest.$ac_objext \
86da66b5 11878 conftest$ac_exeext conftest.$ac_ext
f91abfce
TT
11879 LIBS="$am_save_LIBS"
11880 fi
6e3f3080 11881
ba479fd2 11882fi
b61ff9c8
BS
11883echo "$as_me:$LINENO: result: $am_cv_func_iconv" >&5
11884echo "${ECHO_T}$am_cv_func_iconv" >&6
63cf211a 11885 if test "$am_cv_func_iconv" = yes; then
ba479fd2
NN
11886
11887cat >>confdefs.h <<\_ACEOF
f91abfce 11888#define HAVE_ICONV 1
ba479fd2 11889_ACEOF
f91abfce 11890
dfb77e37
KC
11891 fi
11892 if test "$am_cv_lib_iconv" = yes; then
b61ff9c8
BS
11893 echo "$as_me:$LINENO: checking how to link with libiconv" >&5
11894echo $ECHO_N "checking how to link with libiconv... $ECHO_C" >&6
11895 echo "$as_me:$LINENO: result: $LIBICONV" >&5
11896echo "${ECHO_T}$LIBICONV" >&6
dfb77e37
KC
11897 else
11898 CPPFLAGS="$am_save_CPPFLAGS"
11899 LIBICONV=
11900 LTLIBICONV=
11901 fi
11902
11903
11904
11905 if test "$am_cv_func_iconv" = yes; then
b61ff9c8
BS
11906 echo "$as_me:$LINENO: checking for iconv declaration" >&5
11907echo $ECHO_N "checking for iconv declaration... $ECHO_C" >&6
ba479fd2
NN
11908 if test "${am_cv_proto_iconv+set}" = set; then
11909 echo $ECHO_N "(cached) $ECHO_C" >&6
f91abfce 11910else
ba479fd2
NN
11911
11912 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
11913/* confdefs.h. */
11914_ACEOF
11915cat confdefs.h >>conftest.$ac_ext
11916cat >>conftest.$ac_ext <<_ACEOF
11917/* end confdefs.h. */
f91abfce
TT
11918
11919#include <stdlib.h>
11920#include <iconv.h>
11921extern
11922#ifdef __cplusplus
11923"C"
11924#endif
11925#if defined(__STDC__) || defined(__cplusplus)
11926size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);
11927#else
11928size_t iconv();
11929#endif
11930
ba479fd2
NN
11931int
11932main ()
11933{
f91abfce 11934
ba479fd2
NN
11935 ;
11936 return 0;
11937}
11938_ACEOF
11939rm -f conftest.$ac_objext
b61ff9c8
BS
11940if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11941 (eval $ac_compile) 2>conftest.er1
ba479fd2 11942 ac_status=$?
86da66b5
HPN
11943 grep -v '^ *+' conftest.er1 >conftest.err
11944 rm -f conftest.er1
11945 cat conftest.err >&5
ba479fd2 11946 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
11947 (exit $ac_status); } &&
11948 { ac_try='test -z "$ac_c_werror_flag"
11949 || test ! -s conftest.err'
11950 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11951 (eval $ac_try) 2>&5
11952 ac_status=$?
11953 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11954 (exit $ac_status); }; } &&
11955 { ac_try='test -s conftest.$ac_objext'
11956 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11957 (eval $ac_try) 2>&5
11958 ac_status=$?
11959 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11960 (exit $ac_status); }; }; then
f91abfce
TT
11961 am_cv_proto_iconv_arg1=""
11962else
ba479fd2
NN
11963 echo "$as_me: failed program was:" >&5
11964sed 's/^/| /' conftest.$ac_ext >&5
11965
b61ff9c8 11966am_cv_proto_iconv_arg1="const"
f91abfce 11967fi
b61ff9c8 11968rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
f91abfce
TT
11969 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);"
11970fi
11971
11972 am_cv_proto_iconv=`echo "$am_cv_proto_iconv" | tr -s ' ' | sed -e 's/( /(/'`
b61ff9c8 11973 echo "$as_me:$LINENO: result: ${ac_t:-
ba479fd2
NN
11974 }$am_cv_proto_iconv" >&5
11975echo "${ECHO_T}${ac_t:-
b61ff9c8 11976 }$am_cv_proto_iconv" >&6
ba479fd2
NN
11977
11978cat >>confdefs.h <<_ACEOF
f91abfce 11979#define ICONV_CONST $am_cv_proto_iconv_arg1
ba479fd2 11980_ACEOF
f91abfce
TT
11981
11982 fi
f91abfce 11983
56694dd9
ZW
11984# Until we have in-tree GNU iconv:
11985LIBICONV_DEP=
11986
11987
18fc9bd4 11988
b61ff9c8
BS
11989 echo "$as_me:$LINENO: checking for LC_MESSAGES" >&5
11990echo $ECHO_N "checking for LC_MESSAGES... $ECHO_C" >&6
18fc9bd4
RG
11991if test "${am_cv_val_LC_MESSAGES+set}" = set; then
11992 echo $ECHO_N "(cached) $ECHO_C" >&6
11993else
11994 cat >conftest.$ac_ext <<_ACEOF
11995/* confdefs.h. */
11996_ACEOF
11997cat confdefs.h >>conftest.$ac_ext
11998cat >>conftest.$ac_ext <<_ACEOF
11999/* end confdefs.h. */
12000#include <locale.h>
12001int
12002main ()
12003{
12004return LC_MESSAGES
12005 ;
12006 return 0;
12007}
12008_ACEOF
12009rm -f conftest.$ac_objext conftest$ac_exeext
b61ff9c8
BS
12010if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12011 (eval $ac_link) 2>conftest.er1
18fc9bd4
RG
12012 ac_status=$?
12013 grep -v '^ *+' conftest.er1 >conftest.err
12014 rm -f conftest.er1
12015 cat conftest.err >&5
12016 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
12017 (exit $ac_status); } &&
12018 { ac_try='test -z "$ac_c_werror_flag"
12019 || test ! -s conftest.err'
12020 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12021 (eval $ac_try) 2>&5
12022 ac_status=$?
12023 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12024 (exit $ac_status); }; } &&
12025 { ac_try='test -s conftest$ac_exeext'
12026 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12027 (eval $ac_try) 2>&5
12028 ac_status=$?
12029 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12030 (exit $ac_status); }; }; then
18fc9bd4
RG
12031 am_cv_val_LC_MESSAGES=yes
12032else
12033 echo "$as_me: failed program was:" >&5
12034sed 's/^/| /' conftest.$ac_ext >&5
12035
b61ff9c8 12036am_cv_val_LC_MESSAGES=no
18fc9bd4 12037fi
b61ff9c8 12038rm -f conftest.err conftest.$ac_objext \
18fc9bd4
RG
12039 conftest$ac_exeext conftest.$ac_ext
12040fi
b61ff9c8
BS
12041echo "$as_me:$LINENO: result: $am_cv_val_LC_MESSAGES" >&5
12042echo "${ECHO_T}$am_cv_val_LC_MESSAGES" >&6
18fc9bd4
RG
12043 if test $am_cv_val_LC_MESSAGES = yes; then
12044
12045cat >>confdefs.h <<\_ACEOF
12046#define HAVE_LC_MESSAGES 1
12047_ACEOF
12048
12049 fi
12050
f91abfce 12051
a03ea89b 12052
b61ff9c8
BS
12053 echo "$as_me:$LINENO: checking for nl_langinfo and CODESET" >&5
12054echo $ECHO_N "checking for nl_langinfo and CODESET... $ECHO_C" >&6
a03ea89b
BM
12055if test "${am_cv_langinfo_codeset+set}" = set; then
12056 echo $ECHO_N "(cached) $ECHO_C" >&6
12057else
12058 cat >conftest.$ac_ext <<_ACEOF
12059/* confdefs.h. */
12060_ACEOF
12061cat confdefs.h >>conftest.$ac_ext
12062cat >>conftest.$ac_ext <<_ACEOF
12063/* end confdefs.h. */
12064#include <langinfo.h>
12065int
12066main ()
12067{
12068char* cs = nl_langinfo(CODESET);
12069 ;
12070 return 0;
12071}
12072_ACEOF
12073rm -f conftest.$ac_objext conftest$ac_exeext
b61ff9c8
BS
12074if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12075 (eval $ac_link) 2>conftest.er1
a03ea89b
BM
12076 ac_status=$?
12077 grep -v '^ *+' conftest.er1 >conftest.err
12078 rm -f conftest.er1
12079 cat conftest.err >&5
12080 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
12081 (exit $ac_status); } &&
12082 { ac_try='test -z "$ac_c_werror_flag"
12083 || test ! -s conftest.err'
12084 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12085 (eval $ac_try) 2>&5
12086 ac_status=$?
12087 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12088 (exit $ac_status); }; } &&
12089 { ac_try='test -s conftest$ac_exeext'
12090 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12091 (eval $ac_try) 2>&5
12092 ac_status=$?
12093 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12094 (exit $ac_status); }; }; then
a03ea89b
BM
12095 am_cv_langinfo_codeset=yes
12096else
12097 echo "$as_me: failed program was:" >&5
12098sed 's/^/| /' conftest.$ac_ext >&5
12099
b61ff9c8 12100am_cv_langinfo_codeset=no
a03ea89b 12101fi
b61ff9c8 12102rm -f conftest.err conftest.$ac_objext \
a03ea89b
BM
12103 conftest$ac_exeext conftest.$ac_ext
12104
12105fi
b61ff9c8
BS
12106echo "$as_me:$LINENO: result: $am_cv_langinfo_codeset" >&5
12107echo "${ECHO_T}$am_cv_langinfo_codeset" >&6
a03ea89b
BM
12108 if test $am_cv_langinfo_codeset = yes; then
12109
12110cat >>confdefs.h <<\_ACEOF
12111#define HAVE_LANGINFO_CODESET 1
12112_ACEOF
12113
12114 fi
12115
12116
86cf1cbd
KG
12117# We will need to find libiberty.h and ansidecl.h
12118saved_CFLAGS="$CFLAGS"
12119CFLAGS="$CFLAGS -I${srcdir} -I${srcdir}/../include"
ad6717df
PB
12120
12121
12122
12123
12124
12125
12126
12127
12128
12129
12130
12131
12132
12133
12134
12135
12136
12137
12138
12139
12140
6a257778 12141
ad6717df
PB
12142
12143
0d667716
KG
12144
12145
12146
12147
12148
12149
12150
12151
12152
12153
367e8319 12154
0d667716
KG
12155
12156
7391b66c 12157
ed5b9f96
GK
12158
12159for ac_func in getenv atol asprintf sbrk abort atof getcwd getwd \
12160 strsignal strstr strverscmp \
12161 errno snprintf vsnprintf vasprintf malloc realloc calloc \
367e8319 12162 free basename getopt clock getpagesize clearerr_unlocked feof_unlocked ferror_unlocked fflush_unlocked fgetc_unlocked fgets_unlocked fileno_unlocked fprintf_unlocked fputc_unlocked fputs_unlocked fread_unlocked fwrite_unlocked getchar_unlocked getc_unlocked putchar_unlocked putc_unlocked
81bf3d9e 12163do
ad6717df 12164 ac_tr_decl=`echo "HAVE_DECL_$ac_func" | $as_tr_cpp`
b61ff9c8
BS
12165echo "$as_me:$LINENO: checking whether $ac_func is declared" >&5
12166echo $ECHO_N "checking whether $ac_func is declared... $ECHO_C" >&6
12167if eval "test \"\${gcc_cv_have_decl_$ac_func+set}\" = set"; then
ba479fd2
NN
12168 echo $ECHO_N "(cached) $ECHO_C" >&6
12169else
12170 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
12171/* confdefs.h. */
12172_ACEOF
12173cat confdefs.h >>conftest.$ac_ext
12174cat >>conftest.$ac_ext <<_ACEOF
12175/* end confdefs.h. */
7afe8c41
KG
12176#undef $ac_tr_decl
12177#define $ac_tr_decl 1
ba479fd2 12178
d02af173 12179#include "ansidecl.h"
86cf1cbd 12180#include "system.h"
f31e826b 12181
ba479fd2
NN
12182int
12183main ()
12184{
86cf1cbd
KG
12185#ifndef $ac_func
12186char *(*pfn) = (char *(*)) $ac_func ;
12187#endif
ba479fd2
NN
12188 ;
12189 return 0;
12190}
12191_ACEOF
12192rm -f conftest.$ac_objext
b61ff9c8
BS
12193if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12194 (eval $ac_compile) 2>conftest.er1
ba479fd2 12195 ac_status=$?
86da66b5
HPN
12196 grep -v '^ *+' conftest.er1 >conftest.err
12197 rm -f conftest.er1
12198 cat conftest.err >&5
ba479fd2 12199 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
12200 (exit $ac_status); } &&
12201 { ac_try='test -z "$ac_c_werror_flag"
12202 || test ! -s conftest.err'
12203 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12204 (eval $ac_try) 2>&5
12205 ac_status=$?
12206 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12207 (exit $ac_status); }; } &&
12208 { ac_try='test -s conftest.$ac_objext'
12209 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12210 (eval $ac_try) 2>&5
12211 ac_status=$?
12212 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12213 (exit $ac_status); }; }; then
f31e826b 12214 eval "gcc_cv_have_decl_$ac_func=yes"
81bf3d9e 12215else
ba479fd2
NN
12216 echo "$as_me: failed program was:" >&5
12217sed 's/^/| /' conftest.$ac_ext >&5
12218
b61ff9c8 12219eval "gcc_cv_have_decl_$ac_func=no"
81bf3d9e 12220fi
b61ff9c8 12221rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
81bf3d9e
RH
12222fi
12223
f31e826b 12224if eval "test \"`echo '$gcc_cv_have_decl_'$ac_func`\" = yes"; then
b61ff9c8
BS
12225 echo "$as_me:$LINENO: result: yes" >&5
12226echo "${ECHO_T}yes" >&6 ; cat >>confdefs.h <<_ACEOF
86cf1cbd 12227#define $ac_tr_decl 1
ba479fd2
NN
12228_ACEOF
12229
81bf3d9e 12230else
b61ff9c8
BS
12231 echo "$as_me:$LINENO: result: no" >&5
12232echo "${ECHO_T}no" >&6 ; cat >>confdefs.h <<_ACEOF
f31e826b 12233#define $ac_tr_decl 0
ba479fd2
NN
12234_ACEOF
12235
81bf3d9e
RH
12236fi
12237
12238done
ba479fd2 12239
ba479fd2 12240
ba479fd2 12241
81bf3d9e 12242
81bf3d9e
RH
12243
12244for ac_func in getrlimit setrlimit getrusage
12245do
ad6717df 12246 ac_tr_decl=`echo "HAVE_DECL_$ac_func" | $as_tr_cpp`
b61ff9c8
BS
12247echo "$as_me:$LINENO: checking whether $ac_func is declared" >&5
12248echo $ECHO_N "checking whether $ac_func is declared... $ECHO_C" >&6
12249if eval "test \"\${gcc_cv_have_decl_$ac_func+set}\" = set"; then
ba479fd2
NN
12250 echo $ECHO_N "(cached) $ECHO_C" >&6
12251else
12252 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
12253/* confdefs.h. */
12254_ACEOF
12255cat confdefs.h >>conftest.$ac_ext
12256cat >>conftest.$ac_ext <<_ACEOF
12257/* end confdefs.h. */
7afe8c41
KG
12258#undef $ac_tr_decl
12259#define $ac_tr_decl 1
ba479fd2 12260
d02af173 12261#include "ansidecl.h"
86cf1cbd 12262#include "system.h"
81bf3d9e
RH
12263#ifdef HAVE_SYS_RESOURCE_H
12264#include <sys/resource.h>
12265#endif
12266
f31e826b 12267
ba479fd2
NN
12268int
12269main ()
12270{
86cf1cbd
KG
12271#ifndef $ac_func
12272char *(*pfn) = (char *(*)) $ac_func ;
12273#endif
ba479fd2
NN
12274 ;
12275 return 0;
12276}
12277_ACEOF
12278rm -f conftest.$ac_objext
b61ff9c8
BS
12279if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12280 (eval $ac_compile) 2>conftest.er1
ba479fd2 12281 ac_status=$?
86da66b5
HPN
12282 grep -v '^ *+' conftest.er1 >conftest.err
12283 rm -f conftest.er1
12284 cat conftest.err >&5
ba479fd2 12285 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
12286 (exit $ac_status); } &&
12287 { ac_try='test -z "$ac_c_werror_flag"
12288 || test ! -s conftest.err'
12289 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12290 (eval $ac_try) 2>&5
12291 ac_status=$?
12292 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12293 (exit $ac_status); }; } &&
12294 { ac_try='test -s conftest.$ac_objext'
12295 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12296 (eval $ac_try) 2>&5
12297 ac_status=$?
12298 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12299 (exit $ac_status); }; }; then
f31e826b 12300 eval "gcc_cv_have_decl_$ac_func=yes"
81bf3d9e 12301else
ba479fd2
NN
12302 echo "$as_me: failed program was:" >&5
12303sed 's/^/| /' conftest.$ac_ext >&5
12304
b61ff9c8 12305eval "gcc_cv_have_decl_$ac_func=no"
81bf3d9e 12306fi
b61ff9c8 12307rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
81bf3d9e
RH
12308fi
12309
f31e826b 12310if eval "test \"`echo '$gcc_cv_have_decl_'$ac_func`\" = yes"; then
b61ff9c8
BS
12311 echo "$as_me:$LINENO: result: yes" >&5
12312echo "${ECHO_T}yes" >&6 ; cat >>confdefs.h <<_ACEOF
86cf1cbd 12313#define $ac_tr_decl 1
ba479fd2
NN
12314_ACEOF
12315
81bf3d9e 12316else
b61ff9c8
BS
12317 echo "$as_me:$LINENO: result: no" >&5
12318echo "${ECHO_T}no" >&6 ; cat >>confdefs.h <<_ACEOF
f31e826b 12319#define $ac_tr_decl 0
ba479fd2
NN
12320_ACEOF
12321
81bf3d9e
RH
12322fi
12323
12324done
86cf1cbd 12325
81bf3d9e 12326
ba479fd2 12327cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
12328/* confdefs.h. */
12329_ACEOF
12330cat confdefs.h >>conftest.$ac_ext
12331cat >>conftest.$ac_ext <<_ACEOF
12332/* end confdefs.h. */
b2522d2b
HPN
12333
12334#include "ansidecl.h"
12335#include "system.h"
12336#ifdef HAVE_SYS_RESOURCE_H
12337#include <sys/resource.h>
12338#endif
12339
ba479fd2
NN
12340int
12341main ()
12342{
b2522d2b 12343rlim_t l = 0;
ba479fd2
NN
12344 ;
12345 return 0;
12346}
12347_ACEOF
12348rm -f conftest.$ac_objext
b61ff9c8
BS
12349if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12350 (eval $ac_compile) 2>conftest.er1
ba479fd2 12351 ac_status=$?
86da66b5
HPN
12352 grep -v '^ *+' conftest.er1 >conftest.err
12353 rm -f conftest.er1
12354 cat conftest.err >&5
ba479fd2 12355 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
12356 (exit $ac_status); } &&
12357 { ac_try='test -z "$ac_c_werror_flag"
12358 || test ! -s conftest.err'
12359 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12360 (eval $ac_try) 2>&5
12361 ac_status=$?
12362 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12363 (exit $ac_status); }; } &&
12364 { ac_try='test -s conftest.$ac_objext'
12365 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12366 (eval $ac_try) 2>&5
12367 ac_status=$?
12368 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12369 (exit $ac_status); }; }; then
b2522d2b
HPN
12370 :
12371else
ba479fd2
NN
12372 echo "$as_me: failed program was:" >&5
12373sed 's/^/| /' conftest.$ac_ext >&5
12374
12375
12376cat >>confdefs.h <<\_ACEOF
b2522d2b 12377#define rlim_t long
ba479fd2 12378_ACEOF
b2522d2b
HPN
12379
12380fi
b61ff9c8 12381rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
b2522d2b 12382
2102b2fe
RS
12383# On AIX 5.2, <ldfcn.h> conflicts with <fcntl.h>, as both define incompatible
12384# FREAD and FWRITE macros. Fortunately, for GCC's single usage of ldgetname
12385# in collect2.c, <fcntl.h> isn't visible, but the configure test below needs
12386# to undef these macros to get the correct value for HAVE_DECL_LDGETNAME.
ad6717df 12387
351df804 12388for ac_func in ldgetname
c1800ec8 12389do
ad6717df 12390 ac_tr_decl=`echo "HAVE_DECL_$ac_func" | $as_tr_cpp`
b61ff9c8
BS
12391echo "$as_me:$LINENO: checking whether $ac_func is declared" >&5
12392echo $ECHO_N "checking whether $ac_func is declared... $ECHO_C" >&6
12393if eval "test \"\${gcc_cv_have_decl_$ac_func+set}\" = set"; then
ba479fd2
NN
12394 echo $ECHO_N "(cached) $ECHO_C" >&6
12395else
12396 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
12397/* confdefs.h. */
12398_ACEOF
12399cat confdefs.h >>conftest.$ac_ext
12400cat >>conftest.$ac_ext <<_ACEOF
12401/* end confdefs.h. */
c1800ec8
ZW
12402#undef $ac_tr_decl
12403#define $ac_tr_decl 1
ba479fd2 12404
351df804
KG
12405#include "ansidecl.h"
12406#include "system.h"
12407#ifdef HAVE_LDFCN_H
2102b2fe
RS
12408#undef FREAD
12409#undef FWRITE
351df804
KG
12410#include <ldfcn.h>
12411#endif
12412
12413
ba479fd2
NN
12414int
12415main ()
12416{
351df804
KG
12417#ifndef $ac_func
12418char *(*pfn) = (char *(*)) $ac_func ;
12419#endif
ba479fd2
NN
12420 ;
12421 return 0;
12422}
12423_ACEOF
12424rm -f conftest.$ac_objext
b61ff9c8
BS
12425if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12426 (eval $ac_compile) 2>conftest.er1
ba479fd2 12427 ac_status=$?
86da66b5
HPN
12428 grep -v '^ *+' conftest.er1 >conftest.err
12429 rm -f conftest.er1
12430 cat conftest.err >&5
ba479fd2 12431 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
12432 (exit $ac_status); } &&
12433 { ac_try='test -z "$ac_c_werror_flag"
12434 || test ! -s conftest.err'
12435 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12436 (eval $ac_try) 2>&5
12437 ac_status=$?
12438 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12439 (exit $ac_status); }; } &&
12440 { ac_try='test -s conftest.$ac_objext'
12441 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12442 (eval $ac_try) 2>&5
12443 ac_status=$?
12444 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12445 (exit $ac_status); }; }; then
351df804
KG
12446 eval "gcc_cv_have_decl_$ac_func=yes"
12447else
ba479fd2
NN
12448 echo "$as_me: failed program was:" >&5
12449sed 's/^/| /' conftest.$ac_ext >&5
12450
b61ff9c8 12451eval "gcc_cv_have_decl_$ac_func=no"
351df804 12452fi
b61ff9c8 12453rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
351df804
KG
12454fi
12455
12456if eval "test \"`echo '$gcc_cv_have_decl_'$ac_func`\" = yes"; then
b61ff9c8
BS
12457 echo "$as_me:$LINENO: result: yes" >&5
12458echo "${ECHO_T}yes" >&6 ; cat >>confdefs.h <<_ACEOF
351df804 12459#define $ac_tr_decl 1
ba479fd2
NN
12460_ACEOF
12461
351df804 12462else
b61ff9c8
BS
12463 echo "$as_me:$LINENO: result: no" >&5
12464echo "${ECHO_T}no" >&6 ; cat >>confdefs.h <<_ACEOF
351df804 12465#define $ac_tr_decl 0
ba479fd2
NN
12466_ACEOF
12467
351df804
KG
12468fi
12469
12470done
ba479fd2 12471
351df804
KG
12472
12473
12474for ac_func in times
12475do
ad6717df 12476 ac_tr_decl=`echo "HAVE_DECL_$ac_func" | $as_tr_cpp`
b61ff9c8
BS
12477echo "$as_me:$LINENO: checking whether $ac_func is declared" >&5
12478echo $ECHO_N "checking whether $ac_func is declared... $ECHO_C" >&6
12479if eval "test \"\${gcc_cv_have_decl_$ac_func+set}\" = set"; then
ba479fd2
NN
12480 echo $ECHO_N "(cached) $ECHO_C" >&6
12481else
12482 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
12483/* confdefs.h. */
12484_ACEOF
12485cat confdefs.h >>conftest.$ac_ext
12486cat >>conftest.$ac_ext <<_ACEOF
12487/* end confdefs.h. */
351df804
KG
12488#undef $ac_tr_decl
12489#define $ac_tr_decl 1
ba479fd2 12490
c1800ec8
ZW
12491#include "ansidecl.h"
12492#include "system.h"
12493#ifdef HAVE_SYS_TIMES_H
12494#include <sys/times.h>
12495#endif
12496
12497
ba479fd2
NN
12498int
12499main ()
12500{
c1800ec8
ZW
12501#ifndef $ac_func
12502char *(*pfn) = (char *(*)) $ac_func ;
12503#endif
ba479fd2
NN
12504 ;
12505 return 0;
12506}
12507_ACEOF
12508rm -f conftest.$ac_objext
b61ff9c8
BS
12509if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12510 (eval $ac_compile) 2>conftest.er1
ba479fd2 12511 ac_status=$?
86da66b5
HPN
12512 grep -v '^ *+' conftest.er1 >conftest.err
12513 rm -f conftest.er1
12514 cat conftest.err >&5
ba479fd2 12515 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
12516 (exit $ac_status); } &&
12517 { ac_try='test -z "$ac_c_werror_flag"
12518 || test ! -s conftest.err'
12519 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12520 (eval $ac_try) 2>&5
12521 ac_status=$?
12522 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12523 (exit $ac_status); }; } &&
12524 { ac_try='test -s conftest.$ac_objext'
12525 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12526 (eval $ac_try) 2>&5
12527 ac_status=$?
12528 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12529 (exit $ac_status); }; }; then
2f41c1d6
PB
12530 eval "gcc_cv_have_decl_$ac_func=yes"
12531else
12532 echo "$as_me: failed program was:" >&5
12533sed 's/^/| /' conftest.$ac_ext >&5
ab22c1fa 12534
b61ff9c8 12535eval "gcc_cv_have_decl_$ac_func=no"
2f41c1d6 12536fi
b61ff9c8 12537rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c1800ec8
ZW
12538fi
12539
12540if eval "test \"`echo '$gcc_cv_have_decl_'$ac_func`\" = yes"; then
b61ff9c8
BS
12541 echo "$as_me:$LINENO: result: yes" >&5
12542echo "${ECHO_T}yes" >&6 ; cat >>confdefs.h <<_ACEOF
c1800ec8 12543#define $ac_tr_decl 1
ba479fd2
NN
12544_ACEOF
12545
c1800ec8 12546else
b61ff9c8
BS
12547 echo "$as_me:$LINENO: result: no" >&5
12548echo "${ECHO_T}no" >&6 ; cat >>confdefs.h <<_ACEOF
c1800ec8 12549#define $ac_tr_decl 0
ba479fd2
NN
12550_ACEOF
12551
c1800ec8
ZW
12552fi
12553
12554done
c1800ec8
ZW
12555
12556
4f6d8cc8
GK
12557
12558for ac_func in sigaltstack
12559do
12560 ac_tr_decl=`echo "HAVE_DECL_$ac_func" | $as_tr_cpp`
b61ff9c8
BS
12561echo "$as_me:$LINENO: checking whether $ac_func is declared" >&5
12562echo $ECHO_N "checking whether $ac_func is declared... $ECHO_C" >&6
12563if eval "test \"\${gcc_cv_have_decl_$ac_func+set}\" = set"; then
4f6d8cc8
GK
12564 echo $ECHO_N "(cached) $ECHO_C" >&6
12565else
12566 cat >conftest.$ac_ext <<_ACEOF
12567/* confdefs.h. */
12568_ACEOF
12569cat confdefs.h >>conftest.$ac_ext
12570cat >>conftest.$ac_ext <<_ACEOF
12571/* end confdefs.h. */
12572#undef $ac_tr_decl
12573#define $ac_tr_decl 1
12574
12575#include "ansidecl.h"
12576#include "system.h"
12577#include <signal.h>
12578
12579
12580int
12581main ()
12582{
12583#ifndef $ac_func
12584char *(*pfn) = (char *(*)) $ac_func ;
12585#endif
12586 ;
12587 return 0;
12588}
12589_ACEOF
12590rm -f conftest.$ac_objext
b61ff9c8
BS
12591if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12592 (eval $ac_compile) 2>conftest.er1
4f6d8cc8
GK
12593 ac_status=$?
12594 grep -v '^ *+' conftest.er1 >conftest.err
12595 rm -f conftest.er1
12596 cat conftest.err >&5
12597 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
12598 (exit $ac_status); } &&
12599 { ac_try='test -z "$ac_c_werror_flag"
12600 || test ! -s conftest.err'
12601 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12602 (eval $ac_try) 2>&5
12603 ac_status=$?
12604 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12605 (exit $ac_status); }; } &&
12606 { ac_try='test -s conftest.$ac_objext'
12607 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12608 (eval $ac_try) 2>&5
12609 ac_status=$?
12610 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12611 (exit $ac_status); }; }; then
8b1f719a
PB
12612 eval "gcc_cv_have_decl_$ac_func=yes"
12613else
12614 echo "$as_me: failed program was:" >&5
12615sed 's/^/| /' conftest.$ac_ext >&5
4f6d8cc8 12616
b61ff9c8 12617eval "gcc_cv_have_decl_$ac_func=no"
4f6d8cc8 12618fi
b61ff9c8 12619rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
4f6d8cc8
GK
12620fi
12621
12622if eval "test \"`echo '$gcc_cv_have_decl_'$ac_func`\" = yes"; then
b61ff9c8
BS
12623 echo "$as_me:$LINENO: result: yes" >&5
12624echo "${ECHO_T}yes" >&6 ; cat >>confdefs.h <<_ACEOF
4f6d8cc8
GK
12625#define $ac_tr_decl 1
12626_ACEOF
12627
12628else
b61ff9c8
BS
12629 echo "$as_me:$LINENO: result: no" >&5
12630echo "${ECHO_T}no" >&6 ; cat >>confdefs.h <<_ACEOF
4f6d8cc8
GK
12631#define $ac_tr_decl 0
12632_ACEOF
12633
12634fi
12635
12636done
12637
12638
c1800ec8 12639# More time-related stuff.
b61ff9c8
BS
12640echo "$as_me:$LINENO: checking for struct tms" >&5
12641echo $ECHO_N "checking for struct tms... $ECHO_C" >&6
ba479fd2
NN
12642if test "${ac_cv_struct_tms+set}" = set; then
12643 echo $ECHO_N "(cached) $ECHO_C" >&6
12644else
12645
12646cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
12647/* confdefs.h. */
12648_ACEOF
12649cat confdefs.h >>conftest.$ac_ext
12650cat >>conftest.$ac_ext <<_ACEOF
12651/* end confdefs.h. */
c1800ec8
ZW
12652
12653#include "ansidecl.h"
12654#include "system.h"
12655#ifdef HAVE_SYS_TIMES_H
12656#include <sys/times.h>
12657#endif
12658
ba479fd2
NN
12659int
12660main ()
12661{
c1800ec8 12662struct tms tms;
ba479fd2
NN
12663 ;
12664 return 0;
12665}
12666_ACEOF
12667rm -f conftest.$ac_objext
b61ff9c8
BS
12668if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12669 (eval $ac_compile) 2>conftest.er1
ba479fd2 12670 ac_status=$?
86da66b5
HPN
12671 grep -v '^ *+' conftest.er1 >conftest.err
12672 rm -f conftest.er1
12673 cat conftest.err >&5
ba479fd2 12674 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
12675 (exit $ac_status); } &&
12676 { ac_try='test -z "$ac_c_werror_flag"
12677 || test ! -s conftest.err'
12678 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12679 (eval $ac_try) 2>&5
12680 ac_status=$?
12681 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12682 (exit $ac_status); }; } &&
12683 { ac_try='test -s conftest.$ac_objext'
12684 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12685 (eval $ac_try) 2>&5
12686 ac_status=$?
12687 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12688 (exit $ac_status); }; }; then
c1800ec8
ZW
12689 ac_cv_struct_tms=yes
12690else
ba479fd2
NN
12691 echo "$as_me: failed program was:" >&5
12692sed 's/^/| /' conftest.$ac_ext >&5
12693
b61ff9c8 12694ac_cv_struct_tms=no
c1800ec8 12695fi
b61ff9c8 12696rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c1800ec8 12697fi
b61ff9c8
BS
12698echo "$as_me:$LINENO: result: $ac_cv_struct_tms" >&5
12699echo "${ECHO_T}$ac_cv_struct_tms" >&6
63cf211a 12700if test $ac_cv_struct_tms = yes; then
ba479fd2
NN
12701
12702cat >>confdefs.h <<\_ACEOF
c1800ec8 12703#define HAVE_STRUCT_TMS 1
ba479fd2 12704_ACEOF
c1800ec8
ZW
12705
12706fi
12707
12708# use gcc_cv_* here because this doesn't match the behavior of AC_CHECK_TYPE.
12709# revisit after autoconf 2.50.
b61ff9c8
BS
12710echo "$as_me:$LINENO: checking for clock_t" >&5
12711echo $ECHO_N "checking for clock_t... $ECHO_C" >&6
ba479fd2
NN
12712if test "${gcc_cv_type_clock_t+set}" = set; then
12713 echo $ECHO_N "(cached) $ECHO_C" >&6
12714else
12715
12716cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
12717/* confdefs.h. */
12718_ACEOF
12719cat confdefs.h >>conftest.$ac_ext
12720cat >>conftest.$ac_ext <<_ACEOF
12721/* end confdefs.h. */
c1800ec8
ZW
12722
12723#include "ansidecl.h"
12724#include "system.h"
12725
ba479fd2
NN
12726int
12727main ()
12728{
c1800ec8 12729clock_t x;
ba479fd2
NN
12730 ;
12731 return 0;
12732}
12733_ACEOF
12734rm -f conftest.$ac_objext
b61ff9c8
BS
12735if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12736 (eval $ac_compile) 2>conftest.er1
ba479fd2 12737 ac_status=$?
86da66b5
HPN
12738 grep -v '^ *+' conftest.er1 >conftest.err
12739 rm -f conftest.er1
12740 cat conftest.err >&5
ba479fd2 12741 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
12742 (exit $ac_status); } &&
12743 { ac_try='test -z "$ac_c_werror_flag"
12744 || test ! -s conftest.err'
12745 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12746 (eval $ac_try) 2>&5
12747 ac_status=$?
12748 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12749 (exit $ac_status); }; } &&
12750 { ac_try='test -s conftest.$ac_objext'
12751 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12752 (eval $ac_try) 2>&5
12753 ac_status=$?
12754 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12755 (exit $ac_status); }; }; then
c1800ec8
ZW
12756 gcc_cv_type_clock_t=yes
12757else
ba479fd2
NN
12758 echo "$as_me: failed program was:" >&5
12759sed 's/^/| /' conftest.$ac_ext >&5
12760
b61ff9c8 12761gcc_cv_type_clock_t=no
c1800ec8 12762fi
b61ff9c8 12763rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c1800ec8 12764fi
b61ff9c8
BS
12765echo "$as_me:$LINENO: result: $gcc_cv_type_clock_t" >&5
12766echo "${ECHO_T}$gcc_cv_type_clock_t" >&6
63cf211a 12767if test $gcc_cv_type_clock_t = yes; then
ba479fd2
NN
12768
12769cat >>confdefs.h <<\_ACEOF
c1800ec8 12770#define HAVE_CLOCK_T 1
ba479fd2 12771_ACEOF
c1800ec8
ZW
12772
12773fi
12774
eb70d86d
AS
12775# Restore CFLAGS from before the gcc_AC_NEED_DECLARATIONS tests.
12776CFLAGS="$saved_CFLAGS"
12777
b61ff9c8 12778# Check whether --enable-initfini-array or --disable-initfini-array was given.
07cf4226 12779if test "${enable_initfini_array+set}" = set; then
b61ff9c8
BS
12780 enableval="$enable_initfini_array"
12781
07cf4226 12782else
ba479fd2 12783
b61ff9c8
BS
12784echo "$as_me:$LINENO: checking for .preinit_array/.init_array/.fini_array support" >&5
12785echo $ECHO_N "checking for .preinit_array/.init_array/.fini_array support... $ECHO_C" >&6
ba479fd2
NN
12786if test "${gcc_cv_initfini_array+set}" = set; then
12787 echo $ECHO_N "(cached) $ECHO_C" >&6
07cf4226 12788else
eb70d86d 12789 if test "$cross_compiling" = yes; then
918c4fe4 12790 gcc_cv_initfini_array=no
eb70d86d 12791else
ba479fd2 12792 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
12793/* confdefs.h. */
12794_ACEOF
12795cat confdefs.h >>conftest.$ac_ext
12796cat >>conftest.$ac_ext <<_ACEOF
12797/* end confdefs.h. */
eb70d86d 12798
07cf4226
DM
12799static int x = -1;
12800int main (void) { return x; }
12801int foo (void) { x = 0; }
12802int (*fp) (void) __attribute__ ((section (".init_array"))) = foo;
ba479fd2
NN
12803_ACEOF
12804rm -f conftest$ac_exeext
b61ff9c8
BS
12805if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12806 (eval $ac_link) 2>&5
ba479fd2
NN
12807 ac_status=$?
12808 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12809 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
b61ff9c8
BS
12810 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12811 (eval $ac_try) 2>&5
ba479fd2
NN
12812 ac_status=$?
12813 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12814 (exit $ac_status); }; }; then
918c4fe4 12815 gcc_cv_initfini_array=yes
eb70d86d 12816else
ba479fd2
NN
12817 echo "$as_me: program exited with status $ac_status" >&5
12818echo "$as_me: failed program was:" >&5
12819sed 's/^/| /' conftest.$ac_ext >&5
12820
12821( exit $ac_status )
12822gcc_cv_initfini_array=no
eb70d86d 12823fi
b61ff9c8 12824rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
eb70d86d 12825fi
07cf4226 12826fi
b61ff9c8
BS
12827echo "$as_me:$LINENO: result: $gcc_cv_initfini_array" >&5
12828echo "${ECHO_T}$gcc_cv_initfini_array" >&6
eb70d86d 12829 enable_initfini_array=$gcc_cv_initfini_array
07cf4226 12830
b61ff9c8 12831fi;
63cf211a 12832if test $enable_initfini_array = yes; then
ba479fd2
NN
12833
12834cat >>confdefs.h <<\_ACEOF
eb70d86d 12835#define HAVE_INITFINI_ARRAY 1
ba479fd2 12836_ACEOF
07cf4226 12837
eb70d86d 12838fi
81bf3d9e 12839
ba479fd2 12840# mkdir takes a single argument on some systems.
b61ff9c8
BS
12841echo "$as_me:$LINENO: checking if mkdir takes one argument" >&5
12842echo $ECHO_N "checking if mkdir takes one argument... $ECHO_C" >&6
ba479fd2
NN
12843if test "${gcc_cv_mkdir_takes_one_arg+set}" = set; then
12844 echo $ECHO_N "(cached) $ECHO_C" >&6
75923b2f 12845else
ba479fd2 12846 cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
12847/* confdefs.h. */
12848_ACEOF
12849cat confdefs.h >>conftest.$ac_ext
12850cat >>conftest.$ac_ext <<_ACEOF
12851/* end confdefs.h. */
75923b2f
MK
12852
12853#include <sys/types.h>
12854#ifdef HAVE_SYS_STAT_H
12855# include <sys/stat.h>
12856#endif
12857#ifdef HAVE_UNISTD_H
12858# include <unistd.h>
12859#endif
12860#ifdef HAVE_DIRECT_H
12861# include <direct.h>
12862#endif
ba479fd2
NN
12863int
12864main ()
12865{
75923b2f 12866mkdir ("foo", 0);
ba479fd2
NN
12867 ;
12868 return 0;
12869}
12870_ACEOF
12871rm -f conftest.$ac_objext
b61ff9c8
BS
12872if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12873 (eval $ac_compile) 2>conftest.er1
ba479fd2 12874 ac_status=$?
86da66b5
HPN
12875 grep -v '^ *+' conftest.er1 >conftest.err
12876 rm -f conftest.er1
12877 cat conftest.err >&5
ba479fd2 12878 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
12879 (exit $ac_status); } &&
12880 { ac_try='test -z "$ac_c_werror_flag"
12881 || test ! -s conftest.err'
12882 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12883 (eval $ac_try) 2>&5
12884 ac_status=$?
12885 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12886 (exit $ac_status); }; } &&
12887 { ac_try='test -s conftest.$ac_objext'
12888 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12889 (eval $ac_try) 2>&5
12890 ac_status=$?
12891 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12892 (exit $ac_status); }; }; then
75923b2f
MK
12893 gcc_cv_mkdir_takes_one_arg=no
12894else
ba479fd2
NN
12895 echo "$as_me: failed program was:" >&5
12896sed 's/^/| /' conftest.$ac_ext >&5
12897
b61ff9c8 12898gcc_cv_mkdir_takes_one_arg=yes
75923b2f 12899fi
b61ff9c8 12900rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
75923b2f 12901fi
b61ff9c8
BS
12902echo "$as_me:$LINENO: result: $gcc_cv_mkdir_takes_one_arg" >&5
12903echo "${ECHO_T}$gcc_cv_mkdir_takes_one_arg" >&6
63cf211a 12904if test $gcc_cv_mkdir_takes_one_arg = yes ; then
ba479fd2
NN
12905
12906cat >>confdefs.h <<\_ACEOF
75923b2f 12907#define MKDIR_TAKES_ONE_ARG 1
ba479fd2 12908_ACEOF
75923b2f
MK
12909
12910fi
12911
12912
861bb6c1
JL
12913# File extensions
12914manext='.1'
12915objext='.o'
12916
12917
12918
4977bab6 12919# With Setjmp/Longjmp based exception handling.
b61ff9c8 12920# Check whether --enable-sjlj-exceptions or --disable-sjlj-exceptions was given.
4977bab6 12921if test "${enable_sjlj_exceptions+set}" = set; then
b61ff9c8 12922 enableval="$enable_sjlj_exceptions"
399fe3e1
JDA
12923 case $target in
12924 *-*-hpux10*)
12925 if test $enableval != yes; then
12926 { echo "$as_me:$LINENO: WARNING: dwarf2 exceptions not supported, sjlj exceptions forced" >&5
12927echo "$as_me: WARNING: dwarf2 exceptions not supported, sjlj exceptions forced" >&2;}
12928 enableval=yes
12929 fi
12930 ;;
12931esac
12932force_sjlj_exceptions=yes
12933else
12934 case $target in
12935 *-*-hpux10*)
12936 force_sjlj_exceptions=yes
12937 enableval=yes
12938 ;;
12939 *)
12940 force_sjlj_exceptions=no
12941 ;;
12942esac
12943fi;
12944if test $force_sjlj_exceptions = yes; then
b61ff9c8 12945 sjlj=`if test $enableval = yes; then echo 1; else echo 0; fi`
63cf211a 12946
ba479fd2
NN
12947cat >>confdefs.h <<_ACEOF
12948#define CONFIG_SJLJ_EXCEPTIONS $sjlj
12949_ACEOF
4977bab6 12950
399fe3e1 12951fi
4977bab6 12952
443728bb
L
12953# For platforms with the unwind ABI which includes an unwind library,
12954# libunwind, we can choose to use the system libunwind.
e61c76c9
SE
12955# config.gcc also contains tests of with_system_libunwind.
12956
4977bab6 12957
b61ff9c8 12958# Check whether --with-system-libunwind or --without-system-libunwind was given.
443728bb 12959if test "${with_system_libunwind+set}" = set; then
b61ff9c8 12960 withval="$with_system_libunwind"
4977bab6 12961
b61ff9c8 12962fi;
e61c76c9
SE
12963 # If system-libunwind was not specifically set, pick a default setting.
12964 if test x$with_system_libunwind = x; then
12965 case ${target} in
12966 ia64-*-hpux*) with_system_libunwind=yes ;;
12967 *) with_system_libunwind=no ;;
12968 esac
12969 fi
12970 # Based on system-libunwind and target, do we have ipinfo?
12971 if test x$with_system_libunwind = xyes; then
12972 case ${target} in
12973 ia64-*-*) have_unwind_getipinfo=no ;;
12974 *) have_unwind_getipinfo=yes ;;
12975 esac
12976 else
a0e02041
AP
12977 # Darwin before version 9 does not have _Unwind_GetIPInfo.
12978
12979 case ${target} in
12980 *-*-darwin[3-8]|*-*-darwin[3-8].*) have_unwind_getipinfo=no ;;
12981 *) have_unwind_getipinfo=yes ;;
12982 esac
12983
e61c76c9 12984 fi
4977bab6 12985
e61c76c9 12986 if test x$have_unwind_getipinfo = xyes; then
e64f5acf
SE
12987
12988cat >>confdefs.h <<\_ACEOF
12989#define HAVE_GETIPINFO 1
12990_ACEOF
12991
e61c76c9
SE
12992 fi
12993
e64f5acf 12994
34a86c2b
NN
12995# --------------------------------------------------------
12996# Build, host, and target specific configuration fragments
12997# --------------------------------------------------------
12998
5b28c537
NN
12999# Collect build-machine-specific information.
13000. ${srcdir}/config.build
13001
a89ea0df
NN
13002# Collect host-machine-specific information.
13003. ${srcdir}/config.host
13004
ef69da62 13005target_gtfiles=
a89ea0df
NN
13006
13007# Collect target-machine-specific information.
8ad9fb33 13008. ${srcdir}/config.gcc
861bb6c1
JL
13009
13010extra_objs="${host_extra_objs} ${extra_objs}"
30500d84 13011extra_gcc_objs="${host_extra_gcc_objs} ${extra_gcc_objs}"
861bb6c1
JL
13012
13013# Default the target-machine variables that were not explicitly set.
75bffa71 13014if test x"$tm_file" = x
861bb6c1
JL
13015then tm_file=$cpu_type/$cpu_type.h; fi
13016
6b2adea9 13017if test x"$extra_headers" = x
861bb6c1
JL
13018then extra_headers=; fi
13019
75bffa71 13020if test x$md_file = x
e98e406f 13021then md_file=$cpu_type/$cpu_type.md; fi
861bb6c1 13022
75bffa71 13023if test x$out_file = x
861bb6c1
JL
13024then out_file=$cpu_type/$cpu_type.c; fi
13025
75bffa71 13026if test x"$tmake_file" = x
861bb6c1
JL
13027then tmake_file=$cpu_type/t-$cpu_type
13028fi
13029
90e6a802 13030if test x"$dwarf2" = xyes
756ee602 13031then tm_file="$tm_file tm-dwarf2.h"
90e6a802
RL
13032fi
13033
861bb6c1 13034# Say what files are being used for the output code and MD file.
11642c3a 13035echo "Using \`$srcdir/config/$out_file' for machine-specific logic."
861bb6c1
JL
13036echo "Using \`$srcdir/config/$md_file' as machine description file."
13037
11642c3a 13038# If any of the xm_file variables contain nonexistent files, warn
4dc0535b
ZW
13039# about them and drop them.
13040
11642c3a
ZW
13041bx=
13042for x in $build_xm_file; do
13043 if test -f $srcdir/config/$x
13044 then bx="$bx $x"
ba479fd2
NN
13045 else { echo "$as_me:$LINENO: WARNING: $srcdir/config/$x does not exist." >&5
13046echo "$as_me: WARNING: $srcdir/config/$x does not exist." >&2;}
11642c3a
ZW
13047 fi
13048done
13049build_xm_file="$bx"
13050
13051hx=
13052for x in $host_xm_file; do
13053 if test -f $srcdir/config/$x
13054 then hx="$hx $x"
ba479fd2
NN
13055 else { echo "$as_me:$LINENO: WARNING: $srcdir/config/$x does not exist." >&5
13056echo "$as_me: WARNING: $srcdir/config/$x does not exist." >&2;}
11642c3a
ZW
13057 fi
13058done
13059host_xm_file="$hx"
13060
13061tx=
13062for x in $xm_file; do
13063 if test -f $srcdir/config/$x
13064 then tx="$tx $x"
ba479fd2
NN
13065 else { echo "$as_me:$LINENO: WARNING: $srcdir/config/$x does not exist." >&5
13066echo "$as_me: WARNING: $srcdir/config/$x does not exist." >&2;}
11642c3a
ZW
13067 fi
13068done
13069xm_file="$tx"
13070
861bb6c1
JL
13071count=a
13072for f in $tm_file; do
13073 count=${count}x
13074done
75bffa71 13075if test $count = ax; then
861bb6c1
JL
13076 echo "Using \`$srcdir/config/$tm_file' as target machine macro file."
13077else
13078 echo "Using the following target machine macro files:"
13079 for f in $tm_file; do
13080 echo " $srcdir/config/$f"
13081 done
13082fi
13083
4977bab6 13084if test x$need_64bit_hwint = xyes; then
ba479fd2
NN
13085
13086cat >>confdefs.h <<\_ACEOF
4977bab6 13087#define NEED_64BIT_HOST_WIDE_INT 1
ba479fd2 13088_ACEOF
4977bab6
ZW
13089
13090fi
13091
99fa8911
AP
13092if test x$use_long_long_for_widest_fast_int = xyes; then
13093
13094cat >>confdefs.h <<\_ACEOF
13095#define USE_LONG_LONG_FOR_WIDEST_FAST_INT 1
13096_ACEOF
13097
13098fi
13099
861bb6c1
JL
13100count=a
13101for f in $host_xm_file; do
13102 count=${count}x
13103done
11642c3a
ZW
13104if test $count = a; then
13105 :
13106elif test $count = ax; then
861bb6c1
JL
13107 echo "Using \`$srcdir/config/$host_xm_file' as host machine macro file."
13108else
13109 echo "Using the following host machine macro files:"
13110 for f in $host_xm_file; do
13111 echo " $srcdir/config/$f"
13112 done
13113fi
476d9098 13114echo "Using ${out_host_hook_obj} for host machine hooks."
861bb6c1 13115
75bffa71 13116if test "$host_xm_file" != "$build_xm_file"; then
861bb6c1
JL
13117 count=a
13118 for f in $build_xm_file; do
13119 count=${count}x
13120 done
11642c3a
ZW
13121 if test $count = a; then
13122 :
13123 elif test $count = ax; then
861bb6c1
JL
13124 echo "Using \`$srcdir/config/$build_xm_file' as build machine macro file."
13125 else
13126 echo "Using the following build machine macro files:"
13127 for f in $build_xm_file; do
13128 echo " $srcdir/config/$f"
13129 done
13130 fi
13131fi
13132
4f6d8cc8 13133case ${host} in
b8ec3cc8 13134 powerpc*-*-darwin*)
b61ff9c8
BS
13135 echo "$as_me:$LINENO: checking whether mcontext_t fields have underscores" >&5
13136echo $ECHO_N "checking whether mcontext_t fields have underscores... $ECHO_C" >&6
4f6d8cc8
GK
13137if test "${gcc_cv_mcontext_underscores+set}" = set; then
13138 echo $ECHO_N "(cached) $ECHO_C" >&6
13139else
13140 cat >conftest.$ac_ext <<_ACEOF
13141
ba7da42a 13142#include <sys/cdefs.h>
de4fb767 13143#include <sys/signal.h>
4f6d8cc8
GK
13144#include <ucontext.h>
13145int main() { mcontext_t m; if (m->ss.srr0) return 0; return 0; }
13146
13147_ACEOF
13148rm -f conftest.$ac_objext
b61ff9c8
BS
13149if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13150 (eval $ac_compile) 2>conftest.er1
4f6d8cc8
GK
13151 ac_status=$?
13152 grep -v '^ *+' conftest.er1 >conftest.err
13153 rm -f conftest.er1
13154 cat conftest.err >&5
13155 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
13156 (exit $ac_status); } &&
13157 { ac_try='test -z "$ac_c_werror_flag"
13158 || test ! -s conftest.err'
13159 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13160 (eval $ac_try) 2>&5
13161 ac_status=$?
13162 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13163 (exit $ac_status); }; } &&
13164 { ac_try='test -s conftest.$ac_objext'
13165 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13166 (eval $ac_try) 2>&5
13167 ac_status=$?
13168 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13169 (exit $ac_status); }; }; then
4f6d8cc8
GK
13170 gcc_cv_mcontext_underscores=no
13171else
13172 echo "$as_me: failed program was:" >&5
13173sed 's/^/| /' conftest.$ac_ext >&5
13174
b61ff9c8 13175gcc_cv_mcontext_underscores=yes
4f6d8cc8 13176fi
b61ff9c8 13177rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
4f6d8cc8 13178fi
b61ff9c8
BS
13179echo "$as_me:$LINENO: result: $gcc_cv_mcontext_underscores" >&5
13180echo "${ECHO_T}$gcc_cv_mcontext_underscores" >&6
4f6d8cc8
GK
13181 if test $gcc_cv_mcontext_underscores = yes; then
13182
13183cat >>confdefs.h <<\_ACEOF
13184#define HAS_MCONTEXT_T_UNDERSCORES
13185_ACEOF
13186
13187 fi
13188 ;;
13189esac
13190
8bb915b6
NN
13191# ---------
13192# Threading
13193# ---------
13194
c2e494a8 13195# Check if a valid thread package
615be2cf 13196case ${enable_threads} in
c2e494a8
NN
13197 "" | no)
13198 # No threads
13199 target_thread_file='single'
13200 ;;
13201 yes)
13202 # default
13203 target_thread_file='single'
13204 ;;
18167442 13205 aix | dce | gnat | irix | posix | posix95 | rtems | \
d9dced13 13206 single | solaris | vxworks | win32 | mipssde)
615be2cf 13207 target_thread_file=${enable_threads}
c2e494a8
NN
13208 ;;
13209 *)
615be2cf 13210 echo "${enable_threads} is an unknown thread package" 1>&2
c2e494a8
NN
13211 exit 1
13212 ;;
13213esac
13214
13215if test x${thread_file} = x; then
13216 # No thread file set by target-specific clauses in config.gcc,
13217 # so use file chosen by default logic above
13218 thread_file=${target_thread_file}
861bb6c1
JL
13219fi
13220
8bb915b6
NN
13221# Make gthr-default.h if we have a thread file.
13222gthread_flags=
13223if test $thread_file != single; then
b15a9f63
RW
13224 echo "#include \"gthr-${thread_file}.h\"" > gthr-default.h-t
13225 if diff gthr-default.h-t gthr-default.h 2>/dev/null; then
13226 rm -f gthr-default.h-t
13227 else
13228 mv -f gthr-default.h-t gthr-default.h
13229 fi
8bb915b6
NN
13230 gthread_flags=-DHAVE_GTHR_DEFAULT
13231fi
13232
13233
13234# --------
13235# UNSORTED
13236# --------
13237
18fbf599 13238use_cxa_atexit=no
2121a768
JT
13239if test x$enable___cxa_atexit = xyes || \
13240 test x$enable___cxa_atexit = x -a x$default_use_cxa_atexit = xyes; then
18fbf599 13241 if test x$host = x$target; then
97388150
DS
13242 case $host in
13243 # mingw32 doesn't have __cxa_atexit but uses atexit registration
13244 # keyed to flag_use_cxa_atexit
13245 *-*-mingw32*)
13246 use_cxa_atexit=yes
13247 ;;
13248 *)
b61ff9c8
BS
13249 echo "$as_me:$LINENO: checking for __cxa_atexit" >&5
13250echo $ECHO_N "checking for __cxa_atexit... $ECHO_C" >&6
354b7da5
DH
13251if test "${ac_cv_func___cxa_atexit+set}" = set; then
13252 echo $ECHO_N "(cached) $ECHO_C" >&6
13253else
13254 cat >conftest.$ac_ext <<_ACEOF
354b7da5
DH
13255/* confdefs.h. */
13256_ACEOF
13257cat confdefs.h >>conftest.$ac_ext
13258cat >>conftest.$ac_ext <<_ACEOF
13259/* end confdefs.h. */
86da66b5
HPN
13260/* Define __cxa_atexit to an innocuous variant, in case <limits.h> declares __cxa_atexit.
13261 For example, HP-UX 11i <limits.h> declares gettimeofday. */
13262#define __cxa_atexit innocuous___cxa_atexit
13263
354b7da5
DH
13264/* System header to define __stub macros and hopefully few prototypes,
13265 which can conflict with char __cxa_atexit (); below.
13266 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13267 <limits.h> exists even on freestanding compilers. */
86da66b5 13268
354b7da5
DH
13269#ifdef __STDC__
13270# include <limits.h>
13271#else
13272# include <assert.h>
13273#endif
86da66b5
HPN
13274
13275#undef __cxa_atexit
13276
b61ff9c8 13277/* Override any gcc2 internal prototype to avoid an error. */
354b7da5
DH
13278#ifdef __cplusplus
13279extern "C"
b61ff9c8 13280{
354b7da5 13281#endif
b61ff9c8
BS
13282/* We use char because int might match the return type of a gcc2
13283 builtin and then its argument prototype would still apply. */
354b7da5
DH
13284char __cxa_atexit ();
13285/* The GNU C library defines this for functions which it implements
13286 to always fail with ENOSYS. Some functions are actually named
13287 something starting with __ and the normal name is an alias. */
b61ff9c8 13288#if defined (__stub___cxa_atexit) || defined (__stub_____cxa_atexit)
354b7da5 13289choke me
b61ff9c8
BS
13290#else
13291char (*f) () = __cxa_atexit;
13292#endif
13293#ifdef __cplusplus
13294}
354b7da5
DH
13295#endif
13296
13297int
13298main ()
13299{
b61ff9c8 13300return f != __cxa_atexit;
354b7da5
DH
13301 ;
13302 return 0;
13303}
13304_ACEOF
13305rm -f conftest.$ac_objext conftest$ac_exeext
b61ff9c8
BS
13306if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13307 (eval $ac_link) 2>conftest.er1
354b7da5 13308 ac_status=$?
86da66b5
HPN
13309 grep -v '^ *+' conftest.er1 >conftest.err
13310 rm -f conftest.er1
13311 cat conftest.err >&5
354b7da5 13312 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
13313 (exit $ac_status); } &&
13314 { ac_try='test -z "$ac_c_werror_flag"
13315 || test ! -s conftest.err'
13316 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13317 (eval $ac_try) 2>&5
13318 ac_status=$?
13319 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13320 (exit $ac_status); }; } &&
13321 { ac_try='test -s conftest$ac_exeext'
13322 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13323 (eval $ac_try) 2>&5
13324 ac_status=$?
13325 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13326 (exit $ac_status); }; }; then
354b7da5
DH
13327 ac_cv_func___cxa_atexit=yes
13328else
13329 echo "$as_me: failed program was:" >&5
13330sed 's/^/| /' conftest.$ac_ext >&5
13331
b61ff9c8 13332ac_cv_func___cxa_atexit=no
354b7da5 13333fi
b61ff9c8 13334rm -f conftest.err conftest.$ac_objext \
86da66b5 13335 conftest$ac_exeext conftest.$ac_ext
354b7da5 13336fi
b61ff9c8
BS
13337echo "$as_me:$LINENO: result: $ac_cv_func___cxa_atexit" >&5
13338echo "${ECHO_T}$ac_cv_func___cxa_atexit" >&6
354b7da5 13339if test $ac_cv_func___cxa_atexit = yes; then
18fbf599
PB
13340 use_cxa_atexit=yes
13341else
13342 echo "__cxa_atexit can't be enabled on this target"
13343fi
13344
5f60e48f 13345 ;;
97388150 13346 esac
18fbf599
PB
13347 else
13348 # We can't check for __cxa_atexit when building a cross, so assume
13349 # it is available
13350 use_cxa_atexit=yes
13351 fi
13352 if test x$use_cxa_atexit = xyes; then
ba479fd2
NN
13353
13354cat >>confdefs.h <<\_ACEOF
c7b5e395 13355#define DEFAULT_USE_CXA_ATEXIT 2
ba479fd2 13356_ACEOF
2121a768 13357
18fbf599 13358 fi
2121a768
JT
13359fi
13360
a5381466 13361# Look for a file containing extra machine modes.
1c0ca89d
ZW
13362if test -n "$extra_modes" && test -f $srcdir/config/$extra_modes; then
13363 extra_modes_file='$(srcdir)'/config/${extra_modes}
ba479fd2
NN
13364
13365
13366cat >>confdefs.h <<_ACEOF
e22340b0 13367#define EXTRA_MODES_FILE "config/$extra_modes"
ba479fd2 13368_ACEOF
a5381466
ZW
13369
13370fi
13371
75685792
RS
13372# Convert extra_options into a form suitable for Makefile use.
13373extra_opt_files=
13374for f in $extra_options; do
13375 extra_opt_files="$extra_opt_files \$(srcdir)/config/$f"
13376done
13377
13378
b7cb92ad 13379# auto-host.h is the file containing items generated by autoconf and is
e9a25f70 13380# the first file included by config.h.
4977bab6 13381# If host=build, it is correct to have bconfig include auto-host.h
ba479fd2 13382# as well. If host!=build, we are in error and need to do more
db81d74a 13383# work to find out the build config parameters.
75bffa71 13384if test x$host = x$build
db81d74a 13385then
eaf4e618 13386 build_auto=auto-host.h
b7cb92ad
JL
13387else
13388 # We create a subdir, then run autoconf in the subdir.
13389 # To prevent recursion we set host and build for the new
13390 # invocation of configure to the build for this invocation
ba479fd2 13391 # of configure.
b7cb92ad
JL
13392 tempdir=build.$$
13393 rm -rf $tempdir
13394 mkdir $tempdir
13395 cd $tempdir
13396 case ${srcdir} in
255b8a49 13397 /* | A-Za-z:\\/* ) realsrcdir=${srcdir};;
b7cb92ad
JL
13398 *) realsrcdir=../${srcdir};;
13399 esac
d920e825
L
13400 saved_CFLAGS="${CFLAGS}"
13401 CC="${CC_FOR_BUILD}" CFLAGS="${CFLAGS_FOR_BUILD}" \
f8c33439 13402 LDFLAGS="${LDFLAGS_FOR_BUILD}" \
d920e825 13403 ${realsrcdir}/configure \
33e70558 13404 --enable-languages=${enable_languages-all} \
534d0cc0 13405 --target=$target_alias --host=$build_alias --build=$build_alias
d920e825 13406 CFLAGS="${saved_CFLAGS}"
b7cb92ad
JL
13407
13408 # We just finished tests for the build machine, so rename
13409 # the file auto-build.h in the gcc directory.
13410 mv auto-host.h ../auto-build.h
13411 cd ..
13412 rm -rf $tempdir
eaf4e618 13413 build_auto=auto-build.h
db81d74a
RH
13414fi
13415
06f0b04c 13416
eaf4e618 13417tm_file="${tm_file} defaults.h"
4977bab6
ZW
13418tm_p_file="${tm_p_file} tm-preds.h"
13419host_xm_file="auto-host.h ansidecl.h ${host_xm_file}"
13420build_xm_file="${build_auto} ansidecl.h ${build_xm_file}"
49691411 13421# We don't want ansidecl.h in target files, write code there in ISO/GNU C.
b4862477 13422# put this back in temporarily.
232b67d9 13423xm_file="auto-host.h ansidecl.h ${xm_file}"
0056a9b5 13424
34a86c2b
NN
13425# --------
13426# UNSORTED
13427# --------
13428
cc1e60ea 13429# Compile in configure arguments.
8105825d 13430if test -f configargs.h ; then
cc1e60ea 13431 # Being re-configured.
022dae81 13432 gcc_config_arguments=`grep configuration_arguments configargs.h | sed -e 's/.*"\([^"]*\)".*/\1/'`
cc1e60ea
JM
13433 gcc_config_arguments="$gcc_config_arguments : (reconfigured) $TOPLEVEL_CONFIGURE_ARGUMENTS"
13434else
13435 gcc_config_arguments="$TOPLEVEL_CONFIGURE_ARGUMENTS"
13436fi
eeae7b41
DJ
13437
13438# Double all backslashes and backslash all quotes to turn
13439# gcc_config_arguments into a C string.
13440sed -e 's/\\/\\\\/g; s/"/\\"/g' <<EOF >conftest.out
13441$gcc_config_arguments
13442EOF
13443gcc_config_arguments_str=`cat conftest.out`
13444rm -f conftest.out
13445
cc1e60ea
JM
13446cat > configargs.h <<EOF
13447/* Generated automatically. */
eeae7b41 13448static const char configuration_arguments[] = "$gcc_config_arguments_str";
a6687d2b 13449static const char thread_model[] = "$thread_file";
7816bea0
DJ
13450
13451static const struct {
13452 const char *name, *value;
13453} configure_default_options[] = $configure_default_options;
cc1e60ea
JM
13454EOF
13455
40540e68
RAE
13456gcc_BASEVER=`cat $srcdir/BASE-VER`
13457gcc_DEVPHASE=`cat $srcdir/DEV-PHASE`
13458gcc_DATESTAMP=`cat $srcdir/DATESTAMP`
0c463e16 13459if test -f $srcdir/REVISION ; then
40540e68 13460 gcc_REVISION=`cat $srcdir/REVISION`
0c463e16
RAE
13461else
13462 gcc_REVISION=""
13463fi
13464cat > plugin-version.h <<EOF
13465#include "configargs.h"
13466
13467static char basever[] = "$gcc_BASEVER";
13468static char datestamp[] = "$gcc_DATESTAMP";
13469static char devphase[] = "$gcc_DEVPHASE";
13470static char revision[] = "$gcc_REVISION";
13471
13472/* FIXME plugins: We should make the version information more precise.
13473 One way to do is to add a checksum. */
13474
13475static struct plugin_gcc_version gcc_version = {basever, datestamp,
13476 devphase, revision,
13477 configuration_arguments};
13478EOF
13479
ab87f8c8 13480# Internationalization
18fc9bd4
RG
13481# If we haven't got the data from the intl directory,
13482# assume NLS is disabled.
13483USE_NLS=no
13484LIBINTL=
13485LIBINTL_DEP=
13486INCINTL=
13487XGETTEXT=
13488GMSGFMT=
13489POSUB=
13490
13491if test -f ../intl/config.intl; then
13492 . ../intl/config.intl
13493fi
b61ff9c8
BS
13494echo "$as_me:$LINENO: checking whether NLS is requested" >&5
13495echo $ECHO_N "checking whether NLS is requested... $ECHO_C" >&6
18fc9bd4 13496if test x"$USE_NLS" != xyes; then
b61ff9c8
BS
13497 echo "$as_me:$LINENO: result: no" >&5
13498echo "${ECHO_T}no" >&6
18fc9bd4 13499else
b61ff9c8
BS
13500 echo "$as_me:$LINENO: result: yes" >&5
13501echo "${ECHO_T}yes" >&6
18fc9bd4
RG
13502
13503cat >>confdefs.h <<\_ACEOF
13504#define ENABLE_NLS 1
13505_ACEOF
13506
13507
b61ff9c8
BS
13508 echo "$as_me:$LINENO: checking for catalogs to be installed" >&5
13509echo $ECHO_N "checking for catalogs to be installed... $ECHO_C" >&6
18fc9bd4
RG
13510 # Look for .po and .gmo files in the source directory.
13511 CATALOGS=
13512 XLINGUAS=
13513 for cat in $srcdir/po/*.gmo $srcdir/po/*.po; do
13514 # If there aren't any .gmo files the shell will give us the
13515 # literal string "../path/to/srcdir/po/*.gmo" which has to be
13516 # weeded out.
13517 case "$cat" in *\**)
13518 continue;;
13519 esac
13520 # The quadruple backslash is collapsed to a double backslash
13521 # by the backticks, then collapsed again by the double quotes,
13522 # leaving us with one backslash in the sed expression (right
13523 # before the dot that mustn't act as a wildcard).
13524 cat=`echo $cat | sed -e "s!$srcdir/po/!!" -e "s!\\\\.po!.gmo!"`
13525 lang=`echo $cat | sed -e "s!\\\\.gmo!!"`
13526 # The user is allowed to set LINGUAS to a list of languages to
13527 # install catalogs for. If it's empty that means "all of them."
13528 if test "x$LINGUAS" = x; then
13529 CATALOGS="$CATALOGS $cat"
13530 XLINGUAS="$XLINGUAS $lang"
13531 else
13532 case "$LINGUAS" in *$lang*)
13533 CATALOGS="$CATALOGS $cat"
13534 XLINGUAS="$XLINGUAS $lang"
13535 ;;
13536 esac
13537 fi
13538 done
13539 LINGUAS="$XLINGUAS"
b61ff9c8
BS
13540 echo "$as_me:$LINENO: result: $LINGUAS" >&5
13541echo "${ECHO_T}$LINGUAS" >&6
18fc9bd4
RG
13542
13543
13544 DATADIRNAME=share
13545
13546 INSTOBJEXT=.mo
13547
13548 GENCAT=gencat
13549
13550 CATOBJEXT=.gmo
13551
13552fi
861bb6c1 13553
56694dd9
ZW
13554# If LIBINTL contains LIBICONV, then clear LIBICONV so we don't get
13555# -liconv on the link line twice.
13556case "$LIBINTL" in *$LIBICONV*)
13557 LIBICONV= ;;
13558esac
dc6746e7 13559
b61ff9c8 13560# Check whether --enable-secureplt or --disable-secureplt was given.
7f970b70 13561if test "${enable_secureplt+set}" = set; then
b61ff9c8 13562 enableval="$enable_secureplt"
7f970b70 13563
b61ff9c8 13564fi;
7f970b70 13565
922e3e33
UB
13566# Check whether --enable-cld or --disable-cld was given.
13567if test "${enable_cld+set}" = set; then
13568 enableval="$enable_cld"
13569
13570else
13571 enable_cld=no
13572fi;
13573
56694dd9 13574# Windows32 Registry support for specifying GCC installation paths.
b61ff9c8 13575# Check whether --enable-win32-registry or --disable-win32-registry was given.
56694dd9 13576if test "${enable_win32_registry+set}" = set; then
b61ff9c8 13577 enableval="$enable_win32_registry"
dc6746e7 13578
b61ff9c8 13579fi;
ba479fd2 13580
a1286ef5
ZW
13581case $host_os in
13582 win32 | pe | cygwin* | mingw32* | uwin*)
13583 if test "x$enable_win32_registry" != xno; then
b61ff9c8
BS
13584 echo "$as_me:$LINENO: checking for library containing RegOpenKeyExA" >&5
13585echo $ECHO_N "checking for library containing RegOpenKeyExA... $ECHO_C" >&6
ba479fd2
NN
13586if test "${ac_cv_search_RegOpenKeyExA+set}" = set; then
13587 echo $ECHO_N "(cached) $ECHO_C" >&6
13588else
13589 ac_func_search_save_LIBS=$LIBS
b61ff9c8 13590ac_cv_search_RegOpenKeyExA=no
ba479fd2 13591cat >conftest.$ac_ext <<_ACEOF
ba479fd2
NN
13592/* confdefs.h. */
13593_ACEOF
13594cat confdefs.h >>conftest.$ac_ext
13595cat >>conftest.$ac_ext <<_ACEOF
13596/* end confdefs.h. */
861bb6c1 13597
b61ff9c8 13598/* Override any gcc2 internal prototype to avoid an error. */
ba479fd2
NN
13599#ifdef __cplusplus
13600extern "C"
13601#endif
b61ff9c8
BS
13602/* We use char because int might match the return type of a gcc2
13603 builtin and then its argument prototype would still apply. */
ba479fd2
NN
13604char RegOpenKeyExA ();
13605int
13606main ()
13607{
b61ff9c8 13608RegOpenKeyExA ();
ba479fd2
NN
13609 ;
13610 return 0;
13611}
13612_ACEOF
b61ff9c8
BS
13613rm -f conftest.$ac_objext conftest$ac_exeext
13614if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13615 (eval $ac_link) 2>conftest.er1
ba479fd2 13616 ac_status=$?
86da66b5
HPN
13617 grep -v '^ *+' conftest.er1 >conftest.err
13618 rm -f conftest.er1
13619 cat conftest.err >&5
ba479fd2 13620 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
13621 (exit $ac_status); } &&
13622 { ac_try='test -z "$ac_c_werror_flag"
13623 || test ! -s conftest.err'
13624 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13625 (eval $ac_try) 2>&5
13626 ac_status=$?
13627 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13628 (exit $ac_status); }; } &&
13629 { ac_try='test -s conftest$ac_exeext'
13630 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13631 (eval $ac_try) 2>&5
13632 ac_status=$?
13633 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13634 (exit $ac_status); }; }; then
13635 ac_cv_search_RegOpenKeyExA="none required"
ab87f8c8 13636else
ba479fd2
NN
13637 echo "$as_me: failed program was:" >&5
13638sed 's/^/| /' conftest.$ac_ext >&5
13639
1a4b763e 13640fi
b61ff9c8
BS
13641rm -f conftest.err conftest.$ac_objext \
13642 conftest$ac_exeext conftest.$ac_ext
13643if test "$ac_cv_search_RegOpenKeyExA" = no; then
13644 for ac_lib in advapi32; do
13645 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
13646 cat >conftest.$ac_ext <<_ACEOF
13647/* confdefs.h. */
13648_ACEOF
13649cat confdefs.h >>conftest.$ac_ext
13650cat >>conftest.$ac_ext <<_ACEOF
13651/* end confdefs.h. */
2f41c1d6 13652
b61ff9c8
BS
13653/* Override any gcc2 internal prototype to avoid an error. */
13654#ifdef __cplusplus
13655extern "C"
13656#endif
13657/* We use char because int might match the return type of a gcc2
13658 builtin and then its argument prototype would still apply. */
13659char RegOpenKeyExA ();
13660int
13661main ()
13662{
13663RegOpenKeyExA ();
13664 ;
13665 return 0;
13666}
13667_ACEOF
13668rm -f conftest.$ac_objext conftest$ac_exeext
13669if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13670 (eval $ac_link) 2>conftest.er1
13671 ac_status=$?
13672 grep -v '^ *+' conftest.er1 >conftest.err
13673 rm -f conftest.er1
13674 cat conftest.err >&5
13675 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13676 (exit $ac_status); } &&
13677 { ac_try='test -z "$ac_c_werror_flag"
13678 || test ! -s conftest.err'
13679 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13680 (eval $ac_try) 2>&5
13681 ac_status=$?
13682 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13683 (exit $ac_status); }; } &&
13684 { ac_try='test -s conftest$ac_exeext'
13685 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13686 (eval $ac_try) 2>&5
13687 ac_status=$?
13688 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13689 (exit $ac_status); }; }; then
13690 ac_cv_search_RegOpenKeyExA="-l$ac_lib"
13691break
1a4b763e 13692else
b61ff9c8
BS
13693 echo "$as_me: failed program was:" >&5
13694sed 's/^/| /' conftest.$ac_ext >&5
13695
13696fi
13697rm -f conftest.err conftest.$ac_objext \
13698 conftest$ac_exeext conftest.$ac_ext
13699 done
dd7f7a6e
EC
13700fi
13701LIBS=$ac_func_search_save_LIBS
13702fi
b61ff9c8
BS
13703echo "$as_me:$LINENO: result: $ac_cv_search_RegOpenKeyExA" >&5
13704echo "${ECHO_T}$ac_cv_search_RegOpenKeyExA" >&6
13705if test "$ac_cv_search_RegOpenKeyExA" != no; then
13706 test "$ac_cv_search_RegOpenKeyExA" = "none required" || LIBS="$ac_cv_search_RegOpenKeyExA $LIBS"
dd7f7a6e
EC
13707
13708else
13709 enable_win32_registry=no
13710fi
13711
13712 fi
13713
13714 if test "x$enable_win32_registry" != xno; then
13715
13716cat >>confdefs.h <<\_ACEOF
13717#define ENABLE_WIN32_REGISTRY 1
13718_ACEOF
13719
13720
13721 if test "x$enable_win32_registry" != xyes \
13722 && test "x$enable_win32_registry" != x; then
13723
13724cat >>confdefs.h <<_ACEOF
13725#define WIN32_REGISTRY_KEY "$enable_win32_registry"
13726_ACEOF
13727
13728 fi
13729 fi
13730 ;;
13731esac
ab87f8c8 13732
56694dd9
ZW
13733# Get an absolute path to the GCC top-level source directory
13734holddir=`${PWDCMD-pwd}`
13735cd $srcdir
13736topdir=`${PWDCMD-pwd}`
13737cd $holddir
ab87f8c8 13738
56694dd9 13739# Conditionalize the makefile for this host machine.
2ed26f6b 13740xmake_file=
c406e779 13741for f in ${host_xmake_file}
56694dd9
ZW
13742do
13743 if test -f ${srcdir}/config/$f
13744 then
2ed26f6b 13745 xmake_file="${xmake_file} \$(srcdir)/config/$f"
56694dd9
ZW
13746 fi
13747done
093e61a6 13748
56694dd9 13749# Conditionalize the makefile for this target machine.
2ed26f6b 13750tmake_file_=
c406e779 13751for f in ${tmake_file}
56694dd9
ZW
13752do
13753 if test -f ${srcdir}/config/$f
13754 then
2ed26f6b 13755 tmake_file_="${tmake_file_} \$(srcdir)/config/$f"
56694dd9
ZW
13756 fi
13757done
2ed26f6b 13758tmake_file="${tmake_file_}"
71a94577 13759
ab87f8c8
JL
13760out_object_file=`basename $out_file .c`.o
13761
75685792
RS
13762tm_file_list="options.h"
13763tm_include_list="options.h"
ab87f8c8 13764for f in $tm_file; do
64ccbc99 13765 case $f in
3ca43df7
RS
13766 ./* )
13767 f=`echo $f | sed 's/^..//'`
13768 tm_file_list="${tm_file_list} $f"
13769 tm_include_list="${tm_include_list} $f"
13770 ;;
d02af173 13771 defaults.h )
e22340b0
ZW
13772 tm_file_list="${tm_file_list} \$(srcdir)/$f"
13773 tm_include_list="${tm_include_list} $f"
13774 ;;
13775 * )
13776 tm_file_list="${tm_file_list} \$(srcdir)/config/$f"
13777 tm_include_list="${tm_include_list} config/$f"
13778 ;;
64ccbc99 13779 esac
ab87f8c8
JL
13780done
13781
11642c3a 13782tm_p_file_list=
e22340b0 13783tm_p_include_list=
11642c3a 13784for f in $tm_p_file; do
4977bab6
ZW
13785 case $f in
13786 tm-preds.h )
e22340b0
ZW
13787 tm_p_file_list="${tm_p_file_list} $f"
13788 tm_p_include_list="${tm_p_include_list} $f"
13789 ;;
13790 * )
13791 tm_p_file_list="${tm_p_file_list} \$(srcdir)/config/$f"
13792 tm_p_include_list="${tm_p_include_list} config/$f"
13793 esac
13794done
13795
13796xm_file_list=
13797xm_include_list=
13798for f in $xm_file; do
13799 case $f in
13800 ansidecl.h )
13801 xm_file_list="${xm_file_list} \$(srcdir)/../include/$f"
13802 xm_include_list="${xm_include_list} $f"
13803 ;;
13804 auto-host.h )
13805 xm_file_list="${xm_file_list} $f"
13806 xm_include_list="${xm_include_list} $f"
13807 ;;
13808 * )
13809 xm_file_list="${xm_file_list} \$(srcdir)/config/$f"
13810 xm_include_list="${xm_include_list} config/$f"
13811 ;;
4977bab6 13812 esac
11642c3a
ZW
13813done
13814
ab87f8c8 13815host_xm_file_list=
e22340b0 13816host_xm_include_list=
ab87f8c8 13817for f in $host_xm_file; do
64ccbc99 13818 case $f in
d02af173 13819 ansidecl.h )
e22340b0
ZW
13820 host_xm_file_list="${host_xm_file_list} \$(srcdir)/../include/$f"
13821 host_xm_include_list="${host_xm_include_list} $f"
13822 ;;
e2500fed 13823 auto-host.h )
e22340b0
ZW
13824 host_xm_file_list="${host_xm_file_list} $f"
13825 host_xm_include_list="${host_xm_include_list} $f"
13826 ;;
13827 * )
13828 host_xm_file_list="${host_xm_file_list} \$(srcdir)/config/$f"
13829 host_xm_include_list="${host_xm_include_list} config/$f"
13830 ;;
64ccbc99 13831 esac
ab87f8c8
JL
13832done
13833
13834build_xm_file_list=
13835for f in $build_xm_file; do
64ccbc99 13836 case $f in
d02af173 13837 ansidecl.h )
e22340b0
ZW
13838 build_xm_file_list="${build_xm_file_list} \$(srcdir)/../include/$f"
13839 build_xm_include_list="${build_xm_include_list} $f"
13840 ;;
e2500fed 13841 auto-build.h | auto-host.h )
e22340b0
ZW
13842 build_xm_file_list="${build_xm_file_list} $f"
13843 build_xm_include_list="${build_xm_include_list} $f"
13844 ;;
13845 * )
13846 build_xm_file_list="${build_xm_file_list} \$(srcdir)/config/$f"
13847 build_xm_include_list="${build_xm_include_list} config/$f"
13848 ;;
64ccbc99 13849 esac
ab87f8c8
JL
13850done
13851
2989d30c
GK
13852# Define macro CROSS_DIRECTORY_STRUCTURE in compilation if this is a
13853# cross-compiler which does not use the native headers and libraries.
a078a589 13854# Also use all.cross instead of all.internal and adjust SYSTEM_HEADER_DIR.
ba479fd2
NN
13855CROSS=
13856ALL=all.internal
13857SYSTEM_HEADER_DIR='$(NATIVE_SYSTEM_HEADER_DIR)'
b28250ab
MM
13858
13859if test "x$with_build_sysroot" != x; then
14da6073 13860 build_system_header_dir=$with_build_sysroot'$${sysroot_headers_suffix}$(NATIVE_SYSTEM_HEADER_DIR)'
b28250ab
MM
13861else
13862 # This value is used, even on a native system, because
13863 # CROSS_SYSTEM_HEADER_DIR is just
13864 # $(TARGET_SYSTEM_ROOT)$(NATIVE_SYSTEM_HEADER_DIR).
13865 build_system_header_dir='$(CROSS_SYSTEM_HEADER_DIR)'
13866fi
13867
ab87f8c8
JL
13868if test x$host != x$target
13869then
2989d30c 13870 CROSS="-DCROSS_DIRECTORY_STRUCTURE"
a078a589 13871 ALL=all.cross
160633c6 13872 SYSTEM_HEADER_DIR=$build_system_header_dir
343f59d9 13873 case "$host","$target" in
3a7e8b87
GK
13874 # Darwin crosses can use the host system's libraries and headers,
13875 # because of the fat library support. Of course, it must be the
13876 # same version of Darwin on both sides. Allow the user to
13877 # just say --target=foo-darwin without a version number to mean
13878 # "the version on this system".
13879 *-*-darwin*,*-*-darwin*)
13880 hostos=`echo $host | sed 's/.*-darwin/darwin/'`
13881 targetos=`echo $target | sed 's/.*-darwin/darwin/'`
13882 if test $hostos = $targetos -o $targetos = darwin ; then
13883 CROSS=
13884 SYSTEM_HEADER_DIR='$(NATIVE_SYSTEM_HEADER_DIR)'
13885 with_headers=yes
13886 fi
13887 ;;
13888
343f59d9
AM
13889 i?86-*-*,x86_64-*-* \
13890 | powerpc*-*-*,powerpc64*-*-*)
13891 CROSS="$CROSS -DNATIVE_CROSS" ;;
13892 esac
7a615b25 13893elif test "x$TARGET_SYSTEM_ROOT" != x; then
b28250ab 13894 SYSTEM_HEADER_DIR=$build_system_header_dir
ab87f8c8
JL
13895fi
13896
b39d221a
EC
13897# If this is a cross-compiler that does not
13898# have its own set of headers then define
13899# inhibit_libc
13900
dc06db20
R
13901# If this is using newlib, without having the headers available now,
13902# then define inhibit_libc in LIBGCC2_CFLAGS.
fecd6201
ZW
13903# This prevents libgcc2 from containing any code which requires libc
13904# support.
a929bc28 13905: ${inhibit_libc=false}
dc06db20
R
13906if { { test x$host != x$target && test "x$with_sysroot" = x ; } ||
13907 test x$with_newlib = xyes ; } &&
e50084fa 13908 { test "x$with_headers" = x || test "x$with_headers" = xno ; } ; then
160633c6 13909 inhibit_libc=true
b39d221a
EC
13910fi
13911
13912
a078a589
ZW
13913# When building gcc with a cross-compiler, we need to adjust things so
13914# that the generator programs are still built with the native compiler.
52c0e446 13915# Also, we cannot run fixincludes.
a078a589
ZW
13916
13917# These are the normal (build=host) settings:
ba479fd2
NN
13918CC_FOR_BUILD='$(CC)'
13919BUILD_CFLAGS='$(ALL_CFLAGS)'
f8c33439 13920BUILD_LDFLAGS='$(LDFLAGS)'
ba479fd2 13921STMP_FIXINC=stmp-fixinc
8ad9fb33 13922
83599948
NS
13923# And these apply if build != host, or we are generating coverage data
13924if test x$build != x$host || test "x$coverage_flags" != x
ab87f8c8 13925then
b11e4747 13926 BUILD_CFLAGS='$(INTERNAL_CFLAGS) $(T_CFLAGS) $(CFLAGS_FOR_BUILD)'
f8c33439 13927 BUILD_LDFLAGS='$(LDFLAGS_FOR_BUILD)'
ab87f8c8
JL
13928fi
13929
13930# Expand extra_headers to include complete path.
13931# This substitutes for lots of t-* files.
13932extra_headers_list=
b1ef58c8
NN
13933# Prepend $(srcdir)/config/${cpu_type}/ to every entry in extra_headers.
13934for file in ${extra_headers} ; do
13935 extra_headers_list="${extra_headers_list} \$(srcdir)/config/${cpu_type}/${file}"
13936done
ab87f8c8 13937
1617e5ee
GK
13938# If use_gcc_tgmath is set, append ginclude/tgmath.h.
13939if test x"$use_gcc_tgmath" = xyes
13940then extra_headers_list="${extra_headers_list} \$(srcdir)/ginclude/tgmath.h"
13941fi
13942
c38f02df
ILT
13943# Define collect2 in Makefile.
13944case $host_can_use_collect2 in
13945 no) collect2= ;;
13946 *) collect2='collect2$(exeext)' ;;
13947esac
13948
13949
ab87f8c8 13950# Add a definition of USE_COLLECT2 if system wants one.
34a86c2b
NN
13951case $use_collect2 in
13952 no) use_collect2= ;;
13953 "") ;;
ba479fd2 13954 *)
34a86c2b
NN
13955 host_xm_defines="${host_xm_defines} USE_COLLECT2"
13956 xm_defines="${xm_defines} USE_COLLECT2"
c38f02df
ILT
13957 case $host_can_use_collect2 in
13958 no)
13959 { { echo "$as_me:$LINENO: error: collect2 is required but cannot be built on this system" >&5
13960echo "$as_me: error: collect2 is required but cannot be built on this system" >&2;}
13961 { (exit 1); exit 1; }; }
13962 ;;
13963 esac
34a86c2b
NN
13964 ;;
13965esac
ab87f8c8 13966
8bb915b6
NN
13967# ---------------------------
13968# Assembler & linker features
13969# ---------------------------
13970
da0f6381
PB
13971# During stage 2, ld is actually gcc/collect-ld, which is a small script to
13972# discern between when to use prev-ld/ld-new and when to use ld/ld-new.
13973# However when ld-new is first executed from the build tree, libtool will
13974# relink it as .libs/lt-ld-new, so that it can give it an RPATH that refers
13975# to the build tree. While doing this we need to use the previous-stage
13976# linker, or we have an infinite loop. The presence of a shell script as
13977# ld/ld-new, and the fact that the script *uses ld itself*, is what confuses
13978# the gcc/collect-ld script. So we need to know how libtool works, or
13979# exec-tool will fail.
e8b05380 13980
da0f6381 13981
5d47bb02
PG
13982case `pwd` in
13983 *\ * | *\ *)
13984 { echo "$as_me:$LINENO: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5
13985echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;;
13986esac
da0f6381
PB
13987
13988
da0f6381 13989
5d47bb02
PG
13990macro_version='2.2.6'
13991macro_revision='1.3012'
da0f6381
PB
13992
13993
13994
13995
13996
13997
da0f6381
PB
13998
13999
14000
14001
14002
14003
14004
5d47bb02 14005ltmain="$ac_aux_dir/ltmain.sh"
da0f6381
PB
14006
14007echo "$as_me:$LINENO: checking for a sed that does not truncate output" >&5
14008echo $ECHO_N "checking for a sed that does not truncate output... $ECHO_C" >&6
14009if test "${lt_cv_path_SED+set}" = set; then
e8b05380
PB
14010 echo $ECHO_N "(cached) $ECHO_C" >&6
14011else
da0f6381
PB
14012 # Loop through the user's path and test for sed and gsed.
14013# Then use that list of sed's as ones to test for truncation.
14014as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
e8b05380
PB
14015for as_dir in $PATH
14016do
14017 IFS=$as_save_IFS
14018 test -z "$as_dir" && as_dir=.
da0f6381
PB
14019 for lt_ac_prog in sed gsed; do
14020 for ac_exec_ext in '' $ac_executable_extensions; do
14021 if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then
14022 lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext"
14023 fi
14024 done
14025 done
e8b05380 14026done
da0f6381
PB
14027IFS=$as_save_IFS
14028lt_ac_max=0
14029lt_ac_count=0
14030# Add /usr/xpg4/bin/sed as it is typically found on Solaris
14031# along with /bin/sed that truncates output.
14032for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do
14033 test ! -f $lt_ac_sed && continue
14034 cat /dev/null > conftest.in
14035 lt_ac_count=0
14036 echo $ECHO_N "0123456789$ECHO_C" >conftest.in
14037 # Check for GNU sed and select it if it is found.
14038 if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then
14039 lt_cv_path_SED=$lt_ac_sed
14040 break
14041 fi
14042 while true; do
14043 cat conftest.in conftest.in >conftest.tmp
14044 mv conftest.tmp conftest.in
14045 cp conftest.in conftest.nl
14046 echo >>conftest.nl
14047 $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break
14048 cmp -s conftest.out conftest.nl || break
14049 # 10000 chars as input seems more than enough
14050 test $lt_ac_count -gt 10 && break
14051 lt_ac_count=`expr $lt_ac_count + 1`
14052 if test $lt_ac_count -gt $lt_ac_max; then
14053 lt_ac_max=$lt_ac_count
14054 lt_cv_path_SED=$lt_ac_sed
14055 fi
14056 done
e8b05380
PB
14057done
14058
e8b05380 14059fi
b61ff9c8 14060
da0f6381 14061SED=$lt_cv_path_SED
e8b05380 14062
da0f6381
PB
14063echo "$as_me:$LINENO: result: $SED" >&5
14064echo "${ECHO_T}$SED" >&6
e8b05380 14065
da0f6381
PB
14066test -z "$SED" && SED=sed
14067Xsed="$SED -e 1s/^X//"
e8b05380 14068
e8b05380
PB
14069
14070
ad9c4d9f 14071
da0f6381
PB
14072
14073
14074
14075
14076
14077
14078
14079echo "$as_me:$LINENO: checking for fgrep" >&5
14080echo $ECHO_N "checking for fgrep... $ECHO_C" >&6
14081if test "${ac_cv_prog_fgrep+set}" = set; then
14082 echo $ECHO_N "(cached) $ECHO_C" >&6
e8b05380 14083else
da0f6381
PB
14084 if echo 'ab*c' | (grep -F 'ab*c') >/dev/null 2>&1
14085 then ac_cv_prog_fgrep='grep -F'
14086 else ac_cv_prog_fgrep='fgrep'
14087 fi
981d4858 14088fi
da0f6381
PB
14089echo "$as_me:$LINENO: result: $ac_cv_prog_fgrep" >&5
14090echo "${ECHO_T}$ac_cv_prog_fgrep" >&6
14091 FGREP=$ac_cv_prog_fgrep
9e423e6d 14092
9f18db39 14093
da0f6381 14094test -z "$GREP" && GREP=grep
9f18db39 14095
da0f6381
PB
14096
14097
14098
14099
14100
14101
14102
14103
14104
14105
14106
14107
14108
14109
14110
14111
14112
14113
14114# Check whether --with-gnu-ld or --without-gnu-ld was given.
14115if test "${with_gnu_ld+set}" = set; then
14116 withval="$with_gnu_ld"
14117 test "$withval" = no || with_gnu_ld=yes
14118else
14119 with_gnu_ld=no
14120fi;
14121ac_prog=ld
14122if test "$GCC" = yes; then
14123 # Check if gcc -print-prog-name=ld gives a path.
14124 echo "$as_me:$LINENO: checking for ld used by $CC" >&5
14125echo $ECHO_N "checking for ld used by $CC... $ECHO_C" >&6
14126 case $host in
14127 *-*-mingw*)
14128 # gcc leaves a trailing carriage return which upsets mingw
14129 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
14130 *)
14131 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
14132 esac
14133 case $ac_prog in
14134 # Accept absolute paths.
14135 [\\/]* | ?:[\\/]*)
14136 re_direlt='/[^/][^/]*/\.\./'
14137 # Canonicalize the pathname of ld
14138 ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
14139 while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
14140 ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
14141 done
14142 test -z "$LD" && LD="$ac_prog"
14143 ;;
14144 "")
14145 # If it fails, then pretend we aren't using GCC.
14146 ac_prog=ld
14147 ;;
14148 *)
14149 # If it is relative, then search for the first ld in PATH.
14150 with_gnu_ld=unknown
14151 ;;
14152 esac
14153elif test "$with_gnu_ld" = yes; then
14154 echo "$as_me:$LINENO: checking for GNU ld" >&5
14155echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6
14156else
14157 echo "$as_me:$LINENO: checking for non-GNU ld" >&5
14158echo $ECHO_N "checking for non-GNU ld... $ECHO_C" >&6
14159fi
14160if test "${lt_cv_path_LD+set}" = set; then
14161 echo $ECHO_N "(cached) $ECHO_C" >&6
14162else
14163 if test -z "$LD"; then
14164 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
14165 for ac_dir in $PATH; do
14166 IFS="$lt_save_ifs"
14167 test -z "$ac_dir" && ac_dir=.
14168 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
14169 lt_cv_path_LD="$ac_dir/$ac_prog"
14170 # Check to see if the program is GNU ld. I'd rather use --version,
14171 # but apparently some variants of GNU ld only accept -v.
14172 # Break only if it was the GNU/non-GNU ld that we prefer.
14173 case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
14174 *GNU* | *'with BFD'*)
14175 test "$with_gnu_ld" != no && break
14176 ;;
14177 *)
14178 test "$with_gnu_ld" != yes && break
14179 ;;
14180 esac
14181 fi
14182 done
14183 IFS="$lt_save_ifs"
14184else
14185 lt_cv_path_LD="$LD" # Let the user override the test with a path.
14186fi
14187fi
14188
14189LD="$lt_cv_path_LD"
14190if test -n "$LD"; then
14191 echo "$as_me:$LINENO: result: $LD" >&5
14192echo "${ECHO_T}$LD" >&6
14193else
14194 echo "$as_me:$LINENO: result: no" >&5
14195echo "${ECHO_T}no" >&6
14196fi
14197test -z "$LD" && { { echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5
14198echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
14199 { (exit 1); exit 1; }; }
14200echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
14201echo $ECHO_N "checking if the linker ($LD) is GNU ld... $ECHO_C" >&6
14202if test "${lt_cv_prog_gnu_ld+set}" = set; then
14203 echo $ECHO_N "(cached) $ECHO_C" >&6
14204else
14205 # I'd rather use --version here, but apparently some GNU lds only accept -v.
14206case `$LD -v 2>&1 </dev/null` in
14207*GNU* | *'with BFD'*)
14208 lt_cv_prog_gnu_ld=yes
14209 ;;
14210*)
14211 lt_cv_prog_gnu_ld=no
14212 ;;
14213esac
14214fi
14215echo "$as_me:$LINENO: result: $lt_cv_prog_gnu_ld" >&5
14216echo "${ECHO_T}$lt_cv_prog_gnu_ld" >&6
14217with_gnu_ld=$lt_cv_prog_gnu_ld
14218
14219
14220
14221
14222
14223
14224
14225
14226
da0f6381
PB
14227echo "$as_me:$LINENO: checking for BSD- or MS-compatible name lister (nm)" >&5
14228echo $ECHO_N "checking for BSD- or MS-compatible name lister (nm)... $ECHO_C" >&6
14229if test "${lt_cv_path_NM+set}" = set; then
14230 echo $ECHO_N "(cached) $ECHO_C" >&6
14231else
14232 if test -n "$NM"; then
14233 # Let the user override the test.
14234 lt_cv_path_NM="$NM"
14235else
14236 lt_nm_to_check="${ac_tool_prefix}nm"
14237 if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
14238 lt_nm_to_check="$lt_nm_to_check nm"
14239 fi
14240 for lt_tmp_nm in $lt_nm_to_check; do
14241 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
14242 for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
14243 IFS="$lt_save_ifs"
14244 test -z "$ac_dir" && ac_dir=.
14245 tmp_nm="$ac_dir/$lt_tmp_nm"
14246 if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
14247 # Check to see if the nm accepts a BSD-compat flag.
14248 # Adding the `sed 1q' prevents false positives on HP-UX, which says:
14249 # nm: unknown option "B" ignored
14250 # Tru64's nm complains that /dev/null is an invalid object file
14251 case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
14252 */dev/null* | *'Invalid file or object type'*)
14253 lt_cv_path_NM="$tmp_nm -B"
14254 break
14255 ;;
14256 *)
14257 case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
14258 */dev/null*)
14259 lt_cv_path_NM="$tmp_nm -p"
14260 break
14261 ;;
14262 *)
14263 lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
14264 continue # so that we can try to find one that supports BSD flags
14265 ;;
14266 esac
14267 ;;
14268 esac
14269 fi
14270 done
14271 IFS="$lt_save_ifs"
14272 done
14273 : ${lt_cv_path_NM=no}
14274fi
14275fi
14276echo "$as_me:$LINENO: result: $lt_cv_path_NM" >&5
14277echo "${ECHO_T}$lt_cv_path_NM" >&6
14278if test "$lt_cv_path_NM" != "no"; then
14279 NM="$lt_cv_path_NM"
14280else
14281 # Didn't find any BSD compatible name lister, look for dumpbin.
14282 if test -n "$ac_tool_prefix"; then
14283 for ac_prog in "dumpbin -symbols" "link -dump -symbols"
14284 do
14285 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
14286set dummy $ac_tool_prefix$ac_prog; ac_word=$2
14287echo "$as_me:$LINENO: checking for $ac_word" >&5
14288echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
14289if test "${ac_cv_prog_DUMPBIN+set}" = set; then
14290 echo $ECHO_N "(cached) $ECHO_C" >&6
14291else
14292 if test -n "$DUMPBIN"; then
14293 ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test.
14294else
14295as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14296for as_dir in $PATH
14297do
14298 IFS=$as_save_IFS
14299 test -z "$as_dir" && as_dir=.
14300 for ac_exec_ext in '' $ac_executable_extensions; do
14301 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
14302 ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog"
14303 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
14304 break 2
14305 fi
14306done
14307done
14308
14309fi
14310fi
14311DUMPBIN=$ac_cv_prog_DUMPBIN
14312if test -n "$DUMPBIN"; then
14313 echo "$as_me:$LINENO: result: $DUMPBIN" >&5
14314echo "${ECHO_T}$DUMPBIN" >&6
14315else
14316 echo "$as_me:$LINENO: result: no" >&5
14317echo "${ECHO_T}no" >&6
14318fi
14319
14320 test -n "$DUMPBIN" && break
14321 done
14322fi
14323if test -z "$DUMPBIN"; then
14324 ac_ct_DUMPBIN=$DUMPBIN
14325 for ac_prog in "dumpbin -symbols" "link -dump -symbols"
14326do
14327 # Extract the first word of "$ac_prog", so it can be a program name with args.
14328set dummy $ac_prog; ac_word=$2
14329echo "$as_me:$LINENO: checking for $ac_word" >&5
14330echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
14331if test "${ac_cv_prog_ac_ct_DUMPBIN+set}" = set; then
14332 echo $ECHO_N "(cached) $ECHO_C" >&6
14333else
14334 if test -n "$ac_ct_DUMPBIN"; then
14335 ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test.
14336else
14337as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14338for as_dir in $PATH
14339do
14340 IFS=$as_save_IFS
14341 test -z "$as_dir" && as_dir=.
14342 for ac_exec_ext in '' $ac_executable_extensions; do
14343 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
14344 ac_cv_prog_ac_ct_DUMPBIN="$ac_prog"
14345 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
14346 break 2
14347 fi
14348done
14349done
14350
14351fi
14352fi
14353ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN
14354if test -n "$ac_ct_DUMPBIN"; then
14355 echo "$as_me:$LINENO: result: $ac_ct_DUMPBIN" >&5
14356echo "${ECHO_T}$ac_ct_DUMPBIN" >&6
14357else
14358 echo "$as_me:$LINENO: result: no" >&5
14359echo "${ECHO_T}no" >&6
14360fi
14361
14362 test -n "$ac_ct_DUMPBIN" && break
14363done
14364test -n "$ac_ct_DUMPBIN" || ac_ct_DUMPBIN=":"
14365
14366 DUMPBIN=$ac_ct_DUMPBIN
14367fi
14368
14369
14370 if test "$DUMPBIN" != ":"; then
14371 NM="$DUMPBIN"
14372 fi
14373fi
14374test -z "$NM" && NM=nm
14375
14376
14377
14378
14379
14380
14381echo "$as_me:$LINENO: checking the name lister ($NM) interface" >&5
14382echo $ECHO_N "checking the name lister ($NM) interface... $ECHO_C" >&6
14383if test "${lt_cv_nm_interface+set}" = set; then
14384 echo $ECHO_N "(cached) $ECHO_C" >&6
14385else
14386 lt_cv_nm_interface="BSD nm"
14387 echo "int some_variable = 0;" > conftest.$ac_ext
cd533689 14388 (eval echo "\"\$as_me:14388: $ac_compile\"" >&5)
da0f6381
PB
14389 (eval "$ac_compile" 2>conftest.err)
14390 cat conftest.err >&5
cd533689 14391 (eval echo "\"\$as_me:14391: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
da0f6381
PB
14392 (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
14393 cat conftest.err >&5
cd533689 14394 (eval echo "\"\$as_me:14394: output\"" >&5)
da0f6381
PB
14395 cat conftest.out >&5
14396 if $GREP 'External.*some_variable' conftest.out > /dev/null; then
14397 lt_cv_nm_interface="MS dumpbin"
14398 fi
14399 rm -f conftest*
14400fi
14401echo "$as_me:$LINENO: result: $lt_cv_nm_interface" >&5
14402echo "${ECHO_T}$lt_cv_nm_interface" >&6
14403
14404echo "$as_me:$LINENO: checking whether ln -s works" >&5
14405echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
14406LN_S=$as_ln_s
14407if test "$LN_S" = "ln -s"; then
14408 echo "$as_me:$LINENO: result: yes" >&5
14409echo "${ECHO_T}yes" >&6
14410else
14411 echo "$as_me:$LINENO: result: no, using $LN_S" >&5
14412echo "${ECHO_T}no, using $LN_S" >&6
14413fi
14414
14415# find the maximum length of command line arguments
14416echo "$as_me:$LINENO: checking the maximum length of command line arguments" >&5
14417echo $ECHO_N "checking the maximum length of command line arguments... $ECHO_C" >&6
14418if test "${lt_cv_sys_max_cmd_len+set}" = set; then
14419 echo $ECHO_N "(cached) $ECHO_C" >&6
14420else
14421 i=0
14422 teststring="ABCD"
14423
14424 case $build_os in
14425 msdosdjgpp*)
14426 # On DJGPP, this test can blow up pretty badly due to problems in libc
14427 # (any single argument exceeding 2000 bytes causes a buffer overrun
14428 # during glob expansion). Even if it were fixed, the result of this
14429 # check would be larger than it should be.
14430 lt_cv_sys_max_cmd_len=12288; # 12K is about right
14431 ;;
14432
14433 gnu*)
14434 # Under GNU Hurd, this test is not required because there is
14435 # no limit to the length of command line arguments.
14436 # Libtool will interpret -1 as no limit whatsoever
14437 lt_cv_sys_max_cmd_len=-1;
14438 ;;
14439
5d47bb02 14440 cygwin* | mingw* | cegcc*)
da0f6381
PB
14441 # On Win9x/ME, this test blows up -- it succeeds, but takes
14442 # about 5 minutes as the teststring grows exponentially.
14443 # Worse, since 9x/ME are not pre-emptively multitasking,
14444 # you end up with a "frozen" computer, even though with patience
14445 # the test eventually succeeds (with a max line length of 256k).
14446 # Instead, let's just punt: use the minimum linelength reported by
14447 # all of the supported platforms: 8192 (on NT/2K/XP).
14448 lt_cv_sys_max_cmd_len=8192;
14449 ;;
14450
14451 amigaos*)
14452 # On AmigaOS with pdksh, this test takes hours, literally.
14453 # So we just punt and use a minimum line length of 8192.
14454 lt_cv_sys_max_cmd_len=8192;
14455 ;;
14456
14457 netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
14458 # This has been around since 386BSD, at least. Likely further.
14459 if test -x /sbin/sysctl; then
14460 lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
14461 elif test -x /usr/sbin/sysctl; then
14462 lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
14463 else
14464 lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
14465 fi
14466 # And add a safety zone
14467 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
14468 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
14469 ;;
14470
14471 interix*)
14472 # We know the value 262144 and hardcode it with a safety zone (like BSD)
14473 lt_cv_sys_max_cmd_len=196608
14474 ;;
14475
14476 osf*)
14477 # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
14478 # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
14479 # nice to cause kernel panics so lets avoid the loop below.
14480 # First set a reasonable default.
14481 lt_cv_sys_max_cmd_len=16384
14482 #
14483 if test -x /sbin/sysconfig; then
14484 case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
14485 *1*) lt_cv_sys_max_cmd_len=-1 ;;
14486 esac
14487 fi
14488 ;;
14489 sco3.2v5*)
14490 lt_cv_sys_max_cmd_len=102400
14491 ;;
14492 sysv5* | sco5v6* | sysv4.2uw2*)
14493 kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
14494 if test -n "$kargmax"; then
14495 lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ ]//'`
14496 else
14497 lt_cv_sys_max_cmd_len=32768
14498 fi
14499 ;;
14500 *)
5d47bb02
PG
14501 lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
14502 if test -n "$lt_cv_sys_max_cmd_len"; then
da0f6381
PB
14503 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
14504 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
14505 else
14506 # Make teststring a little bigger before we do anything with it.
14507 # a 1K string should be a reasonable start.
14508 for i in 1 2 3 4 5 6 7 8 ; do
14509 teststring=$teststring$teststring
14510 done
14511 SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
14512 # If test is not a shell built-in, we'll probably end up computing a
14513 # maximum length that is only half of the actual maximum length, but
14514 # we can't tell.
14515 while { test "X"`$SHELL $0 --fallback-echo "X$teststring$teststring" 2>/dev/null` \
14516 = "XX$teststring$teststring"; } >/dev/null 2>&1 &&
14517 test $i != 17 # 1/2 MB should be enough
14518 do
14519 i=`expr $i + 1`
14520 teststring=$teststring$teststring
14521 done
14522 # Only check the string length outside the loop.
14523 lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
14524 teststring=
14525 # Add a significant safety factor because C++ compilers can tack on
14526 # massive amounts of additional arguments before passing them to the
14527 # linker. It appears as though 1/2 is a usable value.
14528 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
14529 fi
14530 ;;
14531 esac
14532
14533fi
14534
14535if test -n $lt_cv_sys_max_cmd_len ; then
14536 echo "$as_me:$LINENO: result: $lt_cv_sys_max_cmd_len" >&5
14537echo "${ECHO_T}$lt_cv_sys_max_cmd_len" >&6
14538else
14539 echo "$as_me:$LINENO: result: none" >&5
14540echo "${ECHO_T}none" >&6
14541fi
14542max_cmd_len=$lt_cv_sys_max_cmd_len
14543
14544
14545
14546
14547
14548
da0f6381
PB
14549: ${CP="cp -f"}
14550: ${MV="mv -f"}
14551: ${RM="rm -f"}
14552
14553echo "$as_me:$LINENO: checking whether the shell understands some XSI constructs" >&5
14554echo $ECHO_N "checking whether the shell understands some XSI constructs... $ECHO_C" >&6
14555# Try some XSI features
14556xsi_shell=no
14557( _lt_dummy="a/b/c"
14558 test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \
5d47bb02
PG
14559 = c,a/b,, \
14560 && eval 'test $(( 1 + 1 )) -eq 2 \
14561 && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
da0f6381
PB
14562 && xsi_shell=yes
14563echo "$as_me:$LINENO: result: $xsi_shell" >&5
14564echo "${ECHO_T}$xsi_shell" >&6
14565
14566
14567echo "$as_me:$LINENO: checking whether the shell understands \"+=\"" >&5
14568echo $ECHO_N "checking whether the shell understands \"+=\"... $ECHO_C" >&6
14569lt_shell_append=no
14570( foo=bar; set foo baz; eval "$1+=\$2" && test "$foo" = barbaz ) \
14571 >/dev/null 2>&1 \
14572 && lt_shell_append=yes
14573echo "$as_me:$LINENO: result: $lt_shell_append" >&5
14574echo "${ECHO_T}$lt_shell_append" >&6
14575
14576
14577if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
14578 lt_unset=unset
14579else
14580 lt_unset=false
14581fi
14582
14583
14584
14585
14586
14587# test EBCDIC or ASCII
14588case `echo X|tr X '\101'` in
14589 A) # ASCII based system
14590 # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
14591 lt_SP2NL='tr \040 \012'
14592 lt_NL2SP='tr \015\012 \040\040'
14593 ;;
14594 *) # EBCDIC based system
14595 lt_SP2NL='tr \100 \n'
14596 lt_NL2SP='tr \r\n \100\100'
14597 ;;
14598esac
14599
14600
14601
14602
14603
14604
14605
14606
14607
14608echo "$as_me:$LINENO: checking for $LD option to reload object files" >&5
14609echo $ECHO_N "checking for $LD option to reload object files... $ECHO_C" >&6
14610if test "${lt_cv_ld_reload_flag+set}" = set; then
14611 echo $ECHO_N "(cached) $ECHO_C" >&6
14612else
14613 lt_cv_ld_reload_flag='-r'
14614fi
14615echo "$as_me:$LINENO: result: $lt_cv_ld_reload_flag" >&5
14616echo "${ECHO_T}$lt_cv_ld_reload_flag" >&6
14617reload_flag=$lt_cv_ld_reload_flag
14618case $reload_flag in
14619"" | " "*) ;;
14620*) reload_flag=" $reload_flag" ;;
14621esac
14622reload_cmds='$LD$reload_flag -o $output$reload_objs'
14623case $host_os in
14624 darwin*)
14625 if test "$GCC" = yes; then
14626 reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
14627 else
14628 reload_cmds='$LD$reload_flag -o $output$reload_objs'
14629 fi
14630 ;;
14631esac
14632
14633
14634
14635
14636
14637
14638
14639
14640
5d47bb02
PG
14641if test -n "$ac_tool_prefix"; then
14642 # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
14643set dummy ${ac_tool_prefix}objdump; ac_word=$2
14644echo "$as_me:$LINENO: checking for $ac_word" >&5
14645echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
14646if test "${ac_cv_prog_OBJDUMP+set}" = set; then
14647 echo $ECHO_N "(cached) $ECHO_C" >&6
14648else
14649 if test -n "$OBJDUMP"; then
14650 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
14651else
14652as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14653for as_dir in $PATH
14654do
14655 IFS=$as_save_IFS
14656 test -z "$as_dir" && as_dir=.
14657 for ac_exec_ext in '' $ac_executable_extensions; do
14658 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
14659 ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
14660 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
14661 break 2
14662 fi
14663done
14664done
14665
14666fi
14667fi
14668OBJDUMP=$ac_cv_prog_OBJDUMP
14669if test -n "$OBJDUMP"; then
14670 echo "$as_me:$LINENO: result: $OBJDUMP" >&5
14671echo "${ECHO_T}$OBJDUMP" >&6
14672else
14673 echo "$as_me:$LINENO: result: no" >&5
14674echo "${ECHO_T}no" >&6
14675fi
14676
14677fi
14678if test -z "$ac_cv_prog_OBJDUMP"; then
14679 ac_ct_OBJDUMP=$OBJDUMP
14680 # Extract the first word of "objdump", so it can be a program name with args.
14681set dummy objdump; ac_word=$2
14682echo "$as_me:$LINENO: checking for $ac_word" >&5
14683echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
14684if test "${ac_cv_prog_ac_ct_OBJDUMP+set}" = set; then
14685 echo $ECHO_N "(cached) $ECHO_C" >&6
14686else
14687 if test -n "$ac_ct_OBJDUMP"; then
14688 ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
14689else
14690as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14691for as_dir in $PATH
14692do
14693 IFS=$as_save_IFS
14694 test -z "$as_dir" && as_dir=.
14695 for ac_exec_ext in '' $ac_executable_extensions; do
14696 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
14697 ac_cv_prog_ac_ct_OBJDUMP="objdump"
14698 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
14699 break 2
14700 fi
14701done
14702done
14703
14704 test -z "$ac_cv_prog_ac_ct_OBJDUMP" && ac_cv_prog_ac_ct_OBJDUMP="false"
14705fi
14706fi
14707ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
14708if test -n "$ac_ct_OBJDUMP"; then
14709 echo "$as_me:$LINENO: result: $ac_ct_OBJDUMP" >&5
14710echo "${ECHO_T}$ac_ct_OBJDUMP" >&6
14711else
14712 echo "$as_me:$LINENO: result: no" >&5
14713echo "${ECHO_T}no" >&6
14714fi
14715
14716 OBJDUMP=$ac_ct_OBJDUMP
14717else
14718 OBJDUMP="$ac_cv_prog_OBJDUMP"
14719fi
14720
14721test -z "$OBJDUMP" && OBJDUMP=objdump
14722
14723
14724
14725
14726
14727
14728
14729
da0f6381
PB
14730
14731echo "$as_me:$LINENO: checking how to recognize dependent libraries" >&5
14732echo $ECHO_N "checking how to recognize dependent libraries... $ECHO_C" >&6
14733if test "${lt_cv_deplibs_check_method+set}" = set; then
14734 echo $ECHO_N "(cached) $ECHO_C" >&6
14735else
14736 lt_cv_file_magic_cmd='$MAGIC_CMD'
14737lt_cv_file_magic_test_file=
14738lt_cv_deplibs_check_method='unknown'
14739# Need to set the preceding variable on all platforms that support
14740# interlibrary dependencies.
14741# 'none' -- dependencies not supported.
14742# `unknown' -- same as none, but documents that we really don't know.
14743# 'pass_all' -- all dependencies passed with no checks.
14744# 'test_compile' -- check by making test program.
14745# 'file_magic [[regex]]' -- check by looking for files in library path
14746# which responds to the $file_magic_cmd with a given extended regex.
14747# If you have `file' or equivalent on your system and you're not sure
14748# whether `pass_all' will *always* work, you probably want this one.
14749
14750case $host_os in
14751aix[4-9]*)
14752 lt_cv_deplibs_check_method=pass_all
14753 ;;
14754
14755beos*)
14756 lt_cv_deplibs_check_method=pass_all
14757 ;;
14758
14759bsdi[45]*)
14760 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
14761 lt_cv_file_magic_cmd='/usr/bin/file -L'
14762 lt_cv_file_magic_test_file=/shlib/libc.so
14763 ;;
14764
14765cygwin*)
14766 # func_win32_libid is a shell function defined in ltmain.sh
14767 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
14768 lt_cv_file_magic_cmd='func_win32_libid'
14769 ;;
14770
14771mingw* | pw32*)
14772 # Base MSYS/MinGW do not provide the 'file' command needed by
14773 # func_win32_libid shell function, so use a weaker test based on 'objdump',
14774 # unless we find 'file', for example because we are cross-compiling.
14775 if ( file / ) >/dev/null 2>&1; then
14776 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
14777 lt_cv_file_magic_cmd='func_win32_libid'
14778 else
14779 lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
14780 lt_cv_file_magic_cmd='$OBJDUMP -f'
14781 fi
14782 ;;
14783
5d47bb02
PG
14784cegcc)
14785 # use the weaker test based on 'objdump'. See mingw*.
14786 lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
14787 lt_cv_file_magic_cmd='$OBJDUMP -f'
14788 ;;
14789
da0f6381
PB
14790darwin* | rhapsody*)
14791 lt_cv_deplibs_check_method=pass_all
14792 ;;
14793
14794freebsd* | dragonfly*)
14795 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
14796 case $host_cpu in
14797 i*86 )
14798 # Not sure whether the presence of OpenBSD here was a mistake.
14799 # Let's accept both of them until this is cleared up.
14800 lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library'
14801 lt_cv_file_magic_cmd=/usr/bin/file
14802 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
14803 ;;
14804 esac
14805 else
14806 lt_cv_deplibs_check_method=pass_all
14807 fi
14808 ;;
14809
14810gnu*)
14811 lt_cv_deplibs_check_method=pass_all
14812 ;;
14813
14814hpux10.20* | hpux11*)
14815 lt_cv_file_magic_cmd=/usr/bin/file
14816 case $host_cpu in
14817 ia64*)
14818 lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64'
14819 lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
14820 ;;
14821 hppa*64*)
14822 lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]'
14823 lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
14824 ;;
14825 *)
14826 lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9].[0-9]) shared library'
14827 lt_cv_file_magic_test_file=/usr/lib/libc.sl
14828 ;;
14829 esac
14830 ;;
14831
14832interix[3-9]*)
14833 # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
14834 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$'
14835 ;;
14836
14837irix5* | irix6* | nonstopux*)
14838 case $LD in
14839 *-32|*"-32 ") libmagic=32-bit;;
14840 *-n32|*"-n32 ") libmagic=N32;;
14841 *-64|*"-64 ") libmagic=64-bit;;
14842 *) libmagic=never-match;;
14843 esac
14844 lt_cv_deplibs_check_method=pass_all
14845 ;;
14846
14847# This must be Linux ELF.
7a9d3fe8 14848linux* | k*bsd*-gnu | kopensolaris*-gnu)
da0f6381
PB
14849 lt_cv_deplibs_check_method=pass_all
14850 ;;
14851
14852netbsd*)
14853 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
14854 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
14855 else
14856 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$'
14857 fi
14858 ;;
14859
14860newos6*)
14861 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
14862 lt_cv_file_magic_cmd=/usr/bin/file
14863 lt_cv_file_magic_test_file=/usr/lib/libnls.so
14864 ;;
14865
14866*nto* | *qnx*)
14867 lt_cv_deplibs_check_method=pass_all
14868 ;;
14869
14870openbsd*)
14871 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
14872 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$'
14873 else
14874 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
14875 fi
14876 ;;
14877
14878osf3* | osf4* | osf5*)
14879 lt_cv_deplibs_check_method=pass_all
14880 ;;
14881
14882rdos*)
14883 lt_cv_deplibs_check_method=pass_all
14884 ;;
14885
14886solaris*)
14887 lt_cv_deplibs_check_method=pass_all
14888 ;;
14889
14890sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
14891 lt_cv_deplibs_check_method=pass_all
14892 ;;
14893
14894sysv4 | sysv4.3*)
14895 case $host_vendor in
14896 motorola)
14897 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]'
14898 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
14899 ;;
14900 ncr)
14901 lt_cv_deplibs_check_method=pass_all
14902 ;;
14903 sequent)
14904 lt_cv_file_magic_cmd='/bin/file'
14905 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
14906 ;;
14907 sni)
14908 lt_cv_file_magic_cmd='/bin/file'
14909 lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"
14910 lt_cv_file_magic_test_file=/lib/libc.so
14911 ;;
14912 siemens)
14913 lt_cv_deplibs_check_method=pass_all
14914 ;;
14915 pc)
14916 lt_cv_deplibs_check_method=pass_all
14917 ;;
14918 esac
14919 ;;
14920
14921tpf*)
14922 lt_cv_deplibs_check_method=pass_all
14923 ;;
14924esac
14925
14926fi
14927echo "$as_me:$LINENO: result: $lt_cv_deplibs_check_method" >&5
14928echo "${ECHO_T}$lt_cv_deplibs_check_method" >&6
14929file_magic_cmd=$lt_cv_file_magic_cmd
14930deplibs_check_method=$lt_cv_deplibs_check_method
14931test -z "$deplibs_check_method" && deplibs_check_method=unknown
14932
14933
14934
14935
14936
14937
14938
14939
14940
14941
14942
14943
14944if test -n "$ac_tool_prefix"; then
14945 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
14946set dummy ${ac_tool_prefix}ar; ac_word=$2
14947echo "$as_me:$LINENO: checking for $ac_word" >&5
14948echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
14949if test "${ac_cv_prog_AR+set}" = set; then
14950 echo $ECHO_N "(cached) $ECHO_C" >&6
14951else
14952 if test -n "$AR"; then
14953 ac_cv_prog_AR="$AR" # Let the user override the test.
14954else
14955as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14956for as_dir in $PATH
14957do
14958 IFS=$as_save_IFS
14959 test -z "$as_dir" && as_dir=.
14960 for ac_exec_ext in '' $ac_executable_extensions; do
14961 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
14962 ac_cv_prog_AR="${ac_tool_prefix}ar"
14963 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
14964 break 2
14965 fi
14966done
14967done
14968
14969fi
14970fi
14971AR=$ac_cv_prog_AR
14972if test -n "$AR"; then
14973 echo "$as_me:$LINENO: result: $AR" >&5
14974echo "${ECHO_T}$AR" >&6
14975else
14976 echo "$as_me:$LINENO: result: no" >&5
14977echo "${ECHO_T}no" >&6
14978fi
14979
14980fi
14981if test -z "$ac_cv_prog_AR"; then
14982 ac_ct_AR=$AR
14983 # Extract the first word of "ar", so it can be a program name with args.
14984set dummy ar; ac_word=$2
14985echo "$as_me:$LINENO: checking for $ac_word" >&5
14986echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
14987if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
14988 echo $ECHO_N "(cached) $ECHO_C" >&6
14989else
14990 if test -n "$ac_ct_AR"; then
14991 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
14992else
14993as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14994for as_dir in $PATH
14995do
14996 IFS=$as_save_IFS
14997 test -z "$as_dir" && as_dir=.
14998 for ac_exec_ext in '' $ac_executable_extensions; do
14999 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15000 ac_cv_prog_ac_ct_AR="ar"
15001 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
15002 break 2
15003 fi
15004done
15005done
15006
15007 test -z "$ac_cv_prog_ac_ct_AR" && ac_cv_prog_ac_ct_AR="false"
15008fi
15009fi
15010ac_ct_AR=$ac_cv_prog_ac_ct_AR
15011if test -n "$ac_ct_AR"; then
15012 echo "$as_me:$LINENO: result: $ac_ct_AR" >&5
15013echo "${ECHO_T}$ac_ct_AR" >&6
15014else
15015 echo "$as_me:$LINENO: result: no" >&5
15016echo "${ECHO_T}no" >&6
15017fi
15018
15019 AR=$ac_ct_AR
15020else
15021 AR="$ac_cv_prog_AR"
15022fi
15023
15024test -z "$AR" && AR=ar
15025test -z "$AR_FLAGS" && AR_FLAGS=cru
15026
15027
15028
15029
15030
15031
15032
15033
15034
15035
15036
15037if test -n "$ac_tool_prefix"; then
15038 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
15039set dummy ${ac_tool_prefix}strip; ac_word=$2
15040echo "$as_me:$LINENO: checking for $ac_word" >&5
15041echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
15042if test "${ac_cv_prog_STRIP+set}" = set; then
15043 echo $ECHO_N "(cached) $ECHO_C" >&6
15044else
15045 if test -n "$STRIP"; then
15046 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
15047else
15048as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15049for as_dir in $PATH
15050do
15051 IFS=$as_save_IFS
15052 test -z "$as_dir" && as_dir=.
15053 for ac_exec_ext in '' $ac_executable_extensions; do
15054 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15055 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
15056 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
15057 break 2
15058 fi
15059done
15060done
15061
15062fi
15063fi
15064STRIP=$ac_cv_prog_STRIP
15065if test -n "$STRIP"; then
15066 echo "$as_me:$LINENO: result: $STRIP" >&5
15067echo "${ECHO_T}$STRIP" >&6
15068else
15069 echo "$as_me:$LINENO: result: no" >&5
15070echo "${ECHO_T}no" >&6
15071fi
15072
15073fi
15074if test -z "$ac_cv_prog_STRIP"; then
15075 ac_ct_STRIP=$STRIP
15076 # Extract the first word of "strip", so it can be a program name with args.
15077set dummy strip; ac_word=$2
15078echo "$as_me:$LINENO: checking for $ac_word" >&5
15079echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
15080if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
15081 echo $ECHO_N "(cached) $ECHO_C" >&6
15082else
15083 if test -n "$ac_ct_STRIP"; then
15084 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
15085else
15086as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15087for as_dir in $PATH
15088do
15089 IFS=$as_save_IFS
15090 test -z "$as_dir" && as_dir=.
15091 for ac_exec_ext in '' $ac_executable_extensions; do
15092 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15093 ac_cv_prog_ac_ct_STRIP="strip"
15094 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
15095 break 2
15096 fi
15097done
15098done
15099
15100 test -z "$ac_cv_prog_ac_ct_STRIP" && ac_cv_prog_ac_ct_STRIP=":"
15101fi
15102fi
15103ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
15104if test -n "$ac_ct_STRIP"; then
15105 echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
15106echo "${ECHO_T}$ac_ct_STRIP" >&6
15107else
15108 echo "$as_me:$LINENO: result: no" >&5
15109echo "${ECHO_T}no" >&6
15110fi
15111
15112 STRIP=$ac_ct_STRIP
15113else
15114 STRIP="$ac_cv_prog_STRIP"
15115fi
15116
15117test -z "$STRIP" && STRIP=:
15118
15119
15120
15121
15122
15123
15124if test -n "$ac_tool_prefix"; then
15125 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
15126set dummy ${ac_tool_prefix}ranlib; ac_word=$2
15127echo "$as_me:$LINENO: checking for $ac_word" >&5
15128echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
15129if test "${ac_cv_prog_RANLIB+set}" = set; then
15130 echo $ECHO_N "(cached) $ECHO_C" >&6
15131else
15132 if test -n "$RANLIB"; then
15133 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
15134else
15135as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15136for as_dir in $PATH
15137do
15138 IFS=$as_save_IFS
15139 test -z "$as_dir" && as_dir=.
15140 for ac_exec_ext in '' $ac_executable_extensions; do
15141 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15142 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
15143 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
15144 break 2
15145 fi
15146done
15147done
15148
15149fi
15150fi
15151RANLIB=$ac_cv_prog_RANLIB
15152if test -n "$RANLIB"; then
15153 echo "$as_me:$LINENO: result: $RANLIB" >&5
15154echo "${ECHO_T}$RANLIB" >&6
15155else
15156 echo "$as_me:$LINENO: result: no" >&5
15157echo "${ECHO_T}no" >&6
15158fi
15159
15160fi
15161if test -z "$ac_cv_prog_RANLIB"; then
15162 ac_ct_RANLIB=$RANLIB
15163 # Extract the first word of "ranlib", so it can be a program name with args.
15164set dummy ranlib; ac_word=$2
15165echo "$as_me:$LINENO: checking for $ac_word" >&5
15166echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
15167if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
15168 echo $ECHO_N "(cached) $ECHO_C" >&6
15169else
15170 if test -n "$ac_ct_RANLIB"; then
15171 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
15172else
15173as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15174for as_dir in $PATH
15175do
15176 IFS=$as_save_IFS
15177 test -z "$as_dir" && as_dir=.
15178 for ac_exec_ext in '' $ac_executable_extensions; do
15179 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15180 ac_cv_prog_ac_ct_RANLIB="ranlib"
15181 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
15182 break 2
15183 fi
15184done
15185done
15186
15187 test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
15188fi
15189fi
15190ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
15191if test -n "$ac_ct_RANLIB"; then
15192 echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
15193echo "${ECHO_T}$ac_ct_RANLIB" >&6
15194else
15195 echo "$as_me:$LINENO: result: no" >&5
15196echo "${ECHO_T}no" >&6
15197fi
15198
15199 RANLIB=$ac_ct_RANLIB
15200else
15201 RANLIB="$ac_cv_prog_RANLIB"
15202fi
15203
15204test -z "$RANLIB" && RANLIB=:
15205
15206
15207
15208
15209
15210
15211# Determine commands to create old-style static archives.
5d47bb02 15212old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
da0f6381
PB
15213old_postinstall_cmds='chmod 644 $oldlib'
15214old_postuninstall_cmds=
15215
15216if test -n "$RANLIB"; then
15217 case $host_os in
15218 openbsd*)
15219 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
15220 ;;
15221 *)
15222 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
15223 ;;
15224 esac
15225 old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
15226fi
15227
15228
15229
15230
15231
15232
15233
15234
15235
15236
15237
15238
15239
15240
15241
15242
15243
15244
15245
15246
15247
15248
15249
15250
15251
15252
15253
15254
15255
15256
15257
15258
15259
15260
15261# If no C compiler was specified, use CC.
15262LTCC=${LTCC-"$CC"}
15263
15264# If no C compiler flags were specified, use CFLAGS.
15265LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
15266
15267# Allow CC to be a program name with arguments.
15268compiler=$CC
15269
15270
15271# Check for command to grab the raw symbol name followed by C symbol from nm.
15272echo "$as_me:$LINENO: checking command to parse $NM output from $compiler object" >&5
15273echo $ECHO_N "checking command to parse $NM output from $compiler object... $ECHO_C" >&6
15274if test "${lt_cv_sys_global_symbol_pipe+set}" = set; then
15275 echo $ECHO_N "(cached) $ECHO_C" >&6
15276else
15277
15278# These are sane defaults that work on at least a few old systems.
15279# [They come from Ultrix. What could be older than Ultrix?!! ;)]
15280
15281# Character class describing NM global symbol codes.
15282symcode='[BCDEGRST]'
15283
15284# Regexp to match symbols that can be accessed directly from C.
15285sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
15286
15287# Define system-specific variables.
15288case $host_os in
15289aix*)
15290 symcode='[BCDT]'
15291 ;;
5d47bb02 15292cygwin* | mingw* | pw32* | cegcc*)
da0f6381
PB
15293 symcode='[ABCDGISTW]'
15294 ;;
15295hpux*)
15296 if test "$host_cpu" = ia64; then
15297 symcode='[ABCDEGRST]'
15298 fi
15299 ;;
15300irix* | nonstopux*)
15301 symcode='[BCDEGRST]'
15302 ;;
15303osf*)
15304 symcode='[BCDEGQRST]'
15305 ;;
15306solaris*)
15307 symcode='[BDRT]'
15308 ;;
15309sco3.2v5*)
15310 symcode='[DT]'
15311 ;;
15312sysv4.2uw2*)
15313 symcode='[DT]'
15314 ;;
15315sysv5* | sco5v6* | unixware* | OpenUNIX*)
15316 symcode='[ABDT]'
15317 ;;
15318sysv4)
15319 symcode='[DFNSTU]'
15320 ;;
15321esac
15322
15323# If we're using GNU nm, then use its standard symbol codes.
15324case `$NM -V 2>&1` in
15325*GNU* | *'with BFD'*)
15326 symcode='[ABCDGIRSTW]' ;;
15327esac
15328
15329# Transform an extracted symbol line into a proper C declaration.
15330# Some systems (esp. on ia64) link data and code symbols differently,
15331# so use this general approach.
15332lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
15333
15334# Transform an extracted symbol line into symbol name and symbol address
15335lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'"
5d47bb02 15336lt_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'"
da0f6381
PB
15337
15338# Handle CRLF in mingw tool chain
15339opt_cr=
15340case $build_os in
15341mingw*)
15342 opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
15343 ;;
15344esac
15345
15346# Try without a prefix underscore, then with it.
15347for ac_symprfx in "" "_"; do
15348
15349 # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
15350 symxfrm="\\1 $ac_symprfx\\2 \\2"
15351
15352 # Write the raw and C identifiers.
15353 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
15354 # Fake it for dumpbin and say T for any non-static function
15355 # and D for any global variable.
15356 # Also find C++ and __fastcall symbols from MSVC++,
15357 # which start with @ or ?.
15358 lt_cv_sys_global_symbol_pipe="$AWK '"\
15359" {last_section=section; section=\$ 3};"\
15360" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
15361" \$ 0!~/External *\|/{next};"\
15362" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
15363" {if(hide[section]) next};"\
15364" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\
15365" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\
15366" s[1]~/^[@?]/{print s[1], s[1]; next};"\
15367" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\
15368" ' prfx=^$ac_symprfx"
15369 else
15370 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
15371 fi
15372
15373 # Check to see that the pipe works correctly.
15374 pipe_works=no
15375
15376 rm -f conftest*
15377 cat > conftest.$ac_ext <<_LT_EOF
15378#ifdef __cplusplus
15379extern "C" {
15380#endif
15381char nm_test_var;
15382void nm_test_func(void);
15383void nm_test_func(void){}
15384#ifdef __cplusplus
15385}
15386#endif
15387int main(){nm_test_var='a';nm_test_func();return(0);}
15388_LT_EOF
15389
15390 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15391 (eval $ac_compile) 2>&5
15392 ac_status=$?
15393 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15394 (exit $ac_status); }; then
15395 # Now try to grab the symbols.
15396 nlist=conftest.nm
15397 if { (eval echo "$as_me:$LINENO: \"$NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist\"") >&5
15398 (eval $NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) 2>&5
15399 ac_status=$?
15400 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15401 (exit $ac_status); } && test -s "$nlist"; then
15402 # Try sorting and uniquifying the output.
15403 if sort "$nlist" | uniq > "$nlist"T; then
15404 mv -f "$nlist"T "$nlist"
15405 else
15406 rm -f "$nlist"T
15407 fi
15408
15409 # Make sure that we snagged all the symbols we need.
15410 if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
15411 if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
15412 cat <<_LT_EOF > conftest.$ac_ext
15413#ifdef __cplusplus
15414extern "C" {
15415#endif
15416
15417_LT_EOF
15418 # Now generate the symbol file.
15419 eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
15420
15421 cat <<_LT_EOF >> conftest.$ac_ext
15422
15423/* The mapping between symbol names and symbols. */
15424const struct {
15425 const char *name;
15426 void *address;
15427}
15428lt__PROGRAM__LTX_preloaded_symbols[] =
15429{
15430 { "@PROGRAM@", (void *) 0 },
15431_LT_EOF
15432 $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
15433 cat <<\_LT_EOF >> conftest.$ac_ext
15434 {0, (void *) 0}
15435};
15436
15437/* This works around a problem in FreeBSD linker */
15438#ifdef FREEBSD_WORKAROUND
15439static const void *lt_preloaded_setup() {
15440 return lt__PROGRAM__LTX_preloaded_symbols;
15441}
15442#endif
15443
15444#ifdef __cplusplus
15445}
15446#endif
15447_LT_EOF
15448 # Now try linking the two files.
15449 mv conftest.$ac_objext conftstm.$ac_objext
15450 lt_save_LIBS="$LIBS"
15451 lt_save_CFLAGS="$CFLAGS"
15452 LIBS="conftstm.$ac_objext"
15453 CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
15454 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15455 (eval $ac_link) 2>&5
15456 ac_status=$?
15457 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15458 (exit $ac_status); } && test -s conftest${ac_exeext}; then
15459 pipe_works=yes
15460 fi
15461 LIBS="$lt_save_LIBS"
15462 CFLAGS="$lt_save_CFLAGS"
15463 else
15464 echo "cannot find nm_test_func in $nlist" >&5
15465 fi
15466 else
15467 echo "cannot find nm_test_var in $nlist" >&5
15468 fi
15469 else
15470 echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5
15471 fi
15472 else
15473 echo "$progname: failed program was:" >&5
15474 cat conftest.$ac_ext >&5
15475 fi
5d47bb02 15476 rm -rf conftest* conftst*
da0f6381
PB
15477
15478 # Do not use the global_symbol_pipe unless it works.
15479 if test "$pipe_works" = yes; then
15480 break
15481 else
15482 lt_cv_sys_global_symbol_pipe=
15483 fi
15484done
15485
15486fi
15487
15488if test -z "$lt_cv_sys_global_symbol_pipe"; then
15489 lt_cv_sys_global_symbol_to_cdecl=
15490fi
15491if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
15492 echo "$as_me:$LINENO: result: failed" >&5
15493echo "${ECHO_T}failed" >&6
15494else
15495 echo "$as_me:$LINENO: result: ok" >&5
15496echo "${ECHO_T}ok" >&6
15497fi
15498
15499
15500
15501
15502
15503
15504
15505
15506
15507
15508
15509
15510
15511
15512
5d47bb02
PG
15513
15514
15515
15516
15517
da0f6381
PB
15518
15519
15520# Check whether --enable-libtool-lock or --disable-libtool-lock was given.
15521if test "${enable_libtool_lock+set}" = set; then
15522 enableval="$enable_libtool_lock"
15523
15524fi;
15525test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
15526
15527# Some flags need to be propagated to the compiler or linker for good
15528# libtool support.
15529case $host in
15530ia64-*-hpux*)
15531 # Find out which ABI we are using.
15532 echo 'int i;' > conftest.$ac_ext
15533 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15534 (eval $ac_compile) 2>&5
15535 ac_status=$?
15536 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15537 (exit $ac_status); }; then
15538 case `/usr/bin/file conftest.$ac_objext` in
15539 *ELF-32*)
15540 HPUX_IA64_MODE="32"
15541 ;;
15542 *ELF-64*)
15543 HPUX_IA64_MODE="64"
15544 ;;
15545 esac
15546 fi
15547 rm -rf conftest*
15548 ;;
15549*-*-irix6*)
15550 # Find out which ABI we are using.
cd533689 15551 echo '#line 15551 "configure"' > conftest.$ac_ext
da0f6381
PB
15552 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15553 (eval $ac_compile) 2>&5
15554 ac_status=$?
15555 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15556 (exit $ac_status); }; then
15557 if test "$lt_cv_prog_gnu_ld" = yes; then
15558 case `/usr/bin/file conftest.$ac_objext` in
15559 *32-bit*)
15560 LD="${LD-ld} -melf32bsmip"
15561 ;;
15562 *N32*)
15563 LD="${LD-ld} -melf32bmipn32"
15564 ;;
15565 *64-bit*)
15566 LD="${LD-ld} -melf64bmip"
15567 ;;
15568 esac
15569 else
15570 case `/usr/bin/file conftest.$ac_objext` in
15571 *32-bit*)
15572 LD="${LD-ld} -32"
15573 ;;
15574 *N32*)
15575 LD="${LD-ld} -n32"
15576 ;;
15577 *64-bit*)
15578 LD="${LD-ld} -64"
15579 ;;
15580 esac
15581 fi
15582 fi
15583 rm -rf conftest*
15584 ;;
15585
15586x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \
15587s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
15588 # Find out which ABI we are using.
15589 echo 'int i;' > conftest.$ac_ext
15590 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15591 (eval $ac_compile) 2>&5
15592 ac_status=$?
15593 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15594 (exit $ac_status); }; then
15595 case `/usr/bin/file conftest.o` in
15596 *32-bit*)
15597 case $host in
15598 x86_64-*kfreebsd*-gnu)
15599 LD="${LD-ld} -m elf_i386_fbsd"
15600 ;;
15601 x86_64-*linux*)
15602 LD="${LD-ld} -m elf_i386"
15603 ;;
15604 ppc64-*linux*|powerpc64-*linux*)
15605 LD="${LD-ld} -m elf32ppclinux"
15606 ;;
15607 s390x-*linux*)
15608 LD="${LD-ld} -m elf_s390"
15609 ;;
15610 sparc64-*linux*)
15611 LD="${LD-ld} -m elf32_sparc"
15612 ;;
15613 esac
15614 ;;
15615 *64-bit*)
15616 case $host in
15617 x86_64-*kfreebsd*-gnu)
15618 LD="${LD-ld} -m elf_x86_64_fbsd"
15619 ;;
15620 x86_64-*linux*)
15621 LD="${LD-ld} -m elf_x86_64"
15622 ;;
15623 ppc*-*linux*|powerpc*-*linux*)
15624 LD="${LD-ld} -m elf64ppc"
15625 ;;
15626 s390*-*linux*|s390*-*tpf*)
15627 LD="${LD-ld} -m elf64_s390"
15628 ;;
15629 sparc*-*linux*)
15630 LD="${LD-ld} -m elf64_sparc"
15631 ;;
15632 esac
15633 ;;
15634 esac
15635 fi
15636 rm -rf conftest*
15637 ;;
15638
15639*-*-sco3.2v5*)
15640 # On SCO OpenServer 5, we need -belf to get full-featured binaries.
15641 SAVE_CFLAGS="$CFLAGS"
15642 CFLAGS="$CFLAGS -belf"
15643 echo "$as_me:$LINENO: checking whether the C compiler needs -belf" >&5
15644echo $ECHO_N "checking whether the C compiler needs -belf... $ECHO_C" >&6
15645if test "${lt_cv_cc_needs_belf+set}" = set; then
15646 echo $ECHO_N "(cached) $ECHO_C" >&6
15647else
15648 ac_ext=c
15649ac_cpp='$CPP $CPPFLAGS'
15650ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
15651ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
15652ac_compiler_gnu=$ac_cv_c_compiler_gnu
15653
15654 cat >conftest.$ac_ext <<_ACEOF
15655/* confdefs.h. */
15656_ACEOF
15657cat confdefs.h >>conftest.$ac_ext
15658cat >>conftest.$ac_ext <<_ACEOF
15659/* end confdefs.h. */
15660
15661int
15662main ()
15663{
15664
15665 ;
15666 return 0;
15667}
15668_ACEOF
15669rm -f conftest.$ac_objext conftest$ac_exeext
15670if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15671 (eval $ac_link) 2>conftest.er1
15672 ac_status=$?
15673 grep -v '^ *+' conftest.er1 >conftest.err
15674 rm -f conftest.er1
15675 cat conftest.err >&5
15676 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15677 (exit $ac_status); } &&
15678 { ac_try='test -z "$ac_c_werror_flag"
15679 || test ! -s conftest.err'
15680 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15681 (eval $ac_try) 2>&5
15682 ac_status=$?
15683 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15684 (exit $ac_status); }; } &&
15685 { ac_try='test -s conftest$ac_exeext'
15686 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15687 (eval $ac_try) 2>&5
15688 ac_status=$?
15689 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15690 (exit $ac_status); }; }; then
15691 lt_cv_cc_needs_belf=yes
15692else
15693 echo "$as_me: failed program was:" >&5
15694sed 's/^/| /' conftest.$ac_ext >&5
15695
15696lt_cv_cc_needs_belf=no
15697fi
15698rm -f conftest.err conftest.$ac_objext \
15699 conftest$ac_exeext conftest.$ac_ext
15700 ac_ext=c
15701ac_cpp='$CPP $CPPFLAGS'
15702ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
15703ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
15704ac_compiler_gnu=$ac_cv_c_compiler_gnu
15705
15706fi
15707echo "$as_me:$LINENO: result: $lt_cv_cc_needs_belf" >&5
15708echo "${ECHO_T}$lt_cv_cc_needs_belf" >&6
15709 if test x"$lt_cv_cc_needs_belf" != x"yes"; then
15710 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
15711 CFLAGS="$SAVE_CFLAGS"
15712 fi
15713 ;;
15714sparc*-*solaris*)
15715 # Find out which ABI we are using.
15716 echo 'int i;' > conftest.$ac_ext
15717 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15718 (eval $ac_compile) 2>&5
15719 ac_status=$?
15720 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15721 (exit $ac_status); }; then
15722 case `/usr/bin/file conftest.o` in
15723 *64-bit*)
15724 case $lt_cv_prog_gnu_ld in
15725 yes*) LD="${LD-ld} -m elf64_sparc" ;;
5d47bb02
PG
15726 *)
15727 if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
15728 LD="${LD-ld} -64"
15729 fi
15730 ;;
da0f6381
PB
15731 esac
15732 ;;
15733 esac
15734 fi
15735 rm -rf conftest*
15736 ;;
15737esac
15738
5d47bb02
PG
15739need_locks="$enable_libtool_lock"
15740
15741
15742 case $host_os in
15743 rhapsody* | darwin*)
15744 if test -n "$ac_tool_prefix"; then
15745 # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args.
15746set dummy ${ac_tool_prefix}dsymutil; ac_word=$2
15747echo "$as_me:$LINENO: checking for $ac_word" >&5
15748echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
15749if test "${ac_cv_prog_DSYMUTIL+set}" = set; then
15750 echo $ECHO_N "(cached) $ECHO_C" >&6
15751else
15752 if test -n "$DSYMUTIL"; then
15753 ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
15754else
15755as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15756for as_dir in $PATH
15757do
15758 IFS=$as_save_IFS
15759 test -z "$as_dir" && as_dir=.
15760 for ac_exec_ext in '' $ac_executable_extensions; do
15761 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15762 ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil"
15763 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
15764 break 2
15765 fi
15766done
15767done
15768
15769fi
15770fi
15771DSYMUTIL=$ac_cv_prog_DSYMUTIL
15772if test -n "$DSYMUTIL"; then
15773 echo "$as_me:$LINENO: result: $DSYMUTIL" >&5
15774echo "${ECHO_T}$DSYMUTIL" >&6
15775else
15776 echo "$as_me:$LINENO: result: no" >&5
15777echo "${ECHO_T}no" >&6
15778fi
15779
15780fi
15781if test -z "$ac_cv_prog_DSYMUTIL"; then
15782 ac_ct_DSYMUTIL=$DSYMUTIL
15783 # Extract the first word of "dsymutil", so it can be a program name with args.
15784set dummy dsymutil; ac_word=$2
15785echo "$as_me:$LINENO: checking for $ac_word" >&5
15786echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
15787if test "${ac_cv_prog_ac_ct_DSYMUTIL+set}" = set; then
15788 echo $ECHO_N "(cached) $ECHO_C" >&6
15789else
15790 if test -n "$ac_ct_DSYMUTIL"; then
15791 ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test.
15792else
15793as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15794for as_dir in $PATH
15795do
15796 IFS=$as_save_IFS
15797 test -z "$as_dir" && as_dir=.
15798 for ac_exec_ext in '' $ac_executable_extensions; do
15799 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15800 ac_cv_prog_ac_ct_DSYMUTIL="dsymutil"
15801 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
15802 break 2
15803 fi
15804done
15805done
15806
15807 test -z "$ac_cv_prog_ac_ct_DSYMUTIL" && ac_cv_prog_ac_ct_DSYMUTIL=":"
15808fi
15809fi
15810ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL
15811if test -n "$ac_ct_DSYMUTIL"; then
15812 echo "$as_me:$LINENO: result: $ac_ct_DSYMUTIL" >&5
15813echo "${ECHO_T}$ac_ct_DSYMUTIL" >&6
15814else
15815 echo "$as_me:$LINENO: result: no" >&5
15816echo "${ECHO_T}no" >&6
15817fi
15818
15819 DSYMUTIL=$ac_ct_DSYMUTIL
15820else
15821 DSYMUTIL="$ac_cv_prog_DSYMUTIL"
15822fi
15823
15824 if test -n "$ac_tool_prefix"; then
15825 # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args.
15826set dummy ${ac_tool_prefix}nmedit; ac_word=$2
15827echo "$as_me:$LINENO: checking for $ac_word" >&5
15828echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
15829if test "${ac_cv_prog_NMEDIT+set}" = set; then
15830 echo $ECHO_N "(cached) $ECHO_C" >&6
15831else
15832 if test -n "$NMEDIT"; then
15833 ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test.
15834else
15835as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15836for as_dir in $PATH
15837do
15838 IFS=$as_save_IFS
15839 test -z "$as_dir" && as_dir=.
15840 for ac_exec_ext in '' $ac_executable_extensions; do
15841 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15842 ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit"
15843 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
15844 break 2
15845 fi
15846done
15847done
15848
15849fi
15850fi
15851NMEDIT=$ac_cv_prog_NMEDIT
15852if test -n "$NMEDIT"; then
15853 echo "$as_me:$LINENO: result: $NMEDIT" >&5
15854echo "${ECHO_T}$NMEDIT" >&6
15855else
15856 echo "$as_me:$LINENO: result: no" >&5
15857echo "${ECHO_T}no" >&6
15858fi
15859
15860fi
15861if test -z "$ac_cv_prog_NMEDIT"; then
15862 ac_ct_NMEDIT=$NMEDIT
15863 # Extract the first word of "nmedit", so it can be a program name with args.
15864set dummy nmedit; ac_word=$2
15865echo "$as_me:$LINENO: checking for $ac_word" >&5
15866echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
15867if test "${ac_cv_prog_ac_ct_NMEDIT+set}" = set; then
15868 echo $ECHO_N "(cached) $ECHO_C" >&6
15869else
15870 if test -n "$ac_ct_NMEDIT"; then
15871 ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test.
15872else
15873as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15874for as_dir in $PATH
15875do
15876 IFS=$as_save_IFS
15877 test -z "$as_dir" && as_dir=.
15878 for ac_exec_ext in '' $ac_executable_extensions; do
15879 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15880 ac_cv_prog_ac_ct_NMEDIT="nmedit"
15881 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
15882 break 2
15883 fi
15884done
15885done
15886
15887 test -z "$ac_cv_prog_ac_ct_NMEDIT" && ac_cv_prog_ac_ct_NMEDIT=":"
15888fi
15889fi
15890ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT
15891if test -n "$ac_ct_NMEDIT"; then
15892 echo "$as_me:$LINENO: result: $ac_ct_NMEDIT" >&5
15893echo "${ECHO_T}$ac_ct_NMEDIT" >&6
15894else
15895 echo "$as_me:$LINENO: result: no" >&5
15896echo "${ECHO_T}no" >&6
15897fi
15898
15899 NMEDIT=$ac_ct_NMEDIT
15900else
15901 NMEDIT="$ac_cv_prog_NMEDIT"
15902fi
15903
15904 if test -n "$ac_tool_prefix"; then
15905 # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args.
15906set dummy ${ac_tool_prefix}lipo; ac_word=$2
15907echo "$as_me:$LINENO: checking for $ac_word" >&5
15908echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
15909if test "${ac_cv_prog_LIPO+set}" = set; then
15910 echo $ECHO_N "(cached) $ECHO_C" >&6
15911else
15912 if test -n "$LIPO"; then
15913 ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
15914else
15915as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15916for as_dir in $PATH
15917do
15918 IFS=$as_save_IFS
15919 test -z "$as_dir" && as_dir=.
15920 for ac_exec_ext in '' $ac_executable_extensions; do
15921 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15922 ac_cv_prog_LIPO="${ac_tool_prefix}lipo"
15923 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
15924 break 2
15925 fi
15926done
15927done
15928
15929fi
15930fi
15931LIPO=$ac_cv_prog_LIPO
15932if test -n "$LIPO"; then
15933 echo "$as_me:$LINENO: result: $LIPO" >&5
15934echo "${ECHO_T}$LIPO" >&6
15935else
15936 echo "$as_me:$LINENO: result: no" >&5
15937echo "${ECHO_T}no" >&6
15938fi
15939
15940fi
15941if test -z "$ac_cv_prog_LIPO"; then
15942 ac_ct_LIPO=$LIPO
15943 # Extract the first word of "lipo", so it can be a program name with args.
15944set dummy lipo; ac_word=$2
15945echo "$as_me:$LINENO: checking for $ac_word" >&5
15946echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
15947if test "${ac_cv_prog_ac_ct_LIPO+set}" = set; then
15948 echo $ECHO_N "(cached) $ECHO_C" >&6
15949else
15950 if test -n "$ac_ct_LIPO"; then
15951 ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test.
15952else
15953as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15954for as_dir in $PATH
15955do
15956 IFS=$as_save_IFS
15957 test -z "$as_dir" && as_dir=.
15958 for ac_exec_ext in '' $ac_executable_extensions; do
15959 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15960 ac_cv_prog_ac_ct_LIPO="lipo"
15961 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
15962 break 2
15963 fi
15964done
15965done
15966
15967 test -z "$ac_cv_prog_ac_ct_LIPO" && ac_cv_prog_ac_ct_LIPO=":"
15968fi
15969fi
15970ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO
15971if test -n "$ac_ct_LIPO"; then
15972 echo "$as_me:$LINENO: result: $ac_ct_LIPO" >&5
15973echo "${ECHO_T}$ac_ct_LIPO" >&6
15974else
15975 echo "$as_me:$LINENO: result: no" >&5
15976echo "${ECHO_T}no" >&6
15977fi
15978
15979 LIPO=$ac_ct_LIPO
15980else
15981 LIPO="$ac_cv_prog_LIPO"
15982fi
15983
15984 if test -n "$ac_tool_prefix"; then
15985 # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args.
15986set dummy ${ac_tool_prefix}otool; ac_word=$2
15987echo "$as_me:$LINENO: checking for $ac_word" >&5
15988echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
15989if test "${ac_cv_prog_OTOOL+set}" = set; then
15990 echo $ECHO_N "(cached) $ECHO_C" >&6
15991else
15992 if test -n "$OTOOL"; then
15993 ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
15994else
15995as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15996for as_dir in $PATH
15997do
15998 IFS=$as_save_IFS
15999 test -z "$as_dir" && as_dir=.
16000 for ac_exec_ext in '' $ac_executable_extensions; do
16001 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16002 ac_cv_prog_OTOOL="${ac_tool_prefix}otool"
16003 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
16004 break 2
16005 fi
16006done
16007done
16008
16009fi
16010fi
16011OTOOL=$ac_cv_prog_OTOOL
16012if test -n "$OTOOL"; then
16013 echo "$as_me:$LINENO: result: $OTOOL" >&5
16014echo "${ECHO_T}$OTOOL" >&6
16015else
16016 echo "$as_me:$LINENO: result: no" >&5
16017echo "${ECHO_T}no" >&6
16018fi
16019
16020fi
16021if test -z "$ac_cv_prog_OTOOL"; then
16022 ac_ct_OTOOL=$OTOOL
16023 # Extract the first word of "otool", so it can be a program name with args.
16024set dummy otool; ac_word=$2
16025echo "$as_me:$LINENO: checking for $ac_word" >&5
16026echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
16027if test "${ac_cv_prog_ac_ct_OTOOL+set}" = set; then
16028 echo $ECHO_N "(cached) $ECHO_C" >&6
16029else
16030 if test -n "$ac_ct_OTOOL"; then
16031 ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test.
16032else
16033as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16034for as_dir in $PATH
16035do
16036 IFS=$as_save_IFS
16037 test -z "$as_dir" && as_dir=.
16038 for ac_exec_ext in '' $ac_executable_extensions; do
16039 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16040 ac_cv_prog_ac_ct_OTOOL="otool"
16041 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
16042 break 2
16043 fi
16044done
16045done
16046
16047 test -z "$ac_cv_prog_ac_ct_OTOOL" && ac_cv_prog_ac_ct_OTOOL=":"
16048fi
16049fi
16050ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL
16051if test -n "$ac_ct_OTOOL"; then
16052 echo "$as_me:$LINENO: result: $ac_ct_OTOOL" >&5
16053echo "${ECHO_T}$ac_ct_OTOOL" >&6
16054else
16055 echo "$as_me:$LINENO: result: no" >&5
16056echo "${ECHO_T}no" >&6
16057fi
16058
16059 OTOOL=$ac_ct_OTOOL
16060else
16061 OTOOL="$ac_cv_prog_OTOOL"
16062fi
16063
16064 if test -n "$ac_tool_prefix"; then
16065 # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args.
16066set dummy ${ac_tool_prefix}otool64; ac_word=$2
16067echo "$as_me:$LINENO: checking for $ac_word" >&5
16068echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
16069if test "${ac_cv_prog_OTOOL64+set}" = set; then
16070 echo $ECHO_N "(cached) $ECHO_C" >&6
16071else
16072 if test -n "$OTOOL64"; then
16073 ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test.
16074else
16075as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16076for as_dir in $PATH
16077do
16078 IFS=$as_save_IFS
16079 test -z "$as_dir" && as_dir=.
16080 for ac_exec_ext in '' $ac_executable_extensions; do
16081 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16082 ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64"
16083 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
16084 break 2
16085 fi
16086done
16087done
16088
16089fi
16090fi
16091OTOOL64=$ac_cv_prog_OTOOL64
16092if test -n "$OTOOL64"; then
16093 echo "$as_me:$LINENO: result: $OTOOL64" >&5
16094echo "${ECHO_T}$OTOOL64" >&6
16095else
16096 echo "$as_me:$LINENO: result: no" >&5
16097echo "${ECHO_T}no" >&6
16098fi
16099
16100fi
16101if test -z "$ac_cv_prog_OTOOL64"; then
16102 ac_ct_OTOOL64=$OTOOL64
16103 # Extract the first word of "otool64", so it can be a program name with args.
16104set dummy otool64; ac_word=$2
16105echo "$as_me:$LINENO: checking for $ac_word" >&5
16106echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
16107if test "${ac_cv_prog_ac_ct_OTOOL64+set}" = set; then
16108 echo $ECHO_N "(cached) $ECHO_C" >&6
16109else
16110 if test -n "$ac_ct_OTOOL64"; then
16111 ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test.
16112else
16113as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16114for as_dir in $PATH
16115do
16116 IFS=$as_save_IFS
16117 test -z "$as_dir" && as_dir=.
16118 for ac_exec_ext in '' $ac_executable_extensions; do
16119 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16120 ac_cv_prog_ac_ct_OTOOL64="otool64"
16121 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
16122 break 2
16123 fi
16124done
16125done
16126
16127 test -z "$ac_cv_prog_ac_ct_OTOOL64" && ac_cv_prog_ac_ct_OTOOL64=":"
16128fi
16129fi
16130ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64
16131if test -n "$ac_ct_OTOOL64"; then
16132 echo "$as_me:$LINENO: result: $ac_ct_OTOOL64" >&5
16133echo "${ECHO_T}$ac_ct_OTOOL64" >&6
16134else
16135 echo "$as_me:$LINENO: result: no" >&5
16136echo "${ECHO_T}no" >&6
16137fi
16138
16139 OTOOL64=$ac_ct_OTOOL64
16140else
16141 OTOOL64="$ac_cv_prog_OTOOL64"
16142fi
16143
16144
16145
16146
16147
16148
16149
16150
16151
16152
16153
16154
16155
16156
16157
16158
16159
16160
16161
16162
16163
16164
16165
16166
16167
16168
16169
16170 echo "$as_me:$LINENO: checking for -single_module linker flag" >&5
16171echo $ECHO_N "checking for -single_module linker flag... $ECHO_C" >&6
16172if test "${lt_cv_apple_cc_single_mod+set}" = set; then
16173 echo $ECHO_N "(cached) $ECHO_C" >&6
16174else
16175 lt_cv_apple_cc_single_mod=no
16176 if test -z "${LT_MULTI_MODULE}"; then
16177 # By default we will add the -single_module flag. You can override
16178 # by either setting the environment variable LT_MULTI_MODULE
16179 # non-empty at configure time, or by adding -multi_module to the
16180 # link flags.
16181 rm -rf libconftest.dylib*
16182 echo "int foo(void){return 1;}" > conftest.c
16183 echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
16184-dynamiclib -Wl,-single_module conftest.c" >&5
16185 $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
16186 -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
16187 _lt_result=$?
16188 if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then
16189 lt_cv_apple_cc_single_mod=yes
16190 else
16191 cat conftest.err >&5
16192 fi
16193 rm -rf libconftest.dylib*
16194 rm -f conftest.*
16195 fi
16196fi
16197echo "$as_me:$LINENO: result: $lt_cv_apple_cc_single_mod" >&5
16198echo "${ECHO_T}$lt_cv_apple_cc_single_mod" >&6
16199 echo "$as_me:$LINENO: checking for -exported_symbols_list linker flag" >&5
16200echo $ECHO_N "checking for -exported_symbols_list linker flag... $ECHO_C" >&6
16201if test "${lt_cv_ld_exported_symbols_list+set}" = set; then
16202 echo $ECHO_N "(cached) $ECHO_C" >&6
16203else
16204 lt_cv_ld_exported_symbols_list=no
16205 save_LDFLAGS=$LDFLAGS
16206 echo "_main" > conftest.sym
16207 LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
16208 cat >conftest.$ac_ext <<_ACEOF
16209/* confdefs.h. */
16210_ACEOF
16211cat confdefs.h >>conftest.$ac_ext
16212cat >>conftest.$ac_ext <<_ACEOF
16213/* end confdefs.h. */
16214
16215int
16216main ()
16217{
16218
16219 ;
16220 return 0;
16221}
16222_ACEOF
16223rm -f conftest.$ac_objext conftest$ac_exeext
16224if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16225 (eval $ac_link) 2>conftest.er1
16226 ac_status=$?
16227 grep -v '^ *+' conftest.er1 >conftest.err
16228 rm -f conftest.er1
16229 cat conftest.err >&5
16230 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16231 (exit $ac_status); } &&
16232 { ac_try='test -z "$ac_c_werror_flag"
16233 || test ! -s conftest.err'
16234 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16235 (eval $ac_try) 2>&5
16236 ac_status=$?
16237 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16238 (exit $ac_status); }; } &&
16239 { ac_try='test -s conftest$ac_exeext'
16240 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16241 (eval $ac_try) 2>&5
16242 ac_status=$?
16243 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16244 (exit $ac_status); }; }; then
16245 lt_cv_ld_exported_symbols_list=yes
16246else
16247 echo "$as_me: failed program was:" >&5
16248sed 's/^/| /' conftest.$ac_ext >&5
16249
16250lt_cv_ld_exported_symbols_list=no
16251fi
16252rm -f conftest.err conftest.$ac_objext \
16253 conftest$ac_exeext conftest.$ac_ext
16254 LDFLAGS="$save_LDFLAGS"
16255
16256fi
16257echo "$as_me:$LINENO: result: $lt_cv_ld_exported_symbols_list" >&5
16258echo "${ECHO_T}$lt_cv_ld_exported_symbols_list" >&6
16259 case $host_os in
16260 rhapsody* | darwin1.[012])
16261 _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
16262 darwin1.*)
16263 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
16264 darwin*) # darwin 5.x on
16265 # if running on 10.5 or later, the deployment target defaults
16266 # to the OS version, if on x86, and 10.4, the deployment
16267 # target defaults to 10.4. Don't you love it?
16268 case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
16269 10.0,*86*-darwin8*|10.0,*-darwin[91]*)
16270 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
16271 10.[012]*)
16272 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
16273 10.*)
16274 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
16275 esac
16276 ;;
16277 esac
16278 if test "$lt_cv_apple_cc_single_mod" = "yes"; then
16279 _lt_dar_single_mod='$single_module'
16280 fi
16281 if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
16282 _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
16283 else
16284 _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
16285 fi
16286 if test "$DSYMUTIL" != ":"; then
16287 _lt_dsymutil='~$DSYMUTIL $lib || :'
16288 else
16289 _lt_dsymutil=
16290 fi
16291 ;;
16292 esac
da0f6381
PB
16293
16294
16295for ac_header in dlfcn.h
16296do
16297as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
16298echo "$as_me:$LINENO: checking for $ac_header" >&5
16299echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16300if eval "test \"\${$as_ac_Header+set}\" = set"; then
16301 echo $ECHO_N "(cached) $ECHO_C" >&6
16302else
16303 cat >conftest.$ac_ext <<_ACEOF
16304/* confdefs.h. */
16305_ACEOF
16306cat confdefs.h >>conftest.$ac_ext
16307cat >>conftest.$ac_ext <<_ACEOF
16308/* end confdefs.h. */
16309#include <$ac_header>
16310_ACEOF
16311if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
16312 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
16313 ac_status=$?
16314 grep -v '^ *+' conftest.er1 >conftest.err
16315 rm -f conftest.er1
16316 cat conftest.err >&5
16317 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16318 (exit $ac_status); } >/dev/null; then
16319 if test -s conftest.err; then
16320 ac_cpp_err=$ac_c_preproc_warn_flag
16321 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
16322 else
16323 ac_cpp_err=
16324 fi
16325else
16326 ac_cpp_err=yes
16327fi
16328if test -z "$ac_cpp_err"; then
16329 eval "$as_ac_Header=yes"
16330else
16331 echo "$as_me: failed program was:" >&5
16332sed 's/^/| /' conftest.$ac_ext >&5
16333
16334 eval "$as_ac_Header=no"
16335fi
16336rm -f conftest.err conftest.$ac_ext
16337fi
16338echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
16339echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
16340if test `eval echo '${'$as_ac_Header'}'` = yes; then
16341 cat >>confdefs.h <<_ACEOF
16342#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
16343_ACEOF
16344
16345fi
16346done
16347
16348
16349
5d47bb02
PG
16350# Set options
16351
16352
16353
16354 enable_dlopen=no
16355
16356
16357 enable_win32_dll=no
16358
16359
16360 # Check whether --enable-shared or --disable-shared was given.
16361if test "${enable_shared+set}" = set; then
16362 enableval="$enable_shared"
16363 p=${PACKAGE-default}
16364 case $enableval in
16365 yes) enable_shared=yes ;;
16366 no) enable_shared=no ;;
16367 *)
16368 enable_shared=no
16369 # Look at the argument we got. We use all the common list separators.
16370 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
16371 for pkg in $enableval; do
16372 IFS="$lt_save_ifs"
16373 if test "X$pkg" = "X$p"; then
16374 enable_shared=yes
16375 fi
16376 done
16377 IFS="$lt_save_ifs"
16378 ;;
16379 esac
16380else
16381 enable_shared=yes
16382fi;
16383
16384
16385
16386
16387
16388
16389
16390
16391 # Check whether --enable-static or --disable-static was given.
16392if test "${enable_static+set}" = set; then
16393 enableval="$enable_static"
16394 p=${PACKAGE-default}
16395 case $enableval in
16396 yes) enable_static=yes ;;
16397 no) enable_static=no ;;
16398 *)
16399 enable_static=no
16400 # Look at the argument we got. We use all the common list separators.
16401 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
16402 for pkg in $enableval; do
16403 IFS="$lt_save_ifs"
16404 if test "X$pkg" = "X$p"; then
16405 enable_static=yes
16406 fi
16407 done
16408 IFS="$lt_save_ifs"
16409 ;;
16410 esac
16411else
16412 enable_static=yes
16413fi;
16414
16415
16416
16417
16418
16419
16420
16421
16422
16423# Check whether --with-pic or --without-pic was given.
16424if test "${with_pic+set}" = set; then
16425 withval="$with_pic"
16426 pic_mode="$withval"
16427else
16428 pic_mode=default
16429fi;
16430
16431test -z "$pic_mode" && pic_mode=default
16432
16433
16434
16435
16436
16437
16438
16439 # Check whether --enable-fast-install or --disable-fast-install was given.
16440if test "${enable_fast_install+set}" = set; then
16441 enableval="$enable_fast_install"
16442 p=${PACKAGE-default}
16443 case $enableval in
16444 yes) enable_fast_install=yes ;;
16445 no) enable_fast_install=no ;;
16446 *)
16447 enable_fast_install=no
16448 # Look at the argument we got. We use all the common list separators.
16449 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
16450 for pkg in $enableval; do
16451 IFS="$lt_save_ifs"
16452 if test "X$pkg" = "X$p"; then
16453 enable_fast_install=yes
16454 fi
16455 done
16456 IFS="$lt_save_ifs"
16457 ;;
16458 esac
16459else
16460 enable_fast_install=yes
16461fi;
16462
16463
16464
16465
16466
16467
16468
16469
16470
16471
da0f6381
PB
16472# This can be used to rebuild libtool when needed
16473LIBTOOL_DEPS="$ltmain"
16474
16475# Always use our own libtool.
16476LIBTOOL='$(SHELL) $(top_builddir)/libtool'
16477
16478
16479
16480
16481
16482
16483
16484
16485
16486
16487
16488
16489
16490
16491
16492
16493
16494
16495
16496
16497
16498
16499
16500
16501
16502test -z "$LN_S" && LN_S="ln -s"
16503
16504
16505
16506
16507
16508
16509
16510
16511
16512
16513
16514
16515
16516
16517if test -n "${ZSH_VERSION+set}" ; then
16518 setopt NO_GLOB_SUBST
16519fi
16520
16521echo "$as_me:$LINENO: checking for objdir" >&5
16522echo $ECHO_N "checking for objdir... $ECHO_C" >&6
16523if test "${lt_cv_objdir+set}" = set; then
16524 echo $ECHO_N "(cached) $ECHO_C" >&6
16525else
16526 rm -f .libs 2>/dev/null
16527mkdir .libs 2>/dev/null
16528if test -d .libs; then
16529 lt_cv_objdir=.libs
16530else
16531 # MS-DOS does not allow filenames that begin with a dot.
16532 lt_cv_objdir=_libs
16533fi
16534rmdir .libs 2>/dev/null
16535fi
16536echo "$as_me:$LINENO: result: $lt_cv_objdir" >&5
16537echo "${ECHO_T}$lt_cv_objdir" >&6
16538objdir=$lt_cv_objdir
16539
16540
16541
16542
16543
16544cat >>confdefs.h <<_ACEOF
16545#define LT_OBJDIR "$lt_cv_objdir/"
16546_ACEOF
16547
16548
16549
16550
16551
16552
16553
16554
16555
16556
16557
16558
16559
16560
16561
16562
16563
16564case $host_os in
16565aix3*)
16566 # AIX sometimes has problems with the GCC collect2 program. For some
16567 # reason, if we set the COLLECT_NAMES environment variable, the problems
16568 # vanish in a puff of smoke.
16569 if test "X${COLLECT_NAMES+set}" != Xset; then
16570 COLLECT_NAMES=
16571 export COLLECT_NAMES
16572 fi
16573 ;;
16574esac
16575
16576# Sed substitution that helps us do robust quoting. It backslashifies
16577# metacharacters that are still active within double-quoted strings.
16578sed_quote_subst='s/\(["`$\\]\)/\\\1/g'
16579
16580# Same as above, but do not quote variable references.
16581double_quote_subst='s/\(["`\\]\)/\\\1/g'
16582
16583# Sed substitution to delay expansion of an escaped shell variable in a
16584# double_quote_subst'ed string.
16585delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
16586
16587# Sed substitution to delay expansion of an escaped single quote.
16588delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
16589
16590# Sed substitution to avoid accidental globbing in evaled expressions
16591no_glob_subst='s/\*/\\\*/g'
16592
16593# Global variables:
16594ofile=libtool
16595can_build_shared=yes
16596
16597# All known linkers require a `.a' archive for static linking (except MSVC,
16598# which needs '.lib').
16599libext=a
16600
16601with_gnu_ld="$lt_cv_prog_gnu_ld"
16602
16603old_CC="$CC"
16604old_CFLAGS="$CFLAGS"
16605
16606# Set sane defaults for various variables
16607test -z "$CC" && CC=cc
16608test -z "$LTCC" && LTCC=$CC
16609test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
16610test -z "$LD" && LD=ld
16611test -z "$ac_objext" && ac_objext=o
16612
16613for cc_temp in $compiler""; do
16614 case $cc_temp in
16615 compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
16616 distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
16617 \-*) ;;
16618 *) break;;
16619 esac
16620done
16621cc_basename=`$ECHO "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
16622
16623
16624# Only perform the check for file, if the check method requires it
16625test -z "$MAGIC_CMD" && MAGIC_CMD=file
16626case $deplibs_check_method in
16627file_magic*)
16628 if test "$file_magic_cmd" = '$MAGIC_CMD'; then
16629 echo "$as_me:$LINENO: checking for ${ac_tool_prefix}file" >&5
16630echo $ECHO_N "checking for ${ac_tool_prefix}file... $ECHO_C" >&6
16631if test "${lt_cv_path_MAGIC_CMD+set}" = set; then
16632 echo $ECHO_N "(cached) $ECHO_C" >&6
16633else
16634 case $MAGIC_CMD in
16635[\\/*] | ?:[\\/]*)
16636 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
16637 ;;
16638*)
16639 lt_save_MAGIC_CMD="$MAGIC_CMD"
16640 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
16641 ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
16642 for ac_dir in $ac_dummy; do
16643 IFS="$lt_save_ifs"
16644 test -z "$ac_dir" && ac_dir=.
16645 if test -f $ac_dir/${ac_tool_prefix}file; then
16646 lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file"
16647 if test -n "$file_magic_test_file"; then
16648 case $deplibs_check_method in
16649 "file_magic "*)
16650 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
16651 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
16652 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
16653 $EGREP "$file_magic_regex" > /dev/null; then
16654 :
16655 else
16656 cat <<_LT_EOF 1>&2
16657
16658*** Warning: the command libtool uses to detect shared libraries,
16659*** $file_magic_cmd, produces output that libtool cannot recognize.
16660*** The result is that libtool may fail to recognize shared libraries
16661*** as such. This will affect the creation of libtool libraries that
16662*** depend on shared libraries, but programs linked with such libtool
16663*** libraries will work regardless of this problem. Nevertheless, you
16664*** may want to report the problem to your system manager and/or to
16665*** bug-libtool@gnu.org
16666
16667_LT_EOF
16668 fi ;;
16669 esac
16670 fi
16671 break
16672 fi
16673 done
16674 IFS="$lt_save_ifs"
16675 MAGIC_CMD="$lt_save_MAGIC_CMD"
16676 ;;
16677esac
16678fi
16679
16680MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
16681if test -n "$MAGIC_CMD"; then
16682 echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5
16683echo "${ECHO_T}$MAGIC_CMD" >&6
16684else
16685 echo "$as_me:$LINENO: result: no" >&5
16686echo "${ECHO_T}no" >&6
16687fi
16688
16689
16690
16691
16692
16693if test -z "$lt_cv_path_MAGIC_CMD"; then
16694 if test -n "$ac_tool_prefix"; then
16695 echo "$as_me:$LINENO: checking for file" >&5
16696echo $ECHO_N "checking for file... $ECHO_C" >&6
16697if test "${lt_cv_path_MAGIC_CMD+set}" = set; then
16698 echo $ECHO_N "(cached) $ECHO_C" >&6
16699else
16700 case $MAGIC_CMD in
16701[\\/*] | ?:[\\/]*)
16702 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
16703 ;;
16704*)
16705 lt_save_MAGIC_CMD="$MAGIC_CMD"
16706 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
16707 ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
16708 for ac_dir in $ac_dummy; do
16709 IFS="$lt_save_ifs"
16710 test -z "$ac_dir" && ac_dir=.
16711 if test -f $ac_dir/file; then
16712 lt_cv_path_MAGIC_CMD="$ac_dir/file"
16713 if test -n "$file_magic_test_file"; then
16714 case $deplibs_check_method in
16715 "file_magic "*)
16716 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
16717 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
16718 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
16719 $EGREP "$file_magic_regex" > /dev/null; then
16720 :
16721 else
16722 cat <<_LT_EOF 1>&2
16723
16724*** Warning: the command libtool uses to detect shared libraries,
16725*** $file_magic_cmd, produces output that libtool cannot recognize.
16726*** The result is that libtool may fail to recognize shared libraries
16727*** as such. This will affect the creation of libtool libraries that
16728*** depend on shared libraries, but programs linked with such libtool
16729*** libraries will work regardless of this problem. Nevertheless, you
16730*** may want to report the problem to your system manager and/or to
16731*** bug-libtool@gnu.org
16732
16733_LT_EOF
16734 fi ;;
16735 esac
16736 fi
16737 break
16738 fi
16739 done
16740 IFS="$lt_save_ifs"
16741 MAGIC_CMD="$lt_save_MAGIC_CMD"
16742 ;;
16743esac
16744fi
16745
16746MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
16747if test -n "$MAGIC_CMD"; then
16748 echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5
16749echo "${ECHO_T}$MAGIC_CMD" >&6
16750else
16751 echo "$as_me:$LINENO: result: no" >&5
16752echo "${ECHO_T}no" >&6
16753fi
16754
16755
16756 else
16757 MAGIC_CMD=:
16758 fi
16759fi
16760
16761 fi
16762 ;;
16763esac
16764
16765# Use C for the default configuration in the libtool script
16766
16767lt_save_CC="$CC"
16768ac_ext=c
16769ac_cpp='$CPP $CPPFLAGS'
16770ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
16771ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
16772ac_compiler_gnu=$ac_cv_c_compiler_gnu
16773
16774
16775# Source file extension for C test sources.
16776ac_ext=c
16777
16778# Object file extension for compiled C test sources.
16779objext=o
16780objext=$objext
16781
16782# Code to be used in simple compile tests
16783lt_simple_compile_test_code="int some_variable = 0;"
16784
16785# Code to be used in simple link tests
16786lt_simple_link_test_code='int main(){return(0);}'
16787
16788
16789
16790
16791
16792
16793
16794# If no C compiler was specified, use CC.
16795LTCC=${LTCC-"$CC"}
16796
16797# If no C compiler flags were specified, use CFLAGS.
16798LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
16799
16800# Allow CC to be a program name with arguments.
16801compiler=$CC
16802
16803# Save the default compiler, since it gets overwritten when the other
16804# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
16805compiler_DEFAULT=$CC
16806
16807# save warnings/boilerplate of simple test code
16808ac_outfile=conftest.$ac_objext
16809echo "$lt_simple_compile_test_code" >conftest.$ac_ext
16810eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
16811_lt_compiler_boilerplate=`cat conftest.err`
16812$RM conftest*
16813
16814ac_outfile=conftest.$ac_objext
16815echo "$lt_simple_link_test_code" >conftest.$ac_ext
16816eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
16817_lt_linker_boilerplate=`cat conftest.err`
5d47bb02 16818$RM -r conftest*
da0f6381
PB
16819
16820
16821## CAVEAT EMPTOR:
16822## There is no encapsulation within the following macros, do not change
16823## the running order or otherwise move them around unless you know exactly
16824## what you are doing...
16825if test -n "$compiler"; then
16826
16827lt_prog_compiler_no_builtin_flag=
16828
16829if test "$GCC" = yes; then
16830 lt_prog_compiler_no_builtin_flag=' -fno-builtin'
16831
16832 echo "$as_me:$LINENO: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
16833echo $ECHO_N "checking if $compiler supports -fno-rtti -fno-exceptions... $ECHO_C" >&6
16834if test "${lt_cv_prog_compiler_rtti_exceptions+set}" = set; then
16835 echo $ECHO_N "(cached) $ECHO_C" >&6
16836else
16837 lt_cv_prog_compiler_rtti_exceptions=no
16838 ac_outfile=conftest.$ac_objext
16839 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
16840 lt_compiler_flag="-fno-rtti -fno-exceptions"
16841 # Insert the option either (1) after the last *FLAGS variable, or
16842 # (2) before a word containing "conftest.", or (3) at the end.
16843 # Note that $ac_compile itself does not contain backslashes and begins
16844 # with a dollar sign (not a hyphen), so the echo should work correctly.
16845 # The option is referenced via a variable to avoid confusing sed.
16846 lt_compile=`echo "$ac_compile" | $SED \
16847 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
16848 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
16849 -e 's:$: $lt_compiler_flag:'`
cd533689 16850 (eval echo "\"\$as_me:16850: $lt_compile\"" >&5)
da0f6381
PB
16851 (eval "$lt_compile" 2>conftest.err)
16852 ac_status=$?
16853 cat conftest.err >&5
cd533689 16854 echo "$as_me:16854: \$? = $ac_status" >&5
da0f6381
PB
16855 if (exit $ac_status) && test -s "$ac_outfile"; then
16856 # The compiler can only warn and ignore the option if not recognized
16857 # So say no if there are warnings other than the usual output.
16858 $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
16859 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
16860 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
16861 lt_cv_prog_compiler_rtti_exceptions=yes
16862 fi
16863 fi
16864 $RM conftest*
16865
16866fi
16867echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
16868echo "${ECHO_T}$lt_cv_prog_compiler_rtti_exceptions" >&6
16869
16870if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then
16871 lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions"
16872else
16873 :
16874fi
16875
16876fi
16877
16878
16879
16880
16881
16882
16883 lt_prog_compiler_wl=
16884lt_prog_compiler_pic=
16885lt_prog_compiler_static=
16886
16887echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5
16888echo $ECHO_N "checking for $compiler option to produce PIC... $ECHO_C" >&6
16889
16890 if test "$GCC" = yes; then
16891 lt_prog_compiler_wl='-Wl,'
16892 lt_prog_compiler_static='-static'
16893
16894 case $host_os in
16895 aix*)
16896 # All AIX code is PIC.
16897 if test "$host_cpu" = ia64; then
16898 # AIX 5 now supports IA64 processor
16899 lt_prog_compiler_static='-Bstatic'
16900 fi
16901 ;;
16902
16903 amigaos*)
5d47bb02
PG
16904 case $host_cpu in
16905 powerpc)
16906 # see comment about AmigaOS4 .so support
16907 lt_prog_compiler_pic='-fPIC'
16908 ;;
16909 m68k)
16910 # FIXME: we need at least 68020 code to build shared libraries, but
16911 # adding the `-m68020' flag to GCC prevents building anything better,
16912 # like `-m68040'.
16913 lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4'
16914 ;;
16915 esac
da0f6381
PB
16916 ;;
16917
16918 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
16919 # PIC is the default for these OSes.
16920 ;;
16921
5d47bb02 16922 mingw* | cygwin* | pw32* | os2* | cegcc*)
da0f6381
PB
16923 # This hack is so that the source file can tell whether it is being
16924 # built for inclusion in a dll (and should export symbols for example).
16925 # Although the cygwin gcc ignores -fPIC, still need this for old-style
16926 # (--disable-auto-import) libraries
16927 lt_prog_compiler_pic='-DDLL_EXPORT'
16928 ;;
16929
16930 darwin* | rhapsody*)
16931 # PIC is the default on this platform
16932 # Common symbols not allowed in MH_DYLIB files
16933 lt_prog_compiler_pic='-fno-common'
16934 ;;
16935
16936 hpux*)
5d47bb02
PG
16937 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
16938 # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
16939 # sets the default TLS model and affects inlining.
da0f6381 16940 case $host_cpu in
5d47bb02 16941 hppa*64*)
da0f6381
PB
16942 # +Z the default
16943 ;;
16944 *)
16945 lt_prog_compiler_pic='-fPIC'
16946 ;;
16947 esac
16948 ;;
16949
16950 interix[3-9]*)
16951 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
16952 # Instead, we relocate shared libraries at runtime.
16953 ;;
16954
16955 msdosdjgpp*)
16956 # Just because we use GCC doesn't mean we suddenly get shared libraries
16957 # on systems that don't support them.
16958 lt_prog_compiler_can_build_shared=no
16959 enable_shared=no
16960 ;;
16961
16962 *nto* | *qnx*)
16963 # QNX uses GNU C++, but need to define -shared option too, otherwise
16964 # it will coredump.
16965 lt_prog_compiler_pic='-fPIC -shared'
16966 ;;
16967
16968 sysv4*MP*)
16969 if test -d /usr/nec; then
16970 lt_prog_compiler_pic=-Kconform_pic
16971 fi
16972 ;;
16973
16974 *)
16975 lt_prog_compiler_pic='-fPIC'
16976 ;;
16977 esac
16978 else
16979 # PORTME Check for flag to pass linker flags through the system compiler.
16980 case $host_os in
16981 aix*)
16982 lt_prog_compiler_wl='-Wl,'
16983 if test "$host_cpu" = ia64; then
16984 # AIX 5 now supports IA64 processor
16985 lt_prog_compiler_static='-Bstatic'
16986 else
16987 lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp'
16988 fi
16989 ;;
da0f6381 16990
5d47bb02 16991 mingw* | cygwin* | pw32* | os2* | cegcc*)
da0f6381
PB
16992 # This hack is so that the source file can tell whether it is being
16993 # built for inclusion in a dll (and should export symbols for example).
16994 lt_prog_compiler_pic='-DDLL_EXPORT'
16995 ;;
16996
16997 hpux9* | hpux10* | hpux11*)
16998 lt_prog_compiler_wl='-Wl,'
16999 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
17000 # not for PA HP-UX.
17001 case $host_cpu in
17002 hppa*64*|ia64*)
17003 # +Z the default
17004 ;;
17005 *)
17006 lt_prog_compiler_pic='+Z'
17007 ;;
17008 esac
17009 # Is there a better lt_prog_compiler_static that works with the bundled CC?
17010 lt_prog_compiler_static='${wl}-a ${wl}archive'
17011 ;;
17012
17013 irix5* | irix6* | nonstopux*)
17014 lt_prog_compiler_wl='-Wl,'
17015 # PIC (with -KPIC) is the default.
17016 lt_prog_compiler_static='-non_shared'
17017 ;;
17018
7a9d3fe8 17019 linux* | k*bsd*-gnu | kopensolaris*-gnu)
da0f6381 17020 case $cc_basename in
5d47bb02
PG
17021 # old Intel for x86_64 which still supported -KPIC.
17022 ecc*)
da0f6381
PB
17023 lt_prog_compiler_wl='-Wl,'
17024 lt_prog_compiler_pic='-KPIC'
17025 lt_prog_compiler_static='-static'
17026 ;;
5d47bb02
PG
17027 # icc used to be incompatible with GCC.
17028 # ICC 10 doesn't accept -KPIC any more.
17029 icc* | ifort*)
17030 lt_prog_compiler_wl='-Wl,'
17031 lt_prog_compiler_pic='-fPIC'
17032 lt_prog_compiler_static='-static'
17033 ;;
17034 # Lahey Fortran 8.1.
17035 lf95*)
17036 lt_prog_compiler_wl='-Wl,'
17037 lt_prog_compiler_pic='--shared'
17038 lt_prog_compiler_static='--static'
17039 ;;
da0f6381
PB
17040 pgcc* | pgf77* | pgf90* | pgf95*)
17041 # Portland Group compilers (*not* the Pentium gcc compiler,
17042 # which looks to be a dead project)
17043 lt_prog_compiler_wl='-Wl,'
17044 lt_prog_compiler_pic='-fpic'
17045 lt_prog_compiler_static='-Bstatic'
17046 ;;
17047 ccc*)
17048 lt_prog_compiler_wl='-Wl,'
17049 # All Alpha code is PIC.
17050 lt_prog_compiler_static='-non_shared'
17051 ;;
5d47bb02
PG
17052 xl*)
17053 # IBM XL C 8.0/Fortran 10.1 on PPC
17054 lt_prog_compiler_wl='-Wl,'
17055 lt_prog_compiler_pic='-qpic'
17056 lt_prog_compiler_static='-qstaticlink'
17057 ;;
da0f6381
PB
17058 *)
17059 case `$CC -V 2>&1 | sed 5q` in
17060 *Sun\ C*)
17061 # Sun C 5.9
17062 lt_prog_compiler_pic='-KPIC'
17063 lt_prog_compiler_static='-Bstatic'
17064 lt_prog_compiler_wl='-Wl,'
17065 ;;
17066 *Sun\ F*)
17067 # Sun Fortran 8.3 passes all unrecognized flags to the linker
17068 lt_prog_compiler_pic='-KPIC'
17069 lt_prog_compiler_static='-Bstatic'
17070 lt_prog_compiler_wl=''
17071 ;;
17072 esac
17073 ;;
17074 esac
17075 ;;
17076
17077 newsos6)
17078 lt_prog_compiler_pic='-KPIC'
17079 lt_prog_compiler_static='-Bstatic'
17080 ;;
17081
17082 *nto* | *qnx*)
17083 # QNX uses GNU C++, but need to define -shared option too, otherwise
17084 # it will coredump.
17085 lt_prog_compiler_pic='-fPIC -shared'
17086 ;;
17087
17088 osf3* | osf4* | osf5*)
17089 lt_prog_compiler_wl='-Wl,'
17090 # All OSF/1 code is PIC.
17091 lt_prog_compiler_static='-non_shared'
17092 ;;
17093
17094 rdos*)
17095 lt_prog_compiler_static='-non_shared'
17096 ;;
17097
17098 solaris*)
17099 lt_prog_compiler_pic='-KPIC'
17100 lt_prog_compiler_static='-Bstatic'
17101 case $cc_basename in
17102 f77* | f90* | f95*)
17103 lt_prog_compiler_wl='-Qoption ld ';;
17104 *)
17105 lt_prog_compiler_wl='-Wl,';;
17106 esac
17107 ;;
17108
17109 sunos4*)
17110 lt_prog_compiler_wl='-Qoption ld '
17111 lt_prog_compiler_pic='-PIC'
17112 lt_prog_compiler_static='-Bstatic'
17113 ;;
17114
17115 sysv4 | sysv4.2uw2* | sysv4.3*)
17116 lt_prog_compiler_wl='-Wl,'
17117 lt_prog_compiler_pic='-KPIC'
17118 lt_prog_compiler_static='-Bstatic'
17119 ;;
17120
17121 sysv4*MP*)
17122 if test -d /usr/nec ;then
17123 lt_prog_compiler_pic='-Kconform_pic'
17124 lt_prog_compiler_static='-Bstatic'
17125 fi
17126 ;;
17127
17128 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
17129 lt_prog_compiler_wl='-Wl,'
17130 lt_prog_compiler_pic='-KPIC'
17131 lt_prog_compiler_static='-Bstatic'
17132 ;;
17133
17134 unicos*)
17135 lt_prog_compiler_wl='-Wl,'
17136 lt_prog_compiler_can_build_shared=no
17137 ;;
17138
17139 uts4*)
17140 lt_prog_compiler_pic='-pic'
17141 lt_prog_compiler_static='-Bstatic'
17142 ;;
17143
17144 *)
17145 lt_prog_compiler_can_build_shared=no
17146 ;;
17147 esac
17148 fi
17149
17150case $host_os in
17151 # For platforms which do not support PIC, -DPIC is meaningless:
17152 *djgpp*)
17153 lt_prog_compiler_pic=
17154 ;;
17155 *)
17156 lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
17157 ;;
17158esac
17159echo "$as_me:$LINENO: result: $lt_prog_compiler_pic" >&5
17160echo "${ECHO_T}$lt_prog_compiler_pic" >&6
17161
17162
17163
17164
17165
17166
17167#
17168# Check to make sure the PIC flag actually works.
17169#
17170if test -n "$lt_prog_compiler_pic"; then
17171 echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
17172echo $ECHO_N "checking if $compiler PIC flag $lt_prog_compiler_pic works... $ECHO_C" >&6
5d47bb02 17173if test "${lt_cv_prog_compiler_pic_works+set}" = set; then
da0f6381
PB
17174 echo $ECHO_N "(cached) $ECHO_C" >&6
17175else
5d47bb02 17176 lt_cv_prog_compiler_pic_works=no
da0f6381
PB
17177 ac_outfile=conftest.$ac_objext
17178 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
17179 lt_compiler_flag="$lt_prog_compiler_pic -DPIC"
17180 # Insert the option either (1) after the last *FLAGS variable, or
17181 # (2) before a word containing "conftest.", or (3) at the end.
17182 # Note that $ac_compile itself does not contain backslashes and begins
17183 # with a dollar sign (not a hyphen), so the echo should work correctly.
17184 # The option is referenced via a variable to avoid confusing sed.
17185 lt_compile=`echo "$ac_compile" | $SED \
17186 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
17187 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
17188 -e 's:$: $lt_compiler_flag:'`
cd533689 17189 (eval echo "\"\$as_me:17189: $lt_compile\"" >&5)
da0f6381
PB
17190 (eval "$lt_compile" 2>conftest.err)
17191 ac_status=$?
17192 cat conftest.err >&5
cd533689 17193 echo "$as_me:17193: \$? = $ac_status" >&5
da0f6381
PB
17194 if (exit $ac_status) && test -s "$ac_outfile"; then
17195 # The compiler can only warn and ignore the option if not recognized
17196 # So say no if there are warnings other than the usual output.
17197 $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
17198 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
17199 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
5d47bb02 17200 lt_cv_prog_compiler_pic_works=yes
da0f6381
PB
17201 fi
17202 fi
17203 $RM conftest*
17204
17205fi
5d47bb02
PG
17206echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_pic_works" >&5
17207echo "${ECHO_T}$lt_cv_prog_compiler_pic_works" >&6
da0f6381 17208
5d47bb02 17209if test x"$lt_cv_prog_compiler_pic_works" = xyes; then
da0f6381
PB
17210 case $lt_prog_compiler_pic in
17211 "" | " "*) ;;
17212 *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;;
17213 esac
17214else
17215 lt_prog_compiler_pic=
17216 lt_prog_compiler_can_build_shared=no
17217fi
17218
17219fi
17220
17221
17222
17223
17224
17225
17226#
17227# Check to make sure the static flag actually works.
17228#
17229wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\"
17230echo "$as_me:$LINENO: checking if $compiler static flag $lt_tmp_static_flag works" >&5
17231echo $ECHO_N "checking if $compiler static flag $lt_tmp_static_flag works... $ECHO_C" >&6
5d47bb02 17232if test "${lt_cv_prog_compiler_static_works+set}" = set; then
da0f6381
PB
17233 echo $ECHO_N "(cached) $ECHO_C" >&6
17234else
5d47bb02 17235 lt_cv_prog_compiler_static_works=no
da0f6381
PB
17236 save_LDFLAGS="$LDFLAGS"
17237 LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
17238 echo "$lt_simple_link_test_code" > conftest.$ac_ext
17239 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
17240 # The linker can only warn and ignore the option if not recognized
17241 # So say no if there are warnings
17242 if test -s conftest.err; then
17243 # Append any errors to the config.log.
17244 cat conftest.err 1>&5
17245 $ECHO "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp
17246 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
17247 if diff conftest.exp conftest.er2 >/dev/null; then
5d47bb02 17248 lt_cv_prog_compiler_static_works=yes
da0f6381
PB
17249 fi
17250 else
5d47bb02 17251 lt_cv_prog_compiler_static_works=yes
da0f6381
PB
17252 fi
17253 fi
5d47bb02 17254 $RM -r conftest*
da0f6381
PB
17255 LDFLAGS="$save_LDFLAGS"
17256
17257fi
5d47bb02
PG
17258echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_static_works" >&5
17259echo "${ECHO_T}$lt_cv_prog_compiler_static_works" >&6
da0f6381 17260
5d47bb02 17261if test x"$lt_cv_prog_compiler_static_works" = xyes; then
da0f6381
PB
17262 :
17263else
17264 lt_prog_compiler_static=
17265fi
17266
17267
17268
17269
17270
17271
17272
17273 echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5
17274echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6
17275if test "${lt_cv_prog_compiler_c_o+set}" = set; then
17276 echo $ECHO_N "(cached) $ECHO_C" >&6
17277else
17278 lt_cv_prog_compiler_c_o=no
17279 $RM -r conftest 2>/dev/null
17280 mkdir conftest
17281 cd conftest
17282 mkdir out
17283 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
17284
17285 lt_compiler_flag="-o out/conftest2.$ac_objext"
17286 # Insert the option either (1) after the last *FLAGS variable, or
17287 # (2) before a word containing "conftest.", or (3) at the end.
17288 # Note that $ac_compile itself does not contain backslashes and begins
17289 # with a dollar sign (not a hyphen), so the echo should work correctly.
17290 lt_compile=`echo "$ac_compile" | $SED \
17291 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
17292 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
17293 -e 's:$: $lt_compiler_flag:'`
cd533689 17294 (eval echo "\"\$as_me:17294: $lt_compile\"" >&5)
da0f6381
PB
17295 (eval "$lt_compile" 2>out/conftest.err)
17296 ac_status=$?
17297 cat out/conftest.err >&5
cd533689 17298 echo "$as_me:17298: \$? = $ac_status" >&5
da0f6381
PB
17299 if (exit $ac_status) && test -s out/conftest2.$ac_objext
17300 then
17301 # The compiler can only warn and ignore the option if not recognized
17302 # So say no if there are warnings
17303 $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
17304 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
17305 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
17306 lt_cv_prog_compiler_c_o=yes
17307 fi
17308 fi
17309 chmod u+w . 2>&5
17310 $RM conftest*
17311 # SGI C++ compiler will create directory out/ii_files/ for
17312 # template instantiation
17313 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
17314 $RM out/* && rmdir out
17315 cd ..
17316 $RM -r conftest
17317 $RM conftest*
17318
17319fi
17320echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o" >&5
17321echo "${ECHO_T}$lt_cv_prog_compiler_c_o" >&6
17322
17323
17324
17325
17326
17327
17328 echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5
17329echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6
17330if test "${lt_cv_prog_compiler_c_o+set}" = set; then
17331 echo $ECHO_N "(cached) $ECHO_C" >&6
17332else
17333 lt_cv_prog_compiler_c_o=no
17334 $RM -r conftest 2>/dev/null
17335 mkdir conftest
17336 cd conftest
17337 mkdir out
17338 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
17339
17340 lt_compiler_flag="-o out/conftest2.$ac_objext"
17341 # Insert the option either (1) after the last *FLAGS variable, or
17342 # (2) before a word containing "conftest.", or (3) at the end.
17343 # Note that $ac_compile itself does not contain backslashes and begins
17344 # with a dollar sign (not a hyphen), so the echo should work correctly.
17345 lt_compile=`echo "$ac_compile" | $SED \
17346 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
17347 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
17348 -e 's:$: $lt_compiler_flag:'`
cd533689 17349 (eval echo "\"\$as_me:17349: $lt_compile\"" >&5)
da0f6381
PB
17350 (eval "$lt_compile" 2>out/conftest.err)
17351 ac_status=$?
17352 cat out/conftest.err >&5
cd533689 17353 echo "$as_me:17353: \$? = $ac_status" >&5
da0f6381
PB
17354 if (exit $ac_status) && test -s out/conftest2.$ac_objext
17355 then
17356 # The compiler can only warn and ignore the option if not recognized
17357 # So say no if there are warnings
17358 $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
17359 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
17360 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
17361 lt_cv_prog_compiler_c_o=yes
17362 fi
17363 fi
17364 chmod u+w . 2>&5
17365 $RM conftest*
17366 # SGI C++ compiler will create directory out/ii_files/ for
17367 # template instantiation
17368 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
17369 $RM out/* && rmdir out
17370 cd ..
17371 $RM -r conftest
17372 $RM conftest*
17373
17374fi
17375echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o" >&5
17376echo "${ECHO_T}$lt_cv_prog_compiler_c_o" >&6
17377
17378
17379
17380
17381hard_links="nottested"
17382if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then
17383 # do not overwrite the value of need_locks provided by the user
17384 echo "$as_me:$LINENO: checking if we can lock with hard links" >&5
17385echo $ECHO_N "checking if we can lock with hard links... $ECHO_C" >&6
17386 hard_links=yes
17387 $RM conftest*
17388 ln conftest.a conftest.b 2>/dev/null && hard_links=no
17389 touch conftest.a
17390 ln conftest.a conftest.b 2>&5 || hard_links=no
17391 ln conftest.a conftest.b 2>/dev/null && hard_links=no
17392 echo "$as_me:$LINENO: result: $hard_links" >&5
17393echo "${ECHO_T}$hard_links" >&6
17394 if test "$hard_links" = no; then
17395 { echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
17396echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
17397 need_locks=warn
17398 fi
17399else
17400 need_locks=no
17401fi
17402
17403
17404
17405
17406
17407
17408 echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5
17409echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6
17410
17411 runpath_var=
17412 allow_undefined_flag=
17413 always_export_symbols=no
17414 archive_cmds=
17415 archive_expsym_cmds=
17416 compiler_needs_object=no
17417 enable_shared_with_static_runtimes=no
17418 export_dynamic_flag_spec=
17419 export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
17420 hardcode_automatic=no
17421 hardcode_direct=no
17422 hardcode_direct_absolute=no
17423 hardcode_libdir_flag_spec=
17424 hardcode_libdir_flag_spec_ld=
17425 hardcode_libdir_separator=
17426 hardcode_minus_L=no
17427 hardcode_shlibpath_var=unsupported
17428 inherit_rpath=no
17429 link_all_deplibs=unknown
17430 module_cmds=
17431 module_expsym_cmds=
17432 old_archive_from_new_cmds=
17433 old_archive_from_expsyms_cmds=
17434 thread_safe_flag_spec=
17435 whole_archive_flag_spec=
17436 # include_expsyms should be a list of space-separated symbols to be *always*
17437 # included in the symbol list
17438 include_expsyms=
17439 # exclude_expsyms can be an extended regexp of symbols to exclude
17440 # it will be wrapped by ` (' and `)$', so one must not match beginning or
17441 # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
17442 # as well as any symbol that contains `d'.
5d47bb02 17443 exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
da0f6381
PB
17444 # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
17445 # platforms (ab)use it in PIC code, but their linkers get confused if
17446 # the symbol is explicitly referenced. Since portable code cannot
17447 # rely on this symbol name, it's probably fine to never include it in
17448 # preloaded symbol tables.
5d47bb02 17449 # Exclude shared library initialization/finalization symbols.
da0f6381
PB
17450 extract_expsyms_cmds=
17451
17452 case $host_os in
5d47bb02 17453 cygwin* | mingw* | pw32* | cegcc*)
da0f6381
PB
17454 # FIXME: the MSVC++ port hasn't been tested in a loooong time
17455 # When not using gcc, we currently assume that we are using
17456 # Microsoft Visual C++.
17457 if test "$GCC" != yes; then
17458 with_gnu_ld=no
17459 fi
17460 ;;
17461 interix*)
17462 # we just hope/assume this is gcc and not c89 (= MSVC++)
17463 with_gnu_ld=yes
17464 ;;
17465 openbsd*)
17466 with_gnu_ld=no
17467 ;;
17468 esac
17469
17470 ld_shlibs=yes
17471 if test "$with_gnu_ld" = yes; then
17472 # If archive_cmds runs LD, not CC, wlarc should be empty
17473 wlarc='${wl}'
17474
17475 # Set some defaults for GNU ld with shared library support. These
17476 # are reset later if shared libraries are not supported. Putting them
17477 # here allows them to be overridden if necessary.
17478 runpath_var=LD_RUN_PATH
17479 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
17480 export_dynamic_flag_spec='${wl}--export-dynamic'
17481 # ancient GNU ld didn't support --whole-archive et. al.
17482 if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
17483 whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
17484 else
17485 whole_archive_flag_spec=
17486 fi
17487 supports_anon_versioning=no
17488 case `$LD -v 2>&1` in
17489 *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
17490 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
17491 *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
17492 *\ 2.11.*) ;; # other 2.11 versions
17493 *) supports_anon_versioning=yes ;;
17494 esac
17495
17496 # See if GNU ld supports shared libraries.
17497 case $host_os in
17498 aix[3-9]*)
17499 # On AIX/PPC, the GNU linker is very broken
17500 if test "$host_cpu" != ia64; then
17501 ld_shlibs=no
17502 cat <<_LT_EOF 1>&2
17503
17504*** Warning: the GNU linker, at least up to release 2.9.1, is reported
17505*** to be unable to reliably create shared libraries on AIX.
17506*** Therefore, libtool is disabling shared libraries support. If you
17507*** really care for shared libraries, you may want to modify your PATH
17508*** so that a non-GNU linker is found, and then restart.
17509
17510_LT_EOF
17511 fi
17512 ;;
17513
17514 amigaos*)
5d47bb02
PG
17515 case $host_cpu in
17516 powerpc)
17517 # see comment about AmigaOS4 .so support
17518 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
17519 archive_expsym_cmds=''
17520 ;;
17521 m68k)
17522 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)'
17523 hardcode_libdir_flag_spec='-L$libdir'
17524 hardcode_minus_L=yes
17525 ;;
17526 esac
da0f6381
PB
17527 ;;
17528
17529 beos*)
17530 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
17531 allow_undefined_flag=unsupported
17532 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
17533 # support --undefined. This deserves some investigation. FIXME
17534 archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
17535 else
17536 ld_shlibs=no
17537 fi
17538 ;;
17539
5d47bb02 17540 cygwin* | mingw* | pw32* | cegcc*)
da0f6381
PB
17541 # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless,
17542 # as there is no search path for DLLs.
17543 hardcode_libdir_flag_spec='-L$libdir'
17544 allow_undefined_flag=unsupported
17545 always_export_symbols=no
17546 enable_shared_with_static_runtimes=yes
17547 export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
17548
17549 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
17550 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
17551 # If the export-symbols file already is a .def file (1st line
17552 # is EXPORTS), use it as is; otherwise, prepend...
17553 archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
17554 cp $export_symbols $output_objdir/$soname.def;
17555 else
17556 echo EXPORTS > $output_objdir/$soname.def;
17557 cat $export_symbols >> $output_objdir/$soname.def;
17558 fi~
17559 $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
17560 else
17561 ld_shlibs=no
17562 fi
17563 ;;
17564
17565 interix[3-9]*)
17566 hardcode_direct=no
17567 hardcode_shlibpath_var=no
17568 hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
17569 export_dynamic_flag_spec='${wl}-E'
17570 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
17571 # Instead, shared libraries are loaded at an image base (0x10000000 by
17572 # default) and relocated if they conflict, which is a slow very memory
17573 # consuming and fragmenting process. To avoid this, we pick a random,
17574 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
17575 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
17576 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
17577 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'
17578 ;;
17579
7a9d3fe8 17580 gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
da0f6381
PB
17581 tmp_diet=no
17582 if test "$host_os" = linux-dietlibc; then
17583 case $cc_basename in
17584 diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn)
17585 esac
17586 fi
17587 if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
17588 && test "$tmp_diet" = no
17589 then
17590 tmp_addflag=
5d47bb02 17591 tmp_sharedflag='-shared'
da0f6381
PB
17592 case $cc_basename,$host_cpu in
17593 pgcc*) # Portland Group C compiler
17594 whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
17595 tmp_addflag=' $pic_flag'
17596 ;;
17597 pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers
17598 whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
17599 tmp_addflag=' $pic_flag -Mnomain' ;;
17600 ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
17601 tmp_addflag=' -i_dynamic' ;;
17602 efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
17603 tmp_addflag=' -i_dynamic -nofor_main' ;;
17604 ifc* | ifort*) # Intel Fortran compiler
17605 tmp_addflag=' -nofor_main' ;;
5d47bb02
PG
17606 lf95*) # Lahey Fortran 8.1
17607 whole_archive_flag_spec=
17608 tmp_sharedflag='--shared' ;;
17609 xl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below)
17610 tmp_sharedflag='-qmkshrobj'
17611 tmp_addflag= ;;
da0f6381
PB
17612 esac
17613 case `$CC -V 2>&1 | sed 5q` in
17614 *Sun\ C*) # Sun C 5.9
17615 whole_archive_flag_spec='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
17616 compiler_needs_object=yes
17617 tmp_sharedflag='-G' ;;
17618 *Sun\ F*) # Sun Fortran 8.3
17619 tmp_sharedflag='-G' ;;
da0f6381
PB
17620 esac
17621 archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
17622
17623 if test "x$supports_anon_versioning" = xyes; then
17624 archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
17625 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
17626 echo "local: *; };" >> $output_objdir/$libname.ver~
17627 $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
17628 fi
5d47bb02
PG
17629
17630 case $cc_basename in
17631 xlf*)
17632 # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
17633 whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
17634 hardcode_libdir_flag_spec=
17635 hardcode_libdir_flag_spec_ld='-rpath $libdir'
17636 archive_cmds='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib'
17637 if test "x$supports_anon_versioning" = xyes; then
17638 archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
17639 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
17640 echo "local: *; };" >> $output_objdir/$libname.ver~
17641 $LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
17642 fi
17643 ;;
17644 esac
da0f6381
PB
17645 else
17646 ld_shlibs=no
17647 fi
17648 ;;
17649
17650 netbsd*)
17651 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
17652 archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
17653 wlarc=
17654 else
17655 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
17656 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
17657 fi
17658 ;;
17659
17660 solaris*)
17661 if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
17662 ld_shlibs=no
17663 cat <<_LT_EOF 1>&2
17664
17665*** Warning: The releases 2.8.* of the GNU linker cannot reliably
17666*** create shared libraries on Solaris systems. Therefore, libtool
17667*** is disabling shared libraries support. We urge you to upgrade GNU
17668*** binutils to release 2.9.1 or newer. Another option is to modify
17669*** your PATH or compiler configuration so that the native linker is
17670*** used, and then restart.
17671
17672_LT_EOF
17673 elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
17674 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
17675 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
17676 else
17677 ld_shlibs=no
17678 fi
17679 ;;
17680
17681 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
17682 case `$LD -v 2>&1` in
17683 *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*)
17684 ld_shlibs=no
17685 cat <<_LT_EOF 1>&2
17686
17687*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
17688*** reliably create shared libraries on SCO systems. Therefore, libtool
17689*** is disabling shared libraries support. We urge you to upgrade GNU
17690*** binutils to release 2.16.91.0.3 or newer. Another option is to modify
17691*** your PATH or compiler configuration so that the native linker is
17692*** used, and then restart.
17693
17694_LT_EOF
17695 ;;
17696 *)
17697 # For security reasons, it is highly recommended that you always
17698 # use absolute paths for naming shared libraries, and exclude the
17699 # DT_RUNPATH tag from executables and libraries. But doing so
17700 # requires that you compile everything twice, which is a pain.
17701 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
17702 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
17703 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
17704 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
17705 else
17706 ld_shlibs=no
17707 fi
17708 ;;
17709 esac
17710 ;;
17711
17712 sunos4*)
17713 archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
17714 wlarc=
17715 hardcode_direct=yes
17716 hardcode_shlibpath_var=no
17717 ;;
17718
17719 *)
17720 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
17721 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
17722 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
17723 else
17724 ld_shlibs=no
17725 fi
17726 ;;
17727 esac
17728
17729 if test "$ld_shlibs" = no; then
17730 runpath_var=
17731 hardcode_libdir_flag_spec=
17732 export_dynamic_flag_spec=
17733 whole_archive_flag_spec=
17734 fi
17735 else
17736 # PORTME fill in a description of your system's linker (not GNU ld)
17737 case $host_os in
17738 aix3*)
17739 allow_undefined_flag=unsupported
17740 always_export_symbols=yes
17741 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'
17742 # Note: this linker hardcodes the directories in LIBPATH if there
17743 # are no directories specified by -L.
17744 hardcode_minus_L=yes
17745 if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
17746 # Neither direct hardcoding nor static linking is supported with a
17747 # broken collect2.
17748 hardcode_direct=unsupported
17749 fi
17750 ;;
17751
17752 aix[4-9]*)
17753 if test "$host_cpu" = ia64; then
17754 # On IA64, the linker does run time linking by default, so we don't
17755 # have to do anything special.
17756 aix_use_runtimelinking=no
17757 exp_sym_flag='-Bexport'
17758 no_entry_flag=""
17759 else
17760 # If we're using GNU nm, then we don't want the "-C" option.
17761 # -C means demangle to AIX nm, but means don't demangle with GNU nm
17762 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
17763 export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
17764 else
17765 export_symbols_cmds='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
17766 fi
17767 aix_use_runtimelinking=no
17768
17769 # Test if we are trying to use run time linking or normal
17770 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
17771 # need to do runtime linking.
17772 case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
17773 for ld_flag in $LDFLAGS; do
17774 if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
17775 aix_use_runtimelinking=yes
17776 break
17777 fi
17778 done
17779 ;;
17780 esac
17781
17782 exp_sym_flag='-bexport'
17783 no_entry_flag='-bnoentry'
17784 fi
17785
17786 # When large executables or shared objects are built, AIX ld can
17787 # have problems creating the table of contents. If linking a library
17788 # or program results in "error TOC overflow" add -mminimal-toc to
17789 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
17790 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
17791
17792 archive_cmds=''
17793 hardcode_direct=yes
17794 hardcode_direct_absolute=yes
17795 hardcode_libdir_separator=':'
17796 link_all_deplibs=yes
17797 file_list_spec='${wl}-f,'
17798
17799 if test "$GCC" = yes; then
17800 case $host_os in aix4.[012]|aix4.[012].*)
17801 # We only want to do this on AIX 4.2 and lower, the check
17802 # below for broken collect2 doesn't work under 4.3+
17803 collect2name=`${CC} -print-prog-name=collect2`
17804 if test -f "$collect2name" &&
17805 strings "$collect2name" | $GREP resolve_lib_name >/dev/null
17806 then
17807 # We have reworked collect2
17808 :
17809 else
17810 # We have old collect2
17811 hardcode_direct=unsupported
17812 # It fails to find uninstalled libraries when the uninstalled
17813 # path is not listed in the libpath. Setting hardcode_minus_L
17814 # to unsupported forces relinking
17815 hardcode_minus_L=yes
17816 hardcode_libdir_flag_spec='-L$libdir'
17817 hardcode_libdir_separator=
17818 fi
17819 ;;
17820 esac
17821 shared_flag='-shared'
17822 if test "$aix_use_runtimelinking" = yes; then
17823 shared_flag="$shared_flag "'${wl}-G'
17824 fi
17825 else
17826 # not using gcc
17827 if test "$host_cpu" = ia64; then
17828 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
17829 # chokes on -Wl,-G. The following line is correct:
17830 shared_flag='-G'
17831 else
17832 if test "$aix_use_runtimelinking" = yes; then
17833 shared_flag='${wl}-G'
17834 else
17835 shared_flag='${wl}-bM:SRE'
17836 fi
17837 fi
17838 fi
17839
5d47bb02 17840 export_dynamic_flag_spec='${wl}-bexpall'
da0f6381
PB
17841 # It seems that -bexpall does not export symbols beginning with
17842 # underscore (_), so it is better to generate a list of symbols to export.
17843 always_export_symbols=yes
17844 if test "$aix_use_runtimelinking" = yes; then
17845 # Warning - without using the other runtime loading flags (-brtl),
17846 # -berok will link without error, but may produce a broken library.
17847 allow_undefined_flag='-berok'
17848 # Determine the default libpath from the value encoded in an
17849 # empty executable.
17850 cat >conftest.$ac_ext <<_ACEOF
17851/* confdefs.h. */
17852_ACEOF
17853cat confdefs.h >>conftest.$ac_ext
17854cat >>conftest.$ac_ext <<_ACEOF
17855/* end confdefs.h. */
17856
17857int
17858main ()
17859{
17860
17861 ;
17862 return 0;
17863}
17864_ACEOF
17865rm -f conftest.$ac_objext conftest$ac_exeext
17866if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17867 (eval $ac_link) 2>conftest.er1
17868 ac_status=$?
17869 grep -v '^ *+' conftest.er1 >conftest.err
17870 rm -f conftest.er1
17871 cat conftest.err >&5
17872 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17873 (exit $ac_status); } &&
17874 { ac_try='test -z "$ac_c_werror_flag"
17875 || test ! -s conftest.err'
17876 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17877 (eval $ac_try) 2>&5
17878 ac_status=$?
17879 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17880 (exit $ac_status); }; } &&
17881 { ac_try='test -s conftest$ac_exeext'
17882 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17883 (eval $ac_try) 2>&5
17884 ac_status=$?
17885 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17886 (exit $ac_status); }; }; then
17887
17888lt_aix_libpath_sed='
17889 /Import File Strings/,/^$/ {
17890 /^0/ {
17891 s/^0 *\(.*\)$/\1/
17892 p
17893 }
17894 }'
17895aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
17896# Check for a 64-bit object if we didn't find anything.
17897if test -z "$aix_libpath"; then
17898 aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
17899fi
17900else
17901 echo "$as_me: failed program was:" >&5
17902sed 's/^/| /' conftest.$ac_ext >&5
17903
17904fi
17905rm -f conftest.err conftest.$ac_objext \
17906 conftest$ac_exeext conftest.$ac_ext
17907if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
17908
17909 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
17910 archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then $ECHO "X${wl}${allow_undefined_flag}" | $Xsed; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
17911 else
17912 if test "$host_cpu" = ia64; then
17913 hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
17914 allow_undefined_flag="-z nodefs"
17915 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"
17916 else
17917 # Determine the default libpath from the value encoded in an
17918 # empty executable.
17919 cat >conftest.$ac_ext <<_ACEOF
17920/* confdefs.h. */
17921_ACEOF
17922cat confdefs.h >>conftest.$ac_ext
17923cat >>conftest.$ac_ext <<_ACEOF
17924/* end confdefs.h. */
17925
17926int
17927main ()
17928{
17929
17930 ;
17931 return 0;
17932}
17933_ACEOF
17934rm -f conftest.$ac_objext conftest$ac_exeext
17935if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17936 (eval $ac_link) 2>conftest.er1
17937 ac_status=$?
17938 grep -v '^ *+' conftest.er1 >conftest.err
17939 rm -f conftest.er1
17940 cat conftest.err >&5
17941 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17942 (exit $ac_status); } &&
17943 { ac_try='test -z "$ac_c_werror_flag"
17944 || test ! -s conftest.err'
17945 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17946 (eval $ac_try) 2>&5
17947 ac_status=$?
17948 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17949 (exit $ac_status); }; } &&
17950 { ac_try='test -s conftest$ac_exeext'
17951 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17952 (eval $ac_try) 2>&5
17953 ac_status=$?
17954 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17955 (exit $ac_status); }; }; then
17956
17957lt_aix_libpath_sed='
17958 /Import File Strings/,/^$/ {
17959 /^0/ {
17960 s/^0 *\(.*\)$/\1/
17961 p
17962 }
17963 }'
17964aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
17965# Check for a 64-bit object if we didn't find anything.
17966if test -z "$aix_libpath"; then
17967 aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
17968fi
17969else
17970 echo "$as_me: failed program was:" >&5
17971sed 's/^/| /' conftest.$ac_ext >&5
17972
17973fi
17974rm -f conftest.err conftest.$ac_objext \
17975 conftest$ac_exeext conftest.$ac_ext
17976if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
17977
17978 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
17979 # Warning - without using the other run time loading flags,
17980 # -berok will link without error, but may produce a broken library.
17981 no_undefined_flag=' ${wl}-bernotok'
17982 allow_undefined_flag=' ${wl}-berok'
17983 # Exported symbols can be pulled into shared objects from archives
17984 whole_archive_flag_spec='$convenience'
17985 archive_cmds_need_lc=yes
17986 # This is similar to how AIX traditionally builds its shared libraries.
17987 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'
17988 fi
17989 fi
17990 ;;
17991
17992 amigaos*)
5d47bb02
PG
17993 case $host_cpu in
17994 powerpc)
17995 # see comment about AmigaOS4 .so support
17996 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
17997 archive_expsym_cmds=''
17998 ;;
17999 m68k)
18000 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)'
18001 hardcode_libdir_flag_spec='-L$libdir'
18002 hardcode_minus_L=yes
18003 ;;
18004 esac
da0f6381
PB
18005 ;;
18006
18007 bsdi[45]*)
18008 export_dynamic_flag_spec=-rdynamic
18009 ;;
18010
5d47bb02 18011 cygwin* | mingw* | pw32* | cegcc*)
da0f6381
PB
18012 # When not using gcc, we currently assume that we are using
18013 # Microsoft Visual C++.
18014 # hardcode_libdir_flag_spec is actually meaningless, as there is
18015 # no search path for DLLs.
18016 hardcode_libdir_flag_spec=' '
18017 allow_undefined_flag=unsupported
18018 # Tell ltmain to make .lib files, not .a files.
18019 libext=lib
18020 # Tell ltmain to make .dll files, not .so files.
18021 shrext_cmds=".dll"
18022 # FIXME: Setting linknames here is a bad hack.
18023 archive_cmds='$CC -o $lib $libobjs $compiler_flags `$ECHO "X$deplibs" | $Xsed -e '\''s/ -lc$//'\''` -link -dll~linknames='
18024 # The linker will automatically build a .lib file if we build a DLL.
18025 old_archive_from_new_cmds='true'
18026 # FIXME: Should let the user specify the lib program.
18027 old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
18028 fix_srcfile_path='`cygpath -w "$srcfile"`'
18029 enable_shared_with_static_runtimes=yes
18030 ;;
18031
18032 darwin* | rhapsody*)
da0f6381 18033
5d47bb02
PG
18034
18035 archive_cmds_need_lc=no
18036 hardcode_direct=no
18037 hardcode_automatic=yes
18038 hardcode_shlibpath_var=unsupported
18039 whole_archive_flag_spec=''
18040 link_all_deplibs=yes
18041 allow_undefined_flag="$_lt_dar_allow_undefined"
18042 case $cc_basename in
18043 ifort*) _lt_dar_can_shared=yes ;;
18044 *) _lt_dar_can_shared=$GCC ;;
18045 esac
18046 if test "$_lt_dar_can_shared" = "yes"; then
18047 output_verbose_link_cmd=echo
18048 archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
18049 module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
18050 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}"
18051 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}"
18052
18053 else
18054 ld_shlibs=no
18055 fi
18056
da0f6381
PB
18057 ;;
18058
18059 dgux*)
18060 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
18061 hardcode_libdir_flag_spec='-L$libdir'
18062 hardcode_shlibpath_var=no
18063 ;;
18064
18065 freebsd1*)
18066 ld_shlibs=no
18067 ;;
18068
18069 # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
18070 # support. Future versions do this automatically, but an explicit c++rt0.o
18071 # does not break anything, and helps significantly (at the cost of a little
18072 # extra space).
18073 freebsd2.2*)
18074 archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
18075 hardcode_libdir_flag_spec='-R$libdir'
18076 hardcode_direct=yes
18077 hardcode_shlibpath_var=no
18078 ;;
18079
18080 # Unfortunately, older versions of FreeBSD 2 do not have this feature.
18081 freebsd2*)
18082 archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
18083 hardcode_direct=yes
18084 hardcode_minus_L=yes
18085 hardcode_shlibpath_var=no
18086 ;;
18087
18088 # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
18089 freebsd* | dragonfly*)
18090 archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
18091 hardcode_libdir_flag_spec='-R$libdir'
18092 hardcode_direct=yes
18093 hardcode_shlibpath_var=no
18094 ;;
18095
18096 hpux9*)
18097 if test "$GCC" = yes; then
18098 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'
18099 else
18100 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'
18101 fi
18102 hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
18103 hardcode_libdir_separator=:
18104 hardcode_direct=yes
18105
18106 # hardcode_minus_L: Not really in the search PATH,
18107 # but as the default location of the library.
18108 hardcode_minus_L=yes
18109 export_dynamic_flag_spec='${wl}-E'
18110 ;;
18111
18112 hpux10*)
18113 if test "$GCC" = yes -a "$with_gnu_ld" = no; then
18114 archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
18115 else
18116 archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
18117 fi
18118 if test "$with_gnu_ld" = no; then
18119 hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
18120 hardcode_libdir_flag_spec_ld='+b $libdir'
18121 hardcode_libdir_separator=:
18122 hardcode_direct=yes
18123 hardcode_direct_absolute=yes
18124 export_dynamic_flag_spec='${wl}-E'
18125 # hardcode_minus_L: Not really in the search PATH,
18126 # but as the default location of the library.
18127 hardcode_minus_L=yes
18128 fi
18129 ;;
18130
18131 hpux11*)
18132 if test "$GCC" = yes -a "$with_gnu_ld" = no; then
18133 case $host_cpu in
18134 hppa*64*)
18135 archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
18136 ;;
18137 ia64*)
5d47bb02 18138 archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
da0f6381
PB
18139 ;;
18140 *)
18141 archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
18142 ;;
18143 esac
18144 else
18145 case $host_cpu in
18146 hppa*64*)
18147 archive_cmds='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
18148 ;;
18149 ia64*)
18150 archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
18151 ;;
18152 *)
18153 archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
18154 ;;
18155 esac
18156 fi
18157 if test "$with_gnu_ld" = no; then
18158 hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
18159 hardcode_libdir_separator=:
18160
18161 case $host_cpu in
18162 hppa*64*|ia64*)
18163 hardcode_direct=no
18164 hardcode_shlibpath_var=no
18165 ;;
18166 *)
18167 hardcode_direct=yes
18168 hardcode_direct_absolute=yes
18169 export_dynamic_flag_spec='${wl}-E'
18170
18171 # hardcode_minus_L: Not really in the search PATH,
18172 # but as the default location of the library.
18173 hardcode_minus_L=yes
18174 ;;
18175 esac
18176 fi
18177 ;;
18178
18179 irix5* | irix6* | nonstopux*)
18180 if test "$GCC" = yes; then
18181 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
18182 # Try to use the -exported_symbol ld option, if it does not
18183 # work, assume that -exports_file does not work either and
18184 # implicitly export all symbols.
18185 save_LDFLAGS="$LDFLAGS"
18186 LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
18187 cat >conftest.$ac_ext <<_ACEOF
18188int foo(void) {}
18189_ACEOF
18190rm -f conftest.$ac_objext conftest$ac_exeext
18191if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18192 (eval $ac_link) 2>conftest.er1
18193 ac_status=$?
18194 grep -v '^ *+' conftest.er1 >conftest.err
18195 rm -f conftest.er1
18196 cat conftest.err >&5
18197 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18198 (exit $ac_status); } &&
18199 { ac_try='test -z "$ac_c_werror_flag"
18200 || test ! -s conftest.err'
18201 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18202 (eval $ac_try) 2>&5
18203 ac_status=$?
18204 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18205 (exit $ac_status); }; } &&
18206 { ac_try='test -s conftest$ac_exeext'
18207 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18208 (eval $ac_try) 2>&5
18209 ac_status=$?
18210 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18211 (exit $ac_status); }; }; then
18212 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
18213
18214else
18215 echo "$as_me: failed program was:" >&5
18216sed 's/^/| /' conftest.$ac_ext >&5
18217
18218fi
18219rm -f conftest.err conftest.$ac_objext \
18220 conftest$ac_exeext conftest.$ac_ext
18221 LDFLAGS="$save_LDFLAGS"
18222 else
18223 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
18224 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
18225 fi
18226 archive_cmds_need_lc='no'
18227 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
18228 hardcode_libdir_separator=:
18229 inherit_rpath=yes
18230 link_all_deplibs=yes
18231 ;;
18232
18233 netbsd*)
18234 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
18235 archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
18236 else
18237 archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
18238 fi
18239 hardcode_libdir_flag_spec='-R$libdir'
18240 hardcode_direct=yes
18241 hardcode_shlibpath_var=no
18242 ;;
18243
18244 newsos6)
18245 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
18246 hardcode_direct=yes
18247 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
18248 hardcode_libdir_separator=:
18249 hardcode_shlibpath_var=no
18250 ;;
18251
18252 *nto* | *qnx*)
18253 ;;
18254
18255 openbsd*)
5d47bb02
PG
18256 if test -f /usr/libexec/ld.so; then
18257 hardcode_direct=yes
18258 hardcode_shlibpath_var=no
18259 hardcode_direct_absolute=yes
18260 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
da0f6381 18261 archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
5d47bb02 18262 archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
da0f6381 18263 hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
5d47bb02
PG
18264 export_dynamic_flag_spec='${wl}-E'
18265 else
18266 case $host_os in
18267 openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
18268 archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
18269 hardcode_libdir_flag_spec='-R$libdir'
18270 ;;
18271 *)
18272 archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
18273 hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
18274 ;;
18275 esac
18276 fi
18277 else
18278 ld_shlibs=no
da0f6381
PB
18279 fi
18280 ;;
18281
18282 os2*)
18283 hardcode_libdir_flag_spec='-L$libdir'
18284 hardcode_minus_L=yes
18285 allow_undefined_flag=unsupported
18286 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'
18287 old_archive_from_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
18288 ;;
18289
18290 osf3*)
18291 if test "$GCC" = yes; then
18292 allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
18293 archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
18294 else
18295 allow_undefined_flag=' -expect_unresolved \*'
18296 archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
18297 fi
18298 archive_cmds_need_lc='no'
18299 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
18300 hardcode_libdir_separator=:
18301 ;;
18302
18303 osf4* | osf5*) # as osf3* with the addition of -msym flag
18304 if test "$GCC" = yes; then
18305 allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
18306 archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
18307 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
18308 else
18309 allow_undefined_flag=' -expect_unresolved \*'
18310 archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
18311 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~
18312 $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
18313
18314 # Both c and cxx compiler support -rpath directly
18315 hardcode_libdir_flag_spec='-rpath $libdir'
18316 fi
18317 archive_cmds_need_lc='no'
18318 hardcode_libdir_separator=:
18319 ;;
18320
18321 solaris*)
18322 no_undefined_flag=' -z defs'
18323 if test "$GCC" = yes; then
18324 wlarc='${wl}'
18325 archive_cmds='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
18326 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
18327 $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
18328 else
18329 case `$CC -V 2>&1` in
18330 *"Compilers 5.0"*)
18331 wlarc=''
18332 archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
18333 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
18334 $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
18335 ;;
18336 *)
18337 wlarc='${wl}'
18338 archive_cmds='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags'
18339 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
18340 $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
18341 ;;
18342 esac
18343 fi
18344 hardcode_libdir_flag_spec='-R$libdir'
18345 hardcode_shlibpath_var=no
18346 case $host_os in
18347 solaris2.[0-5] | solaris2.[0-5].*) ;;
18348 *)
18349 # The compiler driver will combine and reorder linker options,
18350 # but understands `-z linker_flag'. GCC discards it without `$wl',
18351 # but is careful enough not to reorder.
18352 # Supported since Solaris 2.6 (maybe 2.5.1?)
18353 if test "$GCC" = yes; then
18354 whole_archive_flag_spec='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
18355 else
18356 whole_archive_flag_spec='-z allextract$convenience -z defaultextract'
18357 fi
18358 ;;
18359 esac
18360 link_all_deplibs=yes
18361 ;;
18362
18363 sunos4*)
18364 if test "x$host_vendor" = xsequent; then
18365 # Use $CC to link under sequent, because it throws in some extra .o
18366 # files that make .init and .fini sections work.
18367 archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
18368 else
18369 archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
18370 fi
18371 hardcode_libdir_flag_spec='-L$libdir'
18372 hardcode_direct=yes
18373 hardcode_minus_L=yes
18374 hardcode_shlibpath_var=no
18375 ;;
18376
18377 sysv4)
18378 case $host_vendor in
18379 sni)
18380 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
18381 hardcode_direct=yes # is this really true???
18382 ;;
18383 siemens)
18384 ## LD is ld it makes a PLAMLIB
18385 ## CC just makes a GrossModule.
18386 archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
18387 reload_cmds='$CC -r -o $output$reload_objs'
18388 hardcode_direct=no
18389 ;;
18390 motorola)
18391 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
18392 hardcode_direct=no #Motorola manual says yes, but my tests say they lie
18393 ;;
18394 esac
18395 runpath_var='LD_RUN_PATH'
18396 hardcode_shlibpath_var=no
18397 ;;
18398
18399 sysv4.3*)
18400 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
18401 hardcode_shlibpath_var=no
18402 export_dynamic_flag_spec='-Bexport'
18403 ;;
18404
18405 sysv4*MP*)
18406 if test -d /usr/nec; then
18407 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
18408 hardcode_shlibpath_var=no
18409 runpath_var=LD_RUN_PATH
18410 hardcode_runpath_var=yes
18411 ld_shlibs=yes
18412 fi
18413 ;;
18414
18415 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
18416 no_undefined_flag='${wl}-z,text'
18417 archive_cmds_need_lc=no
18418 hardcode_shlibpath_var=no
18419 runpath_var='LD_RUN_PATH'
18420
18421 if test "$GCC" = yes; then
18422 archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
18423 archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
18424 else
18425 archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
18426 archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
18427 fi
18428 ;;
18429
18430 sysv5* | sco3.2v5* | sco5v6*)
18431 # Note: We can NOT use -z defs as we might desire, because we do not
18432 # link with -lc, and that would cause any symbols used from libc to
18433 # always be unresolved, which means just about no library would
18434 # ever link correctly. If we're not using GNU ld we use -z text
18435 # though, which does catch some bad symbols but isn't as heavy-handed
18436 # as -z defs.
18437 no_undefined_flag='${wl}-z,text'
18438 allow_undefined_flag='${wl}-z,nodefs'
18439 archive_cmds_need_lc=no
18440 hardcode_shlibpath_var=no
18441 hardcode_libdir_flag_spec='${wl}-R,$libdir'
18442 hardcode_libdir_separator=':'
18443 link_all_deplibs=yes
18444 export_dynamic_flag_spec='${wl}-Bexport'
18445 runpath_var='LD_RUN_PATH'
18446
18447 if test "$GCC" = yes; then
18448 archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
18449 archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
18450 else
18451 archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
18452 archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
18453 fi
18454 ;;
18455
18456 uts4*)
18457 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
18458 hardcode_libdir_flag_spec='-L$libdir'
18459 hardcode_shlibpath_var=no
18460 ;;
18461
18462 *)
18463 ld_shlibs=no
18464 ;;
18465 esac
18466
18467 if test x$host_vendor = xsni; then
18468 case $host in
18469 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
18470 export_dynamic_flag_spec='${wl}-Blargedynsym'
18471 ;;
18472 esac
18473 fi
18474 fi
18475
18476echo "$as_me:$LINENO: result: $ld_shlibs" >&5
18477echo "${ECHO_T}$ld_shlibs" >&6
18478test "$ld_shlibs" = no && can_build_shared=no
18479
18480with_gnu_ld=$with_gnu_ld
18481
18482
18483
18484
18485
18486
18487
18488
18489
18490
18491
18492
18493
18494
18495
18496#
18497# Do we need to explicitly link libc?
18498#
18499case "x$archive_cmds_need_lc" in
18500x|xyes)
18501 # Assume -lc should be added
18502 archive_cmds_need_lc=yes
18503
18504 if test "$enable_shared" = yes && test "$GCC" = yes; then
18505 case $archive_cmds in
18506 *'~'*)
18507 # FIXME: we may have to deal with multi-command sequences.
18508 ;;
18509 '$CC '*)
18510 # Test whether the compiler implicitly links with -lc since on some
18511 # systems, -lgcc has to come before -lc. If gcc already passes -lc
18512 # to ld, don't add -lc before -lgcc.
18513 echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5
18514echo $ECHO_N "checking whether -lc should be explicitly linked in... $ECHO_C" >&6
baafc534
RW
18515if test "${lt_cv_archive_cmds_need_lc+set}" = set; then
18516 echo $ECHO_N "(cached) $ECHO_C" >&6
18517else
18518 $RM conftest*
18519 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
da0f6381 18520
baafc534 18521 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
da0f6381
PB
18522 (eval $ac_compile) 2>&5
18523 ac_status=$?
18524 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18525 (exit $ac_status); } 2>conftest.err; then
baafc534
RW
18526 soname=conftest
18527 lib=conftest
18528 libobjs=conftest.$ac_objext
18529 deplibs=
18530 wl=$lt_prog_compiler_wl
18531 pic_flag=$lt_prog_compiler_pic
18532 compiler_flags=-v
18533 linker_flags=-v
18534 verstring=
18535 output_objdir=.
18536 libname=conftest
18537 lt_save_allow_undefined_flag=$allow_undefined_flag
18538 allow_undefined_flag=
18539 if { (eval echo "$as_me:$LINENO: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\"") >&5
da0f6381
PB
18540 (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5
18541 ac_status=$?
18542 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18543 (exit $ac_status); }
baafc534
RW
18544 then
18545 lt_cv_archive_cmds_need_lc=no
18546 else
18547 lt_cv_archive_cmds_need_lc=yes
18548 fi
18549 allow_undefined_flag=$lt_save_allow_undefined_flag
18550 else
18551 cat conftest.err 1>&5
18552 fi
18553 $RM conftest*
18554
18555fi
18556echo "$as_me:$LINENO: result: $lt_cv_archive_cmds_need_lc" >&5
18557echo "${ECHO_T}$lt_cv_archive_cmds_need_lc" >&6
18558 archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc
da0f6381
PB
18559 ;;
18560 esac
18561 fi
18562 ;;
18563esac
18564
18565
18566
18567
18568
18569
18570
18571
18572
18573
18574
18575
18576
18577
18578
18579
18580
18581
18582
18583
18584
18585
18586
18587
18588
18589
18590
18591
18592
18593
18594
18595
18596
18597
18598
18599
18600
18601
18602
18603
18604
18605
18606
18607
18608
18609
18610
18611
18612
18613
18614
18615
18616
18617
18618
18619
18620
18621
18622
18623
18624
18625
18626
18627
18628
18629
18630
18631
18632
18633
18634
18635
18636
18637
18638
18639
18640
18641
18642
18643
18644
18645
18646
18647
18648
18649
18650
18651
18652
18653
18654
18655
18656
18657
18658
18659
18660
18661
18662
18663
18664
18665
18666
18667
18668
18669
18670
18671
18672
18673
18674
18675
18676
18677
18678
18679
18680
18681
18682
18683
18684
18685
18686
18687
18688
18689
18690
18691
18692
18693
18694
18695
18696
18697
18698
18699
18700
18701
18702
18703
18704
18705
18706
18707
18708
18709
18710
18711
18712
18713
18714
18715
18716
18717
18718
18719
18720
18721 echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5
18722echo $ECHO_N "checking dynamic linker characteristics... $ECHO_C" >&6
5d47bb02
PG
18723
18724if test "$GCC" = yes; then
da0f6381
PB
18725 case $host_os in
18726 darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
18727 *) lt_awk_arg="/^libraries:/" ;;
18728 esac
18729 lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"`
18730 if $ECHO "$lt_search_path_spec" | $GREP ';' >/dev/null ; then
18731 # if the path contains ";" then we assume it to be the separator
18732 # otherwise default to the standard path separator (i.e. ":") - it is
18733 # assumed that no part of a normal pathname contains ";" but that should
18734 # okay in the real world where ";" in dirpaths is itself problematic.
18735 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED -e 's/;/ /g'`
18736 else
18737 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
18738 fi
18739 # Ok, now we have the path, separated by spaces, we can step through it
18740 # and add multilib dir if necessary.
18741 lt_tmp_lt_search_path_spec=
18742 lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
18743 for lt_sys_path in $lt_search_path_spec; do
18744 if test -d "$lt_sys_path/$lt_multi_os_dir"; then
18745 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
18746 else
18747 test -d "$lt_sys_path" && \
18748 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
18749 fi
18750 done
18751 lt_search_path_spec=`$ECHO $lt_tmp_lt_search_path_spec | awk '
18752BEGIN {RS=" "; FS="/|\n";} {
18753 lt_foo="";
18754 lt_count=0;
18755 for (lt_i = NF; lt_i > 0; lt_i--) {
18756 if ($lt_i != "" && $lt_i != ".") {
18757 if ($lt_i == "..") {
18758 lt_count++;
18759 } else {
18760 if (lt_count == 0) {
18761 lt_foo="/" $lt_i lt_foo;
18762 } else {
18763 lt_count--;
18764 }
18765 }
18766 }
18767 }
18768 if (lt_foo != "") { lt_freq[lt_foo]++; }
18769 if (lt_freq[lt_foo] == 1) { print lt_foo; }
18770}'`
18771 sys_lib_search_path_spec=`$ECHO $lt_search_path_spec`
18772else
18773 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
18774fi
18775library_names_spec=
18776libname_spec='lib$name'
18777soname_spec=
18778shrext_cmds=".so"
18779postinstall_cmds=
18780postuninstall_cmds=
18781finish_cmds=
18782finish_eval=
18783shlibpath_var=
18784shlibpath_overrides_runpath=unknown
18785version_type=none
18786dynamic_linker="$host_os ld.so"
18787sys_lib_dlsearch_path_spec="/lib /usr/lib"
18788need_lib_prefix=unknown
18789hardcode_into_libs=no
18790
18791# when you set need_version to no, make sure it does not cause -set_version
18792# flags to be left without arguments
18793need_version=unknown
18794
18795case $host_os in
18796aix3*)
18797 version_type=linux
18798 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
18799 shlibpath_var=LIBPATH
18800
18801 # AIX 3 has no versioning support, so we append a major version to the name.
18802 soname_spec='${libname}${release}${shared_ext}$major'
18803 ;;
18804
18805aix[4-9]*)
18806 version_type=linux
18807 need_lib_prefix=no
18808 need_version=no
18809 hardcode_into_libs=yes
18810 if test "$host_cpu" = ia64; then
18811 # AIX 5 supports IA64
18812 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
18813 shlibpath_var=LD_LIBRARY_PATH
18814 else
18815 # With GCC up to 2.95.x, collect2 would create an import file
18816 # for dependence libraries. The import file would start with
18817 # the line `#! .'. This would cause the generated library to
18818 # depend on `.', always an invalid library. This was fixed in
18819 # development snapshots of GCC prior to 3.0.
18820 case $host_os in
18821 aix4 | aix4.[01] | aix4.[01].*)
18822 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
18823 echo ' yes '
18824 echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
18825 :
18826 else
18827 can_build_shared=no
18828 fi
18829 ;;
18830 esac
18831 # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
18832 # soname into executable. Probably we can add versioning support to
18833 # collect2, so additional links can be useful in future.
18834 if test "$aix_use_runtimelinking" = yes; then
18835 # If using run time linking (on AIX 4.2 or later) use lib<name>.so
18836 # instead of lib<name>.a to let people know that these are not
18837 # typical AIX shared libraries.
18838 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
18839 else
18840 # We preserve .a as extension for shared libraries through AIX4.2
18841 # and later when we are not doing run time linking.
18842 library_names_spec='${libname}${release}.a $libname.a'
18843 soname_spec='${libname}${release}${shared_ext}$major'
18844 fi
18845 shlibpath_var=LIBPATH
18846 fi
18847 ;;
18848
18849amigaos*)
5d47bb02
PG
18850 case $host_cpu in
18851 powerpc)
18852 # Since July 2007 AmigaOS4 officially supports .so libraries.
18853 # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
18854 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
18855 ;;
18856 m68k)
da0f6381
PB
18857 library_names_spec='$libname.ixlibrary $libname.a'
18858 # Create ${libname}_ixlibrary.a entries in /sys/libs.
18859 finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$ECHO "X$lib" | $Xsed -e '\''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'
5d47bb02
PG
18860 ;;
18861 esac
da0f6381
PB
18862 ;;
18863
18864beos*)
18865 library_names_spec='${libname}${shared_ext}'
18866 dynamic_linker="$host_os ld.so"
18867 shlibpath_var=LIBRARY_PATH
18868 ;;
18869
18870bsdi[45]*)
18871 version_type=linux
18872 need_version=no
18873 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
18874 soname_spec='${libname}${release}${shared_ext}$major'
18875 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
18876 shlibpath_var=LD_LIBRARY_PATH
18877 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
18878 sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
18879 # the default ld.so.conf also contains /usr/contrib/lib and
18880 # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
18881 # libtool to hard-code these into programs
18882 ;;
18883
5d47bb02 18884cygwin* | mingw* | pw32* | cegcc*)
da0f6381
PB
18885 version_type=windows
18886 shrext_cmds=".dll"
18887 need_version=no
18888 need_lib_prefix=no
18889
5d47bb02
PG
18890 case $GCC,$host_os in
18891 yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*)
da0f6381
PB
18892 library_names_spec='$libname.dll.a'
18893 # DLL is installed to $(libdir)/../bin by postinstall_cmds
18894 postinstall_cmds='base_file=`basename \${file}`~
18895 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
18896 dldir=$destdir/`dirname \$dlpath`~
18897 test -d \$dldir || mkdir -p \$dldir~
18898 $install_prog $dir/$dlname \$dldir/$dlname~
18899 chmod a+x \$dldir/$dlname~
18900 if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
18901 eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
18902 fi'
18903 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
18904 dlpath=$dir/\$dldll~
18905 $RM \$dlpath'
18906 shlibpath_overrides_runpath=yes
18907
18908 case $host_os in
18909 cygwin*)
18910 # Cygwin DLLs use 'cyg' prefix rather than 'lib'
18911 soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
18912 sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
18913 ;;
5d47bb02 18914 mingw* | cegcc*)
da0f6381
PB
18915 # MinGW DLLs use traditional 'lib' prefix
18916 soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
18917 sys_lib_search_path_spec=`$CC -print-search-dirs | $GREP "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
18918 if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
18919 # It is most probably a Windows format PATH printed by
18920 # mingw gcc, but we are running on Cygwin. Gcc prints its search
18921 # path with ; separators, and with drive letters. We can handle the
18922 # drive letters (cygwin fileutils understands them), so leave them,
18923 # especially as we might pass files found there to a mingw objdump,
18924 # which wouldn't understand a cygwinified path. Ahh.
18925 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
18926 else
18927 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
18928 fi
18929 ;;
18930 pw32*)
18931 # pw32 DLLs use 'pw' prefix rather than 'lib'
18932 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
18933 ;;
18934 esac
18935 ;;
18936
18937 *)
18938 library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
18939 ;;
18940 esac
18941 dynamic_linker='Win32 ld.exe'
18942 # FIXME: first we should search . and the directory the executable is in
18943 shlibpath_var=PATH
18944 ;;
18945
18946darwin* | rhapsody*)
18947 dynamic_linker="$host_os dyld"
18948 version_type=darwin
18949 need_lib_prefix=no
18950 need_version=no
18951 library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
18952 soname_spec='${libname}${release}${major}$shared_ext'
18953 shlibpath_overrides_runpath=yes
18954 shlibpath_var=DYLD_LIBRARY_PATH
18955 shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
18956
18957 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"
18958 sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
18959 ;;
18960
18961dgux*)
18962 version_type=linux
18963 need_lib_prefix=no
18964 need_version=no
18965 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
18966 soname_spec='${libname}${release}${shared_ext}$major'
18967 shlibpath_var=LD_LIBRARY_PATH
18968 ;;
18969
18970freebsd1*)
18971 dynamic_linker=no
18972 ;;
18973
18974freebsd* | dragonfly*)
18975 # DragonFly does not have aout. When/if they implement a new
18976 # versioning mechanism, adjust this.
18977 if test -x /usr/bin/objformat; then
18978 objformat=`/usr/bin/objformat`
18979 else
18980 case $host_os in
18981 freebsd[123]*) objformat=aout ;;
18982 *) objformat=elf ;;
18983 esac
18984 fi
18985 version_type=freebsd-$objformat
18986 case $version_type in
18987 freebsd-elf*)
18988 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
18989 need_version=no
18990 need_lib_prefix=no
18991 ;;
18992 freebsd-*)
18993 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
18994 need_version=yes
18995 ;;
18996 esac
18997 shlibpath_var=LD_LIBRARY_PATH
18998 case $host_os in
18999 freebsd2*)
19000 shlibpath_overrides_runpath=yes
19001 ;;
19002 freebsd3.[01]* | freebsdelf3.[01]*)
19003 shlibpath_overrides_runpath=yes
19004 hardcode_into_libs=yes
19005 ;;
19006 freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
19007 freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
19008 shlibpath_overrides_runpath=no
19009 hardcode_into_libs=yes
19010 ;;
19011 *) # from 4.6 on, and DragonFly
19012 shlibpath_overrides_runpath=yes
19013 hardcode_into_libs=yes
19014 ;;
19015 esac
19016 ;;
19017
19018gnu*)
19019 version_type=linux
19020 need_lib_prefix=no
19021 need_version=no
19022 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
19023 soname_spec='${libname}${release}${shared_ext}$major'
19024 shlibpath_var=LD_LIBRARY_PATH
19025 hardcode_into_libs=yes
19026 ;;
19027
19028hpux9* | hpux10* | hpux11*)
19029 # Give a soname corresponding to the major version so that dld.sl refuses to
19030 # link against other versions.
19031 version_type=sunos
19032 need_lib_prefix=no
19033 need_version=no
19034 case $host_cpu in
19035 ia64*)
19036 shrext_cmds='.so'
19037 hardcode_into_libs=yes
19038 dynamic_linker="$host_os dld.so"
19039 shlibpath_var=LD_LIBRARY_PATH
19040 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
19041 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
19042 soname_spec='${libname}${release}${shared_ext}$major'
19043 if test "X$HPUX_IA64_MODE" = X32; then
19044 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
19045 else
19046 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
19047 fi
19048 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
19049 ;;
19050 hppa*64*)
19051 shrext_cmds='.sl'
19052 hardcode_into_libs=yes
19053 dynamic_linker="$host_os dld.sl"
19054 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
19055 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
19056 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
19057 soname_spec='${libname}${release}${shared_ext}$major'
19058 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
19059 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
19060 ;;
19061 *)
19062 shrext_cmds='.sl'
19063 dynamic_linker="$host_os dld.sl"
19064 shlibpath_var=SHLIB_PATH
19065 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
19066 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
19067 soname_spec='${libname}${release}${shared_ext}$major'
19068 ;;
19069 esac
19070 # HP-UX runs *really* slowly unless shared libraries are mode 555.
19071 postinstall_cmds='chmod 555 $lib'
19072 ;;
19073
19074interix[3-9]*)
19075 version_type=linux
19076 need_lib_prefix=no
19077 need_version=no
19078 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
19079 soname_spec='${libname}${release}${shared_ext}$major'
19080 dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
19081 shlibpath_var=LD_LIBRARY_PATH
19082 shlibpath_overrides_runpath=no
19083 hardcode_into_libs=yes
19084 ;;
19085
19086irix5* | irix6* | nonstopux*)
19087 case $host_os in
19088 nonstopux*) version_type=nonstopux ;;
19089 *)
19090 if test "$lt_cv_prog_gnu_ld" = yes; then
19091 version_type=linux
19092 else
19093 version_type=irix
19094 fi ;;
19095 esac
19096 need_lib_prefix=no
19097 need_version=no
19098 soname_spec='${libname}${release}${shared_ext}$major'
19099 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
19100 case $host_os in
19101 irix5* | nonstopux*)
19102 libsuff= shlibsuff=
19103 ;;
19104 *)
19105 case $LD in # libtool.m4 will add one of these switches to LD
19106 *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
19107 libsuff= shlibsuff= libmagic=32-bit;;
19108 *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
19109 libsuff=32 shlibsuff=N32 libmagic=N32;;
19110 *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
19111 libsuff=64 shlibsuff=64 libmagic=64-bit;;
19112 *) libsuff= shlibsuff= libmagic=never-match;;
19113 esac
19114 ;;
19115 esac
19116 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
19117 shlibpath_overrides_runpath=no
19118 sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
19119 sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
19120 hardcode_into_libs=yes
19121 ;;
19122
19123# No shared lib support for Linux oldld, aout, or coff.
19124linux*oldld* | linux*aout* | linux*coff*)
19125 dynamic_linker=no
19126 ;;
19127
19128# This must be Linux ELF.
7a9d3fe8 19129linux* | k*bsd*-gnu | kopensolaris*-gnu)
da0f6381
PB
19130 version_type=linux
19131 need_lib_prefix=no
19132 need_version=no
19133 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
19134 soname_spec='${libname}${release}${shared_ext}$major'
19135 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
19136 shlibpath_var=LD_LIBRARY_PATH
19137 shlibpath_overrides_runpath=no
baafc534 19138
da0f6381 19139 # Some binutils ld are patched to set DT_RUNPATH
baafc534
RW
19140 if test "${lt_cv_shlibpath_overrides_runpath+set}" = set; then
19141 echo $ECHO_N "(cached) $ECHO_C" >&6
19142else
19143 lt_cv_shlibpath_overrides_runpath=no
19144 save_LDFLAGS=$LDFLAGS
19145 save_libdir=$libdir
19146 eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \
19147 LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\""
19148 cat >conftest.$ac_ext <<_ACEOF
da0f6381
PB
19149/* confdefs.h. */
19150_ACEOF
19151cat confdefs.h >>conftest.$ac_ext
19152cat >>conftest.$ac_ext <<_ACEOF
19153/* end confdefs.h. */
19154
19155int
19156main ()
19157{
19158
19159 ;
19160 return 0;
19161}
19162_ACEOF
19163rm -f conftest.$ac_objext conftest$ac_exeext
19164if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19165 (eval $ac_link) 2>conftest.er1
19166 ac_status=$?
19167 grep -v '^ *+' conftest.er1 >conftest.err
19168 rm -f conftest.er1
19169 cat conftest.err >&5
19170 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19171 (exit $ac_status); } &&
19172 { ac_try='test -z "$ac_c_werror_flag"
19173 || test ! -s conftest.err'
19174 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19175 (eval $ac_try) 2>&5
19176 ac_status=$?
19177 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19178 (exit $ac_status); }; } &&
19179 { ac_try='test -s conftest$ac_exeext'
19180 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19181 (eval $ac_try) 2>&5
19182 ac_status=$?
19183 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19184 (exit $ac_status); }; }; then
5d47bb02 19185 if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then
baafc534 19186 lt_cv_shlibpath_overrides_runpath=yes
da0f6381
PB
19187fi
19188
19189else
19190 echo "$as_me: failed program was:" >&5
19191sed 's/^/| /' conftest.$ac_ext >&5
19192
19193fi
19194rm -f conftest.err conftest.$ac_objext \
19195 conftest$ac_exeext conftest.$ac_ext
baafc534
RW
19196 LDFLAGS=$save_LDFLAGS
19197 libdir=$save_libdir
19198
19199fi
19200
19201 shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
da0f6381
PB
19202
19203 # This implies no fast_install, which is unacceptable.
19204 # Some rework will be needed to allow for fast_install
19205 # before this can be enabled.
19206 hardcode_into_libs=yes
19207
19208 # Append ld.so.conf contents to the search path
19209 if test -f /etc/ld.so.conf; then
5d47bb02 19210 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;/^$/d' | tr '\n' ' '`
da0f6381
PB
19211 sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
19212 fi
19213
19214 # We used to test for /lib/ld.so.1 and disable shared libraries on
19215 # powerpc, because MkLinux only supported shared libraries with the
19216 # GNU dynamic linker. Since this was broken with cross compilers,
19217 # most powerpc-linux boxes support dynamic linking these days and
19218 # people can always --disable-shared, the test was removed, and we
19219 # assume the GNU/Linux dynamic linker is in use.
19220 dynamic_linker='GNU/Linux ld.so'
19221 ;;
19222
19223netbsd*)
19224 version_type=sunos
19225 need_lib_prefix=no
19226 need_version=no
19227 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
19228 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
19229 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
19230 dynamic_linker='NetBSD (a.out) ld.so'
19231 else
19232 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
19233 soname_spec='${libname}${release}${shared_ext}$major'
19234 dynamic_linker='NetBSD ld.elf_so'
19235 fi
19236 shlibpath_var=LD_LIBRARY_PATH
19237 shlibpath_overrides_runpath=yes
19238 hardcode_into_libs=yes
19239 ;;
19240
19241newsos6)
19242 version_type=linux
19243 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
19244 shlibpath_var=LD_LIBRARY_PATH
19245 shlibpath_overrides_runpath=yes
19246 ;;
19247
19248*nto* | *qnx*)
19249 version_type=qnx
19250 need_lib_prefix=no
19251 need_version=no
19252 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
19253 soname_spec='${libname}${release}${shared_ext}$major'
19254 shlibpath_var=LD_LIBRARY_PATH
19255 shlibpath_overrides_runpath=no
19256 hardcode_into_libs=yes
19257 dynamic_linker='ldqnx.so'
19258 ;;
19259
19260openbsd*)
19261 version_type=sunos
19262 sys_lib_dlsearch_path_spec="/usr/lib"
19263 need_lib_prefix=no
19264 # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
19265 case $host_os in
19266 openbsd3.3 | openbsd3.3.*) need_version=yes ;;
19267 *) need_version=no ;;
19268 esac
19269 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
19270 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
19271 shlibpath_var=LD_LIBRARY_PATH
19272 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
19273 case $host_os in
19274 openbsd2.[89] | openbsd2.[89].*)
19275 shlibpath_overrides_runpath=no
19276 ;;
19277 *)
19278 shlibpath_overrides_runpath=yes
19279 ;;
19280 esac
19281 else
19282 shlibpath_overrides_runpath=yes
19283 fi
19284 ;;
19285
19286os2*)
19287 libname_spec='$name'
19288 shrext_cmds=".dll"
19289 need_lib_prefix=no
19290 library_names_spec='$libname${shared_ext} $libname.a'
19291 dynamic_linker='OS/2 ld.exe'
19292 shlibpath_var=LIBPATH
19293 ;;
19294
19295osf3* | osf4* | osf5*)
19296 version_type=osf
19297 need_lib_prefix=no
19298 need_version=no
19299 soname_spec='${libname}${release}${shared_ext}$major'
19300 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
19301 shlibpath_var=LD_LIBRARY_PATH
19302 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
19303 sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
19304 ;;
19305
19306rdos*)
19307 dynamic_linker=no
19308 ;;
19309
19310solaris*)
19311 version_type=linux
19312 need_lib_prefix=no
19313 need_version=no
19314 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
19315 soname_spec='${libname}${release}${shared_ext}$major'
19316 shlibpath_var=LD_LIBRARY_PATH
19317 shlibpath_overrides_runpath=yes
19318 hardcode_into_libs=yes
19319 # ldd complains unless libraries are executable
19320 postinstall_cmds='chmod +x $lib'
19321 ;;
19322
19323sunos4*)
19324 version_type=sunos
19325 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
19326 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
19327 shlibpath_var=LD_LIBRARY_PATH
19328 shlibpath_overrides_runpath=yes
19329 if test "$with_gnu_ld" = yes; then
19330 need_lib_prefix=no
19331 fi
19332 need_version=yes
19333 ;;
19334
19335sysv4 | sysv4.3*)
19336 version_type=linux
19337 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
19338 soname_spec='${libname}${release}${shared_ext}$major'
19339 shlibpath_var=LD_LIBRARY_PATH
19340 case $host_vendor in
19341 sni)
19342 shlibpath_overrides_runpath=no
19343 need_lib_prefix=no
19344 runpath_var=LD_RUN_PATH
19345 ;;
19346 siemens)
19347 need_lib_prefix=no
19348 ;;
19349 motorola)
19350 need_lib_prefix=no
19351 need_version=no
19352 shlibpath_overrides_runpath=no
19353 sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
19354 ;;
19355 esac
19356 ;;
19357
19358sysv4*MP*)
19359 if test -d /usr/nec ;then
19360 version_type=linux
19361 library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
19362 soname_spec='$libname${shared_ext}.$major'
19363 shlibpath_var=LD_LIBRARY_PATH
19364 fi
19365 ;;
19366
19367sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
19368 version_type=freebsd-elf
19369 need_lib_prefix=no
19370 need_version=no
19371 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
19372 soname_spec='${libname}${release}${shared_ext}$major'
19373 shlibpath_var=LD_LIBRARY_PATH
19374 shlibpath_overrides_runpath=yes
19375 hardcode_into_libs=yes
19376 if test "$with_gnu_ld" = yes; then
19377 sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
19378 else
19379 sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
19380 case $host_os in
19381 sco3.2v5*)
19382 sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
19383 ;;
19384 esac
19385 fi
19386 sys_lib_dlsearch_path_spec='/usr/lib'
19387 ;;
19388
19389tpf*)
19390 # TPF is a cross-target only. Preferred cross-host = GNU/Linux.
19391 version_type=linux
19392 need_lib_prefix=no
19393 need_version=no
5d47bb02 19394 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
da0f6381
PB
19395 shlibpath_var=LD_LIBRARY_PATH
19396 shlibpath_overrides_runpath=no
19397 hardcode_into_libs=yes
19398 ;;
19399
19400uts4*)
19401 version_type=linux
19402 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
19403 soname_spec='${libname}${release}${shared_ext}$major'
19404 shlibpath_var=LD_LIBRARY_PATH
19405 ;;
19406
19407*)
19408 dynamic_linker=no
19409 ;;
19410esac
19411echo "$as_me:$LINENO: result: $dynamic_linker" >&5
19412echo "${ECHO_T}$dynamic_linker" >&6
19413test "$dynamic_linker" = no && can_build_shared=no
19414
19415variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
19416if test "$GCC" = yes; then
19417 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
19418fi
19419
5d47bb02
PG
19420if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
19421 sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
19422fi
19423if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
19424 sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
19425fi
19426
da0f6381
PB
19427
19428
19429
19430
19431
19432
19433
19434
19435
19436
19437
19438
19439
19440
19441
19442
19443
19444
19445
19446
19447
19448
19449
19450
19451
19452
19453
19454
19455
19456
19457
19458
19459
19460
19461
19462
19463
19464
19465
19466
19467
19468
19469
19470
19471
19472
19473
19474
19475
19476
19477
19478
19479
19480
19481
19482
19483
19484
19485
19486
19487
19488
19489
19490
19491
19492
19493
19494
19495
19496
19497
19498
19499
19500
19501
19502
19503
19504
19505
19506
19507
19508
19509
19510
19511
19512
19513 echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5
19514echo $ECHO_N "checking how to hardcode library paths into programs... $ECHO_C" >&6
19515hardcode_action=
19516if test -n "$hardcode_libdir_flag_spec" ||
19517 test -n "$runpath_var" ||
19518 test "X$hardcode_automatic" = "Xyes" ; then
19519
19520 # We can hardcode non-existent directories.
19521 if test "$hardcode_direct" != no &&
19522 # If the only mechanism to avoid hardcoding is shlibpath_var, we
19523 # have to relink, otherwise we might link with an installed library
19524 # when we should be linking with a yet-to-be-installed one
19525 ## test "$_LT_TAGVAR(hardcode_shlibpath_var, )" != no &&
19526 test "$hardcode_minus_L" != no; then
19527 # Linking always hardcodes the temporary library directory.
19528 hardcode_action=relink
19529 else
19530 # We can link without hardcoding, and we can hardcode nonexisting dirs.
19531 hardcode_action=immediate
19532 fi
19533else
19534 # We cannot hardcode anything, or else we can only hardcode existing
19535 # directories.
19536 hardcode_action=unsupported
19537fi
19538echo "$as_me:$LINENO: result: $hardcode_action" >&5
19539echo "${ECHO_T}$hardcode_action" >&6
19540
19541if test "$hardcode_action" = relink ||
19542 test "$inherit_rpath" = yes; then
19543 # Fast installation is not supported
19544 enable_fast_install=no
19545elif test "$shlibpath_overrides_runpath" = yes ||
19546 test "$enable_shared" = no; then
19547 # Fast installation is not necessary
19548 enable_fast_install=needless
19549fi
19550
19551
19552
19553
19554
19555
19556 if test "x$enable_dlopen" != xyes; then
19557 enable_dlopen=unknown
19558 enable_dlopen_self=unknown
19559 enable_dlopen_self_static=unknown
19560else
19561 lt_cv_dlopen=no
19562 lt_cv_dlopen_libs=
19563
19564 case $host_os in
19565 beos*)
19566 lt_cv_dlopen="load_add_on"
19567 lt_cv_dlopen_libs=
19568 lt_cv_dlopen_self=yes
19569 ;;
19570
5d47bb02 19571 mingw* | pw32* | cegcc*)
da0f6381
PB
19572 lt_cv_dlopen="LoadLibrary"
19573 lt_cv_dlopen_libs=
19574 ;;
19575
19576 cygwin*)
19577 lt_cv_dlopen="dlopen"
19578 lt_cv_dlopen_libs=
19579 ;;
19580
19581 darwin*)
19582 # if libdl is installed we need to link against it
19583 echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
19584echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6
19585if test "${ac_cv_lib_dl_dlopen+set}" = set; then
19586 echo $ECHO_N "(cached) $ECHO_C" >&6
19587else
19588 ac_check_lib_save_LIBS=$LIBS
19589LIBS="-ldl $LIBS"
19590cat >conftest.$ac_ext <<_ACEOF
19591/* confdefs.h. */
19592_ACEOF
19593cat confdefs.h >>conftest.$ac_ext
19594cat >>conftest.$ac_ext <<_ACEOF
19595/* end confdefs.h. */
19596
19597/* Override any gcc2 internal prototype to avoid an error. */
19598#ifdef __cplusplus
19599extern "C"
19600#endif
19601/* We use char because int might match the return type of a gcc2
19602 builtin and then its argument prototype would still apply. */
19603char dlopen ();
19604int
19605main ()
19606{
19607dlopen ();
19608 ;
19609 return 0;
19610}
19611_ACEOF
19612rm -f conftest.$ac_objext conftest$ac_exeext
19613if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19614 (eval $ac_link) 2>conftest.er1
19615 ac_status=$?
19616 grep -v '^ *+' conftest.er1 >conftest.err
19617 rm -f conftest.er1
19618 cat conftest.err >&5
19619 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19620 (exit $ac_status); } &&
19621 { ac_try='test -z "$ac_c_werror_flag"
19622 || test ! -s conftest.err'
19623 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19624 (eval $ac_try) 2>&5
19625 ac_status=$?
19626 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19627 (exit $ac_status); }; } &&
19628 { ac_try='test -s conftest$ac_exeext'
19629 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19630 (eval $ac_try) 2>&5
19631 ac_status=$?
19632 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19633 (exit $ac_status); }; }; then
19634 ac_cv_lib_dl_dlopen=yes
19635else
19636 echo "$as_me: failed program was:" >&5
19637sed 's/^/| /' conftest.$ac_ext >&5
19638
19639ac_cv_lib_dl_dlopen=no
19640fi
19641rm -f conftest.err conftest.$ac_objext \
19642 conftest$ac_exeext conftest.$ac_ext
19643LIBS=$ac_check_lib_save_LIBS
19644fi
19645echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5
19646echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6
19647if test $ac_cv_lib_dl_dlopen = yes; then
19648 lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
19649else
19650
19651 lt_cv_dlopen="dyld"
19652 lt_cv_dlopen_libs=
19653 lt_cv_dlopen_self=yes
19654
19655fi
19656
19657 ;;
19658
19659 *)
19660 echo "$as_me:$LINENO: checking for shl_load" >&5
19661echo $ECHO_N "checking for shl_load... $ECHO_C" >&6
19662if test "${ac_cv_func_shl_load+set}" = set; then
19663 echo $ECHO_N "(cached) $ECHO_C" >&6
19664else
19665 cat >conftest.$ac_ext <<_ACEOF
19666/* confdefs.h. */
19667_ACEOF
19668cat confdefs.h >>conftest.$ac_ext
19669cat >>conftest.$ac_ext <<_ACEOF
19670/* end confdefs.h. */
19671/* Define shl_load to an innocuous variant, in case <limits.h> declares shl_load.
19672 For example, HP-UX 11i <limits.h> declares gettimeofday. */
19673#define shl_load innocuous_shl_load
19674
19675/* System header to define __stub macros and hopefully few prototypes,
19676 which can conflict with char shl_load (); below.
19677 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19678 <limits.h> exists even on freestanding compilers. */
19679
19680#ifdef __STDC__
19681# include <limits.h>
19682#else
19683# include <assert.h>
19684#endif
19685
19686#undef shl_load
19687
19688/* Override any gcc2 internal prototype to avoid an error. */
19689#ifdef __cplusplus
19690extern "C"
19691{
19692#endif
19693/* We use char because int might match the return type of a gcc2
19694 builtin and then its argument prototype would still apply. */
19695char shl_load ();
19696/* The GNU C library defines this for functions which it implements
19697 to always fail with ENOSYS. Some functions are actually named
19698 something starting with __ and the normal name is an alias. */
19699#if defined (__stub_shl_load) || defined (__stub___shl_load)
19700choke me
19701#else
19702char (*f) () = shl_load;
19703#endif
19704#ifdef __cplusplus
19705}
19706#endif
19707
19708int
19709main ()
19710{
19711return f != shl_load;
19712 ;
19713 return 0;
19714}
19715_ACEOF
19716rm -f conftest.$ac_objext conftest$ac_exeext
19717if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19718 (eval $ac_link) 2>conftest.er1
19719 ac_status=$?
19720 grep -v '^ *+' conftest.er1 >conftest.err
19721 rm -f conftest.er1
19722 cat conftest.err >&5
19723 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19724 (exit $ac_status); } &&
19725 { ac_try='test -z "$ac_c_werror_flag"
19726 || test ! -s conftest.err'
19727 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19728 (eval $ac_try) 2>&5
19729 ac_status=$?
19730 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19731 (exit $ac_status); }; } &&
19732 { ac_try='test -s conftest$ac_exeext'
19733 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19734 (eval $ac_try) 2>&5
19735 ac_status=$?
19736 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19737 (exit $ac_status); }; }; then
19738 ac_cv_func_shl_load=yes
19739else
19740 echo "$as_me: failed program was:" >&5
19741sed 's/^/| /' conftest.$ac_ext >&5
19742
19743ac_cv_func_shl_load=no
19744fi
19745rm -f conftest.err conftest.$ac_objext \
19746 conftest$ac_exeext conftest.$ac_ext
19747fi
19748echo "$as_me:$LINENO: result: $ac_cv_func_shl_load" >&5
19749echo "${ECHO_T}$ac_cv_func_shl_load" >&6
19750if test $ac_cv_func_shl_load = yes; then
19751 lt_cv_dlopen="shl_load"
19752else
19753 echo "$as_me:$LINENO: checking for shl_load in -ldld" >&5
19754echo $ECHO_N "checking for shl_load in -ldld... $ECHO_C" >&6
19755if test "${ac_cv_lib_dld_shl_load+set}" = set; then
19756 echo $ECHO_N "(cached) $ECHO_C" >&6
19757else
19758 ac_check_lib_save_LIBS=$LIBS
19759LIBS="-ldld $LIBS"
19760cat >conftest.$ac_ext <<_ACEOF
19761/* confdefs.h. */
19762_ACEOF
19763cat confdefs.h >>conftest.$ac_ext
19764cat >>conftest.$ac_ext <<_ACEOF
19765/* end confdefs.h. */
19766
19767/* Override any gcc2 internal prototype to avoid an error. */
19768#ifdef __cplusplus
19769extern "C"
19770#endif
19771/* We use char because int might match the return type of a gcc2
19772 builtin and then its argument prototype would still apply. */
19773char shl_load ();
19774int
19775main ()
19776{
19777shl_load ();
19778 ;
19779 return 0;
19780}
19781_ACEOF
19782rm -f conftest.$ac_objext conftest$ac_exeext
19783if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19784 (eval $ac_link) 2>conftest.er1
19785 ac_status=$?
19786 grep -v '^ *+' conftest.er1 >conftest.err
19787 rm -f conftest.er1
19788 cat conftest.err >&5
19789 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19790 (exit $ac_status); } &&
19791 { ac_try='test -z "$ac_c_werror_flag"
19792 || test ! -s conftest.err'
19793 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19794 (eval $ac_try) 2>&5
19795 ac_status=$?
19796 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19797 (exit $ac_status); }; } &&
19798 { ac_try='test -s conftest$ac_exeext'
19799 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19800 (eval $ac_try) 2>&5
19801 ac_status=$?
19802 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19803 (exit $ac_status); }; }; then
19804 ac_cv_lib_dld_shl_load=yes
19805else
19806 echo "$as_me: failed program was:" >&5
19807sed 's/^/| /' conftest.$ac_ext >&5
19808
19809ac_cv_lib_dld_shl_load=no
19810fi
19811rm -f conftest.err conftest.$ac_objext \
19812 conftest$ac_exeext conftest.$ac_ext
19813LIBS=$ac_check_lib_save_LIBS
19814fi
19815echo "$as_me:$LINENO: result: $ac_cv_lib_dld_shl_load" >&5
19816echo "${ECHO_T}$ac_cv_lib_dld_shl_load" >&6
19817if test $ac_cv_lib_dld_shl_load = yes; then
5d47bb02 19818 lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"
da0f6381
PB
19819else
19820 echo "$as_me:$LINENO: checking for dlopen" >&5
19821echo $ECHO_N "checking for dlopen... $ECHO_C" >&6
19822if test "${ac_cv_func_dlopen+set}" = set; then
19823 echo $ECHO_N "(cached) $ECHO_C" >&6
19824else
19825 cat >conftest.$ac_ext <<_ACEOF
19826/* confdefs.h. */
19827_ACEOF
19828cat confdefs.h >>conftest.$ac_ext
19829cat >>conftest.$ac_ext <<_ACEOF
19830/* end confdefs.h. */
19831/* Define dlopen to an innocuous variant, in case <limits.h> declares dlopen.
19832 For example, HP-UX 11i <limits.h> declares gettimeofday. */
19833#define dlopen innocuous_dlopen
19834
19835/* System header to define __stub macros and hopefully few prototypes,
19836 which can conflict with char dlopen (); below.
19837 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19838 <limits.h> exists even on freestanding compilers. */
19839
19840#ifdef __STDC__
19841# include <limits.h>
19842#else
19843# include <assert.h>
19844#endif
19845
19846#undef dlopen
19847
19848/* Override any gcc2 internal prototype to avoid an error. */
19849#ifdef __cplusplus
19850extern "C"
19851{
19852#endif
19853/* We use char because int might match the return type of a gcc2
19854 builtin and then its argument prototype would still apply. */
19855char dlopen ();
19856/* The GNU C library defines this for functions which it implements
19857 to always fail with ENOSYS. Some functions are actually named
19858 something starting with __ and the normal name is an alias. */
19859#if defined (__stub_dlopen) || defined (__stub___dlopen)
19860choke me
19861#else
19862char (*f) () = dlopen;
19863#endif
19864#ifdef __cplusplus
19865}
19866#endif
19867
19868int
19869main ()
19870{
19871return f != dlopen;
19872 ;
19873 return 0;
19874}
19875_ACEOF
19876rm -f conftest.$ac_objext conftest$ac_exeext
19877if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19878 (eval $ac_link) 2>conftest.er1
19879 ac_status=$?
19880 grep -v '^ *+' conftest.er1 >conftest.err
19881 rm -f conftest.er1
19882 cat conftest.err >&5
19883 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19884 (exit $ac_status); } &&
19885 { ac_try='test -z "$ac_c_werror_flag"
19886 || test ! -s conftest.err'
19887 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19888 (eval $ac_try) 2>&5
19889 ac_status=$?
19890 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19891 (exit $ac_status); }; } &&
19892 { ac_try='test -s conftest$ac_exeext'
19893 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19894 (eval $ac_try) 2>&5
19895 ac_status=$?
19896 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19897 (exit $ac_status); }; }; then
19898 ac_cv_func_dlopen=yes
19899else
19900 echo "$as_me: failed program was:" >&5
19901sed 's/^/| /' conftest.$ac_ext >&5
19902
19903ac_cv_func_dlopen=no
19904fi
19905rm -f conftest.err conftest.$ac_objext \
19906 conftest$ac_exeext conftest.$ac_ext
19907fi
19908echo "$as_me:$LINENO: result: $ac_cv_func_dlopen" >&5
19909echo "${ECHO_T}$ac_cv_func_dlopen" >&6
19910if test $ac_cv_func_dlopen = yes; then
19911 lt_cv_dlopen="dlopen"
19912else
19913 echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
19914echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6
19915if test "${ac_cv_lib_dl_dlopen+set}" = set; then
19916 echo $ECHO_N "(cached) $ECHO_C" >&6
19917else
19918 ac_check_lib_save_LIBS=$LIBS
19919LIBS="-ldl $LIBS"
19920cat >conftest.$ac_ext <<_ACEOF
19921/* confdefs.h. */
19922_ACEOF
19923cat confdefs.h >>conftest.$ac_ext
19924cat >>conftest.$ac_ext <<_ACEOF
19925/* end confdefs.h. */
19926
19927/* Override any gcc2 internal prototype to avoid an error. */
19928#ifdef __cplusplus
19929extern "C"
19930#endif
19931/* We use char because int might match the return type of a gcc2
19932 builtin and then its argument prototype would still apply. */
19933char dlopen ();
19934int
19935main ()
19936{
19937dlopen ();
19938 ;
19939 return 0;
19940}
19941_ACEOF
19942rm -f conftest.$ac_objext conftest$ac_exeext
19943if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19944 (eval $ac_link) 2>conftest.er1
19945 ac_status=$?
19946 grep -v '^ *+' conftest.er1 >conftest.err
19947 rm -f conftest.er1
19948 cat conftest.err >&5
19949 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19950 (exit $ac_status); } &&
19951 { ac_try='test -z "$ac_c_werror_flag"
19952 || test ! -s conftest.err'
19953 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19954 (eval $ac_try) 2>&5
19955 ac_status=$?
19956 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19957 (exit $ac_status); }; } &&
19958 { ac_try='test -s conftest$ac_exeext'
19959 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19960 (eval $ac_try) 2>&5
19961 ac_status=$?
19962 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19963 (exit $ac_status); }; }; then
19964 ac_cv_lib_dl_dlopen=yes
19965else
19966 echo "$as_me: failed program was:" >&5
19967sed 's/^/| /' conftest.$ac_ext >&5
19968
19969ac_cv_lib_dl_dlopen=no
19970fi
19971rm -f conftest.err conftest.$ac_objext \
19972 conftest$ac_exeext conftest.$ac_ext
19973LIBS=$ac_check_lib_save_LIBS
19974fi
19975echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5
19976echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6
19977if test $ac_cv_lib_dl_dlopen = yes; then
19978 lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
19979else
19980 echo "$as_me:$LINENO: checking for dlopen in -lsvld" >&5
19981echo $ECHO_N "checking for dlopen in -lsvld... $ECHO_C" >&6
19982if test "${ac_cv_lib_svld_dlopen+set}" = set; then
19983 echo $ECHO_N "(cached) $ECHO_C" >&6
19984else
19985 ac_check_lib_save_LIBS=$LIBS
19986LIBS="-lsvld $LIBS"
19987cat >conftest.$ac_ext <<_ACEOF
19988/* confdefs.h. */
19989_ACEOF
19990cat confdefs.h >>conftest.$ac_ext
19991cat >>conftest.$ac_ext <<_ACEOF
19992/* end confdefs.h. */
19993
19994/* Override any gcc2 internal prototype to avoid an error. */
19995#ifdef __cplusplus
19996extern "C"
19997#endif
19998/* We use char because int might match the return type of a gcc2
19999 builtin and then its argument prototype would still apply. */
20000char dlopen ();
20001int
20002main ()
20003{
20004dlopen ();
20005 ;
20006 return 0;
20007}
20008_ACEOF
20009rm -f conftest.$ac_objext conftest$ac_exeext
20010if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20011 (eval $ac_link) 2>conftest.er1
20012 ac_status=$?
20013 grep -v '^ *+' conftest.er1 >conftest.err
20014 rm -f conftest.er1
20015 cat conftest.err >&5
20016 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20017 (exit $ac_status); } &&
20018 { ac_try='test -z "$ac_c_werror_flag"
20019 || test ! -s conftest.err'
20020 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20021 (eval $ac_try) 2>&5
20022 ac_status=$?
20023 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20024 (exit $ac_status); }; } &&
20025 { ac_try='test -s conftest$ac_exeext'
20026 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20027 (eval $ac_try) 2>&5
20028 ac_status=$?
20029 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20030 (exit $ac_status); }; }; then
20031 ac_cv_lib_svld_dlopen=yes
20032else
20033 echo "$as_me: failed program was:" >&5
20034sed 's/^/| /' conftest.$ac_ext >&5
20035
20036ac_cv_lib_svld_dlopen=no
20037fi
20038rm -f conftest.err conftest.$ac_objext \
20039 conftest$ac_exeext conftest.$ac_ext
20040LIBS=$ac_check_lib_save_LIBS
20041fi
20042echo "$as_me:$LINENO: result: $ac_cv_lib_svld_dlopen" >&5
20043echo "${ECHO_T}$ac_cv_lib_svld_dlopen" >&6
20044if test $ac_cv_lib_svld_dlopen = yes; then
20045 lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"
20046else
20047 echo "$as_me:$LINENO: checking for dld_link in -ldld" >&5
20048echo $ECHO_N "checking for dld_link in -ldld... $ECHO_C" >&6
20049if test "${ac_cv_lib_dld_dld_link+set}" = set; then
20050 echo $ECHO_N "(cached) $ECHO_C" >&6
20051else
20052 ac_check_lib_save_LIBS=$LIBS
20053LIBS="-ldld $LIBS"
20054cat >conftest.$ac_ext <<_ACEOF
20055/* confdefs.h. */
20056_ACEOF
20057cat confdefs.h >>conftest.$ac_ext
20058cat >>conftest.$ac_ext <<_ACEOF
20059/* end confdefs.h. */
20060
20061/* Override any gcc2 internal prototype to avoid an error. */
20062#ifdef __cplusplus
20063extern "C"
20064#endif
20065/* We use char because int might match the return type of a gcc2
20066 builtin and then its argument prototype would still apply. */
20067char dld_link ();
20068int
20069main ()
20070{
20071dld_link ();
20072 ;
20073 return 0;
20074}
20075_ACEOF
20076rm -f conftest.$ac_objext conftest$ac_exeext
20077if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20078 (eval $ac_link) 2>conftest.er1
20079 ac_status=$?
20080 grep -v '^ *+' conftest.er1 >conftest.err
20081 rm -f conftest.er1
20082 cat conftest.err >&5
20083 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20084 (exit $ac_status); } &&
20085 { ac_try='test -z "$ac_c_werror_flag"
20086 || test ! -s conftest.err'
20087 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20088 (eval $ac_try) 2>&5
20089 ac_status=$?
20090 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20091 (exit $ac_status); }; } &&
20092 { ac_try='test -s conftest$ac_exeext'
20093 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20094 (eval $ac_try) 2>&5
20095 ac_status=$?
20096 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20097 (exit $ac_status); }; }; then
20098 ac_cv_lib_dld_dld_link=yes
20099else
20100 echo "$as_me: failed program was:" >&5
20101sed 's/^/| /' conftest.$ac_ext >&5
20102
20103ac_cv_lib_dld_dld_link=no
20104fi
20105rm -f conftest.err conftest.$ac_objext \
20106 conftest$ac_exeext conftest.$ac_ext
20107LIBS=$ac_check_lib_save_LIBS
20108fi
20109echo "$as_me:$LINENO: result: $ac_cv_lib_dld_dld_link" >&5
20110echo "${ECHO_T}$ac_cv_lib_dld_dld_link" >&6
20111if test $ac_cv_lib_dld_dld_link = yes; then
5d47bb02 20112 lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"
da0f6381
PB
20113fi
20114
20115
20116fi
20117
20118
20119fi
20120
20121
20122fi
20123
20124
20125fi
20126
20127
20128fi
20129
20130 ;;
20131 esac
20132
20133 if test "x$lt_cv_dlopen" != xno; then
20134 enable_dlopen=yes
20135 else
20136 enable_dlopen=no
20137 fi
20138
20139 case $lt_cv_dlopen in
20140 dlopen)
20141 save_CPPFLAGS="$CPPFLAGS"
20142 test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
20143
20144 save_LDFLAGS="$LDFLAGS"
20145 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
20146
20147 save_LIBS="$LIBS"
20148 LIBS="$lt_cv_dlopen_libs $LIBS"
20149
20150 echo "$as_me:$LINENO: checking whether a program can dlopen itself" >&5
20151echo $ECHO_N "checking whether a program can dlopen itself... $ECHO_C" >&6
20152if test "${lt_cv_dlopen_self+set}" = set; then
20153 echo $ECHO_N "(cached) $ECHO_C" >&6
20154else
20155 if test "$cross_compiling" = yes; then :
20156 lt_cv_dlopen_self=cross
20157else
20158 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
20159 lt_status=$lt_dlunknown
20160 cat > conftest.$ac_ext <<_LT_EOF
cd533689 20161#line 20161 "configure"
da0f6381
PB
20162#include "confdefs.h"
20163
20164#if HAVE_DLFCN_H
20165#include <dlfcn.h>
20166#endif
20167
20168#include <stdio.h>
20169
20170#ifdef RTLD_GLOBAL
20171# define LT_DLGLOBAL RTLD_GLOBAL
20172#else
20173# ifdef DL_GLOBAL
20174# define LT_DLGLOBAL DL_GLOBAL
20175# else
20176# define LT_DLGLOBAL 0
20177# endif
20178#endif
20179
20180/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
20181 find out it does not work in some platform. */
20182#ifndef LT_DLLAZY_OR_NOW
20183# ifdef RTLD_LAZY
20184# define LT_DLLAZY_OR_NOW RTLD_LAZY
20185# else
20186# ifdef DL_LAZY
20187# define LT_DLLAZY_OR_NOW DL_LAZY
20188# else
20189# ifdef RTLD_NOW
20190# define LT_DLLAZY_OR_NOW RTLD_NOW
20191# else
20192# ifdef DL_NOW
20193# define LT_DLLAZY_OR_NOW DL_NOW
20194# else
20195# define LT_DLLAZY_OR_NOW 0
20196# endif
20197# endif
20198# endif
20199# endif
20200#endif
20201
da0f6381
PB
20202void fnord() { int i=42;}
20203int main ()
20204{
20205 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
20206 int status = $lt_dlunknown;
20207
20208 if (self)
20209 {
20210 if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
20211 else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
20212 /* dlclose (self); */
20213 }
20214 else
20215 puts (dlerror ());
20216
5d47bb02 20217 return status;
da0f6381
PB
20218}
20219_LT_EOF
20220 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20221 (eval $ac_link) 2>&5
20222 ac_status=$?
20223 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20224 (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then
20225 (./conftest; exit; ) >&5 2>/dev/null
20226 lt_status=$?
20227 case x$lt_status in
20228 x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
20229 x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
20230 x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;;
20231 esac
20232 else :
20233 # compilation failed
20234 lt_cv_dlopen_self=no
20235 fi
20236fi
20237rm -fr conftest*
20238
20239
20240fi
20241echo "$as_me:$LINENO: result: $lt_cv_dlopen_self" >&5
20242echo "${ECHO_T}$lt_cv_dlopen_self" >&6
20243
20244 if test "x$lt_cv_dlopen_self" = xyes; then
20245 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
20246 echo "$as_me:$LINENO: checking whether a statically linked program can dlopen itself" >&5
20247echo $ECHO_N "checking whether a statically linked program can dlopen itself... $ECHO_C" >&6
20248if test "${lt_cv_dlopen_self_static+set}" = set; then
20249 echo $ECHO_N "(cached) $ECHO_C" >&6
20250else
20251 if test "$cross_compiling" = yes; then :
20252 lt_cv_dlopen_self_static=cross
20253else
20254 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
20255 lt_status=$lt_dlunknown
20256 cat > conftest.$ac_ext <<_LT_EOF
cd533689 20257#line 20257 "configure"
da0f6381
PB
20258#include "confdefs.h"
20259
20260#if HAVE_DLFCN_H
20261#include <dlfcn.h>
20262#endif
20263
20264#include <stdio.h>
20265
20266#ifdef RTLD_GLOBAL
20267# define LT_DLGLOBAL RTLD_GLOBAL
20268#else
20269# ifdef DL_GLOBAL
20270# define LT_DLGLOBAL DL_GLOBAL
20271# else
20272# define LT_DLGLOBAL 0
20273# endif
20274#endif
20275
20276/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
20277 find out it does not work in some platform. */
20278#ifndef LT_DLLAZY_OR_NOW
20279# ifdef RTLD_LAZY
20280# define LT_DLLAZY_OR_NOW RTLD_LAZY
20281# else
20282# ifdef DL_LAZY
20283# define LT_DLLAZY_OR_NOW DL_LAZY
20284# else
20285# ifdef RTLD_NOW
20286# define LT_DLLAZY_OR_NOW RTLD_NOW
20287# else
20288# ifdef DL_NOW
20289# define LT_DLLAZY_OR_NOW DL_NOW
20290# else
20291# define LT_DLLAZY_OR_NOW 0
20292# endif
20293# endif
20294# endif
20295# endif
20296#endif
20297
da0f6381
PB
20298void fnord() { int i=42;}
20299int main ()
20300{
20301 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
20302 int status = $lt_dlunknown;
20303
20304 if (self)
20305 {
20306 if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
20307 else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
20308 /* dlclose (self); */
20309 }
20310 else
20311 puts (dlerror ());
20312
5d47bb02 20313 return status;
da0f6381
PB
20314}
20315_LT_EOF
20316 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20317 (eval $ac_link) 2>&5
20318 ac_status=$?
20319 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20320 (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then
20321 (./conftest; exit; ) >&5 2>/dev/null
20322 lt_status=$?
20323 case x$lt_status in
20324 x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
20325 x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
20326 x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;;
20327 esac
20328 else :
20329 # compilation failed
20330 lt_cv_dlopen_self_static=no
20331 fi
20332fi
20333rm -fr conftest*
20334
20335
20336fi
20337echo "$as_me:$LINENO: result: $lt_cv_dlopen_self_static" >&5
20338echo "${ECHO_T}$lt_cv_dlopen_self_static" >&6
20339 fi
20340
20341 CPPFLAGS="$save_CPPFLAGS"
20342 LDFLAGS="$save_LDFLAGS"
20343 LIBS="$save_LIBS"
20344 ;;
20345 esac
20346
20347 case $lt_cv_dlopen_self in
20348 yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
20349 *) enable_dlopen_self=unknown ;;
20350 esac
20351
20352 case $lt_cv_dlopen_self_static in
20353 yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
20354 *) enable_dlopen_self_static=unknown ;;
20355 esac
20356fi
20357
20358
20359
20360
20361
20362
20363
20364
20365
20366
20367
20368
20369
20370
20371
20372
20373
20374striplib=
20375old_striplib=
20376echo "$as_me:$LINENO: checking whether stripping libraries is possible" >&5
20377echo $ECHO_N "checking whether stripping libraries is possible... $ECHO_C" >&6
20378if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
20379 test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
20380 test -z "$striplib" && striplib="$STRIP --strip-unneeded"
20381 echo "$as_me:$LINENO: result: yes" >&5
20382echo "${ECHO_T}yes" >&6
20383else
20384# FIXME - insert some real tests, host_os isn't really good enough
20385 case $host_os in
20386 darwin*)
20387 if test -n "$STRIP" ; then
20388 striplib="$STRIP -x"
20389 old_striplib="$STRIP -S"
20390 echo "$as_me:$LINENO: result: yes" >&5
20391echo "${ECHO_T}yes" >&6
20392 else
20393 echo "$as_me:$LINENO: result: no" >&5
20394echo "${ECHO_T}no" >&6
20395 fi
20396 ;;
20397 *)
20398 echo "$as_me:$LINENO: result: no" >&5
20399echo "${ECHO_T}no" >&6
20400 ;;
20401 esac
20402fi
20403
20404
20405
20406
20407
20408
20409
20410
20411
20412
20413
20414
20415 # Report which library types will actually be built
20416 echo "$as_me:$LINENO: checking if libtool supports shared libraries" >&5
20417echo $ECHO_N "checking if libtool supports shared libraries... $ECHO_C" >&6
20418 echo "$as_me:$LINENO: result: $can_build_shared" >&5
20419echo "${ECHO_T}$can_build_shared" >&6
20420
20421 echo "$as_me:$LINENO: checking whether to build shared libraries" >&5
20422echo $ECHO_N "checking whether to build shared libraries... $ECHO_C" >&6
20423 test "$can_build_shared" = "no" && enable_shared=no
20424
20425 # On AIX, shared libraries and static libraries use the same namespace, and
20426 # are all built from PIC.
20427 case $host_os in
20428 aix3*)
20429 test "$enable_shared" = yes && enable_static=no
20430 if test -n "$RANLIB"; then
20431 archive_cmds="$archive_cmds~\$RANLIB \$lib"
20432 postinstall_cmds='$RANLIB $lib'
20433 fi
20434 ;;
20435
20436 aix[4-9]*)
20437 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
20438 test "$enable_shared" = yes && enable_static=no
20439 fi
20440 ;;
20441 esac
20442 echo "$as_me:$LINENO: result: $enable_shared" >&5
20443echo "${ECHO_T}$enable_shared" >&6
20444
20445 echo "$as_me:$LINENO: checking whether to build static libraries" >&5
20446echo $ECHO_N "checking whether to build static libraries... $ECHO_C" >&6
20447 # Make sure either enable_shared or enable_static is yes.
20448 test "$enable_shared" = yes || enable_static=yes
20449 echo "$as_me:$LINENO: result: $enable_static" >&5
20450echo "${ECHO_T}$enable_static" >&6
20451
20452
20453
20454
20455fi
20456ac_ext=c
20457ac_cpp='$CPP $CPPFLAGS'
20458ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
20459ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
20460ac_compiler_gnu=$ac_cv_c_compiler_gnu
20461
20462CC="$lt_save_CC"
20463
20464
20465
20466
20467
20468
20469
20470
20471
20472
20473
20474
20475
20476
20477
20478
20479# Only expand once:
20480
20481
20482
20483
20484
20485# Identify the assembler which will work hand-in-glove with the newly
20486# built GCC, so that we can examine its features. This is the assembler
20487# which will be driven by the driver program.
20488#
20489# If build != host, and we aren't building gas in-tree, we identify a
20490# build->target assembler and hope that it will have the same features
20491# as the host->target assembler we'll be using.
20492gcc_cv_gas_major_version=
20493gcc_cv_gas_minor_version=
20494gcc_cv_as_gas_srcdir=`echo $srcdir | sed -e 's,/gcc$,,'`/gas
20495
20496if test "${gcc_cv_as+set}" = set; then
20497 :
20498else
20499
20500if test -x "$DEFAULT_ASSEMBLER"; then
20501 gcc_cv_as="$DEFAULT_ASSEMBLER"
20502elif test -f $gcc_cv_as_gas_srcdir/configure.in \
20503 && test -f ../gas/Makefile \
20504 && test x$build = x$host; then
20505 gcc_cv_as=../gas/as-new$build_exeext
20506elif test -x as$build_exeext; then
20507 # Build using assembler in the current directory.
20508 gcc_cv_as=./as$build_exeext
20509elif test -x $AS_FOR_TARGET; then
20510 gcc_cv_as="$AS_FOR_TARGET"
20511else
20512 # Extract the first word of "$AS_FOR_TARGET", so it can be a program name with args.
20513set dummy $AS_FOR_TARGET; ac_word=$2
20514echo "$as_me:$LINENO: checking for $ac_word" >&5
20515echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
20516if test "${ac_cv_path_gcc_cv_as+set}" = set; then
20517 echo $ECHO_N "(cached) $ECHO_C" >&6
20518else
20519 case $gcc_cv_as in
20520 [\\/]* | ?:[\\/]*)
20521 ac_cv_path_gcc_cv_as="$gcc_cv_as" # Let the user override the test with a path.
20522 ;;
20523 *)
20524 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
20525for as_dir in $PATH
20526do
20527 IFS=$as_save_IFS
20528 test -z "$as_dir" && as_dir=.
20529 for ac_exec_ext in '' $ac_executable_extensions; do
20530 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
20531 ac_cv_path_gcc_cv_as="$as_dir/$ac_word$ac_exec_ext"
20532 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
20533 break 2
20534 fi
20535done
20536done
20537
20538 ;;
20539esac
20540fi
20541gcc_cv_as=$ac_cv_path_gcc_cv_as
20542
20543if test -n "$gcc_cv_as"; then
20544 echo "$as_me:$LINENO: result: $gcc_cv_as" >&5
20545echo "${ECHO_T}$gcc_cv_as" >&6
20546else
20547 echo "$as_me:$LINENO: result: no" >&5
20548echo "${ECHO_T}no" >&6
20549fi
20550
20551fi
20552fi
20553
20554
20555ORIGINAL_AS_FOR_TARGET=$gcc_cv_as
20556
20557case "$ORIGINAL_AS_FOR_TARGET" in
20558 ./as | ./as$build_exeext) ;;
20559 *) ac_config_files="$ac_config_files as:exec-tool.in"
20560 ;;
20561esac
20562
20563echo "$as_me:$LINENO: checking what assembler to use" >&5
20564echo $ECHO_N "checking what assembler to use... $ECHO_C" >&6
20565if test "$gcc_cv_as" = ../gas/as-new$build_exeext; then
20566 # Single tree build which includes gas. We want to prefer it
20567 # over whatever linker top-level may have detected, since
20568 # we'll use what we're building after installation anyway.
20569 echo "$as_me:$LINENO: result: newly built gas" >&5
20570echo "${ECHO_T}newly built gas" >&6
20571 in_tree_gas=yes
20572 gcc_cv_as_bfd_srcdir=`echo $srcdir | sed -e 's,/gcc$,,'`/bfd
20573for f in $gcc_cv_as_bfd_srcdir/configure \
20574 $gcc_cv_as_gas_srcdir/configure \
20575 $gcc_cv_as_gas_srcdir/configure.in \
20576 $gcc_cv_as_gas_srcdir/Makefile.in ; do
20577 gcc_cv_gas_version=`sed -n -e 's/^[ ]*\(VERSION=[0-9]*\.[0-9]*.*\)/\1/p' < $f`
20578 if test x$gcc_cv_gas_version != x; then
20579 break
20580 fi
20581done
20582gcc_cv_gas_major_version=`expr "$gcc_cv_gas_version" : "VERSION=\([0-9]*\)"`
20583gcc_cv_gas_minor_version=`expr "$gcc_cv_gas_version" : "VERSION=[0-9]*\.\([0-9]*\)"`
20584gcc_cv_gas_patch_version=`expr "$gcc_cv_gas_version" : "VERSION=[0-9]*\.[0-9]*\.\([0-9]*\)"`
20585case $gcc_cv_gas_patch_version in
20586 "") gcc_cv_gas_patch_version="0" ;;
20587esac
20588gcc_cv_gas_vers=`expr \( \( $gcc_cv_gas_major_version \* 1000 \) \
20589 + $gcc_cv_gas_minor_version \) \* 1000 \
20590 + $gcc_cv_gas_patch_version`
20591
20592 in_tree_gas_is_elf=no
20593 if grep 'obj_format = elf' ../gas/Makefile > /dev/null \
20594 || (grep 'obj_format = multi' ../gas/Makefile \
20595 && grep 'extra_objects =.* obj-elf' ../gas/Makefile) > /dev/null
20596 then
20597 in_tree_gas_is_elf=yes
20598 fi
20599else
20600 echo "$as_me:$LINENO: result: $gcc_cv_as" >&5
20601echo "${ECHO_T}$gcc_cv_as" >&6
20602 in_tree_gas=no
20603fi
20604
20605# Identify the linker which will work hand-in-glove with the newly
20606# built GCC, so that we can examine its features. This is the linker
20607# which will be driven by the driver program.
20608#
20609# If build != host, and we aren't building gas in-tree, we identify a
20610# build->target linker and hope that it will have the same features
20611# as the host->target linker we'll be using.
20612gcc_cv_gld_major_version=
20613gcc_cv_gld_minor_version=
20614gcc_cv_ld_gld_srcdir=`echo $srcdir | sed -e 's,/gcc$,,'`/ld
20615gcc_cv_ld_bfd_srcdir=`echo $srcdir | sed -e 's,/gcc$,,'`/bfd
20616
20617if test "${gcc_cv_ld+set}" = set; then
20618 :
20619else
20620
20621if test -x "$DEFAULT_LINKER"; then
20622 gcc_cv_ld="$DEFAULT_LINKER"
20623elif test -f $gcc_cv_ld_gld_srcdir/configure.in \
20624 && test -f ../ld/Makefile \
20625 && test x$build = x$host; then
20626 gcc_cv_ld=../ld/ld-new$build_exeext
e8b05380
PB
20627elif test -x collect-ld$build_exeext; then
20628 # Build using linker in the current directory.
20629 gcc_cv_ld=./collect-ld$build_exeext
20630elif test -x $LD_FOR_TARGET; then
20631 gcc_cv_ld="$LD_FOR_TARGET"
20632else
20633 # Extract the first word of "$LD_FOR_TARGET", so it can be a program name with args.
20634set dummy $LD_FOR_TARGET; ac_word=$2
b61ff9c8
BS
20635echo "$as_me:$LINENO: checking for $ac_word" >&5
20636echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
e8b05380 20637if test "${ac_cv_path_gcc_cv_ld+set}" = set; then
d739199a
DJ
20638 echo $ECHO_N "(cached) $ECHO_C" >&6
20639else
e8b05380 20640 case $gcc_cv_ld in
d739199a 20641 [\\/]* | ?:[\\/]*)
e8b05380 20642 ac_cv_path_gcc_cv_ld="$gcc_cv_ld" # Let the user override the test with a path.
d739199a
DJ
20643 ;;
20644 *)
20645 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
20646for as_dir in $PATH
20647do
20648 IFS=$as_save_IFS
20649 test -z "$as_dir" && as_dir=.
20650 for ac_exec_ext in '' $ac_executable_extensions; do
b61ff9c8 20651 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
e8b05380 20652 ac_cv_path_gcc_cv_ld="$as_dir/$ac_word$ac_exec_ext"
d739199a
DJ
20653 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
20654 break 2
20655 fi
20656done
20657done
20658
20659 ;;
20660esac
20661fi
e8b05380 20662gcc_cv_ld=$ac_cv_path_gcc_cv_ld
b61ff9c8 20663
e8b05380 20664if test -n "$gcc_cv_ld"; then
b61ff9c8
BS
20665 echo "$as_me:$LINENO: result: $gcc_cv_ld" >&5
20666echo "${ECHO_T}$gcc_cv_ld" >&6
d739199a 20667else
b61ff9c8
BS
20668 echo "$as_me:$LINENO: result: no" >&5
20669echo "${ECHO_T}no" >&6
d739199a
DJ
20670fi
20671
20672fi
e8b05380
PB
20673fi
20674
20675
20676ORIGINAL_LD_FOR_TARGET=$gcc_cv_ld
20677
be0fe523
PB
20678case "$ORIGINAL_LD_FOR_TARGET" in
20679 ./collect-ld | ./collect-ld$build_exeext) ;;
b61ff9c8 20680 *) ac_config_files="$ac_config_files collect-ld:exec-tool.in"
be0fe523
PB
20681 ;;
20682esac
e8b05380 20683
b61ff9c8
BS
20684echo "$as_me:$LINENO: checking what linker to use" >&5
20685echo $ECHO_N "checking what linker to use... $ECHO_C" >&6
e8b05380
PB
20686if test "$gcc_cv_ld" = ../ld/ld-new$build_exeext; then
20687 # Single tree build which includes ld. We want to prefer it
20688 # over whatever linker top-level may have detected, since
20689 # we'll use what we're building after installation anyway.
b61ff9c8
BS
20690 echo "$as_me:$LINENO: result: newly built ld" >&5
20691echo "${ECHO_T}newly built ld" >&6
e8b05380
PB
20692 in_tree_ld=yes
20693 in_tree_ld_is_elf=no
20694 if (grep 'EMUL = .*elf' ../ld/Makefile \
20695 || grep 'EMUL = .*linux' ../ld/Makefile \
20696 || grep 'EMUL = .*lynx' ../ld/Makefile) > /dev/null; then
20697 in_tree_ld_is_elf=yes
20698 fi
20699 for f in $gcc_cv_ld_bfd_srcdir/configure $gcc_cv_ld_gld_srcdir/configure $gcc_cv_ld_gld_srcdir/configure.in $gcc_cv_ld_gld_srcdir/Makefile.in
20700 do
20701 gcc_cv_gld_version=`sed -n -e 's/^[ ]*\(VERSION=[0-9]*\.[0-9]*.*\)/\1/p' < $f`
20702 if test x$gcc_cv_gld_version != x; then
20703 break
20704 fi
20705 done
20706 gcc_cv_gld_major_version=`expr "$gcc_cv_gld_version" : "VERSION=\([0-9]*\)"`
20707 gcc_cv_gld_minor_version=`expr "$gcc_cv_gld_version" : "VERSION=[0-9]*\.\([0-9]*\)"`
20708else
b61ff9c8
BS
20709 echo "$as_me:$LINENO: result: $gcc_cv_ld" >&5
20710echo "${ECHO_T}$gcc_cv_ld" >&6
e8b05380
PB
20711 in_tree_ld=no
20712fi
20713
20714# Figure out what nm we will be using.
20715gcc_cv_binutils_srcdir=`echo $srcdir | sed -e 's,/gcc$,,'`/binutils
20716if test "${gcc_cv_nm+set}" = set; then
20717 :
20718else
20719
20720if test -f $gcc_cv_binutils_srcdir/configure.in \
c15b113b
DD
20721 && test -f ../binutils/Makefile \
20722 && test x$build = x$host; then
e8b05380
PB
20723 gcc_cv_nm=../binutils/nm-new$build_exeext
20724elif test -x nm$build_exeext; then
20725 gcc_cv_nm=./nm$build_exeext
20726elif test -x $NM_FOR_TARGET; then
20727 gcc_cv_nm="$NM_FOR_TARGET"
20728else
20729 # Extract the first word of "$NM_FOR_TARGET", so it can be a program name with args.
20730set dummy $NM_FOR_TARGET; ac_word=$2
b61ff9c8
BS
20731echo "$as_me:$LINENO: checking for $ac_word" >&5
20732echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
e8b05380 20733if test "${ac_cv_path_gcc_cv_nm+set}" = set; then
d739199a
DJ
20734 echo $ECHO_N "(cached) $ECHO_C" >&6
20735else
e8b05380 20736 case $gcc_cv_nm in
d739199a 20737 [\\/]* | ?:[\\/]*)
e8b05380 20738 ac_cv_path_gcc_cv_nm="$gcc_cv_nm" # Let the user override the test with a path.
d739199a
DJ
20739 ;;
20740 *)
20741 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
20742for as_dir in $PATH
20743do
20744 IFS=$as_save_IFS
20745 test -z "$as_dir" && as_dir=.
20746 for ac_exec_ext in '' $ac_executable_extensions; do
b61ff9c8 20747 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
e8b05380 20748 ac_cv_path_gcc_cv_nm="$as_dir/$ac_word$ac_exec_ext"
d739199a
DJ
20749 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
20750 break 2
20751 fi
20752done
20753done
20754
20755 ;;
20756esac
20757fi
e8b05380 20758gcc_cv_nm=$ac_cv_path_gcc_cv_nm
b61ff9c8 20759
e8b05380 20760if test -n "$gcc_cv_nm"; then
b61ff9c8
BS
20761 echo "$as_me:$LINENO: result: $gcc_cv_nm" >&5
20762echo "${ECHO_T}$gcc_cv_nm" >&6
d739199a 20763else
b61ff9c8
BS
20764 echo "$as_me:$LINENO: result: no" >&5
20765echo "${ECHO_T}no" >&6
d739199a
DJ
20766fi
20767
20768fi
e8b05380 20769fi
d739199a 20770
e8b05380 20771
b61ff9c8
BS
20772echo "$as_me:$LINENO: checking what nm to use" >&5
20773echo $ECHO_N "checking what nm to use... $ECHO_C" >&6
e8b05380
PB
20774if test "$gcc_cv_nm" = ../binutils/nm-new$build_exeext; then
20775 # Single tree build which includes binutils.
b61ff9c8
BS
20776 echo "$as_me:$LINENO: result: newly built nm" >&5
20777echo "${ECHO_T}newly built nm" >&6
e8b05380
PB
20778 in_tree_nm=yes
20779else
b61ff9c8
BS
20780 echo "$as_me:$LINENO: result: $gcc_cv_nm" >&5
20781echo "${ECHO_T}$gcc_cv_nm" >&6
e8b05380
PB
20782 in_tree_nm=no
20783fi
20784
20785ORIGINAL_NM_FOR_TARGET=$gcc_cv_nm
20786
be0fe523
PB
20787case "$ORIGINAL_NM_FOR_TARGET" in
20788 ./nm | ./nm$build_exeext) ;;
b61ff9c8 20789 *) ac_config_files="$ac_config_files nm:exec-tool.in"
be0fe523
PB
20790 ;;
20791esac
20792
e8b05380
PB
20793
20794# Figure out what objdump we will be using.
20795if test "${gcc_cv_objdump+set}" = set; then
20796 :
20797else
20798
20799if test -f $gcc_cv_binutils_srcdir/configure.in \
c15b113b
DD
20800 && test -f ../binutils/Makefile \
20801 && test x$build = x$host; then
e8b05380
PB
20802 # Single tree build which includes binutils.
20803 gcc_cv_objdump=../binutils/objdump$build_exeext
20804elif test -x objdump$build_exeext; then
20805 gcc_cv_objdump=./objdump$build_exeext
20806elif test -x $OBJDUMP_FOR_TARGET; then
20807 gcc_cv_objdump="$OBJDUMP_FOR_TARGET"
20808else
20809 # Extract the first word of "$OBJDUMP_FOR_TARGET", so it can be a program name with args.
20810set dummy $OBJDUMP_FOR_TARGET; ac_word=$2
b61ff9c8
BS
20811echo "$as_me:$LINENO: checking for $ac_word" >&5
20812echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
e8b05380 20813if test "${ac_cv_path_gcc_cv_objdump+set}" = set; then
9f18db39
PB
20814 echo $ECHO_N "(cached) $ECHO_C" >&6
20815else
e8b05380 20816 case $gcc_cv_objdump in
9f18db39 20817 [\\/]* | ?:[\\/]*)
e8b05380 20818 ac_cv_path_gcc_cv_objdump="$gcc_cv_objdump" # Let the user override the test with a path.
9f18db39
PB
20819 ;;
20820 *)
20821 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
e8b05380 20822for as_dir in $PATH
9f18db39
PB
20823do
20824 IFS=$as_save_IFS
20825 test -z "$as_dir" && as_dir=.
20826 for ac_exec_ext in '' $ac_executable_extensions; do
b61ff9c8 20827 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
e8b05380 20828 ac_cv_path_gcc_cv_objdump="$as_dir/$ac_word$ac_exec_ext"
9f18db39
PB
20829 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
20830 break 2
20831 fi
20832done
20833done
779243f7 20834
9f18db39
PB
20835 ;;
20836esac
20837fi
e8b05380 20838gcc_cv_objdump=$ac_cv_path_gcc_cv_objdump
b61ff9c8 20839
e8b05380 20840if test -n "$gcc_cv_objdump"; then
b61ff9c8
BS
20841 echo "$as_me:$LINENO: result: $gcc_cv_objdump" >&5
20842echo "${ECHO_T}$gcc_cv_objdump" >&6
9f18db39 20843else
b61ff9c8
BS
20844 echo "$as_me:$LINENO: result: no" >&5
20845echo "${ECHO_T}no" >&6
9f18db39
PB
20846fi
20847
e8b05380
PB
20848fi
20849fi
9f18db39 20850
e8b05380 20851
b61ff9c8
BS
20852echo "$as_me:$LINENO: checking what objdump to use" >&5
20853echo $ECHO_N "checking what objdump to use... $ECHO_C" >&6
e8b05380
PB
20854if test "$gcc_cv_objdump" = ../binutils/objdump$build_exeext; then
20855 # Single tree build which includes binutils.
b61ff9c8
BS
20856 echo "$as_me:$LINENO: result: newly built objdump" >&5
20857echo "${ECHO_T}newly built objdump" >&6
e8b05380 20858elif test x$gcc_cv_objdump = x; then
b61ff9c8
BS
20859 echo "$as_me:$LINENO: result: not found" >&5
20860echo "${ECHO_T}not found" >&6
e8b05380 20861else
b61ff9c8
BS
20862 echo "$as_me:$LINENO: result: $gcc_cv_objdump" >&5
20863echo "${ECHO_T}$gcc_cv_objdump" >&6
a2eafc76 20864fi
3cae5780 20865
6e97481b
JJ
20866# Figure out what readelf we will be using.
20867if test "${gcc_cv_readelf+set}" = set; then
20868 :
20869else
20870
20871if test -f $gcc_cv_binutils_srcdir/configure.in \
20872 && test -f ../binutils/Makefile \
20873 && test x$build = x$host; then
20874 # Single tree build which includes binutils.
20875 gcc_cv_readelf=../binutils/readelf$build_exeext
20876elif test -x readelf$build_exeext; then
20877 gcc_cv_readelf=./readelf$build_exeext
20878else
20879 # Extract the first word of "readelf", so it can be a program name with args.
20880set dummy readelf; ac_word=$2
20881echo "$as_me:$LINENO: checking for $ac_word" >&5
20882echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
20883if test "${ac_cv_path_gcc_cv_readelf+set}" = set; then
20884 echo $ECHO_N "(cached) $ECHO_C" >&6
20885else
20886 case $gcc_cv_readelf in
20887 [\\/]* | ?:[\\/]*)
20888 ac_cv_path_gcc_cv_readelf="$gcc_cv_readelf" # Let the user override the test with a path.
20889 ;;
20890 *)
20891 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
20892for as_dir in $PATH
20893do
20894 IFS=$as_save_IFS
20895 test -z "$as_dir" && as_dir=.
20896 for ac_exec_ext in '' $ac_executable_extensions; do
20897 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
20898 ac_cv_path_gcc_cv_readelf="$as_dir/$ac_word$ac_exec_ext"
20899 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
20900 break 2
20901 fi
20902done
20903done
20904
20905 ;;
20906esac
20907fi
20908gcc_cv_readelf=$ac_cv_path_gcc_cv_readelf
20909
20910if test -n "$gcc_cv_readelf"; then
20911 echo "$as_me:$LINENO: result: $gcc_cv_readelf" >&5
20912echo "${ECHO_T}$gcc_cv_readelf" >&6
20913else
20914 echo "$as_me:$LINENO: result: no" >&5
20915echo "${ECHO_T}no" >&6
20916fi
20917
20918fi
20919fi
20920
20921
20922echo "$as_me:$LINENO: checking what readelf to use" >&5
20923echo $ECHO_N "checking what readelf to use... $ECHO_C" >&6
20924if test "$gcc_cv_readelf" = ../binutils/readelf$build_exeext; then
20925 # Single tree build which includes binutils.
20926 echo "$as_me:$LINENO: result: newly built readelf" >&5
20927echo "${ECHO_T}newly built readelf" >&6
20928elif test x$gcc_cv_readelf = x; then
20929 echo "$as_me:$LINENO: result: not found" >&5
20930echo "${ECHO_T}not found" >&6
20931else
20932 echo "$as_me:$LINENO: result: $gcc_cv_readelf" >&5
20933echo "${ECHO_T}$gcc_cv_readelf" >&6
20934fi
20935
981d4858 20936# Figure out what assembler alignment features are present.
b61ff9c8
BS
20937echo "$as_me:$LINENO: checking assembler for .balign and .p2align" >&5
20938echo $ECHO_N "checking assembler for .balign and .p2align... $ECHO_C" >&6
ba479fd2
NN
20939if test "${gcc_cv_as_balign_and_p2align+set}" = set; then
20940 echo $ECHO_N "(cached) $ECHO_C" >&6
8ada417f
ZW
20941else
20942 gcc_cv_as_balign_and_p2align=no
20943 if test $in_tree_gas = yes; then
20944 if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 6 \) \* 1000 + 0`
20945 then gcc_cv_as_balign_and_p2align=yes
20946fi
20947 elif test x$gcc_cv_as != x; then
6e3f3080 20948 echo '.balign 4
8ada417f 20949.p2align 2' > conftest.s
ba479fd2
NN
20950 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
20951 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20952 (eval $ac_try) 2>&5
20953 ac_status=$?
20954 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20955 (exit $ac_status); }; }
8ada417f
ZW
20956 then
20957 gcc_cv_as_balign_and_p2align=yes
20958 else
20959 echo "configure: failed program was" >&5
20960 cat conftest.s >&5
20961 fi
20962 rm -f conftest.o conftest.s
20963 fi
20964fi
b61ff9c8
BS
20965echo "$as_me:$LINENO: result: $gcc_cv_as_balign_and_p2align" >&5
20966echo "${ECHO_T}$gcc_cv_as_balign_and_p2align" >&6
63cf211a 20967if test $gcc_cv_as_balign_and_p2align = yes; then
ba479fd2
NN
20968
20969cat >>confdefs.h <<\_ACEOF
981d4858 20970#define HAVE_GAS_BALIGN_AND_P2ALIGN 1
ba479fd2 20971_ACEOF
981d4858 20972
ad9c4d9f
NN
20973fi
20974
b61ff9c8
BS
20975echo "$as_me:$LINENO: checking assembler for .p2align with maximum skip" >&5
20976echo $ECHO_N "checking assembler for .p2align with maximum skip... $ECHO_C" >&6
ba479fd2
NN
20977if test "${gcc_cv_as_max_skip_p2align+set}" = set; then
20978 echo $ECHO_N "(cached) $ECHO_C" >&6
8ada417f
ZW
20979else
20980 gcc_cv_as_max_skip_p2align=no
20981 if test $in_tree_gas = yes; then
20982 if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 8 \) \* 1000 + 0`
20983 then gcc_cv_as_max_skip_p2align=yes
20984fi
20985 elif test x$gcc_cv_as != x; then
6e3f3080 20986 echo '.p2align 4,,7' > conftest.s
ba479fd2
NN
20987 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
20988 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20989 (eval $ac_try) 2>&5
20990 ac_status=$?
20991 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20992 (exit $ac_status); }; }
8ada417f
ZW
20993 then
20994 gcc_cv_as_max_skip_p2align=yes
20995 else
20996 echo "configure: failed program was" >&5
20997 cat conftest.s >&5
20998 fi
20999 rm -f conftest.o conftest.s
21000 fi
ad9c4d9f 21001fi
b61ff9c8
BS
21002echo "$as_me:$LINENO: result: $gcc_cv_as_max_skip_p2align" >&5
21003echo "${ECHO_T}$gcc_cv_as_max_skip_p2align" >&6
63cf211a 21004if test $gcc_cv_as_max_skip_p2align = yes; then
ba479fd2
NN
21005
21006cat >>confdefs.h <<\_ACEOF
9e423e6d 21007#define HAVE_GAS_MAX_SKIP_P2ALIGN 1
ba479fd2 21008_ACEOF
9e423e6d 21009
9e423e6d 21010fi
ad9c4d9f 21011
b61ff9c8
BS
21012echo "$as_me:$LINENO: checking assembler for .literal16" >&5
21013echo $ECHO_N "checking assembler for .literal16... $ECHO_C" >&6
5708d18d
MS
21014if test "${gcc_cv_as_literal16+set}" = set; then
21015 echo $ECHO_N "(cached) $ECHO_C" >&6
21016else
21017 gcc_cv_as_literal16=no
21018 if test $in_tree_gas = yes; then
21019 if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 8 \) \* 1000 + 0`
21020 then gcc_cv_as_literal16=yes
21021fi
21022 elif test x$gcc_cv_as != x; then
21023 echo '.literal16' > conftest.s
21024 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
21025 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21026 (eval $ac_try) 2>&5
21027 ac_status=$?
21028 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21029 (exit $ac_status); }; }
21030 then
21031 gcc_cv_as_literal16=yes
21032 else
21033 echo "configure: failed program was" >&5
21034 cat conftest.s >&5
21035 fi
21036 rm -f conftest.o conftest.s
21037 fi
21038fi
b61ff9c8
BS
21039echo "$as_me:$LINENO: result: $gcc_cv_as_literal16" >&5
21040echo "${ECHO_T}$gcc_cv_as_literal16" >&6
5708d18d
MS
21041if test $gcc_cv_as_literal16 = yes; then
21042
21043cat >>confdefs.h <<\_ACEOF
21044#define HAVE_GAS_LITERAL16 1
21045_ACEOF
21046
21047fi
21048
b61ff9c8
BS
21049echo "$as_me:$LINENO: checking assembler for working .subsection -1" >&5
21050echo $ECHO_N "checking assembler for working .subsection -1... $ECHO_C" >&6
ba479fd2
NN
21051if test "${gcc_cv_as_subsection_m1+set}" = set; then
21052 echo $ECHO_N "(cached) $ECHO_C" >&6
8ada417f
ZW
21053else
21054 gcc_cv_as_subsection_m1=no
21055 if test $in_tree_gas = yes; then
21056 if test $in_tree_gas_is_elf = yes \
21057 && test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 9 \) \* 1000 + 0`
21058 then gcc_cv_as_subsection_m1=yes
ad9c4d9f 21059fi
8ada417f 21060 elif test x$gcc_cv_as != x; then
6e3f3080 21061 echo 'conftest_label1: .word 0
d1accaa3
JJ
21062.subsection -1
21063conftest_label2: .word 0
8ada417f 21064.previous' > conftest.s
ba479fd2
NN
21065 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
21066 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21067 (eval $ac_try) 2>&5
21068 ac_status=$?
21069 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21070 (exit $ac_status); }; }
8ada417f
ZW
21071 then
21072 if test x$gcc_cv_nm != x; then
21073 $gcc_cv_nm conftest.o | grep conftest_label1 > conftest.nm1
21074 $gcc_cv_nm conftest.o | grep conftest_label2 | sed -e 's/label2/label1/' > conftest.nm2
21075 if cmp conftest.nm1 conftest.nm2 > /dev/null 2>&1
21076 then :
21077 else gcc_cv_as_subsection_m1=yes
21078 fi
21079 rm -f conftest.nm1 conftest.nm2
21080 fi
21081 else
21082 echo "configure: failed program was" >&5
21083 cat conftest.s >&5
21084 fi
21085 rm -f conftest.o conftest.s
21086 fi
981d4858 21087fi
b61ff9c8
BS
21088echo "$as_me:$LINENO: result: $gcc_cv_as_subsection_m1" >&5
21089echo "${ECHO_T}$gcc_cv_as_subsection_m1" >&6
63cf211a 21090if test $gcc_cv_as_subsection_m1 = yes; then
ba479fd2
NN
21091
21092cat >>confdefs.h <<\_ACEOF
981d4858 21093#define HAVE_GAS_SUBSECTION_ORDERING 1
ba479fd2 21094_ACEOF
981d4858 21095
d1accaa3 21096fi
ad9c4d9f 21097
b61ff9c8
BS
21098echo "$as_me:$LINENO: checking assembler for .weak" >&5
21099echo $ECHO_N "checking assembler for .weak... $ECHO_C" >&6
ba479fd2
NN
21100if test "${gcc_cv_as_weak+set}" = set; then
21101 echo $ECHO_N "(cached) $ECHO_C" >&6
8ada417f
ZW
21102else
21103 gcc_cv_as_weak=no
21104 if test $in_tree_gas = yes; then
21105 if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 2 \) \* 1000 + 0`
21106 then gcc_cv_as_weak=yes
ad9c4d9f 21107fi
8ada417f 21108 elif test x$gcc_cv_as != x; then
6e3f3080 21109 echo ' .weak foobar' > conftest.s
ba479fd2
NN
21110 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
21111 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21112 (eval $ac_try) 2>&5
21113 ac_status=$?
21114 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21115 (exit $ac_status); }; }
8ada417f
ZW
21116 then
21117 gcc_cv_as_weak=yes
21118 else
21119 echo "configure: failed program was" >&5
21120 cat conftest.s >&5
21121 fi
21122 rm -f conftest.o conftest.s
21123 fi
981d4858 21124fi
b61ff9c8
BS
21125echo "$as_me:$LINENO: result: $gcc_cv_as_weak" >&5
21126echo "${ECHO_T}$gcc_cv_as_weak" >&6
63cf211a 21127if test $gcc_cv_as_weak = yes; then
ba479fd2
NN
21128
21129cat >>confdefs.h <<\_ACEOF
981d4858 21130#define HAVE_GAS_WEAK 1
ba479fd2 21131_ACEOF
981d4858 21132
12822146 21133fi
ad9c4d9f 21134
b61ff9c8
BS
21135echo "$as_me:$LINENO: checking assembler for .weakref" >&5
21136echo $ECHO_N "checking assembler for .weakref... $ECHO_C" >&6
a0203ca7
AO
21137if test "${gcc_cv_as_weakref+set}" = set; then
21138 echo $ECHO_N "(cached) $ECHO_C" >&6
21139else
21140 gcc_cv_as_weakref=no
21141 if test $in_tree_gas = yes; then
21142 if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 17 \) \* 1000 + 0`
21143 then gcc_cv_as_weakref=yes
21144fi
21145 elif test x$gcc_cv_as != x; then
21146 echo ' .weakref foobar, barfnot' > conftest.s
21147 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
21148 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21149 (eval $ac_try) 2>&5
21150 ac_status=$?
21151 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21152 (exit $ac_status); }; }
21153 then
21154 gcc_cv_as_weakref=yes
21155 else
21156 echo "configure: failed program was" >&5
21157 cat conftest.s >&5
21158 fi
21159 rm -f conftest.o conftest.s
21160 fi
21161fi
b61ff9c8
BS
21162echo "$as_me:$LINENO: result: $gcc_cv_as_weakref" >&5
21163echo "${ECHO_T}$gcc_cv_as_weakref" >&6
a0203ca7
AO
21164if test $gcc_cv_as_weakref = yes; then
21165
21166cat >>confdefs.h <<\_ACEOF
21167#define HAVE_GAS_WEAKREF 1
21168_ACEOF
21169
21170fi
21171
b61ff9c8
BS
21172echo "$as_me:$LINENO: checking assembler for .nsubspa comdat" >&5
21173echo $ECHO_N "checking assembler for .nsubspa comdat... $ECHO_C" >&6
e41f3691
JDA
21174if test "${gcc_cv_as_nsubspa_comdat+set}" = set; then
21175 echo $ECHO_N "(cached) $ECHO_C" >&6
21176else
21177 gcc_cv_as_nsubspa_comdat=no
21178 if test $in_tree_gas = yes; then
21179 if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 15 \) \* 1000 + 91`
21180 then gcc_cv_as_nsubspa_comdat=yes
21181fi
21182 elif test x$gcc_cv_as != x; then
21183 echo ' .SPACE $TEXT$
21184 .NSUBSPA $CODE$,COMDAT' > conftest.s
21185 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
21186 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21187 (eval $ac_try) 2>&5
21188 ac_status=$?
21189 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21190 (exit $ac_status); }; }
21191 then
21192 gcc_cv_as_nsubspa_comdat=yes
21193 else
21194 echo "configure: failed program was" >&5
21195 cat conftest.s >&5
21196 fi
21197 rm -f conftest.o conftest.s
21198 fi
21199fi
b61ff9c8
BS
21200echo "$as_me:$LINENO: result: $gcc_cv_as_nsubspa_comdat" >&5
21201echo "${ECHO_T}$gcc_cv_as_nsubspa_comdat" >&6
e41f3691
JDA
21202if test $gcc_cv_as_nsubspa_comdat = yes; then
21203
21204cat >>confdefs.h <<\_ACEOF
21205#define HAVE_GAS_NSUBSPA_COMDAT 1
21206_ACEOF
21207
21208fi
21209
8ada417f
ZW
21210# .hidden needs to be supported in both the assembler and the linker,
21211# because GNU LD versions before 2.12.1 have buggy support for STV_HIDDEN.
21212# This is irritatingly difficult to feature test for; we have to check the
21213# date string after the version number. If we've got an in-tree
21214# ld, we don't know its patchlevel version, so we set the baseline at 2.13
21215# to be safe.
21216# The gcc_GAS_CHECK_FEATURE call just sets a cache variable.
b61ff9c8
BS
21217echo "$as_me:$LINENO: checking assembler for .hidden" >&5
21218echo $ECHO_N "checking assembler for .hidden... $ECHO_C" >&6
ba479fd2
NN
21219if test "${gcc_cv_as_hidden+set}" = set; then
21220 echo $ECHO_N "(cached) $ECHO_C" >&6
8ada417f
ZW
21221else
21222 gcc_cv_as_hidden=no
21223 if test $in_tree_gas = yes; then
21224 if test $in_tree_gas_is_elf = yes \
21225 && test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 13 \) \* 1000 + 0`
21226 then gcc_cv_as_hidden=yes
21227fi
21228 elif test x$gcc_cv_as != x; then
6e3f3080 21229 echo ' .hidden foobar
8ada417f 21230foobar:' > conftest.s
ba479fd2
NN
21231 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
21232 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21233 (eval $ac_try) 2>&5
21234 ac_status=$?
21235 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21236 (exit $ac_status); }; }
8ada417f
ZW
21237 then
21238 gcc_cv_as_hidden=yes
21239 else
21240 echo "configure: failed program was" >&5
21241 cat conftest.s >&5
21242 fi
21243 rm -f conftest.o conftest.s
21244 fi
21245fi
b61ff9c8
BS
21246echo "$as_me:$LINENO: result: $gcc_cv_as_hidden" >&5
21247echo "${ECHO_T}$gcc_cv_as_hidden" >&6
63cf211a 21248
ad9c4d9f 21249
b61ff9c8
BS
21250echo "$as_me:$LINENO: checking linker for .hidden support" >&5
21251echo $ECHO_N "checking linker for .hidden support... $ECHO_C" >&6
ba479fd2
NN
21252if test "${gcc_cv_ld_hidden+set}" = set; then
21253 echo $ECHO_N "(cached) $ECHO_C" >&6
8ada417f
ZW
21254else
21255 if test $in_tree_ld = yes ; then
21256 gcc_cv_ld_hidden=no
21257 if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 13 -o "$gcc_cv_gld_major_version" -gt 2 \
21258 && test $in_tree_ld_is_elf = yes; then
21259 gcc_cv_ld_hidden=yes
21260 fi
21261else
21262 gcc_cv_ld_hidden=yes
bace148a 21263 ld_ver=`$gcc_cv_ld --version 2>/dev/null | sed 1q`
8ada417f
ZW
21264 if echo "$ld_ver" | grep GNU > /dev/null; then
21265 ld_vers=`echo $ld_ver | sed -n \
115e6e55 21266 -e 's,^.*[ ]\([0-9][0-9]*\.[0-9][0-9]*.*\)$,\1,p'`
8ada417f 21267 ld_date=`echo $ld_ver | sed -n 's,^.*\([2-9][0-9][0-9][0-9]\)[-]*\([01][0-9]\)[-]*\([0-3][0-9]\).*$,\1\2\3,p'`
11176d2a
JB
21268 ld_vers_major=`expr "$ld_vers" : '\([0-9]*\)'`
21269 ld_vers_minor=`expr "$ld_vers" : '[0-9]*\.\([0-9]*\)'`
21270 ld_vers_patch=`expr "$ld_vers" : '[0-9]*\.[0-9]*\.\([0-9]*\)'`
8ada417f
ZW
21271 if test 0"$ld_date" -lt 20020404; then
21272 if test -n "$ld_date"; then
21273 # If there was date string, but was earlier than 2002-04-04, fail
21274 gcc_cv_ld_hidden=no
21275 elif test -z "$ld_vers"; then
21276 # If there was no date string nor ld version number, something is wrong
21277 gcc_cv_ld_hidden=no
21278 else
8ada417f
ZW
21279 test -z "$ld_vers_patch" && ld_vers_patch=0
21280 if test "$ld_vers_major" -lt 2; then
21281 gcc_cv_ld_hidden=no
21282 elif test "$ld_vers_major" -eq 2 -a "$ld_vers_minor" -lt 12; then
21283 gcc_cv_ld_hidden="no"
21284 elif test "$ld_vers_major" -eq 2 -a "$ld_vers_minor" -eq 12 -a "$ld_vers_patch" -eq 0; then
21285 gcc_cv_ld_hidden=no
c72931a6 21286 fi
8ada417f 21287 fi
789b7de5 21288 fi
8ada417f 21289 else
28690784 21290 case "${target}" in
b0fd7d27 21291 hppa64*-*-hpux* | ia64*-*-hpux*)
28690784
JDA
21292 gcc_cv_ld_hidden=yes
21293 ;;
5e87dc23
RO
21294 *-*-solaris2.9* | *-*-solaris2.1[0-9]*)
21295 gcc_cv_ld_hidden=yes
21296 ;;
28690784
JDA
21297 *)
21298 gcc_cv_ld_hidden=no
21299 ;;
21300 esac
8ada417f
ZW
21301 fi
21302fi
6d07784a 21303fi
b61ff9c8
BS
21304echo "$as_me:$LINENO: result: $gcc_cv_ld_hidden" >&5
21305echo "${ECHO_T}$gcc_cv_ld_hidden" >&6
8ada417f 21306libgcc_visibility=no
ad9c4d9f 21307
232b67d9 21308
8e3940b2 21309if test $gcc_cv_as_hidden = yes && test $gcc_cv_ld_hidden = yes; then
8ada417f 21310 libgcc_visibility=yes
ba479fd2
NN
21311
21312cat >>confdefs.h <<\_ACEOF
8ada417f 21313#define HAVE_GAS_HIDDEN 1
ba479fd2 21314_ACEOF
ad9c4d9f
NN
21315
21316fi
21317
e73da78e
RO
21318echo "$as_me:$LINENO: checking linker read-only and read-write section mixing" >&5
21319echo $ECHO_N "checking linker read-only and read-write section mixing... $ECHO_C" >&6
21320gcc_cv_ld_ro_rw_mix=unknown
21321if test $in_tree_ld = yes ; then
21322 if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 10 -o "$gcc_cv_gld_major_version" -gt 2 \
21323 && test $in_tree_ld_is_elf = yes; then
21324 gcc_cv_ld_ro_rw_mix=read-write
21325 fi
21326elif test x$gcc_cv_as != x -a x$gcc_cv_ld != x -a x$gcc_cv_objdump != x ; then
21327 echo '.section myfoosect, "a"' > conftest1.s
21328 echo '.section myfoosect, "aw"' > conftest2.s
21329 echo '.byte 1' >> conftest2.s
21330 echo '.section myfoosect, "a"' > conftest3.s
21331 echo '.byte 0' >> conftest3.s
21332 if $gcc_cv_as -o conftest1.o conftest1.s > /dev/null 2>&1 \
21333 && $gcc_cv_as -o conftest2.o conftest2.s > /dev/null 2>&1 \
21334 && $gcc_cv_as -o conftest3.o conftest3.s > /dev/null 2>&1 \
21335 && $gcc_cv_ld -shared -o conftest1.so conftest1.o \
21336 conftest2.o conftest3.o > /dev/null 2>&1; then
21337 gcc_cv_ld_ro_rw_mix=`$gcc_cv_objdump -h conftest1.so \
21338 | sed -e '/myfoosect/!d' -e N`
21339 if echo "$gcc_cv_ld_ro_rw_mix" | grep CONTENTS > /dev/null; then
21340 if echo "$gcc_cv_ld_ro_rw_mix" | grep READONLY > /dev/null; then
21341 gcc_cv_ld_ro_rw_mix=read-only
21342 else
21343 gcc_cv_ld_ro_rw_mix=read-write
21344 fi
21345 fi
21346 fi
21347 rm -f conftest.* conftest[123].*
21348fi
21349if test x$gcc_cv_ld_ro_rw_mix = xread-write; then
21350
21351cat >>confdefs.h <<\_ACEOF
21352#define HAVE_LD_RO_RW_SECTION_MIXING 1
21353_ACEOF
21354
21355fi
21356echo "$as_me:$LINENO: result: $gcc_cv_ld_ro_rw_mix" >&5
21357echo "${ECHO_T}$gcc_cv_ld_ro_rw_mix" >&6
21358
8ada417f 21359# Check if we have .[us]leb128, and support symbol arithmetic with it.
b61ff9c8
BS
21360echo "$as_me:$LINENO: checking assembler for .sleb128 and .uleb128" >&5
21361echo $ECHO_N "checking assembler for .sleb128 and .uleb128... $ECHO_C" >&6
ba479fd2
NN
21362if test "${gcc_cv_as_leb128+set}" = set; then
21363 echo $ECHO_N "(cached) $ECHO_C" >&6
8ada417f
ZW
21364else
21365 gcc_cv_as_leb128=no
21366 if test $in_tree_gas = yes; then
21367 if test $in_tree_gas_is_elf = yes \
21368 && test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 11 \) \* 1000 + 0`
21369 then gcc_cv_as_leb128=yes
21370fi
21371 elif test x$gcc_cv_as != x; then
6e3f3080 21372 echo ' .data
b7460f24
RH
21373 .uleb128 L2 - L1
21374L1:
21375 .uleb128 1280
21376 .sleb128 -1010
8ada417f 21377L2:' > conftest.s
ba479fd2
NN
21378 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
21379 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21380 (eval $ac_try) 2>&5
21381 ac_status=$?
21382 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21383 (exit $ac_status); }; }
8ada417f
ZW
21384 then
21385 # GAS versions before 2.11 do not support uleb128,
21386 # despite appearing to.
21387 # ??? There exists an elf-specific test that will crash
21388 # the assembler. Perhaps it's better to figure out whether
21389 # arbitrary sections are supported and try the test.
bace148a 21390 as_ver=`$gcc_cv_as --version 2>/dev/null | sed 1q`
8ada417f 21391 if echo "$as_ver" | grep GNU > /dev/null; then
ddcd0f6f 21392 as_vers=`echo $as_ver | sed -n \
115e6e55 21393 -e 's,^.*[ ]\([0-9][0-9]*\.[0-9][0-9]*.*\)$,\1,p'`
ddcd0f6f
BS
21394 as_major=`expr "$as_vers" : '\([0-9]*\)'`
21395 as_minor=`expr "$as_vers" : '[0-9]*\.\([0-9]*\)'`
8ada417f
ZW
21396 if test $as_major -eq 2 && test $as_minor -lt 11
21397 then :
21398 else gcc_cv_as_leb128=yes
21399 fi
21400 fi
21401 else
21402 echo "configure: failed program was" >&5
21403 cat conftest.s >&5
21404 fi
21405 rm -f conftest.o conftest.s
21406 fi
b7460f24 21407fi
b61ff9c8
BS
21408echo "$as_me:$LINENO: result: $gcc_cv_as_leb128" >&5
21409echo "${ECHO_T}$gcc_cv_as_leb128" >&6
63cf211a 21410if test $gcc_cv_as_leb128 = yes; then
ba479fd2
NN
21411
21412cat >>confdefs.h <<\_ACEOF
b7460f24 21413#define HAVE_AS_LEB128 1
ba479fd2 21414_ACEOF
b7460f24
RH
21415
21416fi
ad9c4d9f 21417
d4ea4622
RH
21418# Check if we have assembler support for unwind directives.
21419echo "$as_me:$LINENO: checking assembler for cfi directives" >&5
21420echo $ECHO_N "checking assembler for cfi directives... $ECHO_C" >&6
21421if test "${gcc_cv_as_cfi_directive+set}" = set; then
21422 echo $ECHO_N "(cached) $ECHO_C" >&6
21423else
21424 gcc_cv_as_cfi_directive=no
6e60703f 21425 if test x$gcc_cv_as != x; then
d4ea4622
RH
21426 echo ' .text
21427 .cfi_startproc
21428 .cfi_offset 0, 0
21429 .cfi_same_value 1
21430 .cfi_def_cfa 1, 2
21431 .cfi_escape 1, 2, 3, 4, 5
21432 .cfi_endproc' > conftest.s
21433 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
21434 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21435 (eval $ac_try) 2>&5
21436 ac_status=$?
21437 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21438 (exit $ac_status); }; }
21439 then
e73da78e
RO
21440 case "$target" in
21441 *-*-solaris*)
21442 # If the linker used on Solaris (like Sun ld) isn't capable of merging
21443 # read-only and read-write sections, we need to make sure that the
21444 # assembler used emits read-write .eh_frame sections.
21445 if test "x$gcc_cv_ld_ro_rw_mix" != xread-write; then
21446 if test "x$gcc_cv_objdump" != x; then
21447 if $gcc_cv_objdump -h conftest.o 2>/dev/null | \
21448 sed -e /.eh_frame/!d -e N | grep READONLY > /dev/null; then
21449 gcc_cv_as_cfi_directive=no
21450 else
21451 gcc_cv_as_cfi_directive=yes
21452 fi
21453 else
21454 # no objdump, err on the side of caution
21455 gcc_cv_as_cfi_directive=no
21456 fi
21457 else
21458 gcc_cv_as_cfi_directive=yes
21459 fi
21460 ;;
21461 *-*-*)
21462 gcc_cv_as_cfi_directive=yes
21463 ;;
21464esac
d4ea4622
RH
21465 else
21466 echo "configure: failed program was" >&5
21467 cat conftest.s >&5
21468 fi
21469 rm -f conftest.o conftest.s
21470 fi
21471fi
21472echo "$as_me:$LINENO: result: $gcc_cv_as_cfi_directive" >&5
21473echo "${ECHO_T}$gcc_cv_as_cfi_directive" >&6
21474
6e97481b
JJ
21475if test $gcc_cv_as_cfi_directive = yes && test x$gcc_cv_readelf != x; then
21476echo "$as_me:$LINENO: checking assembler for working cfi advance" >&5
21477echo $ECHO_N "checking assembler for working cfi advance... $ECHO_C" >&6
21478if test "${gcc_cv_as_cfi_advance_working+set}" = set; then
21479 echo $ECHO_N "(cached) $ECHO_C" >&6
21480else
21481 gcc_cv_as_cfi_advance_working=no
21482 if test x$gcc_cv_as != x; then
21483 echo ' .text
21484 .cfi_startproc
21485 .cfi_adjust_cfa_offset 64
21486 .skip 512, 0
21487 .cfi_adjust_cfa_offset 128
21488 .cfi_endproc' > conftest.s
21489 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
21490 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21491 (eval $ac_try) 2>&5
21492 ac_status=$?
21493 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21494 (exit $ac_status); }; }
21495 then
21496
21497if $gcc_cv_readelf -wf conftest.o 2>/dev/null \
21498 | grep 'DW_CFA_advance_loc[12]:[ ][ ]*512[ ]' >/dev/null; then
21499 gcc_cv_as_cfi_advance_working=yes
21500fi
21501
21502 else
21503 echo "configure: failed program was" >&5
21504 cat conftest.s >&5
21505 fi
21506 rm -f conftest.o conftest.s
21507 fi
21508fi
21509echo "$as_me:$LINENO: result: $gcc_cv_as_cfi_advance_working" >&5
21510echo "${ECHO_T}$gcc_cv_as_cfi_advance_working" >&6
21511
21512else
66f91112
EB
21513 # no readelf, err on the side of caution
21514 gcc_cv_as_cfi_advance_working=no
6e97481b 21515fi
d4ea4622
RH
21516
21517cat >>confdefs.h <<_ACEOF
6e97481b
JJ
21518#define HAVE_GAS_CFI_DIRECTIVE `if test $gcc_cv_as_cfi_directive = yes \
21519 && test $gcc_cv_as_cfi_advance_working = yes; then echo 1; else echo 0; fi`
d4ea4622
RH
21520_ACEOF
21521
21522
058514b3
RH
21523echo "$as_me:$LINENO: checking assembler for cfi personality directive" >&5
21524echo $ECHO_N "checking assembler for cfi personality directive... $ECHO_C" >&6
21525if test "${gcc_cv_as_cfi_personality_directive+set}" = set; then
21526 echo $ECHO_N "(cached) $ECHO_C" >&6
21527else
21528 gcc_cv_as_cfi_personality_directive=no
6e60703f 21529 if test x$gcc_cv_as != x; then
058514b3 21530 echo ' .text
042628f9 21531 .cfi_startproc
058514b3
RH
21532 .cfi_personality 0, symbol
21533 .cfi_endproc' > conftest.s
21534 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
21535 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21536 (eval $ac_try) 2>&5
21537 ac_status=$?
21538 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21539 (exit $ac_status); }; }
21540 then
21541 gcc_cv_as_cfi_personality_directive=yes
21542 else
21543 echo "configure: failed program was" >&5
21544 cat conftest.s >&5
21545 fi
21546 rm -f conftest.o conftest.s
21547 fi
21548fi
21549echo "$as_me:$LINENO: result: $gcc_cv_as_cfi_personality_directive" >&5
21550echo "${ECHO_T}$gcc_cv_as_cfi_personality_directive" >&6
21551
21552
21553cat >>confdefs.h <<_ACEOF
21554#define HAVE_GAS_CFI_PERSONALITY_DIRECTIVE `if test $gcc_cv_as_cfi_personality_directive = yes;
21555 then echo 1; else echo 0; fi`
21556_ACEOF
21557
21558
8ada417f
ZW
21559# GAS versions up to and including 2.11.0 may mis-optimize
21560# .eh_frame data.
b61ff9c8
BS
21561echo "$as_me:$LINENO: checking assembler for eh_frame optimization" >&5
21562echo $ECHO_N "checking assembler for eh_frame optimization... $ECHO_C" >&6
ba479fd2
NN
21563if test "${gcc_cv_as_eh_frame+set}" = set; then
21564 echo $ECHO_N "(cached) $ECHO_C" >&6
8ada417f
ZW
21565else
21566 gcc_cv_as_eh_frame=no
21567 if test $in_tree_gas = yes; then
21568 if test $in_tree_gas_is_elf = yes \
21569 && test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 12 \) \* 1000 + 0`
21570 then gcc_cv_as_eh_frame=yes
ad9c4d9f 21571fi
8ada417f 21572 elif test x$gcc_cv_as != x; then
6e3f3080 21573 echo ' .text
c64688ae
RH
21574.LFB1:
21575 .4byte 0
21576.L1:
21577 .4byte 0
21578.LFE1:
21579 .section .eh_frame,"aw",@progbits
21580__FRAME_BEGIN__:
21581 .4byte .LECIE1-.LSCIE1
21582.LSCIE1:
21583 .4byte 0x0
21584 .byte 0x1
21585 .ascii "z\0"
21586 .byte 0x1
21587 .byte 0x78
21588 .byte 0x1a
21589 .byte 0x0
21590 .byte 0x4
21591 .4byte 1
21592 .p2align 1
21593.LECIE1:
21594.LSFDE1:
21595 .4byte .LEFDE1-.LASFDE1
21596.LASFDE1:
21597 .4byte .LASFDE1-__FRAME_BEGIN__
21598 .4byte .LFB1
21599 .4byte .LFE1-.LFB1
21600 .byte 0x4
21601 .4byte .LFE1-.LFB1
21602 .byte 0x4
21603 .4byte .L1-.LFB1
8ada417f 21604.LEFDE1:' > conftest.s
ba479fd2
NN
21605 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
21606 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21607 (eval $ac_try) 2>&5
21608 ac_status=$?
21609 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21610 (exit $ac_status); }; }
8ada417f
ZW
21611 then
21612 cat > conftest.lit <<EOF
c64688ae
RH
21613 0000 10000000 00000000 017a0001 781a0004 .........z..x...
21614 0010 01000000 12000000 18000000 00000000 ................
093e61a6 21615 0020 08000000 04080000 0044 .........D
01efb963 21616EOF
ba479fd2 21617cat > conftest.big <<EOF
01efb963
AS
21618 0000 00000010 00000000 017a0001 781a0004 .........z..x...
21619 0010 00000001 00000012 00000018 00000000 ................
093e61a6 21620 0020 00000008 04000000 0844 .........D
c64688ae 21621EOF
8ada417f
ZW
21622 # If the assembler didn't choke, and we can objdump,
21623 # and we got the correct data, then succeed.
dbc02e7f
AS
21624 # The text in the here-document typically retains its unix-style line
21625 # endings, while the output of objdump will use host line endings.
21626 # Therefore, use diff -b for the comparisons.
8ada417f
ZW
21627 if test x$gcc_cv_objdump != x \
21628 && $gcc_cv_objdump -s -j .eh_frame conftest.o 2>/dev/null \
21629 | tail -3 > conftest.got \
dbc02e7f
AS
21630 && { diff -b conftest.lit conftest.got > /dev/null 2>&1 \
21631 || diff -b conftest.big conftest.got > /dev/null 2>&1; }
8ada417f
ZW
21632 then
21633 gcc_cv_as_eh_frame=yes
ba479fd2
NN
21634 elif { ac_try='$gcc_cv_as -o conftest.o --traditional-format /dev/null'
21635 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21636 (eval $ac_try) 2>&5
21637 ac_status=$?
21638 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21639 (exit $ac_status); }; }; then
8ada417f
ZW
21640 gcc_cv_as_eh_frame=buggy
21641 else
21642 # Uh oh, what do we do now?
21643 gcc_cv_as_eh_frame=no
21644 fi
21645 else
21646 echo "configure: failed program was" >&5
21647 cat conftest.s >&5
21648 fi
21649 rm -f conftest.o conftest.s
21650 fi
c64688ae 21651fi
b61ff9c8
BS
21652echo "$as_me:$LINENO: result: $gcc_cv_as_eh_frame" >&5
21653echo "${ECHO_T}$gcc_cv_as_eh_frame" >&6
ad9c4d9f 21654
6e3f3080 21655
63cf211a 21656if test $gcc_cv_as_eh_frame = buggy; then
ba479fd2
NN
21657
21658cat >>confdefs.h <<\_ACEOF
8ada417f 21659#define USE_AS_TRADITIONAL_FORMAT 1
ba479fd2 21660_ACEOF
ad9c4d9f
NN
21661
21662fi
21663
b61ff9c8
BS
21664echo "$as_me:$LINENO: checking assembler for section merging support" >&5
21665echo $ECHO_N "checking assembler for section merging support... $ECHO_C" >&6
ba479fd2
NN
21666if test "${gcc_cv_as_shf_merge+set}" = set; then
21667 echo $ECHO_N "(cached) $ECHO_C" >&6
8ada417f
ZW
21668else
21669 gcc_cv_as_shf_merge=no
21670 if test $in_tree_gas = yes; then
21671 if test $in_tree_gas_is_elf = yes \
21672 && test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 12 \) \* 1000 + 0`
21673 then gcc_cv_as_shf_merge=yes
21674fi
21675 elif test x$gcc_cv_as != x; then
6e3f3080 21676 echo '.section .rodata.str, "aMS", @progbits, 1' > conftest.s
ba479fd2
NN
21677 if { ac_try='$gcc_cv_as --fatal-warnings -o conftest.o conftest.s >&5'
21678 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21679 (eval $ac_try) 2>&5
21680 ac_status=$?
21681 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21682 (exit $ac_status); }; }
8ada417f
ZW
21683 then
21684 gcc_cv_as_shf_merge=yes
21685 else
21686 echo "configure: failed program was" >&5
21687 cat conftest.s >&5
21688 fi
21689 rm -f conftest.o conftest.s
21690 fi
201556f0 21691fi
b61ff9c8
BS
21692echo "$as_me:$LINENO: result: $gcc_cv_as_shf_merge" >&5
21693echo "${ECHO_T}$gcc_cv_as_shf_merge" >&6
8ada417f 21694
c18a5b6c 21695if test $gcc_cv_as_shf_merge = no; then
b61ff9c8
BS
21696 echo "$as_me:$LINENO: checking assembler for section merging support" >&5
21697echo $ECHO_N "checking assembler for section merging support... $ECHO_C" >&6
c18a5b6c
MM
21698if test "${gcc_cv_as_shf_merge+set}" = set; then
21699 echo $ECHO_N "(cached) $ECHO_C" >&6
21700else
21701 gcc_cv_as_shf_merge=no
21702 if test $in_tree_gas = yes; then
21703 if test $in_tree_gas_is_elf = yes \
21704 && test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 12 \) \* 1000 + 0`
21705 then gcc_cv_as_shf_merge=yes
21706fi
21707 elif test x$gcc_cv_as != x; then
21708 echo '.section .rodata.str, "aMS", %progbits, 1' > conftest.s
21709 if { ac_try='$gcc_cv_as --fatal-warnings -o conftest.o conftest.s >&5'
21710 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21711 (eval $ac_try) 2>&5
21712 ac_status=$?
21713 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21714 (exit $ac_status); }; }
21715 then
21716 gcc_cv_as_shf_merge=yes
21717 else
21718 echo "configure: failed program was" >&5
21719 cat conftest.s >&5
21720 fi
21721 rm -f conftest.o conftest.s
21722 fi
21723fi
b61ff9c8
BS
21724echo "$as_me:$LINENO: result: $gcc_cv_as_shf_merge" >&5
21725echo "${ECHO_T}$gcc_cv_as_shf_merge" >&6
c18a5b6c
MM
21726
21727fi
8ad9fb33 21728
ba479fd2 21729cat >>confdefs.h <<_ACEOF
8ad9fb33 21730#define HAVE_GAS_SHF_MERGE `if test $gcc_cv_as_shf_merge = yes; then echo 1; else echo 0; fi`
ba479fd2 21731_ACEOF
201556f0 21732
201556f0 21733
b61ff9c8
BS
21734echo "$as_me:$LINENO: checking assembler for COMDAT group support" >&5
21735echo $ECHO_N "checking assembler for COMDAT group support... $ECHO_C" >&6
c18a5b6c
MM
21736if test "${gcc_cv_as_comdat_group+set}" = set; then
21737 echo $ECHO_N "(cached) $ECHO_C" >&6
21738else
21739 gcc_cv_as_comdat_group=no
21740 if test $in_tree_gas = yes; then
21741 if test $in_tree_gas_is_elf = yes \
11176d2a 21742 && test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 16 \) \* 1000 + 0`
c18a5b6c
MM
21743 then gcc_cv_as_comdat_group=yes
21744fi
21745 elif test x$gcc_cv_as != x; then
21746 echo '.section .text,"axG",@progbits,.foo,comdat' > conftest.s
21747 if { ac_try='$gcc_cv_as --fatal-warnings -o conftest.o conftest.s >&5'
21748 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21749 (eval $ac_try) 2>&5
21750 ac_status=$?
21751 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21752 (exit $ac_status); }; }
21753 then
21754 gcc_cv_as_comdat_group=yes
21755 else
21756 echo "configure: failed program was" >&5
21757 cat conftest.s >&5
21758 fi
21759 rm -f conftest.o conftest.s
21760 fi
21761fi
b61ff9c8
BS
21762echo "$as_me:$LINENO: result: $gcc_cv_as_comdat_group" >&5
21763echo "${ECHO_T}$gcc_cv_as_comdat_group" >&6
c18a5b6c
MM
21764
21765if test $gcc_cv_as_comdat_group = yes; then
21766 gcc_cv_as_comdat_group_percent=no
21767else
b61ff9c8
BS
21768 echo "$as_me:$LINENO: checking assembler for COMDAT group support" >&5
21769echo $ECHO_N "checking assembler for COMDAT group support... $ECHO_C" >&6
c18a5b6c
MM
21770if test "${gcc_cv_as_comdat_group_percent+set}" = set; then
21771 echo $ECHO_N "(cached) $ECHO_C" >&6
21772else
21773 gcc_cv_as_comdat_group_percent=no
21774 if test $in_tree_gas = yes; then
21775 if test $in_tree_gas_is_elf = yes \
11176d2a 21776 && test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 16 \) \* 1000 + 0`
c18a5b6c
MM
21777 then gcc_cv_as_comdat_group_percent=yes
21778fi
21779 elif test x$gcc_cv_as != x; then
21780 echo '.section .text,"axG",%progbits,.foo,comdat' > conftest.s
21781 if { ac_try='$gcc_cv_as --fatal-warnings -o conftest.o conftest.s >&5'
21782 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21783 (eval $ac_try) 2>&5
21784 ac_status=$?
21785 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21786 (exit $ac_status); }; }
21787 then
21788 gcc_cv_as_comdat_group_percent=yes
21789 else
21790 echo "configure: failed program was" >&5
21791 cat conftest.s >&5
21792 fi
21793 rm -f conftest.o conftest.s
21794 fi
21795fi
b61ff9c8
BS
21796echo "$as_me:$LINENO: result: $gcc_cv_as_comdat_group_percent" >&5
21797echo "${ECHO_T}$gcc_cv_as_comdat_group_percent" >&6
c18a5b6c
MM
21798
21799fi
11176d2a
JB
21800if test $in_tree_ld != yes && test x"$ld_vers" != x; then
21801 comdat_group=yes
21802 if test 0"$ld_date" -lt 20050308; then
21803 if test -n "$ld_date"; then
21804 # If there was date string, but was earlier than 2005-03-08, fail
21805 comdat_group=no
21806 elif test "$ld_vers_major" -lt 2; then
21807 comdat_group=no
21808 elif test "$ld_vers_major" -eq 2 -a "$ld_vers_minor" -lt 16; then
21809 comdat_group=no
21810 fi
21811 fi
1cf0118d
RO
21812else
21813 # assume linkers other than GNU ld don't support COMDAT group
21814 comdat_group=no
21815fi
21816if test $comdat_group = no; then
21817 gcc_cv_as_comdat_group=no
21818 gcc_cv_as_comdat_group_percent=no
11176d2a 21819fi
c18a5b6c
MM
21820
21821cat >>confdefs.h <<_ACEOF
11176d2a 21822#define HAVE_COMDAT_GROUP `if test $gcc_cv_as_comdat_group = yes || test $gcc_cv_as_comdat_group_percent = yes; then echo 1; else echo 0; fi`
c18a5b6c
MM
21823_ACEOF
21824
21825
6a7a462c 21826# Thread-local storage - the check is heavily parameterized.
f996902d
RH
21827conftest_s=
21828tls_first_major=
21829tls_first_minor=
9739c90c 21830tls_as_opt=
f996902d 21831case "$target" in
6f9b006d
RH
21832 alpha*-*-*)
21833 conftest_s='
21834 .section ".tdata","awT",@progbits
21835foo: .long 25
21836 .text
21837 ldq $27,__tls_get_addr($29) !literal!1
21838 lda $16,foo($29) !tlsgd!1
21839 jsr $26,($27),__tls_get_addr !lituse_tlsgd!1
21840 ldq $27,__tls_get_addr($29) !literal!2
21841 lda $16,foo($29) !tlsldm!2
21842 jsr $26,($27),__tls_get_addr !lituse_tlsldm!2
21843 ldq $1,foo($29) !gotdtprel
21844 ldah $2,foo($29) !dtprelhi
21845 lda $3,foo($2) !dtprello
21846 lda $4,foo($29) !dtprel
21847 ldq $1,foo($29) !gottprel
21848 ldah $2,foo($29) !tprelhi
21849 lda $3,foo($2) !tprello
21850 lda $4,foo($29) !tprel'
21851 tls_first_major=2
21852 tls_first_minor=13
2f3321ca 21853 tls_as_opt=--fatal-warnings
6f9b006d 21854 ;;
ad9646c7
HPN
21855 cris-*-*|crisv32-*-*)
21856 conftest_s='
21857 .section ".tdata","awT",@progbits
21858x: .long 25
21859 .text
21860 move.d x:IE,$r10
21861 nop'
21862 tls_first_major=2
21863 tls_first_minor=20
21864 tls_as_opt=--fatal-warnings
21865 ;;
e4dd71de
AH
21866 frv*-*-*)
21867 conftest_s='
21868 .section ".tdata","awT",@progbits
21869x: .long 25
21870 .text
21871 call #gettlsoff(x)'
21872 tls_first_major=2
21873 tls_first_minor=14
21874 ;;
51076f96
RC
21875 hppa*-*-linux*)
21876 conftest_s='
21877t1: .reg %r20
21878t2: .reg %r21
21879gp: .reg %r19
21880 .section ".tdata","awT",@progbits
21881foo: .long 25
21882 .text
21883 .align 4
21884 addil LT%foo-$tls_gdidx$,gp
21885 ldo RT%foo-$tls_gdidx$(%r1),%arg0
21886 b __tls_get_addr
21887 nop
21888 addil LT%foo-$tls_ldidx$,gp
21889 b __tls_get_addr
21890 ldo RT%foo-$tls_ldidx$(%r1),%arg0
21891 addil LR%foo-$tls_dtpoff$,%ret0
21892 ldo RR%foo-$tls_dtpoff$(%r1),%t1
21893 mfctl %cr27,%t1
21894 addil LT%foo-$tls_ieoff$,gp
21895 ldw RT%foo-$tls_ieoff$(%r1),%t2
21896 add %t1,%t2,%t3
21897 mfctl %cr27,%t1
21898 addil LR%foo-$tls_leoff$,%t1
21899 ldo RR%foo-$tls_leoff$(%r1),%t2'
21900 tls_first_major=2
21901 tls_first_minor=15
21902 tls_as_opt=--fatal-warnings
21903 ;;
d3585b76
DJ
21904 arm*-*-*)
21905 conftest_s='
21906 .section ".tdata","awT",%progbits
21907foo: .long 25
21908 .text
21909.word foo(gottpoff)
21910.word foo(tpoff)
21911.word foo(tlsgd)
21912.word foo(tlsldm)
21913.word foo(tlsldo)'
21914 tls_first_major=2
21915 tls_first_minor=17
21916 ;;
f996902d
RH
21917 i[34567]86-*-*)
21918 conftest_s='
21919 .section ".tdata","awT",@progbits
21920foo: .long 25
21921 .text
21922 movl %gs:0, %eax
21923 leal foo@TLSGD(,%ebx,1), %eax
21924 leal foo@TLSLDM(%ebx), %eax
21925 leal foo@DTPOFF(%eax), %edx
21926 movl foo@GOTTPOFF(%ebx), %eax
21927 subl foo@GOTTPOFF(%ebx), %eax
75d38379
JJ
21928 addl foo@GOTNTPOFF(%ebx), %eax
21929 movl foo@INDNTPOFF, %eax
f996902d
RH
21930 movl $foo@TPOFF, %eax
21931 subl $foo@TPOFF, %eax
21932 leal foo@NTPOFF(%ecx), %eax'
21933 tls_first_major=2
75d38379 21934 tls_first_minor=14
2f3321ca 21935 tls_as_opt=--fatal-warnings
75d38379
JJ
21936 ;;
21937 x86_64-*-*)
21938 conftest_s='
21939 .section ".tdata","awT",@progbits
21940foo: .long 25
21941 .text
21942 movq %fs:0, %rax
21943 leaq foo@TLSGD(%rip), %rdi
21944 leaq foo@TLSLD(%rip), %rdi
21945 leaq foo@DTPOFF(%rax), %rdx
21946 movq foo@GOTTPOFF(%rip), %rax
21947 movq $foo@TPOFF, %rax'
21948 tls_first_major=2
21949 tls_first_minor=14
2f3321ca 21950 tls_as_opt=--fatal-warnings
f996902d 21951 ;;
7b6e506e
RH
21952 ia64-*-*)
21953 conftest_s='
21954 .section ".tdata","awT",@progbits
21955foo: data8 25
21956 .text
21957 addl r16 = @ltoff(@dtpmod(foo#)), gp
21958 addl r17 = @ltoff(@dtprel(foo#)), gp
21959 addl r18 = @ltoff(@tprel(foo#)), gp
21960 addl r19 = @dtprel(foo#), gp
21961 adds r21 = @dtprel(foo#), r13
21962 movl r23 = @dtprel(foo#)
21963 addl r20 = @tprel(foo#), gp
21964 adds r22 = @tprel(foo#), r13
21965 movl r24 = @tprel(foo#)'
21966 tls_first_major=2
21967 tls_first_minor=13
2f3321ca 21968 tls_as_opt=--fatal-warnings
7b6e506e 21969 ;;
69229b81
DJ
21970 mips*-*-*)
21971 conftest_s='
21972 .section .tdata,"awT",@progbits
21973x:
21974 .word 2
21975 .text
21976 addiu $4, $28, %tlsgd(x)
21977 addiu $4, $28, %tlsldm(x)
21978 lui $4, %dtprel_hi(x)
21979 addiu $4, $4, %dtprel_lo(x)
21980 lw $4, %gottprel(x)($28)
21981 lui $4, %tprel_hi(x)
21982 addiu $4, $4, %tprel_lo(x)'
21983 tls_first_major=2
21984 tls_first_minor=16
21985 tls_as_opt='-32 --fatal-warnings'
21986 ;;
75df395f
MK
21987 m68k-*-*)
21988 conftest_s='
21989 .section .tdata,"awT",@progbits
21990x:
21991 .word 2
21992 .text
21993foo:
21994 move.l x@TLSGD(%a5),%a0
21995 move.l x@TLSLDM(%a5),%a0
21996 move.l x@TLSLDO(%a5),%a0
21997 move.l x@TLSIE(%a5),%a0
21998 move.l x@TLSLE(%a5),%a0'
21999 tls_first_major=2
22000 tls_first_minor=19
22001 tls_as_opt='--fatal-warnings'
22002 ;;
c4501e62
JJ
22003 powerpc-*-*)
22004 conftest_s='
22005 .section ".tdata","awT",@progbits
22006 .align 2
22007ld0: .space 4
22008ld1: .space 4
22009x1: .space 4
22010x2: .space 4
22011x3: .space 4
22012 .text
22013 addi 3,31,ld0@got@tlsgd
22014 bl __tls_get_addr
22015 addi 3,31,x1@got@tlsld
22016 bl __tls_get_addr
22017 addi 9,3,x1@dtprel
22018 addis 9,3,x2@dtprel@ha
22019 addi 9,9,x2@dtprel@l
22020 lwz 9,x3@got@tprel(31)
22021 add 9,9,x@tls
22022 addi 9,2,x1@tprel
22023 addis 9,2,x2@tprel@ha
22024 addi 9,9,x2@tprel@l'
22025 tls_first_major=2
22026 tls_first_minor=14
2f3321ca 22027 tls_as_opt="-a32 --fatal-warnings"
c4501e62
JJ
22028 ;;
22029 powerpc64-*-*)
22030 conftest_s='
22031 .section ".tdata","awT",@progbits
22032 .align 3
22033ld0: .space 8
22034ld1: .space 8
22035x1: .space 8
22036x2: .space 8
22037x3: .space 8
22038 .text
22039 addi 3,2,ld0@got@tlsgd
22040 bl .__tls_get_addr
22041 nop
22042 addi 3,2,ld1@toc
22043 bl .__tls_get_addr
22044 nop
22045 addi 3,2,x1@got@tlsld
22046 bl .__tls_get_addr
22047 nop
22048 addi 9,3,x1@dtprel
22049 bl .__tls_get_addr
22050 nop
22051 addis 9,3,x2@dtprel@ha
22052 addi 9,9,x2@dtprel@l
22053 bl .__tls_get_addr
22054 nop
22055 ld 9,x3@got@dtprel(2)
22056 add 9,9,3
22057 bl .__tls_get_addr
22058 nop'
22059 tls_first_major=2
22060 tls_first_minor=14
2f3321ca 22061 tls_as_opt="-a64 --fatal-warnings"
c4501e62 22062 ;;
fd3cd001
UW
22063 s390-*-*)
22064 conftest_s='
22065 .section ".tdata","awT",@progbits
22066foo: .long 25
22067 .text
22068 .long foo@TLSGD
22069 .long foo@TLSLDM
22070 .long foo@DTPOFF
22071 .long foo@NTPOFF
22072 .long foo@GOTNTPOFF
22073 .long foo@INDNTPOFF
22074 l %r1,foo@GOTNTPOFF(%r12)
22075 l %r1,0(%r1):tls_load:foo
22076 bas %r14,0(%r1,%r13):tls_gdcall:foo
22077 bas %r14,0(%r1,%r13):tls_ldcall:foo'
22078 tls_first_major=2
22079 tls_first_minor=14
2f3321ca 22080 tls_as_opt="-m31 --fatal-warnings"
fd3cd001
UW
22081 ;;
22082 s390x-*-*)
22083 conftest_s='
22084 .section ".tdata","awT",@progbits
22085foo: .long 25
22086 .text
22087 .quad foo@TLSGD
22088 .quad foo@TLSLDM
22089 .quad foo@DTPOFF
22090 .quad foo@NTPOFF
22091 .quad foo@GOTNTPOFF
22092 lg %r1,foo@GOTNTPOFF(%r12)
22093 larl %r1,foo@INDNTPOFF
22094 brasl %r14,__tls_get_offset@PLT:tls_gdcall:foo
22095 brasl %r14,__tls_get_offset@PLT:tls_ldcall:foo'
22096 tls_first_major=2
22097 tls_first_minor=14
2f3321ca 22098 tls_as_opt="-m64 -Aesame --fatal-warnings"
fd3cd001 22099 ;;
9ff13962
KK
22100 sh-*-* | sh[34]-*-*)
22101 conftest_s='
22102 .section ".tdata","awT",@progbits
22103foo: .long 25
22104 .text
22105 .long foo@TLSGD
22106 .long foo@TLSLDM
22107 .long foo@DTPOFF
22108 .long foo@GOTTPOFF
22109 .long foo@TPOFF'
22110 tls_first_major=2
22111 tls_first_minor=13
2f3321ca 22112 tls_as_opt=--fatal-warnings
9ff13962 22113 ;;
5751a10b 22114 sparc*-*-*)
2f3321ca 22115 case "$target" in
7935dc1b
EB
22116 sparc*-sun-solaris2.[56789]*)
22117 # TLS was introduced in the Solaris 9 4/04 release but
22118 # we do not enable it by default on Solaris 9 either.
22119 if test "x$enable_tls" = xyes ; then
22120 on_solaris=yes
22121 else
22122 enable_tls=no;
22123 fi
22124 ;;
2f3321ca
EB
22125 sparc*-sun-solaris2.*)
22126 on_solaris=yes
22127 ;;
22128 *)
22129 on_solaris=no
22130 ;;
22131 esac
22132 if test x$on_solaris = xyes && test x$gas_flag = xno; then
22133 conftest_s='
22134 .section ".tdata",#alloc,#write,#tls
22135foo: .long 25
22136 .text
22137 sethi %tgd_hi22(foo), %o0
22138 add %o0, %tgd_lo10(foo), %o1
22139 add %l7, %o1, %o0, %tgd_add(foo)
22140 call __tls_get_addr, %tgd_call(foo)
22141 sethi %tldm_hi22(foo), %l1
22142 add %l1, %tldm_lo10(foo), %l2
22143 add %l7, %l2, %o0, %tldm_add(foo)
22144 call __tls_get_addr, %tldm_call(foo)
22145 sethi %tldo_hix22(foo), %l3
22146 xor %l3, %tldo_lox10(foo), %l4
22147 add %o0, %l4, %l5, %tldo_add(foo)
22148 sethi %tie_hi22(foo), %o3
22149 add %o3, %tie_lo10(foo), %o3
22150 ld [%l7 + %o3], %o2, %tie_ld(foo)
22151 add %g7, %o2, %o4, %tie_add(foo)
22152 sethi %tle_hix22(foo), %l1
22153 xor %l1, %tle_lox10(foo), %o5
22154 ld [%g7 + %o5], %o1'
22155 tls_first_major=0
22156 tls_first_minor=0
22157 else
22158 conftest_s='
5751a10b
JJ
22159 .section ".tdata","awT",@progbits
22160foo: .long 25
22161 .text
22162 sethi %tgd_hi22(foo), %o0
22163 add %o0, %tgd_lo10(foo), %o1
22164 add %l7, %o1, %o0, %tgd_add(foo)
22165 call __tls_get_addr, %tgd_call(foo)
22166 sethi %tldm_hi22(foo), %l1
22167 add %l1, %tldm_lo10(foo), %l2
22168 add %l7, %l2, %o0, %tldm_add(foo)
22169 call __tls_get_addr, %tldm_call(foo)
22170 sethi %tldo_hix22(foo), %l3
22171 xor %l3, %tldo_lox10(foo), %l4
22172 add %o0, %l4, %l5, %tldo_add(foo)
22173 sethi %tie_hi22(foo), %o3
22174 add %o3, %tie_lo10(foo), %o3
22175 ld [%l7 + %o3], %o2, %tie_ld(foo)
22176 add %g7, %o2, %o4, %tie_add(foo)
22177 sethi %tle_hix22(foo), %l1
22178 xor %l1, %tle_lox10(foo), %o5
22179 ld [%g7 + %o5], %o1'
22180 tls_first_major=2
22181 tls_first_minor=14
2f3321ca
EB
22182 tls_as_opt="-32 --fatal-warnings"
22183 fi
5751a10b 22184 ;;
6a7a462c
BW
22185 xtensa*-*-*)
22186 conftest_s='
22187 .section ".tdata","awT",@progbits
22188foo: .long 25
22189 .text
22190 movi a8, foo@TLSFUNC
22191 movi a10, foo@TLSARG
22192 callx8.tls a8, foo@TLSCALL'
22193 tls_first_major=2
22194 tls_first_minor=19
22195 ;;
f996902d 22196esac
8dea1cca
DD
22197set_have_as_tls=no
22198if test "x$enable_tls" = xno ; then
22199 : # TLS explicitly disabled.
22200elif test "x$enable_tls" = xyes ; then
22201 set_have_as_tls=yes # TLS explicitly enabled.
22202elif test -z "$tls_first_major"; then
8ada417f
ZW
22203 : # If we don't have a check, assume no support.
22204else
b61ff9c8
BS
22205 echo "$as_me:$LINENO: checking assembler for thread-local storage support" >&5
22206echo $ECHO_N "checking assembler for thread-local storage support... $ECHO_C" >&6
ba479fd2
NN
22207if test "${gcc_cv_as_tls+set}" = set; then
22208 echo $ECHO_N "(cached) $ECHO_C" >&6
8ada417f
ZW
22209else
22210 gcc_cv_as_tls=no
22211 if test $in_tree_gas = yes; then
22212 if test $gcc_cv_gas_vers -ge `expr \( \( $tls_first_major \* 1000 \) + $tls_first_minor \) \* 1000 + 0`
22213 then gcc_cv_as_tls=yes
ad9c4d9f 22214fi
8ada417f 22215 elif test x$gcc_cv_as != x; then
6e3f3080 22216 echo "$conftest_s" > conftest.s
2f3321ca 22217 if { ac_try='$gcc_cv_as $tls_as_opt -o conftest.o conftest.s >&5'
ba479fd2
NN
22218 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22219 (eval $ac_try) 2>&5
22220 ac_status=$?
22221 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22222 (exit $ac_status); }; }
8ada417f
ZW
22223 then
22224 gcc_cv_as_tls=yes
22225 else
22226 echo "configure: failed program was" >&5
22227 cat conftest.s >&5
22228 fi
22229 rm -f conftest.o conftest.s
f996902d 22230 fi
f996902d 22231fi
b61ff9c8
BS
22232echo "$as_me:$LINENO: result: $gcc_cv_as_tls" >&5
22233echo "${ECHO_T}$gcc_cv_as_tls" >&6
63cf211a 22234if test $gcc_cv_as_tls = yes; then
8dea1cca
DD
22235 set_have_as_tls=yes
22236fi
22237fi
22238if test $set_have_as_tls = yes ; then
ba479fd2
NN
22239
22240cat >>confdefs.h <<\_ACEOF
f996902d 22241#define HAVE_AS_TLS 1
ba479fd2 22242_ACEOF
f996902d 22243
8ada417f
ZW
22244fi
22245
22246# Target-specific assembler checks.
f996902d 22247
b61ff9c8
BS
22248echo "$as_me:$LINENO: checking linker -Bstatic/-Bdynamic option" >&5
22249echo $ECHO_N "checking linker -Bstatic/-Bdynamic option... $ECHO_C" >&6
7e9d8517
L
22250gcc_cv_ld_static_dynamic=no
22251if test $in_tree_ld = yes ; then
83f0ccb8 22252 if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 10 -o "$gcc_cv_gld_major_version" -gt 2; then
7e9d8517
L
22253 gcc_cv_ld_static_dynamic=yes
22254 fi
22255elif test x$gcc_cv_ld != x; then
22256 # Check if linker supports -Bstatic/-Bdynamic option
22257 if $gcc_cv_ld --help 2>/dev/null | grep -- -Bstatic > /dev/null \
22258 && $gcc_cv_ld --help 2>/dev/null | grep -- -Bdynamic > /dev/null; then
22259 gcc_cv_ld_static_dynamic=yes
22260 fi
22261fi
22262if test x"$gcc_cv_ld_static_dynamic" = xyes; then
22263
22264cat >>confdefs.h <<\_ACEOF
22265#define HAVE_LD_STATIC_DYNAMIC 1
22266_ACEOF
22267
22268fi
b61ff9c8
BS
22269echo "$as_me:$LINENO: result: $gcc_cv_ld_static_dynamic" >&5
22270echo "${ECHO_T}$gcc_cv_ld_static_dynamic" >&6
7e9d8517 22271
d594623a 22272if test x"$demangler_in_ld" = xyes; then
b61ff9c8
BS
22273 echo "$as_me:$LINENO: checking linker --demangle support" >&5
22274echo $ECHO_N "checking linker --demangle support... $ECHO_C" >&6
d594623a
L
22275 gcc_cv_ld_demangle=no
22276 if test $in_tree_ld = yes; then
22277 if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 14 -o "$gcc_cv_gld_major_version" -gt 2; then \
22278 gcc_cv_ld_demangle=yes
22279 fi
22280 elif test x$gcc_cv_ld != x -a x"$gnu_ld" = xyes; then
22281 # Check if the GNU linker supports --demangle option
22282 if $gcc_cv_ld --help 2>/dev/null | grep no-demangle > /dev/null; then
22283 gcc_cv_ld_demangle=yes
22284 fi
22285 fi
22286 if test x"$gcc_cv_ld_demangle" = xyes; then
22287
22288cat >>confdefs.h <<\_ACEOF
22289#define HAVE_LD_DEMANGLE 1
22290_ACEOF
22291
22292 fi
b61ff9c8
BS
22293 echo "$as_me:$LINENO: result: $gcc_cv_ld_demangle" >&5
22294echo "${ECHO_T}$gcc_cv_ld_demangle" >&6
d594623a
L
22295fi
22296
3a37b08e
RH
22297case "$target" in
22298 # All TARGET_ABI_OSF targets.
22299 alpha*-*-osf* | alpha*-*-linux* | alpha*-*-*bsd*)
b61ff9c8
BS
22300 echo "$as_me:$LINENO: checking assembler for explicit relocation support" >&5
22301echo $ECHO_N "checking assembler for explicit relocation support... $ECHO_C" >&6
ba479fd2
NN
22302if test "${gcc_cv_as_alpha_explicit_relocs+set}" = set; then
22303 echo $ECHO_N "(cached) $ECHO_C" >&6
3a37b08e 22304else
8ada417f
ZW
22305 gcc_cv_as_alpha_explicit_relocs=no
22306 if test $in_tree_gas = yes; then
22307 if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 12 \) \* 1000 + 0`
22308 then gcc_cv_as_alpha_explicit_relocs=yes
ad9c4d9f 22309fi
8ada417f 22310 elif test x$gcc_cv_as != x; then
6e3f3080 22311 echo ' .set nomacro
3a37b08e
RH
22312 .text
22313 extbl $3, $2, $3 !lituse_bytoff!1
22314 ldq $2, a($29) !literal!1
22315 ldq $4, b($29) !literal!2
22316 ldq_u $3, 0($2) !lituse_base!1
22317 ldq $27, f($29) !literal!5
22318 jsr $26, ($27), f !lituse_jsr!5
22319 ldah $29, 0($26) !gpdisp!3
22320 lda $0, c($29) !gprel
22321 ldah $1, d($29) !gprelhigh
22322 lda $1, d($1) !gprellow
8ada417f 22323 lda $29, 0($29) !gpdisp!3' > conftest.s
ba479fd2
NN
22324 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
22325 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22326 (eval $ac_try) 2>&5
22327 ac_status=$?
22328 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22329 (exit $ac_status); }; }
8ada417f
ZW
22330 then
22331 gcc_cv_as_alpha_explicit_relocs=yes
22332 else
22333 echo "configure: failed program was" >&5
22334 cat conftest.s >&5
22335 fi
22336 rm -f conftest.o conftest.s
22337 fi
cafe096b 22338fi
b61ff9c8
BS
22339echo "$as_me:$LINENO: result: $gcc_cv_as_alpha_explicit_relocs" >&5
22340echo "${ECHO_T}$gcc_cv_as_alpha_explicit_relocs" >&6
63cf211a 22341if test $gcc_cv_as_alpha_explicit_relocs = yes; then
ba479fd2
NN
22342
22343cat >>confdefs.h <<\_ACEOF
3a37b08e 22344#define HAVE_AS_EXPLICIT_RELOCS 1
ba479fd2 22345_ACEOF
3a37b08e 22346
d006f5eb 22347fi
b61ff9c8
BS
22348 echo "$as_me:$LINENO: checking assembler for jsrdirect relocation support" >&5
22349echo $ECHO_N "checking assembler for jsrdirect relocation support... $ECHO_C" >&6
d006f5eb
RH
22350if test "${gcc_cv_as_alpha_jsrdirect_relocs+set}" = set; then
22351 echo $ECHO_N "(cached) $ECHO_C" >&6
22352else
22353 gcc_cv_as_alpha_jsrdirect_relocs=no
22354 if test $in_tree_gas = yes; then
22355 if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 16 \) \* 1000 + 90`
22356 then gcc_cv_as_alpha_jsrdirect_relocs=yes
22357fi
22358 elif test x$gcc_cv_as != x; then
22359 echo ' .set nomacro
22360 .text
22361 ldq $27, a($29) !literal!1
22362 jsr $26, ($27), a !lituse_jsrdirect!1' > conftest.s
22363 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
22364 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22365 (eval $ac_try) 2>&5
22366 ac_status=$?
22367 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22368 (exit $ac_status); }; }
22369 then
22370 gcc_cv_as_alpha_jsrdirect_relocs=yes
22371 else
22372 echo "configure: failed program was" >&5
22373 cat conftest.s >&5
22374 fi
22375 rm -f conftest.o conftest.s
22376 fi
22377fi
b61ff9c8
BS
22378echo "$as_me:$LINENO: result: $gcc_cv_as_alpha_jsrdirect_relocs" >&5
22379echo "${ECHO_T}$gcc_cv_as_alpha_jsrdirect_relocs" >&6
d006f5eb
RH
22380if test $gcc_cv_as_alpha_jsrdirect_relocs = yes; then
22381
22382cat >>confdefs.h <<\_ACEOF
22383#define HAVE_AS_JSRDIRECT_RELOCS 1
22384_ACEOF
22385
86da66b5
HPN
22386fi
22387 ;;
22388
22389 cris-*-*)
b61ff9c8
BS
22390 echo "$as_me:$LINENO: checking assembler for -no-mul-bug-abort option" >&5
22391echo $ECHO_N "checking assembler for -no-mul-bug-abort option... $ECHO_C" >&6
86da66b5
HPN
22392if test "${gcc_cv_as_cris_no_mul_bug+set}" = set; then
22393 echo $ECHO_N "(cached) $ECHO_C" >&6
22394else
22395 gcc_cv_as_cris_no_mul_bug=no
22396 if test $in_tree_gas = yes; then
22397 if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 15 \) \* 1000 + 91`
22398 then gcc_cv_as_cris_no_mul_bug=yes
22399fi
22400 elif test x$gcc_cv_as != x; then
22401 echo '.text' > conftest.s
22402 if { ac_try='$gcc_cv_as -no-mul-bug-abort -o conftest.o conftest.s >&5'
22403 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22404 (eval $ac_try) 2>&5
22405 ac_status=$?
22406 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22407 (exit $ac_status); }; }
22408 then
22409 gcc_cv_as_cris_no_mul_bug=yes
22410 else
22411 echo "configure: failed program was" >&5
22412 cat conftest.s >&5
22413 fi
22414 rm -f conftest.o conftest.s
22415 fi
22416fi
b61ff9c8
BS
22417echo "$as_me:$LINENO: result: $gcc_cv_as_cris_no_mul_bug" >&5
22418echo "${ECHO_T}$gcc_cv_as_cris_no_mul_bug" >&6
86da66b5
HPN
22419if test $gcc_cv_as_cris_no_mul_bug = yes; then
22420
22421cat >>confdefs.h <<\_ACEOF
22422#define HAVE_AS_NO_MUL_BUG_ABORT_OPTION 1
22423_ACEOF
22424
8ada417f 22425fi
3a37b08e 22426 ;;
8ada417f 22427
1cb36a98 22428 sparc*-*-*)
b61ff9c8
BS
22429 echo "$as_me:$LINENO: checking assembler for .register" >&5
22430echo $ECHO_N "checking assembler for .register... $ECHO_C" >&6
ba479fd2
NN
22431if test "${gcc_cv_as_sparc_register_op+set}" = set; then
22432 echo $ECHO_N "(cached) $ECHO_C" >&6
5b68c389 22433else
8ada417f
ZW
22434 gcc_cv_as_sparc_register_op=no
22435 if test x$gcc_cv_as != x; then
6e3f3080 22436 echo '.register %g2, #scratch' > conftest.s
ba479fd2
NN
22437 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
22438 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22439 (eval $ac_try) 2>&5
22440 ac_status=$?
22441 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22442 (exit $ac_status); }; }
8ada417f
ZW
22443 then
22444 gcc_cv_as_sparc_register_op=yes
22445 else
22446 echo "configure: failed program was" >&5
22447 cat conftest.s >&5
22448 fi
22449 rm -f conftest.o conftest.s
22450 fi
cafe096b 22451fi
b61ff9c8
BS
22452echo "$as_me:$LINENO: result: $gcc_cv_as_sparc_register_op" >&5
22453echo "${ECHO_T}$gcc_cv_as_sparc_register_op" >&6
63cf211a 22454if test $gcc_cv_as_sparc_register_op = yes; then
ba479fd2
NN
22455
22456cat >>confdefs.h <<\_ACEOF
1cb36a98 22457#define HAVE_AS_REGISTER_PSEUDO_OP 1
ba479fd2 22458_ACEOF
1cb36a98 22459
8ada417f 22460fi
1cb36a98 22461
b61ff9c8
BS
22462 echo "$as_me:$LINENO: checking assembler for -relax option" >&5
22463echo $ECHO_N "checking assembler for -relax option... $ECHO_C" >&6
ba479fd2
NN
22464if test "${gcc_cv_as_sparc_relax+set}" = set; then
22465 echo $ECHO_N "(cached) $ECHO_C" >&6
e95b1e6a 22466else
8ada417f
ZW
22467 gcc_cv_as_sparc_relax=no
22468 if test x$gcc_cv_as != x; then
6e3f3080 22469 echo '.text' > conftest.s
ba479fd2
NN
22470 if { ac_try='$gcc_cv_as -relax -o conftest.o conftest.s >&5'
22471 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22472 (eval $ac_try) 2>&5
22473 ac_status=$?
22474 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22475 (exit $ac_status); }; }
8ada417f
ZW
22476 then
22477 gcc_cv_as_sparc_relax=yes
22478 else
22479 echo "configure: failed program was" >&5
22480 cat conftest.s >&5
22481 fi
22482 rm -f conftest.o conftest.s
22483 fi
cafe096b 22484fi
b61ff9c8
BS
22485echo "$as_me:$LINENO: result: $gcc_cv_as_sparc_relax" >&5
22486echo "${ECHO_T}$gcc_cv_as_sparc_relax" >&6
63cf211a 22487if test $gcc_cv_as_sparc_relax = yes; then
ba479fd2
NN
22488
22489cat >>confdefs.h <<\_ACEOF
e95b1e6a 22490#define HAVE_AS_RELAX_OPTION 1
ba479fd2 22491_ACEOF
e95b1e6a 22492
8ada417f 22493fi
e95b1e6a 22494
b61ff9c8
BS
22495 echo "$as_me:$LINENO: checking assembler for unaligned pcrel relocs" >&5
22496echo $ECHO_N "checking assembler for unaligned pcrel relocs... $ECHO_C" >&6
ba479fd2
NN
22497if test "${gcc_cv_as_sparc_ua_pcrel+set}" = set; then
22498 echo $ECHO_N "(cached) $ECHO_C" >&6
17e9e88c 22499else
8ada417f
ZW
22500 gcc_cv_as_sparc_ua_pcrel=no
22501 if test x$gcc_cv_as != x; then
6e3f3080 22502 echo '.text
8ada417f
ZW
22503foo:
22504 nop
22505.data
22506.align 4
22507.byte 0
22508.uaword %r_disp32(foo)' > conftest.s
ba479fd2
NN
22509 if { ac_try='$gcc_cv_as -K PIC -o conftest.o conftest.s >&5'
22510 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22511 (eval $ac_try) 2>&5
22512 ac_status=$?
22513 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22514 (exit $ac_status); }; }
8ada417f
ZW
22515 then
22516 if test x$gcc_cv_ld != x \
22517 && $gcc_cv_ld -o conftest conftest.o -G > /dev/null 2>&1; then
22518 gcc_cv_as_sparc_ua_pcrel=yes
22519 fi
22520 rm -f conftest
22521 else
22522 echo "configure: failed program was" >&5
22523 cat conftest.s >&5
22524 fi
22525 rm -f conftest.o conftest.s
22526 fi
cafe096b 22527fi
b61ff9c8
BS
22528echo "$as_me:$LINENO: result: $gcc_cv_as_sparc_ua_pcrel" >&5
22529echo "${ECHO_T}$gcc_cv_as_sparc_ua_pcrel" >&6
63cf211a 22530if test $gcc_cv_as_sparc_ua_pcrel = yes; then
ba479fd2
NN
22531
22532cat >>confdefs.h <<\_ACEOF
17e9e88c 22533#define HAVE_AS_SPARC_UA_PCREL 1
ba479fd2 22534_ACEOF
17e9e88c 22535
17e9e88c 22536
b61ff9c8
BS
22537 echo "$as_me:$LINENO: checking assembler for unaligned pcrel relocs against hidden symbols" >&5
22538echo $ECHO_N "checking assembler for unaligned pcrel relocs against hidden symbols... $ECHO_C" >&6
ba479fd2
NN
22539if test "${gcc_cv_as_sparc_ua_pcrel_hidden+set}" = set; then
22540 echo $ECHO_N "(cached) $ECHO_C" >&6
cf7b8b0d 22541else
8ada417f
ZW
22542 gcc_cv_as_sparc_ua_pcrel_hidden=no
22543 if test x$gcc_cv_as != x; then
6e3f3080 22544 echo '.data
8ada417f
ZW
22545.align 4
22546.byte 0x31
22547.uaword %r_disp32(foo)
22548.byte 0x32, 0x33, 0x34
22549.global foo
22550.hidden foo
22551foo:
22552.skip 4' > conftest.s
ba479fd2
NN
22553 if { ac_try='$gcc_cv_as -K PIC -o conftest.o conftest.s >&5'
22554 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22555 (eval $ac_try) 2>&5
22556 ac_status=$?
22557 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22558 (exit $ac_status); }; }
8ada417f
ZW
22559 then
22560 if test x$gcc_cv_ld != x && test x$gcc_cv_objdump != x \
22561 && $gcc_cv_ld -o conftest conftest.o -G > /dev/null 2>&1 \
22562 && $gcc_cv_objdump -s -j .data conftest 2> /dev/null \
22563 | grep ' 31000000 07323334' > /dev/null 2>&1; then
22564 if $gcc_cv_objdump -R conftest 2> /dev/null \
22565 | grep 'DISP32' > /dev/null 2>&1; then
22566 :
22567 else
22568 gcc_cv_as_sparc_ua_pcrel_hidden=yes
cf7b8b0d 22569 fi
8ada417f
ZW
22570 fi
22571 rm -f conftest
22572 else
22573 echo "configure: failed program was" >&5
22574 cat conftest.s >&5
22575 fi
22576 rm -f conftest.o conftest.s
22577 fi
cafe096b 22578fi
b61ff9c8
BS
22579echo "$as_me:$LINENO: result: $gcc_cv_as_sparc_ua_pcrel_hidden" >&5
22580echo "${ECHO_T}$gcc_cv_as_sparc_ua_pcrel_hidden" >&6
63cf211a 22581if test $gcc_cv_as_sparc_ua_pcrel_hidden = yes; then
ba479fd2
NN
22582
22583cat >>confdefs.h <<\_ACEOF
cf7b8b0d 22584#define HAVE_AS_SPARC_UA_PCREL_HIDDEN 1
ba479fd2 22585_ACEOF
cf7b8b0d 22586
8ada417f 22587fi
ba479fd2 22588
8ada417f 22589fi # unaligned pcrel relocs
cf7b8b0d 22590
b61ff9c8
BS
22591 echo "$as_me:$LINENO: checking assembler for offsetable %lo()" >&5
22592echo $ECHO_N "checking assembler for offsetable %lo()... $ECHO_C" >&6
ba479fd2
NN
22593if test "${gcc_cv_as_sparc_offsetable_lo10+set}" = set; then
22594 echo $ECHO_N "(cached) $ECHO_C" >&6
5b68c389 22595else
8ada417f
ZW
22596 gcc_cv_as_sparc_offsetable_lo10=no
22597 if test x$gcc_cv_as != x; then
6e3f3080 22598 echo '.text
8ada417f
ZW
22599 or %g1, %lo(ab) + 12, %g1
22600 or %g1, %lo(ab + 12), %g1' > conftest.s
ba479fd2
NN
22601 if { ac_try='$gcc_cv_as -xarch=v9 -o conftest.o conftest.s >&5'
22602 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22603 (eval $ac_try) 2>&5
22604 ac_status=$?
22605 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22606 (exit $ac_status); }; }
8ada417f
ZW
22607 then
22608 if test x$gcc_cv_objdump != x \
ecb0ccbc 22609 && $gcc_cv_objdump -s -j .text conftest.o 2> /dev/null \
8ada417f 22610 | grep ' 82106000 82106000' > /dev/null 2>&1; then
1b5c0152 22611 gcc_cv_as_sparc_offsetable_lo10=yes
8ada417f
ZW
22612 fi
22613 else
22614 echo "configure: failed program was" >&5
22615 cat conftest.s >&5
22616 fi
22617 rm -f conftest.o conftest.s
22618 fi
cafe096b 22619fi
b61ff9c8
BS
22620echo "$as_me:$LINENO: result: $gcc_cv_as_sparc_offsetable_lo10" >&5
22621echo "${ECHO_T}$gcc_cv_as_sparc_offsetable_lo10" >&6
63cf211a 22622if test $gcc_cv_as_sparc_offsetable_lo10 = yes; then
ba479fd2
NN
22623
22624cat >>confdefs.h <<\_ACEOF
1cb36a98 22625#define HAVE_AS_OFFSETABLE_LO10 1
ba479fd2 22626_ACEOF
1cb36a98 22627
8ada417f 22628fi
1cb36a98
RH
22629 ;;
22630
c307e6dd 22631 i[34567]86-*-* | x86_64-*-*)
d38bc601
BF
22632 case $target_os in
22633 cygwin* | pe | mingw32*)
233215fe
DK
22634 # Recent binutils allows the three-operand form of ".comm" on PE. This
22635 # definition is used unconditionally to initialise the default state of
22636 # the target option variable that governs usage of the feature.
22637 echo "$as_me:$LINENO: checking assembler for .comm with alignment" >&5
22638echo $ECHO_N "checking assembler for .comm with alignment... $ECHO_C" >&6
22639if test "${gcc_cv_as_comm_has_align+set}" = set; then
22640 echo $ECHO_N "(cached) $ECHO_C" >&6
22641else
22642 gcc_cv_as_comm_has_align=no
22643 if test $in_tree_gas = yes; then
22644 if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 19 \) \* 1000 + 52`
22645 then gcc_cv_as_comm_has_align=yes
22646fi
22647 elif test x$gcc_cv_as != x; then
22648 echo '.comm foo,1,32' > conftest.s
22649 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
22650 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22651 (eval $ac_try) 2>&5
22652 ac_status=$?
22653 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22654 (exit $ac_status); }; }
22655 then
22656 gcc_cv_as_comm_has_align=yes
22657 else
22658 echo "configure: failed program was" >&5
22659 cat conftest.s >&5
22660 fi
22661 rm -f conftest.o conftest.s
22662 fi
22663fi
22664echo "$as_me:$LINENO: result: $gcc_cv_as_comm_has_align" >&5
22665echo "${ECHO_T}$gcc_cv_as_comm_has_align" >&6
22666
22667
22668cat >>confdefs.h <<_ACEOF
22669#define HAVE_GAS_ALIGNED_COMM `if test $gcc_cv_as_comm_has_align = yes; then echo 1; else echo 0; fi`
22670_ACEOF
22671
d38bc601 22672 # Used for DWARF 2 in PE
b61ff9c8
BS
22673 echo "$as_me:$LINENO: checking assembler for .secrel32 relocs" >&5
22674echo $ECHO_N "checking assembler for .secrel32 relocs... $ECHO_C" >&6
d38bc601
BF
22675if test "${gcc_cv_as_ix86_pe_secrel32+set}" = set; then
22676 echo $ECHO_N "(cached) $ECHO_C" >&6
22677else
22678 gcc_cv_as_ix86_pe_secrel32=no
22679 if test $in_tree_gas = yes; then
22680 if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 15 \) \* 1000 + 91`
22681 then gcc_cv_as_ix86_pe_secrel32=yes
22682fi
22683 elif test x$gcc_cv_as != x; then
22684 echo '.text
22685foo: nop
22686.data
22687 .secrel32 foo' > conftest.s
22688 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
22689 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22690 (eval $ac_try) 2>&5
22691 ac_status=$?
22692 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22693 (exit $ac_status); }; }
22694 then
22695 if test x$gcc_cv_ld != x \
22696 && $gcc_cv_ld -o conftest conftest.o > /dev/null 2>&1; then
22697 gcc_cv_as_ix86_pe_secrel32=yes
22698 fi
22699 rm -f conftest
22700 else
22701 echo "configure: failed program was" >&5
22702 cat conftest.s >&5
22703 fi
22704 rm -f conftest.o conftest.s
22705 fi
22706fi
b61ff9c8
BS
22707echo "$as_me:$LINENO: result: $gcc_cv_as_ix86_pe_secrel32" >&5
22708echo "${ECHO_T}$gcc_cv_as_ix86_pe_secrel32" >&6
d38bc601
BF
22709if test $gcc_cv_as_ix86_pe_secrel32 = yes; then
22710
22711cat >>confdefs.h <<\_ACEOF
22712#define HAVE_GAS_PE_SECREL32_RELOC 1
22713_ACEOF
22714
22715fi
22716 ;;
22717 esac
22718
b61ff9c8
BS
22719 echo "$as_me:$LINENO: checking assembler for filds and fists mnemonics" >&5
22720echo $ECHO_N "checking assembler for filds and fists mnemonics... $ECHO_C" >&6
a3a5e3d1 22721if test "${gcc_cv_as_ix86_filds+set}" = set; then
ba479fd2 22722 echo $ECHO_N "(cached) $ECHO_C" >&6
8ada417f 22723else
a3a5e3d1
UB
22724 gcc_cv_as_ix86_filds=no
22725 if test x$gcc_cv_as != x; then
6e3f3080 22726 echo 'filds mem; fists mem' > conftest.s
ba479fd2
NN
22727 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
22728 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22729 (eval $ac_try) 2>&5
22730 ac_status=$?
22731 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22732 (exit $ac_status); }; }
8ada417f 22733 then
a3a5e3d1
UB
22734 gcc_cv_as_ix86_filds=yes
22735 else
22736 echo "configure: failed program was" >&5
22737 cat conftest.s >&5
22738 fi
22739 rm -f conftest.o conftest.s
22740 fi
22741fi
22742echo "$as_me:$LINENO: result: $gcc_cv_as_ix86_filds" >&5
22743echo "${ECHO_T}$gcc_cv_as_ix86_filds" >&6
22744if test $gcc_cv_as_ix86_filds = yes; then
22745
22746cat >>confdefs.h <<\_ACEOF
22747#define HAVE_AS_IX86_FILDS 1
22748_ACEOF
22749
22750fi
22751
22752 echo "$as_me:$LINENO: checking assembler for fildq and fistpq mnemonics" >&5
22753echo $ECHO_N "checking assembler for fildq and fistpq mnemonics... $ECHO_C" >&6
22754if test "${gcc_cv_as_ix86_fildq+set}" = set; then
22755 echo $ECHO_N "(cached) $ECHO_C" >&6
22756else
22757 gcc_cv_as_ix86_fildq=no
22758 if test x$gcc_cv_as != x; then
22759 echo 'fildq mem; fistpq mem' > conftest.s
22760 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
22761 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22762 (eval $ac_try) 2>&5
22763 ac_status=$?
22764 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22765 (exit $ac_status); }; }
22766 then
22767 gcc_cv_as_ix86_fildq=yes
8ada417f
ZW
22768 else
22769 echo "configure: failed program was" >&5
22770 cat conftest.s >&5
981d4858 22771 fi
8ada417f
ZW
22772 rm -f conftest.o conftest.s
22773 fi
22774fi
a3a5e3d1
UB
22775echo "$as_me:$LINENO: result: $gcc_cv_as_ix86_fildq" >&5
22776echo "${ECHO_T}$gcc_cv_as_ix86_fildq" >&6
22777if test $gcc_cv_as_ix86_fildq = yes; then
ba479fd2
NN
22778
22779cat >>confdefs.h <<\_ACEOF
a3a5e3d1 22780#define HAVE_AS_IX86_FILDQ 1
ba479fd2 22781_ACEOF
ad9c4d9f 22782
f6f5dff2
RO
22783fi
22784
b61ff9c8
BS
22785 echo "$as_me:$LINENO: checking assembler for cmov syntax" >&5
22786echo $ECHO_N "checking assembler for cmov syntax... $ECHO_C" >&6
ba479fd2
NN
22787if test "${gcc_cv_as_ix86_cmov_sun_syntax+set}" = set; then
22788 echo $ECHO_N "(cached) $ECHO_C" >&6
f6f5dff2
RO
22789else
22790 gcc_cv_as_ix86_cmov_sun_syntax=no
22791 if test x$gcc_cv_as != x; then
6e3f3080 22792 echo 'cmovl.l %edx, %eax' > conftest.s
ba479fd2
NN
22793 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
22794 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22795 (eval $ac_try) 2>&5
22796 ac_status=$?
22797 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22798 (exit $ac_status); }; }
f6f5dff2
RO
22799 then
22800 gcc_cv_as_ix86_cmov_sun_syntax=yes
22801 else
22802 echo "configure: failed program was" >&5
22803 cat conftest.s >&5
22804 fi
22805 rm -f conftest.o conftest.s
22806 fi
22807fi
b61ff9c8
BS
22808echo "$as_me:$LINENO: result: $gcc_cv_as_ix86_cmov_sun_syntax" >&5
22809echo "${ECHO_T}$gcc_cv_as_ix86_cmov_sun_syntax" >&6
63cf211a 22810if test $gcc_cv_as_ix86_cmov_sun_syntax = yes; then
ba479fd2
NN
22811
22812cat >>confdefs.h <<\_ACEOF
f6f5dff2 22813#define HAVE_AS_IX86_CMOV_SUN_SYNTAX 1
ba479fd2 22814_ACEOF
f6f5dff2 22815
b6c03bcd
RS
22816fi
22817
b61ff9c8
BS
22818 echo "$as_me:$LINENO: checking assembler for ffreep mnemonic" >&5
22819echo $ECHO_N "checking assembler for ffreep mnemonic... $ECHO_C" >&6
b6c03bcd
RS
22820if test "${gcc_cv_as_ix86_ffreep+set}" = set; then
22821 echo $ECHO_N "(cached) $ECHO_C" >&6
22822else
22823 gcc_cv_as_ix86_ffreep=no
22824 if test x$gcc_cv_as != x; then
22825 echo 'ffreep %st(1)' > conftest.s
22826 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
22827 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22828 (eval $ac_try) 2>&5
22829 ac_status=$?
22830 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22831 (exit $ac_status); }; }
22832 then
22833 gcc_cv_as_ix86_ffreep=yes
22834 else
22835 echo "configure: failed program was" >&5
22836 cat conftest.s >&5
22837 fi
22838 rm -f conftest.o conftest.s
22839 fi
22840fi
b61ff9c8
BS
22841echo "$as_me:$LINENO: result: $gcc_cv_as_ix86_ffreep" >&5
22842echo "${ECHO_T}$gcc_cv_as_ix86_ffreep" >&6
b6c03bcd
RS
22843if test $gcc_cv_as_ix86_ffreep = yes; then
22844
22845cat >>confdefs.h <<\_ACEOF
22846#define HAVE_AS_IX86_FFREEP 1
22847_ACEOF
22848
38ca3765
UB
22849fi
22850
b61ff9c8
BS
22851 echo "$as_me:$LINENO: checking assembler for sahf mnemonic" >&5
22852echo $ECHO_N "checking assembler for sahf mnemonic... $ECHO_C" >&6
38ca3765
UB
22853if test "${gcc_cv_as_ix86_sahf+set}" = set; then
22854 echo $ECHO_N "(cached) $ECHO_C" >&6
22855else
22856 gcc_cv_as_ix86_sahf=no
22857 if test x$gcc_cv_as != x; then
22858 echo 'sahf' > conftest.s
22859 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
22860 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22861 (eval $ac_try) 2>&5
22862 ac_status=$?
22863 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22864 (exit $ac_status); }; }
22865 then
22866 gcc_cv_as_ix86_sahf=yes
22867 else
22868 echo "configure: failed program was" >&5
22869 cat conftest.s >&5
22870 fi
22871 rm -f conftest.o conftest.s
22872 fi
22873fi
b61ff9c8
BS
22874echo "$as_me:$LINENO: result: $gcc_cv_as_ix86_sahf" >&5
22875echo "${ECHO_T}$gcc_cv_as_ix86_sahf" >&6
38ca3765
UB
22876if test $gcc_cv_as_ix86_sahf = yes; then
22877
22878cat >>confdefs.h <<\_ACEOF
22879#define HAVE_AS_IX86_SAHF 1
22880_ACEOF
22881
68b92f78
RS
22882fi
22883
b61ff9c8
BS
22884 echo "$as_me:$LINENO: checking assembler for different section symbol subtraction" >&5
22885echo $ECHO_N "checking assembler for different section symbol subtraction... $ECHO_C" >&6
68b92f78
RS
22886if test "${gcc_cv_as_ix86_diff_sect_delta+set}" = set; then
22887 echo $ECHO_N "(cached) $ECHO_C" >&6
22888else
22889 gcc_cv_as_ix86_diff_sect_delta=no
22890 if test x$gcc_cv_as != x; then
22891 echo '.section .rodata
22892.L1:
22893 .long .L2-.L1
22894 .long .L3-.L1
22895 .text
22896.L3: nop
22897.L2: nop' > conftest.s
22898 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
22899 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22900 (eval $ac_try) 2>&5
22901 ac_status=$?
22902 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22903 (exit $ac_status); }; }
22904 then
22905 gcc_cv_as_ix86_diff_sect_delta=yes
22906 else
22907 echo "configure: failed program was" >&5
22908 cat conftest.s >&5
22909 fi
22910 rm -f conftest.o conftest.s
22911 fi
22912fi
b61ff9c8
BS
22913echo "$as_me:$LINENO: result: $gcc_cv_as_ix86_diff_sect_delta" >&5
22914echo "${ECHO_T}$gcc_cv_as_ix86_diff_sect_delta" >&6
68b92f78
RS
22915if test $gcc_cv_as_ix86_diff_sect_delta = yes; then
22916
22917cat >>confdefs.h <<\_ACEOF
22918#define HAVE_AS_IX86_DIFF_SECT_DELTA 1
22919_ACEOF
22920
ad9c4d9f
NN
22921fi
22922
6f3ca281
ZW
22923 # This one is used unconditionally by i386.[ch]; it is to be defined
22924 # to 1 if the feature is present, 0 otherwise.
b61ff9c8
BS
22925 echo "$as_me:$LINENO: checking assembler for GOTOFF in data" >&5
22926echo $ECHO_N "checking assembler for GOTOFF in data... $ECHO_C" >&6
ba479fd2
NN
22927if test "${gcc_cv_as_ix86_gotoff_in_data+set}" = set; then
22928 echo $ECHO_N "(cached) $ECHO_C" >&6
8ada417f
ZW
22929else
22930 gcc_cv_as_ix86_gotoff_in_data=no
22931 if test $in_tree_gas = yes; then
22932 if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 11 \) \* 1000 + 0`
22933 then gcc_cv_as_ix86_gotoff_in_data=yes
22934fi
22935 elif test x$gcc_cv_as != x; then
6e3f3080 22936 echo ' .text
f88c65f7
RH
22937.L0:
22938 nop
22939 .data
8ada417f 22940 .long .L0@GOTOFF' > conftest.s
ba479fd2
NN
22941 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
22942 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22943 (eval $ac_try) 2>&5
22944 ac_status=$?
22945 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22946 (exit $ac_status); }; }
8ada417f
ZW
22947 then
22948 gcc_cv_as_ix86_gotoff_in_data=yes
22949 else
22950 echo "configure: failed program was" >&5
22951 cat conftest.s >&5
f88c65f7 22952 fi
8ada417f
ZW
22953 rm -f conftest.o conftest.s
22954 fi
22955fi
b61ff9c8
BS
22956echo "$as_me:$LINENO: result: $gcc_cv_as_ix86_gotoff_in_data" >&5
22957echo "${ECHO_T}$gcc_cv_as_ix86_gotoff_in_data" >&6
8ada417f 22958
6f3ca281 22959
ba479fd2 22960cat >>confdefs.h <<_ACEOF
6f3ca281 22961#define HAVE_AS_GOTOFF_IN_DATA `if test $gcc_cv_as_ix86_gotoff_in_data = yes; then echo 1; else echo 0; fi`
ba479fd2 22962_ACEOF
f88c65f7 22963
1cb36a98 22964 ;;
ef1ecf87
RH
22965
22966 ia64*-*-*)
b61ff9c8
BS
22967 echo "$as_me:$LINENO: checking assembler for ltoffx and ldxmov relocs" >&5
22968echo $ECHO_N "checking assembler for ltoffx and ldxmov relocs... $ECHO_C" >&6
ba479fd2
NN
22969if test "${gcc_cv_as_ia64_ltoffx_ldxmov_relocs+set}" = set; then
22970 echo $ECHO_N "(cached) $ECHO_C" >&6
ef1ecf87 22971else
8ada417f
ZW
22972 gcc_cv_as_ia64_ltoffx_ldxmov_relocs=no
22973 if test $in_tree_gas = yes; then
22974 if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 14 \) \* 1000 + 0`
22975 then gcc_cv_as_ia64_ltoffx_ldxmov_relocs=yes
ad9c4d9f 22976fi
8ada417f 22977 elif test x$gcc_cv_as != x; then
6e3f3080 22978 echo ' .text
ef1ecf87
RH
22979 addl r15 = @ltoffx(x#), gp
22980 ;;
cfa9ee99 22981 ld8.mov r16 = [r15], x#' > conftest.s
ba479fd2
NN
22982 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
22983 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22984 (eval $ac_try) 2>&5
22985 ac_status=$?
22986 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22987 (exit $ac_status); }; }
8ada417f 22988 then
cfa9ee99 22989 gcc_cv_as_ia64_ltoffx_ldxmov_relocs=yes
8ada417f
ZW
22990 else
22991 echo "configure: failed program was" >&5
22992 cat conftest.s >&5
2c4a9cff 22993 fi
8ada417f
ZW
22994 rm -f conftest.o conftest.s
22995 fi
22996fi
b61ff9c8
BS
22997echo "$as_me:$LINENO: result: $gcc_cv_as_ia64_ltoffx_ldxmov_relocs" >&5
22998echo "${ECHO_T}$gcc_cv_as_ia64_ltoffx_ldxmov_relocs" >&6
63cf211a 22999if test $gcc_cv_as_ia64_ltoffx_ldxmov_relocs = yes; then
ba479fd2
NN
23000
23001cat >>confdefs.h <<\_ACEOF
cfa9ee99 23002#define HAVE_AS_LTOFFX_LDXMOV_RELOCS 1
ba479fd2 23003_ACEOF
8ada417f 23004
cfa9ee99 23005fi
8ada417f 23006
2c4a9cff 23007 ;;
8ada417f 23008
2c4a9cff 23009 powerpc*-*-*)
8ada417f 23010 case $target in
432218ba
DE
23011 *-*-aix*) conftest_s=' .machine "pwr5"
23012 .csect .text[PR]
6b37db3c 23013 mfcr 3,128';;
8af4d362 23014 *-*-darwin*)
b61ff9c8
BS
23015 echo "$as_me:$LINENO: checking assembler for .machine directive support" >&5
23016echo $ECHO_N "checking assembler for .machine directive support... $ECHO_C" >&6
8af4d362
PB
23017if test "${gcc_cv_as_machine_directive+set}" = set; then
23018 echo $ECHO_N "(cached) $ECHO_C" >&6
23019else
23020 gcc_cv_as_machine_directive=no
23021 if test x$gcc_cv_as != x; then
23022 echo ' .machine ppc7400' > conftest.s
23023 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
23024 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23025 (eval $ac_try) 2>&5
23026 ac_status=$?
23027 echo "$as_me:$LINENO: \$? = $ac_status" >&5
23028 (exit $ac_status); }; }
23029 then
23030 gcc_cv_as_machine_directive=yes
23031 else
23032 echo "configure: failed program was" >&5
23033 cat conftest.s >&5
23034 fi
23035 rm -f conftest.o conftest.s
23036 fi
23037fi
b61ff9c8
BS
23038echo "$as_me:$LINENO: result: $gcc_cv_as_machine_directive" >&5
23039echo "${ECHO_T}$gcc_cv_as_machine_directive" >&6
8af4d362
PB
23040
23041 if test x$gcc_cv_as_machine_directive != xyes; then
23042 echo "*** This target requires an assembler supporting \".machine\"" >&2
23043 echo you can get it from: ftp://gcc.gnu.org/pub/gcc/infrastructure/cctools-528.5.dmg >&2
23044 test x$build = x$target && exit 1
23045 fi
23046 conftest_s=' .text
6b37db3c 23047 mfcr r3,128';;
4c67db14 23048 *) conftest_s=' .machine power4
d2ab3e37 23049 .text
6b37db3c 23050 mfcr 3,128';;
8ada417f 23051 esac
8ada417f 23052
b61ff9c8
BS
23053 echo "$as_me:$LINENO: checking assembler for mfcr field support" >&5
23054echo $ECHO_N "checking assembler for mfcr field support... $ECHO_C" >&6
ba479fd2
NN
23055if test "${gcc_cv_as_powerpc_mfcrf+set}" = set; then
23056 echo $ECHO_N "(cached) $ECHO_C" >&6
2c4a9cff 23057else
8ada417f
ZW
23058 gcc_cv_as_powerpc_mfcrf=no
23059 if test $in_tree_gas = yes; then
23060 if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 14 \) \* 1000 + 0`
23061 then gcc_cv_as_powerpc_mfcrf=yes
2c4a9cff 23062fi
8ada417f 23063 elif test x$gcc_cv_as != x; then
6e3f3080 23064 echo "$conftest_s" > conftest.s
ba479fd2
NN
23065 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
23066 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23067 (eval $ac_try) 2>&5
23068 ac_status=$?
23069 echo "$as_me:$LINENO: \$? = $ac_status" >&5
23070 (exit $ac_status); }; }
8ada417f
ZW
23071 then
23072 gcc_cv_as_powerpc_mfcrf=yes
23073 else
23074 echo "configure: failed program was" >&5
23075 cat conftest.s >&5
23076 fi
23077 rm -f conftest.o conftest.s
23078 fi
2c4a9cff 23079fi
b61ff9c8
BS
23080echo "$as_me:$LINENO: result: $gcc_cv_as_powerpc_mfcrf" >&5
23081echo "${ECHO_T}$gcc_cv_as_powerpc_mfcrf" >&6
63cf211a 23082if test $gcc_cv_as_powerpc_mfcrf = yes; then
ba479fd2
NN
23083
23084cat >>confdefs.h <<\_ACEOF
2c4a9cff 23085#define HAVE_AS_MFCRF 1
ba479fd2 23086_ACEOF
ef1ecf87 23087
8ada417f 23088fi
432218ba
DE
23089
23090 case $target in
23091 *-*-aix*) conftest_s=' .machine "pwr5"
23092 .csect .text[PR]
23093 popcntb 3,3';;
23094 *) conftest_s=' .machine power5
23095 .text
23096 popcntb 3,3';;
23097 esac
23098
b61ff9c8
BS
23099 echo "$as_me:$LINENO: checking assembler for popcntb support" >&5
23100echo $ECHO_N "checking assembler for popcntb support... $ECHO_C" >&6
432218ba
DE
23101if test "${gcc_cv_as_powerpc_popcntb+set}" = set; then
23102 echo $ECHO_N "(cached) $ECHO_C" >&6
23103else
23104 gcc_cv_as_powerpc_popcntb=no
23105 if test $in_tree_gas = yes; then
23106 if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 17 \) \* 1000 + 0`
23107 then gcc_cv_as_powerpc_popcntb=yes
23108fi
23109 elif test x$gcc_cv_as != x; then
23110 echo "$conftest_s" > conftest.s
23111 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
23112 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23113 (eval $ac_try) 2>&5
23114 ac_status=$?
23115 echo "$as_me:$LINENO: \$? = $ac_status" >&5
23116 (exit $ac_status); }; }
23117 then
23118 gcc_cv_as_powerpc_popcntb=yes
23119 else
23120 echo "configure: failed program was" >&5
23121 cat conftest.s >&5
23122 fi
23123 rm -f conftest.o conftest.s
23124 fi
23125fi
b61ff9c8
BS
23126echo "$as_me:$LINENO: result: $gcc_cv_as_powerpc_popcntb" >&5
23127echo "${ECHO_T}$gcc_cv_as_powerpc_popcntb" >&6
432218ba
DE
23128if test $gcc_cv_as_powerpc_popcntb = yes; then
23129
23130cat >>confdefs.h <<\_ACEOF
23131#define HAVE_AS_POPCNTB 1
23132_ACEOF
23133
9719f3b7
DE
23134fi
23135
23136 case $target in
23137 *-*-aix*) conftest_s=' .machine "pwr5x"
23138 .csect .text[PR]
23139 frin 1,1';;
1e04bfdc 23140 *) conftest_s=' .machine power5
9719f3b7
DE
23141 .text
23142 frin 1,1';;
23143 esac
23144
b61ff9c8
BS
23145 echo "$as_me:$LINENO: checking assembler for fp round support" >&5
23146echo $ECHO_N "checking assembler for fp round support... $ECHO_C" >&6
9719f3b7
DE
23147if test "${gcc_cv_as_powerpc_fprnd+set}" = set; then
23148 echo $ECHO_N "(cached) $ECHO_C" >&6
23149else
23150 gcc_cv_as_powerpc_fprnd=no
23151 if test $in_tree_gas = yes; then
23152 if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 17 \) \* 1000 + 0`
23153 then gcc_cv_as_powerpc_fprnd=yes
23154fi
23155 elif test x$gcc_cv_as != x; then
23156 echo "$conftest_s" > conftest.s
23157 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
23158 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23159 (eval $ac_try) 2>&5
23160 ac_status=$?
23161 echo "$as_me:$LINENO: \$? = $ac_status" >&5
23162 (exit $ac_status); }; }
23163 then
23164 gcc_cv_as_powerpc_fprnd=yes
23165 else
23166 echo "configure: failed program was" >&5
23167 cat conftest.s >&5
23168 fi
23169 rm -f conftest.o conftest.s
23170 fi
23171fi
b61ff9c8
BS
23172echo "$as_me:$LINENO: result: $gcc_cv_as_powerpc_fprnd" >&5
23173echo "${ECHO_T}$gcc_cv_as_powerpc_fprnd" >&6
9719f3b7
DE
23174if test $gcc_cv_as_powerpc_fprnd = yes; then
23175
23176cat >>confdefs.h <<\_ACEOF
23177#define HAVE_AS_FPRND 1
23178_ACEOF
23179
44cd321e
PS
23180fi
23181
23182 case $target in
23183 *-*-aix*) conftest_s=' .machine "pwr6"
23184 .csect .text[PR]
23185 mffgpr 1,3';;
23186 *) conftest_s=' .machine power6
23187 .text
23188 mffgpr 1,3';;
23189 esac
23190
b61ff9c8
BS
23191 echo "$as_me:$LINENO: checking assembler for move fp gpr support" >&5
23192echo $ECHO_N "checking assembler for move fp gpr support... $ECHO_C" >&6
44cd321e
PS
23193if test "${gcc_cv_as_powerpc_mfpgpr+set}" = set; then
23194 echo $ECHO_N "(cached) $ECHO_C" >&6
23195else
23196 gcc_cv_as_powerpc_mfpgpr=no
23197 if test $in_tree_gas = yes; then
23198 if test $gcc_cv_gas_vers -ge `expr \( \( 9 \* 1000 \) + 99 \) \* 1000 + 0`
23199 then gcc_cv_as_powerpc_mfpgpr=yes
23200fi
23201 elif test x$gcc_cv_as != x; then
23202 echo "$conftest_s" > conftest.s
23203 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
23204 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23205 (eval $ac_try) 2>&5
23206 ac_status=$?
23207 echo "$as_me:$LINENO: \$? = $ac_status" >&5
23208 (exit $ac_status); }; }
23209 then
23210 gcc_cv_as_powerpc_mfpgpr=yes
23211 else
23212 echo "configure: failed program was" >&5
23213 cat conftest.s >&5
23214 fi
23215 rm -f conftest.o conftest.s
23216 fi
23217fi
b61ff9c8
BS
23218echo "$as_me:$LINENO: result: $gcc_cv_as_powerpc_mfpgpr" >&5
23219echo "${ECHO_T}$gcc_cv_as_powerpc_mfpgpr" >&6
44cd321e
PS
23220if test $gcc_cv_as_powerpc_mfpgpr = yes; then
23221
23222cat >>confdefs.h <<\_ACEOF
23223#define HAVE_AS_MFPGPR 1
23224_ACEOF
23225
432218ba
DE
23226fi
23227
7f970b70
AM
23228 case $target in
23229 *-*-aix*) conftest_s=' .csect .text[PR]
23230LCF..0:
23231 addis 11,30,_GLOBAL_OFFSET_TABLE_-LCF..0@ha';;
23232 *-*-darwin*)
23233 conftest_s=' .text
23234LCF0:
23235 addis r11,r30,_GLOBAL_OFFSET_TABLE_-LCF0@ha';;
23236 *) conftest_s=' .text
23237.LCF0:
23238 addis 11,30,_GLOBAL_OFFSET_TABLE_-.LCF0@ha';;
23239 esac
23240
b61ff9c8
BS
23241 echo "$as_me:$LINENO: checking assembler for rel16 relocs" >&5
23242echo $ECHO_N "checking assembler for rel16 relocs... $ECHO_C" >&6
695d8830
AS
23243if test "${gcc_cv_as_powerpc_rel16+set}" = set; then
23244 echo $ECHO_N "(cached) $ECHO_C" >&6
23245else
23246 gcc_cv_as_powerpc_rel16=no
23247 if test $in_tree_gas = yes; then
23248 if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 17 \) \* 1000 + 0`
23249 then gcc_cv_as_powerpc_rel16=yes
23250fi
23251 elif test x$gcc_cv_as != x; then
23252 echo "$conftest_s" > conftest.s
23253 if { ac_try='$gcc_cv_as -a32 -o conftest.o conftest.s >&5'
23254 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23255 (eval $ac_try) 2>&5
23256 ac_status=$?
23257 echo "$as_me:$LINENO: \$? = $ac_status" >&5
23258 (exit $ac_status); }; }
23259 then
23260 gcc_cv_as_powerpc_rel16=yes
23261 else
23262 echo "configure: failed program was" >&5
23263 cat conftest.s >&5
23264 fi
23265 rm -f conftest.o conftest.s
23266 fi
23267fi
b61ff9c8
BS
23268echo "$as_me:$LINENO: result: $gcc_cv_as_powerpc_rel16" >&5
23269echo "${ECHO_T}$gcc_cv_as_powerpc_rel16" >&6
695d8830
AS
23270if test $gcc_cv_as_powerpc_rel16 = yes; then
23271
23272cat >>confdefs.h <<\_ACEOF
23273#define HAVE_AS_REL16 1
23274_ACEOF
23275
23276fi
23277
b639c3c2
JJ
23278 case $target in
23279 *-*-aix*) conftest_s=' .machine "pwr6"
23280 .csect .text[PR]
23281 cmpb 3,4,5';;
23282 *) conftest_s=' .machine power6
23283 .text
23284 cmpb 3,4,5';;
23285 esac
23286
b61ff9c8
BS
23287 echo "$as_me:$LINENO: checking assembler for compare bytes support" >&5
23288echo $ECHO_N "checking assembler for compare bytes support... $ECHO_C" >&6
b639c3c2
JJ
23289if test "${gcc_cv_as_powerpc_cmpb+set}" = set; then
23290 echo $ECHO_N "(cached) $ECHO_C" >&6
23291else
23292 gcc_cv_as_powerpc_cmpb=no
23293 if test $in_tree_gas = yes; then
23294 if test $gcc_cv_gas_vers -ge `expr \( \( 9 \* 1000 \) + 99 \) \* 1000 + 0`
23295 then gcc_cv_as_powerpc_cmpb=yes
23296fi
23297 elif test x$gcc_cv_as != x; then
23298 echo "$conftest_s" > conftest.s
23299 if { ac_try='$gcc_cv_as -a32 -o conftest.o conftest.s >&5'
23300 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23301 (eval $ac_try) 2>&5
23302 ac_status=$?
23303 echo "$as_me:$LINENO: \$? = $ac_status" >&5
23304 (exit $ac_status); }; }
23305 then
23306 gcc_cv_as_powerpc_cmpb=yes
23307 else
23308 echo "configure: failed program was" >&5
23309 cat conftest.s >&5
23310 fi
23311 rm -f conftest.o conftest.s
23312 fi
23313fi
b61ff9c8
BS
23314echo "$as_me:$LINENO: result: $gcc_cv_as_powerpc_cmpb" >&5
23315echo "${ECHO_T}$gcc_cv_as_powerpc_cmpb" >&6
b639c3c2
JJ
23316if test $gcc_cv_as_powerpc_cmpb = yes; then
23317
23318cat >>confdefs.h <<\_ACEOF
23319#define HAVE_AS_CMPB 1
23320_ACEOF
23321
23322fi
23323
23324 case $target in
23325 *-*-aix*) conftest_s=' .machine "pwr6"
23326 .csect .text[PR]
0d74c0ee 23327 dadd 1,2,3';;
b639c3c2
JJ
23328 *) conftest_s=' .machine power6
23329 .text
0d74c0ee 23330 dadd 1,2,3';;
b639c3c2
JJ
23331 esac
23332
b61ff9c8
BS
23333 echo "$as_me:$LINENO: checking assembler for decimal float support" >&5
23334echo $ECHO_N "checking assembler for decimal float support... $ECHO_C" >&6
b639c3c2
JJ
23335if test "${gcc_cv_as_powerpc_dfp+set}" = set; then
23336 echo $ECHO_N "(cached) $ECHO_C" >&6
23337else
23338 gcc_cv_as_powerpc_dfp=no
23339 if test $in_tree_gas = yes; then
23340 if test $gcc_cv_gas_vers -ge `expr \( \( 9 \* 1000 \) + 99 \) \* 1000 + 0`
23341 then gcc_cv_as_powerpc_dfp=yes
23342fi
23343 elif test x$gcc_cv_as != x; then
23344 echo "$conftest_s" > conftest.s
23345 if { ac_try='$gcc_cv_as -a32 -o conftest.o conftest.s >&5'
23346 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23347 (eval $ac_try) 2>&5
23348 ac_status=$?
23349 echo "$as_me:$LINENO: \$? = $ac_status" >&5
23350 (exit $ac_status); }; }
23351 then
23352 gcc_cv_as_powerpc_dfp=yes
23353 else
23354 echo "configure: failed program was" >&5
23355 cat conftest.s >&5
23356 fi
23357 rm -f conftest.o conftest.s
23358 fi
23359fi
b61ff9c8
BS
23360echo "$as_me:$LINENO: result: $gcc_cv_as_powerpc_dfp" >&5
23361echo "${ECHO_T}$gcc_cv_as_powerpc_dfp" >&6
b639c3c2
JJ
23362if test $gcc_cv_as_powerpc_dfp = yes; then
23363
23364cat >>confdefs.h <<\_ACEOF
23365#define HAVE_AS_DFP 1
23366_ACEOF
23367
d40c9e33
PB
23368fi
23369
23370 case $target in
23371 *-*-aix*) conftest_s=' .machine "pwr7"
23372 .csect .text[PR]
23373 lxvd2x 1,2,3';;
23374 *) conftest_s=' .machine power7
23375 .text
23376 lxvd2x 1,2,3';;
23377 esac
23378
23379 echo "$as_me:$LINENO: checking assembler for vector-scalar support" >&5
23380echo $ECHO_N "checking assembler for vector-scalar support... $ECHO_C" >&6
23381if test "${gcc_cv_as_powerpc_vsx+set}" = set; then
23382 echo $ECHO_N "(cached) $ECHO_C" >&6
23383else
23384 gcc_cv_as_powerpc_vsx=no
23385 if test $in_tree_gas = yes; then
23386 if test $gcc_cv_gas_vers -ge `expr \( \( 9 \* 1000 \) + 99 \) \* 1000 + 0`
23387 then gcc_cv_as_powerpc_vsx=yes
23388fi
23389 elif test x$gcc_cv_as != x; then
23390 echo "$conftest_s" > conftest.s
23391 if { ac_try='$gcc_cv_as -a32 -o conftest.o conftest.s >&5'
23392 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23393 (eval $ac_try) 2>&5
23394 ac_status=$?
23395 echo "$as_me:$LINENO: \$? = $ac_status" >&5
23396 (exit $ac_status); }; }
23397 then
23398 gcc_cv_as_powerpc_vsx=yes
23399 else
23400 echo "configure: failed program was" >&5
23401 cat conftest.s >&5
23402 fi
23403 rm -f conftest.o conftest.s
23404 fi
23405fi
23406echo "$as_me:$LINENO: result: $gcc_cv_as_powerpc_vsx" >&5
23407echo "${ECHO_T}$gcc_cv_as_powerpc_vsx" >&6
23408if test $gcc_cv_as_powerpc_vsx = yes; then
23409
23410cat >>confdefs.h <<\_ACEOF
23411#define HAVE_AS_VSX 1
23412_ACEOF
23413
e51917ae
JM
23414fi
23415
b61ff9c8
BS
23416 echo "$as_me:$LINENO: checking assembler for .gnu_attribute support" >&5
23417echo $ECHO_N "checking assembler for .gnu_attribute support... $ECHO_C" >&6
e51917ae
JM
23418if test "${gcc_cv_as_powerpc_gnu_attribute+set}" = set; then
23419 echo $ECHO_N "(cached) $ECHO_C" >&6
23420else
23421 gcc_cv_as_powerpc_gnu_attribute=no
23422 if test $in_tree_gas = yes; then
23423 if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 18 \) \* 1000 + 0`
23424 then gcc_cv_as_powerpc_gnu_attribute=yes
23425fi
23426 elif test x$gcc_cv_as != x; then
23427 echo '.gnu_attribute 4,1' > conftest.s
23428 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
23429 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23430 (eval $ac_try) 2>&5
23431 ac_status=$?
23432 echo "$as_me:$LINENO: \$? = $ac_status" >&5
23433 (exit $ac_status); }; }
23434 then
23435 gcc_cv_as_powerpc_gnu_attribute=yes
23436 else
23437 echo "configure: failed program was" >&5
23438 cat conftest.s >&5
23439 fi
23440 rm -f conftest.o conftest.s
23441 fi
23442fi
b61ff9c8
BS
23443echo "$as_me:$LINENO: result: $gcc_cv_as_powerpc_gnu_attribute" >&5
23444echo "${ECHO_T}$gcc_cv_as_powerpc_gnu_attribute" >&6
e51917ae
JM
23445if test $gcc_cv_as_powerpc_gnu_attribute = yes; then
23446
23447cat >>confdefs.h <<\_ACEOF
23448#define HAVE_AS_GNU_ATTRIBUTE 1
23449_ACEOF
23450
9752c4ad
AM
23451fi
23452
23453 echo "$as_me:$LINENO: checking assembler for tls marker support" >&5
23454echo $ECHO_N "checking assembler for tls marker support... $ECHO_C" >&6
23455if test "${gcc_cv_as_powerpc_tls_markers+set}" = set; then
23456 echo $ECHO_N "(cached) $ECHO_C" >&6
23457else
23458 gcc_cv_as_powerpc_tls_markers=no
23459 if test $in_tree_gas = yes; then
207bf79d 23460 if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 20 \) \* 1000 + 0`
9752c4ad
AM
23461 then gcc_cv_as_powerpc_tls_markers=yes
23462fi
23463 elif test x$gcc_cv_as != x; then
23464 echo ' bl __tls_get_addr(x@tlsgd)' > conftest.s
23465 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
23466 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23467 (eval $ac_try) 2>&5
23468 ac_status=$?
23469 echo "$as_me:$LINENO: \$? = $ac_status" >&5
23470 (exit $ac_status); }; }
23471 then
23472 gcc_cv_as_powerpc_tls_markers=yes
23473 else
23474 echo "configure: failed program was" >&5
23475 cat conftest.s >&5
23476 fi
23477 rm -f conftest.o conftest.s
23478 fi
23479fi
23480echo "$as_me:$LINENO: result: $gcc_cv_as_powerpc_tls_markers" >&5
23481echo "${ECHO_T}$gcc_cv_as_powerpc_tls_markers" >&6
23482if test $gcc_cv_as_powerpc_tls_markers = yes; then
23483
23484cat >>confdefs.h <<\_ACEOF
23485#define HAVE_AS_TLS_MARKERS 1
23486_ACEOF
23487
7f970b70 23488fi
8ada417f
ZW
23489 ;;
23490
23491 mips*-*-*)
b61ff9c8
BS
23492 echo "$as_me:$LINENO: checking assembler for explicit relocation support" >&5
23493echo $ECHO_N "checking assembler for explicit relocation support... $ECHO_C" >&6
ba479fd2
NN
23494if test "${gcc_cv_as_mips_explicit_relocs+set}" = set; then
23495 echo $ECHO_N "(cached) $ECHO_C" >&6
8ada417f
ZW
23496else
23497 gcc_cv_as_mips_explicit_relocs=no
23498 if test $in_tree_gas = yes; then
23499 if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 14 \) \* 1000 + 0`
23500 then gcc_cv_as_mips_explicit_relocs=yes
23501fi
23502 elif test x$gcc_cv_as != x; then
6e3f3080 23503 echo ' lw $4,%gp_rel(foo)($4)' > conftest.s
ba479fd2
NN
23504 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
23505 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23506 (eval $ac_try) 2>&5
23507 ac_status=$?
23508 echo "$as_me:$LINENO: \$? = $ac_status" >&5
23509 (exit $ac_status); }; }
8ada417f
ZW
23510 then
23511 gcc_cv_as_mips_explicit_relocs=yes
23512 else
23513 echo "configure: failed program was" >&5
23514 cat conftest.s >&5
ef1ecf87 23515 fi
8ada417f
ZW
23516 rm -f conftest.o conftest.s
23517 fi
23518fi
b61ff9c8
BS
23519echo "$as_me:$LINENO: result: $gcc_cv_as_mips_explicit_relocs" >&5
23520echo "${ECHO_T}$gcc_cv_as_mips_explicit_relocs" >&6
8ada417f
ZW
23521if test $gcc_cv_as_mips_explicit_relocs = yes; then
23522 if test x$target_cpu_default = x
23523 then target_cpu_default=MASK_EXPLICIT_RELOCS
23524 else target_cpu_default="($target_cpu_default)|MASK_EXPLICIT_RELOCS"
23525 fi
4551169f 23526fi
b61ff9c8
BS
23527 echo "$as_me:$LINENO: checking assembler for -mno-shared support" >&5
23528echo $ECHO_N "checking assembler for -mno-shared support... $ECHO_C" >&6
4551169f
RS
23529if test "${gcc_cv_as_mips_no_shared+set}" = set; then
23530 echo $ECHO_N "(cached) $ECHO_C" >&6
23531else
23532 gcc_cv_as_mips_no_shared=no
23533 if test $in_tree_gas = yes; then
23534 if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 16 \) \* 1000 + 0`
23535 then gcc_cv_as_mips_no_shared=yes
23536fi
23537 elif test x$gcc_cv_as != x; then
23538 echo 'nop' > conftest.s
23539 if { ac_try='$gcc_cv_as -mno-shared -o conftest.o conftest.s >&5'
23540 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23541 (eval $ac_try) 2>&5
23542 ac_status=$?
23543 echo "$as_me:$LINENO: \$? = $ac_status" >&5
23544 (exit $ac_status); }; }
23545 then
23546 gcc_cv_as_mips_no_shared=yes
23547 else
23548 echo "configure: failed program was" >&5
23549 cat conftest.s >&5
23550 fi
23551 rm -f conftest.o conftest.s
23552 fi
23553fi
b61ff9c8
BS
23554echo "$as_me:$LINENO: result: $gcc_cv_as_mips_no_shared" >&5
23555echo "${ECHO_T}$gcc_cv_as_mips_no_shared" >&6
4551169f
RS
23556if test $gcc_cv_as_mips_no_shared = yes; then
23557
23558cat >>confdefs.h <<\_ACEOF
23559#define HAVE_AS_NO_SHARED 1
23560_ACEOF
23561
dcb957d9
JM
23562fi
23563
b61ff9c8
BS
23564 echo "$as_me:$LINENO: checking assembler for .gnu_attribute support" >&5
23565echo $ECHO_N "checking assembler for .gnu_attribute support... $ECHO_C" >&6
dcb957d9
JM
23566if test "${gcc_cv_as_mips_gnu_attribute+set}" = set; then
23567 echo $ECHO_N "(cached) $ECHO_C" >&6
23568else
23569 gcc_cv_as_mips_gnu_attribute=no
23570 if test $in_tree_gas = yes; then
23571 if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 18 \) \* 1000 + 0`
23572 then gcc_cv_as_mips_gnu_attribute=yes
23573fi
23574 elif test x$gcc_cv_as != x; then
23575 echo '.gnu_attribute 4,1' > conftest.s
23576 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
23577 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23578 (eval $ac_try) 2>&5
23579 ac_status=$?
23580 echo "$as_me:$LINENO: \$? = $ac_status" >&5
23581 (exit $ac_status); }; }
23582 then
23583 gcc_cv_as_mips_gnu_attribute=yes
23584 else
23585 echo "configure: failed program was" >&5
23586 cat conftest.s >&5
23587 fi
23588 rm -f conftest.o conftest.s
23589 fi
23590fi
b61ff9c8
BS
23591echo "$as_me:$LINENO: result: $gcc_cv_as_mips_gnu_attribute" >&5
23592echo "${ECHO_T}$gcc_cv_as_mips_gnu_attribute" >&6
dcb957d9
JM
23593if test $gcc_cv_as_mips_gnu_attribute = yes; then
23594
23595cat >>confdefs.h <<\_ACEOF
23596#define HAVE_AS_GNU_ATTRIBUTE 1
23597_ACEOF
23598
a44380d2
JM
23599fi
23600
b61ff9c8
BS
23601 echo "$as_me:$LINENO: checking assembler for .dtprelword support" >&5
23602echo $ECHO_N "checking assembler for .dtprelword support... $ECHO_C" >&6
a44380d2
JM
23603if test "${gcc_cv_as_mips_dtprelword+set}" = set; then
23604 echo $ECHO_N "(cached) $ECHO_C" >&6
23605else
23606 gcc_cv_as_mips_dtprelword=no
23607 if test $in_tree_gas = yes; then
23608 if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 18 \) \* 1000 + 0`
23609 then gcc_cv_as_mips_dtprelword=yes
23610fi
23611 elif test x$gcc_cv_as != x; then
23612 echo '.section .tdata,"awT",@progbits
23613x:
23614 .word 2
23615 .text
23616 .dtprelword x+0x8000' > conftest.s
23617 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
23618 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23619 (eval $ac_try) 2>&5
23620 ac_status=$?
23621 echo "$as_me:$LINENO: \$? = $ac_status" >&5
23622 (exit $ac_status); }; }
23623 then
23624 gcc_cv_as_mips_dtprelword=yes
23625 else
23626 echo "configure: failed program was" >&5
23627 cat conftest.s >&5
23628 fi
23629 rm -f conftest.o conftest.s
23630 fi
23631fi
b61ff9c8
BS
23632echo "$as_me:$LINENO: result: $gcc_cv_as_mips_dtprelword" >&5
23633echo "${ECHO_T}$gcc_cv_as_mips_dtprelword" >&6
a44380d2
JM
23634if test $gcc_cv_as_mips_dtprelword = yes; then
23635
23636cat >>confdefs.h <<\_ACEOF
23637#define HAVE_AS_DTPRELWORD 1
23638_ACEOF
23639
8ada417f 23640fi
dbad5e72
SE
23641 ;;
23642esac
8ada417f 23643
dbad5e72
SE
23644# Mips and HP-UX need the GNU assembler.
23645# Linux on IA64 might be able to use the Intel assembler.
23646
23647case "$target" in
23648 mips*-*-* | *-*-hpux* )
82563d35
RS
23649 if test x$gas_flag = xyes \
23650 || test x"$host" != x"$build" \
23651 || test ! -x "$gcc_cv_as" \
23652 || "$gcc_cv_as" -v < /dev/null 2>&1 | grep GNU > /dev/null; then
23653 :
23654 else
23655 echo "*** This configuration requires the GNU assembler" >&2
23656 exit 1
23657 fi
ef1ecf87 23658 ;;
1cb36a98 23659esac
dbad5e72 23660
9d147085
RH
23661# ??? Not all targets support dwarf2 debug_line, even within a version
23662# of gas. Moreover, we need to emit a valid instruction to trigger any
23663# info to the output file. So, as supported targets are added to gas 2.11,
23664# add some instruction here to (also) show we expect this might work.
23665# ??? Once 2.11 is released, probably need to add first known working
23666# version to the per-target configury.
23667case "$target" in
80486e06 23668 i?86*-*-* | mips*-*-* | alpha*-*-* | powerpc*-*-* | sparc*-*-* | m68*-*-* \
cd985f66 23669 | x86_64*-*-* | hppa*-*-* | arm*-*-* \
ad9646c7 23670 | xstormy16*-*-* | cris-*-* | crisv32-*-* | xtensa*-*-* | bfin-*-* | score*-*-* \
15a43677 23671 | spu-*-* | fido*-*-* | m32c-*-*)
9d147085
RH
23672 insn="nop"
23673 ;;
57116d8d 23674 ia64*-*-* | s390*-*-*)
9d147085
RH
23675 insn="nop 0"
23676 ;;
2853bc5a
HPN
23677 mmix-*-*)
23678 insn="swym 0"
23679 ;;
8ada417f
ZW
23680esac
23681if test x"$insn" != x; then
23682 conftest_s="\
23683 .file 1 \"conftest.s\"
23684 .loc 1 3 0
23685 $insn"
b61ff9c8
BS
23686 echo "$as_me:$LINENO: checking assembler for dwarf2 debug_line support" >&5
23687echo $ECHO_N "checking assembler for dwarf2 debug_line support... $ECHO_C" >&6
ba479fd2
NN
23688if test "${gcc_cv_as_dwarf2_debug_line+set}" = set; then
23689 echo $ECHO_N "(cached) $ECHO_C" >&6
8ada417f
ZW
23690else
23691 gcc_cv_as_dwarf2_debug_line=no
23692 if test $in_tree_gas = yes; then
23693 if test $in_tree_gas_is_elf = yes \
23694 && test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 11 \) \* 1000 + 0`
23695 then gcc_cv_as_dwarf2_debug_line=yes
23696fi
23697 elif test x$gcc_cv_as != x; then
6e3f3080 23698 echo "$conftest_s" > conftest.s
ba479fd2
NN
23699 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
23700 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23701 (eval $ac_try) 2>&5
23702 ac_status=$?
23703 echo "$as_me:$LINENO: \$? = $ac_status" >&5
23704 (exit $ac_status); }; }
8ada417f 23705 then
080a5bb0
EB
23706 if test x$gcc_cv_objdump != x \
23707 && $gcc_cv_objdump -h conftest.o 2> /dev/null \
23708 | grep debug_line > /dev/null 2>&1; then
8ada417f
ZW
23709 gcc_cv_as_dwarf2_debug_line=yes
23710 fi
23711 else
23712 echo "configure: failed program was" >&5
23713 cat conftest.s >&5
23714 fi
23715 rm -f conftest.o conftest.s
23716 fi
23717fi
b61ff9c8
BS
23718echo "$as_me:$LINENO: result: $gcc_cv_as_dwarf2_debug_line" >&5
23719echo "${ECHO_T}$gcc_cv_as_dwarf2_debug_line" >&6
ad9c4d9f 23720
ad9c4d9f 23721
8ada417f
ZW
23722# The .debug_line file table must be in the exact order that
23723# we specified the files, since these indices are also used
23724# by DW_AT_decl_file. Approximate this test by testing if
23725# the assembler bitches if the same index is assigned twice.
b61ff9c8
BS
23726 echo "$as_me:$LINENO: checking assembler for buggy dwarf2 .file directive" >&5
23727echo $ECHO_N "checking assembler for buggy dwarf2 .file directive... $ECHO_C" >&6
ba479fd2
NN
23728if test "${gcc_cv_as_dwarf2_file_buggy+set}" = set; then
23729 echo $ECHO_N "(cached) $ECHO_C" >&6
8ada417f
ZW
23730else
23731 gcc_cv_as_dwarf2_file_buggy=no
23732 if test x$gcc_cv_as != x; then
6e3f3080 23733 echo ' .file 1 "foo.s"
8ada417f 23734 .file 1 "bar.s"' > conftest.s
ba479fd2
NN
23735 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
23736 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23737 (eval $ac_try) 2>&5
23738 ac_status=$?
23739 echo "$as_me:$LINENO: \$? = $ac_status" >&5
23740 (exit $ac_status); }; }
8ada417f
ZW
23741 then
23742 gcc_cv_as_dwarf2_file_buggy=yes
23743 else
23744 echo "configure: failed program was" >&5
23745 cat conftest.s >&5
23746 fi
23747 rm -f conftest.o conftest.s
23748 fi
ad9c4d9f 23749fi
b61ff9c8
BS
23750echo "$as_me:$LINENO: result: $gcc_cv_as_dwarf2_file_buggy" >&5
23751echo "${ECHO_T}$gcc_cv_as_dwarf2_file_buggy" >&6
8ada417f
ZW
23752
23753
23754 if test $gcc_cv_as_dwarf2_debug_line = yes \
23755 && test $gcc_cv_as_dwarf2_file_buggy = no; then
ba479fd2
NN
23756
23757cat >>confdefs.h <<\_ACEOF
9d147085 23758#define HAVE_AS_DWARF2_DEBUG_LINE 1
ba479fd2 23759_ACEOF
9d147085 23760
8ada417f 23761 fi
ad9c4d9f 23762
b61ff9c8
BS
23763 echo "$as_me:$LINENO: checking assembler for --gdwarf2 option" >&5
23764echo $ECHO_N "checking assembler for --gdwarf2 option... $ECHO_C" >&6
ba479fd2
NN
23765if test "${gcc_cv_as_gdwarf2_flag+set}" = set; then
23766 echo $ECHO_N "(cached) $ECHO_C" >&6
8ada417f
ZW
23767else
23768 gcc_cv_as_gdwarf2_flag=no
23769 if test $in_tree_gas = yes; then
23770 if test $in_tree_gas_is_elf = yes \
23771 && test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 11 \) \* 1000 + 0`
23772 then gcc_cv_as_gdwarf2_flag=yes
23773fi
23774 elif test x$gcc_cv_as != x; then
6e3f3080 23775 echo "$insn" > conftest.s
ba479fd2
NN
23776 if { ac_try='$gcc_cv_as --gdwarf2 -o conftest.o conftest.s >&5'
23777 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23778 (eval $ac_try) 2>&5
23779 ac_status=$?
23780 echo "$as_me:$LINENO: \$? = $ac_status" >&5
23781 (exit $ac_status); }; }
8ada417f
ZW
23782 then
23783 gcc_cv_as_gdwarf2_flag=yes
23784 else
23785 echo "configure: failed program was" >&5
23786 cat conftest.s >&5
23787 fi
23788 rm -f conftest.o conftest.s
23789 fi
ad9c4d9f 23790fi
b61ff9c8
BS
23791echo "$as_me:$LINENO: result: $gcc_cv_as_gdwarf2_flag" >&5
23792echo "${ECHO_T}$gcc_cv_as_gdwarf2_flag" >&6
63cf211a 23793if test $gcc_cv_as_gdwarf2_flag = yes; then
ba479fd2
NN
23794
23795cat >>confdefs.h <<\_ACEOF
5f0e9ea2 23796#define HAVE_AS_GDWARF2_DEBUG_FLAG 1
ba479fd2 23797_ACEOF
5f0e9ea2
GK
23798
23799fi
ad9c4d9f 23800
b61ff9c8
BS
23801 echo "$as_me:$LINENO: checking assembler for --gstabs option" >&5
23802echo $ECHO_N "checking assembler for --gstabs option... $ECHO_C" >&6
ba479fd2
NN
23803if test "${gcc_cv_as_gstabs_flag+set}" = set; then
23804 echo $ECHO_N "(cached) $ECHO_C" >&6
8ada417f
ZW
23805else
23806 gcc_cv_as_gstabs_flag=no
23807 if test $in_tree_gas = yes; then
23808 if test $in_tree_gas_is_elf = yes \
23809 && test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 11 \) \* 1000 + 0`
23810 then gcc_cv_as_gstabs_flag=yes
23811fi
23812 elif test x$gcc_cv_as != x; then
6e3f3080 23813 echo "$insn" > conftest.s
ba479fd2
NN
23814 if { ac_try='$gcc_cv_as --gstabs -o conftest.o conftest.s >&5'
23815 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23816 (eval $ac_try) 2>&5
23817 ac_status=$?
23818 echo "$as_me:$LINENO: \$? = $ac_status" >&5
23819 (exit $ac_status); }; }
8ada417f
ZW
23820 then
23821 # The native Solaris 9/Intel assembler doesn't understand --gstabs
23822 # and warns about it, but still exits successfully. So check for
23823 # this.
ba479fd2
NN
23824 if { ac_try='$gcc_cv_as --gstabs -o conftest.o conftest.s 2>&1 | grep -i warning > /dev/null'
23825 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23826 (eval $ac_try) 2>&5
23827 ac_status=$?
23828 echo "$as_me:$LINENO: \$? = $ac_status" >&5
23829 (exit $ac_status); }; }
8ada417f
ZW
23830 then :
23831 else gcc_cv_as_gstabs_flag=yes
23832 fi
23833 else
23834 echo "configure: failed program was" >&5
23835 cat conftest.s >&5
23836 fi
23837 rm -f conftest.o conftest.s
23838 fi
ad9c4d9f 23839fi
b61ff9c8
BS
23840echo "$as_me:$LINENO: result: $gcc_cv_as_gstabs_flag" >&5
23841echo "${ECHO_T}$gcc_cv_as_gstabs_flag" >&6
63cf211a 23842if test $gcc_cv_as_gstabs_flag = yes; then
ba479fd2
NN
23843
23844cat >>confdefs.h <<\_ACEOF
5f0e9ea2 23845#define HAVE_AS_GSTABS_DEBUG_FLAG 1
ba479fd2 23846_ACEOF
5f0e9ea2 23847
c8aea42c
PB
23848fi
23849
b61ff9c8
BS
23850 echo "$as_me:$LINENO: checking assembler for --debug-prefix-map option" >&5
23851echo $ECHO_N "checking assembler for --debug-prefix-map option... $ECHO_C" >&6
c8aea42c
PB
23852if test "${gcc_cv_as_debug_prefix_map_flag+set}" = set; then
23853 echo $ECHO_N "(cached) $ECHO_C" >&6
23854else
23855 gcc_cv_as_debug_prefix_map_flag=no
23856 if test $in_tree_gas = yes; then
303a4698 23857 if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 18 \) \* 1000 + 0`
c8aea42c
PB
23858 then gcc_cv_as_debug_prefix_map_flag=yes
23859fi
23860 elif test x$gcc_cv_as != x; then
23861 echo "$insn" > conftest.s
23862 if { ac_try='$gcc_cv_as --debug-prefix-map /a=/b -o conftest.o conftest.s >&5'
23863 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23864 (eval $ac_try) 2>&5
23865 ac_status=$?
23866 echo "$as_me:$LINENO: \$? = $ac_status" >&5
23867 (exit $ac_status); }; }
23868 then
23869 gcc_cv_as_debug_prefix_map_flag=yes
23870 else
23871 echo "configure: failed program was" >&5
23872 cat conftest.s >&5
23873 fi
23874 rm -f conftest.o conftest.s
23875 fi
23876fi
b61ff9c8
BS
23877echo "$as_me:$LINENO: result: $gcc_cv_as_debug_prefix_map_flag" >&5
23878echo "${ECHO_T}$gcc_cv_as_debug_prefix_map_flag" >&6
c8aea42c
PB
23879if test $gcc_cv_as_debug_prefix_map_flag = yes; then
23880
23881cat >>confdefs.h <<\_ACEOF
23882#define HAVE_AS_DEBUG_PREFIX_MAP 1
23883_ACEOF
23884
5f0e9ea2 23885fi
8ada417f 23886fi
5f0e9ea2 23887
28e6bb13
NC
23888echo "$as_me:$LINENO: checking assembler for .lcomm with alignment" >&5
23889echo $ECHO_N "checking assembler for .lcomm with alignment... $ECHO_C" >&6
23890if test "${gcc_cv_as_lcomm_with_alignment+set}" = set; then
23891 echo $ECHO_N "(cached) $ECHO_C" >&6
23892else
23893 gcc_cv_as_lcomm_with_alignment=no
23894 if test x$gcc_cv_as != x; then
23895 echo '.lcomm bar,4,16' > conftest.s
23896 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5'
23897 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23898 (eval $ac_try) 2>&5
23899 ac_status=$?
23900 echo "$as_me:$LINENO: \$? = $ac_status" >&5
23901 (exit $ac_status); }; }
23902 then
23903 gcc_cv_as_lcomm_with_alignment=yes
23904 else
23905 echo "configure: failed program was" >&5
23906 cat conftest.s >&5
23907 fi
23908 rm -f conftest.o conftest.s
23909 fi
23910fi
23911echo "$as_me:$LINENO: result: $gcc_cv_as_lcomm_with_alignment" >&5
23912echo "${ECHO_T}$gcc_cv_as_lcomm_with_alignment" >&6
23913if test $gcc_cv_as_lcomm_with_alignment = yes; then
23914
23915cat >>confdefs.h <<\_ACEOF
23916#define HAVE_GAS_LCOMM_WITH_ALIGNMENT 1
23917_ACEOF
23918
23919fi
23920
b61ff9c8
BS
23921echo "$as_me:$LINENO: checking assembler for tolerance to line number 0" >&5
23922echo $ECHO_N "checking assembler for tolerance to line number 0... $ECHO_C" >&6
03943c05
AO
23923if test "${gcc_cv_as_line_zero+set}" = set; then
23924 echo $ECHO_N "(cached) $ECHO_C" >&6
23925else
23926 gcc_cv_as_line_zero=no
23927 if test $in_tree_gas = yes; then
cf0eb7a1
AO
23928 if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 16 \) \* 1000 + 91`
23929 then gcc_cv_as_line_zero=yes
03943c05
AO
23930fi
23931 elif test "x$gcc_cv_as" != x; then
23932 { echo '# 1 "test.s" 1'; echo '# 0 "" 2'; } > conftest.s
23933 if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5 2>conftest.out'
23934 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23935 (eval $ac_try) 2>&5
23936 ac_status=$?
23937 echo "$as_me:$LINENO: \$? = $ac_status" >&5
23938 (exit $ac_status); }; } &&
23939 test "x`cat conftest.out`" = x
23940 then
23941 gcc_cv_as_line_zero=yes
23942 else
23943 echo "configure: failed program was" >&5
23944 cat conftest.s >&5
23945 echo "configure: error output was" >&5
23946 cat conftest.out >&5
23947 fi
23948 rm -f conftest.o conftest.s conftest.out
23949 fi
23950fi
b61ff9c8
BS
23951echo "$as_me:$LINENO: result: $gcc_cv_as_line_zero" >&5
23952echo "${ECHO_T}$gcc_cv_as_line_zero" >&6
03943c05
AO
23953if test "x$gcc_cv_as_line_zero" = xyes; then
23954
23955cat >>confdefs.h <<\_ACEOF
23956#define HAVE_AS_LINE_ZERO 1
23957_ACEOF
23958
23959fi
23960
b61ff9c8
BS
23961echo "$as_me:$LINENO: checking linker PT_GNU_EH_FRAME support" >&5
23962echo $ECHO_N "checking linker PT_GNU_EH_FRAME support... $ECHO_C" >&6
275b60d6 23963gcc_cv_ld_eh_frame_hdr=no
34a86c2b 23964if test $in_tree_ld = yes ; then
5408ac6c
HPN
23965 if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 12 -o "$gcc_cv_gld_major_version" -gt 2 \
23966 && test $in_tree_ld_is_elf = yes; then
275b60d6
JJ
23967 gcc_cv_ld_eh_frame_hdr=yes
23968 fi
23969elif test x$gcc_cv_ld != x; then
23970 # Check if linker supports --eh-frame-hdr option
23971 if $gcc_cv_ld --help 2>/dev/null | grep eh-frame-hdr > /dev/null; then
23972 gcc_cv_ld_eh_frame_hdr=yes
23973 fi
23974fi
232b67d9 23975
275b60d6 23976if test x"$gcc_cv_ld_eh_frame_hdr" = xyes; then
ba479fd2
NN
23977
23978cat >>confdefs.h <<\_ACEOF
275b60d6 23979#define HAVE_LD_EH_FRAME_HDR 1
ba479fd2 23980_ACEOF
275b60d6
JJ
23981
23982fi
b61ff9c8
BS
23983echo "$as_me:$LINENO: result: $gcc_cv_ld_eh_frame_hdr" >&5
23984echo "${ECHO_T}$gcc_cv_ld_eh_frame_hdr" >&6
275b60d6 23985
b61ff9c8
BS
23986echo "$as_me:$LINENO: checking linker position independent executable support" >&5
23987echo $ECHO_N "checking linker position independent executable support... $ECHO_C" >&6
24a4dd31
JJ
23988gcc_cv_ld_pie=no
23989if test $in_tree_ld = yes ; then
5408ac6c
HPN
23990 if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 15 -o "$gcc_cv_gld_major_version" -gt 2 \
23991 && test $in_tree_ld_is_elf = yes; then
24a4dd31
JJ
23992 gcc_cv_ld_pie=yes
23993 fi
23994elif test x$gcc_cv_ld != x; then
23995 # Check if linker supports -pie option
23996 if $gcc_cv_ld --help 2>/dev/null | grep -- -pie > /dev/null; then
23997 gcc_cv_ld_pie=yes
23998 fi
23999fi
24000if test x"$gcc_cv_ld_pie" = xyes; then
ba479fd2
NN
24001
24002cat >>confdefs.h <<\_ACEOF
24a4dd31 24003#define HAVE_LD_PIE 1
ba479fd2 24004_ACEOF
24a4dd31
JJ
24005
24006fi
b61ff9c8
BS
24007echo "$as_me:$LINENO: result: $gcc_cv_ld_pie" >&5
24008echo "${ECHO_T}$gcc_cv_ld_pie" >&6
24a4dd31 24009
b61ff9c8
BS
24010echo "$as_me:$LINENO: checking linker EH-compatible garbage collection of sections" >&5
24011echo $ECHO_N "checking linker EH-compatible garbage collection of sections... $ECHO_C" >&6
22ba88ef 24012gcc_cv_ld_eh_gc_sections=no
b639c3c2
JJ
24013if test $in_tree_ld = yes ; then
24014 if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 17 -o "$gcc_cv_gld_major_version" -gt 2 \
24015 && test $in_tree_ld_is_elf = yes; then
24016 gcc_cv_ld_eh_gc_sections=yes
24017 fi
24018elif test x$gcc_cv_as != x -a x$gcc_cv_ld != x -a x$gcc_cv_objdump != x ; then
24019 cat > conftest.s <<EOF
24020 .section .text
24021.globl _start
24022 .type _start, @function
24023_start:
24024 .long foo
24025 .size _start, .-_start
24026 .section .text.foo,"ax",@progbits
24027 .type foo, @function
24028foo:
24029 .long 0
24030 .size foo, .-foo
24031 .section .gcc_except_table.foo,"a",@progbits
24032.L0:
24033 .long 0
24034 .section .eh_frame,"a",@progbits
24035 .long .L0
24036EOF
24037 if $gcc_cv_as -o conftest.o conftest.s > /dev/null 2>&1; then
24038 if $gcc_cv_ld -o conftest conftest.o --entry=_start --gc-sections 2>&1 \
24039 | grep "gc-sections option ignored" > /dev/null; then
24040 gcc_cv_ld_eh_gc_sections=no
24041 elif $gcc_cv_objdump -h conftest | grep gcc_except_table > /dev/null; then
24042 gcc_cv_ld_eh_gc_sections=yes
24043 # If no COMDAT groups, the compiler will emit .gnu.linkonce.t. sections.
24044 if test x$gcc_cv_as_comdat_group != xyes; then
24045 gcc_cv_ld_eh_gc_sections=no
24046 cat > conftest.s <<EOF
24047 .section .text
24048.globl _start
24049 .type _start, @function
24050_start:
24051 .long foo
24052 .size _start, .-_start
24053 .section .gnu.linkonce.t.foo,"ax",@progbits
24054 .type foo, @function
24055foo:
24056 .long 0
24057 .size foo, .-foo
24058 .section .gcc_except_table.foo,"a",@progbits
24059.L0:
24060 .long 0
24061 .section .eh_frame,"a",@progbits
24062 .long .L0
24063EOF
24064 if $gcc_cv_as -o conftest.o conftest.s > /dev/null 2>&1; then
24065 if $gcc_cv_ld -o conftest conftest.o --entry=_start --gc-sections 2>&1 \
24066 | grep "gc-sections option ignored" > /dev/null; then
24067 gcc_cv_ld_eh_gc_sections=no
24068 elif $gcc_cv_objdump -h conftest | grep gcc_except_table > /dev/null; then
24069 gcc_cv_ld_eh_gc_sections=yes
24070 fi
24071 fi
24072 fi
24073 fi
24074 fi
24075 rm -f conftest.s conftest.o conftest
24076fi
e9d207d9
EB
24077case "$target" in
24078 hppa*-*-linux*)
24079 # ??? This apparently exposes a binutils bug with PC-relative relocations.
24080 gcc_cv_ld_eh_gc_sections=no
24081 ;;
24082esac
22ba88ef
EB
24083if test x$gcc_cv_ld_eh_gc_sections = xyes; then
24084
24085cat >>confdefs.h <<\_ACEOF
24086#define HAVE_LD_EH_GC_SECTIONS 1
24087_ACEOF
24088
24089fi
b61ff9c8
BS
24090echo "$as_me:$LINENO: result: $gcc_cv_ld_eh_gc_sections" >&5
24091echo "${ECHO_T}$gcc_cv_ld_eh_gc_sections" >&6
22ba88ef 24092
8bb915b6
NN
24093# --------
24094# UNSORTED
24095# --------
24096
b61ff9c8
BS
24097echo "$as_me:$LINENO: checking linker --as-needed support" >&5
24098echo $ECHO_N "checking linker --as-needed support... $ECHO_C" >&6
82e923f6
RS
24099if test "${gcc_cv_ld_as_needed+set}" = set; then
24100 echo $ECHO_N "(cached) $ECHO_C" >&6
24101else
24102 gcc_cv_ld_as_needed=no
765f1bf9
AM
24103if test $in_tree_ld = yes ; then
24104 if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 16 -o "$gcc_cv_gld_major_version" -gt 2 \
24105 && test $in_tree_ld_is_elf = yes; then
24106 gcc_cv_ld_as_needed=yes
24107 fi
24108elif test x$gcc_cv_ld != x; then
24109 # Check if linker supports --as-needed and --no-as-needed options
24110 if $gcc_cv_ld --help 2>/dev/null | grep as-needed > /dev/null; then
24111 gcc_cv_ld_as_needed=yes
24112 fi
24113fi
82e923f6
RS
24114
24115fi
b61ff9c8
BS
24116echo "$as_me:$LINENO: result: $gcc_cv_ld_as_needed" >&5
24117echo "${ECHO_T}$gcc_cv_ld_as_needed" >&6
765f1bf9
AM
24118if test x"$gcc_cv_ld_as_needed" = xyes; then
24119
24120cat >>confdefs.h <<\_ACEOF
24121#define HAVE_LD_AS_NEEDED 1
24122_ACEOF
24123
24124fi
765f1bf9 24125
d82bf747
AM
24126case "$target:$tm_file" in
24127 powerpc64*-*-linux* | powerpc*-*-linux*rs6000/biarch64.h*)
b61ff9c8
BS
24128 echo "$as_me:$LINENO: checking linker support for omitting dot symbols" >&5
24129echo $ECHO_N "checking linker support for omitting dot symbols... $ECHO_C" >&6
85b776df
AM
24130if test "${gcc_cv_ld_no_dot_syms+set}" = set; then
24131 echo $ECHO_N "(cached) $ECHO_C" >&6
24132else
24133 gcc_cv_ld_no_dot_syms=no
24134 if test $in_tree_ld = yes ; then
24135 if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 16 -o "$gcc_cv_gld_major_version" -gt 2; then
24136 gcc_cv_ld_no_dot_syms=yes
24137 fi
24138 elif test x$gcc_cv_as != x -a x$gcc_cv_ld != x ; then
24139 cat > conftest1.s <<EOF
24140 .text
24141 bl .foo
24142EOF
24143 cat > conftest2.s <<EOF
24144 .section ".opd","aw"
24145 .align 3
24146 .globl foo
24147 .type foo,@function
24148foo:
24149 .quad .LEfoo,.TOC.@tocbase,0
24150 .text
24151.LEfoo:
24152 blr
24153 .size foo,.-.LEfoo
24154EOF
24155 if $gcc_cv_as -a64 -o conftest1.o conftest1.s > /dev/null 2>&1 \
24156 && $gcc_cv_as -a64 -o conftest2.o conftest2.s > /dev/null 2>&1 \
24157 && $gcc_cv_ld -melf64ppc -o conftest conftest1.o conftest2.o > /dev/null 2>&1; then
24158 gcc_cv_ld_no_dot_syms=yes
24159 fi
24160 rm -f conftest conftest1.o conftest2.o conftest1.s conftest2.s
24161 fi
24162
24163fi
b61ff9c8
BS
24164echo "$as_me:$LINENO: result: $gcc_cv_ld_no_dot_syms" >&5
24165echo "${ECHO_T}$gcc_cv_ld_no_dot_syms" >&6
85b776df
AM
24166 if test x"$gcc_cv_ld_no_dot_syms" = xyes; then
24167
24168cat >>confdefs.h <<\_ACEOF
24169#define HAVE_LD_NO_DOT_SYMS 1
24170_ACEOF
24171
24172 fi
24173 ;;
24174esac
24175
cd533689
PP
24176echo "$as_me:$LINENO: checking linker --build-id support" >&5
24177echo $ECHO_N "checking linker --build-id support... $ECHO_C" >&6
24178if test "${gcc_cv_ld_buildid+set}" = set; then
24179 echo $ECHO_N "(cached) $ECHO_C" >&6
24180else
24181 gcc_cv_ld_buildid=no
24182 if test $in_tree_ld = yes ; then
24183 if test "$gcc_cv_gld_major_version" -eq 2 -a \
24184 "$gcc_cv_gld_minor_version" -ge 18 -o \
24185 "$gcc_cv_gld_major_version" -gt 2 \
24186 && test $in_tree_ld_is_elf = yes; then
24187 gcc_cv_ld_buildid=yes
24188 fi
24189 elif test x$gcc_cv_ld != x; then
24190 if $gcc_cv_ld --help 2>/dev/null | grep build-id > /dev/null; then
24191 gcc_cv_ld_buildid=yes
24192 fi
24193 fi
24194fi
24195echo "$as_me:$LINENO: result: $gcc_cv_ld_buildid" >&5
24196echo "${ECHO_T}$gcc_cv_ld_buildid" >&6
24197if test x"$gcc_cv_ld_buildid" = xyes; then
24198
24199cat >>confdefs.h <<\_ACEOF
24200#define HAVE_LD_BUILDID 1
24201_ACEOF
24202
24203fi
24204
24205# Check whether --enable-linker-build-id or --disable-linker-build-id was given.
24206if test "${enable_linker_build_id+set}" = set; then
24207 enableval="$enable_linker_build_id"
24208
24209else
24210 enable_linker_build_id=no
24211fi;
24212
24213if test x"$enable_linker_build_id" = xyes; then
24214 if test x"$gcc_cv_ld_buildid" = xyes; then
24215
24216cat >>confdefs.h <<\_ACEOF
24217#define ENABLE_LD_BUILDID 1
24218_ACEOF
24219
24220 else
24221 { echo "$as_me:$LINENO: WARNING: --build-id is not supported by your linker; --enable-linker-build-id ignored" >&5
24222echo "$as_me: WARNING: --build-id is not supported by your linker; --enable-linker-build-id ignored" >&2;}
24223 fi
24224fi
24225
b61ff9c8
BS
24226echo "$as_me:$LINENO: checking linker --sysroot support" >&5
24227echo $ECHO_N "checking linker --sysroot support... $ECHO_C" >&6
380e5ca4
MM
24228if test "${gcc_cv_ld_sysroot+set}" = set; then
24229 echo $ECHO_N "(cached) $ECHO_C" >&6
24230else
24231 gcc_cv_ld_sysroot=no
24232 if test $in_tree_ld = yes ; then
24233 if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 16 -o "$gcc_cv_gld_major_version" -gt 2 ; then
7032df40 24234 gcc_cv_ld_sysroot=yes
380e5ca4
MM
24235 fi
24236 elif test x$gcc_cv_ld != x; then
24237 if $gcc_cv_ld --help 2>/dev/null | grep sysroot > /dev/null; then
24238 gcc_cv_ld_sysroot=yes
24239 fi
24240 fi
24241fi
b61ff9c8
BS
24242echo "$as_me:$LINENO: result: $gcc_cv_ld_sysroot" >&5
24243echo "${ECHO_T}$gcc_cv_ld_sysroot" >&6
380e5ca4
MM
24244if test x"$gcc_cv_ld_sysroot" = xyes; then
24245
24246cat >>confdefs.h <<\_ACEOF
24247#define HAVE_LD_SYSROOT 1
24248_ACEOF
24249
24250fi
24251
9fb28a67 24252if test x$with_sysroot = x && test x$host = x$target \
c794c06f
CD
24253 && test "$prefix" != "/usr" && test "x$prefix" != "x$local_prefix" \
24254 && test "$prefix" != "NONE"; then
ba479fd2
NN
24255
24256cat >>confdefs.h <<_ACEOF
793e9558 24257#define PREFIX_INCLUDE_DIR "$prefix/include"
ba479fd2 24258_ACEOF
793e9558
PB
24259
24260fi
24261
77008252 24262# Test for stack protector support in target C library.
b61ff9c8
BS
24263echo "$as_me:$LINENO: checking __stack_chk_fail in target C library" >&5
24264echo $ECHO_N "checking __stack_chk_fail in target C library... $ECHO_C" >&6
77008252
JJ
24265if test "${gcc_cv_libc_provides_ssp+set}" = set; then
24266 echo $ECHO_N "(cached) $ECHO_C" >&6
24267else
24268 gcc_cv_libc_provides_ssp=no
a6ccdbab 24269 case "$target" in
22f96a0f 24270 *-*-linux* | *-*-kfreebsd*-gnu | *-*-knetbsd*-gnu)
77008252
JJ
24271 if test x$host != x$target || test "x$TARGET_SYSTEM_ROOT" != x; then
24272 if test "x$with_sysroot" = x; then
24273 glibc_header_dir="${exec_prefix}/${target_noncanonical}/sys-include"
c9ecbf86
JM
24274 elif test "x$with_build_sysroot" != "x"; then
24275 glibc_header_dir="${with_build_sysroot}/usr/include"
77008252
JJ
24276 elif test "x$with_sysroot" = xyes; then
24277 glibc_header_dir="${exec_prefix}/${target_noncanonical}/sys-root/usr/include"
24278 else
24279 glibc_header_dir="${with_sysroot}/usr/include"
24280 fi
24281 else
24282 glibc_header_dir=/usr/include
24283 fi
24284 # glibc 2.4 and later provides __stack_chk_fail and
24285 # either __stack_chk_guard, or TLS access to stack guard canary.
24286 if test -f $glibc_header_dir/features.h \
24287 && $EGREP '^[ ]*#[ ]*define[ ]+__GNU_LIBRARY__[ ]+([1-9][0-9]|[6-9])' \
24288 $glibc_header_dir/features.h > /dev/null; then
24289 if $EGREP '^[ ]*#[ ]*define[ ]+__GLIBC__[ ]+([1-9][0-9]|[3-9])' \
24290 $glibc_header_dir/features.h > /dev/null; then
24291 gcc_cv_libc_provides_ssp=yes
24292 elif $EGREP '^[ ]*#[ ]*define[ ]+__GLIBC__[ ]+2' \
24293 $glibc_header_dir/features.h > /dev/null \
24294 && $EGREP '^[ ]*#[ ]*define[ ]+__GLIBC_MINOR__[ ]+([1-9][0-9]|[4-9])' \
24295 $glibc_header_dir/features.h > /dev/null; then
24296 gcc_cv_libc_provides_ssp=yes
fed6d628
BF
24297 elif $EGREP '^[ ]*#[ ]*define[ ]+__UCLIBC__[ ]+1' \
24298 $glibc_header_dir/features.h > /dev/null && \
24299 test -f $glibc_header_dir/bits/uClibc_config.h && \
24300 $EGREP '^[ ]*#[ ]*define[ ]+__UCLIBC_HAS_SSP__[ ]+1' \
24301 $glibc_header_dir/bits/uClibc_config.h > /dev/null; then
24302 gcc_cv_libc_provides_ssp=yes
77008252 24303 fi
fed6d628 24304 fi
a6ccdbab 24305 ;;
4cc115a2
TS
24306 *-*-gnu*)
24307 # Avoid complicated tests (see
24308 # <http://gcc.gnu.org/ml/gcc/2008-10/msg00130.html>) and for now
24309 # simply assert that glibc does provide this, which is true for all
24310 # realistically usable GNU/Hurd configurations.
24311 gcc_cv_libc_provides_ssp=yes;;
a6ccdbab 24312 *-*-darwin*)
b61ff9c8
BS
24313 echo "$as_me:$LINENO: checking for __stack_chk_fail" >&5
24314echo $ECHO_N "checking for __stack_chk_fail... $ECHO_C" >&6
a6ccdbab
EC
24315if test "${ac_cv_func___stack_chk_fail+set}" = set; then
24316 echo $ECHO_N "(cached) $ECHO_C" >&6
24317else
24318 cat >conftest.$ac_ext <<_ACEOF
24319/* confdefs.h. */
24320_ACEOF
24321cat confdefs.h >>conftest.$ac_ext
24322cat >>conftest.$ac_ext <<_ACEOF
24323/* end confdefs.h. */
24324/* Define __stack_chk_fail to an innocuous variant, in case <limits.h> declares __stack_chk_fail.
24325 For example, HP-UX 11i <limits.h> declares gettimeofday. */
24326#define __stack_chk_fail innocuous___stack_chk_fail
24327
24328/* System header to define __stub macros and hopefully few prototypes,
24329 which can conflict with char __stack_chk_fail (); below.
24330 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
24331 <limits.h> exists even on freestanding compilers. */
24332
24333#ifdef __STDC__
24334# include <limits.h>
24335#else
24336# include <assert.h>
24337#endif
24338
24339#undef __stack_chk_fail
24340
b61ff9c8 24341/* Override any gcc2 internal prototype to avoid an error. */
a6ccdbab
EC
24342#ifdef __cplusplus
24343extern "C"
b61ff9c8 24344{
a6ccdbab 24345#endif
b61ff9c8
BS
24346/* We use char because int might match the return type of a gcc2
24347 builtin and then its argument prototype would still apply. */
a6ccdbab
EC
24348char __stack_chk_fail ();
24349/* The GNU C library defines this for functions which it implements
24350 to always fail with ENOSYS. Some functions are actually named
24351 something starting with __ and the normal name is an alias. */
b61ff9c8 24352#if defined (__stub___stack_chk_fail) || defined (__stub_____stack_chk_fail)
a6ccdbab 24353choke me
b61ff9c8
BS
24354#else
24355char (*f) () = __stack_chk_fail;
24356#endif
24357#ifdef __cplusplus
24358}
a6ccdbab
EC
24359#endif
24360
24361int
24362main ()
24363{
b61ff9c8 24364return f != __stack_chk_fail;
a6ccdbab
EC
24365 ;
24366 return 0;
24367}
24368_ACEOF
24369rm -f conftest.$ac_objext conftest$ac_exeext
b61ff9c8
BS
24370if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24371 (eval $ac_link) 2>conftest.er1
a6ccdbab
EC
24372 ac_status=$?
24373 grep -v '^ *+' conftest.er1 >conftest.err
24374 rm -f conftest.er1
24375 cat conftest.err >&5
24376 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b61ff9c8
BS
24377 (exit $ac_status); } &&
24378 { ac_try='test -z "$ac_c_werror_flag"
24379 || test ! -s conftest.err'
24380 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24381 (eval $ac_try) 2>&5
24382 ac_status=$?
24383 echo "$as_me:$LINENO: \$? = $ac_status" >&5
24384 (exit $ac_status); }; } &&
24385 { ac_try='test -s conftest$ac_exeext'
24386 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24387 (eval $ac_try) 2>&5
24388 ac_status=$?
24389 echo "$as_me:$LINENO: \$? = $ac_status" >&5
24390 (exit $ac_status); }; }; then
8b1f719a
PB
24391 ac_cv_func___stack_chk_fail=yes
24392else
a6ccdbab
EC
24393 echo "$as_me: failed program was:" >&5
24394sed 's/^/| /' conftest.$ac_ext >&5
24395
b61ff9c8 24396ac_cv_func___stack_chk_fail=no
a6ccdbab 24397fi
b61ff9c8 24398rm -f conftest.err conftest.$ac_objext \
a6ccdbab
EC
24399 conftest$ac_exeext conftest.$ac_ext
24400fi
b61ff9c8
BS
24401echo "$as_me:$LINENO: result: $ac_cv_func___stack_chk_fail" >&5
24402echo "${ECHO_T}$ac_cv_func___stack_chk_fail" >&6
a6ccdbab
EC
24403if test $ac_cv_func___stack_chk_fail = yes; then
24404 gcc_cv_libc_provides_ssp=yes
24405else
24406 echo "no __stack_chk_fail on this target"
77008252 24407fi
a6ccdbab
EC
24408
24409 ;;
77008252 24410 *) gcc_cv_libc_provides_ssp=no ;;
a6ccdbab
EC
24411 esac
24412fi
b61ff9c8
BS
24413echo "$as_me:$LINENO: result: $gcc_cv_libc_provides_ssp" >&5
24414echo "${ECHO_T}$gcc_cv_libc_provides_ssp" >&6
a6ccdbab 24415
77008252
JJ
24416if test x$gcc_cv_libc_provides_ssp = xyes; then
24417
24418cat >>confdefs.h <<\_ACEOF
24419#define TARGET_LIBC_PROVIDES_SSP 1
24420_ACEOF
24421
24422fi
24423
ed965309
JJ
24424# Check if TFmode long double should be used by default or not.
24425# Some glibc targets used DFmode long double, but with glibc 2.4
24426# and later they can use TFmode.
24427case "$target" in
f7cc5390
JM
24428 powerpc*-*-linux* | \
24429 powerpc*-*-gnu* | \
ed965309
JJ
24430 sparc*-*-linux* | \
24431 s390*-*-linux* | \
24432 alpha*-*-linux*)
24433
b61ff9c8 24434# Check whether --with-long-double-128 or --without-long-double-128 was given.
ed965309 24435if test "${with_long_double_128+set}" = set; then
b61ff9c8
BS
24436 withval="$with_long_double_128"
24437 gcc_cv_target_ldbl128="$with_long_double_128"
ed965309
JJ
24438else
24439 gcc_cv_target_ldbl128=no
24440 if test x$host != x$target || test "x$TARGET_SYSTEM_ROOT" != x; then
24441 if test "x$with_sysroot" = x; then
24442 glibc_header_dir="${exec_prefix}/${target_noncanonical}/sys-include"
c9ecbf86
JM
24443 elif test "x$with_build_sysroot" != "x"; then
24444 glibc_header_dir="${with_build_sysroot}/usr/include"
ed965309
JJ
24445 elif test "x$with_sysroot" = xyes; then
24446 glibc_header_dir="${exec_prefix}/${target_noncanonical}/sys-root/usr/include"
24447 else
24448 glibc_header_dir="${with_sysroot}/usr/include"
24449 fi
24450 else
24451 glibc_header_dir=/usr/include
24452 fi
65280f6c 24453 grep '^[ ]*#[ ]*define[ ][ ]*__LONG_DOUBLE_MATH_OPTIONAL' \
ed965309
JJ
24454 $glibc_header_dir/bits/wordsize.h > /dev/null 2>&1 \
24455 && gcc_cv_target_ldbl128=yes
65280f6c 24456
b61ff9c8 24457fi;
ed965309
JJ
24458 ;;
24459esac
24460if test x$gcc_cv_target_ldbl128 = xyes; then
24461
24462cat >>confdefs.h <<\_ACEOF
24463#define TARGET_DEFAULT_LONG_DOUBLE_128 1
24464_ACEOF
24465
24466fi
24467
81bf3d9e 24468# Find out what GC implementation we want, or may, use.
ba479fd2 24469
b61ff9c8 24470# Check whether --with-gc or --without-gc was given.
81bf3d9e 24471if test "${with_gc+set}" = set; then
b61ff9c8
BS
24472 withval="$with_gc"
24473 case "$withval" in
08cee789 24474 page)
81bf3d9e 24475 GGC=ggc-$withval
08cee789
DJ
24476 ;;
24477 zone)
24478 GGC=ggc-$withval
24479
24480cat >>confdefs.h <<\_ACEOF
24481#define GGC_ZONE 1
24482_ACEOF
24483
81bf3d9e
RH
24484 ;;
24485 *)
ba479fd2
NN
24486 { { echo "$as_me:$LINENO: error: $withval is an invalid option to --with-gc" >&5
24487echo "$as_me: error: $withval is an invalid option to --with-gc" >&2;}
24488 { (exit 1); exit 1; }; }
81bf3d9e
RH
24489 ;;
24490esac
24491else
005537df 24492 GGC=ggc-page
b61ff9c8 24493fi;
81bf3d9e
RH
24494
24495echo "Using $GGC for garbage collection."
24496
3c809ba4 24497# Use the system's zlib library.
b8dad04b
ZW
24498zlibdir=-L../zlib
24499zlibinc="-I\$(srcdir)/../zlib"
ba479fd2 24500
b61ff9c8 24501# Check whether --with-system-zlib or --without-system-zlib was given.
3c809ba4 24502if test "${with_system_zlib+set}" = set; then
b61ff9c8
BS
24503 withval="$with_system_zlib"
24504 zlibdir=
3c809ba4
AG
24505zlibinc=
24506
b61ff9c8 24507fi;
b8ec3cc8 24508
703d89ab 24509
ab22c1fa 24510
1a4b763e 24511
b61ff9c8
BS
24512echo "$as_me:$LINENO: checking whether to enable maintainer-specific portions of Makefiles" >&5
24513echo $ECHO_N "checking whether to enable maintainer-specific portions of Makefiles... $ECHO_C" >&6
24514 # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
dc6746e7 24515if test "${enable_maintainer_mode+set}" = set; then
b61ff9c8
BS
24516 enableval="$enable_maintainer_mode"
24517 maintainer_mode=$enableval
dc6746e7
PT
24518else
24519 maintainer_mode=no
b61ff9c8 24520fi;
a6ccdbab 24521
b61ff9c8
BS
24522echo "$as_me:$LINENO: result: $maintainer_mode" >&5
24523echo "${ECHO_T}$maintainer_mode" >&6
dc6746e7
PT
24524
24525if test "$maintainer_mode" = "yes"; then
24526 MAINT=''
24527else
24528 MAINT='#'
24529fi
24530
8bb915b6
NN
24531# --------------
24532# Language hooks
24533# --------------
24534
861bb6c1
JL
24535# Make empty files to contain the specs and options for each language.
24536# Then add #include lines to for a compiler that has specs and/or options.
24537
cc11cc9b 24538subdirs=
d7b42618 24539lang_opt_files=
861bb6c1 24540lang_specs_files=
3103b7db 24541lang_tree_files=
861bb6c1
JL
24542# These (without "all_") are set in each config-lang.in.
24543# `language' must be a single word so is spelled singularly.
24544all_languages=
861bb6c1 24545all_compilers=
47ad7893 24546all_outputs='Makefile gccbug'
861bb6c1 24547# List of language makefile fragments.
2ed26f6b
ZW
24548all_lang_makefrags=
24549# List of language subdirectory makefiles. Deprecated.
861bb6c1 24550all_lang_makefiles=
703d89ab 24551# Additional files for gengtype
ef69da62 24552all_gtfiles="$target_gtfiles"
861bb6c1 24553
cc11cc9b
PB
24554# These are the languages that are set in --enable-languages,
24555# and are available in the GCC tree.
24556all_selected_languages=
24557
861bb6c1
JL
24558# Add the language fragments.
24559# Languages are added via two mechanisms. Some information must be
24560# recorded in makefile variables, these are defined in config-lang.in.
24561# We accumulate them and plug them into the main Makefile.
24562# The other mechanism is a set of hooks for each of the main targets
24563# like `clean', `install', etc.
24564
861bb6c1 24565language_hooks="Make-hooks"
861bb6c1 24566
cc11cc9b 24567for lang in ${srcdir}/*/config-lang.in
861bb6c1 24568do
1546bb64
PB
24569 test "$lang" = "${srcdir}/*/config-lang.in" && continue
24570
cc11cc9b
PB
24571 lang_alias=`sed -n -e 's,^language=['"'"'"'"]\(.*\)["'"'"'"'].*$,\1,p' -e 's,^language=\([^ ]*\).*$,\1,p' $lang`
24572 if test "x$lang_alias" = x
24573 then
24574 echo "$lang doesn't set \$language." 1>&2
24575 exit 1
24576 fi
24577 subdir="`echo $lang | sed -e 's,^.*/\([^/]*\)/config-lang.in$,\1,'`"
24578 subdirs="$subdirs $subdir"
349c3166
OH
24579
24580 # $gcc_subdir is where the gcc integration files are to be found
24581 # for a language, both for internal compiler purposes (compiler
24582 # sources implementing front-end to GCC tree converters), and for
24583 # build infrastructure purposes (Make-lang.in, etc.)
24584 #
24585 # This will be <subdir> (relative to $srcdir) if a line like
24586 # gcc_subdir="<subdir>" or gcc_subdir=<subdir>
24587 # is found in <langdir>/config-lang.in, and will remain <langdir>
24588 # otherwise.
24589 #
24590 # Except for the language alias (fetched above), the regular
24591 # "config-lang.in" contents are always retrieved from $gcc_subdir,
24592 # so a <langdir>/config-lang.in setting gcc_subdir typically sets
24593 # only this and the language alias.
24594
24595 gcc_subdir=`sed -n -e 's,^gcc_subdir=['"'"'"'"]\(.*\)["'"'"'"'].*$,\1,p' -e 's,^gcc_subdir=\([^ ]*\).*$,\1,p' $lang`
24596 if [ "$gcc_subdir" = "" ]; then
24597 gcc_subdir="$subdir"
24598 fi
24599
cc11cc9b
PB
24600 case ",$enable_languages," in
24601 *,$lang_alias,*)
24602 all_selected_languages="$all_selected_languages $lang_alias"
349c3166
OH
24603 if test -f $srcdir/$gcc_subdir/lang-specs.h; then
24604 lang_specs_files="$lang_specs_files $srcdir/$gcc_subdir/lang-specs.h"
cc11cc9b
PB
24605 fi
24606 ;;
24607 esac
24608
cc11cc9b
PB
24609 language=
24610 boot_language=
24611 compilers=
cc11cc9b
PB
24612 outputs=
24613 gtfiles=
1546bb64 24614 subdir_requires=
349c3166 24615 . ${srcdir}/$gcc_subdir/config-lang.in
cc11cc9b
PB
24616 if test "x$language" = x
24617 then
349c3166 24618 echo "${srcdir}/$gcc_subdir/config-lang.in doesn't set \$language." 1>&2
cc11cc9b
PB
24619 exit 1
24620 fi
1546bb64
PB
24621
24622 ok=:
24623 case ",$enable_languages," in
24624 *,$lang_alias,*) ;;
24625 *)
24626 for i in $subdir_requires; do
b6348cb3 24627 test -f "${srcdir}/$i/config-lang.in" && continue
1546bb64
PB
24628 ok=false
24629 break
24630 done
24631 ;;
24632 esac
24633 $ok || continue
24634
349c3166
OH
24635 all_lang_makefrags="$all_lang_makefrags \$(srcdir)/$gcc_subdir/Make-lang.in"
24636 if test -f $srcdir/$gcc_subdir/lang.opt; then
24637 lang_opt_files="$lang_opt_files $srcdir/$gcc_subdir/lang.opt"
1546bb64 24638 fi
349c3166
OH
24639 if test -f $srcdir/$gcc_subdir/$subdir-tree.def; then
24640 lang_tree_files="$lang_tree_files $srcdir/$gcc_subdir/$subdir-tree.def"
1546bb64 24641 fi
349c3166
OH
24642 if test -f ${srcdir}/$gcc_subdir/Makefile.in
24643 then all_lang_makefiles="$gcc_subdir/Makefile"
cc11cc9b
PB
24644 fi
24645 all_languages="$all_languages $language"
cc11cc9b 24646 all_compilers="$all_compilers $compilers"
cc11cc9b 24647 all_outputs="$all_outputs $outputs"
703d89ab 24648 all_gtfiles="$all_gtfiles [$subdir] $gtfiles"
861bb6c1
JL
24649done
24650
8ac9d31f
TJ
24651# Pick up gtfiles for c
24652gtfiles=
8ac9d31f 24653. ${srcdir}/c-config-lang.in
703d89ab 24654all_gtfiles="$all_gtfiles [c] $gtfiles"
8ac9d31f 24655
cbc59f01 24656check_languages=
cc11cc9b 24657for language in $all_selected_languages
cbc59f01 24658do
cc11cc9b 24659 check_languages="$check_languages check-$language"
cbc59f01
DD
24660done
24661
62b81e45 24662# We link each language in with a set of hooks, reached indirectly via
cc11cc9b 24663# lang.${target}. Only do so for selected languages.
861bb6c1
JL
24664
24665rm -f Make-hooks
24666touch Make-hooks
bd97af06 24667target_list="all.cross start.encap rest.encap tags \
bcc3d150
BM
24668 install-common install-man install-info install-pdf dvi pdf \
24669 html uninstall info man srcextra srcman srcinfo \
8b1f719a 24670 mostlyclean clean distclean maintainer-clean"
cc11cc9b 24671
861bb6c1
JL
24672for t in $target_list
24673do
24674 x=
cc11cc9b 24675 for lang in $all_selected_languages
861bb6c1 24676 do
cc11cc9b 24677 x="$x $lang.$t"
861bb6c1
JL
24678 done
24679 echo "lang.$t: $x" >> Make-hooks
24680done
24681
8bb915b6
NN
24682# --------
24683# UNSORTED
24684# --------
24685
cc06d68c 24686# Create .gdbinit.
861bb6c1 24687
cc06d68c
GP
24688echo "dir ." > .gdbinit
24689echo "dir ${srcdir}" >> .gdbinit
24690if test x$gdb_needs_out_file_path = xyes
24691then
24692 echo "dir ${srcdir}/config/"`dirname ${out_file}` >> .gdbinit
24693fi
24694if test "x$subdirs" != x; then
24695 for s in $subdirs
24696 do
24697 echo "dir ${srcdir}/$s" >> .gdbinit
24698 done
861bb6c1 24699fi
cc06d68c 24700echo "source ${srcdir}/gdbinit.in" >> .gdbinit
861bb6c1 24701
15c723f3 24702gcc_tooldir='$(libsubdir)/$(libsubdir_to_prefix)$(target_noncanonical)'
d062c304
JL
24703
24704
2ce3c6c6 24705
2bbea3a6
RH
24706# Find a directory in which to install a shared libgcc.
24707
b61ff9c8 24708# Check whether --enable-version-specific-runtime-libs or --disable-version-specific-runtime-libs was given.
2bbea3a6 24709if test "${enable_version_specific_runtime_libs+set}" = set; then
b61ff9c8 24710 enableval="$enable_version_specific_runtime_libs"
ba479fd2 24711
b61ff9c8 24712fi;
2bbea3a6
RH
24713
24714
b61ff9c8 24715# Check whether --with-slibdir or --without-slibdir was given.
5b15f277 24716if test "${with_slibdir+set}" = set; then
b61ff9c8
BS
24717 withval="$with_slibdir"
24718 slibdir="$with_slibdir"
5b15f277
RH
24719else
24720 if test "${enable_version_specific_runtime_libs+set}" = set; then
2bbea3a6 24721 slibdir='$(libsubdir)'
5b15f277 24722elif test "$host" != "$target"; then
2bbea3a6
RH
24723 slibdir='$(build_tooldir)/lib'
24724else
5b15f277 24725 slibdir='$(libdir)'
2bbea3a6 24726fi
b61ff9c8 24727fi;
2bbea3a6
RH
24728
24729
22482f74 24730
b61ff9c8 24731# Check whether --with-datarootdir or --without-datarootdir was given.
22482f74 24732if test "${with_datarootdir+set}" = set; then
b61ff9c8
BS
24733 withval="$with_datarootdir"
24734 datarootdir="\${prefix}/$with_datarootdir"
22482f74
MS
24735else
24736 datarootdir='$(prefix)/share'
b61ff9c8 24737fi;
22482f74
MS
24738
24739
a6ccdbab 24740
b61ff9c8 24741# Check whether --with-docdir or --without-docdir was given.
22482f74 24742if test "${with_docdir+set}" = set; then
b61ff9c8
BS
24743 withval="$with_docdir"
24744 docdir="\${prefix}/$with_docdir"
22482f74
MS
24745else
24746 docdir='$(datarootdir)'
b61ff9c8 24747fi;
703d89ab 24748
ab22c1fa 24749
1a4b763e 24750
b61ff9c8 24751# Check whether --with-htmldir or --without-htmldir was given.
22482f74 24752if test "${with_htmldir+set}" = set; then
b61ff9c8
BS
24753 withval="$with_htmldir"
24754 htmldir="\${prefix}/$with_htmldir"
22482f74
MS
24755else
24756 htmldir='$(docdir)'
b61ff9c8 24757fi;
861bb6c1
JL
24758
24759
703d89ab 24760# Substitute configuration variables
861bb6c1
JL
24761
24762
24763
24764
24765
24766
24767
24768
24769
24770
24771
24772
24773
24774
24775
24776
24777
24778
24779
24780
24781
24782
24783
24784
24785
24786
24787
24788
24789
24790
24791
24792
24793
24794
24795
24796
24797
24798
24799
24800
24801
24802
24803
24804
9b16d2c4 24805
e9a25f70 24806
6e26218f 24807
c8724862 24808
11642c3a
ZW
24809
24810
24811
3d9d2476 24812
e2500fed 24813
a0e527e3 24814
aca600aa
AS
24815
24816
24817
c776a6d0 24818
207bf79d 24819
51b9ff45 24820
861bb6c1 24821
6e3f3080
NN
24822# Echo link setup.
24823if test x${build} = x${host} ; then
24824 if test x${host} = x${target} ; then
24825 echo "Links are now set up to build a native compiler for ${target}." 1>&2
24826 else
24827 echo "Links are now set up to build a cross-compiler" 1>&2
24828 echo " from ${host} to ${target}." 1>&2
24829 fi
24830else
24831 if test x${host} = x${target} ; then
24832 echo "Links are now set up to build (on ${build}) a native compiler" 1>&2
24833 echo " for ${target}." 1>&2
24834 else
24835 echo "Links are now set up to build (on ${build}) a cross-compiler" 1>&2
24836 echo " from ${host} to ${target}." 1>&2
24837 fi
24838fi
24839
6de9cd9a
DN
24840
24841
24842
acd26225
KG
24843case "${GMPLIBS}" in
24844 *-lmpc*)
24845cat >>confdefs.h <<\_ACEOF
24846#define HAVE_mpc 1
24847_ACEOF
24848 ;;
24849esac
24850
f8bf9252
SP
24851
24852
24853
24854
24855
24856if test "x${CLOOGLIBS}" != "x" ; then
24857
24858cat >>confdefs.h <<\_ACEOF
24859#define HAVE_cloog 1
24860_ACEOF
24861
f8bf9252
SP
24862fi
24863
68a607d8
DN
24864# Check for plugin support
24865# Check whether --enable-plugin or --disable-plugin was given.
24866if test "${enable_plugin+set}" = set; then
24867 enableval="$enable_plugin"
24868 enable_plugin=$enableval
24869else
24870 enable_plugin=yes; default_plugin=yes
24871fi;
24872
24873pluginlibs=
24874if test x"$enable_plugin" = x"yes"; then
24875 # Check that the host supports -rdynamic and -ldl
24876 have_rdynamic=no
24877 have_dl=no
24878 saved_LDFLAGS="$LDFLAGS"
24879 saved_LIBS="$LIBS"
24880 LIBS=
24881
24882 # Check -rdynamic
24883 LDFLAGS="$LDFLAGS -rdynamic"
24884 echo "$as_me:$LINENO: checking for -rdynamic" >&5
24885echo $ECHO_N "checking for -rdynamic... $ECHO_C" >&6
24886 cat >conftest.$ac_ext <<_ACEOF
24887/* confdefs.h. */
24888_ACEOF
24889cat confdefs.h >>conftest.$ac_ext
24890cat >>conftest.$ac_ext <<_ACEOF
24891/* end confdefs.h. */
24892
24893int
24894main ()
24895{
24896return 0;
24897 ;
24898 return 0;
24899}
24900_ACEOF
24901rm -f conftest.$ac_objext conftest$ac_exeext
24902if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24903 (eval $ac_link) 2>conftest.er1
24904 ac_status=$?
24905 grep -v '^ *+' conftest.er1 >conftest.err
24906 rm -f conftest.er1
24907 cat conftest.err >&5
24908 echo "$as_me:$LINENO: \$? = $ac_status" >&5
24909 (exit $ac_status); } &&
24910 { ac_try='test -z "$ac_c_werror_flag"
24911 || test ! -s conftest.err'
24912 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24913 (eval $ac_try) 2>&5
24914 ac_status=$?
24915 echo "$as_me:$LINENO: \$? = $ac_status" >&5
24916 (exit $ac_status); }; } &&
24917 { ac_try='test -s conftest$ac_exeext'
24918 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24919 (eval $ac_try) 2>&5
24920 ac_status=$?
24921 echo "$as_me:$LINENO: \$? = $ac_status" >&5
24922 (exit $ac_status); }; }; then
24923 echo "$as_me:$LINENO: result: yes" >&5
24924echo "${ECHO_T}yes" >&6; have_rdynamic=yes
24925else
24926 echo "$as_me: failed program was:" >&5
24927sed 's/^/| /' conftest.$ac_ext >&5
24928
24929echo "$as_me:$LINENO: result: no" >&5
24930echo "${ECHO_T}no" >&6
24931fi
24932rm -f conftest.err conftest.$ac_objext \
24933 conftest$ac_exeext conftest.$ac_ext
24934 if test x"$have_rdynamic" = x"yes" ; then
24935 pluginlibs="-rdynamic"
24936 fi
24937
24938 # Check -ldl
24939 LDFLAGS="$LDFLAGS -ldl"
24940 echo "$as_me:$LINENO: checking for -ldl" >&5
24941echo $ECHO_N "checking for -ldl... $ECHO_C" >&6
24942 cat >conftest.$ac_ext <<_ACEOF
24943/* confdefs.h. */
24944_ACEOF
24945cat confdefs.h >>conftest.$ac_ext
24946cat >>conftest.$ac_ext <<_ACEOF
24947/* end confdefs.h. */
24948#include <dlfcn.h>
24949int
24950main ()
24951{
24952volatile int f = 0; if (f) dlopen ("dummy", 0);
24953 ;
24954 return 0;
24955}
24956_ACEOF
24957rm -f conftest.$ac_objext conftest$ac_exeext
24958if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24959 (eval $ac_link) 2>conftest.er1
24960 ac_status=$?
24961 grep -v '^ *+' conftest.er1 >conftest.err
24962 rm -f conftest.er1
24963 cat conftest.err >&5
24964 echo "$as_me:$LINENO: \$? = $ac_status" >&5
24965 (exit $ac_status); } &&
24966 { ac_try='test -z "$ac_c_werror_flag"
24967 || test ! -s conftest.err'
24968 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24969 (eval $ac_try) 2>&5
24970 ac_status=$?
24971 echo "$as_me:$LINENO: \$? = $ac_status" >&5
24972 (exit $ac_status); }; } &&
24973 { ac_try='test -s conftest$ac_exeext'
24974 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24975 (eval $ac_try) 2>&5
24976 ac_status=$?
24977 echo "$as_me:$LINENO: \$? = $ac_status" >&5
24978 (exit $ac_status); }; }; then
24979 echo "$as_me:$LINENO: result: yes" >&5
24980echo "${ECHO_T}yes" >&6; have_dl=yes
24981else
24982 echo "$as_me: failed program was:" >&5
24983sed 's/^/| /' conftest.$ac_ext >&5
24984
24985echo "$as_me:$LINENO: result: no" >&5
24986echo "${ECHO_T}no" >&6
24987fi
24988rm -f conftest.err conftest.$ac_objext \
24989 conftest$ac_exeext conftest.$ac_ext
24990 if test x"$have_dl" = x"yes"; then
24991 pluginlibs="$pluginlibs -ldl"
24992 fi
24993
24994 # Check that we can build shared objects with -fPIC -shared
24995 LDFLAGS="$LDFLAGS -fPIC -shared"
24996 echo "$as_me:$LINENO: checking for -fPIC -shared" >&5
24997echo $ECHO_N "checking for -fPIC -shared... $ECHO_C" >&6
24998 cat >conftest.$ac_ext <<_ACEOF
24999/* confdefs.h. */
25000_ACEOF
25001cat confdefs.h >>conftest.$ac_ext
25002cat >>conftest.$ac_ext <<_ACEOF
25003/* end confdefs.h. */
25004extern int X;
25005int
25006main ()
25007{
25008return X == 0;
25009 ;
25010 return 0;
25011}
25012_ACEOF
25013rm -f conftest.$ac_objext conftest$ac_exeext
25014if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25015 (eval $ac_link) 2>conftest.er1
25016 ac_status=$?
25017 grep -v '^ *+' conftest.er1 >conftest.err
25018 rm -f conftest.er1
25019 cat conftest.err >&5
25020 echo "$as_me:$LINENO: \$? = $ac_status" >&5
25021 (exit $ac_status); } &&
25022 { ac_try='test -z "$ac_c_werror_flag"
25023 || test ! -s conftest.err'
25024 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25025 (eval $ac_try) 2>&5
25026 ac_status=$?
25027 echo "$as_me:$LINENO: \$? = $ac_status" >&5
25028 (exit $ac_status); }; } &&
25029 { ac_try='test -s conftest$ac_exeext'
25030 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25031 (eval $ac_try) 2>&5
25032 ac_status=$?
25033 echo "$as_me:$LINENO: \$? = $ac_status" >&5
25034 (exit $ac_status); }; }; then
25035 echo "$as_me:$LINENO: result: yes" >&5
25036echo "${ECHO_T}yes" >&6; have_pic_shared=yes
25037else
25038 echo "$as_me: failed program was:" >&5
25039sed 's/^/| /' conftest.$ac_ext >&5
25040
25041echo "$as_me:$LINENO: result: no" >&5
25042echo "${ECHO_T}no" >&6; have_pic_shared=no
25043fi
25044rm -f conftest.err conftest.$ac_objext \
25045 conftest$ac_exeext conftest.$ac_ext
25046 if test x"$have_pic_shared" != x"yes"; then
25047 pluginlibs=
25048 enable_plugin=no
25049 fi
25050
25051 # If plugin support had been requested but not available, fail.
25052 if test x"$enable_plugin" = x"no" ; then
25053 if test x"$default_plugin" != x"yes"; then
25054 { { echo "$as_me:$LINENO: error:
25055Building GCC with plugin support requires a host that supports
25056-fPIC, -shared, -ldl and -rdynamic." >&5
25057echo "$as_me: error:
25058Building GCC with plugin support requires a host that supports
25059-fPIC, -shared, -ldl and -rdynamic." >&2;}
25060 { (exit 1); exit 1; }; }
25061 fi
25062 fi
25063
25064 LDFLAGS="$saved_LDFLAGS"
25065 LIBS="$saved_LIBS"
25066fi
25067
25068
25069
25070if test x"$enable_plugin" = x"yes"; then
25071
25072cat >>confdefs.h <<\_ACEOF
25073#define ENABLE_PLUGIN 1
25074_ACEOF
25075
25076fi
25077
6e3f3080
NN
25078# Configure the subdirectories
25079# AC_CONFIG_SUBDIRS($subdirs)
25080
25081# Create the Makefile
25082# and configure language subdirectories
b61ff9c8 25083 ac_config_files="$ac_config_files $all_outputs"
914c5af7
NN
25084
25085
b61ff9c8 25086 ac_config_commands="$ac_config_commands default"
914c5af7 25087
ba479fd2 25088cat >confcache <<\_ACEOF
6e3f3080
NN
25089# This file is a shell script that caches the results of configure
25090# tests run on this system so they can be shared between configure
ba479fd2
NN
25091# scripts and configure runs, see configure's option --config-cache.
25092# It is not useful on other systems. If it contains results you don't
25093# want to keep, you may remove or edit it.
6e3f3080 25094#
ba479fd2
NN
25095# config.status only pays attention to the cache file if you give it
25096# the --recheck option to rerun configure.
6e3f3080 25097#
ba479fd2
NN
25098# `ac_cv_env_foo' variables (set or unset) will be overridden when
25099# loading this file, other *unset* `ac_cv_foo' will be assigned the
25100# following values.
25101
25102_ACEOF
25103
6e3f3080
NN
25104# The following way of writing the cache mishandles newlines in values,
25105# but we know of no workaround that is simple, portable, and efficient.
b61ff9c8 25106# So, don't put newlines in cache variables' values.
6e3f3080
NN
25107# Ultrix sh set writes to stderr and can't be redirected directly,
25108# and sets the high bit in the cache file unless we assign to the vars.
b61ff9c8 25109{
ba479fd2 25110 (set) 2>&1 |
b61ff9c8
BS
25111 case `(ac_space=' '; set | grep ac_space) 2>&1` in
25112 *ac_space=\ *)
ba479fd2
NN
25113 # `set' does not quote correctly, so add quotes (double-quote
25114 # substitution turns \\\\ into \\, and sed turns \\ into \).
25115 sed -n \
86da66b5
HPN
25116 "s/'/'\\\\''/g;
25117 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
b61ff9c8 25118 ;;
ba479fd2
NN
25119 *)
25120 # `set' quotes correctly as required by POSIX, so do not add quotes.
b61ff9c8
BS
25121 sed -n \
25122 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
ba479fd2 25123 ;;
b61ff9c8
BS
25124 esac;
25125} |
ba479fd2
NN
25126 sed '
25127 t clear
b61ff9c8 25128 : clear
ba479fd2
NN
25129 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
25130 t end
b61ff9c8
BS
25131 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
25132 : end' >>confcache
25133if diff $cache_file confcache >/dev/null 2>&1; then :; else
25134 if test -w $cache_file; then
25135 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
ba479fd2 25136 cat confcache >$cache_file
6e3f3080 25137 else
b61ff9c8 25138 echo "not updating unwritable cache $cache_file"
6e3f3080
NN
25139 fi
25140fi
25141rm -f confcache
25142
25143test "x$prefix" = xNONE && prefix=$ac_default_prefix
25144# Let make expand exec_prefix.
25145test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
25146
b61ff9c8
BS
25147# VPATH may cause trouble with some makes, so we remove $(srcdir),
25148# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
25149# trailing colons and then remove the whole line if VPATH becomes empty
25150# (actually we leave an empty line to preserve line numbers).
25151if test "x$srcdir" = x.; then
25152 ac_vpsub='/^[ ]*VPATH[ ]*=/{
25153s/:*\$(srcdir):*/:/;
25154s/:*\${srcdir}:*/:/;
25155s/:*@srcdir@:*/:/;
25156s/^\([^=]*=[ ]*\):*/\1/;
25157s/:*$//;
25158s/^[^=]*=[ ]*$//;
25159}'
25160fi
25161
63cf211a 25162DEFS=-DHAVE_CONFIG_H
6e3f3080 25163
ba479fd2
NN
25164ac_libobjs=
25165ac_ltlibobjs=
25166for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
25167 # 1. Remove the extension, and $U if already installed.
b61ff9c8
BS
25168 ac_i=`echo "$ac_i" |
25169 sed 's/\$U\././;s/\.o$//;s/\.obj$//'`
25170 # 2. Add them.
25171 ac_libobjs="$ac_libobjs $ac_i\$U.$ac_objext"
25172 ac_ltlibobjs="$ac_ltlibobjs $ac_i"'$U.lo'
ba479fd2
NN
25173done
25174LIBOBJS=$ac_libobjs
63cf211a 25175
ba479fd2
NN
25176LTLIBOBJS=$ac_ltlibobjs
25177
25178
25179
25180: ${CONFIG_STATUS=./config.status}
25181ac_clean_files_save=$ac_clean_files
25182ac_clean_files="$ac_clean_files $CONFIG_STATUS"
25183{ echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
25184echo "$as_me: creating $CONFIG_STATUS" >&6;}
25185cat >$CONFIG_STATUS <<_ACEOF
25186#! $SHELL
25187# Generated by $as_me.
6e3f3080
NN
25188# Run this file to recreate the current configuration.
25189# Compiler output produced by configure, useful for debugging
ba479fd2 25190# configure, is in config.log if it exists.
6e3f3080 25191
ba479fd2
NN
25192debug=false
25193ac_cs_recheck=false
25194ac_cs_silent=false
25195SHELL=\${CONFIG_SHELL-$SHELL}
25196_ACEOF
25197
25198cat >>$CONFIG_STATUS <<\_ACEOF
25199## --------------------- ##
25200## M4sh Initialization. ##
25201## --------------------- ##
25202
b61ff9c8 25203# Be Bourne compatible
ba479fd2
NN
25204if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
25205 emulate sh
25206 NULLCMD=:
25207 # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
25208 # is contrary to our usage. Disable this feature.
25209 alias -g '${1+"$@"}'='"$@"'
b61ff9c8
BS
25210elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
25211 set -o posix
2f41c1d6 25212fi
b61ff9c8 25213DUALCASE=1; export DUALCASE # for MKS sh
ab22c1fa 25214
1a4b763e
BS
25215# Support unset when possible.
25216if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
25217 as_unset=unset
25218else
25219 as_unset=false
25220fi
25221
ab22c1fa 25222
1a4b763e 25223# Work around bugs in pre-3.0 UWIN ksh.
b61ff9c8 25224$as_unset ENV MAIL MAILPATH
1a4b763e
BS
25225PS1='$ '
25226PS2='> '
25227PS4='+ '
25228
25229# NLS nuisances.
25230for as_var in \
25231 LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
25232 LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
25233 LC_TELEPHONE LC_TIME
2f41c1d6 25234do
1a4b763e
BS
25235 if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
25236 eval $as_var=C; export $as_var
25237 else
b61ff9c8 25238 $as_unset $as_var
1a4b763e
BS
25239 fi
25240done
25241
25242# Required to use basename.
b61ff9c8 25243if expr a : '\(a\)' >/dev/null 2>&1; then
1a4b763e
BS
25244 as_expr=expr
25245else
25246 as_expr=false
25247fi
25248
b61ff9c8 25249if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
1a4b763e
BS
25250 as_basename=basename
25251else
25252 as_basename=false
25253fi
25254
25255
25256# Name of the executable.
b61ff9c8 25257as_me=`$as_basename "$0" ||
1a4b763e
BS
25258$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
25259 X"$0" : 'X\(//\)$' \| \
b61ff9c8
BS
25260 X"$0" : 'X\(/\)$' \| \
25261 . : '\(.\)' 2>/dev/null ||
1a4b763e 25262echo X/"$0" |
b61ff9c8
BS
25263 sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
25264 /^X\/\(\/\/\)$/{ s//\1/; q; }
25265 /^X\/\(\/\).*/{ s//\1/; q; }
25266 s/.*/./; q'`
1a4b763e 25267
b61ff9c8
BS
25268
25269# PATH needs CR, and LINENO needs CR and PATH.
25270# Avoid depending upon Character Ranges.
25271as_cr_letters='abcdefghijklmnopqrstuvwxyz'
25272as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
25273as_cr_Letters=$as_cr_letters$as_cr_LETTERS
25274as_cr_digits='0123456789'
25275as_cr_alnum=$as_cr_Letters$as_cr_digits
25276
25277# The user is always right.
25278if test "${PATH_SEPARATOR+set}" != set; then
25279 echo "#! /bin/sh" >conf$$.sh
25280 echo "exit 0" >>conf$$.sh
25281 chmod +x conf$$.sh
25282 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
25283 PATH_SEPARATOR=';'
25284 else
25285 PATH_SEPARATOR=:
25286 fi
25287 rm -f conf$$.sh
25288fi
1a4b763e
BS
25289
25290
b61ff9c8
BS
25291 as_lineno_1=$LINENO
25292 as_lineno_2=$LINENO
25293 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
25294 test "x$as_lineno_1" != "x$as_lineno_2" &&
25295 test "x$as_lineno_3" = "x$as_lineno_2" || {
25296 # Find who we are. Look in the path if we contain no path at all
25297 # relative or not.
25298 case $0 in
25299 *[\\/]* ) as_myself=$0 ;;
25300 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25301for as_dir in $PATH
25302do
25303 IFS=$as_save_IFS
25304 test -z "$as_dir" && as_dir=.
25305 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
25306done
1a4b763e 25307
b61ff9c8
BS
25308 ;;
25309 esac
25310 # We did not find ourselves, most probably we were run as `sh COMMAND'
25311 # in which case we are not to be found in the path.
25312 if test "x$as_myself" = x; then
25313 as_myself=$0
25314 fi
25315 if test ! -f "$as_myself"; then
25316 { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
25317echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
25318 { (exit 1); exit 1; }; }
25319 fi
25320 case $CONFIG_SHELL in
25321 '')
25322 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25323for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
25324do
25325 IFS=$as_save_IFS
25326 test -z "$as_dir" && as_dir=.
25327 for as_base in sh bash ksh sh5; do
25328 case $as_dir in
25329 /*)
25330 if ("$as_dir/$as_base" -c '
8b1f719a
PB
25331 as_lineno_1=$LINENO
25332 as_lineno_2=$LINENO
b61ff9c8 25333 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
8b1f719a 25334 test "x$as_lineno_1" != "x$as_lineno_2" &&
b61ff9c8
BS
25335 test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then
25336 $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
25337 $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
25338 CONFIG_SHELL=$as_dir/$as_base
25339 export CONFIG_SHELL
25340 exec "$CONFIG_SHELL" "$0" ${1+"$@"}
25341 fi;;
25342 esac
25343 done
25344done
25345;;
25346 esac
ba479fd2
NN
25347
25348 # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
25349 # uniformly replaced by the line number. The first 'sed' inserts a
b61ff9c8
BS
25350 # line-number line before each line; the second 'sed' does the real
25351 # work. The second script uses 'N' to pair each line-number line
25352 # with the numbered line, and appends trailing '-' during
25353 # substitution so that $LINENO is not a special case at line end.
ba479fd2 25354 # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
b61ff9c8
BS
25355 # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-)
25356 sed '=' <$as_myself |
ba479fd2
NN
25357 sed '
25358 N
b61ff9c8
BS
25359 s,$,-,
25360 : loop
25361 s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
ba479fd2 25362 t loop
b61ff9c8
BS
25363 s,-$,,
25364 s,^['$as_cr_digits']*\n,,
ba479fd2 25365 ' >$as_me.lineno &&
b61ff9c8
BS
25366 chmod +x $as_me.lineno ||
25367 { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
25368echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
ba479fd2
NN
25369 { (exit 1); exit 1; }; }
25370
25371 # Don't try to exec as it changes $[0], causing all sort of problems
25372 # (the dirname of $[0] is not the place where we might find the
b61ff9c8
BS
25373 # original and so on. Autoconf is especially sensible to this).
25374 . ./$as_me.lineno
ba479fd2
NN
25375 # Exit status is that of the last command.
25376 exit
25377}
25378
25379
b61ff9c8
BS
25380case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
25381 *c*,-n*) ECHO_N= ECHO_C='
25382' ECHO_T=' ' ;;
25383 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
25384 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
ba479fd2
NN
25385esac
25386
b61ff9c8 25387if expr a : '\(a\)' >/dev/null 2>&1; then
ba479fd2
NN
25388 as_expr=expr
25389else
25390 as_expr=false
25391fi
25392
25393rm -f conf$$ conf$$.exe conf$$.file
25394echo >conf$$.file
25395if ln -s conf$$.file conf$$ 2>/dev/null; then
b61ff9c8
BS
25396 # We could just check for DJGPP; but this test a) works b) is more generic
25397 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
25398 if test -f conf$$.exe; then
25399 # Don't use ln at all; we don't have any links
ba479fd2 25400 as_ln_s='cp -p'
b61ff9c8
BS
25401 else
25402 as_ln_s='ln -s'
25403 fi
ba479fd2
NN
25404elif ln conf$$.file conf$$ 2>/dev/null; then
25405 as_ln_s=ln
25406else
25407 as_ln_s='cp -p'
25408fi
b61ff9c8 25409rm -f conf$$ conf$$.exe conf$$.file
ba479fd2
NN
25410
25411if mkdir -p . 2>/dev/null; then
25412 as_mkdir_p=:
25413else
86da66b5 25414 test -d ./-p && rmdir ./-p
ba479fd2
NN
25415 as_mkdir_p=false
25416fi
25417
b61ff9c8 25418as_executable_p="test -f"
ba479fd2
NN
25419
25420# Sed expression to map a string onto a valid CPP name.
86da66b5 25421as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
ba479fd2
NN
25422
25423# Sed expression to map a string onto a valid variable name.
86da66b5 25424as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
ba479fd2
NN
25425
25426
b61ff9c8
BS
25427# IFS
25428# We need space, tab and new line, in precisely that order.
25429as_nl='
25430'
25431IFS=" $as_nl"
25432
25433# CDPATH.
25434$as_unset CDPATH
25435
ba479fd2
NN
25436exec 6>&1
25437
b61ff9c8 25438# Open the log real soon, to keep \$[0] and so on meaningful, and to
ba479fd2 25439# report actual input values of CONFIG_FILES etc. instead of their
b61ff9c8
BS
25440# values after options handling. Logging --version etc. is OK.
25441exec 5>>config.log
25442{
25443 echo
25444 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
25445## Running $as_me. ##
25446_ASBOX
25447} >&5
25448cat >&5 <<_CSEOF
25449
ba479fd2 25450This file was extended by $as_me, which was
b61ff9c8 25451generated by GNU Autoconf 2.59. Invocation command line was
ba479fd2
NN
25452
25453 CONFIG_FILES = $CONFIG_FILES
25454 CONFIG_HEADERS = $CONFIG_HEADERS
25455 CONFIG_LINKS = $CONFIG_LINKS
25456 CONFIG_COMMANDS = $CONFIG_COMMANDS
25457 $ $0 $@
25458
b61ff9c8
BS
25459_CSEOF
25460echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
25461echo >&5
ba479fd2
NN
25462_ACEOF
25463
25464# Files that config.status was made for.
b61ff9c8
BS
25465if test -n "$ac_config_files"; then
25466 echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
25467fi
2f41c1d6 25468
b61ff9c8
BS
25469if test -n "$ac_config_headers"; then
25470 echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
25471fi
25472
25473if test -n "$ac_config_links"; then
25474 echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
25475fi
25476
25477if test -n "$ac_config_commands"; then
25478 echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
25479fi
ba479fd2
NN
25480
25481cat >>$CONFIG_STATUS <<\_ACEOF
b61ff9c8 25482
ba479fd2
NN
25483ac_cs_usage="\
25484\`$as_me' instantiates files from templates according to the
25485current configuration.
25486
25487Usage: $0 [OPTIONS] [FILE]...
25488
25489 -h, --help print this help, then exit
b61ff9c8 25490 -V, --version print version number, then exit
ba479fd2
NN
25491 -q, --quiet do not print progress messages
25492 -d, --debug don't remove temporary files
25493 --recheck update $as_me by reconfiguring in the same conditions
25494 --file=FILE[:TEMPLATE]
86da66b5 25495 instantiate the configuration file FILE
ba479fd2 25496 --header=FILE[:TEMPLATE]
86da66b5 25497 instantiate the configuration header FILE
ba479fd2
NN
25498
25499Configuration files:
25500$config_files
25501
25502Configuration headers:
25503$config_headers
25504
25505Configuration commands:
25506$config_commands
25507
25508Report bugs to <bug-autoconf@gnu.org>."
1a4b763e 25509_ACEOF
b61ff9c8 25510
ba479fd2
NN
25511cat >>$CONFIG_STATUS <<_ACEOF
25512ac_cs_version="\\
25513config.status
b61ff9c8
BS
25514configured by $0, generated by GNU Autoconf 2.59,
25515 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
ba479fd2 25516
b61ff9c8 25517Copyright (C) 2003 Free Software Foundation, Inc.
ba479fd2
NN
25518This config.status script is free software; the Free Software Foundation
25519gives unlimited permission to copy, distribute and modify it."
b61ff9c8 25520srcdir=$srcdir
ba479fd2
NN
25521_ACEOF
25522
25523cat >>$CONFIG_STATUS <<\_ACEOF
25524# If no file are specified by the user, then we need to provide default
25525# value. By we need to know if files were specified by the user.
25526ac_need_defaults=:
25527while test $# != 0
25528do
25529 case $1 in
25530 --*=*)
b61ff9c8
BS
25531 ac_option=`expr "x$1" : 'x\([^=]*\)='`
25532 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
ba479fd2
NN
25533 ac_shift=:
25534 ;;
b61ff9c8 25535 -*)
ba479fd2
NN
25536 ac_option=$1
25537 ac_optarg=$2
25538 ac_shift=shift
25539 ;;
b61ff9c8
BS
25540 *) # This is not an option, so the user has probably given explicit
25541 # arguments.
25542 ac_option=$1
25543 ac_need_defaults=false;;
ba479fd2
NN
25544 esac
25545
25546 case $ac_option in
25547 # Handling of the options.
b61ff9c8
BS
25548_ACEOF
25549cat >>$CONFIG_STATUS <<\_ACEOF
ba479fd2
NN
25550 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
25551 ac_cs_recheck=: ;;
b61ff9c8
BS
25552 --version | --vers* | -V )
25553 echo "$ac_cs_version"; exit 0 ;;
25554 --he | --h)
25555 # Conflict between --help and --header
25556 { { echo "$as_me:$LINENO: error: ambiguous option: $1
25557Try \`$0 --help' for more information." >&5
25558echo "$as_me: error: ambiguous option: $1
25559Try \`$0 --help' for more information." >&2;}
25560 { (exit 1); exit 1; }; };;
25561 --help | --hel | -h )
25562 echo "$ac_cs_usage"; exit 0 ;;
25563 --debug | --d* | -d )
ba479fd2
NN
25564 debug=: ;;
25565 --file | --fil | --fi | --f )
25566 $ac_shift
25567 CONFIG_FILES="$CONFIG_FILES $ac_optarg"
25568 ac_need_defaults=false;;
25569 --header | --heade | --head | --hea )
25570 $ac_shift
25571 CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
25572 ac_need_defaults=false;;
25573 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
25574 | -silent | --silent | --silen | --sile | --sil | --si | --s)
25575 ac_cs_silent=: ;;
25576
25577 # This is an error.
b61ff9c8
BS
25578 -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
25579Try \`$0 --help' for more information." >&5
25580echo "$as_me: error: unrecognized option: $1
25581Try \`$0 --help' for more information." >&2;}
ba479fd2
NN
25582 { (exit 1); exit 1; }; } ;;
25583
b61ff9c8 25584 *) ac_config_targets="$ac_config_targets $1" ;;
ba479fd2
NN
25585
25586 esac
25587 shift
6e3f3080 25588done
ba479fd2
NN
25589
25590ac_configure_extra_args=
25591
25592if $ac_cs_silent; then
25593 exec 6>/dev/null
25594 ac_configure_extra_args="$ac_configure_extra_args --silent"
861bb6c1
JL
25595fi
25596
ba479fd2
NN
25597_ACEOF
25598cat >>$CONFIG_STATUS <<_ACEOF
25599if \$ac_cs_recheck; then
b61ff9c8
BS
25600 echo "running $SHELL $0 " $ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
25601 exec $SHELL $0 $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
ba479fd2 25602fi
861bb6c1 25603
ba479fd2
NN
25604_ACEOF
25605
25606cat >>$CONFIG_STATUS <<_ACEOF
25607#
b61ff9c8 25608# INIT-COMMANDS section.
ba479fd2 25609#
b61ff9c8 25610
ba479fd2 25611subdirs='$subdirs'
ba479fd2
NN
25612
25613_ACEOF
25614
1a4b763e 25615
b61ff9c8
BS
25616
25617cat >>$CONFIG_STATUS <<\_ACEOF
ba479fd2
NN
25618for ac_config_target in $ac_config_targets
25619do
b61ff9c8
BS
25620 case "$ac_config_target" in
25621 # Handling of arguments.
25622 "as" ) CONFIG_FILES="$CONFIG_FILES as:exec-tool.in" ;;
25623 "collect-ld" ) CONFIG_FILES="$CONFIG_FILES collect-ld:exec-tool.in" ;;
25624 "nm" ) CONFIG_FILES="$CONFIG_FILES nm:exec-tool.in" ;;
25625 "$all_outputs" ) CONFIG_FILES="$CONFIG_FILES $all_outputs" ;;
25626 "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
25627 "auto-host.h" ) CONFIG_HEADERS="$CONFIG_HEADERS auto-host.h:config.in" ;;
ba479fd2
NN
25628 *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
25629echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
25630 { (exit 1); exit 1; }; };;
861bb6c1 25631 esac
ba479fd2
NN
25632done
25633
25634# If the user did not use the arguments to specify the items to instantiate,
25635# then the envvar interface is used. Set only those that are not.
25636# We use the long form for the default assignment because of an extremely
25637# bizarre bug on SunOS 4.1.3.
25638if $ac_need_defaults; then
25639 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
25640 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
25641 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
25642fi
25643
25644# Have a temporary directory for convenience. Make it in the build tree
b61ff9c8 25645# simply because there is no reason to put it here, and in addition,
ba479fd2 25646# creating and moving files from /tmp can sometimes cause problems.
b61ff9c8 25647# Create a temporary directory, and hook for its removal unless debugging.
ba479fd2
NN
25648$debug ||
25649{
b61ff9c8 25650 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
ba479fd2
NN
25651 trap '{ (exit 1); exit 1; }' 1 2 13 15
25652}
b61ff9c8 25653
ba479fd2 25654# Create a (secure) tmp directory for tmp files.
6e3f3080 25655
ba479fd2 25656{
b61ff9c8 25657 tmp=`(umask 077 && mktemp -d -q "./confstatXXXXXX") 2>/dev/null` &&
ba479fd2
NN
25658 test -n "$tmp" && test -d "$tmp"
25659} ||
25660{
b61ff9c8
BS
25661 tmp=./confstat$$-$RANDOM
25662 (umask 077 && mkdir $tmp)
ba479fd2
NN
25663} ||
25664{
25665 echo "$me: cannot create a temporary directory in ." >&2
25666 { (exit 1); exit 1; }
25667}
25668
b61ff9c8
BS
25669_ACEOF
25670
25671cat >>$CONFIG_STATUS <<_ACEOF
25672
ba479fd2 25673#
b61ff9c8 25674# CONFIG_FILES section.
ba479fd2
NN
25675#
25676
25677# No need to generate the scripts if there are no CONFIG_FILES.
25678# This happens for instance when ./config.status config.h
b61ff9c8
BS
25679if test -n "\$CONFIG_FILES"; then
25680 # Protect against being on the right side of a sed subst in config.status.
25681 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
25682 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
25683s,@SHELL@,$SHELL,;t t
25684s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
25685s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
25686s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
25687s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
25688s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
25689s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
25690s,@exec_prefix@,$exec_prefix,;t t
25691s,@prefix@,$prefix,;t t
25692s,@program_transform_name@,$program_transform_name,;t t
25693s,@bindir@,$bindir,;t t
25694s,@sbindir@,$sbindir,;t t
25695s,@libexecdir@,$libexecdir,;t t
25696s,@datadir@,$datadir,;t t
25697s,@sysconfdir@,$sysconfdir,;t t
25698s,@sharedstatedir@,$sharedstatedir,;t t
25699s,@localstatedir@,$localstatedir,;t t
25700s,@libdir@,$libdir,;t t
25701s,@includedir@,$includedir,;t t
25702s,@oldincludedir@,$oldincludedir,;t t
25703s,@infodir@,$infodir,;t t
25704s,@mandir@,$mandir,;t t
25705s,@build_alias@,$build_alias,;t t
25706s,@host_alias@,$host_alias,;t t
25707s,@target_alias@,$target_alias,;t t
25708s,@DEFS@,$DEFS,;t t
25709s,@ECHO_C@,$ECHO_C,;t t
25710s,@ECHO_N@,$ECHO_N,;t t
25711s,@ECHO_T@,$ECHO_T,;t t
25712s,@LIBS@,$LIBS,;t t
25713s,@build@,$build,;t t
25714s,@build_cpu@,$build_cpu,;t t
25715s,@build_vendor@,$build_vendor,;t t
25716s,@build_os@,$build_os,;t t
25717s,@host@,$host,;t t
25718s,@host_cpu@,$host_cpu,;t t
25719s,@host_vendor@,$host_vendor,;t t
25720s,@host_os@,$host_os,;t t
25721s,@target@,$target,;t t
25722s,@target_cpu@,$target_cpu,;t t
25723s,@target_vendor@,$target_vendor,;t t
25724s,@target_os@,$target_os,;t t
25725s,@target_noncanonical@,$target_noncanonical,;t t
25726s,@build_libsubdir@,$build_libsubdir,;t t
25727s,@build_subdir@,$build_subdir,;t t
25728s,@host_subdir@,$host_subdir,;t t
25729s,@target_subdir@,$target_subdir,;t t
25730s,@GENINSRC@,$GENINSRC,;t t
25731s,@CC@,$CC,;t t
25732s,@CFLAGS@,$CFLAGS,;t t
25733s,@LDFLAGS@,$LDFLAGS,;t t
25734s,@CPPFLAGS@,$CPPFLAGS,;t t
25735s,@ac_ct_CC@,$ac_ct_CC,;t t
25736s,@EXEEXT@,$EXEEXT,;t t
25737s,@OBJEXT@,$OBJEXT,;t t
3d4e720a
ST
25738s,@GNATBIND@,$GNATBIND,;t t
25739s,@ac_ct_GNATBIND@,$ac_ct_GNATBIND,;t t
25740s,@GNATMAKE@,$GNATMAKE,;t t
25741s,@ac_ct_GNATMAKE@,$ac_ct_GNATMAKE,;t t
b61ff9c8
BS
25742s,@NO_MINUS_C_MINUS_O@,$NO_MINUS_C_MINUS_O,;t t
25743s,@OUTPUT_OPTION@,$OUTPUT_OPTION,;t t
25744s,@CPP@,$CPP,;t t
25745s,@EGREP@,$EGREP,;t t
25746s,@loose_warn@,$loose_warn,;t t
b61ff9c8
BS
25747s,@strict_warn@,$strict_warn,;t t
25748s,@warn_cflags@,$warn_cflags,;t t
25749s,@nocommon_flag@,$nocommon_flag,;t t
25750s,@TREEBROWSER@,$TREEBROWSER,;t t
25751s,@valgrind_path@,$valgrind_path,;t t
25752s,@valgrind_path_defines@,$valgrind_path_defines,;t t
25753s,@valgrind_command@,$valgrind_command,;t t
25754s,@coverage_flags@,$coverage_flags,;t t
25755s,@enable_multilib@,$enable_multilib,;t t
25756s,@enable_decimal_float@,$enable_decimal_float,;t t
25757s,@enable_fixed_point@,$enable_fixed_point,;t t
25758s,@enable_shared@,$enable_shared,;t t
25759s,@TARGET_SYSTEM_ROOT@,$TARGET_SYSTEM_ROOT,;t t
25760s,@TARGET_SYSTEM_ROOT_DEFINE@,$TARGET_SYSTEM_ROOT_DEFINE,;t t
25761s,@CROSS_SYSTEM_HEADER_DIR@,$CROSS_SYSTEM_HEADER_DIR,;t t
25762s,@onestep@,$onestep,;t t
25763s,@PKGVERSION@,$PKGVERSION,;t t
25764s,@REPORT_BUGS_TO@,$REPORT_BUGS_TO,;t t
25765s,@REPORT_BUGS_TEXI@,$REPORT_BUGS_TEXI,;t t
25766s,@datarootdir@,$datarootdir,;t t
25767s,@docdir@,$docdir,;t t
25768s,@htmldir@,$htmldir,;t t
25769s,@SET_MAKE@,$SET_MAKE,;t t
25770s,@AWK@,$AWK,;t t
25771s,@LN_S@,$LN_S,;t t
25772s,@LN@,$LN,;t t
25773s,@RANLIB@,$RANLIB,;t t
25774s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
25775s,@ranlib_flags@,$ranlib_flags,;t t
25776s,@INSTALL@,$INSTALL,;t t
25777s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
25778s,@INSTALL_DATA@,$INSTALL_DATA,;t t
25779s,@make_compare_target@,$make_compare_target,;t t
25780s,@have_mktemp_command@,$have_mktemp_command,;t t
25781s,@MAKEINFO@,$MAKEINFO,;t t
25782s,@BUILD_INFO@,$BUILD_INFO,;t t
25783s,@GENERATED_MANPAGES@,$GENERATED_MANPAGES,;t t
25784s,@FLEX@,$FLEX,;t t
25785s,@BISON@,$BISON,;t t
25786s,@NM@,$NM,;t t
25787s,@AR@,$AR,;t t
25788s,@COLLECT2_LIBS@,$COLLECT2_LIBS,;t t
25789s,@GNAT_LIBEXC@,$GNAT_LIBEXC,;t t
25790s,@LDEXP_LIB@,$LDEXP_LIB,;t t
b61ff9c8
BS
25791s,@LIBICONV@,$LIBICONV,;t t
25792s,@LTLIBICONV@,$LTLIBICONV,;t t
25793s,@LIBICONV_DEP@,$LIBICONV_DEP,;t t
25794s,@manext@,$manext,;t t
25795s,@objext@,$objext,;t t
25796s,@gthread_flags@,$gthread_flags,;t t
25797s,@extra_modes_file@,$extra_modes_file,;t t
25798s,@extra_opt_files@,$extra_opt_files,;t t
25799s,@USE_NLS@,$USE_NLS,;t t
25800s,@LIBINTL@,$LIBINTL,;t t
25801s,@LIBINTL_DEP@,$LIBINTL_DEP,;t t
25802s,@INCINTL@,$INCINTL,;t t
25803s,@XGETTEXT@,$XGETTEXT,;t t
25804s,@GMSGFMT@,$GMSGFMT,;t t
25805s,@POSUB@,$POSUB,;t t
25806s,@CATALOGS@,$CATALOGS,;t t
25807s,@DATADIRNAME@,$DATADIRNAME,;t t
25808s,@INSTOBJEXT@,$INSTOBJEXT,;t t
25809s,@GENCAT@,$GENCAT,;t t
25810s,@CATOBJEXT@,$CATOBJEXT,;t t
b61ff9c8
BS
25811s,@CROSS@,$CROSS,;t t
25812s,@ALL@,$ALL,;t t
25813s,@SYSTEM_HEADER_DIR@,$SYSTEM_HEADER_DIR,;t t
25814s,@inhibit_libc@,$inhibit_libc,;t t
25815s,@CC_FOR_BUILD@,$CC_FOR_BUILD,;t t
25816s,@BUILD_CFLAGS@,$BUILD_CFLAGS,;t t
f8c33439 25817s,@BUILD_LDFLAGS@,$BUILD_LDFLAGS,;t t
b61ff9c8 25818s,@STMP_FIXINC@,$STMP_FIXINC,;t t
b61ff9c8 25819s,@collect2@,$collect2,;t t
da0f6381
PB
25820s,@LIBTOOL@,$LIBTOOL,;t t
25821s,@SED@,$SED,;t t
25822s,@FGREP@,$FGREP,;t t
25823s,@GREP@,$GREP,;t t
25824s,@LD@,$LD,;t t
25825s,@DUMPBIN@,$DUMPBIN,;t t
25826s,@ac_ct_DUMPBIN@,$ac_ct_DUMPBIN,;t t
5d47bb02
PG
25827s,@OBJDUMP@,$OBJDUMP,;t t
25828s,@ac_ct_OBJDUMP@,$ac_ct_OBJDUMP,;t t
da0f6381
PB
25829s,@ac_ct_AR@,$ac_ct_AR,;t t
25830s,@STRIP@,$STRIP,;t t
25831s,@ac_ct_STRIP@,$ac_ct_STRIP,;t t
25832s,@lt_ECHO@,$lt_ECHO,;t t
5d47bb02
PG
25833s,@DSYMUTIL@,$DSYMUTIL,;t t
25834s,@ac_ct_DSYMUTIL@,$ac_ct_DSYMUTIL,;t t
25835s,@NMEDIT@,$NMEDIT,;t t
25836s,@ac_ct_NMEDIT@,$ac_ct_NMEDIT,;t t
25837s,@LIPO@,$LIPO,;t t
25838s,@ac_ct_LIPO@,$ac_ct_LIPO,;t t
25839s,@OTOOL@,$OTOOL,;t t
25840s,@ac_ct_OTOOL@,$ac_ct_OTOOL,;t t
25841s,@OTOOL64@,$OTOOL64,;t t
25842s,@ac_ct_OTOOL64@,$ac_ct_OTOOL64,;t t
da0f6381
PB
25843s,@objdir@,$objdir,;t t
25844s,@enable_fast_install@,$enable_fast_install,;t t
b61ff9c8
BS
25845s,@gcc_cv_as@,$gcc_cv_as,;t t
25846s,@ORIGINAL_AS_FOR_TARGET@,$ORIGINAL_AS_FOR_TARGET,;t t
25847s,@gcc_cv_ld@,$gcc_cv_ld,;t t
25848s,@ORIGINAL_LD_FOR_TARGET@,$ORIGINAL_LD_FOR_TARGET,;t t
25849s,@gcc_cv_nm@,$gcc_cv_nm,;t t
25850s,@ORIGINAL_NM_FOR_TARGET@,$ORIGINAL_NM_FOR_TARGET,;t t
25851s,@gcc_cv_objdump@,$gcc_cv_objdump,;t t
6e97481b 25852s,@gcc_cv_readelf@,$gcc_cv_readelf,;t t
b61ff9c8
BS
25853s,@libgcc_visibility@,$libgcc_visibility,;t t
25854s,@GGC@,$GGC,;t t
25855s,@zlibdir@,$zlibdir,;t t
25856s,@zlibinc@,$zlibinc,;t t
25857s,@MAINT@,$MAINT,;t t
25858s,@gcc_tooldir@,$gcc_tooldir,;t t
25859s,@dollar@,$dollar,;t t
25860s,@slibdir@,$slibdir,;t t
b61ff9c8
BS
25861s,@subdirs@,$subdirs,;t t
25862s,@srcdir@,$srcdir,;t t
25863s,@all_compilers@,$all_compilers,;t t
25864s,@all_gtfiles@,$all_gtfiles,;t t
25865s,@all_lang_makefrags@,$all_lang_makefrags,;t t
25866s,@all_lang_makefiles@,$all_lang_makefiles,;t t
25867s,@all_languages@,$all_languages,;t t
25868s,@all_selected_languages@,$all_selected_languages,;t t
25869s,@build_exeext@,$build_exeext,;t t
25870s,@build_install_headers_dir@,$build_install_headers_dir,;t t
25871s,@build_xm_file_list@,$build_xm_file_list,;t t
25872s,@build_xm_include_list@,$build_xm_include_list,;t t
25873s,@build_xm_defines@,$build_xm_defines,;t t
a0e527e3 25874s,@build_file_translate@,$build_file_translate,;t t
b61ff9c8
BS
25875s,@check_languages@,$check_languages,;t t
25876s,@cpp_install_dir@,$cpp_install_dir,;t t
25877s,@xmake_file@,$xmake_file,;t t
25878s,@tmake_file@,$tmake_file,;t t
aca600aa
AS
25879s,@TM_ENDIAN_CONFIG@,$TM_ENDIAN_CONFIG,;t t
25880s,@TM_MULTILIB_CONFIG@,$TM_MULTILIB_CONFIG,;t t
25881s,@TM_MULTILIB_EXCEPTIONS_CONFIG@,$TM_MULTILIB_EXCEPTIONS_CONFIG,;t t
b61ff9c8
BS
25882s,@extra_gcc_objs@,$extra_gcc_objs,;t t
25883s,@extra_headers_list@,$extra_headers_list,;t t
25884s,@extra_objs@,$extra_objs,;t t
25885s,@extra_parts@,$extra_parts,;t t
25886s,@extra_passes@,$extra_passes,;t t
25887s,@extra_programs@,$extra_programs,;t t
25888s,@float_h_file@,$float_h_file,;t t
25889s,@gcc_config_arguments@,$gcc_config_arguments,;t t
25890s,@gcc_gxx_include_dir@,$gcc_gxx_include_dir,;t t
25891s,@host_exeext@,$host_exeext,;t t
25892s,@host_xm_file_list@,$host_xm_file_list,;t t
25893s,@host_xm_include_list@,$host_xm_include_list,;t t
25894s,@host_xm_defines@,$host_xm_defines,;t t
25895s,@out_host_hook_obj@,$out_host_hook_obj,;t t
25896s,@install@,$install,;t t
25897s,@lang_opt_files@,$lang_opt_files,;t t
25898s,@lang_specs_files@,$lang_specs_files,;t t
25899s,@lang_tree_files@,$lang_tree_files,;t t
25900s,@local_prefix@,$local_prefix,;t t
25901s,@md_file@,$md_file,;t t
25902s,@objc_boehm_gc@,$objc_boehm_gc,;t t
25903s,@out_file@,$out_file,;t t
25904s,@out_object_file@,$out_object_file,;t t
25905s,@thread_file@,$thread_file,;t t
25906s,@tm_file_list@,$tm_file_list,;t t
25907s,@tm_include_list@,$tm_include_list,;t t
25908s,@tm_defines@,$tm_defines,;t t
25909s,@tm_p_file_list@,$tm_p_file_list,;t t
25910s,@tm_p_include_list@,$tm_p_include_list,;t t
25911s,@xm_file_list@,$xm_file_list,;t t
25912s,@xm_include_list@,$xm_include_list,;t t
25913s,@xm_defines@,$xm_defines,;t t
207bf79d 25914s,@use_gcc_stdint@,$use_gcc_stdint,;t t
b61ff9c8
BS
25915s,@c_target_objs@,$c_target_objs,;t t
25916s,@cxx_target_objs@,$cxx_target_objs,;t t
c776a6d0 25917s,@fortran_target_objs@,$fortran_target_objs,;t t
b61ff9c8
BS
25918s,@target_cpu_default@,$target_cpu_default,;t t
25919s,@GMPLIBS@,$GMPLIBS,;t t
25920s,@GMPINC@,$GMPINC,;t t
f8bf9252
SP
25921s,@PPLLIBS@,$PPLLIBS,;t t
25922s,@PPLINC@,$PPLINC,;t t
25923s,@CLOOGLIBS@,$CLOOGLIBS,;t t
25924s,@CLOOGINC@,$CLOOGINC,;t t
68a607d8
DN
25925s,@pluginlibs@,$pluginlibs,;t t
25926s,@enable_plugin@,$enable_plugin,;t t
b61ff9c8
BS
25927s,@LIBOBJS@,$LIBOBJS,;t t
25928s,@LTLIBOBJS@,$LTLIBOBJS,;t t
25929/@language_hooks@/r $language_hooks
25930s,@language_hooks@,,;t t
25931CEOF
25932
25933_ACEOF
25934
25935 cat >>$CONFIG_STATUS <<\_ACEOF
25936 # Split the substitutions into bite-sized pieces for seds with
25937 # small command number limits, like on Digital OSF/1 and HP-UX.
25938 ac_max_sed_lines=48
25939 ac_sed_frag=1 # Number of current file.
25940 ac_beg=1 # First line for current file.
25941 ac_end=$ac_max_sed_lines # Line after last line for current file.
25942 ac_more_lines=:
25943 ac_sed_cmds=
25944 while $ac_more_lines; do
25945 if test $ac_beg -gt 1; then
25946 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
25947 else
25948 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
25949 fi
25950 if test ! -s $tmp/subs.frag; then
25951 ac_more_lines=false
25952 else
25953 # The purpose of the label and of the branching condition is to
25954 # speed up the sed processing (if there are no `@' at all, there
25955 # is no need to browse any of the substitutions).
25956 # These are the two extra sed commands mentioned above.
25957 (echo ':t
25958 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
25959 if test -z "$ac_sed_cmds"; then
25960 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
25961 else
25962 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
25963 fi
25964 ac_sed_frag=`expr $ac_sed_frag + 1`
25965 ac_beg=$ac_end
25966 ac_end=`expr $ac_end + $ac_max_sed_lines`
25967 fi
25968 done
25969 if test -z "$ac_sed_cmds"; then
25970 ac_sed_cmds=cat
1a4b763e 25971 fi
b61ff9c8 25972fi # test -n "$CONFIG_FILES"
1a4b763e 25973
1a4b763e 25974_ACEOF
ba479fd2 25975cat >>$CONFIG_STATUS <<\_ACEOF
b61ff9c8
BS
25976for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
25977 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
25978 case $ac_file in
25979 - | *:- | *:-:* ) # input from stdin
25980 cat >$tmp/stdin
25981 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
25982 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
25983 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
25984 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
25985 * ) ac_file_in=$ac_file.in ;;
703d89ab
ZW
25986 esac
25987
b61ff9c8
BS
25988 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
25989 ac_dir=`(dirname "$ac_file") 2>/dev/null ||
ba479fd2 25990$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
86da66b5
HPN
25991 X"$ac_file" : 'X\(//\)[^/]' \| \
25992 X"$ac_file" : 'X\(//\)$' \| \
b61ff9c8
BS
25993 X"$ac_file" : 'X\(/\)' \| \
25994 . : '\(.\)' 2>/dev/null ||
ba479fd2 25995echo X"$ac_file" |
b61ff9c8
BS
25996 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
25997 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
25998 /^X\(\/\/\)$/{ s//\1/; q; }
25999 /^X\(\/\).*/{ s//\1/; q; }
26000 s/.*/./; q'`
26001 { if $as_mkdir_p; then
26002 mkdir -p "$ac_dir"
26003 else
26004 as_dir="$ac_dir"
ba479fd2 26005 as_dirs=
b61ff9c8
BS
26006 while test ! -d "$as_dir"; do
26007 as_dirs="$as_dir $as_dirs"
26008 as_dir=`(dirname "$as_dir") 2>/dev/null ||
ba479fd2 26009$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
86da66b5
HPN
26010 X"$as_dir" : 'X\(//\)[^/]' \| \
26011 X"$as_dir" : 'X\(//\)$' \| \
b61ff9c8
BS
26012 X"$as_dir" : 'X\(/\)' \| \
26013 . : '\(.\)' 2>/dev/null ||
ba479fd2 26014echo X"$as_dir" |
b61ff9c8
BS
26015 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
26016 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
26017 /^X\(\/\/\)$/{ s//\1/; q; }
26018 /^X\(\/\).*/{ s//\1/; q; }
26019 s/.*/./; q'`
ba479fd2 26020 done
b61ff9c8
BS
26021 test ! -n "$as_dirs" || mkdir $as_dirs
26022 fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
26023echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
ba479fd2 26024 { (exit 1); exit 1; }; }; }
b61ff9c8 26025
ba479fd2
NN
26026 ac_builddir=.
26027
b61ff9c8 26028if test "$ac_dir" != .; then
ba479fd2 26029 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
b61ff9c8
BS
26030 # A "../" for each directory in $ac_dir_suffix.
26031 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
26032else
26033 ac_dir_suffix= ac_top_builddir=
26034fi
ba479fd2
NN
26035
26036case $srcdir in
b61ff9c8 26037 .) # No --srcdir option. We are building in place.
ba479fd2 26038 ac_srcdir=.
b61ff9c8
BS
26039 if test -z "$ac_top_builddir"; then
26040 ac_top_srcdir=.
26041 else
26042 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
26043 fi ;;
26044 [\\/]* | ?:[\\/]* ) # Absolute path.
ba479fd2 26045 ac_srcdir=$srcdir$ac_dir_suffix;
b61ff9c8
BS
26046 ac_top_srcdir=$srcdir ;;
26047 *) # Relative path.
26048 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
26049 ac_top_srcdir=$ac_top_builddir$srcdir ;;
ba479fd2 26050esac
ba479fd2 26051
b61ff9c8
BS
26052# Do not use `cd foo && pwd` to compute absolute paths, because
26053# the directories may not exist.
26054case `pwd` in
26055.) ac_abs_builddir="$ac_dir";;
26056*)
26057 case "$ac_dir" in
26058 .) ac_abs_builddir=`pwd`;;
26059 [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
26060 *) ac_abs_builddir=`pwd`/"$ac_dir";;
26061 esac;;
26062esac
26063case $ac_abs_builddir in
26064.) ac_abs_top_builddir=${ac_top_builddir}.;;
26065*)
26066 case ${ac_top_builddir}. in
26067 .) ac_abs_top_builddir=$ac_abs_builddir;;
26068 [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
26069 *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
26070 esac;;
26071esac
26072case $ac_abs_builddir in
26073.) ac_abs_srcdir=$ac_srcdir;;
26074*)
26075 case $ac_srcdir in
26076 .) ac_abs_srcdir=$ac_abs_builddir;;
26077 [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
26078 *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
26079 esac;;
26080esac
26081case $ac_abs_builddir in
26082.) ac_abs_top_srcdir=$ac_top_srcdir;;
26083*)
26084 case $ac_top_srcdir in
26085 .) ac_abs_top_srcdir=$ac_abs_builddir;;
26086 [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
26087 *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
26088 esac;;
26089esac
703d89ab 26090
ab22c1fa 26091
1a4b763e 26092
b61ff9c8
BS
26093 if test x"$ac_file" != x-; then
26094 { echo "$as_me:$LINENO: creating $ac_file" >&5
26095echo "$as_me: creating $ac_file" >&6;}
26096 rm -f "$ac_file"
26097 fi
26098 # Let's still pretend it is `configure' which instantiates (i.e., don't
26099 # use $as_me), people would be surprised to read:
26100 # /* config.h. Generated by config.status. */
26101 if test x"$ac_file" = x-; then
26102 configure_input=
26103 else
26104 configure_input="$ac_file. "
26105 fi
26106 configure_input=$configure_input"Generated from `echo $ac_file_in |
26107 sed 's,.*/,,'` by configure."
26108
26109 # First look for the input files in the build tree, otherwise in the
26110 # src tree.
26111 ac_file_inputs=`IFS=:
26112 for f in $ac_file_in; do
26113 case $f in
26114 -) echo $tmp/stdin ;;
26115 [\\/$]*)
26116 # Absolute (can't be DOS-style, as IFS=:)
26117 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
26118echo "$as_me: error: cannot find input file: $f" >&2;}
26119 { (exit 1); exit 1; }; }
26120 echo "$f";;
26121 *) # Relative
26122 if test -f "$f"; then
26123 # Build tree
26124 echo "$f"
26125 elif test -f "$srcdir/$f"; then
26126 # Source tree
26127 echo "$srcdir/$f"
26128 else
26129 # /dev/null tree
26130 { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
26131echo "$as_me: error: cannot find input file: $f" >&2;}
26132 { (exit 1); exit 1; }; }
26133 fi;;
26134 esac
26135 done` || { (exit 1); exit 1; }
a6ccdbab 26136_ACEOF
ba479fd2
NN
26137cat >>$CONFIG_STATUS <<_ACEOF
26138 sed "$ac_vpsub
26139$extrasub
26140_ACEOF
26141cat >>$CONFIG_STATUS <<\_ACEOF
26142:t
26143/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
b61ff9c8
BS
26144s,@configure_input@,$configure_input,;t t
26145s,@srcdir@,$ac_srcdir,;t t
26146s,@abs_srcdir@,$ac_abs_srcdir,;t t
26147s,@top_srcdir@,$ac_top_srcdir,;t t
26148s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
26149s,@builddir@,$ac_builddir,;t t
26150s,@abs_builddir@,$ac_abs_builddir,;t t
26151s,@top_builddir@,$ac_top_builddir,;t t
26152s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
26153" $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
26154 rm -f $tmp/stdin
26155 if test x"$ac_file" != x-; then
26156 mv $tmp/out $ac_file
26157 else
26158 cat $tmp/out
26159 rm -f $tmp/out
26160 fi
26161
26162 # Run the commands associated with the file.
be0fe523 26163 case $ac_file in
b61ff9c8
BS
26164 as ) chmod +x as ;;
26165 collect-ld ) chmod +x collect-ld ;;
26166 nm ) chmod +x nm ;;
be0fe523 26167 esac
b61ff9c8
BS
26168done
26169_ACEOF
26170cat >>$CONFIG_STATUS <<\_ACEOF
26171
26172#
26173# CONFIG_HEADER section.
26174#
26175
26176# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
26177# NAME is the cpp macro being defined and VALUE is the value it is being given.
26178#
26179# ac_d sets the value in "#define NAME VALUE" lines.
26180ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
26181ac_dB='[ ].*$,\1#\2'
a3bba767 26182ac_dC=' '
b61ff9c8
BS
26183ac_dD=',;t'
26184# ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
26185ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
26186ac_uB='$,\1#\2define\3'
26187ac_uC=' '
26188ac_uD=',;t'
26189
26190for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
26191 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
26192 case $ac_file in
26193 - | *:- | *:-:* ) # input from stdin
26194 cat >$tmp/stdin
26195 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
26196 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
26197 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
26198 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
26199 * ) ac_file_in=$ac_file.in ;;
26200 esac
26201
26202 test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
26203echo "$as_me: creating $ac_file" >&6;}
26204
26205 # First look for the input files in the build tree, otherwise in the
26206 # src tree.
26207 ac_file_inputs=`IFS=:
26208 for f in $ac_file_in; do
26209 case $f in
26210 -) echo $tmp/stdin ;;
26211 [\\/$]*)
26212 # Absolute (can't be DOS-style, as IFS=:)
26213 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
26214echo "$as_me: error: cannot find input file: $f" >&2;}
26215 { (exit 1); exit 1; }; }
26216 # Do quote $f, to prevent DOS paths from being IFS'd.
26217 echo "$f";;
26218 *) # Relative
26219 if test -f "$f"; then
26220 # Build tree
26221 echo "$f"
26222 elif test -f "$srcdir/$f"; then
26223 # Source tree
26224 echo "$srcdir/$f"
26225 else
26226 # /dev/null tree
26227 { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
26228echo "$as_me: error: cannot find input file: $f" >&2;}
26229 { (exit 1); exit 1; }; }
26230 fi;;
26231 esac
26232 done` || { (exit 1); exit 1; }
26233 # Remove the trailing spaces.
26234 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
26235
26236_ACEOF
26237
26238# Transform confdefs.h into two sed scripts, `conftest.defines' and
26239# `conftest.undefs', that substitutes the proper values into
26240# config.h.in to produce config.h. The first handles `#define'
26241# templates, and the second `#undef' templates.
26242# And first: Protect against being on the right side of a sed subst in
26243# config.status. Protect against being in an unquoted here document
26244# in config.status.
26245rm -f conftest.defines conftest.undefs
26246# Using a here document instead of a string reduces the quoting nightmare.
26247# Putting comments in sed scripts is not portable.
26248#
26249# `end' is used to avoid that the second main sed command (meant for
26250# 0-ary CPP macros) applies to n-ary macro definitions.
26251# See the Autoconf documentation for `clear'.
26252cat >confdef2sed.sed <<\_ACEOF
26253s/[\\&,]/\\&/g
26254s,[\\$`],\\&,g
26255t clear
26256: clear
26257s,^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*\)\(([^)]*)\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
26258t end
26259s,^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
26260: end
26261_ACEOF
26262# If some macros were called several times there might be several times
26263# the same #defines, which is useless. Nevertheless, we may not want to
26264# sort them, since we want the *last* AC-DEFINE to be honored.
26265uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
26266sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
26267rm -f confdef2sed.sed
26268
26269# This sed command replaces #undef with comments. This is necessary, for
861bb6c1
JL
26270# example, in the case of _POSIX_SOURCE, which is predefined and required
26271# on some systems where configure will not decide to define it.
b61ff9c8
BS
26272cat >>conftest.undefs <<\_ACEOF
26273s,^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
26274_ACEOF
26275
26276# Break up conftest.defines because some shells have a limit on the size
26277# of here documents, and old seds have small limits too (100 cmds).
26278echo ' # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
26279echo ' if grep "^[ ]*#[ ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
26280echo ' # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
26281echo ' :' >>$CONFIG_STATUS
26282rm -f conftest.tail
26283while grep . conftest.defines >/dev/null
ba479fd2 26284do
b61ff9c8
BS
26285 # Write a limited-size here document to $tmp/defines.sed.
26286 echo ' cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
26287 # Speed up: don't consider the non `#define' lines.
26288 echo '/^[ ]*#[ ]*define/!b' >>$CONFIG_STATUS
26289 # Work around the forget-to-reset-the-flag bug.
26290 echo 't clr' >>$CONFIG_STATUS
26291 echo ': clr' >>$CONFIG_STATUS
26292 sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
ba479fd2 26293 echo 'CEOF
b61ff9c8
BS
26294 sed -f $tmp/defines.sed $tmp/in >$tmp/out
26295 rm -f $tmp/in
26296 mv $tmp/out $tmp/in
26297' >>$CONFIG_STATUS
26298 sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
ba479fd2
NN
26299 rm -f conftest.defines
26300 mv conftest.tail conftest.defines
26301done
b61ff9c8
BS
26302rm -f conftest.defines
26303echo ' fi # grep' >>$CONFIG_STATUS
26304echo >>$CONFIG_STATUS
26305
26306# Break up conftest.undefs because some shells have a limit on the size
26307# of here documents, and old seds have small limits too (100 cmds).
26308echo ' # Handle all the #undef templates' >>$CONFIG_STATUS
26309rm -f conftest.tail
26310while grep . conftest.undefs >/dev/null
26311do
26312 # Write a limited-size here document to $tmp/undefs.sed.
26313 echo ' cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
26314 # Speed up: don't consider the non `#undef'
26315 echo '/^[ ]*#[ ]*undef/!b' >>$CONFIG_STATUS
26316 # Work around the forget-to-reset-the-flag bug.
26317 echo 't clr' >>$CONFIG_STATUS
26318 echo ': clr' >>$CONFIG_STATUS
26319 sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
26320 echo 'CEOF
26321 sed -f $tmp/undefs.sed $tmp/in >$tmp/out
26322 rm -f $tmp/in
26323 mv $tmp/out $tmp/in
26324' >>$CONFIG_STATUS
26325 sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
26326 rm -f conftest.undefs
26327 mv conftest.tail conftest.undefs
26328done
26329rm -f conftest.undefs
ba479fd2
NN
26330
26331cat >>$CONFIG_STATUS <<\_ACEOF
b61ff9c8
BS
26332 # Let's still pretend it is `configure' which instantiates (i.e., don't
26333 # use $as_me), people would be surprised to read:
26334 # /* config.h. Generated by config.status. */
26335 if test x"$ac_file" = x-; then
26336 echo "/* Generated by configure. */" >$tmp/config.h
26337 else
26338 echo "/* $ac_file. Generated by configure. */" >$tmp/config.h
26339 fi
26340 cat $tmp/in >>$tmp/config.h
26341 rm -f $tmp/in
ba479fd2 26342 if test x"$ac_file" != x-; then
b61ff9c8 26343 if diff $ac_file $tmp/config.h >/dev/null 2>&1; then
ba479fd2
NN
26344 { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
26345echo "$as_me: $ac_file is unchanged" >&6;}
26346 else
b61ff9c8
BS
26347 ac_dir=`(dirname "$ac_file") 2>/dev/null ||
26348$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
26349 X"$ac_file" : 'X\(//\)[^/]' \| \
26350 X"$ac_file" : 'X\(//\)$' \| \
26351 X"$ac_file" : 'X\(/\)' \| \
26352 . : '\(.\)' 2>/dev/null ||
26353echo X"$ac_file" |
26354 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
26355 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
26356 /^X\(\/\/\)$/{ s//\1/; q; }
26357 /^X\(\/\).*/{ s//\1/; q; }
26358 s/.*/./; q'`
26359 { if $as_mkdir_p; then
26360 mkdir -p "$ac_dir"
26361 else
26362 as_dir="$ac_dir"
26363 as_dirs=
26364 while test ! -d "$as_dir"; do
26365 as_dirs="$as_dir $as_dirs"
26366 as_dir=`(dirname "$as_dir") 2>/dev/null ||
26367$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
26368 X"$as_dir" : 'X\(//\)[^/]' \| \
26369 X"$as_dir" : 'X\(//\)$' \| \
26370 X"$as_dir" : 'X\(/\)' \| \
26371 . : '\(.\)' 2>/dev/null ||
26372echo X"$as_dir" |
26373 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
26374 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
26375 /^X\(\/\/\)$/{ s//\1/; q; }
26376 /^X\(\/\).*/{ s//\1/; q; }
26377 s/.*/./; q'`
26378 done
26379 test ! -n "$as_dirs" || mkdir $as_dirs
26380 fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
26381echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
26382 { (exit 1); exit 1; }; }; }
26383
ba479fd2 26384 rm -f $ac_file
b61ff9c8 26385 mv $tmp/config.h $ac_file
ba479fd2
NN
26386 fi
26387 else
b61ff9c8
BS
26388 cat $tmp/config.h
26389 rm -f $tmp/config.h
ba479fd2 26390 fi
b61ff9c8
BS
26391done
26392_ACEOF
26393cat >>$CONFIG_STATUS <<\_ACEOF
2f41c1d6 26394
b61ff9c8
BS
26395#
26396# CONFIG_COMMANDS section.
26397#
26398for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
26399 ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
26400 ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
26401 ac_dir=`(dirname "$ac_dest") 2>/dev/null ||
26402$as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
26403 X"$ac_dest" : 'X\(//\)[^/]' \| \
26404 X"$ac_dest" : 'X\(//\)$' \| \
26405 X"$ac_dest" : 'X\(/\)' \| \
26406 . : '\(.\)' 2>/dev/null ||
26407echo X"$ac_dest" |
26408 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
26409 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
26410 /^X\(\/\/\)$/{ s//\1/; q; }
26411 /^X\(\/\).*/{ s//\1/; q; }
26412 s/.*/./; q'`
26413 { if $as_mkdir_p; then
26414 mkdir -p "$ac_dir"
26415 else
26416 as_dir="$ac_dir"
26417 as_dirs=
26418 while test ! -d "$as_dir"; do
26419 as_dirs="$as_dir $as_dirs"
26420 as_dir=`(dirname "$as_dir") 2>/dev/null ||
26421$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
26422 X"$as_dir" : 'X\(//\)[^/]' \| \
26423 X"$as_dir" : 'X\(//\)$' \| \
26424 X"$as_dir" : 'X\(/\)' \| \
26425 . : '\(.\)' 2>/dev/null ||
26426echo X"$as_dir" |
26427 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
26428 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
26429 /^X\(\/\/\)$/{ s//\1/; q; }
26430 /^X\(\/\).*/{ s//\1/; q; }
26431 s/.*/./; q'`
26432 done
26433 test ! -n "$as_dirs" || mkdir $as_dirs
26434 fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
26435echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
26436 { (exit 1); exit 1; }; }; }
2f41c1d6 26437
b61ff9c8 26438 ac_builddir=.
2f41c1d6 26439
b61ff9c8
BS
26440if test "$ac_dir" != .; then
26441 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
26442 # A "../" for each directory in $ac_dir_suffix.
26443 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
26444else
26445 ac_dir_suffix= ac_top_builddir=
26446fi
26447
26448case $srcdir in
26449 .) # No --srcdir option. We are building in place.
26450 ac_srcdir=.
26451 if test -z "$ac_top_builddir"; then
26452 ac_top_srcdir=.
26453 else
26454 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
26455 fi ;;
26456 [\\/]* | ?:[\\/]* ) # Absolute path.
26457 ac_srcdir=$srcdir$ac_dir_suffix;
26458 ac_top_srcdir=$srcdir ;;
26459 *) # Relative path.
26460 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
26461 ac_top_srcdir=$ac_top_builddir$srcdir ;;
26462esac
26463
26464# Do not use `cd foo && pwd` to compute absolute paths, because
26465# the directories may not exist.
26466case `pwd` in
26467.) ac_abs_builddir="$ac_dir";;
26468*)
26469 case "$ac_dir" in
26470 .) ac_abs_builddir=`pwd`;;
26471 [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
26472 *) ac_abs_builddir=`pwd`/"$ac_dir";;
26473 esac;;
26474esac
26475case $ac_abs_builddir in
26476.) ac_abs_top_builddir=${ac_top_builddir}.;;
26477*)
26478 case ${ac_top_builddir}. in
26479 .) ac_abs_top_builddir=$ac_abs_builddir;;
26480 [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
26481 *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
26482 esac;;
26483esac
26484case $ac_abs_builddir in
26485.) ac_abs_srcdir=$ac_srcdir;;
26486*)
26487 case $ac_srcdir in
26488 .) ac_abs_srcdir=$ac_abs_builddir;;
26489 [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
26490 *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
26491 esac;;
26492esac
26493case $ac_abs_builddir in
26494.) ac_abs_top_srcdir=$ac_top_srcdir;;
26495*)
26496 case $ac_top_srcdir in
26497 .) ac_abs_top_srcdir=$ac_abs_builddir;;
26498 [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
26499 *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
26500 esac;;
26501esac
26502
26503
26504 { echo "$as_me:$LINENO: executing $ac_dest commands" >&5
26505echo "$as_me: executing $ac_dest commands" >&6;}
26506 case $ac_dest in
26507 default )
f1faaabd
NN
26508case ${CONFIG_HEADERS} in
26509 *auto-host.h:config.in*)
26510 echo > cstamp-h ;;
861bb6c1 26511esac
2ed26f6b 26512# Make sure all the subdirs exist.
3b620440 26513for d in $subdirs doc build
2ed26f6b 26514do
2ed26f6b 26515 test -d $d || mkdir $d
2ed26f6b 26516done
ba479fd2
NN
26517 ;;
26518 esac
b61ff9c8
BS
26519done
26520_ACEOF
cafe096b 26521
b61ff9c8 26522cat >>$CONFIG_STATUS <<\_ACEOF
ba479fd2
NN
26523
26524{ (exit 0); exit 0; }
26525_ACEOF
861bb6c1 26526chmod +x $CONFIG_STATUS
ba479fd2
NN
26527ac_clean_files=$ac_clean_files_save
26528
26529
26530# configure is writing to config.log, and then calls config.status.
26531# config.status does its own redirection, appending to config.log.
26532# Unfortunately, on DOS this fails, as config.log is still kept open
26533# by configure, so config.status won't be able to write to it; its
26534# output is simply discarded. So we exec the FD to /dev/null,
26535# effectively closing config.log, so it can be properly (re)opened and
26536# appended to by config.status. When coming back to configure, we
26537# need to make the FD available again.
26538if test "$no_create" != yes; then
26539 ac_cs_success=:
26540 ac_config_status_args=
26541 test "$silent" = yes &&
26542 ac_config_status_args="$ac_config_status_args --quiet"
26543 exec 5>/dev/null
26544 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
26545 exec 5>>config.log
26546 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
26547 # would make configure fail if this is the last instruction.
26548 $ac_cs_success || { (exit 1); exit 1; }
26549fi
861bb6c1 26550