1 | #! /bin/sh |
---|
2 | |
---|
3 | # Guess values for system-dependent variables and create Makefiles. |
---|
4 | # Generated automatically using autoconf version 2.9 |
---|
5 | # Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc. |
---|
6 | # |
---|
7 | # This configure script is free software; the Free Software Foundation |
---|
8 | # gives unlimited permission to copy, distribute and modify it. |
---|
9 | |
---|
10 | # Defaults: |
---|
11 | ac_help= |
---|
12 | ac_default_prefix=/usr/local |
---|
13 | # Any additions from configure.in: |
---|
14 | ac_default_prefix=`pwd`/.. |
---|
15 | ac_help="$ac_help |
---|
16 | --with-rootdir=DIR use DIR ass compiled-in root directory |
---|
17 | (default is PREFIX)" |
---|
18 | ac_help="$ac_help |
---|
19 | --with-lex=[LEX,no] uses LEX as lex program, default is flex" |
---|
20 | ac_help="$ac_help |
---|
21 | --with-perl5=[PERL5,no] uses PERL5 as perl5 program, default is perl" |
---|
22 | ac_help="$ac_help |
---|
23 | --with-info=[INFO,no] uses INFO as info program, default is info" |
---|
24 | ac_help="$ac_help |
---|
25 | --without-readline do not use readline for fancy display" |
---|
26 | ac_help="$ac_help |
---|
27 | --without-MP do not use MP (no MP links)" |
---|
28 | ac_help="$ac_help |
---|
29 | --without-dbm do not use dbm (no DBM links)" |
---|
30 | ac_help="$ac_help |
---|
31 | --without-dld do not use dld (no dynamic linking)" |
---|
32 | ac_help="$ac_help |
---|
33 | --without-factory do not use factory (no poly factorization)" |
---|
34 | ac_help="$ac_help |
---|
35 | --without-libfac do not use libfac (no primary decompositions)" |
---|
36 | ac_help="$ac_help |
---|
37 | --with-apint=PACKAGE use PACKAGE for arbitary integer arithmetic |
---|
38 | where PACKAGE can be gmp, smallgmp" |
---|
39 | ac_help="$ac_help |
---|
40 | --with-exp_type=TYPE uses TYPE as type of exponents in polynomials |
---|
41 | -- default type is short |
---|
42 | -- possible other types are char and int" |
---|
43 | |
---|
44 | # Initialize some variables set by options. |
---|
45 | # The variables have the same names as the options, with |
---|
46 | # dashes changed to underlines. |
---|
47 | build=NONE |
---|
48 | cache_file=./config.cache |
---|
49 | exec_prefix=NONE |
---|
50 | host=NONE |
---|
51 | no_create= |
---|
52 | nonopt=NONE |
---|
53 | no_recursion= |
---|
54 | prefix=NONE |
---|
55 | program_prefix=NONE |
---|
56 | program_suffix=NONE |
---|
57 | program_transform_name=s,x,x, |
---|
58 | silent= |
---|
59 | site= |
---|
60 | srcdir= |
---|
61 | target=NONE |
---|
62 | verbose= |
---|
63 | x_includes=NONE |
---|
64 | x_libraries=NONE |
---|
65 | bindir='${exec_prefix}/bin' |
---|
66 | sbindir='${exec_prefix}/sbin' |
---|
67 | libexecdir='${exec_prefix}/libexec' |
---|
68 | datadir='${prefix}/share' |
---|
69 | sysconfdir='${prefix}/etc' |
---|
70 | sharedstatedir='${prefix}/com' |
---|
71 | localstatedir='${prefix}/var' |
---|
72 | libdir='${exec_prefix}/lib' |
---|
73 | includedir='${prefix}/include' |
---|
74 | oldincludedir='/usr/include' |
---|
75 | infodir='${prefix}/info' |
---|
76 | mandir='${prefix}/man' |
---|
77 | |
---|
78 | # Initialize some other variables. |
---|
79 | subdirs= |
---|
80 | MFLAGS= MAKEFLAGS= |
---|
81 | |
---|
82 | ac_prev= |
---|
83 | for ac_option |
---|
84 | do |
---|
85 | |
---|
86 | # If the previous option needs an argument, assign it. |
---|
87 | if test -n "$ac_prev"; then |
---|
88 | eval "$ac_prev=\$ac_option" |
---|
89 | ac_prev= |
---|
90 | continue |
---|
91 | fi |
---|
92 | |
---|
93 | case "$ac_option" in |
---|
94 | -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;; |
---|
95 | *) ac_optarg= ;; |
---|
96 | esac |
---|
97 | |
---|
98 | # Accept the important Cygnus configure options, so we can diagnose typos. |
---|
99 | |
---|
100 | case "$ac_option" in |
---|
101 | |
---|
102 | -bindir | --bindir | --bindi | --bind | --bin | --bi) |
---|
103 | ac_prev=bindir ;; |
---|
104 | -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) |
---|
105 | bindir="$ac_optarg" ;; |
---|
106 | |
---|
107 | -build | --build | --buil | --bui | --bu) |
---|
108 | ac_prev=build ;; |
---|
109 | -build=* | --build=* | --buil=* | --bui=* | --bu=*) |
---|
110 | build="$ac_optarg" ;; |
---|
111 | |
---|
112 | -cache-file | --cache-file | --cache-fil | --cache-fi \ |
---|
113 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) |
---|
114 | ac_prev=cache_file ;; |
---|
115 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ |
---|
116 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) |
---|
117 | cache_file="$ac_optarg" ;; |
---|
118 | |
---|
119 | -datadir | --datadir | --datadi | --datad | --data | --dat | --da) |
---|
120 | ac_prev=datadir ;; |
---|
121 | -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \ |
---|
122 | | --da=*) |
---|
123 | datadir="$ac_optarg" ;; |
---|
124 | |
---|
125 | -disable-* | --disable-*) |
---|
126 | ac_feature=`echo $ac_option|sed -e 's/-*disable-//'` |
---|
127 | # Reject names that are not valid shell variable names. |
---|
128 | if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then |
---|
129 | { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } |
---|
130 | fi |
---|
131 | ac_feature=`echo $ac_feature| sed 's/-/_/g'` |
---|
132 | eval "enable_${ac_feature}=no" ;; |
---|
133 | |
---|
134 | -enable-* | --enable-*) |
---|
135 | ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'` |
---|
136 | # Reject names that are not valid shell variable names. |
---|
137 | if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then |
---|
138 | { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } |
---|
139 | fi |
---|
140 | ac_feature=`echo $ac_feature| sed 's/-/_/g'` |
---|
141 | case "$ac_option" in |
---|
142 | *=*) ;; |
---|
143 | *) ac_optarg=yes ;; |
---|
144 | esac |
---|
145 | eval "enable_${ac_feature}='$ac_optarg'" ;; |
---|
146 | |
---|
147 | -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ |
---|
148 | | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ |
---|
149 | | --exec | --exe | --ex) |
---|
150 | ac_prev=exec_prefix ;; |
---|
151 | -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ |
---|
152 | | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ |
---|
153 | | --exec=* | --exe=* | --ex=*) |
---|
154 | exec_prefix="$ac_optarg" ;; |
---|
155 | |
---|
156 | -gas | --gas | --ga | --g) |
---|
157 | # Obsolete; use --with-gas. |
---|
158 | with_gas=yes ;; |
---|
159 | |
---|
160 | -help | --help | --hel | --he) |
---|
161 | # Omit some internal or obsolete options to make the list less imposing. |
---|
162 | # This message is too long to be a string in the A/UX 3.1 sh. |
---|
163 | cat << EOF |
---|
164 | Usage: configure [options] [host] |
---|
165 | Options: [defaults in brackets after descriptions] |
---|
166 | Configuration: |
---|
167 | --cache-file=FILE cache test results in FILE |
---|
168 | --help print this message |
---|
169 | --no-create do not create output files |
---|
170 | --quiet, --silent do not print \`checking...' messages |
---|
171 | --version print the version of autoconf that created configure |
---|
172 | Directory and file names: |
---|
173 | --prefix=PREFIX install architecture-independent files in PREFIX |
---|
174 | [$ac_default_prefix] |
---|
175 | --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX |
---|
176 | [same as prefix] |
---|
177 | --bindir=DIR user executables in DIR [EPREFIX/bin] |
---|
178 | --sbindir=DIR system admin executables in DIR [EPREFIX/sbin] |
---|
179 | --libexecdir=DIR program executables in DIR [EPREFIX/libexec] |
---|
180 | --datadir=DIR read-only architecture-independent data in DIR |
---|
181 | [PREFIX/share] |
---|
182 | --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc] |
---|
183 | --sharedstatedir=DIR modifiable architecture-independent data in DIR |
---|
184 | [PREFIX/com] |
---|
185 | --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var] |
---|
186 | --libdir=DIR object code libraries in DIR [EPREFIX/lib] |
---|
187 | --includedir=DIR C header files in DIR [PREFIX/include] |
---|
188 | --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include] |
---|
189 | --infodir=DIR info documentation in DIR [PREFIX/info] |
---|
190 | --mandir=DIR man documentation in DIR [PREFIX/man] |
---|
191 | --srcdir=DIR find the sources in DIR [configure dir or ..] |
---|
192 | --program-prefix=PREFIX prepend PREFIX to installed program names |
---|
193 | --program-suffix=SUFFIX append SUFFIX to installed program names |
---|
194 | --program-transform-name=PROGRAM |
---|
195 | run sed PROGRAM on installed program names |
---|
196 | EOF |
---|
197 | cat << EOF |
---|
198 | Host type: |
---|
199 | --build=BUILD configure for building on BUILD [BUILD=HOST] |
---|
200 | --host=HOST configure for HOST [guessed] |
---|
201 | --target=TARGET configure for TARGET [TARGET=HOST] |
---|
202 | Features and packages: |
---|
203 | --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) |
---|
204 | --enable-FEATURE[=ARG] include FEATURE [ARG=yes] |
---|
205 | --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] |
---|
206 | --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) |
---|
207 | --x-includes=DIR X include files are in DIR |
---|
208 | --x-libraries=DIR X library files are in DIR |
---|
209 | EOF |
---|
210 | if test -n "$ac_help"; then |
---|
211 | echo "--enable and --with options recognized:$ac_help" |
---|
212 | fi |
---|
213 | exit 0 ;; |
---|
214 | |
---|
215 | -host | --host | --hos | --ho) |
---|
216 | ac_prev=host ;; |
---|
217 | -host=* | --host=* | --hos=* | --ho=*) |
---|
218 | host="$ac_optarg" ;; |
---|
219 | |
---|
220 | -includedir | --includedir | --includedi | --included | --include \ |
---|
221 | | --includ | --inclu | --incl | --inc) |
---|
222 | ac_prev=includedir ;; |
---|
223 | -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ |
---|
224 | | --includ=* | --inclu=* | --incl=* | --inc=*) |
---|
225 | includedir="$ac_optarg" ;; |
---|
226 | |
---|
227 | -infodir | --infodir | --infodi | --infod | --info | --inf) |
---|
228 | ac_prev=infodir ;; |
---|
229 | -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) |
---|
230 | infodir="$ac_optarg" ;; |
---|
231 | |
---|
232 | -libdir | --libdir | --libdi | --libd) |
---|
233 | ac_prev=libdir ;; |
---|
234 | -libdir=* | --libdir=* | --libdi=* | --libd=*) |
---|
235 | libdir="$ac_optarg" ;; |
---|
236 | |
---|
237 | -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ |
---|
238 | | --libexe | --libex | --libe) |
---|
239 | ac_prev=libexecdir ;; |
---|
240 | -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ |
---|
241 | | --libexe=* | --libex=* | --libe=*) |
---|
242 | libexecdir="$ac_optarg" ;; |
---|
243 | |
---|
244 | -localstatedir | --localstatedir | --localstatedi | --localstated \ |
---|
245 | | --localstate | --localstat | --localsta | --localst \ |
---|
246 | | --locals | --local | --loca | --loc | --lo) |
---|
247 | ac_prev=localstatedir ;; |
---|
248 | -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ |
---|
249 | | --localstate=* | --localstat=* | --localsta=* | --localst=* \ |
---|
250 | | --locals=* | --local=* | --loca=* | --loc=* | --lo=*) |
---|
251 | localstatedir="$ac_optarg" ;; |
---|
252 | |
---|
253 | -mandir | --mandir | --mandi | --mand | --man | --ma | --m) |
---|
254 | ac_prev=mandir ;; |
---|
255 | -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) |
---|
256 | mandir="$ac_optarg" ;; |
---|
257 | |
---|
258 | -nfp | --nfp | --nf) |
---|
259 | # Obsolete; use --without-fp. |
---|
260 | with_fp=no ;; |
---|
261 | |
---|
262 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ |
---|
263 | | --no-cr | --no-c) |
---|
264 | no_create=yes ;; |
---|
265 | |
---|
266 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ |
---|
267 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) |
---|
268 | no_recursion=yes ;; |
---|
269 | |
---|
270 | -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ |
---|
271 | | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ |
---|
272 | | --oldin | --oldi | --old | --ol | --o) |
---|
273 | ac_prev=oldincludedir ;; |
---|
274 | -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ |
---|
275 | | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ |
---|
276 | | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) |
---|
277 | oldincludedir="$ac_optarg" ;; |
---|
278 | |
---|
279 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) |
---|
280 | ac_prev=prefix ;; |
---|
281 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) |
---|
282 | prefix="$ac_optarg" ;; |
---|
283 | |
---|
284 | -program-prefix | --program-prefix | --program-prefi | --program-pref \ |
---|
285 | | --program-pre | --program-pr | --program-p) |
---|
286 | ac_prev=program_prefix ;; |
---|
287 | -program-prefix=* | --program-prefix=* | --program-prefi=* \ |
---|
288 | | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) |
---|
289 | program_prefix="$ac_optarg" ;; |
---|
290 | |
---|
291 | -program-suffix | --program-suffix | --program-suffi | --program-suff \ |
---|
292 | | --program-suf | --program-su | --program-s) |
---|
293 | ac_prev=program_suffix ;; |
---|
294 | -program-suffix=* | --program-suffix=* | --program-suffi=* \ |
---|
295 | | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) |
---|
296 | program_suffix="$ac_optarg" ;; |
---|
297 | |
---|
298 | -program-transform-name | --program-transform-name \ |
---|
299 | | --program-transform-nam | --program-transform-na \ |
---|
300 | | --program-transform-n | --program-transform- \ |
---|
301 | | --program-transform | --program-transfor \ |
---|
302 | | --program-transfo | --program-transf \ |
---|
303 | | --program-trans | --program-tran \ |
---|
304 | | --progr-tra | --program-tr | --program-t) |
---|
305 | ac_prev=program_transform_name ;; |
---|
306 | -program-transform-name=* | --program-transform-name=* \ |
---|
307 | | --program-transform-nam=* | --program-transform-na=* \ |
---|
308 | | --program-transform-n=* | --program-transform-=* \ |
---|
309 | | --program-transform=* | --program-transfor=* \ |
---|
310 | | --program-transfo=* | --program-transf=* \ |
---|
311 | | --program-trans=* | --program-tran=* \ |
---|
312 | | --progr-tra=* | --program-tr=* | --program-t=*) |
---|
313 | program_transform_name="$ac_optarg" ;; |
---|
314 | |
---|
315 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
---|
316 | | -silent | --silent | --silen | --sile | --sil) |
---|
317 | silent=yes ;; |
---|
318 | |
---|
319 | -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) |
---|
320 | ac_prev=sbindir ;; |
---|
321 | -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ |
---|
322 | | --sbi=* | --sb=*) |
---|
323 | sbindir="$ac_optarg" ;; |
---|
324 | |
---|
325 | -sharedstatedir | --sharedstatedir | --sharedstatedi \ |
---|
326 | | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ |
---|
327 | | --sharedst | --shareds | --shared | --share | --shar \ |
---|
328 | | --sha | --sh) |
---|
329 | ac_prev=sharedstatedir ;; |
---|
330 | -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ |
---|
331 | | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ |
---|
332 | | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ |
---|
333 | | --sha=* | --sh=*) |
---|
334 | sharedstatedir="$ac_optarg" ;; |
---|
335 | |
---|
336 | -site | --site | --sit) |
---|
337 | ac_prev=site ;; |
---|
338 | -site=* | --site=* | --sit=*) |
---|
339 | site="$ac_optarg" ;; |
---|
340 | |
---|
341 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) |
---|
342 | ac_prev=srcdir ;; |
---|
343 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) |
---|
344 | srcdir="$ac_optarg" ;; |
---|
345 | |
---|
346 | -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ |
---|
347 | | --syscon | --sysco | --sysc | --sys | --sy) |
---|
348 | ac_prev=sysconfdir ;; |
---|
349 | -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ |
---|
350 | | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) |
---|
351 | sysconfdir="$ac_optarg" ;; |
---|
352 | |
---|
353 | -target | --target | --targe | --targ | --tar | --ta | --t) |
---|
354 | ac_prev=target ;; |
---|
355 | -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) |
---|
356 | target="$ac_optarg" ;; |
---|
357 | |
---|
358 | -v | -verbose | --verbose | --verbos | --verbo | --verb) |
---|
359 | verbose=yes ;; |
---|
360 | |
---|
361 | -version | --version | --versio | --versi | --vers) |
---|
362 | echo "configure generated by autoconf version 2.9" |
---|
363 | exit 0 ;; |
---|
364 | |
---|
365 | -with-* | --with-*) |
---|
366 | ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'` |
---|
367 | # Reject names that are not valid shell variable names. |
---|
368 | if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then |
---|
369 | { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } |
---|
370 | fi |
---|
371 | ac_package=`echo $ac_package| sed 's/-/_/g'` |
---|
372 | case "$ac_option" in |
---|
373 | *=*) ;; |
---|
374 | *) ac_optarg=yes ;; |
---|
375 | esac |
---|
376 | eval "with_${ac_package}='$ac_optarg'" ;; |
---|
377 | |
---|
378 | -without-* | --without-*) |
---|
379 | ac_package=`echo $ac_option|sed -e 's/-*without-//'` |
---|
380 | # Reject names that are not valid shell variable names. |
---|
381 | if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then |
---|
382 | { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } |
---|
383 | fi |
---|
384 | ac_package=`echo $ac_package| sed 's/-/_/g'` |
---|
385 | eval "with_${ac_package}=no" ;; |
---|
386 | |
---|
387 | --x) |
---|
388 | # Obsolete; use --with-x. |
---|
389 | with_x=yes ;; |
---|
390 | |
---|
391 | -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ |
---|
392 | | --x-incl | --x-inc | --x-in | --x-i) |
---|
393 | ac_prev=x_includes ;; |
---|
394 | -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ |
---|
395 | | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) |
---|
396 | x_includes="$ac_optarg" ;; |
---|
397 | |
---|
398 | -x-libraries | --x-libraries | --x-librarie | --x-librari \ |
---|
399 | | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) |
---|
400 | ac_prev=x_libraries ;; |
---|
401 | -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ |
---|
402 | | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) |
---|
403 | x_libraries="$ac_optarg" ;; |
---|
404 | |
---|
405 | -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; } |
---|
406 | ;; |
---|
407 | |
---|
408 | *) |
---|
409 | if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then |
---|
410 | echo "configure: warning: $ac_option: invalid host type" 1>&2 |
---|
411 | fi |
---|
412 | if test "x$nonopt" != xNONE; then |
---|
413 | { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } |
---|
414 | fi |
---|
415 | nonopt="$ac_option" |
---|
416 | ;; |
---|
417 | |
---|
418 | esac |
---|
419 | done |
---|
420 | |
---|
421 | if test -n "$ac_prev"; then |
---|
422 | { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; } |
---|
423 | fi |
---|
424 | |
---|
425 | trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 |
---|
426 | |
---|
427 | # File descriptor usage: |
---|
428 | # 0 standard input |
---|
429 | # 1 file creation |
---|
430 | # 2 errors and warnings |
---|
431 | # 3 some systems may open it to /dev/tty |
---|
432 | # 4 used on the Kubota Titan |
---|
433 | # 6 checking for... messages and results |
---|
434 | # 5 compiler messages saved in config.log |
---|
435 | if test "$silent" = yes; then |
---|
436 | exec 6>/dev/null |
---|
437 | else |
---|
438 | exec 6>&1 |
---|
439 | fi |
---|
440 | exec 5>./config.log |
---|
441 | |
---|
442 | echo "\ |
---|
443 | This file contains any messages produced by compilers while |
---|
444 | running configure, to aid debugging if configure makes a mistake. |
---|
445 | " 1>&5 |
---|
446 | |
---|
447 | # Strip out --no-create and --no-recursion so they do not pile up. |
---|
448 | # Also quote any args containing shell metacharacters. |
---|
449 | ac_configure_args= |
---|
450 | for ac_arg |
---|
451 | do |
---|
452 | case "$ac_arg" in |
---|
453 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ |
---|
454 | | --no-cr | --no-c) ;; |
---|
455 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ |
---|
456 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;; |
---|
457 | *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*) |
---|
458 | ac_configure_args="$ac_configure_args '$ac_arg'" ;; |
---|
459 | *) ac_configure_args="$ac_configure_args $ac_arg" ;; |
---|
460 | esac |
---|
461 | done |
---|
462 | |
---|
463 | # NLS nuisances. |
---|
464 | # Only set LANG and LC_ALL to C if already set. |
---|
465 | # These must not be set unconditionally because not all systems understand |
---|
466 | # e.g. LANG=C (notably SCO). |
---|
467 | if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi |
---|
468 | if test "${LANG+set}" = set; then LANG=C; export LANG; fi |
---|
469 | |
---|
470 | # confdefs.h avoids OS command line length limits that DEFS can exceed. |
---|
471 | rm -rf conftest* confdefs.h |
---|
472 | # AIX cpp loses on an empty file, so make sure it contains at least a newline. |
---|
473 | echo > confdefs.h |
---|
474 | |
---|
475 | # A filename unique to this package, relative to the directory that |
---|
476 | # configure is in, which we can look for to find out if srcdir is correct. |
---|
477 | ac_unique_file=matpol.h |
---|
478 | |
---|
479 | # Find the source files, if location was not specified. |
---|
480 | if test -z "$srcdir"; then |
---|
481 | ac_srcdir_defaulted=yes |
---|
482 | # Try the directory containing this script, then its parent. |
---|
483 | ac_prog=$0 |
---|
484 | ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'` |
---|
485 | test "x$ac_confdir" = "x$ac_prog" && ac_confdir=. |
---|
486 | srcdir=$ac_confdir |
---|
487 | if test ! -r $srcdir/$ac_unique_file; then |
---|
488 | srcdir=.. |
---|
489 | fi |
---|
490 | else |
---|
491 | ac_srcdir_defaulted=no |
---|
492 | fi |
---|
493 | if test ! -r $srcdir/$ac_unique_file; then |
---|
494 | if test "$ac_srcdir_defaulted" = yes; then |
---|
495 | { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; } |
---|
496 | else |
---|
497 | { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; } |
---|
498 | fi |
---|
499 | fi |
---|
500 | srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'` |
---|
501 | |
---|
502 | # Prefer explicitly selected file to automatically selected ones. |
---|
503 | if test -z "$CONFIG_SITE"; then |
---|
504 | if test "x$prefix" != xNONE; then |
---|
505 | CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site" |
---|
506 | else |
---|
507 | CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site" |
---|
508 | fi |
---|
509 | fi |
---|
510 | for ac_site_file in $CONFIG_SITE; do |
---|
511 | if test -r "$ac_site_file"; then |
---|
512 | echo "loading site script $ac_site_file" |
---|
513 | . "$ac_site_file" |
---|
514 | fi |
---|
515 | done |
---|
516 | |
---|
517 | if test -r "$cache_file"; then |
---|
518 | echo "loading cache $cache_file" |
---|
519 | . $cache_file |
---|
520 | else |
---|
521 | echo "creating cache $cache_file" |
---|
522 | > $cache_file |
---|
523 | fi |
---|
524 | |
---|
525 | ac_ext=c |
---|
526 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. |
---|
527 | ac_cpp='$CPP $CPPFLAGS' |
---|
528 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' |
---|
529 | ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' |
---|
530 | |
---|
531 | if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then |
---|
532 | # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu. |
---|
533 | if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then |
---|
534 | ac_n= ac_c=' |
---|
535 | ' ac_t=' ' |
---|
536 | else |
---|
537 | ac_n=-n ac_c= ac_t= |
---|
538 | fi |
---|
539 | else |
---|
540 | ac_n= ac_c='\c' ac_t= |
---|
541 | fi |
---|
542 | |
---|
543 | |
---|
544 | |
---|
545 | |
---|
546 | |
---|
547 | SINGULAR_MAJOR_VERSION=${SINGULAR_MAJOR_VERSION:-1} |
---|
548 | SINGULAR_MINOR_VERSION=${SINGULAR_MINOR_VERSION:-2} |
---|
549 | SINGULAR_SUB_VERSION=${SINGULAR_SUB_VERSION:-0} |
---|
550 | SINGULAR_VERSION="${SINGULAR_VERSION:-$SINGULAR_MAJOR_VERSION.$SINGULAR_MINOR_VERSION.$SINGULAR_SUB_VERSION}" |
---|
551 | VERSION_DATE=${VERSION_DATE:-"June 1998"} |
---|
552 | |
---|
553 | |
---|
554 | cat >> confdefs.h <<EOF |
---|
555 | #define SINGULAR_MAJOR_VERSION ${SINGULAR_MAJOR_VERSION} |
---|
556 | EOF |
---|
557 | |
---|
558 | cat >> confdefs.h <<EOF |
---|
559 | #define SINGULAR_MINOR_VERSION ${SINGULAR_MINOR_VERSION} |
---|
560 | EOF |
---|
561 | |
---|
562 | cat >> confdefs.h <<EOF |
---|
563 | #define SINGULAR_SUB_VERSION ${SINGULAR_SUB_VERSION} |
---|
564 | EOF |
---|
565 | |
---|
566 | cat >> confdefs.h <<EOF |
---|
567 | #define S_VERSION1 "${SINGULAR_MAJOR_VERSION}.${SINGULAR_MINOR_VERSION}.${SINGULAR_SUB_VERSION}" |
---|
568 | EOF |
---|
569 | |
---|
570 | cat >> confdefs.h <<EOF |
---|
571 | #define S_VERSION2 "${VERSION_DATE}" |
---|
572 | EOF |
---|
573 | |
---|
574 | cat >> confdefs.h <<EOF |
---|
575 | #define SINGULAR_SUB_VERSION ${SINGULAR_SUB_VERSION} |
---|
576 | EOF |
---|
577 | |
---|
578 | |
---|
579 | |
---|
580 | if test "${CXXFLAGS+set}" != set; then |
---|
581 | ac_cxxflags_set=no |
---|
582 | CXXFLAGS="-O" |
---|
583 | fi |
---|
584 | if test "${CFLAGS+set}" != set; then |
---|
585 | CFLAGS="-O" |
---|
586 | ac_cflags_set=no |
---|
587 | fi |
---|
588 | |
---|
589 | # check whether CXX was set by user as env variable |
---|
590 | if test "${CXX+set}" != set; then |
---|
591 | ac_cxx_set=no |
---|
592 | else |
---|
593 | ac_cxx_set=yes |
---|
594 | fi |
---|
595 | # Extract the first word of "gcc", so it can be a program name with args. |
---|
596 | set dummy gcc; ac_word=$2 |
---|
597 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
---|
598 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
---|
599 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
600 | else |
---|
601 | if test -n "$CC"; then |
---|
602 | ac_cv_prog_CC="$CC" # Let the user override the test. |
---|
603 | else |
---|
604 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" |
---|
605 | for ac_dir in $PATH; do |
---|
606 | test -z "$ac_dir" && ac_dir=. |
---|
607 | if test -f $ac_dir/$ac_word; then |
---|
608 | ac_cv_prog_CC="gcc" |
---|
609 | break |
---|
610 | fi |
---|
611 | done |
---|
612 | IFS="$ac_save_ifs" |
---|
613 | fi |
---|
614 | fi |
---|
615 | CC="$ac_cv_prog_CC" |
---|
616 | if test -n "$CC"; then |
---|
617 | echo "$ac_t""$CC" 1>&6 |
---|
618 | else |
---|
619 | echo "$ac_t""no" 1>&6 |
---|
620 | fi |
---|
621 | |
---|
622 | if test -z "$CC"; then |
---|
623 | # Extract the first word of "cc", so it can be a program name with args. |
---|
624 | set dummy cc; ac_word=$2 |
---|
625 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
---|
626 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
---|
627 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
628 | else |
---|
629 | if test -n "$CC"; then |
---|
630 | ac_cv_prog_CC="$CC" # Let the user override the test. |
---|
631 | else |
---|
632 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" |
---|
633 | ac_prog_rejected=no |
---|
634 | for ac_dir in $PATH; do |
---|
635 | test -z "$ac_dir" && ac_dir=. |
---|
636 | if test -f $ac_dir/$ac_word; then |
---|
637 | if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then |
---|
638 | ac_prog_rejected=yes |
---|
639 | continue |
---|
640 | fi |
---|
641 | ac_cv_prog_CC="cc" |
---|
642 | break |
---|
643 | fi |
---|
644 | done |
---|
645 | IFS="$ac_save_ifs" |
---|
646 | if test $ac_prog_rejected = yes; then |
---|
647 | # We found a bogon in the path, so make sure we never use it. |
---|
648 | set dummy $ac_cv_prog_CC |
---|
649 | shift |
---|
650 | if test $# -gt 0; then |
---|
651 | # We chose a different compiler from the bogus one. |
---|
652 | # However, it has the same basename, so the bogon will be chosen |
---|
653 | # first if we set CC to just the basename; use the full file name. |
---|
654 | shift |
---|
655 | set dummy "$ac_dir/$ac_word" "$@" |
---|
656 | shift |
---|
657 | ac_cv_prog_CC="$@" |
---|
658 | fi |
---|
659 | fi |
---|
660 | fi |
---|
661 | fi |
---|
662 | CC="$ac_cv_prog_CC" |
---|
663 | if test -n "$CC"; then |
---|
664 | echo "$ac_t""$CC" 1>&6 |
---|
665 | else |
---|
666 | echo "$ac_t""no" 1>&6 |
---|
667 | fi |
---|
668 | |
---|
669 | test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; } |
---|
670 | fi |
---|
671 | |
---|
672 | echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6 |
---|
673 | if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then |
---|
674 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
675 | else |
---|
676 | cat > conftest.c <<EOF |
---|
677 | #ifdef __GNUC__ |
---|
678 | yes; |
---|
679 | #endif |
---|
680 | EOF |
---|
681 | if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:682: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then |
---|
682 | ac_cv_prog_gcc=yes |
---|
683 | else |
---|
684 | ac_cv_prog_gcc=no |
---|
685 | fi |
---|
686 | fi |
---|
687 | |
---|
688 | echo "$ac_t""$ac_cv_prog_gcc" 1>&6 |
---|
689 | if test $ac_cv_prog_gcc = yes; then |
---|
690 | GCC=yes |
---|
691 | if test "${CFLAGS+set}" != set; then |
---|
692 | echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 |
---|
693 | if eval "test \"`echo '$''{'ac_cv_prog_gcc_g'+set}'`\" = set"; then |
---|
694 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
695 | else |
---|
696 | echo 'void f(){}' > conftest.c |
---|
697 | if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then |
---|
698 | ac_cv_prog_gcc_g=yes |
---|
699 | else |
---|
700 | ac_cv_prog_gcc_g=no |
---|
701 | fi |
---|
702 | rm -f conftest* |
---|
703 | |
---|
704 | fi |
---|
705 | |
---|
706 | echo "$ac_t""$ac_cv_prog_gcc_g" 1>&6 |
---|
707 | if test $ac_cv_prog_gcc_g = yes; then |
---|
708 | CFLAGS="-g -O" |
---|
709 | else |
---|
710 | CFLAGS="-O" |
---|
711 | fi |
---|
712 | fi |
---|
713 | else |
---|
714 | GCC= |
---|
715 | test "${CFLAGS+set}" = set || CFLAGS="-g" |
---|
716 | fi |
---|
717 | |
---|
718 | echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6 |
---|
719 | # On Suns, sometimes $CPP names a directory. |
---|
720 | if test -n "$CPP" && test -d "$CPP"; then |
---|
721 | CPP= |
---|
722 | fi |
---|
723 | if test -z "$CPP"; then |
---|
724 | if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then |
---|
725 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
726 | else |
---|
727 | # This must be in double quotes, not single quotes, because CPP may get |
---|
728 | # substituted into the Makefile and "${CC-cc}" will confuse make. |
---|
729 | CPP="${CC-cc} -E" |
---|
730 | # On the NeXT, cc -E runs the code through the compiler's parser, |
---|
731 | # not just through cpp. |
---|
732 | cat > conftest.$ac_ext <<EOF |
---|
733 | #line 734 "configure" |
---|
734 | #include "confdefs.h" |
---|
735 | #include <assert.h> |
---|
736 | Syntax Error |
---|
737 | EOF |
---|
738 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
---|
739 | { (eval echo configure:740: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
---|
740 | ac_err=`grep -v '^ *+' conftest.out` |
---|
741 | if test -z "$ac_err"; then |
---|
742 | : |
---|
743 | else |
---|
744 | echo "$ac_err" >&5 |
---|
745 | rm -rf conftest* |
---|
746 | CPP="${CC-cc} -E -traditional-cpp" |
---|
747 | cat > conftest.$ac_ext <<EOF |
---|
748 | #line 749 "configure" |
---|
749 | #include "confdefs.h" |
---|
750 | #include <assert.h> |
---|
751 | Syntax Error |
---|
752 | EOF |
---|
753 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
---|
754 | { (eval echo configure:755: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
---|
755 | ac_err=`grep -v '^ *+' conftest.out` |
---|
756 | if test -z "$ac_err"; then |
---|
757 | : |
---|
758 | else |
---|
759 | echo "$ac_err" >&5 |
---|
760 | rm -rf conftest* |
---|
761 | CPP=/lib/cpp |
---|
762 | fi |
---|
763 | rm -f conftest* |
---|
764 | fi |
---|
765 | rm -f conftest* |
---|
766 | ac_cv_prog_CPP="$CPP" |
---|
767 | fi |
---|
768 | CPP="$ac_cv_prog_CPP" |
---|
769 | else |
---|
770 | ac_cv_prog_CPP="$CPP" |
---|
771 | fi |
---|
772 | echo "$ac_t""$CPP" 1>&6 |
---|
773 | |
---|
774 | for ac_prog in $CCC c++ g++ gcc CC cxx |
---|
775 | do |
---|
776 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
---|
777 | set dummy $ac_prog; ac_word=$2 |
---|
778 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
---|
779 | if eval "test \"`echo '$''{'ac_cv_prog_CXX'+set}'`\" = set"; then |
---|
780 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
781 | else |
---|
782 | if test -n "$CXX"; then |
---|
783 | ac_cv_prog_CXX="$CXX" # Let the user override the test. |
---|
784 | else |
---|
785 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" |
---|
786 | for ac_dir in $PATH; do |
---|
787 | test -z "$ac_dir" && ac_dir=. |
---|
788 | if test -f $ac_dir/$ac_word; then |
---|
789 | ac_cv_prog_CXX="$ac_prog" |
---|
790 | break |
---|
791 | fi |
---|
792 | done |
---|
793 | IFS="$ac_save_ifs" |
---|
794 | fi |
---|
795 | fi |
---|
796 | CXX="$ac_cv_prog_CXX" |
---|
797 | if test -n "$CXX"; then |
---|
798 | echo "$ac_t""$CXX" 1>&6 |
---|
799 | else |
---|
800 | echo "$ac_t""no" 1>&6 |
---|
801 | fi |
---|
802 | |
---|
803 | test -n "$CXX" && break |
---|
804 | done |
---|
805 | test -n "$CXX" || CXX="gcc" |
---|
806 | |
---|
807 | |
---|
808 | echo $ac_n "checking whether we are using GNU C++""... $ac_c" 1>&6 |
---|
809 | if eval "test \"`echo '$''{'ac_cv_prog_gxx'+set}'`\" = set"; then |
---|
810 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
811 | else |
---|
812 | cat > conftest.C <<EOF |
---|
813 | #ifdef __GNUC__ |
---|
814 | yes; |
---|
815 | #endif |
---|
816 | EOF |
---|
817 | if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:818: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then |
---|
818 | ac_cv_prog_gxx=yes |
---|
819 | else |
---|
820 | ac_cv_prog_gxx=no |
---|
821 | fi |
---|
822 | fi |
---|
823 | |
---|
824 | echo "$ac_t""$ac_cv_prog_gxx" 1>&6 |
---|
825 | if test $ac_cv_prog_gxx = yes; then |
---|
826 | GXX=yes |
---|
827 | if test "${CXXFLAGS+set}" != set; then |
---|
828 | echo $ac_n "checking whether ${CXX-g++} accepts -g""... $ac_c" 1>&6 |
---|
829 | if eval "test \"`echo '$''{'ac_cv_prog_gxx_g'+set}'`\" = set"; then |
---|
830 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
831 | else |
---|
832 | echo 'void f(){}' > conftest.cc |
---|
833 | if test -z "`${CXX-g++} -g -c conftest.cc 2>&1`"; then |
---|
834 | ac_cv_prog_gxx_g=yes |
---|
835 | else |
---|
836 | ac_cv_prog_gxx_g=no |
---|
837 | fi |
---|
838 | rm -f conftest* |
---|
839 | |
---|
840 | fi |
---|
841 | |
---|
842 | echo "$ac_t""$ac_cv_prog_gxx_g" 1>&6 |
---|
843 | if test $ac_cv_prog_gxx_g = yes; then |
---|
844 | CXXFLAGS="-g -O" |
---|
845 | else |
---|
846 | CXXFLAGS="-O" |
---|
847 | fi |
---|
848 | fi |
---|
849 | else |
---|
850 | GXX= |
---|
851 | test "${CXXFLAGS+set}" = set || CXXFLAGS="-g" |
---|
852 | fi |
---|
853 | |
---|
854 | echo $ac_n "checking for AIX""... $ac_c" 1>&6 |
---|
855 | cat > conftest.$ac_ext <<EOF |
---|
856 | #line 857 "configure" |
---|
857 | #include "confdefs.h" |
---|
858 | #ifdef _AIX |
---|
859 | yes |
---|
860 | #endif |
---|
861 | |
---|
862 | EOF |
---|
863 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
---|
864 | egrep "yes" >/dev/null 2>&1; then |
---|
865 | rm -rf conftest* |
---|
866 | echo "$ac_t""yes" 1>&6; cat >> confdefs.h <<\EOF |
---|
867 | #define _ALL_SOURCE 1 |
---|
868 | EOF |
---|
869 | |
---|
870 | else |
---|
871 | rm -rf conftest* |
---|
872 | echo "$ac_t""no" 1>&6 |
---|
873 | fi |
---|
874 | rm -f conftest* |
---|
875 | |
---|
876 | |
---|
877 | |
---|
878 | # we prefer using gcc for compiling C++ files, provided the user did |
---|
879 | # not overwrite it explicitely |
---|
880 | if test "${GXX}" = yes && test "${ac_cxx_set}" = no; then |
---|
881 | CXX=gcc |
---|
882 | fi |
---|
883 | |
---|
884 | # check whether the compiler accepts -pipe |
---|
885 | echo $ac_n "checking whether compiler accepts -pipe""... $ac_c" 1>&6 |
---|
886 | temp_cflags=${CFLAGS} |
---|
887 | CFLAGS="${CFLAGS} -pipe" |
---|
888 | if eval "test \"`echo '$''{'ac_cv_cxx_have_pipe'+set}'`\" = set"; then |
---|
889 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
890 | else |
---|
891 | cat > conftest.$ac_ext <<EOF |
---|
892 | #line 893 "configure" |
---|
893 | #include "confdefs.h" |
---|
894 | |
---|
895 | int main() { return 0; } |
---|
896 | int t() { |
---|
897 | |
---|
898 | ; return 0; } |
---|
899 | EOF |
---|
900 | if { (eval echo configure:901: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
---|
901 | rm -rf conftest* |
---|
902 | ac_cv_cxx_have_pipe=yes |
---|
903 | else |
---|
904 | rm -rf conftest* |
---|
905 | ac_cv_cxx_have_pipe=no |
---|
906 | fi |
---|
907 | rm -f conftest* |
---|
908 | |
---|
909 | |
---|
910 | fi |
---|
911 | |
---|
912 | echo "$ac_t""${ac_cv_cxx_have_pipe}" 1>&6 |
---|
913 | CFLAGS=${temp_cflags} |
---|
914 | if test "${ac_cv_cxx_have_pipe}" != yes; then |
---|
915 | PIPE= |
---|
916 | else |
---|
917 | PIPE="-pipe" |
---|
918 | fi |
---|
919 | |
---|
920 | |
---|
921 | # Customize CFLAGS |
---|
922 | echo $ac_n "checking whether _AIX is defined""... $ac_c" 1>&6 |
---|
923 | if eval "test \"`echo '$''{'ac_cv_is_aix'+set}'`\" = set"; then |
---|
924 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
925 | else |
---|
926 | cat > conftest.$ac_ext <<EOF |
---|
927 | #line 928 "configure" |
---|
928 | #include "confdefs.h" |
---|
929 | #ifdef _AIX |
---|
930 | yes |
---|
931 | #endif |
---|
932 | |
---|
933 | EOF |
---|
934 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
---|
935 | egrep "yes" >/dev/null 2>&1; then |
---|
936 | rm -rf conftest* |
---|
937 | ac_cv_is_aix=yes |
---|
938 | else |
---|
939 | rm -rf conftest* |
---|
940 | ac_cv_is_aix=no |
---|
941 | fi |
---|
942 | rm -f conftest* |
---|
943 | |
---|
944 | fi |
---|
945 | |
---|
946 | if test "$ac_cv_is_aix" = yes; then |
---|
947 | echo "$ac_t""yes" 1>&6 |
---|
948 | else |
---|
949 | echo "$ac_t""no" 1>&6 |
---|
950 | fi |
---|
951 | |
---|
952 | # we know best when compiling with gcc |
---|
953 | if test "${GXX}" = yes; then |
---|
954 | if test "$ac_cxxflags_set" = no; then |
---|
955 | CXXFLAGS="-O3 -w -fomit-frame-pointer" |
---|
956 | fi |
---|
957 | CXXTEMPLFLAGS="-fno-implicit-templates" |
---|
958 | if test "$ac_cv_is_aix" = yes; then |
---|
959 | CXXNOOPTFLAGS="-w" |
---|
960 | else |
---|
961 | CXXNOOPTFLAGS=$CXXFLAGS |
---|
962 | fi |
---|
963 | STATIC_LDFLAGS="-Xlinker -Bstatic" |
---|
964 | else |
---|
965 | CXXTEMPFLAGS="" |
---|
966 | CXXNOOPTFLAGS=$CXXFLAGS |
---|
967 | STATIC_LDFLAGS="" |
---|
968 | fi |
---|
969 | |
---|
970 | |
---|
971 | |
---|
972 | |
---|
973 | if test "${GCC}" = yes && test "$ac_cflags_set" = no ; then |
---|
974 | CFLAGS="-O3 -w -fomit-frame-pointer" |
---|
975 | fi |
---|
976 | |
---|
977 | echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6 |
---|
978 | set dummy ${MAKE-make}; ac_make=$2 |
---|
979 | if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then |
---|
980 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
981 | else |
---|
982 | cat > conftestmake <<\EOF |
---|
983 | all: |
---|
984 | @echo 'ac_maketemp="${MAKE}"' |
---|
985 | EOF |
---|
986 | # GNU make sometimes prints "make[1]: Entering...", which would confuse us. |
---|
987 | eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=` |
---|
988 | if test -n "$ac_maketemp"; then |
---|
989 | eval ac_cv_prog_make_${ac_make}_set=yes |
---|
990 | else |
---|
991 | eval ac_cv_prog_make_${ac_make}_set=no |
---|
992 | fi |
---|
993 | rm -f conftestmake |
---|
994 | fi |
---|
995 | if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then |
---|
996 | echo "$ac_t""yes" 1>&6 |
---|
997 | SET_MAKE= |
---|
998 | else |
---|
999 | echo "$ac_t""no" 1>&6 |
---|
1000 | SET_MAKE="MAKE=${MAKE-make}" |
---|
1001 | fi |
---|
1002 | |
---|
1003 | |
---|
1004 | |
---|
1005 | |
---|
1006 | |
---|
1007 | # expand prefix |
---|
1008 | test "x$prefix" = xNONE && prefix=$ac_default_prefix |
---|
1009 | if test "${with_rootdir+set}" != set; then |
---|
1010 | cat >> confdefs.h <<EOF |
---|
1011 | #define SINGULAR_ROOT_DIR "${prefix}" |
---|
1012 | EOF |
---|
1013 | |
---|
1014 | else |
---|
1015 | cat >> confdefs.h <<EOF |
---|
1016 | #define SINGULAR_ROOT_DIR "${with_rootdir}" |
---|
1017 | EOF |
---|
1018 | |
---|
1019 | fi |
---|
1020 | |
---|
1021 | # expand exec_prefix |
---|
1022 | if test "x$exec_prefix" = xNONE; then |
---|
1023 | if test -x "singuname.sh"; then |
---|
1024 | singuname="/bin/sh singuname.sh" |
---|
1025 | elif test -x "../singuname.sh"; then |
---|
1026 | singuname="/bin/sh ../singuname.sh" |
---|
1027 | else |
---|
1028 | echo "configure: warning: did not find singuname.sh use uname" 1>&2 |
---|
1029 | singuname="uname" |
---|
1030 | fi |
---|
1031 | if ($singuname >/dev/null 2>&1) then |
---|
1032 | exec_prefix=${prefix}/`$singuname` |
---|
1033 | else |
---|
1034 | { echo "configure: error: Unknown architecture: Check $singuname" 1>&2; exit 1; } |
---|
1035 | fi |
---|
1036 | fi |
---|
1037 | |
---|
1038 | # expand bindir |
---|
1039 | test "x$bindir" = 'x${exec_prefix}/bin' && bindir="${exec_prefix}/bin" |
---|
1040 | SINGULAR=${SINGULAR:-$bindir/Singular-$SINGULAR_MAJOR_VERSION.$SINGULAR_MINOR_VERSION.$SINGULAR_SUB_VERSION} |
---|
1041 | |
---|
1042 | cat >> confdefs.h <<EOF |
---|
1043 | #define SINGULAR_BIN_DIR "${bindir}" |
---|
1044 | EOF |
---|
1045 | |
---|
1046 | |
---|
1047 | # expand libdir |
---|
1048 | test "x$libdir" = 'x${exec_prefix}/lib'&& libdir="${exec_prefix}/lib/${SINGULAR_VERSION}" |
---|
1049 | |
---|
1050 | # expand includedir |
---|
1051 | test "x$includedir" = 'x${prefix}/include' && includedir="${exec_prefix}/include/${SINGULAR_VERSION}" |
---|
1052 | |
---|
1053 | # add to -I to CPPFLAGS and and -L to LDFLAGS, just to be sure |
---|
1054 | LDFLAGS="-L${libdir} ${LDFLAGS}" |
---|
1055 | CPPFLAGS="-I${includedir} ${CPPFLAGS}" |
---|
1056 | |
---|
1057 | |
---|
1058 | |
---|
1059 | # lex |
---|
1060 | if test "${with_lex+set}" != set; then |
---|
1061 | echo $ac_n "checking for flex""... $ac_c" 1>&6 |
---|
1062 | if eval "test \"`echo '$''{'ac_cv_prog_flex'+set}'`\" = set"; then |
---|
1063 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1064 | else |
---|
1065 | if (flex --version >/dev/null 2>&1) |
---|
1066 | then |
---|
1067 | if (flex --version | egrep "[2-9]\.[4-9]" >/dev/null 2>&1) |
---|
1068 | then |
---|
1069 | ac_cv_prog_flex=flex |
---|
1070 | fi |
---|
1071 | fi |
---|
1072 | |
---|
1073 | fi |
---|
1074 | |
---|
1075 | if test "${ac_cv_prog_flex+set}" = set; then |
---|
1076 | echo "$ac_t""flex" 1>&6 |
---|
1077 | LEX=flex |
---|
1078 | |
---|
1079 | else |
---|
1080 | { echo "configure: error: can not find flex with version greater 2.4" 1>&2; exit 1; } |
---|
1081 | fi |
---|
1082 | elif test "${with_lex}" = no; then |
---|
1083 | echo "configure: warning: building without lex -- make might fail" 1>&2 |
---|
1084 | else |
---|
1085 | unset LEX |
---|
1086 | unset ac_cv_prog_LEX |
---|
1087 | for ac_prog in ${with_lex} |
---|
1088 | do |
---|
1089 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
---|
1090 | set dummy $ac_prog; ac_word=$2 |
---|
1091 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
---|
1092 | if eval "test \"`echo '$''{'ac_cv_prog_LEX'+set}'`\" = set"; then |
---|
1093 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1094 | else |
---|
1095 | if test -n "$LEX"; then |
---|
1096 | ac_cv_prog_LEX="$LEX" # Let the user override the test. |
---|
1097 | else |
---|
1098 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" |
---|
1099 | for ac_dir in $PATH; do |
---|
1100 | test -z "$ac_dir" && ac_dir=. |
---|
1101 | if test -f $ac_dir/$ac_word; then |
---|
1102 | ac_cv_prog_LEX="$ac_prog" |
---|
1103 | break |
---|
1104 | fi |
---|
1105 | done |
---|
1106 | IFS="$ac_save_ifs" |
---|
1107 | fi |
---|
1108 | fi |
---|
1109 | LEX="$ac_cv_prog_LEX" |
---|
1110 | if test -n "$LEX"; then |
---|
1111 | echo "$ac_t""$LEX" 1>&6 |
---|
1112 | else |
---|
1113 | echo "$ac_t""no" 1>&6 |
---|
1114 | fi |
---|
1115 | |
---|
1116 | test -n "$LEX" && break |
---|
1117 | done |
---|
1118 | |
---|
1119 | if test "x${LEX}" = x; then |
---|
1120 | echo "configure: warning: building without lex -- make might fail" 1>&2 |
---|
1121 | fi |
---|
1122 | fi |
---|
1123 | |
---|
1124 | # perl version 5 |
---|
1125 | if test "${with_perl5+set}" != set; then |
---|
1126 | echo $ac_n "checking for perl5""... $ac_c" 1>&6 |
---|
1127 | if eval "test \"`echo '$''{'ac_cv_prog_perl5'+set}'`\" = set"; then |
---|
1128 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1129 | else |
---|
1130 | if (perl5 -v >/dev/null 2>&1) |
---|
1131 | then |
---|
1132 | if (perl5 -v | egrep "version 5\.[0-9]" >/dev/null 2>&1 ) |
---|
1133 | then |
---|
1134 | ac_cv_prog_perl5=perl5 |
---|
1135 | fi |
---|
1136 | elif (perl -v >/dev/null 2>&1) |
---|
1137 | then |
---|
1138 | if (perl -v | egrep "version 5\.[0-9]" >/dev/null 2>&1 ) |
---|
1139 | then |
---|
1140 | ac_cv_prog_perl5=perl |
---|
1141 | fi |
---|
1142 | fi |
---|
1143 | |
---|
1144 | fi |
---|
1145 | |
---|
1146 | if test "${ac_cv_prog_perl5+set}" = set; then |
---|
1147 | echo "$ac_t""${ac_cv_prog_perl5}" 1>&6 |
---|
1148 | PERL5=${ac_cv_prog_perl5} |
---|
1149 | |
---|
1150 | else |
---|
1151 | { echo "configure: error: can not find perl version 5" 1>&2; exit 1; } |
---|
1152 | fi |
---|
1153 | elif test "${with_perl5}" = no; then |
---|
1154 | echo "configure: warning: building without perl5 -- make might fail" 1>&2 |
---|
1155 | else |
---|
1156 | unset PERL5 |
---|
1157 | unset ac_cv_prog_PERL5 |
---|
1158 | for ac_prog in ${with_perl5} |
---|
1159 | do |
---|
1160 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
---|
1161 | set dummy $ac_prog; ac_word=$2 |
---|
1162 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
---|
1163 | if eval "test \"`echo '$''{'ac_cv_prog_PERL5'+set}'`\" = set"; then |
---|
1164 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1165 | else |
---|
1166 | if test -n "$PERL5"; then |
---|
1167 | ac_cv_prog_PERL5="$PERL5" # Let the user override the test. |
---|
1168 | else |
---|
1169 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" |
---|
1170 | for ac_dir in $PATH; do |
---|
1171 | test -z "$ac_dir" && ac_dir=. |
---|
1172 | if test -f $ac_dir/$ac_word; then |
---|
1173 | ac_cv_prog_PERL5="$ac_prog" |
---|
1174 | break |
---|
1175 | fi |
---|
1176 | done |
---|
1177 | IFS="$ac_save_ifs" |
---|
1178 | fi |
---|
1179 | fi |
---|
1180 | PERL5="$ac_cv_prog_PERL5" |
---|
1181 | if test -n "$PERL5"; then |
---|
1182 | echo "$ac_t""$PERL5" 1>&6 |
---|
1183 | else |
---|
1184 | echo "$ac_t""no" 1>&6 |
---|
1185 | fi |
---|
1186 | |
---|
1187 | test -n "$PERL5" && break |
---|
1188 | done |
---|
1189 | |
---|
1190 | if test "x${PERL5}" = x; then |
---|
1191 | echo "configure: warning: building without perl5 -- make might fail" 1>&2 |
---|
1192 | fi |
---|
1193 | fi |
---|
1194 | |
---|
1195 | # bison |
---|
1196 | for ac_prog in bison |
---|
1197 | do |
---|
1198 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
---|
1199 | set dummy $ac_prog; ac_word=$2 |
---|
1200 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
---|
1201 | if eval "test \"`echo '$''{'ac_cv_prog_BISON'+set}'`\" = set"; then |
---|
1202 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1203 | else |
---|
1204 | if test -n "$BISON"; then |
---|
1205 | ac_cv_prog_BISON="$BISON" # Let the user override the test. |
---|
1206 | else |
---|
1207 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" |
---|
1208 | for ac_dir in $PATH; do |
---|
1209 | test -z "$ac_dir" && ac_dir=. |
---|
1210 | if test -f $ac_dir/$ac_word; then |
---|
1211 | ac_cv_prog_BISON="$ac_prog" |
---|
1212 | break |
---|
1213 | fi |
---|
1214 | done |
---|
1215 | IFS="$ac_save_ifs" |
---|
1216 | fi |
---|
1217 | fi |
---|
1218 | BISON="$ac_cv_prog_BISON" |
---|
1219 | if test -n "$BISON"; then |
---|
1220 | echo "$ac_t""$BISON" 1>&6 |
---|
1221 | else |
---|
1222 | echo "$ac_t""no" 1>&6 |
---|
1223 | fi |
---|
1224 | |
---|
1225 | test -n "$BISON" && break |
---|
1226 | done |
---|
1227 | |
---|
1228 | if test "${BISON+set}" != set; then |
---|
1229 | echo "configure: warning: did not find bison -- make might fail" 1>&2 |
---|
1230 | fi |
---|
1231 | |
---|
1232 | if test "${with_info+set}" != set; then |
---|
1233 | for ac_prog in info |
---|
1234 | do |
---|
1235 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
---|
1236 | set dummy $ac_prog; ac_word=$2 |
---|
1237 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
---|
1238 | if eval "test \"`echo '$''{'ac_cv_prog_INFO'+set}'`\" = set"; then |
---|
1239 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1240 | else |
---|
1241 | if test -n "$INFO"; then |
---|
1242 | ac_cv_prog_INFO="$INFO" # Let the user override the test. |
---|
1243 | else |
---|
1244 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" |
---|
1245 | for ac_dir in $PATH; do |
---|
1246 | test -z "$ac_dir" && ac_dir=. |
---|
1247 | if test -f $ac_dir/$ac_word; then |
---|
1248 | ac_cv_prog_INFO="$ac_prog" |
---|
1249 | break |
---|
1250 | fi |
---|
1251 | done |
---|
1252 | IFS="$ac_save_ifs" |
---|
1253 | fi |
---|
1254 | fi |
---|
1255 | INFO="$ac_cv_prog_INFO" |
---|
1256 | if test -n "$INFO"; then |
---|
1257 | echo "$ac_t""$INFO" 1>&6 |
---|
1258 | else |
---|
1259 | echo "$ac_t""no" 1>&6 |
---|
1260 | fi |
---|
1261 | |
---|
1262 | test -n "$INFO" && break |
---|
1263 | done |
---|
1264 | test -n "$INFO" || INFO="notfound" |
---|
1265 | |
---|
1266 | if test "${INFO}" = notfound; then |
---|
1267 | { echo "configure: error: did not find info" 1>&2; exit 1; } |
---|
1268 | fi |
---|
1269 | cat >> confdefs.h <<EOF |
---|
1270 | #define HAVE_INFO "info" |
---|
1271 | EOF |
---|
1272 | |
---|
1273 | elif test "$with_info" != no; then |
---|
1274 | unset INFO |
---|
1275 | unset ac_cv_prog_INFO |
---|
1276 | for ac_prog in ${with_info} |
---|
1277 | do |
---|
1278 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
---|
1279 | set dummy $ac_prog; ac_word=$2 |
---|
1280 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
---|
1281 | if eval "test \"`echo '$''{'ac_cv_prog_INFO'+set}'`\" = set"; then |
---|
1282 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1283 | else |
---|
1284 | if test -n "$INFO"; then |
---|
1285 | ac_cv_prog_INFO="$INFO" # Let the user override the test. |
---|
1286 | else |
---|
1287 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" |
---|
1288 | for ac_dir in $PATH; do |
---|
1289 | test -z "$ac_dir" && ac_dir=. |
---|
1290 | if test -f $ac_dir/$ac_word; then |
---|
1291 | ac_cv_prog_INFO="$ac_prog" |
---|
1292 | break |
---|
1293 | fi |
---|
1294 | done |
---|
1295 | IFS="$ac_save_ifs" |
---|
1296 | fi |
---|
1297 | fi |
---|
1298 | INFO="$ac_cv_prog_INFO" |
---|
1299 | if test -n "$INFO"; then |
---|
1300 | echo "$ac_t""$INFO" 1>&6 |
---|
1301 | else |
---|
1302 | echo "$ac_t""no" 1>&6 |
---|
1303 | fi |
---|
1304 | |
---|
1305 | test -n "$INFO" && break |
---|
1306 | done |
---|
1307 | test -n "$INFO" || INFO="notfound" |
---|
1308 | |
---|
1309 | if test "${INFO}" = notfound; then |
---|
1310 | { echo "configure: error: did not find ${with_info}" 1>&2; exit 1; } |
---|
1311 | fi |
---|
1312 | cat >> confdefs.h <<EOF |
---|
1313 | #define HAVE_INFO "${with_info}" |
---|
1314 | EOF |
---|
1315 | |
---|
1316 | fi |
---|
1317 | |
---|
1318 | # ln -s |
---|
1319 | echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6 |
---|
1320 | if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then |
---|
1321 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1322 | else |
---|
1323 | rm -f conftestdata |
---|
1324 | if ln -s X conftestdata 2>/dev/null |
---|
1325 | then |
---|
1326 | rm -f conftestdata |
---|
1327 | ac_cv_prog_LN_S="ln -s" |
---|
1328 | else |
---|
1329 | ac_cv_prog_LN_S=ln |
---|
1330 | fi |
---|
1331 | fi |
---|
1332 | LN_S="$ac_cv_prog_LN_S" |
---|
1333 | if test "$ac_cv_prog_LN_S" = "ln -s"; then |
---|
1334 | echo "$ac_t""yes" 1>&6 |
---|
1335 | else |
---|
1336 | echo "$ac_t""no" 1>&6 |
---|
1337 | fi |
---|
1338 | |
---|
1339 | |
---|
1340 | # lib checks |
---|
1341 | echo $ac_n "checking for -lm""... $ac_c" 1>&6 |
---|
1342 | ac_lib_var=`echo m_atof | tr '.-/+' '___p'` |
---|
1343 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
---|
1344 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1345 | else |
---|
1346 | ac_save_LIBS="$LIBS" |
---|
1347 | LIBS="-lm $LIBS" |
---|
1348 | cat > conftest.$ac_ext <<EOF |
---|
1349 | #line 1350 "configure" |
---|
1350 | #include "confdefs.h" |
---|
1351 | /* Override any gcc2 internal prototype to avoid an error. */ |
---|
1352 | char atof(); |
---|
1353 | |
---|
1354 | int main() { return 0; } |
---|
1355 | int t() { |
---|
1356 | atof() |
---|
1357 | ; return 0; } |
---|
1358 | EOF |
---|
1359 | if { (eval echo configure:1360: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
---|
1360 | rm -rf conftest* |
---|
1361 | eval "ac_cv_lib_$ac_lib_var=yes" |
---|
1362 | else |
---|
1363 | rm -rf conftest* |
---|
1364 | eval "ac_cv_lib_$ac_lib_var=no" |
---|
1365 | fi |
---|
1366 | rm -f conftest* |
---|
1367 | LIBS="$ac_save_LIBS" |
---|
1368 | |
---|
1369 | fi |
---|
1370 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
---|
1371 | echo "$ac_t""yes" 1>&6 |
---|
1372 | ac_tr_lib=HAVE_LIB`echo m | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
---|
1373 | cat >> confdefs.h <<EOF |
---|
1374 | #define $ac_tr_lib 1 |
---|
1375 | EOF |
---|
1376 | |
---|
1377 | LIBS="-lm $LIBS" |
---|
1378 | |
---|
1379 | else |
---|
1380 | echo "$ac_t""no" 1>&6 |
---|
1381 | fi |
---|
1382 | |
---|
1383 | echo $ac_n "checking for -lbsd""... $ac_c" 1>&6 |
---|
1384 | ac_lib_var=`echo bsd_socket | tr '.-/+' '___p'` |
---|
1385 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
---|
1386 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1387 | else |
---|
1388 | ac_save_LIBS="$LIBS" |
---|
1389 | LIBS="-lbsd $LIBS" |
---|
1390 | cat > conftest.$ac_ext <<EOF |
---|
1391 | #line 1392 "configure" |
---|
1392 | #include "confdefs.h" |
---|
1393 | /* Override any gcc2 internal prototype to avoid an error. */ |
---|
1394 | char socket(); |
---|
1395 | |
---|
1396 | int main() { return 0; } |
---|
1397 | int t() { |
---|
1398 | socket() |
---|
1399 | ; return 0; } |
---|
1400 | EOF |
---|
1401 | if { (eval echo configure:1402: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
---|
1402 | rm -rf conftest* |
---|
1403 | eval "ac_cv_lib_$ac_lib_var=yes" |
---|
1404 | else |
---|
1405 | rm -rf conftest* |
---|
1406 | eval "ac_cv_lib_$ac_lib_var=no" |
---|
1407 | fi |
---|
1408 | rm -f conftest* |
---|
1409 | LIBS="$ac_save_LIBS" |
---|
1410 | |
---|
1411 | fi |
---|
1412 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
---|
1413 | echo "$ac_t""yes" 1>&6 |
---|
1414 | ac_tr_lib=HAVE_LIB`echo bsd | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
---|
1415 | cat >> confdefs.h <<EOF |
---|
1416 | #define $ac_tr_lib 1 |
---|
1417 | EOF |
---|
1418 | |
---|
1419 | LIBS="-lbsd $LIBS" |
---|
1420 | |
---|
1421 | else |
---|
1422 | echo "$ac_t""no" 1>&6 |
---|
1423 | fi |
---|
1424 | |
---|
1425 | echo $ac_n "checking for -lsocket""... $ac_c" 1>&6 |
---|
1426 | ac_lib_var=`echo socket_listen | tr '.-/+' '___p'` |
---|
1427 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
---|
1428 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1429 | else |
---|
1430 | ac_save_LIBS="$LIBS" |
---|
1431 | LIBS="-lsocket $LIBS" |
---|
1432 | cat > conftest.$ac_ext <<EOF |
---|
1433 | #line 1434 "configure" |
---|
1434 | #include "confdefs.h" |
---|
1435 | /* Override any gcc2 internal prototype to avoid an error. */ |
---|
1436 | char listen(); |
---|
1437 | |
---|
1438 | int main() { return 0; } |
---|
1439 | int t() { |
---|
1440 | listen() |
---|
1441 | ; return 0; } |
---|
1442 | EOF |
---|
1443 | if { (eval echo configure:1444: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
---|
1444 | rm -rf conftest* |
---|
1445 | eval "ac_cv_lib_$ac_lib_var=yes" |
---|
1446 | else |
---|
1447 | rm -rf conftest* |
---|
1448 | eval "ac_cv_lib_$ac_lib_var=no" |
---|
1449 | fi |
---|
1450 | rm -f conftest* |
---|
1451 | LIBS="$ac_save_LIBS" |
---|
1452 | |
---|
1453 | fi |
---|
1454 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
---|
1455 | echo "$ac_t""yes" 1>&6 |
---|
1456 | ac_tr_lib=HAVE_LIB`echo socket | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
---|
1457 | cat >> confdefs.h <<EOF |
---|
1458 | #define $ac_tr_lib 1 |
---|
1459 | EOF |
---|
1460 | |
---|
1461 | LIBS="-lsocket $LIBS" |
---|
1462 | |
---|
1463 | else |
---|
1464 | echo "$ac_t""no" 1>&6 |
---|
1465 | fi |
---|
1466 | |
---|
1467 | echo $ac_n "checking for -lnsl""... $ac_c" 1>&6 |
---|
1468 | ac_lib_var=`echo nsl_gethostbyname | tr '.-/+' '___p'` |
---|
1469 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
---|
1470 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1471 | else |
---|
1472 | ac_save_LIBS="$LIBS" |
---|
1473 | LIBS="-lnsl $LIBS" |
---|
1474 | cat > conftest.$ac_ext <<EOF |
---|
1475 | #line 1476 "configure" |
---|
1476 | #include "confdefs.h" |
---|
1477 | /* Override any gcc2 internal prototype to avoid an error. */ |
---|
1478 | char gethostbyname(); |
---|
1479 | |
---|
1480 | int main() { return 0; } |
---|
1481 | int t() { |
---|
1482 | gethostbyname() |
---|
1483 | ; return 0; } |
---|
1484 | EOF |
---|
1485 | if { (eval echo configure:1486: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
---|
1486 | rm -rf conftest* |
---|
1487 | eval "ac_cv_lib_$ac_lib_var=yes" |
---|
1488 | else |
---|
1489 | rm -rf conftest* |
---|
1490 | eval "ac_cv_lib_$ac_lib_var=no" |
---|
1491 | fi |
---|
1492 | rm -f conftest* |
---|
1493 | LIBS="$ac_save_LIBS" |
---|
1494 | |
---|
1495 | fi |
---|
1496 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
---|
1497 | echo "$ac_t""yes" 1>&6 |
---|
1498 | ac_tr_lib=HAVE_LIB`echo nsl | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
---|
1499 | cat >> confdefs.h <<EOF |
---|
1500 | #define $ac_tr_lib 1 |
---|
1501 | EOF |
---|
1502 | |
---|
1503 | LIBS="-lnsl $LIBS" |
---|
1504 | |
---|
1505 | else |
---|
1506 | echo "$ac_t""no" 1>&6 |
---|
1507 | fi |
---|
1508 | |
---|
1509 | echo $ac_n "checking for -lucb""... $ac_c" 1>&6 |
---|
1510 | ac_lib_var=`echo ucb_index | tr '.-/+' '___p'` |
---|
1511 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
---|
1512 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1513 | else |
---|
1514 | ac_save_LIBS="$LIBS" |
---|
1515 | LIBS="-lucb $LIBS" |
---|
1516 | cat > conftest.$ac_ext <<EOF |
---|
1517 | #line 1518 "configure" |
---|
1518 | #include "confdefs.h" |
---|
1519 | /* Override any gcc2 internal prototype to avoid an error. */ |
---|
1520 | char index(); |
---|
1521 | |
---|
1522 | int main() { return 0; } |
---|
1523 | int t() { |
---|
1524 | index() |
---|
1525 | ; return 0; } |
---|
1526 | EOF |
---|
1527 | if { (eval echo configure:1528: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
---|
1528 | rm -rf conftest* |
---|
1529 | eval "ac_cv_lib_$ac_lib_var=yes" |
---|
1530 | else |
---|
1531 | rm -rf conftest* |
---|
1532 | eval "ac_cv_lib_$ac_lib_var=no" |
---|
1533 | fi |
---|
1534 | rm -f conftest* |
---|
1535 | LIBS="$ac_save_LIBS" |
---|
1536 | |
---|
1537 | fi |
---|
1538 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
---|
1539 | echo "$ac_t""yes" 1>&6 |
---|
1540 | ac_tr_lib=HAVE_LIB`echo ucb | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
---|
1541 | cat >> confdefs.h <<EOF |
---|
1542 | #define $ac_tr_lib 1 |
---|
1543 | EOF |
---|
1544 | |
---|
1545 | LIBS="-lucb $LIBS" |
---|
1546 | |
---|
1547 | else |
---|
1548 | echo "$ac_t""no" 1>&6 |
---|
1549 | fi |
---|
1550 | |
---|
1551 | |
---|
1552 | # heder file checks |
---|
1553 | # If we cannot run a trivial program, we must be cross compiling. |
---|
1554 | echo $ac_n "checking whether cross-compiling""... $ac_c" 1>&6 |
---|
1555 | if eval "test \"`echo '$''{'ac_cv_c_cross'+set}'`\" = set"; then |
---|
1556 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1557 | else |
---|
1558 | if test "$cross_compiling" = yes; then |
---|
1559 | ac_cv_c_cross=yes |
---|
1560 | else |
---|
1561 | cat > conftest.$ac_ext <<EOF |
---|
1562 | #line 1563 "configure" |
---|
1563 | #include "confdefs.h" |
---|
1564 | main(){return(0);} |
---|
1565 | EOF |
---|
1566 | { (eval echo configure:1567: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } |
---|
1567 | if test -s conftest && (./conftest; exit) 2>/dev/null; then |
---|
1568 | ac_cv_c_cross=no |
---|
1569 | else |
---|
1570 | ac_cv_c_cross=yes |
---|
1571 | fi |
---|
1572 | fi |
---|
1573 | rm -fr conftest* |
---|
1574 | fi |
---|
1575 | |
---|
1576 | echo "$ac_t""$ac_cv_c_cross" 1>&6 |
---|
1577 | cross_compiling=$ac_cv_c_cross |
---|
1578 | |
---|
1579 | echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6 |
---|
1580 | if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then |
---|
1581 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1582 | else |
---|
1583 | cat > conftest.$ac_ext <<EOF |
---|
1584 | #line 1585 "configure" |
---|
1585 | #include "confdefs.h" |
---|
1586 | #include <stdlib.h> |
---|
1587 | #include <stdarg.h> |
---|
1588 | #include <string.h> |
---|
1589 | #include <float.h> |
---|
1590 | EOF |
---|
1591 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
---|
1592 | { (eval echo configure:1593: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
---|
1593 | ac_err=`grep -v '^ *+' conftest.out` |
---|
1594 | if test -z "$ac_err"; then |
---|
1595 | rm -rf conftest* |
---|
1596 | ac_cv_header_stdc=yes |
---|
1597 | else |
---|
1598 | echo "$ac_err" >&5 |
---|
1599 | rm -rf conftest* |
---|
1600 | ac_cv_header_stdc=no |
---|
1601 | fi |
---|
1602 | rm -f conftest* |
---|
1603 | |
---|
1604 | if test $ac_cv_header_stdc = yes; then |
---|
1605 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. |
---|
1606 | cat > conftest.$ac_ext <<EOF |
---|
1607 | #line 1608 "configure" |
---|
1608 | #include "confdefs.h" |
---|
1609 | #include <string.h> |
---|
1610 | EOF |
---|
1611 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
---|
1612 | egrep "memchr" >/dev/null 2>&1; then |
---|
1613 | : |
---|
1614 | else |
---|
1615 | rm -rf conftest* |
---|
1616 | ac_cv_header_stdc=no |
---|
1617 | fi |
---|
1618 | rm -f conftest* |
---|
1619 | |
---|
1620 | fi |
---|
1621 | |
---|
1622 | if test $ac_cv_header_stdc = yes; then |
---|
1623 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. |
---|
1624 | cat > conftest.$ac_ext <<EOF |
---|
1625 | #line 1626 "configure" |
---|
1626 | #include "confdefs.h" |
---|
1627 | #include <stdlib.h> |
---|
1628 | EOF |
---|
1629 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
---|
1630 | egrep "free" >/dev/null 2>&1; then |
---|
1631 | : |
---|
1632 | else |
---|
1633 | rm -rf conftest* |
---|
1634 | ac_cv_header_stdc=no |
---|
1635 | fi |
---|
1636 | rm -f conftest* |
---|
1637 | |
---|
1638 | fi |
---|
1639 | |
---|
1640 | if test $ac_cv_header_stdc = yes; then |
---|
1641 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. |
---|
1642 | if test "$cross_compiling" = yes; then |
---|
1643 | : |
---|
1644 | else |
---|
1645 | cat > conftest.$ac_ext <<EOF |
---|
1646 | #line 1647 "configure" |
---|
1647 | #include "confdefs.h" |
---|
1648 | #include <ctype.h> |
---|
1649 | #define ISLOWER(c) ('a' <= (c) && (c) <= 'z') |
---|
1650 | #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) |
---|
1651 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) |
---|
1652 | int main () { int i; for (i = 0; i < 256; i++) |
---|
1653 | if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2); |
---|
1654 | exit (0); } |
---|
1655 | |
---|
1656 | EOF |
---|
1657 | { (eval echo configure:1658: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } |
---|
1658 | if test -s conftest && (./conftest; exit) 2>/dev/null; then |
---|
1659 | : |
---|
1660 | else |
---|
1661 | ac_cv_header_stdc=no |
---|
1662 | fi |
---|
1663 | fi |
---|
1664 | rm -fr conftest* |
---|
1665 | fi |
---|
1666 | fi |
---|
1667 | |
---|
1668 | echo "$ac_t""$ac_cv_header_stdc" 1>&6 |
---|
1669 | if test $ac_cv_header_stdc = yes; then |
---|
1670 | cat >> confdefs.h <<\EOF |
---|
1671 | #define STDC_HEADERS 1 |
---|
1672 | EOF |
---|
1673 | |
---|
1674 | fi |
---|
1675 | |
---|
1676 | for ac_hdr in limits.h unistd.h |
---|
1677 | do |
---|
1678 | ac_safe=`echo "$ac_hdr" | tr './\055' '___'` |
---|
1679 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 |
---|
1680 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
---|
1681 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1682 | else |
---|
1683 | cat > conftest.$ac_ext <<EOF |
---|
1684 | #line 1685 "configure" |
---|
1685 | #include "confdefs.h" |
---|
1686 | #include <$ac_hdr> |
---|
1687 | EOF |
---|
1688 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
---|
1689 | { (eval echo configure:1690: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
---|
1690 | ac_err=`grep -v '^ *+' conftest.out` |
---|
1691 | if test -z "$ac_err"; then |
---|
1692 | rm -rf conftest* |
---|
1693 | eval "ac_cv_header_$ac_safe=yes" |
---|
1694 | else |
---|
1695 | echo "$ac_err" >&5 |
---|
1696 | rm -rf conftest* |
---|
1697 | eval "ac_cv_header_$ac_safe=no" |
---|
1698 | fi |
---|
1699 | rm -f conftest* |
---|
1700 | fi |
---|
1701 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
---|
1702 | echo "$ac_t""yes" 1>&6 |
---|
1703 | ac_tr_hdr=HAVE_`echo $ac_hdr | tr 'abcdefghijklmnopqrstuvwxyz./\055' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ___'` |
---|
1704 | cat >> confdefs.h <<EOF |
---|
1705 | #define $ac_tr_hdr 1 |
---|
1706 | EOF |
---|
1707 | |
---|
1708 | else |
---|
1709 | echo "$ac_t""no" 1>&6 |
---|
1710 | { echo "configure: error: Can not compile without limits.h unistd.h" 1>&2; exit 1; } |
---|
1711 | fi |
---|
1712 | done |
---|
1713 | |
---|
1714 | |
---|
1715 | for ac_hdr in sys/file.h sys/ioctl.h sys/time.h sys/times.h sys/types.h sys/stat.h fcntl.h sys/param.h pwd.h |
---|
1716 | do |
---|
1717 | ac_safe=`echo "$ac_hdr" | tr './\055' '___'` |
---|
1718 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 |
---|
1719 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
---|
1720 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1721 | else |
---|
1722 | cat > conftest.$ac_ext <<EOF |
---|
1723 | #line 1724 "configure" |
---|
1724 | #include "confdefs.h" |
---|
1725 | #include <$ac_hdr> |
---|
1726 | EOF |
---|
1727 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
---|
1728 | { (eval echo configure:1729: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
---|
1729 | ac_err=`grep -v '^ *+' conftest.out` |
---|
1730 | if test -z "$ac_err"; then |
---|
1731 | rm -rf conftest* |
---|
1732 | eval "ac_cv_header_$ac_safe=yes" |
---|
1733 | else |
---|
1734 | echo "$ac_err" >&5 |
---|
1735 | rm -rf conftest* |
---|
1736 | eval "ac_cv_header_$ac_safe=no" |
---|
1737 | fi |
---|
1738 | rm -f conftest* |
---|
1739 | fi |
---|
1740 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
---|
1741 | echo "$ac_t""yes" 1>&6 |
---|
1742 | ac_tr_hdr=HAVE_`echo $ac_hdr | tr 'abcdefghijklmnopqrstuvwxyz./\055' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ___'` |
---|
1743 | cat >> confdefs.h <<EOF |
---|
1744 | #define $ac_tr_hdr 1 |
---|
1745 | EOF |
---|
1746 | |
---|
1747 | else |
---|
1748 | echo "$ac_t""no" 1>&6 |
---|
1749 | fi |
---|
1750 | done |
---|
1751 | |
---|
1752 | |
---|
1753 | # typedefs, structures |
---|
1754 | echo $ac_n "checking for working const""... $ac_c" 1>&6 |
---|
1755 | if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then |
---|
1756 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1757 | else |
---|
1758 | cat > conftest.$ac_ext <<EOF |
---|
1759 | #line 1760 "configure" |
---|
1760 | #include "confdefs.h" |
---|
1761 | |
---|
1762 | int main() { return 0; } |
---|
1763 | int t() { |
---|
1764 | |
---|
1765 | /* Ultrix mips cc rejects this. */ |
---|
1766 | typedef int charset[2]; const charset x; |
---|
1767 | /* SunOS 4.1.1 cc rejects this. */ |
---|
1768 | char const *const *ccp; |
---|
1769 | char **p; |
---|
1770 | /* NEC SVR4.0.2 mips cc rejects this. */ |
---|
1771 | struct point {int x, y;}; |
---|
1772 | static struct point const zero = {0,0}; |
---|
1773 | /* AIX XL C 1.02.0.0 rejects this. |
---|
1774 | It does not let you subtract one const X* pointer from another in an arm |
---|
1775 | of an if-expression whose if-part is not a constant expression */ |
---|
1776 | const char *g = "string"; |
---|
1777 | ccp = &g + (g ? g-g : 0); |
---|
1778 | /* HPUX 7.0 cc rejects these. */ |
---|
1779 | ++ccp; |
---|
1780 | p = (char**) ccp; |
---|
1781 | ccp = (char const *const *) p; |
---|
1782 | { /* SCO 3.2v4 cc rejects this. */ |
---|
1783 | char *t; |
---|
1784 | char const *s = 0 ? (char *) 0 : (char const *) 0; |
---|
1785 | |
---|
1786 | *t++ = 0; |
---|
1787 | } |
---|
1788 | { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ |
---|
1789 | int x[] = {25, 17}; |
---|
1790 | const int *foo = &x[0]; |
---|
1791 | ++foo; |
---|
1792 | } |
---|
1793 | { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ |
---|
1794 | typedef const int *iptr; |
---|
1795 | iptr p = 0; |
---|
1796 | ++p; |
---|
1797 | } |
---|
1798 | { /* AIX XL C 1.02.0.0 rejects this saying |
---|
1799 | "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ |
---|
1800 | struct s { int j; const int *ap[3]; }; |
---|
1801 | struct s *b; b->j = 5; |
---|
1802 | } |
---|
1803 | { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ |
---|
1804 | const int foo = 10; |
---|
1805 | } |
---|
1806 | |
---|
1807 | ; return 0; } |
---|
1808 | EOF |
---|
1809 | if { (eval echo configure:1810: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
---|
1810 | rm -rf conftest* |
---|
1811 | ac_cv_c_const=yes |
---|
1812 | else |
---|
1813 | rm -rf conftest* |
---|
1814 | ac_cv_c_const=no |
---|
1815 | fi |
---|
1816 | rm -f conftest* |
---|
1817 | |
---|
1818 | fi |
---|
1819 | |
---|
1820 | echo "$ac_t""$ac_cv_c_const" 1>&6 |
---|
1821 | if test $ac_cv_c_const = no; then |
---|
1822 | cat >> confdefs.h <<\EOF |
---|
1823 | #define const |
---|
1824 | EOF |
---|
1825 | |
---|
1826 | fi |
---|
1827 | |
---|
1828 | echo $ac_n "checking for inline""... $ac_c" 1>&6 |
---|
1829 | if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then |
---|
1830 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1831 | else |
---|
1832 | ac_cv_c_inline=no |
---|
1833 | for ac_kw in inline __inline__ __inline; do |
---|
1834 | cat > conftest.$ac_ext <<EOF |
---|
1835 | #line 1836 "configure" |
---|
1836 | #include "confdefs.h" |
---|
1837 | |
---|
1838 | int main() { return 0; } |
---|
1839 | int t() { |
---|
1840 | } $ac_kw foo() { |
---|
1841 | ; return 0; } |
---|
1842 | EOF |
---|
1843 | if { (eval echo configure:1844: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
---|
1844 | rm -rf conftest* |
---|
1845 | ac_cv_c_inline=$ac_kw; break |
---|
1846 | fi |
---|
1847 | rm -f conftest* |
---|
1848 | |
---|
1849 | done |
---|
1850 | |
---|
1851 | fi |
---|
1852 | |
---|
1853 | echo "$ac_t""$ac_cv_c_inline" 1>&6 |
---|
1854 | case "$ac_cv_c_inline" in |
---|
1855 | inline | yes) ;; |
---|
1856 | no) cat >> confdefs.h <<\EOF |
---|
1857 | #define inline |
---|
1858 | EOF |
---|
1859 | ;; |
---|
1860 | *) cat >> confdefs.h <<EOF |
---|
1861 | #define inline $ac_cv_c_inline |
---|
1862 | EOF |
---|
1863 | ;; |
---|
1864 | esac |
---|
1865 | |
---|
1866 | echo $ac_n "checking for size_t""... $ac_c" 1>&6 |
---|
1867 | if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then |
---|
1868 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1869 | else |
---|
1870 | cat > conftest.$ac_ext <<EOF |
---|
1871 | #line 1872 "configure" |
---|
1872 | #include "confdefs.h" |
---|
1873 | #include <sys/types.h> |
---|
1874 | #if STDC_HEADERS |
---|
1875 | #include <stdlib.h> |
---|
1876 | #endif |
---|
1877 | EOF |
---|
1878 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
---|
1879 | egrep "size_t" >/dev/null 2>&1; then |
---|
1880 | rm -rf conftest* |
---|
1881 | ac_cv_type_size_t=yes |
---|
1882 | else |
---|
1883 | rm -rf conftest* |
---|
1884 | ac_cv_type_size_t=no |
---|
1885 | fi |
---|
1886 | rm -f conftest* |
---|
1887 | |
---|
1888 | fi |
---|
1889 | echo "$ac_t""$ac_cv_type_size_t" 1>&6 |
---|
1890 | if test $ac_cv_type_size_t = no; then |
---|
1891 | cat >> confdefs.h <<\EOF |
---|
1892 | #define size_t unsigned |
---|
1893 | EOF |
---|
1894 | |
---|
1895 | fi |
---|
1896 | |
---|
1897 | echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6 |
---|
1898 | if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then |
---|
1899 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1900 | else |
---|
1901 | cat > conftest.$ac_ext <<EOF |
---|
1902 | #line 1903 "configure" |
---|
1903 | #include "confdefs.h" |
---|
1904 | #include <sys/types.h> |
---|
1905 | #include <sys/time.h> |
---|
1906 | #include <time.h> |
---|
1907 | int main() { return 0; } |
---|
1908 | int t() { |
---|
1909 | struct tm *tp; |
---|
1910 | ; return 0; } |
---|
1911 | EOF |
---|
1912 | if { (eval echo configure:1913: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
---|
1913 | rm -rf conftest* |
---|
1914 | ac_cv_header_time=yes |
---|
1915 | else |
---|
1916 | rm -rf conftest* |
---|
1917 | ac_cv_header_time=no |
---|
1918 | fi |
---|
1919 | rm -f conftest* |
---|
1920 | |
---|
1921 | fi |
---|
1922 | |
---|
1923 | echo "$ac_t""$ac_cv_header_time" 1>&6 |
---|
1924 | if test $ac_cv_header_time = yes; then |
---|
1925 | cat >> confdefs.h <<\EOF |
---|
1926 | #define TIME_WITH_SYS_TIME 1 |
---|
1927 | EOF |
---|
1928 | |
---|
1929 | fi |
---|
1930 | |
---|
1931 | echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&6 |
---|
1932 | if eval "test \"`echo '$''{'ac_cv_struct_tm'+set}'`\" = set"; then |
---|
1933 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1934 | else |
---|
1935 | cat > conftest.$ac_ext <<EOF |
---|
1936 | #line 1937 "configure" |
---|
1937 | #include "confdefs.h" |
---|
1938 | #include <sys/types.h> |
---|
1939 | #include <time.h> |
---|
1940 | int main() { return 0; } |
---|
1941 | int t() { |
---|
1942 | struct tm *tp; tp->tm_sec; |
---|
1943 | ; return 0; } |
---|
1944 | EOF |
---|
1945 | if { (eval echo configure:1946: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
---|
1946 | rm -rf conftest* |
---|
1947 | ac_cv_struct_tm=time.h |
---|
1948 | else |
---|
1949 | rm -rf conftest* |
---|
1950 | ac_cv_struct_tm=sys/time.h |
---|
1951 | fi |
---|
1952 | rm -f conftest* |
---|
1953 | |
---|
1954 | fi |
---|
1955 | |
---|
1956 | echo "$ac_t""$ac_cv_struct_tm" 1>&6 |
---|
1957 | if test $ac_cv_struct_tm = sys/time.h; then |
---|
1958 | cat >> confdefs.h <<\EOF |
---|
1959 | #define TM_IN_SYS_TIME 1 |
---|
1960 | EOF |
---|
1961 | |
---|
1962 | fi |
---|
1963 | |
---|
1964 | |
---|
1965 | # library functions. |
---|
1966 | # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works |
---|
1967 | # for constant arguments. Useless! |
---|
1968 | echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6 |
---|
1969 | if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then |
---|
1970 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1971 | else |
---|
1972 | cat > conftest.$ac_ext <<EOF |
---|
1973 | #line 1974 "configure" |
---|
1974 | #include "confdefs.h" |
---|
1975 | #include <alloca.h> |
---|
1976 | int main() { return 0; } |
---|
1977 | int t() { |
---|
1978 | char *p = alloca(2 * sizeof(int)); |
---|
1979 | ; return 0; } |
---|
1980 | EOF |
---|
1981 | if { (eval echo configure:1982: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
---|
1982 | rm -rf conftest* |
---|
1983 | ac_cv_header_alloca_h=yes |
---|
1984 | else |
---|
1985 | rm -rf conftest* |
---|
1986 | ac_cv_header_alloca_h=no |
---|
1987 | fi |
---|
1988 | rm -f conftest* |
---|
1989 | |
---|
1990 | fi |
---|
1991 | |
---|
1992 | echo "$ac_t""$ac_cv_header_alloca_h" 1>&6 |
---|
1993 | if test $ac_cv_header_alloca_h = yes; then |
---|
1994 | cat >> confdefs.h <<\EOF |
---|
1995 | #define HAVE_ALLOCA_H 1 |
---|
1996 | EOF |
---|
1997 | |
---|
1998 | fi |
---|
1999 | |
---|
2000 | echo $ac_n "checking for alloca""... $ac_c" 1>&6 |
---|
2001 | if eval "test \"`echo '$''{'ac_cv_func_alloca'+set}'`\" = set"; then |
---|
2002 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
2003 | else |
---|
2004 | cat > conftest.$ac_ext <<EOF |
---|
2005 | #line 2006 "configure" |
---|
2006 | #include "confdefs.h" |
---|
2007 | |
---|
2008 | #ifdef __GNUC__ |
---|
2009 | # define alloca __builtin_alloca |
---|
2010 | #else |
---|
2011 | # if HAVE_ALLOCA_H |
---|
2012 | # include <alloca.h> |
---|
2013 | # else |
---|
2014 | # ifdef _AIX |
---|
2015 | #pragma alloca |
---|
2016 | # else |
---|
2017 | # ifndef alloca /* predefined by HP cc +Olibcalls */ |
---|
2018 | char *alloca (); |
---|
2019 | # endif |
---|
2020 | # endif |
---|
2021 | # endif |
---|
2022 | #endif |
---|
2023 | |
---|
2024 | int main() { return 0; } |
---|
2025 | int t() { |
---|
2026 | char *p = (char *) alloca(1); |
---|
2027 | ; return 0; } |
---|
2028 | EOF |
---|
2029 | if { (eval echo configure:2030: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
---|
2030 | rm -rf conftest* |
---|
2031 | ac_cv_func_alloca=yes |
---|
2032 | else |
---|
2033 | rm -rf conftest* |
---|
2034 | ac_cv_func_alloca=no |
---|
2035 | fi |
---|
2036 | rm -f conftest* |
---|
2037 | |
---|
2038 | fi |
---|
2039 | |
---|
2040 | echo "$ac_t""$ac_cv_func_alloca" 1>&6 |
---|
2041 | if test $ac_cv_func_alloca = yes; then |
---|
2042 | cat >> confdefs.h <<\EOF |
---|
2043 | #define HAVE_ALLOCA 1 |
---|
2044 | EOF |
---|
2045 | |
---|
2046 | fi |
---|
2047 | |
---|
2048 | if test $ac_cv_func_alloca = no; then |
---|
2049 | # The SVR3 libPW and SVR4 libucb both contain incompatible functions |
---|
2050 | # that cause trouble. Some versions do not even contain alloca or |
---|
2051 | # contain a buggy version. If you still want to use their alloca, |
---|
2052 | # use ar to extract alloca.o from them instead of compiling alloca.c. |
---|
2053 | ALLOCA=alloca.o |
---|
2054 | cat >> confdefs.h <<\EOF |
---|
2055 | #define C_ALLOCA 1 |
---|
2056 | EOF |
---|
2057 | |
---|
2058 | |
---|
2059 | echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6 |
---|
2060 | if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then |
---|
2061 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
2062 | else |
---|
2063 | cat > conftest.$ac_ext <<EOF |
---|
2064 | #line 2065 "configure" |
---|
2065 | #include "confdefs.h" |
---|
2066 | #if defined(CRAY) && ! defined(CRAY2) |
---|
2067 | webecray |
---|
2068 | #else |
---|
2069 | wenotbecray |
---|
2070 | #endif |
---|
2071 | |
---|
2072 | EOF |
---|
2073 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
---|
2074 | egrep "webecray" >/dev/null 2>&1; then |
---|
2075 | rm -rf conftest* |
---|
2076 | ac_cv_os_cray=yes |
---|
2077 | else |
---|
2078 | rm -rf conftest* |
---|
2079 | ac_cv_os_cray=no |
---|
2080 | fi |
---|
2081 | rm -f conftest* |
---|
2082 | |
---|
2083 | fi |
---|
2084 | |
---|
2085 | echo "$ac_t""$ac_cv_os_cray" 1>&6 |
---|
2086 | if test $ac_cv_os_cray = yes; then |
---|
2087 | for ac_func in _getb67 GETB67 getb67; do |
---|
2088 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
---|
2089 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
---|
2090 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
2091 | else |
---|
2092 | cat > conftest.$ac_ext <<EOF |
---|
2093 | #line 2094 "configure" |
---|
2094 | #include "confdefs.h" |
---|
2095 | /* System header to define __stub macros and hopefully few prototypes, |
---|
2096 | which can conflict with char $ac_func(); below. */ |
---|
2097 | #include <assert.h> |
---|
2098 | /* Override any gcc2 internal prototype to avoid an error. */ |
---|
2099 | char $ac_func(); |
---|
2100 | |
---|
2101 | int main() { return 0; } |
---|
2102 | int t() { |
---|
2103 | |
---|
2104 | /* The GNU C library defines this for functions which it implements |
---|
2105 | to always fail with ENOSYS. Some functions are actually named |
---|
2106 | something starting with __ and the normal name is an alias. */ |
---|
2107 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
---|
2108 | choke me |
---|
2109 | #else |
---|
2110 | $ac_func(); |
---|
2111 | #endif |
---|
2112 | |
---|
2113 | ; return 0; } |
---|
2114 | EOF |
---|
2115 | if { (eval echo configure:2116: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
---|
2116 | rm -rf conftest* |
---|
2117 | eval "ac_cv_func_$ac_func=yes" |
---|
2118 | else |
---|
2119 | rm -rf conftest* |
---|
2120 | eval "ac_cv_func_$ac_func=no" |
---|
2121 | fi |
---|
2122 | rm -f conftest* |
---|
2123 | |
---|
2124 | fi |
---|
2125 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
---|
2126 | echo "$ac_t""yes" 1>&6 |
---|
2127 | cat >> confdefs.h <<EOF |
---|
2128 | #define CRAY_STACKSEG_END $ac_func |
---|
2129 | EOF |
---|
2130 | |
---|
2131 | break |
---|
2132 | else |
---|
2133 | echo "$ac_t""no" 1>&6 |
---|
2134 | fi |
---|
2135 | |
---|
2136 | done |
---|
2137 | fi |
---|
2138 | |
---|
2139 | echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6 |
---|
2140 | if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then |
---|
2141 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
2142 | else |
---|
2143 | if test "$cross_compiling" = yes; then |
---|
2144 | ac_cv_c_stack_direction=0 |
---|
2145 | else |
---|
2146 | cat > conftest.$ac_ext <<EOF |
---|
2147 | #line 2148 "configure" |
---|
2148 | #include "confdefs.h" |
---|
2149 | find_stack_direction () |
---|
2150 | { |
---|
2151 | static char *addr = 0; |
---|
2152 | auto char dummy; |
---|
2153 | if (addr == 0) |
---|
2154 | { |
---|
2155 | addr = &dummy; |
---|
2156 | return find_stack_direction (); |
---|
2157 | } |
---|
2158 | else |
---|
2159 | return (&dummy > addr) ? 1 : -1; |
---|
2160 | } |
---|
2161 | main () |
---|
2162 | { |
---|
2163 | exit (find_stack_direction() < 0); |
---|
2164 | } |
---|
2165 | EOF |
---|
2166 | { (eval echo configure:2167: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } |
---|
2167 | if test -s conftest && (./conftest; exit) 2>/dev/null; then |
---|
2168 | ac_cv_c_stack_direction=1 |
---|
2169 | else |
---|
2170 | ac_cv_c_stack_direction=-1 |
---|
2171 | fi |
---|
2172 | fi |
---|
2173 | rm -fr conftest* |
---|
2174 | fi |
---|
2175 | |
---|
2176 | echo "$ac_t""$ac_cv_c_stack_direction" 1>&6 |
---|
2177 | cat >> confdefs.h <<EOF |
---|
2178 | #define STACK_DIRECTION $ac_cv_c_stack_direction |
---|
2179 | EOF |
---|
2180 | |
---|
2181 | fi |
---|
2182 | |
---|
2183 | if test $ac_cv_prog_gcc = yes; then |
---|
2184 | echo $ac_n "checking whether ${CC-cc} needs -traditional""... $ac_c" 1>&6 |
---|
2185 | if eval "test \"`echo '$''{'ac_cv_prog_gcc_traditional'+set}'`\" = set"; then |
---|
2186 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
2187 | else |
---|
2188 | ac_pattern="Autoconf.*'x'" |
---|
2189 | cat > conftest.$ac_ext <<EOF |
---|
2190 | #line 2191 "configure" |
---|
2191 | #include "confdefs.h" |
---|
2192 | #include <sgtty.h> |
---|
2193 | Autoconf TIOCGETP |
---|
2194 | EOF |
---|
2195 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
---|
2196 | egrep "$ac_pattern" >/dev/null 2>&1; then |
---|
2197 | rm -rf conftest* |
---|
2198 | ac_cv_prog_gcc_traditional=yes |
---|
2199 | else |
---|
2200 | rm -rf conftest* |
---|
2201 | ac_cv_prog_gcc_traditional=no |
---|
2202 | fi |
---|
2203 | rm -f conftest* |
---|
2204 | |
---|
2205 | |
---|
2206 | if test $ac_cv_prog_gcc_traditional = no; then |
---|
2207 | cat > conftest.$ac_ext <<EOF |
---|
2208 | #line 2209 "configure" |
---|
2209 | #include "confdefs.h" |
---|
2210 | #include <termio.h> |
---|
2211 | Autoconf TCGETA |
---|
2212 | EOF |
---|
2213 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
---|
2214 | egrep "$ac_pattern" >/dev/null 2>&1; then |
---|
2215 | rm -rf conftest* |
---|
2216 | ac_cv_prog_gcc_traditional=yes |
---|
2217 | fi |
---|
2218 | rm -f conftest* |
---|
2219 | |
---|
2220 | fi |
---|
2221 | fi |
---|
2222 | |
---|
2223 | echo "$ac_t""$ac_cv_prog_gcc_traditional" 1>&6 |
---|
2224 | if test $ac_cv_prog_gcc_traditional = yes; then |
---|
2225 | CC="$CC -traditional" |
---|
2226 | fi |
---|
2227 | fi |
---|
2228 | |
---|
2229 | for ac_func in valloc getpagesize |
---|
2230 | do |
---|
2231 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
---|
2232 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
---|
2233 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
2234 | else |
---|
2235 | cat > conftest.$ac_ext <<EOF |
---|
2236 | #line 2237 "configure" |
---|
2237 | #include "confdefs.h" |
---|
2238 | /* System header to define __stub macros and hopefully few prototypes, |
---|
2239 | which can conflict with char $ac_func(); below. */ |
---|
2240 | #include <assert.h> |
---|
2241 | /* Override any gcc2 internal prototype to avoid an error. */ |
---|
2242 | char $ac_func(); |
---|
2243 | |
---|
2244 | int main() { return 0; } |
---|
2245 | int t() { |
---|
2246 | |
---|
2247 | /* The GNU C library defines this for functions which it implements |
---|
2248 | to always fail with ENOSYS. Some functions are actually named |
---|
2249 | something starting with __ and the normal name is an alias. */ |
---|
2250 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
---|
2251 | choke me |
---|
2252 | #else |
---|
2253 | $ac_func(); |
---|
2254 | #endif |
---|
2255 | |
---|
2256 | ; return 0; } |
---|
2257 | EOF |
---|
2258 | if { (eval echo configure:2259: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
---|
2259 | rm -rf conftest* |
---|
2260 | eval "ac_cv_func_$ac_func=yes" |
---|
2261 | else |
---|
2262 | rm -rf conftest* |
---|
2263 | eval "ac_cv_func_$ac_func=no" |
---|
2264 | fi |
---|
2265 | rm -f conftest* |
---|
2266 | |
---|
2267 | fi |
---|
2268 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
---|
2269 | echo "$ac_t""yes" 1>&6 |
---|
2270 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
---|
2271 | cat >> confdefs.h <<EOF |
---|
2272 | #define $ac_tr_func 1 |
---|
2273 | EOF |
---|
2274 | |
---|
2275 | else |
---|
2276 | echo "$ac_t""no" 1>&6 |
---|
2277 | fi |
---|
2278 | done |
---|
2279 | |
---|
2280 | echo $ac_n "checking for working mmap""... $ac_c" 1>&6 |
---|
2281 | if eval "test \"`echo '$''{'ac_cv_func_mmap'+set}'`\" = set"; then |
---|
2282 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
2283 | else |
---|
2284 | if test "$cross_compiling" = yes; then |
---|
2285 | ac_cv_func_mmap=no |
---|
2286 | else |
---|
2287 | cat > conftest.$ac_ext <<EOF |
---|
2288 | #line 2289 "configure" |
---|
2289 | #include "confdefs.h" |
---|
2290 | |
---|
2291 | /* Thanks to Mike Haertel and Jim Avera for this test. */ |
---|
2292 | #include <sys/types.h> |
---|
2293 | #include <fcntl.h> |
---|
2294 | #include <sys/mman.h> |
---|
2295 | |
---|
2296 | #ifndef HAVE_GETPAGESIZE |
---|
2297 | # include <sys/param.h> |
---|
2298 | # ifdef EXEC_PAGESIZE |
---|
2299 | # define getpagesize() EXEC_PAGESIZE |
---|
2300 | # else |
---|
2301 | # ifdef NBPG |
---|
2302 | # define getpagesize() NBPG * CLSIZE |
---|
2303 | # ifndef CLSIZE |
---|
2304 | # define CLSIZE 1 |
---|
2305 | # endif |
---|
2306 | # else |
---|
2307 | # ifdef NBPC |
---|
2308 | # define getpagesize() NBPC |
---|
2309 | # else |
---|
2310 | # define getpagesize() PAGESIZE /* SVR4 */ |
---|
2311 | # endif |
---|
2312 | # endif |
---|
2313 | # endif |
---|
2314 | #endif |
---|
2315 | |
---|
2316 | #ifndef HAVE_VALLOC |
---|
2317 | # define valloc malloc |
---|
2318 | #endif |
---|
2319 | |
---|
2320 | #ifdef __cplusplus |
---|
2321 | extern "C" { void *valloc(unsigned), *malloc(unsigned); } |
---|
2322 | #else |
---|
2323 | char *valloc(), *malloc(); |
---|
2324 | #endif |
---|
2325 | |
---|
2326 | int |
---|
2327 | main() |
---|
2328 | { |
---|
2329 | char *buf1, *buf2, *buf3; |
---|
2330 | int i = getpagesize(), j; |
---|
2331 | int i2 = i * 2; |
---|
2332 | int fd; |
---|
2333 | |
---|
2334 | buf1 = (char *)valloc(i2); |
---|
2335 | buf2 = (char *)valloc(i); |
---|
2336 | buf3 = (char *)malloc(i2); |
---|
2337 | for (j = 0; j < i2; ++j) |
---|
2338 | *(buf1 + j) = rand(); |
---|
2339 | fd = open("conftestmmap", O_CREAT | O_RDWR, 0666); |
---|
2340 | write(fd, buf1, i2); |
---|
2341 | mmap(buf2, i, PROT_READ | PROT_WRITE, MAP_FIXED | MAP_PRIVATE, fd, 0); |
---|
2342 | for (j = 0; j < i; ++j) |
---|
2343 | if (*(buf1 + j) != *(buf2 + j)) |
---|
2344 | exit(1); |
---|
2345 | lseek(fd, (long)i, 0); |
---|
2346 | read(fd, buf2, i); /* read into mapped memory -- file should not change */ |
---|
2347 | /* (it does in i386 SVR4.0 - Jim Avera, jima@netcom.com) */ |
---|
2348 | lseek(fd, (long)0, 0); |
---|
2349 | read(fd, buf3, i2); |
---|
2350 | for (j = 0; j < i2; ++j) |
---|
2351 | if (*(buf1 + j) != *(buf3 + j)) |
---|
2352 | exit(1); |
---|
2353 | exit(0); |
---|
2354 | } |
---|
2355 | |
---|
2356 | EOF |
---|
2357 | { (eval echo configure:2358: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } |
---|
2358 | if test -s conftest && (./conftest; exit) 2>/dev/null; then |
---|
2359 | ac_cv_func_mmap=yes |
---|
2360 | else |
---|
2361 | ac_cv_func_mmap=no |
---|
2362 | fi |
---|
2363 | fi |
---|
2364 | rm -fr conftest* |
---|
2365 | fi |
---|
2366 | |
---|
2367 | echo "$ac_t""$ac_cv_func_mmap" 1>&6 |
---|
2368 | if test $ac_cv_func_mmap = yes; then |
---|
2369 | cat >> confdefs.h <<\EOF |
---|
2370 | #define HAVE_MMAP 1 |
---|
2371 | EOF |
---|
2372 | |
---|
2373 | fi |
---|
2374 | |
---|
2375 | echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6 |
---|
2376 | if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then |
---|
2377 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
2378 | else |
---|
2379 | cat > conftest.$ac_ext <<EOF |
---|
2380 | #line 2381 "configure" |
---|
2381 | #include "confdefs.h" |
---|
2382 | #include <sys/types.h> |
---|
2383 | #include <signal.h> |
---|
2384 | #ifdef signal |
---|
2385 | #undef signal |
---|
2386 | #endif |
---|
2387 | #ifdef __cplusplus |
---|
2388 | extern "C" void (*signal (int, void (*)(int)))(int); |
---|
2389 | #else |
---|
2390 | void (*signal ()) (); |
---|
2391 | #endif |
---|
2392 | |
---|
2393 | int main() { return 0; } |
---|
2394 | int t() { |
---|
2395 | int i; |
---|
2396 | ; return 0; } |
---|
2397 | EOF |
---|
2398 | if { (eval echo configure:2399: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
---|
2399 | rm -rf conftest* |
---|
2400 | ac_cv_type_signal=void |
---|
2401 | else |
---|
2402 | rm -rf conftest* |
---|
2403 | ac_cv_type_signal=int |
---|
2404 | fi |
---|
2405 | rm -f conftest* |
---|
2406 | |
---|
2407 | fi |
---|
2408 | |
---|
2409 | echo "$ac_t""$ac_cv_type_signal" 1>&6 |
---|
2410 | cat >> confdefs.h <<EOF |
---|
2411 | #define RETSIGTYPE $ac_cv_type_signal |
---|
2412 | EOF |
---|
2413 | |
---|
2414 | |
---|
2415 | echo $ac_n "checking for vprintf""... $ac_c" 1>&6 |
---|
2416 | if eval "test \"`echo '$''{'ac_cv_func_vprintf'+set}'`\" = set"; then |
---|
2417 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
2418 | else |
---|
2419 | cat > conftest.$ac_ext <<EOF |
---|
2420 | #line 2421 "configure" |
---|
2421 | #include "confdefs.h" |
---|
2422 | /* System header to define __stub macros and hopefully few prototypes, |
---|
2423 | which can conflict with char vprintf(); below. */ |
---|
2424 | #include <assert.h> |
---|
2425 | /* Override any gcc2 internal prototype to avoid an error. */ |
---|
2426 | char vprintf(); |
---|
2427 | |
---|
2428 | int main() { return 0; } |
---|
2429 | int t() { |
---|
2430 | |
---|
2431 | /* The GNU C library defines this for functions which it implements |
---|
2432 | to always fail with ENOSYS. Some functions are actually named |
---|
2433 | something starting with __ and the normal name is an alias. */ |
---|
2434 | #if defined (__stub_vprintf) || defined (__stub___vprintf) |
---|
2435 | choke me |
---|
2436 | #else |
---|
2437 | vprintf(); |
---|
2438 | #endif |
---|
2439 | |
---|
2440 | ; return 0; } |
---|
2441 | EOF |
---|
2442 | if { (eval echo configure:2443: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
---|
2443 | rm -rf conftest* |
---|
2444 | eval "ac_cv_func_vprintf=yes" |
---|
2445 | else |
---|
2446 | rm -rf conftest* |
---|
2447 | eval "ac_cv_func_vprintf=no" |
---|
2448 | fi |
---|
2449 | rm -f conftest* |
---|
2450 | |
---|
2451 | fi |
---|
2452 | if eval "test \"`echo '$ac_cv_func_'vprintf`\" = yes"; then |
---|
2453 | echo "$ac_t""yes" 1>&6 |
---|
2454 | cat >> confdefs.h <<\EOF |
---|
2455 | #define HAVE_VPRINTF 1 |
---|
2456 | EOF |
---|
2457 | |
---|
2458 | else |
---|
2459 | echo "$ac_t""no" 1>&6 |
---|
2460 | fi |
---|
2461 | |
---|
2462 | if test "$ac_cv_func_vprintf" != yes; then |
---|
2463 | echo $ac_n "checking for _doprnt""... $ac_c" 1>&6 |
---|
2464 | if eval "test \"`echo '$''{'ac_cv_func__doprnt'+set}'`\" = set"; then |
---|
2465 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
2466 | else |
---|
2467 | cat > conftest.$ac_ext <<EOF |
---|
2468 | #line 2469 "configure" |
---|
2469 | #include "confdefs.h" |
---|
2470 | /* System header to define __stub macros and hopefully few prototypes, |
---|
2471 | which can conflict with char _doprnt(); below. */ |
---|
2472 | #include <assert.h> |
---|
2473 | /* Override any gcc2 internal prototype to avoid an error. */ |
---|
2474 | char _doprnt(); |
---|
2475 | |
---|
2476 | int main() { return 0; } |
---|
2477 | int t() { |
---|
2478 | |
---|
2479 | /* The GNU C library defines this for functions which it implements |
---|
2480 | to always fail with ENOSYS. Some functions are actually named |
---|
2481 | something starting with __ and the normal name is an alias. */ |
---|
2482 | #if defined (__stub__doprnt) || defined (__stub____doprnt) |
---|
2483 | choke me |
---|
2484 | #else |
---|
2485 | _doprnt(); |
---|
2486 | #endif |
---|
2487 | |
---|
2488 | ; return 0; } |
---|
2489 | EOF |
---|
2490 | if { (eval echo configure:2491: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
---|
2491 | rm -rf conftest* |
---|
2492 | eval "ac_cv_func__doprnt=yes" |
---|
2493 | else |
---|
2494 | rm -rf conftest* |
---|
2495 | eval "ac_cv_func__doprnt=no" |
---|
2496 | fi |
---|
2497 | rm -f conftest* |
---|
2498 | |
---|
2499 | fi |
---|
2500 | if eval "test \"`echo '$ac_cv_func_'_doprnt`\" = yes"; then |
---|
2501 | echo "$ac_t""yes" 1>&6 |
---|
2502 | cat >> confdefs.h <<\EOF |
---|
2503 | #define HAVE_DOPRNT 1 |
---|
2504 | EOF |
---|
2505 | |
---|
2506 | else |
---|
2507 | echo "$ac_t""no" 1>&6 |
---|
2508 | fi |
---|
2509 | |
---|
2510 | fi |
---|
2511 | |
---|
2512 | for ac_func in gettimeofday atexit bcopy getcwd getwd sbrk readlink sleep usleep |
---|
2513 | do |
---|
2514 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
---|
2515 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
---|
2516 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
2517 | else |
---|
2518 | cat > conftest.$ac_ext <<EOF |
---|
2519 | #line 2520 "configure" |
---|
2520 | #include "confdefs.h" |
---|
2521 | /* System header to define __stub macros and hopefully few prototypes, |
---|
2522 | which can conflict with char $ac_func(); below. */ |
---|
2523 | #include <assert.h> |
---|
2524 | /* Override any gcc2 internal prototype to avoid an error. */ |
---|
2525 | char $ac_func(); |
---|
2526 | |
---|
2527 | int main() { return 0; } |
---|
2528 | int t() { |
---|
2529 | |
---|
2530 | /* The GNU C library defines this for functions which it implements |
---|
2531 | to always fail with ENOSYS. Some functions are actually named |
---|
2532 | something starting with __ and the normal name is an alias. */ |
---|
2533 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
---|
2534 | choke me |
---|
2535 | #else |
---|
2536 | $ac_func(); |
---|
2537 | #endif |
---|
2538 | |
---|
2539 | ; return 0; } |
---|
2540 | EOF |
---|
2541 | if { (eval echo configure:2542: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
---|
2542 | rm -rf conftest* |
---|
2543 | eval "ac_cv_func_$ac_func=yes" |
---|
2544 | else |
---|
2545 | rm -rf conftest* |
---|
2546 | eval "ac_cv_func_$ac_func=no" |
---|
2547 | fi |
---|
2548 | rm -f conftest* |
---|
2549 | |
---|
2550 | fi |
---|
2551 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
---|
2552 | echo "$ac_t""yes" 1>&6 |
---|
2553 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
---|
2554 | cat >> confdefs.h <<EOF |
---|
2555 | #define $ac_tr_func 1 |
---|
2556 | EOF |
---|
2557 | |
---|
2558 | else |
---|
2559 | echo "$ac_t""no" 1>&6 |
---|
2560 | fi |
---|
2561 | done |
---|
2562 | |
---|
2563 | |
---|
2564 | |
---|
2565 | # arithmetic shifts |
---|
2566 | echo $ac_n "checking whether your machine has correct arithmetic shifts""... $ac_c" 1>&6 |
---|
2567 | if eval "test \"`echo '$''{'ac_cv_shift'+set}'`\" = set"; then |
---|
2568 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
2569 | else |
---|
2570 | if test "$cross_compiling" = yes; then |
---|
2571 | if test "$ac_c_cross_dos" = yes; then |
---|
2572 | ac_cv_shift=yes; |
---|
2573 | else |
---|
2574 | echo "$ac_t""no" 1>&6 |
---|
2575 | { echo "configure: error: cross compilation without default value" 1>&2; exit 1; } |
---|
2576 | fi |
---|
2577 | else |
---|
2578 | cat > conftest.$ac_ext <<EOF |
---|
2579 | #line 2580 "configure" |
---|
2580 | #include "confdefs.h" |
---|
2581 | int main() { if (-2 >> 1 == -1) exit(0); else exit(1); } |
---|
2582 | EOF |
---|
2583 | { (eval echo configure:2584: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } |
---|
2584 | if test -s conftest && (./conftest; exit) 2>/dev/null; then |
---|
2585 | ac_cv_shift=yes |
---|
2586 | else |
---|
2587 | ac_cv_shift=no |
---|
2588 | fi |
---|
2589 | fi |
---|
2590 | rm -fr conftest* |
---|
2591 | fi |
---|
2592 | |
---|
2593 | |
---|
2594 | if test "$ac_cv_shift" = yes; then |
---|
2595 | echo "$ac_t""yes" 1>&6 |
---|
2596 | else |
---|
2597 | echo "$ac_t""no" 1>&6 |
---|
2598 | { echo "configure: error: need -2 >> 1 == -1" 1>&2; exit 1; } |
---|
2599 | fi |
---|
2600 | |
---|
2601 | |
---|
2602 | # check for a peculiar constructor initialization |
---|
2603 | echo $ac_n "checking whether explicit C++ constructor calls are allowed""... $ac_c" 1>&6 |
---|
2604 | if eval "test \"`echo '$''{'ac_cv_explicit_const'+set}'`\" = set"; then |
---|
2605 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
2606 | else |
---|
2607 | cat > conftest.$ac_ext <<EOF |
---|
2608 | #line 2609 "configure" |
---|
2609 | #include "confdefs.h" |
---|
2610 | |
---|
2611 | int main() { return 0; } |
---|
2612 | int t() { |
---|
2613 | class testclass |
---|
2614 | { |
---|
2615 | public: |
---|
2616 | int value; |
---|
2617 | testclass( int i ) : value(i) {} |
---|
2618 | ~testclass() { value = 0; } |
---|
2619 | }; |
---|
2620 | |
---|
2621 | testclass ptr; |
---|
2622 | ptr.testclass(1); |
---|
2623 | |
---|
2624 | ; return 0; } |
---|
2625 | EOF |
---|
2626 | if { (eval echo configure:2627: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
---|
2627 | rm -rf conftest* |
---|
2628 | ac_cv_explicit_const=yes |
---|
2629 | else |
---|
2630 | rm -rf conftest* |
---|
2631 | ac_cv_explicit_const=no |
---|
2632 | fi |
---|
2633 | rm -f conftest* |
---|
2634 | |
---|
2635 | fi |
---|
2636 | |
---|
2637 | echo "$ac_t""$ac_cv_explicit_const" 1>&6 |
---|
2638 | if test "$ac_cv_explicit_const" = yes; then |
---|
2639 | cat >> confdefs.h <<\EOF |
---|
2640 | #define HAVE_EXPLICIT_CONSTR 1 |
---|
2641 | EOF |
---|
2642 | |
---|
2643 | fi |
---|
2644 | |
---|
2645 | # sprintf returns number of printed chars |
---|
2646 | echo $ac_n "checking whether vsprintf returns number of printed chars""... $ac_c" 1>&6 |
---|
2647 | if eval "test \"`echo '$''{'ac_cv_returns_n_of_chars'+set}'`\" = set"; then |
---|
2648 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
2649 | else |
---|
2650 | if test "$cross_compiling" = yes; then |
---|
2651 | ac_cv_returns_n_of_chars=no |
---|
2652 | else |
---|
2653 | cat > conftest.$ac_ext <<EOF |
---|
2654 | #line 2655 "configure" |
---|
2655 | #include "confdefs.h" |
---|
2656 | #include <stdio.h> |
---|
2657 | main() { char *str=(char*)malloc(20); if (((int) sprintf(str,"123456789")) == 9) exit(0); else exit(1); } |
---|
2658 | EOF |
---|
2659 | { (eval echo configure:2660: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } |
---|
2660 | if test -s conftest && (./conftest; exit) 2>/dev/null; then |
---|
2661 | ac_cv_returns_n_of_chars=yes |
---|
2662 | else |
---|
2663 | ac_cv_returns_n_of_chars=no |
---|
2664 | fi |
---|
2665 | fi |
---|
2666 | rm -fr conftest* |
---|
2667 | fi |
---|
2668 | |
---|
2669 | if test "$ac_cv_returns_n_of_chars" = yes; then |
---|
2670 | echo "$ac_t""yes" 1>&6 |
---|
2671 | else |
---|
2672 | echo "$ac_t""no" 1>&6 |
---|
2673 | cat >> confdefs.h <<\EOF |
---|
2674 | #define BSD_SPRINTF 1 |
---|
2675 | EOF |
---|
2676 | |
---|
2677 | fi |
---|
2678 | |
---|
2679 | # determine ALIGN_8 |
---|
2680 | echo $ac_n "checking size of char""... $ac_c" 1>&6 |
---|
2681 | if eval "test \"`echo '$''{'ac_cv_sizeof_char'+set}'`\" = set"; then |
---|
2682 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
2683 | else |
---|
2684 | if test "$cross_compiling" = yes; then |
---|
2685 | ac_cv_sizeof_char=1 |
---|
2686 | else |
---|
2687 | cat > conftest.$ac_ext <<EOF |
---|
2688 | #line 2689 "configure" |
---|
2689 | #include "confdefs.h" |
---|
2690 | #include <stdio.h> |
---|
2691 | main() |
---|
2692 | { |
---|
2693 | FILE *f=fopen("conftestval", "w"); |
---|
2694 | if (!f) exit(1); |
---|
2695 | fprintf(f, "%d\n", sizeof(char)); |
---|
2696 | exit(0); |
---|
2697 | } |
---|
2698 | EOF |
---|
2699 | { (eval echo configure:2700: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } |
---|
2700 | if test -s conftest && (./conftest; exit) 2>/dev/null; then |
---|
2701 | ac_cv_sizeof_char=`cat conftestval` |
---|
2702 | else |
---|
2703 | ac_cv_sizeof_char=0 |
---|
2704 | fi |
---|
2705 | fi |
---|
2706 | rm -fr conftest* |
---|
2707 | fi |
---|
2708 | echo "$ac_t""$ac_cv_sizeof_char" 1>&6 |
---|
2709 | cat >> confdefs.h <<EOF |
---|
2710 | #define SIZEOF_CHAR $ac_cv_sizeof_char |
---|
2711 | EOF |
---|
2712 | |
---|
2713 | |
---|
2714 | echo $ac_n "checking size of short""... $ac_c" 1>&6 |
---|
2715 | if eval "test \"`echo '$''{'ac_cv_sizeof_short'+set}'`\" = set"; then |
---|
2716 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
2717 | else |
---|
2718 | if test "$cross_compiling" = yes; then |
---|
2719 | ac_cv_sizeof_short=2 |
---|
2720 | else |
---|
2721 | cat > conftest.$ac_ext <<EOF |
---|
2722 | #line 2723 "configure" |
---|
2723 | #include "confdefs.h" |
---|
2724 | #include <stdio.h> |
---|
2725 | main() |
---|
2726 | { |
---|
2727 | FILE *f=fopen("conftestval", "w"); |
---|
2728 | if (!f) exit(1); |
---|
2729 | fprintf(f, "%d\n", sizeof(short)); |
---|
2730 | exit(0); |
---|
2731 | } |
---|
2732 | EOF |
---|
2733 | { (eval echo configure:2734: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } |
---|
2734 | if test -s conftest && (./conftest; exit) 2>/dev/null; then |
---|
2735 | ac_cv_sizeof_short=`cat conftestval` |
---|
2736 | else |
---|
2737 | ac_cv_sizeof_short=0 |
---|
2738 | fi |
---|
2739 | fi |
---|
2740 | rm -fr conftest* |
---|
2741 | fi |
---|
2742 | echo "$ac_t""$ac_cv_sizeof_short" 1>&6 |
---|
2743 | cat >> confdefs.h <<EOF |
---|
2744 | #define SIZEOF_SHORT $ac_cv_sizeof_short |
---|
2745 | EOF |
---|
2746 | |
---|
2747 | |
---|
2748 | echo $ac_n "checking size of int""... $ac_c" 1>&6 |
---|
2749 | if eval "test \"`echo '$''{'ac_cv_sizeof_int'+set}'`\" = set"; then |
---|
2750 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
2751 | else |
---|
2752 | if test "$cross_compiling" = yes; then |
---|
2753 | ac_cv_sizeof_int=4 |
---|
2754 | else |
---|
2755 | cat > conftest.$ac_ext <<EOF |
---|
2756 | #line 2757 "configure" |
---|
2757 | #include "confdefs.h" |
---|
2758 | #include <stdio.h> |
---|
2759 | main() |
---|
2760 | { |
---|
2761 | FILE *f=fopen("conftestval", "w"); |
---|
2762 | if (!f) exit(1); |
---|
2763 | fprintf(f, "%d\n", sizeof(int)); |
---|
2764 | exit(0); |
---|
2765 | } |
---|
2766 | EOF |
---|
2767 | { (eval echo configure:2768: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } |
---|
2768 | if test -s conftest && (./conftest; exit) 2>/dev/null; then |
---|
2769 | ac_cv_sizeof_int=`cat conftestval` |
---|
2770 | else |
---|
2771 | ac_cv_sizeof_int=0 |
---|
2772 | fi |
---|
2773 | fi |
---|
2774 | rm -fr conftest* |
---|
2775 | fi |
---|
2776 | echo "$ac_t""$ac_cv_sizeof_int" 1>&6 |
---|
2777 | cat >> confdefs.h <<EOF |
---|
2778 | #define SIZEOF_INT $ac_cv_sizeof_int |
---|
2779 | EOF |
---|
2780 | |
---|
2781 | |
---|
2782 | echo $ac_n "checking size of long""... $ac_c" 1>&6 |
---|
2783 | if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then |
---|
2784 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
2785 | else |
---|
2786 | if test "$cross_compiling" = yes; then |
---|
2787 | ac_cv_sizeof_long=4 |
---|
2788 | else |
---|
2789 | cat > conftest.$ac_ext <<EOF |
---|
2790 | #line 2791 "configure" |
---|
2791 | #include "confdefs.h" |
---|
2792 | #include <stdio.h> |
---|
2793 | main() |
---|
2794 | { |
---|
2795 | FILE *f=fopen("conftestval", "w"); |
---|
2796 | if (!f) exit(1); |
---|
2797 | fprintf(f, "%d\n", sizeof(long)); |
---|
2798 | exit(0); |
---|
2799 | } |
---|
2800 | EOF |
---|
2801 | { (eval echo configure:2802: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } |
---|
2802 | if test -s conftest && (./conftest; exit) 2>/dev/null; then |
---|
2803 | ac_cv_sizeof_long=`cat conftestval` |
---|
2804 | else |
---|
2805 | ac_cv_sizeof_long=0 |
---|
2806 | fi |
---|
2807 | fi |
---|
2808 | rm -fr conftest* |
---|
2809 | fi |
---|
2810 | echo "$ac_t""$ac_cv_sizeof_long" 1>&6 |
---|
2811 | cat >> confdefs.h <<EOF |
---|
2812 | #define SIZEOF_LONG $ac_cv_sizeof_long |
---|
2813 | EOF |
---|
2814 | |
---|
2815 | |
---|
2816 | echo $ac_n "checking size of void*""... $ac_c" 1>&6 |
---|
2817 | if eval "test \"`echo '$''{'ac_cv_sizeof_voidp'+set}'`\" = set"; then |
---|
2818 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
2819 | else |
---|
2820 | if test "$cross_compiling" = yes; then |
---|
2821 | ac_cv_sizeof_voidp=4 |
---|
2822 | else |
---|
2823 | cat > conftest.$ac_ext <<EOF |
---|
2824 | #line 2825 "configure" |
---|
2825 | #include "confdefs.h" |
---|
2826 | #include <stdio.h> |
---|
2827 | main() |
---|
2828 | { |
---|
2829 | FILE *f=fopen("conftestval", "w"); |
---|
2830 | if (!f) exit(1); |
---|
2831 | fprintf(f, "%d\n", sizeof(void*)); |
---|
2832 | exit(0); |
---|
2833 | } |
---|
2834 | EOF |
---|
2835 | { (eval echo configure:2836: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } |
---|
2836 | if test -s conftest && (./conftest; exit) 2>/dev/null; then |
---|
2837 | ac_cv_sizeof_voidp=`cat conftestval` |
---|
2838 | else |
---|
2839 | ac_cv_sizeof_voidp=0 |
---|
2840 | fi |
---|
2841 | fi |
---|
2842 | rm -fr conftest* |
---|
2843 | fi |
---|
2844 | echo "$ac_t""$ac_cv_sizeof_voidp" 1>&6 |
---|
2845 | cat >> confdefs.h <<EOF |
---|
2846 | #define SIZEOF_VOIDP $ac_cv_sizeof_voidp |
---|
2847 | EOF |
---|
2848 | |
---|
2849 | |
---|
2850 | echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6 |
---|
2851 | if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then |
---|
2852 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
2853 | else |
---|
2854 | ac_cv_c_bigendian=unknown |
---|
2855 | # See if sys/param.h defines the BYTE_ORDER macro. |
---|
2856 | cat > conftest.$ac_ext <<EOF |
---|
2857 | #line 2858 "configure" |
---|
2858 | #include "confdefs.h" |
---|
2859 | #include <sys/types.h> |
---|
2860 | #include <sys/param.h> |
---|
2861 | int main() { return 0; } |
---|
2862 | int t() { |
---|
2863 | |
---|
2864 | #if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN |
---|
2865 | bogus endian macros |
---|
2866 | #endif |
---|
2867 | ; return 0; } |
---|
2868 | EOF |
---|
2869 | if { (eval echo configure:2870: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
---|
2870 | rm -rf conftest* |
---|
2871 | # It does; now see whether it defined to BIG_ENDIAN or not. |
---|
2872 | cat > conftest.$ac_ext <<EOF |
---|
2873 | #line 2874 "configure" |
---|
2874 | #include "confdefs.h" |
---|
2875 | #include <sys/types.h> |
---|
2876 | #include <sys/param.h> |
---|
2877 | int main() { return 0; } |
---|
2878 | int t() { |
---|
2879 | |
---|
2880 | #if BYTE_ORDER != BIG_ENDIAN |
---|
2881 | not big endian |
---|
2882 | #endif |
---|
2883 | ; return 0; } |
---|
2884 | EOF |
---|
2885 | if { (eval echo configure:2886: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
---|
2886 | rm -rf conftest* |
---|
2887 | ac_cv_c_bigendian=yes |
---|
2888 | else |
---|
2889 | rm -rf conftest* |
---|
2890 | ac_cv_c_bigendian=no |
---|
2891 | fi |
---|
2892 | rm -f conftest* |
---|
2893 | |
---|
2894 | fi |
---|
2895 | rm -f conftest* |
---|
2896 | |
---|
2897 | if test $ac_cv_c_bigendian = unknown; then |
---|
2898 | if test "$cross_compiling" = yes; then |
---|
2899 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
---|
2900 | else |
---|
2901 | cat > conftest.$ac_ext <<EOF |
---|
2902 | #line 2903 "configure" |
---|
2903 | #include "confdefs.h" |
---|
2904 | main () { |
---|
2905 | /* Are we little or big endian? From Harbison&Steele. */ |
---|
2906 | union |
---|
2907 | { |
---|
2908 | long l; |
---|
2909 | char c[sizeof (long)]; |
---|
2910 | } u; |
---|
2911 | u.l = 1; |
---|
2912 | exit (u.c[sizeof (long) - 1] == 1); |
---|
2913 | } |
---|
2914 | EOF |
---|
2915 | { (eval echo configure:2916: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } |
---|
2916 | if test -s conftest && (./conftest; exit) 2>/dev/null; then |
---|
2917 | ac_cv_c_bigendian=no |
---|
2918 | else |
---|
2919 | ac_cv_c_bigendian=yes |
---|
2920 | fi |
---|
2921 | fi |
---|
2922 | rm -fr conftest* |
---|
2923 | fi |
---|
2924 | fi |
---|
2925 | |
---|
2926 | echo "$ac_t""$ac_cv_c_bigendian" 1>&6 |
---|
2927 | if test $ac_cv_c_bigendian = yes; then |
---|
2928 | cat >> confdefs.h <<\EOF |
---|
2929 | #define WORDS_BIGENDIAN 1 |
---|
2930 | EOF |
---|
2931 | |
---|
2932 | fi |
---|
2933 | |
---|
2934 | if test "$ac_cv_sizeof_int" != 4; then |
---|
2935 | { echo "configure: error: need int to be four bytes long" 1>&2; exit 1; } |
---|
2936 | fi |
---|
2937 | if test "$ac_cv_sizeof_long" != "$ac_cv_sizeof_voidp"; then |
---|
2938 | { echo "configure: error: need equal sizes for long and void*" 1>&2; exit 1; } |
---|
2939 | fi |
---|
2940 | |
---|
2941 | |
---|
2942 | |
---|
2943 | # Check whether --with-rootdir or --without-rootdir was given. |
---|
2944 | if test "${with_rootdir+set}" = set; then |
---|
2945 | withval="$with_rootdir" |
---|
2946 | : |
---|
2947 | fi |
---|
2948 | |
---|
2949 | # Check whether --with-lex or --without-lex was given. |
---|
2950 | if test "${with_lex+set}" = set; then |
---|
2951 | withval="$with_lex" |
---|
2952 | : |
---|
2953 | fi |
---|
2954 | |
---|
2955 | # Check whether --with-perl5 or --without-perl5 was given. |
---|
2956 | if test "${with_perl5+set}" = set; then |
---|
2957 | withval="$with_perl5" |
---|
2958 | : |
---|
2959 | fi |
---|
2960 | |
---|
2961 | # Check whether --with-info or --without-info was given. |
---|
2962 | if test "${with_info+set}" = set; then |
---|
2963 | withval="$with_info" |
---|
2964 | : |
---|
2965 | fi |
---|
2966 | |
---|
2967 | # Check whether --with-readline or --without-readline was given. |
---|
2968 | if test "${with_readline+set}" = set; then |
---|
2969 | withval="$with_readline" |
---|
2970 | : |
---|
2971 | fi |
---|
2972 | |
---|
2973 | # Check whether --with-MP or --without-MP was given. |
---|
2974 | if test "${with_MP+set}" = set; then |
---|
2975 | withval="$with_MP" |
---|
2976 | : |
---|
2977 | fi |
---|
2978 | |
---|
2979 | # Check whether --with-dbm or --without-dbm was given. |
---|
2980 | if test "${with_dbm+set}" = set; then |
---|
2981 | withval="$with_dbm" |
---|
2982 | : |
---|
2983 | fi |
---|
2984 | |
---|
2985 | # Check whether --with-dld or --without-dld was given. |
---|
2986 | if test "${with_dld+set}" = set; then |
---|
2987 | withval="$with_dld" |
---|
2988 | : |
---|
2989 | fi |
---|
2990 | |
---|
2991 | # Check whether --with-factory or --without-factory was given. |
---|
2992 | if test "${with_factory+set}" = set; then |
---|
2993 | withval="$with_factory" |
---|
2994 | : |
---|
2995 | fi |
---|
2996 | |
---|
2997 | # Check whether --with-libfac or --without-libfac was given. |
---|
2998 | if test "${with_libfac+set}" = set; then |
---|
2999 | withval="$with_libfac" |
---|
3000 | : |
---|
3001 | fi |
---|
3002 | |
---|
3003 | # Check whether --with-apint or --without-apint was given. |
---|
3004 | if test "${with_apint+set}" = set; then |
---|
3005 | withval="$with_apint" |
---|
3006 | : |
---|
3007 | fi |
---|
3008 | |
---|
3009 | # Check whether --with-exp_type or --without-exp_type was given. |
---|
3010 | if test "${with_exp_type+set}" = set; then |
---|
3011 | withval="$with_exp_type" |
---|
3012 | : |
---|
3013 | fi |
---|
3014 | |
---|
3015 | |
---|
3016 | |
---|
3017 | |
---|
3018 | |
---|
3019 | # readline |
---|
3020 | if test "$with_readline" != no; then |
---|
3021 | echo $ac_n "checking for -lncurses""... $ac_c" 1>&6 |
---|
3022 | ac_lib_var=`echo ncurses_tgetent | tr '.-/+' '___p'` |
---|
3023 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
---|
3024 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
3025 | else |
---|
3026 | ac_save_LIBS="$LIBS" |
---|
3027 | LIBS="-lncurses $LIBS" |
---|
3028 | cat > conftest.$ac_ext <<EOF |
---|
3029 | #line 3030 "configure" |
---|
3030 | #include "confdefs.h" |
---|
3031 | /* Override any gcc2 internal prototype to avoid an error. */ |
---|
3032 | char tgetent(); |
---|
3033 | |
---|
3034 | int main() { return 0; } |
---|
3035 | int t() { |
---|
3036 | tgetent() |
---|
3037 | ; return 0; } |
---|
3038 | EOF |
---|
3039 | if { (eval echo configure:3040: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
---|
3040 | rm -rf conftest* |
---|
3041 | eval "ac_cv_lib_$ac_lib_var=yes" |
---|
3042 | else |
---|
3043 | rm -rf conftest* |
---|
3044 | eval "ac_cv_lib_$ac_lib_var=no" |
---|
3045 | fi |
---|
3046 | rm -f conftest* |
---|
3047 | LIBS="$ac_save_LIBS" |
---|
3048 | |
---|
3049 | fi |
---|
3050 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
---|
3051 | echo "$ac_t""yes" 1>&6 |
---|
3052 | ac_tr_lib=HAVE_LIB`echo ncurses | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
---|
3053 | cat >> confdefs.h <<EOF |
---|
3054 | #define $ac_tr_lib 1 |
---|
3055 | EOF |
---|
3056 | |
---|
3057 | LIBS="-lncurses $LIBS" |
---|
3058 | |
---|
3059 | else |
---|
3060 | echo "$ac_t""no" 1>&6 |
---|
3061 | \ |
---|
3062 | echo $ac_n "checking for -lcurses""... $ac_c" 1>&6 |
---|
3063 | ac_lib_var=`echo curses_tgetent | tr '.-/+' '___p'` |
---|
3064 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
---|
3065 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
3066 | else |
---|
3067 | ac_save_LIBS="$LIBS" |
---|
3068 | LIBS="-lcurses $LIBS" |
---|
3069 | cat > conftest.$ac_ext <<EOF |
---|
3070 | #line 3071 "configure" |
---|
3071 | #include "confdefs.h" |
---|
3072 | /* Override any gcc2 internal prototype to avoid an error. */ |
---|
3073 | char tgetent(); |
---|
3074 | |
---|
3075 | int main() { return 0; } |
---|
3076 | int t() { |
---|
3077 | tgetent() |
---|
3078 | ; return 0; } |
---|
3079 | EOF |
---|
3080 | if { (eval echo configure:3081: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
---|
3081 | rm -rf conftest* |
---|
3082 | eval "ac_cv_lib_$ac_lib_var=yes" |
---|
3083 | else |
---|
3084 | rm -rf conftest* |
---|
3085 | eval "ac_cv_lib_$ac_lib_var=no" |
---|
3086 | fi |
---|
3087 | rm -f conftest* |
---|
3088 | LIBS="$ac_save_LIBS" |
---|
3089 | |
---|
3090 | fi |
---|
3091 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
---|
3092 | echo "$ac_t""yes" 1>&6 |
---|
3093 | ac_tr_lib=HAVE_LIB`echo curses | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
---|
3094 | cat >> confdefs.h <<EOF |
---|
3095 | #define $ac_tr_lib 1 |
---|
3096 | EOF |
---|
3097 | |
---|
3098 | LIBS="-lcurses $LIBS" |
---|
3099 | |
---|
3100 | else |
---|
3101 | echo "$ac_t""no" 1>&6 |
---|
3102 | \ |
---|
3103 | echo $ac_n "checking for -ltermcap""... $ac_c" 1>&6 |
---|
3104 | ac_lib_var=`echo termcap_tgetent | tr '.-/+' '___p'` |
---|
3105 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
---|
3106 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
3107 | else |
---|
3108 | ac_save_LIBS="$LIBS" |
---|
3109 | LIBS="-ltermcap $LIBS" |
---|
3110 | cat > conftest.$ac_ext <<EOF |
---|
3111 | #line 3112 "configure" |
---|
3112 | #include "confdefs.h" |
---|
3113 | /* Override any gcc2 internal prototype to avoid an error. */ |
---|
3114 | char tgetent(); |
---|
3115 | |
---|
3116 | int main() { return 0; } |
---|
3117 | int t() { |
---|
3118 | tgetent() |
---|
3119 | ; return 0; } |
---|
3120 | EOF |
---|
3121 | if { (eval echo configure:3122: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
---|
3122 | rm -rf conftest* |
---|
3123 | eval "ac_cv_lib_$ac_lib_var=yes" |
---|
3124 | else |
---|
3125 | rm -rf conftest* |
---|
3126 | eval "ac_cv_lib_$ac_lib_var=no" |
---|
3127 | fi |
---|
3128 | rm -f conftest* |
---|
3129 | LIBS="$ac_save_LIBS" |
---|
3130 | |
---|
3131 | fi |
---|
3132 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
---|
3133 | echo "$ac_t""yes" 1>&6 |
---|
3134 | ac_tr_lib=HAVE_LIB`echo termcap | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
---|
3135 | cat >> confdefs.h <<EOF |
---|
3136 | #define $ac_tr_lib 1 |
---|
3137 | EOF |
---|
3138 | |
---|
3139 | LIBS="-ltermcap $LIBS" |
---|
3140 | |
---|
3141 | else |
---|
3142 | echo "$ac_t""no" 1>&6 |
---|
3143 | fi |
---|
3144 | |
---|
3145 | fi |
---|
3146 | |
---|
3147 | fi |
---|
3148 | |
---|
3149 | echo $ac_n "checking for -lreadline""... $ac_c" 1>&6 |
---|
3150 | ac_lib_var=`echo readline_rl_abort | tr '.-/+' '___p'` |
---|
3151 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
---|
3152 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
3153 | else |
---|
3154 | ac_save_LIBS="$LIBS" |
---|
3155 | LIBS="-lreadline $LIBS" |
---|
3156 | cat > conftest.$ac_ext <<EOF |
---|
3157 | #line 3158 "configure" |
---|
3158 | #include "confdefs.h" |
---|
3159 | /* Override any gcc2 internal prototype to avoid an error. */ |
---|
3160 | char rl_abort(); |
---|
3161 | |
---|
3162 | int main() { return 0; } |
---|
3163 | int t() { |
---|
3164 | rl_abort() |
---|
3165 | ; return 0; } |
---|
3166 | EOF |
---|
3167 | if { (eval echo configure:3168: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
---|
3168 | rm -rf conftest* |
---|
3169 | eval "ac_cv_lib_$ac_lib_var=yes" |
---|
3170 | else |
---|
3171 | rm -rf conftest* |
---|
3172 | eval "ac_cv_lib_$ac_lib_var=no" |
---|
3173 | fi |
---|
3174 | rm -f conftest* |
---|
3175 | LIBS="$ac_save_LIBS" |
---|
3176 | |
---|
3177 | fi |
---|
3178 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
---|
3179 | echo "$ac_t""yes" 1>&6 |
---|
3180 | ac_tr_lib=HAVE_LIB`echo readline | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
---|
3181 | cat >> confdefs.h <<EOF |
---|
3182 | #define $ac_tr_lib 1 |
---|
3183 | EOF |
---|
3184 | |
---|
3185 | LIBS="-lreadline $LIBS" |
---|
3186 | |
---|
3187 | else |
---|
3188 | echo "$ac_t""no" 1>&6 |
---|
3189 | fi |
---|
3190 | |
---|
3191 | if test "$ac_cv_lib_readline_rl_abort" = yes; then |
---|
3192 | for ac_hdr in readline/readline.h sys/file.h |
---|
3193 | do |
---|
3194 | ac_safe=`echo "$ac_hdr" | tr './\055' '___'` |
---|
3195 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 |
---|
3196 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
---|
3197 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
3198 | else |
---|
3199 | cat > conftest.$ac_ext <<EOF |
---|
3200 | #line 3201 "configure" |
---|
3201 | #include "confdefs.h" |
---|
3202 | #include <$ac_hdr> |
---|
3203 | EOF |
---|
3204 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
---|
3205 | { (eval echo configure:3206: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
---|
3206 | ac_err=`grep -v '^ *+' conftest.out` |
---|
3207 | if test -z "$ac_err"; then |
---|
3208 | rm -rf conftest* |
---|
3209 | eval "ac_cv_header_$ac_safe=yes" |
---|
3210 | else |
---|
3211 | echo "$ac_err" >&5 |
---|
3212 | rm -rf conftest* |
---|
3213 | eval "ac_cv_header_$ac_safe=no" |
---|
3214 | fi |
---|
3215 | rm -f conftest* |
---|
3216 | fi |
---|
3217 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
---|
3218 | echo "$ac_t""yes" 1>&6 |
---|
3219 | ac_tr_hdr=HAVE_`echo $ac_hdr | tr 'abcdefghijklmnopqrstuvwxyz./\055' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ___'` |
---|
3220 | cat >> confdefs.h <<EOF |
---|
3221 | #define $ac_tr_hdr 1 |
---|
3222 | EOF |
---|
3223 | ac_readline_ok=yes |
---|
3224 | else |
---|
3225 | echo "$ac_t""no" 1>&6 |
---|
3226 | ac_readline_ok=no; break |
---|
3227 | fi |
---|
3228 | done |
---|
3229 | |
---|
3230 | fi |
---|
3231 | if test "$ac_readline_ok" = yes; then |
---|
3232 | for ac_hdr in readline/history.h |
---|
3233 | do |
---|
3234 | ac_safe=`echo "$ac_hdr" | tr './\055' '___'` |
---|
3235 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 |
---|
3236 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
---|
3237 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
3238 | else |
---|
3239 | cat > conftest.$ac_ext <<EOF |
---|
3240 | #line 3241 "configure" |
---|
3241 | #include "confdefs.h" |
---|
3242 | #include <$ac_hdr> |
---|
3243 | EOF |
---|
3244 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
---|
3245 | { (eval echo configure:3246: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
---|
3246 | ac_err=`grep -v '^ *+' conftest.out` |
---|
3247 | if test -z "$ac_err"; then |
---|
3248 | rm -rf conftest* |
---|
3249 | eval "ac_cv_header_$ac_safe=yes" |
---|
3250 | else |
---|
3251 | echo "$ac_err" >&5 |
---|
3252 | rm -rf conftest* |
---|
3253 | eval "ac_cv_header_$ac_safe=no" |
---|
3254 | fi |
---|
3255 | rm -f conftest* |
---|
3256 | fi |
---|
3257 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
---|
3258 | echo "$ac_t""yes" 1>&6 |
---|
3259 | ac_tr_hdr=HAVE_`echo $ac_hdr | tr 'abcdefghijklmnopqrstuvwxyz./\055' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ___'` |
---|
3260 | cat >> confdefs.h <<EOF |
---|
3261 | #define $ac_tr_hdr 1 |
---|
3262 | EOF |
---|
3263 | |
---|
3264 | else |
---|
3265 | echo "$ac_t""no" 1>&6 |
---|
3266 | fi |
---|
3267 | done |
---|
3268 | |
---|
3269 | cat >> confdefs.h <<\EOF |
---|
3270 | #define HAVE_READLINE 1 |
---|
3271 | EOF |
---|
3272 | |
---|
3273 | else |
---|
3274 | echo "configure: warning: building without readline: disabling fancy display" 1>&2; |
---|
3275 | cat >> confdefs.h <<\EOF |
---|
3276 | #define HAVE_FEREAD 1 |
---|
3277 | EOF |
---|
3278 | |
---|
3279 | fi |
---|
3280 | else |
---|
3281 | cat >> confdefs.h <<\EOF |
---|
3282 | #define HAVE_FEREAD 1 |
---|
3283 | EOF |
---|
3284 | |
---|
3285 | fi |
---|
3286 | |
---|
3287 | # |
---|
3288 | # dld |
---|
3289 | if test "$with_dld" = yes; then |
---|
3290 | echo $ac_n "checking for -ldld""... $ac_c" 1>&6 |
---|
3291 | ac_lib_var=`echo dld_dld_init | tr '.-/+' '___p'` |
---|
3292 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
---|
3293 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
3294 | else |
---|
3295 | ac_save_LIBS="$LIBS" |
---|
3296 | LIBS="-ldld $LIBS" |
---|
3297 | cat > conftest.$ac_ext <<EOF |
---|
3298 | #line 3299 "configure" |
---|
3299 | #include "confdefs.h" |
---|
3300 | /* Override any gcc2 internal prototype to avoid an error. */ |
---|
3301 | char dld_init(); |
---|
3302 | |
---|
3303 | int main() { return 0; } |
---|
3304 | int t() { |
---|
3305 | dld_init() |
---|
3306 | ; return 0; } |
---|
3307 | EOF |
---|
3308 | if { (eval echo configure:3309: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
---|
3309 | rm -rf conftest* |
---|
3310 | eval "ac_cv_lib_$ac_lib_var=yes" |
---|
3311 | else |
---|
3312 | rm -rf conftest* |
---|
3313 | eval "ac_cv_lib_$ac_lib_var=no" |
---|
3314 | fi |
---|
3315 | rm -f conftest* |
---|
3316 | LIBS="$ac_save_LIBS" |
---|
3317 | |
---|
3318 | fi |
---|
3319 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
---|
3320 | echo "$ac_t""yes" 1>&6 |
---|
3321 | \ |
---|
3322 | echo "configure: warning: building without dld: disabling dynamic linking" 1>&2 |
---|
3323 | else |
---|
3324 | echo "$ac_t""no" 1>&6 |
---|
3325 | fi |
---|
3326 | |
---|
3327 | fi |
---|
3328 | |
---|
3329 | NEED_LIBS=$LIBS |
---|
3330 | |
---|
3331 | # gmp, smallgmp, MP, MPT, factory, libfac |
---|
3332 | echo $ac_n "checking for -lgmp""... $ac_c" 1>&6 |
---|
3333 | ac_lib_var=`echo gmp_mpq_init | tr '.-/+' '___p'` |
---|
3334 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
---|
3335 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
3336 | else |
---|
3337 | ac_save_LIBS="$LIBS" |
---|
3338 | LIBS="-lgmp $LIBS" |
---|
3339 | cat > conftest.$ac_ext <<EOF |
---|
3340 | #line 3341 "configure" |
---|
3341 | #include "confdefs.h" |
---|
3342 | /* Override any gcc2 internal prototype to avoid an error. */ |
---|
3343 | char mpq_init(); |
---|
3344 | |
---|
3345 | int main() { return 0; } |
---|
3346 | int t() { |
---|
3347 | mpq_init() |
---|
3348 | ; return 0; } |
---|
3349 | EOF |
---|
3350 | if { (eval echo configure:3351: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
---|
3351 | rm -rf conftest* |
---|
3352 | eval "ac_cv_lib_$ac_lib_var=yes" |
---|
3353 | else |
---|
3354 | rm -rf conftest* |
---|
3355 | eval "ac_cv_lib_$ac_lib_var=no" |
---|
3356 | fi |
---|
3357 | rm -f conftest* |
---|
3358 | LIBS="$ac_save_LIBS" |
---|
3359 | |
---|
3360 | fi |
---|
3361 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
---|
3362 | echo "$ac_t""yes" 1>&6 |
---|
3363 | ac_tr_lib=HAVE_LIB`echo gmp | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
---|
3364 | cat >> confdefs.h <<EOF |
---|
3365 | #define $ac_tr_lib 1 |
---|
3366 | EOF |
---|
3367 | |
---|
3368 | LIBS="-lgmp $LIBS" |
---|
3369 | |
---|
3370 | else |
---|
3371 | echo "$ac_t""no" 1>&6 |
---|
3372 | fi |
---|
3373 | |
---|
3374 | if test "ac_cv_lib_gmp_mpq_init" = yes && test "$with-apint" = smallgmp; then |
---|
3375 | LIBS=NEED_LIBS |
---|
3376 | fi |
---|
3377 | echo $ac_n "checking for -lsmallgmp""... $ac_c" 1>&6 |
---|
3378 | ac_lib_var=`echo smallgmp_mpz_init | tr '.-/+' '___p'` |
---|
3379 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
---|
3380 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
3381 | else |
---|
3382 | ac_save_LIBS="$LIBS" |
---|
3383 | LIBS="-lsmallgmp $LIBS" |
---|
3384 | cat > conftest.$ac_ext <<EOF |
---|
3385 | #line 3386 "configure" |
---|
3386 | #include "confdefs.h" |
---|
3387 | /* Override any gcc2 internal prototype to avoid an error. */ |
---|
3388 | char mpz_init(); |
---|
3389 | |
---|
3390 | int main() { return 0; } |
---|
3391 | int t() { |
---|
3392 | mpz_init() |
---|
3393 | ; return 0; } |
---|
3394 | EOF |
---|
3395 | if { (eval echo configure:3396: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
---|
3396 | rm -rf conftest* |
---|
3397 | eval "ac_cv_lib_$ac_lib_var=yes" |
---|
3398 | else |
---|
3399 | rm -rf conftest* |
---|
3400 | eval "ac_cv_lib_$ac_lib_var=no" |
---|
3401 | fi |
---|
3402 | rm -f conftest* |
---|
3403 | LIBS="$ac_save_LIBS" |
---|
3404 | |
---|
3405 | fi |
---|
3406 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
---|
3407 | echo "$ac_t""yes" 1>&6 |
---|
3408 | ac_tr_lib=HAVE_LIB`echo smallgmp | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
---|
3409 | cat >> confdefs.h <<EOF |
---|
3410 | #define $ac_tr_lib 1 |
---|
3411 | EOF |
---|
3412 | |
---|
3413 | LIBS="-lsmallgmp $LIBS" |
---|
3414 | |
---|
3415 | else |
---|
3416 | echo "$ac_t""no" 1>&6 |
---|
3417 | fi |
---|
3418 | |
---|
3419 | echo $ac_n "checking for -lMP""... $ac_c" 1>&6 |
---|
3420 | ac_lib_var=`echo MP_IMP_PutGmpInt | tr '.-/+' '___p'` |
---|
3421 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
---|
3422 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
3423 | else |
---|
3424 | ac_save_LIBS="$LIBS" |
---|
3425 | LIBS="-lMP $LIBS" |
---|
3426 | cat > conftest.$ac_ext <<EOF |
---|
3427 | #line 3428 "configure" |
---|
3428 | #include "confdefs.h" |
---|
3429 | /* Override any gcc2 internal prototype to avoid an error. */ |
---|
3430 | char IMP_PutGmpInt(); |
---|
3431 | |
---|
3432 | int main() { return 0; } |
---|
3433 | int t() { |
---|
3434 | IMP_PutGmpInt() |
---|
3435 | ; return 0; } |
---|
3436 | EOF |
---|
3437 | if { (eval echo configure:3438: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
---|
3438 | rm -rf conftest* |
---|
3439 | eval "ac_cv_lib_$ac_lib_var=yes" |
---|
3440 | else |
---|
3441 | rm -rf conftest* |
---|
3442 | eval "ac_cv_lib_$ac_lib_var=no" |
---|
3443 | fi |
---|
3444 | rm -f conftest* |
---|
3445 | LIBS="$ac_save_LIBS" |
---|
3446 | |
---|
3447 | fi |
---|
3448 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
---|
3449 | echo "$ac_t""yes" 1>&6 |
---|
3450 | ac_tr_lib=HAVE_LIB`echo MP | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
---|
3451 | cat >> confdefs.h <<EOF |
---|
3452 | #define $ac_tr_lib 1 |
---|
3453 | EOF |
---|
3454 | |
---|
3455 | LIBS="-lMP $LIBS" |
---|
3456 | |
---|
3457 | else |
---|
3458 | echo "$ac_t""no" 1>&6 |
---|
3459 | fi |
---|
3460 | |
---|
3461 | echo $ac_n "checking for -lMPT""... $ac_c" 1>&6 |
---|
3462 | ac_lib_var=`echo MPT_MPT_GetTree | tr '.-/+' '___p'` |
---|
3463 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
---|
3464 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
3465 | else |
---|
3466 | ac_save_LIBS="$LIBS" |
---|
3467 | LIBS="-lMPT $LIBS" |
---|
3468 | cat > conftest.$ac_ext <<EOF |
---|
3469 | #line 3470 "configure" |
---|
3470 | #include "confdefs.h" |
---|
3471 | /* Override any gcc2 internal prototype to avoid an error. */ |
---|
3472 | char MPT_GetTree(); |
---|
3473 | |
---|
3474 | int main() { return 0; } |
---|
3475 | int t() { |
---|
3476 | MPT_GetTree() |
---|
3477 | ; return 0; } |
---|
3478 | EOF |
---|
3479 | if { (eval echo configure:3480: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
---|
3480 | rm -rf conftest* |
---|
3481 | eval "ac_cv_lib_$ac_lib_var=yes" |
---|
3482 | else |
---|
3483 | rm -rf conftest* |
---|
3484 | eval "ac_cv_lib_$ac_lib_var=no" |
---|
3485 | fi |
---|
3486 | rm -f conftest* |
---|
3487 | LIBS="$ac_save_LIBS" |
---|
3488 | |
---|
3489 | fi |
---|
3490 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
---|
3491 | echo "$ac_t""yes" 1>&6 |
---|
3492 | ac_tr_lib=HAVE_LIB`echo MPT | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
---|
3493 | cat >> confdefs.h <<EOF |
---|
3494 | #define $ac_tr_lib 1 |
---|
3495 | EOF |
---|
3496 | |
---|
3497 | LIBS="-lMPT $LIBS" |
---|
3498 | |
---|
3499 | else |
---|
3500 | echo "$ac_t""no" 1>&6 |
---|
3501 | fi |
---|
3502 | |
---|
3503 | echo $ac_n "checking for -lsingcf""... $ac_c" 1>&6 |
---|
3504 | ac_lib_var=`echo singcf_atof | tr '.-/+' '___p'` |
---|
3505 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
---|
3506 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
3507 | else |
---|
3508 | ac_save_LIBS="$LIBS" |
---|
3509 | LIBS="-lsingcf $LIBS" |
---|
3510 | cat > conftest.$ac_ext <<EOF |
---|
3511 | #line 3512 "configure" |
---|
3512 | #include "confdefs.h" |
---|
3513 | /* Override any gcc2 internal prototype to avoid an error. */ |
---|
3514 | char atof(); |
---|
3515 | |
---|
3516 | int main() { return 0; } |
---|
3517 | int t() { |
---|
3518 | atof() |
---|
3519 | ; return 0; } |
---|
3520 | EOF |
---|
3521 | if { (eval echo configure:3522: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
---|
3522 | rm -rf conftest* |
---|
3523 | eval "ac_cv_lib_$ac_lib_var=yes" |
---|
3524 | else |
---|
3525 | rm -rf conftest* |
---|
3526 | eval "ac_cv_lib_$ac_lib_var=no" |
---|
3527 | fi |
---|
3528 | rm -f conftest* |
---|
3529 | LIBS="$ac_save_LIBS" |
---|
3530 | |
---|
3531 | fi |
---|
3532 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
---|
3533 | echo "$ac_t""yes" 1>&6 |
---|
3534 | ac_tr_lib=HAVE_LIB`echo singcf | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
---|
3535 | cat >> confdefs.h <<EOF |
---|
3536 | #define $ac_tr_lib 1 |
---|
3537 | EOF |
---|
3538 | |
---|
3539 | LIBS="-lsingcf $LIBS" |
---|
3540 | |
---|
3541 | else |
---|
3542 | echo "$ac_t""no" 1>&6 |
---|
3543 | fi |
---|
3544 | |
---|
3545 | echo $ac_n "checking for -lsingfac""... $ac_c" 1>&6 |
---|
3546 | ac_lib_var=`echo singfac_atof | tr '.-/+' '___p'` |
---|
3547 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
---|
3548 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
3549 | else |
---|
3550 | ac_save_LIBS="$LIBS" |
---|
3551 | LIBS="-lsingfac $LIBS" |
---|
3552 | cat > conftest.$ac_ext <<EOF |
---|
3553 | #line 3554 "configure" |
---|
3554 | #include "confdefs.h" |
---|
3555 | /* Override any gcc2 internal prototype to avoid an error. */ |
---|
3556 | char atof(); |
---|
3557 | |
---|
3558 | int main() { return 0; } |
---|
3559 | int t() { |
---|
3560 | atof() |
---|
3561 | ; return 0; } |
---|
3562 | EOF |
---|
3563 | if { (eval echo configure:3564: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
---|
3564 | rm -rf conftest* |
---|
3565 | eval "ac_cv_lib_$ac_lib_var=yes" |
---|
3566 | else |
---|
3567 | rm -rf conftest* |
---|
3568 | eval "ac_cv_lib_$ac_lib_var=no" |
---|
3569 | fi |
---|
3570 | rm -f conftest* |
---|
3571 | LIBS="$ac_save_LIBS" |
---|
3572 | |
---|
3573 | fi |
---|
3574 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
---|
3575 | echo "$ac_t""yes" 1>&6 |
---|
3576 | ac_tr_lib=HAVE_LIB`echo singfac | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
---|
3577 | cat >> confdefs.h <<EOF |
---|
3578 | #define $ac_tr_lib 1 |
---|
3579 | EOF |
---|
3580 | |
---|
3581 | LIBS="-lsingfac $LIBS" |
---|
3582 | |
---|
3583 | else |
---|
3584 | echo "$ac_t""no" 1>&6 |
---|
3585 | fi |
---|
3586 | |
---|
3587 | |
---|
3588 | for ac_hdr in gmp.h smallgmp.h MP.h MPT.h factory.h factor.h |
---|
3589 | do |
---|
3590 | ac_safe=`echo "$ac_hdr" | tr './\055' '___'` |
---|
3591 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 |
---|
3592 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
---|
3593 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
3594 | else |
---|
3595 | cat > conftest.$ac_ext <<EOF |
---|
3596 | #line 3597 "configure" |
---|
3597 | #include "confdefs.h" |
---|
3598 | #include <$ac_hdr> |
---|
3599 | EOF |
---|
3600 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
---|
3601 | { (eval echo configure:3602: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
---|
3602 | ac_err=`grep -v '^ *+' conftest.out` |
---|
3603 | if test -z "$ac_err"; then |
---|
3604 | rm -rf conftest* |
---|
3605 | eval "ac_cv_header_$ac_safe=yes" |
---|
3606 | else |
---|
3607 | echo "$ac_err" >&5 |
---|
3608 | rm -rf conftest* |
---|
3609 | eval "ac_cv_header_$ac_safe=no" |
---|
3610 | fi |
---|
3611 | rm -f conftest* |
---|
3612 | fi |
---|
3613 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
---|
3614 | echo "$ac_t""yes" 1>&6 |
---|
3615 | ac_tr_hdr=HAVE_`echo $ac_hdr | tr 'abcdefghijklmnopqrstuvwxyz./\055' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ___'` |
---|
3616 | cat >> confdefs.h <<EOF |
---|
3617 | #define $ac_tr_hdr 1 |
---|
3618 | EOF |
---|
3619 | |
---|
3620 | else |
---|
3621 | echo "$ac_t""no" 1>&6 |
---|
3622 | fi |
---|
3623 | done |
---|
3624 | |
---|
3625 | |
---|
3626 | if test "$ac_cv_lib_gmp_mpq_init" = yes && \ |
---|
3627 | test "$ac_cv_header_gmp_h" = yes; then |
---|
3628 | ac_gmp_ok=yes |
---|
3629 | fi |
---|
3630 | |
---|
3631 | if test "$ac_cv_lib_smallgmp_mpz_init" = yes && \ |
---|
3632 | test "$ac_cv_header_smallgmp_h" = yes && \ |
---|
3633 | test "$ac_cv_header_gmp_h" = yes; then |
---|
3634 | ac_smallgmp_ok=yes |
---|
3635 | fi |
---|
3636 | |
---|
3637 | if test "$ac_cv_lib_MP_IMP_PutGmpInt" = yes && \ |
---|
3638 | test "$ac_cv_lib_MPT_MPT_GetTree" && \ |
---|
3639 | test "$ac_cv_header_MP_h" = yes && \ |
---|
3640 | test "$ac_cv_header_MPT_h" = yes; then |
---|
3641 | ac_MP_ok=yes |
---|
3642 | fi |
---|
3643 | |
---|
3644 | if test "$ac_cv_lib_singcf_atof" = yes && \ |
---|
3645 | test "$ac_cv_header_factory_h" = yes; then |
---|
3646 | ac_factory_ok=yes |
---|
3647 | fi |
---|
3648 | |
---|
3649 | if test "$ac_cv_lib_singfac_atof" = yes && \ |
---|
3650 | test "$ac_cv_header_factor_h" = yes; then |
---|
3651 | ac_libfac_ok=yes |
---|
3652 | fi |
---|
3653 | |
---|
3654 | # evaluate results |
---|
3655 | echo $ac_n "checking which apint package to use""... $ac_c" 1>&6 |
---|
3656 | if test "${with_apint}" != gmp && test "${with_apint}" != smallgmp; then |
---|
3657 | if test "$ac_gmp_ok" = yes || test "$enable_gmp" = yes; then |
---|
3658 | echo "$ac_t""gmp" 1>&6 |
---|
3659 | will_have_gmp=yes |
---|
3660 | NEED_LIBS="-lgmp ${NEED_LIBS}" |
---|
3661 | elif test "ac_gmp_smallgmp_ok" = yes || test "$enable_smallgmp" = "yes"; then |
---|
3662 | echo "$ac_t""smallgmp" 1>&6 |
---|
3663 | cat >> confdefs.h <<\EOF |
---|
3664 | #define HAVE_SMALLGMP 1 |
---|
3665 | EOF |
---|
3666 | |
---|
3667 | NEED_LIBS="-lsmallgmp ${NEED_LIBS}" |
---|
3668 | else |
---|
3669 | echo "$ac_t""none" 1>&6 |
---|
3670 | { echo "configure: error: can not build without gmp or smallgmp" 1>&2; exit 1; } |
---|
3671 | fi |
---|
3672 | elif test "${with_apint}" = gmp; then |
---|
3673 | if test "$ac_gmp_ok" = yes || test "$enable_gmp" = yes; then |
---|
3674 | echo "$ac_t""gmp" 1>&6 |
---|
3675 | will_have_gmp=yes |
---|
3676 | NEED_LIBS="-lgmp ${NEED_LIBS}" |
---|
3677 | else |
---|
3678 | echo "$ac_t""none" 1>&6 |
---|
3679 | { echo "configure: error: can not build with gmp" 1>&2; exit 1; } |
---|
3680 | fi |
---|
3681 | else |
---|
3682 | if test "ac_gmp_smallgmp_ok" = yes || test "$enable_smallgmp" = "yes"; then |
---|
3683 | echo "$ac_t""smallgmp" 1>&6 |
---|
3684 | cat >> confdefs.h <<\EOF |
---|
3685 | #define HAVE_SMALLGMP 1 |
---|
3686 | EOF |
---|
3687 | |
---|
3688 | NEED_LIBS="-lsmallgmp ${NEED_LIBS}" |
---|
3689 | else |
---|
3690 | echo "$ac_t""none" 1>&6 |
---|
3691 | { echo "configure: error: can not build with smallgmp" 1>&2; exit 1; } |
---|
3692 | fi |
---|
3693 | fi |
---|
3694 | |
---|
3695 | echo $ac_n "checking whether to have MP""... $ac_c" 1>&6 |
---|
3696 | if test "${with_MP}" != yes && test "${with_MP}" != no; then |
---|
3697 | if (test "${will_have_gmp}" = yes) && \ |
---|
3698 | (test "$ac_MP_ok" = yes || test "$enable_MP" = yes); then |
---|
3699 | echo "$ac_t""yes" 1>&6 |
---|
3700 | cat >> confdefs.h <<\EOF |
---|
3701 | #define HAVE_MPSR 1 |
---|
3702 | EOF |
---|
3703 | |
---|
3704 | NEED_LIBS="-lMPT -lMP ${NEED_LIBS}" |
---|
3705 | else |
---|
3706 | echo "$ac_t""no" 1>&6 |
---|
3707 | fi |
---|
3708 | elif test "${with_MP}" = yes; then |
---|
3709 | if (test "${will_have_gmp}" = yes) && \ |
---|
3710 | (test "$ac_MP_ok" = yes || test "$enable_MP" = yes); then |
---|
3711 | echo "$ac_t""yes" 1>&6 |
---|
3712 | cat >> confdefs.h <<\EOF |
---|
3713 | #define HAVE_MPSR 1 |
---|
3714 | EOF |
---|
3715 | |
---|
3716 | NEED_LIBS="-lMPT -lMP ${NEED_LIBS}" |
---|
3717 | else |
---|
3718 | echo "$ac_t""no" 1>&6 |
---|
3719 | { echo "configure: error: can not build with MP" 1>&2; exit 1; } |
---|
3720 | fi |
---|
3721 | else |
---|
3722 | echo "$ac_t""no" 1>&6 |
---|
3723 | fi |
---|
3724 | |
---|
3725 | echo $ac_n "checking whether to have factory""... $ac_c" 1>&6 |
---|
3726 | if test "${with_factory}" != yes && test "${with_factory}" != no; then |
---|
3727 | if test "$ac_factory_ok" = yes || test "$enable_factory" = yes; then |
---|
3728 | echo "$ac_t""yes" 1>&6 |
---|
3729 | cat >> confdefs.h <<\EOF |
---|
3730 | #define HAVE_FACTORY 1 |
---|
3731 | EOF |
---|
3732 | |
---|
3733 | will_have_factory=yes |
---|
3734 | NEED_LIBS="-lsingcf ${NEED_LIBS}" |
---|
3735 | else |
---|
3736 | echo "$ac_t""no" 1>&6 |
---|
3737 | fi |
---|
3738 | elif test "${with_factory}" = yes; then |
---|
3739 | if test "$ac_factory_ok" = yes || test "$enable_factory" = yes; then |
---|
3740 | echo "$ac_t""yes" 1>&6 |
---|
3741 | cat >> confdefs.h <<\EOF |
---|
3742 | #define HAVE_FACTORY 1 |
---|
3743 | EOF |
---|
3744 | |
---|
3745 | will_have_factory=yes |
---|
3746 | NEED_LIBS="-lsingcf ${NEED_LIBS}" |
---|
3747 | else |
---|
3748 | echo "$ac_t""no" 1>&6 |
---|
3749 | { echo "configure: error: can not build with factory" 1>&2; exit 1; } |
---|
3750 | fi |
---|
3751 | else |
---|
3752 | echo "$ac_t""no" 1>&6 |
---|
3753 | fi |
---|
3754 | |
---|
3755 | echo $ac_n "checking whether to have libfac""... $ac_c" 1>&6 |
---|
3756 | if test "${with_libfac}" != yes && test "${with_libfac}" != no; then |
---|
3757 | if (test "${will_have_factory}" = yes) && \ |
---|
3758 | (test "$ac_libfac_ok" = yes || test "$enable_libfac" = yes); then |
---|
3759 | echo "$ac_t""yes" 1>&6 |
---|
3760 | cat >> confdefs.h <<\EOF |
---|
3761 | #define HAVE_LIBFAC_P 1 |
---|
3762 | EOF |
---|
3763 | |
---|
3764 | NEED_LIBS="-lsingfac ${NEED_LIBS}" |
---|
3765 | else |
---|
3766 | echo "$ac_t""no" 1>&6 |
---|
3767 | fi |
---|
3768 | elif test "${with_libfac}" = yes; then |
---|
3769 | if (test "${will_have_factory}" = yes) && \ |
---|
3770 | (test "$ac_libfac_ok" = yes || test "$enable_libfac" = yes); then |
---|
3771 | echo "$ac_t""yes" 1>&6 |
---|
3772 | cat >> confdefs.h <<\EOF |
---|
3773 | #define HAVE_LIBFAC_P 1 |
---|
3774 | EOF |
---|
3775 | |
---|
3776 | NEED_LIBS="-lsingfac ${NEED_LIBS}" |
---|
3777 | else |
---|
3778 | echo "$ac_t""no" 1>&6 |
---|
3779 | { echo "configure: error: can not build with libfac" 1>&2; exit 1; } |
---|
3780 | fi |
---|
3781 | else |
---|
3782 | echo "$ac_t""no" 1>&6 |
---|
3783 | fi |
---|
3784 | |
---|
3785 | |
---|
3786 | echo $ac_n "checking whether to have dbm links""... $ac_c" 1>&6 |
---|
3787 | if test "$with_dbm" != no; then |
---|
3788 | cat >> confdefs.h <<\EOF |
---|
3789 | #define HAVE_DBM 1 |
---|
3790 | EOF |
---|
3791 | |
---|
3792 | echo "$ac_t""yes" 1>&6 |
---|
3793 | else |
---|
3794 | echo "$ac_t""no" 1>&6 |
---|
3795 | fi |
---|
3796 | |
---|
3797 | echo $ac_n "checking which exponent types to use""... $ac_c" 1>&6 |
---|
3798 | if test "$with_exp_type" = "char"; then |
---|
3799 | echo "$ac_t""char" 1>&6 |
---|
3800 | cat >> confdefs.h <<\EOF |
---|
3801 | #define EXPONENT_TYPE char |
---|
3802 | EOF |
---|
3803 | |
---|
3804 | cat >> confdefs.h <<\EOF |
---|
3805 | #define SIZEOF_EXPONENT SIZEOF_CHAR |
---|
3806 | EOF |
---|
3807 | |
---|
3808 | elif test "with_exp_type" = "int"; then |
---|
3809 | echo "$ac_t""int" 1>&6 |
---|
3810 | cat >> confdefs.h <<\EOF |
---|
3811 | #define EXPONENT_TYPE int |
---|
3812 | EOF |
---|
3813 | |
---|
3814 | cat >> confdefs.h <<\EOF |
---|
3815 | #define SIZEOF_EXPONENT SIZEOF_INT |
---|
3816 | EOF |
---|
3817 | |
---|
3818 | else |
---|
3819 | echo "$ac_t""short" 1>&6 |
---|
3820 | cat >> confdefs.h <<\EOF |
---|
3821 | #define EXPONENT_TYPE short |
---|
3822 | EOF |
---|
3823 | |
---|
3824 | cat >> confdefs.h <<\EOF |
---|
3825 | #define SIZEOF_TYPE SIZEOF_SHORT |
---|
3826 | EOF |
---|
3827 | |
---|
3828 | fi |
---|
3829 | |
---|
3830 | trap '' 1 2 15 |
---|
3831 | cat > confcache <<\EOF |
---|
3832 | # This file is a shell script that caches the results of configure |
---|
3833 | # tests run on this system so they can be shared between configure |
---|
3834 | # scripts and configure runs. It is not useful on other systems. |
---|
3835 | # If it contains results you don't want to keep, you may remove or edit it. |
---|
3836 | # |
---|
3837 | # By default, configure uses ./config.cache as the cache file, |
---|
3838 | # creating it if it does not exist already. You can give configure |
---|
3839 | # the --cache-file=FILE option to use a different cache file; that is |
---|
3840 | # what configure does when it calls configure scripts in |
---|
3841 | # subdirectories, so they share the cache. |
---|
3842 | # Giving --cache-file=/dev/null disables caching, for debugging configure. |
---|
3843 | # config.status only pays attention to the cache file if you give it the |
---|
3844 | # --recheck option to rerun configure. |
---|
3845 | # |
---|
3846 | EOF |
---|
3847 | # Ultrix sh set writes to stderr and can't be redirected directly, |
---|
3848 | # and sets the high bit in the cache file unless we assign to the vars. |
---|
3849 | (set) 2>&1 | |
---|
3850 | sed -n "s/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=\${\1='\2'}/p" \ |
---|
3851 | >> confcache |
---|
3852 | if cmp -s $cache_file confcache; then |
---|
3853 | : |
---|
3854 | else |
---|
3855 | if test -w $cache_file; then |
---|
3856 | echo "updating cache $cache_file" |
---|
3857 | cat confcache > $cache_file |
---|
3858 | else |
---|
3859 | echo "not updating unwritable cache $cache_file" |
---|
3860 | fi |
---|
3861 | fi |
---|
3862 | rm -f confcache |
---|
3863 | |
---|
3864 | trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 |
---|
3865 | |
---|
3866 | test "x$prefix" = xNONE && prefix=$ac_default_prefix |
---|
3867 | # Let make expand exec_prefix. |
---|
3868 | test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' |
---|
3869 | |
---|
3870 | # Any assignment to VPATH causes Sun make to only execute |
---|
3871 | # the first set of double-colon rules, so remove it if not needed. |
---|
3872 | # If there is a colon in the path, we need to keep it. |
---|
3873 | if test "x$srcdir" = x.; then |
---|
3874 | ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d' |
---|
3875 | fi |
---|
3876 | |
---|
3877 | trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15 |
---|
3878 | |
---|
3879 | DEFS=-DHAVE_CONFIG_H |
---|
3880 | |
---|
3881 | # Without the "./", some shells look in PATH for config.status. |
---|
3882 | : ${CONFIG_STATUS=./config.status} |
---|
3883 | |
---|
3884 | echo creating $CONFIG_STATUS |
---|
3885 | rm -f $CONFIG_STATUS |
---|
3886 | cat > $CONFIG_STATUS <<EOF |
---|
3887 | #! /bin/sh |
---|
3888 | # Generated automatically by configure. |
---|
3889 | # Run this file to recreate the current configuration. |
---|
3890 | # This directory was configured as follows, |
---|
3891 | # on host `(hostname || uname -n) 2>/dev/null | sed 1q`: |
---|
3892 | # |
---|
3893 | # $0 $ac_configure_args |
---|
3894 | # |
---|
3895 | # Compiler output produced by configure, useful for debugging |
---|
3896 | # configure, is in ./config.log if it exists. |
---|
3897 | |
---|
3898 | ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]" |
---|
3899 | for ac_option |
---|
3900 | do |
---|
3901 | case "\$ac_option" in |
---|
3902 | -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) |
---|
3903 | echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion" |
---|
3904 | exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;; |
---|
3905 | -version | --version | --versio | --versi | --vers | --ver | --ve | --v) |
---|
3906 | echo "$CONFIG_STATUS generated by autoconf version 2.9" |
---|
3907 | exit 0 ;; |
---|
3908 | -help | --help | --hel | --he | --h) |
---|
3909 | echo "\$ac_cs_usage"; exit 0 ;; |
---|
3910 | *) echo "\$ac_cs_usage"; exit 1 ;; |
---|
3911 | esac |
---|
3912 | done |
---|
3913 | |
---|
3914 | ac_given_srcdir=$srcdir |
---|
3915 | |
---|
3916 | trap 'rm -fr `echo "Makefile mod2.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 |
---|
3917 | EOF |
---|
3918 | cat >> $CONFIG_STATUS <<EOF |
---|
3919 | |
---|
3920 | # Protect against being on the right side of a sed subst in config.status. |
---|
3921 | sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g; |
---|
3922 | s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF |
---|
3923 | $ac_vpsub |
---|
3924 | $extrasub |
---|
3925 | s%@CFLAGS@%$CFLAGS%g |
---|
3926 | s%@CPPFLAGS@%$CPPFLAGS%g |
---|
3927 | s%@CXXFLAGS@%$CXXFLAGS%g |
---|
3928 | s%@DEFS@%$DEFS%g |
---|
3929 | s%@LDFLAGS@%$LDFLAGS%g |
---|
3930 | s%@LIBS@%$LIBS%g |
---|
3931 | s%@exec_prefix@%$exec_prefix%g |
---|
3932 | s%@prefix@%$prefix%g |
---|
3933 | s%@program_transform_name@%$program_transform_name%g |
---|
3934 | s%@bindir@%$bindir%g |
---|
3935 | s%@sbindir@%$sbindir%g |
---|
3936 | s%@libexecdir@%$libexecdir%g |
---|
3937 | s%@datadir@%$datadir%g |
---|
3938 | s%@sysconfdir@%$sysconfdir%g |
---|
3939 | s%@sharedstatedir@%$sharedstatedir%g |
---|
3940 | s%@localstatedir@%$localstatedir%g |
---|
3941 | s%@libdir@%$libdir%g |
---|
3942 | s%@includedir@%$includedir%g |
---|
3943 | s%@oldincludedir@%$oldincludedir%g |
---|
3944 | s%@infodir@%$infodir%g |
---|
3945 | s%@mandir@%$mandir%g |
---|
3946 | s%@SINGULAR_VERSION@%$SINGULAR_VERSION%g |
---|
3947 | s%@CC@%$CC%g |
---|
3948 | s%@CPP@%$CPP%g |
---|
3949 | s%@CXX@%$CXX%g |
---|
3950 | s%@PIPE@%$PIPE%g |
---|
3951 | s%@CXXTEMPLFLAGS@%$CXXTEMPLFLAGS%g |
---|
3952 | s%@CXXNOOPTFLAGS@%$CXXNOOPTFLAGS%g |
---|
3953 | s%@STATIC_LDFLAGS@%$STATIC_LDFLAGS%g |
---|
3954 | s%@SET_MAKE@%$SET_MAKE%g |
---|
3955 | s%@SINGULAR@%$SINGULAR%g |
---|
3956 | s%@LEX@%$LEX%g |
---|
3957 | s%@PERL5@%$PERL5%g |
---|
3958 | s%@BISON@%$BISON%g |
---|
3959 | s%@INFO@%$INFO%g |
---|
3960 | s%@LN_S@%$LN_S%g |
---|
3961 | s%@ALLOCA@%$ALLOCA%g |
---|
3962 | s%@NEED_LIBS@%$NEED_LIBS%g |
---|
3963 | |
---|
3964 | CEOF |
---|
3965 | EOF |
---|
3966 | cat >> $CONFIG_STATUS <<EOF |
---|
3967 | |
---|
3968 | CONFIG_FILES=\${CONFIG_FILES-"Makefile"} |
---|
3969 | EOF |
---|
3970 | cat >> $CONFIG_STATUS <<\EOF |
---|
3971 | for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then |
---|
3972 | # Support "outfile[:infile]", defaulting infile="outfile.in". |
---|
3973 | case "$ac_file" in |
---|
3974 | *:*) ac_file_in=`echo "$ac_file"|sed 's%.*:%%'` |
---|
3975 | ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; |
---|
3976 | *) ac_file_in="${ac_file}.in" ;; |
---|
3977 | esac |
---|
3978 | |
---|
3979 | # Adjust relative srcdir, etc. for subdirectories. |
---|
3980 | |
---|
3981 | # Remove last slash and all that follows it. Not all systems have dirname. |
---|
3982 | ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` |
---|
3983 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then |
---|
3984 | # The file is in a subdirectory. |
---|
3985 | test ! -d "$ac_dir" && mkdir "$ac_dir" |
---|
3986 | ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`" |
---|
3987 | # A "../" for each directory in $ac_dir_suffix. |
---|
3988 | ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'` |
---|
3989 | else |
---|
3990 | ac_dir_suffix= ac_dots= |
---|
3991 | fi |
---|
3992 | |
---|
3993 | case "$ac_given_srcdir" in |
---|
3994 | .) srcdir=. |
---|
3995 | if test -z "$ac_dots"; then top_srcdir=. |
---|
3996 | else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;; |
---|
3997 | /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;; |
---|
3998 | *) # Relative path. |
---|
3999 | srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix" |
---|
4000 | top_srcdir="$ac_dots$ac_given_srcdir" ;; |
---|
4001 | esac |
---|
4002 | |
---|
4003 | echo creating "$ac_file" |
---|
4004 | rm -f "$ac_file" |
---|
4005 | configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure." |
---|
4006 | case "$ac_file" in |
---|
4007 | *Makefile*) ac_comsub="1i\\ |
---|
4008 | # $configure_input" ;; |
---|
4009 | *) ac_comsub= ;; |
---|
4010 | esac |
---|
4011 | sed -e "$ac_comsub |
---|
4012 | s%@configure_input@%$configure_input%g |
---|
4013 | s%@srcdir@%$srcdir%g |
---|
4014 | s%@top_srcdir@%$top_srcdir%g |
---|
4015 | " -f conftest.subs $ac_given_srcdir/$ac_file_in > $ac_file |
---|
4016 | fi; done |
---|
4017 | rm -f conftest.subs |
---|
4018 | |
---|
4019 | # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where |
---|
4020 | # NAME is the cpp macro being defined and VALUE is the value it is being given. |
---|
4021 | # |
---|
4022 | # ac_d sets the value in "#define NAME VALUE" lines. |
---|
4023 | ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)' |
---|
4024 | ac_dB='\([ ][ ]*\)[^ ]*%\1#\2' |
---|
4025 | ac_dC='\3' |
---|
4026 | ac_dD='%g' |
---|
4027 | # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE". |
---|
4028 | ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' |
---|
4029 | ac_uB='\([ ]\)%\1#\2define\3' |
---|
4030 | ac_uC=' ' |
---|
4031 | ac_uD='\4%g' |
---|
4032 | # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE". |
---|
4033 | ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' |
---|
4034 | ac_eB='$%\1#\2define\3' |
---|
4035 | ac_eC=' ' |
---|
4036 | ac_eD='%g' |
---|
4037 | |
---|
4038 | CONFIG_HEADERS=${CONFIG_HEADERS-"mod2.h"} |
---|
4039 | for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then |
---|
4040 | # Support "outfile[:infile]", defaulting infile="outfile.in". |
---|
4041 | case "$ac_file" in |
---|
4042 | *:*) ac_file_in=`echo "$ac_file"|sed 's%.*:%%'` |
---|
4043 | ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; |
---|
4044 | *) ac_file_in="${ac_file}.in" ;; |
---|
4045 | esac |
---|
4046 | |
---|
4047 | echo creating $ac_file |
---|
4048 | |
---|
4049 | rm -f conftest.frag conftest.in conftest.out |
---|
4050 | cp $ac_given_srcdir/$ac_file_in conftest.in |
---|
4051 | |
---|
4052 | EOF |
---|
4053 | |
---|
4054 | # Transform confdefs.h into a sed script conftest.vals that substitutes |
---|
4055 | # the proper values into config.h.in to produce config.h. And first: |
---|
4056 | # Protect against being on the right side of a sed subst in config.status. |
---|
4057 | # Protect against being in an unquoted here document in config.status. |
---|
4058 | rm -f conftest.vals |
---|
4059 | cat > conftest.hdr <<\EOF |
---|
4060 | s/[\\&%]/\\&/g |
---|
4061 | s%[\\$`]%\\&%g |
---|
4062 | s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp |
---|
4063 | s%ac_d%ac_u%gp |
---|
4064 | s%ac_u%ac_e%gp |
---|
4065 | EOF |
---|
4066 | sed -n -f conftest.hdr confdefs.h > conftest.vals |
---|
4067 | rm -f conftest.hdr |
---|
4068 | |
---|
4069 | # This sed command replaces #undef with comments. This is necessary, for |
---|
4070 | # example, in the case of _POSIX_SOURCE, which is predefined and required |
---|
4071 | # on some systems where configure will not decide to define it. |
---|
4072 | cat >> conftest.vals <<\EOF |
---|
4073 | s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */% |
---|
4074 | EOF |
---|
4075 | |
---|
4076 | # Break up conftest.vals because some shells have a limit on |
---|
4077 | # the size of here documents, and old seds have small limits too. |
---|
4078 | # Maximum number of lines to put in a single here document. |
---|
4079 | ac_max_here_lines=12 |
---|
4080 | |
---|
4081 | rm -f conftest.tail |
---|
4082 | while : |
---|
4083 | do |
---|
4084 | ac_lines=`grep -c . conftest.vals` |
---|
4085 | # grep -c gives empty output for an empty file on some AIX systems. |
---|
4086 | if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi |
---|
4087 | # Write a limited-size here document to conftest.frag. |
---|
4088 | echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS |
---|
4089 | sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS |
---|
4090 | echo 'CEOF |
---|
4091 | sed -f conftest.frag conftest.in > conftest.out |
---|
4092 | rm -f conftest.in |
---|
4093 | mv conftest.out conftest.in |
---|
4094 | ' >> $CONFIG_STATUS |
---|
4095 | sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail |
---|
4096 | rm -f conftest.vals |
---|
4097 | mv conftest.tail conftest.vals |
---|
4098 | done |
---|
4099 | rm -f conftest.vals |
---|
4100 | |
---|
4101 | cat >> $CONFIG_STATUS <<\EOF |
---|
4102 | rm -f conftest.frag conftest.h |
---|
4103 | echo "/* $ac_file. Generated automatically by configure. */" > conftest.h |
---|
4104 | cat conftest.in >> conftest.h |
---|
4105 | rm -f conftest.in |
---|
4106 | if cmp -s $ac_file conftest.h 2>/dev/null; then |
---|
4107 | echo "$ac_file is unchanged" |
---|
4108 | rm -f conftest.h |
---|
4109 | else |
---|
4110 | rm -f $ac_file |
---|
4111 | mv conftest.h $ac_file |
---|
4112 | fi |
---|
4113 | fi; done |
---|
4114 | |
---|
4115 | |
---|
4116 | \ |
---|
4117 | if test "$CONFIG_HEADERS"; then echo timestamp > stamp-h; fi |
---|
4118 | exit 0 |
---|
4119 | EOF |
---|
4120 | chmod +x $CONFIG_STATUS |
---|
4121 | rm -fr confdefs* $ac_clean_files |
---|
4122 | test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1 |
---|
4123 | |
---|
4124 | |
---|
4125 | |
---|
4126 | |
---|
4127 | |
---|