blob: 4e5f5554f4444adeee12c4319614aee584562213 [file] [log] [blame]
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001#! /bin/sh
2
3# From configure.in configure.in 1.00
4# Guess values for system-dependent variables and create Makefiles.
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +00005# Generated automatically using autoconf version 2.12
Alexandre Julliard59730ae1996-03-24 16:20:51 +00006# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00007#
8# This configure script is free software; the Free Software Foundation
9# gives unlimited permission to copy, distribute and modify it.
10
11# Defaults:
12ac_help=
13ac_default_prefix=/usr/local
14# Any additions from configure.in:
15ac_help="$ac_help
Alexandre Julliarda0b2b1d1997-11-16 17:38:29 +000016 --disable-emulator build only the Wine library, not the emulator"
Alexandre Julliardff8331e1995-09-18 11:19:54 +000017ac_help="$ac_help
Alexandre Julliarda0b2b1d1997-11-16 17:38:29 +000018 --enable-dll build the Wine library as a DLL"
Alexandre Julliard7e56f681996-01-31 19:02:28 +000019ac_help="$ac_help
Alexandre Julliard642d3131998-07-12 19:29:36 +000020 --disable-lib build the Wine without building libwine.a"
21ac_help="$ac_help
Alexandre Julliardf90efa91998-06-14 15:24:15 +000022 --disable-debug compile out all debugging messages"
23ac_help="$ac_help
24 --disable-trace compile out TRACE messages"
25ac_help="$ac_help
Patrik Stridvallf638aef1998-12-07 09:36:13 +000026 --without-reentrant-x compile for use with non-reentrant X libraries"
Alexandre Julliarda11d7b11998-03-01 20:05:02 +000027ac_help="$ac_help
Alexandre Julliarde2991ea1995-07-29 13:09:43 +000028 --with-x use the X Window System"
29
30# Initialize some variables set by options.
31# The variables have the same names as the options, with
32# dashes changed to underlines.
33build=NONE
34cache_file=./config.cache
35exec_prefix=NONE
36host=NONE
37no_create=
38nonopt=NONE
39no_recursion=
40prefix=NONE
41program_prefix=NONE
42program_suffix=NONE
43program_transform_name=s,x,x,
44silent=
45site=
46srcdir=
47target=NONE
48verbose=
49x_includes=NONE
50x_libraries=NONE
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +000051bindir='${exec_prefix}/bin'
52sbindir='${exec_prefix}/sbin'
53libexecdir='${exec_prefix}/libexec'
54datadir='${prefix}/share'
55sysconfdir='${prefix}/etc'
56sharedstatedir='${prefix}/com'
57localstatedir='${prefix}/var'
58libdir='${exec_prefix}/lib'
59includedir='${prefix}/include'
60oldincludedir='/usr/include'
61infodir='${prefix}/info'
62mandir='${prefix}/man'
Alexandre Julliarde2991ea1995-07-29 13:09:43 +000063
64# Initialize some other variables.
65subdirs=
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +000066MFLAGS= MAKEFLAGS=
Alexandre Julliardda0cfb31996-12-01 17:17:47 +000067# Maximum number of lines to put in a shell here document.
68ac_max_here_lines=12
Alexandre Julliarde2991ea1995-07-29 13:09:43 +000069
70ac_prev=
71for ac_option
72do
73
74 # If the previous option needs an argument, assign it.
75 if test -n "$ac_prev"; then
76 eval "$ac_prev=\$ac_option"
77 ac_prev=
78 continue
79 fi
80
81 case "$ac_option" in
82 -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
83 *) ac_optarg= ;;
84 esac
85
86 # Accept the important Cygnus configure options, so we can diagnose typos.
87
88 case "$ac_option" in
89
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +000090 -bindir | --bindir | --bindi | --bind | --bin | --bi)
91 ac_prev=bindir ;;
92 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
93 bindir="$ac_optarg" ;;
94
95 -build | --build | --buil | --bui | --bu)
Alexandre Julliarde2991ea1995-07-29 13:09:43 +000096 ac_prev=build ;;
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +000097 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
Alexandre Julliarde2991ea1995-07-29 13:09:43 +000098 build="$ac_optarg" ;;
99
100 -cache-file | --cache-file | --cache-fil | --cache-fi \
101 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
102 ac_prev=cache_file ;;
103 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
104 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
105 cache_file="$ac_optarg" ;;
106
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +0000107 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
108 ac_prev=datadir ;;
109 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
110 | --da=*)
111 datadir="$ac_optarg" ;;
112
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000113 -disable-* | --disable-*)
114 ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
115 # Reject names that are not valid shell variable names.
116 if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
117 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
118 fi
119 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
120 eval "enable_${ac_feature}=no" ;;
121
122 -enable-* | --enable-*)
123 ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
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; }
127 fi
128 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
129 case "$ac_option" in
130 *=*) ;;
131 *) ac_optarg=yes ;;
132 esac
133 eval "enable_${ac_feature}='$ac_optarg'" ;;
134
135 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
136 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
137 | --exec | --exe | --ex)
138 ac_prev=exec_prefix ;;
139 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
140 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
141 | --exec=* | --exe=* | --ex=*)
142 exec_prefix="$ac_optarg" ;;
143
144 -gas | --gas | --ga | --g)
145 # Obsolete; use --with-gas.
146 with_gas=yes ;;
147
148 -help | --help | --hel | --he)
149 # Omit some internal or obsolete options to make the list less imposing.
150 # This message is too long to be a string in the A/UX 3.1 sh.
151 cat << EOF
152Usage: configure [options] [host]
153Options: [defaults in brackets after descriptions]
154Configuration:
155 --cache-file=FILE cache test results in FILE
156 --help print this message
157 --no-create do not create output files
158 --quiet, --silent do not print \`checking...' messages
159 --version print the version of autoconf that created configure
160Directory and file names:
161 --prefix=PREFIX install architecture-independent files in PREFIX
162 [$ac_default_prefix]
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +0000163 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000164 [same as prefix]
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +0000165 --bindir=DIR user executables in DIR [EPREFIX/bin]
166 --sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
167 --libexecdir=DIR program executables in DIR [EPREFIX/libexec]
168 --datadir=DIR read-only architecture-independent data in DIR
169 [PREFIX/share]
170 --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
171 --sharedstatedir=DIR modifiable architecture-independent data in DIR
172 [PREFIX/com]
173 --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
174 --libdir=DIR object code libraries in DIR [EPREFIX/lib]
175 --includedir=DIR C header files in DIR [PREFIX/include]
176 --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
177 --infodir=DIR info documentation in DIR [PREFIX/info]
178 --mandir=DIR man documentation in DIR [PREFIX/man]
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000179 --srcdir=DIR find the sources in DIR [configure dir or ..]
180 --program-prefix=PREFIX prepend PREFIX to installed program names
181 --program-suffix=SUFFIX append SUFFIX to installed program names
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +0000182 --program-transform-name=PROGRAM
183 run sed PROGRAM on installed program names
184EOF
185 cat << EOF
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000186Host type:
187 --build=BUILD configure for building on BUILD [BUILD=HOST]
188 --host=HOST configure for HOST [guessed]
189 --target=TARGET configure for TARGET [TARGET=HOST]
190Features and packages:
191 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
192 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
193 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
194 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
195 --x-includes=DIR X include files are in DIR
196 --x-libraries=DIR X library files are in DIR
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000197EOF
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +0000198 if test -n "$ac_help"; then
199 echo "--enable and --with options recognized:$ac_help"
200 fi
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000201 exit 0 ;;
202
203 -host | --host | --hos | --ho)
204 ac_prev=host ;;
205 -host=* | --host=* | --hos=* | --ho=*)
206 host="$ac_optarg" ;;
207
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +0000208 -includedir | --includedir | --includedi | --included | --include \
209 | --includ | --inclu | --incl | --inc)
210 ac_prev=includedir ;;
211 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
212 | --includ=* | --inclu=* | --incl=* | --inc=*)
213 includedir="$ac_optarg" ;;
214
215 -infodir | --infodir | --infodi | --infod | --info | --inf)
216 ac_prev=infodir ;;
217 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
218 infodir="$ac_optarg" ;;
219
220 -libdir | --libdir | --libdi | --libd)
221 ac_prev=libdir ;;
222 -libdir=* | --libdir=* | --libdi=* | --libd=*)
223 libdir="$ac_optarg" ;;
224
225 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
226 | --libexe | --libex | --libe)
227 ac_prev=libexecdir ;;
228 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
229 | --libexe=* | --libex=* | --libe=*)
230 libexecdir="$ac_optarg" ;;
231
232 -localstatedir | --localstatedir | --localstatedi | --localstated \
233 | --localstate | --localstat | --localsta | --localst \
234 | --locals | --local | --loca | --loc | --lo)
235 ac_prev=localstatedir ;;
236 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
237 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
238 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
239 localstatedir="$ac_optarg" ;;
240
241 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
242 ac_prev=mandir ;;
243 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
244 mandir="$ac_optarg" ;;
245
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000246 -nfp | --nfp | --nf)
247 # Obsolete; use --without-fp.
248 with_fp=no ;;
249
250 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
251 | --no-cr | --no-c)
252 no_create=yes ;;
253
254 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
255 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
256 no_recursion=yes ;;
257
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +0000258 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
259 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
260 | --oldin | --oldi | --old | --ol | --o)
261 ac_prev=oldincludedir ;;
262 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
263 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
264 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
265 oldincludedir="$ac_optarg" ;;
266
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000267 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
268 ac_prev=prefix ;;
269 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
270 prefix="$ac_optarg" ;;
271
272 -program-prefix | --program-prefix | --program-prefi | --program-pref \
273 | --program-pre | --program-pr | --program-p)
274 ac_prev=program_prefix ;;
275 -program-prefix=* | --program-prefix=* | --program-prefi=* \
276 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
277 program_prefix="$ac_optarg" ;;
278
279 -program-suffix | --program-suffix | --program-suffi | --program-suff \
280 | --program-suf | --program-su | --program-s)
281 ac_prev=program_suffix ;;
282 -program-suffix=* | --program-suffix=* | --program-suffi=* \
283 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
284 program_suffix="$ac_optarg" ;;
285
286 -program-transform-name | --program-transform-name \
287 | --program-transform-nam | --program-transform-na \
288 | --program-transform-n | --program-transform- \
289 | --program-transform | --program-transfor \
290 | --program-transfo | --program-transf \
291 | --program-trans | --program-tran \
292 | --progr-tra | --program-tr | --program-t)
293 ac_prev=program_transform_name ;;
294 -program-transform-name=* | --program-transform-name=* \
295 | --program-transform-nam=* | --program-transform-na=* \
296 | --program-transform-n=* | --program-transform-=* \
297 | --program-transform=* | --program-transfor=* \
298 | --program-transfo=* | --program-transf=* \
299 | --program-trans=* | --program-tran=* \
300 | --progr-tra=* | --program-tr=* | --program-t=*)
301 program_transform_name="$ac_optarg" ;;
302
303 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
304 | -silent | --silent | --silen | --sile | --sil)
305 silent=yes ;;
306
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +0000307 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
308 ac_prev=sbindir ;;
309 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
310 | --sbi=* | --sb=*)
311 sbindir="$ac_optarg" ;;
312
313 -sharedstatedir | --sharedstatedir | --sharedstatedi \
314 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
315 | --sharedst | --shareds | --shared | --share | --shar \
316 | --sha | --sh)
317 ac_prev=sharedstatedir ;;
318 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
319 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
320 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
321 | --sha=* | --sh=*)
322 sharedstatedir="$ac_optarg" ;;
323
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000324 -site | --site | --sit)
325 ac_prev=site ;;
326 -site=* | --site=* | --sit=*)
327 site="$ac_optarg" ;;
328
329 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
330 ac_prev=srcdir ;;
331 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
332 srcdir="$ac_optarg" ;;
333
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +0000334 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
335 | --syscon | --sysco | --sysc | --sys | --sy)
336 ac_prev=sysconfdir ;;
337 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
338 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
339 sysconfdir="$ac_optarg" ;;
340
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000341 -target | --target | --targe | --targ | --tar | --ta | --t)
342 ac_prev=target ;;
343 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
344 target="$ac_optarg" ;;
345
346 -v | -verbose | --verbose | --verbos | --verbo | --verb)
347 verbose=yes ;;
348
349 -version | --version | --versio | --versi | --vers)
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +0000350 echo "configure generated by autoconf version 2.12"
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000351 exit 0 ;;
352
353 -with-* | --with-*)
354 ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
355 # Reject names that are not valid shell variable names.
356 if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
357 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
358 fi
359 ac_package=`echo $ac_package| sed 's/-/_/g'`
360 case "$ac_option" in
361 *=*) ;;
362 *) ac_optarg=yes ;;
363 esac
364 eval "with_${ac_package}='$ac_optarg'" ;;
365
366 -without-* | --without-*)
367 ac_package=`echo $ac_option|sed -e 's/-*without-//'`
368 # Reject names that are not valid shell variable names.
369 if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
370 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
371 fi
372 ac_package=`echo $ac_package| sed 's/-/_/g'`
373 eval "with_${ac_package}=no" ;;
374
375 --x)
376 # Obsolete; use --with-x.
377 with_x=yes ;;
378
379 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
380 | --x-incl | --x-inc | --x-in | --x-i)
381 ac_prev=x_includes ;;
382 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
383 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
384 x_includes="$ac_optarg" ;;
385
386 -x-libraries | --x-libraries | --x-librarie | --x-librari \
387 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
388 ac_prev=x_libraries ;;
389 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
390 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
391 x_libraries="$ac_optarg" ;;
392
393 -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
394 ;;
395
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +0000396 *)
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000397 if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
398 echo "configure: warning: $ac_option: invalid host type" 1>&2
399 fi
400 if test "x$nonopt" != xNONE; then
401 { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
402 fi
403 nonopt="$ac_option"
404 ;;
405
406 esac
407done
408
409if test -n "$ac_prev"; then
410 { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
411fi
412
413trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
414
415# File descriptor usage:
416# 0 standard input
417# 1 file creation
418# 2 errors and warnings
419# 3 some systems may open it to /dev/tty
420# 4 used on the Kubota Titan
421# 6 checking for... messages and results
422# 5 compiler messages saved in config.log
423if test "$silent" = yes; then
424 exec 6>/dev/null
425else
426 exec 6>&1
427fi
428exec 5>./config.log
429
430echo "\
431This file contains any messages produced by compilers while
432running configure, to aid debugging if configure makes a mistake.
433" 1>&5
434
435# Strip out --no-create and --no-recursion so they do not pile up.
436# Also quote any args containing shell metacharacters.
437ac_configure_args=
438for ac_arg
439do
440 case "$ac_arg" in
441 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
442 | --no-cr | --no-c) ;;
443 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
444 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
445 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
446 ac_configure_args="$ac_configure_args '$ac_arg'" ;;
447 *) ac_configure_args="$ac_configure_args $ac_arg" ;;
448 esac
449done
450
451# NLS nuisances.
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +0000452# Only set these to C if already set. These must not be set unconditionally
453# because not all systems understand e.g. LANG=C (notably SCO).
454# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
455# Non-C LC_CTYPE values break the ctype check.
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000456if test "${LANG+set}" = set; then LANG=C; export LANG; fi
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +0000457if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
458if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
459if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000460
461# confdefs.h avoids OS command line length limits that DEFS can exceed.
462rm -rf conftest* confdefs.h
463# AIX cpp loses on an empty file, so make sure it contains at least a newline.
464echo > confdefs.h
465
466# A filename unique to this package, relative to the directory that
467# configure is in, which we can look for to find out if srcdir is correct.
468ac_unique_file=controls/edit.c
469
470# Find the source files, if location was not specified.
471if test -z "$srcdir"; then
472 ac_srcdir_defaulted=yes
473 # Try the directory containing this script, then its parent.
474 ac_prog=$0
475 ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
476 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
477 srcdir=$ac_confdir
478 if test ! -r $srcdir/$ac_unique_file; then
479 srcdir=..
480 fi
481else
482 ac_srcdir_defaulted=no
483fi
484if test ! -r $srcdir/$ac_unique_file; then
485 if test "$ac_srcdir_defaulted" = yes; then
486 { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
487 else
488 { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
489 fi
490fi
491srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
492
493# Prefer explicitly selected file to automatically selected ones.
494if test -z "$CONFIG_SITE"; then
495 if test "x$prefix" != xNONE; then
496 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
497 else
498 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
499 fi
500fi
501for ac_site_file in $CONFIG_SITE; do
502 if test -r "$ac_site_file"; then
503 echo "loading site script $ac_site_file"
504 . "$ac_site_file"
505 fi
506done
507
508if test -r "$cache_file"; then
509 echo "loading cache $cache_file"
510 . $cache_file
511else
512 echo "creating cache $cache_file"
513 > $cache_file
514fi
515
516ac_ext=c
517# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
Alexandre Julliardb817f4f1996-03-14 18:08:34 +0000518ac_cpp='$CPP $CPPFLAGS'
519ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
520ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +0000521cross_compiling=$ac_cv_prog_cc_cross
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000522
523if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
524 # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
525 if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
526 ac_n= ac_c='
527' ac_t=' '
528 else
529 ac_n=-n ac_c= ac_t=
530 fi
531else
532 ac_n= ac_c='\c' ac_t=
533fi
534
535
Alexandre Julliard18f92e71996-07-17 20:02:21 +0000536
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +0000537ac_aux_dir=
538for ac_dir in tools $srcdir/tools; do
539 if test -f $ac_dir/install-sh; then
540 ac_aux_dir=$ac_dir
541 ac_install_sh="$ac_aux_dir/install-sh -c"
542 break
543 elif test -f $ac_dir/install.sh; then
544 ac_aux_dir=$ac_dir
545 ac_install_sh="$ac_aux_dir/install.sh -c"
546 break
547 fi
548done
549if test -z "$ac_aux_dir"; then
550 { echo "configure: error: can not find install-sh or install.sh in tools $srcdir/tools" 1>&2; exit 1; }
551fi
552ac_config_guess=$ac_aux_dir/config.guess
553ac_config_sub=$ac_aux_dir/config.sub
554ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
555
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000556
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000557# We want these before the checks, so the checks can modify their values.
Alexandre Julliard02e90081998-01-04 17:49:09 +0000558LIBS="$LIBS -lm"
Alexandre Julliardc6c09441997-01-12 18:32:19 +0000559test -z "$PROGEXT" && PROGEXT=""
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000560
Alexandre Julliardff8331e1995-09-18 11:19:54 +0000561
Alexandre Julliarda0b2b1d1997-11-16 17:38:29 +0000562MAIN_TARGET=emu
563LIB_TARGET=libwine.a
Todd Vierling8beb15a1998-12-18 17:30:52 +0000564ALT_LINK="-L\$(TOPOBJDIR) -lwine"
Alexandre Julliardf90efa91998-06-14 15:24:15 +0000565TRACE_MSGS=yes # the TRACE() macro
566DEBUG_MSGS=yes # the TRACE(), WARN(), and FIXME() macros.
Alexandre Julliarda0b2b1d1997-11-16 17:38:29 +0000567
568# Check whether --enable-emulator or --disable-emulator was given.
569if test "${enable_emulator+set}" = set; then
570 enableval="$enable_emulator"
571 if test "$enableval" = "no"; then MAIN_TARGET="lib"; fi
Alexandre Julliardff8331e1995-09-18 11:19:54 +0000572fi
573
574
Alexandre Julliarda0b2b1d1997-11-16 17:38:29 +0000575# Check whether --enable-dll or --disable-dll was given.
576if test "${enable_dll+set}" = set; then
577 enableval="$enable_dll"
578 if test "$enableval" = "no"; then : ; else LIB_TARGET="libwine.so.1.0"; fi
Alexandre Julliard7e56f681996-01-31 19:02:28 +0000579fi
580
581
Alexandre Julliard642d3131998-07-12 19:29:36 +0000582# Check whether --enable-lib or --disable-lib was given.
583if test "${enable_lib+set}" = set; then
584 enableval="$enable_lib"
Ove Kaaven11e1a5e1998-11-06 10:01:45 +0000585 if test "$enableval" = "no"; then ALT_LINK="\$(LIBOBJS) \$(X11OBJS)"; LIB_TARGET=""; fi
Alexandre Julliard642d3131998-07-12 19:29:36 +0000586fi
587
588
Alexandre Julliardff8331e1995-09-18 11:19:54 +0000589
Alexandre Julliardf90efa91998-06-14 15:24:15 +0000590# Check whether --enable-debug or --disable-debug was given.
591if test "${enable_debug+set}" = set; then
592 enableval="$enable_debug"
593 if test "$enableval" = "no"; then DEBUG_MSGS="no"; fi
594fi
595
596
597# Check whether --enable-trace or --disable-trace was given.
598if test "${enable_trace+set}" = set; then
599 enableval="$enable_trace"
600 if test "$enableval" = "no"; then TRACE_MSGS="no"; fi
601fi
602
603
Alexandre Julliarda11d7b11998-03-01 20:05:02 +0000604# Check whether --with-reentrant-x or --without-reentrant-x was given.
605if test "${with_reentrant_x+set}" = set; then
606 withval="$with_reentrant_x"
607 :
608fi
609
610
Alexandre Julliardb7258be1995-09-01 15:57:28 +0000611
Alexandre Julliardb7258be1995-09-01 15:57:28 +0000612
613
Alexandre Julliardff8331e1995-09-18 11:19:54 +0000614
Uwe Bonnes2a4707a1998-10-11 14:57:08 +0000615
Alexandre Julliardf90efa91998-06-14 15:24:15 +0000616if test "$DEBUG_MSGS" = "no"
617then
618 cat >> confdefs.h <<\EOF
619#define NO_DEBUG_MSGS 1
620EOF
621
622 cat >> confdefs.h <<\EOF
623#define NO_TRACE_MSGS 1
624EOF
625
626else
627 if test "$TRACE_MSGS" = "no"
628 then
629 cat >> confdefs.h <<\EOF
630#define NO_TRACE_MSGS 1
631EOF
632
633 fi
634fi
635
Alexandre Julliarda0b2b1d1997-11-16 17:38:29 +0000636
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000637echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
Joseph Praneviche884f9c1999-01-03 16:14:34 +0000638echo "configure:639: checking whether ${MAKE-make} sets \${MAKE}" >&5
Alexandre Julliardda0cfb31996-12-01 17:17:47 +0000639set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000640if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
641 echo $ac_n "(cached) $ac_c" 1>&6
642else
643 cat > conftestmake <<\EOF
644all:
645 @echo 'ac_maketemp="${MAKE}"'
646EOF
647# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
648eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
649if test -n "$ac_maketemp"; then
650 eval ac_cv_prog_make_${ac_make}_set=yes
651else
652 eval ac_cv_prog_make_${ac_make}_set=no
653fi
654rm -f conftestmake
655fi
656if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
657 echo "$ac_t""yes" 1>&6
658 SET_MAKE=
659else
660 echo "$ac_t""no" 1>&6
661 SET_MAKE="MAKE=${MAKE-make}"
662fi
663
664# Extract the first word of "gcc", so it can be a program name with args.
665set dummy gcc; ac_word=$2
666echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
Joseph Praneviche884f9c1999-01-03 16:14:34 +0000667echo "configure:668: checking for $ac_word" >&5
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000668if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
669 echo $ac_n "(cached) $ac_c" 1>&6
670else
671 if test -n "$CC"; then
672 ac_cv_prog_CC="$CC" # Let the user override the test.
673else
674 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
675 for ac_dir in $PATH; do
676 test -z "$ac_dir" && ac_dir=.
677 if test -f $ac_dir/$ac_word; then
678 ac_cv_prog_CC="gcc"
679 break
680 fi
681 done
682 IFS="$ac_save_ifs"
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000683fi
684fi
685CC="$ac_cv_prog_CC"
686if test -n "$CC"; then
687 echo "$ac_t""$CC" 1>&6
688else
689 echo "$ac_t""no" 1>&6
690fi
691
Alexandre Julliardb817f4f1996-03-14 18:08:34 +0000692if test -z "$CC"; then
693 # Extract the first word of "cc", so it can be a program name with args.
694set dummy cc; ac_word=$2
695echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
Joseph Praneviche884f9c1999-01-03 16:14:34 +0000696echo "configure:697: checking for $ac_word" >&5
Alexandre Julliardb817f4f1996-03-14 18:08:34 +0000697if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
698 echo $ac_n "(cached) $ac_c" 1>&6
699else
700 if test -n "$CC"; then
701 ac_cv_prog_CC="$CC" # Let the user override the test.
702else
703 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
704 ac_prog_rejected=no
705 for ac_dir in $PATH; do
706 test -z "$ac_dir" && ac_dir=.
707 if test -f $ac_dir/$ac_word; then
708 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
709 ac_prog_rejected=yes
710 continue
711 fi
712 ac_cv_prog_CC="cc"
713 break
714 fi
715 done
716 IFS="$ac_save_ifs"
717if test $ac_prog_rejected = yes; then
718 # We found a bogon in the path, so make sure we never use it.
719 set dummy $ac_cv_prog_CC
720 shift
721 if test $# -gt 0; then
722 # We chose a different compiler from the bogus one.
723 # However, it has the same basename, so the bogon will be chosen
724 # first if we set CC to just the basename; use the full file name.
725 shift
726 set dummy "$ac_dir/$ac_word" "$@"
727 shift
728 ac_cv_prog_CC="$@"
729 fi
730fi
731fi
732fi
733CC="$ac_cv_prog_CC"
734if test -n "$CC"; then
735 echo "$ac_t""$CC" 1>&6
736else
737 echo "$ac_t""no" 1>&6
738fi
739
740 test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
741fi
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000742
Alexandre Julliardda0cfb31996-12-01 17:17:47 +0000743echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
Joseph Praneviche884f9c1999-01-03 16:14:34 +0000744echo "configure:745: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
Alexandre Julliardda0cfb31996-12-01 17:17:47 +0000745
746ac_ext=c
747# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
748ac_cpp='$CPP $CPPFLAGS'
749ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
750ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +0000751cross_compiling=$ac_cv_prog_cc_cross
Alexandre Julliardda0cfb31996-12-01 17:17:47 +0000752
753cat > conftest.$ac_ext <<EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +0000754#line 755 "configure"
Alexandre Julliardda0cfb31996-12-01 17:17:47 +0000755#include "confdefs.h"
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +0000756main(){return(0);}
Alexandre Julliardda0cfb31996-12-01 17:17:47 +0000757EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +0000758if { (eval echo configure:759: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Alexandre Julliardda0cfb31996-12-01 17:17:47 +0000759 ac_cv_prog_cc_works=yes
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +0000760 # If we can't run a trivial program, we are probably using a cross compiler.
761 if (./conftest; exit) 2>/dev/null; then
762 ac_cv_prog_cc_cross=no
763 else
764 ac_cv_prog_cc_cross=yes
765 fi
Alexandre Julliardda0cfb31996-12-01 17:17:47 +0000766else
767 echo "configure: failed program was:" >&5
768 cat conftest.$ac_ext >&5
Alexandre Julliardda0cfb31996-12-01 17:17:47 +0000769 ac_cv_prog_cc_works=no
770fi
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +0000771rm -fr conftest*
Alexandre Julliardda0cfb31996-12-01 17:17:47 +0000772
773echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
774if test $ac_cv_prog_cc_works = no; then
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +0000775 { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
Alexandre Julliardda0cfb31996-12-01 17:17:47 +0000776fi
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +0000777echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
Joseph Praneviche884f9c1999-01-03 16:14:34 +0000778echo "configure:779: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +0000779echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
780cross_compiling=$ac_cv_prog_cc_cross
Alexandre Julliardda0cfb31996-12-01 17:17:47 +0000781
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000782echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
Joseph Praneviche884f9c1999-01-03 16:14:34 +0000783echo "configure:784: checking whether we are using GNU C" >&5
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000784if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
785 echo $ac_n "(cached) $ac_c" 1>&6
786else
787 cat > conftest.c <<EOF
788#ifdef __GNUC__
789 yes;
790#endif
791EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +0000792if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:793: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000793 ac_cv_prog_gcc=yes
794else
795 ac_cv_prog_gcc=no
796fi
797fi
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +0000798
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000799echo "$ac_t""$ac_cv_prog_gcc" 1>&6
Alexandre Julliardda0cfb31996-12-01 17:17:47 +0000800
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000801if test $ac_cv_prog_gcc = yes; then
802 GCC=yes
Alexandre Julliardda0cfb31996-12-01 17:17:47 +0000803 ac_test_CFLAGS="${CFLAGS+set}"
804 ac_save_CFLAGS="$CFLAGS"
805 CFLAGS=
806 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
Joseph Praneviche884f9c1999-01-03 16:14:34 +0000807echo "configure:808: checking whether ${CC-cc} accepts -g" >&5
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +0000808if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000809 echo $ac_n "(cached) $ac_c" 1>&6
810else
811 echo 'void f(){}' > conftest.c
812if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +0000813 ac_cv_prog_cc_g=yes
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000814else
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +0000815 ac_cv_prog_cc_g=no
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000816fi
817rm -f conftest*
818
819fi
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +0000820
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +0000821echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
Alexandre Julliardda0cfb31996-12-01 17:17:47 +0000822 if test "$ac_test_CFLAGS" = set; then
823 CFLAGS="$ac_save_CFLAGS"
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +0000824 elif test $ac_cv_prog_cc_g = yes; then
Alexandre Julliardda0cfb31996-12-01 17:17:47 +0000825 CFLAGS="-g -O2"
826 else
827 CFLAGS="-O2"
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000828 fi
829else
830 GCC=
831 test "${CFLAGS+set}" = set || CFLAGS="-g"
832fi
833
834echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
Joseph Praneviche884f9c1999-01-03 16:14:34 +0000835echo "configure:836: checking how to run the C preprocessor" >&5
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000836# On Suns, sometimes $CPP names a directory.
837if test -n "$CPP" && test -d "$CPP"; then
838 CPP=
839fi
840if test -z "$CPP"; then
841if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
842 echo $ac_n "(cached) $ac_c" 1>&6
843else
844 # This must be in double quotes, not single quotes, because CPP may get
845 # substituted into the Makefile and "${CC-cc}" will confuse make.
846 CPP="${CC-cc} -E"
847 # On the NeXT, cc -E runs the code through the compiler's parser,
848 # not just through cpp.
849 cat > conftest.$ac_ext <<EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +0000850#line 851 "configure"
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000851#include "confdefs.h"
852#include <assert.h>
853Syntax Error
854EOF
Alexandre Julliardb817f4f1996-03-14 18:08:34 +0000855ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
Joseph Praneviche884f9c1999-01-03 16:14:34 +0000856{ (eval echo configure:857: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000857ac_err=`grep -v '^ *+' conftest.out`
858if test -z "$ac_err"; then
859 :
860else
861 echo "$ac_err" >&5
Alexandre Julliardda0cfb31996-12-01 17:17:47 +0000862 echo "configure: failed program was:" >&5
863 cat conftest.$ac_ext >&5
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000864 rm -rf conftest*
865 CPP="${CC-cc} -E -traditional-cpp"
866 cat > conftest.$ac_ext <<EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +0000867#line 868 "configure"
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000868#include "confdefs.h"
869#include <assert.h>
870Syntax Error
871EOF
Alexandre Julliardb817f4f1996-03-14 18:08:34 +0000872ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
Joseph Praneviche884f9c1999-01-03 16:14:34 +0000873{ (eval echo configure:874: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000874ac_err=`grep -v '^ *+' conftest.out`
875if test -z "$ac_err"; then
876 :
877else
878 echo "$ac_err" >&5
Alexandre Julliardda0cfb31996-12-01 17:17:47 +0000879 echo "configure: failed program was:" >&5
880 cat conftest.$ac_ext >&5
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000881 rm -rf conftest*
882 CPP=/lib/cpp
883fi
884rm -f conftest*
885fi
886rm -f conftest*
887 ac_cv_prog_CPP="$CPP"
888fi
889 CPP="$ac_cv_prog_CPP"
890else
891 ac_cv_prog_CPP="$CPP"
892fi
893echo "$ac_t""$CPP" 1>&6
894
895# If we find X, set shell vars x_includes and x_libraries to the
896# paths, otherwise set no_x=yes.
897# Uses ac_ vars as temps to allow command line to override cache and checks.
898# --without-x overrides everything else, but does not touch the cache.
899echo $ac_n "checking for X""... $ac_c" 1>&6
Joseph Praneviche884f9c1999-01-03 16:14:34 +0000900echo "configure:901: checking for X" >&5
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000901
902# Check whether --with-x or --without-x was given.
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +0000903if test "${with_x+set}" = set; then
904 withval="$with_x"
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000905 :
906fi
907
Alexandre Julliardb817f4f1996-03-14 18:08:34 +0000908# $have_x is `yes', `no', `disabled', or empty when we do not yet know.
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000909if test "x$with_x" = xno; then
Alexandre Julliardb817f4f1996-03-14 18:08:34 +0000910 # The user explicitly disabled X.
911 have_x=disabled
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000912else
913 if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
Alexandre Julliardb817f4f1996-03-14 18:08:34 +0000914 # Both variables are already set.
915 have_x=yes
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000916 else
Alexandre Julliardb817f4f1996-03-14 18:08:34 +0000917if eval "test \"`echo '$''{'ac_cv_have_x'+set}'`\" = set"; then
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000918 echo $ac_n "(cached) $ac_c" 1>&6
919else
920 # One or both of the vars are not set, and there is no cached value.
Alexandre Julliardb817f4f1996-03-14 18:08:34 +0000921ac_x_includes=NO ac_x_libraries=NO
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000922rm -fr conftestdir
923if mkdir conftestdir; then
924 cd conftestdir
925 # Make sure to not put "make" in the Imakefile rules, since we grep it out.
926 cat > Imakefile <<'EOF'
927acfindx:
928 @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
929EOF
930 if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000931 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +0000932 eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000933 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
934 for ac_extension in a so sl; do
935 if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
936 test -f $ac_im_libdir/libX11.$ac_extension; then
937 ac_im_usrlibdir=$ac_im_libdir; break
938 fi
939 done
Alexandre Julliardda0cfb31996-12-01 17:17:47 +0000940 # Screen out bogus values from the imake configuration. They are
941 # bogus both because they are the default anyway, and because
942 # using them would break gcc on systems where it needs fixed includes.
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000943 case "$ac_im_incroot" in
944 /usr/include) ;;
945 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes="$ac_im_incroot" ;;
946 esac
947 case "$ac_im_usrlibdir" in
948 /usr/lib | /lib) ;;
949 *) test -d "$ac_im_usrlibdir" && ac_x_libraries="$ac_im_usrlibdir" ;;
950 esac
951 fi
952 cd ..
953 rm -fr conftestdir
954fi
955
Alexandre Julliardb817f4f1996-03-14 18:08:34 +0000956if test "$ac_x_includes" = NO; then
957 # Guess where to find include files, by looking for this one X11 .h file.
958 test -z "$x_direct_test_include" && x_direct_test_include=X11/Intrinsic.h
959
960 # First, try using that file with no special directory specified.
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000961cat > conftest.$ac_ext <<EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +0000962#line 963 "configure"
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000963#include "confdefs.h"
964#include <$x_direct_test_include>
965EOF
Alexandre Julliardb817f4f1996-03-14 18:08:34 +0000966ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
Joseph Praneviche884f9c1999-01-03 16:14:34 +0000967{ (eval echo configure:968: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000968ac_err=`grep -v '^ *+' conftest.out`
969if test -z "$ac_err"; then
970 rm -rf conftest*
Alexandre Julliardb817f4f1996-03-14 18:08:34 +0000971 # We can compile using X headers with no special include directory.
972ac_x_includes=
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000973else
974 echo "$ac_err" >&5
Alexandre Julliardda0cfb31996-12-01 17:17:47 +0000975 echo "configure: failed program was:" >&5
976 cat conftest.$ac_ext >&5
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000977 rm -rf conftest*
Alexandre Julliardb817f4f1996-03-14 18:08:34 +0000978 # Look for the header file in a standard set of common directories.
Alexandre Julliardda0cfb31996-12-01 17:17:47 +0000979# Check X11 before X11Rn because it is often a symlink to the current release.
Alexandre Julliardb817f4f1996-03-14 18:08:34 +0000980 for ac_dir in \
Alexandre Julliardda0cfb31996-12-01 17:17:47 +0000981 /usr/X11/include \
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000982 /usr/X11R6/include \
983 /usr/X11R5/include \
984 /usr/X11R4/include \
985 \
Alexandre Julliardda0cfb31996-12-01 17:17:47 +0000986 /usr/include/X11 \
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000987 /usr/include/X11R6 \
988 /usr/include/X11R5 \
989 /usr/include/X11R4 \
990 \
Alexandre Julliardda0cfb31996-12-01 17:17:47 +0000991 /usr/local/X11/include \
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000992 /usr/local/X11R6/include \
993 /usr/local/X11R5/include \
994 /usr/local/X11R4/include \
995 \
Alexandre Julliardda0cfb31996-12-01 17:17:47 +0000996 /usr/local/include/X11 \
Alexandre Julliarde2991ea1995-07-29 13:09:43 +0000997 /usr/local/include/X11R6 \
998 /usr/local/include/X11R5 \
999 /usr/local/include/X11R4 \
1000 \
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001001 /usr/X386/include \
1002 /usr/x386/include \
1003 /usr/XFree86/include/X11 \
1004 \
1005 /usr/include \
1006 /usr/local/include \
1007 /usr/unsupported/include \
1008 /usr/athena/include \
1009 /usr/local/x11r5/include \
1010 /usr/lpp/Xamples/include \
1011 \
1012 /usr/openwin/include \
1013 /usr/openwin/share/include \
1014 ; \
1015 do
1016 if test -r "$ac_dir/$x_direct_test_include"; then
Alexandre Julliardb817f4f1996-03-14 18:08:34 +00001017 ac_x_includes=$ac_dir
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001018 break
1019 fi
1020 done
1021fi
1022rm -f conftest*
Alexandre Julliardb817f4f1996-03-14 18:08:34 +00001023fi # $ac_x_includes = NO
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001024
Alexandre Julliardb817f4f1996-03-14 18:08:34 +00001025if test "$ac_x_libraries" = NO; then
1026 # Check for the libraries.
1027
1028 test -z "$x_direct_test_library" && x_direct_test_library=Xt
1029 test -z "$x_direct_test_function" && x_direct_test_function=XtMalloc
1030
1031 # See if we find them without any special options.
1032 # Don't add to $LIBS permanently.
1033 ac_save_LIBS="$LIBS"
1034 LIBS="-l$x_direct_test_library $LIBS"
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001035cat > conftest.$ac_ext <<EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001036#line 1037 "configure"
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001037#include "confdefs.h"
1038
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001039int main() {
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001040${x_direct_test_function}()
1041; return 0; }
1042EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001043if { (eval echo configure:1044: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001044 rm -rf conftest*
Alexandre Julliardb817f4f1996-03-14 18:08:34 +00001045 LIBS="$ac_save_LIBS"
1046# We can link X programs with no special library path.
1047ac_x_libraries=
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001048else
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001049 echo "configure: failed program was:" >&5
1050 cat conftest.$ac_ext >&5
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001051 rm -rf conftest*
1052 LIBS="$ac_save_LIBS"
1053# First see if replacing the include by lib works.
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001054# Check X11 before X11Rn because it is often a symlink to the current release.
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001055for ac_dir in `echo "$ac_x_includes" | sed s/include/lib/` \
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001056 /usr/X11/lib \
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001057 /usr/X11R6/lib \
1058 /usr/X11R5/lib \
1059 /usr/X11R4/lib \
1060 \
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001061 /usr/lib/X11 \
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001062 /usr/lib/X11R6 \
1063 /usr/lib/X11R5 \
1064 /usr/lib/X11R4 \
1065 \
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001066 /usr/local/X11/lib \
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001067 /usr/local/X11R6/lib \
1068 /usr/local/X11R5/lib \
1069 /usr/local/X11R4/lib \
1070 \
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001071 /usr/local/lib/X11 \
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001072 /usr/local/lib/X11R6 \
1073 /usr/local/lib/X11R5 \
1074 /usr/local/lib/X11R4 \
1075 \
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001076 /usr/X386/lib \
1077 /usr/x386/lib \
1078 /usr/XFree86/lib/X11 \
1079 \
1080 /usr/lib \
1081 /usr/local/lib \
1082 /usr/unsupported/lib \
1083 /usr/athena/lib \
1084 /usr/local/x11r5/lib \
1085 /usr/lpp/Xamples/lib \
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001086 /lib/usr/lib/X11 \
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001087 \
1088 /usr/openwin/lib \
1089 /usr/openwin/share/lib \
1090 ; \
1091do
1092 for ac_extension in a so sl; do
1093 if test -r $ac_dir/lib${x_direct_test_library}.$ac_extension; then
Alexandre Julliardb817f4f1996-03-14 18:08:34 +00001094 ac_x_libraries=$ac_dir
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001095 break 2
1096 fi
1097 done
1098done
1099fi
1100rm -f conftest*
Alexandre Julliardb817f4f1996-03-14 18:08:34 +00001101fi # $ac_x_libraries = NO
1102
1103if test "$ac_x_includes" = NO || test "$ac_x_libraries" = NO; then
1104 # Didn't find X anywhere. Cache the known absence of X.
1105 ac_cv_have_x="have_x=no"
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001106else
Alexandre Julliardb817f4f1996-03-14 18:08:34 +00001107 # Record where we found X for the cache.
1108 ac_cv_have_x="have_x=yes \
1109 ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001110fi
1111fi
1112 fi
Alexandre Julliardb817f4f1996-03-14 18:08:34 +00001113 eval "$ac_cv_have_x"
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001114fi # $with_x != no
1115
Alexandre Julliardb817f4f1996-03-14 18:08:34 +00001116if test "$have_x" != yes; then
1117 echo "$ac_t""$have_x" 1>&6
1118 no_x=yes
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001119else
Alexandre Julliardb817f4f1996-03-14 18:08:34 +00001120 # If each of the values was on the command line, it overrides each guess.
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001121 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
1122 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
Alexandre Julliardb817f4f1996-03-14 18:08:34 +00001123 # Update the cache value to reflect the command line values.
1124 ac_cv_have_x="have_x=yes \
1125 ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001126 echo "$ac_t""libraries $x_libraries, headers $x_includes" 1>&6
1127fi
1128
Alexandre Julliardb817f4f1996-03-14 18:08:34 +00001129if test "$no_x" = yes; then
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001130 # Not all programs may use this symbol, but it does not hurt to define it.
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001131 cat >> confdefs.h <<\EOF
1132#define X_DISPLAY_MISSING 1
1133EOF
1134
1135 X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS=
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001136else
1137 if test -n "$x_includes"; then
1138 X_CFLAGS="$X_CFLAGS -I$x_includes"
1139 fi
1140
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001141 # It would also be nice to do this for all -L options, not just this one.
1142 if test -n "$x_libraries"; then
1143 X_LIBS="$X_LIBS -L$x_libraries"
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001144 # For Solaris; some versions of Sun CC require a space after -R and
1145 # others require no space. Words are not sufficient . . . .
1146 case "`(uname -sr) 2>/dev/null`" in
1147 "SunOS 5"*)
1148 echo $ac_n "checking whether -R must be followed by a space""... $ac_c" 1>&6
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001149echo "configure:1150: checking whether -R must be followed by a space" >&5
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001150 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS -R$x_libraries"
1151 cat > conftest.$ac_ext <<EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001152#line 1153 "configure"
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001153#include "confdefs.h"
1154
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001155int main() {
1156
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001157; return 0; }
1158EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001159if { (eval echo configure:1160: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001160 rm -rf conftest*
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001161 ac_R_nospace=yes
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001162else
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001163 echo "configure: failed program was:" >&5
1164 cat conftest.$ac_ext >&5
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001165 rm -rf conftest*
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001166 ac_R_nospace=no
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001167fi
1168rm -f conftest*
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001169 if test $ac_R_nospace = yes; then
1170 echo "$ac_t""no" 1>&6
1171 X_LIBS="$X_LIBS -R$x_libraries"
1172 else
1173 LIBS="$ac_xsave_LIBS -R $x_libraries"
1174 cat > conftest.$ac_ext <<EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001175#line 1176 "configure"
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001176#include "confdefs.h"
1177
1178int main() {
1179
1180; return 0; }
1181EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001182if { (eval echo configure:1183: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001183 rm -rf conftest*
1184 ac_R_space=yes
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001185else
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001186 echo "configure: failed program was:" >&5
1187 cat conftest.$ac_ext >&5
1188 rm -rf conftest*
1189 ac_R_space=no
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001190fi
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001191rm -f conftest*
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001192 if test $ac_R_space = yes; then
1193 echo "$ac_t""yes" 1>&6
1194 X_LIBS="$X_LIBS -R $x_libraries"
1195 else
1196 echo "$ac_t""neither works" 1>&6
1197 fi
1198 fi
1199 LIBS="$ac_xsave_LIBS"
1200 esac
1201 fi
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001202
1203 # Check for system-dependent libraries X programs must link with.
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001204 # Do this before checking for the system-independent R6 libraries
1205 # (-lICE), since we may need -lsocket or whatever for X linking.
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001206
1207 if test "$ISC" = yes; then
1208 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
1209 else
1210 # Martyn.Johnson@cl.cam.ac.uk says this is needed for Ultrix, if the X
1211 # libraries were built with DECnet support. And karl@cs.umb.edu says
1212 # the Alpha needs dnet_stub (dnet does not exist).
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001213 echo $ac_n "checking for dnet_ntoa in -ldnet""... $ac_c" 1>&6
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001214echo "configure:1215: checking for dnet_ntoa in -ldnet" >&5
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001215ac_lib_var=`echo dnet'_'dnet_ntoa | sed 'y%./+-%__p_%'`
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00001216if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001217 echo $ac_n "(cached) $ac_c" 1>&6
1218else
1219 ac_save_LIBS="$LIBS"
1220LIBS="-ldnet $LIBS"
1221cat > conftest.$ac_ext <<EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001222#line 1223 "configure"
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001223#include "confdefs.h"
Alexandre Julliard59730ae1996-03-24 16:20:51 +00001224/* Override any gcc2 internal prototype to avoid an error. */
Alexandre Julliarde2bfa4c1996-05-16 18:21:06 +00001225/* We use char because int might match the return type of a gcc2
1226 builtin and then its argument prototype would still apply. */
Alexandre Julliard59730ae1996-03-24 16:20:51 +00001227char dnet_ntoa();
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001228
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001229int main() {
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001230dnet_ntoa()
1231; return 0; }
1232EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001233if { (eval echo configure:1234: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001234 rm -rf conftest*
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00001235 eval "ac_cv_lib_$ac_lib_var=yes"
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001236else
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001237 echo "configure: failed program was:" >&5
1238 cat conftest.$ac_ext >&5
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001239 rm -rf conftest*
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00001240 eval "ac_cv_lib_$ac_lib_var=no"
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001241fi
1242rm -f conftest*
1243LIBS="$ac_save_LIBS"
1244
1245fi
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00001246if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001247 echo "$ac_t""yes" 1>&6
1248 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
1249else
1250 echo "$ac_t""no" 1>&6
1251fi
1252
Alexandre Julliard59730ae1996-03-24 16:20:51 +00001253 if test $ac_cv_lib_dnet_dnet_ntoa = no; then
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001254 echo $ac_n "checking for dnet_ntoa in -ldnet_stub""... $ac_c" 1>&6
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001255echo "configure:1256: checking for dnet_ntoa in -ldnet_stub" >&5
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001256ac_lib_var=`echo dnet_stub'_'dnet_ntoa | sed 'y%./+-%__p_%'`
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00001257if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001258 echo $ac_n "(cached) $ac_c" 1>&6
1259else
1260 ac_save_LIBS="$LIBS"
1261LIBS="-ldnet_stub $LIBS"
1262cat > conftest.$ac_ext <<EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001263#line 1264 "configure"
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001264#include "confdefs.h"
Alexandre Julliard59730ae1996-03-24 16:20:51 +00001265/* Override any gcc2 internal prototype to avoid an error. */
Alexandre Julliarde2bfa4c1996-05-16 18:21:06 +00001266/* We use char because int might match the return type of a gcc2
1267 builtin and then its argument prototype would still apply. */
Alexandre Julliard59730ae1996-03-24 16:20:51 +00001268char dnet_ntoa();
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001269
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001270int main() {
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001271dnet_ntoa()
1272; return 0; }
1273EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001274if { (eval echo configure:1275: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001275 rm -rf conftest*
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00001276 eval "ac_cv_lib_$ac_lib_var=yes"
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001277else
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001278 echo "configure: failed program was:" >&5
1279 cat conftest.$ac_ext >&5
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001280 rm -rf conftest*
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00001281 eval "ac_cv_lib_$ac_lib_var=no"
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001282fi
1283rm -f conftest*
1284LIBS="$ac_save_LIBS"
1285
1286fi
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00001287if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001288 echo "$ac_t""yes" 1>&6
1289 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
1290else
1291 echo "$ac_t""no" 1>&6
1292fi
1293
1294 fi
1295
1296 # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
1297 # to get the SysV transport functions.
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001298 # chad@anasazi.com says the Pyramis MIS-ES running DC/OSx (SVR4)
1299 # needs -lnsl.
1300 # The nsl library prevents programs from opening the X display
1301 # on Irix 5.2, according to dickey@clark.net.
1302 echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001303echo "configure:1304: checking for gethostbyname" >&5
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001304if eval "test \"`echo '$''{'ac_cv_func_gethostbyname'+set}'`\" = set"; then
1305 echo $ac_n "(cached) $ac_c" 1>&6
1306else
1307 cat > conftest.$ac_ext <<EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001308#line 1309 "configure"
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001309#include "confdefs.h"
1310/* System header to define __stub macros and hopefully few prototypes,
1311 which can conflict with char gethostbyname(); below. */
1312#include <assert.h>
1313/* Override any gcc2 internal prototype to avoid an error. */
1314/* We use char because int might match the return type of a gcc2
1315 builtin and then its argument prototype would still apply. */
1316char gethostbyname();
1317
1318int main() {
1319
1320/* The GNU C library defines this for functions which it implements
1321 to always fail with ENOSYS. Some functions are actually named
1322 something starting with __ and the normal name is an alias. */
1323#if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
1324choke me
1325#else
1326gethostbyname();
1327#endif
1328
1329; return 0; }
1330EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001331if { (eval echo configure:1332: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001332 rm -rf conftest*
1333 eval "ac_cv_func_gethostbyname=yes"
1334else
1335 echo "configure: failed program was:" >&5
1336 cat conftest.$ac_ext >&5
1337 rm -rf conftest*
1338 eval "ac_cv_func_gethostbyname=no"
1339fi
1340rm -f conftest*
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001341fi
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +00001342
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001343if eval "test \"`echo '$ac_cv_func_'gethostbyname`\" = yes"; then
1344 echo "$ac_t""yes" 1>&6
1345 :
1346else
1347 echo "$ac_t""no" 1>&6
1348fi
1349
1350 if test $ac_cv_func_gethostbyname = no; then
1351 echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001352echo "configure:1353: checking for gethostbyname in -lnsl" >&5
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001353ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'`
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00001354if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001355 echo $ac_n "(cached) $ac_c" 1>&6
1356else
1357 ac_save_LIBS="$LIBS"
1358LIBS="-lnsl $LIBS"
1359cat > conftest.$ac_ext <<EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001360#line 1361 "configure"
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001361#include "confdefs.h"
Alexandre Julliard59730ae1996-03-24 16:20:51 +00001362/* Override any gcc2 internal prototype to avoid an error. */
Alexandre Julliarde2bfa4c1996-05-16 18:21:06 +00001363/* We use char because int might match the return type of a gcc2
1364 builtin and then its argument prototype would still apply. */
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001365char gethostbyname();
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001366
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001367int main() {
1368gethostbyname()
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001369; return 0; }
1370EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001371if { (eval echo configure:1372: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001372 rm -rf conftest*
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00001373 eval "ac_cv_lib_$ac_lib_var=yes"
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001374else
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001375 echo "configure: failed program was:" >&5
1376 cat conftest.$ac_ext >&5
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001377 rm -rf conftest*
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00001378 eval "ac_cv_lib_$ac_lib_var=no"
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001379fi
1380rm -f conftest*
1381LIBS="$ac_save_LIBS"
1382
1383fi
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00001384if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001385 echo "$ac_t""yes" 1>&6
1386 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
1387else
1388 echo "$ac_t""no" 1>&6
1389fi
1390
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001391 fi
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001392
1393 # lieder@skyler.mavd.honeywell.com says without -lsocket,
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001394 # socket/setsockopt and other routines are undefined under SCO ODT
1395 # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary
1396 # on later versions), says simon@lia.di.epfl.ch: it contains
1397 # gethostby* variants that don't use the nameserver (or something).
1398 # -lsocket must be given before -lnsl if both are needed.
1399 # We assume that if connect needs -lnsl, so does gethostbyname.
1400 echo $ac_n "checking for connect""... $ac_c" 1>&6
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001401echo "configure:1402: checking for connect" >&5
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001402if eval "test \"`echo '$''{'ac_cv_func_connect'+set}'`\" = set"; then
1403 echo $ac_n "(cached) $ac_c" 1>&6
1404else
1405 cat > conftest.$ac_ext <<EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001406#line 1407 "configure"
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001407#include "confdefs.h"
1408/* System header to define __stub macros and hopefully few prototypes,
1409 which can conflict with char connect(); below. */
1410#include <assert.h>
1411/* Override any gcc2 internal prototype to avoid an error. */
1412/* We use char because int might match the return type of a gcc2
1413 builtin and then its argument prototype would still apply. */
1414char connect();
1415
1416int main() {
1417
1418/* The GNU C library defines this for functions which it implements
1419 to always fail with ENOSYS. Some functions are actually named
1420 something starting with __ and the normal name is an alias. */
1421#if defined (__stub_connect) || defined (__stub___connect)
1422choke me
1423#else
1424connect();
1425#endif
1426
1427; return 0; }
1428EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001429if { (eval echo configure:1430: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001430 rm -rf conftest*
1431 eval "ac_cv_func_connect=yes"
1432else
1433 echo "configure: failed program was:" >&5
1434 cat conftest.$ac_ext >&5
1435 rm -rf conftest*
1436 eval "ac_cv_func_connect=no"
1437fi
1438rm -f conftest*
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001439fi
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +00001440
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001441if eval "test \"`echo '$ac_cv_func_'connect`\" = yes"; then
1442 echo "$ac_t""yes" 1>&6
1443 :
1444else
1445 echo "$ac_t""no" 1>&6
1446fi
1447
1448 if test $ac_cv_func_connect = no; then
1449 echo $ac_n "checking for connect in -lsocket""... $ac_c" 1>&6
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001450echo "configure:1451: checking for connect in -lsocket" >&5
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001451ac_lib_var=`echo socket'_'connect | sed 'y%./+-%__p_%'`
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00001452if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001453 echo $ac_n "(cached) $ac_c" 1>&6
1454else
1455 ac_save_LIBS="$LIBS"
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001456LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001457cat > conftest.$ac_ext <<EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001458#line 1459 "configure"
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001459#include "confdefs.h"
Alexandre Julliard59730ae1996-03-24 16:20:51 +00001460/* Override any gcc2 internal prototype to avoid an error. */
Alexandre Julliarde2bfa4c1996-05-16 18:21:06 +00001461/* We use char because int might match the return type of a gcc2
1462 builtin and then its argument prototype would still apply. */
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001463char connect();
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001464
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001465int main() {
1466connect()
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001467; return 0; }
1468EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001469if { (eval echo configure:1470: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001470 rm -rf conftest*
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00001471 eval "ac_cv_lib_$ac_lib_var=yes"
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001472else
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001473 echo "configure: failed program was:" >&5
1474 cat conftest.$ac_ext >&5
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001475 rm -rf conftest*
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00001476 eval "ac_cv_lib_$ac_lib_var=no"
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001477fi
1478rm -f conftest*
1479LIBS="$ac_save_LIBS"
1480
1481fi
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00001482if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001483 echo "$ac_t""yes" 1>&6
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001484 X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001485else
1486 echo "$ac_t""no" 1>&6
1487fi
1488
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001489 fi
1490
1491 # gomez@mi.uni-erlangen.de says -lposix is necessary on A/UX.
1492 echo $ac_n "checking for remove""... $ac_c" 1>&6
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001493echo "configure:1494: checking for remove" >&5
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001494if eval "test \"`echo '$''{'ac_cv_func_remove'+set}'`\" = set"; then
1495 echo $ac_n "(cached) $ac_c" 1>&6
1496else
1497 cat > conftest.$ac_ext <<EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001498#line 1499 "configure"
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001499#include "confdefs.h"
1500/* System header to define __stub macros and hopefully few prototypes,
1501 which can conflict with char remove(); below. */
1502#include <assert.h>
1503/* Override any gcc2 internal prototype to avoid an error. */
1504/* We use char because int might match the return type of a gcc2
1505 builtin and then its argument prototype would still apply. */
1506char remove();
1507
1508int main() {
1509
1510/* The GNU C library defines this for functions which it implements
1511 to always fail with ENOSYS. Some functions are actually named
1512 something starting with __ and the normal name is an alias. */
1513#if defined (__stub_remove) || defined (__stub___remove)
1514choke me
1515#else
1516remove();
1517#endif
1518
1519; return 0; }
1520EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001521if { (eval echo configure:1522: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001522 rm -rf conftest*
1523 eval "ac_cv_func_remove=yes"
1524else
1525 echo "configure: failed program was:" >&5
1526 cat conftest.$ac_ext >&5
1527 rm -rf conftest*
1528 eval "ac_cv_func_remove=no"
1529fi
1530rm -f conftest*
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001531fi
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +00001532
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001533if eval "test \"`echo '$ac_cv_func_'remove`\" = yes"; then
1534 echo "$ac_t""yes" 1>&6
1535 :
1536else
1537 echo "$ac_t""no" 1>&6
1538fi
1539
1540 if test $ac_cv_func_remove = no; then
1541 echo $ac_n "checking for remove in -lposix""... $ac_c" 1>&6
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001542echo "configure:1543: checking for remove in -lposix" >&5
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001543ac_lib_var=`echo posix'_'remove | sed 'y%./+-%__p_%'`
Alexandre Julliarde2bfa4c1996-05-16 18:21:06 +00001544if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1545 echo $ac_n "(cached) $ac_c" 1>&6
1546else
1547 ac_save_LIBS="$LIBS"
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001548LIBS="-lposix $LIBS"
Alexandre Julliarde2bfa4c1996-05-16 18:21:06 +00001549cat > conftest.$ac_ext <<EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001550#line 1551 "configure"
Alexandre Julliarde2bfa4c1996-05-16 18:21:06 +00001551#include "confdefs.h"
1552/* Override any gcc2 internal prototype to avoid an error. */
1553/* We use char because int might match the return type of a gcc2
1554 builtin and then its argument prototype would still apply. */
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001555char remove();
Alexandre Julliarde2bfa4c1996-05-16 18:21:06 +00001556
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001557int main() {
1558remove()
Alexandre Julliarde2bfa4c1996-05-16 18:21:06 +00001559; return 0; }
1560EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001561if { (eval echo configure:1562: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Alexandre Julliarde2bfa4c1996-05-16 18:21:06 +00001562 rm -rf conftest*
1563 eval "ac_cv_lib_$ac_lib_var=yes"
1564else
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001565 echo "configure: failed program was:" >&5
1566 cat conftest.$ac_ext >&5
Alexandre Julliarde2bfa4c1996-05-16 18:21:06 +00001567 rm -rf conftest*
1568 eval "ac_cv_lib_$ac_lib_var=no"
1569fi
1570rm -f conftest*
1571LIBS="$ac_save_LIBS"
1572
1573fi
1574if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1575 echo "$ac_t""yes" 1>&6
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001576 X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
Alexandre Julliarde2bfa4c1996-05-16 18:21:06 +00001577else
1578 echo "$ac_t""no" 1>&6
1579fi
1580
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001581 fi
1582
1583 # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
1584 echo $ac_n "checking for shmat""... $ac_c" 1>&6
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001585echo "configure:1586: checking for shmat" >&5
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001586if eval "test \"`echo '$''{'ac_cv_func_shmat'+set}'`\" = set"; then
1587 echo $ac_n "(cached) $ac_c" 1>&6
1588else
1589 cat > conftest.$ac_ext <<EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001590#line 1591 "configure"
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001591#include "confdefs.h"
1592/* System header to define __stub macros and hopefully few prototypes,
1593 which can conflict with char shmat(); below. */
1594#include <assert.h>
1595/* Override any gcc2 internal prototype to avoid an error. */
1596/* We use char because int might match the return type of a gcc2
1597 builtin and then its argument prototype would still apply. */
1598char shmat();
1599
1600int main() {
1601
1602/* The GNU C library defines this for functions which it implements
1603 to always fail with ENOSYS. Some functions are actually named
1604 something starting with __ and the normal name is an alias. */
1605#if defined (__stub_shmat) || defined (__stub___shmat)
1606choke me
1607#else
1608shmat();
1609#endif
1610
1611; return 0; }
1612EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001613if { (eval echo configure:1614: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001614 rm -rf conftest*
1615 eval "ac_cv_func_shmat=yes"
1616else
1617 echo "configure: failed program was:" >&5
1618 cat conftest.$ac_ext >&5
1619 rm -rf conftest*
1620 eval "ac_cv_func_shmat=no"
1621fi
1622rm -f conftest*
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001623fi
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +00001624
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001625if eval "test \"`echo '$ac_cv_func_'shmat`\" = yes"; then
1626 echo "$ac_t""yes" 1>&6
1627 :
1628else
1629 echo "$ac_t""no" 1>&6
1630fi
1631
1632 if test $ac_cv_func_shmat = no; then
1633 echo $ac_n "checking for shmat in -lipc""... $ac_c" 1>&6
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001634echo "configure:1635: checking for shmat in -lipc" >&5
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001635ac_lib_var=`echo ipc'_'shmat | sed 'y%./+-%__p_%'`
1636if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1637 echo $ac_n "(cached) $ac_c" 1>&6
1638else
1639 ac_save_LIBS="$LIBS"
1640LIBS="-lipc $LIBS"
1641cat > conftest.$ac_ext <<EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001642#line 1643 "configure"
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001643#include "confdefs.h"
1644/* Override any gcc2 internal prototype to avoid an error. */
1645/* We use char because int might match the return type of a gcc2
1646 builtin and then its argument prototype would still apply. */
1647char shmat();
1648
1649int main() {
1650shmat()
1651; return 0; }
1652EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001653if { (eval echo configure:1654: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001654 rm -rf conftest*
1655 eval "ac_cv_lib_$ac_lib_var=yes"
1656else
1657 echo "configure: failed program was:" >&5
1658 cat conftest.$ac_ext >&5
1659 rm -rf conftest*
1660 eval "ac_cv_lib_$ac_lib_var=no"
1661fi
1662rm -f conftest*
1663LIBS="$ac_save_LIBS"
1664
1665fi
1666if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1667 echo "$ac_t""yes" 1>&6
1668 X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
1669else
1670 echo "$ac_t""no" 1>&6
1671fi
1672
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001673 fi
1674 fi
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001675
1676 # Check for libraries that X11R6 Xt/Xaw programs need.
1677 ac_save_LDFLAGS="$LDFLAGS"
1678 test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
1679 # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
1680 # check for ICE first), but we must link in the order -lSM -lICE or
1681 # we get undefined symbols. So assume we have SM if we have ICE.
1682 # These have to be linked with before -lX11, unlike the other
1683 # libraries we check for below, so use a different variable.
1684 # --interran@uluru.Stanford.EDU, kb@cs.umb.edu.
1685 echo $ac_n "checking for IceConnectionNumber in -lICE""... $ac_c" 1>&6
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001686echo "configure:1687: checking for IceConnectionNumber in -lICE" >&5
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001687ac_lib_var=`echo ICE'_'IceConnectionNumber | sed 'y%./+-%__p_%'`
1688if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1689 echo $ac_n "(cached) $ac_c" 1>&6
1690else
1691 ac_save_LIBS="$LIBS"
1692LIBS="-lICE $LIBS"
1693cat > conftest.$ac_ext <<EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001694#line 1695 "configure"
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001695#include "confdefs.h"
1696/* Override any gcc2 internal prototype to avoid an error. */
1697/* We use char because int might match the return type of a gcc2
1698 builtin and then its argument prototype would still apply. */
1699char IceConnectionNumber();
1700
1701int main() {
1702IceConnectionNumber()
1703; return 0; }
1704EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001705if { (eval echo configure:1706: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001706 rm -rf conftest*
1707 eval "ac_cv_lib_$ac_lib_var=yes"
1708else
1709 echo "configure: failed program was:" >&5
1710 cat conftest.$ac_ext >&5
1711 rm -rf conftest*
1712 eval "ac_cv_lib_$ac_lib_var=no"
1713fi
1714rm -f conftest*
1715LIBS="$ac_save_LIBS"
1716
1717fi
1718if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1719 echo "$ac_t""yes" 1>&6
1720 X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
1721else
1722 echo "$ac_t""no" 1>&6
1723fi
1724
1725 LDFLAGS="$ac_save_LDFLAGS"
1726
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001727fi
1728
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001729for ac_prog in 'bison -y' byacc
1730do
1731# Extract the first word of "$ac_prog", so it can be a program name with args.
1732set dummy $ac_prog; ac_word=$2
1733echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001734echo "configure:1735: checking for $ac_word" >&5
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001735if eval "test \"`echo '$''{'ac_cv_prog_YACC'+set}'`\" = set"; then
1736 echo $ac_n "(cached) $ac_c" 1>&6
1737else
1738 if test -n "$YACC"; then
1739 ac_cv_prog_YACC="$YACC" # Let the user override the test.
1740else
1741 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1742 for ac_dir in $PATH; do
1743 test -z "$ac_dir" && ac_dir=.
1744 if test -f $ac_dir/$ac_word; then
1745 ac_cv_prog_YACC="$ac_prog"
1746 break
1747 fi
1748 done
1749 IFS="$ac_save_ifs"
1750fi
1751fi
1752YACC="$ac_cv_prog_YACC"
1753if test -n "$YACC"; then
1754 echo "$ac_t""$YACC" 1>&6
1755else
1756 echo "$ac_t""no" 1>&6
1757fi
1758
1759test -n "$YACC" && break
1760done
1761test -n "$YACC" || YACC="yacc"
1762
1763# Extract the first word of "flex", so it can be a program name with args.
1764set dummy flex; ac_word=$2
1765echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001766echo "configure:1767: checking for $ac_word" >&5
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001767if eval "test \"`echo '$''{'ac_cv_prog_LEX'+set}'`\" = set"; then
1768 echo $ac_n "(cached) $ac_c" 1>&6
1769else
1770 if test -n "$LEX"; then
1771 ac_cv_prog_LEX="$LEX" # Let the user override the test.
1772else
1773 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1774 for ac_dir in $PATH; do
1775 test -z "$ac_dir" && ac_dir=.
1776 if test -f $ac_dir/$ac_word; then
1777 ac_cv_prog_LEX="flex"
1778 break
1779 fi
1780 done
1781 IFS="$ac_save_ifs"
1782 test -z "$ac_cv_prog_LEX" && ac_cv_prog_LEX="lex"
1783fi
1784fi
1785LEX="$ac_cv_prog_LEX"
1786if test -n "$LEX"; then
1787 echo "$ac_t""$LEX" 1>&6
1788else
1789 echo "$ac_t""no" 1>&6
1790fi
1791
1792if test -z "$LEXLIB"
1793then
1794 case "$LEX" in
1795 flex*) ac_lib=fl ;;
1796 *) ac_lib=l ;;
1797 esac
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001798 echo $ac_n "checking for yywrap in -l$ac_lib""... $ac_c" 1>&6
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001799echo "configure:1800: checking for yywrap in -l$ac_lib" >&5
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001800ac_lib_var=`echo $ac_lib'_'yywrap | sed 'y%./+-%__p_%'`
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00001801if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001802 echo $ac_n "(cached) $ac_c" 1>&6
1803else
1804 ac_save_LIBS="$LIBS"
1805LIBS="-l$ac_lib $LIBS"
1806cat > conftest.$ac_ext <<EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001807#line 1808 "configure"
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001808#include "confdefs.h"
Alexandre Julliard59730ae1996-03-24 16:20:51 +00001809/* Override any gcc2 internal prototype to avoid an error. */
Alexandre Julliarde2bfa4c1996-05-16 18:21:06 +00001810/* We use char because int might match the return type of a gcc2
1811 builtin and then its argument prototype would still apply. */
Alexandre Julliard59730ae1996-03-24 16:20:51 +00001812char yywrap();
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001813
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001814int main() {
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001815yywrap()
1816; return 0; }
1817EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001818if { (eval echo configure:1819: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001819 rm -rf conftest*
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00001820 eval "ac_cv_lib_$ac_lib_var=yes"
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001821else
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001822 echo "configure: failed program was:" >&5
1823 cat conftest.$ac_ext >&5
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001824 rm -rf conftest*
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00001825 eval "ac_cv_lib_$ac_lib_var=no"
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001826fi
1827rm -f conftest*
1828LIBS="$ac_save_LIBS"
1829
1830fi
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00001831if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001832 echo "$ac_t""yes" 1>&6
1833 LEXLIB="-l$ac_lib"
1834else
1835 echo "$ac_t""no" 1>&6
1836fi
1837
1838fi
1839
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001840# Extract the first word of "ranlib", so it can be a program name with args.
1841set dummy ranlib; ac_word=$2
1842echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001843echo "configure:1844: checking for $ac_word" >&5
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001844if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
1845 echo $ac_n "(cached) $ac_c" 1>&6
1846else
1847 if test -n "$RANLIB"; then
1848 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1849else
1850 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1851 for ac_dir in $PATH; do
1852 test -z "$ac_dir" && ac_dir=.
1853 if test -f $ac_dir/$ac_word; then
1854 ac_cv_prog_RANLIB="ranlib"
1855 break
1856 fi
1857 done
1858 IFS="$ac_save_ifs"
1859 test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001860fi
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001861fi
Alexandre Julliardff8331e1995-09-18 11:19:54 +00001862RANLIB="$ac_cv_prog_RANLIB"
1863if test -n "$RANLIB"; then
1864 echo "$ac_t""$RANLIB" 1>&6
1865else
1866 echo "$ac_t""no" 1>&6
1867fi
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00001868
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00001869# Find a good install program. We prefer a C program (faster),
1870# so one script is as good as another. But avoid the broken or
1871# incompatible versions:
1872# SysV /etc/install, /usr/sbin/install
1873# SunOS /usr/etc/install
1874# IRIX /sbin/install
1875# AIX /bin/install
1876# AFS /usr/afsws/bin/install, which mishandles nonexistent args
1877# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
1878# ./install, which can be erroneously created by make from ./install.sh.
1879echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001880echo "configure:1881: checking for a BSD compatible install" >&5
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00001881if test -z "$INSTALL"; then
1882if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
1883 echo $ac_n "(cached) $ac_c" 1>&6
1884else
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +00001885 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="${IFS}:"
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00001886 for ac_dir in $PATH; do
1887 # Account for people who put trailing slashes in PATH elements.
1888 case "$ac_dir/" in
1889 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
1890 *)
1891 # OSF1 and SCO ODT 3.0 have their own names for install.
1892 for ac_prog in ginstall installbsd scoinst install; do
1893 if test -f $ac_dir/$ac_prog; then
1894 if test $ac_prog = install &&
1895 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
1896 # AIX install. It has an incompatible calling convention.
1897 # OSF/1 installbsd also uses dspmsg, but is usable.
1898 :
1899 else
1900 ac_cv_path_install="$ac_dir/$ac_prog -c"
1901 break 2
1902 fi
1903 fi
1904 done
1905 ;;
1906 esac
1907 done
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +00001908 IFS="$ac_save_IFS"
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00001909
1910fi
1911 if test "${ac_cv_path_install+set}" = set; then
1912 INSTALL="$ac_cv_path_install"
1913 else
1914 # As a last resort, use the slow shell script. We don't cache a
1915 # path for INSTALL within a source directory, because that will
1916 # break other packages using the cache if that directory is
1917 # removed, or if the path is relative.
1918 INSTALL="$ac_install_sh"
1919 fi
1920fi
1921echo "$ac_t""$INSTALL" 1>&6
1922
1923# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
1924# It thinks the first close brace ends the variable substitution.
1925test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
1926
1927test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
1928
Alexandre Julliard641ee761997-08-04 16:34:36 +00001929echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001930echo "configure:1931: checking whether ln -s works" >&5
Alexandre Julliard641ee761997-08-04 16:34:36 +00001931if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
1932 echo $ac_n "(cached) $ac_c" 1>&6
1933else
1934 rm -f conftestdata
1935if ln -s X conftestdata 2>/dev/null
1936then
1937 rm -f conftestdata
1938 ac_cv_prog_LN_S="ln -s"
1939else
1940 ac_cv_prog_LN_S=ln
1941fi
1942fi
1943LN_S="$ac_cv_prog_LN_S"
1944if test "$ac_cv_prog_LN_S" = "ln -s"; then
1945 echo "$ac_t""yes" 1>&6
1946else
1947 echo "$ac_t""no" 1>&6
1948fi
1949
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00001950# Extract the first word of "c2man", so it can be a program name with args.
1951set dummy c2man; ac_word=$2
1952echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001953echo "configure:1954: checking for $ac_word" >&5
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00001954if eval "test \"`echo '$''{'ac_cv_prog_C2MAN'+set}'`\" = set"; then
1955 echo $ac_n "(cached) $ac_c" 1>&6
1956else
1957 if test -n "$C2MAN"; then
1958 ac_cv_prog_C2MAN="$C2MAN" # Let the user override the test.
1959else
1960 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1961 for ac_dir in $PATH; do
1962 test -z "$ac_dir" && ac_dir=.
1963 if test -f $ac_dir/$ac_word; then
1964 ac_cv_prog_C2MAN="c2man"
1965 break
1966 fi
1967 done
1968 IFS="$ac_save_ifs"
1969 test -z "$ac_cv_prog_C2MAN" && ac_cv_prog_C2MAN="true"
1970fi
1971fi
1972C2MAN="$ac_cv_prog_C2MAN"
1973if test -n "$C2MAN"; then
1974 echo "$ac_t""$C2MAN" 1>&6
1975else
1976 echo "$ac_t""no" 1>&6
1977fi
1978
Alexandre Julliard02e90081998-01-04 17:49:09 +00001979
1980
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001981echo $ac_n "checking for i386_set_ldt in -li386""... $ac_c" 1>&6
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001982echo "configure:1983: checking for i386_set_ldt in -li386" >&5
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001983ac_lib_var=`echo i386'_'i386_set_ldt | sed 'y%./+-%__p_%'`
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00001984if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
Alexandre Julliard902da691995-11-05 14:39:02 +00001985 echo $ac_n "(cached) $ac_c" 1>&6
1986else
1987 ac_save_LIBS="$LIBS"
1988LIBS="-li386 $LIBS"
1989cat > conftest.$ac_ext <<EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00001990#line 1991 "configure"
Alexandre Julliard902da691995-11-05 14:39:02 +00001991#include "confdefs.h"
Alexandre Julliard59730ae1996-03-24 16:20:51 +00001992/* Override any gcc2 internal prototype to avoid an error. */
Alexandre Julliarde2bfa4c1996-05-16 18:21:06 +00001993/* We use char because int might match the return type of a gcc2
1994 builtin and then its argument prototype would still apply. */
Alexandre Julliard59730ae1996-03-24 16:20:51 +00001995char i386_set_ldt();
Alexandre Julliard902da691995-11-05 14:39:02 +00001996
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00001997int main() {
Alexandre Julliard902da691995-11-05 14:39:02 +00001998i386_set_ldt()
1999; return 0; }
2000EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00002001if { (eval echo configure:2002: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Alexandre Julliard902da691995-11-05 14:39:02 +00002002 rm -rf conftest*
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00002003 eval "ac_cv_lib_$ac_lib_var=yes"
Alexandre Julliard902da691995-11-05 14:39:02 +00002004else
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00002005 echo "configure: failed program was:" >&5
2006 cat conftest.$ac_ext >&5
Alexandre Julliard902da691995-11-05 14:39:02 +00002007 rm -rf conftest*
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00002008 eval "ac_cv_lib_$ac_lib_var=no"
Alexandre Julliard902da691995-11-05 14:39:02 +00002009fi
2010rm -f conftest*
2011LIBS="$ac_save_LIBS"
2012
2013fi
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00002014if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
Alexandre Julliard902da691995-11-05 14:39:02 +00002015 echo "$ac_t""yes" 1>&6
Alexandre Julliard02e90081998-01-04 17:49:09 +00002016 ac_tr_lib=HAVE_LIB`echo i386 | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2017 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2018 cat >> confdefs.h <<EOF
2019#define $ac_tr_lib 1
2020EOF
2021
2022 LIBS="-li386 $LIBS"
2023
2024else
2025 echo "$ac_t""no" 1>&6
2026fi
2027
Todd Vierlingecc76691998-12-15 17:49:02 +00002028echo $ac_n "checking for _oss_ioctl in -lossaudio""... $ac_c" 1>&6
Joseph Praneviche884f9c1999-01-03 16:14:34 +00002029echo "configure:2030: checking for _oss_ioctl in -lossaudio" >&5
Todd Vierlingecc76691998-12-15 17:49:02 +00002030ac_lib_var=`echo ossaudio'_'_oss_ioctl | sed 'y%./+-%__p_%'`
2031if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2032 echo $ac_n "(cached) $ac_c" 1>&6
2033else
2034 ac_save_LIBS="$LIBS"
2035LIBS="-lossaudio $LIBS"
2036cat > conftest.$ac_ext <<EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00002037#line 2038 "configure"
Todd Vierlingecc76691998-12-15 17:49:02 +00002038#include "confdefs.h"
2039/* Override any gcc2 internal prototype to avoid an error. */
2040/* We use char because int might match the return type of a gcc2
2041 builtin and then its argument prototype would still apply. */
2042char _oss_ioctl();
2043
2044int main() {
2045_oss_ioctl()
2046; return 0; }
2047EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00002048if { (eval echo configure:2049: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Todd Vierlingecc76691998-12-15 17:49:02 +00002049 rm -rf conftest*
2050 eval "ac_cv_lib_$ac_lib_var=yes"
2051else
2052 echo "configure: failed program was:" >&5
2053 cat conftest.$ac_ext >&5
2054 rm -rf conftest*
2055 eval "ac_cv_lib_$ac_lib_var=no"
2056fi
2057rm -f conftest*
2058LIBS="$ac_save_LIBS"
2059
2060fi
2061if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2062 echo "$ac_t""yes" 1>&6
2063 ac_tr_lib=HAVE_LIB`echo ossaudio | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2064 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2065 cat >> confdefs.h <<EOF
2066#define $ac_tr_lib 1
2067EOF
2068
2069 LIBS="-lossaudio $LIBS"
2070
2071else
2072 echo "$ac_t""no" 1>&6
2073fi
2074
Alexandre Julliard02e90081998-01-04 17:49:09 +00002075echo $ac_n "checking for iswalnum in -lw""... $ac_c" 1>&6
Joseph Praneviche884f9c1999-01-03 16:14:34 +00002076echo "configure:2077: checking for iswalnum in -lw" >&5
Alexandre Julliard02e90081998-01-04 17:49:09 +00002077ac_lib_var=`echo w'_'iswalnum | sed 'y%./+-%__p_%'`
2078if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2079 echo $ac_n "(cached) $ac_c" 1>&6
2080else
2081 ac_save_LIBS="$LIBS"
2082LIBS="-lw $LIBS"
2083cat > conftest.$ac_ext <<EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00002084#line 2085 "configure"
Alexandre Julliard02e90081998-01-04 17:49:09 +00002085#include "confdefs.h"
2086/* Override any gcc2 internal prototype to avoid an error. */
2087/* We use char because int might match the return type of a gcc2
2088 builtin and then its argument prototype would still apply. */
2089char iswalnum();
2090
2091int main() {
2092iswalnum()
2093; return 0; }
2094EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00002095if { (eval echo configure:2096: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Alexandre Julliard02e90081998-01-04 17:49:09 +00002096 rm -rf conftest*
2097 eval "ac_cv_lib_$ac_lib_var=yes"
2098else
2099 echo "configure: failed program was:" >&5
2100 cat conftest.$ac_ext >&5
2101 rm -rf conftest*
2102 eval "ac_cv_lib_$ac_lib_var=no"
2103fi
2104rm -f conftest*
2105LIBS="$ac_save_LIBS"
2106
2107fi
2108if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2109 echo "$ac_t""yes" 1>&6
2110 ac_tr_lib=HAVE_LIB`echo w | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2111 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2112 cat >> confdefs.h <<EOF
2113#define $ac_tr_lib 1
2114EOF
2115
2116 LIBS="-lw $LIBS"
2117
2118else
2119 echo "$ac_t""no" 1>&6
2120fi
2121
Patrik Stridvallea584721998-11-01 16:22:07 +00002122for ac_func in gethostbyname
2123do
2124echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
Joseph Praneviche884f9c1999-01-03 16:14:34 +00002125echo "configure:2126: checking for $ac_func" >&5
Patrik Stridvallea584721998-11-01 16:22:07 +00002126if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2127 echo $ac_n "(cached) $ac_c" 1>&6
2128else
2129 cat > conftest.$ac_ext <<EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00002130#line 2131 "configure"
Patrik Stridvallea584721998-11-01 16:22:07 +00002131#include "confdefs.h"
2132/* System header to define __stub macros and hopefully few prototypes,
2133 which can conflict with char $ac_func(); below. */
2134#include <assert.h>
2135/* Override any gcc2 internal prototype to avoid an error. */
2136/* We use char because int might match the return type of a gcc2
2137 builtin and then its argument prototype would still apply. */
2138char $ac_func();
2139
2140int main() {
2141
2142/* The GNU C library defines this for functions which it implements
2143 to always fail with ENOSYS. Some functions are actually named
2144 something starting with __ and the normal name is an alias. */
2145#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2146choke me
2147#else
2148$ac_func();
2149#endif
2150
2151; return 0; }
2152EOF
Joseph Praneviche884f9c1999-01-03 16:14:34 +00002153if { (eval echo configure:2154: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Patrik Stridvallea584721998-11-01 16:22:07 +00002154 rm -rf conftest*
2155 eval "ac_cv_func_$ac_func=yes"
2156else
2157 echo "configure: failed program was:" >&5
2158 cat conftest.$ac_ext >&5
2159 rm -rf conftest*
2160 eval "ac_cv_func_$ac_func=no"
2161fi
2162rm -f conftest*
2163fi
2164
2165if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2166 echo "$ac_t""yes" 1>&6
2167 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2168 cat >> confdefs.h <<EOF
2169#define $ac_tr_func 1
2170EOF
2171
2172else
2173 echo "$ac_t""no" 1>&6
Marcus Meissnerf070fda1999-04-24 12:02:14 +00002174echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6
2175echo "configure:2176: checking for gethostbyname in -lnsl" >&5
Patrik Stridvallea584721998-11-01 16:22:07 +00002176ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'`
2177if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2178 echo $ac_n "(cached) $ac_c" 1>&6
2179else
2180 ac_save_LIBS="$LIBS"
2181LIBS="-lnsl $LIBS"
2182cat > conftest.$ac_ext <<EOF
Marcus Meissnerf070fda1999-04-24 12:02:14 +00002183#line 2184 "configure"
Patrik Stridvallea584721998-11-01 16:22:07 +00002184#include "confdefs.h"
2185/* Override any gcc2 internal prototype to avoid an error. */
2186/* We use char because int might match the return type of a gcc2
2187 builtin and then its argument prototype would still apply. */
2188char gethostbyname();
2189
2190int main() {
2191gethostbyname()
2192; return 0; }
2193EOF
Marcus Meissnerf070fda1999-04-24 12:02:14 +00002194if { (eval echo configure:2195: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Patrik Stridvallea584721998-11-01 16:22:07 +00002195 rm -rf conftest*
2196 eval "ac_cv_lib_$ac_lib_var=yes"
2197else
2198 echo "configure: failed program was:" >&5
2199 cat conftest.$ac_ext >&5
2200 rm -rf conftest*
2201 eval "ac_cv_lib_$ac_lib_var=no"
2202fi
2203rm -f conftest*
2204LIBS="$ac_save_LIBS"
2205
2206fi
2207if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2208 echo "$ac_t""yes" 1>&6
Marcus Meissnerf070fda1999-04-24 12:02:14 +00002209 ac_tr_lib=HAVE_LIB`echo nsl | sed -e 's/^a-zA-Z0-9_/_/g' \
Patrik Stridvallea584721998-11-01 16:22:07 +00002210 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2211 cat >> confdefs.h <<EOF
2212#define $ac_tr_lib 1
2213EOF
2214
2215 LIBS="-lnsl $LIBS"
2216
2217else
2218 echo "$ac_t""no" 1>&6
2219fi
2220
2221fi
Marcus Meissnerf070fda1999-04-24 12:02:14 +00002222done
2223
Ulrich Weigand715a55e1999-04-18 13:19:56 +00002224for ac_func in connect
2225do
2226echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
Marcus Meissnerf070fda1999-04-24 12:02:14 +00002227echo "configure:2228: checking for $ac_func" >&5
Ulrich Weigand715a55e1999-04-18 13:19:56 +00002228if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2229 echo $ac_n "(cached) $ac_c" 1>&6
2230else
2231 cat > conftest.$ac_ext <<EOF
Marcus Meissnerf070fda1999-04-24 12:02:14 +00002232#line 2233 "configure"
Ulrich Weigand715a55e1999-04-18 13:19:56 +00002233#include "confdefs.h"
2234/* System header to define __stub macros and hopefully few prototypes,
2235 which can conflict with char $ac_func(); below. */
2236#include <assert.h>
2237/* Override any gcc2 internal prototype to avoid an error. */
2238/* We use char because int might match the return type of a gcc2
2239 builtin and then its argument prototype would still apply. */
2240char $ac_func();
2241
2242int main() {
2243
2244/* The GNU C library defines this for functions which it implements
2245 to always fail with ENOSYS. Some functions are actually named
2246 something starting with __ and the normal name is an alias. */
2247#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2248choke me
2249#else
2250$ac_func();
2251#endif
2252
2253; return 0; }
2254EOF
Marcus Meissnerf070fda1999-04-24 12:02:14 +00002255if { (eval echo configure:2256: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Ulrich Weigand715a55e1999-04-18 13:19:56 +00002256 rm -rf conftest*
2257 eval "ac_cv_func_$ac_func=yes"
2258else
2259 echo "configure: failed program was:" >&5
2260 cat conftest.$ac_ext >&5
2261 rm -rf conftest*
2262 eval "ac_cv_func_$ac_func=no"
2263fi
2264rm -f conftest*
2265fi
2266
2267if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2268 echo "$ac_t""yes" 1>&6
2269 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2270 cat >> confdefs.h <<EOF
2271#define $ac_tr_func 1
2272EOF
2273
2274else
2275 echo "$ac_t""no" 1>&6
Marcus Meissnerf070fda1999-04-24 12:02:14 +00002276echo $ac_n "checking for connect in -lsocket""... $ac_c" 1>&6
2277echo "configure:2278: checking for connect in -lsocket" >&5
Ulrich Weigand715a55e1999-04-18 13:19:56 +00002278ac_lib_var=`echo socket'_'connect | sed 'y%./+-%__p_%'`
2279if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2280 echo $ac_n "(cached) $ac_c" 1>&6
2281else
2282 ac_save_LIBS="$LIBS"
2283LIBS="-lsocket $LIBS"
2284cat > conftest.$ac_ext <<EOF
Marcus Meissnerf070fda1999-04-24 12:02:14 +00002285#line 2286 "configure"
Ulrich Weigand715a55e1999-04-18 13:19:56 +00002286#include "confdefs.h"
2287/* Override any gcc2 internal prototype to avoid an error. */
2288/* We use char because int might match the return type of a gcc2
2289 builtin and then its argument prototype would still apply. */
2290char connect();
2291
2292int main() {
2293connect()
2294; return 0; }
2295EOF
Marcus Meissnerf070fda1999-04-24 12:02:14 +00002296if { (eval echo configure:2297: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Ulrich Weigand715a55e1999-04-18 13:19:56 +00002297 rm -rf conftest*
2298 eval "ac_cv_lib_$ac_lib_var=yes"
2299else
2300 echo "configure: failed program was:" >&5
2301 cat conftest.$ac_ext >&5
2302 rm -rf conftest*
2303 eval "ac_cv_lib_$ac_lib_var=no"
2304fi
2305rm -f conftest*
2306LIBS="$ac_save_LIBS"
2307
2308fi
2309if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2310 echo "$ac_t""yes" 1>&6
Marcus Meissnerf070fda1999-04-24 12:02:14 +00002311 ac_tr_lib=HAVE_LIB`echo socket | sed -e 's/^a-zA-Z0-9_/_/g' \
Ulrich Weigand715a55e1999-04-18 13:19:56 +00002312 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2313 cat >> confdefs.h <<EOF
2314#define $ac_tr_lib 1
2315EOF
2316
2317 LIBS="-lsocket $LIBS"
2318
2319else
2320 echo "$ac_t""no" 1>&6
2321fi
2322
2323fi
Marcus Meissnerf070fda1999-04-24 12:02:14 +00002324done
2325
Alexandre Julliardd30dfd21998-09-27 18:28:36 +00002326echo $ac_n "checking for setrunelocale in -lxpg4""... $ac_c" 1>&6
Marcus Meissnerf070fda1999-04-24 12:02:14 +00002327echo "configure:2328: checking for setrunelocale in -lxpg4" >&5
Alexandre Julliardd30dfd21998-09-27 18:28:36 +00002328ac_lib_var=`echo xpg4'_'setrunelocale | sed 'y%./+-%__p_%'`
2329if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2330 echo $ac_n "(cached) $ac_c" 1>&6
2331else
2332 ac_save_LIBS="$LIBS"
2333LIBS="-lxpg4 $LIBS"
2334cat > conftest.$ac_ext <<EOF
Marcus Meissnerf070fda1999-04-24 12:02:14 +00002335#line 2336 "configure"
Alexandre Julliardd30dfd21998-09-27 18:28:36 +00002336#include "confdefs.h"
2337/* Override any gcc2 internal prototype to avoid an error. */
2338/* We use char because int might match the return type of a gcc2
2339 builtin and then its argument prototype would still apply. */
2340char setrunelocale();
2341
2342int main() {
2343setrunelocale()
2344; return 0; }
2345EOF
Marcus Meissnerf070fda1999-04-24 12:02:14 +00002346if { (eval echo configure:2347: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Alexandre Julliardd30dfd21998-09-27 18:28:36 +00002347 rm -rf conftest*
2348 eval "ac_cv_lib_$ac_lib_var=yes"
2349else
2350 echo "configure: failed program was:" >&5
2351 cat conftest.$ac_ext >&5
2352 rm -rf conftest*
2353 eval "ac_cv_lib_$ac_lib_var=no"
2354fi
2355rm -f conftest*
2356LIBS="$ac_save_LIBS"
2357
2358fi
2359if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2360 echo "$ac_t""yes" 1>&6
2361 ac_tr_lib=HAVE_LIB`echo xpg4 | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2362 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2363 cat >> confdefs.h <<EOF
2364#define $ac_tr_lib 1
2365EOF
2366
2367 LIBS="-lxpg4 $LIBS"
2368
2369else
2370 echo "$ac_t""no" 1>&6
2371fi
2372
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002373echo $ac_n "checking for mmap in -lmmap""... $ac_c" 1>&6
2374echo "configure:2375: checking for mmap in -lmmap" >&5
2375ac_lib_var=`echo mmap'_'mmap | sed 'y%./+-%__p_%'`
2376if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2377 echo $ac_n "(cached) $ac_c" 1>&6
2378else
2379 ac_save_LIBS="$LIBS"
2380LIBS="-lmmap $LIBS"
2381cat > conftest.$ac_ext <<EOF
2382#line 2383 "configure"
2383#include "confdefs.h"
2384/* Override any gcc2 internal prototype to avoid an error. */
2385/* We use char because int might match the return type of a gcc2
2386 builtin and then its argument prototype would still apply. */
2387char mmap();
2388
2389int main() {
2390mmap()
2391; return 0; }
2392EOF
2393if { (eval echo configure:2394: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2394 rm -rf conftest*
2395 eval "ac_cv_lib_$ac_lib_var=yes"
2396else
2397 echo "configure: failed program was:" >&5
2398 cat conftest.$ac_ext >&5
2399 rm -rf conftest*
2400 eval "ac_cv_lib_$ac_lib_var=no"
2401fi
2402rm -f conftest*
2403LIBS="$ac_save_LIBS"
2404
2405fi
2406if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2407 echo "$ac_t""yes" 1>&6
2408 ac_tr_lib=HAVE_LIB`echo mmap | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2409 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2410 cat >> confdefs.h <<EOF
2411#define $ac_tr_lib 1
2412EOF
2413
2414 LIBS="-lmmap $LIBS"
2415
2416else
2417 echo "$ac_t""no" 1>&6
2418fi
2419
Marcus Meissnerf070fda1999-04-24 12:02:14 +00002420
2421for ac_hdr in dlfcn.h
2422do
2423ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2424echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002425echo "configure:2426: checking for $ac_hdr" >&5
Marcus Meissnerf070fda1999-04-24 12:02:14 +00002426if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2427 echo $ac_n "(cached) $ac_c" 1>&6
2428else
2429 cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002430#line 2431 "configure"
Marcus Meissnerf070fda1999-04-24 12:02:14 +00002431#include "confdefs.h"
2432#include <$ac_hdr>
2433EOF
2434ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002435{ (eval echo configure:2436: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
Marcus Meissnerf070fda1999-04-24 12:02:14 +00002436ac_err=`grep -v '^ *+' conftest.out`
2437if test -z "$ac_err"; then
2438 rm -rf conftest*
2439 eval "ac_cv_header_$ac_safe=yes"
2440else
2441 echo "$ac_err" >&5
2442 echo "configure: failed program was:" >&5
2443 cat conftest.$ac_ext >&5
2444 rm -rf conftest*
2445 eval "ac_cv_header_$ac_safe=no"
2446fi
2447rm -f conftest*
2448fi
2449if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2450 echo "$ac_t""yes" 1>&6
2451 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2452 cat >> confdefs.h <<EOF
2453#define $ac_tr_hdr 1
2454EOF
2455 for ac_func in dlopen
2456do
2457echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002458echo "configure:2459: checking for $ac_func" >&5
Marcus Meissnerf070fda1999-04-24 12:02:14 +00002459if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2460 echo $ac_n "(cached) $ac_c" 1>&6
2461else
2462 cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002463#line 2464 "configure"
Marcus Meissnerf070fda1999-04-24 12:02:14 +00002464#include "confdefs.h"
2465/* System header to define __stub macros and hopefully few prototypes,
2466 which can conflict with char $ac_func(); below. */
2467#include <assert.h>
2468/* Override any gcc2 internal prototype to avoid an error. */
2469/* We use char because int might match the return type of a gcc2
2470 builtin and then its argument prototype would still apply. */
2471char $ac_func();
2472
2473int main() {
2474
2475/* The GNU C library defines this for functions which it implements
2476 to always fail with ENOSYS. Some functions are actually named
2477 something starting with __ and the normal name is an alias. */
2478#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2479choke me
2480#else
2481$ac_func();
2482#endif
2483
2484; return 0; }
2485EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002486if { (eval echo configure:2487: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Marcus Meissnerf070fda1999-04-24 12:02:14 +00002487 rm -rf conftest*
2488 eval "ac_cv_func_$ac_func=yes"
2489else
2490 echo "configure: failed program was:" >&5
2491 cat conftest.$ac_ext >&5
2492 rm -rf conftest*
2493 eval "ac_cv_func_$ac_func=no"
2494fi
2495rm -f conftest*
2496fi
2497
2498if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2499 echo "$ac_t""yes" 1>&6
2500 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2501 cat >> confdefs.h <<EOF
2502#define $ac_tr_func 1
2503EOF
2504 cat >> confdefs.h <<\EOF
2505#define HAVE_DL_API 1
2506EOF
2507
2508else
2509 echo "$ac_t""no" 1>&6
Marcus Meissner8220bc91998-10-11 11:10:27 +00002510echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002511echo "configure:2512: checking for dlopen in -ldl" >&5
Marcus Meissner8220bc91998-10-11 11:10:27 +00002512ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'`
2513if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2514 echo $ac_n "(cached) $ac_c" 1>&6
2515else
2516 ac_save_LIBS="$LIBS"
2517LIBS="-ldl $LIBS"
2518cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002519#line 2520 "configure"
Marcus Meissner8220bc91998-10-11 11:10:27 +00002520#include "confdefs.h"
2521/* Override any gcc2 internal prototype to avoid an error. */
2522/* We use char because int might match the return type of a gcc2
2523 builtin and then its argument prototype would still apply. */
2524char dlopen();
2525
2526int main() {
2527dlopen()
2528; return 0; }
2529EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002530if { (eval echo configure:2531: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Marcus Meissner8220bc91998-10-11 11:10:27 +00002531 rm -rf conftest*
2532 eval "ac_cv_lib_$ac_lib_var=yes"
2533else
2534 echo "configure: failed program was:" >&5
2535 cat conftest.$ac_ext >&5
2536 rm -rf conftest*
2537 eval "ac_cv_lib_$ac_lib_var=no"
2538fi
2539rm -f conftest*
2540LIBS="$ac_save_LIBS"
2541
2542fi
2543if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2544 echo "$ac_t""yes" 1>&6
Marcus Meissnerf070fda1999-04-24 12:02:14 +00002545 cat >> confdefs.h <<\EOF
2546#define HAVE_DL_API 1
Marcus Meissner8220bc91998-10-11 11:10:27 +00002547EOF
2548
Marcus Meissnerf070fda1999-04-24 12:02:14 +00002549 LIBS="$LIBS -ldl"
2550
2551else
2552 echo "$ac_t""no" 1>&6
2553fi
2554
2555
2556fi
2557done
2558
Marcus Meissner8220bc91998-10-11 11:10:27 +00002559
2560else
2561 echo "$ac_t""no" 1>&6
2562fi
Marcus Meissnerf070fda1999-04-24 12:02:14 +00002563done
Marcus Meissner8220bc91998-10-11 11:10:27 +00002564
Patrik Stridvallea584721998-11-01 16:22:07 +00002565
2566if test "$have_x" = "yes"
2567then
Patrik Stridvall24110281999-02-04 10:09:54 +00002568 XLIB="-lXext -lX11"
Ove Kaaven1eb593c1999-02-14 09:34:46 +00002569 ac_save_CPPFLAGS="$CPPFLAGS"
2570 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
Patrik Stridvallea584721998-11-01 16:22:07 +00002571
Patrik Stridvall24110281999-02-04 10:09:54 +00002572 for ac_hdr in X11/xpm.h
Lionel Ulmera1d6d241999-01-30 15:54:43 +00002573do
2574ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2575echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002576echo "configure:2577: checking for $ac_hdr" >&5
Lionel Ulmera1d6d241999-01-30 15:54:43 +00002577if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2578 echo $ac_n "(cached) $ac_c" 1>&6
2579else
2580 cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002581#line 2582 "configure"
Lionel Ulmera1d6d241999-01-30 15:54:43 +00002582#include "confdefs.h"
2583#include <$ac_hdr>
2584EOF
2585ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002586{ (eval echo configure:2587: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
Lionel Ulmera1d6d241999-01-30 15:54:43 +00002587ac_err=`grep -v '^ *+' conftest.out`
2588if test -z "$ac_err"; then
2589 rm -rf conftest*
2590 eval "ac_cv_header_$ac_safe=yes"
2591else
2592 echo "$ac_err" >&5
2593 echo "configure: failed program was:" >&5
2594 cat conftest.$ac_ext >&5
2595 rm -rf conftest*
2596 eval "ac_cv_header_$ac_safe=no"
2597fi
2598rm -f conftest*
2599fi
2600if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2601 echo "$ac_t""yes" 1>&6
2602 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2603 cat >> confdefs.h <<EOF
2604#define $ac_tr_hdr 1
2605EOF
2606
2607else
2608 echo "$ac_t""no" 1>&6
2609fi
2610done
2611
Patrik Stridvall24110281999-02-04 10:09:54 +00002612 if test "$ac_cv_header_X11_xpm_h" = "yes"
2613 then
2614 echo $ac_n "checking for XpmCreatePixmapFromData in -lXpm""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002615echo "configure:2616: checking for XpmCreatePixmapFromData in -lXpm" >&5
Patrik Stridvall24110281999-02-04 10:09:54 +00002616ac_lib_var=`echo Xpm'_'XpmCreatePixmapFromData | sed 'y%./+-%__p_%'`
2617if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2618 echo $ac_n "(cached) $ac_c" 1>&6
2619else
2620 ac_save_LIBS="$LIBS"
2621LIBS="-lXpm $X_LIBS -lXext -lX11 $LIBS"
2622cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002623#line 2624 "configure"
Patrik Stridvall24110281999-02-04 10:09:54 +00002624#include "confdefs.h"
2625/* Override any gcc2 internal prototype to avoid an error. */
2626/* We use char because int might match the return type of a gcc2
2627 builtin and then its argument prototype would still apply. */
2628char XpmCreatePixmapFromData();
2629
2630int main() {
2631XpmCreatePixmapFromData()
2632; return 0; }
2633EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002634if { (eval echo configure:2635: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Patrik Stridvall24110281999-02-04 10:09:54 +00002635 rm -rf conftest*
2636 eval "ac_cv_lib_$ac_lib_var=yes"
2637else
2638 echo "configure: failed program was:" >&5
2639 cat conftest.$ac_ext >&5
2640 rm -rf conftest*
2641 eval "ac_cv_lib_$ac_lib_var=no"
2642fi
2643rm -f conftest*
2644LIBS="$ac_save_LIBS"
2645
2646fi
2647if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2648 echo "$ac_t""yes" 1>&6
2649 cat >> confdefs.h <<\EOF
2650#define HAVE_LIBXXPM 1
2651EOF
2652 X_PRE_LIBS="$X_PRE_LIBS -lXpm"
2653else
2654 echo "$ac_t""no" 1>&6
2655fi
2656
2657 fi
2658
2659 for ac_hdr in X11/Xlib.h X11/extensions/XShm.h
2660do
2661ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2662echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002663echo "configure:2664: checking for $ac_hdr" >&5
Patrik Stridvall24110281999-02-04 10:09:54 +00002664if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2665 echo $ac_n "(cached) $ac_c" 1>&6
2666else
2667 cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002668#line 2669 "configure"
Patrik Stridvall24110281999-02-04 10:09:54 +00002669#include "confdefs.h"
2670#include <$ac_hdr>
2671EOF
2672ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002673{ (eval echo configure:2674: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
Patrik Stridvall24110281999-02-04 10:09:54 +00002674ac_err=`grep -v '^ *+' conftest.out`
2675if test -z "$ac_err"; then
2676 rm -rf conftest*
2677 eval "ac_cv_header_$ac_safe=yes"
2678else
2679 echo "$ac_err" >&5
2680 echo "configure: failed program was:" >&5
2681 cat conftest.$ac_ext >&5
2682 rm -rf conftest*
2683 eval "ac_cv_header_$ac_safe=no"
2684fi
2685rm -f conftest*
2686fi
2687if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2688 echo "$ac_t""yes" 1>&6
2689 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2690 cat >> confdefs.h <<EOF
2691#define $ac_tr_hdr 1
2692EOF
2693
2694else
2695 echo "$ac_t""no" 1>&6
2696fi
2697done
2698
2699 if test "$ac_cv_header_X11_Xlib_h" = "yes" -a "$ac_cv_header_X11_extensions_XShm_h" = "yes"
2700 then
2701 echo $ac_n "checking for XShmQueryExtension in -lXext""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002702echo "configure:2703: checking for XShmQueryExtension in -lXext" >&5
Patrik Stridvall24110281999-02-04 10:09:54 +00002703ac_lib_var=`echo Xext'_'XShmQueryExtension | sed 'y%./+-%__p_%'`
2704if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2705 echo $ac_n "(cached) $ac_c" 1>&6
2706else
2707 ac_save_LIBS="$LIBS"
2708LIBS="-lXext $X_LIBS -lXext -lX11 $LIBS"
2709cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002710#line 2711 "configure"
Patrik Stridvall24110281999-02-04 10:09:54 +00002711#include "confdefs.h"
2712/* Override any gcc2 internal prototype to avoid an error. */
2713/* We use char because int might match the return type of a gcc2
2714 builtin and then its argument prototype would still apply. */
2715char XShmQueryExtension();
2716
2717int main() {
2718XShmQueryExtension()
2719; return 0; }
2720EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002721if { (eval echo configure:2722: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Patrik Stridvall24110281999-02-04 10:09:54 +00002722 rm -rf conftest*
2723 eval "ac_cv_lib_$ac_lib_var=yes"
2724else
2725 echo "configure: failed program was:" >&5
2726 cat conftest.$ac_ext >&5
2727 rm -rf conftest*
2728 eval "ac_cv_lib_$ac_lib_var=no"
2729fi
2730rm -f conftest*
2731LIBS="$ac_save_LIBS"
2732
2733fi
2734if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2735 echo "$ac_t""yes" 1>&6
2736 cat >> confdefs.h <<\EOF
2737#define HAVE_LIBXXSHM 1
2738EOF
2739
2740else
2741 echo "$ac_t""no" 1>&6
2742fi
2743
2744 fi
2745 for ac_hdr in X11/Xlib.h X11/extensions/xf86dga.h
2746do
2747ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2748echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002749echo "configure:2750: checking for $ac_hdr" >&5
Patrik Stridvall24110281999-02-04 10:09:54 +00002750if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2751 echo $ac_n "(cached) $ac_c" 1>&6
2752else
2753 cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002754#line 2755 "configure"
Patrik Stridvall24110281999-02-04 10:09:54 +00002755#include "confdefs.h"
2756#include <$ac_hdr>
2757EOF
2758ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002759{ (eval echo configure:2760: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
Patrik Stridvall24110281999-02-04 10:09:54 +00002760ac_err=`grep -v '^ *+' conftest.out`
2761if test -z "$ac_err"; then
2762 rm -rf conftest*
2763 eval "ac_cv_header_$ac_safe=yes"
2764else
2765 echo "$ac_err" >&5
2766 echo "configure: failed program was:" >&5
2767 cat conftest.$ac_ext >&5
2768 rm -rf conftest*
2769 eval "ac_cv_header_$ac_safe=no"
2770fi
2771rm -f conftest*
2772fi
2773if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2774 echo "$ac_t""yes" 1>&6
2775 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2776 cat >> confdefs.h <<EOF
2777#define $ac_tr_hdr 1
2778EOF
2779
2780else
2781 echo "$ac_t""no" 1>&6
2782fi
2783done
2784
2785 if test "$ac_cv_header_X11_Xlib_h" = "yes" -a "$ac_cv_header_X11_extensions_xf86dga_h" = "yes"
2786 then
2787 echo $ac_n "checking for XF86DGAQueryExtension in -lXxf86dga""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002788echo "configure:2789: checking for XF86DGAQueryExtension in -lXxf86dga" >&5
Patrik Stridvall24110281999-02-04 10:09:54 +00002789ac_lib_var=`echo Xxf86dga'_'XF86DGAQueryExtension | sed 'y%./+-%__p_%'`
2790if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2791 echo $ac_n "(cached) $ac_c" 1>&6
2792else
2793 ac_save_LIBS="$LIBS"
2794LIBS="-lXxf86dga $X_LIBS -lXext -lX11 $LIBS"
2795cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002796#line 2797 "configure"
Patrik Stridvall24110281999-02-04 10:09:54 +00002797#include "confdefs.h"
2798/* Override any gcc2 internal prototype to avoid an error. */
2799/* We use char because int might match the return type of a gcc2
2800 builtin and then its argument prototype would still apply. */
2801char XF86DGAQueryExtension();
2802
2803int main() {
2804XF86DGAQueryExtension()
2805; return 0; }
2806EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002807if { (eval echo configure:2808: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Patrik Stridvall24110281999-02-04 10:09:54 +00002808 rm -rf conftest*
2809 eval "ac_cv_lib_$ac_lib_var=yes"
2810else
2811 echo "configure: failed program was:" >&5
2812 cat conftest.$ac_ext >&5
2813 rm -rf conftest*
2814 eval "ac_cv_lib_$ac_lib_var=no"
2815fi
2816rm -f conftest*
2817LIBS="$ac_save_LIBS"
2818
2819fi
2820if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2821 echo "$ac_t""yes" 1>&6
2822 cat >> confdefs.h <<\EOF
2823#define HAVE_LIBXXF86DGA 1
2824EOF
2825 X_PRE_LIBS="$X_PRE_LIBS -lXxf86dga"
2826else
2827 echo "$ac_t""no" 1>&6
2828fi
2829
2830 fi
2831
2832 for ac_hdr in X11/Xlib.h X11/extensions/xf86vmode.h
2833do
2834ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2835echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002836echo "configure:2837: checking for $ac_hdr" >&5
Patrik Stridvall24110281999-02-04 10:09:54 +00002837if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2838 echo $ac_n "(cached) $ac_c" 1>&6
2839else
2840 cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002841#line 2842 "configure"
Patrik Stridvall24110281999-02-04 10:09:54 +00002842#include "confdefs.h"
2843#include <$ac_hdr>
2844EOF
2845ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002846{ (eval echo configure:2847: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
Patrik Stridvall24110281999-02-04 10:09:54 +00002847ac_err=`grep -v '^ *+' conftest.out`
2848if test -z "$ac_err"; then
2849 rm -rf conftest*
2850 eval "ac_cv_header_$ac_safe=yes"
2851else
2852 echo "$ac_err" >&5
2853 echo "configure: failed program was:" >&5
2854 cat conftest.$ac_ext >&5
2855 rm -rf conftest*
2856 eval "ac_cv_header_$ac_safe=no"
2857fi
2858rm -f conftest*
2859fi
2860if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2861 echo "$ac_t""yes" 1>&6
2862 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2863 cat >> confdefs.h <<EOF
2864#define $ac_tr_hdr 1
2865EOF
2866
2867else
2868 echo "$ac_t""no" 1>&6
2869fi
2870done
2871
2872 if test "$ac_cv_header_X11_Xlib_h" = "yes" -a "$ac_cv_header_X11_extensions_xf86vmode_h" = "yes"
2873 then
2874 echo $ac_n "checking for XF86VidModeQueryExtension in -lXxf86vm""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002875echo "configure:2876: checking for XF86VidModeQueryExtension in -lXxf86vm" >&5
Patrik Stridvall24110281999-02-04 10:09:54 +00002876ac_lib_var=`echo Xxf86vm'_'XF86VidModeQueryExtension | sed 'y%./+-%__p_%'`
2877if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2878 echo $ac_n "(cached) $ac_c" 1>&6
2879else
2880 ac_save_LIBS="$LIBS"
2881LIBS="-lXxf86vm $X_LIBS -lXext -lX11 $LIBS"
2882cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002883#line 2884 "configure"
Patrik Stridvall24110281999-02-04 10:09:54 +00002884#include "confdefs.h"
2885/* Override any gcc2 internal prototype to avoid an error. */
2886/* We use char because int might match the return type of a gcc2
2887 builtin and then its argument prototype would still apply. */
2888char XF86VidModeQueryExtension();
2889
2890int main() {
2891XF86VidModeQueryExtension()
2892; return 0; }
2893EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002894if { (eval echo configure:2895: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Patrik Stridvall24110281999-02-04 10:09:54 +00002895 rm -rf conftest*
2896 eval "ac_cv_lib_$ac_lib_var=yes"
2897else
2898 echo "configure: failed program was:" >&5
2899 cat conftest.$ac_ext >&5
2900 rm -rf conftest*
2901 eval "ac_cv_lib_$ac_lib_var=no"
2902fi
2903rm -f conftest*
2904LIBS="$ac_save_LIBS"
2905
2906fi
2907if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2908 echo "$ac_t""yes" 1>&6
2909 cat >> confdefs.h <<\EOF
2910#define HAVE_LIBXXF86VM 1
2911EOF
2912 X_PRE_LIBS="$X_PRE_LIBS -lXxf86vm"
2913else
2914 echo "$ac_t""no" 1>&6
2915fi
2916
2917 fi
Lionel Ulmer5c085701999-02-28 19:48:53 +00002918
Patrik Stridvall24110281999-02-04 10:09:54 +00002919 for ac_hdr in GL/gl.h GL/osmesa.h
2920do
2921ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2922echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002923echo "configure:2924: checking for $ac_hdr" >&5
Patrik Stridvall24110281999-02-04 10:09:54 +00002924if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2925 echo $ac_n "(cached) $ac_c" 1>&6
2926else
2927 cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002928#line 2929 "configure"
Patrik Stridvall24110281999-02-04 10:09:54 +00002929#include "confdefs.h"
2930#include <$ac_hdr>
2931EOF
2932ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002933{ (eval echo configure:2934: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
Patrik Stridvall24110281999-02-04 10:09:54 +00002934ac_err=`grep -v '^ *+' conftest.out`
2935if test -z "$ac_err"; then
2936 rm -rf conftest*
2937 eval "ac_cv_header_$ac_safe=yes"
2938else
2939 echo "$ac_err" >&5
2940 echo "configure: failed program was:" >&5
2941 cat conftest.$ac_ext >&5
2942 rm -rf conftest*
2943 eval "ac_cv_header_$ac_safe=no"
2944fi
2945rm -f conftest*
2946fi
2947if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2948 echo "$ac_t""yes" 1>&6
2949 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2950 cat >> confdefs.h <<EOF
2951#define $ac_tr_hdr 1
2952EOF
2953
2954else
2955 echo "$ac_t""no" 1>&6
2956fi
2957done
2958
2959 if test "$ac_cv_header_GL_gl_h" = "yes" -a "$ac_cv_header_GL_osmesa_h" = "yes"
2960 then
Lionel Ulmer5c085701999-02-28 19:48:53 +00002961 echo $ac_n "checking "for up-to-date Mesa version"""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002962echo "configure:2963: checking "for up-to-date Mesa version"" >&5
Lionel Ulmer5c085701999-02-28 19:48:53 +00002963if eval "test \"`echo '$''{'wine_cv_mesa_version_OK'+set}'`\" = set"; then
2964 echo $ac_n "(cached) $ac_c" 1>&6
2965else
2966 cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002967#line 2968 "configure"
Lionel Ulmer5c085701999-02-28 19:48:53 +00002968#include "confdefs.h"
2969#include <GL/gl.h>
2970int main() {
2971GLenum test = GL_UNSIGNED_SHORT_5_6_5;
2972; return 0; }
2973EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002974if { (eval echo configure:2975: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Lionel Ulmer5c085701999-02-28 19:48:53 +00002975 rm -rf conftest*
2976 wine_cv_mesa_version_OK="yes"
2977else
2978 echo "configure: failed program was:" >&5
2979 cat conftest.$ac_ext >&5
2980 rm -rf conftest*
2981 wine_cv_mesa_version_OK="no"
2982
2983fi
2984rm -f conftest*
2985
2986fi
2987
2988echo "$ac_t""$wine_cv_mesa_version_OK" 1>&6
2989
2990 if test "$wine_cv_mesa_version_OK" = "yes"
2991 then
2992 echo $ac_n "checking for OSMesaCreateContext in -lMesaGL""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00002993echo "configure:2994: checking for OSMesaCreateContext in -lMesaGL" >&5
Patrik Stridvall24110281999-02-04 10:09:54 +00002994ac_lib_var=`echo MesaGL'_'OSMesaCreateContext | sed 'y%./+-%__p_%'`
2995if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2996 echo $ac_n "(cached) $ac_c" 1>&6
2997else
2998 ac_save_LIBS="$LIBS"
2999LIBS="-lMesaGL $X_LIBS -lXext -lX11 -lm $LIBS"
3000cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003001#line 3002 "configure"
Patrik Stridvall24110281999-02-04 10:09:54 +00003002#include "confdefs.h"
3003/* Override any gcc2 internal prototype to avoid an error. */
3004/* We use char because int might match the return type of a gcc2
3005 builtin and then its argument prototype would still apply. */
3006char OSMesaCreateContext();
3007
3008int main() {
3009OSMesaCreateContext()
3010; return 0; }
3011EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003012if { (eval echo configure:3013: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Patrik Stridvall24110281999-02-04 10:09:54 +00003013 rm -rf conftest*
3014 eval "ac_cv_lib_$ac_lib_var=yes"
3015else
3016 echo "configure: failed program was:" >&5
3017 cat conftest.$ac_ext >&5
3018 rm -rf conftest*
3019 eval "ac_cv_lib_$ac_lib_var=no"
3020fi
3021rm -f conftest*
3022LIBS="$ac_save_LIBS"
3023
3024fi
3025if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3026 echo "$ac_t""yes" 1>&6
3027 cat >> confdefs.h <<\EOF
3028#define HAVE_LIBMESAGL 1
3029EOF
3030 X_PRE_LIBS="$X_PRE_LIBS -lMesaGL"
3031else
3032 echo "$ac_t""no" 1>&6
3033fi
3034
Lionel Ulmer5c085701999-02-28 19:48:53 +00003035 fi
Patrik Stridvall24110281999-02-04 10:09:54 +00003036 fi
Ove Kaaven1eb593c1999-02-14 09:34:46 +00003037
3038 CPPFLAGS="$ac_save_CPPFLAGS"
Patrik Stridvallea584721998-11-01 16:22:07 +00003039else
3040 XLIB=""
3041 X_CFLAGS=""
3042 X_LIBS=""
3043fi
Alexandre Julliard902da691995-11-05 14:39:02 +00003044
Patrik Stridvall24110281999-02-04 10:09:54 +00003045for ac_hdr in ncurses.h
3046do
3047ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
3048echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003049echo "configure:3050: checking for $ac_hdr" >&5
Patrik Stridvall24110281999-02-04 10:09:54 +00003050if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3051 echo $ac_n "(cached) $ac_c" 1>&6
3052else
3053 cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003054#line 3055 "configure"
Patrik Stridvall24110281999-02-04 10:09:54 +00003055#include "confdefs.h"
3056#include <$ac_hdr>
3057EOF
3058ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003059{ (eval echo configure:3060: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
Patrik Stridvall24110281999-02-04 10:09:54 +00003060ac_err=`grep -v '^ *+' conftest.out`
3061if test -z "$ac_err"; then
3062 rm -rf conftest*
3063 eval "ac_cv_header_$ac_safe=yes"
3064else
3065 echo "$ac_err" >&5
3066 echo "configure: failed program was:" >&5
3067 cat conftest.$ac_ext >&5
3068 rm -rf conftest*
3069 eval "ac_cv_header_$ac_safe=no"
3070fi
3071rm -f conftest*
3072fi
3073if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3074 echo "$ac_t""yes" 1>&6
3075 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
3076 cat >> confdefs.h <<EOF
3077#define $ac_tr_hdr 1
3078EOF
3079
3080else
3081 echo "$ac_t""no" 1>&6
3082fi
3083done
3084
3085if test "$ac_cv_header_ncurses_h" = "yes"
3086then
3087 echo $ac_n "checking for waddch in -lncurses""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003088echo "configure:3089: checking for waddch in -lncurses" >&5
Joseph Praneviche884f9c1999-01-03 16:14:34 +00003089ac_lib_var=`echo ncurses'_'waddch | sed 'y%./+-%__p_%'`
3090if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3091 echo $ac_n "(cached) $ac_c" 1>&6
3092else
3093 ac_save_LIBS="$LIBS"
3094LIBS="-lncurses $LIBS"
3095cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003096#line 3097 "configure"
Joseph Praneviche884f9c1999-01-03 16:14:34 +00003097#include "confdefs.h"
3098/* Override any gcc2 internal prototype to avoid an error. */
3099/* We use char because int might match the return type of a gcc2
3100 builtin and then its argument prototype would still apply. */
3101char waddch();
3102
3103int main() {
3104waddch()
3105; return 0; }
3106EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003107if { (eval echo configure:3108: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Joseph Praneviche884f9c1999-01-03 16:14:34 +00003108 rm -rf conftest*
3109 eval "ac_cv_lib_$ac_lib_var=yes"
3110else
3111 echo "configure: failed program was:" >&5
3112 cat conftest.$ac_ext >&5
3113 rm -rf conftest*
3114 eval "ac_cv_lib_$ac_lib_var=no"
3115fi
3116rm -f conftest*
3117LIBS="$ac_save_LIBS"
3118
3119fi
3120if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3121 echo "$ac_t""yes" 1>&6
3122 ac_tr_lib=HAVE_LIB`echo ncurses | sed -e 's/[^a-zA-Z0-9_]/_/g' \
3123 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
3124 cat >> confdefs.h <<EOF
3125#define $ac_tr_lib 1
3126EOF
3127
3128 LIBS="-lncurses $LIBS"
3129
3130else
3131 echo "$ac_t""no" 1>&6
3132fi
3133
Patrik Stridvall24110281999-02-04 10:09:54 +00003134fi
Joseph Praneviche884f9c1999-01-03 16:14:34 +00003135if test "$ac_cv_lib_ncurses_waddch" = "yes"
Alexandre Julliard638f1691999-01-17 16:32:32 +00003136then
3137 echo $ac_n "checking for resizeterm in -lncurses""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003138echo "configure:3139: checking for resizeterm in -lncurses" >&5
Alexandre Julliard638f1691999-01-17 16:32:32 +00003139ac_lib_var=`echo ncurses'_'resizeterm | sed 'y%./+-%__p_%'`
3140if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3141 echo $ac_n "(cached) $ac_c" 1>&6
3142else
3143 ac_save_LIBS="$LIBS"
3144LIBS="-lncurses $LIBS"
3145cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003146#line 3147 "configure"
Alexandre Julliard638f1691999-01-17 16:32:32 +00003147#include "confdefs.h"
3148/* Override any gcc2 internal prototype to avoid an error. */
3149/* We use char because int might match the return type of a gcc2
3150 builtin and then its argument prototype would still apply. */
3151char resizeterm();
3152
3153int main() {
3154resizeterm()
3155; return 0; }
3156EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003157if { (eval echo configure:3158: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Alexandre Julliard638f1691999-01-17 16:32:32 +00003158 rm -rf conftest*
3159 eval "ac_cv_lib_$ac_lib_var=yes"
3160else
3161 echo "configure: failed program was:" >&5
3162 cat conftest.$ac_ext >&5
3163 rm -rf conftest*
3164 eval "ac_cv_lib_$ac_lib_var=no"
3165fi
3166rm -f conftest*
3167LIBS="$ac_save_LIBS"
3168
3169fi
3170if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3171 echo "$ac_t""yes" 1>&6
3172 cat >> confdefs.h <<\EOF
3173#define HAVE_RESIZETERM 1
3174EOF
3175
3176else
3177 echo "$ac_t""no" 1>&6
3178fi
3179
Michael Vekslerf5445071999-02-25 17:11:05 +00003180 echo $ac_n "checking for getbkgd in -lncurses""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003181echo "configure:3182: checking for getbkgd in -lncurses" >&5
Michael Vekslerf5445071999-02-25 17:11:05 +00003182ac_lib_var=`echo ncurses'_'getbkgd | sed 'y%./+-%__p_%'`
3183if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3184 echo $ac_n "(cached) $ac_c" 1>&6
3185else
3186 ac_save_LIBS="$LIBS"
3187LIBS="-lncurses $LIBS"
3188cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003189#line 3190 "configure"
Michael Vekslerf5445071999-02-25 17:11:05 +00003190#include "confdefs.h"
3191/* Override any gcc2 internal prototype to avoid an error. */
3192/* We use char because int might match the return type of a gcc2
3193 builtin and then its argument prototype would still apply. */
3194char getbkgd();
3195
3196int main() {
3197getbkgd()
3198; return 0; }
3199EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003200if { (eval echo configure:3201: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Michael Vekslerf5445071999-02-25 17:11:05 +00003201 rm -rf conftest*
3202 eval "ac_cv_lib_$ac_lib_var=yes"
3203else
3204 echo "configure: failed program was:" >&5
3205 cat conftest.$ac_ext >&5
3206 rm -rf conftest*
3207 eval "ac_cv_lib_$ac_lib_var=no"
3208fi
3209rm -f conftest*
3210LIBS="$ac_save_LIBS"
3211
3212fi
3213if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3214 echo "$ac_t""yes" 1>&6
3215 cat >> confdefs.h <<\EOF
3216#define HAVE_GETBKGD 1
3217EOF
3218
3219else
3220 echo "$ac_t""no" 1>&6
3221fi
3222
Joseph Praneviche884f9c1999-01-03 16:14:34 +00003223else
Patrik Stridvall24110281999-02-04 10:09:54 +00003224 for ac_hdr in curses.h
3225do
3226ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
3227echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003228echo "configure:3229: checking for $ac_hdr" >&5
Patrik Stridvall24110281999-02-04 10:09:54 +00003229if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3230 echo $ac_n "(cached) $ac_c" 1>&6
3231else
3232 cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003233#line 3234 "configure"
Patrik Stridvall24110281999-02-04 10:09:54 +00003234#include "confdefs.h"
3235#include <$ac_hdr>
3236EOF
3237ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003238{ (eval echo configure:3239: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
Patrik Stridvall24110281999-02-04 10:09:54 +00003239ac_err=`grep -v '^ *+' conftest.out`
3240if test -z "$ac_err"; then
3241 rm -rf conftest*
3242 eval "ac_cv_header_$ac_safe=yes"
3243else
3244 echo "$ac_err" >&5
3245 echo "configure: failed program was:" >&5
3246 cat conftest.$ac_ext >&5
3247 rm -rf conftest*
3248 eval "ac_cv_header_$ac_safe=no"
3249fi
3250rm -f conftest*
3251fi
3252if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3253 echo "$ac_t""yes" 1>&6
3254 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
3255 cat >> confdefs.h <<EOF
3256#define $ac_tr_hdr 1
3257EOF
3258
3259else
3260 echo "$ac_t""no" 1>&6
3261fi
3262done
3263
3264 if test "$ac_cv_header_curses_h" = "yes"
3265 then
3266 echo $ac_n "checking for waddch in -lcurses""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003267echo "configure:3268: checking for waddch in -lcurses" >&5
Joseph Praneviche884f9c1999-01-03 16:14:34 +00003268ac_lib_var=`echo curses'_'waddch | sed 'y%./+-%__p_%'`
3269if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3270 echo $ac_n "(cached) $ac_c" 1>&6
3271else
3272 ac_save_LIBS="$LIBS"
3273LIBS="-lcurses $LIBS"
3274cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003275#line 3276 "configure"
Joseph Praneviche884f9c1999-01-03 16:14:34 +00003276#include "confdefs.h"
3277/* Override any gcc2 internal prototype to avoid an error. */
3278/* We use char because int might match the return type of a gcc2
3279 builtin and then its argument prototype would still apply. */
3280char waddch();
3281
3282int main() {
3283waddch()
3284; return 0; }
3285EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003286if { (eval echo configure:3287: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Joseph Praneviche884f9c1999-01-03 16:14:34 +00003287 rm -rf conftest*
3288 eval "ac_cv_lib_$ac_lib_var=yes"
3289else
3290 echo "configure: failed program was:" >&5
3291 cat conftest.$ac_ext >&5
3292 rm -rf conftest*
3293 eval "ac_cv_lib_$ac_lib_var=no"
3294fi
3295rm -f conftest*
3296LIBS="$ac_save_LIBS"
3297
3298fi
3299if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3300 echo "$ac_t""yes" 1>&6
3301 ac_tr_lib=HAVE_LIB`echo curses | sed -e 's/[^a-zA-Z0-9_]/_/g' \
3302 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
3303 cat >> confdefs.h <<EOF
3304#define $ac_tr_lib 1
3305EOF
3306
3307 LIBS="-lcurses $LIBS"
3308
3309else
3310 echo "$ac_t""no" 1>&6
3311fi
3312
Patrik Stridvall24110281999-02-04 10:09:54 +00003313 echo $ac_n "checking for resizeterm in -lcurses""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003314echo "configure:3315: checking for resizeterm in -lcurses" >&5
Alexandre Julliard638f1691999-01-17 16:32:32 +00003315ac_lib_var=`echo curses'_'resizeterm | sed 'y%./+-%__p_%'`
3316if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3317 echo $ac_n "(cached) $ac_c" 1>&6
3318else
3319 ac_save_LIBS="$LIBS"
3320LIBS="-lcurses $LIBS"
3321cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003322#line 3323 "configure"
Alexandre Julliard638f1691999-01-17 16:32:32 +00003323#include "confdefs.h"
3324/* Override any gcc2 internal prototype to avoid an error. */
3325/* We use char because int might match the return type of a gcc2
3326 builtin and then its argument prototype would still apply. */
3327char resizeterm();
3328
3329int main() {
3330resizeterm()
3331; return 0; }
3332EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003333if { (eval echo configure:3334: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Alexandre Julliard638f1691999-01-17 16:32:32 +00003334 rm -rf conftest*
3335 eval "ac_cv_lib_$ac_lib_var=yes"
3336else
3337 echo "configure: failed program was:" >&5
3338 cat conftest.$ac_ext >&5
3339 rm -rf conftest*
3340 eval "ac_cv_lib_$ac_lib_var=no"
3341fi
3342rm -f conftest*
3343LIBS="$ac_save_LIBS"
3344
3345fi
3346if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3347 echo "$ac_t""yes" 1>&6
3348 cat >> confdefs.h <<\EOF
3349#define HAVE_RESIZETERM 1
3350EOF
3351
3352else
3353 echo "$ac_t""no" 1>&6
3354fi
3355
Michael Vekslerf5445071999-02-25 17:11:05 +00003356 echo $ac_n "checking for getbkgd in -lcurses""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003357echo "configure:3358: checking for getbkgd in -lcurses" >&5
Michael Vekslerf5445071999-02-25 17:11:05 +00003358ac_lib_var=`echo curses'_'getbkgd | sed 'y%./+-%__p_%'`
3359if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3360 echo $ac_n "(cached) $ac_c" 1>&6
3361else
3362 ac_save_LIBS="$LIBS"
3363LIBS="-lcurses $LIBS"
3364cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003365#line 3366 "configure"
Michael Vekslerf5445071999-02-25 17:11:05 +00003366#include "confdefs.h"
3367/* Override any gcc2 internal prototype to avoid an error. */
3368/* We use char because int might match the return type of a gcc2
3369 builtin and then its argument prototype would still apply. */
3370char getbkgd();
3371
3372int main() {
3373getbkgd()
3374; return 0; }
3375EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003376if { (eval echo configure:3377: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Michael Vekslerf5445071999-02-25 17:11:05 +00003377 rm -rf conftest*
3378 eval "ac_cv_lib_$ac_lib_var=yes"
3379else
3380 echo "configure: failed program was:" >&5
3381 cat conftest.$ac_ext >&5
3382 rm -rf conftest*
3383 eval "ac_cv_lib_$ac_lib_var=no"
3384fi
3385rm -f conftest*
3386LIBS="$ac_save_LIBS"
3387
3388fi
3389if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3390 echo "$ac_t""yes" 1>&6
3391 cat >> confdefs.h <<\EOF
3392#define HAVE_GETBKGD 1
3393EOF
3394
3395else
3396 echo "$ac_t""no" 1>&6
3397fi
3398
Patrik Stridvall24110281999-02-04 10:09:54 +00003399 fi
Joseph Praneviche884f9c1999-01-03 16:14:34 +00003400fi
3401
Pavel Roskin94d99641998-12-26 11:52:51 +00003402echo $ac_n "checking "for GNU style IPX support"""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003403echo "configure:3404: checking "for GNU style IPX support"" >&5
Pavel Roskin94d99641998-12-26 11:52:51 +00003404if eval "test \"`echo '$''{'ac_cv_c_ipx_gnu'+set}'`\" = set"; then
3405 echo $ac_n "(cached) $ac_c" 1>&6
3406else
3407 cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003408#line 3409 "configure"
Pavel Roskin94d99641998-12-26 11:52:51 +00003409#include "confdefs.h"
3410#include <sys/socket.h>
3411 #include <netipx/ipx.h>
3412int main() {
3413((struct sockaddr_ipx *)0)->sipx_family == AF_IPX
3414; return 0; }
3415EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003416if { (eval echo configure:3417: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Pavel Roskin94d99641998-12-26 11:52:51 +00003417 rm -rf conftest*
3418 cat >> confdefs.h <<\EOF
3419#define HAVE_IPX_GNU 1
3420EOF
3421
3422 ac_cv_c_ipx_gnu="yes"
3423else
3424 echo "configure: failed program was:" >&5
3425 cat conftest.$ac_ext >&5
3426 rm -rf conftest*
3427 ac_cv_c_ipx_gnu="no"
3428fi
3429rm -f conftest*
3430
3431fi
3432
3433echo "$ac_t""$ac_cv_c_ipx_gnu" 1>&6
3434
3435if test "$ac_cv_c_ipx_gnu" = "no"
3436then
3437 echo $ac_n "checking "for linux style IPX support"""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003438echo "configure:3439: checking "for linux style IPX support"" >&5
Pavel Roskin94d99641998-12-26 11:52:51 +00003439if eval "test \"`echo '$''{'ac_cv_c_ipx_linux'+set}'`\" = set"; then
3440 echo $ac_n "(cached) $ac_c" 1>&6
3441else
3442 cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003443#line 3444 "configure"
Pavel Roskin94d99641998-12-26 11:52:51 +00003444#include "confdefs.h"
3445#include <sys/socket.h>
3446 #include <asm/types.h>
3447 #include <linux/ipx.h>
3448int main() {
3449((struct sockaddr_ipx *)0)->sipx_family == AF_IPX
3450; return 0; }
3451EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003452if { (eval echo configure:3453: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Pavel Roskin94d99641998-12-26 11:52:51 +00003453 rm -rf conftest*
3454 cat >> confdefs.h <<\EOF
3455#define HAVE_IPX_LINUX 1
3456EOF
3457
3458 ac_cv_c_ipx_linux="yes"
3459else
3460 echo "configure: failed program was:" >&5
3461 cat conftest.$ac_ext >&5
3462 rm -rf conftest*
3463 ac_cv_c_ipx_linux="no"
3464fi
3465rm -f conftest*
3466
3467fi
3468
3469echo "$ac_t""$ac_cv_c_ipx_linux" 1>&6
3470fi
3471
Todd Vierlingecc76691998-12-15 17:49:02 +00003472for ac_hdr in sys/soundcard.h machine/soundcard.h soundcard.h
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00003473do
3474ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
3475echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003476echo "configure:3477: checking for $ac_hdr" >&5
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00003477if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3478 echo $ac_n "(cached) $ac_c" 1>&6
3479else
3480 cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003481#line 3482 "configure"
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00003482#include "confdefs.h"
3483#include <$ac_hdr>
3484EOF
3485ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003486{ (eval echo configure:3487: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00003487ac_err=`grep -v '^ *+' conftest.out`
3488if test -z "$ac_err"; then
3489 rm -rf conftest*
3490 eval "ac_cv_header_$ac_safe=yes"
3491else
3492 echo "$ac_err" >&5
3493 echo "configure: failed program was:" >&5
3494 cat conftest.$ac_ext >&5
3495 rm -rf conftest*
3496 eval "ac_cv_header_$ac_safe=no"
3497fi
3498rm -f conftest*
3499fi
3500if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3501 echo "$ac_t""yes" 1>&6
3502 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
3503 cat >> confdefs.h <<EOF
3504#define $ac_tr_hdr 1
3505EOF
Todd Vierlingecc76691998-12-15 17:49:02 +00003506 break
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00003507else
3508 echo "$ac_t""no" 1>&6
3509fi
3510done
3511
Alexandre Julliard0623a6f1998-01-18 18:01:49 +00003512
3513echo $ac_n "checking "for Open Sound System"""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003514echo "configure:3515: checking "for Open Sound System"" >&5
Alexandre Julliard0623a6f1998-01-18 18:01:49 +00003515if eval "test \"`echo '$''{'ac_cv_c_opensoundsystem'+set}'`\" = set"; then
3516 echo $ac_n "(cached) $ac_c" 1>&6
3517else
3518 cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003519#line 3520 "configure"
Alexandre Julliard0623a6f1998-01-18 18:01:49 +00003520#include "confdefs.h"
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00003521
Todd Vierlingecc76691998-12-15 17:49:02 +00003522 #if defined(HAVE_SYS_SOUNDCARD_H)
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00003523 #include <sys/soundcard.h>
Todd Vierlingecc76691998-12-15 17:49:02 +00003524 #elif defined(HAVE_MACHINE_SOUNDCARD_H)
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00003525 #include <machine/soundcard.h>
Todd Vierlingecc76691998-12-15 17:49:02 +00003526 #elif defined(HAVE_SOUNDCARD_H)
3527 #include <soundcard.h>
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00003528 #endif
3529
Alexandre Julliard0623a6f1998-01-18 18:01:49 +00003530int main() {
3531
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00003532
Alexandre Julliard60ce85c1998-02-01 18:33:27 +00003533/* check for one of the Open Sound System specific SNDCTL_ defines */
3534#if !defined(SNDCTL_DSP_STEREO)
Alexandre Julliard0623a6f1998-01-18 18:01:49 +00003535#error No open sound system
3536#endif
3537
3538; return 0; }
3539EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003540if { (eval echo configure:3541: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Alexandre Julliard0623a6f1998-01-18 18:01:49 +00003541 rm -rf conftest*
3542 ac_cv_c_opensoundsystem="yes"
3543else
3544 echo "configure: failed program was:" >&5
3545 cat conftest.$ac_ext >&5
3546 rm -rf conftest*
3547 ac_cv_c_opensoundsystem="no"
3548fi
3549rm -f conftest*
3550fi
3551
3552echo "$ac_t""$ac_cv_c_opensoundsystem" 1>&6
3553
Alexandre Julliarddadf78f1998-05-17 17:13:43 +00003554if test "$ac_cv_c_opensoundsystem" = "yes"
3555then
3556 cat >> confdefs.h <<\EOF
3557#define HAVE_OSS 1
3558EOF
3559
3560fi
3561
Alexandre Julliard641ee761997-08-04 16:34:36 +00003562if test "$ac_cv_prog_LN_S" = "ln -s"; then : ; else LN_S=cp ; fi
3563
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00003564
Alexandre Julliard4f8c37b1996-01-14 18:12:01 +00003565if test "x${GCC}" = "xyes"
3566then
3567 CFLAGS="$CFLAGS -Wall"
Alexandre Julliard4f8c37b1996-01-14 18:12:01 +00003568 echo $ac_n "checking "for gcc strength-reduce bug"""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003569echo "configure:3570: checking "for gcc strength-reduce bug"" >&5
Alexandre Julliard4f8c37b1996-01-14 18:12:01 +00003570if eval "test \"`echo '$''{'ac_cv_c_gcc_strength_bug'+set}'`\" = set"; then
3571 echo $ac_n "(cached) $ac_c" 1>&6
3572else
3573 if test "$cross_compiling" = yes; then
3574 ac_cv_c_gcc_strength_bug="yes"
3575else
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00003576 cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003577#line 3578 "configure"
Alexandre Julliard4f8c37b1996-01-14 18:12:01 +00003578#include "confdefs.h"
3579
3580int main(void) {
Alexandre Julliardd2e1c1a1996-03-09 16:12:43 +00003581 static int Array[3];
Alexandre Julliard4f8c37b1996-01-14 18:12:01 +00003582 unsigned int B = 3;
3583 int i;
Alexandre Julliardd2e1c1a1996-03-09 16:12:43 +00003584 for(i=0; i<B; i++) Array[i] = i - 3;
3585 exit( Array[1] != -2 );
Alexandre Julliard4f8c37b1996-01-14 18:12:01 +00003586}
3587EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003588if { (eval echo configure:3589: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +00003589then
Alexandre Julliard4f8c37b1996-01-14 18:12:01 +00003590 ac_cv_c_gcc_strength_bug="no"
3591else
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00003592 echo "configure: failed program was:" >&5
3593 cat conftest.$ac_ext >&5
3594 rm -fr conftest*
Alexandre Julliard4f8c37b1996-01-14 18:12:01 +00003595 ac_cv_c_gcc_strength_bug="yes"
3596fi
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00003597rm -fr conftest*
Alexandre Julliard4f8c37b1996-01-14 18:12:01 +00003598fi
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00003599
Alexandre Julliard4f8c37b1996-01-14 18:12:01 +00003600fi
3601
3602echo "$ac_t""$ac_cv_c_gcc_strength_bug" 1>&6
3603 if test "$ac_cv_c_gcc_strength_bug" = "yes"
3604 then
3605 CFLAGS="$CFLAGS -fno-strength-reduce"
3606 fi
3607fi
3608
3609
Alexandre Julliard8cc3a5e1996-08-11 15:49:51 +00003610echo $ac_n "checking "whether external symbols need an underscore prefix"""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003611echo "configure:3612: checking "whether external symbols need an underscore prefix"" >&5
Alexandre Julliard8cc3a5e1996-08-11 15:49:51 +00003612if eval "test \"`echo '$''{'ac_cv_c_extern_prefix'+set}'`\" = set"; then
3613 echo $ac_n "(cached) $ac_c" 1>&6
3614else
3615 saved_libs=$LIBS
3616LIBS="conftest_asm.s $LIBS"
3617cat > conftest_asm.s <<EOF
3618 .globl _ac_test
3619_ac_test:
3620 .long 0
3621EOF
3622cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003623#line 3624 "configure"
Alexandre Julliard8cc3a5e1996-08-11 15:49:51 +00003624#include "confdefs.h"
3625extern int ac_test;
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00003626int main() {
Alexandre Julliard8cc3a5e1996-08-11 15:49:51 +00003627if (ac_test) return 1
3628; return 0; }
3629EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003630if { (eval echo configure:3631: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Alexandre Julliard8cc3a5e1996-08-11 15:49:51 +00003631 rm -rf conftest*
3632 ac_cv_c_extern_prefix="yes"
3633else
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00003634 echo "configure: failed program was:" >&5
3635 cat conftest.$ac_ext >&5
Alexandre Julliard8cc3a5e1996-08-11 15:49:51 +00003636 rm -rf conftest*
3637 ac_cv_c_extern_prefix="no"
3638fi
3639rm -f conftest*
Alexandre Julliard8cc3a5e1996-08-11 15:49:51 +00003640LIBS=$saved_libs
3641fi
3642
3643echo "$ac_t""$ac_cv_c_extern_prefix" 1>&6
3644if test "$ac_cv_c_extern_prefix" = "yes"
3645then
3646 cat >> confdefs.h <<\EOF
3647#define NEED_UNDERSCORE_PREFIX 1
3648EOF
3649
3650fi
3651
3652
Alexandre Julliard0623a6f1998-01-18 18:01:49 +00003653echo $ac_n "checking "whether assembler accepts .string"""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003654echo "configure:3655: checking "whether assembler accepts .string"" >&5
Alexandre Julliard0623a6f1998-01-18 18:01:49 +00003655if eval "test \"`echo '$''{'ac_cv_c_asm_string'+set}'`\" = set"; then
3656 echo $ac_n "(cached) $ac_c" 1>&6
3657else
3658 saved_libs=$LIBS
3659LIBS="conftest_asm.s $LIBS"
3660cat > conftest_asm.s <<EOF
3661 .string "test"
3662EOF
3663cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003664#line 3665 "configure"
Alexandre Julliard0623a6f1998-01-18 18:01:49 +00003665#include "confdefs.h"
3666
3667int main() {
3668
3669; return 0; }
3670EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003671if { (eval echo configure:3672: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Alexandre Julliard0623a6f1998-01-18 18:01:49 +00003672 rm -rf conftest*
3673 ac_cv_c_asm_string="yes"
3674else
3675 echo "configure: failed program was:" >&5
3676 cat conftest.$ac_ext >&5
3677 rm -rf conftest*
3678 ac_cv_c_asm_string="no"
3679fi
3680rm -f conftest*
3681LIBS=$saved_libs
3682fi
3683
3684echo "$ac_t""$ac_cv_c_asm_string" 1>&6
3685if test "$ac_cv_c_asm_string" = "yes"
3686then
3687 cat >> confdefs.h <<\EOF
3688#define HAVE_ASM_STRING 1
3689EOF
3690
3691fi
3692
3693
Alexandre Julliarda0b2b1d1997-11-16 17:38:29 +00003694DLLFLAGS=""
Todd Vierling4b992b01998-12-15 15:26:27 +00003695LDSHARED=""
Alexandre Julliarda0b2b1d1997-11-16 17:38:29 +00003696if test "$LIB_TARGET" = "libwine.so.1.0"
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +00003697then
Todd Vierling4b992b01998-12-15 15:26:27 +00003698 echo $ac_n "checking "whether we can build a Linux dll"""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003699echo "configure:3700: checking "whether we can build a Linux dll"" >&5
Todd Vierling4b992b01998-12-15 15:26:27 +00003700if eval "test \"`echo '$''{'ac_cv_c_dll_linux'+set}'`\" = set"; then
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +00003701 echo $ac_n "(cached) $ac_c" 1>&6
3702else
3703 saved_cflags=$CFLAGS
3704 CFLAGS="$CFLAGS -fPIC -shared -Wl,-soname,conftest.so.1.0"
3705 cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003706#line 3707 "configure"
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +00003707#include "confdefs.h"
3708
3709int main() {
3710return 1
3711; return 0; }
3712EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003713if { (eval echo configure:3714: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +00003714 rm -rf conftest*
Todd Vierling4b992b01998-12-15 15:26:27 +00003715 ac_cv_c_dll_linux="yes"
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +00003716else
3717 echo "configure: failed program was:" >&5
3718 cat conftest.$ac_ext >&5
3719 rm -rf conftest*
Todd Vierling4b992b01998-12-15 15:26:27 +00003720 ac_cv_c_dll_linux="no"
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +00003721fi
3722rm -f conftest*
3723 CFLAGS=$saved_cflags
3724
3725fi
3726
Todd Vierling4b992b01998-12-15 15:26:27 +00003727echo "$ac_t""$ac_cv_c_dll_linux" 1>&6
3728 if test "$ac_cv_c_dll_linux" = "yes"
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +00003729 then
Alexandre Julliarda0b2b1d1997-11-16 17:38:29 +00003730 DLLFLAGS="-fPIC"
Todd Vierling4b992b01998-12-15 15:26:27 +00003731 LDSHARED="\$(CC) -shared -Wl,-soname,libwine.so"
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +00003732 else
Todd Vierling4b992b01998-12-15 15:26:27 +00003733 echo $ac_n "checking "whether we can build a NetBSD dll"""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003734echo "configure:3735: checking "whether we can build a NetBSD dll"" >&5
Todd Vierling4b992b01998-12-15 15:26:27 +00003735if eval "test \"`echo '$''{'ac_cv_c_dll_netbsd'+set}'`\" = set"; then
3736 echo $ac_n "(cached) $ac_c" 1>&6
3737else
3738 saved_cflags=$CFLAGS
3739 CFLAGS="$CFLAGS -fPIC -Bshareable -Bforcearchive"
3740 cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003741#line 3742 "configure"
Todd Vierling4b992b01998-12-15 15:26:27 +00003742#include "confdefs.h"
3743
3744int main() {
3745return 1
3746; return 0; }
3747EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003748if { (eval echo configure:3749: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Todd Vierling4b992b01998-12-15 15:26:27 +00003749 rm -rf conftest*
3750 ac_cv_c_dll_netbsd="yes"
3751else
3752 echo "configure: failed program was:" >&5
3753 cat conftest.$ac_ext >&5
3754 rm -rf conftest*
3755 ac_cv_c_dll_netbsd="no"
3756fi
3757rm -f conftest*
3758 CFLAGS=$saved_cflags
3759
3760fi
3761
3762echo "$ac_t""$ac_cv_c_dll_netbsd" 1>&6
3763 if test "$ac_cv_c_dll_netbsd" = "yes"
3764 then
3765 DLLFLAGS="-fPIC"
3766 LDSHARED="ld -Bshareable -Bforcearchive"
3767 fi
3768 fi
3769 if test "$ac_cv_c_dll_linux" = "no" -a "$ac_cv_c_dll_netbsd" = "no"
3770 then
Alexandre Julliarda0b2b1d1997-11-16 17:38:29 +00003771 LIB_TARGET="libwine.a"
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +00003772 fi
3773fi
3774
3775
Alexandre Julliarda0b2b1d1997-11-16 17:38:29 +00003776
Todd Vierling4b992b01998-12-15 15:26:27 +00003777
Ulrich Weigand715a55e1999-04-18 13:19:56 +00003778wine_cv_libc_reentrant=no
3779echo $ac_n "checking "for reentrant libc: __errno_location"""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003780echo "configure:3781: checking "for reentrant libc: __errno_location"" >&5
Ulrich Weigand715a55e1999-04-18 13:19:56 +00003781if eval "test \"`echo '$''{'wine_cv_libc_r__errno_location'+set}'`\" = set"; then
Alexandre Julliardd30dfd21998-09-27 18:28:36 +00003782 echo $ac_n "(cached) $ac_c" 1>&6
3783else
3784 if test "$cross_compiling" = yes; then
Ulrich Weigand715a55e1999-04-18 13:19:56 +00003785 wine_cv_libc_r__errno_location=yes
Alexandre Julliardd30dfd21998-09-27 18:28:36 +00003786else
3787 cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003788#line 3789 "configure"
Alexandre Julliardd30dfd21998-09-27 18:28:36 +00003789#include "confdefs.h"
3790int myerrno = 0;
3791char buf[256];
3792int *__errno_location(){return &myerrno;}
3793main(){connect(0,buf,255); exit(!myerrno);}
3794EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003795if { (eval echo configure:3796: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
Alexandre Julliardd30dfd21998-09-27 18:28:36 +00003796then
Ulrich Weigand715a55e1999-04-18 13:19:56 +00003797 wine_cv_libc_r__errno_location=yes
Alexandre Julliardd30dfd21998-09-27 18:28:36 +00003798else
3799 echo "configure: failed program was:" >&5
3800 cat conftest.$ac_ext >&5
3801 rm -fr conftest*
Ulrich Weigand715a55e1999-04-18 13:19:56 +00003802 wine_cv_libc_r__errno_location=no
Alexandre Julliardd30dfd21998-09-27 18:28:36 +00003803fi
3804rm -fr conftest*
3805fi
Marcus Meissnerc2606381999-04-11 15:20:29 +00003806
Ulrich Weigand715a55e1999-04-18 13:19:56 +00003807
3808fi
3809
3810echo "$ac_t""$wine_cv_libc_r__errno_location" 1>&6
3811if test "$wine_cv_libc_r__errno_location" = "yes"
3812then
3813 cat >> confdefs.h <<\EOF
3814#define HAVE__ERRNO_LOCATION 1
3815EOF
3816
3817 wine_cv_libc_reentrant=__errno_location
3818fi
3819echo $ac_n "checking "for reentrant libc: __error"""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003820echo "configure:3821: checking "for reentrant libc: __error"" >&5
Ulrich Weigand715a55e1999-04-18 13:19:56 +00003821if eval "test \"`echo '$''{'wine_cv_libc_r__error'+set}'`\" = set"; then
3822 echo $ac_n "(cached) $ac_c" 1>&6
3823else
3824 if test "$cross_compiling" = yes; then
3825 wine_cv_libc_r__error=yes
Marcus Meissnerc2606381999-04-11 15:20:29 +00003826else
3827 cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003828#line 3829 "configure"
Marcus Meissnerc2606381999-04-11 15:20:29 +00003829#include "confdefs.h"
3830int myerrno = 0;
3831char buf[256];
3832int *__error(){return &myerrno;}
3833main(){connect(0,buf,255); exit(!myerrno);}
3834EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003835if { (eval echo configure:3836: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
Marcus Meissnerc2606381999-04-11 15:20:29 +00003836then
Ulrich Weigand715a55e1999-04-18 13:19:56 +00003837 wine_cv_libc_r__error=yes
Marcus Meissnerc2606381999-04-11 15:20:29 +00003838else
3839 echo "configure: failed program was:" >&5
3840 cat conftest.$ac_ext >&5
3841 rm -fr conftest*
Ulrich Weigand715a55e1999-04-18 13:19:56 +00003842 wine_cv_libc_r__error=no
Marcus Meissnerc2606381999-04-11 15:20:29 +00003843fi
3844rm -fr conftest*
3845fi
3846
Marcus Meissnerc2606381999-04-11 15:20:29 +00003847
Alexandre Julliardd30dfd21998-09-27 18:28:36 +00003848fi
3849
Ulrich Weigand715a55e1999-04-18 13:19:56 +00003850echo "$ac_t""$wine_cv_libc_r__error" 1>&6
3851if test "$wine_cv_libc_r__error" = "yes"
3852then
3853 cat >> confdefs.h <<\EOF
3854#define HAVE__ERROR 1
3855EOF
3856
3857 wine_cv_libc_reentrant=__error
3858fi
3859echo $ac_n "checking "for reentrant libc: ___errno"""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003860echo "configure:3861: checking "for reentrant libc: ___errno"" >&5
Ulrich Weigand715a55e1999-04-18 13:19:56 +00003861if eval "test \"`echo '$''{'wine_cv_libc_r___errno'+set}'`\" = set"; then
3862 echo $ac_n "(cached) $ac_c" 1>&6
3863else
3864 if test "$cross_compiling" = yes; then
3865 wine_cv_libc_r___errno=yes
3866else
3867 cat > conftest.$ac_ext <<EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003868#line 3869 "configure"
Ulrich Weigand715a55e1999-04-18 13:19:56 +00003869#include "confdefs.h"
3870int myerrno = 0;
3871char buf[256];
3872int *___errno(){return &myerrno;}
3873main(){connect(0,buf,255); exit(!myerrno);}
3874EOF
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003875if { (eval echo configure:3876: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
Ulrich Weigand715a55e1999-04-18 13:19:56 +00003876then
3877 wine_cv_libc_r___errno=yes
3878else
3879 echo "configure: failed program was:" >&5
3880 cat conftest.$ac_ext >&5
3881 rm -fr conftest*
3882 wine_cv_libc_r___errno=no
3883fi
3884rm -fr conftest*
3885fi
3886
3887
3888fi
3889
3890echo "$ac_t""$wine_cv_libc_r___errno" 1>&6
3891if test "$wine_cv_libc_r___errno" = "yes"
3892then
3893 cat >> confdefs.h <<\EOF
3894#define HAVE___ERRNO 1
3895EOF
3896
3897 wine_cv_libc_reentrant=___errno
3898fi
Alexandre Julliardd30dfd21998-09-27 18:28:36 +00003899if test "$wine_cv_libc_reentrant" = "no"
3900then
3901 cat >> confdefs.h <<\EOF
3902#define NO_REENTRANT_LIBC 1
3903EOF
3904
3905fi
3906
3907
Ulrich Weigand715a55e1999-04-18 13:19:56 +00003908if test "$have_x" = "yes" -a "$wine_cv_libc_reentrant" != "no"
Patrik Stridvall24110281999-02-04 10:09:54 +00003909then
Alexandre Julliarda11d7b11998-03-01 20:05:02 +00003910echo $ac_n "checking "for reentrant X libraries"""... $ac_c" 1>&6
Alexandre Julliard0e7bd081999-05-02 11:46:02 +00003911echo "configure:3912: checking "for reentrant X libraries"" >&5
Alexandre Julliarda11d7b11998-03-01 20:05:02 +00003912if eval "test \"`echo '$''{'wine_cv_x_reentrant'+set}'`\" = set"; then
3913 echo $ac_n "(cached) $ac_c" 1>&6
3914else
Ulrich Weigand715a55e1999-04-18 13:19:56 +00003915 if test "x$with_reentrant_x" = "xno"
Alexandre Julliarda11d7b11998-03-01 20:05:02 +00003916 then
3917 wine_cv_x_reentrant=no
3918 else
Ulrich Weigand715a55e1999-04-18 13:19:56 +00003919 libX11_check=none
Alexandre Julliarda11d7b11998-03-01 20:05:02 +00003920 for dir in "$x_libraries" /usr/lib /usr/local/lib /lib; do
Alexandre Julliard829fe321998-07-26 14:27:39 +00003921 if test -r $dir/libX11.so; then
Alexandre Julliarda11d7b11998-03-01 20:05:02 +00003922 libX11_check="-D $dir/libX11.so"
3923 break 1
3924 fi
Alexandre Julliard829fe321998-07-26 14:27:39 +00003925 if test -r $dir/libX11.a; then
Alexandre Julliarda11d7b11998-03-01 20:05:02 +00003926 libX11_check="$dir/libX11.a"
3927 break 1
3928 fi
3929 done
3930 if test "$libX11_check" != "none"; then
Ulrich Weigand715a55e1999-04-18 13:19:56 +00003931 if nm $libX11_check | grep $wine_cv_libc_reentrant >/dev/null 2>&1
Alexandre Julliard829fe321998-07-26 14:27:39 +00003932 then
Alexandre Julliarda11d7b11998-03-01 20:05:02 +00003933 wine_cv_x_reentrant=yes
3934 else
3935 wine_cv_x_reentrant=no
3936 fi
3937 else
3938 wine_cv_x_reentrant=unknown
3939 fi
3940 fi
3941fi
3942
3943echo "$ac_t""$wine_cv_x_reentrant" 1>&6
Patrik Stridvall24110281999-02-04 10:09:54 +00003944else
3945 wine_cv_x_reentrant=no
3946fi
Alexandre Julliarda11d7b11998-03-01 20:05:02 +00003947if test "$wine_cv_x_reentrant" = "no"
3948then
3949 cat >> confdefs.h <<\EOF
3950#define NO_REENTRANT_X11 1
3951EOF
3952
3953fi
3954
3955
Patrik Stridvall1bb94031999-05-08 15:47:44 +00003956# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
3957# for constant arguments. Useless!
3958echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
3959echo "configure:3960: checking for working alloca.h" >&5
3960if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
3961 echo $ac_n "(cached) $ac_c" 1>&6
3962else
3963 cat > conftest.$ac_ext <<EOF
3964#line 3965 "configure"
3965#include "confdefs.h"
3966#include <alloca.h>
3967int main() {
3968char *p = alloca(2 * sizeof(int));
3969; return 0; }
3970EOF
3971if { (eval echo configure:3972: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
3972 rm -rf conftest*
3973 ac_cv_header_alloca_h=yes
3974else
3975 echo "configure: failed program was:" >&5
3976 cat conftest.$ac_ext >&5
3977 rm -rf conftest*
3978 ac_cv_header_alloca_h=no
3979fi
3980rm -f conftest*
3981fi
Alexandre Julliard2487cce1999-04-18 14:43:16 +00003982
Patrik Stridvall1bb94031999-05-08 15:47:44 +00003983echo "$ac_t""$ac_cv_header_alloca_h" 1>&6
3984if test $ac_cv_header_alloca_h = yes; then
3985 cat >> confdefs.h <<\EOF
3986#define HAVE_ALLOCA_H 1
3987EOF
3988
3989fi
3990
3991echo $ac_n "checking for alloca""... $ac_c" 1>&6
3992echo "configure:3993: checking for alloca" >&5
3993if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
3994 echo $ac_n "(cached) $ac_c" 1>&6
3995else
3996 cat > conftest.$ac_ext <<EOF
3997#line 3998 "configure"
3998#include "confdefs.h"
3999
4000#ifdef __GNUC__
4001# define alloca __builtin_alloca
4002#else
4003# if HAVE_ALLOCA_H
4004# include <alloca.h>
4005# else
4006# ifdef _AIX
4007 #pragma alloca
4008# else
4009# ifndef alloca /* predefined by HP cc +Olibcalls */
4010char *alloca ();
4011# endif
4012# endif
4013# endif
4014#endif
4015
4016int main() {
4017char *p = (char *) alloca(1);
4018; return 0; }
4019EOF
4020if { (eval echo configure:4021: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
4021 rm -rf conftest*
4022 ac_cv_func_alloca_works=yes
4023else
4024 echo "configure: failed program was:" >&5
4025 cat conftest.$ac_ext >&5
4026 rm -rf conftest*
4027 ac_cv_func_alloca_works=no
4028fi
4029rm -f conftest*
4030fi
4031
4032echo "$ac_t""$ac_cv_func_alloca_works" 1>&6
4033if test $ac_cv_func_alloca_works = yes; then
4034 cat >> confdefs.h <<\EOF
4035#define HAVE_ALLOCA 1
4036EOF
4037
4038fi
4039
4040if test $ac_cv_func_alloca_works = no; then
4041 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
4042 # that cause trouble. Some versions do not even contain alloca or
4043 # contain a buggy version. If you still want to use their alloca,
4044 # use ar to extract alloca.o from them instead of compiling alloca.c.
4045 ALLOCA=alloca.o
4046 cat >> confdefs.h <<\EOF
4047#define C_ALLOCA 1
4048EOF
4049
4050
4051echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
4052echo "configure:4053: checking whether alloca needs Cray hooks" >&5
4053if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
4054 echo $ac_n "(cached) $ac_c" 1>&6
4055else
4056 cat > conftest.$ac_ext <<EOF
4057#line 4058 "configure"
4058#include "confdefs.h"
4059#if defined(CRAY) && ! defined(CRAY2)
4060webecray
4061#else
4062wenotbecray
4063#endif
4064
4065EOF
4066if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4067 egrep "webecray" >/dev/null 2>&1; then
4068 rm -rf conftest*
4069 ac_cv_os_cray=yes
4070else
4071 rm -rf conftest*
4072 ac_cv_os_cray=no
4073fi
4074rm -f conftest*
4075
4076fi
4077
4078echo "$ac_t""$ac_cv_os_cray" 1>&6
4079if test $ac_cv_os_cray = yes; then
4080for ac_func in _getb67 GETB67 getb67; do
4081 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
4082echo "configure:4083: checking for $ac_func" >&5
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004083if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
4084 echo $ac_n "(cached) $ac_c" 1>&6
4085else
4086 cat > conftest.$ac_ext <<EOF
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004087#line 4088 "configure"
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004088#include "confdefs.h"
4089/* System header to define __stub macros and hopefully few prototypes,
4090 which can conflict with char $ac_func(); below. */
4091#include <assert.h>
4092/* Override any gcc2 internal prototype to avoid an error. */
Alexandre Julliarde2bfa4c1996-05-16 18:21:06 +00004093/* We use char because int might match the return type of a gcc2
4094 builtin and then its argument prototype would still apply. */
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00004095char $ac_func();
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004096
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00004097int main() {
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004098
4099/* The GNU C library defines this for functions which it implements
4100 to always fail with ENOSYS. Some functions are actually named
4101 something starting with __ and the normal name is an alias. */
4102#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
4103choke me
4104#else
4105$ac_func();
4106#endif
4107
4108; return 0; }
4109EOF
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004110if { (eval echo configure:4111: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
4111 rm -rf conftest*
4112 eval "ac_cv_func_$ac_func=yes"
4113else
4114 echo "configure: failed program was:" >&5
4115 cat conftest.$ac_ext >&5
4116 rm -rf conftest*
4117 eval "ac_cv_func_$ac_func=no"
4118fi
4119rm -f conftest*
4120fi
4121
4122if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
4123 echo "$ac_t""yes" 1>&6
4124 cat >> confdefs.h <<EOF
4125#define CRAY_STACKSEG_END $ac_func
4126EOF
4127
4128 break
4129else
4130 echo "$ac_t""no" 1>&6
4131fi
4132
4133done
4134fi
4135
4136echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
4137echo "configure:4138: checking stack direction for C alloca" >&5
4138if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
4139 echo $ac_n "(cached) $ac_c" 1>&6
4140else
4141 if test "$cross_compiling" = yes; then
4142 ac_cv_c_stack_direction=0
4143else
4144 cat > conftest.$ac_ext <<EOF
4145#line 4146 "configure"
4146#include "confdefs.h"
4147find_stack_direction ()
4148{
4149 static char *addr = 0;
4150 auto char dummy;
4151 if (addr == 0)
4152 {
4153 addr = &dummy;
4154 return find_stack_direction ();
4155 }
4156 else
4157 return (&dummy > addr) ? 1 : -1;
4158}
4159main ()
4160{
4161 exit (find_stack_direction() < 0);
4162}
4163EOF
4164if { (eval echo configure:4165: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
4165then
4166 ac_cv_c_stack_direction=1
4167else
4168 echo "configure: failed program was:" >&5
4169 cat conftest.$ac_ext >&5
4170 rm -fr conftest*
4171 ac_cv_c_stack_direction=-1
4172fi
4173rm -fr conftest*
4174fi
4175
4176fi
4177
4178echo "$ac_t""$ac_cv_c_stack_direction" 1>&6
4179cat >> confdefs.h <<EOF
4180#define STACK_DIRECTION $ac_cv_c_stack_direction
4181EOF
4182
4183fi
4184
4185for ac_func in \
4186 _lwp_create \
4187 clone \
4188 getpagesize \
4189 memmove \
4190 rfork \
4191 sendmsg \
4192 sigaltstack \
4193 strerror \
4194 stricmp \
4195 tcgetattr \
4196 timegm \
4197 usleep \
4198 vfscanf \
4199 wait4 \
4200 waitpid \
4201
4202do
4203echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
4204echo "configure:4205: checking for $ac_func" >&5
4205if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
4206 echo $ac_n "(cached) $ac_c" 1>&6
4207else
4208 cat > conftest.$ac_ext <<EOF
4209#line 4210 "configure"
4210#include "confdefs.h"
4211/* System header to define __stub macros and hopefully few prototypes,
4212 which can conflict with char $ac_func(); below. */
4213#include <assert.h>
4214/* Override any gcc2 internal prototype to avoid an error. */
4215/* We use char because int might match the return type of a gcc2
4216 builtin and then its argument prototype would still apply. */
4217char $ac_func();
4218
4219int main() {
4220
4221/* The GNU C library defines this for functions which it implements
4222 to always fail with ENOSYS. Some functions are actually named
4223 something starting with __ and the normal name is an alias. */
4224#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
4225choke me
4226#else
4227$ac_func();
4228#endif
4229
4230; return 0; }
4231EOF
4232if { (eval echo configure:4233: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004233 rm -rf conftest*
4234 eval "ac_cv_func_$ac_func=yes"
4235else
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00004236 echo "configure: failed program was:" >&5
4237 cat conftest.$ac_ext >&5
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004238 rm -rf conftest*
4239 eval "ac_cv_func_$ac_func=no"
4240fi
4241rm -f conftest*
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004242fi
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +00004243
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004244if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
4245 echo "$ac_t""yes" 1>&6
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00004246 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004247 cat >> confdefs.h <<EOF
4248#define $ac_tr_func 1
4249EOF
4250
4251else
4252 echo "$ac_t""no" 1>&6
4253fi
4254done
4255
Alexandre Julliard2487cce1999-04-18 14:43:16 +00004256
4257
4258for ac_hdr in \
4259 arpa/nameser.h \
4260 curses.h \
Alexandre Julliard2487cce1999-04-18 14:43:16 +00004261 elf.h \
4262 float.h \
4263 libio.h \
4264 linux/cdrom.h \
4265 linux/ucdrom.h \
4266 ncurses.h \
4267 net/if.h \
4268 netinet/in.h \
4269 resolv.h \
4270 strings.h \
4271 sys/cdio.h \
4272 sys/file.h \
4273 sys/filio.h \
4274 sys/lwp.h \
4275 sys/modem.h \
4276 sys/mount.h \
4277 sys/param.h \
4278 sys/sockio.h \
4279 sys/statfs.h \
4280 sys/strtio.h \
4281 sys/syscall.h \
4282 sys/vfs.h \
4283 syscall.h \
4284 ucontext.h \
4285 unistd.h \
4286 wctype.h \
4287
Alexandre Julliard02e90081998-01-04 17:49:09 +00004288do
4289ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4290echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004291echo "configure:4292: checking for $ac_hdr" >&5
Alexandre Julliard02e90081998-01-04 17:49:09 +00004292if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4293 echo $ac_n "(cached) $ac_c" 1>&6
4294else
4295 cat > conftest.$ac_ext <<EOF
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004296#line 4297 "configure"
Alexandre Julliard02e90081998-01-04 17:49:09 +00004297#include "confdefs.h"
4298#include <$ac_hdr>
4299EOF
4300ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004301{ (eval echo configure:4302: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
Alexandre Julliard02e90081998-01-04 17:49:09 +00004302ac_err=`grep -v '^ *+' conftest.out`
4303if test -z "$ac_err"; then
4304 rm -rf conftest*
4305 eval "ac_cv_header_$ac_safe=yes"
4306else
4307 echo "$ac_err" >&5
4308 echo "configure: failed program was:" >&5
4309 cat conftest.$ac_ext >&5
4310 rm -rf conftest*
4311 eval "ac_cv_header_$ac_safe=no"
4312fi
4313rm -f conftest*
4314fi
4315if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4316 echo "$ac_t""yes" 1>&6
4317 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4318 cat >> confdefs.h <<EOF
4319#define $ac_tr_hdr 1
4320EOF
4321
4322else
4323 echo "$ac_t""no" 1>&6
4324fi
4325done
4326
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004327echo $ac_n "checking whether stat file-mode macros are broken""... $ac_c" 1>&6
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004328echo "configure:4329: checking whether stat file-mode macros are broken" >&5
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004329if eval "test \"`echo '$''{'ac_cv_header_stat_broken'+set}'`\" = set"; then
4330 echo $ac_n "(cached) $ac_c" 1>&6
4331else
4332 cat > conftest.$ac_ext <<EOF
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004333#line 4334 "configure"
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004334#include "confdefs.h"
4335#include <sys/types.h>
4336#include <sys/stat.h>
4337
4338#if defined(S_ISBLK) && defined(S_IFDIR)
4339# if S_ISBLK (S_IFDIR)
4340You lose.
4341# endif
4342#endif
4343
4344#if defined(S_ISBLK) && defined(S_IFCHR)
4345# if S_ISBLK (S_IFCHR)
4346You lose.
4347# endif
4348#endif
4349
4350#if defined(S_ISLNK) && defined(S_IFREG)
4351# if S_ISLNK (S_IFREG)
4352You lose.
4353# endif
4354#endif
4355
4356#if defined(S_ISSOCK) && defined(S_IFREG)
4357# if S_ISSOCK (S_IFREG)
4358You lose.
4359# endif
4360#endif
4361
4362EOF
4363if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4364 egrep "You lose" >/dev/null 2>&1; then
4365 rm -rf conftest*
4366 ac_cv_header_stat_broken=yes
4367else
4368 rm -rf conftest*
4369 ac_cv_header_stat_broken=no
4370fi
4371rm -f conftest*
4372
4373fi
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00004374
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004375echo "$ac_t""$ac_cv_header_stat_broken" 1>&6
4376if test $ac_cv_header_stat_broken = yes; then
4377 cat >> confdefs.h <<\EOF
4378#define STAT_MACROS_BROKEN 1
4379EOF
4380
4381fi
4382
Alexandre Julliard2487cce1999-04-18 14:43:16 +00004383
4384
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004385echo $ac_n "checking for working const""... $ac_c" 1>&6
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004386echo "configure:4387: checking for working const" >&5
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004387if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
4388 echo $ac_n "(cached) $ac_c" 1>&6
4389else
4390 cat > conftest.$ac_ext <<EOF
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004391#line 4392 "configure"
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004392#include "confdefs.h"
4393
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00004394int main() {
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004395
4396/* Ultrix mips cc rejects this. */
4397typedef int charset[2]; const charset x;
4398/* SunOS 4.1.1 cc rejects this. */
4399char const *const *ccp;
4400char **p;
4401/* NEC SVR4.0.2 mips cc rejects this. */
4402struct point {int x, y;};
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00004403static struct point const zero = {0,0};
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004404/* AIX XL C 1.02.0.0 rejects this.
4405 It does not let you subtract one const X* pointer from another in an arm
4406 of an if-expression whose if-part is not a constant expression */
4407const char *g = "string";
4408ccp = &g + (g ? g-g : 0);
4409/* HPUX 7.0 cc rejects these. */
4410++ccp;
4411p = (char**) ccp;
4412ccp = (char const *const *) p;
4413{ /* SCO 3.2v4 cc rejects this. */
4414 char *t;
4415 char const *s = 0 ? (char *) 0 : (char const *) 0;
4416
4417 *t++ = 0;
4418}
4419{ /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
4420 int x[] = {25, 17};
4421 const int *foo = &x[0];
4422 ++foo;
4423}
4424{ /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
4425 typedef const int *iptr;
4426 iptr p = 0;
4427 ++p;
4428}
4429{ /* AIX XL C 1.02.0.0 rejects this saying
4430 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
4431 struct s { int j; const int *ap[3]; };
4432 struct s *b; b->j = 5;
4433}
4434{ /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
4435 const int foo = 10;
4436}
4437
4438; return 0; }
4439EOF
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004440if { (eval echo configure:4441: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004441 rm -rf conftest*
4442 ac_cv_c_const=yes
4443else
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00004444 echo "configure: failed program was:" >&5
4445 cat conftest.$ac_ext >&5
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004446 rm -rf conftest*
4447 ac_cv_c_const=no
4448fi
4449rm -f conftest*
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004450fi
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00004451
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004452echo "$ac_t""$ac_cv_c_const" 1>&6
4453if test $ac_cv_c_const = no; then
4454 cat >> confdefs.h <<\EOF
4455#define const
4456EOF
4457
4458fi
4459
Marcus Meissner1a8bbd71999-04-26 14:58:58 +00004460echo $ac_n "checking for inline""... $ac_c" 1>&6
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004461echo "configure:4462: checking for inline" >&5
Marcus Meissner1a8bbd71999-04-26 14:58:58 +00004462if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
4463 echo $ac_n "(cached) $ac_c" 1>&6
4464else
4465 ac_cv_c_inline=no
4466for ac_kw in inline __inline__ __inline; do
4467 cat > conftest.$ac_ext <<EOF
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004468#line 4469 "configure"
Marcus Meissner1a8bbd71999-04-26 14:58:58 +00004469#include "confdefs.h"
4470
4471int main() {
4472} $ac_kw foo() {
4473; return 0; }
4474EOF
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004475if { (eval echo configure:4476: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Marcus Meissner1a8bbd71999-04-26 14:58:58 +00004476 rm -rf conftest*
4477 ac_cv_c_inline=$ac_kw; break
4478else
4479 echo "configure: failed program was:" >&5
4480 cat conftest.$ac_ext >&5
4481fi
4482rm -f conftest*
4483done
4484
4485fi
4486
4487echo "$ac_t""$ac_cv_c_inline" 1>&6
4488case "$ac_cv_c_inline" in
4489 inline | yes) ;;
4490 no) cat >> confdefs.h <<\EOF
4491#define inline
4492EOF
4493 ;;
4494 *) cat >> confdefs.h <<EOF
4495#define inline $ac_cv_c_inline
4496EOF
4497 ;;
4498esac
4499
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004500echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004501echo "configure:4502: checking for ANSI C header files" >&5
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004502if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
4503 echo $ac_n "(cached) $ac_c" 1>&6
4504else
4505 cat > conftest.$ac_ext <<EOF
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004506#line 4507 "configure"
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004507#include "confdefs.h"
4508#include <stdlib.h>
4509#include <stdarg.h>
4510#include <string.h>
4511#include <float.h>
4512EOF
Alexandre Julliardb817f4f1996-03-14 18:08:34 +00004513ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004514{ (eval echo configure:4515: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004515ac_err=`grep -v '^ *+' conftest.out`
4516if test -z "$ac_err"; then
4517 rm -rf conftest*
4518 ac_cv_header_stdc=yes
4519else
4520 echo "$ac_err" >&5
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00004521 echo "configure: failed program was:" >&5
4522 cat conftest.$ac_ext >&5
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004523 rm -rf conftest*
4524 ac_cv_header_stdc=no
4525fi
4526rm -f conftest*
4527
4528if test $ac_cv_header_stdc = yes; then
4529 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
4530cat > conftest.$ac_ext <<EOF
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004531#line 4532 "configure"
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004532#include "confdefs.h"
4533#include <string.h>
4534EOF
4535if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4536 egrep "memchr" >/dev/null 2>&1; then
4537 :
4538else
4539 rm -rf conftest*
4540 ac_cv_header_stdc=no
4541fi
4542rm -f conftest*
4543
4544fi
4545
4546if test $ac_cv_header_stdc = yes; then
4547 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
4548cat > conftest.$ac_ext <<EOF
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004549#line 4550 "configure"
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004550#include "confdefs.h"
4551#include <stdlib.h>
4552EOF
4553if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4554 egrep "free" >/dev/null 2>&1; then
4555 :
4556else
4557 rm -rf conftest*
4558 ac_cv_header_stdc=no
4559fi
4560rm -f conftest*
4561
4562fi
4563
4564if test $ac_cv_header_stdc = yes; then
4565 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
4566if test "$cross_compiling" = yes; then
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00004567 :
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004568else
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00004569 cat > conftest.$ac_ext <<EOF
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004570#line 4571 "configure"
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004571#include "confdefs.h"
4572#include <ctype.h>
4573#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4574#define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4575#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4576int main () { int i; for (i = 0; i < 256; i++)
4577if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
4578exit (0); }
4579
4580EOF
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004581if { (eval echo configure:4582: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +00004582then
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004583 :
4584else
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00004585 echo "configure: failed program was:" >&5
4586 cat conftest.$ac_ext >&5
4587 rm -fr conftest*
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004588 ac_cv_header_stdc=no
4589fi
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004590rm -fr conftest*
4591fi
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00004592
4593fi
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004594fi
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00004595
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004596echo "$ac_t""$ac_cv_header_stdc" 1>&6
4597if test $ac_cv_header_stdc = yes; then
4598 cat >> confdefs.h <<\EOF
4599#define STDC_HEADERS 1
4600EOF
4601
4602fi
4603
4604echo $ac_n "checking for size_t""... $ac_c" 1>&6
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004605echo "configure:4606: checking for size_t" >&5
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004606if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
4607 echo $ac_n "(cached) $ac_c" 1>&6
4608else
4609 cat > conftest.$ac_ext <<EOF
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004610#line 4611 "configure"
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004611#include "confdefs.h"
4612#include <sys/types.h>
4613#if STDC_HEADERS
4614#include <stdlib.h>
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00004615#include <stddef.h>
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004616#endif
4617EOF
4618if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00004619 egrep "size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00004620 rm -rf conftest*
4621 ac_cv_type_size_t=yes
4622else
4623 rm -rf conftest*
4624 ac_cv_type_size_t=no
4625fi
4626rm -f conftest*
4627
4628fi
4629echo "$ac_t""$ac_cv_type_size_t" 1>&6
4630if test $ac_cv_type_size_t = no; then
4631 cat >> confdefs.h <<\EOF
4632#define size_t unsigned
4633EOF
4634
4635fi
4636
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00004637echo $ac_n "checking size of long long""... $ac_c" 1>&6
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004638echo "configure:4639: checking size of long long" >&5
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00004639if eval "test \"`echo '$''{'ac_cv_sizeof_long_long'+set}'`\" = set"; then
4640 echo $ac_n "(cached) $ac_c" 1>&6
4641else
4642 if test "$cross_compiling" = yes; then
4643 ac_cv_sizeof_long_long=0
4644else
4645 cat > conftest.$ac_ext <<EOF
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004646#line 4647 "configure"
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00004647#include "confdefs.h"
4648#include <stdio.h>
4649main()
4650{
4651 FILE *f=fopen("conftestval", "w");
4652 if (!f) exit(1);
4653 fprintf(f, "%d\n", sizeof(long long));
4654 exit(0);
4655}
4656EOF
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004657if { (eval echo configure:4658: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00004658then
4659 ac_cv_sizeof_long_long=`cat conftestval`
4660else
4661 echo "configure: failed program was:" >&5
4662 cat conftest.$ac_ext >&5
4663 rm -fr conftest*
4664 ac_cv_sizeof_long_long=0
4665fi
4666rm -fr conftest*
4667fi
4668
4669fi
4670echo "$ac_t""$ac_cv_sizeof_long_long" 1>&6
4671cat >> confdefs.h <<EOF
4672#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
4673EOF
4674
4675
4676
Alexandre Julliarddadf78f1998-05-17 17:13:43 +00004677
4678if test "$ac_cv_header_sys_vfs_h" = "yes"
4679then
4680 echo $ac_n "checking "whether sys/vfs.h defines statfs"""... $ac_c" 1>&6
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004681echo "configure:4682: checking "whether sys/vfs.h defines statfs"" >&5
Alexandre Julliarddadf78f1998-05-17 17:13:43 +00004682if eval "test \"`echo '$''{'wine_cv_sys_vfs_has_statfs'+set}'`\" = set"; then
4683 echo $ac_n "(cached) $ac_c" 1>&6
4684else
4685 cat > conftest.$ac_ext <<EOF
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004686#line 4687 "configure"
Alexandre Julliarddadf78f1998-05-17 17:13:43 +00004687#include "confdefs.h"
4688
4689 #include <sys/types.h>
4690 #ifdef HAVE_SYS_PARAM_H
4691 # include <sys/param.h>
4692 #endif
4693 #include <sys/vfs.h>
4694
4695int main() {
4696
4697 struct statfs stfs;
4698
4699 memset(&stfs,0,sizeof(stfs));
4700
4701; return 0; }
4702EOF
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004703if { (eval echo configure:4704: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Alexandre Julliarddadf78f1998-05-17 17:13:43 +00004704 rm -rf conftest*
4705 wine_cv_sys_vfs_has_statfs=yes
4706else
4707 echo "configure: failed program was:" >&5
4708 cat conftest.$ac_ext >&5
4709 rm -rf conftest*
4710 wine_cv_sys_vfs_has_statfs=no
4711
4712fi
4713rm -f conftest*
4714
4715fi
4716
4717echo "$ac_t""$wine_cv_sys_vfs_has_statfs" 1>&6
4718 if test "$wine_cv_sys_vfs_has_statfs" = "yes"
4719 then
4720 cat >> confdefs.h <<\EOF
4721#define STATFS_DEFINED_BY_SYS_VFS 1
4722EOF
4723
4724 fi
4725fi
4726
4727if test "$ac_cv_header_sys_statfs_h" = "yes"
4728then
4729 echo $ac_n "checking "whether sys/statfs.h defines statfs"""... $ac_c" 1>&6
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004730echo "configure:4731: checking "whether sys/statfs.h defines statfs"" >&5
Alexandre Julliarddadf78f1998-05-17 17:13:43 +00004731if eval "test \"`echo '$''{'wine_cv_sys_statfs_has_statfs'+set}'`\" = set"; then
4732 echo $ac_n "(cached) $ac_c" 1>&6
4733else
4734 cat > conftest.$ac_ext <<EOF
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004735#line 4736 "configure"
Alexandre Julliarddadf78f1998-05-17 17:13:43 +00004736#include "confdefs.h"
4737
4738 #include <sys/types.h>
4739 #ifdef HAVE_SYS_PARAM_H
4740 # include <sys/param.h>
4741 #endif
4742 #include <sys/statfs.h>
4743
4744int main() {
4745
4746 struct statfs stfs;
4747
4748; return 0; }
4749EOF
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004750if { (eval echo configure:4751: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Alexandre Julliarddadf78f1998-05-17 17:13:43 +00004751 rm -rf conftest*
4752 wine_cv_sys_statfs_has_statfs=yes
4753else
4754 echo "configure: failed program was:" >&5
4755 cat conftest.$ac_ext >&5
4756 rm -rf conftest*
4757 wine_cv_sys_statfs_has_statfs=no
4758
4759fi
4760rm -f conftest*
4761
4762fi
4763
4764echo "$ac_t""$wine_cv_sys_statfs_has_statfs" 1>&6
4765 if test "$wine_cv_sys_statfs_has_statfs" = "yes"
4766 then
4767 cat >> confdefs.h <<\EOF
4768#define STATFS_DEFINED_BY_SYS_STATFS 1
4769EOF
4770
4771 fi
4772fi
4773
4774if test "$ac_cv_header_sys_mount_h" = "yes"
4775then
4776 echo $ac_n "checking "whether sys/mount.h defines statfs"""... $ac_c" 1>&6
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004777echo "configure:4778: checking "whether sys/mount.h defines statfs"" >&5
Alexandre Julliarddadf78f1998-05-17 17:13:43 +00004778if eval "test \"`echo '$''{'wine_cv_sys_mount_has_statfs'+set}'`\" = set"; then
4779 echo $ac_n "(cached) $ac_c" 1>&6
4780else
4781 cat > conftest.$ac_ext <<EOF
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004782#line 4783 "configure"
Alexandre Julliarddadf78f1998-05-17 17:13:43 +00004783#include "confdefs.h"
4784
4785 #include <sys/types.h>
4786 #ifdef HAVE_SYS_PARAM_H
4787 # include <sys/param.h>
4788 #endif
4789 #include <sys/mount.h>
4790
4791int main() {
4792
4793 struct statfs stfs;
4794
4795; return 0; }
4796EOF
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004797if { (eval echo configure:4798: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Alexandre Julliarddadf78f1998-05-17 17:13:43 +00004798 rm -rf conftest*
4799 wine_cv_sys_mount_has_statfs=yes
4800else
4801 echo "configure: failed program was:" >&5
4802 cat conftest.$ac_ext >&5
4803 rm -rf conftest*
4804 wine_cv_sys_mount_has_statfs=no
4805
4806fi
4807rm -f conftest*
4808
4809fi
4810
4811echo "$ac_t""$wine_cv_sys_mount_has_statfs" 1>&6
4812 if test "$wine_cv_sys_mount_has_statfs" = "yes"
4813 then
4814 cat >> confdefs.h <<\EOF
4815#define STATFS_DEFINED_BY_SYS_MOUNT 1
4816EOF
4817
4818 fi
4819fi
4820
4821
4822echo $ac_n "checking "for statfs.f_bfree"""... $ac_c" 1>&6
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004823echo "configure:4824: checking "for statfs.f_bfree"" >&5
Alexandre Julliarddadf78f1998-05-17 17:13:43 +00004824if eval "test \"`echo '$''{'wine_cv_statfs_bfree'+set}'`\" = set"; then
4825 echo $ac_n "(cached) $ac_c" 1>&6
4826else
4827 if test "x$statfs_bfree" = "xno"
4828 then
4829 wine_cv_statfs_bfree=no
4830 else
4831 cat > conftest.$ac_ext <<EOF
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004832#line 4833 "configure"
Alexandre Julliarddadf78f1998-05-17 17:13:43 +00004833#include "confdefs.h"
4834
4835 #include <sys/types.h>
4836 #ifdef HAVE_SYS_PARAM_H
4837 # include <sys/param.h>
4838 #endif
4839 #ifdef STATFS_DEFINED_BY_SYS_MOUNT
4840 # include <sys/mount.h>
4841 #else
4842 # ifdef STATFS_DEFINED_BY_SYS_VFS
4843 # include <sys/vfs.h>
4844 # else
4845 # ifdef STATFS_DEFINED_BY_SYS_STATFS
4846 # include <sys/statfs.h>
4847 # endif
4848 # endif
4849 #endif
4850
4851int main() {
4852
4853 struct statfs stfs;
4854
4855 stfs.f_bfree++;
4856
4857; return 0; }
4858EOF
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004859if { (eval echo configure:4860: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Alexandre Julliarddadf78f1998-05-17 17:13:43 +00004860 rm -rf conftest*
4861 wine_cv_statfs_bfree=yes
4862else
4863 echo "configure: failed program was:" >&5
4864 cat conftest.$ac_ext >&5
4865 rm -rf conftest*
4866 wine_cv_statfs_bfree=no
4867
4868fi
4869rm -f conftest*
4870 fi
4871fi
4872
4873echo "$ac_t""$wine_cv_statfs_bfree" 1>&6
4874if test "$wine_cv_statfs_bfree" = "yes"
4875then
4876 cat >> confdefs.h <<\EOF
4877#define STATFS_HAS_BFREE 1
4878EOF
4879
4880fi
4881
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00004882echo $ac_n "checking "for statfs.f_bavail"""... $ac_c" 1>&6
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004883echo "configure:4884: checking "for statfs.f_bavail"" >&5
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00004884if eval "test \"`echo '$''{'wine_cv_statfs_bavail'+set}'`\" = set"; then
4885 echo $ac_n "(cached) $ac_c" 1>&6
4886else
4887 if test "x$statfs_bavail" = "xno"
4888 then
4889 wine_cv_statfs_bavail=no
4890 else
4891 cat > conftest.$ac_ext <<EOF
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004892#line 4893 "configure"
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00004893#include "confdefs.h"
4894
Alexandre Julliard46ea8b31998-05-03 19:01:20 +00004895 #include <sys/types.h>
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00004896 #ifdef HAVE_SYS_PARAM_H
4897 # include <sys/param.h>
4898 #endif
Alexandre Julliarddadf78f1998-05-17 17:13:43 +00004899 #ifdef STATFS_DEFINED_BY_SYS_MOUNT
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00004900 # include <sys/mount.h>
Alexandre Julliarddadf78f1998-05-17 17:13:43 +00004901 #else
4902 # ifdef STATFS_DEFINED_BY_SYS_VFS
4903 # include <sys/vfs.h>
4904 # else
4905 # ifdef STATFS_DEFINED_BY_SYS_STATFS
4906 # include <sys/statfs.h>
4907 # endif
4908 # endif
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00004909 #endif
4910
4911int main() {
4912
4913 struct statfs stfs;
4914
4915 stfs.f_bavail++;
4916
4917; return 0; }
4918EOF
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004919if { (eval echo configure:4920: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00004920 rm -rf conftest*
4921 wine_cv_statfs_bavail=yes
4922else
4923 echo "configure: failed program was:" >&5
4924 cat conftest.$ac_ext >&5
4925 rm -rf conftest*
4926 wine_cv_statfs_bavail=no
4927
4928fi
4929rm -f conftest*
4930 fi
4931fi
4932
4933echo "$ac_t""$wine_cv_statfs_bavail" 1>&6
4934if test "$wine_cv_statfs_bavail" = "yes"
4935then
4936 cat >> confdefs.h <<\EOF
4937#define STATFS_HAS_BAVAIL 1
4938EOF
4939
4940fi
4941
Alexandre Julliarddadf78f1998-05-17 17:13:43 +00004942
4943echo $ac_n "checking "for working sigaltstack"""... $ac_c" 1>&6
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004944echo "configure:4945: checking "for working sigaltstack"" >&5
Alexandre Julliarddadf78f1998-05-17 17:13:43 +00004945if eval "test \"`echo '$''{'ac_cv_c_working_sigaltstack'+set}'`\" = set"; then
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00004946 echo $ac_n "(cached) $ac_c" 1>&6
4947else
Alexandre Julliarddadf78f1998-05-17 17:13:43 +00004948 if test "$cross_compiling" = yes; then
4949 ac_cv_c_working_sigaltstack="no"
4950
4951else
4952 cat > conftest.$ac_ext <<EOF
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004953#line 4954 "configure"
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00004954#include "confdefs.h"
4955
Alexandre Julliarddadf78f1998-05-17 17:13:43 +00004956 #include <stdio.h>
4957 #include <time.h> /* <sys/time.h> ? bad magic without end */
Alexandre Julliard46ea8b31998-05-03 19:01:20 +00004958 #include <sys/types.h>
Alexandre Julliarddadf78f1998-05-17 17:13:43 +00004959 #include <sys/signal.h>
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00004960 #ifdef HAVE_SYS_PARAM_H
4961 # include <sys/param.h>
4962 #endif
Alexandre Julliarddadf78f1998-05-17 17:13:43 +00004963 #ifdef HAVE_SYSCALL_H
4964 # include <syscall.h>
4965 #else
4966 # ifdef HAVE_SYS_SYSCALL_H
4967 # include <sys/syscall.h>
4968 # endif
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00004969 #endif
4970
Alexandre Julliarddadf78f1998-05-17 17:13:43 +00004971 unsigned char *xaltstack;
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00004972
Alexandre Julliarddadf78f1998-05-17 17:13:43 +00004973 int
4974 main(int argc,char **argv) {
4975 struct sigaltstack ss;
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00004976
Alexandre Julliarddadf78f1998-05-17 17:13:43 +00004977 xaltstack = malloc(16384);
4978 ss.ss_sp = xaltstack;
4979 ss.ss_size = 16384;
4980 ss.ss_flags = 0;
4981 if (sigaltstack(&ss, NULL) < 0) {
4982 /* this catches the glibc case */
4983 perror("sigaltstack");
4984 return (1); /* aka exit(1) aka fail */
4985 }
4986 /* assume it works. */
4987 return 0; /* OK */
4988 }
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00004989
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00004990EOF
Patrik Stridvall1bb94031999-05-08 15:47:44 +00004991if { (eval echo configure:4992: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
Alexandre Julliarddadf78f1998-05-17 17:13:43 +00004992then
4993 ac_cv_c_working_sigaltstack="yes"
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00004994else
4995 echo "configure: failed program was:" >&5
4996 cat conftest.$ac_ext >&5
Alexandre Julliarddadf78f1998-05-17 17:13:43 +00004997 rm -fr conftest*
4998 ac_cv_c_working_sigaltstack="no"
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00004999fi
Alexandre Julliarddadf78f1998-05-17 17:13:43 +00005000rm -fr conftest*
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00005001fi
5002
Alexandre Julliarddadf78f1998-05-17 17:13:43 +00005003fi
5004
5005echo "$ac_t""$ac_cv_c_working_sigaltstack" 1>&6
5006
5007if test "$ac_cv_c_working_sigaltstack" = "yes"
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00005008then
Alexandre Julliarddadf78f1998-05-17 17:13:43 +00005009 cat >> confdefs.h <<\EOF
5010#define HAVE_WORKING_SIGALTSTACK 1
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00005011EOF
5012
5013fi
5014
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00005015
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00005016
Alexandre Julliard829fe321998-07-26 14:27:39 +00005017echo $ac_n "checking "for msg_accrights in struct msghdr"""... $ac_c" 1>&6
Patrik Stridvall1bb94031999-05-08 15:47:44 +00005018echo "configure:5019: checking "for msg_accrights in struct msghdr"" >&5
Alexandre Julliard829fe321998-07-26 14:27:39 +00005019if eval "test \"`echo '$''{'ac_cv_c_msg_accrights'+set}'`\" = set"; then
5020 echo $ac_n "(cached) $ac_c" 1>&6
5021else
5022 cat > conftest.$ac_ext <<EOF
Patrik Stridvall1bb94031999-05-08 15:47:44 +00005023#line 5024 "configure"
Alexandre Julliard829fe321998-07-26 14:27:39 +00005024#include "confdefs.h"
5025#include <sys/types.h>
5026#include <sys/socket.h>
5027int main() {
5028struct msghdr hdr; hdr.msg_accrights=0
5029; return 0; }
5030EOF
Patrik Stridvall1bb94031999-05-08 15:47:44 +00005031if { (eval echo configure:5032: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Alexandre Julliard829fe321998-07-26 14:27:39 +00005032 rm -rf conftest*
5033 ac_cv_c_msg_accrights="yes"
5034else
5035 echo "configure: failed program was:" >&5
5036 cat conftest.$ac_ext >&5
5037 rm -rf conftest*
5038 ac_cv_c_msg_accrights="no"
5039fi
5040rm -f conftest*
5041fi
5042
5043echo "$ac_t""$ac_cv_c_msg_accrights" 1>&6
5044if test "$ac_cv_c_msg_accrights" = "yes"
5045then
5046 cat >> confdefs.h <<\EOF
5047#define HAVE_MSGHDR_ACCRIGHTS 1
5048EOF
5049
5050fi
5051
Marcus Meissnera7f5cb51999-04-16 08:47:41 +00005052GCC_NO_BUILTIN=""
5053if test "$GCC" = "yes"
5054then
5055 GCC_NO_BUILTIN="-fno-builtin"
5056fi
5057
5058
Alexandre Julliard829fe321998-07-26 14:27:39 +00005059
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00005060MAKE_RULES=Make.rules
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00005061
5062
5063trap '' 1 2 15
5064cat > confcache <<\EOF
5065# This file is a shell script that caches the results of configure
5066# tests run on this system so they can be shared between configure
5067# scripts and configure runs. It is not useful on other systems.
5068# If it contains results you don't want to keep, you may remove or edit it.
5069#
5070# By default, configure uses ./config.cache as the cache file,
5071# creating it if it does not exist already. You can give configure
5072# the --cache-file=FILE option to use a different cache file; that is
5073# what configure does when it calls configure scripts in
5074# subdirectories, so they share the cache.
5075# Giving --cache-file=/dev/null disables caching, for debugging configure.
5076# config.status only pays attention to the cache file if you give it the
5077# --recheck option to rerun configure.
5078#
5079EOF
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +00005080# The following way of writing the cache mishandles newlines in values,
5081# but we know of no workaround that is simple, portable, and efficient.
5082# So, don't put newlines in cache variables' values.
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00005083# Ultrix sh set writes to stderr and can't be redirected directly,
5084# and sets the high bit in the cache file unless we assign to the vars.
5085(set) 2>&1 |
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +00005086 case `(ac_space=' '; set) 2>&1` in
5087 *ac_space=\ *)
5088 # `set' does not quote correctly, so add quotes (double-quote substitution
5089 # turns \\\\ into \\, and sed turns \\ into \).
5090 sed -n \
5091 -e "s/'/'\\\\''/g" \
5092 -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
5093 ;;
5094 *)
5095 # `set' quotes correctly as required by POSIX, so do not add quotes.
5096 sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
5097 ;;
5098 esac >> confcache
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00005099if cmp -s $cache_file confcache; then
5100 :
5101else
5102 if test -w $cache_file; then
5103 echo "updating cache $cache_file"
5104 cat confcache > $cache_file
5105 else
5106 echo "not updating unwritable cache $cache_file"
5107 fi
5108fi
5109rm -f confcache
5110
5111trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
5112
5113test "x$prefix" = xNONE && prefix=$ac_default_prefix
5114# Let make expand exec_prefix.
5115test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
5116
5117# Any assignment to VPATH causes Sun make to only execute
5118# the first set of double-colon rules, so remove it if not needed.
5119# If there is a colon in the path, we need to keep it.
5120if test "x$srcdir" = x.; then
5121 ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
5122fi
5123
5124trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
5125
Alexandre Julliard18f92e71996-07-17 20:02:21 +00005126DEFS=-DHAVE_CONFIG_H
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00005127
5128# Without the "./", some shells look in PATH for config.status.
5129: ${CONFIG_STATUS=./config.status}
5130
5131echo creating $CONFIG_STATUS
5132rm -f $CONFIG_STATUS
5133cat > $CONFIG_STATUS <<EOF
5134#! /bin/sh
5135# Generated automatically by configure.
5136# Run this file to recreate the current configuration.
5137# This directory was configured as follows,
5138# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
5139#
5140# $0 $ac_configure_args
5141#
5142# Compiler output produced by configure, useful for debugging
5143# configure, is in ./config.log if it exists.
5144
5145ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
5146for ac_option
5147do
5148 case "\$ac_option" in
5149 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
5150 echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
5151 exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
5152 -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +00005153 echo "$CONFIG_STATUS generated by autoconf version 2.12"
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00005154 exit 0 ;;
5155 -help | --help | --hel | --he | --h)
5156 echo "\$ac_cs_usage"; exit 0 ;;
5157 *) echo "\$ac_cs_usage"; exit 1 ;;
5158 esac
5159done
5160
5161ac_given_srcdir=$srcdir
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00005162ac_given_INSTALL="$INSTALL"
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00005163
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00005164trap 'rm -fr `echo "
5165Make.rules
5166Makefile
Joseph Pranevich791cd6a1998-12-02 19:58:08 +00005167console/Makefile
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00005168controls/Makefile
5169debugger/Makefile
Alexandre Julliard85ed45e1998-08-22 19:03:56 +00005170dlls/Makefile
Juergen Schmiedf7b0de31999-01-03 12:48:29 +00005171dlls/advapi32/Makefile
Marcus Meissnerb3d1a221999-03-13 18:07:44 +00005172dlls/avifil32/Makefile
Alexandre Julliarda0d77311998-09-13 16:32:00 +00005173dlls/comctl32/Makefile
Klaas van Gendc9127491999-02-28 20:05:11 +00005174dlls/commdlg/Makefile
Patrik Stridvall8295c861998-10-11 17:09:05 +00005175dlls/imagehlp/Makefile
5176dlls/msacm/Makefile
5177dlls/msacm32/Makefile
Marcus Meissner51505b11998-11-01 14:00:21 +00005178dlls/ntdll/Makefile
Alexandre Julliardd30dfd21998-09-27 18:28:36 +00005179dlls/psapi/Makefile
Marcus Meissner30ef8771998-12-11 13:26:26 +00005180dlls/rasapi32/Makefile
Alexandre Julliard85ed45e1998-08-22 19:03:56 +00005181dlls/shell32/Makefile
Andreas Mohr5aa96c11999-03-14 12:34:25 +00005182dlls/tapi32/Makefile
Ulrich Weigandd43a46a1999-01-31 10:11:04 +00005183dlls/ver/Makefile
5184dlls/version/Makefile
Alexandre Julliardd30dfd21998-09-27 18:28:36 +00005185dlls/winaspi/Makefile
5186dlls/wnaspi32/Makefile
Alexandre Julliardd37eb361997-07-20 16:23:21 +00005187documentation/Makefile
Alexandre Julliard4f8c37b1996-01-14 18:12:01 +00005188files/Makefile
Alexandre Julliard0e270f41996-08-24 18:26:35 +00005189graphics/Makefile
Huw D M Davies3a24f3f1999-05-02 10:15:16 +00005190graphics/enhmetafiledrv/Makefile
Alexandre Julliardbf9130a1996-10-13 17:45:47 +00005191graphics/metafiledrv/Makefile
Alexandre Julliardebfc0fe1998-06-28 18:40:26 +00005192graphics/psdrv/Makefile
Patrik Stridvall24110281999-02-04 10:09:54 +00005193graphics/ttydrv/Makefile
Alexandre Julliard0e270f41996-08-24 18:26:35 +00005194graphics/win16drv/Makefile
5195graphics/x11drv/Makefile
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00005196if1632/Makefile
James Juranc70dc831999-02-13 12:18:33 +00005197include/Makefile
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00005198ipc/Makefile
5199library/Makefile
5200libtest/Makefile
5201loader/Makefile
Alexandre Julliard46ea8b31998-05-03 19:01:20 +00005202loader/ne/Makefile
Alexandre Julliard767e6f61998-08-09 12:47:43 +00005203loader/dos/Makefile
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00005204memory/Makefile
5205misc/Makefile
5206miscemu/Makefile
Alexandre Julliard9ea19e51997-01-01 17:29:55 +00005207msdos/Makefile
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00005208multimedia/Makefile
5209objects/Makefile
Alexandre Julliarde658d821997-11-30 17:45:40 +00005210ole/Makefile
Alexandre Julliard02ed4c21996-03-02 19:34:10 +00005211programs/Makefile
Alexandre Julliarda11d7b11998-03-01 20:05:02 +00005212programs/clock/Makefile
Eric Williams30008a01999-02-05 17:40:47 +00005213programs/cmdlgtst/Makefile
Alexandre Julliardd30dfd21998-09-27 18:28:36 +00005214programs/control/Makefile
Marcus Meissner32b32d81999-01-29 15:12:10 +00005215programs/avitools/Makefile
Alexandre Julliard44ed71f1997-12-21 19:17:50 +00005216programs/notepad/Makefile
Alexandre Julliard02ed4c21996-03-02 19:34:10 +00005217programs/progman/Makefile
Alexandre Julliarddadf78f1998-05-17 17:13:43 +00005218programs/regtest/Makefile
Sylvain St.Germain1bb0e661999-03-14 14:00:22 +00005219programs/regapi/Makefile
Alexandre Julliarda11d7b11998-03-01 20:05:02 +00005220programs/view/Makefile
Alexandre Julliard1285c2f1996-05-06 16:06:24 +00005221programs/winhelp/Makefile
Alexandre Julliarde658d821997-11-30 17:45:40 +00005222programs/winver/Makefile
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00005223rc/Makefile
Alexandre Julliard44ed71f1997-12-21 19:17:50 +00005224relay32/Makefile
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00005225resources/Makefile
Alexandre Julliard9ea19e51997-01-01 17:29:55 +00005226scheduler/Makefile
Alexandre Julliard642d3131998-07-12 19:29:36 +00005227server/Makefile
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00005228tools/Makefile
Alexandre Julliarda845b881998-06-01 10:44:35 +00005229tools/wrc/Makefile
Alexandre Julliard60ce85c1998-02-01 18:33:27 +00005230tsx11/Makefile
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00005231win32/Makefile
Patrik Stridvallea584721998-11-01 16:22:07 +00005232windows/Makefile
Patrik Stridvallf638aef1998-12-07 09:36:13 +00005233windows/ttydrv/Makefile
Patrik Stridvallea584721998-11-01 16:22:07 +00005234windows/x11drv/Makefile include/config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00005235EOF
5236cat >> $CONFIG_STATUS <<EOF
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00005237
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00005238# Protect against being on the right side of a sed subst in config.status.
5239sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
5240 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00005241$ac_vpsub
5242$extrasub
5243s%@CFLAGS@%$CFLAGS%g
5244s%@CPPFLAGS@%$CPPFLAGS%g
5245s%@CXXFLAGS@%$CXXFLAGS%g
5246s%@DEFS@%$DEFS%g
5247s%@LDFLAGS@%$LDFLAGS%g
5248s%@LIBS@%$LIBS%g
5249s%@exec_prefix@%$exec_prefix%g
5250s%@prefix@%$prefix%g
5251s%@program_transform_name@%$program_transform_name%g
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00005252s%@bindir@%$bindir%g
5253s%@sbindir@%$sbindir%g
5254s%@libexecdir@%$libexecdir%g
5255s%@datadir@%$datadir%g
5256s%@sysconfdir@%$sysconfdir%g
5257s%@sharedstatedir@%$sharedstatedir%g
5258s%@localstatedir@%$localstatedir%g
5259s%@libdir@%$libdir%g
5260s%@includedir@%$includedir%g
5261s%@oldincludedir@%$oldincludedir%g
5262s%@infodir@%$infodir%g
5263s%@mandir@%$mandir%g
Alexandre Julliardc6c09441997-01-12 18:32:19 +00005264s%@PROGEXT@%$PROGEXT%g
Alexandre Julliardff8331e1995-09-18 11:19:54 +00005265s%@MAIN_TARGET@%$MAIN_TARGET%g
Alexandre Julliarda0b2b1d1997-11-16 17:38:29 +00005266s%@LIB_TARGET@%$LIB_TARGET%g
Uwe Bonnes2a4707a1998-10-11 14:57:08 +00005267s%@ALT_LINK@%$ALT_LINK%g
Alexandre Julliard18f92e71996-07-17 20:02:21 +00005268s%@OPTIONS@%$OPTIONS%g
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00005269s%@SET_MAKE@%$SET_MAKE%g
5270s%@CC@%$CC%g
5271s%@CPP@%$CPP%g
Alexandre Julliardff8331e1995-09-18 11:19:54 +00005272s%@X_CFLAGS@%$X_CFLAGS%g
5273s%@X_PRE_LIBS@%$X_PRE_LIBS%g
5274s%@X_LIBS@%$X_LIBS%g
5275s%@X_EXTRA_LIBS@%$X_EXTRA_LIBS%g
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00005276s%@YACC@%$YACC%g
5277s%@LEX@%$LEX%g
5278s%@LEXLIB@%$LEXLIB%g
Alexandre Julliardff8331e1995-09-18 11:19:54 +00005279s%@RANLIB@%$RANLIB%g
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00005280s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
5281s%@INSTALL_DATA@%$INSTALL_DATA%g
Alexandre Julliard641ee761997-08-04 16:34:36 +00005282s%@LN_S@%$LN_S%g
Alexandre Julliardc7c217b1998-04-13 12:21:30 +00005283s%@C2MAN@%$C2MAN%g
Patrik Stridvallea584721998-11-01 16:22:07 +00005284s%@XLIB@%$XLIB%g
Alexandre Julliarda0b2b1d1997-11-16 17:38:29 +00005285s%@DLLFLAGS@%$DLLFLAGS%g
Todd Vierling4b992b01998-12-15 15:26:27 +00005286s%@LDSHARED@%$LDSHARED%g
Patrik Stridvall1bb94031999-05-08 15:47:44 +00005287s%@ALLOCA@%$ALLOCA%g
Marcus Meissnera7f5cb51999-04-16 08:47:41 +00005288s%@GCC_NO_BUILTIN@%$GCC_NO_BUILTIN%g
Alexandre Julliardff8331e1995-09-18 11:19:54 +00005289/@MAKE_RULES@/r $MAKE_RULES
5290s%@MAKE_RULES@%%g
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00005291
5292CEOF
5293EOF
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00005294
5295cat >> $CONFIG_STATUS <<\EOF
5296
5297# Split the substitutions into bite-sized pieces for seds with
5298# small command number limits, like on Digital OSF/1 and HP-UX.
5299ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
5300ac_file=1 # Number of current file.
5301ac_beg=1 # First line for current file.
5302ac_end=$ac_max_sed_cmds # Line after last line for current file.
5303ac_more_lines=:
5304ac_sed_cmds=""
5305while $ac_more_lines; do
5306 if test $ac_beg -gt 1; then
5307 sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
5308 else
5309 sed "${ac_end}q" conftest.subs > conftest.s$ac_file
5310 fi
5311 if test ! -s conftest.s$ac_file; then
5312 ac_more_lines=false
5313 rm -f conftest.s$ac_file
5314 else
5315 if test -z "$ac_sed_cmds"; then
5316 ac_sed_cmds="sed -f conftest.s$ac_file"
5317 else
5318 ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
5319 fi
5320 ac_file=`expr $ac_file + 1`
5321 ac_beg=$ac_end
5322 ac_end=`expr $ac_end + $ac_max_sed_cmds`
5323 fi
5324done
5325if test -z "$ac_sed_cmds"; then
5326 ac_sed_cmds=cat
5327fi
5328EOF
5329
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00005330cat >> $CONFIG_STATUS <<EOF
5331
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00005332CONFIG_FILES=\${CONFIG_FILES-"Make.rules
5333Makefile
Joseph Pranevich791cd6a1998-12-02 19:58:08 +00005334console/Makefile
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00005335controls/Makefile
5336debugger/Makefile
Alexandre Julliard85ed45e1998-08-22 19:03:56 +00005337dlls/Makefile
Juergen Schmiedf7b0de31999-01-03 12:48:29 +00005338dlls/advapi32/Makefile
Marcus Meissnerb3d1a221999-03-13 18:07:44 +00005339dlls/avifil32/Makefile
Alexandre Julliarda0d77311998-09-13 16:32:00 +00005340dlls/comctl32/Makefile
Klaas van Gendc9127491999-02-28 20:05:11 +00005341dlls/commdlg/Makefile
Patrik Stridvall8295c861998-10-11 17:09:05 +00005342dlls/imagehlp/Makefile
5343dlls/msacm/Makefile
5344dlls/msacm32/Makefile
Marcus Meissner51505b11998-11-01 14:00:21 +00005345dlls/ntdll/Makefile
Alexandre Julliardd30dfd21998-09-27 18:28:36 +00005346dlls/psapi/Makefile
Marcus Meissner30ef8771998-12-11 13:26:26 +00005347dlls/rasapi32/Makefile
Alexandre Julliard85ed45e1998-08-22 19:03:56 +00005348dlls/shell32/Makefile
Andreas Mohr5aa96c11999-03-14 12:34:25 +00005349dlls/tapi32/Makefile
Ulrich Weigandd43a46a1999-01-31 10:11:04 +00005350dlls/ver/Makefile
5351dlls/version/Makefile
Alexandre Julliardd30dfd21998-09-27 18:28:36 +00005352dlls/winaspi/Makefile
5353dlls/wnaspi32/Makefile
Alexandre Julliardd37eb361997-07-20 16:23:21 +00005354documentation/Makefile
Alexandre Julliard4f8c37b1996-01-14 18:12:01 +00005355files/Makefile
Alexandre Julliard0e270f41996-08-24 18:26:35 +00005356graphics/Makefile
Huw D M Davies3a24f3f1999-05-02 10:15:16 +00005357graphics/enhmetafiledrv/Makefile
Alexandre Julliardbf9130a1996-10-13 17:45:47 +00005358graphics/metafiledrv/Makefile
Alexandre Julliardebfc0fe1998-06-28 18:40:26 +00005359graphics/psdrv/Makefile
Patrik Stridvall24110281999-02-04 10:09:54 +00005360graphics/ttydrv/Makefile
Alexandre Julliard0e270f41996-08-24 18:26:35 +00005361graphics/win16drv/Makefile
5362graphics/x11drv/Makefile
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00005363if1632/Makefile
James Juranc70dc831999-02-13 12:18:33 +00005364include/Makefile
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00005365ipc/Makefile
5366library/Makefile
5367libtest/Makefile
5368loader/Makefile
Alexandre Julliard46ea8b31998-05-03 19:01:20 +00005369loader/ne/Makefile
Alexandre Julliard767e6f61998-08-09 12:47:43 +00005370loader/dos/Makefile
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00005371memory/Makefile
5372misc/Makefile
5373miscemu/Makefile
Alexandre Julliard9ea19e51997-01-01 17:29:55 +00005374msdos/Makefile
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00005375multimedia/Makefile
5376objects/Makefile
Alexandre Julliarde658d821997-11-30 17:45:40 +00005377ole/Makefile
Alexandre Julliard02ed4c21996-03-02 19:34:10 +00005378programs/Makefile
Alexandre Julliarda11d7b11998-03-01 20:05:02 +00005379programs/clock/Makefile
Eric Williams30008a01999-02-05 17:40:47 +00005380programs/cmdlgtst/Makefile
Alexandre Julliardd30dfd21998-09-27 18:28:36 +00005381programs/control/Makefile
Marcus Meissner32b32d81999-01-29 15:12:10 +00005382programs/avitools/Makefile
Alexandre Julliard44ed71f1997-12-21 19:17:50 +00005383programs/notepad/Makefile
Alexandre Julliard02ed4c21996-03-02 19:34:10 +00005384programs/progman/Makefile
Alexandre Julliarddadf78f1998-05-17 17:13:43 +00005385programs/regtest/Makefile
Sylvain St.Germain1bb0e661999-03-14 14:00:22 +00005386programs/regapi/Makefile
Alexandre Julliarda11d7b11998-03-01 20:05:02 +00005387programs/view/Makefile
Alexandre Julliard1285c2f1996-05-06 16:06:24 +00005388programs/winhelp/Makefile
Alexandre Julliarde658d821997-11-30 17:45:40 +00005389programs/winver/Makefile
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00005390rc/Makefile
Alexandre Julliard44ed71f1997-12-21 19:17:50 +00005391relay32/Makefile
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00005392resources/Makefile
Alexandre Julliard9ea19e51997-01-01 17:29:55 +00005393scheduler/Makefile
Alexandre Julliard642d3131998-07-12 19:29:36 +00005394server/Makefile
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00005395tools/Makefile
Alexandre Julliarda845b881998-06-01 10:44:35 +00005396tools/wrc/Makefile
Alexandre Julliard60ce85c1998-02-01 18:33:27 +00005397tsx11/Makefile
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00005398win32/Makefile
Patrik Stridvallea584721998-11-01 16:22:07 +00005399windows/Makefile
Patrik Stridvallf638aef1998-12-07 09:36:13 +00005400windows/ttydrv/Makefile
Patrik Stridvallea584721998-11-01 16:22:07 +00005401windows/x11drv/Makefile "}
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00005402EOF
5403cat >> $CONFIG_STATUS <<\EOF
5404for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +00005405 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00005406 case "$ac_file" in
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +00005407 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00005408 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
5409 *) ac_file_in="${ac_file}.in" ;;
5410 esac
5411
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00005412 # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00005413
5414 # Remove last slash and all that follows it. Not all systems have dirname.
5415 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
5416 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
5417 # The file is in a subdirectory.
5418 test ! -d "$ac_dir" && mkdir "$ac_dir"
5419 ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
5420 # A "../" for each directory in $ac_dir_suffix.
5421 ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
5422 else
5423 ac_dir_suffix= ac_dots=
5424 fi
5425
5426 case "$ac_given_srcdir" in
5427 .) srcdir=.
5428 if test -z "$ac_dots"; then top_srcdir=.
5429 else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
5430 /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
5431 *) # Relative path.
5432 srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
5433 top_srcdir="$ac_dots$ac_given_srcdir" ;;
5434 esac
5435
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00005436 case "$ac_given_INSTALL" in
5437 [/$]*) INSTALL="$ac_given_INSTALL" ;;
5438 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
5439 esac
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00005440
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00005441 echo creating "$ac_file"
5442 rm -f "$ac_file"
5443 configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
5444 case "$ac_file" in
5445 *Makefile*) ac_comsub="1i\\
5446# $configure_input" ;;
5447 *) ac_comsub= ;;
5448 esac
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +00005449
5450 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00005451 sed -e "$ac_comsub
5452s%@configure_input@%$configure_input%g
5453s%@srcdir@%$srcdir%g
5454s%@top_srcdir@%$top_srcdir%g
Alexandre Julliardd7d4fdf1995-12-26 15:05:24 +00005455s%@INSTALL@%$INSTALL%g
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +00005456" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00005457fi; done
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00005458rm -f conftest.s*
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00005459
Alexandre Julliard18f92e71996-07-17 20:02:21 +00005460# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
5461# NAME is the cpp macro being defined and VALUE is the value it is being given.
5462#
5463# ac_d sets the value in "#define NAME VALUE" lines.
5464ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)'
5465ac_dB='\([ ][ ]*\)[^ ]*%\1#\2'
5466ac_dC='\3'
5467ac_dD='%g'
5468# ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
5469ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
5470ac_uB='\([ ]\)%\1#\2define\3'
5471ac_uC=' '
5472ac_uD='\4%g'
5473# ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
5474ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
5475ac_eB='$%\1#\2define\3'
5476ac_eC=' '
5477ac_eD='%g'
5478
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +00005479if test "${CONFIG_HEADERS+set}" != set; then
Alexandre Julliardda0cfb31996-12-01 17:17:47 +00005480EOF
5481cat >> $CONFIG_STATUS <<EOF
5482 CONFIG_HEADERS="include/config.h"
5483EOF
5484cat >> $CONFIG_STATUS <<\EOF
5485fi
Alexandre Julliard18f92e71996-07-17 20:02:21 +00005486for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +00005487 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
Alexandre Julliard18f92e71996-07-17 20:02:21 +00005488 case "$ac_file" in
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +00005489 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
Alexandre Julliard18f92e71996-07-17 20:02:21 +00005490 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
5491 *) ac_file_in="${ac_file}.in" ;;
5492 esac
5493
5494 echo creating $ac_file
5495
5496 rm -f conftest.frag conftest.in conftest.out
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +00005497 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
5498 cat $ac_file_inputs > conftest.in
Alexandre Julliard18f92e71996-07-17 20:02:21 +00005499
5500EOF
5501
5502# Transform confdefs.h into a sed script conftest.vals that substitutes
5503# the proper values into config.h.in to produce config.h. And first:
5504# Protect against being on the right side of a sed subst in config.status.
5505# Protect against being in an unquoted here document in config.status.
5506rm -f conftest.vals
5507cat > conftest.hdr <<\EOF
5508s/[\\&%]/\\&/g
5509s%[\\$`]%\\&%g
5510s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
5511s%ac_d%ac_u%gp
5512s%ac_u%ac_e%gp
5513EOF
5514sed -n -f conftest.hdr confdefs.h > conftest.vals
5515rm -f conftest.hdr
5516
5517# This sed command replaces #undef with comments. This is necessary, for
5518# example, in the case of _POSIX_SOURCE, which is predefined and required
5519# on some systems where configure will not decide to define it.
5520cat >> conftest.vals <<\EOF
5521s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
5522EOF
5523
5524# Break up conftest.vals because some shells have a limit on
5525# the size of here documents, and old seds have small limits too.
Alexandre Julliard18f92e71996-07-17 20:02:21 +00005526
5527rm -f conftest.tail
5528while :
5529do
5530 ac_lines=`grep -c . conftest.vals`
5531 # grep -c gives empty output for an empty file on some AIX systems.
5532 if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
5533 # Write a limited-size here document to conftest.frag.
5534 echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
5535 sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
5536 echo 'CEOF
5537 sed -f conftest.frag conftest.in > conftest.out
5538 rm -f conftest.in
5539 mv conftest.out conftest.in
5540' >> $CONFIG_STATUS
5541 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
5542 rm -f conftest.vals
5543 mv conftest.tail conftest.vals
5544done
5545rm -f conftest.vals
5546
5547cat >> $CONFIG_STATUS <<\EOF
5548 rm -f conftest.frag conftest.h
5549 echo "/* $ac_file. Generated automatically by configure. */" > conftest.h
5550 cat conftest.in >> conftest.h
5551 rm -f conftest.in
5552 if cmp -s $ac_file conftest.h 2>/dev/null; then
5553 echo "$ac_file is unchanged"
5554 rm -f conftest.h
5555 else
5556 # Remove last slash and all that follows it. Not all systems have dirname.
5557 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
5558 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
5559 # The file is in a subdirectory.
5560 test ! -d "$ac_dir" && mkdir "$ac_dir"
5561 fi
5562 rm -f $ac_file
5563 mv conftest.h $ac_file
5564 fi
5565fi; done
5566
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +00005567EOF
5568cat >> $CONFIG_STATUS <<EOF
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00005569
Alexandre Julliard7e6ae4b1996-12-08 19:25:27 +00005570EOF
5571cat >> $CONFIG_STATUS <<\EOF
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00005572
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00005573exit 0
5574EOF
5575chmod +x $CONFIG_STATUS
5576rm -fr confdefs* $ac_clean_files
5577test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
5578
5579
Ove Kaaven8b4431f1999-01-23 13:59:11 +00005580if test "$have_x" = "no"
5581then
5582 echo
5583 echo "*** Warning: X development files not found. Wine will be built without"
5584 echo "*** X support, which currently does not work, and would probably not be"
5585 echo "*** what you want anyway. You will need to install devel packages of"
5586 echo "*** Xlib/Xfree86 and Xpm at the very least."
Ove Kaaven1eb593c1999-02-14 09:34:46 +00005587elif test "$ac_cv_lib_Xpm_XpmCreatePixmapFromData" = "no"
5588then
5589 echo
5590 echo "*** Warning: Xpm development files not found. Wine will be built without"
5591 echo "*** Xpm support, which currently does not work. You will need to install"
5592 echo "*** devel packages of Xpm."
Ove Kaaven8b4431f1999-01-23 13:59:11 +00005593fi
5594
Alexandre Julliard638f1691999-01-17 16:32:32 +00005595if test "$ac_cv_lib_ncurses_resizeterm" = "no" -a "$ac_cv_lib_ncurses_waddch" = "yes"
5596then
5597 echo
5598 echo "*** Warning: resizeterm not found in ncurses. Wine will be built without"
5599 echo "*** terminal resize support. Consider upgrading ncurses."
Alexandre Julliard638f1691999-01-17 16:32:32 +00005600fi
5601
Alexandre Julliardd30dfd21998-09-27 18:28:36 +00005602if test "$wine_cv_libc_reentrant" = "no"
5603then
5604 echo
5605 echo "*** Warning: non-reentrant libc detected. Wine will be build without"
5606 echo "*** thread support. Consider upgrading libc to a more recent"
5607 echo "*** reentrant version of libc."
Alexandre Julliardd30dfd21998-09-27 18:28:36 +00005608fi
5609
Lionel Ulmer5c085701999-02-28 19:48:53 +00005610if test "$wine_cv_mesa_version_OK" = "no"
5611then
5612 echo
5613 echo "*** Warning: old Mesa headers detected. Wine will be built without Direct3D"
5614 echo "*** support. Consider upgrading your Mesa libraries (http://www.mesa3d.org/)"
5615fi
5616
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00005617echo
Steffen Moeller1511bae1999-02-17 15:27:03 +00005618echo "Configure finished. Do 'make depend && make' to compile Wine."
Alexandre Julliarde2991ea1995-07-29 13:09:43 +00005619echo
5620