Commit | Line | Data |
---|---|---|
252b5132 RH |
1 | #! /bin/sh |
2 | ||
3 | # Guess values for system-dependent variables and create Makefiles. | |
4 | # Generated automatically using autoconf version 2.13 | |
5 | # Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc. | |
6 | # | |
7 | # This configure script is free software; the Free Software Foundation | |
8 | # gives unlimited permission to copy, distribute and modify it. | |
9 | ||
10 | # Defaults: | |
11 | ac_help= | |
12 | ac_default_prefix=/usr/local | |
13 | # Any additions from configure.in: | |
14 | ac_help="$ac_help | |
15 | --enable-shared[=PKGS] build shared libraries [default=yes]" | |
16 | ac_help="$ac_help | |
17 | --enable-static[=PKGS] build static libraries [default=yes]" | |
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 | |
5af11cab | 23 | --disable-libtool-lock avoid locking (might break parallel builds)" |
ac48eca1 AO |
24 | ac_help="$ac_help |
25 | --with-pic try to use only PIC/non-PIC objects [default=use both]" | |
252b5132 RH |
26 | ac_help="$ac_help |
27 | --disable-nls do not use Native Language Support" | |
28 | ac_help="$ac_help | |
29 | --with-included-gettext use the GNU gettext library included here" | |
30 | ac_help="$ac_help | |
31 | --enable-maintainer-mode enable make rules and dependencies not useful | |
32 | (and sometimes confusing) to the casual installer" | |
a2d91340 AC |
33 | ac_help="$ac_help |
34 | --enable-build-warnings Enable build-time compiler warnings if gcc is used" | |
252b5132 RH |
35 | |
36 | # Initialize some variables set by options. | |
37 | # The variables have the same names as the options, with | |
38 | # dashes changed to underlines. | |
39 | build=NONE | |
40 | cache_file=./config.cache | |
41 | exec_prefix=NONE | |
42 | host=NONE | |
43 | no_create= | |
44 | nonopt=NONE | |
45 | no_recursion= | |
46 | prefix=NONE | |
47 | program_prefix=NONE | |
48 | program_suffix=NONE | |
49 | program_transform_name=s,x,x, | |
50 | silent= | |
51 | site= | |
27b7e12d | 52 | sitefile= |
252b5132 RH |
53 | srcdir= |
54 | target=NONE | |
55 | verbose= | |
56 | x_includes=NONE | |
57 | x_libraries=NONE | |
58 | bindir='${exec_prefix}/bin' | |
59 | sbindir='${exec_prefix}/sbin' | |
60 | libexecdir='${exec_prefix}/libexec' | |
61 | datadir='${prefix}/share' | |
62 | sysconfdir='${prefix}/etc' | |
63 | sharedstatedir='${prefix}/com' | |
64 | localstatedir='${prefix}/var' | |
65 | libdir='${exec_prefix}/lib' | |
66 | includedir='${prefix}/include' | |
67 | oldincludedir='/usr/include' | |
68 | infodir='${prefix}/info' | |
69 | mandir='${prefix}/man' | |
70 | ||
71 | # Initialize some other variables. | |
72 | subdirs= | |
73 | MFLAGS= MAKEFLAGS= | |
74 | SHELL=${CONFIG_SHELL-/bin/sh} | |
75 | # Maximum number of lines to put in a shell here document. | |
76 | ac_max_here_lines=12 | |
77 | ||
78 | ac_prev= | |
79 | for ac_option | |
80 | do | |
81 | ||
82 | # If the previous option needs an argument, assign it. | |
83 | if test -n "$ac_prev"; then | |
84 | eval "$ac_prev=\$ac_option" | |
85 | ac_prev= | |
86 | continue | |
87 | fi | |
88 | ||
89 | case "$ac_option" in | |
90 | -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;; | |
91 | *) ac_optarg= ;; | |
92 | esac | |
93 | ||
94 | # Accept the important Cygnus configure options, so we can diagnose typos. | |
95 | ||
96 | case "$ac_option" in | |
97 | ||
98 | -bindir | --bindir | --bindi | --bind | --bin | --bi) | |
99 | ac_prev=bindir ;; | |
100 | -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) | |
101 | bindir="$ac_optarg" ;; | |
102 | ||
103 | -build | --build | --buil | --bui | --bu) | |
104 | ac_prev=build ;; | |
105 | -build=* | --build=* | --buil=* | --bui=* | --bu=*) | |
106 | build="$ac_optarg" ;; | |
107 | ||
108 | -cache-file | --cache-file | --cache-fil | --cache-fi \ | |
109 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) | |
110 | ac_prev=cache_file ;; | |
111 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | |
112 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) | |
113 | cache_file="$ac_optarg" ;; | |
114 | ||
115 | -datadir | --datadir | --datadi | --datad | --data | --dat | --da) | |
116 | ac_prev=datadir ;; | |
117 | -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \ | |
118 | | --da=*) | |
119 | datadir="$ac_optarg" ;; | |
120 | ||
121 | -disable-* | --disable-*) | |
122 | ac_feature=`echo $ac_option|sed -e 's/-*disable-//'` | |
123 | # Reject names that are not valid shell variable names. | |
124 | if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then | |
125 | { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } | |
126 | fi | |
127 | ac_feature=`echo $ac_feature| sed 's/-/_/g'` | |
128 | eval "enable_${ac_feature}=no" ;; | |
129 | ||
130 | -enable-* | --enable-*) | |
131 | ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'` | |
132 | # Reject names that are not valid shell variable names. | |
133 | if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then | |
134 | { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } | |
135 | fi | |
136 | ac_feature=`echo $ac_feature| sed 's/-/_/g'` | |
137 | case "$ac_option" in | |
138 | *=*) ;; | |
139 | *) ac_optarg=yes ;; | |
140 | esac | |
141 | eval "enable_${ac_feature}='$ac_optarg'" ;; | |
142 | ||
143 | -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ | |
144 | | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ | |
145 | | --exec | --exe | --ex) | |
146 | ac_prev=exec_prefix ;; | |
147 | -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ | |
148 | | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ | |
149 | | --exec=* | --exe=* | --ex=*) | |
150 | exec_prefix="$ac_optarg" ;; | |
151 | ||
152 | -gas | --gas | --ga | --g) | |
153 | # Obsolete; use --with-gas. | |
154 | with_gas=yes ;; | |
155 | ||
156 | -help | --help | --hel | --he) | |
157 | # Omit some internal or obsolete options to make the list less imposing. | |
158 | # This message is too long to be a string in the A/UX 3.1 sh. | |
159 | cat << EOF | |
160 | Usage: configure [options] [host] | |
161 | Options: [defaults in brackets after descriptions] | |
162 | Configuration: | |
163 | --cache-file=FILE cache test results in FILE | |
164 | --help print this message | |
165 | --no-create do not create output files | |
166 | --quiet, --silent do not print \`checking...' messages | |
27b7e12d | 167 | --site-file=FILE use FILE as the site file |
252b5132 RH |
168 | --version print the version of autoconf that created configure |
169 | Directory and file names: | |
170 | --prefix=PREFIX install architecture-independent files in PREFIX | |
171 | [$ac_default_prefix] | |
172 | --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX | |
173 | [same as prefix] | |
174 | --bindir=DIR user executables in DIR [EPREFIX/bin] | |
175 | --sbindir=DIR system admin executables in DIR [EPREFIX/sbin] | |
176 | --libexecdir=DIR program executables in DIR [EPREFIX/libexec] | |
177 | --datadir=DIR read-only architecture-independent data in DIR | |
178 | [PREFIX/share] | |
179 | --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc] | |
180 | --sharedstatedir=DIR modifiable architecture-independent data in DIR | |
181 | [PREFIX/com] | |
182 | --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var] | |
183 | --libdir=DIR object code libraries in DIR [EPREFIX/lib] | |
184 | --includedir=DIR C header files in DIR [PREFIX/include] | |
185 | --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include] | |
186 | --infodir=DIR info documentation in DIR [PREFIX/info] | |
187 | --mandir=DIR man documentation in DIR [PREFIX/man] | |
188 | --srcdir=DIR find the sources in DIR [configure dir or ..] | |
189 | --program-prefix=PREFIX prepend PREFIX to installed program names | |
190 | --program-suffix=SUFFIX append SUFFIX to installed program names | |
191 | --program-transform-name=PROGRAM | |
192 | run sed PROGRAM on installed program names | |
193 | EOF | |
194 | cat << EOF | |
195 | Host type: | |
196 | --build=BUILD configure for building on BUILD [BUILD=HOST] | |
197 | --host=HOST configure for HOST [guessed] | |
198 | --target=TARGET configure for TARGET [TARGET=HOST] | |
199 | Features and packages: | |
200 | --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) | |
201 | --enable-FEATURE[=ARG] include FEATURE [ARG=yes] | |
202 | --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] | |
203 | --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) | |
204 | --x-includes=DIR X include files are in DIR | |
205 | --x-libraries=DIR X library files are in DIR | |
206 | EOF | |
207 | if test -n "$ac_help"; then | |
208 | echo "--enable and --with options recognized:$ac_help" | |
209 | fi | |
210 | exit 0 ;; | |
211 | ||
212 | -host | --host | --hos | --ho) | |
213 | ac_prev=host ;; | |
214 | -host=* | --host=* | --hos=* | --ho=*) | |
215 | host="$ac_optarg" ;; | |
216 | ||
217 | -includedir | --includedir | --includedi | --included | --include \ | |
218 | | --includ | --inclu | --incl | --inc) | |
219 | ac_prev=includedir ;; | |
220 | -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ | |
221 | | --includ=* | --inclu=* | --incl=* | --inc=*) | |
222 | includedir="$ac_optarg" ;; | |
223 | ||
224 | -infodir | --infodir | --infodi | --infod | --info | --inf) | |
225 | ac_prev=infodir ;; | |
226 | -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) | |
227 | infodir="$ac_optarg" ;; | |
228 | ||
229 | -libdir | --libdir | --libdi | --libd) | |
230 | ac_prev=libdir ;; | |
231 | -libdir=* | --libdir=* | --libdi=* | --libd=*) | |
232 | libdir="$ac_optarg" ;; | |
233 | ||
234 | -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ | |
235 | | --libexe | --libex | --libe) | |
236 | ac_prev=libexecdir ;; | |
237 | -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ | |
238 | | --libexe=* | --libex=* | --libe=*) | |
239 | libexecdir="$ac_optarg" ;; | |
240 | ||
241 | -localstatedir | --localstatedir | --localstatedi | --localstated \ | |
242 | | --localstate | --localstat | --localsta | --localst \ | |
243 | | --locals | --local | --loca | --loc | --lo) | |
244 | ac_prev=localstatedir ;; | |
245 | -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ | |
246 | | --localstate=* | --localstat=* | --localsta=* | --localst=* \ | |
247 | | --locals=* | --local=* | --loca=* | --loc=* | --lo=*) | |
248 | localstatedir="$ac_optarg" ;; | |
249 | ||
250 | -mandir | --mandir | --mandi | --mand | --man | --ma | --m) | |
251 | ac_prev=mandir ;; | |
252 | -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) | |
253 | mandir="$ac_optarg" ;; | |
254 | ||
255 | -nfp | --nfp | --nf) | |
256 | # Obsolete; use --without-fp. | |
257 | with_fp=no ;; | |
258 | ||
259 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | |
260 | | --no-cr | --no-c) | |
261 | no_create=yes ;; | |
262 | ||
263 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ | |
264 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) | |
265 | no_recursion=yes ;; | |
266 | ||
267 | -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ | |
268 | | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ | |
269 | | --oldin | --oldi | --old | --ol | --o) | |
270 | ac_prev=oldincludedir ;; | |
271 | -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ | |
272 | | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ | |
273 | | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) | |
274 | oldincludedir="$ac_optarg" ;; | |
275 | ||
276 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) | |
277 | ac_prev=prefix ;; | |
278 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) | |
279 | prefix="$ac_optarg" ;; | |
280 | ||
281 | -program-prefix | --program-prefix | --program-prefi | --program-pref \ | |
282 | | --program-pre | --program-pr | --program-p) | |
283 | ac_prev=program_prefix ;; | |
284 | -program-prefix=* | --program-prefix=* | --program-prefi=* \ | |
285 | | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) | |
286 | program_prefix="$ac_optarg" ;; | |
287 | ||
288 | -program-suffix | --program-suffix | --program-suffi | --program-suff \ | |
289 | | --program-suf | --program-su | --program-s) | |
290 | ac_prev=program_suffix ;; | |
291 | -program-suffix=* | --program-suffix=* | --program-suffi=* \ | |
292 | | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) | |
293 | program_suffix="$ac_optarg" ;; | |
294 | ||
295 | -program-transform-name | --program-transform-name \ | |
296 | | --program-transform-nam | --program-transform-na \ | |
297 | | --program-transform-n | --program-transform- \ | |
298 | | --program-transform | --program-transfor \ | |
299 | | --program-transfo | --program-transf \ | |
300 | | --program-trans | --program-tran \ | |
301 | | --progr-tra | --program-tr | --program-t) | |
302 | ac_prev=program_transform_name ;; | |
303 | -program-transform-name=* | --program-transform-name=* \ | |
304 | | --program-transform-nam=* | --program-transform-na=* \ | |
305 | | --program-transform-n=* | --program-transform-=* \ | |
306 | | --program-transform=* | --program-transfor=* \ | |
307 | | --program-transfo=* | --program-transf=* \ | |
308 | | --program-trans=* | --program-tran=* \ | |
309 | | --progr-tra=* | --program-tr=* | --program-t=*) | |
310 | program_transform_name="$ac_optarg" ;; | |
311 | ||
312 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | |
313 | | -silent | --silent | --silen | --sile | --sil) | |
314 | silent=yes ;; | |
315 | ||
316 | -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) | |
317 | ac_prev=sbindir ;; | |
318 | -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ | |
319 | | --sbi=* | --sb=*) | |
320 | sbindir="$ac_optarg" ;; | |
321 | ||
322 | -sharedstatedir | --sharedstatedir | --sharedstatedi \ | |
323 | | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ | |
324 | | --sharedst | --shareds | --shared | --share | --shar \ | |
325 | | --sha | --sh) | |
326 | ac_prev=sharedstatedir ;; | |
327 | -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ | |
328 | | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ | |
329 | | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ | |
330 | | --sha=* | --sh=*) | |
331 | sharedstatedir="$ac_optarg" ;; | |
332 | ||
333 | -site | --site | --sit) | |
334 | ac_prev=site ;; | |
335 | -site=* | --site=* | --sit=*) | |
336 | site="$ac_optarg" ;; | |
337 | ||
27b7e12d AM |
338 | -site-file | --site-file | --site-fil | --site-fi | --site-f) |
339 | ac_prev=sitefile ;; | |
340 | -site-file=* | --site-file=* | --site-fil=* | --site-fi=* | --site-f=*) | |
341 | sitefile="$ac_optarg" ;; | |
342 | ||
252b5132 RH |
343 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) |
344 | ac_prev=srcdir ;; | |
345 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) | |
346 | srcdir="$ac_optarg" ;; | |
347 | ||
348 | -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ | |
349 | | --syscon | --sysco | --sysc | --sys | --sy) | |
350 | ac_prev=sysconfdir ;; | |
351 | -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ | |
352 | | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) | |
353 | sysconfdir="$ac_optarg" ;; | |
354 | ||
355 | -target | --target | --targe | --targ | --tar | --ta | --t) | |
356 | ac_prev=target ;; | |
357 | -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) | |
358 | target="$ac_optarg" ;; | |
359 | ||
360 | -v | -verbose | --verbose | --verbos | --verbo | --verb) | |
361 | verbose=yes ;; | |
362 | ||
363 | -version | --version | --versio | --versi | --vers) | |
364 | echo "configure generated by autoconf version 2.13" | |
365 | exit 0 ;; | |
366 | ||
367 | -with-* | --with-*) | |
368 | ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'` | |
369 | # Reject names that are not valid shell variable names. | |
370 | if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then | |
371 | { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } | |
372 | fi | |
373 | ac_package=`echo $ac_package| sed 's/-/_/g'` | |
374 | case "$ac_option" in | |
375 | *=*) ;; | |
376 | *) ac_optarg=yes ;; | |
377 | esac | |
378 | eval "with_${ac_package}='$ac_optarg'" ;; | |
379 | ||
380 | -without-* | --without-*) | |
381 | ac_package=`echo $ac_option|sed -e 's/-*without-//'` | |
382 | # Reject names that are not valid shell variable names. | |
383 | if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then | |
384 | { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } | |
385 | fi | |
386 | ac_package=`echo $ac_package| sed 's/-/_/g'` | |
387 | eval "with_${ac_package}=no" ;; | |
388 | ||
389 | --x) | |
390 | # Obsolete; use --with-x. | |
391 | with_x=yes ;; | |
392 | ||
393 | -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ | |
394 | | --x-incl | --x-inc | --x-in | --x-i) | |
395 | ac_prev=x_includes ;; | |
396 | -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ | |
397 | | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) | |
398 | x_includes="$ac_optarg" ;; | |
399 | ||
400 | -x-libraries | --x-libraries | --x-librarie | --x-librari \ | |
401 | | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) | |
402 | ac_prev=x_libraries ;; | |
403 | -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ | |
404 | | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) | |
405 | x_libraries="$ac_optarg" ;; | |
406 | ||
407 | -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; } | |
408 | ;; | |
409 | ||
410 | *) | |
411 | if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then | |
412 | echo "configure: warning: $ac_option: invalid host type" 1>&2 | |
413 | fi | |
414 | if test "x$nonopt" != xNONE; then | |
415 | { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } | |
416 | fi | |
417 | nonopt="$ac_option" | |
418 | ;; | |
419 | ||
420 | esac | |
421 | done | |
422 | ||
423 | if test -n "$ac_prev"; then | |
424 | { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; } | |
425 | fi | |
426 | ||
427 | trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 | |
428 | ||
429 | # File descriptor usage: | |
430 | # 0 standard input | |
431 | # 1 file creation | |
432 | # 2 errors and warnings | |
433 | # 3 some systems may open it to /dev/tty | |
434 | # 4 used on the Kubota Titan | |
435 | # 6 checking for... messages and results | |
436 | # 5 compiler messages saved in config.log | |
437 | if test "$silent" = yes; then | |
438 | exec 6>/dev/null | |
439 | else | |
440 | exec 6>&1 | |
441 | fi | |
442 | exec 5>./config.log | |
443 | ||
444 | echo "\ | |
445 | This file contains any messages produced by compilers while | |
446 | running configure, to aid debugging if configure makes a mistake. | |
447 | " 1>&5 | |
448 | ||
449 | # Strip out --no-create and --no-recursion so they do not pile up. | |
450 | # Also quote any args containing shell metacharacters. | |
451 | ac_configure_args= | |
452 | for ac_arg | |
453 | do | |
454 | case "$ac_arg" in | |
455 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | |
456 | | --no-cr | --no-c) ;; | |
457 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ | |
458 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;; | |
459 | *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*) | |
460 | ac_configure_args="$ac_configure_args '$ac_arg'" ;; | |
461 | *) ac_configure_args="$ac_configure_args $ac_arg" ;; | |
462 | esac | |
463 | done | |
464 | ||
465 | # NLS nuisances. | |
466 | # Only set these to C if already set. These must not be set unconditionally | |
467 | # because not all systems understand e.g. LANG=C (notably SCO). | |
468 | # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'! | |
469 | # Non-C LC_CTYPE values break the ctype check. | |
470 | if test "${LANG+set}" = set; then LANG=C; export LANG; fi | |
471 | if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi | |
472 | if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi | |
473 | if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi | |
474 | ||
475 | # confdefs.h avoids OS command line length limits that DEFS can exceed. | |
476 | rm -rf conftest* confdefs.h | |
477 | # AIX cpp loses on an empty file, so make sure it contains at least a newline. | |
478 | echo > confdefs.h | |
479 | ||
480 | # A filename unique to this package, relative to the directory that | |
481 | # configure is in, which we can look for to find out if srcdir is correct. | |
482 | ac_unique_file=gprof.c | |
483 | ||
484 | # Find the source files, if location was not specified. | |
485 | if test -z "$srcdir"; then | |
486 | ac_srcdir_defaulted=yes | |
487 | # Try the directory containing this script, then its parent. | |
488 | ac_prog=$0 | |
489 | ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'` | |
490 | test "x$ac_confdir" = "x$ac_prog" && ac_confdir=. | |
491 | srcdir=$ac_confdir | |
492 | if test ! -r $srcdir/$ac_unique_file; then | |
493 | srcdir=.. | |
494 | fi | |
495 | else | |
496 | ac_srcdir_defaulted=no | |
497 | fi | |
498 | if test ! -r $srcdir/$ac_unique_file; then | |
499 | if test "$ac_srcdir_defaulted" = yes; then | |
500 | { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; } | |
501 | else | |
502 | { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; } | |
503 | fi | |
504 | fi | |
505 | srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'` | |
506 | ||
507 | # Prefer explicitly selected file to automatically selected ones. | |
27b7e12d AM |
508 | if test -z "$sitefile"; then |
509 | if test -z "$CONFIG_SITE"; then | |
510 | if test "x$prefix" != xNONE; then | |
511 | CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site" | |
512 | else | |
513 | CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site" | |
514 | fi | |
252b5132 | 515 | fi |
27b7e12d AM |
516 | else |
517 | CONFIG_SITE="$sitefile" | |
252b5132 RH |
518 | fi |
519 | for ac_site_file in $CONFIG_SITE; do | |
520 | if test -r "$ac_site_file"; then | |
521 | echo "loading site script $ac_site_file" | |
522 | . "$ac_site_file" | |
523 | fi | |
524 | done | |
525 | ||
526 | if test -r "$cache_file"; then | |
527 | echo "loading cache $cache_file" | |
528 | . $cache_file | |
529 | else | |
530 | echo "creating cache $cache_file" | |
531 | > $cache_file | |
532 | fi | |
533 | ||
534 | ac_ext=c | |
535 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. | |
536 | ac_cpp='$CPP $CPPFLAGS' | |
537 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' | |
538 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' | |
539 | cross_compiling=$ac_cv_prog_cc_cross | |
540 | ||
541 | ac_exeext= | |
542 | ac_objext=o | |
543 | if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then | |
544 | # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu. | |
545 | if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then | |
546 | ac_n= ac_c=' | |
547 | ' ac_t=' ' | |
548 | else | |
549 | ac_n=-n ac_c= ac_t= | |
550 | fi | |
551 | else | |
552 | ac_n= ac_c='\c' ac_t= | |
553 | fi | |
554 | ||
ac48eca1 | 555 | echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6 |
27b7e12d | 556 | echo "configure:557: checking for Cygwin environment" >&5 |
ac48eca1 AO |
557 | if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then |
558 | echo $ac_n "(cached) $ac_c" 1>&6 | |
559 | else | |
560 | cat > conftest.$ac_ext <<EOF | |
27b7e12d | 561 | #line 562 "configure" |
ac48eca1 AO |
562 | #include "confdefs.h" |
563 | ||
564 | int main() { | |
565 | ||
566 | #ifndef __CYGWIN__ | |
567 | #define __CYGWIN__ __CYGWIN32__ | |
568 | #endif | |
569 | return __CYGWIN__; | |
570 | ; return 0; } | |
571 | EOF | |
27b7e12d | 572 | if { (eval echo configure:573: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
ac48eca1 AO |
573 | rm -rf conftest* |
574 | ac_cv_cygwin=yes | |
575 | else | |
576 | echo "configure: failed program was:" >&5 | |
577 | cat conftest.$ac_ext >&5 | |
578 | rm -rf conftest* | |
579 | ac_cv_cygwin=no | |
580 | fi | |
581 | rm -f conftest* | |
582 | rm -f conftest* | |
583 | fi | |
584 | ||
585 | echo "$ac_t""$ac_cv_cygwin" 1>&6 | |
586 | CYGWIN= | |
587 | test "$ac_cv_cygwin" = yes && CYGWIN=yes | |
588 | echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6 | |
27b7e12d | 589 | echo "configure:590: checking for mingw32 environment" >&5 |
ac48eca1 AO |
590 | if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then |
591 | echo $ac_n "(cached) $ac_c" 1>&6 | |
592 | else | |
593 | cat > conftest.$ac_ext <<EOF | |
27b7e12d | 594 | #line 595 "configure" |
ac48eca1 AO |
595 | #include "confdefs.h" |
596 | ||
597 | int main() { | |
598 | return __MINGW32__; | |
599 | ; return 0; } | |
600 | EOF | |
27b7e12d | 601 | if { (eval echo configure:602: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
ac48eca1 AO |
602 | rm -rf conftest* |
603 | ac_cv_mingw32=yes | |
604 | else | |
605 | echo "configure: failed program was:" >&5 | |
606 | cat conftest.$ac_ext >&5 | |
607 | rm -rf conftest* | |
608 | ac_cv_mingw32=no | |
609 | fi | |
610 | rm -f conftest* | |
611 | rm -f conftest* | |
612 | fi | |
613 | ||
614 | echo "$ac_t""$ac_cv_mingw32" 1>&6 | |
615 | MINGW32= | |
616 | test "$ac_cv_mingw32" = yes && MINGW32=yes | |
252b5132 RH |
617 | |
618 | ||
619 | ac_aux_dir= | |
620 | for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do | |
621 | if test -f $ac_dir/install-sh; then | |
622 | ac_aux_dir=$ac_dir | |
623 | ac_install_sh="$ac_aux_dir/install-sh -c" | |
624 | break | |
625 | elif test -f $ac_dir/install.sh; then | |
626 | ac_aux_dir=$ac_dir | |
627 | ac_install_sh="$ac_aux_dir/install.sh -c" | |
628 | break | |
629 | fi | |
630 | done | |
631 | if test -z "$ac_aux_dir"; then | |
632 | { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; } | |
633 | fi | |
634 | ac_config_guess=$ac_aux_dir/config.guess | |
635 | ac_config_sub=$ac_aux_dir/config.sub | |
636 | ac_configure=$ac_aux_dir/configure # This should be Cygnus configure. | |
637 | ||
638 | ||
639 | # Do some error checking and defaulting for the host and target type. | |
640 | # The inputs are: | |
641 | # configure --host=HOST --target=TARGET --build=BUILD NONOPT | |
642 | # | |
643 | # The rules are: | |
644 | # 1. You are not allowed to specify --host, --target, and nonopt at the | |
645 | # same time. | |
646 | # 2. Host defaults to nonopt. | |
647 | # 3. If nonopt is not specified, then host defaults to the current host, | |
648 | # as determined by config.guess. | |
649 | # 4. Target and build default to nonopt. | |
650 | # 5. If nonopt is not specified, then target and build default to host. | |
651 | ||
652 | # The aliases save the names the user supplied, while $host etc. | |
653 | # will get canonicalized. | |
654 | case $host---$target---$nonopt in | |
655 | NONE---*---* | *---NONE---* | *---*---NONE) ;; | |
656 | *) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;; | |
657 | esac | |
658 | ||
659 | ||
660 | # Make sure we can run config.sub. | |
661 | if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then : | |
662 | else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; } | |
663 | fi | |
664 | ||
665 | echo $ac_n "checking host system type""... $ac_c" 1>&6 | |
27b7e12d | 666 | echo "configure:667: checking host system type" >&5 |
252b5132 RH |
667 | |
668 | host_alias=$host | |
669 | case "$host_alias" in | |
670 | NONE) | |
671 | case $nonopt in | |
672 | NONE) | |
673 | if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then : | |
674 | else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; } | |
675 | fi ;; | |
676 | *) host_alias=$nonopt ;; | |
677 | esac ;; | |
678 | esac | |
679 | ||
680 | host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias` | |
681 | host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` | |
682 | host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` | |
683 | host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` | |
684 | echo "$ac_t""$host" 1>&6 | |
685 | ||
686 | echo $ac_n "checking target system type""... $ac_c" 1>&6 | |
27b7e12d | 687 | echo "configure:688: checking target system type" >&5 |
252b5132 RH |
688 | |
689 | target_alias=$target | |
690 | case "$target_alias" in | |
691 | NONE) | |
692 | case $nonopt in | |
693 | NONE) target_alias=$host_alias ;; | |
694 | *) target_alias=$nonopt ;; | |
695 | esac ;; | |
696 | esac | |
697 | ||
698 | target=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $target_alias` | |
699 | target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` | |
700 | target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` | |
701 | target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` | |
702 | echo "$ac_t""$target" 1>&6 | |
703 | ||
704 | echo $ac_n "checking build system type""... $ac_c" 1>&6 | |
27b7e12d | 705 | echo "configure:706: checking build system type" >&5 |
252b5132 RH |
706 | |
707 | build_alias=$build | |
708 | case "$build_alias" in | |
709 | NONE) | |
710 | case $nonopt in | |
711 | NONE) build_alias=$host_alias ;; | |
712 | *) build_alias=$nonopt ;; | |
713 | esac ;; | |
714 | esac | |
715 | ||
716 | build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias` | |
717 | build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` | |
718 | build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` | |
719 | build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` | |
720 | echo "$ac_t""$build" 1>&6 | |
721 | ||
722 | test "$host_alias" != "$target_alias" && | |
723 | test "$program_prefix$program_suffix$program_transform_name" = \ | |
724 | NONENONEs,x,x, && | |
725 | program_prefix=${target_alias}- | |
726 | ||
5d64ca4e | 727 | |
37503931 NC |
728 | echo $ac_n "checking for strerror in -lcposix""... $ac_c" 1>&6 |
729 | echo "configure:730: checking for strerror in -lcposix" >&5 | |
730 | ac_lib_var=`echo cposix'_'strerror | sed 'y%./+-%__p_%'` | |
731 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then | |
5d64ca4e L |
732 | echo $ac_n "(cached) $ac_c" 1>&6 |
733 | else | |
37503931 NC |
734 | ac_save_LIBS="$LIBS" |
735 | LIBS="-lcposix $LIBS" | |
736 | cat > conftest.$ac_ext <<EOF | |
737 | #line 738 "configure" | |
5d64ca4e | 738 | #include "confdefs.h" |
37503931 NC |
739 | /* Override any gcc2 internal prototype to avoid an error. */ |
740 | /* We use char because int might match the return type of a gcc2 | |
741 | builtin and then its argument prototype would still apply. */ | |
742 | char strerror(); | |
5d64ca4e | 743 | |
37503931 NC |
744 | int main() { |
745 | strerror() | |
746 | ; return 0; } | |
5d64ca4e | 747 | EOF |
37503931 NC |
748 | if { (eval echo configure:749: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
749 | rm -rf conftest* | |
750 | eval "ac_cv_lib_$ac_lib_var=yes" | |
5d64ca4e L |
751 | else |
752 | echo "configure: failed program was:" >&5 | |
753 | cat conftest.$ac_ext >&5 | |
37503931 NC |
754 | rm -rf conftest* |
755 | eval "ac_cv_lib_$ac_lib_var=no" | |
5d64ca4e L |
756 | fi |
757 | rm -f conftest* | |
37503931 | 758 | LIBS="$ac_save_LIBS" |
5d64ca4e L |
759 | |
760 | fi | |
37503931 | 761 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
5d64ca4e | 762 | echo "$ac_t""yes" 1>&6 |
37503931 | 763 | LIBS="$LIBS -lcposix" |
5d64ca4e L |
764 | else |
765 | echo "$ac_t""no" 1>&6 | |
5d64ca4e L |
766 | fi |
767 | ||
37503931 NC |
768 | |
769 | ||
252b5132 | 770 | |
27b7e12d | 771 | BFD_VERSION=`sed -n -e 's/^.._INIT_AUTOMAKE.*,[ ]*\([^ ]*\)[ ]*).*/\1/p' < ${srcdir}/../bfd/configure.in` |
252b5132 RH |
772 | # Find a good install program. We prefer a C program (faster), |
773 | # so one script is as good as another. But avoid the broken or | |
774 | # incompatible versions: | |
775 | # SysV /etc/install, /usr/sbin/install | |
776 | # SunOS /usr/etc/install | |
777 | # IRIX /sbin/install | |
778 | # AIX /bin/install | |
779 | # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag | |
780 | # AFS /usr/afsws/bin/install, which mishandles nonexistent args | |
781 | # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" | |
782 | # ./install, which can be erroneously created by make from ./install.sh. | |
783 | echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6 | |
37503931 | 784 | echo "configure:785: checking for a BSD compatible install" >&5 |
252b5132 RH |
785 | if test -z "$INSTALL"; then |
786 | if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then | |
787 | echo $ac_n "(cached) $ac_c" 1>&6 | |
788 | else | |
789 | IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":" | |
790 | for ac_dir in $PATH; do | |
791 | # Account for people who put trailing slashes in PATH elements. | |
792 | case "$ac_dir/" in | |
793 | /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;; | |
794 | *) | |
795 | # OSF1 and SCO ODT 3.0 have their own names for install. | |
796 | # Don't use installbsd from OSF since it installs stuff as root | |
797 | # by default. | |
798 | for ac_prog in ginstall scoinst install; do | |
799 | if test -f $ac_dir/$ac_prog; then | |
800 | if test $ac_prog = install && | |
801 | grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then | |
802 | # AIX install. It has an incompatible calling convention. | |
803 | : | |
804 | else | |
805 | ac_cv_path_install="$ac_dir/$ac_prog -c" | |
806 | break 2 | |
807 | fi | |
808 | fi | |
809 | done | |
810 | ;; | |
811 | esac | |
812 | done | |
813 | IFS="$ac_save_IFS" | |
814 | ||
815 | fi | |
816 | if test "${ac_cv_path_install+set}" = set; then | |
817 | INSTALL="$ac_cv_path_install" | |
818 | else | |
819 | # As a last resort, use the slow shell script. We don't cache a | |
820 | # path for INSTALL within a source directory, because that will | |
821 | # break other packages using the cache if that directory is | |
822 | # removed, or if the path is relative. | |
823 | INSTALL="$ac_install_sh" | |
824 | fi | |
825 | fi | |
826 | echo "$ac_t""$INSTALL" 1>&6 | |
827 | ||
828 | # Use test -z because SunOS4 sh mishandles braces in ${var-val}. | |
829 | # It thinks the first close brace ends the variable substitution. | |
830 | test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' | |
831 | ||
832 | test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}' | |
833 | ||
834 | test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' | |
835 | ||
836 | echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6 | |
37503931 | 837 | echo "configure:838: checking whether build environment is sane" >&5 |
252b5132 RH |
838 | # Just in case |
839 | sleep 1 | |
840 | echo timestamp > conftestfile | |
841 | # Do `set' in a subshell so we don't clobber the current shell's | |
842 | # arguments. Must try -L first in case configure is actually a | |
843 | # symlink; some systems play weird games with the mod time of symlinks | |
844 | # (eg FreeBSD returns the mod time of the symlink's containing | |
845 | # directory). | |
846 | if ( | |
847 | set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null` | |
848 | if test "$*" = "X"; then | |
849 | # -L didn't work. | |
850 | set X `ls -t $srcdir/configure conftestfile` | |
851 | fi | |
852 | if test "$*" != "X $srcdir/configure conftestfile" \ | |
853 | && test "$*" != "X conftestfile $srcdir/configure"; then | |
854 | ||
855 | # If neither matched, then we have a broken ls. This can happen | |
856 | # if, for instance, CONFIG_SHELL is bash and it inherits a | |
857 | # broken ls alias from the environment. This has actually | |
858 | # happened. Such a system could not be considered "sane". | |
859 | { echo "configure: error: ls -t appears to fail. Make sure there is not a broken | |
860 | alias in your environment" 1>&2; exit 1; } | |
861 | fi | |
862 | ||
863 | test "$2" = conftestfile | |
864 | ) | |
865 | then | |
866 | # Ok. | |
867 | : | |
868 | else | |
869 | { echo "configure: error: newly created file is older than distributed files! | |
870 | Check your system clock" 1>&2; exit 1; } | |
871 | fi | |
872 | rm -f conftest* | |
873 | echo "$ac_t""yes" 1>&6 | |
874 | if test "$program_transform_name" = s,x,x,; then | |
875 | program_transform_name= | |
876 | else | |
877 | # Double any \ or $. echo might interpret backslashes. | |
878 | cat <<\EOF_SED > conftestsed | |
879 | s,\\,\\\\,g; s,\$,$$,g | |
880 | EOF_SED | |
881 | program_transform_name="`echo $program_transform_name|sed -f conftestsed`" | |
882 | rm -f conftestsed | |
883 | fi | |
884 | test "$program_prefix" != NONE && | |
885 | program_transform_name="s,^,${program_prefix},; $program_transform_name" | |
886 | # Use a double $ so make ignores it. | |
887 | test "$program_suffix" != NONE && | |
888 | program_transform_name="s,\$\$,${program_suffix},; $program_transform_name" | |
889 | ||
890 | # sed with no file args requires a program. | |
891 | test "$program_transform_name" = "" && program_transform_name="s,x,x," | |
892 | ||
893 | echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6 | |
37503931 | 894 | echo "configure:895: checking whether ${MAKE-make} sets \${MAKE}" >&5 |
252b5132 RH |
895 | set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'` |
896 | if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then | |
897 | echo $ac_n "(cached) $ac_c" 1>&6 | |
898 | else | |
899 | cat > conftestmake <<\EOF | |
900 | all: | |
901 | @echo 'ac_maketemp="${MAKE}"' | |
902 | EOF | |
903 | # GNU make sometimes prints "make[1]: Entering...", which would confuse us. | |
904 | eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=` | |
905 | if test -n "$ac_maketemp"; then | |
906 | eval ac_cv_prog_make_${ac_make}_set=yes | |
907 | else | |
908 | eval ac_cv_prog_make_${ac_make}_set=no | |
909 | fi | |
910 | rm -f conftestmake | |
911 | fi | |
912 | if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then | |
913 | echo "$ac_t""yes" 1>&6 | |
914 | SET_MAKE= | |
915 | else | |
916 | echo "$ac_t""no" 1>&6 | |
917 | SET_MAKE="MAKE=${MAKE-make}" | |
918 | fi | |
919 | ||
920 | ||
921 | PACKAGE=gprof | |
922 | ||
27b7e12d | 923 | VERSION=${BFD_VERSION} |
252b5132 RH |
924 | |
925 | if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then | |
926 | { echo "configure: error: source directory already configured; run "make distclean" there first" 1>&2; exit 1; } | |
927 | fi | |
928 | cat >> confdefs.h <<EOF | |
929 | #define PACKAGE "$PACKAGE" | |
930 | EOF | |
931 | ||
932 | cat >> confdefs.h <<EOF | |
933 | #define VERSION "$VERSION" | |
934 | EOF | |
935 | ||
936 | ||
937 | ||
938 | missing_dir=`cd $ac_aux_dir && pwd` | |
939 | echo $ac_n "checking for working aclocal""... $ac_c" 1>&6 | |
37503931 | 940 | echo "configure:941: checking for working aclocal" >&5 |
252b5132 RH |
941 | # Run test in a subshell; some versions of sh will print an error if |
942 | # an executable is not found, even if stderr is redirected. | |
943 | # Redirect stdin to placate older versions of autoconf. Sigh. | |
944 | if (aclocal --version) < /dev/null > /dev/null 2>&1; then | |
945 | ACLOCAL=aclocal | |
946 | echo "$ac_t""found" 1>&6 | |
947 | else | |
948 | ACLOCAL="$missing_dir/missing aclocal" | |
949 | echo "$ac_t""missing" 1>&6 | |
950 | fi | |
951 | ||
952 | echo $ac_n "checking for working autoconf""... $ac_c" 1>&6 | |
37503931 | 953 | echo "configure:954: checking for working autoconf" >&5 |
252b5132 RH |
954 | # Run test in a subshell; some versions of sh will print an error if |
955 | # an executable is not found, even if stderr is redirected. | |
956 | # Redirect stdin to placate older versions of autoconf. Sigh. | |
957 | if (autoconf --version) < /dev/null > /dev/null 2>&1; then | |
958 | AUTOCONF=autoconf | |
959 | echo "$ac_t""found" 1>&6 | |
960 | else | |
961 | AUTOCONF="$missing_dir/missing autoconf" | |
962 | echo "$ac_t""missing" 1>&6 | |
963 | fi | |
964 | ||
965 | echo $ac_n "checking for working automake""... $ac_c" 1>&6 | |
37503931 | 966 | echo "configure:967: checking for working automake" >&5 |
252b5132 RH |
967 | # Run test in a subshell; some versions of sh will print an error if |
968 | # an executable is not found, even if stderr is redirected. | |
969 | # Redirect stdin to placate older versions of autoconf. Sigh. | |
970 | if (automake --version) < /dev/null > /dev/null 2>&1; then | |
971 | AUTOMAKE=automake | |
972 | echo "$ac_t""found" 1>&6 | |
973 | else | |
974 | AUTOMAKE="$missing_dir/missing automake" | |
975 | echo "$ac_t""missing" 1>&6 | |
976 | fi | |
977 | ||
978 | echo $ac_n "checking for working autoheader""... $ac_c" 1>&6 | |
37503931 | 979 | echo "configure:980: checking for working autoheader" >&5 |
252b5132 RH |
980 | # Run test in a subshell; some versions of sh will print an error if |
981 | # an executable is not found, even if stderr is redirected. | |
982 | # Redirect stdin to placate older versions of autoconf. Sigh. | |
983 | if (autoheader --version) < /dev/null > /dev/null 2>&1; then | |
984 | AUTOHEADER=autoheader | |
985 | echo "$ac_t""found" 1>&6 | |
986 | else | |
987 | AUTOHEADER="$missing_dir/missing autoheader" | |
988 | echo "$ac_t""missing" 1>&6 | |
989 | fi | |
990 | ||
991 | echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6 | |
37503931 | 992 | echo "configure:993: checking for working makeinfo" >&5 |
252b5132 RH |
993 | # Run test in a subshell; some versions of sh will print an error if |
994 | # an executable is not found, even if stderr is redirected. | |
995 | # Redirect stdin to placate older versions of autoconf. Sigh. | |
996 | if (makeinfo --version) < /dev/null > /dev/null 2>&1; then | |
997 | MAKEINFO=makeinfo | |
998 | echo "$ac_t""found" 1>&6 | |
999 | else | |
1000 | MAKEINFO="$missing_dir/missing makeinfo" | |
1001 | echo "$ac_t""missing" 1>&6 | |
1002 | fi | |
1003 | ||
1004 | ||
1005 | ||
1006 | # Check whether --enable-shared or --disable-shared was given. | |
1007 | if test "${enable_shared+set}" = set; then | |
1008 | enableval="$enable_shared" | |
1009 | p=${PACKAGE-default} | |
1010 | case "$enableval" in | |
1011 | yes) enable_shared=yes ;; | |
1012 | no) enable_shared=no ;; | |
1013 | *) | |
1014 | enable_shared=no | |
1015 | # Look at the argument we got. We use all the common list separators. | |
1016 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:," | |
1017 | for pkg in $enableval; do | |
1018 | if test "X$pkg" = "X$p"; then | |
1019 | enable_shared=yes | |
1020 | fi | |
1021 | done | |
1022 | IFS="$ac_save_ifs" | |
1023 | ;; | |
1024 | esac | |
1025 | else | |
1026 | enable_shared=yes | |
1027 | fi | |
1028 | ||
1029 | # Check whether --enable-static or --disable-static was given. | |
1030 | if test "${enable_static+set}" = set; then | |
1031 | enableval="$enable_static" | |
1032 | p=${PACKAGE-default} | |
1033 | case "$enableval" in | |
1034 | yes) enable_static=yes ;; | |
1035 | no) enable_static=no ;; | |
1036 | *) | |
1037 | enable_static=no | |
1038 | # Look at the argument we got. We use all the common list separators. | |
1039 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:," | |
1040 | for pkg in $enableval; do | |
1041 | if test "X$pkg" = "X$p"; then | |
1042 | enable_static=yes | |
1043 | fi | |
1044 | done | |
1045 | IFS="$ac_save_ifs" | |
1046 | ;; | |
1047 | esac | |
1048 | else | |
1049 | enable_static=yes | |
1050 | fi | |
1051 | ||
1052 | # Check whether --enable-fast-install or --disable-fast-install was given. | |
1053 | if test "${enable_fast_install+set}" = set; then | |
1054 | enableval="$enable_fast_install" | |
1055 | p=${PACKAGE-default} | |
1056 | case "$enableval" in | |
1057 | yes) enable_fast_install=yes ;; | |
1058 | no) enable_fast_install=no ;; | |
1059 | *) | |
1060 | enable_fast_install=no | |
1061 | # Look at the argument we got. We use all the common list separators. | |
1062 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:," | |
1063 | for pkg in $enableval; do | |
1064 | if test "X$pkg" = "X$p"; then | |
1065 | enable_fast_install=yes | |
1066 | fi | |
1067 | done | |
1068 | IFS="$ac_save_ifs" | |
1069 | ;; | |
1070 | esac | |
1071 | else | |
1072 | enable_fast_install=yes | |
1073 | fi | |
1074 | ||
37503931 NC |
1075 | # Extract the first word of "gcc", so it can be a program name with args. |
1076 | set dummy gcc; ac_word=$2 | |
1077 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
1078 | echo "configure:1079: checking for $ac_word" >&5 | |
1079 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then | |
1080 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1081 | else | |
1082 | if test -n "$CC"; then | |
1083 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
1084 | else | |
1085 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
1086 | ac_dummy="$PATH" | |
1087 | for ac_dir in $ac_dummy; do | |
1088 | test -z "$ac_dir" && ac_dir=. | |
1089 | if test -f $ac_dir/$ac_word; then | |
1090 | ac_cv_prog_CC="gcc" | |
1091 | break | |
1092 | fi | |
1093 | done | |
1094 | IFS="$ac_save_ifs" | |
1095 | fi | |
1096 | fi | |
1097 | CC="$ac_cv_prog_CC" | |
1098 | if test -n "$CC"; then | |
1099 | echo "$ac_t""$CC" 1>&6 | |
1100 | else | |
1101 | echo "$ac_t""no" 1>&6 | |
1102 | fi | |
1103 | ||
1104 | if test -z "$CC"; then | |
1105 | # Extract the first word of "cc", so it can be a program name with args. | |
1106 | set dummy cc; ac_word=$2 | |
1107 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
1108 | echo "configure:1109: checking for $ac_word" >&5 | |
1109 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then | |
1110 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1111 | else | |
1112 | if test -n "$CC"; then | |
1113 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
1114 | else | |
1115 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
1116 | ac_prog_rejected=no | |
1117 | ac_dummy="$PATH" | |
1118 | for ac_dir in $ac_dummy; do | |
1119 | test -z "$ac_dir" && ac_dir=. | |
1120 | if test -f $ac_dir/$ac_word; then | |
1121 | if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then | |
1122 | ac_prog_rejected=yes | |
1123 | continue | |
1124 | fi | |
1125 | ac_cv_prog_CC="cc" | |
1126 | break | |
1127 | fi | |
1128 | done | |
1129 | IFS="$ac_save_ifs" | |
1130 | if test $ac_prog_rejected = yes; then | |
1131 | # We found a bogon in the path, so make sure we never use it. | |
1132 | set dummy $ac_cv_prog_CC | |
1133 | shift | |
1134 | if test $# -gt 0; then | |
1135 | # We chose a different compiler from the bogus one. | |
1136 | # However, it has the same basename, so the bogon will be chosen | |
1137 | # first if we set CC to just the basename; use the full file name. | |
1138 | shift | |
1139 | set dummy "$ac_dir/$ac_word" "$@" | |
1140 | shift | |
1141 | ac_cv_prog_CC="$@" | |
1142 | fi | |
1143 | fi | |
1144 | fi | |
1145 | fi | |
1146 | CC="$ac_cv_prog_CC" | |
1147 | if test -n "$CC"; then | |
1148 | echo "$ac_t""$CC" 1>&6 | |
1149 | else | |
1150 | echo "$ac_t""no" 1>&6 | |
1151 | fi | |
1152 | ||
1153 | if test -z "$CC"; then | |
1154 | case "`uname -s`" in | |
1155 | *win32* | *WIN32*) | |
1156 | # Extract the first word of "cl", so it can be a program name with args. | |
1157 | set dummy cl; ac_word=$2 | |
1158 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
1159 | echo "configure:1160: checking for $ac_word" >&5 | |
1160 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then | |
1161 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1162 | else | |
1163 | if test -n "$CC"; then | |
1164 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
1165 | else | |
1166 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
1167 | ac_dummy="$PATH" | |
1168 | for ac_dir in $ac_dummy; do | |
1169 | test -z "$ac_dir" && ac_dir=. | |
1170 | if test -f $ac_dir/$ac_word; then | |
1171 | ac_cv_prog_CC="cl" | |
1172 | break | |
1173 | fi | |
1174 | done | |
1175 | IFS="$ac_save_ifs" | |
1176 | fi | |
1177 | fi | |
1178 | CC="$ac_cv_prog_CC" | |
1179 | if test -n "$CC"; then | |
1180 | echo "$ac_t""$CC" 1>&6 | |
1181 | else | |
1182 | echo "$ac_t""no" 1>&6 | |
1183 | fi | |
1184 | ;; | |
1185 | esac | |
1186 | fi | |
1187 | test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; } | |
1188 | fi | |
1189 | ||
1190 | echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 | |
1191 | echo "configure:1192: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 | |
1192 | ||
1193 | ac_ext=c | |
1194 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. | |
1195 | ac_cpp='$CPP $CPPFLAGS' | |
1196 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' | |
1197 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' | |
1198 | cross_compiling=$ac_cv_prog_cc_cross | |
1199 | ||
1200 | cat > conftest.$ac_ext << EOF | |
1201 | ||
1202 | #line 1203 "configure" | |
1203 | #include "confdefs.h" | |
1204 | ||
1205 | main(){return(0);} | |
1206 | EOF | |
1207 | if { (eval echo configure:1208: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | |
1208 | ac_cv_prog_cc_works=yes | |
1209 | # If we can't run a trivial program, we are probably using a cross compiler. | |
1210 | if (./conftest; exit) 2>/dev/null; then | |
1211 | ac_cv_prog_cc_cross=no | |
1212 | else | |
1213 | ac_cv_prog_cc_cross=yes | |
1214 | fi | |
1215 | else | |
1216 | echo "configure: failed program was:" >&5 | |
1217 | cat conftest.$ac_ext >&5 | |
1218 | ac_cv_prog_cc_works=no | |
1219 | fi | |
1220 | rm -fr conftest* | |
1221 | ac_ext=c | |
1222 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. | |
1223 | ac_cpp='$CPP $CPPFLAGS' | |
1224 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' | |
1225 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' | |
1226 | cross_compiling=$ac_cv_prog_cc_cross | |
1227 | ||
1228 | echo "$ac_t""$ac_cv_prog_cc_works" 1>&6 | |
1229 | if test $ac_cv_prog_cc_works = no; then | |
1230 | { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; } | |
1231 | fi | |
1232 | echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 | |
1233 | echo "configure:1234: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 | |
1234 | echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6 | |
1235 | cross_compiling=$ac_cv_prog_cc_cross | |
1236 | ||
1237 | echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6 | |
1238 | echo "configure:1239: checking whether we are using GNU C" >&5 | |
1239 | if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then | |
1240 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1241 | else | |
1242 | cat > conftest.c <<EOF | |
1243 | #ifdef __GNUC__ | |
1244 | yes; | |
1245 | #endif | |
1246 | EOF | |
1247 | if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1248: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then | |
1248 | ac_cv_prog_gcc=yes | |
1249 | else | |
1250 | ac_cv_prog_gcc=no | |
1251 | fi | |
1252 | fi | |
1253 | ||
1254 | echo "$ac_t""$ac_cv_prog_gcc" 1>&6 | |
1255 | ||
1256 | if test $ac_cv_prog_gcc = yes; then | |
1257 | GCC=yes | |
1258 | else | |
1259 | GCC= | |
1260 | fi | |
1261 | ||
1262 | ac_test_CFLAGS="${CFLAGS+set}" | |
1263 | ac_save_CFLAGS="$CFLAGS" | |
1264 | CFLAGS= | |
1265 | echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 | |
1266 | echo "configure:1267: checking whether ${CC-cc} accepts -g" >&5 | |
1267 | if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then | |
1268 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1269 | else | |
1270 | echo 'void f(){}' > conftest.c | |
1271 | if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then | |
1272 | ac_cv_prog_cc_g=yes | |
1273 | else | |
1274 | ac_cv_prog_cc_g=no | |
1275 | fi | |
1276 | rm -f conftest* | |
1277 | ||
1278 | fi | |
1279 | ||
1280 | echo "$ac_t""$ac_cv_prog_cc_g" 1>&6 | |
1281 | if test "$ac_test_CFLAGS" = set; then | |
1282 | CFLAGS="$ac_save_CFLAGS" | |
1283 | elif test $ac_cv_prog_cc_g = yes; then | |
1284 | if test "$GCC" = yes; then | |
1285 | CFLAGS="-g -O2" | |
1286 | else | |
1287 | CFLAGS="-g" | |
1288 | fi | |
1289 | else | |
1290 | if test "$GCC" = yes; then | |
1291 | CFLAGS="-O2" | |
1292 | else | |
1293 | CFLAGS= | |
1294 | fi | |
1295 | fi | |
1296 | ||
252b5132 RH |
1297 | # Check whether --with-gnu-ld or --without-gnu-ld was given. |
1298 | if test "${with_gnu_ld+set}" = set; then | |
1299 | withval="$with_gnu_ld" | |
1300 | test "$withval" = no || with_gnu_ld=yes | |
1301 | else | |
1302 | with_gnu_ld=no | |
1303 | fi | |
1304 | ||
1305 | ac_prog=ld | |
1306 | if test "$ac_cv_prog_gcc" = yes; then | |
1307 | # Check if gcc -print-prog-name=ld gives a path. | |
1308 | echo $ac_n "checking for ld used by GCC""... $ac_c" 1>&6 | |
37503931 | 1309 | echo "configure:1310: checking for ld used by GCC" >&5 |
ac48eca1 AO |
1310 | case $host in |
1311 | *-*-mingw*) | |
1312 | # gcc leaves a trailing carriage return which upsets mingw | |
1313 | ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; | |
1314 | *) | |
1315 | ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; | |
1316 | esac | |
252b5132 RH |
1317 | case "$ac_prog" in |
1318 | # Accept absolute paths. | |
5af11cab | 1319 | [\\/]* | [A-Za-z]:[\\/]*) |
252b5132 RH |
1320 | re_direlt='/[^/][^/]*/\.\./' |
1321 | # Canonicalize the path of ld | |
1322 | ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'` | |
1323 | while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do | |
1324 | ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"` | |
1325 | done | |
1326 | test -z "$LD" && LD="$ac_prog" | |
1327 | ;; | |
1328 | "") | |
1329 | # If it fails, then pretend we aren't using GCC. | |
1330 | ac_prog=ld | |
1331 | ;; | |
1332 | *) | |
1333 | # If it is relative, then search for the first ld in PATH. | |
1334 | with_gnu_ld=unknown | |
1335 | ;; | |
1336 | esac | |
1337 | elif test "$with_gnu_ld" = yes; then | |
1338 | echo $ac_n "checking for GNU ld""... $ac_c" 1>&6 | |
37503931 | 1339 | echo "configure:1340: checking for GNU ld" >&5 |
252b5132 RH |
1340 | else |
1341 | echo $ac_n "checking for non-GNU ld""... $ac_c" 1>&6 | |
37503931 | 1342 | echo "configure:1343: checking for non-GNU ld" >&5 |
252b5132 RH |
1343 | fi |
1344 | if eval "test \"`echo '$''{'ac_cv_path_LD'+set}'`\" = set"; then | |
1345 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1346 | else | |
1347 | if test -z "$LD"; then | |
5af11cab | 1348 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}" |
252b5132 RH |
1349 | for ac_dir in $PATH; do |
1350 | test -z "$ac_dir" && ac_dir=. | |
5af11cab | 1351 | if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then |
252b5132 RH |
1352 | ac_cv_path_LD="$ac_dir/$ac_prog" |
1353 | # Check to see if the program is GNU ld. I'd rather use --version, | |
1354 | # but apparently some GNU ld's only accept -v. | |
1355 | # Break only if it was the GNU/non-GNU ld that we prefer. | |
1356 | if "$ac_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then | |
1357 | test "$with_gnu_ld" != no && break | |
1358 | else | |
1359 | test "$with_gnu_ld" != yes && break | |
1360 | fi | |
1361 | fi | |
1362 | done | |
1363 | IFS="$ac_save_ifs" | |
1364 | else | |
1365 | ac_cv_path_LD="$LD" # Let the user override the test with a path. | |
1366 | fi | |
1367 | fi | |
1368 | ||
1369 | LD="$ac_cv_path_LD" | |
1370 | if test -n "$LD"; then | |
1371 | echo "$ac_t""$LD" 1>&6 | |
1372 | else | |
1373 | echo "$ac_t""no" 1>&6 | |
1374 | fi | |
1375 | test -z "$LD" && { echo "configure: error: no acceptable ld found in \$PATH" 1>&2; exit 1; } | |
252b5132 | 1376 | echo $ac_n "checking if the linker ($LD) is GNU ld""... $ac_c" 1>&6 |
37503931 | 1377 | echo "configure:1378: checking if the linker ($LD) is GNU ld" >&5 |
252b5132 RH |
1378 | if eval "test \"`echo '$''{'ac_cv_prog_gnu_ld'+set}'`\" = set"; then |
1379 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1380 | else | |
1381 | # I'd rather use --version here, but apparently some GNU ld's only accept -v. | |
1382 | if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then | |
1383 | ac_cv_prog_gnu_ld=yes | |
1384 | else | |
1385 | ac_cv_prog_gnu_ld=no | |
1386 | fi | |
1387 | fi | |
1388 | ||
1389 | echo "$ac_t""$ac_cv_prog_gnu_ld" 1>&6 | |
ac48eca1 | 1390 | with_gnu_ld=$ac_cv_prog_gnu_ld |
252b5132 RH |
1391 | |
1392 | ||
ac48eca1 | 1393 | echo $ac_n "checking for $LD option to reload object files""... $ac_c" 1>&6 |
37503931 | 1394 | echo "configure:1395: checking for $LD option to reload object files" >&5 |
ac48eca1 AO |
1395 | if eval "test \"`echo '$''{'lt_cv_ld_reload_flag'+set}'`\" = set"; then |
1396 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1397 | else | |
1398 | lt_cv_ld_reload_flag='-r' | |
1399 | fi | |
1400 | ||
1401 | echo "$ac_t""$lt_cv_ld_reload_flag" 1>&6 | |
1402 | reload_flag=$lt_cv_ld_reload_flag | |
1403 | test -n "$reload_flag" && reload_flag=" $reload_flag" | |
1404 | ||
252b5132 | 1405 | echo $ac_n "checking for BSD-compatible nm""... $ac_c" 1>&6 |
37503931 | 1406 | echo "configure:1407: checking for BSD-compatible nm" >&5 |
252b5132 RH |
1407 | if eval "test \"`echo '$''{'ac_cv_path_NM'+set}'`\" = set"; then |
1408 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1409 | else | |
1410 | if test -n "$NM"; then | |
1411 | # Let the user override the test. | |
1412 | ac_cv_path_NM="$NM" | |
1413 | else | |
5af11cab | 1414 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}" |
252b5132 RH |
1415 | for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do |
1416 | test -z "$ac_dir" && ac_dir=. | |
ac48eca1 AO |
1417 | tmp_nm=$ac_dir/${ac_tool_prefix}nm |
1418 | if test -f $tmp_nm || test -f $tmp_nm$ac_exeext ; then | |
252b5132 RH |
1419 | # Check to see if the nm accepts a BSD-compat flag. |
1420 | # Adding the `sed 1q' prevents false positives on HP-UX, which says: | |
1421 | # nm: unknown option "B" ignored | |
17a94bb6 AO |
1422 | # Tru64's nm complains that /dev/null is an invalid object file |
1423 | if ($tmp_nm -B /dev/null 2>&1 | sed '1q'; exit 0) | egrep '(/dev/null|Invalid file or object type)' >/dev/null; then | |
ac48eca1 | 1424 | ac_cv_path_NM="$tmp_nm -B" |
252b5132 | 1425 | break |
ac48eca1 AO |
1426 | elif ($tmp_nm -p /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then |
1427 | ac_cv_path_NM="$tmp_nm -p" | |
252b5132 RH |
1428 | break |
1429 | else | |
ac48eca1 | 1430 | ac_cv_path_NM=${ac_cv_path_NM="$tmp_nm"} # keep the first match, but |
252b5132 RH |
1431 | continue # so that we can try to find one that supports BSD flags |
1432 | fi | |
1433 | fi | |
1434 | done | |
1435 | IFS="$ac_save_ifs" | |
1436 | test -z "$ac_cv_path_NM" && ac_cv_path_NM=nm | |
1437 | fi | |
1438 | fi | |
1439 | ||
1440 | NM="$ac_cv_path_NM" | |
1441 | echo "$ac_t""$NM" 1>&6 | |
1442 | ||
252b5132 | 1443 | echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6 |
37503931 | 1444 | echo "configure:1445: checking whether ln -s works" >&5 |
252b5132 RH |
1445 | if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then |
1446 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1447 | else | |
1448 | rm -f conftestdata | |
1449 | if ln -s X conftestdata 2>/dev/null | |
1450 | then | |
1451 | rm -f conftestdata | |
1452 | ac_cv_prog_LN_S="ln -s" | |
1453 | else | |
1454 | ac_cv_prog_LN_S=ln | |
1455 | fi | |
1456 | fi | |
1457 | LN_S="$ac_cv_prog_LN_S" | |
1458 | if test "$ac_cv_prog_LN_S" = "ln -s"; then | |
1459 | echo "$ac_t""yes" 1>&6 | |
1460 | else | |
1461 | echo "$ac_t""no" 1>&6 | |
1462 | fi | |
1463 | ||
ac48eca1 | 1464 | echo $ac_n "checking how to recognise dependant libraries""... $ac_c" 1>&6 |
37503931 | 1465 | echo "configure:1466: checking how to recognise dependant libraries" >&5 |
ac48eca1 AO |
1466 | if eval "test \"`echo '$''{'lt_cv_deplibs_check_method'+set}'`\" = set"; then |
1467 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1468 | else | |
d64552c5 | 1469 | lt_cv_file_magic_cmd='$MAGIC_CMD' |
ac48eca1 AO |
1470 | lt_cv_file_magic_test_file= |
1471 | lt_cv_deplibs_check_method='unknown' | |
1472 | # Need to set the preceding variable on all platforms that support | |
1473 | # interlibrary dependencies. | |
1474 | # 'none' -- dependencies not supported. | |
1475 | # `unknown' -- same as none, but documents that we really don't know. | |
1476 | # 'pass_all' -- all dependencies passed with no checks. | |
1477 | # 'test_compile' -- check by making test program. | |
1478 | # 'file_magic [regex]' -- check by looking for files in library path | |
1479 | # which responds to the $file_magic_cmd with a given egrep regex. | |
1480 | # If you have `file' or equivalent on your system and you're not sure | |
1481 | # whether `pass_all' will *always* work, you probably want this one. | |
1482 | ||
1483 | case "$host_os" in | |
1484 | aix4*) | |
1485 | lt_cv_deplibs_check_method=pass_all | |
1486 | ;; | |
1487 | ||
1488 | beos*) | |
1489 | lt_cv_deplibs_check_method=pass_all | |
1490 | ;; | |
1491 | ||
1492 | bsdi4*) | |
1493 | lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)' | |
1494 | lt_cv_file_magic_cmd='/usr/bin/file -L' | |
1495 | lt_cv_file_magic_test_file=/shlib/libc.so | |
1496 | ;; | |
1497 | ||
d64552c5 | 1498 | cygwin* | mingw* |pw32*) |
ac48eca1 | 1499 | lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?' |
d64552c5 | 1500 | lt_cv_file_magic_cmd='$OBJDUMP -f' |
ac48eca1 AO |
1501 | ;; |
1502 | ||
1503 | freebsd* ) | |
1504 | if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then | |
1505 | case "$host_cpu" in | |
1506 | i*86 ) | |
17a94bb6 AO |
1507 | # Not sure whether the presence of OpenBSD here was a mistake. |
1508 | # Let's accept both of them until this is cleared up. | |
1509 | lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD)/i[3-9]86 (compact )?demand paged shared library' | |
ac48eca1 AO |
1510 | lt_cv_file_magic_cmd=/usr/bin/file |
1511 | lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` | |
1512 | ;; | |
1513 | esac | |
1514 | else | |
1515 | lt_cv_deplibs_check_method=pass_all | |
1516 | fi | |
1517 | ;; | |
1518 | ||
1519 | gnu*) | |
1520 | lt_cv_deplibs_check_method=pass_all | |
1521 | ;; | |
1522 | ||
1523 | hpux10.20*) | |
1524 | # TODO: Does this work for hpux-11 too? | |
1525 | lt_cv_deplibs_check_method='file_magic (s0-90-90-9|PA-RISC0-9.0-9) shared library' | |
1526 | lt_cv_file_magic_cmd=/usr/bin/file | |
1527 | lt_cv_file_magic_test_file=/usr/lib/libc.sl | |
1528 | ;; | |
1529 | ||
1530 | irix5* | irix6*) | |
1531 | case "$host_os" in | |
1532 | irix5*) | |
1533 | # this will be overridden with pass_all, but let us keep it just in case | |
1534 | lt_cv_deplibs_check_method="file_magic ELF 32-bit MSB dynamic lib MIPS - version 1" | |
1535 | ;; | |
1536 | *) | |
1537 | case "$LD" in | |
1538 | *-32|*"-32 ") libmagic=32-bit;; | |
1539 | *-n32|*"-n32 ") libmagic=N32;; | |
1540 | *-64|*"-64 ") libmagic=64-bit;; | |
1541 | *) libmagic=never-match;; | |
1542 | esac | |
1543 | # this will be overridden with pass_all, but let us keep it just in case | |
1544 | lt_cv_deplibs_check_method="file_magic ELF ${libmagic} MSB mips-[1234] dynamic lib MIPS - version 1" | |
1545 | ;; | |
1546 | esac | |
1547 | lt_cv_file_magic_test_file=`echo /lib${libsuff}/libc.so*` | |
1548 | lt_cv_deplibs_check_method=pass_all | |
1549 | ;; | |
1550 | ||
1551 | # This must be Linux ELF. | |
17a94bb6 | 1552 | linux-gnu*) |
ac48eca1 AO |
1553 | case "$host_cpu" in |
1554 | alpha* | i*86 | powerpc* | sparc* | ia64* ) | |
1555 | lt_cv_deplibs_check_method=pass_all ;; | |
1556 | *) | |
1557 | # glibc up to 2.1.1 does not perform some relocations on ARM | |
1558 | lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' ;; | |
1559 | esac | |
1560 | lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so` | |
1561 | ;; | |
1562 | ||
1563 | netbsd*) | |
1564 | if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then : | |
1565 | else | |
1566 | lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB shared object' | |
1567 | lt_cv_file_magic_cmd='/usr/bin/file -L' | |
1568 | lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` | |
1569 | fi | |
1570 | ;; | |
1571 | ||
1572 | osf3* | osf4* | osf5*) | |
1573 | # this will be overridden with pass_all, but let us keep it just in case | |
1574 | lt_cv_deplibs_check_method='file_magic COFF format alpha shared library' | |
1575 | lt_cv_file_magic_test_file=/shlib/libc.so | |
1576 | lt_cv_deplibs_check_method=pass_all | |
1577 | ;; | |
1578 | ||
1579 | sco3.2v5*) | |
1580 | lt_cv_deplibs_check_method=pass_all | |
1581 | ;; | |
1582 | ||
1583 | solaris*) | |
1584 | lt_cv_deplibs_check_method=pass_all | |
1585 | lt_cv_file_magic_test_file=/lib/libc.so | |
1586 | ;; | |
1587 | ||
1588 | sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) | |
1589 | case "$host_vendor" in | |
1590 | ncr) | |
1591 | lt_cv_deplibs_check_method=pass_all | |
1592 | ;; | |
1593 | motorola) | |
1594 | 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]' | |
1595 | lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` | |
1596 | ;; | |
1597 | esac | |
1598 | ;; | |
1599 | esac | |
1600 | ||
1601 | fi | |
1602 | ||
1603 | echo "$ac_t""$lt_cv_deplibs_check_method" 1>&6 | |
1604 | file_magic_cmd=$lt_cv_file_magic_cmd | |
1605 | deplibs_check_method=$lt_cv_deplibs_check_method | |
1606 | ||
1607 | echo $ac_n "checking for object suffix""... $ac_c" 1>&6 | |
37503931 | 1608 | echo "configure:1609: checking for object suffix" >&5 |
ac48eca1 AO |
1609 | if eval "test \"`echo '$''{'ac_cv_objext'+set}'`\" = set"; then |
1610 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1611 | else | |
1612 | rm -f conftest* | |
1613 | echo 'int i = 1;' > conftest.$ac_ext | |
37503931 | 1614 | if { (eval echo configure:1615: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
ac48eca1 AO |
1615 | for ac_file in conftest.*; do |
1616 | case $ac_file in | |
1617 | *.c) ;; | |
1618 | *) ac_cv_objext=`echo $ac_file | sed -e s/conftest.//` ;; | |
1619 | esac | |
1620 | done | |
1621 | else | |
1622 | { echo "configure: error: installation or configuration problem; compiler does not work" 1>&2; exit 1; } | |
1623 | fi | |
1624 | rm -f conftest* | |
1625 | fi | |
1626 | ||
1627 | echo "$ac_t""$ac_cv_objext" 1>&6 | |
1628 | OBJEXT=$ac_cv_objext | |
1629 | ac_objext=$ac_cv_objext | |
1630 | ||
1631 | ||
1632 | ||
1633 | echo $ac_n "checking for executable suffix""... $ac_c" 1>&6 | |
37503931 | 1634 | echo "configure:1635: checking for executable suffix" >&5 |
ac48eca1 AO |
1635 | if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then |
1636 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1637 | else | |
1638 | if test "$CYGWIN" = yes || test "$MINGW32" = yes; then | |
1639 | ac_cv_exeext=.exe | |
1640 | else | |
1641 | rm -f conftest* | |
1642 | echo 'int main () { return 0; }' > conftest.$ac_ext | |
1643 | ac_cv_exeext= | |
37503931 | 1644 | if { (eval echo configure:1645: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
ac48eca1 AO |
1645 | for file in conftest.*; do |
1646 | case $file in | |
27b7e12d | 1647 | *.c | *.o | *.obj | *.ilk | *.pdb) ;; |
ac48eca1 AO |
1648 | *) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;; |
1649 | esac | |
1650 | done | |
1651 | else | |
1652 | { echo "configure: error: installation or configuration problem: compiler cannot create executables." 1>&2; exit 1; } | |
1653 | fi | |
1654 | rm -f conftest* | |
1655 | test x"${ac_cv_exeext}" = x && ac_cv_exeext=no | |
1656 | fi | |
1657 | fi | |
1658 | ||
1659 | EXEEXT="" | |
1660 | test x"${ac_cv_exeext}" != xno && EXEEXT=${ac_cv_exeext} | |
1661 | echo "$ac_t""${ac_cv_exeext}" 1>&6 | |
1662 | ac_exeext=$EXEEXT | |
1663 | ||
1664 | if test $host != $build; then | |
1665 | ac_tool_prefix=${host_alias}- | |
1666 | else | |
1667 | ac_tool_prefix= | |
1668 | fi | |
1669 | ||
1670 | # Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers! | |
1671 | ||
1672 | # Only perform the check for file, if the check method requires it | |
1673 | case "$deplibs_check_method" in | |
1674 | file_magic*) | |
d64552c5 | 1675 | if test "$file_magic_cmd" = '$MAGIC_CMD'; then |
ac48eca1 | 1676 | echo $ac_n "checking for ${ac_tool_prefix}file""... $ac_c" 1>&6 |
37503931 | 1677 | echo "configure:1678: checking for ${ac_tool_prefix}file" >&5 |
d64552c5 | 1678 | if eval "test \"`echo '$''{'lt_cv_path_MAGIC_CMD'+set}'`\" = set"; then |
ac48eca1 AO |
1679 | echo $ac_n "(cached) $ac_c" 1>&6 |
1680 | else | |
d64552c5 | 1681 | case "$MAGIC_CMD" in |
ac48eca1 | 1682 | /*) |
d64552c5 | 1683 | lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. |
ac48eca1 AO |
1684 | ;; |
1685 | ?:/*) | |
d64552c5 | 1686 | lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a dos path. |
ac48eca1 AO |
1687 | ;; |
1688 | *) | |
d64552c5 | 1689 | ac_save_MAGIC_CMD="$MAGIC_CMD" |
ac48eca1 AO |
1690 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
1691 | ac_dummy="/usr/bin:$PATH" | |
1692 | for ac_dir in $ac_dummy; do | |
1693 | test -z "$ac_dir" && ac_dir=. | |
1694 | if test -f $ac_dir/${ac_tool_prefix}file; then | |
d64552c5 | 1695 | lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file" |
ac48eca1 AO |
1696 | if test -n "$file_magic_test_file"; then |
1697 | case "$deplibs_check_method" in | |
1698 | "file_magic "*) | |
1699 | file_magic_regex="`expr \"$deplibs_check_method\" : \"file_magic \(.*\)\"`" | |
d64552c5 | 1700 | MAGIC_CMD="$lt_cv_path_MAGIC_CMD" |
ac48eca1 AO |
1701 | if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | |
1702 | egrep "$file_magic_regex" > /dev/null; then | |
1703 | : | |
1704 | else | |
1705 | cat <<EOF 1>&2 | |
1706 | ||
1707 | *** Warning: the command libtool uses to detect shared libraries, | |
1708 | *** $file_magic_cmd, produces output that libtool cannot recognize. | |
1709 | *** The result is that libtool may fail to recognize shared libraries | |
1710 | *** as such. This will affect the creation of libtool libraries that | |
1711 | *** depend on shared libraries, but programs linked with such libtool | |
1712 | *** libraries will work regardless of this problem. Nevertheless, you | |
1713 | *** may want to report the problem to your system manager and/or to | |
1714 | *** bug-libtool@gnu.org | |
1715 | ||
1716 | EOF | |
1717 | fi ;; | |
1718 | esac | |
1719 | fi | |
1720 | break | |
1721 | fi | |
1722 | done | |
1723 | IFS="$ac_save_ifs" | |
d64552c5 | 1724 | MAGIC_CMD="$ac_save_MAGIC_CMD" |
ac48eca1 AO |
1725 | ;; |
1726 | esac | |
1727 | fi | |
1728 | ||
d64552c5 AO |
1729 | MAGIC_CMD="$lt_cv_path_MAGIC_CMD" |
1730 | if test -n "$MAGIC_CMD"; then | |
1731 | echo "$ac_t""$MAGIC_CMD" 1>&6 | |
ac48eca1 AO |
1732 | else |
1733 | echo "$ac_t""no" 1>&6 | |
1734 | fi | |
1735 | ||
d64552c5 | 1736 | if test -z "$lt_cv_path_MAGIC_CMD"; then |
ac48eca1 AO |
1737 | if test -n "$ac_tool_prefix"; then |
1738 | echo $ac_n "checking for file""... $ac_c" 1>&6 | |
37503931 | 1739 | echo "configure:1740: checking for file" >&5 |
d64552c5 | 1740 | if eval "test \"`echo '$''{'lt_cv_path_MAGIC_CMD'+set}'`\" = set"; then |
ac48eca1 AO |
1741 | echo $ac_n "(cached) $ac_c" 1>&6 |
1742 | else | |
d64552c5 | 1743 | case "$MAGIC_CMD" in |
ac48eca1 | 1744 | /*) |
d64552c5 | 1745 | lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. |
ac48eca1 AO |
1746 | ;; |
1747 | ?:/*) | |
d64552c5 | 1748 | lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a dos path. |
ac48eca1 AO |
1749 | ;; |
1750 | *) | |
d64552c5 | 1751 | ac_save_MAGIC_CMD="$MAGIC_CMD" |
ac48eca1 AO |
1752 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
1753 | ac_dummy="/usr/bin:$PATH" | |
1754 | for ac_dir in $ac_dummy; do | |
1755 | test -z "$ac_dir" && ac_dir=. | |
1756 | if test -f $ac_dir/file; then | |
d64552c5 | 1757 | lt_cv_path_MAGIC_CMD="$ac_dir/file" |
ac48eca1 AO |
1758 | if test -n "$file_magic_test_file"; then |
1759 | case "$deplibs_check_method" in | |
1760 | "file_magic "*) | |
1761 | file_magic_regex="`expr \"$deplibs_check_method\" : \"file_magic \(.*\)\"`" | |
d64552c5 | 1762 | MAGIC_CMD="$lt_cv_path_MAGIC_CMD" |
ac48eca1 AO |
1763 | if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | |
1764 | egrep "$file_magic_regex" > /dev/null; then | |
1765 | : | |
1766 | else | |
1767 | cat <<EOF 1>&2 | |
1768 | ||
1769 | *** Warning: the command libtool uses to detect shared libraries, | |
1770 | *** $file_magic_cmd, produces output that libtool cannot recognize. | |
1771 | *** The result is that libtool may fail to recognize shared libraries | |
1772 | *** as such. This will affect the creation of libtool libraries that | |
1773 | *** depend on shared libraries, but programs linked with such libtool | |
1774 | *** libraries will work regardless of this problem. Nevertheless, you | |
1775 | *** may want to report the problem to your system manager and/or to | |
1776 | *** bug-libtool@gnu.org | |
1777 | ||
1778 | EOF | |
1779 | fi ;; | |
1780 | esac | |
1781 | fi | |
1782 | break | |
1783 | fi | |
1784 | done | |
1785 | IFS="$ac_save_ifs" | |
d64552c5 | 1786 | MAGIC_CMD="$ac_save_MAGIC_CMD" |
ac48eca1 AO |
1787 | ;; |
1788 | esac | |
1789 | fi | |
1790 | ||
d64552c5 AO |
1791 | MAGIC_CMD="$lt_cv_path_MAGIC_CMD" |
1792 | if test -n "$MAGIC_CMD"; then | |
1793 | echo "$ac_t""$MAGIC_CMD" 1>&6 | |
ac48eca1 AO |
1794 | else |
1795 | echo "$ac_t""no" 1>&6 | |
1796 | fi | |
1797 | ||
1798 | else | |
d64552c5 | 1799 | MAGIC_CMD=: |
ac48eca1 AO |
1800 | fi |
1801 | fi | |
252b5132 | 1802 | |
ac48eca1 AO |
1803 | fi |
1804 | ;; | |
5af11cab | 1805 | esac |
252b5132 | 1806 | |
ac48eca1 AO |
1807 | # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. |
1808 | set dummy ${ac_tool_prefix}ranlib; ac_word=$2 | |
1809 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
37503931 | 1810 | echo "configure:1811: checking for $ac_word" >&5 |
ac48eca1 AO |
1811 | if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then |
1812 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1813 | else | |
1814 | if test -n "$RANLIB"; then | |
1815 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. | |
1816 | else | |
1817 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
1818 | ac_dummy="$PATH" | |
1819 | for ac_dir in $ac_dummy; do | |
1820 | test -z "$ac_dir" && ac_dir=. | |
1821 | if test -f $ac_dir/$ac_word; then | |
1822 | ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" | |
1823 | break | |
1824 | fi | |
1825 | done | |
1826 | IFS="$ac_save_ifs" | |
1827 | fi | |
1828 | fi | |
1829 | RANLIB="$ac_cv_prog_RANLIB" | |
1830 | if test -n "$RANLIB"; then | |
1831 | echo "$ac_t""$RANLIB" 1>&6 | |
1832 | else | |
1833 | echo "$ac_t""no" 1>&6 | |
1834 | fi | |
1835 | ||
1836 | ||
1837 | if test -z "$ac_cv_prog_RANLIB"; then | |
1838 | if test -n "$ac_tool_prefix"; then | |
1839 | # Extract the first word of "ranlib", so it can be a program name with args. | |
1840 | set dummy ranlib; ac_word=$2 | |
1841 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
37503931 | 1842 | echo "configure:1843: checking for $ac_word" >&5 |
ac48eca1 AO |
1843 | if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then |
1844 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1845 | else | |
1846 | if test -n "$RANLIB"; then | |
1847 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. | |
1848 | else | |
1849 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
1850 | ac_dummy="$PATH" | |
1851 | for ac_dir in $ac_dummy; do | |
1852 | test -z "$ac_dir" && ac_dir=. | |
1853 | if test -f $ac_dir/$ac_word; then | |
1854 | ac_cv_prog_RANLIB="ranlib" | |
1855 | break | |
1856 | fi | |
1857 | done | |
1858 | IFS="$ac_save_ifs" | |
1859 | test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":" | |
1860 | fi | |
1861 | fi | |
1862 | RANLIB="$ac_cv_prog_RANLIB" | |
1863 | if test -n "$RANLIB"; then | |
1864 | echo "$ac_t""$RANLIB" 1>&6 | |
1865 | else | |
1866 | echo "$ac_t""no" 1>&6 | |
1867 | fi | |
1868 | ||
1869 | else | |
1870 | RANLIB=":" | |
1871 | fi | |
1872 | fi | |
1873 | ||
1874 | # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. | |
1875 | set dummy ${ac_tool_prefix}strip; ac_word=$2 | |
1876 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
37503931 | 1877 | echo "configure:1878: checking for $ac_word" >&5 |
ac48eca1 AO |
1878 | if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then |
1879 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1880 | else | |
1881 | if test -n "$STRIP"; then | |
1882 | ac_cv_prog_STRIP="$STRIP" # Let the user override the test. | |
1883 | else | |
1884 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
1885 | ac_dummy="$PATH" | |
1886 | for ac_dir in $ac_dummy; do | |
1887 | test -z "$ac_dir" && ac_dir=. | |
1888 | if test -f $ac_dir/$ac_word; then | |
1889 | ac_cv_prog_STRIP="${ac_tool_prefix}strip" | |
1890 | break | |
1891 | fi | |
1892 | done | |
1893 | IFS="$ac_save_ifs" | |
1894 | fi | |
1895 | fi | |
1896 | STRIP="$ac_cv_prog_STRIP" | |
1897 | if test -n "$STRIP"; then | |
1898 | echo "$ac_t""$STRIP" 1>&6 | |
1899 | else | |
1900 | echo "$ac_t""no" 1>&6 | |
1901 | fi | |
1902 | ||
1903 | ||
1904 | if test -z "$ac_cv_prog_STRIP"; then | |
1905 | if test -n "$ac_tool_prefix"; then | |
1906 | # Extract the first word of "strip", so it can be a program name with args. | |
1907 | set dummy strip; ac_word=$2 | |
1908 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
37503931 | 1909 | echo "configure:1910: checking for $ac_word" >&5 |
ac48eca1 AO |
1910 | if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then |
1911 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1912 | else | |
1913 | if test -n "$STRIP"; then | |
1914 | ac_cv_prog_STRIP="$STRIP" # Let the user override the test. | |
1915 | else | |
1916 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
1917 | ac_dummy="$PATH" | |
1918 | for ac_dir in $ac_dummy; do | |
1919 | test -z "$ac_dir" && ac_dir=. | |
1920 | if test -f $ac_dir/$ac_word; then | |
1921 | ac_cv_prog_STRIP="strip" | |
1922 | break | |
1923 | fi | |
1924 | done | |
1925 | IFS="$ac_save_ifs" | |
1926 | test -z "$ac_cv_prog_STRIP" && ac_cv_prog_STRIP=":" | |
1927 | fi | |
1928 | fi | |
1929 | STRIP="$ac_cv_prog_STRIP" | |
1930 | if test -n "$STRIP"; then | |
1931 | echo "$ac_t""$STRIP" 1>&6 | |
1932 | else | |
1933 | echo "$ac_t""no" 1>&6 | |
1934 | fi | |
1935 | ||
1936 | else | |
1937 | STRIP=":" | |
1938 | fi | |
1939 | fi | |
1940 | ||
1941 | ||
252b5132 RH |
1942 | # Check for any special flags to pass to ltconfig. |
1943 | libtool_flags="--cache-file=$cache_file" | |
1944 | test "$enable_shared" = no && libtool_flags="$libtool_flags --disable-shared" | |
1945 | test "$enable_static" = no && libtool_flags="$libtool_flags --disable-static" | |
1946 | test "$enable_fast_install" = no && libtool_flags="$libtool_flags --disable-fast-install" | |
252b5132 RH |
1947 | test "$ac_cv_prog_gcc" = yes && libtool_flags="$libtool_flags --with-gcc" |
1948 | test "$ac_cv_prog_gnu_ld" = yes && libtool_flags="$libtool_flags --with-gnu-ld" | |
1949 | ||
5af11cab AM |
1950 | |
1951 | # Check whether --enable-libtool-lock or --disable-libtool-lock was given. | |
1952 | if test "${enable_libtool_lock+set}" = set; then | |
1953 | enableval="$enable_libtool_lock" | |
1954 | : | |
1955 | fi | |
1956 | ||
1957 | test "x$enable_libtool_lock" = xno && libtool_flags="$libtool_flags --disable-lock" | |
1958 | test x"$silent" = xyes && libtool_flags="$libtool_flags --silent" | |
1959 | ||
ac48eca1 AO |
1960 | # Check whether --with-pic or --without-pic was given. |
1961 | if test "${with_pic+set}" = set; then | |
1962 | withval="$with_pic" | |
1963 | pic_mode="$withval" | |
1964 | else | |
1965 | pic_mode=default | |
1966 | fi | |
1967 | ||
1968 | test x"$pic_mode" = xyes && libtool_flags="$libtool_flags --prefer-pic" | |
1969 | test x"$pic_mode" = xno && libtool_flags="$libtool_flags --prefer-non-pic" | |
1970 | ||
252b5132 RH |
1971 | # Some flags need to be propagated to the compiler or linker for good |
1972 | # libtool support. | |
ac48eca1 | 1973 | case "$host" in |
252b5132 RH |
1974 | *-*-irix6*) |
1975 | # Find out which ABI we are using. | |
37503931 NC |
1976 | echo '#line 1977 "configure"' > conftest.$ac_ext |
1977 | if { (eval echo configure:1978: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then | |
252b5132 RH |
1978 | case "`/usr/bin/file conftest.o`" in |
1979 | *32-bit*) | |
1980 | LD="${LD-ld} -32" | |
1981 | ;; | |
1982 | *N32*) | |
1983 | LD="${LD-ld} -n32" | |
1984 | ;; | |
1985 | *64-bit*) | |
1986 | LD="${LD-ld} -64" | |
1987 | ;; | |
1988 | esac | |
1989 | fi | |
1990 | rm -rf conftest* | |
1991 | ;; | |
1992 | ||
1993 | *-*-sco3.2v5*) | |
1994 | # On SCO OpenServer 5, we need -belf to get full-featured binaries. | |
1995 | SAVE_CFLAGS="$CFLAGS" | |
1996 | CFLAGS="$CFLAGS -belf" | |
1997 | echo $ac_n "checking whether the C compiler needs -belf""... $ac_c" 1>&6 | |
37503931 | 1998 | echo "configure:1999: checking whether the C compiler needs -belf" >&5 |
252b5132 RH |
1999 | if eval "test \"`echo '$''{'lt_cv_cc_needs_belf'+set}'`\" = set"; then |
2000 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2001 | else | |
ac48eca1 AO |
2002 | |
2003 | ac_ext=c | |
2004 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. | |
2005 | ac_cpp='$CPP $CPPFLAGS' | |
2006 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' | |
2007 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' | |
2008 | cross_compiling=$ac_cv_prog_cc_cross | |
2009 | ||
2010 | cat > conftest.$ac_ext <<EOF | |
37503931 | 2011 | #line 2012 "configure" |
252b5132 RH |
2012 | #include "confdefs.h" |
2013 | ||
2014 | int main() { | |
2015 | ||
2016 | ; return 0; } | |
2017 | EOF | |
37503931 | 2018 | if { (eval echo configure:2019: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
252b5132 RH |
2019 | rm -rf conftest* |
2020 | lt_cv_cc_needs_belf=yes | |
2021 | else | |
2022 | echo "configure: failed program was:" >&5 | |
2023 | cat conftest.$ac_ext >&5 | |
2024 | rm -rf conftest* | |
2025 | lt_cv_cc_needs_belf=no | |
2026 | fi | |
2027 | rm -f conftest* | |
ac48eca1 AO |
2028 | ac_ext=c |
2029 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. | |
2030 | ac_cpp='$CPP $CPPFLAGS' | |
2031 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' | |
2032 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' | |
2033 | cross_compiling=$ac_cv_prog_cc_cross | |
2034 | ||
252b5132 RH |
2035 | fi |
2036 | ||
2037 | echo "$ac_t""$lt_cv_cc_needs_belf" 1>&6 | |
2038 | if test x"$lt_cv_cc_needs_belf" != x"yes"; then | |
2039 | # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf | |
2040 | CFLAGS="$SAVE_CFLAGS" | |
2041 | fi | |
2042 | ;; | |
2043 | ||
252b5132 RH |
2044 | |
2045 | esac | |
2046 | ||
252b5132 RH |
2047 | |
2048 | # Save cache, so that ltconfig can load it | |
2049 | cat > confcache <<\EOF | |
2050 | # This file is a shell script that caches the results of configure | |
2051 | # tests run on this system so they can be shared between configure | |
2052 | # scripts and configure runs. It is not useful on other systems. | |
2053 | # If it contains results you don't want to keep, you may remove or edit it. | |
2054 | # | |
2055 | # By default, configure uses ./config.cache as the cache file, | |
2056 | # creating it if it does not exist already. You can give configure | |
2057 | # the --cache-file=FILE option to use a different cache file; that is | |
2058 | # what configure does when it calls configure scripts in | |
2059 | # subdirectories, so they share the cache. | |
2060 | # Giving --cache-file=/dev/null disables caching, for debugging configure. | |
2061 | # config.status only pays attention to the cache file if you give it the | |
2062 | # --recheck option to rerun configure. | |
2063 | # | |
2064 | EOF | |
2065 | # The following way of writing the cache mishandles newlines in values, | |
2066 | # but we know of no workaround that is simple, portable, and efficient. | |
2067 | # So, don't put newlines in cache variables' values. | |
2068 | # Ultrix sh set writes to stderr and can't be redirected directly, | |
2069 | # and sets the high bit in the cache file unless we assign to the vars. | |
2070 | (set) 2>&1 | | |
2071 | case `(ac_space=' '; set | grep ac_space) 2>&1` in | |
2072 | *ac_space=\ *) | |
2073 | # `set' does not quote correctly, so add quotes (double-quote substitution | |
2074 | # turns \\\\ into \\, and sed turns \\ into \). | |
2075 | sed -n \ | |
2076 | -e "s/'/'\\\\''/g" \ | |
2077 | -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p" | |
2078 | ;; | |
2079 | *) | |
2080 | # `set' quotes correctly as required by POSIX, so do not add quotes. | |
2081 | sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p' | |
2082 | ;; | |
2083 | esac >> confcache | |
2084 | if cmp -s $cache_file confcache; then | |
2085 | : | |
2086 | else | |
2087 | if test -w $cache_file; then | |
2088 | echo "updating cache $cache_file" | |
2089 | cat confcache > $cache_file | |
2090 | else | |
2091 | echo "not updating unwritable cache $cache_file" | |
2092 | fi | |
2093 | fi | |
2094 | rm -f confcache | |
2095 | ||
2096 | ||
2097 | # Actually configure libtool. ac_aux_dir is where install-sh is found. | |
ac48eca1 | 2098 | AR="$AR" LTCC="$CC" CC="$CC" CFLAGS="$CFLAGS" CPPFLAGS="$CPPFLAGS" \ |
d64552c5 | 2099 | MAGIC_CMD="$MAGIC_CMD" LD="$LD" LDFLAGS="$LDFLAGS" LIBS="$LIBS" \ |
ac48eca1 AO |
2100 | LN_S="$LN_S" NM="$NM" RANLIB="$RANLIB" STRIP="$STRIP" \ |
2101 | AS="$AS" DLLTOOL="$DLLTOOL" OBJDUMP="$OBJDUMP" \ | |
2102 | objext="$OBJEXT" exeext="$EXEEXT" reload_flag="$reload_flag" \ | |
2103 | deplibs_check_method="$deplibs_check_method" file_magic_cmd="$file_magic_cmd" \ | |
252b5132 | 2104 | ${CONFIG_SHELL-/bin/sh} $ac_aux_dir/ltconfig --no-reexec \ |
ac48eca1 | 2105 | $libtool_flags --no-verify --build="$build" $ac_aux_dir/ltmain.sh $host \ |
252b5132 RH |
2106 | || { echo "configure: error: libtool configure failed" 1>&2; exit 1; } |
2107 | ||
2108 | # Reload cache, that may have been modified by ltconfig | |
2109 | if test -r "$cache_file"; then | |
2110 | echo "loading cache $cache_file" | |
2111 | . $cache_file | |
2112 | else | |
2113 | echo "creating cache $cache_file" | |
2114 | > $cache_file | |
2115 | fi | |
2116 | ||
2117 | ||
2118 | # This can be used to rebuild libtool when needed | |
ac48eca1 | 2119 | LIBTOOL_DEPS="$ac_aux_dir/ltconfig $ac_aux_dir/ltmain.sh $ac_aux_dir/ltcf-c.sh" |
252b5132 RH |
2120 | |
2121 | # Always use our own libtool. | |
2122 | LIBTOOL='$(SHELL) $(top_builddir)/libtool' | |
2123 | ||
2124 | # Redirect the config.log output again, so that the ltconfig log is not | |
2125 | # clobbered by the next message. | |
2126 | exec 5>>./config.log | |
2127 | ||
2128 | ||
ac48eca1 AO |
2129 | |
2130 | ||
2131 | ||
2132 | ||
d64552c5 | 2133 | |
ac48eca1 | 2134 | |
252b5132 RH |
2135 | |
2136 | ||
2137 | ||
2138 | ||
2139 | # Extract the first word of "gcc", so it can be a program name with args. | |
2140 | set dummy gcc; ac_word=$2 | |
2141 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
37503931 | 2142 | echo "configure:2143: checking for $ac_word" >&5 |
252b5132 RH |
2143 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
2144 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2145 | else | |
2146 | if test -n "$CC"; then | |
2147 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
2148 | else | |
2149 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
2150 | ac_dummy="$PATH" | |
2151 | for ac_dir in $ac_dummy; do | |
2152 | test -z "$ac_dir" && ac_dir=. | |
2153 | if test -f $ac_dir/$ac_word; then | |
2154 | ac_cv_prog_CC="gcc" | |
2155 | break | |
2156 | fi | |
2157 | done | |
2158 | IFS="$ac_save_ifs" | |
2159 | fi | |
2160 | fi | |
2161 | CC="$ac_cv_prog_CC" | |
2162 | if test -n "$CC"; then | |
2163 | echo "$ac_t""$CC" 1>&6 | |
2164 | else | |
2165 | echo "$ac_t""no" 1>&6 | |
2166 | fi | |
2167 | ||
2168 | if test -z "$CC"; then | |
2169 | # Extract the first word of "cc", so it can be a program name with args. | |
2170 | set dummy cc; ac_word=$2 | |
2171 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
37503931 | 2172 | echo "configure:2173: checking for $ac_word" >&5 |
252b5132 RH |
2173 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
2174 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2175 | else | |
2176 | if test -n "$CC"; then | |
2177 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
2178 | else | |
2179 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
2180 | ac_prog_rejected=no | |
2181 | ac_dummy="$PATH" | |
2182 | for ac_dir in $ac_dummy; do | |
2183 | test -z "$ac_dir" && ac_dir=. | |
2184 | if test -f $ac_dir/$ac_word; then | |
2185 | if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then | |
2186 | ac_prog_rejected=yes | |
2187 | continue | |
2188 | fi | |
2189 | ac_cv_prog_CC="cc" | |
2190 | break | |
2191 | fi | |
2192 | done | |
2193 | IFS="$ac_save_ifs" | |
2194 | if test $ac_prog_rejected = yes; then | |
2195 | # We found a bogon in the path, so make sure we never use it. | |
2196 | set dummy $ac_cv_prog_CC | |
2197 | shift | |
2198 | if test $# -gt 0; then | |
2199 | # We chose a different compiler from the bogus one. | |
2200 | # However, it has the same basename, so the bogon will be chosen | |
2201 | # first if we set CC to just the basename; use the full file name. | |
2202 | shift | |
2203 | set dummy "$ac_dir/$ac_word" "$@" | |
2204 | shift | |
2205 | ac_cv_prog_CC="$@" | |
2206 | fi | |
2207 | fi | |
2208 | fi | |
2209 | fi | |
2210 | CC="$ac_cv_prog_CC" | |
2211 | if test -n "$CC"; then | |
2212 | echo "$ac_t""$CC" 1>&6 | |
2213 | else | |
2214 | echo "$ac_t""no" 1>&6 | |
2215 | fi | |
2216 | ||
2217 | if test -z "$CC"; then | |
2218 | case "`uname -s`" in | |
2219 | *win32* | *WIN32*) | |
2220 | # Extract the first word of "cl", so it can be a program name with args. | |
2221 | set dummy cl; ac_word=$2 | |
2222 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
37503931 | 2223 | echo "configure:2224: checking for $ac_word" >&5 |
252b5132 RH |
2224 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
2225 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2226 | else | |
2227 | if test -n "$CC"; then | |
2228 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
2229 | else | |
2230 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
2231 | ac_dummy="$PATH" | |
2232 | for ac_dir in $ac_dummy; do | |
2233 | test -z "$ac_dir" && ac_dir=. | |
2234 | if test -f $ac_dir/$ac_word; then | |
2235 | ac_cv_prog_CC="cl" | |
2236 | break | |
2237 | fi | |
2238 | done | |
2239 | IFS="$ac_save_ifs" | |
2240 | fi | |
2241 | fi | |
2242 | CC="$ac_cv_prog_CC" | |
2243 | if test -n "$CC"; then | |
2244 | echo "$ac_t""$CC" 1>&6 | |
2245 | else | |
2246 | echo "$ac_t""no" 1>&6 | |
2247 | fi | |
2248 | ;; | |
2249 | esac | |
2250 | fi | |
2251 | test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; } | |
2252 | fi | |
2253 | ||
2254 | echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 | |
37503931 | 2255 | echo "configure:2256: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 |
252b5132 RH |
2256 | |
2257 | ac_ext=c | |
2258 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. | |
2259 | ac_cpp='$CPP $CPPFLAGS' | |
2260 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' | |
2261 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' | |
2262 | cross_compiling=$ac_cv_prog_cc_cross | |
2263 | ||
2264 | cat > conftest.$ac_ext << EOF | |
2265 | ||
37503931 | 2266 | #line 2267 "configure" |
252b5132 RH |
2267 | #include "confdefs.h" |
2268 | ||
2269 | main(){return(0);} | |
2270 | EOF | |
37503931 | 2271 | if { (eval echo configure:2272: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
252b5132 RH |
2272 | ac_cv_prog_cc_works=yes |
2273 | # If we can't run a trivial program, we are probably using a cross compiler. | |
2274 | if (./conftest; exit) 2>/dev/null; then | |
2275 | ac_cv_prog_cc_cross=no | |
2276 | else | |
2277 | ac_cv_prog_cc_cross=yes | |
2278 | fi | |
2279 | else | |
2280 | echo "configure: failed program was:" >&5 | |
2281 | cat conftest.$ac_ext >&5 | |
2282 | ac_cv_prog_cc_works=no | |
2283 | fi | |
2284 | rm -fr conftest* | |
2285 | ac_ext=c | |
2286 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. | |
2287 | ac_cpp='$CPP $CPPFLAGS' | |
2288 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' | |
2289 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' | |
2290 | cross_compiling=$ac_cv_prog_cc_cross | |
2291 | ||
2292 | echo "$ac_t""$ac_cv_prog_cc_works" 1>&6 | |
2293 | if test $ac_cv_prog_cc_works = no; then | |
2294 | { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; } | |
2295 | fi | |
2296 | echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 | |
37503931 | 2297 | echo "configure:2298: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 |
252b5132 RH |
2298 | echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6 |
2299 | cross_compiling=$ac_cv_prog_cc_cross | |
2300 | ||
2301 | echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6 | |
37503931 | 2302 | echo "configure:2303: checking whether we are using GNU C" >&5 |
252b5132 RH |
2303 | if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then |
2304 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2305 | else | |
2306 | cat > conftest.c <<EOF | |
2307 | #ifdef __GNUC__ | |
2308 | yes; | |
2309 | #endif | |
2310 | EOF | |
37503931 | 2311 | if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:2312: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then |
252b5132 RH |
2312 | ac_cv_prog_gcc=yes |
2313 | else | |
2314 | ac_cv_prog_gcc=no | |
2315 | fi | |
2316 | fi | |
2317 | ||
2318 | echo "$ac_t""$ac_cv_prog_gcc" 1>&6 | |
2319 | ||
2320 | if test $ac_cv_prog_gcc = yes; then | |
2321 | GCC=yes | |
2322 | else | |
2323 | GCC= | |
2324 | fi | |
2325 | ||
2326 | ac_test_CFLAGS="${CFLAGS+set}" | |
2327 | ac_save_CFLAGS="$CFLAGS" | |
2328 | CFLAGS= | |
2329 | echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 | |
37503931 | 2330 | echo "configure:2331: checking whether ${CC-cc} accepts -g" >&5 |
252b5132 RH |
2331 | if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then |
2332 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2333 | else | |
2334 | echo 'void f(){}' > conftest.c | |
2335 | if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then | |
2336 | ac_cv_prog_cc_g=yes | |
2337 | else | |
2338 | ac_cv_prog_cc_g=no | |
2339 | fi | |
2340 | rm -f conftest* | |
2341 | ||
2342 | fi | |
2343 | ||
2344 | echo "$ac_t""$ac_cv_prog_cc_g" 1>&6 | |
2345 | if test "$ac_test_CFLAGS" = set; then | |
2346 | CFLAGS="$ac_save_CFLAGS" | |
2347 | elif test $ac_cv_prog_cc_g = yes; then | |
2348 | if test "$GCC" = yes; then | |
2349 | CFLAGS="-g -O2" | |
2350 | else | |
2351 | CFLAGS="-g" | |
2352 | fi | |
2353 | else | |
2354 | if test "$GCC" = yes; then | |
2355 | CFLAGS="-O2" | |
2356 | else | |
2357 | CFLAGS= | |
2358 | fi | |
2359 | fi | |
2360 | ||
2361 | # Find a good install program. We prefer a C program (faster), | |
2362 | # so one script is as good as another. But avoid the broken or | |
2363 | # incompatible versions: | |
2364 | # SysV /etc/install, /usr/sbin/install | |
2365 | # SunOS /usr/etc/install | |
2366 | # IRIX /sbin/install | |
2367 | # AIX /bin/install | |
2368 | # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag | |
2369 | # AFS /usr/afsws/bin/install, which mishandles nonexistent args | |
2370 | # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" | |
2371 | # ./install, which can be erroneously created by make from ./install.sh. | |
2372 | echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6 | |
37503931 | 2373 | echo "configure:2374: checking for a BSD compatible install" >&5 |
252b5132 RH |
2374 | if test -z "$INSTALL"; then |
2375 | if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then | |
2376 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2377 | else | |
2378 | IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":" | |
2379 | for ac_dir in $PATH; do | |
2380 | # Account for people who put trailing slashes in PATH elements. | |
2381 | case "$ac_dir/" in | |
2382 | /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;; | |
2383 | *) | |
2384 | # OSF1 and SCO ODT 3.0 have their own names for install. | |
2385 | # Don't use installbsd from OSF since it installs stuff as root | |
2386 | # by default. | |
2387 | for ac_prog in ginstall scoinst install; do | |
2388 | if test -f $ac_dir/$ac_prog; then | |
2389 | if test $ac_prog = install && | |
2390 | grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then | |
2391 | # AIX install. It has an incompatible calling convention. | |
2392 | : | |
2393 | else | |
2394 | ac_cv_path_install="$ac_dir/$ac_prog -c" | |
2395 | break 2 | |
2396 | fi | |
2397 | fi | |
2398 | done | |
2399 | ;; | |
2400 | esac | |
2401 | done | |
2402 | IFS="$ac_save_IFS" | |
2403 | ||
2404 | fi | |
2405 | if test "${ac_cv_path_install+set}" = set; then | |
2406 | INSTALL="$ac_cv_path_install" | |
2407 | else | |
2408 | # As a last resort, use the slow shell script. We don't cache a | |
2409 | # path for INSTALL within a source directory, because that will | |
2410 | # break other packages using the cache if that directory is | |
2411 | # removed, or if the path is relative. | |
2412 | INSTALL="$ac_install_sh" | |
2413 | fi | |
2414 | fi | |
2415 | echo "$ac_t""$INSTALL" 1>&6 | |
2416 | ||
2417 | # Use test -z because SunOS4 sh mishandles braces in ${var-val}. | |
2418 | # It thinks the first close brace ends the variable substitution. | |
2419 | test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' | |
2420 | ||
2421 | test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}' | |
2422 | ||
2423 | test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' | |
2424 | ||
2425 | ||
5af11cab AM |
2426 | for ac_func in setmode |
2427 | do | |
2428 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
37503931 | 2429 | echo "configure:2430: checking for $ac_func" >&5 |
5af11cab AM |
2430 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
2431 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2432 | else | |
2433 | cat > conftest.$ac_ext <<EOF | |
37503931 | 2434 | #line 2435 "configure" |
5af11cab AM |
2435 | #include "confdefs.h" |
2436 | /* System header to define __stub macros and hopefully few prototypes, | |
2437 | which can conflict with char $ac_func(); below. */ | |
2438 | #include <assert.h> | |
2439 | /* Override any gcc2 internal prototype to avoid an error. */ | |
2440 | /* We use char because int might match the return type of a gcc2 | |
2441 | builtin and then its argument prototype would still apply. */ | |
2442 | char $ac_func(); | |
2443 | ||
2444 | int main() { | |
2445 | ||
2446 | /* The GNU C library defines this for functions which it implements | |
2447 | to always fail with ENOSYS. Some functions are actually named | |
2448 | something starting with __ and the normal name is an alias. */ | |
2449 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
2450 | choke me | |
2451 | #else | |
2452 | $ac_func(); | |
2453 | #endif | |
2454 | ||
2455 | ; return 0; } | |
2456 | EOF | |
37503931 | 2457 | if { (eval echo configure:2458: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
5af11cab AM |
2458 | rm -rf conftest* |
2459 | eval "ac_cv_func_$ac_func=yes" | |
2460 | else | |
2461 | echo "configure: failed program was:" >&5 | |
2462 | cat conftest.$ac_ext >&5 | |
2463 | rm -rf conftest* | |
2464 | eval "ac_cv_func_$ac_func=no" | |
2465 | fi | |
2466 | rm -f conftest* | |
2467 | fi | |
2468 | ||
2469 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then | |
2470 | echo "$ac_t""yes" 1>&6 | |
2471 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
2472 | cat >> confdefs.h <<EOF | |
2473 | #define $ac_tr_func 1 | |
2474 | EOF | |
2475 | ||
2476 | else | |
2477 | echo "$ac_t""no" 1>&6 | |
2478 | fi | |
2479 | done | |
2480 | ||
252b5132 RH |
2481 | |
2482 | ALL_LINGUAS= | |
2483 | echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6 | |
37503931 | 2484 | echo "configure:2485: checking how to run the C preprocessor" >&5 |
252b5132 RH |
2485 | # On Suns, sometimes $CPP names a directory. |
2486 | if test -n "$CPP" && test -d "$CPP"; then | |
2487 | CPP= | |
2488 | fi | |
2489 | if test -z "$CPP"; then | |
2490 | if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then | |
2491 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2492 | else | |
2493 | # This must be in double quotes, not single quotes, because CPP may get | |
2494 | # substituted into the Makefile and "${CC-cc}" will confuse make. | |
2495 | CPP="${CC-cc} -E" | |
2496 | # On the NeXT, cc -E runs the code through the compiler's parser, | |
2497 | # not just through cpp. | |
2498 | cat > conftest.$ac_ext <<EOF | |
37503931 | 2499 | #line 2500 "configure" |
252b5132 RH |
2500 | #include "confdefs.h" |
2501 | #include <assert.h> | |
2502 | Syntax Error | |
2503 | EOF | |
2504 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
37503931 | 2505 | { (eval echo configure:2506: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
252b5132 RH |
2506 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
2507 | if test -z "$ac_err"; then | |
2508 | : | |
2509 | else | |
2510 | echo "$ac_err" >&5 | |
2511 | echo "configure: failed program was:" >&5 | |
2512 | cat conftest.$ac_ext >&5 | |
2513 | rm -rf conftest* | |
2514 | CPP="${CC-cc} -E -traditional-cpp" | |
2515 | cat > conftest.$ac_ext <<EOF | |
37503931 | 2516 | #line 2517 "configure" |
252b5132 RH |
2517 | #include "confdefs.h" |
2518 | #include <assert.h> | |
2519 | Syntax Error | |
2520 | EOF | |
2521 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
37503931 | 2522 | { (eval echo configure:2523: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
252b5132 RH |
2523 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
2524 | if test -z "$ac_err"; then | |
2525 | : | |
2526 | else | |
2527 | echo "$ac_err" >&5 | |
2528 | echo "configure: failed program was:" >&5 | |
2529 | cat conftest.$ac_ext >&5 | |
2530 | rm -rf conftest* | |
2531 | CPP="${CC-cc} -nologo -E" | |
2532 | cat > conftest.$ac_ext <<EOF | |
37503931 | 2533 | #line 2534 "configure" |
252b5132 RH |
2534 | #include "confdefs.h" |
2535 | #include <assert.h> | |
2536 | Syntax Error | |
2537 | EOF | |
2538 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
37503931 | 2539 | { (eval echo configure:2540: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
252b5132 RH |
2540 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
2541 | if test -z "$ac_err"; then | |
2542 | : | |
2543 | else | |
2544 | echo "$ac_err" >&5 | |
2545 | echo "configure: failed program was:" >&5 | |
2546 | cat conftest.$ac_ext >&5 | |
2547 | rm -rf conftest* | |
2548 | CPP=/lib/cpp | |
2549 | fi | |
2550 | rm -f conftest* | |
2551 | fi | |
2552 | rm -f conftest* | |
2553 | fi | |
2554 | rm -f conftest* | |
2555 | ac_cv_prog_CPP="$CPP" | |
2556 | fi | |
2557 | CPP="$ac_cv_prog_CPP" | |
2558 | else | |
2559 | ac_cv_prog_CPP="$CPP" | |
2560 | fi | |
2561 | echo "$ac_t""$CPP" 1>&6 | |
2562 | ||
ac48eca1 AO |
2563 | # Extract the first word of "ranlib", so it can be a program name with args. |
2564 | set dummy ranlib; ac_word=$2 | |
2565 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
37503931 | 2566 | echo "configure:2567: checking for $ac_word" >&5 |
ac48eca1 AO |
2567 | if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then |
2568 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2569 | else | |
2570 | if test -n "$RANLIB"; then | |
2571 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. | |
2572 | else | |
2573 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
2574 | ac_dummy="$PATH" | |
2575 | for ac_dir in $ac_dummy; do | |
2576 | test -z "$ac_dir" && ac_dir=. | |
2577 | if test -f $ac_dir/$ac_word; then | |
2578 | ac_cv_prog_RANLIB="ranlib" | |
2579 | break | |
2580 | fi | |
2581 | done | |
2582 | IFS="$ac_save_ifs" | |
2583 | test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":" | |
2584 | fi | |
2585 | fi | |
2586 | RANLIB="$ac_cv_prog_RANLIB" | |
2587 | if test -n "$RANLIB"; then | |
2588 | echo "$ac_t""$RANLIB" 1>&6 | |
2589 | else | |
2590 | echo "$ac_t""no" 1>&6 | |
2591 | fi | |
2592 | ||
252b5132 | 2593 | echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6 |
37503931 | 2594 | echo "configure:2595: checking for ANSI C header files" >&5 |
252b5132 RH |
2595 | if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then |
2596 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2597 | else | |
2598 | cat > conftest.$ac_ext <<EOF | |
37503931 | 2599 | #line 2600 "configure" |
252b5132 RH |
2600 | #include "confdefs.h" |
2601 | #include <stdlib.h> | |
2602 | #include <stdarg.h> | |
2603 | #include <string.h> | |
2604 | #include <float.h> | |
2605 | EOF | |
2606 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
37503931 | 2607 | { (eval echo configure:2608: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
252b5132 RH |
2608 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
2609 | if test -z "$ac_err"; then | |
2610 | rm -rf conftest* | |
2611 | ac_cv_header_stdc=yes | |
2612 | else | |
2613 | echo "$ac_err" >&5 | |
2614 | echo "configure: failed program was:" >&5 | |
2615 | cat conftest.$ac_ext >&5 | |
2616 | rm -rf conftest* | |
2617 | ac_cv_header_stdc=no | |
2618 | fi | |
2619 | rm -f conftest* | |
2620 | ||
2621 | if test $ac_cv_header_stdc = yes; then | |
2622 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. | |
2623 | cat > conftest.$ac_ext <<EOF | |
37503931 | 2624 | #line 2625 "configure" |
252b5132 RH |
2625 | #include "confdefs.h" |
2626 | #include <string.h> | |
2627 | EOF | |
2628 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
2629 | egrep "memchr" >/dev/null 2>&1; then | |
2630 | : | |
2631 | else | |
2632 | rm -rf conftest* | |
2633 | ac_cv_header_stdc=no | |
2634 | fi | |
2635 | rm -f conftest* | |
2636 | ||
2637 | fi | |
2638 | ||
2639 | if test $ac_cv_header_stdc = yes; then | |
2640 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. | |
2641 | cat > conftest.$ac_ext <<EOF | |
37503931 | 2642 | #line 2643 "configure" |
252b5132 RH |
2643 | #include "confdefs.h" |
2644 | #include <stdlib.h> | |
2645 | EOF | |
2646 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
2647 | egrep "free" >/dev/null 2>&1; then | |
2648 | : | |
2649 | else | |
2650 | rm -rf conftest* | |
2651 | ac_cv_header_stdc=no | |
2652 | fi | |
2653 | rm -f conftest* | |
2654 | ||
2655 | fi | |
2656 | ||
2657 | if test $ac_cv_header_stdc = yes; then | |
2658 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. | |
2659 | if test "$cross_compiling" = yes; then | |
2660 | : | |
2661 | else | |
2662 | cat > conftest.$ac_ext <<EOF | |
37503931 | 2663 | #line 2664 "configure" |
252b5132 RH |
2664 | #include "confdefs.h" |
2665 | #include <ctype.h> | |
2666 | #define ISLOWER(c) ('a' <= (c) && (c) <= 'z') | |
2667 | #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) | |
2668 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) | |
2669 | int main () { int i; for (i = 0; i < 256; i++) | |
2670 | if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2); | |
2671 | exit (0); } | |
2672 | ||
2673 | EOF | |
37503931 | 2674 | if { (eval echo configure:2675: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
252b5132 RH |
2675 | then |
2676 | : | |
2677 | else | |
2678 | echo "configure: failed program was:" >&5 | |
2679 | cat conftest.$ac_ext >&5 | |
2680 | rm -fr conftest* | |
2681 | ac_cv_header_stdc=no | |
2682 | fi | |
2683 | rm -fr conftest* | |
2684 | fi | |
2685 | ||
2686 | fi | |
2687 | fi | |
2688 | ||
2689 | echo "$ac_t""$ac_cv_header_stdc" 1>&6 | |
2690 | if test $ac_cv_header_stdc = yes; then | |
2691 | cat >> confdefs.h <<\EOF | |
2692 | #define STDC_HEADERS 1 | |
2693 | EOF | |
2694 | ||
2695 | fi | |
2696 | ||
2697 | echo $ac_n "checking for working const""... $ac_c" 1>&6 | |
37503931 | 2698 | echo "configure:2699: checking for working const" >&5 |
252b5132 RH |
2699 | if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then |
2700 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2701 | else | |
2702 | cat > conftest.$ac_ext <<EOF | |
37503931 | 2703 | #line 2704 "configure" |
252b5132 RH |
2704 | #include "confdefs.h" |
2705 | ||
2706 | int main() { | |
2707 | ||
2708 | /* Ultrix mips cc rejects this. */ | |
2709 | typedef int charset[2]; const charset x; | |
2710 | /* SunOS 4.1.1 cc rejects this. */ | |
2711 | char const *const *ccp; | |
2712 | char **p; | |
2713 | /* NEC SVR4.0.2 mips cc rejects this. */ | |
2714 | struct point {int x, y;}; | |
2715 | static struct point const zero = {0,0}; | |
2716 | /* AIX XL C 1.02.0.0 rejects this. | |
2717 | It does not let you subtract one const X* pointer from another in an arm | |
2718 | of an if-expression whose if-part is not a constant expression */ | |
2719 | const char *g = "string"; | |
2720 | ccp = &g + (g ? g-g : 0); | |
2721 | /* HPUX 7.0 cc rejects these. */ | |
2722 | ++ccp; | |
2723 | p = (char**) ccp; | |
2724 | ccp = (char const *const *) p; | |
2725 | { /* SCO 3.2v4 cc rejects this. */ | |
2726 | char *t; | |
2727 | char const *s = 0 ? (char *) 0 : (char const *) 0; | |
2728 | ||
2729 | *t++ = 0; | |
2730 | } | |
2731 | { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ | |
2732 | int x[] = {25, 17}; | |
2733 | const int *foo = &x[0]; | |
2734 | ++foo; | |
2735 | } | |
2736 | { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ | |
2737 | typedef const int *iptr; | |
2738 | iptr p = 0; | |
2739 | ++p; | |
2740 | } | |
2741 | { /* AIX XL C 1.02.0.0 rejects this saying | |
2742 | "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ | |
2743 | struct s { int j; const int *ap[3]; }; | |
2744 | struct s *b; b->j = 5; | |
2745 | } | |
2746 | { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ | |
2747 | const int foo = 10; | |
2748 | } | |
2749 | ||
2750 | ; return 0; } | |
2751 | EOF | |
37503931 | 2752 | if { (eval echo configure:2753: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
252b5132 RH |
2753 | rm -rf conftest* |
2754 | ac_cv_c_const=yes | |
2755 | else | |
2756 | echo "configure: failed program was:" >&5 | |
2757 | cat conftest.$ac_ext >&5 | |
2758 | rm -rf conftest* | |
2759 | ac_cv_c_const=no | |
2760 | fi | |
2761 | rm -f conftest* | |
2762 | fi | |
2763 | ||
2764 | echo "$ac_t""$ac_cv_c_const" 1>&6 | |
2765 | if test $ac_cv_c_const = no; then | |
2766 | cat >> confdefs.h <<\EOF | |
2767 | #define const | |
2768 | EOF | |
2769 | ||
2770 | fi | |
2771 | ||
2772 | echo $ac_n "checking for inline""... $ac_c" 1>&6 | |
37503931 | 2773 | echo "configure:2774: checking for inline" >&5 |
252b5132 RH |
2774 | if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then |
2775 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2776 | else | |
2777 | ac_cv_c_inline=no | |
2778 | for ac_kw in inline __inline__ __inline; do | |
2779 | cat > conftest.$ac_ext <<EOF | |
37503931 | 2780 | #line 2781 "configure" |
252b5132 RH |
2781 | #include "confdefs.h" |
2782 | ||
2783 | int main() { | |
2784 | } $ac_kw foo() { | |
2785 | ; return 0; } | |
2786 | EOF | |
37503931 | 2787 | if { (eval echo configure:2788: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
252b5132 RH |
2788 | rm -rf conftest* |
2789 | ac_cv_c_inline=$ac_kw; break | |
2790 | else | |
2791 | echo "configure: failed program was:" >&5 | |
2792 | cat conftest.$ac_ext >&5 | |
2793 | fi | |
2794 | rm -f conftest* | |
2795 | done | |
2796 | ||
2797 | fi | |
2798 | ||
2799 | echo "$ac_t""$ac_cv_c_inline" 1>&6 | |
2800 | case "$ac_cv_c_inline" in | |
2801 | inline | yes) ;; | |
2802 | no) cat >> confdefs.h <<\EOF | |
2803 | #define inline | |
2804 | EOF | |
2805 | ;; | |
2806 | *) cat >> confdefs.h <<EOF | |
2807 | #define inline $ac_cv_c_inline | |
2808 | EOF | |
2809 | ;; | |
2810 | esac | |
2811 | ||
2812 | echo $ac_n "checking for off_t""... $ac_c" 1>&6 | |
37503931 | 2813 | echo "configure:2814: checking for off_t" >&5 |
252b5132 RH |
2814 | if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then |
2815 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2816 | else | |
2817 | cat > conftest.$ac_ext <<EOF | |
37503931 | 2818 | #line 2819 "configure" |
252b5132 RH |
2819 | #include "confdefs.h" |
2820 | #include <sys/types.h> | |
2821 | #if STDC_HEADERS | |
2822 | #include <stdlib.h> | |
2823 | #include <stddef.h> | |
2824 | #endif | |
2825 | EOF | |
2826 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
2827 | egrep "(^|[^a-zA-Z_0-9])off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then | |
2828 | rm -rf conftest* | |
2829 | ac_cv_type_off_t=yes | |
2830 | else | |
2831 | rm -rf conftest* | |
2832 | ac_cv_type_off_t=no | |
2833 | fi | |
2834 | rm -f conftest* | |
2835 | ||
2836 | fi | |
2837 | echo "$ac_t""$ac_cv_type_off_t" 1>&6 | |
2838 | if test $ac_cv_type_off_t = no; then | |
2839 | cat >> confdefs.h <<\EOF | |
2840 | #define off_t long | |
2841 | EOF | |
2842 | ||
2843 | fi | |
2844 | ||
2845 | echo $ac_n "checking for size_t""... $ac_c" 1>&6 | |
37503931 | 2846 | echo "configure:2847: checking for size_t" >&5 |
252b5132 RH |
2847 | if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then |
2848 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2849 | else | |
2850 | cat > conftest.$ac_ext <<EOF | |
37503931 | 2851 | #line 2852 "configure" |
252b5132 RH |
2852 | #include "confdefs.h" |
2853 | #include <sys/types.h> | |
2854 | #if STDC_HEADERS | |
2855 | #include <stdlib.h> | |
2856 | #include <stddef.h> | |
2857 | #endif | |
2858 | EOF | |
2859 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
2860 | egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then | |
2861 | rm -rf conftest* | |
2862 | ac_cv_type_size_t=yes | |
2863 | else | |
2864 | rm -rf conftest* | |
2865 | ac_cv_type_size_t=no | |
2866 | fi | |
2867 | rm -f conftest* | |
2868 | ||
2869 | fi | |
2870 | echo "$ac_t""$ac_cv_type_size_t" 1>&6 | |
2871 | if test $ac_cv_type_size_t = no; then | |
2872 | cat >> confdefs.h <<\EOF | |
2873 | #define size_t unsigned | |
2874 | EOF | |
2875 | ||
2876 | fi | |
2877 | ||
2878 | # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works | |
2879 | # for constant arguments. Useless! | |
2880 | echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6 | |
37503931 | 2881 | echo "configure:2882: checking for working alloca.h" >&5 |
252b5132 RH |
2882 | if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then |
2883 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2884 | else | |
2885 | cat > conftest.$ac_ext <<EOF | |
37503931 | 2886 | #line 2887 "configure" |
252b5132 RH |
2887 | #include "confdefs.h" |
2888 | #include <alloca.h> | |
2889 | int main() { | |
2890 | char *p = alloca(2 * sizeof(int)); | |
2891 | ; return 0; } | |
2892 | EOF | |
37503931 | 2893 | if { (eval echo configure:2894: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
252b5132 RH |
2894 | rm -rf conftest* |
2895 | ac_cv_header_alloca_h=yes | |
2896 | else | |
2897 | echo "configure: failed program was:" >&5 | |
2898 | cat conftest.$ac_ext >&5 | |
2899 | rm -rf conftest* | |
2900 | ac_cv_header_alloca_h=no | |
2901 | fi | |
2902 | rm -f conftest* | |
2903 | fi | |
2904 | ||
2905 | echo "$ac_t""$ac_cv_header_alloca_h" 1>&6 | |
2906 | if test $ac_cv_header_alloca_h = yes; then | |
2907 | cat >> confdefs.h <<\EOF | |
2908 | #define HAVE_ALLOCA_H 1 | |
2909 | EOF | |
2910 | ||
2911 | fi | |
2912 | ||
2913 | echo $ac_n "checking for alloca""... $ac_c" 1>&6 | |
37503931 | 2914 | echo "configure:2915: checking for alloca" >&5 |
252b5132 RH |
2915 | if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then |
2916 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2917 | else | |
2918 | cat > conftest.$ac_ext <<EOF | |
37503931 | 2919 | #line 2920 "configure" |
252b5132 RH |
2920 | #include "confdefs.h" |
2921 | ||
2922 | #ifdef __GNUC__ | |
2923 | # define alloca __builtin_alloca | |
2924 | #else | |
2925 | # ifdef _MSC_VER | |
2926 | # include <malloc.h> | |
2927 | # define alloca _alloca | |
2928 | # else | |
2929 | # if HAVE_ALLOCA_H | |
2930 | # include <alloca.h> | |
2931 | # else | |
2932 | # ifdef _AIX | |
2933 | #pragma alloca | |
2934 | # else | |
2935 | # ifndef alloca /* predefined by HP cc +Olibcalls */ | |
2936 | char *alloca (); | |
2937 | # endif | |
2938 | # endif | |
2939 | # endif | |
2940 | # endif | |
2941 | #endif | |
2942 | ||
2943 | int main() { | |
2944 | char *p = (char *) alloca(1); | |
2945 | ; return 0; } | |
2946 | EOF | |
37503931 | 2947 | if { (eval echo configure:2948: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
252b5132 RH |
2948 | rm -rf conftest* |
2949 | ac_cv_func_alloca_works=yes | |
2950 | else | |
2951 | echo "configure: failed program was:" >&5 | |
2952 | cat conftest.$ac_ext >&5 | |
2953 | rm -rf conftest* | |
2954 | ac_cv_func_alloca_works=no | |
2955 | fi | |
2956 | rm -f conftest* | |
2957 | fi | |
2958 | ||
2959 | echo "$ac_t""$ac_cv_func_alloca_works" 1>&6 | |
2960 | if test $ac_cv_func_alloca_works = yes; then | |
2961 | cat >> confdefs.h <<\EOF | |
2962 | #define HAVE_ALLOCA 1 | |
2963 | EOF | |
2964 | ||
2965 | fi | |
2966 | ||
2967 | if test $ac_cv_func_alloca_works = no; then | |
2968 | # The SVR3 libPW and SVR4 libucb both contain incompatible functions | |
2969 | # that cause trouble. Some versions do not even contain alloca or | |
2970 | # contain a buggy version. If you still want to use their alloca, | |
2971 | # use ar to extract alloca.o from them instead of compiling alloca.c. | |
2972 | ALLOCA=alloca.${ac_objext} | |
2973 | cat >> confdefs.h <<\EOF | |
2974 | #define C_ALLOCA 1 | |
2975 | EOF | |
2976 | ||
2977 | ||
2978 | echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6 | |
37503931 | 2979 | echo "configure:2980: checking whether alloca needs Cray hooks" >&5 |
252b5132 RH |
2980 | if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then |
2981 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2982 | else | |
2983 | cat > conftest.$ac_ext <<EOF | |
37503931 | 2984 | #line 2985 "configure" |
252b5132 RH |
2985 | #include "confdefs.h" |
2986 | #if defined(CRAY) && ! defined(CRAY2) | |
2987 | webecray | |
2988 | #else | |
2989 | wenotbecray | |
2990 | #endif | |
2991 | ||
2992 | EOF | |
2993 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
2994 | egrep "webecray" >/dev/null 2>&1; then | |
2995 | rm -rf conftest* | |
2996 | ac_cv_os_cray=yes | |
2997 | else | |
2998 | rm -rf conftest* | |
2999 | ac_cv_os_cray=no | |
3000 | fi | |
3001 | rm -f conftest* | |
3002 | ||
3003 | fi | |
3004 | ||
3005 | echo "$ac_t""$ac_cv_os_cray" 1>&6 | |
3006 | if test $ac_cv_os_cray = yes; then | |
3007 | for ac_func in _getb67 GETB67 getb67; do | |
3008 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
37503931 | 3009 | echo "configure:3010: checking for $ac_func" >&5 |
252b5132 RH |
3010 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
3011 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3012 | else | |
3013 | cat > conftest.$ac_ext <<EOF | |
37503931 | 3014 | #line 3015 "configure" |
252b5132 RH |
3015 | #include "confdefs.h" |
3016 | /* System header to define __stub macros and hopefully few prototypes, | |
3017 | which can conflict with char $ac_func(); below. */ | |
3018 | #include <assert.h> | |
3019 | /* Override any gcc2 internal prototype to avoid an error. */ | |
3020 | /* We use char because int might match the return type of a gcc2 | |
3021 | builtin and then its argument prototype would still apply. */ | |
3022 | char $ac_func(); | |
3023 | ||
3024 | int main() { | |
3025 | ||
3026 | /* The GNU C library defines this for functions which it implements | |
3027 | to always fail with ENOSYS. Some functions are actually named | |
3028 | something starting with __ and the normal name is an alias. */ | |
3029 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
3030 | choke me | |
3031 | #else | |
3032 | $ac_func(); | |
3033 | #endif | |
3034 | ||
3035 | ; return 0; } | |
3036 | EOF | |
37503931 | 3037 | if { (eval echo configure:3038: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
252b5132 RH |
3038 | rm -rf conftest* |
3039 | eval "ac_cv_func_$ac_func=yes" | |
3040 | else | |
3041 | echo "configure: failed program was:" >&5 | |
3042 | cat conftest.$ac_ext >&5 | |
3043 | rm -rf conftest* | |
3044 | eval "ac_cv_func_$ac_func=no" | |
3045 | fi | |
3046 | rm -f conftest* | |
3047 | fi | |
3048 | ||
3049 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then | |
3050 | echo "$ac_t""yes" 1>&6 | |
3051 | cat >> confdefs.h <<EOF | |
3052 | #define CRAY_STACKSEG_END $ac_func | |
3053 | EOF | |
3054 | ||
3055 | break | |
3056 | else | |
3057 | echo "$ac_t""no" 1>&6 | |
3058 | fi | |
3059 | ||
3060 | done | |
3061 | fi | |
3062 | ||
3063 | echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6 | |
37503931 | 3064 | echo "configure:3065: checking stack direction for C alloca" >&5 |
252b5132 RH |
3065 | if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then |
3066 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3067 | else | |
3068 | if test "$cross_compiling" = yes; then | |
3069 | ac_cv_c_stack_direction=0 | |
3070 | else | |
3071 | cat > conftest.$ac_ext <<EOF | |
37503931 | 3072 | #line 3073 "configure" |
252b5132 RH |
3073 | #include "confdefs.h" |
3074 | find_stack_direction () | |
3075 | { | |
3076 | static char *addr = 0; | |
3077 | auto char dummy; | |
3078 | if (addr == 0) | |
3079 | { | |
3080 | addr = &dummy; | |
3081 | return find_stack_direction (); | |
3082 | } | |
3083 | else | |
3084 | return (&dummy > addr) ? 1 : -1; | |
3085 | } | |
3086 | main () | |
3087 | { | |
3088 | exit (find_stack_direction() < 0); | |
3089 | } | |
3090 | EOF | |
37503931 | 3091 | if { (eval echo configure:3092: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
252b5132 RH |
3092 | then |
3093 | ac_cv_c_stack_direction=1 | |
3094 | else | |
3095 | echo "configure: failed program was:" >&5 | |
3096 | cat conftest.$ac_ext >&5 | |
3097 | rm -fr conftest* | |
3098 | ac_cv_c_stack_direction=-1 | |
3099 | fi | |
3100 | rm -fr conftest* | |
3101 | fi | |
3102 | ||
3103 | fi | |
3104 | ||
3105 | echo "$ac_t""$ac_cv_c_stack_direction" 1>&6 | |
3106 | cat >> confdefs.h <<EOF | |
3107 | #define STACK_DIRECTION $ac_cv_c_stack_direction | |
3108 | EOF | |
3109 | ||
3110 | fi | |
3111 | ||
3112 | for ac_hdr in unistd.h | |
3113 | do | |
3114 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` | |
3115 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 | |
37503931 | 3116 | echo "configure:3117: checking for $ac_hdr" >&5 |
252b5132 RH |
3117 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
3118 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3119 | else | |
3120 | cat > conftest.$ac_ext <<EOF | |
37503931 | 3121 | #line 3122 "configure" |
252b5132 RH |
3122 | #include "confdefs.h" |
3123 | #include <$ac_hdr> | |
3124 | EOF | |
3125 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
37503931 | 3126 | { (eval echo configure:3127: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
252b5132 RH |
3127 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
3128 | if test -z "$ac_err"; then | |
3129 | rm -rf conftest* | |
3130 | eval "ac_cv_header_$ac_safe=yes" | |
3131 | else | |
3132 | echo "$ac_err" >&5 | |
3133 | echo "configure: failed program was:" >&5 | |
3134 | cat conftest.$ac_ext >&5 | |
3135 | rm -rf conftest* | |
3136 | eval "ac_cv_header_$ac_safe=no" | |
3137 | fi | |
3138 | rm -f conftest* | |
3139 | fi | |
3140 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | |
3141 | echo "$ac_t""yes" 1>&6 | |
3142 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` | |
3143 | cat >> confdefs.h <<EOF | |
3144 | #define $ac_tr_hdr 1 | |
3145 | EOF | |
3146 | ||
3147 | else | |
3148 | echo "$ac_t""no" 1>&6 | |
3149 | fi | |
3150 | done | |
3151 | ||
3152 | for ac_func in getpagesize | |
3153 | do | |
3154 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
37503931 | 3155 | echo "configure:3156: checking for $ac_func" >&5 |
252b5132 RH |
3156 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
3157 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3158 | else | |
3159 | cat > conftest.$ac_ext <<EOF | |
37503931 | 3160 | #line 3161 "configure" |
252b5132 RH |
3161 | #include "confdefs.h" |
3162 | /* System header to define __stub macros and hopefully few prototypes, | |
3163 | which can conflict with char $ac_func(); below. */ | |
3164 | #include <assert.h> | |
3165 | /* Override any gcc2 internal prototype to avoid an error. */ | |
3166 | /* We use char because int might match the return type of a gcc2 | |
3167 | builtin and then its argument prototype would still apply. */ | |
3168 | char $ac_func(); | |
3169 | ||
3170 | int main() { | |
3171 | ||
3172 | /* The GNU C library defines this for functions which it implements | |
3173 | to always fail with ENOSYS. Some functions are actually named | |
3174 | something starting with __ and the normal name is an alias. */ | |
3175 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
3176 | choke me | |
3177 | #else | |
3178 | $ac_func(); | |
3179 | #endif | |
3180 | ||
3181 | ; return 0; } | |
3182 | EOF | |
37503931 | 3183 | if { (eval echo configure:3184: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
252b5132 RH |
3184 | rm -rf conftest* |
3185 | eval "ac_cv_func_$ac_func=yes" | |
3186 | else | |
3187 | echo "configure: failed program was:" >&5 | |
3188 | cat conftest.$ac_ext >&5 | |
3189 | rm -rf conftest* | |
3190 | eval "ac_cv_func_$ac_func=no" | |
3191 | fi | |
3192 | rm -f conftest* | |
3193 | fi | |
3194 | ||
3195 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then | |
3196 | echo "$ac_t""yes" 1>&6 | |
3197 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
3198 | cat >> confdefs.h <<EOF | |
3199 | #define $ac_tr_func 1 | |
3200 | EOF | |
3201 | ||
3202 | else | |
3203 | echo "$ac_t""no" 1>&6 | |
3204 | fi | |
3205 | done | |
3206 | ||
3207 | echo $ac_n "checking for working mmap""... $ac_c" 1>&6 | |
37503931 | 3208 | echo "configure:3209: checking for working mmap" >&5 |
252b5132 RH |
3209 | if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then |
3210 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3211 | else | |
3212 | if test "$cross_compiling" = yes; then | |
3213 | ac_cv_func_mmap_fixed_mapped=no | |
3214 | else | |
3215 | cat > conftest.$ac_ext <<EOF | |
37503931 | 3216 | #line 3217 "configure" |
252b5132 RH |
3217 | #include "confdefs.h" |
3218 | ||
3219 | /* Thanks to Mike Haertel and Jim Avera for this test. | |
3220 | Here is a matrix of mmap possibilities: | |
3221 | mmap private not fixed | |
3222 | mmap private fixed at somewhere currently unmapped | |
3223 | mmap private fixed at somewhere already mapped | |
3224 | mmap shared not fixed | |
3225 | mmap shared fixed at somewhere currently unmapped | |
3226 | mmap shared fixed at somewhere already mapped | |
3227 | For private mappings, we should verify that changes cannot be read() | |
3228 | back from the file, nor mmap's back from the file at a different | |
3229 | address. (There have been systems where private was not correctly | |
3230 | implemented like the infamous i386 svr4.0, and systems where the | |
3231 | VM page cache was not coherent with the filesystem buffer cache | |
3232 | like early versions of FreeBSD and possibly contemporary NetBSD.) | |
3233 | For shared mappings, we should conversely verify that changes get | |
3234 | propogated back to all the places they're supposed to be. | |
3235 | ||
3236 | Grep wants private fixed already mapped. | |
3237 | The main things grep needs to know about mmap are: | |
3238 | * does it exist and is it safe to write into the mmap'd area | |
3239 | * how to use it (BSD variants) */ | |
3240 | #include <sys/types.h> | |
3241 | #include <fcntl.h> | |
3242 | #include <sys/mman.h> | |
3243 | ||
3244 | /* This mess was copied from the GNU getpagesize.h. */ | |
3245 | #ifndef HAVE_GETPAGESIZE | |
3246 | # ifdef HAVE_UNISTD_H | |
3247 | # include <unistd.h> | |
3248 | # endif | |
3249 | ||
3250 | /* Assume that all systems that can run configure have sys/param.h. */ | |
3251 | # ifndef HAVE_SYS_PARAM_H | |
3252 | # define HAVE_SYS_PARAM_H 1 | |
3253 | # endif | |
3254 | ||
3255 | # ifdef _SC_PAGESIZE | |
3256 | # define getpagesize() sysconf(_SC_PAGESIZE) | |
3257 | # else /* no _SC_PAGESIZE */ | |
3258 | # ifdef HAVE_SYS_PARAM_H | |
3259 | # include <sys/param.h> | |
3260 | # ifdef EXEC_PAGESIZE | |
3261 | # define getpagesize() EXEC_PAGESIZE | |
3262 | # else /* no EXEC_PAGESIZE */ | |
3263 | # ifdef NBPG | |
3264 | # define getpagesize() NBPG * CLSIZE | |
3265 | # ifndef CLSIZE | |
3266 | # define CLSIZE 1 | |
3267 | # endif /* no CLSIZE */ | |
3268 | # else /* no NBPG */ | |
3269 | # ifdef NBPC | |
3270 | # define getpagesize() NBPC | |
3271 | # else /* no NBPC */ | |
3272 | # ifdef PAGESIZE | |
3273 | # define getpagesize() PAGESIZE | |
3274 | # endif /* PAGESIZE */ | |
3275 | # endif /* no NBPC */ | |
3276 | # endif /* no NBPG */ | |
3277 | # endif /* no EXEC_PAGESIZE */ | |
3278 | # else /* no HAVE_SYS_PARAM_H */ | |
3279 | # define getpagesize() 8192 /* punt totally */ | |
3280 | # endif /* no HAVE_SYS_PARAM_H */ | |
3281 | # endif /* no _SC_PAGESIZE */ | |
3282 | ||
3283 | #endif /* no HAVE_GETPAGESIZE */ | |
3284 | ||
3285 | #ifdef __cplusplus | |
3286 | extern "C" { void *malloc(unsigned); } | |
3287 | #else | |
3288 | char *malloc(); | |
3289 | #endif | |
3290 | ||
3291 | int | |
3292 | main() | |
3293 | { | |
3294 | char *data, *data2, *data3; | |
3295 | int i, pagesize; | |
3296 | int fd; | |
3297 | ||
3298 | pagesize = getpagesize(); | |
3299 | ||
3300 | /* | |
3301 | * First, make a file with some known garbage in it. | |
3302 | */ | |
3303 | data = malloc(pagesize); | |
3304 | if (!data) | |
3305 | exit(1); | |
3306 | for (i = 0; i < pagesize; ++i) | |
3307 | *(data + i) = rand(); | |
3308 | umask(0); | |
3309 | fd = creat("conftestmmap", 0600); | |
3310 | if (fd < 0) | |
3311 | exit(1); | |
3312 | if (write(fd, data, pagesize) != pagesize) | |
3313 | exit(1); | |
3314 | close(fd); | |
3315 | ||
3316 | /* | |
3317 | * Next, try to mmap the file at a fixed address which | |
3318 | * already has something else allocated at it. If we can, | |
3319 | * also make sure that we see the same garbage. | |
3320 | */ | |
3321 | fd = open("conftestmmap", O_RDWR); | |
3322 | if (fd < 0) | |
3323 | exit(1); | |
3324 | data2 = malloc(2 * pagesize); | |
3325 | if (!data2) | |
3326 | exit(1); | |
3327 | data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1); | |
3328 | if (data2 != mmap(data2, pagesize, PROT_READ | PROT_WRITE, | |
3329 | MAP_PRIVATE | MAP_FIXED, fd, 0L)) | |
3330 | exit(1); | |
3331 | for (i = 0; i < pagesize; ++i) | |
3332 | if (*(data + i) != *(data2 + i)) | |
3333 | exit(1); | |
3334 | ||
3335 | /* | |
3336 | * Finally, make sure that changes to the mapped area | |
3337 | * do not percolate back to the file as seen by read(). | |
3338 | * (This is a bug on some variants of i386 svr4.0.) | |
3339 | */ | |
3340 | for (i = 0; i < pagesize; ++i) | |
3341 | *(data2 + i) = *(data2 + i) + 1; | |
3342 | data3 = malloc(pagesize); | |
3343 | if (!data3) | |
3344 | exit(1); | |
3345 | if (read(fd, data3, pagesize) != pagesize) | |
3346 | exit(1); | |
3347 | for (i = 0; i < pagesize; ++i) | |
3348 | if (*(data + i) != *(data3 + i)) | |
3349 | exit(1); | |
3350 | close(fd); | |
3351 | unlink("conftestmmap"); | |
3352 | exit(0); | |
3353 | } | |
3354 | ||
3355 | EOF | |
37503931 | 3356 | if { (eval echo configure:3357: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
252b5132 RH |
3357 | then |
3358 | ac_cv_func_mmap_fixed_mapped=yes | |
3359 | else | |
3360 | echo "configure: failed program was:" >&5 | |
3361 | cat conftest.$ac_ext >&5 | |
3362 | rm -fr conftest* | |
3363 | ac_cv_func_mmap_fixed_mapped=no | |
3364 | fi | |
3365 | rm -fr conftest* | |
3366 | fi | |
3367 | ||
3368 | fi | |
3369 | ||
3370 | echo "$ac_t""$ac_cv_func_mmap_fixed_mapped" 1>&6 | |
3371 | if test $ac_cv_func_mmap_fixed_mapped = yes; then | |
3372 | cat >> confdefs.h <<\EOF | |
3373 | #define HAVE_MMAP 1 | |
3374 | EOF | |
3375 | ||
3376 | fi | |
3377 | ||
3378 | ||
3379 | for ac_hdr in argz.h limits.h locale.h nl_types.h malloc.h string.h \ | |
3380 | unistd.h values.h sys/param.h | |
3381 | do | |
3382 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` | |
3383 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 | |
37503931 | 3384 | echo "configure:3385: checking for $ac_hdr" >&5 |
252b5132 RH |
3385 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
3386 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3387 | else | |
3388 | cat > conftest.$ac_ext <<EOF | |
37503931 | 3389 | #line 3390 "configure" |
252b5132 RH |
3390 | #include "confdefs.h" |
3391 | #include <$ac_hdr> | |
3392 | EOF | |
3393 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
37503931 | 3394 | { (eval echo configure:3395: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
252b5132 RH |
3395 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
3396 | if test -z "$ac_err"; then | |
3397 | rm -rf conftest* | |
3398 | eval "ac_cv_header_$ac_safe=yes" | |
3399 | else | |
3400 | echo "$ac_err" >&5 | |
3401 | echo "configure: failed program was:" >&5 | |
3402 | cat conftest.$ac_ext >&5 | |
3403 | rm -rf conftest* | |
3404 | eval "ac_cv_header_$ac_safe=no" | |
3405 | fi | |
3406 | rm -f conftest* | |
3407 | fi | |
3408 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | |
3409 | echo "$ac_t""yes" 1>&6 | |
3410 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` | |
3411 | cat >> confdefs.h <<EOF | |
3412 | #define $ac_tr_hdr 1 | |
3413 | EOF | |
3414 | ||
3415 | else | |
3416 | echo "$ac_t""no" 1>&6 | |
3417 | fi | |
3418 | done | |
3419 | ||
3420 | for ac_func in getcwd munmap putenv setenv setlocale strchr strcasecmp \ | |
3421 | __argz_count __argz_stringify __argz_next | |
3422 | do | |
3423 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
37503931 | 3424 | echo "configure:3425: checking for $ac_func" >&5 |
252b5132 RH |
3425 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
3426 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3427 | else | |
3428 | cat > conftest.$ac_ext <<EOF | |
37503931 | 3429 | #line 3430 "configure" |
252b5132 RH |
3430 | #include "confdefs.h" |
3431 | /* System header to define __stub macros and hopefully few prototypes, | |
3432 | which can conflict with char $ac_func(); below. */ | |
3433 | #include <assert.h> | |
3434 | /* Override any gcc2 internal prototype to avoid an error. */ | |
3435 | /* We use char because int might match the return type of a gcc2 | |
3436 | builtin and then its argument prototype would still apply. */ | |
3437 | char $ac_func(); | |
3438 | ||
3439 | int main() { | |
3440 | ||
3441 | /* The GNU C library defines this for functions which it implements | |
3442 | to always fail with ENOSYS. Some functions are actually named | |
3443 | something starting with __ and the normal name is an alias. */ | |
3444 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
3445 | choke me | |
3446 | #else | |
3447 | $ac_func(); | |
3448 | #endif | |
3449 | ||
3450 | ; return 0; } | |
3451 | EOF | |
37503931 | 3452 | if { (eval echo configure:3453: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
252b5132 RH |
3453 | rm -rf conftest* |
3454 | eval "ac_cv_func_$ac_func=yes" | |
3455 | else | |
3456 | echo "configure: failed program was:" >&5 | |
3457 | cat conftest.$ac_ext >&5 | |
3458 | rm -rf conftest* | |
3459 | eval "ac_cv_func_$ac_func=no" | |
3460 | fi | |
3461 | rm -f conftest* | |
3462 | fi | |
3463 | ||
3464 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then | |
3465 | echo "$ac_t""yes" 1>&6 | |
3466 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
3467 | cat >> confdefs.h <<EOF | |
3468 | #define $ac_tr_func 1 | |
3469 | EOF | |
3470 | ||
3471 | else | |
3472 | echo "$ac_t""no" 1>&6 | |
3473 | fi | |
3474 | done | |
3475 | ||
3476 | ||
3477 | if test "${ac_cv_func_stpcpy+set}" != "set"; then | |
3478 | for ac_func in stpcpy | |
3479 | do | |
3480 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
37503931 | 3481 | echo "configure:3482: checking for $ac_func" >&5 |
252b5132 RH |
3482 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
3483 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3484 | else | |
3485 | cat > conftest.$ac_ext <<EOF | |
37503931 | 3486 | #line 3487 "configure" |
252b5132 RH |
3487 | #include "confdefs.h" |
3488 | /* System header to define __stub macros and hopefully few prototypes, | |
3489 | which can conflict with char $ac_func(); below. */ | |
3490 | #include <assert.h> | |
3491 | /* Override any gcc2 internal prototype to avoid an error. */ | |
3492 | /* We use char because int might match the return type of a gcc2 | |
3493 | builtin and then its argument prototype would still apply. */ | |
3494 | char $ac_func(); | |
3495 | ||
3496 | int main() { | |
3497 | ||
3498 | /* The GNU C library defines this for functions which it implements | |
3499 | to always fail with ENOSYS. Some functions are actually named | |
3500 | something starting with __ and the normal name is an alias. */ | |
3501 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
3502 | choke me | |
3503 | #else | |
3504 | $ac_func(); | |
3505 | #endif | |
3506 | ||
3507 | ; return 0; } | |
3508 | EOF | |
37503931 | 3509 | if { (eval echo configure:3510: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
252b5132 RH |
3510 | rm -rf conftest* |
3511 | eval "ac_cv_func_$ac_func=yes" | |
3512 | else | |
3513 | echo "configure: failed program was:" >&5 | |
3514 | cat conftest.$ac_ext >&5 | |
3515 | rm -rf conftest* | |
3516 | eval "ac_cv_func_$ac_func=no" | |
3517 | fi | |
3518 | rm -f conftest* | |
3519 | fi | |
3520 | ||
3521 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then | |
3522 | echo "$ac_t""yes" 1>&6 | |
3523 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
3524 | cat >> confdefs.h <<EOF | |
3525 | #define $ac_tr_func 1 | |
3526 | EOF | |
3527 | ||
3528 | else | |
3529 | echo "$ac_t""no" 1>&6 | |
3530 | fi | |
3531 | done | |
3532 | ||
3533 | fi | |
3534 | if test "${ac_cv_func_stpcpy}" = "yes"; then | |
3535 | cat >> confdefs.h <<\EOF | |
3536 | #define HAVE_STPCPY 1 | |
3537 | EOF | |
3538 | ||
3539 | fi | |
3540 | ||
3541 | if test $ac_cv_header_locale_h = yes; then | |
3542 | echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6 | |
37503931 | 3543 | echo "configure:3544: checking for LC_MESSAGES" >&5 |
252b5132 RH |
3544 | if eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then |
3545 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3546 | else | |
3547 | cat > conftest.$ac_ext <<EOF | |
37503931 | 3548 | #line 3549 "configure" |
252b5132 RH |
3549 | #include "confdefs.h" |
3550 | #include <locale.h> | |
3551 | int main() { | |
3552 | return LC_MESSAGES | |
3553 | ; return 0; } | |
3554 | EOF | |
37503931 | 3555 | if { (eval echo configure:3556: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
252b5132 RH |
3556 | rm -rf conftest* |
3557 | am_cv_val_LC_MESSAGES=yes | |
3558 | else | |
3559 | echo "configure: failed program was:" >&5 | |
3560 | cat conftest.$ac_ext >&5 | |
3561 | rm -rf conftest* | |
3562 | am_cv_val_LC_MESSAGES=no | |
3563 | fi | |
3564 | rm -f conftest* | |
3565 | fi | |
3566 | ||
3567 | echo "$ac_t""$am_cv_val_LC_MESSAGES" 1>&6 | |
3568 | if test $am_cv_val_LC_MESSAGES = yes; then | |
3569 | cat >> confdefs.h <<\EOF | |
3570 | #define HAVE_LC_MESSAGES 1 | |
3571 | EOF | |
3572 | ||
3573 | fi | |
3574 | fi | |
3575 | echo $ac_n "checking whether NLS is requested""... $ac_c" 1>&6 | |
37503931 | 3576 | echo "configure:3577: checking whether NLS is requested" >&5 |
252b5132 RH |
3577 | # Check whether --enable-nls or --disable-nls was given. |
3578 | if test "${enable_nls+set}" = set; then | |
3579 | enableval="$enable_nls" | |
3580 | USE_NLS=$enableval | |
3581 | else | |
3582 | USE_NLS=yes | |
3583 | fi | |
3584 | ||
3585 | echo "$ac_t""$USE_NLS" 1>&6 | |
3586 | ||
3587 | ||
3588 | USE_INCLUDED_LIBINTL=no | |
3589 | ||
3590 | if test "$USE_NLS" = "yes"; then | |
3591 | cat >> confdefs.h <<\EOF | |
3592 | #define ENABLE_NLS 1 | |
3593 | EOF | |
3594 | ||
3595 | echo $ac_n "checking whether included gettext is requested""... $ac_c" 1>&6 | |
37503931 | 3596 | echo "configure:3597: checking whether included gettext is requested" >&5 |
252b5132 RH |
3597 | # Check whether --with-included-gettext or --without-included-gettext was given. |
3598 | if test "${with_included_gettext+set}" = set; then | |
3599 | withval="$with_included_gettext" | |
3600 | nls_cv_force_use_gnu_gettext=$withval | |
3601 | else | |
3602 | nls_cv_force_use_gnu_gettext=no | |
3603 | fi | |
3604 | ||
3605 | echo "$ac_t""$nls_cv_force_use_gnu_gettext" 1>&6 | |
3606 | ||
3607 | nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext" | |
3608 | if test "$nls_cv_force_use_gnu_gettext" != "yes"; then | |
3609 | nls_cv_header_intl= | |
3610 | nls_cv_header_libgt= | |
3611 | CATOBJEXT=NONE | |
3612 | ||
3613 | ac_safe=`echo "libintl.h" | sed 'y%./+-%__p_%'` | |
3614 | echo $ac_n "checking for libintl.h""... $ac_c" 1>&6 | |
37503931 | 3615 | echo "configure:3616: checking for libintl.h" >&5 |
252b5132 RH |
3616 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
3617 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3618 | else | |
3619 | cat > conftest.$ac_ext <<EOF | |
37503931 | 3620 | #line 3621 "configure" |
252b5132 RH |
3621 | #include "confdefs.h" |
3622 | #include <libintl.h> | |
3623 | EOF | |
3624 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
37503931 | 3625 | { (eval echo configure:3626: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
252b5132 RH |
3626 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
3627 | if test -z "$ac_err"; then | |
3628 | rm -rf conftest* | |
3629 | eval "ac_cv_header_$ac_safe=yes" | |
3630 | else | |
3631 | echo "$ac_err" >&5 | |
3632 | echo "configure: failed program was:" >&5 | |
3633 | cat conftest.$ac_ext >&5 | |
3634 | rm -rf conftest* | |
3635 | eval "ac_cv_header_$ac_safe=no" | |
3636 | fi | |
3637 | rm -f conftest* | |
3638 | fi | |
3639 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | |
3640 | echo "$ac_t""yes" 1>&6 | |
3641 | echo $ac_n "checking for gettext in libc""... $ac_c" 1>&6 | |
37503931 | 3642 | echo "configure:3643: checking for gettext in libc" >&5 |
252b5132 RH |
3643 | if eval "test \"`echo '$''{'gt_cv_func_gettext_libc'+set}'`\" = set"; then |
3644 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3645 | else | |
3646 | cat > conftest.$ac_ext <<EOF | |
37503931 | 3647 | #line 3648 "configure" |
252b5132 RH |
3648 | #include "confdefs.h" |
3649 | #include <libintl.h> | |
3650 | int main() { | |
3651 | return (int) gettext ("") | |
3652 | ; return 0; } | |
3653 | EOF | |
37503931 | 3654 | if { (eval echo configure:3655: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
252b5132 RH |
3655 | rm -rf conftest* |
3656 | gt_cv_func_gettext_libc=yes | |
3657 | else | |
3658 | echo "configure: failed program was:" >&5 | |
3659 | cat conftest.$ac_ext >&5 | |
3660 | rm -rf conftest* | |
3661 | gt_cv_func_gettext_libc=no | |
3662 | fi | |
3663 | rm -f conftest* | |
3664 | fi | |
3665 | ||
3666 | echo "$ac_t""$gt_cv_func_gettext_libc" 1>&6 | |
3667 | ||
3668 | if test "$gt_cv_func_gettext_libc" != "yes"; then | |
3669 | echo $ac_n "checking for bindtextdomain in -lintl""... $ac_c" 1>&6 | |
37503931 | 3670 | echo "configure:3671: checking for bindtextdomain in -lintl" >&5 |
252b5132 RH |
3671 | ac_lib_var=`echo intl'_'bindtextdomain | sed 'y%./+-%__p_%'` |
3672 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then | |
3673 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3674 | else | |
3675 | ac_save_LIBS="$LIBS" | |
3676 | LIBS="-lintl $LIBS" | |
3677 | cat > conftest.$ac_ext <<EOF | |
37503931 | 3678 | #line 3679 "configure" |
252b5132 RH |
3679 | #include "confdefs.h" |
3680 | /* Override any gcc2 internal prototype to avoid an error. */ | |
3681 | /* We use char because int might match the return type of a gcc2 | |
3682 | builtin and then its argument prototype would still apply. */ | |
3683 | char bindtextdomain(); | |
3684 | ||
3685 | int main() { | |
3686 | bindtextdomain() | |
3687 | ; return 0; } | |
3688 | EOF | |
37503931 | 3689 | if { (eval echo configure:3690: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
252b5132 RH |
3690 | rm -rf conftest* |
3691 | eval "ac_cv_lib_$ac_lib_var=yes" | |
3692 | else | |
3693 | echo "configure: failed program was:" >&5 | |
3694 | cat conftest.$ac_ext >&5 | |
3695 | rm -rf conftest* | |
3696 | eval "ac_cv_lib_$ac_lib_var=no" | |
3697 | fi | |
3698 | rm -f conftest* | |
3699 | LIBS="$ac_save_LIBS" | |
3700 | ||
3701 | fi | |
3702 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then | |
3703 | echo "$ac_t""yes" 1>&6 | |
3704 | echo $ac_n "checking for gettext in libintl""... $ac_c" 1>&6 | |
37503931 | 3705 | echo "configure:3706: checking for gettext in libintl" >&5 |
252b5132 RH |
3706 | if eval "test \"`echo '$''{'gt_cv_func_gettext_libintl'+set}'`\" = set"; then |
3707 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3708 | else | |
3709 | cat > conftest.$ac_ext <<EOF | |
37503931 | 3710 | #line 3711 "configure" |
252b5132 RH |
3711 | #include "confdefs.h" |
3712 | ||
3713 | int main() { | |
3714 | return (int) gettext ("") | |
3715 | ; return 0; } | |
3716 | EOF | |
37503931 | 3717 | if { (eval echo configure:3718: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
252b5132 RH |
3718 | rm -rf conftest* |
3719 | gt_cv_func_gettext_libintl=yes | |
3720 | else | |
3721 | echo "configure: failed program was:" >&5 | |
3722 | cat conftest.$ac_ext >&5 | |
3723 | rm -rf conftest* | |
3724 | gt_cv_func_gettext_libintl=no | |
3725 | fi | |
3726 | rm -f conftest* | |
3727 | fi | |
3728 | ||
3729 | echo "$ac_t""$gt_cv_func_gettext_libintl" 1>&6 | |
3730 | else | |
3731 | echo "$ac_t""no" 1>&6 | |
3732 | fi | |
3733 | ||
3734 | fi | |
3735 | ||
3736 | if test "$gt_cv_func_gettext_libc" = "yes" \ | |
3737 | || test "$gt_cv_func_gettext_libintl" = "yes"; then | |
3738 | cat >> confdefs.h <<\EOF | |
3739 | #define HAVE_GETTEXT 1 | |
3740 | EOF | |
3741 | ||
3742 | # Extract the first word of "msgfmt", so it can be a program name with args. | |
3743 | set dummy msgfmt; ac_word=$2 | |
3744 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
37503931 | 3745 | echo "configure:3746: checking for $ac_word" >&5 |
252b5132 RH |
3746 | if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then |
3747 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3748 | else | |
3749 | case "$MSGFMT" in | |
3750 | /*) | |
3751 | ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. | |
3752 | ;; | |
3753 | *) | |
3754 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" | |
3755 | for ac_dir in $PATH; do | |
3756 | test -z "$ac_dir" && ac_dir=. | |
3757 | if test -f $ac_dir/$ac_word; then | |
3758 | if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then | |
3759 | ac_cv_path_MSGFMT="$ac_dir/$ac_word" | |
3760 | break | |
3761 | fi | |
3762 | fi | |
3763 | done | |
3764 | IFS="$ac_save_ifs" | |
3765 | test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="no" | |
3766 | ;; | |
3767 | esac | |
3768 | fi | |
3769 | MSGFMT="$ac_cv_path_MSGFMT" | |
3770 | if test -n "$MSGFMT"; then | |
3771 | echo "$ac_t""$MSGFMT" 1>&6 | |
3772 | else | |
3773 | echo "$ac_t""no" 1>&6 | |
3774 | fi | |
3775 | if test "$MSGFMT" != "no"; then | |
3776 | for ac_func in dcgettext | |
3777 | do | |
3778 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
37503931 | 3779 | echo "configure:3780: checking for $ac_func" >&5 |
252b5132 RH |
3780 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
3781 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3782 | else | |
3783 | cat > conftest.$ac_ext <<EOF | |
37503931 | 3784 | #line 3785 "configure" |
252b5132 RH |
3785 | #include "confdefs.h" |
3786 | /* System header to define __stub macros and hopefully few prototypes, | |
3787 | which can conflict with char $ac_func(); below. */ | |
3788 | #include <assert.h> | |
3789 | /* Override any gcc2 internal prototype to avoid an error. */ | |
3790 | /* We use char because int might match the return type of a gcc2 | |
3791 | builtin and then its argument prototype would still apply. */ | |
3792 | char $ac_func(); | |
3793 | ||
3794 | int main() { | |
3795 | ||
3796 | /* The GNU C library defines this for functions which it implements | |
3797 | to always fail with ENOSYS. Some functions are actually named | |
3798 | something starting with __ and the normal name is an alias. */ | |
3799 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
3800 | choke me | |
3801 | #else | |
3802 | $ac_func(); | |
3803 | #endif | |
3804 | ||
3805 | ; return 0; } | |
3806 | EOF | |
37503931 | 3807 | if { (eval echo configure:3808: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
252b5132 RH |
3808 | rm -rf conftest* |
3809 | eval "ac_cv_func_$ac_func=yes" | |
3810 | else | |
3811 | echo "configure: failed program was:" >&5 | |
3812 | cat conftest.$ac_ext >&5 | |
3813 | rm -rf conftest* | |
3814 | eval "ac_cv_func_$ac_func=no" | |
3815 | fi | |
3816 | rm -f conftest* | |
3817 | fi | |
3818 | ||
3819 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then | |
3820 | echo "$ac_t""yes" 1>&6 | |
3821 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
3822 | cat >> confdefs.h <<EOF | |
3823 | #define $ac_tr_func 1 | |
3824 | EOF | |
3825 | ||
3826 | else | |
3827 | echo "$ac_t""no" 1>&6 | |
3828 | fi | |
3829 | done | |
3830 | ||
3831 | # Extract the first word of "gmsgfmt", so it can be a program name with args. | |
3832 | set dummy gmsgfmt; ac_word=$2 | |
3833 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
37503931 | 3834 | echo "configure:3835: checking for $ac_word" >&5 |
252b5132 RH |
3835 | if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then |
3836 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3837 | else | |
3838 | case "$GMSGFMT" in | |
3839 | /*) | |
3840 | ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path. | |
3841 | ;; | |
3842 | ?:/*) | |
3843 | ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path. | |
3844 | ;; | |
3845 | *) | |
3846 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
3847 | ac_dummy="$PATH" | |
3848 | for ac_dir in $ac_dummy; do | |
3849 | test -z "$ac_dir" && ac_dir=. | |
3850 | if test -f $ac_dir/$ac_word; then | |
3851 | ac_cv_path_GMSGFMT="$ac_dir/$ac_word" | |
3852 | break | |
3853 | fi | |
3854 | done | |
3855 | IFS="$ac_save_ifs" | |
3856 | test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT" | |
3857 | ;; | |
3858 | esac | |
3859 | fi | |
3860 | GMSGFMT="$ac_cv_path_GMSGFMT" | |
3861 | if test -n "$GMSGFMT"; then | |
3862 | echo "$ac_t""$GMSGFMT" 1>&6 | |
3863 | else | |
3864 | echo "$ac_t""no" 1>&6 | |
3865 | fi | |
3866 | ||
3867 | # Extract the first word of "xgettext", so it can be a program name with args. | |
3868 | set dummy xgettext; ac_word=$2 | |
3869 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
37503931 | 3870 | echo "configure:3871: checking for $ac_word" >&5 |
252b5132 RH |
3871 | if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then |
3872 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3873 | else | |
3874 | case "$XGETTEXT" in | |
3875 | /*) | |
3876 | ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path. | |
3877 | ;; | |
3878 | *) | |
3879 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" | |
3880 | for ac_dir in $PATH; do | |
3881 | test -z "$ac_dir" && ac_dir=. | |
3882 | if test -f $ac_dir/$ac_word; then | |
3883 | if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then | |
3884 | ac_cv_path_XGETTEXT="$ac_dir/$ac_word" | |
3885 | break | |
3886 | fi | |
3887 | fi | |
3888 | done | |
3889 | IFS="$ac_save_ifs" | |
3890 | test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":" | |
3891 | ;; | |
3892 | esac | |
3893 | fi | |
3894 | XGETTEXT="$ac_cv_path_XGETTEXT" | |
3895 | if test -n "$XGETTEXT"; then | |
3896 | echo "$ac_t""$XGETTEXT" 1>&6 | |
3897 | else | |
3898 | echo "$ac_t""no" 1>&6 | |
3899 | fi | |
3900 | ||
3901 | cat > conftest.$ac_ext <<EOF | |
37503931 | 3902 | #line 3903 "configure" |
252b5132 RH |
3903 | #include "confdefs.h" |
3904 | ||
3905 | int main() { | |
3906 | extern int _nl_msg_cat_cntr; | |
3907 | return _nl_msg_cat_cntr | |
3908 | ; return 0; } | |
3909 | EOF | |
37503931 | 3910 | if { (eval echo configure:3911: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
252b5132 RH |
3911 | rm -rf conftest* |
3912 | CATOBJEXT=.gmo | |
3913 | DATADIRNAME=share | |
3914 | else | |
3915 | echo "configure: failed program was:" >&5 | |
3916 | cat conftest.$ac_ext >&5 | |
3917 | rm -rf conftest* | |
3918 | CATOBJEXT=.mo | |
3919 | DATADIRNAME=lib | |
3920 | fi | |
3921 | rm -f conftest* | |
3922 | INSTOBJEXT=.mo | |
3923 | fi | |
3924 | fi | |
3925 | ||
3926 | else | |
3927 | echo "$ac_t""no" 1>&6 | |
3928 | fi | |
3929 | ||
3930 | ||
3931 | ||
3932 | if test "$CATOBJEXT" = "NONE"; then | |
3933 | nls_cv_use_gnu_gettext=yes | |
3934 | fi | |
3935 | fi | |
3936 | ||
3937 | if test "$nls_cv_use_gnu_gettext" = "yes"; then | |
3938 | INTLOBJS="\$(GETTOBJS)" | |
3939 | # Extract the first word of "msgfmt", so it can be a program name with args. | |
3940 | set dummy msgfmt; ac_word=$2 | |
3941 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
37503931 | 3942 | echo "configure:3943: checking for $ac_word" >&5 |
252b5132 RH |
3943 | if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then |
3944 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3945 | else | |
3946 | case "$MSGFMT" in | |
3947 | /*) | |
3948 | ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. | |
3949 | ;; | |
3950 | *) | |
3951 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" | |
3952 | for ac_dir in $PATH; do | |
3953 | test -z "$ac_dir" && ac_dir=. | |
3954 | if test -f $ac_dir/$ac_word; then | |
3955 | if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then | |
3956 | ac_cv_path_MSGFMT="$ac_dir/$ac_word" | |
3957 | break | |
3958 | fi | |
3959 | fi | |
3960 | done | |
3961 | IFS="$ac_save_ifs" | |
3962 | test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="msgfmt" | |
3963 | ;; | |
3964 | esac | |
3965 | fi | |
3966 | MSGFMT="$ac_cv_path_MSGFMT" | |
3967 | if test -n "$MSGFMT"; then | |
3968 | echo "$ac_t""$MSGFMT" 1>&6 | |
3969 | else | |
3970 | echo "$ac_t""no" 1>&6 | |
3971 | fi | |
3972 | ||
3973 | # Extract the first word of "gmsgfmt", so it can be a program name with args. | |
3974 | set dummy gmsgfmt; ac_word=$2 | |
3975 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
37503931 | 3976 | echo "configure:3977: checking for $ac_word" >&5 |
252b5132 RH |
3977 | if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then |
3978 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3979 | else | |
3980 | case "$GMSGFMT" in | |
3981 | /*) | |
3982 | ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path. | |
3983 | ;; | |
3984 | ?:/*) | |
3985 | ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path. | |
3986 | ;; | |
3987 | *) | |
3988 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
3989 | ac_dummy="$PATH" | |
3990 | for ac_dir in $ac_dummy; do | |
3991 | test -z "$ac_dir" && ac_dir=. | |
3992 | if test -f $ac_dir/$ac_word; then | |
3993 | ac_cv_path_GMSGFMT="$ac_dir/$ac_word" | |
3994 | break | |
3995 | fi | |
3996 | done | |
3997 | IFS="$ac_save_ifs" | |
3998 | test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT" | |
3999 | ;; | |
4000 | esac | |
4001 | fi | |
4002 | GMSGFMT="$ac_cv_path_GMSGFMT" | |
4003 | if test -n "$GMSGFMT"; then | |
4004 | echo "$ac_t""$GMSGFMT" 1>&6 | |
4005 | else | |
4006 | echo "$ac_t""no" 1>&6 | |
4007 | fi | |
4008 | ||
4009 | # Extract the first word of "xgettext", so it can be a program name with args. | |
4010 | set dummy xgettext; ac_word=$2 | |
4011 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
37503931 | 4012 | echo "configure:4013: checking for $ac_word" >&5 |
252b5132 RH |
4013 | if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then |
4014 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4015 | else | |
4016 | case "$XGETTEXT" in | |
4017 | /*) | |
4018 | ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path. | |
4019 | ;; | |
4020 | *) | |
4021 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" | |
4022 | for ac_dir in $PATH; do | |
4023 | test -z "$ac_dir" && ac_dir=. | |
4024 | if test -f $ac_dir/$ac_word; then | |
4025 | if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then | |
4026 | ac_cv_path_XGETTEXT="$ac_dir/$ac_word" | |
4027 | break | |
4028 | fi | |
4029 | fi | |
4030 | done | |
4031 | IFS="$ac_save_ifs" | |
4032 | test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":" | |
4033 | ;; | |
4034 | esac | |
4035 | fi | |
4036 | XGETTEXT="$ac_cv_path_XGETTEXT" | |
4037 | if test -n "$XGETTEXT"; then | |
4038 | echo "$ac_t""$XGETTEXT" 1>&6 | |
4039 | else | |
4040 | echo "$ac_t""no" 1>&6 | |
4041 | fi | |
4042 | ||
4043 | ||
4044 | USE_INCLUDED_LIBINTL=yes | |
4045 | CATOBJEXT=.gmo | |
4046 | INSTOBJEXT=.mo | |
4047 | DATADIRNAME=share | |
4048 | INTLDEPS='$(top_builddir)/../intl/libintl.a' | |
4049 | INTLLIBS=$INTLDEPS | |
4050 | LIBS=`echo $LIBS | sed -e 's/-lintl//'` | |
4051 | nls_cv_header_intl=libintl.h | |
4052 | nls_cv_header_libgt=libgettext.h | |
4053 | fi | |
4054 | ||
4055 | if test "$XGETTEXT" != ":"; then | |
4056 | if $XGETTEXT --omit-header /dev/null 2> /dev/null; then | |
4057 | : ; | |
4058 | else | |
4059 | echo "$ac_t""found xgettext programs is not GNU xgettext; ignore it" 1>&6 | |
4060 | XGETTEXT=":" | |
4061 | fi | |
4062 | fi | |
4063 | ||
4064 | # We need to process the po/ directory. | |
4065 | POSUB=po | |
4066 | else | |
4067 | DATADIRNAME=share | |
4068 | nls_cv_header_intl=libintl.h | |
4069 | nls_cv_header_libgt=libgettext.h | |
4070 | fi | |
4071 | ||
4072 | # If this is used in GNU gettext we have to set USE_NLS to `yes' | |
4073 | # because some of the sources are only built for this goal. | |
4074 | if test "$PACKAGE" = gettext; then | |
4075 | USE_NLS=yes | |
4076 | USE_INCLUDED_LIBINTL=yes | |
4077 | fi | |
4078 | ||
4079 | for lang in $ALL_LINGUAS; do | |
4080 | GMOFILES="$GMOFILES $lang.gmo" | |
4081 | POFILES="$POFILES $lang.po" | |
4082 | done | |
4083 | ||
4084 | ||
4085 | ||
4086 | ||
4087 | ||
4088 | ||
4089 | ||
4090 | ||
4091 | ||
4092 | ||
4093 | ||
4094 | ||
4095 | ||
4096 | ||
4097 | if test "x$CATOBJEXT" != "x"; then | |
4098 | if test "x$ALL_LINGUAS" = "x"; then | |
4099 | LINGUAS= | |
4100 | else | |
4101 | echo $ac_n "checking for catalogs to be installed""... $ac_c" 1>&6 | |
37503931 | 4102 | echo "configure:4103: checking for catalogs to be installed" >&5 |
252b5132 RH |
4103 | NEW_LINGUAS= |
4104 | for lang in ${LINGUAS=$ALL_LINGUAS}; do | |
4105 | case "$ALL_LINGUAS" in | |
4106 | *$lang*) NEW_LINGUAS="$NEW_LINGUAS $lang" ;; | |
4107 | esac | |
4108 | done | |
4109 | LINGUAS=$NEW_LINGUAS | |
4110 | echo "$ac_t""$LINGUAS" 1>&6 | |
4111 | fi | |
4112 | ||
4113 | if test -n "$LINGUAS"; then | |
4114 | for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done | |
4115 | fi | |
4116 | fi | |
4117 | ||
4118 | if test $ac_cv_header_locale_h = yes; then | |
4119 | INCLUDE_LOCALE_H="#include <locale.h>" | |
4120 | else | |
4121 | INCLUDE_LOCALE_H="\ | |
4122 | /* The system does not provide the header <locale.h>. Take care yourself. */" | |
4123 | fi | |
4124 | ||
4125 | ||
4126 | if test -f $srcdir/po2tbl.sed.in; then | |
4127 | if test "$CATOBJEXT" = ".cat"; then | |
4128 | ac_safe=`echo "linux/version.h" | sed 'y%./+-%__p_%'` | |
4129 | echo $ac_n "checking for linux/version.h""... $ac_c" 1>&6 | |
37503931 | 4130 | echo "configure:4131: checking for linux/version.h" >&5 |
252b5132 RH |
4131 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
4132 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4133 | else | |
4134 | cat > conftest.$ac_ext <<EOF | |
37503931 | 4135 | #line 4136 "configure" |
252b5132 RH |
4136 | #include "confdefs.h" |
4137 | #include <linux/version.h> | |
4138 | EOF | |
4139 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
37503931 | 4140 | { (eval echo configure:4141: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
252b5132 RH |
4141 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
4142 | if test -z "$ac_err"; then | |
4143 | rm -rf conftest* | |
4144 | eval "ac_cv_header_$ac_safe=yes" | |
4145 | else | |
4146 | echo "$ac_err" >&5 | |
4147 | echo "configure: failed program was:" >&5 | |
4148 | cat conftest.$ac_ext >&5 | |
4149 | rm -rf conftest* | |
4150 | eval "ac_cv_header_$ac_safe=no" | |
4151 | fi | |
4152 | rm -f conftest* | |
4153 | fi | |
4154 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | |
4155 | echo "$ac_t""yes" 1>&6 | |
4156 | msgformat=linux | |
4157 | else | |
4158 | echo "$ac_t""no" 1>&6 | |
4159 | msgformat=xopen | |
4160 | fi | |
4161 | ||
4162 | ||
4163 | sed -e '/^#/d' $srcdir/$msgformat-msg.sed > po2msg.sed | |
4164 | fi | |
4165 | sed -e '/^#.*[^\\]$/d' -e '/^#$/d' \ | |
4166 | $srcdir/po2tbl.sed.in > po2tbl.sed | |
4167 | fi | |
4168 | ||
4169 | if test "$PACKAGE" = "gettext"; then | |
4170 | GT_NO="#NO#" | |
4171 | GT_YES= | |
4172 | else | |
4173 | GT_NO= | |
4174 | GT_YES="#YES#" | |
4175 | fi | |
4176 | ||
4177 | ||
4178 | ||
4179 | MKINSTALLDIRS="\$(srcdir)/../../mkinstalldirs" | |
4180 | ||
4181 | ||
4182 | l= | |
4183 | ||
4184 | ||
4185 | if test -d $srcdir/po; then | |
4186 | test -d po || mkdir po | |
4187 | if test "x$srcdir" != "x."; then | |
4188 | if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then | |
4189 | posrcprefix="$srcdir/" | |
4190 | else | |
4191 | posrcprefix="../$srcdir/" | |
4192 | fi | |
4193 | else | |
4194 | posrcprefix="../" | |
4195 | fi | |
4196 | rm -f po/POTFILES | |
4197 | sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \ | |
4198 | < $srcdir/po/POTFILES.in > po/POTFILES | |
4199 | fi | |
4200 | ||
4201 | ||
4202 | echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6 | |
37503931 | 4203 | echo "configure:4204: checking whether to enable maintainer-specific portions of Makefiles" >&5 |
252b5132 RH |
4204 | # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given. |
4205 | if test "${enable_maintainer_mode+set}" = set; then | |
4206 | enableval="$enable_maintainer_mode" | |
4207 | USE_MAINTAINER_MODE=$enableval | |
4208 | else | |
4209 | USE_MAINTAINER_MODE=no | |
4210 | fi | |
4211 | ||
4212 | echo "$ac_t""$USE_MAINTAINER_MODE" 1>&6 | |
4213 | ||
4214 | ||
4215 | if test $USE_MAINTAINER_MODE = yes; then | |
4216 | MAINTAINER_MODE_TRUE= | |
4217 | MAINTAINER_MODE_FALSE='#' | |
4218 | else | |
4219 | MAINTAINER_MODE_TRUE='#' | |
4220 | MAINTAINER_MODE_FALSE= | |
4221 | fi | |
4222 | MAINT=$MAINTAINER_MODE_TRUE | |
4223 | ||
4224 | ||
252b5132 RH |
4225 | |
4226 | ||
4227 | echo $ac_n "checking for executable suffix""... $ac_c" 1>&6 | |
37503931 | 4228 | echo "configure:4229: checking for executable suffix" >&5 |
252b5132 RH |
4229 | if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then |
4230 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4231 | else | |
4232 | if test "$CYGWIN" = yes || test "$MINGW32" = yes; then | |
4233 | ac_cv_exeext=.exe | |
4234 | else | |
4235 | rm -f conftest* | |
4236 | echo 'int main () { return 0; }' > conftest.$ac_ext | |
4237 | ac_cv_exeext= | |
37503931 | 4238 | if { (eval echo configure:4239: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
252b5132 RH |
4239 | for file in conftest.*; do |
4240 | case $file in | |
27b7e12d | 4241 | *.c | *.o | *.obj | *.ilk | *.pdb) ;; |
252b5132 RH |
4242 | *) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;; |
4243 | esac | |
4244 | done | |
4245 | else | |
4246 | { echo "configure: error: installation or configuration problem: compiler cannot create executables." 1>&2; exit 1; } | |
4247 | fi | |
4248 | rm -f conftest* | |
4249 | test x"${ac_cv_exeext}" = x && ac_cv_exeext=no | |
4250 | fi | |
4251 | fi | |
4252 | ||
4253 | EXEEXT="" | |
4254 | test x"${ac_cv_exeext}" != xno && EXEEXT=${ac_cv_exeext} | |
4255 | echo "$ac_t""${ac_cv_exeext}" 1>&6 | |
4256 | ac_exeext=$EXEEXT | |
4257 | ||
4258 | ||
0eee5820 AM |
4259 | for ac_hdr in sys/gmon_out.h |
4260 | do | |
4261 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` | |
4262 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 | |
4263 | echo "configure:4264: checking for $ac_hdr" >&5 | |
4264 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then | |
4265 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4266 | else | |
4267 | cat > conftest.$ac_ext <<EOF | |
4268 | #line 4269 "configure" | |
4269 | #include "confdefs.h" | |
4270 | #include <$ac_hdr> | |
4271 | EOF | |
4272 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
4273 | { (eval echo configure:4274: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } | |
4274 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` | |
4275 | if test -z "$ac_err"; then | |
4276 | rm -rf conftest* | |
4277 | eval "ac_cv_header_$ac_safe=yes" | |
4278 | else | |
4279 | echo "$ac_err" >&5 | |
4280 | echo "configure: failed program was:" >&5 | |
4281 | cat conftest.$ac_ext >&5 | |
4282 | rm -rf conftest* | |
4283 | eval "ac_cv_header_$ac_safe=no" | |
4284 | fi | |
4285 | rm -f conftest* | |
4286 | fi | |
4287 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | |
4288 | echo "$ac_t""yes" 1>&6 | |
4289 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` | |
4290 | cat >> confdefs.h <<EOF | |
4291 | #define $ac_tr_hdr 1 | |
4292 | EOF | |
4293 | ||
4294 | else | |
4295 | echo "$ac_t""no" 1>&6 | |
4296 | fi | |
4297 | done | |
4298 | ||
4299 | ||
4300 | echo $ac_n "checking the size of gmon pointers""... $ac_c" 1>&6 | |
4301 | echo "configure:4302: checking the size of gmon pointers" >&5 | |
4302 | if test "$cross_compiling" = yes; then | |
4303 | gmon_ptr_size=4 | |
4304 | else | |
4305 | cat > conftest.$ac_ext <<EOF | |
4306 | #line 4307 "configure" | |
4307 | #include "confdefs.h" | |
4308 | #include <stdio.h> | |
4309 | #include <stdlib.h> | |
4310 | #if HAVE_SYS_GMON_OUT_H | |
4311 | #include <sys/gmon_out.h> | |
4312 | #endif | |
4313 | main() | |
4314 | { | |
4315 | #if HAVE_SYS_GMON_OUT_H | |
4316 | struct gmon_cg_arc_record arc; | |
4317 | FILE *f=fopen("conftestval", "w"); | |
4318 | if (!f) exit(1); | |
4319 | fprintf(f, "%d\n", sizeof(arc.from_pc)); | |
4320 | exit(0); | |
4321 | #else | |
4322 | FILE *f=fopen("conftestval", "w"); | |
4323 | if (!f) exit(1); | |
4324 | fprintf(f, "%d\n", (int) sizeof(char *)); | |
4325 | exit(1); | |
4326 | #endif | |
4327 | } | |
4328 | EOF | |
4329 | if { (eval echo configure:4330: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null | |
4330 | then | |
4331 | gmon_ptr_size=`cat conftestval` | |
4332 | else | |
4333 | echo "configure: failed program was:" >&5 | |
4334 | cat conftest.$ac_ext >&5 | |
4335 | rm -fr conftest* | |
4336 | gmon_ptr_size=4 | |
4337 | fi | |
4338 | rm -fr conftest* | |
4339 | fi | |
4340 | ||
4341 | echo "$ac_t""$gmon_ptr_size" 1>&6 | |
4342 | ||
4343 | cat >> confdefs.h <<EOF | |
4344 | #define GMON_PTR_SIZE $gmon_ptr_size | |
4345 | EOF | |
4346 | ||
4347 | ||
a2d91340 AC |
4348 | build_warnings="-W -Wall" |
4349 | # Check whether --enable-build-warnings or --disable-build-warnings was given. | |
4350 | if test "${enable_build_warnings+set}" = set; then | |
4351 | enableval="$enable_build_warnings" | |
4352 | case "${enableval}" in | |
4353 | yes) ;; | |
4354 | no) build_warnings="-w";; | |
4355 | ,*) t=`echo "${enableval}" | sed -e "s/,/ /g"` | |
4356 | build_warnings="${build_warnings} ${t}";; | |
4357 | *,) t=`echo "${enableval}" | sed -e "s/,/ /g"` | |
4358 | build_warnings="${t} ${build_warnings}";; | |
4359 | *) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;; | |
4360 | esac | |
4361 | if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then | |
4362 | echo "Setting warning flags = $build_warnings" 6>&1 | |
4363 | fi | |
4364 | fi | |
4365 | WARN_CFLAGS="" | |
4366 | if test "x${build_warnings}" != x -a "x$GCC" = xyes ; then | |
4367 | WARN_CFLAGS="${build_warnings}" | |
4368 | fi | |
4369 | ||
4370 | ||
252b5132 RH |
4371 | trap '' 1 2 15 |
4372 | cat > confcache <<\EOF | |
4373 | # This file is a shell script that caches the results of configure | |
4374 | # tests run on this system so they can be shared between configure | |
4375 | # scripts and configure runs. It is not useful on other systems. | |
4376 | # If it contains results you don't want to keep, you may remove or edit it. | |
4377 | # | |
4378 | # By default, configure uses ./config.cache as the cache file, | |
4379 | # creating it if it does not exist already. You can give configure | |
4380 | # the --cache-file=FILE option to use a different cache file; that is | |
4381 | # what configure does when it calls configure scripts in | |
4382 | # subdirectories, so they share the cache. | |
4383 | # Giving --cache-file=/dev/null disables caching, for debugging configure. | |
4384 | # config.status only pays attention to the cache file if you give it the | |
4385 | # --recheck option to rerun configure. | |
4386 | # | |
4387 | EOF | |
4388 | # The following way of writing the cache mishandles newlines in values, | |
4389 | # but we know of no workaround that is simple, portable, and efficient. | |
4390 | # So, don't put newlines in cache variables' values. | |
4391 | # Ultrix sh set writes to stderr and can't be redirected directly, | |
4392 | # and sets the high bit in the cache file unless we assign to the vars. | |
4393 | (set) 2>&1 | | |
4394 | case `(ac_space=' '; set | grep ac_space) 2>&1` in | |
4395 | *ac_space=\ *) | |
4396 | # `set' does not quote correctly, so add quotes (double-quote substitution | |
4397 | # turns \\\\ into \\, and sed turns \\ into \). | |
4398 | sed -n \ | |
4399 | -e "s/'/'\\\\''/g" \ | |
4400 | -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p" | |
4401 | ;; | |
4402 | *) | |
4403 | # `set' quotes correctly as required by POSIX, so do not add quotes. | |
4404 | sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p' | |
4405 | ;; | |
4406 | esac >> confcache | |
4407 | if cmp -s $cache_file confcache; then | |
4408 | : | |
4409 | else | |
4410 | if test -w $cache_file; then | |
4411 | echo "updating cache $cache_file" | |
4412 | cat confcache > $cache_file | |
4413 | else | |
4414 | echo "not updating unwritable cache $cache_file" | |
4415 | fi | |
4416 | fi | |
4417 | rm -f confcache | |
4418 | ||
4419 | trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 | |
4420 | ||
4421 | test "x$prefix" = xNONE && prefix=$ac_default_prefix | |
4422 | # Let make expand exec_prefix. | |
4423 | test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' | |
4424 | ||
4425 | # Any assignment to VPATH causes Sun make to only execute | |
4426 | # the first set of double-colon rules, so remove it if not needed. | |
4427 | # If there is a colon in the path, we need to keep it. | |
4428 | if test "x$srcdir" = x.; then | |
4429 | ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d' | |
4430 | fi | |
4431 | ||
4432 | trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15 | |
4433 | ||
4434 | DEFS=-DHAVE_CONFIG_H | |
4435 | ||
4436 | # Without the "./", some shells look in PATH for config.status. | |
4437 | : ${CONFIG_STATUS=./config.status} | |
4438 | ||
4439 | echo creating $CONFIG_STATUS | |
4440 | rm -f $CONFIG_STATUS | |
4441 | cat > $CONFIG_STATUS <<EOF | |
4442 | #! /bin/sh | |
4443 | # Generated automatically by configure. | |
4444 | # Run this file to recreate the current configuration. | |
4445 | # This directory was configured as follows, | |
4446 | # on host `(hostname || uname -n) 2>/dev/null | sed 1q`: | |
4447 | # | |
4448 | # $0 $ac_configure_args | |
4449 | # | |
4450 | # Compiler output produced by configure, useful for debugging | |
4451 | # configure, is in ./config.log if it exists. | |
4452 | ||
4453 | ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]" | |
4454 | for ac_option | |
4455 | do | |
4456 | case "\$ac_option" in | |
4457 | -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) | |
4458 | echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion" | |
4459 | exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;; | |
4460 | -version | --version | --versio | --versi | --vers | --ver | --ve | --v) | |
4461 | echo "$CONFIG_STATUS generated by autoconf version 2.13" | |
4462 | exit 0 ;; | |
4463 | -help | --help | --hel | --he | --h) | |
4464 | echo "\$ac_cs_usage"; exit 0 ;; | |
4465 | *) echo "\$ac_cs_usage"; exit 1 ;; | |
4466 | esac | |
4467 | done | |
4468 | ||
4469 | ac_given_srcdir=$srcdir | |
4470 | ac_given_INSTALL="$INSTALL" | |
4471 | ||
4472 | trap 'rm -fr `echo "Makefile po/Makefile.in:po/Make-in gconfig.h:gconfig.in" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 | |
4473 | EOF | |
4474 | cat >> $CONFIG_STATUS <<EOF | |
4475 | ||
4476 | # Protect against being on the right side of a sed subst in config.status. | |
4477 | sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g; | |
4478 | s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF | |
4479 | $ac_vpsub | |
4480 | $extrasub | |
4481 | s%@SHELL@%$SHELL%g | |
4482 | s%@CFLAGS@%$CFLAGS%g | |
4483 | s%@CPPFLAGS@%$CPPFLAGS%g | |
4484 | s%@CXXFLAGS@%$CXXFLAGS%g | |
4485 | s%@FFLAGS@%$FFLAGS%g | |
4486 | s%@DEFS@%$DEFS%g | |
4487 | s%@LDFLAGS@%$LDFLAGS%g | |
4488 | s%@LIBS@%$LIBS%g | |
4489 | s%@exec_prefix@%$exec_prefix%g | |
4490 | s%@prefix@%$prefix%g | |
4491 | s%@program_transform_name@%$program_transform_name%g | |
4492 | s%@bindir@%$bindir%g | |
4493 | s%@sbindir@%$sbindir%g | |
4494 | s%@libexecdir@%$libexecdir%g | |
4495 | s%@datadir@%$datadir%g | |
4496 | s%@sysconfdir@%$sysconfdir%g | |
4497 | s%@sharedstatedir@%$sharedstatedir%g | |
4498 | s%@localstatedir@%$localstatedir%g | |
4499 | s%@libdir@%$libdir%g | |
4500 | s%@includedir@%$includedir%g | |
4501 | s%@oldincludedir@%$oldincludedir%g | |
4502 | s%@infodir@%$infodir%g | |
4503 | s%@mandir@%$mandir%g | |
4504 | s%@host@%$host%g | |
4505 | s%@host_alias@%$host_alias%g | |
4506 | s%@host_cpu@%$host_cpu%g | |
4507 | s%@host_vendor@%$host_vendor%g | |
4508 | s%@host_os@%$host_os%g | |
4509 | s%@target@%$target%g | |
4510 | s%@target_alias@%$target_alias%g | |
4511 | s%@target_cpu@%$target_cpu%g | |
4512 | s%@target_vendor@%$target_vendor%g | |
4513 | s%@target_os@%$target_os%g | |
4514 | s%@build@%$build%g | |
4515 | s%@build_alias@%$build_alias%g | |
4516 | s%@build_cpu@%$build_cpu%g | |
4517 | s%@build_vendor@%$build_vendor%g | |
4518 | s%@build_os@%$build_os%g | |
4519 | s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g | |
4520 | s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g | |
4521 | s%@INSTALL_DATA@%$INSTALL_DATA%g | |
4522 | s%@PACKAGE@%$PACKAGE%g | |
4523 | s%@VERSION@%$VERSION%g | |
4524 | s%@ACLOCAL@%$ACLOCAL%g | |
4525 | s%@AUTOCONF@%$AUTOCONF%g | |
4526 | s%@AUTOMAKE@%$AUTOMAKE%g | |
4527 | s%@AUTOHEADER@%$AUTOHEADER%g | |
4528 | s%@MAKEINFO@%$MAKEINFO%g | |
4529 | s%@SET_MAKE@%$SET_MAKE%g | |
37503931 | 4530 | s%@CC@%$CC%g |
252b5132 | 4531 | s%@LN_S@%$LN_S%g |
ac48eca1 AO |
4532 | s%@OBJEXT@%$OBJEXT%g |
4533 | s%@EXEEXT@%$EXEEXT%g | |
4534 | s%@RANLIB@%$RANLIB%g | |
4535 | s%@STRIP@%$STRIP%g | |
252b5132 RH |
4536 | s%@LIBTOOL@%$LIBTOOL%g |
4537 | s%@CPP@%$CPP%g | |
4538 | s%@ALLOCA@%$ALLOCA%g | |
4539 | s%@USE_NLS@%$USE_NLS%g | |
4540 | s%@MSGFMT@%$MSGFMT%g | |
4541 | s%@GMSGFMT@%$GMSGFMT%g | |
4542 | s%@XGETTEXT@%$XGETTEXT%g | |
4543 | s%@USE_INCLUDED_LIBINTL@%$USE_INCLUDED_LIBINTL%g | |
4544 | s%@CATALOGS@%$CATALOGS%g | |
4545 | s%@CATOBJEXT@%$CATOBJEXT%g | |
4546 | s%@DATADIRNAME@%$DATADIRNAME%g | |
4547 | s%@GMOFILES@%$GMOFILES%g | |
4548 | s%@INSTOBJEXT@%$INSTOBJEXT%g | |
4549 | s%@INTLDEPS@%$INTLDEPS%g | |
4550 | s%@INTLLIBS@%$INTLLIBS%g | |
4551 | s%@INTLOBJS@%$INTLOBJS%g | |
4552 | s%@POFILES@%$POFILES%g | |
4553 | s%@POSUB@%$POSUB%g | |
4554 | s%@INCLUDE_LOCALE_H@%$INCLUDE_LOCALE_H%g | |
4555 | s%@GT_NO@%$GT_NO%g | |
4556 | s%@GT_YES@%$GT_YES%g | |
4557 | s%@MKINSTALLDIRS@%$MKINSTALLDIRS%g | |
4558 | s%@l@%$l%g | |
4559 | s%@MAINTAINER_MODE_TRUE@%$MAINTAINER_MODE_TRUE%g | |
4560 | s%@MAINTAINER_MODE_FALSE@%$MAINTAINER_MODE_FALSE%g | |
4561 | s%@MAINT@%$MAINT%g | |
a2d91340 | 4562 | s%@WARN_CFLAGS@%$WARN_CFLAGS%g |
252b5132 RH |
4563 | |
4564 | CEOF | |
4565 | EOF | |
4566 | ||
4567 | cat >> $CONFIG_STATUS <<\EOF | |
4568 | ||
4569 | # Split the substitutions into bite-sized pieces for seds with | |
4570 | # small command number limits, like on Digital OSF/1 and HP-UX. | |
4571 | ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script. | |
4572 | ac_file=1 # Number of current file. | |
4573 | ac_beg=1 # First line for current file. | |
4574 | ac_end=$ac_max_sed_cmds # Line after last line for current file. | |
4575 | ac_more_lines=: | |
4576 | ac_sed_cmds="" | |
4577 | while $ac_more_lines; do | |
4578 | if test $ac_beg -gt 1; then | |
4579 | sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file | |
4580 | else | |
4581 | sed "${ac_end}q" conftest.subs > conftest.s$ac_file | |
4582 | fi | |
4583 | if test ! -s conftest.s$ac_file; then | |
4584 | ac_more_lines=false | |
4585 | rm -f conftest.s$ac_file | |
4586 | else | |
4587 | if test -z "$ac_sed_cmds"; then | |
4588 | ac_sed_cmds="sed -f conftest.s$ac_file" | |
4589 | else | |
4590 | ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file" | |
4591 | fi | |
4592 | ac_file=`expr $ac_file + 1` | |
4593 | ac_beg=$ac_end | |
4594 | ac_end=`expr $ac_end + $ac_max_sed_cmds` | |
4595 | fi | |
4596 | done | |
4597 | if test -z "$ac_sed_cmds"; then | |
4598 | ac_sed_cmds=cat | |
4599 | fi | |
4600 | EOF | |
4601 | ||
4602 | cat >> $CONFIG_STATUS <<EOF | |
4603 | ||
4604 | CONFIG_FILES=\${CONFIG_FILES-"Makefile po/Makefile.in:po/Make-in"} | |
4605 | EOF | |
4606 | cat >> $CONFIG_STATUS <<\EOF | |
4607 | for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then | |
4608 | # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". | |
4609 | case "$ac_file" in | |
4610 | *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'` | |
4611 | ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; | |
4612 | *) ac_file_in="${ac_file}.in" ;; | |
4613 | esac | |
4614 | ||
4615 | # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories. | |
4616 | ||
4617 | # Remove last slash and all that follows it. Not all systems have dirname. | |
4618 | ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` | |
4619 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then | |
4620 | # The file is in a subdirectory. | |
4621 | test ! -d "$ac_dir" && mkdir "$ac_dir" | |
4622 | ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`" | |
4623 | # A "../" for each directory in $ac_dir_suffix. | |
4624 | ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'` | |
4625 | else | |
4626 | ac_dir_suffix= ac_dots= | |
4627 | fi | |
4628 | ||
4629 | case "$ac_given_srcdir" in | |
4630 | .) srcdir=. | |
4631 | if test -z "$ac_dots"; then top_srcdir=. | |
4632 | else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;; | |
4633 | /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;; | |
4634 | *) # Relative path. | |
4635 | srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix" | |
4636 | top_srcdir="$ac_dots$ac_given_srcdir" ;; | |
4637 | esac | |
4638 | ||
4639 | case "$ac_given_INSTALL" in | |
4640 | [/$]*) INSTALL="$ac_given_INSTALL" ;; | |
4641 | *) INSTALL="$ac_dots$ac_given_INSTALL" ;; | |
4642 | esac | |
4643 | ||
4644 | echo creating "$ac_file" | |
4645 | rm -f "$ac_file" | |
4646 | configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure." | |
4647 | case "$ac_file" in | |
4648 | *Makefile*) ac_comsub="1i\\ | |
4649 | # $configure_input" ;; | |
4650 | *) ac_comsub= ;; | |
4651 | esac | |
4652 | ||
4653 | ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"` | |
4654 | sed -e "$ac_comsub | |
4655 | s%@configure_input@%$configure_input%g | |
4656 | s%@srcdir@%$srcdir%g | |
4657 | s%@top_srcdir@%$top_srcdir%g | |
4658 | s%@INSTALL@%$INSTALL%g | |
4659 | " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file | |
4660 | fi; done | |
4661 | rm -f conftest.s* | |
4662 | ||
4663 | # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where | |
4664 | # NAME is the cpp macro being defined and VALUE is the value it is being given. | |
4665 | # | |
4666 | # ac_d sets the value in "#define NAME VALUE" lines. | |
4667 | ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)' | |
4668 | ac_dB='\([ ][ ]*\)[^ ]*%\1#\2' | |
4669 | ac_dC='\3' | |
4670 | ac_dD='%g' | |
4671 | # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE". | |
4672 | ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' | |
4673 | ac_uB='\([ ]\)%\1#\2define\3' | |
4674 | ac_uC=' ' | |
4675 | ac_uD='\4%g' | |
4676 | # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE". | |
4677 | ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' | |
4678 | ac_eB='$%\1#\2define\3' | |
4679 | ac_eC=' ' | |
4680 | ac_eD='%g' | |
4681 | ||
4682 | if test "${CONFIG_HEADERS+set}" != set; then | |
4683 | EOF | |
4684 | cat >> $CONFIG_STATUS <<EOF | |
4685 | CONFIG_HEADERS="gconfig.h:gconfig.in" | |
4686 | EOF | |
4687 | cat >> $CONFIG_STATUS <<\EOF | |
4688 | fi | |
4689 | for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then | |
4690 | # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". | |
4691 | case "$ac_file" in | |
4692 | *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'` | |
4693 | ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; | |
4694 | *) ac_file_in="${ac_file}.in" ;; | |
4695 | esac | |
4696 | ||
4697 | echo creating $ac_file | |
4698 | ||
4699 | rm -f conftest.frag conftest.in conftest.out | |
4700 | ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"` | |
4701 | cat $ac_file_inputs > conftest.in | |
4702 | ||
4703 | EOF | |
4704 | ||
4705 | # Transform confdefs.h into a sed script conftest.vals that substitutes | |
4706 | # the proper values into config.h.in to produce config.h. And first: | |
4707 | # Protect against being on the right side of a sed subst in config.status. | |
4708 | # Protect against being in an unquoted here document in config.status. | |
4709 | rm -f conftest.vals | |
4710 | cat > conftest.hdr <<\EOF | |
4711 | s/[\\&%]/\\&/g | |
4712 | s%[\\$`]%\\&%g | |
4713 | s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp | |
4714 | s%ac_d%ac_u%gp | |
4715 | s%ac_u%ac_e%gp | |
4716 | EOF | |
4717 | sed -n -f conftest.hdr confdefs.h > conftest.vals | |
4718 | rm -f conftest.hdr | |
4719 | ||
4720 | # This sed command replaces #undef with comments. This is necessary, for | |
4721 | # example, in the case of _POSIX_SOURCE, which is predefined and required | |
4722 | # on some systems where configure will not decide to define it. | |
4723 | cat >> conftest.vals <<\EOF | |
4724 | s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */% | |
4725 | EOF | |
4726 | ||
4727 | # Break up conftest.vals because some shells have a limit on | |
4728 | # the size of here documents, and old seds have small limits too. | |
4729 | ||
4730 | rm -f conftest.tail | |
4731 | while : | |
4732 | do | |
4733 | ac_lines=`grep -c . conftest.vals` | |
4734 | # grep -c gives empty output for an empty file on some AIX systems. | |
4735 | if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi | |
4736 | # Write a limited-size here document to conftest.frag. | |
4737 | echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS | |
4738 | sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS | |
4739 | echo 'CEOF | |
4740 | sed -f conftest.frag conftest.in > conftest.out | |
4741 | rm -f conftest.in | |
4742 | mv conftest.out conftest.in | |
4743 | ' >> $CONFIG_STATUS | |
4744 | sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail | |
4745 | rm -f conftest.vals | |
4746 | mv conftest.tail conftest.vals | |
4747 | done | |
4748 | rm -f conftest.vals | |
4749 | ||
4750 | cat >> $CONFIG_STATUS <<\EOF | |
4751 | rm -f conftest.frag conftest.h | |
4752 | echo "/* $ac_file. Generated automatically by configure. */" > conftest.h | |
4753 | cat conftest.in >> conftest.h | |
4754 | rm -f conftest.in | |
4755 | if cmp -s $ac_file conftest.h 2>/dev/null; then | |
4756 | echo "$ac_file is unchanged" | |
4757 | rm -f conftest.h | |
4758 | else | |
4759 | # Remove last slash and all that follows it. Not all systems have dirname. | |
4760 | ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` | |
4761 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then | |
4762 | # The file is in a subdirectory. | |
4763 | test ! -d "$ac_dir" && mkdir "$ac_dir" | |
4764 | fi | |
4765 | rm -f $ac_file | |
4766 | mv conftest.h $ac_file | |
4767 | fi | |
4768 | fi; done | |
4769 | ||
4770 | EOF | |
4771 | cat >> $CONFIG_STATUS <<EOF | |
4772 | ||
4773 | ||
4774 | EOF | |
4775 | cat >> $CONFIG_STATUS <<\EOF | |
4776 | test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h | |
4777 | sed -e '/POTFILES =/r po/POTFILES' po/Makefile.in > po/Makefile | |
4778 | exit 0 | |
4779 | EOF | |
4780 | chmod +x $CONFIG_STATUS | |
4781 | rm -fr confdefs* $ac_clean_files | |
4782 | test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1 | |
4783 |