Commit | Line | Data |
---|---|---|
c906108c SS |
1 | #! /bin/sh |
2 | ||
3 | # Guess values for system-dependent variables and create Makefiles. | |
4 | # Generated automatically using autoconf version 2.13 | |
5 | # Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc. | |
6 | # | |
7 | # This configure script is free software; the Free Software Foundation | |
8 | # gives unlimited permission to copy, distribute and modify it. | |
9 | ||
10 | # Defaults: | |
11 | ac_help= | |
12 | ac_default_prefix=/usr/local | |
13 | # Any additions from configure.in: | |
413ccac7 AC |
14 | ac_help="$ac_help |
15 | --enable-maintainer-mode enable make rules and dependencies not useful | |
16 | (and sometimes confusing) to the casual installer" | |
c906108c SS |
17 | ac_help="$ac_help |
18 | --disable-nls do not use Native Language Support" | |
19 | ac_help="$ac_help | |
20 | --with-included-gettext use the GNU gettext library included here" | |
96baa820 JM |
21 | ac_help="$ac_help |
22 | --enable-multi-ice Build the multi-ice-gdb-server" | |
d318976c FN |
23 | ac_help="$ac_help |
24 | --enable-gdbcli Enable GDB-CLI interface" | |
fb40c209 AC |
25 | ac_help="$ac_help |
26 | --enable-gdbmi Enable GDB-MI interface" | |
c906108c SS |
27 | ac_help="$ac_help |
28 | --enable-tui Enable full-screen terminal user interface" | |
29 | ac_help="$ac_help | |
30 | --enable-netrom Enable NetROM support" | |
31 | ac_help="$ac_help | |
32 | --enable-build-warnings Enable build-time compiler warnings if gcc is used" | |
3b851bce AC |
33 | ac_help="$ac_help |
34 | --enable-gdb-build-warnings Enable GDB specific build-time compiler warnings if gcc is used" | |
c906108c SS |
35 | ac_help="$ac_help |
36 | --with-mmalloc Use memory mapped malloc package" | |
88987551 L |
37 | ac_help="$ac_help |
38 | --with-included-regex Use included regex" | |
7a292a7a SS |
39 | ac_help="$ac_help |
40 | --with-cpu=CPU Set the default CPU variant to debug" | |
41 | ac_help="$ac_help | |
42 | --enable-gdbtk Enable GDBTK GUI front end" | |
43 | ac_help="$ac_help | |
44 | --with-tclconfig=DIR Directory containing tcl configuration (tclConfig.sh)" | |
45 | ac_help="$ac_help | |
46 | --with-tkconfig=DIR Directory containing tk configuration (tkConfig.sh)" | |
47 | ac_help="$ac_help | |
48 | --with-tclinclude=DIR Directory where tcl private headers are" | |
49 | ac_help="$ac_help | |
50 | --with-tkinclude=DIR Directory where tk private headers are" | |
51 | ac_help="$ac_help | |
52 | --with-itclconfig Directory containing itcl configuration (itclConfig.sh)" | |
53 | ac_help="$ac_help | |
54 | --with-itkconfig Directory containing itk configuration (itkConfig.sh)" | |
55 | ac_help="$ac_help | |
56 | --with-tixconfig Directory containing tix configuration (tixConfig.sh)" | |
c906108c SS |
57 | ac_help="$ac_help |
58 | --with-x use the X Window System" | |
7a292a7a SS |
59 | ac_help="$ac_help |
60 | --enable-sim Link gdb with simulator" | |
c906108c SS |
61 | ac_help="$ac_help |
62 | --enable-shared Use shared libraries" | |
63 | ||
64 | # Initialize some variables set by options. | |
65 | # The variables have the same names as the options, with | |
66 | # dashes changed to underlines. | |
67 | build=NONE | |
68 | cache_file=./config.cache | |
69 | exec_prefix=NONE | |
70 | host=NONE | |
71 | no_create= | |
72 | nonopt=NONE | |
73 | no_recursion= | |
74 | prefix=NONE | |
75 | program_prefix=NONE | |
76 | program_suffix=NONE | |
77 | program_transform_name=s,x,x, | |
78 | silent= | |
79 | site= | |
3b851bce | 80 | sitefile= |
c906108c SS |
81 | srcdir= |
82 | target=NONE | |
83 | verbose= | |
84 | x_includes=NONE | |
85 | x_libraries=NONE | |
86 | bindir='${exec_prefix}/bin' | |
87 | sbindir='${exec_prefix}/sbin' | |
88 | libexecdir='${exec_prefix}/libexec' | |
89 | datadir='${prefix}/share' | |
90 | sysconfdir='${prefix}/etc' | |
91 | sharedstatedir='${prefix}/com' | |
92 | localstatedir='${prefix}/var' | |
93 | libdir='${exec_prefix}/lib' | |
94 | includedir='${prefix}/include' | |
95 | oldincludedir='/usr/include' | |
96 | infodir='${prefix}/info' | |
97 | mandir='${prefix}/man' | |
98 | ||
99 | # Initialize some other variables. | |
100 | subdirs= | |
101 | MFLAGS= MAKEFLAGS= | |
102 | SHELL=${CONFIG_SHELL-/bin/sh} | |
103 | # Maximum number of lines to put in a shell here document. | |
104 | ac_max_here_lines=12 | |
105 | ||
106 | ac_prev= | |
107 | for ac_option | |
108 | do | |
109 | ||
110 | # If the previous option needs an argument, assign it. | |
111 | if test -n "$ac_prev"; then | |
112 | eval "$ac_prev=\$ac_option" | |
113 | ac_prev= | |
114 | continue | |
115 | fi | |
116 | ||
117 | case "$ac_option" in | |
118 | -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;; | |
119 | *) ac_optarg= ;; | |
120 | esac | |
121 | ||
122 | # Accept the important Cygnus configure options, so we can diagnose typos. | |
123 | ||
124 | case "$ac_option" in | |
125 | ||
126 | -bindir | --bindir | --bindi | --bind | --bin | --bi) | |
127 | ac_prev=bindir ;; | |
128 | -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) | |
129 | bindir="$ac_optarg" ;; | |
130 | ||
131 | -build | --build | --buil | --bui | --bu) | |
132 | ac_prev=build ;; | |
133 | -build=* | --build=* | --buil=* | --bui=* | --bu=*) | |
134 | build="$ac_optarg" ;; | |
135 | ||
136 | -cache-file | --cache-file | --cache-fil | --cache-fi \ | |
137 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) | |
138 | ac_prev=cache_file ;; | |
139 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | |
140 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) | |
141 | cache_file="$ac_optarg" ;; | |
142 | ||
143 | -datadir | --datadir | --datadi | --datad | --data | --dat | --da) | |
144 | ac_prev=datadir ;; | |
145 | -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \ | |
146 | | --da=*) | |
147 | datadir="$ac_optarg" ;; | |
148 | ||
149 | -disable-* | --disable-*) | |
150 | ac_feature=`echo $ac_option|sed -e 's/-*disable-//'` | |
151 | # Reject names that are not valid shell variable names. | |
152 | if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then | |
153 | { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } | |
154 | fi | |
155 | ac_feature=`echo $ac_feature| sed 's/-/_/g'` | |
156 | eval "enable_${ac_feature}=no" ;; | |
157 | ||
158 | -enable-* | --enable-*) | |
159 | ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'` | |
160 | # Reject names that are not valid shell variable names. | |
161 | if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then | |
162 | { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } | |
163 | fi | |
164 | ac_feature=`echo $ac_feature| sed 's/-/_/g'` | |
165 | case "$ac_option" in | |
166 | *=*) ;; | |
167 | *) ac_optarg=yes ;; | |
168 | esac | |
169 | eval "enable_${ac_feature}='$ac_optarg'" ;; | |
170 | ||
171 | -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ | |
172 | | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ | |
173 | | --exec | --exe | --ex) | |
174 | ac_prev=exec_prefix ;; | |
175 | -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ | |
176 | | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ | |
177 | | --exec=* | --exe=* | --ex=*) | |
178 | exec_prefix="$ac_optarg" ;; | |
179 | ||
180 | -gas | --gas | --ga | --g) | |
181 | # Obsolete; use --with-gas. | |
182 | with_gas=yes ;; | |
183 | ||
184 | -help | --help | --hel | --he) | |
185 | # Omit some internal or obsolete options to make the list less imposing. | |
186 | # This message is too long to be a string in the A/UX 3.1 sh. | |
187 | cat << EOF | |
188 | Usage: configure [options] [host] | |
189 | Options: [defaults in brackets after descriptions] | |
190 | Configuration: | |
191 | --cache-file=FILE cache test results in FILE | |
192 | --help print this message | |
193 | --no-create do not create output files | |
194 | --quiet, --silent do not print \`checking...' messages | |
3b851bce | 195 | --site-file=FILE use FILE as the site file |
c906108c SS |
196 | --version print the version of autoconf that created configure |
197 | Directory and file names: | |
198 | --prefix=PREFIX install architecture-independent files in PREFIX | |
199 | [$ac_default_prefix] | |
200 | --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX | |
201 | [same as prefix] | |
202 | --bindir=DIR user executables in DIR [EPREFIX/bin] | |
203 | --sbindir=DIR system admin executables in DIR [EPREFIX/sbin] | |
204 | --libexecdir=DIR program executables in DIR [EPREFIX/libexec] | |
205 | --datadir=DIR read-only architecture-independent data in DIR | |
206 | [PREFIX/share] | |
207 | --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc] | |
208 | --sharedstatedir=DIR modifiable architecture-independent data in DIR | |
209 | [PREFIX/com] | |
210 | --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var] | |
211 | --libdir=DIR object code libraries in DIR [EPREFIX/lib] | |
212 | --includedir=DIR C header files in DIR [PREFIX/include] | |
213 | --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include] | |
214 | --infodir=DIR info documentation in DIR [PREFIX/info] | |
215 | --mandir=DIR man documentation in DIR [PREFIX/man] | |
216 | --srcdir=DIR find the sources in DIR [configure dir or ..] | |
217 | --program-prefix=PREFIX prepend PREFIX to installed program names | |
218 | --program-suffix=SUFFIX append SUFFIX to installed program names | |
219 | --program-transform-name=PROGRAM | |
220 | run sed PROGRAM on installed program names | |
221 | EOF | |
222 | cat << EOF | |
223 | Host type: | |
224 | --build=BUILD configure for building on BUILD [BUILD=HOST] | |
225 | --host=HOST configure for HOST [guessed] | |
226 | --target=TARGET configure for TARGET [TARGET=HOST] | |
227 | Features and packages: | |
228 | --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) | |
229 | --enable-FEATURE[=ARG] include FEATURE [ARG=yes] | |
230 | --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] | |
231 | --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) | |
232 | --x-includes=DIR X include files are in DIR | |
233 | --x-libraries=DIR X library files are in DIR | |
234 | EOF | |
235 | if test -n "$ac_help"; then | |
236 | echo "--enable and --with options recognized:$ac_help" | |
237 | fi | |
238 | exit 0 ;; | |
239 | ||
240 | -host | --host | --hos | --ho) | |
241 | ac_prev=host ;; | |
242 | -host=* | --host=* | --hos=* | --ho=*) | |
243 | host="$ac_optarg" ;; | |
244 | ||
245 | -includedir | --includedir | --includedi | --included | --include \ | |
246 | | --includ | --inclu | --incl | --inc) | |
247 | ac_prev=includedir ;; | |
248 | -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ | |
249 | | --includ=* | --inclu=* | --incl=* | --inc=*) | |
250 | includedir="$ac_optarg" ;; | |
251 | ||
252 | -infodir | --infodir | --infodi | --infod | --info | --inf) | |
253 | ac_prev=infodir ;; | |
254 | -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) | |
255 | infodir="$ac_optarg" ;; | |
256 | ||
257 | -libdir | --libdir | --libdi | --libd) | |
258 | ac_prev=libdir ;; | |
259 | -libdir=* | --libdir=* | --libdi=* | --libd=*) | |
260 | libdir="$ac_optarg" ;; | |
261 | ||
262 | -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ | |
263 | | --libexe | --libex | --libe) | |
264 | ac_prev=libexecdir ;; | |
265 | -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ | |
266 | | --libexe=* | --libex=* | --libe=*) | |
267 | libexecdir="$ac_optarg" ;; | |
268 | ||
269 | -localstatedir | --localstatedir | --localstatedi | --localstated \ | |
270 | | --localstate | --localstat | --localsta | --localst \ | |
271 | | --locals | --local | --loca | --loc | --lo) | |
272 | ac_prev=localstatedir ;; | |
273 | -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ | |
274 | | --localstate=* | --localstat=* | --localsta=* | --localst=* \ | |
275 | | --locals=* | --local=* | --loca=* | --loc=* | --lo=*) | |
276 | localstatedir="$ac_optarg" ;; | |
277 | ||
278 | -mandir | --mandir | --mandi | --mand | --man | --ma | --m) | |
279 | ac_prev=mandir ;; | |
280 | -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) | |
281 | mandir="$ac_optarg" ;; | |
282 | ||
283 | -nfp | --nfp | --nf) | |
284 | # Obsolete; use --without-fp. | |
285 | with_fp=no ;; | |
286 | ||
287 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | |
288 | | --no-cr | --no-c) | |
289 | no_create=yes ;; | |
290 | ||
291 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ | |
292 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) | |
293 | no_recursion=yes ;; | |
294 | ||
295 | -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ | |
296 | | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ | |
297 | | --oldin | --oldi | --old | --ol | --o) | |
298 | ac_prev=oldincludedir ;; | |
299 | -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ | |
300 | | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ | |
301 | | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) | |
302 | oldincludedir="$ac_optarg" ;; | |
303 | ||
304 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) | |
305 | ac_prev=prefix ;; | |
306 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) | |
307 | prefix="$ac_optarg" ;; | |
308 | ||
309 | -program-prefix | --program-prefix | --program-prefi | --program-pref \ | |
310 | | --program-pre | --program-pr | --program-p) | |
311 | ac_prev=program_prefix ;; | |
312 | -program-prefix=* | --program-prefix=* | --program-prefi=* \ | |
313 | | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) | |
314 | program_prefix="$ac_optarg" ;; | |
315 | ||
316 | -program-suffix | --program-suffix | --program-suffi | --program-suff \ | |
317 | | --program-suf | --program-su | --program-s) | |
318 | ac_prev=program_suffix ;; | |
319 | -program-suffix=* | --program-suffix=* | --program-suffi=* \ | |
320 | | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) | |
321 | program_suffix="$ac_optarg" ;; | |
322 | ||
323 | -program-transform-name | --program-transform-name \ | |
324 | | --program-transform-nam | --program-transform-na \ | |
325 | | --program-transform-n | --program-transform- \ | |
326 | | --program-transform | --program-transfor \ | |
327 | | --program-transfo | --program-transf \ | |
328 | | --program-trans | --program-tran \ | |
329 | | --progr-tra | --program-tr | --program-t) | |
330 | ac_prev=program_transform_name ;; | |
331 | -program-transform-name=* | --program-transform-name=* \ | |
332 | | --program-transform-nam=* | --program-transform-na=* \ | |
333 | | --program-transform-n=* | --program-transform-=* \ | |
334 | | --program-transform=* | --program-transfor=* \ | |
335 | | --program-transfo=* | --program-transf=* \ | |
336 | | --program-trans=* | --program-tran=* \ | |
337 | | --progr-tra=* | --program-tr=* | --program-t=*) | |
338 | program_transform_name="$ac_optarg" ;; | |
339 | ||
340 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | |
341 | | -silent | --silent | --silen | --sile | --sil) | |
342 | silent=yes ;; | |
343 | ||
344 | -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) | |
345 | ac_prev=sbindir ;; | |
346 | -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ | |
347 | | --sbi=* | --sb=*) | |
348 | sbindir="$ac_optarg" ;; | |
349 | ||
350 | -sharedstatedir | --sharedstatedir | --sharedstatedi \ | |
351 | | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ | |
352 | | --sharedst | --shareds | --shared | --share | --shar \ | |
353 | | --sha | --sh) | |
354 | ac_prev=sharedstatedir ;; | |
355 | -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ | |
356 | | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ | |
357 | | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ | |
358 | | --sha=* | --sh=*) | |
359 | sharedstatedir="$ac_optarg" ;; | |
360 | ||
361 | -site | --site | --sit) | |
362 | ac_prev=site ;; | |
363 | -site=* | --site=* | --sit=*) | |
364 | site="$ac_optarg" ;; | |
365 | ||
3b851bce AC |
366 | -site-file | --site-file | --site-fil | --site-fi | --site-f) |
367 | ac_prev=sitefile ;; | |
368 | -site-file=* | --site-file=* | --site-fil=* | --site-fi=* | --site-f=*) | |
369 | sitefile="$ac_optarg" ;; | |
370 | ||
c906108c SS |
371 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) |
372 | ac_prev=srcdir ;; | |
373 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) | |
374 | srcdir="$ac_optarg" ;; | |
375 | ||
376 | -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ | |
377 | | --syscon | --sysco | --sysc | --sys | --sy) | |
378 | ac_prev=sysconfdir ;; | |
379 | -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ | |
380 | | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) | |
381 | sysconfdir="$ac_optarg" ;; | |
382 | ||
383 | -target | --target | --targe | --targ | --tar | --ta | --t) | |
384 | ac_prev=target ;; | |
385 | -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) | |
386 | target="$ac_optarg" ;; | |
387 | ||
388 | -v | -verbose | --verbose | --verbos | --verbo | --verb) | |
389 | verbose=yes ;; | |
390 | ||
391 | -version | --version | --versio | --versi | --vers) | |
392 | echo "configure generated by autoconf version 2.13" | |
393 | exit 0 ;; | |
394 | ||
395 | -with-* | --with-*) | |
396 | ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'` | |
397 | # Reject names that are not valid shell variable names. | |
398 | if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then | |
399 | { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } | |
400 | fi | |
401 | ac_package=`echo $ac_package| sed 's/-/_/g'` | |
402 | case "$ac_option" in | |
403 | *=*) ;; | |
404 | *) ac_optarg=yes ;; | |
405 | esac | |
406 | eval "with_${ac_package}='$ac_optarg'" ;; | |
407 | ||
408 | -without-* | --without-*) | |
409 | ac_package=`echo $ac_option|sed -e 's/-*without-//'` | |
410 | # Reject names that are not valid shell variable names. | |
411 | if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then | |
412 | { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } | |
413 | fi | |
414 | ac_package=`echo $ac_package| sed 's/-/_/g'` | |
415 | eval "with_${ac_package}=no" ;; | |
416 | ||
417 | --x) | |
418 | # Obsolete; use --with-x. | |
419 | with_x=yes ;; | |
420 | ||
421 | -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ | |
422 | | --x-incl | --x-inc | --x-in | --x-i) | |
423 | ac_prev=x_includes ;; | |
424 | -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ | |
425 | | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) | |
426 | x_includes="$ac_optarg" ;; | |
427 | ||
428 | -x-libraries | --x-libraries | --x-librarie | --x-librari \ | |
429 | | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) | |
430 | ac_prev=x_libraries ;; | |
431 | -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ | |
432 | | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) | |
433 | x_libraries="$ac_optarg" ;; | |
434 | ||
435 | -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; } | |
436 | ;; | |
437 | ||
438 | *) | |
439 | if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then | |
440 | echo "configure: warning: $ac_option: invalid host type" 1>&2 | |
441 | fi | |
442 | if test "x$nonopt" != xNONE; then | |
443 | { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } | |
444 | fi | |
445 | nonopt="$ac_option" | |
446 | ;; | |
447 | ||
448 | esac | |
449 | done | |
450 | ||
451 | if test -n "$ac_prev"; then | |
452 | { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; } | |
453 | fi | |
454 | ||
455 | trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 | |
456 | ||
457 | # File descriptor usage: | |
458 | # 0 standard input | |
459 | # 1 file creation | |
460 | # 2 errors and warnings | |
461 | # 3 some systems may open it to /dev/tty | |
462 | # 4 used on the Kubota Titan | |
463 | # 6 checking for... messages and results | |
464 | # 5 compiler messages saved in config.log | |
465 | if test "$silent" = yes; then | |
466 | exec 6>/dev/null | |
467 | else | |
468 | exec 6>&1 | |
469 | fi | |
470 | exec 5>./config.log | |
471 | ||
472 | echo "\ | |
473 | This file contains any messages produced by compilers while | |
474 | running configure, to aid debugging if configure makes a mistake. | |
475 | " 1>&5 | |
476 | ||
477 | # Strip out --no-create and --no-recursion so they do not pile up. | |
478 | # Also quote any args containing shell metacharacters. | |
479 | ac_configure_args= | |
480 | for ac_arg | |
481 | do | |
482 | case "$ac_arg" in | |
483 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | |
484 | | --no-cr | --no-c) ;; | |
485 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ | |
486 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;; | |
487 | *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*) | |
488 | ac_configure_args="$ac_configure_args '$ac_arg'" ;; | |
489 | *) ac_configure_args="$ac_configure_args $ac_arg" ;; | |
490 | esac | |
491 | done | |
492 | ||
493 | # NLS nuisances. | |
494 | # Only set these to C if already set. These must not be set unconditionally | |
495 | # because not all systems understand e.g. LANG=C (notably SCO). | |
496 | # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'! | |
497 | # Non-C LC_CTYPE values break the ctype check. | |
498 | if test "${LANG+set}" = set; then LANG=C; export LANG; fi | |
499 | if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi | |
500 | if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi | |
501 | if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi | |
502 | ||
503 | # confdefs.h avoids OS command line length limits that DEFS can exceed. | |
504 | rm -rf conftest* confdefs.h | |
505 | # AIX cpp loses on an empty file, so make sure it contains at least a newline. | |
506 | echo > confdefs.h | |
507 | ||
508 | # A filename unique to this package, relative to the directory that | |
509 | # configure is in, which we can look for to find out if srcdir is correct. | |
510 | ac_unique_file=main.c | |
511 | ||
512 | # Find the source files, if location was not specified. | |
513 | if test -z "$srcdir"; then | |
514 | ac_srcdir_defaulted=yes | |
515 | # Try the directory containing this script, then its parent. | |
516 | ac_prog=$0 | |
517 | ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'` | |
518 | test "x$ac_confdir" = "x$ac_prog" && ac_confdir=. | |
519 | srcdir=$ac_confdir | |
520 | if test ! -r $srcdir/$ac_unique_file; then | |
521 | srcdir=.. | |
522 | fi | |
523 | else | |
524 | ac_srcdir_defaulted=no | |
525 | fi | |
526 | if test ! -r $srcdir/$ac_unique_file; then | |
527 | if test "$ac_srcdir_defaulted" = yes; then | |
528 | { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; } | |
529 | else | |
530 | { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; } | |
531 | fi | |
532 | fi | |
533 | srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'` | |
534 | ||
535 | # Prefer explicitly selected file to automatically selected ones. | |
3b851bce AC |
536 | if test -z "$sitefile"; then |
537 | if test -z "$CONFIG_SITE"; then | |
538 | if test "x$prefix" != xNONE; then | |
539 | CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site" | |
540 | else | |
541 | CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site" | |
542 | fi | |
c906108c | 543 | fi |
3b851bce AC |
544 | else |
545 | CONFIG_SITE="$sitefile" | |
c906108c SS |
546 | fi |
547 | for ac_site_file in $CONFIG_SITE; do | |
548 | if test -r "$ac_site_file"; then | |
549 | echo "loading site script $ac_site_file" | |
550 | . "$ac_site_file" | |
551 | fi | |
552 | done | |
553 | ||
554 | if test -r "$cache_file"; then | |
555 | echo "loading cache $cache_file" | |
556 | . $cache_file | |
557 | else | |
558 | echo "creating cache $cache_file" | |
559 | > $cache_file | |
560 | fi | |
561 | ||
562 | ac_ext=c | |
563 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. | |
564 | ac_cpp='$CPP $CPPFLAGS' | |
565 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' | |
566 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' | |
567 | cross_compiling=$ac_cv_prog_cc_cross | |
568 | ||
569 | ac_exeext= | |
570 | ac_objext=o | |
571 | if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then | |
572 | # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu. | |
573 | if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then | |
574 | ac_n= ac_c=' | |
575 | ' ac_t=' ' | |
576 | else | |
577 | ac_n=-n ac_c= ac_t= | |
578 | fi | |
579 | else | |
580 | ac_n= ac_c='\c' ac_t= | |
581 | fi | |
582 | ||
583 | ||
584 | ||
413ccac7 | 585 | echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6 |
d318976c | 586 | echo "configure:587: checking whether to enable maintainer-specific portions of Makefiles" >&5 |
413ccac7 AC |
587 | # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given. |
588 | if test "${enable_maintainer_mode+set}" = set; then | |
589 | enableval="$enable_maintainer_mode" | |
590 | USE_MAINTAINER_MODE=$enableval | |
591 | else | |
592 | USE_MAINTAINER_MODE=no | |
593 | fi | |
594 | ||
595 | echo "$ac_t""$USE_MAINTAINER_MODE" 1>&6 | |
596 | ||
597 | ||
598 | if test $USE_MAINTAINER_MODE = yes; then | |
599 | MAINTAINER_MODE_TRUE= | |
600 | MAINTAINER_MODE_FALSE='#' | |
601 | else | |
602 | MAINTAINER_MODE_TRUE='#' | |
603 | MAINTAINER_MODE_FALSE= | |
604 | fi | |
605 | MAINT=$MAINTAINER_MODE_TRUE | |
606 | ||
607 | ||
c906108c SS |
608 | |
609 | # Extract the first word of "gcc", so it can be a program name with args. | |
610 | set dummy gcc; ac_word=$2 | |
611 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
d318976c | 612 | echo "configure:613: checking for $ac_word" >&5 |
c906108c SS |
613 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
614 | echo $ac_n "(cached) $ac_c" 1>&6 | |
615 | else | |
616 | if test -n "$CC"; then | |
617 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
618 | else | |
619 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
620 | ac_dummy="$PATH" | |
621 | for ac_dir in $ac_dummy; do | |
622 | test -z "$ac_dir" && ac_dir=. | |
623 | if test -f $ac_dir/$ac_word; then | |
624 | ac_cv_prog_CC="gcc" | |
625 | break | |
626 | fi | |
627 | done | |
628 | IFS="$ac_save_ifs" | |
629 | fi | |
630 | fi | |
631 | CC="$ac_cv_prog_CC" | |
632 | if test -n "$CC"; then | |
633 | echo "$ac_t""$CC" 1>&6 | |
634 | else | |
635 | echo "$ac_t""no" 1>&6 | |
636 | fi | |
637 | ||
638 | if test -z "$CC"; then | |
639 | # Extract the first word of "cc", so it can be a program name with args. | |
640 | set dummy cc; ac_word=$2 | |
641 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
d318976c | 642 | echo "configure:643: checking for $ac_word" >&5 |
c906108c SS |
643 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
644 | echo $ac_n "(cached) $ac_c" 1>&6 | |
645 | else | |
646 | if test -n "$CC"; then | |
647 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
648 | else | |
649 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
650 | ac_prog_rejected=no | |
651 | ac_dummy="$PATH" | |
652 | for ac_dir in $ac_dummy; do | |
653 | test -z "$ac_dir" && ac_dir=. | |
654 | if test -f $ac_dir/$ac_word; then | |
655 | if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then | |
656 | ac_prog_rejected=yes | |
657 | continue | |
658 | fi | |
659 | ac_cv_prog_CC="cc" | |
660 | break | |
661 | fi | |
662 | done | |
663 | IFS="$ac_save_ifs" | |
664 | if test $ac_prog_rejected = yes; then | |
665 | # We found a bogon in the path, so make sure we never use it. | |
666 | set dummy $ac_cv_prog_CC | |
667 | shift | |
668 | if test $# -gt 0; then | |
669 | # We chose a different compiler from the bogus one. | |
670 | # However, it has the same basename, so the bogon will be chosen | |
671 | # first if we set CC to just the basename; use the full file name. | |
672 | shift | |
673 | set dummy "$ac_dir/$ac_word" "$@" | |
674 | shift | |
675 | ac_cv_prog_CC="$@" | |
676 | fi | |
677 | fi | |
678 | fi | |
679 | fi | |
680 | CC="$ac_cv_prog_CC" | |
681 | if test -n "$CC"; then | |
682 | echo "$ac_t""$CC" 1>&6 | |
683 | else | |
684 | echo "$ac_t""no" 1>&6 | |
685 | fi | |
686 | ||
687 | if test -z "$CC"; then | |
688 | case "`uname -s`" in | |
689 | *win32* | *WIN32*) | |
690 | # Extract the first word of "cl", so it can be a program name with args. | |
691 | set dummy cl; ac_word=$2 | |
692 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
d318976c | 693 | echo "configure:694: checking for $ac_word" >&5 |
c906108c SS |
694 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
695 | echo $ac_n "(cached) $ac_c" 1>&6 | |
696 | else | |
697 | if test -n "$CC"; then | |
698 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
699 | else | |
700 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
701 | ac_dummy="$PATH" | |
702 | for ac_dir in $ac_dummy; do | |
703 | test -z "$ac_dir" && ac_dir=. | |
704 | if test -f $ac_dir/$ac_word; then | |
705 | ac_cv_prog_CC="cl" | |
706 | break | |
707 | fi | |
708 | done | |
709 | IFS="$ac_save_ifs" | |
710 | fi | |
711 | fi | |
712 | CC="$ac_cv_prog_CC" | |
713 | if test -n "$CC"; then | |
714 | echo "$ac_t""$CC" 1>&6 | |
715 | else | |
716 | echo "$ac_t""no" 1>&6 | |
717 | fi | |
718 | ;; | |
719 | esac | |
720 | fi | |
721 | test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; } | |
722 | fi | |
723 | ||
724 | echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 | |
d318976c | 725 | echo "configure:726: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 |
c906108c SS |
726 | |
727 | ac_ext=c | |
728 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. | |
729 | ac_cpp='$CPP $CPPFLAGS' | |
730 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' | |
731 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' | |
732 | cross_compiling=$ac_cv_prog_cc_cross | |
733 | ||
734 | cat > conftest.$ac_ext << EOF | |
735 | ||
d318976c | 736 | #line 737 "configure" |
c906108c SS |
737 | #include "confdefs.h" |
738 | ||
739 | main(){return(0);} | |
740 | EOF | |
d318976c | 741 | if { (eval echo configure:742: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
c906108c SS |
742 | ac_cv_prog_cc_works=yes |
743 | # If we can't run a trivial program, we are probably using a cross compiler. | |
744 | if (./conftest; exit) 2>/dev/null; then | |
745 | ac_cv_prog_cc_cross=no | |
746 | else | |
747 | ac_cv_prog_cc_cross=yes | |
748 | fi | |
749 | else | |
750 | echo "configure: failed program was:" >&5 | |
751 | cat conftest.$ac_ext >&5 | |
752 | ac_cv_prog_cc_works=no | |
753 | fi | |
754 | rm -fr conftest* | |
755 | ac_ext=c | |
756 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. | |
757 | ac_cpp='$CPP $CPPFLAGS' | |
758 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' | |
759 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' | |
760 | cross_compiling=$ac_cv_prog_cc_cross | |
761 | ||
762 | echo "$ac_t""$ac_cv_prog_cc_works" 1>&6 | |
763 | if test $ac_cv_prog_cc_works = no; then | |
764 | { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; } | |
765 | fi | |
766 | echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 | |
d318976c | 767 | echo "configure:768: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 |
c906108c SS |
768 | echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6 |
769 | cross_compiling=$ac_cv_prog_cc_cross | |
770 | ||
771 | echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6 | |
d318976c | 772 | echo "configure:773: checking whether we are using GNU C" >&5 |
c906108c SS |
773 | if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then |
774 | echo $ac_n "(cached) $ac_c" 1>&6 | |
775 | else | |
776 | cat > conftest.c <<EOF | |
777 | #ifdef __GNUC__ | |
778 | yes; | |
779 | #endif | |
780 | EOF | |
d318976c | 781 | if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:782: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then |
c906108c SS |
782 | ac_cv_prog_gcc=yes |
783 | else | |
784 | ac_cv_prog_gcc=no | |
785 | fi | |
786 | fi | |
787 | ||
788 | echo "$ac_t""$ac_cv_prog_gcc" 1>&6 | |
789 | ||
790 | if test $ac_cv_prog_gcc = yes; then | |
791 | GCC=yes | |
792 | else | |
793 | GCC= | |
794 | fi | |
795 | ||
796 | ac_test_CFLAGS="${CFLAGS+set}" | |
797 | ac_save_CFLAGS="$CFLAGS" | |
798 | CFLAGS= | |
799 | echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 | |
d318976c | 800 | echo "configure:801: checking whether ${CC-cc} accepts -g" >&5 |
c906108c SS |
801 | if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then |
802 | echo $ac_n "(cached) $ac_c" 1>&6 | |
803 | else | |
804 | echo 'void f(){}' > conftest.c | |
805 | if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then | |
806 | ac_cv_prog_cc_g=yes | |
807 | else | |
808 | ac_cv_prog_cc_g=no | |
809 | fi | |
810 | rm -f conftest* | |
811 | ||
812 | fi | |
813 | ||
814 | echo "$ac_t""$ac_cv_prog_cc_g" 1>&6 | |
815 | if test "$ac_test_CFLAGS" = set; then | |
816 | CFLAGS="$ac_save_CFLAGS" | |
817 | elif test $ac_cv_prog_cc_g = yes; then | |
818 | if test "$GCC" = yes; then | |
819 | CFLAGS="-g -O2" | |
820 | else | |
821 | CFLAGS="-g" | |
822 | fi | |
823 | else | |
824 | if test "$GCC" = yes; then | |
825 | CFLAGS="-O2" | |
826 | else | |
827 | CFLAGS= | |
828 | fi | |
829 | fi | |
830 | ||
831 | echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6 | |
d318976c | 832 | echo "configure:833: checking how to run the C preprocessor" >&5 |
c906108c SS |
833 | # On Suns, sometimes $CPP names a directory. |
834 | if test -n "$CPP" && test -d "$CPP"; then | |
835 | CPP= | |
836 | fi | |
837 | if test -z "$CPP"; then | |
838 | if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then | |
839 | echo $ac_n "(cached) $ac_c" 1>&6 | |
840 | else | |
841 | # This must be in double quotes, not single quotes, because CPP may get | |
842 | # substituted into the Makefile and "${CC-cc}" will confuse make. | |
843 | CPP="${CC-cc} -E" | |
844 | # On the NeXT, cc -E runs the code through the compiler's parser, | |
845 | # not just through cpp. | |
846 | cat > conftest.$ac_ext <<EOF | |
d318976c | 847 | #line 848 "configure" |
c906108c SS |
848 | #include "confdefs.h" |
849 | #include <assert.h> | |
850 | Syntax Error | |
851 | EOF | |
852 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
d318976c | 853 | { (eval echo configure:854: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
c906108c SS |
854 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
855 | if test -z "$ac_err"; then | |
856 | : | |
857 | else | |
858 | echo "$ac_err" >&5 | |
859 | echo "configure: failed program was:" >&5 | |
860 | cat conftest.$ac_ext >&5 | |
861 | rm -rf conftest* | |
862 | CPP="${CC-cc} -E -traditional-cpp" | |
863 | cat > conftest.$ac_ext <<EOF | |
d318976c | 864 | #line 865 "configure" |
c906108c SS |
865 | #include "confdefs.h" |
866 | #include <assert.h> | |
867 | Syntax Error | |
868 | EOF | |
869 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
d318976c | 870 | { (eval echo configure:871: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
c906108c SS |
871 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
872 | if test -z "$ac_err"; then | |
873 | : | |
874 | else | |
875 | echo "$ac_err" >&5 | |
876 | echo "configure: failed program was:" >&5 | |
877 | cat conftest.$ac_ext >&5 | |
878 | rm -rf conftest* | |
879 | CPP="${CC-cc} -nologo -E" | |
880 | cat > conftest.$ac_ext <<EOF | |
d318976c | 881 | #line 882 "configure" |
c906108c SS |
882 | #include "confdefs.h" |
883 | #include <assert.h> | |
884 | Syntax Error | |
885 | EOF | |
886 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
d318976c | 887 | { (eval echo configure:888: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
c906108c SS |
888 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
889 | if test -z "$ac_err"; then | |
890 | : | |
891 | else | |
892 | echo "$ac_err" >&5 | |
893 | echo "configure: failed program was:" >&5 | |
894 | cat conftest.$ac_ext >&5 | |
895 | rm -rf conftest* | |
896 | CPP=/lib/cpp | |
897 | fi | |
898 | rm -f conftest* | |
899 | fi | |
900 | rm -f conftest* | |
901 | fi | |
902 | rm -f conftest* | |
903 | ac_cv_prog_CPP="$CPP" | |
904 | fi | |
905 | CPP="$ac_cv_prog_CPP" | |
906 | else | |
907 | ac_cv_prog_CPP="$CPP" | |
908 | fi | |
909 | echo "$ac_t""$CPP" 1>&6 | |
910 | ||
911 | echo $ac_n "checking for AIX""... $ac_c" 1>&6 | |
d318976c | 912 | echo "configure:913: checking for AIX" >&5 |
c906108c | 913 | cat > conftest.$ac_ext <<EOF |
d318976c | 914 | #line 915 "configure" |
c906108c SS |
915 | #include "confdefs.h" |
916 | #ifdef _AIX | |
917 | yes | |
918 | #endif | |
919 | ||
920 | EOF | |
921 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
922 | egrep "yes" >/dev/null 2>&1; then | |
923 | rm -rf conftest* | |
924 | echo "$ac_t""yes" 1>&6; cat >> confdefs.h <<\EOF | |
925 | #define _ALL_SOURCE 1 | |
926 | EOF | |
927 | ||
928 | else | |
929 | rm -rf conftest* | |
930 | echo "$ac_t""no" 1>&6 | |
931 | fi | |
932 | rm -f conftest* | |
933 | ||
934 | ||
935 | echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6 | |
d318976c | 936 | echo "configure:937: checking for POSIXized ISC" >&5 |
c906108c SS |
937 | if test -d /etc/conf/kconfig.d && |
938 | grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1 | |
939 | then | |
940 | echo "$ac_t""yes" 1>&6 | |
941 | ISC=yes # If later tests want to check for ISC. | |
942 | cat >> confdefs.h <<\EOF | |
943 | #define _POSIX_SOURCE 1 | |
944 | EOF | |
945 | ||
946 | if test "$GCC" = yes; then | |
947 | CC="$CC -posix" | |
948 | else | |
949 | CC="$CC -Xp" | |
950 | fi | |
951 | else | |
952 | echo "$ac_t""no" 1>&6 | |
953 | ISC= | |
954 | fi | |
955 | ||
956 | ||
957 | ||
958 | ||
959 | echo $ac_n "checking for ${CC-cc} option to accept ANSI C""... $ac_c" 1>&6 | |
d318976c | 960 | echo "configure:961: checking for ${CC-cc} option to accept ANSI C" >&5 |
c906108c SS |
961 | if eval "test \"`echo '$''{'am_cv_prog_cc_stdc'+set}'`\" = set"; then |
962 | echo $ac_n "(cached) $ac_c" 1>&6 | |
963 | else | |
964 | am_cv_prog_cc_stdc=no | |
965 | ac_save_CC="$CC" | |
966 | # Don't try gcc -ansi; that turns off useful extensions and | |
967 | # breaks some systems' header files. | |
968 | # AIX -qlanglvl=ansi | |
969 | # Ultrix and OSF/1 -std1 | |
970 | # HP-UX -Aa -D_HPUX_SOURCE | |
971 | # SVR4 -Xc -D__EXTENSIONS__ | |
972 | for ac_arg in "" -qlanglvl=ansi -std1 "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" | |
973 | do | |
974 | CC="$ac_save_CC $ac_arg" | |
975 | cat > conftest.$ac_ext <<EOF | |
d318976c | 976 | #line 977 "configure" |
c906108c SS |
977 | #include "confdefs.h" |
978 | #include <stdarg.h> | |
979 | #include <stdio.h> | |
980 | #include <sys/types.h> | |
981 | #include <sys/stat.h> | |
982 | /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ | |
983 | struct buf { int x; }; | |
984 | FILE * (*rcsopen) (struct buf *, struct stat *, int); | |
985 | static char *e (p, i) | |
986 | char **p; | |
987 | int i; | |
988 | { | |
989 | return p[i]; | |
990 | } | |
991 | static char *f (char * (*g) (char **, int), char **p, ...) | |
992 | { | |
993 | char *s; | |
994 | va_list v; | |
995 | va_start (v,p); | |
996 | s = g (p, va_arg (v,int)); | |
997 | va_end (v); | |
998 | return s; | |
999 | } | |
1000 | int test (int i, double x); | |
1001 | struct s1 {int (*f) (int a);}; | |
1002 | struct s2 {int (*f) (double a);}; | |
1003 | int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); | |
1004 | int argc; | |
1005 | char **argv; | |
1006 | ||
1007 | int main() { | |
1008 | ||
1009 | return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; | |
1010 | ||
1011 | ; return 0; } | |
1012 | EOF | |
d318976c | 1013 | if { (eval echo configure:1014: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
c906108c SS |
1014 | rm -rf conftest* |
1015 | am_cv_prog_cc_stdc="$ac_arg"; break | |
1016 | else | |
1017 | echo "configure: failed program was:" >&5 | |
1018 | cat conftest.$ac_ext >&5 | |
1019 | fi | |
1020 | rm -f conftest* | |
1021 | done | |
1022 | CC="$ac_save_CC" | |
1023 | ||
1024 | fi | |
1025 | ||
1026 | if test -z "$am_cv_prog_cc_stdc"; then | |
1027 | echo "$ac_t""none needed" 1>&6 | |
1028 | else | |
1029 | echo "$ac_t""$am_cv_prog_cc_stdc" 1>&6 | |
1030 | fi | |
1031 | case "x$am_cv_prog_cc_stdc" in | |
1032 | x|xno) ;; | |
1033 | *) CC="$CC $am_cv_prog_cc_stdc" ;; | |
1034 | esac | |
1035 | ||
1036 | ||
1037 | ac_aux_dir= | |
1038 | for ac_dir in `cd $srcdir;pwd`/.. $srcdir/`cd $srcdir;pwd`/..; do | |
1039 | if test -f $ac_dir/install-sh; then | |
1040 | ac_aux_dir=$ac_dir | |
1041 | ac_install_sh="$ac_aux_dir/install-sh -c" | |
1042 | break | |
1043 | elif test -f $ac_dir/install.sh; then | |
1044 | ac_aux_dir=$ac_dir | |
1045 | ac_install_sh="$ac_aux_dir/install.sh -c" | |
1046 | break | |
1047 | fi | |
1048 | done | |
1049 | if test -z "$ac_aux_dir"; then | |
1050 | { echo "configure: error: can not find install-sh or install.sh in `cd $srcdir;pwd`/.. $srcdir/`cd $srcdir;pwd`/.." 1>&2; exit 1; } | |
1051 | fi | |
1052 | ac_config_guess=$ac_aux_dir/config.guess | |
1053 | ac_config_sub=$ac_aux_dir/config.sub | |
1054 | ac_configure=$ac_aux_dir/configure # This should be Cygnus configure. | |
1055 | ||
1056 | ||
1057 | # Do some error checking and defaulting for the host and target type. | |
1058 | # The inputs are: | |
1059 | # configure --host=HOST --target=TARGET --build=BUILD NONOPT | |
1060 | # | |
1061 | # The rules are: | |
1062 | # 1. You are not allowed to specify --host, --target, and nonopt at the | |
1063 | # same time. | |
1064 | # 2. Host defaults to nonopt. | |
1065 | # 3. If nonopt is not specified, then host defaults to the current host, | |
1066 | # as determined by config.guess. | |
1067 | # 4. Target and build default to nonopt. | |
1068 | # 5. If nonopt is not specified, then target and build default to host. | |
1069 | ||
1070 | # The aliases save the names the user supplied, while $host etc. | |
1071 | # will get canonicalized. | |
1072 | case $host---$target---$nonopt in | |
1073 | NONE---*---* | *---NONE---* | *---*---NONE) ;; | |
1074 | *) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;; | |
1075 | esac | |
1076 | ||
1077 | ||
1078 | # Make sure we can run config.sub. | |
1079 | if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then : | |
1080 | else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; } | |
1081 | fi | |
1082 | ||
1083 | echo $ac_n "checking host system type""... $ac_c" 1>&6 | |
d318976c | 1084 | echo "configure:1085: checking host system type" >&5 |
c906108c SS |
1085 | |
1086 | host_alias=$host | |
1087 | case "$host_alias" in | |
1088 | NONE) | |
1089 | case $nonopt in | |
1090 | NONE) | |
1091 | if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then : | |
1092 | else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; } | |
1093 | fi ;; | |
1094 | *) host_alias=$nonopt ;; | |
1095 | esac ;; | |
1096 | esac | |
1097 | ||
1098 | host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias` | |
1099 | host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` | |
1100 | host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` | |
1101 | host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` | |
1102 | echo "$ac_t""$host" 1>&6 | |
1103 | ||
1104 | echo $ac_n "checking target system type""... $ac_c" 1>&6 | |
d318976c | 1105 | echo "configure:1106: checking target system type" >&5 |
c906108c SS |
1106 | |
1107 | target_alias=$target | |
1108 | case "$target_alias" in | |
1109 | NONE) | |
1110 | case $nonopt in | |
1111 | NONE) target_alias=$host_alias ;; | |
1112 | *) target_alias=$nonopt ;; | |
1113 | esac ;; | |
1114 | esac | |
1115 | ||
1116 | target=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $target_alias` | |
1117 | target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` | |
1118 | target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` | |
1119 | target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` | |
1120 | echo "$ac_t""$target" 1>&6 | |
1121 | ||
1122 | echo $ac_n "checking build system type""... $ac_c" 1>&6 | |
d318976c | 1123 | echo "configure:1124: checking build system type" >&5 |
c906108c SS |
1124 | |
1125 | build_alias=$build | |
1126 | case "$build_alias" in | |
1127 | NONE) | |
1128 | case $nonopt in | |
1129 | NONE) build_alias=$host_alias ;; | |
1130 | *) build_alias=$nonopt ;; | |
1131 | esac ;; | |
1132 | esac | |
1133 | ||
1134 | build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias` | |
1135 | build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` | |
1136 | build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` | |
1137 | build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` | |
1138 | echo "$ac_t""$build" 1>&6 | |
1139 | ||
1140 | test "$host_alias" != "$target_alias" && | |
1141 | test "$program_prefix$program_suffix$program_transform_name" = \ | |
1142 | NONENONEs,x,x, && | |
1143 | program_prefix=${target_alias}- | |
1144 | ||
1145 | ||
1146 | ALL_LINGUAS= | |
1147 | echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6 | |
d318976c | 1148 | echo "configure:1149: checking whether ${MAKE-make} sets \${MAKE}" >&5 |
c906108c SS |
1149 | set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'` |
1150 | if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then | |
1151 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1152 | else | |
1153 | cat > conftestmake <<\EOF | |
1154 | all: | |
1155 | @echo 'ac_maketemp="${MAKE}"' | |
1156 | EOF | |
1157 | # GNU make sometimes prints "make[1]: Entering...", which would confuse us. | |
1158 | eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=` | |
1159 | if test -n "$ac_maketemp"; then | |
1160 | eval ac_cv_prog_make_${ac_make}_set=yes | |
1161 | else | |
1162 | eval ac_cv_prog_make_${ac_make}_set=no | |
1163 | fi | |
1164 | rm -f conftestmake | |
1165 | fi | |
1166 | if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then | |
1167 | echo "$ac_t""yes" 1>&6 | |
1168 | SET_MAKE= | |
1169 | else | |
1170 | echo "$ac_t""no" 1>&6 | |
1171 | SET_MAKE="MAKE=${MAKE-make}" | |
1172 | fi | |
1173 | ||
1174 | # Extract the first word of "ranlib", so it can be a program name with args. | |
1175 | set dummy ranlib; ac_word=$2 | |
1176 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
d318976c | 1177 | echo "configure:1178: checking for $ac_word" >&5 |
c906108c SS |
1178 | if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then |
1179 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1180 | else | |
1181 | if test -n "$RANLIB"; then | |
1182 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. | |
1183 | else | |
1184 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
1185 | ac_dummy="$PATH" | |
1186 | for ac_dir in $ac_dummy; do | |
1187 | test -z "$ac_dir" && ac_dir=. | |
1188 | if test -f $ac_dir/$ac_word; then | |
1189 | ac_cv_prog_RANLIB="ranlib" | |
1190 | break | |
1191 | fi | |
1192 | done | |
1193 | IFS="$ac_save_ifs" | |
1194 | test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":" | |
1195 | fi | |
1196 | fi | |
1197 | RANLIB="$ac_cv_prog_RANLIB" | |
1198 | if test -n "$RANLIB"; then | |
1199 | echo "$ac_t""$RANLIB" 1>&6 | |
1200 | else | |
1201 | echo "$ac_t""no" 1>&6 | |
1202 | fi | |
1203 | ||
1204 | echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6 | |
d318976c | 1205 | echo "configure:1206: checking for ANSI C header files" >&5 |
c906108c SS |
1206 | if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then |
1207 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1208 | else | |
1209 | cat > conftest.$ac_ext <<EOF | |
d318976c | 1210 | #line 1211 "configure" |
c906108c SS |
1211 | #include "confdefs.h" |
1212 | #include <stdlib.h> | |
1213 | #include <stdarg.h> | |
1214 | #include <string.h> | |
1215 | #include <float.h> | |
1216 | EOF | |
1217 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
d318976c | 1218 | { (eval echo configure:1219: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
c906108c SS |
1219 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
1220 | if test -z "$ac_err"; then | |
1221 | rm -rf conftest* | |
1222 | ac_cv_header_stdc=yes | |
1223 | else | |
1224 | echo "$ac_err" >&5 | |
1225 | echo "configure: failed program was:" >&5 | |
1226 | cat conftest.$ac_ext >&5 | |
1227 | rm -rf conftest* | |
1228 | ac_cv_header_stdc=no | |
1229 | fi | |
1230 | rm -f conftest* | |
1231 | ||
1232 | if test $ac_cv_header_stdc = yes; then | |
1233 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. | |
1234 | cat > conftest.$ac_ext <<EOF | |
d318976c | 1235 | #line 1236 "configure" |
c906108c SS |
1236 | #include "confdefs.h" |
1237 | #include <string.h> | |
1238 | EOF | |
1239 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
1240 | egrep "memchr" >/dev/null 2>&1; then | |
1241 | : | |
1242 | else | |
1243 | rm -rf conftest* | |
1244 | ac_cv_header_stdc=no | |
1245 | fi | |
1246 | rm -f conftest* | |
1247 | ||
1248 | fi | |
1249 | ||
1250 | if test $ac_cv_header_stdc = yes; then | |
1251 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. | |
1252 | cat > conftest.$ac_ext <<EOF | |
d318976c | 1253 | #line 1254 "configure" |
c906108c SS |
1254 | #include "confdefs.h" |
1255 | #include <stdlib.h> | |
1256 | EOF | |
1257 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
1258 | egrep "free" >/dev/null 2>&1; then | |
1259 | : | |
1260 | else | |
1261 | rm -rf conftest* | |
1262 | ac_cv_header_stdc=no | |
1263 | fi | |
1264 | rm -f conftest* | |
1265 | ||
1266 | fi | |
1267 | ||
1268 | if test $ac_cv_header_stdc = yes; then | |
1269 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. | |
1270 | if test "$cross_compiling" = yes; then | |
1271 | : | |
1272 | else | |
1273 | cat > conftest.$ac_ext <<EOF | |
d318976c | 1274 | #line 1275 "configure" |
c906108c SS |
1275 | #include "confdefs.h" |
1276 | #include <ctype.h> | |
1277 | #define ISLOWER(c) ('a' <= (c) && (c) <= 'z') | |
1278 | #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) | |
1279 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) | |
1280 | int main () { int i; for (i = 0; i < 256; i++) | |
1281 | if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2); | |
1282 | exit (0); } | |
1283 | ||
1284 | EOF | |
d318976c | 1285 | if { (eval echo configure:1286: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
c906108c SS |
1286 | then |
1287 | : | |
1288 | else | |
1289 | echo "configure: failed program was:" >&5 | |
1290 | cat conftest.$ac_ext >&5 | |
1291 | rm -fr conftest* | |
1292 | ac_cv_header_stdc=no | |
1293 | fi | |
1294 | rm -fr conftest* | |
1295 | fi | |
1296 | ||
1297 | fi | |
1298 | fi | |
1299 | ||
1300 | echo "$ac_t""$ac_cv_header_stdc" 1>&6 | |
1301 | if test $ac_cv_header_stdc = yes; then | |
1302 | cat >> confdefs.h <<\EOF | |
1303 | #define STDC_HEADERS 1 | |
1304 | EOF | |
1305 | ||
1306 | fi | |
1307 | ||
1308 | echo $ac_n "checking for working const""... $ac_c" 1>&6 | |
d318976c | 1309 | echo "configure:1310: checking for working const" >&5 |
c906108c SS |
1310 | if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then |
1311 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1312 | else | |
1313 | cat > conftest.$ac_ext <<EOF | |
d318976c | 1314 | #line 1315 "configure" |
c906108c SS |
1315 | #include "confdefs.h" |
1316 | ||
1317 | int main() { | |
1318 | ||
1319 | /* Ultrix mips cc rejects this. */ | |
1320 | typedef int charset[2]; const charset x; | |
1321 | /* SunOS 4.1.1 cc rejects this. */ | |
1322 | char const *const *ccp; | |
1323 | char **p; | |
1324 | /* NEC SVR4.0.2 mips cc rejects this. */ | |
1325 | struct point {int x, y;}; | |
1326 | static struct point const zero = {0,0}; | |
1327 | /* AIX XL C 1.02.0.0 rejects this. | |
1328 | It does not let you subtract one const X* pointer from another in an arm | |
1329 | of an if-expression whose if-part is not a constant expression */ | |
1330 | const char *g = "string"; | |
1331 | ccp = &g + (g ? g-g : 0); | |
1332 | /* HPUX 7.0 cc rejects these. */ | |
1333 | ++ccp; | |
1334 | p = (char**) ccp; | |
1335 | ccp = (char const *const *) p; | |
1336 | { /* SCO 3.2v4 cc rejects this. */ | |
1337 | char *t; | |
1338 | char const *s = 0 ? (char *) 0 : (char const *) 0; | |
1339 | ||
1340 | *t++ = 0; | |
1341 | } | |
1342 | { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ | |
1343 | int x[] = {25, 17}; | |
1344 | const int *foo = &x[0]; | |
1345 | ++foo; | |
1346 | } | |
1347 | { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ | |
1348 | typedef const int *iptr; | |
1349 | iptr p = 0; | |
1350 | ++p; | |
1351 | } | |
1352 | { /* AIX XL C 1.02.0.0 rejects this saying | |
1353 | "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ | |
1354 | struct s { int j; const int *ap[3]; }; | |
1355 | struct s *b; b->j = 5; | |
1356 | } | |
1357 | { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ | |
1358 | const int foo = 10; | |
1359 | } | |
1360 | ||
1361 | ; return 0; } | |
1362 | EOF | |
d318976c | 1363 | if { (eval echo configure:1364: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
c906108c SS |
1364 | rm -rf conftest* |
1365 | ac_cv_c_const=yes | |
1366 | else | |
1367 | echo "configure: failed program was:" >&5 | |
1368 | cat conftest.$ac_ext >&5 | |
1369 | rm -rf conftest* | |
1370 | ac_cv_c_const=no | |
1371 | fi | |
1372 | rm -f conftest* | |
1373 | fi | |
1374 | ||
1375 | echo "$ac_t""$ac_cv_c_const" 1>&6 | |
1376 | if test $ac_cv_c_const = no; then | |
1377 | cat >> confdefs.h <<\EOF | |
1378 | #define const | |
1379 | EOF | |
1380 | ||
1381 | fi | |
1382 | ||
1383 | echo $ac_n "checking for inline""... $ac_c" 1>&6 | |
d318976c | 1384 | echo "configure:1385: checking for inline" >&5 |
c906108c SS |
1385 | if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then |
1386 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1387 | else | |
1388 | ac_cv_c_inline=no | |
1389 | for ac_kw in inline __inline__ __inline; do | |
1390 | cat > conftest.$ac_ext <<EOF | |
d318976c | 1391 | #line 1392 "configure" |
c906108c SS |
1392 | #include "confdefs.h" |
1393 | ||
1394 | int main() { | |
1395 | } $ac_kw foo() { | |
1396 | ; return 0; } | |
1397 | EOF | |
d318976c | 1398 | if { (eval echo configure:1399: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
c906108c SS |
1399 | rm -rf conftest* |
1400 | ac_cv_c_inline=$ac_kw; break | |
1401 | else | |
1402 | echo "configure: failed program was:" >&5 | |
1403 | cat conftest.$ac_ext >&5 | |
1404 | fi | |
1405 | rm -f conftest* | |
1406 | done | |
1407 | ||
1408 | fi | |
1409 | ||
1410 | echo "$ac_t""$ac_cv_c_inline" 1>&6 | |
1411 | case "$ac_cv_c_inline" in | |
1412 | inline | yes) ;; | |
1413 | no) cat >> confdefs.h <<\EOF | |
1414 | #define inline | |
1415 | EOF | |
1416 | ;; | |
1417 | *) cat >> confdefs.h <<EOF | |
1418 | #define inline $ac_cv_c_inline | |
1419 | EOF | |
1420 | ;; | |
1421 | esac | |
1422 | ||
1423 | echo $ac_n "checking for off_t""... $ac_c" 1>&6 | |
d318976c | 1424 | echo "configure:1425: checking for off_t" >&5 |
c906108c SS |
1425 | if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then |
1426 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1427 | else | |
1428 | cat > conftest.$ac_ext <<EOF | |
d318976c | 1429 | #line 1430 "configure" |
c906108c SS |
1430 | #include "confdefs.h" |
1431 | #include <sys/types.h> | |
1432 | #if STDC_HEADERS | |
1433 | #include <stdlib.h> | |
1434 | #include <stddef.h> | |
1435 | #endif | |
1436 | EOF | |
1437 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
1438 | egrep "(^|[^a-zA-Z_0-9])off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then | |
1439 | rm -rf conftest* | |
1440 | ac_cv_type_off_t=yes | |
1441 | else | |
1442 | rm -rf conftest* | |
1443 | ac_cv_type_off_t=no | |
1444 | fi | |
1445 | rm -f conftest* | |
1446 | ||
1447 | fi | |
1448 | echo "$ac_t""$ac_cv_type_off_t" 1>&6 | |
1449 | if test $ac_cv_type_off_t = no; then | |
1450 | cat >> confdefs.h <<\EOF | |
1451 | #define off_t long | |
1452 | EOF | |
1453 | ||
1454 | fi | |
1455 | ||
1456 | echo $ac_n "checking for size_t""... $ac_c" 1>&6 | |
d318976c | 1457 | echo "configure:1458: checking for size_t" >&5 |
c906108c SS |
1458 | if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then |
1459 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1460 | else | |
1461 | cat > conftest.$ac_ext <<EOF | |
d318976c | 1462 | #line 1463 "configure" |
c906108c SS |
1463 | #include "confdefs.h" |
1464 | #include <sys/types.h> | |
1465 | #if STDC_HEADERS | |
1466 | #include <stdlib.h> | |
1467 | #include <stddef.h> | |
1468 | #endif | |
1469 | EOF | |
1470 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
1471 | egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then | |
1472 | rm -rf conftest* | |
1473 | ac_cv_type_size_t=yes | |
1474 | else | |
1475 | rm -rf conftest* | |
1476 | ac_cv_type_size_t=no | |
1477 | fi | |
1478 | rm -f conftest* | |
1479 | ||
1480 | fi | |
1481 | echo "$ac_t""$ac_cv_type_size_t" 1>&6 | |
1482 | if test $ac_cv_type_size_t = no; then | |
1483 | cat >> confdefs.h <<\EOF | |
1484 | #define size_t unsigned | |
1485 | EOF | |
1486 | ||
1487 | fi | |
1488 | ||
1489 | # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works | |
1490 | # for constant arguments. Useless! | |
1491 | echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6 | |
d318976c | 1492 | echo "configure:1493: checking for working alloca.h" >&5 |
c906108c SS |
1493 | if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then |
1494 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1495 | else | |
1496 | cat > conftest.$ac_ext <<EOF | |
d318976c | 1497 | #line 1498 "configure" |
c906108c SS |
1498 | #include "confdefs.h" |
1499 | #include <alloca.h> | |
1500 | int main() { | |
1501 | char *p = alloca(2 * sizeof(int)); | |
1502 | ; return 0; } | |
1503 | EOF | |
d318976c | 1504 | if { (eval echo configure:1505: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
c906108c SS |
1505 | rm -rf conftest* |
1506 | ac_cv_header_alloca_h=yes | |
1507 | else | |
1508 | echo "configure: failed program was:" >&5 | |
1509 | cat conftest.$ac_ext >&5 | |
1510 | rm -rf conftest* | |
1511 | ac_cv_header_alloca_h=no | |
1512 | fi | |
1513 | rm -f conftest* | |
1514 | fi | |
1515 | ||
1516 | echo "$ac_t""$ac_cv_header_alloca_h" 1>&6 | |
1517 | if test $ac_cv_header_alloca_h = yes; then | |
1518 | cat >> confdefs.h <<\EOF | |
1519 | #define HAVE_ALLOCA_H 1 | |
1520 | EOF | |
1521 | ||
1522 | fi | |
1523 | ||
1524 | echo $ac_n "checking for alloca""... $ac_c" 1>&6 | |
d318976c | 1525 | echo "configure:1526: checking for alloca" >&5 |
c906108c SS |
1526 | if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then |
1527 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1528 | else | |
1529 | cat > conftest.$ac_ext <<EOF | |
d318976c | 1530 | #line 1531 "configure" |
c906108c SS |
1531 | #include "confdefs.h" |
1532 | ||
1533 | #ifdef __GNUC__ | |
1534 | # define alloca __builtin_alloca | |
1535 | #else | |
1536 | # ifdef _MSC_VER | |
1537 | # include <malloc.h> | |
1538 | # define alloca _alloca | |
1539 | # else | |
1540 | # if HAVE_ALLOCA_H | |
1541 | # include <alloca.h> | |
1542 | # else | |
1543 | # ifdef _AIX | |
1544 | #pragma alloca | |
1545 | # else | |
1546 | # ifndef alloca /* predefined by HP cc +Olibcalls */ | |
1547 | char *alloca (); | |
1548 | # endif | |
1549 | # endif | |
1550 | # endif | |
1551 | # endif | |
1552 | #endif | |
1553 | ||
1554 | int main() { | |
1555 | char *p = (char *) alloca(1); | |
1556 | ; return 0; } | |
1557 | EOF | |
d318976c | 1558 | if { (eval echo configure:1559: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
c906108c SS |
1559 | rm -rf conftest* |
1560 | ac_cv_func_alloca_works=yes | |
1561 | else | |
1562 | echo "configure: failed program was:" >&5 | |
1563 | cat conftest.$ac_ext >&5 | |
1564 | rm -rf conftest* | |
1565 | ac_cv_func_alloca_works=no | |
1566 | fi | |
1567 | rm -f conftest* | |
1568 | fi | |
1569 | ||
1570 | echo "$ac_t""$ac_cv_func_alloca_works" 1>&6 | |
1571 | if test $ac_cv_func_alloca_works = yes; then | |
1572 | cat >> confdefs.h <<\EOF | |
1573 | #define HAVE_ALLOCA 1 | |
1574 | EOF | |
1575 | ||
1576 | fi | |
1577 | ||
1578 | if test $ac_cv_func_alloca_works = no; then | |
1579 | # The SVR3 libPW and SVR4 libucb both contain incompatible functions | |
1580 | # that cause trouble. Some versions do not even contain alloca or | |
1581 | # contain a buggy version. If you still want to use their alloca, | |
1582 | # use ar to extract alloca.o from them instead of compiling alloca.c. | |
1583 | ALLOCA=alloca.${ac_objext} | |
1584 | cat >> confdefs.h <<\EOF | |
1585 | #define C_ALLOCA 1 | |
1586 | EOF | |
1587 | ||
1588 | ||
1589 | echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6 | |
d318976c | 1590 | echo "configure:1591: checking whether alloca needs Cray hooks" >&5 |
c906108c SS |
1591 | if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then |
1592 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1593 | else | |
1594 | cat > conftest.$ac_ext <<EOF | |
d318976c | 1595 | #line 1596 "configure" |
c906108c SS |
1596 | #include "confdefs.h" |
1597 | #if defined(CRAY) && ! defined(CRAY2) | |
1598 | webecray | |
1599 | #else | |
1600 | wenotbecray | |
1601 | #endif | |
1602 | ||
1603 | EOF | |
1604 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
1605 | egrep "webecray" >/dev/null 2>&1; then | |
1606 | rm -rf conftest* | |
1607 | ac_cv_os_cray=yes | |
1608 | else | |
1609 | rm -rf conftest* | |
1610 | ac_cv_os_cray=no | |
1611 | fi | |
1612 | rm -f conftest* | |
1613 | ||
1614 | fi | |
1615 | ||
1616 | echo "$ac_t""$ac_cv_os_cray" 1>&6 | |
1617 | if test $ac_cv_os_cray = yes; then | |
1618 | for ac_func in _getb67 GETB67 getb67; do | |
1619 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
d318976c | 1620 | echo "configure:1621: checking for $ac_func" >&5 |
c906108c SS |
1621 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
1622 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1623 | else | |
1624 | cat > conftest.$ac_ext <<EOF | |
d318976c | 1625 | #line 1626 "configure" |
c906108c SS |
1626 | #include "confdefs.h" |
1627 | /* System header to define __stub macros and hopefully few prototypes, | |
1628 | which can conflict with char $ac_func(); below. */ | |
1629 | #include <assert.h> | |
1630 | /* Override any gcc2 internal prototype to avoid an error. */ | |
1631 | /* We use char because int might match the return type of a gcc2 | |
1632 | builtin and then its argument prototype would still apply. */ | |
1633 | char $ac_func(); | |
1634 | ||
1635 | int main() { | |
1636 | ||
1637 | /* The GNU C library defines this for functions which it implements | |
1638 | to always fail with ENOSYS. Some functions are actually named | |
1639 | something starting with __ and the normal name is an alias. */ | |
1640 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
1641 | choke me | |
1642 | #else | |
1643 | $ac_func(); | |
1644 | #endif | |
1645 | ||
1646 | ; return 0; } | |
1647 | EOF | |
d318976c | 1648 | if { (eval echo configure:1649: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
c906108c SS |
1649 | rm -rf conftest* |
1650 | eval "ac_cv_func_$ac_func=yes" | |
1651 | else | |
1652 | echo "configure: failed program was:" >&5 | |
1653 | cat conftest.$ac_ext >&5 | |
1654 | rm -rf conftest* | |
1655 | eval "ac_cv_func_$ac_func=no" | |
1656 | fi | |
1657 | rm -f conftest* | |
1658 | fi | |
1659 | ||
1660 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then | |
1661 | echo "$ac_t""yes" 1>&6 | |
1662 | cat >> confdefs.h <<EOF | |
1663 | #define CRAY_STACKSEG_END $ac_func | |
1664 | EOF | |
1665 | ||
1666 | break | |
1667 | else | |
1668 | echo "$ac_t""no" 1>&6 | |
1669 | fi | |
1670 | ||
1671 | done | |
1672 | fi | |
1673 | ||
1674 | echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6 | |
d318976c | 1675 | echo "configure:1676: checking stack direction for C alloca" >&5 |
c906108c SS |
1676 | if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then |
1677 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1678 | else | |
1679 | if test "$cross_compiling" = yes; then | |
1680 | ac_cv_c_stack_direction=0 | |
1681 | else | |
1682 | cat > conftest.$ac_ext <<EOF | |
d318976c | 1683 | #line 1684 "configure" |
c906108c SS |
1684 | #include "confdefs.h" |
1685 | find_stack_direction () | |
1686 | { | |
1687 | static char *addr = 0; | |
1688 | auto char dummy; | |
1689 | if (addr == 0) | |
1690 | { | |
1691 | addr = &dummy; | |
1692 | return find_stack_direction (); | |
1693 | } | |
1694 | else | |
1695 | return (&dummy > addr) ? 1 : -1; | |
1696 | } | |
1697 | main () | |
1698 | { | |
1699 | exit (find_stack_direction() < 0); | |
1700 | } | |
1701 | EOF | |
d318976c | 1702 | if { (eval echo configure:1703: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
c906108c SS |
1703 | then |
1704 | ac_cv_c_stack_direction=1 | |
1705 | else | |
1706 | echo "configure: failed program was:" >&5 | |
1707 | cat conftest.$ac_ext >&5 | |
1708 | rm -fr conftest* | |
1709 | ac_cv_c_stack_direction=-1 | |
1710 | fi | |
1711 | rm -fr conftest* | |
1712 | fi | |
1713 | ||
1714 | fi | |
1715 | ||
1716 | echo "$ac_t""$ac_cv_c_stack_direction" 1>&6 | |
1717 | cat >> confdefs.h <<EOF | |
1718 | #define STACK_DIRECTION $ac_cv_c_stack_direction | |
1719 | EOF | |
1720 | ||
1721 | fi | |
1722 | ||
1723 | for ac_hdr in unistd.h | |
1724 | do | |
1725 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` | |
1726 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 | |
d318976c | 1727 | echo "configure:1728: checking for $ac_hdr" >&5 |
c906108c SS |
1728 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
1729 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1730 | else | |
1731 | cat > conftest.$ac_ext <<EOF | |
d318976c | 1732 | #line 1733 "configure" |
c906108c SS |
1733 | #include "confdefs.h" |
1734 | #include <$ac_hdr> | |
1735 | EOF | |
1736 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
d318976c | 1737 | { (eval echo configure:1738: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
c906108c SS |
1738 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
1739 | if test -z "$ac_err"; then | |
1740 | rm -rf conftest* | |
1741 | eval "ac_cv_header_$ac_safe=yes" | |
1742 | else | |
1743 | echo "$ac_err" >&5 | |
1744 | echo "configure: failed program was:" >&5 | |
1745 | cat conftest.$ac_ext >&5 | |
1746 | rm -rf conftest* | |
1747 | eval "ac_cv_header_$ac_safe=no" | |
1748 | fi | |
1749 | rm -f conftest* | |
1750 | fi | |
1751 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | |
1752 | echo "$ac_t""yes" 1>&6 | |
1753 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` | |
1754 | cat >> confdefs.h <<EOF | |
1755 | #define $ac_tr_hdr 1 | |
1756 | EOF | |
1757 | ||
1758 | else | |
1759 | echo "$ac_t""no" 1>&6 | |
1760 | fi | |
1761 | done | |
1762 | ||
1763 | for ac_func in getpagesize | |
1764 | do | |
1765 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
d318976c | 1766 | echo "configure:1767: checking for $ac_func" >&5 |
c906108c SS |
1767 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
1768 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1769 | else | |
1770 | cat > conftest.$ac_ext <<EOF | |
d318976c | 1771 | #line 1772 "configure" |
c906108c SS |
1772 | #include "confdefs.h" |
1773 | /* System header to define __stub macros and hopefully few prototypes, | |
1774 | which can conflict with char $ac_func(); below. */ | |
1775 | #include <assert.h> | |
1776 | /* Override any gcc2 internal prototype to avoid an error. */ | |
1777 | /* We use char because int might match the return type of a gcc2 | |
1778 | builtin and then its argument prototype would still apply. */ | |
1779 | char $ac_func(); | |
1780 | ||
1781 | int main() { | |
1782 | ||
1783 | /* The GNU C library defines this for functions which it implements | |
1784 | to always fail with ENOSYS. Some functions are actually named | |
1785 | something starting with __ and the normal name is an alias. */ | |
1786 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
1787 | choke me | |
1788 | #else | |
1789 | $ac_func(); | |
1790 | #endif | |
1791 | ||
1792 | ; return 0; } | |
1793 | EOF | |
d318976c | 1794 | if { (eval echo configure:1795: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
c906108c SS |
1795 | rm -rf conftest* |
1796 | eval "ac_cv_func_$ac_func=yes" | |
1797 | else | |
1798 | echo "configure: failed program was:" >&5 | |
1799 | cat conftest.$ac_ext >&5 | |
1800 | rm -rf conftest* | |
1801 | eval "ac_cv_func_$ac_func=no" | |
1802 | fi | |
1803 | rm -f conftest* | |
1804 | fi | |
1805 | ||
1806 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then | |
1807 | echo "$ac_t""yes" 1>&6 | |
1808 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
1809 | cat >> confdefs.h <<EOF | |
1810 | #define $ac_tr_func 1 | |
1811 | EOF | |
1812 | ||
1813 | else | |
1814 | echo "$ac_t""no" 1>&6 | |
1815 | fi | |
1816 | done | |
1817 | ||
1818 | echo $ac_n "checking for working mmap""... $ac_c" 1>&6 | |
d318976c | 1819 | echo "configure:1820: checking for working mmap" >&5 |
c906108c SS |
1820 | if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then |
1821 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1822 | else | |
1823 | if test "$cross_compiling" = yes; then | |
1824 | ac_cv_func_mmap_fixed_mapped=no | |
1825 | else | |
1826 | cat > conftest.$ac_ext <<EOF | |
d318976c | 1827 | #line 1828 "configure" |
c906108c SS |
1828 | #include "confdefs.h" |
1829 | ||
1830 | /* Thanks to Mike Haertel and Jim Avera for this test. | |
1831 | Here is a matrix of mmap possibilities: | |
1832 | mmap private not fixed | |
1833 | mmap private fixed at somewhere currently unmapped | |
1834 | mmap private fixed at somewhere already mapped | |
1835 | mmap shared not fixed | |
1836 | mmap shared fixed at somewhere currently unmapped | |
1837 | mmap shared fixed at somewhere already mapped | |
1838 | For private mappings, we should verify that changes cannot be read() | |
1839 | back from the file, nor mmap's back from the file at a different | |
1840 | address. (There have been systems where private was not correctly | |
1841 | implemented like the infamous i386 svr4.0, and systems where the | |
1842 | VM page cache was not coherent with the filesystem buffer cache | |
1843 | like early versions of FreeBSD and possibly contemporary NetBSD.) | |
1844 | For shared mappings, we should conversely verify that changes get | |
1845 | propogated back to all the places they're supposed to be. | |
1846 | ||
1847 | Grep wants private fixed already mapped. | |
1848 | The main things grep needs to know about mmap are: | |
1849 | * does it exist and is it safe to write into the mmap'd area | |
1850 | * how to use it (BSD variants) */ | |
1851 | #include <sys/types.h> | |
1852 | #include <fcntl.h> | |
1853 | #include <sys/mman.h> | |
1854 | ||
1855 | /* This mess was copied from the GNU getpagesize.h. */ | |
1856 | #ifndef HAVE_GETPAGESIZE | |
1857 | # ifdef HAVE_UNISTD_H | |
1858 | # include <unistd.h> | |
1859 | # endif | |
1860 | ||
1861 | /* Assume that all systems that can run configure have sys/param.h. */ | |
1862 | # ifndef HAVE_SYS_PARAM_H | |
1863 | # define HAVE_SYS_PARAM_H 1 | |
1864 | # endif | |
1865 | ||
1866 | # ifdef _SC_PAGESIZE | |
1867 | # define getpagesize() sysconf(_SC_PAGESIZE) | |
1868 | # else /* no _SC_PAGESIZE */ | |
1869 | # ifdef HAVE_SYS_PARAM_H | |
1870 | # include <sys/param.h> | |
1871 | # ifdef EXEC_PAGESIZE | |
1872 | # define getpagesize() EXEC_PAGESIZE | |
1873 | # else /* no EXEC_PAGESIZE */ | |
1874 | # ifdef NBPG | |
1875 | # define getpagesize() NBPG * CLSIZE | |
1876 | # ifndef CLSIZE | |
1877 | # define CLSIZE 1 | |
1878 | # endif /* no CLSIZE */ | |
1879 | # else /* no NBPG */ | |
1880 | # ifdef NBPC | |
1881 | # define getpagesize() NBPC | |
1882 | # else /* no NBPC */ | |
1883 | # ifdef PAGESIZE | |
1884 | # define getpagesize() PAGESIZE | |
1885 | # endif /* PAGESIZE */ | |
1886 | # endif /* no NBPC */ | |
1887 | # endif /* no NBPG */ | |
1888 | # endif /* no EXEC_PAGESIZE */ | |
1889 | # else /* no HAVE_SYS_PARAM_H */ | |
1890 | # define getpagesize() 8192 /* punt totally */ | |
1891 | # endif /* no HAVE_SYS_PARAM_H */ | |
1892 | # endif /* no _SC_PAGESIZE */ | |
1893 | ||
1894 | #endif /* no HAVE_GETPAGESIZE */ | |
1895 | ||
1896 | #ifdef __cplusplus | |
1897 | extern "C" { void *malloc(unsigned); } | |
1898 | #else | |
1899 | char *malloc(); | |
1900 | #endif | |
1901 | ||
1902 | int | |
1903 | main() | |
1904 | { | |
1905 | char *data, *data2, *data3; | |
1906 | int i, pagesize; | |
1907 | int fd; | |
1908 | ||
1909 | pagesize = getpagesize(); | |
1910 | ||
1911 | /* | |
1912 | * First, make a file with some known garbage in it. | |
1913 | */ | |
1914 | data = malloc(pagesize); | |
1915 | if (!data) | |
1916 | exit(1); | |
1917 | for (i = 0; i < pagesize; ++i) | |
1918 | *(data + i) = rand(); | |
1919 | umask(0); | |
1920 | fd = creat("conftestmmap", 0600); | |
1921 | if (fd < 0) | |
1922 | exit(1); | |
1923 | if (write(fd, data, pagesize) != pagesize) | |
1924 | exit(1); | |
1925 | close(fd); | |
1926 | ||
1927 | /* | |
1928 | * Next, try to mmap the file at a fixed address which | |
1929 | * already has something else allocated at it. If we can, | |
1930 | * also make sure that we see the same garbage. | |
1931 | */ | |
1932 | fd = open("conftestmmap", O_RDWR); | |
1933 | if (fd < 0) | |
1934 | exit(1); | |
1935 | data2 = malloc(2 * pagesize); | |
1936 | if (!data2) | |
1937 | exit(1); | |
1938 | data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1); | |
1939 | if (data2 != mmap(data2, pagesize, PROT_READ | PROT_WRITE, | |
1940 | MAP_PRIVATE | MAP_FIXED, fd, 0L)) | |
1941 | exit(1); | |
1942 | for (i = 0; i < pagesize; ++i) | |
1943 | if (*(data + i) != *(data2 + i)) | |
1944 | exit(1); | |
1945 | ||
1946 | /* | |
1947 | * Finally, make sure that changes to the mapped area | |
1948 | * do not percolate back to the file as seen by read(). | |
1949 | * (This is a bug on some variants of i386 svr4.0.) | |
1950 | */ | |
1951 | for (i = 0; i < pagesize; ++i) | |
1952 | *(data2 + i) = *(data2 + i) + 1; | |
1953 | data3 = malloc(pagesize); | |
1954 | if (!data3) | |
1955 | exit(1); | |
1956 | if (read(fd, data3, pagesize) != pagesize) | |
1957 | exit(1); | |
1958 | for (i = 0; i < pagesize; ++i) | |
1959 | if (*(data + i) != *(data3 + i)) | |
1960 | exit(1); | |
1961 | close(fd); | |
1962 | unlink("conftestmmap"); | |
1963 | exit(0); | |
1964 | } | |
1965 | ||
1966 | EOF | |
d318976c | 1967 | if { (eval echo configure:1968: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
c906108c SS |
1968 | then |
1969 | ac_cv_func_mmap_fixed_mapped=yes | |
1970 | else | |
1971 | echo "configure: failed program was:" >&5 | |
1972 | cat conftest.$ac_ext >&5 | |
1973 | rm -fr conftest* | |
1974 | ac_cv_func_mmap_fixed_mapped=no | |
1975 | fi | |
1976 | rm -fr conftest* | |
1977 | fi | |
1978 | ||
1979 | fi | |
1980 | ||
1981 | echo "$ac_t""$ac_cv_func_mmap_fixed_mapped" 1>&6 | |
1982 | if test $ac_cv_func_mmap_fixed_mapped = yes; then | |
1983 | cat >> confdefs.h <<\EOF | |
1984 | #define HAVE_MMAP 1 | |
1985 | EOF | |
1986 | ||
1987 | fi | |
1988 | ||
1989 | ||
1990 | for ac_hdr in argz.h limits.h locale.h nl_types.h malloc.h string.h \ | |
1991 | unistd.h values.h sys/param.h | |
1992 | do | |
1993 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` | |
1994 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 | |
d318976c | 1995 | echo "configure:1996: checking for $ac_hdr" >&5 |
c906108c SS |
1996 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
1997 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1998 | else | |
1999 | cat > conftest.$ac_ext <<EOF | |
d318976c | 2000 | #line 2001 "configure" |
c906108c SS |
2001 | #include "confdefs.h" |
2002 | #include <$ac_hdr> | |
2003 | EOF | |
2004 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
d318976c | 2005 | { (eval echo configure:2006: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
c906108c SS |
2006 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
2007 | if test -z "$ac_err"; then | |
2008 | rm -rf conftest* | |
2009 | eval "ac_cv_header_$ac_safe=yes" | |
2010 | else | |
2011 | echo "$ac_err" >&5 | |
2012 | echo "configure: failed program was:" >&5 | |
2013 | cat conftest.$ac_ext >&5 | |
2014 | rm -rf conftest* | |
2015 | eval "ac_cv_header_$ac_safe=no" | |
2016 | fi | |
2017 | rm -f conftest* | |
2018 | fi | |
2019 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | |
2020 | echo "$ac_t""yes" 1>&6 | |
2021 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` | |
2022 | cat >> confdefs.h <<EOF | |
2023 | #define $ac_tr_hdr 1 | |
2024 | EOF | |
2025 | ||
2026 | else | |
2027 | echo "$ac_t""no" 1>&6 | |
2028 | fi | |
2029 | done | |
2030 | ||
2031 | for ac_func in getcwd munmap putenv setenv setlocale strchr strcasecmp \ | |
2032 | __argz_count __argz_stringify __argz_next | |
2033 | do | |
2034 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
d318976c | 2035 | echo "configure:2036: checking for $ac_func" >&5 |
c906108c SS |
2036 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
2037 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2038 | else | |
2039 | cat > conftest.$ac_ext <<EOF | |
d318976c | 2040 | #line 2041 "configure" |
c906108c SS |
2041 | #include "confdefs.h" |
2042 | /* System header to define __stub macros and hopefully few prototypes, | |
2043 | which can conflict with char $ac_func(); below. */ | |
2044 | #include <assert.h> | |
2045 | /* Override any gcc2 internal prototype to avoid an error. */ | |
2046 | /* We use char because int might match the return type of a gcc2 | |
2047 | builtin and then its argument prototype would still apply. */ | |
2048 | char $ac_func(); | |
2049 | ||
2050 | int main() { | |
2051 | ||
2052 | /* The GNU C library defines this for functions which it implements | |
2053 | to always fail with ENOSYS. Some functions are actually named | |
2054 | something starting with __ and the normal name is an alias. */ | |
2055 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
2056 | choke me | |
2057 | #else | |
2058 | $ac_func(); | |
2059 | #endif | |
2060 | ||
2061 | ; return 0; } | |
2062 | EOF | |
d318976c | 2063 | if { (eval echo configure:2064: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
c906108c SS |
2064 | rm -rf conftest* |
2065 | eval "ac_cv_func_$ac_func=yes" | |
2066 | else | |
2067 | echo "configure: failed program was:" >&5 | |
2068 | cat conftest.$ac_ext >&5 | |
2069 | rm -rf conftest* | |
2070 | eval "ac_cv_func_$ac_func=no" | |
2071 | fi | |
2072 | rm -f conftest* | |
2073 | fi | |
2074 | ||
2075 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then | |
2076 | echo "$ac_t""yes" 1>&6 | |
2077 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
2078 | cat >> confdefs.h <<EOF | |
2079 | #define $ac_tr_func 1 | |
2080 | EOF | |
2081 | ||
2082 | else | |
2083 | echo "$ac_t""no" 1>&6 | |
2084 | fi | |
2085 | done | |
2086 | ||
2087 | ||
2088 | if test "${ac_cv_func_stpcpy+set}" != "set"; then | |
2089 | for ac_func in stpcpy | |
2090 | do | |
2091 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
d318976c | 2092 | echo "configure:2093: checking for $ac_func" >&5 |
c906108c SS |
2093 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
2094 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2095 | else | |
2096 | cat > conftest.$ac_ext <<EOF | |
d318976c | 2097 | #line 2098 "configure" |
c906108c SS |
2098 | #include "confdefs.h" |
2099 | /* System header to define __stub macros and hopefully few prototypes, | |
2100 | which can conflict with char $ac_func(); below. */ | |
2101 | #include <assert.h> | |
2102 | /* Override any gcc2 internal prototype to avoid an error. */ | |
2103 | /* We use char because int might match the return type of a gcc2 | |
2104 | builtin and then its argument prototype would still apply. */ | |
2105 | char $ac_func(); | |
2106 | ||
2107 | int main() { | |
2108 | ||
2109 | /* The GNU C library defines this for functions which it implements | |
2110 | to always fail with ENOSYS. Some functions are actually named | |
2111 | something starting with __ and the normal name is an alias. */ | |
2112 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
2113 | choke me | |
2114 | #else | |
2115 | $ac_func(); | |
2116 | #endif | |
2117 | ||
2118 | ; return 0; } | |
2119 | EOF | |
d318976c | 2120 | if { (eval echo configure:2121: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
c906108c SS |
2121 | rm -rf conftest* |
2122 | eval "ac_cv_func_$ac_func=yes" | |
2123 | else | |
2124 | echo "configure: failed program was:" >&5 | |
2125 | cat conftest.$ac_ext >&5 | |
2126 | rm -rf conftest* | |
2127 | eval "ac_cv_func_$ac_func=no" | |
2128 | fi | |
2129 | rm -f conftest* | |
2130 | fi | |
2131 | ||
2132 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then | |
2133 | echo "$ac_t""yes" 1>&6 | |
2134 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
2135 | cat >> confdefs.h <<EOF | |
2136 | #define $ac_tr_func 1 | |
2137 | EOF | |
2138 | ||
2139 | else | |
2140 | echo "$ac_t""no" 1>&6 | |
2141 | fi | |
2142 | done | |
2143 | ||
2144 | fi | |
2145 | if test "${ac_cv_func_stpcpy}" = "yes"; then | |
2146 | cat >> confdefs.h <<\EOF | |
2147 | #define HAVE_STPCPY 1 | |
2148 | EOF | |
2149 | ||
2150 | fi | |
2151 | ||
2152 | if test $ac_cv_header_locale_h = yes; then | |
2153 | echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6 | |
d318976c | 2154 | echo "configure:2155: checking for LC_MESSAGES" >&5 |
c906108c SS |
2155 | if eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then |
2156 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2157 | else | |
2158 | cat > conftest.$ac_ext <<EOF | |
d318976c | 2159 | #line 2160 "configure" |
c906108c SS |
2160 | #include "confdefs.h" |
2161 | #include <locale.h> | |
2162 | int main() { | |
2163 | return LC_MESSAGES | |
2164 | ; return 0; } | |
2165 | EOF | |
d318976c | 2166 | if { (eval echo configure:2167: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
c906108c SS |
2167 | rm -rf conftest* |
2168 | am_cv_val_LC_MESSAGES=yes | |
2169 | else | |
2170 | echo "configure: failed program was:" >&5 | |
2171 | cat conftest.$ac_ext >&5 | |
2172 | rm -rf conftest* | |
2173 | am_cv_val_LC_MESSAGES=no | |
2174 | fi | |
2175 | rm -f conftest* | |
2176 | fi | |
2177 | ||
2178 | echo "$ac_t""$am_cv_val_LC_MESSAGES" 1>&6 | |
2179 | if test $am_cv_val_LC_MESSAGES = yes; then | |
2180 | cat >> confdefs.h <<\EOF | |
2181 | #define HAVE_LC_MESSAGES 1 | |
2182 | EOF | |
2183 | ||
2184 | fi | |
2185 | fi | |
2186 | echo $ac_n "checking whether NLS is requested""... $ac_c" 1>&6 | |
d318976c | 2187 | echo "configure:2188: checking whether NLS is requested" >&5 |
c906108c SS |
2188 | # Check whether --enable-nls or --disable-nls was given. |
2189 | if test "${enable_nls+set}" = set; then | |
2190 | enableval="$enable_nls" | |
2191 | USE_NLS=$enableval | |
2192 | else | |
2193 | USE_NLS=yes | |
2194 | fi | |
2195 | ||
2196 | echo "$ac_t""$USE_NLS" 1>&6 | |
2197 | ||
2198 | ||
2199 | USE_INCLUDED_LIBINTL=no | |
2200 | ||
2201 | if test "$USE_NLS" = "yes"; then | |
2202 | cat >> confdefs.h <<\EOF | |
2203 | #define ENABLE_NLS 1 | |
2204 | EOF | |
2205 | ||
2206 | echo $ac_n "checking whether included gettext is requested""... $ac_c" 1>&6 | |
d318976c | 2207 | echo "configure:2208: checking whether included gettext is requested" >&5 |
c906108c SS |
2208 | # Check whether --with-included-gettext or --without-included-gettext was given. |
2209 | if test "${with_included_gettext+set}" = set; then | |
2210 | withval="$with_included_gettext" | |
2211 | nls_cv_force_use_gnu_gettext=$withval | |
2212 | else | |
2213 | nls_cv_force_use_gnu_gettext=no | |
2214 | fi | |
2215 | ||
2216 | echo "$ac_t""$nls_cv_force_use_gnu_gettext" 1>&6 | |
2217 | ||
2218 | nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext" | |
2219 | if test "$nls_cv_force_use_gnu_gettext" != "yes"; then | |
2220 | nls_cv_header_intl= | |
2221 | nls_cv_header_libgt= | |
2222 | CATOBJEXT=NONE | |
2223 | ||
2224 | ac_safe=`echo "libintl.h" | sed 'y%./+-%__p_%'` | |
2225 | echo $ac_n "checking for libintl.h""... $ac_c" 1>&6 | |
d318976c | 2226 | echo "configure:2227: checking for libintl.h" >&5 |
c906108c SS |
2227 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
2228 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2229 | else | |
2230 | cat > conftest.$ac_ext <<EOF | |
d318976c | 2231 | #line 2232 "configure" |
c906108c SS |
2232 | #include "confdefs.h" |
2233 | #include <libintl.h> | |
2234 | EOF | |
2235 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
d318976c | 2236 | { (eval echo configure:2237: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
c906108c SS |
2237 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
2238 | if test -z "$ac_err"; then | |
2239 | rm -rf conftest* | |
2240 | eval "ac_cv_header_$ac_safe=yes" | |
2241 | else | |
2242 | echo "$ac_err" >&5 | |
2243 | echo "configure: failed program was:" >&5 | |
2244 | cat conftest.$ac_ext >&5 | |
2245 | rm -rf conftest* | |
2246 | eval "ac_cv_header_$ac_safe=no" | |
2247 | fi | |
2248 | rm -f conftest* | |
2249 | fi | |
2250 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | |
2251 | echo "$ac_t""yes" 1>&6 | |
2252 | echo $ac_n "checking for gettext in libc""... $ac_c" 1>&6 | |
d318976c | 2253 | echo "configure:2254: checking for gettext in libc" >&5 |
c906108c SS |
2254 | if eval "test \"`echo '$''{'gt_cv_func_gettext_libc'+set}'`\" = set"; then |
2255 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2256 | else | |
2257 | cat > conftest.$ac_ext <<EOF | |
d318976c | 2258 | #line 2259 "configure" |
c906108c SS |
2259 | #include "confdefs.h" |
2260 | #include <libintl.h> | |
2261 | int main() { | |
2262 | return (int) gettext ("") | |
2263 | ; return 0; } | |
2264 | EOF | |
d318976c | 2265 | if { (eval echo configure:2266: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
c906108c SS |
2266 | rm -rf conftest* |
2267 | gt_cv_func_gettext_libc=yes | |
2268 | else | |
2269 | echo "configure: failed program was:" >&5 | |
2270 | cat conftest.$ac_ext >&5 | |
2271 | rm -rf conftest* | |
2272 | gt_cv_func_gettext_libc=no | |
2273 | fi | |
2274 | rm -f conftest* | |
2275 | fi | |
2276 | ||
2277 | echo "$ac_t""$gt_cv_func_gettext_libc" 1>&6 | |
2278 | ||
2279 | if test "$gt_cv_func_gettext_libc" != "yes"; then | |
2280 | echo $ac_n "checking for bindtextdomain in -lintl""... $ac_c" 1>&6 | |
d318976c | 2281 | echo "configure:2282: checking for bindtextdomain in -lintl" >&5 |
c906108c SS |
2282 | ac_lib_var=`echo intl'_'bindtextdomain | sed 'y%./+-%__p_%'` |
2283 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then | |
2284 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2285 | else | |
2286 | ac_save_LIBS="$LIBS" | |
2287 | LIBS="-lintl $LIBS" | |
2288 | cat > conftest.$ac_ext <<EOF | |
d318976c | 2289 | #line 2290 "configure" |
c906108c SS |
2290 | #include "confdefs.h" |
2291 | /* Override any gcc2 internal prototype to avoid an error. */ | |
2292 | /* We use char because int might match the return type of a gcc2 | |
2293 | builtin and then its argument prototype would still apply. */ | |
2294 | char bindtextdomain(); | |
2295 | ||
2296 | int main() { | |
2297 | bindtextdomain() | |
2298 | ; return 0; } | |
2299 | EOF | |
d318976c | 2300 | if { (eval echo configure:2301: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
c906108c SS |
2301 | rm -rf conftest* |
2302 | eval "ac_cv_lib_$ac_lib_var=yes" | |
2303 | else | |
2304 | echo "configure: failed program was:" >&5 | |
2305 | cat conftest.$ac_ext >&5 | |
2306 | rm -rf conftest* | |
2307 | eval "ac_cv_lib_$ac_lib_var=no" | |
2308 | fi | |
2309 | rm -f conftest* | |
2310 | LIBS="$ac_save_LIBS" | |
2311 | ||
2312 | fi | |
2313 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then | |
2314 | echo "$ac_t""yes" 1>&6 | |
2315 | echo $ac_n "checking for gettext in libintl""... $ac_c" 1>&6 | |
d318976c | 2316 | echo "configure:2317: checking for gettext in libintl" >&5 |
c906108c SS |
2317 | if eval "test \"`echo '$''{'gt_cv_func_gettext_libintl'+set}'`\" = set"; then |
2318 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2319 | else | |
2320 | cat > conftest.$ac_ext <<EOF | |
d318976c | 2321 | #line 2322 "configure" |
c906108c SS |
2322 | #include "confdefs.h" |
2323 | ||
2324 | int main() { | |
2325 | return (int) gettext ("") | |
2326 | ; return 0; } | |
2327 | EOF | |
d318976c | 2328 | if { (eval echo configure:2329: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
c906108c SS |
2329 | rm -rf conftest* |
2330 | gt_cv_func_gettext_libintl=yes | |
2331 | else | |
2332 | echo "configure: failed program was:" >&5 | |
2333 | cat conftest.$ac_ext >&5 | |
2334 | rm -rf conftest* | |
2335 | gt_cv_func_gettext_libintl=no | |
2336 | fi | |
2337 | rm -f conftest* | |
2338 | fi | |
2339 | ||
2340 | echo "$ac_t""$gt_cv_func_gettext_libintl" 1>&6 | |
2341 | else | |
2342 | echo "$ac_t""no" 1>&6 | |
2343 | fi | |
2344 | ||
2345 | fi | |
2346 | ||
2347 | if test "$gt_cv_func_gettext_libc" = "yes" \ | |
2348 | || test "$gt_cv_func_gettext_libintl" = "yes"; then | |
2349 | cat >> confdefs.h <<\EOF | |
2350 | #define HAVE_GETTEXT 1 | |
2351 | EOF | |
2352 | ||
2353 | # Extract the first word of "msgfmt", so it can be a program name with args. | |
2354 | set dummy msgfmt; ac_word=$2 | |
2355 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
d318976c | 2356 | echo "configure:2357: checking for $ac_word" >&5 |
c906108c SS |
2357 | if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then |
2358 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2359 | else | |
2360 | case "$MSGFMT" in | |
2361 | /*) | |
2362 | ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. | |
2363 | ;; | |
2364 | *) | |
2365 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" | |
2366 | for ac_dir in $PATH; do | |
2367 | test -z "$ac_dir" && ac_dir=. | |
2368 | if test -f $ac_dir/$ac_word; then | |
2369 | if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then | |
2370 | ac_cv_path_MSGFMT="$ac_dir/$ac_word" | |
2371 | break | |
2372 | fi | |
2373 | fi | |
2374 | done | |
2375 | IFS="$ac_save_ifs" | |
2376 | test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="no" | |
2377 | ;; | |
2378 | esac | |
2379 | fi | |
2380 | MSGFMT="$ac_cv_path_MSGFMT" | |
2381 | if test -n "$MSGFMT"; then | |
2382 | echo "$ac_t""$MSGFMT" 1>&6 | |
2383 | else | |
2384 | echo "$ac_t""no" 1>&6 | |
2385 | fi | |
2386 | if test "$MSGFMT" != "no"; then | |
2387 | for ac_func in dcgettext | |
2388 | do | |
2389 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
d318976c | 2390 | echo "configure:2391: checking for $ac_func" >&5 |
c906108c SS |
2391 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
2392 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2393 | else | |
2394 | cat > conftest.$ac_ext <<EOF | |
d318976c | 2395 | #line 2396 "configure" |
c906108c SS |
2396 | #include "confdefs.h" |
2397 | /* System header to define __stub macros and hopefully few prototypes, | |
2398 | which can conflict with char $ac_func(); below. */ | |
2399 | #include <assert.h> | |
2400 | /* Override any gcc2 internal prototype to avoid an error. */ | |
2401 | /* We use char because int might match the return type of a gcc2 | |
2402 | builtin and then its argument prototype would still apply. */ | |
2403 | char $ac_func(); | |
2404 | ||
2405 | int main() { | |
2406 | ||
2407 | /* The GNU C library defines this for functions which it implements | |
2408 | to always fail with ENOSYS. Some functions are actually named | |
2409 | something starting with __ and the normal name is an alias. */ | |
2410 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
2411 | choke me | |
2412 | #else | |
2413 | $ac_func(); | |
2414 | #endif | |
2415 | ||
2416 | ; return 0; } | |
2417 | EOF | |
d318976c | 2418 | if { (eval echo configure:2419: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
c906108c SS |
2419 | rm -rf conftest* |
2420 | eval "ac_cv_func_$ac_func=yes" | |
2421 | else | |
2422 | echo "configure: failed program was:" >&5 | |
2423 | cat conftest.$ac_ext >&5 | |
2424 | rm -rf conftest* | |
2425 | eval "ac_cv_func_$ac_func=no" | |
2426 | fi | |
2427 | rm -f conftest* | |
2428 | fi | |
2429 | ||
2430 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then | |
2431 | echo "$ac_t""yes" 1>&6 | |
2432 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
2433 | cat >> confdefs.h <<EOF | |
2434 | #define $ac_tr_func 1 | |
2435 | EOF | |
2436 | ||
2437 | else | |
2438 | echo "$ac_t""no" 1>&6 | |
2439 | fi | |
2440 | done | |
2441 | ||
2442 | # Extract the first word of "gmsgfmt", so it can be a program name with args. | |
2443 | set dummy gmsgfmt; ac_word=$2 | |
2444 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
d318976c | 2445 | echo "configure:2446: checking for $ac_word" >&5 |
c906108c SS |
2446 | if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then |
2447 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2448 | else | |
2449 | case "$GMSGFMT" in | |
2450 | /*) | |
2451 | ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path. | |
2452 | ;; | |
2453 | ?:/*) | |
2454 | ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path. | |
2455 | ;; | |
2456 | *) | |
2457 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
2458 | ac_dummy="$PATH" | |
2459 | for ac_dir in $ac_dummy; do | |
2460 | test -z "$ac_dir" && ac_dir=. | |
2461 | if test -f $ac_dir/$ac_word; then | |
2462 | ac_cv_path_GMSGFMT="$ac_dir/$ac_word" | |
2463 | break | |
2464 | fi | |
2465 | done | |
2466 | IFS="$ac_save_ifs" | |
2467 | test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT" | |
2468 | ;; | |
2469 | esac | |
2470 | fi | |
2471 | GMSGFMT="$ac_cv_path_GMSGFMT" | |
2472 | if test -n "$GMSGFMT"; then | |
2473 | echo "$ac_t""$GMSGFMT" 1>&6 | |
2474 | else | |
2475 | echo "$ac_t""no" 1>&6 | |
2476 | fi | |
2477 | ||
2478 | # Extract the first word of "xgettext", so it can be a program name with args. | |
2479 | set dummy xgettext; ac_word=$2 | |
2480 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
d318976c | 2481 | echo "configure:2482: checking for $ac_word" >&5 |
c906108c SS |
2482 | if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then |
2483 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2484 | else | |
2485 | case "$XGETTEXT" in | |
2486 | /*) | |
2487 | ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path. | |
2488 | ;; | |
2489 | *) | |
2490 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" | |
2491 | for ac_dir in $PATH; do | |
2492 | test -z "$ac_dir" && ac_dir=. | |
2493 | if test -f $ac_dir/$ac_word; then | |
2494 | if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then | |
2495 | ac_cv_path_XGETTEXT="$ac_dir/$ac_word" | |
2496 | break | |
2497 | fi | |
2498 | fi | |
2499 | done | |
2500 | IFS="$ac_save_ifs" | |
2501 | test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":" | |
2502 | ;; | |
2503 | esac | |
2504 | fi | |
2505 | XGETTEXT="$ac_cv_path_XGETTEXT" | |
2506 | if test -n "$XGETTEXT"; then | |
2507 | echo "$ac_t""$XGETTEXT" 1>&6 | |
2508 | else | |
2509 | echo "$ac_t""no" 1>&6 | |
2510 | fi | |
2511 | ||
2512 | cat > conftest.$ac_ext <<EOF | |
d318976c | 2513 | #line 2514 "configure" |
c906108c SS |
2514 | #include "confdefs.h" |
2515 | ||
2516 | int main() { | |
2517 | extern int _nl_msg_cat_cntr; | |
2518 | return _nl_msg_cat_cntr | |
2519 | ; return 0; } | |
2520 | EOF | |
d318976c | 2521 | if { (eval echo configure:2522: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
c906108c SS |
2522 | rm -rf conftest* |
2523 | CATOBJEXT=.gmo | |
2524 | DATADIRNAME=share | |
2525 | else | |
2526 | echo "configure: failed program was:" >&5 | |
2527 | cat conftest.$ac_ext >&5 | |
2528 | rm -rf conftest* | |
2529 | CATOBJEXT=.mo | |
2530 | DATADIRNAME=lib | |
2531 | fi | |
2532 | rm -f conftest* | |
2533 | INSTOBJEXT=.mo | |
2534 | fi | |
2535 | fi | |
2536 | ||
2537 | else | |
2538 | echo "$ac_t""no" 1>&6 | |
2539 | fi | |
2540 | ||
2541 | ||
2542 | ||
2543 | if test "$CATOBJEXT" = "NONE"; then | |
2544 | nls_cv_use_gnu_gettext=yes | |
2545 | fi | |
2546 | fi | |
2547 | ||
2548 | if test "$nls_cv_use_gnu_gettext" = "yes"; then | |
2549 | INTLOBJS="\$(GETTOBJS)" | |
2550 | # Extract the first word of "msgfmt", so it can be a program name with args. | |
2551 | set dummy msgfmt; ac_word=$2 | |
2552 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
d318976c | 2553 | echo "configure:2554: checking for $ac_word" >&5 |
c906108c SS |
2554 | if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then |
2555 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2556 | else | |
2557 | case "$MSGFMT" in | |
2558 | /*) | |
2559 | ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. | |
2560 | ;; | |
2561 | *) | |
2562 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" | |
2563 | for ac_dir in $PATH; do | |
2564 | test -z "$ac_dir" && ac_dir=. | |
2565 | if test -f $ac_dir/$ac_word; then | |
2566 | if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then | |
2567 | ac_cv_path_MSGFMT="$ac_dir/$ac_word" | |
2568 | break | |
2569 | fi | |
2570 | fi | |
2571 | done | |
2572 | IFS="$ac_save_ifs" | |
2573 | test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="msgfmt" | |
2574 | ;; | |
2575 | esac | |
2576 | fi | |
2577 | MSGFMT="$ac_cv_path_MSGFMT" | |
2578 | if test -n "$MSGFMT"; then | |
2579 | echo "$ac_t""$MSGFMT" 1>&6 | |
2580 | else | |
2581 | echo "$ac_t""no" 1>&6 | |
2582 | fi | |
2583 | ||
2584 | # Extract the first word of "gmsgfmt", so it can be a program name with args. | |
2585 | set dummy gmsgfmt; ac_word=$2 | |
2586 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
d318976c | 2587 | echo "configure:2588: checking for $ac_word" >&5 |
c906108c SS |
2588 | if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then |
2589 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2590 | else | |
2591 | case "$GMSGFMT" in | |
2592 | /*) | |
2593 | ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path. | |
2594 | ;; | |
2595 | ?:/*) | |
2596 | ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path. | |
2597 | ;; | |
2598 | *) | |
2599 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
2600 | ac_dummy="$PATH" | |
2601 | for ac_dir in $ac_dummy; do | |
2602 | test -z "$ac_dir" && ac_dir=. | |
2603 | if test -f $ac_dir/$ac_word; then | |
2604 | ac_cv_path_GMSGFMT="$ac_dir/$ac_word" | |
2605 | break | |
2606 | fi | |
2607 | done | |
2608 | IFS="$ac_save_ifs" | |
2609 | test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT" | |
2610 | ;; | |
2611 | esac | |
2612 | fi | |
2613 | GMSGFMT="$ac_cv_path_GMSGFMT" | |
2614 | if test -n "$GMSGFMT"; then | |
2615 | echo "$ac_t""$GMSGFMT" 1>&6 | |
2616 | else | |
2617 | echo "$ac_t""no" 1>&6 | |
2618 | fi | |
2619 | ||
2620 | # Extract the first word of "xgettext", so it can be a program name with args. | |
2621 | set dummy xgettext; ac_word=$2 | |
2622 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
d318976c | 2623 | echo "configure:2624: checking for $ac_word" >&5 |
c906108c SS |
2624 | if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then |
2625 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2626 | else | |
2627 | case "$XGETTEXT" in | |
2628 | /*) | |
2629 | ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path. | |
2630 | ;; | |
2631 | *) | |
2632 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" | |
2633 | for ac_dir in $PATH; do | |
2634 | test -z "$ac_dir" && ac_dir=. | |
2635 | if test -f $ac_dir/$ac_word; then | |
2636 | if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then | |
2637 | ac_cv_path_XGETTEXT="$ac_dir/$ac_word" | |
2638 | break | |
2639 | fi | |
2640 | fi | |
2641 | done | |
2642 | IFS="$ac_save_ifs" | |
2643 | test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":" | |
2644 | ;; | |
2645 | esac | |
2646 | fi | |
2647 | XGETTEXT="$ac_cv_path_XGETTEXT" | |
2648 | if test -n "$XGETTEXT"; then | |
2649 | echo "$ac_t""$XGETTEXT" 1>&6 | |
2650 | else | |
2651 | echo "$ac_t""no" 1>&6 | |
2652 | fi | |
2653 | ||
2654 | ||
2655 | USE_INCLUDED_LIBINTL=yes | |
2656 | CATOBJEXT=.gmo | |
2657 | INSTOBJEXT=.mo | |
2658 | DATADIRNAME=share | |
2659 | INTLDEPS='$(top_builddir)/../intl/libintl.a' | |
2660 | INTLLIBS=$INTLDEPS | |
2661 | LIBS=`echo $LIBS | sed -e 's/-lintl//'` | |
2662 | nls_cv_header_intl=libintl.h | |
2663 | nls_cv_header_libgt=libgettext.h | |
2664 | fi | |
2665 | ||
2666 | if test "$XGETTEXT" != ":"; then | |
2667 | if $XGETTEXT --omit-header /dev/null 2> /dev/null; then | |
2668 | : ; | |
2669 | else | |
2670 | echo "$ac_t""found xgettext programs is not GNU xgettext; ignore it" 1>&6 | |
2671 | XGETTEXT=":" | |
2672 | fi | |
2673 | fi | |
2674 | ||
2675 | # We need to process the po/ directory. | |
2676 | POSUB=po | |
2677 | else | |
2678 | DATADIRNAME=share | |
2679 | nls_cv_header_intl=libintl.h | |
2680 | nls_cv_header_libgt=libgettext.h | |
2681 | fi | |
2682 | ||
2683 | # If this is used in GNU gettext we have to set USE_NLS to `yes' | |
2684 | # because some of the sources are only built for this goal. | |
2685 | if test "$PACKAGE" = gettext; then | |
2686 | USE_NLS=yes | |
2687 | USE_INCLUDED_LIBINTL=yes | |
2688 | fi | |
2689 | ||
2690 | for lang in $ALL_LINGUAS; do | |
2691 | GMOFILES="$GMOFILES $lang.gmo" | |
2692 | POFILES="$POFILES $lang.po" | |
2693 | done | |
2694 | ||
2695 | ||
2696 | ||
2697 | ||
2698 | ||
2699 | ||
2700 | ||
2701 | ||
2702 | ||
2703 | ||
2704 | ||
2705 | ||
2706 | ||
2707 | ||
2708 | if test "x$CATOBJEXT" != "x"; then | |
2709 | if test "x$ALL_LINGUAS" = "x"; then | |
2710 | LINGUAS= | |
2711 | else | |
2712 | echo $ac_n "checking for catalogs to be installed""... $ac_c" 1>&6 | |
d318976c | 2713 | echo "configure:2714: checking for catalogs to be installed" >&5 |
c906108c SS |
2714 | NEW_LINGUAS= |
2715 | for lang in ${LINGUAS=$ALL_LINGUAS}; do | |
2716 | case "$ALL_LINGUAS" in | |
2717 | *$lang*) NEW_LINGUAS="$NEW_LINGUAS $lang" ;; | |
2718 | esac | |
2719 | done | |
2720 | LINGUAS=$NEW_LINGUAS | |
2721 | echo "$ac_t""$LINGUAS" 1>&6 | |
2722 | fi | |
2723 | ||
2724 | if test -n "$LINGUAS"; then | |
2725 | for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done | |
2726 | fi | |
2727 | fi | |
2728 | ||
2729 | if test $ac_cv_header_locale_h = yes; then | |
2730 | INCLUDE_LOCALE_H="#include <locale.h>" | |
2731 | else | |
2732 | INCLUDE_LOCALE_H="\ | |
2733 | /* The system does not provide the header <locale.h>. Take care yourself. */" | |
2734 | fi | |
2735 | ||
2736 | ||
2737 | if test -f $srcdir/po2tbl.sed.in; then | |
2738 | if test "$CATOBJEXT" = ".cat"; then | |
2739 | ac_safe=`echo "linux/version.h" | sed 'y%./+-%__p_%'` | |
2740 | echo $ac_n "checking for linux/version.h""... $ac_c" 1>&6 | |
d318976c | 2741 | echo "configure:2742: checking for linux/version.h" >&5 |
c906108c SS |
2742 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
2743 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2744 | else | |
2745 | cat > conftest.$ac_ext <<EOF | |
d318976c | 2746 | #line 2747 "configure" |
c906108c SS |
2747 | #include "confdefs.h" |
2748 | #include <linux/version.h> | |
2749 | EOF | |
2750 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
d318976c | 2751 | { (eval echo configure:2752: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
c906108c SS |
2752 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
2753 | if test -z "$ac_err"; then | |
2754 | rm -rf conftest* | |
2755 | eval "ac_cv_header_$ac_safe=yes" | |
2756 | else | |
2757 | echo "$ac_err" >&5 | |
2758 | echo "configure: failed program was:" >&5 | |
2759 | cat conftest.$ac_ext >&5 | |
2760 | rm -rf conftest* | |
2761 | eval "ac_cv_header_$ac_safe=no" | |
2762 | fi | |
2763 | rm -f conftest* | |
2764 | fi | |
2765 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | |
2766 | echo "$ac_t""yes" 1>&6 | |
2767 | msgformat=linux | |
2768 | else | |
2769 | echo "$ac_t""no" 1>&6 | |
2770 | msgformat=xopen | |
2771 | fi | |
2772 | ||
2773 | ||
2774 | sed -e '/^#/d' $srcdir/$msgformat-msg.sed > po2msg.sed | |
2775 | fi | |
2776 | sed -e '/^#.*[^\\]$/d' -e '/^#$/d' \ | |
2777 | $srcdir/po2tbl.sed.in > po2tbl.sed | |
2778 | fi | |
2779 | ||
2780 | if test "$PACKAGE" = "gettext"; then | |
2781 | GT_NO="#NO#" | |
2782 | GT_YES= | |
2783 | else | |
2784 | GT_NO= | |
2785 | GT_YES="#YES#" | |
2786 | fi | |
2787 | ||
2788 | ||
2789 | ||
2790 | MKINSTALLDIRS="\$(srcdir)/../../mkinstalldirs" | |
2791 | ||
2792 | ||
2793 | l= | |
2794 | ||
2795 | ||
2796 | if test -d $srcdir/po; then | |
2797 | test -d po || mkdir po | |
2798 | if test "x$srcdir" != "x."; then | |
2799 | if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then | |
2800 | posrcprefix="$srcdir/" | |
2801 | else | |
2802 | posrcprefix="../$srcdir/" | |
2803 | fi | |
2804 | else | |
2805 | posrcprefix="../" | |
2806 | fi | |
2807 | rm -f po/POTFILES | |
2808 | sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \ | |
2809 | < $srcdir/po/POTFILES.in > po/POTFILES | |
2810 | fi | |
2811 | ||
2812 | ||
2813 | ||
2814 | CONFIG_OBS= | |
b46cd165 | 2815 | CONFIG_LOBS= |
c906108c SS |
2816 | CONFIG_DEPS= |
2817 | CONFIG_SRCS= | |
fb40c209 AC |
2818 | CONFIG_INITS= |
2819 | ENABLE_CFLAGS= | |
b3a90332 AC |
2820 | CONFIG_ALL= |
2821 | CONFIG_CLEAN= | |
e56ac5c3 AC |
2822 | CONFIG_INSTALL= |
2823 | CONFIG_UNINSTALL= | |
c906108c SS |
2824 | |
2825 | configdirs="doc testsuite" | |
2826 | ||
96baa820 JM |
2827 | # Check whether --enable-multi-ice or --disable-multi-ice was given. |
2828 | if test "${enable_multi_ice+set}" = set; then | |
2829 | enableval="$enable_multi_ice" | |
2830 | case "${enableval}" in | |
2831 | yes ) enable_multi_ice="yes" ;; | |
2832 | no) enable_multi_ice="no" ;; | |
2833 | *) { echo "configure: error: Bad value for --enable-multi-ice: ${enableval}" 1>&2; exit 1; } ;; | |
2834 | esac | |
2835 | ||
2836 | fi | |
2837 | ||
2838 | ||
2839 | if test "${enable_multi_ice}" = "yes"; then | |
2840 | configdirs="${configdirs} multi-ice" | |
2841 | fi | |
2842 | ||
c906108c SS |
2843 | |
2844 | . ${srcdir}/configure.host | |
2845 | ||
2846 | . ${srcdir}/configure.tgt | |
2847 | ||
1ba607ad AC |
2848 | targ=${target} ; . ${srcdir}/../bfd/config.bfd |
2849 | ||
2850 | ||
2851 | targ=${target} | |
2852 | . ${srcdir}/../bfd/config.bfd | |
5c8cc331 AC |
2853 | |
2854 | targ_archs=`echo ${targ_archs} | sed -e 's/ .*//;'` | |
2855 | ||
1ba607ad AC |
2856 | if test x"${targ_archs}" != x ; then |
2857 | cat >> confdefs.h <<EOF | |
2858 | #define DEFAULT_BFD_ARCH ${targ_archs} | |
2859 | EOF | |
2860 | ||
2861 | fi | |
2862 | if test x"${targ_defvec}" != x ; then | |
2863 | cat >> confdefs.h <<EOF | |
2864 | #define DEFAULT_BFD_VEC ${targ_defvec} | |
2865 | EOF | |
2866 | ||
2867 | fi | |
c906108c | 2868 | |
3b851bce | 2869 | for ac_prog in mawk gawk nawk awk |
7a292a7a SS |
2870 | do |
2871 | # Extract the first word of "$ac_prog", so it can be a program name with args. | |
2872 | set dummy $ac_prog; ac_word=$2 | |
2873 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
b46cd165 | 2874 | echo "configure:2875: checking for $ac_word" >&5 |
7a292a7a SS |
2875 | if eval "test \"`echo '$''{'ac_cv_prog_AWK'+set}'`\" = set"; then |
2876 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2877 | else | |
2878 | if test -n "$AWK"; then | |
2879 | ac_cv_prog_AWK="$AWK" # Let the user override the test. | |
2880 | else | |
2881 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
2882 | ac_dummy="$PATH" | |
2883 | for ac_dir in $ac_dummy; do | |
2884 | test -z "$ac_dir" && ac_dir=. | |
2885 | if test -f $ac_dir/$ac_word; then | |
2886 | ac_cv_prog_AWK="$ac_prog" | |
2887 | break | |
2888 | fi | |
2889 | done | |
2890 | IFS="$ac_save_ifs" | |
2891 | fi | |
2892 | fi | |
2893 | AWK="$ac_cv_prog_AWK" | |
2894 | if test -n "$AWK"; then | |
2895 | echo "$ac_t""$AWK" 1>&6 | |
2896 | else | |
2897 | echo "$ac_t""no" 1>&6 | |
2898 | fi | |
2899 | ||
2900 | test -n "$AWK" && break | |
2901 | done | |
2902 | ||
c906108c SS |
2903 | # Find a good install program. We prefer a C program (faster), |
2904 | # so one script is as good as another. But avoid the broken or | |
2905 | # incompatible versions: | |
2906 | # SysV /etc/install, /usr/sbin/install | |
2907 | # SunOS /usr/etc/install | |
2908 | # IRIX /sbin/install | |
2909 | # AIX /bin/install | |
2910 | # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag | |
2911 | # AFS /usr/afsws/bin/install, which mishandles nonexistent args | |
2912 | # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" | |
2913 | # ./install, which can be erroneously created by make from ./install.sh. | |
2914 | echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6 | |
b46cd165 | 2915 | echo "configure:2916: checking for a BSD compatible install" >&5 |
c906108c SS |
2916 | if test -z "$INSTALL"; then |
2917 | if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then | |
2918 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2919 | else | |
2920 | IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":" | |
2921 | for ac_dir in $PATH; do | |
2922 | # Account for people who put trailing slashes in PATH elements. | |
2923 | case "$ac_dir/" in | |
2924 | /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;; | |
2925 | *) | |
2926 | # OSF1 and SCO ODT 3.0 have their own names for install. | |
2927 | # Don't use installbsd from OSF since it installs stuff as root | |
2928 | # by default. | |
2929 | for ac_prog in ginstall scoinst install; do | |
2930 | if test -f $ac_dir/$ac_prog; then | |
2931 | if test $ac_prog = install && | |
2932 | grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then | |
2933 | # AIX install. It has an incompatible calling convention. | |
2934 | : | |
2935 | else | |
2936 | ac_cv_path_install="$ac_dir/$ac_prog -c" | |
2937 | break 2 | |
2938 | fi | |
2939 | fi | |
2940 | done | |
2941 | ;; | |
2942 | esac | |
2943 | done | |
2944 | IFS="$ac_save_IFS" | |
2945 | ||
2946 | fi | |
2947 | if test "${ac_cv_path_install+set}" = set; then | |
2948 | INSTALL="$ac_cv_path_install" | |
2949 | else | |
2950 | # As a last resort, use the slow shell script. We don't cache a | |
2951 | # path for INSTALL within a source directory, because that will | |
2952 | # break other packages using the cache if that directory is | |
2953 | # removed, or if the path is relative. | |
2954 | INSTALL="$ac_install_sh" | |
2955 | fi | |
2956 | fi | |
2957 | echo "$ac_t""$INSTALL" 1>&6 | |
2958 | ||
2959 | # Use test -z because SunOS4 sh mishandles braces in ${var-val}. | |
2960 | # It thinks the first close brace ends the variable substitution. | |
2961 | test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' | |
2962 | ||
2963 | test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}' | |
2964 | ||
2965 | test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' | |
2966 | ||
2967 | if test $host != $build; then | |
2968 | ac_tool_prefix=${host_alias}- | |
2969 | else | |
2970 | ac_tool_prefix= | |
2971 | fi | |
2972 | ||
2973 | # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args. | |
2974 | set dummy ${ac_tool_prefix}ar; ac_word=$2 | |
2975 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
b46cd165 | 2976 | echo "configure:2977: checking for $ac_word" >&5 |
c906108c SS |
2977 | if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then |
2978 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2979 | else | |
2980 | if test -n "$AR"; then | |
2981 | ac_cv_prog_AR="$AR" # Let the user override the test. | |
2982 | else | |
2983 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
2984 | ac_dummy="$PATH" | |
2985 | for ac_dir in $ac_dummy; do | |
2986 | test -z "$ac_dir" && ac_dir=. | |
2987 | if test -f $ac_dir/$ac_word; then | |
2988 | ac_cv_prog_AR="${ac_tool_prefix}ar" | |
2989 | break | |
2990 | fi | |
2991 | done | |
2992 | IFS="$ac_save_ifs" | |
2993 | test -z "$ac_cv_prog_AR" && ac_cv_prog_AR="ar" | |
2994 | fi | |
2995 | fi | |
2996 | AR="$ac_cv_prog_AR" | |
2997 | if test -n "$AR"; then | |
2998 | echo "$ac_t""$AR" 1>&6 | |
2999 | else | |
3000 | echo "$ac_t""no" 1>&6 | |
3001 | fi | |
3002 | ||
3003 | ||
3004 | ||
3005 | # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. | |
3006 | set dummy ${ac_tool_prefix}ranlib; ac_word=$2 | |
3007 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
b46cd165 | 3008 | echo "configure:3009: checking for $ac_word" >&5 |
c906108c SS |
3009 | if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then |
3010 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3011 | else | |
3012 | if test -n "$RANLIB"; then | |
3013 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. | |
3014 | else | |
3015 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
3016 | ac_dummy="$PATH" | |
3017 | for ac_dir in $ac_dummy; do | |
3018 | test -z "$ac_dir" && ac_dir=. | |
3019 | if test -f $ac_dir/$ac_word; then | |
3020 | ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" | |
3021 | break | |
3022 | fi | |
3023 | done | |
3024 | IFS="$ac_save_ifs" | |
3025 | fi | |
3026 | fi | |
3027 | RANLIB="$ac_cv_prog_RANLIB" | |
3028 | if test -n "$RANLIB"; then | |
3029 | echo "$ac_t""$RANLIB" 1>&6 | |
3030 | else | |
3031 | echo "$ac_t""no" 1>&6 | |
3032 | fi | |
3033 | ||
3034 | ||
3035 | if test -z "$ac_cv_prog_RANLIB"; then | |
3036 | if test -n "$ac_tool_prefix"; then | |
3037 | # Extract the first word of "ranlib", so it can be a program name with args. | |
3038 | set dummy ranlib; ac_word=$2 | |
3039 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
b46cd165 | 3040 | echo "configure:3041: checking for $ac_word" >&5 |
c906108c SS |
3041 | if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then |
3042 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3043 | else | |
3044 | if test -n "$RANLIB"; then | |
3045 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. | |
3046 | else | |
3047 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
3048 | ac_dummy="$PATH" | |
3049 | for ac_dir in $ac_dummy; do | |
3050 | test -z "$ac_dir" && ac_dir=. | |
3051 | if test -f $ac_dir/$ac_word; then | |
3052 | ac_cv_prog_RANLIB="ranlib" | |
3053 | break | |
3054 | fi | |
3055 | done | |
3056 | IFS="$ac_save_ifs" | |
3057 | test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":" | |
3058 | fi | |
3059 | fi | |
3060 | RANLIB="$ac_cv_prog_RANLIB" | |
3061 | if test -n "$RANLIB"; then | |
3062 | echo "$ac_t""$RANLIB" 1>&6 | |
3063 | else | |
3064 | echo "$ac_t""no" 1>&6 | |
3065 | fi | |
3066 | ||
3067 | else | |
3068 | RANLIB=":" | |
3069 | fi | |
3070 | fi | |
3071 | ||
95ca63c4 CF |
3072 | # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args. |
3073 | set dummy ${ac_tool_prefix}dlltool; ac_word=$2 | |
3074 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
b46cd165 | 3075 | echo "configure:3076: checking for $ac_word" >&5 |
95ca63c4 CF |
3076 | if eval "test \"`echo '$''{'ac_cv_prog_DLLTOOL'+set}'`\" = set"; then |
3077 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3078 | else | |
3079 | if test -n "$DLLTOOL"; then | |
3080 | ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test. | |
3081 | else | |
3082 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
3083 | ac_dummy="$PATH" | |
3084 | for ac_dir in $ac_dummy; do | |
3085 | test -z "$ac_dir" && ac_dir=. | |
3086 | if test -f $ac_dir/$ac_word; then | |
3087 | ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool" | |
3088 | break | |
3089 | fi | |
3090 | done | |
3091 | IFS="$ac_save_ifs" | |
3092 | test -z "$ac_cv_prog_DLLTOOL" && ac_cv_prog_DLLTOOL="dlltool" | |
3093 | fi | |
3094 | fi | |
3095 | DLLTOOL="$ac_cv_prog_DLLTOOL" | |
3096 | if test -n "$DLLTOOL"; then | |
3097 | echo "$ac_t""$DLLTOOL" 1>&6 | |
3098 | else | |
3099 | echo "$ac_t""no" 1>&6 | |
3100 | fi | |
3101 | ||
3102 | ||
3103 | ||
3104 | # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args. | |
3105 | set dummy ${ac_tool_prefix}windres; ac_word=$2 | |
3106 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
b46cd165 | 3107 | echo "configure:3108: checking for $ac_word" >&5 |
95ca63c4 CF |
3108 | if eval "test \"`echo '$''{'ac_cv_prog_WINDRES'+set}'`\" = set"; then |
3109 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3110 | else | |
3111 | if test -n "$WINDRES"; then | |
3112 | ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test. | |
3113 | else | |
3114 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
3115 | ac_dummy="$PATH" | |
3116 | for ac_dir in $ac_dummy; do | |
3117 | test -z "$ac_dir" && ac_dir=. | |
3118 | if test -f $ac_dir/$ac_word; then | |
3119 | ac_cv_prog_WINDRES="${ac_tool_prefix}windres" | |
3120 | break | |
3121 | fi | |
3122 | done | |
3123 | IFS="$ac_save_ifs" | |
3124 | test -z "$ac_cv_prog_WINDRES" && ac_cv_prog_WINDRES="windres" | |
3125 | fi | |
3126 | fi | |
3127 | WINDRES="$ac_cv_prog_WINDRES" | |
3128 | if test -n "$WINDRES"; then | |
3129 | echo "$ac_t""$WINDRES" 1>&6 | |
3130 | else | |
3131 | echo "$ac_t""no" 1>&6 | |
3132 | fi | |
3133 | ||
3134 | ||
3135 | ||
c906108c SS |
3136 | for ac_prog in 'bison -y' byacc |
3137 | do | |
3138 | # Extract the first word of "$ac_prog", so it can be a program name with args. | |
3139 | set dummy $ac_prog; ac_word=$2 | |
3140 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
b46cd165 | 3141 | echo "configure:3142: checking for $ac_word" >&5 |
c906108c SS |
3142 | if eval "test \"`echo '$''{'ac_cv_prog_YACC'+set}'`\" = set"; then |
3143 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3144 | else | |
3145 | if test -n "$YACC"; then | |
3146 | ac_cv_prog_YACC="$YACC" # Let the user override the test. | |
3147 | else | |
3148 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
3149 | ac_dummy="$PATH" | |
3150 | for ac_dir in $ac_dummy; do | |
3151 | test -z "$ac_dir" && ac_dir=. | |
3152 | if test -f $ac_dir/$ac_word; then | |
3153 | ac_cv_prog_YACC="$ac_prog" | |
3154 | break | |
3155 | fi | |
3156 | done | |
3157 | IFS="$ac_save_ifs" | |
3158 | fi | |
3159 | fi | |
3160 | YACC="$ac_cv_prog_YACC" | |
3161 | if test -n "$YACC"; then | |
3162 | echo "$ac_t""$YACC" 1>&6 | |
3163 | else | |
3164 | echo "$ac_t""no" 1>&6 | |
3165 | fi | |
3166 | ||
3167 | test -n "$YACC" && break | |
3168 | done | |
3169 | test -n "$YACC" || YACC="yacc" | |
3170 | ||
3171 | ||
75c6e08a MK |
3172 | # Extract the first word of "${ac_tool_prefix}mig", so it can be a program name with args. |
3173 | set dummy ${ac_tool_prefix}mig; ac_word=$2 | |
3174 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
b46cd165 | 3175 | echo "configure:3176: checking for $ac_word" >&5 |
75c6e08a MK |
3176 | if eval "test \"`echo '$''{'ac_cv_prog_MIG'+set}'`\" = set"; then |
3177 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3178 | else | |
3179 | if test -n "$MIG"; then | |
3180 | ac_cv_prog_MIG="$MIG" # Let the user override the test. | |
3181 | else | |
3182 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
3183 | ac_dummy="$PATH" | |
3184 | for ac_dir in $ac_dummy; do | |
3185 | test -z "$ac_dir" && ac_dir=. | |
3186 | if test -f $ac_dir/$ac_word; then | |
3187 | ac_cv_prog_MIG="${ac_tool_prefix}mig" | |
3188 | break | |
3189 | fi | |
3190 | done | |
3191 | IFS="$ac_save_ifs" | |
3192 | test -z "$ac_cv_prog_MIG" && ac_cv_prog_MIG="mig" | |
3193 | fi | |
3194 | fi | |
3195 | MIG="$ac_cv_prog_MIG" | |
3196 | if test -n "$MIG"; then | |
3197 | echo "$ac_t""$MIG" 1>&6 | |
3198 | else | |
3199 | echo "$ac_t""no" 1>&6 | |
3200 | fi | |
3201 | ||
3202 | ||
3203 | ||
3204 | ||
c906108c SS |
3205 | if test "$program_transform_name" = s,x,x,; then |
3206 | program_transform_name= | |
3207 | else | |
3208 | # Double any \ or $. echo might interpret backslashes. | |
3209 | cat <<\EOF_SED > conftestsed | |
3210 | s,\\,\\\\,g; s,\$,$$,g | |
3211 | EOF_SED | |
3212 | program_transform_name="`echo $program_transform_name|sed -f conftestsed`" | |
3213 | rm -f conftestsed | |
3214 | fi | |
3215 | test "$program_prefix" != NONE && | |
3216 | program_transform_name="s,^,${program_prefix},; $program_transform_name" | |
3217 | # Use a double $ so make ignores it. | |
3218 | test "$program_suffix" != NONE && | |
3219 | program_transform_name="s,\$\$,${program_suffix},; $program_transform_name" | |
3220 | ||
3221 | # sed with no file args requires a program. | |
3222 | test "$program_transform_name" = "" && program_transform_name="s,x,x," | |
3223 | ||
3224 | ||
3225 | echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6 | |
b46cd165 | 3226 | echo "configure:3227: checking return type of signal handlers" >&5 |
c906108c SS |
3227 | if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then |
3228 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3229 | else | |
3230 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 3231 | #line 3232 "configure" |
c906108c SS |
3232 | #include "confdefs.h" |
3233 | #include <sys/types.h> | |
3234 | #include <signal.h> | |
3235 | #ifdef signal | |
3236 | #undef signal | |
3237 | #endif | |
3238 | #ifdef __cplusplus | |
3239 | extern "C" void (*signal (int, void (*)(int)))(int); | |
3240 | #else | |
3241 | void (*signal ()) (); | |
3242 | #endif | |
3243 | ||
3244 | int main() { | |
3245 | int i; | |
3246 | ; return 0; } | |
3247 | EOF | |
b46cd165 | 3248 | if { (eval echo configure:3249: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
c906108c SS |
3249 | rm -rf conftest* |
3250 | ac_cv_type_signal=void | |
3251 | else | |
3252 | echo "configure: failed program was:" >&5 | |
3253 | cat conftest.$ac_ext >&5 | |
3254 | rm -rf conftest* | |
3255 | ac_cv_type_signal=int | |
3256 | fi | |
3257 | rm -f conftest* | |
3258 | fi | |
3259 | ||
3260 | echo "$ac_t""$ac_cv_type_signal" 1>&6 | |
3261 | cat >> confdefs.h <<EOF | |
3262 | #define RETSIGTYPE $ac_cv_type_signal | |
3263 | EOF | |
3264 | ||
3265 | ||
3266 | ||
3267 | echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6 | |
b46cd165 | 3268 | echo "configure:3269: checking for ANSI C header files" >&5 |
c906108c SS |
3269 | if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then |
3270 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3271 | else | |
3272 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 3273 | #line 3274 "configure" |
c906108c SS |
3274 | #include "confdefs.h" |
3275 | #include <stdlib.h> | |
3276 | #include <stdarg.h> | |
3277 | #include <string.h> | |
3278 | #include <float.h> | |
3279 | EOF | |
3280 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
b46cd165 | 3281 | { (eval echo configure:3282: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
c906108c SS |
3282 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
3283 | if test -z "$ac_err"; then | |
3284 | rm -rf conftest* | |
3285 | ac_cv_header_stdc=yes | |
3286 | else | |
3287 | echo "$ac_err" >&5 | |
3288 | echo "configure: failed program was:" >&5 | |
3289 | cat conftest.$ac_ext >&5 | |
3290 | rm -rf conftest* | |
3291 | ac_cv_header_stdc=no | |
3292 | fi | |
3293 | rm -f conftest* | |
3294 | ||
3295 | if test $ac_cv_header_stdc = yes; then | |
3296 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. | |
3297 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 3298 | #line 3299 "configure" |
c906108c SS |
3299 | #include "confdefs.h" |
3300 | #include <string.h> | |
3301 | EOF | |
3302 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
3303 | egrep "memchr" >/dev/null 2>&1; then | |
3304 | : | |
3305 | else | |
3306 | rm -rf conftest* | |
3307 | ac_cv_header_stdc=no | |
3308 | fi | |
3309 | rm -f conftest* | |
3310 | ||
3311 | fi | |
3312 | ||
3313 | if test $ac_cv_header_stdc = yes; then | |
3314 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. | |
3315 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 3316 | #line 3317 "configure" |
c906108c SS |
3317 | #include "confdefs.h" |
3318 | #include <stdlib.h> | |
3319 | EOF | |
3320 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
3321 | egrep "free" >/dev/null 2>&1; then | |
3322 | : | |
3323 | else | |
3324 | rm -rf conftest* | |
3325 | ac_cv_header_stdc=no | |
3326 | fi | |
3327 | rm -f conftest* | |
3328 | ||
3329 | fi | |
3330 | ||
3331 | if test $ac_cv_header_stdc = yes; then | |
3332 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. | |
3333 | if test "$cross_compiling" = yes; then | |
3334 | : | |
3335 | else | |
3336 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 3337 | #line 3338 "configure" |
c906108c SS |
3338 | #include "confdefs.h" |
3339 | #include <ctype.h> | |
3340 | #define ISLOWER(c) ('a' <= (c) && (c) <= 'z') | |
3341 | #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) | |
3342 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) | |
3343 | int main () { int i; for (i = 0; i < 256; i++) | |
3344 | if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2); | |
3345 | exit (0); } | |
3346 | ||
3347 | EOF | |
b46cd165 | 3348 | if { (eval echo configure:3349: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
c906108c SS |
3349 | then |
3350 | : | |
3351 | else | |
3352 | echo "configure: failed program was:" >&5 | |
3353 | cat conftest.$ac_ext >&5 | |
3354 | rm -fr conftest* | |
3355 | ac_cv_header_stdc=no | |
3356 | fi | |
3357 | rm -fr conftest* | |
3358 | fi | |
3359 | ||
3360 | fi | |
3361 | fi | |
3362 | ||
3363 | echo "$ac_t""$ac_cv_header_stdc" 1>&6 | |
3364 | if test $ac_cv_header_stdc = yes; then | |
3365 | cat >> confdefs.h <<\EOF | |
3366 | #define STDC_HEADERS 1 | |
3367 | EOF | |
3368 | ||
3369 | fi | |
3370 | ||
3371 | ||
6abadcf8 | 3372 | |
3e0bf9f1 | 3373 | case $host_os in solaris2.7 | solaris2.8) case "$GCC" in yes) |
6abadcf8 ND |
3374 | cat >> confdefs.h <<\EOF |
3375 | #define _MSE_INT_H 1 | |
3376 | EOF | |
3377 | ||
3378 | esac; esac | |
3379 | ||
2894793a | 3380 | for ac_hdr in ctype.h endian.h link.h thread_db.h proc_service.h \ |
c906108c | 3381 | memory.h objlist.h ptrace.h sgtty.h stddef.h stdlib.h \ |
ed9a39eb | 3382 | string.h sys/procfs.h sys/ptrace.h sys/reg.h stdint.h \ |
c906108c | 3383 | term.h termio.h termios.h unistd.h wait.h sys/wait.h \ |
104c1213 | 3384 | wchar.h wctype.h asm/debugreg.h sys/debugreg.h sys/select.h \ |
4b14d3e4 | 3385 | time.h sys/ioctl.h sys/user.h \ |
2894793a | 3386 | dirent.h sys/ndir.h sys/dir.h ndir.h \ |
409a3f64 AC |
3387 | curses.h ncurses.h \ |
3388 | poll.h sys/poll.h | |
c906108c SS |
3389 | do |
3390 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` | |
3391 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 | |
b46cd165 | 3392 | echo "configure:3393: checking for $ac_hdr" >&5 |
c906108c SS |
3393 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
3394 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3395 | else | |
3396 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 3397 | #line 3398 "configure" |
c906108c SS |
3398 | #include "confdefs.h" |
3399 | #include <$ac_hdr> | |
3400 | EOF | |
3401 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
b46cd165 | 3402 | { (eval echo configure:3403: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
c906108c SS |
3403 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
3404 | if test -z "$ac_err"; then | |
3405 | rm -rf conftest* | |
3406 | eval "ac_cv_header_$ac_safe=yes" | |
3407 | else | |
3408 | echo "$ac_err" >&5 | |
3409 | echo "configure: failed program was:" >&5 | |
3410 | cat conftest.$ac_ext >&5 | |
3411 | rm -rf conftest* | |
3412 | eval "ac_cv_header_$ac_safe=no" | |
3413 | fi | |
3414 | rm -f conftest* | |
3415 | fi | |
3416 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | |
3417 | echo "$ac_t""yes" 1>&6 | |
3418 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` | |
3419 | cat >> confdefs.h <<EOF | |
3420 | #define $ac_tr_hdr 1 | |
3421 | EOF | |
3422 | ||
3423 | else | |
3424 | echo "$ac_t""no" 1>&6 | |
3425 | fi | |
3426 | done | |
3427 | ||
3428 | echo $ac_n "checking whether stat file-mode macros are broken""... $ac_c" 1>&6 | |
b46cd165 | 3429 | echo "configure:3430: checking whether stat file-mode macros are broken" >&5 |
c906108c SS |
3430 | if eval "test \"`echo '$''{'ac_cv_header_stat_broken'+set}'`\" = set"; then |
3431 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3432 | else | |
3433 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 3434 | #line 3435 "configure" |
c906108c SS |
3435 | #include "confdefs.h" |
3436 | #include <sys/types.h> | |
3437 | #include <sys/stat.h> | |
3438 | ||
3439 | #if defined(S_ISBLK) && defined(S_IFDIR) | |
3440 | # if S_ISBLK (S_IFDIR) | |
3441 | You lose. | |
3442 | # endif | |
3443 | #endif | |
3444 | ||
3445 | #if defined(S_ISBLK) && defined(S_IFCHR) | |
3446 | # if S_ISBLK (S_IFCHR) | |
3447 | You lose. | |
3448 | # endif | |
3449 | #endif | |
3450 | ||
3451 | #if defined(S_ISLNK) && defined(S_IFREG) | |
3452 | # if S_ISLNK (S_IFREG) | |
3453 | You lose. | |
3454 | # endif | |
3455 | #endif | |
3456 | ||
3457 | #if defined(S_ISSOCK) && defined(S_IFREG) | |
3458 | # if S_ISSOCK (S_IFREG) | |
3459 | You lose. | |
3460 | # endif | |
3461 | #endif | |
3462 | ||
3463 | EOF | |
3464 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
3465 | egrep "You lose" >/dev/null 2>&1; then | |
3466 | rm -rf conftest* | |
3467 | ac_cv_header_stat_broken=yes | |
3468 | else | |
3469 | rm -rf conftest* | |
3470 | ac_cv_header_stat_broken=no | |
3471 | fi | |
3472 | rm -f conftest* | |
3473 | ||
3474 | fi | |
3475 | ||
3476 | echo "$ac_t""$ac_cv_header_stat_broken" 1>&6 | |
3477 | if test $ac_cv_header_stat_broken = yes; then | |
3478 | cat >> confdefs.h <<\EOF | |
3479 | #define STAT_MACROS_BROKEN 1 | |
3480 | EOF | |
3481 | ||
3482 | fi | |
3483 | ||
3484 | ||
3485 | echo $ac_n "checking for working const""... $ac_c" 1>&6 | |
b46cd165 | 3486 | echo "configure:3487: checking for working const" >&5 |
c906108c SS |
3487 | if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then |
3488 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3489 | else | |
3490 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 3491 | #line 3492 "configure" |
c906108c SS |
3492 | #include "confdefs.h" |
3493 | ||
3494 | int main() { | |
3495 | ||
3496 | /* Ultrix mips cc rejects this. */ | |
3497 | typedef int charset[2]; const charset x; | |
3498 | /* SunOS 4.1.1 cc rejects this. */ | |
3499 | char const *const *ccp; | |
3500 | char **p; | |
3501 | /* NEC SVR4.0.2 mips cc rejects this. */ | |
3502 | struct point {int x, y;}; | |
3503 | static struct point const zero = {0,0}; | |
3504 | /* AIX XL C 1.02.0.0 rejects this. | |
3505 | It does not let you subtract one const X* pointer from another in an arm | |
3506 | of an if-expression whose if-part is not a constant expression */ | |
3507 | const char *g = "string"; | |
3508 | ccp = &g + (g ? g-g : 0); | |
3509 | /* HPUX 7.0 cc rejects these. */ | |
3510 | ++ccp; | |
3511 | p = (char**) ccp; | |
3512 | ccp = (char const *const *) p; | |
3513 | { /* SCO 3.2v4 cc rejects this. */ | |
3514 | char *t; | |
3515 | char const *s = 0 ? (char *) 0 : (char const *) 0; | |
3516 | ||
3517 | *t++ = 0; | |
3518 | } | |
3519 | { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ | |
3520 | int x[] = {25, 17}; | |
3521 | const int *foo = &x[0]; | |
3522 | ++foo; | |
3523 | } | |
3524 | { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ | |
3525 | typedef const int *iptr; | |
3526 | iptr p = 0; | |
3527 | ++p; | |
3528 | } | |
3529 | { /* AIX XL C 1.02.0.0 rejects this saying | |
3530 | "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ | |
3531 | struct s { int j; const int *ap[3]; }; | |
3532 | struct s *b; b->j = 5; | |
3533 | } | |
3534 | { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ | |
3535 | const int foo = 10; | |
3536 | } | |
3537 | ||
3538 | ; return 0; } | |
3539 | EOF | |
b46cd165 | 3540 | if { (eval echo configure:3541: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
c906108c SS |
3541 | rm -rf conftest* |
3542 | ac_cv_c_const=yes | |
3543 | else | |
3544 | echo "configure: failed program was:" >&5 | |
3545 | cat conftest.$ac_ext >&5 | |
3546 | rm -rf conftest* | |
3547 | ac_cv_c_const=no | |
3548 | fi | |
3549 | rm -f conftest* | |
3550 | fi | |
3551 | ||
3552 | echo "$ac_t""$ac_cv_c_const" 1>&6 | |
3553 | if test $ac_cv_c_const = no; then | |
3554 | cat >> confdefs.h <<\EOF | |
3555 | #define const | |
3556 | EOF | |
3557 | ||
3558 | fi | |
3559 | ||
3560 | ||
818fa2bf | 3561 | for ac_func in setpgid sbrk sigaction isascii bzero bcopy btowc poll sigprocmask vfork |
c906108c SS |
3562 | do |
3563 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
b46cd165 | 3564 | echo "configure:3565: checking for $ac_func" >&5 |
c906108c SS |
3565 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
3566 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3567 | else | |
3568 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 3569 | #line 3570 "configure" |
c906108c SS |
3570 | #include "confdefs.h" |
3571 | /* System header to define __stub macros and hopefully few prototypes, | |
3572 | which can conflict with char $ac_func(); below. */ | |
3573 | #include <assert.h> | |
3574 | /* Override any gcc2 internal prototype to avoid an error. */ | |
3575 | /* We use char because int might match the return type of a gcc2 | |
3576 | builtin and then its argument prototype would still apply. */ | |
3577 | char $ac_func(); | |
3578 | ||
3579 | int main() { | |
3580 | ||
3581 | /* The GNU C library defines this for functions which it implements | |
3582 | to always fail with ENOSYS. Some functions are actually named | |
3583 | something starting with __ and the normal name is an alias. */ | |
3584 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
3585 | choke me | |
3586 | #else | |
3587 | $ac_func(); | |
3588 | #endif | |
3589 | ||
3590 | ; return 0; } | |
3591 | EOF | |
b46cd165 | 3592 | if { (eval echo configure:3593: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
c906108c SS |
3593 | rm -rf conftest* |
3594 | eval "ac_cv_func_$ac_func=yes" | |
3595 | else | |
3596 | echo "configure: failed program was:" >&5 | |
3597 | cat conftest.$ac_ext >&5 | |
3598 | rm -rf conftest* | |
3599 | eval "ac_cv_func_$ac_func=no" | |
3600 | fi | |
3601 | rm -f conftest* | |
3602 | fi | |
3603 | ||
3604 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then | |
3605 | echo "$ac_t""yes" 1>&6 | |
3606 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
3607 | cat >> confdefs.h <<EOF | |
3608 | #define $ac_tr_func 1 | |
3609 | EOF | |
3610 | ||
3611 | else | |
3612 | echo "$ac_t""no" 1>&6 | |
3613 | fi | |
3614 | done | |
3615 | ||
3616 | # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works | |
3617 | # for constant arguments. Useless! | |
3618 | echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6 | |
b46cd165 | 3619 | echo "configure:3620: checking for working alloca.h" >&5 |
c906108c SS |
3620 | if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then |
3621 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3622 | else | |
3623 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 3624 | #line 3625 "configure" |
c906108c SS |
3625 | #include "confdefs.h" |
3626 | #include <alloca.h> | |
3627 | int main() { | |
3628 | char *p = alloca(2 * sizeof(int)); | |
3629 | ; return 0; } | |
3630 | EOF | |
b46cd165 | 3631 | if { (eval echo configure:3632: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
c906108c SS |
3632 | rm -rf conftest* |
3633 | ac_cv_header_alloca_h=yes | |
3634 | else | |
3635 | echo "configure: failed program was:" >&5 | |
3636 | cat conftest.$ac_ext >&5 | |
3637 | rm -rf conftest* | |
3638 | ac_cv_header_alloca_h=no | |
3639 | fi | |
3640 | rm -f conftest* | |
3641 | fi | |
3642 | ||
3643 | echo "$ac_t""$ac_cv_header_alloca_h" 1>&6 | |
3644 | if test $ac_cv_header_alloca_h = yes; then | |
3645 | cat >> confdefs.h <<\EOF | |
3646 | #define HAVE_ALLOCA_H 1 | |
3647 | EOF | |
3648 | ||
3649 | fi | |
3650 | ||
3651 | echo $ac_n "checking for alloca""... $ac_c" 1>&6 | |
b46cd165 | 3652 | echo "configure:3653: checking for alloca" >&5 |
c906108c SS |
3653 | if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then |
3654 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3655 | else | |
3656 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 3657 | #line 3658 "configure" |
c906108c SS |
3658 | #include "confdefs.h" |
3659 | ||
3660 | #ifdef __GNUC__ | |
3661 | # define alloca __builtin_alloca | |
3662 | #else | |
3663 | # ifdef _MSC_VER | |
3664 | # include <malloc.h> | |
3665 | # define alloca _alloca | |
3666 | # else | |
3667 | # if HAVE_ALLOCA_H | |
3668 | # include <alloca.h> | |
3669 | # else | |
3670 | # ifdef _AIX | |
3671 | #pragma alloca | |
3672 | # else | |
3673 | # ifndef alloca /* predefined by HP cc +Olibcalls */ | |
3674 | char *alloca (); | |
3675 | # endif | |
3676 | # endif | |
3677 | # endif | |
3678 | # endif | |
3679 | #endif | |
3680 | ||
3681 | int main() { | |
3682 | char *p = (char *) alloca(1); | |
3683 | ; return 0; } | |
3684 | EOF | |
b46cd165 | 3685 | if { (eval echo configure:3686: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
c906108c SS |
3686 | rm -rf conftest* |
3687 | ac_cv_func_alloca_works=yes | |
3688 | else | |
3689 | echo "configure: failed program was:" >&5 | |
3690 | cat conftest.$ac_ext >&5 | |
3691 | rm -rf conftest* | |
3692 | ac_cv_func_alloca_works=no | |
3693 | fi | |
3694 | rm -f conftest* | |
3695 | fi | |
3696 | ||
3697 | echo "$ac_t""$ac_cv_func_alloca_works" 1>&6 | |
3698 | if test $ac_cv_func_alloca_works = yes; then | |
3699 | cat >> confdefs.h <<\EOF | |
3700 | #define HAVE_ALLOCA 1 | |
3701 | EOF | |
3702 | ||
3703 | fi | |
3704 | ||
3705 | if test $ac_cv_func_alloca_works = no; then | |
3706 | # The SVR3 libPW and SVR4 libucb both contain incompatible functions | |
3707 | # that cause trouble. Some versions do not even contain alloca or | |
3708 | # contain a buggy version. If you still want to use their alloca, | |
3709 | # use ar to extract alloca.o from them instead of compiling alloca.c. | |
3710 | ALLOCA=alloca.${ac_objext} | |
3711 | cat >> confdefs.h <<\EOF | |
3712 | #define C_ALLOCA 1 | |
3713 | EOF | |
3714 | ||
3715 | ||
3716 | echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6 | |
b46cd165 | 3717 | echo "configure:3718: checking whether alloca needs Cray hooks" >&5 |
c906108c SS |
3718 | if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then |
3719 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3720 | else | |
3721 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 3722 | #line 3723 "configure" |
c906108c SS |
3723 | #include "confdefs.h" |
3724 | #if defined(CRAY) && ! defined(CRAY2) | |
3725 | webecray | |
3726 | #else | |
3727 | wenotbecray | |
3728 | #endif | |
3729 | ||
3730 | EOF | |
3731 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
3732 | egrep "webecray" >/dev/null 2>&1; then | |
3733 | rm -rf conftest* | |
3734 | ac_cv_os_cray=yes | |
3735 | else | |
3736 | rm -rf conftest* | |
3737 | ac_cv_os_cray=no | |
3738 | fi | |
3739 | rm -f conftest* | |
3740 | ||
3741 | fi | |
3742 | ||
3743 | echo "$ac_t""$ac_cv_os_cray" 1>&6 | |
3744 | if test $ac_cv_os_cray = yes; then | |
3745 | for ac_func in _getb67 GETB67 getb67; do | |
3746 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
b46cd165 | 3747 | echo "configure:3748: checking for $ac_func" >&5 |
c906108c SS |
3748 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
3749 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3750 | else | |
3751 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 3752 | #line 3753 "configure" |
c906108c SS |
3753 | #include "confdefs.h" |
3754 | /* System header to define __stub macros and hopefully few prototypes, | |
3755 | which can conflict with char $ac_func(); below. */ | |
3756 | #include <assert.h> | |
3757 | /* Override any gcc2 internal prototype to avoid an error. */ | |
3758 | /* We use char because int might match the return type of a gcc2 | |
3759 | builtin and then its argument prototype would still apply. */ | |
3760 | char $ac_func(); | |
3761 | ||
3762 | int main() { | |
3763 | ||
3764 | /* The GNU C library defines this for functions which it implements | |
3765 | to always fail with ENOSYS. Some functions are actually named | |
3766 | something starting with __ and the normal name is an alias. */ | |
3767 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
3768 | choke me | |
3769 | #else | |
3770 | $ac_func(); | |
3771 | #endif | |
3772 | ||
3773 | ; return 0; } | |
3774 | EOF | |
b46cd165 | 3775 | if { (eval echo configure:3776: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
c906108c SS |
3776 | rm -rf conftest* |
3777 | eval "ac_cv_func_$ac_func=yes" | |
3778 | else | |
3779 | echo "configure: failed program was:" >&5 | |
3780 | cat conftest.$ac_ext >&5 | |
3781 | rm -rf conftest* | |
3782 | eval "ac_cv_func_$ac_func=no" | |
3783 | fi | |
3784 | rm -f conftest* | |
3785 | fi | |
3786 | ||
3787 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then | |
3788 | echo "$ac_t""yes" 1>&6 | |
3789 | cat >> confdefs.h <<EOF | |
3790 | #define CRAY_STACKSEG_END $ac_func | |
3791 | EOF | |
3792 | ||
3793 | break | |
3794 | else | |
3795 | echo "$ac_t""no" 1>&6 | |
3796 | fi | |
3797 | ||
3798 | done | |
3799 | fi | |
3800 | ||
3801 | echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6 | |
b46cd165 | 3802 | echo "configure:3803: checking stack direction for C alloca" >&5 |
c906108c SS |
3803 | if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then |
3804 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3805 | else | |
3806 | if test "$cross_compiling" = yes; then | |
3807 | ac_cv_c_stack_direction=0 | |
3808 | else | |
3809 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 3810 | #line 3811 "configure" |
c906108c SS |
3811 | #include "confdefs.h" |
3812 | find_stack_direction () | |
3813 | { | |
3814 | static char *addr = 0; | |
3815 | auto char dummy; | |
3816 | if (addr == 0) | |
3817 | { | |
3818 | addr = &dummy; | |
3819 | return find_stack_direction (); | |
3820 | } | |
3821 | else | |
3822 | return (&dummy > addr) ? 1 : -1; | |
3823 | } | |
3824 | main () | |
3825 | { | |
3826 | exit (find_stack_direction() < 0); | |
3827 | } | |
3828 | EOF | |
b46cd165 | 3829 | if { (eval echo configure:3830: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
c906108c SS |
3830 | then |
3831 | ac_cv_c_stack_direction=1 | |
3832 | else | |
3833 | echo "configure: failed program was:" >&5 | |
3834 | cat conftest.$ac_ext >&5 | |
3835 | rm -fr conftest* | |
3836 | ac_cv_c_stack_direction=-1 | |
3837 | fi | |
3838 | rm -fr conftest* | |
3839 | fi | |
3840 | ||
3841 | fi | |
3842 | ||
3843 | echo "$ac_t""$ac_cv_c_stack_direction" 1>&6 | |
3844 | cat >> confdefs.h <<EOF | |
3845 | #define STACK_DIRECTION $ac_cv_c_stack_direction | |
3846 | EOF | |
3847 | ||
3848 | fi | |
3849 | ||
3850 | ||
7dfa765c MK |
3851 | # See if machine/reg.h supports the %fs and %gs i386 segment registers. |
3852 | # Older i386 BSD's don't have the r_fs and r_gs members of `struct reg'. | |
3853 | echo $ac_n "checking for r_fs in struct reg""... $ac_c" 1>&6 | |
b46cd165 | 3854 | echo "configure:3855: checking for r_fs in struct reg" >&5 |
422ea4b8 | 3855 | if eval "test \"`echo '$''{'gdb_cv_struct_reg_r_fs'+set}'`\" = set"; then |
7dfa765c MK |
3856 | echo $ac_n "(cached) $ac_c" 1>&6 |
3857 | else | |
3858 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 3859 | #line 3860 "configure" |
7dfa765c MK |
3860 | #include "confdefs.h" |
3861 | #include <machine/reg.h> | |
3862 | int main() { | |
3863 | struct reg r; r.r_fs; | |
3864 | ; return 0; } | |
3865 | EOF | |
b46cd165 | 3866 | if { (eval echo configure:3867: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
7dfa765c | 3867 | rm -rf conftest* |
422ea4b8 | 3868 | gdb_cv_struct_reg_r_fs=yes |
7dfa765c MK |
3869 | else |
3870 | echo "configure: failed program was:" >&5 | |
3871 | cat conftest.$ac_ext >&5 | |
3872 | rm -rf conftest* | |
422ea4b8 | 3873 | gdb_cv_struct_reg_r_fs=no |
7dfa765c MK |
3874 | fi |
3875 | rm -f conftest* | |
3876 | fi | |
3877 | ||
422ea4b8 MK |
3878 | echo "$ac_t""$gdb_cv_struct_reg_r_fs" 1>&6 |
3879 | if test $gdb_cv_struct_reg_r_fs = yes; then | |
7dfa765c | 3880 | cat >> confdefs.h <<\EOF |
422ea4b8 | 3881 | #define HAVE_STRUCT_REG_R_FS 1 |
7dfa765c MK |
3882 | EOF |
3883 | ||
3884 | fi | |
3885 | echo $ac_n "checking for r_gs in struct reg""... $ac_c" 1>&6 | |
b46cd165 | 3886 | echo "configure:3887: checking for r_gs in struct reg" >&5 |
422ea4b8 | 3887 | if eval "test \"`echo '$''{'gdb_cv_struct_reg_r_gs'+set}'`\" = set"; then |
7dfa765c MK |
3888 | echo $ac_n "(cached) $ac_c" 1>&6 |
3889 | else | |
3890 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 3891 | #line 3892 "configure" |
7dfa765c MK |
3892 | #include "confdefs.h" |
3893 | #include <machine/reg.h> | |
3894 | int main() { | |
3895 | struct reg r; r.r_gs; | |
3896 | ; return 0; } | |
3897 | EOF | |
b46cd165 | 3898 | if { (eval echo configure:3899: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
7dfa765c | 3899 | rm -rf conftest* |
422ea4b8 | 3900 | gdb_cv_struct_reg_r_gs=yes |
7dfa765c MK |
3901 | else |
3902 | echo "configure: failed program was:" >&5 | |
3903 | cat conftest.$ac_ext >&5 | |
3904 | rm -rf conftest* | |
422ea4b8 | 3905 | gdb_cv_struct_reg_r_gs=no |
7dfa765c MK |
3906 | fi |
3907 | rm -f conftest* | |
3908 | fi | |
3909 | ||
422ea4b8 MK |
3910 | echo "$ac_t""$gdb_cv_struct_reg_r_gs" 1>&6 |
3911 | if test $gdb_cv_struct_reg_r_gs = yes; then | |
7dfa765c | 3912 | cat >> confdefs.h <<\EOF |
422ea4b8 | 3913 | #define HAVE_STRUCT_REG_R_GS 1 |
7dfa765c MK |
3914 | EOF |
3915 | ||
3916 | fi | |
3917 | ||
64bb1671 | 3918 | echo $ac_n "checking for PTRACE_GETREGS""... $ac_c" 1>&6 |
b46cd165 | 3919 | echo "configure:3920: checking for PTRACE_GETREGS" >&5 |
64bb1671 MK |
3920 | if eval "test \"`echo '$''{'gdb_cv_have_ptrace_getregs'+set}'`\" = set"; then |
3921 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3922 | else | |
3923 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 3924 | #line 3925 "configure" |
64bb1671 MK |
3925 | #include "confdefs.h" |
3926 | #include <sys/ptrace.h> | |
3927 | int main() { | |
3928 | PTRACE_GETREGS; | |
3929 | ; return 0; } | |
3930 | EOF | |
b46cd165 | 3931 | if { (eval echo configure:3932: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
64bb1671 MK |
3932 | rm -rf conftest* |
3933 | gdb_cv_have_ptrace_getregs=yes | |
3934 | else | |
3935 | echo "configure: failed program was:" >&5 | |
3936 | cat conftest.$ac_ext >&5 | |
3937 | rm -rf conftest* | |
3938 | gdb_cv_have_ptrace_getregs=no | |
3939 | fi | |
3940 | rm -f conftest* | |
3941 | fi | |
3942 | ||
4397a6ab | 3943 | echo "$ac_t""$gdb_cv_have_ptrace_getregs" 1>&6 |
64bb1671 MK |
3944 | if test $gdb_cv_have_ptrace_getregs = yes; then |
3945 | cat >> confdefs.h <<\EOF | |
3946 | #define HAVE_PTRACE_GETREGS 1 | |
3947 | EOF | |
3948 | ||
3949 | fi | |
3950 | ||
6ce2ac0b | 3951 | echo $ac_n "checking for PTRACE_GETFPXREGS""... $ac_c" 1>&6 |
b46cd165 | 3952 | echo "configure:3953: checking for PTRACE_GETFPXREGS" >&5 |
6ce2ac0b | 3953 | if eval "test \"`echo '$''{'gdb_cv_have_ptrace_getfpxregs'+set}'`\" = set"; then |
5c44784c JM |
3954 | echo $ac_n "(cached) $ac_c" 1>&6 |
3955 | else | |
3956 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 3957 | #line 3958 "configure" |
5c44784c JM |
3958 | #include "confdefs.h" |
3959 | #include <sys/ptrace.h> | |
3960 | int main() { | |
6ce2ac0b | 3961 | PTRACE_GETFPXREGS; |
5c44784c JM |
3962 | ; return 0; } |
3963 | EOF | |
b46cd165 | 3964 | if { (eval echo configure:3965: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
5c44784c | 3965 | rm -rf conftest* |
6ce2ac0b | 3966 | gdb_cv_have_ptrace_getfpxregs=yes |
5c44784c JM |
3967 | else |
3968 | echo "configure: failed program was:" >&5 | |
3969 | cat conftest.$ac_ext >&5 | |
3970 | rm -rf conftest* | |
6ce2ac0b | 3971 | gdb_cv_have_ptrace_getfpxregs=no |
5c44784c JM |
3972 | fi |
3973 | rm -f conftest* | |
3974 | fi | |
3975 | ||
6ce2ac0b MK |
3976 | echo "$ac_t""$gdb_cv_have_ptrace_getfpxregs" 1>&6 |
3977 | if test $gdb_cv_have_ptrace_getfpxregs = yes; then | |
5c44784c | 3978 | cat >> confdefs.h <<\EOF |
6ce2ac0b | 3979 | #define HAVE_PTRACE_GETFPXREGS 1 |
5c44784c JM |
3980 | EOF |
3981 | ||
3982 | fi | |
3983 | ||
7be570e7 | 3984 | echo $ac_n "checking for socketpair in -lsocket""... $ac_c" 1>&6 |
b46cd165 | 3985 | echo "configure:3986: checking for socketpair in -lsocket" >&5 |
7be570e7 JM |
3986 | ac_lib_var=`echo socket'_'socketpair | sed 'y%./+-%__p_%'` |
3987 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then | |
3988 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3989 | else | |
3990 | ac_save_LIBS="$LIBS" | |
3991 | LIBS="-lsocket $LIBS" | |
3992 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 3993 | #line 3994 "configure" |
7be570e7 JM |
3994 | #include "confdefs.h" |
3995 | /* Override any gcc2 internal prototype to avoid an error. */ | |
3996 | /* We use char because int might match the return type of a gcc2 | |
3997 | builtin and then its argument prototype would still apply. */ | |
3998 | char socketpair(); | |
3999 | ||
4000 | int main() { | |
4001 | socketpair() | |
4002 | ; return 0; } | |
4003 | EOF | |
b46cd165 | 4004 | if { (eval echo configure:4005: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
7be570e7 JM |
4005 | rm -rf conftest* |
4006 | eval "ac_cv_lib_$ac_lib_var=yes" | |
4007 | else | |
4008 | echo "configure: failed program was:" >&5 | |
4009 | cat conftest.$ac_ext >&5 | |
4010 | rm -rf conftest* | |
4011 | eval "ac_cv_lib_$ac_lib_var=no" | |
4012 | fi | |
4013 | rm -f conftest* | |
4014 | LIBS="$ac_save_LIBS" | |
4015 | ||
4016 | fi | |
4017 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then | |
4018 | echo "$ac_t""yes" 1>&6 | |
4019 | ac_tr_lib=HAVE_LIB`echo socket | sed -e 's/[^a-zA-Z0-9_]/_/g' \ | |
4020 | -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` | |
4021 | cat >> confdefs.h <<EOF | |
4022 | #define $ac_tr_lib 1 | |
4023 | EOF | |
4024 | ||
4025 | LIBS="-lsocket $LIBS" | |
4026 | ||
4027 | else | |
4028 | echo "$ac_t""no" 1>&6 | |
4029 | fi | |
4030 | ||
4031 | for ac_func in socketpair | |
4032 | do | |
4033 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
b46cd165 | 4034 | echo "configure:4035: checking for $ac_func" >&5 |
7be570e7 JM |
4035 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
4036 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4037 | else | |
4038 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 4039 | #line 4040 "configure" |
7be570e7 JM |
4040 | #include "confdefs.h" |
4041 | /* System header to define __stub macros and hopefully few prototypes, | |
4042 | which can conflict with char $ac_func(); below. */ | |
4043 | #include <assert.h> | |
4044 | /* Override any gcc2 internal prototype to avoid an error. */ | |
4045 | /* We use char because int might match the return type of a gcc2 | |
4046 | builtin and then its argument prototype would still apply. */ | |
4047 | char $ac_func(); | |
4048 | ||
4049 | int main() { | |
4050 | ||
4051 | /* The GNU C library defines this for functions which it implements | |
4052 | to always fail with ENOSYS. Some functions are actually named | |
4053 | something starting with __ and the normal name is an alias. */ | |
4054 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
4055 | choke me | |
4056 | #else | |
4057 | $ac_func(); | |
4058 | #endif | |
4059 | ||
4060 | ; return 0; } | |
4061 | EOF | |
b46cd165 | 4062 | if { (eval echo configure:4063: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
7be570e7 JM |
4063 | rm -rf conftest* |
4064 | eval "ac_cv_func_$ac_func=yes" | |
4065 | else | |
4066 | echo "configure: failed program was:" >&5 | |
4067 | cat conftest.$ac_ext >&5 | |
4068 | rm -rf conftest* | |
4069 | eval "ac_cv_func_$ac_func=no" | |
4070 | fi | |
4071 | rm -f conftest* | |
4072 | fi | |
4073 | ||
4074 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then | |
4075 | echo "$ac_t""yes" 1>&6 | |
4076 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
4077 | cat >> confdefs.h <<EOF | |
4078 | #define $ac_tr_func 1 | |
4079 | EOF | |
4080 | ||
4081 | else | |
4082 | echo "$ac_t""no" 1>&6 | |
4083 | fi | |
4084 | done | |
4085 | ||
4086 | ||
4087 | ||
c906108c | 4088 | echo $ac_n "checking whether malloc must be declared""... $ac_c" 1>&6 |
b46cd165 | 4089 | echo "configure:4090: checking whether malloc must be declared" >&5 |
c906108c SS |
4090 | if eval "test \"`echo '$''{'bfd_cv_decl_needed_malloc'+set}'`\" = set"; then |
4091 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4092 | else | |
4093 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 4094 | #line 4095 "configure" |
c906108c SS |
4095 | #include "confdefs.h" |
4096 | ||
4097 | #include <stdio.h> | |
4098 | #ifdef HAVE_STRING_H | |
4099 | #include <string.h> | |
4100 | #else | |
4101 | #ifdef HAVE_STRINGS_H | |
4102 | #include <strings.h> | |
4103 | #endif | |
4104 | #endif | |
4105 | #ifdef HAVE_STDLIB_H | |
4106 | #include <stdlib.h> | |
4107 | #endif | |
4108 | #ifdef HAVE_UNISTD_H | |
4109 | #include <unistd.h> | |
4110 | #endif | |
4111 | int main() { | |
4112 | char *(*pfn) = (char *(*)) malloc | |
4113 | ; return 0; } | |
4114 | EOF | |
b46cd165 | 4115 | if { (eval echo configure:4116: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
c906108c SS |
4116 | rm -rf conftest* |
4117 | bfd_cv_decl_needed_malloc=no | |
4118 | else | |
4119 | echo "configure: failed program was:" >&5 | |
4120 | cat conftest.$ac_ext >&5 | |
4121 | rm -rf conftest* | |
4122 | bfd_cv_decl_needed_malloc=yes | |
4123 | fi | |
4124 | rm -f conftest* | |
4125 | fi | |
4126 | ||
4127 | echo "$ac_t""$bfd_cv_decl_needed_malloc" 1>&6 | |
4128 | if test $bfd_cv_decl_needed_malloc = yes; then | |
4129 | cat >> confdefs.h <<\EOF | |
4130 | #define NEED_DECLARATION_MALLOC 1 | |
4131 | EOF | |
4132 | ||
4133 | fi | |
4134 | ||
4135 | echo $ac_n "checking whether realloc must be declared""... $ac_c" 1>&6 | |
b46cd165 | 4136 | echo "configure:4137: checking whether realloc must be declared" >&5 |
c906108c SS |
4137 | if eval "test \"`echo '$''{'bfd_cv_decl_needed_realloc'+set}'`\" = set"; then |
4138 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4139 | else | |
4140 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 4141 | #line 4142 "configure" |
c906108c SS |
4142 | #include "confdefs.h" |
4143 | ||
4144 | #include <stdio.h> | |
4145 | #ifdef HAVE_STRING_H | |
4146 | #include <string.h> | |
4147 | #else | |
4148 | #ifdef HAVE_STRINGS_H | |
4149 | #include <strings.h> | |
4150 | #endif | |
4151 | #endif | |
4152 | #ifdef HAVE_STDLIB_H | |
4153 | #include <stdlib.h> | |
4154 | #endif | |
4155 | #ifdef HAVE_UNISTD_H | |
4156 | #include <unistd.h> | |
4157 | #endif | |
4158 | int main() { | |
4159 | char *(*pfn) = (char *(*)) realloc | |
4160 | ; return 0; } | |
4161 | EOF | |
b46cd165 | 4162 | if { (eval echo configure:4163: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
c906108c SS |
4163 | rm -rf conftest* |
4164 | bfd_cv_decl_needed_realloc=no | |
4165 | else | |
4166 | echo "configure: failed program was:" >&5 | |
4167 | cat conftest.$ac_ext >&5 | |
4168 | rm -rf conftest* | |
4169 | bfd_cv_decl_needed_realloc=yes | |
4170 | fi | |
4171 | rm -f conftest* | |
4172 | fi | |
4173 | ||
4174 | echo "$ac_t""$bfd_cv_decl_needed_realloc" 1>&6 | |
4175 | if test $bfd_cv_decl_needed_realloc = yes; then | |
4176 | cat >> confdefs.h <<\EOF | |
4177 | #define NEED_DECLARATION_REALLOC 1 | |
4178 | EOF | |
4179 | ||
4180 | fi | |
4181 | ||
4182 | echo $ac_n "checking whether free must be declared""... $ac_c" 1>&6 | |
b46cd165 | 4183 | echo "configure:4184: checking whether free must be declared" >&5 |
c906108c SS |
4184 | if eval "test \"`echo '$''{'bfd_cv_decl_needed_free'+set}'`\" = set"; then |
4185 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4186 | else | |
4187 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 4188 | #line 4189 "configure" |
c906108c SS |
4189 | #include "confdefs.h" |
4190 | ||
4191 | #include <stdio.h> | |
4192 | #ifdef HAVE_STRING_H | |
4193 | #include <string.h> | |
4194 | #else | |
4195 | #ifdef HAVE_STRINGS_H | |
4196 | #include <strings.h> | |
4197 | #endif | |
4198 | #endif | |
4199 | #ifdef HAVE_STDLIB_H | |
4200 | #include <stdlib.h> | |
4201 | #endif | |
4202 | #ifdef HAVE_UNISTD_H | |
4203 | #include <unistd.h> | |
4204 | #endif | |
4205 | int main() { | |
4206 | char *(*pfn) = (char *(*)) free | |
4207 | ; return 0; } | |
4208 | EOF | |
b46cd165 | 4209 | if { (eval echo configure:4210: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
c906108c SS |
4210 | rm -rf conftest* |
4211 | bfd_cv_decl_needed_free=no | |
4212 | else | |
4213 | echo "configure: failed program was:" >&5 | |
4214 | cat conftest.$ac_ext >&5 | |
4215 | rm -rf conftest* | |
4216 | bfd_cv_decl_needed_free=yes | |
4217 | fi | |
4218 | rm -f conftest* | |
4219 | fi | |
4220 | ||
4221 | echo "$ac_t""$bfd_cv_decl_needed_free" 1>&6 | |
4222 | if test $bfd_cv_decl_needed_free = yes; then | |
4223 | cat >> confdefs.h <<\EOF | |
4224 | #define NEED_DECLARATION_FREE 1 | |
4225 | EOF | |
4226 | ||
4227 | fi | |
4228 | ||
4229 | echo $ac_n "checking whether strerror must be declared""... $ac_c" 1>&6 | |
b46cd165 | 4230 | echo "configure:4231: checking whether strerror must be declared" >&5 |
c906108c SS |
4231 | if eval "test \"`echo '$''{'bfd_cv_decl_needed_strerror'+set}'`\" = set"; then |
4232 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4233 | else | |
4234 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 4235 | #line 4236 "configure" |
c906108c SS |
4236 | #include "confdefs.h" |
4237 | ||
4238 | #include <stdio.h> | |
4239 | #ifdef HAVE_STRING_H | |
4240 | #include <string.h> | |
4241 | #else | |
4242 | #ifdef HAVE_STRINGS_H | |
4243 | #include <strings.h> | |
4244 | #endif | |
4245 | #endif | |
4246 | #ifdef HAVE_STDLIB_H | |
4247 | #include <stdlib.h> | |
4248 | #endif | |
4249 | #ifdef HAVE_UNISTD_H | |
4250 | #include <unistd.h> | |
4251 | #endif | |
4252 | int main() { | |
4253 | char *(*pfn) = (char *(*)) strerror | |
4254 | ; return 0; } | |
4255 | EOF | |
b46cd165 | 4256 | if { (eval echo configure:4257: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
c906108c SS |
4257 | rm -rf conftest* |
4258 | bfd_cv_decl_needed_strerror=no | |
4259 | else | |
4260 | echo "configure: failed program was:" >&5 | |
4261 | cat conftest.$ac_ext >&5 | |
4262 | rm -rf conftest* | |
4263 | bfd_cv_decl_needed_strerror=yes | |
4264 | fi | |
4265 | rm -f conftest* | |
4266 | fi | |
4267 | ||
4268 | echo "$ac_t""$bfd_cv_decl_needed_strerror" 1>&6 | |
4269 | if test $bfd_cv_decl_needed_strerror = yes; then | |
4270 | cat >> confdefs.h <<\EOF | |
4271 | #define NEED_DECLARATION_STRERROR 1 | |
4272 | EOF | |
4273 | ||
4274 | fi | |
4275 | ||
4276 | echo $ac_n "checking whether strdup must be declared""... $ac_c" 1>&6 | |
b46cd165 | 4277 | echo "configure:4278: checking whether strdup must be declared" >&5 |
c906108c SS |
4278 | if eval "test \"`echo '$''{'bfd_cv_decl_needed_strdup'+set}'`\" = set"; then |
4279 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4280 | else | |
4281 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 4282 | #line 4283 "configure" |
c906108c SS |
4283 | #include "confdefs.h" |
4284 | ||
4285 | #include <stdio.h> | |
4286 | #ifdef HAVE_STRING_H | |
4287 | #include <string.h> | |
4288 | #else | |
4289 | #ifdef HAVE_STRINGS_H | |
4290 | #include <strings.h> | |
4291 | #endif | |
4292 | #endif | |
4293 | #ifdef HAVE_STDLIB_H | |
4294 | #include <stdlib.h> | |
4295 | #endif | |
4296 | #ifdef HAVE_UNISTD_H | |
4297 | #include <unistd.h> | |
4298 | #endif | |
4299 | int main() { | |
4300 | char *(*pfn) = (char *(*)) strdup | |
4301 | ; return 0; } | |
4302 | EOF | |
b46cd165 | 4303 | if { (eval echo configure:4304: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
c906108c SS |
4304 | rm -rf conftest* |
4305 | bfd_cv_decl_needed_strdup=no | |
4306 | else | |
4307 | echo "configure: failed program was:" >&5 | |
4308 | cat conftest.$ac_ext >&5 | |
4309 | rm -rf conftest* | |
4310 | bfd_cv_decl_needed_strdup=yes | |
4311 | fi | |
4312 | rm -f conftest* | |
4313 | fi | |
4314 | ||
4315 | echo "$ac_t""$bfd_cv_decl_needed_strdup" 1>&6 | |
4316 | if test $bfd_cv_decl_needed_strdup = yes; then | |
4317 | cat >> confdefs.h <<\EOF | |
4318 | #define NEED_DECLARATION_STRDUP 1 | |
4319 | EOF | |
4320 | ||
4321 | fi | |
4322 | ||
b83266a0 | 4323 | echo $ac_n "checking whether strstr must be declared""... $ac_c" 1>&6 |
b46cd165 | 4324 | echo "configure:4325: checking whether strstr must be declared" >&5 |
b83266a0 SS |
4325 | if eval "test \"`echo '$''{'bfd_cv_decl_needed_strstr'+set}'`\" = set"; then |
4326 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4327 | else | |
4328 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 4329 | #line 4330 "configure" |
b83266a0 SS |
4330 | #include "confdefs.h" |
4331 | ||
4332 | #include <stdio.h> | |
4333 | #ifdef HAVE_STRING_H | |
4334 | #include <string.h> | |
4335 | #else | |
4336 | #ifdef HAVE_STRINGS_H | |
4337 | #include <strings.h> | |
4338 | #endif | |
4339 | #endif | |
4340 | #ifdef HAVE_STDLIB_H | |
4341 | #include <stdlib.h> | |
4342 | #endif | |
4343 | #ifdef HAVE_UNISTD_H | |
4344 | #include <unistd.h> | |
4345 | #endif | |
4346 | int main() { | |
4347 | char *(*pfn) = (char *(*)) strstr | |
4348 | ; return 0; } | |
4349 | EOF | |
b46cd165 | 4350 | if { (eval echo configure:4351: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
b83266a0 SS |
4351 | rm -rf conftest* |
4352 | bfd_cv_decl_needed_strstr=no | |
4353 | else | |
4354 | echo "configure: failed program was:" >&5 | |
4355 | cat conftest.$ac_ext >&5 | |
4356 | rm -rf conftest* | |
4357 | bfd_cv_decl_needed_strstr=yes | |
4358 | fi | |
4359 | rm -f conftest* | |
4360 | fi | |
4361 | ||
4362 | echo "$ac_t""$bfd_cv_decl_needed_strstr" 1>&6 | |
4363 | if test $bfd_cv_decl_needed_strstr = yes; then | |
4364 | cat >> confdefs.h <<\EOF | |
4365 | #define NEED_DECLARATION_STRSTR 1 | |
4366 | EOF | |
4367 | ||
4368 | fi | |
4369 | ||
c906108c SS |
4370 | |
4371 | ||
4372 | # The following save_state_t checkery is only necessary for HPUX | |
4373 | # versions earlier than 10.20. When those fade from memory, this | |
4374 | # could be expunged. --jsm 1999-03-22 | |
4375 | ||
4376 | echo $ac_n "checking for HPUX save_state structure""... $ac_c" 1>&6 | |
b46cd165 | 4377 | echo "configure:4378: checking for HPUX save_state structure" >&5 |
c906108c | 4378 | cat > conftest.$ac_ext <<EOF |
b46cd165 | 4379 | #line 4380 "configure" |
c906108c SS |
4380 | #include "confdefs.h" |
4381 | #include <machine/save_state.h> | |
4382 | EOF | |
4383 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
4384 | egrep "save_state_t" >/dev/null 2>&1; then | |
4385 | rm -rf conftest* | |
4386 | gdb_cv_hpux_savestate=yes | |
4387 | else | |
4388 | rm -rf conftest* | |
4389 | gdb_cv_hpux_savestate=no | |
4390 | fi | |
4391 | rm -f conftest* | |
4392 | ||
4393 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 4394 | #line 4395 "configure" |
c906108c SS |
4395 | #include "confdefs.h" |
4396 | #include <machine/save_state.h> | |
4397 | EOF | |
4398 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
4399 | egrep "ss_wide" >/dev/null 2>&1; then | |
4400 | rm -rf conftest* | |
4401 | gdb_cv_hpux_sswide=yes | |
4402 | else | |
4403 | rm -rf conftest* | |
4404 | gdb_cv_hpux_sswide=no | |
4405 | fi | |
4406 | rm -f conftest* | |
4407 | ||
4408 | if test $gdb_cv_hpux_savestate = yes | |
4409 | then | |
4410 | cat >> confdefs.h <<\EOF | |
4411 | #define HAVE_STRUCT_SAVE_STATE_T 1 | |
4412 | EOF | |
4413 | ||
4414 | fi | |
4415 | if test $gdb_cv_hpux_sswide = yes | |
4416 | then | |
4417 | cat >> confdefs.h <<\EOF | |
4418 | #define HAVE_STRUCT_MEMBER_SS_WIDE 1 | |
4419 | EOF | |
4420 | ||
4421 | fi | |
4422 | echo "$ac_t""$gdb_cv_hpux_sswide" 1>&6 | |
4423 | ||
4424 | ||
4425 | # If we are configured native on GNU/Linux, work around problems with | |
4426 | # sys/procfs.h | |
c3f6f71d | 4427 | # Also detect which type of /proc is in use, such as for Unixware or Solaris. |
c906108c SS |
4428 | |
4429 | if test "${target}" = "${host}"; then | |
4430 | case "${host}" in | |
4431 | i[3456]86-*-linux*) | |
4432 | cat >> confdefs.h <<\EOF | |
4433 | #define START_INFERIOR_TRAPS_EXPECTED 2 | |
4434 | EOF | |
4435 | ||
4436 | cat >> confdefs.h <<\EOF | |
4437 | #define sys_quotactl 1 | |
4438 | EOF | |
4439 | ||
4440 | ;; | |
c5394b80 | 4441 | *-*-unixware* | *-*-sysv4.2* | *-*-sysv5*) |
c3f6f71d JM |
4442 | cat >> confdefs.h <<\EOF |
4443 | #define NEW_PROC_API 1 | |
c906108c SS |
4444 | EOF |
4445 | ||
c3f6f71d | 4446 | ;; |
3423db82 | 4447 | *-*-solaris2.[678]) |
c3f6f71d JM |
4448 | cat >> confdefs.h <<\EOF |
4449 | #define NEW_PROC_API 1 | |
4450 | EOF | |
4451 | ||
4452 | ;; | |
4453 | esac | |
c906108c SS |
4454 | fi |
4455 | ||
4456 | if test "$ac_cv_header_sys_procfs_h" = yes; then | |
4457 | echo $ac_n "checking for pstatus_t in sys/procfs.h""... $ac_c" 1>&6 | |
b46cd165 | 4458 | echo "configure:4459: checking for pstatus_t in sys/procfs.h" >&5 |
c906108c SS |
4459 | if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_pstatus_t'+set}'`\" = set"; then |
4460 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4461 | else | |
4462 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 4463 | #line 4464 "configure" |
c906108c | 4464 | #include "confdefs.h" |
e17bf198 AO |
4465 | |
4466 | #define _SYSCALL32 | |
c906108c SS |
4467 | #include <sys/procfs.h> |
4468 | int main() { | |
4469 | pstatus_t avar | |
4470 | ; return 0; } | |
4471 | EOF | |
b46cd165 | 4472 | if { (eval echo configure:4473: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
c906108c SS |
4473 | rm -rf conftest* |
4474 | bfd_cv_have_sys_procfs_type_pstatus_t=yes | |
4475 | else | |
4476 | echo "configure: failed program was:" >&5 | |
4477 | cat conftest.$ac_ext >&5 | |
4478 | rm -rf conftest* | |
4479 | bfd_cv_have_sys_procfs_type_pstatus_t=no | |
4480 | ||
4481 | fi | |
4482 | rm -f conftest* | |
4483 | fi | |
4484 | ||
4485 | if test $bfd_cv_have_sys_procfs_type_pstatus_t = yes; then | |
4486 | cat >> confdefs.h <<\EOF | |
4487 | #define HAVE_PSTATUS_T 1 | |
4488 | EOF | |
4489 | ||
4490 | fi | |
4491 | echo "$ac_t""$bfd_cv_have_sys_procfs_type_pstatus_t" 1>&6 | |
4492 | ||
4493 | echo $ac_n "checking for prrun_t in sys/procfs.h""... $ac_c" 1>&6 | |
b46cd165 | 4494 | echo "configure:4495: checking for prrun_t in sys/procfs.h" >&5 |
c906108c SS |
4495 | if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prrun_t'+set}'`\" = set"; then |
4496 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4497 | else | |
4498 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 4499 | #line 4500 "configure" |
c906108c | 4500 | #include "confdefs.h" |
e17bf198 AO |
4501 | |
4502 | #define _SYSCALL32 | |
c906108c SS |
4503 | #include <sys/procfs.h> |
4504 | int main() { | |
4505 | prrun_t avar | |
4506 | ; return 0; } | |
4507 | EOF | |
b46cd165 | 4508 | if { (eval echo configure:4509: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
c906108c SS |
4509 | rm -rf conftest* |
4510 | bfd_cv_have_sys_procfs_type_prrun_t=yes | |
4511 | else | |
4512 | echo "configure: failed program was:" >&5 | |
4513 | cat conftest.$ac_ext >&5 | |
4514 | rm -rf conftest* | |
4515 | bfd_cv_have_sys_procfs_type_prrun_t=no | |
4516 | ||
4517 | fi | |
4518 | rm -f conftest* | |
4519 | fi | |
4520 | ||
4521 | if test $bfd_cv_have_sys_procfs_type_prrun_t = yes; then | |
4522 | cat >> confdefs.h <<\EOF | |
4523 | #define HAVE_PRRUN_T 1 | |
4524 | EOF | |
4525 | ||
4526 | fi | |
4527 | echo "$ac_t""$bfd_cv_have_sys_procfs_type_prrun_t" 1>&6 | |
4528 | ||
4529 | echo $ac_n "checking for gregset_t in sys/procfs.h""... $ac_c" 1>&6 | |
b46cd165 | 4530 | echo "configure:4531: checking for gregset_t in sys/procfs.h" >&5 |
c906108c SS |
4531 | if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_gregset_t'+set}'`\" = set"; then |
4532 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4533 | else | |
4534 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 4535 | #line 4536 "configure" |
c906108c | 4536 | #include "confdefs.h" |
e17bf198 AO |
4537 | |
4538 | #define _SYSCALL32 | |
c906108c SS |
4539 | #include <sys/procfs.h> |
4540 | int main() { | |
4541 | gregset_t avar | |
4542 | ; return 0; } | |
4543 | EOF | |
b46cd165 | 4544 | if { (eval echo configure:4545: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
c906108c SS |
4545 | rm -rf conftest* |
4546 | bfd_cv_have_sys_procfs_type_gregset_t=yes | |
4547 | else | |
4548 | echo "configure: failed program was:" >&5 | |
4549 | cat conftest.$ac_ext >&5 | |
4550 | rm -rf conftest* | |
4551 | bfd_cv_have_sys_procfs_type_gregset_t=no | |
4552 | ||
4553 | fi | |
4554 | rm -f conftest* | |
4555 | fi | |
4556 | ||
4557 | if test $bfd_cv_have_sys_procfs_type_gregset_t = yes; then | |
4558 | cat >> confdefs.h <<\EOF | |
4559 | #define HAVE_GREGSET_T 1 | |
4560 | EOF | |
4561 | ||
4562 | fi | |
4563 | echo "$ac_t""$bfd_cv_have_sys_procfs_type_gregset_t" 1>&6 | |
4564 | ||
4565 | echo $ac_n "checking for fpregset_t in sys/procfs.h""... $ac_c" 1>&6 | |
b46cd165 | 4566 | echo "configure:4567: checking for fpregset_t in sys/procfs.h" >&5 |
c906108c SS |
4567 | if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_fpregset_t'+set}'`\" = set"; then |
4568 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4569 | else | |
4570 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 4571 | #line 4572 "configure" |
c906108c | 4572 | #include "confdefs.h" |
e17bf198 AO |
4573 | |
4574 | #define _SYSCALL32 | |
c906108c SS |
4575 | #include <sys/procfs.h> |
4576 | int main() { | |
4577 | fpregset_t avar | |
4578 | ; return 0; } | |
4579 | EOF | |
b46cd165 | 4580 | if { (eval echo configure:4581: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
c906108c SS |
4581 | rm -rf conftest* |
4582 | bfd_cv_have_sys_procfs_type_fpregset_t=yes | |
4583 | else | |
4584 | echo "configure: failed program was:" >&5 | |
4585 | cat conftest.$ac_ext >&5 | |
4586 | rm -rf conftest* | |
4587 | bfd_cv_have_sys_procfs_type_fpregset_t=no | |
4588 | ||
4589 | fi | |
4590 | rm -f conftest* | |
4591 | fi | |
4592 | ||
4593 | if test $bfd_cv_have_sys_procfs_type_fpregset_t = yes; then | |
4594 | cat >> confdefs.h <<\EOF | |
4595 | #define HAVE_FPREGSET_T 1 | |
4596 | EOF | |
4597 | ||
4598 | fi | |
4599 | echo "$ac_t""$bfd_cv_have_sys_procfs_type_fpregset_t" 1>&6 | |
4600 | ||
3862412b | 4601 | echo $ac_n "checking for prgregset_t in sys/procfs.h""... $ac_c" 1>&6 |
b46cd165 | 4602 | echo "configure:4603: checking for prgregset_t in sys/procfs.h" >&5 |
3862412b MK |
4603 | if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prgregset_t'+set}'`\" = set"; then |
4604 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4605 | else | |
4606 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 4607 | #line 4608 "configure" |
3862412b | 4608 | #include "confdefs.h" |
e17bf198 AO |
4609 | |
4610 | #define _SYSCALL32 | |
3862412b MK |
4611 | #include <sys/procfs.h> |
4612 | int main() { | |
4613 | prgregset_t avar | |
4614 | ; return 0; } | |
4615 | EOF | |
b46cd165 | 4616 | if { (eval echo configure:4617: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
3862412b MK |
4617 | rm -rf conftest* |
4618 | bfd_cv_have_sys_procfs_type_prgregset_t=yes | |
4619 | else | |
4620 | echo "configure: failed program was:" >&5 | |
4621 | cat conftest.$ac_ext >&5 | |
4622 | rm -rf conftest* | |
4623 | bfd_cv_have_sys_procfs_type_prgregset_t=no | |
4624 | ||
4625 | fi | |
4626 | rm -f conftest* | |
4627 | fi | |
4628 | ||
4629 | if test $bfd_cv_have_sys_procfs_type_prgregset_t = yes; then | |
4630 | cat >> confdefs.h <<\EOF | |
4631 | #define HAVE_PRGREGSET_T 1 | |
4632 | EOF | |
4633 | ||
4634 | fi | |
4635 | echo "$ac_t""$bfd_cv_have_sys_procfs_type_prgregset_t" 1>&6 | |
4636 | ||
4637 | echo $ac_n "checking for prfpregset_t in sys/procfs.h""... $ac_c" 1>&6 | |
b46cd165 | 4638 | echo "configure:4639: checking for prfpregset_t in sys/procfs.h" >&5 |
3862412b MK |
4639 | if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prfpregset_t'+set}'`\" = set"; then |
4640 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4641 | else | |
4642 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 4643 | #line 4644 "configure" |
3862412b | 4644 | #include "confdefs.h" |
e17bf198 AO |
4645 | |
4646 | #define _SYSCALL32 | |
3862412b MK |
4647 | #include <sys/procfs.h> |
4648 | int main() { | |
4649 | prfpregset_t avar | |
4650 | ; return 0; } | |
4651 | EOF | |
b46cd165 | 4652 | if { (eval echo configure:4653: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
3862412b MK |
4653 | rm -rf conftest* |
4654 | bfd_cv_have_sys_procfs_type_prfpregset_t=yes | |
4655 | else | |
4656 | echo "configure: failed program was:" >&5 | |
4657 | cat conftest.$ac_ext >&5 | |
4658 | rm -rf conftest* | |
4659 | bfd_cv_have_sys_procfs_type_prfpregset_t=no | |
4660 | ||
4661 | fi | |
4662 | rm -f conftest* | |
4663 | fi | |
4664 | ||
4665 | if test $bfd_cv_have_sys_procfs_type_prfpregset_t = yes; then | |
4666 | cat >> confdefs.h <<\EOF | |
4667 | #define HAVE_PRFPREGSET_T 1 | |
4668 | EOF | |
4669 | ||
4670 | fi | |
4671 | echo "$ac_t""$bfd_cv_have_sys_procfs_type_prfpregset_t" 1>&6 | |
4672 | ||
451928c5 | 4673 | echo $ac_n "checking for prgregset32_t in sys/procfs.h""... $ac_c" 1>&6 |
b46cd165 | 4674 | echo "configure:4675: checking for prgregset32_t in sys/procfs.h" >&5 |
451928c5 AC |
4675 | if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prgregset32_t'+set}'`\" = set"; then |
4676 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4677 | else | |
4678 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 4679 | #line 4680 "configure" |
451928c5 | 4680 | #include "confdefs.h" |
e17bf198 AO |
4681 | |
4682 | #define _SYSCALL32 | |
451928c5 AC |
4683 | #include <sys/procfs.h> |
4684 | int main() { | |
4685 | prgregset32_t avar | |
4686 | ; return 0; } | |
4687 | EOF | |
b46cd165 | 4688 | if { (eval echo configure:4689: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
451928c5 AC |
4689 | rm -rf conftest* |
4690 | bfd_cv_have_sys_procfs_type_prgregset32_t=yes | |
4691 | else | |
4692 | echo "configure: failed program was:" >&5 | |
4693 | cat conftest.$ac_ext >&5 | |
4694 | rm -rf conftest* | |
4695 | bfd_cv_have_sys_procfs_type_prgregset32_t=no | |
4696 | ||
4697 | fi | |
4698 | rm -f conftest* | |
4699 | fi | |
4700 | ||
4701 | if test $bfd_cv_have_sys_procfs_type_prgregset32_t = yes; then | |
4702 | cat >> confdefs.h <<\EOF | |
4703 | #define HAVE_PRGREGSET32_T 1 | |
4704 | EOF | |
4705 | ||
4706 | fi | |
4707 | echo "$ac_t""$bfd_cv_have_sys_procfs_type_prgregset32_t" 1>&6 | |
4708 | ||
4709 | echo $ac_n "checking for prfpregset32_t in sys/procfs.h""... $ac_c" 1>&6 | |
b46cd165 | 4710 | echo "configure:4711: checking for prfpregset32_t in sys/procfs.h" >&5 |
451928c5 AC |
4711 | if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prfpregset32_t'+set}'`\" = set"; then |
4712 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4713 | else | |
4714 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 4715 | #line 4716 "configure" |
451928c5 | 4716 | #include "confdefs.h" |
e17bf198 AO |
4717 | |
4718 | #define _SYSCALL32 | |
451928c5 AC |
4719 | #include <sys/procfs.h> |
4720 | int main() { | |
4721 | prfpregset32_t avar | |
4722 | ; return 0; } | |
4723 | EOF | |
b46cd165 | 4724 | if { (eval echo configure:4725: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
451928c5 AC |
4725 | rm -rf conftest* |
4726 | bfd_cv_have_sys_procfs_type_prfpregset32_t=yes | |
4727 | else | |
4728 | echo "configure: failed program was:" >&5 | |
4729 | cat conftest.$ac_ext >&5 | |
4730 | rm -rf conftest* | |
4731 | bfd_cv_have_sys_procfs_type_prfpregset32_t=no | |
4732 | ||
4733 | fi | |
4734 | rm -f conftest* | |
4735 | fi | |
4736 | ||
4737 | if test $bfd_cv_have_sys_procfs_type_prfpregset32_t = yes; then | |
4738 | cat >> confdefs.h <<\EOF | |
4739 | #define HAVE_PRFPREGSET32_T 1 | |
4740 | EOF | |
4741 | ||
4742 | fi | |
4743 | echo "$ac_t""$bfd_cv_have_sys_procfs_type_prfpregset32_t" 1>&6 | |
4744 | ||
3862412b | 4745 | echo $ac_n "checking for lwpid_t in sys/procfs.h""... $ac_c" 1>&6 |
b46cd165 | 4746 | echo "configure:4747: checking for lwpid_t in sys/procfs.h" >&5 |
3862412b MK |
4747 | if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_lwpid_t'+set}'`\" = set"; then |
4748 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4749 | else | |
4750 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 4751 | #line 4752 "configure" |
3862412b | 4752 | #include "confdefs.h" |
e17bf198 AO |
4753 | |
4754 | #define _SYSCALL32 | |
3862412b MK |
4755 | #include <sys/procfs.h> |
4756 | int main() { | |
4757 | lwpid_t avar | |
4758 | ; return 0; } | |
4759 | EOF | |
b46cd165 | 4760 | if { (eval echo configure:4761: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
3862412b MK |
4761 | rm -rf conftest* |
4762 | bfd_cv_have_sys_procfs_type_lwpid_t=yes | |
4763 | else | |
4764 | echo "configure: failed program was:" >&5 | |
4765 | cat conftest.$ac_ext >&5 | |
4766 | rm -rf conftest* | |
4767 | bfd_cv_have_sys_procfs_type_lwpid_t=no | |
4768 | ||
4769 | fi | |
4770 | rm -f conftest* | |
4771 | fi | |
4772 | ||
4773 | if test $bfd_cv_have_sys_procfs_type_lwpid_t = yes; then | |
4774 | cat >> confdefs.h <<\EOF | |
4775 | #define HAVE_LWPID_T 1 | |
4776 | EOF | |
4777 | ||
4778 | fi | |
4779 | echo "$ac_t""$bfd_cv_have_sys_procfs_type_lwpid_t" 1>&6 | |
4780 | ||
4781 | echo $ac_n "checking for psaddr_t in sys/procfs.h""... $ac_c" 1>&6 | |
b46cd165 | 4782 | echo "configure:4783: checking for psaddr_t in sys/procfs.h" >&5 |
3862412b MK |
4783 | if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_psaddr_t'+set}'`\" = set"; then |
4784 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4785 | else | |
4786 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 4787 | #line 4788 "configure" |
3862412b | 4788 | #include "confdefs.h" |
e17bf198 AO |
4789 | |
4790 | #define _SYSCALL32 | |
3862412b MK |
4791 | #include <sys/procfs.h> |
4792 | int main() { | |
4793 | psaddr_t avar | |
4794 | ; return 0; } | |
4795 | EOF | |
b46cd165 | 4796 | if { (eval echo configure:4797: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
3862412b MK |
4797 | rm -rf conftest* |
4798 | bfd_cv_have_sys_procfs_type_psaddr_t=yes | |
4799 | else | |
4800 | echo "configure: failed program was:" >&5 | |
4801 | cat conftest.$ac_ext >&5 | |
4802 | rm -rf conftest* | |
4803 | bfd_cv_have_sys_procfs_type_psaddr_t=no | |
4804 | ||
4805 | fi | |
4806 | rm -f conftest* | |
4807 | fi | |
4808 | ||
4809 | if test $bfd_cv_have_sys_procfs_type_psaddr_t = yes; then | |
4810 | cat >> confdefs.h <<\EOF | |
4811 | #define HAVE_PSADDR_T 1 | |
4812 | EOF | |
4813 | ||
4814 | fi | |
4815 | echo "$ac_t""$bfd_cv_have_sys_procfs_type_psaddr_t" 1>&6 | |
4816 | ||
c906108c | 4817 | |
451928c5 AC |
4818 | |
4819 | echo $ac_n "checking for struct link_map32 in sys/link.h""... $ac_c" 1>&6 | |
b46cd165 | 4820 | echo "configure:4821: checking for struct link_map32 in sys/link.h" >&5 |
451928c5 AC |
4821 | if eval "test \"`echo '$''{'gdb_cv_have_struct_link_map32'+set}'`\" = set"; then |
4822 | echo $ac_n "(cached) $ac_c" 1>&6 | |
451928c5 AC |
4823 | else |
4824 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 4825 | #line 4826 "configure" |
451928c5 AC |
4826 | #include "confdefs.h" |
4827 | #define _SYSCALL32 | |
2bba1017 KB |
4828 | #include <sys/link.h> |
4829 | int main() { | |
4830 | struct link_map32 l; | |
4831 | ; return 0; } | |
4832 | EOF | |
b46cd165 | 4833 | if { (eval echo configure:4834: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
2bba1017 KB |
4834 | rm -rf conftest* |
4835 | gdb_cv_have_struct_link_map32=yes | |
451928c5 AC |
4836 | else |
4837 | echo "configure: failed program was:" >&5 | |
4838 | cat conftest.$ac_ext >&5 | |
2bba1017 KB |
4839 | rm -rf conftest* |
4840 | gdb_cv_have_struct_link_map32=no | |
451928c5 | 4841 | fi |
2bba1017 | 4842 | rm -f conftest* |
451928c5 AC |
4843 | fi |
4844 | ||
4845 | echo "$ac_t""$gdb_cv_have_struct_link_map32" 1>&6 | |
4846 | if test $gdb_cv_have_struct_link_map32 = yes; then | |
4847 | cat >> confdefs.h <<\EOF | |
4848 | #define HAVE_STRUCT_LINK_MAP32 1 | |
4849 | EOF | |
4850 | ||
4851 | fi | |
4852 | ||
c906108c | 4853 | |
746a987d | 4854 | |
d84dd0c5 MK |
4855 | if test $bfd_cv_have_sys_procfs_type_prfpregset_t = yes; then |
4856 | echo $ac_n "checking whether prfpregset_t type is broken""... $ac_c" 1>&6 | |
b46cd165 | 4857 | echo "configure:4858: checking whether prfpregset_t type is broken" >&5 |
d84dd0c5 MK |
4858 | if eval "test \"`echo '$''{'gdb_cv_prfpregset_t_broken'+set}'`\" = set"; then |
4859 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4860 | else | |
4861 | if test "$cross_compiling" = yes; then | |
4862 | gdb_cv_prfpregset_t_broken=yes | |
4863 | else | |
4864 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 4865 | #line 4866 "configure" |
d84dd0c5 MK |
4866 | #include "confdefs.h" |
4867 | #include <sys/procfs.h> | |
4868 | int main () | |
4869 | { | |
4870 | if (sizeof (prfpregset_t) == sizeof (void *)) | |
4871 | return 1; | |
4872 | return 0; | |
4873 | } | |
4874 | EOF | |
b46cd165 | 4875 | if { (eval echo configure:4876: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
d84dd0c5 MK |
4876 | then |
4877 | gdb_cv_prfpregset_t_broken=no | |
4878 | else | |
4879 | echo "configure: failed program was:" >&5 | |
4880 | cat conftest.$ac_ext >&5 | |
4881 | rm -fr conftest* | |
4882 | gdb_cv_prfpregset_t_broken=yes | |
4883 | fi | |
4884 | rm -fr conftest* | |
4885 | fi | |
4886 | ||
4887 | fi | |
4888 | ||
4889 | echo "$ac_t""$gdb_cv_prfpregset_t_broken" 1>&6 | |
4890 | if test $gdb_cv_prfpregset_t_broken = yes; then | |
4891 | cat >> confdefs.h <<\EOF | |
4892 | #define PRFPREGSET_T_BROKEN 1 | |
4893 | EOF | |
4894 | ||
4895 | fi | |
4896 | fi | |
4897 | ||
4898 | ||
c906108c | 4899 | echo $ac_n "checking for PIOCSET ioctl entry in sys/procfs.h""... $ac_c" 1>&6 |
b46cd165 | 4900 | echo "configure:4901: checking for PIOCSET ioctl entry in sys/procfs.h" >&5 |
c906108c SS |
4901 | if eval "test \"`echo '$''{'gdb_cv_have_procfs_piocset'+set}'`\" = set"; then |
4902 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4903 | else | |
4904 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 4905 | #line 4906 "configure" |
c906108c SS |
4906 | #include "confdefs.h" |
4907 | #include <unistd.h> | |
4908 | #include <sys/types.h> | |
4909 | #include <sys/procfs.h> | |
4910 | ||
4911 | int main() { | |
4912 | ||
4913 | int dummy;; | |
4914 | dummy = ioctl(0, PIOCSET, &dummy); | |
4915 | ||
4916 | ; return 0; } | |
4917 | EOF | |
b46cd165 | 4918 | if { (eval echo configure:4919: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
c906108c SS |
4919 | rm -rf conftest* |
4920 | gdb_cv_have_procfs_piocset=yes | |
4921 | else | |
4922 | echo "configure: failed program was:" >&5 | |
4923 | cat conftest.$ac_ext >&5 | |
4924 | rm -rf conftest* | |
4925 | gdb_cv_have_procfs_piocset=no | |
4926 | fi | |
4927 | rm -f conftest* | |
4928 | fi | |
4929 | ||
4930 | echo "$ac_t""$gdb_cv_have_procfs_piocset" 1>&6 | |
4931 | if test $gdb_cv_have_procfs_piocset = yes; then | |
4932 | cat >> confdefs.h <<\EOF | |
4933 | #define HAVE_PROCFS_PIOCSET 1 | |
4934 | EOF | |
4935 | ||
4936 | fi | |
4937 | fi | |
4938 | ||
4939 | echo $ac_n "checking for main in -lm""... $ac_c" 1>&6 | |
b46cd165 | 4940 | echo "configure:4941: checking for main in -lm" >&5 |
c906108c SS |
4941 | ac_lib_var=`echo m'_'main | sed 'y%./+-%__p_%'` |
4942 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then | |
4943 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4944 | else | |
4945 | ac_save_LIBS="$LIBS" | |
4946 | LIBS="-lm $LIBS" | |
4947 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 4948 | #line 4949 "configure" |
c906108c SS |
4949 | #include "confdefs.h" |
4950 | ||
4951 | int main() { | |
4952 | main() | |
4953 | ; return 0; } | |
4954 | EOF | |
b46cd165 | 4955 | if { (eval echo configure:4956: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
c906108c SS |
4956 | rm -rf conftest* |
4957 | eval "ac_cv_lib_$ac_lib_var=yes" | |
4958 | else | |
4959 | echo "configure: failed program was:" >&5 | |
4960 | cat conftest.$ac_ext >&5 | |
4961 | rm -rf conftest* | |
4962 | eval "ac_cv_lib_$ac_lib_var=no" | |
4963 | fi | |
4964 | rm -f conftest* | |
4965 | LIBS="$ac_save_LIBS" | |
4966 | ||
4967 | fi | |
4968 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then | |
4969 | echo "$ac_t""yes" 1>&6 | |
4970 | ac_tr_lib=HAVE_LIB`echo m | sed -e 's/[^a-zA-Z0-9_]/_/g' \ | |
4971 | -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` | |
4972 | cat >> confdefs.h <<EOF | |
4973 | #define $ac_tr_lib 1 | |
4974 | EOF | |
4975 | ||
4976 | LIBS="-lm $LIBS" | |
4977 | ||
4978 | else | |
4979 | echo "$ac_t""no" 1>&6 | |
4980 | fi | |
4981 | ||
4982 | ||
4983 | echo $ac_n "checking for wctype in -lc""... $ac_c" 1>&6 | |
b46cd165 | 4984 | echo "configure:4985: checking for wctype in -lc" >&5 |
c906108c SS |
4985 | ac_lib_var=`echo c'_'wctype | sed 'y%./+-%__p_%'` |
4986 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then | |
4987 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4988 | else | |
4989 | ac_save_LIBS="$LIBS" | |
4990 | LIBS="-lc $LIBS" | |
4991 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 4992 | #line 4993 "configure" |
c906108c SS |
4993 | #include "confdefs.h" |
4994 | /* Override any gcc2 internal prototype to avoid an error. */ | |
4995 | /* We use char because int might match the return type of a gcc2 | |
4996 | builtin and then its argument prototype would still apply. */ | |
4997 | char wctype(); | |
4998 | ||
4999 | int main() { | |
5000 | wctype() | |
5001 | ; return 0; } | |
5002 | EOF | |
b46cd165 | 5003 | if { (eval echo configure:5004: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
c906108c SS |
5004 | rm -rf conftest* |
5005 | eval "ac_cv_lib_$ac_lib_var=yes" | |
5006 | else | |
5007 | echo "configure: failed program was:" >&5 | |
5008 | cat conftest.$ac_ext >&5 | |
5009 | rm -rf conftest* | |
5010 | eval "ac_cv_lib_$ac_lib_var=no" | |
5011 | fi | |
5012 | rm -f conftest* | |
5013 | LIBS="$ac_save_LIBS" | |
5014 | ||
5015 | fi | |
5016 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then | |
5017 | echo "$ac_t""yes" 1>&6 | |
5018 | : | |
5019 | else | |
5020 | echo "$ac_t""no" 1>&6 | |
5021 | echo $ac_n "checking for wctype in -lw""... $ac_c" 1>&6 | |
b46cd165 | 5022 | echo "configure:5023: checking for wctype in -lw" >&5 |
c906108c SS |
5023 | ac_lib_var=`echo w'_'wctype | sed 'y%./+-%__p_%'` |
5024 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then | |
5025 | echo $ac_n "(cached) $ac_c" 1>&6 | |
5026 | else | |
5027 | ac_save_LIBS="$LIBS" | |
5028 | LIBS="-lw $LIBS" | |
5029 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 5030 | #line 5031 "configure" |
c906108c SS |
5031 | #include "confdefs.h" |
5032 | /* Override any gcc2 internal prototype to avoid an error. */ | |
5033 | /* We use char because int might match the return type of a gcc2 | |
5034 | builtin and then its argument prototype would still apply. */ | |
5035 | char wctype(); | |
5036 | ||
5037 | int main() { | |
5038 | wctype() | |
5039 | ; return 0; } | |
5040 | EOF | |
b46cd165 | 5041 | if { (eval echo configure:5042: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
c906108c SS |
5042 | rm -rf conftest* |
5043 | eval "ac_cv_lib_$ac_lib_var=yes" | |
5044 | else | |
5045 | echo "configure: failed program was:" >&5 | |
5046 | cat conftest.$ac_ext >&5 | |
5047 | rm -rf conftest* | |
5048 | eval "ac_cv_lib_$ac_lib_var=no" | |
5049 | fi | |
5050 | rm -f conftest* | |
5051 | LIBS="$ac_save_LIBS" | |
5052 | ||
5053 | fi | |
5054 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then | |
5055 | echo "$ac_t""yes" 1>&6 | |
5056 | ac_tr_lib=HAVE_LIB`echo w | sed -e 's/^a-zA-Z0-9_/_/g' \ | |
5057 | -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` | |
5058 | cat >> confdefs.h <<EOF | |
5059 | #define $ac_tr_lib 1 | |
5060 | EOF | |
5061 | ||
5062 | LIBS="-lw $LIBS" | |
5063 | ||
5064 | else | |
5065 | echo "$ac_t""no" 1>&6 | |
5066 | fi | |
5067 | ||
5068 | fi | |
5069 | ||
5070 | ||
5071 | ||
5072 | echo $ac_n "checking for long long support in compiler""... $ac_c" 1>&6 | |
b46cd165 | 5073 | echo "configure:5074: checking for long long support in compiler" >&5 |
c906108c SS |
5074 | if eval "test \"`echo '$''{'gdb_cv_c_long_long'+set}'`\" = set"; then |
5075 | echo $ac_n "(cached) $ac_c" 1>&6 | |
5076 | else | |
5077 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 5078 | #line 5079 "configure" |
c906108c SS |
5079 | #include "confdefs.h" |
5080 | ||
5081 | int main() { | |
5082 | ||
5083 | extern long long foo; | |
5084 | switch (foo & 2) { case 0: return 1; } | |
5085 | ||
5086 | ; return 0; } | |
5087 | EOF | |
b46cd165 | 5088 | if { (eval echo configure:5089: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
c906108c SS |
5089 | rm -rf conftest* |
5090 | gdb_cv_c_long_long=yes | |
5091 | else | |
5092 | echo "configure: failed program was:" >&5 | |
5093 | cat conftest.$ac_ext >&5 | |
5094 | rm -rf conftest* | |
5095 | gdb_cv_c_long_long=no | |
5096 | fi | |
5097 | rm -f conftest* | |
5098 | fi | |
5099 | ||
5100 | echo "$ac_t""$gdb_cv_c_long_long" 1>&6 | |
5101 | if test $gdb_cv_c_long_long = yes; then | |
5102 | cat >> confdefs.h <<\EOF | |
5103 | #define CC_HAS_LONG_LONG 1 | |
5104 | EOF | |
5105 | ||
5106 | fi | |
5107 | ||
5108 | ||
5109 | echo $ac_n "checking for long long support in printf""... $ac_c" 1>&6 | |
b46cd165 | 5110 | echo "configure:5111: checking for long long support in printf" >&5 |
c906108c SS |
5111 | if eval "test \"`echo '$''{'gdb_cv_printf_has_long_long'+set}'`\" = set"; then |
5112 | echo $ac_n "(cached) $ac_c" 1>&6 | |
5113 | else | |
5114 | if test "$cross_compiling" = yes; then | |
5115 | gdb_cv_printf_has_long_long=no | |
5116 | else | |
5117 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 5118 | #line 5119 "configure" |
c906108c SS |
5119 | #include "confdefs.h" |
5120 | ||
5121 | int main () { | |
5122 | char buf[32]; | |
5123 | long long l = 0; | |
5124 | l = (l << 16) + 0x0123; | |
5125 | l = (l << 16) + 0x4567; | |
5126 | l = (l << 16) + 0x89ab; | |
5127 | l = (l << 16) + 0xcdef; | |
5128 | sprintf (buf, "0x%016llx", l); | |
5129 | return (strcmp ("0x0123456789abcdef", buf)); | |
5130 | } | |
5131 | EOF | |
b46cd165 | 5132 | if { (eval echo configure:5133: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
c906108c SS |
5133 | then |
5134 | gdb_cv_printf_has_long_long=yes | |
5135 | else | |
5136 | echo "configure: failed program was:" >&5 | |
5137 | cat conftest.$ac_ext >&5 | |
5138 | rm -fr conftest* | |
5139 | gdb_cv_printf_has_long_long=no | |
5140 | fi | |
5141 | rm -fr conftest* | |
5142 | fi | |
5143 | ||
5144 | fi | |
5145 | ||
5146 | if test $gdb_cv_printf_has_long_long = yes; then | |
5147 | cat >> confdefs.h <<\EOF | |
5148 | #define PRINTF_HAS_LONG_LONG 1 | |
5149 | EOF | |
5150 | ||
5151 | fi | |
5152 | echo "$ac_t""$gdb_cv_printf_has_long_long" 1>&6 | |
5153 | ||
5154 | ||
5155 | echo $ac_n "checking for long double support in compiler""... $ac_c" 1>&6 | |
b46cd165 | 5156 | echo "configure:5157: checking for long double support in compiler" >&5 |
c906108c SS |
5157 | if eval "test \"`echo '$''{'ac_cv_c_long_double'+set}'`\" = set"; then |
5158 | echo $ac_n "(cached) $ac_c" 1>&6 | |
5159 | else | |
5160 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 5161 | #line 5162 "configure" |
c906108c SS |
5162 | #include "confdefs.h" |
5163 | ||
5164 | int main() { | |
5165 | long double foo; | |
5166 | ; return 0; } | |
5167 | EOF | |
b46cd165 | 5168 | if { (eval echo configure:5169: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
c906108c SS |
5169 | rm -rf conftest* |
5170 | ac_cv_c_long_double=yes | |
5171 | else | |
5172 | echo "configure: failed program was:" >&5 | |
5173 | cat conftest.$ac_ext >&5 | |
5174 | rm -rf conftest* | |
5175 | ac_cv_c_long_double=no | |
5176 | fi | |
5177 | rm -f conftest* | |
5178 | fi | |
5179 | ||
5180 | echo "$ac_t""$ac_cv_c_long_double" 1>&6 | |
5181 | if test $ac_cv_c_long_double = yes; then | |
5182 | cat >> confdefs.h <<\EOF | |
5183 | #define HAVE_LONG_DOUBLE 1 | |
5184 | EOF | |
5185 | ||
5186 | fi | |
5187 | ||
5188 | ||
5189 | echo $ac_n "checking for long double support in printf""... $ac_c" 1>&6 | |
b46cd165 | 5190 | echo "configure:5191: checking for long double support in printf" >&5 |
c906108c SS |
5191 | if eval "test \"`echo '$''{'gdb_cv_printf_has_long_double'+set}'`\" = set"; then |
5192 | echo $ac_n "(cached) $ac_c" 1>&6 | |
5193 | else | |
5194 | if test "$cross_compiling" = yes; then | |
5195 | gdb_cv_printf_has_long_double=no | |
5196 | else | |
5197 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 5198 | #line 5199 "configure" |
c906108c SS |
5199 | #include "confdefs.h" |
5200 | ||
5201 | int main () { | |
5202 | char buf[16]; | |
5203 | long double f = 3.141592653; | |
5204 | sprintf (buf, "%Lg", f); | |
5205 | return (strncmp ("3.14159", buf, 7)); | |
5206 | } | |
5207 | EOF | |
b46cd165 | 5208 | if { (eval echo configure:5209: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
c906108c SS |
5209 | then |
5210 | gdb_cv_printf_has_long_double=yes | |
5211 | else | |
5212 | echo "configure: failed program was:" >&5 | |
5213 | cat conftest.$ac_ext >&5 | |
5214 | rm -fr conftest* | |
5215 | gdb_cv_printf_has_long_double=no | |
5216 | fi | |
5217 | rm -fr conftest* | |
5218 | fi | |
5219 | ||
5220 | fi | |
5221 | ||
5222 | if test $gdb_cv_printf_has_long_double = yes; then | |
5223 | cat >> confdefs.h <<\EOF | |
5224 | #define PRINTF_HAS_LONG_DOUBLE 1 | |
5225 | EOF | |
5226 | ||
5227 | fi | |
5228 | echo "$ac_t""$gdb_cv_printf_has_long_double" 1>&6 | |
5229 | ||
5230 | ||
5231 | echo $ac_n "checking for long double support in scanf""... $ac_c" 1>&6 | |
b46cd165 | 5232 | echo "configure:5233: checking for long double support in scanf" >&5 |
c906108c SS |
5233 | if eval "test \"`echo '$''{'gdb_cv_scanf_has_long_double'+set}'`\" = set"; then |
5234 | echo $ac_n "(cached) $ac_c" 1>&6 | |
5235 | else | |
5236 | if test "$cross_compiling" = yes; then | |
5237 | gdb_cv_scanf_has_long_double=no | |
5238 | else | |
5239 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 5240 | #line 5241 "configure" |
c906108c SS |
5241 | #include "confdefs.h" |
5242 | ||
5243 | int main () { | |
5244 | char *buf = "3.141592653"; | |
5245 | long double f = 0; | |
5246 | sscanf (buf, "%Lg", &f); | |
5247 | return !(f > 3.14159 && f < 3.14160); | |
5248 | } | |
5249 | EOF | |
b46cd165 | 5250 | if { (eval echo configure:5251: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
c906108c SS |
5251 | then |
5252 | gdb_cv_scanf_has_long_double=yes | |
5253 | else | |
5254 | echo "configure: failed program was:" >&5 | |
5255 | cat conftest.$ac_ext >&5 | |
5256 | rm -fr conftest* | |
5257 | gdb_cv_scanf_has_long_double=no | |
5258 | fi | |
5259 | rm -fr conftest* | |
5260 | fi | |
5261 | ||
5262 | fi | |
5263 | ||
5264 | if test $gdb_cv_scanf_has_long_double = yes; then | |
5265 | cat >> confdefs.h <<\EOF | |
5266 | #define SCANF_HAS_LONG_DOUBLE 1 | |
5267 | EOF | |
5268 | ||
5269 | fi | |
5270 | echo "$ac_t""$gdb_cv_scanf_has_long_double" 1>&6 | |
5271 | ||
5272 | for ac_hdr in unistd.h | |
5273 | do | |
5274 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` | |
5275 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 | |
b46cd165 | 5276 | echo "configure:5277: checking for $ac_hdr" >&5 |
c906108c SS |
5277 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
5278 | echo $ac_n "(cached) $ac_c" 1>&6 | |
5279 | else | |
5280 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 5281 | #line 5282 "configure" |
c906108c SS |
5282 | #include "confdefs.h" |
5283 | #include <$ac_hdr> | |
5284 | EOF | |
5285 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
b46cd165 | 5286 | { (eval echo configure:5287: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
c906108c SS |
5287 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
5288 | if test -z "$ac_err"; then | |
5289 | rm -rf conftest* | |
5290 | eval "ac_cv_header_$ac_safe=yes" | |
5291 | else | |
5292 | echo "$ac_err" >&5 | |
5293 | echo "configure: failed program was:" >&5 | |
5294 | cat conftest.$ac_ext >&5 | |
5295 | rm -rf conftest* | |
5296 | eval "ac_cv_header_$ac_safe=no" | |
5297 | fi | |
5298 | rm -f conftest* | |
5299 | fi | |
5300 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | |
5301 | echo "$ac_t""yes" 1>&6 | |
5302 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` | |
5303 | cat >> confdefs.h <<EOF | |
5304 | #define $ac_tr_hdr 1 | |
5305 | EOF | |
5306 | ||
5307 | else | |
5308 | echo "$ac_t""no" 1>&6 | |
5309 | fi | |
5310 | done | |
5311 | ||
5312 | for ac_func in getpagesize | |
5313 | do | |
5314 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
b46cd165 | 5315 | echo "configure:5316: checking for $ac_func" >&5 |
c906108c SS |
5316 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
5317 | echo $ac_n "(cached) $ac_c" 1>&6 | |
5318 | else | |
5319 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 5320 | #line 5321 "configure" |
c906108c SS |
5321 | #include "confdefs.h" |
5322 | /* System header to define __stub macros and hopefully few prototypes, | |
5323 | which can conflict with char $ac_func(); below. */ | |
5324 | #include <assert.h> | |
5325 | /* Override any gcc2 internal prototype to avoid an error. */ | |
5326 | /* We use char because int might match the return type of a gcc2 | |
5327 | builtin and then its argument prototype would still apply. */ | |
5328 | char $ac_func(); | |
5329 | ||
5330 | int main() { | |
5331 | ||
5332 | /* The GNU C library defines this for functions which it implements | |
5333 | to always fail with ENOSYS. Some functions are actually named | |
5334 | something starting with __ and the normal name is an alias. */ | |
5335 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
5336 | choke me | |
5337 | #else | |
5338 | $ac_func(); | |
5339 | #endif | |
5340 | ||
5341 | ; return 0; } | |
5342 | EOF | |
b46cd165 | 5343 | if { (eval echo configure:5344: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
c906108c SS |
5344 | rm -rf conftest* |
5345 | eval "ac_cv_func_$ac_func=yes" | |
5346 | else | |
5347 | echo "configure: failed program was:" >&5 | |
5348 | cat conftest.$ac_ext >&5 | |
5349 | rm -rf conftest* | |
5350 | eval "ac_cv_func_$ac_func=no" | |
5351 | fi | |
5352 | rm -f conftest* | |
5353 | fi | |
5354 | ||
5355 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then | |
5356 | echo "$ac_t""yes" 1>&6 | |
5357 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
5358 | cat >> confdefs.h <<EOF | |
5359 | #define $ac_tr_func 1 | |
5360 | EOF | |
5361 | ||
5362 | else | |
5363 | echo "$ac_t""no" 1>&6 | |
5364 | fi | |
5365 | done | |
5366 | ||
5367 | echo $ac_n "checking for working mmap""... $ac_c" 1>&6 | |
b46cd165 | 5368 | echo "configure:5369: checking for working mmap" >&5 |
c906108c SS |
5369 | if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then |
5370 | echo $ac_n "(cached) $ac_c" 1>&6 | |
5371 | else | |
5372 | if test "$cross_compiling" = yes; then | |
5373 | ac_cv_func_mmap_fixed_mapped=no | |
5374 | else | |
5375 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 5376 | #line 5377 "configure" |
c906108c SS |
5377 | #include "confdefs.h" |
5378 | ||
5379 | /* Thanks to Mike Haertel and Jim Avera for this test. | |
5380 | Here is a matrix of mmap possibilities: | |
5381 | mmap private not fixed | |
5382 | mmap private fixed at somewhere currently unmapped | |
5383 | mmap private fixed at somewhere already mapped | |
5384 | mmap shared not fixed | |
5385 | mmap shared fixed at somewhere currently unmapped | |
5386 | mmap shared fixed at somewhere already mapped | |
5387 | For private mappings, we should verify that changes cannot be read() | |
5388 | back from the file, nor mmap's back from the file at a different | |
5389 | address. (There have been systems where private was not correctly | |
5390 | implemented like the infamous i386 svr4.0, and systems where the | |
5391 | VM page cache was not coherent with the filesystem buffer cache | |
5392 | like early versions of FreeBSD and possibly contemporary NetBSD.) | |
5393 | For shared mappings, we should conversely verify that changes get | |
5394 | propogated back to all the places they're supposed to be. | |
5395 | ||
5396 | Grep wants private fixed already mapped. | |
5397 | The main things grep needs to know about mmap are: | |
5398 | * does it exist and is it safe to write into the mmap'd area | |
5399 | * how to use it (BSD variants) */ | |
5400 | #include <sys/types.h> | |
5401 | #include <fcntl.h> | |
5402 | #include <sys/mman.h> | |
5403 | ||
5404 | /* This mess was copied from the GNU getpagesize.h. */ | |
5405 | #ifndef HAVE_GETPAGESIZE | |
5406 | # ifdef HAVE_UNISTD_H | |
5407 | # include <unistd.h> | |
5408 | # endif | |
5409 | ||
5410 | /* Assume that all systems that can run configure have sys/param.h. */ | |
5411 | # ifndef HAVE_SYS_PARAM_H | |
5412 | # define HAVE_SYS_PARAM_H 1 | |
5413 | # endif | |
5414 | ||
5415 | # ifdef _SC_PAGESIZE | |
5416 | # define getpagesize() sysconf(_SC_PAGESIZE) | |
5417 | # else /* no _SC_PAGESIZE */ | |
5418 | # ifdef HAVE_SYS_PARAM_H | |
5419 | # include <sys/param.h> | |
5420 | # ifdef EXEC_PAGESIZE | |
5421 | # define getpagesize() EXEC_PAGESIZE | |
5422 | # else /* no EXEC_PAGESIZE */ | |
5423 | # ifdef NBPG | |
5424 | # define getpagesize() NBPG * CLSIZE | |
5425 | # ifndef CLSIZE | |
5426 | # define CLSIZE 1 | |
5427 | # endif /* no CLSIZE */ | |
5428 | # else /* no NBPG */ | |
5429 | # ifdef NBPC | |
5430 | # define getpagesize() NBPC | |
5431 | # else /* no NBPC */ | |
5432 | # ifdef PAGESIZE | |
5433 | # define getpagesize() PAGESIZE | |
5434 | # endif /* PAGESIZE */ | |
5435 | # endif /* no NBPC */ | |
5436 | # endif /* no NBPG */ | |
5437 | # endif /* no EXEC_PAGESIZE */ | |
5438 | # else /* no HAVE_SYS_PARAM_H */ | |
5439 | # define getpagesize() 8192 /* punt totally */ | |
5440 | # endif /* no HAVE_SYS_PARAM_H */ | |
5441 | # endif /* no _SC_PAGESIZE */ | |
5442 | ||
5443 | #endif /* no HAVE_GETPAGESIZE */ | |
5444 | ||
5445 | #ifdef __cplusplus | |
5446 | extern "C" { void *malloc(unsigned); } | |
5447 | #else | |
5448 | char *malloc(); | |
5449 | #endif | |
5450 | ||
5451 | int | |
5452 | main() | |
5453 | { | |
5454 | char *data, *data2, *data3; | |
5455 | int i, pagesize; | |
5456 | int fd; | |
5457 | ||
5458 | pagesize = getpagesize(); | |
5459 | ||
5460 | /* | |
5461 | * First, make a file with some known garbage in it. | |
5462 | */ | |
5463 | data = malloc(pagesize); | |
5464 | if (!data) | |
5465 | exit(1); | |
5466 | for (i = 0; i < pagesize; ++i) | |
5467 | *(data + i) = rand(); | |
5468 | umask(0); | |
5469 | fd = creat("conftestmmap", 0600); | |
5470 | if (fd < 0) | |
5471 | exit(1); | |
5472 | if (write(fd, data, pagesize) != pagesize) | |
5473 | exit(1); | |
5474 | close(fd); | |
5475 | ||
5476 | /* | |
5477 | * Next, try to mmap the file at a fixed address which | |
5478 | * already has something else allocated at it. If we can, | |
5479 | * also make sure that we see the same garbage. | |
5480 | */ | |
5481 | fd = open("conftestmmap", O_RDWR); | |
5482 | if (fd < 0) | |
5483 | exit(1); | |
5484 | data2 = malloc(2 * pagesize); | |
5485 | if (!data2) | |
5486 | exit(1); | |
5487 | data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1); | |
5488 | if (data2 != mmap(data2, pagesize, PROT_READ | PROT_WRITE, | |
5489 | MAP_PRIVATE | MAP_FIXED, fd, 0L)) | |
5490 | exit(1); | |
5491 | for (i = 0; i < pagesize; ++i) | |
5492 | if (*(data + i) != *(data2 + i)) | |
5493 | exit(1); | |
5494 | ||
5495 | /* | |
5496 | * Finally, make sure that changes to the mapped area | |
5497 | * do not percolate back to the file as seen by read(). | |
5498 | * (This is a bug on some variants of i386 svr4.0.) | |
5499 | */ | |
5500 | for (i = 0; i < pagesize; ++i) | |
5501 | *(data2 + i) = *(data2 + i) + 1; | |
5502 | data3 = malloc(pagesize); | |
5503 | if (!data3) | |
5504 | exit(1); | |
5505 | if (read(fd, data3, pagesize) != pagesize) | |
5506 | exit(1); | |
5507 | for (i = 0; i < pagesize; ++i) | |
5508 | if (*(data + i) != *(data3 + i)) | |
5509 | exit(1); | |
5510 | close(fd); | |
5511 | unlink("conftestmmap"); | |
5512 | exit(0); | |
5513 | } | |
5514 | ||
5515 | EOF | |
b46cd165 | 5516 | if { (eval echo configure:5517: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
c906108c SS |
5517 | then |
5518 | ac_cv_func_mmap_fixed_mapped=yes | |
5519 | else | |
5520 | echo "configure: failed program was:" >&5 | |
5521 | cat conftest.$ac_ext >&5 | |
5522 | rm -fr conftest* | |
5523 | ac_cv_func_mmap_fixed_mapped=no | |
5524 | fi | |
5525 | rm -fr conftest* | |
5526 | fi | |
5527 | ||
5528 | fi | |
5529 | ||
5530 | echo "$ac_t""$ac_cv_func_mmap_fixed_mapped" 1>&6 | |
5531 | if test $ac_cv_func_mmap_fixed_mapped = yes; then | |
5532 | cat >> confdefs.h <<\EOF | |
5533 | #define HAVE_MMAP 1 | |
5534 | EOF | |
5535 | ||
5536 | fi | |
5537 | ||
5538 | ||
5539 | ||
5540 | ||
5541 | if test ${build} = ${host} -a ${host} = ${target} ; then | |
5542 | case ${host_os} in | |
5543 | hpux*) | |
5544 | echo $ac_n "checking for HPUX/OSF thread support""... $ac_c" 1>&6 | |
b46cd165 | 5545 | echo "configure:5546: checking for HPUX/OSF thread support" >&5 |
c906108c SS |
5546 | if test -f /usr/include/dce/cma_config.h ; then |
5547 | if test "$GCC" = "yes" ; then | |
5548 | echo "$ac_t""yes" 1>&6 | |
5549 | cat >> confdefs.h <<\EOF | |
5550 | #define HAVE_HPUX_THREAD_SUPPORT 1 | |
5551 | EOF | |
5552 | ||
b46cd165 | 5553 | CONFIG_LOBS="${CONFIG_LOBS} hpux-thread.o" |
c906108c SS |
5554 | CONFIG_SRCS="${CONFIG_SRCS} hpux-thread.c" |
5555 | else | |
5556 | echo "$ac_t""no (suppressed because you are not using GCC)" 1>&6 | |
5557 | fi | |
5558 | else | |
5559 | echo "$ac_t""no" 1>&6 | |
5560 | fi | |
5561 | ;; | |
5562 | solaris*) | |
5563 | echo $ac_n "checking for Solaris thread debugging library""... $ac_c" 1>&6 | |
b46cd165 | 5564 | echo "configure:5565: checking for Solaris thread debugging library" >&5 |
c906108c SS |
5565 | if test -f /usr/lib/libthread_db.so.1 ; then |
5566 | echo "$ac_t""yes" 1>&6 | |
5567 | cat >> confdefs.h <<\EOF | |
5568 | #define HAVE_THREAD_DB_LIB 1 | |
5569 | EOF | |
5570 | ||
b46cd165 | 5571 | CONFIG_LOBS="${CONFIG_LOBS} sol-thread.o" |
c906108c SS |
5572 | CONFIG_SRCS="${CONFIG_SRCS} sol-thread.c" |
5573 | echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6 | |
b46cd165 | 5574 | echo "configure:5575: checking for dlopen in -ldl" >&5 |
c906108c SS |
5575 | ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'` |
5576 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then | |
5577 | echo $ac_n "(cached) $ac_c" 1>&6 | |
5578 | else | |
5579 | ac_save_LIBS="$LIBS" | |
5580 | LIBS="-ldl $LIBS" | |
5581 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 5582 | #line 5583 "configure" |
c906108c SS |
5583 | #include "confdefs.h" |
5584 | /* Override any gcc2 internal prototype to avoid an error. */ | |
5585 | /* We use char because int might match the return type of a gcc2 | |
5586 | builtin and then its argument prototype would still apply. */ | |
5587 | char dlopen(); | |
5588 | ||
5589 | int main() { | |
5590 | dlopen() | |
5591 | ; return 0; } | |
5592 | EOF | |
b46cd165 | 5593 | if { (eval echo configure:5594: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
c906108c SS |
5594 | rm -rf conftest* |
5595 | eval "ac_cv_lib_$ac_lib_var=yes" | |
5596 | else | |
5597 | echo "configure: failed program was:" >&5 | |
5598 | cat conftest.$ac_ext >&5 | |
5599 | rm -rf conftest* | |
5600 | eval "ac_cv_lib_$ac_lib_var=no" | |
5601 | fi | |
5602 | rm -f conftest* | |
5603 | LIBS="$ac_save_LIBS" | |
5604 | ||
5605 | fi | |
5606 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then | |
5607 | echo "$ac_t""yes" 1>&6 | |
5608 | ac_tr_lib=HAVE_LIB`echo dl | sed -e 's/[^a-zA-Z0-9_]/_/g' \ | |
5609 | -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` | |
5610 | cat >> confdefs.h <<EOF | |
5611 | #define $ac_tr_lib 1 | |
5612 | EOF | |
5613 | ||
5614 | LIBS="-ldl $LIBS" | |
5615 | ||
5616 | else | |
5617 | echo "$ac_t""no" 1>&6 | |
5618 | fi | |
5619 | ||
5620 | if test "$GCC" = "yes" ; then | |
5621 | # The GNU linker requires the -export-dynamic option to make | |
5622 | # all symbols visible in the dynamic symbol table. | |
5623 | hold_ldflags=$LDFLAGS | |
5624 | echo $ac_n "checking for the ld -export-dynamic flag""... $ac_c" 1>&6 | |
b46cd165 | 5625 | echo "configure:5626: checking for the ld -export-dynamic flag" >&5 |
c906108c SS |
5626 | LDFLAGS="${LDFLAGS} -Wl,-export-dynamic" |
5627 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 5628 | #line 5629 "configure" |
c906108c SS |
5629 | #include "confdefs.h" |
5630 | ||
5631 | int main() { | |
5632 | int i; | |
5633 | ; return 0; } | |
5634 | EOF | |
b46cd165 | 5635 | if { (eval echo configure:5636: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
c906108c SS |
5636 | rm -rf conftest* |
5637 | found=yes | |
5638 | else | |
5639 | echo "configure: failed program was:" >&5 | |
5640 | cat conftest.$ac_ext >&5 | |
5641 | rm -rf conftest* | |
5642 | found=no | |
5643 | fi | |
5644 | rm -f conftest* | |
5645 | LDFLAGS=$hold_ldflags | |
5646 | echo "$ac_t""$found" 1>&6 | |
5647 | if test $found = yes; then | |
5648 | CONFIG_LDFLAGS="${CONFIG_LDFLAGS} -Wl,-export-dynamic" | |
5649 | fi | |
5650 | fi | |
5651 | # Sun randomly tweaked the prototypes in <proc_service.h> | |
5652 | # at one point. | |
5653 | echo $ac_n "checking if <proc_service.h> is old""... $ac_c" 1>&6 | |
b46cd165 | 5654 | echo "configure:5655: checking if <proc_service.h> is old" >&5 |
c906108c SS |
5655 | if eval "test \"`echo '$''{'gdb_cv_proc_service_is_old'+set}'`\" = set"; then |
5656 | echo $ac_n "(cached) $ac_c" 1>&6 | |
5657 | else | |
5658 | ||
5659 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 5660 | #line 5661 "configure" |
c906108c SS |
5661 | #include "confdefs.h" |
5662 | ||
5663 | #include <proc_service.h> | |
5664 | ps_err_e ps_pdwrite | |
5665 | (struct ps_prochandle*, psaddr_t, const void*, size_t); | |
5666 | ||
5667 | int main() { | |
5668 | ||
5669 | ; return 0; } | |
5670 | EOF | |
b46cd165 | 5671 | if { (eval echo configure:5672: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
c906108c SS |
5672 | rm -rf conftest* |
5673 | gdb_cv_proc_service_is_old=no | |
5674 | else | |
5675 | echo "configure: failed program was:" >&5 | |
5676 | cat conftest.$ac_ext >&5 | |
5677 | rm -rf conftest* | |
5678 | gdb_cv_proc_service_is_old=yes | |
5679 | fi | |
5680 | rm -f conftest* | |
5681 | ||
5682 | fi | |
5683 | ||
5684 | echo "$ac_t""$gdb_cv_proc_service_is_old" 1>&6 | |
5685 | if test $gdb_cv_proc_service_is_old = yes; then | |
5686 | cat >> confdefs.h <<\EOF | |
5687 | #define PROC_SERVICE_IS_OLD 1 | |
5688 | EOF | |
5689 | ||
5690 | fi | |
5691 | else | |
5692 | echo "$ac_t""no" 1>&6 | |
5693 | fi | |
5694 | ;; | |
5695 | esac | |
5696 | ||
5697 | fi | |
5698 | ||
fb40c209 | 5699 | |
d318976c FN |
5700 | # Check whether --enable-gdbcli or --disable-gdbcli was given. |
5701 | if test "${enable_gdbcli+set}" = set; then | |
5702 | enableval="$enable_gdbcli" | |
5703 | ||
6bad8db2 FN |
5704 | case "${enableval}" in |
5705 | yes) enable_gdbcli=yes ;; | |
5706 | "") enable_gdbcli=yes ;; | |
d318976c FN |
5707 | no) |
5708 | { echo "configure: error: The CLI cannot be disabled yet" 1>&2; exit 1; } | |
5709 | ;; | |
5710 | *) | |
6bad8db2 | 5711 | { echo "configure: error: Bad value for --enable-gdbcli: ${enableval}" 1>&2; exit 1; } |
d318976c FN |
5712 | ;; |
5713 | esac | |
5714 | ||
5715 | else | |
5716 | enable_gdbcli=yes | |
5717 | fi | |
5718 | ||
5719 | case ${enable_gdbcli} in | |
5720 | "yes" ) | |
6bad8db2 | 5721 | if test -d "${srcdir}/cli" ; then |
d318976c FN |
5722 | CONFIG_OBS="${CONFIG_OBS} \$(SUBDIR_CLI_OBS)" |
5723 | CONFIG_DEPS="${CONFIG_DEPS} \$(SUBDIR_CLI_DEPS)" | |
486697a0 | 5724 | CONFIG_SRCS="${CONFIG_SRCS} \$(SUBDIR_CLI_SRCS)" |
d318976c FN |
5725 | CONFIG_INITS="${CONFIG_INITS} \$(SUBDIR_CLI_INITS)" |
5726 | ENABLE_CFLAGS="${ENABLE_CFLAGS} \$(SUBDIR_CLI_CFLAGS)" | |
5727 | CONFIG_ALL="${CONFIG_ALL} \$(SUBDIR_CLI_ALL)" | |
5728 | CONFIG_CLEAN="${CONFIG_CLEAN} \$(SUBDIR_CLI_CLEAN)" | |
5729 | CONFIG_INSTALL="${CONFIG_INSTALL} \$(SUBDIR_CLI_INSTALL)" | |
5730 | CONFIG_UNINSTALL="${CONFIG_UNINSTALL} \$(SUBDIR_CLI_UNINSTALL)" | |
5731 | fi | |
5732 | ;; | |
5733 | esac | |
5734 | ||
5735 | ||
fb40c209 AC |
5736 | # Check whether --enable-gdbmi or --disable-gdbmi was given. |
5737 | if test "${enable_gdbmi+set}" = set; then | |
5738 | enableval="$enable_gdbmi" | |
5739 | ||
5740 | case "${enable_gdbmi}" in | |
5741 | yes | no) ;; | |
5742 | "") enable_gdbmi=yes ;; | |
5743 | *) | |
5744 | { echo "configure: error: Bad value for --enable-gdbmi: ${enableval}" 1>&2; exit 1; } | |
5745 | ;; | |
5746 | esac | |
5747 | ||
5748 | fi | |
5749 | ||
5750 | case ${enable_gdbmi} in | |
5751 | "yes" ) | |
5752 | if test -d "${srcdir}/mi" ; then | |
5753 | CONFIG_OBS="${CONFIG_OBS} \$(SUBDIR_MI_OBS)" | |
5754 | CONFIG_DEPS="${CONFIG_DEPS} \$(SUBDIR_MI_DEPS)" | |
486697a0 | 5755 | CONFIG_SRCS="${CONFIG_SRCS} \$(SUBDIR_MI_SRCS)" |
fb40c209 | 5756 | CONFIG_INITS="${CONFIG_INITS} \$(SUBDIR_MI_INITS)" |
b0b1b869 | 5757 | ENABLE_CFLAGS="${ENABLE_CFLAGS} \$(SUBDIR_MI_CFLAGS)" |
b3a90332 AC |
5758 | CONFIG_ALL="${CONFIG_ALL} \$(SUBDIR_MI_ALL)" |
5759 | CONFIG_CLEAN="${CONFIG_CLEAN} \$(SUBDIR_MI_CLEAN)" | |
e56ac5c3 AC |
5760 | CONFIG_INSTALL="${CONFIG_INSTALL} \$(SUBDIR_MI_INSTALL)" |
5761 | CONFIG_UNINSTALL="${CONFIG_UNINSTALL} \$(SUBDIR_MI_UNINSTALL)" | |
fb40c209 AC |
5762 | fi |
5763 | ;; | |
5764 | esac | |
c906108c SS |
5765 | |
5766 | # Check whether --enable-tui or --disable-tui was given. | |
5767 | if test "${enable_tui+set}" = set; then | |
5768 | enableval="$enable_tui" | |
5769 | ||
5770 | case "${enable_tui}" in | |
5771 | yes | no) ;; | |
5772 | "") enable_tui=yes ;; | |
5773 | *) | |
5774 | { echo "configure: error: Bad value for --enable-tui: ${enableval}" 1>&2; exit 1; } | |
5775 | ;; | |
5776 | esac | |
5777 | ||
5778 | fi | |
5779 | ||
5780 | case ${enable_tui} in | |
5781 | "yes" ) | |
ed952ac5 AC |
5782 | if test -d "${srcdir}/tui" ; then |
5783 | CONFIG_OBS="${CONFIG_OBS} \$(SUBDIR_TUI_OBS)" | |
5784 | CONFIG_DEPS="${CONFIG_DEPS} \$(SUBDIR_TUI_DEPS)" | |
486697a0 | 5785 | CONFIG_SRCS="${CONFIG_SRCS} \$(SUBDIR_TUI_SRCS)" |
ed952ac5 AC |
5786 | CONFIG_INITS="${CONFIG_INITS} \$(SUBDIR_TUI_INITS)" |
5787 | ENABLE_CFLAGS="${ENABLE_CFLAGS} \$(SUBDIR_TUI_CFLAGS)" | |
5788 | CONFIG_ALL="${CONFIG_ALL} \$(SUBDIR_TUI_ALL)" | |
5789 | CONFIG_CLEAN="${CONFIG_CLEAN} \$(SUBDIR_TUI_CLEAN)" | |
5790 | CONFIG_INSTALL="${CONFIG_INSTALL} \$(SUBDIR_TUI_INSTALL)" | |
5791 | CONFIG_UNINSTALL="${CONFIG_UNINSTALL} \$(SUBDIR_TUI_UNINSTALL)" | |
5792 | fi | |
5793 | ;; | |
c906108c SS |
5794 | esac |
5795 | ||
c906108c SS |
5796 | # Check whether --enable-netrom or --disable-netrom was given. |
5797 | if test "${enable_netrom+set}" = set; then | |
5798 | enableval="$enable_netrom" | |
5799 | case "${enableval}" in | |
5800 | yes) enable_netrom=yes ;; | |
5801 | no) enable_netrom=no ;; | |
5802 | *) { echo "configure: error: bad value ${enableval} given for netrom option" 1>&2; exit 1; } ;; | |
5803 | esac | |
5804 | fi | |
5805 | ||
5806 | ||
5807 | if test "${enable_netrom}" = "yes"; then | |
b46cd165 | 5808 | CONFIG_LOBS="${CONFIG_LOBS} remote-nrom.o" |
c906108c SS |
5809 | CONFIG_SRCS="${CONFIG_SRCS} remote-nrom.c" |
5810 | fi | |
5811 | ||
1decb323 | 5812 | |
3b851bce AC |
5813 | # NOTE: Don't add -Wall or -Wunused, they both include |
5814 | # -Wunused-parameter which reports bogus warnings. | |
5815 | # NOTE: If you add to this list, remember to update | |
5816 | # gdb/doc/gdbint.texinfo. | |
1decb323 | 5817 | build_warnings="-Wimplicit -Wreturn-type -Wcomment -Wtrigraphs \ |
16cadf39 | 5818 | -Wformat -Wparentheses -Wpointer-arith -Wuninitialized" |
d8038014 AC |
5819 | # Up for debate: -Wswitch -Wcomment -trigraphs -Wtrigraphs |
5820 | # -Wunused-function -Wunused-label -Wunused-variable -Wunused-value | |
5821 | # -Wchar-subscripts -Wuninitialized -Wtraditional -Wshadow -Wcast-qual | |
5822 | # -Wcast-align -Wwrite-strings -Wconversion -Wstrict-prototypes | |
5823 | # -Wmissing-prototypes -Wmissing-declarations -Wredundant-decls | |
5824 | # -Woverloaded-virtual -Winline -Werror" | |
c906108c SS |
5825 | # Check whether --enable-build-warnings or --disable-build-warnings was given. |
5826 | if test "${enable_build_warnings+set}" = set; then | |
5827 | enableval="$enable_build_warnings" | |
1decb323 | 5828 | case "${enableval}" in |
c906108c SS |
5829 | yes) ;; |
5830 | no) build_warnings="-w";; | |
5831 | ,*) t=`echo "${enableval}" | sed -e "s/,/ /g"` | |
5832 | build_warnings="${build_warnings} ${t}";; | |
5833 | *,) t=`echo "${enableval}" | sed -e "s/,/ /g"` | |
5834 | build_warnings="${t} ${build_warnings}";; | |
5835 | *) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;; | |
5836 | esac | |
d4f3574e | 5837 | if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then |
746a987d | 5838 | echo "Setting compiler warning flags = $build_warnings" 6>&1 |
c906108c | 5839 | fi |
1decb323 | 5840 | fi |
3b851bce AC |
5841 | # Check whether --enable-gdb-build-warnings or --disable-gdb-build-warnings was given. |
5842 | if test "${enable_gdb_build_warnings+set}" = set; then | |
5843 | enableval="$enable_gdb_build_warnings" | |
5844 | case "${enableval}" in | |
5845 | yes) ;; | |
5846 | no) build_warnings="-w";; | |
5847 | ,*) t=`echo "${enableval}" | sed -e "s/,/ /g"` | |
5848 | build_warnings="${build_warnings} ${t}";; | |
5849 | *,) t=`echo "${enableval}" | sed -e "s/,/ /g"` | |
5850 | build_warnings="${t} ${build_warnings}";; | |
5851 | *) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;; | |
5852 | esac | |
5853 | if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then | |
5854 | echo "Setting GDB specific compiler warning flags = $build_warnings" 6>&1 | |
5855 | fi | |
5856 | fi | |
104c1213 JM |
5857 | WARN_CFLAGS="" |
5858 | WERROR_CFLAGS="" | |
c906108c SS |
5859 | if test "x${build_warnings}" != x -a "x$GCC" = xyes |
5860 | then | |
746a987d | 5861 | echo $ac_n "checking compiler warning flags""... $ac_c" 1>&6 |
b46cd165 | 5862 | echo "configure:5863: checking compiler warning flags" >&5 |
746a987d AC |
5863 | # Separate out the -Werror flag as some files just cannot be |
5864 | # compiled with it enabled. | |
5865 | for w in ${build_warnings}; do | |
5866 | case $w in | |
5867 | -Werr*) WERROR_CFLAGS=-Werror ;; | |
5868 | *) # Check that GCC accepts it | |
5869 | if $CC $w 2>&1 | grep 'unrecognized option' > /dev/null; then | |
5870 | : | |
5871 | else | |
5872 | WARN_CFLAGS="${WARN_CFLAGS} $w" | |
5873 | fi | |
5874 | esac | |
5875 | done | |
5876 | echo "$ac_t""${WARN_CFLAGS}${WERROR_CFLAGS}" 1>&6 | |
c906108c SS |
5877 | fi |
5878 | ||
5879 | ||
104c1213 | 5880 | |
c906108c SS |
5881 | MMALLOC_CFLAGS= |
5882 | MMALLOC= | |
5883 | ||
5884 | ||
5885 | ||
5886 | # Check whether --with-mmalloc or --without-mmalloc was given. | |
5887 | if test "${with_mmalloc+set}" = set; then | |
5888 | withval="$with_mmalloc" | |
5889 | case "${withval}" in | |
5890 | yes) want_mmalloc=true ;; | |
5891 | no) want_mmalloc=false;; | |
5892 | *) { echo "configure: error: bad value ${withval} for GDB with-mmalloc option" 1>&2; exit 1; } ;; | |
5893 | esac | |
5894 | else | |
5895 | want_mmalloc=false | |
5896 | fi | |
5897 | ||
5898 | if test x$want_mmalloc = xtrue; then | |
5899 | cat >> confdefs.h <<\EOF | |
5900 | #define USE_MMALLOC 1 | |
5901 | EOF | |
5902 | ||
5903 | cat >> confdefs.h <<\EOF | |
5904 | #define MMCHECK_FORCE 1 | |
5905 | EOF | |
5906 | ||
5907 | MMALLOC_CFLAGS="-I$srcdir/../mmalloc" | |
5908 | MMALLOC='../mmalloc/libmmalloc.a' | |
5909 | fi | |
5910 | ||
88987551 L |
5911 | # Check whether --with-included-regex or --without-included-regex was given. |
5912 | if test "${with_included_regex+set}" = set; then | |
5913 | withval="$with_included_regex" | |
5914 | case "${withval}" in | |
5915 | yes) want_included_regex=true ;; | |
5916 | no) want_included_regex=false;; | |
5917 | *) { echo "configure: error: bad value ${withval} for GDB with-included-regex option" 1>&2; exit 1; } ;; | |
5918 | esac | |
5919 | else | |
5920 | want_included_regex=true | |
5921 | fi | |
5922 | ||
88987551 L |
5923 | if test $want_included_regex = false; then |
5924 | echo $ac_n "checking for GNU regex""... $ac_c" 1>&6 | |
b46cd165 | 5925 | echo "configure:5926: checking for GNU regex" >&5 |
88987551 L |
5926 | if eval "test \"`echo '$''{'gdb_cv_have_gnu_regex'+set}'`\" = set"; then |
5927 | echo $ac_n "(cached) $ac_c" 1>&6 | |
5928 | else | |
5929 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 5930 | #line 5931 "configure" |
88987551 L |
5931 | #include "confdefs.h" |
5932 | #include <gnu-versions.h> | |
5933 | #include <sys/types.h> | |
5934 | #include <regex.h> | |
5935 | int main() { | |
5936 | #if !defined _GNU_REGEX_INTERFACE_VERSION || !defined __GLIBC__ || __GLIBC__ < 2 | |
5937 | #error No valid GNU regex. | |
5938 | #endif | |
5939 | ||
5940 | ; return 0; } | |
5941 | EOF | |
b46cd165 | 5942 | if { (eval echo configure:5943: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
88987551 L |
5943 | rm -rf conftest* |
5944 | gdb_cv_have_gnu_regex=yes | |
5945 | else | |
5946 | echo "configure: failed program was:" >&5 | |
5947 | cat conftest.$ac_ext >&5 | |
5948 | rm -rf conftest* | |
5949 | gdb_cv_have_gnu_regex=no | |
5950 | fi | |
5951 | rm -f conftest* | |
5952 | fi | |
5953 | ||
5954 | echo "$ac_t""$gdb_cv_have_gnu_regex" 1>&6 | |
e48f66e4 AC |
5955 | if test $gdb_cv_have_gnu_regex = no; then |
5956 | want_included_regex=true | |
88987551 L |
5957 | fi |
5958 | fi | |
5959 | ||
e48f66e4 AC |
5960 | if test x${want_included_regex} = xtrue; then |
5961 | REGEX="gnu-regex.o" | |
5962 | cat >> confdefs.h <<\EOF | |
5963 | #define USE_INCLUDED_REGEX 1 | |
5964 | EOF | |
5965 | ||
5966 | fi | |
88987551 | 5967 | |
7a292a7a SS |
5968 | |
5969 | # In the Cygwin environment, we need some additional flags. | |
5970 | echo $ac_n "checking for cygwin""... $ac_c" 1>&6 | |
b46cd165 | 5971 | echo "configure:5972: checking for cygwin" >&5 |
7a292a7a SS |
5972 | if eval "test \"`echo '$''{'gdb_cv_os_cygwin'+set}'`\" = set"; then |
5973 | echo $ac_n "(cached) $ac_c" 1>&6 | |
5974 | else | |
5975 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 5976 | #line 5977 "configure" |
7a292a7a SS |
5977 | #include "confdefs.h" |
5978 | ||
5979 | #if defined (__CYGWIN__) || defined (__CYGWIN32__) | |
5980 | lose | |
5981 | #endif | |
5982 | EOF | |
5983 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
5984 | egrep "lose" >/dev/null 2>&1; then | |
5985 | rm -rf conftest* | |
5986 | gdb_cv_os_cygwin=yes | |
5987 | else | |
5988 | rm -rf conftest* | |
5989 | gdb_cv_os_cygwin=no | |
5990 | fi | |
5991 | rm -f conftest* | |
5992 | ||
5993 | fi | |
5994 | ||
5995 | echo "$ac_t""$gdb_cv_os_cygwin" 1>&6 | |
5996 | ||
aff38e61 AC |
5997 | |
5998 | SER_HARDWIRE="ser-unix.o ser-pipe.o ser-tcp.o" | |
5999 | case ${host} in | |
95cbc983 AC |
6000 | *go32* ) SER_HARDWIRE=ser-go32.o ;; |
6001 | *djgpp* ) SER_HARDWIRE=ser-go32.o ;; | |
aff38e61 AC |
6002 | esac |
6003 | ||
6004 | ||
6005 | ||
b83266a0 SS |
6006 | if test x$gdb_host = xgo32; then |
6007 | TERM_LIB= | |
6008 | else | |
c906108c SS |
6009 | if test x$gdb_cv_os_cygwin = xyes; then |
6010 | TERM_LIB='`if test -r ../libtermcap/libtermcap.a; then echo ../libtermcap/libtermcap.a; else echo -ltermcap; fi`' | |
6011 | else | |
6012 | TERM_LIB= | |
6013 | echo $ac_n "checking for tgetent in -lncurses""... $ac_c" 1>&6 | |
b46cd165 | 6014 | echo "configure:6015: checking for tgetent in -lncurses" >&5 |
c906108c SS |
6015 | ac_lib_var=`echo ncurses'_'tgetent | sed 'y%./+-%__p_%'` |
6016 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then | |
6017 | echo $ac_n "(cached) $ac_c" 1>&6 | |
6018 | else | |
6019 | ac_save_LIBS="$LIBS" | |
6020 | LIBS="-lncurses $LIBS" | |
6021 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 6022 | #line 6023 "configure" |
c906108c SS |
6023 | #include "confdefs.h" |
6024 | /* Override any gcc2 internal prototype to avoid an error. */ | |
6025 | /* We use char because int might match the return type of a gcc2 | |
6026 | builtin and then its argument prototype would still apply. */ | |
6027 | char tgetent(); | |
6028 | ||
6029 | int main() { | |
6030 | tgetent() | |
6031 | ; return 0; } | |
6032 | EOF | |
b46cd165 | 6033 | if { (eval echo configure:6034: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
c906108c SS |
6034 | rm -rf conftest* |
6035 | eval "ac_cv_lib_$ac_lib_var=yes" | |
6036 | else | |
6037 | echo "configure: failed program was:" >&5 | |
6038 | cat conftest.$ac_ext >&5 | |
6039 | rm -rf conftest* | |
6040 | eval "ac_cv_lib_$ac_lib_var=no" | |
6041 | fi | |
6042 | rm -f conftest* | |
6043 | LIBS="$ac_save_LIBS" | |
6044 | ||
6045 | fi | |
6046 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then | |
6047 | echo "$ac_t""yes" 1>&6 | |
6048 | TERM_LIB=-lncurses | |
6049 | else | |
6050 | echo "$ac_t""no" 1>&6 | |
6051 | echo $ac_n "checking for tgetent in -lHcurses""... $ac_c" 1>&6 | |
b46cd165 | 6052 | echo "configure:6053: checking for tgetent in -lHcurses" >&5 |
c906108c SS |
6053 | ac_lib_var=`echo Hcurses'_'tgetent | sed 'y%./+-%__p_%'` |
6054 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then | |
6055 | echo $ac_n "(cached) $ac_c" 1>&6 | |
6056 | else | |
6057 | ac_save_LIBS="$LIBS" | |
6058 | LIBS="-lHcurses $LIBS" | |
6059 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 6060 | #line 6061 "configure" |
c906108c SS |
6061 | #include "confdefs.h" |
6062 | /* Override any gcc2 internal prototype to avoid an error. */ | |
6063 | /* We use char because int might match the return type of a gcc2 | |
6064 | builtin and then its argument prototype would still apply. */ | |
6065 | char tgetent(); | |
6066 | ||
6067 | int main() { | |
6068 | tgetent() | |
6069 | ; return 0; } | |
6070 | EOF | |
b46cd165 | 6071 | if { (eval echo configure:6072: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
c906108c SS |
6072 | rm -rf conftest* |
6073 | eval "ac_cv_lib_$ac_lib_var=yes" | |
6074 | else | |
6075 | echo "configure: failed program was:" >&5 | |
6076 | cat conftest.$ac_ext >&5 | |
6077 | rm -rf conftest* | |
6078 | eval "ac_cv_lib_$ac_lib_var=no" | |
6079 | fi | |
6080 | rm -f conftest* | |
6081 | LIBS="$ac_save_LIBS" | |
6082 | ||
6083 | fi | |
6084 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then | |
6085 | echo "$ac_t""yes" 1>&6 | |
6086 | TERM_LIB=-lHcurses | |
6087 | else | |
6088 | echo "$ac_t""no" 1>&6 | |
6089 | echo $ac_n "checking for tgetent in -ltermlib""... $ac_c" 1>&6 | |
b46cd165 | 6090 | echo "configure:6091: checking for tgetent in -ltermlib" >&5 |
c906108c SS |
6091 | ac_lib_var=`echo termlib'_'tgetent | sed 'y%./+-%__p_%'` |
6092 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then | |
6093 | echo $ac_n "(cached) $ac_c" 1>&6 | |
6094 | else | |
6095 | ac_save_LIBS="$LIBS" | |
6096 | LIBS="-ltermlib $LIBS" | |
6097 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 6098 | #line 6099 "configure" |
c906108c SS |
6099 | #include "confdefs.h" |
6100 | /* Override any gcc2 internal prototype to avoid an error. */ | |
6101 | /* We use char because int might match the return type of a gcc2 | |
6102 | builtin and then its argument prototype would still apply. */ | |
6103 | char tgetent(); | |
6104 | ||
6105 | int main() { | |
6106 | tgetent() | |
6107 | ; return 0; } | |
6108 | EOF | |
b46cd165 | 6109 | if { (eval echo configure:6110: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
c906108c SS |
6110 | rm -rf conftest* |
6111 | eval "ac_cv_lib_$ac_lib_var=yes" | |
6112 | else | |
6113 | echo "configure: failed program was:" >&5 | |
6114 | cat conftest.$ac_ext >&5 | |
6115 | rm -rf conftest* | |
6116 | eval "ac_cv_lib_$ac_lib_var=no" | |
6117 | fi | |
6118 | rm -f conftest* | |
6119 | LIBS="$ac_save_LIBS" | |
6120 | ||
6121 | fi | |
6122 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then | |
6123 | echo "$ac_t""yes" 1>&6 | |
6124 | TERM_LIB=-ltermlib | |
6125 | else | |
6126 | echo "$ac_t""no" 1>&6 | |
6127 | echo $ac_n "checking for tgetent in -ltermcap""... $ac_c" 1>&6 | |
b46cd165 | 6128 | echo "configure:6129: checking for tgetent in -ltermcap" >&5 |
c906108c SS |
6129 | ac_lib_var=`echo termcap'_'tgetent | sed 'y%./+-%__p_%'` |
6130 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then | |
6131 | echo $ac_n "(cached) $ac_c" 1>&6 | |
6132 | else | |
6133 | ac_save_LIBS="$LIBS" | |
6134 | LIBS="-ltermcap $LIBS" | |
6135 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 6136 | #line 6137 "configure" |
c906108c SS |
6137 | #include "confdefs.h" |
6138 | /* Override any gcc2 internal prototype to avoid an error. */ | |
6139 | /* We use char because int might match the return type of a gcc2 | |
6140 | builtin and then its argument prototype would still apply. */ | |
6141 | char tgetent(); | |
6142 | ||
6143 | int main() { | |
6144 | tgetent() | |
6145 | ; return 0; } | |
6146 | EOF | |
b46cd165 | 6147 | if { (eval echo configure:6148: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
c906108c SS |
6148 | rm -rf conftest* |
6149 | eval "ac_cv_lib_$ac_lib_var=yes" | |
6150 | else | |
6151 | echo "configure: failed program was:" >&5 | |
6152 | cat conftest.$ac_ext >&5 | |
6153 | rm -rf conftest* | |
6154 | eval "ac_cv_lib_$ac_lib_var=no" | |
6155 | fi | |
6156 | rm -f conftest* | |
6157 | LIBS="$ac_save_LIBS" | |
6158 | ||
6159 | fi | |
6160 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then | |
6161 | echo "$ac_t""yes" 1>&6 | |
6162 | TERM_LIB=-ltermcap | |
6163 | else | |
6164 | echo "$ac_t""no" 1>&6 | |
6165 | echo $ac_n "checking for tgetent in -lcurses""... $ac_c" 1>&6 | |
b46cd165 | 6166 | echo "configure:6167: checking for tgetent in -lcurses" >&5 |
c906108c SS |
6167 | ac_lib_var=`echo curses'_'tgetent | sed 'y%./+-%__p_%'` |
6168 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then | |
6169 | echo $ac_n "(cached) $ac_c" 1>&6 | |
6170 | else | |
6171 | ac_save_LIBS="$LIBS" | |
6172 | LIBS="-lcurses $LIBS" | |
6173 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 6174 | #line 6175 "configure" |
c906108c SS |
6175 | #include "confdefs.h" |
6176 | /* Override any gcc2 internal prototype to avoid an error. */ | |
6177 | /* We use char because int might match the return type of a gcc2 | |
6178 | builtin and then its argument prototype would still apply. */ | |
6179 | char tgetent(); | |
6180 | ||
6181 | int main() { | |
6182 | tgetent() | |
6183 | ; return 0; } | |
6184 | EOF | |
b46cd165 | 6185 | if { (eval echo configure:6186: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
c906108c SS |
6186 | rm -rf conftest* |
6187 | eval "ac_cv_lib_$ac_lib_var=yes" | |
6188 | else | |
6189 | echo "configure: failed program was:" >&5 | |
6190 | cat conftest.$ac_ext >&5 | |
6191 | rm -rf conftest* | |
6192 | eval "ac_cv_lib_$ac_lib_var=no" | |
6193 | fi | |
6194 | rm -f conftest* | |
6195 | LIBS="$ac_save_LIBS" | |
6196 | ||
6197 | fi | |
6198 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then | |
6199 | echo "$ac_t""yes" 1>&6 | |
6200 | TERM_LIB=-lcurses | |
6201 | else | |
6202 | echo "$ac_t""no" 1>&6 | |
6203 | echo $ac_n "checking for tgetent in -lterminfo""... $ac_c" 1>&6 | |
b46cd165 | 6204 | echo "configure:6205: checking for tgetent in -lterminfo" >&5 |
c906108c SS |
6205 | ac_lib_var=`echo terminfo'_'tgetent | sed 'y%./+-%__p_%'` |
6206 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then | |
6207 | echo $ac_n "(cached) $ac_c" 1>&6 | |
6208 | else | |
6209 | ac_save_LIBS="$LIBS" | |
6210 | LIBS="-lterminfo $LIBS" | |
6211 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 6212 | #line 6213 "configure" |
c906108c SS |
6213 | #include "confdefs.h" |
6214 | /* Override any gcc2 internal prototype to avoid an error. */ | |
6215 | /* We use char because int might match the return type of a gcc2 | |
6216 | builtin and then its argument prototype would still apply. */ | |
6217 | char tgetent(); | |
6218 | ||
6219 | int main() { | |
6220 | tgetent() | |
6221 | ; return 0; } | |
6222 | EOF | |
b46cd165 | 6223 | if { (eval echo configure:6224: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
c906108c SS |
6224 | rm -rf conftest* |
6225 | eval "ac_cv_lib_$ac_lib_var=yes" | |
6226 | else | |
6227 | echo "configure: failed program was:" >&5 | |
6228 | cat conftest.$ac_ext >&5 | |
6229 | rm -rf conftest* | |
6230 | eval "ac_cv_lib_$ac_lib_var=no" | |
6231 | fi | |
6232 | rm -f conftest* | |
6233 | LIBS="$ac_save_LIBS" | |
6234 | ||
6235 | fi | |
6236 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then | |
6237 | echo "$ac_t""yes" 1>&6 | |
6238 | TERM_LIB=-lterminfo | |
6239 | else | |
6240 | echo "$ac_t""no" 1>&6 | |
6241 | fi | |
6242 | ||
6243 | fi | |
6244 | ||
6245 | fi | |
6246 | ||
6247 | fi | |
6248 | ||
6249 | fi | |
6250 | ||
6251 | fi | |
6252 | ||
6253 | ||
6254 | if test "x$TERM_LIB" = x | |
6255 | then | |
6256 | { echo "configure: error: Could not find a term library" 1>&2; exit 1; } | |
6257 | fi | |
6258 | fi | |
b83266a0 | 6259 | fi |
c906108c SS |
6260 | |
6261 | ||
cd0fc7c3 SS |
6262 | # libreadline needs libuser32.a in a cygwin environment |
6263 | WIN32LIBS= | |
6264 | if test x$gdb_cv_os_cygwin = xyes; then | |
c5394b80 JM |
6265 | WIN32LIBS="-luser32" |
6266 | case "${target}" in | |
6267 | *cygwin*) WIN32LIBS="$WIN32LIBS -limagehlp" | |
6268 | ;; | |
6269 | esac | |
cd0fc7c3 | 6270 | fi |
c906108c | 6271 | |
7a292a7a | 6272 | |
3fc11d3e JM |
6273 | LIBGUI="../libgui/src/libgui.a" |
6274 | GUI_CFLAGS_X="-I${srcdir}/../libgui/src" | |
6275 | ||
6276 | ||
7a292a7a | 6277 | |
8b93c638 JM |
6278 | # Check whether --with-cpu or --without-cpu was given. |
6279 | if test "${with_cpu+set}" = set; then | |
6280 | withval="$with_cpu" | |
6281 | case "${target}" in | |
6282 | powerpc-* | powerpcle-* ) | |
6283 | ## It would be nice to keep this table in sync with the one in | |
6284 | ## gcc/configure. | |
6285 | case "${with_cpu}" in | |
6286 | ppc-uisa | rs6000 | 403 | 403GC | 505 | 860 | 601 | 602 | 603 \ | |
6287 | | 604 | 750 ) | |
6288 | ## Those are all handled in variants in rs6000-tdep.c, so they're fine. | |
6289 | ;; | |
6290 | common | power | power2 | rios | rios1 | rios2 | rsc | rsc1 ) | |
6291 | ## These are all RS6000 variants, as far as GDB is concerned. | |
6292 | with_cpu=rs6000 | |
6293 | ;; | |
6294 | 603e | ec603e ) | |
6295 | with_cpu=603 | |
6296 | ;; | |
6297 | 604e ) | |
6298 | with_cpu=604 | |
6299 | ;; | |
6300 | * ) | |
6301 | echo "configure: warning: GDB: unknown --with-cpu value: \`${with_cpu}'; using \`ppc-uisa'." 1>&2 | |
6302 | with_cpu=ppc-uisa | |
6303 | ;; | |
6304 | esac | |
6305 | ;; | |
6306 | * ) | |
6307 | echo "configure: warning: GDB may ignore the --with-cpu flag for ${target} targets" 1>&2 | |
6308 | ;; | |
6309 | esac | |
6310 | cat >> confdefs.h <<EOF | |
6311 | #define TARGET_CPU_DEFAULT "${with_cpu}" | |
6312 | EOF | |
6313 | ||
6314 | ||
6315 | fi | |
6316 | ||
6317 | ||
6318 | ||
3fc11d3e JM |
6319 | # Check whether --enable-gdbtk or --disable-gdbtk was given. |
6320 | if test "${enable_gdbtk+set}" = set; then | |
6321 | enableval="$enable_gdbtk" | |
6322 | case "${enableval}" in | |
6323 | yes) | |
6324 | case "$host" in | |
6325 | *go32*) | |
6326 | echo "configure: warning: GDB does not support GDBtk on host ${host}. GDBtk will be disabled." 1>&2 | |
6327 | enable_gdbtk=no ;; | |
6328 | *windows*) | |
6329 | echo "configure: warning: GDB does not support GDBtk on host ${host}. GDBtk will be disabled." 1>&2 | |
6330 | enable_gdbtk=no ;; | |
6331 | *) | |
6332 | enable_gdbtk=yes ;; | |
6333 | esac ;; | |
6334 | no) | |
6335 | enable_gdbtk=no ;; | |
6336 | *) | |
6337 | { echo "configure: error: bad value ${enableval} given for gdbtk option" 1>&2; exit 1; } ;; | |
6338 | esac | |
6339 | else | |
6340 | ||
6341 | # Default is on for everything but go32 and Cygwin | |
6342 | case "$host" in | |
6343 | *go32* | *windows*) | |
6344 | ;; | |
6345 | *) | |
379d6434 AC |
6346 | if test -d "${srcdir}/gdbtk" ; then |
6347 | enable_gdbtk=yes | |
6348 | fi | |
6349 | ;; | |
6350 | esac | |
3fc11d3e JM |
6351 | |
6352 | fi | |
6353 | ||
6354 | ||
6355 | WIN32LDAPP= | |
6356 | ||
6357 | ||
6358 | ||
6359 | configdir="unix" | |
6360 | ||
6361 | GDBTKLIBS= | |
6362 | if test "${enable_gdbtk}" = "yes"; then | |
6363 | ||
6364 | ||
6365 | # | |
6366 | # Ok, lets find the tcl configuration | |
6367 | # First, look for one uninstalled. | |
6368 | # the alternative search directory is invoked by --with-tclconfig | |
6369 | # | |
6370 | ||
6371 | if test x"${no_tcl}" = x ; then | |
6372 | # we reset no_tcl in case something fails here | |
6373 | no_tcl=true | |
6374 | # Check whether --with-tclconfig or --without-tclconfig was given. | |
6375 | if test "${with_tclconfig+set}" = set; then | |
6376 | withval="$with_tclconfig" | |
6377 | with_tclconfig=${withval} | |
6378 | fi | |
6379 | ||
6380 | echo $ac_n "checking for Tcl configuration""... $ac_c" 1>&6 | |
b46cd165 | 6381 | echo "configure:6382: checking for Tcl configuration" >&5 |
3fc11d3e JM |
6382 | if eval "test \"`echo '$''{'ac_cv_c_tclconfig'+set}'`\" = set"; then |
6383 | echo $ac_n "(cached) $ac_c" 1>&6 | |
6384 | else | |
6385 | ||
6386 | ||
6387 | # First check to see if --with-tclconfig was specified. | |
6388 | if test x"${with_tclconfig}" != x ; then | |
6389 | if test -f "${with_tclconfig}/tclConfig.sh" ; then | |
6390 | ac_cv_c_tclconfig=`(cd ${with_tclconfig}; pwd)` | |
6391 | else | |
6392 | { echo "configure: error: ${with_tclconfig} directory doesn't contain tclConfig.sh" 1>&2; exit 1; } | |
6393 | fi | |
6394 | fi | |
6395 | ||
6396 | # then check for a private Tcl installation | |
6397 | if test x"${ac_cv_c_tclconfig}" = x ; then | |
6398 | for i in \ | |
6399 | ../tcl \ | |
6400 | `ls -dr ../tcl[7-9]* 2>/dev/null` \ | |
6401 | ../../tcl \ | |
6402 | `ls -dr ../../tcl[7-9]* 2>/dev/null` \ | |
6403 | ../../../tcl \ | |
6404 | `ls -dr ../../../tcl[7-9]* 2>/dev/null` ; do | |
6405 | if test -f "$i/${configdir}/tclConfig.sh" ; then | |
6406 | ac_cv_c_tclconfig=`(cd $i/${configdir}; pwd)` | |
6407 | break | |
6408 | fi | |
6409 | done | |
6410 | fi | |
6411 | # check in a few common install locations | |
6412 | if test x"${ac_cv_c_tclconfig}" = x ; then | |
6413 | for i in `ls -d ${prefix}/lib /usr/local/lib 2>/dev/null` ; do | |
6414 | if test -f "$i/tclConfig.sh" ; then | |
6415 | ac_cv_c_tclconfig=`(cd $i; pwd)` | |
6416 | break | |
6417 | fi | |
6418 | done | |
6419 | fi | |
6420 | # check in a few other private locations | |
6421 | if test x"${ac_cv_c_tclconfig}" = x ; then | |
6422 | for i in \ | |
6423 | ${srcdir}/../tcl \ | |
6424 | `ls -dr ${srcdir}/../tcl[7-9]* 2>/dev/null` ; do | |
6425 | if test -f "$i/${configdir}/tclConfig.sh" ; then | |
6426 | ac_cv_c_tclconfig=`(cd $i/${configdir}; pwd)` | |
6427 | break | |
6428 | fi | |
6429 | done | |
6430 | fi | |
6431 | ||
6432 | fi | |
6433 | ||
6434 | if test x"${ac_cv_c_tclconfig}" = x ; then | |
6435 | TCLCONFIG="# no Tcl configs found" | |
6436 | echo "configure: warning: Can't find Tcl configuration definitions" 1>&2 | |
6437 | else | |
6438 | no_tcl= | |
6439 | TCLCONFIG=${ac_cv_c_tclconfig}/tclConfig.sh | |
6440 | echo "$ac_t""found $TCLCONFIG" 1>&6 | |
6441 | fi | |
6442 | fi | |
6443 | ||
6444 | if test -z "${no_tcl}"; then | |
6445 | ||
6446 | . $TCLCONFIG | |
6447 | ||
6448 | ||
6449 | ||
6450 | ||
6451 | ||
6452 | ||
6453 | ||
6454 | ||
6455 | ||
6456 | ||
6457 | ||
6458 | ||
6459 | ||
6460 | ||
6461 | ||
6462 | ||
6463 | ||
6464 | ||
6465 | ||
6466 | ||
6467 | ||
6468 | ||
6469 | ||
6470 | ||
6471 | ||
6472 | ||
6473 | # | |
6474 | # Ok, lets find the tk configuration | |
6475 | # First, look for one uninstalled. | |
6476 | # the alternative search directory is invoked by --with-tkconfig | |
6477 | # | |
6478 | ||
6479 | if test x"${no_tk}" = x ; then | |
6480 | # we reset no_tk in case something fails here | |
6481 | no_tk=true | |
6482 | # Check whether --with-tkconfig or --without-tkconfig was given. | |
6483 | if test "${with_tkconfig+set}" = set; then | |
6484 | withval="$with_tkconfig" | |
6485 | with_tkconfig=${withval} | |
6486 | fi | |
6487 | ||
6488 | echo $ac_n "checking for Tk configuration""... $ac_c" 1>&6 | |
b46cd165 | 6489 | echo "configure:6490: checking for Tk configuration" >&5 |
3fc11d3e JM |
6490 | if eval "test \"`echo '$''{'ac_cv_c_tkconfig'+set}'`\" = set"; then |
6491 | echo $ac_n "(cached) $ac_c" 1>&6 | |
6492 | else | |
6493 | ||
6494 | ||
6495 | # First check to see if --with-tkconfig was specified. | |
6496 | if test x"${with_tkconfig}" != x ; then | |
6497 | if test -f "${with_tkconfig}/tkConfig.sh" ; then | |
6498 | ac_cv_c_tkconfig=`(cd ${with_tkconfig}; pwd)` | |
6499 | else | |
6500 | { echo "configure: error: ${with_tkconfig} directory doesn't contain tkConfig.sh" 1>&2; exit 1; } | |
6501 | fi | |
6502 | fi | |
6503 | ||
6504 | # then check for a private Tk library | |
6505 | if test x"${ac_cv_c_tkconfig}" = x ; then | |
6506 | for i in \ | |
6507 | ../tk \ | |
6508 | `ls -dr ../tk[4-9]* 2>/dev/null` \ | |
6509 | ../../tk \ | |
6510 | `ls -dr ../../tk[4-9]* 2>/dev/null` \ | |
6511 | ../../../tk \ | |
6512 | `ls -dr ../../../tk[4-9]* 2>/dev/null` ; do | |
6513 | if test -f "$i/${configdir}/tkConfig.sh" ; then | |
6514 | ac_cv_c_tkconfig=`(cd $i/${configdir}; pwd)` | |
6515 | break | |
6516 | fi | |
6517 | done | |
6518 | fi | |
6519 | # check in a few common install locations | |
6520 | if test x"${ac_cv_c_tkconfig}" = x ; then | |
6521 | for i in `ls -d ${prefix}/lib /usr/local/lib 2>/dev/null` ; do | |
6522 | if test -f "$i/tkConfig.sh" ; then | |
6523 | ac_cv_c_tkconfig=`(cd $i; pwd)` | |
6524 | break | |
6525 | fi | |
6526 | done | |
6527 | fi | |
6528 | # check in a few other private locations | |
6529 | if test x"${ac_cv_c_tkconfig}" = x ; then | |
6530 | for i in \ | |
6531 | ${srcdir}/../tk \ | |
6532 | `ls -dr ${srcdir}/../tk[4-9]* 2>/dev/null` ; do | |
6533 | if test -f "$i/${configdir}/tkConfig.sh" ; then | |
6534 | ac_cv_c_tkconfig=`(cd $i/${configdir}; pwd)` | |
6535 | break | |
6536 | fi | |
6537 | done | |
6538 | fi | |
6539 | ||
6540 | fi | |
6541 | ||
6542 | if test x"${ac_cv_c_tkconfig}" = x ; then | |
6543 | TKCONFIG="# no Tk configs found" | |
6544 | echo "configure: warning: Can't find Tk configuration definitions" 1>&2 | |
6545 | else | |
6546 | no_tk= | |
6547 | TKCONFIG=${ac_cv_c_tkconfig}/tkConfig.sh | |
6548 | echo "$ac_t""found $TKCONFIG" 1>&6 | |
6549 | fi | |
6550 | fi | |
6551 | ||
6552 | ||
6553 | ||
6554 | # If $no_tk is nonempty, then we can't do Tk, and there is no | |
6555 | # point to doing Tcl. | |
6556 | if test -z "${no_tk}"; then | |
6557 | ||
6558 | if test -f "$TKCONFIG" ; then | |
6559 | . $TKCONFIG | |
6560 | fi | |
6561 | ||
6562 | ||
6563 | ||
6564 | ||
6565 | ||
6566 | ||
6567 | ||
6568 | ||
6569 | ||
6570 | ||
6571 | ||
6572 | ||
6573 | ||
6574 | ||
6575 | # | |
6576 | # Ok, lets find the tcl source trees so we can use the headers | |
6577 | # Warning: transition of version 9 to 10 will break this algorithm | |
6578 | # because 10 sorts before 9. We also look for just tcl. We have to | |
6579 | # be careful that we don't match stuff like tclX by accident. | |
6580 | # the alternative search directory is involked by --with-tclinclude | |
6581 | # | |
6582 | ||
6583 | no_tcl=true | |
6584 | echo $ac_n "checking for Tcl private headers. dir=${configdir}""... $ac_c" 1>&6 | |
b46cd165 | 6585 | echo "configure:6586: checking for Tcl private headers. dir=${configdir}" >&5 |
3fc11d3e JM |
6586 | # Check whether --with-tclinclude or --without-tclinclude was given. |
6587 | if test "${with_tclinclude+set}" = set; then | |
6588 | withval="$with_tclinclude" | |
6589 | with_tclinclude=${withval} | |
6590 | fi | |
6591 | ||
6592 | if eval "test \"`echo '$''{'ac_cv_c_tclh'+set}'`\" = set"; then | |
6593 | echo $ac_n "(cached) $ac_c" 1>&6 | |
6594 | else | |
6595 | ||
6596 | # first check to see if --with-tclinclude was specified | |
6597 | if test x"${with_tclinclude}" != x ; then | |
6598 | if test -f ${with_tclinclude}/tclInt.h ; then | |
6599 | ac_cv_c_tclh=`(cd ${with_tclinclude}; pwd)` | |
6600 | elif test -f ${with_tclinclude}/generic/tclInt.h ; then | |
6601 | ac_cv_c_tclh=`(cd ${with_tclinclude}/generic; pwd)` | |
6602 | else | |
6603 | { echo "configure: error: ${with_tclinclude} directory doesn't contain private headers" 1>&2; exit 1; } | |
6604 | fi | |
6605 | fi | |
6606 | ||
6607 | # next check if it came with Tcl configuration file | |
6608 | if test x"${ac_cv_c_tclconfig}" = x ; then | |
6609 | if test -f $ac_cv_c_tclconfig/../generic/tclInt.h ; then | |
6610 | ac_cv_c_tclh=`(cd $ac_cv_c_tclconfig/..; pwd)` | |
6611 | fi | |
6612 | fi | |
6613 | ||
6614 | # next check in private source directory | |
6615 | # | |
6616 | # since ls returns lowest version numbers first, reverse its output | |
6617 | if test x"${ac_cv_c_tclh}" = x ; then | |
6618 | for i in \ | |
6619 | ${srcdir}/../tcl \ | |
6620 | `ls -dr ${srcdir}/../tcl[7-9]* 2>/dev/null` \ | |
6621 | ${srcdir}/../../tcl \ | |
6622 | `ls -dr ${srcdir}/../../tcl[7-9]* 2>/dev/null` \ | |
6623 | ${srcdir}/../../../tcl \ | |
6624 | `ls -dr ${srcdir}/../../../tcl[7-9]* 2>/dev/null ` ; do | |
6625 | if test -f $i/generic/tclInt.h ; then | |
6626 | ac_cv_c_tclh=`(cd $i/generic; pwd)` | |
6627 | break | |
6628 | fi | |
6629 | done | |
6630 | fi | |
6631 | # finally check in a few common install locations | |
6632 | # | |
6633 | # since ls returns lowest version numbers first, reverse its output | |
6634 | if test x"${ac_cv_c_tclh}" = x ; then | |
6635 | for i in \ | |
6636 | `ls -dr /usr/local/src/tcl[7-9]* 2>/dev/null` \ | |
6637 | `ls -dr /usr/local/lib/tcl[7-9]* 2>/dev/null` \ | |
6638 | /usr/local/src/tcl \ | |
6639 | /usr/local/lib/tcl \ | |
6640 | ${prefix}/include ; do | |
6641 | if test -f $i/generic/tclInt.h ; then | |
6642 | ac_cv_c_tclh=`(cd $i/generic; pwd)` | |
6643 | break | |
6644 | fi | |
6645 | done | |
6646 | fi | |
6647 | # see if one is installed | |
6648 | if test x"${ac_cv_c_tclh}" = x ; then | |
6649 | ac_safe=`echo "tclInt.h" | sed 'y%./+-%__p_%'` | |
6650 | echo $ac_n "checking for tclInt.h""... $ac_c" 1>&6 | |
b46cd165 | 6651 | echo "configure:6652: checking for tclInt.h" >&5 |
3fc11d3e JM |
6652 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
6653 | echo $ac_n "(cached) $ac_c" 1>&6 | |
6654 | else | |
6655 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 6656 | #line 6657 "configure" |
3fc11d3e JM |
6657 | #include "confdefs.h" |
6658 | #include <tclInt.h> | |
6659 | EOF | |
6660 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
b46cd165 | 6661 | { (eval echo configure:6662: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
3fc11d3e JM |
6662 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
6663 | if test -z "$ac_err"; then | |
6664 | rm -rf conftest* | |
6665 | eval "ac_cv_header_$ac_safe=yes" | |
6666 | else | |
6667 | echo "$ac_err" >&5 | |
6668 | echo "configure: failed program was:" >&5 | |
6669 | cat conftest.$ac_ext >&5 | |
6670 | rm -rf conftest* | |
6671 | eval "ac_cv_header_$ac_safe=no" | |
6672 | fi | |
6673 | rm -f conftest* | |
6674 | fi | |
6675 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | |
6676 | echo "$ac_t""yes" 1>&6 | |
6677 | ac_cv_c_tclh=installed | |
6678 | else | |
6679 | echo "$ac_t""no" 1>&6 | |
6680 | ac_cv_c_tclh="" | |
6681 | fi | |
6682 | ||
6683 | fi | |
6684 | ||
6685 | fi | |
6686 | ||
6687 | if test x"${ac_cv_c_tclh}" = x ; then | |
6688 | TCLHDIR="# no Tcl private headers found" | |
6689 | { echo "configure: error: Can't find Tcl private headers" 1>&2; exit 1; } | |
6690 | fi | |
6691 | if test x"${ac_cv_c_tclh}" != x ; then | |
6692 | no_tcl="" | |
6693 | if test x"${ac_cv_c_tclh}" = x"installed" ; then | |
6694 | echo "$ac_t""is installed" 1>&6 | |
6695 | TCLHDIR="" | |
6696 | else | |
6697 | echo "$ac_t""found in ${ac_cv_c_tclh}" 1>&6 | |
6698 | # this hack is cause the TCLHDIR won't print if there is a "-I" in it. | |
6699 | TCLHDIR="-I${ac_cv_c_tclh}" | |
6700 | fi | |
6701 | fi | |
6702 | ||
6703 | ||
6704 | ||
6705 | ||
6706 | # | |
6707 | # Ok, lets find the tk source trees so we can use the headers | |
6708 | # If the directory (presumably symlink) named "tk" exists, use that one | |
6709 | # in preference to any others. Same logic is used when choosing library | |
6710 | # and again with Tcl. The search order is the best place to look first, then in | |
6711 | # decreasing significance. The loop breaks if the trigger file is found. | |
6712 | # Note the gross little conversion here of srcdir by cd'ing to the found | |
6713 | # directory. This converts the path from a relative to an absolute, so | |
6714 | # recursive cache variables for the path will work right. We check all | |
6715 | # the possible paths in one loop rather than many seperate loops to speed | |
6716 | # things up. | |
6717 | # the alternative search directory is involked by --with-tkinclude | |
6718 | # | |
6719 | no_tk=true | |
6720 | echo $ac_n "checking for Tk private headers""... $ac_c" 1>&6 | |
b46cd165 | 6721 | echo "configure:6722: checking for Tk private headers" >&5 |
3fc11d3e JM |
6722 | # Check whether --with-tkinclude or --without-tkinclude was given. |
6723 | if test "${with_tkinclude+set}" = set; then | |
6724 | withval="$with_tkinclude" | |
6725 | with_tkinclude=${withval} | |
6726 | fi | |
6727 | ||
6728 | if eval "test \"`echo '$''{'ac_cv_c_tkh'+set}'`\" = set"; then | |
6729 | echo $ac_n "(cached) $ac_c" 1>&6 | |
6730 | else | |
6731 | ||
6732 | # first check to see if --with-tkinclude was specified | |
6733 | if test x"${with_tkinclude}" != x ; then | |
6734 | if test -f ${with_tkinclude}/tk.h ; then | |
6735 | ac_cv_c_tkh=`(cd ${with_tkinclude}; pwd)` | |
6736 | elif test -f ${with_tkinclude}/generic/tk.h ; then | |
6737 | ac_cv_c_tkh=`(cd ${with_tkinclude}/generic; pwd)` | |
6738 | else | |
6739 | { echo "configure: error: ${with_tkinclude} directory doesn't contain private headers" 1>&2; exit 1; } | |
6740 | fi | |
6741 | fi | |
6742 | ||
6743 | # next check if it came with Tk configuration file | |
6744 | if test x"${ac_cv_c_tkconfig}" = x ; then | |
6745 | if test -f $ac_cv_c_tkconfig/../generic/tk.h ; then | |
6746 | ac_cv_c_tkh=`(cd $ac_cv_c_tkconfig/..; pwd)` | |
6747 | fi | |
6748 | fi | |
6749 | ||
6750 | # next check in private source directory | |
6751 | # | |
6752 | # since ls returns lowest version numbers first, reverse its output | |
6753 | if test x"${ac_cv_c_tkh}" = x ; then | |
6754 | for i in \ | |
6755 | ${srcdir}/../tk \ | |
6756 | `ls -dr ${srcdir}/../tk[4-9]* 2>/dev/null` \ | |
6757 | ${srcdir}/../../tk \ | |
6758 | `ls -dr ${srcdir}/../../tk[4-9]* 2>/dev/null` \ | |
6759 | ${srcdir}/../../../tk \ | |
6760 | `ls -dr ${srcdir}/../../../tk[4-9]* 2>/dev/null ` ; do | |
6761 | if test -f $i/generic/tk.h ; then | |
6762 | ac_cv_c_tkh=`(cd $i/generic; pwd)` | |
6763 | break | |
6764 | fi | |
6765 | done | |
6766 | fi | |
6767 | # finally check in a few common install locations | |
6768 | # | |
6769 | # since ls returns lowest version numbers first, reverse its output | |
6770 | if test x"${ac_cv_c_tkh}" = x ; then | |
6771 | for i in \ | |
6772 | `ls -dr /usr/local/src/tk[4-9]* 2>/dev/null` \ | |
6773 | `ls -dr /usr/local/lib/tk[4-9]* 2>/dev/null` \ | |
6774 | /usr/local/src/tk \ | |
6775 | /usr/local/lib/tk \ | |
6776 | ${prefix}/include ; do | |
6777 | if test -f $i/generic/tk.h ; then | |
6778 | ac_cv_c_tkh=`(cd $i/generic; pwd)` | |
6779 | break | |
6780 | fi | |
6781 | done | |
6782 | fi | |
6783 | # see if one is installed | |
6784 | if test x"${ac_cv_c_tkh}" = x ; then | |
6785 | ac_safe=`echo "tk.h" | sed 'y%./+-%__p_%'` | |
6786 | echo $ac_n "checking for tk.h""... $ac_c" 1>&6 | |
b46cd165 | 6787 | echo "configure:6788: checking for tk.h" >&5 |
3fc11d3e JM |
6788 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
6789 | echo $ac_n "(cached) $ac_c" 1>&6 | |
6790 | else | |
6791 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 6792 | #line 6793 "configure" |
3fc11d3e JM |
6793 | #include "confdefs.h" |
6794 | #include <tk.h> | |
6795 | EOF | |
6796 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
b46cd165 | 6797 | { (eval echo configure:6798: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
3fc11d3e JM |
6798 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
6799 | if test -z "$ac_err"; then | |
6800 | rm -rf conftest* | |
6801 | eval "ac_cv_header_$ac_safe=yes" | |
6802 | else | |
6803 | echo "$ac_err" >&5 | |
6804 | echo "configure: failed program was:" >&5 | |
6805 | cat conftest.$ac_ext >&5 | |
6806 | rm -rf conftest* | |
6807 | eval "ac_cv_header_$ac_safe=no" | |
6808 | fi | |
6809 | rm -f conftest* | |
6810 | fi | |
6811 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | |
6812 | echo "$ac_t""yes" 1>&6 | |
6813 | ac_cv_c_tkh=installed | |
6814 | else | |
6815 | echo "$ac_t""no" 1>&6 | |
6816 | ac_cv_c_tkh="" | |
6817 | fi | |
6818 | ||
6819 | fi | |
6820 | ||
6821 | fi | |
6822 | ||
6823 | if test x"${ac_cv_c_tkh}" != x ; then | |
6824 | no_tk="" | |
6825 | if test x"${ac_cv_c_tkh}" = x"installed" ; then | |
6826 | echo "$ac_t""is installed" 1>&6 | |
6827 | TKHDIR="" | |
6828 | else | |
6829 | echo "$ac_t""found in ${ac_cv_c_tkh}" 1>&6 | |
6830 | # this hack is cause the TKHDIR won't print if there is a "-I" in it. | |
6831 | TKHDIR="-I${ac_cv_c_tkh}" | |
6832 | fi | |
6833 | else | |
6834 | TKHDIR="# no Tk directory found" | |
6835 | echo "configure: warning: Can't find Tk private headers" 1>&2 | |
6836 | no_tk=true | |
6837 | fi | |
6838 | ||
6839 | ||
6840 | ||
6841 | ||
6842 | echo $ac_n "checking for Itcl private headers. srcdir=${srcdir}""... $ac_c" 1>&6 | |
b46cd165 | 6843 | echo "configure:6844: checking for Itcl private headers. srcdir=${srcdir}" >&5 |
3fc11d3e JM |
6844 | if test x"${ac_cv_c_itclh}" = x ; then |
6845 | for i in ${srcdir}/../itcl ${srcdir}/../../itcl ${srcdir}/../../../itcl ${srcdir}/../itcl/itcl; do | |
6846 | if test -f $i/generic/itcl.h ; then | |
6847 | ac_cv_c_itclh=`(cd $i/generic; pwd)` | |
6848 | break | |
6849 | fi | |
6850 | done | |
6851 | fi | |
6852 | if test x"${ac_cv_c_itclh}" = x ; then | |
6853 | ITCLHDIR="# no Itcl private headers found" | |
6854 | { echo "configure: error: Can't find Itcl private headers" 1>&2; exit 1; } | |
6855 | fi | |
6856 | if test x"${ac_cv_c_itclh}" != x ; then | |
6857 | ITCLHDIR="-I${ac_cv_c_itclh}" | |
6858 | fi | |
6859 | # should always be here | |
6860 | # ITCLLIB="../itcl/itcl/unix/libitcl.a" | |
6861 | ||
6862 | #AC_SUBST(ITCLLIB) | |
6863 | ||
6864 | ||
6865 | echo $ac_n "checking for Itk private headers. srcdir=${srcdir}""... $ac_c" 1>&6 | |
b46cd165 | 6866 | echo "configure:6867: checking for Itk private headers. srcdir=${srcdir}" >&5 |
3fc11d3e JM |
6867 | if test x"${ac_cv_c_itkh}" = x ; then |
6868 | for i in ${srcdir}/../itcl ${srcdir}/../../itcl ${srcdir}/../../../itcl ${srcdir}/../itcl/itk; do | |
6869 | if test -f $i/generic/itk.h ; then | |
6870 | ac_cv_c_itkh=`(cd $i/generic; pwd)` | |
6871 | break | |
6872 | fi | |
6873 | done | |
6874 | fi | |
6875 | if test x"${ac_cv_c_itkh}" = x ; then | |
6876 | ITKHDIR="# no Itk private headers found" | |
6877 | { echo "configure: error: Can't find Itk private headers" 1>&2; exit 1; } | |
6878 | fi | |
6879 | if test x"${ac_cv_c_itkh}" != x ; then | |
6880 | ITKHDIR="-I${ac_cv_c_itkh}" | |
6881 | fi | |
6882 | # should always be here | |
6883 | # ITKLIB="../itcl/itk/unix/libitk.a" | |
6884 | ||
6885 | #AC_SUBST(ITKLIB) | |
6886 | ||
6887 | ||
6888 | echo $ac_n "checking for Tix private headers. srcdir=${srcdir}""... $ac_c" 1>&6 | |
b46cd165 | 6889 | echo "configure:6890: checking for Tix private headers. srcdir=${srcdir}" >&5 |
3fc11d3e JM |
6890 | if test x"${ac_cv_c_tixh}" = x ; then |
6891 | for i in ${srcdir}/../tix ${srcdir}/../../tix ${srcdir}/../../../tix ; do | |
6892 | if test -f $i/generic/tix.h ; then | |
6893 | ac_cv_c_tixh=`(cd $i/generic; pwd)` | |
6894 | break | |
6895 | fi | |
6896 | done | |
6897 | fi | |
6898 | if test x"${ac_cv_c_tixh}" = x ; then | |
6899 | TIXHDIR="# no Tix private headers found" | |
6900 | { echo "configure: error: Can't find Tix private headers" 1>&2; exit 1; } | |
6901 | fi | |
6902 | if test x"${ac_cv_c_tixh}" != x ; then | |
6903 | TIXHDIR="-I${ac_cv_c_tixh}" | |
6904 | fi | |
6905 | ||
6906 | ||
6907 | ||
6908 | # now look for Itcl library stuff | |
6909 | ||
6910 | ||
6911 | # | |
6912 | # Ok, lets find the itcl configuration | |
6913 | # First, look for one uninstalled. | |
6914 | # the alternative search directory is invoked by --with-itclconfig | |
6915 | # | |
6916 | ||
6917 | if test x"${no_itcl}" = x ; then | |
6918 | # we reset no_itcl in case something fails here | |
6919 | no_itcl=true | |
6920 | # Check whether --with-itclconfig or --without-itclconfig was given. | |
6921 | if test "${with_itclconfig+set}" = set; then | |
6922 | withval="$with_itclconfig" | |
6923 | with_itclconfig=${withval} | |
6924 | fi | |
6925 | ||
6926 | echo $ac_n "checking for Itcl configuration""... $ac_c" 1>&6 | |
b46cd165 | 6927 | echo "configure:6928: checking for Itcl configuration" >&5 |
3fc11d3e JM |
6928 | if eval "test \"`echo '$''{'ac_cv_c_itclconfig'+set}'`\" = set"; then |
6929 | echo $ac_n "(cached) $ac_c" 1>&6 | |
6930 | else | |
6931 | ||
6932 | ||
6933 | # First check to see if --with-itclconfig was specified. | |
6934 | if test x"${with_itclconfig}" != x ; then | |
6935 | if test -f "${with_itclconfig}/itclConfig.sh" ; then | |
6936 | ac_cv_c_itclconfig=`(cd ${with_itclconfig}; pwd)` | |
6937 | else | |
6938 | { echo "configure: error: ${with_itclconfig} directory doesn't contain itclConfig.sh" 1>&2; exit 1; } | |
6939 | fi | |
6940 | fi | |
6941 | ||
6942 | # then check for a private Itcl library | |
6943 | if test x"${ac_cv_c_itclconfig}" = x ; then | |
6944 | for i in \ | |
6945 | ../itcl/itcl \ | |
6946 | `ls -dr ../itcl[4-9]*/itcl 2>/dev/null` \ | |
6947 | ../../itcl \ | |
6948 | `ls -dr ../../itcl[4-9]*/itcl 2>/dev/null` \ | |
6949 | ../../../itcl \ | |
6950 | `ls -dr ../../../itcl[4-9]*/itcl 2>/dev/null` ; do | |
6951 | if test -f "$i/itclConfig.sh" ; then | |
6952 | ac_cv_c_itclconfig=`(cd $i; pwd)` | |
6953 | break | |
6954 | fi | |
6955 | done | |
6956 | fi | |
6957 | # check in a few common install locations | |
6958 | if test x"${ac_cv_c_itclconfig}" = x ; then | |
6959 | for i in `ls -d ${prefix}/lib /usr/local/lib 2>/dev/null` ; do | |
6960 | if test -f "$i/itclConfig.sh" ; then | |
6961 | ac_cv_c_itclconfig=`(cd $i; pwd)` | |
6962 | break | |
6963 | fi | |
6964 | done | |
6965 | fi | |
6966 | # check in a few other private locations | |
6967 | if test x"${ac_cv_c_itclconfig}" = x ; then | |
6968 | for i in \ | |
6969 | ${srcdir}/../itcl/itcl \ | |
6970 | `ls -dr ${srcdir}/../itcl[4-9]*/itcl 2>/dev/null` ; do | |
6971 | if test -f "$i/itclConfig.sh" ; then | |
6972 | ac_cv_c_itclconfig=`(cd $i; pwd)` | |
6973 | break | |
6974 | fi | |
6975 | done | |
6976 | fi | |
6977 | ||
6978 | fi | |
6979 | ||
6980 | if test x"${ac_cv_c_itclconfig}" = x ; then | |
6981 | ITCLCONFIG="# no Itcl configs found" | |
6982 | echo "configure: warning: Can't find Itcl configuration definitions" 1>&2 | |
6983 | else | |
6984 | no_itcl= | |
6985 | ITCLCONFIG=${ac_cv_c_itclconfig}/itclConfig.sh | |
6986 | echo "$ac_t""found $ITCLCONFIG" 1>&6 | |
6987 | fi | |
6988 | fi | |
6989 | ||
6990 | if test -z "${no_itcl}"; then | |
6991 | ||
6992 | if test -f "$ITCLCONFIG" ; then | |
6993 | . $ITCLCONFIG | |
6994 | fi | |
6995 | ||
6996 | ||
6997 | ||
6998 | ||
6999 | ||
7000 | ||
7001 | ||
7002 | ||
7003 | ||
7004 | ||
7005 | ||
7006 | case "${host}" in | |
7007 | *-*-cygwin*) | |
7008 | itcldir=../itcl/itcl/win/ | |
7009 | ;; | |
7010 | *) | |
7011 | itcldir=../itcl/itcl/unix/ | |
7012 | ;; | |
7013 | esac | |
7014 | ||
7015 | ||
7016 | ITCLLIB="${ITCL_BUILD_LIB_SPEC}" | |
7017 | ITCL_DEPS="${itcldir}${ITCL_LIB_FILE}" | |
7018 | fi | |
7019 | ||
7020 | ||
7021 | # now look for Itk library stuff | |
7022 | ||
7023 | # | |
7024 | # Ok, lets find the itk configuration | |
7025 | # First, look for one uninstalled. | |
7026 | # the alternative search directory is invoked by --with-itkconfig | |
7027 | # | |
7028 | ||
7029 | if test x"${no_itk}" = x ; then | |
7030 | # we reset no_itk in case something fails here | |
7031 | no_itk=true | |
7032 | # Check whether --with-itkconfig or --without-itkconfig was given. | |
7033 | if test "${with_itkconfig+set}" = set; then | |
7034 | withval="$with_itkconfig" | |
7035 | with_itkconfig=${withval} | |
7036 | fi | |
7037 | ||
7038 | echo $ac_n "checking for Itk configuration""... $ac_c" 1>&6 | |
b46cd165 | 7039 | echo "configure:7040: checking for Itk configuration" >&5 |
3fc11d3e JM |
7040 | if eval "test \"`echo '$''{'ac_cv_c_itkconfig'+set}'`\" = set"; then |
7041 | echo $ac_n "(cached) $ac_c" 1>&6 | |
7042 | else | |
7043 | ||
7044 | ||
7045 | # First check to see if --with-itkconfig was specified. | |
7046 | if test x"${with_itkconfig}" != x ; then | |
7047 | if test -f "${with_itkconfig}/itkConfig.sh" ; then | |
7048 | ac_cv_c_itkconfig=`(cd ${with_itkconfig}; pwd)` | |
7049 | else | |
7050 | { echo "configure: error: ${with_itkconfig} directory doesn't contain itkConfig.sh" 1>&2; exit 1; } | |
7051 | fi | |
7052 | fi | |
7053 | ||
7054 | # then check for a private Itk library | |
7055 | if test x"${ac_cv_c_itkconfig}" = x ; then | |
7056 | for i in \ | |
7057 | ../itcl/itk \ | |
7058 | `ls -dr ../itcl[4-9]*/itk 2>/dev/null` \ | |
7059 | ../../itk \ | |
7060 | `ls -dr ../../itcl[4-9]*/itk 2>/dev/null` \ | |
7061 | ../../../itk \ | |
7062 | `ls -dr ../../../itcl[4-9]*/itk 2>/dev/null` ; do | |
7063 | if test -f "$i/itkConfig.sh" ; then | |
7064 | ac_cv_c_itkconfig=`(cd $i; pwd)` | |
7065 | break | |
7066 | fi | |
7067 | done | |
7068 | fi | |
7069 | # check in a few common install locations | |
7070 | if test x"${ac_cv_c_itkconfig}" = x ; then | |
7071 | for i in `ls -d ${prefix}/lib /usr/local/lib 2>/dev/null` ; do | |
7072 | if test -f "$i/itkConfig.sh" ; then | |
7073 | ac_cv_c_itkconfig=`(cd $i; pwd)` | |
7074 | break | |
7075 | fi | |
7076 | done | |
7077 | fi | |
7078 | # check in a few other private locations | |
7079 | if test x"${ac_cv_c_itkconfig}" = x ; then | |
7080 | for i in \ | |
7081 | ${srcdir}/../itcl/itk \ | |
7082 | `ls -dr ${srcdir}/../itcl[4-9]*/itk 2>/dev/null` ; do | |
7083 | if test -f "$i/itkConfig.sh" ; then | |
7084 | ac_cv_c_itkconfig=`(cd $i; pwd)` | |
7085 | break | |
7086 | fi | |
7087 | done | |
7088 | fi | |
7089 | ||
7090 | fi | |
7091 | ||
7092 | if test x"${ac_cv_c_itkconfig}" = x ; then | |
7093 | ITKCONFIG="# no Itk configs found" | |
7094 | echo "configure: warning: Can't find Itk configuration definitions" 1>&2 | |
7095 | else | |
7096 | no_itk= | |
7097 | ITKCONFIG=${ac_cv_c_itkconfig}/itkConfig.sh | |
7098 | echo "$ac_t""found $ITKCONFIG" 1>&6 | |
7099 | fi | |
7100 | fi | |
7101 | ||
7102 | ||
7103 | if test -z "${no_itcl}"; then | |
7104 | ||
7105 | if test -f "$ITKCONFIG" ; then | |
7106 | . $ITKCONFIG | |
7107 | fi | |
7108 | ||
7109 | ||
7110 | ||
7111 | ||
7112 | ||
7113 | ||
7114 | ||
7115 | ||
7116 | ||
7117 | ||
7118 | ||
7119 | ||
7120 | case "${host}" in | |
7121 | *-*-cygwin*) | |
7122 | itkdir=../itcl/itk/win/ | |
7123 | ;; | |
7124 | *) | |
7125 | itkdir=../itcl/itk/unix/ | |
7126 | ;; | |
7127 | esac | |
7128 | ||
7129 | ITKLIB="${ITK_BUILD_LIB_SPEC}" | |
7130 | ITK_DEPS="${itkdir}${ITK_LIB_FILE}" | |
7131 | fi | |
7132 | ||
7133 | # now look for Tix library stuff | |
7134 | ||
7135 | # | |
7136 | # Ok, lets find the tix configuration | |
7137 | # First, look for one uninstalled. | |
7138 | # the alternative search directory is invoked by --with-itkconfig | |
7139 | # | |
7140 | ||
7141 | if test x"${no_tix}" = x ; then | |
7142 | # we reset no_tix in case something fails here | |
7143 | no_tix=true | |
7144 | # Check whether --with-tixconfig or --without-tixconfig was given. | |
7145 | if test "${with_tixconfig+set}" = set; then | |
7146 | withval="$with_tixconfig" | |
7147 | with_tixconfig=${withval} | |
7148 | fi | |
7149 | ||
7150 | echo $ac_n "checking for Tix configuration""... $ac_c" 1>&6 | |
b46cd165 | 7151 | echo "configure:7152: checking for Tix configuration" >&5 |
3fc11d3e JM |
7152 | if eval "test \"`echo '$''{'ac_cv_c_tixconfig'+set}'`\" = set"; then |
7153 | echo $ac_n "(cached) $ac_c" 1>&6 | |
7154 | else | |
7155 | ||
7156 | ||
7157 | # First check to see if --with-tixconfig was specified. | |
7158 | if test x"${with_tixconfig}" != x ; then | |
7159 | if test -f "${with_tixconfig}/tixConfig.sh" ; then | |
7160 | ac_cv_c_tixconfig=`(cd ${with_tixconfig}; pwd)` | |
7161 | else | |
7162 | { echo "configure: error: ${with_tixconfig} directory doesn't contain tixConfig.sh" 1>&2; exit 1; } | |
7163 | fi | |
7164 | fi | |
7165 | ||
7166 | # then check for a private Tix library | |
7167 | if test x"${ac_cv_c_tixconfig}" = x ; then | |
7168 | for i in \ | |
7169 | ../tix \ | |
7170 | `ls -dr ../tix 2>/dev/null` \ | |
7171 | ../../tix \ | |
7172 | `ls -dr ../../tix 2>/dev/null` \ | |
7173 | ../../../tix \ | |
7174 | `ls -dr ../../../tix 2>/dev/null` ; do | |
7175 | echo "**** Looking at $i - with ${configdir}" | |
7176 | if test -f "$i/tixConfig.sh" ; then | |
7177 | ac_cv_c_tixconfig=`(cd $i; pwd)` | |
7178 | break | |
7179 | fi | |
7180 | done | |
7181 | fi | |
7182 | # check in a few common install locations | |
7183 | if test x"${ac_cv_c_tixconfig}" = x ; then | |
7184 | for i in `ls -d ${prefix}/lib /usr/local/lib 2>/dev/null` ; do | |
7185 | echo "**** Looking at $i" | |
7186 | if test -f "$i/tixConfig.sh" ; then | |
7187 | ac_cv_c_tixconfig=`(cd $i; pwd)` | |
7188 | break | |
7189 | fi | |
7190 | done | |
7191 | fi | |
7192 | # check in a few other private locations | |
7193 | echo "**** Other private locations" | |
7194 | if test x"${ac_cv_c_tixconfig}" = x ; then | |
7195 | for i in \ | |
7196 | ${srcdir}/../tix \ | |
7197 | `ls -dr ${srcdir}/../tix 2>/dev/null` ; do | |
7198 | echo "**** Looking at $i - with ${configdir}" | |
7199 | if test -f "$i/${configdir}/tixConfig.sh" ; then | |
7200 | ac_cv_c_tixconfig=`(cd $i/${configdir}; pwd)` | |
7201 | break | |
7202 | fi | |
7203 | done | |
7204 | fi | |
7205 | ||
7206 | fi | |
7207 | ||
7208 | if test x"${ac_cv_c_tixconfig}" = x ; then | |
7209 | TIXCONFIG="# no Tix configs found" | |
7210 | echo "configure: warning: Can't find Tix configuration definitions" 1>&2 | |
7211 | else | |
7212 | no_tix= | |
7213 | TIXCONFIG=${ac_cv_c_tixconfig}/tixConfig.sh | |
7214 | echo "$ac_t""found $TIXCONFIG" 1>&6 | |
7215 | fi | |
7216 | fi | |
7217 | ||
7218 | ||
7219 | if test -z "${no_tix}"; then | |
7220 | ||
7221 | if test -f "$TIXCONFIG" ; then | |
7222 | . $TIXCONFIG | |
7223 | fi | |
7224 | ||
7225 | ||
7226 | ||
7227 | ||
7228 | ||
7229 | ||
7230 | ||
7231 | ||
7232 | TIXLIB="${TIX_BUILD_LIB_SPEC}" | |
7233 | TIX_DEPS="${TIX_BUILD_LOCATION}/${TIX_LIB_FILE}" | |
7234 | fi | |
7235 | ||
4226a5a5 | 7236 | ENABLE_CFLAGS="${ENABLE_CFLAGS} \$(SUBDIR_GDBTK_CFLAGS)" |
3fc11d3e JM |
7237 | # Tcl/Tk 8.1 require -fwritable strings. I don't |
7238 | # know whether 8.2 will or not, but I bet it will. | |
7239 | # I don't have to worry about 7.x since we don't support it. | |
7240 | GDBTK_CFLAGS="" | |
7241 | if test "$GCC" = "yes"; then | |
7242 | if test "$TCL_VERSION" != "8.0" ; then | |
7243 | GDBTK_CFLAGS="-fwritable-strings" | |
7244 | fi | |
7245 | fi | |
7246 | ||
7247 | # Include some libraries that Tcl and Tk want. | |
7248 | TCL_LIBS='$(LIBGUI) $(ITCL) $(ITK) $(TIX) $(TK) $(TCL) $(X11_LDFLAGS) $(X11_LIBS)' | |
3fc11d3e JM |
7249 | # Yes, the ordering seems wrong here. But it isn't. |
7250 | # TK_LIBS is the list of libraries that need to be linked | |
7251 | # after Tcl/Tk. Note that this isn't put into LIBS. If it | |
7252 | # were in LIBS then any link tests after this point would | |
7253 | # try to include things like `$(LIBGUI)', which wouldn't work. | |
7254 | GDBTKLIBS="${TCL_LIBS} ${TK_LIBS}" | |
4226a5a5 FN |
7255 | |
7256 | CONFIG_OBS="${CONFIG_OBS} \$(SUBDIR_GDBTK_OBS)" | |
7257 | CONFIG_DEPS="${CONFIG_DEPS} \$(SUBDIR_GDBTK_DEPS)" | |
7258 | CONFIG_SRCS="${CONFIG_SRCS} \$(SUBDIR_GDBTK_SRCS)" | |
7259 | CONFIG_INITS="${CONFIG_INITS} \$(SUBDIR_GDBTK_INITS)" | |
b3a90332 | 7260 | CONFIG_ALL="${CONFIG_ALL} \$(SUBDIR_GDBTK_ALL)" |
ce844ae2 | 7261 | CONFIG_CLEAN="${CONFIG_CLEAN} \$(SUBDIR_GDBTK_CLEAN)" |
e56ac5c3 AC |
7262 | CONFIG_INSTALL="${CONFIG_INSTALL} \$(SUBDIR_GDBTK_INSTALL)" |
7263 | CONFIG_UNINSTALL="${CONFIG_UNINSTALL} \$(SUBDIR_GDBTK_UNINSTALL)" | |
3fc11d3e JM |
7264 | |
7265 | if test x$gdb_cv_os_cygwin = xyes; then | |
7266 | WIN32LIBS="${WIN32LIBS} -lshell32 -lgdi32 -lcomdlg32 -ladvapi32" | |
7267 | WIN32LDAPP="-Wl,--subsystem,console" | |
7268 | CONFIG_OBS="${CONFIG_OBS} gdbres.o" | |
7269 | fi | |
7270 | fi | |
7271 | fi | |
7272 | fi | |
7273 | ||
7274 | ||
7275 | ||
7276 | ||
7277 | ||
7278 | ||
7279 | ||
7280 | ||
7281 | ||
7282 | ||
7283 | ||
7284 | ||
7285 | ||
c906108c SS |
7286 | # If we find X, set shell vars x_includes and x_libraries to the |
7287 | # paths, otherwise set no_x=yes. | |
7288 | # Uses ac_ vars as temps to allow command line to override cache and checks. | |
7289 | # --without-x overrides everything else, but does not touch the cache. | |
7290 | echo $ac_n "checking for X""... $ac_c" 1>&6 | |
b46cd165 | 7291 | echo "configure:7292: checking for X" >&5 |
c906108c SS |
7292 | |
7293 | # Check whether --with-x or --without-x was given. | |
7294 | if test "${with_x+set}" = set; then | |
7295 | withval="$with_x" | |
7296 | : | |
7297 | fi | |
7298 | ||
7299 | # $have_x is `yes', `no', `disabled', or empty when we do not yet know. | |
7300 | if test "x$with_x" = xno; then | |
7301 | # The user explicitly disabled X. | |
7302 | have_x=disabled | |
7303 | else | |
7304 | if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then | |
7305 | # Both variables are already set. | |
7306 | have_x=yes | |
7307 | else | |
7308 | if eval "test \"`echo '$''{'ac_cv_have_x'+set}'`\" = set"; then | |
7309 | echo $ac_n "(cached) $ac_c" 1>&6 | |
7310 | else | |
7311 | # One or both of the vars are not set, and there is no cached value. | |
7312 | ac_x_includes=NO ac_x_libraries=NO | |
7313 | rm -fr conftestdir | |
7314 | if mkdir conftestdir; then | |
7315 | cd conftestdir | |
7316 | # Make sure to not put "make" in the Imakefile rules, since we grep it out. | |
7317 | cat > Imakefile <<'EOF' | |
7318 | acfindx: | |
7319 | @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"' | |
7320 | EOF | |
7321 | if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then | |
7322 | # GNU make sometimes prints "make[1]: Entering...", which would confuse us. | |
7323 | eval `${MAKE-make} acfindx 2>/dev/null | grep -v make` | |
7324 | # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR. | |
7325 | for ac_extension in a so sl; do | |
7326 | if test ! -f $ac_im_usrlibdir/libX11.$ac_extension && | |
7327 | test -f $ac_im_libdir/libX11.$ac_extension; then | |
7328 | ac_im_usrlibdir=$ac_im_libdir; break | |
7329 | fi | |
7330 | done | |
7331 | # Screen out bogus values from the imake configuration. They are | |
7332 | # bogus both because they are the default anyway, and because | |
7333 | # using them would break gcc on systems where it needs fixed includes. | |
7334 | case "$ac_im_incroot" in | |
7335 | /usr/include) ;; | |
7336 | *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes="$ac_im_incroot" ;; | |
7337 | esac | |
7338 | case "$ac_im_usrlibdir" in | |
7339 | /usr/lib | /lib) ;; | |
7340 | *) test -d "$ac_im_usrlibdir" && ac_x_libraries="$ac_im_usrlibdir" ;; | |
7341 | esac | |
7342 | fi | |
7343 | cd .. | |
7344 | rm -fr conftestdir | |
7345 | fi | |
7346 | ||
7347 | if test "$ac_x_includes" = NO; then | |
7348 | # Guess where to find include files, by looking for this one X11 .h file. | |
7349 | test -z "$x_direct_test_include" && x_direct_test_include=X11/Intrinsic.h | |
7350 | ||
7351 | # First, try using that file with no special directory specified. | |
7352 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 7353 | #line 7354 "configure" |
c906108c SS |
7354 | #include "confdefs.h" |
7355 | #include <$x_direct_test_include> | |
7356 | EOF | |
7357 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
b46cd165 | 7358 | { (eval echo configure:7359: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
c906108c SS |
7359 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
7360 | if test -z "$ac_err"; then | |
7361 | rm -rf conftest* | |
7362 | # We can compile using X headers with no special include directory. | |
7363 | ac_x_includes= | |
7364 | else | |
7365 | echo "$ac_err" >&5 | |
7366 | echo "configure: failed program was:" >&5 | |
7367 | cat conftest.$ac_ext >&5 | |
7368 | rm -rf conftest* | |
7369 | # Look for the header file in a standard set of common directories. | |
7370 | # Check X11 before X11Rn because it is often a symlink to the current release. | |
7371 | for ac_dir in \ | |
7372 | /usr/X11/include \ | |
7373 | /usr/X11R6/include \ | |
7374 | /usr/X11R5/include \ | |
7375 | /usr/X11R4/include \ | |
7376 | \ | |
7377 | /usr/include/X11 \ | |
7378 | /usr/include/X11R6 \ | |
7379 | /usr/include/X11R5 \ | |
7380 | /usr/include/X11R4 \ | |
7381 | \ | |
7382 | /usr/local/X11/include \ | |
7383 | /usr/local/X11R6/include \ | |
7384 | /usr/local/X11R5/include \ | |
7385 | /usr/local/X11R4/include \ | |
7386 | \ | |
7387 | /usr/local/include/X11 \ | |
7388 | /usr/local/include/X11R6 \ | |
7389 | /usr/local/include/X11R5 \ | |
7390 | /usr/local/include/X11R4 \ | |
7391 | \ | |
7392 | /usr/X386/include \ | |
7393 | /usr/x386/include \ | |
7394 | /usr/XFree86/include/X11 \ | |
7395 | \ | |
7396 | /usr/include \ | |
7397 | /usr/local/include \ | |
7398 | /usr/unsupported/include \ | |
7399 | /usr/athena/include \ | |
7400 | /usr/local/x11r5/include \ | |
7401 | /usr/lpp/Xamples/include \ | |
7402 | \ | |
7403 | /usr/openwin/include \ | |
7404 | /usr/openwin/share/include \ | |
7405 | ; \ | |
7406 | do | |
7407 | if test -r "$ac_dir/$x_direct_test_include"; then | |
7408 | ac_x_includes=$ac_dir | |
7409 | break | |
7410 | fi | |
7411 | done | |
7412 | fi | |
7413 | rm -f conftest* | |
7414 | fi # $ac_x_includes = NO | |
7415 | ||
7416 | if test "$ac_x_libraries" = NO; then | |
7417 | # Check for the libraries. | |
7418 | ||
7419 | test -z "$x_direct_test_library" && x_direct_test_library=Xt | |
7420 | test -z "$x_direct_test_function" && x_direct_test_function=XtMalloc | |
7421 | ||
7422 | # See if we find them without any special options. | |
7423 | # Don't add to $LIBS permanently. | |
7424 | ac_save_LIBS="$LIBS" | |
7425 | LIBS="-l$x_direct_test_library $LIBS" | |
7426 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 7427 | #line 7428 "configure" |
c906108c SS |
7428 | #include "confdefs.h" |
7429 | ||
7430 | int main() { | |
7431 | ${x_direct_test_function}() | |
7432 | ; return 0; } | |
7433 | EOF | |
b46cd165 | 7434 | if { (eval echo configure:7435: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
c906108c SS |
7435 | rm -rf conftest* |
7436 | LIBS="$ac_save_LIBS" | |
7437 | # We can link X programs with no special library path. | |
7438 | ac_x_libraries= | |
7439 | else | |
7440 | echo "configure: failed program was:" >&5 | |
7441 | cat conftest.$ac_ext >&5 | |
7442 | rm -rf conftest* | |
7443 | LIBS="$ac_save_LIBS" | |
7444 | # First see if replacing the include by lib works. | |
7445 | # Check X11 before X11Rn because it is often a symlink to the current release. | |
7446 | for ac_dir in `echo "$ac_x_includes" | sed s/include/lib/` \ | |
7447 | /usr/X11/lib \ | |
7448 | /usr/X11R6/lib \ | |
7449 | /usr/X11R5/lib \ | |
7450 | /usr/X11R4/lib \ | |
7451 | \ | |
7452 | /usr/lib/X11 \ | |
7453 | /usr/lib/X11R6 \ | |
7454 | /usr/lib/X11R5 \ | |
7455 | /usr/lib/X11R4 \ | |
7456 | \ | |
7457 | /usr/local/X11/lib \ | |
7458 | /usr/local/X11R6/lib \ | |
7459 | /usr/local/X11R5/lib \ | |
7460 | /usr/local/X11R4/lib \ | |
7461 | \ | |
7462 | /usr/local/lib/X11 \ | |
7463 | /usr/local/lib/X11R6 \ | |
7464 | /usr/local/lib/X11R5 \ | |
7465 | /usr/local/lib/X11R4 \ | |
7466 | \ | |
7467 | /usr/X386/lib \ | |
7468 | /usr/x386/lib \ | |
7469 | /usr/XFree86/lib/X11 \ | |
7470 | \ | |
7471 | /usr/lib \ | |
7472 | /usr/local/lib \ | |
7473 | /usr/unsupported/lib \ | |
7474 | /usr/athena/lib \ | |
7475 | /usr/local/x11r5/lib \ | |
7476 | /usr/lpp/Xamples/lib \ | |
7477 | /lib/usr/lib/X11 \ | |
7478 | \ | |
7479 | /usr/openwin/lib \ | |
7480 | /usr/openwin/share/lib \ | |
7481 | ; \ | |
7482 | do | |
7483 | for ac_extension in a so sl; do | |
7484 | if test -r $ac_dir/lib${x_direct_test_library}.$ac_extension; then | |
7485 | ac_x_libraries=$ac_dir | |
7486 | break 2 | |
7487 | fi | |
7488 | done | |
7489 | done | |
7490 | fi | |
7491 | rm -f conftest* | |
7492 | fi # $ac_x_libraries = NO | |
7493 | ||
7494 | if test "$ac_x_includes" = NO || test "$ac_x_libraries" = NO; then | |
7495 | # Didn't find X anywhere. Cache the known absence of X. | |
7496 | ac_cv_have_x="have_x=no" | |
7497 | else | |
7498 | # Record where we found X for the cache. | |
7499 | ac_cv_have_x="have_x=yes \ | |
7500 | ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries" | |
7501 | fi | |
7502 | fi | |
7503 | fi | |
7504 | eval "$ac_cv_have_x" | |
7505 | fi # $with_x != no | |
7506 | ||
7507 | if test "$have_x" != yes; then | |
7508 | echo "$ac_t""$have_x" 1>&6 | |
7509 | no_x=yes | |
7510 | else | |
7511 | # If each of the values was on the command line, it overrides each guess. | |
7512 | test "x$x_includes" = xNONE && x_includes=$ac_x_includes | |
7513 | test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries | |
7514 | # Update the cache value to reflect the command line values. | |
7515 | ac_cv_have_x="have_x=yes \ | |
7516 | ac_x_includes=$x_includes ac_x_libraries=$x_libraries" | |
7517 | echo "$ac_t""libraries $x_libraries, headers $x_includes" 1>&6 | |
7518 | fi | |
7519 | ||
7520 | ||
7a292a7a SS |
7521 | |
7522 | # Unlike the sim directory, whether a simulator is linked is controlled by | |
7523 | # presence of a SIM= and a SIM_OBS= definition in the target '.mt' file. | |
7524 | # This code just checks for a few cases where we'd like to ignore those | |
7525 | # definitions, even when they're present in the '.mt' file. These cases | |
7526 | # are when --disable-sim is specified, or if the simulator directory is | |
7527 | # not part of the soruce tree. | |
7528 | # | |
7529 | # Check whether --enable-sim or --disable-sim was given. | |
7530 | if test "${enable_sim+set}" = set; then | |
7531 | enableval="$enable_sim" | |
7532 | echo "enable_sim = $enable_sim"; | |
7533 | echo "enableval = ${enableval}"; | |
7534 | case "${enableval}" in | |
7535 | yes) ignore_sim=false ;; | |
7536 | no) ignore_sim=true ;; | |
7537 | *) ignore_sim=false ;; | |
7538 | esac | |
7539 | else | |
7540 | ignore_sim=false | |
7541 | fi | |
7542 | ||
7543 | ||
7544 | if test ! -d "${srcdir}/../sim"; then | |
7545 | ignore_sim=true | |
7546 | fi | |
7547 | ||
7548 | if test "${ignore_sim}" = "true"; then | |
7549 | IGNORE_SIM="SIM=" | |
7550 | IGNORE_SIM_OBS="SIM_OBS=" | |
7551 | else | |
7552 | IGNORE_SIM="" | |
7553 | IGNORE_SIM_OBS="" | |
7554 | cat >> confdefs.h <<\EOF | |
7555 | #define WITH_SIM 1 | |
7556 | EOF | |
7557 | ||
7558 | fi | |
7559 | ||
7560 | ||
7561 | ||
c906108c SS |
7562 | |
7563 | ||
7564 | ||
7565 | ||
7566 | ||
7567 | ||
dfcd3bfb | 7568 | |
e56ac5c3 AC |
7569 | |
7570 | ||
b3a90332 AC |
7571 | |
7572 | ||
b46cd165 | 7573 | |
c906108c SS |
7574 | # Begin stuff to support --enable-shared |
7575 | # Check whether --enable-shared or --disable-shared was given. | |
7576 | if test "${enable_shared+set}" = set; then | |
7577 | enableval="$enable_shared" | |
7578 | case "${enableval}" in | |
7579 | yes) shared=true ;; | |
7580 | no) shared=false ;; | |
7581 | *) shared=true ;; | |
7582 | esac | |
7583 | fi | |
7584 | ||
7585 | HLDFLAGS= | |
7586 | HLDENV= | |
7587 | # If we have shared libraries, try to set rpath reasonably. | |
7588 | if test "${shared}" = "true"; then | |
7589 | case "${host}" in | |
7590 | *-*-hpux*) | |
7591 | HLDFLAGS='-Wl,+s,+b,$(libdir)' | |
7592 | ;; | |
7593 | *-*-irix5* | *-*-irix6*) | |
7594 | HLDFLAGS='-Wl,-rpath,$(libdir)' | |
7595 | ;; | |
7596 | *-*-linux*aout*) | |
7597 | ;; | |
88987551 | 7598 | *-*-linux* | *-pc-linux-gnu*) |
c906108c SS |
7599 | HLDFLAGS='-Wl,-rpath,$(libdir)' |
7600 | ;; | |
7601 | *-*-solaris*) | |
7602 | HLDFLAGS='-R $(libdir)' | |
7603 | ;; | |
7604 | *-*-sysv4*) | |
7605 | 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;' | |
7606 | ;; | |
7607 | esac | |
7608 | fi | |
7609 | ||
7610 | # On SunOS, if the linker supports the -rpath option, use it to | |
7611 | # prevent ../bfd and ../opcodes from being included in the run time | |
7612 | # search path. | |
7613 | case "${host}" in | |
7614 | *-*-sunos*) | |
7615 | echo 'main () { }' > conftest.c | |
7616 | ${CC} -o conftest -Wl,-rpath= conftest.c >/dev/null 2>conftest.t | |
7617 | if grep 'unrecognized' conftest.t >/dev/null 2>&1; then | |
7618 | : | |
7619 | elif grep 'No such file' conftest.t >/dev/null 2>&1; then | |
7620 | : | |
7621 | elif grep 'do not mix' conftest.t >/dev/null 2>&1; then | |
7622 | : | |
7623 | elif grep 'some text already loaded' conftest.t >/dev/null 2>&1; then | |
7624 | : | |
7625 | elif test "${shared}" = "true"; then | |
7626 | HLDFLAGS='-Wl,-rpath=$(libdir)' | |
7627 | else | |
7628 | HLDFLAGS='-Wl,-rpath=' | |
7629 | fi | |
7630 | rm -f conftest.t conftest.c conftest | |
7631 | ;; | |
7632 | esac | |
7633 | ||
7634 | ||
7635 | # End stuff to support --enable-shared | |
7636 | ||
7637 | # target_subdir is used by the testsuite to find the target libraries. | |
7638 | target_subdir= | |
7639 | if test "${host}" != "${target}"; then | |
7640 | target_subdir="${target_alias}/" | |
7641 | fi | |
7642 | ||
7643 | ||
7644 | frags= | |
7645 | host_makefile_frag=${srcdir}/config/${gdb_host_cpu}/${gdb_host}.mh | |
7646 | if test ! -f ${host_makefile_frag}; then | |
7647 | { echo "configure: error: "*** Gdb does not support host ${host}"" 1>&2; exit 1; } | |
7648 | fi | |
7649 | frags="$frags $host_makefile_frag" | |
7650 | ||
7651 | target_makefile_frag=${srcdir}/config/${gdb_target_cpu}/${gdb_target}.mt | |
7652 | if test ! -f ${target_makefile_frag}; then | |
7653 | { echo "configure: error: "*** Gdb does not support target ${target}"" 1>&2; exit 1; } | |
7654 | fi | |
7655 | frags="$frags $target_makefile_frag" | |
7656 | ||
7657 | ||
7658 | ||
7659 | ||
7660 | ||
7661 | hostfile=`sed -n ' | |
7662 | s/XM_FILE[ ]*=[ ]*\([^ ]*\)/\1/p | |
7663 | ' ${host_makefile_frag}` | |
7664 | ||
7665 | targetfile=`sed -n ' | |
7666 | s/TM_FILE[ ]*=[ ]*\([^ ]*\)/\1/p | |
7667 | ' ${target_makefile_frag}` | |
7668 | ||
6166d547 AC |
7669 | GDB_MULTI_ARCH=`sed -n ' |
7670 | s/GDB_MULTI_ARCH[ ]*=[ ]*\([^ ]*\)[ ]*/\1/p | |
7671 | ' ${target_makefile_frag}` | |
7672 | ||
c906108c SS |
7673 | # these really aren't orthogonal true/false values of the same condition, |
7674 | # but shells are slow enough that I like to reuse the test conditions | |
7675 | # whenever possible | |
7676 | if test "${target}" = "${host}"; then | |
7677 | nativefile=`sed -n ' | |
7678 | s/NAT_FILE[ ]*=[ ]*\([^ ]*\)/\1/p | |
7679 | ' ${host_makefile_frag}` | |
7680 | # else | |
7681 | # GDBserver is only useful in a "native" enviroment | |
7682 | # configdirs=`echo $configdirs | sed 's/gdbserver//'` | |
7683 | fi | |
7684 | ||
7685 | ||
6166d547 AC |
7686 | # New targets should just set gdb_multi_arch=yes in configure.tgt. |
7687 | # Old targets being converted can either do that or set GDB_MULTI_ARCH | |
7688 | # in the target specific makefile frag. Eventually gdb_multi_arch=yes | |
7689 | # will be the default. | |
7690 | if test x"${GDB_MULTI_ARCH}" = x ; then | |
7691 | case "${gdb_multi_arch}" in | |
7692 | yes ) GDB_MULTI_ARCH=GDB_MULTI_ARCH_PURE ;; | |
7693 | no ) GDB_MULTI_ARCH=0 ;; | |
7694 | 0|1|2 ) GDB_MULTI_ARCH=${gdb_multi_arch} ;; | |
7695 | esac | |
7696 | fi | |
7697 | if test x"${GDB_MULTI_ARCH}" != x ; then | |
7698 | cat >> confdefs.h <<EOF | |
7699 | #define GDB_MULTI_ARCH ${GDB_MULTI_ARCH} | |
7700 | EOF | |
7701 | ||
7702 | fi | |
7703 | # Warn the user when they use an old pratice | |
7704 | case "${GDB_MULTI_ARCH}" in | |
7705 | "" ) ;; | |
7706 | 0 | GDB_MULTI_ARCH_PARTIAL | 1 | GDB_MULTI_ARCH_TM | 2 ) | |
7707 | echo "configure: warning: "GDB: Target is not pure multi-arch"" 1>&2 ;; | |
7708 | GDB_MULTI_ARCH_PURE ) | |
7709 | if test x"${targetfile}" != x ; then | |
7710 | echo "configure: warning: "GDB: Ingoring TM_FILE in ${target_makefile_frag}"" 1>&2 | |
5a2402b8 | 7711 | targetfile="" |
6166d547 AC |
7712 | fi ;; |
7713 | *) { echo "configure: error: "GDB: Unknown GDB_MULTI_ARCH value ${GDB_MULTI_ARCH}"" 1>&2; exit 1; };; | |
7714 | esac | |
7715 | ||
7716 | ||
96baa820 JM |
7717 | SUBDIRS="doc testsuite nlm" |
7718 | if test "${enable_multi_ice}" = "yes"; then | |
7719 | SUBDIRS="${SUBDIRS} multi-ice" | |
7720 | fi | |
7721 | ||
7722 | ||
7723 | ||
c906108c | 7724 | # If hostfile (XM_FILE) and/or targetfile (TM_FILE) and/or nativefile |
5a2402b8 AC |
7725 | # (NAT_FILE) is not set in config/*/*.m[ht] files, we link to an empty |
7726 | # version. | |
c906108c SS |
7727 | |
7728 | files= | |
7729 | links= | |
5a2402b8 | 7730 | |
c906108c | 7731 | rm -f xm.h |
5a2402b8 | 7732 | xm_h="" |
c906108c | 7733 | if test "${hostfile}" != ""; then |
5a2402b8 AC |
7734 | xm_h=xm.h |
7735 | GDB_XM_FILE="config/${gdb_host_cpu}/${hostfile}" | |
7736 | files="${files} ${GDB_XM_FILE}" | |
7737 | links="${links} xm.h" | |
7738 | cat >> confdefs.h <<EOF | |
7739 | #define GDB_XM_FILE ${GDB_XM_FILE} | |
7740 | EOF | |
7741 | ||
c906108c | 7742 | fi |
5a2402b8 AC |
7743 | |
7744 | ||
c906108c | 7745 | rm -f tm.h |
5a2402b8 | 7746 | tm_h="" |
c906108c | 7747 | if test "${targetfile}" != ""; then |
5a2402b8 AC |
7748 | tm_h=tm.h |
7749 | GDB_TM_FILE="config/${gdb_target_cpu}/${targetfile}" | |
7750 | files="${files} ${GDB_TM_FILE}" | |
7751 | links="${links} tm.h" | |
7752 | cat >> confdefs.h <<EOF | |
7753 | #define GDB_TM_FILE ${GDB_TM_FILE} | |
7754 | EOF | |
7755 | ||
c906108c | 7756 | fi |
5a2402b8 AC |
7757 | |
7758 | ||
c906108c | 7759 | rm -f nm.h |
5a2402b8 | 7760 | nm_h="" |
c906108c | 7761 | if test "${nativefile}" != ""; then |
5a2402b8 AC |
7762 | nm_h=nm.h |
7763 | GDB_NM_FILE="config/${gdb_host_cpu}/${nativefile}" | |
7764 | files="${files} ${GDB_NM_FILE}" | |
7765 | links="${links} nm.h" | |
7766 | cat >> confdefs.h <<EOF | |
7767 | #define GDB_NM_FILE ${GDB_NM_FILE} | |
7768 | EOF | |
7769 | ||
c906108c | 7770 | fi |
5a2402b8 AC |
7771 | |
7772 | ||
3fc11d3e | 7773 | echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6 |
b46cd165 | 7774 | echo "configure:7775: checking whether ln -s works" >&5 |
3fc11d3e JM |
7775 | if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then |
7776 | echo $ac_n "(cached) $ac_c" 1>&6 | |
7777 | else | |
7778 | rm -f conftestdata | |
7779 | if ln -s X conftestdata 2>/dev/null | |
7780 | then | |
7781 | rm -f conftestdata | |
7782 | ac_cv_prog_LN_S="ln -s" | |
7783 | else | |
7784 | ac_cv_prog_LN_S=ln | |
7785 | fi | |
7786 | fi | |
7787 | LN_S="$ac_cv_prog_LN_S" | |
7788 | if test "$ac_cv_prog_LN_S" = "ln -s"; then | |
7789 | echo "$ac_t""yes" 1>&6 | |
7790 | else | |
7791 | echo "$ac_t""no" 1>&6 | |
7792 | fi | |
7793 | ||
c906108c SS |
7794 | |
7795 | ||
7796 | ||
7797 | echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6 | |
b46cd165 | 7798 | echo "configure:7799: checking for Cygwin environment" >&5 |
c906108c SS |
7799 | if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then |
7800 | echo $ac_n "(cached) $ac_c" 1>&6 | |
7801 | else | |
7802 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 7803 | #line 7804 "configure" |
c906108c SS |
7804 | #include "confdefs.h" |
7805 | ||
7806 | int main() { | |
7807 | ||
7808 | #ifndef __CYGWIN__ | |
7809 | #define __CYGWIN__ __CYGWIN32__ | |
7810 | #endif | |
7811 | return __CYGWIN__; | |
7812 | ; return 0; } | |
7813 | EOF | |
b46cd165 | 7814 | if { (eval echo configure:7815: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
c906108c SS |
7815 | rm -rf conftest* |
7816 | ac_cv_cygwin=yes | |
7817 | else | |
7818 | echo "configure: failed program was:" >&5 | |
7819 | cat conftest.$ac_ext >&5 | |
7820 | rm -rf conftest* | |
7821 | ac_cv_cygwin=no | |
7822 | fi | |
7823 | rm -f conftest* | |
7824 | rm -f conftest* | |
7825 | fi | |
7826 | ||
7827 | echo "$ac_t""$ac_cv_cygwin" 1>&6 | |
7828 | CYGWIN= | |
7829 | test "$ac_cv_cygwin" = yes && CYGWIN=yes | |
7830 | echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6 | |
b46cd165 | 7831 | echo "configure:7832: checking for mingw32 environment" >&5 |
c906108c SS |
7832 | if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then |
7833 | echo $ac_n "(cached) $ac_c" 1>&6 | |
7834 | else | |
7835 | cat > conftest.$ac_ext <<EOF | |
b46cd165 | 7836 | #line 7837 "configure" |
c906108c SS |
7837 | #include "confdefs.h" |
7838 | ||
7839 | int main() { | |
7840 | return __MINGW32__; | |
7841 | ; return 0; } | |
7842 | EOF | |
b46cd165 | 7843 | if { (eval echo configure:7844: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
c906108c SS |
7844 | rm -rf conftest* |
7845 | ac_cv_mingw32=yes | |
7846 | else | |
7847 | echo "configure: failed program was:" >&5 | |
7848 | cat conftest.$ac_ext >&5 | |
7849 | rm -rf conftest* | |
7850 | ac_cv_mingw32=no | |
7851 | fi | |
7852 | rm -f conftest* | |
7853 | rm -f conftest* | |
7854 | fi | |
7855 | ||
7856 | echo "$ac_t""$ac_cv_mingw32" 1>&6 | |
7857 | MINGW32= | |
7858 | test "$ac_cv_mingw32" = yes && MINGW32=yes | |
7859 | ||
7860 | ||
7861 | echo $ac_n "checking for executable suffix""... $ac_c" 1>&6 | |
b46cd165 | 7862 | echo "configure:7863: checking for executable suffix" >&5 |
c906108c SS |
7863 | if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then |
7864 | echo $ac_n "(cached) $ac_c" 1>&6 | |
7865 | else | |
7866 | if test "$CYGWIN" = yes || test "$MINGW32" = yes; then | |
7867 | ac_cv_exeext=.exe | |
7868 | else | |
7869 | rm -f conftest* | |
7870 | echo 'int main () { return 0; }' > conftest.$ac_ext | |
7871 | ac_cv_exeext= | |
b46cd165 | 7872 | if { (eval echo configure:7873: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
c906108c SS |
7873 | for file in conftest.*; do |
7874 | case $file in | |
3b851bce | 7875 | *.c | *.o | *.obj | *.ilk | *.pdb) ;; |
c906108c SS |
7876 | *) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;; |
7877 | esac | |
7878 | done | |
7879 | else | |
7880 | { echo "configure: error: installation or configuration problem: compiler cannot create executables." 1>&2; exit 1; } | |
7881 | fi | |
7882 | rm -f conftest* | |
7883 | test x"${ac_cv_exeext}" = x && ac_cv_exeext=no | |
7884 | fi | |
7885 | fi | |
7886 | ||
7887 | EXEEXT="" | |
7888 | test x"${ac_cv_exeext}" != xno && EXEEXT=${ac_cv_exeext} | |
7889 | echo "$ac_t""${ac_cv_exeext}" 1>&6 | |
7890 | ac_exeext=$EXEEXT | |
7891 | ||
7892 | ||
7893 | subdirs="$configdirs" | |
7894 | ||
7895 | trap '' 1 2 15 | |
7896 | cat > confcache <<\EOF | |
7897 | # This file is a shell script that caches the results of configure | |
7898 | # tests run on this system so they can be shared between configure | |
7899 | # scripts and configure runs. It is not useful on other systems. | |
7900 | # If it contains results you don't want to keep, you may remove or edit it. | |
7901 | # | |
7902 | # By default, configure uses ./config.cache as the cache file, | |
7903 | # creating it if it does not exist already. You can give configure | |
7904 | # the --cache-file=FILE option to use a different cache file; that is | |
7905 | # what configure does when it calls configure scripts in | |
7906 | # subdirectories, so they share the cache. | |
7907 | # Giving --cache-file=/dev/null disables caching, for debugging configure. | |
7908 | # config.status only pays attention to the cache file if you give it the | |
7909 | # --recheck option to rerun configure. | |
7910 | # | |
7911 | EOF | |
7912 | # The following way of writing the cache mishandles newlines in values, | |
7913 | # but we know of no workaround that is simple, portable, and efficient. | |
7914 | # So, don't put newlines in cache variables' values. | |
7915 | # Ultrix sh set writes to stderr and can't be redirected directly, | |
7916 | # and sets the high bit in the cache file unless we assign to the vars. | |
7917 | (set) 2>&1 | | |
7918 | case `(ac_space=' '; set | grep ac_space) 2>&1` in | |
7919 | *ac_space=\ *) | |
7920 | # `set' does not quote correctly, so add quotes (double-quote substitution | |
7921 | # turns \\\\ into \\, and sed turns \\ into \). | |
7922 | sed -n \ | |
7923 | -e "s/'/'\\\\''/g" \ | |
7924 | -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p" | |
7925 | ;; | |
7926 | *) | |
7927 | # `set' quotes correctly as required by POSIX, so do not add quotes. | |
7928 | sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p' | |
7929 | ;; | |
7930 | esac >> confcache | |
7931 | if cmp -s $cache_file confcache; then | |
7932 | : | |
7933 | else | |
7934 | if test -w $cache_file; then | |
7935 | echo "updating cache $cache_file" | |
7936 | cat confcache > $cache_file | |
7937 | else | |
7938 | echo "not updating unwritable cache $cache_file" | |
7939 | fi | |
7940 | fi | |
7941 | rm -f confcache | |
7942 | ||
7943 | trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 | |
7944 | ||
7945 | test "x$prefix" = xNONE && prefix=$ac_default_prefix | |
7946 | # Let make expand exec_prefix. | |
7947 | test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' | |
7948 | ||
7949 | # Any assignment to VPATH causes Sun make to only execute | |
7950 | # the first set of double-colon rules, so remove it if not needed. | |
7951 | # If there is a colon in the path, we need to keep it. | |
7952 | if test "x$srcdir" = x.; then | |
7953 | ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d' | |
7954 | fi | |
7955 | ||
7956 | trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15 | |
7957 | ||
7958 | DEFS=-DHAVE_CONFIG_H | |
7959 | ||
7960 | # Without the "./", some shells look in PATH for config.status. | |
7961 | : ${CONFIG_STATUS=./config.status} | |
7962 | ||
7963 | echo creating $CONFIG_STATUS | |
7964 | rm -f $CONFIG_STATUS | |
7965 | cat > $CONFIG_STATUS <<EOF | |
7966 | #! /bin/sh | |
7967 | # Generated automatically by configure. | |
7968 | # Run this file to recreate the current configuration. | |
7969 | # This directory was configured as follows, | |
7970 | # on host `(hostname || uname -n) 2>/dev/null | sed 1q`: | |
7971 | # | |
7972 | # $0 $ac_configure_args | |
7973 | # | |
7974 | # Compiler output produced by configure, useful for debugging | |
7975 | # configure, is in ./config.log if it exists. | |
7976 | ||
7977 | ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]" | |
7978 | for ac_option | |
7979 | do | |
7980 | case "\$ac_option" in | |
7981 | -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) | |
7982 | echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion" | |
7983 | exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;; | |
7984 | -version | --version | --versio | --versi | --vers | --ver | --ve | --v) | |
7985 | echo "$CONFIG_STATUS generated by autoconf version 2.13" | |
7986 | exit 0 ;; | |
7987 | -help | --help | --hel | --he | --h) | |
7988 | echo "\$ac_cs_usage"; exit 0 ;; | |
7989 | *) echo "\$ac_cs_usage"; exit 1 ;; | |
7990 | esac | |
7991 | done | |
7992 | ||
7993 | ac_given_srcdir=$srcdir | |
7994 | ac_given_INSTALL="$INSTALL" | |
7995 | ||
ed952ac5 | 7996 | trap 'rm -fr `echo "Makefile .gdbinit:gdbinit.in config.h:config.in" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 |
c906108c SS |
7997 | EOF |
7998 | cat >> $CONFIG_STATUS <<EOF | |
7999 | ||
8000 | # Protect against being on the right side of a sed subst in config.status. | |
8001 | sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g; | |
8002 | s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF | |
8003 | $ac_vpsub | |
8004 | $extrasub | |
8005 | s%@SHELL@%$SHELL%g | |
8006 | s%@CFLAGS@%$CFLAGS%g | |
8007 | s%@CPPFLAGS@%$CPPFLAGS%g | |
8008 | s%@CXXFLAGS@%$CXXFLAGS%g | |
8009 | s%@FFLAGS@%$FFLAGS%g | |
8010 | s%@DEFS@%$DEFS%g | |
8011 | s%@LDFLAGS@%$LDFLAGS%g | |
8012 | s%@LIBS@%$LIBS%g | |
8013 | s%@exec_prefix@%$exec_prefix%g | |
8014 | s%@prefix@%$prefix%g | |
8015 | s%@program_transform_name@%$program_transform_name%g | |
8016 | s%@bindir@%$bindir%g | |
8017 | s%@sbindir@%$sbindir%g | |
8018 | s%@libexecdir@%$libexecdir%g | |
8019 | s%@datadir@%$datadir%g | |
8020 | s%@sysconfdir@%$sysconfdir%g | |
8021 | s%@sharedstatedir@%$sharedstatedir%g | |
8022 | s%@localstatedir@%$localstatedir%g | |
8023 | s%@libdir@%$libdir%g | |
8024 | s%@includedir@%$includedir%g | |
8025 | s%@oldincludedir@%$oldincludedir%g | |
8026 | s%@infodir@%$infodir%g | |
8027 | s%@mandir@%$mandir%g | |
413ccac7 AC |
8028 | s%@MAINTAINER_MODE_TRUE@%$MAINTAINER_MODE_TRUE%g |
8029 | s%@MAINTAINER_MODE_FALSE@%$MAINTAINER_MODE_FALSE%g | |
8030 | s%@MAINT@%$MAINT%g | |
c906108c SS |
8031 | s%@CC@%$CC%g |
8032 | s%@CPP@%$CPP%g | |
8033 | s%@host@%$host%g | |
8034 | s%@host_alias@%$host_alias%g | |
8035 | s%@host_cpu@%$host_cpu%g | |
8036 | s%@host_vendor@%$host_vendor%g | |
8037 | s%@host_os@%$host_os%g | |
8038 | s%@target@%$target%g | |
8039 | s%@target_alias@%$target_alias%g | |
8040 | s%@target_cpu@%$target_cpu%g | |
8041 | s%@target_vendor@%$target_vendor%g | |
8042 | s%@target_os@%$target_os%g | |
8043 | s%@build@%$build%g | |
8044 | s%@build_alias@%$build_alias%g | |
8045 | s%@build_cpu@%$build_cpu%g | |
8046 | s%@build_vendor@%$build_vendor%g | |
8047 | s%@build_os@%$build_os%g | |
8048 | s%@SET_MAKE@%$SET_MAKE%g | |
8049 | s%@RANLIB@%$RANLIB%g | |
8050 | s%@ALLOCA@%$ALLOCA%g | |
8051 | s%@USE_NLS@%$USE_NLS%g | |
8052 | s%@MSGFMT@%$MSGFMT%g | |
8053 | s%@GMSGFMT@%$GMSGFMT%g | |
8054 | s%@XGETTEXT@%$XGETTEXT%g | |
8055 | s%@USE_INCLUDED_LIBINTL@%$USE_INCLUDED_LIBINTL%g | |
8056 | s%@CATALOGS@%$CATALOGS%g | |
8057 | s%@CATOBJEXT@%$CATOBJEXT%g | |
8058 | s%@DATADIRNAME@%$DATADIRNAME%g | |
8059 | s%@GMOFILES@%$GMOFILES%g | |
8060 | s%@INSTOBJEXT@%$INSTOBJEXT%g | |
8061 | s%@INTLDEPS@%$INTLDEPS%g | |
8062 | s%@INTLLIBS@%$INTLLIBS%g | |
8063 | s%@INTLOBJS@%$INTLOBJS%g | |
8064 | s%@POFILES@%$POFILES%g | |
8065 | s%@POSUB@%$POSUB%g | |
8066 | s%@INCLUDE_LOCALE_H@%$INCLUDE_LOCALE_H%g | |
8067 | s%@GT_NO@%$GT_NO%g | |
8068 | s%@GT_YES@%$GT_YES%g | |
8069 | s%@MKINSTALLDIRS@%$MKINSTALLDIRS%g | |
8070 | s%@l@%$l%g | |
7a292a7a | 8071 | s%@AWK@%$AWK%g |
c906108c SS |
8072 | s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g |
8073 | s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g | |
8074 | s%@INSTALL_DATA@%$INSTALL_DATA%g | |
8075 | s%@AR@%$AR%g | |
95ca63c4 CF |
8076 | s%@DLLTOOL@%$DLLTOOL%g |
8077 | s%@WINDRES@%$WINDRES%g | |
c906108c | 8078 | s%@YACC@%$YACC%g |
75c6e08a | 8079 | s%@MIG@%$MIG%g |
c906108c | 8080 | s%@CONFIG_LDFLAGS@%$CONFIG_LDFLAGS%g |
c906108c | 8081 | s%@WARN_CFLAGS@%$WARN_CFLAGS%g |
104c1213 | 8082 | s%@WERROR_CFLAGS@%$WERROR_CFLAGS%g |
c906108c SS |
8083 | s%@MMALLOC_CFLAGS@%$MMALLOC_CFLAGS%g |
8084 | s%@MMALLOC@%$MMALLOC%g | |
88987551 | 8085 | s%@REGEX@%$REGEX%g |
aff38e61 | 8086 | s%@SER_HARDWIRE@%$SER_HARDWIRE%g |
c906108c | 8087 | s%@TERM_LIB@%$TERM_LIB%g |
cd0fc7c3 | 8088 | s%@WIN32LIBS@%$WIN32LIBS%g |
7a292a7a SS |
8089 | s%@LIBGUI@%$LIBGUI%g |
8090 | s%@GUI_CFLAGS_X@%$GUI_CFLAGS_X%g | |
7a292a7a SS |
8091 | s%@WIN32LDAPP@%$WIN32LDAPP%g |
8092 | s%@TCL_VERSION@%$TCL_VERSION%g | |
8093 | s%@TCL_MAJOR_VERSION@%$TCL_MAJOR_VERSION%g | |
8094 | s%@TCL_MINOR_VERSION@%$TCL_MINOR_VERSION%g | |
8095 | s%@TCL_CC@%$TCL_CC%g | |
8096 | s%@TCL_DEFS@%$TCL_DEFS%g | |
8097 | s%@TCL_SHLIB_CFLAGS@%$TCL_SHLIB_CFLAGS%g | |
8098 | s%@TCL_SHLIB_LD@%$TCL_SHLIB_LD%g | |
8099 | s%@TCL_SHLIB_LD_LIBS@%$TCL_SHLIB_LD_LIBS%g | |
8100 | s%@TCL_SHLIB_SUFFIX@%$TCL_SHLIB_SUFFIX%g | |
8101 | s%@TCL_DL_LIBS@%$TCL_DL_LIBS%g | |
8102 | s%@TCL_LD_FLAGS@%$TCL_LD_FLAGS%g | |
8103 | s%@TCL_LD_SEARCH_FLAGS@%$TCL_LD_SEARCH_FLAGS%g | |
8104 | s%@TCL_COMPAT_OBJS@%$TCL_COMPAT_OBJS%g | |
8105 | s%@TCL_RANLIB@%$TCL_RANLIB%g | |
8106 | s%@TCL_BUILD_LIB_SPEC@%$TCL_BUILD_LIB_SPEC%g | |
8107 | s%@TCL_LIB_SPEC@%$TCL_LIB_SPEC%g | |
8108 | s%@TCL_LIB_VERSIONS_OK@%$TCL_LIB_VERSIONS_OK%g | |
8109 | s%@TK_VERSION@%$TK_VERSION%g | |
8110 | s%@TK_DEFS@%$TK_DEFS%g | |
8111 | s%@TK_BUILD_INCLUDES@%$TK_BUILD_INCLUDES%g | |
8112 | s%@TK_XINCLUDES@%$TK_XINCLUDES%g | |
8113 | s%@TK_XLIBSW@%$TK_XLIBSW%g | |
8114 | s%@TK_BUILD_LIB_SPEC@%$TK_BUILD_LIB_SPEC%g | |
8115 | s%@TK_LIB_SPEC@%$TK_LIB_SPEC%g | |
8116 | s%@TCLHDIR@%$TCLHDIR%g | |
8117 | s%@TKHDIR@%$TKHDIR%g | |
8118 | s%@ITCLHDIR@%$ITCLHDIR%g | |
8119 | s%@ITKHDIR@%$ITKHDIR%g | |
8120 | s%@TIXHDIR@%$TIXHDIR%g | |
8121 | s%@ITCL_VERSION@%$ITCL_VERSION%g | |
8122 | s%@ITCL_DEFS@%$ITCL_DEFS%g | |
8123 | s%@ITCL_BUILD_INCLUDES@%$ITCL_BUILD_INCLUDES%g | |
8124 | s%@ITCL_BUILD_LIB_SPEC@%$ITCL_BUILD_LIB_SPEC%g | |
8125 | s%@ITCL_LIB_SPEC@%$ITCL_LIB_SPEC%g | |
8126 | s%@ITK_VERSION@%$ITK_VERSION%g | |
8127 | s%@ITK_DEFS@%$ITK_DEFS%g | |
8128 | s%@ITK_BUILD_INCLUDES@%$ITK_BUILD_INCLUDES%g | |
8129 | s%@ITK_BUILD_LIB_SPEC@%$ITK_BUILD_LIB_SPEC%g | |
8130 | s%@ITK_LIB_SPEC@%$ITK_LIB_SPEC%g | |
8131 | s%@TIX_VERSION@%$TIX_VERSION%g | |
8132 | s%@TIX_BUILD_LIB_SPEC@%$TIX_BUILD_LIB_SPEC%g | |
7a292a7a SS |
8133 | s%@X_CFLAGS@%$X_CFLAGS%g |
8134 | s%@X_LDFLAGS@%$X_LDFLAGS%g | |
8135 | s%@X_LIBS@%$X_LIBS%g | |
8136 | s%@ITCLLIB@%$ITCLLIB%g | |
8137 | s%@ITCL_DEPS@%$ITCL_DEPS%g | |
8138 | s%@ITKLIB@%$ITKLIB%g | |
8139 | s%@ITK_DEPS@%$ITK_DEPS%g | |
8140 | s%@TIXLIB@%$TIXLIB%g | |
8141 | s%@TIX_DEPS@%$TIX_DEPS%g | |
8142 | s%@GDBTKLIBS@%$GDBTKLIBS%g | |
8143 | s%@GDBTK_CFLAGS@%$GDBTK_CFLAGS%g | |
8144 | s%@IGNORE_SIM@%$IGNORE_SIM%g | |
8145 | s%@IGNORE_SIM_OBS@%$IGNORE_SIM_OBS%g | |
c906108c SS |
8146 | s%@ENABLE_CFLAGS@%$ENABLE_CFLAGS%g |
8147 | s%@CONFIG_OBS@%$CONFIG_OBS%g | |
b46cd165 | 8148 | s%@CONFIG_LOBS@%$CONFIG_LOBS%g |
c906108c SS |
8149 | s%@CONFIG_DEPS@%$CONFIG_DEPS%g |
8150 | s%@CONFIG_SRCS@%$CONFIG_SRCS%g | |
dfcd3bfb | 8151 | s%@CONFIG_INITS@%$CONFIG_INITS%g |
b3a90332 AC |
8152 | s%@CONFIG_ALL@%$CONFIG_ALL%g |
8153 | s%@CONFIG_CLEAN@%$CONFIG_CLEAN%g | |
e56ac5c3 AC |
8154 | s%@CONFIG_INSTALL@%$CONFIG_INSTALL%g |
8155 | s%@CONFIG_UNINSTALL@%$CONFIG_UNINSTALL%g | |
c906108c SS |
8156 | s%@HLDFLAGS@%$HLDFLAGS%g |
8157 | s%@HLDENV@%$HLDENV%g | |
8158 | s%@target_subdir@%$target_subdir%g | |
8159 | /@host_makefile_frag@/r $host_makefile_frag | |
8160 | s%@host_makefile_frag@%%g | |
8161 | /@target_makefile_frag@/r $target_makefile_frag | |
8162 | s%@target_makefile_frag@%%g | |
8163 | s%@frags@%$frags%g | |
96baa820 | 8164 | s%@SUBDIRS@%$SUBDIRS%g |
5a2402b8 AC |
8165 | s%@xm_h@%$xm_h%g |
8166 | s%@tm_h@%$tm_h%g | |
8167 | s%@nm_h@%$nm_h%g | |
7a292a7a | 8168 | s%@LN_S@%$LN_S%g |
c906108c SS |
8169 | s%@EXEEXT@%$EXEEXT%g |
8170 | s%@subdirs@%$subdirs%g | |
8171 | ||
8172 | CEOF | |
8173 | EOF | |
8174 | ||
8175 | cat >> $CONFIG_STATUS <<\EOF | |
8176 | ||
8177 | # Split the substitutions into bite-sized pieces for seds with | |
8178 | # small command number limits, like on Digital OSF/1 and HP-UX. | |
8179 | ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script. | |
8180 | ac_file=1 # Number of current file. | |
8181 | ac_beg=1 # First line for current file. | |
8182 | ac_end=$ac_max_sed_cmds # Line after last line for current file. | |
8183 | ac_more_lines=: | |
8184 | ac_sed_cmds="" | |
8185 | while $ac_more_lines; do | |
8186 | if test $ac_beg -gt 1; then | |
8187 | sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file | |
8188 | else | |
8189 | sed "${ac_end}q" conftest.subs > conftest.s$ac_file | |
8190 | fi | |
8191 | if test ! -s conftest.s$ac_file; then | |
8192 | ac_more_lines=false | |
8193 | rm -f conftest.s$ac_file | |
8194 | else | |
8195 | if test -z "$ac_sed_cmds"; then | |
8196 | ac_sed_cmds="sed -f conftest.s$ac_file" | |
8197 | else | |
8198 | ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file" | |
8199 | fi | |
8200 | ac_file=`expr $ac_file + 1` | |
8201 | ac_beg=$ac_end | |
8202 | ac_end=`expr $ac_end + $ac_max_sed_cmds` | |
8203 | fi | |
8204 | done | |
8205 | if test -z "$ac_sed_cmds"; then | |
8206 | ac_sed_cmds=cat | |
8207 | fi | |
8208 | EOF | |
8209 | ||
8210 | cat >> $CONFIG_STATUS <<EOF | |
8211 | ||
ed952ac5 | 8212 | CONFIG_FILES=\${CONFIG_FILES-"Makefile .gdbinit:gdbinit.in"} |
c906108c SS |
8213 | EOF |
8214 | cat >> $CONFIG_STATUS <<\EOF | |
8215 | for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then | |
8216 | # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". | |
8217 | case "$ac_file" in | |
8218 | *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'` | |
8219 | ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; | |
8220 | *) ac_file_in="${ac_file}.in" ;; | |
8221 | esac | |
8222 | ||
8223 | # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories. | |
8224 | ||
8225 | # Remove last slash and all that follows it. Not all systems have dirname. | |
8226 | ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` | |
8227 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then | |
8228 | # The file is in a subdirectory. | |
8229 | test ! -d "$ac_dir" && mkdir "$ac_dir" | |
8230 | ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`" | |
8231 | # A "../" for each directory in $ac_dir_suffix. | |
8232 | ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'` | |
8233 | else | |
8234 | ac_dir_suffix= ac_dots= | |
8235 | fi | |
8236 | ||
8237 | case "$ac_given_srcdir" in | |
8238 | .) srcdir=. | |
8239 | if test -z "$ac_dots"; then top_srcdir=. | |
8240 | else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;; | |
8241 | /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;; | |
8242 | *) # Relative path. | |
8243 | srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix" | |
8244 | top_srcdir="$ac_dots$ac_given_srcdir" ;; | |
8245 | esac | |
8246 | ||
8247 | case "$ac_given_INSTALL" in | |
8248 | [/$]*) INSTALL="$ac_given_INSTALL" ;; | |
8249 | *) INSTALL="$ac_dots$ac_given_INSTALL" ;; | |
8250 | esac | |
8251 | ||
8252 | echo creating "$ac_file" | |
8253 | rm -f "$ac_file" | |
8254 | configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure." | |
8255 | case "$ac_file" in | |
8256 | *Makefile*) ac_comsub="1i\\ | |
8257 | # $configure_input" ;; | |
8258 | *) ac_comsub= ;; | |
8259 | esac | |
8260 | ||
8261 | ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"` | |
8262 | sed -e "$ac_comsub | |
8263 | s%@configure_input@%$configure_input%g | |
8264 | s%@srcdir@%$srcdir%g | |
8265 | s%@top_srcdir@%$top_srcdir%g | |
8266 | s%@INSTALL@%$INSTALL%g | |
8267 | " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file | |
8268 | fi; done | |
8269 | rm -f conftest.s* | |
8270 | ||
8271 | # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where | |
8272 | # NAME is the cpp macro being defined and VALUE is the value it is being given. | |
8273 | # | |
8274 | # ac_d sets the value in "#define NAME VALUE" lines. | |
8275 | ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)' | |
8276 | ac_dB='\([ ][ ]*\)[^ ]*%\1#\2' | |
8277 | ac_dC='\3' | |
8278 | ac_dD='%g' | |
8279 | # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE". | |
8280 | ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' | |
8281 | ac_uB='\([ ]\)%\1#\2define\3' | |
8282 | ac_uC=' ' | |
8283 | ac_uD='\4%g' | |
8284 | # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE". | |
8285 | ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' | |
8286 | ac_eB='$%\1#\2define\3' | |
8287 | ac_eC=' ' | |
8288 | ac_eD='%g' | |
8289 | ||
8290 | if test "${CONFIG_HEADERS+set}" != set; then | |
8291 | EOF | |
8292 | cat >> $CONFIG_STATUS <<EOF | |
8293 | CONFIG_HEADERS="config.h:config.in" | |
8294 | EOF | |
8295 | cat >> $CONFIG_STATUS <<\EOF | |
8296 | fi | |
8297 | for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then | |
8298 | # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". | |
8299 | case "$ac_file" in | |
8300 | *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'` | |
8301 | ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; | |
8302 | *) ac_file_in="${ac_file}.in" ;; | |
8303 | esac | |
8304 | ||
8305 | echo creating $ac_file | |
8306 | ||
8307 | rm -f conftest.frag conftest.in conftest.out | |
8308 | ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"` | |
8309 | cat $ac_file_inputs > conftest.in | |
8310 | ||
8311 | EOF | |
8312 | ||
8313 | # Transform confdefs.h into a sed script conftest.vals that substitutes | |
8314 | # the proper values into config.h.in to produce config.h. And first: | |
8315 | # Protect against being on the right side of a sed subst in config.status. | |
8316 | # Protect against being in an unquoted here document in config.status. | |
8317 | rm -f conftest.vals | |
8318 | cat > conftest.hdr <<\EOF | |
8319 | s/[\\&%]/\\&/g | |
8320 | s%[\\$`]%\\&%g | |
8321 | s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp | |
8322 | s%ac_d%ac_u%gp | |
8323 | s%ac_u%ac_e%gp | |
8324 | EOF | |
8325 | sed -n -f conftest.hdr confdefs.h > conftest.vals | |
8326 | rm -f conftest.hdr | |
8327 | ||
8328 | # This sed command replaces #undef with comments. This is necessary, for | |
8329 | # example, in the case of _POSIX_SOURCE, which is predefined and required | |
8330 | # on some systems where configure will not decide to define it. | |
8331 | cat >> conftest.vals <<\EOF | |
8332 | s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */% | |
8333 | EOF | |
8334 | ||
8335 | # Break up conftest.vals because some shells have a limit on | |
8336 | # the size of here documents, and old seds have small limits too. | |
8337 | ||
8338 | rm -f conftest.tail | |
8339 | while : | |
8340 | do | |
8341 | ac_lines=`grep -c . conftest.vals` | |
8342 | # grep -c gives empty output for an empty file on some AIX systems. | |
8343 | if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi | |
8344 | # Write a limited-size here document to conftest.frag. | |
8345 | echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS | |
8346 | sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS | |
8347 | echo 'CEOF | |
8348 | sed -f conftest.frag conftest.in > conftest.out | |
8349 | rm -f conftest.in | |
8350 | mv conftest.out conftest.in | |
8351 | ' >> $CONFIG_STATUS | |
8352 | sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail | |
8353 | rm -f conftest.vals | |
8354 | mv conftest.tail conftest.vals | |
8355 | done | |
8356 | rm -f conftest.vals | |
8357 | ||
8358 | cat >> $CONFIG_STATUS <<\EOF | |
8359 | rm -f conftest.frag conftest.h | |
8360 | echo "/* $ac_file. Generated automatically by configure. */" > conftest.h | |
8361 | cat conftest.in >> conftest.h | |
8362 | rm -f conftest.in | |
8363 | if cmp -s $ac_file conftest.h 2>/dev/null; then | |
8364 | echo "$ac_file is unchanged" | |
8365 | rm -f conftest.h | |
8366 | else | |
8367 | # Remove last slash and all that follows it. Not all systems have dirname. | |
8368 | ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` | |
8369 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then | |
8370 | # The file is in a subdirectory. | |
8371 | test ! -d "$ac_dir" && mkdir "$ac_dir" | |
8372 | fi | |
8373 | rm -f $ac_file | |
8374 | mv conftest.h $ac_file | |
8375 | fi | |
8376 | fi; done | |
8377 | ||
8378 | EOF | |
8379 | ||
8380 | cat >> $CONFIG_STATUS <<EOF | |
8381 | ac_sources="$files" | |
8382 | ac_dests="$links" | |
8383 | EOF | |
8384 | ||
8385 | cat >> $CONFIG_STATUS <<\EOF | |
8386 | srcdir=$ac_given_srcdir | |
8387 | while test -n "$ac_sources"; do | |
8388 | set $ac_dests; ac_dest=$1; shift; ac_dests=$* | |
8389 | set $ac_sources; ac_source=$1; shift; ac_sources=$* | |
8390 | ||
8391 | echo "linking $srcdir/$ac_source to $ac_dest" | |
8392 | ||
8393 | if test ! -r $srcdir/$ac_source; then | |
8394 | { echo "configure: error: $srcdir/$ac_source: File not found" 1>&2; exit 1; } | |
8395 | fi | |
8396 | rm -f $ac_dest | |
8397 | ||
8398 | # Make relative symlinks. | |
8399 | # Remove last slash and all that follows it. Not all systems have dirname. | |
8400 | ac_dest_dir=`echo $ac_dest|sed 's%/[^/][^/]*$%%'` | |
8401 | if test "$ac_dest_dir" != "$ac_dest" && test "$ac_dest_dir" != .; then | |
8402 | # The dest file is in a subdirectory. | |
8403 | test ! -d "$ac_dest_dir" && mkdir "$ac_dest_dir" | |
8404 | ac_dest_dir_suffix="/`echo $ac_dest_dir|sed 's%^\./%%'`" | |
8405 | # A "../" for each directory in $ac_dest_dir_suffix. | |
8406 | ac_dots=`echo $ac_dest_dir_suffix|sed 's%/[^/]*%../%g'` | |
8407 | else | |
8408 | ac_dest_dir_suffix= ac_dots= | |
8409 | fi | |
8410 | ||
8411 | case "$srcdir" in | |
8412 | [/$]*) ac_rel_source="$srcdir/$ac_source" ;; | |
8413 | *) ac_rel_source="$ac_dots$srcdir/$ac_source" ;; | |
8414 | esac | |
8415 | ||
8416 | # Make a symlink if possible; otherwise try a hard link. | |
8417 | if ln -s $ac_rel_source $ac_dest 2>/dev/null || | |
8418 | ln $srcdir/$ac_source $ac_dest; then : | |
8419 | else | |
8420 | { echo "configure: error: can not link $ac_dest to $srcdir/$ac_source" 1>&2; exit 1; } | |
8421 | fi | |
8422 | done | |
8423 | EOF | |
8424 | cat >> $CONFIG_STATUS <<EOF | |
8425 | ||
8426 | gdb_host_cpu=$gdb_host_cpu | |
8427 | gdb_target_cpu=$gdb_target_cpu | |
8428 | nativefile=$nativefile | |
8429 | ||
8430 | EOF | |
8431 | cat >> $CONFIG_STATUS <<\EOF | |
8432 | ||
8433 | if test "${nativefile}" = ""; then | |
8434 | sed -e '/^NATDEPFILES[ ]*=[ ]*/s//# NATDEPFILES=/' \ | |
8435 | < Makefile > Makefile.tem | |
8436 | mv -f Makefile.tem Makefile | |
8437 | fi | |
8438 | ||
8439 | sed -e '/^TM_FILE[ ]*=/s,^TM_FILE[ ]*=[ ]*,&config/'"${gdb_target_cpu}"'/, | |
8440 | /^XM_FILE[ ]*=/s,^XM_FILE[ ]*=[ ]*,&config/'"${gdb_host_cpu}"'/, | |
8441 | /^NAT_FILE[ ]*=/s,^NAT_FILE[ ]*=[ ]*,&config/'"${gdb_host_cpu}"'/,' <Makefile >Makefile.tmp | |
8442 | mv -f Makefile.tmp Makefile | |
8443 | ||
2acceee2 | 8444 | |
c906108c SS |
8445 | case x$CONFIG_HEADERS in |
8446 | xconfig.h:config.in) | |
8447 | echo > stamp-h ;; | |
8448 | esac | |
8449 | ||
8450 | exit 0 | |
8451 | EOF | |
8452 | chmod +x $CONFIG_STATUS | |
8453 | rm -fr confdefs* $ac_clean_files | |
8454 | test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1 | |
8455 | ||
8456 | if test "$no_recursion" != yes; then | |
8457 | ||
8458 | # Remove --cache-file and --srcdir arguments so they do not pile up. | |
8459 | ac_sub_configure_args= | |
8460 | ac_prev= | |
8461 | for ac_arg in $ac_configure_args; do | |
8462 | if test -n "$ac_prev"; then | |
8463 | ac_prev= | |
8464 | continue | |
8465 | fi | |
8466 | case "$ac_arg" in | |
8467 | -cache-file | --cache-file | --cache-fil | --cache-fi \ | |
8468 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) | |
8469 | ac_prev=cache_file ;; | |
8470 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | |
8471 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) | |
8472 | ;; | |
8473 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) | |
8474 | ac_prev=srcdir ;; | |
8475 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) | |
8476 | ;; | |
8477 | *) ac_sub_configure_args="$ac_sub_configure_args $ac_arg" ;; | |
8478 | esac | |
8479 | done | |
8480 | ||
8481 | for ac_config_dir in $configdirs; do | |
8482 | ||
8483 | # Do not complain, so a configure script can configure whichever | |
8484 | # parts of a large source tree are present. | |
8485 | if test ! -d $srcdir/$ac_config_dir; then | |
8486 | continue | |
8487 | fi | |
8488 | ||
8489 | echo configuring in $ac_config_dir | |
8490 | ||
8491 | case "$srcdir" in | |
8492 | .) ;; | |
8493 | *) | |
8494 | if test -d ./$ac_config_dir || mkdir ./$ac_config_dir; then :; | |
8495 | else | |
8496 | { echo "configure: error: can not create `pwd`/$ac_config_dir" 1>&2; exit 1; } | |
8497 | fi | |
8498 | ;; | |
8499 | esac | |
8500 | ||
8501 | ac_popdir=`pwd` | |
8502 | cd $ac_config_dir | |
8503 | ||
8504 | # A "../" for each directory in /$ac_config_dir. | |
8505 | ac_dots=`echo $ac_config_dir|sed -e 's%^\./%%' -e 's%[^/]$%&/%' -e 's%[^/]*/%../%g'` | |
8506 | ||
8507 | case "$srcdir" in | |
8508 | .) # No --srcdir option. We are building in place. | |
8509 | ac_sub_srcdir=$srcdir ;; | |
8510 | /*) # Absolute path. | |
8511 | ac_sub_srcdir=$srcdir/$ac_config_dir ;; | |
8512 | *) # Relative path. | |
8513 | ac_sub_srcdir=$ac_dots$srcdir/$ac_config_dir ;; | |
8514 | esac | |
8515 | ||
8516 | # Check for guested configure; otherwise get Cygnus style configure. | |
8517 | if test -f $ac_sub_srcdir/configure; then | |
8518 | ac_sub_configure=$ac_sub_srcdir/configure | |
8519 | elif test -f $ac_sub_srcdir/configure.in; then | |
8520 | ac_sub_configure=$ac_configure | |
8521 | else | |
8522 | echo "configure: warning: no configuration information is in $ac_config_dir" 1>&2 | |
8523 | ac_sub_configure= | |
8524 | fi | |
8525 | ||
8526 | # The recursion is here. | |
8527 | if test -n "$ac_sub_configure"; then | |
8528 | ||
8529 | # Make the cache file name correct relative to the subdirectory. | |
8530 | case "$cache_file" in | |
8531 | /*) ac_sub_cache_file=$cache_file ;; | |
8532 | *) # Relative path. | |
8533 | ac_sub_cache_file="$ac_dots$cache_file" ;; | |
8534 | esac | |
8535 | case "$ac_given_INSTALL" in | |
8536 | [/$]*) INSTALL="$ac_given_INSTALL" ;; | |
8537 | *) INSTALL="$ac_dots$ac_given_INSTALL" ;; | |
8538 | esac | |
8539 | ||
8540 | echo "running ${CONFIG_SHELL-/bin/sh} $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_sub_srcdir" | |
8541 | # The eval makes quoting arguments work. | |
8542 | if eval ${CONFIG_SHELL-/bin/sh} $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_sub_srcdir | |
8543 | then : | |
8544 | else | |
8545 | { echo "configure: error: $ac_sub_configure failed for $ac_config_dir" 1>&2; exit 1; } | |
8546 | fi | |
8547 | fi | |
8548 | ||
8549 | cd $ac_popdir | |
8550 | done | |
8551 | fi | |
8552 | ||
8553 | ||
8554 | exit 0 |