Commit | Line | Data |
---|---|---|
252b5132 | 1 | #! /bin/sh |
6be7c12c | 2 | |
252b5132 | 3 | # Guess values for system-dependent variables and create Makefiles. |
6be7c12c AO |
4 | # Generated automatically using autoconf version 2.13 |
5 | # Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc. | |
252b5132 RH |
6 | # |
7 | # This configure script is free software; the Free Software Foundation | |
8 | # gives unlimited permission to copy, distribute and modify it. | |
9 | ||
6be7c12c AO |
10 | # Defaults: |
11 | ac_help= | |
252b5132 | 12 | ac_default_prefix=/usr/local |
6be7c12c AO |
13 | # Any additions from configure.in: |
14 | ac_help="$ac_help | |
15 | --enable-shared[=PKGS] build shared libraries [default=no]" | |
16 | ac_help="$ac_help | |
17 | --enable-static[=PKGS] build static libraries [default=yes]" | |
18 | ac_help="$ac_help | |
19 | --enable-fast-install[=PKGS] optimize for fast installation [default=yes]" | |
20 | ac_help="$ac_help | |
21 | --with-gnu-ld assume the C compiler uses GNU ld [default=no]" | |
22 | ac_help="$ac_help | |
23 | --disable-libtool-lock avoid locking (might break parallel builds)" | |
24 | ac_help="$ac_help | |
25 | --with-pic try to use only PIC/non-PIC objects [default=use both]" | |
26 | ac_help="$ac_help | |
27 | --enable-64-bit-bfd 64-bit support (on hosts with narrower word sizes)" | |
28 | ac_help="$ac_help | |
29 | --enable-targets alternative target configurations" | |
30 | ac_help="$ac_help | |
31 | --enable-commonbfdlib build shared BFD/opcodes/libiberty library" | |
32 | ac_help="$ac_help | |
33 | --with-mmap try using mmap for BFD input files if available" | |
34 | ac_help="$ac_help | |
35 | --enable-build-warnings Enable build-time compiler warnings if gcc is used" | |
36 | ac_help="$ac_help | |
37 | --enable-maintainer-mode enable make rules and dependencies not useful | |
38 | (and sometimes confusing) to the casual installer" | |
a703a6ea | 39 | ac_help="$ac_help |
6a457e5c | 40 | --enable-install-libbfd controls installation of libbfd and related headers" |
6be7c12c AO |
41 | ac_help="$ac_help |
42 | --disable-nls do not use Native Language Support" | |
43 | ac_help="$ac_help | |
44 | --with-included-gettext use the GNU gettext library included here" | |
252b5132 RH |
45 | |
46 | # Initialize some variables set by options. | |
47 | # The variables have the same names as the options, with | |
48 | # dashes changed to underlines. | |
6be7c12c AO |
49 | build=NONE |
50 | cache_file=./config.cache | |
252b5132 | 51 | exec_prefix=NONE |
6be7c12c | 52 | host=NONE |
252b5132 | 53 | no_create= |
6be7c12c | 54 | nonopt=NONE |
252b5132 RH |
55 | no_recursion= |
56 | prefix=NONE | |
57 | program_prefix=NONE | |
58 | program_suffix=NONE | |
59 | program_transform_name=s,x,x, | |
60 | silent= | |
61 | site= | |
c6f8758f | 62 | sitefile= |
252b5132 | 63 | srcdir= |
6be7c12c | 64 | target=NONE |
252b5132 RH |
65 | verbose= |
66 | x_includes=NONE | |
67 | x_libraries=NONE | |
68 | bindir='${exec_prefix}/bin' | |
69 | sbindir='${exec_prefix}/sbin' | |
70 | libexecdir='${exec_prefix}/libexec' | |
71 | datadir='${prefix}/share' | |
72 | sysconfdir='${prefix}/etc' | |
73 | sharedstatedir='${prefix}/com' | |
74 | localstatedir='${prefix}/var' | |
75 | libdir='${exec_prefix}/lib' | |
76 | includedir='${prefix}/include' | |
77 | oldincludedir='/usr/include' | |
78 | infodir='${prefix}/info' | |
79 | mandir='${prefix}/man' | |
80 | ||
6be7c12c AO |
81 | # Initialize some other variables. |
82 | subdirs= | |
83 | MFLAGS= MAKEFLAGS= | |
84 | SHELL=${CONFIG_SHELL-/bin/sh} | |
85 | # Maximum number of lines to put in a shell here document. | |
86 | ac_max_here_lines=12 | |
252b5132 RH |
87 | |
88 | ac_prev= | |
89 | for ac_option | |
90 | do | |
6be7c12c | 91 | |
252b5132 RH |
92 | # If the previous option needs an argument, assign it. |
93 | if test -n "$ac_prev"; then | |
94 | eval "$ac_prev=\$ac_option" | |
95 | ac_prev= | |
96 | continue | |
97 | fi | |
98 | ||
6be7c12c AO |
99 | case "$ac_option" in |
100 | -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;; | |
101 | *) ac_optarg= ;; | |
102 | esac | |
252b5132 RH |
103 | |
104 | # Accept the important Cygnus configure options, so we can diagnose typos. | |
105 | ||
6be7c12c | 106 | case "$ac_option" in |
252b5132 RH |
107 | |
108 | -bindir | --bindir | --bindi | --bind | --bin | --bi) | |
109 | ac_prev=bindir ;; | |
110 | -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) | |
6be7c12c | 111 | bindir="$ac_optarg" ;; |
252b5132 RH |
112 | |
113 | -build | --build | --buil | --bui | --bu) | |
6be7c12c | 114 | ac_prev=build ;; |
252b5132 | 115 | -build=* | --build=* | --buil=* | --bui=* | --bu=*) |
6be7c12c | 116 | build="$ac_optarg" ;; |
252b5132 RH |
117 | |
118 | -cache-file | --cache-file | --cache-fil | --cache-fi \ | |
119 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) | |
120 | ac_prev=cache_file ;; | |
121 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | |
122 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) | |
6be7c12c | 123 | cache_file="$ac_optarg" ;; |
252b5132 RH |
124 | |
125 | -datadir | --datadir | --datadi | --datad | --data | --dat | --da) | |
126 | ac_prev=datadir ;; | |
127 | -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \ | |
128 | | --da=*) | |
6be7c12c | 129 | datadir="$ac_optarg" ;; |
252b5132 RH |
130 | |
131 | -disable-* | --disable-*) | |
6be7c12c | 132 | ac_feature=`echo $ac_option|sed -e 's/-*disable-//'` |
252b5132 | 133 | # Reject names that are not valid shell variable names. |
6be7c12c AO |
134 | if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then |
135 | { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } | |
136 | fi | |
137 | ac_feature=`echo $ac_feature| sed 's/-/_/g'` | |
138 | eval "enable_${ac_feature}=no" ;; | |
252b5132 RH |
139 | |
140 | -enable-* | --enable-*) | |
6be7c12c | 141 | ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'` |
252b5132 | 142 | # Reject names that are not valid shell variable names. |
6be7c12c AO |
143 | if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then |
144 | { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } | |
145 | fi | |
146 | ac_feature=`echo $ac_feature| sed 's/-/_/g'` | |
147 | case "$ac_option" in | |
148 | *=*) ;; | |
252b5132 RH |
149 | *) ac_optarg=yes ;; |
150 | esac | |
6be7c12c | 151 | eval "enable_${ac_feature}='$ac_optarg'" ;; |
252b5132 RH |
152 | |
153 | -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ | |
154 | | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ | |
155 | | --exec | --exe | --ex) | |
156 | ac_prev=exec_prefix ;; | |
157 | -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ | |
158 | | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ | |
159 | | --exec=* | --exe=* | --ex=*) | |
6be7c12c | 160 | exec_prefix="$ac_optarg" ;; |
252b5132 RH |
161 | |
162 | -gas | --gas | --ga | --g) | |
163 | # Obsolete; use --with-gas. | |
164 | with_gas=yes ;; | |
165 | ||
6be7c12c AO |
166 | -help | --help | --hel | --he) |
167 | # Omit some internal or obsolete options to make the list less imposing. | |
168 | # This message is too long to be a string in the A/UX 3.1 sh. | |
169 | cat << EOF | |
170 | Usage: configure [options] [host] | |
171 | Options: [defaults in brackets after descriptions] | |
172 | Configuration: | |
173 | --cache-file=FILE cache test results in FILE | |
174 | --help print this message | |
175 | --no-create do not create output files | |
176 | --quiet, --silent do not print \`checking...' messages | |
c6f8758f | 177 | --site-file=FILE use FILE as the site file |
6be7c12c AO |
178 | --version print the version of autoconf that created configure |
179 | Directory and file names: | |
180 | --prefix=PREFIX install architecture-independent files in PREFIX | |
181 | [$ac_default_prefix] | |
182 | --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX | |
183 | [same as prefix] | |
184 | --bindir=DIR user executables in DIR [EPREFIX/bin] | |
185 | --sbindir=DIR system admin executables in DIR [EPREFIX/sbin] | |
186 | --libexecdir=DIR program executables in DIR [EPREFIX/libexec] | |
187 | --datadir=DIR read-only architecture-independent data in DIR | |
188 | [PREFIX/share] | |
189 | --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc] | |
190 | --sharedstatedir=DIR modifiable architecture-independent data in DIR | |
191 | [PREFIX/com] | |
192 | --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var] | |
193 | --libdir=DIR object code libraries in DIR [EPREFIX/lib] | |
194 | --includedir=DIR C header files in DIR [PREFIX/include] | |
195 | --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include] | |
196 | --infodir=DIR info documentation in DIR [PREFIX/info] | |
197 | --mandir=DIR man documentation in DIR [PREFIX/man] | |
198 | --srcdir=DIR find the sources in DIR [configure dir or ..] | |
199 | --program-prefix=PREFIX prepend PREFIX to installed program names | |
200 | --program-suffix=SUFFIX append SUFFIX to installed program names | |
201 | --program-transform-name=PROGRAM | |
202 | run sed PROGRAM on installed program names | |
203 | EOF | |
204 | cat << EOF | |
205 | Host type: | |
206 | --build=BUILD configure for building on BUILD [BUILD=HOST] | |
207 | --host=HOST configure for HOST [guessed] | |
208 | --target=TARGET configure for TARGET [TARGET=HOST] | |
209 | Features and packages: | |
210 | --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) | |
211 | --enable-FEATURE[=ARG] include FEATURE [ARG=yes] | |
212 | --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] | |
213 | --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) | |
214 | --x-includes=DIR X include files are in DIR | |
215 | --x-libraries=DIR X library files are in DIR | |
216 | EOF | |
217 | if test -n "$ac_help"; then | |
218 | echo "--enable and --with options recognized:$ac_help" | |
219 | fi | |
220 | exit 0 ;; | |
252b5132 RH |
221 | |
222 | -host | --host | --hos | --ho) | |
6be7c12c | 223 | ac_prev=host ;; |
252b5132 | 224 | -host=* | --host=* | --hos=* | --ho=*) |
6be7c12c | 225 | host="$ac_optarg" ;; |
252b5132 RH |
226 | |
227 | -includedir | --includedir | --includedi | --included | --include \ | |
228 | | --includ | --inclu | --incl | --inc) | |
229 | ac_prev=includedir ;; | |
230 | -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ | |
231 | | --includ=* | --inclu=* | --incl=* | --inc=*) | |
6be7c12c | 232 | includedir="$ac_optarg" ;; |
252b5132 RH |
233 | |
234 | -infodir | --infodir | --infodi | --infod | --info | --inf) | |
235 | ac_prev=infodir ;; | |
236 | -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) | |
6be7c12c | 237 | infodir="$ac_optarg" ;; |
252b5132 RH |
238 | |
239 | -libdir | --libdir | --libdi | --libd) | |
240 | ac_prev=libdir ;; | |
241 | -libdir=* | --libdir=* | --libdi=* | --libd=*) | |
6be7c12c | 242 | libdir="$ac_optarg" ;; |
252b5132 RH |
243 | |
244 | -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ | |
245 | | --libexe | --libex | --libe) | |
246 | ac_prev=libexecdir ;; | |
247 | -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ | |
248 | | --libexe=* | --libex=* | --libe=*) | |
6be7c12c | 249 | libexecdir="$ac_optarg" ;; |
252b5132 RH |
250 | |
251 | -localstatedir | --localstatedir | --localstatedi | --localstated \ | |
252 | | --localstate | --localstat | --localsta | --localst \ | |
253 | | --locals | --local | --loca | --loc | --lo) | |
254 | ac_prev=localstatedir ;; | |
255 | -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ | |
256 | | --localstate=* | --localstat=* | --localsta=* | --localst=* \ | |
257 | | --locals=* | --local=* | --loca=* | --loc=* | --lo=*) | |
6be7c12c | 258 | localstatedir="$ac_optarg" ;; |
252b5132 RH |
259 | |
260 | -mandir | --mandir | --mandi | --mand | --man | --ma | --m) | |
261 | ac_prev=mandir ;; | |
262 | -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) | |
6be7c12c | 263 | mandir="$ac_optarg" ;; |
252b5132 RH |
264 | |
265 | -nfp | --nfp | --nf) | |
266 | # Obsolete; use --without-fp. | |
267 | with_fp=no ;; | |
268 | ||
269 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | |
270 | | --no-cr | --no-c) | |
271 | no_create=yes ;; | |
272 | ||
273 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ | |
274 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) | |
275 | no_recursion=yes ;; | |
276 | ||
277 | -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ | |
278 | | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ | |
279 | | --oldin | --oldi | --old | --ol | --o) | |
280 | ac_prev=oldincludedir ;; | |
281 | -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ | |
282 | | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ | |
283 | | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) | |
6be7c12c | 284 | oldincludedir="$ac_optarg" ;; |
252b5132 RH |
285 | |
286 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) | |
287 | ac_prev=prefix ;; | |
288 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) | |
6be7c12c | 289 | prefix="$ac_optarg" ;; |
252b5132 RH |
290 | |
291 | -program-prefix | --program-prefix | --program-prefi | --program-pref \ | |
292 | | --program-pre | --program-pr | --program-p) | |
293 | ac_prev=program_prefix ;; | |
294 | -program-prefix=* | --program-prefix=* | --program-prefi=* \ | |
295 | | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) | |
6be7c12c | 296 | program_prefix="$ac_optarg" ;; |
252b5132 RH |
297 | |
298 | -program-suffix | --program-suffix | --program-suffi | --program-suff \ | |
299 | | --program-suf | --program-su | --program-s) | |
300 | ac_prev=program_suffix ;; | |
301 | -program-suffix=* | --program-suffix=* | --program-suffi=* \ | |
302 | | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) | |
6be7c12c | 303 | program_suffix="$ac_optarg" ;; |
252b5132 RH |
304 | |
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 | ac_prev=program_transform_name ;; | |
313 | -program-transform-name=* | --program-transform-name=* \ | |
314 | | --program-transform-nam=* | --program-transform-na=* \ | |
315 | | --program-transform-n=* | --program-transform-=* \ | |
316 | | --program-transform=* | --program-transfor=* \ | |
317 | | --program-transfo=* | --program-transf=* \ | |
318 | | --program-trans=* | --program-tran=* \ | |
319 | | --progr-tra=* | --program-tr=* | --program-t=*) | |
6be7c12c | 320 | program_transform_name="$ac_optarg" ;; |
252b5132 RH |
321 | |
322 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | |
323 | | -silent | --silent | --silen | --sile | --sil) | |
324 | silent=yes ;; | |
325 | ||
326 | -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) | |
327 | ac_prev=sbindir ;; | |
328 | -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ | |
329 | | --sbi=* | --sb=*) | |
6be7c12c | 330 | sbindir="$ac_optarg" ;; |
252b5132 RH |
331 | |
332 | -sharedstatedir | --sharedstatedir | --sharedstatedi \ | |
333 | | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ | |
334 | | --sharedst | --shareds | --shared | --share | --shar \ | |
335 | | --sha | --sh) | |
336 | ac_prev=sharedstatedir ;; | |
337 | -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ | |
338 | | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ | |
339 | | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ | |
340 | | --sha=* | --sh=*) | |
6be7c12c | 341 | sharedstatedir="$ac_optarg" ;; |
252b5132 RH |
342 | |
343 | -site | --site | --sit) | |
344 | ac_prev=site ;; | |
345 | -site=* | --site=* | --sit=*) | |
6be7c12c AO |
346 | site="$ac_optarg" ;; |
347 | ||
c6f8758f NC |
348 | -site-file | --site-file | --site-fil | --site-fi | --site-f) |
349 | ac_prev=sitefile ;; | |
350 | -site-file=* | --site-file=* | --site-fil=* | --site-fi=* | --site-f=*) | |
351 | sitefile="$ac_optarg" ;; | |
352 | ||
252b5132 RH |
353 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) |
354 | ac_prev=srcdir ;; | |
355 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) | |
6be7c12c | 356 | srcdir="$ac_optarg" ;; |
252b5132 RH |
357 | |
358 | -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ | |
359 | | --syscon | --sysco | --sysc | --sys | --sy) | |
360 | ac_prev=sysconfdir ;; | |
361 | -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ | |
362 | | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) | |
6be7c12c | 363 | sysconfdir="$ac_optarg" ;; |
252b5132 RH |
364 | |
365 | -target | --target | --targe | --targ | --tar | --ta | --t) | |
6be7c12c | 366 | ac_prev=target ;; |
252b5132 | 367 | -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) |
6be7c12c | 368 | target="$ac_optarg" ;; |
252b5132 RH |
369 | |
370 | -v | -verbose | --verbose | --verbos | --verbo | --verb) | |
371 | verbose=yes ;; | |
372 | ||
6be7c12c AO |
373 | -version | --version | --versio | --versi | --vers) |
374 | echo "configure generated by autoconf version 2.13" | |
375 | exit 0 ;; | |
252b5132 RH |
376 | |
377 | -with-* | --with-*) | |
6be7c12c | 378 | ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'` |
252b5132 | 379 | # Reject names that are not valid shell variable names. |
6be7c12c AO |
380 | if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then |
381 | { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } | |
382 | fi | |
252b5132 | 383 | ac_package=`echo $ac_package| sed 's/-/_/g'` |
6be7c12c AO |
384 | case "$ac_option" in |
385 | *=*) ;; | |
252b5132 RH |
386 | *) ac_optarg=yes ;; |
387 | esac | |
6be7c12c | 388 | eval "with_${ac_package}='$ac_optarg'" ;; |
252b5132 RH |
389 | |
390 | -without-* | --without-*) | |
6be7c12c | 391 | ac_package=`echo $ac_option|sed -e 's/-*without-//'` |
252b5132 | 392 | # Reject names that are not valid shell variable names. |
6be7c12c AO |
393 | if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then |
394 | { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } | |
395 | fi | |
396 | ac_package=`echo $ac_package| sed 's/-/_/g'` | |
397 | eval "with_${ac_package}=no" ;; | |
252b5132 RH |
398 | |
399 | --x) | |
400 | # Obsolete; use --with-x. | |
401 | with_x=yes ;; | |
402 | ||
403 | -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ | |
404 | | --x-incl | --x-inc | --x-in | --x-i) | |
405 | ac_prev=x_includes ;; | |
406 | -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ | |
407 | | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) | |
6be7c12c | 408 | x_includes="$ac_optarg" ;; |
252b5132 RH |
409 | |
410 | -x-libraries | --x-libraries | --x-librarie | --x-librari \ | |
411 | | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) | |
412 | ac_prev=x_libraries ;; | |
413 | -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ | |
414 | | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) | |
6be7c12c | 415 | x_libraries="$ac_optarg" ;; |
252b5132 | 416 | |
6be7c12c | 417 | -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; } |
252b5132 RH |
418 | ;; |
419 | ||
420 | *) | |
6be7c12c AO |
421 | if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then |
422 | echo "configure: warning: $ac_option: invalid host type" 1>&2 | |
423 | fi | |
424 | if test "x$nonopt" != xNONE; then | |
425 | { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } | |
426 | fi | |
427 | nonopt="$ac_option" | |
252b5132 RH |
428 | ;; |
429 | ||
430 | esac | |
431 | done | |
432 | ||
433 | if test -n "$ac_prev"; then | |
6be7c12c AO |
434 | { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; } |
435 | fi | |
436 | ||
437 | trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 | |
438 | ||
439 | # File descriptor usage: | |
440 | # 0 standard input | |
441 | # 1 file creation | |
442 | # 2 errors and warnings | |
443 | # 3 some systems may open it to /dev/tty | |
444 | # 4 used on the Kubota Titan | |
445 | # 6 checking for... messages and results | |
446 | # 5 compiler messages saved in config.log | |
447 | if test "$silent" = yes; then | |
448 | exec 6>/dev/null | |
449 | else | |
450 | exec 6>&1 | |
252b5132 | 451 | fi |
6be7c12c | 452 | exec 5>./config.log |
252b5132 | 453 | |
6be7c12c AO |
454 | echo "\ |
455 | This file contains any messages produced by compilers while | |
456 | running configure, to aid debugging if configure makes a mistake. | |
457 | " 1>&5 | |
458 | ||
459 | # Strip out --no-create and --no-recursion so they do not pile up. | |
460 | # Also quote any args containing shell metacharacters. | |
461 | ac_configure_args= | |
462 | for ac_arg | |
252b5132 | 463 | do |
6be7c12c AO |
464 | case "$ac_arg" in |
465 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | |
466 | | --no-cr | --no-c) ;; | |
467 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ | |
468 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;; | |
469 | *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*) | |
470 | ac_configure_args="$ac_configure_args '$ac_arg'" ;; | |
471 | *) ac_configure_args="$ac_configure_args $ac_arg" ;; | |
252b5132 RH |
472 | esac |
473 | done | |
474 | ||
6be7c12c AO |
475 | # NLS nuisances. |
476 | # Only set these to C if already set. These must not be set unconditionally | |
477 | # because not all systems understand e.g. LANG=C (notably SCO). | |
478 | # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'! | |
479 | # Non-C LC_CTYPE values break the ctype check. | |
480 | if test "${LANG+set}" = set; then LANG=C; export LANG; fi | |
481 | if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi | |
482 | if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi | |
483 | if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi | |
252b5132 | 484 | |
6be7c12c AO |
485 | # confdefs.h avoids OS command line length limits that DEFS can exceed. |
486 | rm -rf conftest* confdefs.h | |
487 | # AIX cpp loses on an empty file, so make sure it contains at least a newline. | |
488 | echo > confdefs.h | |
252b5132 | 489 | |
6be7c12c AO |
490 | # A filename unique to this package, relative to the directory that |
491 | # configure is in, which we can look for to find out if srcdir is correct. | |
492 | ac_unique_file=libbfd.c | |
252b5132 RH |
493 | |
494 | # Find the source files, if location was not specified. | |
495 | if test -z "$srcdir"; then | |
496 | ac_srcdir_defaulted=yes | |
497 | # Try the directory containing this script, then its parent. | |
498 | ac_prog=$0 | |
6be7c12c | 499 | ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'` |
252b5132 RH |
500 | test "x$ac_confdir" = "x$ac_prog" && ac_confdir=. |
501 | srcdir=$ac_confdir | |
502 | if test ! -r $srcdir/$ac_unique_file; then | |
503 | srcdir=.. | |
504 | fi | |
505 | else | |
506 | ac_srcdir_defaulted=no | |
507 | fi | |
508 | if test ! -r $srcdir/$ac_unique_file; then | |
509 | if test "$ac_srcdir_defaulted" = yes; then | |
6be7c12c | 510 | { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; } |
252b5132 | 511 | else |
6be7c12c | 512 | { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; } |
252b5132 RH |
513 | fi |
514 | fi | |
6be7c12c | 515 | srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'` |
b3baf5d0 | 516 | |
6be7c12c | 517 | # Prefer explicitly selected file to automatically selected ones. |
c6f8758f NC |
518 | if test -z "$sitefile"; then |
519 | if test -z "$CONFIG_SITE"; then | |
520 | if test "x$prefix" != xNONE; then | |
521 | CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site" | |
522 | else | |
523 | CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site" | |
524 | fi | |
252b5132 | 525 | fi |
c6f8758f NC |
526 | else |
527 | CONFIG_SITE="$sitefile" | |
252b5132 RH |
528 | fi |
529 | for ac_site_file in $CONFIG_SITE; do | |
530 | if test -r "$ac_site_file"; then | |
6be7c12c | 531 | echo "loading site script $ac_site_file" |
252b5132 RH |
532 | . "$ac_site_file" |
533 | fi | |
534 | done | |
535 | ||
536 | if test -r "$cache_file"; then | |
6be7c12c AO |
537 | echo "loading cache $cache_file" |
538 | . $cache_file | |
252b5132 | 539 | else |
6be7c12c AO |
540 | echo "creating cache $cache_file" |
541 | > $cache_file | |
252b5132 RH |
542 | fi |
543 | ||
544 | ac_ext=c | |
6be7c12c | 545 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. |
252b5132 | 546 | ac_cpp='$CPP $CPPFLAGS' |
6be7c12c AO |
547 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' |
548 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' | |
549 | cross_compiling=$ac_cv_prog_cc_cross | |
550 | ||
551 | ac_exeext= | |
552 | ac_objext=o | |
553 | if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then | |
554 | # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu. | |
555 | if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then | |
556 | ac_n= ac_c=' | |
557 | ' ac_t=' ' | |
558 | else | |
559 | ac_n=-n ac_c= ac_t= | |
560 | fi | |
561 | else | |
562 | ac_n= ac_c='\c' ac_t= | |
563 | fi | |
564 | ||
565 | echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6 | |
c6f8758f | 566 | echo "configure:567: checking for Cygwin environment" >&5 |
6be7c12c AO |
567 | if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then |
568 | echo $ac_n "(cached) $ac_c" 1>&6 | |
569 | else | |
570 | cat > conftest.$ac_ext <<EOF | |
c6f8758f | 571 | #line 572 "configure" |
6be7c12c AO |
572 | #include "confdefs.h" |
573 | ||
574 | int main() { | |
575 | ||
576 | #ifndef __CYGWIN__ | |
577 | #define __CYGWIN__ __CYGWIN32__ | |
578 | #endif | |
579 | return __CYGWIN__; | |
580 | ; return 0; } | |
581 | EOF | |
c6f8758f | 582 | if { (eval echo configure:583: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
6be7c12c AO |
583 | rm -rf conftest* |
584 | ac_cv_cygwin=yes | |
585 | else | |
586 | echo "configure: failed program was:" >&5 | |
587 | cat conftest.$ac_ext >&5 | |
588 | rm -rf conftest* | |
589 | ac_cv_cygwin=no | |
590 | fi | |
591 | rm -f conftest* | |
592 | rm -f conftest* | |
593 | fi | |
594 | ||
595 | echo "$ac_t""$ac_cv_cygwin" 1>&6 | |
596 | CYGWIN= | |
597 | test "$ac_cv_cygwin" = yes && CYGWIN=yes | |
598 | echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6 | |
c6f8758f | 599 | echo "configure:600: checking for mingw32 environment" >&5 |
6be7c12c AO |
600 | if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then |
601 | echo $ac_n "(cached) $ac_c" 1>&6 | |
602 | else | |
603 | cat > conftest.$ac_ext <<EOF | |
c6f8758f | 604 | #line 605 "configure" |
6be7c12c AO |
605 | #include "confdefs.h" |
606 | ||
607 | int main() { | |
608 | return __MINGW32__; | |
609 | ; return 0; } | |
610 | EOF | |
c6f8758f | 611 | if { (eval echo configure:612: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
6be7c12c AO |
612 | rm -rf conftest* |
613 | ac_cv_mingw32=yes | |
ac48eca1 | 614 | else |
6be7c12c AO |
615 | echo "configure: failed program was:" >&5 |
616 | cat conftest.$ac_ext >&5 | |
617 | rm -rf conftest* | |
618 | ac_cv_mingw32=no | |
619 | fi | |
620 | rm -f conftest* | |
621 | rm -f conftest* | |
ac48eca1 | 622 | fi |
6be7c12c AO |
623 | |
624 | echo "$ac_t""$ac_cv_mingw32" 1>&6 | |
625 | MINGW32= | |
626 | test "$ac_cv_mingw32" = yes && MINGW32=yes | |
627 | ||
252b5132 RH |
628 | |
629 | ac_aux_dir= | |
630 | for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do | |
631 | if test -f $ac_dir/install-sh; then | |
632 | ac_aux_dir=$ac_dir | |
633 | ac_install_sh="$ac_aux_dir/install-sh -c" | |
634 | break | |
635 | elif test -f $ac_dir/install.sh; then | |
636 | ac_aux_dir=$ac_dir | |
637 | ac_install_sh="$ac_aux_dir/install.sh -c" | |
638 | break | |
639 | fi | |
640 | done | |
641 | if test -z "$ac_aux_dir"; then | |
6be7c12c | 642 | { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; } |
252b5132 | 643 | fi |
6be7c12c AO |
644 | ac_config_guess=$ac_aux_dir/config.guess |
645 | ac_config_sub=$ac_aux_dir/config.sub | |
646 | ac_configure=$ac_aux_dir/configure # This should be Cygnus configure. | |
252b5132 | 647 | |
6be7c12c AO |
648 | |
649 | # Do some error checking and defaulting for the host and target type. | |
650 | # The inputs are: | |
651 | # configure --host=HOST --target=TARGET --build=BUILD NONOPT | |
652 | # | |
653 | # The rules are: | |
654 | # 1. You are not allowed to specify --host, --target, and nonopt at the | |
655 | # same time. | |
656 | # 2. Host defaults to nonopt. | |
657 | # 3. If nonopt is not specified, then host defaults to the current host, | |
658 | # as determined by config.guess. | |
659 | # 4. Target and build default to nonopt. | |
660 | # 5. If nonopt is not specified, then target and build default to host. | |
252b5132 RH |
661 | |
662 | # The aliases save the names the user supplied, while $host etc. | |
663 | # will get canonicalized. | |
6be7c12c AO |
664 | case $host---$target---$nonopt in |
665 | NONE---*---* | *---NONE---* | *---*---NONE) ;; | |
666 | *) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;; | |
667 | esac | |
668 | ||
669 | ||
670 | # Make sure we can run config.sub. | |
671 | if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then : | |
672 | else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; } | |
673 | fi | |
674 | ||
675 | echo $ac_n "checking host system type""... $ac_c" 1>&6 | |
c6f8758f | 676 | echo "configure:677: checking host system type" >&5 |
6be7c12c AO |
677 | |
678 | host_alias=$host | |
679 | case "$host_alias" in | |
680 | NONE) | |
681 | case $nonopt in | |
682 | NONE) | |
683 | if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then : | |
684 | else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; } | |
685 | fi ;; | |
686 | *) host_alias=$nonopt ;; | |
687 | esac ;; | |
688 | esac | |
689 | ||
690 | host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias` | |
691 | host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` | |
692 | host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` | |
693 | host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` | |
694 | echo "$ac_t""$host" 1>&6 | |
695 | ||
696 | echo $ac_n "checking target system type""... $ac_c" 1>&6 | |
c6f8758f | 697 | echo "configure:698: checking target system type" >&5 |
6be7c12c AO |
698 | |
699 | target_alias=$target | |
700 | case "$target_alias" in | |
701 | NONE) | |
702 | case $nonopt in | |
703 | NONE) target_alias=$host_alias ;; | |
704 | *) target_alias=$nonopt ;; | |
705 | esac ;; | |
706 | esac | |
707 | ||
708 | target=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $target_alias` | |
709 | target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` | |
710 | target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` | |
711 | target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` | |
712 | echo "$ac_t""$target" 1>&6 | |
713 | ||
714 | echo $ac_n "checking build system type""... $ac_c" 1>&6 | |
c6f8758f | 715 | echo "configure:716: checking build system type" >&5 |
6be7c12c AO |
716 | |
717 | build_alias=$build | |
718 | case "$build_alias" in | |
719 | NONE) | |
720 | case $nonopt in | |
721 | NONE) build_alias=$host_alias ;; | |
722 | *) build_alias=$nonopt ;; | |
723 | esac ;; | |
724 | esac | |
725 | ||
726 | build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias` | |
727 | build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` | |
728 | build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` | |
729 | build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` | |
730 | echo "$ac_t""$build" 1>&6 | |
731 | ||
732 | test "$host_alias" != "$target_alias" && | |
252b5132 RH |
733 | test "$program_prefix$program_suffix$program_transform_name" = \ |
734 | NONENONEs,x,x, && | |
735 | program_prefix=${target_alias}- | |
6be7c12c | 736 | |
66e25bab | 737 | |
c5d1701e | 738 | echo $ac_n "checking for strerror in -lcposix""... $ac_c" 1>&6 |
c6f8758f | 739 | echo "configure:740: checking for strerror in -lcposix" >&5 |
c5d1701e NC |
740 | ac_lib_var=`echo cposix'_'strerror | sed 'y%./+-%__p_%'` |
741 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then | |
66e25bab AM |
742 | echo $ac_n "(cached) $ac_c" 1>&6 |
743 | else | |
c5d1701e NC |
744 | ac_save_LIBS="$LIBS" |
745 | LIBS="-lcposix $LIBS" | |
746 | cat > conftest.$ac_ext <<EOF | |
c6f8758f | 747 | #line 748 "configure" |
b3baf5d0 | 748 | #include "confdefs.h" |
c5d1701e NC |
749 | /* Override any gcc2 internal prototype to avoid an error. */ |
750 | /* We use char because int might match the return type of a gcc2 | |
751 | builtin and then its argument prototype would still apply. */ | |
752 | char strerror(); | |
b3baf5d0 | 753 | |
c5d1701e NC |
754 | int main() { |
755 | strerror() | |
756 | ; return 0; } | |
6be7c12c | 757 | EOF |
c6f8758f | 758 | if { (eval echo configure:759: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
c5d1701e NC |
759 | rm -rf conftest* |
760 | eval "ac_cv_lib_$ac_lib_var=yes" | |
b3baf5d0 | 761 | else |
6be7c12c AO |
762 | echo "configure: failed program was:" >&5 |
763 | cat conftest.$ac_ext >&5 | |
c5d1701e NC |
764 | rm -rf conftest* |
765 | eval "ac_cv_lib_$ac_lib_var=no" | |
b3baf5d0 | 766 | fi |
6be7c12c | 767 | rm -f conftest* |
c5d1701e | 768 | LIBS="$ac_save_LIBS" |
6be7c12c | 769 | |
b3baf5d0 | 770 | fi |
c5d1701e | 771 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
6be7c12c | 772 | echo "$ac_t""yes" 1>&6 |
c5d1701e | 773 | LIBS="$LIBS -lcposix" |
b3baf5d0 | 774 | else |
6be7c12c | 775 | echo "$ac_t""no" 1>&6 |
b3baf5d0 | 776 | fi |
252b5132 | 777 | |
c5d1701e NC |
778 | |
779 | ||
6be7c12c | 780 | |
6726e1ea | 781 | am__api_version="1.4" |
252b5132 RH |
782 | # Find a good install program. We prefer a C program (faster), |
783 | # so one script is as good as another. But avoid the broken or | |
784 | # incompatible versions: | |
785 | # SysV /etc/install, /usr/sbin/install | |
786 | # SunOS /usr/etc/install | |
787 | # IRIX /sbin/install | |
788 | # AIX /bin/install | |
789 | # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag | |
790 | # AFS /usr/afsws/bin/install, which mishandles nonexistent args | |
791 | # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" | |
792 | # ./install, which can be erroneously created by make from ./install.sh. | |
6be7c12c | 793 | echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6 |
c6f8758f | 794 | echo "configure:795: checking for a BSD compatible install" >&5 |
252b5132 | 795 | if test -z "$INSTALL"; then |
6be7c12c AO |
796 | if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then |
797 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 798 | else |
6be7c12c | 799 | IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":" |
252b5132 RH |
800 | for ac_dir in $PATH; do |
801 | # Account for people who put trailing slashes in PATH elements. | |
6be7c12c AO |
802 | case "$ac_dir/" in |
803 | /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;; | |
252b5132 RH |
804 | *) |
805 | # OSF1 and SCO ODT 3.0 have their own names for install. | |
806 | # Don't use installbsd from OSF since it installs stuff as root | |
807 | # by default. | |
808 | for ac_prog in ginstall scoinst install; do | |
6be7c12c | 809 | if test -f $ac_dir/$ac_prog; then |
252b5132 | 810 | if test $ac_prog = install && |
6be7c12c | 811 | grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then |
252b5132 RH |
812 | # AIX install. It has an incompatible calling convention. |
813 | : | |
814 | else | |
815 | ac_cv_path_install="$ac_dir/$ac_prog -c" | |
816 | break 2 | |
817 | fi | |
818 | fi | |
819 | done | |
820 | ;; | |
821 | esac | |
822 | done | |
6be7c12c | 823 | IFS="$ac_save_IFS" |
252b5132 RH |
824 | |
825 | fi | |
826 | if test "${ac_cv_path_install+set}" = set; then | |
6be7c12c | 827 | INSTALL="$ac_cv_path_install" |
252b5132 RH |
828 | else |
829 | # As a last resort, use the slow shell script. We don't cache a | |
830 | # path for INSTALL within a source directory, because that will | |
831 | # break other packages using the cache if that directory is | |
832 | # removed, or if the path is relative. | |
6be7c12c | 833 | INSTALL="$ac_install_sh" |
252b5132 RH |
834 | fi |
835 | fi | |
6be7c12c | 836 | echo "$ac_t""$INSTALL" 1>&6 |
252b5132 RH |
837 | |
838 | # Use test -z because SunOS4 sh mishandles braces in ${var-val}. | |
839 | # It thinks the first close brace ends the variable substitution. | |
840 | test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' | |
841 | ||
6be7c12c | 842 | test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}' |
252b5132 RH |
843 | |
844 | test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' | |
845 | ||
6be7c12c | 846 | echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6 |
c6f8758f | 847 | echo "configure:848: checking whether build environment is sane" >&5 |
252b5132 RH |
848 | # Just in case |
849 | sleep 1 | |
850 | echo timestamp > conftestfile | |
851 | # Do `set' in a subshell so we don't clobber the current shell's | |
852 | # arguments. Must try -L first in case configure is actually a | |
853 | # symlink; some systems play weird games with the mod time of symlinks | |
854 | # (eg FreeBSD returns the mod time of the symlink's containing | |
855 | # directory). | |
856 | if ( | |
857 | set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null` | |
858 | if test "$*" = "X"; then | |
859 | # -L didn't work. | |
860 | set X `ls -t $srcdir/configure conftestfile` | |
861 | fi | |
862 | if test "$*" != "X $srcdir/configure conftestfile" \ | |
863 | && test "$*" != "X conftestfile $srcdir/configure"; then | |
864 | ||
865 | # If neither matched, then we have a broken ls. This can happen | |
866 | # if, for instance, CONFIG_SHELL is bash and it inherits a | |
867 | # broken ls alias from the environment. This has actually | |
868 | # happened. Such a system could not be considered "sane". | |
6be7c12c AO |
869 | { echo "configure: error: ls -t appears to fail. Make sure there is not a broken |
870 | alias in your environment" 1>&2; exit 1; } | |
252b5132 RH |
871 | fi |
872 | ||
873 | test "$2" = conftestfile | |
874 | ) | |
875 | then | |
876 | # Ok. | |
877 | : | |
878 | else | |
6be7c12c AO |
879 | { echo "configure: error: newly created file is older than distributed files! |
880 | Check your system clock" 1>&2; exit 1; } | |
252b5132 RH |
881 | fi |
882 | rm -f conftest* | |
6be7c12c | 883 | echo "$ac_t""yes" 1>&6 |
252b5132 RH |
884 | if test "$program_transform_name" = s,x,x,; then |
885 | program_transform_name= | |
886 | else | |
887 | # Double any \ or $. echo might interpret backslashes. | |
6be7c12c | 888 | cat <<\EOF_SED > conftestsed |
252b5132 | 889 | s,\\,\\\\,g; s,\$,$$,g |
6be7c12c AO |
890 | EOF_SED |
891 | program_transform_name="`echo $program_transform_name|sed -f conftestsed`" | |
892 | rm -f conftestsed | |
252b5132 RH |
893 | fi |
894 | test "$program_prefix" != NONE && | |
6be7c12c | 895 | program_transform_name="s,^,${program_prefix},; $program_transform_name" |
252b5132 RH |
896 | # Use a double $ so make ignores it. |
897 | test "$program_suffix" != NONE && | |
6be7c12c | 898 | program_transform_name="s,\$\$,${program_suffix},; $program_transform_name" |
252b5132 RH |
899 | |
900 | # sed with no file args requires a program. | |
6be7c12c | 901 | test "$program_transform_name" = "" && program_transform_name="s,x,x," |
252b5132 | 902 | |
6be7c12c | 903 | echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6 |
c6f8758f | 904 | echo "configure:905: checking whether ${MAKE-make} sets \${MAKE}" >&5 |
6be7c12c AO |
905 | set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'` |
906 | if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then | |
907 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 908 | else |
6be7c12c | 909 | cat > conftestmake <<\EOF |
252b5132 RH |
910 | all: |
911 | @echo 'ac_maketemp="${MAKE}"' | |
912 | EOF | |
913 | # GNU make sometimes prints "make[1]: Entering...", which would confuse us. | |
6be7c12c | 914 | eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=` |
252b5132 RH |
915 | if test -n "$ac_maketemp"; then |
916 | eval ac_cv_prog_make_${ac_make}_set=yes | |
917 | else | |
918 | eval ac_cv_prog_make_${ac_make}_set=no | |
919 | fi | |
6be7c12c | 920 | rm -f conftestmake |
252b5132 RH |
921 | fi |
922 | if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then | |
6be7c12c | 923 | echo "$ac_t""yes" 1>&6 |
252b5132 RH |
924 | SET_MAKE= |
925 | else | |
6be7c12c | 926 | echo "$ac_t""no" 1>&6 |
252b5132 RH |
927 | SET_MAKE="MAKE=${MAKE-make}" |
928 | fi | |
929 | ||
6be7c12c | 930 | |
252b5132 RH |
931 | PACKAGE=bfd |
932 | ||
7dfb3b6b | 933 | VERSION=2.15.91 |
252b5132 RH |
934 | |
935 | if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then | |
6be7c12c | 936 | { echo "configure: error: source directory already configured; run "make distclean" there first" 1>&2; exit 1; } |
252b5132 | 937 | fi |
6be7c12c | 938 | cat >> confdefs.h <<EOF |
252b5132 RH |
939 | #define PACKAGE "$PACKAGE" |
940 | EOF | |
941 | ||
6be7c12c | 942 | cat >> confdefs.h <<EOF |
252b5132 RH |
943 | #define VERSION "$VERSION" |
944 | EOF | |
945 | ||
6be7c12c AO |
946 | |
947 | ||
252b5132 | 948 | missing_dir=`cd $ac_aux_dir && pwd` |
6726e1ea | 949 | echo $ac_n "checking for working aclocal-${am__api_version}""... $ac_c" 1>&6 |
c6f8758f | 950 | echo "configure:951: checking for working aclocal-${am__api_version}" >&5 |
252b5132 RH |
951 | # Run test in a subshell; some versions of sh will print an error if |
952 | # an executable is not found, even if stderr is redirected. | |
953 | # Redirect stdin to placate older versions of autoconf. Sigh. | |
6726e1ea L |
954 | if (aclocal-${am__api_version} --version) < /dev/null > /dev/null 2>&1; then |
955 | ACLOCAL=aclocal-${am__api_version} | |
6be7c12c | 956 | echo "$ac_t""found" 1>&6 |
252b5132 | 957 | else |
6726e1ea | 958 | ACLOCAL="$missing_dir/missing aclocal-${am__api_version}" |
6be7c12c | 959 | echo "$ac_t""missing" 1>&6 |
252b5132 RH |
960 | fi |
961 | ||
6be7c12c | 962 | echo $ac_n "checking for working autoconf""... $ac_c" 1>&6 |
c6f8758f | 963 | echo "configure:964: checking for working autoconf" >&5 |
252b5132 RH |
964 | # Run test in a subshell; some versions of sh will print an error if |
965 | # an executable is not found, even if stderr is redirected. | |
966 | # Redirect stdin to placate older versions of autoconf. Sigh. | |
967 | if (autoconf --version) < /dev/null > /dev/null 2>&1; then | |
968 | AUTOCONF=autoconf | |
6be7c12c | 969 | echo "$ac_t""found" 1>&6 |
252b5132 RH |
970 | else |
971 | AUTOCONF="$missing_dir/missing autoconf" | |
6be7c12c | 972 | echo "$ac_t""missing" 1>&6 |
252b5132 RH |
973 | fi |
974 | ||
6726e1ea | 975 | echo $ac_n "checking for working automake-${am__api_version}""... $ac_c" 1>&6 |
c6f8758f | 976 | echo "configure:977: checking for working automake-${am__api_version}" >&5 |
252b5132 RH |
977 | # Run test in a subshell; some versions of sh will print an error if |
978 | # an executable is not found, even if stderr is redirected. | |
979 | # Redirect stdin to placate older versions of autoconf. Sigh. | |
6726e1ea L |
980 | if (automake-${am__api_version} --version) < /dev/null > /dev/null 2>&1; then |
981 | AUTOMAKE=automake-${am__api_version} | |
6be7c12c | 982 | echo "$ac_t""found" 1>&6 |
252b5132 | 983 | else |
6726e1ea | 984 | AUTOMAKE="$missing_dir/missing automake-${am__api_version}" |
6be7c12c | 985 | echo "$ac_t""missing" 1>&6 |
252b5132 RH |
986 | fi |
987 | ||
6be7c12c | 988 | echo $ac_n "checking for working autoheader""... $ac_c" 1>&6 |
c6f8758f | 989 | echo "configure:990: checking for working autoheader" >&5 |
252b5132 RH |
990 | # Run test in a subshell; some versions of sh will print an error if |
991 | # an executable is not found, even if stderr is redirected. | |
992 | # Redirect stdin to placate older versions of autoconf. Sigh. | |
993 | if (autoheader --version) < /dev/null > /dev/null 2>&1; then | |
994 | AUTOHEADER=autoheader | |
6be7c12c | 995 | echo "$ac_t""found" 1>&6 |
252b5132 RH |
996 | else |
997 | AUTOHEADER="$missing_dir/missing autoheader" | |
6be7c12c | 998 | echo "$ac_t""missing" 1>&6 |
252b5132 RH |
999 | fi |
1000 | ||
6be7c12c | 1001 | echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6 |
c6f8758f | 1002 | echo "configure:1003: checking for working makeinfo" >&5 |
252b5132 RH |
1003 | # Run test in a subshell; some versions of sh will print an error if |
1004 | # an executable is not found, even if stderr is redirected. | |
1005 | # Redirect stdin to placate older versions of autoconf. Sigh. | |
1006 | if (makeinfo --version) < /dev/null > /dev/null 2>&1; then | |
1007 | MAKEINFO=makeinfo | |
6be7c12c | 1008 | echo "$ac_t""found" 1>&6 |
252b5132 RH |
1009 | else |
1010 | MAKEINFO="$missing_dir/missing makeinfo" | |
6be7c12c | 1011 | echo "$ac_t""missing" 1>&6 |
252b5132 RH |
1012 | fi |
1013 | ||
6be7c12c | 1014 | |
e43d48cc | 1015 | |
6be7c12c AO |
1016 | if test $host != $build; then |
1017 | ac_tool_prefix=${host_alias}- | |
1018 | else | |
1019 | ac_tool_prefix= | |
1020 | fi | |
1021 | ||
1022 | # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args. | |
252b5132 | 1023 | set dummy ${ac_tool_prefix}ar; ac_word=$2 |
6be7c12c | 1024 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
c6f8758f | 1025 | echo "configure:1026: checking for $ac_word" >&5 |
6be7c12c AO |
1026 | if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then |
1027 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 RH |
1028 | else |
1029 | if test -n "$AR"; then | |
1030 | ac_cv_prog_AR="$AR" # Let the user override the test. | |
1031 | else | |
6be7c12c AO |
1032 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
1033 | ac_dummy="$PATH" | |
1034 | for ac_dir in $ac_dummy; do | |
1035 | test -z "$ac_dir" && ac_dir=. | |
1036 | if test -f $ac_dir/$ac_word; then | |
1037 | ac_cv_prog_AR="${ac_tool_prefix}ar" | |
1038 | break | |
1039 | fi | |
1040 | done | |
1041 | IFS="$ac_save_ifs" | |
1042 | test -z "$ac_cv_prog_AR" && ac_cv_prog_AR="ar" | |
252b5132 RH |
1043 | fi |
1044 | fi | |
6be7c12c | 1045 | AR="$ac_cv_prog_AR" |
252b5132 | 1046 | if test -n "$AR"; then |
6be7c12c | 1047 | echo "$ac_t""$AR" 1>&6 |
252b5132 | 1048 | else |
6be7c12c | 1049 | echo "$ac_t""no" 1>&6 |
252b5132 RH |
1050 | fi |
1051 | ||
1052 | ||
6be7c12c AO |
1053 | |
1054 | # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. | |
252b5132 | 1055 | set dummy ${ac_tool_prefix}ranlib; ac_word=$2 |
6be7c12c | 1056 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
c6f8758f | 1057 | echo "configure:1058: checking for $ac_word" >&5 |
6be7c12c AO |
1058 | if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then |
1059 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 RH |
1060 | else |
1061 | if test -n "$RANLIB"; then | |
1062 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. | |
1063 | else | |
6be7c12c AO |
1064 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
1065 | ac_dummy="$PATH" | |
1066 | for ac_dir in $ac_dummy; do | |
1067 | test -z "$ac_dir" && ac_dir=. | |
1068 | if test -f $ac_dir/$ac_word; then | |
1069 | ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" | |
1070 | break | |
1071 | fi | |
1072 | done | |
1073 | IFS="$ac_save_ifs" | |
252b5132 RH |
1074 | fi |
1075 | fi | |
6be7c12c | 1076 | RANLIB="$ac_cv_prog_RANLIB" |
252b5132 | 1077 | if test -n "$RANLIB"; then |
6be7c12c | 1078 | echo "$ac_t""$RANLIB" 1>&6 |
252b5132 | 1079 | else |
6be7c12c | 1080 | echo "$ac_t""no" 1>&6 |
252b5132 RH |
1081 | fi |
1082 | ||
6be7c12c | 1083 | |
252b5132 | 1084 | if test -z "$ac_cv_prog_RANLIB"; then |
6be7c12c | 1085 | if test -n "$ac_tool_prefix"; then |
252b5132 RH |
1086 | # Extract the first word of "ranlib", so it can be a program name with args. |
1087 | set dummy ranlib; ac_word=$2 | |
6be7c12c | 1088 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
c6f8758f | 1089 | echo "configure:1090: checking for $ac_word" >&5 |
6be7c12c AO |
1090 | if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then |
1091 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1092 | else | |
1093 | if test -n "$RANLIB"; then | |
1094 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. | |
1095 | else | |
1096 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
1097 | ac_dummy="$PATH" | |
1098 | for ac_dir in $ac_dummy; do | |
1099 | test -z "$ac_dir" && ac_dir=. | |
1100 | if test -f $ac_dir/$ac_word; then | |
1101 | ac_cv_prog_RANLIB="ranlib" | |
1102 | break | |
1103 | fi | |
1104 | done | |
1105 | IFS="$ac_save_ifs" | |
1106 | test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":" | |
252b5132 RH |
1107 | fi |
1108 | fi | |
6be7c12c AO |
1109 | RANLIB="$ac_cv_prog_RANLIB" |
1110 | if test -n "$RANLIB"; then | |
1111 | echo "$ac_t""$RANLIB" 1>&6 | |
252b5132 | 1112 | else |
6be7c12c | 1113 | echo "$ac_t""no" 1>&6 |
252b5132 RH |
1114 | fi |
1115 | ||
1116 | else | |
6be7c12c | 1117 | RANLIB=":" |
252b5132 | 1118 | fi |
6be7c12c AO |
1119 | fi |
1120 | ||
252b5132 RH |
1121 | |
1122 | # Check whether --enable-shared or --disable-shared was given. | |
1123 | if test "${enable_shared+set}" = set; then | |
1124 | enableval="$enable_shared" | |
1125 | p=${PACKAGE-default} | |
55c80943 | 1126 | case $enableval in |
252b5132 RH |
1127 | yes) enable_shared=yes ;; |
1128 | no) enable_shared=no ;; | |
1129 | *) | |
1130 | enable_shared=no | |
1131 | # Look at the argument we got. We use all the common list separators. | |
1132 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:," | |
1133 | for pkg in $enableval; do | |
1134 | if test "X$pkg" = "X$p"; then | |
1135 | enable_shared=yes | |
1136 | fi | |
1137 | done | |
1138 | IFS="$ac_save_ifs" | |
1139 | ;; | |
1140 | esac | |
1141 | else | |
1142 | enable_shared=no | |
6be7c12c AO |
1143 | fi |
1144 | ||
252b5132 RH |
1145 | |
1146 | # Check whether --enable-static or --disable-static was given. | |
1147 | if test "${enable_static+set}" = set; then | |
1148 | enableval="$enable_static" | |
1149 | p=${PACKAGE-default} | |
55c80943 | 1150 | case $enableval in |
252b5132 RH |
1151 | yes) enable_static=yes ;; |
1152 | no) enable_static=no ;; | |
1153 | *) | |
1154 | enable_static=no | |
1155 | # Look at the argument we got. We use all the common list separators. | |
1156 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:," | |
1157 | for pkg in $enableval; do | |
1158 | if test "X$pkg" = "X$p"; then | |
1159 | enable_static=yes | |
1160 | fi | |
1161 | done | |
1162 | IFS="$ac_save_ifs" | |
1163 | ;; | |
1164 | esac | |
1165 | else | |
1166 | enable_static=yes | |
6be7c12c AO |
1167 | fi |
1168 | ||
b2ef150d ILT |
1169 | # Check whether --enable-fast-install or --disable-fast-install was given. |
1170 | if test "${enable_fast_install+set}" = set; then | |
1171 | enableval="$enable_fast_install" | |
1172 | p=${PACKAGE-default} | |
55c80943 | 1173 | case $enableval in |
b2ef150d ILT |
1174 | yes) enable_fast_install=yes ;; |
1175 | no) enable_fast_install=no ;; | |
1176 | *) | |
1177 | enable_fast_install=no | |
1178 | # Look at the argument we got. We use all the common list separators. | |
1179 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:," | |
1180 | for pkg in $enableval; do | |
1181 | if test "X$pkg" = "X$p"; then | |
1182 | enable_fast_install=yes | |
1183 | fi | |
1184 | done | |
1185 | IFS="$ac_save_ifs" | |
1186 | ;; | |
1187 | esac | |
1188 | else | |
1189 | enable_fast_install=yes | |
6be7c12c | 1190 | fi |
8d88c4ca | 1191 | |
c5d1701e NC |
1192 | # Extract the first word of "gcc", so it can be a program name with args. |
1193 | set dummy gcc; ac_word=$2 | |
1194 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
c6f8758f | 1195 | echo "configure:1196: checking for $ac_word" >&5 |
c5d1701e NC |
1196 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
1197 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1198 | else | |
1199 | if test -n "$CC"; then | |
1200 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
1201 | else | |
1202 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
1203 | ac_dummy="$PATH" | |
1204 | for ac_dir in $ac_dummy; do | |
1205 | test -z "$ac_dir" && ac_dir=. | |
1206 | if test -f $ac_dir/$ac_word; then | |
1207 | ac_cv_prog_CC="gcc" | |
1208 | break | |
1209 | fi | |
1210 | done | |
1211 | IFS="$ac_save_ifs" | |
1212 | fi | |
1213 | fi | |
1214 | CC="$ac_cv_prog_CC" | |
1215 | if test -n "$CC"; then | |
1216 | echo "$ac_t""$CC" 1>&6 | |
1217 | else | |
1218 | echo "$ac_t""no" 1>&6 | |
1219 | fi | |
1220 | ||
1221 | if test -z "$CC"; then | |
1222 | # Extract the first word of "cc", so it can be a program name with args. | |
1223 | set dummy cc; ac_word=$2 | |
1224 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
c6f8758f | 1225 | echo "configure:1226: checking for $ac_word" >&5 |
c5d1701e NC |
1226 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
1227 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1228 | else | |
1229 | if test -n "$CC"; then | |
1230 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
1231 | else | |
1232 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
1233 | ac_prog_rejected=no | |
1234 | ac_dummy="$PATH" | |
1235 | for ac_dir in $ac_dummy; do | |
1236 | test -z "$ac_dir" && ac_dir=. | |
1237 | if test -f $ac_dir/$ac_word; then | |
1238 | if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then | |
1239 | ac_prog_rejected=yes | |
1240 | continue | |
1241 | fi | |
1242 | ac_cv_prog_CC="cc" | |
1243 | break | |
1244 | fi | |
1245 | done | |
1246 | IFS="$ac_save_ifs" | |
1247 | if test $ac_prog_rejected = yes; then | |
1248 | # We found a bogon in the path, so make sure we never use it. | |
1249 | set dummy $ac_cv_prog_CC | |
1250 | shift | |
1251 | if test $# -gt 0; then | |
1252 | # We chose a different compiler from the bogus one. | |
1253 | # However, it has the same basename, so the bogon will be chosen | |
1254 | # first if we set CC to just the basename; use the full file name. | |
1255 | shift | |
1256 | set dummy "$ac_dir/$ac_word" "$@" | |
1257 | shift | |
1258 | ac_cv_prog_CC="$@" | |
1259 | fi | |
1260 | fi | |
1261 | fi | |
1262 | fi | |
1263 | CC="$ac_cv_prog_CC" | |
1264 | if test -n "$CC"; then | |
1265 | echo "$ac_t""$CC" 1>&6 | |
1266 | else | |
1267 | echo "$ac_t""no" 1>&6 | |
1268 | fi | |
1269 | ||
1270 | if test -z "$CC"; then | |
1271 | case "`uname -s`" in | |
1272 | *win32* | *WIN32*) | |
1273 | # Extract the first word of "cl", so it can be a program name with args. | |
1274 | set dummy cl; ac_word=$2 | |
1275 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
c6f8758f | 1276 | echo "configure:1277: checking for $ac_word" >&5 |
c5d1701e NC |
1277 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
1278 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1279 | else | |
1280 | if test -n "$CC"; then | |
1281 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
1282 | else | |
1283 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
1284 | ac_dummy="$PATH" | |
1285 | for ac_dir in $ac_dummy; do | |
1286 | test -z "$ac_dir" && ac_dir=. | |
1287 | if test -f $ac_dir/$ac_word; then | |
1288 | ac_cv_prog_CC="cl" | |
1289 | break | |
1290 | fi | |
1291 | done | |
1292 | IFS="$ac_save_ifs" | |
1293 | fi | |
1294 | fi | |
1295 | CC="$ac_cv_prog_CC" | |
1296 | if test -n "$CC"; then | |
1297 | echo "$ac_t""$CC" 1>&6 | |
1298 | else | |
1299 | echo "$ac_t""no" 1>&6 | |
1300 | fi | |
1301 | ;; | |
1302 | esac | |
1303 | fi | |
1304 | test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; } | |
1305 | fi | |
1306 | ||
1307 | echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 | |
c6f8758f | 1308 | echo "configure:1309: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 |
c5d1701e NC |
1309 | |
1310 | ac_ext=c | |
1311 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. | |
1312 | ac_cpp='$CPP $CPPFLAGS' | |
1313 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' | |
1314 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' | |
1315 | cross_compiling=$ac_cv_prog_cc_cross | |
1316 | ||
1317 | cat > conftest.$ac_ext << EOF | |
1318 | ||
c6f8758f | 1319 | #line 1320 "configure" |
c5d1701e NC |
1320 | #include "confdefs.h" |
1321 | ||
1322 | main(){return(0);} | |
1323 | EOF | |
c6f8758f | 1324 | if { (eval echo configure:1325: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
c5d1701e NC |
1325 | ac_cv_prog_cc_works=yes |
1326 | # If we can't run a trivial program, we are probably using a cross compiler. | |
1327 | if (./conftest; exit) 2>/dev/null; then | |
1328 | ac_cv_prog_cc_cross=no | |
1329 | else | |
1330 | ac_cv_prog_cc_cross=yes | |
1331 | fi | |
1332 | else | |
1333 | echo "configure: failed program was:" >&5 | |
1334 | cat conftest.$ac_ext >&5 | |
1335 | ac_cv_prog_cc_works=no | |
1336 | fi | |
1337 | rm -fr conftest* | |
1338 | ac_ext=c | |
1339 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. | |
1340 | ac_cpp='$CPP $CPPFLAGS' | |
1341 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' | |
1342 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' | |
1343 | cross_compiling=$ac_cv_prog_cc_cross | |
1344 | ||
1345 | echo "$ac_t""$ac_cv_prog_cc_works" 1>&6 | |
1346 | if test $ac_cv_prog_cc_works = no; then | |
1347 | { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; } | |
1348 | fi | |
1349 | echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 | |
c6f8758f | 1350 | echo "configure:1351: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 |
c5d1701e NC |
1351 | echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6 |
1352 | cross_compiling=$ac_cv_prog_cc_cross | |
1353 | ||
1354 | echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6 | |
c6f8758f | 1355 | echo "configure:1356: checking whether we are using GNU C" >&5 |
c5d1701e NC |
1356 | if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then |
1357 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1358 | else | |
1359 | cat > conftest.c <<EOF | |
1360 | #ifdef __GNUC__ | |
1361 | yes; | |
1362 | #endif | |
1363 | EOF | |
c6f8758f | 1364 | if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1365: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then |
c5d1701e NC |
1365 | ac_cv_prog_gcc=yes |
1366 | else | |
1367 | ac_cv_prog_gcc=no | |
1368 | fi | |
1369 | fi | |
1370 | ||
1371 | echo "$ac_t""$ac_cv_prog_gcc" 1>&6 | |
1372 | ||
1373 | if test $ac_cv_prog_gcc = yes; then | |
1374 | GCC=yes | |
1375 | else | |
1376 | GCC= | |
1377 | fi | |
1378 | ||
1379 | ac_test_CFLAGS="${CFLAGS+set}" | |
1380 | ac_save_CFLAGS="$CFLAGS" | |
1381 | CFLAGS= | |
1382 | echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 | |
c6f8758f | 1383 | echo "configure:1384: checking whether ${CC-cc} accepts -g" >&5 |
c5d1701e NC |
1384 | if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then |
1385 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1386 | else | |
1387 | echo 'void f(){}' > conftest.c | |
1388 | if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then | |
1389 | ac_cv_prog_cc_g=yes | |
1390 | else | |
1391 | ac_cv_prog_cc_g=no | |
1392 | fi | |
1393 | rm -f conftest* | |
1394 | ||
1395 | fi | |
1396 | ||
1397 | echo "$ac_t""$ac_cv_prog_cc_g" 1>&6 | |
1398 | if test "$ac_test_CFLAGS" = set; then | |
1399 | CFLAGS="$ac_save_CFLAGS" | |
1400 | elif test $ac_cv_prog_cc_g = yes; then | |
1401 | if test "$GCC" = yes; then | |
1402 | CFLAGS="-g -O2" | |
1403 | else | |
1404 | CFLAGS="-g" | |
1405 | fi | |
1406 | else | |
1407 | if test "$GCC" = yes; then | |
1408 | CFLAGS="-O2" | |
1409 | else | |
1410 | CFLAGS= | |
1411 | fi | |
1412 | fi | |
1413 | ||
252b5132 RH |
1414 | # Check whether --with-gnu-ld or --without-gnu-ld was given. |
1415 | if test "${with_gnu_ld+set}" = set; then | |
1416 | withval="$with_gnu_ld" | |
1417 | test "$withval" = no || with_gnu_ld=yes | |
1418 | else | |
1419 | with_gnu_ld=no | |
6be7c12c AO |
1420 | fi |
1421 | ||
252b5132 | 1422 | ac_prog=ld |
55c80943 | 1423 | if test "$GCC" = yes; then |
252b5132 | 1424 | # Check if gcc -print-prog-name=ld gives a path. |
6be7c12c | 1425 | echo $ac_n "checking for ld used by GCC""... $ac_c" 1>&6 |
c6f8758f | 1426 | echo "configure:1427: checking for ld used by GCC" >&5 |
ac48eca1 AO |
1427 | case $host in |
1428 | *-*-mingw*) | |
1429 | # gcc leaves a trailing carriage return which upsets mingw | |
1430 | ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; | |
1431 | *) | |
1432 | ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; | |
1433 | esac | |
55c80943 | 1434 | case $ac_prog in |
b2ef150d | 1435 | # Accept absolute paths. |
a74801ba | 1436 | [\\/]* | [A-Za-z]:[\\/]*) |
b2ef150d ILT |
1437 | re_direlt='/[^/][^/]*/\.\./' |
1438 | # Canonicalize the path of ld | |
1439 | ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'` | |
1440 | while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do | |
1441 | ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"` | |
1442 | done | |
1443 | test -z "$LD" && LD="$ac_prog" | |
1444 | ;; | |
252b5132 RH |
1445 | "") |
1446 | # If it fails, then pretend we aren't using GCC. | |
1447 | ac_prog=ld | |
1448 | ;; | |
1449 | *) | |
1450 | # If it is relative, then search for the first ld in PATH. | |
1451 | with_gnu_ld=unknown | |
1452 | ;; | |
1453 | esac | |
1454 | elif test "$with_gnu_ld" = yes; then | |
6be7c12c | 1455 | echo $ac_n "checking for GNU ld""... $ac_c" 1>&6 |
c6f8758f | 1456 | echo "configure:1457: checking for GNU ld" >&5 |
252b5132 | 1457 | else |
6be7c12c | 1458 | echo $ac_n "checking for non-GNU ld""... $ac_c" 1>&6 |
c6f8758f | 1459 | echo "configure:1460: checking for non-GNU ld" >&5 |
252b5132 | 1460 | fi |
6be7c12c AO |
1461 | if eval "test \"`echo '$''{'lt_cv_path_LD'+set}'`\" = set"; then |
1462 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 RH |
1463 | else |
1464 | if test -z "$LD"; then | |
a74801ba | 1465 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}" |
252b5132 RH |
1466 | for ac_dir in $PATH; do |
1467 | test -z "$ac_dir" && ac_dir=. | |
a74801ba | 1468 | if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then |
55c80943 | 1469 | lt_cv_path_LD="$ac_dir/$ac_prog" |
252b5132 RH |
1470 | # Check to see if the program is GNU ld. I'd rather use --version, |
1471 | # but apparently some GNU ld's only accept -v. | |
1472 | # Break only if it was the GNU/non-GNU ld that we prefer. | |
55c80943 | 1473 | if "$lt_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then |
252b5132 RH |
1474 | test "$with_gnu_ld" != no && break |
1475 | else | |
b2ef150d | 1476 | test "$with_gnu_ld" != yes && break |
252b5132 RH |
1477 | fi |
1478 | fi | |
1479 | done | |
1480 | IFS="$ac_save_ifs" | |
1481 | else | |
55c80943 | 1482 | lt_cv_path_LD="$LD" # Let the user override the test with a path. |
252b5132 RH |
1483 | fi |
1484 | fi | |
1485 | ||
55c80943 | 1486 | LD="$lt_cv_path_LD" |
252b5132 | 1487 | if test -n "$LD"; then |
6be7c12c | 1488 | echo "$ac_t""$LD" 1>&6 |
252b5132 | 1489 | else |
6be7c12c | 1490 | echo "$ac_t""no" 1>&6 |
252b5132 | 1491 | fi |
6be7c12c AO |
1492 | test -z "$LD" && { echo "configure: error: no acceptable ld found in \$PATH" 1>&2; exit 1; } |
1493 | echo $ac_n "checking if the linker ($LD) is GNU ld""... $ac_c" 1>&6 | |
c6f8758f | 1494 | echo "configure:1495: checking if the linker ($LD) is GNU ld" >&5 |
6be7c12c AO |
1495 | if eval "test \"`echo '$''{'lt_cv_prog_gnu_ld'+set}'`\" = set"; then |
1496 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 RH |
1497 | else |
1498 | # I'd rather use --version here, but apparently some GNU ld's only accept -v. | |
1499 | if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then | |
55c80943 | 1500 | lt_cv_prog_gnu_ld=yes |
252b5132 | 1501 | else |
55c80943 | 1502 | lt_cv_prog_gnu_ld=no |
252b5132 RH |
1503 | fi |
1504 | fi | |
6be7c12c AO |
1505 | |
1506 | echo "$ac_t""$lt_cv_prog_gnu_ld" 1>&6 | |
55c80943 | 1507 | with_gnu_ld=$lt_cv_prog_gnu_ld |
252b5132 | 1508 | |
6be7c12c AO |
1509 | |
1510 | echo $ac_n "checking for $LD option to reload object files""... $ac_c" 1>&6 | |
c6f8758f | 1511 | echo "configure:1512: checking for $LD option to reload object files" >&5 |
6be7c12c AO |
1512 | if eval "test \"`echo '$''{'lt_cv_ld_reload_flag'+set}'`\" = set"; then |
1513 | echo $ac_n "(cached) $ac_c" 1>&6 | |
ac48eca1 AO |
1514 | else |
1515 | lt_cv_ld_reload_flag='-r' | |
1516 | fi | |
6be7c12c AO |
1517 | |
1518 | echo "$ac_t""$lt_cv_ld_reload_flag" 1>&6 | |
ac48eca1 AO |
1519 | reload_flag=$lt_cv_ld_reload_flag |
1520 | test -n "$reload_flag" && reload_flag=" $reload_flag" | |
1521 | ||
6be7c12c | 1522 | echo $ac_n "checking for BSD-compatible nm""... $ac_c" 1>&6 |
c6f8758f | 1523 | echo "configure:1524: checking for BSD-compatible nm" >&5 |
6be7c12c AO |
1524 | if eval "test \"`echo '$''{'lt_cv_path_NM'+set}'`\" = set"; then |
1525 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 RH |
1526 | else |
1527 | if test -n "$NM"; then | |
1528 | # Let the user override the test. | |
55c80943 | 1529 | lt_cv_path_NM="$NM" |
252b5132 | 1530 | else |
a74801ba | 1531 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}" |
b2ef150d | 1532 | for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do |
252b5132 | 1533 | test -z "$ac_dir" && ac_dir=. |
ac48eca1 AO |
1534 | tmp_nm=$ac_dir/${ac_tool_prefix}nm |
1535 | if test -f $tmp_nm || test -f $tmp_nm$ac_exeext ; then | |
252b5132 RH |
1536 | # Check to see if the nm accepts a BSD-compat flag. |
1537 | # Adding the `sed 1q' prevents false positives on HP-UX, which says: | |
1538 | # nm: unknown option "B" ignored | |
90f2472a AO |
1539 | # Tru64's nm complains that /dev/null is an invalid object file |
1540 | if ($tmp_nm -B /dev/null 2>&1 | sed '1q'; exit 0) | egrep '(/dev/null|Invalid file or object type)' >/dev/null; then | |
55c80943 | 1541 | lt_cv_path_NM="$tmp_nm -B" |
b2ef150d | 1542 | break |
ac48eca1 | 1543 | elif ($tmp_nm -p /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then |
55c80943 | 1544 | lt_cv_path_NM="$tmp_nm -p" |
b2ef150d | 1545 | break |
252b5132 | 1546 | else |
55c80943 | 1547 | lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but |
b2ef150d | 1548 | continue # so that we can try to find one that supports BSD flags |
252b5132 | 1549 | fi |
252b5132 RH |
1550 | fi |
1551 | done | |
1552 | IFS="$ac_save_ifs" | |
55c80943 | 1553 | test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm |
252b5132 RH |
1554 | fi |
1555 | fi | |
1556 | ||
55c80943 | 1557 | NM="$lt_cv_path_NM" |
6be7c12c | 1558 | echo "$ac_t""$NM" 1>&6 |
252b5132 | 1559 | |
6be7c12c | 1560 | echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6 |
c6f8758f | 1561 | echo "configure:1562: checking whether ln -s works" >&5 |
6be7c12c AO |
1562 | if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then |
1563 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1564 | else | |
1565 | rm -f conftestdata | |
1566 | if ln -s X conftestdata 2>/dev/null | |
1567 | then | |
1568 | rm -f conftestdata | |
1569 | ac_cv_prog_LN_S="ln -s" | |
252b5132 | 1570 | else |
6be7c12c AO |
1571 | ac_cv_prog_LN_S=ln |
1572 | fi | |
1573 | fi | |
1574 | LN_S="$ac_cv_prog_LN_S" | |
1575 | if test "$ac_cv_prog_LN_S" = "ln -s"; then | |
1576 | echo "$ac_t""yes" 1>&6 | |
1577 | else | |
1578 | echo "$ac_t""no" 1>&6 | |
252b5132 RH |
1579 | fi |
1580 | ||
6be7c12c | 1581 | echo $ac_n "checking how to recognise dependant libraries""... $ac_c" 1>&6 |
c6f8758f | 1582 | echo "configure:1583: checking how to recognise dependant libraries" >&5 |
6be7c12c AO |
1583 | if eval "test \"`echo '$''{'lt_cv_deplibs_check_method'+set}'`\" = set"; then |
1584 | echo $ac_n "(cached) $ac_c" 1>&6 | |
ac48eca1 | 1585 | else |
d64552c5 | 1586 | lt_cv_file_magic_cmd='$MAGIC_CMD' |
ac48eca1 AO |
1587 | lt_cv_file_magic_test_file= |
1588 | lt_cv_deplibs_check_method='unknown' | |
1589 | # Need to set the preceding variable on all platforms that support | |
1590 | # interlibrary dependencies. | |
1591 | # 'none' -- dependencies not supported. | |
1592 | # `unknown' -- same as none, but documents that we really don't know. | |
1593 | # 'pass_all' -- all dependencies passed with no checks. | |
1594 | # 'test_compile' -- check by making test program. | |
1595 | # 'file_magic [regex]' -- check by looking for files in library path | |
1596 | # which responds to the $file_magic_cmd with a given egrep regex. | |
1597 | # If you have `file' or equivalent on your system and you're not sure | |
1598 | # whether `pass_all' will *always* work, you probably want this one. | |
1599 | ||
55c80943 NC |
1600 | case $host_os in |
1601 | aix*) | |
ac48eca1 AO |
1602 | lt_cv_deplibs_check_method=pass_all |
1603 | ;; | |
1604 | ||
1605 | beos*) | |
1606 | lt_cv_deplibs_check_method=pass_all | |
1607 | ;; | |
1608 | ||
1609 | bsdi4*) | |
55c80943 NC |
1610 | lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)' |
1611 | lt_cv_file_magic_cmd='/usr/bin/file -L' | |
ac48eca1 AO |
1612 | lt_cv_file_magic_test_file=/shlib/libc.so |
1613 | ;; | |
1614 | ||
d64552c5 | 1615 | cygwin* | mingw* |pw32*) |
ac48eca1 | 1616 | lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?' |
d64552c5 | 1617 | lt_cv_file_magic_cmd='$OBJDUMP -f' |
ac48eca1 AO |
1618 | ;; |
1619 | ||
55c80943 NC |
1620 | darwin* | rhapsody*) |
1621 | lt_cv_deplibs_check_method='file_magic Mach-O dynamically linked shared library' | |
b3baf5d0 NC |
1622 | lt_cv_file_magic_cmd='/usr/bin/file -L' |
1623 | case "$host_os" in | |
1624 | rhapsody* | darwin1.012) | |
1625 | lt_cv_file_magic_test_file='/System/Library/Frameworks/System.framework/System' | |
1626 | ;; | |
1627 | *) # Darwin 1.3 on | |
1628 | lt_cv_file_magic_test_file='/usr/lib/libSystem.dylib' | |
1629 | ;; | |
1630 | esac | |
55c80943 NC |
1631 | ;; |
1632 | ||
bc286f95 | 1633 | freebsd* ) |
ac48eca1 | 1634 | if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then |
55c80943 | 1635 | case $host_cpu in |
ac48eca1 | 1636 | i*86 ) |
90f2472a AO |
1637 | # Not sure whether the presence of OpenBSD here was a mistake. |
1638 | # Let's accept both of them until this is cleared up. | |
55c80943 NC |
1639 | lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD)/i[3-9]86 (compact )?demand paged shared library' |
1640 | lt_cv_file_magic_cmd=/usr/bin/file | |
ac48eca1 AO |
1641 | lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` |
1642 | ;; | |
1643 | esac | |
1644 | else | |
1645 | lt_cv_deplibs_check_method=pass_all | |
1646 | fi | |
1647 | ;; | |
1648 | ||
1649 | gnu*) | |
1650 | lt_cv_deplibs_check_method=pass_all | |
1651 | ;; | |
1652 | ||
55c80943 | 1653 | hpux10.20*|hpux11*) |
4867be41 DJ |
1654 | case $host_cpu in |
1655 | hppa*) | |
1656 | lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9].[0-9]) shared library' | |
1657 | lt_cv_file_magic_cmd=/usr/bin/file | |
1658 | lt_cv_file_magic_test_file=/usr/lib/libc.sl | |
1659 | ;; | |
1660 | ia64*) | |
1661 | lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64' | |
1662 | lt_cv_file_magic_cmd=/usr/bin/file | |
1663 | lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so | |
1664 | ;; | |
1665 | esac | |
ac48eca1 AO |
1666 | ;; |
1667 | ||
1668 | irix5* | irix6*) | |
55c80943 | 1669 | case $host_os in |
ac48eca1 AO |
1670 | irix5*) |
1671 | # this will be overridden with pass_all, but let us keep it just in case | |
1672 | lt_cv_deplibs_check_method="file_magic ELF 32-bit MSB dynamic lib MIPS - version 1" | |
1673 | ;; | |
1674 | *) | |
55c80943 | 1675 | case $LD in |
ac48eca1 AO |
1676 | *-32|*"-32 ") libmagic=32-bit;; |
1677 | *-n32|*"-n32 ") libmagic=N32;; | |
1678 | *-64|*"-64 ") libmagic=64-bit;; | |
1679 | *) libmagic=never-match;; | |
1680 | esac | |
1681 | # this will be overridden with pass_all, but let us keep it just in case | |
55c80943 NC |
1682 | lt_cv_deplibs_check_method="file_magic ELF ${libmagic} MSB mips-[1234] dynamic lib MIPS - version 1" |
1683 | ;; | |
ac48eca1 AO |
1684 | esac |
1685 | lt_cv_file_magic_test_file=`echo /lib${libsuff}/libc.so*` | |
1686 | lt_cv_deplibs_check_method=pass_all | |
1687 | ;; | |
1688 | ||
1689 | # This must be Linux ELF. | |
90f2472a | 1690 | linux-gnu*) |
55c80943 | 1691 | case $host_cpu in |
c5d1701e | 1692 | alpha* | mips* | hppa* | i*86 | powerpc* | sparc* | ia64* ) |
ac48eca1 AO |
1693 | lt_cv_deplibs_check_method=pass_all ;; |
1694 | *) | |
1695 | # glibc up to 2.1.1 does not perform some relocations on ARM | |
55c80943 NC |
1696 | lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' ;; |
1697 | esac | |
ac48eca1 AO |
1698 | lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so` |
1699 | ;; | |
1700 | ||
bc286f95 | 1701 | netbsd*) |
55c80943 | 1702 | if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then |
b3baf5d0 | 1703 | lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$' |
ac48eca1 | 1704 | else |
b3baf5d0 | 1705 | lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so$' |
ac48eca1 | 1706 | fi |
55c80943 NC |
1707 | ;; |
1708 | ||
1709 | newsos6) | |
1710 | lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)' | |
1711 | lt_cv_file_magic_cmd=/usr/bin/file | |
1712 | lt_cv_file_magic_test_file=/usr/lib/libnls.so | |
ac48eca1 AO |
1713 | ;; |
1714 | ||
1715 | osf3* | osf4* | osf5*) | |
1716 | # this will be overridden with pass_all, but let us keep it just in case | |
1717 | lt_cv_deplibs_check_method='file_magic COFF format alpha shared library' | |
1718 | lt_cv_file_magic_test_file=/shlib/libc.so | |
1719 | lt_cv_deplibs_check_method=pass_all | |
1720 | ;; | |
1721 | ||
1722 | sco3.2v5*) | |
1723 | lt_cv_deplibs_check_method=pass_all | |
1724 | ;; | |
1725 | ||
1726 | solaris*) | |
1727 | lt_cv_deplibs_check_method=pass_all | |
1728 | lt_cv_file_magic_test_file=/lib/libc.so | |
1729 | ;; | |
1730 | ||
6be7c12c AO |
1731 | sysv5uw[78]* | sysv4*uw2*) |
1732 | lt_cv_deplibs_check_method=pass_all | |
1733 | ;; | |
1734 | ||
ac48eca1 | 1735 | sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) |
55c80943 | 1736 | case $host_vendor in |
ac48eca1 AO |
1737 | ncr) |
1738 | lt_cv_deplibs_check_method=pass_all | |
1739 | ;; | |
1740 | motorola) | |
55c80943 NC |
1741 | lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]' |
1742 | lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` | |
ac48eca1 AO |
1743 | ;; |
1744 | esac | |
1745 | ;; | |
1746 | esac | |
1747 | ||
1748 | fi | |
6be7c12c AO |
1749 | |
1750 | echo "$ac_t""$lt_cv_deplibs_check_method" 1>&6 | |
ac48eca1 AO |
1751 | file_magic_cmd=$lt_cv_file_magic_cmd |
1752 | deplibs_check_method=$lt_cv_deplibs_check_method | |
1753 | ||
6be7c12c | 1754 | echo $ac_n "checking for object suffix""... $ac_c" 1>&6 |
c6f8758f | 1755 | echo "configure:1756: checking for object suffix" >&5 |
6be7c12c AO |
1756 | if eval "test \"`echo '$''{'ac_cv_objext'+set}'`\" = set"; then |
1757 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1758 | else | |
1759 | rm -f conftest* | |
1760 | echo 'int i = 1;' > conftest.$ac_ext | |
c6f8758f | 1761 | if { (eval echo configure:1762: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
6be7c12c AO |
1762 | for ac_file in conftest.*; do |
1763 | case $ac_file in | |
1764 | *.c) ;; | |
1765 | *) ac_cv_objext=`echo $ac_file | sed -e s/conftest.//` ;; | |
1766 | esac | |
1767 | done | |
1768 | else | |
1769 | { echo "configure: error: installation or configuration problem; compiler does not work" 1>&2; exit 1; } | |
1770 | fi | |
1771 | rm -f conftest* | |
1772 | fi | |
ac48eca1 | 1773 | |
6be7c12c AO |
1774 | echo "$ac_t""$ac_cv_objext" 1>&6 |
1775 | OBJEXT=$ac_cv_objext | |
1776 | ac_objext=$ac_cv_objext | |
1777 | ||
1778 | ||
1779 | ||
1780 | echo $ac_n "checking for executable suffix""... $ac_c" 1>&6 | |
c6f8758f | 1781 | echo "configure:1782: checking for executable suffix" >&5 |
6be7c12c AO |
1782 | if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then |
1783 | echo $ac_n "(cached) $ac_c" 1>&6 | |
ac48eca1 | 1784 | else |
6be7c12c AO |
1785 | if test "$CYGWIN" = yes || test "$MINGW32" = yes; then |
1786 | ac_cv_exeext=.exe | |
1787 | else | |
1788 | rm -f conftest* | |
1789 | echo 'int main () { return 0; }' > conftest.$ac_ext | |
1790 | ac_cv_exeext= | |
c6f8758f | 1791 | if { (eval echo configure:1792: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
6be7c12c AO |
1792 | for file in conftest.*; do |
1793 | case $file in | |
c6f8758f | 1794 | *.c | *.o | *.obj | *.ilk | *.pdb) ;; |
6be7c12c AO |
1795 | *) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;; |
1796 | esac | |
1797 | done | |
1798 | else | |
1799 | { echo "configure: error: installation or configuration problem: compiler cannot create executables." 1>&2; exit 1; } | |
1800 | fi | |
1801 | rm -f conftest* | |
1802 | test x"${ac_cv_exeext}" = x && ac_cv_exeext=no | |
1803 | fi | |
1804 | fi | |
1805 | ||
1806 | EXEEXT="" | |
1807 | test x"${ac_cv_exeext}" != xno && EXEEXT=${ac_cv_exeext} | |
1808 | echo "$ac_t""${ac_cv_exeext}" 1>&6 | |
1809 | ac_exeext=$EXEEXT | |
1810 | ||
1811 | # Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers! | |
1812 | ||
1813 | # Only perform the check for file, if the check method requires it | |
1814 | case $deplibs_check_method in | |
1815 | file_magic*) | |
1816 | if test "$file_magic_cmd" = '$MAGIC_CMD'; then | |
1817 | echo $ac_n "checking for ${ac_tool_prefix}file""... $ac_c" 1>&6 | |
c6f8758f | 1818 | echo "configure:1819: checking for ${ac_tool_prefix}file" >&5 |
6be7c12c AO |
1819 | if eval "test \"`echo '$''{'lt_cv_path_MAGIC_CMD'+set}'`\" = set"; then |
1820 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1821 | else | |
1822 | case $MAGIC_CMD in | |
1823 | /*) | |
1824 | lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. | |
1825 | ;; | |
1826 | ?:/*) | |
1827 | lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a dos path. | |
1828 | ;; | |
1829 | *) | |
d64552c5 | 1830 | ac_save_MAGIC_CMD="$MAGIC_CMD" |
ac48eca1 AO |
1831 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
1832 | ac_dummy="/usr/bin:$PATH" | |
1833 | for ac_dir in $ac_dummy; do | |
1834 | test -z "$ac_dir" && ac_dir=. | |
1835 | if test -f $ac_dir/${ac_tool_prefix}file; then | |
d64552c5 | 1836 | lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file" |
ac48eca1 | 1837 | if test -n "$file_magic_test_file"; then |
55c80943 | 1838 | case $deplibs_check_method in |
ac48eca1 AO |
1839 | "file_magic "*) |
1840 | file_magic_regex="`expr \"$deplibs_check_method\" : \"file_magic \(.*\)\"`" | |
d64552c5 | 1841 | MAGIC_CMD="$lt_cv_path_MAGIC_CMD" |
ac48eca1 AO |
1842 | if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | |
1843 | egrep "$file_magic_regex" > /dev/null; then | |
1844 | : | |
1845 | else | |
1846 | cat <<EOF 1>&2 | |
1847 | ||
1848 | *** Warning: the command libtool uses to detect shared libraries, | |
1849 | *** $file_magic_cmd, produces output that libtool cannot recognize. | |
1850 | *** The result is that libtool may fail to recognize shared libraries | |
1851 | *** as such. This will affect the creation of libtool libraries that | |
1852 | *** depend on shared libraries, but programs linked with such libtool | |
1853 | *** libraries will work regardless of this problem. Nevertheless, you | |
1854 | *** may want to report the problem to your system manager and/or to | |
1855 | *** bug-libtool@gnu.org | |
1856 | ||
1857 | EOF | |
1858 | fi ;; | |
1859 | esac | |
1860 | fi | |
1861 | break | |
1862 | fi | |
1863 | done | |
1864 | IFS="$ac_save_ifs" | |
d64552c5 | 1865 | MAGIC_CMD="$ac_save_MAGIC_CMD" |
ac48eca1 AO |
1866 | ;; |
1867 | esac | |
1868 | fi | |
1869 | ||
d64552c5 AO |
1870 | MAGIC_CMD="$lt_cv_path_MAGIC_CMD" |
1871 | if test -n "$MAGIC_CMD"; then | |
6be7c12c | 1872 | echo "$ac_t""$MAGIC_CMD" 1>&6 |
ac48eca1 | 1873 | else |
6be7c12c | 1874 | echo "$ac_t""no" 1>&6 |
ac48eca1 AO |
1875 | fi |
1876 | ||
d64552c5 | 1877 | if test -z "$lt_cv_path_MAGIC_CMD"; then |
ac48eca1 | 1878 | if test -n "$ac_tool_prefix"; then |
6be7c12c | 1879 | echo $ac_n "checking for file""... $ac_c" 1>&6 |
c6f8758f | 1880 | echo "configure:1881: checking for file" >&5 |
6be7c12c AO |
1881 | if eval "test \"`echo '$''{'lt_cv_path_MAGIC_CMD'+set}'`\" = set"; then |
1882 | echo $ac_n "(cached) $ac_c" 1>&6 | |
ac48eca1 | 1883 | else |
55c80943 | 1884 | case $MAGIC_CMD in |
ac48eca1 | 1885 | /*) |
d64552c5 | 1886 | lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. |
ac48eca1 AO |
1887 | ;; |
1888 | ?:/*) | |
d64552c5 | 1889 | lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a dos path. |
ac48eca1 AO |
1890 | ;; |
1891 | *) | |
d64552c5 | 1892 | ac_save_MAGIC_CMD="$MAGIC_CMD" |
ac48eca1 AO |
1893 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
1894 | ac_dummy="/usr/bin:$PATH" | |
1895 | for ac_dir in $ac_dummy; do | |
1896 | test -z "$ac_dir" && ac_dir=. | |
1897 | if test -f $ac_dir/file; then | |
d64552c5 | 1898 | lt_cv_path_MAGIC_CMD="$ac_dir/file" |
ac48eca1 | 1899 | if test -n "$file_magic_test_file"; then |
55c80943 | 1900 | case $deplibs_check_method in |
ac48eca1 AO |
1901 | "file_magic "*) |
1902 | file_magic_regex="`expr \"$deplibs_check_method\" : \"file_magic \(.*\)\"`" | |
d64552c5 | 1903 | MAGIC_CMD="$lt_cv_path_MAGIC_CMD" |
ac48eca1 AO |
1904 | if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | |
1905 | egrep "$file_magic_regex" > /dev/null; then | |
1906 | : | |
1907 | else | |
1908 | cat <<EOF 1>&2 | |
1909 | ||
1910 | *** Warning: the command libtool uses to detect shared libraries, | |
1911 | *** $file_magic_cmd, produces output that libtool cannot recognize. | |
1912 | *** The result is that libtool may fail to recognize shared libraries | |
1913 | *** as such. This will affect the creation of libtool libraries that | |
1914 | *** depend on shared libraries, but programs linked with such libtool | |
1915 | *** libraries will work regardless of this problem. Nevertheless, you | |
1916 | *** may want to report the problem to your system manager and/or to | |
1917 | *** bug-libtool@gnu.org | |
1918 | ||
1919 | EOF | |
1920 | fi ;; | |
1921 | esac | |
1922 | fi | |
1923 | break | |
1924 | fi | |
1925 | done | |
1926 | IFS="$ac_save_ifs" | |
d64552c5 | 1927 | MAGIC_CMD="$ac_save_MAGIC_CMD" |
ac48eca1 AO |
1928 | ;; |
1929 | esac | |
1930 | fi | |
1931 | ||
d64552c5 AO |
1932 | MAGIC_CMD="$lt_cv_path_MAGIC_CMD" |
1933 | if test -n "$MAGIC_CMD"; then | |
6be7c12c | 1934 | echo "$ac_t""$MAGIC_CMD" 1>&6 |
ac48eca1 | 1935 | else |
6be7c12c | 1936 | echo "$ac_t""no" 1>&6 |
ac48eca1 AO |
1937 | fi |
1938 | ||
1939 | else | |
d64552c5 | 1940 | MAGIC_CMD=: |
ac48eca1 AO |
1941 | fi |
1942 | fi | |
1943 | ||
1944 | fi | |
1945 | ;; | |
1946 | esac | |
1947 | ||
6be7c12c | 1948 | # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. |
ac48eca1 | 1949 | set dummy ${ac_tool_prefix}ranlib; ac_word=$2 |
6be7c12c | 1950 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
c6f8758f | 1951 | echo "configure:1952: checking for $ac_word" >&5 |
6be7c12c AO |
1952 | if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then |
1953 | echo $ac_n "(cached) $ac_c" 1>&6 | |
ac48eca1 AO |
1954 | else |
1955 | if test -n "$RANLIB"; then | |
1956 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. | |
1957 | else | |
6be7c12c AO |
1958 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
1959 | ac_dummy="$PATH" | |
1960 | for ac_dir in $ac_dummy; do | |
1961 | test -z "$ac_dir" && ac_dir=. | |
1962 | if test -f $ac_dir/$ac_word; then | |
1963 | ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" | |
1964 | break | |
1965 | fi | |
1966 | done | |
1967 | IFS="$ac_save_ifs" | |
ac48eca1 AO |
1968 | fi |
1969 | fi | |
6be7c12c | 1970 | RANLIB="$ac_cv_prog_RANLIB" |
ac48eca1 | 1971 | if test -n "$RANLIB"; then |
6be7c12c | 1972 | echo "$ac_t""$RANLIB" 1>&6 |
ac48eca1 | 1973 | else |
6be7c12c | 1974 | echo "$ac_t""no" 1>&6 |
ac48eca1 AO |
1975 | fi |
1976 | ||
6be7c12c | 1977 | |
ac48eca1 | 1978 | if test -z "$ac_cv_prog_RANLIB"; then |
6be7c12c | 1979 | if test -n "$ac_tool_prefix"; then |
ac48eca1 AO |
1980 | # Extract the first word of "ranlib", so it can be a program name with args. |
1981 | set dummy ranlib; ac_word=$2 | |
6be7c12c | 1982 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
c6f8758f | 1983 | echo "configure:1984: checking for $ac_word" >&5 |
6be7c12c AO |
1984 | if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then |
1985 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1986 | else | |
1987 | if test -n "$RANLIB"; then | |
1988 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. | |
1989 | else | |
1990 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
1991 | ac_dummy="$PATH" | |
1992 | for ac_dir in $ac_dummy; do | |
1993 | test -z "$ac_dir" && ac_dir=. | |
1994 | if test -f $ac_dir/$ac_word; then | |
1995 | ac_cv_prog_RANLIB="ranlib" | |
1996 | break | |
1997 | fi | |
1998 | done | |
1999 | IFS="$ac_save_ifs" | |
2000 | test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":" | |
ac48eca1 AO |
2001 | fi |
2002 | fi | |
6be7c12c AO |
2003 | RANLIB="$ac_cv_prog_RANLIB" |
2004 | if test -n "$RANLIB"; then | |
2005 | echo "$ac_t""$RANLIB" 1>&6 | |
ac48eca1 | 2006 | else |
6be7c12c | 2007 | echo "$ac_t""no" 1>&6 |
ac48eca1 AO |
2008 | fi |
2009 | ||
2010 | else | |
6be7c12c AO |
2011 | RANLIB=":" |
2012 | fi | |
ac48eca1 AO |
2013 | fi |
2014 | ||
6be7c12c | 2015 | # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. |
ac48eca1 | 2016 | set dummy ${ac_tool_prefix}strip; ac_word=$2 |
6be7c12c | 2017 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
c6f8758f | 2018 | echo "configure:2019: checking for $ac_word" >&5 |
6be7c12c AO |
2019 | if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then |
2020 | echo $ac_n "(cached) $ac_c" 1>&6 | |
ac48eca1 AO |
2021 | else |
2022 | if test -n "$STRIP"; then | |
2023 | ac_cv_prog_STRIP="$STRIP" # Let the user override the test. | |
2024 | else | |
6be7c12c AO |
2025 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
2026 | ac_dummy="$PATH" | |
2027 | for ac_dir in $ac_dummy; do | |
2028 | test -z "$ac_dir" && ac_dir=. | |
2029 | if test -f $ac_dir/$ac_word; then | |
2030 | ac_cv_prog_STRIP="${ac_tool_prefix}strip" | |
2031 | break | |
2032 | fi | |
2033 | done | |
2034 | IFS="$ac_save_ifs" | |
ac48eca1 AO |
2035 | fi |
2036 | fi | |
6be7c12c | 2037 | STRIP="$ac_cv_prog_STRIP" |
ac48eca1 | 2038 | if test -n "$STRIP"; then |
6be7c12c | 2039 | echo "$ac_t""$STRIP" 1>&6 |
ac48eca1 | 2040 | else |
6be7c12c | 2041 | echo "$ac_t""no" 1>&6 |
ac48eca1 AO |
2042 | fi |
2043 | ||
6be7c12c | 2044 | |
ac48eca1 | 2045 | if test -z "$ac_cv_prog_STRIP"; then |
6be7c12c | 2046 | if test -n "$ac_tool_prefix"; then |
ac48eca1 AO |
2047 | # Extract the first word of "strip", so it can be a program name with args. |
2048 | set dummy strip; ac_word=$2 | |
6be7c12c | 2049 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
c6f8758f | 2050 | echo "configure:2051: checking for $ac_word" >&5 |
6be7c12c AO |
2051 | if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then |
2052 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2053 | else | |
2054 | if test -n "$STRIP"; then | |
2055 | ac_cv_prog_STRIP="$STRIP" # Let the user override the test. | |
2056 | else | |
2057 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
2058 | ac_dummy="$PATH" | |
2059 | for ac_dir in $ac_dummy; do | |
2060 | test -z "$ac_dir" && ac_dir=. | |
2061 | if test -f $ac_dir/$ac_word; then | |
2062 | ac_cv_prog_STRIP="strip" | |
2063 | break | |
2064 | fi | |
2065 | done | |
2066 | IFS="$ac_save_ifs" | |
2067 | test -z "$ac_cv_prog_STRIP" && ac_cv_prog_STRIP=":" | |
ac48eca1 AO |
2068 | fi |
2069 | fi | |
6be7c12c AO |
2070 | STRIP="$ac_cv_prog_STRIP" |
2071 | if test -n "$STRIP"; then | |
2072 | echo "$ac_t""$STRIP" 1>&6 | |
ac48eca1 | 2073 | else |
6be7c12c | 2074 | echo "$ac_t""no" 1>&6 |
ac48eca1 AO |
2075 | fi |
2076 | ||
2077 | else | |
6be7c12c AO |
2078 | STRIP=":" |
2079 | fi | |
ac48eca1 | 2080 | fi |
252b5132 | 2081 | |
6be7c12c | 2082 | |
252b5132 | 2083 | # Check for any special flags to pass to ltconfig. |
b2ef150d | 2084 | libtool_flags="--cache-file=$cache_file" |
252b5132 RH |
2085 | test "$enable_shared" = no && libtool_flags="$libtool_flags --disable-shared" |
2086 | test "$enable_static" = no && libtool_flags="$libtool_flags --disable-static" | |
b2ef150d | 2087 | test "$enable_fast_install" = no && libtool_flags="$libtool_flags --disable-fast-install" |
55c80943 NC |
2088 | test "$GCC" = yes && libtool_flags="$libtool_flags --with-gcc" |
2089 | test "$lt_cv_prog_gnu_ld" = yes && libtool_flags="$libtool_flags --with-gnu-ld" | |
252b5132 | 2090 | |
6be7c12c | 2091 | |
a74801ba ILT |
2092 | # Check whether --enable-libtool-lock or --disable-libtool-lock was given. |
2093 | if test "${enable_libtool_lock+set}" = set; then | |
2094 | enableval="$enable_libtool_lock" | |
6be7c12c AO |
2095 | : |
2096 | fi | |
a74801ba ILT |
2097 | |
2098 | test "x$enable_libtool_lock" = xno && libtool_flags="$libtool_flags --disable-lock" | |
2099 | test x"$silent" = xyes && libtool_flags="$libtool_flags --silent" | |
2100 | ||
ac48eca1 AO |
2101 | # Check whether --with-pic or --without-pic was given. |
2102 | if test "${with_pic+set}" = set; then | |
2103 | withval="$with_pic" | |
2104 | pic_mode="$withval" | |
2105 | else | |
2106 | pic_mode=default | |
6be7c12c AO |
2107 | fi |
2108 | ||
ac48eca1 AO |
2109 | test x"$pic_mode" = xyes && libtool_flags="$libtool_flags --prefer-pic" |
2110 | test x"$pic_mode" = xno && libtool_flags="$libtool_flags --prefer-non-pic" | |
2111 | ||
252b5132 RH |
2112 | # Some flags need to be propagated to the compiler or linker for good |
2113 | # libtool support. | |
55c80943 | 2114 | case $host in |
252b5132 RH |
2115 | *-*-irix6*) |
2116 | # Find out which ABI we are using. | |
c6f8758f NC |
2117 | echo '#line 2118 "configure"' > conftest.$ac_ext |
2118 | if { (eval echo configure:2119: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then | |
6a457e5c NC |
2119 | if test "$lt_cv_prog_gnu_ld" = yes; then |
2120 | case `/usr/bin/file conftest.$ac_objext` in | |
2121 | *32-bit*) | |
2122 | LD="${LD-ld} -melf32bsmip" | |
2123 | ;; | |
2124 | *N32*) | |
2125 | LD="${LD-ld} -melf32bmipn32" | |
2126 | ;; | |
2127 | *64-bit*) | |
2128 | LD="${LD-ld} -melf64bmip" | |
2129 | ;; | |
2130 | esac | |
2131 | else | |
55c80943 | 2132 | case `/usr/bin/file conftest.$ac_objext` in |
252b5132 RH |
2133 | *32-bit*) |
2134 | LD="${LD-ld} -32" | |
2135 | ;; | |
2136 | *N32*) | |
2137 | LD="${LD-ld} -n32" | |
2138 | ;; | |
2139 | *64-bit*) | |
2140 | LD="${LD-ld} -64" | |
2141 | ;; | |
2142 | esac | |
6a457e5c | 2143 | fi |
252b5132 RH |
2144 | fi |
2145 | rm -rf conftest* | |
2146 | ;; | |
2147 | ||
4867be41 DJ |
2148 | ia64-*-hpux*) |
2149 | # Find out which ABI we are using. | |
2150 | echo 'int i;' > conftest.$ac_ext | |
c6f8758f | 2151 | if { (eval echo configure:2152: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
4867be41 DJ |
2152 | case "`/usr/bin/file conftest.o`" in |
2153 | *ELF-32*) | |
2154 | HPUX_IA64_MODE="32" | |
2155 | ;; | |
2156 | *ELF-64*) | |
2157 | HPUX_IA64_MODE="64" | |
2158 | ;; | |
2159 | esac | |
2160 | fi | |
2161 | rm -rf conftest* | |
2162 | ;; | |
2163 | ||
252b5132 RH |
2164 | *-*-sco3.2v5*) |
2165 | # On SCO OpenServer 5, we need -belf to get full-featured binaries. | |
b2ef150d | 2166 | SAVE_CFLAGS="$CFLAGS" |
252b5132 | 2167 | CFLAGS="$CFLAGS -belf" |
6be7c12c | 2168 | echo $ac_n "checking whether the C compiler needs -belf""... $ac_c" 1>&6 |
c6f8758f | 2169 | echo "configure:2170: checking whether the C compiler needs -belf" >&5 |
6be7c12c AO |
2170 | if eval "test \"`echo '$''{'lt_cv_cc_needs_belf'+set}'`\" = set"; then |
2171 | echo $ac_n "(cached) $ac_c" 1>&6 | |
b2ef150d | 2172 | else |
6be7c12c | 2173 | |
ac48eca1 | 2174 | ac_ext=c |
6be7c12c | 2175 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. |
ac48eca1 | 2176 | ac_cpp='$CPP $CPPFLAGS' |
6be7c12c AO |
2177 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' |
2178 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' | |
2179 | cross_compiling=$ac_cv_prog_cc_cross | |
ac48eca1 | 2180 | |
6be7c12c | 2181 | cat > conftest.$ac_ext <<EOF |
c6f8758f | 2182 | #line 2183 "configure" |
b2ef150d ILT |
2183 | #include "confdefs.h" |
2184 | ||
6be7c12c | 2185 | int main() { |
b2ef150d | 2186 | |
6be7c12c AO |
2187 | ; return 0; } |
2188 | EOF | |
c6f8758f | 2189 | if { (eval echo configure:2190: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
6be7c12c | 2190 | rm -rf conftest* |
b2ef150d ILT |
2191 | lt_cv_cc_needs_belf=yes |
2192 | else | |
6be7c12c AO |
2193 | echo "configure: failed program was:" >&5 |
2194 | cat conftest.$ac_ext >&5 | |
2195 | rm -rf conftest* | |
2196 | lt_cv_cc_needs_belf=no | |
b2ef150d | 2197 | fi |
6be7c12c | 2198 | rm -f conftest* |
ac48eca1 | 2199 | ac_ext=c |
6be7c12c | 2200 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. |
ac48eca1 | 2201 | ac_cpp='$CPP $CPPFLAGS' |
6be7c12c AO |
2202 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' |
2203 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' | |
2204 | cross_compiling=$ac_cv_prog_cc_cross | |
ac48eca1 | 2205 | |
b2ef150d | 2206 | fi |
6be7c12c AO |
2207 | |
2208 | echo "$ac_t""$lt_cv_cc_needs_belf" 1>&6 | |
b2ef150d ILT |
2209 | if test x"$lt_cv_cc_needs_belf" != x"yes"; then |
2210 | # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf | |
2211 | CFLAGS="$SAVE_CFLAGS" | |
2212 | fi | |
252b5132 RH |
2213 | ;; |
2214 | ||
6be7c12c | 2215 | |
252b5132 RH |
2216 | esac |
2217 | ||
6be7c12c | 2218 | |
b2ef150d | 2219 | # Save cache, so that ltconfig can load it |
6be7c12c | 2220 | cat > confcache <<\EOF |
b2ef150d ILT |
2221 | # This file is a shell script that caches the results of configure |
2222 | # tests run on this system so they can be shared between configure | |
6be7c12c AO |
2223 | # scripts and configure runs. It is not useful on other systems. |
2224 | # If it contains results you don't want to keep, you may remove or edit it. | |
b2ef150d | 2225 | # |
6be7c12c AO |
2226 | # By default, configure uses ./config.cache as the cache file, |
2227 | # creating it if it does not exist already. You can give configure | |
2228 | # the --cache-file=FILE option to use a different cache file; that is | |
2229 | # what configure does when it calls configure scripts in | |
2230 | # subdirectories, so they share the cache. | |
2231 | # Giving --cache-file=/dev/null disables caching, for debugging configure. | |
2232 | # config.status only pays attention to the cache file if you give it the | |
2233 | # --recheck option to rerun configure. | |
b2ef150d | 2234 | # |
6be7c12c | 2235 | EOF |
b2ef150d ILT |
2236 | # The following way of writing the cache mishandles newlines in values, |
2237 | # but we know of no workaround that is simple, portable, and efficient. | |
2238 | # So, don't put newlines in cache variables' values. | |
2239 | # Ultrix sh set writes to stderr and can't be redirected directly, | |
2240 | # and sets the high bit in the cache file unless we assign to the vars. | |
6be7c12c AO |
2241 | (set) 2>&1 | |
2242 | case `(ac_space=' '; set | grep ac_space) 2>&1` in | |
2243 | *ac_space=\ *) | |
2244 | # `set' does not quote correctly, so add quotes (double-quote substitution | |
2245 | # turns \\\\ into \\, and sed turns \\ into \). | |
2246 | sed -n \ | |
2247 | -e "s/'/'\\\\''/g" \ | |
2248 | -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p" | |
2249 | ;; | |
2250 | *) | |
2251 | # `set' quotes correctly as required by POSIX, so do not add quotes. | |
2252 | sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p' | |
2253 | ;; | |
2254 | esac >> confcache | |
2255 | if cmp -s $cache_file confcache; then | |
2256 | : | |
2257 | else | |
b2ef150d | 2258 | if test -w $cache_file; then |
6be7c12c AO |
2259 | echo "updating cache $cache_file" |
2260 | cat confcache > $cache_file | |
b2ef150d ILT |
2261 | else |
2262 | echo "not updating unwritable cache $cache_file" | |
2263 | fi | |
2264 | fi | |
2265 | rm -f confcache | |
2266 | ||
6be7c12c | 2267 | |
252b5132 | 2268 | # Actually configure libtool. ac_aux_dir is where install-sh is found. |
ac48eca1 | 2269 | AR="$AR" LTCC="$CC" CC="$CC" CFLAGS="$CFLAGS" CPPFLAGS="$CPPFLAGS" \ |
d64552c5 | 2270 | MAGIC_CMD="$MAGIC_CMD" LD="$LD" LDFLAGS="$LDFLAGS" LIBS="$LIBS" \ |
ac48eca1 AO |
2271 | LN_S="$LN_S" NM="$NM" RANLIB="$RANLIB" STRIP="$STRIP" \ |
2272 | AS="$AS" DLLTOOL="$DLLTOOL" OBJDUMP="$OBJDUMP" \ | |
2273 | objext="$OBJEXT" exeext="$EXEEXT" reload_flag="$reload_flag" \ | |
2274 | deplibs_check_method="$deplibs_check_method" file_magic_cmd="$file_magic_cmd" \ | |
252b5132 | 2275 | ${CONFIG_SHELL-/bin/sh} $ac_aux_dir/ltconfig --no-reexec \ |
ac48eca1 | 2276 | $libtool_flags --no-verify --build="$build" $ac_aux_dir/ltmain.sh $host \ |
6be7c12c | 2277 | || { echo "configure: error: libtool configure failed" 1>&2; exit 1; } |
252b5132 | 2278 | |
b2ef150d ILT |
2279 | # Reload cache, that may have been modified by ltconfig |
2280 | if test -r "$cache_file"; then | |
6be7c12c AO |
2281 | echo "loading cache $cache_file" |
2282 | . $cache_file | |
b2ef150d | 2283 | else |
6be7c12c AO |
2284 | echo "creating cache $cache_file" |
2285 | > $cache_file | |
b2ef150d ILT |
2286 | fi |
2287 | ||
6be7c12c | 2288 | |
b2ef150d | 2289 | # This can be used to rebuild libtool when needed |
ac48eca1 | 2290 | LIBTOOL_DEPS="$ac_aux_dir/ltconfig $ac_aux_dir/ltmain.sh $ac_aux_dir/ltcf-c.sh" |
b2ef150d ILT |
2291 | |
2292 | # Always use our own libtool. | |
2293 | LIBTOOL='$(SHELL) $(top_builddir)/libtool' | |
2294 | ||
252b5132 RH |
2295 | # Redirect the config.log output again, so that the ltconfig log is not |
2296 | # clobbered by the next message. | |
2297 | exec 5>>./config.log | |
2298 | ||
6be7c12c AO |
2299 | |
2300 | ||
2301 | ||
2302 | ||
2303 | ||
2304 | ||
252b5132 RH |
2305 | # Check whether --enable-64-bit-bfd or --disable-64-bit-bfd was given. |
2306 | if test "${enable_64_bit_bfd+set}" = set; then | |
2307 | enableval="$enable_64_bit_bfd" | |
2308 | case "${enableval}" in | |
2309 | yes) want64=true ;; | |
2310 | no) want64=false ;; | |
6be7c12c | 2311 | *) { echo "configure: error: bad value ${enableval} for 64-bit-bfd option" 1>&2; exit 1; } ;; |
252b5132 RH |
2312 | esac |
2313 | else | |
2314 | want64=false | |
6be7c12c AO |
2315 | fi |
2316 | # Check whether --enable-targets or --disable-targets was given. | |
252b5132 RH |
2317 | if test "${enable_targets+set}" = set; then |
2318 | enableval="$enable_targets" | |
2319 | case "${enableval}" in | |
6be7c12c | 2320 | yes | "") { echo "configure: error: enable-targets option must specify target names or 'all'" 1>&2; exit 1; } |
252b5132 RH |
2321 | ;; |
2322 | no) enable_targets= ;; | |
2323 | *) enable_targets=$enableval ;; | |
2324 | esac | |
6be7c12c AO |
2325 | fi |
2326 | # Check whether --enable-commonbfdlib or --disable-commonbfdlib was given. | |
252b5132 RH |
2327 | if test "${enable_commonbfdlib+set}" = set; then |
2328 | enableval="$enable_commonbfdlib" | |
2329 | case "${enableval}" in | |
2330 | yes) commonbfdlib=true ;; | |
2331 | no) commonbfdlib=false ;; | |
6be7c12c | 2332 | *) { echo "configure: error: bad value ${enableval} for BFD commonbfdlib option" 1>&2; exit 1; } ;; |
252b5132 | 2333 | esac |
6be7c12c | 2334 | fi |
252b5132 RH |
2335 | # Check whether --with-mmap or --without-mmap was given. |
2336 | if test "${with_mmap+set}" = set; then | |
2337 | withval="$with_mmap" | |
2338 | case "${withval}" in | |
2339 | yes) want_mmap=true ;; | |
2340 | no) want_mmap=false ;; | |
6be7c12c | 2341 | *) { echo "configure: error: bad value ${withval} for BFD with-mmap option" 1>&2; exit 1; } ;; |
252b5132 RH |
2342 | esac |
2343 | else | |
2344 | want_mmap=false | |
6be7c12c AO |
2345 | fi |
2346 | ||
0218d1e4 | 2347 | build_warnings="-W -Wall -Wstrict-prototypes -Wmissing-prototypes" |
a2d91340 AC |
2348 | # Check whether --enable-build-warnings or --disable-build-warnings was given. |
2349 | if test "${enable_build_warnings+set}" = set; then | |
2350 | enableval="$enable_build_warnings" | |
2351 | case "${enableval}" in | |
2352 | yes) ;; | |
2353 | no) build_warnings="-w";; | |
2354 | ,*) t=`echo "${enableval}" | sed -e "s/,/ /g"` | |
2355 | build_warnings="${build_warnings} ${t}";; | |
2356 | *,) t=`echo "${enableval}" | sed -e "s/,/ /g"` | |
2357 | build_warnings="${t} ${build_warnings}";; | |
2358 | *) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;; | |
2359 | esac | |
2360 | if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then | |
2361 | echo "Setting warning flags = $build_warnings" 6>&1 | |
2362 | fi | |
6be7c12c AO |
2363 | fi |
2364 | WARN_CFLAGS="" | |
66e25bab | 2365 | if test "x${build_warnings}" != x && test "x$GCC" = xyes ; then |
a2d91340 AC |
2366 | WARN_CFLAGS="${build_warnings}" |
2367 | fi | |
2368 | ||
2369 | ||
6be7c12c AO |
2370 | |
2371 | ||
2372 | ||
252b5132 RH |
2373 | |
2374 | if test -z "$target" ; then | |
6be7c12c | 2375 | { echo "configure: error: Unrecognized target system type; please check config.sub." 1>&2; exit 1; } |
252b5132 | 2376 | fi |
252b5132 | 2377 | |
6be7c12c | 2378 | echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6 |
c6f8758f | 2379 | echo "configure:2380: checking whether to enable maintainer-specific portions of Makefiles" >&5 |
252b5132 RH |
2380 | # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given. |
2381 | if test "${enable_maintainer_mode+set}" = set; then | |
2382 | enableval="$enable_maintainer_mode" | |
2383 | USE_MAINTAINER_MODE=$enableval | |
2384 | else | |
2385 | USE_MAINTAINER_MODE=no | |
6be7c12c AO |
2386 | fi |
2387 | ||
2388 | echo "$ac_t""$USE_MAINTAINER_MODE" 1>&6 | |
2389 | ||
252b5132 RH |
2390 | |
2391 | if test $USE_MAINTAINER_MODE = yes; then | |
2392 | MAINTAINER_MODE_TRUE= | |
2393 | MAINTAINER_MODE_FALSE='#' | |
2394 | else | |
2395 | MAINTAINER_MODE_TRUE='#' | |
2396 | MAINTAINER_MODE_FALSE= | |
2397 | fi | |
2398 | MAINT=$MAINTAINER_MODE_TRUE | |
6be7c12c | 2399 | |
252b5132 | 2400 | |
a703a6ea | 2401 | echo $ac_n "checking whether to install libbfd""... $ac_c" 1>&6 |
c6f8758f | 2402 | echo "configure:2403: checking whether to install libbfd" >&5 |
a703a6ea AM |
2403 | # Check whether --enable-install-libbfd or --disable-install-libbfd was given. |
2404 | if test "${enable_install_libbfd+set}" = set; then | |
2405 | enableval="$enable_install_libbfd" | |
2406 | install_libbfd_p=$enableval | |
2407 | else | |
66e25bab | 2408 | if test "${host}" = "${target}" || test "$enable_shared" = "yes"; then |
a703a6ea AM |
2409 | install_libbfd_p=yes |
2410 | else | |
2411 | install_libbfd_p=no | |
2412 | fi | |
2413 | fi | |
2414 | ||
2415 | echo "$ac_t""$install_libbfd_p" 1>&6 | |
2416 | ||
2417 | ||
2418 | if test $install_libbfd_p = yes; then | |
2419 | INSTALL_LIBBFD_TRUE= | |
2420 | INSTALL_LIBBFD_FALSE='#' | |
2421 | else | |
2422 | INSTALL_LIBBFD_TRUE='#' | |
2423 | INSTALL_LIBBFD_FALSE= | |
2424 | fi | |
2425 | # libbfd.a is a host library containing target dependent code | |
2426 | bfdlibdir='$(libdir)' | |
2427 | bfdincludedir='$(includedir)' | |
2428 | if test "${host}" != "${target}"; then | |
2429 | bfdlibdir='$(exec_prefix)/$(host_alias)/$(target_alias)/lib' | |
2430 | bfdincludedir='$(exec_prefix)/$(host_alias)/$(target_alias)/include' | |
2431 | fi | |
2432 | ||
2433 | ||
2434 | ||
2435 | ||
252b5132 RH |
2436 | |
2437 | ||
6be7c12c | 2438 | echo $ac_n "checking for executable suffix""... $ac_c" 1>&6 |
c6f8758f | 2439 | echo "configure:2440: checking for executable suffix" >&5 |
6be7c12c AO |
2440 | if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then |
2441 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 2442 | else |
6be7c12c AO |
2443 | if test "$CYGWIN" = yes || test "$MINGW32" = yes; then |
2444 | ac_cv_exeext=.exe | |
252b5132 | 2445 | else |
6be7c12c AO |
2446 | rm -f conftest* |
2447 | echo 'int main () { return 0; }' > conftest.$ac_ext | |
2448 | ac_cv_exeext= | |
c6f8758f | 2449 | if { (eval echo configure:2450: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
6be7c12c AO |
2450 | for file in conftest.*; do |
2451 | case $file in | |
c6f8758f | 2452 | *.c | *.o | *.obj | *.ilk | *.pdb) ;; |
6be7c12c AO |
2453 | *) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;; |
2454 | esac | |
2455 | done | |
2456 | else | |
2457 | { echo "configure: error: installation or configuration problem: compiler cannot create executables." 1>&2; exit 1; } | |
2458 | fi | |
2459 | rm -f conftest* | |
2460 | test x"${ac_cv_exeext}" = x && ac_cv_exeext=no | |
252b5132 | 2461 | fi |
b3baf5d0 | 2462 | fi |
252b5132 | 2463 | |
6be7c12c AO |
2464 | EXEEXT="" |
2465 | test x"${ac_cv_exeext}" != xno && EXEEXT=${ac_cv_exeext} | |
2466 | echo "$ac_t""${ac_cv_exeext}" 1>&6 | |
2467 | ac_exeext=$EXEEXT | |
252b5132 | 2468 | |
252b5132 | 2469 | |
6be7c12c AO |
2470 | host64=false |
2471 | target64=false | |
69263e90 | 2472 | bfd_default_target_size=32 |
252b5132 | 2473 | |
6be7c12c AO |
2474 | # host stuff: |
2475 | ||
2476 | # Extract the first word of "gcc", so it can be a program name with args. | |
2477 | set dummy gcc; ac_word=$2 | |
2478 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
c6f8758f | 2479 | echo "configure:2480: checking for $ac_word" >&5 |
6be7c12c AO |
2480 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
2481 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 RH |
2482 | else |
2483 | if test -n "$CC"; then | |
2484 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
2485 | else | |
6be7c12c AO |
2486 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
2487 | ac_dummy="$PATH" | |
2488 | for ac_dir in $ac_dummy; do | |
2489 | test -z "$ac_dir" && ac_dir=. | |
2490 | if test -f $ac_dir/$ac_word; then | |
2491 | ac_cv_prog_CC="gcc" | |
2492 | break | |
2493 | fi | |
2494 | done | |
2495 | IFS="$ac_save_ifs" | |
252b5132 RH |
2496 | fi |
2497 | fi | |
6be7c12c | 2498 | CC="$ac_cv_prog_CC" |
252b5132 | 2499 | if test -n "$CC"; then |
6be7c12c | 2500 | echo "$ac_t""$CC" 1>&6 |
b3baf5d0 | 2501 | else |
6be7c12c | 2502 | echo "$ac_t""no" 1>&6 |
b3baf5d0 NC |
2503 | fi |
2504 | ||
252b5132 RH |
2505 | if test -z "$CC"; then |
2506 | # Extract the first word of "cc", so it can be a program name with args. | |
2507 | set dummy cc; ac_word=$2 | |
6be7c12c | 2508 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
c6f8758f | 2509 | echo "configure:2510: checking for $ac_word" >&5 |
6be7c12c AO |
2510 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
2511 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 RH |
2512 | else |
2513 | if test -n "$CC"; then | |
2514 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
2515 | else | |
6be7c12c | 2516 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
252b5132 | 2517 | ac_prog_rejected=no |
6be7c12c AO |
2518 | ac_dummy="$PATH" |
2519 | for ac_dir in $ac_dummy; do | |
2520 | test -z "$ac_dir" && ac_dir=. | |
2521 | if test -f $ac_dir/$ac_word; then | |
2522 | if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then | |
2523 | ac_prog_rejected=yes | |
2524 | continue | |
2525 | fi | |
2526 | ac_cv_prog_CC="cc" | |
2527 | break | |
2528 | fi | |
2529 | done | |
2530 | IFS="$ac_save_ifs" | |
252b5132 RH |
2531 | if test $ac_prog_rejected = yes; then |
2532 | # We found a bogon in the path, so make sure we never use it. | |
2533 | set dummy $ac_cv_prog_CC | |
2534 | shift | |
6be7c12c | 2535 | if test $# -gt 0; then |
252b5132 RH |
2536 | # We chose a different compiler from the bogus one. |
2537 | # However, it has the same basename, so the bogon will be chosen | |
2538 | # first if we set CC to just the basename; use the full file name. | |
2539 | shift | |
6be7c12c | 2540 | set dummy "$ac_dir/$ac_word" "$@" |
252b5132 RH |
2541 | shift |
2542 | ac_cv_prog_CC="$@" | |
2543 | fi | |
2544 | fi | |
2545 | fi | |
2546 | fi | |
6be7c12c | 2547 | CC="$ac_cv_prog_CC" |
252b5132 | 2548 | if test -n "$CC"; then |
6be7c12c | 2549 | echo "$ac_t""$CC" 1>&6 |
252b5132 | 2550 | else |
6be7c12c | 2551 | echo "$ac_t""no" 1>&6 |
252b5132 RH |
2552 | fi |
2553 | ||
6be7c12c AO |
2554 | if test -z "$CC"; then |
2555 | case "`uname -s`" in | |
2556 | *win32* | *WIN32*) | |
2557 | # Extract the first word of "cl", so it can be a program name with args. | |
2558 | set dummy cl; ac_word=$2 | |
2559 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
c6f8758f | 2560 | echo "configure:2561: checking for $ac_word" >&5 |
6be7c12c AO |
2561 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
2562 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 RH |
2563 | else |
2564 | if test -n "$CC"; then | |
2565 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
2566 | else | |
6be7c12c AO |
2567 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
2568 | ac_dummy="$PATH" | |
2569 | for ac_dir in $ac_dummy; do | |
2570 | test -z "$ac_dir" && ac_dir=. | |
2571 | if test -f $ac_dir/$ac_word; then | |
2572 | ac_cv_prog_CC="cl" | |
2573 | break | |
2574 | fi | |
2575 | done | |
2576 | IFS="$ac_save_ifs" | |
252b5132 RH |
2577 | fi |
2578 | fi | |
6be7c12c | 2579 | CC="$ac_cv_prog_CC" |
252b5132 | 2580 | if test -n "$CC"; then |
6be7c12c | 2581 | echo "$ac_t""$CC" 1>&6 |
252b5132 | 2582 | else |
6be7c12c | 2583 | echo "$ac_t""no" 1>&6 |
252b5132 | 2584 | fi |
6be7c12c AO |
2585 | ;; |
2586 | esac | |
2587 | fi | |
2588 | test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; } | |
b3baf5d0 | 2589 | fi |
252b5132 | 2590 | |
6be7c12c | 2591 | echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 |
c6f8758f | 2592 | echo "configure:2593: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 |
252b5132 | 2593 | |
6be7c12c AO |
2594 | ac_ext=c |
2595 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. | |
2596 | ac_cpp='$CPP $CPPFLAGS' | |
2597 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' | |
2598 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' | |
2599 | cross_compiling=$ac_cv_prog_cc_cross | |
252b5132 | 2600 | |
6be7c12c | 2601 | cat > conftest.$ac_ext << EOF |
252b5132 | 2602 | |
c6f8758f | 2603 | #line 2604 "configure" |
6be7c12c AO |
2604 | #include "confdefs.h" |
2605 | ||
2606 | main(){return(0);} | |
2607 | EOF | |
c6f8758f | 2608 | if { (eval echo configure:2609: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
6be7c12c AO |
2609 | ac_cv_prog_cc_works=yes |
2610 | # If we can't run a trivial program, we are probably using a cross compiler. | |
2611 | if (./conftest; exit) 2>/dev/null; then | |
2612 | ac_cv_prog_cc_cross=no | |
2613 | else | |
2614 | ac_cv_prog_cc_cross=yes | |
2615 | fi | |
2616 | else | |
2617 | echo "configure: failed program was:" >&5 | |
2618 | cat conftest.$ac_ext >&5 | |
2619 | ac_cv_prog_cc_works=no | |
252b5132 | 2620 | fi |
6be7c12c AO |
2621 | rm -fr conftest* |
2622 | ac_ext=c | |
2623 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. | |
2624 | ac_cpp='$CPP $CPPFLAGS' | |
2625 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' | |
2626 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' | |
2627 | cross_compiling=$ac_cv_prog_cc_cross | |
252b5132 | 2628 | |
6be7c12c AO |
2629 | echo "$ac_t""$ac_cv_prog_cc_works" 1>&6 |
2630 | if test $ac_cv_prog_cc_works = no; then | |
2631 | { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; } | |
2632 | fi | |
2633 | echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 | |
c6f8758f | 2634 | echo "configure:2635: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 |
6be7c12c AO |
2635 | echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6 |
2636 | cross_compiling=$ac_cv_prog_cc_cross | |
b3baf5d0 | 2637 | |
6be7c12c | 2638 | echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6 |
c6f8758f | 2639 | echo "configure:2640: checking whether we are using GNU C" >&5 |
6be7c12c AO |
2640 | if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then |
2641 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 2642 | else |
6be7c12c AO |
2643 | cat > conftest.c <<EOF |
2644 | #ifdef __GNUC__ | |
2645 | yes; | |
252b5132 | 2646 | #endif |
6be7c12c | 2647 | EOF |
c6f8758f | 2648 | if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:2649: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then |
6be7c12c AO |
2649 | ac_cv_prog_gcc=yes |
2650 | else | |
2651 | ac_cv_prog_gcc=no | |
2652 | fi | |
2653 | fi | |
252b5132 | 2654 | |
6be7c12c | 2655 | echo "$ac_t""$ac_cv_prog_gcc" 1>&6 |
252b5132 | 2656 | |
6be7c12c AO |
2657 | if test $ac_cv_prog_gcc = yes; then |
2658 | GCC=yes | |
2659 | else | |
2660 | GCC= | |
2661 | fi | |
252b5132 | 2662 | |
6be7c12c AO |
2663 | ac_test_CFLAGS="${CFLAGS+set}" |
2664 | ac_save_CFLAGS="$CFLAGS" | |
2665 | CFLAGS= | |
2666 | echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 | |
c6f8758f | 2667 | echo "configure:2668: checking whether ${CC-cc} accepts -g" >&5 |
6be7c12c AO |
2668 | if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then |
2669 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2670 | else | |
2671 | echo 'void f(){}' > conftest.c | |
2672 | if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then | |
252b5132 RH |
2673 | ac_cv_prog_cc_g=yes |
2674 | else | |
6be7c12c | 2675 | ac_cv_prog_cc_g=no |
252b5132 | 2676 | fi |
6be7c12c AO |
2677 | rm -f conftest* |
2678 | ||
252b5132 | 2679 | fi |
6be7c12c AO |
2680 | |
2681 | echo "$ac_t""$ac_cv_prog_cc_g" 1>&6 | |
252b5132 | 2682 | if test "$ac_test_CFLAGS" = set; then |
6be7c12c | 2683 | CFLAGS="$ac_save_CFLAGS" |
252b5132 RH |
2684 | elif test $ac_cv_prog_cc_g = yes; then |
2685 | if test "$GCC" = yes; then | |
2686 | CFLAGS="-g -O2" | |
2687 | else | |
2688 | CFLAGS="-g" | |
2689 | fi | |
2690 | else | |
2691 | if test "$GCC" = yes; then | |
2692 | CFLAGS="-O2" | |
2693 | else | |
2694 | CFLAGS= | |
2695 | fi | |
2696 | fi | |
2697 | ||
2698 | ||
f9d1e83f | 2699 | ALL_LINGUAS="fr tr ja es sv da zh_CN ro" |
6be7c12c | 2700 | echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6 |
c6f8758f | 2701 | echo "configure:2702: checking how to run the C preprocessor" >&5 |
252b5132 RH |
2702 | # On Suns, sometimes $CPP names a directory. |
2703 | if test -n "$CPP" && test -d "$CPP"; then | |
2704 | CPP= | |
2705 | fi | |
2706 | if test -z "$CPP"; then | |
6be7c12c AO |
2707 | if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then |
2708 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2709 | else | |
2710 | # This must be in double quotes, not single quotes, because CPP may get | |
2711 | # substituted into the Makefile and "${CC-cc}" will confuse make. | |
2712 | CPP="${CC-cc} -E" | |
2713 | # On the NeXT, cc -E runs the code through the compiler's parser, | |
2714 | # not just through cpp. | |
2715 | cat > conftest.$ac_ext <<EOF | |
c6f8758f | 2716 | #line 2717 "configure" |
252b5132 RH |
2717 | #include "confdefs.h" |
2718 | #include <assert.h> | |
6be7c12c AO |
2719 | Syntax Error |
2720 | EOF | |
2721 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
c6f8758f | 2722 | { (eval echo configure:2723: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
6be7c12c AO |
2723 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
2724 | if test -z "$ac_err"; then | |
2725 | : | |
252b5132 | 2726 | else |
6be7c12c AO |
2727 | echo "$ac_err" >&5 |
2728 | echo "configure: failed program was:" >&5 | |
2729 | cat conftest.$ac_ext >&5 | |
2730 | rm -rf conftest* | |
2731 | CPP="${CC-cc} -E -traditional-cpp" | |
2732 | cat > conftest.$ac_ext <<EOF | |
c6f8758f | 2733 | #line 2734 "configure" |
252b5132 | 2734 | #include "confdefs.h" |
6be7c12c AO |
2735 | #include <assert.h> |
2736 | Syntax Error | |
2737 | EOF | |
2738 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
c6f8758f | 2739 | { (eval echo configure:2740: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
6be7c12c AO |
2740 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
2741 | if test -z "$ac_err"; then | |
2742 | : | |
252b5132 | 2743 | else |
6be7c12c AO |
2744 | echo "$ac_err" >&5 |
2745 | echo "configure: failed program was:" >&5 | |
252b5132 | 2746 | cat conftest.$ac_ext >&5 |
6be7c12c AO |
2747 | rm -rf conftest* |
2748 | CPP="${CC-cc} -nologo -E" | |
2749 | cat > conftest.$ac_ext <<EOF | |
c6f8758f | 2750 | #line 2751 "configure" |
6be7c12c AO |
2751 | #include "confdefs.h" |
2752 | #include <assert.h> | |
2753 | Syntax Error | |
2754 | EOF | |
2755 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
c6f8758f | 2756 | { (eval echo configure:2757: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
6be7c12c AO |
2757 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
2758 | if test -z "$ac_err"; then | |
2759 | : | |
b3baf5d0 | 2760 | else |
6be7c12c AO |
2761 | echo "$ac_err" >&5 |
2762 | echo "configure: failed program was:" >&5 | |
b3baf5d0 | 2763 | cat conftest.$ac_ext >&5 |
6be7c12c AO |
2764 | rm -rf conftest* |
2765 | CPP=/lib/cpp | |
252b5132 | 2766 | fi |
6be7c12c | 2767 | rm -f conftest* |
252b5132 | 2768 | fi |
6be7c12c | 2769 | rm -f conftest* |
252b5132 | 2770 | fi |
6be7c12c AO |
2771 | rm -f conftest* |
2772 | ac_cv_prog_CPP="$CPP" | |
2773 | fi | |
2774 | CPP="$ac_cv_prog_CPP" | |
ac48eca1 | 2775 | else |
6be7c12c | 2776 | ac_cv_prog_CPP="$CPP" |
b3baf5d0 | 2777 | fi |
6be7c12c AO |
2778 | echo "$ac_t""$CPP" 1>&6 |
2779 | ||
2780 | # Extract the first word of "ranlib", so it can be a program name with args. | |
2781 | set dummy ranlib; ac_word=$2 | |
2782 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
c6f8758f | 2783 | echo "configure:2784: checking for $ac_word" >&5 |
6be7c12c AO |
2784 | if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then |
2785 | echo $ac_n "(cached) $ac_c" 1>&6 | |
ac48eca1 | 2786 | else |
6be7c12c AO |
2787 | if test -n "$RANLIB"; then |
2788 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. | |
2789 | else | |
2790 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
2791 | ac_dummy="$PATH" | |
2792 | for ac_dir in $ac_dummy; do | |
2793 | test -z "$ac_dir" && ac_dir=. | |
2794 | if test -f $ac_dir/$ac_word; then | |
2795 | ac_cv_prog_RANLIB="ranlib" | |
2796 | break | |
ac48eca1 | 2797 | fi |
6be7c12c AO |
2798 | done |
2799 | IFS="$ac_save_ifs" | |
2800 | test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":" | |
ac48eca1 AO |
2801 | fi |
2802 | fi | |
6be7c12c AO |
2803 | RANLIB="$ac_cv_prog_RANLIB" |
2804 | if test -n "$RANLIB"; then | |
2805 | echo "$ac_t""$RANLIB" 1>&6 | |
ac48eca1 | 2806 | else |
6be7c12c | 2807 | echo "$ac_t""no" 1>&6 |
b3baf5d0 | 2808 | fi |
ac48eca1 | 2809 | |
6be7c12c | 2810 | echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6 |
c6f8758f | 2811 | echo "configure:2812: checking for ANSI C header files" >&5 |
6be7c12c AO |
2812 | if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then |
2813 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 2814 | else |
6be7c12c | 2815 | cat > conftest.$ac_ext <<EOF |
c6f8758f | 2816 | #line 2817 "configure" |
252b5132 RH |
2817 | #include "confdefs.h" |
2818 | #include <stdlib.h> | |
2819 | #include <stdarg.h> | |
2820 | #include <string.h> | |
2821 | #include <float.h> | |
6be7c12c AO |
2822 | EOF |
2823 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
c6f8758f | 2824 | { (eval echo configure:2825: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
6be7c12c AO |
2825 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
2826 | if test -z "$ac_err"; then | |
2827 | rm -rf conftest* | |
252b5132 RH |
2828 | ac_cv_header_stdc=yes |
2829 | else | |
6be7c12c AO |
2830 | echo "$ac_err" >&5 |
2831 | echo "configure: failed program was:" >&5 | |
252b5132 | 2832 | cat conftest.$ac_ext >&5 |
6be7c12c | 2833 | rm -rf conftest* |
252b5132 RH |
2834 | ac_cv_header_stdc=no |
2835 | fi | |
6be7c12c | 2836 | rm -f conftest* |
252b5132 RH |
2837 | |
2838 | if test $ac_cv_header_stdc = yes; then | |
2839 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. | |
6be7c12c | 2840 | cat > conftest.$ac_ext <<EOF |
c6f8758f | 2841 | #line 2842 "configure" |
252b5132 RH |
2842 | #include "confdefs.h" |
2843 | #include <string.h> | |
6be7c12c | 2844 | EOF |
252b5132 RH |
2845 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
2846 | egrep "memchr" >/dev/null 2>&1; then | |
2847 | : | |
2848 | else | |
6be7c12c | 2849 | rm -rf conftest* |
252b5132 RH |
2850 | ac_cv_header_stdc=no |
2851 | fi | |
2852 | rm -f conftest* | |
2853 | ||
2854 | fi | |
2855 | ||
2856 | if test $ac_cv_header_stdc = yes; then | |
2857 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. | |
6be7c12c | 2858 | cat > conftest.$ac_ext <<EOF |
c6f8758f | 2859 | #line 2860 "configure" |
252b5132 RH |
2860 | #include "confdefs.h" |
2861 | #include <stdlib.h> | |
6be7c12c | 2862 | EOF |
252b5132 RH |
2863 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
2864 | egrep "free" >/dev/null 2>&1; then | |
2865 | : | |
2866 | else | |
6be7c12c | 2867 | rm -rf conftest* |
252b5132 RH |
2868 | ac_cv_header_stdc=no |
2869 | fi | |
2870 | rm -f conftest* | |
2871 | ||
2872 | fi | |
2873 | ||
2874 | if test $ac_cv_header_stdc = yes; then | |
2875 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. | |
6be7c12c | 2876 | if test "$cross_compiling" = yes; then |
252b5132 RH |
2877 | : |
2878 | else | |
6be7c12c | 2879 | cat > conftest.$ac_ext <<EOF |
c6f8758f | 2880 | #line 2881 "configure" |
252b5132 RH |
2881 | #include "confdefs.h" |
2882 | #include <ctype.h> | |
6be7c12c AO |
2883 | #define ISLOWER(c) ('a' <= (c) && (c) <= 'z') |
2884 | #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) | |
b3baf5d0 | 2885 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) |
6be7c12c AO |
2886 | int main () { int i; for (i = 0; i < 256; i++) |
2887 | if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2); | |
2888 | exit (0); } | |
2889 | ||
2890 | EOF | |
c6f8758f | 2891 | if { (eval echo configure:2892: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
6be7c12c | 2892 | then |
252b5132 RH |
2893 | : |
2894 | else | |
6be7c12c AO |
2895 | echo "configure: failed program was:" >&5 |
2896 | cat conftest.$ac_ext >&5 | |
2897 | rm -fr conftest* | |
2898 | ac_cv_header_stdc=no | |
252b5132 | 2899 | fi |
6be7c12c | 2900 | rm -fr conftest* |
252b5132 | 2901 | fi |
6be7c12c | 2902 | |
252b5132 RH |
2903 | fi |
2904 | fi | |
b3baf5d0 | 2905 | |
6be7c12c AO |
2906 | echo "$ac_t""$ac_cv_header_stdc" 1>&6 |
2907 | if test $ac_cv_header_stdc = yes; then | |
2908 | cat >> confdefs.h <<\EOF | |
252b5132 RH |
2909 | #define STDC_HEADERS 1 |
2910 | EOF | |
2911 | ||
2912 | fi | |
2913 | ||
6be7c12c | 2914 | echo $ac_n "checking for working const""... $ac_c" 1>&6 |
c6f8758f | 2915 | echo "configure:2916: checking for working const" >&5 |
6be7c12c AO |
2916 | if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then |
2917 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 2918 | else |
6be7c12c | 2919 | cat > conftest.$ac_ext <<EOF |
c6f8758f | 2920 | #line 2921 "configure" |
252b5132 | 2921 | #include "confdefs.h" |
6be7c12c AO |
2922 | |
2923 | int main() { | |
2924 | ||
2925 | /* Ultrix mips cc rejects this. */ | |
2926 | typedef int charset[2]; const charset x; | |
2927 | /* SunOS 4.1.1 cc rejects this. */ | |
2928 | char const *const *ccp; | |
2929 | char **p; | |
2930 | /* NEC SVR4.0.2 mips cc rejects this. */ | |
2931 | struct point {int x, y;}; | |
2932 | static struct point const zero = {0,0}; | |
2933 | /* AIX XL C 1.02.0.0 rejects this. | |
2934 | It does not let you subtract one const X* pointer from another in an arm | |
2935 | of an if-expression whose if-part is not a constant expression */ | |
2936 | const char *g = "string"; | |
2937 | ccp = &g + (g ? g-g : 0); | |
2938 | /* HPUX 7.0 cc rejects these. */ | |
2939 | ++ccp; | |
2940 | p = (char**) ccp; | |
2941 | ccp = (char const *const *) p; | |
2942 | { /* SCO 3.2v4 cc rejects this. */ | |
2943 | char *t; | |
2944 | char const *s = 0 ? (char *) 0 : (char const *) 0; | |
2945 | ||
2946 | *t++ = 0; | |
252b5132 | 2947 | } |
6be7c12c AO |
2948 | { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ |
2949 | int x[] = {25, 17}; | |
2950 | const int *foo = &x[0]; | |
2951 | ++foo; | |
252b5132 | 2952 | } |
6be7c12c AO |
2953 | { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ |
2954 | typedef const int *iptr; | |
2955 | iptr p = 0; | |
2956 | ++p; | |
252b5132 | 2957 | } |
6be7c12c AO |
2958 | { /* AIX XL C 1.02.0.0 rejects this saying |
2959 | "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ | |
2960 | struct s { int j; const int *ap[3]; }; | |
2961 | struct s *b; b->j = 5; | |
b3baf5d0 | 2962 | } |
6be7c12c AO |
2963 | { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ |
2964 | const int foo = 10; | |
2965 | } | |
2966 | ||
2967 | ; return 0; } | |
2968 | EOF | |
c6f8758f | 2969 | if { (eval echo configure:2970: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
6be7c12c | 2970 | rm -rf conftest* |
252b5132 RH |
2971 | ac_cv_c_const=yes |
2972 | else | |
6be7c12c AO |
2973 | echo "configure: failed program was:" >&5 |
2974 | cat conftest.$ac_ext >&5 | |
2975 | rm -rf conftest* | |
2976 | ac_cv_c_const=no | |
252b5132 | 2977 | fi |
6be7c12c | 2978 | rm -f conftest* |
252b5132 | 2979 | fi |
b3baf5d0 | 2980 | |
6be7c12c AO |
2981 | echo "$ac_t""$ac_cv_c_const" 1>&6 |
2982 | if test $ac_cv_c_const = no; then | |
2983 | cat >> confdefs.h <<\EOF | |
2984 | #define const | |
252b5132 RH |
2985 | EOF |
2986 | ||
2987 | fi | |
2988 | ||
6be7c12c | 2989 | echo $ac_n "checking for inline""... $ac_c" 1>&6 |
c6f8758f | 2990 | echo "configure:2991: checking for inline" >&5 |
6be7c12c AO |
2991 | if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then |
2992 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 RH |
2993 | else |
2994 | ac_cv_c_inline=no | |
2995 | for ac_kw in inline __inline__ __inline; do | |
6be7c12c | 2996 | cat > conftest.$ac_ext <<EOF |
c6f8758f | 2997 | #line 2998 "configure" |
252b5132 RH |
2998 | #include "confdefs.h" |
2999 | ||
6be7c12c AO |
3000 | int main() { |
3001 | } $ac_kw foo() { | |
3002 | ; return 0; } | |
3003 | EOF | |
c6f8758f | 3004 | if { (eval echo configure:3005: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
6be7c12c | 3005 | rm -rf conftest* |
252b5132 RH |
3006 | ac_cv_c_inline=$ac_kw; break |
3007 | else | |
6be7c12c AO |
3008 | echo "configure: failed program was:" >&5 |
3009 | cat conftest.$ac_ext >&5 | |
252b5132 | 3010 | fi |
6be7c12c | 3011 | rm -f conftest* |
252b5132 RH |
3012 | done |
3013 | ||
3014 | fi | |
6be7c12c AO |
3015 | |
3016 | echo "$ac_t""$ac_cv_c_inline" 1>&6 | |
3017 | case "$ac_cv_c_inline" in | |
252b5132 | 3018 | inline | yes) ;; |
6be7c12c AO |
3019 | no) cat >> confdefs.h <<\EOF |
3020 | #define inline | |
252b5132 RH |
3021 | EOF |
3022 | ;; | |
6be7c12c | 3023 | *) cat >> confdefs.h <<EOF |
252b5132 RH |
3024 | #define inline $ac_cv_c_inline |
3025 | EOF | |
3026 | ;; | |
3027 | esac | |
3028 | ||
6be7c12c | 3029 | echo $ac_n "checking for off_t""... $ac_c" 1>&6 |
c6f8758f | 3030 | echo "configure:3031: checking for off_t" >&5 |
6be7c12c AO |
3031 | if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then |
3032 | echo $ac_n "(cached) $ac_c" 1>&6 | |
b3baf5d0 | 3033 | else |
6be7c12c | 3034 | cat > conftest.$ac_ext <<EOF |
c6f8758f | 3035 | #line 3036 "configure" |
b3baf5d0 | 3036 | #include "confdefs.h" |
6be7c12c AO |
3037 | #include <sys/types.h> |
3038 | #if STDC_HEADERS | |
3039 | #include <stdlib.h> | |
3040 | #include <stddef.h> | |
3041 | #endif | |
3042 | EOF | |
3043 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
3044 | egrep "(^|[^a-zA-Z_0-9])off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then | |
3045 | rm -rf conftest* | |
653f71ca | 3046 | ac_cv_type_off_t=yes |
252b5132 | 3047 | else |
6be7c12c AO |
3048 | rm -rf conftest* |
3049 | ac_cv_type_off_t=no | |
252b5132 | 3050 | fi |
6be7c12c | 3051 | rm -f conftest* |
b3baf5d0 | 3052 | |
6be7c12c AO |
3053 | fi |
3054 | echo "$ac_t""$ac_cv_type_off_t" 1>&6 | |
3055 | if test $ac_cv_type_off_t = no; then | |
3056 | cat >> confdefs.h <<\EOF | |
252b5132 RH |
3057 | #define off_t long |
3058 | EOF | |
3059 | ||
3060 | fi | |
3061 | ||
6be7c12c | 3062 | echo $ac_n "checking for size_t""... $ac_c" 1>&6 |
c6f8758f | 3063 | echo "configure:3064: checking for size_t" >&5 |
6be7c12c AO |
3064 | if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then |
3065 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 3066 | else |
6be7c12c | 3067 | cat > conftest.$ac_ext <<EOF |
c6f8758f | 3068 | #line 3069 "configure" |
252b5132 | 3069 | #include "confdefs.h" |
6be7c12c AO |
3070 | #include <sys/types.h> |
3071 | #if STDC_HEADERS | |
3072 | #include <stdlib.h> | |
3073 | #include <stddef.h> | |
3074 | #endif | |
3075 | EOF | |
3076 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
3077 | egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then | |
3078 | rm -rf conftest* | |
653f71ca | 3079 | ac_cv_type_size_t=yes |
252b5132 | 3080 | else |
6be7c12c AO |
3081 | rm -rf conftest* |
3082 | ac_cv_type_size_t=no | |
252b5132 | 3083 | fi |
6be7c12c | 3084 | rm -f conftest* |
b3baf5d0 | 3085 | |
6be7c12c AO |
3086 | fi |
3087 | echo "$ac_t""$ac_cv_type_size_t" 1>&6 | |
3088 | if test $ac_cv_type_size_t = no; then | |
3089 | cat >> confdefs.h <<\EOF | |
252b5132 RH |
3090 | #define size_t unsigned |
3091 | EOF | |
3092 | ||
3093 | fi | |
3094 | ||
3095 | # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works | |
3096 | # for constant arguments. Useless! | |
6be7c12c | 3097 | echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6 |
c6f8758f | 3098 | echo "configure:3099: checking for working alloca.h" >&5 |
6be7c12c AO |
3099 | if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then |
3100 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 3101 | else |
6be7c12c | 3102 | cat > conftest.$ac_ext <<EOF |
c6f8758f | 3103 | #line 3104 "configure" |
252b5132 RH |
3104 | #include "confdefs.h" |
3105 | #include <alloca.h> | |
6be7c12c AO |
3106 | int main() { |
3107 | char *p = alloca(2 * sizeof(int)); | |
3108 | ; return 0; } | |
3109 | EOF | |
c6f8758f | 3110 | if { (eval echo configure:3111: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
6be7c12c AO |
3111 | rm -rf conftest* |
3112 | ac_cv_header_alloca_h=yes | |
3113 | else | |
3114 | echo "configure: failed program was:" >&5 | |
3115 | cat conftest.$ac_ext >&5 | |
3116 | rm -rf conftest* | |
3117 | ac_cv_header_alloca_h=no | |
3118 | fi | |
3119 | rm -f conftest* | |
3120 | fi | |
3121 | ||
3122 | echo "$ac_t""$ac_cv_header_alloca_h" 1>&6 | |
3123 | if test $ac_cv_header_alloca_h = yes; then | |
3124 | cat >> confdefs.h <<\EOF | |
252b5132 RH |
3125 | #define HAVE_ALLOCA_H 1 |
3126 | EOF | |
3127 | ||
3128 | fi | |
3129 | ||
6be7c12c | 3130 | echo $ac_n "checking for alloca""... $ac_c" 1>&6 |
c6f8758f | 3131 | echo "configure:3132: checking for alloca" >&5 |
6be7c12c AO |
3132 | if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then |
3133 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 3134 | else |
6be7c12c | 3135 | cat > conftest.$ac_ext <<EOF |
c6f8758f | 3136 | #line 3137 "configure" |
252b5132 | 3137 | #include "confdefs.h" |
6be7c12c | 3138 | |
252b5132 RH |
3139 | #ifdef __GNUC__ |
3140 | # define alloca __builtin_alloca | |
3141 | #else | |
3142 | # ifdef _MSC_VER | |
3143 | # include <malloc.h> | |
3144 | # define alloca _alloca | |
3145 | # else | |
3146 | # if HAVE_ALLOCA_H | |
3147 | # include <alloca.h> | |
3148 | # else | |
3149 | # ifdef _AIX | |
3150 | #pragma alloca | |
3151 | # else | |
3152 | # ifndef alloca /* predefined by HP cc +Olibcalls */ | |
3153 | char *alloca (); | |
3154 | # endif | |
3155 | # endif | |
3156 | # endif | |
3157 | # endif | |
3158 | #endif | |
3159 | ||
6be7c12c AO |
3160 | int main() { |
3161 | char *p = (char *) alloca(1); | |
3162 | ; return 0; } | |
3163 | EOF | |
c6f8758f | 3164 | if { (eval echo configure:3165: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
6be7c12c | 3165 | rm -rf conftest* |
252b5132 RH |
3166 | ac_cv_func_alloca_works=yes |
3167 | else | |
6be7c12c AO |
3168 | echo "configure: failed program was:" >&5 |
3169 | cat conftest.$ac_ext >&5 | |
3170 | rm -rf conftest* | |
3171 | ac_cv_func_alloca_works=no | |
252b5132 | 3172 | fi |
6be7c12c | 3173 | rm -f conftest* |
252b5132 RH |
3174 | fi |
3175 | ||
6be7c12c | 3176 | echo "$ac_t""$ac_cv_func_alloca_works" 1>&6 |
252b5132 | 3177 | if test $ac_cv_func_alloca_works = yes; then |
6be7c12c | 3178 | cat >> confdefs.h <<\EOF |
252b5132 RH |
3179 | #define HAVE_ALLOCA 1 |
3180 | EOF | |
3181 | ||
6be7c12c | 3182 | fi |
b3baf5d0 | 3183 | |
6be7c12c AO |
3184 | if test $ac_cv_func_alloca_works = no; then |
3185 | # The SVR3 libPW and SVR4 libucb both contain incompatible functions | |
3186 | # that cause trouble. Some versions do not even contain alloca or | |
3187 | # contain a buggy version. If you still want to use their alloca, | |
3188 | # use ar to extract alloca.o from them instead of compiling alloca.c. | |
3189 | ALLOCA=alloca.${ac_objext} | |
3190 | cat >> confdefs.h <<\EOF | |
252b5132 RH |
3191 | #define C_ALLOCA 1 |
3192 | EOF | |
3193 | ||
6be7c12c AO |
3194 | |
3195 | echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6 | |
c6f8758f | 3196 | echo "configure:3197: checking whether alloca needs Cray hooks" >&5 |
6be7c12c AO |
3197 | if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then |
3198 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 3199 | else |
6be7c12c | 3200 | cat > conftest.$ac_ext <<EOF |
c6f8758f | 3201 | #line 3202 "configure" |
252b5132 RH |
3202 | #include "confdefs.h" |
3203 | #if defined(CRAY) && ! defined(CRAY2) | |
3204 | webecray | |
3205 | #else | |
3206 | wenotbecray | |
3207 | #endif | |
3208 | ||
6be7c12c | 3209 | EOF |
252b5132 RH |
3210 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
3211 | egrep "webecray" >/dev/null 2>&1; then | |
6be7c12c | 3212 | rm -rf conftest* |
252b5132 RH |
3213 | ac_cv_os_cray=yes |
3214 | else | |
6be7c12c | 3215 | rm -rf conftest* |
252b5132 RH |
3216 | ac_cv_os_cray=no |
3217 | fi | |
3218 | rm -f conftest* | |
3219 | ||
3220 | fi | |
6be7c12c AO |
3221 | |
3222 | echo "$ac_t""$ac_cv_os_cray" 1>&6 | |
252b5132 | 3223 | if test $ac_cv_os_cray = yes; then |
6be7c12c AO |
3224 | for ac_func in _getb67 GETB67 getb67; do |
3225 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
c6f8758f | 3226 | echo "configure:3227: checking for $ac_func" >&5 |
6be7c12c AO |
3227 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
3228 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3229 | else | |
3230 | cat > conftest.$ac_ext <<EOF | |
c6f8758f | 3231 | #line 3232 "configure" |
252b5132 RH |
3232 | #include "confdefs.h" |
3233 | /* System header to define __stub macros and hopefully few prototypes, | |
6be7c12c | 3234 | which can conflict with char $ac_func(); below. */ |
252b5132 RH |
3235 | #include <assert.h> |
3236 | /* Override any gcc2 internal prototype to avoid an error. */ | |
3237 | /* We use char because int might match the return type of a gcc2 | |
6be7c12c AO |
3238 | builtin and then its argument prototype would still apply. */ |
3239 | char $ac_func(); | |
3240 | ||
3241 | int main() { | |
252b5132 RH |
3242 | |
3243 | /* The GNU C library defines this for functions which it implements | |
3244 | to always fail with ENOSYS. Some functions are actually named | |
3245 | something starting with __ and the normal name is an alias. */ | |
3246 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
3247 | choke me | |
3248 | #else | |
6be7c12c | 3249 | $ac_func(); |
252b5132 RH |
3250 | #endif |
3251 | ||
6be7c12c AO |
3252 | ; return 0; } |
3253 | EOF | |
c6f8758f | 3254 | if { (eval echo configure:3255: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
6be7c12c AO |
3255 | rm -rf conftest* |
3256 | eval "ac_cv_func_$ac_func=yes" | |
3257 | else | |
3258 | echo "configure: failed program was:" >&5 | |
3259 | cat conftest.$ac_ext >&5 | |
3260 | rm -rf conftest* | |
3261 | eval "ac_cv_func_$ac_func=no" | |
3262 | fi | |
3263 | rm -f conftest* | |
3264 | fi | |
3265 | ||
3266 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then | |
3267 | echo "$ac_t""yes" 1>&6 | |
3268 | cat >> confdefs.h <<EOF | |
252b5132 RH |
3269 | #define CRAY_STACKSEG_END $ac_func |
3270 | EOF | |
3271 | ||
6be7c12c AO |
3272 | break |
3273 | else | |
3274 | echo "$ac_t""no" 1>&6 | |
252b5132 RH |
3275 | fi |
3276 | ||
6be7c12c | 3277 | done |
252b5132 RH |
3278 | fi |
3279 | ||
6be7c12c | 3280 | echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6 |
c6f8758f | 3281 | echo "configure:3282: checking stack direction for C alloca" >&5 |
6be7c12c AO |
3282 | if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then |
3283 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 RH |
3284 | else |
3285 | if test "$cross_compiling" = yes; then | |
3286 | ac_cv_c_stack_direction=0 | |
3287 | else | |
6be7c12c | 3288 | cat > conftest.$ac_ext <<EOF |
c6f8758f | 3289 | #line 3290 "configure" |
252b5132 RH |
3290 | #include "confdefs.h" |
3291 | find_stack_direction () | |
3292 | { | |
3293 | static char *addr = 0; | |
3294 | auto char dummy; | |
3295 | if (addr == 0) | |
3296 | { | |
3297 | addr = &dummy; | |
3298 | return find_stack_direction (); | |
3299 | } | |
3300 | else | |
3301 | return (&dummy > addr) ? 1 : -1; | |
3302 | } | |
3303 | main () | |
3304 | { | |
6be7c12c | 3305 | exit (find_stack_direction() < 0); |
252b5132 | 3306 | } |
6be7c12c | 3307 | EOF |
c6f8758f | 3308 | if { (eval echo configure:3309: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
6be7c12c | 3309 | then |
252b5132 RH |
3310 | ac_cv_c_stack_direction=1 |
3311 | else | |
6be7c12c AO |
3312 | echo "configure: failed program was:" >&5 |
3313 | cat conftest.$ac_ext >&5 | |
3314 | rm -fr conftest* | |
3315 | ac_cv_c_stack_direction=-1 | |
252b5132 | 3316 | fi |
6be7c12c | 3317 | rm -fr conftest* |
252b5132 | 3318 | fi |
6be7c12c | 3319 | |
252b5132 RH |
3320 | fi |
3321 | ||
6be7c12c AO |
3322 | echo "$ac_t""$ac_cv_c_stack_direction" 1>&6 |
3323 | cat >> confdefs.h <<EOF | |
252b5132 RH |
3324 | #define STACK_DIRECTION $ac_cv_c_stack_direction |
3325 | EOF | |
3326 | ||
3327 | fi | |
3328 | ||
bc286f95 | 3329 | for ac_hdr in unistd.h |
252b5132 | 3330 | do |
6be7c12c AO |
3331 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` |
3332 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 | |
c6f8758f | 3333 | echo "configure:3334: checking for $ac_hdr" >&5 |
6be7c12c AO |
3334 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
3335 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3336 | else | |
3337 | cat > conftest.$ac_ext <<EOF | |
c6f8758f | 3338 | #line 3339 "configure" |
252b5132 | 3339 | #include "confdefs.h" |
6be7c12c AO |
3340 | #include <$ac_hdr> |
3341 | EOF | |
3342 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
c6f8758f | 3343 | { (eval echo configure:3344: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
6be7c12c AO |
3344 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
3345 | if test -z "$ac_err"; then | |
3346 | rm -rf conftest* | |
3347 | eval "ac_cv_header_$ac_safe=yes" | |
252b5132 | 3348 | else |
6be7c12c AO |
3349 | echo "$ac_err" >&5 |
3350 | echo "configure: failed program was:" >&5 | |
252b5132 | 3351 | cat conftest.$ac_ext >&5 |
6be7c12c AO |
3352 | rm -rf conftest* |
3353 | eval "ac_cv_header_$ac_safe=no" | |
252b5132 | 3354 | fi |
6be7c12c | 3355 | rm -f conftest* |
252b5132 | 3356 | fi |
6be7c12c AO |
3357 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
3358 | echo "$ac_t""yes" 1>&6 | |
3359 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` | |
3360 | cat >> confdefs.h <<EOF | |
3361 | #define $ac_tr_hdr 1 | |
252b5132 | 3362 | EOF |
6be7c12c AO |
3363 | |
3364 | else | |
3365 | echo "$ac_t""no" 1>&6 | |
252b5132 RH |
3366 | fi |
3367 | done | |
3368 | ||
3369 | for ac_func in getpagesize | |
3370 | do | |
6be7c12c | 3371 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
c6f8758f | 3372 | echo "configure:3373: checking for $ac_func" >&5 |
6be7c12c AO |
3373 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
3374 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3375 | else | |
3376 | cat > conftest.$ac_ext <<EOF | |
c6f8758f | 3377 | #line 3378 "configure" |
252b5132 RH |
3378 | #include "confdefs.h" |
3379 | /* System header to define __stub macros and hopefully few prototypes, | |
6be7c12c | 3380 | which can conflict with char $ac_func(); below. */ |
252b5132 RH |
3381 | #include <assert.h> |
3382 | /* Override any gcc2 internal prototype to avoid an error. */ | |
3383 | /* We use char because int might match the return type of a gcc2 | |
6be7c12c AO |
3384 | builtin and then its argument prototype would still apply. */ |
3385 | char $ac_func(); | |
3386 | ||
3387 | int main() { | |
252b5132 RH |
3388 | |
3389 | /* The GNU C library defines this for functions which it implements | |
3390 | to always fail with ENOSYS. Some functions are actually named | |
3391 | something starting with __ and the normal name is an alias. */ | |
3392 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
3393 | choke me | |
3394 | #else | |
6be7c12c | 3395 | $ac_func(); |
252b5132 RH |
3396 | #endif |
3397 | ||
6be7c12c | 3398 | ; return 0; } |
252b5132 | 3399 | EOF |
c6f8758f | 3400 | if { (eval echo configure:3401: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
6be7c12c AO |
3401 | rm -rf conftest* |
3402 | eval "ac_cv_func_$ac_func=yes" | |
3403 | else | |
3404 | echo "configure: failed program was:" >&5 | |
3405 | cat conftest.$ac_ext >&5 | |
3406 | rm -rf conftest* | |
3407 | eval "ac_cv_func_$ac_func=no" | |
3408 | fi | |
3409 | rm -f conftest* | |
3410 | fi | |
252b5132 | 3411 | |
6be7c12c AO |
3412 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
3413 | echo "$ac_t""yes" 1>&6 | |
3414 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
3415 | cat >> confdefs.h <<EOF | |
3416 | #define $ac_tr_func 1 | |
3417 | EOF | |
3418 | ||
3419 | else | |
3420 | echo "$ac_t""no" 1>&6 | |
252b5132 RH |
3421 | fi |
3422 | done | |
3423 | ||
6be7c12c | 3424 | echo $ac_n "checking for working mmap""... $ac_c" 1>&6 |
c6f8758f | 3425 | echo "configure:3426: checking for working mmap" >&5 |
6be7c12c AO |
3426 | if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then |
3427 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 RH |
3428 | else |
3429 | if test "$cross_compiling" = yes; then | |
3430 | ac_cv_func_mmap_fixed_mapped=no | |
3431 | else | |
6be7c12c | 3432 | cat > conftest.$ac_ext <<EOF |
c6f8758f | 3433 | #line 3434 "configure" |
252b5132 | 3434 | #include "confdefs.h" |
6be7c12c | 3435 | |
252b5132 RH |
3436 | /* Thanks to Mike Haertel and Jim Avera for this test. |
3437 | Here is a matrix of mmap possibilities: | |
3438 | mmap private not fixed | |
3439 | mmap private fixed at somewhere currently unmapped | |
3440 | mmap private fixed at somewhere already mapped | |
3441 | mmap shared not fixed | |
3442 | mmap shared fixed at somewhere currently unmapped | |
3443 | mmap shared fixed at somewhere already mapped | |
3444 | For private mappings, we should verify that changes cannot be read() | |
3445 | back from the file, nor mmap's back from the file at a different | |
3446 | address. (There have been systems where private was not correctly | |
3447 | implemented like the infamous i386 svr4.0, and systems where the | |
6be7c12c | 3448 | VM page cache was not coherent with the filesystem buffer cache |
252b5132 RH |
3449 | like early versions of FreeBSD and possibly contemporary NetBSD.) |
3450 | For shared mappings, we should conversely verify that changes get | |
3451 | propogated back to all the places they're supposed to be. | |
3452 | ||
3453 | Grep wants private fixed already mapped. | |
3454 | The main things grep needs to know about mmap are: | |
3455 | * does it exist and is it safe to write into the mmap'd area | |
3456 | * how to use it (BSD variants) */ | |
3457 | #include <sys/types.h> | |
3458 | #include <fcntl.h> | |
3459 | #include <sys/mman.h> | |
3460 | ||
b3baf5d0 | 3461 | /* This mess was copied from the GNU getpagesize.h. */ |
6be7c12c | 3462 | #ifndef HAVE_GETPAGESIZE |
bc286f95 BE |
3463 | # ifdef HAVE_UNISTD_H |
3464 | # include <unistd.h> | |
3465 | # endif | |
6be7c12c | 3466 | |
252b5132 | 3467 | /* Assume that all systems that can run configure have sys/param.h. */ |
6be7c12c | 3468 | # ifndef HAVE_SYS_PARAM_H |
252b5132 RH |
3469 | # define HAVE_SYS_PARAM_H 1 |
3470 | # endif | |
3471 | ||
3472 | # ifdef _SC_PAGESIZE | |
3473 | # define getpagesize() sysconf(_SC_PAGESIZE) | |
3474 | # else /* no _SC_PAGESIZE */ | |
6be7c12c | 3475 | # ifdef HAVE_SYS_PARAM_H |
252b5132 RH |
3476 | # include <sys/param.h> |
3477 | # ifdef EXEC_PAGESIZE | |
3478 | # define getpagesize() EXEC_PAGESIZE | |
3479 | # else /* no EXEC_PAGESIZE */ | |
3480 | # ifdef NBPG | |
3481 | # define getpagesize() NBPG * CLSIZE | |
3482 | # ifndef CLSIZE | |
3483 | # define CLSIZE 1 | |
3484 | # endif /* no CLSIZE */ | |
3485 | # else /* no NBPG */ | |
3486 | # ifdef NBPC | |
3487 | # define getpagesize() NBPC | |
3488 | # else /* no NBPC */ | |
3489 | # ifdef PAGESIZE | |
3490 | # define getpagesize() PAGESIZE | |
3491 | # endif /* PAGESIZE */ | |
3492 | # endif /* no NBPC */ | |
3493 | # endif /* no NBPG */ | |
3494 | # endif /* no EXEC_PAGESIZE */ | |
3495 | # else /* no HAVE_SYS_PARAM_H */ | |
3496 | # define getpagesize() 8192 /* punt totally */ | |
3497 | # endif /* no HAVE_SYS_PARAM_H */ | |
3498 | # endif /* no _SC_PAGESIZE */ | |
3499 | ||
3500 | #endif /* no HAVE_GETPAGESIZE */ | |
3501 | ||
6be7c12c AO |
3502 | #ifdef __cplusplus |
3503 | extern "C" { void *malloc(unsigned); } | |
3504 | #else | |
3505 | char *malloc(); | |
3506 | #endif | |
3507 | ||
252b5132 | 3508 | int |
6be7c12c | 3509 | main() |
252b5132 | 3510 | { |
6be7c12c AO |
3511 | char *data, *data2, *data3; |
3512 | int i, pagesize; | |
3513 | int fd; | |
3514 | ||
3515 | pagesize = getpagesize(); | |
3516 | ||
3517 | /* | |
3518 | * First, make a file with some known garbage in it. | |
3519 | */ | |
3520 | data = malloc(pagesize); | |
3521 | if (!data) | |
3522 | exit(1); | |
3523 | for (i = 0; i < pagesize; ++i) | |
3524 | *(data + i) = rand(); | |
3525 | umask(0); | |
3526 | fd = creat("conftestmmap", 0600); | |
3527 | if (fd < 0) | |
3528 | exit(1); | |
3529 | if (write(fd, data, pagesize) != pagesize) | |
3530 | exit(1); | |
3531 | close(fd); | |
3532 | ||
3533 | /* | |
3534 | * Next, try to mmap the file at a fixed address which | |
3535 | * already has something else allocated at it. If we can, | |
3536 | * also make sure that we see the same garbage. | |
3537 | */ | |
3538 | fd = open("conftestmmap", O_RDWR); | |
3539 | if (fd < 0) | |
3540 | exit(1); | |
3541 | data2 = malloc(2 * pagesize); | |
3542 | if (!data2) | |
3543 | exit(1); | |
3544 | data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1); | |
3545 | if (data2 != mmap(data2, pagesize, PROT_READ | PROT_WRITE, | |
3546 | MAP_PRIVATE | MAP_FIXED, fd, 0L)) | |
3547 | exit(1); | |
3548 | for (i = 0; i < pagesize; ++i) | |
3549 | if (*(data + i) != *(data2 + i)) | |
3550 | exit(1); | |
3551 | ||
3552 | /* | |
3553 | * Finally, make sure that changes to the mapped area | |
3554 | * do not percolate back to the file as seen by read(). | |
3555 | * (This is a bug on some variants of i386 svr4.0.) | |
3556 | */ | |
3557 | for (i = 0; i < pagesize; ++i) | |
3558 | *(data2 + i) = *(data2 + i) + 1; | |
3559 | data3 = malloc(pagesize); | |
3560 | if (!data3) | |
3561 | exit(1); | |
3562 | if (read(fd, data3, pagesize) != pagesize) | |
3563 | exit(1); | |
3564 | for (i = 0; i < pagesize; ++i) | |
3565 | if (*(data + i) != *(data3 + i)) | |
3566 | exit(1); | |
3567 | close(fd); | |
3568 | unlink("conftestmmap"); | |
3569 | exit(0); | |
252b5132 | 3570 | } |
6be7c12c AO |
3571 | |
3572 | EOF | |
c6f8758f | 3573 | if { (eval echo configure:3574: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
6be7c12c | 3574 | then |
252b5132 RH |
3575 | ac_cv_func_mmap_fixed_mapped=yes |
3576 | else | |
6be7c12c AO |
3577 | echo "configure: failed program was:" >&5 |
3578 | cat conftest.$ac_ext >&5 | |
3579 | rm -fr conftest* | |
3580 | ac_cv_func_mmap_fixed_mapped=no | |
252b5132 | 3581 | fi |
6be7c12c | 3582 | rm -fr conftest* |
252b5132 | 3583 | fi |
6be7c12c | 3584 | |
252b5132 | 3585 | fi |
b3baf5d0 | 3586 | |
6be7c12c AO |
3587 | echo "$ac_t""$ac_cv_func_mmap_fixed_mapped" 1>&6 |
3588 | if test $ac_cv_func_mmap_fixed_mapped = yes; then | |
3589 | cat >> confdefs.h <<\EOF | |
252b5132 RH |
3590 | #define HAVE_MMAP 1 |
3591 | EOF | |
3592 | ||
3593 | fi | |
3594 | ||
6be7c12c AO |
3595 | |
3596 | for ac_hdr in argz.h limits.h locale.h nl_types.h malloc.h string.h \ | |
252b5132 RH |
3597 | unistd.h values.h sys/param.h |
3598 | do | |
6be7c12c AO |
3599 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` |
3600 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 | |
c6f8758f | 3601 | echo "configure:3602: checking for $ac_hdr" >&5 |
6be7c12c AO |
3602 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
3603 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3604 | else | |
3605 | cat > conftest.$ac_ext <<EOF | |
c6f8758f | 3606 | #line 3607 "configure" |
252b5132 | 3607 | #include "confdefs.h" |
6be7c12c AO |
3608 | #include <$ac_hdr> |
3609 | EOF | |
3610 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
c6f8758f | 3611 | { (eval echo configure:3612: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
6be7c12c AO |
3612 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
3613 | if test -z "$ac_err"; then | |
3614 | rm -rf conftest* | |
3615 | eval "ac_cv_header_$ac_safe=yes" | |
252b5132 | 3616 | else |
6be7c12c AO |
3617 | echo "$ac_err" >&5 |
3618 | echo "configure: failed program was:" >&5 | |
252b5132 | 3619 | cat conftest.$ac_ext >&5 |
6be7c12c AO |
3620 | rm -rf conftest* |
3621 | eval "ac_cv_header_$ac_safe=no" | |
252b5132 | 3622 | fi |
6be7c12c | 3623 | rm -f conftest* |
252b5132 | 3624 | fi |
6be7c12c AO |
3625 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
3626 | echo "$ac_t""yes" 1>&6 | |
3627 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` | |
3628 | cat >> confdefs.h <<EOF | |
3629 | #define $ac_tr_hdr 1 | |
252b5132 | 3630 | EOF |
6be7c12c AO |
3631 | |
3632 | else | |
3633 | echo "$ac_t""no" 1>&6 | |
252b5132 RH |
3634 | fi |
3635 | done | |
3636 | ||
6be7c12c | 3637 | for ac_func in getcwd munmap putenv setenv setlocale strchr strcasecmp \ |
252b5132 RH |
3638 | __argz_count __argz_stringify __argz_next |
3639 | do | |
6be7c12c | 3640 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
c6f8758f | 3641 | echo "configure:3642: checking for $ac_func" >&5 |
6be7c12c AO |
3642 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
3643 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3644 | else | |
3645 | cat > conftest.$ac_ext <<EOF | |
c6f8758f | 3646 | #line 3647 "configure" |
252b5132 RH |
3647 | #include "confdefs.h" |
3648 | /* System header to define __stub macros and hopefully few prototypes, | |
6be7c12c | 3649 | which can conflict with char $ac_func(); below. */ |
252b5132 RH |
3650 | #include <assert.h> |
3651 | /* Override any gcc2 internal prototype to avoid an error. */ | |
3652 | /* We use char because int might match the return type of a gcc2 | |
6be7c12c AO |
3653 | builtin and then its argument prototype would still apply. */ |
3654 | char $ac_func(); | |
3655 | ||
3656 | int main() { | |
252b5132 RH |
3657 | |
3658 | /* The GNU C library defines this for functions which it implements | |
3659 | to always fail with ENOSYS. Some functions are actually named | |
3660 | something starting with __ and the normal name is an alias. */ | |
3661 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
3662 | choke me | |
3663 | #else | |
6be7c12c | 3664 | $ac_func(); |
252b5132 RH |
3665 | #endif |
3666 | ||
6be7c12c | 3667 | ; return 0; } |
252b5132 | 3668 | EOF |
c6f8758f | 3669 | if { (eval echo configure:3670: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
6be7c12c AO |
3670 | rm -rf conftest* |
3671 | eval "ac_cv_func_$ac_func=yes" | |
3672 | else | |
3673 | echo "configure: failed program was:" >&5 | |
3674 | cat conftest.$ac_ext >&5 | |
3675 | rm -rf conftest* | |
3676 | eval "ac_cv_func_$ac_func=no" | |
3677 | fi | |
3678 | rm -f conftest* | |
3679 | fi | |
252b5132 | 3680 | |
6be7c12c AO |
3681 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
3682 | echo "$ac_t""yes" 1>&6 | |
3683 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
3684 | cat >> confdefs.h <<EOF | |
3685 | #define $ac_tr_func 1 | |
3686 | EOF | |
3687 | ||
3688 | else | |
3689 | echo "$ac_t""no" 1>&6 | |
252b5132 RH |
3690 | fi |
3691 | done | |
3692 | ||
b3baf5d0 | 3693 | |
6be7c12c AO |
3694 | if test "${ac_cv_func_stpcpy+set}" != "set"; then |
3695 | for ac_func in stpcpy | |
252b5132 | 3696 | do |
6be7c12c | 3697 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
c6f8758f | 3698 | echo "configure:3699: checking for $ac_func" >&5 |
6be7c12c AO |
3699 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
3700 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3701 | else | |
3702 | cat > conftest.$ac_ext <<EOF | |
c6f8758f | 3703 | #line 3704 "configure" |
252b5132 RH |
3704 | #include "confdefs.h" |
3705 | /* System header to define __stub macros and hopefully few prototypes, | |
6be7c12c | 3706 | which can conflict with char $ac_func(); below. */ |
252b5132 RH |
3707 | #include <assert.h> |
3708 | /* Override any gcc2 internal prototype to avoid an error. */ | |
3709 | /* We use char because int might match the return type of a gcc2 | |
6be7c12c AO |
3710 | builtin and then its argument prototype would still apply. */ |
3711 | char $ac_func(); | |
3712 | ||
3713 | int main() { | |
252b5132 RH |
3714 | |
3715 | /* The GNU C library defines this for functions which it implements | |
3716 | to always fail with ENOSYS. Some functions are actually named | |
3717 | something starting with __ and the normal name is an alias. */ | |
3718 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
3719 | choke me | |
3720 | #else | |
6be7c12c | 3721 | $ac_func(); |
252b5132 RH |
3722 | #endif |
3723 | ||
6be7c12c | 3724 | ; return 0; } |
252b5132 | 3725 | EOF |
c6f8758f | 3726 | if { (eval echo configure:3727: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
6be7c12c AO |
3727 | rm -rf conftest* |
3728 | eval "ac_cv_func_$ac_func=yes" | |
3729 | else | |
3730 | echo "configure: failed program was:" >&5 | |
3731 | cat conftest.$ac_ext >&5 | |
3732 | rm -rf conftest* | |
3733 | eval "ac_cv_func_$ac_func=no" | |
3734 | fi | |
3735 | rm -f conftest* | |
3736 | fi | |
252b5132 | 3737 | |
6be7c12c AO |
3738 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
3739 | echo "$ac_t""yes" 1>&6 | |
3740 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
3741 | cat >> confdefs.h <<EOF | |
3742 | #define $ac_tr_func 1 | |
3743 | EOF | |
3744 | ||
3745 | else | |
3746 | echo "$ac_t""no" 1>&6 | |
252b5132 RH |
3747 | fi |
3748 | done | |
3749 | ||
3750 | fi | |
3751 | if test "${ac_cv_func_stpcpy}" = "yes"; then | |
6be7c12c | 3752 | cat >> confdefs.h <<\EOF |
252b5132 RH |
3753 | #define HAVE_STPCPY 1 |
3754 | EOF | |
3755 | ||
3756 | fi | |
3757 | ||
3758 | if test $ac_cv_header_locale_h = yes; then | |
6be7c12c | 3759 | echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6 |
c6f8758f | 3760 | echo "configure:3761: checking for LC_MESSAGES" >&5 |
6be7c12c AO |
3761 | if eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then |
3762 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 3763 | else |
6be7c12c | 3764 | cat > conftest.$ac_ext <<EOF |
c6f8758f | 3765 | #line 3766 "configure" |
252b5132 RH |
3766 | #include "confdefs.h" |
3767 | #include <locale.h> | |
6be7c12c | 3768 | int main() { |
252b5132 | 3769 | return LC_MESSAGES |
6be7c12c AO |
3770 | ; return 0; } |
3771 | EOF | |
c6f8758f | 3772 | if { (eval echo configure:3773: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
6be7c12c | 3773 | rm -rf conftest* |
252b5132 RH |
3774 | am_cv_val_LC_MESSAGES=yes |
3775 | else | |
6be7c12c AO |
3776 | echo "configure: failed program was:" >&5 |
3777 | cat conftest.$ac_ext >&5 | |
3778 | rm -rf conftest* | |
3779 | am_cv_val_LC_MESSAGES=no | |
252b5132 | 3780 | fi |
6be7c12c | 3781 | rm -f conftest* |
252b5132 | 3782 | fi |
b3baf5d0 | 3783 | |
6be7c12c AO |
3784 | echo "$ac_t""$am_cv_val_LC_MESSAGES" 1>&6 |
3785 | if test $am_cv_val_LC_MESSAGES = yes; then | |
3786 | cat >> confdefs.h <<\EOF | |
252b5132 RH |
3787 | #define HAVE_LC_MESSAGES 1 |
3788 | EOF | |
3789 | ||
3790 | fi | |
3791 | fi | |
6be7c12c | 3792 | echo $ac_n "checking whether NLS is requested""... $ac_c" 1>&6 |
c6f8758f | 3793 | echo "configure:3794: checking whether NLS is requested" >&5 |
252b5132 RH |
3794 | # Check whether --enable-nls or --disable-nls was given. |
3795 | if test "${enable_nls+set}" = set; then | |
3796 | enableval="$enable_nls" | |
3797 | USE_NLS=$enableval | |
3798 | else | |
3799 | USE_NLS=yes | |
6be7c12c AO |
3800 | fi |
3801 | ||
3802 | echo "$ac_t""$USE_NLS" 1>&6 | |
3803 | ||
252b5132 RH |
3804 | |
3805 | USE_INCLUDED_LIBINTL=no | |
3806 | ||
3807 | if test "$USE_NLS" = "yes"; then | |
6be7c12c | 3808 | cat >> confdefs.h <<\EOF |
252b5132 RH |
3809 | #define ENABLE_NLS 1 |
3810 | EOF | |
3811 | ||
6be7c12c | 3812 | echo $ac_n "checking whether included gettext is requested""... $ac_c" 1>&6 |
c6f8758f | 3813 | echo "configure:3814: checking whether included gettext is requested" >&5 |
6be7c12c | 3814 | # Check whether --with-included-gettext or --without-included-gettext was given. |
252b5132 RH |
3815 | if test "${with_included_gettext+set}" = set; then |
3816 | withval="$with_included_gettext" | |
3817 | nls_cv_force_use_gnu_gettext=$withval | |
3818 | else | |
3819 | nls_cv_force_use_gnu_gettext=no | |
6be7c12c AO |
3820 | fi |
3821 | ||
3822 | echo "$ac_t""$nls_cv_force_use_gnu_gettext" 1>&6 | |
252b5132 RH |
3823 | |
3824 | nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext" | |
3825 | if test "$nls_cv_force_use_gnu_gettext" != "yes"; then | |
3826 | nls_cv_header_intl= | |
3827 | nls_cv_header_libgt= | |
3828 | CATOBJEXT=NONE | |
3829 | ||
6be7c12c AO |
3830 | ac_safe=`echo "libintl.h" | sed 'y%./+-%__p_%'` |
3831 | echo $ac_n "checking for libintl.h""... $ac_c" 1>&6 | |
c6f8758f | 3832 | echo "configure:3833: checking for libintl.h" >&5 |
6be7c12c AO |
3833 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
3834 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 3835 | else |
6be7c12c | 3836 | cat > conftest.$ac_ext <<EOF |
c6f8758f | 3837 | #line 3838 "configure" |
252b5132 RH |
3838 | #include "confdefs.h" |
3839 | #include <libintl.h> | |
6be7c12c AO |
3840 | EOF |
3841 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
c6f8758f | 3842 | { (eval echo configure:3843: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
6be7c12c AO |
3843 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
3844 | if test -z "$ac_err"; then | |
3845 | rm -rf conftest* | |
3846 | eval "ac_cv_header_$ac_safe=yes" | |
252b5132 | 3847 | else |
6be7c12c AO |
3848 | echo "$ac_err" >&5 |
3849 | echo "configure: failed program was:" >&5 | |
252b5132 | 3850 | cat conftest.$ac_ext >&5 |
6be7c12c AO |
3851 | rm -rf conftest* |
3852 | eval "ac_cv_header_$ac_safe=no" | |
252b5132 | 3853 | fi |
6be7c12c | 3854 | rm -f conftest* |
252b5132 | 3855 | fi |
6be7c12c AO |
3856 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
3857 | echo "$ac_t""yes" 1>&6 | |
3858 | echo $ac_n "checking for gettext in libc""... $ac_c" 1>&6 | |
c6f8758f | 3859 | echo "configure:3860: checking for gettext in libc" >&5 |
6be7c12c AO |
3860 | if eval "test \"`echo '$''{'gt_cv_func_gettext_libc'+set}'`\" = set"; then |
3861 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 3862 | else |
6be7c12c | 3863 | cat > conftest.$ac_ext <<EOF |
c6f8758f | 3864 | #line 3865 "configure" |
252b5132 RH |
3865 | #include "confdefs.h" |
3866 | #include <libintl.h> | |
6be7c12c | 3867 | int main() { |
252b5132 | 3868 | return (int) gettext ("") |
6be7c12c AO |
3869 | ; return 0; } |
3870 | EOF | |
c6f8758f | 3871 | if { (eval echo configure:3872: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
6be7c12c | 3872 | rm -rf conftest* |
252b5132 RH |
3873 | gt_cv_func_gettext_libc=yes |
3874 | else | |
6be7c12c AO |
3875 | echo "configure: failed program was:" >&5 |
3876 | cat conftest.$ac_ext >&5 | |
3877 | rm -rf conftest* | |
3878 | gt_cv_func_gettext_libc=no | |
252b5132 | 3879 | fi |
6be7c12c | 3880 | rm -f conftest* |
252b5132 | 3881 | fi |
6be7c12c AO |
3882 | |
3883 | echo "$ac_t""$gt_cv_func_gettext_libc" 1>&6 | |
252b5132 RH |
3884 | |
3885 | if test "$gt_cv_func_gettext_libc" != "yes"; then | |
6be7c12c | 3886 | echo $ac_n "checking for bindtextdomain in -lintl""... $ac_c" 1>&6 |
c6f8758f | 3887 | echo "configure:3888: checking for bindtextdomain in -lintl" >&5 |
6be7c12c AO |
3888 | ac_lib_var=`echo intl'_'bindtextdomain | sed 'y%./+-%__p_%'` |
3889 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then | |
3890 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 3891 | else |
6be7c12c | 3892 | ac_save_LIBS="$LIBS" |
252b5132 | 3893 | LIBS="-lintl $LIBS" |
6be7c12c | 3894 | cat > conftest.$ac_ext <<EOF |
c6f8758f | 3895 | #line 3896 "configure" |
252b5132 RH |
3896 | #include "confdefs.h" |
3897 | /* Override any gcc2 internal prototype to avoid an error. */ | |
3898 | /* We use char because int might match the return type of a gcc2 | |
6be7c12c AO |
3899 | builtin and then its argument prototype would still apply. */ |
3900 | char bindtextdomain(); | |
3901 | ||
3902 | int main() { | |
3903 | bindtextdomain() | |
3904 | ; return 0; } | |
3905 | EOF | |
c6f8758f | 3906 | if { (eval echo configure:3907: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
6be7c12c AO |
3907 | rm -rf conftest* |
3908 | eval "ac_cv_lib_$ac_lib_var=yes" | |
3909 | else | |
3910 | echo "configure: failed program was:" >&5 | |
3911 | cat conftest.$ac_ext >&5 | |
3912 | rm -rf conftest* | |
3913 | eval "ac_cv_lib_$ac_lib_var=no" | |
3914 | fi | |
3915 | rm -f conftest* | |
3916 | LIBS="$ac_save_LIBS" | |
3917 | ||
3918 | fi | |
3919 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then | |
3920 | echo "$ac_t""yes" 1>&6 | |
3921 | echo $ac_n "checking for gettext in libintl""... $ac_c" 1>&6 | |
c6f8758f | 3922 | echo "configure:3923: checking for gettext in libintl" >&5 |
6be7c12c AO |
3923 | if eval "test \"`echo '$''{'gt_cv_func_gettext_libintl'+set}'`\" = set"; then |
3924 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3925 | else | |
3926 | cat > conftest.$ac_ext <<EOF | |
c6f8758f | 3927 | #line 3928 "configure" |
252b5132 RH |
3928 | #include "confdefs.h" |
3929 | ||
6be7c12c | 3930 | int main() { |
252b5132 | 3931 | return (int) gettext ("") |
6be7c12c AO |
3932 | ; return 0; } |
3933 | EOF | |
c6f8758f | 3934 | if { (eval echo configure:3935: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
6be7c12c | 3935 | rm -rf conftest* |
252b5132 RH |
3936 | gt_cv_func_gettext_libintl=yes |
3937 | else | |
6be7c12c AO |
3938 | echo "configure: failed program was:" >&5 |
3939 | cat conftest.$ac_ext >&5 | |
3940 | rm -rf conftest* | |
3941 | gt_cv_func_gettext_libintl=no | |
252b5132 | 3942 | fi |
6be7c12c | 3943 | rm -f conftest* |
252b5132 | 3944 | fi |
6be7c12c AO |
3945 | |
3946 | echo "$ac_t""$gt_cv_func_gettext_libintl" 1>&6 | |
3947 | else | |
3948 | echo "$ac_t""no" 1>&6 | |
252b5132 RH |
3949 | fi |
3950 | ||
3951 | fi | |
3952 | ||
3953 | if test "$gt_cv_func_gettext_libc" = "yes" \ | |
3954 | || test "$gt_cv_func_gettext_libintl" = "yes"; then | |
6be7c12c | 3955 | cat >> confdefs.h <<\EOF |
252b5132 RH |
3956 | #define HAVE_GETTEXT 1 |
3957 | EOF | |
3958 | ||
3959 | # Extract the first word of "msgfmt", so it can be a program name with args. | |
3960 | set dummy msgfmt; ac_word=$2 | |
6be7c12c | 3961 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
c6f8758f | 3962 | echo "configure:3963: checking for $ac_word" >&5 |
6be7c12c AO |
3963 | if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then |
3964 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 RH |
3965 | else |
3966 | case "$MSGFMT" in | |
3967 | /*) | |
3968 | ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. | |
3969 | ;; | |
3970 | *) | |
3971 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" | |
3972 | for ac_dir in $PATH; do | |
3973 | test -z "$ac_dir" && ac_dir=. | |
3974 | if test -f $ac_dir/$ac_word; then | |
3975 | if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then | |
3976 | ac_cv_path_MSGFMT="$ac_dir/$ac_word" | |
3977 | break | |
3978 | fi | |
3979 | fi | |
3980 | done | |
3981 | IFS="$ac_save_ifs" | |
3982 | test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="no" | |
3983 | ;; | |
3984 | esac | |
3985 | fi | |
3986 | MSGFMT="$ac_cv_path_MSGFMT" | |
3987 | if test -n "$MSGFMT"; then | |
6be7c12c | 3988 | echo "$ac_t""$MSGFMT" 1>&6 |
252b5132 | 3989 | else |
6be7c12c | 3990 | echo "$ac_t""no" 1>&6 |
252b5132 RH |
3991 | fi |
3992 | if test "$MSGFMT" != "no"; then | |
6be7c12c | 3993 | for ac_func in dcgettext |
252b5132 | 3994 | do |
6be7c12c | 3995 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
c6f8758f | 3996 | echo "configure:3997: checking for $ac_func" >&5 |
6be7c12c AO |
3997 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
3998 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3999 | else | |
4000 | cat > conftest.$ac_ext <<EOF | |
c6f8758f | 4001 | #line 4002 "configure" |
252b5132 RH |
4002 | #include "confdefs.h" |
4003 | /* System header to define __stub macros and hopefully few prototypes, | |
6be7c12c | 4004 | which can conflict with char $ac_func(); below. */ |
252b5132 RH |
4005 | #include <assert.h> |
4006 | /* Override any gcc2 internal prototype to avoid an error. */ | |
4007 | /* We use char because int might match the return type of a gcc2 | |
6be7c12c AO |
4008 | builtin and then its argument prototype would still apply. */ |
4009 | char $ac_func(); | |
4010 | ||
4011 | int main() { | |
252b5132 RH |
4012 | |
4013 | /* The GNU C library defines this for functions which it implements | |
4014 | to always fail with ENOSYS. Some functions are actually named | |
4015 | something starting with __ and the normal name is an alias. */ | |
4016 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
4017 | choke me | |
4018 | #else | |
6be7c12c | 4019 | $ac_func(); |
252b5132 RH |
4020 | #endif |
4021 | ||
6be7c12c | 4022 | ; return 0; } |
252b5132 | 4023 | EOF |
c6f8758f | 4024 | if { (eval echo configure:4025: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
6be7c12c AO |
4025 | rm -rf conftest* |
4026 | eval "ac_cv_func_$ac_func=yes" | |
4027 | else | |
4028 | echo "configure: failed program was:" >&5 | |
4029 | cat conftest.$ac_ext >&5 | |
4030 | rm -rf conftest* | |
4031 | eval "ac_cv_func_$ac_func=no" | |
4032 | fi | |
4033 | rm -f conftest* | |
4034 | fi | |
252b5132 | 4035 | |
6be7c12c AO |
4036 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
4037 | echo "$ac_t""yes" 1>&6 | |
4038 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
4039 | cat >> confdefs.h <<EOF | |
4040 | #define $ac_tr_func 1 | |
4041 | EOF | |
4042 | ||
4043 | else | |
4044 | echo "$ac_t""no" 1>&6 | |
252b5132 RH |
4045 | fi |
4046 | done | |
4047 | ||
4048 | # Extract the first word of "gmsgfmt", so it can be a program name with args. | |
4049 | set dummy gmsgfmt; ac_word=$2 | |
6be7c12c | 4050 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
c6f8758f | 4051 | echo "configure:4052: checking for $ac_word" >&5 |
6be7c12c AO |
4052 | if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then |
4053 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 4054 | else |
6be7c12c AO |
4055 | case "$GMSGFMT" in |
4056 | /*) | |
252b5132 RH |
4057 | ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path. |
4058 | ;; | |
6be7c12c AO |
4059 | ?:/*) |
4060 | ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path. | |
4061 | ;; | |
252b5132 | 4062 | *) |
6be7c12c AO |
4063 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
4064 | ac_dummy="$PATH" | |
4065 | for ac_dir in $ac_dummy; do | |
4066 | test -z "$ac_dir" && ac_dir=. | |
4067 | if test -f $ac_dir/$ac_word; then | |
4068 | ac_cv_path_GMSGFMT="$ac_dir/$ac_word" | |
4069 | break | |
4070 | fi | |
4071 | done | |
4072 | IFS="$ac_save_ifs" | |
252b5132 RH |
4073 | test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT" |
4074 | ;; | |
4075 | esac | |
4076 | fi | |
6be7c12c | 4077 | GMSGFMT="$ac_cv_path_GMSGFMT" |
252b5132 | 4078 | if test -n "$GMSGFMT"; then |
6be7c12c | 4079 | echo "$ac_t""$GMSGFMT" 1>&6 |
252b5132 | 4080 | else |
6be7c12c | 4081 | echo "$ac_t""no" 1>&6 |
252b5132 RH |
4082 | fi |
4083 | ||
4084 | # Extract the first word of "xgettext", so it can be a program name with args. | |
4085 | set dummy xgettext; ac_word=$2 | |
6be7c12c | 4086 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
c6f8758f | 4087 | echo "configure:4088: checking for $ac_word" >&5 |
6be7c12c AO |
4088 | if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then |
4089 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 RH |
4090 | else |
4091 | case "$XGETTEXT" in | |
4092 | /*) | |
4093 | ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path. | |
4094 | ;; | |
4095 | *) | |
4096 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" | |
4097 | for ac_dir in $PATH; do | |
4098 | test -z "$ac_dir" && ac_dir=. | |
4099 | if test -f $ac_dir/$ac_word; then | |
4100 | if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then | |
4101 | ac_cv_path_XGETTEXT="$ac_dir/$ac_word" | |
4102 | break | |
4103 | fi | |
4104 | fi | |
4105 | done | |
4106 | IFS="$ac_save_ifs" | |
4107 | test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":" | |
4108 | ;; | |
4109 | esac | |
4110 | fi | |
4111 | XGETTEXT="$ac_cv_path_XGETTEXT" | |
4112 | if test -n "$XGETTEXT"; then | |
6be7c12c | 4113 | echo "$ac_t""$XGETTEXT" 1>&6 |
252b5132 | 4114 | else |
6be7c12c | 4115 | echo "$ac_t""no" 1>&6 |
252b5132 RH |
4116 | fi |
4117 | ||
6be7c12c | 4118 | cat > conftest.$ac_ext <<EOF |
c6f8758f | 4119 | #line 4120 "configure" |
252b5132 RH |
4120 | #include "confdefs.h" |
4121 | ||
6be7c12c | 4122 | int main() { |
252b5132 RH |
4123 | extern int _nl_msg_cat_cntr; |
4124 | return _nl_msg_cat_cntr | |
6be7c12c AO |
4125 | ; return 0; } |
4126 | EOF | |
c6f8758f | 4127 | if { (eval echo configure:4128: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
6be7c12c | 4128 | rm -rf conftest* |
252b5132 RH |
4129 | CATOBJEXT=.gmo |
4130 | DATADIRNAME=share | |
4131 | else | |
6be7c12c AO |
4132 | echo "configure: failed program was:" >&5 |
4133 | cat conftest.$ac_ext >&5 | |
4134 | rm -rf conftest* | |
4135 | CATOBJEXT=.mo | |
252b5132 RH |
4136 | DATADIRNAME=lib |
4137 | fi | |
6be7c12c | 4138 | rm -f conftest* |
252b5132 RH |
4139 | INSTOBJEXT=.mo |
4140 | fi | |
4141 | fi | |
6be7c12c AO |
4142 | |
4143 | else | |
4144 | echo "$ac_t""no" 1>&6 | |
b3baf5d0 | 4145 | fi |
252b5132 | 4146 | |
6be7c12c AO |
4147 | |
4148 | ||
252b5132 RH |
4149 | if test "$CATOBJEXT" = "NONE"; then |
4150 | nls_cv_use_gnu_gettext=yes | |
4151 | fi | |
4152 | fi | |
4153 | ||
4154 | if test "$nls_cv_use_gnu_gettext" = "yes"; then | |
4155 | INTLOBJS="\$(GETTOBJS)" | |
4156 | # Extract the first word of "msgfmt", so it can be a program name with args. | |
4157 | set dummy msgfmt; ac_word=$2 | |
6be7c12c | 4158 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
c6f8758f | 4159 | echo "configure:4160: checking for $ac_word" >&5 |
6be7c12c AO |
4160 | if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then |
4161 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 RH |
4162 | else |
4163 | case "$MSGFMT" in | |
4164 | /*) | |
4165 | ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. | |
4166 | ;; | |
4167 | *) | |
4168 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" | |
4169 | for ac_dir in $PATH; do | |
4170 | test -z "$ac_dir" && ac_dir=. | |
4171 | if test -f $ac_dir/$ac_word; then | |
4172 | if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then | |
4173 | ac_cv_path_MSGFMT="$ac_dir/$ac_word" | |
4174 | break | |
4175 | fi | |
4176 | fi | |
4177 | done | |
4178 | IFS="$ac_save_ifs" | |
4179 | test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="msgfmt" | |
4180 | ;; | |
4181 | esac | |
4182 | fi | |
4183 | MSGFMT="$ac_cv_path_MSGFMT" | |
4184 | if test -n "$MSGFMT"; then | |
6be7c12c | 4185 | echo "$ac_t""$MSGFMT" 1>&6 |
252b5132 | 4186 | else |
6be7c12c | 4187 | echo "$ac_t""no" 1>&6 |
252b5132 RH |
4188 | fi |
4189 | ||
4190 | # Extract the first word of "gmsgfmt", so it can be a program name with args. | |
4191 | set dummy gmsgfmt; ac_word=$2 | |
6be7c12c | 4192 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
c6f8758f | 4193 | echo "configure:4194: checking for $ac_word" >&5 |
6be7c12c AO |
4194 | if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then |
4195 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 4196 | else |
6be7c12c AO |
4197 | case "$GMSGFMT" in |
4198 | /*) | |
252b5132 RH |
4199 | ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path. |
4200 | ;; | |
6be7c12c AO |
4201 | ?:/*) |
4202 | ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path. | |
4203 | ;; | |
252b5132 | 4204 | *) |
6be7c12c AO |
4205 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
4206 | ac_dummy="$PATH" | |
4207 | for ac_dir in $ac_dummy; do | |
4208 | test -z "$ac_dir" && ac_dir=. | |
4209 | if test -f $ac_dir/$ac_word; then | |
4210 | ac_cv_path_GMSGFMT="$ac_dir/$ac_word" | |
4211 | break | |
4212 | fi | |
4213 | done | |
4214 | IFS="$ac_save_ifs" | |
252b5132 RH |
4215 | test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT" |
4216 | ;; | |
4217 | esac | |
4218 | fi | |
6be7c12c | 4219 | GMSGFMT="$ac_cv_path_GMSGFMT" |
252b5132 | 4220 | if test -n "$GMSGFMT"; then |
6be7c12c | 4221 | echo "$ac_t""$GMSGFMT" 1>&6 |
252b5132 | 4222 | else |
6be7c12c | 4223 | echo "$ac_t""no" 1>&6 |
252b5132 RH |
4224 | fi |
4225 | ||
4226 | # Extract the first word of "xgettext", so it can be a program name with args. | |
4227 | set dummy xgettext; ac_word=$2 | |
6be7c12c | 4228 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
c6f8758f | 4229 | echo "configure:4230: checking for $ac_word" >&5 |
6be7c12c AO |
4230 | if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then |
4231 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 RH |
4232 | else |
4233 | case "$XGETTEXT" in | |
4234 | /*) | |
4235 | ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path. | |
4236 | ;; | |
4237 | *) | |
4238 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" | |
4239 | for ac_dir in $PATH; do | |
4240 | test -z "$ac_dir" && ac_dir=. | |
4241 | if test -f $ac_dir/$ac_word; then | |
4242 | if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then | |
4243 | ac_cv_path_XGETTEXT="$ac_dir/$ac_word" | |
4244 | break | |
4245 | fi | |
4246 | fi | |
4247 | done | |
4248 | IFS="$ac_save_ifs" | |
4249 | test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":" | |
4250 | ;; | |
4251 | esac | |
4252 | fi | |
4253 | XGETTEXT="$ac_cv_path_XGETTEXT" | |
4254 | if test -n "$XGETTEXT"; then | |
6be7c12c | 4255 | echo "$ac_t""$XGETTEXT" 1>&6 |
252b5132 | 4256 | else |
6be7c12c | 4257 | echo "$ac_t""no" 1>&6 |
252b5132 RH |
4258 | fi |
4259 | ||
6be7c12c | 4260 | |
252b5132 RH |
4261 | USE_INCLUDED_LIBINTL=yes |
4262 | CATOBJEXT=.gmo | |
4263 | INSTOBJEXT=.mo | |
4264 | DATADIRNAME=share | |
4265 | INTLDEPS='$(top_builddir)/../intl/libintl.a' | |
4266 | INTLLIBS=$INTLDEPS | |
4267 | LIBS=`echo $LIBS | sed -e 's/-lintl//'` | |
4268 | nls_cv_header_intl=libintl.h | |
4269 | nls_cv_header_libgt=libgettext.h | |
4270 | fi | |
4271 | ||
4272 | if test "$XGETTEXT" != ":"; then | |
4273 | if $XGETTEXT --omit-header /dev/null 2> /dev/null; then | |
4274 | : ; | |
4275 | else | |
6be7c12c | 4276 | echo "$ac_t""found xgettext programs is not GNU xgettext; ignore it" 1>&6 |
252b5132 RH |
4277 | XGETTEXT=":" |
4278 | fi | |
4279 | fi | |
4280 | ||
4281 | # We need to process the po/ directory. | |
4282 | POSUB=po | |
4283 | else | |
4284 | DATADIRNAME=share | |
4285 | nls_cv_header_intl=libintl.h | |
4286 | nls_cv_header_libgt=libgettext.h | |
4287 | fi | |
4288 | ||
4289 | # If this is used in GNU gettext we have to set USE_NLS to `yes' | |
4290 | # because some of the sources are only built for this goal. | |
4291 | if test "$PACKAGE" = gettext; then | |
4292 | USE_NLS=yes | |
4293 | USE_INCLUDED_LIBINTL=yes | |
4294 | fi | |
4295 | ||
4296 | for lang in $ALL_LINGUAS; do | |
4297 | GMOFILES="$GMOFILES $lang.gmo" | |
4298 | POFILES="$POFILES $lang.po" | |
4299 | done | |
4300 | ||
6be7c12c AO |
4301 | |
4302 | ||
4303 | ||
4304 | ||
4305 | ||
4306 | ||
4307 | ||
4308 | ||
4309 | ||
4310 | ||
4311 | ||
4312 | ||
4313 | ||
252b5132 RH |
4314 | if test "x$CATOBJEXT" != "x"; then |
4315 | if test "x$ALL_LINGUAS" = "x"; then | |
4316 | LINGUAS= | |
4317 | else | |
6be7c12c | 4318 | echo $ac_n "checking for catalogs to be installed""... $ac_c" 1>&6 |
c6f8758f | 4319 | echo "configure:4320: checking for catalogs to be installed" >&5 |
252b5132 RH |
4320 | NEW_LINGUAS= |
4321 | for lang in ${LINGUAS=$ALL_LINGUAS}; do | |
4322 | case "$ALL_LINGUAS" in | |
4323 | *$lang*) NEW_LINGUAS="$NEW_LINGUAS $lang" ;; | |
4324 | esac | |
4325 | done | |
4326 | LINGUAS=$NEW_LINGUAS | |
6be7c12c | 4327 | echo "$ac_t""$LINGUAS" 1>&6 |
252b5132 RH |
4328 | fi |
4329 | ||
4330 | if test -n "$LINGUAS"; then | |
4331 | for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done | |
4332 | fi | |
4333 | fi | |
4334 | ||
4335 | if test $ac_cv_header_locale_h = yes; then | |
4336 | INCLUDE_LOCALE_H="#include <locale.h>" | |
4337 | else | |
4338 | INCLUDE_LOCALE_H="\ | |
4339 | /* The system does not provide the header <locale.h>. Take care yourself. */" | |
4340 | fi | |
6be7c12c | 4341 | |
252b5132 RH |
4342 | |
4343 | if test -f $srcdir/po2tbl.sed.in; then | |
4344 | if test "$CATOBJEXT" = ".cat"; then | |
6be7c12c AO |
4345 | ac_safe=`echo "linux/version.h" | sed 'y%./+-%__p_%'` |
4346 | echo $ac_n "checking for linux/version.h""... $ac_c" 1>&6 | |
c6f8758f | 4347 | echo "configure:4348: checking for linux/version.h" >&5 |
6be7c12c AO |
4348 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
4349 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4350 | else | |
4351 | cat > conftest.$ac_ext <<EOF | |
c6f8758f | 4352 | #line 4353 "configure" |
252b5132 RH |
4353 | #include "confdefs.h" |
4354 | #include <linux/version.h> | |
6be7c12c AO |
4355 | EOF |
4356 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
c6f8758f | 4357 | { (eval echo configure:4358: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
6be7c12c AO |
4358 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
4359 | if test -z "$ac_err"; then | |
4360 | rm -rf conftest* | |
4361 | eval "ac_cv_header_$ac_safe=yes" | |
252b5132 | 4362 | else |
6be7c12c AO |
4363 | echo "$ac_err" >&5 |
4364 | echo "configure: failed program was:" >&5 | |
252b5132 | 4365 | cat conftest.$ac_ext >&5 |
6be7c12c AO |
4366 | rm -rf conftest* |
4367 | eval "ac_cv_header_$ac_safe=no" | |
252b5132 | 4368 | fi |
6be7c12c | 4369 | rm -f conftest* |
252b5132 | 4370 | fi |
6be7c12c AO |
4371 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
4372 | echo "$ac_t""yes" 1>&6 | |
252b5132 RH |
4373 | msgformat=linux |
4374 | else | |
6be7c12c AO |
4375 | echo "$ac_t""no" 1>&6 |
4376 | msgformat=xopen | |
252b5132 RH |
4377 | fi |
4378 | ||
6be7c12c | 4379 | |
252b5132 RH |
4380 | sed -e '/^#/d' $srcdir/$msgformat-msg.sed > po2msg.sed |
4381 | fi | |
4382 | sed -e '/^#.*[^\\]$/d' -e '/^#$/d' \ | |
4383 | $srcdir/po2tbl.sed.in > po2tbl.sed | |
4384 | fi | |
4385 | ||
4386 | if test "$PACKAGE" = "gettext"; then | |
4387 | GT_NO="#NO#" | |
4388 | GT_YES= | |
4389 | else | |
4390 | GT_NO= | |
4391 | GT_YES="#YES#" | |
4392 | fi | |
6be7c12c AO |
4393 | |
4394 | ||
252b5132 RH |
4395 | |
4396 | MKINSTALLDIRS="\$(srcdir)/../../mkinstalldirs" | |
6be7c12c | 4397 | |
252b5132 RH |
4398 | |
4399 | l= | |
6be7c12c | 4400 | |
252b5132 | 4401 | |
3c3bdf30 | 4402 | if test -f $srcdir/po/POTFILES.in; then |
252b5132 RH |
4403 | test -d po || mkdir po |
4404 | if test "x$srcdir" != "x."; then | |
4405 | if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then | |
4406 | posrcprefix="$srcdir/" | |
4407 | else | |
4408 | posrcprefix="../$srcdir/" | |
4409 | fi | |
4410 | else | |
4411 | posrcprefix="../" | |
4412 | fi | |
4413 | rm -f po/POTFILES | |
4414 | sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \ | |
4415 | < $srcdir/po/POTFILES.in > po/POTFILES | |
4416 | fi | |
6be7c12c | 4417 | |
252b5132 RH |
4418 | |
4419 | # Permit host specific settings. | |
4420 | . ${srcdir}/configure.host | |
4421 | ||
6be7c12c | 4422 | |
252b5132 RH |
4423 | # Find a good install program. We prefer a C program (faster), |
4424 | # so one script is as good as another. But avoid the broken or | |
4425 | # incompatible versions: | |
4426 | # SysV /etc/install, /usr/sbin/install | |
4427 | # SunOS /usr/etc/install | |
4428 | # IRIX /sbin/install | |
4429 | # AIX /bin/install | |
4430 | # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag | |
4431 | # AFS /usr/afsws/bin/install, which mishandles nonexistent args | |
4432 | # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" | |
4433 | # ./install, which can be erroneously created by make from ./install.sh. | |
6be7c12c | 4434 | echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6 |
c6f8758f | 4435 | echo "configure:4436: checking for a BSD compatible install" >&5 |
252b5132 | 4436 | if test -z "$INSTALL"; then |
6be7c12c AO |
4437 | if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then |
4438 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 4439 | else |
6be7c12c | 4440 | IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":" |
252b5132 RH |
4441 | for ac_dir in $PATH; do |
4442 | # Account for people who put trailing slashes in PATH elements. | |
6be7c12c AO |
4443 | case "$ac_dir/" in |
4444 | /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;; | |
252b5132 RH |
4445 | *) |
4446 | # OSF1 and SCO ODT 3.0 have their own names for install. | |
4447 | # Don't use installbsd from OSF since it installs stuff as root | |
4448 | # by default. | |
4449 | for ac_prog in ginstall scoinst install; do | |
6be7c12c | 4450 | if test -f $ac_dir/$ac_prog; then |
252b5132 | 4451 | if test $ac_prog = install && |
6be7c12c | 4452 | grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then |
252b5132 RH |
4453 | # AIX install. It has an incompatible calling convention. |
4454 | : | |
4455 | else | |
4456 | ac_cv_path_install="$ac_dir/$ac_prog -c" | |
4457 | break 2 | |
4458 | fi | |
4459 | fi | |
4460 | done | |
4461 | ;; | |
4462 | esac | |
4463 | done | |
6be7c12c | 4464 | IFS="$ac_save_IFS" |
252b5132 RH |
4465 | |
4466 | fi | |
4467 | if test "${ac_cv_path_install+set}" = set; then | |
6be7c12c | 4468 | INSTALL="$ac_cv_path_install" |
252b5132 RH |
4469 | else |
4470 | # As a last resort, use the slow shell script. We don't cache a | |
4471 | # path for INSTALL within a source directory, because that will | |
4472 | # break other packages using the cache if that directory is | |
4473 | # removed, or if the path is relative. | |
6be7c12c | 4474 | INSTALL="$ac_install_sh" |
252b5132 RH |
4475 | fi |
4476 | fi | |
6be7c12c | 4477 | echo "$ac_t""$INSTALL" 1>&6 |
252b5132 RH |
4478 | |
4479 | # Use test -z because SunOS4 sh mishandles braces in ${var-val}. | |
4480 | # It thinks the first close brace ends the variable substitution. | |
4481 | test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' | |
4482 | ||
6be7c12c | 4483 | test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}' |
252b5132 RH |
4484 | |
4485 | test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' | |
4486 | ||
6be7c12c | 4487 | |
252b5132 | 4488 | BFD_HOST_64BIT_LONG=0 |
ec317fb1 | 4489 | BFD_HOST_LONG_LONG=0 |
252b5132 RH |
4490 | BFD_HOST_64_BIT_DEFINED=0 |
4491 | BFD_HOST_64_BIT= | |
4492 | BFD_HOST_U_64_BIT= | |
252b5132 | 4493 | |
ec317fb1 | 4494 | echo $ac_n "checking for long long""... $ac_c" 1>&6 |
c6f8758f | 4495 | echo "configure:4496: checking for long long" >&5 |
ec317fb1 ILT |
4496 | if eval "test \"`echo '$''{'bfd_cv_has_long_long'+set}'`\" = set"; then |
4497 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4498 | else | |
4499 | cat > conftest.$ac_ext <<EOF | |
c6f8758f | 4500 | #line 4501 "configure" |
ec317fb1 ILT |
4501 | #include "confdefs.h" |
4502 | ||
4503 | int main() { | |
4504 | unsigned long long ll = 18446744073709551615ULL; | |
4505 | ; return 0; } | |
4506 | EOF | |
c6f8758f | 4507 | if { (eval echo configure:4508: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
ec317fb1 ILT |
4508 | rm -rf conftest* |
4509 | bfd_cv_has_long_long=yes | |
4510 | else | |
4511 | echo "configure: failed program was:" >&5 | |
4512 | cat conftest.$ac_ext >&5 | |
4513 | rm -rf conftest* | |
4514 | bfd_cv_has_long_long=no | |
4515 | fi | |
4516 | rm -f conftest* | |
4517 | fi | |
4518 | ||
4519 | echo "$ac_t""$bfd_cv_has_long_long" 1>&6 | |
4520 | if test $bfd_cv_has_long_long = yes; then | |
4521 | BFD_HOST_LONG_LONG=1 | |
6726e1ea | 4522 | echo $ac_n "checking size of long long""... $ac_c" 1>&6 |
c6f8758f | 4523 | echo "configure:4524: checking size of long long" >&5 |
6726e1ea L |
4524 | if eval "test \"`echo '$''{'ac_cv_sizeof_long_long'+set}'`\" = set"; then |
4525 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4526 | else | |
4527 | for ac_size in 4 8 1 2 16 12 ; do # List sizes in rough order of prevalence. | |
4528 | cat > conftest.$ac_ext <<EOF | |
c6f8758f | 4529 | #line 4530 "configure" |
6726e1ea L |
4530 | #include "confdefs.h" |
4531 | #include "confdefs.h" | |
4532 | #include <sys/types.h> | |
4533 | ||
4534 | ||
4535 | int main() { | |
4536 | switch (0) case 0: case (sizeof (long long) == $ac_size):; | |
4537 | ; return 0; } | |
4538 | EOF | |
c6f8758f | 4539 | if { (eval echo configure:4540: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
6726e1ea L |
4540 | rm -rf conftest* |
4541 | ac_cv_sizeof_long_long=$ac_size | |
4542 | else | |
4543 | echo "configure: failed program was:" >&5 | |
4544 | cat conftest.$ac_ext >&5 | |
4545 | fi | |
4546 | rm -f conftest* | |
4547 | if test x$ac_cv_sizeof_long_long != x ; then break; fi | |
4548 | done | |
4549 | ||
4550 | fi | |
4551 | ||
4552 | if test x$ac_cv_sizeof_long_long = x ; then | |
4553 | { echo "configure: error: cannot determine a size for long long" 1>&2; exit 1; } | |
4554 | fi | |
4555 | echo "$ac_t""$ac_cv_sizeof_long_long" 1>&6 | |
4556 | cat >> confdefs.h <<EOF | |
4557 | #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long | |
4558 | EOF | |
4559 | ||
4560 | ||
4561 | fi | |
4562 | ||
4563 | echo $ac_n "checking size of long""... $ac_c" 1>&6 | |
c6f8758f | 4564 | echo "configure:4565: checking size of long" >&5 |
6726e1ea L |
4565 | if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then |
4566 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4567 | else | |
4568 | for ac_size in 4 8 1 2 16 12 ; do # List sizes in rough order of prevalence. | |
4569 | cat > conftest.$ac_ext <<EOF | |
c6f8758f | 4570 | #line 4571 "configure" |
6726e1ea L |
4571 | #include "confdefs.h" |
4572 | #include "confdefs.h" | |
4573 | #include <sys/types.h> | |
4574 | ||
4575 | ||
4576 | int main() { | |
4577 | switch (0) case 0: case (sizeof (long) == $ac_size):; | |
4578 | ; return 0; } | |
4579 | EOF | |
c6f8758f | 4580 | if { (eval echo configure:4581: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
6726e1ea L |
4581 | rm -rf conftest* |
4582 | ac_cv_sizeof_long=$ac_size | |
4583 | else | |
4584 | echo "configure: failed program was:" >&5 | |
4585 | cat conftest.$ac_ext >&5 | |
4586 | fi | |
4587 | rm -f conftest* | |
4588 | if test x$ac_cv_sizeof_long != x ; then break; fi | |
4589 | done | |
4590 | ||
4591 | fi | |
4592 | ||
4593 | if test x$ac_cv_sizeof_long = x ; then | |
4594 | { echo "configure: error: cannot determine a size for long" 1>&2; exit 1; } | |
4595 | fi | |
4596 | echo "$ac_t""$ac_cv_sizeof_long" 1>&6 | |
4597 | cat >> confdefs.h <<EOF | |
4598 | #define SIZEOF_LONG $ac_cv_sizeof_long | |
4599 | EOF | |
4600 | ||
4601 | ||
4602 | if test "x${ac_cv_sizeof_long}" = "x8"; then | |
4603 | host64=true | |
ccba357f AM |
4604 | BFD_HOST_64BIT_LONG=1 |
4605 | test -n "${HOST_64BIT_TYPE}" || HOST_64BIT_TYPE="long" | |
4606 | test -n "${HOST_U_64BIT_TYPE}" || HOST_U_64BIT_TYPE="unsigned long" | |
6726e1ea | 4607 | elif test "x${ac_cv_sizeof_long_long}" = "x8"; then |
ccba357f AM |
4608 | test -n "${HOST_64BIT_TYPE}" || HOST_64BIT_TYPE="long long" |
4609 | test -n "${HOST_U_64BIT_TYPE}" || HOST_U_64BIT_TYPE="unsigned long long" | |
6726e1ea L |
4610 | fi |
4611 | ||
ccba357f | 4612 | if test -n "${HOST_64BIT_TYPE}" -a -n "${HOST_U_64BIT_TYPE}"; then |
6726e1ea | 4613 | BFD_HOST_64_BIT_DEFINED=1 |
ccba357f AM |
4614 | BFD_HOST_64_BIT="${HOST_64BIT_TYPE}" |
4615 | BFD_HOST_U_64_BIT="${HOST_U_64BIT_TYPE}" | |
ec317fb1 ILT |
4616 | fi |
4617 | ||
4618 | ||
4619 | ||
6be7c12c AO |
4620 | |
4621 | ||
4622 | ||
4623 | ||
252b5132 RH |
4624 | # Put a plausible default for CC_FOR_BUILD in Makefile. |
4625 | if test -z "$CC_FOR_BUILD"; then | |
4626 | if test "x$cross_compiling" = "xno"; then | |
4627 | CC_FOR_BUILD='$(CC)' | |
4628 | else | |
4629 | CC_FOR_BUILD=gcc | |
4630 | fi | |
4631 | fi | |
4632 | ||
4633 | # Also set EXEEXT_FOR_BUILD. | |
4634 | if test "x$cross_compiling" = "xno"; then | |
4635 | EXEEXT_FOR_BUILD='$(EXEEXT)' | |
4636 | else | |
6be7c12c | 4637 | echo $ac_n "checking for build system executable suffix""... $ac_c" 1>&6 |
c6f8758f | 4638 | echo "configure:4639: checking for build system executable suffix" >&5 |
6be7c12c AO |
4639 | if eval "test \"`echo '$''{'bfd_cv_build_exeext'+set}'`\" = set"; then |
4640 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 4641 | else |
aab08431 ILT |
4642 | rm -f conftest* |
4643 | echo 'int main () { return 0; }' > conftest.c | |
4644 | bfd_cv_build_exeext= | |
4645 | ${CC_FOR_BUILD} -o conftest conftest.c 1>&5 2>&5 | |
4646 | for file in conftest.*; do | |
4647 | case $file in | |
4648 | *.c | *.o | *.obj | *.ilk | *.pdb) ;; | |
4649 | *) bfd_cv_build_exeext=`echo $file | sed -e s/conftest//` ;; | |
4650 | esac | |
4651 | done | |
4652 | rm -f conftest* | |
4653 | test x"${bfd_cv_build_exeext}" = x && bfd_cv_build_exeext=no | |
252b5132 | 4654 | fi |
6be7c12c AO |
4655 | |
4656 | echo "$ac_t""$bfd_cv_build_exeext" 1>&6 | |
252b5132 RH |
4657 | EXEEXT_FOR_BUILD="" |
4658 | test x"${bfd_cv_build_exeext}" != xno && EXEEXT_FOR_BUILD=${bfd_cv_build_exeext} | |
4659 | fi | |
4660 | ||
6be7c12c AO |
4661 | |
4662 | for ac_hdr in stddef.h string.h strings.h stdlib.h time.h unistd.h | |
252b5132 | 4663 | do |
6be7c12c AO |
4664 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` |
4665 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 | |
c6f8758f | 4666 | echo "configure:4667: checking for $ac_hdr" >&5 |
6be7c12c AO |
4667 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
4668 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4669 | else | |
4670 | cat > conftest.$ac_ext <<EOF | |
c6f8758f | 4671 | #line 4672 "configure" |
252b5132 | 4672 | #include "confdefs.h" |
6be7c12c AO |
4673 | #include <$ac_hdr> |
4674 | EOF | |
4675 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
c6f8758f | 4676 | { (eval echo configure:4677: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
6be7c12c AO |
4677 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
4678 | if test -z "$ac_err"; then | |
4679 | rm -rf conftest* | |
4680 | eval "ac_cv_header_$ac_safe=yes" | |
252b5132 | 4681 | else |
6be7c12c AO |
4682 | echo "$ac_err" >&5 |
4683 | echo "configure: failed program was:" >&5 | |
252b5132 | 4684 | cat conftest.$ac_ext >&5 |
6be7c12c AO |
4685 | rm -rf conftest* |
4686 | eval "ac_cv_header_$ac_safe=no" | |
252b5132 | 4687 | fi |
6be7c12c | 4688 | rm -f conftest* |
252b5132 | 4689 | fi |
6be7c12c AO |
4690 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
4691 | echo "$ac_t""yes" 1>&6 | |
4692 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` | |
4693 | cat >> confdefs.h <<EOF | |
4694 | #define $ac_tr_hdr 1 | |
252b5132 | 4695 | EOF |
6be7c12c AO |
4696 | |
4697 | else | |
4698 | echo "$ac_t""no" 1>&6 | |
252b5132 RH |
4699 | fi |
4700 | done | |
4701 | ||
6be7c12c | 4702 | for ac_hdr in fcntl.h sys/file.h sys/time.h |
252b5132 | 4703 | do |
6be7c12c AO |
4704 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` |
4705 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 | |
c6f8758f | 4706 | echo "configure:4707: checking for $ac_hdr" >&5 |
6be7c12c AO |
4707 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
4708 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4709 | else | |
4710 | cat > conftest.$ac_ext <<EOF | |
c6f8758f | 4711 | #line 4712 "configure" |
252b5132 | 4712 | #include "confdefs.h" |
6be7c12c AO |
4713 | #include <$ac_hdr> |
4714 | EOF | |
4715 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
c6f8758f | 4716 | { (eval echo configure:4717: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
6be7c12c AO |
4717 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
4718 | if test -z "$ac_err"; then | |
4719 | rm -rf conftest* | |
4720 | eval "ac_cv_header_$ac_safe=yes" | |
252b5132 | 4721 | else |
6be7c12c AO |
4722 | echo "$ac_err" >&5 |
4723 | echo "configure: failed program was:" >&5 | |
252b5132 | 4724 | cat conftest.$ac_ext >&5 |
6be7c12c AO |
4725 | rm -rf conftest* |
4726 | eval "ac_cv_header_$ac_safe=no" | |
252b5132 | 4727 | fi |
6be7c12c | 4728 | rm -f conftest* |
252b5132 | 4729 | fi |
6be7c12c AO |
4730 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
4731 | echo "$ac_t""yes" 1>&6 | |
4732 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` | |
4733 | cat >> confdefs.h <<EOF | |
4734 | #define $ac_tr_hdr 1 | |
252b5132 | 4735 | EOF |
6be7c12c AO |
4736 | |
4737 | else | |
4738 | echo "$ac_t""no" 1>&6 | |
252b5132 RH |
4739 | fi |
4740 | done | |
4741 | ||
6be7c12c | 4742 | echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6 |
c6f8758f | 4743 | echo "configure:4744: checking whether time.h and sys/time.h may both be included" >&5 |
6be7c12c AO |
4744 | if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then |
4745 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 4746 | else |
6be7c12c | 4747 | cat > conftest.$ac_ext <<EOF |
c6f8758f | 4748 | #line 4749 "configure" |
252b5132 RH |
4749 | #include "confdefs.h" |
4750 | #include <sys/types.h> | |
4751 | #include <sys/time.h> | |
4752 | #include <time.h> | |
6be7c12c | 4753 | int main() { |
252b5132 | 4754 | struct tm *tp; |
6be7c12c AO |
4755 | ; return 0; } |
4756 | EOF | |
c6f8758f | 4757 | if { (eval echo configure:4758: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
6be7c12c | 4758 | rm -rf conftest* |
252b5132 RH |
4759 | ac_cv_header_time=yes |
4760 | else | |
6be7c12c AO |
4761 | echo "configure: failed program was:" >&5 |
4762 | cat conftest.$ac_ext >&5 | |
4763 | rm -rf conftest* | |
4764 | ac_cv_header_time=no | |
252b5132 | 4765 | fi |
6be7c12c | 4766 | rm -f conftest* |
252b5132 | 4767 | fi |
b3baf5d0 | 4768 | |
6be7c12c AO |
4769 | echo "$ac_t""$ac_cv_header_time" 1>&6 |
4770 | if test $ac_cv_header_time = yes; then | |
4771 | cat >> confdefs.h <<\EOF | |
252b5132 RH |
4772 | #define TIME_WITH_SYS_TIME 1 |
4773 | EOF | |
4774 | ||
4775 | fi | |
4776 | ||
4777 | ac_header_dirent=no | |
6be7c12c AO |
4778 | for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h |
4779 | do | |
4780 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` | |
4781 | echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6 | |
c6f8758f | 4782 | echo "configure:4783: checking for $ac_hdr that defines DIR" >&5 |
6be7c12c AO |
4783 | if eval "test \"`echo '$''{'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then |
4784 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4785 | else | |
4786 | cat > conftest.$ac_ext <<EOF | |
c6f8758f | 4787 | #line 4788 "configure" |
252b5132 RH |
4788 | #include "confdefs.h" |
4789 | #include <sys/types.h> | |
4790 | #include <$ac_hdr> | |
6be7c12c | 4791 | int main() { |
252b5132 | 4792 | DIR *dirp = 0; |
6be7c12c AO |
4793 | ; return 0; } |
4794 | EOF | |
c6f8758f | 4795 | if { (eval echo configure:4796: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
6be7c12c AO |
4796 | rm -rf conftest* |
4797 | eval "ac_cv_header_dirent_$ac_safe=yes" | |
252b5132 | 4798 | else |
6be7c12c AO |
4799 | echo "configure: failed program was:" >&5 |
4800 | cat conftest.$ac_ext >&5 | |
4801 | rm -rf conftest* | |
4802 | eval "ac_cv_header_dirent_$ac_safe=no" | |
252b5132 | 4803 | fi |
6be7c12c | 4804 | rm -f conftest* |
252b5132 | 4805 | fi |
6be7c12c AO |
4806 | if eval "test \"`echo '$ac_cv_header_dirent_'$ac_safe`\" = yes"; then |
4807 | echo "$ac_t""yes" 1>&6 | |
4808 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` | |
4809 | cat >> confdefs.h <<EOF | |
4810 | #define $ac_tr_hdr 1 | |
252b5132 | 4811 | EOF |
6be7c12c AO |
4812 | ac_header_dirent=$ac_hdr; break |
4813 | else | |
4814 | echo "$ac_t""no" 1>&6 | |
252b5132 RH |
4815 | fi |
4816 | done | |
4817 | # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. | |
4818 | if test $ac_header_dirent = dirent.h; then | |
6be7c12c | 4819 | echo $ac_n "checking for opendir in -ldir""... $ac_c" 1>&6 |
c6f8758f | 4820 | echo "configure:4821: checking for opendir in -ldir" >&5 |
6be7c12c AO |
4821 | ac_lib_var=`echo dir'_'opendir | sed 'y%./+-%__p_%'` |
4822 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then | |
4823 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 4824 | else |
6be7c12c | 4825 | ac_save_LIBS="$LIBS" |
252b5132 | 4826 | LIBS="-ldir $LIBS" |
6be7c12c | 4827 | cat > conftest.$ac_ext <<EOF |
c6f8758f | 4828 | #line 4829 "configure" |
252b5132 RH |
4829 | #include "confdefs.h" |
4830 | /* Override any gcc2 internal prototype to avoid an error. */ | |
4831 | /* We use char because int might match the return type of a gcc2 | |
6be7c12c AO |
4832 | builtin and then its argument prototype would still apply. */ |
4833 | char opendir(); | |
4834 | ||
4835 | int main() { | |
4836 | opendir() | |
4837 | ; return 0; } | |
4838 | EOF | |
c6f8758f | 4839 | if { (eval echo configure:4840: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
6be7c12c AO |
4840 | rm -rf conftest* |
4841 | eval "ac_cv_lib_$ac_lib_var=yes" | |
4842 | else | |
4843 | echo "configure: failed program was:" >&5 | |
4844 | cat conftest.$ac_ext >&5 | |
4845 | rm -rf conftest* | |
4846 | eval "ac_cv_lib_$ac_lib_var=no" | |
4847 | fi | |
4848 | rm -f conftest* | |
4849 | LIBS="$ac_save_LIBS" | |
4850 | ||
4851 | fi | |
4852 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then | |
4853 | echo "$ac_t""yes" 1>&6 | |
252b5132 | 4854 | LIBS="$LIBS -ldir" |
6be7c12c AO |
4855 | else |
4856 | echo "$ac_t""no" 1>&6 | |
252b5132 RH |
4857 | fi |
4858 | ||
4859 | else | |
6be7c12c | 4860 | echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6 |
c6f8758f | 4861 | echo "configure:4862: checking for opendir in -lx" >&5 |
6be7c12c AO |
4862 | ac_lib_var=`echo x'_'opendir | sed 'y%./+-%__p_%'` |
4863 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then | |
4864 | echo $ac_n "(cached) $ac_c" 1>&6 | |
b3baf5d0 | 4865 | else |
6be7c12c | 4866 | ac_save_LIBS="$LIBS" |
b3baf5d0 | 4867 | LIBS="-lx $LIBS" |
6be7c12c | 4868 | cat > conftest.$ac_ext <<EOF |
c6f8758f | 4869 | #line 4870 "configure" |
b3baf5d0 | 4870 | #include "confdefs.h" |
6be7c12c AO |
4871 | /* Override any gcc2 internal prototype to avoid an error. */ |
4872 | /* We use char because int might match the return type of a gcc2 | |
4873 | builtin and then its argument prototype would still apply. */ | |
4874 | char opendir(); | |
4875 | ||
4876 | int main() { | |
4877 | opendir() | |
4878 | ; return 0; } | |
4879 | EOF | |
c6f8758f | 4880 | if { (eval echo configure:4881: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
6be7c12c AO |
4881 | rm -rf conftest* |
4882 | eval "ac_cv_lib_$ac_lib_var=yes" | |
4883 | else | |
4884 | echo "configure: failed program was:" >&5 | |
4885 | cat conftest.$ac_ext >&5 | |
4886 | rm -rf conftest* | |
4887 | eval "ac_cv_lib_$ac_lib_var=no" | |
4888 | fi | |
4889 | rm -f conftest* | |
4890 | LIBS="$ac_save_LIBS" | |
252b5132 | 4891 | |
6be7c12c AO |
4892 | fi |
4893 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then | |
4894 | echo "$ac_t""yes" 1>&6 | |
252b5132 | 4895 | LIBS="$LIBS -lx" |
6be7c12c AO |
4896 | else |
4897 | echo "$ac_t""no" 1>&6 | |
252b5132 RH |
4898 | fi |
4899 | ||
4900 | fi | |
4901 | ||
633fd09f | 4902 | for ac_func in fcntl getpagesize setitimer sysconf fdopen getuid getgid |
252b5132 | 4903 | do |
6be7c12c | 4904 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
c6f8758f | 4905 | echo "configure:4906: checking for $ac_func" >&5 |
6be7c12c AO |
4906 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
4907 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4908 | else | |
4909 | cat > conftest.$ac_ext <<EOF | |
c6f8758f | 4910 | #line 4911 "configure" |
252b5132 RH |
4911 | #include "confdefs.h" |
4912 | /* System header to define __stub macros and hopefully few prototypes, | |
6be7c12c | 4913 | which can conflict with char $ac_func(); below. */ |
252b5132 RH |
4914 | #include <assert.h> |
4915 | /* Override any gcc2 internal prototype to avoid an error. */ | |
4916 | /* We use char because int might match the return type of a gcc2 | |
6be7c12c AO |
4917 | builtin and then its argument prototype would still apply. */ |
4918 | char $ac_func(); | |
4919 | ||
4920 | int main() { | |
252b5132 RH |
4921 | |
4922 | /* The GNU C library defines this for functions which it implements | |
4923 | to always fail with ENOSYS. Some functions are actually named | |
4924 | something starting with __ and the normal name is an alias. */ | |
4925 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
4926 | choke me | |
4927 | #else | |
6be7c12c | 4928 | $ac_func(); |
252b5132 RH |
4929 | #endif |
4930 | ||
6be7c12c | 4931 | ; return 0; } |
252b5132 | 4932 | EOF |
c6f8758f | 4933 | if { (eval echo configure:4934: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
6be7c12c AO |
4934 | rm -rf conftest* |
4935 | eval "ac_cv_func_$ac_func=yes" | |
4936 | else | |
4937 | echo "configure: failed program was:" >&5 | |
4938 | cat conftest.$ac_ext >&5 | |
4939 | rm -rf conftest* | |
4940 | eval "ac_cv_func_$ac_func=no" | |
4941 | fi | |
4942 | rm -f conftest* | |
4943 | fi | |
252b5132 | 4944 | |
6be7c12c AO |
4945 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
4946 | echo "$ac_t""yes" 1>&6 | |
4947 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
4948 | cat >> confdefs.h <<EOF | |
4949 | #define $ac_tr_func 1 | |
4950 | EOF | |
4951 | ||
4952 | else | |
4953 | echo "$ac_t""no" 1>&6 | |
252b5132 RH |
4954 | fi |
4955 | done | |
4956 | ||
49c97a80 ILT |
4957 | for ac_func in strtoull |
4958 | do | |
4959 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
c6f8758f | 4960 | echo "configure:4961: checking for $ac_func" >&5 |
49c97a80 ILT |
4961 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
4962 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4963 | else | |
4964 | cat > conftest.$ac_ext <<EOF | |
c6f8758f | 4965 | #line 4966 "configure" |
49c97a80 ILT |
4966 | #include "confdefs.h" |
4967 | /* System header to define __stub macros and hopefully few prototypes, | |
4968 | which can conflict with char $ac_func(); below. */ | |
4969 | #include <assert.h> | |
4970 | /* Override any gcc2 internal prototype to avoid an error. */ | |
4971 | /* We use char because int might match the return type of a gcc2 | |
4972 | builtin and then its argument prototype would still apply. */ | |
4973 | char $ac_func(); | |
4974 | ||
4975 | int main() { | |
4976 | ||
4977 | /* The GNU C library defines this for functions which it implements | |
4978 | to always fail with ENOSYS. Some functions are actually named | |
4979 | something starting with __ and the normal name is an alias. */ | |
4980 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
4981 | choke me | |
4982 | #else | |
4983 | $ac_func(); | |
4984 | #endif | |
4985 | ||
4986 | ; return 0; } | |
4987 | EOF | |
c6f8758f | 4988 | if { (eval echo configure:4989: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
49c97a80 ILT |
4989 | rm -rf conftest* |
4990 | eval "ac_cv_func_$ac_func=yes" | |
4991 | else | |
4992 | echo "configure: failed program was:" >&5 | |
4993 | cat conftest.$ac_ext >&5 | |
4994 | rm -rf conftest* | |
4995 | eval "ac_cv_func_$ac_func=no" | |
4996 | fi | |
4997 | rm -f conftest* | |
4998 | fi | |
4999 | ||
5000 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then | |
5001 | echo "$ac_t""yes" 1>&6 | |
5002 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
5003 | cat >> confdefs.h <<EOF | |
5004 | #define $ac_tr_func 1 | |
5005 | EOF | |
5006 | ||
5007 | else | |
5008 | echo "$ac_t""no" 1>&6 | |
5009 | fi | |
5010 | done | |
5011 | ||
6be7c12c AO |
5012 | |
5013 | ||
252b5132 | 5014 | case "${host}" in |
855b0be7 | 5015 | *-*-msdos* | *-*-go32* | *-*-mingw32* | *-*-cygwin* | *-*-windows*) |
6be7c12c | 5016 | cat >> confdefs.h <<\EOF |
252b5132 RH |
5017 | #define USE_BINARY_FOPEN 1 |
5018 | EOF | |
5019 | ;; | |
5020 | esac | |
5021 | ||
6be7c12c | 5022 | echo $ac_n "checking whether strstr must be declared""... $ac_c" 1>&6 |
c6f8758f | 5023 | echo "configure:5024: checking whether strstr must be declared" >&5 |
6be7c12c AO |
5024 | if eval "test \"`echo '$''{'bfd_cv_decl_needed_strstr'+set}'`\" = set"; then |
5025 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 5026 | else |
6be7c12c | 5027 | cat > conftest.$ac_ext <<EOF |
c6f8758f | 5028 | #line 5029 "configure" |
252b5132 RH |
5029 | #include "confdefs.h" |
5030 | ||
5031 | #include <stdio.h> | |
5032 | #ifdef HAVE_STRING_H | |
5033 | #include <string.h> | |
5034 | #else | |
5035 | #ifdef HAVE_STRINGS_H | |
5036 | #include <strings.h> | |
5037 | #endif | |
5038 | #endif | |
5039 | #ifdef HAVE_STDLIB_H | |
5040 | #include <stdlib.h> | |
5041 | #endif | |
5042 | #ifdef HAVE_UNISTD_H | |
5043 | #include <unistd.h> | |
5044 | #endif | |
6be7c12c | 5045 | int main() { |
252b5132 | 5046 | char *(*pfn) = (char *(*)) strstr |
6be7c12c AO |
5047 | ; return 0; } |
5048 | EOF | |
c6f8758f | 5049 | if { (eval echo configure:5050: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
6be7c12c | 5050 | rm -rf conftest* |
252b5132 RH |
5051 | bfd_cv_decl_needed_strstr=no |
5052 | else | |
6be7c12c AO |
5053 | echo "configure: failed program was:" >&5 |
5054 | cat conftest.$ac_ext >&5 | |
5055 | rm -rf conftest* | |
5056 | bfd_cv_decl_needed_strstr=yes | |
252b5132 | 5057 | fi |
6be7c12c | 5058 | rm -f conftest* |
252b5132 RH |
5059 | fi |
5060 | ||
6be7c12c | 5061 | echo "$ac_t""$bfd_cv_decl_needed_strstr" 1>&6 |
252b5132 | 5062 | if test $bfd_cv_decl_needed_strstr = yes; then |
6be7c12c | 5063 | cat >> confdefs.h <<\EOF |
252b5132 RH |
5064 | #define NEED_DECLARATION_STRSTR 1 |
5065 | EOF | |
5066 | ||
5067 | fi | |
5068 | ||
6be7c12c | 5069 | echo $ac_n "checking whether malloc must be declared""... $ac_c" 1>&6 |
c6f8758f | 5070 | echo "configure:5071: checking whether malloc must be declared" >&5 |
6be7c12c AO |
5071 | if eval "test \"`echo '$''{'bfd_cv_decl_needed_malloc'+set}'`\" = set"; then |
5072 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 5073 | else |
6be7c12c | 5074 | cat > conftest.$ac_ext <<EOF |
c6f8758f | 5075 | #line 5076 "configure" |
252b5132 RH |
5076 | #include "confdefs.h" |
5077 | ||
5078 | #include <stdio.h> | |
5079 | #ifdef HAVE_STRING_H | |
5080 | #include <string.h> | |
5081 | #else | |
5082 | #ifdef HAVE_STRINGS_H | |
5083 | #include <strings.h> | |
5084 | #endif | |
5085 | #endif | |
5086 | #ifdef HAVE_STDLIB_H | |
5087 | #include <stdlib.h> | |
5088 | #endif | |
5089 | #ifdef HAVE_UNISTD_H | |
5090 | #include <unistd.h> | |
5091 | #endif | |
6be7c12c | 5092 | int main() { |
252b5132 | 5093 | char *(*pfn) = (char *(*)) malloc |
6be7c12c AO |
5094 | ; return 0; } |
5095 | EOF | |
c6f8758f | 5096 | if { (eval echo configure:5097: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
6be7c12c | 5097 | rm -rf conftest* |
252b5132 RH |
5098 | bfd_cv_decl_needed_malloc=no |
5099 | else | |
6be7c12c AO |
5100 | echo "configure: failed program was:" >&5 |
5101 | cat conftest.$ac_ext >&5 | |
5102 | rm -rf conftest* | |
5103 | bfd_cv_decl_needed_malloc=yes | |
252b5132 | 5104 | fi |
6be7c12c | 5105 | rm -f conftest* |
252b5132 RH |
5106 | fi |
5107 | ||
6be7c12c | 5108 | echo "$ac_t""$bfd_cv_decl_needed_malloc" 1>&6 |
252b5132 | 5109 | if test $bfd_cv_decl_needed_malloc = yes; then |
6be7c12c | 5110 | cat >> confdefs.h <<\EOF |
252b5132 RH |
5111 | #define NEED_DECLARATION_MALLOC 1 |
5112 | EOF | |
5113 | ||
5114 | fi | |
5115 | ||
6be7c12c | 5116 | echo $ac_n "checking whether realloc must be declared""... $ac_c" 1>&6 |
c6f8758f | 5117 | echo "configure:5118: checking whether realloc must be declared" >&5 |
6be7c12c AO |
5118 | if eval "test \"`echo '$''{'bfd_cv_decl_needed_realloc'+set}'`\" = set"; then |
5119 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 5120 | else |
6be7c12c | 5121 | cat > conftest.$ac_ext <<EOF |
c6f8758f | 5122 | #line 5123 "configure" |
252b5132 RH |
5123 | #include "confdefs.h" |
5124 | ||
5125 | #include <stdio.h> | |
5126 | #ifdef HAVE_STRING_H | |
5127 | #include <string.h> | |
5128 | #else | |
5129 | #ifdef HAVE_STRINGS_H | |
5130 | #include <strings.h> | |
5131 | #endif | |
5132 | #endif | |
5133 | #ifdef HAVE_STDLIB_H | |
5134 | #include <stdlib.h> | |
5135 | #endif | |
5136 | #ifdef HAVE_UNISTD_H | |
5137 | #include <unistd.h> | |
5138 | #endif | |
6be7c12c | 5139 | int main() { |
252b5132 | 5140 | char *(*pfn) = (char *(*)) realloc |
6be7c12c AO |
5141 | ; return 0; } |
5142 | EOF | |
c6f8758f | 5143 | if { (eval echo configure:5144: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
6be7c12c | 5144 | rm -rf conftest* |
252b5132 RH |
5145 | bfd_cv_decl_needed_realloc=no |
5146 | else | |
6be7c12c AO |
5147 | echo "configure: failed program was:" >&5 |
5148 | cat conftest.$ac_ext >&5 | |
5149 | rm -rf conftest* | |
5150 | bfd_cv_decl_needed_realloc=yes | |
252b5132 | 5151 | fi |
6be7c12c | 5152 | rm -f conftest* |
252b5132 RH |
5153 | fi |
5154 | ||
6be7c12c | 5155 | echo "$ac_t""$bfd_cv_decl_needed_realloc" 1>&6 |
252b5132 | 5156 | if test $bfd_cv_decl_needed_realloc = yes; then |
6be7c12c | 5157 | cat >> confdefs.h <<\EOF |
252b5132 RH |
5158 | #define NEED_DECLARATION_REALLOC 1 |
5159 | EOF | |
5160 | ||
5161 | fi | |
5162 | ||
6be7c12c | 5163 | echo $ac_n "checking whether free must be declared""... $ac_c" 1>&6 |
c6f8758f | 5164 | echo "configure:5165: checking whether free must be declared" >&5 |
6be7c12c AO |
5165 | if eval "test \"`echo '$''{'bfd_cv_decl_needed_free'+set}'`\" = set"; then |
5166 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 5167 | else |
6be7c12c | 5168 | cat > conftest.$ac_ext <<EOF |
c6f8758f | 5169 | #line 5170 "configure" |
252b5132 RH |
5170 | #include "confdefs.h" |
5171 | ||
5172 | #include <stdio.h> | |
5173 | #ifdef HAVE_STRING_H | |
5174 | #include <string.h> | |
5175 | #else | |
5176 | #ifdef HAVE_STRINGS_H | |
5177 | #include <strings.h> | |
5178 | #endif | |
5179 | #endif | |
5180 | #ifdef HAVE_STDLIB_H | |
5181 | #include <stdlib.h> | |
5182 | #endif | |
5183 | #ifdef HAVE_UNISTD_H | |
5184 | #include <unistd.h> | |
5185 | #endif | |
6be7c12c | 5186 | int main() { |
252b5132 | 5187 | char *(*pfn) = (char *(*)) free |
6be7c12c AO |
5188 | ; return 0; } |
5189 | EOF | |
c6f8758f | 5190 | if { (eval echo configure:5191: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
6be7c12c | 5191 | rm -rf conftest* |
252b5132 RH |
5192 | bfd_cv_decl_needed_free=no |
5193 | else | |
6be7c12c AO |
5194 | echo "configure: failed program was:" >&5 |
5195 | cat conftest.$ac_ext >&5 | |
5196 | rm -rf conftest* | |
5197 | bfd_cv_decl_needed_free=yes | |
252b5132 | 5198 | fi |
6be7c12c | 5199 | rm -f conftest* |
252b5132 RH |
5200 | fi |
5201 | ||
6be7c12c | 5202 | echo "$ac_t""$bfd_cv_decl_needed_free" 1>&6 |
252b5132 | 5203 | if test $bfd_cv_decl_needed_free = yes; then |
6be7c12c | 5204 | cat >> confdefs.h <<\EOF |
252b5132 RH |
5205 | #define NEED_DECLARATION_FREE 1 |
5206 | EOF | |
5207 | ||
5208 | fi | |
5209 | ||
6be7c12c | 5210 | echo $ac_n "checking whether getenv must be declared""... $ac_c" 1>&6 |
c6f8758f | 5211 | echo "configure:5212: checking whether getenv must be declared" >&5 |
6be7c12c AO |
5212 | if eval "test \"`echo '$''{'bfd_cv_decl_needed_getenv'+set}'`\" = set"; then |
5213 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 5214 | else |
6be7c12c | 5215 | cat > conftest.$ac_ext <<EOF |
c6f8758f | 5216 | #line 5217 "configure" |
252b5132 RH |
5217 | #include "confdefs.h" |
5218 | ||
5219 | #include <stdio.h> | |
5220 | #ifdef HAVE_STRING_H | |
5221 | #include <string.h> | |
5222 | #else | |
5223 | #ifdef HAVE_STRINGS_H | |
5224 | #include <strings.h> | |
5225 | #endif | |
5226 | #endif | |
5227 | #ifdef HAVE_STDLIB_H | |
5228 | #include <stdlib.h> | |
5229 | #endif | |
5230 | #ifdef HAVE_UNISTD_H | |
5231 | #include <unistd.h> | |
5232 | #endif | |
6be7c12c | 5233 | int main() { |
252b5132 | 5234 | char *(*pfn) = (char *(*)) getenv |
6be7c12c AO |
5235 | ; return 0; } |
5236 | EOF | |
c6f8758f | 5237 | if { (eval echo configure:5238: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
6be7c12c | 5238 | rm -rf conftest* |
252b5132 RH |
5239 | bfd_cv_decl_needed_getenv=no |
5240 | else | |
6be7c12c AO |
5241 | echo "configure: failed program was:" >&5 |
5242 | cat conftest.$ac_ext >&5 | |
5243 | rm -rf conftest* | |
5244 | bfd_cv_decl_needed_getenv=yes | |
252b5132 | 5245 | fi |
6be7c12c | 5246 | rm -f conftest* |
252b5132 RH |
5247 | fi |
5248 | ||
6be7c12c | 5249 | echo "$ac_t""$bfd_cv_decl_needed_getenv" 1>&6 |
252b5132 | 5250 | if test $bfd_cv_decl_needed_getenv = yes; then |
6be7c12c | 5251 | cat >> confdefs.h <<\EOF |
252b5132 RH |
5252 | #define NEED_DECLARATION_GETENV 1 |
5253 | EOF | |
5254 | ||
5255 | fi | |
5256 | ||
6be7c12c | 5257 | |
252b5132 RH |
5258 | # If we are configured native, pick a core file support file. |
5259 | COREFILE= | |
5260 | COREFLAG= | |
5261 | TRAD_HEADER= | |
5262 | if test "${target}" = "${host}"; then | |
5263 | case "${host}" in | |
13dfd2d0 | 5264 | alpha*-*-freebsd* | alpha*-*-kfreebsd*-gnu) |
46d59bfa DB |
5265 | COREFILE='' |
5266 | ;; | |
252b5132 RH |
5267 | alpha*-*-linux-gnu*) |
5268 | COREFILE=trad-core.lo | |
5269 | TRAD_HEADER='"hosts/alphalinux.h"' | |
5270 | ;; | |
690cc98b NC |
5271 | alpha*-*-netbsd* | alpha*-*-openbsd*) |
5272 | COREFILE=netbsd-core.lo | |
5273 | ;; | |
252b5132 | 5274 | alpha*-*-*) COREFILE=osf-core.lo ;; |
13dfd2d0 NC |
5275 | arm-*-freebsd* | arm-*-kfreebsd*-gnu) |
5276 | COREFILE='' ;; | |
61d0bc33 | 5277 | arm-*-netbsd*) COREFILE=netbsd-core.lo ;; |
252b5132 RH |
5278 | arm-*-riscix) COREFILE=trad-core.lo ;; |
5279 | hppa*-*-hpux*) COREFILE=hpux-core.lo ;; | |
5280 | hppa*-*-hiux*) COREFILE=hpux-core.lo ;; | |
5281 | hppa*-*-mpeix*) COREFILE=hpux-core.lo ;; | |
5282 | hppa*-*-bsd*) COREFILE="hpux-core.lo hppabsd-core.lo" | |
5283 | COREFLAG="-DHPUX_CORE -DHPPABSD_CORE" ;; | |
eef0f186 MK |
5284 | hppa*-*-netbsd* | hppa*-*-openbsd*) |
5285 | COREFILE=netbsd-core.lo | |
5286 | ;; | |
5287 | ||
dc810e39 | 5288 | i370-*-*) |
5b93d8bb AM |
5289 | COREFILE=trad-core.lo |
5290 | TRAD_HEADER='"hosts/i370linux.h"' | |
5291 | ;; | |
5292 | ||
80c7c40a | 5293 | i[3-7]86-sequent-bsd*) |
5b93d8bb | 5294 | COREFILE=trad-core.lo |
252b5132 RH |
5295 | TRAD_HEADER='"hosts/symmetry.h"' |
5296 | ;; | |
80c7c40a NC |
5297 | i[3-7]86-sequent-sysv4*) ;; |
5298 | i[3-7]86-sequent-sysv*) | |
252b5132 RH |
5299 | COREFILE=trad-core.lo |
5300 | TRAD_HEADER='"hosts/symmetry.h"' | |
5301 | ;; | |
80c7c40a | 5302 | i[3-7]86-*-bsdi) |
7e3b3466 NC |
5303 | COREFILE= |
5304 | ;; | |
d2bef492 | 5305 | i[3-7]86-*-bsd* | i[3-7]86-*-freebsd[123] | i[3-7]86-*-freebsd[123]\.* | i[3-7]86-*-freebsd4\.[01234] | i[3-7]86-*-freebsd4\.[01234]\.* | i[3-7]86-*-freebsd*aout*) |
252b5132 RH |
5306 | COREFILE=trad-core.lo |
5307 | TRAD_HEADER='"hosts/i386bsd.h"' | |
5308 | ;; | |
13dfd2d0 | 5309 | i[3-7]86-*-freebsd* | i[3-7]86-*-kfreebsd*-gnu) |
d4af9775 DB |
5310 | COREFILE='' |
5311 | TRAD_HEADER='"hosts/i386bsd.h"' | |
5312 | ;; | |
4615568e | 5313 | i[3-7]86-*-netbsd* | i[3-7]86-*-knetbsd*-gnu | i[3-7]86-*-openbsd*) |
252b5132 RH |
5314 | COREFILE=netbsd-core.lo |
5315 | ;; | |
80c7c40a | 5316 | i[3-7]86-esix-sysv3*) |
252b5132 RH |
5317 | COREFILE=trad-core.lo |
5318 | TRAD_HEADER='"hosts/esix.h"' | |
5319 | ;; | |
80c7c40a | 5320 | i[3-7]86-*-sco3.2v5*) |
252b5132 RH |
5321 | COREFILE=sco5-core.lo |
5322 | ;; | |
80c7c40a | 5323 | i[3-7]86-*-sco* | i[3-7]86-*-isc*) |
252b5132 RH |
5324 | COREFILE=trad-core.lo |
5325 | TRAD_HEADER='"hosts/i386sco.h"' | |
5326 | ;; | |
80c7c40a | 5327 | i[3-7]86-*-mach3*) |
252b5132 RH |
5328 | COREFILE=trad-core.lo |
5329 | TRAD_HEADER='"hosts/i386mach3.h"' | |
5330 | ;; | |
80c7c40a | 5331 | i[3-7]86-*-linux-gnu*) |
252b5132 RH |
5332 | COREFILE=trad-core.lo |
5333 | TRAD_HEADER='"hosts/i386linux.h"' | |
5334 | ;; | |
80c7c40a NC |
5335 | i[3-7]86-*-isc*) COREFILE=trad-core.lo ;; |
5336 | i[3-7]86-*-aix*) COREFILE=aix386-core.lo ;; | |
252b5132 RH |
5337 | i860-*-mach3* | i860-*-osf1*) |
5338 | COREFILE=trad-core.lo | |
5339 | TRAD_HEADER='"hosts/i860mach3.h"' | |
5340 | ;; | |
252b5132 RH |
5341 | mips-*-netbsd* | mips*-*-openbsd*) |
5342 | COREFILE=netbsd-core.lo | |
5343 | ;; | |
5344 | mips-dec-*) | |
5345 | COREFILE=trad-core.lo | |
5346 | TRAD_HEADER='"hosts/decstation.h"' | |
5347 | ;; | |
5348 | mips-sgi-irix4*) COREFILE=irix-core.lo ;; | |
5349 | mips-sgi-irix5*) COREFILE=irix-core.lo ;; | |
5350 | mips-sgi-irix6*) COREFILE=irix-core.lo ;; | |
252b5132 RH |
5351 | mips-*-sysv4*) ;; |
5352 | mips-*-sysv* | mips-*-riscos*) | |
5353 | COREFILE=trad-core.lo | |
5354 | TRAD_HEADER='"hosts/riscos.h"' | |
5355 | ;; | |
5356 | mips-sony-bsd*) | |
5357 | COREFILE=trad-core.lo | |
5358 | TRAD_HEADER='"hosts/news-mips.h"' | |
5359 | ;; | |
5360 | m68*-bull*-sysv*) | |
5361 | COREFILE=trad-core.lo | |
5362 | TRAD_HEADER='"hosts/dpx2.h"' | |
5363 | ;; | |
5364 | m68*-hp-hpux*) COREFILE=hpux-core.lo ;; | |
5365 | m68*-hp-bsd*) | |
5366 | COREFILE=trad-core.lo | |
5367 | TRAD_HEADER='"hosts/hp300bsd.h"' | |
5368 | ;; | |
5369 | m68*-*-linux-gnu*) | |
5370 | COREFILE=trad-core.lo | |
5371 | TRAD_HEADER='"hosts/m68klinux.h"' | |
5372 | ;; | |
5373 | m68*-motorola-sysv*) | |
5374 | COREFILE=trad-core.lo | |
5375 | TRAD_HEADER='"hosts/delta68.h"' | |
5376 | ;; | |
5377 | m68*-sony-*) | |
5378 | COREFILE=trad-core.lo | |
5379 | TRAD_HEADER='"hosts/news.h"' | |
5380 | ;; | |
5381 | m68*-*-netbsd* | m68*-*-openbsd*) | |
5382 | COREFILE=netbsd-core.lo | |
5383 | ;; | |
5384 | m68*-apple-aux*) | |
5385 | COREFILE=trad-core.lo | |
5386 | TRAD_HEADER='"hosts/m68kaux.h"' | |
5387 | ;; | |
eb1e0e80 NC |
5388 | m88*-*-sysv4*) |
5389 | ;; | |
5390 | m88*-motorola-sysv*) | |
5391 | COREFILE=ptrace-core.lo | |
5392 | ;; | |
252b5132 RH |
5393 | m88*-*-mach3*) |
5394 | COREFILE=trad-core.lo | |
5395 | TRAD_HEADER='"hosts/m88kmach3.h"' | |
5396 | ;; | |
c6f8758f NC |
5397 | m88*-*-openbsd*) |
5398 | COREFILE=netbsd-core.lo | |
5399 | ;; | |
252b5132 RH |
5400 | ns32k-pc532-mach) |
5401 | COREFILE=trad-core.lo | |
5402 | TRAD_HEADER='"hosts/pc532mach.h"' | |
5403 | ;; | |
5404 | ns32k-*-netbsd* | ns32k-*-openbsd*) | |
5405 | COREFILE=netbsd-core.lo | |
5406 | ;; | |
eb1e0e80 NC |
5407 | rs6000-*-lynx*) |
5408 | COREFILE=lynx-core.lo | |
5409 | ;; | |
5410 | rs6000-*-aix5.* | powerpc-*-aix5.*) | |
5411 | COREFILE=rs6000-core.lo | |
5412 | COREFLAG="$COREFLAG -DAIX_5_CORE -DAIX_CORE_DUMPX_CORE" | |
5413 | ;; | |
83954261 | 5414 | rs6000-*-aix4.[3-9]* | powerpc-*-aix4.[3-9]*) |
653f71ca KB |
5415 | COREFILE=rs6000-core.lo |
5416 | COREFLAG="$COREFLAG -DAIX_CORE_DUMPX_CORE" | |
83954261 AM |
5417 | # Not all versions of AIX with -DAIX_CORE_DUMPX_CORE |
5418 | # have c_impl as a member of struct core_dumpx | |
5419 | echo $ac_n "checking for c_impl in struct core_dumpx""... $ac_c" 1>&6 | |
eef0f186 | 5420 | echo "configure:5421: checking for c_impl in struct core_dumpx" >&5 |
83954261 | 5421 | cat > conftest.$ac_ext <<EOF |
eef0f186 | 5422 | #line 5423 "configure" |
83954261 AM |
5423 | #include "confdefs.h" |
5424 | #include <core.h> | |
5425 | int main() { | |
5426 | struct core_dumpx c; c.c_impl = 0; | |
5427 | ; return 0; } | |
5428 | EOF | |
eef0f186 | 5429 | if { (eval echo configure:5430: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
83954261 AM |
5430 | rm -rf conftest* |
5431 | cat >> confdefs.h <<\EOF | |
5432 | #define HAVE_ST_C_IMPL 1 | |
5433 | EOF | |
5434 | ||
5435 | echo "$ac_t""yes" 1>&6 | |
5436 | else | |
5437 | echo "configure: failed program was:" >&5 | |
5438 | cat conftest.$ac_ext >&5 | |
5439 | rm -rf conftest* | |
5440 | echo "$ac_t""no" 1>&6 | |
5441 | fi | |
5442 | rm -f conftest* | |
653f71ca | 5443 | ;; |
252b5132 RH |
5444 | rs6000-*-aix4*) COREFILE=rs6000-core.lo ;; |
5445 | rs6000-*-*) COREFILE=rs6000-core.lo ;; | |
252b5132 RH |
5446 | powerpc-*-aix4*) COREFILE=rs6000-core.lo ;; |
5447 | powerpc-*-aix*) COREFILE=rs6000-core.lo ;; | |
5448 | powerpc-*-beos*) ;; | |
13dfd2d0 NC |
5449 | powerpc-*-freebsd* | powerpc-*-kfreebsd*-gnu) |
5450 | COREFILE='' ;; | |
252b5132 | 5451 | powerpc-*-netbsd*) COREFILE=netbsd-core.lo ;; |
d4af9775 | 5452 | powerpc-*-*bsd*) COREFILE=netbsd-core.lo ;; |
dc810e39 | 5453 | s390*-*-*) COREFILE=trad-core.lo ;; |
8d05742f | 5454 | sh*-*-netbsd*) COREFILE=netbsd-core.lo ;; |
a9bf1154 | 5455 | sparc-*-netbsd* | sparc*-*-openbsd*) |
252b5132 RH |
5456 | COREFILE=netbsd-core.lo |
5457 | ;; | |
5458 | tahoe-*-*) | |
5459 | COREFILE=trad-core.lo | |
5460 | TRAD_HEADER='"hosts/tahoe.h"' | |
5461 | ;; | |
de6e5e1a NC |
5462 | vax-*-netbsd* | vax-*-openbsd*) |
5463 | COREFILE=netbsd-core.lo | |
5464 | ;; | |
252b5132 RH |
5465 | vax-*-ultrix2*) |
5466 | COREFILE=trad-core.lo | |
5467 | TRAD_HEADER='"hosts/vaxult2.h"' | |
5468 | ;; | |
5469 | vax-*-ultrix*) | |
5470 | COREFILE=trad-core.lo | |
5471 | TRAD_HEADER='"hosts/vaxult2.h"' | |
5472 | ;; | |
f8fc3443 NC |
5473 | vax-*-linux-gnu*) |
5474 | COREFILE=trad-core.lo | |
5475 | TRAD_HEADER='"hosts/vaxlinux.h"' | |
5476 | ;; | |
252b5132 RH |
5477 | vax-*-*) |
5478 | COREFILE=trad-core.lo | |
5479 | TRAD_HEADER='"hosts/vaxbsd.h"' | |
5480 | ;; | |
85cfd8d3 MK |
5481 | x86_64-*-netbsd* | x86_64-*-openbsd*) |
5482 | COREFILE=netbsd-core.lo | |
5483 | ;; | |
252b5132 RH |
5484 | esac |
5485 | ||
5486 | case "$COREFILE" in | |
5487 | aix386-core.lo) COREFLAG=-DAIX386_CORE ;; | |
5488 | hppabsd-core.lo) COREFLAG=-DHPPABSD_CORE ;; | |
5489 | hpux-core.lo) COREFLAG=-DHPUX_CORE ;; | |
5490 | irix-core.lo) COREFLAG=-DIRIX_CORE ;; | |
5491 | lynx-core.lo) COREFLAG=-DLYNX_CORE ;; | |
5492 | netbsd-core.lo) COREFLAG=-DNETBSD_CORE ;; | |
5493 | osf-core.lo) COREFLAG=-DOSF_CORE ;; | |
5494 | ptrace-core.lo) COREFLAG=-DPTRACE_CORE ;; | |
5495 | rs6000-core.lo) COREFLAG="$COREFLAG -DAIX_CORE" ;; | |
5496 | sco5-core.lo) COREFLAG="$COREFLAG -DSCO5_CORE" ;; | |
5497 | trad-core.lo) COREFLAG="$COREFLAG -DTRAD_CORE" ;; | |
5498 | esac | |
5499 | ||
5500 | # ELF corefile support has several flavors, but all of | |
5501 | # them use something called <sys/procfs.h> | |
6be7c12c | 5502 | for ac_hdr in sys/procfs.h |
252b5132 | 5503 | do |
6be7c12c AO |
5504 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` |
5505 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 | |
eef0f186 | 5506 | echo "configure:5507: checking for $ac_hdr" >&5 |
6be7c12c AO |
5507 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
5508 | echo $ac_n "(cached) $ac_c" 1>&6 | |
5509 | else | |
5510 | cat > conftest.$ac_ext <<EOF | |
eef0f186 | 5511 | #line 5512 "configure" |
252b5132 | 5512 | #include "confdefs.h" |
6be7c12c AO |
5513 | #include <$ac_hdr> |
5514 | EOF | |
5515 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
eef0f186 | 5516 | { (eval echo configure:5517: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
6be7c12c AO |
5517 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
5518 | if test -z "$ac_err"; then | |
5519 | rm -rf conftest* | |
5520 | eval "ac_cv_header_$ac_safe=yes" | |
252b5132 | 5521 | else |
6be7c12c AO |
5522 | echo "$ac_err" >&5 |
5523 | echo "configure: failed program was:" >&5 | |
252b5132 | 5524 | cat conftest.$ac_ext >&5 |
6be7c12c AO |
5525 | rm -rf conftest* |
5526 | eval "ac_cv_header_$ac_safe=no" | |
252b5132 | 5527 | fi |
6be7c12c | 5528 | rm -f conftest* |
252b5132 | 5529 | fi |
6be7c12c AO |
5530 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
5531 | echo "$ac_t""yes" 1>&6 | |
5532 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` | |
5533 | cat >> confdefs.h <<EOF | |
5534 | #define $ac_tr_hdr 1 | |
252b5132 | 5535 | EOF |
6be7c12c AO |
5536 | |
5537 | else | |
5538 | echo "$ac_t""no" 1>&6 | |
252b5132 RH |
5539 | fi |
5540 | done | |
5541 | ||
5542 | if test "$ac_cv_header_sys_procfs_h" = yes; then | |
6be7c12c | 5543 | echo $ac_n "checking for prstatus_t in sys/procfs.h""... $ac_c" 1>&6 |
eef0f186 | 5544 | echo "configure:5545: checking for prstatus_t in sys/procfs.h" >&5 |
6be7c12c AO |
5545 | if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prstatus_t'+set}'`\" = set"; then |
5546 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 5547 | else |
6be7c12c | 5548 | cat > conftest.$ac_ext <<EOF |
eef0f186 | 5549 | #line 5550 "configure" |
252b5132 | 5550 | #include "confdefs.h" |
7ee38065 MS |
5551 | |
5552 | #define _SYSCALL32 | |
252b5132 | 5553 | #include <sys/procfs.h> |
6be7c12c | 5554 | int main() { |
252b5132 | 5555 | prstatus_t avar |
6be7c12c AO |
5556 | ; return 0; } |
5557 | EOF | |
eef0f186 | 5558 | if { (eval echo configure:5559: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
6be7c12c | 5559 | rm -rf conftest* |
252b5132 RH |
5560 | bfd_cv_have_sys_procfs_type_prstatus_t=yes |
5561 | else | |
6be7c12c AO |
5562 | echo "configure: failed program was:" >&5 |
5563 | cat conftest.$ac_ext >&5 | |
5564 | rm -rf conftest* | |
5565 | bfd_cv_have_sys_procfs_type_prstatus_t=no | |
5566 | ||
252b5132 | 5567 | fi |
6be7c12c | 5568 | rm -f conftest* |
252b5132 RH |
5569 | fi |
5570 | ||
5571 | if test $bfd_cv_have_sys_procfs_type_prstatus_t = yes; then | |
6be7c12c | 5572 | cat >> confdefs.h <<\EOF |
252b5132 RH |
5573 | #define HAVE_PRSTATUS_T 1 |
5574 | EOF | |
5575 | ||
5576 | fi | |
6be7c12c | 5577 | echo "$ac_t""$bfd_cv_have_sys_procfs_type_prstatus_t" 1>&6 |
252b5132 | 5578 | |
6be7c12c | 5579 | echo $ac_n "checking for prstatus32_t in sys/procfs.h""... $ac_c" 1>&6 |
eef0f186 | 5580 | echo "configure:5581: checking for prstatus32_t in sys/procfs.h" >&5 |
6be7c12c AO |
5581 | if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prstatus32_t'+set}'`\" = set"; then |
5582 | echo $ac_n "(cached) $ac_c" 1>&6 | |
7ee38065 | 5583 | else |
6be7c12c | 5584 | cat > conftest.$ac_ext <<EOF |
eef0f186 | 5585 | #line 5586 "configure" |
7ee38065 MS |
5586 | #include "confdefs.h" |
5587 | ||
5588 | #define _SYSCALL32 | |
5589 | #include <sys/procfs.h> | |
6be7c12c | 5590 | int main() { |
7ee38065 | 5591 | prstatus32_t avar |
6be7c12c AO |
5592 | ; return 0; } |
5593 | EOF | |
eef0f186 | 5594 | if { (eval echo configure:5595: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
6be7c12c | 5595 | rm -rf conftest* |
7ee38065 MS |
5596 | bfd_cv_have_sys_procfs_type_prstatus32_t=yes |
5597 | else | |
6be7c12c AO |
5598 | echo "configure: failed program was:" >&5 |
5599 | cat conftest.$ac_ext >&5 | |
5600 | rm -rf conftest* | |
5601 | bfd_cv_have_sys_procfs_type_prstatus32_t=no | |
5602 | ||
7ee38065 | 5603 | fi |
6be7c12c | 5604 | rm -f conftest* |
7ee38065 MS |
5605 | fi |
5606 | ||
5607 | if test $bfd_cv_have_sys_procfs_type_prstatus32_t = yes; then | |
6be7c12c | 5608 | cat >> confdefs.h <<\EOF |
7ee38065 MS |
5609 | #define HAVE_PRSTATUS32_T 1 |
5610 | EOF | |
5611 | ||
5612 | fi | |
6be7c12c | 5613 | echo "$ac_t""$bfd_cv_have_sys_procfs_type_prstatus32_t" 1>&6 |
7ee38065 | 5614 | |
6be7c12c | 5615 | echo $ac_n "checking for prstatus_t.pr_who in sys/procfs.h""... $ac_c" 1>&6 |
eef0f186 | 5616 | echo "configure:5617: checking for prstatus_t.pr_who in sys/procfs.h" >&5 |
6be7c12c AO |
5617 | if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_member_prstatus_t_pr_who'+set}'`\" = set"; then |
5618 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 5619 | else |
6be7c12c | 5620 | cat > conftest.$ac_ext <<EOF |
eef0f186 | 5621 | #line 5622 "configure" |
252b5132 | 5622 | #include "confdefs.h" |
7ee38065 MS |
5623 | |
5624 | #define _SYSCALL32 | |
252b5132 | 5625 | #include <sys/procfs.h> |
6be7c12c | 5626 | int main() { |
252b5132 | 5627 | prstatus_t avar; void* aref = (void*) &avar.pr_who |
6be7c12c AO |
5628 | ; return 0; } |
5629 | EOF | |
eef0f186 | 5630 | if { (eval echo configure:5631: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
6be7c12c | 5631 | rm -rf conftest* |
252b5132 RH |
5632 | bfd_cv_have_sys_procfs_type_member_prstatus_t_pr_who=yes |
5633 | else | |
6be7c12c AO |
5634 | echo "configure: failed program was:" >&5 |
5635 | cat conftest.$ac_ext >&5 | |
5636 | rm -rf conftest* | |
5637 | bfd_cv_have_sys_procfs_type_member_prstatus_t_pr_who=no | |
5638 | ||
252b5132 | 5639 | fi |
6be7c12c | 5640 | rm -f conftest* |
252b5132 RH |
5641 | fi |
5642 | ||
5643 | if test $bfd_cv_have_sys_procfs_type_member_prstatus_t_pr_who = yes; then | |
6be7c12c | 5644 | cat >> confdefs.h <<\EOF |
252b5132 RH |
5645 | #define HAVE_PRSTATUS_T_PR_WHO 1 |
5646 | EOF | |
5647 | ||
5648 | fi | |
6be7c12c | 5649 | echo "$ac_t""$bfd_cv_have_sys_procfs_type_member_prstatus_t_pr_who" 1>&6 |
252b5132 | 5650 | |
6be7c12c | 5651 | echo $ac_n "checking for prstatus32_t.pr_who in sys/procfs.h""... $ac_c" 1>&6 |
eef0f186 | 5652 | echo "configure:5653: checking for prstatus32_t.pr_who in sys/procfs.h" >&5 |
6be7c12c AO |
5653 | if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_member_prstatus32_t_pr_who'+set}'`\" = set"; then |
5654 | echo $ac_n "(cached) $ac_c" 1>&6 | |
7ee38065 | 5655 | else |
6be7c12c | 5656 | cat > conftest.$ac_ext <<EOF |
eef0f186 | 5657 | #line 5658 "configure" |
7ee38065 MS |
5658 | #include "confdefs.h" |
5659 | ||
5660 | #define _SYSCALL32 | |
5661 | #include <sys/procfs.h> | |
6be7c12c | 5662 | int main() { |
7ee38065 | 5663 | prstatus32_t avar; void* aref = (void*) &avar.pr_who |
6be7c12c AO |
5664 | ; return 0; } |
5665 | EOF | |
eef0f186 | 5666 | if { (eval echo configure:5667: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
6be7c12c | 5667 | rm -rf conftest* |
7ee38065 MS |
5668 | bfd_cv_have_sys_procfs_type_member_prstatus32_t_pr_who=yes |
5669 | else | |
6be7c12c AO |
5670 | echo "configure: failed program was:" >&5 |
5671 | cat conftest.$ac_ext >&5 | |
5672 | rm -rf conftest* | |
5673 | bfd_cv_have_sys_procfs_type_member_prstatus32_t_pr_who=no | |
5674 | ||
7ee38065 | 5675 | fi |
6be7c12c | 5676 | rm -f conftest* |
7ee38065 MS |
5677 | fi |
5678 | ||
5679 | if test $bfd_cv_have_sys_procfs_type_member_prstatus32_t_pr_who = yes; then | |
6be7c12c | 5680 | cat >> confdefs.h <<\EOF |
7ee38065 MS |
5681 | #define HAVE_PRSTATUS32_T_PR_WHO 1 |
5682 | EOF | |
5683 | ||
5684 | fi | |
6be7c12c | 5685 | echo "$ac_t""$bfd_cv_have_sys_procfs_type_member_prstatus32_t_pr_who" 1>&6 |
7ee38065 | 5686 | |
6be7c12c | 5687 | echo $ac_n "checking for pstatus_t in sys/procfs.h""... $ac_c" 1>&6 |
eef0f186 | 5688 | echo "configure:5689: checking for pstatus_t in sys/procfs.h" >&5 |
6be7c12c AO |
5689 | if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_pstatus_t'+set}'`\" = set"; then |
5690 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 5691 | else |
6be7c12c | 5692 | cat > conftest.$ac_ext <<EOF |
eef0f186 | 5693 | #line 5694 "configure" |
252b5132 | 5694 | #include "confdefs.h" |
7ee38065 MS |
5695 | |
5696 | #define _SYSCALL32 | |
252b5132 | 5697 | #include <sys/procfs.h> |
6be7c12c | 5698 | int main() { |
252b5132 | 5699 | pstatus_t avar |
6be7c12c AO |
5700 | ; return 0; } |
5701 | EOF | |
eef0f186 | 5702 | if { (eval echo configure:5703: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
6be7c12c | 5703 | rm -rf conftest* |
252b5132 RH |
5704 | bfd_cv_have_sys_procfs_type_pstatus_t=yes |
5705 | else | |
6be7c12c AO |
5706 | echo "configure: failed program was:" >&5 |
5707 | cat conftest.$ac_ext >&5 | |
5708 | rm -rf conftest* | |
5709 | bfd_cv_have_sys_procfs_type_pstatus_t=no | |
5710 | ||
252b5132 | 5711 | fi |
6be7c12c | 5712 | rm -f conftest* |
252b5132 RH |
5713 | fi |
5714 | ||
5715 | if test $bfd_cv_have_sys_procfs_type_pstatus_t = yes; then | |
6be7c12c | 5716 | cat >> confdefs.h <<\EOF |
252b5132 RH |
5717 | #define HAVE_PSTATUS_T 1 |
5718 | EOF | |
5719 | ||
5720 | fi | |
6be7c12c | 5721 | echo "$ac_t""$bfd_cv_have_sys_procfs_type_pstatus_t" 1>&6 |
252b5132 | 5722 | |
6be7c12c | 5723 | echo $ac_n "checking for pxstatus_t in sys/procfs.h""... $ac_c" 1>&6 |
eef0f186 | 5724 | echo "configure:5725: checking for pxstatus_t in sys/procfs.h" >&5 |
6be7c12c AO |
5725 | if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_pxstatus_t'+set}'`\" = set"; then |
5726 | echo $ac_n "(cached) $ac_c" 1>&6 | |
f572a39d | 5727 | else |
6be7c12c | 5728 | cat > conftest.$ac_ext <<EOF |
eef0f186 | 5729 | #line 5730 "configure" |
f572a39d AM |
5730 | #include "confdefs.h" |
5731 | ||
5732 | #define _SYSCALL32 | |
5733 | #include <sys/procfs.h> | |
6be7c12c | 5734 | int main() { |
f572a39d | 5735 | pxstatus_t avar |
6be7c12c AO |
5736 | ; return 0; } |
5737 | EOF | |
eef0f186 | 5738 | if { (eval echo configure:5739: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
6be7c12c | 5739 | rm -rf conftest* |
f572a39d AM |
5740 | bfd_cv_have_sys_procfs_type_pxstatus_t=yes |
5741 | else | |
6be7c12c AO |
5742 | echo "configure: failed program was:" >&5 |
5743 | cat conftest.$ac_ext >&5 | |
5744 | rm -rf conftest* | |
5745 | bfd_cv_have_sys_procfs_type_pxstatus_t=no | |
5746 | ||
f572a39d | 5747 | fi |
6be7c12c | 5748 | rm -f conftest* |
f572a39d AM |
5749 | fi |
5750 | ||
5751 | if test $bfd_cv_have_sys_procfs_type_pxstatus_t = yes; then | |
6be7c12c | 5752 | cat >> confdefs.h <<\EOF |
f572a39d AM |
5753 | #define HAVE_PXSTATUS_T 1 |
5754 | EOF | |
5755 | ||
5756 | fi | |
6be7c12c | 5757 | echo "$ac_t""$bfd_cv_have_sys_procfs_type_pxstatus_t" 1>&6 |
f572a39d | 5758 | |
6be7c12c | 5759 | echo $ac_n "checking for pstatus32_t in sys/procfs.h""... $ac_c" 1>&6 |
eef0f186 | 5760 | echo "configure:5761: checking for pstatus32_t in sys/procfs.h" >&5 |
6be7c12c AO |
5761 | if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_pstatus32_t'+set}'`\" = set"; then |
5762 | echo $ac_n "(cached) $ac_c" 1>&6 | |
7ee38065 | 5763 | else |
6be7c12c | 5764 | cat > conftest.$ac_ext <<EOF |
eef0f186 | 5765 | #line 5766 "configure" |
7ee38065 MS |
5766 | #include "confdefs.h" |
5767 | ||
5768 | #define _SYSCALL32 | |
5769 | #include <sys/procfs.h> | |
6be7c12c | 5770 | int main() { |
7ee38065 | 5771 | pstatus32_t avar |
6be7c12c AO |
5772 | ; return 0; } |
5773 | EOF | |
eef0f186 | 5774 | if { (eval echo configure:5775: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
6be7c12c | 5775 | rm -rf conftest* |
7ee38065 MS |
5776 | bfd_cv_have_sys_procfs_type_pstatus32_t=yes |
5777 | else | |
6be7c12c AO |
5778 | echo "configure: failed program was:" >&5 |
5779 | cat conftest.$ac_ext >&5 | |
5780 | rm -rf conftest* | |
5781 | bfd_cv_have_sys_procfs_type_pstatus32_t=no | |
5782 | ||
7ee38065 | 5783 | fi |
6be7c12c | 5784 | rm -f conftest* |
7ee38065 MS |
5785 | fi |
5786 | ||
5787 | if test $bfd_cv_have_sys_procfs_type_pstatus32_t = yes; then | |
6be7c12c | 5788 | cat >> confdefs.h <<\EOF |
7ee38065 MS |
5789 | #define HAVE_PSTATUS32_T 1 |
5790 | EOF | |
5791 | ||
5792 | fi | |
6be7c12c | 5793 | echo "$ac_t""$bfd_cv_have_sys_procfs_type_pstatus32_t" 1>&6 |
7ee38065 | 5794 | |
6be7c12c | 5795 | echo $ac_n "checking for prpsinfo_t in sys/procfs.h""... $ac_c" 1>&6 |
eef0f186 | 5796 | echo "configure:5797: checking for prpsinfo_t in sys/procfs.h" >&5 |
6be7c12c AO |
5797 | if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prpsinfo_t'+set}'`\" = set"; then |
5798 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 5799 | else |
6be7c12c | 5800 | cat > conftest.$ac_ext <<EOF |
eef0f186 | 5801 | #line 5802 "configure" |
252b5132 | 5802 | #include "confdefs.h" |
7ee38065 MS |
5803 | |
5804 | #define _SYSCALL32 | |
252b5132 | 5805 | #include <sys/procfs.h> |
6be7c12c | 5806 | int main() { |
252b5132 | 5807 | prpsinfo_t avar |
6be7c12c AO |
5808 | ; return 0; } |
5809 | EOF | |
eef0f186 | 5810 | if { (eval echo configure:5811: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
6be7c12c | 5811 | rm -rf conftest* |
252b5132 RH |
5812 | bfd_cv_have_sys_procfs_type_prpsinfo_t=yes |
5813 | else | |
6be7c12c AO |
5814 | echo "configure: failed program was:" >&5 |
5815 | cat conftest.$ac_ext >&5 | |
5816 | rm -rf conftest* | |
5817 | bfd_cv_have_sys_procfs_type_prpsinfo_t=no | |
5818 | ||
252b5132 | 5819 | fi |
6be7c12c | 5820 | rm -f conftest* |
252b5132 RH |
5821 | fi |
5822 | ||
5823 | if test $bfd_cv_have_sys_procfs_type_prpsinfo_t = yes; then | |
6be7c12c | 5824 | cat >> confdefs.h <<\EOF |
252b5132 RH |
5825 | #define HAVE_PRPSINFO_T 1 |
5826 | EOF | |
5827 | ||
5828 | fi | |
6be7c12c | 5829 | echo "$ac_t""$bfd_cv_have_sys_procfs_type_prpsinfo_t" 1>&6 |
252b5132 | 5830 | |
6be7c12c | 5831 | echo $ac_n "checking for prpsinfo32_t in sys/procfs.h""... $ac_c" 1>&6 |
eef0f186 | 5832 | echo "configure:5833: checking for prpsinfo32_t in sys/procfs.h" >&5 |
6be7c12c AO |
5833 | if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prpsinfo32_t'+set}'`\" = set"; then |
5834 | echo $ac_n "(cached) $ac_c" 1>&6 | |
7ee38065 | 5835 | else |
6be7c12c | 5836 | cat > conftest.$ac_ext <<EOF |
eef0f186 | 5837 | #line 5838 "configure" |
7ee38065 MS |
5838 | #include "confdefs.h" |
5839 | ||
5840 | #define _SYSCALL32 | |
5841 | #include <sys/procfs.h> | |
6be7c12c | 5842 | int main() { |
7ee38065 | 5843 | prpsinfo32_t avar |
6be7c12c AO |
5844 | ; return 0; } |
5845 | EOF | |
eef0f186 | 5846 | if { (eval echo configure:5847: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
6be7c12c | 5847 | rm -rf conftest* |
7ee38065 MS |
5848 | bfd_cv_have_sys_procfs_type_prpsinfo32_t=yes |
5849 | else | |
6be7c12c AO |
5850 | echo "configure: failed program was:" >&5 |
5851 | cat conftest.$ac_ext >&5 | |
5852 | rm -rf conftest* | |
5853 | bfd_cv_have_sys_procfs_type_prpsinfo32_t=no | |
5854 | ||
7ee38065 | 5855 | fi |
6be7c12c | 5856 | rm -f conftest* |
7ee38065 MS |
5857 | fi |
5858 | ||
5859 | if test $bfd_cv_have_sys_procfs_type_prpsinfo32_t = yes; then | |
6be7c12c | 5860 | cat >> confdefs.h <<\EOF |
7ee38065 MS |
5861 | #define HAVE_PRPSINFO32_T 1 |
5862 | EOF | |
5863 | ||
5864 | fi | |
6be7c12c | 5865 | echo "$ac_t""$bfd_cv_have_sys_procfs_type_prpsinfo32_t" 1>&6 |
7ee38065 | 5866 | |
6be7c12c | 5867 | echo $ac_n "checking for psinfo_t in sys/procfs.h""... $ac_c" 1>&6 |
eef0f186 | 5868 | echo "configure:5869: checking for psinfo_t in sys/procfs.h" >&5 |
6be7c12c AO |
5869 | if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_psinfo_t'+set}'`\" = set"; then |
5870 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 5871 | else |
6be7c12c | 5872 | cat > conftest.$ac_ext <<EOF |
eef0f186 | 5873 | #line 5874 "configure" |
252b5132 | 5874 | #include "confdefs.h" |
7ee38065 MS |
5875 | |
5876 | #define _SYSCALL32 | |
252b5132 | 5877 | #include <sys/procfs.h> |
6be7c12c | 5878 | int main() { |
252b5132 | 5879 | psinfo_t avar |
6be7c12c AO |
5880 | ; return 0; } |
5881 | EOF | |
eef0f186 | 5882 | if { (eval echo configure:5883: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
6be7c12c | 5883 | rm -rf conftest* |
252b5132 RH |
5884 | bfd_cv_have_sys_procfs_type_psinfo_t=yes |
5885 | else | |
6be7c12c AO |
5886 | echo "configure: failed program was:" >&5 |
5887 | cat conftest.$ac_ext >&5 | |
5888 | rm -rf conftest* | |
5889 | bfd_cv_have_sys_procfs_type_psinfo_t=no | |
5890 | ||
252b5132 | 5891 | fi |
6be7c12c | 5892 | rm -f conftest* |
252b5132 RH |
5893 | fi |
5894 | ||
5895 | if test $bfd_cv_have_sys_procfs_type_psinfo_t = yes; then | |
6be7c12c | 5896 | cat >> confdefs.h <<\EOF |
252b5132 RH |
5897 | #define HAVE_PSINFO_T 1 |
5898 | EOF | |
5899 | ||
5900 | fi | |
6be7c12c | 5901 | echo "$ac_t""$bfd_cv_have_sys_procfs_type_psinfo_t" 1>&6 |
252b5132 | 5902 | |
6be7c12c | 5903 | echo $ac_n "checking for psinfo32_t in sys/procfs.h""... $ac_c" 1>&6 |
eef0f186 | 5904 | echo "configure:5905: checking for psinfo32_t in sys/procfs.h" >&5 |
6be7c12c AO |
5905 | if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_psinfo32_t'+set}'`\" = set"; then |
5906 | echo $ac_n "(cached) $ac_c" 1>&6 | |
7ee38065 | 5907 | else |
6be7c12c | 5908 | cat > conftest.$ac_ext <<EOF |
eef0f186 | 5909 | #line 5910 "configure" |
7ee38065 MS |
5910 | #include "confdefs.h" |
5911 | ||
5912 | #define _SYSCALL32 | |
5913 | #include <sys/procfs.h> | |
6be7c12c | 5914 | int main() { |
7ee38065 | 5915 | psinfo32_t avar |
6be7c12c AO |
5916 | ; return 0; } |
5917 | EOF | |
eef0f186 | 5918 | if { (eval echo configure:5919: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
6be7c12c | 5919 | rm -rf conftest* |
7ee38065 MS |
5920 | bfd_cv_have_sys_procfs_type_psinfo32_t=yes |
5921 | else | |
6be7c12c AO |
5922 | echo "configure: failed program was:" >&5 |
5923 | cat conftest.$ac_ext >&5 | |
5924 | rm -rf conftest* | |
5925 | bfd_cv_have_sys_procfs_type_psinfo32_t=no | |
5926 | ||
7ee38065 | 5927 | fi |
6be7c12c | 5928 | rm -f conftest* |
7ee38065 MS |
5929 | fi |
5930 | ||
5931 | if test $bfd_cv_have_sys_procfs_type_psinfo32_t = yes; then | |
6be7c12c | 5932 | cat >> confdefs.h <<\EOF |
7ee38065 MS |
5933 | #define HAVE_PSINFO32_T 1 |
5934 | EOF | |
5935 | ||
5936 | fi | |
6be7c12c | 5937 | echo "$ac_t""$bfd_cv_have_sys_procfs_type_psinfo32_t" 1>&6 |
7ee38065 | 5938 | |
6be7c12c | 5939 | echo $ac_n "checking for lwpstatus_t in sys/procfs.h""... $ac_c" 1>&6 |
eef0f186 | 5940 | echo "configure:5941: checking for lwpstatus_t in sys/procfs.h" >&5 |
6be7c12c AO |
5941 | if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_lwpstatus_t'+set}'`\" = set"; then |
5942 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 5943 | else |
6be7c12c | 5944 | cat > conftest.$ac_ext <<EOF |
eef0f186 | 5945 | #line 5946 "configure" |
252b5132 | 5946 | #include "confdefs.h" |
7ee38065 MS |
5947 | |
5948 | #define _SYSCALL32 | |
252b5132 | 5949 | #include <sys/procfs.h> |
6be7c12c | 5950 | int main() { |
252b5132 | 5951 | lwpstatus_t avar |
6be7c12c AO |
5952 | ; return 0; } |
5953 | EOF | |
eef0f186 | 5954 | if { (eval echo configure:5955: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
6be7c12c | 5955 | rm -rf conftest* |
252b5132 RH |
5956 | bfd_cv_have_sys_procfs_type_lwpstatus_t=yes |
5957 | else | |
6be7c12c AO |
5958 | echo "configure: failed program was:" >&5 |
5959 | cat conftest.$ac_ext >&5 | |
5960 | rm -rf conftest* | |
5961 | bfd_cv_have_sys_procfs_type_lwpstatus_t=no | |
5962 | ||
252b5132 | 5963 | fi |
6be7c12c | 5964 | rm -f conftest* |
252b5132 RH |
5965 | fi |
5966 | ||
5967 | if test $bfd_cv_have_sys_procfs_type_lwpstatus_t = yes; then | |
6be7c12c | 5968 | cat >> confdefs.h <<\EOF |
252b5132 RH |
5969 | #define HAVE_LWPSTATUS_T 1 |
5970 | EOF | |
5971 | ||
5972 | fi | |
6be7c12c | 5973 | echo "$ac_t""$bfd_cv_have_sys_procfs_type_lwpstatus_t" 1>&6 |
252b5132 | 5974 | |
6be7c12c | 5975 | echo $ac_n "checking for lwpxstatus_t in sys/procfs.h""... $ac_c" 1>&6 |
eef0f186 | 5976 | echo "configure:5977: checking for lwpxstatus_t in sys/procfs.h" >&5 |
6be7c12c AO |
5977 | if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_lwpxstatus_t'+set}'`\" = set"; then |
5978 | echo $ac_n "(cached) $ac_c" 1>&6 | |
f572a39d | 5979 | else |
6be7c12c | 5980 | cat > conftest.$ac_ext <<EOF |
eef0f186 | 5981 | #line 5982 "configure" |
f572a39d AM |
5982 | #include "confdefs.h" |
5983 | ||
5984 | #define _SYSCALL32 | |
5985 | #include <sys/procfs.h> | |
6be7c12c | 5986 | int main() { |
f572a39d | 5987 | lwpxstatus_t avar |
6be7c12c AO |
5988 | ; return 0; } |
5989 | EOF | |
eef0f186 | 5990 | if { (eval echo configure:5991: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
6be7c12c | 5991 | rm -rf conftest* |
f572a39d AM |
5992 | bfd_cv_have_sys_procfs_type_lwpxstatus_t=yes |
5993 | else | |
6be7c12c AO |
5994 | echo "configure: failed program was:" >&5 |
5995 | cat conftest.$ac_ext >&5 | |
5996 | rm -rf conftest* | |
5997 | bfd_cv_have_sys_procfs_type_lwpxstatus_t=no | |
5998 | ||
f572a39d | 5999 | fi |
6be7c12c | 6000 | rm -f conftest* |
f572a39d AM |
6001 | fi |
6002 | ||
6003 | if test $bfd_cv_have_sys_procfs_type_lwpxstatus_t = yes; then | |
6be7c12c | 6004 | cat >> confdefs.h <<\EOF |
f572a39d AM |
6005 | #define HAVE_LWPXSTATUS_T 1 |
6006 | EOF | |
6007 | ||
6008 | fi | |
6be7c12c | 6009 | echo "$ac_t""$bfd_cv_have_sys_procfs_type_lwpxstatus_t" 1>&6 |
f572a39d | 6010 | |
6be7c12c | 6011 | echo $ac_n "checking for lwpstatus_t.pr_context in sys/procfs.h""... $ac_c" 1>&6 |
eef0f186 | 6012 | echo "configure:6013: checking for lwpstatus_t.pr_context in sys/procfs.h" >&5 |
6be7c12c AO |
6013 | if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_context'+set}'`\" = set"; then |
6014 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 6015 | else |
6be7c12c | 6016 | cat > conftest.$ac_ext <<EOF |
eef0f186 | 6017 | #line 6018 "configure" |
252b5132 | 6018 | #include "confdefs.h" |
7ee38065 MS |
6019 | |
6020 | #define _SYSCALL32 | |
252b5132 | 6021 | #include <sys/procfs.h> |
6be7c12c | 6022 | int main() { |
252b5132 | 6023 | lwpstatus_t avar; void* aref = (void*) &avar.pr_context |
6be7c12c AO |
6024 | ; return 0; } |
6025 | EOF | |
eef0f186 | 6026 | if { (eval echo configure:6027: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
6be7c12c | 6027 | rm -rf conftest* |
252b5132 RH |
6028 | bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_context=yes |
6029 | else | |
6be7c12c AO |
6030 | echo "configure: failed program was:" >&5 |
6031 | cat conftest.$ac_ext >&5 | |
6032 | rm -rf conftest* | |
6033 | bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_context=no | |
6034 | ||
252b5132 | 6035 | fi |
6be7c12c | 6036 | rm -f conftest* |
252b5132 RH |
6037 | fi |
6038 | ||
6039 | if test $bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_context = yes; then | |
6be7c12c | 6040 | cat >> confdefs.h <<\EOF |
252b5132 RH |
6041 | #define HAVE_LWPSTATUS_T_PR_CONTEXT 1 |
6042 | EOF | |
6043 | ||
6044 | fi | |
6be7c12c | 6045 | echo "$ac_t""$bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_context" 1>&6 |
252b5132 | 6046 | |
6be7c12c | 6047 | echo $ac_n "checking for lwpstatus_t.pr_reg in sys/procfs.h""... $ac_c" 1>&6 |
eef0f186 | 6048 | echo "configure:6049: checking for lwpstatus_t.pr_reg in sys/procfs.h" >&5 |
6be7c12c AO |
6049 | if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_reg'+set}'`\" = set"; then |
6050 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 | 6051 | else |
6be7c12c | 6052 | cat > conftest.$ac_ext <<EOF |
eef0f186 | 6053 | #line 6054 "configure" |
252b5132 | 6054 | #include "confdefs.h" |
7ee38065 MS |
6055 | |
6056 | #define _SYSCALL32 | |
252b5132 | 6057 | #include <sys/procfs.h> |
6be7c12c | 6058 | int main() { |
252b5132 | 6059 | lwpstatus_t avar; void* aref = (void*) &avar.pr_reg |
6be7c12c AO |
6060 | ; return 0; } |
6061 | EOF | |
eef0f186 | 6062 | if { (eval echo configure:6063: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
6be7c12c | 6063 | rm -rf conftest* |
252b5132 RH |
6064 | bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_reg=yes |
6065 | else | |
6be7c12c AO |
6066 | echo "configure: failed program was:" >&5 |
6067 | cat conftest.$ac_ext >&5 | |
6068 | rm -rf conftest* | |
6069 | bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_reg=no | |
6070 | ||
252b5132 | 6071 | fi |
6be7c12c | 6072 | rm -f conftest* |
252b5132 RH |
6073 | fi |
6074 | ||
6075 | if test $bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_reg = yes; then | |
6be7c12c | 6076 | cat >> confdefs.h <<\EOF |
252b5132 RH |
6077 | #define HAVE_LWPSTATUS_T_PR_REG 1 |
6078 | EOF | |
6079 | ||
6080 | fi | |
6be7c12c | 6081 | echo "$ac_t""$bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_reg" 1>&6 |
252b5132 | 6082 | |
6be7c12c | 6083 | echo $ac_n "checking for win32_pstatus_t in sys/procfs.h""... $ac_c" 1>&6 |
eef0f186 | 6084 | echo "configure:6085: checking for win32_pstatus_t in sys/procfs.h" >&5 |
6be7c12c AO |
6085 | if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_win32_pstatus_t'+set}'`\" = set"; then |
6086 | echo $ac_n "(cached) $ac_c" 1>&6 | |
e3c976c4 | 6087 | else |
6be7c12c | 6088 | cat > conftest.$ac_ext <<EOF |
eef0f186 | 6089 | #line 6090 "configure" |
e3c976c4 | 6090 | #include "confdefs.h" |
7ee38065 MS |
6091 | |
6092 | #define _SYSCALL32 | |
e3c976c4 | 6093 | #include <sys/procfs.h> |
6be7c12c | 6094 | int main() { |
e3c976c4 | 6095 | win32_pstatus_t avar |
6be7c12c AO |
6096 | ; return 0; } |
6097 | EOF | |
eef0f186 | 6098 | if { (eval echo configure:6099: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
6be7c12c | 6099 | rm -rf conftest* |
e3c976c4 ILT |
6100 | bfd_cv_have_sys_procfs_type_win32_pstatus_t=yes |
6101 | else | |
6be7c12c AO |
6102 | echo "configure: failed program was:" >&5 |
6103 | cat conftest.$ac_ext >&5 | |
6104 | rm -rf conftest* | |
6105 | bfd_cv_have_sys_procfs_type_win32_pstatus_t=no | |
6106 | ||
e3c976c4 | 6107 | fi |
6be7c12c | 6108 | rm -f conftest* |
252b5132 RH |
6109 | fi |
6110 | ||
e3c976c4 | 6111 | if test $bfd_cv_have_sys_procfs_type_win32_pstatus_t = yes; then |
6be7c12c | 6112 | cat >> confdefs.h <<\EOF |
e3c976c4 | 6113 | #define HAVE_WIN32_PSTATUS_T 1 |
16e9c715 NC |
6114 | EOF |
6115 | ||
6116 | fi | |
6be7c12c | 6117 | echo "$ac_t""$bfd_cv_have_sys_procfs_type_win32_pstatus_t" 1>&6 |
e3c976c4 ILT |
6118 | |
6119 | fi | |
6120 | fi | |
16e9c715 | 6121 | |
b3baf5d0 | 6122 | |
6be7c12c AO |
6123 | if test -n "$TRAD_HEADER"; then |
6124 | cat >> confdefs.h <<EOF | |
252b5132 RH |
6125 | #define TRAD_HEADER $TRAD_HEADER |
6126 | EOF | |
6127 | ||
3f9b03b5 | 6128 | fi |
252b5132 RH |
6129 | |
6130 | # Horrible hacks to build DLLs on Windows. | |
6131 | WIN32LDFLAGS= | |
6132 | WIN32LIBADD= | |
6133 | case "${host}" in | |
6134 | *-*-cygwin*) | |
6135 | if test "$enable_shared" = "yes"; then | |
6136 | WIN32LDFLAGS="-no-undefined" | |
6137 | WIN32LIBADD="-L`pwd`/../libiberty -liberty -L`pwd`/../intl -lintl -lcygwin -lkernel32" | |
6138 | fi | |
6139 | ;; | |
78be1d6e | 6140 | *-*-linux*) |
39691762 L |
6141 | # We borrow WIN32LIBADD so that the shared libbfd won't depend on |
6142 | # libiberty.a. | |
ca51bfff L |
6143 | case "${host}" in |
6144 | mips*-*-linux*) | |
6145 | # Linux/MIPS uses PIC by default. | |
6146 | if test "$enable_shared" = "yes"; then | |
6147 | WIN32LIBADD="-L../libiberty -liberty" | |
6148 | fi | |
6149 | ;; | |
6150 | *) | |
66e25bab | 6151 | x=`sed -n -e 's/^[ ]*PICFLAG[ ]*=[ ]*//p' < ../libiberty/Makefile | sed -n '$p'` |
bb2a49f2 | 6152 | if test -n "$x"; then |
ca51bfff L |
6153 | WIN32LIBADD="-L../libiberty/pic -liberty" |
6154 | fi | |
6155 | ;; | |
6156 | esac | |
39691762 | 6157 | ;; |
252b5132 RH |
6158 | esac |
6159 | ||
6be7c12c AO |
6160 | |
6161 | ||
252b5132 RH |
6162 | # target stuff: |
6163 | ||
6164 | # Canonicalize the secondary target names. | |
6165 | if test -n "$enable_targets" ; then | |
6166 | for targ in `echo $enable_targets | sed 's/,/ /g'` | |
6167 | do | |
6d83c84b | 6168 | result=`$ac_config_sub $targ 2>/dev/null` |
252b5132 RH |
6169 | if test -n "$result" ; then |
6170 | canon_targets="$canon_targets $result" | |
6171 | else | |
6172 | # Allow targets that config.sub doesn't recognize, like "all". | |
6173 | canon_targets="$canon_targets $targ" | |
6174 | fi | |
6175 | done | |
6176 | fi | |
6177 | ||
6178 | all_targets=false | |
6179 | defvec= | |
6180 | selvecs= | |
08f74004 | 6181 | assocvecs= |
252b5132 RH |
6182 | selarchs= |
6183 | TDEFINES= | |
6184 | for targ in $target $canon_targets | |
6185 | do | |
6186 | if test "x$targ" = "xall"; then | |
6187 | all_targets=true | |
08f74004 | 6188 | assocvecs="$assocvecs $targ_defvec $targ_selvecs" |
252b5132 RH |
6189 | else |
6190 | . $srcdir/config.bfd | |
6191 | if test "x$targ" = "x$target"; then | |
6192 | defvec=$targ_defvec | |
6193 | fi | |
6194 | selvecs="$selvecs $targ_defvec $targ_selvecs" | |
6195 | selarchs="$selarchs $targ_archs" | |
6196 | TDEFINES="$TDEFINES $targ_cflags" | |
6197 | fi | |
6198 | done | |
6199 | ||
6be7c12c | 6200 | |
252b5132 RH |
6201 | # This processing still needs to be done if we're to decide properly whether |
6202 | # 64-bit support needs to be compiled in. Currently, it will be included if | |
6203 | # the default or any other explicitly requested target requires it; it | |
6204 | # will not be included on a 32-bit host if no 64-bit target is requested, and | |
9eb7245e | 6205 | # no "--with-64-bit-bfd" option is given, even if "--enable-targets=all" is |
252b5132 RH |
6206 | # used. |
6207 | ||
6208 | # uniq the default and selected vectors in all the configured targets. | |
6209 | f="" | |
6210 | for i in $selvecs ; do | |
6211 | case " $f " in | |
6212 | *" $i "*) ;; | |
6213 | *) f="$f $i" ;; | |
6214 | esac | |
6215 | done | |
6216 | selvecs="$f" | |
6217 | ||
6be7c12c | 6218 | |
08f74004 AM |
6219 | # uniq the associated vectors in all the configured targets. |
6220 | f="" | |
6221 | for i in $assocvecs ; do | |
6222 | case " $f " in | |
6223 | *" $i "*) ;; | |
6224 | *) f="$f $i" ;; | |
6225 | esac | |
6226 | done | |
6227 | assocvecs="$f" | |
6228 | ||
6229 | ||
252b5132 RH |
6230 | # uniq the architectures in all the configured targets. |
6231 | f="" | |
6232 | for i in $selarchs ; do | |
6233 | case " $f " in | |
6234 | *" $i "*) ;; | |
6235 | *) f="$f $i" ;; | |
6236 | esac | |
6237 | done | |
6238 | selarchs="$f" | |
6239 | ||
6240 | # Target backend .o files. | |
6241 | tb= | |
6242 | ||
65765700 | 6243 | elf="elf.lo elflink.lo elf-strtab.lo elf-eh-frame.lo dwarf1.lo" |
252b5132 RH |
6244 | |
6245 | for vec in $selvecs | |
6246 | do | |
69263e90 | 6247 | target_size=32 |
252b5132 RH |
6248 | case "$vec" in |
6249 | # This list is alphabetized to make it easy to compare | |
dc810e39 AM |
6250 | # with the two vector lists in targets.c. For the same reason, |
6251 | # use one entry per line, even though this leads to long lines. | |
252b5132 RH |
6252 | a29kcoff_big_vec) tb="$tb coff-a29k.lo cofflink.lo" ;; |
6253 | a_out_adobe_vec) tb="$tb aout-adobe.lo aout32.lo" ;; | |
341ca622 | 6254 | aix5coff64_vec) tb="$tb coff64-rs6000.lo xcofflink.lo aix5ppc-core.lo"; target_size=64 ;; |
252b5132 RH |
6255 | aout0_big_vec) tb="$tb aout0.lo aout32.lo" ;; |
6256 | aout_arm_big_vec) tb="$tb aout-arm.lo aout32.lo" ;; | |
6257 | aout_arm_little_vec) tb="$tb aout-arm.lo aout32.lo" ;; | |
252b5132 | 6258 | apollocoff_vec) tb="$tb coff-apollo.lo" ;; |
dc810e39 AM |
6259 | arm_epoc_pe_big_vec) tb="$tb epoc-pe-arm.lo peigen.lo cofflink.lo " ;; |
6260 | arm_epoc_pe_little_vec) tb="$tb epoc-pe-arm.lo peigen.lo cofflink.lo " ;; | |
6261 | arm_epoc_pei_big_vec) tb="$tb epoc-pei-arm.lo peigen.lo cofflink.lo " ;; | |
6262 | arm_epoc_pei_little_vec) tb="$tb epoc-pei-arm.lo peigen.lo cofflink.lo " ;; | |
6263 | armcoff_big_vec) tb="$tb coff-arm.lo cofflink.lo " ;; | |
6264 | armcoff_little_vec) tb="$tb coff-arm.lo cofflink.lo " ;; | |
6265 | armnetbsd_vec) tb="$tb armnetbsd.lo aout32.lo" ;; | |
6266 | armpe_big_vec) tb="$tb pe-arm.lo peigen.lo cofflink.lo " ;; | |
6267 | armpe_little_vec) tb="$tb pe-arm.lo peigen.lo cofflink.lo " ;; | |
6268 | armpei_big_vec) tb="$tb pei-arm.lo peigen.lo cofflink.lo " ;; | |
6269 | armpei_little_vec) tb="$tb pei-arm.lo peigen.lo cofflink.lo " ;; | |
252b5132 RH |
6270 | b_out_vec_big_host) tb="$tb bout.lo aout32.lo" ;; |
6271 | b_out_vec_little_host) tb="$tb bout.lo aout32.lo" ;; | |
fac41780 | 6272 | bfd_efi_app_ia32_vec) tb="$tb efi-app-ia32.lo peigen.lo cofflink.lo" ;; |
dc810e39 | 6273 | bfd_efi_app_ia64_vec) tb="$tb efi-app-ia64.lo pepigen.lo cofflink.lo"; target_size=64 ;; |
73c3cd1c | 6274 | bfd_elf32_am33lin_vec) tb="$tb elf32-am33lin.lo elf32.lo $elf" ;; |
adde6300 | 6275 | bfd_elf32_avr_vec) tb="$tb elf32-avr.lo elf32.lo $elf" ;; |
dc810e39 | 6276 | bfd_elf32_big_generic_vec) tb="$tb elf32-gen.lo elf32.lo $elf" ;; |
252b5132 | 6277 | bfd_elf32_bigarc_vec) tb="$tb elf32-arc.lo elf32.lo $elf" ;; |
252b5132 | 6278 | bfd_elf32_bigarm_oabi_vec) tb="$tb elfarm-oabi.lo elf32.lo $elf" ;; |
b6821651 | 6279 | bfd_elf32_bigarm_vec) tb="$tb elfarm-nabi.lo elf32.lo $elf" ;; |
c6e90b02 | 6280 | bfd_elf32_bigmips_vec) tb="$tb elf32-mips.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo" ;; |
0949843d | 6281 | bfd_elf32_cr16c_vec) tb="$tb elf32-cr16c.lo elf32.lo $elf" ;; |
06c15ad7 | 6282 | bfd_elf32_cris_vec) tb="$tb elf32-cris.lo elf32.lo $elf" ;; |
252b5132 RH |
6283 | bfd_elf32_d10v_vec) tb="$tb elf32-d10v.lo elf32.lo $elf" ;; |
6284 | bfd_elf32_d30v_vec) tb="$tb elf32-d30v.lo elf32.lo $elf" ;; | |
d172d4ba | 6285 | bfd_elf32_dlx_big_vec) tb="$tb elf32-dlx.lo elf32.lo $elf" ;; |
252b5132 | 6286 | bfd_elf32_fr30_vec) tb="$tb elf32-fr30.lo elf32.lo $elf" ;; |
4e5ba5b7 | 6287 | bfd_elf32_frv_vec) tb="$tb elf32-frv.lo elf32.lo $elf" ;; |
43850d5b | 6288 | bfd_elf32_frvfdpic_vec) tb="$tb elf32-frv.lo elf32.lo $elf" ;; |
e01b0e69 | 6289 | bfd_elf32_h8300_vec) tb="$tb elf32-h8300.lo elf32.lo $elf" ;; |
dc810e39 AM |
6290 | bfd_elf32_hppa_linux_vec) tb="$tb elf32-hppa.lo elf32.lo $elf" ;; |
6291 | bfd_elf32_hppa_vec) tb="$tb elf32-hppa.lo elf32.lo $elf" ;; | |
5b93d8bb | 6292 | bfd_elf32_i370_vec) tb="$tb elf32-i370.lo elf32.lo $elf" ;; |
b6821651 AM |
6293 | bfd_elf32_i386_freebsd_vec) tb="$tb elf32-i386.lo elf32.lo $elf" ;; |
6294 | bfd_elf32_i386_vec) tb="$tb elf32-i386.lo elf32.lo $elf" ;; | |
9d751335 | 6295 | bfd_elf32_i860_little_vec) tb="$tb elf32-i860.lo elf32.lo $elf" ;; |
dc810e39 | 6296 | bfd_elf32_i860_vec) tb="$tb elf32-i860.lo elf32.lo $elf" ;; |
b2ef150d | 6297 | bfd_elf32_i960_vec) tb="$tb elf32-i960.lo elf32.lo $elf" ;; |
dc810e39 | 6298 | bfd_elf32_ia64_big_vec) tb="$tb elf32-ia64.lo elf32.lo $elf" ;; |
fcf12726 | 6299 | bfd_elf32_ia64_hpux_big_vec) tb="$tb elf32-ia64.lo elf32.lo $elf";; |
cf88bb9f | 6300 | bfd_elf32_ip2k_vec) tb="$tb elf32-ip2k.lo elf32.lo $elf" ;; |
a75473eb | 6301 | bfd_elf32_iq2000_vec) tb="$tb elf32-iq2000.lo elf32.lo $elf" ;; |
252b5132 | 6302 | bfd_elf32_little_generic_vec) tb="$tb elf32-gen.lo elf32.lo $elf" ;; |
dc810e39 AM |
6303 | bfd_elf32_littlearc_vec) tb="$tb elf32-arc.lo elf32.lo $elf" ;; |
6304 | bfd_elf32_littlearm_oabi_vec) tb="$tb elfarm-oabi.lo elf32.lo $elf" ;; | |
b6821651 | 6305 | bfd_elf32_littlearm_vec) tb="$tb elfarm-nabi.lo elf32.lo $elf" ;; |
c6e90b02 | 6306 | bfd_elf32_littlemips_vec) tb="$tb elf32-mips.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo" ;; |
252b5132 | 6307 | bfd_elf32_m32r_vec) tb="$tb elf32-m32r.lo elf32.lo $elf" ;; |
6edf0760 NC |
6308 | bfd_elf32_m32rle_vec) tb="$tb elf32-m32r.lo elf32.lo $elf" ;; |
6309 | bfd_elf32_m32rlin_vec) tb="$tb elf32-m32r.lo elf32.lo $elf" ;; | |
6310 | bfd_elf32_m32rlelin_vec) tb="$tb elf32-m32r.lo elf32.lo $elf" ;; | |
f5a6f915 SC |
6311 | bfd_elf32_m68hc11_vec) tb="$tb elf32-m68hc11.lo elf32-m68hc1x.lo elf32.lo $elf" ;; |
6312 | bfd_elf32_m68hc12_vec) tb="$tb elf32-m68hc12.lo elf32-m68hc1x.lo elf32.lo $elf" ;; | |
252b5132 RH |
6313 | bfd_elf32_m68k_vec) tb="$tb elf32-m68k.lo elf32.lo $elf" ;; |
6314 | bfd_elf32_m88k_vec) tb="$tb elf32-m88k.lo elf32.lo $elf" ;; | |
6315 | bfd_elf32_mcore_big_vec) tb="$tb elf32-mcore.lo elf32.lo $elf" ;; | |
6316 | bfd_elf32_mcore_little_vec) tb="$tb elf32-mcore.lo elf32.lo $elf" ;; | |
6317 | bfd_elf32_mn10200_vec) tb="$tb elf-m10200.lo elf32.lo $elf" ;; | |
6318 | bfd_elf32_mn10300_vec) tb="$tb elf-m10300.lo elf32.lo $elf" ;; | |
2469cfa2 | 6319 | bfd_elf32_msp430_vec) tb="$tb elf32-msp430.lo elf32.lo $elf" ;; |
8a397dad TS |
6320 | bfd_elf32_nbigmips_vec) tb="$tb elfn32-mips.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo"; target_size=64 ;; |
6321 | bfd_elf32_nlittlemips_vec) tb="$tb elfn32-mips.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo"; target_size=64 ;; | |
6322 | bfd_elf32_ntradbigmips_vec) tb="$tb elfn32-mips.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo"; target_size=64 ;; | |
6323 | bfd_elf32_ntradlittlemips_vec) tb="$tb elfn32-mips.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo"; target_size=64 ;; | |
b3baf5d0 | 6324 | bfd_elf32_openrisc_vec) tb="$tb elf32-openrisc.lo elf32.lo $elf" ;; |
3b16e843 | 6325 | bfd_elf32_or32_big_vec) tb="$tb elf32-or32.lo elf32.lo $elf" ;; |
0bcb993b ILT |
6326 | bfd_elf32_pj_vec) tb="$tb elf32-pj.lo elf32.lo $elf";; |
6327 | bfd_elf32_pjl_vec) tb="$tb elf32-pj.lo elf32.lo $elf";; | |
b6821651 AM |
6328 | bfd_elf32_powerpc_vec) tb="$tb elf32-ppc.lo elf32.lo $elf" ;; |
6329 | bfd_elf32_powerpcle_vec) tb="$tb elf32-ppc.lo elf32.lo $elf" ;; | |
a85d7ed0 | 6330 | bfd_elf32_s390_vec) tb="$tb elf32-s390.lo elf32.lo $elf" ;; |
eb1e0e80 NC |
6331 | # FIXME: We include cofflink.lo not because it's needed for |
6332 | # bfd_elf32_sh64[l]_vec, but because we include bfd_elf32_sh[l]_vec | |
6333 | # which needs it but does not list it. Should be fixed in right place. | |
9cba27b2 JT |
6334 | bfd_elf32_sh64_vec) tb="$tb elf32-sh64.lo elf32-sh64-com.lo elf32.lo $elf cofflink.lo" target_size=64 ;; |
6335 | bfd_elf32_sh64l_vec) tb="$tb elf32-sh64.lo elf32-sh64-com.lo elf32.lo $elf cofflink.lo" target_size=64 ;; | |
2bc3c89a AM |
6336 | bfd_elf32_sh64lin_vec) tb="$tb elf32-sh64.lo elf32-sh64-com.lo elf32.lo $elf cofflink.lo" target_size=64 ;; |
6337 | bfd_elf32_sh64blin_vec) tb="$tb elf32-sh64.lo elf32-sh64-com.lo elf32.lo $elf cofflink.lo" target_size=64 ;; | |
6338 | bfd_elf32_sh64lnbsd_vec) tb="$tb elf32-sh64.lo elf32-sh64-com.lo elf32.lo $elf cofflink.lo" ;; | |
6339 | bfd_elf32_sh64nbsd_vec) tb="$tb elf32-sh64.lo elf32-sh64-com.lo elf32.lo $elf cofflink.lo" ;; | |
b6821651 AM |
6340 | bfd_elf32_sh_vec) tb="$tb elf32-sh.lo elf32.lo $elf coff-sh.lo" ;; |
6341 | bfd_elf32_shblin_vec) tb="$tb elf32-sh.lo elf32.lo $elf coff-sh.lo cofflink.lo" ;; | |
6342 | bfd_elf32_shl_vec) tb="$tb elf32-sh.lo elf32.lo $elf coff-sh.lo" ;; | |
6343 | bfd_elf32_shlin_vec) tb="$tb elf32-sh.lo elf32.lo $elf coff-sh.lo cofflink.lo" ;; | |
6344 | bfd_elf32_shlnbsd_vec) tb="$tb elf32-sh.lo elf32.lo $elf coff-sh.lo cofflink.lo" ;; | |
6345 | bfd_elf32_shnbsd_vec) tb="$tb elf32-sh.lo elf32.lo $elf coff-sh.lo cofflink.lo" ;; | |
252b5132 | 6346 | bfd_elf32_sparc_vec) tb="$tb elf32-sparc.lo elf32.lo $elf" ;; |
c6e90b02 TS |
6347 | bfd_elf32_tradbigmips_vec) tb="$tb elf32-mips.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo" ;; |
6348 | bfd_elf32_tradlittlemips_vec) tb="$tb elf32-mips.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo" ;; | |
dc810e39 | 6349 | bfd_elf32_us_cris_vec) tb="$tb elf32-cris.lo elf32.lo $elf" ;; |
252b5132 | 6350 | bfd_elf32_v850_vec) tb="$tb elf32-v850.lo elf32.lo $elf" ;; |
90ace9e9 | 6351 | bfd_elf32_vax_vec) tb="$tb elf32-vax.lo elf32.lo $elf" ;; |
93fbbb04 | 6352 | bfd_elf32_xstormy16_vec) tb="$tb elf32-xstormy16.lo elf32.lo $elf" ;; |
e0001a05 NC |
6353 | bfd_elf32_xtensa_le_vec) tb="$tb xtensa-isa.lo xtensa-modules.lo elf32-xtensa.lo elf32.lo $elf" ;; |
6354 | bfd_elf32_xtensa_be_vec) tb="$tb xtensa-isa.lo xtensa-modules.lo elf32-xtensa.lo elf32.lo $elf" ;; | |
2238051f | 6355 | bfd_elf64_alpha_freebsd_vec) tb="$tb elf64-alpha.lo elf64.lo $elf"; target_size=64 ;; |
dc810e39 AM |
6356 | bfd_elf64_alpha_vec) tb="$tb elf64-alpha.lo elf64.lo $elf"; target_size=64 ;; |
6357 | bfd_elf64_big_generic_vec) tb="$tb elf64-gen.lo elf64.lo $elf"; target_size=64 ;; | |
c6e90b02 | 6358 | bfd_elf64_bigmips_vec) tb="$tb elf64-mips.lo elf64.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo"; target_size=64 ;; |
dc810e39 AM |
6359 | bfd_elf64_hppa_linux_vec) tb="$tb elf64-hppa.lo elf64.lo $elf"; target_size=64 ;; |
6360 | bfd_elf64_hppa_vec) tb="$tb elf64-hppa.lo elf64.lo $elf"; target_size=64 ;; | |
dc810e39 | 6361 | bfd_elf64_ia64_big_vec) tb="$tb elf64-ia64.lo elf64.lo $elf"; target_size=64 ;; |
fcf12726 | 6362 | bfd_elf64_ia64_hpux_big_vec) tb="$tb elf64-ia64.lo elf64.lo $elf"; target_size=64 ;; |
dc810e39 AM |
6363 | bfd_elf64_ia64_little_vec) tb="$tb elf64-ia64.lo elf64.lo $elf"; target_size=64 ;; |
6364 | bfd_elf64_little_generic_vec) tb="$tb elf64-gen.lo elf64.lo $elf"; target_size=64 ;; | |
c6e90b02 | 6365 | bfd_elf64_littlemips_vec) tb="$tb elf64-mips.lo elf64.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo"; target_size=64 ;; |
3c3bdf30 | 6366 | bfd_elf64_mmix_vec) tb="$tb elf64-mmix.lo elf64.lo $elf" target_size=64 ;; |
dc810e39 AM |
6367 | bfd_elf64_powerpc_vec) tb="$tb elf64-ppc.lo elf64-gen.lo elf64.lo $elf"; target_size=64 ;; |
6368 | bfd_elf64_powerpcle_vec) tb="$tb elf64-ppc.lo elf64-gen.lo elf64.lo $elf" target_size=64 ;; | |
6369 | bfd_elf64_s390_vec) tb="$tb elf64-s390.lo elf64.lo $elf"; target_size=64 ;; | |
341ca622 AM |
6370 | bfd_elf64_sh64_vec) tb="$tb elf64-sh64.lo elf64.lo $elf" target_size=64 ;; |
6371 | bfd_elf64_sh64l_vec) tb="$tb elf64-sh64.lo elf64.lo $elf" target_size=64 ;; | |
2bc3c89a AM |
6372 | bfd_elf64_sh64lin_vec) tb="$tb elf64-sh64.lo elf64.lo $elf" target_size=64 ;; |
6373 | bfd_elf64_sh64blin_vec) tb="$tb elf64-sh64.lo elf64.lo $elf" target_size=64 ;; | |
6374 | bfd_elf64_sh64lnbsd_vec) tb="$tb elf64-sh64.lo elf64.lo $elf" target_size=64 ;; | |
6375 | bfd_elf64_sh64nbsd_vec) tb="$tb elf64-sh64.lo elf64.lo $elf" target_size=64 ;; | |
dc810e39 | 6376 | bfd_elf64_sparc_vec) tb="$tb elf64-sparc.lo elf64.lo $elf"; target_size=64 ;; |
c6e90b02 TS |
6377 | bfd_elf64_tradbigmips_vec) tb="$tb elf64-mips.lo elf64.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo"; target_size=64 ;; |
6378 | bfd_elf64_tradlittlemips_vec) tb="$tb elf64-mips.lo elf64.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo"; target_size=64 ;; | |
dc810e39 | 6379 | bfd_elf64_x86_64_vec) tb="$tb elf64-x86-64.lo elf64.lo $elf"; target_size=64 ;; |
3c3bdf30 | 6380 | bfd_mmo_vec) tb="$tb mmo.lo" target_size=64 ;; |
dc810e39 AM |
6381 | bfd_powerpc_pe_vec) tb="$tb pe-ppc.lo peigen.lo cofflink.lo" ;; |
6382 | bfd_powerpc_pei_vec) tb="$tb pei-ppc.lo peigen.lo cofflink.lo" ;; | |
6383 | bfd_powerpcle_pe_vec) tb="$tb pe-ppc.lo peigen.lo cofflink.lo" ;; | |
6384 | bfd_powerpcle_pei_vec) tb="$tb pei-ppc.lo peigen.lo cofflink.lo" ;; | |
06c15ad7 | 6385 | cris_aout_vec) tb="$tb aout-cris.lo" ;; |
dc810e39 | 6386 | demo_64_vec) tb="$tb demo64.lo aout64.lo"; target_size=64 ;; |
252b5132 | 6387 | ecoff_big_vec) tb="$tb coff-mips.lo ecoff.lo ecofflink.lo" ;; |
252b5132 | 6388 | ecoff_biglittle_vec) tb="$tb coff-mips.lo ecoff.lo ecofflink.lo" ;; |
dc810e39 AM |
6389 | ecoff_little_vec) tb="$tb coff-mips.lo ecoff.lo ecofflink.lo" ;; |
6390 | ecoffalpha_little_vec) tb="$tb coff-alpha.lo ecoff.lo ecofflink.lo"; target_size=64 ;; | |
252b5132 RH |
6391 | go32coff_vec) tb="$tb coff-go32.lo cofflink.lo" ;; |
6392 | go32stubbedcoff_vec) tb="$tb coff-stgo32.lo cofflink.lo" ;; | |
6393 | h8300coff_vec) tb="$tb coff-h8300.lo reloc16.lo" ;; | |
6394 | h8500coff_vec) tb="$tb coff-h8500.lo reloc16.lo" ;; | |
6395 | host_aout_vec) tb="$tb host-aout.lo aout32.lo" ;; | |
6396 | hp300bsd_vec) tb="$tb hp300bsd.lo aout32.lo" ;; | |
6397 | hp300hpux_vec) tb="$tb hp300hpux.lo aout32.lo" ;; | |
6398 | i386aout_vec) tb="$tb i386aout.lo aout32.lo" ;; | |
6399 | i386bsd_vec) tb="$tb i386bsd.lo aout32.lo" ;; | |
6400 | i386coff_vec) tb="$tb coff-i386.lo cofflink.lo" ;; | |
6401 | i386dynix_vec) tb="$tb i386dynix.lo aout32.lo" ;; | |
6402 | i386freebsd_vec) tb="$tb i386freebsd.lo aout32.lo" ;; | |
252b5132 RH |
6403 | i386linux_vec) tb="$tb i386linux.lo aout32.lo" ;; |
6404 | i386lynx_aout_vec) tb="$tb i386lynx.lo lynx-core.lo aout32.lo" ;; | |
6405 | i386lynx_coff_vec) tb="$tb cf-i386lynx.lo cofflink.lo lynx-core.lo" ;; | |
6406 | i386mach3_vec) tb="$tb i386mach3.lo aout32.lo" ;; | |
dc810e39 | 6407 | i386msdos_vec) tb="$tb i386msdos.lo" ;; |
252b5132 RH |
6408 | i386netbsd_vec) tb="$tb i386netbsd.lo aout32.lo" ;; |
6409 | i386os9k_vec) tb="$tb i386os9k.lo aout32.lo" ;; | |
dc810e39 AM |
6410 | i386pe_vec) tb="$tb pe-i386.lo peigen.lo cofflink.lo" ;; |
6411 | i386pei_vec) tb="$tb pei-i386.lo peigen.lo cofflink.lo" ;; | |
252b5132 RH |
6412 | i860coff_vec) tb="$tb coff-i860.lo cofflink.lo" ;; |
6413 | icoff_big_vec) tb="$tb coff-i960.lo cofflink.lo" ;; | |
6414 | icoff_little_vec) tb="$tb coff-i960.lo cofflink.lo" ;; | |
6415 | ieee_vec) tb="$tb ieee.lo" ;; | |
dc810e39 AM |
6416 | m68k4knetbsd_vec) tb="$tb m68k4knetbsd.lo aout32.lo" ;; |
6417 | m68kaux_coff_vec) tb="$tb coff-aux.lo coff-m68k.lo cofflink.lo" ;; | |
252b5132 RH |
6418 | m68kcoff_vec) tb="$tb coff-m68k.lo cofflink.lo" ;; |
6419 | m68kcoffun_vec) tb="$tb coff-u68k.lo coff-m68k.lo cofflink.lo" ;; | |
6420 | m68klinux_vec) tb="$tb m68klinux.lo aout32.lo" ;; | |
6421 | m68klynx_aout_vec) tb="$tb m68klynx.lo lynx-core.lo aout32.lo" ;; | |
6422 | m68klynx_coff_vec) tb="$tb cf-m68klynx.lo coff-m68k.lo cofflink.lo lynx-core.lo" ;; | |
6423 | m68knetbsd_vec) tb="$tb m68knetbsd.lo aout32.lo" ;; | |
252b5132 RH |
6424 | m68ksysvcoff_vec) tb="$tb coff-svm68k.lo cofflink.lo" ;; |
6425 | m88kbcs_vec) tb="$tb coff-m88k.lo" ;; | |
341ca622 | 6426 | m88kmach3_vec) tb="$tb m88kmach3.lo aout32.lo" ;; |
c6f8758f | 6427 | m88kopenbsd_vec) tb="$tb m88kopenbsd.lo aout32.lo" ;; |
93509525 KD |
6428 | mach_o_be_vec) tb="$tb mach-o.lo" ;; |
6429 | mach_o_le_vec) tb="$tb mach-o.lo" ;; | |
6430 | mach_o_fat_vec) tb="$tb mach-o.lo" ;; | |
277d1b5e ILT |
6431 | mcore_pe_big_vec) tb="$tb pe-mcore.lo peigen.lo cofflink.lo" ;; |
6432 | mcore_pe_little_vec) tb="$tb pe-mcore.lo peigen.lo cofflink.lo" ;; | |
6433 | mcore_pei_big_vec) tb="$tb pei-mcore.lo peigen.lo cofflink.lo" ;; | |
6434 | mcore_pei_little_vec) tb="$tb pei-mcore.lo peigen.lo cofflink.lo" ;; | |
dc810e39 AM |
6435 | mipslpe_vec) tb="$tb pe-mips.lo peigen.lo cofflink.lo" ;; |
6436 | mipslpei_vec) tb="$tb pei-mips.lo peigen.lo cofflink.lo" ;; | |
252b5132 | 6437 | newsos3_vec) tb="$tb newsos3.lo aout32.lo" ;; |
dc810e39 | 6438 | nlm32_alpha_vec) tb="$tb nlm32-alpha.lo nlm32.lo nlm.lo"; target_size=64 ;; |
252b5132 | 6439 | nlm32_i386_vec) tb="$tb nlm32-i386.lo nlm32.lo nlm.lo" ;; |
252b5132 | 6440 | nlm32_powerpc_vec) tb="$tb nlm32-ppc.lo nlm32.lo nlm.lo" ;; |
dc810e39 | 6441 | nlm32_sparc_vec) tb="$tb nlm32-sparc.lo nlm32.lo nlm.lo" ;; |
3b16e843 | 6442 | or32coff_big_vec) tb="$tb coff-or32.lo cofflink.lo" ;; |
252b5132 | 6443 | pc532machaout_vec) tb="$tb pc532-mach.lo aout-ns32k.lo" ;; |
dc810e39 | 6444 | pc532netbsd_vec) tb="$tb ns32knetbsd.lo aout-ns32k.lo" ;; |
93509525 KD |
6445 | pef_vec) tb="$tb pef.lo" ;; |
6446 | pef_xlib_vec) tb="$tb pef.lo" ;; | |
e135f41b | 6447 | pdp11_aout_vec) tb="$tb pdp11.lo" ;; |
6768c14a | 6448 | pmac_xcoff_vec) tb="$tb coff-rs6000.lo xcofflink.lo" ;; |
252b5132 | 6449 | ppcboot_vec) tb="$tb ppcboot.lo" ;; |
dc810e39 | 6450 | riscix_vec) tb="$tb aout32.lo riscix.lo" ;; |
eb1e0e80 | 6451 | rs6000coff64_vec) tb="$tb coff64-rs6000.lo xcofflink.lo aix5ppc-core.lo"; target_size=64 ;; |
dc810e39 | 6452 | rs6000coff_vec) tb="$tb coff-rs6000.lo xcofflink.lo" ;; |
252b5132 | 6453 | shcoff_small_vec) tb="$tb coff-sh.lo cofflink.lo" ;; |
dc810e39 | 6454 | shcoff_vec) tb="$tb coff-sh.lo cofflink.lo" ;; |
252b5132 | 6455 | shlcoff_small_vec) tb="$tb coff-sh.lo cofflink.lo" ;; |
dc810e39 | 6456 | shlcoff_vec) tb="$tb coff-sh.lo cofflink.lo" ;; |
60bcf0fa NC |
6457 | shlpe_vec) tb="$tb pe-sh.lo coff-sh.lo peigen.lo cofflink.lo" ;; |
6458 | shlpei_vec) tb="$tb pei-sh.lo coff-sh.lo peigen.lo cofflink.lo" ;; | |
252b5132 | 6459 | som_vec) tb="$tb som.lo" ;; |
dc810e39 | 6460 | sparccoff_vec) tb="$tb coff-sparc.lo" ;; |
252b5132 RH |
6461 | sparcle_aout_vec) tb="$tb aout-sparcle.lo aout32.lo" ;; |
6462 | sparclinux_vec) tb="$tb sparclinux.lo aout32.lo" ;; | |
6463 | sparclynx_aout_vec) tb="$tb sparclynx.lo lynx-core.lo aout32.lo" ;; | |
6464 | sparclynx_coff_vec) tb="$tb cf-sparclynx.lo lynx-core.lo" ;; | |
6465 | sparcnetbsd_vec) tb="$tb sparcnetbsd.lo aout32.lo" ;; | |
252b5132 | 6466 | sunos_big_vec) tb="$tb sunos.lo aout32.lo" ;; |
93509525 | 6467 | sym_vec) tb="$tb xsym.lo" ;; |
252b5132 RH |
6468 | tic30_aout_vec) tb="$tb aout-tic30.lo" ;; |
6469 | tic30_coff_vec) tb="$tb coff-tic30.lo" ;; | |
026df7c5 NC |
6470 | tic4x_coff0_vec) tb="$tb coff-tic4x.lo" ;; |
6471 | tic4x_coff0_beh_vec) tb="$tb coff-tic4x.lo" ;; | |
6472 | tic4x_coff1_vec) tb="$tb coff-tic4x.lo" ;; | |
6473 | tic4x_coff1_beh_vec) tb="$tb coff-tic4x.lo" ;; | |
6474 | tic4x_coff2_vec) tb="$tb coff-tic4x.lo" ;; | |
6475 | tic4x_coff2_beh_vec) tb="$tb coff-tic4x.lo" ;; | |
81635ce4 | 6476 | tic54x_coff0_beh_vec) tb="$tb coff-tic54x.lo" ;; |
dc810e39 | 6477 | tic54x_coff0_vec) tb="$tb coff-tic54x.lo" ;; |
81635ce4 | 6478 | tic54x_coff1_beh_vec) tb="$tb coff-tic54x.lo" ;; |
dc810e39 | 6479 | tic54x_coff1_vec) tb="$tb coff-tic54x.lo" ;; |
81635ce4 | 6480 | tic54x_coff2_beh_vec) tb="$tb coff-tic54x.lo" ;; |
dc810e39 | 6481 | tic54x_coff2_vec) tb="$tb coff-tic54x.lo" ;; |
252b5132 | 6482 | tic80coff_vec) tb="$tb coff-tic80.lo cofflink.lo" ;; |
90ace9e9 | 6483 | vaxnetbsd_vec) tb="$tb vaxnetbsd.lo aout32.lo" ;; |
3c2bfad6 | 6484 | vax1knetbsd_vec) tb="$tb vax1knetbsd.lo aout32.lo" ;; |
ba26fd96 | 6485 | vaxbsd_vec) tb="$tb vaxbsd.lo aout32.lo" ;; |
252b5132 | 6486 | versados_vec) tb="$tb versados.lo" ;; |
dc810e39 | 6487 | vms_alpha_vec) tb="$tb vms.lo vms-hdr.lo vms-gsd.lo vms-tir.lo vms-misc.lo"; target_size=64 ;; |
252b5132 RH |
6488 | vms_vax_vec) tb="$tb vms.lo vms-hdr.lo vms-gsd.lo vms-tir.lo vms-misc.lo" ;; |
6489 | w65_vec) tb="$tb coff-w65.lo reloc16.lo" ;; | |
6490 | we32kcoff_vec) tb="$tb coff-we32k.lo" ;; | |
6491 | z8kcoff_vec) tb="$tb coff-z8k.lo reloc16.lo" ;; | |
6492 | ||
341ca622 AM |
6493 | # These appear out of order in targets.c |
6494 | srec_vec) tb="$tb srec.lo" ;; | |
6495 | symbolsrec_vec) tb="$tb srec.lo" ;; | |
6496 | tekhex_vec) tb="$tb tekhex.lo" ;; | |
6497 | cisco_core_big_vec) tb="$tb cisco-core.lo" ;; | |
6498 | cisco_core_little_vec) tb="$tb cisco-core.lo" ;; | |
6499 | ||
252b5132 | 6500 | "") ;; |
6be7c12c | 6501 | *) { echo "configure: error: *** unknown target vector $vec" 1>&2; exit 1; } ;; |
252b5132 | 6502 | esac |
69263e90 AM |
6503 | |
6504 | if test ${target_size} = 64; then | |
6505 | target64=true | |
6506 | fi | |
6507 | if test x"${vec}" = x"${defvec}"; then | |
6508 | bfd_default_target_size=${target_size} | |
6509 | fi | |
252b5132 RH |
6510 | done |
6511 | ||
6512 | # Target architecture .o files. | |
6513 | # A couple of CPUs use shorter file names to avoid problems on DOS | |
6514 | # filesystems. | |
6515 | ta=`echo $selarchs | sed -e s/bfd_/cpu-/g -e s/_arch/.lo/g -e s/mn10200/m10200/ -e s/mn10300/m10300/` | |
6516 | ||
6517 | # Weed out duplicate .o files. | |
6518 | f="" | |
6519 | for i in $tb ; do | |
6520 | case " $f " in | |
6521 | *" $i "*) ;; | |
6522 | *) f="$f $i" ;; | |
6523 | esac | |
6524 | done | |
6525 | tb="$f" | |
6526 | ||
6527 | f="" | |
6528 | for i in $ta ; do | |
6529 | case " $f " in | |
6530 | *" $i "*) ;; | |
6531 | *) f="$f $i" ;; | |
6532 | esac | |
6533 | done | |
6534 | ta="$f" | |
6535 | ||
6536 | bfd_backends="$tb" | |
6537 | bfd_machines="$ta" | |
6538 | ||
6539 | if test x${all_targets} = xtrue ; then | |
6540 | bfd_backends="${bfd_backends}"' $(ALL_BACKENDS)' | |
6541 | bfd_machines="${bfd_machines}"' $(ALL_MACHINES)' | |
6542 | selvecs= | |
6543 | havevecs= | |
6544 | selarchs= | |
08f74004 AM |
6545 | test -n "$assocvecs" && |
6546 | assocvecs=`echo $assocvecs | sed -e 's/^/\&/' -e 's/ \(.\)/,\&\1/g'` | |
252b5132 RH |
6547 | else # all_targets is true |
6548 | # Only set these if they will be nonempty, for the clever echo. | |
6549 | havevecs= | |
08f74004 | 6550 | assocvecs= |
252b5132 RH |
6551 | test -n "$selvecs" && |
6552 | havevecs=`echo $selvecs | sed -e 's/^/-DHAVE_/' -e 's/ \(.\)/ -DHAVE_\1/g'` | |
6553 | test -n "$selvecs" && | |
6554 | selvecs=`echo $selvecs | sed -e 's/^/\&/' -e 's/ \(.\)/,\&\1/g'` | |
6555 | test -n "$selarchs" && | |
6556 | selarchs=`echo $selarchs | sed -e 's/^/\&/' -e 's/ \(.\)/,\&\1/g'` | |
6557 | fi # all_targets is true | |
6558 | ||
6559 | case ${host64}-${target64}-${want64} in | |
6560 | *true*) | |
6561 | wordsize=64 | |
2858ef35 | 6562 | bfd_libs='$(BFD64_LIBS) $(BFD32_LIBS)' |
252b5132 | 6563 | all_backends='$(BFD64_BACKENDS) $(BFD32_BACKENDS)' |
ccba357f | 6564 | if test $BFD_HOST_64_BIT_DEFINED = 0; then |
6be7c12c AO |
6565 | echo "configure: warning: You have requested a 64 bit BFD configuration, but" 1>&2 |
6566 | echo "configure: warning: your compiler may not have a 64 bit integral type" 1>&2 | |
252b5132 | 6567 | fi |
966abd70 HPN |
6568 | if test -n "$GCC" ; then |
6569 | bad_64bit_gcc=no; | |
6570 | echo $ac_n "checking for gcc version with buggy 64-bit support""... $ac_c" 1>&6 | |
eef0f186 | 6571 | echo "configure:6572: checking for gcc version with buggy 64-bit support" >&5 |
966abd70 HPN |
6572 | # Add more tests for gcc versions with non-working 64-bit support here. |
6573 | cat > conftest.$ac_ext <<EOF | |
eef0f186 | 6574 | #line 6575 "configure" |
966abd70 HPN |
6575 | #include "confdefs.h" |
6576 | :__GNUC__:__GNUC_MINOR__:__i386__: | |
6577 | EOF | |
6578 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
6579 | egrep ": 2 : 91 : 1 :" >/dev/null 2>&1; then | |
6580 | rm -rf conftest* | |
6581 | bad_64bit_gcc=yes; | |
6582 | echo "$ac_t""yes: egcs-1.1.2 on ix86 spotted" 1>&6 | |
6583 | else | |
6584 | rm -rf conftest* | |
6585 | echo "$ac_t""no" 1>&6 | |
6586 | fi | |
6587 | rm -f conftest* | |
6588 | ||
6589 | if test $bad_64bit_gcc = yes ; then | |
6590 | { echo "configure: error: A newer version of gcc is needed for the requested 64-bit BFD configuration" 1>&2; exit 1; } | |
6591 | fi | |
6592 | fi | |
252b5132 RH |
6593 | ;; |
6594 | false-false-false) | |
6595 | wordsize=32 | |
2858ef35 | 6596 | bfd_libs='$(BFD32_LIBS)' |
252b5132 RH |
6597 | all_backends='$(BFD32_BACKENDS)' |
6598 | ;; | |
6599 | esac | |
6600 | ||
6be7c12c AO |
6601 | |
6602 | ||
6603 | ||
6604 | ||
6605 | ||
69263e90 | 6606 | |
2858ef35 | 6607 | |
1012372a AC |
6608 | # Determine the host dependant file_ptr a.k.a. off_t type. In order |
6609 | # prefer: off64_t - if ftello64 and fseeko64, off_t - if ftello and | |
6610 | # fseeko, long. This assumes that sizeof off_t is .ge. sizeof long. | |
6611 | # Hopefully a reasonable assumption since fseeko et.al. should be | |
6612 | # upward compatible. | |
6613 | for ac_func in ftello ftello64 fseeko fseeko64 | |
6614 | do | |
6615 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
eef0f186 | 6616 | echo "configure:6617: checking for $ac_func" >&5 |
1012372a AC |
6617 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
6618 | echo $ac_n "(cached) $ac_c" 1>&6 | |
6619 | else | |
6620 | cat > conftest.$ac_ext <<EOF | |
eef0f186 | 6621 | #line 6622 "configure" |
1012372a AC |
6622 | #include "confdefs.h" |
6623 | /* System header to define __stub macros and hopefully few prototypes, | |
6624 | which can conflict with char $ac_func(); below. */ | |
6625 | #include <assert.h> | |
6626 | /* Override any gcc2 internal prototype to avoid an error. */ | |
6627 | /* We use char because int might match the return type of a gcc2 | |
6628 | builtin and then its argument prototype would still apply. */ | |
6629 | char $ac_func(); | |
6630 | ||
6631 | int main() { | |
6632 | ||
6633 | /* The GNU C library defines this for functions which it implements | |
6634 | to always fail with ENOSYS. Some functions are actually named | |
6635 | something starting with __ and the normal name is an alias. */ | |
6636 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
6637 | choke me | |
6638 | #else | |
6639 | $ac_func(); | |
6640 | #endif | |
6641 | ||
6642 | ; return 0; } | |
6643 | EOF | |
eef0f186 | 6644 | if { (eval echo configure:6645: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
1012372a AC |
6645 | rm -rf conftest* |
6646 | eval "ac_cv_func_$ac_func=yes" | |
6647 | else | |
6648 | echo "configure: failed program was:" >&5 | |
6649 | cat conftest.$ac_ext >&5 | |
6650 | rm -rf conftest* | |
6651 | eval "ac_cv_func_$ac_func=no" | |
6652 | fi | |
6653 | rm -f conftest* | |
6654 | fi | |
6655 | ||
6656 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then | |
6657 | echo "$ac_t""yes" 1>&6 | |
6658 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
6659 | cat >> confdefs.h <<EOF | |
6660 | #define $ac_tr_func 1 | |
6661 | EOF | |
6662 | ||
6663 | else | |
6664 | echo "$ac_t""no" 1>&6 | |
6665 | fi | |
6666 | done | |
6667 | ||
1012372a AC |
6668 | if test x"$ac_cv_func_ftello" = xyes -a x"$ac_cv_func_fseeko" = xyes; then |
6669 | echo $ac_n "checking size of off_t""... $ac_c" 1>&6 | |
eef0f186 | 6670 | echo "configure:6671: checking size of off_t" >&5 |
1012372a AC |
6671 | if eval "test \"`echo '$''{'ac_cv_sizeof_off_t'+set}'`\" = set"; then |
6672 | echo $ac_n "(cached) $ac_c" 1>&6 | |
6673 | else | |
6674 | for ac_size in 4 8 1 2 16 12 ; do # List sizes in rough order of prevalence. | |
6675 | cat > conftest.$ac_ext <<EOF | |
eef0f186 | 6676 | #line 6677 "configure" |
1012372a AC |
6677 | #include "confdefs.h" |
6678 | #include "confdefs.h" | |
6679 | #include <sys/types.h> | |
6680 | ||
6681 | ||
6682 | int main() { | |
6683 | switch (0) case 0: case (sizeof (off_t) == $ac_size):; | |
6684 | ; return 0; } | |
6685 | EOF | |
eef0f186 | 6686 | if { (eval echo configure:6687: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
1012372a AC |
6687 | rm -rf conftest* |
6688 | ac_cv_sizeof_off_t=$ac_size | |
6689 | else | |
6690 | echo "configure: failed program was:" >&5 | |
6691 | cat conftest.$ac_ext >&5 | |
6692 | fi | |
6693 | rm -f conftest* | |
6694 | if test x$ac_cv_sizeof_off_t != x ; then break; fi | |
6695 | done | |
6696 | ||
6697 | fi | |
6698 | ||
6699 | if test x$ac_cv_sizeof_off_t = x ; then | |
6700 | { echo "configure: error: cannot determine a size for off_t" 1>&2; exit 1; } | |
6701 | fi | |
6702 | echo "$ac_t""$ac_cv_sizeof_off_t" 1>&6 | |
6703 | cat >> confdefs.h <<EOF | |
6704 | #define SIZEOF_OFF_T $ac_cv_sizeof_off_t | |
6705 | EOF | |
6706 | ||
6707 | ||
1012372a | 6708 | fi |
ccba357f | 6709 | echo $ac_n "checking file_ptr type""... $ac_c" 1>&6 |
eef0f186 | 6710 | echo "configure:6711: checking file_ptr type" >&5 |
ccba357f AM |
6711 | bfd_file_ptr="long" |
6712 | bfd_ufile_ptr="unsigned long" | |
6713 | if test x"$ac_cv_func_ftello64" = xyes -a x"$ac_cv_func_fseeko64" = xyes \ | |
6714 | -o x"${ac_cv_sizeof_off_t}" = x8; then | |
1012372a AC |
6715 | bfd_file_ptr=BFD_HOST_64_BIT |
6716 | bfd_ufile_ptr=BFD_HOST_U_64_BIT | |
6717 | fi | |
6718 | echo "$ac_t""$bfd_file_ptr" 1>&6 | |
6719 | ||
6720 | ||
6721 | ||
6722 | ||
252b5132 RH |
6723 | tdefaults="" |
6724 | test -n "${defvec}" && tdefaults="${tdefaults} -DDEFAULT_VECTOR=${defvec}" | |
6725 | test -n "${selvecs}" && tdefaults="${tdefaults} -DSELECT_VECS='${selvecs}'" | |
08f74004 | 6726 | test -n "${assocvecs}" && tdefaults="${tdefaults} -DASSOCIATED_VECS='${assocvecs}'" |
252b5132 RH |
6727 | test -n "${selarchs}" && tdefaults="${tdefaults} -DSELECT_ARCHITECTURES='${selarchs}'" |
6728 | test -n "${havevecs}" && tdefaults="${tdefaults} ${havevecs}" | |
6729 | ||
6be7c12c | 6730 | |
bc286f95 | 6731 | for ac_hdr in unistd.h |
252b5132 | 6732 | do |
6be7c12c AO |
6733 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` |
6734 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 | |
eef0f186 | 6735 | echo "configure:6736: checking for $ac_hdr" >&5 |
6be7c12c AO |
6736 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
6737 | echo $ac_n "(cached) $ac_c" 1>&6 | |
6738 | else | |
6739 | cat > conftest.$ac_ext <<EOF | |
eef0f186 | 6740 | #line 6741 "configure" |
252b5132 | 6741 | #include "confdefs.h" |
6be7c12c AO |
6742 | #include <$ac_hdr> |
6743 | EOF | |
6744 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
eef0f186 | 6745 | { (eval echo configure:6746: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
6be7c12c AO |
6746 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
6747 | if test -z "$ac_err"; then | |
6748 | rm -rf conftest* | |
6749 | eval "ac_cv_header_$ac_safe=yes" | |
252b5132 | 6750 | else |
6be7c12c AO |
6751 | echo "$ac_err" >&5 |
6752 | echo "configure: failed program was:" >&5 | |
252b5132 | 6753 | cat conftest.$ac_ext >&5 |
6be7c12c AO |
6754 | rm -rf conftest* |
6755 | eval "ac_cv_header_$ac_safe=no" | |
252b5132 | 6756 | fi |
6be7c12c | 6757 | rm -f conftest* |
252b5132 | 6758 | fi |
6be7c12c AO |
6759 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
6760 | echo "$ac_t""yes" 1>&6 | |
6761 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` | |
6762 | cat >> confdefs.h <<EOF | |
6763 | #define $ac_tr_hdr 1 | |
252b5132 | 6764 | EOF |
6be7c12c AO |
6765 | |
6766 | else | |
6767 | echo "$ac_t""no" 1>&6 | |
252b5132 RH |
6768 | fi |
6769 | done | |
6770 | ||
6771 | for ac_func in getpagesize | |
6772 | do | |
6be7c12c | 6773 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
eef0f186 | 6774 | echo "configure:6775: checking for $ac_func" >&5 |
6be7c12c AO |
6775 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
6776 | echo $ac_n "(cached) $ac_c" 1>&6 | |
6777 | else | |
6778 | cat > conftest.$ac_ext <<EOF | |
eef0f186 | 6779 | #line 6780 "configure" |
252b5132 RH |
6780 | #include "confdefs.h" |
6781 | /* System header to define __stub macros and hopefully few prototypes, | |
6be7c12c | 6782 | which can conflict with char $ac_func(); below. */ |
252b5132 RH |
6783 | #include <assert.h> |
6784 | /* Override any gcc2 internal prototype to avoid an error. */ | |
6785 | /* We use char because int might match the return type of a gcc2 | |
6be7c12c AO |
6786 | builtin and then its argument prototype would still apply. */ |
6787 | char $ac_func(); | |
6788 | ||
6789 | int main() { | |
252b5132 RH |
6790 | |
6791 | /* The GNU C library defines this for functions which it implements | |
6792 | to always fail with ENOSYS. Some functions are actually named | |
6793 | something starting with __ and the normal name is an alias. */ | |
6794 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
6795 | choke me | |
6796 | #else | |
6be7c12c | 6797 | $ac_func(); |
252b5132 RH |
6798 | #endif |
6799 | ||
6be7c12c | 6800 | ; return 0; } |
252b5132 | 6801 | EOF |
eef0f186 | 6802 | if { (eval echo configure:6803: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
6be7c12c AO |
6803 | rm -rf conftest* |
6804 | eval "ac_cv_func_$ac_func=yes" | |
6805 | else | |
6806 | echo "configure: failed program was:" >&5 | |
6807 | cat conftest.$ac_ext >&5 | |
6808 | rm -rf conftest* | |
6809 | eval "ac_cv_func_$ac_func=no" | |
6810 | fi | |
6811 | rm -f conftest* | |
6812 | fi | |
252b5132 | 6813 | |
6be7c12c AO |
6814 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
6815 | echo "$ac_t""yes" 1>&6 | |
6816 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
6817 | cat >> confdefs.h <<EOF | |
6818 | #define $ac_tr_func 1 | |
6819 | EOF | |
6820 | ||
6821 | else | |
6822 | echo "$ac_t""no" 1>&6 | |
252b5132 RH |
6823 | fi |
6824 | done | |
6825 | ||
6be7c12c | 6826 | echo $ac_n "checking for working mmap""... $ac_c" 1>&6 |
eef0f186 | 6827 | echo "configure:6828: checking for working mmap" >&5 |
6be7c12c AO |
6828 | if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then |
6829 | echo $ac_n "(cached) $ac_c" 1>&6 | |
252b5132 RH |
6830 | else |
6831 | if test "$cross_compiling" = yes; then | |
6832 | ac_cv_func_mmap_fixed_mapped=no | |
6833 | else | |
6be7c12c | 6834 | cat > conftest.$ac_ext <<EOF |
eef0f186 | 6835 | #line 6836 "configure" |
252b5132 | 6836 | #include "confdefs.h" |
6be7c12c | 6837 | |
252b5132 RH |
6838 | /* Thanks to Mike Haertel and Jim Avera for this test. |
6839 | Here is a matrix of mmap possibilities: | |
6840 | mmap private not fixed | |
6841 | mmap private fixed at somewhere currently unmapped | |
6842 | mmap private fixed at somewhere already mapped | |
6843 | mmap shared not fixed | |
6844 | mmap shared fixed at somewhere currently unmapped | |
6845 | mmap shared fixed at somewhere already mapped | |
6846 | For private mappings, we should verify that changes cannot be read() | |
6847 | back from the file, nor mmap's back from the file at a different | |
6848 | address. (There have been systems where private was not correctly | |
6849 | implemented like the infamous i386 svr4.0, and systems where the | |
6be7c12c | 6850 | VM page cache was not coherent with the filesystem buffer cache |
252b5132 RH |
6851 | like early versions of FreeBSD and possibly contemporary NetBSD.) |
6852 | For shared mappings, we should conversely verify that changes get | |
6853 | propogated back to all the places they're supposed to be. | |
6854 | ||
6855 | Grep wants private fixed already mapped. | |
6856 | The main things grep needs to know about mmap are: | |
6857 | * does it exist and is it safe to write into the mmap'd area | |
6858 | * how to use it (BSD variants) */ | |
6859 | #include <sys/types.h> | |
6860 | #include <fcntl.h> | |
6861 | #include <sys/mman.h> | |
6862 | ||
b3baf5d0 | 6863 | /* This mess was copied from the GNU getpagesize.h. */ |
6be7c12c | 6864 | #ifndef HAVE_GETPAGESIZE |
bc286f95 BE |
6865 | # ifdef HAVE_UNISTD_H |
6866 | # include <unistd.h> | |
6867 | # endif | |
6be7c12c | 6868 | |
252b5132 | 6869 | /* Assume that all systems that can run configure have sys/param.h. */ |
6be7c12c | 6870 | # ifndef HAVE_SYS_PARAM_H |
252b5132 RH |
6871 | # define HAVE_SYS_PARAM_H 1 |
6872 | # endif | |
6873 | ||
6874 | # ifdef _SC_PAGESIZE | |
6875 | # define getpagesize() sysconf(_SC_PAGESIZE) | |
6876 | # else /* no _SC_PAGESIZE */ | |
6be7c12c | 6877 | # ifdef HAVE_SYS_PARAM_H |
252b5132 RH |
6878 | # include <sys/param.h> |
6879 | # ifdef EXEC_PAGESIZE | |
6880 | # define getpagesize() EXEC_PAGESIZE | |
6881 | # else /* no EXEC_PAGESIZE */ | |
6882 | # ifdef NBPG | |
6883 | # define getpagesize() NBPG * CLSIZE | |
6884 | # ifndef CLSIZE | |
6885 | # define CLSIZE 1 | |
6886 | # endif /* no CLSIZE */ | |
6887 | # else /* no NBPG */ | |
6888 | # ifdef NBPC | |
6889 | # define getpagesize() NBPC | |
6890 | # else /* no NBPC */ | |
6891 | # ifdef PAGESIZE | |
6892 | # define getpagesize() PAGESIZE | |
6893 | # endif /* PAGESIZE */ | |
6894 | # endif /* no NBPC */ | |
6895 | # endif /* no NBPG */ | |
6896 | # endif /* no EXEC_PAGESIZE */ | |
6897 | # else /* no HAVE_SYS_PARAM_H */ | |
6898 | # define getpagesize() 8192 /* punt totally */ | |
6899 | # endif /* no HAVE_SYS_PARAM_H */ | |
6900 | # endif /* no _SC_PAGESIZE */ | |
6901 | ||
6902 | #endif /* no HAVE_GETPAGESIZE */ | |
6903 | ||
6be7c12c AO |
6904 | #ifdef __cplusplus |
6905 | extern "C" { void *malloc(unsigned); } | |
6906 | #else | |
6907 | char *malloc(); | |
6908 | #endif | |
6909 | ||
252b5132 | 6910 | int |
6be7c12c | 6911 | main() |
252b5132 | 6912 | { |
6be7c12c AO |
6913 | char *data, *data2, *data3; |
6914 | int i, pagesize; | |
6915 | int fd; | |
6916 | ||
6917 | pagesize = getpagesize(); | |
6918 | ||
6919 | /* | |
6920 | * First, make a file with some known garbage in it. | |
6921 | */ | |
6922 | data = malloc(pagesize); | |
6923 | if (!data) | |
6924 | exit(1); | |
6925 | for (i = 0; i < pagesize; ++i) | |
6926 | *(data + i) = rand(); | |
6927 | umask(0); | |
6928 | fd = creat("conftestmmap", 0600); | |
6929 | if (fd < 0) | |
6930 | exit(1); | |
6931 | if (write(fd, data, pagesize) != pagesize) | |
6932 | exit(1); | |
6933 | close(fd); | |
6934 | ||
6935 | /* | |
6936 | * Next, try to mmap the file at a fixed address which | |
6937 | * already has something else allocated at it. If we can, | |
6938 | * also make sure that we see the same garbage. | |
6939 | */ | |
6940 | fd = open("conftestmmap", O_RDWR); | |
6941 | if (fd < 0) | |
6942 | exit(1); | |
6943 | data2 = malloc(2 * pagesize); | |
6944 | if (!data2) | |
6945 | exit(1); | |
6946 | data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1); | |
6947 | if (data2 != mmap(data2, pagesize, PROT_READ | PROT_WRITE, | |
6948 | MAP_PRIVATE | MAP_FIXED, fd, 0L)) | |
6949 | exit(1); | |
6950 | for (i = 0; i < pagesize; ++i) | |
6951 | if (*(data + i) != *(data2 + i)) | |
6952 | exit(1); | |
6953 | ||
6954 | /* | |
6955 | * Finally, make sure that changes to the mapped area | |
6956 | * do not percolate back to the file as seen by read(). | |
6957 | * (This is a bug on some variants of i386 svr4.0.) | |
6958 | */ | |
6959 | for (i = 0; i < pagesize; ++i) | |
6960 | *(data2 + i) = *(data2 + i) + 1; | |
6961 | data3 = malloc(pagesize); | |
6962 | if (!data3) | |
6963 | exit(1); | |
6964 | if (read(fd, data3, pagesize) != pagesize) | |
6965 | exit(1); | |
6966 | for (i = 0; i < pagesize; ++i) | |
6967 | if (*(data + i) != *(data3 + i)) | |
6968 | exit(1); | |
6969 | close(fd); | |
6970 | unlink("conftestmmap"); | |
6971 | exit(0); | |
252b5132 | 6972 | } |
6be7c12c AO |
6973 | |
6974 | EOF | |
eef0f186 | 6975 | if { (eval echo configure:6976: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
6be7c12c | 6976 | then |
252b5132 RH |
6977 | ac_cv_func_mmap_fixed_mapped=yes |
6978 | else | |
6be7c12c AO |
6979 | echo "configure: failed program was:" >&5 |
6980 | cat conftest.$ac_ext >&5 | |
6981 | rm -fr conftest* | |
6982 | ac_cv_func_mmap_fixed_mapped=no | |
252b5132 | 6983 | fi |
6be7c12c | 6984 | rm -fr conftest* |
252b5132 | 6985 | fi |
6be7c12c | 6986 | |
252b5132 | 6987 | fi |
b3baf5d0 | 6988 | |
6be7c12c AO |
6989 | echo "$ac_t""$ac_cv_func_mmap_fixed_mapped" 1>&6 |
6990 | if test $ac_cv_func_mmap_fixed_mapped = yes; then | |
6991 | cat >> confdefs.h <<\EOF | |
252b5132 RH |
6992 | #define HAVE_MMAP 1 |
6993 | EOF | |
6994 | ||
6995 | fi | |
6996 | ||
6997 | for ac_func in madvise mprotect | |
6998 | do | |
6be7c12c | 6999 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
eef0f186 | 7000 | echo "configure:7001: checking for $ac_func" >&5 |
6be7c12c AO |
7001 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
7002 | echo $ac_n "(cached) $ac_c" 1>&6 | |
7003 | else | |
7004 | cat > conftest.$ac_ext <<EOF | |
eef0f186 | 7005 | #line 7006 "configure" |
252b5132 RH |
7006 | #include "confdefs.h" |
7007 | /* System header to define __stub macros and hopefully few prototypes, | |
6be7c12c | 7008 | which can conflict with char $ac_func(); below. */ |
252b5132 RH |
7009 | #include <assert.h> |
7010 | /* Override any gcc2 internal prototype to avoid an error. */ | |
7011 | /* We use char because int might match the return type of a gcc2 | |
6be7c12c AO |
7012 | builtin and then its argument prototype would still apply. */ |
7013 | char $ac_func(); | |
7014 | ||
7015 | int main() { | |
252b5132 RH |
7016 | |
7017 | /* The GNU C library defines this for functions which it implements | |
7018 | to always fail with ENOSYS. Some functions are actually named | |
7019 | something starting with __ and the normal name is an alias. */ | |
7020 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
7021 | choke me | |
7022 | #else | |
6be7c12c | 7023 | $ac_func(); |
252b5132 RH |
7024 | #endif |
7025 | ||
6be7c12c | 7026 | ; return 0; } |
252b5132 | 7027 | EOF |
eef0f186 | 7028 | if { (eval echo configure:7029: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
6be7c12c AO |
7029 | rm -rf conftest* |
7030 | eval "ac_cv_func_$ac_func=yes" | |
7031 | else | |
7032 | echo "configure: failed program was:" >&5 | |
7033 | cat conftest.$ac_ext >&5 | |
7034 | rm -rf conftest* | |
7035 | eval "ac_cv_func_$ac_func=no" | |
7036 | fi | |
7037 | rm -f conftest* | |
7038 | fi | |
252b5132 | 7039 | |
6be7c12c AO |
7040 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
7041 | echo "$ac_t""yes" 1>&6 | |
7042 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
7043 | cat >> confdefs.h <<EOF | |
7044 | #define $ac_tr_func 1 | |
7045 | EOF | |
7046 | ||
7047 | else | |
7048 | echo "$ac_t""no" 1>&6 | |
252b5132 RH |
7049 | fi |
7050 | done | |
7051 | ||
7052 | case ${want_mmap}+${ac_cv_func_mmap_fixed_mapped} in | |
6be7c12c | 7053 | true+yes ) cat >> confdefs.h <<\EOF |
252b5132 RH |
7054 | #define USE_MMAP 1 |
7055 | EOF | |
7056 | ;; | |
7057 | esac | |
7058 | ||
7059 | rm -f doc/config.status | |
6be7c12c AO |
7060 | trap '' 1 2 15 |
7061 | cat > confcache <<\EOF | |
252b5132 RH |
7062 | # This file is a shell script that caches the results of configure |
7063 | # tests run on this system so they can be shared between configure | |
6be7c12c AO |
7064 | # scripts and configure runs. It is not useful on other systems. |
7065 | # If it contains results you don't want to keep, you may remove or edit it. | |
252b5132 | 7066 | # |
6be7c12c AO |
7067 | # By default, configure uses ./config.cache as the cache file, |
7068 | # creating it if it does not exist already. You can give configure | |
7069 | # the --cache-file=FILE option to use a different cache file; that is | |
7070 | # what configure does when it calls configure scripts in | |
7071 | # subdirectories, so they share the cache. | |
7072 | # Giving --cache-file=/dev/null disables caching, for debugging configure. | |
7073 | # config.status only pays attention to the cache file if you give it the | |
7074 | # --recheck option to rerun configure. | |
252b5132 | 7075 | # |
6be7c12c | 7076 | EOF |
252b5132 RH |
7077 | # The following way of writing the cache mishandles newlines in values, |
7078 | # but we know of no workaround that is simple, portable, and efficient. | |
7079 | # So, don't put newlines in cache variables' values. | |
7080 | # Ultrix sh set writes to stderr and can't be redirected directly, | |
7081 | # and sets the high bit in the cache file unless we assign to the vars. | |
6be7c12c AO |
7082 | (set) 2>&1 | |
7083 | case `(ac_space=' '; set | grep ac_space) 2>&1` in | |
7084 | *ac_space=\ *) | |
7085 | # `set' does not quote correctly, so add quotes (double-quote substitution | |
7086 | # turns \\\\ into \\, and sed turns \\ into \). | |
7087 | sed -n \ | |
7088 | -e "s/'/'\\\\''/g" \ | |
7089 | -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p" | |
7090 | ;; | |
7091 | *) | |
7092 | # `set' quotes correctly as required by POSIX, so do not add quotes. | |
7093 | sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p' | |
7094 | ;; | |
7095 | esac >> confcache | |
7096 | if cmp -s $cache_file confcache; then | |
7097 | : | |
7098 | else | |
252b5132 | 7099 | if test -w $cache_file; then |
6be7c12c AO |
7100 | echo "updating cache $cache_file" |
7101 | cat confcache > $cache_file | |
252b5132 RH |
7102 | else |
7103 | echo "not updating unwritable cache $cache_file" | |
7104 | fi | |
7105 | fi | |
7106 | rm -f confcache | |
7107 | ||
6be7c12c AO |
7108 | trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 |
7109 | ||
252b5132 RH |
7110 | test "x$prefix" = xNONE && prefix=$ac_default_prefix |
7111 | # Let make expand exec_prefix. | |
7112 | test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' | |
7113 | ||
6be7c12c AO |
7114 | # Any assignment to VPATH causes Sun make to only execute |
7115 | # the first set of double-colon rules, so remove it if not needed. | |
7116 | # If there is a colon in the path, we need to keep it. | |
252b5132 | 7117 | if test "x$srcdir" = x.; then |
6be7c12c | 7118 | ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d' |
252b5132 RH |
7119 | fi |
7120 | ||
6be7c12c AO |
7121 | trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15 |
7122 | ||
252b5132 RH |
7123 | DEFS=-DHAVE_CONFIG_H |
7124 | ||
6be7c12c | 7125 | # Without the "./", some shells look in PATH for config.status. |
252b5132 | 7126 | : ${CONFIG_STATUS=./config.status} |
6be7c12c AO |
7127 | |
7128 | echo creating $CONFIG_STATUS | |
7129 | rm -f $CONFIG_STATUS | |
7130 | cat > $CONFIG_STATUS <<EOF | |
7131 | #! /bin/sh | |
252b5132 RH |
7132 | # Generated automatically by configure. |
7133 | # Run this file to recreate the current configuration. | |
6be7c12c AO |
7134 | # This directory was configured as follows, |
7135 | # on host `(hostname || uname -n) 2>/dev/null | sed 1q`: | |
7136 | # | |
7137 | # $0 $ac_configure_args | |
7138 | # | |
252b5132 | 7139 | # Compiler output produced by configure, useful for debugging |
6be7c12c | 7140 | # configure, is in ./config.log if it exists. |
b3baf5d0 | 7141 | |
6be7c12c AO |
7142 | ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]" |
7143 | for ac_option | |
252b5132 | 7144 | do |
6be7c12c | 7145 | case "\$ac_option" in |
252b5132 | 7146 | -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) |
6be7c12c AO |
7147 | echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion" |
7148 | exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;; | |
7149 | -version | --version | --versio | --versi | --vers | --ver | --ve | --v) | |
7150 | echo "$CONFIG_STATUS generated by autoconf version 2.13" | |
7151 | exit 0 ;; | |
7152 | -help | --help | --hel | --he | --h) | |
7153 | echo "\$ac_cs_usage"; exit 0 ;; | |
7154 | *) echo "\$ac_cs_usage"; exit 1 ;; | |
252b5132 RH |
7155 | esac |
7156 | done | |
7157 | ||
6be7c12c AO |
7158 | ac_given_srcdir=$srcdir |
7159 | ac_given_INSTALL="$INSTALL" | |
b3baf5d0 | 7160 | |
bc286f95 | 7161 | trap 'rm -fr `echo "Makefile doc/Makefile bfd-in3.h:bfd-in2.h po/Makefile.in:po/Make-in config.h:config.in" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 |
b3baf5d0 | 7162 | EOF |
6be7c12c | 7163 | cat >> $CONFIG_STATUS <<EOF |
b3baf5d0 | 7164 | |
6be7c12c AO |
7165 | # Protect against being on the right side of a sed subst in config.status. |
7166 | sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g; | |
7167 | s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF | |
7168 | $ac_vpsub | |
7169 | $extrasub | |
7170 | s%@SHELL@%$SHELL%g | |
7171 | s%@CFLAGS@%$CFLAGS%g | |
7172 | s%@CPPFLAGS@%$CPPFLAGS%g | |
7173 | s%@CXXFLAGS@%$CXXFLAGS%g | |
7174 | s%@FFLAGS@%$FFLAGS%g | |
7175 | s%@DEFS@%$DEFS%g | |
7176 | s%@LDFLAGS@%$LDFLAGS%g | |
7177 | s%@LIBS@%$LIBS%g | |
7178 | s%@exec_prefix@%$exec_prefix%g | |
7179 | s%@prefix@%$prefix%g | |
7180 | s%@program_transform_name@%$program_transform_name%g | |
7181 | s%@bindir@%$bindir%g | |
7182 | s%@sbindir@%$sbindir%g | |
7183 | s%@libexecdir@%$libexecdir%g | |
7184 | s%@datadir@%$datadir%g | |
7185 | s%@sysconfdir@%$sysconfdir%g | |
7186 | s%@sharedstatedir@%$sharedstatedir%g | |
7187 | s%@localstatedir@%$localstatedir%g | |
7188 | s%@libdir@%$libdir%g | |
7189 | s%@includedir@%$includedir%g | |
7190 | s%@oldincludedir@%$oldincludedir%g | |
7191 | s%@infodir@%$infodir%g | |
7192 | s%@mandir@%$mandir%g | |
7193 | s%@host@%$host%g | |
7194 | s%@host_alias@%$host_alias%g | |
7195 | s%@host_cpu@%$host_cpu%g | |
7196 | s%@host_vendor@%$host_vendor%g | |
7197 | s%@host_os@%$host_os%g | |
7198 | s%@target@%$target%g | |
7199 | s%@target_alias@%$target_alias%g | |
7200 | s%@target_cpu@%$target_cpu%g | |
7201 | s%@target_vendor@%$target_vendor%g | |
7202 | s%@target_os@%$target_os%g | |
7203 | s%@build@%$build%g | |
7204 | s%@build_alias@%$build_alias%g | |
7205 | s%@build_cpu@%$build_cpu%g | |
7206 | s%@build_vendor@%$build_vendor%g | |
7207 | s%@build_os@%$build_os%g | |
6be7c12c AO |
7208 | s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g |
7209 | s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g | |
7210 | s%@INSTALL_DATA@%$INSTALL_DATA%g | |
7211 | s%@PACKAGE@%$PACKAGE%g | |
7212 | s%@VERSION@%$VERSION%g | |
7213 | s%@ACLOCAL@%$ACLOCAL%g | |
7214 | s%@AUTOCONF@%$AUTOCONF%g | |
7215 | s%@AUTOMAKE@%$AUTOMAKE%g | |
7216 | s%@AUTOHEADER@%$AUTOHEADER%g | |
7217 | s%@MAKEINFO@%$MAKEINFO%g | |
7218 | s%@SET_MAKE@%$SET_MAKE%g | |
7219 | s%@AR@%$AR%g | |
7220 | s%@RANLIB@%$RANLIB%g | |
c5d1701e | 7221 | s%@CC@%$CC%g |
6be7c12c AO |
7222 | s%@LN_S@%$LN_S%g |
7223 | s%@OBJEXT@%$OBJEXT%g | |
7224 | s%@EXEEXT@%$EXEEXT%g | |
7225 | s%@STRIP@%$STRIP%g | |
7226 | s%@LIBTOOL@%$LIBTOOL%g | |
7227 | s%@WARN_CFLAGS@%$WARN_CFLAGS%g | |
7228 | s%@MAINTAINER_MODE_TRUE@%$MAINTAINER_MODE_TRUE%g | |
7229 | s%@MAINTAINER_MODE_FALSE@%$MAINTAINER_MODE_FALSE%g | |
7230 | s%@MAINT@%$MAINT%g | |
a703a6ea AM |
7231 | s%@INSTALL_LIBBFD_TRUE@%$INSTALL_LIBBFD_TRUE%g |
7232 | s%@INSTALL_LIBBFD_FALSE@%$INSTALL_LIBBFD_FALSE%g | |
7233 | s%@bfdlibdir@%$bfdlibdir%g | |
7234 | s%@bfdincludedir@%$bfdincludedir%g | |
6be7c12c AO |
7235 | s%@CPP@%$CPP%g |
7236 | s%@ALLOCA@%$ALLOCA%g | |
7237 | s%@USE_NLS@%$USE_NLS%g | |
7238 | s%@MSGFMT@%$MSGFMT%g | |
7239 | s%@GMSGFMT@%$GMSGFMT%g | |
7240 | s%@XGETTEXT@%$XGETTEXT%g | |
7241 | s%@USE_INCLUDED_LIBINTL@%$USE_INCLUDED_LIBINTL%g | |
7242 | s%@CATALOGS@%$CATALOGS%g | |
7243 | s%@CATOBJEXT@%$CATOBJEXT%g | |
7244 | s%@DATADIRNAME@%$DATADIRNAME%g | |
7245 | s%@GMOFILES@%$GMOFILES%g | |
7246 | s%@INSTOBJEXT@%$INSTOBJEXT%g | |
7247 | s%@INTLDEPS@%$INTLDEPS%g | |
7248 | s%@INTLLIBS@%$INTLLIBS%g | |
7249 | s%@INTLOBJS@%$INTLOBJS%g | |
7250 | s%@POFILES@%$POFILES%g | |
7251 | s%@POSUB@%$POSUB%g | |
7252 | s%@INCLUDE_LOCALE_H@%$INCLUDE_LOCALE_H%g | |
7253 | s%@GT_NO@%$GT_NO%g | |
7254 | s%@GT_YES@%$GT_YES%g | |
7255 | s%@MKINSTALLDIRS@%$MKINSTALLDIRS%g | |
7256 | s%@l@%$l%g | |
7257 | s%@HDEFINES@%$HDEFINES%g | |
7258 | s%@BFD_HOST_64BIT_LONG@%$BFD_HOST_64BIT_LONG%g | |
ec317fb1 | 7259 | s%@BFD_HOST_LONG_LONG@%$BFD_HOST_LONG_LONG%g |
6be7c12c AO |
7260 | s%@BFD_HOST_64_BIT_DEFINED@%$BFD_HOST_64_BIT_DEFINED%g |
7261 | s%@BFD_HOST_64_BIT@%$BFD_HOST_64_BIT%g | |
7262 | s%@BFD_HOST_U_64_BIT@%$BFD_HOST_U_64_BIT%g | |
7263 | s%@CC_FOR_BUILD@%$CC_FOR_BUILD%g | |
7264 | s%@EXEEXT_FOR_BUILD@%$EXEEXT_FOR_BUILD%g | |
7265 | s%@COREFILE@%$COREFILE%g | |
7266 | s%@COREFLAG@%$COREFLAG%g | |
7267 | s%@WIN32LDFLAGS@%$WIN32LDFLAGS%g | |
7268 | s%@WIN32LIBADD@%$WIN32LIBADD%g | |
7269 | s%@TDEFINES@%$TDEFINES%g | |
7270 | s%@wordsize@%$wordsize%g | |
2858ef35 | 7271 | s%@bfd_libs@%$bfd_libs%g |
6be7c12c AO |
7272 | s%@all_backends@%$all_backends%g |
7273 | s%@bfd_backends@%$bfd_backends%g | |
7274 | s%@bfd_machines@%$bfd_machines%g | |
69263e90 | 7275 | s%@bfd_default_target_size@%$bfd_default_target_size%g |
1012372a AC |
7276 | s%@bfd_file_ptr@%$bfd_file_ptr%g |
7277 | s%@bfd_ufile_ptr@%$bfd_ufile_ptr%g | |
6be7c12c | 7278 | s%@tdefaults@%$tdefaults%g |
b3baf5d0 | 7279 | |
252b5132 RH |
7280 | CEOF |
7281 | EOF | |
7282 | ||
6be7c12c AO |
7283 | cat >> $CONFIG_STATUS <<\EOF |
7284 | ||
7285 | # Split the substitutions into bite-sized pieces for seds with | |
7286 | # small command number limits, like on Digital OSF/1 and HP-UX. | |
dc810e39 | 7287 | ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script. |
6be7c12c AO |
7288 | ac_file=1 # Number of current file. |
7289 | ac_beg=1 # First line for current file. | |
7290 | ac_end=$ac_max_sed_cmds # Line after last line for current file. | |
7291 | ac_more_lines=: | |
7292 | ac_sed_cmds="" | |
7293 | while $ac_more_lines; do | |
7294 | if test $ac_beg -gt 1; then | |
7295 | sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file | |
7296 | else | |
7297 | sed "${ac_end}q" conftest.subs > conftest.s$ac_file | |
7298 | fi | |
7299 | if test ! -s conftest.s$ac_file; then | |
7300 | ac_more_lines=false | |
7301 | rm -f conftest.s$ac_file | |
7302 | else | |
7303 | if test -z "$ac_sed_cmds"; then | |
7304 | ac_sed_cmds="sed -f conftest.s$ac_file" | |
252b5132 | 7305 | else |
6be7c12c | 7306 | ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file" |
252b5132 | 7307 | fi |
6be7c12c AO |
7308 | ac_file=`expr $ac_file + 1` |
7309 | ac_beg=$ac_end | |
7310 | ac_end=`expr $ac_end + $ac_max_sed_cmds` | |
252b5132 | 7311 | fi |
6be7c12c AO |
7312 | done |
7313 | if test -z "$ac_sed_cmds"; then | |
7314 | ac_sed_cmds=cat | |
7315 | fi | |
7316 | EOF | |
7317 | ||
7318 | cat >> $CONFIG_STATUS <<EOF | |
252b5132 | 7319 | |
bc286f95 | 7320 | CONFIG_FILES=\${CONFIG_FILES-"Makefile doc/Makefile bfd-in3.h:bfd-in2.h po/Makefile.in:po/Make-in"} |
252b5132 | 7321 | EOF |
6be7c12c AO |
7322 | cat >> $CONFIG_STATUS <<\EOF |
7323 | for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then | |
252b5132 | 7324 | # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". |
6be7c12c AO |
7325 | case "$ac_file" in |
7326 | *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'` | |
7327 | ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; | |
7328 | *) ac_file_in="${ac_file}.in" ;; | |
252b5132 RH |
7329 | esac |
7330 | ||
6be7c12c | 7331 | # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories. |
b3baf5d0 | 7332 | |
6be7c12c AO |
7333 | # Remove last slash and all that follows it. Not all systems have dirname. |
7334 | ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` | |
7335 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then | |
7336 | # The file is in a subdirectory. | |
7337 | test ! -d "$ac_dir" && mkdir "$ac_dir" | |
7338 | ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`" | |
252b5132 | 7339 | # A "../" for each directory in $ac_dir_suffix. |
6be7c12c | 7340 | ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'` |
252b5132 RH |
7341 | else |
7342 | ac_dir_suffix= ac_dots= | |
7343 | fi | |
7344 | ||
6be7c12c AO |
7345 | case "$ac_given_srcdir" in |
7346 | .) srcdir=. | |
7347 | if test -z "$ac_dots"; then top_srcdir=. | |
7348 | else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;; | |
7349 | /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;; | |
252b5132 | 7350 | *) # Relative path. |
6be7c12c AO |
7351 | srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix" |
7352 | top_srcdir="$ac_dots$ac_given_srcdir" ;; | |
252b5132 RH |
7353 | esac |
7354 | ||
6be7c12c AO |
7355 | case "$ac_given_INSTALL" in |
7356 | [/$]*) INSTALL="$ac_given_INSTALL" ;; | |
7357 | *) INSTALL="$ac_dots$ac_given_INSTALL" ;; | |
252b5132 RH |
7358 | esac |
7359 | ||
6be7c12c AO |
7360 | echo creating "$ac_file" |
7361 | rm -f "$ac_file" | |
7362 | configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure." | |
7363 | case "$ac_file" in | |
7364 | *Makefile*) ac_comsub="1i\\ | |
7365 | # $configure_input" ;; | |
7366 | *) ac_comsub= ;; | |
7367 | esac | |
252b5132 | 7368 | |
6be7c12c AO |
7369 | ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"` |
7370 | sed -e "$ac_comsub | |
7371 | s%@configure_input@%$configure_input%g | |
7372 | s%@srcdir@%$srcdir%g | |
7373 | s%@top_srcdir@%$top_srcdir%g | |
7374 | s%@INSTALL@%$INSTALL%g | |
7375 | " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file | |
7376 | fi; done | |
7377 | rm -f conftest.s* | |
252b5132 RH |
7378 | |
7379 | # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where | |
7380 | # NAME is the cpp macro being defined and VALUE is the value it is being given. | |
7381 | # | |
7382 | # ac_d sets the value in "#define NAME VALUE" lines. | |
6be7c12c AO |
7383 | ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)' |
7384 | ac_dB='\([ ][ ]*\)[^ ]*%\1#\2' | |
7385 | ac_dC='\3' | |
7386 | ac_dD='%g' | |
7387 | # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE". | |
7388 | ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' | |
7389 | ac_uB='\([ ]\)%\1#\2define\3' | |
252b5132 | 7390 | ac_uC=' ' |
6be7c12c AO |
7391 | ac_uD='\4%g' |
7392 | # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE". | |
7393 | ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' | |
7394 | ac_eB='$%\1#\2define\3' | |
7395 | ac_eC=' ' | |
7396 | ac_eD='%g' | |
7397 | ||
7398 | if test "${CONFIG_HEADERS+set}" != set; then | |
7399 | EOF | |
7400 | cat >> $CONFIG_STATUS <<EOF | |
7401 | CONFIG_HEADERS="config.h:config.in" | |
7402 | EOF | |
7403 | cat >> $CONFIG_STATUS <<\EOF | |
7404 | fi | |
7405 | for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then | |
252b5132 | 7406 | # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". |
6be7c12c AO |
7407 | case "$ac_file" in |
7408 | *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'` | |
7409 | ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; | |
7410 | *) ac_file_in="${ac_file}.in" ;; | |
252b5132 RH |
7411 | esac |
7412 | ||
6be7c12c AO |
7413 | echo creating $ac_file |
7414 | ||
7415 | rm -f conftest.frag conftest.in conftest.out | |
7416 | ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"` | |
7417 | cat $ac_file_inputs > conftest.in | |
7418 | ||
7419 | EOF | |
7420 | ||
7421 | # Transform confdefs.h into a sed script conftest.vals that substitutes | |
7422 | # the proper values into config.h.in to produce config.h. And first: | |
7423 | # Protect against being on the right side of a sed subst in config.status. | |
7424 | # Protect against being in an unquoted here document in config.status. | |
7425 | rm -f conftest.vals | |
7426 | cat > conftest.hdr <<\EOF | |
7427 | s/[\\&%]/\\&/g | |
7428 | s%[\\$`]%\\&%g | |
7429 | s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp | |
7430 | s%ac_d%ac_u%gp | |
7431 | s%ac_u%ac_e%gp | |
7432 | EOF | |
7433 | sed -n -f conftest.hdr confdefs.h > conftest.vals | |
7434 | rm -f conftest.hdr | |
252b5132 RH |
7435 | |
7436 | # This sed command replaces #undef with comments. This is necessary, for | |
7437 | # example, in the case of _POSIX_SOURCE, which is predefined and required | |
7438 | # on some systems where configure will not decide to define it. | |
6be7c12c AO |
7439 | cat >> conftest.vals <<\EOF |
7440 | s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */% | |
252b5132 RH |
7441 | EOF |
7442 | ||
6be7c12c AO |
7443 | # Break up conftest.vals because some shells have a limit on |
7444 | # the size of here documents, and old seds have small limits too. | |
252b5132 RH |
7445 | |
7446 | rm -f conftest.tail | |
6be7c12c | 7447 | while : |
252b5132 | 7448 | do |
6be7c12c AO |
7449 | ac_lines=`grep -c . conftest.vals` |
7450 | # grep -c gives empty output for an empty file on some AIX systems. | |
7451 | if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi | |
7452 | # Write a limited-size here document to conftest.frag. | |
7453 | echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS | |
7454 | sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS | |
252b5132 | 7455 | echo 'CEOF |
6be7c12c AO |
7456 | sed -f conftest.frag conftest.in > conftest.out |
7457 | rm -f conftest.in | |
7458 | mv conftest.out conftest.in | |
7459 | ' >> $CONFIG_STATUS | |
7460 | sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail | |
7461 | rm -f conftest.vals | |
7462 | mv conftest.tail conftest.vals | |
252b5132 | 7463 | done |
6be7c12c AO |
7464 | rm -f conftest.vals |
7465 | ||
7466 | cat >> $CONFIG_STATUS <<\EOF | |
7467 | rm -f conftest.frag conftest.h | |
7468 | echo "/* $ac_file. Generated automatically by configure. */" > conftest.h | |
7469 | cat conftest.in >> conftest.h | |
7470 | rm -f conftest.in | |
7471 | if cmp -s $ac_file conftest.h 2>/dev/null; then | |
7472 | echo "$ac_file is unchanged" | |
7473 | rm -f conftest.h | |
252b5132 | 7474 | else |
6be7c12c AO |
7475 | # Remove last slash and all that follows it. Not all systems have dirname. |
7476 | ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` | |
252b5132 | 7477 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then |
6be7c12c AO |
7478 | # The file is in a subdirectory. |
7479 | test ! -d "$ac_dir" && mkdir "$ac_dir" | |
252b5132 | 7480 | fi |
6be7c12c AO |
7481 | rm -f $ac_file |
7482 | mv conftest.h $ac_file | |
252b5132 | 7483 | fi |
6be7c12c | 7484 | fi; done |
252b5132 RH |
7485 | |
7486 | EOF | |
6be7c12c | 7487 | cat >> $CONFIG_STATUS <<EOF |
b3baf5d0 | 7488 | |
b3baf5d0 | 7489 | |
6be7c12c AO |
7490 | EOF |
7491 | cat >> $CONFIG_STATUS <<\EOF | |
7492 | test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h | |
7493 | sed -e '/SRC-POTFILES =/r po/SRC-POTFILES' -e '/BLD-POTFILES =/r po/BLD-POTFILES' po/Makefile.in > po/Makefile | |
7494 | exit 0 | |
252b5132 RH |
7495 | EOF |
7496 | chmod +x $CONFIG_STATUS | |
6be7c12c AO |
7497 | rm -fr confdefs* $ac_clean_files |
7498 | test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1 | |
252b5132 | 7499 | |
55c80943 | 7500 |