source: git/configure @ c37827

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