Parent Directory
|
Revision Log
Setting up web subdirectory in repository
1 | aw0a | 1 | #! /bin/sh |
2 | |||
3 | # Guess values for system-dependent variables and create Makefiles. | ||
4 | # Generated automatically using autoconf version 2.13 | ||
5 | # Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc. | ||
6 | # | ||
7 | # This configure script is free software; the Free Software Foundation | ||
8 | # gives unlimited permission to copy, distribute and modify it. | ||
9 | |||
10 | # Defaults: | ||
11 | ac_help= | ||
12 | ac_default_prefix=/usr/local | ||
13 | # Any additions from configure.in: | ||
14 | ac_help="$ac_help | ||
15 | |||
16 | ASCEND specific options | ||
17 | |||
18 | Compiler options: | ||
19 | --enable-gcc allow use of gcc if avaiable" | ||
20 | ac_help="$ac_help | ||
21 | --enable-optimization optimize the C code while building ascend" | ||
22 | ac_help="$ac_help | ||
23 | --with-x use the X Window System" | ||
24 | ac_help="$ac_help | ||
25 | Location of Tcl, Tk, and tkTable: | ||
26 | --with-tcl=LIBRARY,HEADER | ||
27 | The location of the Tcl8.0 library and/or header | ||
28 | For a static Tcl8.0 library, give the full path: | ||
29 | --with-tcl='/usr/local/lib/libtcl8.0.a' | ||
30 | For a dynamic library, give any -L options required: | ||
31 | --with-tcl='-L/usr/local/lib -ltcl8.0' | ||
32 | To specify only the header, leave off the library: | ||
33 | --with-tcl=',/usr/local/include/tcl.h' " | ||
34 | ac_help="$ac_help | ||
35 | --with-tk=LIBRARY,HEADER | ||
36 | The location of the Tk8.0 library and/or header | ||
37 | For a static Tk8.0 library, give the full path: | ||
38 | --with-tk='/usr/local/lib/libtk8.0.a' | ||
39 | For a dynamic library, give any -L options required: | ||
40 | --with-tk='-L/usr/local/lib -ltk8.0' | ||
41 | To specify only the header, leave off the library: | ||
42 | --with-tk=',/usr/local/include/tk.h' " | ||
43 | ac_help="$ac_help | ||
44 | --with-tktable=TKTABLE full path to a TkTable1.3 static library" | ||
45 | ac_help="$ac_help | ||
46 | --with-wish=/path/to/bin/wish | ||
47 | The location of the wish shell executable matching | ||
48 | the tcl/tk given by --with-tk and --with-tcl. | ||
49 | X11 must be running during configure. " | ||
50 | ac_help="$ac_help | ||
51 | Fortran compiler and libraries: | ||
52 | --with-fortran=F77,F77LIBS | ||
53 | The location of your Fortran compiler and its | ||
54 | library files. For example, under SunOS: | ||
55 | --with-fortran='f77,-L/usr/lang/lib -lF77 -lM77' | ||
56 | To specify only the compiler or libraries, leave off | ||
57 | whatever is not needed: | ||
58 | --with-fortran=',-L/usr/lang/lib -lF77 -lM77' | ||
59 | Use '--without-fortran' to not link against | ||
60 | any Fortran libraries" | ||
61 | ac_help="$ac_help | ||
62 | --with-blas=BLASLIB The full path to the blas library. | ||
63 | Use '--with-blas=build' to build the blas library | ||
64 | from the sources that come with the distribution." | ||
65 | ac_help="$ac_help | ||
66 | --with-linpack=LPAKLIB The full path to the linpack library. | ||
67 | Use '--with-linpack=build' to build the library | ||
68 | from the sources that come with the distribution." | ||
69 | ac_help="$ac_help | ||
70 | --with-lsod=LSODLIB The full path to the lsod library. | ||
71 | Use '--with-lsod=build' to build the lsod library | ||
72 | from the sources that come with the distribution." | ||
73 | ac_help="$ac_help | ||
74 | --with-conopt=CONOPTLIB The full path to the conopt library." | ||
75 | ac_help="$ac_help | ||
76 | Generation of Makefiles: | ||
77 | --without-tkdir do not generate Makefiles in the TK subdir" | ||
78 | ac_help="$ac_help | ||
79 | --without-models do not generate Makefiles in the models subdir" | ||
80 | |||
81 | # Initialize some variables set by options. | ||
82 | # The variables have the same names as the options, with | ||
83 | # dashes changed to underlines. | ||
84 | build=NONE | ||
85 | cache_file=./config.cache | ||
86 | exec_prefix=NONE | ||
87 | host=NONE | ||
88 | no_create= | ||
89 | nonopt=NONE | ||
90 | no_recursion= | ||
91 | prefix=NONE | ||
92 | program_prefix=NONE | ||
93 | program_suffix=NONE | ||
94 | program_transform_name=s,x,x, | ||
95 | silent= | ||
96 | site= | ||
97 | srcdir= | ||
98 | target=NONE | ||
99 | verbose= | ||
100 | x_includes=NONE | ||
101 | x_libraries=NONE | ||
102 | bindir='${exec_prefix}/bin' | ||
103 | sbindir='${exec_prefix}/sbin' | ||
104 | libexecdir='${exec_prefix}/libexec' | ||
105 | datadir='${prefix}/share' | ||
106 | sysconfdir='${prefix}/etc' | ||
107 | sharedstatedir='${prefix}/com' | ||
108 | localstatedir='${prefix}/var' | ||
109 | libdir='${exec_prefix}/lib' | ||
110 | includedir='${prefix}/include' | ||
111 | oldincludedir='/usr/include' | ||
112 | infodir='${prefix}/info' | ||
113 | mandir='${prefix}/man' | ||
114 | |||
115 | # Initialize some other variables. | ||
116 | subdirs= | ||
117 | MFLAGS= MAKEFLAGS= | ||
118 | SHELL=${CONFIG_SHELL-/bin/sh} | ||
119 | # Maximum number of lines to put in a shell here document. | ||
120 | ac_max_here_lines=12 | ||
121 | |||
122 | ac_prev= | ||
123 | for ac_option | ||
124 | do | ||
125 | |||
126 | # If the previous option needs an argument, assign it. | ||
127 | if test -n "$ac_prev"; then | ||
128 | eval "$ac_prev=\$ac_option" | ||
129 | ac_prev= | ||
130 | continue | ||
131 | fi | ||
132 | |||
133 | case "$ac_option" in | ||
134 | -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;; | ||
135 | *) ac_optarg= ;; | ||
136 | esac | ||
137 | |||
138 | # Accept the important Cygnus configure options, so we can diagnose typos. | ||
139 | |||
140 | case "$ac_option" in | ||
141 | |||
142 | -bindir | --bindir | --bindi | --bind | --bin | --bi) | ||
143 | ac_prev=bindir ;; | ||
144 | -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) | ||
145 | bindir="$ac_optarg" ;; | ||
146 | |||
147 | -build | --build | --buil | --bui | --bu) | ||
148 | ac_prev=build ;; | ||
149 | -build=* | --build=* | --buil=* | --bui=* | --bu=*) | ||
150 | build="$ac_optarg" ;; | ||
151 | |||
152 | -cache-file | --cache-file | --cache-fil | --cache-fi \ | ||
153 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) | ||
154 | ac_prev=cache_file ;; | ||
155 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | ||
156 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) | ||
157 | cache_file="$ac_optarg" ;; | ||
158 | |||
159 | -datadir | --datadir | --datadi | --datad | --data | --dat | --da) | ||
160 | ac_prev=datadir ;; | ||
161 | -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \ | ||
162 | | --da=*) | ||
163 | datadir="$ac_optarg" ;; | ||
164 | |||
165 | -disable-* | --disable-*) | ||
166 | ac_feature=`echo $ac_option|sed -e 's/-*disable-//'` | ||
167 | # Reject names that are not valid shell variable names. | ||
168 | if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then | ||
169 | { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } | ||
170 | fi | ||
171 | ac_feature=`echo $ac_feature| sed 's/-/_/g'` | ||
172 | eval "enable_${ac_feature}=no" ;; | ||
173 | |||
174 | -enable-* | --enable-*) | ||
175 | ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'` | ||
176 | # Reject names that are not valid shell variable names. | ||
177 | if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then | ||
178 | { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } | ||
179 | fi | ||
180 | ac_feature=`echo $ac_feature| sed 's/-/_/g'` | ||
181 | case "$ac_option" in | ||
182 | *=*) ;; | ||
183 | *) ac_optarg=yes ;; | ||
184 | esac | ||
185 | eval "enable_${ac_feature}='$ac_optarg'" ;; | ||
186 | |||
187 | -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ | ||
188 | | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ | ||
189 | | --exec | --exe | --ex) | ||
190 | ac_prev=exec_prefix ;; | ||
191 | -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ | ||
192 | | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ | ||
193 | | --exec=* | --exe=* | --ex=*) | ||
194 | exec_prefix="$ac_optarg" ;; | ||
195 | |||
196 | -gas | --gas | --ga | --g) | ||
197 | # Obsolete; use --with-gas. | ||
198 | with_gas=yes ;; | ||
199 | |||
200 | -help | --help | --hel | --he) | ||
201 | # Omit some internal or obsolete options to make the list less imposing. | ||
202 | # This message is too long to be a string in the A/UX 3.1 sh. | ||
203 | cat << EOF | ||
204 | Usage: configure [options] [host] | ||
205 | Options: [defaults in brackets after descriptions] | ||
206 | Configuration: | ||
207 | --cache-file=FILE cache test results in FILE | ||
208 | --help print this message | ||
209 | --no-create do not create output files | ||
210 | --quiet, --silent do not print \`checking...' messages | ||
211 | --version print the version of autoconf that created configure | ||
212 | Directory and file names: | ||
213 | --prefix=PREFIX install architecture-independent files in PREFIX | ||
214 | [$ac_default_prefix] | ||
215 | --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX | ||
216 | [same as prefix] | ||
217 | --bindir=DIR user executables in DIR [EPREFIX/bin] | ||
218 | --sbindir=DIR system admin executables in DIR [EPREFIX/sbin] | ||
219 | --libexecdir=DIR program executables in DIR [EPREFIX/libexec] | ||
220 | --datadir=DIR read-only architecture-independent data in DIR | ||
221 | [PREFIX/share] | ||
222 | --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc] | ||
223 | --sharedstatedir=DIR modifiable architecture-independent data in DIR | ||
224 | [PREFIX/com] | ||
225 | --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var] | ||
226 | --libdir=DIR object code libraries in DIR [EPREFIX/lib] | ||
227 | --includedir=DIR C header files in DIR [PREFIX/include] | ||
228 | --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include] | ||
229 | --infodir=DIR info documentation in DIR [PREFIX/info] | ||
230 | --mandir=DIR man documentation in DIR [PREFIX/man] | ||
231 | --srcdir=DIR find the sources in DIR [configure dir or ..] | ||
232 | --program-prefix=PREFIX prepend PREFIX to installed program names | ||
233 | --program-suffix=SUFFIX append SUFFIX to installed program names | ||
234 | --program-transform-name=PROGRAM | ||
235 | run sed PROGRAM on installed program names | ||
236 | EOF | ||
237 | cat << EOF | ||
238 | Host type: | ||
239 | --build=BUILD configure for building on BUILD [BUILD=HOST] | ||
240 | --host=HOST configure for HOST [guessed] | ||
241 | --target=TARGET configure for TARGET [TARGET=HOST] | ||
242 | Features and packages: | ||
243 | --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) | ||
244 | --enable-FEATURE[=ARG] include FEATURE [ARG=yes] | ||
245 | --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] | ||
246 | --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) | ||
247 | --x-includes=DIR X include files are in DIR | ||
248 | --x-libraries=DIR X library files are in DIR | ||
249 | EOF | ||
250 | if test -n "$ac_help"; then | ||
251 | echo "--enable and --with options recognized:$ac_help" | ||
252 | fi | ||
253 | exit 0 ;; | ||
254 | |||
255 | -host | --host | --hos | --ho) | ||
256 | ac_prev=host ;; | ||
257 | -host=* | --host=* | --hos=* | --ho=*) | ||
258 | host="$ac_optarg" ;; | ||
259 | |||
260 | -includedir | --includedir | --includedi | --included | --include \ | ||
261 | | --includ | --inclu | --incl | --inc) | ||
262 | ac_prev=includedir ;; | ||
263 | -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ | ||
264 | | --includ=* | --inclu=* | --incl=* | --inc=*) | ||
265 | includedir="$ac_optarg" ;; | ||
266 | |||
267 | -infodir | --infodir | --infodi | --infod | --info | --inf) | ||
268 | ac_prev=infodir ;; | ||
269 | -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) | ||
270 | infodir="$ac_optarg" ;; | ||
271 | |||
272 | -libdir | --libdir | --libdi | --libd) | ||
273 | ac_prev=libdir ;; | ||
274 | -libdir=* | --libdir=* | --libdi=* | --libd=*) | ||
275 | libdir="$ac_optarg" ;; | ||
276 | |||
277 | -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ | ||
278 | | --libexe | --libex | --libe) | ||
279 | ac_prev=libexecdir ;; | ||
280 | -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ | ||
281 | | --libexe=* | --libex=* | --libe=*) | ||
282 | libexecdir="$ac_optarg" ;; | ||
283 | |||
284 | -localstatedir | --localstatedir | --localstatedi | --localstated \ | ||
285 | | --localstate | --localstat | --localsta | --localst \ | ||
286 | | --locals | --local | --loca | --loc | --lo) | ||
287 | ac_prev=localstatedir ;; | ||
288 | -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ | ||
289 | | --localstate=* | --localstat=* | --localsta=* | --localst=* \ | ||
290 | | --locals=* | --local=* | --loca=* | --loc=* | --lo=*) | ||
291 | localstatedir="$ac_optarg" ;; | ||
292 | |||
293 | -mandir | --mandir | --mandi | --mand | --man | --ma | --m) | ||
294 | ac_prev=mandir ;; | ||
295 | -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) | ||
296 | mandir="$ac_optarg" ;; | ||
297 | |||
298 | -nfp | --nfp | --nf) | ||
299 | # Obsolete; use --without-fp. | ||
300 | with_fp=no ;; | ||
301 | |||
302 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | ||
303 | | --no-cr | --no-c) | ||
304 | no_create=yes ;; | ||
305 | |||
306 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ | ||
307 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) | ||
308 | no_recursion=yes ;; | ||
309 | |||
310 | -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ | ||
311 | | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ | ||
312 | | --oldin | --oldi | --old | --ol | --o) | ||
313 | ac_prev=oldincludedir ;; | ||
314 | -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ | ||
315 | | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ | ||
316 | | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) | ||
317 | oldincludedir="$ac_optarg" ;; | ||
318 | |||
319 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) | ||
320 | ac_prev=prefix ;; | ||
321 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) | ||
322 | prefix="$ac_optarg" ;; | ||
323 | |||
324 | -program-prefix | --program-prefix | --program-prefi | --program-pref \ | ||
325 | | --program-pre | --program-pr | --program-p) | ||
326 | ac_prev=program_prefix ;; | ||
327 | -program-prefix=* | --program-prefix=* | --program-prefi=* \ | ||
328 | | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) | ||
329 | program_prefix="$ac_optarg" ;; | ||
330 | |||
331 | -program-suffix | --program-suffix | --program-suffi | --program-suff \ | ||
332 | | --program-suf | --program-su | --program-s) | ||
333 | ac_prev=program_suffix ;; | ||
334 | -program-suffix=* | --program-suffix=* | --program-suffi=* \ | ||
335 | | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) | ||
336 | program_suffix="$ac_optarg" ;; | ||
337 | |||
338 | -program-transform-name | --program-transform-name \ | ||
339 | | --program-transform-nam | --program-transform-na \ | ||
340 | | --program-transform-n | --program-transform- \ | ||
341 | | --program-transform | --program-transfor \ | ||
342 | | --program-transfo | --program-transf \ | ||
343 | | --program-trans | --program-tran \ | ||
344 | | --progr-tra | --program-tr | --program-t) | ||
345 | ac_prev=program_transform_name ;; | ||
346 | -program-transform-name=* | --program-transform-name=* \ | ||
347 | | --program-transform-nam=* | --program-transform-na=* \ | ||
348 | | --program-transform-n=* | --program-transform-=* \ | ||
349 | | --program-transform=* | --program-transfor=* \ | ||
350 | | --program-transfo=* | --program-transf=* \ | ||
351 | | --program-trans=* | --program-tran=* \ | ||
352 | | --progr-tra=* | --program-tr=* | --program-t=*) | ||
353 | program_transform_name="$ac_optarg" ;; | ||
354 | |||
355 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | ||
356 | | -silent | --silent | --silen | --sile | --sil) | ||
357 | silent=yes ;; | ||
358 | |||
359 | -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) | ||
360 | ac_prev=sbindir ;; | ||
361 | -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ | ||
362 | | --sbi=* | --sb=*) | ||
363 | sbindir="$ac_optarg" ;; | ||
364 | |||
365 | -sharedstatedir | --sharedstatedir | --sharedstatedi \ | ||
366 | | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ | ||
367 | | --sharedst | --shareds | --shared | --share | --shar \ | ||
368 | | --sha | --sh) | ||
369 | ac_prev=sharedstatedir ;; | ||
370 | -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ | ||
371 | | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ | ||
372 | | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ | ||
373 | | --sha=* | --sh=*) | ||
374 | sharedstatedir="$ac_optarg" ;; | ||
375 | |||
376 | -site | --site | --sit) | ||
377 | ac_prev=site ;; | ||
378 | -site=* | --site=* | --sit=*) | ||
379 | site="$ac_optarg" ;; | ||
380 | |||
381 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) | ||
382 | ac_prev=srcdir ;; | ||
383 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) | ||
384 | srcdir="$ac_optarg" ;; | ||
385 | |||
386 | -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ | ||
387 | | --syscon | --sysco | --sysc | --sys | --sy) | ||
388 | ac_prev=sysconfdir ;; | ||
389 | -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ | ||
390 | | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) | ||
391 | sysconfdir="$ac_optarg" ;; | ||
392 | |||
393 | -target | --target | --targe | --targ | --tar | --ta | --t) | ||
394 | ac_prev=target ;; | ||
395 | -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) | ||
396 | target="$ac_optarg" ;; | ||
397 | |||
398 | -v | -verbose | --verbose | --verbos | --verbo | --verb) | ||
399 | verbose=yes ;; | ||
400 | |||
401 | -version | --version | --versio | --versi | --vers) | ||
402 | echo "configure generated by autoconf version 2.13" | ||
403 | exit 0 ;; | ||
404 | |||
405 | -with-* | --with-*) | ||
406 | ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'` | ||
407 | # Reject names that are not valid shell variable names. | ||
408 | if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then | ||
409 | { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } | ||
410 | fi | ||
411 | ac_package=`echo $ac_package| sed 's/-/_/g'` | ||
412 | case "$ac_option" in | ||
413 | *=*) ;; | ||
414 | *) ac_optarg=yes ;; | ||
415 | esac | ||
416 | eval "with_${ac_package}='$ac_optarg'" ;; | ||
417 | |||
418 | -without-* | --without-*) | ||
419 | ac_package=`echo $ac_option|sed -e 's/-*without-//'` | ||
420 | # Reject names that are not valid shell variable names. | ||
421 | if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then | ||
422 | { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } | ||
423 | fi | ||
424 | ac_package=`echo $ac_package| sed 's/-/_/g'` | ||
425 | eval "with_${ac_package}=no" ;; | ||
426 | |||
427 | --x) | ||
428 | # Obsolete; use --with-x. | ||
429 | with_x=yes ;; | ||
430 | |||
431 | -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ | ||
432 | | --x-incl | --x-inc | --x-in | --x-i) | ||
433 | ac_prev=x_includes ;; | ||
434 | -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ | ||
435 | | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) | ||
436 | x_includes="$ac_optarg" ;; | ||
437 | |||
438 | -x-libraries | --x-libraries | --x-librarie | --x-librari \ | ||
439 | | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) | ||
440 | ac_prev=x_libraries ;; | ||
441 | -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ | ||
442 | | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) | ||
443 | x_libraries="$ac_optarg" ;; | ||
444 | |||
445 | -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; } | ||
446 | ;; | ||
447 | |||
448 | *) | ||
449 | if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then | ||
450 | echo "configure: warning: $ac_option: invalid host type" 1>&2 | ||
451 | fi | ||
452 | if test "x$nonopt" != xNONE; then | ||
453 | { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } | ||
454 | fi | ||
455 | nonopt="$ac_option" | ||
456 | ;; | ||
457 | |||
458 | esac | ||
459 | done | ||
460 | |||
461 | if test -n "$ac_prev"; then | ||
462 | { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; } | ||
463 | fi | ||
464 | |||
465 | trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 | ||
466 | |||
467 | # File descriptor usage: | ||
468 | # 0 standard input | ||
469 | # 1 file creation | ||
470 | # 2 errors and warnings | ||
471 | # 3 some systems may open it to /dev/tty | ||
472 | # 4 used on the Kubota Titan | ||
473 | # 6 checking for... messages and results | ||
474 | # 5 compiler messages saved in config.log | ||
475 | if test "$silent" = yes; then | ||
476 | exec 6>/dev/null | ||
477 | else | ||
478 | exec 6>&1 | ||
479 | fi | ||
480 | exec 5>./config.log | ||
481 | |||
482 | echo "\ | ||
483 | This file contains any messages produced by compilers while | ||
484 | running configure, to aid debugging if configure makes a mistake. | ||
485 | " 1>&5 | ||
486 | |||
487 | # Strip out --no-create and --no-recursion so they do not pile up. | ||
488 | # Also quote any args containing shell metacharacters. | ||
489 | ac_configure_args= | ||
490 | for ac_arg | ||
491 | do | ||
492 | case "$ac_arg" in | ||
493 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | ||
494 | | --no-cr | --no-c) ;; | ||
495 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ | ||
496 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;; | ||
497 | *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*) | ||
498 | ac_configure_args="$ac_configure_args '$ac_arg'" ;; | ||
499 | *) ac_configure_args="$ac_configure_args $ac_arg" ;; | ||
500 | esac | ||
501 | done | ||
502 | |||
503 | # NLS nuisances. | ||
504 | # Only set these to C if already set. These must not be set unconditionally | ||
505 | # because not all systems understand e.g. LANG=C (notably SCO). | ||
506 | # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'! | ||
507 | # Non-C LC_CTYPE values break the ctype check. | ||
508 | if test "${LANG+set}" = set; then LANG=C; export LANG; fi | ||
509 | if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi | ||
510 | if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi | ||
511 | if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi | ||
512 | |||
513 | # confdefs.h avoids OS command line length limits that DEFS can exceed. | ||
514 | rm -rf conftest* confdefs.h | ||
515 | # AIX cpp loses on an empty file, so make sure it contains at least a newline. | ||
516 | echo > confdefs.h | ||
517 | |||
518 | # A filename unique to this package, relative to the directory that | ||
519 | # configure is in, which we can look for to find out if srcdir is correct. | ||
520 | ac_unique_file=ascend4/compiler/ascParse.y | ||
521 | |||
522 | # Find the source files, if location was not specified. | ||
523 | if test -z "$srcdir"; then | ||
524 | ac_srcdir_defaulted=yes | ||
525 | # Try the directory containing this script, then its parent. | ||
526 | ac_prog=$0 | ||
527 | ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'` | ||
528 | test "x$ac_confdir" = "x$ac_prog" && ac_confdir=. | ||
529 | srcdir=$ac_confdir | ||
530 | if test ! -r $srcdir/$ac_unique_file; then | ||
531 | srcdir=.. | ||
532 | fi | ||
533 | else | ||
534 | ac_srcdir_defaulted=no | ||
535 | fi | ||
536 | if test ! -r $srcdir/$ac_unique_file; then | ||
537 | if test "$ac_srcdir_defaulted" = yes; then | ||
538 | { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; } | ||
539 | else | ||
540 | { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; } | ||
541 | fi | ||
542 | fi | ||
543 | srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'` | ||
544 | |||
545 | # Prefer explicitly selected file to automatically selected ones. | ||
546 | if test -z "$CONFIG_SITE"; then | ||
547 | if test "x$prefix" != xNONE; then | ||
548 | CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site" | ||
549 | else | ||
550 | CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site" | ||
551 | fi | ||
552 | fi | ||
553 | for ac_site_file in $CONFIG_SITE; do | ||
554 | if test -r "$ac_site_file"; then | ||
555 | echo "loading site script $ac_site_file" | ||
556 | . "$ac_site_file" | ||
557 | fi | ||
558 | done | ||
559 | |||
560 | |||
561 | ac_ext=c | ||
562 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. | ||
563 | ac_cpp='$CPP $CPPFLAGS' | ||
564 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' | ||
565 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' | ||
566 | cross_compiling=$ac_cv_prog_cc_cross | ||
567 | |||
568 | ac_exeext= | ||
569 | ac_objext=o | ||
570 | if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then | ||
571 | # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu. | ||
572 | if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then | ||
573 | ac_n= ac_c=' | ||
574 | ' ac_t=' ' | ||
575 | else | ||
576 | ac_n=-n ac_c= ac_t= | ||
577 | fi | ||
578 | else | ||
579 | ac_n= ac_c='\c' ac_t= | ||
580 | fi | ||
581 | |||
582 | |||
583 | |||
584 | |||
585 | #-------------------------------------------------------------------- | ||
586 | # CVS Most Recent Revision Data | ||
587 | # Put this data after AC_INIT since we want this information | ||
588 | # to also appear in configure and autoconf, when creating | ||
589 | # configure, strips all comments that appear in configure.in | ||
590 | # before AC_INIT | ||
591 | # $Revision: 1.37 $ | ||
592 | # $Date: 2003/11/23 19:36:39 $ | ||
593 | # $Author: ballan $ | ||
594 | # $Source: /afs/cs.cmu.edu/project/ascend/Repository/configure,v $ | ||
595 | #-------------------------------------------------------------------- | ||
596 | |||
597 | |||
598 | #-------------------------------------------------------------------- | ||
599 | # Where configure should look for files it needs. | ||
600 | #-------------------------------------------------------------------- | ||
601 | ac_aux_dir= | ||
602 | for ac_dir in config $srcdir/config; do | ||
603 | if test -f $ac_dir/install-sh; then | ||
604 | ac_aux_dir=$ac_dir | ||
605 | ac_install_sh="$ac_aux_dir/install-sh -c" | ||
606 | break | ||
607 | elif test -f $ac_dir/install.sh; then | ||
608 | ac_aux_dir=$ac_dir | ||
609 | ac_install_sh="$ac_aux_dir/install.sh -c" | ||
610 | break | ||
611 | fi | ||
612 | done | ||
613 | if test -z "$ac_aux_dir"; then | ||
614 | { echo "configure: error: can not find install-sh or install.sh in config $srcdir/config" 1>&2; exit 1; } | ||
615 | fi | ||
616 | ac_config_guess=$ac_aux_dir/config.guess | ||
617 | ac_config_sub=$ac_aux_dir/config.sub | ||
618 | ac_configure=$ac_aux_dir/configure # This should be Cygnus configure. | ||
619 | |||
620 | |||
621 | #-------------------------------------------------------------------- | ||
622 | # Set the output variables prefix and exec_prefix that | ||
623 | # determine where things will be installed. | ||
624 | #-------------------------------------------------------------------- | ||
625 | if test "${prefix}" = "NONE"; then | ||
626 | prefix=/usr/local | ||
627 | fi | ||
628 | if test "${exec_prefix}" = "NONE"; then | ||
629 | exec_prefix=$prefix | ||
630 | fi | ||
631 | |||
632 | |||
633 | #-------------------------------------------------------------------- | ||
634 | # For the Fortran support libraries and the TCL/TK libraries | ||
635 | # and header files, we unfortunately need the full path to | ||
636 | # these files. The problem with having the full path is that | ||
637 | # if the user moves the source tree, things will break unless | ||
638 | # the user re-runs configure. | ||
639 | #-------------------------------------------------------------------- | ||
640 | ascpwd=`pwd` | ||
641 | fullpathsrcdir=`cd $srcdir ; pwd` | ||
642 | |||
643 | |||
644 | #-------------------------------------------------------------------- | ||
645 | # The asc_include variable is (directory) path to the ascend4 | ||
646 | # SOURCE directory relative to the immediate subdirectories of | ||
647 | # the ascend4 OBJECT directory. | ||
648 | # -- If we are building in the source directory ($srcdir is "." | ||
649 | # asc_include is simply "../." | ||
650 | # -- If the user gives us a full path to the configure script, | ||
651 | # we just append "/ascend4" to that full path: | ||
652 | # "$scrdir/ascend4" | ||
653 | # -- For any other value of $srcdir (like ../src/), we go up | ||
654 | # two directories (to get to the top of the OBJECT tree, | ||
655 | # insert the source directory, and then go back down one | ||
656 | # level to the ascend4 directory: "../../$srcdir/ascend4" | ||
657 | #-------------------------------------------------------------------- | ||
658 | case "$srcdir" in | ||
659 | .) | ||
660 | asc_include="../$srcdir" | ||
661 | ;; | ||
662 | /*) | ||
663 | asc_include="$srcdir/ascend4" | ||
664 | ;; | ||
665 | *) | ||
666 | asc_include="../../$srcdir/ascend4" | ||
667 | ;; | ||
668 | esac | ||
669 | |||
670 | |||
671 | #-------------------------------------------------------------------- | ||
672 | # Do basic checks to determine | ||
673 | # * if we have `ranlib' | ||
674 | # * if we can create symbolic links | ||
675 | # * if `make' sets the MAKE macro | ||
676 | # * a bsd-compatible `install' program | ||
677 | # If we use the install-sh script that comes with configure, | ||
678 | # prefix it with the current directory so it'll work in | ||
679 | # subdirectories. Unfortunately, it won't work if the user | ||
680 | # moves the source tree. | ||
681 | #-------------------------------------------------------------------- | ||
682 | # Extract the first word of "ranlib", so it can be a program name with args. | ||
683 | set dummy ranlib; ac_word=$2 | ||
684 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | ||
685 | echo "configure:686: checking for $ac_word" >&5 | ||
686 | if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then | ||
687 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
688 | else | ||
689 | if test -n "$RANLIB"; then | ||
690 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. | ||
691 | else | ||
692 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | ||
693 | ac_dummy="$PATH" | ||
694 | for ac_dir in $ac_dummy; do | ||
695 | test -z "$ac_dir" && ac_dir=. | ||
696 | if test -f $ac_dir/$ac_word; then | ||
697 | ac_cv_prog_RANLIB="ranlib" | ||
698 | break | ||
699 | fi | ||
700 | done | ||
701 | IFS="$ac_save_ifs" | ||
702 | test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":" | ||
703 | fi | ||
704 | fi | ||
705 | RANLIB="$ac_cv_prog_RANLIB" | ||
706 | if test -n "$RANLIB"; then | ||
707 | echo "$ac_t""$RANLIB" 1>&6 | ||
708 | else | ||
709 | echo "$ac_t""no" 1>&6 | ||
710 | fi | ||
711 | |||
712 | echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6 | ||
713 | echo "configure:714: checking whether ln -s works" >&5 | ||
714 | if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then | ||
715 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
716 | else | ||
717 | rm -f conftestdata | ||
718 | if ln -s X conftestdata 2>/dev/null | ||
719 | then | ||
720 | rm -f conftestdata | ||
721 | ac_cv_prog_LN_S="ln -s" | ||
722 | else | ||
723 | ac_cv_prog_LN_S=ln | ||
724 | fi | ||
725 | fi | ||
726 | LN_S="$ac_cv_prog_LN_S" | ||
727 | if test "$ac_cv_prog_LN_S" = "ln -s"; then | ||
728 | echo "$ac_t""yes" 1>&6 | ||
729 | else | ||
730 | echo "$ac_t""no" 1>&6 | ||
731 | fi | ||
732 | |||
733 | echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6 | ||
734 | echo "configure:735: checking whether ${MAKE-make} sets \${MAKE}" >&5 | ||
735 | set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'` | ||
736 | if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then | ||
737 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
738 | else | ||
739 | cat > conftestmake <<\EOF | ||
740 | all: | ||
741 | @echo 'ac_maketemp="${MAKE}"' | ||
742 | EOF | ||
743 | # GNU make sometimes prints "make[1]: Entering...", which would confuse us. | ||
744 | eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=` | ||
745 | if test -n "$ac_maketemp"; then | ||
746 | eval ac_cv_prog_make_${ac_make}_set=yes | ||
747 | else | ||
748 | eval ac_cv_prog_make_${ac_make}_set=no | ||
749 | fi | ||
750 | rm -f conftestmake | ||
751 | fi | ||
752 | if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then | ||
753 | echo "$ac_t""yes" 1>&6 | ||
754 | SET_MAKE= | ||
755 | else | ||
756 | echo "$ac_t""no" 1>&6 | ||
757 | SET_MAKE="MAKE=${MAKE-make}" | ||
758 | fi | ||
759 | |||
760 | # Find a good install program. We prefer a C program (faster), | ||
761 | # so one script is as good as another. But avoid the broken or | ||
762 | # incompatible versions: | ||
763 | # SysV /etc/install, /usr/sbin/install | ||
764 | # SunOS /usr/etc/install | ||
765 | # IRIX /sbin/install | ||
766 | # AIX /bin/install | ||
767 | # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag | ||
768 | # AFS /usr/afsws/bin/install, which mishandles nonexistent args | ||
769 | # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" | ||
770 | # ./install, which can be erroneously created by make from ./install.sh. | ||
771 | echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6 | ||
772 | echo "configure:773: checking for a BSD compatible install" >&5 | ||
773 | if test -z "$INSTALL"; then | ||
774 | if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then | ||
775 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
776 | else | ||
777 | IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":" | ||
778 | for ac_dir in $PATH; do | ||
779 | # Account for people who put trailing slashes in PATH elements. | ||
780 | case "$ac_dir/" in | ||
781 | /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;; | ||
782 | *) | ||
783 | # OSF1 and SCO ODT 3.0 have their own names for install. | ||
784 | # Don't use installbsd from OSF since it installs stuff as root | ||
785 | # by default. | ||
786 | for ac_prog in ginstall scoinst install; do | ||
787 | if test -f $ac_dir/$ac_prog; then | ||
788 | if test $ac_prog = install && | ||
789 | grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then | ||
790 | # AIX install. It has an incompatible calling convention. | ||
791 | : | ||
792 | else | ||
793 | ac_cv_path_install="$ac_dir/$ac_prog -c" | ||
794 | break 2 | ||
795 | fi | ||
796 | fi | ||
797 | done | ||
798 | ;; | ||
799 | esac | ||
800 | done | ||
801 | IFS="$ac_save_IFS" | ||
802 | |||
803 | fi | ||
804 | if test "${ac_cv_path_install+set}" = set; then | ||
805 | INSTALL="$ac_cv_path_install" | ||
806 | else | ||
807 | # As a last resort, use the slow shell script. We don't cache a | ||
808 | # path for INSTALL within a source directory, because that will | ||
809 | # break other packages using the cache if that directory is | ||
810 | # removed, or if the path is relative. | ||
811 | INSTALL="$ac_install_sh" | ||
812 | fi | ||
813 | fi | ||
814 | echo "$ac_t""$INSTALL" 1>&6 | ||
815 | |||
816 | # Use test -z because SunOS4 sh mishandles braces in ${var-val}. | ||
817 | # It thinks the first close brace ends the variable substitution. | ||
818 | test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' | ||
819 | |||
820 | test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}' | ||
821 | |||
822 | test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' | ||
823 | |||
824 | case "X$INSTALL" in | ||
825 | X/*) | ||
826 | ;; | ||
827 | *) | ||
828 | INSTALL="$ascpwd/$INSTALL" | ||
829 | ;; | ||
830 | esac | ||
831 | |||
832 | |||
833 | #-------------------------------------------------------------------- | ||
834 | # Get the host type for various checks along the way | ||
835 | #-------------------------------------------------------------------- | ||
836 | |||
837 | # Make sure we can run config.sub. | ||
838 | if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then : | ||
839 | else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; } | ||
840 | fi | ||
841 | |||
842 | echo $ac_n "checking host system type""... $ac_c" 1>&6 | ||
843 | echo "configure:844: checking host system type" >&5 | ||
844 | |||
845 | host_alias=$host | ||
846 | case "$host_alias" in | ||
847 | NONE) | ||
848 | case $nonopt in | ||
849 | NONE) | ||
850 | if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then : | ||
851 | else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; } | ||
852 | fi ;; | ||
853 | *) host_alias=$nonopt ;; | ||
854 | esac ;; | ||
855 | esac | ||
856 | |||
857 | host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias` | ||
858 | host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` | ||
859 | host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` | ||
860 | host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` | ||
861 | echo "$ac_t""$host" 1>&6 | ||
862 | |||
863 | |||
864 | |||
865 | #-------------------------------------------------------------------- | ||
866 | # Check for the C compiler: set CC and CFLAGS. | ||
867 | # If the user does NOT specify `--enable-gcc' on the configure | ||
868 | # command command line, set CC to either the envar CC or `cc'. | ||
869 | # Call AC_PROG_CC which will use the value of CC (perhaps set | ||
870 | # immediately above) or will check for `gcc' and then for `cc' | ||
871 | # if `gcc' is not found. | ||
872 | # | ||
873 | # If we are using GCC, then assume it groks ANSI. Otherwise, | ||
874 | # try to compile a small program using ANSI constructs with | ||
875 | # CC. If this fails, try to locate each of the following: | ||
876 | # c89 xlc acc | ||
877 | # and if successful, see if it compiles an ANSI C program. | ||
878 | # (Doing this in a loop would be ideal, but configure caches | ||
879 | # the result of AC_CHECK_PROG and uses the cached value for | ||
880 | # all but the first pass through the loop. This is also the | ||
881 | # reason we have to use a different variable asc_cc1, asc_cc2 | ||
882 | # for each call to AC_CHECK_PROG. | ||
883 | # | ||
884 | # If we do not find an ANSI C compiler, print a warning and | ||
885 | # use the first value of CC we tried. | ||
886 | #-------------------------------------------------------------------- | ||
887 | |||
888 | # Check whether --enable-gcc or --disable-gcc was given. | ||
889 | if test "${enable_gcc+set}" = set; then | ||
890 | enableval="$enable_gcc" | ||
891 | asc_gcc_ok=$enableval | ||
892 | else | ||
893 | asc_gcc_ok=no | ||
894 | fi | ||
895 | |||
896 | if test ! "$asc_gcc_ok" = "yes"; then | ||
897 | CC=${CC-cc} | ||
898 | fi | ||
899 | asc_orig_cc=$CC | ||
900 | |||
901 | if test "X$asc_gcc_ok" = "Xyes" ; then | ||
902 | asc_ansi_ok=yes | ||
903 | else | ||
904 | echo $ac_n "checking whether $CC understands const, void*, and function prototypes""... $ac_c" 1>&6 | ||
905 | echo "configure:906: checking whether $CC understands const, void*, and function prototypes" >&5 | ||
906 | cat > conftest.$ac_ext <<EOF | ||
907 | #line 908 "configure" | ||
908 | #include "confdefs.h" | ||
909 | |||
910 | int main() { | ||
911 | |||
912 | int tstproto(int arg1, char * arg2); | ||
913 | int tstconst(const int arg1, const char *arg2); | ||
914 | int tstvoidp(const int arg1, const void *arg2); | ||
915 | ; return 0; } | ||
916 | EOF | ||
917 | if { (eval echo configure:918: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then | ||
918 | rm -rf conftest* | ||
919 | asc_ansi_ok=yes | ||
920 | else | ||
921 | echo "configure: failed program was:" >&5 | ||
922 | cat conftest.$ac_ext >&5 | ||
923 | rm -rf conftest* | ||
924 | asc_ansi_ok=no | ||
925 | fi | ||
926 | rm -f conftest* | ||
927 | echo "$ac_t""$asc_ansi_ok" 1>&6 | ||
928 | fi | ||
929 | |||
930 | if test "$asc_ansi_ok" = no ; then | ||
931 | # Extract the first word of "c89", so it can be a program name with args. | ||
932 | set dummy c89; ac_word=$2 | ||
933 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | ||
934 | echo "configure:935: checking for $ac_word" >&5 | ||
935 | if eval "test \"`echo '$''{'ac_cv_prog_asc_cc1'+set}'`\" = set"; then | ||
936 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
937 | else | ||
938 | if test -n "$asc_cc1"; then | ||
939 | ac_cv_prog_asc_cc1="$asc_cc1" # Let the user override the test. | ||
940 | else | ||
941 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | ||
942 | ac_dummy="$PATH" | ||
943 | for ac_dir in $ac_dummy; do | ||
944 | test -z "$ac_dir" && ac_dir=. | ||
945 | if test -f $ac_dir/$ac_word; then | ||
946 | ac_cv_prog_asc_cc1="c89" | ||
947 | break | ||
948 | fi | ||
949 | done | ||
950 | IFS="$ac_save_ifs" | ||
951 | test -z "$ac_cv_prog_asc_cc1" && ac_cv_prog_asc_cc1="NONE" | ||
952 | fi | ||
953 | fi | ||
954 | asc_cc1="$ac_cv_prog_asc_cc1" | ||
955 | if test -n "$asc_cc1"; then | ||
956 | echo "$ac_t""$asc_cc1" 1>&6 | ||
957 | else | ||
958 | echo "$ac_t""no" 1>&6 | ||
959 | fi | ||
960 | |||
961 | if test ! "$asc_cc1" = NONE ; then | ||
962 | CC=$asc_cc1 | ||
963 | echo $ac_n "checking whether $CC understands const, void*, and function prototypes""... $ac_c" 1>&6 | ||
964 | echo "configure:965: checking whether $CC understands const, void*, and function prototypes" >&5 | ||
965 | cat > conftest.$ac_ext <<EOF | ||
966 | #line 967 "configure" | ||
967 | #include "confdefs.h" | ||
968 | |||
969 | int main() { | ||
970 | |||
971 | int tstproto(int arg1, char * arg2); | ||
972 | int tstconst(const int arg1, const char *arg2); | ||
973 | int tstvoidp(const int arg1, const void *arg2); | ||
974 | ; return 0; } | ||
975 | EOF | ||
976 | if { (eval echo configure:977: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then | ||
977 | rm -rf conftest* | ||
978 | asc_ansi_ok=yes | ||
979 | else | ||
980 | echo "configure: failed program was:" >&5 | ||
981 | cat conftest.$ac_ext >&5 | ||
982 | rm -rf conftest* | ||
983 | asc_ansi_ok=no | ||
984 | fi | ||
985 | rm -f conftest* | ||
986 | echo "$ac_t""$asc_ansi_ok" 1>&6 | ||
987 | fi | ||
988 | fi | ||
989 | |||
990 | if test "$asc_ansi_ok" = no ; then | ||
991 | # Extract the first word of "xlc", so it can be a program name with args. | ||
992 | set dummy xlc; ac_word=$2 | ||
993 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | ||
994 | echo "configure:995: checking for $ac_word" >&5 | ||
995 | if eval "test \"`echo '$''{'ac_cv_prog_asc_cc2'+set}'`\" = set"; then | ||
996 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
997 | else | ||
998 | if test -n "$asc_cc2"; then | ||
999 | ac_cv_prog_asc_cc2="$asc_cc2" # Let the user override the test. | ||
1000 | else | ||
1001 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | ||
1002 | ac_dummy="$PATH" | ||
1003 | for ac_dir in $ac_dummy; do | ||
1004 | test -z "$ac_dir" && ac_dir=. | ||
1005 | if test -f $ac_dir/$ac_word; then | ||
1006 | ac_cv_prog_asc_cc2="xlc" | ||
1007 | break | ||
1008 | fi | ||
1009 | done | ||
1010 | IFS="$ac_save_ifs" | ||
1011 | test -z "$ac_cv_prog_asc_cc2" && ac_cv_prog_asc_cc2="NONE" | ||
1012 | fi | ||
1013 | fi | ||
1014 | asc_cc2="$ac_cv_prog_asc_cc2" | ||
1015 | if test -n "$asc_cc2"; then | ||
1016 | echo "$ac_t""$asc_cc2" 1>&6 | ||
1017 | else | ||
1018 | echo "$ac_t""no" 1>&6 | ||
1019 | fi | ||
1020 | |||
1021 | if test ! "$asc_cc2" = NONE ; then | ||
1022 | CC=$asc_cc2 | ||
1023 | echo $ac_n "checking whether $CC understands const, void*, and function prototypes""... $ac_c" 1>&6 | ||
1024 | echo "configure:1025: checking whether $CC understands const, void*, and function prototypes" >&5 | ||
1025 | cat > conftest.$ac_ext <<EOF | ||
1026 | #line 1027 "configure" | ||
1027 | #include "confdefs.h" | ||
1028 | |||
1029 | int main() { | ||
1030 | |||
1031 | int tstproto(int arg1, char * arg2); | ||
1032 | int tstconst(const int arg1, const char *arg2); | ||
1033 | int tstvoidp(const int arg1, const void *arg2); | ||
1034 | ; return 0; } | ||
1035 | EOF | ||
1036 | if { (eval echo configure:1037: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then | ||
1037 | rm -rf conftest* | ||
1038 | asc_ansi_ok=yes | ||
1039 | else | ||
1040 | echo "configure: failed program was:" >&5 | ||
1041 | cat conftest.$ac_ext >&5 | ||
1042 | rm -rf conftest* | ||
1043 | asc_ansi_ok=no | ||
1044 | fi | ||
1045 | rm -f conftest* | ||
1046 | echo "$ac_t""$asc_ansi_ok" 1>&6 | ||
1047 | fi | ||
1048 | fi | ||
1049 | |||
1050 | if test "$asc_ansi_ok" = no ; then | ||
1051 | # Extract the first word of "acc", so it can be a program name with args. | ||
1052 | set dummy acc; ac_word=$2 | ||
1053 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | ||
1054 | echo "configure:1055: checking for $ac_word" >&5 | ||
1055 | if eval "test \"`echo '$''{'ac_cv_prog_asc_cc3'+set}'`\" = set"; then | ||
1056 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
1057 | else | ||
1058 | if test -n "$asc_cc3"; then | ||
1059 | ac_cv_prog_asc_cc3="$asc_cc3" # Let the user override the test. | ||
1060 | else | ||
1061 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | ||
1062 | ac_dummy="$PATH" | ||
1063 | for ac_dir in $ac_dummy; do | ||
1064 | test -z "$ac_dir" && ac_dir=. | ||
1065 | if test -f $ac_dir/$ac_word; then | ||
1066 | ac_cv_prog_asc_cc3="acc" | ||
1067 | break | ||
1068 | fi | ||
1069 | done | ||
1070 | IFS="$ac_save_ifs" | ||
1071 | test -z "$ac_cv_prog_asc_cc3" && ac_cv_prog_asc_cc3="NONE" | ||
1072 | fi | ||
1073 | fi | ||
1074 | asc_cc3="$ac_cv_prog_asc_cc3" | ||
1075 | if test -n "$asc_cc3"; then | ||
1076 | echo "$ac_t""$asc_cc3" 1>&6 | ||
1077 | else | ||
1078 | echo "$ac_t""no" 1>&6 | ||
1079 | fi | ||
1080 | |||
1081 | if test ! "$asc_cc3" = NONE ; then | ||
1082 | CC=$asc_cc3 | ||
1083 | echo $ac_n "checking whether $CC understands const, void*, and function prototypes""... $ac_c" 1>&6 | ||
1084 | echo "configure:1085: checking whether $CC understands const, void*, and function prototypes" >&5 | ||
1085 | cat > conftest.$ac_ext <<EOF | ||
1086 | #line 1087 "configure" | ||
1087 | #include "confdefs.h" | ||
1088 | |||
1089 | int main() { | ||
1090 | |||
1091 | int tstproto(int arg1, char * arg2); | ||
1092 | int tstconst(const int arg1, const char *arg2); | ||
1093 | int tstvoidp(const int arg1, const void *arg2); | ||
1094 | ; return 0; } | ||
1095 | EOF | ||
1096 | if { (eval echo configure:1097: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then | ||
1097 | rm -rf conftest* | ||
1098 | asc_ansi_ok=yes | ||
1099 | else | ||
1100 | echo "configure: failed program was:" >&5 | ||
1101 | cat conftest.$ac_ext >&5 | ||
1102 | rm -rf conftest* | ||
1103 | asc_ansi_ok=no | ||
1104 | fi | ||
1105 | rm -f conftest* | ||
1106 | echo "$ac_t""$asc_ansi_ok" 1>&6 | ||
1107 | fi | ||
1108 | fi | ||
1109 | |||
1110 | # Extract the first word of "gcc", so it can be a program name with args. | ||
1111 | set dummy gcc; ac_word=$2 | ||
1112 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | ||
1113 | echo "configure:1114: checking for $ac_word" >&5 | ||
1114 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then | ||
1115 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
1116 | else | ||
1117 | if test -n "$CC"; then | ||
1118 | ac_cv_prog_CC="$CC" # Let the user override the test. | ||
1119 | else | ||
1120 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | ||
1121 | ac_dummy="$PATH" | ||
1122 | for ac_dir in $ac_dummy; do | ||
1123 | test -z "$ac_dir" && ac_dir=. | ||
1124 | if test -f $ac_dir/$ac_word; then | ||
1125 | ac_cv_prog_CC="gcc" | ||
1126 | break | ||
1127 | fi | ||
1128 | done | ||
1129 | IFS="$ac_save_ifs" | ||
1130 | fi | ||
1131 | fi | ||
1132 | CC="$ac_cv_prog_CC" | ||
1133 | if test -n "$CC"; then | ||
1134 | echo "$ac_t""$CC" 1>&6 | ||
1135 | else | ||
1136 | echo "$ac_t""no" 1>&6 | ||
1137 | fi | ||
1138 | |||
1139 | if test -z "$CC"; then | ||
1140 | # Extract the first word of "cc", so it can be a program name with args. | ||
1141 | set dummy cc; ac_word=$2 | ||
1142 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | ||
1143 | echo "configure:1144: checking for $ac_word" >&5 | ||
1144 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then | ||
1145 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
1146 | else | ||
1147 | if test -n "$CC"; then | ||
1148 | ac_cv_prog_CC="$CC" # Let the user override the test. | ||
1149 | else | ||
1150 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | ||
1151 | ac_prog_rejected=no | ||
1152 | ac_dummy="$PATH" | ||
1153 | for ac_dir in $ac_dummy; do | ||
1154 | test -z "$ac_dir" && ac_dir=. | ||
1155 | if test -f $ac_dir/$ac_word; then | ||
1156 | if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then | ||
1157 | ac_prog_rejected=yes | ||
1158 | continue | ||
1159 | fi | ||
1160 | ac_cv_prog_CC="cc" | ||
1161 | break | ||
1162 | fi | ||
1163 | done | ||
1164 | IFS="$ac_save_ifs" | ||
1165 | if test $ac_prog_rejected = yes; then | ||
1166 | # We found a bogon in the path, so make sure we never use it. | ||
1167 | set dummy $ac_cv_prog_CC | ||
1168 | shift | ||
1169 | if test $# -gt 0; then | ||
1170 | # We chose a different compiler from the bogus one. | ||
1171 | # However, it has the same basename, so the bogon will be chosen | ||
1172 | # first if we set CC to just the basename; use the full file name. | ||
1173 | shift | ||
1174 | set dummy "$ac_dir/$ac_word" "$@" | ||
1175 | shift | ||
1176 | ac_cv_prog_CC="$@" | ||
1177 | fi | ||
1178 | fi | ||
1179 | fi | ||
1180 | fi | ||
1181 | CC="$ac_cv_prog_CC" | ||
1182 | if test -n "$CC"; then | ||
1183 | echo "$ac_t""$CC" 1>&6 | ||
1184 | else | ||
1185 | echo "$ac_t""no" 1>&6 | ||
1186 | fi | ||
1187 | |||
1188 | if test -z "$CC"; then | ||
1189 | case "`uname -s`" in | ||
1190 | *win32* | *WIN32*) | ||
1191 | # Extract the first word of "cl", so it can be a program name with args. | ||
1192 | set dummy cl; ac_word=$2 | ||
1193 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | ||
1194 | echo "configure:1195: checking for $ac_word" >&5 | ||
1195 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then | ||
1196 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
1197 | else | ||
1198 | if test -n "$CC"; then | ||
1199 | ac_cv_prog_CC="$CC" # Let the user override the test. | ||
1200 | else | ||
1201 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | ||
1202 | ac_dummy="$PATH" | ||
1203 | for ac_dir in $ac_dummy; do | ||
1204 | test -z "$ac_dir" && ac_dir=. | ||
1205 | if test -f $ac_dir/$ac_word; then | ||
1206 | ac_cv_prog_CC="cl" | ||
1207 | break | ||
1208 | fi | ||
1209 | done | ||
1210 | IFS="$ac_save_ifs" | ||
1211 | fi | ||
1212 | fi | ||
1213 | CC="$ac_cv_prog_CC" | ||
1214 | if test -n "$CC"; then | ||
1215 | echo "$ac_t""$CC" 1>&6 | ||
1216 | else | ||
1217 | echo "$ac_t""no" 1>&6 | ||
1218 | fi | ||
1219 | ;; | ||
1220 | esac | ||
1221 | fi | ||
1222 | test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; } | ||
1223 | fi | ||
1224 | |||
1225 | echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 | ||
1226 | echo "configure:1227: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 | ||
1227 | |||
1228 | ac_ext=c | ||
1229 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. | ||
1230 | ac_cpp='$CPP $CPPFLAGS' | ||
1231 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' | ||
1232 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' | ||
1233 | cross_compiling=$ac_cv_prog_cc_cross | ||
1234 | |||
1235 | cat > conftest.$ac_ext << EOF | ||
1236 | |||
1237 | #line 1238 "configure" | ||
1238 | #include "confdefs.h" | ||
1239 | |||
1240 | main(){return(0);} | ||
1241 | EOF | ||
1242 | if { (eval echo configure:1243: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | ||
1243 | ac_cv_prog_cc_works=yes | ||
1244 | # If we can't run a trivial program, we are probably using a cross compiler. | ||
1245 | if (./conftest; exit) 2>/dev/null; then | ||
1246 | ac_cv_prog_cc_cross=no | ||
1247 | else | ||
1248 | ac_cv_prog_cc_cross=yes | ||
1249 | fi | ||
1250 | else | ||
1251 | echo "configure: failed program was:" >&5 | ||
1252 | cat conftest.$ac_ext >&5 | ||
1253 | ac_cv_prog_cc_works=no | ||
1254 | fi | ||
1255 | rm -fr conftest* | ||
1256 | ac_ext=c | ||
1257 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. | ||
1258 | ac_cpp='$CPP $CPPFLAGS' | ||
1259 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' | ||
1260 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' | ||
1261 | cross_compiling=$ac_cv_prog_cc_cross | ||
1262 | |||
1263 | echo "$ac_t""$ac_cv_prog_cc_works" 1>&6 | ||
1264 | if test $ac_cv_prog_cc_works = no; then | ||
1265 | { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; } | ||
1266 | fi | ||
1267 | echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 | ||
1268 | echo "configure:1269: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 | ||
1269 | echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6 | ||
1270 | cross_compiling=$ac_cv_prog_cc_cross | ||
1271 | |||
1272 | echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6 | ||
1273 | echo "configure:1274: checking whether we are using GNU C" >&5 | ||
1274 | if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then | ||
1275 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
1276 | else | ||
1277 | cat > conftest.c <<EOF | ||
1278 | #ifdef __GNUC__ | ||
1279 | yes; | ||
1280 | #endif | ||
1281 | EOF | ||
1282 | if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1283: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then | ||
1283 | ac_cv_prog_gcc=yes | ||
1284 | else | ||
1285 | ac_cv_prog_gcc=no | ||
1286 | fi | ||
1287 | fi | ||
1288 | |||
1289 | echo "$ac_t""$ac_cv_prog_gcc" 1>&6 | ||
1290 | |||
1291 | if test $ac_cv_prog_gcc = yes; then | ||
1292 | GCC=yes | ||
1293 | else | ||
1294 | GCC= | ||
1295 | fi | ||
1296 | |||
1297 | ac_test_CFLAGS="${CFLAGS+set}" | ||
1298 | ac_save_CFLAGS="$CFLAGS" | ||
1299 | CFLAGS= | ||
1300 | echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 | ||
1301 | echo "configure:1302: checking whether ${CC-cc} accepts -g" >&5 | ||
1302 | if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then | ||
1303 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
1304 | else | ||
1305 | echo 'void f(){}' > conftest.c | ||
1306 | if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then | ||
1307 | ac_cv_prog_cc_g=yes | ||
1308 | else | ||
1309 | ac_cv_prog_cc_g=no | ||
1310 | fi | ||
1311 | rm -f conftest* | ||
1312 | |||
1313 | fi | ||
1314 | |||
1315 | echo "$ac_t""$ac_cv_prog_cc_g" 1>&6 | ||
1316 | if test "$ac_test_CFLAGS" = set; then | ||
1317 | CFLAGS="$ac_save_CFLAGS" | ||
1318 | elif test $ac_cv_prog_cc_g = yes; then | ||
1319 | if test "$GCC" = yes; then | ||
1320 | CFLAGS="-g -O2" | ||
1321 | else | ||
1322 | CFLAGS="-g" | ||
1323 | fi | ||
1324 | else | ||
1325 | if test "$GCC" = yes; then | ||
1326 | CFLAGS="-O2" | ||
1327 | else | ||
1328 | CFLAGS= | ||
1329 | fi | ||
1330 | fi | ||
1331 | |||
1332 | |||
1333 | if test "$asc_ansi_ok" = no ; then | ||
1334 | CC=$asc_orig_cc | ||
1335 | { echo "configure: error: Cannot find an ANSI C compiler. ASCEND will not build | ||
1336 | without an ANSI compiler. If you have an ANSI compiler which | ||
1337 | configure is not finding, set the CC environment variable to | ||
1338 | the full path fo the compiler and rerun configure." 1>&2; exit 1; } | ||
1339 | fi | ||
1340 | |||
1341 | |||
1342 | #-------------------------------------------------------------------- | ||
1343 | # Do other misc checks with CC and CFLAGS. | ||
1344 | # | ||
1345 | # Determine how to run the C preprocessor. | ||
1346 | # | ||
1347 | # If the user specifies --enable-optimization, remove `-g' | ||
1348 | # from CFLAGS, add `-O' to CFLAGS, and define `NDEBUG'. If | ||
1349 | # we are not building optimized, check for special libraries | ||
1350 | # needed for building a debugging binary (currenly only | ||
1351 | # /usr/lib/end.o under HPUX). | ||
1352 | # | ||
1353 | # Check if we're running on AIX; if so, add `-D_ALL_SOURCE' | ||
1354 | # to CFLAGS. | ||
1355 | # | ||
1356 | # Check if we're running on HPUX; if so, add -D_HPUX_SOURCE' | ||
1357 | # to CFLAGS unless the C preprocessor goes it for us. | ||
1358 | #-------------------------------------------------------------------- | ||
1359 | |||
1360 | echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6 | ||
1361 | echo "configure:1362: checking how to run the C preprocessor" >&5 | ||
1362 | # On Suns, sometimes $CPP names a directory. | ||
1363 | if test -n "$CPP" && test -d "$CPP"; then | ||
1364 | CPP= | ||
1365 | fi | ||
1366 | if test -z "$CPP"; then | ||
1367 | if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then | ||
1368 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
1369 | else | ||
1370 | # This must be in double quotes, not single quotes, because CPP may get | ||
1371 | # substituted into the Makefile and "${CC-cc}" will confuse make. | ||
1372 | CPP="${CC-cc} -E" | ||
1373 | # On the NeXT, cc -E runs the code through the compiler's parser, | ||
1374 | # not just through cpp. | ||
1375 | cat > conftest.$ac_ext <<EOF | ||
1376 | #line 1377 "configure" | ||
1377 | #include "confdefs.h" | ||
1378 | #include <assert.h> | ||
1379 | Syntax Error | ||
1380 | EOF | ||
1381 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | ||
1382 | { (eval echo configure:1383: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } | ||
1383 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` | ||
1384 | if test -z "$ac_err"; then | ||
1385 | : | ||
1386 | else | ||
1387 | echo "$ac_err" >&5 | ||
1388 | echo "configure: failed program was:" >&5 | ||
1389 | cat conftest.$ac_ext >&5 | ||
1390 | rm -rf conftest* | ||
1391 | CPP="${CC-cc} -E -traditional-cpp" | ||
1392 | cat > conftest.$ac_ext <<EOF | ||
1393 | #line 1394 "configure" | ||
1394 | #include "confdefs.h" | ||
1395 | #include <assert.h> | ||
1396 | Syntax Error | ||
1397 | EOF | ||
1398 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | ||
1399 | { (eval echo configure:1400: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } | ||
1400 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` | ||
1401 | if test -z "$ac_err"; then | ||
1402 | : | ||
1403 | else | ||
1404 | echo "$ac_err" >&5 | ||
1405 | echo "configure: failed program was:" >&5 | ||
1406 | cat conftest.$ac_ext >&5 | ||
1407 | rm -rf conftest* | ||
1408 | CPP="${CC-cc} -nologo -E" | ||
1409 | cat > conftest.$ac_ext <<EOF | ||
1410 | #line 1411 "configure" | ||
1411 | #include "confdefs.h" | ||
1412 | #include <assert.h> | ||
1413 | Syntax Error | ||
1414 | EOF | ||
1415 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | ||
1416 | { (eval echo configure:1417: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } | ||
1417 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` | ||
1418 | if test -z "$ac_err"; then | ||
1419 | : | ||
1420 | else | ||
1421 | echo "$ac_err" >&5 | ||
1422 | echo "configure: failed program was:" >&5 | ||
1423 | cat conftest.$ac_ext >&5 | ||
1424 | rm -rf conftest* | ||
1425 | CPP=/lib/cpp | ||
1426 | fi | ||
1427 | rm -f conftest* | ||
1428 | fi | ||
1429 | rm -f conftest* | ||
1430 | fi | ||
1431 | rm -f conftest* | ||
1432 | ac_cv_prog_CPP="$CPP" | ||
1433 | fi | ||
1434 | CPP="$ac_cv_prog_CPP" | ||
1435 | else | ||
1436 | ac_cv_prog_CPP="$CPP" | ||
1437 | fi | ||
1438 | echo "$ac_t""$CPP" 1>&6 | ||
1439 | |||
1440 | |||
1441 | # Check whether --enable-optimization or --disable-optimization was given. | ||
1442 | if test "${enable_optimization+set}" = set; then | ||
1443 | enableval="$enable_optimization" | ||
1444 | asc_do_opt="$enableval" | ||
1445 | else | ||
1446 | asc_do_opt=no | ||
1447 | fi | ||
1448 | |||
1449 | if test "$asc_do_opt" = yes; then | ||
1450 | CFLAGS=`echo "-O $CFLAGS " | sed 's/ -g / /g'` | ||
1451 | cat >> confdefs.h <<\EOF | ||
1452 | #define NDEBUG 1 | ||
1453 | EOF | ||
1454 | |||
1455 | else | ||
1456 | # Extract the first word of "end.o", so it can be a program name with args. | ||
1457 | set dummy end.o; ac_word=$2 | ||
1458 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | ||
1459 | echo "configure:1460: checking for $ac_word" >&5 | ||
1460 | if eval "test \"`echo '$''{'ac_cv_path_DEBUG_LIBS'+set}'`\" = set"; then | ||
1461 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
1462 | else | ||
1463 | case "$DEBUG_LIBS" in | ||
1464 | /*) | ||
1465 | ac_cv_path_DEBUG_LIBS="$DEBUG_LIBS" # Let the user override the test with a path. | ||
1466 | ;; | ||
1467 | ?:/*) | ||
1468 | ac_cv_path_DEBUG_LIBS="$DEBUG_LIBS" # Let the user override the test with a dos path. | ||
1469 | ;; | ||
1470 | *) | ||
1471 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | ||
1472 | ac_dummy="/usr/lib" | ||
1473 | for ac_dir in $ac_dummy; do | ||
1474 | test -z "$ac_dir" && ac_dir=. | ||
1475 | if test -f $ac_dir/$ac_word; then | ||
1476 | ac_cv_path_DEBUG_LIBS="$ac_dir/$ac_word" | ||
1477 | break | ||
1478 | fi | ||
1479 | done | ||
1480 | IFS="$ac_save_ifs" | ||
1481 | ;; | ||
1482 | esac | ||
1483 | fi | ||
1484 | DEBUG_LIBS="$ac_cv_path_DEBUG_LIBS" | ||
1485 | if test -n "$DEBUG_LIBS"; then | ||
1486 | echo "$ac_t""$DEBUG_LIBS" 1>&6 | ||
1487 | else | ||
1488 | echo "$ac_t""no" 1>&6 | ||
1489 | fi | ||
1490 | |||
1491 | fi | ||
1492 | |||
1493 | echo $ac_n "checking for AIX""... $ac_c" 1>&6 | ||
1494 | echo "configure:1495: checking for AIX" >&5 | ||
1495 | cat > conftest.$ac_ext <<EOF | ||
1496 | #line 1497 "configure" | ||
1497 | #include "confdefs.h" | ||
1498 | |||
1499 | #ifdef _AIX | ||
1500 | yes | ||
1501 | #endif | ||
1502 | |||
1503 | EOF | ||
1504 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | ||
1505 | egrep "yes" >/dev/null 2>&1; then | ||
1506 | rm -rf conftest* | ||
1507 | asc_aix=yes ; cat >> confdefs.h <<\EOF | ||
1508 | #define _ALL_SOURCE 1 | ||
1509 | EOF | ||
1510 | |||
1511 | else | ||
1512 | rm -rf conftest* | ||
1513 | asc_aix=no | ||
1514 | fi | ||
1515 | rm -f conftest* | ||
1516 | |||
1517 | echo "$ac_t""$asc_aix" 1>&6 | ||
1518 | |||
1519 | echo $ac_n "checking whether -D_HPUX_SOURCE is needed""... $ac_c" 1>&6 | ||
1520 | echo "configure:1521: checking whether -D_HPUX_SOURCE is needed" >&5 | ||
1521 | cat > conftest.$ac_ext <<EOF | ||
1522 | #line 1523 "configure" | ||
1523 | #include "confdefs.h" | ||
1524 | |||
1525 | #ifdef __hpux | ||
1526 | #ifndef _HPUX_SOURCE | ||
1527 | yes | ||
1528 | #endif | ||
1529 | #endif | ||
1530 | |||
1531 | EOF | ||
1532 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | ||
1533 | egrep "yes" >/dev/null 2>&1; then | ||
1534 | rm -rf conftest* | ||
1535 | asc_hpux=yes ; cat >> confdefs.h <<\EOF | ||
1536 | #define _HPUX_SOURCE 1 | ||
1537 | EOF | ||
1538 | |||
1539 | else | ||
1540 | rm -rf conftest* | ||
1541 | asc_hpux=no | ||
1542 | fi | ||
1543 | rm -f conftest* | ||
1544 | |||
1545 | echo "$ac_t""$asc_hpux" 1>&6 | ||
1546 | |||
1547 | # Check the size of pointers; if cross compiling, assume 32 bit pointers | ||
1548 | echo $ac_n "checking size of void *""... $ac_c" 1>&6 | ||
1549 | echo "configure:1550: checking size of void *" >&5 | ||
1550 | if eval "test \"`echo '$''{'ac_cv_sizeof_void_p'+set}'`\" = set"; then | ||
1551 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
1552 | else | ||
1553 | if test "$cross_compiling" = yes; then | ||
1554 | ac_cv_sizeof_void_p=4 | ||
1555 | else | ||
1556 | cat > conftest.$ac_ext <<EOF | ||
1557 | #line 1558 "configure" | ||
1558 | #include "confdefs.h" | ||
1559 | #include <stdio.h> | ||
1560 | int main() | ||
1561 | { | ||
1562 | FILE *f=fopen("conftestval", "w"); | ||
1563 | if (!f) return(1); | ||
1564 | fprintf(f, "%d\n", sizeof(void *)); | ||
1565 | return(0); | ||
1566 | } | ||
1567 | EOF | ||
1568 | if { (eval echo configure:1569: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null | ||
1569 | then | ||
1570 | ac_cv_sizeof_void_p=`cat conftestval` | ||
1571 | else | ||
1572 | echo "configure: failed program was:" >&5 | ||
1573 | cat conftest.$ac_ext >&5 | ||
1574 | rm -fr conftest* | ||
1575 | ac_cv_sizeof_void_p=0 | ||
1576 | fi | ||
1577 | rm -fr conftest* | ||
1578 | fi | ||
1579 | |||
1580 | fi | ||
1581 | echo "$ac_t""$ac_cv_sizeof_void_p" 1>&6 | ||
1582 | cat >> confdefs.h <<EOF | ||
1583 | #define SIZEOF_VOID_P $ac_cv_sizeof_void_p | ||
1584 | EOF | ||
1585 | |||
1586 | |||
1587 | |||
1588 | |||
1589 | #-------------------------------------------------------------------- | ||
1590 | # Set YACC. | ||
1591 | # See if we can find `yacc' ourselves; if not, call the | ||
1592 | # autoconf macro which looks for `bison' and then for `yacc' | ||
1593 | #-------------------------------------------------------------------- | ||
1594 | asc_found_yacc=0 | ||
1595 | # Extract the first word of "yacc", so it can be a program name with args. | ||
1596 | set dummy yacc; ac_word=$2 | ||
1597 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | ||
1598 | echo "configure:1599: checking for $ac_word" >&5 | ||
1599 | if eval "test \"`echo '$''{'ac_cv_prog_YACC'+set}'`\" = set"; then | ||
1600 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
1601 | else | ||
1602 | if test -n "$YACC"; then | ||
1603 | ac_cv_prog_YACC="$YACC" # Let the user override the test. | ||
1604 | else | ||
1605 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | ||
1606 | ac_dummy="$PATH" | ||
1607 | for ac_dir in $ac_dummy; do | ||
1608 | test -z "$ac_dir" && ac_dir=. | ||
1609 | if test -f $ac_dir/$ac_word; then | ||
1610 | ac_cv_prog_YACC="yacc" | ||
1611 | break | ||
1612 | fi | ||
1613 | done | ||
1614 | IFS="$ac_save_ifs" | ||
1615 | test -z "$ac_cv_prog_YACC" && ac_cv_prog_YACC="asc_found_yacc=no" | ||
1616 | fi | ||
1617 | fi | ||
1618 | YACC="$ac_cv_prog_YACC" | ||
1619 | if test -n "$YACC"; then | ||
1620 | echo "$ac_t""$YACC" 1>&6 | ||
1621 | else | ||
1622 | echo "$ac_t""no" 1>&6 | ||
1623 | fi | ||
1624 | |||
1625 | if test "$asc_found_yacc" = no ; then | ||
1626 | for ac_prog in 'bison -y' byacc | ||
1627 | do | ||
1628 | # Extract the first word of "$ac_prog", so it can be a program name with args. | ||
1629 | set dummy $ac_prog; ac_word=$2 | ||
1630 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | ||
1631 | echo "configure:1632: checking for $ac_word" >&5 | ||
1632 | if eval "test \"`echo '$''{'ac_cv_prog_YACC'+set}'`\" = set"; then | ||
1633 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
1634 | else | ||
1635 | if test -n "$YACC"; then | ||
1636 | ac_cv_prog_YACC="$YACC" # Let the user override the test. | ||
1637 | else | ||
1638 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | ||
1639 | ac_dummy="$PATH" | ||
1640 | for ac_dir in $ac_dummy; do | ||
1641 | test -z "$ac_dir" && ac_dir=. | ||
1642 | if test -f $ac_dir/$ac_word; then | ||
1643 | ac_cv_prog_YACC="$ac_prog" | ||
1644 | break | ||
1645 | fi | ||
1646 | done | ||
1647 | IFS="$ac_save_ifs" | ||
1648 | fi | ||
1649 | fi | ||
1650 | YACC="$ac_cv_prog_YACC" | ||
1651 | if test -n "$YACC"; then | ||
1652 | echo "$ac_t""$YACC" 1>&6 | ||
1653 | else | ||
1654 | echo "$ac_t""no" 1>&6 | ||
1655 | fi | ||
1656 | |||
1657 | test -n "$YACC" && break | ||
1658 | done | ||
1659 | test -n "$YACC" || YACC="yacc" | ||
1660 | |||
1661 | fi | ||
1662 | |||
1663 | |||
1664 | #-------------------------------------------------------------------- | ||
1665 | # Set LEX. | ||
1666 | # ASCEND requires a `flex' which understands -P (allows you to | ||
1667 | # specify a prefix other than `yy'). The -P flag was added at | ||
1668 | # the same time a -V (version) flag was added (version 2.4.1), | ||
1669 | # so if `flex' understands -V, it'll understand -P (checking | ||
1670 | # for -P directly requires a flex input file). | ||
1671 | # | ||
1672 | # 1. If `LEX' is not set, look for `flex' and set `LEX' to | ||
1673 | # `flex' if found. | ||
1674 | # 2. If `flex' was found, see if it understands -V. If so, | ||
1675 | # set `scanner_src' and `typer_src' to have `flex' generate | ||
1676 | # the C files from the flex input files | ||
1677 | # ascend4/compiler/scanner.l & ascend4/interface/typelex.l | ||
1678 | # We don't need to look for libfl.a since we define | ||
1679 | # yywrap() ourselves. | ||
1680 | # 3. If `flex' wasn't found or was found but isn't new enough: | ||
1681 | # a. Print a warning message | ||
1682 | # b. Set `scanner_src' and `typer_src' to use pre-generated | ||
1683 | # C files for the flex files mentioned in (2). | ||
1684 | # c. Set `LEX' to `lex' | ||
1685 | # d. Search for the lex library `libl.a' and set LEXLIB to | ||
1686 | # its location. | ||
1687 | #-------------------------------------------------------------------- | ||
1688 | # Extract the first word of "flex", so it can be a program name with args. | ||
1689 | set dummy flex; ac_word=$2 | ||
1690 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | ||
1691 | echo "configure:1692: checking for $ac_word" >&5 | ||
1692 | if eval "test \"`echo '$''{'ac_cv_prog_LEX'+set}'`\" = set"; then | ||
1693 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
1694 | else | ||
1695 | if test -n "$LEX"; then | ||
1696 | ac_cv_prog_LEX="$LEX" # Let the user override the test. | ||
1697 | else | ||
1698 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | ||
1699 | ac_dummy="$PATH" | ||
1700 | for ac_dir in $ac_dummy; do | ||
1701 | test -z "$ac_dir" && ac_dir=. | ||
1702 | if test -f $ac_dir/$ac_word; then | ||
1703 | ac_cv_prog_LEX="flex" | ||
1704 | break | ||
1705 | fi | ||
1706 | done | ||
1707 | IFS="$ac_save_ifs" | ||
1708 | fi | ||
1709 | fi | ||
1710 | LEX="$ac_cv_prog_LEX" | ||
1711 | if test -n "$LEX"; then | ||
1712 | echo "$ac_t""$LEX" 1>&6 | ||
1713 | else | ||
1714 | echo "$ac_t""no" 1>&6 | ||
1715 | fi | ||
1716 | |||
1717 | |||
1718 | if test -n "$LEX" ; then | ||
1719 | echo $ac_n "checking whether $LEX is at least version 2.4.1""... $ac_c" 1>&6 | ||
1720 | echo "configure:1721: checking whether $LEX is at least version 2.4.1" >&5 | ||
1721 | echo "$LEX -V" 1>&5 | ||
1722 | if $LEX -V 1>&5 2>&5 ; then | ||
1723 | echo "$ac_t""yes" 1>&6 | ||
1724 | scanner_src="scanner.c.from.flex" | ||
1725 | typer_src="typelex.c.from.flex" | ||
1726 | else | ||
1727 | echo "$ac_t""no" 1>&6 | ||
1728 | LEX='' | ||
1729 | fi | ||
1730 | fi | ||
1731 | |||
1732 | if test -z "$LEX" ; then | ||
1733 | echo "configure: warning: Cannot find a flex lexer version 2.4.1 or greater. | ||
1734 | Using pregenerated C files for ascend4/compiler/scanner.l | ||
1735 | and ascend4/interface/typelex.l. If you have flex 2.4.1 | ||
1736 | or newer, set the LEX environment variable to its location | ||
1737 | and run configure again." 1>&2 | ||
1738 | scanner_src="scanner.c.from.c" | ||
1739 | typer_src="typelex.c.from.c" | ||
1740 | |||
1741 | # let configure set LEX and LEXLIB even though we won't be using them | ||
1742 | # Extract the first word of "flex", so it can be a program name with args. | ||
1743 | set dummy flex; ac_word=$2 | ||
1744 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | ||
1745 | echo "configure:1746: checking for $ac_word" >&5 | ||
1746 | if eval "test \"`echo '$''{'ac_cv_prog_LEX'+set}'`\" = set"; then | ||
1747 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
1748 | else | ||
1749 | if test -n "$LEX"; then | ||
1750 | ac_cv_prog_LEX="$LEX" # Let the user override the test. | ||
1751 | else | ||
1752 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | ||
1753 | ac_dummy="$PATH" | ||
1754 | for ac_dir in $ac_dummy; do | ||
1755 | test -z "$ac_dir" && ac_dir=. | ||
1756 | if test -f $ac_dir/$ac_word; then | ||
1757 | ac_cv_prog_LEX="flex" | ||
1758 | break | ||
1759 | fi | ||
1760 | done | ||
1761 | IFS="$ac_save_ifs" | ||
1762 | test -z "$ac_cv_prog_LEX" && ac_cv_prog_LEX="lex" | ||
1763 | fi | ||
1764 | fi | ||
1765 | LEX="$ac_cv_prog_LEX" | ||
1766 | if test -n "$LEX"; then | ||
1767 | echo "$ac_t""$LEX" 1>&6 | ||
1768 | else | ||
1769 | echo "$ac_t""no" 1>&6 | ||
1770 | fi | ||
1771 | |||
1772 | if test -z "$LEXLIB" | ||
1773 | then | ||
1774 | case "$LEX" in | ||
1775 | flex*) ac_lib=fl ;; | ||
1776 | *) ac_lib=l ;; | ||
1777 | esac | ||
1778 | echo $ac_n "checking for yywrap in -l$ac_lib""... $ac_c" 1>&6 | ||
1779 | echo "configure:1780: checking for yywrap in -l$ac_lib" >&5 | ||
1780 | ac_lib_var=`echo $ac_lib'_'yywrap | sed 'y%./+-%__p_%'` | ||
1781 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then | ||
1782 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
1783 | else | ||
1784 | ac_save_LIBS="$LIBS" | ||
1785 | LIBS="-l$ac_lib $LIBS" | ||
1786 | cat > conftest.$ac_ext <<EOF | ||
1787 | #line 1788 "configure" | ||
1788 | #include "confdefs.h" | ||
1789 | /* Override any gcc2 internal prototype to avoid an error. */ | ||
1790 | /* We use char because int might match the return type of a gcc2 | ||
1791 | builtin and then its argument prototype would still apply. */ | ||
1792 | char yywrap(); | ||
1793 | |||
1794 | int main() { | ||
1795 | yywrap() | ||
1796 | ; return 0; } | ||
1797 | EOF | ||
1798 | if { (eval echo configure:1799: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | ||
1799 | rm -rf conftest* | ||
1800 | eval "ac_cv_lib_$ac_lib_var=yes" | ||
1801 | else | ||
1802 | echo "configure: failed program was:" >&5 | ||
1803 | cat conftest.$ac_ext >&5 | ||
1804 | rm -rf conftest* | ||
1805 | eval "ac_cv_lib_$ac_lib_var=no" | ||
1806 | fi | ||
1807 | rm -f conftest* | ||
1808 | LIBS="$ac_save_LIBS" | ||
1809 | |||
1810 | fi | ||
1811 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then | ||
1812 | echo "$ac_t""yes" 1>&6 | ||
1813 | LEXLIB="-l$ac_lib" | ||
1814 | else | ||
1815 | echo "$ac_t""no" 1>&6 | ||
1816 | fi | ||
1817 | |||
1818 | fi | ||
1819 | |||
1820 | fi | ||
1821 | |||
1822 | |||
1823 | #-------------------------------------------------------------------- | ||
1824 | # Math libraries. | ||
1825 | # On a few very rare systems, all of the libm.a stuff is | ||
1826 | # already in libc.a. Set compiler flags accordingly. | ||
1827 | # Also, Linux requires the "ieee" library for math to work | ||
1828 | # right (and it must appear before "-lm"). | ||
1829 | # | ||
1830 | # When building on HPUX with GCC, GCC cannot find `copysign' | ||
1831 | # because it lives in an odd place; see if we need to add | ||
1832 | # this odd place to MATH_LIBS. | ||
1833 | # | ||
1834 | # See if erf(), the error function, exists; if so, define | ||
1835 | # HAVE_ERF. | ||
1836 | #-------------------------------------------------------------------- | ||
1837 | echo $ac_n "checking for sin""... $ac_c" 1>&6 | ||
1838 | echo "configure:1839: checking for sin" >&5 | ||
1839 | if eval "test \"`echo '$''{'ac_cv_func_sin'+set}'`\" = set"; then | ||
1840 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
1841 | else | ||
1842 | cat > conftest.$ac_ext <<EOF | ||
1843 | #line 1844 "configure" | ||
1844 | #include "confdefs.h" | ||
1845 | /* System header to define __stub macros and hopefully few prototypes, | ||
1846 | which can conflict with char sin(); below. */ | ||
1847 | #include <assert.h> | ||
1848 | /* Override any gcc2 internal prototype to avoid an error. */ | ||
1849 | /* We use char because int might match the return type of a gcc2 | ||
1850 | builtin and then its argument prototype would still apply. */ | ||
1851 | char sin(); | ||
1852 | |||
1853 | int main() { | ||
1854 | |||
1855 | /* The GNU C library defines this for functions which it implements | ||
1856 | to always fail with ENOSYS. Some functions are actually named | ||
1857 | something starting with __ and the normal name is an alias. */ | ||
1858 | #if defined (__stub_sin) || defined (__stub___sin) | ||
1859 | choke me | ||
1860 | #else | ||
1861 | sin(); | ||
1862 | #endif | ||
1863 | |||
1864 | ; return 0; } | ||
1865 | EOF | ||
1866 | if { (eval echo configure:1867: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | ||
1867 | rm -rf conftest* | ||
1868 | eval "ac_cv_func_sin=yes" | ||
1869 | else | ||
1870 | echo "configure: failed program was:" >&5 | ||
1871 | cat conftest.$ac_ext >&5 | ||
1872 | rm -rf conftest* | ||
1873 | eval "ac_cv_func_sin=no" | ||
1874 | fi | ||
1875 | rm -f conftest* | ||
1876 | fi | ||
1877 | |||
1878 | if eval "test \"`echo '$ac_cv_func_'sin`\" = yes"; then | ||
1879 | echo "$ac_t""yes" 1>&6 | ||
1880 | MATH_LIBS="" | ||
1881 | else | ||
1882 | echo "$ac_t""no" 1>&6 | ||
1883 | MATH_LIBS="-lm" | ||
1884 | fi | ||
1885 | |||
1886 | |||
1887 | echo $ac_n "checking for printf in -lieee""... $ac_c" 1>&6 | ||
1888 | echo "configure:1889: checking for printf in -lieee" >&5 | ||
1889 | ac_lib_var=`echo ieee'_'printf | sed 'y%./+-%__p_%'` | ||
1890 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then | ||
1891 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
1892 | else | ||
1893 | ac_save_LIBS="$LIBS" | ||
1894 | LIBS="-lieee $LIBS" | ||
1895 | cat > conftest.$ac_ext <<EOF | ||
1896 | #line 1897 "configure" | ||
1897 | #include "confdefs.h" | ||
1898 | /* Override any gcc2 internal prototype to avoid an error. */ | ||
1899 | /* We use char because int might match the return type of a gcc2 | ||
1900 | builtin and then its argument prototype would still apply. */ | ||
1901 | char printf(); | ||
1902 | |||
1903 | int main() { | ||
1904 | printf() | ||
1905 | ; return 0; } | ||
1906 | EOF | ||
1907 | if { (eval echo configure:1908: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | ||
1908 | rm -rf conftest* | ||
1909 | eval "ac_cv_lib_$ac_lib_var=yes" | ||
1910 | else | ||
1911 | echo "configure: failed program was:" >&5 | ||
1912 | cat conftest.$ac_ext >&5 | ||
1913 | rm -rf conftest* | ||
1914 | eval "ac_cv_lib_$ac_lib_var=no" | ||
1915 | fi | ||
1916 | rm -f conftest* | ||
1917 | LIBS="$ac_save_LIBS" | ||
1918 | |||
1919 | fi | ||
1920 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then | ||
1921 | echo "$ac_t""yes" 1>&6 | ||
1922 | MATH_LIBS="-lieee $MATH_LIBS" | ||
1923 | else | ||
1924 | echo "$ac_t""no" 1>&6 | ||
1925 | fi | ||
1926 | |||
1927 | |||
1928 | if test -n "$MATH_LIBS" ; then | ||
1929 | echo $ac_n "checking for copysign in -lm""... $ac_c" 1>&6 | ||
1930 | echo "configure:1931: checking for copysign in -lm" >&5 | ||
1931 | ac_lib_var=`echo m'_'copysign | sed 'y%./+-%__p_%'` | ||
1932 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then | ||
1933 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
1934 | else | ||
1935 | ac_save_LIBS="$LIBS" | ||
1936 | LIBS="-lm $MATH_LIBS $LIBS" | ||
1937 | cat > conftest.$ac_ext <<EOF | ||
1938 | #line 1939 "configure" | ||
1939 | #include "confdefs.h" | ||
1940 | /* Override any gcc2 internal prototype to avoid an error. */ | ||
1941 | /* We use char because int might match the return type of a gcc2 | ||
1942 | builtin and then its argument prototype would still apply. */ | ||
1943 | char copysign(); | ||
1944 | |||
1945 | int main() { | ||
1946 | copysign() | ||
1947 | ; return 0; } | ||
1948 | EOF | ||
1949 | if { (eval echo configure:1950: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | ||
1950 | rm -rf conftest* | ||
1951 | eval "ac_cv_lib_$ac_lib_var=yes" | ||
1952 | else | ||
1953 | echo "configure: failed program was:" >&5 | ||
1954 | cat conftest.$ac_ext >&5 | ||
1955 | rm -rf conftest* | ||
1956 | eval "ac_cv_lib_$ac_lib_var=no" | ||
1957 | fi | ||
1958 | rm -f conftest* | ||
1959 | LIBS="$ac_save_LIBS" | ||
1960 | |||
1961 | fi | ||
1962 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then | ||
1963 | echo "$ac_t""yes" 1>&6 | ||
1964 | ac_tr_lib=HAVE_LIB`echo m | sed -e 's/[^a-zA-Z0-9_]/_/g' \ | ||
1965 | -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` | ||
1966 | cat >> confdefs.h <<EOF | ||
1967 | #define $ac_tr_lib 1 | ||
1968 | EOF | ||
1969 | |||
1970 | LIBS="-lm $LIBS" | ||
1971 | |||
1972 | else | ||
1973 | echo "$ac_t""no" 1>&6 | ||
1974 | echo $ac_n "checking for drem in -lm""... $ac_c" 1>&6 | ||
1975 | echo "configure:1976: checking for drem in -lm" >&5 | ||
1976 | ac_lib_var=`echo m'_'drem | sed 'y%./+-%__p_%'` | ||
1977 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then | ||
1978 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
1979 | else | ||
1980 | ac_save_LIBS="$LIBS" | ||
1981 | LIBS="-lm /lib/pa1.1/libM.a | ||
1982 | $LIBS" | ||
1983 | cat > conftest.$ac_ext <<EOF | ||
1984 | #line 1985 "configure" | ||
1985 | #include "confdefs.h" | ||
1986 | /* Override any gcc2 internal prototype to avoid an error. */ | ||
1987 | /* We use char because int might match the return type of a gcc2 | ||
1988 | builtin and then its argument prototype would still apply. */ | ||
1989 | char drem(); | ||
1990 | |||
1991 | int main() { | ||
1992 | drem() | ||
1993 | ; return 0; } | ||
1994 | EOF | ||
1995 | if { (eval echo configure:1996: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | ||
1996 | rm -rf conftest* | ||
1997 | eval "ac_cv_lib_$ac_lib_var=yes" | ||
1998 | else | ||
1999 | echo "configure: failed program was:" >&5 | ||
2000 | cat conftest.$ac_ext >&5 | ||
2001 | rm -rf conftest* | ||
2002 | eval "ac_cv_lib_$ac_lib_var=no" | ||
2003 | fi | ||
2004 | rm -f conftest* | ||
2005 | LIBS="$ac_save_LIBS" | ||
2006 | |||
2007 | fi | ||
2008 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then | ||
2009 | echo "$ac_t""yes" 1>&6 | ||
2010 | MATH_LIBS="$MATH_LIBS /lib/pa1.1/libM.a" | ||
2011 | |||
2012 | else | ||
2013 | echo "$ac_t""no" 1>&6 | ||
2014 | fi | ||
2015 | |||
2016 | fi | ||
2017 | |||
2018 | fi | ||
2019 | |||
2020 | # store the current list of libraries, add the math libraries to LIBS, | ||
2021 | # check for erf(), then reset the value of LIBS. | ||
2022 | asc_keep_LIBS="$LIBS" | ||
2023 | LIBS="$LIBS $MATH_LIBS" | ||
2024 | for ac_func in erf | ||
2025 | do | ||
2026 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | ||
2027 | echo "configure:2028: checking for $ac_func" >&5 | ||
2028 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then | ||
2029 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
2030 | else | ||
2031 | cat > conftest.$ac_ext <<EOF | ||
2032 | #line 2033 "configure" | ||
2033 | #include "confdefs.h" | ||
2034 | /* System header to define __stub macros and hopefully few prototypes, | ||
2035 | which can conflict with char $ac_func(); below. */ | ||
2036 | #include <assert.h> | ||
2037 | /* Override any gcc2 internal prototype to avoid an error. */ | ||
2038 | /* We use char because int might match the return type of a gcc2 | ||
2039 | builtin and then its argument prototype would still apply. */ | ||
2040 | char $ac_func(); | ||
2041 | |||
2042 | int main() { | ||
2043 | |||
2044 | /* The GNU C library defines this for functions which it implements | ||
2045 | to always fail with ENOSYS. Some functions are actually named | ||
2046 | something starting with __ and the normal name is an alias. */ | ||
2047 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | ||
2048 | choke me | ||
2049 | #else | ||
2050 | $ac_func(); | ||
2051 | #endif | ||
2052 | |||
2053 | ; return 0; } | ||
2054 | EOF | ||
2055 | if { (eval echo configure:2056: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | ||
2056 | rm -rf conftest* | ||
2057 | eval "ac_cv_func_$ac_func=yes" | ||
2058 | else | ||
2059 | echo "configure: failed program was:" >&5 | ||
2060 | cat conftest.$ac_ext >&5 | ||
2061 | rm -rf conftest* | ||
2062 | eval "ac_cv_func_$ac_func=no" | ||
2063 | fi | ||
2064 | rm -f conftest* | ||
2065 | fi | ||
2066 | |||
2067 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then | ||
2068 | echo "$ac_t""yes" 1>&6 | ||
2069 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | ||
2070 | cat >> confdefs.h <<EOF | ||
2071 | #define $ac_tr_func 1 | ||
2072 | EOF | ||
2073 | |||
2074 | else | ||
2075 | echo "$ac_t""no" 1>&6 | ||
2076 | fi | ||
2077 | done | ||
2078 | |||
2079 | LIBS="$asc_keep_LIBS" | ||
2080 | |||
2081 | |||
2082 | #-------------------------------------------------------------------- | ||
2083 | # Check for X11. | ||
2084 | # We'll use the simple autoconf builtin macro for finding | ||
2085 | # X11 until we find a reason not to. | ||
2086 | # | ||
2087 | # On Solaris and IRIX, add the path to the X library to the | ||
2088 | # run-time shared-library-search-path so the ASCEND binary | ||
2089 | # can find the X library without the user having to set | ||
2090 | # LD_LIBRARY_PATH | ||
2091 | #-------------------------------------------------------------------- | ||
2092 | # If we find X, set shell vars x_includes and x_libraries to the | ||
2093 | # paths, otherwise set no_x=yes. | ||
2094 | # Uses ac_ vars as temps to allow command line to override cache and checks. | ||
2095 | # --without-x overrides everything else, but does not touch the cache. | ||
2096 | echo $ac_n "checking for X""... $ac_c" 1>&6 | ||
2097 | echo "configure:2098: checking for X" >&5 | ||
2098 | |||
2099 | # Check whether --with-x or --without-x was given. | ||
2100 | if test "${with_x+set}" = set; then | ||
2101 | withval="$with_x" | ||
2102 | : | ||
2103 | fi | ||
2104 | |||
2105 | # $have_x is `yes', `no', `disabled', or empty when we do not yet know. | ||
2106 | if test "x$with_x" = xno; then | ||
2107 | # The user explicitly disabled X. | ||
2108 | have_x=disabled | ||
2109 | else | ||
2110 | if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then | ||
2111 | # Both variables are already set. | ||
2112 | have_x=yes | ||
2113 | else | ||
2114 | if eval "test \"`echo '$''{'ac_cv_have_x'+set}'`\" = set"; then | ||
2115 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
2116 | else | ||
2117 | # One or both of the vars are not set, and there is no cached value. | ||
2118 | ac_x_includes=NO ac_x_libraries=NO | ||
2119 | rm -fr conftestdir | ||
2120 | if mkdir conftestdir; then | ||
2121 | cd conftestdir | ||
2122 | # Make sure to not put "make" in the Imakefile rules, since we grep it out. | ||
2123 | cat > Imakefile <<'EOF' | ||
2124 | acfindx: | ||
2125 | @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"' | ||
2126 | EOF | ||
2127 | if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then | ||
2128 | # GNU make sometimes prints "make[1]: Entering...", which would confuse us. | ||
2129 | eval `${MAKE-make} acfindx 2>/dev/null | grep -v make` | ||
2130 | # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR. | ||
2131 | for ac_extension in a so sl; do | ||
2132 | if test ! -f $ac_im_usrlibdir/libX11.$ac_extension && | ||
2133 | test -f $ac_im_libdir/libX11.$ac_extension; then | ||
2134 | ac_im_usrlibdir=$ac_im_libdir; break | ||
2135 | fi | ||
2136 | done | ||
2137 | # Screen out bogus values from the imake configuration. They are | ||
2138 | # bogus both because they are the default anyway, and because | ||
2139 | # using them would break gcc on systems where it needs fixed includes. | ||
2140 | case "$ac_im_incroot" in | ||
2141 | /usr/include) ;; | ||
2142 | *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes="$ac_im_incroot" ;; | ||
2143 | esac | ||
2144 | case "$ac_im_usrlibdir" in | ||
2145 | /usr/lib | /lib) ;; | ||
2146 | *) test -d "$ac_im_usrlibdir" && ac_x_libraries="$ac_im_usrlibdir" ;; | ||
2147 | esac | ||
2148 | fi | ||
2149 | cd .. | ||
2150 | rm -fr conftestdir | ||
2151 | fi | ||
2152 | |||
2153 | if test "$ac_x_includes" = NO; then | ||
2154 | # Guess where to find include files, by looking for this one X11 .h file. | ||
2155 | test -z "$x_direct_test_include" && x_direct_test_include=X11/Intrinsic.h | ||
2156 | |||
2157 | # First, try using that file with no special directory specified. | ||
2158 | cat > conftest.$ac_ext <<EOF | ||
2159 | #line 2160 "configure" | ||
2160 | #include "confdefs.h" | ||
2161 | #include <$x_direct_test_include> | ||
2162 | EOF | ||
2163 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | ||
2164 | { (eval echo configure:2165: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } | ||
2165 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` | ||
2166 | if test -z "$ac_err"; then | ||
2167 | rm -rf conftest* | ||
2168 | # We can compile using X headers with no special include directory. | ||
2169 | ac_x_includes= | ||
2170 | else | ||
2171 | echo "$ac_err" >&5 | ||
2172 | echo "configure: failed program was:" >&5 | ||
2173 | cat conftest.$ac_ext >&5 | ||
2174 | rm -rf conftest* | ||
2175 | # Look for the header file in a standard set of common directories. | ||
2176 | # Check X11 before X11Rn because it is often a symlink to the current release. | ||
2177 | for ac_dir in \ | ||
2178 | /usr/X11/include \ | ||
2179 | /usr/X11R6/include \ | ||
2180 | /usr/X11R5/include \ | ||
2181 | /usr/X11R4/include \ | ||
2182 | \ | ||
2183 | /usr/include/X11 \ | ||
2184 | /usr/include/X11R6 \ | ||
2185 | /usr/include/X11R5 \ | ||
2186 | /usr/include/X11R4 \ | ||
2187 | \ | ||
2188 | /usr/local/X11/include \ | ||
2189 | /usr/local/X11R6/include \ | ||
2190 | /usr/local/X11R5/include \ | ||
2191 | /usr/local/X11R4/include \ | ||
2192 | \ | ||
2193 | /usr/local/include/X11 \ | ||
2194 | /usr/local/include/X11R6 \ | ||
2195 | /usr/local/include/X11R5 \ | ||
2196 | /usr/local/include/X11R4 \ | ||
2197 | \ | ||
2198 | /usr/X386/include \ | ||
2199 | /usr/x386/include \ | ||
2200 | /usr/XFree86/include/X11 \ | ||
2201 | \ | ||
2202 | /usr/include \ | ||
2203 | /usr/local/include \ | ||
2204 | /usr/unsupported/include \ | ||
2205 | /usr/athena/include \ | ||
2206 | /usr/local/x11r5/include \ | ||
2207 | /usr/lpp/Xamples/include \ | ||
2208 | \ | ||
2209 | /usr/openwin/include \ | ||
2210 | /usr/openwin/share/include \ | ||
2211 | ; \ | ||
2212 | do | ||
2213 | if test -r "$ac_dir/$x_direct_test_include"; then | ||
2214 | ac_x_includes=$ac_dir | ||
2215 | break | ||
2216 | fi | ||
2217 | done | ||
2218 | fi | ||
2219 | rm -f conftest* | ||
2220 | fi # $ac_x_includes = NO | ||
2221 | |||
2222 | if test "$ac_x_libraries" = NO; then | ||
2223 | # Check for the libraries. | ||
2224 | |||
2225 | test -z "$x_direct_test_library" && x_direct_test_library=Xt | ||
2226 | test -z "$x_direct_test_function" && x_direct_test_function=XtMalloc | ||
2227 | |||
2228 | # See if we find them without any special options. | ||
2229 | # Don't add to $LIBS permanently. | ||
2230 | ac_save_LIBS="$LIBS" | ||
2231 | LIBS="-l$x_direct_test_library $LIBS" | ||
2232 | cat > conftest.$ac_ext <<EOF | ||
2233 | #line 2234 "configure" | ||
2234 | #include "confdefs.h" | ||
2235 | |||
2236 | int main() { | ||
2237 | ${x_direct_test_function}() | ||
2238 | ; return 0; } | ||
2239 | EOF | ||
2240 | if { (eval echo configure:2241: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | ||
2241 | rm -rf conftest* | ||
2242 | LIBS="$ac_save_LIBS" | ||
2243 | # We can link X programs with no special library path. | ||
2244 | ac_x_libraries= | ||
2245 | else | ||
2246 | echo "configure: failed program was:" >&5 | ||
2247 | cat conftest.$ac_ext >&5 | ||
2248 | rm -rf conftest* | ||
2249 | LIBS="$ac_save_LIBS" | ||
2250 | # First see if replacing the include by lib works. | ||
2251 | # Check X11 before X11Rn because it is often a symlink to the current release. | ||
2252 | for ac_dir in `echo "$ac_x_includes" | sed s/include/lib/` \ | ||
2253 | /usr/X11/lib \ | ||
2254 | /usr/X11R6/lib \ | ||
2255 | /usr/X11R5/lib \ | ||
2256 | /usr/X11R4/lib \ | ||
2257 | \ | ||
2258 | /usr/lib/X11 \ | ||
2259 | /usr/lib/X11R6 \ | ||
2260 | /usr/lib/X11R5 \ | ||
2261 | /usr/lib/X11R4 \ | ||
2262 | \ | ||
2263 | /usr/local/X11/lib \ | ||
2264 | /usr/local/X11R6/lib \ | ||
2265 | /usr/local/X11R5/lib \ | ||
2266 | /usr/local/X11R4/lib \ | ||
2267 | \ | ||
2268 | /usr/local/lib/X11 \ | ||
2269 | /usr/local/lib/X11R6 \ | ||
2270 | /usr/local/lib/X11R5 \ | ||
2271 | /usr/local/lib/X11R4 \ | ||
2272 | \ | ||
2273 | /usr/X386/lib \ | ||
2274 | /usr/x386/lib \ | ||
2275 | /usr/XFree86/lib/X11 \ | ||
2276 | \ | ||
2277 | /usr/lib \ | ||
2278 | /usr/local/lib \ | ||
2279 | /usr/unsupported/lib \ | ||
2280 | /usr/athena/lib \ | ||
2281 | /usr/local/x11r5/lib \ | ||
2282 | /usr/lpp/Xamples/lib \ | ||
2283 | /lib/usr/lib/X11 \ | ||
2284 | \ | ||
2285 | /usr/openwin/lib \ | ||
2286 | /usr/openwin/share/lib \ | ||
2287 | ; \ | ||
2288 | do | ||
2289 | for ac_extension in a so sl; do | ||
2290 | if test -r $ac_dir/lib${x_direct_test_library}.$ac_extension; then | ||
2291 | ac_x_libraries=$ac_dir | ||
2292 | break 2 | ||
2293 | fi | ||
2294 | done | ||
2295 | done | ||
2296 | fi | ||
2297 | rm -f conftest* | ||
2298 | fi # $ac_x_libraries = NO | ||
2299 | |||
2300 | if test "$ac_x_includes" = NO || test "$ac_x_libraries" = NO; then | ||
2301 | # Didn't find X anywhere. Cache the known absence of X. | ||
2302 | ac_cv_have_x="have_x=no" | ||
2303 | else | ||
2304 | # Record where we found X for the cache. | ||
2305 | ac_cv_have_x="have_x=yes \ | ||
2306 | ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries" | ||
2307 | fi | ||
2308 | fi | ||
2309 | fi | ||
2310 | eval "$ac_cv_have_x" | ||
2311 | fi # $with_x != no | ||
2312 | |||
2313 | if test "$have_x" != yes; then | ||
2314 | echo "$ac_t""$have_x" 1>&6 | ||
2315 | no_x=yes | ||
2316 | else | ||
2317 | # If each of the values was on the command line, it overrides each guess. | ||
2318 | test "x$x_includes" = xNONE && x_includes=$ac_x_includes | ||
2319 | test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries | ||
2320 | # Update the cache value to reflect the command line values. | ||
2321 | ac_cv_have_x="have_x=yes \ | ||
2322 | ac_x_includes=$x_includes ac_x_libraries=$x_libraries" | ||
2323 | echo "$ac_t""libraries $x_libraries, headers $x_includes" 1>&6 | ||
2324 | fi | ||
2325 | |||
2326 | if test -n "$x_includes"; then | ||
2327 | X11_INCLUDES="-I$x_includes" | ||
2328 | fi | ||
2329 | if test -n "$x_libraries"; then | ||
2330 | X11_LIBRARIES="-L$x_libraries" | ||
2331 | case "$host" in | ||
2332 | sparc-sun-solaris*) | ||
2333 | X11_RUN_PATH="-R$x_libraries" | ||
2334 | ;; | ||
2335 | mips-sgi-irix*) | ||
2336 | X11_RUN_PATH="-rpath $x_libraries" | ||
2337 | ;; | ||
2338 | *) | ||
2339 | X11_RUN_PATH="" | ||
2340 | ;; | ||
2341 | esac | ||
2342 | fi | ||
2343 | |||
2344 | |||
2345 | #-------------------------------------------------------------------- | ||
2346 | # Check for the existence of various libraries. The order here | ||
2347 | # is important, so that then end up in the right order in the | ||
2348 | # command line generated by make. The -lsocket and -lnsl | ||
2349 | # libraries require a couple of special tricks: | ||
2350 | # 1. Use "connect" and "accept" to check for -lsocket, and | ||
2351 | # "gethostbyname" to check for -lnsl. | ||
2352 | # 2. Use each function name only once: can't redo a check | ||
2353 | # because autoconf caches the results of the last check | ||
2354 | # and won't redo it. | ||
2355 | # 3. Use -lnsl and -lsocket only if they supply procedures that | ||
2356 | # aren't already present in the normal libraries. This is | ||
2357 | # because IRIX 5.2 has libraries, but they aren't needed and | ||
2358 | # they're bogus: they goof up name resolution if used. | ||
2359 | # 4. On some SVR4 systems, can't use -lsocket without -lnsl | ||
2360 | # too. To get around this problem, check for both libraries | ||
2361 | # together if -lsocket doesn't work by itself. | ||
2362 | #-------------------------------------------------------------------- | ||
2363 | |||
2364 | asc_checkBoth=0 | ||
2365 | echo $ac_n "checking for connect""... $ac_c" 1>&6 | ||
2366 | echo "configure:2367: checking for connect" >&5 | ||
2367 | if eval "test \"`echo '$''{'ac_cv_func_connect'+set}'`\" = set"; then | ||
2368 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
2369 | else | ||
2370 | cat > conftest.$ac_ext <<EOF | ||
2371 | #line 2372 "configure" | ||
2372 | #include "confdefs.h" | ||
2373 | /* System header to define __stub macros and hopefully few prototypes, | ||
2374 | which can conflict with char connect(); below. */ | ||
2375 | #include <assert.h> | ||
2376 | /* Override any gcc2 internal prototype to avoid an error. */ | ||
2377 | /* We use char because int might match the return type of a gcc2 | ||
2378 | builtin and then its argument prototype would still apply. */ | ||
2379 | char connect(); | ||
2380 | |||
2381 | int main() { | ||
2382 | |||
2383 | /* The GNU C library defines this for functions which it implements | ||
2384 | to always fail with ENOSYS. Some functions are actually named | ||
2385 | something starting with __ and the normal name is an alias. */ | ||
2386 | #if defined (__stub_connect) || defined (__stub___connect) | ||
2387 | choke me | ||
2388 | #else | ||
2389 | connect(); | ||
2390 | #endif | ||
2391 | |||
2392 | ; return 0; } | ||
2393 | EOF | ||
2394 | if { (eval echo configure:2395: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | ||
2395 | rm -rf conftest* | ||
2396 | eval "ac_cv_func_connect=yes" | ||
2397 | else | ||
2398 | echo "configure: failed program was:" >&5 | ||
2399 | cat conftest.$ac_ext >&5 | ||
2400 | rm -rf conftest* | ||
2401 | eval "ac_cv_func_connect=no" | ||
2402 | fi | ||
2403 | rm -f conftest* | ||
2404 | fi | ||
2405 | |||
2406 | if eval "test \"`echo '$ac_cv_func_'connect`\" = yes"; then | ||
2407 | echo "$ac_t""yes" 1>&6 | ||
2408 | asc_checkSocket=0 | ||
2409 | else | ||
2410 | echo "$ac_t""no" 1>&6 | ||
2411 | asc_checkSocket=1 | ||
2412 | fi | ||
2413 | |||
2414 | if test "$asc_checkSocket" = 1; then | ||
2415 | echo $ac_n "checking for printf in -lsocket""... $ac_c" 1>&6 | ||
2416 | echo "configure:2417: checking for printf in -lsocket" >&5 | ||
2417 | ac_lib_var=`echo socket'_'printf | sed 'y%./+-%__p_%'` | ||
2418 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then | ||
2419 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
2420 | else | ||
2421 | ac_save_LIBS="$LIBS" | ||
2422 | LIBS="-lsocket $LIBS" | ||
2423 | cat > conftest.$ac_ext <<EOF | ||
2424 | #line 2425 "configure" | ||
2425 | #include "confdefs.h" | ||
2426 | /* Override any gcc2 internal prototype to avoid an error. */ | ||
2427 | /* We use char because int might match the return type of a gcc2 | ||
2428 | builtin and then its argument prototype would still apply. */ | ||
2429 | char printf(); | ||
2430 | |||
2431 | int main() { | ||
2432 | printf() | ||
2433 | ; return 0; } | ||
2434 | EOF | ||
2435 | if { (eval echo configure:2436: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | ||
2436 | rm -rf conftest* | ||
2437 | eval "ac_cv_lib_$ac_lib_var=yes" | ||
2438 | else | ||
2439 | echo "configure: failed program was:" >&5 | ||
2440 | cat conftest.$ac_ext >&5 | ||
2441 | rm -rf conftest* | ||
2442 | eval "ac_cv_lib_$ac_lib_var=no" | ||
2443 | fi | ||
2444 | rm -f conftest* | ||
2445 | LIBS="$ac_save_LIBS" | ||
2446 | |||
2447 | fi | ||
2448 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then | ||
2449 | echo "$ac_t""yes" 1>&6 | ||
2450 | X11_EXTRA_LIBS="-lsocket" | ||
2451 | else | ||
2452 | echo "$ac_t""no" 1>&6 | ||
2453 | asc_checkBoth=1 | ||
2454 | fi | ||
2455 | |||
2456 | fi | ||
2457 | if test "$asc_checkBoth" = 1; then | ||
2458 | asc_oldLibs=$LIBS | ||
2459 | X11_EXTRA_LIBS="-lsocket -lnsl" | ||
2460 | LIBS="$LIBS $X11_EXTRA_LIBS" | ||
2461 | echo $ac_n "checking for accept""... $ac_c" 1>&6 | ||
2462 | echo "configure:2463: checking for accept" >&5 | ||
2463 | if eval "test \"`echo '$''{'ac_cv_func_accept'+set}'`\" = set"; then | ||
2464 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
2465 | else | ||
2466 | cat > conftest.$ac_ext <<EOF | ||
2467 | #line 2468 "configure" | ||
2468 | #include "confdefs.h" | ||
2469 | /* System header to define __stub macros and hopefully few prototypes, | ||
2470 | which can conflict with char accept(); below. */ | ||
2471 | #include <assert.h> | ||
2472 | /* Override any gcc2 internal prototype to avoid an error. */ | ||
2473 | /* We use char because int might match the return type of a gcc2 | ||
2474 | builtin and then its argument prototype would still apply. */ | ||
2475 | char accept(); | ||
2476 | |||
2477 | int main() { | ||
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_accept) || defined (__stub___accept) | ||
2483 | choke me | ||
2484 | #else | ||
2485 | accept(); | ||
2486 | #endif | ||
2487 | |||
2488 | ; return 0; } | ||
2489 | EOF | ||
2490 | if { (eval echo configure:2491: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | ||
2491 | rm -rf conftest* | ||
2492 | eval "ac_cv_func_accept=yes" | ||
2493 | else | ||
2494 | echo "configure: failed program was:" >&5 | ||
2495 | cat conftest.$ac_ext >&5 | ||
2496 | rm -rf conftest* | ||
2497 | eval "ac_cv_func_accept=no" | ||
2498 | fi | ||
2499 | rm -f conftest* | ||
2500 | fi | ||
2501 | |||
2502 | if eval "test \"`echo '$ac_cv_func_'accept`\" = yes"; then | ||
2503 | echo "$ac_t""yes" 1>&6 | ||
2504 | asc_checkNsl=0 | ||
2505 | else | ||
2506 | echo "$ac_t""no" 1>&6 | ||
2507 | X11_EXTRA_LIBS="" | ||
2508 | fi | ||
2509 | |||
2510 | LIBS=$asc_oldLibs | ||
2511 | fi | ||
2512 | asc_oldLibs=$LIBS | ||
2513 | LIBS="$LIBS $X11_EXTRA_LIBS" | ||
2514 | echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6 | ||
2515 | echo "configure:2516: checking for gethostbyname" >&5 | ||
2516 | if eval "test \"`echo '$''{'ac_cv_func_gethostbyname'+set}'`\" = set"; then | ||
2517 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
2518 | else | ||
2519 | cat > conftest.$ac_ext <<EOF | ||
2520 | #line 2521 "configure" | ||
2521 | #include "confdefs.h" | ||
2522 | /* System header to define __stub macros and hopefully few prototypes, | ||
2523 | which can conflict with char gethostbyname(); below. */ | ||
2524 | #include <assert.h> | ||
2525 | /* Override any gcc2 internal prototype to avoid an error. */ | ||
2526 | /* We use char because int might match the return type of a gcc2 | ||
2527 | builtin and then its argument prototype would still apply. */ | ||
2528 | char gethostbyname(); | ||
2529 | |||
2530 | int main() { | ||
2531 | |||
2532 | /* The GNU C library defines this for functions which it implements | ||
2533 | to always fail with ENOSYS. Some functions are actually named | ||
2534 | something starting with __ and the normal name is an alias. */ | ||
2535 | #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname) | ||
2536 | choke me | ||
2537 | #else | ||
2538 | gethostbyname(); | ||
2539 | #endif | ||
2540 | |||
2541 | ; return 0; } | ||
2542 | EOF | ||
2543 | if { (eval echo configure:2544: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | ||
2544 | rm -rf conftest* | ||
2545 | eval "ac_cv_func_gethostbyname=yes" | ||
2546 | else | ||
2547 | echo "configure: failed program was:" >&5 | ||
2548 | cat conftest.$ac_ext >&5 | ||
2549 | rm -rf conftest* | ||
2550 | eval "ac_cv_func_gethostbyname=no" | ||
2551 | fi | ||
2552 | rm -f conftest* | ||
2553 | fi | ||
2554 | |||
2555 | if eval "test \"`echo '$ac_cv_func_'gethostbyname`\" = yes"; then | ||
2556 | echo "$ac_t""yes" 1>&6 | ||
2557 | : | ||
2558 | else | ||
2559 | echo "$ac_t""no" 1>&6 | ||
2560 | echo $ac_n "checking for printf in -lnsl""... $ac_c" 1>&6 | ||
2561 | echo "configure:2562: checking for printf in -lnsl" >&5 | ||
2562 | ac_lib_var=`echo nsl'_'printf | sed 'y%./+-%__p_%'` | ||
2563 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then | ||
2564 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
2565 | else | ||
2566 | ac_save_LIBS="$LIBS" | ||
2567 | LIBS="-lnsl $LIBS" | ||
2568 | cat > conftest.$ac_ext <<EOF | ||
2569 | #line 2570 "configure" | ||
2570 | #include "confdefs.h" | ||
2571 | /* Override any gcc2 internal prototype to avoid an error. */ | ||
2572 | /* We use char because int might match the return type of a gcc2 | ||
2573 | builtin and then its argument prototype would still apply. */ | ||
2574 | char printf(); | ||
2575 | |||
2576 | int main() { | ||
2577 | printf() | ||
2578 | ; return 0; } | ||
2579 | EOF | ||
2580 | if { (eval echo configure:2581: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | ||
2581 | rm -rf conftest* | ||
2582 | eval "ac_cv_lib_$ac_lib_var=yes" | ||
2583 | else | ||
2584 | echo "configure: failed program was:" >&5 | ||
2585 | cat conftest.$ac_ext >&5 | ||
2586 | rm -rf conftest* | ||
2587 | eval "ac_cv_lib_$ac_lib_var=no" | ||
2588 | fi | ||
2589 | rm -f conftest* | ||
2590 | LIBS="$ac_save_LIBS" | ||
2591 | |||
2592 | fi | ||
2593 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then | ||
2594 | echo "$ac_t""yes" 1>&6 | ||
2595 | X11_EXTRA_LIBS="$X11_EXTRA_LIBS -lnsl" | ||
2596 | else | ||
2597 | echo "$ac_t""no" 1>&6 | ||
2598 | fi | ||
2599 | |||
2600 | fi | ||
2601 | |||
2602 | LIBS=$asc_oldLibs | ||
2603 | |||
2604 | |||
2605 | #-------------------------------------------------------------------- | ||
2606 | # The following comes directly from the configure.in file for | ||
2607 | # Tcl8.0. | ||
2608 | # | ||
2609 | # The statements below define a collection of symbols related to | ||
2610 | # dynamic loading and shared libraries: | ||
2611 | # | ||
2612 | # DL_OBJS - Name of the object file that implements dynamic | ||
2613 | # loading for ASCEND on this system. | ||
2614 | # DL_LIBS - Library file(s) to include in tclsh and other base | ||
2615 | # applications in order for the "load" command to work. | ||
2616 | # LD_FLAGS - Flags to pass to the compiler when linking object | ||
2617 | # files into an executable application binary such | ||
2618 | # as tclsh. | ||
2619 | # LD_SEARCH_FLAGS-Flags to pass to ld, such as "-R /usr/local/tcl/lib", | ||
2620 | # that tell the run-time dynamic linker where to look | ||
2621 | # for shared libraries such as libtcl.so. Depends on | ||
2622 | # the variable LIB_RUNTIME_DIR in the Makefile. | ||
2623 | # MAKE_LIB - Command to execute to build the ASCEND library; | ||
2624 | # differs depending on whether or not ASCEND is being | ||
2625 | # compiled as a shared library. | ||
2626 | # SHLIB_CFLAGS - Flags to pass to cc when compiling the components | ||
2627 | # of a shared library (may request position-independent | ||
2628 | # code, among other things). | ||
2629 | # SHLIB_LD - Base command to use for combining object files | ||
2630 | # into a shared library. | ||
2631 | # SHLIB_LD_LIBS - Dependent libraries for the linker to scan when | ||
2632 | # creating shared libraries. This symbol typically | ||
2633 | # goes at the end of the "ld" commands that build | ||
2634 | # shared libraries. The value of the symbol is | ||
2635 | # "${LIBS}" if all of the dependent libraries should | ||
2636 | # be specified when creating a shared library. If | ||
2637 | # dependent libraries should not be specified (as on | ||
2638 | # SunOS 4.x, where they cause the link to fail, or in | ||
2639 | # general if ASCEND and Tk aren't themselves shared | ||
2640 | # libraries), then this symbol has an empty string | ||
2641 | # as its value. | ||
2642 | # SHLIB_SUFFIX - Suffix to use for the names of dynamically loadable | ||
2643 | # extensions. An empty string means we don't know how | ||
2644 | # to use shared libraries on this platform. | ||
2645 | # ASC_LIB_FILE - Name of the file that contains the ASCEND library, such | ||
2646 | # as libtcl7.8.so or libtcl7.8.a. | ||
2647 | # ASC_LIB_SUFFIX -Specifies everything that comes after the "libtcl" | ||
2648 | # in the shared library name, using the $VERSION variable | ||
2649 | # to put the version in the right place. This is used | ||
2650 | # by platforms that need non-standard library names. | ||
2651 | # Examples: ${VERSION}.so.1.1 on NetBSD, since it needs | ||
2652 | # to have a version after the .so, and ${VERSION}.a | ||
2653 | # on AIX, since the ASCEND shared library needs to have | ||
2654 | # a .a extension whereas shared objects for loadable | ||
2655 | # extensions have a .so extension. Defaults to | ||
2656 | # ${VERSION}${SHLIB_SUFFIX}. | ||
2657 | #-------------------------------------------------------------------- | ||
2658 | |||
2659 | # Step 1: set the variable "system" to hold the name and version number | ||
2660 | # for the system. This can usually be done via the "uname" command, but | ||
2661 | # there are a few systems, like Next, where this doesn't work. | ||
2662 | |||
2663 | # Changed this to use the "$host" variable from AC_CANONICAL_HOST | ||
2664 | |||
2665 | # Step 2: check for existence of -ldl library. This is needed because | ||
2666 | # Linux can use either -ldl or -ldld for dynamic loading. | ||
2667 | |||
2668 | echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6 | ||
2669 | echo "configure:2670: checking for dlopen in -ldl" >&5 | ||
2670 | ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'` | ||
2671 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then | ||
2672 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
2673 | else | ||
2674 | ac_save_LIBS="$LIBS" | ||
2675 | LIBS="-ldl $LIBS" | ||
2676 | cat > conftest.$ac_ext <<EOF | ||
2677 | #line 2678 "configure" | ||
2678 | #include "confdefs.h" | ||
2679 | /* Override any gcc2 internal prototype to avoid an error. */ | ||
2680 | /* We use char because int might match the return type of a gcc2 | ||
2681 | builtin and then its argument prototype would still apply. */ | ||
2682 | char dlopen(); | ||
2683 | |||
2684 | int main() { | ||
2685 | dlopen() | ||
2686 | ; return 0; } | ||
2687 | EOF | ||
2688 | if { (eval echo configure:2689: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | ||
2689 | rm -rf conftest* | ||
2690 | eval "ac_cv_lib_$ac_lib_var=yes" | ||
2691 | else | ||
2692 | echo "configure: failed program was:" >&5 | ||
2693 | cat conftest.$ac_ext >&5 | ||
2694 | rm -rf conftest* | ||
2695 | eval "ac_cv_lib_$ac_lib_var=no" | ||
2696 | fi | ||
2697 | rm -f conftest* | ||
2698 | LIBS="$ac_save_LIBS" | ||
2699 | |||
2700 | fi | ||
2701 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then | ||
2702 | echo "$ac_t""yes" 1>&6 | ||
2703 | have_dl=yes | ||
2704 | else | ||
2705 | echo "$ac_t""no" 1>&6 | ||
2706 | have_dl=no | ||
2707 | fi | ||
2708 | |||
2709 | |||
2710 | # Step 3: set configuration options based on system name and version. | ||
2711 | |||
2712 | ASC_SHARED_LIB_SUFFIX="" | ||
2713 | ASC_UNSHARED_LIB_SUFFIX="" | ||
2714 | ASC_LIB_VERSIONS_OK=ok | ||
2715 | case $host in | ||
2716 | *-aix*) | ||
2717 | SHLIB_CFLAGS="" | ||
2718 | SHLIB_LD="$fullpathsrcdir/ldAix /bin/ld -bhalt:4 -bM:SRE -bE:lib.exp -H512 -T512" | ||
2719 | SHLIB_LD_LIBS='${LIBS}' | ||
2720 | SHLIB_SUFFIX=".so" | ||
2721 | DL_OBJS="" | ||
2722 | DL_LIBS="-lld" | ||
2723 | LD_FLAGS="" | ||
2724 | LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}' | ||
2725 | ASC_SHARED_LIB_SUFFIX='${VERSION}.a' | ||
2726 | ;; | ||
2727 | *-bsdi*) | ||
2728 | SHLIB_CFLAGS="" | ||
2729 | SHLIB_LD="shlicc -r" | ||
2730 | SHLIB_LD_LIBS='${LIBS}' | ||
2731 | SHLIB_SUFFIX=".so" | ||
2732 | DL_OBJS="" | ||
2733 | DL_LIBS="-ldl" | ||
2734 | LD_FLAGS="" | ||
2735 | LD_SEARCH_FLAGS="" | ||
2736 | ;; | ||
2737 | *-dgux*) | ||
2738 | SHLIB_CFLAGS="-K PIC" | ||
2739 | SHLIB_LD="cc -G" | ||
2740 | SHLIB_LD_LIBS="" | ||
2741 | SHLIB_SUFFIX=".so" | ||
2742 | DL_OBJS="" | ||
2743 | DL_LIBS="-ldl" | ||
2744 | LD_FLAGS="" | ||
2745 | LD_SEARCH_FLAGS="" | ||
2746 | ;; | ||
2747 | *-hpux8*|*-hpux9*|*-hpux10*) | ||
2748 | echo $ac_n "checking for shl_load in -ldld""... $ac_c" 1>&6 | ||
2749 | echo "configure:2750: checking for shl_load in -ldld" >&5 | ||
2750 | ac_lib_var=`echo dld'_'shl_load | sed 'y%./+-%__p_%'` | ||
2751 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then | ||
2752 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
2753 | else | ||
2754 | ac_save_LIBS="$LIBS" | ||
2755 | LIBS="-ldld $LIBS" | ||
2756 | cat > conftest.$ac_ext <<EOF | ||
2757 | #line 2758 "configure" | ||
2758 | #include "confdefs.h" | ||
2759 | /* Override any gcc2 internal prototype to avoid an error. */ | ||
2760 | /* We use char because int might match the return type of a gcc2 | ||
2761 | builtin and then its argument prototype would still apply. */ | ||
2762 | char shl_load(); | ||
2763 | |||
2764 | int main() { | ||
2765 | shl_load() | ||
2766 | ; return 0; } | ||
2767 | EOF | ||
2768 | if { (eval echo configure:2769: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | ||
2769 | rm -rf conftest* | ||
2770 | eval "ac_cv_lib_$ac_lib_var=yes" | ||
2771 | else | ||
2772 | echo "configure: failed program was:" >&5 | ||
2773 | cat conftest.$ac_ext >&5 | ||
2774 | rm -rf conftest* | ||
2775 | eval "ac_cv_lib_$ac_lib_var=no" | ||
2776 | fi | ||
2777 | rm -f conftest* | ||
2778 | LIBS="$ac_save_LIBS" | ||
2779 | |||
2780 | fi | ||
2781 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then | ||
2782 | echo "$ac_t""yes" 1>&6 | ||
2783 | tcl_ok=yes | ||
2784 | else | ||
2785 | echo "$ac_t""no" 1>&6 | ||
2786 | tcl_ok=no | ||
2787 | fi | ||
2788 | |||
2789 | if test "$tcl_ok" = yes; then | ||
2790 | SHLIB_CFLAGS="+z" | ||
2791 | SHLIB_LD="ld -b" | ||
2792 | SHLIB_LD_LIBS="" | ||
2793 | SHLIB_SUFFIX=".sl" | ||
2794 | DL_OBJS="" | ||
2795 | DL_LIBS="-ldld" | ||
2796 | LD_FLAGS="-Wl,-E" | ||
2797 | LD_SEARCH_FLAGS='-Wl,+b,${LIB_RUNTIME_DIR}:.' | ||
2798 | fi | ||
2799 | ;; | ||
2800 | *-irix4*) | ||
2801 | SHLIB_CFLAGS="-G 0" | ||
2802 | SHLIB_SUFFIX=".a" | ||
2803 | SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r -G 0" | ||
2804 | SHLIB_LD_LIBS='${LIBS}' | ||
2805 | DL_OBJS="" | ||
2806 | DL_LIBS="" | ||
2807 | LD_FLAGS="-Wl,-D,08000000" | ||
2808 | LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}' | ||
2809 | ASC_SHARED_LIB_SUFFIX='${VERSION}.a' | ||
2810 | ;; | ||
2811 | *-irix5*|*-irix6.*) | ||
2812 | SHLIB_CFLAGS="" | ||
2813 | SHLIB_LD="ld -shared -rdata_shared" | ||
2814 | SHLIB_LD_LIBS="" | ||
2815 | SHLIB_SUFFIX=".so" | ||
2816 | DL_OBJS="" | ||
2817 | DL_LIBS="" | ||
2818 | LD_FLAGS="" | ||
2819 | LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}' | ||
2820 | ;; | ||
2821 | *-linux*) | ||
2822 | SHLIB_CFLAGS="-fPIC" | ||
2823 | SHLIB_LD_LIBS="" | ||
2824 | SHLIB_SUFFIX=".so" | ||
2825 | if test "$have_dl" = yes; then | ||
2826 | SHLIB_LD="${CC} -shared" | ||
2827 | DL_OBJS="" | ||
2828 | DL_LIBS="-ldl" | ||
2829 | LD_FLAGS="-rdynamic" | ||
2830 | LD_SEARCH_FLAGS="" | ||
2831 | else | ||
2832 | ac_safe=`echo "dld.h" | sed 'y%./+-%__p_%'` | ||
2833 | echo $ac_n "checking for dld.h""... $ac_c" 1>&6 | ||
2834 | echo "configure:2835: checking for dld.h" >&5 | ||
2835 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then | ||
2836 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
2837 | else | ||
2838 | cat > conftest.$ac_ext <<EOF | ||
2839 | #line 2840 "configure" | ||
2840 | #include "confdefs.h" | ||
2841 | #include <dld.h> | ||
2842 | EOF | ||
2843 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | ||
2844 | { (eval echo configure:2845: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } | ||
2845 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` | ||
2846 | if test -z "$ac_err"; then | ||
2847 | rm -rf conftest* | ||
2848 | eval "ac_cv_header_$ac_safe=yes" | ||
2849 | else | ||
2850 | echo "$ac_err" >&5 | ||
2851 | echo "configure: failed program was:" >&5 | ||
2852 | cat conftest.$ac_ext >&5 | ||
2853 | rm -rf conftest* | ||
2854 | eval "ac_cv_header_$ac_safe=no" | ||
2855 | fi | ||
2856 | rm -f conftest* | ||
2857 | fi | ||
2858 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | ||
2859 | echo "$ac_t""yes" 1>&6 | ||
2860 | |||
2861 | SHLIB_LD="ld -shared" | ||
2862 | DL_OBJS="" | ||
2863 | DL_LIBS="-ldld" | ||
2864 | LD_FLAGS="" | ||
2865 | LD_SEARCH_FLAGS="" | ||
2866 | else | ||
2867 | echo "$ac_t""no" 1>&6 | ||
2868 | fi | ||
2869 | |||
2870 | fi | ||
2871 | ;; | ||
2872 | MP-RAS-02*) | ||
2873 | SHLIB_CFLAGS="-K PIC" | ||
2874 | SHLIB_LD="cc -G" | ||
2875 | SHLIB_LD_LIBS="" | ||
2876 | SHLIB_SUFFIX=".so" | ||
2877 | DL_OBJS="" | ||
2878 | DL_LIBS="-ldl" | ||
2879 | LD_FLAGS="" | ||
2880 | LD_SEARCH_FLAGS="" | ||
2881 | ;; | ||
2882 | MP-RAS-*) | ||
2883 | SHLIB_CFLAGS="-K PIC" | ||
2884 | SHLIB_LD="cc -G" | ||
2885 | SHLIB_LD_LIBS="" | ||
2886 | SHLIB_SUFFIX=".so" | ||
2887 | DL_OBJS="" | ||
2888 | DL_LIBS="-ldl" | ||
2889 | LD_FLAGS="-Wl,-Bexport" | ||
2890 | LD_SEARCH_FLAGS="" | ||
2891 | ;; | ||
2892 | *-netbsd*|*-freebsd*|*-openbsd*) | ||
2893 | # Not available on all versions: check for include file. | ||
2894 | ac_safe=`echo "dlfcn.h" | sed 'y%./+-%__p_%'` | ||
2895 | echo $ac_n "checking for dlfcn.h""... $ac_c" 1>&6 | ||
2896 | echo "configure:2897: checking for dlfcn.h" >&5 | ||
2897 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then | ||
2898 | echo $ac_n "(cached) $ac_c" 1>&6 | ||
2899 | else | ||
2900 | cat > conftest.$ac_ext <<EOF | ||
2901 | #line 2902 "configure" | ||
2902 | #include "confdefs.h" | ||
2903 | #include <dlfcn.h> | ||
2904 | EOF | ||
2905 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | ||
2906 | { (eval echo configure:2907: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } | ||
2907 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` | ||
2908 | if test -z "$ac_err"; then | ||
2909 | rm -rf conftest* | ||
2910 | eval "ac_cv_header_$ac_safe=yes" | ||
2911 | else | ||
2912 | echo "$ac_err" >&5 | ||
2913 | echo "configure: failed program was:" >&5 | ||
2914 | cat conftest.$ac_ext >&5 | ||
2915 | rm -rf conftest* | ||
2916 | eval "ac_cv_header_$ac_safe=no" | ||
2917 | fi | ||
2918 | rm -f conftest* | ||
2919 | fi | ||
2920 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | ||
2921 | echo "$ac_t""yes" 1>&6 | ||
2922 | |||
2923 | SHLIB_CFLAGS="-fpic" | ||
2924 | SHLIB_LD="ld -Bshareable -x" | ||
2925 | SHLIB_LD_LIBS="" | ||
2926 | SHLIB_SUFFIX=".so" | ||
2927 | DL_OBJS="" | ||
2928 | DL_LIBS="" | ||
2929 | LD_FLAGS="" | ||
2930 | LD_SEARCH_FLAGS="" | ||
2931 | ASC_SHARED_LIB_SUFFIX='`echo ${VERSION} | tr -d .`.so.1.0' | ||
2932 | |||
2933 | else | ||
2934 | echo "$ac_t""no" 1>&6 | ||
2935 | |||
2936 | SHLIB_CFLAGS="" | ||
2937 | SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r" | ||
2938 | SHLIB_LD_LIBS='${LIBS}' | ||
2939 | SHLIB_SUFFIX=".a" | ||
2940 | DL_OBJS="" | ||
2941 | DL_LIBS="" | ||
2942 | LD_FLAGS="" | ||
2943 | LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}' | ||
2944 | ASC_SHARED_LIB_SUFFIX='`echo ${VERSION} | tr -d .`.a' | ||
2945 | |||
2946 | fi | ||
2947 | |||
2948 | |||
2949 | # FreeBSD doesn't handle version numbers with dots. | ||
2950 | |||
2951 | ASC_UNSHARED_LIB_SUFFIX='`echo ${VERSION} | tr -d .`.a' | ||
2952 | ASC_LIB_VERSIONS_OK=nodots | ||
2953 | ;; | ||
2954 | *-nextstep*) | ||
2955 | SHLIB_CFLAGS="" | ||
2956 | SHLIB_LD="cc -nostdlib -r" | ||
2957 | SHLIB_LD_LIBS="" | ||
2958 | SHLIB_SUFFIX=".so" | ||
2959 | DL_OBJS="" | ||
2960 | DL_LIBS="" | ||
2961 | LD_FLAGS="" | ||
2962 | LD_SEARCH_FLAGS="" | ||
2963 | ;; | ||
2964 | alpha-dec-osf*) | ||
2965 | # Digital OSF/1 | ||
2966 | SHLIB_CFLAGS="" | ||
2967 | SHLIB_LD='ld -shared -expect_unresolved "*"' | ||
2968 | SHLIB_LD_LIBS="" | ||
2969 | SHLIB_SUFFIX=".so" | ||
2970 | DL_OBJS="" | ||
2971 | DL_LIBS="" | ||
2972 | LD_FLAGS="" | ||
2973 | LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}' | ||
2974 | ;; | ||
2975 | *-riscos*) | ||
2976 | SHLIB_CFLAGS="-G 0" | ||
2977 | SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r -G 0" | ||
2978 | SHLIB_LD_LIBS='${LIBS}' | ||
2979 | SHLIB_SUFFIX=".a" | ||
2980 | DL_OBJS="" | ||
2981 | DL_LIBS="" | ||
2982 | LD_FLAGS="-Wl,-D,08000000" | ||
2983 | LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}' | ||
2984 | ;; | ||
2985 | SCO_SV-3.2*) | ||
2986 | # Note, dlopen is available only on SCO 3.2.5 and greater. However, | ||
2987 | # this test works, since "uname -s" was non-standard in 3.2.4 and | ||
2988 | # below. | ||
2989 | SHLIB_CFLAGS="-Kpic -belf" | ||
2990 | SHLIB_LD="ld -G" | ||
2991 | SHLIB_LD_LIBS="" | ||
2992 | SHLIB_SUFFIX=".so" | ||
2993 | DL_OBJS="" | ||
2994 | DL_LIBS="" | ||
2995 | LD_FLAGS="-belf -Wl,-Bexport" | ||
2996 | LD_SEARCH_FLAGS="" | ||
2997 | ;; | ||
2998 | *-sni-sysv*) | ||
2999 | SHLIB_CFLAGS="-K PIC" | ||
3000 | SHLIB_LD="cc -G" | ||
3001 | SHLIB_LD_LIBS="" | ||
3002 | SHLIB_SUFFIX=".so" | ||
3003 | DL_OBJS="" | ||
3004 | DL_LIBS="-ldl" | ||
3005 | LD_FLAGS="" | ||
3006 | LD_SEARCH_FLAGS="" | ||
3007 | ;; | ||
3008 | *-sunos4*) | ||
3009 | SHLIB_CFLAGS="-PIC" | ||
3010 | SHLIB_LD="ld" | ||
3011 | SHLIB_LD_LIBS="" | ||
3012 | SHLIB_SUFFIX=".so" | ||
3013 | DL_OBJS="" | ||
3014 | DL_LIBS="-ldl" | ||
3015 | LD_FLAGS="" | ||
3016 | LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}' | ||
3017 | |||
3018 | # SunOS can't handle version numbers with dots in them in library | ||
3019 | # specs, like -ltcl7.5, so use -ltcl75 instead. Also, it | ||
3020 | # requires an extra version number at the end of .so file names. | ||
3021 | # So, the library has to have a name like libtcl75.so.1.0 | ||
3022 | |||
3023 | ASC_SHARED_LIB_SUFFIX='`echo ${VERSION} | tr -d .`.so.1.0' | ||
3024 | ASC_UNSHARED_LIB_SUFFIX='`echo ${VERSION} | tr -d .`.a' | ||
3025 | ASC_LIB_VERSIONS_OK=nodots | ||
3026 | ;; | ||
3027 | *-solaris*) | ||
3028 | SHLIB_CFLAGS="-KPIC" | ||
3029 | SHLIB_LD="/usr/ccs/bin/ld -G -z text" | ||
3030 | |||
3031 | # Note: need the LIBS below, otherwise Tk won't find ASCEND's | ||
3032 | # symbols when dynamically loaded into tclsh. | ||
3033 | |||
3034 | SHLIB_LD_LIBS='${LIBS}' | ||
3035 | SHLIB_SUFFIX=".so" | ||
3036 | DL_OBJS="" | ||
3037 | DL_LIBS="-ldl" | ||
3038 | LD_FLAGS="" | ||
3039 | LD_SEARCH_FLAGS='-R ${LIB_RUNTIME_DIR}' | ||
3040 | ;; | ||
3041 | *-ultrix4*) | ||
3042 | SHLIB_CFLAGS="-G 0" | ||
3043 | SHLIB_SUFFIX=".a" | ||
3044 | SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r -G 0" | ||
3045 | SHLIB_LD_LIBS='${LIBS}' | ||
3046 | DL_OBJS="" | ||
3047 | DL_LIBS="" | ||
3048 | LD_FLAGS="-Wl,-D,08000000" | ||
3049 | LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}' | ||
3050 | ;; | ||
3051 | mips-dde-sysv*) | ||
3052 | SHLIB_CFLAGS="-KPIC" | ||
3053 | SHLIB_LD="cc -G" | ||
3054 | SHLIB_LD_LIBS="" | ||
3055 | SHLIB_SUFFIX=".so" | ||
3056 | DL_OBJS="" | ||
3057 | DL_LIBS="-ldl" | ||
3058 | # Some UNIX_SV* systems (unixware 1.1.2 for example) have linkers | ||
3059 | # that don't grok the -Bexport option. Test that it does. | ||
3060 | hold_ldflags=$LDFLAGS | ||
3061 | echo $ac_n "checking for ld accepts -Bexport flag""... $ac_c" 1>&6 | ||
3062 | echo "configure:3063: checking for ld accepts -Bexport flag" >&5 | ||
3063 | LDFLAGS="${LDFLAGS} -Wl,-Bexport" | ||
3064 | cat > conftest.$ac_ext <<EOF | ||
3065 | #line 3066 "configure" | ||
3066 | #include "confdefs.h" | ||
3067 | |||
3068 | int main() { | ||
3069 | int i; | ||
3070 | ; return 0; } | ||
3071 | EOF | ||
3072 | if { (eval echo configure:3073: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | ||
3073 | rm -rf conftest* | ||
3074 | found=yes | ||
3075 | else | ||
3076 | echo "configure: failed program was:" >&5 | ||
3077 | cat conftest.$ac_ext >&5 | ||
3078 | rm -rf conftest* | ||
3079 | found=no | ||
3080 | fi | ||
3081 | rm -f conftest* | ||
3082 | LDFLAGS=$hold_ldflags | ||
3083 | echo "$ac_t""$found" 1>&6 | ||
3084 | if test "$found" = yes; then | ||
3085 | LD_FLAGS="-Wl,-Bexport" | ||
3086 | else | ||
3087 | LD_FLAGS="" | ||
3088 | fi | ||
3089 | LD_SEARCH_FLAGS="" | ||
3090 | ;; | ||
3091 | esac | ||
3092 | |||
3093 | # Step 4: If pseudo-static linking is in use (see K. B. Kenny, "Dynamic | ||
3094 | # Loading for Tcl -- What Became of It?". Proc. 2nd Tcl/Tk Workshop, | ||
3095 | # New Orleans, LA, Computerized Processes Unlimited, 1994), then we need | ||
3096 | # to determine which of several header files defines the a.out file | ||
3097 | # format (a.out.h, sys/exec.h, or sys/exec_aout.h). At present, we | ||
3098 | # support only a file format that is more or less version-7-compatible. | ||
3099 | # In particular, |