Do not bias REG_N_REFS by loop_depth when optimising for size.
[official-gcc.git] / zlib / configure
blob5448edf7a0c3495859cbad65d0eb9f432bceed2c
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 --with-system-zlib use installed libz"
23 ac_help="$ac_help
24 --enable-maintainer-mode enable make rules and dependencies not useful
25 (and sometimes confusing) to the casual installer"
26 ac_help="$ac_help
27 --enable-shared[=PKGS] build shared libraries [default=yes]"
28 ac_help="$ac_help
29 --enable-static[=PKGS] build static libraries [default=yes]"
30 ac_help="$ac_help
31 --enable-fast-install[=PKGS] optimize for fast installation [default=yes]"
32 ac_help="$ac_help
33 --with-gnu-ld assume the C compiler uses GNU ld [default=no]"
34 ac_help="$ac_help
35 --disable-libtool-lock force libtool not to do file locking"
37 # Initialize some variables set by options.
38 # The variables have the same names as the options, with
39 # dashes changed to underlines.
40 build=NONE
41 cache_file=./config.cache
42 exec_prefix=NONE
43 host=NONE
44 no_create=
45 nonopt=NONE
46 no_recursion=
47 prefix=NONE
48 program_prefix=NONE
49 program_suffix=NONE
50 program_transform_name=s,x,x,
51 silent=
52 site=
53 sitefile=
54 srcdir=
55 target=NONE
56 verbose=
57 x_includes=NONE
58 x_libraries=NONE
59 bindir='${exec_prefix}/bin'
60 sbindir='${exec_prefix}/sbin'
61 libexecdir='${exec_prefix}/libexec'
62 datadir='${prefix}/share'
63 sysconfdir='${prefix}/etc'
64 sharedstatedir='${prefix}/com'
65 localstatedir='${prefix}/var'
66 libdir='${exec_prefix}/lib'
67 includedir='${prefix}/include'
68 oldincludedir='/usr/include'
69 infodir='${prefix}/info'
70 mandir='${prefix}/man'
72 # Initialize some other variables.
73 subdirs=
74 MFLAGS= MAKEFLAGS=
75 SHELL=${CONFIG_SHELL-/bin/sh}
76 # Maximum number of lines to put in a shell here document.
77 ac_max_here_lines=12
79 ac_prev=
80 for ac_option
83 # If the previous option needs an argument, assign it.
84 if test -n "$ac_prev"; then
85 eval "$ac_prev=\$ac_option"
86 ac_prev=
87 continue
90 case "$ac_option" in
91 -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
92 *) ac_optarg= ;;
93 esac
95 # Accept the important Cygnus configure options, so we can diagnose typos.
97 case "$ac_option" in
99 -bindir | --bindir | --bindi | --bind | --bin | --bi)
100 ac_prev=bindir ;;
101 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
102 bindir="$ac_optarg" ;;
104 -build | --build | --buil | --bui | --bu)
105 ac_prev=build ;;
106 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
107 build="$ac_optarg" ;;
109 -cache-file | --cache-file | --cache-fil | --cache-fi \
110 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
111 ac_prev=cache_file ;;
112 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
113 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
114 cache_file="$ac_optarg" ;;
116 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
117 ac_prev=datadir ;;
118 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
119 | --da=*)
120 datadir="$ac_optarg" ;;
122 -disable-* | --disable-*)
123 ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
124 # Reject names that are not valid shell variable names.
125 if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
126 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
128 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
129 eval "enable_${ac_feature}=no" ;;
131 -enable-* | --enable-*)
132 ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
133 # Reject names that are not valid shell variable names.
134 if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
135 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
137 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
138 case "$ac_option" in
139 *=*) ;;
140 *) ac_optarg=yes ;;
141 esac
142 eval "enable_${ac_feature}='$ac_optarg'" ;;
144 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
145 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
146 | --exec | --exe | --ex)
147 ac_prev=exec_prefix ;;
148 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
149 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
150 | --exec=* | --exe=* | --ex=*)
151 exec_prefix="$ac_optarg" ;;
153 -gas | --gas | --ga | --g)
154 # Obsolete; use --with-gas.
155 with_gas=yes ;;
157 -help | --help | --hel | --he)
158 # Omit some internal or obsolete options to make the list less imposing.
159 # This message is too long to be a string in the A/UX 3.1 sh.
160 cat << EOF
161 Usage: configure [options] [host]
162 Options: [defaults in brackets after descriptions]
163 Configuration:
164 --cache-file=FILE cache test results in FILE
165 --help print this message
166 --no-create do not create output files
167 --quiet, --silent do not print \`checking...' messages
168 --site-file=FILE use FILE as the site file
169 --version print the version of autoconf that created configure
170 Directory and file names:
171 --prefix=PREFIX install architecture-independent files in PREFIX
172 [$ac_default_prefix]
173 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
174 [same as prefix]
175 --bindir=DIR user executables in DIR [EPREFIX/bin]
176 --sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
177 --libexecdir=DIR program executables in DIR [EPREFIX/libexec]
178 --datadir=DIR read-only architecture-independent data in DIR
179 [PREFIX/share]
180 --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
181 --sharedstatedir=DIR modifiable architecture-independent data in DIR
182 [PREFIX/com]
183 --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
184 --libdir=DIR object code libraries in DIR [EPREFIX/lib]
185 --includedir=DIR C header files in DIR [PREFIX/include]
186 --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
187 --infodir=DIR info documentation in DIR [PREFIX/info]
188 --mandir=DIR man documentation in DIR [PREFIX/man]
189 --srcdir=DIR find the sources in DIR [configure dir or ..]
190 --program-prefix=PREFIX prepend PREFIX to installed program names
191 --program-suffix=SUFFIX append SUFFIX to installed program names
192 --program-transform-name=PROGRAM
193 run sed PROGRAM on installed program names
195 cat << EOF
196 Host type:
197 --build=BUILD configure for building on BUILD [BUILD=HOST]
198 --host=HOST configure for HOST [guessed]
199 --target=TARGET configure for TARGET [TARGET=HOST]
200 Features and packages:
201 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
202 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
203 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
204 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
205 --x-includes=DIR X include files are in DIR
206 --x-libraries=DIR X library files are in DIR
208 if test -n "$ac_help"; then
209 echo "--enable and --with options recognized:$ac_help"
211 exit 0 ;;
213 -host | --host | --hos | --ho)
214 ac_prev=host ;;
215 -host=* | --host=* | --hos=* | --ho=*)
216 host="$ac_optarg" ;;
218 -includedir | --includedir | --includedi | --included | --include \
219 | --includ | --inclu | --incl | --inc)
220 ac_prev=includedir ;;
221 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
222 | --includ=* | --inclu=* | --incl=* | --inc=*)
223 includedir="$ac_optarg" ;;
225 -infodir | --infodir | --infodi | --infod | --info | --inf)
226 ac_prev=infodir ;;
227 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
228 infodir="$ac_optarg" ;;
230 -libdir | --libdir | --libdi | --libd)
231 ac_prev=libdir ;;
232 -libdir=* | --libdir=* | --libdi=* | --libd=*)
233 libdir="$ac_optarg" ;;
235 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
236 | --libexe | --libex | --libe)
237 ac_prev=libexecdir ;;
238 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
239 | --libexe=* | --libex=* | --libe=*)
240 libexecdir="$ac_optarg" ;;
242 -localstatedir | --localstatedir | --localstatedi | --localstated \
243 | --localstate | --localstat | --localsta | --localst \
244 | --locals | --local | --loca | --loc | --lo)
245 ac_prev=localstatedir ;;
246 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
247 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
248 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
249 localstatedir="$ac_optarg" ;;
251 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
252 ac_prev=mandir ;;
253 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
254 mandir="$ac_optarg" ;;
256 -nfp | --nfp | --nf)
257 # Obsolete; use --without-fp.
258 with_fp=no ;;
260 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
261 | --no-cr | --no-c)
262 no_create=yes ;;
264 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
265 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
266 no_recursion=yes ;;
268 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
269 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
270 | --oldin | --oldi | --old | --ol | --o)
271 ac_prev=oldincludedir ;;
272 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
273 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
274 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
275 oldincludedir="$ac_optarg" ;;
277 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
278 ac_prev=prefix ;;
279 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
280 prefix="$ac_optarg" ;;
282 -program-prefix | --program-prefix | --program-prefi | --program-pref \
283 | --program-pre | --program-pr | --program-p)
284 ac_prev=program_prefix ;;
285 -program-prefix=* | --program-prefix=* | --program-prefi=* \
286 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
287 program_prefix="$ac_optarg" ;;
289 -program-suffix | --program-suffix | --program-suffi | --program-suff \
290 | --program-suf | --program-su | --program-s)
291 ac_prev=program_suffix ;;
292 -program-suffix=* | --program-suffix=* | --program-suffi=* \
293 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
294 program_suffix="$ac_optarg" ;;
296 -program-transform-name | --program-transform-name \
297 | --program-transform-nam | --program-transform-na \
298 | --program-transform-n | --program-transform- \
299 | --program-transform | --program-transfor \
300 | --program-transfo | --program-transf \
301 | --program-trans | --program-tran \
302 | --progr-tra | --program-tr | --program-t)
303 ac_prev=program_transform_name ;;
304 -program-transform-name=* | --program-transform-name=* \
305 | --program-transform-nam=* | --program-transform-na=* \
306 | --program-transform-n=* | --program-transform-=* \
307 | --program-transform=* | --program-transfor=* \
308 | --program-transfo=* | --program-transf=* \
309 | --program-trans=* | --program-tran=* \
310 | --progr-tra=* | --program-tr=* | --program-t=*)
311 program_transform_name="$ac_optarg" ;;
313 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
314 | -silent | --silent | --silen | --sile | --sil)
315 silent=yes ;;
317 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
318 ac_prev=sbindir ;;
319 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
320 | --sbi=* | --sb=*)
321 sbindir="$ac_optarg" ;;
323 -sharedstatedir | --sharedstatedir | --sharedstatedi \
324 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
325 | --sharedst | --shareds | --shared | --share | --shar \
326 | --sha | --sh)
327 ac_prev=sharedstatedir ;;
328 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
329 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
330 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
331 | --sha=* | --sh=*)
332 sharedstatedir="$ac_optarg" ;;
334 -site | --site | --sit)
335 ac_prev=site ;;
336 -site=* | --site=* | --sit=*)
337 site="$ac_optarg" ;;
339 -site-file | --site-file | --site-fil | --site-fi | --site-f)
340 ac_prev=sitefile ;;
341 -site-file=* | --site-file=* | --site-fil=* | --site-fi=* | --site-f=*)
342 sitefile="$ac_optarg" ;;
344 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
345 ac_prev=srcdir ;;
346 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
347 srcdir="$ac_optarg" ;;
349 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
350 | --syscon | --sysco | --sysc | --sys | --sy)
351 ac_prev=sysconfdir ;;
352 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
353 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
354 sysconfdir="$ac_optarg" ;;
356 -target | --target | --targe | --targ | --tar | --ta | --t)
357 ac_prev=target ;;
358 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
359 target="$ac_optarg" ;;
361 -v | -verbose | --verbose | --verbos | --verbo | --verb)
362 verbose=yes ;;
364 -version | --version | --versio | --versi | --vers)
365 echo "configure generated by autoconf version 2.13"
366 exit 0 ;;
368 -with-* | --with-*)
369 ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
370 # Reject names that are not valid shell variable names.
371 if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
372 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
374 ac_package=`echo $ac_package| sed 's/-/_/g'`
375 case "$ac_option" in
376 *=*) ;;
377 *) ac_optarg=yes ;;
378 esac
379 eval "with_${ac_package}='$ac_optarg'" ;;
381 -without-* | --without-*)
382 ac_package=`echo $ac_option|sed -e 's/-*without-//'`
383 # Reject names that are not valid shell variable names.
384 if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
385 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
387 ac_package=`echo $ac_package| sed 's/-/_/g'`
388 eval "with_${ac_package}=no" ;;
390 --x)
391 # Obsolete; use --with-x.
392 with_x=yes ;;
394 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
395 | --x-incl | --x-inc | --x-in | --x-i)
396 ac_prev=x_includes ;;
397 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
398 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
399 x_includes="$ac_optarg" ;;
401 -x-libraries | --x-libraries | --x-librarie | --x-librari \
402 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
403 ac_prev=x_libraries ;;
404 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
405 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
406 x_libraries="$ac_optarg" ;;
408 -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
412 if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
413 echo "configure: warning: $ac_option: invalid host type" 1>&2
415 if test "x$nonopt" != xNONE; then
416 { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
418 nonopt="$ac_option"
421 esac
422 done
424 if test -n "$ac_prev"; then
425 { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
428 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
430 # File descriptor usage:
431 # 0 standard input
432 # 1 file creation
433 # 2 errors and warnings
434 # 3 some systems may open it to /dev/tty
435 # 4 used on the Kubota Titan
436 # 6 checking for... messages and results
437 # 5 compiler messages saved in config.log
438 if test "$silent" = yes; then
439 exec 6>/dev/null
440 else
441 exec 6>&1
443 exec 5>./config.log
445 echo "\
446 This file contains any messages produced by compilers while
447 running configure, to aid debugging if configure makes a mistake.
448 " 1>&5
450 # Strip out --no-create and --no-recursion so they do not pile up.
451 # Also quote any args containing shell metacharacters.
452 ac_configure_args=
453 for ac_arg
455 case "$ac_arg" in
456 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
457 | --no-cr | --no-c) ;;
458 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
459 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
460 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
461 ac_configure_args="$ac_configure_args '$ac_arg'" ;;
462 *) ac_configure_args="$ac_configure_args $ac_arg" ;;
463 esac
464 done
466 # NLS nuisances.
467 # Only set these to C if already set. These must not be set unconditionally
468 # because not all systems understand e.g. LANG=C (notably SCO).
469 # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
470 # Non-C LC_CTYPE values break the ctype check.
471 if test "${LANG+set}" = set; then LANG=C; export LANG; fi
472 if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
473 if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
474 if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi
476 # confdefs.h avoids OS command line length limits that DEFS can exceed.
477 rm -rf conftest* confdefs.h
478 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
479 echo > confdefs.h
481 # A filename unique to this package, relative to the directory that
482 # configure is in, which we can look for to find out if srcdir is correct.
483 ac_unique_file=zlib.h
485 # Find the source files, if location was not specified.
486 if test -z "$srcdir"; then
487 ac_srcdir_defaulted=yes
488 # Try the directory containing this script, then its parent.
489 ac_prog=$0
490 ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
491 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
492 srcdir=$ac_confdir
493 if test ! -r $srcdir/$ac_unique_file; then
494 srcdir=..
496 else
497 ac_srcdir_defaulted=no
499 if test ! -r $srcdir/$ac_unique_file; then
500 if test "$ac_srcdir_defaulted" = yes; then
501 { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
502 else
503 { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
506 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
508 # Prefer explicitly selected file to automatically selected ones.
509 if test -z "$sitefile"; then
510 if test -z "$CONFIG_SITE"; then
511 if test "x$prefix" != xNONE; then
512 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
513 else
514 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
517 else
518 CONFIG_SITE="$sitefile"
520 for ac_site_file in $CONFIG_SITE; do
521 if test -r "$ac_site_file"; then
522 echo "loading site script $ac_site_file"
523 . "$ac_site_file"
525 done
527 if test -r "$cache_file"; then
528 echo "loading cache $cache_file"
529 . $cache_file
530 else
531 echo "creating cache $cache_file"
532 > $cache_file
535 ac_ext=c
536 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
537 ac_cpp='$CPP $CPPFLAGS'
538 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
539 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
540 cross_compiling=$ac_cv_prog_cc_cross
542 ac_exeext=
543 ac_objext=o
544 if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
545 # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
546 if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
547 ac_n= ac_c='
548 ' ac_t=' '
549 else
550 ac_n=-n ac_c= ac_t=
552 else
553 ac_n= ac_c='\c' ac_t=
557 ac_aux_dir=
558 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
559 if test -f $ac_dir/install-sh; then
560 ac_aux_dir=$ac_dir
561 ac_install_sh="$ac_aux_dir/install-sh -c"
562 break
563 elif test -f $ac_dir/install.sh; then
564 ac_aux_dir=$ac_dir
565 ac_install_sh="$ac_aux_dir/install.sh -c"
566 break
568 done
569 if test -z "$ac_aux_dir"; then
570 { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
572 ac_config_guess=$ac_aux_dir/config.guess
573 ac_config_sub=$ac_aux_dir/config.sub
574 ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
577 # Do some error checking and defaulting for the host and target type.
578 # The inputs are:
579 # configure --host=HOST --target=TARGET --build=BUILD NONOPT
581 # The rules are:
582 # 1. You are not allowed to specify --host, --target, and nonopt at the
583 # same time.
584 # 2. Host defaults to nonopt.
585 # 3. If nonopt is not specified, then host defaults to the current host,
586 # as determined by config.guess.
587 # 4. Target and build default to nonopt.
588 # 5. If nonopt is not specified, then target and build default to host.
590 # The aliases save the names the user supplied, while $host etc.
591 # will get canonicalized.
592 case $host---$target---$nonopt in
593 NONE---*---* | *---NONE---* | *---*---NONE) ;;
594 *) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
595 esac
598 # Make sure we can run config.sub.
599 if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
600 else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
603 echo $ac_n "checking host system type""... $ac_c" 1>&6
604 echo "configure:605: checking host system type" >&5
606 host_alias=$host
607 case "$host_alias" in
608 NONE)
609 case $nonopt in
610 NONE)
611 if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
612 else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
613 fi ;;
614 *) host_alias=$nonopt ;;
615 esac ;;
616 esac
618 host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
619 host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
620 host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
621 host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
622 echo "$ac_t""$host" 1>&6
624 echo $ac_n "checking target system type""... $ac_c" 1>&6
625 echo "configure:626: checking target system type" >&5
627 target_alias=$target
628 case "$target_alias" in
629 NONE)
630 case $nonopt in
631 NONE) target_alias=$host_alias ;;
632 *) target_alias=$nonopt ;;
633 esac ;;
634 esac
636 target=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $target_alias`
637 target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
638 target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
639 target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
640 echo "$ac_t""$target" 1>&6
642 echo $ac_n "checking build system type""... $ac_c" 1>&6
643 echo "configure:644: checking build system type" >&5
645 build_alias=$build
646 case "$build_alias" in
647 NONE)
648 case $nonopt in
649 NONE) build_alias=$host_alias ;;
650 *) build_alias=$nonopt ;;
651 esac ;;
652 esac
654 build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias`
655 build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
656 build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
657 build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
658 echo "$ac_t""$build" 1>&6
660 test "$host_alias" != "$target_alias" &&
661 test "$program_prefix$program_suffix$program_transform_name" = \
662 NONENONEs,x,x, &&
663 program_prefix=${target_alias}-
665 # Find a good install program. We prefer a C program (faster),
666 # so one script is as good as another. But avoid the broken or
667 # incompatible versions:
668 # SysV /etc/install, /usr/sbin/install
669 # SunOS /usr/etc/install
670 # IRIX /sbin/install
671 # AIX /bin/install
672 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
673 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
674 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
675 # ./install, which can be erroneously created by make from ./install.sh.
676 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
677 echo "configure:678: checking for a BSD compatible install" >&5
678 if test -z "$INSTALL"; then
679 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
680 echo $ac_n "(cached) $ac_c" 1>&6
681 else
682 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":"
683 for ac_dir in $PATH; do
684 # Account for people who put trailing slashes in PATH elements.
685 case "$ac_dir/" in
686 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
688 # OSF1 and SCO ODT 3.0 have their own names for install.
689 # Don't use installbsd from OSF since it installs stuff as root
690 # by default.
691 for ac_prog in ginstall scoinst install; do
692 if test -f $ac_dir/$ac_prog; then
693 if test $ac_prog = install &&
694 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
695 # AIX install. It has an incompatible calling convention.
697 else
698 ac_cv_path_install="$ac_dir/$ac_prog -c"
699 break 2
702 done
704 esac
705 done
706 IFS="$ac_save_IFS"
709 if test "${ac_cv_path_install+set}" = set; then
710 INSTALL="$ac_cv_path_install"
711 else
712 # As a last resort, use the slow shell script. We don't cache a
713 # path for INSTALL within a source directory, because that will
714 # break other packages using the cache if that directory is
715 # removed, or if the path is relative.
716 INSTALL="$ac_install_sh"
719 echo "$ac_t""$INSTALL" 1>&6
721 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
722 # It thinks the first close brace ends the variable substitution.
723 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
725 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
727 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
729 echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
730 echo "configure:731: checking whether build environment is sane" >&5
731 # Just in case
732 sleep 1
733 echo timestamp > conftestfile
734 # Do `set' in a subshell so we don't clobber the current shell's
735 # arguments. Must try -L first in case configure is actually a
736 # symlink; some systems play weird games with the mod time of symlinks
737 # (eg FreeBSD returns the mod time of the symlink's containing
738 # directory).
739 if (
740 set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
741 if test "$*" = "X"; then
742 # -L didn't work.
743 set X `ls -t $srcdir/configure conftestfile`
745 if test "$*" != "X $srcdir/configure conftestfile" \
746 && test "$*" != "X conftestfile $srcdir/configure"; then
748 # If neither matched, then we have a broken ls. This can happen
749 # if, for instance, CONFIG_SHELL is bash and it inherits a
750 # broken ls alias from the environment. This has actually
751 # happened. Such a system could not be considered "sane".
752 { echo "configure: error: ls -t appears to fail. Make sure there is not a broken
753 alias in your environment" 1>&2; exit 1; }
756 test "$2" = conftestfile
758 then
759 # Ok.
761 else
762 { echo "configure: error: newly created file is older than distributed files!
763 Check your system clock" 1>&2; exit 1; }
765 rm -f conftest*
766 echo "$ac_t""yes" 1>&6
767 if test "$program_transform_name" = s,x,x,; then
768 program_transform_name=
769 else
770 # Double any \ or $. echo might interpret backslashes.
771 cat <<\EOF_SED > conftestsed
772 s,\\,\\\\,g; s,\$,$$,g
773 EOF_SED
774 program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
775 rm -f conftestsed
777 test "$program_prefix" != NONE &&
778 program_transform_name="s,^,${program_prefix},; $program_transform_name"
779 # Use a double $ so make ignores it.
780 test "$program_suffix" != NONE &&
781 program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
783 # sed with no file args requires a program.
784 test "$program_transform_name" = "" && program_transform_name="s,x,x,"
786 echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
787 echo "configure:788: checking whether ${MAKE-make} sets \${MAKE}" >&5
788 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
789 if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
790 echo $ac_n "(cached) $ac_c" 1>&6
791 else
792 cat > conftestmake <<\EOF
793 all:
794 @echo 'ac_maketemp="${MAKE}"'
796 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
797 eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
798 if test -n "$ac_maketemp"; then
799 eval ac_cv_prog_make_${ac_make}_set=yes
800 else
801 eval ac_cv_prog_make_${ac_make}_set=no
803 rm -f conftestmake
805 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
806 echo "$ac_t""yes" 1>&6
807 SET_MAKE=
808 else
809 echo "$ac_t""no" 1>&6
810 SET_MAKE="MAKE=${MAKE-make}"
814 PACKAGE=zlib
816 VERSION=1.1.3
818 if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
819 { echo "configure: error: source directory already configured; run "make distclean" there first" 1>&2; exit 1; }
821 cat >> confdefs.h <<EOF
822 #define PACKAGE "$PACKAGE"
825 cat >> confdefs.h <<EOF
826 #define VERSION "$VERSION"
831 missing_dir=`cd $ac_aux_dir && pwd`
832 echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
833 echo "configure:834: checking for working aclocal" >&5
834 # Run test in a subshell; some versions of sh will print an error if
835 # an executable is not found, even if stderr is redirected.
836 # Redirect stdin to placate older versions of autoconf. Sigh.
837 if (aclocal --version) < /dev/null > /dev/null 2>&1; then
838 ACLOCAL=aclocal
839 echo "$ac_t""found" 1>&6
840 else
841 ACLOCAL="$missing_dir/missing aclocal"
842 echo "$ac_t""missing" 1>&6
845 echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
846 echo "configure:847: checking for working autoconf" >&5
847 # Run test in a subshell; some versions of sh will print an error if
848 # an executable is not found, even if stderr is redirected.
849 # Redirect stdin to placate older versions of autoconf. Sigh.
850 if (autoconf --version) < /dev/null > /dev/null 2>&1; then
851 AUTOCONF=autoconf
852 echo "$ac_t""found" 1>&6
853 else
854 AUTOCONF="$missing_dir/missing autoconf"
855 echo "$ac_t""missing" 1>&6
858 echo $ac_n "checking for working automake""... $ac_c" 1>&6
859 echo "configure:860: checking for working automake" >&5
860 # Run test in a subshell; some versions of sh will print an error if
861 # an executable is not found, even if stderr is redirected.
862 # Redirect stdin to placate older versions of autoconf. Sigh.
863 if (automake --version) < /dev/null > /dev/null 2>&1; then
864 AUTOMAKE=automake
865 echo "$ac_t""found" 1>&6
866 else
867 AUTOMAKE="$missing_dir/missing automake"
868 echo "$ac_t""missing" 1>&6
871 echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
872 echo "configure:873: checking for working autoheader" >&5
873 # Run test in a subshell; some versions of sh will print an error if
874 # an executable is not found, even if stderr is redirected.
875 # Redirect stdin to placate older versions of autoconf. Sigh.
876 if (autoheader --version) < /dev/null > /dev/null 2>&1; then
877 AUTOHEADER=autoheader
878 echo "$ac_t""found" 1>&6
879 else
880 AUTOHEADER="$missing_dir/missing autoheader"
881 echo "$ac_t""missing" 1>&6
884 echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
885 echo "configure:886: checking for working makeinfo" >&5
886 # Run test in a subshell; some versions of sh will print an error if
887 # an executable is not found, even if stderr is redirected.
888 # Redirect stdin to placate older versions of autoconf. Sigh.
889 if (makeinfo --version) < /dev/null > /dev/null 2>&1; then
890 MAKEINFO=makeinfo
891 echo "$ac_t""found" 1>&6
892 else
893 MAKEINFO="$missing_dir/missing makeinfo"
894 echo "$ac_t""missing" 1>&6
899 # Check whether --with-target-subdir or --without-target-subdir was given.
900 if test "${with_target_subdir+set}" = set; then
901 withval="$with_target_subdir"
905 # Check whether --with-cross-host or --without-cross-host was given.
906 if test "${with_cross_host+set}" = set; then
907 withval="$with_cross_host"
912 # Check whether --enable-multilib or --disable-multilib was given.
913 if test "${enable_multilib+set}" = set; then
914 enableval="$enable_multilib"
915 case "${enableval}" in
916 yes) multilib=yes ;;
917 no) multilib=no ;;
918 *) { echo "configure: error: bad value ${enableval} for multilib option" 1>&2; exit 1; } ;;
919 esac
920 else
921 multilib=yes
925 if test "${srcdir}" = "."; then
926 if test "${with_target_subdir}" != "."; then
927 zlib_basedir="${srcdir}/${with_multisrctop}../"
928 else
929 zlib_basedir="${srcdir}/${with_multisrctop}"
931 else
932 zlib_basedir="${srcdir}/"
936 # Check whether --with-system-zlib or --without-system-zlib was given.
937 if test "${with_system_zlib+set}" = set; then
938 withval="$with_system_zlib"
944 # Extract the first word of "gcc", so it can be a program name with args.
945 set dummy gcc; ac_word=$2
946 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
947 echo "configure:948: checking for $ac_word" >&5
948 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
949 echo $ac_n "(cached) $ac_c" 1>&6
950 else
951 if test -n "$CC"; then
952 ac_cv_prog_CC="$CC" # Let the user override the test.
953 else
954 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
955 ac_dummy="$PATH"
956 for ac_dir in $ac_dummy; do
957 test -z "$ac_dir" && ac_dir=.
958 if test -f $ac_dir/$ac_word; then
959 ac_cv_prog_CC="gcc"
960 break
962 done
963 IFS="$ac_save_ifs"
966 CC="$ac_cv_prog_CC"
967 if test -n "$CC"; then
968 echo "$ac_t""$CC" 1>&6
969 else
970 echo "$ac_t""no" 1>&6
973 if test -z "$CC"; then
974 # Extract the first word of "cc", so it can be a program name with args.
975 set dummy cc; ac_word=$2
976 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
977 echo "configure:978: checking for $ac_word" >&5
978 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
979 echo $ac_n "(cached) $ac_c" 1>&6
980 else
981 if test -n "$CC"; then
982 ac_cv_prog_CC="$CC" # Let the user override the test.
983 else
984 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
985 ac_prog_rejected=no
986 ac_dummy="$PATH"
987 for ac_dir in $ac_dummy; do
988 test -z "$ac_dir" && ac_dir=.
989 if test -f $ac_dir/$ac_word; then
990 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
991 ac_prog_rejected=yes
992 continue
994 ac_cv_prog_CC="cc"
995 break
997 done
998 IFS="$ac_save_ifs"
999 if test $ac_prog_rejected = yes; then
1000 # We found a bogon in the path, so make sure we never use it.
1001 set dummy $ac_cv_prog_CC
1002 shift
1003 if test $# -gt 0; then
1004 # We chose a different compiler from the bogus one.
1005 # However, it has the same basename, so the bogon will be chosen
1006 # first if we set CC to just the basename; use the full file name.
1007 shift
1008 set dummy "$ac_dir/$ac_word" "$@"
1009 shift
1010 ac_cv_prog_CC="$@"
1015 CC="$ac_cv_prog_CC"
1016 if test -n "$CC"; then
1017 echo "$ac_t""$CC" 1>&6
1018 else
1019 echo "$ac_t""no" 1>&6
1022 test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
1025 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
1026 echo "configure:1027: checking whether we are using GNU C" >&5
1027 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
1028 echo $ac_n "(cached) $ac_c" 1>&6
1029 else
1030 cat > conftest.c <<EOF
1031 #ifdef __GNUC__
1032 yes;
1033 #endif
1035 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1036: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
1036 ac_cv_prog_gcc=yes
1037 else
1038 ac_cv_prog_gcc=no
1042 echo "$ac_t""$ac_cv_prog_gcc" 1>&6
1044 if test $ac_cv_prog_gcc = yes; then
1045 GCC=yes
1046 ac_test_CFLAGS="${CFLAGS+set}"
1047 ac_save_CFLAGS="$CFLAGS"
1048 CFLAGS=
1049 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
1050 echo "configure:1051: checking whether ${CC-cc} accepts -g" >&5
1051 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
1052 echo $ac_n "(cached) $ac_c" 1>&6
1053 else
1054 echo 'void f(){}' > conftest.c
1055 if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
1056 ac_cv_prog_cc_g=yes
1057 else
1058 ac_cv_prog_cc_g=no
1060 rm -f conftest*
1064 echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
1065 if test "$ac_test_CFLAGS" = set; then
1066 CFLAGS="$ac_save_CFLAGS"
1067 elif test $ac_cv_prog_cc_g = yes; then
1068 CFLAGS="-g -O2"
1069 else
1070 CFLAGS="-O2"
1072 else
1073 GCC=
1074 test "${CFLAGS+set}" = set || CFLAGS="-g"
1078 echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
1079 echo "configure:1080: checking whether to enable maintainer-specific portions of Makefiles" >&5
1080 # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
1081 if test "${enable_maintainer_mode+set}" = set; then
1082 enableval="$enable_maintainer_mode"
1083 USE_MAINTAINER_MODE=$enableval
1084 else
1085 USE_MAINTAINER_MODE=no
1088 echo "$ac_t""$USE_MAINTAINER_MODE" 1>&6
1091 if test $USE_MAINTAINER_MODE = yes; then
1092 MAINTAINER_MODE_TRUE=
1093 MAINTAINER_MODE_FALSE='#'
1094 else
1095 MAINTAINER_MODE_TRUE='#'
1096 MAINTAINER_MODE_FALSE=
1098 MAINT=$MAINTAINER_MODE_TRUE
1101 echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
1102 echo "configure:1103: checking for Cygwin environment" >&5
1103 if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
1104 echo $ac_n "(cached) $ac_c" 1>&6
1105 else
1106 cat > conftest.$ac_ext <<EOF
1107 #line 1108 "configure"
1108 #include "confdefs.h"
1110 int main() {
1112 #ifndef __CYGWIN__
1113 #define __CYGWIN__ __CYGWIN32__
1114 #endif
1115 return __CYGWIN__;
1116 ; return 0; }
1118 if { (eval echo configure:1119: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1119 rm -rf conftest*
1120 ac_cv_cygwin=yes
1121 else
1122 echo "configure: failed program was:" >&5
1123 cat conftest.$ac_ext >&5
1124 rm -rf conftest*
1125 ac_cv_cygwin=no
1127 rm -f conftest*
1128 rm -f conftest*
1131 echo "$ac_t""$ac_cv_cygwin" 1>&6
1132 CYGWIN=
1133 test "$ac_cv_cygwin" = yes && CYGWIN=yes
1134 echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
1135 echo "configure:1136: checking for mingw32 environment" >&5
1136 if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
1137 echo $ac_n "(cached) $ac_c" 1>&6
1138 else
1139 cat > conftest.$ac_ext <<EOF
1140 #line 1141 "configure"
1141 #include "confdefs.h"
1143 int main() {
1144 return __MINGW32__;
1145 ; return 0; }
1147 if { (eval echo configure:1148: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1148 rm -rf conftest*
1149 ac_cv_mingw32=yes
1150 else
1151 echo "configure: failed program was:" >&5
1152 cat conftest.$ac_ext >&5
1153 rm -rf conftest*
1154 ac_cv_mingw32=no
1156 rm -f conftest*
1157 rm -f conftest*
1160 echo "$ac_t""$ac_cv_mingw32" 1>&6
1161 MINGW32=
1162 test "$ac_cv_mingw32" = yes && MINGW32=yes
1165 echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
1166 echo "configure:1167: checking for executable suffix" >&5
1167 if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
1168 echo $ac_n "(cached) $ac_c" 1>&6
1169 else
1170 if test "$CYGWIN" = yes || test "$MINGW32" = yes; then
1171 ac_cv_exeext=.exe
1172 else
1173 rm -f conftest*
1174 echo 'int main () { return 0; }' > conftest.$ac_ext
1175 ac_cv_exeext=
1176 if { (eval echo configure:1177: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
1177 for file in conftest.*; do
1178 case $file in
1179 *.c | *.o | *.obj | *.ilk | *.pdb) ;;
1180 *) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
1181 esac
1182 done
1183 else
1184 { echo "configure: error: installation or configuration problem: compiler cannot create executables." 1>&2; exit 1; }
1186 rm -f conftest*
1187 test x"${ac_cv_exeext}" = x && ac_cv_exeext=no
1191 EXEEXT=""
1192 test x"${ac_cv_exeext}" != xno && EXEEXT=${ac_cv_exeext}
1193 echo "$ac_t""${ac_cv_exeext}" 1>&6
1194 ac_exeext=$EXEEXT
1197 ac_aux_dir=
1198 for ac_dir in .. $srcdir/..; do
1199 if test -f $ac_dir/install-sh; then
1200 ac_aux_dir=$ac_dir
1201 ac_install_sh="$ac_aux_dir/install-sh -c"
1202 break
1203 elif test -f $ac_dir/install.sh; then
1204 ac_aux_dir=$ac_dir
1205 ac_install_sh="$ac_aux_dir/install.sh -c"
1206 break
1208 done
1209 if test -z "$ac_aux_dir"; then
1210 { echo "configure: error: can not find install-sh or install.sh in .. $srcdir/.." 1>&2; exit 1; }
1212 ac_config_guess=$ac_aux_dir/config.guess
1213 ac_config_sub=$ac_aux_dir/config.sub
1214 ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
1217 # Check whether --enable-shared or --disable-shared was given.
1218 if test "${enable_shared+set}" = set; then
1219 enableval="$enable_shared"
1220 p=${PACKAGE-default}
1221 case "$enableval" in
1222 yes) enable_shared=yes ;;
1223 no) enable_shared=no ;;
1225 enable_shared=no
1226 # Look at the argument we got. We use all the common list separators.
1227 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
1228 for pkg in $enableval; do
1229 if test "X$pkg" = "X$p"; then
1230 enable_shared=yes
1232 done
1233 IFS="$ac_save_ifs"
1235 esac
1236 else
1237 enable_shared=yes
1240 # Check whether --enable-static or --disable-static was given.
1241 if test "${enable_static+set}" = set; then
1242 enableval="$enable_static"
1243 p=${PACKAGE-default}
1244 case "$enableval" in
1245 yes) enable_static=yes ;;
1246 no) enable_static=no ;;
1248 enable_static=no
1249 # Look at the argument we got. We use all the common list separators.
1250 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
1251 for pkg in $enableval; do
1252 if test "X$pkg" = "X$p"; then
1253 enable_static=yes
1255 done
1256 IFS="$ac_save_ifs"
1258 esac
1259 else
1260 enable_static=yes
1263 # Check whether --enable-fast-install or --disable-fast-install was given.
1264 if test "${enable_fast_install+set}" = set; then
1265 enableval="$enable_fast_install"
1266 p=${PACKAGE-default}
1267 case "$enableval" in
1268 yes) enable_fast_install=yes ;;
1269 no) enable_fast_install=no ;;
1271 enable_fast_install=no
1272 # Look at the argument we got. We use all the common list separators.
1273 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
1274 for pkg in $enableval; do
1275 if test "X$pkg" = "X$p"; then
1276 enable_fast_install=yes
1278 done
1279 IFS="$ac_save_ifs"
1281 esac
1282 else
1283 enable_fast_install=yes
1286 # Extract the first word of "ranlib", so it can be a program name with args.
1287 set dummy ranlib; ac_word=$2
1288 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1289 echo "configure:1290: checking for $ac_word" >&5
1290 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
1291 echo $ac_n "(cached) $ac_c" 1>&6
1292 else
1293 if test -n "$RANLIB"; then
1294 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1295 else
1296 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1297 ac_dummy="$PATH"
1298 for ac_dir in $ac_dummy; do
1299 test -z "$ac_dir" && ac_dir=.
1300 if test -f $ac_dir/$ac_word; then
1301 ac_cv_prog_RANLIB="ranlib"
1302 break
1304 done
1305 IFS="$ac_save_ifs"
1306 test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
1309 RANLIB="$ac_cv_prog_RANLIB"
1310 if test -n "$RANLIB"; then
1311 echo "$ac_t""$RANLIB" 1>&6
1312 else
1313 echo "$ac_t""no" 1>&6
1316 # Check whether --with-gnu-ld or --without-gnu-ld was given.
1317 if test "${with_gnu_ld+set}" = set; then
1318 withval="$with_gnu_ld"
1319 test "$withval" = no || with_gnu_ld=yes
1320 else
1321 with_gnu_ld=no
1324 ac_prog=ld
1325 if test "$ac_cv_prog_gcc" = yes; then
1326 # Check if gcc -print-prog-name=ld gives a path.
1327 echo $ac_n "checking for ld used by GCC""... $ac_c" 1>&6
1328 echo "configure:1329: checking for ld used by GCC" >&5
1329 ac_prog=`($CC -print-prog-name=ld) 2>&5`
1330 case "$ac_prog" in
1331 # Accept absolute paths.
1332 /* | [A-Za-z]:[\\/]*)
1333 re_direlt='/[^/][^/]*/\.\./'
1334 # Canonicalize the path of ld
1335 ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
1336 while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
1337 ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
1338 done
1339 test -z "$LD" && LD="$ac_prog"
1342 # If it fails, then pretend we aren't using GCC.
1343 ac_prog=ld
1346 # If it is relative, then search for the first ld in PATH.
1347 with_gnu_ld=unknown
1349 esac
1350 elif test "$with_gnu_ld" = yes; then
1351 echo $ac_n "checking for GNU ld""... $ac_c" 1>&6
1352 echo "configure:1353: checking for GNU ld" >&5
1353 else
1354 echo $ac_n "checking for non-GNU ld""... $ac_c" 1>&6
1355 echo "configure:1356: checking for non-GNU ld" >&5
1357 if eval "test \"`echo '$''{'ac_cv_path_LD'+set}'`\" = set"; then
1358 echo $ac_n "(cached) $ac_c" 1>&6
1359 else
1360 if test -z "$LD"; then
1361 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1362 for ac_dir in $PATH; do
1363 test -z "$ac_dir" && ac_dir=.
1364 if test -f "$ac_dir/$ac_prog"; then
1365 ac_cv_path_LD="$ac_dir/$ac_prog"
1366 # Check to see if the program is GNU ld. I'd rather use --version,
1367 # but apparently some GNU ld's only accept -v.
1368 # Break only if it was the GNU/non-GNU ld that we prefer.
1369 if "$ac_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
1370 test "$with_gnu_ld" != no && break
1371 else
1372 test "$with_gnu_ld" != yes && break
1375 done
1376 IFS="$ac_save_ifs"
1377 else
1378 ac_cv_path_LD="$LD" # Let the user override the test with a path.
1382 LD="$ac_cv_path_LD"
1383 if test -n "$LD"; then
1384 echo "$ac_t""$LD" 1>&6
1385 else
1386 echo "$ac_t""no" 1>&6
1388 test -z "$LD" && { echo "configure: error: no acceptable ld found in \$PATH" 1>&2; exit 1; }
1390 echo $ac_n "checking if the linker ($LD) is GNU ld""... $ac_c" 1>&6
1391 echo "configure:1392: checking if the linker ($LD) is GNU ld" >&5
1392 if eval "test \"`echo '$''{'ac_cv_prog_gnu_ld'+set}'`\" = set"; then
1393 echo $ac_n "(cached) $ac_c" 1>&6
1394 else
1395 # I'd rather use --version here, but apparently some GNU ld's only accept -v.
1396 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
1397 ac_cv_prog_gnu_ld=yes
1398 else
1399 ac_cv_prog_gnu_ld=no
1403 echo "$ac_t""$ac_cv_prog_gnu_ld" 1>&6
1406 echo $ac_n "checking for BSD-compatible nm""... $ac_c" 1>&6
1407 echo "configure:1408: checking for BSD-compatible nm" >&5
1408 if eval "test \"`echo '$''{'ac_cv_path_NM'+set}'`\" = set"; then
1409 echo $ac_n "(cached) $ac_c" 1>&6
1410 else
1411 if test -n "$NM"; then
1412 # Let the user override the test.
1413 ac_cv_path_NM="$NM"
1414 else
1415 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1416 for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do
1417 test -z "$ac_dir" && ac_dir=.
1418 if test -f $ac_dir/nm; then
1419 # Check to see if the nm accepts a BSD-compat flag.
1420 # Adding the `sed 1q' prevents false positives on HP-UX, which says:
1421 # nm: unknown option "B" ignored
1422 if ($ac_dir/nm -B /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then
1423 ac_cv_path_NM="$ac_dir/nm -B"
1424 break
1425 elif ($ac_dir/nm -p /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then
1426 ac_cv_path_NM="$ac_dir/nm -p"
1427 break
1428 else
1429 ac_cv_path_NM=${ac_cv_path_NM="$ac_dir/nm"} # keep the first match, but
1430 continue # so that we can try to find one that supports BSD flags
1433 done
1434 IFS="$ac_save_ifs"
1435 test -z "$ac_cv_path_NM" && ac_cv_path_NM=nm
1439 NM="$ac_cv_path_NM"
1440 echo "$ac_t""$NM" 1>&6
1443 # Check for command to grab the raw symbol name followed by C symbol from nm.
1444 echo $ac_n "checking command to parse $NM output""... $ac_c" 1>&6
1445 echo "configure:1446: checking command to parse $NM output" >&5
1446 if eval "test \"`echo '$''{'ac_cv_sys_global_symbol_pipe'+set}'`\" = set"; then
1447 echo $ac_n "(cached) $ac_c" 1>&6
1448 else
1449 # These are sane defaults that work on at least a few old systems.
1450 # {They come from Ultrix. What could be older than Ultrix?!! ;)}
1452 # Character class describing NM global symbol codes.
1453 ac_symcode='[BCDEGRST]'
1455 # Regexp to match symbols that can be accessed directly from C.
1456 ac_sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
1458 # Transform the above into a raw symbol and a C symbol.
1459 ac_symxfrm='\1 \2\3 \3'
1461 # Transform an extracted symbol line into a proper C declaration
1462 ac_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern char \1;/p'"
1464 # Define system-specific variables.
1465 case "$host_os" in
1466 aix*)
1467 ac_symcode='[BCDT]'
1469 cygwin* | mingw*)
1470 ac_symcode='[ABCDGISTW]'
1472 hpux*)
1473 ac_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern char \1();/p' -e 's/^. .* \(.*\)$/extern char \1;/p'"
1475 irix*)
1476 ac_symcode='[BCDEGRST]'
1478 solaris*)
1479 ac_symcode='[BDT]'
1481 esac
1483 # If we're using GNU nm, then use its standard symbol codes.
1484 if $NM -V 2>&1 | egrep '(GNU|with BFD)' > /dev/null; then
1485 ac_symcode='[ABCDGISTW]'
1488 # Try without a prefix undercore, then with it.
1489 for ac_symprfx in "" "_"; do
1491 ac_cv_sys_global_symbol_pipe="sed -n -e 's/^.* \($ac_symcode\) *\($ac_symprfx\)$ac_sympat$/$ac_symxfrm/p'"
1493 # Check to see that the pipe works correctly.
1494 ac_pipe_works=no
1495 rm -f conftest.$ac_ext
1496 cat > conftest.$ac_ext <<EOF
1497 #ifdef __cplusplus
1498 extern "C" {
1499 #endif
1500 char nm_test_var;
1501 void nm_test_func(){}
1502 #ifdef __cplusplus
1504 #endif
1505 int main(){nm_test_var='a';nm_test_func;return 0;}
1508 if { (eval echo configure:1509: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1509 # Now try to grab the symbols.
1510 ac_nlist=conftest.nm
1512 if { (eval echo configure:1513: \"$NM conftest.$ac_objext \| $ac_cv_sys_global_symbol_pipe \> $ac_nlist\") 1>&5; (eval $NM conftest.$ac_objext \| $ac_cv_sys_global_symbol_pipe \> $ac_nlist) 2>&5; } && test -s "$ac_nlist"; then
1514 # Try sorting and uniquifying the output.
1515 if sort "$ac_nlist" | uniq > "$ac_nlist"T; then
1516 mv -f "$ac_nlist"T "$ac_nlist"
1517 else
1518 rm -f "$ac_nlist"T
1521 # Make sure that we snagged all the symbols we need.
1522 if egrep ' nm_test_var$' "$ac_nlist" >/dev/null; then
1523 if egrep ' nm_test_func$' "$ac_nlist" >/dev/null; then
1524 cat <<EOF > conftest.c
1525 #ifdef __cplusplus
1526 extern "C" {
1527 #endif
1530 # Now generate the symbol file.
1531 eval "$ac_global_symbol_to_cdecl"' < "$ac_nlist" >> conftest.c'
1533 cat <<EOF >> conftest.c
1534 #if defined (__STDC__) && __STDC__
1535 # define lt_ptr_t void *
1536 #else
1537 # define lt_ptr_t char *
1538 # define const
1539 #endif
1541 /* The mapping between symbol names and symbols. */
1542 const struct {
1543 const char *name;
1544 lt_ptr_t address;
1546 lt_preloaded_symbols[] =
1549 sed 's/^. \(.*\) \(.*\)$/ {"\2", (lt_ptr_t) \&\2},/' < "$ac_nlist" >> conftest.c
1550 cat <<\EOF >> conftest.c
1551 {0, (lt_ptr_t) 0}
1554 #ifdef __cplusplus
1556 #endif
1558 # Now try linking the two files.
1559 mv conftest.$ac_objext conftestm.$ac_objext
1560 ac_save_LIBS="$LIBS"
1561 ac_save_CFLAGS="$CFLAGS"
1562 LIBS="conftestm.$ac_objext"
1563 CFLAGS="$CFLAGS$no_builtin_flag"
1564 if { (eval echo configure:1565: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1565 ac_pipe_works=yes
1566 else
1567 echo "configure: failed program was:" >&5
1568 cat conftest.c >&5
1570 LIBS="$ac_save_LIBS"
1571 CFLAGS="$ac_save_CFLAGS"
1572 else
1573 echo "cannot find nm_test_func in $ac_nlist" >&5
1575 else
1576 echo "cannot find nm_test_var in $ac_nlist" >&5
1578 else
1579 echo "cannot run $ac_cv_sys_global_symbol_pipe" >&5
1581 else
1582 echo "$progname: failed program was:" >&5
1583 cat conftest.c >&5
1585 rm -rf conftest*
1587 # Do not use the global_symbol_pipe unless it works.
1588 if test "$ac_pipe_works" = yes; then
1589 if test x"$ac_symprfx" = x"_"; then
1590 ac_cv_sys_symbol_underscore=yes
1591 else
1592 ac_cv_sys_symbol_underscore=no
1594 break
1595 else
1596 ac_cv_sys_global_symbol_pipe=
1598 done
1603 ac_result=yes
1604 if test -z "$ac_cv_sys_global_symbol_pipe"; then
1605 ac_result=no
1607 echo "$ac_t""$ac_result" 1>&6
1609 echo $ac_n "checking for _ prefix in compiled symbols""... $ac_c" 1>&6
1610 echo "configure:1611: checking for _ prefix in compiled symbols" >&5
1611 if eval "test \"`echo '$''{'ac_cv_sys_symbol_underscore'+set}'`\" = set"; then
1612 echo $ac_n "(cached) $ac_c" 1>&6
1613 else
1614 ac_cv_sys_symbol_underscore=no
1615 cat > conftest.$ac_ext <<EOF
1616 void nm_test_func(){}
1617 int main(){nm_test_func;return 0;}
1619 if { (eval echo configure:1620: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1620 # Now try to grab the symbols.
1621 ac_nlist=conftest.nm
1622 if { (eval echo configure:1623: \"$NM conftest.$ac_objext \| $ac_cv_sys_global_symbol_pipe \> $ac_nlist\") 1>&5; (eval $NM conftest.$ac_objext \| $ac_cv_sys_global_symbol_pipe \> $ac_nlist) 2>&5; } && test -s "$ac_nlist"; then
1623 # See whether the symbols have a leading underscore.
1624 if egrep '^. _nm_test_func' "$ac_nlist" >/dev/null; then
1625 ac_cv_sys_symbol_underscore=yes
1626 else
1627 if egrep '^. nm_test_func ' "$ac_nlist" >/dev/null; then
1629 else
1630 echo "configure: cannot find nm_test_func in $ac_nlist" >&5
1633 else
1634 echo "configure: cannot run $ac_cv_sys_global_symbol_pipe" >&5
1636 else
1637 echo "configure: failed program was:" >&5
1638 cat conftest.c >&5
1640 rm -rf conftest*
1644 echo "$ac_t""$ac_cv_sys_symbol_underscore" 1>&6
1645 USE_SYMBOL_UNDERSCORE=${ac_cv_sys_symbol_underscore=no}
1647 echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
1648 echo "configure:1649: checking whether ln -s works" >&5
1649 if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
1650 echo $ac_n "(cached) $ac_c" 1>&6
1651 else
1652 rm -f conftestdata
1653 if ln -s X conftestdata 2>/dev/null
1654 then
1655 rm -f conftestdata
1656 ac_cv_prog_LN_S="ln -s"
1657 else
1658 ac_cv_prog_LN_S=ln
1661 LN_S="$ac_cv_prog_LN_S"
1662 if test "$ac_cv_prog_LN_S" = "ln -s"; then
1663 echo "$ac_t""yes" 1>&6
1664 else
1665 echo "$ac_t""no" 1>&6
1668 if test $host != $build; then
1669 ac_tool_prefix=${host_alias}-
1670 else
1671 ac_tool_prefix=
1675 # Check for any special flags to pass to ltconfig.
1676 libtool_flags="--cache-file=$cache_file"
1677 test "$enable_shared" = no && libtool_flags="$libtool_flags --disable-shared"
1678 test "$enable_static" = no && libtool_flags="$libtool_flags --disable-static"
1679 test "$enable_fast_install" = no && libtool_flags="$libtool_flags --disable-fast-install"
1680 test "$lt_dlopen" = yes && libtool_flags="$libtool_flags --enable-dlopen"
1681 test "$silent" = yes && libtool_flags="$libtool_flags --silent"
1682 test "$ac_cv_prog_gcc" = yes && libtool_flags="$libtool_flags --with-gcc"
1683 test "$ac_cv_prog_gnu_ld" = yes && libtool_flags="$libtool_flags --with-gnu-ld"
1685 # Some flags need to be propagated to the compiler or linker for good
1686 # libtool support.
1687 case "$host" in
1688 *-*-irix6*)
1689 # Find out which ABI we are using.
1690 echo '#line 1691 "configure"' > conftest.$ac_ext
1691 if { (eval echo configure:1692: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1692 case "`/usr/bin/file conftest.o`" in
1693 *32-bit*)
1694 LD="${LD-ld} -32"
1696 *N32*)
1697 LD="${LD-ld} -n32"
1699 *64-bit*)
1700 LD="${LD-ld} -64"
1702 esac
1704 rm -rf conftest*
1707 *-*-sco3.2v5*)
1708 # On SCO OpenServer 5, we need -belf to get full-featured binaries.
1709 SAVE_CFLAGS="$CFLAGS"
1710 CFLAGS="$CFLAGS -belf"
1711 echo $ac_n "checking whether the C compiler needs -belf""... $ac_c" 1>&6
1712 echo "configure:1713: checking whether the C compiler needs -belf" >&5
1713 if eval "test \"`echo '$''{'lt_cv_cc_needs_belf'+set}'`\" = set"; then
1714 echo $ac_n "(cached) $ac_c" 1>&6
1715 else
1716 cat > conftest.$ac_ext <<EOF
1717 #line 1718 "configure"
1718 #include "confdefs.h"
1720 int main() {
1722 ; return 0; }
1724 if { (eval echo configure:1725: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1725 rm -rf conftest*
1726 lt_cv_cc_needs_belf=yes
1727 else
1728 echo "configure: failed program was:" >&5
1729 cat conftest.$ac_ext >&5
1730 rm -rf conftest*
1731 lt_cv_cc_needs_belf=no
1733 rm -f conftest*
1736 echo "$ac_t""$lt_cv_cc_needs_belf" 1>&6
1737 if test x"$lt_cv_cc_needs_belf" != x"yes"; then
1738 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
1739 CFLAGS="$SAVE_CFLAGS"
1743 *-*-cygwin*)
1744 # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
1745 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
1746 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1747 echo "configure:1748: checking for $ac_word" >&5
1748 if eval "test \"`echo '$''{'ac_cv_prog_DLLTOOL'+set}'`\" = set"; then
1749 echo $ac_n "(cached) $ac_c" 1>&6
1750 else
1751 if test -n "$DLLTOOL"; then
1752 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
1753 else
1754 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1755 ac_dummy="$PATH"
1756 for ac_dir in $ac_dummy; do
1757 test -z "$ac_dir" && ac_dir=.
1758 if test -f $ac_dir/$ac_word; then
1759 ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
1760 break
1762 done
1763 IFS="$ac_save_ifs"
1766 DLLTOOL="$ac_cv_prog_DLLTOOL"
1767 if test -n "$DLLTOOL"; then
1768 echo "$ac_t""$DLLTOOL" 1>&6
1769 else
1770 echo "$ac_t""no" 1>&6
1774 if test -z "$ac_cv_prog_DLLTOOL"; then
1775 if test -n "$ac_tool_prefix"; then
1776 # Extract the first word of "dlltool", so it can be a program name with args.
1777 set dummy dlltool; ac_word=$2
1778 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1779 echo "configure:1780: checking for $ac_word" >&5
1780 if eval "test \"`echo '$''{'ac_cv_prog_DLLTOOL'+set}'`\" = set"; then
1781 echo $ac_n "(cached) $ac_c" 1>&6
1782 else
1783 if test -n "$DLLTOOL"; then
1784 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
1785 else
1786 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1787 ac_dummy="$PATH"
1788 for ac_dir in $ac_dummy; do
1789 test -z "$ac_dir" && ac_dir=.
1790 if test -f $ac_dir/$ac_word; then
1791 ac_cv_prog_DLLTOOL="dlltool"
1792 break
1794 done
1795 IFS="$ac_save_ifs"
1796 test -z "$ac_cv_prog_DLLTOOL" && ac_cv_prog_DLLTOOL="false"
1799 DLLTOOL="$ac_cv_prog_DLLTOOL"
1800 if test -n "$DLLTOOL"; then
1801 echo "$ac_t""$DLLTOOL" 1>&6
1802 else
1803 echo "$ac_t""no" 1>&6
1806 else
1807 DLLTOOL="false"
1811 # Extract the first word of "${ac_tool_prefix}as", so it can be a program name with args.
1812 set dummy ${ac_tool_prefix}as; ac_word=$2
1813 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1814 echo "configure:1815: checking for $ac_word" >&5
1815 if eval "test \"`echo '$''{'ac_cv_prog_AS'+set}'`\" = set"; then
1816 echo $ac_n "(cached) $ac_c" 1>&6
1817 else
1818 if test -n "$AS"; then
1819 ac_cv_prog_AS="$AS" # Let the user override the test.
1820 else
1821 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1822 ac_dummy="$PATH"
1823 for ac_dir in $ac_dummy; do
1824 test -z "$ac_dir" && ac_dir=.
1825 if test -f $ac_dir/$ac_word; then
1826 ac_cv_prog_AS="${ac_tool_prefix}as"
1827 break
1829 done
1830 IFS="$ac_save_ifs"
1833 AS="$ac_cv_prog_AS"
1834 if test -n "$AS"; then
1835 echo "$ac_t""$AS" 1>&6
1836 else
1837 echo "$ac_t""no" 1>&6
1841 if test -z "$ac_cv_prog_AS"; then
1842 if test -n "$ac_tool_prefix"; then
1843 # Extract the first word of "as", so it can be a program name with args.
1844 set dummy as; ac_word=$2
1845 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1846 echo "configure:1847: checking for $ac_word" >&5
1847 if eval "test \"`echo '$''{'ac_cv_prog_AS'+set}'`\" = set"; then
1848 echo $ac_n "(cached) $ac_c" 1>&6
1849 else
1850 if test -n "$AS"; then
1851 ac_cv_prog_AS="$AS" # Let the user override the test.
1852 else
1853 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1854 ac_dummy="$PATH"
1855 for ac_dir in $ac_dummy; do
1856 test -z "$ac_dir" && ac_dir=.
1857 if test -f $ac_dir/$ac_word; then
1858 ac_cv_prog_AS="as"
1859 break
1861 done
1862 IFS="$ac_save_ifs"
1863 test -z "$ac_cv_prog_AS" && ac_cv_prog_AS="false"
1866 AS="$ac_cv_prog_AS"
1867 if test -n "$AS"; then
1868 echo "$ac_t""$AS" 1>&6
1869 else
1870 echo "$ac_t""no" 1>&6
1873 else
1874 AS="false"
1881 esac
1883 # enable the --disable-libtool-lock switch
1885 # Check whether --enable-libtool-lock or --disable-libtool-lock was given.
1886 if test "${enable_libtool_lock+set}" = set; then
1887 enableval="$enable_libtool_lock"
1888 need_locks=$enableval
1889 else
1890 need_locks=yes
1894 if test x"$need_locks" = xno; then
1895 libtool_flags="$libtool_flags --disable-lock"
1899 # Save cache, so that ltconfig can load it
1900 cat > confcache <<\EOF
1901 # This file is a shell script that caches the results of configure
1902 # tests run on this system so they can be shared between configure
1903 # scripts and configure runs. It is not useful on other systems.
1904 # If it contains results you don't want to keep, you may remove or edit it.
1906 # By default, configure uses ./config.cache as the cache file,
1907 # creating it if it does not exist already. You can give configure
1908 # the --cache-file=FILE option to use a different cache file; that is
1909 # what configure does when it calls configure scripts in
1910 # subdirectories, so they share the cache.
1911 # Giving --cache-file=/dev/null disables caching, for debugging configure.
1912 # config.status only pays attention to the cache file if you give it the
1913 # --recheck option to rerun configure.
1916 # The following way of writing the cache mishandles newlines in values,
1917 # but we know of no workaround that is simple, portable, and efficient.
1918 # So, don't put newlines in cache variables' values.
1919 # Ultrix sh set writes to stderr and can't be redirected directly,
1920 # and sets the high bit in the cache file unless we assign to the vars.
1921 (set) 2>&1 |
1922 case `(ac_space=' '; set | grep ac_space) 2>&1` in
1923 *ac_space=\ *)
1924 # `set' does not quote correctly, so add quotes (double-quote substitution
1925 # turns \\\\ into \\, and sed turns \\ into \).
1926 sed -n \
1927 -e "s/'/'\\\\''/g" \
1928 -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
1931 # `set' quotes correctly as required by POSIX, so do not add quotes.
1932 sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
1934 esac >> confcache
1935 if cmp -s $cache_file confcache; then
1937 else
1938 if test -w $cache_file; then
1939 echo "updating cache $cache_file"
1940 cat confcache > $cache_file
1941 else
1942 echo "not updating unwritable cache $cache_file"
1945 rm -f confcache
1948 # Actually configure libtool. ac_aux_dir is where install-sh is found.
1949 CC="$CC" CFLAGS="$CFLAGS" CPPFLAGS="$CPPFLAGS" \
1950 LD="$LD" NM="$NM" RANLIB="$RANLIB" LN_S="$LN_S" \
1951 DLLTOOL="$DLLTOOL" AS="$AS" \
1952 ${CONFIG_SHELL-/bin/sh} $ac_aux_dir/ltconfig --no-reexec \
1953 $libtool_flags --no-verify $ac_aux_dir/ltmain.sh $host \
1954 || { echo "configure: error: libtool configure failed" 1>&2; exit 1; }
1956 # Reload cache, that may have been modified by ltconfig
1957 if test -r "$cache_file"; then
1958 echo "loading cache $cache_file"
1959 . $cache_file
1960 else
1961 echo "creating cache $cache_file"
1962 > $cache_file
1966 # This can be used to rebuild libtool when needed
1967 LIBTOOL_DEPS="$ac_aux_dir/ltconfig $ac_aux_dir/ltmain.sh"
1969 # Always use our own libtool.
1970 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
1972 # Redirect the config.log output again, so that the ltconfig log is not
1973 # clobbered by the next message.
1974 exec 5>>./config.log
1977 if test -z "$with_target_subdir" || test "$with_target_subdir" = "."; then
1978 COMPPATH=.
1979 else
1980 COMPPATH=..
1985 if test -n "$with_cross_host"; then
1986 # We are being configured with a cross compiler. AC_REPLACE_FUNCS
1987 # may not work correctly, because the compiler may not be able to
1988 # link executables.
1990 # We assume newlib. This lets us hard-code the functions we know
1991 # we'll have.
1992 cat >> confdefs.h <<\EOF
1993 #define HAVE_MEMCPY 1
1996 cat >> confdefs.h <<\EOF
1997 #define HAVE_STRERROR 1
2001 # We ignore --with-system-zlib in this case.
2002 target_all=libzgcj.la
2003 else
2004 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
2005 echo "configure:2006: checking how to run the C preprocessor" >&5
2006 # On Suns, sometimes $CPP names a directory.
2007 if test -n "$CPP" && test -d "$CPP"; then
2008 CPP=
2010 if test -z "$CPP"; then
2011 if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
2012 echo $ac_n "(cached) $ac_c" 1>&6
2013 else
2014 # This must be in double quotes, not single quotes, because CPP may get
2015 # substituted into the Makefile and "${CC-cc}" will confuse make.
2016 CPP="${CC-cc} -E"
2017 # On the NeXT, cc -E runs the code through the compiler's parser,
2018 # not just through cpp.
2019 cat > conftest.$ac_ext <<EOF
2020 #line 2021 "configure"
2021 #include "confdefs.h"
2022 #include <assert.h>
2023 Syntax Error
2025 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2026 { (eval echo configure:2027: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2027 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2028 if test -z "$ac_err"; then
2030 else
2031 echo "$ac_err" >&5
2032 echo "configure: failed program was:" >&5
2033 cat conftest.$ac_ext >&5
2034 rm -rf conftest*
2035 CPP="${CC-cc} -E -traditional-cpp"
2036 cat > conftest.$ac_ext <<EOF
2037 #line 2038 "configure"
2038 #include "confdefs.h"
2039 #include <assert.h>
2040 Syntax Error
2042 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2043 { (eval echo configure:2044: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2044 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2045 if test -z "$ac_err"; then
2047 else
2048 echo "$ac_err" >&5
2049 echo "configure: failed program was:" >&5
2050 cat conftest.$ac_ext >&5
2051 rm -rf conftest*
2052 CPP="${CC-cc} -nologo -E"
2053 cat > conftest.$ac_ext <<EOF
2054 #line 2055 "configure"
2055 #include "confdefs.h"
2056 #include <assert.h>
2057 Syntax Error
2059 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2060 { (eval echo configure:2061: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2061 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2062 if test -z "$ac_err"; then
2064 else
2065 echo "$ac_err" >&5
2066 echo "configure: failed program was:" >&5
2067 cat conftest.$ac_ext >&5
2068 rm -rf conftest*
2069 CPP=/lib/cpp
2071 rm -f conftest*
2073 rm -f conftest*
2075 rm -f conftest*
2076 ac_cv_prog_CPP="$CPP"
2078 CPP="$ac_cv_prog_CPP"
2079 else
2080 ac_cv_prog_CPP="$CPP"
2082 echo "$ac_t""$CPP" 1>&6
2084 for ac_hdr in unistd.h
2086 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2087 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2088 echo "configure:2089: checking for $ac_hdr" >&5
2089 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2090 echo $ac_n "(cached) $ac_c" 1>&6
2091 else
2092 cat > conftest.$ac_ext <<EOF
2093 #line 2094 "configure"
2094 #include "confdefs.h"
2095 #include <$ac_hdr>
2097 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2098 { (eval echo configure:2099: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2099 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2100 if test -z "$ac_err"; then
2101 rm -rf conftest*
2102 eval "ac_cv_header_$ac_safe=yes"
2103 else
2104 echo "$ac_err" >&5
2105 echo "configure: failed program was:" >&5
2106 cat conftest.$ac_ext >&5
2107 rm -rf conftest*
2108 eval "ac_cv_header_$ac_safe=no"
2110 rm -f conftest*
2112 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2113 echo "$ac_t""yes" 1>&6
2114 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2115 cat >> confdefs.h <<EOF
2116 #define $ac_tr_hdr 1
2119 else
2120 echo "$ac_t""no" 1>&6
2122 done
2124 for ac_func in getpagesize
2126 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2127 echo "configure:2128: checking for $ac_func" >&5
2128 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2129 echo $ac_n "(cached) $ac_c" 1>&6
2130 else
2131 cat > conftest.$ac_ext <<EOF
2132 #line 2133 "configure"
2133 #include "confdefs.h"
2134 /* System header to define __stub macros and hopefully few prototypes,
2135 which can conflict with char $ac_func(); below. */
2136 #include <assert.h>
2137 /* Override any gcc2 internal prototype to avoid an error. */
2138 /* We use char because int might match the return type of a gcc2
2139 builtin and then its argument prototype would still apply. */
2140 char $ac_func();
2142 int main() {
2144 /* The GNU C library defines this for functions which it implements
2145 to always fail with ENOSYS. Some functions are actually named
2146 something starting with __ and the normal name is an alias. */
2147 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2148 choke me
2149 #else
2150 $ac_func();
2151 #endif
2153 ; return 0; }
2155 if { (eval echo configure:2156: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2156 rm -rf conftest*
2157 eval "ac_cv_func_$ac_func=yes"
2158 else
2159 echo "configure: failed program was:" >&5
2160 cat conftest.$ac_ext >&5
2161 rm -rf conftest*
2162 eval "ac_cv_func_$ac_func=no"
2164 rm -f conftest*
2167 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2168 echo "$ac_t""yes" 1>&6
2169 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2170 cat >> confdefs.h <<EOF
2171 #define $ac_tr_func 1
2174 else
2175 echo "$ac_t""no" 1>&6
2177 done
2179 echo $ac_n "checking for working mmap""... $ac_c" 1>&6
2180 echo "configure:2181: checking for working mmap" >&5
2181 if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
2182 echo $ac_n "(cached) $ac_c" 1>&6
2183 else
2184 if test "$cross_compiling" = yes; then
2185 ac_cv_func_mmap_fixed_mapped=no
2186 else
2187 cat > conftest.$ac_ext <<EOF
2188 #line 2189 "configure"
2189 #include "confdefs.h"
2191 /* Thanks to Mike Haertel and Jim Avera for this test.
2192 Here is a matrix of mmap possibilities:
2193 mmap private not fixed
2194 mmap private fixed at somewhere currently unmapped
2195 mmap private fixed at somewhere already mapped
2196 mmap shared not fixed
2197 mmap shared fixed at somewhere currently unmapped
2198 mmap shared fixed at somewhere already mapped
2199 For private mappings, we should verify that changes cannot be read()
2200 back from the file, nor mmap's back from the file at a different
2201 address. (There have been systems where private was not correctly
2202 implemented like the infamous i386 svr4.0, and systems where the
2203 VM page cache was not coherent with the filesystem buffer cache
2204 like early versions of FreeBSD and possibly contemporary NetBSD.)
2205 For shared mappings, we should conversely verify that changes get
2206 propogated back to all the places they're supposed to be.
2208 Grep wants private fixed already mapped.
2209 The main things grep needs to know about mmap are:
2210 * does it exist and is it safe to write into the mmap'd area
2211 * how to use it (BSD variants) */
2212 #include <sys/types.h>
2213 #include <fcntl.h>
2214 #include <sys/mman.h>
2216 /* This mess was copied from the GNU getpagesize.h. */
2217 #ifndef HAVE_GETPAGESIZE
2218 # ifdef HAVE_UNISTD_H
2219 # include <unistd.h>
2220 # endif
2222 /* Assume that all systems that can run configure have sys/param.h. */
2223 # ifndef HAVE_SYS_PARAM_H
2224 # define HAVE_SYS_PARAM_H 1
2225 # endif
2227 # ifdef _SC_PAGESIZE
2228 # define getpagesize() sysconf(_SC_PAGESIZE)
2229 # else /* no _SC_PAGESIZE */
2230 # ifdef HAVE_SYS_PARAM_H
2231 # include <sys/param.h>
2232 # ifdef EXEC_PAGESIZE
2233 # define getpagesize() EXEC_PAGESIZE
2234 # else /* no EXEC_PAGESIZE */
2235 # ifdef NBPG
2236 # define getpagesize() NBPG * CLSIZE
2237 # ifndef CLSIZE
2238 # define CLSIZE 1
2239 # endif /* no CLSIZE */
2240 # else /* no NBPG */
2241 # ifdef NBPC
2242 # define getpagesize() NBPC
2243 # else /* no NBPC */
2244 # ifdef PAGESIZE
2245 # define getpagesize() PAGESIZE
2246 # endif /* PAGESIZE */
2247 # endif /* no NBPC */
2248 # endif /* no NBPG */
2249 # endif /* no EXEC_PAGESIZE */
2250 # else /* no HAVE_SYS_PARAM_H */
2251 # define getpagesize() 8192 /* punt totally */
2252 # endif /* no HAVE_SYS_PARAM_H */
2253 # endif /* no _SC_PAGESIZE */
2255 #endif /* no HAVE_GETPAGESIZE */
2257 #ifdef __cplusplus
2258 extern "C" { void *malloc(unsigned); }
2259 #else
2260 char *malloc();
2261 #endif
2264 main()
2266 char *data, *data2, *data3;
2267 int i, pagesize;
2268 int fd;
2270 pagesize = getpagesize();
2273 * First, make a file with some known garbage in it.
2275 data = malloc(pagesize);
2276 if (!data)
2277 exit(1);
2278 for (i = 0; i < pagesize; ++i)
2279 *(data + i) = rand();
2280 umask(0);
2281 fd = creat("conftestmmap", 0600);
2282 if (fd < 0)
2283 exit(1);
2284 if (write(fd, data, pagesize) != pagesize)
2285 exit(1);
2286 close(fd);
2289 * Next, try to mmap the file at a fixed address which
2290 * already has something else allocated at it. If we can,
2291 * also make sure that we see the same garbage.
2293 fd = open("conftestmmap", O_RDWR);
2294 if (fd < 0)
2295 exit(1);
2296 data2 = malloc(2 * pagesize);
2297 if (!data2)
2298 exit(1);
2299 data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1);
2300 if (data2 != mmap(data2, pagesize, PROT_READ | PROT_WRITE,
2301 MAP_PRIVATE | MAP_FIXED, fd, 0L))
2302 exit(1);
2303 for (i = 0; i < pagesize; ++i)
2304 if (*(data + i) != *(data2 + i))
2305 exit(1);
2308 * Finally, make sure that changes to the mapped area
2309 * do not percolate back to the file as seen by read().
2310 * (This is a bug on some variants of i386 svr4.0.)
2312 for (i = 0; i < pagesize; ++i)
2313 *(data2 + i) = *(data2 + i) + 1;
2314 data3 = malloc(pagesize);
2315 if (!data3)
2316 exit(1);
2317 if (read(fd, data3, pagesize) != pagesize)
2318 exit(1);
2319 for (i = 0; i < pagesize; ++i)
2320 if (*(data + i) != *(data3 + i))
2321 exit(1);
2322 close(fd);
2323 unlink("conftestmmap");
2324 exit(0);
2328 if { (eval echo configure:2329: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2329 then
2330 ac_cv_func_mmap_fixed_mapped=yes
2331 else
2332 echo "configure: failed program was:" >&5
2333 cat conftest.$ac_ext >&5
2334 rm -fr conftest*
2335 ac_cv_func_mmap_fixed_mapped=no
2337 rm -fr conftest*
2342 echo "$ac_t""$ac_cv_func_mmap_fixed_mapped" 1>&6
2343 if test $ac_cv_func_mmap_fixed_mapped = yes; then
2344 cat >> confdefs.h <<\EOF
2345 #define HAVE_MMAP 1
2350 for ac_func in memcpy strerror
2352 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2353 echo "configure:2354: checking for $ac_func" >&5
2354 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2355 echo $ac_n "(cached) $ac_c" 1>&6
2356 else
2357 cat > conftest.$ac_ext <<EOF
2358 #line 2359 "configure"
2359 #include "confdefs.h"
2360 /* System header to define __stub macros and hopefully few prototypes,
2361 which can conflict with char $ac_func(); below. */
2362 #include <assert.h>
2363 /* Override any gcc2 internal prototype to avoid an error. */
2364 /* We use char because int might match the return type of a gcc2
2365 builtin and then its argument prototype would still apply. */
2366 char $ac_func();
2368 int main() {
2370 /* The GNU C library defines this for functions which it implements
2371 to always fail with ENOSYS. Some functions are actually named
2372 something starting with __ and the normal name is an alias. */
2373 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2374 choke me
2375 #else
2376 $ac_func();
2377 #endif
2379 ; return 0; }
2381 if { (eval echo configure:2382: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2382 rm -rf conftest*
2383 eval "ac_cv_func_$ac_func=yes"
2384 else
2385 echo "configure: failed program was:" >&5
2386 cat conftest.$ac_ext >&5
2387 rm -rf conftest*
2388 eval "ac_cv_func_$ac_func=no"
2390 rm -f conftest*
2393 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2394 echo "$ac_t""yes" 1>&6
2395 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2396 cat >> confdefs.h <<EOF
2397 #define $ac_tr_func 1
2400 else
2401 echo "$ac_t""no" 1>&6
2403 done
2406 if test "$with_system_zlib" = yes; then
2407 echo $ac_n "checking for deflate in -lz""... $ac_c" 1>&6
2408 echo "configure:2409: checking for deflate in -lz" >&5
2409 ac_lib_var=`echo z'_'deflate | sed 'y%./+-%__p_%'`
2410 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2411 echo $ac_n "(cached) $ac_c" 1>&6
2412 else
2413 ac_save_LIBS="$LIBS"
2414 LIBS="-lz $LIBS"
2415 cat > conftest.$ac_ext <<EOF
2416 #line 2417 "configure"
2417 #include "confdefs.h"
2418 /* Override any gcc2 internal prototype to avoid an error. */
2419 /* We use char because int might match the return type of a gcc2
2420 builtin and then its argument prototype would still apply. */
2421 char deflate();
2423 int main() {
2424 deflate()
2425 ; return 0; }
2427 if { (eval echo configure:2428: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2428 rm -rf conftest*
2429 eval "ac_cv_lib_$ac_lib_var=yes"
2430 else
2431 echo "configure: failed program was:" >&5
2432 cat conftest.$ac_ext >&5
2433 rm -rf conftest*
2434 eval "ac_cv_lib_$ac_lib_var=no"
2436 rm -f conftest*
2437 LIBS="$ac_save_LIBS"
2440 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2441 echo "$ac_t""yes" 1>&6
2442 target_all=
2443 else
2444 echo "$ac_t""no" 1>&6
2445 target_all=libzgcj.la
2448 else
2449 target_all=libzgcj.la
2455 for ac_hdr in unistd.h
2457 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2458 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2459 echo "configure:2460: checking for $ac_hdr" >&5
2460 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2461 echo $ac_n "(cached) $ac_c" 1>&6
2462 else
2463 cat > conftest.$ac_ext <<EOF
2464 #line 2465 "configure"
2465 #include "confdefs.h"
2466 #include <$ac_hdr>
2468 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2469 { (eval echo configure:2470: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2470 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2471 if test -z "$ac_err"; then
2472 rm -rf conftest*
2473 eval "ac_cv_header_$ac_safe=yes"
2474 else
2475 echo "$ac_err" >&5
2476 echo "configure: failed program was:" >&5
2477 cat conftest.$ac_ext >&5
2478 rm -rf conftest*
2479 eval "ac_cv_header_$ac_safe=no"
2481 rm -f conftest*
2483 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2484 echo "$ac_t""yes" 1>&6
2485 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2486 cat >> confdefs.h <<EOF
2487 #define $ac_tr_hdr 1
2490 else
2491 echo "$ac_t""no" 1>&6
2493 done
2498 if test -z "$with_cross_host"; then
2499 USE_LIBDIR_TRUE=
2500 USE_LIBDIR_FALSE='#'
2501 else
2502 USE_LIBDIR_TRUE='#'
2503 USE_LIBDIR_FALSE=
2506 if test "${multilib}" = "yes"; then
2507 multilib_arg="--enable-multilib"
2508 else
2509 multilib_arg=
2512 trap '' 1 2 15
2513 cat > confcache <<\EOF
2514 # This file is a shell script that caches the results of configure
2515 # tests run on this system so they can be shared between configure
2516 # scripts and configure runs. It is not useful on other systems.
2517 # If it contains results you don't want to keep, you may remove or edit it.
2519 # By default, configure uses ./config.cache as the cache file,
2520 # creating it if it does not exist already. You can give configure
2521 # the --cache-file=FILE option to use a different cache file; that is
2522 # what configure does when it calls configure scripts in
2523 # subdirectories, so they share the cache.
2524 # Giving --cache-file=/dev/null disables caching, for debugging configure.
2525 # config.status only pays attention to the cache file if you give it the
2526 # --recheck option to rerun configure.
2529 # The following way of writing the cache mishandles newlines in values,
2530 # but we know of no workaround that is simple, portable, and efficient.
2531 # So, don't put newlines in cache variables' values.
2532 # Ultrix sh set writes to stderr and can't be redirected directly,
2533 # and sets the high bit in the cache file unless we assign to the vars.
2534 (set) 2>&1 |
2535 case `(ac_space=' '; set | grep ac_space) 2>&1` in
2536 *ac_space=\ *)
2537 # `set' does not quote correctly, so add quotes (double-quote substitution
2538 # turns \\\\ into \\, and sed turns \\ into \).
2539 sed -n \
2540 -e "s/'/'\\\\''/g" \
2541 -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
2544 # `set' quotes correctly as required by POSIX, so do not add quotes.
2545 sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
2547 esac >> confcache
2548 if cmp -s $cache_file confcache; then
2550 else
2551 if test -w $cache_file; then
2552 echo "updating cache $cache_file"
2553 cat confcache > $cache_file
2554 else
2555 echo "not updating unwritable cache $cache_file"
2558 rm -f confcache
2560 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
2562 test "x$prefix" = xNONE && prefix=$ac_default_prefix
2563 # Let make expand exec_prefix.
2564 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
2566 # Any assignment to VPATH causes Sun make to only execute
2567 # the first set of double-colon rules, so remove it if not needed.
2568 # If there is a colon in the path, we need to keep it.
2569 if test "x$srcdir" = x.; then
2570 ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
2573 trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
2575 # Transform confdefs.h into DEFS.
2576 # Protect against shell expansion while executing Makefile rules.
2577 # Protect against Makefile macro expansion.
2578 cat > conftest.defs <<\EOF
2579 s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%-D\1=\2%g
2580 s%[ `~#$^&*(){}\\|;'"<>?]%\\&%g
2581 s%\[%\\&%g
2582 s%\]%\\&%g
2583 s%\$%$$%g
2585 DEFS=`sed -f conftest.defs confdefs.h | tr '\012' ' '`
2586 rm -f conftest.defs
2589 # Without the "./", some shells look in PATH for config.status.
2590 : ${CONFIG_STATUS=./config.status}
2592 echo creating $CONFIG_STATUS
2593 rm -f $CONFIG_STATUS
2594 cat > $CONFIG_STATUS <<EOF
2595 #! /bin/sh
2596 # Generated automatically by configure.
2597 # Run this file to recreate the current configuration.
2598 # This directory was configured as follows,
2599 # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
2601 # $0 $ac_configure_args
2603 # Compiler output produced by configure, useful for debugging
2604 # configure, is in ./config.log if it exists.
2606 ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
2607 for ac_option
2609 case "\$ac_option" in
2610 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
2611 echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
2612 exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
2613 -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
2614 echo "$CONFIG_STATUS generated by autoconf version 2.13"
2615 exit 0 ;;
2616 -help | --help | --hel | --he | --h)
2617 echo "\$ac_cs_usage"; exit 0 ;;
2618 *) echo "\$ac_cs_usage"; exit 1 ;;
2619 esac
2620 done
2622 ac_given_srcdir=$srcdir
2623 ac_given_INSTALL="$INSTALL"
2625 trap 'rm -fr `echo "Makefile" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
2627 cat >> $CONFIG_STATUS <<EOF
2629 # Protect against being on the right side of a sed subst in config.status.
2630 sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
2631 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
2632 $ac_vpsub
2633 $extrasub
2634 s%@SHELL@%$SHELL%g
2635 s%@CFLAGS@%$CFLAGS%g
2636 s%@CPPFLAGS@%$CPPFLAGS%g
2637 s%@CXXFLAGS@%$CXXFLAGS%g
2638 s%@FFLAGS@%$FFLAGS%g
2639 s%@DEFS@%$DEFS%g
2640 s%@LDFLAGS@%$LDFLAGS%g
2641 s%@LIBS@%$LIBS%g
2642 s%@exec_prefix@%$exec_prefix%g
2643 s%@prefix@%$prefix%g
2644 s%@program_transform_name@%$program_transform_name%g
2645 s%@bindir@%$bindir%g
2646 s%@sbindir@%$sbindir%g
2647 s%@libexecdir@%$libexecdir%g
2648 s%@datadir@%$datadir%g
2649 s%@sysconfdir@%$sysconfdir%g
2650 s%@sharedstatedir@%$sharedstatedir%g
2651 s%@localstatedir@%$localstatedir%g
2652 s%@libdir@%$libdir%g
2653 s%@includedir@%$includedir%g
2654 s%@oldincludedir@%$oldincludedir%g
2655 s%@infodir@%$infodir%g
2656 s%@mandir@%$mandir%g
2657 s%@host@%$host%g
2658 s%@host_alias@%$host_alias%g
2659 s%@host_cpu@%$host_cpu%g
2660 s%@host_vendor@%$host_vendor%g
2661 s%@host_os@%$host_os%g
2662 s%@target@%$target%g
2663 s%@target_alias@%$target_alias%g
2664 s%@target_cpu@%$target_cpu%g
2665 s%@target_vendor@%$target_vendor%g
2666 s%@target_os@%$target_os%g
2667 s%@build@%$build%g
2668 s%@build_alias@%$build_alias%g
2669 s%@build_cpu@%$build_cpu%g
2670 s%@build_vendor@%$build_vendor%g
2671 s%@build_os@%$build_os%g
2672 s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
2673 s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
2674 s%@INSTALL_DATA@%$INSTALL_DATA%g
2675 s%@PACKAGE@%$PACKAGE%g
2676 s%@VERSION@%$VERSION%g
2677 s%@ACLOCAL@%$ACLOCAL%g
2678 s%@AUTOCONF@%$AUTOCONF%g
2679 s%@AUTOMAKE@%$AUTOMAKE%g
2680 s%@AUTOHEADER@%$AUTOHEADER%g
2681 s%@MAKEINFO@%$MAKEINFO%g
2682 s%@SET_MAKE@%$SET_MAKE%g
2683 s%@zlib_basedir@%$zlib_basedir%g
2684 s%@CC@%$CC%g
2685 s%@MAINTAINER_MODE_TRUE@%$MAINTAINER_MODE_TRUE%g
2686 s%@MAINTAINER_MODE_FALSE@%$MAINTAINER_MODE_FALSE%g
2687 s%@MAINT@%$MAINT%g
2688 s%@EXEEXT@%$EXEEXT%g
2689 s%@RANLIB@%$RANLIB%g
2690 s%@LD@%$LD%g
2691 s%@NM@%$NM%g
2692 s%@USE_SYMBOL_UNDERSCORE@%$USE_SYMBOL_UNDERSCORE%g
2693 s%@LN_S@%$LN_S%g
2694 s%@DLLTOOL@%$DLLTOOL%g
2695 s%@AS@%$AS%g
2696 s%@LIBTOOL@%$LIBTOOL%g
2697 s%@COMPPATH@%$COMPPATH%g
2698 s%@CPP@%$CPP%g
2699 s%@target_all@%$target_all%g
2700 s%@USE_LIBDIR_TRUE@%$USE_LIBDIR_TRUE%g
2701 s%@USE_LIBDIR_FALSE@%$USE_LIBDIR_FALSE%g
2703 CEOF
2706 cat >> $CONFIG_STATUS <<\EOF
2708 # Split the substitutions into bite-sized pieces for seds with
2709 # small command number limits, like on Digital OSF/1 and HP-UX.
2710 ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
2711 ac_file=1 # Number of current file.
2712 ac_beg=1 # First line for current file.
2713 ac_end=$ac_max_sed_cmds # Line after last line for current file.
2714 ac_more_lines=:
2715 ac_sed_cmds=""
2716 while $ac_more_lines; do
2717 if test $ac_beg -gt 1; then
2718 sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
2719 else
2720 sed "${ac_end}q" conftest.subs > conftest.s$ac_file
2722 if test ! -s conftest.s$ac_file; then
2723 ac_more_lines=false
2724 rm -f conftest.s$ac_file
2725 else
2726 if test -z "$ac_sed_cmds"; then
2727 ac_sed_cmds="sed -f conftest.s$ac_file"
2728 else
2729 ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
2731 ac_file=`expr $ac_file + 1`
2732 ac_beg=$ac_end
2733 ac_end=`expr $ac_end + $ac_max_sed_cmds`
2735 done
2736 if test -z "$ac_sed_cmds"; then
2737 ac_sed_cmds=cat
2741 cat >> $CONFIG_STATUS <<EOF
2743 CONFIG_FILES=\${CONFIG_FILES-"Makefile"}
2745 cat >> $CONFIG_STATUS <<\EOF
2746 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
2747 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
2748 case "$ac_file" in
2749 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
2750 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
2751 *) ac_file_in="${ac_file}.in" ;;
2752 esac
2754 # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
2756 # Remove last slash and all that follows it. Not all systems have dirname.
2757 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
2758 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
2759 # The file is in a subdirectory.
2760 test ! -d "$ac_dir" && mkdir "$ac_dir"
2761 ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
2762 # A "../" for each directory in $ac_dir_suffix.
2763 ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
2764 else
2765 ac_dir_suffix= ac_dots=
2768 case "$ac_given_srcdir" in
2769 .) srcdir=.
2770 if test -z "$ac_dots"; then top_srcdir=.
2771 else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
2772 /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
2773 *) # Relative path.
2774 srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
2775 top_srcdir="$ac_dots$ac_given_srcdir" ;;
2776 esac
2778 case "$ac_given_INSTALL" in
2779 [/$]*) INSTALL="$ac_given_INSTALL" ;;
2780 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
2781 esac
2783 echo creating "$ac_file"
2784 rm -f "$ac_file"
2785 configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
2786 case "$ac_file" in
2787 *Makefile*) ac_comsub="1i\\
2788 # $configure_input" ;;
2789 *) ac_comsub= ;;
2790 esac
2792 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
2793 sed -e "$ac_comsub
2794 s%@configure_input@%$configure_input%g
2795 s%@srcdir@%$srcdir%g
2796 s%@top_srcdir@%$top_srcdir%g
2797 s%@INSTALL@%$INSTALL%g
2798 " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
2799 fi; done
2800 rm -f conftest.s*
2803 cat >> $CONFIG_STATUS <<EOF
2804 srcdir=${srcdir}
2805 host=${host}
2806 target=${target}
2807 with_multisubdir=${with_multisubdir}
2808 ac_configure_args="${multilib_arg} ${ac_configure_args}"
2809 CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
2810 zlib_basedir=${zlib_basedir}
2811 CC="${CC}"
2812 CXX="${CXX}"
2815 cat >> $CONFIG_STATUS <<\EOF
2816 if test -n "$CONFIG_FILES"; then
2817 ac_file=Makefile . ${zlib_basedir}/../config-ml.in
2819 exit 0
2821 chmod +x $CONFIG_STATUS
2822 rm -fr confdefs* $ac_clean_files
2823 test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1