ViewVC Help
View File | Revision Log | Show Annotations | Revision Graph | Root Listing
root/cebix/BasiliskII/src/Unix/configure
Revision: 1.15
Committed: 1999-11-03T10:56:23Z (24 years, 10 months ago) by cebix
Branch: MAIN
Changes since 1.14: +1 -1 lines
Log Message:
- imported UAE CPU 0.8.10 changes
- new utility functions Mac_memset, Mac2Host_memcpy, Host2Mac_memcpu and
  Mac2Mac_memcpy
- extfs.cpp: fixed bug in fs_rename() and fs_cat_move() (auxiliary IOParam
  block was not in Mac address space)
- some provisions for using UAE CPU compiler (doesn't work yet)

File Contents

# User Rev Content
1 cebix 1.1 #! /bin/sh
2    
3     # Guess values for system-dependent variables and create Makefiles.
4     # Generated automatically using autoconf version 2.13
5     # Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
6     #
7     # This configure script is free software; the Free Software Foundation
8     # gives unlimited permission to copy, distribute and modify it.
9    
10     # Defaults:
11     ac_help=
12     ac_default_prefix=/usr/local
13     # Any additions from configure.in:
14     ac_help="$ac_help
15 cebix 1.9 --enable-xf86-dga use the XFree86 DGA extension [default=yes]"
16 cebix 1.7 ac_help="$ac_help
17 cebix 1.9 --enable-fbdev-dga use direct frame buffer access via /dev/fb [default=yes]"
18 cebix 1.1 ac_help="$ac_help
19 cebix 1.13 --with-esd support ESD for sound under Linux/FreeBSD [default=yes]"
20 cebix 1.9 ac_help="$ac_help
21 cebix 1.13 --with-gtk use GTK user interface [default=yes]"
22     ac_help="$ac_help
23     --with-mon use mon as debugger [default=yes]"
24 cebix 1.1 ac_help="$ac_help
25     --with-x use the X Window System"
26     ac_help="$ac_help
27     --with-gtk-prefix=PFX Prefix where GTK is installed (optional)"
28     ac_help="$ac_help
29     --with-gtk-exec-prefix=PFX Exec prefix where GTK is installed (optional)"
30     ac_help="$ac_help
31     --disable-gtktest Do not try to compile and run a test GTK program"
32 cebix 1.9 ac_help="$ac_help
33     --with-esd-prefix=PFX Prefix where ESD is installed (optional)"
34     ac_help="$ac_help
35     --with-esd-exec-prefix=PFX Exec prefix where ESD is installed (optional)"
36     ac_help="$ac_help
37     --disable-esdtest Do not try to compile and run a test ESD program"
38 cebix 1.1
39     # Initialize some variables set by options.
40     # The variables have the same names as the options, with
41     # dashes changed to underlines.
42     build=NONE
43     cache_file=./config.cache
44     exec_prefix=NONE
45     host=NONE
46     no_create=
47     nonopt=NONE
48     no_recursion=
49     prefix=NONE
50     program_prefix=NONE
51     program_suffix=NONE
52     program_transform_name=s,x,x,
53     silent=
54     site=
55     srcdir=
56     target=NONE
57     verbose=
58     x_includes=NONE
59     x_libraries=NONE
60     bindir='${exec_prefix}/bin'
61     sbindir='${exec_prefix}/sbin'
62     libexecdir='${exec_prefix}/libexec'
63     datadir='${prefix}/share'
64     sysconfdir='${prefix}/etc'
65     sharedstatedir='${prefix}/com'
66     localstatedir='${prefix}/var'
67     libdir='${exec_prefix}/lib'
68     includedir='${prefix}/include'
69     oldincludedir='/usr/include'
70     infodir='${prefix}/info'
71     mandir='${prefix}/man'
72    
73     # Initialize some other variables.
74     subdirs=
75     MFLAGS= MAKEFLAGS=
76     SHELL=${CONFIG_SHELL-/bin/sh}
77     # Maximum number of lines to put in a shell here document.
78     ac_max_here_lines=12
79    
80     ac_prev=
81     for ac_option
82     do
83    
84     # If the previous option needs an argument, assign it.
85     if test -n "$ac_prev"; then
86     eval "$ac_prev=\$ac_option"
87     ac_prev=
88     continue
89     fi
90    
91     case "$ac_option" in
92     -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
93     *) ac_optarg= ;;
94     esac
95    
96     # Accept the important Cygnus configure options, so we can diagnose typos.
97    
98     case "$ac_option" in
99    
100     -bindir | --bindir | --bindi | --bind | --bin | --bi)
101     ac_prev=bindir ;;
102     -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
103     bindir="$ac_optarg" ;;
104    
105     -build | --build | --buil | --bui | --bu)
106     ac_prev=build ;;
107     -build=* | --build=* | --buil=* | --bui=* | --bu=*)
108     build="$ac_optarg" ;;
109    
110     -cache-file | --cache-file | --cache-fil | --cache-fi \
111     | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
112     ac_prev=cache_file ;;
113     -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
114     | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
115     cache_file="$ac_optarg" ;;
116    
117     -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
118     ac_prev=datadir ;;
119     -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
120     | --da=*)
121     datadir="$ac_optarg" ;;
122    
123     -disable-* | --disable-*)
124     ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
125     # Reject names that are not valid shell variable names.
126     if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
127     { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
128     fi
129     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
130     eval "enable_${ac_feature}=no" ;;
131    
132     -enable-* | --enable-*)
133     ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
134     # Reject names that are not valid shell variable names.
135     if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
136     { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
137     fi
138     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
139     case "$ac_option" in
140     *=*) ;;
141     *) ac_optarg=yes ;;
142     esac
143     eval "enable_${ac_feature}='$ac_optarg'" ;;
144    
145     -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
146     | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
147     | --exec | --exe | --ex)
148     ac_prev=exec_prefix ;;
149     -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
150     | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
151     | --exec=* | --exe=* | --ex=*)
152     exec_prefix="$ac_optarg" ;;
153    
154     -gas | --gas | --ga | --g)
155     # Obsolete; use --with-gas.
156     with_gas=yes ;;
157    
158     -help | --help | --hel | --he)
159     # Omit some internal or obsolete options to make the list less imposing.
160     # This message is too long to be a string in the A/UX 3.1 sh.
161     cat << EOF
162     Usage: configure [options] [host]
163     Options: [defaults in brackets after descriptions]
164     Configuration:
165     --cache-file=FILE cache test results in FILE
166     --help print this message
167     --no-create do not create output files
168     --quiet, --silent do not print \`checking...' messages
169     --version print the version of autoconf that created configure
170     Directory and file names:
171     --prefix=PREFIX install architecture-independent files in PREFIX
172     [$ac_default_prefix]
173     --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
174     [same as prefix]
175     --bindir=DIR user executables in DIR [EPREFIX/bin]
176     --sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
177     --libexecdir=DIR program executables in DIR [EPREFIX/libexec]
178     --datadir=DIR read-only architecture-independent data in DIR
179     [PREFIX/share]
180     --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
181     --sharedstatedir=DIR modifiable architecture-independent data in DIR
182     [PREFIX/com]
183     --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
184     --libdir=DIR object code libraries in DIR [EPREFIX/lib]
185     --includedir=DIR C header files in DIR [PREFIX/include]
186     --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
187     --infodir=DIR info documentation in DIR [PREFIX/info]
188     --mandir=DIR man documentation in DIR [PREFIX/man]
189     --srcdir=DIR find the sources in DIR [configure dir or ..]
190     --program-prefix=PREFIX prepend PREFIX to installed program names
191     --program-suffix=SUFFIX append SUFFIX to installed program names
192     --program-transform-name=PROGRAM
193     run sed PROGRAM on installed program names
194     EOF
195     cat << EOF
196     Host type:
197     --build=BUILD configure for building on BUILD [BUILD=HOST]
198     --host=HOST configure for HOST [guessed]
199     --target=TARGET configure for TARGET [TARGET=HOST]
200     Features and packages:
201     --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
202     --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
203     --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
204     --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
205     --x-includes=DIR X include files are in DIR
206     --x-libraries=DIR X library files are in DIR
207     EOF
208     if test -n "$ac_help"; then
209     echo "--enable and --with options recognized:$ac_help"
210     fi
211     exit 0 ;;
212    
213     -host | --host | --hos | --ho)
214     ac_prev=host ;;
215     -host=* | --host=* | --hos=* | --ho=*)
216     host="$ac_optarg" ;;
217    
218     -includedir | --includedir | --includedi | --included | --include \
219     | --includ | --inclu | --incl | --inc)
220     ac_prev=includedir ;;
221     -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
222     | --includ=* | --inclu=* | --incl=* | --inc=*)
223     includedir="$ac_optarg" ;;
224    
225     -infodir | --infodir | --infodi | --infod | --info | --inf)
226     ac_prev=infodir ;;
227     -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
228     infodir="$ac_optarg" ;;
229    
230     -libdir | --libdir | --libdi | --libd)
231     ac_prev=libdir ;;
232     -libdir=* | --libdir=* | --libdi=* | --libd=*)
233     libdir="$ac_optarg" ;;
234    
235     -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
236     | --libexe | --libex | --libe)
237     ac_prev=libexecdir ;;
238     -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
239     | --libexe=* | --libex=* | --libe=*)
240     libexecdir="$ac_optarg" ;;
241    
242     -localstatedir | --localstatedir | --localstatedi | --localstated \
243     | --localstate | --localstat | --localsta | --localst \
244     | --locals | --local | --loca | --loc | --lo)
245     ac_prev=localstatedir ;;
246     -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
247     | --localstate=* | --localstat=* | --localsta=* | --localst=* \
248     | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
249     localstatedir="$ac_optarg" ;;
250    
251     -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
252     ac_prev=mandir ;;
253     -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
254     mandir="$ac_optarg" ;;
255    
256     -nfp | --nfp | --nf)
257     # Obsolete; use --without-fp.
258     with_fp=no ;;
259    
260     -no-create | --no-create | --no-creat | --no-crea | --no-cre \
261     | --no-cr | --no-c)
262     no_create=yes ;;
263    
264     -no-recursion | --no-recursion | --no-recursio | --no-recursi \
265     | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
266     no_recursion=yes ;;
267    
268     -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
269     | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
270     | --oldin | --oldi | --old | --ol | --o)
271     ac_prev=oldincludedir ;;
272     -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
273     | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
274     | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
275     oldincludedir="$ac_optarg" ;;
276    
277     -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
278     ac_prev=prefix ;;
279     -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
280     prefix="$ac_optarg" ;;
281    
282     -program-prefix | --program-prefix | --program-prefi | --program-pref \
283     | --program-pre | --program-pr | --program-p)
284     ac_prev=program_prefix ;;
285     -program-prefix=* | --program-prefix=* | --program-prefi=* \
286     | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
287     program_prefix="$ac_optarg" ;;
288    
289     -program-suffix | --program-suffix | --program-suffi | --program-suff \
290     | --program-suf | --program-su | --program-s)
291     ac_prev=program_suffix ;;
292     -program-suffix=* | --program-suffix=* | --program-suffi=* \
293     | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
294     program_suffix="$ac_optarg" ;;
295    
296     -program-transform-name | --program-transform-name \
297     | --program-transform-nam | --program-transform-na \
298     | --program-transform-n | --program-transform- \
299     | --program-transform | --program-transfor \
300     | --program-transfo | --program-transf \
301     | --program-trans | --program-tran \
302     | --progr-tra | --program-tr | --program-t)
303     ac_prev=program_transform_name ;;
304     -program-transform-name=* | --program-transform-name=* \
305     | --program-transform-nam=* | --program-transform-na=* \
306     | --program-transform-n=* | --program-transform-=* \
307     | --program-transform=* | --program-transfor=* \
308     | --program-transfo=* | --program-transf=* \
309     | --program-trans=* | --program-tran=* \
310     | --progr-tra=* | --program-tr=* | --program-t=*)
311     program_transform_name="$ac_optarg" ;;
312    
313     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
314     | -silent | --silent | --silen | --sile | --sil)
315     silent=yes ;;
316    
317     -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
318     ac_prev=sbindir ;;
319     -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
320     | --sbi=* | --sb=*)
321     sbindir="$ac_optarg" ;;
322    
323     -sharedstatedir | --sharedstatedir | --sharedstatedi \
324     | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
325     | --sharedst | --shareds | --shared | --share | --shar \
326     | --sha | --sh)
327     ac_prev=sharedstatedir ;;
328     -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
329     | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
330     | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
331     | --sha=* | --sh=*)
332     sharedstatedir="$ac_optarg" ;;
333    
334     -site | --site | --sit)
335     ac_prev=site ;;
336     -site=* | --site=* | --sit=*)
337     site="$ac_optarg" ;;
338    
339     -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
340     ac_prev=srcdir ;;
341     -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
342     srcdir="$ac_optarg" ;;
343    
344     -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
345     | --syscon | --sysco | --sysc | --sys | --sy)
346     ac_prev=sysconfdir ;;
347     -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
348     | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
349     sysconfdir="$ac_optarg" ;;
350    
351     -target | --target | --targe | --targ | --tar | --ta | --t)
352     ac_prev=target ;;
353     -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
354     target="$ac_optarg" ;;
355    
356     -v | -verbose | --verbose | --verbos | --verbo | --verb)
357     verbose=yes ;;
358    
359     -version | --version | --versio | --versi | --vers)
360     echo "configure generated by autoconf version 2.13"
361     exit 0 ;;
362    
363     -with-* | --with-*)
364     ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
365     # Reject names that are not valid shell variable names.
366     if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
367     { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
368     fi
369     ac_package=`echo $ac_package| sed 's/-/_/g'`
370     case "$ac_option" in
371     *=*) ;;
372     *) ac_optarg=yes ;;
373     esac
374     eval "with_${ac_package}='$ac_optarg'" ;;
375    
376     -without-* | --without-*)
377     ac_package=`echo $ac_option|sed -e 's/-*without-//'`
378     # Reject names that are not valid shell variable names.
379     if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
380     { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
381     fi
382     ac_package=`echo $ac_package| sed 's/-/_/g'`
383     eval "with_${ac_package}=no" ;;
384    
385     --x)
386     # Obsolete; use --with-x.
387     with_x=yes ;;
388    
389     -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
390     | --x-incl | --x-inc | --x-in | --x-i)
391     ac_prev=x_includes ;;
392     -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
393     | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
394     x_includes="$ac_optarg" ;;
395    
396     -x-libraries | --x-libraries | --x-librarie | --x-librari \
397     | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
398     ac_prev=x_libraries ;;
399     -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
400     | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
401     x_libraries="$ac_optarg" ;;
402    
403     -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
404     ;;
405    
406     *)
407     if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
408     echo "configure: warning: $ac_option: invalid host type" 1>&2
409     fi
410     if test "x$nonopt" != xNONE; then
411     { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
412     fi
413     nonopt="$ac_option"
414     ;;
415    
416     esac
417     done
418    
419     if test -n "$ac_prev"; then
420     { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
421     fi
422    
423     trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
424    
425     # File descriptor usage:
426     # 0 standard input
427     # 1 file creation
428     # 2 errors and warnings
429     # 3 some systems may open it to /dev/tty
430     # 4 used on the Kubota Titan
431     # 6 checking for... messages and results
432     # 5 compiler messages saved in config.log
433     if test "$silent" = yes; then
434     exec 6>/dev/null
435     else
436     exec 6>&1
437     fi
438     exec 5>./config.log
439    
440     echo "\
441     This file contains any messages produced by compilers while
442     running configure, to aid debugging if configure makes a mistake.
443     " 1>&5
444    
445     # Strip out --no-create and --no-recursion so they do not pile up.
446     # Also quote any args containing shell metacharacters.
447     ac_configure_args=
448     for ac_arg
449     do
450     case "$ac_arg" in
451     -no-create | --no-create | --no-creat | --no-crea | --no-cre \
452     | --no-cr | --no-c) ;;
453     -no-recursion | --no-recursion | --no-recursio | --no-recursi \
454     | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
455     *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
456     ac_configure_args="$ac_configure_args '$ac_arg'" ;;
457     *) ac_configure_args="$ac_configure_args $ac_arg" ;;
458     esac
459     done
460    
461     # NLS nuisances.
462     # Only set these to C if already set. These must not be set unconditionally
463     # because not all systems understand e.g. LANG=C (notably SCO).
464     # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
465     # Non-C LC_CTYPE values break the ctype check.
466     if test "${LANG+set}" = set; then LANG=C; export LANG; fi
467     if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
468     if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
469     if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi
470    
471     # confdefs.h avoids OS command line length limits that DEFS can exceed.
472     rm -rf conftest* confdefs.h
473     # AIX cpp loses on an empty file, so make sure it contains at least a newline.
474     echo > confdefs.h
475    
476     # A filename unique to this package, relative to the directory that
477     # configure is in, which we can look for to find out if srcdir is correct.
478     ac_unique_file=main_unix.cpp
479    
480     # Find the source files, if location was not specified.
481     if test -z "$srcdir"; then
482     ac_srcdir_defaulted=yes
483     # Try the directory containing this script, then its parent.
484     ac_prog=$0
485     ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
486     test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
487     srcdir=$ac_confdir
488     if test ! -r $srcdir/$ac_unique_file; then
489     srcdir=..
490     fi
491     else
492     ac_srcdir_defaulted=no
493     fi
494     if test ! -r $srcdir/$ac_unique_file; then
495     if test "$ac_srcdir_defaulted" = yes; then
496     { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
497     else
498     { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
499     fi
500     fi
501     srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
502    
503     # Prefer explicitly selected file to automatically selected ones.
504     if test -z "$CONFIG_SITE"; then
505     if test "x$prefix" != xNONE; then
506     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
507     else
508     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
509     fi
510     fi
511     for ac_site_file in $CONFIG_SITE; do
512     if test -r "$ac_site_file"; then
513     echo "loading site script $ac_site_file"
514     . "$ac_site_file"
515     fi
516     done
517    
518     if test -r "$cache_file"; then
519     echo "loading cache $cache_file"
520     . $cache_file
521     else
522     echo "creating cache $cache_file"
523     > $cache_file
524     fi
525    
526     ac_ext=c
527     # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
528     ac_cpp='$CPP $CPPFLAGS'
529     ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
530     ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
531     cross_compiling=$ac_cv_prog_cc_cross
532    
533     ac_exeext=
534     ac_objext=o
535     if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
536     # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
537     if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
538     ac_n= ac_c='
539     ' ac_t=' '
540     else
541     ac_n=-n ac_c= ac_t=
542     fi
543     else
544     ac_n= ac_c='\c' ac_t=
545     fi
546    
547    
548    
549    
550    
551 cebix 1.7 # Check whether --enable-xf86-dga or --disable-xf86-dga was given.
552     if test "${enable_xf86_dga+set}" = set; then
553     enableval="$enable_xf86_dga"
554     WANT_XF86_DGA=$enableval
555 cebix 1.11 else
556     WANT_XF86_DGA=yes
557 cebix 1.7 fi
558    
559     # Check whether --enable-fbdev-dga or --disable-fbdev-dga was given.
560     if test "${enable_fbdev_dga+set}" = set; then
561     enableval="$enable_fbdev_dga"
562     WANT_FBDEV_DGA=$enableval
563 cebix 1.11 else
564     WANT_FBDEV_DGA=yes
565 cebix 1.1 fi
566    
567 cebix 1.13 # Check whether --with-esd or --without-esd was given.
568     if test "${with_esd+set}" = set; then
569     withval="$with_esd"
570     WANT_ESD=$withval
571 cebix 1.11 else
572     WANT_ESD=yes
573 cebix 1.9 fi
574    
575 cebix 1.13 # Check whether --with-gtk or --without-gtk was given.
576     if test "${with_gtk+set}" = set; then
577     withval="$with_gtk"
578     WANT_GTK=$withval
579     else
580     WANT_GTK=yes
581     fi
582    
583     # Check whether --with-mon or --without-mon was given.
584     if test "${with_mon+set}" = set; then
585     withval="$with_mon"
586     WANT_MON=$withval
587 cebix 1.11 else
588 cebix 1.13 WANT_MON=yes
589 cebix 1.1 fi
590    
591    
592     # Extract the first word of "gcc", so it can be a program name with args.
593     set dummy gcc; ac_word=$2
594     echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
595 cebix 1.13 echo "configure:596: checking for $ac_word" >&5
596 cebix 1.1 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
597     echo $ac_n "(cached) $ac_c" 1>&6
598     else
599     if test -n "$CC"; then
600     ac_cv_prog_CC="$CC" # Let the user override the test.
601     else
602     IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
603     ac_dummy="$PATH"
604     for ac_dir in $ac_dummy; do
605     test -z "$ac_dir" && ac_dir=.
606     if test -f $ac_dir/$ac_word; then
607     ac_cv_prog_CC="gcc"
608     break
609     fi
610     done
611     IFS="$ac_save_ifs"
612     fi
613     fi
614     CC="$ac_cv_prog_CC"
615     if test -n "$CC"; then
616     echo "$ac_t""$CC" 1>&6
617     else
618     echo "$ac_t""no" 1>&6
619     fi
620    
621     if test -z "$CC"; then
622     # Extract the first word of "cc", so it can be a program name with args.
623     set dummy cc; ac_word=$2
624     echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
625 cebix 1.13 echo "configure:626: checking for $ac_word" >&5
626 cebix 1.1 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
627     echo $ac_n "(cached) $ac_c" 1>&6
628     else
629     if test -n "$CC"; then
630     ac_cv_prog_CC="$CC" # Let the user override the test.
631     else
632     IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
633     ac_prog_rejected=no
634     ac_dummy="$PATH"
635     for ac_dir in $ac_dummy; do
636     test -z "$ac_dir" && ac_dir=.
637     if test -f $ac_dir/$ac_word; then
638     if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
639     ac_prog_rejected=yes
640     continue
641     fi
642     ac_cv_prog_CC="cc"
643     break
644     fi
645     done
646     IFS="$ac_save_ifs"
647     if test $ac_prog_rejected = yes; then
648     # We found a bogon in the path, so make sure we never use it.
649     set dummy $ac_cv_prog_CC
650     shift
651     if test $# -gt 0; then
652     # We chose a different compiler from the bogus one.
653     # However, it has the same basename, so the bogon will be chosen
654     # first if we set CC to just the basename; use the full file name.
655     shift
656     set dummy "$ac_dir/$ac_word" "$@"
657     shift
658     ac_cv_prog_CC="$@"
659     fi
660     fi
661     fi
662     fi
663     CC="$ac_cv_prog_CC"
664     if test -n "$CC"; then
665     echo "$ac_t""$CC" 1>&6
666     else
667     echo "$ac_t""no" 1>&6
668     fi
669    
670     if test -z "$CC"; then
671     case "`uname -s`" in
672     *win32* | *WIN32*)
673     # Extract the first word of "cl", so it can be a program name with args.
674     set dummy cl; ac_word=$2
675     echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
676 cebix 1.13 echo "configure:677: checking for $ac_word" >&5
677 cebix 1.1 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
678     echo $ac_n "(cached) $ac_c" 1>&6
679     else
680     if test -n "$CC"; then
681     ac_cv_prog_CC="$CC" # Let the user override the test.
682     else
683     IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
684     ac_dummy="$PATH"
685     for ac_dir in $ac_dummy; do
686     test -z "$ac_dir" && ac_dir=.
687     if test -f $ac_dir/$ac_word; then
688     ac_cv_prog_CC="cl"
689     break
690     fi
691     done
692     IFS="$ac_save_ifs"
693     fi
694     fi
695     CC="$ac_cv_prog_CC"
696     if test -n "$CC"; then
697     echo "$ac_t""$CC" 1>&6
698     else
699     echo "$ac_t""no" 1>&6
700     fi
701     ;;
702     esac
703     fi
704     test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
705     fi
706    
707     echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
708 cebix 1.13 echo "configure:709: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
709 cebix 1.1
710     ac_ext=c
711     # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
712     ac_cpp='$CPP $CPPFLAGS'
713     ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
714     ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
715     cross_compiling=$ac_cv_prog_cc_cross
716    
717     cat > conftest.$ac_ext << EOF
718    
719 cebix 1.13 #line 720 "configure"
720 cebix 1.1 #include "confdefs.h"
721    
722     main(){return(0);}
723     EOF
724 cebix 1.13 if { (eval echo configure:725: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
725 cebix 1.1 ac_cv_prog_cc_works=yes
726     # If we can't run a trivial program, we are probably using a cross compiler.
727     if (./conftest; exit) 2>/dev/null; then
728     ac_cv_prog_cc_cross=no
729     else
730     ac_cv_prog_cc_cross=yes
731     fi
732     else
733     echo "configure: failed program was:" >&5
734     cat conftest.$ac_ext >&5
735     ac_cv_prog_cc_works=no
736     fi
737     rm -fr conftest*
738     ac_ext=c
739     # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
740     ac_cpp='$CPP $CPPFLAGS'
741     ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
742     ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
743     cross_compiling=$ac_cv_prog_cc_cross
744    
745     echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
746     if test $ac_cv_prog_cc_works = no; then
747     { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
748     fi
749     echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
750 cebix 1.13 echo "configure:751: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
751 cebix 1.1 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
752     cross_compiling=$ac_cv_prog_cc_cross
753    
754     echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
755 cebix 1.13 echo "configure:756: checking whether we are using GNU C" >&5
756 cebix 1.1 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
757     echo $ac_n "(cached) $ac_c" 1>&6
758     else
759     cat > conftest.c <<EOF
760     #ifdef __GNUC__
761     yes;
762     #endif
763     EOF
764 cebix 1.13 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:765: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
765 cebix 1.1 ac_cv_prog_gcc=yes
766     else
767     ac_cv_prog_gcc=no
768     fi
769     fi
770    
771     echo "$ac_t""$ac_cv_prog_gcc" 1>&6
772    
773     if test $ac_cv_prog_gcc = yes; then
774     GCC=yes
775     else
776     GCC=
777     fi
778    
779     ac_test_CFLAGS="${CFLAGS+set}"
780     ac_save_CFLAGS="$CFLAGS"
781     CFLAGS=
782     echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
783 cebix 1.13 echo "configure:784: checking whether ${CC-cc} accepts -g" >&5
784 cebix 1.1 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
785     echo $ac_n "(cached) $ac_c" 1>&6
786     else
787     echo 'void f(){}' > conftest.c
788     if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
789     ac_cv_prog_cc_g=yes
790     else
791     ac_cv_prog_cc_g=no
792     fi
793     rm -f conftest*
794    
795     fi
796    
797     echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
798     if test "$ac_test_CFLAGS" = set; then
799     CFLAGS="$ac_save_CFLAGS"
800     elif test $ac_cv_prog_cc_g = yes; then
801     if test "$GCC" = yes; then
802     CFLAGS="-g -O2"
803     else
804     CFLAGS="-g"
805     fi
806     else
807     if test "$GCC" = yes; then
808     CFLAGS="-O2"
809     else
810     CFLAGS=
811     fi
812     fi
813    
814 cebix 1.3 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
815 cebix 1.13 echo "configure:816: checking how to run the C preprocessor" >&5
816 cebix 1.3 # On Suns, sometimes $CPP names a directory.
817     if test -n "$CPP" && test -d "$CPP"; then
818     CPP=
819     fi
820     if test -z "$CPP"; then
821     if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
822     echo $ac_n "(cached) $ac_c" 1>&6
823     else
824     # This must be in double quotes, not single quotes, because CPP may get
825     # substituted into the Makefile and "${CC-cc}" will confuse make.
826     CPP="${CC-cc} -E"
827     # On the NeXT, cc -E runs the code through the compiler's parser,
828     # not just through cpp.
829     cat > conftest.$ac_ext <<EOF
830 cebix 1.13 #line 831 "configure"
831 cebix 1.3 #include "confdefs.h"
832     #include <assert.h>
833     Syntax Error
834     EOF
835     ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
836 cebix 1.13 { (eval echo configure:837: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
837 cebix 1.3 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
838     if test -z "$ac_err"; then
839     :
840     else
841     echo "$ac_err" >&5
842     echo "configure: failed program was:" >&5
843     cat conftest.$ac_ext >&5
844     rm -rf conftest*
845     CPP="${CC-cc} -E -traditional-cpp"
846     cat > conftest.$ac_ext <<EOF
847 cebix 1.13 #line 848 "configure"
848 cebix 1.3 #include "confdefs.h"
849     #include <assert.h>
850     Syntax Error
851     EOF
852     ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
853 cebix 1.13 { (eval echo configure:854: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
854 cebix 1.3 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
855     if test -z "$ac_err"; then
856     :
857     else
858     echo "$ac_err" >&5
859     echo "configure: failed program was:" >&5
860     cat conftest.$ac_ext >&5
861     rm -rf conftest*
862     CPP="${CC-cc} -nologo -E"
863     cat > conftest.$ac_ext <<EOF
864 cebix 1.13 #line 865 "configure"
865 cebix 1.3 #include "confdefs.h"
866     #include <assert.h>
867     Syntax Error
868     EOF
869     ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
870 cebix 1.13 { (eval echo configure:871: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
871 cebix 1.3 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
872     if test -z "$ac_err"; then
873     :
874     else
875     echo "$ac_err" >&5
876     echo "configure: failed program was:" >&5
877     cat conftest.$ac_ext >&5
878     rm -rf conftest*
879     CPP=/lib/cpp
880     fi
881     rm -f conftest*
882     fi
883     rm -f conftest*
884     fi
885     rm -f conftest*
886     ac_cv_prog_CPP="$CPP"
887     fi
888     CPP="$ac_cv_prog_CPP"
889     else
890     ac_cv_prog_CPP="$CPP"
891     fi
892     echo "$ac_t""$CPP" 1>&6
893    
894 cebix 1.1 for ac_prog in $CCC c++ g++ gcc CC cxx cc++ cl
895     do
896     # Extract the first word of "$ac_prog", so it can be a program name with args.
897     set dummy $ac_prog; ac_word=$2
898     echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
899 cebix 1.13 echo "configure:900: checking for $ac_word" >&5
900 cebix 1.1 if eval "test \"`echo '$''{'ac_cv_prog_CXX'+set}'`\" = set"; then
901     echo $ac_n "(cached) $ac_c" 1>&6
902     else
903     if test -n "$CXX"; then
904     ac_cv_prog_CXX="$CXX" # Let the user override the test.
905     else
906     IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
907     ac_dummy="$PATH"
908     for ac_dir in $ac_dummy; do
909     test -z "$ac_dir" && ac_dir=.
910     if test -f $ac_dir/$ac_word; then
911     ac_cv_prog_CXX="$ac_prog"
912     break
913     fi
914     done
915     IFS="$ac_save_ifs"
916     fi
917     fi
918     CXX="$ac_cv_prog_CXX"
919     if test -n "$CXX"; then
920     echo "$ac_t""$CXX" 1>&6
921     else
922     echo "$ac_t""no" 1>&6
923     fi
924    
925     test -n "$CXX" && break
926     done
927     test -n "$CXX" || CXX="gcc"
928    
929    
930     echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works""... $ac_c" 1>&6
931 cebix 1.13 echo "configure:932: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
932 cebix 1.1
933     ac_ext=C
934     # CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
935     ac_cpp='$CXXCPP $CPPFLAGS'
936     ac_compile='${CXX-g++} -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
937     ac_link='${CXX-g++} -o conftest${ac_exeext} $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
938     cross_compiling=$ac_cv_prog_cxx_cross
939    
940     cat > conftest.$ac_ext << EOF
941    
942 cebix 1.13 #line 943 "configure"
943 cebix 1.1 #include "confdefs.h"
944    
945     int main(){return(0);}
946     EOF
947 cebix 1.13 if { (eval echo configure:948: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
948 cebix 1.1 ac_cv_prog_cxx_works=yes
949     # If we can't run a trivial program, we are probably using a cross compiler.
950     if (./conftest; exit) 2>/dev/null; then
951     ac_cv_prog_cxx_cross=no
952     else
953     ac_cv_prog_cxx_cross=yes
954     fi
955     else
956     echo "configure: failed program was:" >&5
957     cat conftest.$ac_ext >&5
958     ac_cv_prog_cxx_works=no
959     fi
960     rm -fr conftest*
961     ac_ext=c
962     # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
963     ac_cpp='$CPP $CPPFLAGS'
964     ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
965     ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
966     cross_compiling=$ac_cv_prog_cc_cross
967    
968     echo "$ac_t""$ac_cv_prog_cxx_works" 1>&6
969     if test $ac_cv_prog_cxx_works = no; then
970     { echo "configure: error: installation or configuration problem: C++ compiler cannot create executables." 1>&2; exit 1; }
971     fi
972     echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
973 cebix 1.13 echo "configure:974: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
974 cebix 1.1 echo "$ac_t""$ac_cv_prog_cxx_cross" 1>&6
975     cross_compiling=$ac_cv_prog_cxx_cross
976    
977     echo $ac_n "checking whether we are using GNU C++""... $ac_c" 1>&6
978 cebix 1.13 echo "configure:979: checking whether we are using GNU C++" >&5
979 cebix 1.1 if eval "test \"`echo '$''{'ac_cv_prog_gxx'+set}'`\" = set"; then
980     echo $ac_n "(cached) $ac_c" 1>&6
981     else
982     cat > conftest.C <<EOF
983     #ifdef __GNUC__
984     yes;
985     #endif
986     EOF
987 cebix 1.13 if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:988: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
988 cebix 1.1 ac_cv_prog_gxx=yes
989     else
990     ac_cv_prog_gxx=no
991     fi
992     fi
993    
994     echo "$ac_t""$ac_cv_prog_gxx" 1>&6
995    
996     if test $ac_cv_prog_gxx = yes; then
997     GXX=yes
998     else
999     GXX=
1000     fi
1001    
1002     ac_test_CXXFLAGS="${CXXFLAGS+set}"
1003     ac_save_CXXFLAGS="$CXXFLAGS"
1004     CXXFLAGS=
1005     echo $ac_n "checking whether ${CXX-g++} accepts -g""... $ac_c" 1>&6
1006 cebix 1.13 echo "configure:1007: checking whether ${CXX-g++} accepts -g" >&5
1007 cebix 1.1 if eval "test \"`echo '$''{'ac_cv_prog_cxx_g'+set}'`\" = set"; then
1008     echo $ac_n "(cached) $ac_c" 1>&6
1009     else
1010     echo 'void f(){}' > conftest.cc
1011     if test -z "`${CXX-g++} -g -c conftest.cc 2>&1`"; then
1012     ac_cv_prog_cxx_g=yes
1013     else
1014     ac_cv_prog_cxx_g=no
1015     fi
1016     rm -f conftest*
1017    
1018     fi
1019    
1020     echo "$ac_t""$ac_cv_prog_cxx_g" 1>&6
1021     if test "$ac_test_CXXFLAGS" = set; then
1022     CXXFLAGS="$ac_save_CXXFLAGS"
1023     elif test $ac_cv_prog_cxx_g = yes; then
1024     if test "$GXX" = yes; then
1025     CXXFLAGS="-g -O2"
1026     else
1027     CXXFLAGS="-g"
1028     fi
1029     else
1030     if test "$GXX" = yes; then
1031     CXXFLAGS="-O2"
1032     else
1033     CXXFLAGS=
1034     fi
1035     fi
1036    
1037     echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
1038 cebix 1.13 echo "configure:1039: checking whether ${MAKE-make} sets \${MAKE}" >&5
1039 cebix 1.1 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
1040     if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
1041     echo $ac_n "(cached) $ac_c" 1>&6
1042     else
1043     cat > conftestmake <<\EOF
1044     all:
1045     @echo 'ac_maketemp="${MAKE}"'
1046     EOF
1047     # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1048     eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
1049     if test -n "$ac_maketemp"; then
1050     eval ac_cv_prog_make_${ac_make}_set=yes
1051     else
1052     eval ac_cv_prog_make_${ac_make}_set=no
1053     fi
1054     rm -f conftestmake
1055     fi
1056     if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1057     echo "$ac_t""yes" 1>&6
1058     SET_MAKE=
1059     else
1060     echo "$ac_t""no" 1>&6
1061     SET_MAKE="MAKE=${MAKE-make}"
1062     fi
1063    
1064     ac_aux_dir=
1065     for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
1066     if test -f $ac_dir/install-sh; then
1067     ac_aux_dir=$ac_dir
1068     ac_install_sh="$ac_aux_dir/install-sh -c"
1069     break
1070     elif test -f $ac_dir/install.sh; then
1071     ac_aux_dir=$ac_dir
1072     ac_install_sh="$ac_aux_dir/install.sh -c"
1073     break
1074     fi
1075     done
1076     if test -z "$ac_aux_dir"; then
1077     { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
1078     fi
1079     ac_config_guess=$ac_aux_dir/config.guess
1080     ac_config_sub=$ac_aux_dir/config.sub
1081     ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
1082    
1083     # Find a good install program. We prefer a C program (faster),
1084     # so one script is as good as another. But avoid the broken or
1085     # incompatible versions:
1086     # SysV /etc/install, /usr/sbin/install
1087     # SunOS /usr/etc/install
1088     # IRIX /sbin/install
1089     # AIX /bin/install
1090     # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
1091     # AFS /usr/afsws/bin/install, which mishandles nonexistent args
1092     # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
1093     # ./install, which can be erroneously created by make from ./install.sh.
1094     echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
1095 cebix 1.13 echo "configure:1096: checking for a BSD compatible install" >&5
1096 cebix 1.1 if test -z "$INSTALL"; then
1097     if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
1098     echo $ac_n "(cached) $ac_c" 1>&6
1099     else
1100     IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":"
1101     for ac_dir in $PATH; do
1102     # Account for people who put trailing slashes in PATH elements.
1103     case "$ac_dir/" in
1104     /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
1105     *)
1106     # OSF1 and SCO ODT 3.0 have their own names for install.
1107     # Don't use installbsd from OSF since it installs stuff as root
1108     # by default.
1109     for ac_prog in ginstall scoinst install; do
1110     if test -f $ac_dir/$ac_prog; then
1111     if test $ac_prog = install &&
1112     grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
1113     # AIX install. It has an incompatible calling convention.
1114     :
1115     else
1116     ac_cv_path_install="$ac_dir/$ac_prog -c"
1117     break 2
1118     fi
1119     fi
1120     done
1121     ;;
1122     esac
1123     done
1124     IFS="$ac_save_IFS"
1125    
1126     fi
1127     if test "${ac_cv_path_install+set}" = set; then
1128     INSTALL="$ac_cv_path_install"
1129     else
1130     # As a last resort, use the slow shell script. We don't cache a
1131     # path for INSTALL within a source directory, because that will
1132     # break other packages using the cache if that directory is
1133     # removed, or if the path is relative.
1134     INSTALL="$ac_install_sh"
1135     fi
1136     fi
1137     echo "$ac_t""$INSTALL" 1>&6
1138    
1139     # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
1140     # It thinks the first close brace ends the variable substitution.
1141     test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
1142    
1143     test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
1144    
1145     test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
1146    
1147    
1148 cebix 1.10 MONSRCS=
1149     echo $ac_n "checking for mon""... $ac_c" 1>&6
1150 cebix 1.13 echo "configure:1151: checking for mon" >&5
1151 cebix 1.10 if grep mon_init ../../../mon/src/mon.h >/dev/null 2>/dev/null; then
1152     echo "$ac_t""yes" 1>&6
1153 cebix 1.11 WANT_MON=yes
1154 cebix 1.10 DEFINES="$DEFINES -DENABLE_MON=1"
1155     MONSRCS="../../../mon/src/mon.cpp ../../../mon/src/mon_6502.cpp ../../../mon/src/mon_68k.cpp ../../../mon/src/mon_8080.cpp ../../../mon/src/mon_cmd.cpp ../../../mon/src/mon_ppc.cpp ../../../mon/src/mon_x86.cpp"
1156     CXXFLAGS="$CXXFLAGS -I../../../mon/src"
1157 cebix 1.13 echo $ac_n "checking for readline in -lreadline""... $ac_c" 1>&6
1158     echo "configure:1159: checking for readline in -lreadline" >&5
1159     ac_lib_var=`echo readline'_'readline | sed 'y%./+-%__p_%'`
1160     if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1161     echo $ac_n "(cached) $ac_c" 1>&6
1162     else
1163     ac_save_LIBS="$LIBS"
1164     LIBS="-lreadline $LIBS"
1165     cat > conftest.$ac_ext <<EOF
1166     #line 1167 "configure"
1167     #include "confdefs.h"
1168     /* Override any gcc2 internal prototype to avoid an error. */
1169     /* We use char because int might match the return type of a gcc2
1170     builtin and then its argument prototype would still apply. */
1171     char readline();
1172    
1173     int main() {
1174     readline()
1175     ; return 0; }
1176     EOF
1177     if { (eval echo configure:1178: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1178     rm -rf conftest*
1179     eval "ac_cv_lib_$ac_lib_var=yes"
1180     else
1181     echo "configure: failed program was:" >&5
1182     cat conftest.$ac_ext >&5
1183     rm -rf conftest*
1184     eval "ac_cv_lib_$ac_lib_var=no"
1185     fi
1186     rm -f conftest*
1187     LIBS="$ac_save_LIBS"
1188    
1189     fi
1190     if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1191     echo "$ac_t""yes" 1>&6
1192     ac_tr_lib=HAVE_LIB`echo readline | sed -e 's/[^a-zA-Z0-9_]/_/g' \
1193     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
1194     cat >> confdefs.h <<EOF
1195     #define $ac_tr_lib 1
1196     EOF
1197    
1198     LIBS="-lreadline $LIBS"
1199    
1200     else
1201     echo "$ac_t""no" 1>&6
1202     fi
1203    
1204     for ac_hdr in readline/readline.h readline/history.h
1205     do
1206     ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
1207     echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
1208     echo "configure:1209: checking for $ac_hdr" >&5
1209     if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1210     echo $ac_n "(cached) $ac_c" 1>&6
1211     else
1212     cat > conftest.$ac_ext <<EOF
1213     #line 1214 "configure"
1214     #include "confdefs.h"
1215     #include <$ac_hdr>
1216     EOF
1217     ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1218     { (eval echo configure:1219: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1219     ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1220     if test -z "$ac_err"; then
1221     rm -rf conftest*
1222     eval "ac_cv_header_$ac_safe=yes"
1223     else
1224     echo "$ac_err" >&5
1225     echo "configure: failed program was:" >&5
1226     cat conftest.$ac_ext >&5
1227     rm -rf conftest*
1228     eval "ac_cv_header_$ac_safe=no"
1229     fi
1230     rm -f conftest*
1231     fi
1232     if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1233     echo "$ac_t""yes" 1>&6
1234     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
1235     cat >> confdefs.h <<EOF
1236     #define $ac_tr_hdr 1
1237     EOF
1238    
1239     else
1240     echo "$ac_t""no" 1>&6
1241     fi
1242     done
1243    
1244 cebix 1.10 else
1245     echo "$ac_t""no" 1>&6
1246 cebix 1.11 WANT_MON=no
1247 cebix 1.10 DEFINES="$DEFINES -DENABLE_MON=0"
1248     fi
1249    
1250 cebix 1.9 echo $ac_n "checking for sem_init in -lposix4""... $ac_c" 1>&6
1251 cebix 1.13 echo "configure:1252: checking for sem_init in -lposix4" >&5
1252 cebix 1.9 ac_lib_var=`echo posix4'_'sem_init | sed 'y%./+-%__p_%'`
1253     if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1254     echo $ac_n "(cached) $ac_c" 1>&6
1255     else
1256     ac_save_LIBS="$LIBS"
1257     LIBS="-lposix4 $LIBS"
1258     cat > conftest.$ac_ext <<EOF
1259 cebix 1.13 #line 1260 "configure"
1260 cebix 1.9 #include "confdefs.h"
1261     /* Override any gcc2 internal prototype to avoid an error. */
1262     /* We use char because int might match the return type of a gcc2
1263     builtin and then its argument prototype would still apply. */
1264     char sem_init();
1265    
1266     int main() {
1267     sem_init()
1268     ; return 0; }
1269     EOF
1270 cebix 1.13 if { (eval echo configure:1271: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1271 cebix 1.9 rm -rf conftest*
1272     eval "ac_cv_lib_$ac_lib_var=yes"
1273     else
1274     echo "configure: failed program was:" >&5
1275     cat conftest.$ac_ext >&5
1276     rm -rf conftest*
1277     eval "ac_cv_lib_$ac_lib_var=no"
1278     fi
1279     rm -f conftest*
1280     LIBS="$ac_save_LIBS"
1281    
1282     fi
1283     if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1284     echo "$ac_t""yes" 1>&6
1285     ac_tr_lib=HAVE_LIB`echo posix4 | sed -e 's/[^a-zA-Z0-9_]/_/g' \
1286     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
1287     cat >> confdefs.h <<EOF
1288     #define $ac_tr_lib 1
1289     EOF
1290    
1291     LIBS="-lposix4 $LIBS"
1292    
1293     else
1294     echo "$ac_t""no" 1>&6
1295     fi
1296    
1297    
1298 cebix 1.1 # If we find X, set shell vars x_includes and x_libraries to the
1299     # paths, otherwise set no_x=yes.
1300     # Uses ac_ vars as temps to allow command line to override cache and checks.
1301     # --without-x overrides everything else, but does not touch the cache.
1302     echo $ac_n "checking for X""... $ac_c" 1>&6
1303 cebix 1.13 echo "configure:1304: checking for X" >&5
1304 cebix 1.1
1305     # Check whether --with-x or --without-x was given.
1306     if test "${with_x+set}" = set; then
1307     withval="$with_x"
1308     :
1309     fi
1310    
1311     # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
1312     if test "x$with_x" = xno; then
1313     # The user explicitly disabled X.
1314     have_x=disabled
1315     else
1316     if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
1317     # Both variables are already set.
1318     have_x=yes
1319     else
1320     if eval "test \"`echo '$''{'ac_cv_have_x'+set}'`\" = set"; then
1321     echo $ac_n "(cached) $ac_c" 1>&6
1322     else
1323     # One or both of the vars are not set, and there is no cached value.
1324     ac_x_includes=NO ac_x_libraries=NO
1325     rm -fr conftestdir
1326     if mkdir conftestdir; then
1327     cd conftestdir
1328     # Make sure to not put "make" in the Imakefile rules, since we grep it out.
1329     cat > Imakefile <<'EOF'
1330     acfindx:
1331     @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
1332     EOF
1333     if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
1334     # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1335     eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
1336     # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
1337     for ac_extension in a so sl; do
1338     if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
1339     test -f $ac_im_libdir/libX11.$ac_extension; then
1340     ac_im_usrlibdir=$ac_im_libdir; break
1341     fi
1342     done
1343     # Screen out bogus values from the imake configuration. They are
1344     # bogus both because they are the default anyway, and because
1345     # using them would break gcc on systems where it needs fixed includes.
1346     case "$ac_im_incroot" in
1347     /usr/include) ;;
1348     *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes="$ac_im_incroot" ;;
1349     esac
1350     case "$ac_im_usrlibdir" in
1351     /usr/lib | /lib) ;;
1352     *) test -d "$ac_im_usrlibdir" && ac_x_libraries="$ac_im_usrlibdir" ;;
1353     esac
1354     fi
1355     cd ..
1356     rm -fr conftestdir
1357     fi
1358    
1359     if test "$ac_x_includes" = NO; then
1360     # Guess where to find include files, by looking for this one X11 .h file.
1361     test -z "$x_direct_test_include" && x_direct_test_include=X11/Intrinsic.h
1362    
1363     # First, try using that file with no special directory specified.
1364     cat > conftest.$ac_ext <<EOF
1365 cebix 1.13 #line 1366 "configure"
1366 cebix 1.1 #include "confdefs.h"
1367     #include <$x_direct_test_include>
1368     EOF
1369     ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1370 cebix 1.13 { (eval echo configure:1371: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1371 cebix 1.1 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1372     if test -z "$ac_err"; then
1373     rm -rf conftest*
1374     # We can compile using X headers with no special include directory.
1375     ac_x_includes=
1376     else
1377     echo "$ac_err" >&5
1378     echo "configure: failed program was:" >&5
1379     cat conftest.$ac_ext >&5
1380     rm -rf conftest*
1381     # Look for the header file in a standard set of common directories.
1382     # Check X11 before X11Rn because it is often a symlink to the current release.
1383     for ac_dir in \
1384     /usr/X11/include \
1385     /usr/X11R6/include \
1386     /usr/X11R5/include \
1387     /usr/X11R4/include \
1388     \
1389     /usr/include/X11 \
1390     /usr/include/X11R6 \
1391     /usr/include/X11R5 \
1392     /usr/include/X11R4 \
1393     \
1394     /usr/local/X11/include \
1395     /usr/local/X11R6/include \
1396     /usr/local/X11R5/include \
1397     /usr/local/X11R4/include \
1398     \
1399     /usr/local/include/X11 \
1400     /usr/local/include/X11R6 \
1401     /usr/local/include/X11R5 \
1402     /usr/local/include/X11R4 \
1403     \
1404     /usr/X386/include \
1405     /usr/x386/include \
1406     /usr/XFree86/include/X11 \
1407     \
1408     /usr/include \
1409     /usr/local/include \
1410     /usr/unsupported/include \
1411     /usr/athena/include \
1412     /usr/local/x11r5/include \
1413     /usr/lpp/Xamples/include \
1414     \
1415     /usr/openwin/include \
1416     /usr/openwin/share/include \
1417     ; \
1418     do
1419     if test -r "$ac_dir/$x_direct_test_include"; then
1420     ac_x_includes=$ac_dir
1421     break
1422     fi
1423     done
1424     fi
1425     rm -f conftest*
1426     fi # $ac_x_includes = NO
1427    
1428     if test "$ac_x_libraries" = NO; then
1429     # Check for the libraries.
1430    
1431     test -z "$x_direct_test_library" && x_direct_test_library=Xt
1432     test -z "$x_direct_test_function" && x_direct_test_function=XtMalloc
1433    
1434     # See if we find them without any special options.
1435     # Don't add to $LIBS permanently.
1436     ac_save_LIBS="$LIBS"
1437     LIBS="-l$x_direct_test_library $LIBS"
1438     cat > conftest.$ac_ext <<EOF
1439 cebix 1.13 #line 1440 "configure"
1440 cebix 1.1 #include "confdefs.h"
1441    
1442     int main() {
1443     ${x_direct_test_function}()
1444     ; return 0; }
1445     EOF
1446 cebix 1.13 if { (eval echo configure:1447: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1447 cebix 1.1 rm -rf conftest*
1448     LIBS="$ac_save_LIBS"
1449     # We can link X programs with no special library path.
1450     ac_x_libraries=
1451     else
1452     echo "configure: failed program was:" >&5
1453     cat conftest.$ac_ext >&5
1454     rm -rf conftest*
1455     LIBS="$ac_save_LIBS"
1456     # First see if replacing the include by lib works.
1457     # Check X11 before X11Rn because it is often a symlink to the current release.
1458     for ac_dir in `echo "$ac_x_includes" | sed s/include/lib/` \
1459     /usr/X11/lib \
1460     /usr/X11R6/lib \
1461     /usr/X11R5/lib \
1462     /usr/X11R4/lib \
1463     \
1464     /usr/lib/X11 \
1465     /usr/lib/X11R6 \
1466     /usr/lib/X11R5 \
1467     /usr/lib/X11R4 \
1468     \
1469     /usr/local/X11/lib \
1470     /usr/local/X11R6/lib \
1471     /usr/local/X11R5/lib \
1472     /usr/local/X11R4/lib \
1473     \
1474     /usr/local/lib/X11 \
1475     /usr/local/lib/X11R6 \
1476     /usr/local/lib/X11R5 \
1477     /usr/local/lib/X11R4 \
1478     \
1479     /usr/X386/lib \
1480     /usr/x386/lib \
1481     /usr/XFree86/lib/X11 \
1482     \
1483     /usr/lib \
1484     /usr/local/lib \
1485     /usr/unsupported/lib \
1486     /usr/athena/lib \
1487     /usr/local/x11r5/lib \
1488     /usr/lpp/Xamples/lib \
1489     /lib/usr/lib/X11 \
1490     \
1491     /usr/openwin/lib \
1492     /usr/openwin/share/lib \
1493     ; \
1494     do
1495     for ac_extension in a so sl; do
1496     if test -r $ac_dir/lib${x_direct_test_library}.$ac_extension; then
1497     ac_x_libraries=$ac_dir
1498     break 2
1499     fi
1500     done
1501     done
1502     fi
1503     rm -f conftest*
1504     fi # $ac_x_libraries = NO
1505    
1506     if test "$ac_x_includes" = NO || test "$ac_x_libraries" = NO; then
1507     # Didn't find X anywhere. Cache the known absence of X.
1508     ac_cv_have_x="have_x=no"
1509     else
1510     # Record where we found X for the cache.
1511     ac_cv_have_x="have_x=yes \
1512     ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
1513     fi
1514     fi
1515     fi
1516     eval "$ac_cv_have_x"
1517     fi # $with_x != no
1518    
1519     if test "$have_x" != yes; then
1520     echo "$ac_t""$have_x" 1>&6
1521     no_x=yes
1522     else
1523     # If each of the values was on the command line, it overrides each guess.
1524     test "x$x_includes" = xNONE && x_includes=$ac_x_includes
1525     test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
1526     # Update the cache value to reflect the command line values.
1527     ac_cv_have_x="have_x=yes \
1528     ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
1529     echo "$ac_t""libraries $x_libraries, headers $x_includes" 1>&6
1530     fi
1531    
1532     if test "$no_x" = yes; then
1533     # Not all programs may use this symbol, but it does not hurt to define it.
1534     cat >> confdefs.h <<\EOF
1535     #define X_DISPLAY_MISSING 1
1536     EOF
1537    
1538     X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS=
1539     else
1540     if test -n "$x_includes"; then
1541     X_CFLAGS="$X_CFLAGS -I$x_includes"
1542     fi
1543    
1544     # It would also be nice to do this for all -L options, not just this one.
1545     if test -n "$x_libraries"; then
1546     X_LIBS="$X_LIBS -L$x_libraries"
1547     # For Solaris; some versions of Sun CC require a space after -R and
1548     # others require no space. Words are not sufficient . . . .
1549     case "`(uname -sr) 2>/dev/null`" in
1550     "SunOS 5"*)
1551     echo $ac_n "checking whether -R must be followed by a space""... $ac_c" 1>&6
1552 cebix 1.13 echo "configure:1553: checking whether -R must be followed by a space" >&5
1553 cebix 1.1 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS -R$x_libraries"
1554     cat > conftest.$ac_ext <<EOF
1555 cebix 1.13 #line 1556 "configure"
1556 cebix 1.1 #include "confdefs.h"
1557    
1558     int main() {
1559    
1560     ; return 0; }
1561     EOF
1562 cebix 1.13 if { (eval echo configure:1563: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1563 cebix 1.1 rm -rf conftest*
1564     ac_R_nospace=yes
1565     else
1566     echo "configure: failed program was:" >&5
1567     cat conftest.$ac_ext >&5
1568     rm -rf conftest*
1569     ac_R_nospace=no
1570     fi
1571     rm -f conftest*
1572     if test $ac_R_nospace = yes; then
1573     echo "$ac_t""no" 1>&6
1574     X_LIBS="$X_LIBS -R$x_libraries"
1575     else
1576     LIBS="$ac_xsave_LIBS -R $x_libraries"
1577     cat > conftest.$ac_ext <<EOF
1578 cebix 1.13 #line 1579 "configure"
1579 cebix 1.1 #include "confdefs.h"
1580    
1581     int main() {
1582    
1583     ; return 0; }
1584     EOF
1585 cebix 1.13 if { (eval echo configure:1586: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1586 cebix 1.1 rm -rf conftest*
1587     ac_R_space=yes
1588     else
1589     echo "configure: failed program was:" >&5
1590     cat conftest.$ac_ext >&5
1591     rm -rf conftest*
1592     ac_R_space=no
1593     fi
1594     rm -f conftest*
1595     if test $ac_R_space = yes; then
1596     echo "$ac_t""yes" 1>&6
1597     X_LIBS="$X_LIBS -R $x_libraries"
1598     else
1599     echo "$ac_t""neither works" 1>&6
1600     fi
1601     fi
1602     LIBS="$ac_xsave_LIBS"
1603     esac
1604     fi
1605    
1606     # Check for system-dependent libraries X programs must link with.
1607     # Do this before checking for the system-independent R6 libraries
1608     # (-lICE), since we may need -lsocket or whatever for X linking.
1609    
1610     if test "$ISC" = yes; then
1611     X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
1612     else
1613     # Martyn.Johnson@cl.cam.ac.uk says this is needed for Ultrix, if the X
1614     # libraries were built with DECnet support. And karl@cs.umb.edu says
1615     # the Alpha needs dnet_stub (dnet does not exist).
1616     echo $ac_n "checking for dnet_ntoa in -ldnet""... $ac_c" 1>&6
1617 cebix 1.13 echo "configure:1618: checking for dnet_ntoa in -ldnet" >&5
1618 cebix 1.1 ac_lib_var=`echo dnet'_'dnet_ntoa | sed 'y%./+-%__p_%'`
1619     if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1620     echo $ac_n "(cached) $ac_c" 1>&6
1621     else
1622     ac_save_LIBS="$LIBS"
1623     LIBS="-ldnet $LIBS"
1624     cat > conftest.$ac_ext <<EOF
1625 cebix 1.13 #line 1626 "configure"
1626 cebix 1.1 #include "confdefs.h"
1627     /* Override any gcc2 internal prototype to avoid an error. */
1628     /* We use char because int might match the return type of a gcc2
1629     builtin and then its argument prototype would still apply. */
1630     char dnet_ntoa();
1631    
1632     int main() {
1633     dnet_ntoa()
1634     ; return 0; }
1635     EOF
1636 cebix 1.13 if { (eval echo configure:1637: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1637 cebix 1.1 rm -rf conftest*
1638     eval "ac_cv_lib_$ac_lib_var=yes"
1639     else
1640     echo "configure: failed program was:" >&5
1641     cat conftest.$ac_ext >&5
1642     rm -rf conftest*
1643     eval "ac_cv_lib_$ac_lib_var=no"
1644     fi
1645     rm -f conftest*
1646     LIBS="$ac_save_LIBS"
1647    
1648     fi
1649     if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1650     echo "$ac_t""yes" 1>&6
1651     X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
1652     else
1653     echo "$ac_t""no" 1>&6
1654     fi
1655    
1656     if test $ac_cv_lib_dnet_dnet_ntoa = no; then
1657     echo $ac_n "checking for dnet_ntoa in -ldnet_stub""... $ac_c" 1>&6
1658 cebix 1.13 echo "configure:1659: checking for dnet_ntoa in -ldnet_stub" >&5
1659 cebix 1.1 ac_lib_var=`echo dnet_stub'_'dnet_ntoa | sed 'y%./+-%__p_%'`
1660     if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1661     echo $ac_n "(cached) $ac_c" 1>&6
1662     else
1663     ac_save_LIBS="$LIBS"
1664     LIBS="-ldnet_stub $LIBS"
1665     cat > conftest.$ac_ext <<EOF
1666 cebix 1.13 #line 1667 "configure"
1667 cebix 1.1 #include "confdefs.h"
1668     /* Override any gcc2 internal prototype to avoid an error. */
1669     /* We use char because int might match the return type of a gcc2
1670     builtin and then its argument prototype would still apply. */
1671     char dnet_ntoa();
1672    
1673     int main() {
1674     dnet_ntoa()
1675     ; return 0; }
1676     EOF
1677 cebix 1.13 if { (eval echo configure:1678: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1678 cebix 1.1 rm -rf conftest*
1679     eval "ac_cv_lib_$ac_lib_var=yes"
1680     else
1681     echo "configure: failed program was:" >&5
1682     cat conftest.$ac_ext >&5
1683     rm -rf conftest*
1684     eval "ac_cv_lib_$ac_lib_var=no"
1685     fi
1686     rm -f conftest*
1687     LIBS="$ac_save_LIBS"
1688    
1689     fi
1690     if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1691     echo "$ac_t""yes" 1>&6
1692     X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
1693     else
1694     echo "$ac_t""no" 1>&6
1695     fi
1696    
1697     fi
1698    
1699     # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
1700     # to get the SysV transport functions.
1701     # chad@anasazi.com says the Pyramis MIS-ES running DC/OSx (SVR4)
1702     # needs -lnsl.
1703     # The nsl library prevents programs from opening the X display
1704     # on Irix 5.2, according to dickey@clark.net.
1705     echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6
1706 cebix 1.13 echo "configure:1707: checking for gethostbyname" >&5
1707 cebix 1.1 if eval "test \"`echo '$''{'ac_cv_func_gethostbyname'+set}'`\" = set"; then
1708     echo $ac_n "(cached) $ac_c" 1>&6
1709     else
1710     cat > conftest.$ac_ext <<EOF
1711 cebix 1.13 #line 1712 "configure"
1712 cebix 1.1 #include "confdefs.h"
1713     /* System header to define __stub macros and hopefully few prototypes,
1714     which can conflict with char gethostbyname(); below. */
1715     #include <assert.h>
1716     /* Override any gcc2 internal prototype to avoid an error. */
1717     /* We use char because int might match the return type of a gcc2
1718     builtin and then its argument prototype would still apply. */
1719     char gethostbyname();
1720    
1721     int main() {
1722    
1723     /* The GNU C library defines this for functions which it implements
1724     to always fail with ENOSYS. Some functions are actually named
1725     something starting with __ and the normal name is an alias. */
1726     #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
1727     choke me
1728     #else
1729     gethostbyname();
1730     #endif
1731    
1732     ; return 0; }
1733     EOF
1734 cebix 1.13 if { (eval echo configure:1735: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1735 cebix 1.1 rm -rf conftest*
1736     eval "ac_cv_func_gethostbyname=yes"
1737     else
1738     echo "configure: failed program was:" >&5
1739     cat conftest.$ac_ext >&5
1740     rm -rf conftest*
1741     eval "ac_cv_func_gethostbyname=no"
1742     fi
1743     rm -f conftest*
1744     fi
1745    
1746     if eval "test \"`echo '$ac_cv_func_'gethostbyname`\" = yes"; then
1747     echo "$ac_t""yes" 1>&6
1748     :
1749     else
1750     echo "$ac_t""no" 1>&6
1751     fi
1752    
1753     if test $ac_cv_func_gethostbyname = no; then
1754     echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6
1755 cebix 1.13 echo "configure:1756: checking for gethostbyname in -lnsl" >&5
1756 cebix 1.1 ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'`
1757     if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1758     echo $ac_n "(cached) $ac_c" 1>&6
1759     else
1760     ac_save_LIBS="$LIBS"
1761     LIBS="-lnsl $LIBS"
1762     cat > conftest.$ac_ext <<EOF
1763 cebix 1.13 #line 1764 "configure"
1764 cebix 1.1 #include "confdefs.h"
1765     /* Override any gcc2 internal prototype to avoid an error. */
1766     /* We use char because int might match the return type of a gcc2
1767     builtin and then its argument prototype would still apply. */
1768     char gethostbyname();
1769    
1770     int main() {
1771     gethostbyname()
1772     ; return 0; }
1773     EOF
1774 cebix 1.13 if { (eval echo configure:1775: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1775 cebix 1.1 rm -rf conftest*
1776     eval "ac_cv_lib_$ac_lib_var=yes"
1777     else
1778     echo "configure: failed program was:" >&5
1779     cat conftest.$ac_ext >&5
1780     rm -rf conftest*
1781     eval "ac_cv_lib_$ac_lib_var=no"
1782     fi
1783     rm -f conftest*
1784     LIBS="$ac_save_LIBS"
1785    
1786     fi
1787     if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1788     echo "$ac_t""yes" 1>&6
1789     X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
1790     else
1791     echo "$ac_t""no" 1>&6
1792     fi
1793    
1794     fi
1795    
1796     # lieder@skyler.mavd.honeywell.com says without -lsocket,
1797     # socket/setsockopt and other routines are undefined under SCO ODT
1798     # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary
1799     # on later versions), says simon@lia.di.epfl.ch: it contains
1800     # gethostby* variants that don't use the nameserver (or something).
1801     # -lsocket must be given before -lnsl if both are needed.
1802     # We assume that if connect needs -lnsl, so does gethostbyname.
1803     echo $ac_n "checking for connect""... $ac_c" 1>&6
1804 cebix 1.13 echo "configure:1805: checking for connect" >&5
1805 cebix 1.1 if eval "test \"`echo '$''{'ac_cv_func_connect'+set}'`\" = set"; then
1806     echo $ac_n "(cached) $ac_c" 1>&6
1807     else
1808     cat > conftest.$ac_ext <<EOF
1809 cebix 1.13 #line 1810 "configure"
1810 cebix 1.1 #include "confdefs.h"
1811     /* System header to define __stub macros and hopefully few prototypes,
1812     which can conflict with char connect(); below. */
1813     #include <assert.h>
1814     /* Override any gcc2 internal prototype to avoid an error. */
1815     /* We use char because int might match the return type of a gcc2
1816     builtin and then its argument prototype would still apply. */
1817     char connect();
1818    
1819     int main() {
1820    
1821     /* The GNU C library defines this for functions which it implements
1822     to always fail with ENOSYS. Some functions are actually named
1823     something starting with __ and the normal name is an alias. */
1824     #if defined (__stub_connect) || defined (__stub___connect)
1825     choke me
1826     #else
1827     connect();
1828     #endif
1829    
1830     ; return 0; }
1831     EOF
1832 cebix 1.13 if { (eval echo configure:1833: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1833 cebix 1.1 rm -rf conftest*
1834     eval "ac_cv_func_connect=yes"
1835     else
1836     echo "configure: failed program was:" >&5
1837     cat conftest.$ac_ext >&5
1838     rm -rf conftest*
1839     eval "ac_cv_func_connect=no"
1840     fi
1841     rm -f conftest*
1842     fi
1843    
1844     if eval "test \"`echo '$ac_cv_func_'connect`\" = yes"; then
1845     echo "$ac_t""yes" 1>&6
1846     :
1847     else
1848     echo "$ac_t""no" 1>&6
1849     fi
1850    
1851     if test $ac_cv_func_connect = no; then
1852     echo $ac_n "checking for connect in -lsocket""... $ac_c" 1>&6
1853 cebix 1.13 echo "configure:1854: checking for connect in -lsocket" >&5
1854 cebix 1.1 ac_lib_var=`echo socket'_'connect | sed 'y%./+-%__p_%'`
1855     if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1856     echo $ac_n "(cached) $ac_c" 1>&6
1857     else
1858     ac_save_LIBS="$LIBS"
1859     LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
1860     cat > conftest.$ac_ext <<EOF
1861 cebix 1.13 #line 1862 "configure"
1862 cebix 1.1 #include "confdefs.h"
1863     /* Override any gcc2 internal prototype to avoid an error. */
1864     /* We use char because int might match the return type of a gcc2
1865     builtin and then its argument prototype would still apply. */
1866     char connect();
1867    
1868     int main() {
1869     connect()
1870     ; return 0; }
1871     EOF
1872 cebix 1.13 if { (eval echo configure:1873: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1873 cebix 1.1 rm -rf conftest*
1874     eval "ac_cv_lib_$ac_lib_var=yes"
1875     else
1876     echo "configure: failed program was:" >&5
1877     cat conftest.$ac_ext >&5
1878     rm -rf conftest*
1879     eval "ac_cv_lib_$ac_lib_var=no"
1880     fi
1881     rm -f conftest*
1882     LIBS="$ac_save_LIBS"
1883    
1884     fi
1885     if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1886     echo "$ac_t""yes" 1>&6
1887     X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
1888     else
1889     echo "$ac_t""no" 1>&6
1890     fi
1891    
1892     fi
1893    
1894     # gomez@mi.uni-erlangen.de says -lposix is necessary on A/UX.
1895     echo $ac_n "checking for remove""... $ac_c" 1>&6
1896 cebix 1.13 echo "configure:1897: checking for remove" >&5
1897 cebix 1.1 if eval "test \"`echo '$''{'ac_cv_func_remove'+set}'`\" = set"; then
1898     echo $ac_n "(cached) $ac_c" 1>&6
1899     else
1900     cat > conftest.$ac_ext <<EOF
1901 cebix 1.13 #line 1902 "configure"
1902 cebix 1.1 #include "confdefs.h"
1903     /* System header to define __stub macros and hopefully few prototypes,
1904     which can conflict with char remove(); below. */
1905     #include <assert.h>
1906     /* Override any gcc2 internal prototype to avoid an error. */
1907     /* We use char because int might match the return type of a gcc2
1908     builtin and then its argument prototype would still apply. */
1909     char remove();
1910    
1911     int main() {
1912    
1913     /* The GNU C library defines this for functions which it implements
1914     to always fail with ENOSYS. Some functions are actually named
1915     something starting with __ and the normal name is an alias. */
1916     #if defined (__stub_remove) || defined (__stub___remove)
1917     choke me
1918     #else
1919     remove();
1920     #endif
1921    
1922     ; return 0; }
1923     EOF
1924 cebix 1.13 if { (eval echo configure:1925: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1925 cebix 1.1 rm -rf conftest*
1926     eval "ac_cv_func_remove=yes"
1927     else
1928     echo "configure: failed program was:" >&5
1929     cat conftest.$ac_ext >&5
1930     rm -rf conftest*
1931     eval "ac_cv_func_remove=no"
1932     fi
1933     rm -f conftest*
1934     fi
1935    
1936     if eval "test \"`echo '$ac_cv_func_'remove`\" = yes"; then
1937     echo "$ac_t""yes" 1>&6
1938     :
1939     else
1940     echo "$ac_t""no" 1>&6
1941     fi
1942    
1943     if test $ac_cv_func_remove = no; then
1944     echo $ac_n "checking for remove in -lposix""... $ac_c" 1>&6
1945 cebix 1.13 echo "configure:1946: checking for remove in -lposix" >&5
1946 cebix 1.1 ac_lib_var=`echo posix'_'remove | sed 'y%./+-%__p_%'`
1947     if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1948     echo $ac_n "(cached) $ac_c" 1>&6
1949     else
1950     ac_save_LIBS="$LIBS"
1951     LIBS="-lposix $LIBS"
1952     cat > conftest.$ac_ext <<EOF
1953 cebix 1.13 #line 1954 "configure"
1954 cebix 1.1 #include "confdefs.h"
1955     /* Override any gcc2 internal prototype to avoid an error. */
1956     /* We use char because int might match the return type of a gcc2
1957     builtin and then its argument prototype would still apply. */
1958     char remove();
1959    
1960     int main() {
1961     remove()
1962     ; return 0; }
1963     EOF
1964 cebix 1.13 if { (eval echo configure:1965: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1965 cebix 1.1 rm -rf conftest*
1966     eval "ac_cv_lib_$ac_lib_var=yes"
1967     else
1968     echo "configure: failed program was:" >&5
1969     cat conftest.$ac_ext >&5
1970     rm -rf conftest*
1971     eval "ac_cv_lib_$ac_lib_var=no"
1972     fi
1973     rm -f conftest*
1974     LIBS="$ac_save_LIBS"
1975    
1976     fi
1977     if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1978     echo "$ac_t""yes" 1>&6
1979     X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
1980     else
1981     echo "$ac_t""no" 1>&6
1982     fi
1983    
1984     fi
1985    
1986     # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
1987     echo $ac_n "checking for shmat""... $ac_c" 1>&6
1988 cebix 1.13 echo "configure:1989: checking for shmat" >&5
1989 cebix 1.1 if eval "test \"`echo '$''{'ac_cv_func_shmat'+set}'`\" = set"; then
1990     echo $ac_n "(cached) $ac_c" 1>&6
1991     else
1992     cat > conftest.$ac_ext <<EOF
1993 cebix 1.13 #line 1994 "configure"
1994 cebix 1.1 #include "confdefs.h"
1995     /* System header to define __stub macros and hopefully few prototypes,
1996     which can conflict with char shmat(); below. */
1997     #include <assert.h>
1998     /* Override any gcc2 internal prototype to avoid an error. */
1999     /* We use char because int might match the return type of a gcc2
2000     builtin and then its argument prototype would still apply. */
2001     char shmat();
2002    
2003     int main() {
2004    
2005     /* The GNU C library defines this for functions which it implements
2006     to always fail with ENOSYS. Some functions are actually named
2007     something starting with __ and the normal name is an alias. */
2008     #if defined (__stub_shmat) || defined (__stub___shmat)
2009     choke me
2010     #else
2011     shmat();
2012     #endif
2013    
2014     ; return 0; }
2015     EOF
2016 cebix 1.13 if { (eval echo configure:2017: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2017 cebix 1.1 rm -rf conftest*
2018     eval "ac_cv_func_shmat=yes"
2019     else
2020     echo "configure: failed program was:" >&5
2021     cat conftest.$ac_ext >&5
2022     rm -rf conftest*
2023     eval "ac_cv_func_shmat=no"
2024     fi
2025     rm -f conftest*
2026     fi
2027    
2028     if eval "test \"`echo '$ac_cv_func_'shmat`\" = yes"; then
2029     echo "$ac_t""yes" 1>&6
2030     :
2031     else
2032     echo "$ac_t""no" 1>&6
2033     fi
2034    
2035     if test $ac_cv_func_shmat = no; then
2036     echo $ac_n "checking for shmat in -lipc""... $ac_c" 1>&6
2037 cebix 1.13 echo "configure:2038: checking for shmat in -lipc" >&5
2038 cebix 1.1 ac_lib_var=`echo ipc'_'shmat | sed 'y%./+-%__p_%'`
2039     if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2040     echo $ac_n "(cached) $ac_c" 1>&6
2041     else
2042     ac_save_LIBS="$LIBS"
2043     LIBS="-lipc $LIBS"
2044     cat > conftest.$ac_ext <<EOF
2045 cebix 1.13 #line 2046 "configure"
2046 cebix 1.1 #include "confdefs.h"
2047     /* Override any gcc2 internal prototype to avoid an error. */
2048     /* We use char because int might match the return type of a gcc2
2049     builtin and then its argument prototype would still apply. */
2050     char shmat();
2051    
2052     int main() {
2053     shmat()
2054     ; return 0; }
2055     EOF
2056 cebix 1.13 if { (eval echo configure:2057: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2057 cebix 1.1 rm -rf conftest*
2058     eval "ac_cv_lib_$ac_lib_var=yes"
2059     else
2060     echo "configure: failed program was:" >&5
2061     cat conftest.$ac_ext >&5
2062     rm -rf conftest*
2063     eval "ac_cv_lib_$ac_lib_var=no"
2064     fi
2065     rm -f conftest*
2066     LIBS="$ac_save_LIBS"
2067    
2068     fi
2069     if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2070     echo "$ac_t""yes" 1>&6
2071     X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
2072     else
2073     echo "$ac_t""no" 1>&6
2074     fi
2075    
2076     fi
2077     fi
2078    
2079     # Check for libraries that X11R6 Xt/Xaw programs need.
2080     ac_save_LDFLAGS="$LDFLAGS"
2081     test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
2082     # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
2083     # check for ICE first), but we must link in the order -lSM -lICE or
2084     # we get undefined symbols. So assume we have SM if we have ICE.
2085     # These have to be linked with before -lX11, unlike the other
2086     # libraries we check for below, so use a different variable.
2087     # --interran@uluru.Stanford.EDU, kb@cs.umb.edu.
2088     echo $ac_n "checking for IceConnectionNumber in -lICE""... $ac_c" 1>&6
2089 cebix 1.13 echo "configure:2090: checking for IceConnectionNumber in -lICE" >&5
2090 cebix 1.1 ac_lib_var=`echo ICE'_'IceConnectionNumber | sed 'y%./+-%__p_%'`
2091     if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2092     echo $ac_n "(cached) $ac_c" 1>&6
2093     else
2094     ac_save_LIBS="$LIBS"
2095     LIBS="-lICE $X_EXTRA_LIBS $LIBS"
2096     cat > conftest.$ac_ext <<EOF
2097 cebix 1.13 #line 2098 "configure"
2098 cebix 1.1 #include "confdefs.h"
2099     /* Override any gcc2 internal prototype to avoid an error. */
2100     /* We use char because int might match the return type of a gcc2
2101     builtin and then its argument prototype would still apply. */
2102     char IceConnectionNumber();
2103    
2104     int main() {
2105     IceConnectionNumber()
2106     ; return 0; }
2107     EOF
2108 cebix 1.13 if { (eval echo configure:2109: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2109 cebix 1.1 rm -rf conftest*
2110     eval "ac_cv_lib_$ac_lib_var=yes"
2111     else
2112     echo "configure: failed program was:" >&5
2113     cat conftest.$ac_ext >&5
2114     rm -rf conftest*
2115     eval "ac_cv_lib_$ac_lib_var=no"
2116     fi
2117     rm -f conftest*
2118     LIBS="$ac_save_LIBS"
2119    
2120     fi
2121     if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2122     echo "$ac_t""yes" 1>&6
2123     X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
2124     else
2125     echo "$ac_t""no" 1>&6
2126     fi
2127    
2128     LDFLAGS="$ac_save_LDFLAGS"
2129    
2130     fi
2131    
2132     if [ "x$no_x" = "xyes" ]; then
2133     { echo "configure: error: You need X11 to run Basilisk II." 1>&2; exit 1; }
2134     fi
2135     CFLAGS="$CFLAGS $X_CFLAGS"
2136     CXXFLAGS="$CXXFLAGS $X_CFLAGS"
2137     LIBS="$LIBS $X_PRE_LIBS $X_LIBS -lX11 -lXext $X_EXTRA_LIBS"
2138    
2139     echo $ac_n "checking for pthread_create in -lpthread""... $ac_c" 1>&6
2140 cebix 1.13 echo "configure:2141: checking for pthread_create in -lpthread" >&5
2141 cebix 1.1 ac_lib_var=`echo pthread'_'pthread_create | sed 'y%./+-%__p_%'`
2142     if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2143     echo $ac_n "(cached) $ac_c" 1>&6
2144     else
2145     ac_save_LIBS="$LIBS"
2146     LIBS="-lpthread $LIBS"
2147     cat > conftest.$ac_ext <<EOF
2148 cebix 1.13 #line 2149 "configure"
2149 cebix 1.1 #include "confdefs.h"
2150     /* Override any gcc2 internal prototype to avoid an error. */
2151     /* We use char because int might match the return type of a gcc2
2152     builtin and then its argument prototype would still apply. */
2153     char pthread_create();
2154    
2155     int main() {
2156     pthread_create()
2157     ; return 0; }
2158     EOF
2159 cebix 1.13 if { (eval echo configure:2160: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2160 cebix 1.1 rm -rf conftest*
2161     eval "ac_cv_lib_$ac_lib_var=yes"
2162     else
2163     echo "configure: failed program was:" >&5
2164     cat conftest.$ac_ext >&5
2165     rm -rf conftest*
2166     eval "ac_cv_lib_$ac_lib_var=no"
2167     fi
2168     rm -f conftest*
2169     LIBS="$ac_save_LIBS"
2170    
2171     fi
2172     if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2173     echo "$ac_t""yes" 1>&6
2174 cebix 1.9 ac_tr_lib=HAVE_LIB`echo pthread | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2175     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2176     cat >> confdefs.h <<EOF
2177     #define $ac_tr_lib 1
2178     EOF
2179    
2180     LIBS="-lpthread $LIBS"
2181    
2182 cebix 1.1 else
2183     echo "$ac_t""no" 1>&6
2184    
2185 cebix 1.9 echo $ac_n "checking for pthread_create in -lc_r""... $ac_c" 1>&6
2186 cebix 1.13 echo "configure:2187: checking for pthread_create in -lc_r" >&5
2187 cebix 1.1 ac_lib_var=`echo c_r'_'pthread_create | sed 'y%./+-%__p_%'`
2188     if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2189     echo $ac_n "(cached) $ac_c" 1>&6
2190     else
2191     ac_save_LIBS="$LIBS"
2192     LIBS="-lc_r $LIBS"
2193     cat > conftest.$ac_ext <<EOF
2194 cebix 1.13 #line 2195 "configure"
2195 cebix 1.1 #include "confdefs.h"
2196     /* Override any gcc2 internal prototype to avoid an error. */
2197     /* We use char because int might match the return type of a gcc2
2198     builtin and then its argument prototype would still apply. */
2199     char pthread_create();
2200    
2201     int main() {
2202     pthread_create()
2203     ; return 0; }
2204     EOF
2205 cebix 1.13 if { (eval echo configure:2206: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2206 cebix 1.1 rm -rf conftest*
2207     eval "ac_cv_lib_$ac_lib_var=yes"
2208     else
2209     echo "configure: failed program was:" >&5
2210     cat conftest.$ac_ext >&5
2211     rm -rf conftest*
2212     eval "ac_cv_lib_$ac_lib_var=no"
2213     fi
2214     rm -f conftest*
2215     LIBS="$ac_save_LIBS"
2216    
2217     fi
2218     if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2219     echo "$ac_t""yes" 1>&6
2220 cebix 1.9 ac_tr_lib=HAVE_LIB`echo c_r | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2221     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2222     cat >> confdefs.h <<EOF
2223     #define $ac_tr_lib 1
2224     EOF
2225    
2226     LIBS="-lc_r $LIBS"
2227    
2228 cebix 1.1 else
2229     echo "$ac_t""no" 1>&6
2230    
2231 cebix 1.9 echo $ac_n "checking for pthread_create in -lPTL""... $ac_c" 1>&6
2232 cebix 1.13 echo "configure:2233: checking for pthread_create in -lPTL" >&5
2233 cebix 1.5 ac_lib_var=`echo PTL'_'pthread_create | sed 'y%./+-%__p_%'`
2234     if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2235     echo $ac_n "(cached) $ac_c" 1>&6
2236     else
2237     ac_save_LIBS="$LIBS"
2238     LIBS="-lPTL $LIBS"
2239     cat > conftest.$ac_ext <<EOF
2240 cebix 1.13 #line 2241 "configure"
2241 cebix 1.5 #include "confdefs.h"
2242     /* Override any gcc2 internal prototype to avoid an error. */
2243     /* We use char because int might match the return type of a gcc2
2244     builtin and then its argument prototype would still apply. */
2245     char pthread_create();
2246    
2247     int main() {
2248     pthread_create()
2249     ; return 0; }
2250     EOF
2251 cebix 1.13 if { (eval echo configure:2252: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2252 cebix 1.5 rm -rf conftest*
2253     eval "ac_cv_lib_$ac_lib_var=yes"
2254     else
2255     echo "configure: failed program was:" >&5
2256     cat conftest.$ac_ext >&5
2257     rm -rf conftest*
2258     eval "ac_cv_lib_$ac_lib_var=no"
2259     fi
2260     rm -f conftest*
2261     LIBS="$ac_save_LIBS"
2262    
2263     fi
2264     if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2265     echo "$ac_t""yes" 1>&6
2266 cebix 1.9 ac_tr_lib=HAVE_LIB`echo PTL | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2267     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2268     cat >> confdefs.h <<EOF
2269     #define $ac_tr_lib 1
2270     EOF
2271    
2272     LIBS="-lPTL $LIBS"
2273    
2274 cebix 1.5 else
2275     echo "$ac_t""no" 1>&6
2276 cebix 1.9
2277     { echo "configure: error: You need pthreads to run Basilisk II." 1>&2; exit 1; }
2278    
2279 cebix 1.5 fi
2280    
2281 cebix 1.9
2282     fi
2283    
2284    
2285 cebix 1.1 fi
2286 cebix 1.9
2287    
2288     SEMSRCS=
2289     for ac_func in sem_init
2290 cebix 1.1 do
2291     echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2292 cebix 1.13 echo "configure:2293: checking for $ac_func" >&5
2293 cebix 1.1 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2294     echo $ac_n "(cached) $ac_c" 1>&6
2295     else
2296     cat > conftest.$ac_ext <<EOF
2297 cebix 1.13 #line 2298 "configure"
2298 cebix 1.1 #include "confdefs.h"
2299     /* System header to define __stub macros and hopefully few prototypes,
2300     which can conflict with char $ac_func(); below. */
2301     #include <assert.h>
2302     /* Override any gcc2 internal prototype to avoid an error. */
2303     /* We use char because int might match the return type of a gcc2
2304     builtin and then its argument prototype would still apply. */
2305     char $ac_func();
2306    
2307     int main() {
2308    
2309     /* The GNU C library defines this for functions which it implements
2310     to always fail with ENOSYS. Some functions are actually named
2311     something starting with __ and the normal name is an alias. */
2312     #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2313     choke me
2314     #else
2315     $ac_func();
2316     #endif
2317    
2318     ; return 0; }
2319     EOF
2320 cebix 1.13 if { (eval echo configure:2321: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2321 cebix 1.1 rm -rf conftest*
2322     eval "ac_cv_func_$ac_func=yes"
2323     else
2324     echo "configure: failed program was:" >&5
2325     cat conftest.$ac_ext >&5
2326     rm -rf conftest*
2327     eval "ac_cv_func_$ac_func=no"
2328     fi
2329     rm -f conftest*
2330     fi
2331    
2332     if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2333     echo "$ac_t""yes" 1>&6
2334     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2335     cat >> confdefs.h <<EOF
2336     #define $ac_tr_func 1
2337     EOF
2338    
2339     else
2340     echo "$ac_t""no" 1>&6
2341 cebix 1.9 SEMSRCS=posix_sem.cpp
2342    
2343 cebix 1.1 fi
2344     done
2345    
2346    
2347 cebix 1.7 if [ "x$WANT_XF86_DGA" = "xyes" ]; then
2348 cebix 1.1 echo $ac_n "checking for XF86DGAQueryExtension in -lXxf86dga""... $ac_c" 1>&6
2349 cebix 1.13 echo "configure:2350: checking for XF86DGAQueryExtension in -lXxf86dga" >&5
2350 cebix 1.1 ac_lib_var=`echo Xxf86dga'_'XF86DGAQueryExtension | sed 'y%./+-%__p_%'`
2351     if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2352     echo $ac_n "(cached) $ac_c" 1>&6
2353     else
2354     ac_save_LIBS="$LIBS"
2355     LIBS="-lXxf86dga $LIBS"
2356     cat > conftest.$ac_ext <<EOF
2357 cebix 1.13 #line 2358 "configure"
2358 cebix 1.1 #include "confdefs.h"
2359     /* Override any gcc2 internal prototype to avoid an error. */
2360     /* We use char because int might match the return type of a gcc2
2361     builtin and then its argument prototype would still apply. */
2362     char XF86DGAQueryExtension();
2363    
2364     int main() {
2365     XF86DGAQueryExtension()
2366     ; return 0; }
2367     EOF
2368 cebix 1.13 if { (eval echo configure:2369: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2369 cebix 1.1 rm -rf conftest*
2370     eval "ac_cv_lib_$ac_lib_var=yes"
2371     else
2372     echo "configure: failed program was:" >&5
2373     cat conftest.$ac_ext >&5
2374     rm -rf conftest*
2375     eval "ac_cv_lib_$ac_lib_var=no"
2376     fi
2377     rm -f conftest*
2378     LIBS="$ac_save_LIBS"
2379    
2380     fi
2381     if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2382     echo "$ac_t""yes" 1>&6
2383 cebix 1.9
2384 cebix 1.7 DEFINES="$DEFINES -DENABLE_XF86_DGA=1"
2385 cebix 1.1 LIBS="$LIBS -lXxf86dga"
2386 cebix 1.7 if [ "x$WANT_FBDEV_DGA" = "xyes" ]; then
2387     echo "configure: warning: Cannot have both --enable-xf86-dga and --enable-fbdev-dga, ignoring --enable-fbdev-dga." 1>&2
2388     WANT_FBDEV_DGA=no
2389     fi
2390 cebix 1.9
2391     else
2392     echo "$ac_t""no" 1>&6
2393    
2394     echo "configure: warning: Could not find XFree86 DGA extension, ignoring --enable-xf86-dga." 1>&2
2395 cebix 1.12 WANT_XF86_DGA=no
2396 cebix 1.9 DEFINES="$DEFINES -DENABLE_XF86_DGA=0"
2397    
2398     fi
2399    
2400 cebix 1.7 else
2401     DEFINES="$DEFINES -DENABLE_XF86_DGA=0"
2402     fi
2403     if [ "x$WANT_FBDEV_DGA" = "xyes" ]; then
2404     DEFINES="$DEFINES -DENABLE_FBDEV_DGA=1"
2405     else
2406     DEFINES="$DEFINES -DENABLE_FBDEV_DGA=0"
2407 cebix 1.1 fi
2408    
2409 cebix 1.9 UISRCS=../dummy/prefs_editor_dummy.cpp
2410 cebix 1.13 if [ "x$WANT_GTK" = "xyes" ]; then
2411 cebix 1.1 # Check whether --with-gtk-prefix or --without-gtk-prefix was given.
2412     if test "${with_gtk_prefix+set}" = set; then
2413     withval="$with_gtk_prefix"
2414     gtk_config_prefix="$withval"
2415     else
2416     gtk_config_prefix=""
2417     fi
2418    
2419     # Check whether --with-gtk-exec-prefix or --without-gtk-exec-prefix was given.
2420     if test "${with_gtk_exec_prefix+set}" = set; then
2421     withval="$with_gtk_exec_prefix"
2422     gtk_config_exec_prefix="$withval"
2423     else
2424     gtk_config_exec_prefix=""
2425     fi
2426    
2427     # Check whether --enable-gtktest or --disable-gtktest was given.
2428     if test "${enable_gtktest+set}" = set; then
2429     enableval="$enable_gtktest"
2430     :
2431     else
2432     enable_gtktest=yes
2433     fi
2434    
2435    
2436     if test x$gtk_config_exec_prefix != x ; then
2437     gtk_config_args="$gtk_config_args --exec-prefix=$gtk_config_exec_prefix"
2438     if test x${GTK_CONFIG+set} != xset ; then
2439     GTK_CONFIG=$gtk_config_exec_prefix/bin/gtk-config
2440     fi
2441     fi
2442     if test x$gtk_config_prefix != x ; then
2443     gtk_config_args="$gtk_config_args --prefix=$gtk_config_prefix"
2444     if test x${GTK_CONFIG+set} != xset ; then
2445     GTK_CONFIG=$gtk_config_prefix/bin/gtk-config
2446     fi
2447     fi
2448    
2449     # Extract the first word of "gtk-config", so it can be a program name with args.
2450     set dummy gtk-config; ac_word=$2
2451     echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2452 cebix 1.13 echo "configure:2453: checking for $ac_word" >&5
2453 cebix 1.1 if eval "test \"`echo '$''{'ac_cv_path_GTK_CONFIG'+set}'`\" = set"; then
2454     echo $ac_n "(cached) $ac_c" 1>&6
2455     else
2456     case "$GTK_CONFIG" in
2457     /*)
2458     ac_cv_path_GTK_CONFIG="$GTK_CONFIG" # Let the user override the test with a path.
2459     ;;
2460     ?:/*)
2461     ac_cv_path_GTK_CONFIG="$GTK_CONFIG" # Let the user override the test with a dos path.
2462     ;;
2463     *)
2464     IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2465     ac_dummy="$PATH"
2466     for ac_dir in $ac_dummy; do
2467     test -z "$ac_dir" && ac_dir=.
2468     if test -f $ac_dir/$ac_word; then
2469     ac_cv_path_GTK_CONFIG="$ac_dir/$ac_word"
2470     break
2471     fi
2472     done
2473     IFS="$ac_save_ifs"
2474     test -z "$ac_cv_path_GTK_CONFIG" && ac_cv_path_GTK_CONFIG="no"
2475     ;;
2476     esac
2477     fi
2478     GTK_CONFIG="$ac_cv_path_GTK_CONFIG"
2479     if test -n "$GTK_CONFIG"; then
2480     echo "$ac_t""$GTK_CONFIG" 1>&6
2481     else
2482     echo "$ac_t""no" 1>&6
2483     fi
2484    
2485     min_gtk_version=1.2.0
2486     echo $ac_n "checking for GTK - version >= $min_gtk_version""... $ac_c" 1>&6
2487 cebix 1.13 echo "configure:2488: checking for GTK - version >= $min_gtk_version" >&5
2488 cebix 1.1 no_gtk=""
2489     if test "$GTK_CONFIG" = "no" ; then
2490     no_gtk=yes
2491     else
2492     GTK_CFLAGS=`$GTK_CONFIG $gtk_config_args --cflags`
2493     GTK_LIBS=`$GTK_CONFIG $gtk_config_args --libs`
2494     gtk_config_major_version=`$GTK_CONFIG $gtk_config_args --version | \
2495     sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\1/'`
2496     gtk_config_minor_version=`$GTK_CONFIG $gtk_config_args --version | \
2497     sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\2/'`
2498     gtk_config_micro_version=`$GTK_CONFIG $gtk_config_args --version | \
2499     sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\3/'`
2500     if test "x$enable_gtktest" = "xyes" ; then
2501     ac_save_CFLAGS="$CFLAGS"
2502     ac_save_LIBS="$LIBS"
2503     CFLAGS="$CFLAGS $GTK_CFLAGS"
2504     LIBS="$LIBS $GTK_LIBS"
2505     rm -f conf.gtktest
2506     if test "$cross_compiling" = yes; then
2507     echo $ac_n "cross compiling; assumed OK... $ac_c"
2508     else
2509     cat > conftest.$ac_ext <<EOF
2510 cebix 1.13 #line 2511 "configure"
2511 cebix 1.1 #include "confdefs.h"
2512    
2513     #include <gtk/gtk.h>
2514     #include <stdio.h>
2515    
2516     int
2517     main ()
2518     {
2519     int major, minor, micro;
2520    
2521     system ("touch conf.gtktest");
2522    
2523     if (sscanf("$min_gtk_version", "%d.%d.%d", &major, &minor, &micro) != 3) {
2524     printf("%s, bad version string\n", "$min_gtk_version");
2525     exit(1);
2526     }
2527    
2528     if ((gtk_major_version != $gtk_config_major_version) ||
2529     (gtk_minor_version != $gtk_config_minor_version) ||
2530     (gtk_micro_version != $gtk_config_micro_version))
2531     {
2532     printf("\n*** 'gtk-config --version' returned %d.%d.%d, but GTK+ (%d.%d.%d)\n",
2533     $gtk_config_major_version, $gtk_config_minor_version, $gtk_config_micro_version,
2534     gtk_major_version, gtk_minor_version, gtk_micro_version);
2535     printf ("*** was found! If gtk-config was correct, then it is best\n");
2536     printf ("*** to remove the old version of GTK+. You may also be able to fix the error\n");
2537     printf("*** by modifying your LD_LIBRARY_PATH enviroment variable, or by editing\n");
2538     printf("*** /etc/ld.so.conf. Make sure you have run ldconfig if that is\n");
2539     printf("*** required on your system.\n");
2540     printf("*** If gtk-config was wrong, set the environment variable GTK_CONFIG\n");
2541     printf("*** to point to the correct copy of gtk-config, and remove the file config.cache\n");
2542     printf("*** before re-running configure\n");
2543     }
2544     else
2545     {
2546     if ((gtk_major_version > major) ||
2547     ((gtk_major_version == major) && (gtk_minor_version > minor)) ||
2548     ((gtk_major_version == major) && (gtk_minor_version == minor) && (gtk_micro_version >= micro)))
2549     {
2550     return 0;
2551     }
2552     else
2553     {
2554     printf("\n*** An old version of GTK+ (%d.%d.%d) was found.\n",
2555     gtk_major_version, gtk_minor_version, gtk_micro_version);
2556     printf("*** You need a version of GTK+ newer than %d.%d.%d. The latest version of\n",
2557     major, minor, micro);
2558     printf("*** GTK+ is always available from ftp://ftp.gtk.org.\n");
2559     printf("***\n");
2560     printf("*** If you have already installed a sufficiently new version, this error\n");
2561     printf("*** probably means that the wrong copy of the gtk-config shell script is\n");
2562     printf("*** being found. The easiest way to fix this is to remove the old version\n");
2563     printf("*** of GTK+, but you can also set the GTK_CONFIG environment to point to the\n");
2564     printf("*** correct copy of gtk-config. (In this case, you will have to\n");
2565     printf("*** modify your LD_LIBRARY_PATH enviroment variable, or edit /etc/ld.so.conf\n");
2566     printf("*** so that the correct libraries are found at run-time))\n");
2567     }
2568     }
2569     return 1;
2570     }
2571    
2572     EOF
2573 cebix 1.13 if { (eval echo configure:2574: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2574 cebix 1.1 then
2575     :
2576     else
2577     echo "configure: failed program was:" >&5
2578     cat conftest.$ac_ext >&5
2579     rm -fr conftest*
2580     no_gtk=yes
2581     fi
2582     rm -fr conftest*
2583     fi
2584    
2585     CFLAGS="$ac_save_CFLAGS"
2586     LIBS="$ac_save_LIBS"
2587     fi
2588     fi
2589     if test "x$no_gtk" = x ; then
2590     echo "$ac_t""yes" 1>&6
2591 cebix 1.9
2592     DEFINES="$DEFINES -DENABLE_GTK=1"
2593     CFLAGS="$CFLAGS $GTK_CFLAGS"
2594     CXXFLAGS="$CXXFLAGS $GTK_CFLAGS"
2595     LIBS="$LIBS $GTK_LIBS"
2596     UISRCS=prefs_editor_gtk.cpp
2597    
2598 cebix 1.1 else
2599     echo "$ac_t""no" 1>&6
2600     if test "$GTK_CONFIG" = "no" ; then
2601     echo "*** The gtk-config script installed by GTK could not be found"
2602     echo "*** If GTK was installed in PREFIX, make sure PREFIX/bin is in"
2603     echo "*** your path, or set the GTK_CONFIG environment variable to the"
2604     echo "*** full path to gtk-config."
2605     else
2606     if test -f conf.gtktest ; then
2607     :
2608     else
2609     echo "*** Could not run GTK test program, checking why..."
2610     CFLAGS="$CFLAGS $GTK_CFLAGS"
2611     LIBS="$LIBS $GTK_LIBS"
2612     cat > conftest.$ac_ext <<EOF
2613 cebix 1.13 #line 2614 "configure"
2614 cebix 1.1 #include "confdefs.h"
2615    
2616     #include <gtk/gtk.h>
2617     #include <stdio.h>
2618    
2619     int main() {
2620     return ((gtk_major_version) || (gtk_minor_version) || (gtk_micro_version));
2621     ; return 0; }
2622     EOF
2623 cebix 1.13 if { (eval echo configure:2624: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2624 cebix 1.1 rm -rf conftest*
2625     echo "*** The test program compiled, but did not run. This usually means"
2626     echo "*** that the run-time linker is not finding GTK or finding the wrong"
2627     echo "*** version of GTK. If it is not finding GTK, you'll need to set your"
2628     echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point"
2629     echo "*** to the installed location Also, make sure you have run ldconfig if that"
2630     echo "*** is required on your system"
2631     echo "***"
2632     echo "*** If you have an old version installed, it is best to remove it, although"
2633     echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH"
2634     echo "***"
2635     echo "*** If you have a RedHat 5.0 system, you should remove the GTK package that"
2636     echo "*** came with the system with the command"
2637     echo "***"
2638     echo "*** rpm --erase --nodeps gtk gtk-devel"
2639     else
2640     echo "configure: failed program was:" >&5
2641     cat conftest.$ac_ext >&5
2642     rm -rf conftest*
2643     echo "*** The test program failed to compile or link. See the file config.log for the"
2644     echo "*** exact error that occured. This usually means GTK was incorrectly installed"
2645     echo "*** or that you have moved GTK since it was installed. In the latter case, you"
2646     echo "*** may want to edit the gtk-config script: $GTK_CONFIG"
2647     fi
2648     rm -f conftest*
2649     CFLAGS="$ac_save_CFLAGS"
2650     LIBS="$ac_save_LIBS"
2651     fi
2652     fi
2653     GTK_CFLAGS=""
2654     GTK_LIBS=""
2655 cebix 1.9
2656     echo "configure: warning: Could not find GTK+, disabling user interface." 1>&2
2657 cebix 1.13 WANT_GTK=no
2658 cebix 1.14 DEFINES="$DEFINES -DENABLE_GTK=0"
2659 cebix 1.9
2660 cebix 1.1 fi
2661    
2662    
2663     rm -f conf.gtktest
2664    
2665 cebix 1.9 fi
2666    
2667     if [ "x$WANT_ESD" = "xyes" ]; then
2668     # Check whether --with-esd-prefix or --without-esd-prefix was given.
2669     if test "${with_esd_prefix+set}" = set; then
2670     withval="$with_esd_prefix"
2671     esd_prefix="$withval"
2672     else
2673     esd_prefix=""
2674     fi
2675    
2676     # Check whether --with-esd-exec-prefix or --without-esd-exec-prefix was given.
2677     if test "${with_esd_exec_prefix+set}" = set; then
2678     withval="$with_esd_exec_prefix"
2679     esd_exec_prefix="$withval"
2680     else
2681     esd_exec_prefix=""
2682     fi
2683    
2684     # Check whether --enable-esdtest or --disable-esdtest was given.
2685     if test "${enable_esdtest+set}" = set; then
2686     enableval="$enable_esdtest"
2687     :
2688     else
2689     enable_esdtest=yes
2690     fi
2691    
2692    
2693     if test x$esd_exec_prefix != x ; then
2694     esd_args="$esd_args --exec-prefix=$esd_exec_prefix"
2695     if test x${ESD_CONFIG+set} != xset ; then
2696     ESD_CONFIG=$esd_exec_prefix/bin/esd-config
2697     fi
2698     fi
2699     if test x$esd_prefix != x ; then
2700     esd_args="$esd_args --prefix=$esd_prefix"
2701     if test x${ESD_CONFIG+set} != xset ; then
2702     ESD_CONFIG=$esd_prefix/bin/esd-config
2703     fi
2704 cebix 1.1 fi
2705 cebix 1.9
2706     # Extract the first word of "esd-config", so it can be a program name with args.
2707     set dummy esd-config; ac_word=$2
2708     echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2709 cebix 1.14 echo "configure:2710: checking for $ac_word" >&5
2710 cebix 1.9 if eval "test \"`echo '$''{'ac_cv_path_ESD_CONFIG'+set}'`\" = set"; then
2711     echo $ac_n "(cached) $ac_c" 1>&6
2712     else
2713     case "$ESD_CONFIG" in
2714     /*)
2715     ac_cv_path_ESD_CONFIG="$ESD_CONFIG" # Let the user override the test with a path.
2716     ;;
2717     ?:/*)
2718     ac_cv_path_ESD_CONFIG="$ESD_CONFIG" # Let the user override the test with a dos path.
2719     ;;
2720     *)
2721     IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2722     ac_dummy="$PATH"
2723     for ac_dir in $ac_dummy; do
2724     test -z "$ac_dir" && ac_dir=.
2725     if test -f $ac_dir/$ac_word; then
2726     ac_cv_path_ESD_CONFIG="$ac_dir/$ac_word"
2727     break
2728     fi
2729     done
2730     IFS="$ac_save_ifs"
2731     test -z "$ac_cv_path_ESD_CONFIG" && ac_cv_path_ESD_CONFIG="no"
2732     ;;
2733     esac
2734     fi
2735     ESD_CONFIG="$ac_cv_path_ESD_CONFIG"
2736     if test -n "$ESD_CONFIG"; then
2737     echo "$ac_t""$ESD_CONFIG" 1>&6
2738     else
2739     echo "$ac_t""no" 1>&6
2740 cebix 1.1 fi
2741    
2742 cebix 1.9 min_esd_version=0.2.8
2743     echo $ac_n "checking for ESD - version >= $min_esd_version""... $ac_c" 1>&6
2744 cebix 1.14 echo "configure:2745: checking for ESD - version >= $min_esd_version" >&5
2745 cebix 1.9 no_esd=""
2746     if test "$ESD_CONFIG" = "no" ; then
2747     no_esd=yes
2748     else
2749     ESD_CFLAGS=`$ESD_CONFIG $esdconf_args --cflags`
2750     ESD_LIBS=`$ESD_CONFIG $esdconf_args --libs`
2751    
2752     esd_major_version=`$ESD_CONFIG $esd_args --version | \
2753     sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\1/'`
2754     esd_minor_version=`$ESD_CONFIG $esd_args --version | \
2755     sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\2/'`
2756     esd_micro_version=`$ESD_CONFIG $esd_config_args --version | \
2757     sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\3/'`
2758     if test "x$enable_esdtest" = "xyes" ; then
2759     ac_save_CFLAGS="$CFLAGS"
2760     ac_save_LIBS="$LIBS"
2761     CFLAGS="$CFLAGS $ESD_CFLAGS"
2762     LIBS="$LIBS $ESD_LIBS"
2763     rm -f conf.esdtest
2764     if test "$cross_compiling" = yes; then
2765     echo $ac_n "cross compiling; assumed OK... $ac_c"
2766 cebix 1.1 else
2767     cat > conftest.$ac_ext <<EOF
2768 cebix 1.14 #line 2769 "configure"
2769 cebix 1.1 #include "confdefs.h"
2770    
2771 cebix 1.9 #include <stdio.h>
2772     #include <stdlib.h>
2773     #include <string.h>
2774     #include <esd.h>
2775    
2776     char*
2777     my_strdup (char *str)
2778     {
2779     char *new_str;
2780    
2781     if (str)
2782     {
2783     new_str = malloc ((strlen (str) + 1) * sizeof(char));
2784     strcpy (new_str, str);
2785     }
2786     else
2787     new_str = NULL;
2788    
2789     return new_str;
2790     }
2791    
2792     int main ()
2793     {
2794     int major, minor, micro;
2795     char *tmp_version;
2796    
2797     system ("touch conf.esdtest");
2798    
2799     /* HP/UX 9 (%@#!) writes to sscanf strings */
2800     tmp_version = my_strdup("$min_esd_version");
2801     if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, &micro) != 3) {
2802     printf("%s, bad version string\n", "$min_esd_version");
2803     exit(1);
2804     }
2805    
2806     if (($esd_major_version > major) ||
2807     (($esd_major_version == major) && ($esd_minor_version > minor)) ||
2808     (($esd_major_version == major) && ($esd_minor_version == minor) && ($esd_micro_version >= micro)))
2809     {
2810     return 0;
2811     }
2812     else
2813     {
2814     printf("\n*** 'esd-config --version' returned %d.%d.%d, but the minimum version\n", $esd_major_version, $esd_minor_version, $esd_micro_version);
2815     printf("*** of ESD required is %d.%d.%d. If esd-config is correct, then it is\n", major, minor, micro);
2816     printf("*** best to upgrade to the required version.\n");
2817     printf("*** If esd-config was wrong, set the environment variable ESD_CONFIG\n");
2818     printf("*** to point to the correct copy of esd-config, and remove the file\n");
2819     printf("*** config.cache before re-running configure\n");
2820     return 1;
2821     }
2822     }
2823 cebix 1.1
2824    
2825     EOF
2826 cebix 1.14 if { (eval echo configure:2827: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2827 cebix 1.9 then
2828     :
2829 cebix 1.1 else
2830     echo "configure: failed program was:" >&5
2831     cat conftest.$ac_ext >&5
2832 cebix 1.9 rm -fr conftest*
2833     no_esd=yes
2834 cebix 1.1 fi
2835 cebix 1.9 rm -fr conftest*
2836 cebix 1.1 fi
2837    
2838 cebix 1.9 CFLAGS="$ac_save_CFLAGS"
2839     LIBS="$ac_save_LIBS"
2840     fi
2841     fi
2842     if test "x$no_esd" = x ; then
2843     echo "$ac_t""yes" 1>&6
2844    
2845     DEFINES="$DEFINES -DENABLE_ESD=1"
2846     CFLAGS="$CFLAGS $ESD_CFLAGS"
2847     CXXFLAGS="$CXXFLAGS $ESD_CFLAGS"
2848     LIBS="$LIBS $ESD_LIBS"
2849    
2850     else
2851     echo "$ac_t""no" 1>&6
2852     if test "$ESD_CONFIG" = "no" ; then
2853     echo "*** The esd-config script installed by ESD could not be found"
2854     echo "*** If ESD was installed in PREFIX, make sure PREFIX/bin is in"
2855     echo "*** your path, or set the ESD_CONFIG environment variable to the"
2856     echo "*** full path to esd-config."
2857     else
2858     if test -f conf.esdtest ; then
2859     :
2860     else
2861     echo "*** Could not run ESD test program, checking why..."
2862     CFLAGS="$CFLAGS $ESD_CFLAGS"
2863     LIBS="$LIBS $ESD_LIBS"
2864     cat > conftest.$ac_ext <<EOF
2865 cebix 1.14 #line 2866 "configure"
2866 cebix 1.9 #include "confdefs.h"
2867 cebix 1.1
2868 cebix 1.9 #include <stdio.h>
2869     #include <esd.h>
2870 cebix 1.1
2871     int main() {
2872 cebix 1.9 return 0;
2873 cebix 1.1 ; return 0; }
2874     EOF
2875 cebix 1.14 if { (eval echo configure:2876: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2876 cebix 1.1 rm -rf conftest*
2877 cebix 1.9 echo "*** The test program compiled, but did not run. This usually means"
2878     echo "*** that the run-time linker is not finding ESD or finding the wrong"
2879     echo "*** version of ESD. If it is not finding ESD, you'll need to set your"
2880     echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point"
2881     echo "*** to the installed location Also, make sure you have run ldconfig if that"
2882     echo "*** is required on your system"
2883     echo "***"
2884     echo "*** If you have an old version installed, it is best to remove it, although"
2885     echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH"
2886 cebix 1.1 else
2887     echo "configure: failed program was:" >&5
2888     cat conftest.$ac_ext >&5
2889     rm -rf conftest*
2890 cebix 1.9 echo "*** The test program failed to compile or link. See the file config.log for the"
2891     echo "*** exact error that occured. This usually means ESD was incorrectly installed"
2892     echo "*** or that you have moved ESD since it was installed. In the latter case, you"
2893     echo "*** may want to edit the esd-config script: $ESD_CONFIG"
2894 cebix 1.1 fi
2895     rm -f conftest*
2896 cebix 1.9 CFLAGS="$ac_save_CFLAGS"
2897     LIBS="$ac_save_LIBS"
2898     fi
2899     fi
2900     ESD_CFLAGS=""
2901     ESD_LIBS=""
2902    
2903     echo "configure: warning: Could not find ESD, disabling ESD support." 1>&2
2904     WANT_ESD=no
2905 cebix 1.14 DEFINES="$DEFINES -DENABLE_ESD=0"
2906 cebix 1.9
2907     fi
2908    
2909    
2910     rm -f conf.esdtest
2911 cebix 1.1
2912     fi
2913    
2914     echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
2915 cebix 1.14 echo "configure:2916: checking for ANSI C header files" >&5
2916 cebix 1.1 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
2917     echo $ac_n "(cached) $ac_c" 1>&6
2918     else
2919     cat > conftest.$ac_ext <<EOF
2920 cebix 1.14 #line 2921 "configure"
2921 cebix 1.1 #include "confdefs.h"
2922     #include <stdlib.h>
2923     #include <stdarg.h>
2924     #include <string.h>
2925     #include <float.h>
2926     EOF
2927     ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2928 cebix 1.14 { (eval echo configure:2929: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2929 cebix 1.1 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2930     if test -z "$ac_err"; then
2931     rm -rf conftest*
2932     ac_cv_header_stdc=yes
2933     else
2934     echo "$ac_err" >&5
2935     echo "configure: failed program was:" >&5
2936     cat conftest.$ac_ext >&5
2937     rm -rf conftest*
2938     ac_cv_header_stdc=no
2939     fi
2940     rm -f conftest*
2941    
2942     if test $ac_cv_header_stdc = yes; then
2943     # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
2944     cat > conftest.$ac_ext <<EOF
2945 cebix 1.14 #line 2946 "configure"
2946 cebix 1.1 #include "confdefs.h"
2947     #include <string.h>
2948     EOF
2949     if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2950     egrep "memchr" >/dev/null 2>&1; then
2951     :
2952     else
2953     rm -rf conftest*
2954     ac_cv_header_stdc=no
2955     fi
2956     rm -f conftest*
2957    
2958     fi
2959    
2960     if test $ac_cv_header_stdc = yes; then
2961     # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
2962     cat > conftest.$ac_ext <<EOF
2963 cebix 1.14 #line 2964 "configure"
2964 cebix 1.1 #include "confdefs.h"
2965     #include <stdlib.h>
2966     EOF
2967     if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2968     egrep "free" >/dev/null 2>&1; then
2969     :
2970     else
2971     rm -rf conftest*
2972     ac_cv_header_stdc=no
2973     fi
2974     rm -f conftest*
2975    
2976     fi
2977    
2978     if test $ac_cv_header_stdc = yes; then
2979     # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
2980     if test "$cross_compiling" = yes; then
2981     :
2982     else
2983     cat > conftest.$ac_ext <<EOF
2984 cebix 1.14 #line 2985 "configure"
2985 cebix 1.1 #include "confdefs.h"
2986     #include <ctype.h>
2987     #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
2988     #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
2989     #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
2990     int main () { int i; for (i = 0; i < 256; i++)
2991     if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
2992     exit (0); }
2993    
2994     EOF
2995 cebix 1.14 if { (eval echo configure:2996: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2996 cebix 1.1 then
2997     :
2998     else
2999     echo "configure: failed program was:" >&5
3000     cat conftest.$ac_ext >&5
3001     rm -fr conftest*
3002     ac_cv_header_stdc=no
3003     fi
3004     rm -fr conftest*
3005     fi
3006    
3007     fi
3008     fi
3009    
3010     echo "$ac_t""$ac_cv_header_stdc" 1>&6
3011     if test $ac_cv_header_stdc = yes; then
3012     cat >> confdefs.h <<\EOF
3013     #define STDC_HEADERS 1
3014     EOF
3015    
3016     fi
3017    
3018     for ac_hdr in unistd.h fcntl.h sys/time.h
3019     do
3020     ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
3021     echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
3022 cebix 1.14 echo "configure:3023: checking for $ac_hdr" >&5
3023 cebix 1.1 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3024     echo $ac_n "(cached) $ac_c" 1>&6
3025     else
3026     cat > conftest.$ac_ext <<EOF
3027 cebix 1.14 #line 3028 "configure"
3028 cebix 1.1 #include "confdefs.h"
3029     #include <$ac_hdr>
3030     EOF
3031     ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3032 cebix 1.14 { (eval echo configure:3033: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3033 cebix 1.1 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3034     if test -z "$ac_err"; then
3035     rm -rf conftest*
3036     eval "ac_cv_header_$ac_safe=yes"
3037     else
3038     echo "$ac_err" >&5
3039     echo "configure: failed program was:" >&5
3040     cat conftest.$ac_ext >&5
3041     rm -rf conftest*
3042     eval "ac_cv_header_$ac_safe=no"
3043     fi
3044     rm -f conftest*
3045     fi
3046     if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3047     echo "$ac_t""yes" 1>&6
3048     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
3049     cat >> confdefs.h <<EOF
3050     #define $ac_tr_hdr 1
3051     EOF
3052    
3053     else
3054     echo "$ac_t""no" 1>&6
3055     fi
3056     done
3057    
3058    
3059     echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6
3060 cebix 1.14 echo "configure:3061: checking whether byte ordering is bigendian" >&5
3061 cebix 1.1 if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then
3062     echo $ac_n "(cached) $ac_c" 1>&6
3063     else
3064     ac_cv_c_bigendian=unknown
3065     # See if sys/param.h defines the BYTE_ORDER macro.
3066     cat > conftest.$ac_ext <<EOF
3067 cebix 1.14 #line 3068 "configure"
3068 cebix 1.1 #include "confdefs.h"
3069     #include <sys/types.h>
3070     #include <sys/param.h>
3071     int main() {
3072    
3073     #if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
3074     bogus endian macros
3075     #endif
3076     ; return 0; }
3077     EOF
3078 cebix 1.14 if { (eval echo configure:3079: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3079 cebix 1.1 rm -rf conftest*
3080     # It does; now see whether it defined to BIG_ENDIAN or not.
3081     cat > conftest.$ac_ext <<EOF
3082 cebix 1.14 #line 3083 "configure"
3083 cebix 1.1 #include "confdefs.h"
3084     #include <sys/types.h>
3085     #include <sys/param.h>
3086     int main() {
3087    
3088     #if BYTE_ORDER != BIG_ENDIAN
3089     not big endian
3090     #endif
3091     ; return 0; }
3092     EOF
3093 cebix 1.14 if { (eval echo configure:3094: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3094 cebix 1.1 rm -rf conftest*
3095     ac_cv_c_bigendian=yes
3096     else
3097     echo "configure: failed program was:" >&5
3098     cat conftest.$ac_ext >&5
3099     rm -rf conftest*
3100     ac_cv_c_bigendian=no
3101     fi
3102     rm -f conftest*
3103     else
3104     echo "configure: failed program was:" >&5
3105     cat conftest.$ac_ext >&5
3106     fi
3107     rm -f conftest*
3108     if test $ac_cv_c_bigendian = unknown; then
3109     if test "$cross_compiling" = yes; then
3110     { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
3111     else
3112     cat > conftest.$ac_ext <<EOF
3113 cebix 1.14 #line 3114 "configure"
3114 cebix 1.1 #include "confdefs.h"
3115     main () {
3116     /* Are we little or big endian? From Harbison&Steele. */
3117     union
3118     {
3119     long l;
3120     char c[sizeof (long)];
3121     } u;
3122     u.l = 1;
3123     exit (u.c[sizeof (long) - 1] == 1);
3124     }
3125     EOF
3126 cebix 1.14 if { (eval echo configure:3127: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
3127 cebix 1.1 then
3128     ac_cv_c_bigendian=no
3129     else
3130     echo "configure: failed program was:" >&5
3131     cat conftest.$ac_ext >&5
3132     rm -fr conftest*
3133     ac_cv_c_bigendian=yes
3134     fi
3135     rm -fr conftest*
3136     fi
3137    
3138     fi
3139     fi
3140    
3141     echo "$ac_t""$ac_cv_c_bigendian" 1>&6
3142     if test $ac_cv_c_bigendian = yes; then
3143     cat >> confdefs.h <<\EOF
3144     #define WORDS_BIGENDIAN 1
3145     EOF
3146    
3147     fi
3148    
3149     echo $ac_n "checking for working const""... $ac_c" 1>&6
3150 cebix 1.14 echo "configure:3151: checking for working const" >&5
3151 cebix 1.1 if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
3152     echo $ac_n "(cached) $ac_c" 1>&6
3153     else
3154     cat > conftest.$ac_ext <<EOF
3155 cebix 1.14 #line 3156 "configure"
3156 cebix 1.1 #include "confdefs.h"
3157    
3158     int main() {
3159    
3160     /* Ultrix mips cc rejects this. */
3161     typedef int charset[2]; const charset x;
3162     /* SunOS 4.1.1 cc rejects this. */
3163     char const *const *ccp;
3164     char **p;
3165     /* NEC SVR4.0.2 mips cc rejects this. */
3166     struct point {int x, y;};
3167     static struct point const zero = {0,0};
3168     /* AIX XL C 1.02.0.0 rejects this.
3169     It does not let you subtract one const X* pointer from another in an arm
3170     of an if-expression whose if-part is not a constant expression */
3171     const char *g = "string";
3172     ccp = &g + (g ? g-g : 0);
3173     /* HPUX 7.0 cc rejects these. */
3174     ++ccp;
3175     p = (char**) ccp;
3176     ccp = (char const *const *) p;
3177     { /* SCO 3.2v4 cc rejects this. */
3178     char *t;
3179     char const *s = 0 ? (char *) 0 : (char const *) 0;
3180    
3181     *t++ = 0;
3182     }
3183     { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
3184     int x[] = {25, 17};
3185     const int *foo = &x[0];
3186     ++foo;
3187     }
3188     { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
3189     typedef const int *iptr;
3190     iptr p = 0;
3191     ++p;
3192     }
3193     { /* AIX XL C 1.02.0.0 rejects this saying
3194     "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
3195     struct s { int j; const int *ap[3]; };
3196     struct s *b; b->j = 5;
3197     }
3198     { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
3199     const int foo = 10;
3200     }
3201    
3202     ; return 0; }
3203     EOF
3204 cebix 1.14 if { (eval echo configure:3205: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3205 cebix 1.1 rm -rf conftest*
3206     ac_cv_c_const=yes
3207     else
3208     echo "configure: failed program was:" >&5
3209     cat conftest.$ac_ext >&5
3210     rm -rf conftest*
3211     ac_cv_c_const=no
3212     fi
3213     rm -f conftest*
3214     fi
3215    
3216     echo "$ac_t""$ac_cv_c_const" 1>&6
3217     if test $ac_cv_c_const = no; then
3218     cat >> confdefs.h <<\EOF
3219     #define const
3220     EOF
3221    
3222     fi
3223    
3224     echo $ac_n "checking for inline""... $ac_c" 1>&6
3225 cebix 1.14 echo "configure:3226: checking for inline" >&5
3226 cebix 1.1 if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
3227     echo $ac_n "(cached) $ac_c" 1>&6
3228     else
3229     ac_cv_c_inline=no
3230     for ac_kw in inline __inline__ __inline; do
3231     cat > conftest.$ac_ext <<EOF
3232 cebix 1.14 #line 3233 "configure"
3233 cebix 1.1 #include "confdefs.h"
3234    
3235     int main() {
3236     } $ac_kw foo() {
3237     ; return 0; }
3238     EOF
3239 cebix 1.14 if { (eval echo configure:3240: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3240 cebix 1.1 rm -rf conftest*
3241     ac_cv_c_inline=$ac_kw; break
3242     else
3243     echo "configure: failed program was:" >&5
3244     cat conftest.$ac_ext >&5
3245     fi
3246     rm -f conftest*
3247     done
3248    
3249     fi
3250    
3251     echo "$ac_t""$ac_cv_c_inline" 1>&6
3252     case "$ac_cv_c_inline" in
3253     inline | yes) ;;
3254     no) cat >> confdefs.h <<\EOF
3255     #define inline
3256     EOF
3257     ;;
3258     *) cat >> confdefs.h <<EOF
3259     #define inline $ac_cv_c_inline
3260     EOF
3261     ;;
3262     esac
3263    
3264     echo $ac_n "checking size of short""... $ac_c" 1>&6
3265 cebix 1.14 echo "configure:3266: checking size of short" >&5
3266 cebix 1.1 if eval "test \"`echo '$''{'ac_cv_sizeof_short'+set}'`\" = set"; then
3267     echo $ac_n "(cached) $ac_c" 1>&6
3268     else
3269     if test "$cross_compiling" = yes; then
3270     ac_cv_sizeof_short=2
3271     else
3272     cat > conftest.$ac_ext <<EOF
3273 cebix 1.14 #line 3274 "configure"
3274 cebix 1.1 #include "confdefs.h"
3275     #include <stdio.h>
3276     main()
3277     {
3278     FILE *f=fopen("conftestval", "w");
3279     if (!f) exit(1);
3280     fprintf(f, "%d\n", sizeof(short));
3281     exit(0);
3282     }
3283     EOF
3284 cebix 1.14 if { (eval echo configure:3285: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
3285 cebix 1.1 then
3286     ac_cv_sizeof_short=`cat conftestval`
3287     else
3288     echo "configure: failed program was:" >&5
3289     cat conftest.$ac_ext >&5
3290     rm -fr conftest*
3291     ac_cv_sizeof_short=0
3292     fi
3293     rm -fr conftest*
3294     fi
3295    
3296     fi
3297     echo "$ac_t""$ac_cv_sizeof_short" 1>&6
3298     cat >> confdefs.h <<EOF
3299     #define SIZEOF_SHORT $ac_cv_sizeof_short
3300     EOF
3301    
3302    
3303     echo $ac_n "checking size of int""... $ac_c" 1>&6
3304 cebix 1.14 echo "configure:3305: checking size of int" >&5
3305 cebix 1.1 if eval "test \"`echo '$''{'ac_cv_sizeof_int'+set}'`\" = set"; then
3306     echo $ac_n "(cached) $ac_c" 1>&6
3307     else
3308     if test "$cross_compiling" = yes; then
3309     ac_cv_sizeof_int=4
3310     else
3311     cat > conftest.$ac_ext <<EOF
3312 cebix 1.14 #line 3313 "configure"
3313 cebix 1.1 #include "confdefs.h"
3314     #include <stdio.h>
3315     main()
3316     {
3317     FILE *f=fopen("conftestval", "w");
3318     if (!f) exit(1);
3319     fprintf(f, "%d\n", sizeof(int));
3320     exit(0);
3321     }
3322     EOF
3323 cebix 1.14 if { (eval echo configure:3324: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
3324 cebix 1.1 then
3325     ac_cv_sizeof_int=`cat conftestval`
3326     else
3327     echo "configure: failed program was:" >&5
3328     cat conftest.$ac_ext >&5
3329     rm -fr conftest*
3330     ac_cv_sizeof_int=0
3331     fi
3332     rm -fr conftest*
3333     fi
3334    
3335     fi
3336     echo "$ac_t""$ac_cv_sizeof_int" 1>&6
3337     cat >> confdefs.h <<EOF
3338     #define SIZEOF_INT $ac_cv_sizeof_int
3339     EOF
3340    
3341    
3342     echo $ac_n "checking size of long""... $ac_c" 1>&6
3343 cebix 1.14 echo "configure:3344: checking size of long" >&5
3344 cebix 1.1 if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then
3345     echo $ac_n "(cached) $ac_c" 1>&6
3346     else
3347     if test "$cross_compiling" = yes; then
3348     ac_cv_sizeof_long=4
3349     else
3350     cat > conftest.$ac_ext <<EOF
3351 cebix 1.14 #line 3352 "configure"
3352 cebix 1.1 #include "confdefs.h"
3353     #include <stdio.h>
3354     main()
3355     {
3356     FILE *f=fopen("conftestval", "w");
3357     if (!f) exit(1);
3358     fprintf(f, "%d\n", sizeof(long));
3359     exit(0);
3360     }
3361     EOF
3362 cebix 1.14 if { (eval echo configure:3363: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
3363 cebix 1.1 then
3364     ac_cv_sizeof_long=`cat conftestval`
3365     else
3366     echo "configure: failed program was:" >&5
3367     cat conftest.$ac_ext >&5
3368     rm -fr conftest*
3369     ac_cv_sizeof_long=0
3370     fi
3371     rm -fr conftest*
3372     fi
3373    
3374     fi
3375     echo "$ac_t""$ac_cv_sizeof_long" 1>&6
3376     cat >> confdefs.h <<EOF
3377     #define SIZEOF_LONG $ac_cv_sizeof_long
3378     EOF
3379    
3380    
3381     echo $ac_n "checking size of long long""... $ac_c" 1>&6
3382 cebix 1.14 echo "configure:3383: checking size of long long" >&5
3383 cebix 1.1 if eval "test \"`echo '$''{'ac_cv_sizeof_long_long'+set}'`\" = set"; then
3384     echo $ac_n "(cached) $ac_c" 1>&6
3385     else
3386     if test "$cross_compiling" = yes; then
3387     ac_cv_sizeof_long_long=8
3388     else
3389     cat > conftest.$ac_ext <<EOF
3390 cebix 1.14 #line 3391 "configure"
3391 cebix 1.1 #include "confdefs.h"
3392     #include <stdio.h>
3393     main()
3394     {
3395     FILE *f=fopen("conftestval", "w");
3396     if (!f) exit(1);
3397     fprintf(f, "%d\n", sizeof(long long));
3398     exit(0);
3399     }
3400     EOF
3401 cebix 1.14 if { (eval echo configure:3402: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
3402 cebix 1.1 then
3403     ac_cv_sizeof_long_long=`cat conftestval`
3404     else
3405     echo "configure: failed program was:" >&5
3406     cat conftest.$ac_ext >&5
3407     rm -fr conftest*
3408     ac_cv_sizeof_long_long=0
3409     fi
3410     rm -fr conftest*
3411     fi
3412    
3413     fi
3414     echo "$ac_t""$ac_cv_sizeof_long_long" 1>&6
3415     cat >> confdefs.h <<EOF
3416     #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
3417     EOF
3418    
3419    
3420     echo $ac_n "checking for off_t""... $ac_c" 1>&6
3421 cebix 1.14 echo "configure:3422: checking for off_t" >&5
3422 cebix 1.1 if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
3423     echo $ac_n "(cached) $ac_c" 1>&6
3424     else
3425     cat > conftest.$ac_ext <<EOF
3426 cebix 1.14 #line 3427 "configure"
3427 cebix 1.1 #include "confdefs.h"
3428     #include <sys/types.h>
3429     #if STDC_HEADERS
3430     #include <stdlib.h>
3431     #include <stddef.h>
3432     #endif
3433     EOF
3434     if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3435     egrep "(^|[^a-zA-Z_0-9])off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
3436     rm -rf conftest*
3437     ac_cv_type_off_t=yes
3438     else
3439     rm -rf conftest*
3440     ac_cv_type_off_t=no
3441     fi
3442     rm -f conftest*
3443    
3444     fi
3445     echo "$ac_t""$ac_cv_type_off_t" 1>&6
3446     if test $ac_cv_type_off_t = no; then
3447     cat >> confdefs.h <<\EOF
3448     #define off_t long
3449     EOF
3450    
3451     fi
3452    
3453     echo $ac_n "checking for loff_t""... $ac_c" 1>&6
3454 cebix 1.14 echo "configure:3455: checking for loff_t" >&5
3455 cebix 1.1 if eval "test \"`echo '$''{'ac_cv_type_loff_t'+set}'`\" = set"; then
3456     echo $ac_n "(cached) $ac_c" 1>&6
3457     else
3458     cat > conftest.$ac_ext <<EOF
3459 cebix 1.14 #line 3460 "configure"
3460 cebix 1.1 #include "confdefs.h"
3461     #include <sys/types.h>
3462     #if STDC_HEADERS
3463     #include <stdlib.h>
3464     #include <stddef.h>
3465     #endif
3466     EOF
3467     if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3468     egrep "(^|[^a-zA-Z_0-9])loff_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
3469     rm -rf conftest*
3470     ac_cv_type_loff_t=yes
3471     else
3472     rm -rf conftest*
3473     ac_cv_type_loff_t=no
3474     fi
3475     rm -f conftest*
3476    
3477     fi
3478     echo "$ac_t""$ac_cv_type_loff_t" 1>&6
3479     if test $ac_cv_type_loff_t = no; then
3480     cat >> confdefs.h <<\EOF
3481     #define loff_t off_t
3482     EOF
3483    
3484     fi
3485    
3486     echo $ac_n "checking for size_t""... $ac_c" 1>&6
3487 cebix 1.14 echo "configure:3488: checking for size_t" >&5
3488 cebix 1.1 if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
3489     echo $ac_n "(cached) $ac_c" 1>&6
3490     else
3491     cat > conftest.$ac_ext <<EOF
3492 cebix 1.14 #line 3493 "configure"
3493 cebix 1.1 #include "confdefs.h"
3494     #include <sys/types.h>
3495     #if STDC_HEADERS
3496     #include <stdlib.h>
3497     #include <stddef.h>
3498     #endif
3499     EOF
3500     if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3501     egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
3502     rm -rf conftest*
3503     ac_cv_type_size_t=yes
3504     else
3505     rm -rf conftest*
3506     ac_cv_type_size_t=no
3507     fi
3508     rm -f conftest*
3509    
3510     fi
3511     echo "$ac_t""$ac_cv_type_size_t" 1>&6
3512     if test $ac_cv_type_size_t = no; then
3513     cat >> confdefs.h <<\EOF
3514     #define size_t unsigned
3515     EOF
3516    
3517     fi
3518    
3519     echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
3520 cebix 1.14 echo "configure:3521: checking whether time.h and sys/time.h may both be included" >&5
3521 cebix 1.1 if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then
3522     echo $ac_n "(cached) $ac_c" 1>&6
3523     else
3524     cat > conftest.$ac_ext <<EOF
3525 cebix 1.14 #line 3526 "configure"
3526 cebix 1.1 #include "confdefs.h"
3527     #include <sys/types.h>
3528     #include <sys/time.h>
3529     #include <time.h>
3530     int main() {
3531     struct tm *tp;
3532     ; return 0; }
3533     EOF
3534 cebix 1.14 if { (eval echo configure:3535: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3535 cebix 1.1 rm -rf conftest*
3536     ac_cv_header_time=yes
3537     else
3538     echo "configure: failed program was:" >&5
3539     cat conftest.$ac_ext >&5
3540     rm -rf conftest*
3541     ac_cv_header_time=no
3542     fi
3543     rm -f conftest*
3544     fi
3545    
3546     echo "$ac_t""$ac_cv_header_time" 1>&6
3547     if test $ac_cv_header_time = yes; then
3548     cat >> confdefs.h <<\EOF
3549     #define TIME_WITH_SYS_TIME 1
3550     EOF
3551    
3552     fi
3553    
3554     echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&6
3555 cebix 1.14 echo "configure:3556: checking whether struct tm is in sys/time.h or time.h" >&5
3556 cebix 1.1 if eval "test \"`echo '$''{'ac_cv_struct_tm'+set}'`\" = set"; then
3557     echo $ac_n "(cached) $ac_c" 1>&6
3558     else
3559     cat > conftest.$ac_ext <<EOF
3560 cebix 1.14 #line 3561 "configure"
3561 cebix 1.1 #include "confdefs.h"
3562     #include <sys/types.h>
3563     #include <time.h>
3564     int main() {
3565     struct tm *tp; tp->tm_sec;
3566     ; return 0; }
3567     EOF
3568 cebix 1.14 if { (eval echo configure:3569: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3569 cebix 1.1 rm -rf conftest*
3570     ac_cv_struct_tm=time.h
3571     else
3572     echo "configure: failed program was:" >&5
3573     cat conftest.$ac_ext >&5
3574     rm -rf conftest*
3575     ac_cv_struct_tm=sys/time.h
3576     fi
3577     rm -f conftest*
3578     fi
3579    
3580     echo "$ac_t""$ac_cv_struct_tm" 1>&6
3581     if test $ac_cv_struct_tm = sys/time.h; then
3582     cat >> confdefs.h <<\EOF
3583     #define TM_IN_SYS_TIME 1
3584     EOF
3585    
3586     fi
3587    
3588    
3589     for ac_func in strdup cfmakeraw
3590     do
3591     echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3592 cebix 1.14 echo "configure:3593: checking for $ac_func" >&5
3593 cebix 1.1 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3594     echo $ac_n "(cached) $ac_c" 1>&6
3595     else
3596     cat > conftest.$ac_ext <<EOF
3597 cebix 1.14 #line 3598 "configure"
3598 cebix 1.1 #include "confdefs.h"
3599     /* System header to define __stub macros and hopefully few prototypes,
3600     which can conflict with char $ac_func(); below. */
3601     #include <assert.h>
3602     /* Override any gcc2 internal prototype to avoid an error. */
3603     /* We use char because int might match the return type of a gcc2
3604     builtin and then its argument prototype would still apply. */
3605     char $ac_func();
3606    
3607     int main() {
3608    
3609     /* The GNU C library defines this for functions which it implements
3610     to always fail with ENOSYS. Some functions are actually named
3611     something starting with __ and the normal name is an alias. */
3612     #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3613     choke me
3614     #else
3615     $ac_func();
3616     #endif
3617    
3618     ; return 0; }
3619     EOF
3620 cebix 1.14 if { (eval echo configure:3621: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3621 cebix 1.1 rm -rf conftest*
3622     eval "ac_cv_func_$ac_func=yes"
3623     else
3624     echo "configure: failed program was:" >&5
3625     cat conftest.$ac_ext >&5
3626     rm -rf conftest*
3627     eval "ac_cv_func_$ac_func=no"
3628     fi
3629     rm -f conftest*
3630     fi
3631    
3632     if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3633     echo "$ac_t""yes" 1>&6
3634     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3635     cat >> confdefs.h <<EOF
3636     #define $ac_tr_func 1
3637     EOF
3638    
3639     else
3640     echo "$ac_t""no" 1>&6
3641     fi
3642     done
3643    
3644     for ac_func in nanosleep clock_gettime timer_create
3645     do
3646     echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3647 cebix 1.14 echo "configure:3648: checking for $ac_func" >&5
3648 cebix 1.1 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3649     echo $ac_n "(cached) $ac_c" 1>&6
3650     else
3651     cat > conftest.$ac_ext <<EOF
3652 cebix 1.14 #line 3653 "configure"
3653 cebix 1.1 #include "confdefs.h"
3654     /* System header to define __stub macros and hopefully few prototypes,
3655     which can conflict with char $ac_func(); below. */
3656     #include <assert.h>
3657     /* Override any gcc2 internal prototype to avoid an error. */
3658     /* We use char because int might match the return type of a gcc2
3659     builtin and then its argument prototype would still apply. */
3660     char $ac_func();
3661    
3662     int main() {
3663    
3664     /* The GNU C library defines this for functions which it implements
3665     to always fail with ENOSYS. Some functions are actually named
3666     something starting with __ and the normal name is an alias. */
3667     #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3668     choke me
3669     #else
3670     $ac_func();
3671     #endif
3672    
3673     ; return 0; }
3674     EOF
3675 cebix 1.14 if { (eval echo configure:3676: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3676 cebix 1.9 rm -rf conftest*
3677     eval "ac_cv_func_$ac_func=yes"
3678     else
3679     echo "configure: failed program was:" >&5
3680     cat conftest.$ac_ext >&5
3681     rm -rf conftest*
3682     eval "ac_cv_func_$ac_func=no"
3683     fi
3684     rm -f conftest*
3685     fi
3686    
3687     if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3688     echo "$ac_t""yes" 1>&6
3689     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3690     cat >> confdefs.h <<EOF
3691     #define $ac_tr_func 1
3692     EOF
3693    
3694     else
3695     echo "$ac_t""no" 1>&6
3696     fi
3697     done
3698    
3699     for ac_func in pthread_cancel
3700     do
3701     echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3702 cebix 1.14 echo "configure:3703: checking for $ac_func" >&5
3703 cebix 1.9 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3704     echo $ac_n "(cached) $ac_c" 1>&6
3705     else
3706     cat > conftest.$ac_ext <<EOF
3707 cebix 1.14 #line 3708 "configure"
3708 cebix 1.9 #include "confdefs.h"
3709     /* System header to define __stub macros and hopefully few prototypes,
3710     which can conflict with char $ac_func(); below. */
3711     #include <assert.h>
3712     /* Override any gcc2 internal prototype to avoid an error. */
3713     /* We use char because int might match the return type of a gcc2
3714     builtin and then its argument prototype would still apply. */
3715     char $ac_func();
3716    
3717     int main() {
3718    
3719     /* The GNU C library defines this for functions which it implements
3720     to always fail with ENOSYS. Some functions are actually named
3721     something starting with __ and the normal name is an alias. */
3722     #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3723     choke me
3724     #else
3725     $ac_func();
3726     #endif
3727    
3728     ; return 0; }
3729     EOF
3730 cebix 1.14 if { (eval echo configure:3731: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3731 cebix 1.1 rm -rf conftest*
3732     eval "ac_cv_func_$ac_func=yes"
3733     else
3734     echo "configure: failed program was:" >&5
3735     cat conftest.$ac_ext >&5
3736     rm -rf conftest*
3737     eval "ac_cv_func_$ac_func=no"
3738     fi
3739     rm -f conftest*
3740     fi
3741    
3742     if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3743     echo "$ac_t""yes" 1>&6
3744     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3745     cat >> confdefs.h <<EOF
3746     #define $ac_tr_func 1
3747     EOF
3748    
3749     else
3750     echo "$ac_t""no" 1>&6
3751     fi
3752     done
3753    
3754    
3755     SYSSRCS="../dummy/ether_dummy.cpp ../dummy/scsi_dummy.cpp ../dummy/audio_dummy.cpp"
3756     if MACHINE=`uname -a 2>/dev/null`; then
3757     case "$MACHINE" in
3758     Linux*)
3759 cebix 1.9 SYSSRCS="Linux/ether_linux.cpp Linux/scsi_linux.cpp audio_oss_esd.cpp"
3760 cebix 1.1 ;;
3761     FreeBSD*3.*)
3762     echo $ac_n "checking for cam_open_btl in -lcam""... $ac_c" 1>&6
3763 cebix 1.14 echo "configure:3764: checking for cam_open_btl in -lcam" >&5
3764 cebix 1.1 ac_lib_var=`echo cam'_'cam_open_btl | sed 'y%./+-%__p_%'`
3765     if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3766     echo $ac_n "(cached) $ac_c" 1>&6
3767     else
3768     ac_save_LIBS="$LIBS"
3769     LIBS="-lcam $LIBS"
3770     cat > conftest.$ac_ext <<EOF
3771 cebix 1.14 #line 3772 "configure"
3772 cebix 1.1 #include "confdefs.h"
3773     /* Override any gcc2 internal prototype to avoid an error. */
3774     /* We use char because int might match the return type of a gcc2
3775     builtin and then its argument prototype would still apply. */
3776     char cam_open_btl();
3777    
3778     int main() {
3779     cam_open_btl()
3780     ; return 0; }
3781     EOF
3782 cebix 1.14 if { (eval echo configure:3783: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3783 cebix 1.1 rm -rf conftest*
3784     eval "ac_cv_lib_$ac_lib_var=yes"
3785     else
3786     echo "configure: failed program was:" >&5
3787     cat conftest.$ac_ext >&5
3788     rm -rf conftest*
3789     eval "ac_cv_lib_$ac_lib_var=no"
3790     fi
3791     rm -f conftest*
3792     LIBS="$ac_save_LIBS"
3793    
3794     fi
3795     if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3796     echo "$ac_t""yes" 1>&6
3797     HAVE_LIBCAM=yes
3798     else
3799     echo "$ac_t""no" 1>&6
3800     HAVE_LIBCAM=no
3801     fi
3802    
3803     if [ "x$HAVE_LIBCAM" = "xno" ]; then
3804     { echo "configure: error: Cannot find libcam for SCSI management." 1>&2; exit 1; }
3805     else
3806     ac_safe=`echo "/sys/cam/cam.h" | sed 'y%./+-%__p_%'`
3807     echo $ac_n "checking for /sys/cam/cam.h""... $ac_c" 1>&6
3808 cebix 1.14 echo "configure:3809: checking for /sys/cam/cam.h" >&5
3809 cebix 1.1 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3810     echo $ac_n "(cached) $ac_c" 1>&6
3811     else
3812     cat > conftest.$ac_ext <<EOF
3813 cebix 1.14 #line 3814 "configure"
3814 cebix 1.1 #include "confdefs.h"
3815     #include </sys/cam/cam.h>
3816     EOF
3817     ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3818 cebix 1.14 { (eval echo configure:3819: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3819 cebix 1.1 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3820     if test -z "$ac_err"; then
3821     rm -rf conftest*
3822     eval "ac_cv_header_$ac_safe=yes"
3823     else
3824     echo "$ac_err" >&5
3825     echo "configure: failed program was:" >&5
3826     cat conftest.$ac_ext >&5
3827     rm -rf conftest*
3828     eval "ac_cv_header_$ac_safe=no"
3829     fi
3830     rm -f conftest*
3831     fi
3832     if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3833     echo "$ac_t""yes" 1>&6
3834     :
3835     else
3836     echo "$ac_t""no" 1>&6
3837     fi
3838    
3839     if [ "x$ac_cv_header__sys_cam_cam_h" = "xno" ]; then
3840     { echo "configure: error: Cannot find kernel includes for CAM library." 1>&2; exit 1; }
3841     fi
3842 cebix 1.9 SYSSRCS="../dummy/ether_dummy.cpp FreeBSD/scsi_freebsd.cpp audio_oss_esd.cpp"
3843 cebix 1.1 CXXFLAGS="$CXXFLAGS -I/sys"
3844     CFLAGS="$CFLAGS -I/sys"
3845     LIBS="$LIBS -lcam"
3846     DEFINES="$DEFINES -DBSD_COMP -DCAM"
3847     fi
3848     ;;
3849     FreeBSD*)
3850     echo $ac_n "checking for scsi_open in -lscsi""... $ac_c" 1>&6
3851 cebix 1.14 echo "configure:3852: checking for scsi_open in -lscsi" >&5
3852 cebix 1.1 ac_lib_var=`echo scsi'_'scsi_open | sed 'y%./+-%__p_%'`
3853     if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3854     echo $ac_n "(cached) $ac_c" 1>&6
3855     else
3856     ac_save_LIBS="$LIBS"
3857     LIBS="-lscsi $LIBS"
3858     cat > conftest.$ac_ext <<EOF
3859 cebix 1.14 #line 3860 "configure"
3860 cebix 1.1 #include "confdefs.h"
3861     /* Override any gcc2 internal prototype to avoid an error. */
3862     /* We use char because int might match the return type of a gcc2
3863     builtin and then its argument prototype would still apply. */
3864     char scsi_open();
3865    
3866     int main() {
3867     scsi_open()
3868     ; return 0; }
3869     EOF
3870 cebix 1.14 if { (eval echo configure:3871: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3871 cebix 1.1 rm -rf conftest*
3872     eval "ac_cv_lib_$ac_lib_var=yes"
3873     else
3874     echo "configure: failed program was:" >&5
3875     cat conftest.$ac_ext >&5
3876     rm -rf conftest*
3877     eval "ac_cv_lib_$ac_lib_var=no"
3878     fi
3879     rm -f conftest*
3880     LIBS="$ac_save_LIBS"
3881    
3882     fi
3883     if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3884     echo "$ac_t""yes" 1>&6
3885     HAVE_LIBSCSI=yes
3886     else
3887     echo "$ac_t""no" 1>&6
3888     HAVE_LIBSCSI=no
3889     fi
3890    
3891     if [ "x$HAVE_LIBSCSI" = "xno" ]; then
3892     { echo "configure: error: Cannot find libscsi for SCSI management." 1>&2; exit 1; }
3893     else
3894     ac_safe=`echo "scsi.h sys/scsiio.h" | sed 'y%./+-%__p_%'`
3895     echo $ac_n "checking for scsi.h sys/scsiio.h""... $ac_c" 1>&6
3896 cebix 1.14 echo "configure:3897: checking for scsi.h sys/scsiio.h" >&5
3897 cebix 1.1 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3898     echo $ac_n "(cached) $ac_c" 1>&6
3899     else
3900     cat > conftest.$ac_ext <<EOF
3901 cebix 1.14 #line 3902 "configure"
3902 cebix 1.1 #include "confdefs.h"
3903     #include <scsi.h sys/scsiio.h>
3904     EOF
3905     ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3906 cebix 1.14 { (eval echo configure:3907: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3907 cebix 1.1 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3908     if test -z "$ac_err"; then
3909     rm -rf conftest*
3910     eval "ac_cv_header_$ac_safe=yes"
3911     else
3912     echo "$ac_err" >&5
3913     echo "configure: failed program was:" >&5
3914     cat conftest.$ac_ext >&5
3915     rm -rf conftest*
3916     eval "ac_cv_header_$ac_safe=no"
3917     fi
3918     rm -f conftest*
3919     fi
3920     if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3921     echo "$ac_t""yes" 1>&6
3922     :
3923     else
3924     echo "$ac_t""no" 1>&6
3925     fi
3926    
3927     if [ "x$ac_cv_header_scsi_h" = "xno" ]; then
3928     { echo "configure: error: Cannot find includes for the SCSI library." 1>&2; exit 1; }
3929     fi
3930     SYSSRCS="../dummy/ether_dummy.cpp FreeBSD/scsi_freebsd.cpp ../dummy/audio_dummy.cpp"
3931     LIBS="$LIBS -lscsi"
3932     DEFINES="$DEFINES -DBSD_COMP"
3933     fi
3934     ;;
3935     SunOS*)
3936     SYSSRCS="../dummy/ether_dummy.cpp ../dummy/scsi_dummy.cpp Solaris/audio_solaris.cpp"
3937     DEFINES="$DEFINES -DBSD_COMP -D_POSIX_PTHREAD_SEMANTICS"
3938     ;;
3939     IRIX*)
3940     SYSSRCS="../dummy/ether_dummy.cpp ../dummy/scsi_dummy.cpp ../dummy/audio_dummy.cpp Irix/unaligned.c"
3941     DEFINES="$DEFINES -DCRTSCTS=CNEW_RTSCTS -DB230400=B115200"
3942     LIBS="$LIBS -lm"
3943     ;;
3944     esac
3945 cebix 1.7 fi
3946 cebix 1.10 SYSSRCS="$SYSSRCS $SEMSRCS $UISRCS $MONSRCS"
3947 cebix 1.1
3948     HAVE_I386=no
3949     echo $ac_n "checking for x86 target CPU""... $ac_c" 1>&6
3950 cebix 1.14 echo "configure:3951: checking for x86 target CPU" >&5
3951 cebix 1.1 cat > conftest.$ac_ext <<EOF
3952 cebix 1.14 #line 3953 "configure"
3953 cebix 1.1 #include "confdefs.h"
3954    
3955     #ifdef __i386__
3956     yes
3957     #endif
3958    
3959     EOF
3960     if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3961     egrep "yes" >/dev/null 2>&1; then
3962     rm -rf conftest*
3963     echo "$ac_t""yes" 1>&6; HAVE_I386=yes
3964     else
3965     rm -rf conftest*
3966     echo "$ac_t""no" 1>&6
3967     fi
3968     rm -f conftest*
3969    
3970    
3971 cebix 1.8 HAVE_SPARC=no
3972     echo $ac_n "checking for SPARC target CPU""... $ac_c" 1>&6
3973 cebix 1.14 echo "configure:3974: checking for SPARC target CPU" >&5
3974 cebix 1.8 cat > conftest.$ac_ext <<EOF
3975 cebix 1.14 #line 3976 "configure"
3976 cebix 1.8 #include "confdefs.h"
3977    
3978     #ifdef __sparc__
3979     yes
3980     #endif
3981    
3982     EOF
3983     if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3984     egrep "yes" >/dev/null 2>&1; then
3985     rm -rf conftest*
3986     echo "$ac_t""yes" 1>&6; HAVE_SPARC=yes
3987     else
3988     rm -rf conftest*
3989     echo "$ac_t""no" 1>&6
3990     fi
3991     rm -f conftest*
3992    
3993    
3994 cebix 1.1 HAVE_GAS=no
3995     echo $ac_n "checking for GAS .p2align feature""... $ac_c" 1>&6
3996 cebix 1.14 echo "configure:3997: checking for GAS .p2align feature" >&5
3997 cebix 1.1 cat >conftest.S << EOF
3998     .text
3999     .p2align 5
4000     EOF
4001     if $CC conftest.S -c -o conftest.o >/dev/null 2>&1 ; then HAVE_GAS=yes; fi
4002     echo "$ac_t""$HAVE_GAS" 1>&6
4003    
4004     HAVE_GCC27=no
4005     echo $ac_n "checking for GCC 2.7 or higher""... $ac_c" 1>&6
4006 cebix 1.14 echo "configure:4007: checking for GCC 2.7 or higher" >&5
4007 cebix 1.1 cat > conftest.$ac_ext <<EOF
4008 cebix 1.14 #line 4009 "configure"
4009 cebix 1.1 #include "confdefs.h"
4010     #if __GNUC__ - 1 > 1 || __GNUC_MINOR__ - 1 > 5
4011     yes
4012     #endif
4013    
4014     EOF
4015     if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4016     egrep "yes" >/dev/null 2>&1; then
4017     rm -rf conftest*
4018     echo "$ac_t""yes" 1>&6; HAVE_GCC27=yes
4019     else
4020     rm -rf conftest*
4021     echo "$ac_t""no" 1>&6
4022     fi
4023     rm -f conftest*
4024    
4025    
4026     if [ "x$HAVE_GCC27" = "xyes" ]; then
4027     CFLAGS="$CFLAGS -fomit-frame-pointer"
4028     CXXFLAGS="$CXXFLAGS -fomit-frame-pointer"
4029     fi
4030    
4031 cebix 1.11 WANT_X86_ASSEMBLY=no
4032     WANT_SPARC_V8_ASSEMBLY=no
4033     WANT_SPARC_V9_ASSEMBLY=no
4034 cebix 1.8 CPUSRCS="cpuemu1.cpp cpuemu2.cpp cpuemu3.cpp cpuemu4.cpp cpuemu5.cpp cpuemu6.cpp cpuemu7.cpp cpuemu8.cpp"
4035 cebix 1.1 if [ "x$HAVE_GCC27" = "xyes" -a "x$HAVE_I386" = "xyes" ]; then
4036 cebix 1.8 DEFINES="$DEFINES -DREGPARAM=\"__attribute__((regparm(3)))\""
4037 cebix 1.1 if [ "x$HAVE_GAS" = "xyes" ]; then
4038 cebix 1.11 WANT_X86_ASSEMBLY=yes
4039 cebix 1.1 DEFINES="$DEFINES -DX86_ASSEMBLY"
4040 cebix 1.15 CPUSRCS="../uae_cpu/compiler.cpp cpufast1.s cpufast2.s cpufast3.s cpufast4.s cpufast5.s cpufast6.s cpufast7.s cpufast8.s"
4041 cebix 1.1 fi
4042 cebix 1.8 elif [ "x$HAVE_GCC27" = "xyes" -a "x$HAVE_SPARC" = "xyes" -a "x$HAVE_GAS" = "xyes" ]; then
4043     case "$MACHINE" in
4044     SunOS*)
4045     echo $ac_n "checking SPARC CPU architecture""... $ac_c" 1>&6
4046 cebix 1.14 echo "configure:4047: checking SPARC CPU architecture" >&5
4047 cebix 1.8 SPARC_TYPE=`Solaris/which_sparc`
4048     echo "$ac_t""$SPARC_TYPE" 1>&6
4049     case "$SPARC_TYPE" in
4050     SPARC_V8)
4051 cebix 1.11 WANT_SPARC_V8_ASSEMBLY=yes
4052 cebix 1.8 DEFINES="$DEFINES -DSPARC_V8_ASSEMBLY"
4053     CFLAGS="$CFLAGS -Wa,-Av8"
4054     CXXFLAGS="$CXXFLAGS -Wa,-Av8"
4055     ;;
4056     SPARC_V9)
4057 cebix 1.11 WANT_SPARC_V9_ASSEMBLY=yes
4058 cebix 1.8 DEFINES="$DEFINES -DSPARC_V9_ASSEMBLY"
4059     CFLAGS="$CFLAGS -Wa,-Av9"
4060     CXXFLAGS="$CXXFLAGS -Wa,-Av9"
4061     ;;
4062     esac
4063     ;;
4064     esac
4065 cebix 1.1 fi
4066 cebix 1.8
4067     CPUINCLUDES="-I../uae_cpu"
4068     CPUSRCS="../uae_cpu/basilisk_glue.cpp ../uae_cpu/memory.cpp ../uae_cpu/newcpu.cpp ../uae_cpu/readcpu.cpp ../uae_cpu/fpp.cpp cpustbl.cpp cpudefs.cpp $CPUSRCS"
4069 cebix 1.1
4070    
4071    
4072    
4073    
4074     trap '' 1 2 15
4075     cat > confcache <<\EOF
4076     # This file is a shell script that caches the results of configure
4077     # tests run on this system so they can be shared between configure
4078     # scripts and configure runs. It is not useful on other systems.
4079     # If it contains results you don't want to keep, you may remove or edit it.
4080     #
4081     # By default, configure uses ./config.cache as the cache file,
4082     # creating it if it does not exist already. You can give configure
4083     # the --cache-file=FILE option to use a different cache file; that is
4084     # what configure does when it calls configure scripts in
4085     # subdirectories, so they share the cache.
4086     # Giving --cache-file=/dev/null disables caching, for debugging configure.
4087     # config.status only pays attention to the cache file if you give it the
4088     # --recheck option to rerun configure.
4089     #
4090     EOF
4091     # The following way of writing the cache mishandles newlines in values,
4092     # but we know of no workaround that is simple, portable, and efficient.
4093     # So, don't put newlines in cache variables' values.
4094     # Ultrix sh set writes to stderr and can't be redirected directly,
4095     # and sets the high bit in the cache file unless we assign to the vars.
4096     (set) 2>&1 |
4097     case `(ac_space=' '; set | grep ac_space) 2>&1` in
4098     *ac_space=\ *)
4099     # `set' does not quote correctly, so add quotes (double-quote substitution
4100     # turns \\\\ into \\, and sed turns \\ into \).
4101     sed -n \
4102     -e "s/'/'\\\\''/g" \
4103     -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
4104     ;;
4105     *)
4106     # `set' quotes correctly as required by POSIX, so do not add quotes.
4107     sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
4108     ;;
4109     esac >> confcache
4110     if cmp -s $cache_file confcache; then
4111     :
4112     else
4113     if test -w $cache_file; then
4114     echo "updating cache $cache_file"
4115     cat confcache > $cache_file
4116     else
4117     echo "not updating unwritable cache $cache_file"
4118     fi
4119     fi
4120     rm -f confcache
4121    
4122     trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
4123    
4124     test "x$prefix" = xNONE && prefix=$ac_default_prefix
4125     # Let make expand exec_prefix.
4126     test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
4127    
4128     # Any assignment to VPATH causes Sun make to only execute
4129     # the first set of double-colon rules, so remove it if not needed.
4130     # If there is a colon in the path, we need to keep it.
4131     if test "x$srcdir" = x.; then
4132     ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
4133     fi
4134    
4135     trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
4136    
4137     DEFS=-DHAVE_CONFIG_H
4138    
4139     # Without the "./", some shells look in PATH for config.status.
4140     : ${CONFIG_STATUS=./config.status}
4141    
4142     echo creating $CONFIG_STATUS
4143     rm -f $CONFIG_STATUS
4144     cat > $CONFIG_STATUS <<EOF
4145     #! /bin/sh
4146     # Generated automatically by configure.
4147     # Run this file to recreate the current configuration.
4148     # This directory was configured as follows,
4149     # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
4150     #
4151     # $0 $ac_configure_args
4152     #
4153     # Compiler output produced by configure, useful for debugging
4154     # configure, is in ./config.log if it exists.
4155    
4156     ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
4157     for ac_option
4158     do
4159     case "\$ac_option" in
4160     -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
4161     echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
4162     exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
4163     -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
4164     echo "$CONFIG_STATUS generated by autoconf version 2.13"
4165     exit 0 ;;
4166     -help | --help | --hel | --he | --h)
4167     echo "\$ac_cs_usage"; exit 0 ;;
4168     *) echo "\$ac_cs_usage"; exit 1 ;;
4169     esac
4170     done
4171    
4172     ac_given_srcdir=$srcdir
4173     ac_given_INSTALL="$INSTALL"
4174    
4175     trap 'rm -fr `echo "Makefile config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
4176     EOF
4177     cat >> $CONFIG_STATUS <<EOF
4178    
4179     # Protect against being on the right side of a sed subst in config.status.
4180     sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
4181     s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
4182     $ac_vpsub
4183     $extrasub
4184     s%@SHELL@%$SHELL%g
4185     s%@CFLAGS@%$CFLAGS%g
4186     s%@CPPFLAGS@%$CPPFLAGS%g
4187     s%@CXXFLAGS@%$CXXFLAGS%g
4188     s%@FFLAGS@%$FFLAGS%g
4189     s%@DEFS@%$DEFS%g
4190     s%@LDFLAGS@%$LDFLAGS%g
4191     s%@LIBS@%$LIBS%g
4192     s%@exec_prefix@%$exec_prefix%g
4193     s%@prefix@%$prefix%g
4194     s%@program_transform_name@%$program_transform_name%g
4195     s%@bindir@%$bindir%g
4196     s%@sbindir@%$sbindir%g
4197     s%@libexecdir@%$libexecdir%g
4198     s%@datadir@%$datadir%g
4199     s%@sysconfdir@%$sysconfdir%g
4200     s%@sharedstatedir@%$sharedstatedir%g
4201     s%@localstatedir@%$localstatedir%g
4202     s%@libdir@%$libdir%g
4203     s%@includedir@%$includedir%g
4204     s%@oldincludedir@%$oldincludedir%g
4205     s%@infodir@%$infodir%g
4206     s%@mandir@%$mandir%g
4207     s%@CC@%$CC%g
4208 cebix 1.3 s%@CPP@%$CPP%g
4209 cebix 1.1 s%@CXX@%$CXX%g
4210     s%@SET_MAKE@%$SET_MAKE%g
4211     s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
4212     s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
4213     s%@INSTALL_DATA@%$INSTALL_DATA%g
4214     s%@X_CFLAGS@%$X_CFLAGS%g
4215     s%@X_PRE_LIBS@%$X_PRE_LIBS%g
4216     s%@X_LIBS@%$X_LIBS%g
4217     s%@X_EXTRA_LIBS@%$X_EXTRA_LIBS%g
4218     s%@GTK_CONFIG@%$GTK_CONFIG%g
4219     s%@GTK_CFLAGS@%$GTK_CFLAGS%g
4220     s%@GTK_LIBS@%$GTK_LIBS%g
4221 cebix 1.9 s%@ESD_CONFIG@%$ESD_CONFIG%g
4222     s%@ESD_CFLAGS@%$ESD_CFLAGS%g
4223     s%@ESD_LIBS@%$ESD_LIBS%g
4224 cebix 1.1 s%@DEFINES@%$DEFINES%g
4225     s%@SYSSRCS@%$SYSSRCS%g
4226     s%@CPUINCLUDES@%$CPUINCLUDES%g
4227     s%@CPUSRCS@%$CPUSRCS%g
4228    
4229     CEOF
4230     EOF
4231    
4232     cat >> $CONFIG_STATUS <<\EOF
4233    
4234     # Split the substitutions into bite-sized pieces for seds with
4235     # small command number limits, like on Digital OSF/1 and HP-UX.
4236     ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
4237     ac_file=1 # Number of current file.
4238     ac_beg=1 # First line for current file.
4239     ac_end=$ac_max_sed_cmds # Line after last line for current file.
4240     ac_more_lines=:
4241     ac_sed_cmds=""
4242     while $ac_more_lines; do
4243     if test $ac_beg -gt 1; then
4244     sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
4245     else
4246     sed "${ac_end}q" conftest.subs > conftest.s$ac_file
4247     fi
4248     if test ! -s conftest.s$ac_file; then
4249     ac_more_lines=false
4250     rm -f conftest.s$ac_file
4251     else
4252     if test -z "$ac_sed_cmds"; then
4253     ac_sed_cmds="sed -f conftest.s$ac_file"
4254     else
4255     ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
4256     fi
4257     ac_file=`expr $ac_file + 1`
4258     ac_beg=$ac_end
4259     ac_end=`expr $ac_end + $ac_max_sed_cmds`
4260     fi
4261     done
4262     if test -z "$ac_sed_cmds"; then
4263     ac_sed_cmds=cat
4264     fi
4265     EOF
4266    
4267     cat >> $CONFIG_STATUS <<EOF
4268    
4269     CONFIG_FILES=\${CONFIG_FILES-"Makefile"}
4270     EOF
4271     cat >> $CONFIG_STATUS <<\EOF
4272     for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
4273     # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
4274     case "$ac_file" in
4275     *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
4276     ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
4277     *) ac_file_in="${ac_file}.in" ;;
4278     esac
4279    
4280     # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
4281    
4282     # Remove last slash and all that follows it. Not all systems have dirname.
4283     ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
4284     if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
4285     # The file is in a subdirectory.
4286     test ! -d "$ac_dir" && mkdir "$ac_dir"
4287     ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
4288     # A "../" for each directory in $ac_dir_suffix.
4289     ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
4290     else
4291     ac_dir_suffix= ac_dots=
4292     fi
4293    
4294     case "$ac_given_srcdir" in
4295     .) srcdir=.
4296     if test -z "$ac_dots"; then top_srcdir=.
4297     else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
4298     /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
4299     *) # Relative path.
4300     srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
4301     top_srcdir="$ac_dots$ac_given_srcdir" ;;
4302     esac
4303    
4304     case "$ac_given_INSTALL" in
4305     [/$]*) INSTALL="$ac_given_INSTALL" ;;
4306     *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
4307     esac
4308    
4309     echo creating "$ac_file"
4310     rm -f "$ac_file"
4311     configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
4312     case "$ac_file" in
4313     *Makefile*) ac_comsub="1i\\
4314     # $configure_input" ;;
4315     *) ac_comsub= ;;
4316     esac
4317    
4318     ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
4319     sed -e "$ac_comsub
4320     s%@configure_input@%$configure_input%g
4321     s%@srcdir@%$srcdir%g
4322     s%@top_srcdir@%$top_srcdir%g
4323     s%@INSTALL@%$INSTALL%g
4324     " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
4325     fi; done
4326     rm -f conftest.s*
4327    
4328     # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
4329     # NAME is the cpp macro being defined and VALUE is the value it is being given.
4330     #
4331     # ac_d sets the value in "#define NAME VALUE" lines.
4332     ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)'
4333     ac_dB='\([ ][ ]*\)[^ ]*%\1#\2'
4334     ac_dC='\3'
4335     ac_dD='%g'
4336     # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
4337     ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
4338     ac_uB='\([ ]\)%\1#\2define\3'
4339     ac_uC=' '
4340     ac_uD='\4%g'
4341     # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
4342     ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
4343     ac_eB='$%\1#\2define\3'
4344     ac_eC=' '
4345     ac_eD='%g'
4346    
4347     if test "${CONFIG_HEADERS+set}" != set; then
4348     EOF
4349     cat >> $CONFIG_STATUS <<EOF
4350     CONFIG_HEADERS="config.h"
4351     EOF
4352     cat >> $CONFIG_STATUS <<\EOF
4353     fi
4354     for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
4355     # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
4356     case "$ac_file" in
4357     *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
4358     ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
4359     *) ac_file_in="${ac_file}.in" ;;
4360     esac
4361    
4362     echo creating $ac_file
4363    
4364     rm -f conftest.frag conftest.in conftest.out
4365     ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
4366     cat $ac_file_inputs > conftest.in
4367    
4368     EOF
4369    
4370     # Transform confdefs.h into a sed script conftest.vals that substitutes
4371     # the proper values into config.h.in to produce config.h. And first:
4372     # Protect against being on the right side of a sed subst in config.status.
4373     # Protect against being in an unquoted here document in config.status.
4374     rm -f conftest.vals
4375     cat > conftest.hdr <<\EOF
4376     s/[\\&%]/\\&/g
4377     s%[\\$`]%\\&%g
4378     s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
4379     s%ac_d%ac_u%gp
4380     s%ac_u%ac_e%gp
4381     EOF
4382     sed -n -f conftest.hdr confdefs.h > conftest.vals
4383     rm -f conftest.hdr
4384    
4385     # This sed command replaces #undef with comments. This is necessary, for
4386     # example, in the case of _POSIX_SOURCE, which is predefined and required
4387     # on some systems where configure will not decide to define it.
4388     cat >> conftest.vals <<\EOF
4389     s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
4390     EOF
4391    
4392     # Break up conftest.vals because some shells have a limit on
4393     # the size of here documents, and old seds have small limits too.
4394    
4395     rm -f conftest.tail
4396     while :
4397     do
4398     ac_lines=`grep -c . conftest.vals`
4399     # grep -c gives empty output for an empty file on some AIX systems.
4400     if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
4401     # Write a limited-size here document to conftest.frag.
4402     echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
4403     sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
4404     echo 'CEOF
4405     sed -f conftest.frag conftest.in > conftest.out
4406     rm -f conftest.in
4407     mv conftest.out conftest.in
4408     ' >> $CONFIG_STATUS
4409     sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
4410     rm -f conftest.vals
4411     mv conftest.tail conftest.vals
4412     done
4413     rm -f conftest.vals
4414    
4415     cat >> $CONFIG_STATUS <<\EOF
4416     rm -f conftest.frag conftest.h
4417     echo "/* $ac_file. Generated automatically by configure. */" > conftest.h
4418     cat conftest.in >> conftest.h
4419     rm -f conftest.in
4420     if cmp -s $ac_file conftest.h 2>/dev/null; then
4421     echo "$ac_file is unchanged"
4422     rm -f conftest.h
4423     else
4424     # Remove last slash and all that follows it. Not all systems have dirname.
4425     ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
4426     if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
4427     # The file is in a subdirectory.
4428     test ! -d "$ac_dir" && mkdir "$ac_dir"
4429     fi
4430     rm -f $ac_file
4431     mv conftest.h $ac_file
4432     fi
4433     fi; done
4434    
4435     EOF
4436     cat >> $CONFIG_STATUS <<EOF
4437    
4438     EOF
4439     cat >> $CONFIG_STATUS <<\EOF
4440    
4441     exit 0
4442     EOF
4443     chmod +x $CONFIG_STATUS
4444     rm -fr confdefs* $ac_clean_files
4445     test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
4446    
4447 cebix 1.11
4448     echo
4449     echo Basilisk II configuration summary:
4450     echo
4451     echo XFree86 DGA support .............. : $WANT_XF86_DGA
4452     echo fbdev DGA support ................ : $WANT_FBDEV_DGA
4453     echo ESD sound support ................ : $WANT_ESD
4454 cebix 1.13 echo GTK user interface ............... : $WANT_GTK
4455 cebix 1.11 echo mon debugger support ............. : $WANT_MON
4456     echo i386 assembly optimizations ...... : $WANT_X86_ASSEMBLY
4457     echo SPARC V8 assembly optimizations .. : $WANT_SPARC_V8_ASSEMBLY
4458     echo SPARC V9 assembly optimizations .. : $WANT_SPARC_V9_ASSEMBLY
4459     echo
4460 cebix 1.1 echo "Configuration done. Now type \"make\"."