Release 960606
[wine/multimedia.git] / configure
blob72b314342e432ba76353523c277064f60d7ab5fd
1 #! /bin/sh
3 # From configure.in configure.in 1.00
4 # Guess values for system-dependent variables and create Makefiles.
5 # Generated automatically using autoconf version 2.10-patched
6 # Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
8 # This configure script is free software; the Free Software Foundation
9 # gives unlimited permission to copy, distribute and modify it.
11 # Defaults:
12 ac_help=
13 ac_default_prefix=/usr/local
14 # Any additions from configure.in:
15 ac_help="$ac_help
16 --with-library build Wine as a library instead of an emulator"
17 ac_help="$ac_help
18 --with-dll build Wine as a DLL instead of an emulator"
19 ac_help="$ac_help
20 --with-ipc use inter-process communication for DDE"
21 ac_help="$ac_help
22 --with-malloc-debug enable malloc() debugging"
23 ac_help="$ac_help
24 --with-x use the X Window System"
26 # Initialize some variables set by options.
27 # The variables have the same names as the options, with
28 # dashes changed to underlines.
29 build=NONE
30 cache_file=./config.cache
31 exec_prefix=NONE
32 host=NONE
33 no_create=
34 nonopt=NONE
35 no_recursion=
36 prefix=NONE
37 program_prefix=NONE
38 program_suffix=NONE
39 program_transform_name=s,x,x,
40 silent=
41 site=
42 srcdir=
43 target=NONE
44 verbose=
45 x_includes=NONE
46 x_libraries=NONE
47 bindir='${exec_prefix}/bin'
48 sbindir='${exec_prefix}/sbin'
49 libexecdir='${exec_prefix}/libexec'
50 datadir='${prefix}/share'
51 sysconfdir='${prefix}/etc'
52 sharedstatedir='${prefix}/com'
53 localstatedir='${prefix}/var'
54 libdir='${exec_prefix}/lib'
55 includedir='${prefix}/include'
56 oldincludedir='/usr/include'
57 infodir='${prefix}/info'
58 mandir='${prefix}/man'
60 # Initialize some other variables.
61 subdirs=
62 MFLAGS= MAKEFLAGS=
64 ac_prev=
65 for ac_option
68 # If the previous option needs an argument, assign it.
69 if test -n "$ac_prev"; then
70 eval "$ac_prev=\$ac_option"
71 ac_prev=
72 continue
75 case "$ac_option" in
76 -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
77 *) ac_optarg= ;;
78 esac
80 # Accept the important Cygnus configure options, so we can diagnose typos.
82 case "$ac_option" in
84 -bindir | --bindir | --bindi | --bind | --bin | --bi)
85 ac_prev=bindir ;;
86 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
87 bindir="$ac_optarg" ;;
89 -build | --build | --buil | --bui | --bu)
90 ac_prev=build ;;
91 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
92 build="$ac_optarg" ;;
94 -cache-file | --cache-file | --cache-fil | --cache-fi \
95 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
96 ac_prev=cache_file ;;
97 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
98 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
99 cache_file="$ac_optarg" ;;
101 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
102 ac_prev=datadir ;;
103 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
104 | --da=*)
105 datadir="$ac_optarg" ;;
107 -disable-* | --disable-*)
108 ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
109 # Reject names that are not valid shell variable names.
110 if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
111 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
113 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
114 eval "enable_${ac_feature}=no" ;;
116 -enable-* | --enable-*)
117 ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
118 # Reject names that are not valid shell variable names.
119 if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
120 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
122 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
123 case "$ac_option" in
124 *=*) ;;
125 *) ac_optarg=yes ;;
126 esac
127 eval "enable_${ac_feature}='$ac_optarg'" ;;
129 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
130 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
131 | --exec | --exe | --ex)
132 ac_prev=exec_prefix ;;
133 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
134 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
135 | --exec=* | --exe=* | --ex=*)
136 exec_prefix="$ac_optarg" ;;
138 -gas | --gas | --ga | --g)
139 # Obsolete; use --with-gas.
140 with_gas=yes ;;
142 -help | --help | --hel | --he)
143 # Omit some internal or obsolete options to make the list less imposing.
144 # This message is too long to be a string in the A/UX 3.1 sh.
145 cat << EOF
146 Usage: configure [options] [host]
147 Options: [defaults in brackets after descriptions]
148 Configuration:
149 --cache-file=FILE cache test results in FILE
150 --help print this message
151 --no-create do not create output files
152 --quiet, --silent do not print \`checking...' messages
153 --version print the version of autoconf that created configure
154 Directory and file names:
155 --prefix=PREFIX install architecture-independent files in PREFIX
156 [$ac_default_prefix]
157 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
158 [same as prefix]
159 --bindir=DIR user executables in DIR [EPREFIX/bin]
160 --sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
161 --libexecdir=DIR program executables in DIR [EPREFIX/libexec]
162 --datadir=DIR read-only architecture-independent data in DIR
163 [PREFIX/share]
164 --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
165 --sharedstatedir=DIR modifiable architecture-independent data in DIR
166 [PREFIX/com]
167 --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
168 --libdir=DIR object code libraries in DIR [EPREFIX/lib]
169 --includedir=DIR C header files in DIR [PREFIX/include]
170 --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
171 --infodir=DIR info documentation in DIR [PREFIX/info]
172 --mandir=DIR man documentation in DIR [PREFIX/man]
173 --srcdir=DIR find the sources in DIR [configure dir or ..]
174 --program-prefix=PREFIX prepend PREFIX to installed program names
175 --program-suffix=SUFFIX append SUFFIX to installed program names
176 --program-transform-name=PROGRAM
177 run sed PROGRAM on installed program names
179 cat << EOF
180 Host type:
181 --build=BUILD configure for building on BUILD [BUILD=HOST]
182 --host=HOST configure for HOST [guessed]
183 --target=TARGET configure for TARGET [TARGET=HOST]
184 Features and packages:
185 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
186 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
187 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
188 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
189 --x-includes=DIR X include files are in DIR
190 --x-libraries=DIR X library files are in DIR
192 if test -n "$ac_help"; then
193 echo "--enable and --with options recognized:$ac_help"
195 exit 0 ;;
197 -host | --host | --hos | --ho)
198 ac_prev=host ;;
199 -host=* | --host=* | --hos=* | --ho=*)
200 host="$ac_optarg" ;;
202 -includedir | --includedir | --includedi | --included | --include \
203 | --includ | --inclu | --incl | --inc)
204 ac_prev=includedir ;;
205 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
206 | --includ=* | --inclu=* | --incl=* | --inc=*)
207 includedir="$ac_optarg" ;;
209 -infodir | --infodir | --infodi | --infod | --info | --inf)
210 ac_prev=infodir ;;
211 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
212 infodir="$ac_optarg" ;;
214 -libdir | --libdir | --libdi | --libd)
215 ac_prev=libdir ;;
216 -libdir=* | --libdir=* | --libdi=* | --libd=*)
217 libdir="$ac_optarg" ;;
219 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
220 | --libexe | --libex | --libe)
221 ac_prev=libexecdir ;;
222 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
223 | --libexe=* | --libex=* | --libe=*)
224 libexecdir="$ac_optarg" ;;
226 -localstatedir | --localstatedir | --localstatedi | --localstated \
227 | --localstate | --localstat | --localsta | --localst \
228 | --locals | --local | --loca | --loc | --lo)
229 ac_prev=localstatedir ;;
230 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
231 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
232 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
233 localstatedir="$ac_optarg" ;;
235 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
236 ac_prev=mandir ;;
237 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
238 mandir="$ac_optarg" ;;
240 -nfp | --nfp | --nf)
241 # Obsolete; use --without-fp.
242 with_fp=no ;;
244 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
245 | --no-cr | --no-c)
246 no_create=yes ;;
248 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
249 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
250 no_recursion=yes ;;
252 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
253 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
254 | --oldin | --oldi | --old | --ol | --o)
255 ac_prev=oldincludedir ;;
256 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
257 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
258 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
259 oldincludedir="$ac_optarg" ;;
261 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
262 ac_prev=prefix ;;
263 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
264 prefix="$ac_optarg" ;;
266 -program-prefix | --program-prefix | --program-prefi | --program-pref \
267 | --program-pre | --program-pr | --program-p)
268 ac_prev=program_prefix ;;
269 -program-prefix=* | --program-prefix=* | --program-prefi=* \
270 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
271 program_prefix="$ac_optarg" ;;
273 -program-suffix | --program-suffix | --program-suffi | --program-suff \
274 | --program-suf | --program-su | --program-s)
275 ac_prev=program_suffix ;;
276 -program-suffix=* | --program-suffix=* | --program-suffi=* \
277 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
278 program_suffix="$ac_optarg" ;;
280 -program-transform-name | --program-transform-name \
281 | --program-transform-nam | --program-transform-na \
282 | --program-transform-n | --program-transform- \
283 | --program-transform | --program-transfor \
284 | --program-transfo | --program-transf \
285 | --program-trans | --program-tran \
286 | --progr-tra | --program-tr | --program-t)
287 ac_prev=program_transform_name ;;
288 -program-transform-name=* | --program-transform-name=* \
289 | --program-transform-nam=* | --program-transform-na=* \
290 | --program-transform-n=* | --program-transform-=* \
291 | --program-transform=* | --program-transfor=* \
292 | --program-transfo=* | --program-transf=* \
293 | --program-trans=* | --program-tran=* \
294 | --progr-tra=* | --program-tr=* | --program-t=*)
295 program_transform_name="$ac_optarg" ;;
297 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
298 | -silent | --silent | --silen | --sile | --sil)
299 silent=yes ;;
301 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
302 ac_prev=sbindir ;;
303 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
304 | --sbi=* | --sb=*)
305 sbindir="$ac_optarg" ;;
307 -sharedstatedir | --sharedstatedir | --sharedstatedi \
308 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
309 | --sharedst | --shareds | --shared | --share | --shar \
310 | --sha | --sh)
311 ac_prev=sharedstatedir ;;
312 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
313 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
314 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
315 | --sha=* | --sh=*)
316 sharedstatedir="$ac_optarg" ;;
318 -site | --site | --sit)
319 ac_prev=site ;;
320 -site=* | --site=* | --sit=*)
321 site="$ac_optarg" ;;
323 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
324 ac_prev=srcdir ;;
325 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
326 srcdir="$ac_optarg" ;;
328 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
329 | --syscon | --sysco | --sysc | --sys | --sy)
330 ac_prev=sysconfdir ;;
331 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
332 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
333 sysconfdir="$ac_optarg" ;;
335 -target | --target | --targe | --targ | --tar | --ta | --t)
336 ac_prev=target ;;
337 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
338 target="$ac_optarg" ;;
340 -v | -verbose | --verbose | --verbos | --verbo | --verb)
341 verbose=yes ;;
343 -version | --version | --versio | --versi | --vers)
344 echo "configure generated by autoconf version 2.10-patched"
345 exit 0 ;;
347 -with-* | --with-*)
348 ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
349 # Reject names that are not valid shell variable names.
350 if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
351 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
353 ac_package=`echo $ac_package| sed 's/-/_/g'`
354 case "$ac_option" in
355 *=*) ;;
356 *) ac_optarg=yes ;;
357 esac
358 eval "with_${ac_package}='$ac_optarg'" ;;
360 -without-* | --without-*)
361 ac_package=`echo $ac_option|sed -e 's/-*without-//'`
362 # Reject names that are not valid shell variable names.
363 if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
364 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
366 ac_package=`echo $ac_package| sed 's/-/_/g'`
367 eval "with_${ac_package}=no" ;;
369 --x)
370 # Obsolete; use --with-x.
371 with_x=yes ;;
373 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
374 | --x-incl | --x-inc | --x-in | --x-i)
375 ac_prev=x_includes ;;
376 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
377 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
378 x_includes="$ac_optarg" ;;
380 -x-libraries | --x-libraries | --x-librarie | --x-librari \
381 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
382 ac_prev=x_libraries ;;
383 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
384 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
385 x_libraries="$ac_optarg" ;;
387 -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
391 if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
392 echo "configure: warning: $ac_option: invalid host type" 1>&2
394 if test "x$nonopt" != xNONE; then
395 { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
397 nonopt="$ac_option"
400 esac
401 done
403 if test -n "$ac_prev"; then
404 { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
407 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
409 # File descriptor usage:
410 # 0 standard input
411 # 1 file creation
412 # 2 errors and warnings
413 # 3 some systems may open it to /dev/tty
414 # 4 used on the Kubota Titan
415 # 6 checking for... messages and results
416 # 5 compiler messages saved in config.log
417 if test "$silent" = yes; then
418 exec 6>/dev/null
419 else
420 exec 6>&1
422 exec 5>./config.log
424 echo "\
425 This file contains any messages produced by compilers while
426 running configure, to aid debugging if configure makes a mistake.
427 " 1>&5
429 # Strip out --no-create and --no-recursion so they do not pile up.
430 # Also quote any args containing shell metacharacters.
431 ac_configure_args=
432 for ac_arg
434 case "$ac_arg" in
435 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
436 | --no-cr | --no-c) ;;
437 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
438 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
439 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
440 ac_configure_args="$ac_configure_args '$ac_arg'" ;;
441 *) ac_configure_args="$ac_configure_args $ac_arg" ;;
442 esac
443 done
445 # NLS nuisances.
446 # Only set LANG and LC_ALL to C if already set.
447 # These must not be set unconditionally because not all systems understand
448 # e.g. LANG=C (notably SCO).
449 if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
450 if test "${LANG+set}" = set; then LANG=C; export LANG; fi
452 # confdefs.h avoids OS command line length limits that DEFS can exceed.
453 rm -rf conftest* confdefs.h
454 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
455 echo > confdefs.h
457 # A filename unique to this package, relative to the directory that
458 # configure is in, which we can look for to find out if srcdir is correct.
459 ac_unique_file=controls/edit.c
461 # Find the source files, if location was not specified.
462 if test -z "$srcdir"; then
463 ac_srcdir_defaulted=yes
464 # Try the directory containing this script, then its parent.
465 ac_prog=$0
466 ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
467 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
468 srcdir=$ac_confdir
469 if test ! -r $srcdir/$ac_unique_file; then
470 srcdir=..
472 else
473 ac_srcdir_defaulted=no
475 if test ! -r $srcdir/$ac_unique_file; then
476 if test "$ac_srcdir_defaulted" = yes; then
477 { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
478 else
479 { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
482 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
484 # Prefer explicitly selected file to automatically selected ones.
485 if test -z "$CONFIG_SITE"; then
486 if test "x$prefix" != xNONE; then
487 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
488 else
489 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
492 for ac_site_file in $CONFIG_SITE; do
493 if test -r "$ac_site_file"; then
494 echo "loading site script $ac_site_file"
495 . "$ac_site_file"
497 done
499 if test -r "$cache_file"; then
500 echo "loading cache $cache_file"
501 . $cache_file
502 else
503 echo "creating cache $cache_file"
504 > $cache_file
507 ac_ext=c
508 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
509 ac_cpp='$CPP $CPPFLAGS'
510 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
511 ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
513 if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
514 # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
515 if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
516 ac_n= ac_c='
517 ' ac_t=' '
518 else
519 ac_n=-n ac_c= ac_t=
521 else
522 ac_n= ac_c='\c' ac_t=
526 ac_aux_dir=
527 for ac_dir in tools $srcdir/tools; do
528 if test -f $ac_dir/install-sh; then
529 ac_aux_dir=$ac_dir
530 ac_install_sh="$ac_aux_dir/install-sh -c"
531 break
532 elif test -f $ac_dir/install.sh; then
533 ac_aux_dir=$ac_dir
534 ac_install_sh="$ac_aux_dir/install.sh -c"
535 break
537 done
538 if test -z "$ac_aux_dir"; then
539 { echo "configure: error: can not find install-sh or install.sh in tools $srcdir/tools" 1>&2; exit 1; }
541 ac_config_guess=$ac_aux_dir/config.guess
542 ac_config_sub=$ac_aux_dir/config.sub
543 ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
546 # We want these before the checks, so the checks can modify their values.
547 test -z "$CFLAGS" && CFLAGS="-g -O2"
548 test -z "$LDFLAGS" && LDFLAGS=-g
549 test -z "$LDLIBS" && LDLIBS=-lm
552 # Check whether --with-library or --without-library was given.
553 if test "${with_library+set}" = set; then
554 withval="$with_library"
555 cat >> confdefs.h <<\EOF
556 #define WINELIB 1
558 MAIN_TARGET="libwine.a"
559 else
560 MAIN_TARGET="wine"
564 # Check whether --with-dll or --without-dll was given.
565 if test "${with_dll+set}" = set; then
566 withval="$with_dll"
567 cat >> confdefs.h <<\EOF
568 #define WINELIB 1
570 cat >> confdefs.h <<\EOF
571 #define WINELIBDLL 1
574 MAIN_TARGET="libwine.so.1.0" CFLAGS="$CFLAGS -fPIC"
579 # Check whether --with-ipc or --without-ipc was given.
580 if test "${with_ipc+set}" = set; then
581 withval="$with_ipc"
582 cat >> confdefs.h <<\EOF
583 #define CONFIG_IPC 1
589 # Check whether --with-malloc-debug or --without-malloc-debug was given.
590 if test "${with_malloc_debug+set}" = set; then
591 withval="$with_malloc_debug"
592 cat >> confdefs.h <<\EOF
593 #define MALLOC_DEBUGGING 1
600 echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
601 set dummy ${MAKE-make}; ac_make=$2
602 if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
603 echo $ac_n "(cached) $ac_c" 1>&6
604 else
605 cat > conftestmake <<\EOF
606 all:
607 @echo 'ac_maketemp="${MAKE}"'
609 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
610 eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
611 if test -n "$ac_maketemp"; then
612 eval ac_cv_prog_make_${ac_make}_set=yes
613 else
614 eval ac_cv_prog_make_${ac_make}_set=no
616 rm -f conftestmake
618 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
619 echo "$ac_t""yes" 1>&6
620 SET_MAKE=
621 else
622 echo "$ac_t""no" 1>&6
623 SET_MAKE="MAKE=${MAKE-make}"
626 # Extract the first word of "gcc", so it can be a program name with args.
627 set dummy gcc; ac_word=$2
628 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
629 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
630 echo $ac_n "(cached) $ac_c" 1>&6
631 else
632 if test -n "$CC"; then
633 ac_cv_prog_CC="$CC" # Let the user override the test.
634 else
635 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
636 for ac_dir in $PATH; do
637 test -z "$ac_dir" && ac_dir=.
638 if test -f $ac_dir/$ac_word; then
639 ac_cv_prog_CC="gcc"
640 break
642 done
643 IFS="$ac_save_ifs"
646 CC="$ac_cv_prog_CC"
647 if test -n "$CC"; then
648 echo "$ac_t""$CC" 1>&6
649 else
650 echo "$ac_t""no" 1>&6
653 if test -z "$CC"; then
654 # Extract the first word of "cc", so it can be a program name with args.
655 set dummy cc; ac_word=$2
656 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
657 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
658 echo $ac_n "(cached) $ac_c" 1>&6
659 else
660 if test -n "$CC"; then
661 ac_cv_prog_CC="$CC" # Let the user override the test.
662 else
663 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
664 ac_prog_rejected=no
665 for ac_dir in $PATH; do
666 test -z "$ac_dir" && ac_dir=.
667 if test -f $ac_dir/$ac_word; then
668 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
669 ac_prog_rejected=yes
670 continue
672 ac_cv_prog_CC="cc"
673 break
675 done
676 IFS="$ac_save_ifs"
677 if test $ac_prog_rejected = yes; then
678 # We found a bogon in the path, so make sure we never use it.
679 set dummy $ac_cv_prog_CC
680 shift
681 if test $# -gt 0; then
682 # We chose a different compiler from the bogus one.
683 # However, it has the same basename, so the bogon will be chosen
684 # first if we set CC to just the basename; use the full file name.
685 shift
686 set dummy "$ac_dir/$ac_word" "$@"
687 shift
688 ac_cv_prog_CC="$@"
693 CC="$ac_cv_prog_CC"
694 if test -n "$CC"; then
695 echo "$ac_t""$CC" 1>&6
696 else
697 echo "$ac_t""no" 1>&6
700 test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
703 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
704 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
705 echo $ac_n "(cached) $ac_c" 1>&6
706 else
707 cat > conftest.c <<EOF
708 #ifdef __GNUC__
709 yes;
710 #endif
712 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:713: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
713 ac_cv_prog_gcc=yes
714 else
715 ac_cv_prog_gcc=no
719 echo "$ac_t""$ac_cv_prog_gcc" 1>&6
720 if test $ac_cv_prog_gcc = yes; then
721 GCC=yes
722 if test "${CFLAGS+set}" != set; then
723 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
724 if eval "test \"`echo '$''{'ac_cv_prog_gcc_g'+set}'`\" = set"; then
725 echo $ac_n "(cached) $ac_c" 1>&6
726 else
727 echo 'void f(){}' > conftest.c
728 if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
729 ac_cv_prog_gcc_g=yes
730 else
731 ac_cv_prog_gcc_g=no
733 rm -f conftest*
737 echo "$ac_t""$ac_cv_prog_gcc_g" 1>&6
738 if test $ac_cv_prog_gcc_g = yes; then
739 CFLAGS="-g -O"
740 else
741 CFLAGS="-O"
744 else
745 GCC=
746 test "${CFLAGS+set}" = set || CFLAGS="-g"
749 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
750 # On Suns, sometimes $CPP names a directory.
751 if test -n "$CPP" && test -d "$CPP"; then
752 CPP=
754 if test -z "$CPP"; then
755 if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
756 echo $ac_n "(cached) $ac_c" 1>&6
757 else
758 # This must be in double quotes, not single quotes, because CPP may get
759 # substituted into the Makefile and "${CC-cc}" will confuse make.
760 CPP="${CC-cc} -E"
761 # On the NeXT, cc -E runs the code through the compiler's parser,
762 # not just through cpp.
763 cat > conftest.$ac_ext <<EOF
764 #line 765 "configure"
765 #include "confdefs.h"
766 #include <assert.h>
767 Syntax Error
769 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
770 { (eval echo configure:771: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
771 ac_err=`grep -v '^ *+' conftest.out`
772 if test -z "$ac_err"; then
774 else
775 echo "$ac_err" >&5
776 rm -rf conftest*
777 CPP="${CC-cc} -E -traditional-cpp"
778 cat > conftest.$ac_ext <<EOF
779 #line 780 "configure"
780 #include "confdefs.h"
781 #include <assert.h>
782 Syntax Error
784 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
785 { (eval echo configure:786: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
786 ac_err=`grep -v '^ *+' conftest.out`
787 if test -z "$ac_err"; then
789 else
790 echo "$ac_err" >&5
791 rm -rf conftest*
792 CPP=/lib/cpp
794 rm -f conftest*
796 rm -f conftest*
797 ac_cv_prog_CPP="$CPP"
799 CPP="$ac_cv_prog_CPP"
800 else
801 ac_cv_prog_CPP="$CPP"
803 echo "$ac_t""$CPP" 1>&6
805 echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6
806 if test -d /etc/conf/kconfig.d &&
807 grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
808 then
809 echo "$ac_t""yes" 1>&6
810 ISC=yes # If later tests want to check for ISC.
811 cat >> confdefs.h <<\EOF
812 #define _POSIX_SOURCE 1
815 if test "$GCC" = yes; then
816 CC="$CC -posix"
817 else
818 CC="$CC -Xp"
820 else
821 echo "$ac_t""no" 1>&6
822 ISC=
825 # If we find X, set shell vars x_includes and x_libraries to the
826 # paths, otherwise set no_x=yes.
827 # Uses ac_ vars as temps to allow command line to override cache and checks.
828 # --without-x overrides everything else, but does not touch the cache.
829 echo $ac_n "checking for X""... $ac_c" 1>&6
831 # Check whether --with-x or --without-x was given.
832 if test "${with_x+set}" = set; then
833 withval="$with_x"
837 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
838 if test "x$with_x" = xno; then
839 # The user explicitly disabled X.
840 have_x=disabled
841 else
842 if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
843 # Both variables are already set.
844 have_x=yes
845 else
846 if eval "test \"`echo '$''{'ac_cv_have_x'+set}'`\" = set"; then
847 echo $ac_n "(cached) $ac_c" 1>&6
848 else
849 # One or both of the vars are not set, and there is no cached value.
850 ac_x_includes=NO ac_x_libraries=NO
851 rm -fr conftestdir
852 if mkdir conftestdir; then
853 cd conftestdir
854 # Make sure to not put "make" in the Imakefile rules, since we grep it out.
855 cat > Imakefile <<'EOF'
856 acfindx:
857 @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
859 if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
860 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
861 eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
862 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
863 for ac_extension in a so sl; do
864 if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
865 test -f $ac_im_libdir/libX11.$ac_extension; then
866 ac_im_usrlibdir=$ac_im_libdir; break
868 done
869 # Screen out bogus values from the imake configuration.
870 case "$ac_im_incroot" in
871 /usr/include) ;;
872 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes="$ac_im_incroot" ;;
873 esac
874 case "$ac_im_usrlibdir" in
875 /usr/lib | /lib) ;;
876 *) test -d "$ac_im_usrlibdir" && ac_x_libraries="$ac_im_usrlibdir" ;;
877 esac
879 cd ..
880 rm -fr conftestdir
883 if test "$ac_x_includes" = NO; then
884 # Guess where to find include files, by looking for this one X11 .h file.
885 test -z "$x_direct_test_include" && x_direct_test_include=X11/Intrinsic.h
887 # First, try using that file with no special directory specified.
888 cat > conftest.$ac_ext <<EOF
889 #line 890 "configure"
890 #include "confdefs.h"
891 #include <$x_direct_test_include>
893 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
894 { (eval echo configure:895: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
895 ac_err=`grep -v '^ *+' conftest.out`
896 if test -z "$ac_err"; then
897 rm -rf conftest*
898 # We can compile using X headers with no special include directory.
899 ac_x_includes=
900 else
901 echo "$ac_err" >&5
902 rm -rf conftest*
903 # Look for the header file in a standard set of common directories.
904 for ac_dir in \
905 /usr/X11R6/include \
906 /usr/X11R5/include \
907 /usr/X11R4/include \
909 /usr/include/X11R6 \
910 /usr/include/X11R5 \
911 /usr/include/X11R4 \
913 /usr/local/X11R6/include \
914 /usr/local/X11R5/include \
915 /usr/local/X11R4/include \
917 /usr/local/include/X11R6 \
918 /usr/local/include/X11R5 \
919 /usr/local/include/X11R4 \
921 /usr/X11/include \
922 /usr/include/X11 \
923 /usr/local/X11/include \
924 /usr/local/include/X11 \
926 /usr/X386/include \
927 /usr/x386/include \
928 /usr/XFree86/include/X11 \
930 /usr/include \
931 /usr/local/include \
932 /usr/unsupported/include \
933 /usr/athena/include \
934 /usr/local/x11r5/include \
935 /usr/lpp/Xamples/include \
937 /usr/openwin/include \
938 /usr/openwin/share/include \
941 if test -r "$ac_dir/$x_direct_test_include"; then
942 ac_x_includes=$ac_dir
943 break
945 done
947 rm -f conftest*
948 fi # $ac_x_includes = NO
950 if test "$ac_x_libraries" = NO; then
951 # Check for the libraries.
953 test -z "$x_direct_test_library" && x_direct_test_library=Xt
954 test -z "$x_direct_test_function" && x_direct_test_function=XtMalloc
956 # See if we find them without any special options.
957 # Don't add to $LIBS permanently.
958 ac_save_LIBS="$LIBS"
959 LIBS="-l$x_direct_test_library $LIBS"
960 cat > conftest.$ac_ext <<EOF
961 #line 962 "configure"
962 #include "confdefs.h"
964 int main() { return 0; }
965 int t() {
966 ${x_direct_test_function}()
967 ; return 0; }
969 if { (eval echo configure:970: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
970 rm -rf conftest*
971 LIBS="$ac_save_LIBS"
972 # We can link X programs with no special library path.
973 ac_x_libraries=
974 else
975 rm -rf conftest*
976 LIBS="$ac_save_LIBS"
977 # First see if replacing the include by lib works.
978 for ac_dir in `echo "$ac_x_includes" | sed s/include/lib/` \
979 /usr/X11R6/lib \
980 /usr/X11R5/lib \
981 /usr/X11R4/lib \
983 /usr/lib/X11R6 \
984 /usr/lib/X11R5 \
985 /usr/lib/X11R4 \
987 /usr/local/X11R6/lib \
988 /usr/local/X11R5/lib \
989 /usr/local/X11R4/lib \
991 /usr/local/lib/X11R6 \
992 /usr/local/lib/X11R5 \
993 /usr/local/lib/X11R4 \
995 /usr/X11/lib \
996 /usr/lib/X11 \
997 /usr/local/X11/lib \
998 /usr/local/lib/X11 \
1000 /usr/X386/lib \
1001 /usr/x386/lib \
1002 /usr/XFree86/lib/X11 \
1004 /usr/lib \
1005 /usr/local/lib \
1006 /usr/unsupported/lib \
1007 /usr/athena/lib \
1008 /usr/local/x11r5/lib \
1009 /usr/lpp/Xamples/lib \
1011 /usr/openwin/lib \
1012 /usr/openwin/share/lib \
1015 for ac_extension in a so sl; do
1016 if test -r $ac_dir/lib${x_direct_test_library}.$ac_extension; then
1017 ac_x_libraries=$ac_dir
1018 break 2
1020 done
1021 done
1023 rm -f conftest*
1025 fi # $ac_x_libraries = NO
1027 if test "$ac_x_includes" = NO || test "$ac_x_libraries" = NO; then
1028 # Didn't find X anywhere. Cache the known absence of X.
1029 ac_cv_have_x="have_x=no"
1030 else
1031 # Record where we found X for the cache.
1032 ac_cv_have_x="have_x=yes \
1033 ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
1037 eval "$ac_cv_have_x"
1038 fi # $with_x != no
1040 if test "$have_x" != yes; then
1041 echo "$ac_t""$have_x" 1>&6
1042 no_x=yes
1043 else
1044 # If each of the values was on the command line, it overrides each guess.
1045 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
1046 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
1047 # Update the cache value to reflect the command line values.
1048 ac_cv_have_x="have_x=yes \
1049 ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
1050 echo "$ac_t""libraries $x_libraries, headers $x_includes" 1>&6
1053 if test "$no_x" = yes; then
1054 # Not all programs may use this symbol, but it does not hurt to define it.
1055 X_CFLAGS="$X_CFLAGS -DX_DISPLAY_MISSING"
1056 else
1057 if test -n "$x_includes"; then
1058 X_CFLAGS="$X_CFLAGS -I$x_includes"
1061 # It would be nice to have a more robust check for the -R ld option than
1062 # just checking for Solaris.
1063 # It would also be nice to do this for all -L options, not just this one.
1064 if test -n "$x_libraries"; then
1065 X_LIBS="$X_LIBS -L$x_libraries"
1066 if test "`(uname) 2>/dev/null`" = SunOS &&
1067 uname -r | grep '^5' >/dev/null; then
1068 X_LIBS="$X_LIBS -R $x_libraries"
1072 # Check for libraries that X11R6 Xt/Xaw programs need.
1074 ac_save_LDFLAGS="$LDFLAGS"
1075 LDFLAGS="$LDFLAGS -L$x_libraries"
1076 # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
1077 # check for ICE first), but we must link in the order -lSM -lICE or
1078 # we get undefined symbols. So assume we have SM if we have ICE.
1079 # These have to be linked with before -lX11, unlike the other
1080 # libraries we check for below, so use a different variable.
1081 # --interran@uluru.Stanford.EDU, kb@cs.umb.edu.
1082 echo $ac_n "checking for -lICE""... $ac_c" 1>&6
1083 ac_lib_var=`echo ICE'_'IceConnectionNumber | tr './+\055' '__p_'`
1084 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1085 echo $ac_n "(cached) $ac_c" 1>&6
1086 else
1087 ac_save_LIBS="$LIBS"
1088 LIBS="-lICE $LIBS"
1089 cat > conftest.$ac_ext <<EOF
1090 #line 1091 "configure"
1091 #include "confdefs.h"
1092 /* Override any gcc2 internal prototype to avoid an error. */
1093 /* We use char because int might match the return type of a gcc2
1094 builtin and then its argument prototype would still apply. */
1095 char IceConnectionNumber();
1097 int main() { return 0; }
1098 int t() {
1099 IceConnectionNumber()
1100 ; return 0; }
1102 if { (eval echo configure:1103: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
1103 rm -rf conftest*
1104 eval "ac_cv_lib_$ac_lib_var=yes"
1105 else
1106 rm -rf conftest*
1107 eval "ac_cv_lib_$ac_lib_var=no"
1109 rm -f conftest*
1110 LIBS="$ac_save_LIBS"
1113 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1114 echo "$ac_t""yes" 1>&6
1115 X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
1116 else
1117 echo "$ac_t""no" 1>&6
1120 LDFLAGS="$ac_save_LDFLAGS"
1122 # Check for system-dependent libraries X programs must link with.
1124 if test "$ISC" = yes; then
1125 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
1126 else
1127 # Martyn.Johnson@cl.cam.ac.uk says this is needed for Ultrix, if the X
1128 # libraries were built with DECnet support. And karl@cs.umb.edu says
1129 # the Alpha needs dnet_stub (dnet does not exist).
1130 echo $ac_n "checking for -ldnet""... $ac_c" 1>&6
1131 ac_lib_var=`echo dnet'_'dnet_ntoa | tr './+\055' '__p_'`
1132 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1133 echo $ac_n "(cached) $ac_c" 1>&6
1134 else
1135 ac_save_LIBS="$LIBS"
1136 LIBS="-ldnet $LIBS"
1137 cat > conftest.$ac_ext <<EOF
1138 #line 1139 "configure"
1139 #include "confdefs.h"
1140 /* Override any gcc2 internal prototype to avoid an error. */
1141 /* We use char because int might match the return type of a gcc2
1142 builtin and then its argument prototype would still apply. */
1143 char dnet_ntoa();
1145 int main() { return 0; }
1146 int t() {
1147 dnet_ntoa()
1148 ; return 0; }
1150 if { (eval echo configure:1151: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
1151 rm -rf conftest*
1152 eval "ac_cv_lib_$ac_lib_var=yes"
1153 else
1154 rm -rf conftest*
1155 eval "ac_cv_lib_$ac_lib_var=no"
1157 rm -f conftest*
1158 LIBS="$ac_save_LIBS"
1161 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1162 echo "$ac_t""yes" 1>&6
1163 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
1164 else
1165 echo "$ac_t""no" 1>&6
1168 if test $ac_cv_lib_dnet_dnet_ntoa = no; then
1169 echo $ac_n "checking for -ldnet_stub""... $ac_c" 1>&6
1170 ac_lib_var=`echo dnet_stub'_'dnet_ntoa | tr './+\055' '__p_'`
1171 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1172 echo $ac_n "(cached) $ac_c" 1>&6
1173 else
1174 ac_save_LIBS="$LIBS"
1175 LIBS="-ldnet_stub $LIBS"
1176 cat > conftest.$ac_ext <<EOF
1177 #line 1178 "configure"
1178 #include "confdefs.h"
1179 /* Override any gcc2 internal prototype to avoid an error. */
1180 /* We use char because int might match the return type of a gcc2
1181 builtin and then its argument prototype would still apply. */
1182 char dnet_ntoa();
1184 int main() { return 0; }
1185 int t() {
1186 dnet_ntoa()
1187 ; return 0; }
1189 if { (eval echo configure:1190: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
1190 rm -rf conftest*
1191 eval "ac_cv_lib_$ac_lib_var=yes"
1192 else
1193 rm -rf conftest*
1194 eval "ac_cv_lib_$ac_lib_var=no"
1196 rm -f conftest*
1197 LIBS="$ac_save_LIBS"
1200 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1201 echo "$ac_t""yes" 1>&6
1202 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
1203 else
1204 echo "$ac_t""no" 1>&6
1209 # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
1210 # to get the SysV transport functions.
1211 # Not sure which flavor of 386 UNIX this is, but it seems harmless to
1212 # check for it.
1213 echo $ac_n "checking for -lnsl""... $ac_c" 1>&6
1214 ac_lib_var=`echo nsl'_'t_accept | tr './+\055' '__p_'`
1215 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1216 echo $ac_n "(cached) $ac_c" 1>&6
1217 else
1218 ac_save_LIBS="$LIBS"
1219 LIBS="-lnsl $LIBS"
1220 cat > conftest.$ac_ext <<EOF
1221 #line 1222 "configure"
1222 #include "confdefs.h"
1223 /* Override any gcc2 internal prototype to avoid an error. */
1224 /* We use char because int might match the return type of a gcc2
1225 builtin and then its argument prototype would still apply. */
1226 char t_accept();
1228 int main() { return 0; }
1229 int t() {
1230 t_accept()
1231 ; return 0; }
1233 if { (eval echo configure:1234: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
1234 rm -rf conftest*
1235 eval "ac_cv_lib_$ac_lib_var=yes"
1236 else
1237 rm -rf conftest*
1238 eval "ac_cv_lib_$ac_lib_var=no"
1240 rm -f conftest*
1241 LIBS="$ac_save_LIBS"
1244 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1245 echo "$ac_t""yes" 1>&6
1246 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
1247 else
1248 echo "$ac_t""no" 1>&6
1252 # lieder@skyler.mavd.honeywell.com says without -lsocket,
1253 # socket/setsockopt and other routines are undefined under SCO ODT 2.0.
1254 # But -lsocket is broken on IRIX, according to simon@lia.di.epfl.ch.
1255 if test "`(uname) 2>/dev/null`" != IRIX; then
1256 if test $ac_cv_lib_nsl_t_accept = no; then
1257 echo $ac_n "checking for -lsocket""... $ac_c" 1>&6
1258 ac_lib_var=`echo socket'_'socket | tr './+\055' '__p_'`
1259 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1260 echo $ac_n "(cached) $ac_c" 1>&6
1261 else
1262 ac_save_LIBS="$LIBS"
1263 LIBS="-lsocket $LIBS"
1264 cat > conftest.$ac_ext <<EOF
1265 #line 1266 "configure"
1266 #include "confdefs.h"
1267 /* Override any gcc2 internal prototype to avoid an error. */
1268 /* We use char because int might match the return type of a gcc2
1269 builtin and then its argument prototype would still apply. */
1270 char socket();
1272 int main() { return 0; }
1273 int t() {
1274 socket()
1275 ; return 0; }
1277 if { (eval echo configure:1278: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
1278 rm -rf conftest*
1279 eval "ac_cv_lib_$ac_lib_var=yes"
1280 else
1281 rm -rf conftest*
1282 eval "ac_cv_lib_$ac_lib_var=no"
1284 rm -f conftest*
1285 LIBS="$ac_save_LIBS"
1288 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1289 echo "$ac_t""yes" 1>&6
1290 X_EXTRA_LIBS="$X_EXTRA_LIBS -lsocket"
1291 else
1292 echo "$ac_t""no" 1>&6
1295 else
1296 # If we found -lnsl, use it to check for -lsocket. -- AJ
1297 echo $ac_n "checking for -lsocket""... $ac_c" 1>&6
1298 ac_lib_var=`echo socket'_'socket | tr './+\055' '__p_'`
1299 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1300 echo $ac_n "(cached) $ac_c" 1>&6
1301 else
1302 ac_save_LIBS="$LIBS"
1303 LIBS="-lsocket -lnsl $LIBS"
1304 cat > conftest.$ac_ext <<EOF
1305 #line 1306 "configure"
1306 #include "confdefs.h"
1307 /* Override any gcc2 internal prototype to avoid an error. */
1308 /* We use char because int might match the return type of a gcc2
1309 builtin and then its argument prototype would still apply. */
1310 char socket();
1312 int main() { return 0; }
1313 int t() {
1314 socket()
1315 ; return 0; }
1317 if { (eval echo configure:1318: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
1318 rm -rf conftest*
1319 eval "ac_cv_lib_$ac_lib_var=yes"
1320 else
1321 rm -rf conftest*
1322 eval "ac_cv_lib_$ac_lib_var=no"
1324 rm -f conftest*
1325 LIBS="$ac_save_LIBS"
1328 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1329 echo "$ac_t""yes" 1>&6
1330 X_EXTRA_LIBS="$X_EXTRA_LIBS -lsocket"
1331 else
1332 echo "$ac_t""no" 1>&6
1340 for ac_prog in 'bison -y' byacc
1342 # Extract the first word of "$ac_prog", so it can be a program name with args.
1343 set dummy $ac_prog; ac_word=$2
1344 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1345 if eval "test \"`echo '$''{'ac_cv_prog_YACC'+set}'`\" = set"; then
1346 echo $ac_n "(cached) $ac_c" 1>&6
1347 else
1348 if test -n "$YACC"; then
1349 ac_cv_prog_YACC="$YACC" # Let the user override the test.
1350 else
1351 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1352 for ac_dir in $PATH; do
1353 test -z "$ac_dir" && ac_dir=.
1354 if test -f $ac_dir/$ac_word; then
1355 ac_cv_prog_YACC="$ac_prog"
1356 break
1358 done
1359 IFS="$ac_save_ifs"
1362 YACC="$ac_cv_prog_YACC"
1363 if test -n "$YACC"; then
1364 echo "$ac_t""$YACC" 1>&6
1365 else
1366 echo "$ac_t""no" 1>&6
1369 test -n "$YACC" && break
1370 done
1371 test -n "$YACC" || YACC="yacc"
1373 # Extract the first word of "flex", so it can be a program name with args.
1374 set dummy flex; ac_word=$2
1375 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1376 if eval "test \"`echo '$''{'ac_cv_prog_LEX'+set}'`\" = set"; then
1377 echo $ac_n "(cached) $ac_c" 1>&6
1378 else
1379 if test -n "$LEX"; then
1380 ac_cv_prog_LEX="$LEX" # Let the user override the test.
1381 else
1382 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1383 for ac_dir in $PATH; do
1384 test -z "$ac_dir" && ac_dir=.
1385 if test -f $ac_dir/$ac_word; then
1386 ac_cv_prog_LEX="flex"
1387 break
1389 done
1390 IFS="$ac_save_ifs"
1391 test -z "$ac_cv_prog_LEX" && ac_cv_prog_LEX="lex"
1394 LEX="$ac_cv_prog_LEX"
1395 if test -n "$LEX"; then
1396 echo "$ac_t""$LEX" 1>&6
1397 else
1398 echo "$ac_t""no" 1>&6
1401 if test -z "$LEXLIB"
1402 then
1403 case "$LEX" in
1404 flex*) ac_lib=fl ;;
1405 *) ac_lib=l ;;
1406 esac
1407 echo $ac_n "checking for -l$ac_lib""... $ac_c" 1>&6
1408 ac_lib_var=`echo $ac_lib'_'yywrap | tr './+\055' '__p_'`
1409 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1410 echo $ac_n "(cached) $ac_c" 1>&6
1411 else
1412 ac_save_LIBS="$LIBS"
1413 LIBS="-l$ac_lib $LIBS"
1414 cat > conftest.$ac_ext <<EOF
1415 #line 1416 "configure"
1416 #include "confdefs.h"
1417 /* Override any gcc2 internal prototype to avoid an error. */
1418 /* We use char because int might match the return type of a gcc2
1419 builtin and then its argument prototype would still apply. */
1420 char yywrap();
1422 int main() { return 0; }
1423 int t() {
1424 yywrap()
1425 ; return 0; }
1427 if { (eval echo configure:1428: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
1428 rm -rf conftest*
1429 eval "ac_cv_lib_$ac_lib_var=yes"
1430 else
1431 rm -rf conftest*
1432 eval "ac_cv_lib_$ac_lib_var=no"
1434 rm -f conftest*
1435 LIBS="$ac_save_LIBS"
1438 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1439 echo "$ac_t""yes" 1>&6
1440 LEXLIB="-l$ac_lib"
1441 else
1442 echo "$ac_t""no" 1>&6
1447 # Extract the first word of "ranlib", so it can be a program name with args.
1448 set dummy ranlib; ac_word=$2
1449 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1450 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
1451 echo $ac_n "(cached) $ac_c" 1>&6
1452 else
1453 if test -n "$RANLIB"; then
1454 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1455 else
1456 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1457 for ac_dir in $PATH; do
1458 test -z "$ac_dir" && ac_dir=.
1459 if test -f $ac_dir/$ac_word; then
1460 ac_cv_prog_RANLIB="ranlib"
1461 break
1463 done
1464 IFS="$ac_save_ifs"
1465 test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
1468 RANLIB="$ac_cv_prog_RANLIB"
1469 if test -n "$RANLIB"; then
1470 echo "$ac_t""$RANLIB" 1>&6
1471 else
1472 echo "$ac_t""no" 1>&6
1475 # Find a good install program. We prefer a C program (faster),
1476 # so one script is as good as another. But avoid the broken or
1477 # incompatible versions:
1478 # SysV /etc/install, /usr/sbin/install
1479 # SunOS /usr/etc/install
1480 # IRIX /sbin/install
1481 # AIX /bin/install
1482 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
1483 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
1484 # ./install, which can be erroneously created by make from ./install.sh.
1485 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
1486 if test -z "$INSTALL"; then
1487 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
1488 echo $ac_n "(cached) $ac_c" 1>&6
1489 else
1490 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1491 for ac_dir in $PATH; do
1492 # Account for people who put trailing slashes in PATH elements.
1493 case "$ac_dir/" in
1494 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
1496 # OSF1 and SCO ODT 3.0 have their own names for install.
1497 for ac_prog in ginstall installbsd scoinst install; do
1498 if test -f $ac_dir/$ac_prog; then
1499 if test $ac_prog = install &&
1500 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
1501 # AIX install. It has an incompatible calling convention.
1502 # OSF/1 installbsd also uses dspmsg, but is usable.
1504 else
1505 ac_cv_path_install="$ac_dir/$ac_prog -c"
1506 break 2
1509 done
1511 esac
1512 done
1513 IFS="$ac_save_ifs"
1516 if test "${ac_cv_path_install+set}" = set; then
1517 INSTALL="$ac_cv_path_install"
1518 else
1519 # As a last resort, use the slow shell script. We don't cache a
1520 # path for INSTALL within a source directory, because that will
1521 # break other packages using the cache if that directory is
1522 # removed, or if the path is relative.
1523 INSTALL="$ac_install_sh"
1526 echo "$ac_t""$INSTALL" 1>&6
1528 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
1529 # It thinks the first close brace ends the variable substitution.
1530 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
1532 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
1534 echo $ac_n "checking for -li386""... $ac_c" 1>&6
1535 ac_lib_var=`echo i386'_'i386_set_ldt | tr './+\055' '__p_'`
1536 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1537 echo $ac_n "(cached) $ac_c" 1>&6
1538 else
1539 ac_save_LIBS="$LIBS"
1540 LIBS="-li386 $LIBS"
1541 cat > conftest.$ac_ext <<EOF
1542 #line 1543 "configure"
1543 #include "confdefs.h"
1544 /* Override any gcc2 internal prototype to avoid an error. */
1545 /* We use char because int might match the return type of a gcc2
1546 builtin and then its argument prototype would still apply. */
1547 char i386_set_ldt();
1549 int main() { return 0; }
1550 int t() {
1551 i386_set_ldt()
1552 ; return 0; }
1554 if { (eval echo configure:1555: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
1555 rm -rf conftest*
1556 eval "ac_cv_lib_$ac_lib_var=yes"
1557 else
1558 rm -rf conftest*
1559 eval "ac_cv_lib_$ac_lib_var=no"
1561 rm -f conftest*
1562 LIBS="$ac_save_LIBS"
1565 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1566 echo "$ac_t""yes" 1>&6
1567 LDLIBS="$LDLIBS -li386"
1568 else
1569 echo "$ac_t""no" 1>&6
1574 if test "x${GCC}" = "xyes"
1575 then
1576 CFLAGS="$CFLAGS -Wall"
1577 # If we cannot run a trivial program, we must be cross compiling.
1578 echo $ac_n "checking whether cross-compiling""... $ac_c" 1>&6
1579 if eval "test \"`echo '$''{'ac_cv_c_cross'+set}'`\" = set"; then
1580 echo $ac_n "(cached) $ac_c" 1>&6
1581 else
1582 if test "$cross_compiling" = yes; then
1583 ac_cv_c_cross=yes
1584 else
1585 cat > conftest.$ac_ext <<EOF
1586 #line 1587 "configure"
1587 #include "confdefs.h"
1588 main(){return(0);}
1590 { (eval echo configure:1591: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }
1591 if test -s conftest && (./conftest; exit) 2>/dev/null; then
1592 ac_cv_c_cross=no
1593 else
1594 ac_cv_c_cross=yes
1597 rm -fr conftest*
1600 echo "$ac_t""$ac_cv_c_cross" 1>&6
1601 cross_compiling=$ac_cv_c_cross
1603 echo $ac_n "checking "for gcc strength-reduce bug"""... $ac_c" 1>&6
1604 if eval "test \"`echo '$''{'ac_cv_c_gcc_strength_bug'+set}'`\" = set"; then
1605 echo $ac_n "(cached) $ac_c" 1>&6
1606 else
1607 if test "$cross_compiling" = yes; then
1608 ac_cv_c_gcc_strength_bug="yes"
1609 else
1610 cat > conftest.$ac_ext <<EOF
1611 #line 1612 "configure"
1612 #include "confdefs.h"
1614 int main(void) {
1615 static int Array[3];
1616 unsigned int B = 3;
1617 int i;
1618 for(i=0; i<B; i++) Array[i] = i - 3;
1619 exit( Array[1] != -2 );
1622 { (eval echo configure:1623: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }
1623 if test -s conftest && (./conftest; exit) 2>/dev/null; then
1624 ac_cv_c_gcc_strength_bug="no"
1625 else
1626 ac_cv_c_gcc_strength_bug="yes"
1629 rm -fr conftest*
1632 echo "$ac_t""$ac_cv_c_gcc_strength_bug" 1>&6
1633 if test "$ac_cv_c_gcc_strength_bug" = "yes"
1634 then
1635 CFLAGS="$CFLAGS -fno-strength-reduce"
1640 for ac_func in tcgetattr usleep
1642 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
1643 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
1644 echo $ac_n "(cached) $ac_c" 1>&6
1645 else
1646 cat > conftest.$ac_ext <<EOF
1647 #line 1648 "configure"
1648 #include "confdefs.h"
1649 /* System header to define __stub macros and hopefully few prototypes,
1650 which can conflict with char $ac_func(); below. */
1651 #include <assert.h>
1652 /* Override any gcc2 internal prototype to avoid an error. */
1653 /* We use char because int might match the return type of a gcc2
1654 builtin and then its argument prototype would still apply. */
1655 char $ac_func();
1657 int main() { return 0; }
1658 int t() {
1660 /* The GNU C library defines this for functions which it implements
1661 to always fail with ENOSYS. Some functions are actually named
1662 something starting with __ and the normal name is an alias. */
1663 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
1664 choke me
1665 #else
1666 $ac_func();
1667 #endif
1669 ; return 0; }
1671 if { (eval echo configure:1672: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
1672 rm -rf conftest*
1673 eval "ac_cv_func_$ac_func=yes"
1674 else
1675 rm -rf conftest*
1676 eval "ac_cv_func_$ac_func=no"
1678 rm -f conftest*
1681 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
1682 echo "$ac_t""yes" 1>&6
1683 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
1684 cat >> confdefs.h <<EOF
1685 #define $ac_tr_func 1
1688 else
1689 echo "$ac_t""no" 1>&6
1691 done
1693 for ac_hdr in stdlib.h
1695 ac_safe=`echo "$ac_hdr" | tr './\055' '___'`
1696 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
1697 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1698 echo $ac_n "(cached) $ac_c" 1>&6
1699 else
1700 cat > conftest.$ac_ext <<EOF
1701 #line 1702 "configure"
1702 #include "confdefs.h"
1703 #include <$ac_hdr>
1705 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1706 { (eval echo configure:1707: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1707 ac_err=`grep -v '^ *+' conftest.out`
1708 if test -z "$ac_err"; then
1709 rm -rf conftest*
1710 eval "ac_cv_header_$ac_safe=yes"
1711 else
1712 echo "$ac_err" >&5
1713 rm -rf conftest*
1714 eval "ac_cv_header_$ac_safe=no"
1716 rm -f conftest*
1718 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1719 echo "$ac_t""yes" 1>&6
1720 ac_tr_hdr=HAVE_`echo $ac_hdr | tr 'abcdefghijklmnopqrstuvwxyz./\055' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ___'`
1721 cat >> confdefs.h <<EOF
1722 #define $ac_tr_hdr 1
1725 else
1726 echo "$ac_t""no" 1>&6
1728 done
1730 echo $ac_n "checking whether stat file-mode macros are broken""... $ac_c" 1>&6
1731 if eval "test \"`echo '$''{'ac_cv_header_stat_broken'+set}'`\" = set"; then
1732 echo $ac_n "(cached) $ac_c" 1>&6
1733 else
1734 cat > conftest.$ac_ext <<EOF
1735 #line 1736 "configure"
1736 #include "confdefs.h"
1737 #include <sys/types.h>
1738 #include <sys/stat.h>
1740 #if defined(S_ISBLK) && defined(S_IFDIR)
1741 # if S_ISBLK (S_IFDIR)
1742 You lose.
1743 # endif
1744 #endif
1746 #if defined(S_ISBLK) && defined(S_IFCHR)
1747 # if S_ISBLK (S_IFCHR)
1748 You lose.
1749 # endif
1750 #endif
1752 #if defined(S_ISLNK) && defined(S_IFREG)
1753 # if S_ISLNK (S_IFREG)
1754 You lose.
1755 # endif
1756 #endif
1758 #if defined(S_ISSOCK) && defined(S_IFREG)
1759 # if S_ISSOCK (S_IFREG)
1760 You lose.
1761 # endif
1762 #endif
1765 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1766 egrep "You lose" >/dev/null 2>&1; then
1767 rm -rf conftest*
1768 ac_cv_header_stat_broken=yes
1769 else
1770 rm -rf conftest*
1771 ac_cv_header_stat_broken=no
1773 rm -f conftest*
1777 echo "$ac_t""$ac_cv_header_stat_broken" 1>&6
1778 if test $ac_cv_header_stat_broken = yes; then
1779 cat >> confdefs.h <<\EOF
1780 #define STAT_MACROS_BROKEN 1
1785 echo $ac_n "checking for working const""... $ac_c" 1>&6
1786 if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
1787 echo $ac_n "(cached) $ac_c" 1>&6
1788 else
1789 cat > conftest.$ac_ext <<EOF
1790 #line 1791 "configure"
1791 #include "confdefs.h"
1793 int main() { return 0; }
1794 int t() {
1796 /* Ultrix mips cc rejects this. */
1797 typedef int charset[2]; const charset x;
1798 /* SunOS 4.1.1 cc rejects this. */
1799 char const *const *ccp;
1800 char **p;
1801 /* NEC SVR4.0.2 mips cc rejects this. */
1802 struct point {int x, y;};
1803 static struct point const zero = {0,0};
1804 /* AIX XL C 1.02.0.0 rejects this.
1805 It does not let you subtract one const X* pointer from another in an arm
1806 of an if-expression whose if-part is not a constant expression */
1807 const char *g = "string";
1808 ccp = &g + (g ? g-g : 0);
1809 /* HPUX 7.0 cc rejects these. */
1810 ++ccp;
1811 p = (char**) ccp;
1812 ccp = (char const *const *) p;
1813 { /* SCO 3.2v4 cc rejects this. */
1814 char *t;
1815 char const *s = 0 ? (char *) 0 : (char const *) 0;
1817 *t++ = 0;
1819 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
1820 int x[] = {25, 17};
1821 const int *foo = &x[0];
1822 ++foo;
1824 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
1825 typedef const int *iptr;
1826 iptr p = 0;
1827 ++p;
1829 { /* AIX XL C 1.02.0.0 rejects this saying
1830 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
1831 struct s { int j; const int *ap[3]; };
1832 struct s *b; b->j = 5;
1834 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
1835 const int foo = 10;
1838 ; return 0; }
1840 if { (eval echo configure:1841: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1841 rm -rf conftest*
1842 ac_cv_c_const=yes
1843 else
1844 rm -rf conftest*
1845 ac_cv_c_const=no
1847 rm -f conftest*
1851 echo "$ac_t""$ac_cv_c_const" 1>&6
1852 if test $ac_cv_c_const = no; then
1853 cat >> confdefs.h <<\EOF
1854 #define const
1859 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
1860 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
1861 echo $ac_n "(cached) $ac_c" 1>&6
1862 else
1863 cat > conftest.$ac_ext <<EOF
1864 #line 1865 "configure"
1865 #include "confdefs.h"
1866 #include <stdlib.h>
1867 #include <stdarg.h>
1868 #include <string.h>
1869 #include <float.h>
1871 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1872 { (eval echo configure:1873: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1873 ac_err=`grep -v '^ *+' conftest.out`
1874 if test -z "$ac_err"; then
1875 rm -rf conftest*
1876 ac_cv_header_stdc=yes
1877 else
1878 echo "$ac_err" >&5
1879 rm -rf conftest*
1880 ac_cv_header_stdc=no
1882 rm -f conftest*
1884 if test $ac_cv_header_stdc = yes; then
1885 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
1886 cat > conftest.$ac_ext <<EOF
1887 #line 1888 "configure"
1888 #include "confdefs.h"
1889 #include <string.h>
1891 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1892 egrep "memchr" >/dev/null 2>&1; then
1894 else
1895 rm -rf conftest*
1896 ac_cv_header_stdc=no
1898 rm -f conftest*
1902 if test $ac_cv_header_stdc = yes; then
1903 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
1904 cat > conftest.$ac_ext <<EOF
1905 #line 1906 "configure"
1906 #include "confdefs.h"
1907 #include <stdlib.h>
1909 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1910 egrep "free" >/dev/null 2>&1; then
1912 else
1913 rm -rf conftest*
1914 ac_cv_header_stdc=no
1916 rm -f conftest*
1920 if test $ac_cv_header_stdc = yes; then
1921 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
1922 if test "$cross_compiling" = yes; then
1924 else
1925 cat > conftest.$ac_ext <<EOF
1926 #line 1927 "configure"
1927 #include "confdefs.h"
1928 #include <ctype.h>
1929 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
1930 #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
1931 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
1932 int main () { int i; for (i = 0; i < 256; i++)
1933 if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
1934 exit (0); }
1937 { (eval echo configure:1938: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }
1938 if test -s conftest && (./conftest; exit) 2>/dev/null; then
1940 else
1941 ac_cv_header_stdc=no
1944 rm -fr conftest*
1948 echo "$ac_t""$ac_cv_header_stdc" 1>&6
1949 if test $ac_cv_header_stdc = yes; then
1950 cat >> confdefs.h <<\EOF
1951 #define STDC_HEADERS 1
1956 echo $ac_n "checking for size_t""... $ac_c" 1>&6
1957 if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
1958 echo $ac_n "(cached) $ac_c" 1>&6
1959 else
1960 cat > conftest.$ac_ext <<EOF
1961 #line 1962 "configure"
1962 #include "confdefs.h"
1963 #include <sys/types.h>
1964 #if STDC_HEADERS
1965 #include <stdlib.h>
1966 #endif
1968 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1969 egrep "size_t" >/dev/null 2>&1; then
1970 rm -rf conftest*
1971 ac_cv_type_size_t=yes
1972 else
1973 rm -rf conftest*
1974 ac_cv_type_size_t=no
1976 rm -f conftest*
1979 echo "$ac_t""$ac_cv_type_size_t" 1>&6
1980 if test $ac_cv_type_size_t = no; then
1981 cat >> confdefs.h <<\EOF
1982 #define size_t unsigned
1989 MAKE_RULES=Make.rules
1992 trap '' 1 2 15
1993 cat > confcache <<\EOF
1994 # This file is a shell script that caches the results of configure
1995 # tests run on this system so they can be shared between configure
1996 # scripts and configure runs. It is not useful on other systems.
1997 # If it contains results you don't want to keep, you may remove or edit it.
1999 # By default, configure uses ./config.cache as the cache file,
2000 # creating it if it does not exist already. You can give configure
2001 # the --cache-file=FILE option to use a different cache file; that is
2002 # what configure does when it calls configure scripts in
2003 # subdirectories, so they share the cache.
2004 # Giving --cache-file=/dev/null disables caching, for debugging configure.
2005 # config.status only pays attention to the cache file if you give it the
2006 # --recheck option to rerun configure.
2009 # Ultrix sh set writes to stderr and can't be redirected directly,
2010 # and sets the high bit in the cache file unless we assign to the vars.
2011 (set) 2>&1 |
2012 sed -n "s/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=\${\1='\2'}/p" \
2013 >> confcache
2014 if cmp -s $cache_file confcache; then
2016 else
2017 if test -w $cache_file; then
2018 echo "updating cache $cache_file"
2019 cat confcache > $cache_file
2020 else
2021 echo "not updating unwritable cache $cache_file"
2024 rm -f confcache
2026 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
2028 test "x$prefix" = xNONE && prefix=$ac_default_prefix
2029 # Let make expand exec_prefix.
2030 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
2032 # Any assignment to VPATH causes Sun make to only execute
2033 # the first set of double-colon rules, so remove it if not needed.
2034 # If there is a colon in the path, we need to keep it.
2035 if test "x$srcdir" = x.; then
2036 ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
2039 trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
2041 # Transform confdefs.h into DEFS.
2042 # Protect against shell expansion while executing Makefile rules.
2043 # Protect against Makefile macro expansion.
2044 cat > conftest.defs <<\EOF
2045 s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%-D\1=\2%g
2046 s%[ `~#$^&*(){}\\|;'"<>?]%\\&%g
2047 s%\[%\\&%g
2048 s%\]%\\&%g
2049 s%\$%$$%g
2051 DEFS=`sed -f conftest.defs confdefs.h | tr '\012' ' '`
2052 rm -f conftest.defs
2055 # Without the "./", some shells look in PATH for config.status.
2056 : ${CONFIG_STATUS=./config.status}
2058 echo creating $CONFIG_STATUS
2059 rm -f $CONFIG_STATUS
2060 cat > $CONFIG_STATUS <<EOF
2061 #! /bin/sh
2062 # Generated automatically by configure.
2063 # Run this file to recreate the current configuration.
2064 # This directory was configured as follows,
2065 # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
2067 # $0 $ac_configure_args
2069 # Compiler output produced by configure, useful for debugging
2070 # configure, is in ./config.log if it exists.
2072 ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
2073 for ac_option
2075 case "\$ac_option" in
2076 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
2077 echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
2078 exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
2079 -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
2080 echo "$CONFIG_STATUS generated by autoconf version 2.10-patched"
2081 exit 0 ;;
2082 -help | --help | --hel | --he | --h)
2083 echo "\$ac_cs_usage"; exit 0 ;;
2084 *) echo "\$ac_cs_usage"; exit 1 ;;
2085 esac
2086 done
2088 ac_given_srcdir=$srcdir
2089 ac_given_INSTALL="$INSTALL"
2091 trap 'rm -fr `echo "
2092 Make.rules
2093 Makefile
2094 controls/Makefile
2095 debugger/Makefile
2096 debugger/readline/Makefile
2097 files/Makefile
2098 if1632/Makefile
2099 ipc/Makefile
2100 library/Makefile
2101 libtest/Makefile
2102 loader/Makefile
2103 memory/Makefile
2104 misc/Makefile
2105 miscemu/Makefile
2106 multimedia/Makefile
2107 objects/Makefile
2108 programs/Makefile
2109 programs/progman/Makefile
2110 programs/winhelp/Makefile
2111 rc/Makefile
2112 resources/Makefile
2113 tools/Makefile
2114 win32/Makefile
2115 windows/Makefile " | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
2117 cat >> $CONFIG_STATUS <<EOF
2119 # Protect against being on the right side of a sed subst in config.status.
2120 sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
2121 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
2122 $ac_vpsub
2123 $extrasub
2124 s%@CFLAGS@%$CFLAGS%g
2125 s%@CPPFLAGS@%$CPPFLAGS%g
2126 s%@CXXFLAGS@%$CXXFLAGS%g
2127 s%@DEFS@%$DEFS%g
2128 s%@LDFLAGS@%$LDFLAGS%g
2129 s%@LIBS@%$LIBS%g
2130 s%@exec_prefix@%$exec_prefix%g
2131 s%@prefix@%$prefix%g
2132 s%@program_transform_name@%$program_transform_name%g
2133 s%@bindir@%$bindir%g
2134 s%@sbindir@%$sbindir%g
2135 s%@libexecdir@%$libexecdir%g
2136 s%@datadir@%$datadir%g
2137 s%@sysconfdir@%$sysconfdir%g
2138 s%@sharedstatedir@%$sharedstatedir%g
2139 s%@localstatedir@%$localstatedir%g
2140 s%@libdir@%$libdir%g
2141 s%@includedir@%$includedir%g
2142 s%@oldincludedir@%$oldincludedir%g
2143 s%@infodir@%$infodir%g
2144 s%@mandir@%$mandir%g
2145 s%@LDLIBS@%$LDLIBS%g
2146 s%@MAIN_TARGET@%$MAIN_TARGET%g
2147 s%@SET_MAKE@%$SET_MAKE%g
2148 s%@CC@%$CC%g
2149 s%@CPP@%$CPP%g
2150 s%@X_CFLAGS@%$X_CFLAGS%g
2151 s%@X_PRE_LIBS@%$X_PRE_LIBS%g
2152 s%@X_LIBS@%$X_LIBS%g
2153 s%@X_EXTRA_LIBS@%$X_EXTRA_LIBS%g
2154 s%@YACC@%$YACC%g
2155 s%@LEX@%$LEX%g
2156 s%@LEXLIB@%$LEXLIB%g
2157 s%@RANLIB@%$RANLIB%g
2158 s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
2159 s%@INSTALL_DATA@%$INSTALL_DATA%g
2160 /@MAKE_RULES@/r $MAKE_RULES
2161 s%@MAKE_RULES@%%g
2163 CEOF
2165 cat >> $CONFIG_STATUS <<EOF
2167 CONFIG_FILES=\${CONFIG_FILES-"Make.rules
2168 Makefile
2169 controls/Makefile
2170 debugger/Makefile
2171 debugger/readline/Makefile
2172 files/Makefile
2173 if1632/Makefile
2174 ipc/Makefile
2175 library/Makefile
2176 libtest/Makefile
2177 loader/Makefile
2178 memory/Makefile
2179 misc/Makefile
2180 miscemu/Makefile
2181 multimedia/Makefile
2182 objects/Makefile
2183 programs/Makefile
2184 programs/progman/Makefile
2185 programs/winhelp/Makefile
2186 rc/Makefile
2187 resources/Makefile
2188 tools/Makefile
2189 win32/Makefile
2190 windows/Makefile "}
2192 cat >> $CONFIG_STATUS <<\EOF
2193 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
2194 # Support "outfile[:infile]", defaulting infile="outfile.in".
2195 case "$ac_file" in
2196 *:*) ac_file_in=`echo "$ac_file"|sed 's%.*:%%'`
2197 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
2198 *) ac_file_in="${ac_file}.in" ;;
2199 esac
2201 # Adjust relative srcdir, etc. for subdirectories.
2203 # Remove last slash and all that follows it. Not all systems have dirname.
2204 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
2205 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
2206 # The file is in a subdirectory.
2207 test ! -d "$ac_dir" && mkdir "$ac_dir"
2208 ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
2209 # A "../" for each directory in $ac_dir_suffix.
2210 ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
2211 else
2212 ac_dir_suffix= ac_dots=
2215 case "$ac_given_srcdir" in
2216 .) srcdir=.
2217 if test -z "$ac_dots"; then top_srcdir=.
2218 else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
2219 /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
2220 *) # Relative path.
2221 srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
2222 top_srcdir="$ac_dots$ac_given_srcdir" ;;
2223 esac
2225 case "$ac_given_INSTALL" in
2226 [/$]*) INSTALL="$ac_given_INSTALL" ;;
2227 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
2228 esac
2229 echo creating "$ac_file"
2230 rm -f "$ac_file"
2231 configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
2232 case "$ac_file" in
2233 *Makefile*) ac_comsub="1i\\
2234 # $configure_input" ;;
2235 *) ac_comsub= ;;
2236 esac
2237 sed -e "$ac_comsub
2238 s%@configure_input@%$configure_input%g
2239 s%@srcdir@%$srcdir%g
2240 s%@top_srcdir@%$top_srcdir%g
2241 s%@INSTALL@%$INSTALL%g
2242 " -f conftest.subs $ac_given_srcdir/$ac_file_in > $ac_file
2243 fi; done
2244 rm -f conftest.subs
2248 exit 0
2250 chmod +x $CONFIG_STATUS
2251 rm -fr confdefs* $ac_clean_files
2252 test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
2255 echo
2256 echo "Configure finished. Do 'make depend; make' to compile Wine."
2257 echo