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