]> www.ginac.de Git - ginac.git/blob - configure
- Complete revamp of methods in class matrix. Some redundant (and poor)
[ginac.git] / configure
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   --enable-maintainer-mode enable make rules and dependencies not useful
16                           (and sometimes confusing) to the casual installer"
17 ac_help="$ac_help
18   --enable-shared[=PKGS]  build shared libraries [default=yes]"
19 ac_help="$ac_help
20   --enable-static[=PKGS]  build static libraries [default=yes]"
21 ac_help="$ac_help
22   --enable-fast-install[=PKGS]  optimize for fast installation [default=yes]"
23 ac_help="$ac_help
24   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]"
25 ac_help="$ac_help
26   --disable-libtool-lock  avoid locking (might break parallel builds)"
27 ac_help="$ac_help
28   --enable-html-doc       build HTML documentation [default=no]"
29 ac_help="$ac_help
30   --enable-ps-doc         build PostScript documentation [default=no]"
31 ac_help="$ac_help
32   --with-cint=CINTSYSDIR  build GiNaC-cint C++ interpreter [default=no]"
33
34 # Initialize some variables set by options.
35 # The variables have the same names as the options, with
36 # dashes changed to underlines.
37 build=NONE
38 cache_file=./config.cache
39 exec_prefix=NONE
40 host=NONE
41 no_create=
42 nonopt=NONE
43 no_recursion=
44 prefix=NONE
45 program_prefix=NONE
46 program_suffix=NONE
47 program_transform_name=s,x,x,
48 silent=
49 site=
50 srcdir=
51 target=NONE
52 verbose=
53 x_includes=NONE
54 x_libraries=NONE
55 bindir='${exec_prefix}/bin'
56 sbindir='${exec_prefix}/sbin'
57 libexecdir='${exec_prefix}/libexec'
58 datadir='${prefix}/share'
59 sysconfdir='${prefix}/etc'
60 sharedstatedir='${prefix}/com'
61 localstatedir='${prefix}/var'
62 libdir='${exec_prefix}/lib'
63 includedir='${prefix}/include'
64 oldincludedir='/usr/include'
65 infodir='${prefix}/info'
66 mandir='${prefix}/man'
67
68 # Initialize some other variables.
69 subdirs=
70 MFLAGS= MAKEFLAGS=
71 SHELL=${CONFIG_SHELL-/bin/sh}
72 # Maximum number of lines to put in a shell here document.
73 ac_max_here_lines=12
74
75 ac_prev=
76 for ac_option
77 do
78
79   # If the previous option needs an argument, assign it.
80   if test -n "$ac_prev"; then
81     eval "$ac_prev=\$ac_option"
82     ac_prev=
83     continue
84   fi
85
86   case "$ac_option" in
87   -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
88   *) ac_optarg= ;;
89   esac
90
91   # Accept the important Cygnus configure options, so we can diagnose typos.
92
93   case "$ac_option" in
94
95   -bindir | --bindir | --bindi | --bind | --bin | --bi)
96     ac_prev=bindir ;;
97   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
98     bindir="$ac_optarg" ;;
99
100   -build | --build | --buil | --bui | --bu)
101     ac_prev=build ;;
102   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
103     build="$ac_optarg" ;;
104
105   -cache-file | --cache-file | --cache-fil | --cache-fi \
106   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
107     ac_prev=cache_file ;;
108   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
109   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
110     cache_file="$ac_optarg" ;;
111
112   -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
113     ac_prev=datadir ;;
114   -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
115   | --da=*)
116     datadir="$ac_optarg" ;;
117
118   -disable-* | --disable-*)
119     ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
120     # Reject names that are not valid shell variable names.
121     if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
122       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
123     fi
124     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
125     eval "enable_${ac_feature}=no" ;;
126
127   -enable-* | --enable-*)
128     ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
129     # Reject names that are not valid shell variable names.
130     if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
131       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
132     fi
133     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
134     case "$ac_option" in
135       *=*) ;;
136       *) ac_optarg=yes ;;
137     esac
138     eval "enable_${ac_feature}='$ac_optarg'" ;;
139
140   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
141   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
142   | --exec | --exe | --ex)
143     ac_prev=exec_prefix ;;
144   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
145   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
146   | --exec=* | --exe=* | --ex=*)
147     exec_prefix="$ac_optarg" ;;
148
149   -gas | --gas | --ga | --g)
150     # Obsolete; use --with-gas.
151     with_gas=yes ;;
152
153   -help | --help | --hel | --he)
154     # Omit some internal or obsolete options to make the list less imposing.
155     # This message is too long to be a string in the A/UX 3.1 sh.
156     cat << EOF
157 Usage: configure [options] [host]
158 Options: [defaults in brackets after descriptions]
159 Configuration:
160   --cache-file=FILE       cache test results in FILE
161   --help                  print this message
162   --no-create             do not create output files
163   --quiet, --silent       do not print \`checking...' messages
164   --version               print the version of autoconf that created configure
165 Directory and file names:
166   --prefix=PREFIX         install architecture-independent files in PREFIX
167                           [$ac_default_prefix]
168   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
169                           [same as prefix]
170   --bindir=DIR            user executables in DIR [EPREFIX/bin]
171   --sbindir=DIR           system admin executables in DIR [EPREFIX/sbin]
172   --libexecdir=DIR        program executables in DIR [EPREFIX/libexec]
173   --datadir=DIR           read-only architecture-independent data in DIR
174                           [PREFIX/share]
175   --sysconfdir=DIR        read-only single-machine data in DIR [PREFIX/etc]
176   --sharedstatedir=DIR    modifiable architecture-independent data in DIR
177                           [PREFIX/com]
178   --localstatedir=DIR     modifiable single-machine data in DIR [PREFIX/var]
179   --libdir=DIR            object code libraries in DIR [EPREFIX/lib]
180   --includedir=DIR        C header files in DIR [PREFIX/include]
181   --oldincludedir=DIR     C header files for non-gcc in DIR [/usr/include]
182   --infodir=DIR           info documentation in DIR [PREFIX/info]
183   --mandir=DIR            man documentation in DIR [PREFIX/man]
184   --srcdir=DIR            find the sources in DIR [configure dir or ..]
185   --program-prefix=PREFIX prepend PREFIX to installed program names
186   --program-suffix=SUFFIX append SUFFIX to installed program names
187   --program-transform-name=PROGRAM
188                           run sed PROGRAM on installed program names
189 EOF
190     cat << EOF
191 Host type:
192   --build=BUILD           configure for building on BUILD [BUILD=HOST]
193   --host=HOST             configure for HOST [guessed]
194   --target=TARGET         configure for TARGET [TARGET=HOST]
195 Features and packages:
196   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
197   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
198   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
199   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
200   --x-includes=DIR        X include files are in DIR
201   --x-libraries=DIR       X library files are in DIR
202 EOF
203     if test -n "$ac_help"; then
204       echo "--enable and --with options recognized:$ac_help"
205     fi
206     exit 0 ;;
207
208   -host | --host | --hos | --ho)
209     ac_prev=host ;;
210   -host=* | --host=* | --hos=* | --ho=*)
211     host="$ac_optarg" ;;
212
213   -includedir | --includedir | --includedi | --included | --include \
214   | --includ | --inclu | --incl | --inc)
215     ac_prev=includedir ;;
216   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
217   | --includ=* | --inclu=* | --incl=* | --inc=*)
218     includedir="$ac_optarg" ;;
219
220   -infodir | --infodir | --infodi | --infod | --info | --inf)
221     ac_prev=infodir ;;
222   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
223     infodir="$ac_optarg" ;;
224
225   -libdir | --libdir | --libdi | --libd)
226     ac_prev=libdir ;;
227   -libdir=* | --libdir=* | --libdi=* | --libd=*)
228     libdir="$ac_optarg" ;;
229
230   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
231   | --libexe | --libex | --libe)
232     ac_prev=libexecdir ;;
233   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
234   | --libexe=* | --libex=* | --libe=*)
235     libexecdir="$ac_optarg" ;;
236
237   -localstatedir | --localstatedir | --localstatedi | --localstated \
238   | --localstate | --localstat | --localsta | --localst \
239   | --locals | --local | --loca | --loc | --lo)
240     ac_prev=localstatedir ;;
241   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
242   | --localstate=* | --localstat=* | --localsta=* | --localst=* \
243   | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
244     localstatedir="$ac_optarg" ;;
245
246   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
247     ac_prev=mandir ;;
248   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
249     mandir="$ac_optarg" ;;
250
251   -nfp | --nfp | --nf)
252     # Obsolete; use --without-fp.
253     with_fp=no ;;
254
255   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
256   | --no-cr | --no-c)
257     no_create=yes ;;
258
259   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
260   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
261     no_recursion=yes ;;
262
263   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
264   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
265   | --oldin | --oldi | --old | --ol | --o)
266     ac_prev=oldincludedir ;;
267   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
268   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
269   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
270     oldincludedir="$ac_optarg" ;;
271
272   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
273     ac_prev=prefix ;;
274   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
275     prefix="$ac_optarg" ;;
276
277   -program-prefix | --program-prefix | --program-prefi | --program-pref \
278   | --program-pre | --program-pr | --program-p)
279     ac_prev=program_prefix ;;
280   -program-prefix=* | --program-prefix=* | --program-prefi=* \
281   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
282     program_prefix="$ac_optarg" ;;
283
284   -program-suffix | --program-suffix | --program-suffi | --program-suff \
285   | --program-suf | --program-su | --program-s)
286     ac_prev=program_suffix ;;
287   -program-suffix=* | --program-suffix=* | --program-suffi=* \
288   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
289     program_suffix="$ac_optarg" ;;
290
291   -program-transform-name | --program-transform-name \
292   | --program-transform-nam | --program-transform-na \
293   | --program-transform-n | --program-transform- \
294   | --program-transform | --program-transfor \
295   | --program-transfo | --program-transf \
296   | --program-trans | --program-tran \
297   | --progr-tra | --program-tr | --program-t)
298     ac_prev=program_transform_name ;;
299   -program-transform-name=* | --program-transform-name=* \
300   | --program-transform-nam=* | --program-transform-na=* \
301   | --program-transform-n=* | --program-transform-=* \
302   | --program-transform=* | --program-transfor=* \
303   | --program-transfo=* | --program-transf=* \
304   | --program-trans=* | --program-tran=* \
305   | --progr-tra=* | --program-tr=* | --program-t=*)
306     program_transform_name="$ac_optarg" ;;
307
308   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
309   | -silent | --silent | --silen | --sile | --sil)
310     silent=yes ;;
311
312   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
313     ac_prev=sbindir ;;
314   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
315   | --sbi=* | --sb=*)
316     sbindir="$ac_optarg" ;;
317
318   -sharedstatedir | --sharedstatedir | --sharedstatedi \
319   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
320   | --sharedst | --shareds | --shared | --share | --shar \
321   | --sha | --sh)
322     ac_prev=sharedstatedir ;;
323   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
324   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
325   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
326   | --sha=* | --sh=*)
327     sharedstatedir="$ac_optarg" ;;
328
329   -site | --site | --sit)
330     ac_prev=site ;;
331   -site=* | --site=* | --sit=*)
332     site="$ac_optarg" ;;
333
334   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
335     ac_prev=srcdir ;;
336   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
337     srcdir="$ac_optarg" ;;
338
339   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
340   | --syscon | --sysco | --sysc | --sys | --sy)
341     ac_prev=sysconfdir ;;
342   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
343   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
344     sysconfdir="$ac_optarg" ;;
345
346   -target | --target | --targe | --targ | --tar | --ta | --t)
347     ac_prev=target ;;
348   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
349     target="$ac_optarg" ;;
350
351   -v | -verbose | --verbose | --verbos | --verbo | --verb)
352     verbose=yes ;;
353
354   -version | --version | --versio | --versi | --vers)
355     echo "configure generated by autoconf version 2.13"
356     exit 0 ;;
357
358   -with-* | --with-*)
359     ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
360     # Reject names that are not valid shell variable names.
361     if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
362       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
363     fi
364     ac_package=`echo $ac_package| sed 's/-/_/g'`
365     case "$ac_option" in
366       *=*) ;;
367       *) ac_optarg=yes ;;
368     esac
369     eval "with_${ac_package}='$ac_optarg'" ;;
370
371   -without-* | --without-*)
372     ac_package=`echo $ac_option|sed -e 's/-*without-//'`
373     # Reject names that are not valid shell variable names.
374     if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
375       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
376     fi
377     ac_package=`echo $ac_package| sed 's/-/_/g'`
378     eval "with_${ac_package}=no" ;;
379
380   --x)
381     # Obsolete; use --with-x.
382     with_x=yes ;;
383
384   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
385   | --x-incl | --x-inc | --x-in | --x-i)
386     ac_prev=x_includes ;;
387   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
388   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
389     x_includes="$ac_optarg" ;;
390
391   -x-libraries | --x-libraries | --x-librarie | --x-librari \
392   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
393     ac_prev=x_libraries ;;
394   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
395   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
396     x_libraries="$ac_optarg" ;;
397
398   -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
399     ;;
400
401   *)
402     if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
403       echo "configure: warning: $ac_option: invalid host type" 1>&2
404     fi
405     if test "x$nonopt" != xNONE; then
406       { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
407     fi
408     nonopt="$ac_option"
409     ;;
410
411   esac
412 done
413
414 if test -n "$ac_prev"; then
415   { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
416 fi
417
418 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
419
420 # File descriptor usage:
421 # 0 standard input
422 # 1 file creation
423 # 2 errors and warnings
424 # 3 some systems may open it to /dev/tty
425 # 4 used on the Kubota Titan
426 # 6 checking for... messages and results
427 # 5 compiler messages saved in config.log
428 if test "$silent" = yes; then
429   exec 6>/dev/null
430 else
431   exec 6>&1
432 fi
433 exec 5>./config.log
434
435 echo "\
436 This file contains any messages produced by compilers while
437 running configure, to aid debugging if configure makes a mistake.
438 " 1>&5
439
440 # Strip out --no-create and --no-recursion so they do not pile up.
441 # Also quote any args containing shell metacharacters.
442 ac_configure_args=
443 for ac_arg
444 do
445   case "$ac_arg" in
446   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
447   | --no-cr | --no-c) ;;
448   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
449   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
450   *" "*|*"      "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
451   ac_configure_args="$ac_configure_args '$ac_arg'" ;;
452   *) ac_configure_args="$ac_configure_args $ac_arg" ;;
453   esac
454 done
455
456 # NLS nuisances.
457 # Only set these to C if already set.  These must not be set unconditionally
458 # because not all systems understand e.g. LANG=C (notably SCO).
459 # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
460 # Non-C LC_CTYPE values break the ctype check.
461 if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
462 if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
463 if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
464 if test "${LC_CTYPE+set}"    = set; then LC_CTYPE=C;    export LC_CTYPE;    fi
465
466 # confdefs.h avoids OS command line length limits that DEFS can exceed.
467 rm -rf conftest* confdefs.h
468 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
469 echo > confdefs.h
470
471 # A filename unique to this package, relative to the directory that
472 # configure is in, which we can look for to find out if srcdir is correct.
473 ac_unique_file=ginac/basic.cpp
474
475 # Find the source files, if location was not specified.
476 if test -z "$srcdir"; then
477   ac_srcdir_defaulted=yes
478   # Try the directory containing this script, then its parent.
479   ac_prog=$0
480   ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
481   test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
482   srcdir=$ac_confdir
483   if test ! -r $srcdir/$ac_unique_file; then
484     srcdir=..
485   fi
486 else
487   ac_srcdir_defaulted=no
488 fi
489 if test ! -r $srcdir/$ac_unique_file; then
490   if test "$ac_srcdir_defaulted" = yes; then
491     { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
492   else
493     { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
494   fi
495 fi
496 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
497
498 # Prefer explicitly selected file to automatically selected ones.
499 if test -z "$CONFIG_SITE"; then
500   if test "x$prefix" != xNONE; then
501     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
502   else
503     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
504   fi
505 fi
506 for ac_site_file in $CONFIG_SITE; do
507   if test -r "$ac_site_file"; then
508     echo "loading site script $ac_site_file"
509     . "$ac_site_file"
510   fi
511 done
512
513 if test -r "$cache_file"; then
514   echo "loading cache $cache_file"
515   . $cache_file
516 else
517   echo "creating cache $cache_file"
518   > $cache_file
519 fi
520
521 ac_ext=c
522 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
523 ac_cpp='$CPP $CPPFLAGS'
524 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
525 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
526 cross_compiling=$ac_cv_prog_cc_cross
527
528 ac_exeext=
529 ac_objext=o
530 if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
531   # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
532   if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
533     ac_n= ac_c='
534 ' ac_t='        '
535   else
536     ac_n=-n ac_c= ac_t=
537   fi
538 else
539   ac_n= ac_c='\c' ac_t=
540 fi
541
542
543
544
545
546 GINACLIB_MAJOR_VERSION=0
547 GINACLIB_MINOR_VERSION=6
548 GINACLIB_MICRO_VERSION=4
549 GINACLIB_INTERFACE_AGE=0
550 GINACLIB_BINARY_AGE=1
551 GINACLIB_VERSION=$GINACLIB_MAJOR_VERSION.$GINACLIB_MINOR_VERSION.$GINACLIB_MICRO_VERSION
552
553
554
555
556
557
558
559
560
561 ARCHIVE_VERSION=0
562 ARCHIVE_AGE=0
563
564
565
566 cat >> confdefs.h <<EOF
567 #define ARCHIVE_VERSION $ARCHIVE_VERSION
568 EOF
569
570 cat >> confdefs.h <<EOF
571 #define ARCHIVE_AGE $ARCHIVE_AGE
572 EOF
573
574
575 LT_RELEASE=$GINACLIB_MAJOR_VERSION.$GINACLIB_MINOR_VERSION
576 LT_CURRENT=`expr $GINACLIB_MICRO_VERSION - $GINACLIB_INTERFACE_AGE`
577 LT_REVISION=$GINACLIB_INTERFACE_AGE
578 LT_AGE=`expr $GINACLIB_BINARY_AGE - $GINACLIB_INTERFACE_AGE`
579
580
581
582
583
584
585
586
587
588 ac_aux_dir=
589 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
590   if test -f $ac_dir/install-sh; then
591     ac_aux_dir=$ac_dir
592     ac_install_sh="$ac_aux_dir/install-sh -c"
593     break
594   elif test -f $ac_dir/install.sh; then
595     ac_aux_dir=$ac_dir
596     ac_install_sh="$ac_aux_dir/install.sh -c"
597     break
598   fi
599 done
600 if test -z "$ac_aux_dir"; then
601   { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
602 fi
603 ac_config_guess=$ac_aux_dir/config.guess
604 ac_config_sub=$ac_aux_dir/config.sub
605 ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
606
607 # Find a good install program.  We prefer a C program (faster),
608 # so one script is as good as another.  But avoid the broken or
609 # incompatible versions:
610 # SysV /etc/install, /usr/sbin/install
611 # SunOS /usr/etc/install
612 # IRIX /sbin/install
613 # AIX /bin/install
614 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
615 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
616 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
617 # ./install, which can be erroneously created by make from ./install.sh.
618 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
619 echo "configure:620: checking for a BSD compatible install" >&5
620 if test -z "$INSTALL"; then
621 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
622   echo $ac_n "(cached) $ac_c" 1>&6
623 else
624     IFS="${IFS=         }"; ac_save_IFS="$IFS"; IFS=":"
625   for ac_dir in $PATH; do
626     # Account for people who put trailing slashes in PATH elements.
627     case "$ac_dir/" in
628     /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
629     *)
630       # OSF1 and SCO ODT 3.0 have their own names for install.
631       # Don't use installbsd from OSF since it installs stuff as root
632       # by default.
633       for ac_prog in ginstall scoinst install; do
634         if test -f $ac_dir/$ac_prog; then
635           if test $ac_prog = install &&
636             grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
637             # AIX install.  It has an incompatible calling convention.
638             :
639           else
640             ac_cv_path_install="$ac_dir/$ac_prog -c"
641             break 2
642           fi
643         fi
644       done
645       ;;
646     esac
647   done
648   IFS="$ac_save_IFS"
649
650 fi
651   if test "${ac_cv_path_install+set}" = set; then
652     INSTALL="$ac_cv_path_install"
653   else
654     # As a last resort, use the slow shell script.  We don't cache a
655     # path for INSTALL within a source directory, because that will
656     # break other packages using the cache if that directory is
657     # removed, or if the path is relative.
658     INSTALL="$ac_install_sh"
659   fi
660 fi
661 echo "$ac_t""$INSTALL" 1>&6
662
663 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
664 # It thinks the first close brace ends the variable substitution.
665 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
666
667 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
668
669 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
670
671 echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
672 echo "configure:673: checking whether build environment is sane" >&5
673 # Just in case
674 sleep 1
675 echo timestamp > conftestfile
676 # Do `set' in a subshell so we don't clobber the current shell's
677 # arguments.  Must try -L first in case configure is actually a
678 # symlink; some systems play weird games with the mod time of symlinks
679 # (eg FreeBSD returns the mod time of the symlink's containing
680 # directory).
681 if (
682    set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
683    if test "$*" = "X"; then
684       # -L didn't work.
685       set X `ls -t $srcdir/configure conftestfile`
686    fi
687    if test "$*" != "X $srcdir/configure conftestfile" \
688       && test "$*" != "X conftestfile $srcdir/configure"; then
689
690       # If neither matched, then we have a broken ls.  This can happen
691       # if, for instance, CONFIG_SHELL is bash and it inherits a
692       # broken ls alias from the environment.  This has actually
693       # happened.  Such a system could not be considered "sane".
694       { echo "configure: error: ls -t appears to fail.  Make sure there is not a broken
695 alias in your environment" 1>&2; exit 1; }
696    fi
697
698    test "$2" = conftestfile
699    )
700 then
701    # Ok.
702    :
703 else
704    { echo "configure: error: newly created file is older than distributed files!
705 Check your system clock" 1>&2; exit 1; }
706 fi
707 rm -f conftest*
708 echo "$ac_t""yes" 1>&6
709 if test "$program_transform_name" = s,x,x,; then
710   program_transform_name=
711 else
712   # Double any \ or $.  echo might interpret backslashes.
713   cat <<\EOF_SED > conftestsed
714 s,\\,\\\\,g; s,\$,$$,g
715 EOF_SED
716   program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
717   rm -f conftestsed
718 fi
719 test "$program_prefix" != NONE &&
720   program_transform_name="s,^,${program_prefix},; $program_transform_name"
721 # Use a double $ so make ignores it.
722 test "$program_suffix" != NONE &&
723   program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
724
725 # sed with no file args requires a program.
726 test "$program_transform_name" = "" && program_transform_name="s,x,x,"
727
728 echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
729 echo "configure:730: checking whether ${MAKE-make} sets \${MAKE}" >&5
730 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
731 if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
732   echo $ac_n "(cached) $ac_c" 1>&6
733 else
734   cat > conftestmake <<\EOF
735 all:
736         @echo 'ac_maketemp="${MAKE}"'
737 EOF
738 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
739 eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
740 if test -n "$ac_maketemp"; then
741   eval ac_cv_prog_make_${ac_make}_set=yes
742 else
743   eval ac_cv_prog_make_${ac_make}_set=no
744 fi
745 rm -f conftestmake
746 fi
747 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
748   echo "$ac_t""yes" 1>&6
749   SET_MAKE=
750 else
751   echo "$ac_t""no" 1>&6
752   SET_MAKE="MAKE=${MAKE-make}"
753 fi
754
755
756 PACKAGE=GiNaC
757
758 VERSION=$GINACLIB_VERSION
759
760 if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
761   { echo "configure: error: source directory already configured; run "make distclean" there first" 1>&2; exit 1; }
762 fi
763 cat >> confdefs.h <<EOF
764 #define PACKAGE "$PACKAGE"
765 EOF
766
767 cat >> confdefs.h <<EOF
768 #define VERSION "$VERSION"
769 EOF
770
771
772
773 missing_dir=`cd $ac_aux_dir && pwd`
774 echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
775 echo "configure:776: checking for working aclocal" >&5
776 # Run test in a subshell; some versions of sh will print an error if
777 # an executable is not found, even if stderr is redirected.
778 # Redirect stdin to placate older versions of autoconf.  Sigh.
779 if (aclocal --version) < /dev/null > /dev/null 2>&1; then
780    ACLOCAL=aclocal
781    echo "$ac_t""found" 1>&6
782 else
783    ACLOCAL="$missing_dir/missing aclocal"
784    echo "$ac_t""missing" 1>&6
785 fi
786
787 echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
788 echo "configure:789: checking for working autoconf" >&5
789 # Run test in a subshell; some versions of sh will print an error if
790 # an executable is not found, even if stderr is redirected.
791 # Redirect stdin to placate older versions of autoconf.  Sigh.
792 if (autoconf --version) < /dev/null > /dev/null 2>&1; then
793    AUTOCONF=autoconf
794    echo "$ac_t""found" 1>&6
795 else
796    AUTOCONF="$missing_dir/missing autoconf"
797    echo "$ac_t""missing" 1>&6
798 fi
799
800 echo $ac_n "checking for working automake""... $ac_c" 1>&6
801 echo "configure:802: checking for working automake" >&5
802 # Run test in a subshell; some versions of sh will print an error if
803 # an executable is not found, even if stderr is redirected.
804 # Redirect stdin to placate older versions of autoconf.  Sigh.
805 if (automake --version) < /dev/null > /dev/null 2>&1; then
806    AUTOMAKE=automake
807    echo "$ac_t""found" 1>&6
808 else
809    AUTOMAKE="$missing_dir/missing automake"
810    echo "$ac_t""missing" 1>&6
811 fi
812
813 echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
814 echo "configure:815: checking for working autoheader" >&5
815 # Run test in a subshell; some versions of sh will print an error if
816 # an executable is not found, even if stderr is redirected.
817 # Redirect stdin to placate older versions of autoconf.  Sigh.
818 if (autoheader --version) < /dev/null > /dev/null 2>&1; then
819    AUTOHEADER=autoheader
820    echo "$ac_t""found" 1>&6
821 else
822    AUTOHEADER="$missing_dir/missing autoheader"
823    echo "$ac_t""missing" 1>&6
824 fi
825
826 echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
827 echo "configure:828: checking for working makeinfo" >&5
828 # Run test in a subshell; some versions of sh will print an error if
829 # an executable is not found, even if stderr is redirected.
830 # Redirect stdin to placate older versions of autoconf.  Sigh.
831 if (makeinfo --version) < /dev/null > /dev/null 2>&1; then
832    MAKEINFO=makeinfo
833    echo "$ac_t""found" 1>&6
834 else
835    MAKEINFO="$missing_dir/missing makeinfo"
836    echo "$ac_t""missing" 1>&6
837 fi
838
839
840 echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
841 echo "configure:842: checking whether to enable maintainer-specific portions of Makefiles" >&5
842     # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
843 if test "${enable_maintainer_mode+set}" = set; then
844   enableval="$enable_maintainer_mode"
845   USE_MAINTAINER_MODE=$enableval
846 else
847   USE_MAINTAINER_MODE=no
848 fi
849
850   echo "$ac_t""$USE_MAINTAINER_MODE" 1>&6
851   
852
853 if test $USE_MAINTAINER_MODE = yes; then
854   MAINTAINER_MODE_TRUE=
855   MAINTAINER_MODE_FALSE='#'
856 else
857   MAINTAINER_MODE_TRUE='#'
858   MAINTAINER_MODE_FALSE=
859 fi
860   MAINT=$MAINTAINER_MODE_TRUE
861   
862
863
864 for ac_prog in $CCC c++ g++ gcc CC cxx cc++ cl
865 do
866 # Extract the first word of "$ac_prog", so it can be a program name with args.
867 set dummy $ac_prog; ac_word=$2
868 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
869 echo "configure:870: checking for $ac_word" >&5
870 if eval "test \"`echo '$''{'ac_cv_prog_CXX'+set}'`\" = set"; then
871   echo $ac_n "(cached) $ac_c" 1>&6
872 else
873   if test -n "$CXX"; then
874   ac_cv_prog_CXX="$CXX" # Let the user override the test.
875 else
876   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
877   ac_dummy="$PATH"
878   for ac_dir in $ac_dummy; do
879     test -z "$ac_dir" && ac_dir=.
880     if test -f $ac_dir/$ac_word; then
881       ac_cv_prog_CXX="$ac_prog"
882       break
883     fi
884   done
885   IFS="$ac_save_ifs"
886 fi
887 fi
888 CXX="$ac_cv_prog_CXX"
889 if test -n "$CXX"; then
890   echo "$ac_t""$CXX" 1>&6
891 else
892   echo "$ac_t""no" 1>&6
893 fi
894
895 test -n "$CXX" && break
896 done
897 test -n "$CXX" || CXX="gcc"
898
899
900 echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works""... $ac_c" 1>&6
901 echo "configure:902: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
902
903 ac_ext=C
904 # CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
905 ac_cpp='$CXXCPP $CPPFLAGS'
906 ac_compile='${CXX-g++} -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
907 ac_link='${CXX-g++} -o conftest${ac_exeext} $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
908 cross_compiling=$ac_cv_prog_cxx_cross
909
910 cat > conftest.$ac_ext << EOF
911
912 #line 913 "configure"
913 #include "confdefs.h"
914
915 int main(){return(0);}
916 EOF
917 if { (eval echo configure:918: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
918   ac_cv_prog_cxx_works=yes
919   # If we can't run a trivial program, we are probably using a cross compiler.
920   if (./conftest; exit) 2>/dev/null; then
921     ac_cv_prog_cxx_cross=no
922   else
923     ac_cv_prog_cxx_cross=yes
924   fi
925 else
926   echo "configure: failed program was:" >&5
927   cat conftest.$ac_ext >&5
928   ac_cv_prog_cxx_works=no
929 fi
930 rm -fr conftest*
931 ac_ext=c
932 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
933 ac_cpp='$CPP $CPPFLAGS'
934 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
935 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
936 cross_compiling=$ac_cv_prog_cc_cross
937
938 echo "$ac_t""$ac_cv_prog_cxx_works" 1>&6
939 if test $ac_cv_prog_cxx_works = no; then
940   { echo "configure: error: installation or configuration problem: C++ compiler cannot create executables." 1>&2; exit 1; }
941 fi
942 echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
943 echo "configure:944: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
944 echo "$ac_t""$ac_cv_prog_cxx_cross" 1>&6
945 cross_compiling=$ac_cv_prog_cxx_cross
946
947 echo $ac_n "checking whether we are using GNU C++""... $ac_c" 1>&6
948 echo "configure:949: checking whether we are using GNU C++" >&5
949 if eval "test \"`echo '$''{'ac_cv_prog_gxx'+set}'`\" = set"; then
950   echo $ac_n "(cached) $ac_c" 1>&6
951 else
952   cat > conftest.C <<EOF
953 #ifdef __GNUC__
954   yes;
955 #endif
956 EOF
957 if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:958: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
958   ac_cv_prog_gxx=yes
959 else
960   ac_cv_prog_gxx=no
961 fi
962 fi
963
964 echo "$ac_t""$ac_cv_prog_gxx" 1>&6
965
966 if test $ac_cv_prog_gxx = yes; then
967   GXX=yes
968 else
969   GXX=
970 fi
971
972 ac_test_CXXFLAGS="${CXXFLAGS+set}"
973 ac_save_CXXFLAGS="$CXXFLAGS"
974 CXXFLAGS=
975 echo $ac_n "checking whether ${CXX-g++} accepts -g""... $ac_c" 1>&6
976 echo "configure:977: checking whether ${CXX-g++} accepts -g" >&5
977 if eval "test \"`echo '$''{'ac_cv_prog_cxx_g'+set}'`\" = set"; then
978   echo $ac_n "(cached) $ac_c" 1>&6
979 else
980   echo 'void f(){}' > conftest.cc
981 if test -z "`${CXX-g++} -g -c conftest.cc 2>&1`"; then
982   ac_cv_prog_cxx_g=yes
983 else
984   ac_cv_prog_cxx_g=no
985 fi
986 rm -f conftest*
987
988 fi
989
990 echo "$ac_t""$ac_cv_prog_cxx_g" 1>&6
991 if test "$ac_test_CXXFLAGS" = set; then
992   CXXFLAGS="$ac_save_CXXFLAGS"
993 elif test $ac_cv_prog_cxx_g = yes; then
994   if test "$GXX" = yes; then
995     CXXFLAGS="-g -O2"
996   else
997     CXXFLAGS="-g"
998   fi
999 else
1000   if test "$GXX" = yes; then
1001     CXXFLAGS="-O2"
1002   else
1003     CXXFLAGS=
1004   fi
1005 fi
1006
1007 echo $ac_n "checking how to run the C++ preprocessor""... $ac_c" 1>&6
1008 echo "configure:1009: checking how to run the C++ preprocessor" >&5
1009 if test -z "$CXXCPP"; then
1010 if eval "test \"`echo '$''{'ac_cv_prog_CXXCPP'+set}'`\" = set"; then
1011   echo $ac_n "(cached) $ac_c" 1>&6
1012 else
1013   ac_ext=C
1014 # CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1015 ac_cpp='$CXXCPP $CPPFLAGS'
1016 ac_compile='${CXX-g++} -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1017 ac_link='${CXX-g++} -o conftest${ac_exeext} $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1018 cross_compiling=$ac_cv_prog_cxx_cross
1019   CXXCPP="${CXX-g++} -E"
1020   cat > conftest.$ac_ext <<EOF
1021 #line 1022 "configure"
1022 #include "confdefs.h"
1023 #include <stdlib.h>
1024 EOF
1025 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1026 { (eval echo configure:1027: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1027 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1028 if test -z "$ac_err"; then
1029   :
1030 else
1031   echo "$ac_err" >&5
1032   echo "configure: failed program was:" >&5
1033   cat conftest.$ac_ext >&5
1034   rm -rf conftest*
1035   CXXCPP=/lib/cpp
1036 fi
1037 rm -f conftest*
1038   ac_cv_prog_CXXCPP="$CXXCPP"
1039 ac_ext=c
1040 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1041 ac_cpp='$CPP $CPPFLAGS'
1042 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1043 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1044 cross_compiling=$ac_cv_prog_cc_cross
1045 fi
1046 fi
1047 CXXCPP="$ac_cv_prog_CXXCPP"
1048 echo "$ac_t""$CXXCPP" 1>&6
1049
1050 # Find a good install program.  We prefer a C program (faster),
1051 # so one script is as good as another.  But avoid the broken or
1052 # incompatible versions:
1053 # SysV /etc/install, /usr/sbin/install
1054 # SunOS /usr/etc/install
1055 # IRIX /sbin/install
1056 # AIX /bin/install
1057 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
1058 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
1059 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
1060 # ./install, which can be erroneously created by make from ./install.sh.
1061 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
1062 echo "configure:1063: checking for a BSD compatible install" >&5
1063 if test -z "$INSTALL"; then
1064 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
1065   echo $ac_n "(cached) $ac_c" 1>&6
1066 else
1067     IFS="${IFS=         }"; ac_save_IFS="$IFS"; IFS=":"
1068   for ac_dir in $PATH; do
1069     # Account for people who put trailing slashes in PATH elements.
1070     case "$ac_dir/" in
1071     /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
1072     *)
1073       # OSF1 and SCO ODT 3.0 have their own names for install.
1074       # Don't use installbsd from OSF since it installs stuff as root
1075       # by default.
1076       for ac_prog in ginstall scoinst install; do
1077         if test -f $ac_dir/$ac_prog; then
1078           if test $ac_prog = install &&
1079             grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
1080             # AIX install.  It has an incompatible calling convention.
1081             :
1082           else
1083             ac_cv_path_install="$ac_dir/$ac_prog -c"
1084             break 2
1085           fi
1086         fi
1087       done
1088       ;;
1089     esac
1090   done
1091   IFS="$ac_save_IFS"
1092
1093 fi
1094   if test "${ac_cv_path_install+set}" = set; then
1095     INSTALL="$ac_cv_path_install"
1096   else
1097     # As a last resort, use the slow shell script.  We don't cache a
1098     # path for INSTALL within a source directory, because that will
1099     # break other packages using the cache if that directory is
1100     # removed, or if the path is relative.
1101     INSTALL="$ac_install_sh"
1102   fi
1103 fi
1104 echo "$ac_t""$INSTALL" 1>&6
1105
1106 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
1107 # It thinks the first close brace ends the variable substitution.
1108 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
1109
1110 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
1111
1112 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
1113
1114 # Check whether --enable-shared or --disable-shared was given.
1115 if test "${enable_shared+set}" = set; then
1116   enableval="$enable_shared"
1117   p=${PACKAGE-default}
1118 case "$enableval" in
1119 yes) enable_shared=yes ;;
1120 no) enable_shared=no ;;
1121 *)
1122   enable_shared=no
1123   # Look at the argument we got.  We use all the common list separators.
1124   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
1125   for pkg in $enableval; do
1126     if test "X$pkg" = "X$p"; then
1127       enable_shared=yes
1128     fi
1129   done
1130   IFS="$ac_save_ifs"
1131   ;;
1132 esac
1133 else
1134   enable_shared=yes
1135 fi
1136
1137 # Check whether --enable-static or --disable-static was given.
1138 if test "${enable_static+set}" = set; then
1139   enableval="$enable_static"
1140   p=${PACKAGE-default}
1141 case "$enableval" in
1142 yes) enable_static=yes ;;
1143 no) enable_static=no ;;
1144 *)
1145   enable_static=no
1146   # Look at the argument we got.  We use all the common list separators.
1147   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
1148   for pkg in $enableval; do
1149     if test "X$pkg" = "X$p"; then
1150       enable_static=yes
1151     fi
1152   done
1153   IFS="$ac_save_ifs"
1154   ;;
1155 esac
1156 else
1157   enable_static=yes
1158 fi
1159
1160 # Check whether --enable-fast-install or --disable-fast-install was given.
1161 if test "${enable_fast_install+set}" = set; then
1162   enableval="$enable_fast_install"
1163   p=${PACKAGE-default}
1164 case "$enableval" in
1165 yes) enable_fast_install=yes ;;
1166 no) enable_fast_install=no ;;
1167 *)
1168   enable_fast_install=no
1169   # Look at the argument we got.  We use all the common list separators.
1170   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
1171   for pkg in $enableval; do
1172     if test "X$pkg" = "X$p"; then
1173       enable_fast_install=yes
1174     fi
1175   done
1176   IFS="$ac_save_ifs"
1177   ;;
1178 esac
1179 else
1180   enable_fast_install=yes
1181 fi
1182
1183
1184 # Make sure we can run config.sub.
1185 if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
1186 else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
1187 fi
1188
1189 echo $ac_n "checking host system type""... $ac_c" 1>&6
1190 echo "configure:1191: checking host system type" >&5
1191
1192 host_alias=$host
1193 case "$host_alias" in
1194 NONE)
1195   case $nonopt in
1196   NONE)
1197     if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
1198     else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
1199     fi ;;
1200   *) host_alias=$nonopt ;;
1201   esac ;;
1202 esac
1203
1204 host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
1205 host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1206 host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1207 host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1208 echo "$ac_t""$host" 1>&6
1209
1210 echo $ac_n "checking build system type""... $ac_c" 1>&6
1211 echo "configure:1212: checking build system type" >&5
1212
1213 build_alias=$build
1214 case "$build_alias" in
1215 NONE)
1216   case $nonopt in
1217   NONE) build_alias=$host_alias ;;
1218   *) build_alias=$nonopt ;;
1219   esac ;;
1220 esac
1221
1222 build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias`
1223 build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1224 build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1225 build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1226 echo "$ac_t""$build" 1>&6
1227
1228 # Extract the first word of "ranlib", so it can be a program name with args.
1229 set dummy ranlib; ac_word=$2
1230 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1231 echo "configure:1232: checking for $ac_word" >&5
1232 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
1233   echo $ac_n "(cached) $ac_c" 1>&6
1234 else
1235   if test -n "$RANLIB"; then
1236   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1237 else
1238   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1239   ac_dummy="$PATH"
1240   for ac_dir in $ac_dummy; do
1241     test -z "$ac_dir" && ac_dir=.
1242     if test -f $ac_dir/$ac_word; then
1243       ac_cv_prog_RANLIB="ranlib"
1244       break
1245     fi
1246   done
1247   IFS="$ac_save_ifs"
1248   test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
1249 fi
1250 fi
1251 RANLIB="$ac_cv_prog_RANLIB"
1252 if test -n "$RANLIB"; then
1253   echo "$ac_t""$RANLIB" 1>&6
1254 else
1255   echo "$ac_t""no" 1>&6
1256 fi
1257
1258 # Extract the first word of "gcc", so it can be a program name with args.
1259 set dummy gcc; ac_word=$2
1260 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1261 echo "configure:1262: checking for $ac_word" >&5
1262 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
1263   echo $ac_n "(cached) $ac_c" 1>&6
1264 else
1265   if test -n "$CC"; then
1266   ac_cv_prog_CC="$CC" # Let the user override the test.
1267 else
1268   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1269   ac_dummy="$PATH"
1270   for ac_dir in $ac_dummy; do
1271     test -z "$ac_dir" && ac_dir=.
1272     if test -f $ac_dir/$ac_word; then
1273       ac_cv_prog_CC="gcc"
1274       break
1275     fi
1276   done
1277   IFS="$ac_save_ifs"
1278 fi
1279 fi
1280 CC="$ac_cv_prog_CC"
1281 if test -n "$CC"; then
1282   echo "$ac_t""$CC" 1>&6
1283 else
1284   echo "$ac_t""no" 1>&6
1285 fi
1286
1287 if test -z "$CC"; then
1288   # Extract the first word of "cc", so it can be a program name with args.
1289 set dummy cc; ac_word=$2
1290 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1291 echo "configure:1292: checking for $ac_word" >&5
1292 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
1293   echo $ac_n "(cached) $ac_c" 1>&6
1294 else
1295   if test -n "$CC"; then
1296   ac_cv_prog_CC="$CC" # Let the user override the test.
1297 else
1298   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1299   ac_prog_rejected=no
1300   ac_dummy="$PATH"
1301   for ac_dir in $ac_dummy; do
1302     test -z "$ac_dir" && ac_dir=.
1303     if test -f $ac_dir/$ac_word; then
1304       if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
1305         ac_prog_rejected=yes
1306         continue
1307       fi
1308       ac_cv_prog_CC="cc"
1309       break
1310     fi
1311   done
1312   IFS="$ac_save_ifs"
1313 if test $ac_prog_rejected = yes; then
1314   # We found a bogon in the path, so make sure we never use it.
1315   set dummy $ac_cv_prog_CC
1316   shift
1317   if test $# -gt 0; then
1318     # We chose a different compiler from the bogus one.
1319     # However, it has the same basename, so the bogon will be chosen
1320     # first if we set CC to just the basename; use the full file name.
1321     shift
1322     set dummy "$ac_dir/$ac_word" "$@"
1323     shift
1324     ac_cv_prog_CC="$@"
1325   fi
1326 fi
1327 fi
1328 fi
1329 CC="$ac_cv_prog_CC"
1330 if test -n "$CC"; then
1331   echo "$ac_t""$CC" 1>&6
1332 else
1333   echo "$ac_t""no" 1>&6
1334 fi
1335
1336   if test -z "$CC"; then
1337     case "`uname -s`" in
1338     *win32* | *WIN32*)
1339       # Extract the first word of "cl", so it can be a program name with args.
1340 set dummy cl; ac_word=$2
1341 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1342 echo "configure:1343: checking for $ac_word" >&5
1343 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
1344   echo $ac_n "(cached) $ac_c" 1>&6
1345 else
1346   if test -n "$CC"; then
1347   ac_cv_prog_CC="$CC" # Let the user override the test.
1348 else
1349   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1350   ac_dummy="$PATH"
1351   for ac_dir in $ac_dummy; do
1352     test -z "$ac_dir" && ac_dir=.
1353     if test -f $ac_dir/$ac_word; then
1354       ac_cv_prog_CC="cl"
1355       break
1356     fi
1357   done
1358   IFS="$ac_save_ifs"
1359 fi
1360 fi
1361 CC="$ac_cv_prog_CC"
1362 if test -n "$CC"; then
1363   echo "$ac_t""$CC" 1>&6
1364 else
1365   echo "$ac_t""no" 1>&6
1366 fi
1367  ;;
1368     esac
1369   fi
1370   test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
1371 fi
1372
1373 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
1374 echo "configure:1375: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
1375
1376 ac_ext=c
1377 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1378 ac_cpp='$CPP $CPPFLAGS'
1379 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1380 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1381 cross_compiling=$ac_cv_prog_cc_cross
1382
1383 cat > conftest.$ac_ext << EOF
1384
1385 #line 1386 "configure"
1386 #include "confdefs.h"
1387
1388 main(){return(0);}
1389 EOF
1390 if { (eval echo configure:1391: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1391   ac_cv_prog_cc_works=yes
1392   # If we can't run a trivial program, we are probably using a cross compiler.
1393   if (./conftest; exit) 2>/dev/null; then
1394     ac_cv_prog_cc_cross=no
1395   else
1396     ac_cv_prog_cc_cross=yes
1397   fi
1398 else
1399   echo "configure: failed program was:" >&5
1400   cat conftest.$ac_ext >&5
1401   ac_cv_prog_cc_works=no
1402 fi
1403 rm -fr conftest*
1404 ac_ext=c
1405 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1406 ac_cpp='$CPP $CPPFLAGS'
1407 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1408 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1409 cross_compiling=$ac_cv_prog_cc_cross
1410
1411 echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
1412 if test $ac_cv_prog_cc_works = no; then
1413   { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
1414 fi
1415 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
1416 echo "configure:1417: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
1417 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
1418 cross_compiling=$ac_cv_prog_cc_cross
1419
1420 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
1421 echo "configure:1422: checking whether we are using GNU C" >&5
1422 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
1423   echo $ac_n "(cached) $ac_c" 1>&6
1424 else
1425   cat > conftest.c <<EOF
1426 #ifdef __GNUC__
1427   yes;
1428 #endif
1429 EOF
1430 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1431: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
1431   ac_cv_prog_gcc=yes
1432 else
1433   ac_cv_prog_gcc=no
1434 fi
1435 fi
1436
1437 echo "$ac_t""$ac_cv_prog_gcc" 1>&6
1438
1439 if test $ac_cv_prog_gcc = yes; then
1440   GCC=yes
1441 else
1442   GCC=
1443 fi
1444
1445 ac_test_CFLAGS="${CFLAGS+set}"
1446 ac_save_CFLAGS="$CFLAGS"
1447 CFLAGS=
1448 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
1449 echo "configure:1450: checking whether ${CC-cc} accepts -g" >&5
1450 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
1451   echo $ac_n "(cached) $ac_c" 1>&6
1452 else
1453   echo 'void f(){}' > conftest.c
1454 if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
1455   ac_cv_prog_cc_g=yes
1456 else
1457   ac_cv_prog_cc_g=no
1458 fi
1459 rm -f conftest*
1460
1461 fi
1462
1463 echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
1464 if test "$ac_test_CFLAGS" = set; then
1465   CFLAGS="$ac_save_CFLAGS"
1466 elif test $ac_cv_prog_cc_g = yes; then
1467   if test "$GCC" = yes; then
1468     CFLAGS="-g -O2"
1469   else
1470     CFLAGS="-g"
1471   fi
1472 else
1473   if test "$GCC" = yes; then
1474     CFLAGS="-O2"
1475   else
1476     CFLAGS=
1477   fi
1478 fi
1479
1480 # Check whether --with-gnu-ld or --without-gnu-ld was given.
1481 if test "${with_gnu_ld+set}" = set; then
1482   withval="$with_gnu_ld"
1483   test "$withval" = no || with_gnu_ld=yes
1484 else
1485   with_gnu_ld=no
1486 fi
1487
1488 ac_prog=ld
1489 if test "$ac_cv_prog_gcc" = yes; then
1490   # Check if gcc -print-prog-name=ld gives a path.
1491   echo $ac_n "checking for ld used by GCC""... $ac_c" 1>&6
1492 echo "configure:1493: checking for ld used by GCC" >&5
1493   ac_prog=`($CC -print-prog-name=ld) 2>&5`
1494   case "$ac_prog" in
1495     # Accept absolute paths.
1496     [\\/]* | [A-Za-z]:[\\/]*)
1497       re_direlt='/[^/][^/]*/\.\./'
1498       # Canonicalize the path of ld
1499       ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
1500       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
1501         ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
1502       done
1503       test -z "$LD" && LD="$ac_prog"
1504       ;;
1505   "")
1506     # If it fails, then pretend we aren't using GCC.
1507     ac_prog=ld
1508     ;;
1509   *)
1510     # If it is relative, then search for the first ld in PATH.
1511     with_gnu_ld=unknown
1512     ;;
1513   esac
1514 elif test "$with_gnu_ld" = yes; then
1515   echo $ac_n "checking for GNU ld""... $ac_c" 1>&6
1516 echo "configure:1517: checking for GNU ld" >&5
1517 else
1518   echo $ac_n "checking for non-GNU ld""... $ac_c" 1>&6
1519 echo "configure:1520: checking for non-GNU ld" >&5
1520 fi
1521 if eval "test \"`echo '$''{'ac_cv_path_LD'+set}'`\" = set"; then
1522   echo $ac_n "(cached) $ac_c" 1>&6
1523 else
1524   if test -z "$LD"; then
1525   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
1526   for ac_dir in $PATH; do
1527     test -z "$ac_dir" && ac_dir=.
1528     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
1529       ac_cv_path_LD="$ac_dir/$ac_prog"
1530       # Check to see if the program is GNU ld.  I'd rather use --version,
1531       # but apparently some GNU ld's only accept -v.
1532       # Break only if it was the GNU/non-GNU ld that we prefer.
1533       if "$ac_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
1534         test "$with_gnu_ld" != no && break
1535       else
1536         test "$with_gnu_ld" != yes && break
1537       fi
1538     fi
1539   done
1540   IFS="$ac_save_ifs"
1541 else
1542   ac_cv_path_LD="$LD" # Let the user override the test with a path.
1543 fi
1544 fi
1545
1546 LD="$ac_cv_path_LD"
1547 if test -n "$LD"; then
1548   echo "$ac_t""$LD" 1>&6
1549 else
1550   echo "$ac_t""no" 1>&6
1551 fi
1552 test -z "$LD" && { echo "configure: error: no acceptable ld found in \$PATH" 1>&2; exit 1; }
1553
1554 echo $ac_n "checking if the linker ($LD) is GNU ld""... $ac_c" 1>&6
1555 echo "configure:1556: checking if the linker ($LD) is GNU ld" >&5
1556 if eval "test \"`echo '$''{'ac_cv_prog_gnu_ld'+set}'`\" = set"; then
1557   echo $ac_n "(cached) $ac_c" 1>&6
1558 else
1559   # I'd rather use --version here, but apparently some GNU ld's only accept -v.
1560 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
1561   ac_cv_prog_gnu_ld=yes
1562 else
1563   ac_cv_prog_gnu_ld=no
1564 fi
1565 fi
1566
1567 echo "$ac_t""$ac_cv_prog_gnu_ld" 1>&6
1568
1569
1570 echo $ac_n "checking for BSD-compatible nm""... $ac_c" 1>&6
1571 echo "configure:1572: checking for BSD-compatible nm" >&5
1572 if eval "test \"`echo '$''{'ac_cv_path_NM'+set}'`\" = set"; then
1573   echo $ac_n "(cached) $ac_c" 1>&6
1574 else
1575   if test -n "$NM"; then
1576   # Let the user override the test.
1577   ac_cv_path_NM="$NM"
1578 else
1579   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
1580   for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do
1581     test -z "$ac_dir" && ac_dir=.
1582     if test -f $ac_dir/nm || test -f $ac_dir/nm$ac_exeext ; then
1583       # Check to see if the nm accepts a BSD-compat flag.
1584       # Adding the `sed 1q' prevents false positives on HP-UX, which says:
1585       #   nm: unknown option "B" ignored
1586       if ($ac_dir/nm -B /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then
1587         ac_cv_path_NM="$ac_dir/nm -B"
1588         break
1589       elif ($ac_dir/nm -p /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then
1590         ac_cv_path_NM="$ac_dir/nm -p"
1591         break
1592       else
1593         ac_cv_path_NM=${ac_cv_path_NM="$ac_dir/nm"} # keep the first match, but
1594         continue # so that we can try to find one that supports BSD flags
1595       fi
1596     fi
1597   done
1598   IFS="$ac_save_ifs"
1599   test -z "$ac_cv_path_NM" && ac_cv_path_NM=nm
1600 fi
1601 fi
1602
1603 NM="$ac_cv_path_NM"
1604 echo "$ac_t""$NM" 1>&6
1605
1606
1607 echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
1608 echo "configure:1609: checking whether ln -s works" >&5
1609 if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
1610   echo $ac_n "(cached) $ac_c" 1>&6
1611 else
1612   rm -f conftestdata
1613 if ln -s X conftestdata 2>/dev/null
1614 then
1615   rm -f conftestdata
1616   ac_cv_prog_LN_S="ln -s"
1617 else
1618   ac_cv_prog_LN_S=ln
1619 fi
1620 fi
1621 LN_S="$ac_cv_prog_LN_S"
1622 if test "$ac_cv_prog_LN_S" = "ln -s"; then
1623   echo "$ac_t""yes" 1>&6
1624 else
1625   echo "$ac_t""no" 1>&6
1626 fi
1627
1628
1629 # Check for any special flags to pass to ltconfig.
1630 libtool_flags="--cache-file=$cache_file"
1631 test "$enable_shared" = no && libtool_flags="$libtool_flags --disable-shared"
1632 test "$enable_static" = no && libtool_flags="$libtool_flags --disable-static"
1633 test "$enable_fast_install" = no && libtool_flags="$libtool_flags --disable-fast-install"
1634 test "$ac_cv_prog_gcc" = yes && libtool_flags="$libtool_flags --with-gcc"
1635 test "$ac_cv_prog_gnu_ld" = yes && libtool_flags="$libtool_flags --with-gnu-ld"
1636
1637
1638 # Check whether --enable-libtool-lock or --disable-libtool-lock was given.
1639 if test "${enable_libtool_lock+set}" = set; then
1640   enableval="$enable_libtool_lock"
1641   :
1642 fi
1643
1644 test "x$enable_libtool_lock" = xno && libtool_flags="$libtool_flags --disable-lock"
1645 test x"$silent" = xyes && libtool_flags="$libtool_flags --silent"
1646
1647 # Some flags need to be propagated to the compiler or linker for good
1648 # libtool support.
1649 case "$host" in
1650 *-*-irix6*)
1651   # Find out which ABI we are using.
1652   echo '#line 1653 "configure"' > conftest.$ac_ext
1653   if { (eval echo configure:1654: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1654     case "`/usr/bin/file conftest.o`" in
1655     *32-bit*)
1656       LD="${LD-ld} -32"
1657       ;;
1658     *N32*)
1659       LD="${LD-ld} -n32"
1660       ;;
1661     *64-bit*)
1662       LD="${LD-ld} -64"
1663       ;;
1664     esac
1665   fi
1666   rm -rf conftest*
1667   ;;
1668
1669 *-*-sco3.2v5*)
1670   # On SCO OpenServer 5, we need -belf to get full-featured binaries.
1671   SAVE_CFLAGS="$CFLAGS"
1672   CFLAGS="$CFLAGS -belf"
1673   echo $ac_n "checking whether the C compiler needs -belf""... $ac_c" 1>&6
1674 echo "configure:1675: checking whether the C compiler needs -belf" >&5
1675 if eval "test \"`echo '$''{'lt_cv_cc_needs_belf'+set}'`\" = set"; then
1676   echo $ac_n "(cached) $ac_c" 1>&6
1677 else
1678   
1679      ac_ext=c
1680 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1681 ac_cpp='$CPP $CPPFLAGS'
1682 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1683 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1684 cross_compiling=$ac_cv_prog_cc_cross
1685
1686      cat > conftest.$ac_ext <<EOF
1687 #line 1688 "configure"
1688 #include "confdefs.h"
1689
1690 int main() {
1691
1692 ; return 0; }
1693 EOF
1694 if { (eval echo configure:1695: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1695   rm -rf conftest*
1696   lt_cv_cc_needs_belf=yes
1697 else
1698   echo "configure: failed program was:" >&5
1699   cat conftest.$ac_ext >&5
1700   rm -rf conftest*
1701   lt_cv_cc_needs_belf=no
1702 fi
1703 rm -f conftest*
1704      ac_ext=c
1705 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1706 ac_cpp='$CPP $CPPFLAGS'
1707 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1708 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1709 cross_compiling=$ac_cv_prog_cc_cross
1710
1711 fi
1712
1713 echo "$ac_t""$lt_cv_cc_needs_belf" 1>&6
1714   if test x"$lt_cv_cc_needs_belf" != x"yes"; then
1715     # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
1716     CFLAGS="$SAVE_CFLAGS"
1717   fi
1718   ;;
1719
1720
1721 esac
1722
1723
1724 # Save cache, so that ltconfig can load it
1725 cat > confcache <<\EOF
1726 # This file is a shell script that caches the results of configure
1727 # tests run on this system so they can be shared between configure
1728 # scripts and configure runs.  It is not useful on other systems.
1729 # If it contains results you don't want to keep, you may remove or edit it.
1730 #
1731 # By default, configure uses ./config.cache as the cache file,
1732 # creating it if it does not exist already.  You can give configure
1733 # the --cache-file=FILE option to use a different cache file; that is
1734 # what configure does when it calls configure scripts in
1735 # subdirectories, so they share the cache.
1736 # Giving --cache-file=/dev/null disables caching, for debugging configure.
1737 # config.status only pays attention to the cache file if you give it the
1738 # --recheck option to rerun configure.
1739 #
1740 EOF
1741 # The following way of writing the cache mishandles newlines in values,
1742 # but we know of no workaround that is simple, portable, and efficient.
1743 # So, don't put newlines in cache variables' values.
1744 # Ultrix sh set writes to stderr and can't be redirected directly,
1745 # and sets the high bit in the cache file unless we assign to the vars.
1746 (set) 2>&1 |
1747   case `(ac_space=' '; set | grep ac_space) 2>&1` in
1748   *ac_space=\ *)
1749     # `set' does not quote correctly, so add quotes (double-quote substitution
1750     # turns \\\\ into \\, and sed turns \\ into \).
1751     sed -n \
1752       -e "s/'/'\\\\''/g" \
1753       -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
1754     ;;
1755   *)
1756     # `set' quotes correctly as required by POSIX, so do not add quotes.
1757     sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
1758     ;;
1759   esac >> confcache
1760 if cmp -s $cache_file confcache; then
1761   :
1762 else
1763   if test -w $cache_file; then
1764     echo "updating cache $cache_file"
1765     cat confcache > $cache_file
1766   else
1767     echo "not updating unwritable cache $cache_file"
1768   fi
1769 fi
1770 rm -f confcache
1771
1772
1773 # Actually configure libtool.  ac_aux_dir is where install-sh is found.
1774 CC="$CC" CFLAGS="$CFLAGS" CPPFLAGS="$CPPFLAGS" \
1775 LD="$LD" LDFLAGS="$LDFLAGS" LIBS="$LIBS" \
1776 LN_S="$LN_S" NM="$NM" RANLIB="$RANLIB" \
1777 DLLTOOL="$DLLTOOL" AS="$AS" OBJDUMP="$OBJDUMP" \
1778 ${CONFIG_SHELL-/bin/sh} $ac_aux_dir/ltconfig --no-reexec \
1779 $libtool_flags --no-verify $ac_aux_dir/ltmain.sh $host \
1780 || { echo "configure: error: libtool configure failed" 1>&2; exit 1; }
1781
1782 # Reload cache, that may have been modified by ltconfig
1783 if test -r "$cache_file"; then
1784   echo "loading cache $cache_file"
1785   . $cache_file
1786 else
1787   echo "creating cache $cache_file"
1788   > $cache_file
1789 fi
1790
1791
1792 # This can be used to rebuild libtool when needed
1793 LIBTOOL_DEPS="$ac_aux_dir/ltconfig $ac_aux_dir/ltmain.sh"
1794
1795 # Always use our own libtool.
1796 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
1797
1798 # Redirect the config.log output again, so that the ltconfig log is not
1799 # clobbered by the next message.
1800 exec 5>>./config.log
1801
1802 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
1803 echo "configure:1804: checking how to run the C preprocessor" >&5
1804 # On Suns, sometimes $CPP names a directory.
1805 if test -n "$CPP" && test -d "$CPP"; then
1806   CPP=
1807 fi
1808 if test -z "$CPP"; then
1809 if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
1810   echo $ac_n "(cached) $ac_c" 1>&6
1811 else
1812     # This must be in double quotes, not single quotes, because CPP may get
1813   # substituted into the Makefile and "${CC-cc}" will confuse make.
1814   CPP="${CC-cc} -E"
1815   # On the NeXT, cc -E runs the code through the compiler's parser,
1816   # not just through cpp.
1817   cat > conftest.$ac_ext <<EOF
1818 #line 1819 "configure"
1819 #include "confdefs.h"
1820 #include <assert.h>
1821 Syntax Error
1822 EOF
1823 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1824 { (eval echo configure:1825: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1825 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1826 if test -z "$ac_err"; then
1827   :
1828 else
1829   echo "$ac_err" >&5
1830   echo "configure: failed program was:" >&5
1831   cat conftest.$ac_ext >&5
1832   rm -rf conftest*
1833   CPP="${CC-cc} -E -traditional-cpp"
1834   cat > conftest.$ac_ext <<EOF
1835 #line 1836 "configure"
1836 #include "confdefs.h"
1837 #include <assert.h>
1838 Syntax Error
1839 EOF
1840 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1841 { (eval echo configure:1842: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1842 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1843 if test -z "$ac_err"; then
1844   :
1845 else
1846   echo "$ac_err" >&5
1847   echo "configure: failed program was:" >&5
1848   cat conftest.$ac_ext >&5
1849   rm -rf conftest*
1850   CPP="${CC-cc} -nologo -E"
1851   cat > conftest.$ac_ext <<EOF
1852 #line 1853 "configure"
1853 #include "confdefs.h"
1854 #include <assert.h>
1855 Syntax Error
1856 EOF
1857 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1858 { (eval echo configure:1859: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1859 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1860 if test -z "$ac_err"; then
1861   :
1862 else
1863   echo "$ac_err" >&5
1864   echo "configure: failed program was:" >&5
1865   cat conftest.$ac_ext >&5
1866   rm -rf conftest*
1867   CPP=/lib/cpp
1868 fi
1869 rm -f conftest*
1870 fi
1871 rm -f conftest*
1872 fi
1873 rm -f conftest*
1874   ac_cv_prog_CPP="$CPP"
1875 fi
1876   CPP="$ac_cv_prog_CPP"
1877 else
1878   ac_cv_prog_CPP="$CPP"
1879 fi
1880 echo "$ac_t""$CPP" 1>&6
1881
1882 missing_dir=`cd $ac_aux_dir && pwd`
1883 for ac_prog in flex lex
1884 do
1885 # Extract the first word of "$ac_prog", so it can be a program name with args.
1886 set dummy $ac_prog; ac_word=$2
1887 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1888 echo "configure:1889: checking for $ac_word" >&5
1889 if eval "test \"`echo '$''{'ac_cv_prog_LEX'+set}'`\" = set"; then
1890   echo $ac_n "(cached) $ac_c" 1>&6
1891 else
1892   if test -n "$LEX"; then
1893   ac_cv_prog_LEX="$LEX" # Let the user override the test.
1894 else
1895   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1896   ac_dummy="$PATH"
1897   for ac_dir in $ac_dummy; do
1898     test -z "$ac_dir" && ac_dir=.
1899     if test -f $ac_dir/$ac_word; then
1900       ac_cv_prog_LEX="$ac_prog"
1901       break
1902     fi
1903   done
1904   IFS="$ac_save_ifs"
1905 fi
1906 fi
1907 LEX="$ac_cv_prog_LEX"
1908 if test -n "$LEX"; then
1909   echo "$ac_t""$LEX" 1>&6
1910 else
1911   echo "$ac_t""no" 1>&6
1912 fi
1913
1914 test -n "$LEX" && break
1915 done
1916 test -n "$LEX" || LEX=""$missing_dir/missing flex""
1917
1918 # Extract the first word of "flex", so it can be a program name with args.
1919 set dummy flex; ac_word=$2
1920 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1921 echo "configure:1922: checking for $ac_word" >&5
1922 if eval "test \"`echo '$''{'ac_cv_prog_LEX'+set}'`\" = set"; then
1923   echo $ac_n "(cached) $ac_c" 1>&6
1924 else
1925   if test -n "$LEX"; then
1926   ac_cv_prog_LEX="$LEX" # Let the user override the test.
1927 else
1928   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1929   ac_dummy="$PATH"
1930   for ac_dir in $ac_dummy; do
1931     test -z "$ac_dir" && ac_dir=.
1932     if test -f $ac_dir/$ac_word; then
1933       ac_cv_prog_LEX="flex"
1934       break
1935     fi
1936   done
1937   IFS="$ac_save_ifs"
1938   test -z "$ac_cv_prog_LEX" && ac_cv_prog_LEX="lex"
1939 fi
1940 fi
1941 LEX="$ac_cv_prog_LEX"
1942 if test -n "$LEX"; then
1943   echo "$ac_t""$LEX" 1>&6
1944 else
1945   echo "$ac_t""no" 1>&6
1946 fi
1947
1948 if test -z "$LEXLIB"
1949 then
1950   case "$LEX" in
1951   flex*) ac_lib=fl ;;
1952   *) ac_lib=l ;;
1953   esac
1954   echo $ac_n "checking for yywrap in -l$ac_lib""... $ac_c" 1>&6
1955 echo "configure:1956: checking for yywrap in -l$ac_lib" >&5
1956 ac_lib_var=`echo $ac_lib'_'yywrap | sed 'y%./+-%__p_%'`
1957 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1958   echo $ac_n "(cached) $ac_c" 1>&6
1959 else
1960   ac_save_LIBS="$LIBS"
1961 LIBS="-l$ac_lib  $LIBS"
1962 cat > conftest.$ac_ext <<EOF
1963 #line 1964 "configure"
1964 #include "confdefs.h"
1965 /* Override any gcc2 internal prototype to avoid an error.  */
1966 /* We use char because int might match the return type of a gcc2
1967     builtin and then its argument prototype would still apply.  */
1968 char yywrap();
1969
1970 int main() {
1971 yywrap()
1972 ; return 0; }
1973 EOF
1974 if { (eval echo configure:1975: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1975   rm -rf conftest*
1976   eval "ac_cv_lib_$ac_lib_var=yes"
1977 else
1978   echo "configure: failed program was:" >&5
1979   cat conftest.$ac_ext >&5
1980   rm -rf conftest*
1981   eval "ac_cv_lib_$ac_lib_var=no"
1982 fi
1983 rm -f conftest*
1984 LIBS="$ac_save_LIBS"
1985
1986 fi
1987 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1988   echo "$ac_t""yes" 1>&6
1989   LEXLIB="-l$ac_lib"
1990 else
1991   echo "$ac_t""no" 1>&6
1992 fi
1993
1994 fi
1995
1996 echo $ac_n "checking lex output file root""... $ac_c" 1>&6
1997 echo "configure:1998: checking lex output file root" >&5
1998 if eval "test \"`echo '$''{'ac_cv_prog_lex_root'+set}'`\" = set"; then
1999   echo $ac_n "(cached) $ac_c" 1>&6
2000 else
2001   # The minimal lex program is just a single line: %%.  But some broken lexes
2002 # (Solaris, I think it was) want two %% lines, so accommodate them.
2003 echo '%%
2004 %%' | $LEX
2005 if test -f lex.yy.c; then
2006   ac_cv_prog_lex_root=lex.yy
2007 elif test -f lexyy.c; then
2008   ac_cv_prog_lex_root=lexyy
2009 else
2010   { echo "configure: error: cannot find output from $LEX; giving up" 1>&2; exit 1; }
2011 fi
2012 fi
2013
2014 echo "$ac_t""$ac_cv_prog_lex_root" 1>&6
2015 LEX_OUTPUT_ROOT=$ac_cv_prog_lex_root
2016
2017 echo $ac_n "checking whether yytext is a pointer""... $ac_c" 1>&6
2018 echo "configure:2019: checking whether yytext is a pointer" >&5
2019 if eval "test \"`echo '$''{'ac_cv_prog_lex_yytext_pointer'+set}'`\" = set"; then
2020   echo $ac_n "(cached) $ac_c" 1>&6
2021 else
2022   # POSIX says lex can declare yytext either as a pointer or an array; the
2023 # default is implementation-dependent. Figure out which it is, since
2024 # not all implementations provide the %pointer and %array declarations.
2025 ac_cv_prog_lex_yytext_pointer=no
2026 echo 'extern char *yytext;' >>$LEX_OUTPUT_ROOT.c
2027 ac_save_LIBS="$LIBS"
2028 LIBS="$LIBS $LEXLIB"
2029 cat > conftest.$ac_ext <<EOF
2030 #line 2031 "configure"
2031 #include "confdefs.h"
2032 `cat $LEX_OUTPUT_ROOT.c`
2033 int main() {
2034
2035 ; return 0; }
2036 EOF
2037 if { (eval echo configure:2038: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2038   rm -rf conftest*
2039   ac_cv_prog_lex_yytext_pointer=yes
2040 else
2041   echo "configure: failed program was:" >&5
2042   cat conftest.$ac_ext >&5
2043 fi
2044 rm -f conftest*
2045 LIBS="$ac_save_LIBS"
2046 rm -f "${LEX_OUTPUT_ROOT}.c"
2047
2048 fi
2049
2050 echo "$ac_t""$ac_cv_prog_lex_yytext_pointer" 1>&6
2051 if test $ac_cv_prog_lex_yytext_pointer = yes; then
2052   cat >> confdefs.h <<\EOF
2053 #define YYTEXT_POINTER 1
2054 EOF
2055
2056 fi
2057
2058 for ac_prog in 'bison -y' byacc
2059 do
2060 # Extract the first word of "$ac_prog", so it can be a program name with args.
2061 set dummy $ac_prog; ac_word=$2
2062 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2063 echo "configure:2064: checking for $ac_word" >&5
2064 if eval "test \"`echo '$''{'ac_cv_prog_YACC'+set}'`\" = set"; then
2065   echo $ac_n "(cached) $ac_c" 1>&6
2066 else
2067   if test -n "$YACC"; then
2068   ac_cv_prog_YACC="$YACC" # Let the user override the test.
2069 else
2070   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
2071   ac_dummy="$PATH"
2072   for ac_dir in $ac_dummy; do
2073     test -z "$ac_dir" && ac_dir=.
2074     if test -f $ac_dir/$ac_word; then
2075       ac_cv_prog_YACC="$ac_prog"
2076       break
2077     fi
2078   done
2079   IFS="$ac_save_ifs"
2080 fi
2081 fi
2082 YACC="$ac_cv_prog_YACC"
2083 if test -n "$YACC"; then
2084   echo "$ac_t""$YACC" 1>&6
2085 else
2086   echo "$ac_t""no" 1>&6
2087 fi
2088
2089 test -n "$YACC" && break
2090 done
2091 test -n "$YACC" || YACC="yacc"
2092
2093
2094 # Check whether --enable-html-doc or --disable-html-doc was given.
2095 if test "${enable_html_doc+set}" = set; then
2096   enableval="$enable_html_doc"
2097   :
2098 else
2099   enable_html_doc=no
2100 fi
2101
2102 # Check whether --enable-ps-doc or --disable-ps-doc was given.
2103 if test "${enable_ps_doc+set}" = set; then
2104   enableval="$enable_ps_doc"
2105   :
2106 else
2107   enable_ps_doc=no
2108 fi
2109
2110 # Check whether --with-cint or --without-cint was given.
2111 if test "${with_cint+set}" = set; then
2112   withval="$with_cint"
2113   :
2114 else
2115   with_cint=no
2116 fi
2117
2118
2119 echo $ac_n "checking size of long""... $ac_c" 1>&6
2120 echo "configure:2121: checking size of long" >&5
2121 if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then
2122   echo $ac_n "(cached) $ac_c" 1>&6
2123 else
2124   if test "$cross_compiling" = yes; then
2125   ac_cv_sizeof_long=4
2126 else
2127   cat > conftest.$ac_ext <<EOF
2128 #line 2129 "configure"
2129 #include "confdefs.h"
2130 #include <stdio.h>
2131 main()
2132 {
2133   FILE *f=fopen("conftestval", "w");
2134   if (!f) exit(1);
2135   fprintf(f, "%d\n", sizeof(long));
2136   exit(0);
2137 }
2138 EOF
2139 if { (eval echo configure:2140: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2140 then
2141   ac_cv_sizeof_long=`cat conftestval`
2142 else
2143   echo "configure: failed program was:" >&5
2144   cat conftest.$ac_ext >&5
2145   rm -fr conftest*
2146   ac_cv_sizeof_long=0
2147 fi
2148 rm -fr conftest*
2149 fi
2150
2151 fi
2152 echo "$ac_t""$ac_cv_sizeof_long" 1>&6
2153 cat >> confdefs.h <<EOF
2154 #define SIZEOF_LONG $ac_cv_sizeof_long
2155 EOF
2156
2157
2158 echo $ac_n "checking size of long long""... $ac_c" 1>&6
2159 echo "configure:2160: checking size of long long" >&5
2160 if eval "test \"`echo '$''{'ac_cv_sizeof_long_long'+set}'`\" = set"; then
2161   echo $ac_n "(cached) $ac_c" 1>&6
2162 else
2163   if test "$cross_compiling" = yes; then
2164   ac_cv_sizeof_long_long=8
2165 else
2166   cat > conftest.$ac_ext <<EOF
2167 #line 2168 "configure"
2168 #include "confdefs.h"
2169 #include <stdio.h>
2170 main()
2171 {
2172   FILE *f=fopen("conftestval", "w");
2173   if (!f) exit(1);
2174   fprintf(f, "%d\n", sizeof(long long));
2175   exit(0);
2176 }
2177 EOF
2178 if { (eval echo configure:2179: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2179 then
2180   ac_cv_sizeof_long_long=`cat conftestval`
2181 else
2182   echo "configure: failed program was:" >&5
2183   cat conftest.$ac_ext >&5
2184   rm -fr conftest*
2185   ac_cv_sizeof_long_long=0
2186 fi
2187 rm -fr conftest*
2188 fi
2189
2190 fi
2191 echo "$ac_t""$ac_cv_sizeof_long_long" 1>&6
2192 cat >> confdefs.h <<EOF
2193 #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
2194 EOF
2195
2196
2197 echo $ac_n "checking size of long double""... $ac_c" 1>&6
2198 echo "configure:2199: checking size of long double" >&5
2199 if eval "test \"`echo '$''{'ac_cv_sizeof_long_double'+set}'`\" = set"; then
2200   echo $ac_n "(cached) $ac_c" 1>&6
2201 else
2202   if test "$cross_compiling" = yes; then
2203   ac_cv_sizeof_long_double=12
2204 else
2205   cat > conftest.$ac_ext <<EOF
2206 #line 2207 "configure"
2207 #include "confdefs.h"
2208 #include <stdio.h>
2209 main()
2210 {
2211   FILE *f=fopen("conftestval", "w");
2212   if (!f) exit(1);
2213   fprintf(f, "%d\n", sizeof(long double));
2214   exit(0);
2215 }
2216 EOF
2217 if { (eval echo configure:2218: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2218 then
2219   ac_cv_sizeof_long_double=`cat conftestval`
2220 else
2221   echo "configure: failed program was:" >&5
2222   cat conftest.$ac_ext >&5
2223   rm -fr conftest*
2224   ac_cv_sizeof_long_double=0
2225 fi
2226 rm -fr conftest*
2227 fi
2228
2229 fi
2230 echo "$ac_t""$ac_cv_sizeof_long_double" 1>&6
2231 cat >> confdefs.h <<EOF
2232 #define SIZEOF_LONG_DOUBLE $ac_cv_sizeof_long_double
2233 EOF
2234
2235
2236
2237 ac_ext=C
2238 # CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2239 ac_cpp='$CXXCPP $CPPFLAGS'
2240 ac_compile='${CXX-g++} -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2241 ac_link='${CXX-g++} -o conftest${ac_exeext} $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2242 cross_compiling=$ac_cv_prog_cxx_cross
2243
2244
2245 for ac_hdr in unistd.h
2246 do
2247 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2248 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2249 echo "configure:2250: checking for $ac_hdr" >&5
2250 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2251   echo $ac_n "(cached) $ac_c" 1>&6
2252 else
2253   cat > conftest.$ac_ext <<EOF
2254 #line 2255 "configure"
2255 #include "confdefs.h"
2256 #include <$ac_hdr>
2257 EOF
2258 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2259 { (eval echo configure:2260: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2260 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2261 if test -z "$ac_err"; then
2262   rm -rf conftest*
2263   eval "ac_cv_header_$ac_safe=yes"
2264 else
2265   echo "$ac_err" >&5
2266   echo "configure: failed program was:" >&5
2267   cat conftest.$ac_ext >&5
2268   rm -rf conftest*
2269   eval "ac_cv_header_$ac_safe=no"
2270 fi
2271 rm -f conftest*
2272 fi
2273 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2274   echo "$ac_t""yes" 1>&6
2275     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2276   cat >> confdefs.h <<EOF
2277 #define $ac_tr_hdr 1
2278 EOF
2279  
2280 else
2281   echo "$ac_t""no" 1>&6
2282 fi
2283 done
2284
2285 for ac_hdr in readline/readline.h readline/history.h
2286 do
2287 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2288 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2289 echo "configure:2290: checking for $ac_hdr" >&5
2290 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2291   echo $ac_n "(cached) $ac_c" 1>&6
2292 else
2293   cat > conftest.$ac_ext <<EOF
2294 #line 2295 "configure"
2295 #include "confdefs.h"
2296 #include <$ac_hdr>
2297 EOF
2298 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2299 { (eval echo configure:2300: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2300 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2301 if test -z "$ac_err"; then
2302   rm -rf conftest*
2303   eval "ac_cv_header_$ac_safe=yes"
2304 else
2305   echo "$ac_err" >&5
2306   echo "configure: failed program was:" >&5
2307   cat conftest.$ac_ext >&5
2308   rm -rf conftest*
2309   eval "ac_cv_header_$ac_safe=no"
2310 fi
2311 rm -f conftest*
2312 fi
2313 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2314   echo "$ac_t""yes" 1>&6
2315     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2316   cat >> confdefs.h <<EOF
2317 #define $ac_tr_hdr 1
2318 EOF
2319  
2320 else
2321   echo "$ac_t""no" 1>&6
2322 fi
2323 done
2324
2325 if test "x${ac_cv_header_readline_readline_h}" != "xyes" -o "x${ac_cv_header_readline_history_h}" != "xyes"; then
2326   
2327 ginac_warning_txt="$ginac_warning_txt
2328 == I could not find the headers for libreadline (needed for building ginsh).
2329 "
2330 ginac_warning=yes
2331 fi
2332 LIBTERMCAP=
2333 for ac_func in tgetent
2334 do
2335 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2336 echo "configure:2337: checking for $ac_func" >&5
2337 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2338   echo $ac_n "(cached) $ac_c" 1>&6
2339 else
2340   cat > conftest.$ac_ext <<EOF
2341 #line 2342 "configure"
2342 #include "confdefs.h"
2343 /* System header to define __stub macros and hopefully few prototypes,
2344     which can conflict with char $ac_func(); below.  */
2345 #include <assert.h>
2346 /* Override any gcc2 internal prototype to avoid an error.  */
2347 #ifdef __cplusplus
2348 extern "C"
2349 #endif
2350 /* We use char because int might match the return type of a gcc2
2351     builtin and then its argument prototype would still apply.  */
2352 char $ac_func();
2353
2354 int main() {
2355
2356 /* The GNU C library defines this for functions which it implements
2357     to always fail with ENOSYS.  Some functions are actually named
2358     something starting with __ and the normal name is an alias.  */
2359 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2360 choke me
2361 #else
2362 $ac_func();
2363 #endif
2364
2365 ; return 0; }
2366 EOF
2367 if { (eval echo configure:2368: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2368   rm -rf conftest*
2369   eval "ac_cv_func_$ac_func=yes"
2370 else
2371   echo "configure: failed program was:" >&5
2372   cat conftest.$ac_ext >&5
2373   rm -rf conftest*
2374   eval "ac_cv_func_$ac_func=no"
2375 fi
2376 rm -f conftest*
2377 fi
2378
2379 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2380   echo "$ac_t""yes" 1>&6
2381     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2382   cat >> confdefs.h <<EOF
2383 #define $ac_tr_func 1
2384 EOF
2385  
2386 else
2387   echo "$ac_t""no" 1>&6
2388 fi
2389 done
2390
2391 if test "x$ac_cv_func_tgetent" = "xyes"; then
2392     :
2393 else
2394     echo $ac_n "checking for tgetent in -lncurses""... $ac_c" 1>&6
2395 echo "configure:2396: checking for tgetent in -lncurses" >&5
2396 ac_lib_var=`echo ncurses'_'tgetent | sed 'y%./+-%__p_%'`
2397 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2398   echo $ac_n "(cached) $ac_c" 1>&6
2399 else
2400   ac_save_LIBS="$LIBS"
2401 LIBS="-lncurses  $LIBS"
2402 cat > conftest.$ac_ext <<EOF
2403 #line 2404 "configure"
2404 #include "confdefs.h"
2405 /* Override any gcc2 internal prototype to avoid an error.  */
2406 #ifdef __cplusplus
2407 extern "C"
2408 #endif
2409 /* We use char because int might match the return type of a gcc2
2410     builtin and then its argument prototype would still apply.  */
2411 char tgetent();
2412
2413 int main() {
2414 tgetent()
2415 ; return 0; }
2416 EOF
2417 if { (eval echo configure:2418: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2418   rm -rf conftest*
2419   eval "ac_cv_lib_$ac_lib_var=yes"
2420 else
2421   echo "configure: failed program was:" >&5
2422   cat conftest.$ac_ext >&5
2423   rm -rf conftest*
2424   eval "ac_cv_lib_$ac_lib_var=no"
2425 fi
2426 rm -f conftest*
2427 LIBS="$ac_save_LIBS"
2428
2429 fi
2430 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2431   echo "$ac_t""yes" 1>&6
2432   LIBTERMCAP="-lncurses"
2433 else
2434   echo "$ac_t""no" 1>&6
2435 fi
2436
2437     if test -z "$LIBTERMCAP"; then
2438         echo $ac_n "checking for tgetent in -ltermcap""... $ac_c" 1>&6
2439 echo "configure:2440: checking for tgetent in -ltermcap" >&5
2440 ac_lib_var=`echo termcap'_'tgetent | sed 'y%./+-%__p_%'`
2441 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2442   echo $ac_n "(cached) $ac_c" 1>&6
2443 else
2444   ac_save_LIBS="$LIBS"
2445 LIBS="-ltermcap  $LIBS"
2446 cat > conftest.$ac_ext <<EOF
2447 #line 2448 "configure"
2448 #include "confdefs.h"
2449 /* Override any gcc2 internal prototype to avoid an error.  */
2450 #ifdef __cplusplus
2451 extern "C"
2452 #endif
2453 /* We use char because int might match the return type of a gcc2
2454     builtin and then its argument prototype would still apply.  */
2455 char tgetent();
2456
2457 int main() {
2458 tgetent()
2459 ; return 0; }
2460 EOF
2461 if { (eval echo configure:2462: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2462   rm -rf conftest*
2463   eval "ac_cv_lib_$ac_lib_var=yes"
2464 else
2465   echo "configure: failed program was:" >&5
2466   cat conftest.$ac_ext >&5
2467   rm -rf conftest*
2468   eval "ac_cv_lib_$ac_lib_var=no"
2469 fi
2470 rm -f conftest*
2471 LIBS="$ac_save_LIBS"
2472
2473 fi
2474 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2475   echo "$ac_t""yes" 1>&6
2476   LIBTERMCAP="-ltermcap"
2477 else
2478   echo "$ac_t""no" 1>&6
2479 fi
2480
2481     fi
2482 fi
2483
2484
2485 save_LIBS=$LIBS
2486 LIBS="$LIBTERMCAP $LIBS"
2487 echo $ac_n "checking for readline in -lreadline""... $ac_c" 1>&6
2488 echo "configure:2489: checking for readline in -lreadline" >&5
2489 ac_lib_var=`echo readline'_'readline | sed 'y%./+-%__p_%'`
2490 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2491   echo $ac_n "(cached) $ac_c" 1>&6
2492 else
2493   ac_save_LIBS="$LIBS"
2494 LIBS="-lreadline  $LIBS"
2495 cat > conftest.$ac_ext <<EOF
2496 #line 2497 "configure"
2497 #include "confdefs.h"
2498 /* Override any gcc2 internal prototype to avoid an error.  */
2499 #ifdef __cplusplus
2500 extern "C"
2501 #endif
2502 /* We use char because int might match the return type of a gcc2
2503     builtin and then its argument prototype would still apply.  */
2504 char readline();
2505
2506 int main() {
2507 readline()
2508 ; return 0; }
2509 EOF
2510 if { (eval echo configure:2511: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2511   rm -rf conftest*
2512   eval "ac_cv_lib_$ac_lib_var=yes"
2513 else
2514   echo "configure: failed program was:" >&5
2515   cat conftest.$ac_ext >&5
2516   rm -rf conftest*
2517   eval "ac_cv_lib_$ac_lib_var=no"
2518 fi
2519 rm -f conftest*
2520 LIBS="$ac_save_LIBS"
2521
2522 fi
2523 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2524   echo "$ac_t""yes" 1>&6
2525     ac_tr_lib=HAVE_LIB`echo readline | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2526     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2527   cat >> confdefs.h <<EOF
2528 #define $ac_tr_lib 1
2529 EOF
2530
2531   LIBS="-lreadline $LIBS"
2532
2533 else
2534   echo "$ac_t""no" 1>&6
2535 fi
2536
2537 if test "x${ac_cv_lib_readline_readline}" != "xyes"; then
2538   
2539 ginac_warning_txt="$ginac_warning_txt
2540 == I could not find libreadline (needed by ginsh).
2541 "
2542 ginac_warning=yes
2543 fi
2544 GINSH_LIBS=$LIBS
2545 LIBS=$save_LIBS
2546
2547
2548 for ac_hdr in iostream vector map string list typeinfo iterator stdexcept algorithm
2549 do
2550 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2551 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2552 echo "configure:2553: checking for $ac_hdr" >&5
2553 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2554   echo $ac_n "(cached) $ac_c" 1>&6
2555 else
2556   cat > conftest.$ac_ext <<EOF
2557 #line 2558 "configure"
2558 #include "confdefs.h"
2559 #include <$ac_hdr>
2560 EOF
2561 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2562 { (eval echo configure:2563: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2563 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2564 if test -z "$ac_err"; then
2565   rm -rf conftest*
2566   eval "ac_cv_header_$ac_safe=yes"
2567 else
2568   echo "$ac_err" >&5
2569   echo "configure: failed program was:" >&5
2570   cat conftest.$ac_ext >&5
2571   rm -rf conftest*
2572   eval "ac_cv_header_$ac_safe=no"
2573 fi
2574 rm -f conftest*
2575 fi
2576 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2577   echo "$ac_t""yes" 1>&6
2578     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2579   cat >> confdefs.h <<EOF
2580 #define $ac_tr_hdr 1
2581 EOF
2582  
2583 else
2584   echo "$ac_t""no" 1>&6
2585 { echo "configure: error: need to have ANSI compliant headers" 1>&2; exit 1; }
2586 fi
2587 done
2588
2589 for ac_hdr in sstream strstream
2590 do
2591 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2592 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2593 echo "configure:2594: checking for $ac_hdr" >&5
2594 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2595   echo $ac_n "(cached) $ac_c" 1>&6
2596 else
2597   cat > conftest.$ac_ext <<EOF
2598 #line 2599 "configure"
2599 #include "confdefs.h"
2600 #include <$ac_hdr>
2601 EOF
2602 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2603 { (eval echo configure:2604: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2604 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2605 if test -z "$ac_err"; then
2606   rm -rf conftest*
2607   eval "ac_cv_header_$ac_safe=yes"
2608 else
2609   echo "$ac_err" >&5
2610   echo "configure: failed program was:" >&5
2611   cat conftest.$ac_ext >&5
2612   rm -rf conftest*
2613   eval "ac_cv_header_$ac_safe=no"
2614 fi
2615 rm -f conftest*
2616 fi
2617 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2618   echo "$ac_t""yes" 1>&6
2619     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2620   cat >> confdefs.h <<EOF
2621 #define $ac_tr_hdr 1
2622 EOF
2623  
2624 else
2625   echo "$ac_t""no" 1>&6
2626 fi
2627 done
2628
2629
2630
2631     for ac_hdr in cln/cln.h
2632 do
2633 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2634 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2635 echo "configure:2636: checking for $ac_hdr" >&5
2636 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2637   echo $ac_n "(cached) $ac_c" 1>&6
2638 else
2639   cat > conftest.$ac_ext <<EOF
2640 #line 2641 "configure"
2641 #include "confdefs.h"
2642 #include <$ac_hdr>
2643 EOF
2644 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2645 { (eval echo configure:2646: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2646 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2647 if test -z "$ac_err"; then
2648   rm -rf conftest*
2649   eval "ac_cv_header_$ac_safe=yes"
2650 else
2651   echo "$ac_err" >&5
2652   echo "configure: failed program was:" >&5
2653   cat conftest.$ac_ext >&5
2654   rm -rf conftest*
2655   eval "ac_cv_header_$ac_safe=no"
2656 fi
2657 rm -f conftest*
2658 fi
2659 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2660   echo "$ac_t""yes" 1>&6
2661     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2662   cat >> confdefs.h <<EOF
2663 #define $ac_tr_hdr 1
2664 EOF
2665  
2666 else
2667   echo "$ac_t""no" 1>&6
2668 for ac_hdr in cln.h
2669 do
2670 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2671 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2672 echo "configure:2673: checking for $ac_hdr" >&5
2673 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2674   echo $ac_n "(cached) $ac_c" 1>&6
2675 else
2676   cat > conftest.$ac_ext <<EOF
2677 #line 2678 "configure"
2678 #include "confdefs.h"
2679 #include <$ac_hdr>
2680 EOF
2681 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2682 { (eval echo configure:2683: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2683 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2684 if test -z "$ac_err"; then
2685   rm -rf conftest*
2686   eval "ac_cv_header_$ac_safe=yes"
2687 else
2688   echo "$ac_err" >&5
2689   echo "configure: failed program was:" >&5
2690   cat conftest.$ac_ext >&5
2691   rm -rf conftest*
2692   eval "ac_cv_header_$ac_safe=no"
2693 fi
2694 rm -f conftest*
2695 fi
2696 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2697   echo "$ac_t""yes" 1>&6
2698     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2699   cat >> confdefs.h <<EOF
2700 #define $ac_tr_hdr 1
2701 EOF
2702  
2703 else
2704   echo "$ac_t""no" 1>&6
2705 { echo "configure: error: cannot find header for Bruno Haible's CLN" 1>&2; exit 1; };
2706         
2707 fi
2708 done
2709
2710     
2711 fi
2712 done
2713
2714
2715
2716     echo $ac_n "checking for doublefactorial in -lcln""... $ac_c" 1>&6
2717 echo "configure:2718: checking for doublefactorial in -lcln" >&5
2718     saved_LIBS="${LIBS}"
2719     if eval "test \"`echo '$''{'ginac_cv_lib_cln_link'+set}'`\" = set"; then
2720   echo $ac_n "(cached) $ac_c" 1>&6
2721 else
2722   LIBS="-lcln"
2723         case "${ac_cv_header_cln_cln_h}" in
2724         "yes")
2725             cat > conftest.$ac_ext <<EOF
2726 #line 2727 "configure"
2727 #include "confdefs.h"
2728 #include <cln/cl_integer.h>
2729 int main() {
2730 doublefactorial(2);
2731 ; return 0; }
2732 EOF
2733 if { (eval echo configure:2734: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2734   rm -rf conftest*
2735   ginac_cv_lib_cln_link="-lcln"
2736 else
2737   echo "configure: failed program was:" >&5
2738   cat conftest.$ac_ext >&5
2739   rm -rf conftest*
2740   ginac_cv_lib_cln_link="fail"
2741 fi
2742 rm -f conftest*
2743             ;;
2744         *)
2745             cat > conftest.$ac_ext <<EOF
2746 #line 2747 "configure"
2747 #include "confdefs.h"
2748 #include <cl_integer.h>
2749 int main() {
2750 doublefactorial(2);
2751 ; return 0; }
2752 EOF
2753 if { (eval echo configure:2754: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2754   rm -rf conftest*
2755   ginac_cv_lib_cln_link="-lcln"
2756 else
2757   echo "configure: failed program was:" >&5
2758   cat conftest.$ac_ext >&5
2759   rm -rf conftest*
2760   ginac_cv_lib_cln_link="fail"
2761 fi
2762 rm -f conftest*
2763             ;;
2764         esac
2765     
2766 fi
2767
2768     case "${ginac_cv_lib_cln_link}" in
2769     "-lcln")
2770         LIBS="${ginac_cv_lib_cln_link} ${saved_LIBS}"
2771         echo "$ac_t"""yes"" 1>&6
2772     ;;
2773     "fail")
2774         LIBS="${saved_LIBS}"
2775         echo "$ac_t""no" 1>&6
2776         
2777 ginac_error_txt="$ginac_error_txt
2778 ** I could not successfully link a test-program against libcln.
2779    You either need to set \$LDFLAGS or install/update the CLN library.
2780 "
2781 ginac_error=yes
2782     ;;
2783     esac
2784
2785
2786 GINACLIB_CPPFLAGS=$CPPFLAGS
2787 GINACLIB_LIBS=$LIBS
2788
2789
2790
2791 # Extract the first word of "doxygen", so it can be a program name with args.
2792 set dummy doxygen; ac_word=$2
2793 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2794 echo "configure:2795: checking for $ac_word" >&5
2795 if eval "test \"`echo '$''{'ac_cv_path_DOXYGEN'+set}'`\" = set"; then
2796   echo $ac_n "(cached) $ac_c" 1>&6
2797 else
2798   case "$DOXYGEN" in
2799   /*)
2800   ac_cv_path_DOXYGEN="$DOXYGEN" # Let the user override the test with a path.
2801   ;;
2802   ?:/*)                  
2803   ac_cv_path_DOXYGEN="$DOXYGEN" # Let the user override the test with a dos path.
2804   ;;
2805   *)
2806   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
2807   ac_dummy="$PATH"
2808   for ac_dir in $ac_dummy; do 
2809     test -z "$ac_dir" && ac_dir=.
2810     if test -f $ac_dir/$ac_word; then
2811       ac_cv_path_DOXYGEN="$ac_dir/$ac_word"
2812       break
2813     fi
2814   done
2815   IFS="$ac_save_ifs"
2816   test -z "$ac_cv_path_DOXYGEN" && ac_cv_path_DOXYGEN=""""
2817   ;;
2818 esac
2819 fi
2820 DOXYGEN="$ac_cv_path_DOXYGEN"
2821 if test -n "$DOXYGEN"; then
2822   echo "$ac_t""$DOXYGEN" 1>&6
2823 else
2824   echo "$ac_t""no" 1>&6
2825 fi
2826
2827 # Extract the first word of "latex", so it can be a program name with args.
2828 set dummy latex; ac_word=$2
2829 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2830 echo "configure:2831: checking for $ac_word" >&5
2831 if eval "test \"`echo '$''{'ac_cv_path_LATEX'+set}'`\" = set"; then
2832   echo $ac_n "(cached) $ac_c" 1>&6
2833 else
2834   case "$LATEX" in
2835   /*)
2836   ac_cv_path_LATEX="$LATEX" # Let the user override the test with a path.
2837   ;;
2838   ?:/*)                  
2839   ac_cv_path_LATEX="$LATEX" # Let the user override the test with a dos path.
2840   ;;
2841   *)
2842   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
2843   ac_dummy="$PATH"
2844   for ac_dir in $ac_dummy; do 
2845     test -z "$ac_dir" && ac_dir=.
2846     if test -f $ac_dir/$ac_word; then
2847       ac_cv_path_LATEX="$ac_dir/$ac_word"
2848       break
2849     fi
2850   done
2851   IFS="$ac_save_ifs"
2852   test -z "$ac_cv_path_LATEX" && ac_cv_path_LATEX=""""
2853   ;;
2854 esac
2855 fi
2856 LATEX="$ac_cv_path_LATEX"
2857 if test -n "$LATEX"; then
2858   echo "$ac_t""$LATEX" 1>&6
2859 else
2860   echo "$ac_t""no" 1>&6
2861 fi
2862
2863 # Extract the first word of "makeindex", so it can be a program name with args.
2864 set dummy makeindex; ac_word=$2
2865 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2866 echo "configure:2867: checking for $ac_word" >&5
2867 if eval "test \"`echo '$''{'ac_cv_path_MAKEINDEX'+set}'`\" = set"; then
2868   echo $ac_n "(cached) $ac_c" 1>&6
2869 else
2870   case "$MAKEINDEX" in
2871   /*)
2872   ac_cv_path_MAKEINDEX="$MAKEINDEX" # Let the user override the test with a path.
2873   ;;
2874   ?:/*)                  
2875   ac_cv_path_MAKEINDEX="$MAKEINDEX" # Let the user override the test with a dos path.
2876   ;;
2877   *)
2878   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
2879   ac_dummy="$PATH"
2880   for ac_dir in $ac_dummy; do 
2881     test -z "$ac_dir" && ac_dir=.
2882     if test -f $ac_dir/$ac_word; then
2883       ac_cv_path_MAKEINDEX="$ac_dir/$ac_word"
2884       break
2885     fi
2886   done
2887   IFS="$ac_save_ifs"
2888   test -z "$ac_cv_path_MAKEINDEX" && ac_cv_path_MAKEINDEX=""""
2889   ;;
2890 esac
2891 fi
2892 MAKEINDEX="$ac_cv_path_MAKEINDEX"
2893 if test -n "$MAKEINDEX"; then
2894   echo "$ac_t""$MAKEINDEX" 1>&6
2895 else
2896   echo "$ac_t""no" 1>&6
2897 fi
2898
2899 # Extract the first word of "dvips", so it can be a program name with args.
2900 set dummy dvips; ac_word=$2
2901 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2902 echo "configure:2903: checking for $ac_word" >&5
2903 if eval "test \"`echo '$''{'ac_cv_path_DVIPS'+set}'`\" = set"; then
2904   echo $ac_n "(cached) $ac_c" 1>&6
2905 else
2906   case "$DVIPS" in
2907   /*)
2908   ac_cv_path_DVIPS="$DVIPS" # Let the user override the test with a path.
2909   ;;
2910   ?:/*)                  
2911   ac_cv_path_DVIPS="$DVIPS" # Let the user override the test with a dos path.
2912   ;;
2913   *)
2914   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
2915   ac_dummy="$PATH"
2916   for ac_dir in $ac_dummy; do 
2917     test -z "$ac_dir" && ac_dir=.
2918     if test -f $ac_dir/$ac_word; then
2919       ac_cv_path_DVIPS="$ac_dir/$ac_word"
2920       break
2921     fi
2922   done
2923   IFS="$ac_save_ifs"
2924   test -z "$ac_cv_path_DVIPS" && ac_cv_path_DVIPS=""""
2925   ;;
2926 esac
2927 fi
2928 DVIPS="$ac_cv_path_DVIPS"
2929 if test -n "$DVIPS"; then
2930   echo "$ac_t""$DVIPS" 1>&6
2931 else
2932   echo "$ac_t""no" 1>&6
2933 fi
2934
2935 # Extract the first word of "fig2dev", so it can be a program name with args.
2936 set dummy fig2dev; ac_word=$2
2937 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2938 echo "configure:2939: checking for $ac_word" >&5
2939 if eval "test \"`echo '$''{'ac_cv_path_FIG2DEV'+set}'`\" = set"; then
2940   echo $ac_n "(cached) $ac_c" 1>&6
2941 else
2942   case "$FIG2DEV" in
2943   /*)
2944   ac_cv_path_FIG2DEV="$FIG2DEV" # Let the user override the test with a path.
2945   ;;
2946   ?:/*)                  
2947   ac_cv_path_FIG2DEV="$FIG2DEV" # Let the user override the test with a dos path.
2948   ;;
2949   *)
2950   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
2951   ac_dummy="$PATH"
2952   for ac_dir in $ac_dummy; do 
2953     test -z "$ac_dir" && ac_dir=.
2954     if test -f $ac_dir/$ac_word; then
2955       ac_cv_path_FIG2DEV="$ac_dir/$ac_word"
2956       break
2957     fi
2958   done
2959   IFS="$ac_save_ifs"
2960   test -z "$ac_cv_path_FIG2DEV" && ac_cv_path_FIG2DEV=""""
2961   ;;
2962 esac
2963 fi
2964 FIG2DEV="$ac_cv_path_FIG2DEV"
2965 if test -n "$FIG2DEV"; then
2966   echo "$ac_t""$FIG2DEV" 1>&6
2967 else
2968   echo "$ac_t""no" 1>&6
2969 fi
2970
2971
2972 TUTORIAL_TARGETS=
2973 REFERENCE_TARGETS=
2974 if test "x${enable_html_doc}" = "xyes"; then
2975   TUTORIAL_TARGETS="$TUTORIAL_TARGETS ginac.html"
2976   if [ "$DOXYGEN" ]; then
2977     REFERENCE_TARGETS="$REFERENCE_TARGETS index.html"
2978   fi
2979 fi
2980 if test "x${enable_ps_doc}" = "xyes"; then
2981   TUTORIAL_TARGETS="$TUTORIAL_TARGETS ginac.ps"
2982   if [ "$DOXYGEN" ]; then
2983     REFERENCE_TARGETS="$REFERENCE_TARGETS reference.ps"
2984   fi
2985 fi
2986
2987
2988
2989 GINACCINTDIR=
2990 if test "x$with_cint" != "xno"; then
2991   if test "x$with_cint" = "xyes"; then
2992     if test "x$CINTSYSDIR" = "x"; then
2993       { echo "configure: error: please export \$CINTSYSDIR or specify --with-cint=CINTSYSDIR" 1>&2; exit 1; }
2994     fi
2995   else
2996     CINTSYSDIR=$with_cint
2997     export CINTSYSDIR
2998   fi
2999   # Extract the first word of "cint", so it can be a program name with args.
3000 set dummy cint; ac_word=$2
3001 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3002 echo "configure:3003: checking for $ac_word" >&5
3003 if eval "test \"`echo '$''{'ac_cv_path_CINT'+set}'`\" = set"; then
3004   echo $ac_n "(cached) $ac_c" 1>&6
3005 else
3006   case "$CINT" in
3007   /*)
3008   ac_cv_path_CINT="$CINT" # Let the user override the test with a path.
3009   ;;
3010   ?:/*)                  
3011   ac_cv_path_CINT="$CINT" # Let the user override the test with a dos path.
3012   ;;
3013   *)
3014   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
3015   ac_dummy="$CINTSYSDIR:$PATH"
3016   for ac_dir in $ac_dummy; do 
3017     test -z "$ac_dir" && ac_dir=.
3018     if test -f $ac_dir/$ac_word; then
3019       ac_cv_path_CINT="$ac_dir/$ac_word"
3020       break
3021     fi
3022   done
3023   IFS="$ac_save_ifs"
3024   test -z "$ac_cv_path_CINT" && ac_cv_path_CINT=""""
3025   ;;
3026 esac
3027 fi
3028 CINT="$ac_cv_path_CINT"
3029 if test -n "$CINT"; then
3030   echo "$ac_t""$CINT" 1>&6
3031 else
3032   echo "$ac_t""no" 1>&6
3033 fi
3034
3035   # Extract the first word of "makecint", so it can be a program name with args.
3036 set dummy makecint; ac_word=$2
3037 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3038 echo "configure:3039: checking for $ac_word" >&5
3039 if eval "test \"`echo '$''{'ac_cv_path_MAKECINT'+set}'`\" = set"; then
3040   echo $ac_n "(cached) $ac_c" 1>&6
3041 else
3042   case "$MAKECINT" in
3043   /*)
3044   ac_cv_path_MAKECINT="$MAKECINT" # Let the user override the test with a path.
3045   ;;
3046   ?:/*)                  
3047   ac_cv_path_MAKECINT="$MAKECINT" # Let the user override the test with a dos path.
3048   ;;
3049   *)
3050   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
3051   ac_dummy="$CINTSYSDIR:$PATH"
3052   for ac_dir in $ac_dummy; do 
3053     test -z "$ac_dir" && ac_dir=.
3054     if test -f $ac_dir/$ac_word; then
3055       ac_cv_path_MAKECINT="$ac_dir/$ac_word"
3056       break
3057     fi
3058   done
3059   IFS="$ac_save_ifs"
3060   test -z "$ac_cv_path_MAKECINT" && ac_cv_path_MAKECINT=""""
3061   ;;
3062 esac
3063 fi
3064 MAKECINT="$ac_cv_path_MAKECINT"
3065 if test -n "$MAKECINT"; then
3066   echo "$ac_t""$MAKECINT" 1>&6
3067 else
3068   echo "$ac_t""no" 1>&6
3069 fi
3070
3071   if [ "$CINT" -a "$MAKECINT" ]; then
3072     echo "$ac_t""creating cint/Makefile" 1>&6
3073     (cd cint && \
3074     $MAKECINT -mk Makefile.makecint -o ginaccint.bin -m \
3075       -D OBSCURE_CINT_HACK "$CPPFLAGS" -cc "$CXXFLAGS" \
3076       -I .. -I $CINTSYSDIR -m -H ../ginac/ginac.h \
3077       -C++ ginaccint.bin.cpp \
3078       -l -L../ginac/.libs -lginac -lcln \
3079       -cint -M0x10; \
3080     cd ..)
3081     GINACCINTDIR="cint"
3082   else
3083     { echo "configure: error: Cannot configure GiNaC-cint" 1>&2; exit 1; }
3084   fi
3085 fi
3086
3087
3088
3089 trap '' 1 2 15
3090 cat > confcache <<\EOF
3091 # This file is a shell script that caches the results of configure
3092 # tests run on this system so they can be shared between configure
3093 # scripts and configure runs.  It is not useful on other systems.
3094 # If it contains results you don't want to keep, you may remove or edit it.
3095 #
3096 # By default, configure uses ./config.cache as the cache file,
3097 # creating it if it does not exist already.  You can give configure
3098 # the --cache-file=FILE option to use a different cache file; that is
3099 # what configure does when it calls configure scripts in
3100 # subdirectories, so they share the cache.
3101 # Giving --cache-file=/dev/null disables caching, for debugging configure.
3102 # config.status only pays attention to the cache file if you give it the
3103 # --recheck option to rerun configure.
3104 #
3105 EOF
3106 # The following way of writing the cache mishandles newlines in values,
3107 # but we know of no workaround that is simple, portable, and efficient.
3108 # So, don't put newlines in cache variables' values.
3109 # Ultrix sh set writes to stderr and can't be redirected directly,
3110 # and sets the high bit in the cache file unless we assign to the vars.
3111 (set) 2>&1 |
3112   case `(ac_space=' '; set | grep ac_space) 2>&1` in
3113   *ac_space=\ *)
3114     # `set' does not quote correctly, so add quotes (double-quote substitution
3115     # turns \\\\ into \\, and sed turns \\ into \).
3116     sed -n \
3117       -e "s/'/'\\\\''/g" \
3118       -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
3119     ;;
3120   *)
3121     # `set' quotes correctly as required by POSIX, so do not add quotes.
3122     sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
3123     ;;
3124   esac >> confcache
3125 if cmp -s $cache_file confcache; then
3126   :
3127 else
3128   if test -w $cache_file; then
3129     echo "updating cache $cache_file"
3130     cat confcache > $cache_file
3131   else
3132     echo "not updating unwritable cache $cache_file"
3133   fi
3134 fi
3135 rm -f confcache
3136
3137 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
3138
3139 test "x$prefix" = xNONE && prefix=$ac_default_prefix
3140 # Let make expand exec_prefix.
3141 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
3142
3143 # Any assignment to VPATH causes Sun make to only execute
3144 # the first set of double-colon rules, so remove it if not needed.
3145 # If there is a colon in the path, we need to keep it.
3146 if test "x$srcdir" = x.; then
3147   ac_vpsub='/^[         ]*VPATH[        ]*=[^:]*$/d'
3148 fi
3149
3150 trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
3151
3152 DEFS=-DHAVE_CONFIG_H
3153
3154 # Without the "./", some shells look in PATH for config.status.
3155 : ${CONFIG_STATUS=./config.status}
3156
3157 echo creating $CONFIG_STATUS
3158 rm -f $CONFIG_STATUS
3159 cat > $CONFIG_STATUS <<EOF
3160 #! /bin/sh
3161 # Generated automatically by configure.
3162 # Run this file to recreate the current configuration.
3163 # This directory was configured as follows,
3164 # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
3165 #
3166 # $0 $ac_configure_args
3167 #
3168 # Compiler output produced by configure, useful for debugging
3169 # configure, is in ./config.log if it exists.
3170
3171 ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
3172 for ac_option
3173 do
3174   case "\$ac_option" in
3175   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
3176     echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
3177     exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
3178   -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
3179     echo "$CONFIG_STATUS generated by autoconf version 2.13"
3180     exit 0 ;;
3181   -help | --help | --hel | --he | --h)
3182     echo "\$ac_cs_usage"; exit 0 ;;
3183   *) echo "\$ac_cs_usage"; exit 1 ;;
3184   esac
3185 done
3186
3187 ac_given_srcdir=$srcdir
3188 ac_given_INSTALL="$INSTALL"
3189
3190 trap 'rm -fr `echo "
3191 Makefile
3192 GiNaC.spec
3193 ginac-config
3194 ginac/Makefile
3195 ginac/version.h
3196 check/Makefile
3197 ginsh/Makefile
3198 tools/Makefile
3199 doc/Makefile
3200 doc/tutorial/Makefile
3201 doc/reference/Makefile
3202 cint/Makefile
3203 cint/launch.h
3204  config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
3205 EOF
3206 cat >> $CONFIG_STATUS <<EOF
3207
3208 # Protect against being on the right side of a sed subst in config.status.
3209 sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
3210  s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
3211 $ac_vpsub
3212 $extrasub
3213 s%@SHELL@%$SHELL%g
3214 s%@CFLAGS@%$CFLAGS%g
3215 s%@CPPFLAGS@%$CPPFLAGS%g
3216 s%@CXXFLAGS@%$CXXFLAGS%g
3217 s%@FFLAGS@%$FFLAGS%g
3218 s%@DEFS@%$DEFS%g
3219 s%@LDFLAGS@%$LDFLAGS%g
3220 s%@LIBS@%$LIBS%g
3221 s%@exec_prefix@%$exec_prefix%g
3222 s%@prefix@%$prefix%g
3223 s%@program_transform_name@%$program_transform_name%g
3224 s%@bindir@%$bindir%g
3225 s%@sbindir@%$sbindir%g
3226 s%@libexecdir@%$libexecdir%g
3227 s%@datadir@%$datadir%g
3228 s%@sysconfdir@%$sysconfdir%g
3229 s%@sharedstatedir@%$sharedstatedir%g
3230 s%@localstatedir@%$localstatedir%g
3231 s%@libdir@%$libdir%g
3232 s%@includedir@%$includedir%g
3233 s%@oldincludedir@%$oldincludedir%g
3234 s%@infodir@%$infodir%g
3235 s%@mandir@%$mandir%g
3236 s%@GINACLIB_MAJOR_VERSION@%$GINACLIB_MAJOR_VERSION%g
3237 s%@GINACLIB_MINOR_VERSION@%$GINACLIB_MINOR_VERSION%g
3238 s%@GINACLIB_MICRO_VERSION@%$GINACLIB_MICRO_VERSION%g
3239 s%@GINACLIB_INTERFACE_AGE@%$GINACLIB_INTERFACE_AGE%g
3240 s%@GINACLIB_BINARY_AGE@%$GINACLIB_BINARY_AGE%g
3241 s%@GINACLIB_VERSION@%$GINACLIB_VERSION%g
3242 s%@ARCHIVE_VERSION@%$ARCHIVE_VERSION%g
3243 s%@ARCHIVE_AGE@%$ARCHIVE_AGE%g
3244 s%@LT_RELEASE@%$LT_RELEASE%g
3245 s%@LT_CURRENT@%$LT_CURRENT%g
3246 s%@LT_REVISION@%$LT_REVISION%g
3247 s%@LT_AGE@%$LT_AGE%g
3248 s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
3249 s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
3250 s%@INSTALL_DATA@%$INSTALL_DATA%g
3251 s%@PACKAGE@%$PACKAGE%g
3252 s%@VERSION@%$VERSION%g
3253 s%@ACLOCAL@%$ACLOCAL%g
3254 s%@AUTOCONF@%$AUTOCONF%g
3255 s%@AUTOMAKE@%$AUTOMAKE%g
3256 s%@AUTOHEADER@%$AUTOHEADER%g
3257 s%@MAKEINFO@%$MAKEINFO%g
3258 s%@SET_MAKE@%$SET_MAKE%g
3259 s%@MAINTAINER_MODE_TRUE@%$MAINTAINER_MODE_TRUE%g
3260 s%@MAINTAINER_MODE_FALSE@%$MAINTAINER_MODE_FALSE%g
3261 s%@MAINT@%$MAINT%g
3262 s%@CXX@%$CXX%g
3263 s%@CXXCPP@%$CXXCPP%g
3264 s%@host@%$host%g
3265 s%@host_alias@%$host_alias%g
3266 s%@host_cpu@%$host_cpu%g
3267 s%@host_vendor@%$host_vendor%g
3268 s%@host_os@%$host_os%g
3269 s%@build@%$build%g
3270 s%@build_alias@%$build_alias%g
3271 s%@build_cpu@%$build_cpu%g
3272 s%@build_vendor@%$build_vendor%g
3273 s%@build_os@%$build_os%g
3274 s%@RANLIB@%$RANLIB%g
3275 s%@CC@%$CC%g
3276 s%@LD@%$LD%g
3277 s%@NM@%$NM%g
3278 s%@LN_S@%$LN_S%g
3279 s%@LIBTOOL@%$LIBTOOL%g
3280 s%@LEX@%$LEX%g
3281 s%@LEXLIB@%$LEXLIB%g
3282 s%@CPP@%$CPP%g
3283 s%@LEX_OUTPUT_ROOT@%$LEX_OUTPUT_ROOT%g
3284 s%@YACC@%$YACC%g
3285 s%@LIBTERMCAP@%$LIBTERMCAP%g
3286 s%@GINSH_LIBS@%$GINSH_LIBS%g
3287 s%@GINACLIB_CPPFLAGS@%$GINACLIB_CPPFLAGS%g
3288 s%@GINACLIB_LIBS@%$GINACLIB_LIBS%g
3289 s%@DOXYGEN@%$DOXYGEN%g
3290 s%@LATEX@%$LATEX%g
3291 s%@MAKEINDEX@%$MAKEINDEX%g
3292 s%@DVIPS@%$DVIPS%g
3293 s%@FIG2DEV@%$FIG2DEV%g
3294 s%@TUTORIAL_TARGETS@%$TUTORIAL_TARGETS%g
3295 s%@REFERENCE_TARGETS@%$REFERENCE_TARGETS%g
3296 s%@CINT@%$CINT%g
3297 s%@MAKECINT@%$MAKECINT%g
3298 s%@CINTSYSDIR@%$CINTSYSDIR%g
3299 s%@GINACCINTDIR@%$GINACCINTDIR%g
3300
3301 CEOF
3302 EOF
3303
3304 cat >> $CONFIG_STATUS <<\EOF
3305
3306 # Split the substitutions into bite-sized pieces for seds with
3307 # small command number limits, like on Digital OSF/1 and HP-UX.
3308 ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
3309 ac_file=1 # Number of current file.
3310 ac_beg=1 # First line for current file.
3311 ac_end=$ac_max_sed_cmds # Line after last line for current file.
3312 ac_more_lines=:
3313 ac_sed_cmds=""
3314 while $ac_more_lines; do
3315   if test $ac_beg -gt 1; then
3316     sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
3317   else
3318     sed "${ac_end}q" conftest.subs > conftest.s$ac_file
3319   fi
3320   if test ! -s conftest.s$ac_file; then
3321     ac_more_lines=false
3322     rm -f conftest.s$ac_file
3323   else
3324     if test -z "$ac_sed_cmds"; then
3325       ac_sed_cmds="sed -f conftest.s$ac_file"
3326     else
3327       ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
3328     fi
3329     ac_file=`expr $ac_file + 1`
3330     ac_beg=$ac_end
3331     ac_end=`expr $ac_end + $ac_max_sed_cmds`
3332   fi
3333 done
3334 if test -z "$ac_sed_cmds"; then
3335   ac_sed_cmds=cat
3336 fi
3337 EOF
3338
3339 cat >> $CONFIG_STATUS <<EOF
3340
3341 CONFIG_FILES=\${CONFIG_FILES-"Makefile
3342 GiNaC.spec
3343 ginac-config
3344 ginac/Makefile
3345 ginac/version.h
3346 check/Makefile
3347 ginsh/Makefile
3348 tools/Makefile
3349 doc/Makefile
3350 doc/tutorial/Makefile
3351 doc/reference/Makefile
3352 cint/Makefile
3353 cint/launch.h
3354 "}
3355 EOF
3356 cat >> $CONFIG_STATUS <<\EOF
3357 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
3358   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
3359   case "$ac_file" in
3360   *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
3361        ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
3362   *) ac_file_in="${ac_file}.in" ;;
3363   esac
3364
3365   # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
3366
3367   # Remove last slash and all that follows it.  Not all systems have dirname.
3368   ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
3369   if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
3370     # The file is in a subdirectory.
3371     test ! -d "$ac_dir" && mkdir "$ac_dir"
3372     ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
3373     # A "../" for each directory in $ac_dir_suffix.
3374     ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
3375   else
3376     ac_dir_suffix= ac_dots=
3377   fi
3378
3379   case "$ac_given_srcdir" in
3380   .)  srcdir=.
3381       if test -z "$ac_dots"; then top_srcdir=.
3382       else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
3383   /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
3384   *) # Relative path.
3385     srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
3386     top_srcdir="$ac_dots$ac_given_srcdir" ;;
3387   esac
3388
3389   case "$ac_given_INSTALL" in
3390   [/$]*) INSTALL="$ac_given_INSTALL" ;;
3391   *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
3392   esac
3393
3394   echo creating "$ac_file"
3395   rm -f "$ac_file"
3396   configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
3397   case "$ac_file" in
3398   *Makefile*) ac_comsub="1i\\
3399 # $configure_input" ;;
3400   *) ac_comsub= ;;
3401   esac
3402
3403   ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
3404   sed -e "$ac_comsub
3405 s%@configure_input@%$configure_input%g
3406 s%@srcdir@%$srcdir%g
3407 s%@top_srcdir@%$top_srcdir%g
3408 s%@INSTALL@%$INSTALL%g
3409 " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
3410 fi; done
3411 rm -f conftest.s*
3412
3413 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
3414 # NAME is the cpp macro being defined and VALUE is the value it is being given.
3415 #
3416 # ac_d sets the value in "#define NAME VALUE" lines.
3417 ac_dA='s%^\([   ]*\)#\([        ]*define[       ][      ]*\)'
3418 ac_dB='\([      ][      ]*\)[^  ]*%\1#\2'
3419 ac_dC='\3'
3420 ac_dD='%g'
3421 # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
3422 ac_uA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
3423 ac_uB='\([      ]\)%\1#\2define\3'
3424 ac_uC=' '
3425 ac_uD='\4%g'
3426 # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
3427 ac_eA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
3428 ac_eB='$%\1#\2define\3'
3429 ac_eC=' '
3430 ac_eD='%g'
3431
3432 if test "${CONFIG_HEADERS+set}" != set; then
3433 EOF
3434 cat >> $CONFIG_STATUS <<EOF
3435   CONFIG_HEADERS="config.h"
3436 EOF
3437 cat >> $CONFIG_STATUS <<\EOF
3438 fi
3439 for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
3440   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
3441   case "$ac_file" in
3442   *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
3443        ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
3444   *) ac_file_in="${ac_file}.in" ;;
3445   esac
3446
3447   echo creating $ac_file
3448
3449   rm -f conftest.frag conftest.in conftest.out
3450   ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
3451   cat $ac_file_inputs > conftest.in
3452
3453 EOF
3454
3455 # Transform confdefs.h into a sed script conftest.vals that substitutes
3456 # the proper values into config.h.in to produce config.h.  And first:
3457 # Protect against being on the right side of a sed subst in config.status.
3458 # Protect against being in an unquoted here document in config.status.
3459 rm -f conftest.vals
3460 cat > conftest.hdr <<\EOF
3461 s/[\\&%]/\\&/g
3462 s%[\\$`]%\\&%g
3463 s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
3464 s%ac_d%ac_u%gp
3465 s%ac_u%ac_e%gp
3466 EOF
3467 sed -n -f conftest.hdr confdefs.h > conftest.vals
3468 rm -f conftest.hdr
3469
3470 # This sed command replaces #undef with comments.  This is necessary, for
3471 # example, in the case of _POSIX_SOURCE, which is predefined and required
3472 # on some systems where configure will not decide to define it.
3473 cat >> conftest.vals <<\EOF
3474 s%^[    ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
3475 EOF
3476
3477 # Break up conftest.vals because some shells have a limit on
3478 # the size of here documents, and old seds have small limits too.
3479
3480 rm -f conftest.tail
3481 while :
3482 do
3483   ac_lines=`grep -c . conftest.vals`
3484   # grep -c gives empty output for an empty file on some AIX systems.
3485   if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
3486   # Write a limited-size here document to conftest.frag.
3487   echo '  cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
3488   sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
3489   echo 'CEOF
3490   sed -f conftest.frag conftest.in > conftest.out
3491   rm -f conftest.in
3492   mv conftest.out conftest.in
3493 ' >> $CONFIG_STATUS
3494   sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
3495   rm -f conftest.vals
3496   mv conftest.tail conftest.vals
3497 done
3498 rm -f conftest.vals
3499
3500 cat >> $CONFIG_STATUS <<\EOF
3501   rm -f conftest.frag conftest.h
3502   echo "/* $ac_file.  Generated automatically by configure.  */" > conftest.h
3503   cat conftest.in >> conftest.h
3504   rm -f conftest.in
3505   if cmp -s $ac_file conftest.h 2>/dev/null; then
3506     echo "$ac_file is unchanged"
3507     rm -f conftest.h
3508   else
3509     # Remove last slash and all that follows it.  Not all systems have dirname.
3510       ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
3511       if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
3512       # The file is in a subdirectory.
3513       test ! -d "$ac_dir" && mkdir "$ac_dir"
3514     fi
3515     rm -f $ac_file
3516     mv conftest.h $ac_file
3517   fi
3518 fi; done
3519
3520 EOF
3521 cat >> $CONFIG_STATUS <<EOF
3522
3523
3524 EOF
3525 cat >> $CONFIG_STATUS <<\EOF
3526 test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h
3527 chmod +x ginac-config
3528 exit 0
3529 EOF
3530 chmod +x $CONFIG_STATUS
3531 rm -fr confdefs* $ac_clean_files
3532 test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
3533
3534
3535 if test "x${ginac_error}" = "xyes"; then
3536     echo "**** The following problems have been detected by configure."
3537     echo "**** Please check the messages below before running \"make\"."
3538     echo "**** (see the section 'Common Problems' in the INSTALL file)"
3539     echo "$ginac_error_txt"
3540     if test "x${ginac_warning_txt}" != "x"; then
3541         echo "${ginac_warning_txt}"
3542     fi
3543     echo "deleting cache ${cache_file}"
3544     rm -f $cache_file
3545     else 
3546         if test x$ginac_warning = xyes; then
3547             echo "=== The following minor problems have been detected by configure."
3548             echo "=== Please check the messages below before running \"make\"."
3549             echo "=== (see the section 'Common Problems' in the INSTALL file)"
3550             echo "$ginac_warning_txt"
3551         fi
3552     echo "Configuration of GiNaC $VERSION done. Now type \"make\"."
3553 fi