]>
Commit | Line | Data |
---|---|---|
5436fc65 C |
1 | #! /bin/sh |
2 | ||
3 | # Guess values for system-dependent variables and create Makefiles. | |
ba68ad57 | 4 | # Generated automatically using autoconf version 2.12 |
bc859e63 | 5 | # Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc. |
5436fc65 C |
6 | # |
7 | # This configure script is free software; the Free Software Foundation | |
8 | # gives unlimited permission to copy, distribute and modify it. | |
9 | ||
10 | # Defaults: | |
11 | ac_help= | |
12 | ac_default_prefix=/usr/local | |
13 | # Any additions from configure.in: | |
fcfc3c0c TT |
14 | ac_help="$ac_help |
15 | --disable-nls do not use Native Language Support" | |
16 | ac_help="$ac_help | |
17 | --with-included-gettext use the GNU gettext library included here" | |
5436fc65 C |
18 | ac_help="$ac_help |
19 | --enable-netrom " | |
0728afad | 20 | ac_help="$ac_help |
ba68ad57 JM |
21 | --enable-warnings Enable compiler warnings if gcc is used" |
22 | ac_help="$ac_help | |
23 | --with-mmalloc Use memory mapped malloc package" | |
2476848a MH |
24 | ac_help="$ac_help |
25 | --enable-ide Enable IDE support" | |
c076f1ed | 26 | ac_help="$ac_help |
ba68ad57 | 27 | --with-foundry-libs=DIR Use the Foundry SDK in DIR" |
5436fc65 | 28 | ac_help="$ac_help |
ba68ad57 | 29 | --enable-gdbtk Enable GDBTK GUI front end" |
5436fc65 | 30 | ac_help="$ac_help |
ba68ad57 | 31 | --with-tclconfig=DIR Directory containing tcl configuration (tclConfig.sh)" |
4e327047 | 32 | ac_help="$ac_help |
ba68ad57 | 33 | --with-tkconfig=DIR Directory containing tk configuration (tkConfig.sh)" |
4e327047 | 34 | ac_help="$ac_help |
ba68ad57 | 35 | --with-tclinclude=DIR Directory where tcl private headers are" |
4e327047 | 36 | ac_help="$ac_help |
ba68ad57 | 37 | --with-tkinclude=DIR Directory where tk private headers are" |
b236defa FCE |
38 | ac_help="$ac_help |
39 | --with-x use the X Window System" | |
40 | ac_help="$ac_help | |
ba68ad57 | 41 | --with-sim-gpu2=DIR Use GPU2 library under given DIR" |
75a55dc3 | 42 | ac_help="$ac_help |
ba68ad57 | 43 | --with-sim-funit=DIR Use target FP lib under given DIR" |
1d5eb137 | 44 | ac_help="$ac_help |
ba68ad57 | 45 | --enable-shared Use shared libraries" |
5436fc65 C |
46 | |
47 | # Initialize some variables set by options. | |
48 | # The variables have the same names as the options, with | |
49 | # dashes changed to underlines. | |
50 | build=NONE | |
51 | cache_file=./config.cache | |
52 | exec_prefix=NONE | |
53 | host=NONE | |
54 | no_create= | |
55 | nonopt=NONE | |
56 | no_recursion= | |
57 | prefix=NONE | |
58 | program_prefix=NONE | |
59 | program_suffix=NONE | |
60 | program_transform_name=s,x,x, | |
61 | silent= | |
62 | site= | |
63 | srcdir= | |
64 | target=NONE | |
65 | verbose= | |
66 | x_includes=NONE | |
67 | x_libraries=NONE | |
1a7b4b7c DE |
68 | bindir='${exec_prefix}/bin' |
69 | sbindir='${exec_prefix}/sbin' | |
70 | libexecdir='${exec_prefix}/libexec' | |
71 | datadir='${prefix}/share' | |
72 | sysconfdir='${prefix}/etc' | |
73 | sharedstatedir='${prefix}/com' | |
74 | localstatedir='${prefix}/var' | |
75 | libdir='${exec_prefix}/lib' | |
76 | includedir='${prefix}/include' | |
77 | oldincludedir='/usr/include' | |
78 | infodir='${prefix}/info' | |
79 | mandir='${prefix}/man' | |
5436fc65 C |
80 | |
81 | # Initialize some other variables. | |
82 | subdirs= | |
1a7b4b7c | 83 | MFLAGS= MAKEFLAGS= |
bfde4a67 SG |
84 | # Maximum number of lines to put in a shell here document. |
85 | ac_max_here_lines=12 | |
5436fc65 C |
86 | |
87 | ac_prev= | |
88 | for ac_option | |
89 | do | |
90 | ||
91 | # If the previous option needs an argument, assign it. | |
92 | if test -n "$ac_prev"; then | |
93 | eval "$ac_prev=\$ac_option" | |
94 | ac_prev= | |
95 | continue | |
96 | fi | |
97 | ||
98 | case "$ac_option" in | |
99 | -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;; | |
100 | *) ac_optarg= ;; | |
101 | esac | |
102 | ||
103 | # Accept the important Cygnus configure options, so we can diagnose typos. | |
104 | ||
105 | case "$ac_option" in | |
106 | ||
1a7b4b7c DE |
107 | -bindir | --bindir | --bindi | --bind | --bin | --bi) |
108 | ac_prev=bindir ;; | |
109 | -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) | |
110 | bindir="$ac_optarg" ;; | |
111 | ||
112 | -build | --build | --buil | --bui | --bu) | |
5436fc65 | 113 | ac_prev=build ;; |
1a7b4b7c | 114 | -build=* | --build=* | --buil=* | --bui=* | --bu=*) |
5436fc65 C |
115 | build="$ac_optarg" ;; |
116 | ||
117 | -cache-file | --cache-file | --cache-fil | --cache-fi \ | |
118 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) | |
119 | ac_prev=cache_file ;; | |
120 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | |
121 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) | |
122 | cache_file="$ac_optarg" ;; | |
123 | ||
1a7b4b7c DE |
124 | -datadir | --datadir | --datadi | --datad | --data | --dat | --da) |
125 | ac_prev=datadir ;; | |
126 | -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \ | |
127 | | --da=*) | |
128 | datadir="$ac_optarg" ;; | |
129 | ||
5436fc65 C |
130 | -disable-* | --disable-*) |
131 | ac_feature=`echo $ac_option|sed -e 's/-*disable-//'` | |
132 | # Reject names that are not valid shell variable names. | |
133 | if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then | |
134 | { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } | |
135 | fi | |
136 | ac_feature=`echo $ac_feature| sed 's/-/_/g'` | |
137 | eval "enable_${ac_feature}=no" ;; | |
138 | ||
139 | -enable-* | --enable-*) | |
140 | ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'` | |
141 | # Reject names that are not valid shell variable names. | |
142 | if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then | |
143 | { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } | |
144 | fi | |
145 | ac_feature=`echo $ac_feature| sed 's/-/_/g'` | |
146 | case "$ac_option" in | |
147 | *=*) ;; | |
148 | *) ac_optarg=yes ;; | |
149 | esac | |
150 | eval "enable_${ac_feature}='$ac_optarg'" ;; | |
151 | ||
152 | -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ | |
153 | | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ | |
154 | | --exec | --exe | --ex) | |
155 | ac_prev=exec_prefix ;; | |
156 | -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ | |
157 | | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ | |
158 | | --exec=* | --exe=* | --ex=*) | |
159 | exec_prefix="$ac_optarg" ;; | |
160 | ||
161 | -gas | --gas | --ga | --g) | |
162 | # Obsolete; use --with-gas. | |
163 | with_gas=yes ;; | |
164 | ||
165 | -help | --help | --hel | --he) | |
166 | # Omit some internal or obsolete options to make the list less imposing. | |
167 | # This message is too long to be a string in the A/UX 3.1 sh. | |
168 | cat << EOF | |
169 | Usage: configure [options] [host] | |
170 | Options: [defaults in brackets after descriptions] | |
171 | Configuration: | |
172 | --cache-file=FILE cache test results in FILE | |
173 | --help print this message | |
174 | --no-create do not create output files | |
175 | --quiet, --silent do not print \`checking...' messages | |
176 | --version print the version of autoconf that created configure | |
177 | Directory and file names: | |
178 | --prefix=PREFIX install architecture-independent files in PREFIX | |
179 | [$ac_default_prefix] | |
1a7b4b7c | 180 | --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX |
5436fc65 | 181 | [same as prefix] |
1a7b4b7c DE |
182 | --bindir=DIR user executables in DIR [EPREFIX/bin] |
183 | --sbindir=DIR system admin executables in DIR [EPREFIX/sbin] | |
184 | --libexecdir=DIR program executables in DIR [EPREFIX/libexec] | |
185 | --datadir=DIR read-only architecture-independent data in DIR | |
186 | [PREFIX/share] | |
187 | --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc] | |
188 | --sharedstatedir=DIR modifiable architecture-independent data in DIR | |
189 | [PREFIX/com] | |
190 | --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var] | |
191 | --libdir=DIR object code libraries in DIR [EPREFIX/lib] | |
192 | --includedir=DIR C header files in DIR [PREFIX/include] | |
193 | --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include] | |
194 | --infodir=DIR info documentation in DIR [PREFIX/info] | |
195 | --mandir=DIR man documentation in DIR [PREFIX/man] | |
5436fc65 C |
196 | --srcdir=DIR find the sources in DIR [configure dir or ..] |
197 | --program-prefix=PREFIX prepend PREFIX to installed program names | |
198 | --program-suffix=SUFFIX append SUFFIX to installed program names | |
1a7b4b7c DE |
199 | --program-transform-name=PROGRAM |
200 | run sed PROGRAM on installed program names | |
201 | EOF | |
202 | cat << EOF | |
5436fc65 C |
203 | Host type: |
204 | --build=BUILD configure for building on BUILD [BUILD=HOST] | |
205 | --host=HOST configure for HOST [guessed] | |
206 | --target=TARGET configure for TARGET [TARGET=HOST] | |
207 | Features and packages: | |
208 | --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) | |
209 | --enable-FEATURE[=ARG] include FEATURE [ARG=yes] | |
210 | --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] | |
211 | --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) | |
212 | --x-includes=DIR X include files are in DIR | |
213 | --x-libraries=DIR X library files are in DIR | |
5436fc65 | 214 | EOF |
1a7b4b7c DE |
215 | if test -n "$ac_help"; then |
216 | echo "--enable and --with options recognized:$ac_help" | |
217 | fi | |
5436fc65 C |
218 | exit 0 ;; |
219 | ||
220 | -host | --host | --hos | --ho) | |
221 | ac_prev=host ;; | |
222 | -host=* | --host=* | --hos=* | --ho=*) | |
223 | host="$ac_optarg" ;; | |
224 | ||
1a7b4b7c DE |
225 | -includedir | --includedir | --includedi | --included | --include \ |
226 | | --includ | --inclu | --incl | --inc) | |
227 | ac_prev=includedir ;; | |
228 | -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ | |
229 | | --includ=* | --inclu=* | --incl=* | --inc=*) | |
230 | includedir="$ac_optarg" ;; | |
231 | ||
232 | -infodir | --infodir | --infodi | --infod | --info | --inf) | |
233 | ac_prev=infodir ;; | |
234 | -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) | |
235 | infodir="$ac_optarg" ;; | |
236 | ||
237 | -libdir | --libdir | --libdi | --libd) | |
238 | ac_prev=libdir ;; | |
239 | -libdir=* | --libdir=* | --libdi=* | --libd=*) | |
240 | libdir="$ac_optarg" ;; | |
241 | ||
242 | -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ | |
243 | | --libexe | --libex | --libe) | |
244 | ac_prev=libexecdir ;; | |
245 | -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ | |
246 | | --libexe=* | --libex=* | --libe=*) | |
247 | libexecdir="$ac_optarg" ;; | |
248 | ||
249 | -localstatedir | --localstatedir | --localstatedi | --localstated \ | |
250 | | --localstate | --localstat | --localsta | --localst \ | |
251 | | --locals | --local | --loca | --loc | --lo) | |
252 | ac_prev=localstatedir ;; | |
253 | -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ | |
254 | | --localstate=* | --localstat=* | --localsta=* | --localst=* \ | |
255 | | --locals=* | --local=* | --loca=* | --loc=* | --lo=*) | |
256 | localstatedir="$ac_optarg" ;; | |
257 | ||
258 | -mandir | --mandir | --mandi | --mand | --man | --ma | --m) | |
259 | ac_prev=mandir ;; | |
260 | -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) | |
261 | mandir="$ac_optarg" ;; | |
262 | ||
5436fc65 C |
263 | -nfp | --nfp | --nf) |
264 | # Obsolete; use --without-fp. | |
265 | with_fp=no ;; | |
266 | ||
267 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | |
268 | | --no-cr | --no-c) | |
269 | no_create=yes ;; | |
270 | ||
271 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ | |
272 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) | |
273 | no_recursion=yes ;; | |
274 | ||
1a7b4b7c DE |
275 | -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ |
276 | | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ | |
277 | | --oldin | --oldi | --old | --ol | --o) | |
278 | ac_prev=oldincludedir ;; | |
279 | -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ | |
280 | | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ | |
281 | | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) | |
282 | oldincludedir="$ac_optarg" ;; | |
283 | ||
5436fc65 C |
284 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) |
285 | ac_prev=prefix ;; | |
286 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) | |
287 | prefix="$ac_optarg" ;; | |
288 | ||
289 | -program-prefix | --program-prefix | --program-prefi | --program-pref \ | |
290 | | --program-pre | --program-pr | --program-p) | |
291 | ac_prev=program_prefix ;; | |
292 | -program-prefix=* | --program-prefix=* | --program-prefi=* \ | |
293 | | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) | |
294 | program_prefix="$ac_optarg" ;; | |
295 | ||
296 | -program-suffix | --program-suffix | --program-suffi | --program-suff \ | |
297 | | --program-suf | --program-su | --program-s) | |
298 | ac_prev=program_suffix ;; | |
299 | -program-suffix=* | --program-suffix=* | --program-suffi=* \ | |
300 | | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) | |
301 | program_suffix="$ac_optarg" ;; | |
302 | ||
303 | -program-transform-name | --program-transform-name \ | |
304 | | --program-transform-nam | --program-transform-na \ | |
305 | | --program-transform-n | --program-transform- \ | |
306 | | --program-transform | --program-transfor \ | |
307 | | --program-transfo | --program-transf \ | |
308 | | --program-trans | --program-tran \ | |
309 | | --progr-tra | --program-tr | --program-t) | |
310 | ac_prev=program_transform_name ;; | |
311 | -program-transform-name=* | --program-transform-name=* \ | |
312 | | --program-transform-nam=* | --program-transform-na=* \ | |
313 | | --program-transform-n=* | --program-transform-=* \ | |
314 | | --program-transform=* | --program-transfor=* \ | |
315 | | --program-transfo=* | --program-transf=* \ | |
316 | | --program-trans=* | --program-tran=* \ | |
317 | | --progr-tra=* | --program-tr=* | --program-t=*) | |
318 | program_transform_name="$ac_optarg" ;; | |
319 | ||
320 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | |
321 | | -silent | --silent | --silen | --sile | --sil) | |
322 | silent=yes ;; | |
323 | ||
1a7b4b7c DE |
324 | -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) |
325 | ac_prev=sbindir ;; | |
326 | -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ | |
327 | | --sbi=* | --sb=*) | |
328 | sbindir="$ac_optarg" ;; | |
329 | ||
330 | -sharedstatedir | --sharedstatedir | --sharedstatedi \ | |
331 | | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ | |
332 | | --sharedst | --shareds | --shared | --share | --shar \ | |
333 | | --sha | --sh) | |
334 | ac_prev=sharedstatedir ;; | |
335 | -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ | |
336 | | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ | |
337 | | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ | |
338 | | --sha=* | --sh=*) | |
339 | sharedstatedir="$ac_optarg" ;; | |
340 | ||
5436fc65 C |
341 | -site | --site | --sit) |
342 | ac_prev=site ;; | |
343 | -site=* | --site=* | --sit=*) | |
344 | site="$ac_optarg" ;; | |
345 | ||
346 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) | |
347 | ac_prev=srcdir ;; | |
348 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) | |
349 | srcdir="$ac_optarg" ;; | |
350 | ||
1a7b4b7c DE |
351 | -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ |
352 | | --syscon | --sysco | --sysc | --sys | --sy) | |
353 | ac_prev=sysconfdir ;; | |
354 | -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ | |
355 | | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) | |
356 | sysconfdir="$ac_optarg" ;; | |
357 | ||
5436fc65 C |
358 | -target | --target | --targe | --targ | --tar | --ta | --t) |
359 | ac_prev=target ;; | |
360 | -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) | |
361 | target="$ac_optarg" ;; | |
362 | ||
363 | -v | -verbose | --verbose | --verbos | --verbo | --verb) | |
364 | verbose=yes ;; | |
365 | ||
366 | -version | --version | --versio | --versi | --vers) | |
ba68ad57 | 367 | echo "configure generated by autoconf version 2.12" |
5436fc65 C |
368 | exit 0 ;; |
369 | ||
370 | -with-* | --with-*) | |
371 | ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'` | |
372 | # Reject names that are not valid shell variable names. | |
373 | if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then | |
374 | { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } | |
375 | fi | |
376 | ac_package=`echo $ac_package| sed 's/-/_/g'` | |
377 | case "$ac_option" in | |
378 | *=*) ;; | |
379 | *) ac_optarg=yes ;; | |
380 | esac | |
381 | eval "with_${ac_package}='$ac_optarg'" ;; | |
382 | ||
383 | -without-* | --without-*) | |
384 | ac_package=`echo $ac_option|sed -e 's/-*without-//'` | |
385 | # Reject names that are not valid shell variable names. | |
386 | if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then | |
387 | { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } | |
388 | fi | |
389 | ac_package=`echo $ac_package| sed 's/-/_/g'` | |
390 | eval "with_${ac_package}=no" ;; | |
391 | ||
392 | --x) | |
393 | # Obsolete; use --with-x. | |
394 | with_x=yes ;; | |
395 | ||
396 | -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ | |
397 | | --x-incl | --x-inc | --x-in | --x-i) | |
398 | ac_prev=x_includes ;; | |
399 | -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ | |
400 | | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) | |
401 | x_includes="$ac_optarg" ;; | |
402 | ||
403 | -x-libraries | --x-libraries | --x-librarie | --x-librari \ | |
404 | | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) | |
405 | ac_prev=x_libraries ;; | |
406 | -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ | |
407 | | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) | |
408 | x_libraries="$ac_optarg" ;; | |
409 | ||
410 | -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; } | |
411 | ;; | |
412 | ||
1a7b4b7c | 413 | *) |
5436fc65 C |
414 | if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then |
415 | echo "configure: warning: $ac_option: invalid host type" 1>&2 | |
416 | fi | |
417 | if test "x$nonopt" != xNONE; then | |
418 | { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } | |
419 | fi | |
420 | nonopt="$ac_option" | |
421 | ;; | |
422 | ||
423 | esac | |
424 | done | |
425 | ||
426 | if test -n "$ac_prev"; then | |
427 | { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; } | |
428 | fi | |
429 | ||
430 | trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 | |
431 | ||
432 | # File descriptor usage: | |
433 | # 0 standard input | |
434 | # 1 file creation | |
435 | # 2 errors and warnings | |
436 | # 3 some systems may open it to /dev/tty | |
437 | # 4 used on the Kubota Titan | |
438 | # 6 checking for... messages and results | |
439 | # 5 compiler messages saved in config.log | |
440 | if test "$silent" = yes; then | |
441 | exec 6>/dev/null | |
442 | else | |
443 | exec 6>&1 | |
444 | fi | |
445 | exec 5>./config.log | |
446 | ||
447 | echo "\ | |
448 | This file contains any messages produced by compilers while | |
449 | running configure, to aid debugging if configure makes a mistake. | |
450 | " 1>&5 | |
451 | ||
452 | # Strip out --no-create and --no-recursion so they do not pile up. | |
453 | # Also quote any args containing shell metacharacters. | |
454 | ac_configure_args= | |
455 | for ac_arg | |
456 | do | |
457 | case "$ac_arg" in | |
458 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | |
459 | | --no-cr | --no-c) ;; | |
460 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ | |
461 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;; | |
462 | *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*) | |
463 | ac_configure_args="$ac_configure_args '$ac_arg'" ;; | |
464 | *) ac_configure_args="$ac_configure_args $ac_arg" ;; | |
465 | esac | |
466 | done | |
467 | ||
468 | # NLS nuisances. | |
bfde4a67 SG |
469 | # Only set these to C if already set. These must not be set unconditionally |
470 | # because not all systems understand e.g. LANG=C (notably SCO). | |
471 | # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'! | |
472 | # Non-C LC_CTYPE values break the ctype check. | |
ef6c51d1 | 473 | if test "${LANG+set}" = set; then LANG=C; export LANG; fi |
bfde4a67 SG |
474 | if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi |
475 | if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi | |
476 | if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi | |
5436fc65 C |
477 | |
478 | # confdefs.h avoids OS command line length limits that DEFS can exceed. | |
479 | rm -rf conftest* confdefs.h | |
480 | # AIX cpp loses on an empty file, so make sure it contains at least a newline. | |
481 | echo > confdefs.h | |
482 | ||
483 | # A filename unique to this package, relative to the directory that | |
484 | # configure is in, which we can look for to find out if srcdir is correct. | |
485 | ac_unique_file=main.c | |
486 | ||
487 | # Find the source files, if location was not specified. | |
488 | if test -z "$srcdir"; then | |
489 | ac_srcdir_defaulted=yes | |
490 | # Try the directory containing this script, then its parent. | |
491 | ac_prog=$0 | |
492 | ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'` | |
493 | test "x$ac_confdir" = "x$ac_prog" && ac_confdir=. | |
494 | srcdir=$ac_confdir | |
495 | if test ! -r $srcdir/$ac_unique_file; then | |
496 | srcdir=.. | |
497 | fi | |
498 | else | |
499 | ac_srcdir_defaulted=no | |
500 | fi | |
501 | if test ! -r $srcdir/$ac_unique_file; then | |
502 | if test "$ac_srcdir_defaulted" = yes; then | |
503 | { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; } | |
504 | else | |
505 | { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; } | |
506 | fi | |
507 | fi | |
508 | srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'` | |
509 | ||
510 | # Prefer explicitly selected file to automatically selected ones. | |
511 | if test -z "$CONFIG_SITE"; then | |
512 | if test "x$prefix" != xNONE; then | |
513 | CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site" | |
514 | else | |
515 | CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site" | |
516 | fi | |
517 | fi | |
518 | for ac_site_file in $CONFIG_SITE; do | |
519 | if test -r "$ac_site_file"; then | |
520 | echo "loading site script $ac_site_file" | |
521 | . "$ac_site_file" | |
522 | fi | |
523 | done | |
524 | ||
525 | if test -r "$cache_file"; then | |
526 | echo "loading cache $cache_file" | |
527 | . $cache_file | |
528 | else | |
529 | echo "creating cache $cache_file" | |
530 | > $cache_file | |
531 | fi | |
532 | ||
533 | ac_ext=c | |
534 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. | |
3dedc867 | 535 | ac_cpp='$CPP $CPPFLAGS' |
1a7b4b7c | 536 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' |
ba68ad57 | 537 | ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' |
bfde4a67 | 538 | cross_compiling=$ac_cv_prog_cc_cross |
5436fc65 C |
539 | |
540 | if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then | |
541 | # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu. | |
542 | if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then | |
543 | ac_n= ac_c=' | |
544 | ' ac_t=' ' | |
545 | else | |
546 | ac_n=-n ac_c= ac_t= | |
547 | fi | |
548 | else | |
549 | ac_n= ac_c='\c' ac_t= | |
550 | fi | |
551 | ||
552 | ||
553 | ||
db210d08 | 554 | |
5436fc65 C |
555 | # Extract the first word of "gcc", so it can be a program name with args. |
556 | set dummy gcc; ac_word=$2 | |
557 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
ba68ad57 | 558 | echo "configure:559: checking for $ac_word" >&5 |
5436fc65 C |
559 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
560 | echo $ac_n "(cached) $ac_c" 1>&6 | |
561 | else | |
562 | if test -n "$CC"; then | |
563 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
564 | else | |
ba68ad57 | 565 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" |
da3d57e3 | 566 | for ac_dir in $PATH; do |
5436fc65 C |
567 | test -z "$ac_dir" && ac_dir=. |
568 | if test -f $ac_dir/$ac_word; then | |
569 | ac_cv_prog_CC="gcc" | |
570 | break | |
571 | fi | |
572 | done | |
573 | IFS="$ac_save_ifs" | |
5436fc65 C |
574 | fi |
575 | fi | |
576 | CC="$ac_cv_prog_CC" | |
577 | if test -n "$CC"; then | |
578 | echo "$ac_t""$CC" 1>&6 | |
579 | else | |
580 | echo "$ac_t""no" 1>&6 | |
581 | fi | |
582 | ||
1a7b4b7c DE |
583 | if test -z "$CC"; then |
584 | # Extract the first word of "cc", so it can be a program name with args. | |
585 | set dummy cc; ac_word=$2 | |
586 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
ba68ad57 | 587 | echo "configure:588: checking for $ac_word" >&5 |
1a7b4b7c DE |
588 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
589 | echo $ac_n "(cached) $ac_c" 1>&6 | |
590 | else | |
591 | if test -n "$CC"; then | |
592 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
593 | else | |
ba68ad57 | 594 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" |
1a7b4b7c DE |
595 | ac_prog_rejected=no |
596 | for ac_dir in $PATH; do | |
597 | test -z "$ac_dir" && ac_dir=. | |
598 | if test -f $ac_dir/$ac_word; then | |
599 | if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then | |
600 | ac_prog_rejected=yes | |
601 | continue | |
602 | fi | |
603 | ac_cv_prog_CC="cc" | |
604 | break | |
605 | fi | |
606 | done | |
607 | IFS="$ac_save_ifs" | |
608 | if test $ac_prog_rejected = yes; then | |
609 | # We found a bogon in the path, so make sure we never use it. | |
610 | set dummy $ac_cv_prog_CC | |
611 | shift | |
612 | if test $# -gt 0; then | |
613 | # We chose a different compiler from the bogus one. | |
614 | # However, it has the same basename, so the bogon will be chosen | |
615 | # first if we set CC to just the basename; use the full file name. | |
616 | shift | |
617 | set dummy "$ac_dir/$ac_word" "$@" | |
618 | shift | |
619 | ac_cv_prog_CC="$@" | |
620 | fi | |
621 | fi | |
622 | fi | |
623 | fi | |
624 | CC="$ac_cv_prog_CC" | |
625 | if test -n "$CC"; then | |
626 | echo "$ac_t""$CC" 1>&6 | |
627 | else | |
628 | echo "$ac_t""no" 1>&6 | |
629 | fi | |
630 | ||
631 | test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; } | |
632 | fi | |
5436fc65 | 633 | |
bfde4a67 | 634 | echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 |
ba68ad57 | 635 | echo "configure:636: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 |
bfde4a67 SG |
636 | |
637 | ac_ext=c | |
638 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. | |
639 | ac_cpp='$CPP $CPPFLAGS' | |
640 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' | |
ba68ad57 | 641 | ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' |
bfde4a67 SG |
642 | cross_compiling=$ac_cv_prog_cc_cross |
643 | ||
644 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 645 | #line 646 "configure" |
bfde4a67 SG |
646 | #include "confdefs.h" |
647 | main(){return(0);} | |
648 | EOF | |
ba68ad57 | 649 | if { (eval echo configure:650: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
bfde4a67 SG |
650 | ac_cv_prog_cc_works=yes |
651 | # If we can't run a trivial program, we are probably using a cross compiler. | |
652 | if (./conftest; exit) 2>/dev/null; then | |
653 | ac_cv_prog_cc_cross=no | |
654 | else | |
655 | ac_cv_prog_cc_cross=yes | |
656 | fi | |
657 | else | |
658 | echo "configure: failed program was:" >&5 | |
659 | cat conftest.$ac_ext >&5 | |
660 | ac_cv_prog_cc_works=no | |
661 | fi | |
662 | rm -fr conftest* | |
663 | ||
664 | echo "$ac_t""$ac_cv_prog_cc_works" 1>&6 | |
665 | if test $ac_cv_prog_cc_works = no; then | |
666 | { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; } | |
667 | fi | |
668 | echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 | |
ba68ad57 | 669 | echo "configure:670: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 |
bfde4a67 SG |
670 | echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6 |
671 | cross_compiling=$ac_cv_prog_cc_cross | |
672 | ||
5436fc65 | 673 | echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6 |
ba68ad57 | 674 | echo "configure:675: checking whether we are using GNU C" >&5 |
5436fc65 C |
675 | if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then |
676 | echo $ac_n "(cached) $ac_c" 1>&6 | |
677 | else | |
678 | cat > conftest.c <<EOF | |
679 | #ifdef __GNUC__ | |
680 | yes; | |
681 | #endif | |
682 | EOF | |
ba68ad57 | 683 | if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:684: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then |
5436fc65 C |
684 | ac_cv_prog_gcc=yes |
685 | else | |
686 | ac_cv_prog_gcc=no | |
687 | fi | |
688 | fi | |
1a7b4b7c | 689 | |
5436fc65 | 690 | echo "$ac_t""$ac_cv_prog_gcc" 1>&6 |
bfde4a67 | 691 | |
5436fc65 C |
692 | if test $ac_cv_prog_gcc = yes; then |
693 | GCC=yes | |
ba68ad57 JM |
694 | ac_test_CFLAGS="${CFLAGS+set}" |
695 | ac_save_CFLAGS="$CFLAGS" | |
696 | CFLAGS= | |
697 | echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 | |
698 | echo "configure:699: checking whether ${CC-cc} accepts -g" >&5 | |
bfde4a67 | 699 | if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then |
5436fc65 C |
700 | echo $ac_n "(cached) $ac_c" 1>&6 |
701 | else | |
702 | echo 'void f(){}' > conftest.c | |
703 | if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then | |
bfde4a67 | 704 | ac_cv_prog_cc_g=yes |
5436fc65 | 705 | else |
bfde4a67 | 706 | ac_cv_prog_cc_g=no |
5436fc65 C |
707 | fi |
708 | rm -f conftest* | |
709 | ||
710 | fi | |
1a7b4b7c | 711 | |
bfde4a67 | 712 | echo "$ac_t""$ac_cv_prog_cc_g" 1>&6 |
ba68ad57 JM |
713 | if test "$ac_test_CFLAGS" = set; then |
714 | CFLAGS="$ac_save_CFLAGS" | |
715 | elif test $ac_cv_prog_cc_g = yes; then | |
bfde4a67 SG |
716 | CFLAGS="-g -O2" |
717 | else | |
6ee3e5d6 | 718 | CFLAGS="-O2" |
6ee3e5d6 | 719 | fi |
ba68ad57 JM |
720 | else |
721 | GCC= | |
722 | test "${CFLAGS+set}" = set || CFLAGS="-g" | |
5436fc65 C |
723 | fi |
724 | ||
725 | echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6 | |
ba68ad57 | 726 | echo "configure:727: checking how to run the C preprocessor" >&5 |
5436fc65 C |
727 | # On Suns, sometimes $CPP names a directory. |
728 | if test -n "$CPP" && test -d "$CPP"; then | |
729 | CPP= | |
730 | fi | |
731 | if test -z "$CPP"; then | |
732 | if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then | |
733 | echo $ac_n "(cached) $ac_c" 1>&6 | |
734 | else | |
735 | # This must be in double quotes, not single quotes, because CPP may get | |
736 | # substituted into the Makefile and "${CC-cc}" will confuse make. | |
737 | CPP="${CC-cc} -E" | |
738 | # On the NeXT, cc -E runs the code through the compiler's parser, | |
739 | # not just through cpp. | |
740 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 741 | #line 742 "configure" |
5436fc65 C |
742 | #include "confdefs.h" |
743 | #include <assert.h> | |
744 | Syntax Error | |
745 | EOF | |
1a7b4b7c | 746 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
ba68ad57 JM |
747 | { (eval echo configure:748: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
748 | ac_err=`grep -v '^ *+' conftest.out` | |
5436fc65 C |
749 | if test -z "$ac_err"; then |
750 | : | |
751 | else | |
752 | echo "$ac_err" >&5 | |
bfde4a67 SG |
753 | echo "configure: failed program was:" >&5 |
754 | cat conftest.$ac_ext >&5 | |
5436fc65 C |
755 | rm -rf conftest* |
756 | CPP="${CC-cc} -E -traditional-cpp" | |
757 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 758 | #line 759 "configure" |
eac4afd1 JM |
759 | #include "confdefs.h" |
760 | #include <assert.h> | |
761 | Syntax Error | |
762 | EOF | |
763 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
ba68ad57 JM |
764 | { (eval echo configure:765: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
765 | ac_err=`grep -v '^ *+' conftest.out` | |
5436fc65 C |
766 | if test -z "$ac_err"; then |
767 | : | |
768 | else | |
769 | echo "$ac_err" >&5 | |
bfde4a67 SG |
770 | echo "configure: failed program was:" >&5 |
771 | cat conftest.$ac_ext >&5 | |
5436fc65 | 772 | rm -rf conftest* |
fcfc3c0c TT |
773 | CPP=/lib/cpp |
774 | fi | |
775 | rm -f conftest* | |
776 | fi | |
777 | rm -f conftest* | |
778 | ac_cv_prog_CPP="$CPP" | |
779 | fi | |
780 | CPP="$ac_cv_prog_CPP" | |
781 | else | |
782 | ac_cv_prog_CPP="$CPP" | |
783 | fi | |
784 | echo "$ac_t""$CPP" 1>&6 | |
785 | ||
786 | echo $ac_n "checking for AIX""... $ac_c" 1>&6 | |
ba68ad57 | 787 | echo "configure:788: checking for AIX" >&5 |
fcfc3c0c | 788 | cat > conftest.$ac_ext <<EOF |
ba68ad57 | 789 | #line 790 "configure" |
fcfc3c0c TT |
790 | #include "confdefs.h" |
791 | #ifdef _AIX | |
792 | yes | |
793 | #endif | |
794 | ||
795 | EOF | |
796 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
797 | egrep "yes" >/dev/null 2>&1; then | |
798 | rm -rf conftest* | |
799 | echo "$ac_t""yes" 1>&6; cat >> confdefs.h <<\EOF | |
800 | #define _ALL_SOURCE 1 | |
801 | EOF | |
802 | ||
803 | else | |
804 | rm -rf conftest* | |
805 | echo "$ac_t""no" 1>&6 | |
806 | fi | |
807 | rm -f conftest* | |
808 | ||
809 | ||
810 | ac_safe=`echo "minix/config.h" | sed 'y%./+-%__p_%'` | |
811 | echo $ac_n "checking for minix/config.h""... $ac_c" 1>&6 | |
ba68ad57 | 812 | echo "configure:813: checking for minix/config.h" >&5 |
fcfc3c0c TT |
813 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
814 | echo $ac_n "(cached) $ac_c" 1>&6 | |
815 | else | |
816 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 817 | #line 818 "configure" |
fcfc3c0c TT |
818 | #include "confdefs.h" |
819 | #include <minix/config.h> | |
820 | EOF | |
821 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
ba68ad57 JM |
822 | { (eval echo configure:823: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
823 | ac_err=`grep -v '^ *+' conftest.out` | |
fcfc3c0c TT |
824 | if test -z "$ac_err"; then |
825 | rm -rf conftest* | |
826 | eval "ac_cv_header_$ac_safe=yes" | |
827 | else | |
828 | echo "$ac_err" >&5 | |
829 | echo "configure: failed program was:" >&5 | |
830 | cat conftest.$ac_ext >&5 | |
831 | rm -rf conftest* | |
832 | eval "ac_cv_header_$ac_safe=no" | |
833 | fi | |
834 | rm -f conftest* | |
835 | fi | |
836 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | |
837 | echo "$ac_t""yes" 1>&6 | |
838 | MINIX=yes | |
839 | else | |
840 | echo "$ac_t""no" 1>&6 | |
841 | MINIX= | |
842 | fi | |
843 | ||
844 | if test "$MINIX" = yes; then | |
845 | cat >> confdefs.h <<\EOF | |
846 | #define _POSIX_SOURCE 1 | |
847 | EOF | |
848 | ||
849 | cat >> confdefs.h <<\EOF | |
850 | #define _POSIX_1_SOURCE 2 | |
851 | EOF | |
852 | ||
853 | cat >> confdefs.h <<\EOF | |
854 | #define _MINIX 1 | |
855 | EOF | |
856 | ||
857 | fi | |
858 | ||
859 | echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6 | |
ba68ad57 | 860 | echo "configure:861: checking for POSIXized ISC" >&5 |
fcfc3c0c TT |
861 | if test -d /etc/conf/kconfig.d && |
862 | grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1 | |
863 | then | |
864 | echo "$ac_t""yes" 1>&6 | |
865 | ISC=yes # If later tests want to check for ISC. | |
866 | cat >> confdefs.h <<\EOF | |
867 | #define _POSIX_SOURCE 1 | |
868 | EOF | |
869 | ||
870 | if test "$GCC" = yes; then | |
871 | CC="$CC -posix" | |
872 | else | |
873 | CC="$CC -Xp" | |
874 | fi | |
875 | else | |
876 | echo "$ac_t""no" 1>&6 | |
877 | ISC= | |
878 | fi | |
879 | ||
880 | ||
881 | DLLTOOL=${DLLTOOL-dlltool} | |
882 | ||
883 | ||
884 | ac_aux_dir= | |
885 | for ac_dir in `cd $srcdir;pwd`/.. $srcdir/`cd $srcdir;pwd`/..; do | |
886 | if test -f $ac_dir/install-sh; then | |
887 | ac_aux_dir=$ac_dir | |
888 | ac_install_sh="$ac_aux_dir/install-sh -c" | |
889 | break | |
890 | elif test -f $ac_dir/install.sh; then | |
891 | ac_aux_dir=$ac_dir | |
892 | ac_install_sh="$ac_aux_dir/install.sh -c" | |
893 | break | |
894 | fi | |
895 | done | |
896 | if test -z "$ac_aux_dir"; then | |
897 | { echo "configure: error: can not find install-sh or install.sh in `cd $srcdir;pwd`/.. $srcdir/`cd $srcdir;pwd`/.." 1>&2; exit 1; } | |
898 | fi | |
899 | ac_config_guess=$ac_aux_dir/config.guess | |
900 | ac_config_sub=$ac_aux_dir/config.sub | |
901 | ac_configure=$ac_aux_dir/configure # This should be Cygnus configure. | |
902 | ||
903 | ||
904 | # Do some error checking and defaulting for the host and target type. | |
905 | # The inputs are: | |
906 | # configure --host=HOST --target=TARGET --build=BUILD NONOPT | |
907 | # | |
908 | # The rules are: | |
909 | # 1. You are not allowed to specify --host, --target, and nonopt at the | |
910 | # same time. | |
911 | # 2. Host defaults to nonopt. | |
912 | # 3. If nonopt is not specified, then host defaults to the current host, | |
913 | # as determined by config.guess. | |
914 | # 4. Target and build default to nonopt. | |
915 | # 5. If nonopt is not specified, then target and build default to host. | |
916 | ||
917 | # The aliases save the names the user supplied, while $host etc. | |
918 | # will get canonicalized. | |
919 | case $host---$target---$nonopt in | |
920 | NONE---*---* | *---NONE---* | *---*---NONE) ;; | |
921 | *) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;; | |
922 | esac | |
923 | ||
924 | ||
925 | # Make sure we can run config.sub. | |
ba68ad57 | 926 | if $ac_config_sub sun4 >/dev/null 2>&1; then : |
fcfc3c0c TT |
927 | else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; } |
928 | fi | |
929 | ||
930 | echo $ac_n "checking host system type""... $ac_c" 1>&6 | |
ba68ad57 | 931 | echo "configure:932: checking host system type" >&5 |
fcfc3c0c TT |
932 | |
933 | host_alias=$host | |
934 | case "$host_alias" in | |
935 | NONE) | |
936 | case $nonopt in | |
937 | NONE) | |
ba68ad57 | 938 | if host_alias=`$ac_config_guess`; then : |
fcfc3c0c TT |
939 | else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; } |
940 | fi ;; | |
941 | *) host_alias=$nonopt ;; | |
942 | esac ;; | |
943 | esac | |
944 | ||
ba68ad57 | 945 | host=`$ac_config_sub $host_alias` |
fcfc3c0c TT |
946 | host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` |
947 | host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` | |
948 | host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` | |
949 | echo "$ac_t""$host" 1>&6 | |
950 | ||
951 | echo $ac_n "checking target system type""... $ac_c" 1>&6 | |
ba68ad57 | 952 | echo "configure:953: checking target system type" >&5 |
fcfc3c0c TT |
953 | |
954 | target_alias=$target | |
955 | case "$target_alias" in | |
956 | NONE) | |
957 | case $nonopt in | |
958 | NONE) target_alias=$host_alias ;; | |
959 | *) target_alias=$nonopt ;; | |
960 | esac ;; | |
961 | esac | |
962 | ||
ba68ad57 | 963 | target=`$ac_config_sub $target_alias` |
fcfc3c0c TT |
964 | target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` |
965 | target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` | |
966 | target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` | |
967 | echo "$ac_t""$target" 1>&6 | |
968 | ||
969 | echo $ac_n "checking build system type""... $ac_c" 1>&6 | |
ba68ad57 | 970 | echo "configure:971: checking build system type" >&5 |
fcfc3c0c TT |
971 | |
972 | build_alias=$build | |
973 | case "$build_alias" in | |
974 | NONE) | |
975 | case $nonopt in | |
976 | NONE) build_alias=$host_alias ;; | |
977 | *) build_alias=$nonopt ;; | |
978 | esac ;; | |
979 | esac | |
980 | ||
ba68ad57 | 981 | build=`$ac_config_sub $build_alias` |
fcfc3c0c TT |
982 | build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` |
983 | build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` | |
984 | build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` | |
985 | echo "$ac_t""$build" 1>&6 | |
986 | ||
987 | test "$host_alias" != "$target_alias" && | |
988 | test "$program_prefix$program_suffix$program_transform_name" = \ | |
989 | NONENONEs,x,x, && | |
990 | program_prefix=${target_alias}- | |
991 | ||
992 | ||
993 | ALL_LINGUAS= | |
994 | echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6 | |
ba68ad57 | 995 | echo "configure:996: checking whether ${MAKE-make} sets \${MAKE}" >&5 |
fcfc3c0c TT |
996 | set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'` |
997 | if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then | |
998 | echo $ac_n "(cached) $ac_c" 1>&6 | |
999 | else | |
1000 | cat > conftestmake <<\EOF | |
1001 | all: | |
1002 | @echo 'ac_maketemp="${MAKE}"' | |
1003 | EOF | |
1004 | # GNU make sometimes prints "make[1]: Entering...", which would confuse us. | |
1005 | eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=` | |
1006 | if test -n "$ac_maketemp"; then | |
1007 | eval ac_cv_prog_make_${ac_make}_set=yes | |
1008 | else | |
1009 | eval ac_cv_prog_make_${ac_make}_set=no | |
1010 | fi | |
1011 | rm -f conftestmake | |
1012 | fi | |
1013 | if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then | |
1014 | echo "$ac_t""yes" 1>&6 | |
1015 | SET_MAKE= | |
1016 | else | |
1017 | echo "$ac_t""no" 1>&6 | |
1018 | SET_MAKE="MAKE=${MAKE-make}" | |
1019 | fi | |
1020 | ||
1021 | # Extract the first word of "ranlib", so it can be a program name with args. | |
1022 | set dummy ranlib; ac_word=$2 | |
1023 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
ba68ad57 | 1024 | echo "configure:1025: checking for $ac_word" >&5 |
fcfc3c0c TT |
1025 | if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then |
1026 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1027 | else | |
1028 | if test -n "$RANLIB"; then | |
1029 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. | |
1030 | else | |
ba68ad57 | 1031 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" |
fcfc3c0c TT |
1032 | for ac_dir in $PATH; do |
1033 | test -z "$ac_dir" && ac_dir=. | |
1034 | if test -f $ac_dir/$ac_word; then | |
1035 | ac_cv_prog_RANLIB="ranlib" | |
1036 | break | |
1037 | fi | |
1038 | done | |
1039 | IFS="$ac_save_ifs" | |
1040 | test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":" | |
1041 | fi | |
1042 | fi | |
1043 | RANLIB="$ac_cv_prog_RANLIB" | |
1044 | if test -n "$RANLIB"; then | |
1045 | echo "$ac_t""$RANLIB" 1>&6 | |
1046 | else | |
1047 | echo "$ac_t""no" 1>&6 | |
1048 | fi | |
1049 | ||
1050 | echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6 | |
ba68ad57 | 1051 | echo "configure:1052: checking for ANSI C header files" >&5 |
fcfc3c0c TT |
1052 | if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then |
1053 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1054 | else | |
1055 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 1056 | #line 1057 "configure" |
fcfc3c0c TT |
1057 | #include "confdefs.h" |
1058 | #include <stdlib.h> | |
1059 | #include <stdarg.h> | |
1060 | #include <string.h> | |
1061 | #include <float.h> | |
1062 | EOF | |
1063 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
ba68ad57 JM |
1064 | { (eval echo configure:1065: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
1065 | ac_err=`grep -v '^ *+' conftest.out` | |
fcfc3c0c TT |
1066 | if test -z "$ac_err"; then |
1067 | rm -rf conftest* | |
1068 | ac_cv_header_stdc=yes | |
1069 | else | |
1070 | echo "$ac_err" >&5 | |
1071 | echo "configure: failed program was:" >&5 | |
1072 | cat conftest.$ac_ext >&5 | |
1073 | rm -rf conftest* | |
1074 | ac_cv_header_stdc=no | |
1075 | fi | |
1076 | rm -f conftest* | |
1077 | ||
1078 | if test $ac_cv_header_stdc = yes; then | |
1079 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. | |
1080 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 1081 | #line 1082 "configure" |
fcfc3c0c TT |
1082 | #include "confdefs.h" |
1083 | #include <string.h> | |
1084 | EOF | |
1085 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
1086 | egrep "memchr" >/dev/null 2>&1; then | |
1087 | : | |
1088 | else | |
1089 | rm -rf conftest* | |
1090 | ac_cv_header_stdc=no | |
1091 | fi | |
1092 | rm -f conftest* | |
1093 | ||
1094 | fi | |
1095 | ||
1096 | if test $ac_cv_header_stdc = yes; then | |
1097 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. | |
1098 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 1099 | #line 1100 "configure" |
fcfc3c0c TT |
1100 | #include "confdefs.h" |
1101 | #include <stdlib.h> | |
1102 | EOF | |
1103 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
1104 | egrep "free" >/dev/null 2>&1; then | |
1105 | : | |
1106 | else | |
1107 | rm -rf conftest* | |
1108 | ac_cv_header_stdc=no | |
1109 | fi | |
1110 | rm -f conftest* | |
1111 | ||
1112 | fi | |
1113 | ||
1114 | if test $ac_cv_header_stdc = yes; then | |
1115 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. | |
1116 | if test "$cross_compiling" = yes; then | |
1117 | : | |
1118 | else | |
1119 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 1120 | #line 1121 "configure" |
fcfc3c0c TT |
1121 | #include "confdefs.h" |
1122 | #include <ctype.h> | |
1123 | #define ISLOWER(c) ('a' <= (c) && (c) <= 'z') | |
1124 | #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) | |
1125 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) | |
1126 | int main () { int i; for (i = 0; i < 256; i++) | |
1127 | if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2); | |
1128 | exit (0); } | |
1129 | ||
1130 | EOF | |
ba68ad57 | 1131 | if { (eval echo configure:1132: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null |
fcfc3c0c TT |
1132 | then |
1133 | : | |
1134 | else | |
1135 | echo "configure: failed program was:" >&5 | |
1136 | cat conftest.$ac_ext >&5 | |
1137 | rm -fr conftest* | |
1138 | ac_cv_header_stdc=no | |
1139 | fi | |
1140 | rm -fr conftest* | |
1141 | fi | |
1142 | ||
1143 | fi | |
1144 | fi | |
1145 | ||
1146 | echo "$ac_t""$ac_cv_header_stdc" 1>&6 | |
1147 | if test $ac_cv_header_stdc = yes; then | |
1148 | cat >> confdefs.h <<\EOF | |
1149 | #define STDC_HEADERS 1 | |
1150 | EOF | |
1151 | ||
1152 | fi | |
1153 | ||
1154 | echo $ac_n "checking for working const""... $ac_c" 1>&6 | |
ba68ad57 | 1155 | echo "configure:1156: checking for working const" >&5 |
fcfc3c0c TT |
1156 | if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then |
1157 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1158 | else | |
1159 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 1160 | #line 1161 "configure" |
fcfc3c0c TT |
1161 | #include "confdefs.h" |
1162 | ||
1163 | int main() { | |
1164 | ||
1165 | /* Ultrix mips cc rejects this. */ | |
1166 | typedef int charset[2]; const charset x; | |
1167 | /* SunOS 4.1.1 cc rejects this. */ | |
1168 | char const *const *ccp; | |
1169 | char **p; | |
1170 | /* NEC SVR4.0.2 mips cc rejects this. */ | |
1171 | struct point {int x, y;}; | |
1172 | static struct point const zero = {0,0}; | |
1173 | /* AIX XL C 1.02.0.0 rejects this. | |
1174 | It does not let you subtract one const X* pointer from another in an arm | |
1175 | of an if-expression whose if-part is not a constant expression */ | |
1176 | const char *g = "string"; | |
1177 | ccp = &g + (g ? g-g : 0); | |
1178 | /* HPUX 7.0 cc rejects these. */ | |
1179 | ++ccp; | |
1180 | p = (char**) ccp; | |
1181 | ccp = (char const *const *) p; | |
1182 | { /* SCO 3.2v4 cc rejects this. */ | |
1183 | char *t; | |
1184 | char const *s = 0 ? (char *) 0 : (char const *) 0; | |
1185 | ||
1186 | *t++ = 0; | |
1187 | } | |
1188 | { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ | |
1189 | int x[] = {25, 17}; | |
1190 | const int *foo = &x[0]; | |
1191 | ++foo; | |
1192 | } | |
1193 | { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ | |
1194 | typedef const int *iptr; | |
1195 | iptr p = 0; | |
1196 | ++p; | |
1197 | } | |
1198 | { /* AIX XL C 1.02.0.0 rejects this saying | |
1199 | "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ | |
1200 | struct s { int j; const int *ap[3]; }; | |
1201 | struct s *b; b->j = 5; | |
1202 | } | |
1203 | { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ | |
1204 | const int foo = 10; | |
1205 | } | |
1206 | ||
1207 | ; return 0; } | |
1208 | EOF | |
ba68ad57 | 1209 | if { (eval echo configure:1210: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
fcfc3c0c TT |
1210 | rm -rf conftest* |
1211 | ac_cv_c_const=yes | |
1212 | else | |
1213 | echo "configure: failed program was:" >&5 | |
1214 | cat conftest.$ac_ext >&5 | |
1215 | rm -rf conftest* | |
1216 | ac_cv_c_const=no | |
1217 | fi | |
1218 | rm -f conftest* | |
1219 | fi | |
1220 | ||
1221 | echo "$ac_t""$ac_cv_c_const" 1>&6 | |
1222 | if test $ac_cv_c_const = no; then | |
1223 | cat >> confdefs.h <<\EOF | |
1224 | #define const | |
1225 | EOF | |
1226 | ||
1227 | fi | |
1228 | ||
1229 | echo $ac_n "checking for inline""... $ac_c" 1>&6 | |
ba68ad57 | 1230 | echo "configure:1231: checking for inline" >&5 |
fcfc3c0c TT |
1231 | if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then |
1232 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1233 | else | |
1234 | ac_cv_c_inline=no | |
1235 | for ac_kw in inline __inline__ __inline; do | |
1236 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 1237 | #line 1238 "configure" |
fcfc3c0c TT |
1238 | #include "confdefs.h" |
1239 | ||
1240 | int main() { | |
1241 | } $ac_kw foo() { | |
1242 | ; return 0; } | |
1243 | EOF | |
ba68ad57 | 1244 | if { (eval echo configure:1245: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
fcfc3c0c TT |
1245 | rm -rf conftest* |
1246 | ac_cv_c_inline=$ac_kw; break | |
1247 | else | |
1248 | echo "configure: failed program was:" >&5 | |
1249 | cat conftest.$ac_ext >&5 | |
1250 | fi | |
1251 | rm -f conftest* | |
1252 | done | |
1253 | ||
1254 | fi | |
1255 | ||
1256 | echo "$ac_t""$ac_cv_c_inline" 1>&6 | |
1257 | case "$ac_cv_c_inline" in | |
1258 | inline | yes) ;; | |
1259 | no) cat >> confdefs.h <<\EOF | |
1260 | #define inline | |
1261 | EOF | |
1262 | ;; | |
1263 | *) cat >> confdefs.h <<EOF | |
1264 | #define inline $ac_cv_c_inline | |
1265 | EOF | |
1266 | ;; | |
1267 | esac | |
1268 | ||
1269 | echo $ac_n "checking for off_t""... $ac_c" 1>&6 | |
ba68ad57 | 1270 | echo "configure:1271: checking for off_t" >&5 |
fcfc3c0c TT |
1271 | if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then |
1272 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1273 | else | |
1274 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 1275 | #line 1276 "configure" |
fcfc3c0c TT |
1276 | #include "confdefs.h" |
1277 | #include <sys/types.h> | |
1278 | #if STDC_HEADERS | |
1279 | #include <stdlib.h> | |
1280 | #include <stddef.h> | |
1281 | #endif | |
1282 | EOF | |
1283 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
1284 | egrep "off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then | |
1285 | rm -rf conftest* | |
1286 | ac_cv_type_off_t=yes | |
1287 | else | |
1288 | rm -rf conftest* | |
1289 | ac_cv_type_off_t=no | |
1290 | fi | |
1291 | rm -f conftest* | |
1292 | ||
1293 | fi | |
1294 | echo "$ac_t""$ac_cv_type_off_t" 1>&6 | |
1295 | if test $ac_cv_type_off_t = no; then | |
1296 | cat >> confdefs.h <<\EOF | |
1297 | #define off_t long | |
1298 | EOF | |
1299 | ||
1300 | fi | |
1301 | ||
1302 | echo $ac_n "checking for size_t""... $ac_c" 1>&6 | |
ba68ad57 | 1303 | echo "configure:1304: checking for size_t" >&5 |
fcfc3c0c TT |
1304 | if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then |
1305 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1306 | else | |
1307 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 1308 | #line 1309 "configure" |
fcfc3c0c TT |
1309 | #include "confdefs.h" |
1310 | #include <sys/types.h> | |
1311 | #if STDC_HEADERS | |
1312 | #include <stdlib.h> | |
1313 | #include <stddef.h> | |
1314 | #endif | |
1315 | EOF | |
1316 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
1317 | egrep "size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then | |
1318 | rm -rf conftest* | |
1319 | ac_cv_type_size_t=yes | |
1320 | else | |
1321 | rm -rf conftest* | |
1322 | ac_cv_type_size_t=no | |
1323 | fi | |
1324 | rm -f conftest* | |
1325 | ||
1326 | fi | |
1327 | echo "$ac_t""$ac_cv_type_size_t" 1>&6 | |
1328 | if test $ac_cv_type_size_t = no; then | |
1329 | cat >> confdefs.h <<\EOF | |
1330 | #define size_t unsigned | |
1331 | EOF | |
1332 | ||
1333 | fi | |
1334 | ||
1335 | # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works | |
1336 | # for constant arguments. Useless! | |
1337 | echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6 | |
ba68ad57 | 1338 | echo "configure:1339: checking for working alloca.h" >&5 |
fcfc3c0c TT |
1339 | if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then |
1340 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1341 | else | |
1342 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 1343 | #line 1344 "configure" |
fcfc3c0c TT |
1344 | #include "confdefs.h" |
1345 | #include <alloca.h> | |
1346 | int main() { | |
1347 | char *p = alloca(2 * sizeof(int)); | |
1348 | ; return 0; } | |
1349 | EOF | |
ba68ad57 | 1350 | if { (eval echo configure:1351: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
fcfc3c0c TT |
1351 | rm -rf conftest* |
1352 | ac_cv_header_alloca_h=yes | |
1353 | else | |
1354 | echo "configure: failed program was:" >&5 | |
1355 | cat conftest.$ac_ext >&5 | |
1356 | rm -rf conftest* | |
1357 | ac_cv_header_alloca_h=no | |
1358 | fi | |
1359 | rm -f conftest* | |
1360 | fi | |
1361 | ||
1362 | echo "$ac_t""$ac_cv_header_alloca_h" 1>&6 | |
1363 | if test $ac_cv_header_alloca_h = yes; then | |
1364 | cat >> confdefs.h <<\EOF | |
1365 | #define HAVE_ALLOCA_H 1 | |
1366 | EOF | |
1367 | ||
1368 | fi | |
1369 | ||
1370 | echo $ac_n "checking for alloca""... $ac_c" 1>&6 | |
ba68ad57 | 1371 | echo "configure:1372: checking for alloca" >&5 |
fcfc3c0c TT |
1372 | if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then |
1373 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1374 | else | |
1375 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 1376 | #line 1377 "configure" |
fcfc3c0c TT |
1377 | #include "confdefs.h" |
1378 | ||
1379 | #ifdef __GNUC__ | |
1380 | # define alloca __builtin_alloca | |
1381 | #else | |
ba68ad57 JM |
1382 | # if HAVE_ALLOCA_H |
1383 | # include <alloca.h> | |
fcfc3c0c | 1384 | # else |
ba68ad57 | 1385 | # ifdef _AIX |
6ee3e5d6 | 1386 | #pragma alloca |
ba68ad57 JM |
1387 | # else |
1388 | # ifndef alloca /* predefined by HP cc +Olibcalls */ | |
fcfc3c0c TT |
1389 | char *alloca (); |
1390 | # endif | |
1391 | # endif | |
1392 | # endif | |
1393 | #endif | |
1394 | ||
1395 | int main() { | |
1396 | char *p = (char *) alloca(1); | |
1397 | ; return 0; } | |
1398 | EOF | |
ba68ad57 | 1399 | if { (eval echo configure:1400: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
fcfc3c0c TT |
1400 | rm -rf conftest* |
1401 | ac_cv_func_alloca_works=yes | |
1402 | else | |
1403 | echo "configure: failed program was:" >&5 | |
1404 | cat conftest.$ac_ext >&5 | |
1405 | rm -rf conftest* | |
1406 | ac_cv_func_alloca_works=no | |
1407 | fi | |
1408 | rm -f conftest* | |
1409 | fi | |
1410 | ||
1411 | echo "$ac_t""$ac_cv_func_alloca_works" 1>&6 | |
1412 | if test $ac_cv_func_alloca_works = yes; then | |
1413 | cat >> confdefs.h <<\EOF | |
1414 | #define HAVE_ALLOCA 1 | |
1415 | EOF | |
1416 | ||
1417 | fi | |
1418 | ||
1419 | if test $ac_cv_func_alloca_works = no; then | |
1420 | # The SVR3 libPW and SVR4 libucb both contain incompatible functions | |
1421 | # that cause trouble. Some versions do not even contain alloca or | |
1422 | # contain a buggy version. If you still want to use their alloca, | |
1423 | # use ar to extract alloca.o from them instead of compiling alloca.c. | |
ba68ad57 | 1424 | ALLOCA=alloca.o |
fcfc3c0c TT |
1425 | cat >> confdefs.h <<\EOF |
1426 | #define C_ALLOCA 1 | |
1427 | EOF | |
1428 | ||
1429 | ||
1430 | echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6 | |
ba68ad57 | 1431 | echo "configure:1432: checking whether alloca needs Cray hooks" >&5 |
fcfc3c0c TT |
1432 | if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then |
1433 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1434 | else | |
1435 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 1436 | #line 1437 "configure" |
fcfc3c0c TT |
1437 | #include "confdefs.h" |
1438 | #if defined(CRAY) && ! defined(CRAY2) | |
1439 | webecray | |
1440 | #else | |
1441 | wenotbecray | |
1442 | #endif | |
1443 | ||
1444 | EOF | |
1445 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
1446 | egrep "webecray" >/dev/null 2>&1; then | |
1447 | rm -rf conftest* | |
1448 | ac_cv_os_cray=yes | |
1449 | else | |
1450 | rm -rf conftest* | |
1451 | ac_cv_os_cray=no | |
1452 | fi | |
1453 | rm -f conftest* | |
1454 | ||
1455 | fi | |
1456 | ||
1457 | echo "$ac_t""$ac_cv_os_cray" 1>&6 | |
1458 | if test $ac_cv_os_cray = yes; then | |
1459 | for ac_func in _getb67 GETB67 getb67; do | |
1460 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
ba68ad57 | 1461 | echo "configure:1462: checking for $ac_func" >&5 |
fcfc3c0c TT |
1462 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
1463 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1464 | else | |
1465 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 1466 | #line 1467 "configure" |
fcfc3c0c TT |
1467 | #include "confdefs.h" |
1468 | /* System header to define __stub macros and hopefully few prototypes, | |
1469 | which can conflict with char $ac_func(); below. */ | |
1470 | #include <assert.h> | |
1471 | /* Override any gcc2 internal prototype to avoid an error. */ | |
1472 | /* We use char because int might match the return type of a gcc2 | |
1473 | builtin and then its argument prototype would still apply. */ | |
1474 | char $ac_func(); | |
1475 | ||
1476 | int main() { | |
1477 | ||
1478 | /* The GNU C library defines this for functions which it implements | |
1479 | to always fail with ENOSYS. Some functions are actually named | |
1480 | something starting with __ and the normal name is an alias. */ | |
1481 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
1482 | choke me | |
1483 | #else | |
1484 | $ac_func(); | |
1485 | #endif | |
1486 | ||
1487 | ; return 0; } | |
1488 | EOF | |
ba68ad57 | 1489 | if { (eval echo configure:1490: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
fcfc3c0c TT |
1490 | rm -rf conftest* |
1491 | eval "ac_cv_func_$ac_func=yes" | |
1492 | else | |
1493 | echo "configure: failed program was:" >&5 | |
1494 | cat conftest.$ac_ext >&5 | |
1495 | rm -rf conftest* | |
1496 | eval "ac_cv_func_$ac_func=no" | |
1497 | fi | |
1498 | rm -f conftest* | |
1499 | fi | |
1500 | ||
1501 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then | |
1502 | echo "$ac_t""yes" 1>&6 | |
1503 | cat >> confdefs.h <<EOF | |
1504 | #define CRAY_STACKSEG_END $ac_func | |
1505 | EOF | |
1506 | ||
1507 | break | |
1508 | else | |
1509 | echo "$ac_t""no" 1>&6 | |
1510 | fi | |
1511 | ||
1512 | done | |
1513 | fi | |
1514 | ||
1515 | echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6 | |
ba68ad57 | 1516 | echo "configure:1517: checking stack direction for C alloca" >&5 |
fcfc3c0c TT |
1517 | if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then |
1518 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1519 | else | |
1520 | if test "$cross_compiling" = yes; then | |
1521 | ac_cv_c_stack_direction=0 | |
1522 | else | |
1523 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 1524 | #line 1525 "configure" |
fcfc3c0c TT |
1525 | #include "confdefs.h" |
1526 | find_stack_direction () | |
1527 | { | |
1528 | static char *addr = 0; | |
1529 | auto char dummy; | |
1530 | if (addr == 0) | |
1531 | { | |
1532 | addr = &dummy; | |
1533 | return find_stack_direction (); | |
1534 | } | |
1535 | else | |
1536 | return (&dummy > addr) ? 1 : -1; | |
1537 | } | |
1538 | main () | |
1539 | { | |
1540 | exit (find_stack_direction() < 0); | |
1541 | } | |
1542 | EOF | |
ba68ad57 | 1543 | if { (eval echo configure:1544: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null |
fcfc3c0c TT |
1544 | then |
1545 | ac_cv_c_stack_direction=1 | |
1546 | else | |
1547 | echo "configure: failed program was:" >&5 | |
1548 | cat conftest.$ac_ext >&5 | |
1549 | rm -fr conftest* | |
1550 | ac_cv_c_stack_direction=-1 | |
1551 | fi | |
1552 | rm -fr conftest* | |
1553 | fi | |
1554 | ||
1555 | fi | |
1556 | ||
1557 | echo "$ac_t""$ac_cv_c_stack_direction" 1>&6 | |
1558 | cat >> confdefs.h <<EOF | |
1559 | #define STACK_DIRECTION $ac_cv_c_stack_direction | |
1560 | EOF | |
1561 | ||
1562 | fi | |
1563 | ||
1564 | for ac_hdr in unistd.h | |
1565 | do | |
1566 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` | |
1567 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 | |
ba68ad57 | 1568 | echo "configure:1569: checking for $ac_hdr" >&5 |
fcfc3c0c TT |
1569 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
1570 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1571 | else | |
1572 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 1573 | #line 1574 "configure" |
fcfc3c0c TT |
1574 | #include "confdefs.h" |
1575 | #include <$ac_hdr> | |
1576 | EOF | |
1577 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
ba68ad57 JM |
1578 | { (eval echo configure:1579: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
1579 | ac_err=`grep -v '^ *+' conftest.out` | |
fcfc3c0c TT |
1580 | if test -z "$ac_err"; then |
1581 | rm -rf conftest* | |
1582 | eval "ac_cv_header_$ac_safe=yes" | |
1583 | else | |
1584 | echo "$ac_err" >&5 | |
1585 | echo "configure: failed program was:" >&5 | |
1586 | cat conftest.$ac_ext >&5 | |
1587 | rm -rf conftest* | |
1588 | eval "ac_cv_header_$ac_safe=no" | |
1589 | fi | |
1590 | rm -f conftest* | |
1591 | fi | |
1592 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | |
1593 | echo "$ac_t""yes" 1>&6 | |
1594 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` | |
1595 | cat >> confdefs.h <<EOF | |
1596 | #define $ac_tr_hdr 1 | |
1597 | EOF | |
1598 | ||
1599 | else | |
1600 | echo "$ac_t""no" 1>&6 | |
1601 | fi | |
1602 | done | |
1603 | ||
1604 | for ac_func in getpagesize | |
1605 | do | |
1606 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
ba68ad57 | 1607 | echo "configure:1608: checking for $ac_func" >&5 |
fcfc3c0c TT |
1608 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
1609 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1610 | else | |
1611 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 1612 | #line 1613 "configure" |
fcfc3c0c TT |
1613 | #include "confdefs.h" |
1614 | /* System header to define __stub macros and hopefully few prototypes, | |
1615 | which can conflict with char $ac_func(); below. */ | |
1616 | #include <assert.h> | |
1617 | /* Override any gcc2 internal prototype to avoid an error. */ | |
1618 | /* We use char because int might match the return type of a gcc2 | |
1619 | builtin and then its argument prototype would still apply. */ | |
1620 | char $ac_func(); | |
1621 | ||
1622 | int main() { | |
1623 | ||
1624 | /* The GNU C library defines this for functions which it implements | |
1625 | to always fail with ENOSYS. Some functions are actually named | |
1626 | something starting with __ and the normal name is an alias. */ | |
1627 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
1628 | choke me | |
1629 | #else | |
1630 | $ac_func(); | |
1631 | #endif | |
1632 | ||
1633 | ; return 0; } | |
1634 | EOF | |
ba68ad57 | 1635 | if { (eval echo configure:1636: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
fcfc3c0c TT |
1636 | rm -rf conftest* |
1637 | eval "ac_cv_func_$ac_func=yes" | |
1638 | else | |
1639 | echo "configure: failed program was:" >&5 | |
1640 | cat conftest.$ac_ext >&5 | |
1641 | rm -rf conftest* | |
1642 | eval "ac_cv_func_$ac_func=no" | |
1643 | fi | |
1644 | rm -f conftest* | |
1645 | fi | |
1646 | ||
1647 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then | |
1648 | echo "$ac_t""yes" 1>&6 | |
1649 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
1650 | cat >> confdefs.h <<EOF | |
1651 | #define $ac_tr_func 1 | |
1652 | EOF | |
1653 | ||
1654 | else | |
1655 | echo "$ac_t""no" 1>&6 | |
1656 | fi | |
1657 | done | |
1658 | ||
1659 | echo $ac_n "checking for working mmap""... $ac_c" 1>&6 | |
ba68ad57 | 1660 | echo "configure:1661: checking for working mmap" >&5 |
fcfc3c0c TT |
1661 | if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then |
1662 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1663 | else | |
1664 | if test "$cross_compiling" = yes; then | |
1665 | ac_cv_func_mmap_fixed_mapped=no | |
1666 | else | |
1667 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 1668 | #line 1669 "configure" |
fcfc3c0c TT |
1669 | #include "confdefs.h" |
1670 | ||
1671 | /* Thanks to Mike Haertel and Jim Avera for this test. | |
1672 | Here is a matrix of mmap possibilities: | |
1673 | mmap private not fixed | |
1674 | mmap private fixed at somewhere currently unmapped | |
1675 | mmap private fixed at somewhere already mapped | |
1676 | mmap shared not fixed | |
1677 | mmap shared fixed at somewhere currently unmapped | |
1678 | mmap shared fixed at somewhere already mapped | |
1679 | For private mappings, we should verify that changes cannot be read() | |
1680 | back from the file, nor mmap's back from the file at a different | |
1681 | address. (There have been systems where private was not correctly | |
1682 | implemented like the infamous i386 svr4.0, and systems where the | |
1683 | VM page cache was not coherent with the filesystem buffer cache | |
1684 | like early versions of FreeBSD and possibly contemporary NetBSD.) | |
1685 | For shared mappings, we should conversely verify that changes get | |
1686 | propogated back to all the places they're supposed to be. | |
1687 | ||
1688 | Grep wants private fixed already mapped. | |
1689 | The main things grep needs to know about mmap are: | |
1690 | * does it exist and is it safe to write into the mmap'd area | |
1691 | * how to use it (BSD variants) */ | |
1692 | #include <sys/types.h> | |
1693 | #include <fcntl.h> | |
1694 | #include <sys/mman.h> | |
1695 | ||
1696 | /* This mess was copied from the GNU getpagesize.h. */ | |
1697 | #ifndef HAVE_GETPAGESIZE | |
1698 | # ifdef HAVE_UNISTD_H | |
1699 | # include <unistd.h> | |
1700 | # endif | |
1701 | ||
1702 | /* Assume that all systems that can run configure have sys/param.h. */ | |
1703 | # ifndef HAVE_SYS_PARAM_H | |
1704 | # define HAVE_SYS_PARAM_H 1 | |
1705 | # endif | |
1706 | ||
1707 | # ifdef _SC_PAGESIZE | |
1708 | # define getpagesize() sysconf(_SC_PAGESIZE) | |
1709 | # else /* no _SC_PAGESIZE */ | |
1710 | # ifdef HAVE_SYS_PARAM_H | |
1711 | # include <sys/param.h> | |
1712 | # ifdef EXEC_PAGESIZE | |
1713 | # define getpagesize() EXEC_PAGESIZE | |
1714 | # else /* no EXEC_PAGESIZE */ | |
1715 | # ifdef NBPG | |
1716 | # define getpagesize() NBPG * CLSIZE | |
1717 | # ifndef CLSIZE | |
1718 | # define CLSIZE 1 | |
1719 | # endif /* no CLSIZE */ | |
1720 | # else /* no NBPG */ | |
1721 | # ifdef NBPC | |
1722 | # define getpagesize() NBPC | |
1723 | # else /* no NBPC */ | |
1724 | # ifdef PAGESIZE | |
1725 | # define getpagesize() PAGESIZE | |
1726 | # endif /* PAGESIZE */ | |
1727 | # endif /* no NBPC */ | |
1728 | # endif /* no NBPG */ | |
1729 | # endif /* no EXEC_PAGESIZE */ | |
1730 | # else /* no HAVE_SYS_PARAM_H */ | |
1731 | # define getpagesize() 8192 /* punt totally */ | |
1732 | # endif /* no HAVE_SYS_PARAM_H */ | |
1733 | # endif /* no _SC_PAGESIZE */ | |
1734 | ||
1735 | #endif /* no HAVE_GETPAGESIZE */ | |
1736 | ||
1737 | #ifdef __cplusplus | |
1738 | extern "C" { void *malloc(unsigned); } | |
1739 | #else | |
1740 | char *malloc(); | |
1741 | #endif | |
1742 | ||
1743 | int | |
1744 | main() | |
1745 | { | |
1746 | char *data, *data2, *data3; | |
1747 | int i, pagesize; | |
1748 | int fd; | |
1749 | ||
1750 | pagesize = getpagesize(); | |
1751 | ||
1752 | /* | |
1753 | * First, make a file with some known garbage in it. | |
1754 | */ | |
1755 | data = malloc(pagesize); | |
1756 | if (!data) | |
1757 | exit(1); | |
1758 | for (i = 0; i < pagesize; ++i) | |
1759 | *(data + i) = rand(); | |
1760 | umask(0); | |
1761 | fd = creat("conftestmmap", 0600); | |
1762 | if (fd < 0) | |
1763 | exit(1); | |
1764 | if (write(fd, data, pagesize) != pagesize) | |
1765 | exit(1); | |
1766 | close(fd); | |
1767 | ||
1768 | /* | |
1769 | * Next, try to mmap the file at a fixed address which | |
1770 | * already has something else allocated at it. If we can, | |
1771 | * also make sure that we see the same garbage. | |
1772 | */ | |
1773 | fd = open("conftestmmap", O_RDWR); | |
1774 | if (fd < 0) | |
1775 | exit(1); | |
1776 | data2 = malloc(2 * pagesize); | |
1777 | if (!data2) | |
1778 | exit(1); | |
1779 | data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1); | |
1780 | if (data2 != mmap(data2, pagesize, PROT_READ | PROT_WRITE, | |
1781 | MAP_PRIVATE | MAP_FIXED, fd, 0L)) | |
1782 | exit(1); | |
1783 | for (i = 0; i < pagesize; ++i) | |
1784 | if (*(data + i) != *(data2 + i)) | |
1785 | exit(1); | |
1786 | ||
1787 | /* | |
1788 | * Finally, make sure that changes to the mapped area | |
1789 | * do not percolate back to the file as seen by read(). | |
1790 | * (This is a bug on some variants of i386 svr4.0.) | |
1791 | */ | |
1792 | for (i = 0; i < pagesize; ++i) | |
1793 | *(data2 + i) = *(data2 + i) + 1; | |
1794 | data3 = malloc(pagesize); | |
1795 | if (!data3) | |
1796 | exit(1); | |
1797 | if (read(fd, data3, pagesize) != pagesize) | |
1798 | exit(1); | |
1799 | for (i = 0; i < pagesize; ++i) | |
1800 | if (*(data + i) != *(data3 + i)) | |
1801 | exit(1); | |
1802 | close(fd); | |
1803 | unlink("conftestmmap"); | |
1804 | exit(0); | |
1805 | } | |
1806 | ||
1807 | EOF | |
ba68ad57 | 1808 | if { (eval echo configure:1809: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null |
fcfc3c0c TT |
1809 | then |
1810 | ac_cv_func_mmap_fixed_mapped=yes | |
1811 | else | |
1812 | echo "configure: failed program was:" >&5 | |
1813 | cat conftest.$ac_ext >&5 | |
1814 | rm -fr conftest* | |
1815 | ac_cv_func_mmap_fixed_mapped=no | |
1816 | fi | |
1817 | rm -fr conftest* | |
1818 | fi | |
1819 | ||
1820 | fi | |
1821 | ||
1822 | echo "$ac_t""$ac_cv_func_mmap_fixed_mapped" 1>&6 | |
1823 | if test $ac_cv_func_mmap_fixed_mapped = yes; then | |
1824 | cat >> confdefs.h <<\EOF | |
1825 | #define HAVE_MMAP 1 | |
1826 | EOF | |
1827 | ||
1828 | fi | |
1829 | ||
1830 | ||
1831 | for ac_hdr in argz.h limits.h locale.h nl_types.h malloc.h string.h \ | |
1832 | unistd.h values.h sys/param.h | |
1833 | do | |
1834 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` | |
1835 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 | |
ba68ad57 | 1836 | echo "configure:1837: checking for $ac_hdr" >&5 |
fcfc3c0c TT |
1837 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
1838 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1839 | else | |
1840 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 1841 | #line 1842 "configure" |
fcfc3c0c TT |
1842 | #include "confdefs.h" |
1843 | #include <$ac_hdr> | |
1844 | EOF | |
1845 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
ba68ad57 JM |
1846 | { (eval echo configure:1847: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
1847 | ac_err=`grep -v '^ *+' conftest.out` | |
fcfc3c0c TT |
1848 | if test -z "$ac_err"; then |
1849 | rm -rf conftest* | |
1850 | eval "ac_cv_header_$ac_safe=yes" | |
1851 | else | |
1852 | echo "$ac_err" >&5 | |
1853 | echo "configure: failed program was:" >&5 | |
1854 | cat conftest.$ac_ext >&5 | |
1855 | rm -rf conftest* | |
1856 | eval "ac_cv_header_$ac_safe=no" | |
1857 | fi | |
1858 | rm -f conftest* | |
1859 | fi | |
1860 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | |
1861 | echo "$ac_t""yes" 1>&6 | |
1862 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` | |
1863 | cat >> confdefs.h <<EOF | |
1864 | #define $ac_tr_hdr 1 | |
1865 | EOF | |
1866 | ||
1867 | else | |
1868 | echo "$ac_t""no" 1>&6 | |
1869 | fi | |
1870 | done | |
1871 | ||
1872 | for ac_func in getcwd munmap putenv setenv setlocale strchr strcasecmp \ | |
1873 | __argz_count __argz_stringify __argz_next | |
1874 | do | |
1875 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
ba68ad57 | 1876 | echo "configure:1877: checking for $ac_func" >&5 |
fcfc3c0c TT |
1877 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
1878 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1879 | else | |
1880 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 1881 | #line 1882 "configure" |
fcfc3c0c TT |
1882 | #include "confdefs.h" |
1883 | /* System header to define __stub macros and hopefully few prototypes, | |
1884 | which can conflict with char $ac_func(); below. */ | |
1885 | #include <assert.h> | |
1886 | /* Override any gcc2 internal prototype to avoid an error. */ | |
1887 | /* We use char because int might match the return type of a gcc2 | |
1888 | builtin and then its argument prototype would still apply. */ | |
1889 | char $ac_func(); | |
1890 | ||
1891 | int main() { | |
1892 | ||
1893 | /* The GNU C library defines this for functions which it implements | |
1894 | to always fail with ENOSYS. Some functions are actually named | |
1895 | something starting with __ and the normal name is an alias. */ | |
1896 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
1897 | choke me | |
1898 | #else | |
1899 | $ac_func(); | |
1900 | #endif | |
1901 | ||
1902 | ; return 0; } | |
1903 | EOF | |
ba68ad57 | 1904 | if { (eval echo configure:1905: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
fcfc3c0c TT |
1905 | rm -rf conftest* |
1906 | eval "ac_cv_func_$ac_func=yes" | |
1907 | else | |
1908 | echo "configure: failed program was:" >&5 | |
1909 | cat conftest.$ac_ext >&5 | |
1910 | rm -rf conftest* | |
1911 | eval "ac_cv_func_$ac_func=no" | |
1912 | fi | |
1913 | rm -f conftest* | |
1914 | fi | |
1915 | ||
1916 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then | |
1917 | echo "$ac_t""yes" 1>&6 | |
1918 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
1919 | cat >> confdefs.h <<EOF | |
1920 | #define $ac_tr_func 1 | |
1921 | EOF | |
1922 | ||
1923 | else | |
1924 | echo "$ac_t""no" 1>&6 | |
1925 | fi | |
1926 | done | |
1927 | ||
1928 | ||
1929 | if test "${ac_cv_func_stpcpy+set}" != "set"; then | |
1930 | for ac_func in stpcpy | |
1931 | do | |
1932 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
ba68ad57 | 1933 | echo "configure:1934: checking for $ac_func" >&5 |
fcfc3c0c TT |
1934 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
1935 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1936 | else | |
1937 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 1938 | #line 1939 "configure" |
fcfc3c0c TT |
1939 | #include "confdefs.h" |
1940 | /* System header to define __stub macros and hopefully few prototypes, | |
1941 | which can conflict with char $ac_func(); below. */ | |
1942 | #include <assert.h> | |
1943 | /* Override any gcc2 internal prototype to avoid an error. */ | |
1944 | /* We use char because int might match the return type of a gcc2 | |
1945 | builtin and then its argument prototype would still apply. */ | |
1946 | char $ac_func(); | |
1947 | ||
1948 | int main() { | |
1949 | ||
1950 | /* The GNU C library defines this for functions which it implements | |
1951 | to always fail with ENOSYS. Some functions are actually named | |
1952 | something starting with __ and the normal name is an alias. */ | |
1953 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
1954 | choke me | |
1955 | #else | |
1956 | $ac_func(); | |
1957 | #endif | |
1958 | ||
1959 | ; return 0; } | |
1960 | EOF | |
ba68ad57 | 1961 | if { (eval echo configure:1962: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
fcfc3c0c TT |
1962 | rm -rf conftest* |
1963 | eval "ac_cv_func_$ac_func=yes" | |
1964 | else | |
1965 | echo "configure: failed program was:" >&5 | |
1966 | cat conftest.$ac_ext >&5 | |
1967 | rm -rf conftest* | |
1968 | eval "ac_cv_func_$ac_func=no" | |
1969 | fi | |
1970 | rm -f conftest* | |
1971 | fi | |
1972 | ||
1973 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then | |
1974 | echo "$ac_t""yes" 1>&6 | |
1975 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
1976 | cat >> confdefs.h <<EOF | |
1977 | #define $ac_tr_func 1 | |
1978 | EOF | |
1979 | ||
1980 | else | |
1981 | echo "$ac_t""no" 1>&6 | |
1982 | fi | |
1983 | done | |
1984 | ||
1985 | fi | |
1986 | if test "${ac_cv_func_stpcpy}" = "yes"; then | |
1987 | cat >> confdefs.h <<\EOF | |
1988 | #define HAVE_STPCPY 1 | |
1989 | EOF | |
1990 | ||
1991 | fi | |
1992 | ||
1993 | if test $ac_cv_header_locale_h = yes; then | |
1994 | echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6 | |
ba68ad57 | 1995 | echo "configure:1996: checking for LC_MESSAGES" >&5 |
fcfc3c0c TT |
1996 | if eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then |
1997 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1998 | else | |
1999 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 2000 | #line 2001 "configure" |
fcfc3c0c TT |
2001 | #include "confdefs.h" |
2002 | #include <locale.h> | |
2003 | int main() { | |
2004 | return LC_MESSAGES | |
2005 | ; return 0; } | |
2006 | EOF | |
ba68ad57 | 2007 | if { (eval echo configure:2008: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
fcfc3c0c TT |
2008 | rm -rf conftest* |
2009 | am_cv_val_LC_MESSAGES=yes | |
2010 | else | |
2011 | echo "configure: failed program was:" >&5 | |
2012 | cat conftest.$ac_ext >&5 | |
2013 | rm -rf conftest* | |
2014 | am_cv_val_LC_MESSAGES=no | |
2015 | fi | |
2016 | rm -f conftest* | |
2017 | fi | |
2018 | ||
2019 | echo "$ac_t""$am_cv_val_LC_MESSAGES" 1>&6 | |
2020 | if test $am_cv_val_LC_MESSAGES = yes; then | |
2021 | cat >> confdefs.h <<\EOF | |
2022 | #define HAVE_LC_MESSAGES 1 | |
2023 | EOF | |
2024 | ||
2025 | fi | |
2026 | fi | |
2027 | echo $ac_n "checking whether NLS is requested""... $ac_c" 1>&6 | |
ba68ad57 | 2028 | echo "configure:2029: checking whether NLS is requested" >&5 |
fcfc3c0c TT |
2029 | # Check whether --enable-nls or --disable-nls was given. |
2030 | if test "${enable_nls+set}" = set; then | |
2031 | enableval="$enable_nls" | |
2032 | USE_NLS=$enableval | |
2033 | else | |
2034 | USE_NLS=yes | |
2035 | fi | |
2036 | ||
2037 | echo "$ac_t""$USE_NLS" 1>&6 | |
2038 | ||
2039 | ||
2040 | USE_INCLUDED_LIBINTL=no | |
2041 | ||
2042 | if test "$USE_NLS" = "yes"; then | |
2043 | cat >> confdefs.h <<\EOF | |
2044 | #define ENABLE_NLS 1 | |
2045 | EOF | |
2046 | ||
2047 | echo $ac_n "checking whether included gettext is requested""... $ac_c" 1>&6 | |
ba68ad57 | 2048 | echo "configure:2049: checking whether included gettext is requested" >&5 |
fcfc3c0c TT |
2049 | # Check whether --with-included-gettext or --without-included-gettext was given. |
2050 | if test "${with_included_gettext+set}" = set; then | |
2051 | withval="$with_included_gettext" | |
2052 | nls_cv_force_use_gnu_gettext=$withval | |
2053 | else | |
2054 | nls_cv_force_use_gnu_gettext=no | |
2055 | fi | |
2056 | ||
2057 | echo "$ac_t""$nls_cv_force_use_gnu_gettext" 1>&6 | |
2058 | ||
2059 | nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext" | |
2060 | if test "$nls_cv_force_use_gnu_gettext" != "yes"; then | |
2061 | nls_cv_header_intl= | |
2062 | nls_cv_header_libgt= | |
2063 | CATOBJEXT=NONE | |
2064 | ||
2065 | ac_safe=`echo "libintl.h" | sed 'y%./+-%__p_%'` | |
2066 | echo $ac_n "checking for libintl.h""... $ac_c" 1>&6 | |
ba68ad57 | 2067 | echo "configure:2068: checking for libintl.h" >&5 |
fcfc3c0c TT |
2068 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
2069 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2070 | else | |
2071 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 2072 | #line 2073 "configure" |
fcfc3c0c TT |
2073 | #include "confdefs.h" |
2074 | #include <libintl.h> | |
2075 | EOF | |
2076 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
ba68ad57 JM |
2077 | { (eval echo configure:2078: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
2078 | ac_err=`grep -v '^ *+' conftest.out` | |
fcfc3c0c TT |
2079 | if test -z "$ac_err"; then |
2080 | rm -rf conftest* | |
2081 | eval "ac_cv_header_$ac_safe=yes" | |
2082 | else | |
2083 | echo "$ac_err" >&5 | |
2084 | echo "configure: failed program was:" >&5 | |
2085 | cat conftest.$ac_ext >&5 | |
2086 | rm -rf conftest* | |
2087 | eval "ac_cv_header_$ac_safe=no" | |
2088 | fi | |
2089 | rm -f conftest* | |
2090 | fi | |
2091 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | |
2092 | echo "$ac_t""yes" 1>&6 | |
2093 | echo $ac_n "checking for gettext in libc""... $ac_c" 1>&6 | |
ba68ad57 | 2094 | echo "configure:2095: checking for gettext in libc" >&5 |
fcfc3c0c TT |
2095 | if eval "test \"`echo '$''{'gt_cv_func_gettext_libc'+set}'`\" = set"; then |
2096 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2097 | else | |
2098 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 2099 | #line 2100 "configure" |
fcfc3c0c TT |
2100 | #include "confdefs.h" |
2101 | #include <libintl.h> | |
2102 | int main() { | |
2103 | return (int) gettext ("") | |
2104 | ; return 0; } | |
2105 | EOF | |
ba68ad57 | 2106 | if { (eval echo configure:2107: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
fcfc3c0c TT |
2107 | rm -rf conftest* |
2108 | gt_cv_func_gettext_libc=yes | |
2109 | else | |
2110 | echo "configure: failed program was:" >&5 | |
2111 | cat conftest.$ac_ext >&5 | |
2112 | rm -rf conftest* | |
2113 | gt_cv_func_gettext_libc=no | |
2114 | fi | |
2115 | rm -f conftest* | |
2116 | fi | |
2117 | ||
2118 | echo "$ac_t""$gt_cv_func_gettext_libc" 1>&6 | |
2119 | ||
2120 | if test "$gt_cv_func_gettext_libc" != "yes"; then | |
2121 | echo $ac_n "checking for bindtextdomain in -lintl""... $ac_c" 1>&6 | |
ba68ad57 | 2122 | echo "configure:2123: checking for bindtextdomain in -lintl" >&5 |
fcfc3c0c TT |
2123 | ac_lib_var=`echo intl'_'bindtextdomain | sed 'y%./+-%__p_%'` |
2124 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then | |
2125 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2126 | else | |
2127 | ac_save_LIBS="$LIBS" | |
2128 | LIBS="-lintl $LIBS" | |
2129 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 2130 | #line 2131 "configure" |
fcfc3c0c TT |
2131 | #include "confdefs.h" |
2132 | /* Override any gcc2 internal prototype to avoid an error. */ | |
2133 | /* We use char because int might match the return type of a gcc2 | |
2134 | builtin and then its argument prototype would still apply. */ | |
2135 | char bindtextdomain(); | |
2136 | ||
2137 | int main() { | |
2138 | bindtextdomain() | |
2139 | ; return 0; } | |
2140 | EOF | |
ba68ad57 | 2141 | if { (eval echo configure:2142: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
fcfc3c0c TT |
2142 | rm -rf conftest* |
2143 | eval "ac_cv_lib_$ac_lib_var=yes" | |
2144 | else | |
2145 | echo "configure: failed program was:" >&5 | |
2146 | cat conftest.$ac_ext >&5 | |
2147 | rm -rf conftest* | |
2148 | eval "ac_cv_lib_$ac_lib_var=no" | |
2149 | fi | |
2150 | rm -f conftest* | |
2151 | LIBS="$ac_save_LIBS" | |
2152 | ||
2153 | fi | |
2154 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then | |
2155 | echo "$ac_t""yes" 1>&6 | |
2156 | echo $ac_n "checking for gettext in libintl""... $ac_c" 1>&6 | |
ba68ad57 | 2157 | echo "configure:2158: checking for gettext in libintl" >&5 |
fcfc3c0c TT |
2158 | if eval "test \"`echo '$''{'gt_cv_func_gettext_libintl'+set}'`\" = set"; then |
2159 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2160 | else | |
2161 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 2162 | #line 2163 "configure" |
fcfc3c0c TT |
2163 | #include "confdefs.h" |
2164 | ||
2165 | int main() { | |
2166 | return (int) gettext ("") | |
2167 | ; return 0; } | |
2168 | EOF | |
ba68ad57 | 2169 | if { (eval echo configure:2170: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
fcfc3c0c TT |
2170 | rm -rf conftest* |
2171 | gt_cv_func_gettext_libintl=yes | |
2172 | else | |
2173 | echo "configure: failed program was:" >&5 | |
2174 | cat conftest.$ac_ext >&5 | |
2175 | rm -rf conftest* | |
2176 | gt_cv_func_gettext_libintl=no | |
2177 | fi | |
2178 | rm -f conftest* | |
2179 | fi | |
2180 | ||
2181 | echo "$ac_t""$gt_cv_func_gettext_libintl" 1>&6 | |
2182 | else | |
2183 | echo "$ac_t""no" 1>&6 | |
2184 | fi | |
2185 | ||
2186 | fi | |
2187 | ||
2188 | if test "$gt_cv_func_gettext_libc" = "yes" \ | |
2189 | || test "$gt_cv_func_gettext_libintl" = "yes"; then | |
2190 | cat >> confdefs.h <<\EOF | |
2191 | #define HAVE_GETTEXT 1 | |
2192 | EOF | |
2193 | ||
2194 | # Extract the first word of "msgfmt", so it can be a program name with args. | |
2195 | set dummy msgfmt; ac_word=$2 | |
2196 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
ba68ad57 | 2197 | echo "configure:2198: checking for $ac_word" >&5 |
fcfc3c0c TT |
2198 | if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then |
2199 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2200 | else | |
2201 | case "$MSGFMT" in | |
2202 | /*) | |
2203 | ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. | |
2204 | ;; | |
2205 | *) | |
2206 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" | |
2207 | for ac_dir in $PATH; do | |
2208 | test -z "$ac_dir" && ac_dir=. | |
2209 | if test -f $ac_dir/$ac_word; then | |
2210 | if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then | |
2211 | ac_cv_path_MSGFMT="$ac_dir/$ac_word" | |
2212 | break | |
2213 | fi | |
2214 | fi | |
2215 | done | |
2216 | IFS="$ac_save_ifs" | |
2217 | test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="no" | |
2218 | ;; | |
2219 | esac | |
2220 | fi | |
2221 | MSGFMT="$ac_cv_path_MSGFMT" | |
2222 | if test -n "$MSGFMT"; then | |
2223 | echo "$ac_t""$MSGFMT" 1>&6 | |
2224 | else | |
2225 | echo "$ac_t""no" 1>&6 | |
2226 | fi | |
2227 | if test "$MSGFMT" != "no"; then | |
2228 | for ac_func in dcgettext | |
2229 | do | |
2230 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
ba68ad57 | 2231 | echo "configure:2232: checking for $ac_func" >&5 |
fcfc3c0c TT |
2232 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
2233 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2234 | else | |
2235 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 2236 | #line 2237 "configure" |
fcfc3c0c TT |
2237 | #include "confdefs.h" |
2238 | /* System header to define __stub macros and hopefully few prototypes, | |
2239 | which can conflict with char $ac_func(); below. */ | |
2240 | #include <assert.h> | |
2241 | /* Override any gcc2 internal prototype to avoid an error. */ | |
2242 | /* We use char because int might match the return type of a gcc2 | |
2243 | builtin and then its argument prototype would still apply. */ | |
2244 | char $ac_func(); | |
2245 | ||
2246 | int main() { | |
2247 | ||
2248 | /* The GNU C library defines this for functions which it implements | |
2249 | to always fail with ENOSYS. Some functions are actually named | |
2250 | something starting with __ and the normal name is an alias. */ | |
2251 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
2252 | choke me | |
2253 | #else | |
2254 | $ac_func(); | |
2255 | #endif | |
2256 | ||
2257 | ; return 0; } | |
2258 | EOF | |
ba68ad57 | 2259 | if { (eval echo configure:2260: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
fcfc3c0c TT |
2260 | rm -rf conftest* |
2261 | eval "ac_cv_func_$ac_func=yes" | |
2262 | else | |
2263 | echo "configure: failed program was:" >&5 | |
2264 | cat conftest.$ac_ext >&5 | |
2265 | rm -rf conftest* | |
2266 | eval "ac_cv_func_$ac_func=no" | |
2267 | fi | |
2268 | rm -f conftest* | |
2269 | fi | |
2270 | ||
2271 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then | |
2272 | echo "$ac_t""yes" 1>&6 | |
2273 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
2274 | cat >> confdefs.h <<EOF | |
2275 | #define $ac_tr_func 1 | |
2276 | EOF | |
2277 | ||
2278 | else | |
2279 | echo "$ac_t""no" 1>&6 | |
2280 | fi | |
2281 | done | |
2282 | ||
2283 | # Extract the first word of "gmsgfmt", so it can be a program name with args. | |
2284 | set dummy gmsgfmt; ac_word=$2 | |
2285 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
ba68ad57 | 2286 | echo "configure:2287: checking for $ac_word" >&5 |
fcfc3c0c TT |
2287 | if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then |
2288 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2289 | else | |
2290 | case "$GMSGFMT" in | |
2291 | /*) | |
2292 | ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path. | |
2293 | ;; | |
fcfc3c0c | 2294 | *) |
ba68ad57 | 2295 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" |
fcfc3c0c TT |
2296 | for ac_dir in $PATH; do |
2297 | test -z "$ac_dir" && ac_dir=. | |
2298 | if test -f $ac_dir/$ac_word; then | |
2299 | ac_cv_path_GMSGFMT="$ac_dir/$ac_word" | |
2300 | break | |
2301 | fi | |
2302 | done | |
2303 | IFS="$ac_save_ifs" | |
2304 | test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT" | |
2305 | ;; | |
2306 | esac | |
2307 | fi | |
2308 | GMSGFMT="$ac_cv_path_GMSGFMT" | |
2309 | if test -n "$GMSGFMT"; then | |
2310 | echo "$ac_t""$GMSGFMT" 1>&6 | |
2311 | else | |
2312 | echo "$ac_t""no" 1>&6 | |
2313 | fi | |
2314 | ||
2315 | # Extract the first word of "xgettext", so it can be a program name with args. | |
2316 | set dummy xgettext; ac_word=$2 | |
2317 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
ba68ad57 | 2318 | echo "configure:2319: checking for $ac_word" >&5 |
fcfc3c0c TT |
2319 | if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then |
2320 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2321 | else | |
2322 | case "$XGETTEXT" in | |
2323 | /*) | |
2324 | ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path. | |
2325 | ;; | |
2326 | *) | |
2327 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" | |
2328 | for ac_dir in $PATH; do | |
2329 | test -z "$ac_dir" && ac_dir=. | |
2330 | if test -f $ac_dir/$ac_word; then | |
2331 | if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then | |
2332 | ac_cv_path_XGETTEXT="$ac_dir/$ac_word" | |
2333 | break | |
2334 | fi | |
2335 | fi | |
2336 | done | |
2337 | IFS="$ac_save_ifs" | |
2338 | test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":" | |
2339 | ;; | |
2340 | esac | |
2341 | fi | |
2342 | XGETTEXT="$ac_cv_path_XGETTEXT" | |
2343 | if test -n "$XGETTEXT"; then | |
2344 | echo "$ac_t""$XGETTEXT" 1>&6 | |
2345 | else | |
2346 | echo "$ac_t""no" 1>&6 | |
2347 | fi | |
2348 | ||
2349 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 2350 | #line 2351 "configure" |
fcfc3c0c TT |
2351 | #include "confdefs.h" |
2352 | ||
2353 | int main() { | |
2354 | extern int _nl_msg_cat_cntr; | |
2355 | return _nl_msg_cat_cntr | |
2356 | ; return 0; } | |
2357 | EOF | |
ba68ad57 | 2358 | if { (eval echo configure:2359: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
fcfc3c0c TT |
2359 | rm -rf conftest* |
2360 | CATOBJEXT=.gmo | |
2361 | DATADIRNAME=share | |
2362 | else | |
2363 | echo "configure: failed program was:" >&5 | |
2364 | cat conftest.$ac_ext >&5 | |
2365 | rm -rf conftest* | |
2366 | CATOBJEXT=.mo | |
2367 | DATADIRNAME=lib | |
5436fc65 C |
2368 | fi |
2369 | rm -f conftest* | |
fcfc3c0c TT |
2370 | INSTOBJEXT=.mo |
2371 | fi | |
2372 | fi | |
2373 | ||
2374 | else | |
2375 | echo "$ac_t""no" 1>&6 | |
5436fc65 | 2376 | fi |
fcfc3c0c TT |
2377 | |
2378 | ||
2379 | ||
2380 | if test "$CATOBJEXT" = "NONE"; then | |
2381 | nls_cv_use_gnu_gettext=yes | |
2382 | fi | |
2383 | fi | |
2384 | ||
2385 | if test "$nls_cv_use_gnu_gettext" = "yes"; then | |
2386 | INTLOBJS="\$(GETTOBJS)" | |
2387 | # Extract the first word of "msgfmt", so it can be a program name with args. | |
2388 | set dummy msgfmt; ac_word=$2 | |
2389 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
ba68ad57 | 2390 | echo "configure:2391: checking for $ac_word" >&5 |
fcfc3c0c TT |
2391 | if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then |
2392 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2393 | else | |
2394 | case "$MSGFMT" in | |
2395 | /*) | |
2396 | ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. | |
2397 | ;; | |
2398 | *) | |
2399 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" | |
2400 | for ac_dir in $PATH; do | |
2401 | test -z "$ac_dir" && ac_dir=. | |
2402 | if test -f $ac_dir/$ac_word; then | |
2403 | if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then | |
2404 | ac_cv_path_MSGFMT="$ac_dir/$ac_word" | |
2405 | break | |
2406 | fi | |
2407 | fi | |
2408 | done | |
2409 | IFS="$ac_save_ifs" | |
2410 | test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="msgfmt" | |
2411 | ;; | |
2412 | esac | |
5436fc65 | 2413 | fi |
fcfc3c0c TT |
2414 | MSGFMT="$ac_cv_path_MSGFMT" |
2415 | if test -n "$MSGFMT"; then | |
2416 | echo "$ac_t""$MSGFMT" 1>&6 | |
dedcc91d | 2417 | else |
fcfc3c0c | 2418 | echo "$ac_t""no" 1>&6 |
5436fc65 | 2419 | fi |
5436fc65 | 2420 | |
fcfc3c0c TT |
2421 | # Extract the first word of "gmsgfmt", so it can be a program name with args. |
2422 | set dummy gmsgfmt; ac_word=$2 | |
2423 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
ba68ad57 | 2424 | echo "configure:2425: checking for $ac_word" >&5 |
fcfc3c0c TT |
2425 | if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then |
2426 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2427 | else | |
2428 | case "$GMSGFMT" in | |
2429 | /*) | |
2430 | ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path. | |
2431 | ;; | |
fcfc3c0c | 2432 | *) |
ba68ad57 | 2433 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" |
fcfc3c0c TT |
2434 | for ac_dir in $PATH; do |
2435 | test -z "$ac_dir" && ac_dir=. | |
2436 | if test -f $ac_dir/$ac_word; then | |
2437 | ac_cv_path_GMSGFMT="$ac_dir/$ac_word" | |
2438 | break | |
2439 | fi | |
2440 | done | |
2441 | IFS="$ac_save_ifs" | |
2442 | test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT" | |
2443 | ;; | |
2444 | esac | |
2445 | fi | |
2446 | GMSGFMT="$ac_cv_path_GMSGFMT" | |
2447 | if test -n "$GMSGFMT"; then | |
2448 | echo "$ac_t""$GMSGFMT" 1>&6 | |
2449 | else | |
2450 | echo "$ac_t""no" 1>&6 | |
2451 | fi | |
5436fc65 | 2452 | |
fcfc3c0c TT |
2453 | # Extract the first word of "xgettext", so it can be a program name with args. |
2454 | set dummy xgettext; ac_word=$2 | |
2455 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
ba68ad57 | 2456 | echo "configure:2457: checking for $ac_word" >&5 |
fcfc3c0c TT |
2457 | if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then |
2458 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2459 | else | |
2460 | case "$XGETTEXT" in | |
2461 | /*) | |
2462 | ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path. | |
2463 | ;; | |
2464 | *) | |
2465 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" | |
2466 | for ac_dir in $PATH; do | |
2467 | test -z "$ac_dir" && ac_dir=. | |
2468 | if test -f $ac_dir/$ac_word; then | |
2469 | if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then | |
2470 | ac_cv_path_XGETTEXT="$ac_dir/$ac_word" | |
2471 | break | |
2472 | fi | |
2473 | fi | |
2474 | done | |
2475 | IFS="$ac_save_ifs" | |
2476 | test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":" | |
2477 | ;; | |
2478 | esac | |
2479 | fi | |
2480 | XGETTEXT="$ac_cv_path_XGETTEXT" | |
2481 | if test -n "$XGETTEXT"; then | |
2482 | echo "$ac_t""$XGETTEXT" 1>&6 | |
5436fc65 | 2483 | else |
5436fc65 C |
2484 | echo "$ac_t""no" 1>&6 |
2485 | fi | |
5436fc65 | 2486 | |
fcfc3c0c TT |
2487 | |
2488 | USE_INCLUDED_LIBINTL=yes | |
2489 | CATOBJEXT=.gmo | |
2490 | INSTOBJEXT=.mo | |
2491 | DATADIRNAME=share | |
2492 | INTLDEPS='$(top_builddir)/../intl/libintl.a' | |
2493 | INTLLIBS=$INTLDEPS | |
2494 | LIBS=`echo $LIBS | sed -e 's/-lintl//'` | |
2495 | nls_cv_header_intl=libintl.h | |
2496 | nls_cv_header_libgt=libgettext.h | |
2497 | fi | |
5436fc65 | 2498 | |
fcfc3c0c TT |
2499 | if test "$XGETTEXT" != ":"; then |
2500 | if $XGETTEXT --omit-header /dev/null 2> /dev/null; then | |
2501 | : ; | |
2502 | else | |
2503 | echo "$ac_t""found xgettext programs is not GNU xgettext; ignore it" 1>&6 | |
2504 | XGETTEXT=":" | |
2505 | fi | |
2506 | fi | |
2507 | ||
2508 | # We need to process the po/ directory. | |
2509 | POSUB=po | |
2510 | else | |
2511 | DATADIRNAME=share | |
2512 | nls_cv_header_intl=libintl.h | |
2513 | nls_cv_header_libgt=libgettext.h | |
2514 | fi | |
2515 | ||
2516 | # If this is used in GNU gettext we have to set USE_NLS to `yes' | |
2517 | # because some of the sources are only built for this goal. | |
2518 | if test "$PACKAGE" = gettext; then | |
2519 | USE_NLS=yes | |
2520 | USE_INCLUDED_LIBINTL=yes | |
2521 | fi | |
2522 | ||
2523 | for lang in $ALL_LINGUAS; do | |
2524 | GMOFILES="$GMOFILES $lang.gmo" | |
2525 | POFILES="$POFILES $lang.po" | |
2526 | done | |
2527 | ||
2528 | ||
2529 | ||
2530 | ||
2531 | ||
2532 | ||
2533 | ||
2534 | ||
2535 | ||
2536 | ||
2537 | ||
2538 | ||
2539 | ||
2540 | ||
2541 | if test "x$CATOBJEXT" != "x"; then | |
2542 | if test "x$ALL_LINGUAS" = "x"; then | |
2543 | LINGUAS= | |
2544 | else | |
2545 | echo $ac_n "checking for catalogs to be installed""... $ac_c" 1>&6 | |
ba68ad57 | 2546 | echo "configure:2547: checking for catalogs to be installed" >&5 |
fcfc3c0c TT |
2547 | NEW_LINGUAS= |
2548 | for lang in ${LINGUAS=$ALL_LINGUAS}; do | |
2549 | case "$ALL_LINGUAS" in | |
2550 | *$lang*) NEW_LINGUAS="$NEW_LINGUAS $lang" ;; | |
2551 | esac | |
2552 | done | |
2553 | LINGUAS=$NEW_LINGUAS | |
2554 | echo "$ac_t""$LINGUAS" 1>&6 | |
2555 | fi | |
2556 | ||
2557 | if test -n "$LINGUAS"; then | |
2558 | for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done | |
2559 | fi | |
2560 | fi | |
2561 | ||
2562 | if test $ac_cv_header_locale_h = yes; then | |
2563 | INCLUDE_LOCALE_H="#include <locale.h>" | |
2564 | else | |
2565 | INCLUDE_LOCALE_H="\ | |
2566 | /* The system does not provide the header <locale.h>. Take care yourself. */" | |
2567 | fi | |
2568 | ||
2569 | ||
2570 | if test -f $srcdir/po2tbl.sed.in; then | |
2571 | if test "$CATOBJEXT" = ".cat"; then | |
2572 | ac_safe=`echo "linux/version.h" | sed 'y%./+-%__p_%'` | |
2573 | echo $ac_n "checking for linux/version.h""... $ac_c" 1>&6 | |
ba68ad57 | 2574 | echo "configure:2575: checking for linux/version.h" >&5 |
5436fc65 C |
2575 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
2576 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2577 | else | |
2578 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 2579 | #line 2580 "configure" |
5436fc65 | 2580 | #include "confdefs.h" |
fcfc3c0c | 2581 | #include <linux/version.h> |
5436fc65 | 2582 | EOF |
1a7b4b7c | 2583 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
ba68ad57 JM |
2584 | { (eval echo configure:2585: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
2585 | ac_err=`grep -v '^ *+' conftest.out` | |
5436fc65 C |
2586 | if test -z "$ac_err"; then |
2587 | rm -rf conftest* | |
2588 | eval "ac_cv_header_$ac_safe=yes" | |
2589 | else | |
2590 | echo "$ac_err" >&5 | |
bfde4a67 SG |
2591 | echo "configure: failed program was:" >&5 |
2592 | cat conftest.$ac_ext >&5 | |
5436fc65 C |
2593 | rm -rf conftest* |
2594 | eval "ac_cv_header_$ac_safe=no" | |
2595 | fi | |
2596 | rm -f conftest* | |
2597 | fi | |
2598 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | |
2599 | echo "$ac_t""yes" 1>&6 | |
fcfc3c0c | 2600 | msgformat=linux |
5436fc65 C |
2601 | else |
2602 | echo "$ac_t""no" 1>&6 | |
fcfc3c0c | 2603 | msgformat=xopen |
0579b53d GN |
2604 | fi |
2605 | ||
0579b53d | 2606 | |
fcfc3c0c TT |
2607 | sed -e '/^#/d' $srcdir/$msgformat-msg.sed > po2msg.sed |
2608 | fi | |
2609 | sed -e '/^#.*[^\\]$/d' -e '/^#$/d' \ | |
2610 | $srcdir/po2tbl.sed.in > po2tbl.sed | |
2611 | fi | |
2612 | ||
2613 | if test "$PACKAGE" = "gettext"; then | |
2614 | GT_NO="#NO#" | |
2615 | GT_YES= | |
2616 | else | |
2617 | GT_NO= | |
2618 | GT_YES="#YES#" | |
2619 | fi | |
2620 | ||
2621 | ||
0579b53d | 2622 | |
fcfc3c0c TT |
2623 | MKINSTALLDIRS="\$(srcdir)/../../mkinstalldirs" |
2624 | ||
0579b53d | 2625 | |
fcfc3c0c TT |
2626 | l= |
2627 | ||
0579b53d | 2628 | |
fcfc3c0c TT |
2629 | if test -d $srcdir/po; then |
2630 | test -d po || mkdir po | |
2631 | if test "x$srcdir" != "x."; then | |
2632 | if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then | |
2633 | posrcprefix="$srcdir/" | |
2634 | else | |
2635 | posrcprefix="../$srcdir/" | |
2636 | fi | |
2637 | else | |
2638 | posrcprefix="../" | |
2639 | fi | |
2640 | rm -f po/POTFILES | |
2641 | sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \ | |
2642 | < $srcdir/po/POTFILES.in > po/POTFILES | |
2643 | fi | |
2644 | ||
0579b53d | 2645 | |
bfde4a67 SG |
2646 | |
2647 | CONFIG_OBS= | |
018d76dd | 2648 | CONFIG_DEPS= |
c7bb1531 | 2649 | CONFIG_SRCS= |
bfde4a67 SG |
2650 | |
2651 | configdirs="doc testsuite" | |
2652 | ||
2653 | ||
2654 | . ${srcdir}/configure.host | |
2655 | ||
2656 | . ${srcdir}/configure.tgt | |
2657 | ||
2658 | ||
5436fc65 C |
2659 | # Find a good install program. We prefer a C program (faster), |
2660 | # so one script is as good as another. But avoid the broken or | |
2661 | # incompatible versions: | |
2662 | # SysV /etc/install, /usr/sbin/install | |
2663 | # SunOS /usr/etc/install | |
2664 | # IRIX /sbin/install | |
2665 | # AIX /bin/install | |
2666 | # AFS /usr/afsws/bin/install, which mishandles nonexistent args | |
2667 | # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" | |
2668 | # ./install, which can be erroneously created by make from ./install.sh. | |
2669 | echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6 | |
ba68ad57 | 2670 | echo "configure:2671: checking for a BSD compatible install" >&5 |
5436fc65 C |
2671 | if test -z "$INSTALL"; then |
2672 | if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then | |
2673 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2674 | else | |
ba68ad57 | 2675 | IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="${IFS}:" |
5436fc65 C |
2676 | for ac_dir in $PATH; do |
2677 | # Account for people who put trailing slashes in PATH elements. | |
2678 | case "$ac_dir/" in | |
2679 | /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;; | |
2680 | *) | |
2681 | # OSF1 and SCO ODT 3.0 have their own names for install. | |
ba68ad57 | 2682 | for ac_prog in ginstall installbsd scoinst install; do |
5436fc65 C |
2683 | if test -f $ac_dir/$ac_prog; then |
2684 | if test $ac_prog = install && | |
2685 | grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then | |
2686 | # AIX install. It has an incompatible calling convention. | |
ba68ad57 | 2687 | # OSF/1 installbsd also uses dspmsg, but is usable. |
5436fc65 C |
2688 | : |
2689 | else | |
2690 | ac_cv_path_install="$ac_dir/$ac_prog -c" | |
2691 | break 2 | |
2692 | fi | |
2693 | fi | |
2694 | done | |
2695 | ;; | |
2696 | esac | |
2697 | done | |
bfde4a67 | 2698 | IFS="$ac_save_IFS" |
1a7b4b7c | 2699 | |
5436fc65 | 2700 | fi |
1a7b4b7c DE |
2701 | if test "${ac_cv_path_install+set}" = set; then |
2702 | INSTALL="$ac_cv_path_install" | |
2703 | else | |
2704 | # As a last resort, use the slow shell script. We don't cache a | |
2705 | # path for INSTALL within a source directory, because that will | |
2706 | # break other packages using the cache if that directory is | |
2707 | # removed, or if the path is relative. | |
2708 | INSTALL="$ac_install_sh" | |
2709 | fi | |
5436fc65 C |
2710 | fi |
2711 | echo "$ac_t""$INSTALL" 1>&6 | |
2712 | ||
2713 | # Use test -z because SunOS4 sh mishandles braces in ${var-val}. | |
2714 | # It thinks the first close brace ends the variable substitution. | |
2715 | test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' | |
2716 | ||
2717 | test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' | |
2718 | ||
d8efbc66 FF |
2719 | if test $host != $build; then |
2720 | ac_tool_prefix=${host_alias}- | |
2721 | else | |
2722 | ac_tool_prefix= | |
2723 | fi | |
2724 | ||
2725 | # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args. | |
2726 | set dummy ${ac_tool_prefix}ar; ac_word=$2 | |
2727 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
ba68ad57 | 2728 | echo "configure:2729: checking for $ac_word" >&5 |
d8efbc66 FF |
2729 | if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then |
2730 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2731 | else | |
2732 | if test -n "$AR"; then | |
2733 | ac_cv_prog_AR="$AR" # Let the user override the test. | |
2734 | else | |
ba68ad57 | 2735 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" |
d8efbc66 FF |
2736 | for ac_dir in $PATH; do |
2737 | test -z "$ac_dir" && ac_dir=. | |
2738 | if test -f $ac_dir/$ac_word; then | |
2739 | ac_cv_prog_AR="${ac_tool_prefix}ar" | |
2740 | break | |
2741 | fi | |
2742 | done | |
2743 | IFS="$ac_save_ifs" | |
2744 | test -z "$ac_cv_prog_AR" && ac_cv_prog_AR="ar" | |
2745 | fi | |
2746 | fi | |
2747 | AR="$ac_cv_prog_AR" | |
2748 | if test -n "$AR"; then | |
2749 | echo "$ac_t""$AR" 1>&6 | |
2750 | else | |
2751 | echo "$ac_t""no" 1>&6 | |
2752 | fi | |
2753 | ||
2754 | ||
2755 | ||
2756 | # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. | |
2757 | set dummy ${ac_tool_prefix}ranlib; ac_word=$2 | |
2758 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
ba68ad57 | 2759 | echo "configure:2760: checking for $ac_word" >&5 |
d8efbc66 FF |
2760 | if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then |
2761 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2762 | else | |
2763 | if test -n "$RANLIB"; then | |
2764 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. | |
2765 | else | |
ba68ad57 | 2766 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" |
d8efbc66 FF |
2767 | for ac_dir in $PATH; do |
2768 | test -z "$ac_dir" && ac_dir=. | |
2769 | if test -f $ac_dir/$ac_word; then | |
2770 | ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" | |
2771 | break | |
2772 | fi | |
2773 | done | |
2774 | IFS="$ac_save_ifs" | |
2775 | fi | |
2776 | fi | |
2777 | RANLIB="$ac_cv_prog_RANLIB" | |
2778 | if test -n "$RANLIB"; then | |
2779 | echo "$ac_t""$RANLIB" 1>&6 | |
2780 | else | |
2781 | echo "$ac_t""no" 1>&6 | |
2782 | fi | |
2783 | ||
2784 | ||
2785 | if test -z "$ac_cv_prog_RANLIB"; then | |
2786 | if test -n "$ac_tool_prefix"; then | |
2787 | # Extract the first word of "ranlib", so it can be a program name with args. | |
5436fc65 C |
2788 | set dummy ranlib; ac_word=$2 |
2789 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
ba68ad57 | 2790 | echo "configure:2791: checking for $ac_word" >&5 |
5436fc65 C |
2791 | if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then |
2792 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2793 | else | |
2794 | if test -n "$RANLIB"; then | |
2795 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. | |
2796 | else | |
ba68ad57 | 2797 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" |
da3d57e3 | 2798 | for ac_dir in $PATH; do |
5436fc65 C |
2799 | test -z "$ac_dir" && ac_dir=. |
2800 | if test -f $ac_dir/$ac_word; then | |
2801 | ac_cv_prog_RANLIB="ranlib" | |
2802 | break | |
2803 | fi | |
2804 | done | |
2805 | IFS="$ac_save_ifs" | |
2806 | test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":" | |
2807 | fi | |
2808 | fi | |
2809 | RANLIB="$ac_cv_prog_RANLIB" | |
2810 | if test -n "$RANLIB"; then | |
2811 | echo "$ac_t""$RANLIB" 1>&6 | |
2812 | else | |
2813 | echo "$ac_t""no" 1>&6 | |
2814 | fi | |
2815 | ||
d8efbc66 FF |
2816 | else |
2817 | RANLIB=":" | |
2818 | fi | |
2819 | fi | |
2820 | ||
204c8825 FF |
2821 | for ac_prog in 'bison -y' byacc |
2822 | do | |
2823 | # Extract the first word of "$ac_prog", so it can be a program name with args. | |
2824 | set dummy $ac_prog; ac_word=$2 | |
2825 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
ba68ad57 | 2826 | echo "configure:2827: checking for $ac_word" >&5 |
204c8825 FF |
2827 | if eval "test \"`echo '$''{'ac_cv_prog_YACC'+set}'`\" = set"; then |
2828 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2829 | else | |
2830 | if test -n "$YACC"; then | |
2831 | ac_cv_prog_YACC="$YACC" # Let the user override the test. | |
2832 | else | |
ba68ad57 | 2833 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" |
204c8825 FF |
2834 | for ac_dir in $PATH; do |
2835 | test -z "$ac_dir" && ac_dir=. | |
2836 | if test -f $ac_dir/$ac_word; then | |
2837 | ac_cv_prog_YACC="$ac_prog" | |
2838 | break | |
2839 | fi | |
2840 | done | |
2841 | IFS="$ac_save_ifs" | |
2842 | fi | |
2843 | fi | |
2844 | YACC="$ac_cv_prog_YACC" | |
2845 | if test -n "$YACC"; then | |
2846 | echo "$ac_t""$YACC" 1>&6 | |
2847 | else | |
2848 | echo "$ac_t""no" 1>&6 | |
2849 | fi | |
2850 | ||
2851 | test -n "$YACC" && break | |
2852 | done | |
2853 | test -n "$YACC" || YACC="yacc" | |
2854 | ||
d8efbc66 FF |
2855 | for ac_prog in mawk gawk nawk awk |
2856 | do | |
2857 | # Extract the first word of "$ac_prog", so it can be a program name with args. | |
2858 | set dummy $ac_prog; ac_word=$2 | |
2859 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
ba68ad57 | 2860 | echo "configure:2861: checking for $ac_word" >&5 |
d8efbc66 FF |
2861 | if eval "test \"`echo '$''{'ac_cv_prog_AWK'+set}'`\" = set"; then |
2862 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2863 | else | |
2864 | if test -n "$AWK"; then | |
2865 | ac_cv_prog_AWK="$AWK" # Let the user override the test. | |
2866 | else | |
ba68ad57 | 2867 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" |
d8efbc66 FF |
2868 | for ac_dir in $PATH; do |
2869 | test -z "$ac_dir" && ac_dir=. | |
2870 | if test -f $ac_dir/$ac_word; then | |
2871 | ac_cv_prog_AWK="$ac_prog" | |
2872 | break | |
2873 | fi | |
2874 | done | |
2875 | IFS="$ac_save_ifs" | |
2876 | fi | |
2877 | fi | |
2878 | AWK="$ac_cv_prog_AWK" | |
2879 | if test -n "$AWK"; then | |
2880 | echo "$ac_t""$AWK" 1>&6 | |
2881 | else | |
2882 | echo "$ac_t""no" 1>&6 | |
2883 | fi | |
2884 | ||
2885 | test -n "$AWK" && break | |
2886 | done | |
2887 | ||
5436fc65 | 2888 | |
5436fc65 C |
2889 | if test "$program_transform_name" = s,x,x,; then |
2890 | program_transform_name= | |
2891 | else | |
1a7b4b7c DE |
2892 | # Double any \ or $. echo might interpret backslashes. |
2893 | cat <<\EOF_SED > conftestsed | |
2894 | s,\\,\\\\,g; s,\$,$$,g | |
2895 | EOF_SED | |
5436fc65 C |
2896 | program_transform_name="`echo $program_transform_name|sed -f conftestsed`" |
2897 | rm -f conftestsed | |
2898 | fi | |
2899 | test "$program_prefix" != NONE && | |
2900 | program_transform_name="s,^,${program_prefix},; $program_transform_name" | |
2901 | # Use a double $ so make ignores it. | |
2902 | test "$program_suffix" != NONE && | |
2903 | program_transform_name="s,\$\$,${program_suffix},; $program_transform_name" | |
2904 | ||
2905 | # sed with no file args requires a program. | |
2906 | test "$program_transform_name" = "" && program_transform_name="s,x,x," | |
2907 | ||
2908 | ||
c14cabba | 2909 | echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6 |
ba68ad57 | 2910 | echo "configure:2911: checking return type of signal handlers" >&5 |
c14cabba AC |
2911 | if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then |
2912 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2913 | else | |
2914 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 2915 | #line 2916 "configure" |
c14cabba AC |
2916 | #include "confdefs.h" |
2917 | #include <sys/types.h> | |
2918 | #include <signal.h> | |
2919 | #ifdef signal | |
2920 | #undef signal | |
2921 | #endif | |
2922 | #ifdef __cplusplus | |
2923 | extern "C" void (*signal (int, void (*)(int)))(int); | |
2924 | #else | |
2925 | void (*signal ()) (); | |
2926 | #endif | |
2927 | ||
2928 | int main() { | |
2929 | int i; | |
2930 | ; return 0; } | |
2931 | EOF | |
ba68ad57 | 2932 | if { (eval echo configure:2933: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
c14cabba AC |
2933 | rm -rf conftest* |
2934 | ac_cv_type_signal=void | |
2935 | else | |
2936 | echo "configure: failed program was:" >&5 | |
2937 | cat conftest.$ac_ext >&5 | |
2938 | rm -rf conftest* | |
2939 | ac_cv_type_signal=int | |
2940 | fi | |
2941 | rm -f conftest* | |
2942 | fi | |
2943 | ||
2944 | echo "$ac_t""$ac_cv_type_signal" 1>&6 | |
2945 | cat >> confdefs.h <<EOF | |
2946 | #define RETSIGTYPE $ac_cv_type_signal | |
2947 | EOF | |
2948 | ||
2949 | ||
2950 | ||
2b576293 | 2951 | echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6 |
ba68ad57 | 2952 | echo "configure:2953: checking for ANSI C header files" >&5 |
2b576293 C |
2953 | if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then |
2954 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2955 | else | |
2956 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 2957 | #line 2958 "configure" |
2b576293 C |
2958 | #include "confdefs.h" |
2959 | #include <stdlib.h> | |
2960 | #include <stdarg.h> | |
2961 | #include <string.h> | |
2962 | #include <float.h> | |
2963 | EOF | |
1a7b4b7c | 2964 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
ba68ad57 JM |
2965 | { (eval echo configure:2966: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
2966 | ac_err=`grep -v '^ *+' conftest.out` | |
2b576293 C |
2967 | if test -z "$ac_err"; then |
2968 | rm -rf conftest* | |
2969 | ac_cv_header_stdc=yes | |
2970 | else | |
2971 | echo "$ac_err" >&5 | |
bfde4a67 SG |
2972 | echo "configure: failed program was:" >&5 |
2973 | cat conftest.$ac_ext >&5 | |
2b576293 C |
2974 | rm -rf conftest* |
2975 | ac_cv_header_stdc=no | |
2976 | fi | |
2977 | rm -f conftest* | |
2978 | ||
2979 | if test $ac_cv_header_stdc = yes; then | |
2980 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. | |
2981 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 2982 | #line 2983 "configure" |
2b576293 C |
2983 | #include "confdefs.h" |
2984 | #include <string.h> | |
2985 | EOF | |
2986 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
2987 | egrep "memchr" >/dev/null 2>&1; then | |
2988 | : | |
2989 | else | |
2990 | rm -rf conftest* | |
2991 | ac_cv_header_stdc=no | |
2992 | fi | |
2993 | rm -f conftest* | |
2994 | ||
2995 | fi | |
2996 | ||
2997 | if test $ac_cv_header_stdc = yes; then | |
2998 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. | |
2999 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 3000 | #line 3001 "configure" |
2b576293 C |
3001 | #include "confdefs.h" |
3002 | #include <stdlib.h> | |
3003 | EOF | |
3004 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
3005 | egrep "free" >/dev/null 2>&1; then | |
3006 | : | |
3007 | else | |
3008 | rm -rf conftest* | |
3009 | ac_cv_header_stdc=no | |
3010 | fi | |
3011 | rm -f conftest* | |
3012 | ||
3013 | fi | |
3014 | ||
3015 | if test $ac_cv_header_stdc = yes; then | |
3016 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. | |
3017 | if test "$cross_compiling" = yes; then | |
1a7b4b7c | 3018 | : |
2b576293 | 3019 | else |
bfde4a67 | 3020 | cat > conftest.$ac_ext <<EOF |
ba68ad57 | 3021 | #line 3022 "configure" |
2b576293 C |
3022 | #include "confdefs.h" |
3023 | #include <ctype.h> | |
3024 | #define ISLOWER(c) ('a' <= (c) && (c) <= 'z') | |
3025 | #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) | |
3026 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) | |
3027 | int main () { int i; for (i = 0; i < 256; i++) | |
3028 | if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2); | |
3029 | exit (0); } | |
3030 | ||
3031 | EOF | |
ba68ad57 | 3032 | if { (eval echo configure:3033: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null |
bfde4a67 | 3033 | then |
2b576293 C |
3034 | : |
3035 | else | |
bfde4a67 SG |
3036 | echo "configure: failed program was:" >&5 |
3037 | cat conftest.$ac_ext >&5 | |
3038 | rm -fr conftest* | |
2b576293 C |
3039 | ac_cv_header_stdc=no |
3040 | fi | |
ef6c51d1 | 3041 | rm -fr conftest* |
bfde4a67 SG |
3042 | fi |
3043 | ||
2b576293 C |
3044 | fi |
3045 | fi | |
1a7b4b7c | 3046 | |
2b576293 C |
3047 | echo "$ac_t""$ac_cv_header_stdc" 1>&6 |
3048 | if test $ac_cv_header_stdc = yes; then | |
3049 | cat >> confdefs.h <<\EOF | |
3050 | #define STDC_HEADERS 1 | |
3051 | EOF | |
3052 | ||
3053 | fi | |
3054 | ||
4ff3dfab JM |
3055 | for ac_hdr in ctype.h curses.h endian.h libintl.h limits.h link.h \ |
3056 | memory.h objlist.h ptrace.h sgtty.h stddef.h stdlib.h \ | |
3057 | string.h strings.h sys/procfs.h sys/ptrace.h sys/reg.h \ | |
3058 | term.h termio.h termios.h unistd.h wait.h sys/wait.h \ | |
3059 | wchar.h wctype.h | |
1a494973 | 3060 | do |
bfde4a67 | 3061 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` |
1a494973 | 3062 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 |
ba68ad57 | 3063 | echo "configure:3064: checking for $ac_hdr" >&5 |
1a494973 C |
3064 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
3065 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3066 | else | |
3067 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 3068 | #line 3069 "configure" |
1a494973 C |
3069 | #include "confdefs.h" |
3070 | #include <$ac_hdr> | |
3071 | EOF | |
1a7b4b7c | 3072 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
ba68ad57 JM |
3073 | { (eval echo configure:3074: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
3074 | ac_err=`grep -v '^ *+' conftest.out` | |
1a494973 C |
3075 | if test -z "$ac_err"; then |
3076 | rm -rf conftest* | |
3077 | eval "ac_cv_header_$ac_safe=yes" | |
3078 | else | |
3079 | echo "$ac_err" >&5 | |
bfde4a67 SG |
3080 | echo "configure: failed program was:" >&5 |
3081 | cat conftest.$ac_ext >&5 | |
1a494973 C |
3082 | rm -rf conftest* |
3083 | eval "ac_cv_header_$ac_safe=no" | |
3084 | fi | |
3085 | rm -f conftest* | |
3086 | fi | |
3087 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | |
3088 | echo "$ac_t""yes" 1>&6 | |
bfde4a67 | 3089 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` |
1a494973 C |
3090 | cat >> confdefs.h <<EOF |
3091 | #define $ac_tr_hdr 1 | |
3092 | EOF | |
3093 | ||
3094 | else | |
3095 | echo "$ac_t""no" 1>&6 | |
3096 | fi | |
3097 | done | |
3098 | ||
eac4afd1 | 3099 | |
2b576293 | 3100 | echo $ac_n "checking whether stat file-mode macros are broken""... $ac_c" 1>&6 |
ba68ad57 | 3101 | echo "configure:3102: checking whether stat file-mode macros are broken" >&5 |
2b576293 C |
3102 | if eval "test \"`echo '$''{'ac_cv_header_stat_broken'+set}'`\" = set"; then |
3103 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3104 | else | |
3105 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 3106 | #line 3107 "configure" |
2b576293 C |
3107 | #include "confdefs.h" |
3108 | #include <sys/types.h> | |
3109 | #include <sys/stat.h> | |
3110 | ||
3111 | #if defined(S_ISBLK) && defined(S_IFDIR) | |
3112 | # if S_ISBLK (S_IFDIR) | |
3113 | You lose. | |
3114 | # endif | |
3115 | #endif | |
3116 | ||
3117 | #if defined(S_ISBLK) && defined(S_IFCHR) | |
3118 | # if S_ISBLK (S_IFCHR) | |
3119 | You lose. | |
3120 | # endif | |
3121 | #endif | |
3122 | ||
3123 | #if defined(S_ISLNK) && defined(S_IFREG) | |
3124 | # if S_ISLNK (S_IFREG) | |
3125 | You lose. | |
3126 | # endif | |
3127 | #endif | |
3128 | ||
3129 | #if defined(S_ISSOCK) && defined(S_IFREG) | |
3130 | # if S_ISSOCK (S_IFREG) | |
3131 | You lose. | |
3132 | # endif | |
3133 | #endif | |
3134 | ||
3135 | EOF | |
3136 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
3137 | egrep "You lose" >/dev/null 2>&1; then | |
3138 | rm -rf conftest* | |
3139 | ac_cv_header_stat_broken=yes | |
3140 | else | |
3141 | rm -rf conftest* | |
3142 | ac_cv_header_stat_broken=no | |
3143 | fi | |
3144 | rm -f conftest* | |
3145 | ||
3146 | fi | |
1a7b4b7c | 3147 | |
2b576293 C |
3148 | echo "$ac_t""$ac_cv_header_stat_broken" 1>&6 |
3149 | if test $ac_cv_header_stat_broken = yes; then | |
3150 | cat >> confdefs.h <<\EOF | |
3151 | #define STAT_MACROS_BROKEN 1 | |
3152 | EOF | |
3153 | ||
3154 | fi | |
3155 | ||
3156 | ||
8501c742 | 3157 | echo $ac_n "checking for working const""... $ac_c" 1>&6 |
ba68ad57 | 3158 | echo "configure:3159: checking for working const" >&5 |
8501c742 SG |
3159 | if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then |
3160 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3161 | else | |
3162 | cat > conftest.$ac_ext <<EOF | |
ba68ad57 | 3163 | #line 3164 "configure" |
8501c742 SG |
3164 | #include "confdefs.h" |
3165 | ||
bfde4a67 | 3166 | int main() { |
8501c742 SG |
3167 | |
3168 | /* Ultrix mips cc rejects this. */ | |
3169 | typedef int charset[2]; const charset x; | |
3170 | /* SunOS 4.1.1 cc rejects this. */ | |
3171 | char const *const *ccp; | |
3172 | char **p; | |
3173 | /* NEC SVR4.0.2 mips cc rejects this. */ | |
3174 | struct point {int x, y;}; | |
3175 | static struct point const zero = {0,0}; | |
3176 | /* AIX XL C 1.02.0.0 rejects this. | |
3177 | It does not let you subtract one const X* pointer from another in an arm | |
3178 | of an if-expression whose if-part is not a constant expression */ | |
3179 | const char *g = "string"; | |
3180 | ccp = &g + (g ? g-g : 0); | |
3181 | /* HPUX 7.0 cc rejects these. */ | |
3182 | ++ccp; | |
3183 | p = (char**) ccp; | |
3184 | ccp = (char const *const *) p; | |
3185 | { /* SCO 3.2v4 cc rejects this. */ | |
3186 | char *t; | |
3187 | char const *s = 0 ? (char *) 0 : (char const *) 0; | |
3188 | ||
3189 | *t++ = 0; | |
3190 | } | |
3191 | { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ | |
3192 | int x[] = {25, 17}; | |
3193 | const int *foo = &x[0]; | |
3194 | ++foo; | |
3195 | } | |
3196 | { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ | |
3197 | typedef const int *iptr; | |
3198 | iptr p = 0; | |
3199 | ++p; | |
3200 | } | |
3201 | { /* AIX XL C 1.02.0.0 rejects this saying | |
3202 | "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ | |
3203 | struct s { int j; const int *ap[3]; }; | |
3204 | struct s *b; b->j = 5; | |
3205 | } | |
3206 | { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ | |
3207 | const int foo = 10; | |
3208 | } | |
3209 | ||
3210 | ; return 0; } | |
3211 | EOF | |
ba68ad57 | 3212 | if { (eval echo configure:3213: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
8501c742 SG |
3213 | rm -rf conftest* |
3214 | ac_cv_c_const=yes | |
3215 | else | |
bfde4a67 SG |
3216 | echo "configure: failed program was:" >&5 |
3217 | cat conftest.$ac_ext >&5 | |
8501c742 SG |
3218 | rm -rf conftest* |
3219 | ac_cv_c_const=no | |
3220 | fi | |
3221 | rm -f conftest* | |
8501c742 SG |
3222 | fi |
3223 | ||
3224 | echo "$ac_t""$ac_cv_c_const" 1>&6 | |
3225 | if test $ac_cv_c_const = no; then | |
3226 | cat >> confdefs.h <<\EOF | |
3227 | #define const | |
3228 | EOF | |
3229 | ||
3230 | fi | |
3231 | ||
3232 | ||
e3009a74 JM |
3233 | for ac_func in setpgid sbrk select poll sigaction isascii bzero bcopy \ |
3234 | memcpy btowc | |
72ae15f6 FF |
3235 | do |
3236 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
e3009a74 | 3237 | echo "configure:3238: checking for $ac_func" >&5 |
72ae15f6 FF |
3238 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
3239 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3240 | else | |
3241 | cat > conftest.$ac_ext <<EOF | |
e3009a74 | 3242 | #line 3243 "configure" |
72ae15f6 FF |
3243 | #include "confdefs.h" |
3244 | /* System header to define __stub macros and hopefully few prototypes, | |
3245 | which can conflict with char $ac_func(); below. */ | |
3246 | #include <assert.h> | |
3247 | /* Override any gcc2 internal prototype to avoid an error. */ | |
bc859e63 SG |
3248 | /* We use char because int might match the return type of a gcc2 |
3249 | builtin and then its argument prototype would still apply. */ | |
1a7b4b7c | 3250 | char $ac_func(); |
72ae15f6 | 3251 | |
bfde4a67 | 3252 | int main() { |
72ae15f6 FF |
3253 | |
3254 | /* The GNU C library defines this for functions which it implements | |
3255 | to always fail with ENOSYS. Some functions are actually named | |
3256 | something starting with __ and the normal name is an alias. */ | |
3257 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
3258 | choke me | |
3259 | #else | |
3260 | $ac_func(); | |
3261 | #endif | |
3262 | ||
3263 | ; return 0; } | |
3264 | EOF | |
e3009a74 | 3265 | if { (eval echo configure:3266: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
72ae15f6 FF |
3266 | rm -rf conftest* |
3267 | eval "ac_cv_func_$ac_func=yes" | |
3268 | else | |
bfde4a67 SG |
3269 | echo "configure: failed program was:" >&5 |
3270 | cat conftest.$ac_ext >&5 | |
72ae15f6 FF |
3271 | rm -rf conftest* |
3272 | eval "ac_cv_func_$ac_func=no" | |
3273 | fi | |
3274 | rm -f conftest* | |
ef6c51d1 | 3275 | fi |
bfde4a67 | 3276 | |
72ae15f6 FF |
3277 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
3278 | echo "$ac_t""yes" 1>&6 | |
1a7b4b7c | 3279 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
72ae15f6 FF |
3280 | cat >> confdefs.h <<EOF |
3281 | #define $ac_tr_func 1 | |
3282 | EOF | |
3283 | ||
3284 | else | |
3285 | echo "$ac_t""no" 1>&6 | |
3286 | fi | |
3287 | done | |
3288 | ||
0aa3233e ILT |
3289 | # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works |
3290 | # for constant arguments. Useless! | |
3291 | echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6 | |
e3009a74 | 3292 | echo "configure:3293: checking for working alloca.h" >&5 |
0aa3233e ILT |
3293 | if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then |
3294 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3295 | else | |
3296 | cat > conftest.$ac_ext <<EOF | |
e3009a74 | 3297 | #line 3298 "configure" |
0aa3233e ILT |
3298 | #include "confdefs.h" |
3299 | #include <alloca.h> | |
3300 | int main() { | |
3301 | char *p = alloca(2 * sizeof(int)); | |
3302 | ; return 0; } | |
3303 | EOF | |
e3009a74 | 3304 | if { (eval echo configure:3305: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
0aa3233e ILT |
3305 | rm -rf conftest* |
3306 | ac_cv_header_alloca_h=yes | |
3307 | else | |
3308 | echo "configure: failed program was:" >&5 | |
3309 | cat conftest.$ac_ext >&5 | |
3310 | rm -rf conftest* | |
3311 | ac_cv_header_alloca_h=no | |
3312 | fi | |
3313 | rm -f conftest* | |
3314 | fi | |
3315 | ||
3316 | echo "$ac_t""$ac_cv_header_alloca_h" 1>&6 | |
3317 | if test $ac_cv_header_alloca_h = yes; then | |
3318 | cat >> confdefs.h <<\EOF | |
3319 | #define HAVE_ALLOCA_H 1 | |
3320 | EOF | |
3321 | ||
3322 | fi | |
3323 | ||
3324 | echo $ac_n "checking for alloca""... $ac_c" 1>&6 | |
e3009a74 | 3325 | echo "configure:3326: checking for alloca" >&5 |
0aa3233e ILT |
3326 | if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then |
3327 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3328 | else | |
3329 | cat > conftest.$ac_ext <<EOF | |
e3009a74 | 3330 | #line 3331 "configure" |
0aa3233e ILT |
3331 | #include "confdefs.h" |
3332 | ||
3333 | #ifdef __GNUC__ | |
3334 | # define alloca __builtin_alloca | |
3335 | #else | |
ba68ad57 JM |
3336 | # if HAVE_ALLOCA_H |
3337 | # include <alloca.h> | |
0aa3233e | 3338 | # else |
ba68ad57 | 3339 | # ifdef _AIX |
6ee3e5d6 | 3340 | #pragma alloca |
ba68ad57 JM |
3341 | # else |
3342 | # ifndef alloca /* predefined by HP cc +Olibcalls */ | |
0aa3233e ILT |
3343 | char *alloca (); |
3344 | # endif | |
3345 | # endif | |
3346 | # endif | |
3347 | #endif | |
3348 | ||
3349 | int main() { | |
3350 | char *p = (char *) alloca(1); | |
3351 | ; return 0; } | |
3352 | EOF | |
e3009a74 | 3353 | if { (eval echo configure:3354: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
0aa3233e ILT |
3354 | rm -rf conftest* |
3355 | ac_cv_func_alloca_works=yes | |
3356 | else | |
3357 | echo "configure: failed program was:" >&5 | |
3358 | cat conftest.$ac_ext >&5 | |
3359 | rm -rf conftest* | |
3360 | ac_cv_func_alloca_works=no | |
3361 | fi | |
3362 | rm -f conftest* | |
3363 | fi | |
3364 | ||
3365 | echo "$ac_t""$ac_cv_func_alloca_works" 1>&6 | |
3366 | if test $ac_cv_func_alloca_works = yes; then | |
3367 | cat >> confdefs.h <<\EOF | |
3368 | #define HAVE_ALLOCA 1 | |
3369 | EOF | |
3370 | ||
3371 | fi | |
3372 | ||
3373 | if test $ac_cv_func_alloca_works = no; then | |
3374 | # The SVR3 libPW and SVR4 libucb both contain incompatible functions | |
3375 | # that cause trouble. Some versions do not even contain alloca or | |
3376 | # contain a buggy version. If you still want to use their alloca, | |
3377 | # use ar to extract alloca.o from them instead of compiling alloca.c. | |
ba68ad57 | 3378 | ALLOCA=alloca.o |
0aa3233e ILT |
3379 | cat >> confdefs.h <<\EOF |
3380 | #define C_ALLOCA 1 | |
3381 | EOF | |
3382 | ||
3383 | ||
3384 | echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6 | |
e3009a74 | 3385 | echo "configure:3386: checking whether alloca needs Cray hooks" >&5 |
0aa3233e ILT |
3386 | if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then |
3387 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3388 | else | |
3389 | cat > conftest.$ac_ext <<EOF | |
e3009a74 | 3390 | #line 3391 "configure" |
0aa3233e ILT |
3391 | #include "confdefs.h" |
3392 | #if defined(CRAY) && ! defined(CRAY2) | |
3393 | webecray | |
3394 | #else | |
3395 | wenotbecray | |
3396 | #endif | |
3397 | ||
3398 | EOF | |
3399 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
3400 | egrep "webecray" >/dev/null 2>&1; then | |
3401 | rm -rf conftest* | |
3402 | ac_cv_os_cray=yes | |
3403 | else | |
3404 | rm -rf conftest* | |
3405 | ac_cv_os_cray=no | |
3406 | fi | |
3407 | rm -f conftest* | |
3408 | ||
3409 | fi | |
3410 | ||
3411 | echo "$ac_t""$ac_cv_os_cray" 1>&6 | |
3412 | if test $ac_cv_os_cray = yes; then | |
3413 | for ac_func in _getb67 GETB67 getb67; do | |
3414 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
e3009a74 | 3415 | echo "configure:3416: checking for $ac_func" >&5 |
0aa3233e ILT |
3416 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
3417 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3418 | else | |
3419 | cat > conftest.$ac_ext <<EOF | |
e3009a74 | 3420 | #line 3421 "configure" |
0aa3233e ILT |
3421 | #include "confdefs.h" |
3422 | /* System header to define __stub macros and hopefully few prototypes, | |
3423 | which can conflict with char $ac_func(); below. */ | |
3424 | #include <assert.h> | |
3425 | /* Override any gcc2 internal prototype to avoid an error. */ | |
3426 | /* We use char because int might match the return type of a gcc2 | |
3427 | builtin and then its argument prototype would still apply. */ | |
3428 | char $ac_func(); | |
3429 | ||
3430 | int main() { | |
3431 | ||
3432 | /* The GNU C library defines this for functions which it implements | |
3433 | to always fail with ENOSYS. Some functions are actually named | |
3434 | something starting with __ and the normal name is an alias. */ | |
3435 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
3436 | choke me | |
3437 | #else | |
3438 | $ac_func(); | |
3439 | #endif | |
3440 | ||
3441 | ; return 0; } | |
3442 | EOF | |
e3009a74 | 3443 | if { (eval echo configure:3444: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
0aa3233e ILT |
3444 | rm -rf conftest* |
3445 | eval "ac_cv_func_$ac_func=yes" | |
3446 | else | |
3447 | echo "configure: failed program was:" >&5 | |
3448 | cat conftest.$ac_ext >&5 | |
3449 | rm -rf conftest* | |
3450 | eval "ac_cv_func_$ac_func=no" | |
3451 | fi | |
3452 | rm -f conftest* | |
3453 | fi | |
3454 | ||
3455 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then | |
3456 | echo "$ac_t""yes" 1>&6 | |
3457 | cat >> confdefs.h <<EOF | |
3458 | #define CRAY_STACKSEG_END $ac_func | |
3459 | EOF | |
3460 | ||
3461 | break | |
3462 | else | |
3463 | echo "$ac_t""no" 1>&6 | |
3464 | fi | |
3465 | ||
3466 | done | |
3467 | fi | |
3468 | ||
3469 | echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6 | |
e3009a74 | 3470 | echo "configure:3471: checking stack direction for C alloca" >&5 |
0aa3233e ILT |
3471 | if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then |
3472 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3473 | else | |
3474 | if test "$cross_compiling" = yes; then | |
3475 | ac_cv_c_stack_direction=0 | |
3476 | else | |
3477 | cat > conftest.$ac_ext <<EOF | |
e3009a74 | 3478 | #line 3479 "configure" |
0aa3233e ILT |
3479 | #include "confdefs.h" |
3480 | find_stack_direction () | |
3481 | { | |
3482 | static char *addr = 0; | |
3483 | auto char dummy; | |
3484 | if (addr == 0) | |
3485 | { | |
3486 | addr = &dummy; | |
3487 | return find_stack_direction (); | |
3488 | } | |
3489 | else | |
3490 | return (&dummy > addr) ? 1 : -1; | |
3491 | } | |
3492 | main () | |
3493 | { | |
3494 | exit (find_stack_direction() < 0); | |
3495 | } | |
3496 | EOF | |
e3009a74 | 3497 | if { (eval echo configure:3498: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null |
0aa3233e ILT |
3498 | then |
3499 | ac_cv_c_stack_direction=1 | |
3500 | else | |
3501 | echo "configure: failed program was:" >&5 | |
3502 | cat conftest.$ac_ext >&5 | |
3503 | rm -fr conftest* | |
3504 | ac_cv_c_stack_direction=-1 | |
3505 | fi | |
3506 | rm -fr conftest* | |
3507 | fi | |
3508 | ||
3509 | fi | |
3510 | ||
3511 | echo "$ac_t""$ac_cv_c_stack_direction" 1>&6 | |
3512 | cat >> confdefs.h <<EOF | |
3513 | #define STACK_DIRECTION $ac_cv_c_stack_direction | |
3514 | EOF | |
3515 | ||
3516 | fi | |
3517 | ||
72ae15f6 | 3518 | |
75a55dc3 | 3519 | # If we are configured native on GNU/Linux, work around problems with sys/procfs.h |
0d4c1152 FF |
3520 | if test "${target}" = "${host}"; then |
3521 | case "${host}" in | |
0728afad | 3522 | i[3456]86-*-linux*) |
0d4c1152 | 3523 | cat >> confdefs.h <<\EOF |
0728afad | 3524 | #define START_INFERIOR_TRAPS_EXPECTED 2 |
0d4c1152 FF |
3525 | EOF |
3526 | ||
3527 | cat >> confdefs.h <<\EOF | |
3528 | #define sys_quotactl 1 | |
3529 | EOF | |
3530 | ||
3531 | ;; | |
3532 | esac | |
3533 | fi | |
3534 | ||
4708ac65 | 3535 | echo $ac_n "checking for gregset_t type""... $ac_c" 1>&6 |
e3009a74 | 3536 | echo "configure:3537: checking for gregset_t type" >&5 |
07b77f5c | 3537 | if eval "test \"`echo '$''{'gdb_cv_have_gregset_t'+set}'`\" = set"; then |
4708ac65 FF |
3538 | echo $ac_n "(cached) $ac_c" 1>&6 |
3539 | else | |
3540 | cat > conftest.$ac_ext <<EOF | |
e3009a74 | 3541 | #line 3542 "configure" |
4708ac65 FF |
3542 | #include "confdefs.h" |
3543 | #include <sys/procfs.h> | |
bfde4a67 | 3544 | int main() { |
4708ac65 FF |
3545 | gregset_t *gregsetp = 0 |
3546 | ; return 0; } | |
3547 | EOF | |
e3009a74 | 3548 | if { (eval echo configure:3549: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
4708ac65 | 3549 | rm -rf conftest* |
07b77f5c | 3550 | gdb_cv_have_gregset_t=yes |
4708ac65 | 3551 | else |
bfde4a67 SG |
3552 | echo "configure: failed program was:" >&5 |
3553 | cat conftest.$ac_ext >&5 | |
4708ac65 | 3554 | rm -rf conftest* |
07b77f5c | 3555 | gdb_cv_have_gregset_t=no |
4708ac65 FF |
3556 | fi |
3557 | rm -f conftest* | |
4708ac65 FF |
3558 | fi |
3559 | ||
07b77f5c FF |
3560 | echo "$ac_t""$gdb_cv_have_gregset_t" 1>&6 |
3561 | if test $gdb_cv_have_gregset_t = yes; then | |
4708ac65 FF |
3562 | cat >> confdefs.h <<\EOF |
3563 | #define HAVE_GREGSET_T 1 | |
3564 | EOF | |
3565 | ||
3566 | fi | |
3567 | ||
3568 | echo $ac_n "checking for fpregset_t type""... $ac_c" 1>&6 | |
e3009a74 | 3569 | echo "configure:3570: checking for fpregset_t type" >&5 |
07b77f5c | 3570 | if eval "test \"`echo '$''{'gdb_cv_have_fpregset_t'+set}'`\" = set"; then |
4708ac65 FF |
3571 | echo $ac_n "(cached) $ac_c" 1>&6 |
3572 | else | |
3573 | cat > conftest.$ac_ext <<EOF | |
e3009a74 | 3574 | #line 3575 "configure" |
4708ac65 FF |
3575 | #include "confdefs.h" |
3576 | #include <sys/procfs.h> | |
bfde4a67 | 3577 | int main() { |
4708ac65 FF |
3578 | fpregset_t *fpregsetp = 0 |
3579 | ; return 0; } | |
3580 | EOF | |
e3009a74 | 3581 | if { (eval echo configure:3582: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
4708ac65 | 3582 | rm -rf conftest* |
07b77f5c | 3583 | gdb_cv_have_fpregset_t=yes |
4708ac65 | 3584 | else |
bfde4a67 SG |
3585 | echo "configure: failed program was:" >&5 |
3586 | cat conftest.$ac_ext >&5 | |
4708ac65 | 3587 | rm -rf conftest* |
07b77f5c | 3588 | gdb_cv_have_fpregset_t=no |
4708ac65 FF |
3589 | fi |
3590 | rm -f conftest* | |
4708ac65 FF |
3591 | fi |
3592 | ||
07b77f5c FF |
3593 | echo "$ac_t""$gdb_cv_have_fpregset_t" 1>&6 |
3594 | if test $gdb_cv_have_fpregset_t = yes; then | |
4708ac65 FF |
3595 | cat >> confdefs.h <<\EOF |
3596 | #define HAVE_FPREGSET_T 1 | |
3597 | EOF | |
3598 | ||
3599 | fi | |
3600 | ||
bfde4a67 | 3601 | echo $ac_n "checking for main in -lm""... $ac_c" 1>&6 |
e3009a74 | 3602 | echo "configure:3603: checking for main in -lm" >&5 |
bfde4a67 | 3603 | ac_lib_var=`echo m'_'main | sed 'y%./+-%__p_%'` |
ef6c51d1 SG |
3604 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
3605 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3606 | else | |
3607 | ac_save_LIBS="$LIBS" | |
3608 | LIBS="-lm $LIBS" | |
3609 | cat > conftest.$ac_ext <<EOF | |
e3009a74 | 3610 | #line 3611 "configure" |
ef6c51d1 SG |
3611 | #include "confdefs.h" |
3612 | ||
bfde4a67 | 3613 | int main() { |
ef6c51d1 SG |
3614 | main() |
3615 | ; return 0; } | |
3616 | EOF | |
e3009a74 | 3617 | if { (eval echo configure:3618: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
ef6c51d1 SG |
3618 | rm -rf conftest* |
3619 | eval "ac_cv_lib_$ac_lib_var=yes" | |
3620 | else | |
bfde4a67 SG |
3621 | echo "configure: failed program was:" >&5 |
3622 | cat conftest.$ac_ext >&5 | |
ef6c51d1 SG |
3623 | rm -rf conftest* |
3624 | eval "ac_cv_lib_$ac_lib_var=no" | |
3625 | fi | |
3626 | rm -f conftest* | |
3627 | LIBS="$ac_save_LIBS" | |
3628 | ||
3629 | fi | |
3630 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then | |
3631 | echo "$ac_t""yes" 1>&6 | |
bfde4a67 SG |
3632 | ac_tr_lib=HAVE_LIB`echo m | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
3633 | -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` | |
ef6c51d1 SG |
3634 | cat >> confdefs.h <<EOF |
3635 | #define $ac_tr_lib 1 | |
3636 | EOF | |
3637 | ||
3638 | LIBS="-lm $LIBS" | |
3639 | ||
3640 | else | |
3641 | echo "$ac_t""no" 1>&6 | |
3642 | fi | |
3643 | ||
3644 | ||
aa220473 | 3645 | |
3f550b59 | 3646 | echo $ac_n "checking for long long support in compiler""... $ac_c" 1>&6 |
e3009a74 | 3647 | echo "configure:3648: checking for long long support in compiler" >&5 |
3f550b59 FF |
3648 | if eval "test \"`echo '$''{'gdb_cv_c_long_long'+set}'`\" = set"; then |
3649 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3650 | else | |
3651 | cat > conftest.$ac_ext <<EOF | |
e3009a74 | 3652 | #line 3653 "configure" |
3f550b59 FF |
3653 | #include "confdefs.h" |
3654 | ||
bfde4a67 | 3655 | int main() { |
80f600a4 | 3656 | |
d538f9cf FF |
3657 | extern long long foo; |
3658 | switch (foo & 2) { case 0: return 1; } | |
3659 | ||
3f550b59 FF |
3660 | ; return 0; } |
3661 | EOF | |
e3009a74 | 3662 | if { (eval echo configure:3663: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
3f550b59 FF |
3663 | rm -rf conftest* |
3664 | gdb_cv_c_long_long=yes | |
3665 | else | |
bfde4a67 SG |
3666 | echo "configure: failed program was:" >&5 |
3667 | cat conftest.$ac_ext >&5 | |
3f550b59 FF |
3668 | rm -rf conftest* |
3669 | gdb_cv_c_long_long=no | |
3670 | fi | |
3671 | rm -f conftest* | |
3f550b59 FF |
3672 | fi |
3673 | ||
3674 | echo "$ac_t""$gdb_cv_c_long_long" 1>&6 | |
3675 | if test $gdb_cv_c_long_long = yes; then | |
3676 | cat >> confdefs.h <<\EOF | |
3677 | #define CC_HAS_LONG_LONG 1 | |
3678 | EOF | |
3679 | ||
3680 | fi | |
3681 | ||
3682 | ||
3683 | echo $ac_n "checking for long long support in printf""... $ac_c" 1>&6 | |
e3009a74 | 3684 | echo "configure:3685: checking for long long support in printf" >&5 |
3f550b59 FF |
3685 | if eval "test \"`echo '$''{'gdb_cv_printf_has_long_long'+set}'`\" = set"; then |
3686 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3687 | else | |
3688 | if test "$cross_compiling" = yes; then | |
3689 | gdb_cv_printf_has_long_long=no | |
3690 | else | |
bfde4a67 | 3691 | cat > conftest.$ac_ext <<EOF |
e3009a74 | 3692 | #line 3693 "configure" |
3f550b59 FF |
3693 | #include "confdefs.h" |
3694 | ||
3695 | int main () { | |
f7b8c9ce AC |
3696 | char buf[32]; |
3697 | long long l = 0; | |
3698 | l = (l << 16) + 0x0123; | |
3699 | l = (l << 16) + 0x4567; | |
3700 | l = (l << 16) + 0x89ab; | |
3701 | l = (l << 16) + 0xcdef; | |
3702 | sprintf (buf, "0x%016llx", l); | |
3703 | return (strcmp ("0x0123456789abcdef", buf)); | |
3f550b59 FF |
3704 | } |
3705 | EOF | |
e3009a74 | 3706 | if { (eval echo configure:3707: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null |
bfde4a67 | 3707 | then |
3f550b59 FF |
3708 | gdb_cv_printf_has_long_long=yes |
3709 | else | |
bfde4a67 SG |
3710 | echo "configure: failed program was:" >&5 |
3711 | cat conftest.$ac_ext >&5 | |
3712 | rm -fr conftest* | |
3f550b59 FF |
3713 | gdb_cv_printf_has_long_long=no |
3714 | fi | |
ef6c51d1 | 3715 | rm -fr conftest* |
8b701284 ILT |
3716 | fi |
3717 | ||
bfde4a67 SG |
3718 | fi |
3719 | ||
3f550b59 FF |
3720 | if test $gdb_cv_printf_has_long_long = yes; then |
3721 | cat >> confdefs.h <<\EOF | |
3722 | #define PRINTF_HAS_LONG_LONG 1 | |
3723 | EOF | |
3724 | ||
3725 | fi | |
3726 | echo "$ac_t""$gdb_cv_printf_has_long_long" 1>&6 | |
3727 | ||
3728 | ||
07b77f5c | 3729 | echo $ac_n "checking for long double support in compiler""... $ac_c" 1>&6 |
e3009a74 | 3730 | echo "configure:3731: checking for long double support in compiler" >&5 |
aa220473 SG |
3731 | if eval "test \"`echo '$''{'ac_cv_c_long_double'+set}'`\" = set"; then |
3732 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3733 | else | |
3734 | cat > conftest.$ac_ext <<EOF | |
e3009a74 | 3735 | #line 3736 "configure" |
aa220473 SG |
3736 | #include "confdefs.h" |
3737 | ||
bfde4a67 | 3738 | int main() { |
aa220473 SG |
3739 | long double foo; |
3740 | ; return 0; } | |
3741 | EOF | |
e3009a74 | 3742 | if { (eval echo configure:3743: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
aa220473 SG |
3743 | rm -rf conftest* |
3744 | ac_cv_c_long_double=yes | |
3745 | else | |
bfde4a67 SG |
3746 | echo "configure: failed program was:" >&5 |
3747 | cat conftest.$ac_ext >&5 | |
aa220473 SG |
3748 | rm -rf conftest* |
3749 | ac_cv_c_long_double=no | |
3750 | fi | |
3751 | rm -f conftest* | |
aa220473 SG |
3752 | fi |
3753 | ||
3754 | echo "$ac_t""$ac_cv_c_long_double" 1>&6 | |
3755 | if test $ac_cv_c_long_double = yes; then | |
3756 | cat >> confdefs.h <<\EOF | |
3757 | #define HAVE_LONG_DOUBLE 1 | |
3758 | EOF | |
3759 | ||
3760 | fi | |
3761 | ||
07b77f5c FF |
3762 | |
3763 | echo $ac_n "checking for long double support in printf""... $ac_c" 1>&6 | |
e3009a74 | 3764 | echo "configure:3765: checking for long double support in printf" >&5 |
07b77f5c FF |
3765 | if eval "test \"`echo '$''{'gdb_cv_printf_has_long_double'+set}'`\" = set"; then |
3766 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3767 | else | |
3768 | if test "$cross_compiling" = yes; then | |
3769 | gdb_cv_printf_has_long_double=no | |
3770 | else | |
bfde4a67 | 3771 | cat > conftest.$ac_ext <<EOF |
e3009a74 | 3772 | #line 3773 "configure" |
07b77f5c FF |
3773 | #include "confdefs.h" |
3774 | ||
3775 | int main () { | |
3776 | char buf[16]; | |
3777 | long double f = 3.141592653; | |
3778 | sprintf (buf, "%Lg", f); | |
3779 | return (strncmp ("3.14159", buf, 7)); | |
3780 | } | |
3781 | EOF | |
e3009a74 | 3782 | if { (eval echo configure:3783: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null |
bfde4a67 | 3783 | then |
07b77f5c FF |
3784 | gdb_cv_printf_has_long_double=yes |
3785 | else | |
bfde4a67 SG |
3786 | echo "configure: failed program was:" >&5 |
3787 | cat conftest.$ac_ext >&5 | |
3788 | rm -fr conftest* | |
07b77f5c FF |
3789 | gdb_cv_printf_has_long_double=no |
3790 | fi | |
ef6c51d1 | 3791 | rm -fr conftest* |
8b701284 ILT |
3792 | fi |
3793 | ||
bfde4a67 SG |
3794 | fi |
3795 | ||
07b77f5c FF |
3796 | if test $gdb_cv_printf_has_long_double = yes; then |
3797 | cat >> confdefs.h <<\EOF | |
3798 | #define PRINTF_HAS_LONG_DOUBLE 1 | |
3799 | EOF | |
3800 | ||
3801 | fi | |
3802 | echo "$ac_t""$gdb_cv_printf_has_long_double" 1>&6 | |
3803 | ||
f7b8c9ce AC |
3804 | |
3805 | echo $ac_n "checking for long double support in scanf""... $ac_c" 1>&6 | |
e3009a74 | 3806 | echo "configure:3807: checking for long double support in scanf" >&5 |
f7b8c9ce AC |
3807 | if eval "test \"`echo '$''{'gdb_cv_scanf_has_long_double'+set}'`\" = set"; then |
3808 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3809 | else | |
3810 | if test "$cross_compiling" = yes; then | |
3811 | gdb_cv_scanf_has_long_double=no | |
3812 | else | |
3813 | cat > conftest.$ac_ext <<EOF | |
e3009a74 | 3814 | #line 3815 "configure" |
f7b8c9ce AC |
3815 | #include "confdefs.h" |
3816 | ||
3817 | int main () { | |
3818 | char *buf = "3.141592653"; | |
3819 | long double f = 0; | |
3820 | sscanf (buf, "%Lg", &f); | |
3821 | return !(f > 3.14159 && f < 3.14160); | |
3822 | } | |
3823 | EOF | |
e3009a74 | 3824 | if { (eval echo configure:3825: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null |
f7b8c9ce AC |
3825 | then |
3826 | gdb_cv_scanf_has_long_double=yes | |
3827 | else | |
3828 | echo "configure: failed program was:" >&5 | |
3829 | cat conftest.$ac_ext >&5 | |
3830 | rm -fr conftest* | |
3831 | gdb_cv_scanf_has_long_double=no | |
3832 | fi | |
3833 | rm -fr conftest* | |
3834 | fi | |
3835 | ||
3836 | fi | |
3837 | ||
3838 | if test $gdb_cv_scanf_has_long_double = yes; then | |
3839 | cat >> confdefs.h <<\EOF | |
3840 | #define SCANF_HAS_LONG_DOUBLE 1 | |
3841 | EOF | |
3842 | ||
3843 | fi | |
3844 | echo "$ac_t""$gdb_cv_scanf_has_long_double" 1>&6 | |
3845 | ||
bfde4a67 SG |
3846 | for ac_hdr in unistd.h |
3847 | do | |
3848 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` | |
3849 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 | |
e3009a74 | 3850 | echo "configure:3851: checking for $ac_hdr" >&5 |
bfde4a67 SG |
3851 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
3852 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3853 | else | |
3854 | cat > conftest.$ac_ext <<EOF | |
e3009a74 | 3855 | #line 3856 "configure" |
bfde4a67 SG |
3856 | #include "confdefs.h" |
3857 | #include <$ac_hdr> | |
3858 | EOF | |
3859 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
e3009a74 | 3860 | { (eval echo configure:3861: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
ba68ad57 | 3861 | ac_err=`grep -v '^ *+' conftest.out` |
bfde4a67 SG |
3862 | if test -z "$ac_err"; then |
3863 | rm -rf conftest* | |
3864 | eval "ac_cv_header_$ac_safe=yes" | |
3865 | else | |
3866 | echo "$ac_err" >&5 | |
3867 | echo "configure: failed program was:" >&5 | |
3868 | cat conftest.$ac_ext >&5 | |
3869 | rm -rf conftest* | |
3870 | eval "ac_cv_header_$ac_safe=no" | |
3871 | fi | |
3872 | rm -f conftest* | |
3873 | fi | |
3874 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | |
3875 | echo "$ac_t""yes" 1>&6 | |
3876 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` | |
3877 | cat >> confdefs.h <<EOF | |
3878 | #define $ac_tr_hdr 1 | |
3879 | EOF | |
3880 | ||
3881 | else | |
3882 | echo "$ac_t""no" 1>&6 | |
3883 | fi | |
3884 | done | |
3885 | ||
3886 | for ac_func in getpagesize | |
1a7b4b7c DE |
3887 | do |
3888 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
e3009a74 | 3889 | echo "configure:3890: checking for $ac_func" >&5 |
1a7b4b7c DE |
3890 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
3891 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3892 | else | |
3893 | cat > conftest.$ac_ext <<EOF | |
e3009a74 | 3894 | #line 3895 "configure" |
1a7b4b7c DE |
3895 | #include "confdefs.h" |
3896 | /* System header to define __stub macros and hopefully few prototypes, | |
3897 | which can conflict with char $ac_func(); below. */ | |
3898 | #include <assert.h> | |
3899 | /* Override any gcc2 internal prototype to avoid an error. */ | |
bc859e63 SG |
3900 | /* We use char because int might match the return type of a gcc2 |
3901 | builtin and then its argument prototype would still apply. */ | |
1a7b4b7c DE |
3902 | char $ac_func(); |
3903 | ||
bfde4a67 | 3904 | int main() { |
1a7b4b7c DE |
3905 | |
3906 | /* The GNU C library defines this for functions which it implements | |
3907 | to always fail with ENOSYS. Some functions are actually named | |
3908 | something starting with __ and the normal name is an alias. */ | |
3909 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
3910 | choke me | |
3911 | #else | |
3912 | $ac_func(); | |
3913 | #endif | |
3914 | ||
3915 | ; return 0; } | |
3916 | EOF | |
e3009a74 | 3917 | if { (eval echo configure:3918: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
1a7b4b7c DE |
3918 | rm -rf conftest* |
3919 | eval "ac_cv_func_$ac_func=yes" | |
3920 | else | |
bfde4a67 SG |
3921 | echo "configure: failed program was:" >&5 |
3922 | cat conftest.$ac_ext >&5 | |
1a7b4b7c DE |
3923 | rm -rf conftest* |
3924 | eval "ac_cv_func_$ac_func=no" | |
3925 | fi | |
3926 | rm -f conftest* | |
ef6c51d1 | 3927 | fi |
bfde4a67 | 3928 | |
1a7b4b7c DE |
3929 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
3930 | echo "$ac_t""yes" 1>&6 | |
3931 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
3932 | cat >> confdefs.h <<EOF | |
3933 | #define $ac_tr_func 1 | |
3934 | EOF | |
3935 | ||
3936 | else | |
3937 | echo "$ac_t""no" 1>&6 | |
3938 | fi | |
3939 | done | |
3940 | ||
2b576293 | 3941 | echo $ac_n "checking for working mmap""... $ac_c" 1>&6 |
e3009a74 | 3942 | echo "configure:3943: checking for working mmap" >&5 |
bfde4a67 | 3943 | if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then |
2b576293 C |
3944 | echo $ac_n "(cached) $ac_c" 1>&6 |
3945 | else | |
3946 | if test "$cross_compiling" = yes; then | |
bfde4a67 | 3947 | ac_cv_func_mmap_fixed_mapped=no |
2b576293 | 3948 | else |
bfde4a67 | 3949 | cat > conftest.$ac_ext <<EOF |
e3009a74 | 3950 | #line 3951 "configure" |
2b576293 C |
3951 | #include "confdefs.h" |
3952 | ||
bfde4a67 SG |
3953 | /* Thanks to Mike Haertel and Jim Avera for this test. |
3954 | Here is a matrix of mmap possibilities: | |
3955 | mmap private not fixed | |
3956 | mmap private fixed at somewhere currently unmapped | |
3957 | mmap private fixed at somewhere already mapped | |
3958 | mmap shared not fixed | |
3959 | mmap shared fixed at somewhere currently unmapped | |
3960 | mmap shared fixed at somewhere already mapped | |
3961 | For private mappings, we should verify that changes cannot be read() | |
3962 | back from the file, nor mmap's back from the file at a different | |
3963 | address. (There have been systems where private was not correctly | |
3964 | implemented like the infamous i386 svr4.0, and systems where the | |
3965 | VM page cache was not coherent with the filesystem buffer cache | |
3966 | like early versions of FreeBSD and possibly contemporary NetBSD.) | |
3967 | For shared mappings, we should conversely verify that changes get | |
3968 | propogated back to all the places they're supposed to be. | |
3969 | ||
3970 | Grep wants private fixed already mapped. | |
3971 | The main things grep needs to know about mmap are: | |
3972 | * does it exist and is it safe to write into the mmap'd area | |
3973 | * how to use it (BSD variants) */ | |
2b576293 C |
3974 | #include <sys/types.h> |
3975 | #include <fcntl.h> | |
3976 | #include <sys/mman.h> | |
3977 | ||
bfde4a67 | 3978 | /* This mess was copied from the GNU getpagesize.h. */ |
2b576293 | 3979 | #ifndef HAVE_GETPAGESIZE |
bfde4a67 SG |
3980 | # ifdef HAVE_UNISTD_H |
3981 | # include <unistd.h> | |
8b701284 ILT |
3982 | # endif |
3983 | ||
bfde4a67 SG |
3984 | /* Assume that all systems that can run configure have sys/param.h. */ |
3985 | # ifndef HAVE_SYS_PARAM_H | |
3986 | # define HAVE_SYS_PARAM_H 1 | |
3987 | # endif | |
3988 | ||
3989 | # ifdef _SC_PAGESIZE | |
3990 | # define getpagesize() sysconf(_SC_PAGESIZE) | |
3991 | # else /* no _SC_PAGESIZE */ | |
3992 | # ifdef HAVE_SYS_PARAM_H | |
3993 | # include <sys/param.h> | |
3994 | # ifdef EXEC_PAGESIZE | |
3995 | # define getpagesize() EXEC_PAGESIZE | |
3996 | # else /* no EXEC_PAGESIZE */ | |
3997 | # ifdef NBPG | |
3998 | # define getpagesize() NBPG * CLSIZE | |
3999 | # ifndef CLSIZE | |
4000 | # define CLSIZE 1 | |
4001 | # endif /* no CLSIZE */ | |
4002 | # else /* no NBPG */ | |
4003 | # ifdef NBPC | |
4004 | # define getpagesize() NBPC | |
4005 | # else /* no NBPC */ | |
4006 | # ifdef PAGESIZE | |
4007 | # define getpagesize() PAGESIZE | |
4008 | # endif /* PAGESIZE */ | |
4009 | # endif /* no NBPC */ | |
4010 | # endif /* no NBPG */ | |
4011 | # endif /* no EXEC_PAGESIZE */ | |
4012 | # else /* no HAVE_SYS_PARAM_H */ | |
4013 | # define getpagesize() 8192 /* punt totally */ | |
4014 | # endif /* no HAVE_SYS_PARAM_H */ | |
4015 | # endif /* no _SC_PAGESIZE */ | |
4016 | ||
4017 | #endif /* no HAVE_GETPAGESIZE */ | |
2b576293 C |
4018 | |
4019 | #ifdef __cplusplus | |
bfde4a67 | 4020 | extern "C" { void *malloc(unsigned); } |
2b576293 | 4021 | #else |
bfde4a67 | 4022 | char *malloc(); |
2b576293 C |
4023 | #endif |
4024 | ||
4025 | int | |
4026 | main() | |
4027 | { | |
bfde4a67 SG |
4028 | char *data, *data2, *data3; |
4029 | int i, pagesize; | |
4030 | int fd; | |
4031 | ||
4032 | pagesize = getpagesize(); | |
4033 | ||
4034 | /* | |
4035 | * First, make a file with some known garbage in it. | |
4036 | */ | |
4037 | data = malloc(pagesize); | |
4038 | if (!data) | |
4039 | exit(1); | |
4040 | for (i = 0; i < pagesize; ++i) | |
4041 | *(data + i) = rand(); | |
4042 | umask(0); | |
4043 | fd = creat("conftestmmap", 0600); | |
4044 | if (fd < 0) | |
4045 | exit(1); | |
4046 | if (write(fd, data, pagesize) != pagesize) | |
4047 | exit(1); | |
4048 | close(fd); | |
4049 | ||
4050 | /* | |
4051 | * Next, try to mmap the file at a fixed address which | |
4052 | * already has something else allocated at it. If we can, | |
4053 | * also make sure that we see the same garbage. | |
4054 | */ | |
4055 | fd = open("conftestmmap", O_RDWR); | |
4056 | if (fd < 0) | |
4057 | exit(1); | |
4058 | data2 = malloc(2 * pagesize); | |
4059 | if (!data2) | |
4060 | exit(1); | |
4061 | data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1); | |
4062 | if (data2 != mmap(data2, pagesize, PROT_READ | PROT_WRITE, | |
4063 | MAP_PRIVATE | MAP_FIXED, fd, 0L)) | |
4064 | exit(1); | |
4065 | for (i = 0; i < pagesize; ++i) | |
4066 | if (*(data + i) != *(data2 + i)) | |
4067 | exit(1); | |
4068 | ||
4069 | /* | |
4070 | * Finally, make sure that changes to the mapped area | |
4071 | * do not percolate back to the file as seen by read(). | |
4072 | * (This is a bug on some variants of i386 svr4.0.) | |
4073 | */ | |
4074 | for (i = 0; i < pagesize; ++i) | |
4075 | *(data2 + i) = *(data2 + i) + 1; | |
4076 | data3 = malloc(pagesize); | |
4077 | if (!data3) | |
4078 | exit(1); | |
4079 | if (read(fd, data3, pagesize) != pagesize) | |
4080 | exit(1); | |
4081 | for (i = 0; i < pagesize; ++i) | |
4082 | if (*(data + i) != *(data3 + i)) | |
4083 | exit(1); | |
4084 | close(fd); | |
4085 | unlink("conftestmmap"); | |
4086 | exit(0); | |
2b576293 C |
4087 | } |
4088 | ||
4089 | EOF | |
e3009a74 | 4090 | if { (eval echo configure:4091: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null |
bfde4a67 SG |
4091 | then |
4092 | ac_cv_func_mmap_fixed_mapped=yes | |
2b576293 | 4093 | else |
bfde4a67 SG |
4094 | echo "configure: failed program was:" >&5 |
4095 | cat conftest.$ac_ext >&5 | |
4096 | rm -fr conftest* | |
4097 | ac_cv_func_mmap_fixed_mapped=no | |
2b576293 | 4098 | fi |
ef6c51d1 | 4099 | rm -fr conftest* |
8b701284 ILT |
4100 | fi |
4101 | ||
bfde4a67 SG |
4102 | fi |
4103 | ||
4104 | echo "$ac_t""$ac_cv_func_mmap_fixed_mapped" 1>&6 | |
4105 | if test $ac_cv_func_mmap_fixed_mapped = yes; then | |
2b576293 C |
4106 | cat >> confdefs.h <<\EOF |
4107 | #define HAVE_MMAP 1 | |
4108 | EOF | |
4109 | ||
4110 | fi | |
4111 | ||
5436fc65 | 4112 | |
5819f35d | 4113 | echo $ac_n "checking whether malloc must be declared""... $ac_c" 1>&6 |
e3009a74 | 4114 | echo "configure:4115: checking whether malloc must be declared" >&5 |
5819f35d SG |
4115 | if eval "test \"`echo '$''{'bfd_cv_decl_needed_malloc'+set}'`\" = set"; then |
4116 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4117 | else | |
4118 | cat > conftest.$ac_ext <<EOF | |
e3009a74 | 4119 | #line 4120 "configure" |
5819f35d SG |
4120 | #include "confdefs.h" |
4121 | ||
4122 | #include <stdio.h> | |
4123 | #ifdef HAVE_STRING_H | |
4124 | #include <string.h> | |
4125 | #else | |
4126 | #ifdef HAVE_STRINGS_H | |
4127 | #include <strings.h> | |
4128 | #endif | |
4129 | #endif | |
4130 | #ifdef HAVE_STDLIB_H | |
4131 | #include <stdlib.h> | |
4132 | #endif | |
4133 | #ifdef HAVE_UNISTD_H | |
4134 | #include <unistd.h> | |
4135 | #endif | |
bfde4a67 | 4136 | int main() { |
5819f35d SG |
4137 | char *(*pfn) = (char *(*)) malloc |
4138 | ; return 0; } | |
4139 | EOF | |
e3009a74 | 4140 | if { (eval echo configure:4141: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
5819f35d SG |
4141 | rm -rf conftest* |
4142 | bfd_cv_decl_needed_malloc=no | |
4143 | else | |
bfde4a67 SG |
4144 | echo "configure: failed program was:" >&5 |
4145 | cat conftest.$ac_ext >&5 | |
5819f35d SG |
4146 | rm -rf conftest* |
4147 | bfd_cv_decl_needed_malloc=yes | |
4148 | fi | |
4149 | rm -f conftest* | |
5819f35d SG |
4150 | fi |
4151 | ||
4152 | echo "$ac_t""$bfd_cv_decl_needed_malloc" 1>&6 | |
4153 | if test $bfd_cv_decl_needed_malloc = yes; then | |
4154 | bfd_tr_decl=NEED_DECLARATION_`echo malloc | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
4155 | cat >> confdefs.h <<EOF | |
4156 | #define $bfd_tr_decl 1 | |
4157 | EOF | |
4158 | ||
4159 | fi | |
4160 | ||
4161 | echo $ac_n "checking whether realloc must be declared""... $ac_c" 1>&6 | |
e3009a74 | 4162 | echo "configure:4163: checking whether realloc must be declared" >&5 |
5819f35d SG |
4163 | if eval "test \"`echo '$''{'bfd_cv_decl_needed_realloc'+set}'`\" = set"; then |
4164 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4165 | else | |
4166 | cat > conftest.$ac_ext <<EOF | |
e3009a74 | 4167 | #line 4168 "configure" |
5819f35d SG |
4168 | #include "confdefs.h" |
4169 | ||
4170 | #include <stdio.h> | |
4171 | #ifdef HAVE_STRING_H | |
4172 | #include <string.h> | |
4173 | #else | |
4174 | #ifdef HAVE_STRINGS_H | |
4175 | #include <strings.h> | |
4176 | #endif | |
4177 | #endif | |
4178 | #ifdef HAVE_STDLIB_H | |
4179 | #include <stdlib.h> | |
4180 | #endif | |
4181 | #ifdef HAVE_UNISTD_H | |
4182 | #include <unistd.h> | |
4183 | #endif | |
bfde4a67 | 4184 | int main() { |
5819f35d SG |
4185 | char *(*pfn) = (char *(*)) realloc |
4186 | ; return 0; } | |
4187 | EOF | |
e3009a74 | 4188 | if { (eval echo configure:4189: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
5819f35d SG |
4189 | rm -rf conftest* |
4190 | bfd_cv_decl_needed_realloc=no | |
4191 | else | |
bfde4a67 SG |
4192 | echo "configure: failed program was:" >&5 |
4193 | cat conftest.$ac_ext >&5 | |
5819f35d SG |
4194 | rm -rf conftest* |
4195 | bfd_cv_decl_needed_realloc=yes | |
4196 | fi | |
4197 | rm -f conftest* | |
5819f35d SG |
4198 | fi |
4199 | ||
4200 | echo "$ac_t""$bfd_cv_decl_needed_realloc" 1>&6 | |
4201 | if test $bfd_cv_decl_needed_realloc = yes; then | |
4202 | bfd_tr_decl=NEED_DECLARATION_`echo realloc | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
4203 | cat >> confdefs.h <<EOF | |
4204 | #define $bfd_tr_decl 1 | |
4205 | EOF | |
4206 | ||
4207 | fi | |
4208 | ||
4209 | echo $ac_n "checking whether free must be declared""... $ac_c" 1>&6 | |
e3009a74 | 4210 | echo "configure:4211: checking whether free must be declared" >&5 |
5819f35d SG |
4211 | if eval "test \"`echo '$''{'bfd_cv_decl_needed_free'+set}'`\" = set"; then |
4212 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4213 | else | |
4214 | cat > conftest.$ac_ext <<EOF | |
e3009a74 | 4215 | #line 4216 "configure" |
5819f35d SG |
4216 | #include "confdefs.h" |
4217 | ||
4218 | #include <stdio.h> | |
4219 | #ifdef HAVE_STRING_H | |
4220 | #include <string.h> | |
4221 | #else | |
4222 | #ifdef HAVE_STRINGS_H | |
4223 | #include <strings.h> | |
4224 | #endif | |
4225 | #endif | |
4226 | #ifdef HAVE_STDLIB_H | |
4227 | #include <stdlib.h> | |
4228 | #endif | |
4229 | #ifdef HAVE_UNISTD_H | |
4230 | #include <unistd.h> | |
4231 | #endif | |
bfde4a67 | 4232 | int main() { |
5819f35d SG |
4233 | char *(*pfn) = (char *(*)) free |
4234 | ; return 0; } | |
4235 | EOF | |
e3009a74 | 4236 | if { (eval echo configure:4237: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
5819f35d SG |
4237 | rm -rf conftest* |
4238 | bfd_cv_decl_needed_free=no | |
4239 | else | |
bfde4a67 SG |
4240 | echo "configure: failed program was:" >&5 |
4241 | cat conftest.$ac_ext >&5 | |
5819f35d SG |
4242 | rm -rf conftest* |
4243 | bfd_cv_decl_needed_free=yes | |
4244 | fi | |
4245 | rm -f conftest* | |
5819f35d SG |
4246 | fi |
4247 | ||
4248 | echo "$ac_t""$bfd_cv_decl_needed_free" 1>&6 | |
4249 | if test $bfd_cv_decl_needed_free = yes; then | |
4250 | bfd_tr_decl=NEED_DECLARATION_`echo free | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
4251 | cat >> confdefs.h <<EOF | |
4252 | #define $bfd_tr_decl 1 | |
4253 | EOF | |
4254 | ||
4255 | fi | |
4256 | ||
fef1696f | 4257 | |
21cbc60c | 4258 | echo $ac_n "checking whether strerror must be declared""... $ac_c" 1>&6 |
e3009a74 | 4259 | echo "configure:4260: checking whether strerror must be declared" >&5 |
21cbc60c JM |
4260 | if eval "test \"`echo '$''{'bfd_cv_decl_needed_strerror'+set}'`\" = set"; then |
4261 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4262 | else | |
4263 | cat > conftest.$ac_ext <<EOF | |
e3009a74 | 4264 | #line 4265 "configure" |
21cbc60c JM |
4265 | #include "confdefs.h" |
4266 | ||
4267 | #include <stdio.h> | |
4268 | #ifdef HAVE_STRING_H | |
4269 | #include <string.h> | |
4270 | #else | |
4271 | #ifdef HAVE_STRINGS_H | |
4272 | #include <strings.h> | |
4273 | #endif | |
4274 | #endif | |
4275 | #ifdef HAVE_STDLIB_H | |
4276 | #include <stdlib.h> | |
4277 | #endif | |
4278 | #ifdef HAVE_UNISTD_H | |
4279 | #include <unistd.h> | |
4280 | #endif | |
4281 | int main() { | |
4282 | char *(*pfn) = (char *(*)) strerror | |
4283 | ; return 0; } | |
4284 | EOF | |
e3009a74 | 4285 | if { (eval echo configure:4286: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
21cbc60c JM |
4286 | rm -rf conftest* |
4287 | bfd_cv_decl_needed_strerror=no | |
4288 | else | |
4289 | echo "configure: failed program was:" >&5 | |
4290 | cat conftest.$ac_ext >&5 | |
4291 | rm -rf conftest* | |
4292 | bfd_cv_decl_needed_strerror=yes | |
4293 | fi | |
4294 | rm -f conftest* | |
4295 | fi | |
4296 | ||
4297 | echo "$ac_t""$bfd_cv_decl_needed_strerror" 1>&6 | |
4298 | if test $bfd_cv_decl_needed_strerror = yes; then | |
4299 | bfd_tr_decl=NEED_DECLARATION_`echo strerror | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
4300 | cat >> confdefs.h <<EOF | |
4301 | #define $bfd_tr_decl 1 | |
4302 | EOF | |
4303 | ||
4304 | fi | |
4305 | ||
4306 | ||
47ef0da5 | 4307 | |
89e673a4 SG |
4308 | |
4309 | if test ${build} = ${host} -a ${host} = ${target} ; then | |
4b95e9a1 JM |
4310 | case ${host_os} in |
4311 | hpux*) | |
4312 | echo $ac_n "checking for HPUX/OSF thread support""... $ac_c" 1>&6 | |
e3009a74 | 4313 | echo "configure:4314: checking for HPUX/OSF thread support" >&5 |
4b95e9a1 JM |
4314 | if test -f /usr/include/dce/cma_config.h ; then |
4315 | if test "$GCC" = "yes" ; then | |
4316 | echo "$ac_t""yes" 1>&6 | |
4317 | cat >> confdefs.h <<\EOF | |
5d394f70 SG |
4318 | #define HAVE_HPUX_THREAD_SUPPORT 1 |
4319 | EOF | |
4320 | ||
4b95e9a1 | 4321 | CONFIG_OBS="${CONFIG_OJS} hpux-thread.o" |
c7bb1531 | 4322 | CONFIG_SRCS="${CONFIG_SRCS} hpux-thread.c" |
4b95e9a1 JM |
4323 | else |
4324 | echo "$ac_t""no (suppressed because you are not using GCC)" 1>&6 | |
4325 | fi | |
4326 | else | |
4327 | echo "$ac_t""no" 1>&6 | |
4328 | fi | |
4329 | ;; | |
4330 | solaris*) | |
4331 | echo $ac_n "checking for Solaris thread debugging library""... $ac_c" 1>&6 | |
e3009a74 | 4332 | echo "configure:4333: checking for Solaris thread debugging library" >&5 |
4b95e9a1 JM |
4333 | if test -f /usr/lib/libthread_db.so.1 ; then |
4334 | echo "$ac_t""yes" 1>&6 | |
4335 | cat >> confdefs.h <<\EOF | |
6c310da8 SG |
4336 | #define HAVE_THREAD_DB_LIB 1 |
4337 | EOF | |
4338 | ||
4b95e9a1 | 4339 | CONFIG_OBS="${CONFIG_OBS} sol-thread.o" |
c7bb1531 | 4340 | CONFIG_SRCS="${CONFIG_SRCS} sol-thread.c" |
4b95e9a1 | 4341 | echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6 |
e3009a74 | 4342 | echo "configure:4343: checking for dlopen in -ldl" >&5 |
bfde4a67 | 4343 | ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'` |
95b47547 SG |
4344 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
4345 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4346 | else | |
4347 | ac_save_LIBS="$LIBS" | |
4348 | LIBS="-ldl $LIBS" | |
4349 | cat > conftest.$ac_ext <<EOF | |
e3009a74 | 4350 | #line 4351 "configure" |
95b47547 SG |
4351 | #include "confdefs.h" |
4352 | /* Override any gcc2 internal prototype to avoid an error. */ | |
4353 | /* We use char because int might match the return type of a gcc2 | |
4354 | builtin and then its argument prototype would still apply. */ | |
4355 | char dlopen(); | |
4356 | ||
bfde4a67 | 4357 | int main() { |
95b47547 SG |
4358 | dlopen() |
4359 | ; return 0; } | |
4360 | EOF | |
e3009a74 | 4361 | if { (eval echo configure:4362: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
95b47547 SG |
4362 | rm -rf conftest* |
4363 | eval "ac_cv_lib_$ac_lib_var=yes" | |
4364 | else | |
bfde4a67 SG |
4365 | echo "configure: failed program was:" >&5 |
4366 | cat conftest.$ac_ext >&5 | |
95b47547 SG |
4367 | rm -rf conftest* |
4368 | eval "ac_cv_lib_$ac_lib_var=no" | |
4369 | fi | |
4370 | rm -f conftest* | |
4371 | LIBS="$ac_save_LIBS" | |
4372 | ||
4373 | fi | |
4374 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then | |
4375 | echo "$ac_t""yes" 1>&6 | |
bfde4a67 SG |
4376 | ac_tr_lib=HAVE_LIB`echo dl | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
4377 | -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` | |
95b47547 SG |
4378 | cat >> confdefs.h <<EOF |
4379 | #define $ac_tr_lib 1 | |
4380 | EOF | |
4381 | ||
4382 | LIBS="-ldl $LIBS" | |
4383 | ||
4384 | else | |
4385 | echo "$ac_t""no" 1>&6 | |
4386 | fi | |
4387 | ||
4b95e9a1 JM |
4388 | if test "$GCC" = "yes" ; then |
4389 | # The GNU linker requires the -export-dynamic option to make | |
4390 | # all symbols visible in the dynamic symbol table. | |
4391 | hold_ldflags=$LDFLAGS | |
4392 | echo $ac_n "checking for the ld -export-dynamic flag""... $ac_c" 1>&6 | |
e3009a74 | 4393 | echo "configure:4394: checking for the ld -export-dynamic flag" >&5 |
4b95e9a1 JM |
4394 | LDFLAGS="${LDFLAGS} -Wl,-export-dynamic" |
4395 | cat > conftest.$ac_ext <<EOF | |
e3009a74 | 4396 | #line 4397 "configure" |
4b95e9a1 JM |
4397 | #include "confdefs.h" |
4398 | ||
4399 | int main() { | |
4400 | int i; | |
4401 | ; return 0; } | |
4402 | EOF | |
e3009a74 | 4403 | if { (eval echo configure:4404: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
4b95e9a1 JM |
4404 | rm -rf conftest* |
4405 | found=yes | |
4406 | else | |
4407 | echo "configure: failed program was:" >&5 | |
4408 | cat conftest.$ac_ext >&5 | |
4409 | rm -rf conftest* | |
4410 | found=no | |
4411 | fi | |
4412 | rm -f conftest* | |
4413 | LDFLAGS=$hold_ldflags | |
4414 | echo "$ac_t""$found" 1>&6 | |
4415 | if test $found = yes; then | |
4416 | CONFIG_LDFLAGS="${CONFIG_LDFLAGS} -Wl,-export-dynamic" | |
4417 | fi | |
4418 | fi | |
4419 | else | |
4420 | echo "$ac_t""no" 1>&6 | |
4421 | fi | |
4422 | ;; | |
4423 | esac | |
4424 | ||
89e673a4 | 4425 | fi |
47ef0da5 | 4426 | |
5436fc65 | 4427 | ENABLE_CFLAGS= |
5436fc65 C |
4428 | |
4429 | # Check whether --enable-netrom or --disable-netrom was given. | |
1a7b4b7c DE |
4430 | if test "${enable_netrom+set}" = set; then |
4431 | enableval="$enable_netrom" | |
5436fc65 C |
4432 | case "${enableval}" in |
4433 | yes) enable_netrom=yes ;; | |
4434 | no) enable_netrom=no ;; | |
4435 | *) { echo "configure: error: bad value ${enableval} given for netrom option" 1>&2; exit 1; } ;; | |
4436 | esac | |
4437 | fi | |
4438 | ||
4439 | ||
4440 | if test "${enable_netrom}" = "yes"; then | |
6c310da8 | 4441 | CONFIG_OBS="${CONFIG_OBS} remote-nrom.o" |
c7bb1531 | 4442 | CONFIG_SRCS="${CONFIG_SRCS} remote-nrom.c" |
5436fc65 C |
4443 | fi |
4444 | ||
ba68ad57 JM |
4445 | # Check whether --enable-warnings or --disable-warnings was given. |
4446 | if test "${enable_warnings+set}" = set; then | |
4447 | enableval="$enable_warnings" | |
4448 | case "${enableval}" in | |
4449 | yes) enable_warnings=yes ;; | |
4450 | no) enable_warnings=no ;; | |
4451 | *) { echo "configure: error: bad value ${enableval} given for warnings options" 1>&2; exit 1; } ;; | |
4452 | esac | |
4453 | fi | |
4454 | ||
4455 | ||
4456 | if test "x$enable_warnings" = xyes -a "x$GCC" = xyes | |
4457 | then | |
e3009a74 | 4458 | WARN_CFLAGS="-Wall -Wstrict-prototypes -Wmissing-prototypes" |
ba68ad57 JM |
4459 | else |
4460 | WARN_CFLAGS="" | |
4461 | fi | |
4462 | ||
4463 | ||
0728afad FF |
4464 | MMALLOC_CFLAGS= |
4465 | MMALLOC= | |
4466 | ||
4467 | ||
4468 | ||
4469 | # Check whether --with-mmalloc or --without-mmalloc was given. | |
4470 | if test "${with_mmalloc+set}" = set; then | |
4471 | withval="$with_mmalloc" | |
4472 | case "${withval}" in | |
4473 | yes) want_mmalloc=true ;; | |
4474 | no) want_mmalloc=false;; | |
4475 | *) { echo "configure: error: bad value ${withval} for GDB with-mmalloc option" 1>&2; exit 1; } ;; | |
4476 | esac | |
4477 | else | |
4478 | want_mmalloc=false | |
4479 | fi | |
4480 | ||
4481 | if test x$want_mmalloc = xtrue; then | |
4482 | cat >> confdefs.h <<\EOF | |
4483 | #define USE_MMALLOC 1 | |
4484 | EOF | |
4485 | ||
4486 | cat >> confdefs.h <<\EOF | |
dd600735 | 4487 | #define MMCHECK_FORCE 1 |
0728afad FF |
4488 | EOF |
4489 | ||
4490 | MMALLOC_CFLAGS="-I$srcdir/../mmalloc" | |
4491 | MMALLOC='../mmalloc/libmmalloc.a' | |
4492 | fi | |
4493 | ||
5436fc65 | 4494 | # start-sanitize-gdbtk |
fa41e1a3 | 4495 | # start-sanitize-ide |
2476848a MH |
4496 | ENABLE_IDE= |
4497 | # Check whether --enable-ide or --disable-ide was given. | |
4498 | if test "${enable_ide+set}" = set; then | |
4499 | enableval="$enable_ide" | |
4500 | : | |
4501 | fi | |
4502 | ||
4503 | if test "$enable_ide" = yes; then | |
4504 | enable_ide=yes | |
4505 | ENABLE_IDE=1 | |
4506 | else | |
4507 | enable_ide=no | |
4508 | fi | |
4509 | ||
4510 | ||
c076f1ed DM |
4511 | # Check whether --with-foundry-libs or --without-foundry-libs was given. |
4512 | if test "${with_foundry_libs+set}" = set; then | |
4513 | withval="$with_foundry_libs" | |
4514 | FOUNDRY_LIB_BASE=${withval} | |
4515 | fi | |
4516 | ||
4517 | ||
4518 | ||
4519 | # | |
4520 | # This is the Foundry SDK | |
4521 | # | |
4522 | # These variables are used to determine where the Foundry libs and | |
4523 | # header files are located. | |
4524 | # | |
4525 | if test "$FOUNDRY_LIB_BASE" != ""; then | |
4526 | LIBGUI="${FOUNDRY_LIB_BASE}/lib/libgui.a" | |
4527 | GUI_CFLAGS_X="-I${FOUNDRY_LIB_BASE}/include" | |
4528 | if test x$enable_ide = xyes; then | |
4529 | IDE_CFLAGS_X="-I${FOUNDRY_LIB_BASE}/include -DIDE" | |
4530 | IDE_X="-L${FOUNDRY_LIB_BASE}/lib -lilu-Tk -lilu-c -lilu" | |
4531 | else | |
4532 | IDE_CFLAGS_X="-I${FOUNDRY_LIB_BASE}/include" | |
4533 | fi | |
4534 | LIBIDETCL="${FOUNDRY_LIB_BASE}/lib/libidetcl.a" | |
4535 | LIBIDE="${FOUNDRY_LIB_BASE}/lib/libide.a" | |
4536 | IDE_DEPS="${FOUNDRY_LIB_BASE}/lib/libilu-Tk.a ${FOUNDRY_LIB_BASE}/lib/libilu-c.a ${FOUNDRY_LIB_BASE}/lib/libilu.a" | |
4537 | else | |
4538 | LIBGUI="../libgui/src/libgui.a" | |
4539 | GUI_CFLAGS_X="-I${srcdir}/../libgui/src" | |
4540 | if test x$enable_ide = xyes; then | |
4541 | IDE_CFLAGS_X="-I${srcdir}/../libidetcl/src -I${srcdir}/../libide/src -DIDE -I${srcdir}/../ilu/runtime/mainloop" | |
4542 | IDE_X="-L../ilu/runtime/mainloop -lilu-Tk -L../ilu/runtime/c -lilu-c -L../ilu/runtime/kernel -lilu" | |
4543 | else | |
4544 | IDE_CFLAGS_X="-I${srcdir}/../libidetcl/src -I${srcdir}/../libide/src" | |
4545 | fi | |
4546 | LIBIDETCL="../libidetcl/src/libidetcl.a" | |
4547 | LIBIDE="../libide/src/libide.a" | |
4548 | IDE_DEPS="../ilu/runtime/mainloop/libilu-Tk.a ../ilu/runtime/c/libilu-c.a ../ilu/runtime/kernel/libilu.a" | |
4549 | fi | |
4550 | ||
4551 | ||
4552 | ||
4553 | ||
4554 | ||
4555 | ||
4556 | ||
fa41e1a3 | 4557 | # end-sanitize-ide |
c076f1ed | 4558 | |
5436fc65 C |
4559 | ENABLE_GDBTK= |
4560 | ||
4561 | # Check whether --enable-gdbtk or --disable-gdbtk was given. | |
1a7b4b7c DE |
4562 | if test "${enable_gdbtk+set}" = set; then |
4563 | enableval="$enable_gdbtk" | |
5436fc65 | 4564 | case "${enableval}" in |
0fe1522a SG |
4565 | yes) |
4566 | case "$host" in | |
4567 | *go32*) | |
4568 | echo "configure: warning: GDB does not support GDBtk on host ${host}. GDBtk will be disabled." 1>&2 | |
4569 | enable_gdbtk=no ;; | |
8a19b35a | 4570 | *windows*) |
b613bfbf GN |
4571 | echo "configure: warning: GDB does not support GDBtk on host ${host}. GDBtk will be disabled." 1>&2 |
4572 | enable_gdbtk=no ;; | |
0fe1522a SG |
4573 | *) |
4574 | enable_gdbtk=yes ;; | |
4575 | esac ;; | |
4576 | no) | |
4577 | enable_gdbtk=no ;; | |
4578 | *) | |
4579 | { echo "configure: error: bad value ${enableval} given for gdbtk option" 1>&2; exit 1; } ;; | |
5436fc65 | 4580 | esac |
0fe1522a SG |
4581 | else |
4582 | ||
b613bfbf | 4583 | # Default is on for everything but go32 and cygwin32 |
0fe1522a | 4584 | case "$host" in |
8a19b35a | 4585 | *go32* | *windows*) |
b613bfbf | 4586 | ;; |
0fe1522a SG |
4587 | *) |
4588 | enable_gdbtk=yes ;; | |
4589 | esac | |
4590 | ||
5436fc65 C |
4591 | fi |
4592 | ||
4593 | ||
9b119644 ILT |
4594 | # In the cygwin32 environment, we need some additional flags. |
4595 | echo $ac_n "checking for cygwin32""... $ac_c" 1>&6 | |
e3009a74 | 4596 | echo "configure:4597: checking for cygwin32" >&5 |
9b119644 ILT |
4597 | if eval "test \"`echo '$''{'gdb_cv_os_cygwin32'+set}'`\" = set"; then |
4598 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4599 | else | |
4600 | cat > conftest.$ac_ext <<EOF | |
e3009a74 | 4601 | #line 4602 "configure" |
9b119644 ILT |
4602 | #include "confdefs.h" |
4603 | ||
4604 | #ifdef __CYGWIN32__ | |
4605 | lose | |
4606 | #endif | |
4607 | EOF | |
4608 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
4609 | egrep "lose" >/dev/null 2>&1; then | |
4610 | rm -rf conftest* | |
4611 | gdb_cv_os_cygwin32=yes | |
4612 | else | |
4613 | rm -rf conftest* | |
4614 | gdb_cv_os_cygwin32=no | |
4615 | fi | |
4616 | rm -f conftest* | |
4617 | ||
4618 | fi | |
4619 | ||
4620 | echo "$ac_t""$gdb_cv_os_cygwin32" 1>&6 | |
4621 | ||
4622 | WIN32LIBS= | |
4623 | WIN32LDAPP= | |
4624 | ||
4625 | ||
4626 | ||
929db6e5 EZ |
4627 | WINDRES=${WINDRES-windres} |
4628 | ||
4629 | ||
9b119644 ILT |
4630 | if test x$gdb_cv_os_cygwin32 = xyes; then |
4631 | if test x$enable_ide = xyes; then | |
4632 | WIN32LIBS="-ladvapi32" | |
4633 | fi | |
4634 | fi | |
4635 | ||
4636 | configdir="unix" | |
8a19b35a | 4637 | |
b177bf84 | 4638 | GDBTKLIBS= |
5436fc65 | 4639 | if test "${enable_gdbtk}" = "yes"; then |
0fe1522a | 4640 | |
047465fd TT |
4641 | |
4642 | # | |
4643 | # Ok, lets find the tcl configuration | |
4644 | # First, look for one uninstalled. | |
4645 | # the alternative search directory is invoked by --with-tclconfig | |
4646 | # | |
5436fc65 | 4647 | |
047465fd TT |
4648 | if test x"${no_tcl}" = x ; then |
4649 | # we reset no_tcl in case something fails here | |
4650 | no_tcl=true | |
4651 | # Check whether --with-tclconfig or --without-tclconfig was given. | |
4652 | if test "${with_tclconfig+set}" = set; then | |
4653 | withval="$with_tclconfig" | |
4654 | with_tclconfig=${withval} | |
5436fc65 C |
4655 | fi |
4656 | ||
047465fd | 4657 | echo $ac_n "checking for Tcl configuration""... $ac_c" 1>&6 |
e3009a74 | 4658 | echo "configure:4659: checking for Tcl configuration" >&5 |
047465fd | 4659 | if eval "test \"`echo '$''{'ac_cv_c_tclconfig'+set}'`\" = set"; then |
5436fc65 C |
4660 | echo $ac_n "(cached) $ac_c" 1>&6 |
4661 | else | |
047465fd | 4662 | |
1a7b4b7c | 4663 | |
047465fd TT |
4664 | # First check to see if --with-tclconfig was specified. |
4665 | if test x"${with_tclconfig}" != x ; then | |
4666 | if test -f "${with_tclconfig}/tclConfig.sh" ; then | |
4667 | ac_cv_c_tclconfig=`(cd ${with_tclconfig}; pwd)` | |
4668 | else | |
4669 | { echo "configure: error: ${with_tclconfig} directory doesn't contain tclConfig.sh" 1>&2; exit 1; } | |
5436fc65 | 4670 | fi |
047465fd | 4671 | fi |
5436fc65 | 4672 | |
047465fd TT |
4673 | # then check for a private Tcl installation |
4674 | if test x"${ac_cv_c_tclconfig}" = x ; then | |
4675 | for i in \ | |
4676 | ../tcl \ | |
4677 | `ls -dr ../tcl[7-9]* 2>/dev/null` \ | |
4678 | ../../tcl \ | |
4679 | `ls -dr ../../tcl[7-9]* 2>/dev/null` \ | |
4680 | ../../../tcl \ | |
4681 | `ls -dr ../../../tcl[7-9]* 2>/dev/null` ; do | |
8a19b35a MH |
4682 | if test -f "$i/${configdir}/tclConfig.sh" ; then |
4683 | ac_cv_c_tclconfig=`(cd $i/${configdir}; pwd)` | |
047465fd TT |
4684 | break |
4685 | fi | |
4686 | done | |
4687 | fi | |
4688 | # check in a few common install locations | |
4689 | if test x"${ac_cv_c_tclconfig}" = x ; then | |
4690 | for i in `ls -d ${prefix}/lib /usr/local/lib 2>/dev/null` ; do | |
4691 | if test -f "$i/tclConfig.sh" ; then | |
4692 | ac_cv_c_tclconfig=`(cd $i; pwd)` | |
4693 | break | |
4694 | fi | |
4695 | done | |
4696 | fi | |
4697 | # check in a few other private locations | |
4698 | if test x"${ac_cv_c_tclconfig}" = x ; then | |
4699 | for i in \ | |
4700 | ${srcdir}/../tcl \ | |
4701 | `ls -dr ${srcdir}/../tcl[7-9]* 2>/dev/null` ; do | |
8a19b35a MH |
4702 | if test -f "$i/${configdir}/tclConfig.sh" ; then |
4703 | ac_cv_c_tclconfig=`(cd $i/${configdir}; pwd)` | |
047465fd TT |
4704 | break |
4705 | fi | |
4706 | done | |
4707 | fi | |
4708 | ||
5436fc65 | 4709 | fi |
1a7b4b7c | 4710 | |
047465fd TT |
4711 | if test x"${ac_cv_c_tclconfig}" = x ; then |
4712 | TCLCONFIG="# no Tcl configs found" | |
4713 | echo "configure: warning: Can't find Tcl configuration definitions" 1>&2 | |
4714 | else | |
4715 | no_tcl= | |
4716 | TCLCONFIG=${ac_cv_c_tclconfig}/tclConfig.sh | |
4717 | echo "$ac_t""found $TCLCONFIG" 1>&6 | |
5436fc65 | 4718 | fi |
5436fc65 C |
4719 | fi |
4720 | ||
0cf433d9 ILT |
4721 | if test -z "${no_tcl}"; then |
4722 | ||
047465fd | 4723 | . $TCLCONFIG |
5436fc65 | 4724 | |
047465fd TT |
4725 | |
4726 | ||
4727 | ||
4728 | ||
4729 | ||
5436fc65 | 4730 | |
5436fc65 | 4731 | |
5436fc65 | 4732 | |
5436fc65 | 4733 | |
047465fd TT |
4734 | |
4735 | ||
4736 | ||
4737 | ||
4738 | ||
4739 | ||
4740 | ||
4741 | ||
4742 | ||
4743 | ||
4744 | ||
4745 | ||
5436fc65 | 4746 | |
5436fc65 | 4747 | |
5436fc65 | 4748 | |
0cf433d9 | 4749 | |
047465fd TT |
4750 | # |
4751 | # Ok, lets find the tk configuration | |
4752 | # First, look for one uninstalled. | |
4753 | # the alternative search directory is invoked by --with-tkconfig | |
4754 | # | |
5436fc65 | 4755 | |
047465fd TT |
4756 | if test x"${no_tk}" = x ; then |
4757 | # we reset no_tk in case something fails here | |
4758 | no_tk=true | |
4759 | # Check whether --with-tkconfig or --without-tkconfig was given. | |
4760 | if test "${with_tkconfig+set}" = set; then | |
4761 | withval="$with_tkconfig" | |
4762 | with_tkconfig=${withval} | |
5436fc65 C |
4763 | fi |
4764 | ||
047465fd | 4765 | echo $ac_n "checking for Tk configuration""... $ac_c" 1>&6 |
e3009a74 | 4766 | echo "configure:4767: checking for Tk configuration" >&5 |
047465fd | 4767 | if eval "test \"`echo '$''{'ac_cv_c_tkconfig'+set}'`\" = set"; then |
5436fc65 C |
4768 | echo $ac_n "(cached) $ac_c" 1>&6 |
4769 | else | |
047465fd | 4770 | |
5436fc65 | 4771 | |
047465fd TT |
4772 | # First check to see if --with-tkconfig was specified. |
4773 | if test x"${with_tkconfig}" != x ; then | |
4774 | if test -f "${with_tkconfig}/tkConfig.sh" ; then | |
4775 | ac_cv_c_tkconfig=`(cd ${with_tkconfig}; pwd)` | |
4776 | else | |
4777 | { echo "configure: error: ${with_tkconfig} directory doesn't contain tkConfig.sh" 1>&2; exit 1; } | |
5436fc65 | 4778 | fi |
047465fd | 4779 | fi |
5436fc65 | 4780 | |
047465fd TT |
4781 | # then check for a private Tk library |
4782 | if test x"${ac_cv_c_tkconfig}" = x ; then | |
4783 | for i in \ | |
4784 | ../tk \ | |
4785 | `ls -dr ../tk[4-9]* 2>/dev/null` \ | |
4786 | ../../tk \ | |
4787 | `ls -dr ../../tk[4-9]* 2>/dev/null` \ | |
4788 | ../../../tk \ | |
4789 | `ls -dr ../../../tk[4-9]* 2>/dev/null` ; do | |
8a19b35a MH |
4790 | if test -f "$i/${configdir}/tkConfig.sh" ; then |
4791 | ac_cv_c_tkconfig=`(cd $i/${configdir}; pwd)` | |
047465fd TT |
4792 | break |
4793 | fi | |
4794 | done | |
4795 | fi | |
4796 | # check in a few common install locations | |
4797 | if test x"${ac_cv_c_tkconfig}" = x ; then | |
4798 | for i in `ls -d ${prefix}/lib /usr/local/lib 2>/dev/null` ; do | |
4799 | if test -f "$i/tkConfig.sh" ; then | |
4800 | ac_cv_c_tkconfig=`(cd $i; pwd)` | |
4801 | break | |
4802 | fi | |
4803 | done | |
4804 | fi | |
4805 | # check in a few other private locations | |
4806 | if test x"${ac_cv_c_tkconfig}" = x ; then | |
4807 | for i in \ | |
4808 | ${srcdir}/../tk \ | |
4809 | `ls -dr ${srcdir}/../tk[4-9]* 2>/dev/null` ; do | |
8a19b35a MH |
4810 | if test -f "$i/${configdir}/tkConfig.sh" ; then |
4811 | ac_cv_c_tkconfig=`(cd $i/${configdir}; pwd)` | |
047465fd TT |
4812 | break |
4813 | fi | |
4814 | done | |
4815 | fi | |
4816 | ||
5436fc65 | 4817 | fi |
5436fc65 | 4818 | |
047465fd TT |
4819 | if test x"${ac_cv_c_tkconfig}" = x ; then |
4820 | TKCONFIG="# no Tk configs found" | |
4821 | echo "configure: warning: Can't find Tk configuration definitions" 1>&2 | |
4822 | else | |
4823 | no_tk= | |
4824 | TKCONFIG=${ac_cv_c_tkconfig}/tkConfig.sh | |
4825 | echo "$ac_t""found $TKCONFIG" 1>&6 | |
4826 | fi | |
5436fc65 C |
4827 | fi |
4828 | ||
4829 | ||
5436fc65 | 4830 | |
0cf433d9 ILT |
4831 | # If $no_tk is nonempty, then we can't do Tk, and there is no |
4832 | # point to doing Tcl. | |
4833 | if test -z "${no_tk}"; then | |
4834 | ||
047465fd TT |
4835 | if test -f "$TKCONFIG" ; then |
4836 | . $TKCONFIG | |
4837 | fi | |
5436fc65 | 4838 | |
047465fd TT |
4839 | |
4840 | ||
5436fc65 | 4841 | |
047465fd | 4842 | |
5436fc65 C |
4843 | |
4844 | ||
a2b63bbd | 4845 | |
047465fd TT |
4846 | |
4847 | ||
4848 | ||
9b119644 | 4849 | |
047465fd | 4850 | |
0cf433d9 | 4851 | |
5436fc65 | 4852 | # |
4e327047 TT |
4853 | # Ok, lets find the tcl source trees so we can use the headers |
4854 | # Warning: transition of version 9 to 10 will break this algorithm | |
4855 | # because 10 sorts before 9. We also look for just tcl. We have to | |
4856 | # be careful that we don't match stuff like tclX by accident. | |
4857 | # the alternative search directory is involked by --with-tclinclude | |
5436fc65 | 4858 | # |
8a19b35a | 4859 | |
4e327047 | 4860 | no_tcl=true |
8a19b35a | 4861 | echo $ac_n "checking for Tcl private headers. dir=${configdir}""... $ac_c" 1>&6 |
e3009a74 | 4862 | echo "configure:4863: checking for Tcl private headers. dir=${configdir}" >&5 |
4e327047 | 4863 | # Check whether --with-tclinclude or --without-tclinclude was given. |
1a7b4b7c DE |
4864 | if test "${with_tclinclude+set}" = set; then |
4865 | withval="$with_tclinclude" | |
4e327047 TT |
4866 | with_tclinclude=${withval} |
4867 | fi | |
4868 | ||
4869 | if eval "test \"`echo '$''{'ac_cv_c_tclh'+set}'`\" = set"; then | |
4870 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4871 | else | |
4872 | ||
4873 | # first check to see if --with-tclinclude was specified | |
4874 | if test x"${with_tclinclude}" != x ; then | |
4875 | if test -f ${with_tclinclude}/tclInt.h ; then | |
4876 | ac_cv_c_tclh=`(cd ${with_tclinclude}; pwd)` | |
047465fd TT |
4877 | elif test -f ${with_tclinclude}/generic/tclInt.h ; then |
4878 | ac_cv_c_tclh=`(cd ${with_tclinclude}/generic; pwd)` | |
5436fc65 | 4879 | else |
4e327047 TT |
4880 | { echo "configure: error: ${with_tclinclude} directory doesn't contain private headers" 1>&2; exit 1; } |
4881 | fi | |
4882 | fi | |
047465fd TT |
4883 | |
4884 | # next check if it came with Tcl configuration file | |
4885 | if test x"${ac_cv_c_tclconfig}" = x ; then | |
4886 | if test -f $ac_cv_c_tclconfig/../generic/tclInt.h ; then | |
4887 | ac_cv_c_tclh=`(cd $ac_cv_c_tclconfig/..; pwd)` | |
4888 | fi | |
4889 | fi | |
4890 | ||
4e327047 TT |
4891 | # next check in private source directory |
4892 | # | |
4893 | # since ls returns lowest version numbers first, reverse its output | |
4894 | if test x"${ac_cv_c_tclh}" = x ; then | |
4895 | for i in \ | |
4896 | ${srcdir}/../tcl \ | |
047465fd | 4897 | `ls -dr ${srcdir}/../tcl[7-9]* 2>/dev/null` \ |
4e327047 | 4898 | ${srcdir}/../../tcl \ |
047465fd | 4899 | `ls -dr ${srcdir}/../../tcl[7-9]* 2>/dev/null` \ |
4e327047 | 4900 | ${srcdir}/../../../tcl \ |
047465fd | 4901 | `ls -dr ${srcdir}/../../../tcl[7-9]* 2>/dev/null ` ; do |
4e327047 | 4902 | if test -f $i/generic/tclInt.h ; then |
047465fd | 4903 | ac_cv_c_tclh=`(cd $i/generic; pwd)` |
1a7b4b7c | 4904 | break |
4e327047 TT |
4905 | fi |
4906 | done | |
4907 | fi | |
4908 | # finally check in a few common install locations | |
4909 | # | |
4910 | # since ls returns lowest version numbers first, reverse its output | |
4911 | if test x"${ac_cv_c_tclh}" = x ; then | |
4912 | for i in \ | |
047465fd TT |
4913 | `ls -dr /usr/local/src/tcl[7-9]* 2>/dev/null` \ |
4914 | `ls -dr /usr/local/lib/tcl[7-9]* 2>/dev/null` \ | |
4e327047 TT |
4915 | /usr/local/src/tcl \ |
4916 | /usr/local/lib/tcl \ | |
4917 | ${prefix}/include ; do | |
047465fd TT |
4918 | if test -f $i/generic/tclInt.h ; then |
4919 | ac_cv_c_tclh=`(cd $i/generic; pwd)` | |
4e327047 TT |
4920 | break |
4921 | fi | |
4922 | done | |
4923 | fi | |
4924 | # see if one is installed | |
4925 | if test x"${ac_cv_c_tclh}" = x ; then | |
bfde4a67 | 4926 | ac_safe=`echo "tclInt.h" | sed 'y%./+-%__p_%'` |
4e327047 | 4927 | echo $ac_n "checking for tclInt.h""... $ac_c" 1>&6 |
e3009a74 | 4928 | echo "configure:4929: checking for tclInt.h" >&5 |
5436fc65 C |
4929 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
4930 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4931 | else | |
4932 | cat > conftest.$ac_ext <<EOF | |
e3009a74 | 4933 | #line 4934 "configure" |
5436fc65 | 4934 | #include "confdefs.h" |
4e327047 | 4935 | #include <tclInt.h> |
5436fc65 | 4936 | EOF |
1a7b4b7c | 4937 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
e3009a74 | 4938 | { (eval echo configure:4939: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
ba68ad57 | 4939 | ac_err=`grep -v '^ *+' conftest.out` |
5436fc65 C |
4940 | if test -z "$ac_err"; then |
4941 | rm -rf conftest* | |
4942 | eval "ac_cv_header_$ac_safe=yes" | |
4943 | else | |
4944 | echo "$ac_err" >&5 | |
bfde4a67 SG |
4945 | echo "configure: failed program was:" >&5 |
4946 | cat conftest.$ac_ext >&5 | |
5436fc65 C |
4947 | rm -rf conftest* |
4948 | eval "ac_cv_header_$ac_safe=no" | |
4949 | fi | |
4950 | rm -f conftest* | |
4951 | fi | |
4952 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | |
4953 | echo "$ac_t""yes" 1>&6 | |
4e327047 | 4954 | ac_cv_c_tclh=installed |
5436fc65 C |
4955 | else |
4956 | echo "$ac_t""no" 1>&6 | |
4e327047 | 4957 | ac_cv_c_tclh="" |
5436fc65 C |
4958 | fi |
4959 | ||
4e327047 TT |
4960 | fi |
4961 | ||
4962 | fi | |
4963 | ||
4964 | if test x"${ac_cv_c_tclh}" = x ; then | |
4965 | TCLHDIR="# no Tcl private headers found" | |
4966 | { echo "configure: error: Can't find Tcl private headers" 1>&2; exit 1; } | |
4967 | fi | |
4968 | if test x"${ac_cv_c_tclh}" != x ; then | |
4969 | no_tcl="" | |
1a7b4b7c | 4970 | if test x"${ac_cv_c_tclh}" = x"installed" ; then |
4e327047 TT |
4971 | echo "$ac_t""is installed" 1>&6 |
4972 | TCLHDIR="" | |
4973 | else | |
4974 | echo "$ac_t""found in ${ac_cv_c_tclh}" 1>&6 | |
4975 | # this hack is cause the TCLHDIR won't print if there is a "-I" in it. | |
4976 | TCLHDIR="-I${ac_cv_c_tclh}" | |
5436fc65 | 4977 | fi |
5436fc65 | 4978 | fi |
4e327047 | 4979 | |
4e327047 | 4980 | |
5436fc65 | 4981 | |
0cf433d9 | 4982 | |
5436fc65 | 4983 | # |
4e327047 TT |
4984 | # Ok, lets find the tk source trees so we can use the headers |
4985 | # If the directory (presumably symlink) named "tk" exists, use that one | |
4986 | # in preference to any others. Same logic is used when choosing library | |
4987 | # and again with Tcl. The search order is the best place to look first, then in | |
4988 | # decreasing significance. The loop breaks if the trigger file is found. | |
4989 | # Note the gross little conversion here of srcdir by cd'ing to the found | |
4990 | # directory. This converts the path from a relative to an absolute, so | |
4991 | # recursive cache variables for the path will work right. We check all | |
4992 | # the possible paths in one loop rather than many seperate loops to speed | |
4993 | # things up. | |
047465fd | 4994 | # the alternative search directory is involked by --with-tkinclude |
5436fc65 | 4995 | # |
047465fd | 4996 | no_tk=true |
4e327047 | 4997 | echo $ac_n "checking for Tk private headers""... $ac_c" 1>&6 |
e3009a74 | 4998 | echo "configure:4999: checking for Tk private headers" >&5 |
4e327047 | 4999 | # Check whether --with-tkinclude or --without-tkinclude was given. |
1a7b4b7c DE |
5000 | if test "${with_tkinclude+set}" = set; then |
5001 | withval="$with_tkinclude" | |
4e327047 TT |
5002 | with_tkinclude=${withval} |
5003 | fi | |
5004 | ||
4e327047 TT |
5005 | if eval "test \"`echo '$''{'ac_cv_c_tkh'+set}'`\" = set"; then |
5006 | echo $ac_n "(cached) $ac_c" 1>&6 | |
5007 | else | |
5008 | ||
5009 | # first check to see if --with-tkinclude was specified | |
5010 | if test x"${with_tkinclude}" != x ; then | |
5011 | if test -f ${with_tkinclude}/tk.h ; then | |
5012 | ac_cv_c_tkh=`(cd ${with_tkinclude}; pwd)` | |
047465fd TT |
5013 | elif test -f ${with_tkinclude}/generic/tk.h ; then |
5014 | ac_cv_c_tkh=`(cd ${with_tkinclude}/generic; pwd)` | |
5436fc65 | 5015 | else |
4e327047 TT |
5016 | { echo "configure: error: ${with_tkinclude} directory doesn't contain private headers" 1>&2; exit 1; } |
5017 | fi | |
5018 | fi | |
047465fd TT |
5019 | |
5020 | # next check if it came with Tk configuration file | |
5021 | if test x"${ac_cv_c_tkconfig}" = x ; then | |
5022 | if test -f $ac_cv_c_tkconfig/../generic/tk.h ; then | |
5023 | ac_cv_c_tkh=`(cd $ac_cv_c_tkconfig/..; pwd)` | |
5024 | fi | |
5025 | fi | |
5026 | ||
4e327047 TT |
5027 | # next check in private source directory |
5028 | # | |
047465fd | 5029 | # since ls returns lowest version numbers first, reverse its output |
4e327047 TT |
5030 | if test x"${ac_cv_c_tkh}" = x ; then |
5031 | for i in \ | |
5032 | ${srcdir}/../tk \ | |
047465fd | 5033 | `ls -dr ${srcdir}/../tk[4-9]* 2>/dev/null` \ |
4e327047 | 5034 | ${srcdir}/../../tk \ |
047465fd | 5035 | `ls -dr ${srcdir}/../../tk[4-9]* 2>/dev/null` \ |
4e327047 | 5036 | ${srcdir}/../../../tk \ |
047465fd TT |
5037 | `ls -dr ${srcdir}/../../../tk[4-9]* 2>/dev/null ` ; do |
5038 | if test -f $i/generic/tk.h ; then | |
5039 | ac_cv_c_tkh=`(cd $i/generic; pwd)` | |
4e327047 TT |
5040 | break |
5041 | fi | |
4e327047 TT |
5042 | done |
5043 | fi | |
5044 | # finally check in a few common install locations | |
5045 | # | |
047465fd | 5046 | # since ls returns lowest version numbers first, reverse its output |
4e327047 TT |
5047 | if test x"${ac_cv_c_tkh}" = x ; then |
5048 | for i in \ | |
047465fd TT |
5049 | `ls -dr /usr/local/src/tk[4-9]* 2>/dev/null` \ |
5050 | `ls -dr /usr/local/lib/tk[4-9]* 2>/dev/null` \ | |
4e327047 TT |
5051 | /usr/local/src/tk \ |
5052 | /usr/local/lib/tk \ | |
5053 | ${prefix}/include ; do | |
047465fd TT |
5054 | if test -f $i/generic/tk.h ; then |
5055 | ac_cv_c_tkh=`(cd $i/generic; pwd)` | |
4e327047 TT |
5056 | break |
5057 | fi | |
5058 | done | |
5059 | fi | |
5060 | # see if one is installed | |
5061 | if test x"${ac_cv_c_tkh}" = x ; then | |
bfde4a67 | 5062 | ac_safe=`echo "tk.h" | sed 'y%./+-%__p_%'` |
4e327047 | 5063 | echo $ac_n "checking for tk.h""... $ac_c" 1>&6 |
e3009a74 | 5064 | echo "configure:5065: checking for tk.h" >&5 |
5436fc65 C |
5065 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
5066 | echo $ac_n "(cached) $ac_c" 1>&6 | |
5067 | else | |
5068 | cat > conftest.$ac_ext <<EOF | |
e3009a74 | 5069 | #line 5070 "configure" |
5436fc65 | 5070 | #include "confdefs.h" |
4e327047 | 5071 | #include <tk.h> |
5436fc65 | 5072 | EOF |
1a7b4b7c | 5073 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
e3009a74 | 5074 | { (eval echo configure:5075: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
ba68ad57 | 5075 | ac_err=`grep -v '^ *+' conftest.out` |
5436fc65 C |
5076 | if test -z "$ac_err"; then |
5077 | rm -rf conftest* | |
5078 | eval "ac_cv_header_$ac_safe=yes" | |
5079 | else | |
5080 | echo "$ac_err" >&5 | |
bfde4a67 SG |
5081 | echo "configure: failed program was:" >&5 |
5082 | cat conftest.$ac_ext >&5 | |
5436fc65 C |
5083 | rm -rf conftest* |
5084 | eval "ac_cv_header_$ac_safe=no" | |
5085 | fi | |
5086 | rm -f conftest* | |
5087 | fi | |
5088 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | |
5089 | echo "$ac_t""yes" 1>&6 | |
4e327047 | 5090 | ac_cv_c_tkh=installed |
5436fc65 C |
5091 | else |
5092 | echo "$ac_t""no" 1>&6 | |
047465fd | 5093 | ac_cv_c_tkh="" |
5436fc65 C |
5094 | fi |
5095 | ||
4e327047 TT |
5096 | fi |
5097 | ||
5098 | fi | |
5099 | ||
5100 | if test x"${ac_cv_c_tkh}" != x ; then | |
5101 | no_tk="" | |
5102 | if test x"${ac_cv_c_tkh}" = x"installed" ; then | |
5103 | echo "$ac_t""is installed" 1>&6 | |
5104 | TKHDIR="" | |
5105 | else | |
047465fd | 5106 | echo "$ac_t""found in ${ac_cv_c_tkh}" 1>&6 |
4e327047 TT |
5107 | # this hack is cause the TKHDIR won't print if there is a "-I" in it. |
5108 | TKHDIR="-I${ac_cv_c_tkh}" | |
5436fc65 C |
5109 | fi |
5110 | else | |
4e327047 TT |
5111 | TKHDIR="# no Tk directory found" |
5112 | echo "configure: warning: Can't find Tk private headers" 1>&2 | |
5113 | no_tk=true | |
5436fc65 C |
5114 | fi |
5115 | ||
5436fc65 C |
5116 | |
5117 | ||
2476848a MH |
5118 | |
5119 | echo $ac_n "checking for Itcl private headers. srcdir=${srcdir}""... $ac_c" 1>&6 | |
e3009a74 | 5120 | echo "configure:5121: checking for Itcl private headers. srcdir=${srcdir}" >&5 |
2476848a MH |
5121 | if test x"${ac_cv_c_itclh}" = x ; then |
5122 | for i in ${srcdir}/../itcl ${srcdir}/../../itcl ${srcdir}/../../../itcl ; do | |
5123 | if test -f $i/src/itcl.h ; then | |
5124 | ac_cv_c_itclh=`(cd $i/src; pwd)` | |
5125 | break | |
5126 | fi | |
5127 | done | |
5128 | fi | |
5129 | if test x"${ac_cv_c_itclh}" = x ; then | |
5130 | ITCLHDIR="# no Itcl private headers found" | |
5131 | { echo "configure: error: Can't find Itcl private headers" 1>&2; exit 1; } | |
5132 | fi | |
5133 | if test x"${ac_cv_c_itclh}" != x ; then | |
5134 | ITCLHDIR="-I${ac_cv_c_itclh}" | |
5135 | fi | |
5136 | # should always be here | |
5137 | ITCLLIB="../itcl/src/libitcl.a" | |
5138 | ||
5139 | ||
5140 | ||
5141 | ||
5142 | echo $ac_n "checking for Tix private headers. srcdir=${srcdir}""... $ac_c" 1>&6 | |
e3009a74 | 5143 | echo "configure:5144: checking for Tix private headers. srcdir=${srcdir}" >&5 |
2476848a MH |
5144 | if test x"${ac_cv_c_tixh}" = x ; then |
5145 | for i in ${srcdir}/../tix ${srcdir}/../../tix ${srcdir}/../../../tix ; do | |
5146 | if test -f $i/generic/tix.h ; then | |
5147 | ac_cv_c_tixh=`(cd $i/generic; pwd)` | |
5148 | break | |
5149 | fi | |
5150 | done | |
5151 | fi | |
5152 | if test x"${ac_cv_c_tixh}" = x ; then | |
5153 | TIXHDIR="# no Tix private headers found" | |
5154 | { echo "configure: error: Can't find Tix private headers" 1>&2; exit 1; } | |
5155 | fi | |
5156 | if test x"${ac_cv_c_tixh}" != x ; then | |
5157 | TIXHDIR="-I${ac_cv_c_tixh}" | |
5158 | fi | |
2476848a MH |
5159 | |
5160 | ||
5161 | ||
6bc5b2fa | 5162 | # now look for tix library stuff |
1154b47a | 5163 | TIXVERSION=4.1.8.0 |
6bc5b2fa MH |
5164 | . ${ac_cv_c_tclconfig}/tclConfig.sh |
5165 | case "${host}" in | |
5166 | *-*-cygwin32*) | |
f1f6dd9c | 5167 | tixdir=../tix/win/tcl8.0 |
6bc5b2fa MH |
5168 | ;; |
5169 | *) | |
1154b47a | 5170 | tixdir=../tix/unix/tk8.0 |
6bc5b2fa MH |
5171 | ;; |
5172 | esac | |
bb3d9f43 KS |
5173 | if test "${TCL_SHARED_BUILD}" = "1"; then |
5174 | TIX_LIB_EXT="${TCL_SHLIB_SUFFIX}" | |
11f91b2b KS |
5175 | |
5176 | # Can't win them all: SunOS 4 (others?) appends a version | |
5177 | # number after the ".so" | |
5178 | case "${host}" in | |
5179 | *-*-sunos4*) | |
5180 | TIX_LIB_EXT="${TIX_LIB_EXT}.1.0" ;; | |
5181 | esac | |
5182 | ||
bb3d9f43 KS |
5183 | else |
5184 | TIX_LIB_EXT=".a" | |
5185 | fi | |
11f91b2b | 5186 | |
6bc5b2fa MH |
5187 | if test "${TCL_LIB_VERSIONS_OK}" = "ok"; then |
5188 | TIXLIB="-L${tixdir} -ltix${TIXVERSION}" | |
bb3d9f43 | 5189 | TIX_DEPS="${tixdir}/libtix${TIXVERSION}${TIX_LIB_EXT}" |
6bc5b2fa MH |
5190 | else |
5191 | TIXLIB="-L${tixdir} -ltix`echo ${TIXVERSION} | tr -d .`" | |
bb3d9f43 | 5192 | TIX_DEPS="${tixdir}/libtix`echo ${TIXVERSION} | tr -d .`${TIX_LIB_EXT}" |
6bc5b2fa | 5193 | fi |
5436fc65 | 5194 | |
0cf433d9 | 5195 | ENABLE_GDBTK=1 |
509b70ac | 5196 | ENABLE_CFLAGS="${ENABLE_CFLAGS} -DGDBTK" |
5436fc65 | 5197 | |
6c310da8 | 5198 | # Include some libraries that Tcl and Tk want. |
2476848a | 5199 | if test "${enable_ide}" = "yes"; then |
8b5befef ILT |
5200 | TCL_LIBS='$(LIBIDETCL) $(LIBIDE) $(LIBGUI) $(IDE) $(ITCL) $(TIX) $(TK) $(TCL) $(X11_LDFLAGS) $(X11_LIBS)' |
5201 | CONFIG_DEPS='$(LIBIDETCL) $(LIBIDE) $(LIBGUI) $(IDE_DEPS) $(ITCL_DEPS) $(TIX_DEPS) $(TK_DEPS) $(TCL_DEPS)' | |
2476848a | 5202 | else |
dafec9dd ILT |
5203 | TCL_LIBS='$(LIBGUI) $(ITCL) $(TIX) $(TK) $(TCL) $(X11_LDFLAGS) $(X11_LIBS)' |
5204 | CONFIG_DEPS='$(LIBGUI) $(ITCL_DEPS) $(TIX_DEPS) $(TK_DEPS) $(TCL_DEPS)' | |
2476848a | 5205 | fi |
46964086 TT |
5206 | # Yes, the ordering seems wrong here. But it isn't. |
5207 | # TK_LIBS is the list of libraries that need to be linked | |
b177bf84 TT |
5208 | # after Tcl/Tk. Note that this isn't put into LIBS. If it |
5209 | # were in LIBS then any link tests after this point would | |
5210 | # try to include things like `$(LIBGUI)', which wouldn't work. | |
5211 | GDBTKLIBS="${TCL_LIBS} ${TK_LIBS}" | |
f3b86a30 | 5212 | CONFIG_OBS="${CONFIG_OBS} gdbtk.o gdbtk-cmds.o gdbtk-hooks.o" |
9b119644 ILT |
5213 | |
5214 | if test x$gdb_cv_os_cygwin32 = xyes; then | |
018d76dd | 5215 | WIN32LIBS="${WIN32LIBS} -lshell32 -lgdi32 -lcomdlg32 -ladvapi32 -luser32" |
47792960 | 5216 | WIN32LDAPP="-Wl,--subsystem,console" |
929db6e5 | 5217 | CONFIG_OBS="${CONFIG_OBS} gdbres.o" |
9b119644 | 5218 | fi |
0cf433d9 | 5219 | fi |
1a57cd09 | 5220 | fi |
a2b63bbd | 5221 | fi |
66efdff9 | 5222 | |
66efdff9 | 5223 | |
5436fc65 | 5224 | |
66efdff9 JM |
5225 | |
5226 | ||
6bc5b2fa | 5227 | |
018d76dd | 5228 | |
b177bf84 | 5229 | |
5436fc65 C |
5230 | # end-sanitize-gdbtk |
5231 | ||
b236defa FCE |
5232 | # If we find X, set shell vars x_includes and x_libraries to the |
5233 | # paths, otherwise set no_x=yes. | |
5234 | # Uses ac_ vars as temps to allow command line to override cache and checks. | |
5235 | # --without-x overrides everything else, but does not touch the cache. | |
5236 | echo $ac_n "checking for X""... $ac_c" 1>&6 | |
e3009a74 | 5237 | echo "configure:5238: checking for X" >&5 |
b236defa FCE |
5238 | |
5239 | # Check whether --with-x or --without-x was given. | |
5240 | if test "${with_x+set}" = set; then | |
5241 | withval="$with_x" | |
5242 | : | |
5243 | fi | |
5244 | ||
5245 | # $have_x is `yes', `no', `disabled', or empty when we do not yet know. | |
5246 | if test "x$with_x" = xno; then | |
5247 | # The user explicitly disabled X. | |
5248 | have_x=disabled | |
5249 | else | |
5250 | if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then | |
5251 | # Both variables are already set. | |
5252 | have_x=yes | |
5253 | else | |
5254 | if eval "test \"`echo '$''{'ac_cv_have_x'+set}'`\" = set"; then | |
5255 | echo $ac_n "(cached) $ac_c" 1>&6 | |
5256 | else | |
5257 | # One or both of the vars are not set, and there is no cached value. | |
5258 | ac_x_includes=NO ac_x_libraries=NO | |
5259 | rm -fr conftestdir | |
5260 | if mkdir conftestdir; then | |
5261 | cd conftestdir | |
5262 | # Make sure to not put "make" in the Imakefile rules, since we grep it out. | |
5263 | cat > Imakefile <<'EOF' | |
5264 | acfindx: | |
5265 | @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"' | |
5266 | EOF | |
5267 | if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then | |
5268 | # GNU make sometimes prints "make[1]: Entering...", which would confuse us. | |
5269 | eval `${MAKE-make} acfindx 2>/dev/null | grep -v make` | |
5270 | # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR. | |
5271 | for ac_extension in a so sl; do | |
5272 | if test ! -f $ac_im_usrlibdir/libX11.$ac_extension && | |
5273 | test -f $ac_im_libdir/libX11.$ac_extension; then | |
5274 | ac_im_usrlibdir=$ac_im_libdir; break | |
5275 | fi | |
5276 | done | |
5277 | # Screen out bogus values from the imake configuration. They are | |
5278 | # bogus both because they are the default anyway, and because | |
5279 | # using them would break gcc on systems where it needs fixed includes. | |
5280 | case "$ac_im_incroot" in | |
5281 | /usr/include) ;; | |
5282 | *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes="$ac_im_incroot" ;; | |
5283 | esac | |
5284 | case "$ac_im_usrlibdir" in | |
5285 | /usr/lib | /lib) ;; | |
5286 | *) test -d "$ac_im_usrlibdir" && ac_x_libraries="$ac_im_usrlibdir" ;; | |
5287 | esac | |
5288 | fi | |
5289 | cd .. | |
5290 | rm -fr conftestdir | |
5291 | fi | |
5292 | ||
5293 | if test "$ac_x_includes" = NO; then | |
5294 | # Guess where to find include files, by looking for this one X11 .h file. | |
5295 | test -z "$x_direct_test_include" && x_direct_test_include=X11/Intrinsic.h | |
5296 | ||
5297 | # First, try using that file with no special directory specified. | |
5298 | cat > conftest.$ac_ext <<EOF | |
e3009a74 | 5299 | #line 5300 "configure" |
b236defa FCE |
5300 | #include "confdefs.h" |
5301 | #include <$x_direct_test_include> | |
5302 | EOF | |
5303 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
e3009a74 | 5304 | { (eval echo configure:5305: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
ba68ad57 | 5305 | ac_err=`grep -v '^ *+' conftest.out` |
b236defa FCE |
5306 | if test -z "$ac_err"; then |
5307 | rm -rf conftest* | |
5308 | # We can compile using X headers with no special include directory. | |
5309 | ac_x_includes= | |
5310 | else | |
5311 | echo "$ac_err" >&5 | |
5312 | echo "configure: failed program was:" >&5 | |
5313 | cat conftest.$ac_ext >&5 | |
5314 | rm -rf conftest* | |
5315 | # Look for the header file in a standard set of common directories. | |
5316 | # Check X11 before X11Rn because it is often a symlink to the current release. | |
5317 | for ac_dir in \ | |
5318 | /usr/X11/include \ | |
5319 | /usr/X11R6/include \ | |
5320 | /usr/X11R5/include \ | |
5321 | /usr/X11R4/include \ | |
5322 | \ | |
5323 | /usr/include/X11 \ | |
5324 | /usr/include/X11R6 \ | |
5325 | /usr/include/X11R5 \ | |
5326 | /usr/include/X11R4 \ | |
5327 | \ | |
5328 | /usr/local/X11/include \ | |
5329 | /usr/local/X11R6/include \ | |
5330 | /usr/local/X11R5/include \ | |
5331 | /usr/local/X11R4/include \ | |
5332 | \ | |
5333 | /usr/local/include/X11 \ | |
5334 | /usr/local/include/X11R6 \ | |
5335 | /usr/local/include/X11R5 \ | |
5336 | /usr/local/include/X11R4 \ | |
5337 | \ | |
5338 | /usr/X386/include \ | |
5339 | /usr/x386/include \ | |
5340 | /usr/XFree86/include/X11 \ | |
5341 | \ | |
5342 | /usr/include \ | |
5343 | /usr/local/include \ | |
5344 | /usr/unsupported/include \ | |
5345 | /usr/athena/include \ | |
5346 | /usr/local/x11r5/include \ | |
5347 | /usr/lpp/Xamples/include \ | |
5348 | \ | |
5349 | /usr/openwin/include \ | |
5350 | /usr/openwin/share/include \ | |
5351 | ; \ | |
5352 | do | |
5353 | if test -r "$ac_dir/$x_direct_test_include"; then | |
5354 | ac_x_includes=$ac_dir | |
5355 | break | |
5356 | fi | |
5357 | done | |
5358 | fi | |
5359 | rm -f conftest* | |
5360 | fi # $ac_x_includes = NO | |
5361 | ||
5362 | if test "$ac_x_libraries" = NO; then | |
5363 | # Check for the libraries. | |
5364 | ||
5365 | test -z "$x_direct_test_library" && x_direct_test_library=Xt | |
5366 | test -z "$x_direct_test_function" && x_direct_test_function=XtMalloc | |
5367 | ||
5368 | # See if we find them without any special options. | |
5369 | # Don't add to $LIBS permanently. | |
5370 | ac_save_LIBS="$LIBS" | |
5371 | LIBS="-l$x_direct_test_library $LIBS" | |
5372 | cat > conftest.$ac_ext <<EOF | |
e3009a74 | 5373 | #line 5374 "configure" |
b236defa FCE |
5374 | #include "confdefs.h" |
5375 | ||
5376 | int main() { | |
5377 | ${x_direct_test_function}() | |
5378 | ; return 0; } | |
5379 | EOF | |
e3009a74 | 5380 | if { (eval echo configure:5381: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
b236defa FCE |
5381 | rm -rf conftest* |
5382 | LIBS="$ac_save_LIBS" | |
5383 | # We can link X programs with no special library path. | |
5384 | ac_x_libraries= | |
5385 | else | |
5386 | echo "configure: failed program was:" >&5 | |
5387 | cat conftest.$ac_ext >&5 | |
5388 | rm -rf conftest* | |
5389 | LIBS="$ac_save_LIBS" | |
5390 | # First see if replacing the include by lib works. | |
5391 | # Check X11 before X11Rn because it is often a symlink to the current release. | |
5392 | for ac_dir in `echo "$ac_x_includes" | sed s/include/lib/` \ | |
5393 | /usr/X11/lib \ | |
5394 | /usr/X11R6/lib \ | |
5395 | /usr/X11R5/lib \ | |
5396 | /usr/X11R4/lib \ | |
5397 | \ | |
5398 | /usr/lib/X11 \ | |
5399 | /usr/lib/X11R6 \ | |
5400 | /usr/lib/X11R5 \ | |
5401 | /usr/lib/X11R4 \ | |
5402 | \ | |
5403 | /usr/local/X11/lib \ | |
5404 | /usr/local/X11R6/lib \ | |
5405 | /usr/local/X11R5/lib \ | |
5406 | /usr/local/X11R4/lib \ | |
5407 | \ | |
5408 | /usr/local/lib/X11 \ | |
5409 | /usr/local/lib/X11R6 \ | |
5410 | /usr/local/lib/X11R5 \ | |
5411 | /usr/local/lib/X11R4 \ | |
5412 | \ | |
5413 | /usr/X386/lib \ | |
5414 | /usr/x386/lib \ | |
5415 | /usr/XFree86/lib/X11 \ | |
5416 | \ | |
5417 | /usr/lib \ | |
5418 | /usr/local/lib \ | |
5419 | /usr/unsupported/lib \ | |
5420 | /usr/athena/lib \ | |
5421 | /usr/local/x11r5/lib \ | |
5422 | /usr/lpp/Xamples/lib \ | |
5423 | /lib/usr/lib/X11 \ | |
5424 | \ | |
5425 | /usr/openwin/lib \ | |
5426 | /usr/openwin/share/lib \ | |
5427 | ; \ | |
5428 | do | |
5429 | for ac_extension in a so sl; do | |
5430 | if test -r $ac_dir/lib${x_direct_test_library}.$ac_extension; then | |
5431 | ac_x_libraries=$ac_dir | |
5432 | break 2 | |
5433 | fi | |
5434 | done | |
5435 | done | |
5436 | fi | |
5437 | rm -f conftest* | |
5438 | fi # $ac_x_libraries = NO | |
5439 | ||
5440 | if test "$ac_x_includes" = NO || test "$ac_x_libraries" = NO; then | |
5441 | # Didn't find X anywhere. Cache the known absence of X. | |
5442 | ac_cv_have_x="have_x=no" | |
5443 | else | |
5444 | # Record where we found X for the cache. | |
5445 | ac_cv_have_x="have_x=yes \ | |
5446 | ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries" | |
5447 | fi | |
5448 | fi | |
5449 | fi | |
5450 | eval "$ac_cv_have_x" | |
5451 | fi # $with_x != no | |
5452 | ||
5453 | if test "$have_x" != yes; then | |
5454 | echo "$ac_t""$have_x" 1>&6 | |
5455 | no_x=yes | |
5456 | else | |
5457 | # If each of the values was on the command line, it overrides each guess. | |
5458 | test "x$x_includes" = xNONE && x_includes=$ac_x_includes | |
5459 | test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries | |
5460 | # Update the cache value to reflect the command line values. | |
5461 | ac_cv_have_x="have_x=yes \ | |
5462 | ac_x_includes=$x_includes ac_x_libraries=$x_libraries" | |
5463 | echo "$ac_t""libraries $x_libraries, headers $x_includes" 1>&6 | |
5464 | fi | |
5465 | ||
5466 | # start-sanitize-sky | |
5467 | # Enable GPU2 library for MIPS simulator | |
5468 | # Check whether --with-sim-gpu2 or --without-sim-gpu2 was given. | |
5469 | if test "${with_sim_gpu2+set}" = set; then | |
5470 | withval="$with_sim_gpu2" | |
bd5eafcd FCE |
5471 | case "${target}" in |
5472 | mips*-sky-*) | |
5473 | if test -d "${withval}" | |
5474 | then | |
f915cc91 | 5475 | LIBS="${LIBS} -L${withval}/lib -lgpu2 -L${x_libraries} -lX11 -lXext" |
bd5eafcd FCE |
5476 | else |
5477 | echo "configure: warning: Directory ${withval} does not exist." 1>&2 | |
5478 | fi ;; | |
5479 | *) echo "configure: warning: --with-sim-gpu2 option invalid for target ${target}" 1>&2 | |
5480 | esac | |
b236defa | 5481 | fi |
75a55dc3 JM |
5482 | |
5483 | # Enable target accurate FP library | |
5484 | # Check whether --with-sim-funit or --without-sim-funit was given. | |
5485 | if test "${with_sim_funit+set}" = set; then | |
5486 | withval="$with_sim_funit" | |
5487 | case "${target}" in | |
5488 | mips*-sky-*) | |
5489 | if test -d "${withval}" | |
5490 | then | |
5491 | LIBS="${LIBS} -L${withval}/lib -lfunit" | |
5492 | else | |
5493 | echo "configure: warning: Directory ${withval} does not exist." 1>&2 | |
5494 | fi ;; | |
5495 | *) echo "configure: warning: --with-sim-funit option invalid for target ${target}" 1>&2 | |
5496 | esac | |
5497 | fi | |
b236defa FCE |
5498 | # end-sanitize-sky |
5499 | ||
15125484 | 5500 | echo $ac_n "checking for wctype in -lw""... $ac_c" 1>&6 |
e3009a74 | 5501 | echo "configure:5502: checking for wctype in -lw" >&5 |
15125484 JM |
5502 | ac_lib_var=`echo w'_'wctype | sed 'y%./+-%__p_%'` |
5503 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then | |
5504 | echo $ac_n "(cached) $ac_c" 1>&6 | |
5505 | else | |
5506 | ac_save_LIBS="$LIBS" | |
5507 | LIBS="-lw $LIBS" | |
5508 | cat > conftest.$ac_ext <<EOF | |
e3009a74 | 5509 | #line 5510 "configure" |
15125484 JM |
5510 | #include "confdefs.h" |
5511 | /* Override any gcc2 internal prototype to avoid an error. */ | |
5512 | /* We use char because int might match the return type of a gcc2 | |
5513 | builtin and then its argument prototype would still apply. */ | |
5514 | char wctype(); | |
5515 | ||
5516 | int main() { | |
5517 | wctype() | |
5518 | ; return 0; } | |
5519 | EOF | |
e3009a74 | 5520 | if { (eval echo configure:5521: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then |
15125484 JM |
5521 | rm -rf conftest* |
5522 | eval "ac_cv_lib_$ac_lib_var=yes" | |
5523 | else | |
5524 | echo "configure: failed program was:" >&5 | |
5525 | cat conftest.$ac_ext >&5 | |
5526 | rm -rf conftest* | |
5527 | eval "ac_cv_lib_$ac_lib_var=no" | |
5528 | fi | |
5529 | rm -f conftest* | |
5530 | LIBS="$ac_save_LIBS" | |
5531 | ||
5532 | fi | |
5533 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then | |
5534 | echo "$ac_t""yes" 1>&6 | |
5535 | LIBS="$LIBS -lw" | |
5536 | else | |
5537 | echo "$ac_t""no" 1>&6 | |
5538 | fi | |
5539 | ||
5540 | ||
5436fc65 C |
5541 | |
5542 | ||
5543 | ||
5544 | ||
018d76dd | 5545 | |
c7bb1531 | 5546 | |
1d5eb137 FF |
5547 | # Begin stuff to support --enable-shared |
5548 | # Check whether --enable-shared or --disable-shared was given. | |
5549 | if test "${enable_shared+set}" = set; then | |
5550 | enableval="$enable_shared" | |
5551 | case "${enableval}" in | |
5552 | yes) shared=true ;; | |
5553 | no) shared=false ;; | |
5554 | *) shared=true ;; | |
5555 | esac | |
5556 | fi | |
5557 | ||
5558 | HLDFLAGS= | |
5559 | HLDENV= | |
5560 | # If we have shared libraries, try to set rpath reasonably. | |
5561 | if test "${shared}" = "true"; then | |
5562 | case "${host}" in | |
5563 | *-*-hpux*) | |
5564 | HLDFLAGS='-Wl,+s,+b,$(libdir)' | |
5565 | ;; | |
5566 | *-*-irix5* | *-*-irix6*) | |
5567 | HLDFLAGS='-Wl,-rpath,$(libdir)' | |
5568 | ;; | |
5569 | *-*-linux*aout*) | |
5570 | ;; | |
8ddf07a2 | 5571 | *-*-linux* | *-pc-linux-gnu) |
1d5eb137 FF |
5572 | HLDFLAGS='-Wl,-rpath,$(libdir)' |
5573 | ;; | |
5574 | *-*-solaris*) | |
5575 | HLDFLAGS='-R $(libdir)' | |
5576 | ;; | |
5577 | *-*-sysv4*) | |
5578 | HLDENV='if test -z "$${LD_RUN_PATH}"; then LD_RUN_PATH=$(libdir); else LD_RUN_PATH=$${LD_RUN_PATH}:$(libdir); fi; export LD_RUN_PATH;' | |
5579 | ;; | |
5580 | esac | |
5581 | fi | |
5582 | ||
5583 | # On SunOS, if the linker supports the -rpath option, use it to | |
5584 | # prevent ../bfd and ../opcodes from being included in the run time | |
5585 | # search path. | |
5586 | case "${host}" in | |
5587 | *-*-sunos*) | |
5588 | echo 'main () { }' > conftest.c | |
5589 | ${CC} -o conftest -Wl,-rpath= conftest.c >/dev/null 2>conftest.t | |
5590 | if grep 'unrecognized' conftest.t >/dev/null 2>&1; then | |
5591 | : | |
5592 | elif grep 'No such file' conftest.t >/dev/null 2>&1; then | |
5593 | : | |
5594 | elif grep 'do not mix' conftest.t >/dev/null 2>&1; then | |
5595 | : | |
074d813d PS |
5596 | elif grep 'some text already loaded' conftest.t >/dev/null 2>&1; then |
5597 | : | |
1d5eb137 FF |
5598 | elif test "${shared}" = "true"; then |
5599 | HLDFLAGS='-Wl,-rpath=$(libdir)' | |
5600 | else | |
5601 | HLDFLAGS='-Wl,-rpath=' | |
5602 | fi | |
5603 | rm -f conftest.t conftest.c conftest | |
5604 | ;; | |
5605 | esac | |
5606 | ||
5607 | ||
5608 | # End stuff to support --enable-shared | |
5609 | ||
7c40dd08 DE |
5610 | # target_subdir is used by the testsuite to find the target libraries. |
5611 | target_subdir= | |
5612 | if test "${host}" != "${target}"; then | |
5613 | target_subdir="${target_alias}/" | |
5614 | fi | |
5615 | ||
5436fc65 | 5616 | |
5f107900 | 5617 | frags= |
5436fc65 C |
5618 | host_makefile_frag=${srcdir}/config/${gdb_host_cpu}/${gdb_host}.mh |
5619 | if test ! -f ${host_makefile_frag}; then | |
5620 | { echo "configure: error: "*** Gdb does not support host ${host}"" 1>&2; exit 1; } | |
5621 | fi | |
5f107900 | 5622 | frags="$frags $host_makefile_frag" |
5436fc65 C |
5623 | |
5624 | target_makefile_frag=${srcdir}/config/${gdb_target_cpu}/${gdb_target}.mt | |
5625 | if test ! -f ${target_makefile_frag}; then | |
5626 | { echo "configure: error: "*** Gdb does not support target ${target}"" 1>&2; exit 1; } | |
5627 | fi | |
5f107900 | 5628 | frags="$frags $target_makefile_frag" |
5436fc65 C |
5629 | |
5630 | ||
5631 | ||
5632 | ||
5633 | ||
094fd4ae C |
5634 | hostfile=`sed -n ' |
5635 | s/XM_FILE[ ]*=[ ]*\([^ ]*\)/\1/p | |
5636 | ' ${host_makefile_frag}` | |
5436fc65 | 5637 | |
094fd4ae C |
5638 | targetfile=`sed -n ' |
5639 | s/TM_FILE[ ]*=[ ]*\([^ ]*\)/\1/p | |
5640 | ' ${target_makefile_frag}` | |
5436fc65 C |
5641 | |
5642 | # these really aren't orthogonal true/false values of the same condition, | |
5643 | # but shells are slow enough that I like to reuse the test conditions | |
5644 | # whenever possible | |
5645 | if test "${target}" = "${host}"; then | |
094fd4ae C |
5646 | nativefile=`sed -n ' |
5647 | s/NAT_FILE[ ]*=[ ]*\([^ ]*\)/\1/p | |
5648 | ' ${host_makefile_frag}` | |
33ef0f93 | 5649 | # else |
5436fc65 | 5650 | # GDBserver is only useful in a "native" enviroment |
33ef0f93 | 5651 | # configdirs=`echo $configdirs | sed 's/gdbserver//'` |
5436fc65 C |
5652 | fi |
5653 | ||
094fd4ae | 5654 | |
5436fc65 C |
5655 | # If hostfile (XM_FILE) and/or targetfile (TM_FILE) and/or nativefile |
5656 | # (NAT_FILE) is not set in config/*/*.m[ht] files, we don't make the | |
5657 | # corresponding links. But we have to remove the xm.h files and tm.h | |
5658 | # files anyway, e.g. when switching from "configure host" to | |
5659 | # "configure none". | |
5660 | ||
5661 | files= | |
5662 | links= | |
5663 | rm -f xm.h | |
5664 | if test "${hostfile}" != ""; then | |
5665 | files="${files} config/${gdb_host_cpu}/${hostfile}" | |
5666 | links="${links} xm.h" | |
5667 | fi | |
5668 | rm -f tm.h | |
5669 | if test "${targetfile}" != ""; then | |
5670 | files="${files} config/${gdb_target_cpu}/${targetfile}" | |
5671 | links="${links} tm.h" | |
5672 | fi | |
5673 | rm -f nm.h | |
5674 | if test "${nativefile}" != ""; then | |
5675 | files="${files} config/${gdb_host_cpu}/${nativefile}" | |
5676 | links="${links} nm.h" | |
5677 | else | |
5678 | # A cross-only configuration. | |
5679 | files="${files} config/nm-empty.h" | |
5680 | links="${links} nm.h" | |
5681 | fi | |
5682 | # start-sanitize-gdbtk | |
99174711 | 5683 | echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6 |
e3009a74 | 5684 | echo "configure:5685: checking whether ln -s works" >&5 |
99174711 JM |
5685 | if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then |
5686 | echo $ac_n "(cached) $ac_c" 1>&6 | |
5687 | else | |
5688 | rm -f conftestdata | |
5689 | if ln -s X conftestdata 2>/dev/null | |
5690 | then | |
5691 | rm -f conftestdata | |
5692 | ac_cv_prog_LN_S="ln -s" | |
5693 | else | |
5694 | ac_cv_prog_LN_S=ln | |
5695 | fi | |
5696 | fi | |
5697 | LN_S="$ac_cv_prog_LN_S" | |
5698 | if test "$ac_cv_prog_LN_S" = "ln -s"; then | |
5699 | echo "$ac_t""yes" 1>&6 | |
5700 | else | |
5701 | echo "$ac_t""no" 1>&6 | |
5702 | fi | |
5436fc65 C |
5703 | |
5704 | # Make it possible to use the GUI without doing a full install | |
99174711 JM |
5705 | if test "${enable_gdbtk}" = "yes" -a ! -d gdbtcl ; then |
5706 | if test "$LN_S" = "ln -s" -a ! -f gdbtcl ; then | |
5707 | echo linking $srcdir/gdbtcl to gdbtcl | |
5708 | $LN_S $srcdir/gdbtcl gdbtcl | |
5709 | else | |
5710 | echo Warning: Unable to link $srcdir/gdbtcl to gdbtcl. You will need to do a | |
5711 | echo " " make install before you are able to run the GUI. | |
5712 | fi | |
5436fc65 C |
5713 | fi |
5714 | # end-sanitize-gdbtk | |
5715 | ||
5716 | ||
5717 | ||
3fbb8cde | 5718 | echo $ac_n "checking for Cygwin32 environment""... $ac_c" 1>&6 |
e3009a74 | 5719 | echo "configure:5720: checking for Cygwin32 environment" >&5 |
3fbb8cde ILT |
5720 | if eval "test \"`echo '$''{'am_cv_cygwin32'+set}'`\" = set"; then |
5721 | echo $ac_n "(cached) $ac_c" 1>&6 | |
5722 | else | |
5723 | cat > conftest.$ac_ext <<EOF | |
e3009a74 | 5724 | #line 5725 "configure" |
3fbb8cde ILT |
5725 | #include "confdefs.h" |
5726 | ||
5727 | int main() { | |
b2b1c5da | 5728 | return __CYGWIN32__; |
3fbb8cde ILT |
5729 | ; return 0; } |
5730 | EOF | |
e3009a74 | 5731 | if { (eval echo configure:5732: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
3fbb8cde ILT |
5732 | rm -rf conftest* |
5733 | am_cv_cygwin32=yes | |
5734 | else | |
5735 | echo "configure: failed program was:" >&5 | |
5736 | cat conftest.$ac_ext >&5 | |
5737 | rm -rf conftest* | |
5738 | am_cv_cygwin32=no | |
5739 | fi | |
5740 | rm -f conftest* | |
5741 | rm -f conftest* | |
5742 | fi | |
5743 | ||
5744 | echo "$ac_t""$am_cv_cygwin32" 1>&6 | |
5745 | CYGWIN32= | |
5746 | test "$am_cv_cygwin32" = yes && CYGWIN32=yes | |
b2b1c5da | 5747 | echo $ac_n "checking for Mingw32 environment""... $ac_c" 1>&6 |
e3009a74 | 5748 | echo "configure:5749: checking for Mingw32 environment" >&5 |
b2b1c5da MM |
5749 | if eval "test \"`echo '$''{'am_cv_mingw32'+set}'`\" = set"; then |
5750 | echo $ac_n "(cached) $ac_c" 1>&6 | |
5751 | else | |
5752 | cat > conftest.$ac_ext <<EOF | |
e3009a74 | 5753 | #line 5754 "configure" |
b2b1c5da MM |
5754 | #include "confdefs.h" |
5755 | ||
5756 | int main() { | |
5757 | return __MINGW32__; | |
5758 | ; return 0; } | |
5759 | EOF | |
e3009a74 | 5760 | if { (eval echo configure:5761: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
b2b1c5da MM |
5761 | rm -rf conftest* |
5762 | am_cv_mingw32=yes | |
5763 | else | |
5764 | echo "configure: failed program was:" >&5 | |
5765 | cat conftest.$ac_ext >&5 | |
5766 | rm -rf conftest* | |
5767 | am_cv_mingw32=no | |
5768 | fi | |
5769 | rm -f conftest* | |
5770 | rm -f conftest* | |
5771 | fi | |
5772 | ||
5773 | echo "$ac_t""$am_cv_mingw32" 1>&6 | |
5774 | MINGW32= | |
5775 | test "$am_cv_mingw32" = yes && MINGW32=yes | |
5776 | ||
98fa4ade GN |
5777 | |
5778 | echo $ac_n "checking for executable suffix""... $ac_c" 1>&6 | |
e3009a74 | 5779 | echo "configure:5780: checking for executable suffix" >&5 |
98fa4ade GN |
5780 | if eval "test \"`echo '$''{'am_cv_exeext'+set}'`\" = set"; then |
5781 | echo $ac_n "(cached) $ac_c" 1>&6 | |
5782 | else | |
dd600735 | 5783 | if test "$CYGWIN32" = yes || test "$MINGW32" = yes; then |
98fa4ade GN |
5784 | am_cv_exeext=.exe |
5785 | else | |
5786 | cat > am_c_test.c << 'EOF' | |
5787 | int main() { | |
5788 | /* Nothing needed here */ | |
5789 | } | |
5790 | EOF | |
5791 | ${CC-cc} -o am_c_test $CFLAGS $CPPFLAGS $LDFLAGS am_c_test.c $LIBS 1>&5 | |
75a55dc3 JM |
5792 | am_cv_exeext= |
5793 | for file in am_c_test.*; do | |
5794 | case $file in | |
5795 | *.c) ;; | |
5796 | *.o) ;; | |
5797 | *) am_cv_exeext=`echo $file | sed -e s/am_c_test//` ;; | |
5798 | esac | |
5799 | done | |
98fa4ade GN |
5800 | rm -f am_c_test* |
5801 | fi | |
5802 | ||
5803 | test x"${am_cv_exeext}" = x && am_cv_exeext=no | |
5804 | fi | |
5805 | EXEEXT="" | |
5806 | test x"${am_cv_exeext}" != xno && EXEEXT=${am_cv_exeext} | |
5807 | echo "$ac_t""${am_cv_exeext}" 1>&6 | |
5808 | ||
5809 | ||
5436fc65 C |
5810 | subdirs="$configdirs" |
5811 | ||
5812 | trap '' 1 2 15 | |
5813 | cat > confcache <<\EOF | |
5814 | # This file is a shell script that caches the results of configure | |
5815 | # tests run on this system so they can be shared between configure | |
5816 | # scripts and configure runs. It is not useful on other systems. | |
5817 | # If it contains results you don't want to keep, you may remove or edit it. | |
5818 | # | |
5819 | # By default, configure uses ./config.cache as the cache file, | |
5820 | # creating it if it does not exist already. You can give configure | |
5821 | # the --cache-file=FILE option to use a different cache file; that is | |
5822 | # what configure does when it calls configure scripts in | |
5823 | # subdirectories, so they share the cache. | |
5824 | # Giving --cache-file=/dev/null disables caching, for debugging configure. | |
5825 | # config.status only pays attention to the cache file if you give it the | |
5826 | # --recheck option to rerun configure. | |
5827 | # | |
5828 | EOF | |
bfde4a67 SG |
5829 | # The following way of writing the cache mishandles newlines in values, |
5830 | # but we know of no workaround that is simple, portable, and efficient. | |
5831 | # So, don't put newlines in cache variables' values. | |
5436fc65 C |
5832 | # Ultrix sh set writes to stderr and can't be redirected directly, |
5833 | # and sets the high bit in the cache file unless we assign to the vars. | |
5834 | (set) 2>&1 | | |
ba68ad57 | 5835 | case `(ac_space=' '; set) 2>&1` in |
bfde4a67 SG |
5836 | *ac_space=\ *) |
5837 | # `set' does not quote correctly, so add quotes (double-quote substitution | |
5838 | # turns \\\\ into \\, and sed turns \\ into \). | |
5839 | sed -n \ | |
5840 | -e "s/'/'\\\\''/g" \ | |
5841 | -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p" | |
5842 | ;; | |
5843 | *) | |
5844 | # `set' quotes correctly as required by POSIX, so do not add quotes. | |
5845 | sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p' | |
5846 | ;; | |
5847 | esac >> confcache | |
5436fc65 C |
5848 | if cmp -s $cache_file confcache; then |
5849 | : | |
5850 | else | |
5851 | if test -w $cache_file; then | |
5852 | echo "updating cache $cache_file" | |
5853 | cat confcache > $cache_file | |
5854 | else | |
5855 | echo "not updating unwritable cache $cache_file" | |
5856 | fi | |
5857 | fi | |
5858 | rm -f confcache | |
5859 | ||
5860 | trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 | |
5861 | ||
5862 | test "x$prefix" = xNONE && prefix=$ac_default_prefix | |
5863 | # Let make expand exec_prefix. | |
5864 | test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' | |
5865 | ||
5866 | # Any assignment to VPATH causes Sun make to only execute | |
5867 | # the first set of double-colon rules, so remove it if not needed. | |
5868 | # If there is a colon in the path, we need to keep it. | |
5869 | if test "x$srcdir" = x.; then | |
5870 | ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d' | |
5871 | fi | |
5872 | ||
5873 | trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15 | |
5874 | ||
db210d08 | 5875 | DEFS=-DHAVE_CONFIG_H |
5436fc65 C |
5876 | |
5877 | # Without the "./", some shells look in PATH for config.status. | |
5878 | : ${CONFIG_STATUS=./config.status} | |
5879 | ||
5880 | echo creating $CONFIG_STATUS | |
5881 | rm -f $CONFIG_STATUS | |
5882 | cat > $CONFIG_STATUS <<EOF | |
5883 | #! /bin/sh | |
5884 | # Generated automatically by configure. | |
5885 | # Run this file to recreate the current configuration. | |
5886 | # This directory was configured as follows, | |
5887 | # on host `(hostname || uname -n) 2>/dev/null | sed 1q`: | |
5888 | # | |
5889 | # $0 $ac_configure_args | |
5890 | # | |
5891 | # Compiler output produced by configure, useful for debugging | |
5892 | # configure, is in ./config.log if it exists. | |
5893 | ||
5894 | ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]" | |
5895 | for ac_option | |
5896 | do | |
5897 | case "\$ac_option" in | |
5898 | -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) | |
5899 | echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion" | |
5900 | exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;; | |
5901 | -version | --version | --versio | --versi | --vers | --ver | --ve | --v) | |
ba68ad57 | 5902 | echo "$CONFIG_STATUS generated by autoconf version 2.12" |
5436fc65 C |
5903 | exit 0 ;; |
5904 | -help | --help | --hel | --he | --h) | |
5905 | echo "\$ac_cs_usage"; exit 0 ;; | |
5906 | *) echo "\$ac_cs_usage"; exit 1 ;; | |
5907 | esac | |
5908 | done | |
5909 | ||
5910 | ac_given_srcdir=$srcdir | |
5911 | ac_given_INSTALL="$INSTALL" | |
5912 | ||
0cb7d01d | 5913 | trap 'rm -fr `echo "Makefile .gdbinit:gdbinit.in config.h:config.in" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 |
1a7b4b7c DE |
5914 | EOF |
5915 | cat >> $CONFIG_STATUS <<EOF | |
5436fc65 | 5916 | |
1a7b4b7c DE |
5917 | # Protect against being on the right side of a sed subst in config.status. |
5918 | sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g; | |
5919 | s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF | |
5436fc65 C |
5920 | $ac_vpsub |
5921 | $extrasub | |
5922 | s%@CFLAGS@%$CFLAGS%g | |
5923 | s%@CPPFLAGS@%$CPPFLAGS%g | |
5924 | s%@CXXFLAGS@%$CXXFLAGS%g | |
5925 | s%@DEFS@%$DEFS%g | |
5926 | s%@LDFLAGS@%$LDFLAGS%g | |
5927 | s%@LIBS@%$LIBS%g | |
5928 | s%@exec_prefix@%$exec_prefix%g | |
5929 | s%@prefix@%$prefix%g | |
5930 | s%@program_transform_name@%$program_transform_name%g | |
1a7b4b7c DE |
5931 | s%@bindir@%$bindir%g |
5932 | s%@sbindir@%$sbindir%g | |
5933 | s%@libexecdir@%$libexecdir%g | |
5934 | s%@datadir@%$datadir%g | |
5935 | s%@sysconfdir@%$sysconfdir%g | |
5936 | s%@sharedstatedir@%$sharedstatedir%g | |
5937 | s%@localstatedir@%$localstatedir%g | |
5938 | s%@libdir@%$libdir%g | |
5939 | s%@includedir@%$includedir%g | |
5940 | s%@oldincludedir@%$oldincludedir%g | |
5941 | s%@infodir@%$infodir%g | |
5942 | s%@mandir@%$mandir%g | |
5436fc65 C |
5943 | s%@CC@%$CC%g |
5944 | s%@CPP@%$CPP%g | |
35ce4f08 | 5945 | s%@DLLTOOL@%$DLLTOOL%g |
5436fc65 C |
5946 | s%@host@%$host%g |
5947 | s%@host_alias@%$host_alias%g | |
5948 | s%@host_cpu@%$host_cpu%g | |
5949 | s%@host_vendor@%$host_vendor%g | |
5950 | s%@host_os@%$host_os%g | |
0579b53d GN |
5951 | s%@target@%$target%g |
5952 | s%@target_alias@%$target_alias%g | |
5953 | s%@target_cpu@%$target_cpu%g | |
5954 | s%@target_vendor@%$target_vendor%g | |
5955 | s%@target_os@%$target_os%g | |
5436fc65 C |
5956 | s%@build@%$build%g |
5957 | s%@build_alias@%$build_alias%g | |
5958 | s%@build_cpu@%$build_cpu%g | |
5959 | s%@build_vendor@%$build_vendor%g | |
5960 | s%@build_os@%$build_os%g | |
fcfc3c0c TT |
5961 | s%@SET_MAKE@%$SET_MAKE%g |
5962 | s%@RANLIB@%$RANLIB%g | |
5963 | s%@ALLOCA@%$ALLOCA%g | |
5964 | s%@USE_NLS@%$USE_NLS%g | |
5965 | s%@MSGFMT@%$MSGFMT%g | |
5966 | s%@GMSGFMT@%$GMSGFMT%g | |
5967 | s%@XGETTEXT@%$XGETTEXT%g | |
5968 | s%@USE_INCLUDED_LIBINTL@%$USE_INCLUDED_LIBINTL%g | |
5969 | s%@CATALOGS@%$CATALOGS%g | |
5970 | s%@CATOBJEXT@%$CATOBJEXT%g | |
5971 | s%@DATADIRNAME@%$DATADIRNAME%g | |
5972 | s%@GMOFILES@%$GMOFILES%g | |
5973 | s%@INSTOBJEXT@%$INSTOBJEXT%g | |
5974 | s%@INTLDEPS@%$INTLDEPS%g | |
5975 | s%@INTLLIBS@%$INTLLIBS%g | |
5976 | s%@INTLOBJS@%$INTLOBJS%g | |
5977 | s%@POFILES@%$POFILES%g | |
5978 | s%@POSUB@%$POSUB%g | |
5979 | s%@INCLUDE_LOCALE_H@%$INCLUDE_LOCALE_H%g | |
5980 | s%@GT_NO@%$GT_NO%g | |
5981 | s%@GT_YES@%$GT_YES%g | |
5982 | s%@MKINSTALLDIRS@%$MKINSTALLDIRS%g | |
5983 | s%@l@%$l%g | |
0579b53d GN |
5984 | s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g |
5985 | s%@INSTALL_DATA@%$INSTALL_DATA%g | |
d8efbc66 | 5986 | s%@AR@%$AR%g |
d8efbc66 FF |
5987 | s%@YACC@%$YACC%g |
5988 | s%@AWK@%$AWK%g | |
4915acad | 5989 | s%@CONFIG_LDFLAGS@%$CONFIG_LDFLAGS%g |
ba68ad57 | 5990 | s%@WARN_CFLAGS@%$WARN_CFLAGS%g |
0728afad FF |
5991 | s%@MMALLOC_CFLAGS@%$MMALLOC_CFLAGS%g |
5992 | s%@MMALLOC@%$MMALLOC%g | |
2476848a | 5993 | s%@ENABLE_IDE@%$ENABLE_IDE%g |
c076f1ed DM |
5994 | s%@FOUNDRY_LIB_BASE@%$FOUNDRY_LIB_BASE%g |
5995 | s%@LIBGUI@%$LIBGUI%g | |
5996 | s%@GUI_CFLAGS_X@%$GUI_CFLAGS_X%g | |
5997 | s%@IDE_CFLAGS_X@%$IDE_CFLAGS_X%g | |
5998 | s%@IDE_X@%$IDE_X%g | |
5999 | s%@LIBIDETCL@%$LIBIDETCL%g | |
6000 | s%@LIBIDE@%$LIBIDE%g | |
6001 | s%@IDE_DEPS@%$IDE_DEPS%g | |
9b119644 ILT |
6002 | s%@WIN32LIBS@%$WIN32LIBS%g |
6003 | s%@WIN32LDAPP@%$WIN32LDAPP%g | |
929db6e5 | 6004 | s%@WINDRES@%$WINDRES%g |
047465fd TT |
6005 | s%@TCL_VERSION@%$TCL_VERSION%g |
6006 | s%@TCL_MAJOR_VERSION@%$TCL_MAJOR_VERSION%g | |
6007 | s%@TCL_MINOR_VERSION@%$TCL_MINOR_VERSION%g | |
6008 | s%@TCL_CC@%$TCL_CC%g | |
6009 | s%@TCL_DEFS@%$TCL_DEFS%g | |
6010 | s%@TCL_SHLIB_CFLAGS@%$TCL_SHLIB_CFLAGS%g | |
6011 | s%@TCL_SHLIB_LD@%$TCL_SHLIB_LD%g | |
6012 | s%@TCL_SHLIB_LD_LIBS@%$TCL_SHLIB_LD_LIBS%g | |
6013 | s%@TCL_SHLIB_SUFFIX@%$TCL_SHLIB_SUFFIX%g | |
6014 | s%@TCL_DL_LIBS@%$TCL_DL_LIBS%g | |
6015 | s%@TCL_LD_FLAGS@%$TCL_LD_FLAGS%g | |
6016 | s%@TCL_LD_SEARCH_FLAGS@%$TCL_LD_SEARCH_FLAGS%g | |
6017 | s%@TCL_COMPAT_OBJS@%$TCL_COMPAT_OBJS%g | |
6018 | s%@TCL_RANLIB@%$TCL_RANLIB%g | |
6019 | s%@TCL_BUILD_LIB_SPEC@%$TCL_BUILD_LIB_SPEC%g | |
6020 | s%@TCL_LIB_SPEC@%$TCL_LIB_SPEC%g | |
6021 | s%@TCL_LIB_VERSIONS_OK@%$TCL_LIB_VERSIONS_OK%g | |
6022 | s%@TK_VERSION@%$TK_VERSION%g | |
6023 | s%@TK_DEFS@%$TK_DEFS%g | |
9b119644 | 6024 | s%@TK_BUILD_INCLUDES@%$TK_BUILD_INCLUDES%g |
047465fd TT |
6025 | s%@TK_XINCLUDES@%$TK_XINCLUDES%g |
6026 | s%@TK_XLIBSW@%$TK_XLIBSW%g | |
6027 | s%@TK_BUILD_LIB_SPEC@%$TK_BUILD_LIB_SPEC%g | |
6028 | s%@TK_LIB_SPEC@%$TK_LIB_SPEC%g | |
5436fc65 | 6029 | s%@TCLHDIR@%$TCLHDIR%g |
4e327047 | 6030 | s%@TKHDIR@%$TKHDIR%g |
2476848a MH |
6031 | s%@ITCLHDIR@%$ITCLHDIR%g |
6032 | s%@ITCLLIB@%$ITCLLIB%g | |
6033 | s%@TIXHDIR@%$TIXHDIR%g | |
5436fc65 | 6034 | s%@ENABLE_GDBTK@%$ENABLE_GDBTK%g |
047465fd | 6035 | s%@X_CFLAGS@%$X_CFLAGS%g |
a2b63bbd | 6036 | s%@X_LDFLAGS@%$X_LDFLAGS%g |
047465fd | 6037 | s%@X_LIBS@%$X_LIBS%g |
6bc5b2fa | 6038 | s%@TIXLIB@%$TIXLIB%g |
018d76dd | 6039 | s%@TIX_DEPS@%$TIX_DEPS%g |
b177bf84 | 6040 | s%@GDBTKLIBS@%$GDBTKLIBS%g |
5436fc65 | 6041 | s%@ENABLE_CFLAGS@%$ENABLE_CFLAGS%g |
6c310da8 | 6042 | s%@CONFIG_OBS@%$CONFIG_OBS%g |
018d76dd | 6043 | s%@CONFIG_DEPS@%$CONFIG_DEPS%g |
c7bb1531 | 6044 | s%@CONFIG_SRCS@%$CONFIG_SRCS%g |
1d5eb137 FF |
6045 | s%@HLDFLAGS@%$HLDFLAGS%g |
6046 | s%@HLDENV@%$HLDENV%g | |
7c40dd08 | 6047 | s%@target_subdir@%$target_subdir%g |
5436fc65 C |
6048 | /@host_makefile_frag@/r $host_makefile_frag |
6049 | s%@host_makefile_frag@%%g | |
6050 | /@target_makefile_frag@/r $target_makefile_frag | |
6051 | s%@target_makefile_frag@%%g | |
5f107900 | 6052 | s%@frags@%$frags%g |
99174711 | 6053 | s%@LN_S@%$LN_S%g |
3fbb8cde | 6054 | s%@EXEEXT@%$EXEEXT%g |
5436fc65 C |
6055 | s%@subdirs@%$subdirs%g |
6056 | ||
6057 | CEOF | |
6058 | EOF | |
bfde4a67 SG |
6059 | |
6060 | cat >> $CONFIG_STATUS <<\EOF | |
6061 | ||
6062 | # Split the substitutions into bite-sized pieces for seds with | |
6063 | # small command number limits, like on Digital OSF/1 and HP-UX. | |
6064 | ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script. | |
6065 | ac_file=1 # Number of current file. | |
6066 | ac_beg=1 # First line for current file. | |
6067 | ac_end=$ac_max_sed_cmds # Line after last line for current file. | |
6068 | ac_more_lines=: | |
6069 | ac_sed_cmds="" | |
6070 | while $ac_more_lines; do | |
6071 | if test $ac_beg -gt 1; then | |
6072 | sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file | |
6073 | else | |
6074 | sed "${ac_end}q" conftest.subs > conftest.s$ac_file | |
6075 | fi | |
6076 | if test ! -s conftest.s$ac_file; then | |
6077 | ac_more_lines=false | |
6078 | rm -f conftest.s$ac_file | |
6079 | else | |
6080 | if test -z "$ac_sed_cmds"; then | |
6081 | ac_sed_cmds="sed -f conftest.s$ac_file" | |
6082 | else | |
6083 | ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file" | |
6084 | fi | |
6085 | ac_file=`expr $ac_file + 1` | |
6086 | ac_beg=$ac_end | |
6087 | ac_end=`expr $ac_end + $ac_max_sed_cmds` | |
6088 | fi | |
6089 | done | |
6090 | if test -z "$ac_sed_cmds"; then | |
6091 | ac_sed_cmds=cat | |
6092 | fi | |
6093 | EOF | |
6094 | ||
5436fc65 C |
6095 | cat >> $CONFIG_STATUS <<EOF |
6096 | ||
0cb7d01d | 6097 | CONFIG_FILES=\${CONFIG_FILES-"Makefile .gdbinit:gdbinit.in"} |
5436fc65 C |
6098 | EOF |
6099 | cat >> $CONFIG_STATUS <<\EOF | |
6100 | for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then | |
bfde4a67 | 6101 | # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". |
5436fc65 | 6102 | case "$ac_file" in |
bfde4a67 | 6103 | *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'` |
5436fc65 C |
6104 | ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; |
6105 | *) ac_file_in="${ac_file}.in" ;; | |
6106 | esac | |
6107 | ||
bfde4a67 | 6108 | # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories. |
5436fc65 C |
6109 | |
6110 | # Remove last slash and all that follows it. Not all systems have dirname. | |
6111 | ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` | |
6112 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then | |
6113 | # The file is in a subdirectory. | |
6114 | test ! -d "$ac_dir" && mkdir "$ac_dir" | |
6115 | ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`" | |
6116 | # A "../" for each directory in $ac_dir_suffix. | |
6117 | ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'` | |
6118 | else | |
6119 | ac_dir_suffix= ac_dots= | |
6120 | fi | |
6121 | ||
6122 | case "$ac_given_srcdir" in | |
6123 | .) srcdir=. | |
6124 | if test -z "$ac_dots"; then top_srcdir=. | |
6125 | else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;; | |
6126 | /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;; | |
6127 | *) # Relative path. | |
6128 | srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix" | |
6129 | top_srcdir="$ac_dots$ac_given_srcdir" ;; | |
6130 | esac | |
6131 | ||
6132 | case "$ac_given_INSTALL" in | |
6133 | [/$]*) INSTALL="$ac_given_INSTALL" ;; | |
6134 | *) INSTALL="$ac_dots$ac_given_INSTALL" ;; | |
6135 | esac | |
bfde4a67 | 6136 | |
5436fc65 C |
6137 | echo creating "$ac_file" |
6138 | rm -f "$ac_file" | |
6139 | configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure." | |
6140 | case "$ac_file" in | |
6141 | *Makefile*) ac_comsub="1i\\ | |
6142 | # $configure_input" ;; | |
6143 | *) ac_comsub= ;; | |
6144 | esac | |
bfde4a67 SG |
6145 | |
6146 | ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"` | |
5436fc65 C |
6147 | sed -e "$ac_comsub |
6148 | s%@configure_input@%$configure_input%g | |
6149 | s%@srcdir@%$srcdir%g | |
6150 | s%@top_srcdir@%$top_srcdir%g | |
6151 | s%@INSTALL@%$INSTALL%g | |
bfde4a67 | 6152 | " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file |
5436fc65 | 6153 | fi; done |
bfde4a67 | 6154 | rm -f conftest.s* |
5436fc65 | 6155 | |
db210d08 FF |
6156 | # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where |
6157 | # NAME is the cpp macro being defined and VALUE is the value it is being given. | |
6158 | # | |
6159 | # ac_d sets the value in "#define NAME VALUE" lines. | |
6160 | ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)' | |
6161 | ac_dB='\([ ][ ]*\)[^ ]*%\1#\2' | |
6162 | ac_dC='\3' | |
6163 | ac_dD='%g' | |
6164 | # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE". | |
6165 | ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' | |
6166 | ac_uB='\([ ]\)%\1#\2define\3' | |
6167 | ac_uC=' ' | |
6168 | ac_uD='\4%g' | |
6169 | # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE". | |
6170 | ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' | |
6171 | ac_eB='$%\1#\2define\3' | |
6172 | ac_eC=' ' | |
6173 | ac_eD='%g' | |
6174 | ||
bfde4a67 SG |
6175 | if test "${CONFIG_HEADERS+set}" != set; then |
6176 | EOF | |
6177 | cat >> $CONFIG_STATUS <<EOF | |
6178 | CONFIG_HEADERS="config.h:config.in" | |
6179 | EOF | |
6180 | cat >> $CONFIG_STATUS <<\EOF | |
6181 | fi | |
db210d08 | 6182 | for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then |
bfde4a67 | 6183 | # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". |
db210d08 | 6184 | case "$ac_file" in |
bfde4a67 | 6185 | *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'` |
db210d08 FF |
6186 | ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; |
6187 | *) ac_file_in="${ac_file}.in" ;; | |
6188 | esac | |
6189 | ||
6190 | echo creating $ac_file | |
6191 | ||
6192 | rm -f conftest.frag conftest.in conftest.out | |
bfde4a67 SG |
6193 | ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"` |
6194 | cat $ac_file_inputs > conftest.in | |
db210d08 FF |
6195 | |
6196 | EOF | |
6197 | ||
6198 | # Transform confdefs.h into a sed script conftest.vals that substitutes | |
6199 | # the proper values into config.h.in to produce config.h. And first: | |
1a7b4b7c | 6200 | # Protect against being on the right side of a sed subst in config.status. |
db210d08 FF |
6201 | # Protect against being in an unquoted here document in config.status. |
6202 | rm -f conftest.vals | |
6203 | cat > conftest.hdr <<\EOF | |
6204 | s/[\\&%]/\\&/g | |
6205 | s%[\\$`]%\\&%g | |
bc859e63 | 6206 | s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp |
db210d08 FF |
6207 | s%ac_d%ac_u%gp |
6208 | s%ac_u%ac_e%gp | |
6209 | EOF | |
6210 | sed -n -f conftest.hdr confdefs.h > conftest.vals | |
6211 | rm -f conftest.hdr | |
6212 | ||
6213 | # This sed command replaces #undef with comments. This is necessary, for | |
6214 | # example, in the case of _POSIX_SOURCE, which is predefined and required | |
6215 | # on some systems where configure will not decide to define it. | |
6216 | cat >> conftest.vals <<\EOF | |
6217 | s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */% | |
6218 | EOF | |
6219 | ||
6220 | # Break up conftest.vals because some shells have a limit on | |
6221 | # the size of here documents, and old seds have small limits too. | |
db210d08 FF |
6222 | |
6223 | rm -f conftest.tail | |
6224 | while : | |
6225 | do | |
6226 | ac_lines=`grep -c . conftest.vals` | |
6227 | # grep -c gives empty output for an empty file on some AIX systems. | |
6228 | if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi | |
6229 | # Write a limited-size here document to conftest.frag. | |
6230 | echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS | |
6231 | sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS | |
6232 | echo 'CEOF | |
6233 | sed -f conftest.frag conftest.in > conftest.out | |
6234 | rm -f conftest.in | |
6235 | mv conftest.out conftest.in | |
6236 | ' >> $CONFIG_STATUS | |
6237 | sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail | |
6238 | rm -f conftest.vals | |
6239 | mv conftest.tail conftest.vals | |
6240 | done | |
6241 | rm -f conftest.vals | |
6242 | ||
6243 | cat >> $CONFIG_STATUS <<\EOF | |
6244 | rm -f conftest.frag conftest.h | |
6245 | echo "/* $ac_file. Generated automatically by configure. */" > conftest.h | |
6246 | cat conftest.in >> conftest.h | |
6247 | rm -f conftest.in | |
6248 | if cmp -s $ac_file conftest.h 2>/dev/null; then | |
6249 | echo "$ac_file is unchanged" | |
6250 | rm -f conftest.h | |
6251 | else | |
bc859e63 SG |
6252 | # Remove last slash and all that follows it. Not all systems have dirname. |
6253 | ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` | |
6254 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then | |
6255 | # The file is in a subdirectory. | |
6256 | test ! -d "$ac_dir" && mkdir "$ac_dir" | |
6257 | fi | |
db210d08 FF |
6258 | rm -f $ac_file |
6259 | mv conftest.h $ac_file | |
6260 | fi | |
6261 | fi; done | |
6262 | ||
5436fc65 C |
6263 | EOF |
6264 | ||
6265 | cat >> $CONFIG_STATUS <<EOF | |
6266 | ac_sources="$files" | |
6267 | ac_dests="$links" | |
6268 | EOF | |
6269 | ||
6270 | cat >> $CONFIG_STATUS <<\EOF | |
6271 | srcdir=$ac_given_srcdir | |
6272 | while test -n "$ac_sources"; do | |
6273 | set $ac_dests; ac_dest=$1; shift; ac_dests=$* | |
6274 | set $ac_sources; ac_source=$1; shift; ac_sources=$* | |
6275 | ||
6276 | echo "linking $srcdir/$ac_source to $ac_dest" | |
6277 | ||
6278 | if test ! -r $srcdir/$ac_source; then | |
6279 | { echo "configure: error: $srcdir/$ac_source: File not found" 1>&2; exit 1; } | |
6280 | fi | |
6281 | rm -f $ac_dest | |
6282 | ||
6283 | # Make relative symlinks. | |
6284 | # Remove last slash and all that follows it. Not all systems have dirname. | |
6285 | ac_dest_dir=`echo $ac_dest|sed 's%/[^/][^/]*$%%'` | |
6286 | if test "$ac_dest_dir" != "$ac_dest" && test "$ac_dest_dir" != .; then | |
6287 | # The dest file is in a subdirectory. | |
6288 | test ! -d "$ac_dest_dir" && mkdir "$ac_dest_dir" | |
6289 | ac_dest_dir_suffix="/`echo $ac_dest_dir|sed 's%^\./%%'`" | |
6290 | # A "../" for each directory in $ac_dest_dir_suffix. | |
6291 | ac_dots=`echo $ac_dest_dir_suffix|sed 's%/[^/]*%../%g'` | |
6292 | else | |
6293 | ac_dest_dir_suffix= ac_dots= | |
6294 | fi | |
6295 | ||
6296 | case "$srcdir" in | |
6297 | [/$]*) ac_rel_source="$srcdir/$ac_source" ;; | |
6298 | *) ac_rel_source="$ac_dots$srcdir/$ac_source" ;; | |
6299 | esac | |
6300 | ||
6301 | # Make a symlink if possible; otherwise try a hard link. | |
6302 | if ln -s $ac_rel_source $ac_dest 2>/dev/null || | |
6303 | ln $srcdir/$ac_source $ac_dest; then : | |
6304 | else | |
6305 | { echo "configure: error: can not link $ac_dest to $srcdir/$ac_source" 1>&2; exit 1; } | |
6306 | fi | |
6307 | done | |
0a5a1821 C |
6308 | EOF |
6309 | cat >> $CONFIG_STATUS <<EOF | |
5436fc65 | 6310 | |
0a5a1821 C |
6311 | gdb_host_cpu=$gdb_host_cpu |
6312 | gdb_target_cpu=$gdb_target_cpu | |
6313 | nativefile=$nativefile | |
6314 | ||
6315 | EOF | |
6316 | cat >> $CONFIG_STATUS <<\EOF | |
5436fc65 C |
6317 | |
6318 | if test "${nativefile}" = ""; then | |
7bd1f0c5 | 6319 | sed -e '/^NATDEPFILES[ ]*=[ ]*/s//# NATDEPFILES=/' \ |
5436fc65 C |
6320 | < Makefile > Makefile.tem |
6321 | mv -f Makefile.tem Makefile | |
6322 | fi | |
6323 | ||
6324 | sed -e '/^TM_FILE[ ]*=/s,^TM_FILE[ ]*=[ ]*,&config/'"${gdb_target_cpu}"'/, | |
6325 | /^XM_FILE[ ]*=/s,^XM_FILE[ ]*=[ ]*,&config/'"${gdb_host_cpu}"'/, | |
6326 | /^NAT_FILE[ ]*=/s,^NAT_FILE[ ]*=[ ]*,&config/'"${gdb_host_cpu}"'/,' <Makefile >Makefile.tmp | |
6327 | mv -f Makefile.tmp Makefile | |
6328 | ||
31520669 | 6329 | case x$CONFIG_HEADERS in |
18ea4416 | 6330 | xconfig.h:config.in) |
31520669 FF |
6331 | echo > stamp-h ;; |
6332 | esac | |
6333 | ||
5436fc65 C |
6334 | exit 0 |
6335 | EOF | |
6336 | chmod +x $CONFIG_STATUS | |
6337 | rm -fr confdefs* $ac_clean_files | |
6338 | test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1 | |
6339 | ||
6340 | if test "$no_recursion" != yes; then | |
6341 | ||
6342 | # Remove --cache-file and --srcdir arguments so they do not pile up. | |
6343 | ac_sub_configure_args= | |
6344 | ac_prev= | |
6345 | for ac_arg in $ac_configure_args; do | |
6346 | if test -n "$ac_prev"; then | |
6347 | ac_prev= | |
6348 | continue | |
6349 | fi | |
6350 | case "$ac_arg" in | |
6351 | -cache-file | --cache-file | --cache-fil | --cache-fi \ | |
6352 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) | |
6353 | ac_prev=cache_file ;; | |
6354 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | |
6355 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) | |
6356 | ;; | |
6357 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) | |
6358 | ac_prev=srcdir ;; | |
6359 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) | |
6360 | ;; | |
6361 | *) ac_sub_configure_args="$ac_sub_configure_args $ac_arg" ;; | |
6362 | esac | |
6363 | done | |
6364 | ||
6365 | for ac_config_dir in $configdirs; do | |
6366 | ||
6367 | # Do not complain, so a configure script can configure whichever | |
6368 | # parts of a large source tree are present. | |
6369 | if test ! -d $srcdir/$ac_config_dir; then | |
6370 | continue | |
6371 | fi | |
6372 | ||
6373 | echo configuring in $ac_config_dir | |
6374 | ||
6375 | case "$srcdir" in | |
6376 | .) ;; | |
6377 | *) | |
6378 | if test -d ./$ac_config_dir || mkdir ./$ac_config_dir; then :; | |
6379 | else | |
6380 | { echo "configure: error: can not create `pwd`/$ac_config_dir" 1>&2; exit 1; } | |
6381 | fi | |
6382 | ;; | |
6383 | esac | |
6384 | ||
6385 | ac_popdir=`pwd` | |
6386 | cd $ac_config_dir | |
6387 | ||
bfde4a67 SG |
6388 | # A "../" for each directory in /$ac_config_dir. |
6389 | ac_dots=`echo $ac_config_dir|sed -e 's%^\./%%' -e 's%[^/]$%&/%' -e 's%[^/]*/%../%g'` | |
6390 | ||
5436fc65 C |
6391 | case "$srcdir" in |
6392 | .) # No --srcdir option. We are building in place. | |
6393 | ac_sub_srcdir=$srcdir ;; | |
6394 | /*) # Absolute path. | |
6395 | ac_sub_srcdir=$srcdir/$ac_config_dir ;; | |
6396 | *) # Relative path. | |
bfde4a67 | 6397 | ac_sub_srcdir=$ac_dots$srcdir/$ac_config_dir ;; |
5436fc65 C |
6398 | esac |
6399 | ||
6400 | # Check for guested configure; otherwise get Cygnus style configure. | |
6401 | if test -f $ac_sub_srcdir/configure; then | |
6402 | ac_sub_configure=$ac_sub_srcdir/configure | |
6403 | elif test -f $ac_sub_srcdir/configure.in; then | |
6404 | ac_sub_configure=$ac_configure | |
6405 | else | |
6406 | echo "configure: warning: no configuration information is in $ac_config_dir" 1>&2 | |
6407 | ac_sub_configure= | |
6408 | fi | |
6409 | ||
6410 | # The recursion is here. | |
6411 | if test -n "$ac_sub_configure"; then | |
6412 | ||
6413 | # Make the cache file name correct relative to the subdirectory. | |
5436fc65 C |
6414 | case "$cache_file" in |
6415 | /*) ac_sub_cache_file=$cache_file ;; | |
6416 | *) # Relative path. | |
6417 | ac_sub_cache_file="$ac_dots$cache_file" ;; | |
6418 | esac | |
6419 | case "$ac_given_INSTALL" in | |
6420 | [/$]*) INSTALL="$ac_given_INSTALL" ;; | |
6421 | *) INSTALL="$ac_dots$ac_given_INSTALL" ;; | |
6422 | esac | |
6423 | ||
6424 | echo "running ${CONFIG_SHELL-/bin/sh} $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_sub_srcdir" | |
6425 | # The eval makes quoting arguments work. | |
6426 | if eval ${CONFIG_SHELL-/bin/sh} $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_sub_srcdir | |
6427 | then : | |
6428 | else | |
6429 | { echo "configure: error: $ac_sub_configure failed for $ac_config_dir" 1>&2; exit 1; } | |
6430 | fi | |
6431 | fi | |
6432 | ||
6433 | cd $ac_popdir | |
6434 | done | |
6435 | fi | |
6436 | ||
5e711e7f PS |
6437 | |
6438 | exit 0 | |
b7f3b6d5 | 6439 |