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