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