updated version, but need to update installation scripts
[cls.git] / configure
blob9c71c882cd0c48a58652b963ec29ee6779670a07
1 #! /bin/sh
3 # Guess values for system-dependent variables and create Makefiles.
4 # Generated automatically using autoconf version 2.13
5 # Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
7 # This configure script is free software; the Free Software Foundation
8 # gives unlimited permission to copy, distribute and modify it.
10 # Defaults:
11 ac_help=
12 ac_default_prefix=/usr/local
13 # Any additions from configure.in:
14 ac_help="$ac_help
15 --with-gcc use gcc compiler"
16 ac_help="$ac_help
17 --with-x use the X Window System"
19 # Initialize some variables set by options.
20 # The variables have the same names as the options, with
21 # dashes changed to underlines.
22 build=NONE
23 cache_file=./config.cache
24 exec_prefix=NONE
25 host=NONE
26 no_create=
27 nonopt=NONE
28 no_recursion=
29 prefix=NONE
30 program_prefix=NONE
31 program_suffix=NONE
32 program_transform_name=s,x,x,
33 silent=
34 site=
35 srcdir=
36 target=NONE
37 verbose=
38 x_includes=NONE
39 x_libraries=NONE
40 bindir='${exec_prefix}/bin'
41 sbindir='${exec_prefix}/sbin'
42 libexecdir='${exec_prefix}/libexec'
43 datadir='${prefix}/share'
44 sysconfdir='${prefix}/etc'
45 sharedstatedir='${prefix}/com'
46 localstatedir='${prefix}/var'
47 libdir='${exec_prefix}/lib'
48 includedir='${prefix}/include'
49 oldincludedir='/usr/include'
50 infodir='${prefix}/info'
51 mandir='${prefix}/man'
53 # Initialize some other variables.
54 subdirs=
55 MFLAGS= MAKEFLAGS=
56 SHELL=${CONFIG_SHELL-/bin/sh}
57 # Maximum number of lines to put in a shell here document.
58 ac_max_here_lines=12
60 ac_prev=
61 for ac_option
64 # If the previous option needs an argument, assign it.
65 if test -n "$ac_prev"; then
66 eval "$ac_prev=\$ac_option"
67 ac_prev=
68 continue
71 case "$ac_option" in
72 -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
73 *) ac_optarg= ;;
74 esac
76 # Accept the important Cygnus configure options, so we can diagnose typos.
78 case "$ac_option" in
80 -bindir | --bindir | --bindi | --bind | --bin | --bi)
81 ac_prev=bindir ;;
82 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
83 bindir="$ac_optarg" ;;
85 -build | --build | --buil | --bui | --bu)
86 ac_prev=build ;;
87 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
88 build="$ac_optarg" ;;
90 -cache-file | --cache-file | --cache-fil | --cache-fi \
91 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
92 ac_prev=cache_file ;;
93 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
94 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
95 cache_file="$ac_optarg" ;;
97 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
98 ac_prev=datadir ;;
99 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
100 | --da=*)
101 datadir="$ac_optarg" ;;
103 -disable-* | --disable-*)
104 ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
105 # Reject names that are not valid shell variable names.
106 if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
107 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
109 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
110 eval "enable_${ac_feature}=no" ;;
112 -enable-* | --enable-*)
113 ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
114 # Reject names that are not valid shell variable names.
115 if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
116 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
118 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
119 case "$ac_option" in
120 *=*) ;;
121 *) ac_optarg=yes ;;
122 esac
123 eval "enable_${ac_feature}='$ac_optarg'" ;;
125 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
126 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
127 | --exec | --exe | --ex)
128 ac_prev=exec_prefix ;;
129 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
130 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
131 | --exec=* | --exe=* | --ex=*)
132 exec_prefix="$ac_optarg" ;;
134 -gas | --gas | --ga | --g)
135 # Obsolete; use --with-gas.
136 with_gas=yes ;;
138 -help | --help | --hel | --he)
139 # Omit some internal or obsolete options to make the list less imposing.
140 # This message is too long to be a string in the A/UX 3.1 sh.
141 cat << EOF
142 Usage: configure [options] [host]
143 Options: [defaults in brackets after descriptions]
144 Configuration:
145 --cache-file=FILE cache test results in FILE
146 --help print this message
147 --no-create do not create output files
148 --quiet, --silent do not print \`checking...' messages
149 --version print the version of autoconf that created configure
150 Directory and file names:
151 --prefix=PREFIX install architecture-independent files in PREFIX
152 [$ac_default_prefix]
153 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
154 [same as prefix]
155 --bindir=DIR user executables in DIR [EPREFIX/bin]
156 --sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
157 --libexecdir=DIR program executables in DIR [EPREFIX/libexec]
158 --datadir=DIR read-only architecture-independent data in DIR
159 [PREFIX/share]
160 --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
161 --sharedstatedir=DIR modifiable architecture-independent data in DIR
162 [PREFIX/com]
163 --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
164 --libdir=DIR object code libraries in DIR [EPREFIX/lib]
165 --includedir=DIR C header files in DIR [PREFIX/include]
166 --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
167 --infodir=DIR info documentation in DIR [PREFIX/info]
168 --mandir=DIR man documentation in DIR [PREFIX/man]
169 --srcdir=DIR find the sources in DIR [configure dir or ..]
170 --program-prefix=PREFIX prepend PREFIX to installed program names
171 --program-suffix=SUFFIX append SUFFIX to installed program names
172 --program-transform-name=PROGRAM
173 run sed PROGRAM on installed program names
175 cat << EOF
176 Host type:
177 --build=BUILD configure for building on BUILD [BUILD=HOST]
178 --host=HOST configure for HOST [guessed]
179 --target=TARGET configure for TARGET [TARGET=HOST]
180 Features and packages:
181 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
182 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
183 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
184 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
185 --x-includes=DIR X include files are in DIR
186 --x-libraries=DIR X library files are in DIR
188 if test -n "$ac_help"; then
189 echo "--enable and --with options recognized:$ac_help"
191 exit 0 ;;
193 -host | --host | --hos | --ho)
194 ac_prev=host ;;
195 -host=* | --host=* | --hos=* | --ho=*)
196 host="$ac_optarg" ;;
198 -includedir | --includedir | --includedi | --included | --include \
199 | --includ | --inclu | --incl | --inc)
200 ac_prev=includedir ;;
201 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
202 | --includ=* | --inclu=* | --incl=* | --inc=*)
203 includedir="$ac_optarg" ;;
205 -infodir | --infodir | --infodi | --infod | --info | --inf)
206 ac_prev=infodir ;;
207 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
208 infodir="$ac_optarg" ;;
210 -libdir | --libdir | --libdi | --libd)
211 ac_prev=libdir ;;
212 -libdir=* | --libdir=* | --libdi=* | --libd=*)
213 libdir="$ac_optarg" ;;
215 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
216 | --libexe | --libex | --libe)
217 ac_prev=libexecdir ;;
218 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
219 | --libexe=* | --libex=* | --libe=*)
220 libexecdir="$ac_optarg" ;;
222 -localstatedir | --localstatedir | --localstatedi | --localstated \
223 | --localstate | --localstat | --localsta | --localst \
224 | --locals | --local | --loca | --loc | --lo)
225 ac_prev=localstatedir ;;
226 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
227 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
228 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
229 localstatedir="$ac_optarg" ;;
231 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
232 ac_prev=mandir ;;
233 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
234 mandir="$ac_optarg" ;;
236 -nfp | --nfp | --nf)
237 # Obsolete; use --without-fp.
238 with_fp=no ;;
240 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
241 | --no-cr | --no-c)
242 no_create=yes ;;
244 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
245 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
246 no_recursion=yes ;;
248 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
249 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
250 | --oldin | --oldi | --old | --ol | --o)
251 ac_prev=oldincludedir ;;
252 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
253 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
254 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
255 oldincludedir="$ac_optarg" ;;
257 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
258 ac_prev=prefix ;;
259 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
260 prefix="$ac_optarg" ;;
262 -program-prefix | --program-prefix | --program-prefi | --program-pref \
263 | --program-pre | --program-pr | --program-p)
264 ac_prev=program_prefix ;;
265 -program-prefix=* | --program-prefix=* | --program-prefi=* \
266 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
267 program_prefix="$ac_optarg" ;;
269 -program-suffix | --program-suffix | --program-suffi | --program-suff \
270 | --program-suf | --program-su | --program-s)
271 ac_prev=program_suffix ;;
272 -program-suffix=* | --program-suffix=* | --program-suffi=* \
273 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
274 program_suffix="$ac_optarg" ;;
276 -program-transform-name | --program-transform-name \
277 | --program-transform-nam | --program-transform-na \
278 | --program-transform-n | --program-transform- \
279 | --program-transform | --program-transfor \
280 | --program-transfo | --program-transf \
281 | --program-trans | --program-tran \
282 | --progr-tra | --program-tr | --program-t)
283 ac_prev=program_transform_name ;;
284 -program-transform-name=* | --program-transform-name=* \
285 | --program-transform-nam=* | --program-transform-na=* \
286 | --program-transform-n=* | --program-transform-=* \
287 | --program-transform=* | --program-transfor=* \
288 | --program-transfo=* | --program-transf=* \
289 | --program-trans=* | --program-tran=* \
290 | --progr-tra=* | --program-tr=* | --program-t=*)
291 program_transform_name="$ac_optarg" ;;
293 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
294 | -silent | --silent | --silen | --sile | --sil)
295 silent=yes ;;
297 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
298 ac_prev=sbindir ;;
299 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
300 | --sbi=* | --sb=*)
301 sbindir="$ac_optarg" ;;
303 -sharedstatedir | --sharedstatedir | --sharedstatedi \
304 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
305 | --sharedst | --shareds | --shared | --share | --shar \
306 | --sha | --sh)
307 ac_prev=sharedstatedir ;;
308 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
309 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
310 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
311 | --sha=* | --sh=*)
312 sharedstatedir="$ac_optarg" ;;
314 -site | --site | --sit)
315 ac_prev=site ;;
316 -site=* | --site=* | --sit=*)
317 site="$ac_optarg" ;;
319 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
320 ac_prev=srcdir ;;
321 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
322 srcdir="$ac_optarg" ;;
324 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
325 | --syscon | --sysco | --sysc | --sys | --sy)
326 ac_prev=sysconfdir ;;
327 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
328 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
329 sysconfdir="$ac_optarg" ;;
331 -target | --target | --targe | --targ | --tar | --ta | --t)
332 ac_prev=target ;;
333 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
334 target="$ac_optarg" ;;
336 -v | -verbose | --verbose | --verbos | --verbo | --verb)
337 verbose=yes ;;
339 -version | --version | --versio | --versi | --vers)
340 echo "configure generated by autoconf version 2.13"
341 exit 0 ;;
343 -with-* | --with-*)
344 ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
345 # Reject names that are not valid shell variable names.
346 if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
347 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
349 ac_package=`echo $ac_package| sed 's/-/_/g'`
350 case "$ac_option" in
351 *=*) ;;
352 *) ac_optarg=yes ;;
353 esac
354 eval "with_${ac_package}='$ac_optarg'" ;;
356 -without-* | --without-*)
357 ac_package=`echo $ac_option|sed -e 's/-*without-//'`
358 # Reject names that are not valid shell variable names.
359 if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
360 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
362 ac_package=`echo $ac_package| sed 's/-/_/g'`
363 eval "with_${ac_package}=no" ;;
365 --x)
366 # Obsolete; use --with-x.
367 with_x=yes ;;
369 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
370 | --x-incl | --x-inc | --x-in | --x-i)
371 ac_prev=x_includes ;;
372 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
373 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
374 x_includes="$ac_optarg" ;;
376 -x-libraries | --x-libraries | --x-librarie | --x-librari \
377 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
378 ac_prev=x_libraries ;;
379 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
380 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
381 x_libraries="$ac_optarg" ;;
383 -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
387 if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
388 echo "configure: warning: $ac_option: invalid host type" 1>&2
390 if test "x$nonopt" != xNONE; then
391 { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
393 nonopt="$ac_option"
396 esac
397 done
399 if test -n "$ac_prev"; then
400 { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
403 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
405 # File descriptor usage:
406 # 0 standard input
407 # 1 file creation
408 # 2 errors and warnings
409 # 3 some systems may open it to /dev/tty
410 # 4 used on the Kubota Titan
411 # 6 checking for... messages and results
412 # 5 compiler messages saved in config.log
413 if test "$silent" = yes; then
414 exec 6>/dev/null
415 else
416 exec 6>&1
418 exec 5>./config.log
420 echo "\
421 This file contains any messages produced by compilers while
422 running configure, to aid debugging if configure makes a mistake.
423 " 1>&5
425 # Strip out --no-create and --no-recursion so they do not pile up.
426 # Also quote any args containing shell metacharacters.
427 ac_configure_args=
428 for ac_arg
430 case "$ac_arg" in
431 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
432 | --no-cr | --no-c) ;;
433 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
434 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
435 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
436 ac_configure_args="$ac_configure_args '$ac_arg'" ;;
437 *) ac_configure_args="$ac_configure_args $ac_arg" ;;
438 esac
439 done
441 # NLS nuisances.
442 # Only set these to C if already set. These must not be set unconditionally
443 # because not all systems understand e.g. LANG=C (notably SCO).
444 # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
445 # Non-C LC_CTYPE values break the ctype check.
446 if test "${LANG+set}" = set; then LANG=C; export LANG; fi
447 if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
448 if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
449 if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi
451 # confdefs.h avoids OS command line length limits that DEFS can exceed.
452 rm -rf conftest* confdefs.h
453 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
454 echo > confdefs.h
456 # A filename unique to this package, relative to the directory that
457 # configure is in, which we can look for to find out if srcdir is correct.
458 ac_unique_file=Makefile.in
460 # Find the source files, if location was not specified.
461 if test -z "$srcdir"; then
462 ac_srcdir_defaulted=yes
463 # Try the directory containing this script, then its parent.
464 ac_prog=$0
465 ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
466 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
467 srcdir=$ac_confdir
468 if test ! -r $srcdir/$ac_unique_file; then
469 srcdir=..
471 else
472 ac_srcdir_defaulted=no
474 if test ! -r $srcdir/$ac_unique_file; then
475 if test "$ac_srcdir_defaulted" = yes; then
476 { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
477 else
478 { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
481 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
483 # Prefer explicitly selected file to automatically selected ones.
484 if test -z "$CONFIG_SITE"; then
485 if test "x$prefix" != xNONE; then
486 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
487 else
488 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
491 for ac_site_file in $CONFIG_SITE; do
492 if test -r "$ac_site_file"; then
493 echo "loading site script $ac_site_file"
494 . "$ac_site_file"
496 done
498 if test -r "$cache_file"; then
499 echo "loading cache $cache_file"
500 . $cache_file
501 else
502 echo "creating cache $cache_file"
503 > $cache_file
506 ac_ext=c
507 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
508 ac_cpp='$CPP $CPPFLAGS'
509 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
510 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
511 cross_compiling=$ac_cv_prog_cc_cross
513 ac_exeext=
514 ac_objext=o
515 if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
516 # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
517 if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
518 ac_n= ac_c='
519 ' ac_t=' '
520 else
521 ac_n=-n ac_c= ac_t=
523 else
524 ac_n= ac_c='\c' ac_t=
529 ac_aux_dir=
530 for ac_dir in config $srcdir/config; do
531 if test -f $ac_dir/install-sh; then
532 ac_aux_dir=$ac_dir
533 ac_install_sh="$ac_aux_dir/install-sh -c"
534 break
535 elif test -f $ac_dir/install.sh; then
536 ac_aux_dir=$ac_dir
537 ac_install_sh="$ac_aux_dir/install.sh -c"
538 break
540 done
541 if test -z "$ac_aux_dir"; then
542 { echo "configure: error: can not find install-sh or install.sh in config $srcdir/config" 1>&2; exit 1; }
544 ac_config_guess=$ac_aux_dir/config.guess
545 ac_config_sub=$ac_aux_dir/config.sub
546 ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
551 # Determine host information
554 # Make sure we can run config.sub.
555 if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
556 else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
559 echo $ac_n "checking host system type""... $ac_c" 1>&6
560 echo "configure:561: checking host system type" >&5
562 host_alias=$host
563 case "$host_alias" in
564 NONE)
565 case $nonopt in
566 NONE)
567 if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
568 else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
569 fi ;;
570 *) host_alias=$nonopt ;;
571 esac ;;
572 esac
574 host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
575 host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
576 host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
577 host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
578 echo "$ac_t""$host" 1>&6
583 # Set some default values
585 LIBS=-lm
586 UCFLAGS=-O
587 ULDFLAGS=
588 X11INCDIR_FLAG=
589 X11LIBDIR_FLAG=
590 EXTRALIBS=
591 EXTRAOBJS=
592 FOREIGN_FILE=dummy-foreign.h
596 # Determine the C compiler to use and adjust its flags
599 # Use gcc only if specified using --with-gcc or CC environment variable
600 # Check whether --with-gcc or --without-gcc was given.
601 if test "${with_gcc+set}" = set; then
602 withval="$with_gcc"
603 CC=gcc
604 else
605 if test -z "$CC"; then CC=cc; fi
609 # Set a variable using_gcc to make checking for gcc easy below
610 if test `$CC -v 2>&1 | grep -c gcc` != "0" ; then using_gcc=1; fi
612 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
613 echo "configure:614: checking how to run the C preprocessor" >&5
614 # On Suns, sometimes $CPP names a directory.
615 if test -n "$CPP" && test -d "$CPP"; then
616 CPP=
618 if test -z "$CPP"; then
619 if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
620 echo $ac_n "(cached) $ac_c" 1>&6
621 else
622 # This must be in double quotes, not single quotes, because CPP may get
623 # substituted into the Makefile and "${CC-cc}" will confuse make.
624 CPP="${CC-cc} -E"
625 # On the NeXT, cc -E runs the code through the compiler's parser,
626 # not just through cpp.
627 cat > conftest.$ac_ext <<EOF
628 #line 629 "configure"
629 #include "confdefs.h"
630 #include <assert.h>
631 Syntax Error
633 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
634 { (eval echo configure:635: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
635 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
636 if test -z "$ac_err"; then
638 else
639 echo "$ac_err" >&5
640 echo "configure: failed program was:" >&5
641 cat conftest.$ac_ext >&5
642 rm -rf conftest*
643 CPP="${CC-cc} -E -traditional-cpp"
644 cat > conftest.$ac_ext <<EOF
645 #line 646 "configure"
646 #include "confdefs.h"
647 #include <assert.h>
648 Syntax Error
650 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
651 { (eval echo configure:652: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
652 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
653 if test -z "$ac_err"; then
655 else
656 echo "$ac_err" >&5
657 echo "configure: failed program was:" >&5
658 cat conftest.$ac_ext >&5
659 rm -rf conftest*
660 CPP="${CC-cc} -nologo -E"
661 cat > conftest.$ac_ext <<EOF
662 #line 663 "configure"
663 #include "confdefs.h"
664 #include <assert.h>
665 Syntax Error
667 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
668 { (eval echo configure:669: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
669 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
670 if test -z "$ac_err"; then
672 else
673 echo "$ac_err" >&5
674 echo "configure: failed program was:" >&5
675 cat conftest.$ac_ext >&5
676 rm -rf conftest*
677 CPP=/lib/cpp
679 rm -f conftest*
681 rm -f conftest*
683 rm -f conftest*
684 ac_cv_prog_CPP="$CPP"
686 CPP="$ac_cv_prog_CPP"
687 else
688 ac_cv_prog_CPP="$CPP"
690 echo "$ac_t""$CPP" 1>&6
693 if test "$using_gcc"; then
694 # Adjust gcc flags
695 case $host in
696 *linux*)
697 # This may be needed on other systems using gnu ld
698 ULDFLAGS="$ULDFLAGS -export-dynamic"
700 esac
701 case $host in
702 i?86-*)
703 # Enable IEEE floating point comparisons.
704 UCFLAGS="$UCFLAGS -mieee-fp"
706 alpha*)
707 # This needs to be checked out. Something is needed to get
708 # divide by zero to produce a NaN instead of a SIGFPE.
709 UCFLAGS="$UCFLAGS -mieee"
711 esac
712 else
713 # Adjust native cc flags
714 case $host in
715 *aix*)
716 # This needs to be checked out.
717 UCFLAGS="$UCFLAGS -qmaxmem=3000 -qlanglvl=ansi"
719 alpha-dec-osf*)
720 # This needs to be checked out.
721 UCFLAGS="$UCFLAGS -std -ieee_with_no_inexact -Olimit 2000"
723 *unicos*)
724 # This needs to be checked out.
725 UCFLAGS="$UCFLAGS -h tolerant -DCRAYCC"
727 *hpux*)
728 # Turn -Aa and -D_HPUX_SOURCE turn on ANSI compliance and some
729 # POSIX stuff. Drop limit on optimization to make sure byte code
730 # loop is optimized.
731 UCFLAGS="$UCFLAGS -Aa -D_HPUX_SOURCE +Onolimit"
733 mips-sgi-irix*)
734 # IRIX 6.4's cc uses -OPT:Olimit=n instead of -Olimit n. My
735 # guess is that it changed with 6.0, but I don't know for sure.
736 set `echo "$host_os" | sed 's/irix//' | tr '.' ' '`
737 os_major=$1
738 if test "$os_major" -ge 6; then
739 UCFLAGS="$UCFLAGS -OPT:Olimit=2000"
740 else
741 UCFLAGS="$UCFLAGS -Olimit 2000"
744 mips*)
745 # Most compilers for the mips architecture use this flag to
746 # increase the optimization limit; this is needed for
747 # xlbcode.c:bcloop
748 UCFLAGS="$UCFLAGS -Olimit 2000"
750 esac
755 # Adjust libraries
757 case $host in
758 alpha-dec-osf*)
759 # This needs to be checked out.
760 EXTRALIBS="$EXTRALIBS -ldnet_stub"
762 *hpux9*|*hpux10*)
763 # Need this to bring in finite. Don't know if this is needed in hpux8.
764 # It isn't needed in hpux10.2 but may be in earlier hpux10's. Don't
765 # know about hpux11.
766 if test "$using_gcc"; then
767 LIBS="-L/lib/pa1.1 $LIBS"
768 EXTRALIBS="-L/lib/pa1.1 $EXTRALIBS"
771 *linux*)
772 # Older Linux versions produce a SIGFPE on divide by zero unless
773 # ieee library is used.
774 echo $ac_n "checking for main in -lieee""... $ac_c" 1>&6
775 echo "configure:776: checking for main in -lieee" >&5
776 ac_lib_var=`echo ieee'_'main | sed 'y%./+-%__p_%'`
777 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
778 echo $ac_n "(cached) $ac_c" 1>&6
779 else
780 ac_save_LIBS="$LIBS"
781 LIBS="-lieee $LIBS"
782 cat > conftest.$ac_ext <<EOF
783 #line 784 "configure"
784 #include "confdefs.h"
786 int main() {
787 main()
788 ; return 0; }
790 if { (eval echo configure:791: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
791 rm -rf conftest*
792 eval "ac_cv_lib_$ac_lib_var=yes"
793 else
794 echo "configure: failed program was:" >&5
795 cat conftest.$ac_ext >&5
796 rm -rf conftest*
797 eval "ac_cv_lib_$ac_lib_var=no"
799 rm -f conftest*
800 LIBS="$ac_save_LIBS"
803 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
804 echo "$ac_t""yes" 1>&6
805 EXTRALIBS="$EXTRALIBS -lieee"
806 else
807 echo "$ac_t""no" 1>&6
811 *sun-solaris*)
812 # Recent Solaris versions seem to have moved socket functions out
813 # into the socket library
814 echo $ac_n "checking for socket""... $ac_c" 1>&6
815 echo "configure:816: checking for socket" >&5
816 if eval "test \"`echo '$''{'ac_cv_func_socket'+set}'`\" = set"; then
817 echo $ac_n "(cached) $ac_c" 1>&6
818 else
819 cat > conftest.$ac_ext <<EOF
820 #line 821 "configure"
821 #include "confdefs.h"
822 /* System header to define __stub macros and hopefully few prototypes,
823 which can conflict with char socket(); below. */
824 #include <assert.h>
825 /* Override any gcc2 internal prototype to avoid an error. */
826 /* We use char because int might match the return type of a gcc2
827 builtin and then its argument prototype would still apply. */
828 char socket();
830 int main() {
832 /* The GNU C library defines this for functions which it implements
833 to always fail with ENOSYS. Some functions are actually named
834 something starting with __ and the normal name is an alias. */
835 #if defined (__stub_socket) || defined (__stub___socket)
836 choke me
837 #else
838 socket();
839 #endif
841 ; return 0; }
843 if { (eval echo configure:844: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
844 rm -rf conftest*
845 eval "ac_cv_func_socket=yes"
846 else
847 echo "configure: failed program was:" >&5
848 cat conftest.$ac_ext >&5
849 rm -rf conftest*
850 eval "ac_cv_func_socket=no"
852 rm -f conftest*
855 if eval "test \"`echo '$ac_cv_func_'socket`\" = yes"; then
856 echo "$ac_t""yes" 1>&6
858 else
859 echo "$ac_t""no" 1>&6
860 echo $ac_n "checking for socket in -lsocket""... $ac_c" 1>&6
861 echo "configure:862: checking for socket in -lsocket" >&5
862 ac_lib_var=`echo socket'_'socket | sed 'y%./+-%__p_%'`
863 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
864 echo $ac_n "(cached) $ac_c" 1>&6
865 else
866 ac_save_LIBS="$LIBS"
867 LIBS="-lsocket $LIBS"
868 cat > conftest.$ac_ext <<EOF
869 #line 870 "configure"
870 #include "confdefs.h"
871 /* Override any gcc2 internal prototype to avoid an error. */
872 /* We use char because int might match the return type of a gcc2
873 builtin and then its argument prototype would still apply. */
874 char socket();
876 int main() {
877 socket()
878 ; return 0; }
880 if { (eval echo configure:881: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
881 rm -rf conftest*
882 eval "ac_cv_lib_$ac_lib_var=yes"
883 else
884 echo "configure: failed program was:" >&5
885 cat conftest.$ac_ext >&5
886 rm -rf conftest*
887 eval "ac_cv_lib_$ac_lib_var=no"
889 rm -f conftest*
890 LIBS="$ac_save_LIBS"
893 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
894 echo "$ac_t""yes" 1>&6
895 EXTRALIBS="$EXTRALIBS -lsocket"
896 else
897 echo "$ac_t""no" 1>&6
898 { echo "configure: error: can't find socket functions" 1>&2; exit 1; }
904 esac
908 # Check for IEEE math support
910 case $host in
911 *sun-solaris*)
912 # Bring in finite and isnan on newer versions of solaris
913 CFLAGS="$CFLAGS -D__EXTENSIONS__"
914 UCFLAGS="$UCFLAGS -D__EXTENSIONS__"
916 esac
917 for ac_func in finite isnan
919 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
920 echo "configure:921: checking for $ac_func" >&5
921 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
922 echo $ac_n "(cached) $ac_c" 1>&6
923 else
924 cat > conftest.$ac_ext <<EOF
925 #line 926 "configure"
926 #include "confdefs.h"
927 /* System header to define __stub macros and hopefully few prototypes,
928 which can conflict with char $ac_func(); below. */
929 #include <assert.h>
930 /* Override any gcc2 internal prototype to avoid an error. */
931 /* We use char because int might match the return type of a gcc2
932 builtin and then its argument prototype would still apply. */
933 char $ac_func();
935 int main() {
937 /* The GNU C library defines this for functions which it implements
938 to always fail with ENOSYS. Some functions are actually named
939 something starting with __ and the normal name is an alias. */
940 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
941 choke me
942 #else
943 $ac_func();
944 #endif
946 ; return 0; }
948 if { (eval echo configure:949: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
949 rm -rf conftest*
950 eval "ac_cv_func_$ac_func=yes"
951 else
952 echo "configure: failed program was:" >&5
953 cat conftest.$ac_ext >&5
954 rm -rf conftest*
955 eval "ac_cv_func_$ac_func=no"
957 rm -f conftest*
960 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
961 echo "$ac_t""yes" 1>&6
962 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
963 cat >> confdefs.h <<EOF
964 #define $ac_tr_func 1
967 else
968 echo "$ac_t""no" 1>&6
970 done
975 # Check for some other functions
977 for ac_func in memmove difftime matherr
979 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
980 echo "configure:981: checking for $ac_func" >&5
981 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
982 echo $ac_n "(cached) $ac_c" 1>&6
983 else
984 cat > conftest.$ac_ext <<EOF
985 #line 986 "configure"
986 #include "confdefs.h"
987 /* System header to define __stub macros and hopefully few prototypes,
988 which can conflict with char $ac_func(); below. */
989 #include <assert.h>
990 /* Override any gcc2 internal prototype to avoid an error. */
991 /* We use char because int might match the return type of a gcc2
992 builtin and then its argument prototype would still apply. */
993 char $ac_func();
995 int main() {
997 /* The GNU C library defines this for functions which it implements
998 to always fail with ENOSYS. Some functions are actually named
999 something starting with __ and the normal name is an alias. */
1000 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
1001 choke me
1002 #else
1003 $ac_func();
1004 #endif
1006 ; return 0; }
1008 if { (eval echo configure:1009: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1009 rm -rf conftest*
1010 eval "ac_cv_func_$ac_func=yes"
1011 else
1012 echo "configure: failed program was:" >&5
1013 cat conftest.$ac_ext >&5
1014 rm -rf conftest*
1015 eval "ac_cv_func_$ac_func=no"
1017 rm -f conftest*
1020 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
1021 echo "$ac_t""yes" 1>&6
1022 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
1023 cat >> confdefs.h <<EOF
1024 #define $ac_tr_func 1
1027 else
1028 echo "$ac_t""no" 1>&6
1030 done
1035 # Check for POSIX sigsetjmp and friends.
1036 # Use grep for sigjmp_buf since sigsetjmp/siglongjmp may be macros.
1038 cat > conftest.$ac_ext <<EOF
1039 #line 1040 "configure"
1040 #include "confdefs.h"
1041 #include <setjmp.h>
1043 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1044 egrep "sigjmp_buf" >/dev/null 2>&1; then
1045 rm -rf conftest*
1046 cat >> confdefs.h <<\EOF
1047 #define HAVE_SIGSETJMP 1
1051 rm -f conftest*
1056 # Determine the graphics system to use
1058 # If we find X, set shell vars x_includes and x_libraries to the
1059 # paths, otherwise set no_x=yes.
1060 # Uses ac_ vars as temps to allow command line to override cache and checks.
1061 # --without-x overrides everything else, but does not touch the cache.
1062 echo $ac_n "checking for X""... $ac_c" 1>&6
1063 echo "configure:1064: checking for X" >&5
1065 # Check whether --with-x or --without-x was given.
1066 if test "${with_x+set}" = set; then
1067 withval="$with_x"
1071 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
1072 if test "x$with_x" = xno; then
1073 # The user explicitly disabled X.
1074 have_x=disabled
1075 else
1076 if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
1077 # Both variables are already set.
1078 have_x=yes
1079 else
1080 if eval "test \"`echo '$''{'ac_cv_have_x'+set}'`\" = set"; then
1081 echo $ac_n "(cached) $ac_c" 1>&6
1082 else
1083 # One or both of the vars are not set, and there is no cached value.
1084 ac_x_includes=NO ac_x_libraries=NO
1085 rm -fr conftestdir
1086 if mkdir conftestdir; then
1087 cd conftestdir
1088 # Make sure to not put "make" in the Imakefile rules, since we grep it out.
1089 cat > Imakefile <<'EOF'
1090 acfindx:
1091 @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
1093 if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
1094 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1095 eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
1096 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
1097 for ac_extension in a so sl; do
1098 if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
1099 test -f $ac_im_libdir/libX11.$ac_extension; then
1100 ac_im_usrlibdir=$ac_im_libdir; break
1102 done
1103 # Screen out bogus values from the imake configuration. They are
1104 # bogus both because they are the default anyway, and because
1105 # using them would break gcc on systems where it needs fixed includes.
1106 case "$ac_im_incroot" in
1107 /usr/include) ;;
1108 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes="$ac_im_incroot" ;;
1109 esac
1110 case "$ac_im_usrlibdir" in
1111 /usr/lib | /lib) ;;
1112 *) test -d "$ac_im_usrlibdir" && ac_x_libraries="$ac_im_usrlibdir" ;;
1113 esac
1115 cd ..
1116 rm -fr conftestdir
1119 if test "$ac_x_includes" = NO; then
1120 # Guess where to find include files, by looking for this one X11 .h file.
1121 test -z "$x_direct_test_include" && x_direct_test_include=X11/Intrinsic.h
1123 # First, try using that file with no special directory specified.
1124 cat > conftest.$ac_ext <<EOF
1125 #line 1126 "configure"
1126 #include "confdefs.h"
1127 #include <$x_direct_test_include>
1129 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1130 { (eval echo configure:1131: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1131 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1132 if test -z "$ac_err"; then
1133 rm -rf conftest*
1134 # We can compile using X headers with no special include directory.
1135 ac_x_includes=
1136 else
1137 echo "$ac_err" >&5
1138 echo "configure: failed program was:" >&5
1139 cat conftest.$ac_ext >&5
1140 rm -rf conftest*
1141 # Look for the header file in a standard set of common directories.
1142 # Check X11 before X11Rn because it is often a symlink to the current release.
1143 for ac_dir in \
1144 /usr/X11/include \
1145 /usr/X11R6/include \
1146 /usr/X11R5/include \
1147 /usr/X11R4/include \
1149 /usr/include/X11 \
1150 /usr/include/X11R6 \
1151 /usr/include/X11R5 \
1152 /usr/include/X11R4 \
1154 /usr/local/X11/include \
1155 /usr/local/X11R6/include \
1156 /usr/local/X11R5/include \
1157 /usr/local/X11R4/include \
1159 /usr/local/include/X11 \
1160 /usr/local/include/X11R6 \
1161 /usr/local/include/X11R5 \
1162 /usr/local/include/X11R4 \
1164 /usr/X386/include \
1165 /usr/x386/include \
1166 /usr/XFree86/include/X11 \
1168 /usr/include \
1169 /usr/local/include \
1170 /usr/unsupported/include \
1171 /usr/athena/include \
1172 /usr/local/x11r5/include \
1173 /usr/lpp/Xamples/include \
1175 /usr/openwin/include \
1176 /usr/openwin/share/include \
1179 if test -r "$ac_dir/$x_direct_test_include"; then
1180 ac_x_includes=$ac_dir
1181 break
1183 done
1185 rm -f conftest*
1186 fi # $ac_x_includes = NO
1188 if test "$ac_x_libraries" = NO; then
1189 # Check for the libraries.
1191 test -z "$x_direct_test_library" && x_direct_test_library=Xt
1192 test -z "$x_direct_test_function" && x_direct_test_function=XtMalloc
1194 # See if we find them without any special options.
1195 # Don't add to $LIBS permanently.
1196 ac_save_LIBS="$LIBS"
1197 LIBS="-l$x_direct_test_library $LIBS"
1198 cat > conftest.$ac_ext <<EOF
1199 #line 1200 "configure"
1200 #include "confdefs.h"
1202 int main() {
1203 ${x_direct_test_function}()
1204 ; return 0; }
1206 if { (eval echo configure:1207: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1207 rm -rf conftest*
1208 LIBS="$ac_save_LIBS"
1209 # We can link X programs with no special library path.
1210 ac_x_libraries=
1211 else
1212 echo "configure: failed program was:" >&5
1213 cat conftest.$ac_ext >&5
1214 rm -rf conftest*
1215 LIBS="$ac_save_LIBS"
1216 # First see if replacing the include by lib works.
1217 # Check X11 before X11Rn because it is often a symlink to the current release.
1218 for ac_dir in `echo "$ac_x_includes" | sed s/include/lib/` \
1219 /usr/X11/lib \
1220 /usr/X11R6/lib \
1221 /usr/X11R5/lib \
1222 /usr/X11R4/lib \
1224 /usr/lib/X11 \
1225 /usr/lib/X11R6 \
1226 /usr/lib/X11R5 \
1227 /usr/lib/X11R4 \
1229 /usr/local/X11/lib \
1230 /usr/local/X11R6/lib \
1231 /usr/local/X11R5/lib \
1232 /usr/local/X11R4/lib \
1234 /usr/local/lib/X11 \
1235 /usr/local/lib/X11R6 \
1236 /usr/local/lib/X11R5 \
1237 /usr/local/lib/X11R4 \
1239 /usr/X386/lib \
1240 /usr/x386/lib \
1241 /usr/XFree86/lib/X11 \
1243 /usr/lib \
1244 /usr/local/lib \
1245 /usr/unsupported/lib \
1246 /usr/athena/lib \
1247 /usr/local/x11r5/lib \
1248 /usr/lpp/Xamples/lib \
1249 /lib/usr/lib/X11 \
1251 /usr/openwin/lib \
1252 /usr/openwin/share/lib \
1255 for ac_extension in a so sl; do
1256 if test -r $ac_dir/lib${x_direct_test_library}.$ac_extension; then
1257 ac_x_libraries=$ac_dir
1258 break 2
1260 done
1261 done
1263 rm -f conftest*
1264 fi # $ac_x_libraries = NO
1266 if test "$ac_x_includes" = NO || test "$ac_x_libraries" = NO; then
1267 # Didn't find X anywhere. Cache the known absence of X.
1268 ac_cv_have_x="have_x=no"
1269 else
1270 # Record where we found X for the cache.
1271 ac_cv_have_x="have_x=yes \
1272 ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
1276 eval "$ac_cv_have_x"
1277 fi # $with_x != no
1279 if test "$have_x" != yes; then
1280 echo "$ac_t""$have_x" 1>&6
1281 no_x=yes
1282 else
1283 # If each of the values was on the command line, it overrides each guess.
1284 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
1285 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
1286 # Update the cache value to reflect the command line values.
1287 ac_cv_have_x="have_x=yes \
1288 ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
1289 echo "$ac_t""libraries $x_libraries, headers $x_includes" 1>&6
1292 if test "$no_x"; then
1293 GRAPHSYS=GNUPLOT
1294 else
1295 GRAPHSYS=X11WINDOWS
1296 if test "$x_includes"; then X11INCDIR_FLAG="-I$x_includes"; fi
1297 if test "$x_libraries"; then X11LIBDIR_FLAG="-L$x_libraries"; fi
1302 # Check for dynamic loaing support
1305 # First try for SysVR4-style dlfcn support
1306 echo $ac_n "checking for dlopen""... $ac_c" 1>&6
1307 echo "configure:1308: checking for dlopen" >&5
1308 if eval "test \"`echo '$''{'ac_cv_func_dlopen'+set}'`\" = set"; then
1309 echo $ac_n "(cached) $ac_c" 1>&6
1310 else
1311 cat > conftest.$ac_ext <<EOF
1312 #line 1313 "configure"
1313 #include "confdefs.h"
1314 /* System header to define __stub macros and hopefully few prototypes,
1315 which can conflict with char dlopen(); below. */
1316 #include <assert.h>
1317 /* Override any gcc2 internal prototype to avoid an error. */
1318 /* We use char because int might match the return type of a gcc2
1319 builtin and then its argument prototype would still apply. */
1320 char dlopen();
1322 int main() {
1324 /* The GNU C library defines this for functions which it implements
1325 to always fail with ENOSYS. Some functions are actually named
1326 something starting with __ and the normal name is an alias. */
1327 #if defined (__stub_dlopen) || defined (__stub___dlopen)
1328 choke me
1329 #else
1330 dlopen();
1331 #endif
1333 ; return 0; }
1335 if { (eval echo configure:1336: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1336 rm -rf conftest*
1337 eval "ac_cv_func_dlopen=yes"
1338 else
1339 echo "configure: failed program was:" >&5
1340 cat conftest.$ac_ext >&5
1341 rm -rf conftest*
1342 eval "ac_cv_func_dlopen=no"
1344 rm -f conftest*
1347 if eval "test \"`echo '$ac_cv_func_'dlopen`\" = yes"; then
1348 echo "$ac_t""yes" 1>&6
1350 FOREIGN_FILE="sysvr4-foreign.h"
1351 foreign=1
1352 cat >> confdefs.h <<\EOF
1353 #define HAVE_DLOPEN 1
1355 # not sure why I need this but I seem to
1356 cat >> confdefs.h <<\EOF
1357 #define HAVE_FOREIGN 1
1360 else
1361 echo "$ac_t""no" 1>&6
1362 echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6
1363 echo "configure:1364: checking for dlopen in -ldl" >&5
1364 ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'`
1365 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1366 echo $ac_n "(cached) $ac_c" 1>&6
1367 else
1368 ac_save_LIBS="$LIBS"
1369 LIBS="-ldl $LIBS"
1370 cat > conftest.$ac_ext <<EOF
1371 #line 1372 "configure"
1372 #include "confdefs.h"
1373 /* Override any gcc2 internal prototype to avoid an error. */
1374 /* We use char because int might match the return type of a gcc2
1375 builtin and then its argument prototype would still apply. */
1376 char dlopen();
1378 int main() {
1379 dlopen()
1380 ; return 0; }
1382 if { (eval echo configure:1383: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1383 rm -rf conftest*
1384 eval "ac_cv_lib_$ac_lib_var=yes"
1385 else
1386 echo "configure: failed program was:" >&5
1387 cat conftest.$ac_ext >&5
1388 rm -rf conftest*
1389 eval "ac_cv_lib_$ac_lib_var=no"
1391 rm -f conftest*
1392 LIBS="$ac_save_LIBS"
1395 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1396 echo "$ac_t""yes" 1>&6
1398 FOREIGN_FILE="sysvr4-foreign.h"
1399 foreign=1
1400 cat >> confdefs.h <<\EOF
1401 #define HAVE_DLOPEN 1
1403 # not sure why I need this but I seem to
1404 cat >> confdefs.h <<\EOF
1405 #define HAVE_FOREIGN 1
1408 EXTRALIBS="$EXTRALIBS -ldl"
1409 else
1410 echo "$ac_t""no" 1>&6
1416 # Next try some os-specific solutions
1417 if test ! "$foreign"; then
1418 case $host in
1419 *aix*)
1420 # This needs to be checked
1421 ULDFLAGS="-bE:xlisp.exp -bM:SRE"
1422 link_sources="$link_sources src/c/machines/aix/xlisp.exp"
1423 link_sources="$link_sources src/cmachines/aix/dynload/dlfcn.c"
1424 link_targets ="$link_targets src/c/xlisp.exp src/c/dlfcn.c"
1425 FOREIGN_FILE="sysvr4-foreign.h";
1426 cat >> confdefs.h <<\EOF
1427 #define HAVE_FOREIGN 1
1430 cat >> confdefs.h <<\EOF
1431 #define HAVE_DLOPEN 1
1434 UCFLAGS="$UCFLAGS -Imachines/aix/dynload"
1435 EXTRAOBJS=dlfcn.o
1436 EXTRALIBS="$EXTRALIBS -lld"
1437 foreign=1
1439 *hpux*)
1440 FOREIGN_FILE="sysvr4-foreign.h"
1441 cat >> confdefs.h <<\EOF
1442 #define HAVE_FOREIGN 1
1445 cat >> confdefs.h <<\EOF
1446 #define HAVE_DLOPEN 1
1449 UCFLAGS="$UCFLAGS -Imachines/hpux/dlfcn"
1450 EXTRAOBJS="$EXTRAOBJS dlfcn.o"
1451 link_sources="$link_sources src/c/machines/hpux/dlfcn/dlfcn.c"
1452 link_targets="$link_targets src/c/dlfcn.c"
1453 EXTRALIBS="$EXTRALIBS -ldld"
1454 ULDFLAGS="$ULDFLAGS -Wl,-E"
1455 foreign=1
1457 mips-dec-ultrix*)
1458 FOREIGN_FILE="pmax-foreign.h"
1459 cat >> confdefs.h <<\EOF
1460 #define HAVE_FOREIGN 1
1463 ULDFLAGS="$ULDFLAGS -Wl,-D -Wl,c00000"
1464 foreign=1
1466 vax*)
1467 FOREIGN_FILE="bsd-foreign.h"
1468 cat >> confdefs.h <<\EOF
1469 #define HAVE_FOREIGN 1
1472 foreign=1
1474 *bsd*)
1475 FOREIGN_FILE="bsd-foreign.h"
1476 cat >> confdefs.h <<\EOF
1477 #define HAVE_FOREIGN 1
1480 foreign=1
1482 esac
1484 # As last resort try for GNU dld
1485 if test ! "$foreign"; then
1486 echo $ac_n "checking for dld_init in -ldld""... $ac_c" 1>&6
1487 echo "configure:1488: checking for dld_init in -ldld" >&5
1488 ac_lib_var=`echo dld'_'dld_init | sed 'y%./+-%__p_%'`
1489 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1490 echo $ac_n "(cached) $ac_c" 1>&6
1491 else
1492 ac_save_LIBS="$LIBS"
1493 LIBS="-ldld $LIBS"
1494 cat > conftest.$ac_ext <<EOF
1495 #line 1496 "configure"
1496 #include "confdefs.h"
1497 /* Override any gcc2 internal prototype to avoid an error. */
1498 /* We use char because int might match the return type of a gcc2
1499 builtin and then its argument prototype would still apply. */
1500 char dld_init();
1502 int main() {
1503 dld_init()
1504 ; return 0; }
1506 if { (eval echo configure:1507: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1507 rm -rf conftest*
1508 eval "ac_cv_lib_$ac_lib_var=yes"
1509 else
1510 echo "configure: failed program was:" >&5
1511 cat conftest.$ac_ext >&5
1512 rm -rf conftest*
1513 eval "ac_cv_lib_$ac_lib_var=no"
1515 rm -f conftest*
1516 LIBS="$ac_save_LIBS"
1519 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1520 echo "$ac_t""yes" 1>&6
1522 FOREIGN_FILE="dld-foreign.h"
1523 foreign=1
1524 cat >> confdefs.h <<\EOF
1525 #define HAVE_FOREIGN 1
1528 EXTRALIBS="$EXTRALIBS -ldld"
1529 else
1530 echo "$ac_t""no" 1>&6
1537 # Determine how to create shared libraries -- adapted from Tcl 8.0
1539 SHLIB_CFLAGS=""
1540 SHLIB_LD_LIBS=""
1541 case $host in
1542 *aix*) # **** this doesn't work yet
1543 SHLIB_LD="$fullSrcDir/ldAix /bin/ld -bhalt:4 -bM:SRE -bE:lib.exp -H512 -T512 -bnoentry"
1544 SHLIB_LD_LIBS='${LIBS}'
1546 alpha-dec-osf*)
1547 # check this out
1548 SHLIB_LD='ld -shared -expect_unresolved "*"'
1550 *hpux*)
1551 SHLIB_CFLAGS="+z -Aa -D_HPUX_SOURCE"
1552 SHLIB_LD="ld -b"
1554 *irix*)
1555 SHLIB_LD="ld -shared -rdata_shared"
1557 *linux*)
1558 SHLIB_CFLAGS="-fPIC"
1559 SHLIB_LD="${CC} -shared"
1561 *netbsd*|*freebsd*|*openbsd*)
1562 SHLIB_CFLAGS="-fpic"
1563 SHLIB_LD="ld -Bshareable -x"
1565 *sunos*)
1566 SHLIB_CFLAGS="-PIC"
1567 SHLIB_LD="ld"
1569 *solaris*)
1570 SHLIB_CFLAGS="-KPIC"
1571 SHLIB_LD="/usr/ccs/bin/ld -G -z text"
1572 SHLIB_LD_LIBS='${LIBS}'
1575 echo "configure: warning: Don't know how to create shared libraries on this platform" 1>&2
1576 esac
1578 # If we're running gcc, then change the C flags for compiling shared
1579 # libraries to the right flags for gcc, instead of those for the
1580 # standard manufacturer compiler.
1581 if test `$CC -v 2>&1 | grep -c gcc` != "0" ; then
1582 case $system in
1583 *aix*)
1585 *irix*)
1587 *netbsd*|*freebsd*|*openbsd*|*linux*)
1590 SHLIB_CFLAGS="-fPIC"
1592 esac
1597 # Register variables for substitution
1613 echo GRAPHSYS = $GRAPHSYS
1614 echo X11INCDIR_FLAG = $X11INCDIR_FLAG
1615 echo X11LIBDIR_FLAG = $X11LIBDIR_FLAG
1616 echo UCFLAGS = $UCFLAGS
1617 echo ULDFLAGS = $ULDFLAGS
1618 echo EXTRALIBS = $EXTRALIBS
1619 echo EXTRAOBJS = $EXTRAOBJS
1620 echo FOREIGN_FILE = $FOREIGN_FILE
1621 echo CC = $CC
1622 echo SHLIB_CFLAGS = $SHLIB_CFLAGS
1623 echo SHLIB_LD = $SHLIB_LD
1624 echo SHLIB_LD_LIBS = $SHLIB_LD_LIBS
1627 trap '' 1 2 15
1628 cat > confcache <<\EOF
1629 # This file is a shell script that caches the results of configure
1630 # tests run on this system so they can be shared between configure
1631 # scripts and configure runs. It is not useful on other systems.
1632 # If it contains results you don't want to keep, you may remove or edit it.
1634 # By default, configure uses ./config.cache as the cache file,
1635 # creating it if it does not exist already. You can give configure
1636 # the --cache-file=FILE option to use a different cache file; that is
1637 # what configure does when it calls configure scripts in
1638 # subdirectories, so they share the cache.
1639 # Giving --cache-file=/dev/null disables caching, for debugging configure.
1640 # config.status only pays attention to the cache file if you give it the
1641 # --recheck option to rerun configure.
1644 # The following way of writing the cache mishandles newlines in values,
1645 # but we know of no workaround that is simple, portable, and efficient.
1646 # So, don't put newlines in cache variables' values.
1647 # Ultrix sh set writes to stderr and can't be redirected directly,
1648 # and sets the high bit in the cache file unless we assign to the vars.
1649 (set) 2>&1 |
1650 case `(ac_space=' '; set | grep ac_space) 2>&1` in
1651 *ac_space=\ *)
1652 # `set' does not quote correctly, so add quotes (double-quote substitution
1653 # turns \\\\ into \\, and sed turns \\ into \).
1654 sed -n \
1655 -e "s/'/'\\\\''/g" \
1656 -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
1659 # `set' quotes correctly as required by POSIX, so do not add quotes.
1660 sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
1662 esac >> confcache
1663 if cmp -s $cache_file confcache; then
1665 else
1666 if test -w $cache_file; then
1667 echo "updating cache $cache_file"
1668 cat confcache > $cache_file
1669 else
1670 echo "not updating unwritable cache $cache_file"
1673 rm -f confcache
1675 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
1677 test "x$prefix" = xNONE && prefix=$ac_default_prefix
1678 # Let make expand exec_prefix.
1679 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
1681 # Any assignment to VPATH causes Sun make to only execute
1682 # the first set of double-colon rules, so remove it if not needed.
1683 # If there is a colon in the path, we need to keep it.
1684 if test "x$srcdir" = x.; then
1685 ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
1688 trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
1690 DEFS=-DHAVE_CONFIG_H
1692 # Without the "./", some shells look in PATH for config.status.
1693 : ${CONFIG_STATUS=./config.status}
1695 echo creating $CONFIG_STATUS
1696 rm -f $CONFIG_STATUS
1697 cat > $CONFIG_STATUS <<EOF
1698 #! /bin/sh
1699 # Generated automatically by configure.
1700 # Run this file to recreate the current configuration.
1701 # This directory was configured as follows,
1702 # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
1704 # $0 $ac_configure_args
1706 # Compiler output produced by configure, useful for debugging
1707 # configure, is in ./config.log if it exists.
1709 ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
1710 for ac_option
1712 case "\$ac_option" in
1713 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
1714 echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
1715 exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
1716 -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
1717 echo "$CONFIG_STATUS generated by autoconf version 2.13"
1718 exit 0 ;;
1719 -help | --help | --hel | --he | --h)
1720 echo "\$ac_cs_usage"; exit 0 ;;
1721 *) echo "\$ac_cs_usage"; exit 1 ;;
1722 esac
1723 done
1725 ac_given_srcdir=$srcdir
1727 trap 'rm -fr `echo "Makefile shlibconfig.sh src/c/Makefile src/include/xlconfig.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
1729 cat >> $CONFIG_STATUS <<EOF
1731 # Protect against being on the right side of a sed subst in config.status.
1732 sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
1733 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
1734 $ac_vpsub
1735 $extrasub
1736 s%@SHELL@%$SHELL%g
1737 s%@CFLAGS@%$CFLAGS%g
1738 s%@CPPFLAGS@%$CPPFLAGS%g
1739 s%@CXXFLAGS@%$CXXFLAGS%g
1740 s%@FFLAGS@%$FFLAGS%g
1741 s%@DEFS@%$DEFS%g
1742 s%@LDFLAGS@%$LDFLAGS%g
1743 s%@LIBS@%$LIBS%g
1744 s%@exec_prefix@%$exec_prefix%g
1745 s%@prefix@%$prefix%g
1746 s%@program_transform_name@%$program_transform_name%g
1747 s%@bindir@%$bindir%g
1748 s%@sbindir@%$sbindir%g
1749 s%@libexecdir@%$libexecdir%g
1750 s%@datadir@%$datadir%g
1751 s%@sysconfdir@%$sysconfdir%g
1752 s%@sharedstatedir@%$sharedstatedir%g
1753 s%@localstatedir@%$localstatedir%g
1754 s%@libdir@%$libdir%g
1755 s%@includedir@%$includedir%g
1756 s%@oldincludedir@%$oldincludedir%g
1757 s%@infodir@%$infodir%g
1758 s%@mandir@%$mandir%g
1759 s%@host@%$host%g
1760 s%@host_alias@%$host_alias%g
1761 s%@host_cpu@%$host_cpu%g
1762 s%@host_vendor@%$host_vendor%g
1763 s%@host_os@%$host_os%g
1764 s%@CPP@%$CPP%g
1765 s%@GRAPHSYS@%$GRAPHSYS%g
1766 s%@X11INCDIR_FLAG@%$X11INCDIR_FLAG%g
1767 s%@X11LIBDIR_FLAG@%$X11LIBDIR_FLAG%g
1768 s%@UCFLAGS@%$UCFLAGS%g
1769 s%@ULDFLAGS@%$ULDFLAGS%g
1770 s%@EXTRALIBS@%$EXTRALIBS%g
1771 s%@EXTRAOBJS@%$EXTRAOBJS%g
1772 s%@FOREIGN_FILE@%$FOREIGN_FILE%g
1773 s%@CC@%$CC%g
1774 s%@SHLIB_CFLAGS@%$SHLIB_CFLAGS%g
1775 s%@SHLIB_LD@%$SHLIB_LD%g
1776 s%@SHLIB_LD_LIBS@%$SHLIB_LD_LIBS%g
1778 CEOF
1781 cat >> $CONFIG_STATUS <<\EOF
1783 # Split the substitutions into bite-sized pieces for seds with
1784 # small command number limits, like on Digital OSF/1 and HP-UX.
1785 ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
1786 ac_file=1 # Number of current file.
1787 ac_beg=1 # First line for current file.
1788 ac_end=$ac_max_sed_cmds # Line after last line for current file.
1789 ac_more_lines=:
1790 ac_sed_cmds=""
1791 while $ac_more_lines; do
1792 if test $ac_beg -gt 1; then
1793 sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
1794 else
1795 sed "${ac_end}q" conftest.subs > conftest.s$ac_file
1797 if test ! -s conftest.s$ac_file; then
1798 ac_more_lines=false
1799 rm -f conftest.s$ac_file
1800 else
1801 if test -z "$ac_sed_cmds"; then
1802 ac_sed_cmds="sed -f conftest.s$ac_file"
1803 else
1804 ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
1806 ac_file=`expr $ac_file + 1`
1807 ac_beg=$ac_end
1808 ac_end=`expr $ac_end + $ac_max_sed_cmds`
1810 done
1811 if test -z "$ac_sed_cmds"; then
1812 ac_sed_cmds=cat
1816 cat >> $CONFIG_STATUS <<EOF
1818 CONFIG_FILES=\${CONFIG_FILES-"Makefile shlibconfig.sh src/c/Makefile"}
1820 cat >> $CONFIG_STATUS <<\EOF
1821 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
1822 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
1823 case "$ac_file" in
1824 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
1825 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
1826 *) ac_file_in="${ac_file}.in" ;;
1827 esac
1829 # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
1831 # Remove last slash and all that follows it. Not all systems have dirname.
1832 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
1833 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
1834 # The file is in a subdirectory.
1835 test ! -d "$ac_dir" && mkdir "$ac_dir"
1836 ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
1837 # A "../" for each directory in $ac_dir_suffix.
1838 ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
1839 else
1840 ac_dir_suffix= ac_dots=
1843 case "$ac_given_srcdir" in
1844 .) srcdir=.
1845 if test -z "$ac_dots"; then top_srcdir=.
1846 else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
1847 /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
1848 *) # Relative path.
1849 srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
1850 top_srcdir="$ac_dots$ac_given_srcdir" ;;
1851 esac
1854 echo creating "$ac_file"
1855 rm -f "$ac_file"
1856 configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
1857 case "$ac_file" in
1858 *Makefile*) ac_comsub="1i\\
1859 # $configure_input" ;;
1860 *) ac_comsub= ;;
1861 esac
1863 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
1864 sed -e "$ac_comsub
1865 s%@configure_input@%$configure_input%g
1866 s%@srcdir@%$srcdir%g
1867 s%@top_srcdir@%$top_srcdir%g
1868 " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
1869 fi; done
1870 rm -f conftest.s*
1872 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
1873 # NAME is the cpp macro being defined and VALUE is the value it is being given.
1875 # ac_d sets the value in "#define NAME VALUE" lines.
1876 ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)'
1877 ac_dB='\([ ][ ]*\)[^ ]*%\1#\2'
1878 ac_dC='\3'
1879 ac_dD='%g'
1880 # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
1881 ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
1882 ac_uB='\([ ]\)%\1#\2define\3'
1883 ac_uC=' '
1884 ac_uD='\4%g'
1885 # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
1886 ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
1887 ac_eB='$%\1#\2define\3'
1888 ac_eC=' '
1889 ac_eD='%g'
1891 if test "${CONFIG_HEADERS+set}" != set; then
1893 cat >> $CONFIG_STATUS <<EOF
1894 CONFIG_HEADERS="src/include/xlconfig.h"
1896 cat >> $CONFIG_STATUS <<\EOF
1898 for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
1899 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
1900 case "$ac_file" in
1901 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
1902 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
1903 *) ac_file_in="${ac_file}.in" ;;
1904 esac
1906 echo creating $ac_file
1908 rm -f conftest.frag conftest.in conftest.out
1909 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
1910 cat $ac_file_inputs > conftest.in
1914 # Transform confdefs.h into a sed script conftest.vals that substitutes
1915 # the proper values into config.h.in to produce config.h. And first:
1916 # Protect against being on the right side of a sed subst in config.status.
1917 # Protect against being in an unquoted here document in config.status.
1918 rm -f conftest.vals
1919 cat > conftest.hdr <<\EOF
1920 s/[\\&%]/\\&/g
1921 s%[\\$`]%\\&%g
1922 s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
1923 s%ac_d%ac_u%gp
1924 s%ac_u%ac_e%gp
1926 sed -n -f conftest.hdr confdefs.h > conftest.vals
1927 rm -f conftest.hdr
1929 # This sed command replaces #undef with comments. This is necessary, for
1930 # example, in the case of _POSIX_SOURCE, which is predefined and required
1931 # on some systems where configure will not decide to define it.
1932 cat >> conftest.vals <<\EOF
1933 s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
1936 # Break up conftest.vals because some shells have a limit on
1937 # the size of here documents, and old seds have small limits too.
1939 rm -f conftest.tail
1940 while :
1942 ac_lines=`grep -c . conftest.vals`
1943 # grep -c gives empty output for an empty file on some AIX systems.
1944 if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
1945 # Write a limited-size here document to conftest.frag.
1946 echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
1947 sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
1948 echo 'CEOF
1949 sed -f conftest.frag conftest.in > conftest.out
1950 rm -f conftest.in
1951 mv conftest.out conftest.in
1952 ' >> $CONFIG_STATUS
1953 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
1954 rm -f conftest.vals
1955 mv conftest.tail conftest.vals
1956 done
1957 rm -f conftest.vals
1959 cat >> $CONFIG_STATUS <<\EOF
1960 rm -f conftest.frag conftest.h
1961 echo "/* $ac_file. Generated automatically by configure. */" > conftest.h
1962 cat conftest.in >> conftest.h
1963 rm -f conftest.in
1964 if cmp -s $ac_file conftest.h 2>/dev/null; then
1965 echo "$ac_file is unchanged"
1966 rm -f conftest.h
1967 else
1968 # Remove last slash and all that follows it. Not all systems have dirname.
1969 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
1970 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
1971 # The file is in a subdirectory.
1972 test ! -d "$ac_dir" && mkdir "$ac_dir"
1974 rm -f $ac_file
1975 mv conftest.h $ac_file
1977 fi; done
1981 cat >> $CONFIG_STATUS <<EOF
1982 ac_sources="$link_sources"
1983 ac_dests="$link_targets"
1986 cat >> $CONFIG_STATUS <<\EOF
1987 srcdir=$ac_given_srcdir
1988 while test -n "$ac_sources"; do
1989 set $ac_dests; ac_dest=$1; shift; ac_dests=$*
1990 set $ac_sources; ac_source=$1; shift; ac_sources=$*
1992 echo "linking $srcdir/$ac_source to $ac_dest"
1994 if test ! -r $srcdir/$ac_source; then
1995 { echo "configure: error: $srcdir/$ac_source: File not found" 1>&2; exit 1; }
1997 rm -f $ac_dest
1999 # Make relative symlinks.
2000 # Remove last slash and all that follows it. Not all systems have dirname.
2001 ac_dest_dir=`echo $ac_dest|sed 's%/[^/][^/]*$%%'`
2002 if test "$ac_dest_dir" != "$ac_dest" && test "$ac_dest_dir" != .; then
2003 # The dest file is in a subdirectory.
2004 test ! -d "$ac_dest_dir" && mkdir "$ac_dest_dir"
2005 ac_dest_dir_suffix="/`echo $ac_dest_dir|sed 's%^\./%%'`"
2006 # A "../" for each directory in $ac_dest_dir_suffix.
2007 ac_dots=`echo $ac_dest_dir_suffix|sed 's%/[^/]*%../%g'`
2008 else
2009 ac_dest_dir_suffix= ac_dots=
2012 case "$srcdir" in
2013 [/$]*) ac_rel_source="$srcdir/$ac_source" ;;
2014 *) ac_rel_source="$ac_dots$srcdir/$ac_source" ;;
2015 esac
2017 # Make a symlink if possible; otherwise try a hard link.
2018 if ln -s $ac_rel_source $ac_dest 2>/dev/null ||
2019 ln $srcdir/$ac_source $ac_dest; then :
2020 else
2021 { echo "configure: error: can not link $ac_dest to $srcdir/$ac_source" 1>&2; exit 1; }
2023 done
2025 cat >> $CONFIG_STATUS <<EOF
2028 cat >> $CONFIG_STATUS <<\EOF
2030 exit 0
2032 chmod +x $CONFIG_STATUS
2033 rm -fr confdefs* $ac_clean_files
2034 test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1