Daily bump.
[official-gcc.git] / libjava / configure
blobc1c48b7de8eb20492aa7a83b5515128e4eaf1da3
1 #! /bin/sh
3 # Guess values for system-dependent variables and create Makefiles.
4 # Generated automatically using autoconf version 2.13
5 # Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
7 # This configure script is free software; the Free Software Foundation
8 # gives unlimited permission to copy, distribute and modify it.
10 # Defaults:
11 ac_help=
12 ac_default_prefix=/usr/local
13 # Any additions from configure.in:
14 ac_help="$ac_help
15 --with-target-subdir=SUBDIR
16 configuring in a subdirectory"
17 ac_help="$ac_help
18 --with-cross-host=HOST configuring with a cross compiler"
19 ac_help="$ac_help
20 --enable-multilib build many library versions (default)"
21 ac_help="$ac_help
22 --disable-dependency-tracking Speeds up one-time builds
23 --enable-dependency-tracking Do not reject slow dependency extractors"
24 ac_help="$ac_help
25 --enable-maintainer-mode enable make rules and dependencies not useful
26 (and sometimes confusing) to the casual installer"
27 ac_help="$ac_help
28 --enable-shared[=PKGS] build shared libraries [default=yes]"
29 ac_help="$ac_help
30 --enable-static[=PKGS] build static libraries [default=yes]"
31 ac_help="$ac_help
32 --enable-fast-install[=PKGS] optimize for fast installation [default=yes]"
33 ac_help="$ac_help
34 --with-gnu-ld assume the C compiler uses GNU ld [default=no]"
35 ac_help="$ac_help
36 --disable-libtool-lock avoid locking (might break parallel builds)"
37 ac_help="$ac_help
38 --with-pic try to use only PIC/non-PIC objects [default=use both]"
39 ac_help="$ac_help
40 --disable-getenv-properties
41 don't set system properties from GCJ_PROPERTIES"
42 ac_help="$ac_help
43 --enable-hash-synchronization
44 Use global hash table for monitor locks"
45 ac_help="$ac_help
46 --enable-libgcj-debug enable runtime debugging code"
47 ac_help="$ac_help
48 --enable-interpreter enable interpreter"
49 ac_help="$ac_help
50 --enable-sjlj-exceptions force use of builtin_setjmp for exceptions"
51 ac_help="$ac_help
52 --disable-java-net disable java.net"
53 ac_help="$ac_help
54 --without-libffi don't use libffi"
55 ac_help="$ac_help
56 --disable-jvmpi disable JVMPI support"
57 ac_help="$ac_help
58 --with-ecos enable runtime eCos target support"
59 ac_help="$ac_help
60 --with-system-zlib use installed libz"
61 ac_help="$ac_help
62 --enable-java-gc=TYPE choose garbage collector [boehm]"
63 ac_help="$ac_help
64 --with-libiconv-prefix=DIR search for libiconv in DIR/include and DIR/lib"
65 ac_help="$ac_help
66 --with-x use the X Window System"
67 ac_help="$ac_help
68 --enable-java-awt list of AWT peer implementations to be built"
70 # Initialize some variables set by options.
71 # The variables have the same names as the options, with
72 # dashes changed to underlines.
73 build=NONE
74 cache_file=./config.cache
75 exec_prefix=NONE
76 host=NONE
77 no_create=
78 nonopt=NONE
79 no_recursion=
80 prefix=NONE
81 program_prefix=NONE
82 program_suffix=NONE
83 program_transform_name=s,x,x,
84 silent=
85 site=
86 srcdir=
87 target=NONE
88 verbose=
89 x_includes=NONE
90 x_libraries=NONE
91 bindir='${exec_prefix}/bin'
92 sbindir='${exec_prefix}/sbin'
93 libexecdir='${exec_prefix}/libexec'
94 datadir='${prefix}/share'
95 sysconfdir='${prefix}/etc'
96 sharedstatedir='${prefix}/com'
97 localstatedir='${prefix}/var'
98 libdir='${exec_prefix}/lib'
99 includedir='${prefix}/include'
100 oldincludedir='/usr/include'
101 infodir='${prefix}/info'
102 mandir='${prefix}/man'
104 # Initialize some other variables.
105 subdirs=
106 MFLAGS= MAKEFLAGS=
107 SHELL=${CONFIG_SHELL-/bin/sh}
108 # Maximum number of lines to put in a shell here document.
109 ac_max_here_lines=12
111 ac_prev=
112 for ac_option
115 # If the previous option needs an argument, assign it.
116 if test -n "$ac_prev"; then
117 eval "$ac_prev=\$ac_option"
118 ac_prev=
119 continue
122 case "$ac_option" in
123 -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
124 *) ac_optarg= ;;
125 esac
127 # Accept the important Cygnus configure options, so we can diagnose typos.
129 case "$ac_option" in
131 -bindir | --bindir | --bindi | --bind | --bin | --bi)
132 ac_prev=bindir ;;
133 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
134 bindir="$ac_optarg" ;;
136 -build | --build | --buil | --bui | --bu)
137 ac_prev=build ;;
138 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
139 build="$ac_optarg" ;;
141 -cache-file | --cache-file | --cache-fil | --cache-fi \
142 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
143 ac_prev=cache_file ;;
144 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
145 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
146 cache_file="$ac_optarg" ;;
148 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
149 ac_prev=datadir ;;
150 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
151 | --da=*)
152 datadir="$ac_optarg" ;;
154 -disable-* | --disable-*)
155 ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
156 # Reject names that are not valid shell variable names.
157 if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
158 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
160 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
161 eval "enable_${ac_feature}=no" ;;
163 -enable-* | --enable-*)
164 ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
165 # Reject names that are not valid shell variable names.
166 if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
167 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
169 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
170 case "$ac_option" in
171 *=*) ;;
172 *) ac_optarg=yes ;;
173 esac
174 eval "enable_${ac_feature}='$ac_optarg'" ;;
176 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
177 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
178 | --exec | --exe | --ex)
179 ac_prev=exec_prefix ;;
180 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
181 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
182 | --exec=* | --exe=* | --ex=*)
183 exec_prefix="$ac_optarg" ;;
185 -gas | --gas | --ga | --g)
186 # Obsolete; use --with-gas.
187 with_gas=yes ;;
189 -help | --help | --hel | --he)
190 # Omit some internal or obsolete options to make the list less imposing.
191 # This message is too long to be a string in the A/UX 3.1 sh.
192 cat << EOF
193 Usage: configure [options] [host]
194 Options: [defaults in brackets after descriptions]
195 Configuration:
196 --cache-file=FILE cache test results in FILE
197 --help print this message
198 --no-create do not create output files
199 --quiet, --silent do not print \`checking...' messages
200 --version print the version of autoconf that created configure
201 Directory and file names:
202 --prefix=PREFIX install architecture-independent files in PREFIX
203 [$ac_default_prefix]
204 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
205 [same as prefix]
206 --bindir=DIR user executables in DIR [EPREFIX/bin]
207 --sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
208 --libexecdir=DIR program executables in DIR [EPREFIX/libexec]
209 --datadir=DIR read-only architecture-independent data in DIR
210 [PREFIX/share]
211 --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
212 --sharedstatedir=DIR modifiable architecture-independent data in DIR
213 [PREFIX/com]
214 --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
215 --libdir=DIR object code libraries in DIR [EPREFIX/lib]
216 --includedir=DIR C header files in DIR [PREFIX/include]
217 --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
218 --infodir=DIR info documentation in DIR [PREFIX/info]
219 --mandir=DIR man documentation in DIR [PREFIX/man]
220 --srcdir=DIR find the sources in DIR [configure dir or ..]
221 --program-prefix=PREFIX prepend PREFIX to installed program names
222 --program-suffix=SUFFIX append SUFFIX to installed program names
223 --program-transform-name=PROGRAM
224 run sed PROGRAM on installed program names
226 cat << EOF
227 Host type:
228 --build=BUILD configure for building on BUILD [BUILD=HOST]
229 --host=HOST configure for HOST [guessed]
230 --target=TARGET configure for TARGET [TARGET=HOST]
231 Features and packages:
232 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
233 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
234 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
235 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
236 --x-includes=DIR X include files are in DIR
237 --x-libraries=DIR X library files are in DIR
239 if test -n "$ac_help"; then
240 echo "--enable and --with options recognized:$ac_help"
242 exit 0 ;;
244 -host | --host | --hos | --ho)
245 ac_prev=host ;;
246 -host=* | --host=* | --hos=* | --ho=*)
247 host="$ac_optarg" ;;
249 -includedir | --includedir | --includedi | --included | --include \
250 | --includ | --inclu | --incl | --inc)
251 ac_prev=includedir ;;
252 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
253 | --includ=* | --inclu=* | --incl=* | --inc=*)
254 includedir="$ac_optarg" ;;
256 -infodir | --infodir | --infodi | --infod | --info | --inf)
257 ac_prev=infodir ;;
258 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
259 infodir="$ac_optarg" ;;
261 -libdir | --libdir | --libdi | --libd)
262 ac_prev=libdir ;;
263 -libdir=* | --libdir=* | --libdi=* | --libd=*)
264 libdir="$ac_optarg" ;;
266 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
267 | --libexe | --libex | --libe)
268 ac_prev=libexecdir ;;
269 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
270 | --libexe=* | --libex=* | --libe=*)
271 libexecdir="$ac_optarg" ;;
273 -localstatedir | --localstatedir | --localstatedi | --localstated \
274 | --localstate | --localstat | --localsta | --localst \
275 | --locals | --local | --loca | --loc | --lo)
276 ac_prev=localstatedir ;;
277 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
278 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
279 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
280 localstatedir="$ac_optarg" ;;
282 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
283 ac_prev=mandir ;;
284 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
285 mandir="$ac_optarg" ;;
287 -nfp | --nfp | --nf)
288 # Obsolete; use --without-fp.
289 with_fp=no ;;
291 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
292 | --no-cr | --no-c)
293 no_create=yes ;;
295 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
296 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
297 no_recursion=yes ;;
299 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
300 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
301 | --oldin | --oldi | --old | --ol | --o)
302 ac_prev=oldincludedir ;;
303 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
304 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
305 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
306 oldincludedir="$ac_optarg" ;;
308 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
309 ac_prev=prefix ;;
310 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
311 prefix="$ac_optarg" ;;
313 -program-prefix | --program-prefix | --program-prefi | --program-pref \
314 | --program-pre | --program-pr | --program-p)
315 ac_prev=program_prefix ;;
316 -program-prefix=* | --program-prefix=* | --program-prefi=* \
317 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
318 program_prefix="$ac_optarg" ;;
320 -program-suffix | --program-suffix | --program-suffi | --program-suff \
321 | --program-suf | --program-su | --program-s)
322 ac_prev=program_suffix ;;
323 -program-suffix=* | --program-suffix=* | --program-suffi=* \
324 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
325 program_suffix="$ac_optarg" ;;
327 -program-transform-name | --program-transform-name \
328 | --program-transform-nam | --program-transform-na \
329 | --program-transform-n | --program-transform- \
330 | --program-transform | --program-transfor \
331 | --program-transfo | --program-transf \
332 | --program-trans | --program-tran \
333 | --progr-tra | --program-tr | --program-t)
334 ac_prev=program_transform_name ;;
335 -program-transform-name=* | --program-transform-name=* \
336 | --program-transform-nam=* | --program-transform-na=* \
337 | --program-transform-n=* | --program-transform-=* \
338 | --program-transform=* | --program-transfor=* \
339 | --program-transfo=* | --program-transf=* \
340 | --program-trans=* | --program-tran=* \
341 | --progr-tra=* | --program-tr=* | --program-t=*)
342 program_transform_name="$ac_optarg" ;;
344 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
345 | -silent | --silent | --silen | --sile | --sil)
346 silent=yes ;;
348 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
349 ac_prev=sbindir ;;
350 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
351 | --sbi=* | --sb=*)
352 sbindir="$ac_optarg" ;;
354 -sharedstatedir | --sharedstatedir | --sharedstatedi \
355 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
356 | --sharedst | --shareds | --shared | --share | --shar \
357 | --sha | --sh)
358 ac_prev=sharedstatedir ;;
359 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
360 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
361 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
362 | --sha=* | --sh=*)
363 sharedstatedir="$ac_optarg" ;;
365 -site | --site | --sit)
366 ac_prev=site ;;
367 -site=* | --site=* | --sit=*)
368 site="$ac_optarg" ;;
370 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
371 ac_prev=srcdir ;;
372 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
373 srcdir="$ac_optarg" ;;
375 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
376 | --syscon | --sysco | --sysc | --sys | --sy)
377 ac_prev=sysconfdir ;;
378 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
379 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
380 sysconfdir="$ac_optarg" ;;
382 -target | --target | --targe | --targ | --tar | --ta | --t)
383 ac_prev=target ;;
384 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
385 target="$ac_optarg" ;;
387 -v | -verbose | --verbose | --verbos | --verbo | --verb)
388 verbose=yes ;;
390 -version | --version | --versio | --versi | --vers)
391 echo "configure generated by autoconf version 2.13"
392 exit 0 ;;
394 -with-* | --with-*)
395 ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
396 # Reject names that are not valid shell variable names.
397 if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
398 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
400 ac_package=`echo $ac_package| sed 's/-/_/g'`
401 case "$ac_option" in
402 *=*) ;;
403 *) ac_optarg=yes ;;
404 esac
405 eval "with_${ac_package}='$ac_optarg'" ;;
407 -without-* | --without-*)
408 ac_package=`echo $ac_option|sed -e 's/-*without-//'`
409 # Reject names that are not valid shell variable names.
410 if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
411 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
413 ac_package=`echo $ac_package| sed 's/-/_/g'`
414 eval "with_${ac_package}=no" ;;
416 --x)
417 # Obsolete; use --with-x.
418 with_x=yes ;;
420 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
421 | --x-incl | --x-inc | --x-in | --x-i)
422 ac_prev=x_includes ;;
423 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
424 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
425 x_includes="$ac_optarg" ;;
427 -x-libraries | --x-libraries | --x-librarie | --x-librari \
428 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
429 ac_prev=x_libraries ;;
430 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
431 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
432 x_libraries="$ac_optarg" ;;
434 -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
438 if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
439 echo "configure: warning: $ac_option: invalid host type" 1>&2
441 if test "x$nonopt" != xNONE; then
442 { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
444 nonopt="$ac_option"
447 esac
448 done
450 if test -n "$ac_prev"; then
451 { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
454 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
456 # File descriptor usage:
457 # 0 standard input
458 # 1 file creation
459 # 2 errors and warnings
460 # 3 some systems may open it to /dev/tty
461 # 4 used on the Kubota Titan
462 # 6 checking for... messages and results
463 # 5 compiler messages saved in config.log
464 if test "$silent" = yes; then
465 exec 6>/dev/null
466 else
467 exec 6>&1
469 exec 5>./config.log
471 echo "\
472 This file contains any messages produced by compilers while
473 running configure, to aid debugging if configure makes a mistake.
474 " 1>&5
476 # Strip out --no-create and --no-recursion so they do not pile up.
477 # Also quote any args containing shell metacharacters.
478 ac_configure_args=
479 for ac_arg
481 case "$ac_arg" in
482 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
483 | --no-cr | --no-c) ;;
484 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
485 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
486 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
487 ac_configure_args="$ac_configure_args '$ac_arg'" ;;
488 *) ac_configure_args="$ac_configure_args $ac_arg" ;;
489 esac
490 done
492 # NLS nuisances.
493 # Only set these to C if already set. These must not be set unconditionally
494 # because not all systems understand e.g. LANG=C (notably SCO).
495 # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
496 # Non-C LC_CTYPE values break the ctype check.
497 if test "${LANG+set}" = set; then LANG=C; export LANG; fi
498 if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
499 if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
500 if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi
502 # confdefs.h avoids OS command line length limits that DEFS can exceed.
503 rm -rf conftest* confdefs.h
504 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
505 echo > confdefs.h
507 # A filename unique to this package, relative to the directory that
508 # configure is in, which we can look for to find out if srcdir is correct.
509 ac_unique_file=java/lang/System.java
511 # Find the source files, if location was not specified.
512 if test -z "$srcdir"; then
513 ac_srcdir_defaulted=yes
514 # Try the directory containing this script, then its parent.
515 ac_prog=$0
516 ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
517 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
518 srcdir=$ac_confdir
519 if test ! -r $srcdir/$ac_unique_file; then
520 srcdir=..
522 else
523 ac_srcdir_defaulted=no
525 if test ! -r $srcdir/$ac_unique_file; then
526 if test "$ac_srcdir_defaulted" = yes; then
527 { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
528 else
529 { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
532 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
534 # Prefer explicitly selected file to automatically selected ones.
535 if test -z "$CONFIG_SITE"; then
536 if test "x$prefix" != xNONE; then
537 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
538 else
539 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
542 for ac_site_file in $CONFIG_SITE; do
543 if test -r "$ac_site_file"; then
544 echo "loading site script $ac_site_file"
545 . "$ac_site_file"
547 done
549 if test -r "$cache_file"; then
550 echo "loading cache $cache_file"
551 . $cache_file
552 else
553 echo "creating cache $cache_file"
554 > $cache_file
557 ac_ext=c
558 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
559 ac_cpp='$CPP $CPPFLAGS'
560 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
561 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
562 cross_compiling=$ac_cv_prog_cc_cross
564 ac_exeext=
565 ac_objext=o
566 if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
567 # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
568 if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
569 ac_n= ac_c='
570 ' ac_t=' '
571 else
572 ac_n=-n ac_c= ac_t=
574 else
575 ac_n= ac_c='\c' ac_t=
580 # This works around the fact that libtool configuration may change LD
581 # for this particular configuration, but some shells, instead of
582 # keeping the changes in LD private, export them just because LD is
583 # exported.
584 ORIGINAL_LD_FOR_MULTILIBS=$LD
586 echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
587 echo "configure:588: checking whether ln -s works" >&5
588 if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
589 echo $ac_n "(cached) $ac_c" 1>&6
590 else
591 rm -f conftestdata
592 if ln -s X conftestdata 2>/dev/null
593 then
594 rm -f conftestdata
595 ac_cv_prog_LN_S="ln -s"
596 else
597 ac_cv_prog_LN_S=ln
600 LN_S="$ac_cv_prog_LN_S"
601 if test "$ac_cv_prog_LN_S" = "ln -s"; then
602 echo "$ac_t""yes" 1>&6
603 else
604 echo "$ac_t""no" 1>&6
608 # Check whether --with-target-subdir or --without-target-subdir was given.
609 if test "${with_target_subdir+set}" = set; then
610 withval="$with_target_subdir"
614 # Check whether --with-cross-host or --without-cross-host was given.
615 if test "${with_cross_host+set}" = set; then
616 withval="$with_cross_host"
622 # expand $ac_aux_dir to an absolute path
623 am_aux_dir=`CDPATH=:; cd $ac_aux_dir && pwd`
625 # Find a good install program. We prefer a C program (faster),
626 # so one script is as good as another. But avoid the broken or
627 # incompatible versions:
628 # SysV /etc/install, /usr/sbin/install
629 # SunOS /usr/etc/install
630 # IRIX /sbin/install
631 # AIX /bin/install
632 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
633 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
634 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
635 # ./install, which can be erroneously created by make from ./install.sh.
636 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
637 echo "configure:638: checking for a BSD compatible install" >&5
638 if test -z "$INSTALL"; then
639 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
640 echo $ac_n "(cached) $ac_c" 1>&6
641 else
642 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":"
643 for ac_dir in $PATH; do
644 # Account for people who put trailing slashes in PATH elements.
645 case "$ac_dir/" in
646 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
648 # OSF1 and SCO ODT 3.0 have their own names for install.
649 # Don't use installbsd from OSF since it installs stuff as root
650 # by default.
651 for ac_prog in ginstall scoinst install; do
652 if test -f $ac_dir/$ac_prog; then
653 if test $ac_prog = install &&
654 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
655 # AIX install. It has an incompatible calling convention.
657 else
658 ac_cv_path_install="$ac_dir/$ac_prog -c"
659 break 2
662 done
664 esac
665 done
666 IFS="$ac_save_IFS"
669 if test "${ac_cv_path_install+set}" = set; then
670 INSTALL="$ac_cv_path_install"
671 else
672 # As a last resort, use the slow shell script. We don't cache a
673 # path for INSTALL within a source directory, because that will
674 # break other packages using the cache if that directory is
675 # removed, or if the path is relative.
676 INSTALL="$ac_install_sh"
679 echo "$ac_t""$INSTALL" 1>&6
681 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
682 # It thinks the first close brace ends the variable substitution.
683 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
685 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
687 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
689 echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
690 echo "configure:691: checking whether build environment is sane" >&5
691 # Just in case
692 sleep 1
693 echo timestamp > conftest.file
694 # Do `set' in a subshell so we don't clobber the current shell's
695 # arguments. Must try -L first in case configure is actually a
696 # symlink; some systems play weird games with the mod time of symlinks
697 # (eg FreeBSD returns the mod time of the symlink's containing
698 # directory).
699 if (
700 set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null`
701 if test "$*" = "X"; then
702 # -L didn't work.
703 set X `ls -t $srcdir/configure conftest.file`
705 rm -f conftest.file
706 if test "$*" != "X $srcdir/configure conftest.file" \
707 && test "$*" != "X conftest.file $srcdir/configure"; then
709 # If neither matched, then we have a broken ls. This can happen
710 # if, for instance, CONFIG_SHELL is bash and it inherits a
711 # broken ls alias from the environment. This has actually
712 # happened. Such a system could not be considered "sane".
713 { echo "configure: error: ls -t appears to fail. Make sure there is not a broken
714 alias in your environment" 1>&2; exit 1; }
717 test "$2" = conftest.file
719 then
720 # Ok.
722 else
723 { echo "configure: error: newly created file is older than distributed files!
724 Check your system clock" 1>&2; exit 1; }
726 echo "$ac_t""yes" 1>&6
727 if test "$program_transform_name" = s,x,x,; then
728 program_transform_name=
729 else
730 # Double any \ or $. echo might interpret backslashes.
731 cat <<\EOF_SED > conftestsed
732 s,\\,\\\\,g; s,\$,$$,g
733 EOF_SED
734 program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
735 rm -f conftestsed
737 test "$program_prefix" != NONE &&
738 program_transform_name="s,^,${program_prefix},; $program_transform_name"
739 # Use a double $ so make ignores it.
740 test "$program_suffix" != NONE &&
741 program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
743 # sed with no file args requires a program.
744 test "$program_transform_name" = "" && program_transform_name="s,x,x,"
746 test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing"
747 # Use eval to expand $SHELL
748 if eval "$MISSING --run true"; then
749 am_missing_run="$MISSING --run "
750 else
751 am_missing_run=
752 am_backtick='`'
753 echo "configure: warning: ${am_backtick}missing' script is too old or missing" 1>&2
756 for ac_prog in gawk mawk nawk awk
758 # Extract the first word of "$ac_prog", so it can be a program name with args.
759 set dummy $ac_prog; ac_word=$2
760 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
761 echo "configure:762: checking for $ac_word" >&5
762 if eval "test \"`echo '$''{'ac_cv_prog_AWK'+set}'`\" = set"; then
763 echo $ac_n "(cached) $ac_c" 1>&6
764 else
765 if test -n "$AWK"; then
766 ac_cv_prog_AWK="$AWK" # Let the user override the test.
767 else
768 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
769 ac_dummy="$PATH"
770 for ac_dir in $ac_dummy; do
771 test -z "$ac_dir" && ac_dir=.
772 if test -f $ac_dir/$ac_word; then
773 ac_cv_prog_AWK="$ac_prog"
774 break
776 done
777 IFS="$ac_save_ifs"
780 AWK="$ac_cv_prog_AWK"
781 if test -n "$AWK"; then
782 echo "$ac_t""$AWK" 1>&6
783 else
784 echo "$ac_t""no" 1>&6
787 test -n "$AWK" && break
788 done
790 echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
791 echo "configure:792: checking whether ${MAKE-make} sets \${MAKE}" >&5
792 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
793 if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
794 echo $ac_n "(cached) $ac_c" 1>&6
795 else
796 cat > conftestmake <<\EOF
797 all:
798 @echo 'ac_maketemp="${MAKE}"'
800 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
801 eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
802 if test -n "$ac_maketemp"; then
803 eval ac_cv_prog_make_${ac_make}_set=yes
804 else
805 eval ac_cv_prog_make_${ac_make}_set=no
807 rm -f conftestmake
809 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
810 echo "$ac_t""yes" 1>&6
811 SET_MAKE=
812 else
813 echo "$ac_t""no" 1>&6
814 SET_MAKE="MAKE=${MAKE-make}"
817 # Check whether --enable-dependency-tracking or --disable-dependency-tracking was given.
818 if test "${enable_dependency_tracking+set}" = set; then
819 enableval="$enable_dependency_tracking"
823 if test "x$enable_dependency_tracking" != xno; then
824 am_depcomp="$ac_aux_dir/depcomp"
825 AMDEPBACKSLASH='\'
829 if test "x$enable_dependency_tracking" != xno; then
830 AMDEP_TRUE=
831 AMDEP_FALSE='#'
832 else
833 AMDEP_TRUE='#'
834 AMDEP_FALSE=
840 rm -f .deps 2>/dev/null
841 mkdir .deps 2>/dev/null
842 if test -d .deps; then
843 DEPDIR=.deps
844 else
845 # MS-DOS does not allow filenames that begin with a dot.
846 DEPDIR=_deps
848 rmdir .deps 2>/dev/null
853 am_make=${MAKE-make}
854 cat > confinc << 'END'
855 doit:
856 @echo done
858 # If we don't find an include directive, just comment out the code.
859 echo $ac_n "checking for style of include used by $am_make""... $ac_c" 1>&6
860 echo "configure:861: checking for style of include used by $am_make" >&5
861 am__include='#'
862 am__quote=
863 _am_result=none
864 # First try GNU make style include.
865 echo "include confinc" > confmf
866 # We grep out `Entering directory' and `Leaving directory'
867 # messages which can occur if `w' ends up in MAKEFLAGS.
868 # In particular we don't look at `^make:' because GNU make might
869 # be invoked under some other name (usually "gmake"), in which
870 # case it prints its new name instead of `make'.
871 if test "`$am_make -s -f confmf 2> /dev/null | fgrep -v 'ing directory'`" = "done"; then
872 am__include=include
873 am__quote=
874 _am_result=GNU
876 # Now try BSD make style include.
877 if test "$am__include" = "#"; then
878 echo '.include "confinc"' > confmf
879 if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then
880 am__include=.include
881 am__quote='"'
882 _am_result=BSD
887 echo "$ac_t""$_am_result" 1>&6
888 rm -f confinc confmf
890 if test $host != $build; then
891 ac_tool_prefix=${host_alias}-
892 else
893 ac_tool_prefix=
896 echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
897 echo "configure:898: checking for Cygwin environment" >&5
898 if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
899 echo $ac_n "(cached) $ac_c" 1>&6
900 else
901 cat > conftest.$ac_ext <<EOF
902 #line 903 "configure"
903 #include "confdefs.h"
905 int main() {
907 #ifndef __CYGWIN__
908 #define __CYGWIN__ __CYGWIN32__
909 #endif
910 return __CYGWIN__;
911 ; return 0; }
913 if { (eval echo configure:914: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
914 rm -rf conftest*
915 ac_cv_cygwin=yes
916 else
917 echo "configure: failed program was:" >&5
918 cat conftest.$ac_ext >&5
919 rm -rf conftest*
920 ac_cv_cygwin=no
922 rm -f conftest*
923 rm -f conftest*
926 echo "$ac_t""$ac_cv_cygwin" 1>&6
927 CYGWIN=
928 test "$ac_cv_cygwin" = yes && CYGWIN=yes
929 echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
930 echo "configure:931: checking for mingw32 environment" >&5
931 if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
932 echo $ac_n "(cached) $ac_c" 1>&6
933 else
934 cat > conftest.$ac_ext <<EOF
935 #line 936 "configure"
936 #include "confdefs.h"
938 int main() {
939 return __MINGW32__;
940 ; return 0; }
942 if { (eval echo configure:943: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
943 rm -rf conftest*
944 ac_cv_mingw32=yes
945 else
946 echo "configure: failed program was:" >&5
947 cat conftest.$ac_ext >&5
948 rm -rf conftest*
949 ac_cv_mingw32=no
951 rm -f conftest*
952 rm -f conftest*
955 echo "$ac_t""$ac_cv_mingw32" 1>&6
956 MINGW32=
957 test "$ac_cv_mingw32" = yes && MINGW32=yes
959 # Check whether --enable-multilib or --disable-multilib was given.
960 if test "${enable_multilib+set}" = set; then
961 enableval="$enable_multilib"
962 case "${enableval}" in
963 yes) multilib=yes ;;
964 no) multilib=no ;;
965 *) { echo "configure: error: bad value ${enableval} for multilib option" 1>&2; exit 1; } ;;
966 esac
967 else
968 multilib=yes
972 # When building with srcdir == objdir, links to the source files will
973 # be created in directories within the target_subdir. We have to
974 # adjust toplevel_srcdir accordingly, so that configure finds
975 # install-sh and other auxiliary files that live in the top-level
976 # source directory.
977 if test "${srcdir}" = "."; then
978 if test -z "${with_target_subdir}"; then
979 toprel=".."
980 else
981 if test "${with_target_subdir}" != "."; then
982 toprel="${with_multisrctop}../.."
983 else
984 toprel="${with_multisrctop}.."
987 else
988 toprel=".."
991 libgcj_basedir=$srcdir/$toprel/./libjava
994 ac_aux_dir=
995 for ac_dir in ${srcdir}/$toprel $srcdir/${srcdir}/$toprel; do
996 if test -f $ac_dir/install-sh; then
997 ac_aux_dir=$ac_dir
998 ac_install_sh="$ac_aux_dir/install-sh -c"
999 break
1000 elif test -f $ac_dir/install.sh; then
1001 ac_aux_dir=$ac_dir
1002 ac_install_sh="$ac_aux_dir/install.sh -c"
1003 break
1005 done
1006 if test -z "$ac_aux_dir"; then
1007 { echo "configure: error: can not find install-sh or install.sh in ${srcdir}/$toprel $srcdir/${srcdir}/$toprel" 1>&2; exit 1; }
1009 ac_config_guess=$ac_aux_dir/config.guess
1010 ac_config_sub=$ac_aux_dir/config.sub
1011 ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
1013 if :; then :; else
1014 # This overrides the previous occurrence for automake, but not for
1015 # autoconf, which is exactly what we want.
1016 ac_aux_dir=
1017 for ac_dir in .. $srcdir/..; do
1018 if test -f $ac_dir/install-sh; then
1019 ac_aux_dir=$ac_dir
1020 ac_install_sh="$ac_aux_dir/install-sh -c"
1021 break
1022 elif test -f $ac_dir/install.sh; then
1023 ac_aux_dir=$ac_dir
1024 ac_install_sh="$ac_aux_dir/install.sh -c"
1025 break
1027 done
1028 if test -z "$ac_aux_dir"; then
1029 { echo "configure: error: can not find install-sh or install.sh in .. $srcdir/.." 1>&2; exit 1; }
1031 ac_config_guess=$ac_aux_dir/config.guess
1032 ac_config_sub=$ac_aux_dir/config.sub
1033 ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
1037 # This works around an automake problem.
1038 mkinstalldirs="`cd $ac_aux_dir && pwd`/mkinstalldirs"
1042 # Do some error checking and defaulting for the host and target type.
1043 # The inputs are:
1044 # configure --host=HOST --target=TARGET --build=BUILD NONOPT
1046 # The rules are:
1047 # 1. You are not allowed to specify --host, --target, and nonopt at the
1048 # same time.
1049 # 2. Host defaults to nonopt.
1050 # 3. If nonopt is not specified, then host defaults to the current host,
1051 # as determined by config.guess.
1052 # 4. Target and build default to nonopt.
1053 # 5. If nonopt is not specified, then target and build default to host.
1055 # The aliases save the names the user supplied, while $host etc.
1056 # will get canonicalized.
1057 case $host---$target---$nonopt in
1058 NONE---*---* | *---NONE---* | *---*---NONE) ;;
1059 *) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
1060 esac
1063 # Make sure we can run config.sub.
1064 if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
1065 else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
1068 echo $ac_n "checking host system type""... $ac_c" 1>&6
1069 echo "configure:1070: checking host system type" >&5
1071 host_alias=$host
1072 case "$host_alias" in
1073 NONE)
1074 case $nonopt in
1075 NONE)
1076 if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
1077 else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
1078 fi ;;
1079 *) host_alias=$nonopt ;;
1080 esac ;;
1081 esac
1083 host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
1084 host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1085 host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1086 host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1087 echo "$ac_t""$host" 1>&6
1089 echo $ac_n "checking target system type""... $ac_c" 1>&6
1090 echo "configure:1091: checking target system type" >&5
1092 target_alias=$target
1093 case "$target_alias" in
1094 NONE)
1095 case $nonopt in
1096 NONE) target_alias=$host_alias ;;
1097 *) target_alias=$nonopt ;;
1098 esac ;;
1099 esac
1101 target=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $target_alias`
1102 target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1103 target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1104 target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1105 echo "$ac_t""$target" 1>&6
1107 echo $ac_n "checking build system type""... $ac_c" 1>&6
1108 echo "configure:1109: checking build system type" >&5
1110 build_alias=$build
1111 case "$build_alias" in
1112 NONE)
1113 case $nonopt in
1114 NONE) build_alias=$host_alias ;;
1115 *) build_alias=$nonopt ;;
1116 esac ;;
1117 esac
1119 build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias`
1120 build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1121 build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1122 build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1123 echo "$ac_t""$build" 1>&6
1125 test "$host_alias" != "$target_alias" &&
1126 test "$program_prefix$program_suffix$program_transform_name" = \
1127 NONENONEs,x,x, &&
1128 program_prefix=${target_alias}-
1134 # Extract the first word of "gcc", so it can be a program name with args.
1135 set dummy gcc; ac_word=$2
1136 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1137 echo "configure:1138: checking for $ac_word" >&5
1138 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
1139 echo $ac_n "(cached) $ac_c" 1>&6
1140 else
1141 if test -n "$CC"; then
1142 ac_cv_prog_CC="$CC" # Let the user override the test.
1143 else
1144 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1145 ac_dummy="$PATH"
1146 for ac_dir in $ac_dummy; do
1147 test -z "$ac_dir" && ac_dir=.
1148 if test -f $ac_dir/$ac_word; then
1149 ac_cv_prog_CC="gcc"
1150 break
1152 done
1153 IFS="$ac_save_ifs"
1156 CC="$ac_cv_prog_CC"
1157 if test -n "$CC"; then
1158 echo "$ac_t""$CC" 1>&6
1159 else
1160 echo "$ac_t""no" 1>&6
1163 if test -z "$CC"; then
1164 # Extract the first word of "cc", so it can be a program name with args.
1165 set dummy cc; ac_word=$2
1166 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1167 echo "configure:1168: checking for $ac_word" >&5
1168 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
1169 echo $ac_n "(cached) $ac_c" 1>&6
1170 else
1171 if test -n "$CC"; then
1172 ac_cv_prog_CC="$CC" # Let the user override the test.
1173 else
1174 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1175 ac_prog_rejected=no
1176 ac_dummy="$PATH"
1177 for ac_dir in $ac_dummy; do
1178 test -z "$ac_dir" && ac_dir=.
1179 if test -f $ac_dir/$ac_word; then
1180 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
1181 ac_prog_rejected=yes
1182 continue
1184 ac_cv_prog_CC="cc"
1185 break
1187 done
1188 IFS="$ac_save_ifs"
1189 if test $ac_prog_rejected = yes; then
1190 # We found a bogon in the path, so make sure we never use it.
1191 set dummy $ac_cv_prog_CC
1192 shift
1193 if test $# -gt 0; then
1194 # We chose a different compiler from the bogus one.
1195 # However, it has the same basename, so the bogon will be chosen
1196 # first if we set CC to just the basename; use the full file name.
1197 shift
1198 set dummy "$ac_dir/$ac_word" "$@"
1199 shift
1200 ac_cv_prog_CC="$@"
1205 CC="$ac_cv_prog_CC"
1206 if test -n "$CC"; then
1207 echo "$ac_t""$CC" 1>&6
1208 else
1209 echo "$ac_t""no" 1>&6
1212 if test -z "$CC"; then
1213 case "`uname -s`" in
1214 *win32* | *WIN32*)
1215 # Extract the first word of "cl", so it can be a program name with args.
1216 set dummy cl; ac_word=$2
1217 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1218 echo "configure:1219: checking for $ac_word" >&5
1219 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
1220 echo $ac_n "(cached) $ac_c" 1>&6
1221 else
1222 if test -n "$CC"; then
1223 ac_cv_prog_CC="$CC" # Let the user override the test.
1224 else
1225 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1226 ac_dummy="$PATH"
1227 for ac_dir in $ac_dummy; do
1228 test -z "$ac_dir" && ac_dir=.
1229 if test -f $ac_dir/$ac_word; then
1230 ac_cv_prog_CC="cl"
1231 break
1233 done
1234 IFS="$ac_save_ifs"
1237 CC="$ac_cv_prog_CC"
1238 if test -n "$CC"; then
1239 echo "$ac_t""$CC" 1>&6
1240 else
1241 echo "$ac_t""no" 1>&6
1244 esac
1246 test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
1250 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
1251 echo "configure:1252: checking whether we are using GNU C" >&5
1252 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
1253 echo $ac_n "(cached) $ac_c" 1>&6
1254 else
1255 cat > conftest.c <<EOF
1256 #ifdef __GNUC__
1257 yes;
1258 #endif
1260 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1261: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
1261 ac_cv_prog_gcc=yes
1262 else
1263 ac_cv_prog_gcc=no
1267 echo "$ac_t""$ac_cv_prog_gcc" 1>&6
1269 if test $ac_cv_prog_gcc = yes; then
1270 GCC=yes
1271 else
1272 GCC=
1275 ac_test_CFLAGS="${CFLAGS+set}"
1276 ac_save_CFLAGS="$CFLAGS"
1277 CFLAGS=
1278 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
1279 echo "configure:1280: checking whether ${CC-cc} accepts -g" >&5
1280 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
1281 echo $ac_n "(cached) $ac_c" 1>&6
1282 else
1283 echo 'void f(){}' > conftest.c
1284 if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
1285 ac_cv_prog_cc_g=yes
1286 else
1287 ac_cv_prog_cc_g=no
1289 rm -f conftest*
1293 echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
1294 if test "$ac_test_CFLAGS" = set; then
1295 CFLAGS="$ac_save_CFLAGS"
1296 elif test $ac_cv_prog_cc_g = yes; then
1297 if test "$GCC" = yes; then
1298 CFLAGS="-g -O2"
1299 else
1300 CFLAGS="-g"
1302 else
1303 if test "$GCC" = yes; then
1304 CFLAGS="-O2"
1305 else
1306 CFLAGS=
1311 # We use the libstdc++-v3 version of LIB_AC_PROG_CXX, but use
1312 # glibjava_CXX instead of glibcpp_CXX. That's because we're passed a
1313 # different definition of CXX than other directories, since we don't
1314 # depend on libstdc++-v3 having already been built.
1318 # Use glibjava_CXX so that we do not cause CXX to be cached with the
1319 # flags that come in CXX while configuring libjava. They're different
1320 # from those used for all other target libraries. If CXX is set in
1321 # the environment, respect that here.
1322 glibjava_CXX=$CXX
1323 for ac_prog in $CCC c++ g++ gcc CC cxx cc++
1325 # Extract the first word of "$ac_prog", so it can be a program name with args.
1326 set dummy $ac_prog; ac_word=$2
1327 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1328 echo "configure:1329: checking for $ac_word" >&5
1329 if eval "test \"`echo '$''{'ac_cv_prog_glibjava_CXX'+set}'`\" = set"; then
1330 echo $ac_n "(cached) $ac_c" 1>&6
1331 else
1332 if test -n "$glibjava_CXX"; then
1333 ac_cv_prog_glibjava_CXX="$glibjava_CXX" # Let the user override the test.
1334 else
1335 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1336 ac_dummy="$PATH"
1337 for ac_dir in $ac_dummy; do
1338 test -z "$ac_dir" && ac_dir=.
1339 if test -f $ac_dir/$ac_word; then
1340 ac_cv_prog_glibjava_CXX="$ac_prog"
1341 break
1343 done
1344 IFS="$ac_save_ifs"
1347 glibjava_CXX="$ac_cv_prog_glibjava_CXX"
1348 if test -n "$glibjava_CXX"; then
1349 echo "$ac_t""$glibjava_CXX" 1>&6
1350 else
1351 echo "$ac_t""no" 1>&6
1354 test -n "$glibjava_CXX" && break
1355 done
1356 test -n "$glibjava_CXX" || glibjava_CXX="gcc"
1359 CXX=$glibjava_CXX
1360 test -z "$glibjava_CXX" && { echo "configure: error: no acceptable c++ found in \$PATH" 1>&2; exit 1; }
1362 echo $ac_n "checking whether we are using GNU C++""... $ac_c" 1>&6
1363 echo "configure:1364: checking whether we are using GNU C++" >&5
1364 if eval "test \"`echo '$''{'ac_cv_prog_gxx'+set}'`\" = set"; then
1365 echo $ac_n "(cached) $ac_c" 1>&6
1366 else
1367 cat > conftest.C <<EOF
1368 #ifdef __GNUC__
1369 yes;
1370 #endif
1372 if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:1373: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
1373 ac_cv_prog_gxx=yes
1374 else
1375 ac_cv_prog_gxx=no
1379 echo "$ac_t""$ac_cv_prog_gxx" 1>&6
1381 if test "$ac_cv_prog_gxx" = yes; then
1382 GXX=yes
1383 ac_test_CXXFLAGS="${CXXFLAGS+set}"
1384 ac_save_CXXFLAGS="$CXXFLAGS"
1385 CXXFLAGS=
1386 echo $ac_n "checking whether ${CXX-g++} accepts -g""... $ac_c" 1>&6
1387 echo "configure:1388: checking whether ${CXX-g++} accepts -g" >&5
1388 if eval "test \"`echo '$''{'ac_cv_prog_cxx_g'+set}'`\" = set"; then
1389 echo $ac_n "(cached) $ac_c" 1>&6
1390 else
1391 echo 'void f(){}' > conftest.cc
1392 if test -z "`${CXX-g++} -g -c conftest.cc 2>&1`"; then
1393 ac_cv_prog_cxx_g=yes
1394 else
1395 ac_cv_prog_cxx_g=no
1397 rm -f conftest*
1401 echo "$ac_t""$ac_cv_prog_cxx_g" 1>&6
1402 if test "$ac_test_CXXFLAGS" = set; then
1403 CXXFLAGS="$ac_save_CXXFLAGS"
1404 elif test "$ac_cv_prog_cxx_g" = yes; then
1405 CXXFLAGS="-g -O2"
1406 else
1407 CXXFLAGS="-O2"
1409 else
1410 GXX=
1411 test "${CXXFLAGS+set}" = set || CXXFLAGS="-g"
1415 version=0.0.7
1416 # test to see if srcdir already configured
1417 if test "`CDPATH=:; cd $srcdir && pwd`" != "`pwd`" &&
1418 test -f $srcdir/config.status; then
1419 { echo "configure: error: source directory already configured; run \"make distclean\" there first" 1>&2; exit 1; }
1422 # Define the identity of the package.
1423 PACKAGE=libjava
1424 VERSION=$version
1425 cat >> confdefs.h <<EOF
1426 #define PACKAGE "$PACKAGE"
1429 cat >> confdefs.h <<EOF
1430 #define VERSION "$VERSION"
1434 # Autoconf 2.50 wants to disallow AM_ names. We explicitly allow
1435 # the ones we care about.
1437 # Autoconf 2.50 always computes EXEEXT. However we need to be
1438 # compatible with 2.13, for now. So we always define EXEEXT, but we
1439 # don't compute it.
1441 # Similar for OBJEXT -- only we only use OBJEXT if the user actually
1442 # requests that it be used. This is a bit dumb.
1443 : ${OBJEXT=o}
1446 # Some tools Automake needs.
1448 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal"}
1451 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
1454 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake"}
1457 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
1460 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
1463 AMTAR=${AMTAR-"${am_missing_run}tar"}
1465 install_sh=${install_sh-"$am_aux_dir/install-sh"}
1467 INSTALL_STRIP_PROGRAM="\${SHELL} \$(install_sh) -c -s"
1469 # We need awk for the "check" target. The system "awk" is bad on
1470 # some platforms.
1472 depcc="$CC" am_compiler_list=
1474 echo $ac_n "checking dependency style of $depcc""... $ac_c" 1>&6
1475 echo "configure:1476: checking dependency style of $depcc" >&5
1476 if eval "test \"`echo '$''{'am_cv_CC_dependencies_compiler_type'+set}'`\" = set"; then
1477 echo $ac_n "(cached) $ac_c" 1>&6
1478 else
1479 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
1480 # We make a subdir and do the tests there. Otherwise we can end up
1481 # making bogus files that we don't know about and never remove. For
1482 # instance it was reported that on HP-UX the gcc test will end up
1483 # making a dummy file named `D' -- because `-MD' means `put the output
1484 # in D'.
1485 mkdir conftest.dir
1486 # Copy depcomp to subdir because otherwise we won't find it if we're
1487 # using a relative directory.
1488 cp "$am_depcomp" conftest.dir
1489 cd conftest.dir
1491 am_cv_CC_dependencies_compiler_type=none
1492 if test "$am_compiler_list" = ""; then
1493 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
1495 for depmode in $am_compiler_list; do
1496 # We need to recreate these files for each test, as the compiler may
1497 # overwrite some of them when testing with obscure command lines.
1498 # This happens at least with the AIX C compiler.
1499 echo '#include "conftest.h"' > conftest.c
1500 echo 'int i;' > conftest.h
1501 echo "${am__include} ${am__quote}conftest.Po${am__quote}" > confmf
1503 case $depmode in
1504 nosideeffect)
1505 # after this tag, mechanisms are not by side-effect, so they'll
1506 # only be used when explicitly requested
1507 if test "x$enable_dependency_tracking" = xyes; then
1508 continue
1509 else
1510 break
1513 none) break ;;
1514 esac
1515 # We check with `-c' and `-o' for the sake of the "dashmstdout"
1516 # mode. It turns out that the SunPro C++ compiler does not properly
1517 # handle `-M -o', and we need to detect this.
1518 if depmode=$depmode \
1519 source=conftest.c object=conftest.o \
1520 depfile=conftest.Po tmpdepfile=conftest.TPo \
1521 $SHELL ./depcomp $depcc -c conftest.c -o conftest.o >/dev/null 2>&1 &&
1522 grep conftest.h conftest.Po > /dev/null 2>&1 &&
1523 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
1524 am_cv_CC_dependencies_compiler_type=$depmode
1525 break
1527 done
1529 cd ..
1530 rm -rf conftest.dir
1531 else
1532 am_cv_CC_dependencies_compiler_type=none
1537 echo "$ac_t""$am_cv_CC_dependencies_compiler_type" 1>&6
1538 CCDEPMODE="depmode=$am_cv_CC_dependencies_compiler_type"
1541 depcc="$CXX" am_compiler_list=
1543 echo $ac_n "checking dependency style of $depcc""... $ac_c" 1>&6
1544 echo "configure:1545: checking dependency style of $depcc" >&5
1545 if eval "test \"`echo '$''{'am_cv_CXX_dependencies_compiler_type'+set}'`\" = set"; then
1546 echo $ac_n "(cached) $ac_c" 1>&6
1547 else
1548 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
1549 # We make a subdir and do the tests there. Otherwise we can end up
1550 # making bogus files that we don't know about and never remove. For
1551 # instance it was reported that on HP-UX the gcc test will end up
1552 # making a dummy file named `D' -- because `-MD' means `put the output
1553 # in D'.
1554 mkdir conftest.dir
1555 # Copy depcomp to subdir because otherwise we won't find it if we're
1556 # using a relative directory.
1557 cp "$am_depcomp" conftest.dir
1558 cd conftest.dir
1560 am_cv_CXX_dependencies_compiler_type=none
1561 if test "$am_compiler_list" = ""; then
1562 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
1564 for depmode in $am_compiler_list; do
1565 # We need to recreate these files for each test, as the compiler may
1566 # overwrite some of them when testing with obscure command lines.
1567 # This happens at least with the AIX C compiler.
1568 echo '#include "conftest.h"' > conftest.c
1569 echo 'int i;' > conftest.h
1570 echo "${am__include} ${am__quote}conftest.Po${am__quote}" > confmf
1572 case $depmode in
1573 nosideeffect)
1574 # after this tag, mechanisms are not by side-effect, so they'll
1575 # only be used when explicitly requested
1576 if test "x$enable_dependency_tracking" = xyes; then
1577 continue
1578 else
1579 break
1582 none) break ;;
1583 esac
1584 # We check with `-c' and `-o' for the sake of the "dashmstdout"
1585 # mode. It turns out that the SunPro C++ compiler does not properly
1586 # handle `-M -o', and we need to detect this.
1587 if depmode=$depmode \
1588 source=conftest.c object=conftest.o \
1589 depfile=conftest.Po tmpdepfile=conftest.TPo \
1590 $SHELL ./depcomp $depcc -c conftest.c -o conftest.o >/dev/null 2>&1 &&
1591 grep conftest.h conftest.Po > /dev/null 2>&1 &&
1592 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
1593 am_cv_CXX_dependencies_compiler_type=$depmode
1594 break
1596 done
1598 cd ..
1599 rm -rf conftest.dir
1600 else
1601 am_cv_CXX_dependencies_compiler_type=none
1606 echo "$ac_t""$am_cv_CXX_dependencies_compiler_type" 1>&6
1607 CXXDEPMODE="depmode=$am_cv_CXX_dependencies_compiler_type"
1611 # AC_CHECK_TOOL does AC_REQUIRE (AC_CANONICAL_BUILD). If we don't
1612 # run it explicitly here, it will be run implicitly before
1613 # LIBGCJ_CONFIGURE, which doesn't work because that means that it will
1614 # be run before AC_CANONICAL_HOST.
1615 echo $ac_n "checking build system type""... $ac_c" 1>&6
1616 echo "configure:1617: checking build system type" >&5
1618 build_alias=$build
1619 case "$build_alias" in
1620 NONE)
1621 case $nonopt in
1622 NONE) build_alias=$host_alias ;;
1623 *) build_alias=$nonopt ;;
1624 esac ;;
1625 esac
1627 build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias`
1628 build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1629 build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1630 build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1631 echo "$ac_t""$build" 1>&6
1634 # Extract the first word of "${ac_tool_prefix}as", so it can be a program name with args.
1635 set dummy ${ac_tool_prefix}as; ac_word=$2
1636 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1637 echo "configure:1638: checking for $ac_word" >&5
1638 if eval "test \"`echo '$''{'ac_cv_prog_AS'+set}'`\" = set"; then
1639 echo $ac_n "(cached) $ac_c" 1>&6
1640 else
1641 if test -n "$AS"; then
1642 ac_cv_prog_AS="$AS" # Let the user override the test.
1643 else
1644 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1645 ac_dummy="$PATH"
1646 for ac_dir in $ac_dummy; do
1647 test -z "$ac_dir" && ac_dir=.
1648 if test -f $ac_dir/$ac_word; then
1649 ac_cv_prog_AS="${ac_tool_prefix}as"
1650 break
1652 done
1653 IFS="$ac_save_ifs"
1654 test -z "$ac_cv_prog_AS" && ac_cv_prog_AS="as"
1657 AS="$ac_cv_prog_AS"
1658 if test -n "$AS"; then
1659 echo "$ac_t""$AS" 1>&6
1660 else
1661 echo "$ac_t""no" 1>&6
1666 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
1667 set dummy ${ac_tool_prefix}ar; ac_word=$2
1668 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1669 echo "configure:1670: checking for $ac_word" >&5
1670 if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
1671 echo $ac_n "(cached) $ac_c" 1>&6
1672 else
1673 if test -n "$AR"; then
1674 ac_cv_prog_AR="$AR" # Let the user override the test.
1675 else
1676 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1677 ac_dummy="$PATH"
1678 for ac_dir in $ac_dummy; do
1679 test -z "$ac_dir" && ac_dir=.
1680 if test -f $ac_dir/$ac_word; then
1681 ac_cv_prog_AR="${ac_tool_prefix}ar"
1682 break
1684 done
1685 IFS="$ac_save_ifs"
1686 test -z "$ac_cv_prog_AR" && ac_cv_prog_AR="ar"
1689 AR="$ac_cv_prog_AR"
1690 if test -n "$AR"; then
1691 echo "$ac_t""$AR" 1>&6
1692 else
1693 echo "$ac_t""no" 1>&6
1698 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
1699 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
1700 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1701 echo "configure:1702: checking for $ac_word" >&5
1702 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
1703 echo $ac_n "(cached) $ac_c" 1>&6
1704 else
1705 if test -n "$RANLIB"; then
1706 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1707 else
1708 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1709 ac_dummy="$PATH"
1710 for ac_dir in $ac_dummy; do
1711 test -z "$ac_dir" && ac_dir=.
1712 if test -f $ac_dir/$ac_word; then
1713 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
1714 break
1716 done
1717 IFS="$ac_save_ifs"
1720 RANLIB="$ac_cv_prog_RANLIB"
1721 if test -n "$RANLIB"; then
1722 echo "$ac_t""$RANLIB" 1>&6
1723 else
1724 echo "$ac_t""no" 1>&6
1728 if test -z "$ac_cv_prog_RANLIB"; then
1729 if test -n "$ac_tool_prefix"; then
1730 # Extract the first word of "ranlib", so it can be a program name with args.
1731 set dummy ranlib; ac_word=$2
1732 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1733 echo "configure:1734: checking for $ac_word" >&5
1734 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
1735 echo $ac_n "(cached) $ac_c" 1>&6
1736 else
1737 if test -n "$RANLIB"; then
1738 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1739 else
1740 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1741 ac_dummy="$PATH"
1742 for ac_dir in $ac_dummy; do
1743 test -z "$ac_dir" && ac_dir=.
1744 if test -f $ac_dir/$ac_word; then
1745 ac_cv_prog_RANLIB="ranlib"
1746 break
1748 done
1749 IFS="$ac_save_ifs"
1750 test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
1753 RANLIB="$ac_cv_prog_RANLIB"
1754 if test -n "$RANLIB"; then
1755 echo "$ac_t""$RANLIB" 1>&6
1756 else
1757 echo "$ac_t""no" 1>&6
1760 else
1761 RANLIB=":"
1766 # Find a good install program. We prefer a C program (faster),
1767 # so one script is as good as another. But avoid the broken or
1768 # incompatible versions:
1769 # SysV /etc/install, /usr/sbin/install
1770 # SunOS /usr/etc/install
1771 # IRIX /sbin/install
1772 # AIX /bin/install
1773 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
1774 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
1775 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
1776 # ./install, which can be erroneously created by make from ./install.sh.
1777 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
1778 echo "configure:1779: checking for a BSD compatible install" >&5
1779 if test -z "$INSTALL"; then
1780 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
1781 echo $ac_n "(cached) $ac_c" 1>&6
1782 else
1783 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":"
1784 for ac_dir in $PATH; do
1785 # Account for people who put trailing slashes in PATH elements.
1786 case "$ac_dir/" in
1787 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
1789 # OSF1 and SCO ODT 3.0 have their own names for install.
1790 # Don't use installbsd from OSF since it installs stuff as root
1791 # by default.
1792 for ac_prog in ginstall scoinst install; do
1793 if test -f $ac_dir/$ac_prog; then
1794 if test $ac_prog = install &&
1795 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
1796 # AIX install. It has an incompatible calling convention.
1798 else
1799 ac_cv_path_install="$ac_dir/$ac_prog -c"
1800 break 2
1803 done
1805 esac
1806 done
1807 IFS="$ac_save_IFS"
1810 if test "${ac_cv_path_install+set}" = set; then
1811 INSTALL="$ac_cv_path_install"
1812 else
1813 # As a last resort, use the slow shell script. We don't cache a
1814 # path for INSTALL within a source directory, because that will
1815 # break other packages using the cache if that directory is
1816 # removed, or if the path is relative.
1817 INSTALL="$ac_install_sh"
1820 echo "$ac_t""$INSTALL" 1>&6
1822 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
1823 # It thinks the first close brace ends the variable substitution.
1824 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
1826 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
1828 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
1831 echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
1832 echo "configure:1833: checking whether to enable maintainer-specific portions of Makefiles" >&5
1833 # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
1834 if test "${enable_maintainer_mode+set}" = set; then
1835 enableval="$enable_maintainer_mode"
1836 USE_MAINTAINER_MODE=$enableval
1837 else
1838 USE_MAINTAINER_MODE=no
1841 echo "$ac_t""$USE_MAINTAINER_MODE" 1>&6
1844 if test $USE_MAINTAINER_MODE = yes; then
1845 MAINTAINER_MODE_TRUE=
1846 MAINTAINER_MODE_FALSE='#'
1847 else
1848 MAINTAINER_MODE_TRUE='#'
1849 MAINTAINER_MODE_FALSE=
1851 MAINT=$MAINTAINER_MODE_TRUE
1855 # We need AC_EXEEXT to keep automake happy in cygnus mode. However,
1856 # at least currently, we never actually build a program, so we never
1857 # need to use $(EXEEXT). Moreover, the test for EXEEXT normally
1858 # fails, because we are probably configuring with a cross compiler
1859 # which cant create executables. So we include AC_EXEEXT to keep
1860 # automake happy, but we don't execute it, since we don't care about
1861 # the result.
1862 if false; then
1863 # autoconf 2.50 runs AC_EXEEXT by default, and the macro expands
1864 # to nothing, so nothing would remain between `then' and `fi' if it
1865 # were not for the `:' below.
1869 echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
1870 echo "configure:1871: checking for executable suffix" >&5
1871 if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
1872 echo $ac_n "(cached) $ac_c" 1>&6
1873 else
1874 if test "$CYGWIN" = yes || test "$MINGW32" = yes; then
1875 ac_cv_exeext=.exe
1876 else
1877 rm -f conftest*
1878 echo 'int main () { return 0; }' > conftest.$ac_ext
1879 ac_cv_exeext=
1880 if { (eval echo configure:1881: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
1881 for file in conftest.*; do
1882 case $file in
1883 *.c | *.o | *.obj) ;;
1884 *) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
1885 esac
1886 done
1887 else
1888 { echo "configure: error: installation or configuration problem: compiler cannot create executables." 1>&2; exit 1; }
1890 rm -f conftest*
1891 test x"${ac_cv_exeext}" = x && ac_cv_exeext=no
1895 EXEEXT=""
1896 test x"${ac_cv_exeext}" != xno && EXEEXT=${ac_cv_exeext}
1897 echo "$ac_t""${ac_cv_exeext}" 1>&6
1898 ac_exeext=$EXEEXT
1902 # configure.host sets the following important variables
1903 # libgcj_cflags - host specific C compiler flags
1904 # libgcj_cxxflags - host specific C++ compiler flags
1905 # libgcj_javaflags - host specific Java compiler flags
1907 libgcj_cflags=
1908 libgcj_cxxflags=
1909 libgcj_javaflags=
1911 . ${srcdir}/configure.host
1913 LIBGCJ_CFLAGS="${libgcj_cflags}"
1914 LIBGCJ_CXXFLAGS="${libgcj_cxxflags}"
1915 LIBGCJ_JAVAFLAGS="${libgcj_javaflags}"
1925 # Only use libltdl for native builds.
1926 if test -z "${with_cross_host}"; then
1927 case $enable_ltdl_convenience in
1928 no) { echo "configure: error: this package needs a convenience libltdl" 1>&2; exit 1; } ;;
1929 "") enable_ltdl_convenience=yes
1930 ac_configure_args="$ac_configure_args --enable-ltdl-convenience" ;;
1931 esac
1932 LIBLTDL='${top_builddir}/''libltdl'/libltdlc.la
1933 INCLTDL='-I${top_srcdir}/''libltdl'
1936 DIRLTDL=libltdl
1937 cat >> confdefs.h <<\EOF
1938 #define USE_LTDL 1
1941 # Sigh. Libtool's macro doesn't do the right thing.
1942 INCLTDL="-I\$(top_srcdir)/libltdl $INCLTDL"
1943 # FIXME: this is a hack.
1944 sub_auxdir="`cd $ac_aux_dir && pwd`"
1945 ac_configure_args="$ac_configure_args --with-auxdir=$sub_auxdir"
1950 # Check whether --enable-shared or --disable-shared was given.
1951 if test "${enable_shared+set}" = set; then
1952 enableval="$enable_shared"
1953 p=${PACKAGE-default}
1954 case $enableval in
1955 yes) enable_shared=yes ;;
1956 no) enable_shared=no ;;
1958 enable_shared=no
1959 # Look at the argument we got. We use all the common list separators.
1960 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
1961 for pkg in $enableval; do
1962 if test "X$pkg" = "X$p"; then
1963 enable_shared=yes
1965 done
1966 IFS="$ac_save_ifs"
1968 esac
1969 else
1970 enable_shared=yes
1973 # Check whether --enable-static or --disable-static was given.
1974 if test "${enable_static+set}" = set; then
1975 enableval="$enable_static"
1976 p=${PACKAGE-default}
1977 case $enableval in
1978 yes) enable_static=yes ;;
1979 no) enable_static=no ;;
1981 enable_static=no
1982 # Look at the argument we got. We use all the common list separators.
1983 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
1984 for pkg in $enableval; do
1985 if test "X$pkg" = "X$p"; then
1986 enable_static=yes
1988 done
1989 IFS="$ac_save_ifs"
1991 esac
1992 else
1993 enable_static=yes
1996 # Check whether --enable-fast-install or --disable-fast-install was given.
1997 if test "${enable_fast_install+set}" = set; then
1998 enableval="$enable_fast_install"
1999 p=${PACKAGE-default}
2000 case $enableval in
2001 yes) enable_fast_install=yes ;;
2002 no) enable_fast_install=no ;;
2004 enable_fast_install=no
2005 # Look at the argument we got. We use all the common list separators.
2006 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
2007 for pkg in $enableval; do
2008 if test "X$pkg" = "X$p"; then
2009 enable_fast_install=yes
2011 done
2012 IFS="$ac_save_ifs"
2014 esac
2015 else
2016 enable_fast_install=yes
2019 # Check whether --with-gnu-ld or --without-gnu-ld was given.
2020 if test "${with_gnu_ld+set}" = set; then
2021 withval="$with_gnu_ld"
2022 test "$withval" = no || with_gnu_ld=yes
2023 else
2024 with_gnu_ld=no
2027 ac_prog=ld
2028 if test "$GCC" = yes; then
2029 # Check if gcc -print-prog-name=ld gives a path.
2030 echo $ac_n "checking for ld used by GCC""... $ac_c" 1>&6
2031 echo "configure:2032: checking for ld used by GCC" >&5
2032 case $host in
2033 *-*-mingw*)
2034 # gcc leaves a trailing carriage return which upsets mingw
2035 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
2037 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
2038 esac
2039 case $ac_prog in
2040 # Accept absolute paths.
2041 [\\/]* | [A-Za-z]:[\\/]*)
2042 re_direlt='/[^/][^/]*/\.\./'
2043 # Canonicalize the path of ld
2044 ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
2045 while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
2046 ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
2047 done
2048 test -z "$LD" && LD="$ac_prog"
2051 # If it fails, then pretend we aren't using GCC.
2052 ac_prog=ld
2055 # If it is relative, then search for the first ld in PATH.
2056 with_gnu_ld=unknown
2058 esac
2059 elif test "$with_gnu_ld" = yes; then
2060 echo $ac_n "checking for GNU ld""... $ac_c" 1>&6
2061 echo "configure:2062: checking for GNU ld" >&5
2062 else
2063 echo $ac_n "checking for non-GNU ld""... $ac_c" 1>&6
2064 echo "configure:2065: checking for non-GNU ld" >&5
2066 if eval "test \"`echo '$''{'lt_cv_path_LD'+set}'`\" = set"; then
2067 echo $ac_n "(cached) $ac_c" 1>&6
2068 else
2069 if test -z "$LD"; then
2070 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
2071 for ac_dir in $PATH; do
2072 test -z "$ac_dir" && ac_dir=.
2073 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
2074 lt_cv_path_LD="$ac_dir/$ac_prog"
2075 # Check to see if the program is GNU ld. I'd rather use --version,
2076 # but apparently some GNU ld's only accept -v.
2077 # Break only if it was the GNU/non-GNU ld that we prefer.
2078 if "$lt_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
2079 test "$with_gnu_ld" != no && break
2080 else
2081 test "$with_gnu_ld" != yes && break
2084 done
2085 IFS="$ac_save_ifs"
2086 else
2087 lt_cv_path_LD="$LD" # Let the user override the test with a path.
2091 LD="$lt_cv_path_LD"
2092 if test -n "$LD"; then
2093 echo "$ac_t""$LD" 1>&6
2094 else
2095 echo "$ac_t""no" 1>&6
2097 test -z "$LD" && { echo "configure: error: no acceptable ld found in \$PATH" 1>&2; exit 1; }
2098 echo $ac_n "checking if the linker ($LD) is GNU ld""... $ac_c" 1>&6
2099 echo "configure:2100: checking if the linker ($LD) is GNU ld" >&5
2100 if eval "test \"`echo '$''{'lt_cv_prog_gnu_ld'+set}'`\" = set"; then
2101 echo $ac_n "(cached) $ac_c" 1>&6
2102 else
2103 # I'd rather use --version here, but apparently some GNU ld's only accept -v.
2104 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
2105 lt_cv_prog_gnu_ld=yes
2106 else
2107 lt_cv_prog_gnu_ld=no
2111 echo "$ac_t""$lt_cv_prog_gnu_ld" 1>&6
2112 with_gnu_ld=$lt_cv_prog_gnu_ld
2115 echo $ac_n "checking for $LD option to reload object files""... $ac_c" 1>&6
2116 echo "configure:2117: checking for $LD option to reload object files" >&5
2117 if eval "test \"`echo '$''{'lt_cv_ld_reload_flag'+set}'`\" = set"; then
2118 echo $ac_n "(cached) $ac_c" 1>&6
2119 else
2120 lt_cv_ld_reload_flag='-r'
2123 echo "$ac_t""$lt_cv_ld_reload_flag" 1>&6
2124 reload_flag=$lt_cv_ld_reload_flag
2125 test -n "$reload_flag" && reload_flag=" $reload_flag"
2127 echo $ac_n "checking for BSD-compatible nm""... $ac_c" 1>&6
2128 echo "configure:2129: checking for BSD-compatible nm" >&5
2129 if eval "test \"`echo '$''{'lt_cv_path_NM'+set}'`\" = set"; then
2130 echo $ac_n "(cached) $ac_c" 1>&6
2131 else
2132 if test -n "$NM"; then
2133 # Let the user override the test.
2134 lt_cv_path_NM="$NM"
2135 else
2136 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
2137 for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do
2138 test -z "$ac_dir" && ac_dir=.
2139 tmp_nm=$ac_dir/${ac_tool_prefix}nm
2140 if test -f $tmp_nm || test -f $tmp_nm$ac_exeext ; then
2141 # Check to see if the nm accepts a BSD-compat flag.
2142 # Adding the `sed 1q' prevents false positives on HP-UX, which says:
2143 # nm: unknown option "B" ignored
2144 # Tru64's nm complains that /dev/null is an invalid object file
2145 if ($tmp_nm -B /dev/null 2>&1 | sed '1q'; exit 0) | egrep '(/dev/null|Invalid file or object type)' >/dev/null; then
2146 lt_cv_path_NM="$tmp_nm -B"
2147 break
2148 elif ($tmp_nm -p /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then
2149 lt_cv_path_NM="$tmp_nm -p"
2150 break
2151 else
2152 lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
2153 continue # so that we can try to find one that supports BSD flags
2156 done
2157 IFS="$ac_save_ifs"
2158 test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
2162 NM="$lt_cv_path_NM"
2163 echo "$ac_t""$NM" 1>&6
2165 echo $ac_n "checking how to recognise dependant libraries""... $ac_c" 1>&6
2166 echo "configure:2167: checking how to recognise dependant libraries" >&5
2167 if eval "test \"`echo '$''{'lt_cv_deplibs_check_method'+set}'`\" = set"; then
2168 echo $ac_n "(cached) $ac_c" 1>&6
2169 else
2170 lt_cv_file_magic_cmd='$MAGIC_CMD'
2171 lt_cv_file_magic_test_file=
2172 lt_cv_deplibs_check_method='unknown'
2173 # Need to set the preceding variable on all platforms that support
2174 # interlibrary dependencies.
2175 # 'none' -- dependencies not supported.
2176 # `unknown' -- same as none, but documents that we really don't know.
2177 # 'pass_all' -- all dependencies passed with no checks.
2178 # 'test_compile' -- check by making test program.
2179 # 'file_magic [regex]' -- check by looking for files in library path
2180 # which responds to the $file_magic_cmd with a given egrep regex.
2181 # If you have `file' or equivalent on your system and you're not sure
2182 # whether `pass_all' will *always* work, you probably want this one.
2184 case $host_os in
2185 aix*)
2186 lt_cv_deplibs_check_method=pass_all
2189 beos*)
2190 lt_cv_deplibs_check_method=pass_all
2193 bsdi4*)
2194 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
2195 lt_cv_file_magic_cmd='/usr/bin/file -L'
2196 lt_cv_file_magic_test_file=/shlib/libc.so
2199 cygwin* | mingw* |pw32*)
2200 lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
2201 lt_cv_file_magic_cmd='$OBJDUMP -f'
2204 darwin* | rhapsody*)
2205 lt_cv_deplibs_check_method='file_magic Mach-O dynamically linked shared library'
2206 lt_cv_file_magic_cmd='/usr/bin/file -L'
2207 case "$host_os" in
2208 rhapsody* | darwin1.012)
2209 lt_cv_file_magic_test_file='/System/Library/Frameworks/System.framework/System'
2211 *) # Darwin 1.3 on
2212 lt_cv_file_magic_test_file='/usr/lib/libSystem.dylib'
2214 esac
2217 freebsd* )
2218 if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
2219 case $host_cpu in
2220 i*86 )
2221 # Not sure whether the presence of OpenBSD here was a mistake.
2222 # Let's accept both of them until this is cleared up.
2223 lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD)/i[3-9]86 (compact )?demand paged shared library'
2224 lt_cv_file_magic_cmd=/usr/bin/file
2225 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
2227 esac
2228 else
2229 lt_cv_deplibs_check_method=pass_all
2233 gnu*)
2234 lt_cv_deplibs_check_method=pass_all
2237 hpux10.20*|hpux11*)
2238 lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9].[0-9]) shared library'
2239 lt_cv_file_magic_cmd=/usr/bin/file
2240 lt_cv_file_magic_test_file=/usr/lib/libc.sl
2243 irix5* | irix6*)
2244 case $host_os in
2245 irix5*)
2246 # this will be overridden with pass_all, but let us keep it just in case
2247 lt_cv_deplibs_check_method="file_magic ELF 32-bit MSB dynamic lib MIPS - version 1"
2250 case $LD in
2251 *-32|*"-32 ") libmagic=32-bit;;
2252 *-n32|*"-n32 ") libmagic=N32;;
2253 *-64|*"-64 ") libmagic=64-bit;;
2254 *) libmagic=never-match;;
2255 esac
2256 # this will be overridden with pass_all, but let us keep it just in case
2257 lt_cv_deplibs_check_method="file_magic ELF ${libmagic} MSB mips-[1234] dynamic lib MIPS - version 1"
2259 esac
2260 lt_cv_file_magic_test_file=`echo /lib${libsuff}/libc.so*`
2261 lt_cv_deplibs_check_method=pass_all
2264 # This must be Linux ELF.
2265 linux-gnu*)
2266 case $host_cpu in
2267 alpha* | hppa* | i*86 | powerpc* | sparc* | ia64* )
2268 lt_cv_deplibs_check_method=pass_all ;;
2270 # glibc up to 2.1.1 does not perform some relocations on ARM
2271 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' ;;
2272 esac
2273 lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so`
2276 netbsd*)
2277 if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
2278 lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$'
2279 else
2280 lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so$'
2284 newsos6)
2285 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
2286 lt_cv_file_magic_cmd=/usr/bin/file
2287 lt_cv_file_magic_test_file=/usr/lib/libnls.so
2290 osf3* | osf4* | osf5*)
2291 # this will be overridden with pass_all, but let us keep it just in case
2292 lt_cv_deplibs_check_method='file_magic COFF format alpha shared library'
2293 lt_cv_file_magic_test_file=/shlib/libc.so
2294 lt_cv_deplibs_check_method=pass_all
2297 sco3.2v5*)
2298 lt_cv_deplibs_check_method=pass_all
2301 solaris*)
2302 lt_cv_deplibs_check_method=pass_all
2303 lt_cv_file_magic_test_file=/lib/libc.so
2306 sysv5uw[78]* | sysv4*uw2*)
2307 lt_cv_deplibs_check_method=pass_all
2310 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
2311 case $host_vendor in
2312 ncr)
2313 lt_cv_deplibs_check_method=pass_all
2315 motorola)
2316 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]'
2317 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
2319 esac
2321 esac
2325 echo "$ac_t""$lt_cv_deplibs_check_method" 1>&6
2326 file_magic_cmd=$lt_cv_file_magic_cmd
2327 deplibs_check_method=$lt_cv_deplibs_check_method
2329 echo $ac_n "checking for object suffix""... $ac_c" 1>&6
2330 echo "configure:2331: checking for object suffix" >&5
2331 if eval "test \"`echo '$''{'ac_cv_objext'+set}'`\" = set"; then
2332 echo $ac_n "(cached) $ac_c" 1>&6
2333 else
2334 rm -f conftest*
2335 echo 'int i = 1;' > conftest.$ac_ext
2336 if { (eval echo configure:2337: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2337 for ac_file in conftest.*; do
2338 case $ac_file in
2339 *.c) ;;
2340 *) ac_cv_objext=`echo $ac_file | sed -e s/conftest.//` ;;
2341 esac
2342 done
2343 else
2344 { echo "configure: error: installation or configuration problem; compiler does not work" 1>&2; exit 1; }
2346 rm -f conftest*
2349 echo "$ac_t""$ac_cv_objext" 1>&6
2350 OBJEXT=$ac_cv_objext
2351 ac_objext=$ac_cv_objext
2353 # Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers!
2355 # Only perform the check for file, if the check method requires it
2356 case $deplibs_check_method in
2357 file_magic*)
2358 if test "$file_magic_cmd" = '$MAGIC_CMD'; then
2359 echo $ac_n "checking for ${ac_tool_prefix}file""... $ac_c" 1>&6
2360 echo "configure:2361: checking for ${ac_tool_prefix}file" >&5
2361 if eval "test \"`echo '$''{'lt_cv_path_MAGIC_CMD'+set}'`\" = set"; then
2362 echo $ac_n "(cached) $ac_c" 1>&6
2363 else
2364 case $MAGIC_CMD in
2366 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
2368 ?:/*)
2369 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a dos path.
2372 ac_save_MAGIC_CMD="$MAGIC_CMD"
2373 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2374 ac_dummy="/usr/bin:$PATH"
2375 for ac_dir in $ac_dummy; do
2376 test -z "$ac_dir" && ac_dir=.
2377 if test -f $ac_dir/${ac_tool_prefix}file; then
2378 lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file"
2379 if test -n "$file_magic_test_file"; then
2380 case $deplibs_check_method in
2381 "file_magic "*)
2382 file_magic_regex="`expr \"$deplibs_check_method\" : \"file_magic \(.*\)\"`"
2383 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
2384 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
2385 egrep "$file_magic_regex" > /dev/null; then
2387 else
2388 cat <<EOF 1>&2
2390 *** Warning: the command libtool uses to detect shared libraries,
2391 *** $file_magic_cmd, produces output that libtool cannot recognize.
2392 *** The result is that libtool may fail to recognize shared libraries
2393 *** as such. This will affect the creation of libtool libraries that
2394 *** depend on shared libraries, but programs linked with such libtool
2395 *** libraries will work regardless of this problem. Nevertheless, you
2396 *** may want to report the problem to your system manager and/or to
2397 *** bug-libtool@gnu.org
2400 fi ;;
2401 esac
2403 break
2405 done
2406 IFS="$ac_save_ifs"
2407 MAGIC_CMD="$ac_save_MAGIC_CMD"
2409 esac
2412 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
2413 if test -n "$MAGIC_CMD"; then
2414 echo "$ac_t""$MAGIC_CMD" 1>&6
2415 else
2416 echo "$ac_t""no" 1>&6
2419 if test -z "$lt_cv_path_MAGIC_CMD"; then
2420 if test -n "$ac_tool_prefix"; then
2421 echo $ac_n "checking for file""... $ac_c" 1>&6
2422 echo "configure:2423: checking for file" >&5
2423 if eval "test \"`echo '$''{'lt_cv_path_MAGIC_CMD'+set}'`\" = set"; then
2424 echo $ac_n "(cached) $ac_c" 1>&6
2425 else
2426 case $MAGIC_CMD in
2428 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
2430 ?:/*)
2431 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a dos path.
2434 ac_save_MAGIC_CMD="$MAGIC_CMD"
2435 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2436 ac_dummy="/usr/bin:$PATH"
2437 for ac_dir in $ac_dummy; do
2438 test -z "$ac_dir" && ac_dir=.
2439 if test -f $ac_dir/file; then
2440 lt_cv_path_MAGIC_CMD="$ac_dir/file"
2441 if test -n "$file_magic_test_file"; then
2442 case $deplibs_check_method in
2443 "file_magic "*)
2444 file_magic_regex="`expr \"$deplibs_check_method\" : \"file_magic \(.*\)\"`"
2445 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
2446 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
2447 egrep "$file_magic_regex" > /dev/null; then
2449 else
2450 cat <<EOF 1>&2
2452 *** Warning: the command libtool uses to detect shared libraries,
2453 *** $file_magic_cmd, produces output that libtool cannot recognize.
2454 *** The result is that libtool may fail to recognize shared libraries
2455 *** as such. This will affect the creation of libtool libraries that
2456 *** depend on shared libraries, but programs linked with such libtool
2457 *** libraries will work regardless of this problem. Nevertheless, you
2458 *** may want to report the problem to your system manager and/or to
2459 *** bug-libtool@gnu.org
2462 fi ;;
2463 esac
2465 break
2467 done
2468 IFS="$ac_save_ifs"
2469 MAGIC_CMD="$ac_save_MAGIC_CMD"
2471 esac
2474 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
2475 if test -n "$MAGIC_CMD"; then
2476 echo "$ac_t""$MAGIC_CMD" 1>&6
2477 else
2478 echo "$ac_t""no" 1>&6
2481 else
2482 MAGIC_CMD=:
2488 esac
2490 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
2491 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
2492 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2493 echo "configure:2494: checking for $ac_word" >&5
2494 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
2495 echo $ac_n "(cached) $ac_c" 1>&6
2496 else
2497 if test -n "$RANLIB"; then
2498 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
2499 else
2500 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2501 ac_dummy="$PATH"
2502 for ac_dir in $ac_dummy; do
2503 test -z "$ac_dir" && ac_dir=.
2504 if test -f $ac_dir/$ac_word; then
2505 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
2506 break
2508 done
2509 IFS="$ac_save_ifs"
2512 RANLIB="$ac_cv_prog_RANLIB"
2513 if test -n "$RANLIB"; then
2514 echo "$ac_t""$RANLIB" 1>&6
2515 else
2516 echo "$ac_t""no" 1>&6
2520 if test -z "$ac_cv_prog_RANLIB"; then
2521 if test -n "$ac_tool_prefix"; then
2522 # Extract the first word of "ranlib", so it can be a program name with args.
2523 set dummy ranlib; ac_word=$2
2524 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2525 echo "configure:2526: checking for $ac_word" >&5
2526 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
2527 echo $ac_n "(cached) $ac_c" 1>&6
2528 else
2529 if test -n "$RANLIB"; then
2530 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
2531 else
2532 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2533 ac_dummy="$PATH"
2534 for ac_dir in $ac_dummy; do
2535 test -z "$ac_dir" && ac_dir=.
2536 if test -f $ac_dir/$ac_word; then
2537 ac_cv_prog_RANLIB="ranlib"
2538 break
2540 done
2541 IFS="$ac_save_ifs"
2542 test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
2545 RANLIB="$ac_cv_prog_RANLIB"
2546 if test -n "$RANLIB"; then
2547 echo "$ac_t""$RANLIB" 1>&6
2548 else
2549 echo "$ac_t""no" 1>&6
2552 else
2553 RANLIB=":"
2557 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
2558 set dummy ${ac_tool_prefix}strip; ac_word=$2
2559 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2560 echo "configure:2561: checking for $ac_word" >&5
2561 if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
2562 echo $ac_n "(cached) $ac_c" 1>&6
2563 else
2564 if test -n "$STRIP"; then
2565 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
2566 else
2567 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2568 ac_dummy="$PATH"
2569 for ac_dir in $ac_dummy; do
2570 test -z "$ac_dir" && ac_dir=.
2571 if test -f $ac_dir/$ac_word; then
2572 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
2573 break
2575 done
2576 IFS="$ac_save_ifs"
2579 STRIP="$ac_cv_prog_STRIP"
2580 if test -n "$STRIP"; then
2581 echo "$ac_t""$STRIP" 1>&6
2582 else
2583 echo "$ac_t""no" 1>&6
2587 if test -z "$ac_cv_prog_STRIP"; then
2588 if test -n "$ac_tool_prefix"; then
2589 # Extract the first word of "strip", so it can be a program name with args.
2590 set dummy strip; ac_word=$2
2591 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2592 echo "configure:2593: checking for $ac_word" >&5
2593 if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
2594 echo $ac_n "(cached) $ac_c" 1>&6
2595 else
2596 if test -n "$STRIP"; then
2597 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
2598 else
2599 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2600 ac_dummy="$PATH"
2601 for ac_dir in $ac_dummy; do
2602 test -z "$ac_dir" && ac_dir=.
2603 if test -f $ac_dir/$ac_word; then
2604 ac_cv_prog_STRIP="strip"
2605 break
2607 done
2608 IFS="$ac_save_ifs"
2609 test -z "$ac_cv_prog_STRIP" && ac_cv_prog_STRIP=":"
2612 STRIP="$ac_cv_prog_STRIP"
2613 if test -n "$STRIP"; then
2614 echo "$ac_t""$STRIP" 1>&6
2615 else
2616 echo "$ac_t""no" 1>&6
2619 else
2620 STRIP=":"
2625 # Check for any special flags to pass to ltconfig.
2626 libtool_flags="--cache-file=$cache_file"
2627 test "$enable_shared" = no && libtool_flags="$libtool_flags --disable-shared"
2628 test "$enable_static" = no && libtool_flags="$libtool_flags --disable-static"
2629 test "$enable_fast_install" = no && libtool_flags="$libtool_flags --disable-fast-install"
2630 test "$GCC" = yes && libtool_flags="$libtool_flags --with-gcc"
2631 test "$lt_cv_prog_gnu_ld" = yes && libtool_flags="$libtool_flags --with-gnu-ld"
2632 libtool_flags="$libtool_flags --enable-dlopen"
2634 # Check whether --enable-libtool-lock or --disable-libtool-lock was given.
2635 if test "${enable_libtool_lock+set}" = set; then
2636 enableval="$enable_libtool_lock"
2640 test "x$enable_libtool_lock" = xno && libtool_flags="$libtool_flags --disable-lock"
2641 test x"$silent" = xyes && libtool_flags="$libtool_flags --silent"
2643 # Check whether --with-pic or --without-pic was given.
2644 if test "${with_pic+set}" = set; then
2645 withval="$with_pic"
2646 pic_mode="$withval"
2647 else
2648 pic_mode=default
2651 test x"$pic_mode" = xyes && libtool_flags="$libtool_flags --prefer-pic"
2652 test x"$pic_mode" = xno && libtool_flags="$libtool_flags --prefer-non-pic"
2654 # Some flags need to be propagated to the compiler or linker for good
2655 # libtool support.
2656 case $host in
2657 *-*-irix6*)
2658 # Find out which ABI we are using.
2659 echo '#line 2660 "configure"' > conftest.$ac_ext
2660 if { (eval echo configure:2661: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2661 case `/usr/bin/file conftest.$ac_objext` in
2662 *32-bit*)
2663 LD="${LD-ld} -32"
2665 *N32*)
2666 LD="${LD-ld} -n32"
2668 *64-bit*)
2669 LD="${LD-ld} -64"
2671 esac
2673 rm -rf conftest*
2676 *-*-sco3.2v5*)
2677 # On SCO OpenServer 5, we need -belf to get full-featured binaries.
2678 SAVE_CFLAGS="$CFLAGS"
2679 CFLAGS="$CFLAGS -belf"
2680 echo $ac_n "checking whether the C compiler needs -belf""... $ac_c" 1>&6
2681 echo "configure:2682: checking whether the C compiler needs -belf" >&5
2682 if eval "test \"`echo '$''{'lt_cv_cc_needs_belf'+set}'`\" = set"; then
2683 echo $ac_n "(cached) $ac_c" 1>&6
2684 else
2686 ac_ext=c
2687 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2688 ac_cpp='$CPP $CPPFLAGS'
2689 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2690 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2691 cross_compiling=$ac_cv_prog_cc_cross
2693 cat > conftest.$ac_ext <<EOF
2694 #line 2695 "configure"
2695 #include "confdefs.h"
2697 int main() {
2699 ; return 0; }
2701 if { (eval echo configure:2702: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2702 rm -rf conftest*
2703 lt_cv_cc_needs_belf=yes
2704 else
2705 echo "configure: failed program was:" >&5
2706 cat conftest.$ac_ext >&5
2707 rm -rf conftest*
2708 lt_cv_cc_needs_belf=no
2710 rm -f conftest*
2711 ac_ext=c
2712 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2713 ac_cpp='$CPP $CPPFLAGS'
2714 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2715 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2716 cross_compiling=$ac_cv_prog_cc_cross
2720 echo "$ac_t""$lt_cv_cc_needs_belf" 1>&6
2721 if test x"$lt_cv_cc_needs_belf" != x"yes"; then
2722 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
2723 CFLAGS="$SAVE_CFLAGS"
2728 esac
2730 echo $ac_n "checking how to run the C++ preprocessor""... $ac_c" 1>&6
2731 echo "configure:2732: checking how to run the C++ preprocessor" >&5
2732 if test -z "$CXXCPP"; then
2733 if eval "test \"`echo '$''{'ac_cv_prog_CXXCPP'+set}'`\" = set"; then
2734 echo $ac_n "(cached) $ac_c" 1>&6
2735 else
2736 ac_ext=C
2737 # CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2738 ac_cpp='$CXXCPP $CPPFLAGS'
2739 ac_compile='${CXX-g++} -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2740 ac_link='${CXX-g++} -o conftest${ac_exeext} $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2741 cross_compiling=$ac_cv_prog_cxx_cross
2742 CXXCPP="${CXX-g++} -E"
2743 cat > conftest.$ac_ext <<EOF
2744 #line 2745 "configure"
2745 #include "confdefs.h"
2746 #include <stdlib.h>
2748 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2749 { (eval echo configure:2750: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2750 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2751 if test -z "$ac_err"; then
2753 else
2754 echo "$ac_err" >&5
2755 echo "configure: failed program was:" >&5
2756 cat conftest.$ac_ext >&5
2757 rm -rf conftest*
2758 CXXCPP=/lib/cpp
2760 rm -f conftest*
2761 ac_cv_prog_CXXCPP="$CXXCPP"
2762 ac_ext=c
2763 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2764 ac_cpp='$CPP $CPPFLAGS'
2765 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2766 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2767 cross_compiling=$ac_cv_prog_cc_cross
2770 CXXCPP="$ac_cv_prog_CXXCPP"
2771 echo "$ac_t""$CXXCPP" 1>&6
2774 # Save cache, so that ltconfig can load it
2775 cat > confcache <<\EOF
2776 # This file is a shell script that caches the results of configure
2777 # tests run on this system so they can be shared between configure
2778 # scripts and configure runs. It is not useful on other systems.
2779 # If it contains results you don't want to keep, you may remove or edit it.
2781 # By default, configure uses ./config.cache as the cache file,
2782 # creating it if it does not exist already. You can give configure
2783 # the --cache-file=FILE option to use a different cache file; that is
2784 # what configure does when it calls configure scripts in
2785 # subdirectories, so they share the cache.
2786 # Giving --cache-file=/dev/null disables caching, for debugging configure.
2787 # config.status only pays attention to the cache file if you give it the
2788 # --recheck option to rerun configure.
2791 # The following way of writing the cache mishandles newlines in values,
2792 # but we know of no workaround that is simple, portable, and efficient.
2793 # So, don't put newlines in cache variables' values.
2794 # Ultrix sh set writes to stderr and can't be redirected directly,
2795 # and sets the high bit in the cache file unless we assign to the vars.
2796 (set) 2>&1 |
2797 case `(ac_space=' '; set | grep ac_space) 2>&1` in
2798 *ac_space=\ *)
2799 # `set' does not quote correctly, so add quotes (double-quote substitution
2800 # turns \\\\ into \\, and sed turns \\ into \).
2801 sed -n \
2802 -e "s/'/'\\\\''/g" \
2803 -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
2806 # `set' quotes correctly as required by POSIX, so do not add quotes.
2807 sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
2809 esac >> confcache
2810 if cmp -s $cache_file confcache; then
2812 else
2813 if test -w $cache_file; then
2814 echo "updating cache $cache_file"
2815 cat confcache > $cache_file
2816 else
2817 echo "not updating unwritable cache $cache_file"
2820 rm -f confcache
2823 # Actually configure libtool. ac_aux_dir is where install-sh is found.
2824 AR="$AR" LTCC="$CC" CC="$CC" CFLAGS="$CFLAGS" CPPFLAGS="$CPPFLAGS" \
2825 MAGIC_CMD="$MAGIC_CMD" LD="$LD" LDFLAGS="$LDFLAGS" LIBS="$LIBS" \
2826 LN_S="$LN_S" NM="$NM" RANLIB="$RANLIB" STRIP="$STRIP" \
2827 AS="$AS" DLLTOOL="$DLLTOOL" OBJDUMP="$OBJDUMP" \
2828 objext="$OBJEXT" exeext="$EXEEXT" reload_flag="$reload_flag" \
2829 deplibs_check_method="$deplibs_check_method" file_magic_cmd="$file_magic_cmd" \
2830 ${CONFIG_SHELL-/bin/sh} $ac_aux_dir/ltconfig --no-reexec \
2831 $libtool_flags --no-verify --build="$build" $ac_aux_dir/ltmain.sh $host \
2832 || { echo "configure: error: libtool configure failed" 1>&2; exit 1; }
2834 # Reload cache, that may have been modified by ltconfig
2835 if test -r "$cache_file"; then
2836 echo "loading cache $cache_file"
2837 . $cache_file
2838 else
2839 echo "creating cache $cache_file"
2840 > $cache_file
2844 # This can be used to rebuild libtool when needed
2845 LIBTOOL_DEPS="$ac_aux_dir/ltconfig $ac_aux_dir/ltmain.sh $ac_aux_dir/ltcf-c.sh"
2847 # Always use our own libtool.
2848 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
2850 # Redirect the config.log output again, so that the ltconfig log is not
2851 # clobbered by the next message.
2852 exec 5>>./config.log
2856 LIBTOOL_DEPS=$LIBTOOL_DEPS" $ac_aux_dir/ltcf-cxx.sh"
2857 lt_save_CC="$CC"
2858 lt_save_CFLAGS="$CFLAGS"
2859 AR="$AR" LTCC="$CC" CC="$CXX" CXX="$CXX" CFLAGS="$CXXFLAGS" CPPFLAGS="$CPPFLAGS" \
2860 MAGIC_CMD="$MAGIC_CMD" LD="$LD" LDFLAGS="$LDFLAGS" LIBS="$LIBS" \
2861 LN_S="$LN_S" NM="$NM" RANLIB="$RANLIB" STRIP="$STRIP" \
2862 AS="$AS" DLLTOOL="$DLLTOOL" OBJDUMP="$OBJDUMP" \
2863 objext="$OBJEXT" exeext="$EXEEXT" reload_flag="$reload_flag" \
2864 deplibs_check_method="$deplibs_check_method" \
2865 file_magic_cmd="$file_magic_cmd" \
2866 ${CONFIG_SHELL-/bin/sh} $ac_aux_dir/ltconfig -o libtool $libtool_flags \
2867 --build="$build" --add-tag=CXX $ac_aux_dir/ltcf-cxx.sh $host \
2868 || { echo "configure: error: libtool tag configuration failed" 1>&2; exit 1; }
2869 CC="$lt_save_CC"
2870 CFLAGS="$lt_save_CFLAGS"
2872 # Redirect the config.log output again, so that the ltconfig log is not
2873 # clobbered by the next message.
2874 exec 5>>./config.log
2881 subdirs="$DIRLTDL"
2884 if test -z "$with_target_subdir" || test "$with_target_subdir" = "."; then
2885 COMPPATH=.
2886 else
2887 COMPPATH=..
2893 if test -d $srcdir/testsuite; then
2894 TESTSUBDIR_TRUE=
2895 TESTSUBDIR_FALSE='#'
2896 else
2897 TESTSUBDIR_TRUE='#'
2898 TESTSUBDIR_FALSE=
2901 # Check whether --enable-getenv-properties or --disable-getenv-properties was given.
2902 if test "${enable_getenv_properties+set}" = set; then
2903 enableval="$enable_getenv_properties"
2908 if test -z "$enable_getenv_properties"; then
2909 enable_getenv_properties=${enable_getenv_properties_default-yes}
2911 if test "$enable_getenv_properties" = no; then
2912 cat >> confdefs.h <<\EOF
2913 #define DISABLE_GETENV_PROPERTIES 1
2918 if test -z "$enable_main_args"; then
2919 enable_main_args=${enable_main_args_default-yes}
2921 if test "$enable_main_args" = no; then
2922 cat >> confdefs.h <<\EOF
2923 #define DISABLE_MAIN_ARGS 1
2929 # Check whether --enable-hash-synchronization or --disable-hash-synchronization was given.
2930 if test "${enable_hash_synchronization+set}" = set; then
2931 enableval="$enable_hash_synchronization"
2936 if test -z "$enable_hash_synchronization"; then
2937 enable_hash_synchronization=$enable_hash_synchronization_default
2940 if test "${slow_pthread_self}" = "yes"; then
2941 cat >> confdefs.h <<\EOF
2942 #define SLOW_PTHREAD_SELF 1
2948 LIBGCJDEBUG="false"
2950 # Check whether --enable-libgcj-debug or --disable-libgcj-debug was given.
2951 if test "${enable_libgcj_debug+set}" = set; then
2952 enableval="$enable_libgcj_debug"
2953 if test "$enable_libgcj_debug" = yes; then
2954 cat >> confdefs.h <<\EOF
2955 #define DEBUG 1
2958 LIBGCJDEBUG="true"
2963 # Check whether --enable-interpreter or --disable-interpreter was given.
2964 if test "${enable_interpreter+set}" = set; then
2965 enableval="$enable_interpreter"
2966 if test "$enable_interpreter" = yes; then
2967 # This can also be set in configure.host.
2968 libgcj_interpreter=yes
2969 elif test "$enable_interpreter" = no; then
2970 libgcj_interpreter=no
2975 if test "$libgcj_interpreter" = yes; then
2976 cat >> confdefs.h <<\EOF
2977 #define INTERPRETER 1
2982 echo $ac_n "checking for exception model to use""... $ac_c" 1>&6
2983 echo "configure:2984: checking for exception model to use" >&5
2985 ac_ext=C
2986 # CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2987 ac_cpp='$CXXCPP $CPPFLAGS'
2988 ac_compile='${CXX-g++} -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2989 ac_link='${CXX-g++} -o conftest${ac_exeext} $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2990 cross_compiling=$ac_cv_prog_cxx_cross
2992 # Check whether --enable-sjlj-exceptions or --disable-sjlj-exceptions was given.
2993 if test "${enable_sjlj_exceptions+set}" = set; then
2994 enableval="$enable_sjlj_exceptions"
2996 else
2997 cat > conftest.$ac_ext << EOF
2998 #line 2999 "configure"
2999 struct S { ~S(); };
3000 void bar();
3001 void foo()
3003 S s;
3004 bar();
3007 old_CXXFLAGS="$CXXFLAGS"
3008 CXXFLAGS=-S
3009 if { (eval echo configure:3010: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3010 if grep _Unwind_SjLj_Resume conftest.s >/dev/null 2>&1 ; then
3011 enable_sjlj_exceptions=yes
3012 elif grep _Unwind_Resume conftest.s >/dev/null 2>&1 ; then
3013 enable_sjlj_exceptions=no
3016 CXXFLAGS="$old_CXXFLAGS"
3017 rm -f conftest*
3020 if test x$enable_sjlj_exceptions = xyes; then
3021 cat >> confdefs.h <<\EOF
3022 #define SJLJ_EXCEPTIONS 1
3025 ac_exception_model_name=sjlj
3026 elif test x$enable_sjlj_exceptions = xno; then
3027 ac_exception_model_name="call frame"
3028 else
3029 { echo "configure: error: unable to detect exception model" 1>&2; exit 1; }
3031 ac_ext=c
3032 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
3033 ac_cpp='$CPP $CPPFLAGS'
3034 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
3035 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
3036 cross_compiling=$ac_cv_prog_cc_cross
3038 echo "$ac_t""$ac_exception_model_name" 1>&6
3040 # If we are non using SJLJ exceptions, and this host does not have support
3041 # for unwinding from a signal handler, enable checked dereferences and divides.
3042 if test $can_unwind_signal = no && test $enable_sjlj_exceptions = no; then
3043 CHECKREFSPEC=-fcheck-references
3044 DIVIDESPEC=-fuse-divide-subroutine
3045 EXCEPTIONSPEC=
3048 # Check whether --enable-java-net or --disable-java-net was given.
3049 if test "${enable_java_net+set}" = set; then
3050 enableval="$enable_java_net"
3055 if test -z "$enable_java_net"; then
3056 enable_java_net=${enable_java_net_default-yes}
3058 if test "$enable_java_net" = no; then
3059 cat >> confdefs.h <<\EOF
3060 #define DISABLE_JAVA_NET 1
3065 # Check whether --with-libffi or --without-libffi was given.
3066 if test "${with_libffi+set}" = set; then
3067 withval="$with_libffi"
3069 else
3070 with_libffi=${with_libffi_default-yes}
3074 LIBFFI=
3075 LIBFFIINCS=
3076 if test "$with_libffi" != no; then
3077 cat >> confdefs.h <<\EOF
3078 #define USE_LIBFFI 1
3081 LIBFFI=../libffi/libffi_convenience.la
3082 LIBFFIINCS='-I$(top_srcdir)/../libffi/include -I$(MULTIBUILDTOP)../libffi/include'
3087 # Check whether --enable-jvmpi or --disable-jvmpi was given.
3088 if test "${enable_jvmpi+set}" = set; then
3089 enableval="$enable_jvmpi"
3094 if test "$enable_jvmpi" != no; then
3095 cat >> confdefs.h <<\EOF
3096 #define ENABLE_JVMPI 1
3101 TARGET_ECOS=${PROCESS-"no"}
3102 # Check whether --with-ecos or --without-ecos was given.
3103 if test "${with_ecos+set}" = set; then
3104 withval="$with_ecos"
3105 TARGET_ECOS="$with_ecos"
3110 PLATFORMOBJS=
3111 case "$TARGET_ECOS" in
3112 no) case "$host" in
3113 *mingw*)
3114 PLATFORM=Win32
3115 PLATFORMOBJS=win32.lo
3116 PLATFORMH=win32.h
3119 PLATFORM=Posix
3120 PLATFORMOBJS=posix.lo
3121 PLATFORMH=posix.h
3123 esac
3126 PLATFORM=Ecos
3127 cat >> confdefs.h <<\EOF
3128 #define ECOS 1
3131 PLATFORMOBJS=posix.lo
3132 PLATFORMH=posix.h
3134 esac
3138 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
3139 echo "configure:3140: checking how to run the C preprocessor" >&5
3140 # On Suns, sometimes $CPP names a directory.
3141 if test -n "$CPP" && test -d "$CPP"; then
3142 CPP=
3144 if test -z "$CPP"; then
3145 if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
3146 echo $ac_n "(cached) $ac_c" 1>&6
3147 else
3148 # This must be in double quotes, not single quotes, because CPP may get
3149 # substituted into the Makefile and "${CC-cc}" will confuse make.
3150 CPP="${CC-cc} -E"
3151 # On the NeXT, cc -E runs the code through the compiler's parser,
3152 # not just through cpp.
3153 cat > conftest.$ac_ext <<EOF
3154 #line 3155 "configure"
3155 #include "confdefs.h"
3156 #include <assert.h>
3157 Syntax Error
3159 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3160 { (eval echo configure:3161: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3161 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3162 if test -z "$ac_err"; then
3164 else
3165 echo "$ac_err" >&5
3166 echo "configure: failed program was:" >&5
3167 cat conftest.$ac_ext >&5
3168 rm -rf conftest*
3169 CPP="${CC-cc} -E -traditional-cpp"
3170 cat > conftest.$ac_ext <<EOF
3171 #line 3172 "configure"
3172 #include "confdefs.h"
3173 #include <assert.h>
3174 Syntax Error
3176 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3177 { (eval echo configure:3178: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3178 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3179 if test -z "$ac_err"; then
3181 else
3182 echo "$ac_err" >&5
3183 echo "configure: failed program was:" >&5
3184 cat conftest.$ac_ext >&5
3185 rm -rf conftest*
3186 CPP="${CC-cc} -nologo -E"
3187 cat > conftest.$ac_ext <<EOF
3188 #line 3189 "configure"
3189 #include "confdefs.h"
3190 #include <assert.h>
3191 Syntax Error
3193 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3194 { (eval echo configure:3195: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3195 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3196 if test -z "$ac_err"; then
3198 else
3199 echo "$ac_err" >&5
3200 echo "configure: failed program was:" >&5
3201 cat conftest.$ac_ext >&5
3202 rm -rf conftest*
3203 CPP=/lib/cpp
3205 rm -f conftest*
3207 rm -f conftest*
3209 rm -f conftest*
3210 ac_cv_prog_CPP="$CPP"
3212 CPP="$ac_cv_prog_CPP"
3213 else
3214 ac_cv_prog_CPP="$CPP"
3216 echo "$ac_t""$CPP" 1>&6
3218 cat > conftest.$ac_ext <<EOF
3219 #line 3220 "configure"
3220 #include "confdefs.h"
3221 #include <stdint.h>
3223 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3224 egrep "uint32_t" >/dev/null 2>&1; then
3225 rm -rf conftest*
3226 cat >> confdefs.h <<\EOF
3227 #define HAVE_INT32_DEFINED 1
3231 rm -f conftest*
3233 cat > conftest.$ac_ext <<EOF
3234 #line 3235 "configure"
3235 #include "confdefs.h"
3236 #include <inttypes.h>
3238 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3239 egrep "uint32_t" >/dev/null 2>&1; then
3240 rm -rf conftest*
3241 cat >> confdefs.h <<\EOF
3242 #define HAVE_INT32_DEFINED 1
3246 rm -f conftest*
3248 cat > conftest.$ac_ext <<EOF
3249 #line 3250 "configure"
3250 #include "confdefs.h"
3251 #include <sys/types.h>
3253 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3254 egrep "u_int32_t" >/dev/null 2>&1; then
3255 rm -rf conftest*
3256 cat >> confdefs.h <<\EOF
3257 #define HAVE_BSD_INT32_DEFINED 1
3261 rm -f conftest*
3263 cat > conftest.$ac_ext <<EOF
3264 #line 3265 "configure"
3265 #include "confdefs.h"
3266 #include <sys/config.h>
3268 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3269 egrep "u_int32_t" >/dev/null 2>&1; then
3270 rm -rf conftest*
3271 cat >> confdefs.h <<\EOF
3272 #define HAVE_BSD_INT32_DEFINED 1
3276 rm -f conftest*
3280 cat > conftest.$ac_ext <<EOF
3281 #line 3282 "configure"
3282 #include "confdefs.h"
3283 #include <time.h>
3285 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3286 egrep "mktime" >/dev/null 2>&1; then
3287 rm -rf conftest*
3288 cat >> confdefs.h <<\EOF
3289 #define HAVE_MKTIME 1
3293 rm -f conftest*
3295 cat > conftest.$ac_ext <<EOF
3296 #line 3297 "configure"
3297 #include "confdefs.h"
3298 #include <time.h>
3300 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3301 egrep "localtime" >/dev/null 2>&1; then
3302 rm -rf conftest*
3303 cat >> confdefs.h <<\EOF
3304 #define HAVE_LOCALTIME 1
3308 rm -f conftest*
3311 test -d java || mkdir java
3312 test -d java/io || mkdir java/io
3313 test -d gnu || mkdir gnu
3317 test -d java/lang || mkdir java/lang
3321 case "${host}" in
3322 *mingw*)
3323 SYSTEMSPEC="-lgdi32 -lwsock32 -lws2_32"
3326 SYSTEMSPEC=
3328 esac
3331 LIBGCJTESTSPEC="-L`pwd`/.libs -rpath `pwd`/.libs"
3334 # Check whether --with-system-zlib or --without-system-zlib was given.
3335 if test "${with_system_zlib+set}" = set; then
3336 withval="$with_system_zlib"
3340 ZLIBSPEC=
3342 ZLIBTESTSPEC=
3345 libsubdir=.libs
3347 echo $ac_n "checking for garbage collector to use""... $ac_c" 1>&6
3348 echo "configure:3349: checking for garbage collector to use" >&5
3349 # Check whether --enable-java-gc or --disable-java-gc was given.
3350 if test "${enable_java_gc+set}" = set; then
3351 enableval="$enable_java_gc"
3353 GC=$enableval
3354 else
3355 GC=boehm
3358 GCLIBS=
3359 GCINCS=
3360 GCDEPS=
3361 GCOBJS=
3362 GCSPEC=
3363 JC1GCSPEC=
3364 GCTESTSPEC=
3365 case "$GC" in
3366 boehm)
3367 echo "$ac_t""boehm" 1>&6
3368 GCLIBS=../boehm-gc/libgcjgc_convenience.la
3369 GCINCS='-I$(top_srcdir)/../boehm-gc/include'
3370 JC1GCSPEC='-fuse-boehm-gc'
3371 GCTESTSPEC="-L`pwd`/../boehm-gc/.libs -rpath `pwd`/../boehm-gc/.libs"
3373 GCINCS="$GCINCS `cat ../boehm-gc/boehm-cflags`"
3374 GCOBJS=boehm.lo
3375 GCHDR=boehm-gc.h
3376 cat >> confdefs.h <<\EOF
3377 #define HAVE_BOEHM_GC 1
3382 echo "$ac_t""none" 1>&6
3383 GCOBJS=nogc.lo
3384 GCHDR=no-gc.h
3387 { echo "configure: error: unrecognized collector \"$GC\"" 1>&2; exit 1; }
3389 esac
3400 echo $ac_n "checking for thread model used by GCC""... $ac_c" 1>&6
3401 echo "configure:3402: checking for thread model used by GCC" >&5
3402 THREADS=`$CC -v 2>&1 | sed -n 's/^Thread model: //p'`
3403 echo "$ac_t""$THREADS" 1>&6
3405 case "$THREADS" in
3406 no | none | single)
3407 THREADS=none
3409 posix | pthreads)
3410 THREADS=posix
3411 case "$host" in
3412 *-*-linux*)
3413 cat >> confdefs.h <<\EOF
3414 #define LINUX_THREADS 1
3418 esac
3420 win32)
3422 decosf1 | irix | mach | os2 | solaris | dce | vxworks)
3423 { echo "configure: error: thread package $THREADS not yet supported" 1>&2; exit 1; }
3426 { echo "configure: error: $THREADS is an unknown thread package" 1>&2; exit 1; }
3428 esac
3430 THREADLDFLAGS=
3431 THREADLIBS=
3432 THREADINCS=
3433 THREADDEPS=
3434 THREADOBJS=
3435 THREADH=
3436 THREADSPEC=
3437 case "$THREADS" in
3438 posix)
3439 case "$host" in
3440 *-*-cygwin*)
3441 # Don't set THREADLIBS here. Cygwin doesn't have -lpthread.
3444 *-*-freebsd[1234]*)
3446 # Before FreeBSD 5, it didn't have -lpthread (or any library which
3447 # merely adds pthread_* functions) but it does have a -pthread switch
3448 # which is required at link-time to select -lc_r *instead* of -lc.
3449 THREADLDFLAGS=-pthread
3450 # Don't set THREADSPEC here as might be expected since -pthread is
3451 # not processed when found within a spec file, it must come from
3452 # the command line. For now, the user must provide the -pthread
3453 # switch to link code compiled with gcj. In future, consider adding
3454 # support for weak references to pthread_* functions ala gthr.h API.
3455 THREADSPEC='%{!pthread: %eUnder this configuration, the user must provide -pthread when linking.}'
3457 *-*-freebsd*)
3458 # FreeBSD 5 implements a model much closer to other modern UNIX
3459 # which support threads. However, it still does not support
3460 # -lpthread.
3461 THREADLDFLAGS=-pthread
3462 THREADSPEC=-lc_r
3465 THREADLIBS=-lpthread
3466 THREADSPEC=-lpthread
3468 esac
3469 THREADOBJS=posix-threads.lo
3470 THREADH=posix-threads.h
3471 # MIT pthreads doesn't seem to have the mutexattr functions.
3472 # But for now we don't check for it. We just assume you aren't
3473 # using MIT pthreads.
3474 cat >> confdefs.h <<\EOF
3475 #define HAVE_PTHREAD_MUTEXATTR_INIT 1
3479 # If we're using the Boehm GC, then we happen to know that it
3480 # defines _REENTRANT, so we don't bother. Eww.
3481 if test "$GC" != boehm; then
3482 cat >> confdefs.h <<\EOF
3483 #define _REENTRANT 1
3487 cat >> confdefs.h <<\EOF
3488 #define _POSIX_PTHREAD_SEMANTICS 1
3493 win32)
3494 THREADOBJS=win32-threads.lo
3495 THREADH=win32-threads.h
3498 none)
3499 THREADOBJS=no-threads.lo
3500 THREADH=no-threads.h
3502 esac
3511 if test -d sysdep; then true; else mkdir sysdep; fi
3514 HASH_SYNC_SPEC=
3515 # Hash synchronization is only useful with posix threads right now.
3516 if test "$enable_hash_synchronization" = yes && test "$THREADS" = "posix"; then
3517 HASH_SYNC_SPEC=-fhash-synchronization
3518 cat >> confdefs.h <<\EOF
3519 #define JV_HASH_SYNCHRONIZATION 1
3528 if test "$GCC" = yes; then
3529 USING_GCC_TRUE=
3530 USING_GCC_FALSE='#'
3531 else
3532 USING_GCC_TRUE='#'
3533 USING_GCC_FALSE=
3536 CANADIAN=no
3537 NULL_TARGET=no
3538 NATIVE=yes
3540 # We're in the tree with gcc, and need to include some of its headers.
3541 GCC_UNWIND_INCLUDE='-I$(libgcj_basedir)/../gcc'
3543 # Figure out where generated headers like libgcj-config.h get installed.
3544 gcc_version_trigger=${libgcj_basedir}/../gcc/version.c
3545 gcc_version_full=`grep version_string ${gcc_version_trigger} | sed -e 's/.*\"\([^\"]*\)\".*/\1/'`
3546 gcc_version=`echo ${gcc_version_full} | sed -e 's/\([^ ]*\) .*/\1/'`
3547 tool_include_dir='$(libdir)/gcc-lib/$(target_alias)/'${gcc_version}/include
3551 if test -n "${with_cross_host_stupid}"; then
3552 # We are being configured with a cross compiler. AC_REPLACE_FUNCS
3553 # may not work correctly, because the compiler may not be able to
3554 # link executables.
3556 # We assume newlib. This lets us hard-code the functions we know
3557 # we'll have.
3558 cat >> confdefs.h <<\EOF
3559 #define HAVE_MEMMOVE 1
3562 cat >> confdefs.h <<\EOF
3563 #define HAVE_MEMCPY 1
3566 cat >> confdefs.h <<\EOF
3567 #define HAVE_STRERROR 1
3570 cat >> confdefs.h <<\EOF
3571 #define HAVE_TIME 1
3574 cat >> confdefs.h <<\EOF
3575 #define HAVE_GMTIME_R 1
3578 cat >> confdefs.h <<\EOF
3579 #define HAVE_LOCALTIME_R 1
3582 cat >> confdefs.h <<\EOF
3583 #define HAVE_PTHREAD_MUTEXATTR_INIT 1
3586 cat >> confdefs.h <<\EOF
3587 #define HAVE_ALLOCA 1
3591 cat >> confdefs.h <<\EOF
3592 #define NO_GETUID 1
3596 # If Canadian cross, then don't pick up tools from the build
3597 # directory.
3598 if test x"$build" != x"$with_cross_host" && x"$build" != x"$target"; then
3599 CANADIAN=yes
3600 GCC_UNWIND_INCLUDE=
3601 GCJ="${target_alias}-gcj"
3603 NATIVE=no
3604 else
3605 for ac_func in strerror ioctl select fstat open fsync sleep opendir
3607 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3608 echo "configure:3609: checking for $ac_func" >&5
3609 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3610 echo $ac_n "(cached) $ac_c" 1>&6
3611 else
3612 cat > conftest.$ac_ext <<EOF
3613 #line 3614 "configure"
3614 #include "confdefs.h"
3615 /* System header to define __stub macros and hopefully few prototypes,
3616 which can conflict with char $ac_func(); below. */
3617 #include <assert.h>
3618 /* Override any gcc2 internal prototype to avoid an error. */
3619 /* We use char because int might match the return type of a gcc2
3620 builtin and then its argument prototype would still apply. */
3621 char $ac_func();
3623 int main() {
3625 /* The GNU C library defines this for functions which it implements
3626 to always fail with ENOSYS. Some functions are actually named
3627 something starting with __ and the normal name is an alias. */
3628 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3629 choke me
3630 #else
3631 $ac_func();
3632 #endif
3634 ; return 0; }
3636 if { (eval echo configure:3637: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3637 rm -rf conftest*
3638 eval "ac_cv_func_$ac_func=yes"
3639 else
3640 echo "configure: failed program was:" >&5
3641 cat conftest.$ac_ext >&5
3642 rm -rf conftest*
3643 eval "ac_cv_func_$ac_func=no"
3645 rm -f conftest*
3648 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3649 echo "$ac_t""yes" 1>&6
3650 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3651 cat >> confdefs.h <<EOF
3652 #define $ac_tr_func 1
3655 else
3656 echo "$ac_t""no" 1>&6
3658 done
3660 for ac_func in gmtime_r localtime_r readdir_r getpwuid_r getcwd
3662 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3663 echo "configure:3664: checking for $ac_func" >&5
3664 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3665 echo $ac_n "(cached) $ac_c" 1>&6
3666 else
3667 cat > conftest.$ac_ext <<EOF
3668 #line 3669 "configure"
3669 #include "confdefs.h"
3670 /* System header to define __stub macros and hopefully few prototypes,
3671 which can conflict with char $ac_func(); below. */
3672 #include <assert.h>
3673 /* Override any gcc2 internal prototype to avoid an error. */
3674 /* We use char because int might match the return type of a gcc2
3675 builtin and then its argument prototype would still apply. */
3676 char $ac_func();
3678 int main() {
3680 /* The GNU C library defines this for functions which it implements
3681 to always fail with ENOSYS. Some functions are actually named
3682 something starting with __ and the normal name is an alias. */
3683 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3684 choke me
3685 #else
3686 $ac_func();
3687 #endif
3689 ; return 0; }
3691 if { (eval echo configure:3692: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3692 rm -rf conftest*
3693 eval "ac_cv_func_$ac_func=yes"
3694 else
3695 echo "configure: failed program was:" >&5
3696 cat conftest.$ac_ext >&5
3697 rm -rf conftest*
3698 eval "ac_cv_func_$ac_func=no"
3700 rm -f conftest*
3703 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3704 echo "$ac_t""yes" 1>&6
3705 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3706 cat >> confdefs.h <<EOF
3707 #define $ac_tr_func 1
3710 else
3711 echo "$ac_t""no" 1>&6
3713 done
3715 for ac_func in access stat mkdir rename rmdir unlink realpath utime chmod
3717 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3718 echo "configure:3719: checking for $ac_func" >&5
3719 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3720 echo $ac_n "(cached) $ac_c" 1>&6
3721 else
3722 cat > conftest.$ac_ext <<EOF
3723 #line 3724 "configure"
3724 #include "confdefs.h"
3725 /* System header to define __stub macros and hopefully few prototypes,
3726 which can conflict with char $ac_func(); below. */
3727 #include <assert.h>
3728 /* Override any gcc2 internal prototype to avoid an error. */
3729 /* We use char because int might match the return type of a gcc2
3730 builtin and then its argument prototype would still apply. */
3731 char $ac_func();
3733 int main() {
3735 /* The GNU C library defines this for functions which it implements
3736 to always fail with ENOSYS. Some functions are actually named
3737 something starting with __ and the normal name is an alias. */
3738 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3739 choke me
3740 #else
3741 $ac_func();
3742 #endif
3744 ; return 0; }
3746 if { (eval echo configure:3747: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3747 rm -rf conftest*
3748 eval "ac_cv_func_$ac_func=yes"
3749 else
3750 echo "configure: failed program was:" >&5
3751 cat conftest.$ac_ext >&5
3752 rm -rf conftest*
3753 eval "ac_cv_func_$ac_func=no"
3755 rm -f conftest*
3758 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3759 echo "$ac_t""yes" 1>&6
3760 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3761 cat >> confdefs.h <<EOF
3762 #define $ac_tr_func 1
3765 else
3766 echo "$ac_t""no" 1>&6
3768 done
3770 for ac_func in nl_langinfo setlocale
3772 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3773 echo "configure:3774: checking for $ac_func" >&5
3774 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3775 echo $ac_n "(cached) $ac_c" 1>&6
3776 else
3777 cat > conftest.$ac_ext <<EOF
3778 #line 3779 "configure"
3779 #include "confdefs.h"
3780 /* System header to define __stub macros and hopefully few prototypes,
3781 which can conflict with char $ac_func(); below. */
3782 #include <assert.h>
3783 /* Override any gcc2 internal prototype to avoid an error. */
3784 /* We use char because int might match the return type of a gcc2
3785 builtin and then its argument prototype would still apply. */
3786 char $ac_func();
3788 int main() {
3790 /* The GNU C library defines this for functions which it implements
3791 to always fail with ENOSYS. Some functions are actually named
3792 something starting with __ and the normal name is an alias. */
3793 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3794 choke me
3795 #else
3796 $ac_func();
3797 #endif
3799 ; return 0; }
3801 if { (eval echo configure:3802: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3802 rm -rf conftest*
3803 eval "ac_cv_func_$ac_func=yes"
3804 else
3805 echo "configure: failed program was:" >&5
3806 cat conftest.$ac_ext >&5
3807 rm -rf conftest*
3808 eval "ac_cv_func_$ac_func=no"
3810 rm -f conftest*
3813 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3814 echo "$ac_t""yes" 1>&6
3815 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3816 cat >> confdefs.h <<EOF
3817 #define $ac_tr_func 1
3820 else
3821 echo "$ac_t""no" 1>&6
3823 done
3825 for ac_func in inet_aton inet_addr
3827 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3828 echo "configure:3829: checking for $ac_func" >&5
3829 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3830 echo $ac_n "(cached) $ac_c" 1>&6
3831 else
3832 cat > conftest.$ac_ext <<EOF
3833 #line 3834 "configure"
3834 #include "confdefs.h"
3835 /* System header to define __stub macros and hopefully few prototypes,
3836 which can conflict with char $ac_func(); below. */
3837 #include <assert.h>
3838 /* Override any gcc2 internal prototype to avoid an error. */
3839 /* We use char because int might match the return type of a gcc2
3840 builtin and then its argument prototype would still apply. */
3841 char $ac_func();
3843 int main() {
3845 /* The GNU C library defines this for functions which it implements
3846 to always fail with ENOSYS. Some functions are actually named
3847 something starting with __ and the normal name is an alias. */
3848 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3849 choke me
3850 #else
3851 $ac_func();
3852 #endif
3854 ; return 0; }
3856 if { (eval echo configure:3857: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3857 rm -rf conftest*
3858 eval "ac_cv_func_$ac_func=yes"
3859 else
3860 echo "configure: failed program was:" >&5
3861 cat conftest.$ac_ext >&5
3862 rm -rf conftest*
3863 eval "ac_cv_func_$ac_func=no"
3865 rm -f conftest*
3868 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3869 echo "$ac_t""yes" 1>&6
3870 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3871 cat >> confdefs.h <<EOF
3872 #define $ac_tr_func 1
3874 break
3875 else
3876 echo "$ac_t""no" 1>&6
3878 done
3880 for ac_func in inet_pton uname inet_ntoa
3882 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3883 echo "configure:3884: checking for $ac_func" >&5
3884 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3885 echo $ac_n "(cached) $ac_c" 1>&6
3886 else
3887 cat > conftest.$ac_ext <<EOF
3888 #line 3889 "configure"
3889 #include "confdefs.h"
3890 /* System header to define __stub macros and hopefully few prototypes,
3891 which can conflict with char $ac_func(); below. */
3892 #include <assert.h>
3893 /* Override any gcc2 internal prototype to avoid an error. */
3894 /* We use char because int might match the return type of a gcc2
3895 builtin and then its argument prototype would still apply. */
3896 char $ac_func();
3898 int main() {
3900 /* The GNU C library defines this for functions which it implements
3901 to always fail with ENOSYS. Some functions are actually named
3902 something starting with __ and the normal name is an alias. */
3903 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3904 choke me
3905 #else
3906 $ac_func();
3907 #endif
3909 ; return 0; }
3911 if { (eval echo configure:3912: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3912 rm -rf conftest*
3913 eval "ac_cv_func_$ac_func=yes"
3914 else
3915 echo "configure: failed program was:" >&5
3916 cat conftest.$ac_ext >&5
3917 rm -rf conftest*
3918 eval "ac_cv_func_$ac_func=no"
3920 rm -f conftest*
3923 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3924 echo "$ac_t""yes" 1>&6
3925 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3926 cat >> confdefs.h <<EOF
3927 #define $ac_tr_func 1
3930 else
3931 echo "$ac_t""no" 1>&6
3933 done
3935 for ac_func in fork execvp pipe sigaction
3937 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3938 echo "configure:3939: checking for $ac_func" >&5
3939 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3940 echo $ac_n "(cached) $ac_c" 1>&6
3941 else
3942 cat > conftest.$ac_ext <<EOF
3943 #line 3944 "configure"
3944 #include "confdefs.h"
3945 /* System header to define __stub macros and hopefully few prototypes,
3946 which can conflict with char $ac_func(); below. */
3947 #include <assert.h>
3948 /* Override any gcc2 internal prototype to avoid an error. */
3949 /* We use char because int might match the return type of a gcc2
3950 builtin and then its argument prototype would still apply. */
3951 char $ac_func();
3953 int main() {
3955 /* The GNU C library defines this for functions which it implements
3956 to always fail with ENOSYS. Some functions are actually named
3957 something starting with __ and the normal name is an alias. */
3958 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3959 choke me
3960 #else
3961 $ac_func();
3962 #endif
3964 ; return 0; }
3966 if { (eval echo configure:3967: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3967 rm -rf conftest*
3968 eval "ac_cv_func_$ac_func=yes"
3969 else
3970 echo "configure: failed program was:" >&5
3971 cat conftest.$ac_ext >&5
3972 rm -rf conftest*
3973 eval "ac_cv_func_$ac_func=no"
3975 rm -f conftest*
3978 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3979 echo "$ac_t""yes" 1>&6
3980 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3981 cat >> confdefs.h <<EOF
3982 #define $ac_tr_func 1
3985 else
3986 echo "$ac_t""no" 1>&6
3988 done
3990 for ac_hdr in execinfo.h unistd.h dlfcn.h
3992 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
3993 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
3994 echo "configure:3995: checking for $ac_hdr" >&5
3995 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3996 echo $ac_n "(cached) $ac_c" 1>&6
3997 else
3998 cat > conftest.$ac_ext <<EOF
3999 #line 4000 "configure"
4000 #include "confdefs.h"
4001 #include <$ac_hdr>
4003 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4004 { (eval echo configure:4005: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4005 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4006 if test -z "$ac_err"; then
4007 rm -rf conftest*
4008 eval "ac_cv_header_$ac_safe=yes"
4009 else
4010 echo "$ac_err" >&5
4011 echo "configure: failed program was:" >&5
4012 cat conftest.$ac_ext >&5
4013 rm -rf conftest*
4014 eval "ac_cv_header_$ac_safe=no"
4016 rm -f conftest*
4018 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4019 echo "$ac_t""yes" 1>&6
4020 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4021 cat >> confdefs.h <<EOF
4022 #define $ac_tr_hdr 1
4025 else
4026 echo "$ac_t""no" 1>&6
4028 done
4030 echo $ac_n "checking for backtrace""... $ac_c" 1>&6
4031 echo "configure:4032: checking for backtrace" >&5
4032 if eval "test \"`echo '$''{'ac_cv_func_backtrace'+set}'`\" = set"; then
4033 echo $ac_n "(cached) $ac_c" 1>&6
4034 else
4035 cat > conftest.$ac_ext <<EOF
4036 #line 4037 "configure"
4037 #include "confdefs.h"
4038 /* System header to define __stub macros and hopefully few prototypes,
4039 which can conflict with char backtrace(); below. */
4040 #include <assert.h>
4041 /* Override any gcc2 internal prototype to avoid an error. */
4042 /* We use char because int might match the return type of a gcc2
4043 builtin and then its argument prototype would still apply. */
4044 char backtrace();
4046 int main() {
4048 /* The GNU C library defines this for functions which it implements
4049 to always fail with ENOSYS. Some functions are actually named
4050 something starting with __ and the normal name is an alias. */
4051 #if defined (__stub_backtrace) || defined (__stub___backtrace)
4052 choke me
4053 #else
4054 backtrace();
4055 #endif
4057 ; return 0; }
4059 if { (eval echo configure:4060: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4060 rm -rf conftest*
4061 eval "ac_cv_func_backtrace=yes"
4062 else
4063 echo "configure: failed program was:" >&5
4064 cat conftest.$ac_ext >&5
4065 rm -rf conftest*
4066 eval "ac_cv_func_backtrace=no"
4068 rm -f conftest*
4071 if eval "test \"`echo '$ac_cv_func_'backtrace`\" = yes"; then
4072 echo "$ac_t""yes" 1>&6
4074 case "$host" in
4075 ia64-*-linux*)
4076 # Has broken backtrace()
4079 cat >> confdefs.h <<\EOF
4080 #define HAVE_BACKTRACE 1
4084 esac
4086 else
4087 echo "$ac_t""no" 1>&6
4091 echo $ac_n "checking for dladdr in -ldl""... $ac_c" 1>&6
4092 echo "configure:4093: checking for dladdr in -ldl" >&5
4093 ac_lib_var=`echo dl'_'dladdr | sed 'y%./+-%__p_%'`
4094 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4095 echo $ac_n "(cached) $ac_c" 1>&6
4096 else
4097 ac_save_LIBS="$LIBS"
4098 LIBS="-ldl $LIBS"
4099 cat > conftest.$ac_ext <<EOF
4100 #line 4101 "configure"
4101 #include "confdefs.h"
4102 /* Override any gcc2 internal prototype to avoid an error. */
4103 /* We use char because int might match the return type of a gcc2
4104 builtin and then its argument prototype would still apply. */
4105 char dladdr();
4107 int main() {
4108 dladdr()
4109 ; return 0; }
4111 if { (eval echo configure:4112: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4112 rm -rf conftest*
4113 eval "ac_cv_lib_$ac_lib_var=yes"
4114 else
4115 echo "configure: failed program was:" >&5
4116 cat conftest.$ac_ext >&5
4117 rm -rf conftest*
4118 eval "ac_cv_lib_$ac_lib_var=no"
4120 rm -f conftest*
4121 LIBS="$ac_save_LIBS"
4124 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4125 echo "$ac_t""yes" 1>&6
4127 cat >> confdefs.h <<\EOF
4128 #define HAVE_DLADDR 1
4131 else
4132 echo "$ac_t""no" 1>&6
4135 for ac_file in /proc/self/exe
4138 ac_safe=`echo "$ac_file" | sed 'y%./+-%__p_%'`
4139 echo $ac_n "checking for $ac_file""... $ac_c" 1>&6
4140 echo "configure:4141: checking for $ac_file" >&5
4141 if eval "test \"`echo '$''{'ac_cv_file_$ac_safe'+set}'`\" = set"; then
4142 echo $ac_n "(cached) $ac_c" 1>&6
4143 else
4144 if test "$cross_compiling" = yes; then
4145 { echo "configure: error: Cannot check for file existence when cross compiling" 1>&2; exit 1; }
4146 else
4147 if test -r $ac_file; then
4148 eval "ac_cv_file_$ac_safe=yes"
4149 else
4150 eval "ac_cv_file_$ac_safe=no"
4154 if eval "test \"`echo '$ac_cv_file_'$ac_safe`\" = yes"; then
4155 echo "$ac_t""yes" 1>&6
4156 ac_tr_file=HAVE_`echo $ac_file | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4157 cat >> confdefs.h <<EOF
4158 #define $ac_tr_file 1
4161 cat >> confdefs.h <<\EOF
4162 #define HAVE_PROC_SELF_EXE 1
4165 else
4166 echo "$ac_t""no" 1>&6
4169 done
4174 am_cv_lib_iconv_ldpath=
4175 # Check whether --with-libiconv-prefix or --without-libiconv-prefix was given.
4176 if test "${with_libiconv_prefix+set}" = set; then
4177 withval="$with_libiconv_prefix"
4179 for dir in `echo "$withval" | tr : ' '`; do
4180 if test -d $dir/include; then CPPFLAGS="$CPPFLAGS -I$dir/include"; fi
4181 if test -d $dir/lib; then am_cv_lib_iconv_ldpath="-L$dir/lib"; fi
4182 done
4187 echo $ac_n "checking for iconv""... $ac_c" 1>&6
4188 echo "configure:4189: checking for iconv" >&5
4189 if eval "test \"`echo '$''{'am_cv_func_iconv'+set}'`\" = set"; then
4190 echo $ac_n "(cached) $ac_c" 1>&6
4191 else
4193 am_cv_func_iconv="no, consider installing GNU libiconv"
4194 am_cv_lib_iconv=no
4195 cat > conftest.$ac_ext <<EOF
4196 #line 4197 "configure"
4197 #include "confdefs.h"
4198 #include <stdlib.h>
4199 #include <iconv.h>
4200 int main() {
4201 iconv_t cd = iconv_open("","");
4202 iconv(cd,NULL,NULL,NULL,NULL);
4203 iconv_close(cd);
4204 ; return 0; }
4206 if { (eval echo configure:4207: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4207 rm -rf conftest*
4208 am_cv_func_iconv=yes
4209 else
4210 echo "configure: failed program was:" >&5
4211 cat conftest.$ac_ext >&5
4213 rm -f conftest*
4214 if test "$am_cv_func_iconv" != yes; then
4215 am_save_LIBS="$LIBS"
4216 LIBS="$LIBS $am_cv_libiconv_ldpath -liconv"
4217 cat > conftest.$ac_ext <<EOF
4218 #line 4219 "configure"
4219 #include "confdefs.h"
4220 #include <stdlib.h>
4221 #include <iconv.h>
4222 int main() {
4223 iconv_t cd = iconv_open("","");
4224 iconv(cd,NULL,NULL,NULL,NULL);
4225 iconv_close(cd);
4226 ; return 0; }
4228 if { (eval echo configure:4229: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4229 rm -rf conftest*
4230 am_cv_lib_iconv=yes
4231 am_cv_func_iconv=yes
4232 else
4233 echo "configure: failed program was:" >&5
4234 cat conftest.$ac_ext >&5
4236 rm -f conftest*
4237 LIBS="$am_save_LIBS"
4242 echo "$ac_t""$am_cv_func_iconv" 1>&6
4243 if test "$am_cv_func_iconv" = yes; then
4244 cat >> confdefs.h <<\EOF
4245 #define HAVE_ICONV 1
4248 echo $ac_n "checking for iconv declaration""... $ac_c" 1>&6
4249 echo "configure:4250: checking for iconv declaration" >&5
4250 if eval "test \"`echo '$''{'am_cv_proto_iconv'+set}'`\" = set"; then
4251 echo $ac_n "(cached) $ac_c" 1>&6
4252 else
4254 cat > conftest.$ac_ext <<EOF
4255 #line 4256 "configure"
4256 #include "confdefs.h"
4258 #include <stdlib.h>
4259 #include <iconv.h>
4260 extern
4261 #ifdef __cplusplus
4263 #endif
4264 #if defined(__STDC__) || defined(__cplusplus)
4265 size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);
4266 #else
4267 size_t iconv();
4268 #endif
4270 int main() {
4272 ; return 0; }
4274 if { (eval echo configure:4275: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4275 rm -rf conftest*
4276 am_cv_proto_iconv_arg1=""
4277 else
4278 echo "configure: failed program was:" >&5
4279 cat conftest.$ac_ext >&5
4280 rm -rf conftest*
4281 am_cv_proto_iconv_arg1="const"
4283 rm -f conftest*
4284 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);"
4287 am_cv_proto_iconv=`echo "$am_cv_proto_iconv" | tr -s ' ' | sed -e 's/( /(/'`
4288 echo "$ac_t""${ac_t:-
4289 }$am_cv_proto_iconv" 1>&6
4290 cat >> confdefs.h <<EOF
4291 #define ICONV_CONST $am_cv_proto_iconv_arg1
4295 LIBICONV=
4296 if test "$am_cv_lib_iconv" = yes; then
4297 LIBICONV="$am_cv_lib_iconv_ldpath -liconv"
4301 if test "$ac_cv_header_locale_h" = yes; then
4302 echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6
4303 echo "configure:4304: checking for LC_MESSAGES" >&5
4304 if eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then
4305 echo $ac_n "(cached) $ac_c" 1>&6
4306 else
4307 cat > conftest.$ac_ext <<EOF
4308 #line 4309 "configure"
4309 #include "confdefs.h"
4310 #include <locale.h>
4311 int main() {
4312 return LC_MESSAGES
4313 ; return 0; }
4315 if { (eval echo configure:4316: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4316 rm -rf conftest*
4317 am_cv_val_LC_MESSAGES=yes
4318 else
4319 echo "configure: failed program was:" >&5
4320 cat conftest.$ac_ext >&5
4321 rm -rf conftest*
4322 am_cv_val_LC_MESSAGES=no
4324 rm -f conftest*
4327 echo "$ac_t""$am_cv_val_LC_MESSAGES" 1>&6
4328 if test "$am_cv_val_LC_MESSAGES" = yes; then
4329 cat >> confdefs.h <<\EOF
4330 #define HAVE_LC_MESSAGES 1
4335 echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&6
4336 echo "configure:4337: checking whether struct tm is in sys/time.h or time.h" >&5
4337 if eval "test \"`echo '$''{'ac_cv_struct_tm'+set}'`\" = set"; then
4338 echo $ac_n "(cached) $ac_c" 1>&6
4339 else
4340 cat > conftest.$ac_ext <<EOF
4341 #line 4342 "configure"
4342 #include "confdefs.h"
4343 #include <sys/types.h>
4344 #include <time.h>
4345 int main() {
4346 struct tm *tp; tp->tm_sec;
4347 ; return 0; }
4349 if { (eval echo configure:4350: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4350 rm -rf conftest*
4351 ac_cv_struct_tm=time.h
4352 else
4353 echo "configure: failed program was:" >&5
4354 cat conftest.$ac_ext >&5
4355 rm -rf conftest*
4356 ac_cv_struct_tm=sys/time.h
4358 rm -f conftest*
4361 echo "$ac_t""$ac_cv_struct_tm" 1>&6
4362 if test $ac_cv_struct_tm = sys/time.h; then
4363 cat >> confdefs.h <<\EOF
4364 #define TM_IN_SYS_TIME 1
4369 echo $ac_n "checking for tm_zone in struct tm""... $ac_c" 1>&6
4370 echo "configure:4371: checking for tm_zone in struct tm" >&5
4371 if eval "test \"`echo '$''{'ac_cv_struct_tm_zone'+set}'`\" = set"; then
4372 echo $ac_n "(cached) $ac_c" 1>&6
4373 else
4374 cat > conftest.$ac_ext <<EOF
4375 #line 4376 "configure"
4376 #include "confdefs.h"
4377 #include <sys/types.h>
4378 #include <$ac_cv_struct_tm>
4379 int main() {
4380 struct tm tm; tm.tm_zone;
4381 ; return 0; }
4383 if { (eval echo configure:4384: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4384 rm -rf conftest*
4385 ac_cv_struct_tm_zone=yes
4386 else
4387 echo "configure: failed program was:" >&5
4388 cat conftest.$ac_ext >&5
4389 rm -rf conftest*
4390 ac_cv_struct_tm_zone=no
4392 rm -f conftest*
4395 echo "$ac_t""$ac_cv_struct_tm_zone" 1>&6
4396 if test "$ac_cv_struct_tm_zone" = yes; then
4397 cat >> confdefs.h <<\EOF
4398 #define HAVE_TM_ZONE 1
4401 else
4402 echo $ac_n "checking for tzname""... $ac_c" 1>&6
4403 echo "configure:4404: checking for tzname" >&5
4404 if eval "test \"`echo '$''{'ac_cv_var_tzname'+set}'`\" = set"; then
4405 echo $ac_n "(cached) $ac_c" 1>&6
4406 else
4407 cat > conftest.$ac_ext <<EOF
4408 #line 4409 "configure"
4409 #include "confdefs.h"
4410 #include <time.h>
4411 #ifndef tzname /* For SGI. */
4412 extern char *tzname[]; /* RS6000 and others reject char **tzname. */
4413 #endif
4414 int main() {
4415 atoi(*tzname);
4416 ; return 0; }
4418 if { (eval echo configure:4419: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4419 rm -rf conftest*
4420 ac_cv_var_tzname=yes
4421 else
4422 echo "configure: failed program was:" >&5
4423 cat conftest.$ac_ext >&5
4424 rm -rf conftest*
4425 ac_cv_var_tzname=no
4427 rm -f conftest*
4430 echo "$ac_t""$ac_cv_var_tzname" 1>&6
4431 if test $ac_cv_var_tzname = yes; then
4432 cat >> confdefs.h <<\EOF
4433 #define HAVE_TZNAME 1
4440 for ac_func in gethostbyname_r
4442 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
4443 echo "configure:4444: checking for $ac_func" >&5
4444 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
4445 echo $ac_n "(cached) $ac_c" 1>&6
4446 else
4447 cat > conftest.$ac_ext <<EOF
4448 #line 4449 "configure"
4449 #include "confdefs.h"
4450 /* System header to define __stub macros and hopefully few prototypes,
4451 which can conflict with char $ac_func(); below. */
4452 #include <assert.h>
4453 /* Override any gcc2 internal prototype to avoid an error. */
4454 /* We use char because int might match the return type of a gcc2
4455 builtin and then its argument prototype would still apply. */
4456 char $ac_func();
4458 int main() {
4460 /* The GNU C library defines this for functions which it implements
4461 to always fail with ENOSYS. Some functions are actually named
4462 something starting with __ and the normal name is an alias. */
4463 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
4464 choke me
4465 #else
4466 $ac_func();
4467 #endif
4469 ; return 0; }
4471 if { (eval echo configure:4472: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4472 rm -rf conftest*
4473 eval "ac_cv_func_$ac_func=yes"
4474 else
4475 echo "configure: failed program was:" >&5
4476 cat conftest.$ac_ext >&5
4477 rm -rf conftest*
4478 eval "ac_cv_func_$ac_func=no"
4480 rm -f conftest*
4483 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
4484 echo "$ac_t""yes" 1>&6
4485 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
4486 cat >> confdefs.h <<EOF
4487 #define $ac_tr_func 1
4490 cat >> confdefs.h <<\EOF
4491 #define HAVE_GETHOSTBYNAME_R 1
4494 # There are two different kinds of gethostbyname_r.
4495 # We look for the one that returns `int'.
4496 # Hopefully this check is robust enough.
4497 cat > conftest.$ac_ext <<EOF
4498 #line 4499 "configure"
4499 #include "confdefs.h"
4500 #include <netdb.h>
4502 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4503 egrep "int.*gethostbyname_r" >/dev/null 2>&1; then
4504 rm -rf conftest*
4506 cat >> confdefs.h <<\EOF
4507 #define GETHOSTBYNAME_R_RETURNS_INT 1
4511 rm -f conftest*
4514 case " $GCINCS " in
4515 *" -D_REENTRANT "*) ;;
4517 echo $ac_n "checking whether gethostbyname_r declaration requires -D_REENTRANT""... $ac_c" 1>&6
4518 echo "configure:4519: checking whether gethostbyname_r declaration requires -D_REENTRANT" >&5
4519 if eval "test \"`echo '$''{'libjava_cv_gethostbyname_r_needs_reentrant'+set}'`\" = set"; then
4520 echo $ac_n "(cached) $ac_c" 1>&6
4521 else
4523 ac_ext=C
4524 # CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
4525 ac_cpp='$CXXCPP $CPPFLAGS'
4526 ac_compile='${CXX-g++} -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
4527 ac_link='${CXX-g++} -o conftest${ac_exeext} $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
4528 cross_compiling=$ac_cv_prog_cxx_cross
4530 cat > conftest.$ac_ext <<EOF
4531 #line 4532 "configure"
4532 #include "confdefs.h"
4533 #include <netdb.h>
4534 int main() {
4535 gethostbyname_r("", 0, 0);
4536 ; return 0; }
4538 if { (eval echo configure:4539: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4539 rm -rf conftest*
4540 libjava_cv_gethostbyname_r_needs_reentrant=no
4541 else
4542 echo "configure: failed program was:" >&5
4543 cat conftest.$ac_ext >&5
4544 rm -rf conftest*
4545 CPPFLAGS_SAVE="$CPPFLAGS"
4546 CPPFLAGS="$CPPFLAGS -D_REENTRANT"
4547 cat > conftest.$ac_ext <<EOF
4548 #line 4549 "configure"
4549 #include "confdefs.h"
4550 #include <netdb.h>
4551 int main() {
4552 gethostbyname_r("", 0, 0);
4553 ; return 0; }
4555 if { (eval echo configure:4556: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4556 rm -rf conftest*
4557 libjava_cv_gethostbyname_r_needs_reentrant=yes
4558 else
4559 echo "configure: failed program was:" >&5
4560 cat conftest.$ac_ext >&5
4561 rm -rf conftest*
4562 libjava_cv_gethostbyname_r_needs_reentrant=fail
4564 rm -f conftest*
4565 CPPFLAGS="$CPPFLAGS_SAVE"
4568 rm -f conftest*
4569 ac_ext=c
4570 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
4571 ac_cpp='$CPP $CPPFLAGS'
4572 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
4573 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
4574 cross_compiling=$ac_cv_prog_cc_cross
4579 echo "$ac_t""$libjava_cv_gethostbyname_r_needs_reentrant" 1>&6
4580 if test "x$libjava_cv_gethostbyname_r_needs_reentrant" = xyes; then
4581 cat >> confdefs.h <<\EOF
4582 #define _REENTRANT 1
4587 esac
4589 echo $ac_n "checking for struct hostent_data""... $ac_c" 1>&6
4590 echo "configure:4591: checking for struct hostent_data" >&5
4591 if eval "test \"`echo '$''{'libjava_cv_struct_hostent_data'+set}'`\" = set"; then
4592 echo $ac_n "(cached) $ac_c" 1>&6
4593 else
4594 cat > conftest.$ac_ext <<EOF
4595 #line 4596 "configure"
4596 #include "confdefs.h"
4598 #if GETHOSTBYNAME_R_NEEDS_REENTRANT && !defined(_REENTRANT)
4599 # define _REENTRANT 1
4600 #endif
4601 #include <netdb.h>
4602 int main() {
4603 struct hostent_data data;
4604 ; return 0; }
4606 if { (eval echo configure:4607: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4607 rm -rf conftest*
4608 libjava_cv_struct_hostent_data=yes
4609 else
4610 echo "configure: failed program was:" >&5
4611 cat conftest.$ac_ext >&5
4612 rm -rf conftest*
4613 libjava_cv_struct_hostent_data=no
4615 rm -f conftest*
4618 echo "$ac_t""$libjava_cv_struct_hostent_data" 1>&6
4619 if test "x$libjava_cv_struct_hostent_data" = xyes; then
4620 cat >> confdefs.h <<\EOF
4621 #define HAVE_STRUCT_HOSTENT_DATA 1
4626 else
4627 echo "$ac_t""no" 1>&6
4629 done
4632 # FIXME: libjava source code expects to find a prototype for
4633 # gethostbyaddr_r in netdb.h. The outer check ensures that
4634 # HAVE_GETHOSTBYADDR_R will not be defined if the prototype fails
4635 # to exist where expected. (The root issue: AC_CHECK_FUNCS assumes C
4636 # linkage check is enough, yet C++ code requires proper prototypes.)
4637 cat > conftest.$ac_ext <<EOF
4638 #line 4639 "configure"
4639 #include "confdefs.h"
4640 #include <netdb.h>
4642 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4643 egrep "gethostbyaddr_r" >/dev/null 2>&1; then
4644 rm -rf conftest*
4646 for ac_func in gethostbyaddr_r
4648 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
4649 echo "configure:4650: checking for $ac_func" >&5
4650 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
4651 echo $ac_n "(cached) $ac_c" 1>&6
4652 else
4653 cat > conftest.$ac_ext <<EOF
4654 #line 4655 "configure"
4655 #include "confdefs.h"
4656 /* System header to define __stub macros and hopefully few prototypes,
4657 which can conflict with char $ac_func(); below. */
4658 #include <assert.h>
4659 /* Override any gcc2 internal prototype to avoid an error. */
4660 /* We use char because int might match the return type of a gcc2
4661 builtin and then its argument prototype would still apply. */
4662 char $ac_func();
4664 int main() {
4666 /* The GNU C library defines this for functions which it implements
4667 to always fail with ENOSYS. Some functions are actually named
4668 something starting with __ and the normal name is an alias. */
4669 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
4670 choke me
4671 #else
4672 $ac_func();
4673 #endif
4675 ; return 0; }
4677 if { (eval echo configure:4678: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4678 rm -rf conftest*
4679 eval "ac_cv_func_$ac_func=yes"
4680 else
4681 echo "configure: failed program was:" >&5
4682 cat conftest.$ac_ext >&5
4683 rm -rf conftest*
4684 eval "ac_cv_func_$ac_func=no"
4686 rm -f conftest*
4689 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
4690 echo "$ac_t""yes" 1>&6
4691 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
4692 cat >> confdefs.h <<EOF
4693 #define $ac_tr_func 1
4696 cat >> confdefs.h <<\EOF
4697 #define HAVE_GETHOSTBYADDR_R 1
4700 # There are two different kinds of gethostbyaddr_r.
4701 # We look for the one that returns `int'.
4702 # Hopefully this check is robust enough.
4703 cat > conftest.$ac_ext <<EOF
4704 #line 4705 "configure"
4705 #include "confdefs.h"
4706 #include <netdb.h>
4708 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4709 egrep "int.*gethostbyaddr_r" >/dev/null 2>&1; then
4710 rm -rf conftest*
4712 cat >> confdefs.h <<\EOF
4713 #define GETHOSTBYADDR_R_RETURNS_INT 1
4717 rm -f conftest*
4719 else
4720 echo "$ac_t""no" 1>&6
4722 done
4725 rm -f conftest*
4728 for ac_func in gethostname
4730 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
4731 echo "configure:4732: checking for $ac_func" >&5
4732 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
4733 echo $ac_n "(cached) $ac_c" 1>&6
4734 else
4735 cat > conftest.$ac_ext <<EOF
4736 #line 4737 "configure"
4737 #include "confdefs.h"
4738 /* System header to define __stub macros and hopefully few prototypes,
4739 which can conflict with char $ac_func(); below. */
4740 #include <assert.h>
4741 /* Override any gcc2 internal prototype to avoid an error. */
4742 /* We use char because int might match the return type of a gcc2
4743 builtin and then its argument prototype would still apply. */
4744 char $ac_func();
4746 int main() {
4748 /* The GNU C library defines this for functions which it implements
4749 to always fail with ENOSYS. Some functions are actually named
4750 something starting with __ and the normal name is an alias. */
4751 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
4752 choke me
4753 #else
4754 $ac_func();
4755 #endif
4757 ; return 0; }
4759 if { (eval echo configure:4760: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4760 rm -rf conftest*
4761 eval "ac_cv_func_$ac_func=yes"
4762 else
4763 echo "configure: failed program was:" >&5
4764 cat conftest.$ac_ext >&5
4765 rm -rf conftest*
4766 eval "ac_cv_func_$ac_func=no"
4768 rm -f conftest*
4771 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
4772 echo "$ac_t""yes" 1>&6
4773 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
4774 cat >> confdefs.h <<EOF
4775 #define $ac_tr_func 1
4778 cat >> confdefs.h <<\EOF
4779 #define HAVE_GETHOSTNAME 1
4782 cat > conftest.$ac_ext <<EOF
4783 #line 4784 "configure"
4784 #include "confdefs.h"
4785 #include <unistd.h>
4787 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4788 egrep "gethostname" >/dev/null 2>&1; then
4789 rm -rf conftest*
4791 cat >> confdefs.h <<\EOF
4792 #define HAVE_GETHOSTNAME_DECL 1
4796 rm -f conftest*
4798 else
4799 echo "$ac_t""no" 1>&6
4801 done
4804 # Look for these functions in the thread library, but only bother
4805 # if using POSIX threads.
4806 if test "$THREADS" = posix; then
4807 save_LIBS="$LIBS"
4808 LIBS="$LIBS $THREADLIBS"
4809 # Some POSIX thread systems don't have pthread_mutexattr_settype.
4810 # E.g., Solaris.
4811 for ac_func in pthread_mutexattr_settype pthread_mutexattr_setkind_np
4813 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
4814 echo "configure:4815: checking for $ac_func" >&5
4815 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
4816 echo $ac_n "(cached) $ac_c" 1>&6
4817 else
4818 cat > conftest.$ac_ext <<EOF
4819 #line 4820 "configure"
4820 #include "confdefs.h"
4821 /* System header to define __stub macros and hopefully few prototypes,
4822 which can conflict with char $ac_func(); below. */
4823 #include <assert.h>
4824 /* Override any gcc2 internal prototype to avoid an error. */
4825 /* We use char because int might match the return type of a gcc2
4826 builtin and then its argument prototype would still apply. */
4827 char $ac_func();
4829 int main() {
4831 /* The GNU C library defines this for functions which it implements
4832 to always fail with ENOSYS. Some functions are actually named
4833 something starting with __ and the normal name is an alias. */
4834 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
4835 choke me
4836 #else
4837 $ac_func();
4838 #endif
4840 ; return 0; }
4842 if { (eval echo configure:4843: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4843 rm -rf conftest*
4844 eval "ac_cv_func_$ac_func=yes"
4845 else
4846 echo "configure: failed program was:" >&5
4847 cat conftest.$ac_ext >&5
4848 rm -rf conftest*
4849 eval "ac_cv_func_$ac_func=no"
4851 rm -f conftest*
4854 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
4855 echo "$ac_t""yes" 1>&6
4856 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
4857 cat >> confdefs.h <<EOF
4858 #define $ac_tr_func 1
4861 else
4862 echo "$ac_t""no" 1>&6
4864 done
4867 # Look for sched_yield. Up to Solaris 2.6, it is in libposix4, since
4868 # Solaris 7 the name librt is preferred.
4869 for ac_func in sched_yield
4871 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
4872 echo "configure:4873: checking for $ac_func" >&5
4873 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
4874 echo $ac_n "(cached) $ac_c" 1>&6
4875 else
4876 cat > conftest.$ac_ext <<EOF
4877 #line 4878 "configure"
4878 #include "confdefs.h"
4879 /* System header to define __stub macros and hopefully few prototypes,
4880 which can conflict with char $ac_func(); below. */
4881 #include <assert.h>
4882 /* Override any gcc2 internal prototype to avoid an error. */
4883 /* We use char because int might match the return type of a gcc2
4884 builtin and then its argument prototype would still apply. */
4885 char $ac_func();
4887 int main() {
4889 /* The GNU C library defines this for functions which it implements
4890 to always fail with ENOSYS. Some functions are actually named
4891 something starting with __ and the normal name is an alias. */
4892 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
4893 choke me
4894 #else
4895 $ac_func();
4896 #endif
4898 ; return 0; }
4900 if { (eval echo configure:4901: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4901 rm -rf conftest*
4902 eval "ac_cv_func_$ac_func=yes"
4903 else
4904 echo "configure: failed program was:" >&5
4905 cat conftest.$ac_ext >&5
4906 rm -rf conftest*
4907 eval "ac_cv_func_$ac_func=no"
4909 rm -f conftest*
4912 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
4913 echo "$ac_t""yes" 1>&6
4914 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
4915 cat >> confdefs.h <<EOF
4916 #define $ac_tr_func 1
4919 else
4920 echo "$ac_t""no" 1>&6
4921 echo $ac_n "checking for sched_yield in -lrt""... $ac_c" 1>&6
4922 echo "configure:4923: checking for sched_yield in -lrt" >&5
4923 ac_lib_var=`echo rt'_'sched_yield | sed 'y%./+-%__p_%'`
4924 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4925 echo $ac_n "(cached) $ac_c" 1>&6
4926 else
4927 ac_save_LIBS="$LIBS"
4928 LIBS="-lrt $LIBS"
4929 cat > conftest.$ac_ext <<EOF
4930 #line 4931 "configure"
4931 #include "confdefs.h"
4932 /* Override any gcc2 internal prototype to avoid an error. */
4933 /* We use char because int might match the return type of a gcc2
4934 builtin and then its argument prototype would still apply. */
4935 char sched_yield();
4937 int main() {
4938 sched_yield()
4939 ; return 0; }
4941 if { (eval echo configure:4942: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4942 rm -rf conftest*
4943 eval "ac_cv_lib_$ac_lib_var=yes"
4944 else
4945 echo "configure: failed program was:" >&5
4946 cat conftest.$ac_ext >&5
4947 rm -rf conftest*
4948 eval "ac_cv_lib_$ac_lib_var=no"
4950 rm -f conftest*
4951 LIBS="$ac_save_LIBS"
4954 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4955 echo "$ac_t""yes" 1>&6
4957 cat >> confdefs.h <<\EOF
4958 #define HAVE_SCHED_YIELD 1
4961 THREADLIBS="$THREADLIBS -lrt"
4962 THREADSPEC="$THREADSPEC -lrt"
4963 else
4964 echo "$ac_t""no" 1>&6
4966 echo $ac_n "checking for sched_yield in -lposix4""... $ac_c" 1>&6
4967 echo "configure:4968: checking for sched_yield in -lposix4" >&5
4968 ac_lib_var=`echo posix4'_'sched_yield | sed 'y%./+-%__p_%'`
4969 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4970 echo $ac_n "(cached) $ac_c" 1>&6
4971 else
4972 ac_save_LIBS="$LIBS"
4973 LIBS="-lposix4 $LIBS"
4974 cat > conftest.$ac_ext <<EOF
4975 #line 4976 "configure"
4976 #include "confdefs.h"
4977 /* Override any gcc2 internal prototype to avoid an error. */
4978 /* We use char because int might match the return type of a gcc2
4979 builtin and then its argument prototype would still apply. */
4980 char sched_yield();
4982 int main() {
4983 sched_yield()
4984 ; return 0; }
4986 if { (eval echo configure:4987: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4987 rm -rf conftest*
4988 eval "ac_cv_lib_$ac_lib_var=yes"
4989 else
4990 echo "configure: failed program was:" >&5
4991 cat conftest.$ac_ext >&5
4992 rm -rf conftest*
4993 eval "ac_cv_lib_$ac_lib_var=no"
4995 rm -f conftest*
4996 LIBS="$ac_save_LIBS"
4999 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5000 echo "$ac_t""yes" 1>&6
5002 cat >> confdefs.h <<\EOF
5003 #define HAVE_SCHED_YIELD 1
5006 THREADLIBS="$THREADLIBS -lposix4"
5007 THREADSPEC="$THREADSPEC -lposix4"
5008 else
5009 echo "$ac_t""no" 1>&6
5015 done
5017 LIBS="$save_LIBS"
5019 # We can save a little space at runtime if the mutex has m_count
5020 # or __m_count. This is a nice hack for Linux.
5021 cat > conftest.$ac_ext <<EOF
5022 #line 5023 "configure"
5023 #include "confdefs.h"
5024 #include <pthread.h>
5025 int main() {
5027 extern pthread_mutex_t *mutex; int q = mutex->m_count;
5029 ; return 0; }
5031 if { (eval echo configure:5032: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5032 rm -rf conftest*
5033 cat >> confdefs.h <<\EOF
5034 #define PTHREAD_MUTEX_HAVE_M_COUNT 1
5037 else
5038 echo "configure: failed program was:" >&5
5039 cat conftest.$ac_ext >&5
5040 rm -rf conftest*
5042 cat > conftest.$ac_ext <<EOF
5043 #line 5044 "configure"
5044 #include "confdefs.h"
5045 #include <pthread.h>
5046 int main() {
5048 extern pthread_mutex_t *mutex; int q = mutex->__m_count;
5050 ; return 0; }
5052 if { (eval echo configure:5053: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5053 rm -rf conftest*
5054 cat >> confdefs.h <<\EOF
5055 #define PTHREAD_MUTEX_HAVE___M_COUNT 1
5058 else
5059 echo "configure: failed program was:" >&5
5060 cat conftest.$ac_ext >&5
5062 rm -f conftest*
5064 rm -f conftest*
5067 # We require a way to get the time.
5068 time_found=no
5069 for ac_func in gettimeofday time ftime
5071 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
5072 echo "configure:5073: checking for $ac_func" >&5
5073 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
5074 echo $ac_n "(cached) $ac_c" 1>&6
5075 else
5076 cat > conftest.$ac_ext <<EOF
5077 #line 5078 "configure"
5078 #include "confdefs.h"
5079 /* System header to define __stub macros and hopefully few prototypes,
5080 which can conflict with char $ac_func(); below. */
5081 #include <assert.h>
5082 /* Override any gcc2 internal prototype to avoid an error. */
5083 /* We use char because int might match the return type of a gcc2
5084 builtin and then its argument prototype would still apply. */
5085 char $ac_func();
5087 int main() {
5089 /* The GNU C library defines this for functions which it implements
5090 to always fail with ENOSYS. Some functions are actually named
5091 something starting with __ and the normal name is an alias. */
5092 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5093 choke me
5094 #else
5095 $ac_func();
5096 #endif
5098 ; return 0; }
5100 if { (eval echo configure:5101: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5101 rm -rf conftest*
5102 eval "ac_cv_func_$ac_func=yes"
5103 else
5104 echo "configure: failed program was:" >&5
5105 cat conftest.$ac_ext >&5
5106 rm -rf conftest*
5107 eval "ac_cv_func_$ac_func=no"
5109 rm -f conftest*
5112 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
5113 echo "$ac_t""yes" 1>&6
5114 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
5115 cat >> confdefs.h <<EOF
5116 #define $ac_tr_func 1
5118 time_found=yes
5119 else
5120 echo "$ac_t""no" 1>&6
5122 done
5124 if test "$time_found" = no; then
5125 { echo "configure: error: no function found to get the time" 1>&2; exit 1; }
5128 for ac_func in memmove
5130 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
5131 echo "configure:5132: checking for $ac_func" >&5
5132 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
5133 echo $ac_n "(cached) $ac_c" 1>&6
5134 else
5135 cat > conftest.$ac_ext <<EOF
5136 #line 5137 "configure"
5137 #include "confdefs.h"
5138 /* System header to define __stub macros and hopefully few prototypes,
5139 which can conflict with char $ac_func(); below. */
5140 #include <assert.h>
5141 /* Override any gcc2 internal prototype to avoid an error. */
5142 /* We use char because int might match the return type of a gcc2
5143 builtin and then its argument prototype would still apply. */
5144 char $ac_func();
5146 int main() {
5148 /* The GNU C library defines this for functions which it implements
5149 to always fail with ENOSYS. Some functions are actually named
5150 something starting with __ and the normal name is an alias. */
5151 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5152 choke me
5153 #else
5154 $ac_func();
5155 #endif
5157 ; return 0; }
5159 if { (eval echo configure:5160: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5160 rm -rf conftest*
5161 eval "ac_cv_func_$ac_func=yes"
5162 else
5163 echo "configure: failed program was:" >&5
5164 cat conftest.$ac_ext >&5
5165 rm -rf conftest*
5166 eval "ac_cv_func_$ac_func=no"
5168 rm -f conftest*
5171 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
5172 echo "$ac_t""yes" 1>&6
5173 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
5174 cat >> confdefs.h <<EOF
5175 #define $ac_tr_func 1
5178 else
5179 echo "$ac_t""no" 1>&6
5181 done
5184 # We require memcpy.
5185 memcpy_found=no
5186 for ac_func in memcpy
5188 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
5189 echo "configure:5190: checking for $ac_func" >&5
5190 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
5191 echo $ac_n "(cached) $ac_c" 1>&6
5192 else
5193 cat > conftest.$ac_ext <<EOF
5194 #line 5195 "configure"
5195 #include "confdefs.h"
5196 /* System header to define __stub macros and hopefully few prototypes,
5197 which can conflict with char $ac_func(); below. */
5198 #include <assert.h>
5199 /* Override any gcc2 internal prototype to avoid an error. */
5200 /* We use char because int might match the return type of a gcc2
5201 builtin and then its argument prototype would still apply. */
5202 char $ac_func();
5204 int main() {
5206 /* The GNU C library defines this for functions which it implements
5207 to always fail with ENOSYS. Some functions are actually named
5208 something starting with __ and the normal name is an alias. */
5209 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5210 choke me
5211 #else
5212 $ac_func();
5213 #endif
5215 ; return 0; }
5217 if { (eval echo configure:5218: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5218 rm -rf conftest*
5219 eval "ac_cv_func_$ac_func=yes"
5220 else
5221 echo "configure: failed program was:" >&5
5222 cat conftest.$ac_ext >&5
5223 rm -rf conftest*
5224 eval "ac_cv_func_$ac_func=no"
5226 rm -f conftest*
5229 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
5230 echo "$ac_t""yes" 1>&6
5231 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
5232 cat >> confdefs.h <<EOF
5233 #define $ac_tr_func 1
5235 memcpy_found=yes
5236 else
5237 echo "$ac_t""no" 1>&6
5239 done
5241 if test "$memcpy_found" = no; then
5242 { echo "configure: error: memcpy is required" 1>&2; exit 1; }
5245 echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6
5246 echo "configure:5247: checking for dlopen in -ldl" >&5
5247 ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'`
5248 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
5249 echo $ac_n "(cached) $ac_c" 1>&6
5250 else
5251 ac_save_LIBS="$LIBS"
5252 LIBS="-ldl $LIBS"
5253 cat > conftest.$ac_ext <<EOF
5254 #line 5255 "configure"
5255 #include "confdefs.h"
5256 /* Override any gcc2 internal prototype to avoid an error. */
5257 /* We use char because int might match the return type of a gcc2
5258 builtin and then its argument prototype would still apply. */
5259 char dlopen();
5261 int main() {
5262 dlopen()
5263 ; return 0; }
5265 if { (eval echo configure:5266: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5266 rm -rf conftest*
5267 eval "ac_cv_lib_$ac_lib_var=yes"
5268 else
5269 echo "configure: failed program was:" >&5
5270 cat conftest.$ac_ext >&5
5271 rm -rf conftest*
5272 eval "ac_cv_lib_$ac_lib_var=no"
5274 rm -f conftest*
5275 LIBS="$ac_save_LIBS"
5278 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5279 echo "$ac_t""yes" 1>&6
5281 cat >> confdefs.h <<\EOF
5282 #define HAVE_DLOPEN 1
5285 else
5286 echo "$ac_t""no" 1>&6
5290 # Some library-finding code we stole from Tcl.
5291 #--------------------------------------------------------------------
5292 # Check for the existence of the -lsocket and -lnsl libraries.
5293 # The order here is important, so that they end up in the right
5294 # order in the command line generated by make. Here are some
5295 # special considerations:
5296 # 1. Use "connect" and "accept" to check for -lsocket, and
5297 # "gethostbyname" to check for -lnsl.
5298 # 2. Use each function name only once: can't redo a check because
5299 # autoconf caches the results of the last check and won't redo it.
5300 # 3. Use -lnsl and -lsocket only if they supply procedures that
5301 # aren't already present in the normal libraries. This is because
5302 # IRIX 5.2 has libraries, but they aren't needed and they're
5303 # bogus: they goof up name resolution if used.
5304 # 4. On some SVR4 systems, can't use -lsocket without -lnsl too.
5305 # To get around this problem, check for both libraries together
5306 # if -lsocket doesn't work by itself.
5307 #--------------------------------------------------------------------
5309 echo $ac_n "checking for socket libraries""... $ac_c" 1>&6
5310 echo "configure:5311: checking for socket libraries" >&5
5311 if eval "test \"`echo '$''{'gcj_cv_lib_sockets'+set}'`\" = set"; then
5312 echo $ac_n "(cached) $ac_c" 1>&6
5313 else
5314 gcj_cv_lib_sockets=
5315 gcj_checkBoth=0
5316 unset ac_cv_func_connect
5317 echo $ac_n "checking for connect""... $ac_c" 1>&6
5318 echo "configure:5319: checking for connect" >&5
5319 if eval "test \"`echo '$''{'ac_cv_func_connect'+set}'`\" = set"; then
5320 echo $ac_n "(cached) $ac_c" 1>&6
5321 else
5322 cat > conftest.$ac_ext <<EOF
5323 #line 5324 "configure"
5324 #include "confdefs.h"
5325 /* System header to define __stub macros and hopefully few prototypes,
5326 which can conflict with char connect(); below. */
5327 #include <assert.h>
5328 /* Override any gcc2 internal prototype to avoid an error. */
5329 /* We use char because int might match the return type of a gcc2
5330 builtin and then its argument prototype would still apply. */
5331 char connect();
5333 int main() {
5335 /* The GNU C library defines this for functions which it implements
5336 to always fail with ENOSYS. Some functions are actually named
5337 something starting with __ and the normal name is an alias. */
5338 #if defined (__stub_connect) || defined (__stub___connect)
5339 choke me
5340 #else
5341 connect();
5342 #endif
5344 ; return 0; }
5346 if { (eval echo configure:5347: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5347 rm -rf conftest*
5348 eval "ac_cv_func_connect=yes"
5349 else
5350 echo "configure: failed program was:" >&5
5351 cat conftest.$ac_ext >&5
5352 rm -rf conftest*
5353 eval "ac_cv_func_connect=no"
5355 rm -f conftest*
5358 if eval "test \"`echo '$ac_cv_func_'connect`\" = yes"; then
5359 echo "$ac_t""yes" 1>&6
5360 gcj_checkSocket=0
5361 else
5362 echo "$ac_t""no" 1>&6
5363 gcj_checkSocket=1
5366 if test "$gcj_checkSocket" = 1; then
5367 unset ac_cv_func_connect
5368 echo $ac_n "checking for main in -lsocket""... $ac_c" 1>&6
5369 echo "configure:5370: checking for main in -lsocket" >&5
5370 ac_lib_var=`echo socket'_'main | sed 'y%./+-%__p_%'`
5371 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
5372 echo $ac_n "(cached) $ac_c" 1>&6
5373 else
5374 ac_save_LIBS="$LIBS"
5375 LIBS="-lsocket $LIBS"
5376 cat > conftest.$ac_ext <<EOF
5377 #line 5378 "configure"
5378 #include "confdefs.h"
5380 int main() {
5381 main()
5382 ; return 0; }
5384 if { (eval echo configure:5385: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5385 rm -rf conftest*
5386 eval "ac_cv_lib_$ac_lib_var=yes"
5387 else
5388 echo "configure: failed program was:" >&5
5389 cat conftest.$ac_ext >&5
5390 rm -rf conftest*
5391 eval "ac_cv_lib_$ac_lib_var=no"
5393 rm -f conftest*
5394 LIBS="$ac_save_LIBS"
5397 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5398 echo "$ac_t""yes" 1>&6
5399 gcj_cv_lib_sockets="-lsocket"
5400 else
5401 echo "$ac_t""no" 1>&6
5402 gcj_checkBoth=1
5406 if test "$gcj_checkBoth" = 1; then
5407 gcj_oldLibs=$LIBS
5408 LIBS="$LIBS -lsocket -lnsl"
5409 unset ac_cv_func_accept
5410 echo $ac_n "checking for accept""... $ac_c" 1>&6
5411 echo "configure:5412: checking for accept" >&5
5412 if eval "test \"`echo '$''{'ac_cv_func_accept'+set}'`\" = set"; then
5413 echo $ac_n "(cached) $ac_c" 1>&6
5414 else
5415 cat > conftest.$ac_ext <<EOF
5416 #line 5417 "configure"
5417 #include "confdefs.h"
5418 /* System header to define __stub macros and hopefully few prototypes,
5419 which can conflict with char accept(); below. */
5420 #include <assert.h>
5421 /* Override any gcc2 internal prototype to avoid an error. */
5422 /* We use char because int might match the return type of a gcc2
5423 builtin and then its argument prototype would still apply. */
5424 char accept();
5426 int main() {
5428 /* The GNU C library defines this for functions which it implements
5429 to always fail with ENOSYS. Some functions are actually named
5430 something starting with __ and the normal name is an alias. */
5431 #if defined (__stub_accept) || defined (__stub___accept)
5432 choke me
5433 #else
5434 accept();
5435 #endif
5437 ; return 0; }
5439 if { (eval echo configure:5440: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5440 rm -rf conftest*
5441 eval "ac_cv_func_accept=yes"
5442 else
5443 echo "configure: failed program was:" >&5
5444 cat conftest.$ac_ext >&5
5445 rm -rf conftest*
5446 eval "ac_cv_func_accept=no"
5448 rm -f conftest*
5451 if eval "test \"`echo '$ac_cv_func_'accept`\" = yes"; then
5452 echo "$ac_t""yes" 1>&6
5453 gcj_checkNsl=0
5454 gcj_cv_lib_sockets="-lsocket -lnsl"
5455 else
5456 echo "$ac_t""no" 1>&6
5459 unset ac_cv_func_accept
5460 LIBS=$gcj_oldLibs
5462 unset ac_cv_func_gethostbyname
5463 gcj_oldLibs=$LIBS
5464 LIBS="$LIBS $gcj_cv_lib_sockets"
5465 echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6
5466 echo "configure:5467: checking for gethostbyname" >&5
5467 if eval "test \"`echo '$''{'ac_cv_func_gethostbyname'+set}'`\" = set"; then
5468 echo $ac_n "(cached) $ac_c" 1>&6
5469 else
5470 cat > conftest.$ac_ext <<EOF
5471 #line 5472 "configure"
5472 #include "confdefs.h"
5473 /* System header to define __stub macros and hopefully few prototypes,
5474 which can conflict with char gethostbyname(); below. */
5475 #include <assert.h>
5476 /* Override any gcc2 internal prototype to avoid an error. */
5477 /* We use char because int might match the return type of a gcc2
5478 builtin and then its argument prototype would still apply. */
5479 char gethostbyname();
5481 int main() {
5483 /* The GNU C library defines this for functions which it implements
5484 to always fail with ENOSYS. Some functions are actually named
5485 something starting with __ and the normal name is an alias. */
5486 #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
5487 choke me
5488 #else
5489 gethostbyname();
5490 #endif
5492 ; return 0; }
5494 if { (eval echo configure:5495: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5495 rm -rf conftest*
5496 eval "ac_cv_func_gethostbyname=yes"
5497 else
5498 echo "configure: failed program was:" >&5
5499 cat conftest.$ac_ext >&5
5500 rm -rf conftest*
5501 eval "ac_cv_func_gethostbyname=no"
5503 rm -f conftest*
5506 if eval "test \"`echo '$ac_cv_func_'gethostbyname`\" = yes"; then
5507 echo "$ac_t""yes" 1>&6
5509 else
5510 echo "$ac_t""no" 1>&6
5511 echo $ac_n "checking for main in -lnsl""... $ac_c" 1>&6
5512 echo "configure:5513: checking for main in -lnsl" >&5
5513 ac_lib_var=`echo nsl'_'main | sed 'y%./+-%__p_%'`
5514 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
5515 echo $ac_n "(cached) $ac_c" 1>&6
5516 else
5517 ac_save_LIBS="$LIBS"
5518 LIBS="-lnsl $LIBS"
5519 cat > conftest.$ac_ext <<EOF
5520 #line 5521 "configure"
5521 #include "confdefs.h"
5523 int main() {
5524 main()
5525 ; return 0; }
5527 if { (eval echo configure:5528: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5528 rm -rf conftest*
5529 eval "ac_cv_lib_$ac_lib_var=yes"
5530 else
5531 echo "configure: failed program was:" >&5
5532 cat conftest.$ac_ext >&5
5533 rm -rf conftest*
5534 eval "ac_cv_lib_$ac_lib_var=no"
5536 rm -f conftest*
5537 LIBS="$ac_save_LIBS"
5540 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5541 echo "$ac_t""yes" 1>&6
5542 gcj_cv_lib_sockets="$gcj_cv_lib_sockets -lnsl"
5543 else
5544 echo "$ac_t""no" 1>&6
5549 unset ac_cv_func_gethostbyname
5550 LIBS=$gcj_oldLIBS
5554 echo "$ac_t""$gcj_cv_lib_sockets" 1>&6
5555 SYSTEMSPEC="$SYSTEMSPEC $gcj_cv_lib_sockets"
5557 if test "$with_system_zlib" = yes; then
5558 echo $ac_n "checking for deflate in -lz""... $ac_c" 1>&6
5559 echo "configure:5560: checking for deflate in -lz" >&5
5560 ac_lib_var=`echo z'_'deflate | sed 'y%./+-%__p_%'`
5561 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
5562 echo $ac_n "(cached) $ac_c" 1>&6
5563 else
5564 ac_save_LIBS="$LIBS"
5565 LIBS="-lz $LIBS"
5566 cat > conftest.$ac_ext <<EOF
5567 #line 5568 "configure"
5568 #include "confdefs.h"
5569 /* Override any gcc2 internal prototype to avoid an error. */
5570 /* We use char because int might match the return type of a gcc2
5571 builtin and then its argument prototype would still apply. */
5572 char deflate();
5574 int main() {
5575 deflate()
5576 ; return 0; }
5578 if { (eval echo configure:5579: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5579 rm -rf conftest*
5580 eval "ac_cv_lib_$ac_lib_var=yes"
5581 else
5582 echo "configure: failed program was:" >&5
5583 cat conftest.$ac_ext >&5
5584 rm -rf conftest*
5585 eval "ac_cv_lib_$ac_lib_var=no"
5587 rm -f conftest*
5588 LIBS="$ac_save_LIBS"
5591 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5592 echo "$ac_t""yes" 1>&6
5593 ZLIBSPEC=-lz
5594 else
5595 echo "$ac_t""no" 1>&6
5596 ZLIBSPEC=
5601 # On Solaris, and maybe other architectures, the Boehm collector
5602 # requires -ldl.
5603 if test "$GC" = boehm; then
5604 echo $ac_n "checking for main in -ldl""... $ac_c" 1>&6
5605 echo "configure:5606: checking for main in -ldl" >&5
5606 ac_lib_var=`echo dl'_'main | sed 'y%./+-%__p_%'`
5607 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
5608 echo $ac_n "(cached) $ac_c" 1>&6
5609 else
5610 ac_save_LIBS="$LIBS"
5611 LIBS="-ldl $LIBS"
5612 cat > conftest.$ac_ext <<EOF
5613 #line 5614 "configure"
5614 #include "confdefs.h"
5616 int main() {
5617 main()
5618 ; return 0; }
5620 if { (eval echo configure:5621: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5621 rm -rf conftest*
5622 eval "ac_cv_lib_$ac_lib_var=yes"
5623 else
5624 echo "configure: failed program was:" >&5
5625 cat conftest.$ac_ext >&5
5626 rm -rf conftest*
5627 eval "ac_cv_lib_$ac_lib_var=no"
5629 rm -f conftest*
5630 LIBS="$ac_save_LIBS"
5633 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5634 echo "$ac_t""yes" 1>&6
5635 SYSTEMSPEC="$SYSTEMSPEC -ldl"
5636 else
5637 echo "$ac_t""no" 1>&6
5642 if test -z "${with_multisubdir}"; then
5643 builddotdot=.
5644 else
5646 builddotdot=`echo ${with_multisubdir} | sed -e 's:[^/][^/]*:..:g'`
5650 # If Canadian cross, then don't pick up tools from the build
5651 # directory.
5652 if test x"$build" != x"$with_cross_host" -a x"$build" != x"$target"; then
5653 CANADIAN=yes
5654 GCC_UNWIND_INCLUDE=
5655 GCJ="${target_alias}-gcj"
5656 elif test -x "${builddotdot}/../../gcc/gcj"; then
5657 dir="`cd ${builddotdot}/../../gcc && pwd`"
5658 GCJ="$dir/gcj -B`pwd`/ -B$dir/"
5659 else
5660 CANADIAN=yes
5661 NULL_TARGET=yes
5662 GCJ="gcj -B`pwd`/"
5666 # Create it, so that compile/link tests don't fail
5667 test -f libgcj.spec || touch libgcj.spec
5669 # We must search the source tree for java.lang, since we still don't
5670 # have libgcj.jar nor java/lang/*.class
5671 GCJ_SAVE_CPPFLAGS=$CPPFLAGS
5672 CPPFLAGS="$CPPFLAGS -I`pwd` -I`cd $srcdir && pwd`"
5674 # Since some classes depend on this one, we need its source available
5675 # before we can do any GCJ compilation test :-(
5676 if test ! -f gnu/classpath/Configuration.java; then
5677 test -d gnu || mkdir gnu
5678 test -d gnu/classpath || mkdir gnu/classpath
5679 sed 's,@LIBGCJDEBUG@,$LIBGCJDEBUG,' \
5680 < $srcdir/gnu/classpath/Configuration.java.in \
5681 > gnu/classpath/Configuration.java
5682 # We do not want to redirect the output of the grep below to /dev/null,
5683 # but we add /dev/null to the input list so that grep will print the
5684 # filename of Configuration.java in case it finds any matches.
5685 if grep @ gnu/classpath/Configuration.java /dev/null; then
5686 { echo "configure: error: configure.in is missing the substitutions above" 1>&2; exit 1; }
5690 # Extract the first word of "${ac_tool_prefix}gcj", so it can be a program name with args.
5691 set dummy ${ac_tool_prefix}gcj; ac_word=$2
5692 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5693 echo "configure:5695: checking for $ac_word" >&5
5694 if eval "test \"`echo '$''{'ac_cv_prog_GCJ'+set}'`\" = set"; then
5695 echo $ac_n "(cached) $ac_c" 1>&6
5696 else
5697 if test -n "$GCJ"; then
5698 ac_cv_prog_GCJ="$GCJ" # Let the user override the test.
5699 else
5700 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5701 ac_dummy="$PATH"
5702 for ac_dir in $ac_dummy; do
5703 test -z "$ac_dir" && ac_dir=.
5704 if test -f $ac_dir/$ac_word; then
5705 ac_cv_prog_GCJ="${ac_tool_prefix}gcj"
5706 break
5708 done
5709 IFS="$ac_save_ifs"
5712 GCJ="$ac_cv_prog_GCJ"
5713 if test -n "$GCJ"; then
5714 echo "$ac_t""$GCJ" 1>&6
5715 else
5716 echo "$ac_t""no" 1>&6
5720 if test -z "$ac_cv_prog_GCJ"; then
5721 if test -n "$ac_tool_prefix"; then
5722 # Extract the first word of "gcj", so it can be a program name with args.
5723 set dummy gcj; ac_word=$2
5724 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5725 echo "configure:5727: checking for $ac_word" >&5
5726 if eval "test \"`echo '$''{'ac_cv_prog_GCJ'+set}'`\" = set"; then
5727 echo $ac_n "(cached) $ac_c" 1>&6
5728 else
5729 if test -n "$GCJ"; then
5730 ac_cv_prog_GCJ="$GCJ" # Let the user override the test.
5731 else
5732 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5733 ac_dummy="$PATH"
5734 for ac_dir in $ac_dummy; do
5735 test -z "$ac_dir" && ac_dir=.
5736 if test -f $ac_dir/$ac_word; then
5737 ac_cv_prog_GCJ="gcj"
5738 break
5740 done
5741 IFS="$ac_save_ifs"
5742 test -z "$ac_cv_prog_GCJ" && ac_cv_prog_GCJ="no"
5745 GCJ="$ac_cv_prog_GCJ"
5746 if test -n "$GCJ"; then
5747 echo "$ac_t""$GCJ" 1>&6
5748 else
5749 echo "$ac_t""no" 1>&6
5752 else
5753 GCJ="no"
5757 test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2"
5761 LIBTOOL_DEPS=$LIBTOOL_DEPS" $ac_aux_dir/ltcf-gcj.sh"
5762 lt_save_CC="$CC"
5763 lt_save_CFLAGS="$CFLAGS"
5764 AR="$AR" LTCC="$CC" CC="$GCJ" CFLAGS="$GCJFLAGS" CPPFLAGS="$CPPFLAGS" \
5765 MAGIC_CMD="$MAGIC_CMD" LD="$LD" LDFLAGS="$LDFLAGS" LIBS="$LIBS" \
5766 LN_S="$LN_S" NM="$NM" RANLIB="$RANLIB" STRIP="$STRIP" \
5767 AS="$AS" DLLTOOL="$DLLTOOL" OBJDUMP="$OBJDUMP" \
5768 objext="$OBJEXT" exeext="$EXEEXT" reload_flag="$reload_flag" \
5769 deplibs_check_method="$deplibs_check_method" \
5770 file_magic_cmd="$file_magic_cmd" \
5771 ${CONFIG_SHELL-/bin/sh} $ac_aux_dir/ltconfig -o libtool $libtool_flags \
5772 --build="$build" --add-tag=GCJ $ac_aux_dir/ltcf-gcj.sh $host \
5773 || { echo "configure: error: libtool tag configuration failed" 1>&2; exit 1; }
5774 CC="$lt_save_CC"
5775 CFLAGS="$lt_save_CFLAGS"
5777 # Redirect the config.log output again, so that the ltconfig log is not
5778 # clobbered by the next message.
5779 exec 5>>./config.log
5784 CPPFLAGS=$GCJ_SAVE_CPPFLAGS
5786 echo $ac_n "checking size of void *""... $ac_c" 1>&6
5787 echo "configure:5789: checking size of void *" >&5
5788 if eval "test \"`echo '$''{'ac_cv_sizeof_void_p'+set}'`\" = set"; then
5789 echo $ac_n "(cached) $ac_c" 1>&6
5790 else
5791 for ac_size in 4 8 1 2 16 12 ; do # List sizes in rough order of prevalence.
5792 cat > conftest.$ac_ext <<EOF
5793 #line 5795 "configure"
5794 #include "confdefs.h"
5795 #include "confdefs.h"
5796 #include <sys/types.h>
5799 int main() {
5800 switch (0) case 0: case (sizeof (void *) == $ac_size):;
5801 ; return 0; }
5803 if { (eval echo configure:5805: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5804 rm -rf conftest*
5805 ac_cv_sizeof_void_p=$ac_size
5806 else
5807 echo "configure: failed program was:" >&5
5808 cat conftest.$ac_ext >&5
5810 rm -f conftest*
5811 if test x$ac_cv_sizeof_void_p != x ; then break; fi
5812 done
5816 if test x$ac_cv_sizeof_void_p = x ; then
5817 { echo "configure: error: cannot determine a size for void *" 1>&2; exit 1; }
5819 echo "$ac_t""$ac_cv_sizeof_void_p" 1>&6
5820 cat >> confdefs.h <<EOF
5821 #define SIZEOF_VOID_P $ac_cv_sizeof_void_p
5826 ZLIBS=
5827 SYS_ZLIBS=
5828 ZINCS=
5830 if test -z "$ZLIBSPEC"; then
5831 # Use zlib from the GCC tree.
5832 ZINCS='-I$(top_srcdir)/../zlib'
5833 ZLIBS=../zlib/libzgcj_convenience.la
5834 else
5835 # System's zlib.
5836 SYS_ZLIBS="$ZLIBSPEC"
5847 if test "$CANADIAN" = yes; then
5848 CANADIAN_TRUE=
5849 CANADIAN_FALSE='#'
5850 else
5851 CANADIAN_TRUE='#'
5852 CANADIAN_FALSE=
5856 if test "$NULL_TARGET" = yes; then
5857 NULL_TARGET_TRUE=
5858 NULL_TARGET_FALSE='#'
5859 else
5860 NULL_TARGET_TRUE='#'
5861 NULL_TARGET_FALSE=
5865 if test "$NATIVE" = yes || test "$NULL_TARGET" = yes; then
5866 NATIVE_TRUE=
5867 NATIVE_FALSE='#'
5868 else
5869 NATIVE_TRUE='#'
5870 NATIVE_FALSE=
5874 if test -z "$with_cross_host"; then
5875 USE_LIBDIR_TRUE=
5876 USE_LIBDIR_FALSE='#'
5877 else
5878 USE_LIBDIR_TRUE='#'
5879 USE_LIBDIR_FALSE=
5883 if test "$NEEDS_DATA_START" = yes && test "$NATIVE" = yes; then
5884 NEEDS_DATA_START_TRUE=
5885 NEEDS_DATA_START_FALSE='#'
5886 else
5887 NEEDS_DATA_START_TRUE='#'
5888 NEEDS_DATA_START_FALSE=
5894 # Determine gcj version number.
5896 gcjversion=`$GCJ -v 2>&1 | sed -n 's/^.*version \([^ ]*\).*$/\1/p'`
5898 GCJVERSION=$gcjversion
5900 cat >> confdefs.h <<EOF
5901 #define GCJVERSION "$GCJVERSION"
5905 echo $ac_n "checking for g++ -ffloat-store bug""... $ac_c" 1>&6
5906 echo "configure:5908: checking for g++ -ffloat-store bug" >&5
5907 save_CFLAGS="$CFLAGS"
5908 CFLAGS="-x c++ -O2 -ffloat-store"
5909 cat > conftest.$ac_ext <<EOF
5910 #line 5912 "configure"
5911 #include "confdefs.h"
5912 #include <math.h>
5913 int main() {
5915 ; return 0; }
5917 if { (eval echo configure:5919: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5918 rm -rf conftest*
5919 echo "$ac_t""no" 1>&6
5920 else
5921 echo "configure: failed program was:" >&5
5922 cat conftest.$ac_ext >&5
5923 rm -rf conftest*
5924 cat >> confdefs.h <<\EOF
5925 #define __NO_MATH_INLINES 1
5928 echo "$ac_t""yes" 1>&6
5930 rm -f conftest*
5931 CFLAGS="$save_CFLAGS"
5933 for ac_hdr in unistd.h bstring.h sys/time.h sys/types.h fcntl.h sys/ioctl.h sys/filio.h sys/stat.h sys/select.h sys/socket.h netinet/in.h arpa/inet.h netdb.h pwd.h sys/config.h stdint.h langinfo.h locale.h
5935 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
5936 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
5937 echo "configure:5939: checking for $ac_hdr" >&5
5938 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
5939 echo $ac_n "(cached) $ac_c" 1>&6
5940 else
5941 cat > conftest.$ac_ext <<EOF
5942 #line 5944 "configure"
5943 #include "confdefs.h"
5944 #include <$ac_hdr>
5946 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5947 { (eval echo configure:5949: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5948 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5949 if test -z "$ac_err"; then
5950 rm -rf conftest*
5951 eval "ac_cv_header_$ac_safe=yes"
5952 else
5953 echo "$ac_err" >&5
5954 echo "configure: failed program was:" >&5
5955 cat conftest.$ac_ext >&5
5956 rm -rf conftest*
5957 eval "ac_cv_header_$ac_safe=no"
5959 rm -f conftest*
5961 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
5962 echo "$ac_t""yes" 1>&6
5963 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
5964 cat >> confdefs.h <<EOF
5965 #define $ac_tr_hdr 1
5968 else
5969 echo "$ac_t""no" 1>&6
5971 done
5973 for ac_hdr in dirent.h
5975 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
5976 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
5977 echo "configure:5979: checking for $ac_hdr" >&5
5978 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
5979 echo $ac_n "(cached) $ac_c" 1>&6
5980 else
5981 cat > conftest.$ac_ext <<EOF
5982 #line 5984 "configure"
5983 #include "confdefs.h"
5984 #include <$ac_hdr>
5986 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5987 { (eval echo configure:5989: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5988 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5989 if test -z "$ac_err"; then
5990 rm -rf conftest*
5991 eval "ac_cv_header_$ac_safe=yes"
5992 else
5993 echo "$ac_err" >&5
5994 echo "configure: failed program was:" >&5
5995 cat conftest.$ac_ext >&5
5996 rm -rf conftest*
5997 eval "ac_cv_header_$ac_safe=no"
5999 rm -f conftest*
6001 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
6002 echo "$ac_t""yes" 1>&6
6003 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
6004 cat >> confdefs.h <<EOF
6005 #define $ac_tr_hdr 1
6008 else
6009 echo "$ac_t""no" 1>&6
6011 done
6013 for ac_hdr in inttypes.h
6015 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
6016 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
6017 echo "configure:6019: checking for $ac_hdr" >&5
6018 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
6019 echo $ac_n "(cached) $ac_c" 1>&6
6020 else
6021 cat > conftest.$ac_ext <<EOF
6022 #line 6024 "configure"
6023 #include "confdefs.h"
6024 #include <$ac_hdr>
6026 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
6027 { (eval echo configure:6029: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
6028 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
6029 if test -z "$ac_err"; then
6030 rm -rf conftest*
6031 eval "ac_cv_header_$ac_safe=yes"
6032 else
6033 echo "$ac_err" >&5
6034 echo "configure: failed program was:" >&5
6035 cat conftest.$ac_ext >&5
6036 rm -rf conftest*
6037 eval "ac_cv_header_$ac_safe=no"
6039 rm -f conftest*
6041 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
6042 echo "$ac_t""yes" 1>&6
6043 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
6044 cat >> confdefs.h <<EOF
6045 #define $ac_tr_hdr 1
6048 cat >> confdefs.h <<\EOF
6049 #define HAVE_INTTYPES_H 1
6052 cat >> confdefs.h <<\EOF
6053 #define JV_HAVE_INTTYPES_H 1
6057 else
6058 echo "$ac_t""no" 1>&6
6060 done
6062 echo $ac_n "checking for sys/wait.h that is POSIX.1 compatible""... $ac_c" 1>&6
6063 echo "configure:6065: checking for sys/wait.h that is POSIX.1 compatible" >&5
6064 if eval "test \"`echo '$''{'ac_cv_header_sys_wait_h'+set}'`\" = set"; then
6065 echo $ac_n "(cached) $ac_c" 1>&6
6066 else
6067 cat > conftest.$ac_ext <<EOF
6068 #line 6070 "configure"
6069 #include "confdefs.h"
6070 #include <sys/types.h>
6071 #include <sys/wait.h>
6072 #ifndef WEXITSTATUS
6073 #define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
6074 #endif
6075 #ifndef WIFEXITED
6076 #define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
6077 #endif
6078 int main() {
6079 int s;
6080 wait (&s);
6081 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
6082 ; return 0; }
6084 if { (eval echo configure:6086: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6085 rm -rf conftest*
6086 ac_cv_header_sys_wait_h=yes
6087 else
6088 echo "configure: failed program was:" >&5
6089 cat conftest.$ac_ext >&5
6090 rm -rf conftest*
6091 ac_cv_header_sys_wait_h=no
6093 rm -f conftest*
6096 echo "$ac_t""$ac_cv_header_sys_wait_h" 1>&6
6097 if test $ac_cv_header_sys_wait_h = yes; then
6098 cat >> confdefs.h <<\EOF
6099 #define HAVE_SYS_WAIT_H 1
6105 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
6106 echo "configure:6108: checking for ANSI C header files" >&5
6107 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
6108 echo $ac_n "(cached) $ac_c" 1>&6
6109 else
6110 cat > conftest.$ac_ext <<EOF
6111 #line 6113 "configure"
6112 #include "confdefs.h"
6113 #include <stdlib.h>
6114 #include <stdarg.h>
6115 #include <string.h>
6116 #include <float.h>
6118 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
6119 { (eval echo configure:6121: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
6120 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
6121 if test -z "$ac_err"; then
6122 rm -rf conftest*
6123 ac_cv_header_stdc=yes
6124 else
6125 echo "$ac_err" >&5
6126 echo "configure: failed program was:" >&5
6127 cat conftest.$ac_ext >&5
6128 rm -rf conftest*
6129 ac_cv_header_stdc=no
6131 rm -f conftest*
6133 if test $ac_cv_header_stdc = yes; then
6134 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6135 cat > conftest.$ac_ext <<EOF
6136 #line 6138 "configure"
6137 #include "confdefs.h"
6138 #include <string.h>
6140 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6141 egrep "memchr" >/dev/null 2>&1; then
6143 else
6144 rm -rf conftest*
6145 ac_cv_header_stdc=no
6147 rm -f conftest*
6151 if test $ac_cv_header_stdc = yes; then
6152 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6153 cat > conftest.$ac_ext <<EOF
6154 #line 6156 "configure"
6155 #include "confdefs.h"
6156 #include <stdlib.h>
6158 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6159 egrep "free" >/dev/null 2>&1; then
6161 else
6162 rm -rf conftest*
6163 ac_cv_header_stdc=no
6165 rm -f conftest*
6169 if test $ac_cv_header_stdc = yes; then
6170 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6171 if test "$cross_compiling" = yes; then
6173 else
6174 cat > conftest.$ac_ext <<EOF
6175 #line 6177 "configure"
6176 #include "confdefs.h"
6177 #include <ctype.h>
6178 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6179 #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6180 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6181 int main () { int i; for (i = 0; i < 256; i++)
6182 if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
6183 exit (0); }
6186 if { (eval echo configure:6188: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
6187 then
6189 else
6190 echo "configure: failed program was:" >&5
6191 cat conftest.$ac_ext >&5
6192 rm -fr conftest*
6193 ac_cv_header_stdc=no
6195 rm -fr conftest*
6201 echo "$ac_t""$ac_cv_header_stdc" 1>&6
6202 if test $ac_cv_header_stdc = yes; then
6203 cat >> confdefs.h <<\EOF
6204 #define STDC_HEADERS 1
6209 echo $ac_n "checking for ssize_t""... $ac_c" 1>&6
6210 echo "configure:6212: checking for ssize_t" >&5
6211 if eval "test \"`echo '$''{'ac_cv_type_ssize_t'+set}'`\" = set"; then
6212 echo $ac_n "(cached) $ac_c" 1>&6
6213 else
6214 cat > conftest.$ac_ext <<EOF
6215 #line 6217 "configure"
6216 #include "confdefs.h"
6217 #include <sys/types.h>
6218 #if STDC_HEADERS
6219 #include <stdlib.h>
6220 #include <stddef.h>
6221 #endif
6223 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6224 egrep "(^|[^a-zA-Z_0-9])ssize_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
6225 rm -rf conftest*
6226 ac_cv_type_ssize_t=yes
6227 else
6228 rm -rf conftest*
6229 ac_cv_type_ssize_t=no
6231 rm -f conftest*
6234 echo "$ac_t""$ac_cv_type_ssize_t" 1>&6
6235 if test $ac_cv_type_ssize_t = no; then
6236 cat >> confdefs.h <<\EOF
6237 #define ssize_t int
6243 echo $ac_n "checking for in_addr_t""... $ac_c" 1>&6
6244 echo "configure:6246: checking for in_addr_t" >&5
6245 cat > conftest.$ac_ext <<EOF
6246 #line 6248 "configure"
6247 #include "confdefs.h"
6248 #include <sys/types.h>
6249 #if STDC_HEADERS
6250 #include <stdlib.h>
6251 #include <stddef.h>
6252 #endif
6253 #if HAVE_NETINET_IN_H
6254 #include <netinet/in.h>
6255 #endif
6256 int main() {
6257 in_addr_t foo;
6258 ; return 0; }
6260 if { (eval echo configure:6262: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6261 rm -rf conftest*
6262 cat >> confdefs.h <<\EOF
6263 #define HAVE_IN_ADDR_T 1
6266 echo "$ac_t""yes" 1>&6
6267 else
6268 echo "configure: failed program was:" >&5
6269 cat conftest.$ac_ext >&5
6270 rm -rf conftest*
6271 echo "$ac_t""no" 1>&6
6273 rm -f conftest*
6275 echo $ac_n "checking whether struct ip_mreq is in netinet/in.h""... $ac_c" 1>&6
6276 echo "configure:6278: checking whether struct ip_mreq is in netinet/in.h" >&5
6277 cat > conftest.$ac_ext <<EOF
6278 #line 6280 "configure"
6279 #include "confdefs.h"
6280 #include <netinet/in.h>
6281 int main() {
6282 struct ip_mreq mreq;
6283 ; return 0; }
6285 if { (eval echo configure:6287: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6286 rm -rf conftest*
6287 cat >> confdefs.h <<\EOF
6288 #define HAVE_STRUCT_IP_MREQ 1
6291 echo "$ac_t""yes" 1>&6
6292 else
6293 echo "configure: failed program was:" >&5
6294 cat conftest.$ac_ext >&5
6295 rm -rf conftest*
6296 echo "$ac_t""no" 1>&6
6298 rm -f conftest*
6300 echo $ac_n "checking whether struct ipv6_mreq is in netinet/in.h""... $ac_c" 1>&6
6301 echo "configure:6303: checking whether struct ipv6_mreq is in netinet/in.h" >&5
6302 cat > conftest.$ac_ext <<EOF
6303 #line 6305 "configure"
6304 #include "confdefs.h"
6305 #include <netinet/in.h>
6306 int main() {
6307 struct ipv6_mreq mreq6;
6308 ; return 0; }
6310 if { (eval echo configure:6312: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6311 rm -rf conftest*
6312 cat >> confdefs.h <<\EOF
6313 #define HAVE_STRUCT_IPV6_MREQ 1
6316 echo "$ac_t""yes" 1>&6
6317 else
6318 echo "configure: failed program was:" >&5
6319 cat conftest.$ac_ext >&5
6320 rm -rf conftest*
6321 echo "$ac_t""no" 1>&6
6323 rm -f conftest*
6325 echo $ac_n "checking whether struct sockaddr_in6 is in netinet/in.h""... $ac_c" 1>&6
6326 echo "configure:6328: checking whether struct sockaddr_in6 is in netinet/in.h" >&5
6327 cat > conftest.$ac_ext <<EOF
6328 #line 6330 "configure"
6329 #include "confdefs.h"
6330 #include <netinet/in.h>
6331 int main() {
6332 struct sockaddr_in6 addr6;
6333 ; return 0; }
6335 if { (eval echo configure:6337: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6336 rm -rf conftest*
6337 cat >> confdefs.h <<\EOF
6338 #define HAVE_INET6 1
6341 echo "$ac_t""yes" 1>&6
6342 else
6343 echo "configure: failed program was:" >&5
6344 cat conftest.$ac_ext >&5
6345 rm -rf conftest*
6346 echo "$ac_t""no" 1>&6
6348 rm -f conftest*
6350 echo $ac_n "checking for socklen_t in sys/socket.h""... $ac_c" 1>&6
6351 echo "configure:6353: checking for socklen_t in sys/socket.h" >&5
6352 cat > conftest.$ac_ext <<EOF
6353 #line 6355 "configure"
6354 #include "confdefs.h"
6355 #define _POSIX_PII_SOCKET
6356 #include <sys/types.h>
6357 #include <sys/socket.h>
6358 int main() {
6359 socklen_t x = 5;
6360 ; return 0; }
6362 if { (eval echo configure:6364: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6363 rm -rf conftest*
6364 cat >> confdefs.h <<\EOF
6365 #define HAVE_SOCKLEN_T 1
6368 echo "$ac_t""yes" 1>&6
6369 else
6370 echo "configure: failed program was:" >&5
6371 cat conftest.$ac_ext >&5
6372 rm -rf conftest*
6373 echo "$ac_t""no" 1>&6
6375 rm -f conftest*
6377 echo $ac_n "checking for tm_gmtoff in struct tm""... $ac_c" 1>&6
6378 echo "configure:6380: checking for tm_gmtoff in struct tm" >&5
6379 cat > conftest.$ac_ext <<EOF
6380 #line 6382 "configure"
6381 #include "confdefs.h"
6382 #include <time.h>
6383 int main() {
6384 struct tm tim; tim.tm_gmtoff = 0;
6385 ; return 0; }
6387 if { (eval echo configure:6389: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6388 rm -rf conftest*
6389 cat >> confdefs.h <<\EOF
6390 #define STRUCT_TM_HAS_GMTOFF 1
6393 echo "$ac_t""yes" 1>&6
6394 else
6395 echo "configure: failed program was:" >&5
6396 cat conftest.$ac_ext >&5
6397 rm -rf conftest*
6398 echo "$ac_t""no" 1>&6
6399 echo $ac_n "checking for global timezone variable""... $ac_c" 1>&6
6400 echo "configure:6402: checking for global timezone variable" >&5
6401 cat > conftest.$ac_ext <<EOF
6402 #line 6404 "configure"
6403 #include "confdefs.h"
6404 #include <time.h>
6405 int main() {
6406 long z2 = timezone;
6407 ; return 0; }
6409 if { (eval echo configure:6411: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6410 rm -rf conftest*
6411 cat >> confdefs.h <<\EOF
6412 #define HAVE_TIMEZONE 1
6415 echo "$ac_t""yes" 1>&6
6416 else
6417 echo "configure: failed program was:" >&5
6418 cat conftest.$ac_ext >&5
6419 rm -rf conftest*
6420 echo "$ac_t""no" 1>&6
6422 rm -f conftest*
6424 rm -f conftest*
6426 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
6427 # for constant arguments. Useless!
6428 echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
6429 echo "configure:6431: checking for working alloca.h" >&5
6430 if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
6431 echo $ac_n "(cached) $ac_c" 1>&6
6432 else
6433 cat > conftest.$ac_ext <<EOF
6434 #line 6436 "configure"
6435 #include "confdefs.h"
6436 #include <alloca.h>
6437 int main() {
6438 char *p = alloca(2 * sizeof(int));
6439 ; return 0; }
6441 if { (eval echo configure:6443: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6442 rm -rf conftest*
6443 ac_cv_header_alloca_h=yes
6444 else
6445 echo "configure: failed program was:" >&5
6446 cat conftest.$ac_ext >&5
6447 rm -rf conftest*
6448 ac_cv_header_alloca_h=no
6450 rm -f conftest*
6453 echo "$ac_t""$ac_cv_header_alloca_h" 1>&6
6454 if test $ac_cv_header_alloca_h = yes; then
6455 cat >> confdefs.h <<\EOF
6456 #define HAVE_ALLOCA_H 1
6461 echo $ac_n "checking for alloca""... $ac_c" 1>&6
6462 echo "configure:6464: checking for alloca" >&5
6463 if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
6464 echo $ac_n "(cached) $ac_c" 1>&6
6465 else
6466 cat > conftest.$ac_ext <<EOF
6467 #line 6469 "configure"
6468 #include "confdefs.h"
6470 #ifdef __GNUC__
6471 # define alloca __builtin_alloca
6472 #else
6473 # ifdef _MSC_VER
6474 # include <malloc.h>
6475 # define alloca _alloca
6476 # else
6477 # if HAVE_ALLOCA_H
6478 # include <alloca.h>
6479 # else
6480 # ifdef _AIX
6481 #pragma alloca
6482 # else
6483 # ifndef alloca /* predefined by HP cc +Olibcalls */
6484 char *alloca ();
6485 # endif
6486 # endif
6487 # endif
6488 # endif
6489 #endif
6491 int main() {
6492 char *p = (char *) alloca(1);
6493 ; return 0; }
6495 if { (eval echo configure:6497: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6496 rm -rf conftest*
6497 ac_cv_func_alloca_works=yes
6498 else
6499 echo "configure: failed program was:" >&5
6500 cat conftest.$ac_ext >&5
6501 rm -rf conftest*
6502 ac_cv_func_alloca_works=no
6504 rm -f conftest*
6507 echo "$ac_t""$ac_cv_func_alloca_works" 1>&6
6508 if test $ac_cv_func_alloca_works = yes; then
6509 cat >> confdefs.h <<\EOF
6510 #define HAVE_ALLOCA 1
6515 if test $ac_cv_func_alloca_works = no; then
6516 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
6517 # that cause trouble. Some versions do not even contain alloca or
6518 # contain a buggy version. If you still want to use their alloca,
6519 # use ar to extract alloca.o from them instead of compiling alloca.c.
6520 ALLOCA=alloca.${ac_objext}
6521 cat >> confdefs.h <<\EOF
6522 #define C_ALLOCA 1
6526 echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
6527 echo "configure:6529: checking whether alloca needs Cray hooks" >&5
6528 if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
6529 echo $ac_n "(cached) $ac_c" 1>&6
6530 else
6531 cat > conftest.$ac_ext <<EOF
6532 #line 6534 "configure"
6533 #include "confdefs.h"
6534 #if defined(CRAY) && ! defined(CRAY2)
6535 webecray
6536 #else
6537 wenotbecray
6538 #endif
6541 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6542 egrep "webecray" >/dev/null 2>&1; then
6543 rm -rf conftest*
6544 ac_cv_os_cray=yes
6545 else
6546 rm -rf conftest*
6547 ac_cv_os_cray=no
6549 rm -f conftest*
6553 echo "$ac_t""$ac_cv_os_cray" 1>&6
6554 if test $ac_cv_os_cray = yes; then
6555 for ac_func in _getb67 GETB67 getb67; do
6556 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
6557 echo "configure:6559: checking for $ac_func" >&5
6558 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
6559 echo $ac_n "(cached) $ac_c" 1>&6
6560 else
6561 cat > conftest.$ac_ext <<EOF
6562 #line 6564 "configure"
6563 #include "confdefs.h"
6564 /* System header to define __stub macros and hopefully few prototypes,
6565 which can conflict with char $ac_func(); below. */
6566 #include <assert.h>
6567 /* Override any gcc2 internal prototype to avoid an error. */
6568 /* We use char because int might match the return type of a gcc2
6569 builtin and then its argument prototype would still apply. */
6570 char $ac_func();
6572 int main() {
6574 /* The GNU C library defines this for functions which it implements
6575 to always fail with ENOSYS. Some functions are actually named
6576 something starting with __ and the normal name is an alias. */
6577 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
6578 choke me
6579 #else
6580 $ac_func();
6581 #endif
6583 ; return 0; }
6585 if { (eval echo configure:6587: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6586 rm -rf conftest*
6587 eval "ac_cv_func_$ac_func=yes"
6588 else
6589 echo "configure: failed program was:" >&5
6590 cat conftest.$ac_ext >&5
6591 rm -rf conftest*
6592 eval "ac_cv_func_$ac_func=no"
6594 rm -f conftest*
6597 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
6598 echo "$ac_t""yes" 1>&6
6599 cat >> confdefs.h <<EOF
6600 #define CRAY_STACKSEG_END $ac_func
6603 break
6604 else
6605 echo "$ac_t""no" 1>&6
6608 done
6611 echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
6612 echo "configure:6614: checking stack direction for C alloca" >&5
6613 if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
6614 echo $ac_n "(cached) $ac_c" 1>&6
6615 else
6616 if test "$cross_compiling" = yes; then
6617 ac_cv_c_stack_direction=0
6618 else
6619 cat > conftest.$ac_ext <<EOF
6620 #line 6622 "configure"
6621 #include "confdefs.h"
6622 find_stack_direction ()
6624 static char *addr = 0;
6625 auto char dummy;
6626 if (addr == 0)
6628 addr = &dummy;
6629 return find_stack_direction ();
6631 else
6632 return (&dummy > addr) ? 1 : -1;
6634 main ()
6636 exit (find_stack_direction() < 0);
6639 if { (eval echo configure:6641: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
6640 then
6641 ac_cv_c_stack_direction=1
6642 else
6643 echo "configure: failed program was:" >&5
6644 cat conftest.$ac_ext >&5
6645 rm -fr conftest*
6646 ac_cv_c_stack_direction=-1
6648 rm -fr conftest*
6653 echo "$ac_t""$ac_cv_c_stack_direction" 1>&6
6654 cat >> confdefs.h <<EOF
6655 #define STACK_DIRECTION $ac_cv_c_stack_direction
6661 for ac_prog in perl
6663 # Extract the first word of "$ac_prog", so it can be a program name with args.
6664 set dummy $ac_prog; ac_word=$2
6665 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
6666 echo "configure:6668: checking for $ac_word" >&5
6667 if eval "test \"`echo '$''{'ac_cv_prog_PERL'+set}'`\" = set"; then
6668 echo $ac_n "(cached) $ac_c" 1>&6
6669 else
6670 if test -n "$PERL"; then
6671 ac_cv_prog_PERL="$PERL" # Let the user override the test.
6672 else
6673 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6674 ac_dummy="$PATH"
6675 for ac_dir in $ac_dummy; do
6676 test -z "$ac_dir" && ac_dir=.
6677 if test -f $ac_dir/$ac_word; then
6678 ac_cv_prog_PERL="$ac_prog"
6679 break
6681 done
6682 IFS="$ac_save_ifs"
6685 PERL="$ac_cv_prog_PERL"
6686 if test -n "$PERL"; then
6687 echo "$ac_t""$PERL" 1>&6
6688 else
6689 echo "$ac_t""no" 1>&6
6692 test -n "$PERL" && break
6693 done
6694 test -n "$PERL" || PERL="false"
6697 SYSDEP_SOURCES=
6699 case "${host}" in
6700 i?86-*-linux*)
6701 SIGNAL_HANDLER=include/i386-signal.h
6703 sparc*-sun-solaris*)
6704 SIGNAL_HANDLER=include/sparc-signal.h
6706 # ia64-*)
6707 # SYSDEP_SOURCES=sysdep/ia64.c
6708 # test -d sysdep || mkdir sysdep
6709 # ;;
6710 ia64-*-linux*)
6711 SIGNAL_HANDLER=include/dwarf2-signal.h
6713 powerpc-*-linux*)
6714 SIGNAL_HANDLER=include/dwarf2-signal.h
6716 alpha*-*-linux*)
6717 SIGNAL_HANDLER=include/dwarf2-signal.h
6719 sparc*-*-linux*)
6720 SIGNAL_HANDLER=include/dwarf2-signal.h
6722 *mingw*)
6723 SIGNAL_HANDLER=include/win32-signal.h
6726 SIGNAL_HANDLER=include/default-signal.h
6728 esac
6730 # If we're using sjlj exceptions, forget what we just learned.
6731 if test "$enable_sjlj_exceptions" = yes; then
6732 SIGNAL_HANDLER=include/default-signal.h
6739 if test "${multilib}" = "yes"; then
6740 multilib_arg="--enable-multilib"
6741 else
6742 multilib_arg=
6745 # If we find X, set shell vars x_includes and x_libraries to the
6746 # paths, otherwise set no_x=yes.
6747 # Uses ac_ vars as temps to allow command line to override cache and checks.
6748 # --without-x overrides everything else, but does not touch the cache.
6749 echo $ac_n "checking for X""... $ac_c" 1>&6
6750 echo "configure:6752: checking for X" >&5
6752 # Check whether --with-x or --without-x was given.
6753 if test "${with_x+set}" = set; then
6754 withval="$with_x"
6758 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
6759 if test "x$with_x" = xno; then
6760 # The user explicitly disabled X.
6761 have_x=disabled
6762 else
6763 if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
6764 # Both variables are already set.
6765 have_x=yes
6766 else
6767 if eval "test \"`echo '$''{'ac_cv_have_x'+set}'`\" = set"; then
6768 echo $ac_n "(cached) $ac_c" 1>&6
6769 else
6770 # One or both of the vars are not set, and there is no cached value.
6771 ac_x_includes=NO ac_x_libraries=NO
6772 rm -fr conftestdir
6773 if mkdir conftestdir; then
6774 cd conftestdir
6775 # Make sure to not put "make" in the Imakefile rules, since we grep it out.
6776 cat > Imakefile <<'EOF'
6777 acfindx:
6778 @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
6780 if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
6781 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
6782 eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
6783 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
6784 for ac_extension in a so sl; do
6785 if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
6786 test -f $ac_im_libdir/libX11.$ac_extension; then
6787 ac_im_usrlibdir=$ac_im_libdir; break
6789 done
6790 # Screen out bogus values from the imake configuration. They are
6791 # bogus both because they are the default anyway, and because
6792 # using them would break gcc on systems where it needs fixed includes.
6793 case "$ac_im_incroot" in
6794 /usr/include) ;;
6795 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes="$ac_im_incroot" ;;
6796 esac
6797 case "$ac_im_usrlibdir" in
6798 /usr/lib | /lib) ;;
6799 *) test -d "$ac_im_usrlibdir" && ac_x_libraries="$ac_im_usrlibdir" ;;
6800 esac
6802 cd ..
6803 rm -fr conftestdir
6806 if test "$ac_x_includes" = NO; then
6807 # Guess where to find include files, by looking for this one X11 .h file.
6808 test -z "$x_direct_test_include" && x_direct_test_include=X11/Intrinsic.h
6810 # First, try using that file with no special directory specified.
6811 cat > conftest.$ac_ext <<EOF
6812 #line 6814 "configure"
6813 #include "confdefs.h"
6814 #include <$x_direct_test_include>
6816 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
6817 { (eval echo configure:6819: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
6818 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
6819 if test -z "$ac_err"; then
6820 rm -rf conftest*
6821 # We can compile using X headers with no special include directory.
6822 ac_x_includes=
6823 else
6824 echo "$ac_err" >&5
6825 echo "configure: failed program was:" >&5
6826 cat conftest.$ac_ext >&5
6827 rm -rf conftest*
6828 # Look for the header file in a standard set of common directories.
6829 # Check X11 before X11Rn because it is often a symlink to the current release.
6830 for ac_dir in \
6831 /usr/X11/include \
6832 /usr/X11R6/include \
6833 /usr/X11R5/include \
6834 /usr/X11R4/include \
6836 /usr/include/X11 \
6837 /usr/include/X11R6 \
6838 /usr/include/X11R5 \
6839 /usr/include/X11R4 \
6841 /usr/local/X11/include \
6842 /usr/local/X11R6/include \
6843 /usr/local/X11R5/include \
6844 /usr/local/X11R4/include \
6846 /usr/local/include/X11 \
6847 /usr/local/include/X11R6 \
6848 /usr/local/include/X11R5 \
6849 /usr/local/include/X11R4 \
6851 /usr/X386/include \
6852 /usr/x386/include \
6853 /usr/XFree86/include/X11 \
6855 /usr/include \
6856 /usr/local/include \
6857 /usr/unsupported/include \
6858 /usr/athena/include \
6859 /usr/local/x11r5/include \
6860 /usr/lpp/Xamples/include \
6862 /usr/openwin/include \
6863 /usr/openwin/share/include \
6866 if test -r "$ac_dir/$x_direct_test_include"; then
6867 ac_x_includes=$ac_dir
6868 break
6870 done
6872 rm -f conftest*
6873 fi # $ac_x_includes = NO
6875 if test "$ac_x_libraries" = NO; then
6876 # Check for the libraries.
6878 test -z "$x_direct_test_library" && x_direct_test_library=Xt
6879 test -z "$x_direct_test_function" && x_direct_test_function=XtMalloc
6881 # See if we find them without any special options.
6882 # Don't add to $LIBS permanently.
6883 ac_save_LIBS="$LIBS"
6884 LIBS="-l$x_direct_test_library $LIBS"
6885 cat > conftest.$ac_ext <<EOF
6886 #line 6888 "configure"
6887 #include "confdefs.h"
6889 int main() {
6890 ${x_direct_test_function}()
6891 ; return 0; }
6893 if { (eval echo configure:6895: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6894 rm -rf conftest*
6895 LIBS="$ac_save_LIBS"
6896 # We can link X programs with no special library path.
6897 ac_x_libraries=
6898 else
6899 echo "configure: failed program was:" >&5
6900 cat conftest.$ac_ext >&5
6901 rm -rf conftest*
6902 LIBS="$ac_save_LIBS"
6903 # First see if replacing the include by lib works.
6904 # Check X11 before X11Rn because it is often a symlink to the current release.
6905 for ac_dir in `echo "$ac_x_includes" | sed s/include/lib/` \
6906 /usr/X11/lib \
6907 /usr/X11R6/lib \
6908 /usr/X11R5/lib \
6909 /usr/X11R4/lib \
6911 /usr/lib/X11 \
6912 /usr/lib/X11R6 \
6913 /usr/lib/X11R5 \
6914 /usr/lib/X11R4 \
6916 /usr/local/X11/lib \
6917 /usr/local/X11R6/lib \
6918 /usr/local/X11R5/lib \
6919 /usr/local/X11R4/lib \
6921 /usr/local/lib/X11 \
6922 /usr/local/lib/X11R6 \
6923 /usr/local/lib/X11R5 \
6924 /usr/local/lib/X11R4 \
6926 /usr/X386/lib \
6927 /usr/x386/lib \
6928 /usr/XFree86/lib/X11 \
6930 /usr/lib \
6931 /usr/local/lib \
6932 /usr/unsupported/lib \
6933 /usr/athena/lib \
6934 /usr/local/x11r5/lib \
6935 /usr/lpp/Xamples/lib \
6936 /lib/usr/lib/X11 \
6938 /usr/openwin/lib \
6939 /usr/openwin/share/lib \
6942 for ac_extension in a so sl; do
6943 if test -r $ac_dir/lib${x_direct_test_library}.$ac_extension; then
6944 ac_x_libraries=$ac_dir
6945 break 2
6947 done
6948 done
6950 rm -f conftest*
6951 fi # $ac_x_libraries = NO
6953 if test "$ac_x_includes" = NO || test "$ac_x_libraries" = NO; then
6954 # Didn't find X anywhere. Cache the known absence of X.
6955 ac_cv_have_x="have_x=no"
6956 else
6957 # Record where we found X for the cache.
6958 ac_cv_have_x="have_x=yes \
6959 ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
6963 eval "$ac_cv_have_x"
6964 fi # $with_x != no
6966 if test "$have_x" != yes; then
6967 echo "$ac_t""$have_x" 1>&6
6968 no_x=yes
6969 else
6970 # If each of the values was on the command line, it overrides each guess.
6971 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
6972 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
6973 # Update the cache value to reflect the command line values.
6974 ac_cv_have_x="have_x=yes \
6975 ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
6976 echo "$ac_t""libraries $x_libraries, headers $x_includes" 1>&6
6979 if test "$no_x" = yes; then
6980 # Not all programs may use this symbol, but it does not hurt to define it.
6981 cat >> confdefs.h <<\EOF
6982 #define X_DISPLAY_MISSING 1
6985 X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS=
6986 else
6987 if test -n "$x_includes"; then
6988 X_CFLAGS="$X_CFLAGS -I$x_includes"
6991 # It would also be nice to do this for all -L options, not just this one.
6992 if test -n "$x_libraries"; then
6993 X_LIBS="$X_LIBS -L$x_libraries"
6994 # For Solaris; some versions of Sun CC require a space after -R and
6995 # others require no space. Words are not sufficient . . . .
6996 case "`(uname -sr) 2>/dev/null`" in
6997 "SunOS 5"*)
6998 echo $ac_n "checking whether -R must be followed by a space""... $ac_c" 1>&6
6999 echo "configure:7001: checking whether -R must be followed by a space" >&5
7000 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS -R$x_libraries"
7001 cat > conftest.$ac_ext <<EOF
7002 #line 7004 "configure"
7003 #include "confdefs.h"
7005 int main() {
7007 ; return 0; }
7009 if { (eval echo configure:7011: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7010 rm -rf conftest*
7011 ac_R_nospace=yes
7012 else
7013 echo "configure: failed program was:" >&5
7014 cat conftest.$ac_ext >&5
7015 rm -rf conftest*
7016 ac_R_nospace=no
7018 rm -f conftest*
7019 if test $ac_R_nospace = yes; then
7020 echo "$ac_t""no" 1>&6
7021 X_LIBS="$X_LIBS -R$x_libraries"
7022 else
7023 LIBS="$ac_xsave_LIBS -R $x_libraries"
7024 cat > conftest.$ac_ext <<EOF
7025 #line 7027 "configure"
7026 #include "confdefs.h"
7028 int main() {
7030 ; return 0; }
7032 if { (eval echo configure:7034: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7033 rm -rf conftest*
7034 ac_R_space=yes
7035 else
7036 echo "configure: failed program was:" >&5
7037 cat conftest.$ac_ext >&5
7038 rm -rf conftest*
7039 ac_R_space=no
7041 rm -f conftest*
7042 if test $ac_R_space = yes; then
7043 echo "$ac_t""yes" 1>&6
7044 X_LIBS="$X_LIBS -R $x_libraries"
7045 else
7046 echo "$ac_t""neither works" 1>&6
7049 LIBS="$ac_xsave_LIBS"
7050 esac
7053 # Check for system-dependent libraries X programs must link with.
7054 # Do this before checking for the system-independent R6 libraries
7055 # (-lICE), since we may need -lsocket or whatever for X linking.
7057 if test "$ISC" = yes; then
7058 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
7059 else
7060 # Martyn.Johnson@cl.cam.ac.uk says this is needed for Ultrix, if the X
7061 # libraries were built with DECnet support. And karl@cs.umb.edu says
7062 # the Alpha needs dnet_stub (dnet does not exist).
7063 echo $ac_n "checking for dnet_ntoa in -ldnet""... $ac_c" 1>&6
7064 echo "configure:7066: checking for dnet_ntoa in -ldnet" >&5
7065 ac_lib_var=`echo dnet'_'dnet_ntoa | sed 'y%./+-%__p_%'`
7066 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
7067 echo $ac_n "(cached) $ac_c" 1>&6
7068 else
7069 ac_save_LIBS="$LIBS"
7070 LIBS="-ldnet $LIBS"
7071 cat > conftest.$ac_ext <<EOF
7072 #line 7074 "configure"
7073 #include "confdefs.h"
7074 /* Override any gcc2 internal prototype to avoid an error. */
7075 /* We use char because int might match the return type of a gcc2
7076 builtin and then its argument prototype would still apply. */
7077 char dnet_ntoa();
7079 int main() {
7080 dnet_ntoa()
7081 ; return 0; }
7083 if { (eval echo configure:7085: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7084 rm -rf conftest*
7085 eval "ac_cv_lib_$ac_lib_var=yes"
7086 else
7087 echo "configure: failed program was:" >&5
7088 cat conftest.$ac_ext >&5
7089 rm -rf conftest*
7090 eval "ac_cv_lib_$ac_lib_var=no"
7092 rm -f conftest*
7093 LIBS="$ac_save_LIBS"
7096 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
7097 echo "$ac_t""yes" 1>&6
7098 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
7099 else
7100 echo "$ac_t""no" 1>&6
7103 if test $ac_cv_lib_dnet_dnet_ntoa = no; then
7104 echo $ac_n "checking for dnet_ntoa in -ldnet_stub""... $ac_c" 1>&6
7105 echo "configure:7107: checking for dnet_ntoa in -ldnet_stub" >&5
7106 ac_lib_var=`echo dnet_stub'_'dnet_ntoa | sed 'y%./+-%__p_%'`
7107 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
7108 echo $ac_n "(cached) $ac_c" 1>&6
7109 else
7110 ac_save_LIBS="$LIBS"
7111 LIBS="-ldnet_stub $LIBS"
7112 cat > conftest.$ac_ext <<EOF
7113 #line 7115 "configure"
7114 #include "confdefs.h"
7115 /* Override any gcc2 internal prototype to avoid an error. */
7116 /* We use char because int might match the return type of a gcc2
7117 builtin and then its argument prototype would still apply. */
7118 char dnet_ntoa();
7120 int main() {
7121 dnet_ntoa()
7122 ; return 0; }
7124 if { (eval echo configure:7126: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7125 rm -rf conftest*
7126 eval "ac_cv_lib_$ac_lib_var=yes"
7127 else
7128 echo "configure: failed program was:" >&5
7129 cat conftest.$ac_ext >&5
7130 rm -rf conftest*
7131 eval "ac_cv_lib_$ac_lib_var=no"
7133 rm -f conftest*
7134 LIBS="$ac_save_LIBS"
7137 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
7138 echo "$ac_t""yes" 1>&6
7139 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
7140 else
7141 echo "$ac_t""no" 1>&6
7146 # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
7147 # to get the SysV transport functions.
7148 # chad@anasazi.com says the Pyramis MIS-ES running DC/OSx (SVR4)
7149 # needs -lnsl.
7150 # The nsl library prevents programs from opening the X display
7151 # on Irix 5.2, according to dickey@clark.net.
7152 echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6
7153 echo "configure:7155: checking for gethostbyname" >&5
7154 if eval "test \"`echo '$''{'ac_cv_func_gethostbyname'+set}'`\" = set"; then
7155 echo $ac_n "(cached) $ac_c" 1>&6
7156 else
7157 cat > conftest.$ac_ext <<EOF
7158 #line 7160 "configure"
7159 #include "confdefs.h"
7160 /* System header to define __stub macros and hopefully few prototypes,
7161 which can conflict with char gethostbyname(); below. */
7162 #include <assert.h>
7163 /* Override any gcc2 internal prototype to avoid an error. */
7164 /* We use char because int might match the return type of a gcc2
7165 builtin and then its argument prototype would still apply. */
7166 char gethostbyname();
7168 int main() {
7170 /* The GNU C library defines this for functions which it implements
7171 to always fail with ENOSYS. Some functions are actually named
7172 something starting with __ and the normal name is an alias. */
7173 #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
7174 choke me
7175 #else
7176 gethostbyname();
7177 #endif
7179 ; return 0; }
7181 if { (eval echo configure:7183: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7182 rm -rf conftest*
7183 eval "ac_cv_func_gethostbyname=yes"
7184 else
7185 echo "configure: failed program was:" >&5
7186 cat conftest.$ac_ext >&5
7187 rm -rf conftest*
7188 eval "ac_cv_func_gethostbyname=no"
7190 rm -f conftest*
7193 if eval "test \"`echo '$ac_cv_func_'gethostbyname`\" = yes"; then
7194 echo "$ac_t""yes" 1>&6
7196 else
7197 echo "$ac_t""no" 1>&6
7200 if test $ac_cv_func_gethostbyname = no; then
7201 echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6
7202 echo "configure:7204: checking for gethostbyname in -lnsl" >&5
7203 ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'`
7204 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
7205 echo $ac_n "(cached) $ac_c" 1>&6
7206 else
7207 ac_save_LIBS="$LIBS"
7208 LIBS="-lnsl $LIBS"
7209 cat > conftest.$ac_ext <<EOF
7210 #line 7212 "configure"
7211 #include "confdefs.h"
7212 /* Override any gcc2 internal prototype to avoid an error. */
7213 /* We use char because int might match the return type of a gcc2
7214 builtin and then its argument prototype would still apply. */
7215 char gethostbyname();
7217 int main() {
7218 gethostbyname()
7219 ; return 0; }
7221 if { (eval echo configure:7223: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7222 rm -rf conftest*
7223 eval "ac_cv_lib_$ac_lib_var=yes"
7224 else
7225 echo "configure: failed program was:" >&5
7226 cat conftest.$ac_ext >&5
7227 rm -rf conftest*
7228 eval "ac_cv_lib_$ac_lib_var=no"
7230 rm -f conftest*
7231 LIBS="$ac_save_LIBS"
7234 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
7235 echo "$ac_t""yes" 1>&6
7236 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
7237 else
7238 echo "$ac_t""no" 1>&6
7243 # lieder@skyler.mavd.honeywell.com says without -lsocket,
7244 # socket/setsockopt and other routines are undefined under SCO ODT
7245 # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary
7246 # on later versions), says simon@lia.di.epfl.ch: it contains
7247 # gethostby* variants that don't use the nameserver (or something).
7248 # -lsocket must be given before -lnsl if both are needed.
7249 # We assume that if connect needs -lnsl, so does gethostbyname.
7250 echo $ac_n "checking for connect""... $ac_c" 1>&6
7251 echo "configure:7253: checking for connect" >&5
7252 if eval "test \"`echo '$''{'ac_cv_func_connect'+set}'`\" = set"; then
7253 echo $ac_n "(cached) $ac_c" 1>&6
7254 else
7255 cat > conftest.$ac_ext <<EOF
7256 #line 7258 "configure"
7257 #include "confdefs.h"
7258 /* System header to define __stub macros and hopefully few prototypes,
7259 which can conflict with char connect(); below. */
7260 #include <assert.h>
7261 /* Override any gcc2 internal prototype to avoid an error. */
7262 /* We use char because int might match the return type of a gcc2
7263 builtin and then its argument prototype would still apply. */
7264 char connect();
7266 int main() {
7268 /* The GNU C library defines this for functions which it implements
7269 to always fail with ENOSYS. Some functions are actually named
7270 something starting with __ and the normal name is an alias. */
7271 #if defined (__stub_connect) || defined (__stub___connect)
7272 choke me
7273 #else
7274 connect();
7275 #endif
7277 ; return 0; }
7279 if { (eval echo configure:7281: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7280 rm -rf conftest*
7281 eval "ac_cv_func_connect=yes"
7282 else
7283 echo "configure: failed program was:" >&5
7284 cat conftest.$ac_ext >&5
7285 rm -rf conftest*
7286 eval "ac_cv_func_connect=no"
7288 rm -f conftest*
7291 if eval "test \"`echo '$ac_cv_func_'connect`\" = yes"; then
7292 echo "$ac_t""yes" 1>&6
7294 else
7295 echo "$ac_t""no" 1>&6
7298 if test $ac_cv_func_connect = no; then
7299 echo $ac_n "checking for connect in -lsocket""... $ac_c" 1>&6
7300 echo "configure:7302: checking for connect in -lsocket" >&5
7301 ac_lib_var=`echo socket'_'connect | sed 'y%./+-%__p_%'`
7302 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
7303 echo $ac_n "(cached) $ac_c" 1>&6
7304 else
7305 ac_save_LIBS="$LIBS"
7306 LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
7307 cat > conftest.$ac_ext <<EOF
7308 #line 7310 "configure"
7309 #include "confdefs.h"
7310 /* Override any gcc2 internal prototype to avoid an error. */
7311 /* We use char because int might match the return type of a gcc2
7312 builtin and then its argument prototype would still apply. */
7313 char connect();
7315 int main() {
7316 connect()
7317 ; return 0; }
7319 if { (eval echo configure:7321: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7320 rm -rf conftest*
7321 eval "ac_cv_lib_$ac_lib_var=yes"
7322 else
7323 echo "configure: failed program was:" >&5
7324 cat conftest.$ac_ext >&5
7325 rm -rf conftest*
7326 eval "ac_cv_lib_$ac_lib_var=no"
7328 rm -f conftest*
7329 LIBS="$ac_save_LIBS"
7332 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
7333 echo "$ac_t""yes" 1>&6
7334 X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
7335 else
7336 echo "$ac_t""no" 1>&6
7341 # gomez@mi.uni-erlangen.de says -lposix is necessary on A/UX.
7342 echo $ac_n "checking for remove""... $ac_c" 1>&6
7343 echo "configure:7345: checking for remove" >&5
7344 if eval "test \"`echo '$''{'ac_cv_func_remove'+set}'`\" = set"; then
7345 echo $ac_n "(cached) $ac_c" 1>&6
7346 else
7347 cat > conftest.$ac_ext <<EOF
7348 #line 7350 "configure"
7349 #include "confdefs.h"
7350 /* System header to define __stub macros and hopefully few prototypes,
7351 which can conflict with char remove(); below. */
7352 #include <assert.h>
7353 /* Override any gcc2 internal prototype to avoid an error. */
7354 /* We use char because int might match the return type of a gcc2
7355 builtin and then its argument prototype would still apply. */
7356 char remove();
7358 int main() {
7360 /* The GNU C library defines this for functions which it implements
7361 to always fail with ENOSYS. Some functions are actually named
7362 something starting with __ and the normal name is an alias. */
7363 #if defined (__stub_remove) || defined (__stub___remove)
7364 choke me
7365 #else
7366 remove();
7367 #endif
7369 ; return 0; }
7371 if { (eval echo configure:7373: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7372 rm -rf conftest*
7373 eval "ac_cv_func_remove=yes"
7374 else
7375 echo "configure: failed program was:" >&5
7376 cat conftest.$ac_ext >&5
7377 rm -rf conftest*
7378 eval "ac_cv_func_remove=no"
7380 rm -f conftest*
7383 if eval "test \"`echo '$ac_cv_func_'remove`\" = yes"; then
7384 echo "$ac_t""yes" 1>&6
7386 else
7387 echo "$ac_t""no" 1>&6
7390 if test $ac_cv_func_remove = no; then
7391 echo $ac_n "checking for remove in -lposix""... $ac_c" 1>&6
7392 echo "configure:7394: checking for remove in -lposix" >&5
7393 ac_lib_var=`echo posix'_'remove | sed 'y%./+-%__p_%'`
7394 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
7395 echo $ac_n "(cached) $ac_c" 1>&6
7396 else
7397 ac_save_LIBS="$LIBS"
7398 LIBS="-lposix $LIBS"
7399 cat > conftest.$ac_ext <<EOF
7400 #line 7402 "configure"
7401 #include "confdefs.h"
7402 /* Override any gcc2 internal prototype to avoid an error. */
7403 /* We use char because int might match the return type of a gcc2
7404 builtin and then its argument prototype would still apply. */
7405 char remove();
7407 int main() {
7408 remove()
7409 ; return 0; }
7411 if { (eval echo configure:7413: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7412 rm -rf conftest*
7413 eval "ac_cv_lib_$ac_lib_var=yes"
7414 else
7415 echo "configure: failed program was:" >&5
7416 cat conftest.$ac_ext >&5
7417 rm -rf conftest*
7418 eval "ac_cv_lib_$ac_lib_var=no"
7420 rm -f conftest*
7421 LIBS="$ac_save_LIBS"
7424 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
7425 echo "$ac_t""yes" 1>&6
7426 X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
7427 else
7428 echo "$ac_t""no" 1>&6
7433 # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
7434 echo $ac_n "checking for shmat""... $ac_c" 1>&6
7435 echo "configure:7437: checking for shmat" >&5
7436 if eval "test \"`echo '$''{'ac_cv_func_shmat'+set}'`\" = set"; then
7437 echo $ac_n "(cached) $ac_c" 1>&6
7438 else
7439 cat > conftest.$ac_ext <<EOF
7440 #line 7442 "configure"
7441 #include "confdefs.h"
7442 /* System header to define __stub macros and hopefully few prototypes,
7443 which can conflict with char shmat(); below. */
7444 #include <assert.h>
7445 /* Override any gcc2 internal prototype to avoid an error. */
7446 /* We use char because int might match the return type of a gcc2
7447 builtin and then its argument prototype would still apply. */
7448 char shmat();
7450 int main() {
7452 /* The GNU C library defines this for functions which it implements
7453 to always fail with ENOSYS. Some functions are actually named
7454 something starting with __ and the normal name is an alias. */
7455 #if defined (__stub_shmat) || defined (__stub___shmat)
7456 choke me
7457 #else
7458 shmat();
7459 #endif
7461 ; return 0; }
7463 if { (eval echo configure:7465: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7464 rm -rf conftest*
7465 eval "ac_cv_func_shmat=yes"
7466 else
7467 echo "configure: failed program was:" >&5
7468 cat conftest.$ac_ext >&5
7469 rm -rf conftest*
7470 eval "ac_cv_func_shmat=no"
7472 rm -f conftest*
7475 if eval "test \"`echo '$ac_cv_func_'shmat`\" = yes"; then
7476 echo "$ac_t""yes" 1>&6
7478 else
7479 echo "$ac_t""no" 1>&6
7482 if test $ac_cv_func_shmat = no; then
7483 echo $ac_n "checking for shmat in -lipc""... $ac_c" 1>&6
7484 echo "configure:7486: checking for shmat in -lipc" >&5
7485 ac_lib_var=`echo ipc'_'shmat | sed 'y%./+-%__p_%'`
7486 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
7487 echo $ac_n "(cached) $ac_c" 1>&6
7488 else
7489 ac_save_LIBS="$LIBS"
7490 LIBS="-lipc $LIBS"
7491 cat > conftest.$ac_ext <<EOF
7492 #line 7494 "configure"
7493 #include "confdefs.h"
7494 /* Override any gcc2 internal prototype to avoid an error. */
7495 /* We use char because int might match the return type of a gcc2
7496 builtin and then its argument prototype would still apply. */
7497 char shmat();
7499 int main() {
7500 shmat()
7501 ; return 0; }
7503 if { (eval echo configure:7505: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7504 rm -rf conftest*
7505 eval "ac_cv_lib_$ac_lib_var=yes"
7506 else
7507 echo "configure: failed program was:" >&5
7508 cat conftest.$ac_ext >&5
7509 rm -rf conftest*
7510 eval "ac_cv_lib_$ac_lib_var=no"
7512 rm -f conftest*
7513 LIBS="$ac_save_LIBS"
7516 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
7517 echo "$ac_t""yes" 1>&6
7518 X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
7519 else
7520 echo "$ac_t""no" 1>&6
7526 # Check for libraries that X11R6 Xt/Xaw programs need.
7527 ac_save_LDFLAGS="$LDFLAGS"
7528 test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
7529 # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
7530 # check for ICE first), but we must link in the order -lSM -lICE or
7531 # we get undefined symbols. So assume we have SM if we have ICE.
7532 # These have to be linked with before -lX11, unlike the other
7533 # libraries we check for below, so use a different variable.
7534 # --interran@uluru.Stanford.EDU, kb@cs.umb.edu.
7535 echo $ac_n "checking for IceConnectionNumber in -lICE""... $ac_c" 1>&6
7536 echo "configure:7538: checking for IceConnectionNumber in -lICE" >&5
7537 ac_lib_var=`echo ICE'_'IceConnectionNumber | sed 'y%./+-%__p_%'`
7538 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
7539 echo $ac_n "(cached) $ac_c" 1>&6
7540 else
7541 ac_save_LIBS="$LIBS"
7542 LIBS="-lICE $X_EXTRA_LIBS $LIBS"
7543 cat > conftest.$ac_ext <<EOF
7544 #line 7546 "configure"
7545 #include "confdefs.h"
7546 /* Override any gcc2 internal prototype to avoid an error. */
7547 /* We use char because int might match the return type of a gcc2
7548 builtin and then its argument prototype would still apply. */
7549 char IceConnectionNumber();
7551 int main() {
7552 IceConnectionNumber()
7553 ; return 0; }
7555 if { (eval echo configure:7557: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7556 rm -rf conftest*
7557 eval "ac_cv_lib_$ac_lib_var=yes"
7558 else
7559 echo "configure: failed program was:" >&5
7560 cat conftest.$ac_ext >&5
7561 rm -rf conftest*
7562 eval "ac_cv_lib_$ac_lib_var=no"
7564 rm -f conftest*
7565 LIBS="$ac_save_LIBS"
7568 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
7569 echo "$ac_t""yes" 1>&6
7570 X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
7571 else
7572 echo "$ac_t""no" 1>&6
7575 LDFLAGS="$ac_save_LDFLAGS"
7580 # Check whether --enable-java-awt or --disable-java-awt was given.
7581 if test "${enable_java_awt+set}" = set; then
7582 enableval="$enable_java_awt"
7587 peerlibs="`echo ${enable_java_awt} | tr ',' ' '`"
7588 use_xlib_awt=""
7589 use_gtk_awt=""
7591 for peer in $peerlibs ; do
7592 case $peer in
7593 xlib)
7594 if test "$no_x" = yes; then
7595 echo "*** xlib peers requested but no X library available" 1>&2
7596 exit 1
7597 else
7598 use_xlib_awt="yes"
7601 gtk)
7602 # Nothing, yet...
7605 use_xlib_awt=
7606 use_gtk_awt=
7607 break
7610 echo "*** unrecognised argument \"${peer}\" for --enable-java-awt" 1>&2
7611 exit 1
7612 esac
7613 done
7617 if test "$use_xlib_awt" = yes; then
7618 XLIB_AWT_TRUE=
7619 XLIB_AWT_FALSE='#'
7620 else
7621 XLIB_AWT_TRUE='#'
7622 XLIB_AWT_FALSE=
7626 if test "$use_gtk_awt" = yes; then
7627 GTK_AWT_TRUE=
7628 GTK_AWT_FALSE='#'
7629 else
7630 GTK_AWT_TRUE='#'
7631 GTK_AWT_FALSE=
7635 here=`pwd`
7638 # We get this from the environment.
7641 trap '' 1 2 15
7642 cat > confcache <<\EOF
7643 # This file is a shell script that caches the results of configure
7644 # tests run on this system so they can be shared between configure
7645 # scripts and configure runs. It is not useful on other systems.
7646 # If it contains results you don't want to keep, you may remove or edit it.
7648 # By default, configure uses ./config.cache as the cache file,
7649 # creating it if it does not exist already. You can give configure
7650 # the --cache-file=FILE option to use a different cache file; that is
7651 # what configure does when it calls configure scripts in
7652 # subdirectories, so they share the cache.
7653 # Giving --cache-file=/dev/null disables caching, for debugging configure.
7654 # config.status only pays attention to the cache file if you give it the
7655 # --recheck option to rerun configure.
7658 # The following way of writing the cache mishandles newlines in values,
7659 # but we know of no workaround that is simple, portable, and efficient.
7660 # So, don't put newlines in cache variables' values.
7661 # Ultrix sh set writes to stderr and can't be redirected directly,
7662 # and sets the high bit in the cache file unless we assign to the vars.
7663 (set) 2>&1 |
7664 case `(ac_space=' '; set | grep ac_space) 2>&1` in
7665 *ac_space=\ *)
7666 # `set' does not quote correctly, so add quotes (double-quote substitution
7667 # turns \\\\ into \\, and sed turns \\ into \).
7668 sed -n \
7669 -e "s/'/'\\\\''/g" \
7670 -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
7673 # `set' quotes correctly as required by POSIX, so do not add quotes.
7674 sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
7676 esac >> confcache
7677 if cmp -s $cache_file confcache; then
7679 else
7680 if test -w $cache_file; then
7681 echo "updating cache $cache_file"
7682 cat confcache > $cache_file
7683 else
7684 echo "not updating unwritable cache $cache_file"
7687 rm -f confcache
7689 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
7691 test "x$prefix" = xNONE && prefix=$ac_default_prefix
7692 # Let make expand exec_prefix.
7693 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
7695 # Any assignment to VPATH causes Sun make to only execute
7696 # the first set of double-colon rules, so remove it if not needed.
7697 # If there is a colon in the path, we need to keep it.
7698 if test "x$srcdir" = x.; then
7699 ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
7702 trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
7704 DEFS=-DHAVE_CONFIG_H
7706 # Without the "./", some shells look in PATH for config.status.
7707 : ${CONFIG_STATUS=./config.status}
7709 echo creating $CONFIG_STATUS
7710 rm -f $CONFIG_STATUS
7711 cat > $CONFIG_STATUS <<EOF
7712 #! /bin/sh
7713 # Generated automatically by configure.
7714 # Run this file to recreate the current configuration.
7715 # This directory was configured as follows,
7716 # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
7718 # $0 $ac_configure_args
7720 # Compiler output produced by configure, useful for debugging
7721 # configure, is in ./config.log if it exists.
7723 ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
7724 for ac_option
7726 case "\$ac_option" in
7727 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
7728 echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
7729 exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
7730 -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
7731 echo "$CONFIG_STATUS generated by autoconf version 2.13"
7732 exit 0 ;;
7733 -help | --help | --hel | --he | --h)
7734 echo "\$ac_cs_usage"; exit 0 ;;
7735 *) echo "\$ac_cs_usage"; exit 1 ;;
7736 esac
7737 done
7739 ac_given_srcdir=$srcdir
7740 ac_given_INSTALL="$INSTALL"
7742 trap 'rm -fr `echo "Makefile libgcj.spec libgcj-test.spec gnu/classpath/Configuration.java gcj/Makefile include/Makefile testsuite/Makefile include/config.h gcj/libgcj-config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
7744 cat >> $CONFIG_STATUS <<EOF
7746 # Protect against being on the right side of a sed subst in config.status.
7747 sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
7748 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
7749 $ac_vpsub
7750 $extrasub
7751 s%@SHELL@%$SHELL%g
7752 s%@CFLAGS@%$CFLAGS%g
7753 s%@CPPFLAGS@%$CPPFLAGS%g
7754 s%@CXXFLAGS@%$CXXFLAGS%g
7755 s%@FFLAGS@%$FFLAGS%g
7756 s%@DEFS@%$DEFS%g
7757 s%@LDFLAGS@%$LDFLAGS%g
7758 s%@LIBS@%$LIBS%g
7759 s%@exec_prefix@%$exec_prefix%g
7760 s%@prefix@%$prefix%g
7761 s%@program_transform_name@%$program_transform_name%g
7762 s%@bindir@%$bindir%g
7763 s%@sbindir@%$sbindir%g
7764 s%@libexecdir@%$libexecdir%g
7765 s%@datadir@%$datadir%g
7766 s%@sysconfdir@%$sysconfdir%g
7767 s%@sharedstatedir@%$sharedstatedir%g
7768 s%@localstatedir@%$localstatedir%g
7769 s%@libdir@%$libdir%g
7770 s%@includedir@%$includedir%g
7771 s%@oldincludedir@%$oldincludedir%g
7772 s%@infodir@%$infodir%g
7773 s%@mandir@%$mandir%g
7774 s%@LN_S@%$LN_S%g
7775 s%@libgcj_basedir@%$libgcj_basedir%g
7776 s%@mkinstalldirs@%$mkinstalldirs%g
7777 s%@host@%$host%g
7778 s%@host_alias@%$host_alias%g
7779 s%@host_cpu@%$host_cpu%g
7780 s%@host_vendor@%$host_vendor%g
7781 s%@host_os@%$host_os%g
7782 s%@target@%$target%g
7783 s%@target_alias@%$target_alias%g
7784 s%@target_cpu@%$target_cpu%g
7785 s%@target_vendor@%$target_vendor%g
7786 s%@target_os@%$target_os%g
7787 s%@build@%$build%g
7788 s%@build_alias@%$build_alias%g
7789 s%@build_cpu@%$build_cpu%g
7790 s%@build_vendor@%$build_vendor%g
7791 s%@build_os@%$build_os%g
7792 s%@CC@%$CC%g
7793 s%@glibjava_CXX@%$glibjava_CXX%g
7794 s%@CXX@%$CXX%g
7795 s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
7796 s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
7797 s%@INSTALL_DATA@%$INSTALL_DATA%g
7798 s%@PACKAGE@%$PACKAGE%g
7799 s%@VERSION@%$VERSION%g
7800 s%@EXEEXT@%$EXEEXT%g
7801 s%@OBJEXT@%$OBJEXT%g
7802 s%@ACLOCAL@%$ACLOCAL%g
7803 s%@AUTOCONF@%$AUTOCONF%g
7804 s%@AUTOMAKE@%$AUTOMAKE%g
7805 s%@AUTOHEADER@%$AUTOHEADER%g
7806 s%@MAKEINFO@%$MAKEINFO%g
7807 s%@AMTAR@%$AMTAR%g
7808 s%@install_sh@%$install_sh%g
7809 s%@INSTALL_STRIP_PROGRAM@%$INSTALL_STRIP_PROGRAM%g
7810 s%@AWK@%$AWK%g
7811 s%@SET_MAKE@%$SET_MAKE%g
7812 s%@AMDEP_TRUE@%$AMDEP_TRUE%g
7813 s%@AMDEP_FALSE@%$AMDEP_FALSE%g
7814 s%@AMDEPBACKSLASH@%$AMDEPBACKSLASH%g
7815 s%@DEPDIR@%$DEPDIR%g
7816 s%@am__include@%$am__include%g
7817 s%@am__quote@%$am__quote%g
7818 s%@CCDEPMODE@%$CCDEPMODE%g
7819 s%@CXXDEPMODE@%$CXXDEPMODE%g
7820 s%@AS@%$AS%g
7821 s%@AR@%$AR%g
7822 s%@RANLIB@%$RANLIB%g
7823 s%@MAINTAINER_MODE_TRUE@%$MAINTAINER_MODE_TRUE%g
7824 s%@MAINTAINER_MODE_FALSE@%$MAINTAINER_MODE_FALSE%g
7825 s%@MAINT@%$MAINT%g
7826 s%@LIBGCJ_CFLAGS@%$LIBGCJ_CFLAGS%g
7827 s%@LIBGCJ_CXXFLAGS@%$LIBGCJ_CXXFLAGS%g
7828 s%@LIBGCJ_JAVAFLAGS@%$LIBGCJ_JAVAFLAGS%g
7829 s%@INCLTDL@%$INCLTDL%g
7830 s%@LIBLTDL@%$LIBLTDL%g
7831 s%@DIRLTDL@%$DIRLTDL%g
7832 s%@STRIP@%$STRIP%g
7833 s%@LIBTOOL@%$LIBTOOL%g
7834 s%@CXXCPP@%$CXXCPP%g
7835 s%@subdirs@%$subdirs%g
7836 s%@COMPPATH@%$COMPPATH%g
7837 s%@TESTSUBDIR_TRUE@%$TESTSUBDIR_TRUE%g
7838 s%@TESTSUBDIR_FALSE@%$TESTSUBDIR_FALSE%g
7839 s%@LIBGCJDEBUG@%$LIBGCJDEBUG%g
7840 s%@LIBFFI@%$LIBFFI%g
7841 s%@LIBFFIINCS@%$LIBFFIINCS%g
7842 s%@PLATFORMOBJS@%$PLATFORMOBJS%g
7843 s%@CPP@%$CPP%g
7844 s%@SYSTEMSPEC@%$SYSTEMSPEC%g
7845 s%@LIBGCJTESTSPEC@%$LIBGCJTESTSPEC%g
7846 s%@ZLIBSPEC@%$ZLIBSPEC%g
7847 s%@ZLIBTESTSPEC@%$ZLIBTESTSPEC%g
7848 s%@GCLIBS@%$GCLIBS%g
7849 s%@GCINCS@%$GCINCS%g
7850 s%@GCDEPS@%$GCDEPS%g
7851 s%@GCOBJS@%$GCOBJS%g
7852 s%@GCSPEC@%$GCSPEC%g
7853 s%@JC1GCSPEC@%$JC1GCSPEC%g
7854 s%@GCTESTSPEC@%$GCTESTSPEC%g
7855 s%@THREADLIBS@%$THREADLIBS%g
7856 s%@THREADINCS@%$THREADINCS%g
7857 s%@THREADDEPS@%$THREADDEPS%g
7858 s%@THREADOBJS@%$THREADOBJS%g
7859 s%@THREADSPEC@%$THREADSPEC%g
7860 s%@THREADLDFLAGS@%$THREADLDFLAGS%g
7861 s%@HASH_SYNC_SPEC@%$HASH_SYNC_SPEC%g
7862 s%@USING_GCC_TRUE@%$USING_GCC_TRUE%g
7863 s%@USING_GCC_FALSE@%$USING_GCC_FALSE%g
7864 s%@tool_include_dir@%$tool_include_dir%g
7865 s%@gcc_version@%$gcc_version%g
7866 s%@LIBICONV@%$LIBICONV%g
7867 s%@GCJ@%$GCJ%g
7868 s%@GCJFLAGS@%$GCJFLAGS%g
7869 s%@ZLIBS@%$ZLIBS%g
7870 s%@SYS_ZLIBS@%$SYS_ZLIBS%g
7871 s%@ZINCS@%$ZINCS%g
7872 s%@DIVIDESPEC@%$DIVIDESPEC%g
7873 s%@CHECKREFSPEC@%$CHECKREFSPEC%g
7874 s%@EXCEPTIONSPEC@%$EXCEPTIONSPEC%g
7875 s%@CANADIAN_TRUE@%$CANADIAN_TRUE%g
7876 s%@CANADIAN_FALSE@%$CANADIAN_FALSE%g
7877 s%@NULL_TARGET_TRUE@%$NULL_TARGET_TRUE%g
7878 s%@NULL_TARGET_FALSE@%$NULL_TARGET_FALSE%g
7879 s%@NATIVE_TRUE@%$NATIVE_TRUE%g
7880 s%@NATIVE_FALSE@%$NATIVE_FALSE%g
7881 s%@USE_LIBDIR_TRUE@%$USE_LIBDIR_TRUE%g
7882 s%@USE_LIBDIR_FALSE@%$USE_LIBDIR_FALSE%g
7883 s%@NEEDS_DATA_START_TRUE@%$NEEDS_DATA_START_TRUE%g
7884 s%@NEEDS_DATA_START_FALSE@%$NEEDS_DATA_START_FALSE%g
7885 s%@GCC_UNWIND_INCLUDE@%$GCC_UNWIND_INCLUDE%g
7886 s%@AM_RUNTESTFLAGS@%$AM_RUNTESTFLAGS%g
7887 s%@GCJVERSION@%$GCJVERSION%g
7888 s%@ALLOCA@%$ALLOCA%g
7889 s%@PERL@%$PERL%g
7890 s%@SYSDEP_SOURCES@%$SYSDEP_SOURCES%g
7891 s%@X_CFLAGS@%$X_CFLAGS%g
7892 s%@X_PRE_LIBS@%$X_PRE_LIBS%g
7893 s%@X_LIBS@%$X_LIBS%g
7894 s%@X_EXTRA_LIBS@%$X_EXTRA_LIBS%g
7895 s%@XLIB_AWT_TRUE@%$XLIB_AWT_TRUE%g
7896 s%@XLIB_AWT_FALSE@%$XLIB_AWT_FALSE%g
7897 s%@GTK_AWT_TRUE@%$GTK_AWT_TRUE%g
7898 s%@GTK_AWT_FALSE@%$GTK_AWT_FALSE%g
7899 s%@here@%$here%g
7901 CEOF
7904 cat >> $CONFIG_STATUS <<\EOF
7906 # Split the substitutions into bite-sized pieces for seds with
7907 # small command number limits, like on Digital OSF/1 and HP-UX.
7908 ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
7909 ac_file=1 # Number of current file.
7910 ac_beg=1 # First line for current file.
7911 ac_end=$ac_max_sed_cmds # Line after last line for current file.
7912 ac_more_lines=:
7913 ac_sed_cmds=""
7914 while $ac_more_lines; do
7915 if test $ac_beg -gt 1; then
7916 sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
7917 else
7918 sed "${ac_end}q" conftest.subs > conftest.s$ac_file
7920 if test ! -s conftest.s$ac_file; then
7921 ac_more_lines=false
7922 rm -f conftest.s$ac_file
7923 else
7924 if test -z "$ac_sed_cmds"; then
7925 ac_sed_cmds="sed -f conftest.s$ac_file"
7926 else
7927 ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
7929 ac_file=`expr $ac_file + 1`
7930 ac_beg=$ac_end
7931 ac_end=`expr $ac_end + $ac_max_sed_cmds`
7933 done
7934 if test -z "$ac_sed_cmds"; then
7935 ac_sed_cmds=cat
7939 cat >> $CONFIG_STATUS <<EOF
7941 CONFIG_FILES=\${CONFIG_FILES-"Makefile libgcj.spec libgcj-test.spec gnu/classpath/Configuration.java gcj/Makefile include/Makefile testsuite/Makefile"}
7943 cat >> $CONFIG_STATUS <<\EOF
7944 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
7945 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
7946 case "$ac_file" in
7947 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
7948 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
7949 *) ac_file_in="${ac_file}.in" ;;
7950 esac
7952 # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
7954 # Remove last slash and all that follows it. Not all systems have dirname.
7955 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
7956 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
7957 # The file is in a subdirectory.
7958 test ! -d "$ac_dir" && mkdir "$ac_dir"
7959 ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
7960 # A "../" for each directory in $ac_dir_suffix.
7961 ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
7962 else
7963 ac_dir_suffix= ac_dots=
7966 case "$ac_given_srcdir" in
7967 .) srcdir=.
7968 if test -z "$ac_dots"; then top_srcdir=.
7969 else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
7970 /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
7971 *) # Relative path.
7972 srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
7973 top_srcdir="$ac_dots$ac_given_srcdir" ;;
7974 esac
7976 case "$ac_given_INSTALL" in
7977 [/$]*) INSTALL="$ac_given_INSTALL" ;;
7978 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
7979 esac
7981 echo creating "$ac_file"
7982 rm -f "$ac_file"
7983 configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
7984 case "$ac_file" in
7985 *Makefile*) ac_comsub="1i\\
7986 # $configure_input" ;;
7987 *) ac_comsub= ;;
7988 esac
7990 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
7991 sed -e "$ac_comsub
7992 s%@configure_input@%$configure_input%g
7993 s%@srcdir@%$srcdir%g
7994 s%@top_srcdir@%$top_srcdir%g
7995 s%@INSTALL@%$INSTALL%g
7996 " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
7997 fi; done
7998 rm -f conftest.s*
8000 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
8001 # NAME is the cpp macro being defined and VALUE is the value it is being given.
8003 # ac_d sets the value in "#define NAME VALUE" lines.
8004 ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)'
8005 ac_dB='\([ ][ ]*\)[^ ]*%\1#\2'
8006 ac_dC='\3'
8007 ac_dD='%g'
8008 # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
8009 ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
8010 ac_uB='\([ ]\)%\1#\2define\3'
8011 ac_uC=' '
8012 ac_uD='\4%g'
8013 # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
8014 ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
8015 ac_eB='$%\1#\2define\3'
8016 ac_eC=' '
8017 ac_eD='%g'
8019 if test "${CONFIG_HEADERS+set}" != set; then
8021 cat >> $CONFIG_STATUS <<EOF
8022 CONFIG_HEADERS="include/config.h gcj/libgcj-config.h"
8024 cat >> $CONFIG_STATUS <<\EOF
8026 for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
8027 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
8028 case "$ac_file" in
8029 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
8030 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
8031 *) ac_file_in="${ac_file}.in" ;;
8032 esac
8034 echo creating $ac_file
8036 rm -f conftest.frag conftest.in conftest.out
8037 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
8038 cat $ac_file_inputs > conftest.in
8042 # Transform confdefs.h into a sed script conftest.vals that substitutes
8043 # the proper values into config.h.in to produce config.h. And first:
8044 # Protect against being on the right side of a sed subst in config.status.
8045 # Protect against being in an unquoted here document in config.status.
8046 rm -f conftest.vals
8047 cat > conftest.hdr <<\EOF
8048 s/[\\&%]/\\&/g
8049 s%[\\$`]%\\&%g
8050 s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
8051 s%ac_d%ac_u%gp
8052 s%ac_u%ac_e%gp
8054 sed -n -f conftest.hdr confdefs.h > conftest.vals
8055 rm -f conftest.hdr
8057 # This sed command replaces #undef with comments. This is necessary, for
8058 # example, in the case of _POSIX_SOURCE, which is predefined and required
8059 # on some systems where configure will not decide to define it.
8060 cat >> conftest.vals <<\EOF
8061 s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
8064 # Break up conftest.vals because some shells have a limit on
8065 # the size of here documents, and old seds have small limits too.
8067 rm -f conftest.tail
8068 while :
8070 ac_lines=`grep -c . conftest.vals`
8071 # grep -c gives empty output for an empty file on some AIX systems.
8072 if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
8073 # Write a limited-size here document to conftest.frag.
8074 echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
8075 sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
8076 echo 'CEOF
8077 sed -f conftest.frag conftest.in > conftest.out
8078 rm -f conftest.in
8079 mv conftest.out conftest.in
8080 ' >> $CONFIG_STATUS
8081 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
8082 rm -f conftest.vals
8083 mv conftest.tail conftest.vals
8084 done
8085 rm -f conftest.vals
8087 cat >> $CONFIG_STATUS <<\EOF
8088 rm -f conftest.frag conftest.h
8089 echo "/* $ac_file. Generated automatically by configure. */" > conftest.h
8090 cat conftest.in >> conftest.h
8091 rm -f conftest.in
8092 if cmp -s $ac_file conftest.h 2>/dev/null; then
8093 echo "$ac_file is unchanged"
8094 rm -f conftest.h
8095 else
8096 # Remove last slash and all that follows it. Not all systems have dirname.
8097 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
8098 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
8099 # The file is in a subdirectory.
8100 test ! -d "$ac_dir" && mkdir "$ac_dir"
8102 rm -f $ac_file
8103 mv conftest.h $ac_file
8105 fi; done
8109 cat >> $CONFIG_STATUS <<EOF
8110 ac_sources="include/$PLATFORMH java/io/natFile${FILE-${PLATFORM}}.cc java/io/natFileDescriptor${FILE-${PLATFORM}}.cc java/lang/${PLATFORM}Process.java java/lang/nat${PLATFORM}Process.cc include/$GCHDR include/$THREADH sysdep/$sysdeps_dir/locks.h $SIGNAL_HANDLER"
8111 ac_dests="include/platform.h java/io/natFile.cc java/io/natFileDescriptor.cc java/lang/ConcreteProcess.java java/lang/natConcreteProcess.cc include/java-gc.h include/java-threads.h sysdep/locks.h include/java-signal.h"
8114 cat >> $CONFIG_STATUS <<\EOF
8115 srcdir=$ac_given_srcdir
8116 while test -n "$ac_sources"; do
8117 set $ac_dests; ac_dest=$1; shift; ac_dests=$*
8118 set $ac_sources; ac_source=$1; shift; ac_sources=$*
8120 echo "linking $srcdir/$ac_source to $ac_dest"
8122 if test ! -r $srcdir/$ac_source; then
8123 { echo "configure: error: $srcdir/$ac_source: File not found" 1>&2; exit 1; }
8125 rm -f $ac_dest
8127 # Make relative symlinks.
8128 # Remove last slash and all that follows it. Not all systems have dirname.
8129 ac_dest_dir=`echo $ac_dest|sed 's%/[^/][^/]*$%%'`
8130 if test "$ac_dest_dir" != "$ac_dest" && test "$ac_dest_dir" != .; then
8131 # The dest file is in a subdirectory.
8132 test ! -d "$ac_dest_dir" && mkdir "$ac_dest_dir"
8133 ac_dest_dir_suffix="/`echo $ac_dest_dir|sed 's%^\./%%'`"
8134 # A "../" for each directory in $ac_dest_dir_suffix.
8135 ac_dots=`echo $ac_dest_dir_suffix|sed 's%/[^/]*%../%g'`
8136 else
8137 ac_dest_dir_suffix= ac_dots=
8140 case "$srcdir" in
8141 [/$]*) ac_rel_source="$srcdir/$ac_source" ;;
8142 *) ac_rel_source="$ac_dots$srcdir/$ac_source" ;;
8143 esac
8145 # Make a symlink if possible; otherwise try a hard link.
8146 if ln -s $ac_rel_source $ac_dest 2>/dev/null ||
8147 ln $srcdir/$ac_source $ac_dest; then :
8148 else
8149 { echo "configure: error: can not link $ac_dest to $srcdir/$ac_source" 1>&2; exit 1; }
8151 done
8153 cat >> $CONFIG_STATUS <<EOF
8154 AMDEP_TRUE="$AMDEP_TRUE"
8155 ac_aux_dir="$ac_aux_dir"
8156 am_indx=1
8157 for am_file in include/config.h gcj/libgcj-config.h; do
8158 case " \$CONFIG_HEADERS " in
8159 *" \$am_file "*)
8160 am_dir=\`echo \$am_file |sed 's%:.*%%;s%[^/]*\$%%'\`
8161 if test -n "\$am_dir"; then
8162 am_tmpdir=\`echo \$am_dir |sed 's%^\(/*\).*\$%\1%'\`
8163 for am_subdir in \`echo \$am_dir |sed 's%/% %'\`; do
8164 am_tmpdir=\$am_tmpdir\$am_subdir/
8165 if test ! -d \$am_tmpdir; then
8166 mkdir \$am_tmpdir
8168 done
8170 echo timestamp > "\$am_dir"stamp-h\$am_indx
8172 esac
8173 am_indx=\`expr \$am_indx + 1\`
8174 done
8175 srcdir=${srcdir}
8176 host=${host}
8177 target=${target}
8178 with_multisubdir=${with_multisubdir}
8179 ac_configure_args="${multilib_arg} ${ac_configure_args}"
8180 CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
8181 libgcj_basedir=${libgcj_basedir}
8182 CC="${CC}"
8183 CXX="${CXX}"
8186 cat >> $CONFIG_STATUS <<\EOF
8188 test x"$AMDEP_TRUE" != x"" ||
8189 for mf in $CONFIG_FILES; do
8190 case "$mf" in
8191 Makefile) dirpart=.;;
8192 */Makefile) dirpart=`echo "$mf" | sed -e 's|/[^/]*$||'`;;
8193 *) continue;;
8194 esac
8195 grep '^DEP_FILES *= *[^ #]' < "$mf" > /dev/null || continue
8196 # Extract the definition of DEP_FILES from the Makefile without
8197 # running `make'.
8198 DEPDIR=`sed -n -e '/^DEPDIR = / s///p' < "$mf"`
8199 test -z "$DEPDIR" && continue
8200 # When using ansi2knr, U may be empty or an underscore; expand it
8201 U=`sed -n -e '/^U = / s///p' < "$mf"`
8202 test -d "$dirpart/$DEPDIR" || mkdir "$dirpart/$DEPDIR"
8203 # We invoke sed twice because it is the simplest approach to
8204 # changing $(DEPDIR) to its actual value in the expansion.
8205 for file in `sed -n -e '
8206 /^DEP_FILES = .*\\\\$/ {
8207 s/^DEP_FILES = //
8208 :loop
8209 s/\\\\$//
8212 /\\\\$/ b loop
8215 /^DEP_FILES = / s/^DEP_FILES = //p' < "$mf" | \
8216 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
8217 # Make sure the directory exists.
8218 test -f "$dirpart/$file" && continue
8219 fdir=`echo "$file" | sed -e 's|/[^/]*$||'`
8220 $ac_aux_dir/mkinstalldirs "$dirpart/$fdir" > /dev/null 2>&1
8221 # echo "creating $dirpart/$file"
8222 echo '# dummy' > "$dirpart/$file"
8223 done
8224 done
8227 # Only add multilib support code if we just rebuilt top-level Makefile.
8228 case " $CONFIG_FILES " in
8229 *" Makefile "*)
8230 LD="${ORIGINAL_LD_FOR_MULTILIBS}"
8231 ac_file=Makefile . ${libgcj_basedir}/../config-ml.in
8233 esac
8235 # Make subdirectories and `.d' files. Look in both srcdir and
8236 # builddir for the .java files.
8237 h=`pwd`
8238 : > deps.mk
8239 ( (cd $srcdir && find . \( -name '*.java' -o -name '*.cc' \) -print) ;
8240 find . \( -name '*.java' -o -name '*.cc' \) -print) | \
8241 fgrep -v testsuite | \
8242 sed -e 's/\.java/.d/'\;'s/\.cc/.d/' | \
8243 while read f; do
8244 echo "include $f" >> deps.mk
8245 test -f $f || {
8247 d=`echo $f | sed -e 's,/[^/]*$,,'`
8249 if test ! -d $d; then
8250 $libgcj_basedir/../mkinstalldirs $d
8252 echo > $f
8254 done
8256 exit 0
8258 chmod +x $CONFIG_STATUS
8259 rm -fr confdefs* $ac_clean_files
8260 test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
8262 if test "$no_recursion" != yes; then
8264 # Remove --cache-file and --srcdir arguments so they do not pile up.
8265 ac_sub_configure_args=
8266 ac_prev=
8267 for ac_arg in $ac_configure_args; do
8268 if test -n "$ac_prev"; then
8269 ac_prev=
8270 continue
8272 case "$ac_arg" in
8273 -cache-file | --cache-file | --cache-fil | --cache-fi \
8274 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
8275 ac_prev=cache_file ;;
8276 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
8277 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
8279 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
8280 ac_prev=srcdir ;;
8281 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
8283 *) ac_sub_configure_args="$ac_sub_configure_args $ac_arg" ;;
8284 esac
8285 done
8287 for ac_config_dir in $DIRLTDL; do
8289 # Do not complain, so a configure script can configure whichever
8290 # parts of a large source tree are present.
8291 if test ! -d $srcdir/$ac_config_dir; then
8292 continue
8295 echo configuring in $ac_config_dir
8297 case "$srcdir" in
8298 .) ;;
8300 if test -d ./$ac_config_dir || mkdir ./$ac_config_dir; then :;
8301 else
8302 { echo "configure: error: can not create `pwd`/$ac_config_dir" 1>&2; exit 1; }
8305 esac
8307 ac_popdir=`pwd`
8308 cd $ac_config_dir
8310 # A "../" for each directory in /$ac_config_dir.
8311 ac_dots=`echo $ac_config_dir|sed -e 's%^\./%%' -e 's%[^/]$%&/%' -e 's%[^/]*/%../%g'`
8313 case "$srcdir" in
8314 .) # No --srcdir option. We are building in place.
8315 ac_sub_srcdir=$srcdir ;;
8316 /*) # Absolute path.
8317 ac_sub_srcdir=$srcdir/$ac_config_dir ;;
8318 *) # Relative path.
8319 ac_sub_srcdir=$ac_dots$srcdir/$ac_config_dir ;;
8320 esac
8322 # Check for guested configure; otherwise get Cygnus style configure.
8323 if test -f $ac_sub_srcdir/configure; then
8324 ac_sub_configure=$ac_sub_srcdir/configure
8325 elif test -f $ac_sub_srcdir/configure.in; then
8326 ac_sub_configure=$ac_configure
8327 else
8328 echo "configure: warning: no configuration information is in $ac_config_dir" 1>&2
8329 ac_sub_configure=
8332 # The recursion is here.
8333 if test -n "$ac_sub_configure"; then
8335 # Make the cache file name correct relative to the subdirectory.
8336 case "$cache_file" in
8337 /*) ac_sub_cache_file=$cache_file ;;
8338 *) # Relative path.
8339 ac_sub_cache_file="$ac_dots$cache_file" ;;
8340 esac
8341 case "$ac_given_INSTALL" in
8342 [/$]*) INSTALL="$ac_given_INSTALL" ;;
8343 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
8344 esac
8346 echo "running ${CONFIG_SHELL-/bin/sh} $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_sub_srcdir"
8347 # The eval makes quoting arguments work.
8348 if eval ${CONFIG_SHELL-/bin/sh} $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_sub_srcdir
8349 then :
8350 else
8351 { echo "configure: error: $ac_sub_configure failed for $ac_config_dir" 1>&2; exit 1; }
8355 cd $ac_popdir
8356 done