1 | #! /bin/sh |
---|
2 | |
---|
3 | # From configure.in for Readline 4.0, version 2.14, from autoconf version 2.12 |
---|
4 | LIBVERSION=4.0 |
---|
5 | |
---|
6 | |
---|
7 | |
---|
8 | |
---|
9 | |
---|
10 | |
---|
11 | |
---|
12 | |
---|
13 | |
---|
14 | |
---|
15 | |
---|
16 | |
---|
17 | |
---|
18 | |
---|
19 | |
---|
20 | |
---|
21 | |
---|
22 | |
---|
23 | |
---|
24 | |
---|
25 | |
---|
26 | |
---|
27 | |
---|
28 | |
---|
29 | |
---|
30 | |
---|
31 | |
---|
32 | |
---|
33 | |
---|
34 | |
---|
35 | |
---|
36 | |
---|
37 | |
---|
38 | |
---|
39 | |
---|
40 | |
---|
41 | |
---|
42 | |
---|
43 | |
---|
44 | |
---|
45 | |
---|
46 | |
---|
47 | |
---|
48 | |
---|
49 | |
---|
50 | |
---|
51 | |
---|
52 | |
---|
53 | |
---|
54 | |
---|
55 | |
---|
56 | |
---|
57 | |
---|
58 | |
---|
59 | |
---|
60 | |
---|
61 | |
---|
62 | |
---|
63 | |
---|
64 | |
---|
65 | |
---|
66 | |
---|
67 | |
---|
68 | |
---|
69 | |
---|
70 | |
---|
71 | |
---|
72 | |
---|
73 | |
---|
74 | |
---|
75 | |
---|
76 | |
---|
77 | |
---|
78 | |
---|
79 | |
---|
80 | |
---|
81 | |
---|
82 | |
---|
83 | |
---|
84 | |
---|
85 | |
---|
86 | |
---|
87 | |
---|
88 | |
---|
89 | |
---|
90 | |
---|
91 | |
---|
92 | |
---|
93 | |
---|
94 | # Guess values for system-dependent variables and create Makefiles. |
---|
95 | # Generated automatically using autoconf version 2.12 |
---|
96 | # Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc. |
---|
97 | # |
---|
98 | # This configure script is free software; the Free Software Foundation |
---|
99 | # gives unlimited permission to copy, distribute and modify it. |
---|
100 | |
---|
101 | # Defaults: |
---|
102 | ac_help= |
---|
103 | ac_default_prefix=/usr/local |
---|
104 | # Any additions from configure.in: |
---|
105 | ac_help="$ac_help |
---|
106 | --with-curses use the curses library instead of the termcap library" |
---|
107 | |
---|
108 | # Initialize some variables set by options. |
---|
109 | # The variables have the same names as the options, with |
---|
110 | # dashes changed to underlines. |
---|
111 | build=NONE |
---|
112 | cache_file=./config.cache |
---|
113 | exec_prefix=NONE |
---|
114 | host=NONE |
---|
115 | no_create= |
---|
116 | nonopt=NONE |
---|
117 | no_recursion= |
---|
118 | prefix=NONE |
---|
119 | program_prefix=NONE |
---|
120 | program_suffix=NONE |
---|
121 | program_transform_name=s,x,x, |
---|
122 | silent= |
---|
123 | site= |
---|
124 | srcdir= |
---|
125 | target=NONE |
---|
126 | verbose= |
---|
127 | x_includes=NONE |
---|
128 | x_libraries=NONE |
---|
129 | bindir='${exec_prefix}/bin' |
---|
130 | sbindir='${exec_prefix}/sbin' |
---|
131 | libexecdir='${exec_prefix}/libexec' |
---|
132 | datadir='${prefix}/share' |
---|
133 | sysconfdir='${prefix}/etc' |
---|
134 | sharedstatedir='${prefix}/com' |
---|
135 | localstatedir='${prefix}/var' |
---|
136 | libdir='${exec_prefix}/lib' |
---|
137 | includedir='${prefix}/include' |
---|
138 | oldincludedir='/usr/include' |
---|
139 | infodir='${prefix}/info' |
---|
140 | mandir='${prefix}/man' |
---|
141 | |
---|
142 | # Initialize some other variables. |
---|
143 | subdirs= |
---|
144 | MFLAGS= MAKEFLAGS= |
---|
145 | # Maximum number of lines to put in a shell here document. |
---|
146 | ac_max_here_lines=12 |
---|
147 | |
---|
148 | ac_prev= |
---|
149 | for ac_option |
---|
150 | do |
---|
151 | |
---|
152 | # If the previous option needs an argument, assign it. |
---|
153 | if test -n "$ac_prev"; then |
---|
154 | eval "$ac_prev=\$ac_option" |
---|
155 | ac_prev= |
---|
156 | continue |
---|
157 | fi |
---|
158 | |
---|
159 | case "$ac_option" in |
---|
160 | -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;; |
---|
161 | *) ac_optarg= ;; |
---|
162 | esac |
---|
163 | |
---|
164 | # Accept the important Cygnus configure options, so we can diagnose typos. |
---|
165 | |
---|
166 | case "$ac_option" in |
---|
167 | |
---|
168 | -bindir | --bindir | --bindi | --bind | --bin | --bi) |
---|
169 | ac_prev=bindir ;; |
---|
170 | -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) |
---|
171 | bindir="$ac_optarg" ;; |
---|
172 | |
---|
173 | -build | --build | --buil | --bui | --bu) |
---|
174 | ac_prev=build ;; |
---|
175 | -build=* | --build=* | --buil=* | --bui=* | --bu=*) |
---|
176 | build="$ac_optarg" ;; |
---|
177 | |
---|
178 | -cache-file | --cache-file | --cache-fil | --cache-fi \ |
---|
179 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) |
---|
180 | ac_prev=cache_file ;; |
---|
181 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ |
---|
182 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) |
---|
183 | cache_file="$ac_optarg" ;; |
---|
184 | |
---|
185 | -datadir | --datadir | --datadi | --datad | --data | --dat | --da) |
---|
186 | ac_prev=datadir ;; |
---|
187 | -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \ |
---|
188 | | --da=*) |
---|
189 | datadir="$ac_optarg" ;; |
---|
190 | |
---|
191 | -disable-* | --disable-*) |
---|
192 | ac_feature=`echo $ac_option|sed -e 's/-*disable-//'` |
---|
193 | # Reject names that are not valid shell variable names. |
---|
194 | if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then |
---|
195 | { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } |
---|
196 | fi |
---|
197 | ac_feature=`echo $ac_feature| sed 's/-/_/g'` |
---|
198 | eval "enable_${ac_feature}=no" ;; |
---|
199 | |
---|
200 | -enable-* | --enable-*) |
---|
201 | ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'` |
---|
202 | # Reject names that are not valid shell variable names. |
---|
203 | if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then |
---|
204 | { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } |
---|
205 | fi |
---|
206 | ac_feature=`echo $ac_feature| sed 's/-/_/g'` |
---|
207 | case "$ac_option" in |
---|
208 | *=*) ;; |
---|
209 | *) ac_optarg=yes ;; |
---|
210 | esac |
---|
211 | eval "enable_${ac_feature}='$ac_optarg'" ;; |
---|
212 | |
---|
213 | -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ |
---|
214 | | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ |
---|
215 | | --exec | --exe | --ex) |
---|
216 | ac_prev=exec_prefix ;; |
---|
217 | -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ |
---|
218 | | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ |
---|
219 | | --exec=* | --exe=* | --ex=*) |
---|
220 | exec_prefix="$ac_optarg" ;; |
---|
221 | |
---|
222 | -gas | --gas | --ga | --g) |
---|
223 | # Obsolete; use --with-gas. |
---|
224 | with_gas=yes ;; |
---|
225 | |
---|
226 | -help | --help | --hel | --he) |
---|
227 | # Omit some internal or obsolete options to make the list less imposing. |
---|
228 | # This message is too long to be a string in the A/UX 3.1 sh. |
---|
229 | cat << EOF |
---|
230 | Usage: configure [options] [host] |
---|
231 | Options: [defaults in brackets after descriptions] |
---|
232 | Configuration: |
---|
233 | --cache-file=FILE cache test results in FILE |
---|
234 | --help print this message |
---|
235 | --no-create do not create output files |
---|
236 | --quiet, --silent do not print \`checking...' messages |
---|
237 | --version print the version of autoconf that created configure |
---|
238 | Directory and file names: |
---|
239 | --prefix=PREFIX install architecture-independent files in PREFIX |
---|
240 | [$ac_default_prefix] |
---|
241 | --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX |
---|
242 | [same as prefix] |
---|
243 | --bindir=DIR user executables in DIR [EPREFIX/bin] |
---|
244 | --sbindir=DIR system admin executables in DIR [EPREFIX/sbin] |
---|
245 | --libexecdir=DIR program executables in DIR [EPREFIX/libexec] |
---|
246 | --datadir=DIR read-only architecture-independent data in DIR |
---|
247 | [PREFIX/share] |
---|
248 | --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc] |
---|
249 | --sharedstatedir=DIR modifiable architecture-independent data in DIR |
---|
250 | [PREFIX/com] |
---|
251 | --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var] |
---|
252 | --libdir=DIR object code libraries in DIR [EPREFIX/lib] |
---|
253 | --includedir=DIR C header files in DIR [PREFIX/include] |
---|
254 | --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include] |
---|
255 | --infodir=DIR info documentation in DIR [PREFIX/info] |
---|
256 | --mandir=DIR man documentation in DIR [PREFIX/man] |
---|
257 | --srcdir=DIR find the sources in DIR [configure dir or ..] |
---|
258 | --program-prefix=PREFIX prepend PREFIX to installed program names |
---|
259 | --program-suffix=SUFFIX append SUFFIX to installed program names |
---|
260 | --program-transform-name=PROGRAM |
---|
261 | run sed PROGRAM on installed program names |
---|
262 | EOF |
---|
263 | cat << EOF |
---|
264 | Host type: |
---|
265 | --build=BUILD configure for building on BUILD [BUILD=HOST] |
---|
266 | --host=HOST configure for HOST [guessed] |
---|
267 | --target=TARGET configure for TARGET [TARGET=HOST] |
---|
268 | Features and packages: |
---|
269 | --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) |
---|
270 | --enable-FEATURE[=ARG] include FEATURE [ARG=yes] |
---|
271 | --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] |
---|
272 | --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) |
---|
273 | --x-includes=DIR X include files are in DIR |
---|
274 | --x-libraries=DIR X library files are in DIR |
---|
275 | EOF |
---|
276 | if test -n "$ac_help"; then |
---|
277 | echo "--enable and --with options recognized:$ac_help" |
---|
278 | fi |
---|
279 | exit 0 ;; |
---|
280 | |
---|
281 | -host | --host | --hos | --ho) |
---|
282 | ac_prev=host ;; |
---|
283 | -host=* | --host=* | --hos=* | --ho=*) |
---|
284 | host="$ac_optarg" ;; |
---|
285 | |
---|
286 | -includedir | --includedir | --includedi | --included | --include \ |
---|
287 | | --includ | --inclu | --incl | --inc) |
---|
288 | ac_prev=includedir ;; |
---|
289 | -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ |
---|
290 | | --includ=* | --inclu=* | --incl=* | --inc=*) |
---|
291 | includedir="$ac_optarg" ;; |
---|
292 | |
---|
293 | -infodir | --infodir | --infodi | --infod | --info | --inf) |
---|
294 | ac_prev=infodir ;; |
---|
295 | -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) |
---|
296 | infodir="$ac_optarg" ;; |
---|
297 | |
---|
298 | -libdir | --libdir | --libdi | --libd) |
---|
299 | ac_prev=libdir ;; |
---|
300 | -libdir=* | --libdir=* | --libdi=* | --libd=*) |
---|
301 | libdir="$ac_optarg" ;; |
---|
302 | |
---|
303 | -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ |
---|
304 | | --libexe | --libex | --libe) |
---|
305 | ac_prev=libexecdir ;; |
---|
306 | -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ |
---|
307 | | --libexe=* | --libex=* | --libe=*) |
---|
308 | libexecdir="$ac_optarg" ;; |
---|
309 | |
---|
310 | -localstatedir | --localstatedir | --localstatedi | --localstated \ |
---|
311 | | --localstate | --localstat | --localsta | --localst \ |
---|
312 | | --locals | --local | --loca | --loc | --lo) |
---|
313 | ac_prev=localstatedir ;; |
---|
314 | -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ |
---|
315 | | --localstate=* | --localstat=* | --localsta=* | --localst=* \ |
---|
316 | | --locals=* | --local=* | --loca=* | --loc=* | --lo=*) |
---|
317 | localstatedir="$ac_optarg" ;; |
---|
318 | |
---|
319 | -mandir | --mandir | --mandi | --mand | --man | --ma | --m) |
---|
320 | ac_prev=mandir ;; |
---|
321 | -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) |
---|
322 | mandir="$ac_optarg" ;; |
---|
323 | |
---|
324 | -nfp | --nfp | --nf) |
---|
325 | # Obsolete; use --without-fp. |
---|
326 | with_fp=no ;; |
---|
327 | |
---|
328 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ |
---|
329 | | --no-cr | --no-c) |
---|
330 | no_create=yes ;; |
---|
331 | |
---|
332 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ |
---|
333 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) |
---|
334 | no_recursion=yes ;; |
---|
335 | |
---|
336 | -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ |
---|
337 | | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ |
---|
338 | | --oldin | --oldi | --old | --ol | --o) |
---|
339 | ac_prev=oldincludedir ;; |
---|
340 | -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ |
---|
341 | | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ |
---|
342 | | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) |
---|
343 | oldincludedir="$ac_optarg" ;; |
---|
344 | |
---|
345 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) |
---|
346 | ac_prev=prefix ;; |
---|
347 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) |
---|
348 | prefix="$ac_optarg" ;; |
---|
349 | |
---|
350 | -program-prefix | --program-prefix | --program-prefi | --program-pref \ |
---|
351 | | --program-pre | --program-pr | --program-p) |
---|
352 | ac_prev=program_prefix ;; |
---|
353 | -program-prefix=* | --program-prefix=* | --program-prefi=* \ |
---|
354 | | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) |
---|
355 | program_prefix="$ac_optarg" ;; |
---|
356 | |
---|
357 | -program-suffix | --program-suffix | --program-suffi | --program-suff \ |
---|
358 | | --program-suf | --program-su | --program-s) |
---|
359 | ac_prev=program_suffix ;; |
---|
360 | -program-suffix=* | --program-suffix=* | --program-suffi=* \ |
---|
361 | | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) |
---|
362 | program_suffix="$ac_optarg" ;; |
---|
363 | |
---|
364 | -program-transform-name | --program-transform-name \ |
---|
365 | | --program-transform-nam | --program-transform-na \ |
---|
366 | | --program-transform-n | --program-transform- \ |
---|
367 | | --program-transform | --program-transfor \ |
---|
368 | | --program-transfo | --program-transf \ |
---|
369 | | --program-trans | --program-tran \ |
---|
370 | | --progr-tra | --program-tr | --program-t) |
---|
371 | ac_prev=program_transform_name ;; |
---|
372 | -program-transform-name=* | --program-transform-name=* \ |
---|
373 | | --program-transform-nam=* | --program-transform-na=* \ |
---|
374 | | --program-transform-n=* | --program-transform-=* \ |
---|
375 | | --program-transform=* | --program-transfor=* \ |
---|
376 | | --program-transfo=* | --program-transf=* \ |
---|
377 | | --program-trans=* | --program-tran=* \ |
---|
378 | | --progr-tra=* | --program-tr=* | --program-t=*) |
---|
379 | program_transform_name="$ac_optarg" ;; |
---|
380 | |
---|
381 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
---|
382 | | -silent | --silent | --silen | --sile | --sil) |
---|
383 | silent=yes ;; |
---|
384 | |
---|
385 | -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) |
---|
386 | ac_prev=sbindir ;; |
---|
387 | -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ |
---|
388 | | --sbi=* | --sb=*) |
---|
389 | sbindir="$ac_optarg" ;; |
---|
390 | |
---|
391 | -sharedstatedir | --sharedstatedir | --sharedstatedi \ |
---|
392 | | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ |
---|
393 | | --sharedst | --shareds | --shared | --share | --shar \ |
---|
394 | | --sha | --sh) |
---|
395 | ac_prev=sharedstatedir ;; |
---|
396 | -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ |
---|
397 | | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ |
---|
398 | | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ |
---|
399 | | --sha=* | --sh=*) |
---|
400 | sharedstatedir="$ac_optarg" ;; |
---|
401 | |
---|
402 | -site | --site | --sit) |
---|
403 | ac_prev=site ;; |
---|
404 | -site=* | --site=* | --sit=*) |
---|
405 | site="$ac_optarg" ;; |
---|
406 | |
---|
407 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) |
---|
408 | ac_prev=srcdir ;; |
---|
409 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) |
---|
410 | srcdir="$ac_optarg" ;; |
---|
411 | |
---|
412 | -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ |
---|
413 | | --syscon | --sysco | --sysc | --sys | --sy) |
---|
414 | ac_prev=sysconfdir ;; |
---|
415 | -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ |
---|
416 | | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) |
---|
417 | sysconfdir="$ac_optarg" ;; |
---|
418 | |
---|
419 | -target | --target | --targe | --targ | --tar | --ta | --t) |
---|
420 | ac_prev=target ;; |
---|
421 | -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) |
---|
422 | target="$ac_optarg" ;; |
---|
423 | |
---|
424 | -v | -verbose | --verbose | --verbos | --verbo | --verb) |
---|
425 | verbose=yes ;; |
---|
426 | |
---|
427 | -version | --version | --versio | --versi | --vers) |
---|
428 | echo "configure generated by autoconf version 2.12" |
---|
429 | exit 0 ;; |
---|
430 | |
---|
431 | -with-* | --with-*) |
---|
432 | ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'` |
---|
433 | # Reject names that are not valid shell variable names. |
---|
434 | if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then |
---|
435 | { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } |
---|
436 | fi |
---|
437 | ac_package=`echo $ac_package| sed 's/-/_/g'` |
---|
438 | case "$ac_option" in |
---|
439 | *=*) ;; |
---|
440 | *) ac_optarg=yes ;; |
---|
441 | esac |
---|
442 | eval "with_${ac_package}='$ac_optarg'" ;; |
---|
443 | |
---|
444 | -without-* | --without-*) |
---|
445 | ac_package=`echo $ac_option|sed -e 's/-*without-//'` |
---|
446 | # Reject names that are not valid shell variable names. |
---|
447 | if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then |
---|
448 | { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } |
---|
449 | fi |
---|
450 | ac_package=`echo $ac_package| sed 's/-/_/g'` |
---|
451 | eval "with_${ac_package}=no" ;; |
---|
452 | |
---|
453 | --x) |
---|
454 | # Obsolete; use --with-x. |
---|
455 | with_x=yes ;; |
---|
456 | |
---|
457 | -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ |
---|
458 | | --x-incl | --x-inc | --x-in | --x-i) |
---|
459 | ac_prev=x_includes ;; |
---|
460 | -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ |
---|
461 | | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) |
---|
462 | x_includes="$ac_optarg" ;; |
---|
463 | |
---|
464 | -x-libraries | --x-libraries | --x-librarie | --x-librari \ |
---|
465 | | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) |
---|
466 | ac_prev=x_libraries ;; |
---|
467 | -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ |
---|
468 | | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) |
---|
469 | x_libraries="$ac_optarg" ;; |
---|
470 | |
---|
471 | -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; } |
---|
472 | ;; |
---|
473 | |
---|
474 | *) |
---|
475 | if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then |
---|
476 | echo "configure: warning: $ac_option: invalid host type" 1>&2 |
---|
477 | fi |
---|
478 | if test "x$nonopt" != xNONE; then |
---|
479 | { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } |
---|
480 | fi |
---|
481 | nonopt="$ac_option" |
---|
482 | ;; |
---|
483 | |
---|
484 | esac |
---|
485 | done |
---|
486 | |
---|
487 | if test -n "$ac_prev"; then |
---|
488 | { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; } |
---|
489 | fi |
---|
490 | |
---|
491 | trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 |
---|
492 | |
---|
493 | # File descriptor usage: |
---|
494 | # 0 standard input |
---|
495 | # 1 file creation |
---|
496 | # 2 errors and warnings |
---|
497 | # 3 some systems may open it to /dev/tty |
---|
498 | # 4 used on the Kubota Titan |
---|
499 | # 6 checking for... messages and results |
---|
500 | # 5 compiler messages saved in config.log |
---|
501 | if test "$silent" = yes; then |
---|
502 | exec 6>/dev/null |
---|
503 | else |
---|
504 | exec 6>&1 |
---|
505 | fi |
---|
506 | exec 5>./config.log |
---|
507 | |
---|
508 | echo "\ |
---|
509 | This file contains any messages produced by compilers while |
---|
510 | running configure, to aid debugging if configure makes a mistake. |
---|
511 | " 1>&5 |
---|
512 | |
---|
513 | # Strip out --no-create and --no-recursion so they do not pile up. |
---|
514 | # Also quote any args containing shell metacharacters. |
---|
515 | ac_configure_args= |
---|
516 | for ac_arg |
---|
517 | do |
---|
518 | case "$ac_arg" in |
---|
519 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ |
---|
520 | | --no-cr | --no-c) ;; |
---|
521 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ |
---|
522 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;; |
---|
523 | *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*) |
---|
524 | ac_configure_args="$ac_configure_args '$ac_arg'" ;; |
---|
525 | *) ac_configure_args="$ac_configure_args $ac_arg" ;; |
---|
526 | esac |
---|
527 | done |
---|
528 | |
---|
529 | # NLS nuisances. |
---|
530 | # Only set these to C if already set. These must not be set unconditionally |
---|
531 | # because not all systems understand e.g. LANG=C (notably SCO). |
---|
532 | # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'! |
---|
533 | # Non-C LC_CTYPE values break the ctype check. |
---|
534 | if test "${LANG+set}" = set; then LANG=C; export LANG; fi |
---|
535 | if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi |
---|
536 | if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi |
---|
537 | if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi |
---|
538 | |
---|
539 | # confdefs.h avoids OS command line length limits that DEFS can exceed. |
---|
540 | rm -rf conftest* confdefs.h |
---|
541 | # AIX cpp loses on an empty file, so make sure it contains at least a newline. |
---|
542 | echo > confdefs.h |
---|
543 | |
---|
544 | # A filename unique to this package, relative to the directory that |
---|
545 | # configure is in, which we can look for to find out if srcdir is correct. |
---|
546 | ac_unique_file=readline.h |
---|
547 | |
---|
548 | # Find the source files, if location was not specified. |
---|
549 | if test -z "$srcdir"; then |
---|
550 | ac_srcdir_defaulted=yes |
---|
551 | # Try the directory containing this script, then its parent. |
---|
552 | ac_prog=$0 |
---|
553 | ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'` |
---|
554 | test "x$ac_confdir" = "x$ac_prog" && ac_confdir=. |
---|
555 | srcdir=$ac_confdir |
---|
556 | if test ! -r $srcdir/$ac_unique_file; then |
---|
557 | srcdir=.. |
---|
558 | fi |
---|
559 | else |
---|
560 | ac_srcdir_defaulted=no |
---|
561 | fi |
---|
562 | if test ! -r $srcdir/$ac_unique_file; then |
---|
563 | if test "$ac_srcdir_defaulted" = yes; then |
---|
564 | { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; } |
---|
565 | else |
---|
566 | { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; } |
---|
567 | fi |
---|
568 | fi |
---|
569 | srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'` |
---|
570 | |
---|
571 | # Prefer explicitly selected file to automatically selected ones. |
---|
572 | if test -z "$CONFIG_SITE"; then |
---|
573 | if test "x$prefix" != xNONE; then |
---|
574 | CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site" |
---|
575 | else |
---|
576 | CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site" |
---|
577 | fi |
---|
578 | fi |
---|
579 | for ac_site_file in $CONFIG_SITE; do |
---|
580 | if test -r "$ac_site_file"; then |
---|
581 | echo "loading site script $ac_site_file" |
---|
582 | . "$ac_site_file" |
---|
583 | fi |
---|
584 | done |
---|
585 | |
---|
586 | if test -r "$cache_file"; then |
---|
587 | echo "loading cache $cache_file" |
---|
588 | . $cache_file |
---|
589 | else |
---|
590 | echo "creating cache $cache_file" |
---|
591 | > $cache_file |
---|
592 | fi |
---|
593 | |
---|
594 | ac_ext=c |
---|
595 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. |
---|
596 | ac_cpp='$CPP $CPPFLAGS' |
---|
597 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' |
---|
598 | ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' |
---|
599 | cross_compiling=$ac_cv_prog_cc_cross |
---|
600 | |
---|
601 | if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then |
---|
602 | # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu. |
---|
603 | if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then |
---|
604 | ac_n= ac_c=' |
---|
605 | ' ac_t=' ' |
---|
606 | else |
---|
607 | ac_n=-n ac_c= ac_t= |
---|
608 | fi |
---|
609 | else |
---|
610 | ac_n= ac_c='\c' ac_t= |
---|
611 | fi |
---|
612 | |
---|
613 | |
---|
614 | |
---|
615 | |
---|
616 | |
---|
617 | |
---|
618 | ac_aux_dir= |
---|
619 | for ac_dir in ./support $srcdir/./support; do |
---|
620 | if test -f $ac_dir/install-sh; then |
---|
621 | ac_aux_dir=$ac_dir |
---|
622 | ac_install_sh="$ac_aux_dir/install-sh -c" |
---|
623 | break |
---|
624 | elif test -f $ac_dir/install.sh; then |
---|
625 | ac_aux_dir=$ac_dir |
---|
626 | ac_install_sh="$ac_aux_dir/install.sh -c" |
---|
627 | break |
---|
628 | fi |
---|
629 | done |
---|
630 | if test -z "$ac_aux_dir"; then |
---|
631 | { echo "configure: error: can not find install-sh or install.sh in ./support $srcdir/./support" 1>&2; exit 1; } |
---|
632 | fi |
---|
633 | ac_config_guess=$ac_aux_dir/config.guess |
---|
634 | ac_config_sub=$ac_aux_dir/config.sub |
---|
635 | ac_configure=$ac_aux_dir/configure # This should be Cygnus configure. |
---|
636 | |
---|
637 | |
---|
638 | |
---|
639 | # Make sure we can run config.sub. |
---|
640 | if $ac_config_sub sun4 >/dev/null 2>&1; then : |
---|
641 | else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; } |
---|
642 | fi |
---|
643 | |
---|
644 | echo $ac_n "checking host system type""... $ac_c" 1>&6 |
---|
645 | echo "configure:646: checking host system type" >&5 |
---|
646 | |
---|
647 | host_alias=$host |
---|
648 | case "$host_alias" in |
---|
649 | NONE) |
---|
650 | case $nonopt in |
---|
651 | NONE) |
---|
652 | if host_alias=`$ac_config_guess`; then : |
---|
653 | else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; } |
---|
654 | fi ;; |
---|
655 | *) host_alias=$nonopt ;; |
---|
656 | esac ;; |
---|
657 | esac |
---|
658 | |
---|
659 | host=`$ac_config_sub $host_alias` |
---|
660 | host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` |
---|
661 | host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` |
---|
662 | host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` |
---|
663 | echo "$ac_t""$host" 1>&6 |
---|
664 | |
---|
665 | |
---|
666 | opt_curses=no |
---|
667 | opt_shared=no |
---|
668 | |
---|
669 | # Check whether --with-curses or --without-curses was given. |
---|
670 | if test "${with_curses+set}" = set; then |
---|
671 | withval="$with_curses" |
---|
672 | opt_curses=$withval |
---|
673 | fi |
---|
674 | |
---|
675 | |
---|
676 | if test "$opt_curses" = "yes"; then |
---|
677 | prefer_curses=yes |
---|
678 | fi |
---|
679 | |
---|
680 | # We want these before the checks, so the checks can modify their values. |
---|
681 | test -z "$CFLAGS" && CFLAGS=-g auto_cflags=1 |
---|
682 | |
---|
683 | # Extract the first word of "gcc", so it can be a program name with args. |
---|
684 | set dummy gcc; ac_word=$2 |
---|
685 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
---|
686 | echo "configure:687: checking for $ac_word" >&5 |
---|
687 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
---|
688 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
689 | else |
---|
690 | if test -n "$CC"; then |
---|
691 | ac_cv_prog_CC="$CC" # Let the user override the test. |
---|
692 | else |
---|
693 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" |
---|
694 | for ac_dir in $PATH; do |
---|
695 | test -z "$ac_dir" && ac_dir=. |
---|
696 | if test -f $ac_dir/$ac_word; then |
---|
697 | ac_cv_prog_CC="gcc" |
---|
698 | break |
---|
699 | fi |
---|
700 | done |
---|
701 | IFS="$ac_save_ifs" |
---|
702 | fi |
---|
703 | fi |
---|
704 | CC="$ac_cv_prog_CC" |
---|
705 | if test -n "$CC"; then |
---|
706 | echo "$ac_t""$CC" 1>&6 |
---|
707 | else |
---|
708 | echo "$ac_t""no" 1>&6 |
---|
709 | fi |
---|
710 | |
---|
711 | if test -z "$CC"; then |
---|
712 | # Extract the first word of "cc", so it can be a program name with args. |
---|
713 | set dummy cc; ac_word=$2 |
---|
714 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
---|
715 | echo "configure:716: checking for $ac_word" >&5 |
---|
716 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
---|
717 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
718 | else |
---|
719 | if test -n "$CC"; then |
---|
720 | ac_cv_prog_CC="$CC" # Let the user override the test. |
---|
721 | else |
---|
722 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" |
---|
723 | ac_prog_rejected=no |
---|
724 | for ac_dir in $PATH; do |
---|
725 | test -z "$ac_dir" && ac_dir=. |
---|
726 | if test -f $ac_dir/$ac_word; then |
---|
727 | if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then |
---|
728 | ac_prog_rejected=yes |
---|
729 | continue |
---|
730 | fi |
---|
731 | ac_cv_prog_CC="cc" |
---|
732 | break |
---|
733 | fi |
---|
734 | done |
---|
735 | IFS="$ac_save_ifs" |
---|
736 | if test $ac_prog_rejected = yes; then |
---|
737 | # We found a bogon in the path, so make sure we never use it. |
---|
738 | set dummy $ac_cv_prog_CC |
---|
739 | shift |
---|
740 | if test $# -gt 0; then |
---|
741 | # We chose a different compiler from the bogus one. |
---|
742 | # However, it has the same basename, so the bogon will be chosen |
---|
743 | # first if we set CC to just the basename; use the full file name. |
---|
744 | shift |
---|
745 | set dummy "$ac_dir/$ac_word" "$@" |
---|
746 | shift |
---|
747 | ac_cv_prog_CC="$@" |
---|
748 | fi |
---|
749 | fi |
---|
750 | fi |
---|
751 | fi |
---|
752 | CC="$ac_cv_prog_CC" |
---|
753 | if test -n "$CC"; then |
---|
754 | echo "$ac_t""$CC" 1>&6 |
---|
755 | else |
---|
756 | echo "$ac_t""no" 1>&6 |
---|
757 | fi |
---|
758 | |
---|
759 | test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; } |
---|
760 | fi |
---|
761 | |
---|
762 | echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 |
---|
763 | echo "configure:764: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 |
---|
764 | |
---|
765 | ac_ext=c |
---|
766 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. |
---|
767 | ac_cpp='$CPP $CPPFLAGS' |
---|
768 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' |
---|
769 | ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' |
---|
770 | cross_compiling=$ac_cv_prog_cc_cross |
---|
771 | |
---|
772 | cat > conftest.$ac_ext <<EOF |
---|
773 | #line 774 "configure" |
---|
774 | #include "confdefs.h" |
---|
775 | main(){return(0);} |
---|
776 | EOF |
---|
777 | if { (eval echo configure:778: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
---|
778 | ac_cv_prog_cc_works=yes |
---|
779 | # If we can't run a trivial program, we are probably using a cross compiler. |
---|
780 | if (./conftest; exit) 2>/dev/null; then |
---|
781 | ac_cv_prog_cc_cross=no |
---|
782 | else |
---|
783 | ac_cv_prog_cc_cross=yes |
---|
784 | fi |
---|
785 | else |
---|
786 | echo "configure: failed program was:" >&5 |
---|
787 | cat conftest.$ac_ext >&5 |
---|
788 | ac_cv_prog_cc_works=no |
---|
789 | fi |
---|
790 | rm -fr conftest* |
---|
791 | |
---|
792 | echo "$ac_t""$ac_cv_prog_cc_works" 1>&6 |
---|
793 | if test $ac_cv_prog_cc_works = no; then |
---|
794 | { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; } |
---|
795 | fi |
---|
796 | echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 |
---|
797 | echo "configure:798: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 |
---|
798 | echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6 |
---|
799 | cross_compiling=$ac_cv_prog_cc_cross |
---|
800 | |
---|
801 | echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6 |
---|
802 | echo "configure:803: checking whether we are using GNU C" >&5 |
---|
803 | if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then |
---|
804 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
805 | else |
---|
806 | cat > conftest.c <<EOF |
---|
807 | #ifdef __GNUC__ |
---|
808 | yes; |
---|
809 | #endif |
---|
810 | EOF |
---|
811 | if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:812: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then |
---|
812 | ac_cv_prog_gcc=yes |
---|
813 | else |
---|
814 | ac_cv_prog_gcc=no |
---|
815 | fi |
---|
816 | fi |
---|
817 | |
---|
818 | echo "$ac_t""$ac_cv_prog_gcc" 1>&6 |
---|
819 | |
---|
820 | if test $ac_cv_prog_gcc = yes; then |
---|
821 | GCC=yes |
---|
822 | ac_test_CFLAGS="${CFLAGS+set}" |
---|
823 | ac_save_CFLAGS="$CFLAGS" |
---|
824 | CFLAGS= |
---|
825 | echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 |
---|
826 | echo "configure:827: checking whether ${CC-cc} accepts -g" >&5 |
---|
827 | if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then |
---|
828 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
829 | else |
---|
830 | echo 'void f(){}' > conftest.c |
---|
831 | if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then |
---|
832 | ac_cv_prog_cc_g=yes |
---|
833 | else |
---|
834 | ac_cv_prog_cc_g=no |
---|
835 | fi |
---|
836 | rm -f conftest* |
---|
837 | |
---|
838 | fi |
---|
839 | |
---|
840 | echo "$ac_t""$ac_cv_prog_cc_g" 1>&6 |
---|
841 | if test "$ac_test_CFLAGS" = set; then |
---|
842 | CFLAGS="$ac_save_CFLAGS" |
---|
843 | elif test $ac_cv_prog_cc_g = yes; then |
---|
844 | CFLAGS="-g -O2" |
---|
845 | else |
---|
846 | CFLAGS="-O2" |
---|
847 | fi |
---|
848 | else |
---|
849 | GCC= |
---|
850 | test "${CFLAGS+set}" = set || CFLAGS="-g" |
---|
851 | fi |
---|
852 | |
---|
853 | echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6 |
---|
854 | echo "configure:855: checking how to run the C preprocessor" >&5 |
---|
855 | # On Suns, sometimes $CPP names a directory. |
---|
856 | if test -n "$CPP" && test -d "$CPP"; then |
---|
857 | CPP= |
---|
858 | fi |
---|
859 | if test -z "$CPP"; then |
---|
860 | if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then |
---|
861 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
862 | else |
---|
863 | # This must be in double quotes, not single quotes, because CPP may get |
---|
864 | # substituted into the Makefile and "${CC-cc}" will confuse make. |
---|
865 | CPP="${CC-cc} -E" |
---|
866 | # On the NeXT, cc -E runs the code through the compiler's parser, |
---|
867 | # not just through cpp. |
---|
868 | cat > conftest.$ac_ext <<EOF |
---|
869 | #line 870 "configure" |
---|
870 | #include "confdefs.h" |
---|
871 | #include <assert.h> |
---|
872 | Syntax Error |
---|
873 | EOF |
---|
874 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
---|
875 | { (eval echo configure:876: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
---|
876 | ac_err=`grep -v '^ *+' conftest.out` |
---|
877 | if test -z "$ac_err"; then |
---|
878 | : |
---|
879 | else |
---|
880 | echo "$ac_err" >&5 |
---|
881 | echo "configure: failed program was:" >&5 |
---|
882 | cat conftest.$ac_ext >&5 |
---|
883 | rm -rf conftest* |
---|
884 | CPP="${CC-cc} -E -traditional-cpp" |
---|
885 | cat > conftest.$ac_ext <<EOF |
---|
886 | #line 887 "configure" |
---|
887 | #include "confdefs.h" |
---|
888 | #include <assert.h> |
---|
889 | Syntax Error |
---|
890 | EOF |
---|
891 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
---|
892 | { (eval echo configure:893: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
---|
893 | ac_err=`grep -v '^ *+' conftest.out` |
---|
894 | if test -z "$ac_err"; then |
---|
895 | : |
---|
896 | else |
---|
897 | echo "$ac_err" >&5 |
---|
898 | echo "configure: failed program was:" >&5 |
---|
899 | cat conftest.$ac_ext >&5 |
---|
900 | rm -rf conftest* |
---|
901 | CPP=/lib/cpp |
---|
902 | fi |
---|
903 | rm -f conftest* |
---|
904 | fi |
---|
905 | rm -f conftest* |
---|
906 | ac_cv_prog_CPP="$CPP" |
---|
907 | fi |
---|
908 | CPP="$ac_cv_prog_CPP" |
---|
909 | else |
---|
910 | ac_cv_prog_CPP="$CPP" |
---|
911 | fi |
---|
912 | echo "$ac_t""$CPP" 1>&6 |
---|
913 | |
---|
914 | ac_safe=`echo "minix/config.h" | sed 'y%./+-%__p_%'` |
---|
915 | echo $ac_n "checking for minix/config.h""... $ac_c" 1>&6 |
---|
916 | echo "configure:917: checking for minix/config.h" >&5 |
---|
917 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
---|
918 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
919 | else |
---|
920 | cat > conftest.$ac_ext <<EOF |
---|
921 | #line 922 "configure" |
---|
922 | #include "confdefs.h" |
---|
923 | #include <minix/config.h> |
---|
924 | EOF |
---|
925 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
---|
926 | { (eval echo configure:927: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
---|
927 | ac_err=`grep -v '^ *+' conftest.out` |
---|
928 | if test -z "$ac_err"; then |
---|
929 | rm -rf conftest* |
---|
930 | eval "ac_cv_header_$ac_safe=yes" |
---|
931 | else |
---|
932 | echo "$ac_err" >&5 |
---|
933 | echo "configure: failed program was:" >&5 |
---|
934 | cat conftest.$ac_ext >&5 |
---|
935 | rm -rf conftest* |
---|
936 | eval "ac_cv_header_$ac_safe=no" |
---|
937 | fi |
---|
938 | rm -f conftest* |
---|
939 | fi |
---|
940 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
---|
941 | echo "$ac_t""yes" 1>&6 |
---|
942 | MINIX=yes |
---|
943 | else |
---|
944 | echo "$ac_t""no" 1>&6 |
---|
945 | MINIX= |
---|
946 | fi |
---|
947 | |
---|
948 | if test "$MINIX" = yes; then |
---|
949 | cat >> confdefs.h <<\EOF |
---|
950 | #define _POSIX_SOURCE 1 |
---|
951 | EOF |
---|
952 | |
---|
953 | cat >> confdefs.h <<\EOF |
---|
954 | #define _POSIX_1_SOURCE 2 |
---|
955 | EOF |
---|
956 | |
---|
957 | cat >> confdefs.h <<\EOF |
---|
958 | #define _MINIX 1 |
---|
959 | EOF |
---|
960 | |
---|
961 | fi |
---|
962 | |
---|
963 | |
---|
964 | # If we're using gcc and the user hasn't specified CFLAGS, add -O to CFLAGS. |
---|
965 | test -n "$GCC" && test -n "$auto_cflags" && CFLAGS="$CFLAGS -O" |
---|
966 | |
---|
967 | if test $ac_cv_prog_gcc = yes; then |
---|
968 | echo $ac_n "checking whether ${CC-cc} needs -traditional""... $ac_c" 1>&6 |
---|
969 | echo "configure:970: checking whether ${CC-cc} needs -traditional" >&5 |
---|
970 | if eval "test \"`echo '$''{'ac_cv_prog_gcc_traditional'+set}'`\" = set"; then |
---|
971 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
972 | else |
---|
973 | ac_pattern="Autoconf.*'x'" |
---|
974 | cat > conftest.$ac_ext <<EOF |
---|
975 | #line 976 "configure" |
---|
976 | #include "confdefs.h" |
---|
977 | #include <sgtty.h> |
---|
978 | Autoconf TIOCGETP |
---|
979 | EOF |
---|
980 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
---|
981 | egrep "$ac_pattern" >/dev/null 2>&1; then |
---|
982 | rm -rf conftest* |
---|
983 | ac_cv_prog_gcc_traditional=yes |
---|
984 | else |
---|
985 | rm -rf conftest* |
---|
986 | ac_cv_prog_gcc_traditional=no |
---|
987 | fi |
---|
988 | rm -f conftest* |
---|
989 | |
---|
990 | |
---|
991 | if test $ac_cv_prog_gcc_traditional = no; then |
---|
992 | cat > conftest.$ac_ext <<EOF |
---|
993 | #line 994 "configure" |
---|
994 | #include "confdefs.h" |
---|
995 | #include <termio.h> |
---|
996 | Autoconf TCGETA |
---|
997 | EOF |
---|
998 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
---|
999 | egrep "$ac_pattern" >/dev/null 2>&1; then |
---|
1000 | rm -rf conftest* |
---|
1001 | ac_cv_prog_gcc_traditional=yes |
---|
1002 | fi |
---|
1003 | rm -f conftest* |
---|
1004 | |
---|
1005 | fi |
---|
1006 | fi |
---|
1007 | |
---|
1008 | echo "$ac_t""$ac_cv_prog_gcc_traditional" 1>&6 |
---|
1009 | if test $ac_cv_prog_gcc_traditional = yes; then |
---|
1010 | CC="$CC -traditional" |
---|
1011 | fi |
---|
1012 | fi |
---|
1013 | |
---|
1014 | # Find a good install program. We prefer a C program (faster), |
---|
1015 | # so one script is as good as another. But avoid the broken or |
---|
1016 | # incompatible versions: |
---|
1017 | # SysV /etc/install, /usr/sbin/install |
---|
1018 | # SunOS /usr/etc/install |
---|
1019 | # IRIX /sbin/install |
---|
1020 | # AIX /bin/install |
---|
1021 | # AFS /usr/afsws/bin/install, which mishandles nonexistent args |
---|
1022 | # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" |
---|
1023 | # ./install, which can be erroneously created by make from ./install.sh. |
---|
1024 | echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6 |
---|
1025 | echo "configure:1026: checking for a BSD compatible install" >&5 |
---|
1026 | if test -z "$INSTALL"; then |
---|
1027 | if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then |
---|
1028 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1029 | else |
---|
1030 | IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="${IFS}:" |
---|
1031 | for ac_dir in $PATH; do |
---|
1032 | # Account for people who put trailing slashes in PATH elements. |
---|
1033 | case "$ac_dir/" in |
---|
1034 | /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;; |
---|
1035 | *) |
---|
1036 | # OSF1 and SCO ODT 3.0 have their own names for install. |
---|
1037 | for ac_prog in ginstall installbsd scoinst install; do |
---|
1038 | if test -f $ac_dir/$ac_prog; then |
---|
1039 | if test $ac_prog = install && |
---|
1040 | grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then |
---|
1041 | # AIX install. It has an incompatible calling convention. |
---|
1042 | # OSF/1 installbsd also uses dspmsg, but is usable. |
---|
1043 | : |
---|
1044 | else |
---|
1045 | ac_cv_path_install="$ac_dir/$ac_prog -c" |
---|
1046 | break 2 |
---|
1047 | fi |
---|
1048 | fi |
---|
1049 | done |
---|
1050 | ;; |
---|
1051 | esac |
---|
1052 | done |
---|
1053 | IFS="$ac_save_IFS" |
---|
1054 | |
---|
1055 | fi |
---|
1056 | if test "${ac_cv_path_install+set}" = set; then |
---|
1057 | INSTALL="$ac_cv_path_install" |
---|
1058 | else |
---|
1059 | # As a last resort, use the slow shell script. We don't cache a |
---|
1060 | # path for INSTALL within a source directory, because that will |
---|
1061 | # break other packages using the cache if that directory is |
---|
1062 | # removed, or if the path is relative. |
---|
1063 | INSTALL="$ac_install_sh" |
---|
1064 | fi |
---|
1065 | fi |
---|
1066 | echo "$ac_t""$INSTALL" 1>&6 |
---|
1067 | |
---|
1068 | # Use test -z because SunOS4 sh mishandles braces in ${var-val}. |
---|
1069 | # It thinks the first close brace ends the variable substitution. |
---|
1070 | test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' |
---|
1071 | |
---|
1072 | test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' |
---|
1073 | |
---|
1074 | # Extract the first word of "ar", so it can be a program name with args. |
---|
1075 | set dummy ar; ac_word=$2 |
---|
1076 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
---|
1077 | echo "configure:1078: checking for $ac_word" >&5 |
---|
1078 | if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then |
---|
1079 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1080 | else |
---|
1081 | if test -n "$AR"; then |
---|
1082 | ac_cv_prog_AR="$AR" # Let the user override the test. |
---|
1083 | else |
---|
1084 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" |
---|
1085 | for ac_dir in $PATH; do |
---|
1086 | test -z "$ac_dir" && ac_dir=. |
---|
1087 | if test -f $ac_dir/$ac_word; then |
---|
1088 | ac_cv_prog_AR="ar" |
---|
1089 | break |
---|
1090 | fi |
---|
1091 | done |
---|
1092 | IFS="$ac_save_ifs" |
---|
1093 | fi |
---|
1094 | fi |
---|
1095 | AR="$ac_cv_prog_AR" |
---|
1096 | if test -n "$AR"; then |
---|
1097 | echo "$ac_t""$AR" 1>&6 |
---|
1098 | else |
---|
1099 | echo "$ac_t""no" 1>&6 |
---|
1100 | fi |
---|
1101 | |
---|
1102 | test -n "$ARFLAGS" || ARFLAGS="cr" |
---|
1103 | # Extract the first word of "ranlib", so it can be a program name with args. |
---|
1104 | set dummy ranlib; ac_word=$2 |
---|
1105 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
---|
1106 | echo "configure:1107: checking for $ac_word" >&5 |
---|
1107 | if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then |
---|
1108 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1109 | else |
---|
1110 | if test -n "$RANLIB"; then |
---|
1111 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. |
---|
1112 | else |
---|
1113 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" |
---|
1114 | for ac_dir in $PATH; do |
---|
1115 | test -z "$ac_dir" && ac_dir=. |
---|
1116 | if test -f $ac_dir/$ac_word; then |
---|
1117 | ac_cv_prog_RANLIB="ranlib" |
---|
1118 | break |
---|
1119 | fi |
---|
1120 | done |
---|
1121 | IFS="$ac_save_ifs" |
---|
1122 | test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":" |
---|
1123 | fi |
---|
1124 | fi |
---|
1125 | RANLIB="$ac_cv_prog_RANLIB" |
---|
1126 | if test -n "$RANLIB"; then |
---|
1127 | echo "$ac_t""$RANLIB" 1>&6 |
---|
1128 | else |
---|
1129 | echo "$ac_t""no" 1>&6 |
---|
1130 | fi |
---|
1131 | |
---|
1132 | |
---|
1133 | MAKE_SHELL=/bin/sh |
---|
1134 | |
---|
1135 | |
---|
1136 | echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6 |
---|
1137 | echo "configure:1138: checking return type of signal handlers" >&5 |
---|
1138 | if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then |
---|
1139 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1140 | else |
---|
1141 | cat > conftest.$ac_ext <<EOF |
---|
1142 | #line 1143 "configure" |
---|
1143 | #include "confdefs.h" |
---|
1144 | #include <sys/types.h> |
---|
1145 | #include <signal.h> |
---|
1146 | #ifdef signal |
---|
1147 | #undef signal |
---|
1148 | #endif |
---|
1149 | #ifdef __cplusplus |
---|
1150 | extern "C" void (*signal (int, void (*)(int)))(int); |
---|
1151 | #else |
---|
1152 | void (*signal ()) (); |
---|
1153 | #endif |
---|
1154 | |
---|
1155 | int main() { |
---|
1156 | int i; |
---|
1157 | ; return 0; } |
---|
1158 | EOF |
---|
1159 | if { (eval echo configure:1160: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
---|
1160 | rm -rf conftest* |
---|
1161 | ac_cv_type_signal=void |
---|
1162 | else |
---|
1163 | echo "configure: failed program was:" >&5 |
---|
1164 | cat conftest.$ac_ext >&5 |
---|
1165 | rm -rf conftest* |
---|
1166 | ac_cv_type_signal=int |
---|
1167 | fi |
---|
1168 | rm -f conftest* |
---|
1169 | fi |
---|
1170 | |
---|
1171 | echo "$ac_t""$ac_cv_type_signal" 1>&6 |
---|
1172 | cat >> confdefs.h <<EOF |
---|
1173 | #define RETSIGTYPE $ac_cv_type_signal |
---|
1174 | EOF |
---|
1175 | |
---|
1176 | |
---|
1177 | |
---|
1178 | echo $ac_n "checking whether stat file-mode macros are broken""... $ac_c" 1>&6 |
---|
1179 | echo "configure:1180: checking whether stat file-mode macros are broken" >&5 |
---|
1180 | if eval "test \"`echo '$''{'ac_cv_header_stat_broken'+set}'`\" = set"; then |
---|
1181 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1182 | else |
---|
1183 | cat > conftest.$ac_ext <<EOF |
---|
1184 | #line 1185 "configure" |
---|
1185 | #include "confdefs.h" |
---|
1186 | #include <sys/types.h> |
---|
1187 | #include <sys/stat.h> |
---|
1188 | |
---|
1189 | #if defined(S_ISBLK) && defined(S_IFDIR) |
---|
1190 | # if S_ISBLK (S_IFDIR) |
---|
1191 | You lose. |
---|
1192 | # endif |
---|
1193 | #endif |
---|
1194 | |
---|
1195 | #if defined(S_ISBLK) && defined(S_IFCHR) |
---|
1196 | # if S_ISBLK (S_IFCHR) |
---|
1197 | You lose. |
---|
1198 | # endif |
---|
1199 | #endif |
---|
1200 | |
---|
1201 | #if defined(S_ISLNK) && defined(S_IFREG) |
---|
1202 | # if S_ISLNK (S_IFREG) |
---|
1203 | You lose. |
---|
1204 | # endif |
---|
1205 | #endif |
---|
1206 | |
---|
1207 | #if defined(S_ISSOCK) && defined(S_IFREG) |
---|
1208 | # if S_ISSOCK (S_IFREG) |
---|
1209 | You lose. |
---|
1210 | # endif |
---|
1211 | #endif |
---|
1212 | |
---|
1213 | EOF |
---|
1214 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
---|
1215 | egrep "You lose" >/dev/null 2>&1; then |
---|
1216 | rm -rf conftest* |
---|
1217 | ac_cv_header_stat_broken=yes |
---|
1218 | else |
---|
1219 | rm -rf conftest* |
---|
1220 | ac_cv_header_stat_broken=no |
---|
1221 | fi |
---|
1222 | rm -f conftest* |
---|
1223 | |
---|
1224 | fi |
---|
1225 | |
---|
1226 | echo "$ac_t""$ac_cv_header_stat_broken" 1>&6 |
---|
1227 | if test $ac_cv_header_stat_broken = yes; then |
---|
1228 | cat >> confdefs.h <<\EOF |
---|
1229 | #define STAT_MACROS_BROKEN 1 |
---|
1230 | EOF |
---|
1231 | |
---|
1232 | fi |
---|
1233 | |
---|
1234 | ac_header_dirent=no |
---|
1235 | for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h |
---|
1236 | do |
---|
1237 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` |
---|
1238 | echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6 |
---|
1239 | echo "configure:1240: checking for $ac_hdr that defines DIR" >&5 |
---|
1240 | if eval "test \"`echo '$''{'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then |
---|
1241 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1242 | else |
---|
1243 | cat > conftest.$ac_ext <<EOF |
---|
1244 | #line 1245 "configure" |
---|
1245 | #include "confdefs.h" |
---|
1246 | #include <sys/types.h> |
---|
1247 | #include <$ac_hdr> |
---|
1248 | int main() { |
---|
1249 | DIR *dirp = 0; |
---|
1250 | ; return 0; } |
---|
1251 | EOF |
---|
1252 | if { (eval echo configure:1253: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
---|
1253 | rm -rf conftest* |
---|
1254 | eval "ac_cv_header_dirent_$ac_safe=yes" |
---|
1255 | else |
---|
1256 | echo "configure: failed program was:" >&5 |
---|
1257 | cat conftest.$ac_ext >&5 |
---|
1258 | rm -rf conftest* |
---|
1259 | eval "ac_cv_header_dirent_$ac_safe=no" |
---|
1260 | fi |
---|
1261 | rm -f conftest* |
---|
1262 | fi |
---|
1263 | if eval "test \"`echo '$ac_cv_header_dirent_'$ac_safe`\" = yes"; then |
---|
1264 | echo "$ac_t""yes" 1>&6 |
---|
1265 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` |
---|
1266 | cat >> confdefs.h <<EOF |
---|
1267 | #define $ac_tr_hdr 1 |
---|
1268 | EOF |
---|
1269 | ac_header_dirent=$ac_hdr; break |
---|
1270 | else |
---|
1271 | echo "$ac_t""no" 1>&6 |
---|
1272 | fi |
---|
1273 | done |
---|
1274 | # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. |
---|
1275 | if test $ac_header_dirent = dirent.h; then |
---|
1276 | echo $ac_n "checking for opendir in -ldir""... $ac_c" 1>&6 |
---|
1277 | echo "configure:1278: checking for opendir in -ldir" >&5 |
---|
1278 | ac_lib_var=`echo dir'_'opendir | sed 'y%./+-%__p_%'` |
---|
1279 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
---|
1280 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1281 | else |
---|
1282 | ac_save_LIBS="$LIBS" |
---|
1283 | LIBS="-ldir $LIBS" |
---|
1284 | cat > conftest.$ac_ext <<EOF |
---|
1285 | #line 1286 "configure" |
---|
1286 | #include "confdefs.h" |
---|
1287 | /* Override any gcc2 internal prototype to avoid an error. */ |
---|
1288 | /* We use char because int might match the return type of a gcc2 |
---|
1289 | builtin and then its argument prototype would still apply. */ |
---|
1290 | char opendir(); |
---|
1291 | |
---|
1292 | int main() { |
---|
1293 | opendir() |
---|
1294 | ; return 0; } |
---|
1295 | EOF |
---|
1296 | if { (eval echo configure:1297: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
---|
1297 | rm -rf conftest* |
---|
1298 | eval "ac_cv_lib_$ac_lib_var=yes" |
---|
1299 | else |
---|
1300 | echo "configure: failed program was:" >&5 |
---|
1301 | cat conftest.$ac_ext >&5 |
---|
1302 | rm -rf conftest* |
---|
1303 | eval "ac_cv_lib_$ac_lib_var=no" |
---|
1304 | fi |
---|
1305 | rm -f conftest* |
---|
1306 | LIBS="$ac_save_LIBS" |
---|
1307 | |
---|
1308 | fi |
---|
1309 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
---|
1310 | echo "$ac_t""yes" 1>&6 |
---|
1311 | LIBS="$LIBS -ldir" |
---|
1312 | else |
---|
1313 | echo "$ac_t""no" 1>&6 |
---|
1314 | fi |
---|
1315 | |
---|
1316 | else |
---|
1317 | echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6 |
---|
1318 | echo "configure:1319: checking for opendir in -lx" >&5 |
---|
1319 | ac_lib_var=`echo x'_'opendir | sed 'y%./+-%__p_%'` |
---|
1320 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
---|
1321 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1322 | else |
---|
1323 | ac_save_LIBS="$LIBS" |
---|
1324 | LIBS="-lx $LIBS" |
---|
1325 | cat > conftest.$ac_ext <<EOF |
---|
1326 | #line 1327 "configure" |
---|
1327 | #include "confdefs.h" |
---|
1328 | /* Override any gcc2 internal prototype to avoid an error. */ |
---|
1329 | /* We use char because int might match the return type of a gcc2 |
---|
1330 | builtin and then its argument prototype would still apply. */ |
---|
1331 | char opendir(); |
---|
1332 | |
---|
1333 | int main() { |
---|
1334 | opendir() |
---|
1335 | ; return 0; } |
---|
1336 | EOF |
---|
1337 | if { (eval echo configure:1338: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
---|
1338 | rm -rf conftest* |
---|
1339 | eval "ac_cv_lib_$ac_lib_var=yes" |
---|
1340 | else |
---|
1341 | echo "configure: failed program was:" >&5 |
---|
1342 | cat conftest.$ac_ext >&5 |
---|
1343 | rm -rf conftest* |
---|
1344 | eval "ac_cv_lib_$ac_lib_var=no" |
---|
1345 | fi |
---|
1346 | rm -f conftest* |
---|
1347 | LIBS="$ac_save_LIBS" |
---|
1348 | |
---|
1349 | fi |
---|
1350 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
---|
1351 | echo "$ac_t""yes" 1>&6 |
---|
1352 | LIBS="$LIBS -lx" |
---|
1353 | else |
---|
1354 | echo "$ac_t""no" 1>&6 |
---|
1355 | fi |
---|
1356 | |
---|
1357 | fi |
---|
1358 | |
---|
1359 | |
---|
1360 | for ac_func in strcasecmp select setenv putenv tcgetattr setlocale lstat |
---|
1361 | do |
---|
1362 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
---|
1363 | echo "configure:1364: checking for $ac_func" >&5 |
---|
1364 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
---|
1365 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1366 | else |
---|
1367 | cat > conftest.$ac_ext <<EOF |
---|
1368 | #line 1369 "configure" |
---|
1369 | #include "confdefs.h" |
---|
1370 | /* System header to define __stub macros and hopefully few prototypes, |
---|
1371 | which can conflict with char $ac_func(); below. */ |
---|
1372 | #include <assert.h> |
---|
1373 | /* Override any gcc2 internal prototype to avoid an error. */ |
---|
1374 | /* We use char because int might match the return type of a gcc2 |
---|
1375 | builtin and then its argument prototype would still apply. */ |
---|
1376 | char $ac_func(); |
---|
1377 | |
---|
1378 | int main() { |
---|
1379 | |
---|
1380 | /* The GNU C library defines this for functions which it implements |
---|
1381 | to always fail with ENOSYS. Some functions are actually named |
---|
1382 | something starting with __ and the normal name is an alias. */ |
---|
1383 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
---|
1384 | choke me |
---|
1385 | #else |
---|
1386 | $ac_func(); |
---|
1387 | #endif |
---|
1388 | |
---|
1389 | ; return 0; } |
---|
1390 | EOF |
---|
1391 | if { (eval echo configure:1392: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
---|
1392 | rm -rf conftest* |
---|
1393 | eval "ac_cv_func_$ac_func=yes" |
---|
1394 | else |
---|
1395 | echo "configure: failed program was:" >&5 |
---|
1396 | cat conftest.$ac_ext >&5 |
---|
1397 | rm -rf conftest* |
---|
1398 | eval "ac_cv_func_$ac_func=no" |
---|
1399 | fi |
---|
1400 | rm -f conftest* |
---|
1401 | fi |
---|
1402 | |
---|
1403 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
---|
1404 | echo "$ac_t""yes" 1>&6 |
---|
1405 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
---|
1406 | cat >> confdefs.h <<EOF |
---|
1407 | #define $ac_tr_func 1 |
---|
1408 | EOF |
---|
1409 | |
---|
1410 | else |
---|
1411 | echo "$ac_t""no" 1>&6 |
---|
1412 | fi |
---|
1413 | done |
---|
1414 | |
---|
1415 | |
---|
1416 | echo $ac_n "checking for working strcoll""... $ac_c" 1>&6 |
---|
1417 | echo "configure:1418: checking for working strcoll" >&5 |
---|
1418 | if eval "test \"`echo '$''{'ac_cv_func_strcoll_works'+set}'`\" = set"; then |
---|
1419 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1420 | else |
---|
1421 | if test "$cross_compiling" = yes; then |
---|
1422 | ac_cv_func_strcoll_works=no |
---|
1423 | else |
---|
1424 | cat > conftest.$ac_ext <<EOF |
---|
1425 | #line 1426 "configure" |
---|
1426 | #include "confdefs.h" |
---|
1427 | #include <string.h> |
---|
1428 | main () |
---|
1429 | { |
---|
1430 | exit (strcoll ("abc", "def") >= 0 || |
---|
1431 | strcoll ("ABC", "DEF") >= 0 || |
---|
1432 | strcoll ("123", "456") >= 0); |
---|
1433 | } |
---|
1434 | EOF |
---|
1435 | if { (eval echo configure:1436: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null |
---|
1436 | then |
---|
1437 | ac_cv_func_strcoll_works=yes |
---|
1438 | else |
---|
1439 | echo "configure: failed program was:" >&5 |
---|
1440 | cat conftest.$ac_ext >&5 |
---|
1441 | rm -fr conftest* |
---|
1442 | ac_cv_func_strcoll_works=no |
---|
1443 | fi |
---|
1444 | rm -fr conftest* |
---|
1445 | fi |
---|
1446 | |
---|
1447 | fi |
---|
1448 | |
---|
1449 | echo "$ac_t""$ac_cv_func_strcoll_works" 1>&6 |
---|
1450 | if test $ac_cv_func_strcoll_works = yes; then |
---|
1451 | cat >> confdefs.h <<\EOF |
---|
1452 | #define HAVE_STRCOLL 1 |
---|
1453 | EOF |
---|
1454 | |
---|
1455 | fi |
---|
1456 | |
---|
1457 | |
---|
1458 | for ac_hdr in unistd.h stdlib.h varargs.h stdarg.h string.h \ |
---|
1459 | sys/ptem.h sys/pte.h sys/stream.h sys/select.h \ |
---|
1460 | termcap.h termios.h termio.h sys/file.h locale.h |
---|
1461 | do |
---|
1462 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` |
---|
1463 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 |
---|
1464 | echo "configure:1465: checking for $ac_hdr" >&5 |
---|
1465 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
---|
1466 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1467 | else |
---|
1468 | cat > conftest.$ac_ext <<EOF |
---|
1469 | #line 1470 "configure" |
---|
1470 | #include "confdefs.h" |
---|
1471 | #include <$ac_hdr> |
---|
1472 | EOF |
---|
1473 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
---|
1474 | { (eval echo configure:1475: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
---|
1475 | ac_err=`grep -v '^ *+' conftest.out` |
---|
1476 | if test -z "$ac_err"; then |
---|
1477 | rm -rf conftest* |
---|
1478 | eval "ac_cv_header_$ac_safe=yes" |
---|
1479 | else |
---|
1480 | echo "$ac_err" >&5 |
---|
1481 | echo "configure: failed program was:" >&5 |
---|
1482 | cat conftest.$ac_ext >&5 |
---|
1483 | rm -rf conftest* |
---|
1484 | eval "ac_cv_header_$ac_safe=no" |
---|
1485 | fi |
---|
1486 | rm -f conftest* |
---|
1487 | fi |
---|
1488 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
---|
1489 | echo "$ac_t""yes" 1>&6 |
---|
1490 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` |
---|
1491 | cat >> confdefs.h <<EOF |
---|
1492 | #define $ac_tr_hdr 1 |
---|
1493 | EOF |
---|
1494 | |
---|
1495 | else |
---|
1496 | echo "$ac_t""no" 1>&6 |
---|
1497 | fi |
---|
1498 | done |
---|
1499 | |
---|
1500 | |
---|
1501 | |
---|
1502 | echo $ac_n "checking for type of signal functions""... $ac_c" 1>&6 |
---|
1503 | echo "configure:1504: checking for type of signal functions" >&5 |
---|
1504 | if eval "test \"`echo '$''{'bash_cv_signal_vintage'+set}'`\" = set"; then |
---|
1505 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1506 | else |
---|
1507 | |
---|
1508 | cat > conftest.$ac_ext <<EOF |
---|
1509 | #line 1510 "configure" |
---|
1510 | #include "confdefs.h" |
---|
1511 | #include <signal.h> |
---|
1512 | int main() { |
---|
1513 | |
---|
1514 | sigset_t ss; |
---|
1515 | struct sigaction sa; |
---|
1516 | sigemptyset(&ss); sigsuspend(&ss); |
---|
1517 | sigaction(SIGINT, &sa, (struct sigaction *) 0); |
---|
1518 | sigprocmask(SIG_BLOCK, &ss, (sigset_t *) 0); |
---|
1519 | |
---|
1520 | ; return 0; } |
---|
1521 | EOF |
---|
1522 | if { (eval echo configure:1523: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
---|
1523 | rm -rf conftest* |
---|
1524 | bash_cv_signal_vintage=posix |
---|
1525 | else |
---|
1526 | echo "configure: failed program was:" >&5 |
---|
1527 | cat conftest.$ac_ext >&5 |
---|
1528 | rm -rf conftest* |
---|
1529 | |
---|
1530 | cat > conftest.$ac_ext <<EOF |
---|
1531 | #line 1532 "configure" |
---|
1532 | #include "confdefs.h" |
---|
1533 | #include <signal.h> |
---|
1534 | int main() { |
---|
1535 | |
---|
1536 | int mask = sigmask(SIGINT); |
---|
1537 | sigsetmask(mask); sigblock(mask); sigpause(mask); |
---|
1538 | |
---|
1539 | ; return 0; } |
---|
1540 | EOF |
---|
1541 | if { (eval echo configure:1542: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
---|
1542 | rm -rf conftest* |
---|
1543 | bash_cv_signal_vintage=4.2bsd |
---|
1544 | else |
---|
1545 | echo "configure: failed program was:" >&5 |
---|
1546 | cat conftest.$ac_ext >&5 |
---|
1547 | rm -rf conftest* |
---|
1548 | |
---|
1549 | cat > conftest.$ac_ext <<EOF |
---|
1550 | #line 1551 "configure" |
---|
1551 | #include "confdefs.h" |
---|
1552 | |
---|
1553 | #include <signal.h> |
---|
1554 | RETSIGTYPE foo() { } |
---|
1555 | int main() { |
---|
1556 | |
---|
1557 | int mask = sigmask(SIGINT); |
---|
1558 | sigset(SIGINT, foo); sigrelse(SIGINT); |
---|
1559 | sighold(SIGINT); sigpause(SIGINT); |
---|
1560 | |
---|
1561 | ; return 0; } |
---|
1562 | EOF |
---|
1563 | if { (eval echo configure:1564: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
---|
1564 | rm -rf conftest* |
---|
1565 | bash_cv_signal_vintage=svr3 |
---|
1566 | else |
---|
1567 | echo "configure: failed program was:" >&5 |
---|
1568 | cat conftest.$ac_ext >&5 |
---|
1569 | rm -rf conftest* |
---|
1570 | bash_cv_signal_vintage=v7 |
---|
1571 | |
---|
1572 | fi |
---|
1573 | rm -f conftest* |
---|
1574 | |
---|
1575 | fi |
---|
1576 | rm -f conftest* |
---|
1577 | |
---|
1578 | fi |
---|
1579 | rm -f conftest* |
---|
1580 | |
---|
1581 | fi |
---|
1582 | |
---|
1583 | echo "$ac_t""$bash_cv_signal_vintage" 1>&6 |
---|
1584 | if test "$bash_cv_signal_vintage" = posix; then |
---|
1585 | cat >> confdefs.h <<\EOF |
---|
1586 | #define HAVE_POSIX_SIGNALS 1 |
---|
1587 | EOF |
---|
1588 | |
---|
1589 | elif test "$bash_cv_signal_vintage" = "4.2bsd"; then |
---|
1590 | cat >> confdefs.h <<\EOF |
---|
1591 | #define HAVE_BSD_SIGNALS 1 |
---|
1592 | EOF |
---|
1593 | |
---|
1594 | elif test "$bash_cv_signal_vintage" = svr3; then |
---|
1595 | cat >> confdefs.h <<\EOF |
---|
1596 | #define HAVE_USG_SIGHOLD 1 |
---|
1597 | EOF |
---|
1598 | |
---|
1599 | fi |
---|
1600 | |
---|
1601 | |
---|
1602 | |
---|
1603 | echo $ac_n "checking if signal handlers must be reinstalled when invoked""... $ac_c" 1>&6 |
---|
1604 | echo "configure:1605: checking if signal handlers must be reinstalled when invoked" >&5 |
---|
1605 | if eval "test \"`echo '$''{'bash_cv_must_reinstall_sighandlers'+set}'`\" = set"; then |
---|
1606 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1607 | else |
---|
1608 | if test "$cross_compiling" = yes; then |
---|
1609 | echo "configure: warning: cannot check signal handling if cross compiling -- defaulting to no" 1>&2 |
---|
1610 | bash_cv_must_reinstall_sighandlers=no |
---|
1611 | |
---|
1612 | else |
---|
1613 | cat > conftest.$ac_ext <<EOF |
---|
1614 | #line 1615 "configure" |
---|
1615 | #include "confdefs.h" |
---|
1616 | |
---|
1617 | #include <signal.h> |
---|
1618 | #ifdef HAVE_UNISTD_H |
---|
1619 | #include <unistd.h> |
---|
1620 | #endif |
---|
1621 | |
---|
1622 | typedef RETSIGTYPE sigfunc(); |
---|
1623 | |
---|
1624 | int nsigint; |
---|
1625 | |
---|
1626 | #ifdef HAVE_POSIX_SIGNALS |
---|
1627 | sigfunc * |
---|
1628 | set_signal_handler(sig, handler) |
---|
1629 | int sig; |
---|
1630 | sigfunc *handler; |
---|
1631 | { |
---|
1632 | struct sigaction act, oact; |
---|
1633 | act.sa_handler = handler; |
---|
1634 | act.sa_flags = 0; |
---|
1635 | sigemptyset (&act.sa_mask); |
---|
1636 | sigemptyset (&oact.sa_mask); |
---|
1637 | sigaction (sig, &act, &oact); |
---|
1638 | return (oact.sa_handler); |
---|
1639 | } |
---|
1640 | #else |
---|
1641 | #define set_signal_handler(s, h) signal(s, h) |
---|
1642 | #endif |
---|
1643 | |
---|
1644 | RETSIGTYPE |
---|
1645 | sigint(s) |
---|
1646 | int s; |
---|
1647 | { |
---|
1648 | nsigint++; |
---|
1649 | } |
---|
1650 | |
---|
1651 | main() |
---|
1652 | { |
---|
1653 | nsigint = 0; |
---|
1654 | set_signal_handler(SIGINT, sigint); |
---|
1655 | kill((int)getpid(), SIGINT); |
---|
1656 | kill((int)getpid(), SIGINT); |
---|
1657 | exit(nsigint != 2); |
---|
1658 | } |
---|
1659 | |
---|
1660 | EOF |
---|
1661 | if { (eval echo configure:1662: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null |
---|
1662 | then |
---|
1663 | bash_cv_must_reinstall_sighandlers=no |
---|
1664 | else |
---|
1665 | echo "configure: failed program was:" >&5 |
---|
1666 | cat conftest.$ac_ext >&5 |
---|
1667 | rm -fr conftest* |
---|
1668 | bash_cv_must_reinstall_sighandlers=yes |
---|
1669 | fi |
---|
1670 | rm -fr conftest* |
---|
1671 | fi |
---|
1672 | |
---|
1673 | fi |
---|
1674 | |
---|
1675 | echo "$ac_t""$bash_cv_must_reinstall_sighandlers" 1>&6 |
---|
1676 | if test $bash_cv_must_reinstall_sighandlers = yes; then |
---|
1677 | cat >> confdefs.h <<\EOF |
---|
1678 | #define MUST_REINSTALL_SIGHANDLERS 1 |
---|
1679 | EOF |
---|
1680 | |
---|
1681 | fi |
---|
1682 | |
---|
1683 | |
---|
1684 | |
---|
1685 | echo $ac_n "checking for presence of POSIX-style sigsetjmp/siglongjmp""... $ac_c" 1>&6 |
---|
1686 | echo "configure:1687: checking for presence of POSIX-style sigsetjmp/siglongjmp" >&5 |
---|
1687 | if eval "test \"`echo '$''{'bash_cv_func_sigsetjmp'+set}'`\" = set"; then |
---|
1688 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1689 | else |
---|
1690 | if test "$cross_compiling" = yes; then |
---|
1691 | echo "configure: warning: cannot check for sigsetjmp/siglongjmp if cross-compiling -- defaulting to missing" 1>&2 |
---|
1692 | bash_cv_func_sigsetjmp=missing |
---|
1693 | |
---|
1694 | else |
---|
1695 | cat > conftest.$ac_ext <<EOF |
---|
1696 | #line 1697 "configure" |
---|
1697 | #include "confdefs.h" |
---|
1698 | |
---|
1699 | #ifdef HAVE_UNISTD_H |
---|
1700 | #include <unistd.h> |
---|
1701 | #endif |
---|
1702 | #include <sys/types.h> |
---|
1703 | #include <signal.h> |
---|
1704 | #include <setjmp.h> |
---|
1705 | |
---|
1706 | main() |
---|
1707 | { |
---|
1708 | #if !defined (_POSIX_VERSION) || !defined (HAVE_POSIX_SIGNALS) |
---|
1709 | exit (1); |
---|
1710 | #else |
---|
1711 | |
---|
1712 | int code; |
---|
1713 | sigset_t set, oset; |
---|
1714 | sigjmp_buf xx; |
---|
1715 | |
---|
1716 | /* get the mask */ |
---|
1717 | sigemptyset(&set); |
---|
1718 | sigemptyset(&oset); |
---|
1719 | sigprocmask(SIG_BLOCK, (sigset_t *)NULL, &set); |
---|
1720 | sigprocmask(SIG_BLOCK, (sigset_t *)NULL, &oset); |
---|
1721 | |
---|
1722 | /* save it */ |
---|
1723 | code = sigsetjmp(xx, 1); |
---|
1724 | if (code) |
---|
1725 | exit(0); /* could get sigmask and compare to oset here. */ |
---|
1726 | |
---|
1727 | /* change it */ |
---|
1728 | sigaddset(&set, SIGINT); |
---|
1729 | sigprocmask(SIG_BLOCK, &set, (sigset_t *)NULL); |
---|
1730 | |
---|
1731 | /* and siglongjmp */ |
---|
1732 | siglongjmp(xx, 10); |
---|
1733 | exit(1); |
---|
1734 | #endif |
---|
1735 | } |
---|
1736 | EOF |
---|
1737 | if { (eval echo configure:1738: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null |
---|
1738 | then |
---|
1739 | bash_cv_func_sigsetjmp=present |
---|
1740 | else |
---|
1741 | echo "configure: failed program was:" >&5 |
---|
1742 | cat conftest.$ac_ext >&5 |
---|
1743 | rm -fr conftest* |
---|
1744 | bash_cv_func_sigsetjmp=missing |
---|
1745 | fi |
---|
1746 | rm -fr conftest* |
---|
1747 | fi |
---|
1748 | |
---|
1749 | fi |
---|
1750 | |
---|
1751 | echo "$ac_t""$bash_cv_func_sigsetjmp" 1>&6 |
---|
1752 | if test $bash_cv_func_sigsetjmp = present; then |
---|
1753 | cat >> confdefs.h <<\EOF |
---|
1754 | #define HAVE_POSIX_SIGSETJMP 1 |
---|
1755 | EOF |
---|
1756 | |
---|
1757 | fi |
---|
1758 | |
---|
1759 | echo $ac_n "checking for lstat""... $ac_c" 1>&6 |
---|
1760 | echo "configure:1761: checking for lstat" >&5 |
---|
1761 | if eval "test \"`echo '$''{'bash_cv_func_lstat'+set}'`\" = set"; then |
---|
1762 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1763 | else |
---|
1764 | cat > conftest.$ac_ext <<EOF |
---|
1765 | #line 1766 "configure" |
---|
1766 | #include "confdefs.h" |
---|
1767 | |
---|
1768 | #include <sys/types.h> |
---|
1769 | #include <sys/stat.h> |
---|
1770 | |
---|
1771 | int main() { |
---|
1772 | lstat(".",(struct stat *)0); |
---|
1773 | ; return 0; } |
---|
1774 | EOF |
---|
1775 | if { (eval echo configure:1776: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
---|
1776 | rm -rf conftest* |
---|
1777 | bash_cv_func_lstat=yes |
---|
1778 | else |
---|
1779 | echo "configure: failed program was:" >&5 |
---|
1780 | cat conftest.$ac_ext >&5 |
---|
1781 | rm -rf conftest* |
---|
1782 | bash_cv_func_lstat=no |
---|
1783 | fi |
---|
1784 | rm -f conftest* |
---|
1785 | fi |
---|
1786 | |
---|
1787 | echo "$ac_t""$bash_cv_func_lstat" 1>&6 |
---|
1788 | if test $bash_cv_func_lstat = yes; then |
---|
1789 | cat >> confdefs.h <<\EOF |
---|
1790 | #define HAVE_LSTAT 1 |
---|
1791 | EOF |
---|
1792 | |
---|
1793 | fi |
---|
1794 | |
---|
1795 | echo $ac_n "checking whether programs are able to redeclare getpw functions""... $ac_c" 1>&6 |
---|
1796 | echo "configure:1797: checking whether programs are able to redeclare getpw functions" >&5 |
---|
1797 | if eval "test \"`echo '$''{'bash_cv_can_redecl_getpw'+set}'`\" = set"; then |
---|
1798 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1799 | else |
---|
1800 | cat > conftest.$ac_ext <<EOF |
---|
1801 | #line 1802 "configure" |
---|
1802 | #include "confdefs.h" |
---|
1803 | #include <sys/types.h> |
---|
1804 | #include <pwd.h> |
---|
1805 | extern struct passwd *getpwent(); |
---|
1806 | extern struct passwd *getpwuid(); |
---|
1807 | extern struct passwd *getpwnam(); |
---|
1808 | int main() { |
---|
1809 | struct passwd *z; z = getpwent(); z = getpwuid(0); z = getpwnam("root"); |
---|
1810 | ; return 0; } |
---|
1811 | EOF |
---|
1812 | if { (eval echo configure:1813: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
---|
1813 | rm -rf conftest* |
---|
1814 | bash_cv_can_redecl_getpw=yes |
---|
1815 | else |
---|
1816 | echo "configure: failed program was:" >&5 |
---|
1817 | cat conftest.$ac_ext >&5 |
---|
1818 | rm -rf conftest* |
---|
1819 | bash_cv_can_redecl_getpw=no |
---|
1820 | fi |
---|
1821 | rm -f conftest* |
---|
1822 | fi |
---|
1823 | |
---|
1824 | echo "$ac_t""$bash_cv_can_redecl_getpw" 1>&6 |
---|
1825 | if test $bash_cv_can_redecl_getpw = no; then |
---|
1826 | cat >> confdefs.h <<\EOF |
---|
1827 | #define HAVE_GETPW_DECLS 1 |
---|
1828 | EOF |
---|
1829 | |
---|
1830 | fi |
---|
1831 | |
---|
1832 | |
---|
1833 | echo $ac_n "checking whether or not strcoll and strcmp differ""... $ac_c" 1>&6 |
---|
1834 | echo "configure:1835: checking whether or not strcoll and strcmp differ" >&5 |
---|
1835 | if eval "test \"`echo '$''{'bash_cv_func_strcoll_broken'+set}'`\" = set"; then |
---|
1836 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1837 | else |
---|
1838 | if test "$cross_compiling" = yes; then |
---|
1839 | echo "configure: warning: cannot check strcoll if cross compiling -- defaulting to no" 1>&2 |
---|
1840 | bash_cv_func_strcoll_broken=no |
---|
1841 | |
---|
1842 | else |
---|
1843 | cat > conftest.$ac_ext <<EOF |
---|
1844 | #line 1845 "configure" |
---|
1845 | #include "confdefs.h" |
---|
1846 | |
---|
1847 | #include <stdio.h> |
---|
1848 | #if defined (HAVE_LOCALE_H) |
---|
1849 | #include <locale.h> |
---|
1850 | #endif |
---|
1851 | |
---|
1852 | main(c, v) |
---|
1853 | int c; |
---|
1854 | char *v[]; |
---|
1855 | { |
---|
1856 | int r1, r2; |
---|
1857 | char *deflocale, *defcoll; |
---|
1858 | |
---|
1859 | #ifdef HAVE_SETLOCALE |
---|
1860 | deflocale = setlocale(LC_ALL, ""); |
---|
1861 | defcoll = setlocale(LC_COLLATE, ""); |
---|
1862 | #endif |
---|
1863 | |
---|
1864 | #ifdef HAVE_STRCOLL |
---|
1865 | /* These two values are taken from tests/glob-test. */ |
---|
1866 | r1 = strcoll("abd", "aXd"); |
---|
1867 | #else |
---|
1868 | r1 = 0; |
---|
1869 | #endif |
---|
1870 | r2 = strcmp("abd", "aXd"); |
---|
1871 | |
---|
1872 | /* These two should both be greater than 0. It is permissible for |
---|
1873 | a system to return different values, as long as the sign is the |
---|
1874 | same. */ |
---|
1875 | |
---|
1876 | /* Exit with 1 (failure) if these two values are both > 0, since |
---|
1877 | this tests whether strcoll(3) is broken with respect to strcmp(3) |
---|
1878 | in the default locale. */ |
---|
1879 | exit (r1 > 0 && r2 > 0); |
---|
1880 | } |
---|
1881 | |
---|
1882 | EOF |
---|
1883 | if { (eval echo configure:1884: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null |
---|
1884 | then |
---|
1885 | bash_cv_func_strcoll_broken=yes |
---|
1886 | else |
---|
1887 | echo "configure: failed program was:" >&5 |
---|
1888 | cat conftest.$ac_ext >&5 |
---|
1889 | rm -fr conftest* |
---|
1890 | bash_cv_func_strcoll_broken=no |
---|
1891 | fi |
---|
1892 | rm -fr conftest* |
---|
1893 | fi |
---|
1894 | |
---|
1895 | fi |
---|
1896 | |
---|
1897 | echo "$ac_t""$bash_cv_func_strcoll_broken" 1>&6 |
---|
1898 | if test $bash_cv_func_strcoll_broken = yes; then |
---|
1899 | cat >> confdefs.h <<\EOF |
---|
1900 | #define STRCOLL_BROKEN 1 |
---|
1901 | EOF |
---|
1902 | |
---|
1903 | fi |
---|
1904 | |
---|
1905 | |
---|
1906 | echo $ac_n "checking whether signal handlers are of type void""... $ac_c" 1>&6 |
---|
1907 | echo "configure:1908: checking whether signal handlers are of type void" >&5 |
---|
1908 | if eval "test \"`echo '$''{'bash_cv_void_sighandler'+set}'`\" = set"; then |
---|
1909 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1910 | else |
---|
1911 | cat > conftest.$ac_ext <<EOF |
---|
1912 | #line 1913 "configure" |
---|
1913 | #include "confdefs.h" |
---|
1914 | #include <sys/types.h> |
---|
1915 | #include <signal.h> |
---|
1916 | #ifdef signal |
---|
1917 | #undef signal |
---|
1918 | #endif |
---|
1919 | #ifdef __cplusplus |
---|
1920 | extern "C" |
---|
1921 | #endif |
---|
1922 | void (*signal ()) (); |
---|
1923 | int main() { |
---|
1924 | int i; |
---|
1925 | ; return 0; } |
---|
1926 | EOF |
---|
1927 | if { (eval echo configure:1928: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
---|
1928 | rm -rf conftest* |
---|
1929 | bash_cv_void_sighandler=yes |
---|
1930 | else |
---|
1931 | echo "configure: failed program was:" >&5 |
---|
1932 | cat conftest.$ac_ext >&5 |
---|
1933 | rm -rf conftest* |
---|
1934 | bash_cv_void_sighandler=no |
---|
1935 | fi |
---|
1936 | rm -f conftest* |
---|
1937 | fi |
---|
1938 | echo "$ac_t""$bash_cv_void_sighandler" 1>&6 |
---|
1939 | if test $bash_cv_void_sighandler = yes; then |
---|
1940 | cat >> confdefs.h <<\EOF |
---|
1941 | #define VOID_SIGHANDLER 1 |
---|
1942 | EOF |
---|
1943 | |
---|
1944 | fi |
---|
1945 | |
---|
1946 | echo $ac_n "checking for TIOCGWINSZ in sys/ioctl.h""... $ac_c" 1>&6 |
---|
1947 | echo "configure:1948: checking for TIOCGWINSZ in sys/ioctl.h" >&5 |
---|
1948 | if eval "test \"`echo '$''{'bash_cv_tiocgwinsz_in_ioctl'+set}'`\" = set"; then |
---|
1949 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1950 | else |
---|
1951 | cat > conftest.$ac_ext <<EOF |
---|
1952 | #line 1953 "configure" |
---|
1953 | #include "confdefs.h" |
---|
1954 | #include <sys/types.h> |
---|
1955 | #include <sys/ioctl.h> |
---|
1956 | int main() { |
---|
1957 | int x = TIOCGWINSZ; |
---|
1958 | ; return 0; } |
---|
1959 | EOF |
---|
1960 | if { (eval echo configure:1961: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
---|
1961 | rm -rf conftest* |
---|
1962 | bash_cv_tiocgwinsz_in_ioctl=yes |
---|
1963 | else |
---|
1964 | echo "configure: failed program was:" >&5 |
---|
1965 | cat conftest.$ac_ext >&5 |
---|
1966 | rm -rf conftest* |
---|
1967 | bash_cv_tiocgwinsz_in_ioctl=no |
---|
1968 | fi |
---|
1969 | rm -f conftest* |
---|
1970 | fi |
---|
1971 | |
---|
1972 | echo "$ac_t""$bash_cv_tiocgwinsz_in_ioctl" 1>&6 |
---|
1973 | if test $bash_cv_tiocgwinsz_in_ioctl = yes; then |
---|
1974 | cat >> confdefs.h <<\EOF |
---|
1975 | #define GWINSZ_IN_SYS_IOCTL 1 |
---|
1976 | EOF |
---|
1977 | |
---|
1978 | fi |
---|
1979 | |
---|
1980 | echo $ac_n "checking for TIOCSTAT in sys/ioctl.h""... $ac_c" 1>&6 |
---|
1981 | echo "configure:1982: checking for TIOCSTAT in sys/ioctl.h" >&5 |
---|
1982 | if eval "test \"`echo '$''{'bash_cv_tiocstat_in_ioctl'+set}'`\" = set"; then |
---|
1983 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
1984 | else |
---|
1985 | cat > conftest.$ac_ext <<EOF |
---|
1986 | #line 1987 "configure" |
---|
1987 | #include "confdefs.h" |
---|
1988 | #include <sys/types.h> |
---|
1989 | #include <sys/ioctl.h> |
---|
1990 | int main() { |
---|
1991 | int x = TIOCSTAT; |
---|
1992 | ; return 0; } |
---|
1993 | EOF |
---|
1994 | if { (eval echo configure:1995: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
---|
1995 | rm -rf conftest* |
---|
1996 | bash_cv_tiocstat_in_ioctl=yes |
---|
1997 | else |
---|
1998 | echo "configure: failed program was:" >&5 |
---|
1999 | cat conftest.$ac_ext >&5 |
---|
2000 | rm -rf conftest* |
---|
2001 | bash_cv_tiocstat_in_ioctl=no |
---|
2002 | fi |
---|
2003 | rm -f conftest* |
---|
2004 | fi |
---|
2005 | |
---|
2006 | echo "$ac_t""$bash_cv_tiocstat_in_ioctl" 1>&6 |
---|
2007 | if test $bash_cv_tiocstat_in_ioctl = yes; then |
---|
2008 | cat >> confdefs.h <<\EOF |
---|
2009 | #define TIOCSTAT_IN_SYS_IOCTL 1 |
---|
2010 | EOF |
---|
2011 | |
---|
2012 | fi |
---|
2013 | |
---|
2014 | echo $ac_n "checking for FIONREAD in sys/ioctl.h""... $ac_c" 1>&6 |
---|
2015 | echo "configure:2016: checking for FIONREAD in sys/ioctl.h" >&5 |
---|
2016 | if eval "test \"`echo '$''{'bash_cv_fionread_in_ioctl'+set}'`\" = set"; then |
---|
2017 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
2018 | else |
---|
2019 | cat > conftest.$ac_ext <<EOF |
---|
2020 | #line 2021 "configure" |
---|
2021 | #include "confdefs.h" |
---|
2022 | #include <sys/types.h> |
---|
2023 | #include <sys/ioctl.h> |
---|
2024 | int main() { |
---|
2025 | int x = FIONREAD; |
---|
2026 | ; return 0; } |
---|
2027 | EOF |
---|
2028 | if { (eval echo configure:2029: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
---|
2029 | rm -rf conftest* |
---|
2030 | bash_cv_fionread_in_ioctl=yes |
---|
2031 | else |
---|
2032 | echo "configure: failed program was:" >&5 |
---|
2033 | cat conftest.$ac_ext >&5 |
---|
2034 | rm -rf conftest* |
---|
2035 | bash_cv_fionread_in_ioctl=no |
---|
2036 | fi |
---|
2037 | rm -f conftest* |
---|
2038 | fi |
---|
2039 | |
---|
2040 | echo "$ac_t""$bash_cv_fionread_in_ioctl" 1>&6 |
---|
2041 | if test $bash_cv_fionread_in_ioctl = yes; then |
---|
2042 | cat >> confdefs.h <<\EOF |
---|
2043 | #define FIONREAD_IN_SYS_IOCTL 1 |
---|
2044 | EOF |
---|
2045 | |
---|
2046 | fi |
---|
2047 | |
---|
2048 | echo $ac_n "checking for speed_t in sys/types.h""... $ac_c" 1>&6 |
---|
2049 | echo "configure:2050: checking for speed_t in sys/types.h" >&5 |
---|
2050 | if eval "test \"`echo '$''{'bash_cv_speed_t_in_sys_types'+set}'`\" = set"; then |
---|
2051 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
2052 | else |
---|
2053 | cat > conftest.$ac_ext <<EOF |
---|
2054 | #line 2055 "configure" |
---|
2055 | #include "confdefs.h" |
---|
2056 | #include <sys/types.h> |
---|
2057 | int main() { |
---|
2058 | speed_t x; |
---|
2059 | ; return 0; } |
---|
2060 | EOF |
---|
2061 | if { (eval echo configure:2062: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
---|
2062 | rm -rf conftest* |
---|
2063 | bash_cv_speed_t_in_sys_types=yes |
---|
2064 | else |
---|
2065 | echo "configure: failed program was:" >&5 |
---|
2066 | cat conftest.$ac_ext >&5 |
---|
2067 | rm -rf conftest* |
---|
2068 | bash_cv_speed_t_in_sys_types=no |
---|
2069 | fi |
---|
2070 | rm -f conftest* |
---|
2071 | fi |
---|
2072 | |
---|
2073 | echo "$ac_t""$bash_cv_speed_t_in_sys_types" 1>&6 |
---|
2074 | if test $bash_cv_speed_t_in_sys_types = yes; then |
---|
2075 | cat >> confdefs.h <<\EOF |
---|
2076 | #define SPEED_T_IN_SYS_TYPES 1 |
---|
2077 | EOF |
---|
2078 | |
---|
2079 | fi |
---|
2080 | |
---|
2081 | echo $ac_n "checking for struct winsize in sys/ioctl.h and termios.h""... $ac_c" 1>&6 |
---|
2082 | echo "configure:2083: checking for struct winsize in sys/ioctl.h and termios.h" >&5 |
---|
2083 | if eval "test \"`echo '$''{'bash_cv_struct_winsize_header'+set}'`\" = set"; then |
---|
2084 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
2085 | else |
---|
2086 | cat > conftest.$ac_ext <<EOF |
---|
2087 | #line 2088 "configure" |
---|
2088 | #include "confdefs.h" |
---|
2089 | #include <sys/types.h> |
---|
2090 | #include <sys/ioctl.h> |
---|
2091 | int main() { |
---|
2092 | struct winsize x; |
---|
2093 | ; return 0; } |
---|
2094 | EOF |
---|
2095 | if { (eval echo configure:2096: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
---|
2096 | rm -rf conftest* |
---|
2097 | bash_cv_struct_winsize_header=ioctl_h |
---|
2098 | else |
---|
2099 | echo "configure: failed program was:" >&5 |
---|
2100 | cat conftest.$ac_ext >&5 |
---|
2101 | rm -rf conftest* |
---|
2102 | cat > conftest.$ac_ext <<EOF |
---|
2103 | #line 2104 "configure" |
---|
2104 | #include "confdefs.h" |
---|
2105 | #include <sys/types.h> |
---|
2106 | #include <termios.h> |
---|
2107 | int main() { |
---|
2108 | struct winsize x; |
---|
2109 | ; return 0; } |
---|
2110 | EOF |
---|
2111 | if { (eval echo configure:2112: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
---|
2112 | rm -rf conftest* |
---|
2113 | bash_cv_struct_winsize_header=termios_h |
---|
2114 | else |
---|
2115 | echo "configure: failed program was:" >&5 |
---|
2116 | cat conftest.$ac_ext >&5 |
---|
2117 | rm -rf conftest* |
---|
2118 | bash_cv_struct_winsize_header=other |
---|
2119 | fi |
---|
2120 | rm -f conftest* |
---|
2121 | |
---|
2122 | fi |
---|
2123 | rm -f conftest* |
---|
2124 | fi |
---|
2125 | |
---|
2126 | if test $bash_cv_struct_winsize_header = ioctl_h; then |
---|
2127 | echo "$ac_t""sys/ioctl.h" 1>&6 |
---|
2128 | cat >> confdefs.h <<\EOF |
---|
2129 | #define STRUCT_WINSIZE_IN_SYS_IOCTL 1 |
---|
2130 | EOF |
---|
2131 | |
---|
2132 | elif test $bash_cv_struct_winsize_header = termios_h; then |
---|
2133 | echo "$ac_t""termios.h" 1>&6 |
---|
2134 | cat >> confdefs.h <<\EOF |
---|
2135 | #define STRUCT_WINSIZE_IN_TERMIOS 1 |
---|
2136 | EOF |
---|
2137 | |
---|
2138 | else |
---|
2139 | echo "$ac_t""not found" 1>&6 |
---|
2140 | fi |
---|
2141 | |
---|
2142 | |
---|
2143 | echo $ac_n "checking if struct dirent has a d_ino member""... $ac_c" 1>&6 |
---|
2144 | echo "configure:2145: checking if struct dirent has a d_ino member" >&5 |
---|
2145 | if eval "test \"`echo '$''{'bash_cv_dirent_has_dino'+set}'`\" = set"; then |
---|
2146 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
2147 | else |
---|
2148 | cat > conftest.$ac_ext <<EOF |
---|
2149 | #line 2150 "configure" |
---|
2150 | #include "confdefs.h" |
---|
2151 | |
---|
2152 | #include <stdio.h> |
---|
2153 | #include <sys/types.h> |
---|
2154 | #ifdef HAVE_UNISTD_H |
---|
2155 | # include <unistd.h> |
---|
2156 | #endif /* HAVE_UNISTD_H */ |
---|
2157 | #if defined(HAVE_DIRENT_H) |
---|
2158 | # include <dirent.h> |
---|
2159 | #else |
---|
2160 | # define dirent direct |
---|
2161 | # ifdef HAVE_SYS_NDIR_H |
---|
2162 | # include <sys/ndir.h> |
---|
2163 | # endif /* SYSNDIR */ |
---|
2164 | # ifdef HAVE_SYS_DIR_H |
---|
2165 | # include <sys/dir.h> |
---|
2166 | # endif /* SYSDIR */ |
---|
2167 | # ifdef HAVE_NDIR_H |
---|
2168 | # include <ndir.h> |
---|
2169 | # endif |
---|
2170 | #endif /* HAVE_DIRENT_H */ |
---|
2171 | |
---|
2172 | int main() { |
---|
2173 | |
---|
2174 | struct dirent d; int z; z = d.d_ino; |
---|
2175 | |
---|
2176 | ; return 0; } |
---|
2177 | EOF |
---|
2178 | if { (eval echo configure:2179: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
---|
2179 | rm -rf conftest* |
---|
2180 | bash_cv_dirent_has_dino=yes |
---|
2181 | else |
---|
2182 | echo "configure: failed program was:" >&5 |
---|
2183 | cat conftest.$ac_ext >&5 |
---|
2184 | rm -rf conftest* |
---|
2185 | bash_cv_dirent_has_dino=no |
---|
2186 | fi |
---|
2187 | rm -f conftest* |
---|
2188 | fi |
---|
2189 | |
---|
2190 | echo "$ac_t""$bash_cv_dirent_has_dino" 1>&6 |
---|
2191 | if test $bash_cv_dirent_has_dino = yes; then |
---|
2192 | cat >> confdefs.h <<\EOF |
---|
2193 | #define STRUCT_DIRENT_HAS_D_INO 1 |
---|
2194 | EOF |
---|
2195 | |
---|
2196 | fi |
---|
2197 | |
---|
2198 | |
---|
2199 | echo $ac_n "checking if struct dirent has a d_fileno member""... $ac_c" 1>&6 |
---|
2200 | echo "configure:2201: checking if struct dirent has a d_fileno member" >&5 |
---|
2201 | if eval "test \"`echo '$''{'bash_cv_dirent_has_d_fileno'+set}'`\" = set"; then |
---|
2202 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
2203 | else |
---|
2204 | cat > conftest.$ac_ext <<EOF |
---|
2205 | #line 2206 "configure" |
---|
2206 | #include "confdefs.h" |
---|
2207 | |
---|
2208 | #include <stdio.h> |
---|
2209 | #include <sys/types.h> |
---|
2210 | #ifdef HAVE_UNISTD_H |
---|
2211 | # include <unistd.h> |
---|
2212 | #endif /* HAVE_UNISTD_H */ |
---|
2213 | #if defined(HAVE_DIRENT_H) |
---|
2214 | # include <dirent.h> |
---|
2215 | #else |
---|
2216 | # define dirent direct |
---|
2217 | # ifdef HAVE_SYS_NDIR_H |
---|
2218 | # include <sys/ndir.h> |
---|
2219 | # endif /* SYSNDIR */ |
---|
2220 | # ifdef HAVE_SYS_DIR_H |
---|
2221 | # include <sys/dir.h> |
---|
2222 | # endif /* SYSDIR */ |
---|
2223 | # ifdef HAVE_NDIR_H |
---|
2224 | # include <ndir.h> |
---|
2225 | # endif |
---|
2226 | #endif /* HAVE_DIRENT_H */ |
---|
2227 | |
---|
2228 | int main() { |
---|
2229 | |
---|
2230 | struct dirent d; int z; z = d.d_fileno; |
---|
2231 | |
---|
2232 | ; return 0; } |
---|
2233 | EOF |
---|
2234 | if { (eval echo configure:2235: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
---|
2235 | rm -rf conftest* |
---|
2236 | bash_cv_dirent_has_d_fileno=yes |
---|
2237 | else |
---|
2238 | echo "configure: failed program was:" >&5 |
---|
2239 | cat conftest.$ac_ext >&5 |
---|
2240 | rm -rf conftest* |
---|
2241 | bash_cv_dirent_has_d_fileno=no |
---|
2242 | fi |
---|
2243 | rm -f conftest* |
---|
2244 | fi |
---|
2245 | |
---|
2246 | echo "$ac_t""$bash_cv_dirent_has_d_fileno" 1>&6 |
---|
2247 | if test $bash_cv_dirent_has_d_fileno = yes; then |
---|
2248 | cat >> confdefs.h <<\EOF |
---|
2249 | #define STRUCT_DIRENT_HAS_D_FILENO 1 |
---|
2250 | EOF |
---|
2251 | |
---|
2252 | fi |
---|
2253 | |
---|
2254 | |
---|
2255 | case "$host_os" in |
---|
2256 | aix*) prefer_curses=yes ;; |
---|
2257 | esac |
---|
2258 | |
---|
2259 | if test "X$bash_cv_termcap_lib" = "X"; then |
---|
2260 | _bash_needmsg=yes |
---|
2261 | else |
---|
2262 | echo $ac_n "checking which library has the termcap functions""... $ac_c" 1>&6 |
---|
2263 | echo "configure:2264: checking which library has the termcap functions" >&5 |
---|
2264 | _bash_needmsg= |
---|
2265 | fi |
---|
2266 | if eval "test \"`echo '$''{'bash_cv_termcap_lib'+set}'`\" = set"; then |
---|
2267 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
2268 | else |
---|
2269 | echo $ac_n "checking for tgetent in -ltermcap""... $ac_c" 1>&6 |
---|
2270 | echo "configure:2271: checking for tgetent in -ltermcap" >&5 |
---|
2271 | ac_lib_var=`echo termcap'_'tgetent | sed 'y%./+-%__p_%'` |
---|
2272 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
---|
2273 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
2274 | else |
---|
2275 | ac_save_LIBS="$LIBS" |
---|
2276 | LIBS="-ltermcap $LIBS" |
---|
2277 | cat > conftest.$ac_ext <<EOF |
---|
2278 | #line 2279 "configure" |
---|
2279 | #include "confdefs.h" |
---|
2280 | /* Override any gcc2 internal prototype to avoid an error. */ |
---|
2281 | /* We use char because int might match the return type of a gcc2 |
---|
2282 | builtin and then its argument prototype would still apply. */ |
---|
2283 | char tgetent(); |
---|
2284 | |
---|
2285 | int main() { |
---|
2286 | tgetent() |
---|
2287 | ; return 0; } |
---|
2288 | EOF |
---|
2289 | if { (eval echo configure:2290: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
---|
2290 | rm -rf conftest* |
---|
2291 | eval "ac_cv_lib_$ac_lib_var=yes" |
---|
2292 | else |
---|
2293 | echo "configure: failed program was:" >&5 |
---|
2294 | cat conftest.$ac_ext >&5 |
---|
2295 | rm -rf conftest* |
---|
2296 | eval "ac_cv_lib_$ac_lib_var=no" |
---|
2297 | fi |
---|
2298 | rm -f conftest* |
---|
2299 | LIBS="$ac_save_LIBS" |
---|
2300 | |
---|
2301 | fi |
---|
2302 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
---|
2303 | echo "$ac_t""yes" 1>&6 |
---|
2304 | bash_cv_termcap_lib=libtermcap |
---|
2305 | else |
---|
2306 | echo "$ac_t""no" 1>&6 |
---|
2307 | echo $ac_n "checking for tgetent in -lcurses""... $ac_c" 1>&6 |
---|
2308 | echo "configure:2309: checking for tgetent in -lcurses" >&5 |
---|
2309 | ac_lib_var=`echo curses'_'tgetent | sed 'y%./+-%__p_%'` |
---|
2310 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
---|
2311 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
2312 | else |
---|
2313 | ac_save_LIBS="$LIBS" |
---|
2314 | LIBS="-lcurses $LIBS" |
---|
2315 | cat > conftest.$ac_ext <<EOF |
---|
2316 | #line 2317 "configure" |
---|
2317 | #include "confdefs.h" |
---|
2318 | /* Override any gcc2 internal prototype to avoid an error. */ |
---|
2319 | /* We use char because int might match the return type of a gcc2 |
---|
2320 | builtin and then its argument prototype would still apply. */ |
---|
2321 | char tgetent(); |
---|
2322 | |
---|
2323 | int main() { |
---|
2324 | tgetent() |
---|
2325 | ; return 0; } |
---|
2326 | EOF |
---|
2327 | if { (eval echo configure:2328: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
---|
2328 | rm -rf conftest* |
---|
2329 | eval "ac_cv_lib_$ac_lib_var=yes" |
---|
2330 | else |
---|
2331 | echo "configure: failed program was:" >&5 |
---|
2332 | cat conftest.$ac_ext >&5 |
---|
2333 | rm -rf conftest* |
---|
2334 | eval "ac_cv_lib_$ac_lib_var=no" |
---|
2335 | fi |
---|
2336 | rm -f conftest* |
---|
2337 | LIBS="$ac_save_LIBS" |
---|
2338 | |
---|
2339 | fi |
---|
2340 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
---|
2341 | echo "$ac_t""yes" 1>&6 |
---|
2342 | bash_cv_termcap_lib=libcurses |
---|
2343 | else |
---|
2344 | echo "$ac_t""no" 1>&6 |
---|
2345 | echo $ac_n "checking for tgetent in -lncurses""... $ac_c" 1>&6 |
---|
2346 | echo "configure:2347: checking for tgetent in -lncurses" >&5 |
---|
2347 | ac_lib_var=`echo ncurses'_'tgetent | sed 'y%./+-%__p_%'` |
---|
2348 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
---|
2349 | echo $ac_n "(cached) $ac_c" 1>&6 |
---|
2350 | else |
---|
2351 | ac_save_LIBS="$LIBS" |
---|
2352 | LIBS="-lncurses $LIBS" |
---|
2353 | cat > conftest.$ac_ext <<EOF |
---|
2354 | #line 2355 "configure" |
---|
2355 | #include "confdefs.h" |
---|
2356 | /* Override any gcc2 internal prototype to avoid an error. */ |
---|
2357 | /* We use char because int might match the return type of a gcc2 |
---|
2358 | builtin and then its argument prototype would still apply. */ |
---|
2359 | char tgetent(); |
---|
2360 | |
---|
2361 | int main() { |
---|
2362 | tgetent() |
---|
2363 | ; return 0; } |
---|
2364 | EOF |
---|
2365 | if { (eval echo configure:2366: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
---|
2366 | rm -rf conftest* |
---|
2367 | eval "ac_cv_lib_$ac_lib_var=yes" |
---|
2368 | else |
---|
2369 | echo "configure: failed program was:" >&5 |
---|
2370 | cat conftest.$ac_ext >&5 |
---|
2371 | rm -rf conftest* |
---|
2372 | eval "ac_cv_lib_$ac_lib_var=no" |
---|
2373 | fi |
---|
2374 | rm -f conftest* |
---|
2375 | LIBS="$ac_save_LIBS" |
---|
2376 | |
---|
2377 | fi |
---|
2378 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
---|
2379 | echo "$ac_t""yes" 1>&6 |
---|
2380 | bash_cv_termcap_lib=libncurses |
---|
2381 | else |
---|
2382 | echo "$ac_t""no" 1>&6 |
---|
2383 | bash_cv_termcap_lib=gnutermcap |
---|
2384 | fi |
---|
2385 | |
---|
2386 | fi |
---|
2387 | |
---|
2388 | fi |
---|
2389 | |
---|
2390 | fi |
---|
2391 | |
---|
2392 | if test "X$_bash_needmsg" = "Xyes"; then |
---|
2393 | echo $ac_n "checking which library has the termcap functions""... $ac_c" 1>&6 |
---|
2394 | echo "configure:2395: checking which library has the termcap functions" >&5 |
---|
2395 | fi |
---|
2396 | echo "$ac_t""using $bash_cv_termcap_lib" 1>&6 |
---|
2397 | if test $bash_cv_termcap_lib = gnutermcap && test -z "$prefer_curses"; then |
---|
2398 | LDFLAGS="$LDFLAGS -L./lib/termcap" |
---|
2399 | TERMCAP_LIB="./lib/termcap/libtermcap.a" |
---|
2400 | TERMCAP_DEP="./lib/termcap/libtermcap.a" |
---|
2401 | elif test $bash_cv_termcap_lib = libtermcap && test -z "$prefer_curses"; then |
---|
2402 | TERMCAP_LIB=-ltermcap |
---|
2403 | TERMCAP_DEP= |
---|
2404 | elif test $bash_cv_termcap_lib = libncurses; then |
---|
2405 | TERMCAP_LIB=-lncurses |
---|
2406 | TERMCAP_DEP= |
---|
2407 | else |
---|
2408 | TERMCAP_LIB=-lcurses |
---|
2409 | TERMCAP_DEP= |
---|
2410 | fi |
---|
2411 | |
---|
2412 | if test "$TERMCAP_LIB" = "./lib/termcap/libtermcap.a"; then |
---|
2413 | TERMCAP_LIB=-ltermcap #default |
---|
2414 | fi |
---|
2415 | |
---|
2416 | case "$host_cpu" in |
---|
2417 | *cray*) LOCAL_CFLAGS=-DCRAY ;; |
---|
2418 | esac |
---|
2419 | |
---|
2420 | case "$host_os" in |
---|
2421 | isc*) LOCAL_CFLAGS=-Disc386 ;; |
---|
2422 | esac |
---|
2423 | |
---|
2424 | # shared library configuration section |
---|
2425 | # |
---|
2426 | # Shared object configuration section. These values are generated by |
---|
2427 | # ${srcdir}/support/shobj-conf |
---|
2428 | # |
---|
2429 | if test -f ${srcdir}/support/shobj-conf; then |
---|
2430 | echo $ac_n "checking configuration for building shared libraries""... $ac_c" 1>&6 |
---|
2431 | echo "configure:2432: checking configuration for building shared libraries" >&5 |
---|
2432 | eval `${CONFIG_SHELL-/bin/sh} ${srcdir}/support/shobj-conf -C ${CC} -c ${host_cpu} -o ${host_os} -v ${host_vendor}` |
---|
2433 | |
---|
2434 | |
---|
2435 | |
---|
2436 | |
---|
2437 | |
---|
2438 | |
---|
2439 | |
---|
2440 | |
---|
2441 | |
---|
2442 | |
---|
2443 | |
---|
2444 | |
---|
2445 | echo "$ac_t""$SHLIB_STATUS" 1>&6 |
---|
2446 | fi |
---|
2447 | |
---|
2448 | BUILD_DIR=`pwd` |
---|
2449 | |
---|
2450 | |
---|
2451 | |
---|
2452 | |
---|
2453 | |
---|
2454 | |
---|
2455 | |
---|
2456 | |
---|
2457 | |
---|
2458 | |
---|
2459 | |
---|
2460 | |
---|
2461 | |
---|
2462 | |
---|
2463 | |
---|
2464 | |
---|
2465 | |
---|
2466 | trap '' 1 2 15 |
---|
2467 | cat > confcache <<\EOF |
---|
2468 | # This file is a shell script that caches the results of configure |
---|
2469 | # tests run on this system so they can be shared between configure |
---|
2470 | # scripts and configure runs. It is not useful on other systems. |
---|
2471 | # If it contains results you don't want to keep, you may remove or edit it. |
---|
2472 | # |
---|
2473 | # By default, configure uses ./config.cache as the cache file, |
---|
2474 | # creating it if it does not exist already. You can give configure |
---|
2475 | # the --cache-file=FILE option to use a different cache file; that is |
---|
2476 | # what configure does when it calls configure scripts in |
---|
2477 | # subdirectories, so they share the cache. |
---|
2478 | # Giving --cache-file=/dev/null disables caching, for debugging configure. |
---|
2479 | # config.status only pays attention to the cache file if you give it the |
---|
2480 | # --recheck option to rerun configure. |
---|
2481 | # |
---|
2482 | EOF |
---|
2483 | # The following way of writing the cache mishandles newlines in values, |
---|
2484 | # but we know of no workaround that is simple, portable, and efficient. |
---|
2485 | # So, don't put newlines in cache variables' values. |
---|
2486 | # Ultrix sh set writes to stderr and can't be redirected directly, |
---|
2487 | # and sets the high bit in the cache file unless we assign to the vars. |
---|
2488 | (set) 2>&1 | |
---|
2489 | case `(ac_space=' '; set) 2>&1` in |
---|
2490 | *ac_space=\ *) |
---|
2491 | # `set' does not quote correctly, so add quotes (double-quote substitution |
---|
2492 | # turns \\\\ into \\, and sed turns \\ into \). |
---|
2493 | sed -n \ |
---|
2494 | -e "s/'/'\\\\''/g" \ |
---|
2495 | -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p" |
---|
2496 | ;; |
---|
2497 | *) |
---|
2498 | # `set' quotes correctly as required by POSIX, so do not add quotes. |
---|
2499 | sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p' |
---|
2500 | ;; |
---|
2501 | esac >> confcache |
---|
2502 | if cmp -s $cache_file confcache; then |
---|
2503 | : |
---|
2504 | else |
---|
2505 | if test -w $cache_file; then |
---|
2506 | echo "updating cache $cache_file" |
---|
2507 | cat confcache > $cache_file |
---|
2508 | else |
---|
2509 | echo "not updating unwritable cache $cache_file" |
---|
2510 | fi |
---|
2511 | fi |
---|
2512 | rm -f confcache |
---|
2513 | |
---|
2514 | trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 |
---|
2515 | |
---|
2516 | test "x$prefix" = xNONE && prefix=$ac_default_prefix |
---|
2517 | # Let make expand exec_prefix. |
---|
2518 | test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' |
---|
2519 | |
---|
2520 | # Any assignment to VPATH causes Sun make to only execute |
---|
2521 | # the first set of double-colon rules, so remove it if not needed. |
---|
2522 | # If there is a colon in the path, we need to keep it. |
---|
2523 | if test "x$srcdir" = x.; then |
---|
2524 | ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d' |
---|
2525 | fi |
---|
2526 | |
---|
2527 | trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15 |
---|
2528 | |
---|
2529 | DEFS=-DHAVE_CONFIG_H |
---|
2530 | |
---|
2531 | # Without the "./", some shells look in PATH for config.status. |
---|
2532 | : ${CONFIG_STATUS=./config.status} |
---|
2533 | |
---|
2534 | echo creating $CONFIG_STATUS |
---|
2535 | rm -f $CONFIG_STATUS |
---|
2536 | cat > $CONFIG_STATUS <<EOF |
---|
2537 | #! /bin/sh |
---|
2538 | # Generated automatically by configure. |
---|
2539 | # Run this file to recreate the current configuration. |
---|
2540 | # This directory was configured as follows, |
---|
2541 | # on host `(hostname || uname -n) 2>/dev/null | sed 1q`: |
---|
2542 | # |
---|
2543 | # $0 $ac_configure_args |
---|
2544 | # |
---|
2545 | # Compiler output produced by configure, useful for debugging |
---|
2546 | # configure, is in ./config.log if it exists. |
---|
2547 | |
---|
2548 | ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]" |
---|
2549 | for ac_option |
---|
2550 | do |
---|
2551 | case "\$ac_option" in |
---|
2552 | -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) |
---|
2553 | echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion" |
---|
2554 | exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;; |
---|
2555 | -version | --version | --versio | --versi | --vers | --ver | --ve | --v) |
---|
2556 | echo "$CONFIG_STATUS generated by autoconf version 2.12" |
---|
2557 | exit 0 ;; |
---|
2558 | -help | --help | --hel | --he | --h) |
---|
2559 | echo "\$ac_cs_usage"; exit 0 ;; |
---|
2560 | *) echo "\$ac_cs_usage"; exit 1 ;; |
---|
2561 | esac |
---|
2562 | done |
---|
2563 | |
---|
2564 | ac_given_srcdir=$srcdir |
---|
2565 | ac_given_INSTALL="$INSTALL" |
---|
2566 | |
---|
2567 | trap 'rm -fr `echo "Makefile doc/Makefile examples/Makefile shlib/Makefile config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 |
---|
2568 | EOF |
---|
2569 | cat >> $CONFIG_STATUS <<EOF |
---|
2570 | |
---|
2571 | # Protect against being on the right side of a sed subst in config.status. |
---|
2572 | sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g; |
---|
2573 | s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF |
---|
2574 | $ac_vpsub |
---|
2575 | $extrasub |
---|
2576 | s%@CFLAGS@%$CFLAGS%g |
---|
2577 | s%@CPPFLAGS@%$CPPFLAGS%g |
---|
2578 | s%@CXXFLAGS@%$CXXFLAGS%g |
---|
2579 | s%@DEFS@%$DEFS%g |
---|
2580 | s%@LDFLAGS@%$LDFLAGS%g |
---|
2581 | s%@LIBS@%$LIBS%g |
---|
2582 | s%@exec_prefix@%$exec_prefix%g |
---|
2583 | s%@prefix@%$prefix%g |
---|
2584 | s%@program_transform_name@%$program_transform_name%g |
---|
2585 | s%@bindir@%$bindir%g |
---|
2586 | s%@sbindir@%$sbindir%g |
---|
2587 | s%@libexecdir@%$libexecdir%g |
---|
2588 | s%@datadir@%$datadir%g |
---|
2589 | s%@sysconfdir@%$sysconfdir%g |
---|
2590 | s%@sharedstatedir@%$sharedstatedir%g |
---|
2591 | s%@localstatedir@%$localstatedir%g |
---|
2592 | s%@libdir@%$libdir%g |
---|
2593 | s%@includedir@%$includedir%g |
---|
2594 | s%@oldincludedir@%$oldincludedir%g |
---|
2595 | s%@infodir@%$infodir%g |
---|
2596 | s%@mandir@%$mandir%g |
---|
2597 | s%@host@%$host%g |
---|
2598 | s%@host_alias@%$host_alias%g |
---|
2599 | s%@host_cpu@%$host_cpu%g |
---|
2600 | s%@host_vendor@%$host_vendor%g |
---|
2601 | s%@host_os@%$host_os%g |
---|
2602 | s%@CC@%$CC%g |
---|
2603 | s%@CPP@%$CPP%g |
---|
2604 | s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g |
---|
2605 | s%@INSTALL_DATA@%$INSTALL_DATA%g |
---|
2606 | s%@AR@%$AR%g |
---|
2607 | s%@RANLIB@%$RANLIB%g |
---|
2608 | s%@MAKE_SHELL@%$MAKE_SHELL%g |
---|
2609 | s%@SHOBJ_CC@%$SHOBJ_CC%g |
---|
2610 | s%@SHOBJ_CFLAGS@%$SHOBJ_CFLAGS%g |
---|
2611 | s%@SHOBJ_LD@%$SHOBJ_LD%g |
---|
2612 | s%@SHOBJ_LDFLAGS@%$SHOBJ_LDFLAGS%g |
---|
2613 | s%@SHOBJ_XLDFLAGS@%$SHOBJ_XLDFLAGS%g |
---|
2614 | s%@SHOBJ_LIBS@%$SHOBJ_LIBS%g |
---|
2615 | s%@SHOBJ_STATUS@%$SHOBJ_STATUS%g |
---|
2616 | s%@SHLIB_STATUS@%$SHLIB_STATUS%g |
---|
2617 | s%@SHLIB_XLDFLAGS@%$SHLIB_XLDFLAGS%g |
---|
2618 | s%@SHLIB_LIBSUFF@%$SHLIB_LIBSUFF%g |
---|
2619 | s%@SHLIB_LIBVERSION@%$SHLIB_LIBVERSION%g |
---|
2620 | s%@SHLIB_LIBS@%$SHLIB_LIBS%g |
---|
2621 | s%@BUILD_DIR@%$BUILD_DIR%g |
---|
2622 | s%@LOCAL_CFLAGS@%$LOCAL_CFLAGS%g |
---|
2623 | s%@LOCAL_LDFLAGS@%$LOCAL_LDFLAGS%g |
---|
2624 | s%@LOCAL_DEFS@%$LOCAL_DEFS%g |
---|
2625 | s%@ARFLAGS@%$ARFLAGS%g |
---|
2626 | s%@LIBVERSION@%$LIBVERSION%g |
---|
2627 | s%@TERMCAP_LIB@%$TERMCAP_LIB%g |
---|
2628 | |
---|
2629 | CEOF |
---|
2630 | EOF |
---|
2631 | |
---|
2632 | cat >> $CONFIG_STATUS <<\EOF |
---|
2633 | |
---|
2634 | # Split the substitutions into bite-sized pieces for seds with |
---|
2635 | # small command number limits, like on Digital OSF/1 and HP-UX. |
---|
2636 | ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script. |
---|
2637 | ac_file=1 # Number of current file. |
---|
2638 | ac_beg=1 # First line for current file. |
---|
2639 | ac_end=$ac_max_sed_cmds # Line after last line for current file. |
---|
2640 | ac_more_lines=: |
---|
2641 | ac_sed_cmds="" |
---|
2642 | while $ac_more_lines; do |
---|
2643 | if test $ac_beg -gt 1; then |
---|
2644 | sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file |
---|
2645 | else |
---|
2646 | sed "${ac_end}q" conftest.subs > conftest.s$ac_file |
---|
2647 | fi |
---|
2648 | if test ! -s conftest.s$ac_file; then |
---|
2649 | ac_more_lines=false |
---|
2650 | rm -f conftest.s$ac_file |
---|
2651 | else |
---|
2652 | if test -z "$ac_sed_cmds"; then |
---|
2653 | ac_sed_cmds="sed -f conftest.s$ac_file" |
---|
2654 | else |
---|
2655 | ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file" |
---|
2656 | fi |
---|
2657 | ac_file=`expr $ac_file + 1` |
---|
2658 | ac_beg=$ac_end |
---|
2659 | ac_end=`expr $ac_end + $ac_max_sed_cmds` |
---|
2660 | fi |
---|
2661 | done |
---|
2662 | if test -z "$ac_sed_cmds"; then |
---|
2663 | ac_sed_cmds=cat |
---|
2664 | fi |
---|
2665 | EOF |
---|
2666 | |
---|
2667 | cat >> $CONFIG_STATUS <<EOF |
---|
2668 | |
---|
2669 | CONFIG_FILES=\${CONFIG_FILES-"Makefile doc/Makefile examples/Makefile shlib/Makefile"} |
---|
2670 | EOF |
---|
2671 | cat >> $CONFIG_STATUS <<\EOF |
---|
2672 | for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then |
---|
2673 | # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". |
---|
2674 | case "$ac_file" in |
---|
2675 | *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'` |
---|
2676 | ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; |
---|
2677 | *) ac_file_in="${ac_file}.in" ;; |
---|
2678 | esac |
---|
2679 | |
---|
2680 | # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories. |
---|
2681 | |
---|
2682 | # Remove last slash and all that follows it. Not all systems have dirname. |
---|
2683 | ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` |
---|
2684 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then |
---|
2685 | # The file is in a subdirectory. |
---|
2686 | test ! -d "$ac_dir" && mkdir "$ac_dir" |
---|
2687 | ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`" |
---|
2688 | # A "../" for each directory in $ac_dir_suffix. |
---|
2689 | ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'` |
---|
2690 | else |
---|
2691 | ac_dir_suffix= ac_dots= |
---|
2692 | fi |
---|
2693 | |
---|
2694 | case "$ac_given_srcdir" in |
---|
2695 | .) srcdir=. |
---|
2696 | if test -z "$ac_dots"; then top_srcdir=. |
---|
2697 | else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;; |
---|
2698 | /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;; |
---|
2699 | *) # Relative path. |
---|
2700 | srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix" |
---|
2701 | top_srcdir="$ac_dots$ac_given_srcdir" ;; |
---|
2702 | esac |
---|
2703 | |
---|
2704 | case "$ac_given_INSTALL" in |
---|
2705 | [/$]*) INSTALL="$ac_given_INSTALL" ;; |
---|
2706 | *) INSTALL="$ac_dots$ac_given_INSTALL" ;; |
---|
2707 | esac |
---|
2708 | |
---|
2709 | echo creating "$ac_file" |
---|
2710 | rm -f "$ac_file" |
---|
2711 | configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure." |
---|
2712 | case "$ac_file" in |
---|
2713 | *Makefile*) ac_comsub="1i\\ |
---|
2714 | # $configure_input" ;; |
---|
2715 | *) ac_comsub= ;; |
---|
2716 | esac |
---|
2717 | |
---|
2718 | ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"` |
---|
2719 | sed -e "$ac_comsub |
---|
2720 | s%@configure_input@%$configure_input%g |
---|
2721 | s%@srcdir@%$srcdir%g |
---|
2722 | s%@top_srcdir@%$top_srcdir%g |
---|
2723 | s%@INSTALL@%$INSTALL%g |
---|
2724 | " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file |
---|
2725 | fi; done |
---|
2726 | rm -f conftest.s* |
---|
2727 | |
---|
2728 | # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where |
---|
2729 | # NAME is the cpp macro being defined and VALUE is the value it is being given. |
---|
2730 | # |
---|
2731 | # ac_d sets the value in "#define NAME VALUE" lines. |
---|
2732 | ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)' |
---|
2733 | ac_dB='\([ ][ ]*\)[^ ]*%\1#\2' |
---|
2734 | ac_dC='\3' |
---|
2735 | ac_dD='%g' |
---|
2736 | # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE". |
---|
2737 | ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' |
---|
2738 | ac_uB='\([ ]\)%\1#\2define\3' |
---|
2739 | ac_uC=' ' |
---|
2740 | ac_uD='\4%g' |
---|
2741 | # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE". |
---|
2742 | ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' |
---|
2743 | ac_eB='$%\1#\2define\3' |
---|
2744 | ac_eC=' ' |
---|
2745 | ac_eD='%g' |
---|
2746 | |
---|
2747 | if test "${CONFIG_HEADERS+set}" != set; then |
---|
2748 | EOF |
---|
2749 | cat >> $CONFIG_STATUS <<EOF |
---|
2750 | CONFIG_HEADERS="config.h" |
---|
2751 | EOF |
---|
2752 | cat >> $CONFIG_STATUS <<\EOF |
---|
2753 | fi |
---|
2754 | for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then |
---|
2755 | # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". |
---|
2756 | case "$ac_file" in |
---|
2757 | *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'` |
---|
2758 | ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; |
---|
2759 | *) ac_file_in="${ac_file}.in" ;; |
---|
2760 | esac |
---|
2761 | |
---|
2762 | echo creating $ac_file |
---|
2763 | |
---|
2764 | rm -f conftest.frag conftest.in conftest.out |
---|
2765 | ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"` |
---|
2766 | cat $ac_file_inputs > conftest.in |
---|
2767 | |
---|
2768 | EOF |
---|
2769 | |
---|
2770 | # Transform confdefs.h into a sed script conftest.vals that substitutes |
---|
2771 | # the proper values into config.h.in to produce config.h. And first: |
---|
2772 | # Protect against being on the right side of a sed subst in config.status. |
---|
2773 | # Protect against being in an unquoted here document in config.status. |
---|
2774 | rm -f conftest.vals |
---|
2775 | cat > conftest.hdr <<\EOF |
---|
2776 | s/[\\&%]/\\&/g |
---|
2777 | s%[\\$`]%\\&%g |
---|
2778 | s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp |
---|
2779 | s%ac_d%ac_u%gp |
---|
2780 | s%ac_u%ac_e%gp |
---|
2781 | EOF |
---|
2782 | sed -n -f conftest.hdr confdefs.h > conftest.vals |
---|
2783 | rm -f conftest.hdr |
---|
2784 | |
---|
2785 | # This sed command replaces #undef with comments. This is necessary, for |
---|
2786 | # example, in the case of _POSIX_SOURCE, which is predefined and required |
---|
2787 | # on some systems where configure will not decide to define it. |
---|
2788 | cat >> conftest.vals <<\EOF |
---|
2789 | s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */% |
---|
2790 | EOF |
---|
2791 | |
---|
2792 | # Break up conftest.vals because some shells have a limit on |
---|
2793 | # the size of here documents, and old seds have small limits too. |
---|
2794 | |
---|
2795 | rm -f conftest.tail |
---|
2796 | while : |
---|
2797 | do |
---|
2798 | ac_lines=`grep -c . conftest.vals` |
---|
2799 | # grep -c gives empty output for an empty file on some AIX systems. |
---|
2800 | if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi |
---|
2801 | # Write a limited-size here document to conftest.frag. |
---|
2802 | echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS |
---|
2803 | sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS |
---|
2804 | echo 'CEOF |
---|
2805 | sed -f conftest.frag conftest.in > conftest.out |
---|
2806 | rm -f conftest.in |
---|
2807 | mv conftest.out conftest.in |
---|
2808 | ' >> $CONFIG_STATUS |
---|
2809 | sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail |
---|
2810 | rm -f conftest.vals |
---|
2811 | mv conftest.tail conftest.vals |
---|
2812 | done |
---|
2813 | rm -f conftest.vals |
---|
2814 | |
---|
2815 | cat >> $CONFIG_STATUS <<\EOF |
---|
2816 | rm -f conftest.frag conftest.h |
---|
2817 | echo "/* $ac_file. Generated automatically by configure. */" > conftest.h |
---|
2818 | cat conftest.in >> conftest.h |
---|
2819 | rm -f conftest.in |
---|
2820 | if cmp -s $ac_file conftest.h 2>/dev/null; then |
---|
2821 | echo "$ac_file is unchanged" |
---|
2822 | rm -f conftest.h |
---|
2823 | else |
---|
2824 | # Remove last slash and all that follows it. Not all systems have dirname. |
---|
2825 | ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` |
---|
2826 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then |
---|
2827 | # The file is in a subdirectory. |
---|
2828 | test ! -d "$ac_dir" && mkdir "$ac_dir" |
---|
2829 | fi |
---|
2830 | rm -f $ac_file |
---|
2831 | mv conftest.h $ac_file |
---|
2832 | fi |
---|
2833 | fi; done |
---|
2834 | |
---|
2835 | EOF |
---|
2836 | cat >> $CONFIG_STATUS <<EOF |
---|
2837 | |
---|
2838 | EOF |
---|
2839 | cat >> $CONFIG_STATUS <<\EOF |
---|
2840 | |
---|
2841 | # Makefile uses this timestamp file to record whether config.h is up to date. |
---|
2842 | echo > stamp-h |
---|
2843 | |
---|
2844 | exit 0 |
---|
2845 | EOF |
---|
2846 | chmod +x $CONFIG_STATUS |
---|
2847 | rm -fr confdefs* $ac_clean_files |
---|
2848 | test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1 |
---|
2849 | |
---|